Prerequisites
- An each::labs API key. Grab one here if you don’t have one yet.
Getting Started
1
Get your API key
Sign up at eachlabs.ai and create an API key from API Keys.
2
Update your code
Point any OpenAI-compatible SDK to the each::labs base URL:
3
Make your first request
Use the
provider/model-name format to pick any model. Replace the sample safety_identifier with a stable ID for your signed-in user: your internal user ID or a hash of it. Each person gets their own ID; never send the sample value itself.Switch Models Instantly
Just change themodel parameter. That’s literally it. No config changes, no new SDKs, no drama:
Streaming
Setstream: true to receive OpenAI-compatible server-sent events as tokens arrive:
stream_options={"include_usage": True}
in Python or stream_options: { include_usage: true } in TypeScript.
Run requests for end users
For chat completions, add the requiredsafety_identifier at the top level of the request body to identify the person the request is for. It sits next to model and messages, not inside messages:
extra_body. With the TypeScript SDK, add it to the request params, as in the examples above. Use a stable, pseudonymous ID (your internal user ID or a hash of it, never a new random ID per request), and never an email address, a name, a phone number or an IP address, hashed or not. It is required on every request that runs a model.
It is accepted on every LLM Router endpoint on api.eachlabs.ai, but its field and location vary by endpoint; each::sense does not accept it. See Safety identifier reference for the exact location, and Safety identifier requirements for the policy. OpenAI’s user field is a request label and is never read as safety_identifier.
Advanced Features
LLM Router comes with some nice tricks out of the box:- Smart Routing automatically sends requests to the cheapest or fastest provider
- Fallbacks so your app doesn’t break when a model is having a bad day
- Caching to save you money and time on repeated requests
- Rate Limiting per model or per user, your call
- Usage Analytics to keep tabs on costs, tokens, and latency
Next Steps
LLM Router Overview
The full rundown on features and supported providers.
Available Models
Browse every available model with list prices. Go window shopping.
Audio API
Use OpenAI-compatible file transcription and streamed speech.