> ## Documentation Index
> Fetch the complete documentation index at: https://docs.sawmills.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# New Relic Destination

> Export OpenTelemetry metrics to New Relic via the native Metric API and agent listener endpoint for time-slice metrics in Sawmills pipelines.

## Supported Data Types

📈 **Metrics**

## Overview

The New Relic destination exports OpenTelemetry metrics to the New Relic Metric API. Summary metrics marked as time-slice metrics are exported via the New Relic agent listener endpoint.

## Configuration

| Field              | Type     | Default                                                           | Required | Description                                               |
| :----------------- | :------- | :---------------------------------------------------------------- | :------- | :-------------------------------------------------------- |
| Name               | String   | none                                                              | true     | Unique identifier within Sawmills.                        |
| API Key            | String   | none                                                              | true     | New Relic license key used to authenticate requests.      |
| Endpoint           | String   | `https://metric-api.newrelic.com/metric/v1`                       | true     | New Relic Metric API endpoint.                            |
| Agent Endpoint     | String   | `https://collector.newrelic.com/agent_listener/invoke_raw_method` | true     | New Relic agent listener endpoint for time-slice metrics. |
| Enabled Data Types | Checkbox | Metrics                                                           |          | The telemetry data types you want to export.              |

## Metric Mapping

* Gauge metrics map to `gauge`.
* Sum metrics map to `count` with `interval.ms` derived from start and end timestamps.
* Summary metrics map to `summary` with count/sum/min/max.
* Histogram metrics map to `summary` with count/sum/min/max.

Exponential histograms are not supported.

## Time-slice Metrics

Summary metrics are sent to the agent listener when they are marked as time-slice metrics or include New Relic agent attributes.
