Endpoint quick reference
The same sk- key works across all three endpoints, sharing the account quota.
API categories
OpenAI-compatible
/v1/chat/completions, /v1/embeddings, /v1/images/*, /v1/audio/*, /v1/responses, /v1/realtimeClaude Messages
/v1/messages, /v1/messages/count_tokensGemini native
:generateContent, :streamGenerateContent, :embedContentRerank
/v1/rerank — Cohere / Jina compatibleMidjourney
/mj/submit/*, /mj/task/{id}/fetchSuno
/suno/submit/music, /suno/fetch/{id}Common conventions
- Protocol: HTTPS, HTTP/2 recommended (
curl --http2). - Encoding:
Content-Type: application/json; charset=utf-8. - Timeout: server default 600 seconds. Streaming responses keep a long connection, with an idle heartbeat every 15 seconds.
- Request body size: default limit 32 MB (after compression).
- Response headers:
X-OpenPAI-Request-Id: the request ID — include it in support tickets to speed up diagnosis.X-OpenPAI-Group: the user group this request used.X-OpenPAI-Quota-Consumed: the amount charged for this request.X-OpenPAI-Remaining-Quota: the account balance after the charge.
Next steps
Authentication
Auth header formats and examples for the three protocols.
Error codes
HTTP statuses, error structure and troubleshooting tips.
Rate limits
RPM / TPM limits and handling 429.