$interactionAttachment
$interactionAttachment
returns the URL of the attachment option’s value.
Usage
$interactionAttachment[option]
Parameters
Field | Type | Description | Required |
---|---|---|---|
option | string | The name of the attachment option. | true |
Example(s)
This will return the URL of the attached file in the attachment
option:
1$createApplicationCommand[$guildID;exampleslash;Simple example slash command.;true;true;slash;[{2 "name": "attachment",3 "description": "Example attachment option.",4 "required": true,5 "type": 116}]]
1client.interactionCommand({2 name: "exampleslash",3 prototype: "slash",4 code: `$interactionReply[Your attachment: $interactionAttachment[attachment]]`5});