Client Configuration
/v1/mcp/:model_name/configGenerates a ready-to-paste configuration snippet for connecting an MCP-compatible IDE or CLI to a specific MCP server through SandBase. Pass the client query parameter to get the correct JSON format for your tool.
Authentication
| Header | Required | Description |
|---|---|---|
Authorization | Yes | Bearer <API_KEY> — Your SandBase API key. The key is embedded into the generated config so the IDE can authenticate automatically. |
Path Parameters
| Parameter | Type | Description |
|---|---|---|
model_name | string | Required. The MCP server identifier (e.g. exa/exa, browserbase/browserbase). Use the List Servers endpoint to discover available names. |
Query Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
client | string | claude | Target IDE/CLI. One of: claude, claude-code, cursor, vscode, codex, opencode. |
Supported Clients
| Value | IDE / CLI | Config File |
|---|---|---|
claude | Claude Desktop | claude_desktop_config.json |
claude-code | Claude Code (CLI) | .mcp.json |
cursor | Cursor | .cursor/mcp.json |
vscode | VS Code / Copilot | .vscode/mcp.json |
codex | OpenAI Codex CLI | CLI config |
opencode | OpenCode | opencode.json |
Response
Returns a JSON object formatted for the requested client. The response contains the server URL and authentication headers pre-filled with your API key.
TIP
The response is not wrapped in the standard { "code": 0, "data": ... } envelope — it returns the raw configuration JSON so you can paste it directly into your config file.
Example Request
# Get config for Claude Desktop
curl "https://api.sandbase.ai/v1/mcp/exa/exa/config?client=claude" \
-H "Authorization: Bearer sb-your-api-key"
# Get config for VS Code
curl "https://api.sandbase.ai/v1/mcp/exa/exa/config?client=vscode" \
-H "Authorization: Bearer sb-your-api-key"
# Get config for Cursor
curl "https://api.sandbase.ai/v1/mcp/browserbase/browserbase/config?client=cursor" \
-H "Authorization: Bearer sb-your-api-key"Example Responses
Claude Desktop / Claude Code / Cursor
All three use the same mcpServers format:
{
"mcpServers": {
"Exa Search": {
"url": "https://mcp.sandbase.ai/exa/exa/sse",
"headers": {
"Authorization": "Bearer sb-your-api-key"
}
}
}
}VS Code
VS Code uses a servers key with an explicit type field:
{
"servers": {
"Exa Search": {
"type": "sse",
"url": "https://mcp.sandbase.ai/exa/exa/sse",
"headers": {
"Authorization": "Bearer sb-your-api-key"
}
}
}
}Codex CLI
Codex uses an mcp_servers array:
{
"mcp_servers": [
{
"name": "Exa Search",
"url": "https://mcp.sandbase.ai/exa/exa/sse",
"headers": {
"Authorization": "Bearer sb-your-api-key"
}
}
]
}OpenCode
{
"mcpServers": {
"Exa Search": {
"url": "https://mcp.sandbase.ai/exa/exa/sse",
"headers": {
"Authorization": "Bearer sb-your-api-key"
}
}
}
}Using the Generated Config
Claude Desktop
- Open Settings → Developer → Edit Config
- Paste the response into
claude_desktop_config.json - Restart Claude Desktop
~/Library/Application Support/Claude/claude_desktop_config.json # macOS
%APPDATA%\Claude\claude_desktop_config.json # WindowsClaude Code (CLI)
Add the config to .mcp.json in your project root or home directory:
# Project-level
echo '<paste response>' > .mcp.json
# Or global
echo '<paste response>' > ~/.mcp.jsonCursor
- Create
.cursor/mcp.jsonin your project root - Paste the response
- Restart Cursor or reload the window
your-project/.cursor/mcp.jsonVS Code
- Create
.vscode/mcp.jsonin your workspace - Paste the response
- Reload the window (
Ctrl+Shift+P→ "Reload Window")
your-project/.vscode/mcp.jsonCodex CLI
Pass the config via the --mcp-config flag or add it to your Codex configuration file:
codex --mcp-config mcp.jsonOpenCode
Add the config to opencode.json in your project root:
your-project/opencode.jsonCombining Multiple Servers
You can merge configs from multiple calls. Each response uses the server's display name as the key, so merging is straightforward:
{
"mcpServers": {
"Exa Search": {
"url": "https://mcp.sandbase.ai/exa/exa/sse",
"headers": { "Authorization": "Bearer sb-your-api-key" }
},
"Browserbase": {
"url": "https://mcp.sandbase.ai/browserbase/browserbase/sse",
"headers": { "Authorization": "Bearer sb-your-api-key" }
}
}
}Error Responses
| Status | Error Code | Description |
|---|---|---|
| 400 | invalid_request | Missing model_name path parameter |
| 401 | unauthorized | Missing or invalid API key |
| 404 | not_found | MCP server not found or not of type mcp |
Error Example
{
"error": "not_found",
"message": "MCP server not found: invalid/server-name"
}Related
- List MCP Servers — Discover available MCP servers
- List Tools for a Server — Get available tools for a specific server
- SSE Proxy — Connect to an MCP server via SSE
- MCP Tools Overview — API overview and authentication

