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

# Custom Metrics & Unit Economics

> Inject external business or technical metrics into Pelanor—whether you need unit-economics KPIs (e.g., cost per API call) or simply want to display custom metrics alongside cloud costs.

## Overview

Custom metrics add context to your cloud spend. They power two primary use-cases:

1. **Unit Economics** – combine cost with a business KPI (users, API calls, GB processed) to track efficiency trends.
2. **Enhanced Reporting** – surface any metric as a column, filter, or chart in standard Pelanor reports and dashboards.

***

## Metric Types

| Type                    | Description                                    | Example                           | Best For                         |
| ----------------------- | ---------------------------------------------- | --------------------------------- | -------------------------------- |
| **Basic Metrics**       | A single count value per timestamp.            | Total daily active users          | Org-level KPIs (users, requests) |
| **Dimensional Metrics** | Metric values split by one or more properties. | Active users per *region* per day | Deeper analysis across segments  |

## Getting Started

### Integration Options

#### API Integration *(recommended)*

<Steps>
  <Step title="Open Custom Metrics">
    Navigate to **Unit Cost → Custom Metrics** in Pelanor.
  </Step>

  <Step title="Review the API Guide">
    Click **API Documentation** to view payload schemas and examples.
  </Step>

  <Step title="Send Your Data">
    POST metrics to the `/v1/custom-metrics` endpoint using the documented format.
  </Step>
</Steps>

[Pelanor API Docs](https://app.pelanor.io/api-docs#tag/default/put/v1/custom-metrics/)

***

<Tabs>
  <Tab title="Direct Data Upload">
    1. Pelanor can ingest periodic CSVs dropped into a dedicated S3 bucket or uploaded manually.<br />
    2. Contact Support to configure ingestion.
  </Tab>

  <Tab title="Autonomous Collection">
    Pelanor can pull metrics from common observability back-ends:

    * **Datadog**
    * **Amazon CloudWatch**
    * **Snowflake**

    Reach out to enable automatic collection.
  </Tab>
</Tabs>

<Info>
  After upload, processing may take a few minutes before metrics become searchable.
</Info>

***

## Accessing Your Metrics

Imported metrics appear in two places:

1. **Reports & Dashboards** – add a metric as a column, filter, or chart just like built-in cost metrics.
2. **Unit Cost Dashboard** – a purpose-built view that pairs cost with a denominator metric to compute unit costs.

***

### Unit Cost Dashboard

<Frame>
  <img src="https://mintlify.s3.us-west-1.amazonaws.com/pelanor-6a347cfc/images/unit-economics-1.png" alt="Unit Economics Dashboard Screenshot" />
</Frame>

#### Cost Filters

Refine which costs participate in unit-cost calculations—for example, include only production spend or tag-based subsets.

<Frame>
  <img src="https://mintlify.s3.us-west-1.amazonaws.com/pelanor-6a347cfc/images/unit-economics-2.png" alt="Cost Filter Settings" />
</Frame>

***

## Using the Dashboard

<Steps>
  <Step title="Configure Cost Filters">
    Select which resources should count toward your calculations.
  </Step>

  <Step title="Set Date Range">
    Choose the analysis window (daily, weekly, monthly).
  </Step>

  <Step title="Choose Aggregation">
    Pick how to roll up data—daily, weekly, or monthly.
  </Step>
</Steps>

<Tabs>
  <Tab title="Basic Metrics">
    <ul>
      <li>Current vs. previous period summaries</li>
      <li>Unit-cost trends</li>
      <li>Cost-distribution charts</li>
      <li>Detailed tables</li>
    </ul>

    <Frame>
      <img src="https://mintlify.s3.us-west-1.amazonaws.com/pelanor-6a347cfc/images/unit-economics-3.png" alt="Basic Metrics Dashboard" />
    </Frame>
  </Tab>

  <Tab title="Dimensional Metrics">
    Includes everything from Basic Metrics, plus segment breakdowns (e.g., by region).

    <Frame>
      <img src="https://mintlify.s3.us-west-1.amazonaws.com/pelanor-6a347cfc/images/unit-economics-4.png" alt="Dimensional Metrics Dashboard" />
    </Frame>
  </Tab>
</Tabs>

***

## Working with Widgets

<Steps>
  <Step title="Add Widget to Dashboard">
    In any widget menu, click **Add to dashboard**.

    <Frame>
      <img src="https://mintlify.s3.us-west-1.amazonaws.com/pelanor-6a347cfc/images/unit-economics-5.png" alt="Add Widget" />
    </Frame>
  </Step>

  <Step title="Select Destination">
    Choose which dashboard should host the widget.

    <Frame>
      <img src="https://mintlify.s3.us-west-1.amazonaws.com/pelanor-6a347cfc/images/unit-economics-6.png" alt="Select Dashboard" />
    </Frame>
  </Step>

  <Step title="View the Widget">
    The widget is appended to the destination dashboard automatically.
  </Step>
</Steps>
