Skip to main content
POST
/
v0
/
auth
GenerateAccessToken
curl --request POST \
  --url https://api.interhuman.ai/v0/auth \
  --header 'Content-Type: application/json' \
  --data '
{
  "key_id": "<string>",
  "key_secret": "<string>",
  "scopes": [
    "interhumanai.upload"
  ]
}
'
{
  "access_token": "<string>",
  "expires_in": 123,
  "scope": "<string>",
  "token_type": "Bearer"
}

Authenticate with access tokens

Interhuman uses short-lived bearer tokens for every request. Use your issued key pair to exchange for an access token, then send that token on HTTP or WebSocket calls. If you still need a key, start with Get an API key.

Body

application/json
key_id
string
required

API key ID from the Interhuman dashboard.

key_secret
string
required

API key secret from the Interhuman dashboard.

scopes
enum<string>[]
required

List of requested scopes. At least one scope must be provided.

Minimum array length: 1

Scopes define which endpoints the token can call. Options: interhumanai.upload for /v0/upload/analyze, interhumanai.stream for /v0/stream/analyze.

Available options:
interhumanai.upload,
interhumanai.stream

Response

Authentication successful, token follows

access_token
string
required

The generated access token.

expires_in
integer
required

Time in seconds until expiration. Usually 900s or 15 minutes.

scope
string
required

Space-separated list of granted scopes.

token_type
string
default:Bearer

Token type. Always Bearer.