Hydrilla
Get API Key

Authentication

The Hydrilla AI API uses secure Bearer keys to authenticate requests. Manage your keys and monitor usage through the developer dashboard.

Authorization headers

Pass your API key in the Authorization header using standard Bearer authentication (recommended):

bashbearer-header.sh
curl -X GET https://backend.hydrilla.ai/v1/user/me \
  -H "Authorization: Bearer hyd_live_d81a9f02b37c4e91823abce"

Alternatively, send the key in the x-api-key header:

bashx-api-key-header.sh
curl -X GET https://backend.hydrilla.ai/v1/user/me \
  -H "x-api-key: hyd_live_d81a9f02b37c4e91823abce"

Key security and hashing

One-time reveal

When you generate a key, the full key (hyd_live_…) is shown once. Store it securely in your environment variables.

SHA-256 hashing

Hydrilla never stores your plaintext API key in the database. Only a cryptographic SHA-256 hash is persisted.

Instant revocation

You can revoke an API key at any time in the dashboard under API Keys. Revocation is instantaneous.

Error codes

401 Unauthorized

Returned if the key is missing, malformed, or has been revoked.

json401_UNAUTHORIZED.json
{
  "error": "Unauthorized",
  "message": "Invalid or revoked API key. Generate a key at https://hydrilla.co/app/api-keys"
}

402 Insufficient credits

Returned if your account credit balance is too low to run the generation.

json402_INSUFFICIENT_CREDITS.json
{
  "error": "Insufficient credits",
  "message": "This operation requires 2 credits, but your balance is 0.",
  "credits_available": 0,
  "credits_required": 2,
  "upgrade_url": "https://hydrilla.co/app/settings"
}

Was this page helpful?