Background
PR #3242 (sebuf migration) renamed five documented v1 URLs because the sebuf RPC path generator derives paths from method names:
| Legacy v1 URL |
New sebuf path |
POST /api/scenario/v1/run |
/api/scenario/v1/run-scenario |
GET /api/scenario/v1/status |
/api/scenario/v1/get-scenario-status |
GET /api/scenario/v1/templates |
/api/scenario/v1/list-scenario-templates |
GET /api/supply-chain/v1/country-products |
/api/supply-chain/v1/get-country-products |
GET /api/supply-chain/v1/multi-sector-cost-shock |
/api/supply-chain/v1/get-multi-sector-cost-shock |
To preserve the wire contract, #3242 added thin URL-rewrite alias files:
api/scenario/v1/{run,status,templates}.ts
api/supply-chain/v1/{country-products,multi-sector-cost-shock}.ts
Each file rewrites the pathname to the new sebuf path and delegates to the domain [rpc].ts gateway via server/alias-rewrite.ts. A matching alias table lives in vite.config.ts (V1_ALIASES) for dev parity.
What to do here
When either service bumps to v2 (i.e. the next breaking contract change):
- Delete the 5 alias files.
- Delete
server/alias-rewrite.ts if nothing else consumes it.
- Delete the
V1_ALIASES block in vite.config.ts.
- Update docs to the new-only paths.
Until then the aliases are harmless: they're pure URL rewrites, keyed on exact pathname, and premium/rate-limit/entitlement checks all fire on the canonical new path.
Why not now
The old URLs are in docs/api-scenarios.mdx, docs/panels/supply-chain.mdx, OpenAPI specs under docs/api/, and possibly partner scripts. Removing them is a v1→v2 break, not a silent follow-up.
Background
PR #3242 (sebuf migration) renamed five documented v1 URLs because the sebuf RPC path generator derives paths from method names:
POST /api/scenario/v1/run/api/scenario/v1/run-scenarioGET /api/scenario/v1/status/api/scenario/v1/get-scenario-statusGET /api/scenario/v1/templates/api/scenario/v1/list-scenario-templatesGET /api/supply-chain/v1/country-products/api/supply-chain/v1/get-country-productsGET /api/supply-chain/v1/multi-sector-cost-shock/api/supply-chain/v1/get-multi-sector-cost-shockTo preserve the wire contract, #3242 added thin URL-rewrite alias files:
api/scenario/v1/{run,status,templates}.tsapi/supply-chain/v1/{country-products,multi-sector-cost-shock}.tsEach file rewrites the pathname to the new sebuf path and delegates to the domain
[rpc].tsgateway viaserver/alias-rewrite.ts. A matching alias table lives invite.config.ts(V1_ALIASES) for dev parity.What to do here
When either service bumps to v2 (i.e. the next breaking contract change):
server/alias-rewrite.tsif nothing else consumes it.V1_ALIASESblock invite.config.ts.Until then the aliases are harmless: they're pure URL rewrites, keyed on exact pathname, and premium/rate-limit/entitlement checks all fire on the canonical new path.
Why not now
The old URLs are in
docs/api-scenarios.mdx,docs/panels/supply-chain.mdx, OpenAPI specs underdocs/api/, and possibly partner scripts. Removing them is a v1→v2 break, not a silent follow-up.