As an alternative to the standard OAuth login flow, you can now use an API key to authenticate to the mabl cloud MCP. API key auth is a good fit for agent-to-agent use cases, where access should be scoped to a single workspace rather than an individual user account.
When to use API key auth
OAuth and API key auth are both supported, and each has its own strengths:
- OAuth connects to your mabl user account, so you can access any workspace your user belongs to. Uses your mabl login, so you’ll occasionally need to re-authenticate, just like with the mabl app. Start here if you’re not sure which method to pick.
- API key authenticates the connection directly. Access is scoped to the single workspace where the key was generated and persists until the key itself is deleted or expires. Best for agent-to-agent use cases.
Both “Editor” and “Viewer” API keys are supported. We recommend an “Editor” key so all MCP tools function properly.
Try it out
- Create or retrieve an “Editor” or “Viewer” mabl API key.
- Add the following configuration to your AI client’s MCP settings, replacing
YOUR_API_KEY_HEREwith your API key:
{
"mcpServers": {
"mabl": {
"url": "https://mcp.mabl.com/mcp",
"headers": {
"x-api-key": "YOUR_API_KEY_HERE"
}
}
}
}If your configuration file is checked into version control or shared with others, reference the key from an environment variable instead of pasting it directly. For example, "x-api-key": "${MABL_API_KEY}".
In Claude Code, you can also run:
claude mcp add --transport http mabl https://mcp.mabl.com/mcp --header "x-api-key: YOUR_API_KEY_HERE"
If your AI client doesn’t support HTTP, SSE and stdio bridge transports also work with API key auth.
Learn more
- Set up the cloud MCP server - full setup instructions, including alternative transports.
- mabl MCP tools and prompts - reference of available tools and sample prompts.