provisioning

Upgrade a test key to a live free-grant key (6,000s credit)

Stage 1 of the key lifecycle. Call with a pv_test_ key in Authorization; receive a pv_live_ key with tier: free_grant and a 6,000-second credit grant. No email or card required. GitHub-gated (PRI-479): calling without a github_token returns 403 github_verification_required whose details carry the OAuth client_id and device-flow URLs — complete GitHub's device flow and retry with {"github_token": "..."}. One free grant per GitHub account, ever (duplicate → 409 github_account_already_used). IP caps (3 / IP / 24h) remain as secondary defense.

post/v1/keys/upgrade

Request

  • Base URL: https://api.primateintelligence.ai
  • URL: https://api.primateintelligence.ai/v1/keys/upgrade
  • Auth: HTTP bearer

Request body

github_tokenstring

PRI-479: GitHub OAuth access token from the device flow. Required when the GitHub gate is enabled (calling without one returns 403 github_verification_required with device-flow bootstrap details). Verified against GitHub and discarded — never stored. One free grant per GitHub account, ever.

Response

Live key issued. The raw api_key appears only in this response.

object'api_key' required
livemodetrue required
api_keystring required

The raw pv_live_ key — store securely, shown only once.

tier'free_grant' required
expires_atstring date-time required
grant_secondsinteger required
notestring

Example response

{
  "grant_seconds": 6000
}

Changes

No recorded changes to this operation across all 1 revision of this API.