Connect MCP with Claude Code
Configure the B6AI MCP server so Claude Code can build and manage your bots in natural language.
Overview
B6AI ships a hosted Model Context Protocol server, `b6ai-bot-builder`, that lets an AI client build and manage your bots (intents, utterances, knowledge and flows) from natural-language instructions. Once Claude Code is connected, you can ask it to "create a support bot that handles order status and refunds" and it authors a complete bot in your workspace.
The server speaks MCP over HTTP and authenticates every request with your workspace identity, so Claude Code only ever sees what your role is allowed to see.
Prerequisites
- A B6AI workspace with the MCP server enabled on your plan.
- The Claude Code application installed and updated to a version that supports remote MCP servers.
- Your B6AI MCP endpoint (https://mcp.b6ai.ai/mcp) and a way to sign in, the server authorizes you through B6AI’s identity provider (Keycloak / OAuth 2.0).
- The OAuth client ID `b6ai-mcp`. B6AI does not allow clients to register themselves, so Claude Code cannot obtain this automatically.
Get your B6AI MCP endpoint
The MCP endpoint is workspace-specific. Copy it from your workspace, or ask your administrator for it. Authentication uses OAuth 2.0 against B6AI’s identity provider, the client opens a sign-in window the first time it connects, so you do not paste long-lived secrets into config files where the client supports OAuth.
https://mcp.b6ai.ai/mcpUse the B6AI OAuth client ID
Most MCP clients try to register themselves with the authorization server the first time they connect (dynamic client registration). B6AI switches that off on purpose, because anything that can reach the identity provider could otherwise create its own OAuth client. Instead, B6AI publishes one pre-approved client that every user shares.
When Claude Code asks for an OAuth client ID, enter the value below. Leave it blank and registration fails before you ever reach the sign-in page.
b6ai-mcpAdd the server to Claude Code
Add the B6AI MCP server to Claude Code using the configuration below, then restart the client so it loads the new server.
claude mcp add --transport http b6ai https://mcp.b6ai.ai/mcpVerify the connection
Claude Code lists MCP servers with `claude mcp list` and shows their tools with `/mcp` inside a session.
- Open the tools / connectors list in Claude Code and confirm `b6ai-bot-builder` appears as connected.
- Ask Claude Code to list your bots, or to describe what it can do with B6AI.
- Ask it to create a simple test bot, then open Bot Builder in B6AI to confirm the bot was created.
Troubleshooting
| Symptom | Likely cause | Resolution |
|---|---|---|
| Could not register with B6AI’s sign-in service | No OAuth client ID supplied; B6AI does not allow self-registration | Enter `b6ai-mcp` as the OAuth client ID in Claude Code, then connect again. |
| Server not listed | Config not loaded | Check the config path and fully restart Claude Code. |
| Sign-in loop / 401 | Auth not completed or token expired | Re-run the sign-in flow, or regenerate the token and update the header. |
| No bots returned | Account has no bots or lacks permission | Confirm your B6AI role can build bots and that the workspace has at least one bot. |
| Tool calls rejected | Endpoint or transport mismatch | Confirm the URL ends in `/mcp` and matches the transport Claude Code expects. |