docs/v1/MetricsAPI.md in datadog_api_client-1.4.0 vs docs/v1/MetricsAPI.md in datadog_api_client-1.5.0
- old
+ new
@@ -1,19 +1,18 @@
# DatadogAPIClient::V1::MetricsAPI
All URIs are relative to *https://api.datadoghq.com*
-| Method | HTTP request | Description |
-| ------ | ------------ | ----------- |
-| [**get_metric_metadata**](MetricsAPI.md#get_metric_metadata) | **GET** /api/v1/metrics/{metric_name} | Get metric metadata |
-| [**list_active_metrics**](MetricsAPI.md#list_active_metrics) | **GET** /api/v1/metrics | Get active metrics list |
-| [**list_metrics**](MetricsAPI.md#list_metrics) | **GET** /api/v1/search | Search metrics |
-| [**query_metrics**](MetricsAPI.md#query_metrics) | **GET** /api/v1/query | Query timeseries points |
-| [**submit_metrics**](MetricsAPI.md#submit_metrics) | **POST** /api/v1/series | Submit metrics |
-| [**update_metric_metadata**](MetricsAPI.md#update_metric_metadata) | **PUT** /api/v1/metrics/{metric_name} | Edit metric metadata |
+| Method | HTTP request | Description |
+| ------------------------------------------------------------------ | ------------------------------------- | ----------------------- |
+| [**get_metric_metadata**](MetricsAPI.md#get_metric_metadata) | **GET** /api/v1/metrics/{metric_name} | Get metric metadata |
+| [**list_active_metrics**](MetricsAPI.md#list_active_metrics) | **GET** /api/v1/metrics | Get active metrics list |
+| [**list_metrics**](MetricsAPI.md#list_metrics) | **GET** /api/v1/search | Search metrics |
+| [**query_metrics**](MetricsAPI.md#query_metrics) | **GET** /api/v1/query | Query timeseries points |
+| [**submit_metrics**](MetricsAPI.md#submit_metrics) | **POST** /api/v1/series | Submit metrics |
+| [**update_metric_metadata**](MetricsAPI.md#update_metric_metadata) | **PUT** /api/v1/metrics/{metric_name} | Edit metric metadata |
-
## get_metric_metadata
> <MetricMetadata> get_metric_metadata(metric_name)
Get metadata about a specific metric.
@@ -52,13 +51,13 @@
end
```
### Parameters
-| Name | Type | Description | Notes |
-| ---- | ---- | ----------- | ----- |
-| **metric_name** | **String** | Name of the metric for which to get metadata. | |
+| Name | Type | Description | Notes |
+| --------------- | ---------- | --------------------------------------------- | ----- |
+| **metric_name** | **String** | Name of the metric for which to get metadata. | |
### Return type
[**MetricMetadata**](MetricMetadata.md)
@@ -69,11 +68,10 @@
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
-
## list_active_metrics
> <MetricsListResponse> list_active_metrics(from, opts)
Get the list of actively reporting metrics from a given time until now.
@@ -116,15 +114,15 @@
end
```
### Parameters
-| Name | Type | Description | Notes |
-| ---- | ---- | ----------- | ----- |
-| **from** | **Integer** | Seconds since the Unix epoch. | |
-| **host** | **String** | Hostname for filtering the list of metrics returned. If set, metrics retrieved are those with the corresponding hostname tag. | [optional] |
-| **tag_filter** | **String** | Filter metrics that have been submitted with the given tags. Supports boolean and wildcard expressions. Cannot be combined with other filters. | [optional] |
+| Name | Type | Description | Notes |
+| -------------- | ----------- | ---------------------------------------------------------------------------------------------------------------------------------------------- | ---------- |
+| **from** | **Integer** | Seconds since the Unix epoch. | |
+| **host** | **String** | Hostname for filtering the list of metrics returned. If set, metrics retrieved are those with the corresponding hostname tag. | [optional] |
+| **tag_filter** | **String** | Filter metrics that have been submitted with the given tags. Supports boolean and wildcard expressions. Cannot be combined with other filters. | [optional] |
### Return type
[**MetricsListResponse**](MetricsListResponse.md)
@@ -135,11 +133,10 @@
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
-
## list_metrics
> <MetricSearchResponse> list_metrics(q)
Search for metrics from the last 24 hours in Datadog.
@@ -178,13 +175,13 @@
end
```
### Parameters
-| Name | Type | Description | Notes |
-| ---- | ---- | ----------- | ----- |
-| **q** | **String** | Query string to search metrics upon. Must be prefixed with `metrics:`. | |
+| Name | Type | Description | Notes |
+| ----- | ---------- | -------------------------------------------------------------------------------- | ----- |
+| **q** | **String** | Query string to search metrics upon. Must be prefixed with `metrics:`. | |
### Return type
[**MetricSearchResponse**](MetricSearchResponse.md)
@@ -195,11 +192,10 @@
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
-
## query_metrics
> <MetricsQueryResponse> query_metrics(from, to, query)
Query timeseries points.
@@ -240,15 +236,15 @@
end
```
### Parameters
-| Name | Type | Description | Notes |
-| ---- | ---- | ----------- | ----- |
-| **from** | **Integer** | Start of the queried time period, seconds since the Unix epoch. | |
-| **to** | **Integer** | End of the queried time period, seconds since the Unix epoch. | |
-| **query** | **String** | Query string. | |
+| Name | Type | Description | Notes |
+| --------- | ----------- | --------------------------------------------------------------- | ----- |
+| **from** | **Integer** | Start of the queried time period, seconds since the Unix epoch. | |
+| **to** | **Integer** | End of the queried time period, seconds since the Unix epoch. | |
+| **query** | **String** | Query string. | |
### Return type
[**MetricsQueryResponse**](MetricsQueryResponse.md)
@@ -259,11 +255,10 @@
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
-
## submit_metrics
> <IntakePayloadAccepted> submit_metrics(body, opts)
The metrics end-point allows you to post time-series data that can be graphed on Datadog’s dashboards.
@@ -274,18 +269,18 @@
- 64 bits for the timestamp
- 32 bits for the value
- 20 bytes for the metric names
- 50 bytes for the timeseries
- The full payload is approximately 100 bytes. However, with the DogStatsD API,
-compression is applied, which reduces the payload size.
+ compression is applied, which reduces the payload size.
### Examples
```ruby
require 'datadog_api_client'
api_instance = DatadogAPIClient::V1::MetricsAPI.new
-body = DatadogAPIClient::V1::MetricsPayload.new({series: [DatadogAPIClient::V1::Series.new({metric: 'system.load.1', points: [[3.56]]})]}) # MetricsPayload |
+body = DatadogAPIClient::V1::MetricsPayload.new({series: [DatadogAPIClient::V1::Series.new({metric: 'system.load.1', points: [[3.56]]})]}) # MetricsPayload |
opts = {
content_encoding: DatadogAPIClient::V1::MetricContentEncoding::DEFLATE # MetricContentEncoding | HTTP header used to compress the media-type.
}
begin
@@ -315,14 +310,14 @@
end
```
### Parameters
-| Name | Type | Description | Notes |
-| ---- | ---- | ----------- | ----- |
-| **body** | [**MetricsPayload**](MetricsPayload.md) | | |
-| **content_encoding** | **MetricContentEncoding** | HTTP header used to compress the media-type. | [optional] |
+| Name | Type | Description | Notes |
+| -------------------- | --------------------------------------- | -------------------------------------------- | ---------- |
+| **body** | [**MetricsPayload**](MetricsPayload.md) | | |
+| **content_encoding** | **MetricContentEncoding** | HTTP header used to compress the media-type. | [optional] |
### Return type
[**IntakePayloadAccepted**](IntakePayloadAccepted.md)
@@ -331,13 +326,12 @@
[apiKeyAuth](README.md#apiKeyAuth)
### HTTP request headers
- **Content-Type**: text/json
-- **Accept**: text/json
+- **Accept**: text/json, application/json
-
## update_metric_metadata
> <MetricMetadata> update_metric_metadata(metric_name, body)
Edit metadata of a specific metric. Find out more about [supported types](https://docs.datadoghq.com/developers/metrics).
@@ -377,14 +371,14 @@
end
```
### Parameters
-| Name | Type | Description | Notes |
-| ---- | ---- | ----------- | ----- |
-| **metric_name** | **String** | Name of the metric for which to edit metadata. | |
-| **body** | [**MetricMetadata**](MetricMetadata.md) | New metadata. | |
+| Name | Type | Description | Notes |
+| --------------- | --------------------------------------- | ---------------------------------------------- | ----- |
+| **metric_name** | **String** | Name of the metric for which to edit metadata. | |
+| **body** | [**MetricMetadata**](MetricMetadata.md) | New metadata. | |
### Return type
[**MetricMetadata**](MetricMetadata.md)
@@ -394,6 +388,5 @@
### HTTP request headers
- **Content-Type**: application/json
- **Accept**: application/json
-