{ "/budget/delete": { "post": { "tags": [ "budget management" ], "summary": "Delete Budget", "description": "Delete budget\n\nParameters:\n- id: str - The budget id to delete", "operationId": "delete_budget_budget_delete_post", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/BudgetDeleteRequest" } } }, "required": true }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } }, "security": [ { "APIKeyHeader": [] } ] } }, "/budget/info": { "post": { "tags": [ "budget management" ], "summary": "Info Budget", "description": "Get the budget id specific information\n\nParameters:\n- budgets: List[str] - The list of budget ids to get information for", "operationId": "info_budget_budget_info_post", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/BudgetRequest" } } }, "required": true }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } }, "security": [ { "APIKeyHeader": [] } ] } }, "/budget/list": { "get": { "tags": [ "budget management" ], "summary": "List Budget", "description": "List all the created budgets in proxy db. Used on Admin UI.", "operationId": "list_budget_budget_list_get", "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } } }, "security": [ { "APIKeyHeader": [] } ] } }, "/budget/new": { "post": { "tags": [ "budget management" ], "summary": "New Budget", "description": "Create a new budget object. Can apply this to teams, orgs, end-users, keys.\n\nParameters:\n- budget_duration: Optional[str] - Budget reset period (\"30d\", \"1h\", etc.)\n- budget_id: Optional[str] - The id of the budget. If not provided, a new id will be generated.\n- max_budget: Optional[float] - The max budget for the budget.\n- soft_budget: Optional[float] - The soft budget for the budget.\n- max_parallel_requests: Optional[int] - The max number of parallel requests for the budget.\n- tpm_limit: Optional[int] - The tokens per minute limit for the budget.\n- rpm_limit: Optional[int] - The requests per minute limit for the budget.\n- model_max_budget: Optional[dict] - Specify max budget for a given model. Example: {\"openai/gpt-4o-mini\": {\"max_budget\": 100.0, \"budget_duration\": \"1d\", \"tpm_limit\": 100000, \"rpm_limit\": 100000}}\n- budget_reset_at: Optional[datetime] - Datetime when the initial budget is reset. Default is now.", "operationId": "new_budget_budget_new_post", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/BudgetNewRequest" } } }, "required": true }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } }, "security": [ { "APIKeyHeader": [] } ] } }, "/budget/settings": { "get": { "tags": [ "budget management" ], "summary": "Budget Settings", "description": "Get list of configurable params + current value for a budget item + description of each field\n\nUsed on Admin UI.\n\nQuery Parameters:\n- budget_id: str - The budget id to get information for", "operationId": "budget_settings_budget_settings_get", "security": [ { "APIKeyHeader": [] } ], "parameters": [ { "name": "budget_id", "in": "query", "required": true, "schema": { "type": "string", "title": "Budget Id" } } ], "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } } } }, "/budget/update": { "post": { "tags": [ "budget management" ], "summary": "Update Budget", "description": "Update an existing budget object.\n\nParameters:\n- budget_duration: Optional[str] - Budget reset period (\"30d\", \"1h\", etc.)\n- budget_id: Optional[str] - The id of the budget. If not provided, a new id will be generated.\n- max_budget: Optional[float] - The max budget for the budget.\n- soft_budget: Optional[float] - The soft budget for the budget.\n- max_parallel_requests: Optional[int] - The max number of parallel requests for the budget.\n- tpm_limit: Optional[int] - The tokens per minute limit for the budget.\n- rpm_limit: Optional[int] - The requests per minute limit for the budget.\n- model_max_budget: Optional[dict] - Specify max budget for a given model. Example: {\"openai/gpt-4o-mini\": {\"max_budget\": 100.0, \"budget_duration\": \"1d\", \"tpm_limit\": 100000, \"rpm_limit\": 100000}}\n- budget_reset_at: Optional[datetime] - Update the Datetime when the budget was last reset.", "operationId": "update_budget_budget_update_post", "requestBody": { "content": { "application/json": { "schema": { "$ref": "#/components/schemas/BudgetNewRequest" } } }, "required": true }, "responses": { "200": { "description": "Successful Response", "content": { "application/json": { "schema": {} } } }, "422": { "description": "Validation Error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/HTTPValidationError" } } } } }, "security": [ { "APIKeyHeader": [] } ] } } }