Submit metrics
POST {{baseUrl}}/api/v2/series
The metrics end-point allows you to post time-series data that can be graphed on Datadog’s dashboards. The maximum payload size is 500 kilobytes (512000 bytes). Compressed payloads must have a decompressed size of less than 5 megabytes (5242880 bytes).
If you’re submitting metrics directly to the Datadog API without using DogStatsD, expect:
- 64 bits for the timestamp
- 64 bits for the value
- 20 bytes for the metric names
- 50 bytes for the timeseries
- The full payload is approximately 100 bytes.
Host name is one of the resources in the Resources field.
Request Body
{"series"=>[{"metric"=>"<string>", "points"=>[{"timestamp"=>"<long>", "value"=>"<double>"}, {"timestamp"=>"<long>", "value"=>"<double>"}], "interval"=>"<long>", "metadata"=>{"origin"=>{"metric_type"=>0, "product"=>0, "service"=>0}}, "resources"=>[{"name"=>"<string>", "type"=>"<string>"}, {"name"=>"<string>", "type"=>"<string>"}], "source_type_name"=>"<string>", "tags"=>["<string>", "<string>"], "type"=>3, "unit"=>"<string>"}, {"metric"=>"<string>", "points"=>[{"timestamp"=>"<long>", "value"=>"<double>"}, {"timestamp"=>"<long>", "value"=>"<double>"}], "interval"=>"<long>", "metadata"=>{"origin"=>{"metric_type"=>0, "product"=>0, "service"=>0}}, "resources"=>[{"name"=>"<string>", "type"=>"<string>"}, {"name"=>"<string>", "type"=>"<string>"}], "source_type_name"=>"<string>", "tags"=>["<string>", "<string>"], "type"=>0, "unit"=>"<string>"}]}
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
Content-Encoding | string | HTTP header used to compress the media-type. | |
Content-Type | string | ||
Accept | string |