Docs

Everything, on one page

Gnomon runs one command per session in a sealed sandbox and bills 0.0003 USDG for each started second of it.

The CLI and MCP server are one package: gnomonrun on npm. Node 18 or newer.

Quick start

$ npx gnomonrun run --worker python -- python3 -c "print(2**64)"
18446744073709551616
1s · free (29s of trial left) · exit 0

CLI

npx gnomonrun run -- <command>
Run one command in a cloud sandbox. Makes a key in ~/.gnomon if there is none, and starts on the 30s free trial.
--worker python | node | shell
Which image runs the command. Default: python.
--budget 0.02
The most this session may cost, in USDG (default 0.02). It is held first; unused budget goes back. Max 30 minutes.
--local
Run in your own shell instead, with no sandbox. Free, and you still get a receipt signed by your key.
npx gnomonrun account
Your address, balance, free seconds left and linked funding wallets.
npx gnomonrun fund
Opens /fund with your account filled in.
npx gnomonrun stop <session>
Stops a running session. It is charged up to the moment it stopped.
npx gnomonrun mcp
Serve Gnomon as MCP tools over stdio (run_in_sandbox, gnomon_account, verify_receipt), using the same key and balance.
npx gnomonrun verify <session | file>
Checks a receipt signature against the runner key from /api/config.

For agents (MCP)

Give your agent its own sandbox. gnomonrun mcp speaks the Model Context Protocol over stdio and exposes three tools: run_in_sandbox (command, runtime, max_seconds), gnomon_account and verify_receipt. It uses the key in ~/.gnomon, so runs draw on the same balance and leave the same receipts.

Claude Code:

claude mcp add gnomon -- npx -y gnomonrun mcp

Claude Desktop, Cursor and other clients (their MCP config file):

{
  "mcpServers": {
    "gnomon": { "command": "npx", "args": ["-y", "gnomonrun", "mcp"] }
  }
}

Signing requests

The key in ~/.gnomon/key.json is your account. Each API call carries x-gnomon-account, x-gnomon-time and x-gnomon-signature: an EIP-191 signature of this message, valid for 2 minutes and only once.

gnomon:v1
<METHOD>
<path>
<unix time in ms>
<sha256 hex of the body>

HTTP API

POST /v1/sessions
Signed. { worker, command, budget } → NDJSON stream: start, out, end (with receipt)
POST /v1/sessions/:id/stop
Signed. Stop your running session
GET /v1/account
Signed. Balance, trial left, linked wallets
GET /v1/receipts/:id
Public. The signed receipt of a finished session
GET /api/config
Public. Price, trial, chain, treasury and the runner public key
GET /v1/receipts/:id/proof
Public. Merkle proof tying the receipt to its anchor transaction
GET /api/status
Public. Runner health and how many rows we keep

Receipts

A finished session returns JSON like this, signed with the runner's ed25519 key. The signature covers the receipt with its keys sorted. Check one on the home page or with gnomonrun verify.

{
  "v": 1, "mode": "cloud", "session": "ses_…", "account": "0x…",
  "worker": "python", "started": "…", "ended": "…", "ms": 412, "seconds": 1,
  "price_per_second": "300", "cost": "300", "exit": 0, "stopped": "finished",
  "command_sha256": "…", "nonce": "…",
  "sig": "<ed25519 signature, hex>", "node": "<runner public key, hex>"
}

On-chain anchors

Each hour, receipts not yet anchored become the leaves of a Merkle tree, and the root goes out in the data of a zero-value transaction from the anchor wallet to itself on Robinhood Chain. The wallet is listed at /api/config. gnomonrun verify, the MCP tool and the checker on the home page all recompute the proof and read the transaction from the chain's RPC.

leaf    = sha256(0x00 || canonical receipt JSON, sig included)
node    = sha256(0x01 || smaller child || larger child)
tx data = 0x474e4d4e ("GNMN") || 0x01 || root (32 bytes) || leaf count (uint32)

GET /v1/receipts/:id/proof   → { leaf, root, proof[], count, tx, block }
GET /v1/proof?leaf=…         → the same, for receipts past our 30 days

Limits

256 MB of memory, 0.5 CPU, 128 processes, 64 MB of scratch at /work, no network, 30 minutes per session, 8000 characters per command.