Skip to main content
Glama
cbinsights

CB Insights MCP Server

Official
by cbinsights

ChatCBI

Query CB Insights' conversational AI to analyze business intelligence data through specific, clear questions, maintaining context across interactions.

Instructions

When using this tool, provide clear, specific queries for the best results. You can continue conversations with ChatCBI by including the chat ID from previous interaction.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
messageYes
chat_idNo

Implementation Reference

  • server.py:46-72 (handler)
    The ChatCBI tool handler, decorated with @mcp.tool, which authenticates, constructs the API request to /chatcbi endpoint, and returns the response content.
    @mcp.tool(name="ChatCBI", description="When using this tool, provide clear, specific queries for the best results. You can continue conversations with ChatCBI by including the chat ID from previous interaction.", annotations=ToolAnnotations(title="Chat with CBI", readOnlyHint=True, openWorldHint=True), structured_output=False, ) def chat_with_cbi(message: str, chat_id: Optional[str] = None) -> {}: token = get_auth_token() url = f"{API_BASE}/chatcbi" headers = { "Authorization": f"Bearer {token}", "Content-Type": "application/json" } payload = {"message": message} if chat_id: payload["chatID"] = chat_id with httpx.Client() as client: try: response = client.post(url, headers=headers, json=payload, timeout=TIMEOUT) response.raise_for_status() return response.content except Exception as e: raise Exception(e) return {}
  • Helper function to obtain authentication token from CB Insights API, used by the ChatCBI handler.
    def get_auth_token() -> str: url = f"{API_BASE}/authorize" payload = { "clientId": CLIENT_ID, "clientSecret": CLIENT_SECRET } with httpx.Client() as client: try: response = client.post(url, json=payload, timeout=30.0) response.raise_for_status() return response.json()["token"] except Exception as e: raise Exception(f"Failed to authenticate: {str(e)}")
  • server.py:46-50 (registration)
    Registration of the ChatCBI tool via @mcp.tool decorator, specifying name, description, annotations, and output settings.
    @mcp.tool(name="ChatCBI", description="When using this tool, provide clear, specific queries for the best results. You can continue conversations with ChatCBI by including the chat ID from previous interaction.", annotations=ToolAnnotations(title="Chat with CBI", readOnlyHint=True, openWorldHint=True), structured_output=False, )
  • Function signature defining input schema: message (str, required), chat_id (Optional[str]), output as dict.
    def chat_with_cbi(message: str, chat_id: Optional[str] = None) -> {}:
Install Server

Other Tools

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/cbinsights/cbi-mcp-server'

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