Supported Formats

json

GET /api/metrics
Fetch a list of metrics

Supported Formats

json

Params

Param name Description
page
optional

Page number

Validations:

  • Must be a number.

per_page
optional

Number of results per page, default: 50

Validations:

  • Must be a number.


POST /api/metrics/v1
Add a metric data point (token auth)

POST /api/metrics
Add a metric data point (token auth)

Supported Formats

json

Params

Param name Description
metric_id
optional

Metric ID for the metric data point. One of “metric_id” or “name” must be specified.

Validations:

  • Must be a String

name
optional

Metric name for the metric data point. Data points with the same name will be added to the same metric. One of “metric_id” or “name” must be specified.

Validations:

  • Must be a String

date
required

Metric data point occurrence date. e.g. 01/01/2021, 2021/01/01

Validations:

  • Must be a String

value
required

Metric data point value

Validations:

  • Must be a number.

roll_up
optional

Calculation type used for the metric, affects all metric data points.

Validations:

  • Must be one of: sum, average, increase, weighted_average, last_month_available.

metric_source_slug
optional

Metric Source unique ID to reference the appropriate Metric. Overrides the metric name.

Validations:

  • Must be a String

api_token
required

Authentication token, available at app.doubleloop.app/organizations/settings/integrations

Validations:

  • Must be a String