Admin API

Manage your account's servers programmatically with a normal API key — no dashboard required.

1. Base URL & authentication

All endpoints live on https://notoken.cloud/api/v1/ and authenticate with the same API keys the inference endpoints use:

Authorization: Bearer tnt-...

Keys are created in the dashboard (API keys tab). Key creation and revocation stay dashboard-only on purpose: a leaked key can manage your servers, so it must never be able to mint new keys.

2. The 7 routes

MethodPathDescription
POST/api/v1/podsLaunch a server (same validation as the dashboard)
GET/api/v1/podsList your servers
GET/api/v1/pods/:idGet one server
POST/api/v1/pods/:id/stopStop a server (auto-restartable)
POST/api/v1/pods/:id/terminateTerminate a server (permanent)
GET/api/v1/settingsGet idle auto-stop setting
POST/api/v1/settingsSet idle auto-stop (0–1440 min)
GET/api/v1/creditsCredits balance + ledger (read-only)

Mutations are rate-limited to 30 requests per minute per key. Every call is recorded in your key's action history (visible in the dashboard's API keys tab).

3. Examples

List your servers:

curl https://notoken.cloud/api/v1/pods \
  -H "Authorization: Bearer tnt-..."
# 200 -> { "pods": [ { id, sku, status, instance_id, endpoint, ... } ] }

Launch a server — sku is one of starter-ada, starter-bw, pro-bw, pro-max-bw, ultra-bw; users and ctx default to the SKU's first menu option:

curl -X POST https://notoken.cloud/api/v1/pods \
  -H "Authorization: Bearer tnt-..." \
  -H "Content-Type: application/json" \
  -d '{"sku":"starter-bw","users":1,"ctx":260000}'
# 201 -> { "pod": { id, sku, status, instance_id, ... } }

Stop or terminate:

curl -X POST https://notoken.cloud/api/v1/pods/42/stop      -H "Authorization: Bearer tnt-..."
curl -X POST https://notoken.cloud/api/v1/pods/42/terminate -H "Authorization: Bearer tnt-..."
# 200 -> { "ok": true }

Settings and credits:

curl https://notoken.cloud/api/v1/settings -H "Authorization: Bearer tnt-..."
# 200 -> { "idle_stop_minutes": 15 }

curl -X POST https://notoken.cloud/api/v1/settings \
  -H "Authorization: Bearer tnt-..." -H "Content-Type: application/json" \
  -d '{"idle_stop_minutes":5}'

curl https://notoken.cloud/api/v1/credits -H "Authorization: Bearer tnt-..."
# 200 -> { "balance_cents": 509, "ledger": [ ... ] }

4. Errors

StatusMeaning
401Missing/invalid API key or disabled account
402Insufficient credits (need ≥ $1 to launch)
404Server not found (or belongs to another account)
409Invalid config / SKU not launchable / 10-server cap reached
429Rate limited — mutations are 30/min per key

Ownership is enforced on every route: a valid key can only see and manage its own account's servers. Foreign or unknown ids return 404, never a leak.

5. Inference vs management

This API manages servers. For inference, point your agent at your server's endpoint: https://api.notoken.cloud/{instance_id}/v1 — see the Docs.