Skip to main content
Veri speaks the Model Context Protocol, so MCP clients such as Claude Code, Claude Desktop, and Cursor can inspect deployment metrics and request failures, query bounded training metrics, check account burn, and—when writes are enabled—submit, cancel, or clean up runs on your behalf. There are two ways to connect, with the same tools either way:
  • Hosted endpoint (recommended): https://api.veri.studio/mcp — nothing to install, authenticated with your API key.
  • Local server: veri mcp serve runs as a subprocess of your MCP client and uses your veri login credentials. Use it if you prefer not to place an API key in client config.

Hosted endpoint

Connect with your Veri API key as a bearer header (create one from the dashboard’s API keys page). Every call acts as that key’s owner — the same permissions you have from the CLI, nothing more. Claude Code: put the key in your shell’s environment first, then register the endpoint:
Your shell substitutes the key when you run claude mcp add, and Claude Code stores it in its own config. Do not add -s project to this command: that writes the key into a .mcp.json that is usually committed. Cursor takes a URL entry under mcpServers in ~/.cursor/mcp.json (or .cursor/mcp.json in a project). Reference the key as ${env:VERI_API_KEY} rather than pasting it: .cursor/mcp.json is often committed, and Cursor fills the value in from its environment.
Claude Desktop only launches local servers from claude_desktop_config.json (command and args, no url entries), so use the local server there. For an unattended agent, use https://api.veri.studio/readonly/mcp instead: the write and delete tools are not registered at all on that path (see Read-only mode). Verify with /mcp inside a Claude Code session, or ask the agent “what is my Veri credit balance?”

Local server setup

The local server runs on your own machine: your MCP client starts it as a subprocess and talks to it over stdin/stdout, so there is no port to open and no API key in client config — it authenticates with your stored veri login credentials.
1

Install the SDK with the mcp extra

The MCP server ships with the SDK behind an optional mcp extra. Run this even if veri is already installed: these flags upgrade an existing install and add the extra, which uv tool upgrade and pipx upgrade never do.
A uv tool or pipx install keeps only the extras named on the latest install: installing 'veri-sdk[attach]' alone removes mcp. Name every extra you use in one install, or take them all with 'veri-sdk[all]' (mcp, attach, yaml, tui). veri doctor reports a failing mcp extra row when veri mcp serve cannot start.
2

Log in

The server reads your stored credentials, so log in once:
You never paste an API key into the MCP client. The server uses the credentials from veri login (or the VERI_API_KEY environment variable if you set one).
3

Check that the server starts

MCP clients do not show the server’s error output: when veri mcp serve cannot start, Claude Code reports only Failed to connect and Connection closed. Start it once yourself so you can see the reason:
It exits with no output when it can start. If it prints an error instead, fix that first: a missing mcp extra means re-running the install line from the first step, and Not logged in means running veri login.
4

Register Veri in your client

Add Veri to your MCP client. The command the client runs is always veri mcp serve.Claude Code has a one-liner. The part after -- is the command it will spawn:
By default this registers Veri for you in the current project. Use -s user to make it available in every project, or -s project to write a .mcp.json that your whole team shares (each teammate still runs their own veri login).Claude Desktop and Cursor are configured with a JSON file. Add a veri entry under mcpServers:
The file location depends on the client:If the client reports that it cannot find veri (desktop apps often start without your shell’s PATH), set "command" to the absolute path that which veri prints.
5

Restart and verify

Restart the client so it picks up the new server.In Claude Code, run claude mcp list (or /mcp inside a session) and confirm the veri line ends in ✔ Connected. In Claude Desktop and Cursor, the Veri tools appear once the server connects. Ask the agent something like “what is my Veri credit balance?” to confirm it can reach your account.

Read-only mode

By default every tool is available, including ones that create billable GPU jobs and deployments. Your MCP client prompts you to approve each tool call, so creation is gated by that approval. Tools that spend credits have descriptions that begin with CREATES A BILLABLE ... so the intent is clear in the approval prompt. For an automated or unattended setup where no human approves each call, run the server read-only so the 12 write and delete tools (every tool in the write and delete tables below) are not registered at all. Pass --readonly in the command:
Setting the environment variable VERI_MCP_READONLY=1 has the same effect. On the hosted endpoint, use the /readonly/mcp path instead:

Available tools

Read tools (always available)

Arguments without a default are required. limit values are capped at the maximum shown.

Write tools (available unless read-only)

Delete tools (available unless read-only)

Deletes are irreversible and, unlike provisioning, cost nothing, so your MCP client’s approval prompt is the only safeguard. Every description below starts with PERMANENTLY DELETES so the stakes are visible in that prompt. Use read-only mode for any unattended agent. Each returns {"deleted": true, "id": ..., "object": ...}. Job logs, lifecycle webhooks, Prometheus metrics export, and per-replica drain have no MCP tools today. Read logs with veri jobs logs <id> and reach the rest over REST; see the API reference. Creating evaluators and running local code evaluators happen in the veri CLI (veri evaluators create, veri experiments run --local): an experiment that pins a local code evaluator waits in awaiting_local until those scores arrive.

Test deployment observability with MCP

MCP is optional for deployment observability—the dashboard, SDK, and REST API expose the same underlying telemetry. MCP is the agent-facing interface for investigating that telemetry in natural language. For a safe test, register the server in read-only mode:
Send a buffered and a streaming request to a serving deployment, then ask:
Inspect deployment <deployment-id> over the past hour. Report request volume, p50/p95/p99 TTFT and end-to-end latency, token throughput, error rate, and cost efficiency. List failed requests grouped by error category. Do not modify resources.
The agent should use:
  1. veri_get_deployment_metrics for compact lifetime health and cost context.
  2. veri_query_deployment_metrics for server-aggregated time-series buckets.
  3. veri_list_deployment_requests for the terminal records behind errors.
Time-series queries return at most 500 buckets, and request-history queries return at most 50 rows per call. Pass an explicit deployment ID and time window when you want repeatable results.

Deployment observability smoke test

Generate buffered and streaming traffic, verify dashboard charts, test SDK and REST queries, and interpret every metric.

Self-hosting the HTTP server

veri mcp serve-http is the multi-tenant streamable HTTP server behind the hosted https://api.veri.studio/mcp endpoint. You can also run it yourself, for example on an internal host shared by a team of agents:
The HTTP server does not use your local veri login credentials. Every request must carry your Veri API key as a bearer token, and each call acts as that key’s owner. The server speaks plain HTTP (no TLS), so connect with an http:// URL. Bearer keys travel in every request: beyond a trusted network, put a TLS-terminating proxy in front of it and use the proxy’s https:// URL instead.
Two endpoints are served: The transport is stateless, so the service scales horizontally behind a plain load balancer, and GET /healthz is an unauthenticated liveness probe. Requests are forwarded to the Veri API with the caller’s own key — the server holds no credentials of its own. Point it at a different control plane with --upstream-url or VERI_MCP_UPSTREAM_URL.

Training analysis with W&B

Use Veri MCP for infrastructure, lifecycle, deployment telemetry, and billing. Connect the official W&B MCP alongside it for rich cross-run training analysis, artifacts, and reports. veri_get_training_metrics returns a bounded native metric series, and veri_get_training_job returns the run’s wandb_run_url when the job logged to W&B. Veri does not proxy W&B credentials or reimplement W&B’s query surface.

Working with datasets and rewards

The server does not upload local files. Upload your dataset with the CLI first, then pass its id to the agent:
Rewards need no upload step: veri_create_training_job takes a reward_source parameter carrying the reward function’s Python source text, so the agent passes the code inline when it creates the job.

Harness-in-the-loop RL jobs

Harness RL jobs (method grpo_harness, where your own agent, built on the OpenAI SDK, LangChain, or the Anthropic SDK, drives the GRPO rollouts unmodified) are regular training jobs to MCP: they appear in veri_list_training_jobs, veri_get_training_job and veri_get_training_metrics like any other run (read their logs with veri jobs logs <id> and their setup and checkpoint events with veri jobs events <id>). Submission is CLI-only today (veri run-harness, because the harness code directory is uploaded with the job; veri_create_training_job does not accept this method), and the per-rollout trajectory archive lives on the job’s dashboard page. When a user asks their agent how to RL-train the model behind an existing agent or harness, the setup is small enough to explain conversationally: the agent keeps its normal loop and reads OPENAI_BASE_URL / ANTHROPIC_BASE_URL (pointed at the in-training policy per rollout) plus the task from VERI_TASK_INPUT; a TRL-signature reward function (attached to the job inline) scores each finished trajectory. The full contract and a worked demo: Harness-in-the-loop RL and the URL-extraction agent demo.