scientific-skills/protocolsio-integration/references/workspaces.md
Workspaces in protocols.io enable team collaboration by organizing protocols, managing members, and controlling access permissions. The Workspaces API allows you to list workspaces, manage memberships, and access workspace-specific protocols.
All workspace endpoints use the base URL: https://protocols.io/api/v3
Retrieve all workspaces the authenticated user has access to.
Endpoint: GET /workspaces
Query Parameters:
page_size: Number of results per page (default: 10, max: 50)page_id: Page number for pagination (starts at 0)Response includes:
Example Request:
curl -H "Authorization: Bearer YOUR_TOKEN" \
"https://protocols.io/api/v3/workspaces"
Retrieve detailed information about a specific workspace.
Endpoint: GET /workspaces/{workspace_id}
Path Parameters:
workspace_id: The workspace's unique identifierResponse includes:
Retrieve all members of a workspace.
Endpoint: GET /workspaces/{workspace_id}/members
Query Parameters:
page_size: Number of results per pagepage_id: Page number for paginationResponse includes:
Request to join a workspace.
Endpoint: POST /workspaces/{workspace_id}/join-request
Request Body:
message (optional): Message to workspace admins explaining the requestExample Request:
curl -X POST \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"message": "I am collaborating with Dr. Smith on the CRISPR project and would like to access the shared protocols."
}' \
"https://protocols.io/api/v3/workspaces/12345/join-request"
Directly join a public workspace without approval.
Endpoint: POST /workspaces/{workspace_id}/join
Note: Only available for workspaces configured to allow public joining
Retrieve all protocols in a workspace.
Endpoint: GET /workspaces/{workspace_id}/protocols
Query Parameters:
filter: Filter protocols
all: All protocols in the workspaceown: Only protocols you createdshared: Protocols shared with youkey: Search keywordsorder_field: Sort field (activity, created_on, modified_on, name)order_dir: Sort direction (desc, asc)page_size: Number of results per pagepage_id: Page number for paginationcontent_format: Content format (json, html, markdown)Example Request:
curl -H "Authorization: Bearer YOUR_TOKEN" \
"https://protocols.io/api/v3/workspaces/12345/protocols?filter=all&order_field=modified_on&order_dir=desc"
Create a new protocol within a specific workspace.
Endpoint: POST /workspaces/{workspace_id}/protocols
Request Body: Same parameters as standard protocol creation (see protocols_api.md)
Note: The protocol will be created within the workspace and inherit workspace permissions
Personal Workspace
Group Workspace
Institutional Workspace
Owner
Admin
Member
Viewer
Organize lab protocols in a shared workspace:
GET /workspacesGET /workspaces/{id}/protocolsPOST /workspaces/{id}/protocolsDevelop protocols with team members:
GET /workspacesWork with external collaborators:
POST /workspaces/{id}/join-requestMove protocols between workspaces:
GET /workspaces/{source_id}/protocolsPOST /workspaces/{target_id}/protocolsReview workspace activity and content:
GET /workspacesOrganization
Access Control
Protocol Standards
Collaboration
Backup and Archival
Organizations are higher-level entities that can contain multiple workspaces.
Endpoint: GET /organizations/{org_id}/export
Use case: Bulk export of all protocols and workspace data for institutional archives or backups
Workspace activity may trigger notifications:
Configure notification preferences in account settings.
Common error responses:
400 Bad Request: Invalid workspace ID or parameters401 Unauthorized: Missing or invalid access token403 Forbidden: Insufficient workspace permissions404 Not Found: Workspace not found or no access429 Too Many Requests: Rate limit exceededWhen integrating workspace functionality: