Skip to main content
Glama
piekstra

Slack MCP Server

by piekstra

create_channel

Create a new public or private Slack channel by specifying a name and privacy setting. Simplify team collaboration with organized communication spaces directly from the Slack MCP Server.

Instructions

Create a new Slack channel.

Args: name: Name for the new channel is_private: Whether the channel should be private

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
is_privateNo
nameYes

Implementation Reference

  • The main MCP tool handler for 'create_channel'. This function is decorated with @mcp.tool(), making it the executable tool logic that creates a new Slack channel by calling the SlackClient method.
    @mcp.tool() async def create_channel(name: str, is_private: bool = False) -> str: """ Create a new Slack channel. Args: name: Name for the new channel is_private: Whether the channel should be private """ try: client = SlackClient() result = await client.create_channel(name, is_private) return json.dumps(result, indent=2) except Exception as e: return json.dumps({"error": str(e)}, indent=2)
  • Supporting method in SlackClient class that makes the actual API call to Slack's conversations.create endpoint to create the channel.
    async def create_channel(self, name: str, is_private: bool = False) -> Dict[str, Any]: """Create a new channel.""" data = {"name": name, "is_private": is_private} return await self._make_request("POST", "conversations.create", json_data=data)
  • The @mcp.tool() decorator registers this function as an MCP tool named 'create_channel' (using the function name).
    @mcp.tool()

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/piekstra/slack-mcp-server'

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