Workspaces API Guide
Learn how to manage workspaces using the Wacht Rust SDK.Prerequisites
Before using any API methods, you must initialize the SDK:List Workspaces
Retrieve a paginated list of workspaces from your deployment.Basic List
With Pagination and Filters
Builder Methods
limit(i32)- Number of results to return (max 100)offset(i32)- Number of results to skipsearch(&str)- Search query to filter resultssort_key(&str)- Field to sort bysort_order(&str)- Sort order (“asc” or “desc”)
Get Workspace Details
Retrieve complete information about a workspace.Create Workspace
Create a new workspace in your deployment.Basic Workspace Creation
With Optional Fields
Required Fields
name(String) - Workspace name
Optional Fields
description(Option<String>) - Workspace descriptionpublic_metadata(Option<serde_json::Value>) - Public metadataprivate_metadata(Option<serde_json::Value>) - Private metadataworkspace_image(Option<Vec<u8>>) - Workspace image data
Update Workspace
Update an existing workspace’s information. Only provided fields will be updated.Available Update Fields
All fields are optional - only include what you want to change:name(Option<String>)description(Option<String>)public_metadata(Option<serde_json::Value>)private_metadata(Option<serde_json::Value>)workspace_image(Option<Vec<u8>>)
Delete Workspace
Permanently delete a workspace. This action cannot be undone.Manage Workspace Members
List Members
Add Member
Update Member
Remove Member
Manage Workspace Roles
List Roles
Create Role
Update Role
Delete Role
Error Handling
All SDK methods return aResult<T, Error>:
Related
- Installation - SDK setup
- Organizations Guide - Managing organizations
- Users Guide - Managing users
- API Reference - Backend API - Full API docs
