discord-mcp

Prune inactive members

discord_prune_members

DestructiveDry run by default

Toolset
Members members
Discord permissions
Manage Server and Kick Members
Context cost
364 tokens, estimated1,457 bytes of definition, divided by 4

Remove members who have been inactive (no roles, not seen) for a number of days. SAFE BY DEFAULT: dry_run is true unless explicitly set to false, so call it first to preview the count, then re-call with dry_run:false to actually remove them. Removal is irreversible (members must rejoin). Requires the Manage Server and Kick Members permissions (Administrator when the server has the PRUNE_REQUIRES_ADMIN feature).

Risk and annotations

Read-onlyreadOnlyHintnoCan modify your server.
DestructivedestructiveHintyesMay perform destructive updates, so clients can ask before running it.
IdempotentidempotentHintnoRepeating the call can have an 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).
daysrequiredinteger
1 to 30
Inactivity threshold in days (1–30).
rolesoptionalarray of strings
none
Optional role IDs (snowflakes) to include; by default only members with no roles are counted. A member with roles is counted only when every role they hold is in this list.
dry_runoptionalboolean
default true
If true (default), only returns the count that would be pruned without removing anyone. Set false to actually prune.
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

Also in Members

Raw definition (1,457 bytes)
{
  "name": "discord_prune_members",
  "description": "Remove members who have been inactive (no roles, not seen) for a number of days. SAFE BY DEFAULT: dry_run is true unless explicitly set to false, so call it first to preview the count, then re-call with dry_run:false to actually remove them. Removal is irreversible (members must rejoin). Requires the Manage Server and Kick Members permissions (Administrator when the server has the PRUNE_REQUIRES_ADMIN feature).",
  "inputSchema": {
    "type": "object",
    "properties": {
      "guild_id": {
        "type": "string",
        "pattern": "^\\d{17,20}$",
        "description": "Discord server (guild) ID (snowflake)."
      },
      "days": {
        "type": "integer",
        "minimum": 1,
        "maximum": 30,
        "description": "Inactivity threshold in days (1–30)."
      },
      "roles": {
        "description": "Optional role IDs (snowflakes) to include; by default only members with no roles are counted. A member with roles is counted only when every role they hold is in this list.",
        "type": "array",
        "items": {
          "type": "string",
          "pattern": "^\\d{17,20}$"
        }
      },
      "dry_run": {
        "default": true,
        "description": "If true (default), only returns the count that would be pruned without removing anyone. Set false to actually prune.",
        "type": "boolean"
      },
      "reason": {
        "description": "Optional reason recorded in the server audit log.",
        "type": "string"
      }
    },
    "required": [
      "guild_id",
      "days"
    ],
    "additionalProperties": false
  },
  "annotations": {
    "title": "Prune inactive members",
    "readOnlyHint": false,
    "destructiveHint": true,
    "idempotentHint": false,
    "openWorldHint": true
  }
}