Create Api Key
POST /api-keys
Mint a new API key for the caller’s own org. The token is returned exactly once.
Authorizations
Parameters
Header Parameters
Request Body required
Request to mint a new organization API key.
extra="forbid" so a caller sending org_id, is_agency or
is_ops gets an explicit 422 instead of the field being silently
dropped — it is a stronger, more debuggable signal that those fields do
not exist on this door.
object
Optional list of IPv4/IPv6 CIDR strings (e.g. [‘10.0.0.0/8’, ‘2001:db8::/32’]). Bare IPs are accepted as /32 (IPv4) or /128 (IPv6). When non-empty, only requests from a matching IP are accepted — all others receive 403. Empty list (the default) means unrestricted: the key works from any IP address. Maximum 50 entries.
Key mode. A ‘test’ key is returned with a g8_test_ prefix; a ‘live’ key carries g8_live_; a ‘sandbox’ key carries g8_sbx_ and only authenticates against the graph8 developer sandbox. A key minted by a ‘test’-mode credential is always forced to ‘test’ regardless of this field — a test key may not mint itself a live successor.
Human-readable name for the key
Responses
201
Successful Response
object
Response after minting a key.
api_key_token is returned exactly once, here, at creation. No other
endpoint on this router — or the app’s — ever returns it again.
object
Sandbox or live, derived from mode (additive; a test key reads live).
object
Whether there are more pages
Items per page
Current page number (1-indexed)
Total number of items
422
Validation Error