Button Routes

These are the API routes to do with the discord buttons on the project.

Create a new button

POST /buttons/add

This will create a new discord button

Headers

Name
Value

Content-Type

application/json

Authorization

<key>

Body

Name
Type
Description

buttonId

UUIDv4

The database Id of the button

discordButtonId

string

The unique id for the discord button

guildId

string

The id of the guild where the button is added

channelId

string

The id of the discord channel for the button

messageId

string

The id of the message for the discord button

buttonType

string

The buttonType used in the buttonInteraction system

buttonJsonExtraData

json as string

This is the extra data that buttons can carry

Response

{
    "created": boolean
}

Delete button

POST /buttons/remove

This will delete the button from a id

Headers

Name
Value

Content-Type

application/json

Authorization

<key>

Body

Name
Type
Description

buttonId

UUIDv4

The database id for the button

Response

Get Button

GET /buttons/get/[ Discord Button Id ]/[ Discord Channel Id ]/[ Discord Message Id ]/[ Discord Guild Id ]

This will respond with button information

Headers

Name
Value

Content-Type

application/json

Authorization

<key>

Request

Name
Type
Description

Discord Button Id

string

The custom id of the discord button

Discord Channel Id

string

The id from the discord channel

Discord Message Id

string

The id from the discord message

Discord Guild Id

string

The id from the discord guild

Response

Does Button Exist

GET /buttons/exist/[ Discord Button Id ]/[ Discord Channel Id ]/[ Message Id ]/[ Discord Guild Id ]

This will respond with button information

Headers

Name
Value

Content-Type

application/json

Authorization

<key>

Request

Name
Type
Description

Discord Button Id

string

The custom id of the discord button

Discord Channel Id

string

The id from the discord channel

Discord Message Id

string

The id from the discord message

Discord Guild Id

string

The id from the discord guild

Response

Last updated