Authenticate with a key. One header on every request.

All /v1 endpoints require an API key. There are no cookies and no sessions on the API.

API keys

Keys start with prx-. Create them in the console. A key is shown once, when you create it; copy it somewhere safe, because it cannot be shown again. If you lose it, revoke it and make a new one.

Sending a key

Send the key in the x-api-key header, or as a bearer token in Authorization. Both are equivalent.

curl https://api.prisx.tech/v1/balance \
  -H "x-api-key: $PRISX_API_KEY"

# or
curl https://api.prisx.tech/v1/balance \
  -H "Authorization: Bearer $PRISX_API_KEY"

A missing, malformed or revoked key returns 401 authentication_error:

401
{
  "type": "error",
  "error": {
    "type": "authentication_error",
    "message": "Invalid API key."
  }
}

Managing keys

  • You can have at most 5 active keys at a time.
  • Revoke a key in the console at any time. It stops working immediately.
  • Use one key per application, so you can revoke one without breaking the others.

Access checks

A valid key is not enough on its own. After the key is accepted, the platform confirms that your Discord account is still in the PrisX server with the beta role. That check is trusted for a day and then repeated. If your access has ended, requests return 403 permission_error with the message "Your Discord account no longer has access to the closed beta."