---
title: "Get Agent Usage"
method: GET
path: "/v2/gen-ai/agents/{uuid}/usage"
tags: ["DigitalOcean-public.v2-new_GradientAI Platform"]
---

# Get Agent Usage

`GET /v2/gen-ai/agents/{uuid}/usage`

To get agent usage, send a GET request to `/v2/gen-ai/agents/{uuid}/usage`. Returns usage metrics for the specified agent within the provided time range.

## Path parameters

- `uuid` string, required

## Query parameters

- `start` string
- `stop` string

## Response `200`

A successful response.

- ApiGetAgentUsageOutput — Agent usage
  - `log_insights_usage` ApiResourceUsage — Resource Usage Description
    - `measurements` ApiUsageMeasurement[]
      - `tokens` integer
      - `usage_type` string
    - `resource_uuid` string
    - `start` string, date-time
    - `stop` string, date-time
  - `usage` ApiResourceUsage — Resource Usage Description
    - `measurements` ApiUsageMeasurement[]
      - `tokens` integer
      - `usage_type` string
    - `resource_uuid` string
    - `start` string, date-time
    - `stop` string, date-time

## Other responses

- `401` — Authentication failed due to invalid credentials.
- `404` — The resource was not found.
- `429` — The API rate limit has been exceeded.
- `500` — There was a server error.
- `default` — There was an unexpected error.

---

[API](https://skmtc.net/digitalocean/apis/digitalocean-api.md) · [All operations](https://skmtc.net/digitalocean/apis/digitalocean-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/digitalocean/digitalocean-api/versions/cb3bf9b21459/schema)
