Authentication
All API requests use the same base URL and API key authentication.
Base URL
https://shark.ai/api/v1SDK clients should usually set their base URL to https://shark.ai/api/v1.
API Key
Send your key as a Bearer token:
Authorization: Bearer sk-your-api-keyThe gateway also accepts x-api-key for clients that cannot set an Authorization header.
Optional Headers
| Header | Description |
|---|---|
| X-App-UID | End-user identifier for tracking and analytics. |
| X-App-User-Credits | Optional user balance pre-check. Returns 402 when the estimated request cost exceeds this value. |
| X-Tracing-ID | Custom tracing ID. A UUID is generated when omitted. |