---
title: "Get user usage detail"
method: GET
path: "/user-usage-detail"
tags: ["entitlements"]
---

# Get user usage detail

`GET /user-usage-detail`

## Query parameters

- `company_id` string, required — Company the user belongs to
- `end_time` string, date-time — End of the usage window (exclusive); defaults to now
- `start_time` string, date-time — Start of the usage window; defaults to 30 days before the end
- `user_id` string, required — User to break usage down for

## Response `200`

OK

- object
  - `data` UserUsageDetailResponseData, required
    - `credits` UserCreditUsageResponseData[], required — The user's net credit consumption within the window
      - `billing_credit_id` string, required
      - `credit_name` string, required — The display name of the credit type
      - `credits_used` number, double, required — The user's net track-driven consumption of the credit within the window (draws minus refunds)
      - `share` number, double, required — This row's fraction (0-1) of the company's total track-driven consumption of the credit within the window, including unattributed consumption
      - `user` UserResponseData
        - `created_at` string, date-time, required
        - `environment_id` string, required
        - `id` string, required
        - `last_seen_at` string, date-time, nullable
        - `name` string, required
        - `updated_at` string, date-time, required
      - `user_id` string, nullable — The user the consumption is attributed to; null for unattributed consumption
    - `daily_credit_points` UserDailyCreditPointResponseData[], required — The user's net credit consumption by UTC day
      - `credits_used` number, double, required — The user's net credit consumption on the day
      - `date` string, date-time, required — The UTC day
    - `daily_points` UserDailyUsagePointResponseData[], required — The user's per-feature usage by UTC day
      - `date` string, date-time, required — The UTC day
      - `feature` FeatureResponseData
        - `created_at` string, date-time, required
        - `description` string, required
        - `event_subtype` string, nullable
        - `feature_type` 'boolean' | 'event' | 'license' | 'trait', required
        - `icon` string, required
        - `id` string, required
        - `license_id` string, nullable — The license sold through this feature. Set only on features of type license, and created automatically with them.
        - `lifecycle_phase` 'add_on' | 'alpha' | 'beta' | 'deprecated' | 'ga' | 'inactive' | 'in_plan' | 'internal_testing' | 'legacy'
        - `maintainer_account_member_id` string, nullable
        - `name` string, required
        - `plural_name` string, nullable
        - `singular_name` string, nullable
        - `trait_id` string, nullable
        - `updated_at` string, date-time, required
        - `usage_limit_trait_id` string, nullable — Set when the feature carries a pay-in-advance quantity. Provisioned lazily for other feature types, and at creation for license features.
      - `value` integer, required — The user's usage of the feature on the day
    - `end_time` string, date-time, required — End of the usage window (exclusive)
    - `feature_totals` UserFeatureUsageResponseData[], required — The user's per-feature usage totals within the window
      - `feature` FeatureResponseData
        - `created_at` string, date-time, required
        - `description` string, required
        - `event_subtype` string, nullable
        - `feature_type` 'boolean' | 'event' | 'license' | 'trait', required
        - `icon` string, required
        - `id` string, required
        - `license_id` string, nullable — The license sold through this feature. Set only on features of type license, and created automatically with them.
        - `lifecycle_phase` 'add_on' | 'alpha' | 'beta' | 'deprecated' | 'ga' | 'inactive' | 'in_plan' | 'internal_testing' | 'legacy'
        - `maintainer_account_member_id` string, nullable
        - `name` string, required
        - `plural_name` string, nullable
        - `singular_name` string, nullable
        - `trait_id` string, nullable
        - `updated_at` string, date-time, required
        - `usage_limit_trait_id` string, nullable — Set when the feature carries a pay-in-advance quantity. Provisioned lazily for other feature types, and at creation for license features.
      - `last_seen` string, date-time, required — When the user last used the feature within the window
      - `share` number, double, required — This row's fraction (0-1) of the company's total usage of the feature within the window, including unattributed usage
      - `user` UserResponseData
        - `created_at` string, date-time, required
        - `environment_id` string, required
        - `id` string, required
        - `last_seen_at` string, date-time, nullable
        - `name` string, required
        - `updated_at` string, date-time, required
      - `user_id` string, nullable — The user the usage is attributed to; null for unattributed usage
      - `value` integer, required — The user's usage of the feature within the window
    - `start_time` string, date-time, required — Start of the usage window
    - `user` UserResponseData
      - `created_at` string, date-time, required
      - `environment_id` string, required
      - `id` string, required
      - `last_seen_at` string, date-time, nullable
      - `name` string, required
      - `updated_at` string, date-time, required
  - `params` object, required — Input parameters
    - `company_id` string — Company the user belongs to
    - `end_time` string, date-time — End of the usage window (exclusive); defaults to now
    - `start_time` string, date-time — Start of the usage window; defaults to 30 days before the end
    - `user_id` string — User to break usage down for

## Other responses

- `401` — Unauthorized
- `403` — Forbidden
- `404` — Not found
- `500` — Server error

---

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