REST Resource: projects.locations.instances.dashboardCharts

Resource: DashboardChart

DashboardChart resource. NEXT TAG: 10

JSON representation
{
  "name": string,
  "display_name": string,
  "description": string,
  "native_dashboard": string,
  "tile_type": enum (TileType),
  "chart_datasource": {
    object (ChartDatasource)
  },
  "visualization": {
    object (Visualization)
  },
  "etag": string,
  "drill_down_config": {
    object (DrillDownConfig)
  }
}
Fields
name

string

Output only. Name of the dashboardChart.

display_name

string

Required. Display name/Title of the dashboardChart visible to users.

description

string

Optional. Description of the dashboardChart.

native_dashboard

string

Output only. NativeDashboard this chart belongs to.

tile_type

enum (TileType)

Optional. Type of tile i.e., visualization, button or text.

chart_datasource

object (ChartDatasource)

Optional. Query and datasource used in the chart. Should be empty for Button Tiles.

visualization

object (Visualization)

Required. Depending on tile_type one of below fields will be required.

etag

string

Optional. This checksum is computed by the server based on the value of other fields, and may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding.

drill_down_config

object (DrillDownConfig)

Optional. Drill down configuration.

TileType

TileType indicates what type of chart tile it is i.e., visualization chart, button or text.

Enums
TILE_TYPE_UNSPECIFIED Defaults to VISUALIZATION.
TILE_TYPE_VISUALIZATION Visualization i.e., bar charts, pie charts etc.
TILE_TYPE_BUTTON Button with hyperlink.

ChartDatasource

Datasource of the chart including the query reference and source name.

JSON representation
{
  "dashboard_query": string,
  "data_sources": [
    enum (DataSource)
  ]
}
Fields
dashboard_query

string

Reference to dashboard query resource used in the chart.

data_sources[]

enum (DataSource)

Name of the datasource used in the chart.

Visualization

Visualization config for a chart. https://echarts.apache.org/en/option.html#series NEXT TAG: 16

JSON representation
{
  "x_axes": [
    {
      object (Axis)
    }
  ],
  "y_axes": [
    {
      object (Axis)
    }
  ],
  "series": [
    {
      object (Series)
    }
  ],
  "tooltip": {
    object (Tooltip)
  },
  "legends": [
    {
      object (Legend)
    }
  ],
  "column_defs": [
    {
      object (ColumnDef)
    }
  ],
  "button": {
    object (Button)
  },
  "series_column": [
    string
  ],
  "grouping_type": string,
  "google_maps_config": {
    object (GoogleMapsConfig)
  }
}
Fields
x_axes[]

object (Axis)

y_axes[]

object (Axis)

series[]

object (Series)

tooltip

object (Tooltip)

legends[]

object (Legend)

column_defs[]

object (ColumnDef)

Column Definition to represent chart as a table.

button

object (Button)

Button config for a chart if tileType is TILE_TYPE_BUTTON.

series_column[]

string

Optional. Selected column for series

grouping_type

string

Optional. Selected grouping type for series

google_maps_config

object (GoogleMapsConfig)

Optional. Google Maps config for a chart if type is GOOGLE MAPS.

Axis

JSON representation
{
  "axis_type": enum (AxisType),
  "display_name": string,
  "min": integer,
  "max": integer
}
Fields
axis_type

enum (AxisType)

display_name

string

min

integer

Minimum value to be rendered in ECharts as per https://echarts.apache.org/en/option.html#xAxis.min

max

integer

Maximum value to be rendered in ECharts as per https://echarts.apache.org/en/option.html#xAxis.max

AxisType

Enums
AXIS_TYPE_UNSPECIFIED
VALUE
CATEGORY
TIME
LOG

Series

JSON representation
{
  "series_type": enum (SeriesType),
  "series_name": string,
  "show_symbol": boolean,
  "show_background": boolean,
  "stack": string,
  "series_stack_strategy": enum (SeriesStackStrategy),
  "encode": {
    object (Encode)
  },
  "label": string,
  "field": string,
  "data_label": {
    object (DataLabel)
  },
  "radius": [
    string
  ],
  "item_style": {
    object (ItemStyle)
  },
  "series_unique_value": string,
  "area_style": {
    object (AreaStyle)
  },
  "item_colors": {
    object (ItemColors)
  },
  "gauge_config": {
    object (GaugeConfig)
  },
  "metric_trend_config": {
    object (MetricTrendConfig)
  }
}
Fields
series_type

enum (SeriesType)

series_name

string

user specified series label

show_symbol

boolean

show_background

boolean

stack

string

series_stack_strategy

enum (SeriesStackStrategy)

encode

object (Encode)

label

string

field

string

data_label

object (DataLabel)

Optional. Data label config for a series. Displays data vaule in the chart

radius[]

string

Optional. Used to make a pie chart into a douhnut chart

item_style

object (ItemStyle)

Optional. Custom styling for chart

series_unique_value

string

Optional. Series unique value from the query result

area_style

object (AreaStyle)

Optional. Custom styling for area chart

item_colors

object (ItemColors)

Optional. Field to be saved for retrieving slice colors for the chart

gauge_config

object (GaugeConfig)

Optional. Field to be saved for retrieving gauge config for gauge chart

metric_trend_config

object (MetricTrendConfig)

Optional. Fields to capture trend config for metric charts

SeriesType

Enums
SERIES_TYPE_UNSPECIFIED
LINE
BAR
PIE
TEXT
MAP Represents map chart type.
GAUGE Represents gauge chart type.
SCATTERPLOT Represents scatterplot chart type.

SeriesStackStrategy

Enums
SERIES_STACK_STRATEGY_UNSPECIFIED
SAMESIGN
ALL
POSITIVE
NEGATIVE

Encode

JSON representation
{
  "x": string,
  "y": string,
  "value": string,
  "item_name": string
}
Fields
x

string

y

string

value

string

For some type of series that are not in any coordinate system, like 'pie'

item_name

string

This is useful in charts like 'pie', where data item name can be displayed in legend.

DataLabel

Data label config for a series.

JSON representation
{
  "show": boolean
}
Fields
show

boolean

Optional. Whether to show data label.

ItemStyle

Custom styling for chart

JSON representation
{
  "border_width": integer,
  "border_color": string,
  "color": string
}
Fields
border_width

integer

Optional. Used to add border width

border_color

string

Optional. Used to add border color

color

string

Optional. Used to add color

AreaStyle

Custom styling for area chart

JSON representation
{
  "color": string,
  "origin": string,
  "shadow_blur": integer,
  "shadow_color": string,
  "shadow_offset_x": integer,
  "shadow_offset_y": integer,
  "opacity": integer
}
Fields
color

string

Optional. Used to add color

origin

string

Optional. Used to add origin

shadow_blur

integer

Optional. Used to add shadow blur

shadow_color

string

Optional. Used to add shadow color

shadow_offset_x

integer

Optional. Used to add shadow offsetX

shadow_offset_y

integer

Optional. Used to add shadow offsetY

opacity

integer

Optional. Used to add opacity

ItemColors

Field to be saved for retrieving slice colors for the chart

JSON representation
{
  "colors": [
    {
      object (ChartSliceColor)
    }
  ]
}
Fields
colors[]

object (ChartSliceColor)

Optional. Slice colors array

ChartSliceColor

Slice containing the key and value for a slice in the chart

JSON representation
{
  "key": string,
  "value": {
    object (UserSelectedValues)
  }
}
Fields
key

string

Optional. Key for the slice

value

object (UserSelectedValues)

Optional. Value for the slice

UserSelectedValues

User selected color and label for the slice of the chart

JSON representation
{
  "color": string,
  "label": string
}
Fields
color

string

Optional. User specified color of a pie slice

label

string

Optional. User specified label for a pie slice

GaugeConfig

Field to be saved for retrieving value and color for gauge chart

JSON representation
{
  "base_value": {
    object (GaugeValue)
  },
  "limit_value": {
    object (GaugeValue)
  },
  "threshold_values": [
    {
      object (GaugeValue)
    }
  ]
}
Fields
base_value

object (GaugeValue)

Optional. Base value for gauge chart

limit_value

object (GaugeValue)

Optional. Limit value for gauge chart

threshold_values[]

object (GaugeValue)

Optional. Threshold values for gauge chart

GaugeValue

Field to be saved for retrieving value and color for gauge chart

JSON representation
{
  "value": integer,
  "color": string
}
Fields
value

integer

Optional. Value for gauge chart

color

string

Optional. Color for gauge chart

MetricTrendConfig

Metric trend config for displaying trend value in Metrics chart

JSON representation
{
  "metric_format": enum (MetricFormat),
  "metric_display_trend": enum (MetricDisplayTrend),
  "trend_toggle": boolean,
  "metric_trend_type": enum (MetricTrendType)
}
Fields
metric_format

enum (MetricFormat)

Optional. Metric chart configuration to display metric trend

metric_display_trend

enum (MetricDisplayTrend)

Optional. Metric chart configuration to display the trend value

trend_toggle

boolean

Optional. Metric chart configuration to toggle trend display on metric charts

metric_trend_type

enum (MetricTrendType)

Optional. Metric chart configuration to display trend type whether regular or inverse

MetricFormat

Metric format to be displayed for the metric charts.

Enums
METRIC_FORMAT_UNSPECIFIED Metric format is not specified.
METRIC_FORMAT_NUMBER Metric format in number
METRIC_FORMAT_PLAIN_TEXT Metric format in plain text

MetricDisplayTrend

Trend to be displayed for the metric charts as.

Enums
METRIC_DISPLAY_TREND_UNSPECIFIED Trend is not specified.
METRIC_DISPLAY_TREND_ABSOLUTE_VALUE Trend data in absolute value
METRIC_DISPLAY_TREND_PERCENTAGE Trend data in percentage
METRIC_DISPLAY_TREND_ABSOLUTE_VALUE_AND_PERCENTAGE Trend data in both absolute value and percentage

MetricTrendType

Trend to be displayed for the metric charts as.

Enums
METRIC_TREND_TYPE_UNSPECIFIED Trend type is not specified.
METRIC_TREND_TYPE_REGULAR The trend type is regular(green for positive delta)
METRIC_TREND_TYPE_INVERSE The trend type is inverse(red for positive delta)

Tooltip

JSON representation
{
  "show": boolean,
  "tooltip_trigger": enum (ToolTipTrigger)
}
Fields
show

boolean

tooltip_trigger

enum (ToolTipTrigger)

ToolTipTrigger

Enums
TOOLTIP_TRIGGER_UNSPECIFIED
TOOLTIP_TRIGGER_NONE
TOOLTIP_TRIGGER_ITEM
TOOLTIP_TRIGGER_AXIS

Legend

JSON representation
{
  "id": string,
  "show": boolean,
  "z_level": integer,
  "z": integer,
  "left": integer,
  "top": integer,
  "right": integer,
  "bottom": integer,
  "legend_orient": enum (LegendOrient),
  "legend_align": enum (LegendAlign),
  "padding": [
    integer
  ]
}
Fields
id

string

show

boolean

z_level

integer

z

integer

left

integer

top

integer

right

integer

bottom

integer

legend_orient

enum (LegendOrient)

legend_align

enum (LegendAlign)

padding[]

integer

LegendOrient

Enums
LEGEND_ORIENT_UNSPECIFIED
VERTICAL
HORIZONTAL

LegendAlign

Enums
LEGEND_ALIGN_UNSPECIFIED
AUTO
LEFT
RIGHT

ColumnDef

Column Definition.

JSON representation
{
  "field": string,
  "header": string
}
Fields
field

string

Field key in data.

header

string

Header name for column.

Button

Button config for a chart.

JSON representation
{
  "label": string,
  "hyperlink": string,
  "description": string,
  "new_tab": boolean,
  "properties": {
    object (Properties)
  }
}
Fields
label

string

description

string

new_tab

boolean

Whether to open the link in a new tab.

properties

object (Properties)

Properties

JSON representation
{
  "color": string,
  "button_style": enum (ButtonStyle)
}
Fields
color

string

button_style

enum (ButtonStyle)

ButtonStyle

Enums
BUTTON_STYLE_UNSPECIFIED
BUTTON_STYLE_FILLED
BUTTON_STYLE_OUTLINED
BUTTON_STYLE_TRANSPARENT

GoogleMapsConfig

Google Maps config for a chart if chart type is map.

JSON representation
{
  "data_settings": {
    object (DataSettings)
  },
  "plot_mode": enum (PlotMode),
  "map_position": {
    object (MapPosition)
  },
  "point_settings": {
    object (PointSettings)
  }
}
Fields
data_settings

object (DataSettings)

Optional. Data settings for the map.

plot_mode

enum (PlotMode)

Optional. Plot mode for the map. This is used to determine whether to show points, heatmap or both.

map_position

object (MapPosition)

Optional. Map position settings for the map.

point_settings

object (PointSettings)

Optional. Point settings for the map.

DataSettings

Data settings for the map.

JSON representation
{
  "latitude_column": string,
  "longitude_column": string,
  "count_column": string
}
Fields
latitude_column

string

Optional. Latitude column.

longitude_column

string

Optional. Longitude column.

count_column

string

Optional. Field to count.

PlotMode

Plot mode for the map.

Enums
PLOT_MODE_UNSPECIFIED Plot mode is not specified.
PLOT_MODE_POINTS Plot mode is points.
PLOT_MODE_HEATMAP Plot mode is heatmap.
PLOT_MODE_BOTH Plot mode is both points and heatmap.

MapPosition

Map position settings for the map.

JSON representation
{
  "fit_data": boolean,
  "latitude_value": number,
  "longitude_value": number,
  "zoom_scale_value": number
}
Fields
fit_data

boolean

Optional. Whether to fit the map to the data. If true, the map will be resized to fit the data. If false, langitude and longitude will be used to set the map size.

latitude_value

number

Optional. Latitude of the map.

longitude_value

number

Optional. Longitude of the map.

zoom_scale_value

number

Optional. Scale of the map.

PointSettings

Point settings for the map.

JSON representation
{
  "point_size_type": enum (PointSizeType),
  "color": string
}
Fields
point_size_type

enum (PointSizeType)

Optional. Point size type for the map. This is used to determine the size of the points on the map.

color

string

Optional. Color for the point on the map.

PointSizeType

Point size type for the map.

Enums
POINT_SIZE_TYPE_UNSPECIFIED Point size is not specified.
POINT_SIZE_TYPE_FIXED Point size is fixed.
POINT_SIZE_TYPE_PROPORTIONAL_TO_SIZE Point size is proportional to the size of the data point.

DrillDownConfig

NEXT TAG: 3 Drill down configuration.

JSON representation
{
  "left_drill_downs": [
    {
      object (DrillDown)
    }
  ],
  "right_drill_downs": [
    {
      object (DrillDown)
    }
  ]
}
Fields
left_drill_downs[]

object (DrillDown)

Required. Left click drill downs.

right_drill_downs[]

object (DrillDown)

Required. Right click drill downs.

DrillDown

NEXT TAG: 5 Drill down config.

JSON representation
{
  "id": string,
  "display_name": string,

  // Union field settings can be only one of the following:
  "default_settings": {
    object (DefaultDrillDownSettings)
  },
  "custom_settings": {
    object (CustomDrillDownSettings)
  }
  // End of list of possible types for union field settings.
}
Fields
id

string

Required. ID of the drill down.

display_name

string

Required. Display name of the drill down.

Union field settings. Drill down settings. settings can be only one of the following:
default_settings

object (DefaultDrillDownSettings)

Default drill down settings.

custom_settings

object (CustomDrillDownSettings)

Custom drill down settings.

DefaultDrillDownSettings

Default drill down settings.

JSON representation
{
  "enabled": boolean
}
Fields
enabled

boolean

Required. Whether the default drill down is enabled.

CustomDrillDownSettings

NEXT TAG: 6 Custom drill down settings.

JSON representation
{
  "new_tab": boolean,
  "left_click_column": string,

  // Union field action can be only one of the following:
  "query": {
    object (DrillDownQuery)
  },
  "filter": {
    object (DrillDownFilter)
  },
  "external_link": {
    object (DrillDownExternalLink)
  }
  // End of list of possible types for union field action.
}
Fields
new_tab

boolean

Required. Whether to open the drill down action in a new tab.

left_click_column

string

Optional. Table chart column name to associate the custom drill down action on left click.

Union field action. Action to be performed on drill down. action can be only one of the following:
query

object (DrillDownQuery)

Drill down query action config.

filter

object (DrillDownFilter)

Drill down filter action config.

DrillDownQuery

Drill down query config.

JSON representation
{
  "query": string
}
Fields
query

string

Required. Search query to be executed on drill down.

DrillDownFilter

Drill down filter config.

JSON representation
{
  "dashboard_filters": [
    {
      object (DrillDownDashboardFilter)
    }
  ]
}
Fields
dashboard_filters[]

object (DrillDownDashboardFilter)

Required. Dashboard filters to be applied on drill down.

DrillDownDashboardFilter

Drill down dashboard filter config.

JSON representation
{
  "dashboard_filter_id": string,
  "filter_operator_and_values": [
    {
      object (FilterOperatorAndValues)
    }
  ]
}
Fields
dashboard_filter_id

string

Required. ID of the dashboard filter.

filter_operator_and_values[]

object (FilterOperatorAndValues)

Required. Filter operator and field values for the dashboard filter.

Methods

batchGet

Get dashboard charts in batches.

get

Get a dashboard chart.

list

List all dashboard charts.