Skip to main content
Glama
piekstra

Slack MCP Server

by piekstra

get_channel_info

Retrieve detailed information about a specific Slack channel using its unique ID to manage and analyze channel data efficiently within the Slack MCP Server.

Instructions

Get detailed information about a specific Slack channel.

Args: channel_id: The ID of the channel

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
channel_idYes

Implementation Reference

  • The primary MCP tool handler for 'get_channel_info', registered with @mcp.tool(). It creates a SlackClient instance, calls its get_channel_info method with the provided channel_id, and returns the result as formatted JSON or an error.
    async def get_channel_info(channel_id: str) -> str: """ Get detailed information about a specific Slack channel. Args: channel_id: The ID of the channel """ try: client = SlackClient() result = await client.get_channel_info(channel_id) return json.dumps(result, indent=2) except Exception as e: return json.dumps({"error": str(e)}, indent=2)
  • Supporting helper method in the SlackClient class that performs the actual Slack API call to retrieve channel information using the 'conversations.info' endpoint.
    async def get_channel_info(self, channel_id: str) -> Dict[str, Any]: """Get detailed information about a specific channel.""" params = {"channel": channel_id} return await self._make_request("GET", "conversations.info", params=params)

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