Projects
/v1/projects creates and maintains projects, each with its own routing policy, budget, and usage reporting. All endpoints need the manage_projects scope.
Create a project
POST /v1/projects returns 201 with the project object. Only name (up to 255 characters) is required.
Gateway derives slug from the name (Internal Tools becomes internal-tools), appending -2, -3, and so on on collision. The API doesn’t accept slug; change it in the dashboard. The project object has id, organization_id, name, slug, description, is_active, uses_organization_default_routing, routing_policy, budget_config, created_at, and updated_at (types).
List and get projects
GET /v1/projects returns up to limit projects (default 20, max 100), oldest first, in a {results, next, previous} envelope. While next isn’t null, pass it as cursor for the next page.
A project in another organization returns 404.
Update a project
PATCH /v1/projects/{project_id} changes only the fields you send: name, description, is_active, budget_config, uses_organization_default_routing, and routing_policy. name and is_active can’t be null: sending null returns 422, so omit a field to keep it. "description": null clears the description.
Setting is_active to false doesn’t stop traffic: requests naming the project are still served, but its guardrail overrides stop applying and new project API keys are blocked.
Delete a project
DELETE /v1/projects/{project_id} returns 204 and also deletes the project’s routing policy and budget.
While active project API keys exist, delete returns 409 PROJECT_HAS_ACTIVE_API_KEYS with their count; revoke them first. If Gateway can’t confirm there are no live keys, it returns 503 and deletes nothing, so retry.