ornn login. Create a key once in the console, then use it from your application, scripts, or CI.
The API reference documents every operation a key can call, with schemas and examples. Download the OpenAPI specification for Postman, Swagger tools, or a client generator.
For a complete cluster integration, start with Provision and manage Kubernetes through REST.
What a key can and cannot do
An API key belongs to one organization: the one you choose when you create it. The key is its own caller in that organization, not a copy of your account. It keeps working if you leave the organization, and what it creates or buys is recorded under the key. It never carries Ornn staff access. Compute, cluster, storage, and SSH-key APIs require organization membership and access to the requested resources. Buyer approval is required for Reserve browsing and purchasing, and for writes that start billable infrastructure (networks, storage, and disks). A key does not bypass these checks, payment, or node eligibility.Access levels
Choose an access level when you create a key. You can’t change it later; create a new key instead.
A read-only key gets
403 with code api_key_read_only on any other request, including requests that create, change, or delete something. Use read-only keys for reporting and data sync, such as copying reservations, listings, and ledger entries into your own systems.
Account, team, and key-management routes reject API keys with
403 and detail.code api_key_requires_session. The CLI accepts keys through ORNN_API_KEY; MCP clients still use the MCP sign-in flow.
Keys don’t expire. A key stops working as soon as anyone in the organization revokes it. It keeps working when the member who created it leaves.
Create a key
1
Open the Developer tab
Open Account Settings and select Developer (
/account?tab=developer). The tab is
available to every organization member and lists the keys of every organization you belong to.
Suppliers can use Developers in the supplier portal instead.2
Create the key
If you have no keys, click Create key in the No API keys yet empty state. Otherwise,
use Create key above the list. Enter a name of up to 100 characters, such as
CI deploys.
Choose the Organization the key belongs to (your active organization is selected) and its Access:
Read and write, or Read only. Then confirm.3
Copy the key
Copy the key, which starts with
ornn_sk_, and store it in your secrets manager. Ornn shows it
only once and keeps only a hash, so a lost key cannot be recovered. If it is lost or leaked,
revoke it under Account → Developer → API keys and create a new one. Expand Use it in
requests in the confirmation to see a ready-to-paste curl request with its own copy button
to check the account and organization the key resolves to.Use a key
Send the key in theAuthorization header as a bearer token. The key already belongs to its organization, so you don’t need to name the organization in the request. Start by checking which account and organization the key resolves to.
200 with the key as the caller and exactly one entry in organizations: the organization the key belongs to. user_id is the key’s ID, name is the key’s name, and api_key shows its id, name, and access (read or read_write). Save the organization id; routes such as List organization SSH keys take it in the path. Check approved before browsing or buying Reserve capacity.
A 401 means the key was revoked or mistyped. See Check API authentication for the full response.
Suppliers: see Use the supplier API for node, telemetry, enrollment, and listing routes.
Import the OpenAPI contract
The contract athttps://docs.ornn.com/openapi.yaml is OpenAPI 3.1. Its server is https://api.ornn.com and its security scheme is a bearer token.
- Postman
- Swagger UI
- Client generators
- Choose Import and paste
https://docs.ornn.com/openapi.yaml. Postman creates a collection with one request per operation. - Store your key in a secret environment or vault variable, for example
ornnApiKey. - On the collection’s Authorization tab, choose Bearer Token and set the token to
{{ornnApiKey}}. Requests set to inherit authorization use it. - Send Check API authentication first to confirm the key and organization.
Rotate a key
Keys don’t expire, so rotate them on your own schedule, when someone with access to the key leaves, or immediately if a key may be exposed.1
Create the replacement
Create a new key in Account Settings → Developer with a name that identifies it, such as
CI deploys 2026-10.2
Deploy and verify it
Store the new key in your secrets manager and roll it out. Confirm it returns
200 from GET /v1/auth/session with the expected organization.3
Revoke the old key
Revoke the old key after every system has switched. Requests that still use it start failing
with
401.Revoke a key
1
Find the key
Open Account Settings → Developer. The list shows every key in your organizations: its
name, organization, access, whether you or a teammate created it, and when.
2
Revoke it
Click Revoke on the key and confirm. Anything using the key stops working immediately. This
can’t be undone.
CLI sign-in and API keys
CLI 1.0.160 or later accepts either a browser login session or an organization API key. For automation, supplyORNN_API_KEY from your secrets manager. See
CLI authentication for usage and precedence.
Both credentials use the same CLI commands. The key’s access level and organization
restrictions still apply, including read-only restrictions. See
CLI and REST equivalents for corresponding API requests.
ornn registry login requires a user login session with ORNN_API_KEY unset because it creates a key. Docker logs in to the container registry with an API key, so the command creates a read-write key named Docker login on <machine> and hands it to Docker; the CLI itself keeps using your session. Running it again on the same machine revokes that machine’s previous key. Revoke the key under Developer to sign Docker out everywhere it was used.
Reservation REST reference
These routes read reservations visible to your key’s organization: reservations it holds and sales against listings it supplies. Visibility of a sale does not grant the supplier the buyer’s cluster-launch rights. Cluster creation uses existing eligible reserved capacity; it does not buy capacity or bypass ownership, payment, or reservation dates.- List reservations:
GET /commerce/reservationsreturnsreservationsandnextCursor. - Get a reservation:
GET /commerce/reservations/{reservationId}returns one reservation. - List reserved nodes:
GET /v1/orchestrator/nodes?reservation_id={reservation_id}returns thenodesof a reservation you hold.
reservationId, status, startsAt, endsAt, reservedNodeCount, and reservedGpuCount (0 on CPU capacity, which reports cores, 2 vCPUs each). Use reservationId, not a listing ID, in the cluster launch request. When nextCursor is nonempty, send it unchanged as the URL-encoded cursor query parameter on the next request. Continue until it is absent, null, or empty. Reservation fields use camelCase; cluster request fields use snake_case.
See Create a cluster for the request and response schema, or follow the complete Kubernetes REST walkthrough.
The console’s How to use this key example prompts for the key without echoing it.
The copied command contains no credential, so it does not put your key in shell history.
Errors and safe retries
401: check that the bearer key is correct and not revoked. Repeated requests with a rejected key from one address are throttled with429.403: the key does not grant the required access. Reserve browsing and purchasing, and writes that start billable infrastructure (networks, storage, and disks), require buyer approval; other customer APIs require membership and access to the requested resources.api_key_requires_sessionmeans the operation needs a signed-in console session.api_key_read_onlymeans the key has read-only access; use a read and write key to make changes.404: verify resource ownership and IDs. Cluster credentials can also return404while they are not ready.400or422: check request fields, UUIDs, and supported values.409: resolve the reported state or capacity conflict before retrying.429or5xx: back off before retrying reads; honorRetry-Afterwhen provided.
detail.code and detail.message. Some routes return a string detail, a top-level code or error, or no JSON body. Always check the HTTP status before decoding success fields; preserve the sanitized response when contacting support.
A successful launch or worker-add response means the operation was accepted, not that the nodes are ready. Poll status and verify readiness. After a timeout on a write, read current state before retrying: do not assume the write failed. Only some routes accept an Idempotency-Key; see Retries and idempotency. Never log API keys or cluster credentials.