v2

latestOpenAPI 3.1.02026-08-075421692.0 MB
Discord

Edit a Discord guild role

Updates a role's name, color, hoist, mentionable flag, or permission bitfield. At least one field must be supplied. Omitted fields are left unchanged.

Requires the bot to hold Manage Roles, and the target role must sit below the bot's highest role. See the create-role operation for the re-invite requirement.

patch/v1/discord/guilds/{guildId}/roles/{roleId}

Path parameters

guildIdstring required

Discord guild snowflake ID

roleIdstring required

Discord role snowflake ID

Query parameters

accountIdstring required

SocialAccount _id of the Discord account bound to this guild

Request body

namestring
colorinteger
hoistboolean
mentionableboolean
permissionsstring

Permissions bitfield as a stringified integer

Response

Role updated.