Workspace (Public API)
Get and update workspace settings. Scoped to the API key’s workspace. GET returns id, name, rootFolderId, archiveFolderId (use archiveFolderId with GET /items/:id/items to list archived items). Placeholder: Update and branding/whitelabelling are not yet implemented.
Get workspace
GET /api/v2/workspace
Returns the workspace for the API key (id, name, rootFolderId, archiveFolderId). Use archiveFolderId with GET /items/:id/items to list archived items.
curl "https://api.markup.io/api/v2/workspace" \
-X GET \
-H "Authorization: Bearer <API-KEY-SECRET>" \
-H "Markup-API-Version: 2023-02-22" \
-H "Content-Type: application/json" {
"data": {
"id": "some id",
"name": "some name",
"rootFolderId": "some rootFolderId"
}
}Response Body - WorkspaceResponse
Create workspace
POST /api/v2/workspace
Create a new workspace in the API key’s organization. Only organization-scoped API keys can call this; workspace-scoped keys receive 403. Body: name (required). Returns 201 with WorkspaceResponse (id, name, rootFolderId, archiveFolderId).
curl "https://api.markup.io/api/v2/workspace" \
-X POST \
-H "Authorization: Bearer <API-KEY-SECRET>" \
-H "Markup-API-Version: 2023-02-22" \
-H "Content-Type: application/json" \
--data '{
"name": "My New Workspace"
}'{
"data": {
"id": "some id",
"name": "some name",
"rootFolderId": "some rootFolderId"
}
}Response Body - WorkspaceResponse
Request Body CreateWorkspacePublicRequest
| Option | Type | |
|---|---|---|
| name | string | Workspace display name. |
Update workspace
PATCH /api/v2/workspace
Update workspace name and/or slug. Pass workspaceId in query/body for org-scoped keys.
Body: { name?: string, slug?: string }. At least one required. Returns 200 with WorkspaceResponse.
curl "https://api.markup.io/api/v2/workspace" \
-X PATCH \
-H "Authorization: Bearer <API-KEY-SECRET>" \
-H "Markup-API-Version: 2023-02-22" \
-H "Content-Type: application/json" \
--data '{}'{
"data": {
"id": "some id",
"name": "some name",
"rootFolderId": "some rootFolderId"
}
}Response Body - WorkspaceResponse
Request Body UpdateWorkspacePublicRequest
| Option | Type | |
|---|---|---|
| name optional | string | |
| slug optional | string |
Delete workspace
DELETE /api/v2/workspace
Delete a workspace. Organization-scoped API keys can delete any workspace in the org (pass workspaceId in query or body). Workspace-scoped API keys can delete only the workspace they manage (no workspaceId needed). Returns 204 on success.
curl "https://api.markup.io/api/v2/workspace" \
-X DELETE \
-H "Authorization: Bearer <API-KEY-SECRET>" \
-H "Markup-API-Version: 2023-02-22" \
-H "Content-Type: application/json" 204 No ContentRelated types
WorkspaceResponse
| Option | Type | |
|---|---|---|
| id | string | |
| name | string | |
| rootFolderId | string |