Skip to content

Authentication

All API endpoints (except the health check at GET /) require authentication via an API key.

  1. Sign in to the Developer Portal
  2. Navigate to API Keys
  3. Click Generate Key and give it a name
  4. Copy the key immediately — it won’t be shown again

Your key will look like: ss_a1b2c3d4e5f6789...

Include the key in the X-API-Key header with every request:

Terminal window
curl https://mcll3bnfubyazfg6wekv3xc6fi0dgpyk.lambda-url.us-east-1.on.aws/identify_clothing \
-H "X-API-Key: ss_your_key_here" \
-H "Content-Type: application/json" \
-d '{"image_url": "https://example.com/outfit.jpg"}'
StatusErrorMeaning
401Missing X-API-Key headerYou didn’t include the header
403Invalid API keyThe key is wrong, revoked, or inactive
{
"error": "Missing X-API-Key header"
}
{
"error": "Invalid API key"
}

You can manage your keys from the Developer Portal:

  • Generate new keys with descriptive names
  • Revoke keys that are compromised or no longer needed
  • Monitor when each key was last used
  • Never expose keys in client-side code — use a backend proxy
  • Use different keys for development, staging, and production
  • Rotate keys periodically — revoke old ones after generating new ones
  • Store keys in environment variables, not in source code