View dashboard chart result¶
Read the latest results from the chart. You can use at to read the latest snapshot before the specified time point.
GET $CLOUDSIGMA_API_BASE/data-dashboards/{dashboard_id}/charts/{chart_id}/result
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. Prepare personal access token and target workspace ID that can access the target workspace. Get the kanban ID from Query data kanban list. Get the chart ID from Query data dashboard details.
Request parameters¶
Replace $DASHBOARD_ID, $CHART_ID, $CLOUDSIGMA_API_KEY, $WORKSPACE_ID in the example with actual values.
curl -X GET "$CLOUDSIGMA_API_BASE/data-dashboards/$DASHBOARD_ID/charts/$CHART_ID/result" \
-H "X-API-Key: $CLOUDSIGMA_API_KEY" \
-H "X-Workspace-ID: $WORKSPACE_ID"
Parameter |
Type |
Required |
Description |
|---|---|---|---|
|
string |
Yes |
Data dashboard ID. |
|
string |
Yes |
Chart ID. |
Query parameters
Parameter |
Type |
Required |
Description |
|---|---|---|---|
|
string |
No |
RFC 3339 point in time. |
at Select snapshots based on result completion time. The result is no later than the specified moment and no earlier than the starting point of the current snapshot. The service can retrieve at most 20 pages, 100 items per page, and the upper limit of the retrieval time is 5 seconds, so the snapshot at the specified time may not be found.
When at is more than 1 minutes later than the current time on the server, HTTP 400 is returned. The configuration update time is different from the results completion time.
Successful response¶
{
"code": "OK",
"msg": "OK",
"data": {
"execution_id": "exec-001",
"status": "completed",
"mode": "live",
"result": {
"query_id": "",
"db_name": "",
"statement_id": "",
"status": "",
"total": 1
}
}
}
Field |
Type |
Description |
|---|---|---|
|
string |
Chart run ID. |
|
string |
Run or result status. |
|
string |
error message. |
|
string |
Result selection mode. |
|
string |
Request time. RFC 3339 time. |
|
string |
Refresh time. RFC 3339 time. |
|
object or null |
Query results. Returned on success. |
|
string |
Query ID. |
|
string |
Database name. |
|
string |
Unique identifier for an IAM policy statement. |
|
string |
status. |
|
string |
error message. |
|
integer |
The offset of this query. |
|
integer |
The maximum number of queries for this time. |
|
integer |
The number of records that match the current query conditions. |
|
array of object |
Column definition. |
|
string |
Name. |
|
string |
type. |
|
array |
results. |
|
integer |
Number of rows affected. |
|
object or null |
Whether it is an empty collection. |
|
string |
Description of results. |
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 |
When the scheduling or refresh service is unavailable, HTTP 503 is returned, and the error structure is changed to the integer code (503) and the string message (localized error message).