Overview
Workspaces endpointsAvailable Operations
- list - List workspaces
- create - Create a workspace
- delete - Delete a workspace
- get - Get a workspace
- update - Update a workspace
- listMembers - List workspace members
- bulkAddMembers - Bulk add members to a workspace
- bulkRemoveMembers - Bulk remove members from a workspace
- listBudgets - List workspace budgets
- deleteBudget - Delete a workspace budget
- getBudget - Get a workspace budget
- setBudget - Create or update a workspace budget
list
List all workspaces for the authenticated user. Management key required.Example Usage
Standalone function
The standalone function version of this method:Parameters
Response
Promise<operations.ListWorkspacesResponse>Errors
create
Create a new workspace for the authenticated user. Management key required.Example Usage
Standalone function
The standalone function version of this method:Parameters
Response
Promise<models.CreateWorkspaceResponse>Errors
delete
Delete an existing workspace. Workspaces with active API keys cannot be deleted; remove the keys first. Deleting the default workspace requires confirm_default_workspace_deletion=true. Deleting any workspace permanently deletes its budgets and guardrails and disables its classifiers and broadcast destinations. Management key required.Example Usage
Standalone function
The standalone function version of this method:Parameters
Response
Promise<models.DeleteWorkspaceResponse>Errors
get
Get a single workspace by ID or slug. Management key required.Example Usage
Standalone function
The standalone function version of this method:Parameters
Response
Promise<models.GetWorkspaceResponse>Errors
update
Update an existing workspace by ID or slug. Management key required.Example Usage
Standalone function
The standalone function version of this method:Parameters
Response
Promise<models.UpdateWorkspaceResponse>Errors
listMembers
List all members of a workspace. Returns paginated results. For the default workspace, returns all organization members (implicit membership). Management key required.Example Usage
Standalone function
The standalone function version of this method:Parameters
Response
Promise<operations.ListWorkspaceMembersResponse>Errors
bulkAddMembers
Add multiple organization members to a workspace. New members are assigned the workspace role that matches their organization role. Users who are already members of the workspace keep their current role and are not included in the response. Management key required.Example Usage
Standalone function
The standalone function version of this method:Parameters
Response
Promise<models.BulkAddWorkspaceMembersResponse>Errors
bulkRemoveMembers
Remove multiple members from a workspace. Members with active API keys in the workspace cannot be removed. SCIM-managed members cannot be removed; changes must be made in your identity provider. Management key required.Example Usage
Standalone function
The standalone function version of this method:Parameters
Response
Promise<models.BulkRemoveWorkspaceMembersResponse>Errors
listBudgets
List all budgets configured for a workspace. Management key required.Example Usage
Standalone function
The standalone function version of this method:Parameters
Response
Promise<models.ListWorkspaceBudgetsResponse>Errors
deleteBudget
Remove the budget for a given interval. Management key required.Example Usage
Standalone function
The standalone function version of this method:Parameters
Response
Promise<models.DeleteWorkspaceBudgetResponse>Errors
getBudget
Retrieve the budget for a given interval. Management key required.Example Usage
Standalone function
The standalone function version of this method:Parameters
Response
Promise<models.GetWorkspaceBudgetResponse>Errors
setBudget
Create or update the budget for a given interval. Budget limits must strictly decrease as the interval narrows (lifetime > monthly > weekly > daily). The optionalinclude_byok_in_budgets flag is a workspace-wide setting: when provided it applies to every budget interval for the workspace, not just the interval in this request. Note that a change made here is applied to budget enforcement immediately, but an already-open workspace settings page in the web dashboard may keep showing the previous value until it is reloaded. Management key required.