Skip to Content
API GatewayAuthentication

Authentication

External users authenticate with a Bearer token in the Authorization header.

Usage

curl -X POST https://creative.hellyeahai.com/images/generate \ -H "Authorization: Bearer hyai_xxxx..." \ -H "Content-Type: application/json" \ -d '{"prompt": "a cute cat", "model": "jimeng-4.5"}'

Creating API Keys

curl -X POST https://creative.hellyeahai.com/admin/keys \ -H "Authorization: Bearer <admin-secret>" \ -H "Content-Type: application/json" \ -d '{ "name": "client-name", "owner": "contact-person", "credits_quota": 5000, "quota_period_days": 3 }'

Keys are prefixed with hyai_ and cannot be retrieved after creation.

Additional optional fields: rate_limit_rpm (default 30), allowed_providers (default ‘jimeng’), expires_at, expires_in_days.

Key Management

  • Keys are permanent until manually disabled
  • Disabling: DELETE /admin/keys/:id
  • Update quota: POST /admin/keys/:id/quota
Last updated on