Overview
Workspaces in Mudstack are containers that organize and manage assets, libraries, tags, and other entities. Each workspace belongs to a specific account and is isolated from other workspaces. This means that all content within a workspace is accessible only through that workspace and cannot be shared across workspaces.Key Concepts
Headers
To interact with a workspace, you must include the following headers in every API request:- x-workspace-id: The unique identifier of the workspace.
- x-account-id: The unique identifier of the account to which the workspace belongs.
Entities Within a Workspace
Workspaces contain several entities, each with its own sub-entities. These include:- Assets: Files, images, videos, or other digital content. Assets can have versions, tags, comments, and attachments.
- Libraries: Collections of assets grouped together for better organization.
- Tags: Metadata used to categorize and search for assets.
- Members: Users who have access to the workspace, with specific roles and permissions.
- Settings: Configuration options for the workspace.
- History: Logs of actions performed within the workspace.
Common API Endpoints
Below are some common endpoints for interacting with workspaces:Workspace Management
- Create a Workspace: POST /workspaces
- Get Workspace Details: GET /workspaces
- Update Workspace Details: PUT /workspaces
- Delete a Workspace: DELETE /workspaces
Member Management
- Get Workspace Members: GET /workspaces/members
- Add Account Member to Workspace: POST /workspaces/members/{user_id}
- Remove Member from Workspace: DELETE /workspaces/members/{user_id}
Asset Management
- To learn more about managing assets, see our Assets Documentation
Folder Management
- Create a Folder: POST /workspaces/folders
- Get a Folder: GET /workspaces/folders/{folder_id}
- Move a Folder: PUT /workspaces/folders/{folder_id}
- Delete a Folder: DELETE /workspaces/folders/{folder_id}
- Get folder hierarchy: GET /workspaces/folders/hierarchy
Library Management
- Get All Libraries: GET /workspaces/libraries
- Create a Library: POST /workspaces/libraries
- Update a Library: PUT /workspaces/libraries/{library_id}
- Delete a Library: DELETE /workspaces/libraries/{library_id}
Tag Management
- Get All Tags: GET /workspaces/tags
- Create Tags: POST /workspaces/tags
- Delete Tag: DELETE /workspaces/tags/{tag_id}
Tasks
- Create a new task: POST /workspaces/tasks
- Get a specific task: GET /workspaces/tasks/{task_id}
- Update a task: PUT /workspaces/tasks/{task_id}
- Delete a task: DELETE /workspaces/tasks/{task_id}
Settings Management
- Get Workspace Settings: GET /workspaces/settings
- Update Workspace Settings: PUT /workspaces/settings
Example Request
Here is an example of how to retrieve the details of a workspace:Notes
- Ensure that the
x-workspace-id
andx-account-id
headers are included in every request to avoid authorization errors. - Workspaces are isolated, so entities like assets, libraries, and tags cannot be accessed outside their respective workspace.