Mutation
mutation UpdateDashboard($input: UpdateDashboardInput!) {
updateDashboard(input: $input) {
dashboard {
id
name
globalRange {
__typename
... on DashboardPresetRange {
__typename
}
}
globalFilters
widgets {
id
kind
chartType
config {
__typename
... on DashboardChartWidgetConfig {
__typename
}
}
layout {
__typename
}
position
}
createdAt {
unixTimestamp
iso8601
}
}
error {
message
type
code
fields {
field
message
type
}
}
}
}Variables
{
"input": {
"dashboardId": "id"
}
}Response
{
"data": {
"updateDashboard": {
"dashboard": {
"id": "id",
"name": "string",
"globalRange": {
"__typename": "DashboardPresetRange"
},
"globalFilters": "string",
"widgets": [
{
"id": "id",
"kind": "TIMESERIES",
"chartType": "BAR",
"config": {
"__typename": "DashboardChartWidgetConfig"
},
"layout": {
"__typename": "DashboardWidgetLayout"
},
"position": 1
}
],
"createdAt": {
"unixTimestamp": "string",
"iso8601": "string"
}
},
"error": {
"message": "string",
"type": "VALIDATION",
"code": "string",
"fields": [
{
"field": "string",
"message": "string",
"type": "VALIDATION"
}
]
}
}
}
}Mutations
updateDashboard
Updates metadata and, when widgets is provided, replaces the dashboard’s full widget set in one transaction. Requires dashboard:edit.
MUTATION
updateDashboard(input: UpdateDashboardInput!): UpdateDashboardOutput!Arguments
input
required
Returns
dashboard
error
Mutation
mutation UpdateDashboard($input: UpdateDashboardInput!) {
updateDashboard(input: $input) {
dashboard {
id
name
globalRange {
__typename
... on DashboardPresetRange {
__typename
}
}
globalFilters
widgets {
id
kind
chartType
config {
__typename
... on DashboardChartWidgetConfig {
__typename
}
}
layout {
__typename
}
position
}
createdAt {
unixTimestamp
iso8601
}
}
error {
message
type
code
fields {
field
message
type
}
}
}
}Variables
{
"input": {
"dashboardId": "id"
}
}Response
{
"data": {
"updateDashboard": {
"dashboard": {
"id": "id",
"name": "string",
"globalRange": {
"__typename": "DashboardPresetRange"
},
"globalFilters": "string",
"widgets": [
{
"id": "id",
"kind": "TIMESERIES",
"chartType": "BAR",
"config": {
"__typename": "DashboardChartWidgetConfig"
},
"layout": {
"__typename": "DashboardWidgetLayout"
},
"position": 1
}
],
"createdAt": {
"unixTimestamp": "string",
"iso8601": "string"
}
},
"error": {
"message": "string",
"type": "VALIDATION",
"code": "string",
"fields": [
{
"field": "string",
"message": "string",
"type": "VALIDATION"
}
]
}
}
}
}Was this page helpful?

