The Workspace API allows you to access and manage workspace-level information in DMLY.
Use it to list available workspaces and fetch a workspace’s details by ID.
Base URLhttps://api.dmly.io/api
AuthenticationAll endpoints require the x-api-key header:
x-api-key: YOUR_API_KEY
Endpoints
List WorkspacesGET /v1/workspacesRetrieve a list of workspaces.
Response: 200 OK — Array of Workspace
Query ParametersName | In | Type | Required | Description |
limit | query | string | No | Max number of results |
page | query | string | No | Page number for pagination |
searchText | query | string | No | Free text search |
Example Requestcurl -X GET "https://api.dmly.io/api/v1/workspaces?page=1&limit=20&searchText=marketing" \
-H "x-api-key: YOUR_API_KEY"[
{
"id": "ws_001",
"title": "Marketing Team"
},
{
"id": "ws_002",
"title": "Sales Workspace"
}
]GET /v1/workspaces/{workspaceId}Retrieve a workspace by its unique ID.
Response: 200 OK — Workspace
Path ParametersName | In | Type | Required | Description |
workspaceId | path | string | Yes | Workspace unique ID |
Example Requestcurl -X GET "https://api.dmly.io/api/v1/workspaces/ws_001" \
-H "x-api-key: YOUR_API_KEY"{
"id": "ws_001",
"title": "Marketing Team"
}{
"id": "string",
"title": "string"
}[
{
// Workspace object
}
]Use searchText to support workspace pickers in your UI.
Paginate large results using page and limit.
Cache workspace lists server-side if your integration requests them frequently.
Store workspaceId and reuse it when calling Contacts, Messages, Broadcasts, Templates, and Segments endpoints.
Security NotesNever expose x-api-key in browser/frontend applications.
Restrict API key usage to server-side services.
Ensure the caller is authorized to access the requested workspace (especially in multi-tenant integrations).