When you send a request to OpenRouter without saying which provider should run it, OpenRouter picks one from every provider that hosts the model. That is the point of a router: one key, one bill, a fallback when a provider is down. It also means your prompt can land at a company you never chose.
On November 19, 2026, Dragos published the results of a five-month test. From July through November, its research team sent "approximately two million prompts containing unique URLs and canary token credentials to widely used AI services" and watched what happened next. According to the post, data from at least three AI providers was exposed, some of the stolen requests were marked Zero Data Retention, and AWS keys planted in prompts (real keys tied to empty accounts with full logging) were tested, in some cases within hours, and used for tens of thousands of AWS API calls. Dragos also reports that a Chinese AI lab's systems fetched the secret URLs from more than half of the prompts sent to its models, including roughly two-thirds of those marked "no data collection" or ZDR, and that prompts sent to U.S. providers reselling that lab's models triggered the same scraper. The post does not name the providers.
On November 22, OpenRouter posted that it had off-boarded three providers, removed 125 endpoints from ZDR eligibility (providers flagged by the researchers, plus endpoints removed as a precaution), and notified potentially affected customers. It says the findings "did not show any breach or unauthorized access of OpenRouter." It does not name the three providers. The post links security notices from eight providers. In one of them, dated November 24, MiniMax says its security system extracted URLs from requests that reached it directly from OpenRouter or through other providers, including Novita, Streamlake and Atlas Cloud, and then opened some of those URLs, including on requests marked ZDR or no data collection. MiniMax says it has disabled that process and found no evidence that prompt content or model responses were disclosed to third parties.
Dragos's advice for anyone using a router: "Pick the upstream providers yourself instead of accepting the default pool, and verify that your privacy settings actually change where your requests go." This guide does both, against the live API.
fetch against the live OpenRouter API: tiny chat requests with max_tokens at 20, two generation lookups, and the public endpoint and ZDR lists. The code and output below are copied from that run. The scripts print only the fields shown, and nothing in the output was edited. Everything run for this guide, including a few exploratory calls, cost about $0.00007 by the usage figures OpenRouter returned. Not run: any change to account privacy settings or guardrails (the account used was left as it was), the Sensitive Info guardrail, and anyone using a canary. Llama 3.1 8B and Tencent Hy4 Flash were picked because they are cheap and have several providers, not as recommendations.See where your requests go today
- Endpoint
- /api/v1/chat/completions
- Header
- X-OpenRouter-Metadata: enabled
- Result
- 4 candidates, 1 picked
Run on a Mac for this guide
Start by looking at what happens with no routing rules at all. Every response carries a provider field naming the provider that served it. Send the X-OpenRouter-Metadata: enabled header and the response also gets an openrouter_metadata object listing the endpoints that were candidates. OpenRouter's router metadata docs describe the header as a per-request opt-in for debugging and auditing routing.
export OPENROUTER_API_KEY=sk-or-v1-... # your key; never paste it into a prompt
node --version # v24.13.0 on the test MacOne file, no SDK, that sends a five-word prompt and prints where it went:
// or-check.mjs: send one tiny request through OpenRouter and print where it went.
// Usage: node or-check.mjs <model> ['<provider JSON>']
const [model, providerJson = "null"] = process.argv.slice(2);
const provider = JSON.parse(providerJson);
const res = await fetch("https://openrouter.ai/api/v1/chat/completions", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.OPENROUTER_API_KEY}`,
"Content-Type": "application/json",
"X-OpenRouter-Metadata": "enabled", // adds openrouter_metadata to the response
},
body: JSON.stringify({
model,
messages: [{ role: "user", content: "Reply with one word: ok" }],
max_tokens: 20,
...(provider && { provider }),
}),
});
const body = await res.json();
const meta = body.openrouter_metadata;
console.log("HTTP", res.status);
if (body.error) {
console.log("error:", body.error.message);
console.log("routing_funnel:", JSON.stringify(body.error.metadata?.routing_funnel));
} else {
console.log("id:", body.id);
console.log("provider:", body.provider);
console.log("summary:", meta?.summary);
console.log("candidates:", meta?.endpoints.available.map((e) => e.provider).join(", "));
console.log("cost:", body.usage.cost);
}$ node or-check.mjs meta-llama/llama-3.1-8b-instruct
HTTP 200
id: gen-1796062907-ZqbKYDLqSCp0YEB4L80s
provider: Groq
summary: available=4, selected=Groq
candidates: Groq, Amazon Bedrock, CoreWeave, DeepInfra
cost: 0.0000024255Four providers host this model, and the router picked Groq. OpenRouter's provider routing docs say default routing weighs each provider's effective price, throughput, time to first token, rate limits, reliability and tool-call quality, and that "each request picks one at random, weighted by those shares." So two identical requests can land at two different providers.
The candidates are not all alike. OpenRouter publishes the list of endpoints it treats as Zero Data Retention at GET /api/v1/endpoints/zdr. This script compares a model's endpoints with that list:
// zdr-endpoints.mjs: which endpoints of a model are on OpenRouter's ZDR list.
// Usage: node zdr-endpoints.mjs <model>
const model = process.argv[2];
const auth = { Authorization: `Bearer ${process.env.OPENROUTER_API_KEY}` };
const all = (await (await fetch(`https://openrouter.ai/api/v1/models/${model}/endpoints`)).json()).data.endpoints;
const zdr = (await (await fetch("https://openrouter.ai/api/v1/endpoints/zdr", { headers: auth })).json()).data;
const zdrTags = new Set(zdr.filter((e) => e.model_id === model).map((e) => e.tag));
for (const e of all) {
console.log(e.tag.padEnd(20), e.provider_name.padEnd(16), zdrTags.has(e.tag) ? "ZDR" : "not on the ZDR list");
}$ node zdr-endpoints.mjs tencent/hy4-flash
pearl-research/fp8 Pearl Research ZDR
fireworks Fireworks ZDR
deepinfra/fp4 DeepInfra ZDR
tencent/fp8 Tencent not on the ZDR list
$ node or-check.mjs tencent/hy4-flash
HTTP 200
id: gen-1796062908-asj6ma3uGxQJMCMtJ1Kj
provider: Tencent
summary: available=4, selected=Tencent
candidates: Tencent, Pearl Research, DeepInfra, Fireworks
cost: 0.0000074349For Tencent Hy4 Flash, three of four endpoints are on the ZDR list. With no rules, the router sent the request to the fourth one. That is what default routing is allowed to do when the request asks for nothing else: on this account, no privacy setting asked for ZDR either.
Pin providers and turn fallbacks off
- Fields
- order + allow_fallbacks: false
- Or
- only, ignore
- No match
- HTTP 404, no inference
Run on a Mac for this guide
The provider object in the request body controls routing. order lists the providers to try first, and allow_fallbacks: false stops the router from moving on to anyone else. The docs are explicit that order alone is not an allowlist: OpenRouter "will try them one at a time and proceed to other providers if none are operational."
{
"model": "meta-llama/llama-3.1-8b-instruct",
"messages": [{ "role": "user", "content": "Reply with one word: ok" }],
"max_tokens": 20,
"provider": {
"order": ["groq"],
"allow_fallbacks": false
}
}$ node or-check.mjs meta-llama/llama-3.1-8b-instruct '{"order":["groq"],"allow_fallbacks":false}'
HTTP 200
id: gen-1796062907-D3XraKOqNqHhgXem7Nj0
provider: Groq
summary: available=1, selected=Groq
candidates: Groq
cost: 0.0000025839One candidate instead of four. If Groq had been down, this request would have failed rather than gone elsewhere. That is the trade: the docs warn that restricting providers "may significantly reduce fallback options and limit request recovery." List two or three providers you have checked in order to keep some recovery.
only is the other allowlist. It restricts the pool, and if two or more of the allowed providers can serve the model, default routing picks among them. Ask for a provider that does not host the model and the request fails before any inference runs:
$ node or-check.mjs meta-llama/llama-3.1-8b-instruct '{"only":["openai"]}'
HTTP 404
error: No allowed providers are available for the selected model. Providers serving meta-llama/llama-3.1-8b-instruct: deepinfra, groq, amazon-bedrock, coreweave, but your request's provider.only preference permits only: openai.
routing_funnel: [{"step":"Initial Endpoints","endpoint_count":4}]ignore works the other way round. Ignoring Tencent's own endpoint for Hy4 Flash left three candidates:
$ node or-check.mjs tencent/hy4-flash '{"ignore":["tencent"]}'
HTTP 200
id: gen-1796062911-xStzLu6HHybww034XtnL
provider: DeepInfra
summary: available=3, selected=DeepInfra
candidates: DeepInfra, Pearl Research, Fireworks
cost: 0.0000074349Not run here
A base slug such as
deepinfra matches every endpoint of that provider, all variants and regions. Use the full slug, such as deepinfra/turbo, to target one. And when you set a non-empty order with fallbacks off, private endpoints your organization has access to stay eligible even if their provider is not in order. Without order, turning fallbacks off keeps only the top-ranked endpoint.Require ZDR on the request
- Field
- zdr: true
- Not the same
- data_collection: deny
- Effect here
- 4 candidates down to 3
Run on a Mac for this guide
zdr: true restricts a request to endpoints OpenRouter classifies as Zero Data Retention. The same Hy4 Flash request with it:
$ node or-check.mjs tencent/hy4-flash '{"zdr":true}'
HTTP 200
id: gen-1796062910-qTUmQsgkq1k8whUyWxhw
provider: Pearl Research
summary: available=3, selected=Pearl Research
candidates: Pearl Research, DeepInfra, Fireworks
cost: 0.0000052965Tencent's endpoint, the one not on the ZDR list, is gone from the candidates. Now the same request with data_collection: "deny", which the docs describe as "use only providers which do not collect user data":
$ node or-check.mjs tencent/hy4-flash '{"data_collection":"deny"}'
HTTP 200
id: gen-1796062913-TP9drXqz2jd9n5on2b6S
provider: DeepInfra
summary: available=4, selected=DeepInfra
candidates: DeepInfra, Pearl Research, Tencent, Fireworks
cost: 0.0000074349All four endpoints stayed candidates, Tencent's included. The docs define the default, allow, as allowing providers that "store user data non-transiently and may train on it." On this model, deny did not remove the endpoint that zdr removed. If your requirement is that prompts are not retained, ask for zdr.
Combine a pin with ZDR and the policy wins over the pin. The error lists every filter and what it removed:
$ node or-check.mjs tencent/hy4-flash '{"order":["tencent"],"allow_fallbacks":false,"zdr":true}'
HTTP 404
error: No endpoints found for tencent/hy4-flash. Every candidate endpoint was removed during routing: Filter by Data Policy removed tencent/fp8; Filter by Fallback removed pearl-research/fp8, fireworks, deepinfra/fp4.
routing_funnel: [{"step":"Initial Endpoints","endpoint_count":4},{"step":"Filter by Data Policy","endpoint_count":3},{"step":"Filter by Fallback","endpoint_count":0}]Not run here
From OpenRouter's ZDR docs.
zdr: true also admits Safety Retention endpoints, which "may retain prompts and responses from any request, only to prevent abuse" and do not train on them, unless your privacy settings or a guardrail are set to ZDR only. Self-serve accounts that have not chosen allow Safety Retention. ZDR enforcement covers model inference, not plugins and tools you enable, such as web search. OpenRouter does not count in-memory prompt caching as retention. And OpenRouter combines the request flag with your account and guardrail settings using OR, so a request can turn ZDR on but never off.Set the same rules for the account and each key
- Account
- Settings > Privacy
- Per key
- Guardrails
- Combine
- Strictest rule wins
Not run here
Request-level rules live in your code, and the one call that forgets the provider object gets default routing. Account and key settings catch that call. Nothing in this step was changed on the test account; it is from OpenRouter's privacy, provider routing and guardrails docs.
| Where | What you can set | What it covers |
|---|---|---|
| The provider object on a request | order, allow_fallbacks, only, ignore, zdr, data_collection, and more | That request only. A call that leaves it out gets default routing, within the limits below |
| Settings > Privacy (account) | Allowed providers, ignored providers, training opt-out, ZDR per model group, Safety Retention | Every API request and chatroom message. A request's only list narrows within the allowed list |
| A guardrail assigned to an API key or a member | Provider allowlist, model allowlist, ZDR per model group, Sensitive Info, budget | Only the keys or members it is assigned to. Allowlists intersect, so stricter rules win |
- Allowed providers in Settings > Privacy act as a ceiling. A request's
onlylist narrows within it, and if no provider satisfies both, the request fails with a 404. - Ignored providers in the same place are merged with any
ignorelist on a request. - Training: you can opt out of providers that may train on your data, with separate settings for paid and free models.
- ZDR can be enforced per model group: Anthropic, OpenAI, Google, SpaceXSI and all other models. For Google models and all other models you also choose ZDR only or Allow Safety Retention.
For limits per key, use a guardrail. Guardrails are created per workspace and can carry a provider allowlist, a model allowlist, ZDR per model group, the Sensitive Info filters and a budget. Assign one to an API key, or to a member so it covers all of their keys. When several apply, provider and model allowlists intersect, so a key guardrail can only narrow what a member guardrail allows. The docs add a warning worth repeating: "A guardrail enforces nothing until it is assigned." The dashboard shows an eligibility preview of the providers and models left after your account settings and the guardrail are combined.
provider object, can then only reach those providers. To see what a key can reach, the API has a models list filtered by your provider preferences, privacy settings and guardrails: GET /api/v1/models/user.sk-or-v1- keys, ghp_ tokens and AWS access key IDs, before the request reaches the provider. Its format list says it "does not use entropy-only detection", so a custom token format needs a custom regex pattern. Dragos recommends turning on secret filtering where it is offered, and adds: "This can't hurt, but it's not a panacea."Check which provider served each request
- On the response
- provider
- Afterwards
- GET /api/v1/generation?id=
- Dashboard
- Logs > Generations
Run on a Mac for this guide
Dragos's advice was to verify, not assume. There are three places to look. The provider field on every response, already printed above. The openrouter_metadata object when you send the header. And a lookup by the generation id after the fact, which returns provider_name and a provider_responses list with one entry per attempt, fallbacks included:
// which-provider.mjs: look up a finished request by its generation id.
// Usage: node which-provider.mjs <gen-id>
const id = process.argv[2];
const res = await fetch(`https://openrouter.ai/api/v1/generation?id=${encodeURIComponent(id)}`, {
headers: { Authorization: `Bearer ${process.env.OPENROUTER_API_KEY}` },
});
const { data, error } = await res.json();
if (error) {
console.log("HTTP", res.status, error.message);
process.exit(1);
}
console.log({
model: data.model,
provider_name: data.provider_name,
created_at: data.created_at,
total_cost: data.total_cost,
attempts: data.provider_responses?.map((r) => `${r.provider_name} HTTP ${r.status} ${r.latency} ms`),
});$ node which-provider.mjs gen-1796062910-qTUmQsgkq1k8whUyWxhw
{
model: 'tencent/hy4-flash-20261116',
provider_name: 'Pearl Research',
created_at: '2026-11-30T18:21:50.476Z',
total_cost: 0.000005296,
attempts: [ 'Pearl Research HTTP 200 1001 ms' ]
}This is the ZDR request from step 3, served by Pearl Research in one attempt. In an earlier run, a lookup sent straight after its request returned Generation ... not found with HTTP 404 for about nine seconds of retries; the same id worked a minute later. Wait before you look up, or retry.
In the dashboard, the Logs page shows the final provider for each generation, and its Upstream Requests tab lists every routing attempt, including retries and fallbacks. For your own records, store the id and provider of every response next to your own request id, and alert when provider is not one you allowed. That alert is the check that tells you a setting did not do what you thought.
Seed a canary
- Token
- Never valid anywhere
- Pinned to
- One provider
- Detection
- Your own logs
Run on a Mac for this guide
Routing rules decide where a prompt goes. They cannot show what happens to it there. Dragos's last recommendation covers that: "Add a fake credential to the context that your agents and pipelines already send and treat any use of it as an incident."
A canary is a string that exists in one prompt and nowhere else. This script makes one that is never a valid credential for anything, puts it in a test prompt next to a URL on a host you control, pins the request to one provider, and writes down where it went:
// canary.mjs: put a never-valid token and a URL on a host you control in a test
// prompt, pin it to one provider, and record exactly where it went.
// Usage: node canary.mjs <model> <provider-slug>
import { randomBytes } from "node:crypto";
import { appendFileSync } from "node:fs";
const [model, slug] = process.argv.slice(2);
const host = process.env.CANARY_HOST ?? "canary.example.com"; // replace with a host whose logs you read
const canary = `nlc_canary_${randomBytes(12).toString("hex")}`;
const prompt = `Staging notes. Dashboard: https://${host}/c/${canary} Token: ${canary}. Reply with one word: ok`;
const res = await fetch("https://openrouter.ai/api/v1/chat/completions", {
method: "POST",
headers: { Authorization: `Bearer ${process.env.OPENROUTER_API_KEY}`, "Content-Type": "application/json" },
body: JSON.stringify({
model,
messages: [{ role: "user", content: prompt }],
max_tokens: 20,
provider: { order: [slug], allow_fallbacks: false },
}),
});
const body = await res.json();
const record = { canary, model, requested: slug, served_by: body.provider, generation_id: body.id, at: new Date().toISOString() };
appendFileSync("canaries.jsonl", JSON.stringify(record) + "\n");
console.log("HTTP", res.status, record);$ node canary.mjs meta-llama/llama-3.1-8b-instruct groq
HTTP 200 {
canary: 'nlc_canary_2a0dfb9de12b170f67675df1',
model: 'meta-llama/llama-3.1-8b-instruct',
requested: 'groq',
served_by: 'Groq',
generation_id: 'gen-1796062914-Fx3aSwVyfxpmkoI7oCIE',
at: '2026-11-30T18:21:54.481Z'
}
$ node which-provider.mjs gen-1796062914-Fx3aSwVyfxpmkoI7oCIE
{
model: 'meta-llama/llama-3.1-8b-instruct',
provider_name: 'Groq',
created_at: '2026-11-30T18:21:54.409Z',
total_cost: 0.000004959,
attempts: [ 'Groq HTTP 200 19 ms' ]
}The run above used the placeholder host canary.example.com, so there is nothing to watch for that canary. With CANARY_HOST set to a subdomain whose logs you read, the record ties the canary to one model, one provider and one minute. Run it once per provider you allow, on a schedule, so a hit points at a route.
# On the host in CANARY_HOST: any request for a canary path means someone read the prompt.
grep -F "/c/nlc_canary_" /var/log/nginx/access.log
# Then find which request carried it:
grep -F "nlc_canary_2a0dfb9de12b170f67675df1" canaries.jsonlThe watch commands are an example and were not run here. If your own API ever sees a token that starts with nlc_canary_, treat that as the same alert: no real client has one.
Not run here
Dragos used real AWS keys tied to empty accounts with full logging, and suggests a free Thinkst Canarytoken as a start. This guide does not create real credentials in any account, and you do not need to: a URL on a host you own and a token no system accepts are enough to see a read. If you turn on the Secrets preset from step 4, a canary in a known format, such as an AWS-shaped key, would be redacted before it reaches the provider and would test nothing past OpenRouter. And as Dragos notes, a canary tells you that a prompt leaked, not where in the chain.
What none of this protects against
- A breach at a provider you picked. Dragos found stolen requests that were marked ZDR and writes: "A privacy flag doesn't help when the attacker is already inside."
- Hops after the first one. "A privacy flag only binds the first hop," according to Dragos. MiniMax's notice describes requests that reached it through other providers. OpenRouter says it is now "conducting technical verification of network paths to identify instances where requests and responses may be being forwarded to third parties."
- The labels themselves. OpenRouter's docs call its data policy tags "not a definitive source of third party data policies, but represents our best knowledge." The ZDR list in step 1 was fetched on November 30, after OpenRouter's removals, and can change again.
- OpenRouter as a hop. Your prompt still passes through OpenRouter. Its data collection docs say it does not store prompts or responses unless you opt in to logging or to OpenRouter using your data, or content is flagged as potential CSAM, and that it stores request metadata such as token counts and latency.
- What is in the prompt. None of these settings take a secret out of a prompt. Dragos's warning: "AI agents will happily send whatever they can read, including credentials." Keep keys out of the context an agent can see, and rotate any real credential that went into a prompt.
When to call the lab's API directly
Dragos's advice starts with three choices about where prompts go. Hosting the model yourself is "the only option where nobody else gets to read your prompts." Going directly to a first-tier provider means "one company, one contract, and one privacy policy to read," which Dragos calls "the smallest exposure you can buy." Routers come third, with care.
In practice: if a request carries customer data, source code or anything you could not afford to see in someone else's logs, and the model you use comes from one lab, call that lab's API with your own account. You lose the shared bill and automatic fallback, and you remove the router and the provider pool from the path. Keep OpenRouter for open-weight models, comparisons and work where a leak would cost little, with the allowlist from step 2 on every request.
Checklist
- Run
or-check.mjsfor each model you use and look at the candidates. - Send
providerwithorderandallow_fallbacks: false, oronly, on every request that carries user data. - Add
zdr: truewhere prompts must not be retained.data_collection: "deny"is not the same thing. - Set allowed providers, ignored providers and ZDR in Settings > Privacy. Pick ZDR only if Safety Retention is not acceptable to you.
- One key per product or job, each with an assigned guardrail. Check the eligibility preview.
- Store the
idandproviderof every response, and alert on a provider you did not allow. - Seed a canary per allowed provider and watch your logs for it.
- Reread OpenRouter's list of provider security announcements, which it says it will keep updated.
Not run here
Not run here
- Account privacy settings and guardrails. Nothing on the test account was changed, so the account and per-key behavior in step 4 is from OpenRouter's docs.
- The Sensitive Info guardrail and its Secrets preset.
- Detection of a canary being used. The canary in step 6 pointed at a placeholder host, and the log commands are an example.
- The incident itself. Nothing here tests whether any provider leaks data. The incident details are from the Dragos, OpenRouter and MiniMax posts linked below.
- Streaming responses, the Responses and Messages APIs, BYOK keys and private endpoints.
Sources
- Dragos, Three breaches, endless leaks: Your AI supply chain needs canaries (HD Moore, November 19, 2026)
- OpenRouter, Data Processing Incidents on Inference Providers (November 22, 2026), including its list of provider security announcements
- MiniMax, Update on URL Access in Forwarded API Requests (November 24, 2026)
- OpenRouter docs: Provider Routing, Zero Data Retention, Provider Logging, Data Collection, Guardrails, Sensitive Info Guardrail, Detected Secret Formats, Router Metadata, Logs
- OpenRouter API reference: Get request & usage metadata for a generation, Preview the impact of ZDR on the available endpoints, List models filtered by user provider preferences, privacy settings, and guardrails
Disclaimer: Nick Launches is not affiliated with OpenRouter, Dragos, MiniMax or any provider named here. Tested on one Mac on November 30, 2026, with Node.js 24.13.0 against the live OpenRouter API. Provider lists, ZDR status and routing results change over time and were current at the time of the run. The incident is described as stated in the Dragos, OpenRouter and MiniMax posts and was not reproduced for this guide.