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

# Get billing statistics

> Returns usage for the current team from nightly usage snapshots. Billable endpoint, billable user, and premium integration counts come from the latest snapshot in the range. Ingested byte totals sum the ingestion days in the range; snapshots only include ingestion volume starting October 1, 2026. startDate and endDate are inclusive UTC ISO 8601 date-time strings, the range can be at most one year, and omitting both dates covers all snapshots. Byte totals are int64 values encoded as strings.



## OpenAPI

````yaml https://api.wirespeed.co/v1/openapi.json get /v1/billing/stats
openapi: 3.0.0
info:
  title: Wirespeed API
  description: The public Wirespeed API. v1 is the first stable contract.
  version: '1.0'
  contact: {}
servers:
  - url: https://api.wirespeed.co
security: []
tags: []
paths:
  /v1/billing/stats:
    get:
      tags:
        - Billing
      summary: Get billing statistics
      description: >-
        Returns usage for the current team from nightly usage snapshots.
        Billable endpoint, billable user, and premium integration counts come
        from the latest snapshot in the range. Ingested byte totals sum the
        ingestion days in the range; snapshots only include ingestion volume
        starting October 1, 2026. startDate and endDate are inclusive UTC ISO
        8601 date-time strings, the range can be at most one year, and omitting
        both dates covers all snapshots. Byte totals are int64 values encoded as
        strings.
      operationId: BillingController_getStats
      parameters:
        - name: startDate
          required: false
          in: query
          description: Start date (inclusive, ISO8601 string)
          schema:
            type: string
        - name: endDate
          required: false
          in: query
          description: End date (inclusive, ISO8601 string)
          schema:
            type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BillingStatsDto'
        '400':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HttpError'
      security:
        - bearer: []
components:
  schemas:
    BillingStatsDto:
      type: object
      properties:
        billableEndpoints:
          type: number
        billableUsers:
          type: number
        premiumIngestedBytes:
          type: string
          format: int64
          nullable: true
          description: Sum of premium ingested bytes across snapshots in the date range
        ingestedBytes:
          type: string
          format: int64
          nullable: true
          description: Sum of ingested bytes across snapshots in the date range
        premiumIntegrations:
          type: number
      required:
        - billableEndpoints
        - billableUsers
        - premiumIngestedBytes
        - ingestedBytes
        - premiumIntegrations
    HttpError:
      type: object
      properties:
        message:
          type: string
        statusCode:
          type: number
        code:
          type: string
          description: >-
            Stable machine-readable error code. Clients should branch and
            translate on this instead of `message`.
        params:
          type: object
          description: Values interpolated into the message for `code`.
          additionalProperties:
            oneOf:
              - type: string
              - type: number
              - type: boolean
            nullable: true
        validationErrors:
          description: >-
            Per-property failures when `code` is `VALIDATION_FAILED` from
            request validation.
          type: array
          items:
            $ref: '#/components/schemas/HttpValidationIssue'
      required:
        - message
        - statusCode
    HttpValidationIssue:
      type: object
      properties:
        property:
          type: string
          description: Dotted path of the invalid property.
        constraint:
          type: string
          description: >-
            class-validator constraint name; clients translate
            `errors:validation.<constraint>`.
        params:
          type: object
          description: Values interpolated into the constraint message.
          additionalProperties:
            oneOf:
              - type: string
              - type: number
              - type: boolean
            nullable: true
        code:
          type: string
          description: Catalog code overriding the constraint translation.
      required:
        - property
        - constraint
        - params
  securitySchemes:
    bearer:
      scheme: bearer
      bearerFormat: API key
      type: http
      description: >-
        Team API key sent as a Bearer token. Create a key in Wirespeed under
        Settings → Team. See
        https://docs.wirespeed.co/api-reference/authentication.

````

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