Stripe confirmed its acquisition of OpenRouter on August 19, 2026. An acquisition does not require an immediate cutover, but it is a useful time to test a second gateway and document a config-only rollback path.
What changes
The migration has four parts:
- Keep payload shape unchanged.
- Swap base URL and API key source.
- Verify model IDs and any OpenRouter-only headers.
- Roll traffic gradually while comparing latency, output, and cost behavior.
Before you start
- Access to the current OpenRouter integration code and deployment config.
PHASEO_API_KEYavailable in dev, staging, and production.- A short list of production model IDs and representative prompts.
1) Inventory current OpenRouter usage
Start by identifying every place OpenRouter is referenced: endpoint URLs, keys, model IDs, and any provider-specific headers.- Find
openrouter.aiendpoint references. - Find
OPENROUTER_API_KEYusage in code, CI, and hosting env vars. - Find OpenRouter-only headers such as
HTTP-RefererandX-Title. - Document active model IDs and any fallback-chain logic.
- Document any reusable prompt, provider, or parameter defaults that should move into Gateway presets instead of staying duplicated in application code.
2) Swap base URL and credentials
Keep request payload shape unchanged first. Do behavior parity before optimization.3) Validate model IDs and map OpenRouter-only behavior
Do not assume every previous alias is valid. Query/v1/models and verify each production model ID.
- Keep
Authorization: Bearerformat unchanged. - Keep
HTTP-RefererandX-Titlewhen they identify the calling application. Phaseo accepts the lowercase equivalentshttp-refererandx-title. - If callers depend on OpenRouter-only response fields, adapt them in one compatibility layer instead of changing every caller.
- If your OpenRouter setup relies on provider allow/deny lists or routing defaults, map those into Presets and Routing and Fallbacks instead of scattering them across callers.
Map provider controls
Several common provider controls have direct Phaseo equivalents:
Phaseo also supports
provider.required_execution_region and provider.required_data_region when a workload needs regional controls. See Pin or ignore providers and Route only to EU or ZDR-capable providers for complete requests.
4) OpenRouter parity checklist
Use this checklist before shifting meaningful traffic:- Base URL updated to
https://api.phaseo.app/v1. OPENROUTER_API_KEYreplaced withPHASEO_API_KEYin all environments.- All production model IDs verified against
/v1/models. - One non-streaming request validated through
/v1/chat/completionsor/v1/responses. - One streaming request validated through the same app-level integration path used in production.
- Generation lookups rechecked through
GET /v1/generations?id=<request_id>so failed requests can be replayed from the storedreplay_requestpayload whenreplay_supported=true. - Tool-calling and structured-output flows rechecked with real prompts.
- Invalid-key and invalid-model failures verified in staging.
- Any OpenRouter-only headers or response fields either removed or explicitly normalized.
- Shared prompt/routing defaults moved into presets where appropriate.
Agent migration checklist
Give a coding agent this bounded sequence:- Search runtime code and deployment config for
openrouter.ai,OPENROUTER_API_KEY,sk-or-v1,HTTP-Referer, andX-Title. - Change the client boundary to
https://api.phaseo.app/v1andPHASEO_API_KEYwithout adding a secret value to source control. - Query
GET /v1/modelsand record every old-to-new model mapping. - Adapt OpenRouter-only routing options or response fields in one compatibility module.
- Run the health, models, non-streaming, streaming, and failure-path checks below.
- Report changed files, secret-name changes, model mappings, test evidence, parity gaps, and the rollback switch.
5) Roll out safely
Use a staged rollout: dev first, then a small production slice, then full traffic once metrics are stable.- Start with internal traffic only.
- Move to 5-10% production traffic and compare quality, latency, and cost metrics.
- Promote to 100% only after parity is confirmed.
- Keep rollback as a config-only endpoint/key switch until the cutover is stable.
Validation commands
- Run one streaming request through your app-level integration test.
- Run one negative test for invalid key or invalid model.
- Replay a small golden prompt set and compare outputs to baseline.