# Deploy a VPS in one HTTP request
$ curl -X POST https://spawn.prim.sh/v1/instances \
-H "X-402-Payment: $PAYMENT_TOKEN" \
-d '{"image": "ubuntu-24.04", "plan": "s-1vcpu-1gb"}'
# Response (402 → pay → 201)
{
"id": "inst_k7x9m2",
"ipv4": "198.51.100.1",
"ssh_key": "ssh-ed25519 AAAA...",
"status": "provisioning",
"ready_at": "~45s"
}
No account. No API key. No dashboard. Just pay and compute.
Standard HTTP. Create, list, resize, snapshot, destroy instances. x402 payment on every mutating request. JSON in, JSON out.
Model Context Protocol tools. Any MCP-compatible agent can spawn infrastructure as naturally as calling a function. spawn_instance, exec_command, destroy_instance.
Drop-in replacement for tool-use schemas. Works with any agent framework that speaks the OpenAI function calling spec.
# MCP — agent spawns its own infrastructure
tools:
spawn_instance:
image: "ubuntu-24.04"
plan: "s-2vcpu-4gb"
ssh_keys: ["ssh-ed25519 AAAA..."]
user_data: "#!/bin/bash\napt install -y python3..."
exec_command:
instance: "inst_k7x9m2"
command: "python3 train_model.py --epochs 100"
destroy_instance:
instance: "inst_k7x9m2"
An agent spins up a VPS, installs itself, runs a task, tears it down. No human in the loop.
Need 50 workers? Spawn 50 instances. Fan out, collect results, destroy. Pay per second.
Ship a web app, database, or API endpoint. Get a public IP. No Heroku, no Vercel, no YAML.
Run untrusted code in disposable VMs. Each instance is a fresh machine with its own IP and filesystem.
Agent A deploys Agent B on a new VPS. Agent B deploys a database. Recursive infrastructure.
No account, no email, no identity. x402 payment is the only credential. Agents don't have passports.
# All endpoints. That's it.
POST /v1/instances # Create instance
GET /v1/instances # List instances (by payment identity)
GET /v1/instances/:id # Get instance details
POST /v1/instances/:id/exec # Execute command via SSH
PUT /v1/instances/:id # Resize / modify
DELETE /v1/instances/:id # Destroy instance
POST /v1/instances/:id/snap # Create snapshot
GET /v1/snapshots # List snapshots
GET /v1/plans # Available plans + pricing
GET /v1/images # Available OS images
GET /v1/regions # Available regions
# Auth: every mutating request returns 402 first.
# Pay via Lightning, Base L2, or Stripe.
# Payment receipt = identity = ownership proof.
Pay per second. No minimums. No commitments. x402 micropayments.
| Plan | CPU | RAM | Storage | $/hour |
|---|---|---|---|---|
| s-1vcpu-512mb | 1 vCPU | 512 MB | 10 GB | $0.007 |
| s-1vcpu-1gb | 1 vCPU | 1 GB | 25 GB | $0.012 |
| s-2vcpu-4gb | 2 vCPU | 4 GB | 50 GB | $0.036 |
| s-4vcpu-8gb | 4 vCPU | 8 GB | 100 GB | $0.071 |
| s-8vcpu-16gb | 8 vCPU | 16 GB | 200 GB | $0.143 |
| gpu-a10-24gb | 8 vCPU | 32 GB | 200 GB | $1.10 |
Bandwidth: $0.01/GB. Snapshots: $0.05/GB/mo. All prices in USD.
The internet has a status code for payments. It's been reserved since 1997. HTTP 402: Payment Required.
Every other cloud provider requires: an email, a password, a credit card, KYC verification, an API key, a dashboard, a billing page, a support ticket system. Agents don't have emails.
x402 is the missing piece. Agent sends request → server returns 402 with payment details → agent pays (Lightning/L2/Stripe) → server returns the resource. The payment IS the authentication.
No account. No API key. No session. No cookies. Every request is self-contained. The payment receipt proves you paid, identifies your resources, and authorizes access. Stateless compute for stateless agents.
# The x402 flow
1. POST /v1/instances
→ 402 Payment Required
→ {"price": "0.012", "currency": "USD", "networks": ["lightning", "base"]}
2. Agent pays $0.012 via Lightning
→ receives payment_token
3. POST /v1/instances
X-402-Payment: lnbc120n1p...
→ 201 Created
→ {"id": "inst_k7x9m2", "ipv4": "198.51.100.1"}
# The payment token is your identity.
# Same token on GET /v1/instances → your instances.
# Lost token = lost access. Agents handle their own keys.
For operators running spawn.sh nodes. Not for end users (agents are the end users).
$ spawn node add --region nyc1 --provider hetzner
$ spawn node list
$ spawn node drain nyc1-04
$ spawn capacity --region all
$ spawn audit --last 24h
$ spawn pricing set s-1vcpu-1gb --hourly 0.012
$ spawn payments reconcile --network lightning
No sign-up page because there's nothing to sign up for. Just point your agent at the API and pay.
Read the docs →or just: curl https://spawn.prim.sh/v1/plans