Documentation
Everything you need to integrate CheapLLM into your workflow.
Quick Start
Get started with CheapLLM in under 5 minutes:
- Create an account — Sign up at cheapllm.net/signup
- Add your API key — Go to Settings → API Keys → Add Key
- Submit your first prompt — Use the web form or upload a CSV
- Get results — View in your dashboard or receive via email/webhook
Adding Your API Keys
CheapLLM uses a Bring Your Own Key (BYOK) model. You provide your own API keys from supported providers.
How to add a key:
- Navigate to Settings → API Keys
- Click Add New Key
- Select your provider (OpenAI, Anthropic, etc.)
- Paste your API key and click Save
Security Note
Your API keys are encrypted with AES-256 at rest. They are only decrypted in-memory when making requests on your behalf. We never log or store keys in plaintext. You can delete your keys at any time.
Where to get API keys:
- —OpenAI:platform.openai.com/api-keys
- —Anthropic:console.anthropic.com/settings/keys
- —Google (Gemini):aistudio.google.com/app/apikey
- —xAI (Grok):console.x.ai
- —Mistral:console.mistral.ai/api-keys
- —Together AI:api.together.xyz/settings/api-keys
Supported Providers
OpenAI
GPT-4o, GPT-4 Turbo, GPT-3.5 Turbo, o1, o1-mini
Anthropic
Claude 3.5 Sonnet, Claude 3 Opus, Claude 3 Haiku
Gemini 1.5 Pro, Gemini 1.5 Flash, Gemini Pro
xAI
Grok-2, Grok-2 Mini
Mistral
Mistral Large, Mistral Medium, Mistral Small, Mixtral
Together AI
200+ open-source models (Llama, DeepSeek, Qwen, etc.)
Using the Web Interface
The simplest way to use CheapLLM is through the web dashboard:
- Go to Dashboard → New Request
- Select your Provider and Model
- Type or paste your prompt
- Click Submit
- Results will appear in your dashboard and optionally be sent to your email
CSV Bulk Upload
For bulk requests, upload a CSV file with your prompts:
CSV Format
prompt,model,system_message
"Summarize this article: ...",gpt-4o,"You are a helpful assistant"
"Translate to Spanish: Hello world",claude-3-5-sonnet,
"Generate 5 product names for a coffee brand",gpt-4o-mini,Required Columns
- —
prompt— The prompt text (required)
Optional Columns
- —
model— Model ID (defaults to your account default) - —
system_message— System prompt for the model - —
temperature— Temperature setting (0-2) - —
max_tokens— Maximum response length
REST API Reference
Integrate CheapLLM programmatically using our REST API.
Base URL
https://api.cheapllm.net/v1Authentication
Include your CheapLLM API token in the Authorization header:
Authorization: Bearer YOUR_CHEAPLLM_TOKENSubmit a Request
POST /requests
curl -X POST https://api.cheapllm.net/v1/requests \
-H "Authorization: Bearer YOUR_CHEAPLLM_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"provider": "openai",
"model": "gpt-4o",
"prompt": "Explain quantum computing in simple terms",
"system_message": "You are a helpful teacher",
"temperature": 0.7,
"max_tokens": 1000
}'Response
{
"id": "req_abc123",
"status": "pending",
"created_at": "2024-01-15T10:30:00Z",
"estimated_completion": "2024-01-15T14:30:00Z"
}Get Request Status
GET /requests/:id
curl https://api.cheapllm.net/v1/requests/req_abc123 \
-H "Authorization: Bearer YOUR_CHEAPLLM_TOKEN"List Requests
GET /requests?status=completed&limit=50
curl "https://api.cheapllm.net/v1/requests?status=completed&limit=50" \
-H "Authorization: Bearer YOUR_CHEAPLLM_TOKEN"Webhooks
Receive notifications when your requests complete:
Setup
- Go to Settings → Webhooks
- Add your webhook URL
- Optionally add a signing secret for verification
Webhook Payload
{
"event": "request.completed",
"request_id": "req_abc123",
"status": "completed",
"result": {
"content": "Quantum computing is...",
"tokens_used": 245,
"cost_usd": 0.0012
},
"timestamp": "2024-01-15T14:32:15Z"
}Rate Limits
| Endpoint | Limit |
|---|---|
| POST /requests | 1,000 requests/minute |
| GET /requests | 100 requests/minute |
| CSV Upload | 10,000 rows per file |
Error Handling
The API returns standard HTTP status codes:
| Code | Meaning |
|---|---|
200 | Success |
400 | Bad request (invalid parameters) |
401 | Unauthorized (invalid API token) |
429 | Rate limit exceeded |
500 | Internal server error |
Error Response Format
{
"error": {
"code": "invalid_api_key",
"message": "The provided API key is invalid or expired",
"details": null
}
}