discord-mcp

Add role to member

discord_add_role

Write

Toolset
Roles roles
Discord permission
Manage Roles
Context cost
241 tokens, estimated963 bytes of definition, divided by 4

Assign an existing role to a member. Requires the Manage Roles permission, and the role must be below the bot's highest role. Idempotent: assigning a role the member already has has no effect. Use discord_remove_role to undo.

Risk and annotations

Read-onlyreadOnlyHintnoCan modify your server.
DestructivedestructiveHintnoDeclared non-destructive.
IdempotentidempotentHintyesRepeating the call with the same arguments has no additional effect.
Open worldopenWorldHintyesInteracts with an external system: Discord.

Annotations are hints the server declares. Clients use them to decide when to ask you before a call.

Parameters

ParameterTypeRulesDescription
guild_idrequiredstring
pattern ^\d{17,20}$
Discord server (guild) ID (snowflake).
user_idrequiredstring
pattern ^\d{17,20}$
Discord user ID (snowflake) of the member to give the role to.
role_idrequiredstring
pattern ^\d{17,20}$
ID (snowflake) of the role to assign.
reasonoptionalstring
none
Optional reason recorded in the server audit log.

Output

This tool declares no output schema. Its description says what it returns; this page shows no example rather than invent one.

Related tools

Named in its description

Also in Roles

Raw definition (963 bytes)
{
  "name": "discord_add_role",
  "description": "Assign an existing role to a member. Requires the Manage Roles permission, and the role must be below the bot's highest role. Idempotent: assigning a role the member already has has no effect. Use discord_remove_role to undo.",
  "inputSchema": {
    "type": "object",
    "properties": {
      "guild_id": {
        "type": "string",
        "pattern": "^\\d{17,20}$",
        "description": "Discord server (guild) ID (snowflake)."
      },
      "user_id": {
        "type": "string",
        "pattern": "^\\d{17,20}$",
        "description": "Discord user ID (snowflake) of the member to give the role to."
      },
      "role_id": {
        "type": "string",
        "pattern": "^\\d{17,20}$",
        "description": "ID (snowflake) of the role to assign."
      },
      "reason": {
        "description": "Optional reason recorded in the server audit log.",
        "type": "string"
      }
    },
    "required": [
      "guild_id",
      "user_id",
      "role_id"
    ],
    "additionalProperties": false
  },
  "annotations": {
    "title": "Add role to member",
    "readOnlyHint": false,
    "destructiveHint": false,
    "idempotentHint": true,
    "openWorldHint": true
  }
}