.setDescription(description)
description: string | null → this
attachmentMeta.setDescription(description);Class
Attachment metadata for message payloads (file bytes sent separately). Prefer AttachmentBuilder when attaching file data via files: [builder].
new AttachmentMeta(id: number, filename: string, options?: Partial<AttachmentPayloadOptions>)numberstringPartial<AttachmentPayloadOptions>| Name | Type | Description |
|---|---|---|
| description? | string | null | Alt text / description for accessibility. |
| filename | string | Filename (may be prefixed with SPOILER_ if spoiler is true). |
| idread-only | number | Attachment ID (index in files array). |
| spoiler | boolean | Whether this attachment should be hidden until clicked. |
description: string | null → this
attachmentMeta.setDescription(description);name: string → this
attachmentMeta.setName(name);spoiler: boolean → this
attachmentMeta.setSpoiler(spoiler);