API Locker exposes a full Model Context Protocol (MCP) server. Any MCP-compatible client — Claude (web), Claude Code, Claude Desktop, Cursor, Zed, Continue, Cline — can list your credentials, reveal values, run health checks, and proxy API calls, all with one connection.
Pick the one that fits your AI client:
apilocker CLI, run apilocker register once, then point your client at apilocker mcp. Covered further down this page.API Locker is a compliant OAuth 2.1 remote MCP server. When Claude's Connectors Directory supports API Locker, users can add it in three clicks:
After approval, Claude has full access to your vault through the same 21 tools listed below. Claude shows a safety label on every tool call (read vs. write vs. external request) before executing. You can revoke the connection at any time from your dashboard.
Is API Locker in the directory yet? Submission is in progress with Anthropic. Until it's listed, you can still add API Locker manually by pasting this URL into Claude's Add custom connector flow: https://api.apilocker.app/v1/mcp — Claude will handle the OAuth handshake and consent screen automatically.
npm install -g apilocker
Requires Node 18+. Works on macOS, Linux, Windows.
apilocker register
Opens your browser, you click Authorize once, done. The CLI stores a per-device master token in ~/.apilocker/config.json (mode 0600). The MCP bridge picks it up automatically — you never paste a token into your AI client's config.
Pick your tool. Every flow uses the same apilocker mcp stdio bridge; only the config shape differs.
This is the fastest path. Claude Code ships with a built-in MCP add command:
claude mcp add apilocker -- apilocker mcp
That's the entire install. Verify with claude mcp list — you should see apilocker: apilocker mcp - ✓ Connected. The server is available in your next Claude Code session automatically.
Paste this into your config file and restart the app.
Config location:
~/Library/Application Support/Claude/claude_desktop_config.json%APPDATA%\Claude\claude_desktop_config.json~/.config/Claude/claude_desktop_config.json{
"mcpServers": {
"apilocker": {
"command": "apilocker",
"args": ["mcp"]
}
}
}
Open Cursor Settings → Features → Model Context Protocol, click Add Server, and paste the same config as Claude Desktop. Restart Cursor after saving.
Open your Zed settings.json and add a context_servers entry:
{
"context_servers": {
"apilocker": {
"command": {
"path": "apilocker",
"args": ["mcp"],
"env": {}
}
}
}
}
Edit ~/.continue/config.json and add an mcpServers entry (same shape as Claude Desktop).
Every vault operation is exposed as an MCP tool. Your agent can do anything the CLI can do:
Once API Locker is connected, your AI agent can handle credential-related tasks in plain English. Here are three concrete flows, each showing the kinds of prompts that work well and which MCP tools get called under the hood:
What you ask Claude:
"Take a look at my API Locker vault. Which keys haven't been rotated in over 90 days, and are any of my scoped tokens close to expiring?"
What Claude does:
list_keys to enumerate every credential you have storedrun_doctor to get the built-in health report (stale rotations, unused keys, expiring tokens, local config permission checks)list_tokens to see which scoped tokens exist and their rotation cadenceweb-app-prod token expires in 3 days unless refreshed."All three tools are read-only — no state changes, nothing consumed, nothing charged. This is the safest entry point for a new connection.
What you ask Claude:
"I just got an alert that my Stripe live key might be compromised. Generate a new one, store it in the vault, and tell me what to paste into the Stripe dashboard."
What Claude does:
get_key_metadata to confirm the credential alias (STRIPE_SECRET_KEY) and its current provider + rotation historyrotate_key to replace the encrypted blob in the vault and stamp rotated_atget_activity to confirm the rotation event was audit-loggedSTRIPE_SECRET_KEY keep working automatically — no app-code changes neededThe rotate_key tool carries destructiveHint: true, so Claude will show a confirmation UI before executing. Your existing Stripe API client code continues to work against the proxied endpoint immediately.
What you ask Claude:
"Use my OpenAI key in API Locker to call gpt-4.1-mini with the prompt 'Write a haiku about vault security.' Don't show me the raw key."
What Claude does:
list_keys filtered by category: "llm" to find the OpenAI credential's key_idproxy_request with key_id + path: "/v1/chat/completions" + the request body — API Locker's proxy handler injects the raw key into the outbound call server-side, forwards to OpenAI, and returns the responseAt no point did Claude see your OpenAI API key. The proxy_request tool carries openWorldHint: true and destructiveHint: true because it makes an outbound call that can affect billing or state on the target service. Every call is audit-logged with the source IP, latency, and response status.
API Locker's MCP server handles sensitive data. Here's exactly what we do and don't store:
reveal_key call, an authenticated proxy_request call, or the Worker's own OAuth sign-in flow reading its own credentials from the vault. Plaintext is never logged, cached, or persisted outside of encrypted storage.proxy_request: forwarded to the target upstream API unchanged. We do not log, store, or retain request bodies or responses — only metadata (timestamp, target host, status code, latency, response size).{user_id, timestamp, source_ip, country, status_code, latency_ms}. Logs are retained indefinitely for the user's own visibility (GET /v1/activity, apilocker activity) and are never shared externally.See our full Privacy Policy for the formal version.
The MCP bridge reads your master token from ~/.apilocker/config.json. This gives the connected MCP client full vault access — the same permissions you have at the CLI. Only connect MCP clients you own and trust completely (Claude Desktop on your own laptop, your own Cursor instance, etc.).
For more restricted scenarios, use the scoped-token auth path: pass a scoped token in the Authorization header when calling the MCP server directly over HTTP. Scoped tokens can only call read tools (list_keys, reveal_key, proxy_request, etc.) and only for credentials in their pre-approved allowed_keys list. Write tools (store_key, rotate_key, delete_key, device/token management) are rejected for scoped tokens.
For remote MCP connections (OAuth 2.1), scopes are enforced at the token level: vault:read is required for any MCP call, vault:write is additionally required for tools that modify vault state, and vault:proxy is required for proxy_request. Refresh tokens rotate on use and reuse is treated as token theft (the entire grant family is revoked immediately).
Questions, bug reports, feedback, and security disclosures all have a home:
Want visual confirmation? The dashboard's MCP panel shows the server status, a test-connection button, and a live feed of recent MCP activity. Check there after connecting a client to verify everything's working.
apilocker mcp runs as a subprocess of your MCP client, speaking the MCP stdio transport: line-delimited JSON-RPC over stdin/stdout. Every message from the client gets forwarded to the HTTPS backend at https://api.apilocker.app/v1/mcp with your master token as the Authorization header. The backend's response is written back to the client's stdout as a single line.
Startup banners are written to stderr (never stdout) so the protocol stream stays clean. If you want to see what the bridge is doing, run apilocker mcp directly in a terminal — you'll see the startup message, and any messages you paste on stdin will be forwarded.
apilocker is in your PATH (which apilocker from the shell).apilocker register first.