Give your AI agent access to GPU compute
CloudGPU lets an AI agent find a GPU, see what it costs, and run work on it within a budget you set. Discovery and quotes need no account. Running anything needs an API key, and CloudGPU’s servers enforce the budget and time limit, so a GPU still shuts down if the agent’s session ends. You can give an agent its own key with a spending limit through a connect link, without copying a key into it.
Agent docs · MCP server · OpenAPI · Live prices
How it works
| Step | What the agent calls | Needs a key? |
|---|---|---|
| Discover | GET /v1/public/gpu-catalog: GPU models, VRAM, live price per GPU-hour, availability, billing rules, system disk options, templates |
No |
| Quote | POST /v1/quotes with VRAM, GPU count, template, duration and budget: candidates sorted by estimated cost |
No (send a key to also see whether your balance can start each one) |
| Connect | POST /v1/agent/connect: the account owner opens a link and approves the agent with a spending limit |
No (this is how the agent gets one) |
| Run a job | POST /v1/jobs with a command, max_minutes, max_spend_usd and an Idempotency-Key: CloudGPU starts a GPU, runs the command and destroys the GPU |
Yes |
| Or rent | POST /v1/gpu/instances, then SSH or the MCP server’s upload, run_command and download tools, then POST /v1/gpu/instances/{id}/destroy |
Yes |
What exists today
- Public GPU catalog at
https://cloudgpu.app/v1/public/gpu-catalog, JSON, withgenerated_atandcache_ttl_seconds. It uses the same prices as the website. - Quote API at
POST https://cloudgpu.app/v1/quotes. Each candidate hasestimated_total_cost(what the task is expected to use) andrequired_starting_balance(what your balance needs to start it). These differ because one hour is pre-authorised at start. Quotes are estimates and expire after 5 minutes. - Jobs API at
/v1/jobs: one command, run start to finish on CloudGPU’s servers. Retrying with the sameIdempotency-Keyreturns the same job and never starts a second GPU. Each job has a status, an event history, its exit code, the last part of its output and its cost. - Agent connect: an agent asks for a key with
POST /v1/agent/connect; you open the link, sign in, check the agent’s name and limits, and approve. The key has a total spending limit, a number of GPUs it may run at once and an expiry date. Revoke it on the API page and it can no longer start anything. - GPU instances API under
/v1/gpu/: list offers and templates, start an instance with server-enforced limits (max_minutes,max_spend_usd,idle_minutes), an optional startup script and an optional larger system disk, read its status and SSH details, destroy it. - MCP server:
npx -y cloudgpu-mcp, for Cursor, Cline, Claude Code, opencode and other MCP clients. It runs on your computer and drives the same API, jobs and connect links included (guide). - Model API: the same key works for the OpenAI-compatible model API at
https://cloudgpu.app/v1(docs).
A job’s GPU is destroyed when the job ends, and its disk is erased. The command must upload its own results, for example to your own storage, or print them. CloudGPU does not keep files.
Billing and limits
Per minute, rounded up, with a 1-minute minimum. One hour is pre-authorised while an instance runs, and unused minutes go back to your balance when you destroy the instance. There is no subscription and no minimum term.
Billing comes from a prepaid USD balance. Every job needs a time limit and a spend limit, and every instance started through the API can carry them; CloudGPU’s servers enforce both. A key from a connect link also has a total spending limit and a cap on how many jobs or instances it runs at once.
Example: quote, then run a job
# 1. What would 30 minutes on a 24 GB card cost? (no key needed)
curl -s https://cloudgpu.app/v1/quotes \
-H 'Content-Type: application/json' \
-d '{"requirements":{"min_vram_gb":24},"estimated_duration_seconds":1800,"max_budget_usd":"1.00"}'
# 2. Run a job on the first candidate with a hard time and spend limit
curl -s https://cloudgpu.app/v1/jobs \
-H "Authorization: Bearer $CLOUDGPU_API_KEY" -H 'Content-Type: application/json' \
-H "Idempotency-Key: $(uuidgen)" \
-d '{"quote_id":"quote_...","command":"python train.py && rclone copy out/ mystorage:run1","max_minutes":40,"max_spend_usd":1.00}'
# 3. Check it
curl -s https://cloudgpu.app/v1/jobs/job_... -H "Authorization: Bearer $CLOUDGPU_API_KEY"
If the quote has expired, the GPU is no longer available, its price went up or the configuration differs from the quote, step 2 returns an error and starts nothing. If step 2 times out, send it again with the same Idempotency-Key.
FAQ
How do I give an agent a key without giving it my whole account?
Let the agent call POST /v1/agent/connect (the MCP server’s connect_account tool does this). You get a link; sign in, check the agent’s name, the spending limit and how many GPUs it may run at once, lower them if you like, and approve. The agent receives its own key. CloudGPU’s servers refuse anything over those limits, and you can revoke the key on the API page at any time.
What if the agent sends the same job twice?
Jobs need an Idempotency-Key. The same key with the same request returns the job that already exists, so a retry after a timeout never starts a second GPU. The same key with different parameters is refused.
Does an agent need an account to see prices?
No. The GPU catalog and the quote API are public. An API key is only needed to start an instance, and with a key the quote also says whether your balance can start each candidate.
How do I stop an agent from overspending?
Set max_minutes and max_spend_usd when the agent starts an instance. CloudGPU’s servers destroy the instance when either is reached, even if the agent’s session has ended. The MCP server also takes a per-session spend cap.
Why is the balance needed to start higher than the quote?
One hour is pre-authorised while an instance runs. A 30-minute task may be quoted below the hourly price, but your balance must cover the hour to start it. Unused minutes go back to your balance when you destroy the instance.
Which agents can use CloudGPU?
Any agent that can make HTTPS requests can use the REST API. MCP clients such as Cursor, Cline, Claude Code and opencode can use the MCP server.
Does CloudGPU keep my files after the instance is destroyed?
No. Destroying an instance, or the end of a job, erases the disk. Copy results off first, or have the job’s command upload them.
Prices are on https://cloudgpu.app/pricing and in the public catalog, and are not repeated here.