List AI Gateway routers
GET
/__remote/api.vercel.com/v1/ai-gateway/routersList the authenticated team's active and archived custom routers.
/__remote/api.vercel.com/v1/ai-gateway/routers
const response = await fetch('/__remote/api.vercel.com/v1/ai-gateway/routers?ownerId=string&teamId=string&slug=string', { method: 'GET', headers: { 'Authorization': 'Bearer YOUR_ACCESS_TOKEN', 'Content-Type': 'application/json', },});
const data = await response.json();console.log(data);Response
{ "routers": [ { "allowFallbackFromFast": "false", "baseUrl": "https://example.com", "byokCredentialIds": [], "caching": "auto", "createdAt": "123", "createdBy": "string", "deleted": "false", "description": "string", "disallowPromptTraining": "false", "displayName": "Example Name", "has": [], "hipaaCompliant": "false", "inferenceRegion": { "geoRegion": "string", "providerRegion": "example_id", "providers": "value", "scope": "global" }, "instanceId": "example_id", "kind": "string", "models": [], "modelSlug": "string", "observabilityTags": [], "ownerId": "example_id", "providerOnly": [], "providerOptions": "value", "providerOrder": [], "providerTimeouts": { "byok": "value" }, "selector": "cost", "selectorOptions": { "cost": "value", "tps": "value", "ttft": "value" }, "serviceTier": "fast", "sort": "cost", "speed": "fast", "status": "string", "updatedAt": "123", "updatedBy": "string", "virtualModelSlug": "string", "visibility": "string", "zeroDataRetention": "false" } ]}AuthorizationbearerToken
Default authentication mechanism
The owner (team) ID to list routers for. Only trusted-origin callers use this. Public callers select their team with
teamId or slug, and a supplied ownerId never overrides the authenticated team.