curl -X POST \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer <jwt_token>" \
  -d '{
    "query": "mutation RefreshDashboard($id: String!) { refreshDashboard(id: $id) { id widgets { id title dataRefreshedAt } } }",
    "variables": {
      "id": "dashboard_123456789"
    }
  }' \
  https://{ACCOUNT}.askwisdom.ai/graphql
{
  "data": {
    "refreshDashboard": {
      "id": "dashboard_123456789",
      "widgets": [
        {
          "id": "widget_987654321",
          "title": "Sales Chart",
          "dataRefreshedAt": "2024-01-15T10:30:00Z"
        }
      ]
    }
  }
}
The refreshDashboard mutation refreshes all data in a dashboard’s widgets to show the latest information.

Signature

refreshDashboard(id: String!, version: String): Dashboard!

Arguments

id
String!
required
The unique identifier of the dashboard to refresh.

Response

Returns the refreshed Dashboard object with updated widget data. See Dashboard for the schema.

Usage Example

The following example shows how to refresh all dashboard data:
mutation RefreshDashboard($id: String!) {
  refreshDashboard(id: $id) {
    id
    widgets {
      id
      title
      dataRefreshedAt
    }
  }
}
curl -X POST \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer <jwt_token>" \
  -d '{
    "query": "mutation RefreshDashboard($id: String!) { refreshDashboard(id: $id) { id widgets { id title dataRefreshedAt } } }",
    "variables": {
      "id": "dashboard_123456789"
    }
  }' \
  https://{ACCOUNT}.askwisdom.ai/graphql
{
  "data": {
    "refreshDashboard": {
      "id": "dashboard_123456789",
      "widgets": [
        {
          "id": "widget_987654321",
          "title": "Sales Chart",
          "dataRefreshedAt": "2024-01-15T10:30:00Z"
        }
      ]
    }
  }
}