One key. Your choice of model.
Fluence routes requests to CheaperInference and DIT. Your application uses your Fluence key and one public endpoint. Access is invite-only during the private preview.
Get connected
- Ask your Fluence contact to invite your email, then sign in using a one-time code or magic link.
- Add prepaid USD credits in Billing. The minimum purchase is $5.
- Create an API key. Save the secret when it is shown.
- Use
https://api.fluence.cloud/v1as your OpenAI-compatible base URL.
curl https://api.fluence.cloud/v1/models \ -H "Authorization: Bearer $FLUENCE_API_KEY"
The live catalog is authoritative for model IDs, prices, context limits, privacy availability, and supported protocols. Unsupported models and protocols return an error.
Chat Completions
curl https://api.fluence.cloud/v1/chat/completions \
-H "Authorization: Bearer $FLUENCE_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model":"openai/gpt-5.6-luna","messages":[{"role":"user","content":"Hello"}],"max_tokens":128,"stream":true}'Responses
Use POST /v1/responses with model, input, and max_output_tokens. Streaming and client-executed tools are supported on eligible models. Responses are stateless: send conversation history with each request. Stored responses, previous_response_id, background jobs, hosted tools, and unbounded multi-pass Pro mode are not supported.
Anthropic Messages
Use https://api.fluence.cloud as your Anthropic base URL, without a trailing /v1. Send x-api-key: YOUR_FLUENCE_KEY and anthropic-version: 2023-06-01. Call POST /v1/messages with a Claude model from the catalog, messages, and max_tokens. Streaming and tool calls retain the native event format.
Routing and privacy
Configure one strategy in Settings: budget, curated, or custom discount. Budget routes must cost at most 30% of the reference price. Curated routing ranks eligible providers using recent latency observations. Custom routing requires your chosen minimum discount. These settings do not guarantee capacity or a particular latency.
Send "zdr": true to require a zero-retention route. Account and global privacy requirements cannot be disabled by a request. If no eligible route meets every constraint, the router returns 503. Fluence stores request metadata and billing records, without retaining your prompts or completions.
Timeouts and retries
Configure first-response, stream-idle, and total-request deadlines in Settings. The total limit covers every provider attempt and is at most 240 seconds. Before useful output starts, the router can fail over to another eligible provider without raising the quoted customer rates. After output starts, failures arrive as protocol-compatible stream errors. Always inspect the final stream event, even after HTTP 200.
Use bounded exponential backoff with jitter for 429, 502, 503, or 504, respecting Retry-After. Send an Idempotency-Key to prevent a duplicate dispatch. Reusing a key returns 409; it does not replay content, because response bodies are not stored. Check usage before retrying an ambiguous completed request.
Key permissions and limits
| Scope | Access |
|---|---|
inference | Model discovery and inference requests |
usage:read | GET /v1/usage, /v1/usage/requests, /v1/usage/daily |
account:read | GET /v1/account |
account:write | PATCH /v1/account and POST /v1/account/topup |
Per-key restrictions cover requests per minute/day, concurrency, monthly USD budgets, expiry, allowed model IDs, and IPv4/IPv6 addresses or CIDRs. Empty means no additional key restriction. The service currently limits each account to 50 concurrent requests. Monthly budgets reset at the start of each UTC calendar month.
Prompt caching
Set the key default to passthrough, on, or off. Override it with x-fluence-prompt-cache or x-ci-prompt-cache. Passthrough preserves your input. On marks supported prefixes as cacheable. Off removes explicit cache controls; it cannot turn off a provider’s implicit caching. The x-ci-prompt-cache-affinity response header reports the provider’s outcome when available, otherwise unavailable or off. Cache discounts depend on the actual provider response.
Billing
The router holds a conservative maximum credit amount before dispatch and releases unused credit after settlement. Customer rates include the model markup and are capped at reference prices. Completed requests include a fluence.billing.charged_usd field with the settled charge. Streams carry this in their final usage event. Failed or incomplete requests without confirmed completion are not charged.
Credit purchases are nonrefundable under the Fluence terms. Credits do not expire. Applicable taxes are added separately. Stripe handles your card details and fraud checks. Payments under Radar review do not become usable credit until approved. Optional auto top-up requires a saved card and explicit monthly purchase cap.
Errors
| Status | Meaning |
|---|---|
| 400 | Invalid or unsupported request parameter |
| 401 | Missing, expired, or revoked key |
| 402 | Insufficient available credits |
| 403 | Scope, IP, model, or account restriction |
| 409 | Duplicate idempotency key |
| 413 | Request body too large |
| 429 | Rate, concurrency, or spending limit reached |
| 502 | Upstream response or stream failure |
| 503 | No eligible route or temporary service outage |
| 504 | Provider or overall request timeout |
Each inference response includes x-request-id. Use it to find the request in Usage. JSON errors contain error.code and error.message; Messages uses the Anthropic error envelope.