Create
Claude Code
Connect Claude Code CLI to a Webex MCP server.
Before configuring, you'll need OAuth 2.0 credentials. See OAuth 2.0 setup instructions in the main guide.
anchorOAuth 2.0
anchorclaude mcp add-json <server-name> \
'{"type":"http","url":"<MCP_SERVER_URL>","oauth":{"clientId":"YOUR_CLIENT_ID","callbackPort":PORT}}' \
--client-secret
The --client-secret flag will prompt you to enter the client secret securely.
Claude Code uses OAuth 2.0 well-known discovery endpoints for configuration, and scopes are fetched from those discovered endpoints.
Set callbackPort to match the callback URI you registered when creating the Webex Integration. Make sure to register the callback URI in this format http://localhost:PORT/callback. The port can be any available port — it just needs to match your registered callback URI. If omitted, Claude Code picks a random available port.
Replace:
<server-name>with a descriptive name (e.g.,webex)<MCP_SERVER_URL>with the Webex MCP server endpoint URLYOUR_CLIENT_IDwith the Client ID from your Webex IntegrationPORTwith the port matching your registered redirect URI
anchorAuthenticate
anchorAfter adding the server, run /mcp inside Claude Code. The server will show as failed with not authenticated status.
- Select the server from the list
- Choose Authenticate
- A browser window will open for you to sign in and grant access
- Once authenticated, the server status will update to connected