Authentication
All API requests require authentication using an API Key.
Get API Key
- Register at the Console
- Navigate to API Keys page
- Click Create to generate a new key
- Copy and securely store your key
Usage
Include the API Key in request headers based on the format:
| Format | Header |
|---|---|
| OpenAI Compatible | Authorization: Bearer YOUR_API_KEY |
| Anthropic | x-api-key: YOUR_API_KEY |
| Gemini | Authorization: Bearer YOUR_API_KEY |
OpenAI / Gemini Format
curl -H "Authorization: Bearer sk-your-api-key" \
https://pico.5884.cn/v1/chat/completions
Anthropic Format
curl -H "x-api-key: sk-your-api-key" \
-H "anthropic-version: 2023-06-01" \
https://pico.5884.cn/v1/messages
Security Notes
- API Keys are displayed only once at creation
- Store keys securely, do not commit to version control
- Each key can be independently disabled