# Delete data dashboard

Delete the specified data dashboard and its configuration. This operation is irreversible.

```text
DELETE https://moi.matrixorigin.cn/newmoi/data-dashboards/{dashboard_id}
```

## Preparation before calling

Prepare a personal access token and target workspace ID that has access to the target workspace.

The example below uses:

- `$AI_STUDIO_API_KEY`: The actual personal access token, passed through the `X-API-Key` Header.
- `$WORKSPACE_ID`: Target workspace ID, passed through `X-Workspace-ID` Header.

- `$DASHBOARD_ID`: `dashboard_id` to use, specifying the target resource via the request path.

## Call example

```bash
curl -X DELETE "https://moi.matrixorigin.cn/newmoi/data-dashboards/$DASHBOARD_ID" \
  -H "X-API-Key: $AI_STUDIO_API_KEY" \
  -H "X-Workspace-ID: $WORKSPACE_ID"
```

## Path parameters

| Parameters | Type | Is it required | Description |
| --- | --- | --- | --- |
| `dashboard_id` | string | Yes | Data dashboard ID. |
## Successful response

When the deletion is successful, `data.deleted` in the response is `true`.

```json
{
  "code": 0,
  "data": {"deleted": true}
}
```

The response fields are as follows.

| Field | Type | Description |
| --- | --- | --- |
| `data.deleted` | boolean | Whether it has been deleted. |

## Error response

::::{div} mo-api-split
:::{div} mo-api-split-main
```{raw} html
<dl class="mo-api-fields">
<div class="mo-api-field"><dt><code>code</code><span class="mo-api-field__type">integer or string</span></dt><dd>Error code or status.</dd></div>
<div class="mo-api-field"><dt><code>message</code><span class="mo-api-field__type">string</span></dt><dd>Error message.</dd></div>
</dl>
```
:::
:::{div} mo-api-split-aside
```{raw} html
<p class="mo-api-example-label">Error response example</p>
```
```json
{
  "code": 3,
  "message": "not found",
  "details": {
    "domain": "moi-core.catalog.data_dashboard",
    "reason": "DATA_DASHBOARD_NOT_FOUND"
  }
}
```
:::
::::
