Reporting dashboards and targets
Delete a dashboard group
/a/ReportDashboardGroup_delete
Soft-delete a dashboard group and all of its active widgets.
When to use this endpoint
Select the saved widget or group from its corresponding list before deleting. Deletion retains records but removes them from active reads and reports. There is no reporting restore endpoint.
Authentication and permissions
Authenticate with signed API-key fields or a logged-in CRM session. All lookups and writes are tenant-local.
Only the group owner may manage its name, sharing/settings, or deletion. View/edit shares do not grant group-management rights. None disables its share array; otherwise string user IDs or All grant that share. No reporting-feature or additional CRM2 page-role check is applied.
For signed form requests, sign numeric scalar values as strings, including values inside native nested arrays. Send JSON text only for parameters explicitly accepting JSON strings; see Getting started.
These reporting handlers require tenant schema upgrade 794 before deployment. No request path creates or repairs schema.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
id | Integer-compatible | Yes | Positive integer ID in the authenticated tenant. Malformed, fractional, zero, or negative values are rejected; deleted records are unavailable. |
Example request
$result = FM_api('ReportDashboardGroup_delete', ['id'=> '12']);
Example response
{"ok":"1"}
Errors and unusual responses
| Response | Condition |
|---|---|
{"error":"not logged in"} | No authenticated tenant context is available. Invalid signed credentials can be rejected by the dispatcher before the handler runs. |
{"error":"missing or invalid parameter: id"} | Required id is absent or invalid. |
{"error":"no permission to access api"} | The group is not readable/editable, or the operation requires ownership and the caller is not its owner. |
{"error":"reporting write failed"} | A database write failed. Transactional operations roll back instead of returning success. |
{"error":"reporting deletion could not be recorded"} | The deletion audit failed; the entire soft deletion is rolled back. |
Legacy application errors may be returned with HTTP 200. Check the decoded response for error, not only the HTTP status.
Behaviour and edge cases
- Only the owner can delete an active group. Missing/deleted groups return an error.
- The group and all active widgets are retained with deleted=1, Unix deletion/edit timestamps, and individual tenant deletion audits. Already deleted widgets are not audited again.
- All changes commit in one transaction. Deleted groups/widgets disappear from selectors, embedding, detail reads, and rendering; there is no reporting restore endpoint.
Side effects
- Invalidates both caches and writes a group audit plus each child widget audit using the widget delete function. Audit failure rolls back the complete cascade. No history or notification is sent.
See it in Fieldmotion
CRM1
Delete the dashboard group from the report dashboard selector/editor. Filter browser Network requests for ReportDashboardGroup_delete.
CRM2
Use Delete on a classic or new dashboard-group list; the server does not enforce the UI’s edit permissions. Filter browser Network requests for ReportDashboardGroup_delete.
Related endpoints
ReportDashboardGroups_listfinds groups visible to the current user.ReportDashboards_listloads stored widget configuration.ReportDashboardGroup_setMetaedits group metadata and sharing.