Create a new API key
Mints a new opaque API key (sk-orq-<key_id>-<secret>) in the workspace. The raw secret is returned ONCE in the response and is never retrievable afterwards. The stored record retains only token_prefix and a SHA-256 token_hash.
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
Human-readable name. Required.
Owner attribution. Defaults to service_account when omitted.
Project authorization scope. Defaults to all-projects when omitted.
Permission preset. Defaults to PERMISSION_MODE_ALL when omitted.
PERMISSION_MODE_UNSPECIFIED, PERMISSION_MODE_ALL, PERMISSION_MODE_RESTRICTED, PERMISSION_MODE_READ_ONLY Per-domain access map. Required when permission_mode =
PERMISSION_MODE_RESTRICTED. See ApiKey.access for the full
catalog of valid keys (Domain.id) and AccessLevel string values,
or fetch the live catalog via the capability catalog endpoint.
Optional expiration. When set, the authenticate hot-path rejects
the key once expires_at is in the past. Unset means the key
never expires.