---
title: "Get endpoint inference KV cache usage [READ]"
method: POST
path: "/v2/endpoint/{namespace}/{name}/metrics/inference/kv-cache"
tags: ["Metrics"]
---

# Get endpoint inference KV cache usage \[READ\]

`POST /v2/endpoint/{namespace}/{name}/metrics/inference/kv-cache`

## Request

- Base URL: `https://api.endpoints.huggingface.cloud` (the document declares no server; this is the origin it was published from)
- URL: `https://api.endpoints.huggingface.cloud/v2/endpoint/{namespace}/{name}/metrics/inference/kv-cache`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/huggingface/apis/hf-inference-endpoints-api/docs/v2/endpoint/:namespace/:name/metrics/inference/kv-cache/post.ts> (a function with typed inputs; its response is checked against the schema)

## Path parameters

- `namespace` string, required
- `name` string, required

## Request body

- MetricsParams
  - `replicaId` string, nullable: Optionally filter by replica ID
  - `start` string, date-time, required: RFC 3339 Date Format. Ex: 2021-01-01T00:00:00Z
  - `stop` string, date-time, required: RFC 3339 Date Format. Ex: 2021-01-01T00:00:00Z

## Response `200`

Endpoint metric returned successfully

- GraphHardware
  - `series` SeriesHardware[], required
    - `data` DataPoint[], required
      - `x` string, date-time, required
      - `y` number, float, required
    - `deviceId` integer, nullable
    - `max` number, float, nullable
    - `replicaId` string, required

## Changes

- **2026-09-18** `737c5c190b57`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/huggingface/apis/hf-inference-endpoints-api/changes/v2/endpoint/:namespace/:name/metrics/inference/kv-cache/post.md)

---

[API](https://skmtc.dev/huggingface/apis/hf-inference-endpoints-api.md) - [All operations](https://skmtc.dev/huggingface/apis/hf-inference-endpoints-api/llms.txt) - [OpenAPI document](https://skmtc.dev/huggingface/apis/hf-inference-endpoints-api/revisions/974d2a213e21?raw)
