Skip to main content
Glama
discord-mcp

discord-mcp

permissions_audit_channel

Read-onlyIdempotent

Audit which guild roles can view, send in, or manage a channel or thread per role, including @everyone, and get allowed, denied, and unknown counts before changing permissions.

Instructions

Purpose: Audit which individual guild roles can view, send in, or manage one channel or thread. Each role is evaluated independently with @everyone; member-specific overwrites and multi-role combinations are intentionally excluded. Thread management uses MANAGE_THREADS.

When to use: - Review channel exposure before redesigning roles or permission overwrites. - Find role baselines that allow, deny, or cannot prove channel access.

When NOT to use: - Determining one member's effective access; use permissions_explain for that member. - Predicting whether a locked or archived thread operation will succeed right now; this audits permission baselines, not mutable thread state. - Mutating roles or overwrites; this tool is read-only.

Returns: a compact per-role action matrix plus allowed, denied, and unknown counts. Omit actions to audit all three actions; select fewer actions to reduce output.

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": {
      "guild_id": "<guild_id>",
      "channel_id": "<channel_id>"
    },
    "name": "permissions_audit_channel"
  }
}

Input Schema

NameRequiredDescriptionDefault
actionsNoOptional action subset; defaults to view_channel, send_messages, manage_channel
guild_idYesGuild whose roles should be audited
channel_idYesGuild channel or thread whose role baselines should be audited

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.28.0
    • changedOutput schema / anyOf
      Previous value: -[
      -  {
      -    "$schema": "https://json-schema.org/draft/2020-12/schema",
      -    "additionalProperties": {},
      -    "properties": {
      -      "channel_id": {
      -        "description": "Discord channel ID (snowflake)",
      -        "pattern": "^\\d{17,20}$",
      -        "type": "string"
      -      },
      -      "confidence": {
      -        "enum": [
      -          "complete",
      -          "partial"
      -        ],
      -        "type": "string"
      -      },
      -      "guild_id": {
      -        "description": "Discord guild (server) ID",
      -        "pattern": "^\\d{17,20}$",
      -        "type": "string"
      -      },
      -      "member_overwrite_count": {
      -        "maximum": 9007199254740991,
      -        "minimum": 0,
      -        "type": "integer"
      -      },
      -      "permission_source_channel_id": {
      -        "anyOf": [
      -          {
      -            "description": "Discord channel ID (snowflake)",
      -            "pattern": "^\\d{17,20}$",
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ]
      -      },
      -      "requested_actions": {
      -        "items": {
      -          "enum": [
      -            "view_channel",
      -            "send_messages",
      -            "manage_channel"
      -          ],
      -          "type": "string"
      -        },
      -        "type": "array"
      -      },
      -      "roles": {
      -        "items": {
      -          "additionalProperties": false,
      -          "properties": {
      -            "actions": {
      -              "additionalProperties": false,
      -              "properties": {
      -                "manage_channel": {
      -                  "anyOf": [
      -                    {
      -                      "type": "boolean"
      -                    },
      -                    {
      -                      "type": "null"
      -                    }
      -                  ]
      -                },
      -                "send_messages": {
      -                  "anyOf": [
      -                    {
      -                      "type": "boolean"
      -                    },
      -                    {
      -                      "type": "null"
      -                    }
      -                  ]
      -                },
      -                "view_channel": {
      -                  "anyOf": [
      -                    {
      -                      "type": "boolean"
      -                    },
      -                    {
      -                      "type": "null"
      -                    }
      -                  ]
      -                }
      -              },
      -              "type": "object"
      -            },
      -            "administrator": {
      -              "type": "boolean"
      -            },
      -            "id": {
      -              "description": "Discord role ID",
      -              "pattern": "^\\d{17,20}$",
      -              "type": "string"
      -            },
      -            "managed": {
      -              "type": "boolean"
      -            },
      -            "name": {
      -              "type": "string"
      -            },
      -            "position": {
      -              "maximum": 9007199254740991,
      -              "minimum": -9007199254740991,
      -              "type": "integer"
      -            }
      -          },
      -          "required": [
      -            "id",
      -            "name",
      -            "position",
      -            "managed",
      -            "administrator",
      -            "actions"
      -          ],
      -          "type": "object"
      -        },
      -        "type": "array"
      -      },
      -      "summary": {
      -        "additionalProperties": false,
      -        "properties": {
      -          "by_action": {
      -            "additionalProperties": false,
      -            "properties": {
      -              "manage_channel": {
      -                "additionalProperties": false,
      -                "properties": {
      -                  "allowed": {
      -                    "maximum": 9007199254740991,
      -                    "minimum": 0,
      -                    "type": "integer"
      -                  },
      -                  "denied": {
      -                    "maximum": 9007199254740991,
      -                    "minimum": 0,
      -                    "type": "integer"
      -                  },
      -                  "unknown": {
      -                    "maximum": 9007199254740991,
      -                    "minimum": 0,
      -                    "type": "integer"
      -                  }
      -                },
      -                "required": [
      -                  "allowed",
      -                  "denied",
      -                  "unknown"
      -                ],
      -                "type": "object"
      -              },
      -              "send_messages": {
      -                "additionalProperties": false,
      -                "properties": {
      -                  "allowed": {
      -                    "maximum": 9007199254740991,
      -                    "minimum": 0,
      -                    "type": "integer"
      -                  },
      -                  "denied": {
      -                    "maximum": 9007199254740991,
      -                    "minimum": 0,
      -                    "type": "integer"
      -                  },
      -                  "unknown": {
      -                    "maximum": 9007199254740991,
      -                    "minimum": 0,
      -                    "type": "integer"
      -                  }
      -                },
      -                "required": [
      -                  "allowed",
      -                  "denied",
      -                  "unknown"
      -                ],
      -                "type": "object"
      -              },
      -              "view_channel": {
      -                "additionalProperties": false,
      -                "properties": {
      -                  "allowed": {
      -                    "maximum": 9007199254740991,
      -                    "minimum": 0,
      -                    "type": "integer"
      -                  },
      -                  "denied": {
      -                    "maximum": 9007199254740991,
      -                    "minimum": 0,
      -                    "type": "integer"
      -                  },
      -                  "unknown": {
      -                    "maximum": 9007199254740991,
      -                    "minimum": 0,
      -                    "type": "integer"
      -                  }
      -                },
      -                "required": [
      -                  "allowed",
      -                  "denied",
      -                  "unknown"
      -                ],
      -                "type": "object"
      -              }
      -            },
      -            "type": "object"
      -          },
      -          "role_count": {
      -            "maximum": 9007199254740991,
      -            "minimum": 0,
      -            "type": "integer"
      -          }
      -        },
      -        "required": [
      -          "role_count",
      -          "by_action"
      -        ],
      -        "type": "object"
      -      },
      -      "unknown_permission_bits": {
      -        "description": "Discord permission bitfield as a base-10 string (e.g. \"8\" = ADMINISTRATOR).",
      -        "pattern": "^\\d+$",
      -        "type": "string"
      -      },
      -      "warnings": {
      -        "items": {
      -          "type": "string"
      -        },
      -        "type": "array"
      -      }
      -    },
      -    "required": [
      -      "guild_id",
      -      "channel_id",
      -      "permission_source_channel_id",
      -      "requested_actions",
      -      "roles",
      -      "summary",
      -      "member_overwrite_count",
      -      "unknown_permission_bits",
      -      "warnings",
      -      "confidence"
      -    ],
      -    "type": "object"
      -  },
      -  {
      -    "properties": {
      -      "category": {
      -        "enum": [
      -          "client",
      -          "server"
      -        ],
      -        "type": "string"
      -      },
      -      "code": {
      -        "type": "string"
      -      },
      -      "recovery_hint": {
      -        "type": "string"
      -      },
      -      "retriable": {
      -        "type": "boolean"
      -      }
      -    },
      -    "required": [
      -      "code",
      -      "retriable",
      -      "category",
      -      "recovery_hint"
      -    ],
      -    "type": "object"
      -  }
      -]New value: +[
      +  {
      +    "$schema": "https://json-schema.org/draft/2020-12/schema",
      +    "additionalProperties": {},
      +    "properties": {
      +      "channel_id": {
      +        "description": "Discord channel ID (snowflake)",
      +        "pattern": "^\\d{17,20}$",
      +        "type": "string"
      +      },
      +      "confidence": {
      +        "enum": [
      +          "complete",
      +          "partial"
      +        ],
      +        "type": "string"
      +      },
      +      "guild_id": {
      +        "description": "Discord guild (server) ID",
      +        "pattern": "^\\d{17,20}$",
      +        "type": "string"
      +      },
      +      "member_overwrite_count": {
      +        "maximum": 9007199254740991,
      +        "minimum": 0,
      +        "type": "integer"
      +      },
      +      "permission_source_channel_id": {
      +        "anyOf": [
      +          {
      +            "description": "Discord channel ID (snowflake)",
      +            "pattern": "^\\d{17,20}$",
      +            "type": "string"
      +          },
      +          {
      +            "type": "null"
      +          }
      +        ]
      +      },
      +      "requested_actions": {
      +        "items": {
      +          "enum": [
      +            "view_channel",
      +            "send_messages",
      +            "manage_channel"
      +          ],
      +          "type": "string"
      +        },
      +        "type": "array"
      +      },
      +      "roles": {
      +        "items": {
      +          "additionalProperties": false,
      +          "properties": {
      +            "actions": {
      +              "additionalProperties": false,
      +              "properties": {
      +                "manage_channel": {
      +                  "type": [
      +                    "boolean",
      +                    "null"
      +                  ]
      +                },
      +                "send_messages": {
      +                  "type": [
      +                    "boolean",
      +                    "null"
      +                  ]
      +                },
      +                "view_channel": {
      +                  "type": [
      +                    "boolean",
      +                    "null"
      +                  ]
      +                }
      +              },
      +              "type": "object"
      +            },
      +            "administrator": {
      +              "type": "boolean"
      +            },
      +            "id": {
      +              "description": "Discord role ID",
      +              "pattern": "^\\d{17,20}$",
      +              "type": "string"
      +            },
      +            "managed": {
      +              "type": "boolean"
      +            },
      +            "name": {
      +              "type": "string"
      +            },
      +            "position": {
      +              "maximum": 9007199254740991,
      +              "minimum": -9007199254740991,
      +              "type": "integer"
      +            }
      +          },
      +          "required": [
      +            "id",
      +            "name",
      +            "position",
      +            "managed",
      +            "administrator",
      +            "actions"
      +          ],
      +          "type": "object"
      +        },
      +        "type": "array"
      +      },
      +      "summary": {
      +        "additionalProperties": false,
      +        "properties": {
      +          "by_action": {
      +            "additionalProperties": false,
      +            "properties": {
      +              "manage_channel": {
      +                "additionalProperties": false,
      +                "properties": {
      +                  "allowed": {
      +                    "maximum": 9007199254740991,
      +                    "minimum": 0,
      +                    "type": "integer"
      +                  },
      +                  "denied": {
      +                    "maximum": 9007199254740991,
      +                    "minimum": 0,
      +                    "type": "integer"
      +                  },
      +                  "unknown": {
      +                    "maximum": 9007199254740991,
      +                    "minimum": 0,
      +                    "type": "integer"
      +                  }
      +                },
      +                "required": [
      +                  "allowed",
      +                  "denied",
      +                  "unknown"
      +                ],
      +                "type": "object"
      +              },
      +              "send_messages": {
      +                "additionalProperties": false,
      +                "properties": {
      +                  "allowed": {
      +                    "maximum": 9007199254740991,
      +                    "minimum": 0,
      +                    "type": "integer"
      +                  },
      +                  "denied": {
      +                    "maximum": 9007199254740991,
      +                    "minimum": 0,
      +                    "type": "integer"
      +                  },
      +                  "unknown": {
      +                    "maximum": 9007199254740991,
      +                    "minimum": 0,
      +                    "type": "integer"
      +                  }
      +                },
      +                "required": [
      +                  "allowed",
      +                  "denied",
      +                  "unknown"
      +                ],
      +                "type": "object"
      +              },
      +              "view_channel": {
      +                "additionalProperties": false,
      +                "properties": {
      +                  "allowed": {
      +                    "maximum": 9007199254740991,
      +                    "minimum": 0,
      +                    "type": "integer"
      +                  },
      +                  "denied": {
      +                    "maximum": 9007199254740991,
      +                    "minimum": 0,
      +                    "type": "integer"
      +                  },
      +                  "unknown": {
      +                    "maximum": 9007199254740991,
      +                    "minimum": 0,
      +                    "type": "integer"
      +                  }
      +                },
      +                "required": [
      +                  "allowed",
      +                  "denied",
      +                  "unknown"
      +                ],
      +                "type": "object"
      +              }
      +            },
      +            "type": "object"
      +          },
      +          "role_count": {
      +            "maximum": 9007199254740991,
      +            "minimum": 0,
      +            "type": "integer"
      +          }
      +        },
      +        "required": [
      +          "role_count",
      +          "by_action"
      +        ],
      +        "type": "object"
      +      },
      +      "unknown_permission_bits": {
      +        "description": "Discord permission bitfield as a base-10 string (e.g. \"8\" = ADMINISTRATOR).",
      +        "pattern": "^\\d+$",
      +        "type": "string"
      +      },
      +      "warnings": {
      +        "items": {
      +          "type": "string"
      +        },
      +        "type": "array"
      +      }
      +    },
      +    "required": [
      +      "guild_id",
      +      "channel_id",
      +      "permission_source_channel_id",
      +      "requested_actions",
      +      "roles",
      +      "summary",
      +      "member_overwrite_count",
      +      "unknown_permission_bits",
      +      "warnings",
      +      "confidence"
      +    ],
      +    "type": "object"
      +  },
      +  {
      +    "properties": {
      +      "category": {
      +        "enum": [
      +          "client",
      +          "server"
      +        ],
      +        "type": "string"
      +      },
      +      "code": {
      +        "type": "string"
      +      },
      +      "recovery_hint": {
      +        "type": "string"
      +      },
      +      "retriable": {
      +        "type": "boolean"
      +      }
      +    },
      +    "required": [
      +      "code",
      +      "retriable",
      +      "category",
      +      "recovery_hint"
      +    ],
      +    "type": "object"
      +  }
      +]
  2. First observedv0.22.0

TDQS

A4.6/5.0
Behavior4/5

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

Beyond the readOnly/idempotent/non-destructive annotations, it discloses real behavioral limits: each role is evaluated independently with @everyone, member overwrites and multi-role combinations are excluded, thread management keys off MANAGE_THREADS, and results include an 'unknown' bucket where access cannot be proven. That 'unknown' category and the exclusion of multi-role combination are the kind of caveats an agent would otherwise get wrong; the only minor gap is that it does not describe pagination or scale limits, which matters little for a per-role matrix.

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 purpose followed by use/exclusion/return sections, so scanning is fast and nothing is buried. Slightly verbose in its labeled-section format, and the 'read-only' line restates the readOnlyHint annotation, but no sentence is genuinely wasted.

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

Completeness5/5

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

For a three-parameter read-only audit with a full schema and an output schema, the definition covers what is measured, what is deliberately excluded, when to route elsewhere, and what the output shape contains. An agent has everything needed to pick and call it correctly.

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% and each parameter is already documented, so the schema carries the load. The description still adds value by explaining that omitting `actions` audits all three and that selecting fewer actions reduces output size — a cost/verbosity tradeoff not encoded in 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?

Opens with a specific verb and resource: 'Audit which individual guild roles can view, send in, or manage one channel or thread.' It immediately bounds scope to per-role baselines and explicitly excludes member-level and multi-role rollup, which is exactly what separates it from permissions_explain.

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

Usage Guidelines5/5

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

Provides explicit 'When to use' and 'When NOT to use' sections, each with a named alternative and the condition selecting it (use permissions_explain for one member's effective access; do not use for live thread state; not for mutation). Guidance leaves nothing to inference.

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