Get all workspaces
GET {{baseUrl}}/workspaces
Gets all [workspaces] The response includes your workspaces and any workspaces that you have access to.
Note:
This endpoint's response contains the visibility field. [Visibility] determines who can access the workspace:
- personal— Only you can access the workspace.
- team— All team members can access the workspace.
- private— Only invited team members can access the workspace ([Professional and Enterprise plans only]
- public— Everyone can access the workspace.
- partner— Only invited team members and [partners] can access the workspace ([Professional and Enterprise plans only]
Request Params
| Key | Datatype | Required | Description | 
|---|---|---|---|
| type | string | The type of workspace to filter the response by: | 
- personal
- team
- private
- public
- partner| |- include| string | | Include the following information in the endpoint's response:
- mocks:deactivated— Include all deactivated mock servers in the response.
- scim— Return the SCIM user IDs of the workspace creator and who last modified it. | |- createdBy| string | | Return only workspaces created by a specific user ID. For multiple users, pass this value as a comma-separated list of user IDs. The response only returns workspaces that you have access to. |
RESPONSES
status: OK
"{\n    \"workspaces\": [\n        {\n            \"id\": \"a0f46158-1529-11ee-be56-0242ac120002\",\n            \"name\": \"Test Workspace\",\n            \"createdBy\": \"12345678\",\n            \"type\": \"team\",\n            \"visibility\": \"private\"\n        },\n        {\n            \"id\": \"f8801e9e-03a4-4c7b-b31e-5db5cd771696\",\n            \"name\": \"Teamwork\",\n            \"createdBy\": \"12345678\",\n            \"type\": \"team\",\n            \"visibility\": \"team\"\n        },\n        {\n            \"id\": \"74dbfab8-1529-11ee-be56-0242ac120002\",\n            \"name\": \"Public Examples\",\n            \"createdBy\": \"87654321\",\n            \"type\": \"team\",\n            \"visibility\": \"public\"\n        },\n        {\n            \"id\": \"74dbfab8-1529-11ee-be56-0242ac120002\",\n            \"name\": \"Partner Workspace\",\n            \"createdBy\": \"87654321\",\n            \"type\": \"team\",\n            \"visibility\": \"partner\"\n        },\n        {\n            \"id\": \"1f0df51a-8658-4ee8-a2a1-d2567dfa09a9\",\n            \"name\": \"My Workspace\",\n            \"createdBy\": \"56784321\",\n            \"type\": \"personal\",\n            \"visibility\": \"personal\"\n        },\n    ]\n}"