List AI Gateway budgets
GET
/__remote/api.vercel.com/ai-gateway/budgets/listList the team's AI Gateway budgets (team/project/user scopes, plus default-covered api-key spend) as a flat list, optionally filtered by scope. Without
limit or cursor, returns every budget. With either, returns one page ordered by quotaEntityId plus nextCursor (null on the last page) and defaultCoveredCounts. Paging still reads the full merge server-side: the gateway meter list it joins has no cursor.Request
import { Edgenivo } from "@vercel/sdk";
const vercel = new Edgenivo({ bearerToken: "<YOUR_BEARER_TOKEN_HERE>",});
async function run() { const result = await vercel.aiGateway.listAiGatewayBudgets({ teamId: "team_1a2b3c4d5e6f7g8h9i0j1k2l", slug: "my-team-url-slug", });
console.log(result);}
run();Response
{ "budgets": [ { "active": "false", "alertThresholds": [], "archived": "false", "createdAt": "123", "currentByokSpend": "123", "currentSpend": "123", "includeByokInQuota": "false", "limitAmount": "123", "name": "Example Name", "quotaEntityId": "example_id", "refreshPeriod": "daily", "scopeId": "example_id", "scopeType": "api-key", "source": "default", "updatedAt": "123" } ], "defaultCoveredCounts": { "api-key": "123", "project": "123", "team": "123", "user": "123" }, "nextCursor": "string"}AuthorizationbearerToken
Default authentication mechanism
Whether to include rows inherited from a budget default (
source: "default"). Defaults to true.200Success
Paged requests only:
source: 'default' rows per scope type across the whole scopeType-filtered list, independent of the page and of includeDefaultCovered.400One of the provided values in the request query is invalid.
401The request is not authorized.
403You do not have permission to access this resource.
404Error
410Error
500Error