[Index]
Defines the schema for the Counters Dashboard Widget.
Model ref.: data/DashboardWidgetCounters
The full URL would include the host-proxy name: https://[host-proxy].
Variables are enclosed in square brackets.
{
"$schema": "http://json-schema.org/draft-03/schema",
"type": "object",
"properties": {
"title": {
"title": "Title",
"description": "The title to be displayed for this counter.",
"type": "string",
"required": true
},
"description": {
"title": "Description",
"description": "The description to be displayed for this widget.",
"type": "string"
},
"datasource": {
"title": "Data Source",
"description": "Specify Data Source",
"type": "string",
"default": "LXT0",
"choices": [
{
"value": "LXT0",
"title": "Insights"
},
{
"value": "Automate",
"title": "Automate"
}
]
},
"resource": {
"title": "Resource",
"description": "Specify resource",
"type": "string",
"format": "uri",
"target": "/api/data/ReporterResource/choices/?field=name&format=json&hierarchy=[hierarchy]&auth_token=[authtoken],
"target_attr": "name",
"target_model_type": "data/ReporterResource",
"choices": []
},
"resource_definition": {
"title": "Resource Definition",
"description": "Returns the resource definitions",
"type": "string"
},
"_lowerTs": {
"title": "Start Timestamp",
"description": "Lower timestamp bound for the data range shown in the chart",
"type": "integer"
},
"_upperTs": {
"title": "End Timestamp",
"description": "Upper timestamp bound for the data range shown in the chart",
"type": "integer"
},
"_outputType": {
"title": "Output Type",
"description": "The format in which the data will be presented in the chart",
"type": "string",
"default": "highcharts",
"choices": [
{
"value": "raw",
"title": "Raw"
},
{
"value": "highcharts",
"title": "Highcharts"
}
]
},
"_limit": {
"title": "Number of rows",
"description": "Number of rows to be displayed in the table",
"type": "string",
"default": "20"
},
"_offset": {
"title": "Starting Row",
"description": "Starting row for table pagination",
"type": "string",
"default": "0"
},
"_groupingLimit": {
"title": "Series Limit",
"description": "The maximum number of groups to display on the chart",
"type": "string",
"default": "0",
"choices": [
{
"value": "0",
"title": "All"
},
{
"value": "1",
"title": "1"
},
{
"value": "2",
"title": "2"
},
{
"value": "3",
"title": "3"
},
{
"value": "4",
"title": "4"
},
{
"value": "5",
"title": "5"
},
{
"value": "6",
"title": "6"
},
{
"value": "7",
"title": "7"
},
{
"value": "8",
"title": "8"
},
{
"value": "9",
"title": "9"
},
{
"value": "10",
"title": "10"
},
{
"value": "15",
"title": "15"
},
{
"value": "20",
"title": "20"
},
{
"value": "25",
"title": "25"
},
{
"value": "30",
"title": "30"
},
{
"value": "40",
"title": "40"
},
{
"value": "50",
"title": "50"
},
{
"value": "60",
"title": "60"
},
{
"value": "70",
"title": "70"
},
{
"value": "80",
"title": "80"
},
{
"value": "90",
"title": "90"
},
{
"value": "100",
"title": "100"
},
{
"value": "200",
"title": "200"
},
{
"value": "300",
"title": "300"
},
{
"value": "400",
"title": "400"
},
{
"value": "500",
"title": "500"
},
{
"value": "1000",
"title": "1000"
},
{
"value": "10000",
"title": "10000"
},
{
"value": "50000",
"title": "50000"
},
{
"value": "100000",
"title": "100000"
}
]
},
"type": {
"title": "Type",
"description": "The chart type.",
"type": "integer",
"default": "16",
"choices": [
{
"value": 0,
"title": "Line"
},
{
"value": 1,
"title": "Column"
},
{
"value": 2,
"title": "Pie"
},
{
"value": 3,
"title": "Gauge"
},
{
"value": 16,
"title": "Table"
}
]
},
"fields": {
"title": "Fields",
"description": "Specify the fields from the resource to be used in the chart.",
"type": "array",
"items": {
"type": "object",
"properties": {
"guid": {
"title": "GUID",
"description": "Unique identifier for the field.",
"type": "string"
},
"ruleName": {
"title": "Field Name",
"description": "This is the field name.",
"type": "string",
"choices": []
},
"headerName": {
"title": "Friendly Name",
"description": "Specify a friendly name to be used in the chart.",
"type": "string"
},
"ruleTypeString": {
"title": "Field Type",
"description": "This is the field type",
"type": "string",
"readonly": true
},
"ruleType": {
"title": "Field Type",
"description": "This is the field type",
"type": "integer"
},
"valueType": {
"title": "Value Type",
"description": "This is the operation value type",
"type": "integer"
},
"operation": {
"title": "Operation",
"description": "Select the operation to be performed on the field.",
"type": "string",
"choices": []
},
"value_mapping": {
"title": "Value Mapping",
"description": "Select the value mapping to display user-friendly values. This will override the resource value mapping if one exists. To use the raw value, select 'NO MAPPING'.",
"type": "string"
}
}
}
},
"filters": {
"title": "Filters",
"description": "Specify filters to be applied to the data.",
"type": "array",
"items": {
"type": "object",
"properties": {
"guid": {
"title": "GUID",
"description": "Unique identifier for the filter field.",
"type": "string"
},
"ruleName": {
"title": "Field Name",
"description": "Specify Field Name",
"type": "string",
"choices": []
},
"operation": {
"title": "Operation",
"description": "Specify operation",
"type": "string",
"choices": []
},
"filterValue": {
"title": "Filter Value",
"description": "Specify filter value",
"type": "string"
},
"type": {
"title": "Filter Type",
"description": "Specify type",
"type": "integer"
}
}
}
},
"sorts": {
"title": "Sorts",
"description": "Specify sorts to be applied to the fields.",
"type": "array",
"items": {
"type": "object",
"properties": {
"guid": {
"title": "GUID",
"description": "Unique identifier for the sort field.",
"type": "string"
},
"ruleName": {
"title": "Field Name",
"description": "Select the field name to sort by.",
"type": "string",
"choices": []
},
"sort": {
"title": "Sort Type",
"description": "Select the sort type",
"type": "integer",
"choices": [
{
"value": 0,
"title": "Ascending"
},
{
"value": 1,
"title": "Descending"
}
]
}
}
}
},
"settings": {
"title": "Chart Settings",
"description": "Chart Settings",
"type": "object",
"properties": {
"description": {
"title": "Description",
"description": "Specify description",
"type": "string"
},
"icon": {
"title": "Icon",
"description": "The icon to be used for this counter.",
"type": "string",
"format": "uri",
"required": false,
"readonly": false,
"target": "/api/data/Icons/choices/?choice_title=icon_name&field=icon_value&format=json&hierarchy=[hierarchy]&auth_token=[authtoken],
"target_attr": "icon_value",
"target_title": "icon_name",
"target_model_type": "data/Icons",
"choices": []
},
"prefix": {
"title": "Prefix",
"description": "Specify the prefix text to be applied to the counter value.",
"type": "string"
},
"suffix": {
"title": "Suffix",
"description": "Specify the suffix text to be applied to the counter value.",
"type": "string"
},
"defaultValue": {
"title": "Default Value",
"description": "Specify a default value to show in case no data is returned.",
"type": "any"
},
"emptyGroupText": {
"title": "Empty Group Text",
"description": "Text will be used when group name is empty.",
"type": "string"
},
"renderers": {
"title": "Renderers",
"description": "Specify renderers",
"type": "array",
"items": {
"type": "object",
"properties": {
"guid": {
"title": "GUID",
"description": "Unique identifier for the renderers.",
"type": "string"
},
"ruleName": {
"title": "Field Name",
"description": "Specify field name.",
"type": "string",
"readonly": true
},
"showName": {
"title": "Display in Title",
"description": "Display the field's data in title?",
"type": "boolean",
"default": true
}
}
}
}
}
},
"automate_counters": {
"title": "Counters",
"description": "Filters that can't be removed by end user.",
"type": "array",
"required": false,
"readonly": false,
"items": {
"type": "object",
"properties": {
"title": {
"title": "Title",
"description": "The title to be displayed for this counter.",
"type": "string",
"required": true
},
"icon": {
"title": "Icon",
"description": "The icon to be used for this counter.",
"type": "string",
"format": "uri",
"required": false,
"readonly": false,
"target": "/api/data/Icons/choices/?choice_title=icon_name&field=icon_value&format=json&hierarchy=[hierarchy]&auth_token=[authtoken],
"target_attr": "icon_value",
"target_title": "icon_name",
"target_model_type": "data/Icons",
"choices": []
},
"type": {
"title": "Type",
"description": "The selected model type from the Type drop-down list to associate with the Title.",
"type": "string",
"format": "uri",
"required": false,
"readonly": false,
"target": "/api/choices/?format=json&hierarchy=[hierarchy]&auth_token=[authtoken],
"choices": []
},
"field_display_policy": {
"title": "Field Display Policy",
"description": "The selected Field Display Policy that is associated with the counter.",
"type": "string",
"format": "uri",
"required": false,
"readonly": false,
"target": "/api/data/FieldDisplayPolicy/template_choices/?field=name&format=json&hierarchy=[hierarchy]&auth_token=[authtoken],
"target_attr": "name",
"target_model_type": "data/FieldDisplayPolicy",
"choices": []
},
"condition": {
"title": "Condition",
"description": "Only show this counter if this condition evaluates to true.",
"type": "string",
"required": false,
"readonly": false,
"displayable": true
},
"configuration_template": {
"title": "Configuration Template",
"description": "The selected Configuration Template that is associated with the counter.",
"type": "string",
"format": "uri",
"required": false,
"readonly": false,
"target": "/api/data/ConfigurationTemplate/template_choices/?field=name&format=json&hierarchy=[hierarchy]&auth_token=[authtoken],
"target_attr": "name",
"target_model_type": "data/ConfigurationTemplate",
"choices": []
},
"filter_options": {
"title": "Fixed Filters",
"description": "Filters that can't be removed by end user.",
"type": "array",
"required": false,
"readonly": false,
"items": {
"type": "object",
"properties": {
"filter_by": {
"title": "Field Name",
"type": "string",
"required": false,
"readonly": false
},
"operation": {
"title": "Operation",
"type": "string",
"required": false,
"readonly": false,
"choices": [
{
"value": "contains",
"title": "Contains"
},
{
"value": "notcontain",
"title": "Does Not Contain"
},
{
"value": "startswith",
"title": "Starts With"
},
{
"value": "endswith",
"title": "Ends With"
},
{
"value": "equals",
"title": "Equals"
},
{
"value": "notequal",
"title": "Not Equal"
}
]
},
"filterValue": {
"title": "Filter Value",
"type": "string",
"required": false,
"readonly": false
},
"ignore_case": {
"title": "Ignore Case",
"type": "boolean",
"required": false,
"readonly": false
}
}
}
},
"configurable_options": {
"title": "Configurable Filters",
"description": "Filters suggested to end users and my be cleared.",
"type": "array",
"required": false,
"readonly": false,
"items": {
"type": "object",
"properties": {
"filter_by": {
"title": "Field Name",
"type": "string",
"required": false,
"readonly": false
},
"operation": {
"title": "Operation",
"type": "string",
"required": false,
"readonly": false,
"choices": [
{
"value": "contains",
"title": "Contains"
},
{
"value": "notcontain",
"title": "Does Not Contain"
},
{
"value": "startswith",
"title": "Starts With"
},
{
"value": "endswith",
"title": "Ends With"
},
{
"value": "equals",
"title": "Equals"
},
{
"value": "notequal",
"title": "Not Equal"
}
]
},
"filterValue": {
"title": "Filter Value",
"type": "string",
"required": false,
"readonly": false
},
"ignore_case": {
"title": "Ignore Case",
"type": "boolean",
"required": false,
"readonly": false
}
}
}
}
}
}
},
"drilldowns": {
"title": "Drilldown Settings",
"description": "Drilldown Settings",
"type": "object",
"properties": {
"filterOption": {
"title": "Filter Options",
"description": "Specify Filter option",
"type": "string",
"default": "IN",
"choices": [
{
"value": "IN",
"title": "IN"
},
{
"value": "REGEX",
"title": "REGEX"
}
]
},
"drilldownOption": {
"title": "Drilldown Options",
"description": "Specify Drilldown option",
"type": "integer",
"default": "0",
"choices": [
{
"value": 0,
"title": "None"
},
{
"value": 1,
"title": "Filter Other Widgets"
},
{
"value": 2,
"title": "Link to Another Dashboard"
},
{
"value": 4,
"title": "Launch Third-Party URL"
},
{
"value": 5,
"title": "Conditional Drilldown"
}
]
},
"dashboardId": {
"title": "Dashboards",
"description": "Specify Dashboard ID",
"type": "string",
"choices": []
},
"url": {
"title": "Third-Party URL",
"description": "Specify Third-Party URL",
"type": "string"
},
"jsonConf": {
"title": "Conditional Drilldown",
"description": "Specify Json Conditional Drilldown Configuration",
"type": "string"
},
"drilldownFields": {
"title": "Drilldown Fields",
"description": "Specify Drilldown Fields",
"type": "array",
"items": {
"type": "object",
"properties": {
"ruleName": {
"title": "Field Name",
"description": "Specify field name",
"type": "string",
"choices": []
}
}
}
}
}
}
},
"schema_version": "0.5"
}
| Task | Call | URL | Parameters | Response |
|---|---|---|---|---|
| Get the GUI Add form. | GET | /api/data/DashboardWidgetCounters/add/ |
|
The GUI Add form of data/DashboardWidgetCounters as JSON |
The API call to the /add/ URL can only be made from a hierarchy that allows the model type to be added. The actions in the response shows the url for the POST API call to create an instance.
| Task | Call | URL | Parameters | Payload |
|---|---|---|---|---|
| Create | POST | /api/data/DashboardWidgetCounters | hierarchy=[hierarchy] |
|
tool/Transaction/[trans pkid]to inspect the created resource and its instance pkid.
| Task | Call | URL | Parameters | Response |
|---|---|---|---|---|
| List | GET | /api/data/DashboardWidgetCounters/ |
|
The data/DashboardWidgetCounters schema and all instances as JSON. |
(The list will return 0 to 3 data/DashboardWidgetCounters instances)
{
"pagination": {
"skip": 0,
"limit": 3,
"maximum_limit": 2000,
"total": 0,
"total_limit": null,
"order_by": "title",
"direction": "asc",
"current": "/api/data/DashboardWidgetCounters/?skip=0&limit=3&order_by=title&direction=asc&traversal=fulltree"
},
"operations": [
"help",
"bulk_update_form",
"update",
"add",
"export",
"get",
"list",
"export_bulkload_template",
"migration",
"remove",
"move",
"transform",
"configuration_template",
"field_display_policy"
],
"meta": {
"model_type": "data/DashboardWidgetCounters",
"summary_attrs": [
{
"name": "title",
"title": "Title"
},
{
"name": "description",
"title": "Description"
},
{
"name": "hierarchy_friendly_name",
"title": "Located At",
"allow_filtering": true
}
],
"tagged_versions": [],
"tags": [],
"title": "",
"business_key": {},
"api_version": "21.2",
"cached": true,
"references": {
"children": [],
"parent": [
{
"href": "/api/data/HierarchyNode/6t0ggef2c0deab00hb595101",
"pkid": "6t0ggef2c0deab00hb595101"
}
],
"device": [
{
"href": "",
"pkid": ""
}
],
"foreign_key": []
},
"model_specific_actions": [
"get",
"add",
"list"
],
"schema_version": "0.5",
"actions": [
{
"add": {
"method": "GET",
"class": "add",
"href": "/api/data/DashboardWidgetCounters/add/?hierarchy=[hierarchy]",
"support_async": false,
"title": "Add"
}
},
{
"list": {
"method": "GET",
"class": "list",
"href": "/api/data/DashboardWidgetCounters/?hierarchy=[hierarchy]",
"support_async": false,
"title": "List"
}
}
]
},
"resources": []
}
| Task | Call | URL | Parameters | Response |
|---|---|---|---|---|
| Get | GET | /api/data/DashboardWidgetCounters/[pkid] | hierarchy=[hierarchy] | The data/DashboardWidgetCounters instance with [pkid]. |