- Confidential API
- Router (Beta)
Use the local Confidential Proxy for sensitive model traffic. Go to the confidential setup.
Confidential API
What the proxy does
- Accepts the client’s OpenAI-compatible request on your machine.
- Encrypts request content before network egress.
- Sends ciphertext and required metadata through the Prem API Gateway.
- Decrypts the enclave response locally and returns the supported OpenAI-compatible response shape.
How the connection works
Your app and the Confidential Proxy stay on your machine. The Prem API Gateway sees only the sealed message. The Prem API Enclave opens it inside a Trusted Execution Environment (TEE).What you can connect
You can connect any client that lets you set a custom base URL. For example:- OpenAI SDKs for Node.js, Python, and other languages.
- Agent frameworks that support a custom OpenAI provider.
- Internal apps that call
/v1/chat/completions. - Audio apps that use the transcription or translation routes.
The client does not gain every OpenAI API feature. It gains the routes that the Confidential Proxy implements.
Supported routes
The inspected package implements these OpenAI-compatible routes:
The current Deepgram transcription response is not normalized to OpenAI’s
{ "text": "..." } shape. It returns Deepgram-style metadata and results fields.
Before you start
Get these four things ready:- An app that lets you set a custom OpenAI base URL.
- A Prem API key. This proves who you are. See API Keys.
- A client Key Encryption Key (KEK). This is a master key that protects your other keys.
- A model that your Prem account can use. See Models & Pricing.
The API key and the KEK are two different secrets. The API key handles sign-in, limits, and billing. The KEK protects your encryption keys. Keep both safe.
1. Set your secrets
Open a terminal. Set these values in the terminal that runs the proxy:PROXY_URL and ENCLAVE_URL show the current default endpoints. Check the Prem dashboard if the endpoints change.2. Start the Confidential Proxy
Start the proxy in OpenAI mode. Keep this terminal open while you work:http://127.0.0.1:8787/v1. Your app sends its requests there.
Do you need one proxy for both OpenAI and Anthropic apps? Start it in both mode:
both mode, the OpenAI base URL is http://127.0.0.1:8787/openai/v1.
3. Point your app at the proxy
List the models that your Prem API key can use:id value in later requests. Do not substitute an OpenAI model name unless Prem lists that exact ID.
The model list currently does not include a provider-backed or Reticle-verifiable assurance label. Do not infer one from the alias. See Platform Status for the current contract gap.
4. Test chat completions
Send a small non-streaming request:glm-5.2 when your account uses another model.
Inspect the response model field as well as the requested alias. A request for glm-5.2 currently returns the resolved ID zai-org/GLM-5.2.
Do not continue if this request fails. See Errors and Rate limits.
5. Configure the application
Change only the API key and base URL when the application already uses Chat Completions.glm-5.2 to a model your account can use. See your model IDs on the Prem dashboard.
Other clients name the base URL setting in different ways. Look for baseURL, base_url, endpoint, host, or provider URL.
What this setup protects
Good to know
Use a Prem model ID. Compatibility does not give you OpenAI-hosted models. Use a model that/v1/models returns.
One stream at a time. The encrypted endpoint allows one active stream for each API key. A second stream on the same key can return 429. Follow the Retry-After header when the response has one. See Agents & Automation.
Check the finish reason. Read finish_reason on each response. Do not treat a cut-off reply as a complete one.
Troubleshooting
The app still calls api.openai.com
The app still calls api.openai.com
Check the base URL setting. Restart the app after you change it.
The API says model not found
The API says model not found
List your models with
/v1/models. Use an enabled Prem model ID from that list.The app calls /v1/responses
The app calls /v1/responses
Set the app to use Chat Completions. The proxy does not expose the Responses API.
Streaming stops early
Streaming stops early
Check
finish_reason, timeout settings, proxy logs, and rate limits. Do not treat partial content as complete.The API returns 429
The API returns 429
Wait for the active request to finish. Follow
Retry-After when the response has it.Frequently asked questions
Does “OpenAI-compatible” mean OpenAI processes the request?
No. The term describes the HTTP interface only. The request goes through Prem and uses the Prem model you choose.Can I use an OpenAI model name?
Only when/v1/models returns that exact ID. Compatibility does not give you OpenAI-hosted models.
Can I use the Responses API?
No. Set the client to use/v1/chat/completions.
Which key goes in the Authorization header?
The Prem API key. The KEK is a separate local secret. Never send the KEK.Does changing the base URL protect my local tools?
No. It protects the model path after the proxy seals the request. Your local tools keep their own trust boundaries.Router
Beta An OpenAI-compatible Chat Completions client can call Router directly:
Confirm that
kimi-k3 appears in GET /v1/models for this key. Otherwise, use
an exact returned model ID. See Router models.
Related
Confidential Proxy
Review every mode, route, key, and daemon option.
OpenCode
Configure OpenCode as a specific OpenAI-compatible client.
OpenClaw
Configure a custom Chat Completions provider.
Hermes Agent
Use a named provider with the Chat Completions transport.
Goose
Point Goose’s built-in OpenAI provider at the proxy.
Anthropic-compatible clients
Use the Messages API shape through the same proxy.
Agents & Automation
Handle concurrency, retries, reasoning, and unattended operation.
Platform Status
Review current behavior and assurance gaps.

