Skip to main content
All API requests to genui.sh require authentication using an API key.

Getting Your API Key

  1. Sign in to your genui.sh dashboard
  2. Navigate to Settings > API Keys
  3. Click Create New Key
  4. Copy and securely store your API key
API keys are only shown once when created. If you lose your key, you’ll need to generate a new one.

Using Your API Key

Include your API key in the Authorization header of all requests:
Authorization: Bearer YOUR_API_KEY
curl -X GET https://genui.sh/api/artifacts \
  -H "Authorization: Bearer genui_abc123..."

Best Practices

Never hardcode API keys in your source code. Use environment variables instead:
export GENUI_API_KEY=genui_your_key_here
Generate new API keys periodically and revoke old ones from the dashboard.
Create separate API keys for development, staging, and production environments.
Check your dashboard regularly to monitor API usage and detect any anomalies.

Error Responses

If authentication fails, you’ll receive one of these responses:
Status CodeErrorDescription
401unauthorizedMissing or invalid API key
403forbiddenAPI key doesn’t have permission for this resource
429rate_limitedToo many requests, slow down
Example error response:
{
  "error": {
    "code": "unauthorized",
    "message": "Invalid API key provided"
  }
}

Rate Limits

API requests are rate limited based on your plan:
PlanRequests per minute
Free60
Pro600
EnterpriseCustom
Rate limit headers are included in all responses:
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 45
X-RateLimit-Reset: 1705320000