{"openapi":"3.1.0","info":{"title":"Tenzro Labs Platform API","version":"1.0.0","description":"Browse the curated catalogue, manage credits, keys, plans and rentals, and place and pay orders. Inference itself goes through the OpenAI-compatible endpoint."},"servers":[{"url":"https://platform.tenzro.xyz/api"}],"security":[{"apiKey":[]}],"components":{"securitySchemes":{"apiKey":{"type":"http","scheme":"bearer","description":"A Tenzro Labs API key (tzl_…)."}},"schemas":{"Error":{"type":"object","properties":{"error":{"type":"object","properties":{"code":{"type":"string"},"message":{"type":"string"}}}}}}},"paths":{"/models":{"get":{"tags":["Catalogue"],"summary":"List models","description":"Every model in the catalogue with its pricing in Tenzro Labs credits (1 credit = 0.001 TNZO) and the machines that serve it. Pricing is free on testnet.\n\nNo key needed.","operationId":"getModels","security":[],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":[{"id":"qwen3.5-4b","name":"Qwen 3.5 4B","family":"Qwen","description":"Small, fast language model for chat, extraction and tool calls.","modality":"text","context_length":131072,"pricing":{"input_credits_per_mtok":0,"output_credits_per_mtok":0,"credits_per_request":0},"available":true,"machines":["tenzro-partner-cluster"]}]}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/models/{id}":{"get":{"tags":["Catalogue"],"summary":"Get a model","description":"One model, plus the current route order: the machines a request would go to, best first.\n\nNo key needed.","operationId":"getModelsById","security":[],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"id":"qwen3.5-4b","name":"Qwen 3.5 4B","family":"Qwen","description":"Small, fast language model for chat, extraction and tool calls.","modality":"text","context_length":131072,"pricing":{"input_credits_per_mtok":0,"output_credits_per_mtok":0,"credits_per_request":0},"available":true,"machines":["tenzro-partner-cluster"],"routes":[{"machine_id":"tenzro-partner-cluster","health":"online","region":"Europe","score":120}]}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/machines":{"get":{"tags":["Catalogue"],"summary":"List machines","description":"The machines Tenzro Labs runs, with hardware, live health, and what each offers. rent and subscribe are null where a machine offers neither.\n\nNo key needed.","operationId":"getMachines","security":[],"parameters":[{"name":"service","in":"query","required":false,"description":"Only machines offering this.","schema":{"type":"string","enum":["serverless","rent","subscribe"]}},{"name":"region","in":"query","required":false,"description":"Exact region name, e.g. Europe.","schema":{"type":"string"}},{"name":"gpu","in":"query","required":false,"description":"true for GPU machines, false for CPU-only.","schema":{"type":"boolean"}},{"name":"operator","in":"query","required":false,"description":"Operator id.","schema":{"type":"string"}},{"name":"model","in":"query","required":false,"description":"Only machines set up to serve this model id.","schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":[{"id":"tenzro-partner-cluster","name":"Tenzro Partner Cluster","region":"Europe","operator":{"id":"tenzro-partners","name":"Tenzro Partners"},"health":"online","hardware":{"gpus":[{"model":"NVIDIA DGX Spark (GB10)","count":1,"vram_gb":128},{"model":"NVIDIA RTX 5070 Ti","count":1,"vram_gb":16}],"cpu_cores":40,"memory_gb":160,"storage_gb":4000},"services":{"serverless":{"models":["qwen3.8-27b","qwen3.5-4b","timesfm-2.5-200m","qwen3-embedding-0.6b","flux2-klein-4b"],"serving_now":["qwen3.8-27b","qwen3.5-4b","timesfm-2.5-200m","qwen3-embedding-0.6b"]},"rent":null,"subscribe":null},"network":{"status":"active","reachability":"reachable"}}]}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/machines/{id}":{"get":{"tags":["Catalogue"],"summary":"Get a machine","description":"No key needed.","operationId":"getMachinesById","security":[],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"id":"tenzro-partner-cluster","name":"Tenzro Partner Cluster","region":"Europe","operator":{"id":"tenzro-partners","name":"Tenzro Partners"},"health":"online","hardware":{"gpus":[{"model":"NVIDIA DGX Spark (GB10)","count":1,"vram_gb":128},{"model":"NVIDIA RTX 5070 Ti","count":1,"vram_gb":16}],"cpu_cores":40,"memory_gb":160,"storage_gb":4000},"services":{"serverless":{"models":["qwen3.8-27b","qwen3.5-4b","timesfm-2.5-200m","qwen3-embedding-0.6b","flux2-klein-4b"],"serving_now":["qwen3.8-27b","qwen3.5-4b","timesfm-2.5-200m","qwen3-embedding-0.6b"]},"rent":null,"subscribe":null},"network":{"status":"active","reachability":"reachable"}}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/operators":{"get":{"tags":["Catalogue"],"summary":"List operators","description":"Who runs the machines, and which machines they run: operators on the Tenzro Network that partner with Tenzro Labs.\n\nNo key needed.","operationId":"getOperators","security":[],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":[{"id":"tenzro-partners","name":"Tenzro Partners","description":"Operators on the Tenzro Network that partner with Tenzro Labs: they rent it capacity or serve its traffic on demand, and it serves its curated models from their machines.","website":"https://tenzro.xyz","featured":true,"certifications":[],"machines":[{"id":"tenzro-partner-cluster","name":"Tenzro Partner Cluster","health":"online"}]}]}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/operators/{id}":{"get":{"tags":["Catalogue"],"summary":"Get an operator","description":"No key needed.","operationId":"getOperatorsById","security":[],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"id":"tenzro-partners","name":"Tenzro Partners","website":"https://tenzro.xyz","featured":true,"certifications":[]}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/route":{"get":{"tags":["Catalogue"],"summary":"Preview routing","description":"Which machines an unscoped request for a model would be sent to right now, in order.\n\nNo key needed.","operationId":"getRoute","security":[],"parameters":[{"name":"model","in":"query","required":true,"description":"Model id.","schema":{"type":"string"}},{"name":"region","in":"query","required":false,"description":"Prefer machines in this region when otherwise equal.","schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"model":"qwen3.5-4b","routes":[{"machine_id":"tenzro-partner-cluster","health":"online","region":"Europe","score":120}]}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/packages":{"get":{"tags":["Catalogue"],"summary":"List credit packages and offers","description":"No key needed.","operationId":"getPackages","security":[],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":[]}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/payment-methods":{"get":{"tags":["Catalogue"],"summary":"List payment methods","description":"Whether card and stablecoin payments are set up, and which chains and tokens are accepted. available is false for a method that is not set up.\n\nNo key needed.","operationId":"getPaymentMethods","security":[],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"card":{"available":false,"processor":"stripe"},"stablecoin":{"available":false,"processor":"bridge","options":[]}}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/quotes":{"post":{"tags":["Catalogue"],"summary":"Price an order","description":"What an order would cost, without creating it. Accepts the same body as Create an order. amount_usd is the fiat price; details.credits is what it grants. Credit orders are refused until Tenzro Labs sets the credit price, as shown.\n\nNo key needed.","operationId":"postQuotes","security":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"oneOf":[{"title":"Credits","type":"object","required":["type","amount_usd"],"properties":{"type":{"const":"credits"},"amount_usd":{"type":"integer","minimum":5,"maximum":5000,"description":"The fiat price to pay, in whole US dollars. The credits it buys are set by Tenzro Labs; until that price is set, credit orders are refused."},"machine_id":{"type":"string","description":"Pin the credit to one machine. Omit for credit usable anywhere."},"gift":{"type":"boolean","description":"Issue a redeemable ticket code instead of crediting this account."}}},{"title":"Package","type":"object","required":["type","package_id"],"properties":{"type":{"const":"package"},"package_id":{"type":"string"},"gift":{"type":"boolean"}}},{"title":"Rental","type":"object","required":["type","machine_id","cpu_cores","memory_gb","hours"],"properties":{"type":{"const":"rental"},"machine_id":{"type":"string"},"gpu":{"type":"integer","minimum":0},"cpu_cores":{"type":"integer","minimum":1},"memory_gb":{"type":"integer","minimum":1},"storage_gb":{"type":"integer","minimum":0},"hours":{"type":"integer","minimum":1}}},{"title":"Subscription","type":"object","required":["type","machine_id","plan_id"],"properties":{"type":{"const":"subscription"},"machine_id":{"type":"string"},"plan_id":{"type":"string"},"renew_subscription_id":{"type":"string","description":"Renew an existing stablecoin plan for another 30 days."}}}]},"example":{"type":"credits","amount_usd":25}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"error":{"code":"invalid_request","message":"Credit top-ups open when pricing is set; usage is free on testnet."}}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/me":{"get":{"tags":["Account"],"summary":"Get the account and key","description":"The account the key belongs to, and the key's own permissions and scope.\n\nNeeds a key with the `read` permission.","operationId":"getMe","responses":{"200":{"description":"OK","content":{"application/json":{"example":{"email":"dev@example.com","created_at":"2026-09-01T00:00:00.000Z","key":{"id":"key_Zb81Qm0sP4aT","name":"ci","prefix":"tzl_3kQ9aZ1x","permissions":["inference","read"],"scope":null,"subscription_id":null,"rental_id":null,"created_at":"2026-09-26T08:00:00.000Z","last_used_at":null,"revoked_at":null}}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/credits":{"get":{"tags":["Credits"],"summary":"Get the credit balance","description":"Total balance and its split between credit usable anywhere (machine_id null) and credit pinned to machines.\n\nNeeds a key with the `read` permission.","operationId":"getCredits","responses":{"200":{"description":"OK","content":{"application/json":{"example":{"total_credits":25000,"by_scope":[{"machine_id":null,"credits":25000}]}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/credits/activity":{"get":{"tags":["Credits"],"summary":"List credit activity","description":"Credit added, plan credit granted, and usage charged, newest first.\n\nNeeds a key with the `read` permission.","operationId":"getCreditsActivity","parameters":[{"name":"limit","in":"query","required":false,"description":"1–500, default 50.","schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":[{"id":"812","type":"usage","credits":0,"machine_id":"tenzro-partner-cluster","at":"2026-09-26T08:01:12.000Z"}]}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/credits/redeem":{"post":{"tags":["Credits"],"summary":"Redeem a ticket","description":"Needs a key with the `manage` permission.","operationId":"postCreditsRedeem","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["code"],"properties":{"code":{"type":"string","example":"TZ-7K2M-9QXA-4BVN-P0RD"}}},"example":{"code":"TZ-7K2M-9QXA-4BVN-P0RD"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"redeemed":true,"credits":25000,"machine_id":null}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/tickets":{"get":{"tags":["Credits"],"summary":"List tickets you bought","description":"Gift tickets and credit tickets this account bought, including codes not yet redeemed.\n\nNeeds a key with the `read` permission.","operationId":"getTickets","responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":[{"code":"TZ-7K2M-9QXA-4BVN-P0RD","credits":25000,"machine_id":null,"redeemed":false,"redeemed_by_you":false}]}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/orders":{"post":{"tags":["Orders"],"summary":"Create an order","description":"Creates an unpaid order for credits, a package, a rental, or a plan. Pay it with Pay an order, or send a person to pay_url. Nothing is charged until payment completes.\n\nNeeds a key with the `manage` permission.","operationId":"postOrders","requestBody":{"required":true,"content":{"application/json":{"schema":{"oneOf":[{"title":"Credits","type":"object","required":["type","amount_usd"],"properties":{"type":{"const":"credits"},"amount_usd":{"type":"integer","minimum":5,"maximum":5000,"description":"The fiat price to pay, in whole US dollars. The credits it buys are set by Tenzro Labs; until that price is set, credit orders are refused."},"machine_id":{"type":"string","description":"Pin the credit to one machine. Omit for credit usable anywhere."},"gift":{"type":"boolean","description":"Issue a redeemable ticket code instead of crediting this account."}}},{"title":"Package","type":"object","required":["type","package_id"],"properties":{"type":{"const":"package"},"package_id":{"type":"string"},"gift":{"type":"boolean"}}},{"title":"Rental","type":"object","required":["type","machine_id","cpu_cores","memory_gb","hours"],"properties":{"type":{"const":"rental"},"machine_id":{"type":"string"},"gpu":{"type":"integer","minimum":0},"cpu_cores":{"type":"integer","minimum":1},"memory_gb":{"type":"integer","minimum":1},"storage_gb":{"type":"integer","minimum":0},"hours":{"type":"integer","minimum":1}}},{"title":"Subscription","type":"object","required":["type","machine_id","plan_id"],"properties":{"type":{"const":"subscription"},"machine_id":{"type":"string"},"plan_id":{"type":"string"},"renew_subscription_id":{"type":"string","description":"Renew an existing stablecoin plan for another 30 days."}}}]},"example":{"type":"credits","amount_usd":25}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"id":"ord_4hYt2K9qLmN0pXr8","type":"credits","title":"Credit top-up · any machine","amount_usd":25,"currency":"usd","status":"pending","machine_id":null,"payment":{"method":null},"pay_url":"https://platform.tenzro.xyz/checkout/ord_4hYt2K9qLmN0pXr8","created_at":"2026-09-26T08:00:00.000Z","paid_at":null}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"tags":["Orders"],"summary":"List orders","description":"Needs a key with the `read` permission.","operationId":"getOrders","parameters":[{"name":"limit","in":"query","required":false,"description":"1–200, default 50.","schema":{"type":"integer"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":[{"id":"ord_4hYt2K9qLmN0pXr8","type":"credits","title":"Credit top-up · any machine","amount_usd":25,"currency":"usd","status":"pending","machine_id":null,"payment":{"method":null},"pay_url":"https://platform.tenzro.xyz/checkout/ord_4hYt2K9qLmN0pXr8","created_at":"2026-09-26T08:00:00.000Z","paid_at":null}]}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/orders/{id}/pay":{"post":{"tags":["Orders"],"summary":"Pay an order","description":"card returns a Stripe Checkout URL for a person to open. stablecoin returns a deposit address, token, chain and exact amount; the order is fulfilled when the deposit is received.\n\nNeeds a key with the `manage` permission.","operationId":"postOrdersByIdPay","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["method"],"properties":{"method":{"enum":["card","stablecoin"]},"chain":{"type":"string","description":"Stablecoin only. See List payment methods."},"token":{"type":"string","description":"Stablecoin only, e.g. usdc."}}},"example":{"method":"stablecoin","chain":"base","token":"usdc"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"id":"ord_4hYt2K9qLmN0pXr8","type":"credits","title":"Credit top-up · any machine","amount_usd":25,"currency":"usd","status":"pending","machine_id":null,"payment":{"method":"stablecoin","deposit":{"chain":"base","token":"usdc","amount":"25.00","address":"0x9f…c21","memo":null}},"pay_url":"https://platform.tenzro.xyz/checkout/ord_4hYt2K9qLmN0pXr8","created_at":"2026-09-26T08:00:00.000Z","paid_at":null}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/orders/{id}":{"get":{"tags":["Orders"],"summary":"Get an order","description":"Current status. For a paid credit order, includes the ticket: its code, the credits it grants, and whether you redeemed it. Poll this after paying.\n\nNeeds a key with the `read` permission.","operationId":"getOrdersById","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"id":"ord_4hYt2K9qLmN0pXr8","type":"credits","title":"Credit top-up · any machine","amount_usd":25,"currency":"usd","status":"paid","machine_id":null,"payment":{"method":null},"pay_url":"https://platform.tenzro.xyz/checkout/ord_4hYt2K9qLmN0pXr8","created_at":"2026-09-26T08:00:00.000Z","paid_at":"2026-09-26T08:03:00.000Z","ticket":null}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/keys":{"get":{"tags":["API keys"],"summary":"List API keys","description":"Needs a key with the `read` permission.","operationId":"getKeys","responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":[{"id":"key_Zb81Qm0sP4aT","name":"ci","prefix":"tzl_3kQ9aZ1x","permissions":["inference","read"],"scope":null,"subscription_id":null,"rental_id":null,"created_at":"2026-09-26T08:00:00.000Z","last_used_at":null,"revoked_at":null}]}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"tags":["API keys"],"summary":"Create an API key","description":"The secret is returned once. A key can only grant permissions it holds. Scope with machine_id, subscription_id or rental_id; otherwise the key reaches every machine.\n\nNeeds a key with the `manage` permission.","operationId":"postKeys","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string"},"permissions":{"type":"array","items":{"enum":["inference","read","manage"]},"default":["inference"]},"machine_id":{"type":"string"},"subscription_id":{"type":"string"},"rental_id":{"type":"string"}}},"example":{"name":"ci","permissions":["inference","read"]}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"id":"key_Zb81Qm0sP4aT","name":"ci","prefix":"tzl_3kQ9aZ1x","permissions":["inference","read"],"scope":null,"subscription_id":null,"rental_id":null,"created_at":"2026-09-26T08:00:00.000Z","last_used_at":null,"revoked_at":null,"secret":"tzl_3kQ9aZ1x…"}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/keys/{id}":{"delete":{"tags":["API keys"],"summary":"Revoke an API key","description":"Needs a key with the `manage` permission.","operationId":"deleteKeysById","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"id":"key_Zb81Qm0sP4aT","revoked":true}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/subscriptions":{"get":{"tags":["Plans & rentals"],"summary":"List plans","description":"No machine offers plans on testnet, so this list is empty.\n\nNeeds a key with the `read` permission.","operationId":"getSubscriptions","responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":[]}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/subscriptions/{id}/cancel":{"post":{"tags":["Plans & rentals"],"summary":"Cancel at period end","description":"Card plans only. The plan stays active until current_period_end.\n\nNeeds a key with the `manage` permission.","operationId":"postSubscriptionsByIdCancel","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"id":"subs_Qp0r…","status":"active","auto_renews":false,"cancel_at_period_end":true}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/subscriptions/{id}/resume":{"post":{"tags":["Plans & rentals"],"summary":"Resume auto-renewal","description":"Needs a key with the `manage` permission.","operationId":"postSubscriptionsByIdResume","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"id":"subs_Qp0r…","status":"active","auto_renews":true,"cancel_at_period_end":false}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/rentals":{"get":{"tags":["Plans & rentals"],"summary":"List rentals","description":"No machine offers rentals on testnet, so this list is empty.\n\nNeeds a key with the `read` permission.","operationId":"getRentals","responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":[]}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/identity":{"get":{"tags":["Identity & agents"],"summary":"Get your Tenzro identity","description":"Your did:tenzro:human identity and wallet, rooted in your passkeys. manage_url is where passkeys and devices are managed.\n\nNeeds a key with the `read` permission.","operationId":"getIdentity","responses":{"200":{"description":"OK","content":{"application/json":{"example":{"state":"ready","did":"did:tenzro:human:e0b27720-3043-84d5-9b66-49eba92b1a8d","wallet_address":"0xd8aa2ca0a3b56be2b58d6c883c7b3ed31d749428","error":null,"passkeys":2,"can_send":true,"manage_url":"https://accounts.tenzro.xyz/wallet?return_to=…"}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/agents":{"get":{"tags":["Identity & agents"],"summary":"List agents","description":"Each agent's status and the limits its owner approved. An outstanding approval is collected first, so a list read after the owner approves shows the result.\n\nNeeds a key with the `read` permission.","operationId":"getAgents","responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":[{"id":"agt_Zp3kQ9x1RmW4sT","name":"research-bot","status":"active","approval":null,"capabilities":["inference"],"limits":{"max_transaction_tnzo":null,"max_daily_tnzo":null,"daily_limit_credits":20000,"total_limit_credits":500000,"expires_in_days":90},"proposed":null,"did":"did:tenzro:machine:e0b27720-3043-84d5-9b66-49eba92b1a8d:7c1d…","wallet_address":"0x4b1f…","serving":{"nodes":3,"operators":2},"network_key_held":true,"error":null,"created_at":"2026-09-26T09:05:00.000Z","approved_at":"2026-09-26T09:12:00.000Z","activated_at":"2026-09-26T09:12:00.000Z","expires_at":"2026-12-25T09:12:00.000Z","revoked_at":null}]}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"tags":["Identity & agents"],"summary":"Create an agent","description":"Proposes an agent under your identity and returns approve_url. The account owner opens it, may adjust the settings, and approves with their passkey on the account site; a passkey cannot be pressed from code, so relay the link to a person. The agent becomes active once the approval is collected: reading the agent collects it. The settings the owner approved are the ones that apply. Refused with no_serving_nodes while the network has none.\n\nNeeds a key with the `manage` permission.","operationId":"postAgents","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["name"],"properties":{"name":{"type":"string","description":"1 to 64 lowercase letters, digits, dots, dashes or underscores."},"capabilities":{"type":"array","items":{"enum":["inference","payments"]},"default":["inference"]},"max_transaction_tnzo":{"type":"string","description":"Network cap on any one payment the agent makes, in TNZO (e.g. \"1.5\")."},"max_daily_tnzo":{"type":"string","description":"Network cap on what the agent pays per day, in TNZO."},"daily_limit_credits":{"type":"number","description":"Tenzro Labs credits this agent may spend per UTC day."},"total_limit_credits":{"type":"number","description":"Tenzro Labs credits this agent may spend in total."},"expires_in_days":{"type":"integer","minimum":1,"maximum":3650,"description":"The delegation ends after this many days."}}},"example":{"name":"research-bot","capabilities":["inference"],"daily_limit_credits":20000,"total_limit_credits":500000,"expires_in_days":90}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"approve_url":"https://accounts.tenzro.xyz/agents/approve/apr_3xQk…","agent":{"id":"agt_Zp3kQ9x1RmW4sT","name":"research-bot","status":"awaiting_approval","approval":{"kind":"create","state":"pending","approve_url":"https://accounts.tenzro.xyz/agents/approve/apr_3xQk…"},"capabilities":["inference"],"limits":null,"proposed":{"agent_name":"research-bot","capabilities":["inference"],"max_transaction_tnzo":"","max_daily_tnzo":"","daily_limit_credits":20000,"total_limit_credits":500000,"expires_in_days":90},"did":null,"wallet_address":null,"serving":{"nodes":3,"operators":2},"network_key_held":false,"error":null,"created_at":"2026-09-26T09:05:00.000Z","approved_at":null,"activated_at":null,"expires_at":null,"revoked_at":null}}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/agents/{id}":{"get":{"tags":["Identity & agents"],"summary":"Get an agent","description":"Includes what it has spent today and in total. Collects an outstanding approval first.\n\nNeeds a key with the `read` permission.","operationId":"getAgentsById","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"id":"agt_Zp3kQ9x1RmW4sT","name":"research-bot","status":"active","approval":null,"capabilities":["inference"],"limits":{"max_transaction_tnzo":null,"max_daily_tnzo":null,"daily_limit_credits":20000,"total_limit_credits":500000,"expires_in_days":90},"proposed":null,"did":"did:tenzro:machine:e0b27720-3043-84d5-9b66-49eba92b1a8d:7c1d…","wallet_address":"0x4b1f…","serving":{"nodes":3,"operators":2},"network_key_held":true,"error":null,"created_at":"2026-09-26T09:05:00.000Z","approved_at":"2026-09-26T09:12:00.000Z","activated_at":"2026-09-26T09:12:00.000Z","expires_at":"2026-12-25T09:12:00.000Z","revoked_at":null,"spend":{"today_credits":0,"total_credits":0}}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/agents/{id}/settings":{"post":{"tags":["Identity & agents"],"summary":"Change an agent's limits","description":"Proposes new settings for an active agent, starting from the ones its owner approved last; fields you leave out stay as they are. Nothing changes until the owner approves at approve_url with their passkey. The agent's name cannot be changed.\n\nNeeds a key with the `manage` permission.","operationId":"postAgentsByIdSettings","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"capabilities":{"type":"array","items":{"enum":["inference","payments"]},"default":["inference"]},"max_transaction_tnzo":{"type":"string","description":"Network cap on any one payment the agent makes, in TNZO (e.g. \"1.5\")."},"max_daily_tnzo":{"type":"string","description":"Network cap on what the agent pays per day, in TNZO."},"daily_limit_credits":{"type":"number","description":"Tenzro Labs credits this agent may spend per UTC day."},"total_limit_credits":{"type":"number","description":"Tenzro Labs credits this agent may spend in total."},"expires_in_days":{"type":"integer","minimum":1,"maximum":3650,"description":"The delegation ends after this many days."}}},"example":{"daily_limit_credits":50000}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"approve_url":"https://accounts.tenzro.xyz/agents/approve/apr_3xQk…","agent":{"id":"agt_Zp3kQ9x1RmW4sT","name":"research-bot","status":"active","approval":{"kind":"update","state":"pending","approve_url":"https://accounts.tenzro.xyz/agents/approve/apr_3xQk…"},"capabilities":["inference"],"limits":{"max_transaction_tnzo":null,"max_daily_tnzo":null,"daily_limit_credits":20000,"total_limit_credits":500000,"expires_in_days":90},"proposed":null,"did":"did:tenzro:machine:e0b27720-3043-84d5-9b66-49eba92b1a8d:7c1d…","wallet_address":"0x4b1f…","serving":{"nodes":3,"operators":2},"network_key_held":true,"error":null,"created_at":"2026-09-26T09:05:00.000Z","approved_at":"2026-09-26T09:12:00.000Z","activated_at":"2026-09-26T09:12:00.000Z","expires_at":"2026-12-25T09:12:00.000Z","revoked_at":null}}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/agents/{id}/keys":{"post":{"tags":["Identity & agents"],"summary":"Create an API key for an agent","description":"An inference key that identifies this agent. Its usage counts against the limits its owner approved. Active agents only. The secret is returned once.\n\nNeeds a key with the `manage` permission.","operationId":"postAgentsByIdKeys","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string"},"machine_id":{"type":"string","description":"Pin the key to one machine."}}},"example":{"name":"research-bot prod"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"id":"key_Zb81Qm0sP4aT","name":"ci","prefix":"tzl_3kQ9aZ1x","permissions":["inference"],"scope":null,"subscription_id":null,"rental_id":null,"created_at":"2026-09-26T08:00:00.000Z","last_used_at":null,"revoked_at":null,"agent_id":"agt_Zp3kQ9x1RmW4sT","secret":"tzl_…"}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/agents/{id}/revoke":{"post":{"tags":["Identity & agents"],"summary":"Revoke an agent","description":"Proposes revoking the agent. Once the owner approves at approve_url with their passkey, its identity is revoked on the network and every Platform API key it holds stops working.\n\nNeeds a key with the `manage` permission.","operationId":"postAgentsByIdRevoke","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"approve_url":"https://accounts.tenzro.xyz/agents/approve/apr_3xQk…","agent":{"id":"agt_Zp3kQ9x1RmW4sT","name":"research-bot","status":"active","approval":{"kind":"revoke","state":"pending","approve_url":"https://accounts.tenzro.xyz/agents/approve/apr_3xQk…"},"capabilities":["inference"],"limits":{"max_transaction_tnzo":null,"max_daily_tnzo":null,"daily_limit_credits":20000,"total_limit_credits":500000,"expires_in_days":90},"proposed":null,"did":"did:tenzro:machine:e0b27720-3043-84d5-9b66-49eba92b1a8d:7c1d…","wallet_address":"0x4b1f…","serving":{"nodes":3,"operators":2},"network_key_held":true,"error":null,"created_at":"2026-09-26T09:05:00.000Z","approved_at":"2026-09-26T09:12:00.000Z","activated_at":"2026-09-26T09:12:00.000Z","expires_at":"2026-12-25T09:12:00.000Z","revoked_at":null}}}}},"default":{"description":"Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}}}