Dashboards API
Create and Manage dashboards via the Semaphor Management API
Overview
The Dashboards API allows you to create, retrieve, update, delete, duplicate, and share dashboards programmatically.
Base path:
All endpoints require authentication and permission checks.
Example: Create a Dashboard via API
1. Get a project token
2. Create a dashboard
Expected Response:
Duplicate Dashboard
POST /dashboards/:id/duplicate
- Duplicates an existing dashboard, including its template and properties.
- The new dashboard will have a new ID, and you can optionally override the title and description.
Request Body (optional):
If no body is provided, the duplicate will have the original title with "(Copy)" appended and the same description.
Example Request:
Example Response:
Get Dashboard by ID
GET /dashboards/:id
- Returns details for a specific dashboard, including permissions.
Example Request:
Example Response:
Update Dashboard
PUT /dashboards/:id
- Updates dashboard fields (title, description, template, isPrivate, isPublic, version, tenantId).
Request Body:
Example Request:
Example Response:
Delete Dashboard
DELETE /dashboards/:id
- Deletes a dashboard by ID.
Example Request:
Example Response:
Share Dashboard
POST /dashboards/:id/share
- Shares a dashboard with users or groups.
Request Body:
scope
options:specific_tenant_user
,all_tenant_users
,specific_org_user
,all_org_users
,org_users_only
,all_tenants_only
role
options:VIEWER
,EDITOR
,CONTRIBUTOR
Example Request:
Example Response:
Remove Dashboard Shares
DELETE /dashboards/:id/share
- Removes sharing permissions for specified users/groups.
Request Body:
Example Request:
Example Response:
Error Handling
- All endpoints return standard error responses with appropriate HTTP status codes (400, 401, 403, 404, 500, etc.).
- Validation errors return details in the response body.
Notes
- All endpoints require authentication (Bearer token).
- Permission checks are enforced for all operations.
- Sharing supports granular roles and scopes for flexible access control.