Skip to main content
Version: Latest Version (2.9.1)

highbond_metric (Resource)

Schema

Required

field_nameString The underlying name of the column in the table used for the metric calculation. field_name must be unique within a table and follow the column naming requirements
funcString Defines the aggregate function to use in the metric calculation
intervalString Summarizes the metric into a period
nameString The name of the metric
table_idNumber The ID of the Table
time_field_nameString A column in the table with a date, datetime or time data type

Optional

base_colorString The name of the metric
configString A JSON string storing the metric format configuration
filter_configString A JSON string storing the metric filter configuration
force_updatesBoolean Allows overriding top-level 'create_only' option.
func_argumentString A JSON string storing the arguments of the Metric function
idString The ID of this resource.
metric_typeString Tags the metric as an indicator type, such as a key performance indicator or key risk indicator
show_sparklineBoolean Shows (true) or hides (false) the trend of key indicator performance from the earliest calculation period to the current period for users that view the metric
view_thresholdsBoolean Shows (true) or hides (false) active trigger thresholds on the sparkline

Read-Only

created_atString The date the metric was created
updated_atString The date the metric was updated

Example Usage

resource "highbond_metric" "main" {
name = "Example metric"
table_id = highbond_table.main.id
base_color = "#3F3D3C"
func = "uniques"
interval = "month"
metric_type = "kpi"
show_sparkline = true
view_thresholds = true
field_name = "a1"
time_field_name = "metadata.publish_date"
force_updates = true // Create only with force update changes
config = <<EOS
{
"field_format_map": {},
"conditional_formats_map": {}
}
EOS

filter_config = <<EOS
{
"filtersOpen": false,
"params": {}
}
EOS

func_argument = ""
}