MCP server
MartLLM is an MCP server at https://api.martllm.com/mcp. An agent connected
to it can list models, price a request, make and edit images, make videos and
check your balance, without writing HTTP calls.
It is listed in the official MCP Registry
as dev.uberllm/mcp, so clients that read the registry can add it by name.
It uses the Streamable HTTP transport. Sign in with the same API key you use
for /v1, sent as Authorization: Bearer ull_.... A tool call is billed,
limited and refused exactly like the same request to the API: the same prices,
the same per-key spend limits, and failed requests cost nothing.
Prices without a key
To look up models and prices only, connect to https://api.martllm.com/mcp/public.
It needs no API key and no account. It has three read-only tools: list_models,
get_model and quote (what a request would cost). It cannot make anything or
spend money.
claude mcp add --transport http uberllm-prices https://api.martllm.com/mcp/public
Claude Code
Replace $KEY with your API key, or set KEY in your shell first:
claude mcp add --transport http uberllm https://api.martllm.com/mcp --header "Authorization: Bearer $KEY"
Add --scope user to use it in every project. Run claude mcp list to check
that it connected.
Claude Desktop
Claude Desktop connects to a remote server with a key through
mcp-remote (needs Node.js). Open
Settings → Developer → Edit Config and add:
{
"mcpServers": {
"uberllm": {
"command": "npx",
"args": ["-y", "mcp-remote", "https://api.martllm.com/mcp", "--header", "Authorization:${UBERLLM_AUTH}"],
"env": { "UBERLLM_AUTH": "Bearer ull_your_key_here" }
}
}
}
The header has no space after : on purpose: on Windows, Claude Desktop does
not quote spaces inside args. Restart Claude Desktop after saving.
Cursor and other clients
Clients that read an mcpServers file (Cursor's ~/.cursor/mcp.json, for
example) take:
{
"mcpServers": {
"uberllm": {
"url": "https://api.martllm.com/mcp",
"headers": { "Authorization": "Bearer ull_your_key_here" }
}
}
}
Tools
| Tool | What it does | Spends |
|---|---|---|
list_models |
Models you can call now, with their price. type is chat, image, video or music; search keeps models whose id or name contains the words. |
No |
get_model |
One model: its price and, for a media model, parameters, a JSON Schema of the options its requests take. |
No |
quote |
Checks an image, video, music or text-to-speech request against the model and prices it, without making anything. Returns cost_usd, the listed price, and max_cost_usd, what is held while it runs and the most it is billed. |
No |
generate_image |
Makes pictures from a prompt. Returns links and usage.cost_usd. With return_image: true the pictures also come back in the answer. |
Yes |
edit_image |
Changes the picture in image_url (or the pictures in input_images) following the prompt. Use an editing model, such as one whose id ends in -edit. |
Yes |
start_video |
Starts a video and returns a job. Send idempotency_key so a retry never starts or pays for a second video. |
Yes, when the video is made |
get_job |
A video or music job: status, progress and, once it succeeded, its file links and cost. | No |
wait_job |
Waits until a job ends, for up to timeout_seconds (50 at most). If done is false, call it again. |
No |
balance |
What you can spend now and what is held for requests and jobs still running, in US dollars. | No |
Options a model lists in its parameters schema (for example duration_seconds,
resolution or aspect_ratio) go in options on quote, generate_image,
edit_image and start_video. Send max_cost (US dollars) on a spending tool
to refuse anything that could cost more.
A video takes from about 30 seconds to several minutes. The usual flow is
get_model, quote, start_video, then wait_job until the status is
succeeded, failed, canceled or expired.
Files
Result links (/v1/media/artifacts/...) need the same API key in the
Authorization header to download. Files are kept for about 3 hours after a job
finishes; image links for about 15 minutes. See
Make a video or image for the details of each request.
Errors
When the API refuses a call, the tool answers with an error result carrying the
API's own message and code, for example insufficient_credits or
max_cost_too_low. The codes are the ones in Errors.
You can connect and list the tools without a key, so MCP directories and
inspectors can see what the server does. Every tool call needs your key: without
one it is answered 401 before any tool runs, and nothing is read or spent.
Check the connection
curl https://api.martllm.com/mcp \
-H "Authorization: Bearer $KEY" \
-H "Content-Type: application/json" \
-H "Accept: application/json, text/event-stream" \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"balance","arguments":{}}}'
It answers with your balance. Without the Authorization line it answers 401;
send "method":"tools/list" instead to see the tools without a key.