Skip to main content
Glama
wowjinxy
by wowjinxy

create_category

Organize Discord channels by creating new categories to group related channels together, improving server structure and navigation.

Instructions

Create a new channel category.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYes
server_idNo
positionNo
reasonNo

Implementation Reference

  • The handler and registration for the MCP tool 'create_category', which creates a new Discord channel category using guild.create_category.
    async def create_category(
        name: str,
        server_id: str | int | None = None,
        position: int | None = None,
        reason: str | None = None,
        ctx: Context = None,
    ) -> str:  # type: ignore[override]
        """Create a new channel category."""
    
        assert ctx is not None
        bot, config = await _acquire(ctx)
        guild_id = _resolve_guild_id(config, server_id)
        guild = await _ensure_guild(bot, guild_id)
    
        kwargs: dict[str, object] = {"name": name}
        if position is not None:
            kwargs["position"] = int(position)
    
        category = await _call_discord(
            "create category",
            guild.create_category(reason=reason, **kwargs),
        )
        return f"Created category {category.name} (ID: {category.id})."

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/wowjinxy/mcp-discord'

If you have feedback or need assistance with the MCP directory API, please join our Discord server