interface APIAttachment

export interface APIAttachment

See also: https://discord.com/developers/docs/resources/message#attachment-object-attachment-structure

optional
application? : APIApplication | null

For Clips, the application in the stream, if recognized

optional
clip_created_at? : string

For Clips, when the clip was created

optional
clip_participants? : APIUser[]

For Clips, array of users who were in the stream

optional
content_type? : string

The attachment's media type

See also: https://en.wikipedia.org/wiki/Media_type

optional
description? : string

Description (alt text) for the file (max 1024 characters)

optional
duration_secs? : number

The duration of the audio file (currently for voice messages)

optional
ephemeral? : boolean

Whether this attachment is ephemeral

filename : string

Name of file attached

optional
flags? : AttachmentFlags

Attachment flags combined as a bitfield

optional
height? : number | null

Height of file (if image or video)

id : Snowflake

Attachment id

optional
placeholder_version? : number

Version of the placeholder (if image or video)

optional
placeholder? : string

ThumbHash placeholder (if image or video)

See also: https://evanw.github.io/thumbhash/

proxy_url : string

A proxied url of file

size : number

Size of file in bytes

optional
title? : string

The original filename of the upload with special characters preservedThis will be present when the filename contains special characters (e.g. Cyrillic), in which case the filename field will be a sanitized version without those characters

url : string

Source url of file

optional
waveform? : string

Base64 encoded bytearray representing a sampled waveform (currently for voice messages)

optional
width? : number | null

Width of file (if image or video)