Add a role menu
/api/settings/discord-role-menusSave a new role menu. It is not posted until Post is called. style is buttons or select. Between 1 and 25 roles, each with a label of at most 80 characters on one line and an optional emoji; a role with a dangerous permission is refused.
Needs the ManageSettings permission.
An API key, made on Settings, API keys. Every key starts with mbk_.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/problem+json
application/problem+json
application/problem+json
curl -X POST "https://example.com/api/settings/discord-role-menus" \ -H "Content-Type: application/json" \ -d '{ "name": "string", "channelId": "string", "text": "string", "style": "string", "singleChoice": true, "roles": null }'{ "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "name": "string", "channelId": "string", "text": "string", "style": "string", "singleChoice": true, "roles": [ { "roleId": "string", "label": "string", "emoji": null } ], "messageId": null, "postedAt": null, "changedSincePosted": true}List role menus GET
The role menus Modbot posts in Discord, each with the roles it gives and whether its message is up. Needs the `ManageSettings` permission.
Delete a role menu DELETE
Delete the role menu and, when it is posted, its message in Discord. Roles members already picked stay with them. Needs the `ManageSettings` permission.