# Usage Object

> Source: https://truto.one/docs/api-reference/unified-usage-metering-api/usage/

Schema for the `Usage` resource in **Unified Usage Metering API**.

## Properties

- **`id`** _(string, required)_
  Unique identifier for the usage.
- **`product`** _(object)_
  The product associated with the usage.
  - **`id`** _(string, required)_
    Unique identifier for the product.
  - **`name`** _(string)_
    Name of the product.
- **`metric_name`** _(string)_
  Name of the metric being charged for
- **`resources`** _(array<object>)_
  - **`id`** _(string)_
    Unique identifier for the resource.
  - **`name`** _(string)_
    Name of the resource.
  - **`workspace`** _(object)_
    The resource is present in this workspace.
    - **`id`** _(string)_
      Unique identifier for the workspace.
    - **`name`** _(string)_
      Name of the workspace.
- **`organization`** _(object)_
  The organization associated with the usage.
  - **`id`** _(string, required)_
    Unique identifier for the organization.
  - **`name`** _(string)_
    Name of the organization.
- **`user`** _(object)_
  User attributed to the usage row when the vendor exposes a user pivot. Omit for org-level or aggregated rows.
  - **`id`** _(string)_
    Unique identifier for the user in the source application.
  - **`email`** _(string)_
    Primary email of the user.
  - **`name`** _(string)_
    Display name of the user.
- **`model`** _(object)_
  AI model for the row when applicable. Omit for non-AI vendors.
  - **`id`** _(string)_
    Model identifier (e.g. claude-sonnet-4-6, gpt-5).
  - **`provider`** _(string)_
    Provider hosting the model (e.g. anthropic, openai, cursor).
- **`charges`** _(array<object>)_
  The amounts charged for the usage.
  - **`amount`** _(number)_
    The amount charged for the usage.
  - **`currency`** _(string)_
    The currency in which the charge is made.
  - **`type`** _(string)_
    The type of charge.
    Allowed: `total`, `net`, `on_demand`, `committed`, `included`, `usage_based`, `discount`, `tax`, `credit`, `platform_fee`
- **`usage`** _(object)_
  The usage data for the product.
  - **`quantity`** _(number)_
    Generic quantity (e.g. Confluent).
  - **`unit`** _(string)_
    Unit for quantity (e.g. GB, request, hour).
  - **`requests`** _(object)_
    - **`total`** _(number)_
    - **`chat`** _(number)_
    - **`agent`** _(number)_
    - **`composer`** _(number)_
    - **`cmdk`** _(number)_
      Inline edit (e.g. Cursor Cmd+K).
    - **`tab_shown`** _(number)_
    - **`tab_accepted`** _(number)_
    - **`api_key`** _(number)_
    - **`included`** _(number)_
    - **`usage_based`** _(number)_
    - **`bugbot`** _(number)_
  - **`sessions`** _(object)_
    - **`distinct`** _(number)_
    - **`dispatch_turns`** _(number)_
      Cowork / background dispatch turns.
  - **`conversations`** _(object)_
    - **`distinct`** _(number)_
    - **`message_count`** _(number)_
    - **`thinking_message_count`** _(number)_
    - **`shared_viewed_count`** _(number)_
    - **`turn_count`** _(number)_
    - **`thread_count`** _(number)_
  - **`code`** _(object)_
    - **`lines_added`** _(number)_
    - **`lines_removed`** _(number)_
    - **`lines_accepted_added`** _(number)_
    - **`lines_accepted_removed`** _(number)_
    - **`applies`** _(number)_
    - **`accepts`** _(number)_
    - **`rejects`** _(number)_
    - **`commits`** _(number)_
    - **`pull_requests`** _(number)_
    - **`tool_actions`** _(object)_
      Per-tool accept/reject counts (e.g. Claude Code).
    - **`file_extensions`** _(object)_
      - **`apply_most_used`** _(string)_
      - **`tab_most_used`** _(string)_
  - **`tokens`** _(object)_
    - **`input`** _(number)_
    - **`output`** _(number)_
    - **`cache_read`** _(number)_
    - **`cache_write`** _(number)_
    - **`cache_write_ephemeral_5m`** _(number)_
    - **`cache_write_ephemeral_1h`** _(number)_
    - **`total`** _(number)_
  - **`tools`** _(object)_
    - **`web_search_count`** _(number)_
    - **`connectors_used_count`** _(number)_
    - **`distinct_connectors_used_count`** _(number)_
    - **`skills_used_count`** _(number)_
    - **`distinct_skills_used_count`** _(number)_
    - **`action_count`** _(number)_
  - **`activity`** _(object)_
    - **`is_active`** _(boolean)_
    - **`max_mode`** _(boolean)_
    - **`client_version`** _(string)_
- **`start_date`** _(string)_
  The start date for the usage data.
- **`end_date`** _(string)_
  The end date for the usage data.
- **`created_at`** _(string)_
  Date and time when the usage data metric was created.
- **`updated_at`** _(string)_
  Date and time when the usage data metric was last updated.
- **`surface`** _(string)_
  Specific product surface for this row when the source exposes a single surface, such as chat, claude_code, cowork, office_agent, composer, or api. Omit when the row is aggregate and no per-surface split exists.
- **`remote_data`** _(object)_
  Raw data returned from the remote API call.

## Methods

- [GET /unified/usage-metering/usage](/docs/api-reference/unified-usage-metering-api/usage/list) — List Usage
