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

# Metrics History

> Get historical data points for all services

# Metrics History

Retrieve historical online count data points for all services over the last 24 hours.

## Response

<ResponseField name="data" type="object">
  Object with service slugs as keys

  <Expandable title="History Object">
    <ResponseField name="[slug]" type="object">
      History data for each service

      <Expandable title="Service History">
        <ResponseField name="name" type="string">
          Display name of the service
        </ResponseField>

        <ResponseField name="points" type="array">
          Array of data points

          <Expandable title="Data Point">
            <ResponseField name="t" type="number">
              Unix timestamp in milliseconds
            </ResponseField>

            <ResponseField name="v" type="number">
              Online count value at that time
            </ResponseField>
          </Expandable>
        </ResponseField>
      </Expandable>
    </ResponseField>
  </Expandable>
</ResponseField>

## Example Request

```bash theme={null}
curl -X GET "https://www.orcrev.fit/api/metrics/history"
```

## Example Response

```json theme={null}
{
  "data": {
    "service-one": {
      "name": "Service One",
      "points": [
        { "t": 1703750400000, "v": 1250 },
        { "t": 1703754000000, "v": 1380 },
        { "t": 1703757600000, "v": 1520 }
      ]
    },
    "service-two": {
      "name": "Service Two",
      "points": [
        { "t": 1703750400000, "v": 850 },
        { "t": 1703754000000, "v": 920 }
      ]
    }
  }
}
```

<Tip>
  Use this endpoint to build charts and graphs showing online count trends over time.
</Tip>

<Warning>
  This endpoint returns data for the last 24 hours only. Older data is automatically pruned.
</Warning>

<ResponseExample>
  ```json Response theme={null}
  {
    "data": {
      "service-one": {
        "name": "Service One",
        "points": [
          { "t": 1703750400000, "v": 1250 },
          { "t": 1703754000000, "v": 1380 }
        ]
      }
    }
  }
  ```
</ResponseExample>
