Give your agent a spend key

It finds, rents and stops GPUs on its own. One flat 5% fee, inside every rate.

1. Create an API key

Go to Account → Security. Pick the renter scope to let the agent rent. Without it, the key is read-only.

Keeping spend in check

Every rental has a hard budget cap the agent sets, and nothing is charged above it. The agent spends only your prepaid USDC or USDT balance on Base. Give the key an expiry and revoke it when you are done.

2. Connect your agent

The hosted MCP server needs no install: https://amplerun.com/api/mcp, with your key as a Bearer header.

Claude Code

claude mcp add --transport http amplerun https://amplerun.com/api/mcp \
  --header "Authorization: Bearer ark_..."

Cursor and other MCP clients (.cursor/mcp.json or your client's config)

{
  "mcpServers": {
    "amplerun": {
      "url": "https://amplerun.com/api/mcp",
      "headers": { "Authorization": "Bearer ark_..." }
    }
  }
}
What the agent can do
  • Read: list_templates, search_offers, get_quote, get_rental, list_rentals, get_balance.
  • Spend (renter scope): create_rental, stop_rental.
  • Earn: host_this_machine explains how to list the machine's GPU.
  • Sign up (no key needed): get_agent_account_challenge, register_agent_account.

Clients that only accept OAuth connectors can't connect yet. The machine-readable description is at /api/mcp/server-card (draft MCP Server Card format).

3. Or call the API

Browsing offers needs no key. The full contract is in the API reference and OpenAPI document.

curl https://amplerun.com/api/v1/offers?limit=5
TypeScript SDK example

Install it with npm i @amplerun/sdk.

import { createAmpleRun } from "@amplerun/sdk";

const ar = createAmpleRun({ apiKey: process.env.AMPLERUN_API_KEY! });
const [tpl] = (await ar.templates.list({ kind: "classical" })).items;
const { items } = await ar.offers.list({ template_id: tpl!.id }); // cheapest first
const quote = await ar.quotes.create({
  offer_id: items.find((o) => o.fit?.fits)!.offer_id,
  template_id: tpl!.id,
  duration_limit_s: 3600,
  budget_micro: "2000000", // hard cap: 2 USDC
});
const job = await ar.jobs.create({ quote_id: quote.quote_id, ssh_public_key: "ssh-ed25519 AAAA..." });

Your agent can sign itself up

No email and no person in the loop. The agent proves it controls a wallet, and that wallet becomes its account's payout wallet.

  1. It asks for a challenge for its wallet address. Signing it accepts the Terms.
  2. It signs the message with its wallet. The message works once, for five minutes.
  3. It registers with the signature, its name and its maker, and gets an API key with the renter scope, shown once. It can ask for the host scope too.
# 1. Ask for a challenge for your wallet address
curl -X POST https://amplerun.com/api/v1/agents/accounts/challenge \
  -H 'content-type: application/json' -d '{"address":"0xYourWallet"}'
# 2. Sign "message" exactly as returned (personal_sign, EIP-191)
# 3. Register: returns account_kind "agent" and an API key, shown once
curl -X POST https://amplerun.com/api/v1/agents/accounts \
  -H 'content-type: application/json' \
  -d '{"message":"...","signature":"0x...","agent":{"name":"ops-bot","vendor":"grok"}}'
Over MCP, and the rules

The hosted MCP server offers get_agent_account_challenge and register_agent_account without a key. The local server (npx @amplerun/mcp) signs for the agent when you set AMPLERUN_AGENT_WALLET_KEY; the private key stays on your machine.

There is no free credit: fund the account from its wallet before renting. The same wallet always opens the same account, and the account is marked as agent-created. A wallet linked to another account, or to a suspended one, is refused.

Earn with this machine's GPU

An agent can help you list the GPU it runs on. You approve it; nothing is listed without you.

  1. The agent asks you, then runs the installer. It needs root.
    curl -fsSL https://amplerun.com/host | sudo AMPLERUN_OUTPUT=json bash
  2. It sends you an approval link. Sign in and approve the machine.
  3. Once live, it earns from every rental. See earnings.
Installer status

Proposed: the one-line installer is still being built. Until it answers, add the machine from Earn. With AMPLERUN_OUTPUT=json it prints one JSON line per step: checks, then pairing_code and approve_url, then live.

For crawlers and agents: /llms.txt and the draft A2A agent card.