MCP Server
LLM API runs a Model Context Protocol server at
https://api.llmapi.ai/mcp. Connect a coding agent with a personal MCP token and it can do
what the dashboard does — check usage and failed requests, manage projects, API keys, IAM rules,
guardrails, prompts and team members — as you, and only inside one organization.
Create a token
- In the dashboard open Settings → MCP Access.
- Click Create token, name it, and choose:
- Access — Read only, Read and write, or Full access. See
access levels below.
- Project — the whole organization, or one project. A project token cannot use
organization-wide actions.
- Expiry — 7, 30 or 90 days.
- Copy the token. It is shown only once.
Access levels
Each level includes everything in the levels before it. Pick the lowest one that covers what
you want the agent to do.
| Level |
Adds |
Who can create it |
| Read only |
Usage, spend and request logs; projects, API keys, BYOK keys, IAM rules and guardrails (never key secrets); prompts, eval suites, members, the audit log, invoices and transactions |
Any member |
| Read and write |
Create and edit projects; create API keys that expire within 24 hours; change API key limits and IAM rules, and delete API keys; create, edit, test and delete guardrails; prompts, eval suites and eval runs; balance and pay-as-you-go usage alerts |
Any member |
| Full access |
Everything with API keys: any expiry, changing an expiry, regenerating and rotating; add, replace and delete BYOK provider keys; invite and remove members and change roles; organization settings except payment settings, domains, observability exports and client organizations |
Owners and admins |
The access level and your role both apply, and the stricter one wins. A developer with a
Read and write token can still do only what a developer can do in the dashboard. If an owner
or admin is demoted to developer, their Full access tokens keep working as Read and write.
A project token sees and changes only its project. Organization-wide actions — members,
billing, domains, observability and organization settings — are refused.
When the token blocks a call, the agent receives a 403 with one of these codes, so it can tell
you what is missing:
| Code |
Meaning |
MCP_TOKEN_READ_ONLY |
The call changes something and the token is Read only. |
MCP_TOKEN_FULL_ACCESS_REQUIRED |
The call needs a Full access token. |
MCP_TOKEN_PROJECT_SCOPED |
The call spans the organization and the token is limited to one project. |
MCP_ROUTE_DENIED |
The action is never available through MCP, such as a payment or a payment setting. |
MCP_ACCESS_DISABLED |
An owner turned MCP access off for the organization. |
MCP_NOT_MEMBER |
The token's owner no longer belongs to the organization. |
A 403 without one of these codes means your role does not allow the action. A 404 also covers
resources of other organizations and other projects.
Connect your agent
# Claude Code
claude mcp add --transport http llmapi https://api.llmapi.ai/mcp \
--header "Authorization: Bearer llmapi_umcp_..."
// Cursor: ~/.cursor/mcp.json
{
"mcpServers": {
"llmapi": {
"url": "https://api.llmapi.ai/mcp",
"headers": { "Authorization": "Bearer llmapi_umcp_..." }
}
}
}
Then ask the agent to run whoami. It reports the organization the token is limited to, your
role, and the token's access and expiry.
What the agent can and cannot do
- Every action runs with your role: a developer's token cannot do what a developer cannot
do in the dashboard.
- The token works only in its organization. Resources of other organizations you belong
to are not visible to it.
- Not available through MCP: payments, top-ups, subscriptions, vouchers and a key's extra usage; your
password, sessions and two-factor settings; creating or deleting organizations and deleting
projects; the playground; creating MCP tokens.
- API keys a Read and write token creates expire within 24 hours (one hour by default),
because the agent has seen the secret, and such a token cannot change a key's expiry. A
Full access token manages keys as you do in the dashboard. The agent still sees every new
secret, so prefer Read and write unless the agent must create long-lived keys.
- BYOK provider keys can be added by an agent but are never shown back.
WARNING
Request logs contain prompts and completions written by your users. They are returned only when
the agent asks for them, and they are marked as third-party content. Treat what a log says as
data, never as instructions to your agent.
Stay in control
- Every call an agent makes is in Settings → Audit logs, marked MCP with the tool and
client that made it.
- Revoke a token on Settings → MCP Access at any time. Owners and admins can revoke any
member's token; owners can turn MCP access off for the whole organization.
- Removing a member or changing their role takes effect on their tokens immediately.
- Each token is limited to 300 requests per minute, and the organization to 1,200.
Context usage
The server exposes eight tools (seven for a Read only token) rather than one tool per
endpoint. The agent searches the operation catalog and reads one operation's parameters only
when it needs them. Connecting costs about 2,000–3,000 tokens of the agent's context: server
instructions and tool definitions. Each search returns about 400–800 tokens and each operation
description about 1,500. Ask the agent to request only the fields it needs to keep large
responses small.