SignalFx

Visualization Overview

The metric data you send to SignalFx can be visualized in charts, which are grouped into dashboards in the SignalFx web UI. A chart can be part of only one dashboard. For background information on charts, see Planning and Creating Charts.

API supports only v2 charts

Chart APIs are supported only for v2 charts. A v2 chart is one that was created using the SignalFx v2 API.

The following example creates a simple chart via the API:

curl \
  --request POST \
  --header "X-SF-TOKEN: YOUR_ACCESS_TOKEN" \
  --header "Content-Type: application/json" \
  --data \
  '{
  	"name": "CPU load",
  	"programText": "data('cpu.load').publish()"
	}' \
  https://api.signalfx.com/v2/chart

The response will contain the ID of the chart along with auto-generated and default values:

{
    "created": 1477347160569,
    "creator": "BqDQY5OAAAA",
    "customProperties": {},
    "description": "",
    "id": "CvkFy8TAIAA",
    "lastUpdated": 1477347160569,
    "lastUpdatedBy": "BqDQY5OAAAA",
    "name": "CPU load",
    "options": {
        "type": "TimeSeriesChart",
        "areaChartOptions": null,
        "axes": [
            {
                "highWatermark": null,
                "label": null,
                "lowWatermark": null,
                "max": null,
                "min": null
            }
        ],
        "colorBy": "Dimension",
        "defaultPlotType": "LineChart",
        "legendOptions": null,
        "lineChartOptions": null,
        "programOptions": null,
        "showEventLines": false,
        "stacked": false,
        "time": {
            "type": "relative",
            "range": 900000
        },
        "unitPrefix": "Metric"
    },
    "programText": "data('cpu.load').publish()",
    "tags": []
}

You can view the chart at http://app.signalfx.com/#/chart/ID_OF_CHART.

By default, the metric time series published from the program will be visualized as a line chart. You can choose other visualization options when creating or updating the chart. For a full list of the available settings, see the Chart Model.

The following example creates a new dashboard containing the chart we just created:

curl \
  --request POST \
  --header "X-SF-TOKEN: YOUR_ACCESS_TOKEN" \
  --header "Content-Type: application/json" \
  --data \
  '{
  	"name": "My new dashboard",
  	"charts": [
    	{
      	"chartId": "CvkFy8TAIAA",
        "column": 0,
        "height": 1,
        "row": 0,
        "width": 6
      }
    ]
	}' \
  https://api.signalfx.com/v2/dashboard

The response to this will be a new dashboard object:

{
    "charts": [
        {
            "chartId": "CvkGG1vAAAA",
            "column": 0,
            "height": 1,
            "row": 0,
            "width": 6
        }
    ],
    "created": 1477349028264,
    "creator": "BqDQY5OAAAA",
    "customProperties": {},
    "description": "",
    "filters": null,
    "groupId": "CvkFzXtAIAA",
    "id": "CvkFzX7AEAA",
    "lastUpdated": 1477349028362,
    "lastUpdatedBy": "BqDQY5OAAAA",
    "name": "My new dashboard",
    "tags": []
}

Note that since we didn't provide an ID for a dashboard group in our request, a new dashboard group was created. Dashboard groups are ways of organizing related dashboards together, and a dashboard can only be part of a single dashboard group. For background information on dashboards and dashboard groups, see Dashboard Basics.

Visualization Overview