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

Discord MCP - Discord server management MCP for AI agents

Prune members

prune_members
Destructive

Remove server members who have been inactive for a set number of days and hold no roles; preview the count first, then confirm to apply the cleanup.

Instructions

Remove members inactive for a number of days who hold no roles. Needs Kick Members and Manage Server, or Administrator where the owner has made pruning admin-only. Safe to call directly: the first call counts who would go using Discord's own preview and returns a confirm_token; repeating the call with the token prunes for real.

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": {
      "days": "<days>"
    },
    "name": "prune_members"
  }
}

Input Schema

NameRequiredDescriptionDefault
daysYesInactivity threshold in days.
guildNoGuild (server) name or ID. Omit to use the default guild.
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. Changed2 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 / description
      Added value: +"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."
  3. Changed1 schema field changedv1.3.0
    • removedInput schema / additionalProperties
      Removed value: -false
  4. First observedv1.0.2

TDQS

A4.2/5.0
Behavior4/5

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

Goes well beyond the destructiveHint=true annotation by naming the required permissions (Kick Members and Manage Server, or Administrator under admin-only pruning) and explaining the preview-vs-execute token behavior. It stops short of saying the removed members are kicked and whether the action is reversible or logged, though the reason parameter implies an audit trail.

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

Conciseness5/5

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

Three sentences, front-loaded with the purpose and then permissions and the safety flow. Every sentence carries information the agent needs; nothing is restated from the name or annotations.

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 destructive, five-parameter tool with no output schema, the description covers permissions, the guardrail flow, and what the preview returns. The only gap is the shape of the result after execution (who was removed, counts), which the agent must infer.

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

Parameters3/5

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

Schema coverage is 100%, so the baseline applies. The description adds useful workflow meaning by tying confirm_token to the preview result, but it provides no per-parameter detail beyond what the schema already documents for days, guild, reason, and dry_run.

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 with the exact selection criteria: remove members who are inactive for N days and hold no roles. That criterion-set distinguishes it from the list/search/role-assignment siblings without needing to name them.

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 clear procedural guidance for the two-step flow (first call previews and returns confirm_token, second call with the token executes) and says it is 'safe to call directly.' It does not name alternatives such as kicking or banning individual members, so the when-not-to-use case is only implied.

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