> ## Documentation Index
> Fetch the complete documentation index at: https://docs.stigg.io/llms.txt
> Use this file to discover all available pages before exploring further.

# UsageHistoryV2Input

> Input parameters for retrieving usage history



**Kind**: `input`

## Fields

**`customerId`**: `String!` (required)

Customer id

---

**`endDate`**: `DateTime`

The end date of the range

---

**`environmentId`**: `UUID`

The unique identifier for the environment

---

**`featureId`**: `String!` (required)

Feature id

---

**`groupBy`**: `[String!]`

Criteria by which to group the usage history

---

**`includeInactiveSubscriptions`**: `Boolean`

When true, includes usage data from the most recent cancelled or expired subscription

---

**`paging`**: `CursorPaging`

Cursor pagination over series groups. When omitted, all groups are returned and no pageInfo is emitted.

---

**`resourceId`**: `String`

The customer resource this usage applies to. Optional — only required if the customer has multiple resources (for example, one subscription per workspace or site) and usage needs to be tracked separately per resource; omit it to report usage at the customer level.

---

**`startDate`**: `DateTime!` (required)

The start date of the range



## Related topics

- [Go SDK](https://docs.stigg.io/api-and-sdks/changelog/backend-graphql/go.md)
- [UsageHistoryInput](https://docs.stigg.io/graphql-reference/types/UsageHistoryInput.md)
- [UsageHistoryV2](https://docs.stigg.io/graphql-reference/types/UsageHistoryV2.md)
- [usageHistoryV2](https://docs.stigg.io/graphql-reference/queries/usageHistoryV2.md)
- [Node.js SDK](https://docs.stigg.io/api-and-sdks/changelog/backend-graphql/node.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.