APIAttachment

https://discord.com/developers/docs/resources/channel#attachment-object-attachment-structure

Signature

export interface APIAttachment

Properties

filename: string;

Name of file attached

title?: string;

The title of the file

content_type?: string;

The attachment's media type See https://en.wikipedia.org/wiki/Media_type

size: number;

Size of file in bytes

url: string;

Source url of file

height?: number | null;

Height of file (if image)

width?: number | null;

Width of file (if image)

ephemeral?: boolean;

Whether this attachment is ephemeral

duration_secs?: number;

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

waveform?: string;

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