Update data dashboard¶
Updates the name, description, and data source of the specified data dashboard.
PATCH $CLOUDSIGMA_API_BASE/data-dashboards/{dashboard_id}
Before you call¶
Configure the CloudSigma regional endpoint and authentication before calling. The endpoint, credentials, workspace, and resource IDs must belong to the same region. First select the data dashboard to be updated in Query Data Kanban List.
Prepare personal access token and target workspace ID that can access the target workspace.
Request body¶
Replace $DASHBOARD_ID, $CLOUDSIGMA_API_KEY, $WORKSPACE_ID in the example with actual values.
curl -X PATCH "$CLOUDSIGMA_API_BASE/data-dashboards/$DASHBOARD_ID" \
-H "X-API-Key: $CLOUDSIGMA_API_KEY" \
-H "X-Workspace-ID: $WORKSPACE_ID" \
-H "Content-Type: application/json" \
-d '{
"name": "销售概览",
"description": "更新后的说明",
"sources": [
{
"table_id": 1001
}
]
}'
Parameter |
Type |
Required |
Description |
|---|---|---|---|
|
string |
Yes |
Data dashboard ID. |
Request body
Field |
Type |
Required |
Description |
|---|---|---|---|
|
string |
Yes |
Data dashboard name. Cannot be empty. |
|
string |
No |
Data dashboard description. Saves as an empty string when omitted. |
|
array of object |
Yes |
List of data sources. At least 1 items. |
|
integer |
When the object is provided |
Table ID. Not less than 1. |
sources Fill in the valid positive int64 table ID. After service deduplication, check the permissions item by item in the table. Kanban permissions are not a substitute for actual SQL permissions.
The complete name and sources still need to be submitted when updating. sources will be replaced as a whole, and omitting description will clear the description. If the ownership registration fails after creation, the kanban board may have been created. Please check and confirm first.
Successful response¶
{
"code": "OK",
"msg": "OK",
"data": {
"updated": true
}
}
Field |
Type |
Description |
|---|---|---|
|
boolean |
Has it been updated? Fixed to true. |
Error response¶
The following example corresponds to HTTP 400.
{
"code": "ErrParamInvalid",
"msg": "Bad Request"
}
Field |
Type |
Description |
|---|---|---|
|
string |
Error code, such as |
|
string |
HTTP status description, such as |
The data source is still referenced by the chart¶
Deleting a data source that is still referenced by the chart returns HTTP 409, using the following separate error structure.
Field |
Type |
Description |
|---|---|---|
|
integer |
This conflict is |
|
string |
Localized error messages. |
|
string |
|
|
string |
|
|
string |
Request ID. Returns if not empty. |
|
array of object |
The datasheet is still referenced. |
|
integer |
Table ID. |
|
string |
Database name. |
|
string |
Table name. |
|
array of object |
A chart that references this table. |
|
string |
Chart ID. |
|
string |
Chart name. |