Skip to main content
Glama
Discord MCP - Discord server management MCP for AI agents

Discord MCP - Discord server management MCP for AI agents

Remove role

remove_role

Remove a role from a Discord member after a hierarchy check, using a confirmation preview to avoid accidental access changes.

Instructions

Take a role away from a member. Preflights the bot's role hierarchy so a failure is an explanation, not a 403. Usually done at once. A role can also hold someone back (one that hides channels from whoever has it, such as a quarantine role); taking that away lets them in, so it needs confirming: the first call changes nothing and returns a preview and a confirm_token, and repeating the call with the token makes the change.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "member": "<member>",
      "role": "<role>"
    },
    "name": "remove_role"
  }
}

Input Schema

NameRequiredDescriptionDefault
roleYesRole name or ID.
guildNoGuild (server) name or ID. Omit to use the default guild.
memberYesMember name or user ID.
reasonNoThe reason recorded in the server's audit log.
dry_runNoIf true, nothing is changed: the result shows what this call would do.
confirm_tokenNoThe token from this exact action's preview. Where the app can show a confirmation dialog, calling with it asks the user there, and it happens only if they agree.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv2.2.2
    • addedInput schema / properties / dry_run / description
      Added value: +"If true, nothing is changed: the result shows what this call would do."
    • addedInput schema / properties / reason / description
      Added value: +"The reason recorded in the server's audit log."
  2. Changed3 schema fields changedv1.4.2
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • addedInput schema / properties / confirm_token
      Added value: +{
      +  "description": "The token from this exact action's preview. Where the app can show a confirmation dialog, calling with it asks the user there, and it happens only if they agree.",
      +  "type": "string"
      +}
    • addedInput schema / properties / dry_run
      Added value: +{
      +  "type": "boolean"
      +}
  3. Changed1 schema field changedv1.3.0
    • removedInput schema / additionalProperties
      Removed value: -false
  4. First observedv1.0.2

TDQS

A4.5/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Goes well beyond the annotations by disclosing the preflight hierarchy check that turns a permission failure into an explanation, the two-phase preview/confirm_token protocol, and the fact that the first call changes nothing. This is exactly the mutation behavior an agent needs and cannot get from readOnlyHint=false / destructiveHint=false.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the core action, and each sentence carries distinct information. The final sentence is dense and the parenthetical quarantine example slows parsing slightly, but nothing is redundant.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a six-parameter mutation with no output schema and only terse annotations, the description covers the permission-failure mode, the confirmation workflow, and the dual (restrictive vs. permissive) nature of role removal. Return-value shape is unspecified but arguably covered by describing the preview response.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3, but the description adds the sequencing meaning of confirm_token and dry_run that the schema only states individually — the first call yields a preview and token, and the repeat call with the token performs the change. It does not clarify the audit-log reason or default-guild behavior beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Take a role away from a member'), which cleanly distinguishes it from assign_role, delete_role, and update_role in the sibling list. An agent can identify the operation without opening the schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives real context for when the tool behaves differently: 'Usually done at once,' but a role that hides channels (e.g. a quarantine role) requires the confirm flow because removal grants access. It does not explicitly route the agent to assign_role or bulk_update_roles, so sibling-level guidance is implied rather than stated.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools