API Stability |
Long-Term
|
The createDashboardFromTemplateV2() GraphQL mutation field may be used to create a dashboard in LogScale from a YAML template.
For more information on creating dashboards, see the Create Dashboards and Widgets documentation page. You may also want to look at the Dashboards & Widgets page for related information.
Syntax
Below is the syntax for the createDashboardFromTemplateV2() mutation field:
createDashboardFromTemplateV2(
input: CreateDashboardFromTemplateV2Input!
): Dashboard!
In the example below, for the YAML template, ellipses are shown instead to save space:
mutation {
createDashboardFromTemplateV2(input:
{ viewName: "humio",
name: "my-fancy-dashboard",
yamlTemplate: "..."
} )
{ id }
}
{
"data": {
"createDashboardFromTemplateV2": {
"id": "H9HVDeyfpru69mbwQzSITrEc1p3RRhFl"
}
}
}
Given Datatypes
For
CreateDashboardFromTemplateV2Input
,
there are a few parameters. Below is a list of them along with
their a brief description of each:
Table: CreateDashboardFromTemplateV2Input
Parameter | Type | Required | Default | Stability | Description |
---|---|---|---|---|---|
Some arguments may be required, as indicated in the Required column. For some fields, this column indicates that a result will always be returned for this column. | |||||
Table last updated: Sep 17, 2024 | |||||
name | string | yes | Long-Term | The name of the dashboard. | |
viewName | string | yes | Long-Term | The name of the view of the dashboard. | |
yamlTemplate | yaml | yes | Long-Term | A template that can be used to recreate the dashboard. |
Returned Datatypes
The returned datatype Dashboard
has many
parameters. Below is a list of them along with a description of
each:
Table: Dashboard
Parameter | Type | Required | Default | Stability | Description |
---|---|---|---|---|---|
Some arguments may be required, as indicated in the Required column. For some fields, this column indicates that a result will always be returned for this column. | |||||
Table last updated: Mar 28, 2025 | |||||
allowedActions | [AssetAction ] | yes | Preview | The allowed asset actions. See AssetAction Table). This is feature is a preview and may be changed. | |
defaultFilter | DashboardFilter | Long-Term | The default filter used with the dashboard (see DashboardFilter Table). | ||
defaultSharedTimeEnabled | boolean | yes | Long-Term | Whether the shared time by default is enabled. | |
defaultSharedTimeEnd | string | yes | Long-Term | The default shared ending time. | |
defaultSharedTimeStart | string | yes | Long-Term | The default shared starting time. | |
description | string | Long-Term | A description of the dashboard. | ||
displayName | string | yes | Long-Term | The display name of the dashboard. | |
filters | [DashboardFilter ] | yes | Long-Term | The filters used with the dashboard. See DashboardFilter . | |
id | string | yes | Long-Term | The unique identifier for the dashboard. | |
isStarred | boolean | yes | Long-Term | Whether the dashboard is marked with a star. | |
labels | [string] | yes | Long-Term | Any labels associated with the dashboard. | |
name | string | yes | Long-Term | The name of the dashboard. | |
package | PackageInstallation | yes | Long-Term | The package, if there is one, in which the dashboard is included (see PackageInstallation Table). | |
packageId | VersionedPackageSpecifier | yes | Long-Term | The unique identifiers of the package. VersionedPackageSpecifier is a scalar. | |
parameters | [DashboardParameter ] | yes | Long-Term | List of dashboard parameters (see DashboardParameter Table). | |
readOnlyTokens | [DashboardLink ] | yes | Long-Term | List of tokens used to access the dashboard without logging in. Useful for wall mounted dashboards or public dashboards. See DashboardLink . | |
resource | string | yes | Short-Term | The resource identifier for this dashboard. | |
searchDomain | searchDomain | yes | Long-Term | The search domain for the dashboard. See searchDomain . | |
sections | [Section ] | yes | Long-Term | The sections for the dashboard. See Section . | |
yamlTemplate | string | yes | Long-Term | A YAML formatted string that describes the dashboard. It does not contain links or permissions, and is safe to share and use for making copies of a dashboard. This replaced templateYaml starting in LogScale version 1.165. | |
timeJumpSizeInMs | integer | Long-Term | The skip time in milliseconds for the dashboard. | ||
updateFrequency | DashboardUpdateFrequencyType | yes | Long-Term | The frequency in which dashboard is updated. See the explanations under the DashboardParameter . | |
widgets | [Widget ] | yes | Long-Term | Widgets for the dashboard (see Widget Table). |