API keys
Authenticate every request with a Bearer token:
The full secret is shown once at creation. Only a prefix (
ask_live_…) and
the last 4 characters are stored for display; the key itself is stored as a
SHA-256 hash.
Scopes
Each key carriesresource:action scopes (e.g. assistants:read,
calls:create). A request to an endpoint you lack the scope for returns 403.
Role presets:
- read_only →
read+liston every resource - read_write → full CRUD +
list - admin → all scopes
- custom → exactly the scopes you assign
Selecting a subaccount
A key may be authorized for one or more subaccounts. Tell the API which one a request targets, in priority order:X-Subaccount-Idheader (recommended)subaccount_idin the request bodylocation_idin the request body (legacy alias)
403.
IP allowlisting
A key can be restricted to specific source IPs or CIDR ranges. Requests from other addresses are rejected with401.