---
title: "Get Granular Usage"
method: GET
path: "/api/v1/orgs/current/billing/granular-usage"
tags: ["orgs"]
---

# Get Granular Usage

`GET /api/v1/orgs/current/billing/granular-usage`

Get granular usage data with flexible grouping.

workspace_ids filters results to the specified workspaces. Only workspaces
the user has read access to will be included in the results.

## Query parameters

- `start_time` string, date-time, required
- `end_time` string, date-time, required
- `workspace_ids` string[], required
- `group_by` 'user' | 'api_key' | 'project' | 'workspace' — Dimensions for grouping granular usage data.

## Response `200`

Successful Response

- GranularUsageResponse — Response for granular usage query.
  - `stride` GranularUsageStride, required — Stride configuration for time bucketing - only ONE field should be non-zero.
    - `days` integer
    - `hours` integer
  - `usage` GranularUsageRecord[], required
    - `time_bucket` string, date-time, nullable
    - `dimensions` GranularUsageDimensions, required — Dimension values for a granular usage record.
      - `user_id` string, uuid, nullable
      - `user_email` string, nullable
      - `api_key_id` string, uuid, nullable
      - `api_key_short_key` string, nullable
      - `project_id` string, uuid, nullable
      - `project_name` string, nullable
      - `workspace_id` string, uuid, nullable
      - `workspace_name` string, nullable
    - `traces` integer

## Other responses

- `422` — Validation Error

---

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