/billing

Get Monthly Usage Endpoint

Changed on

Get monthly usage data for a tenant with validation for year and month parameters.

Args: request: Request object containing year and month with validation user_context: User context with tenant admin permissions resource_id: Optional[UUID]. If provided, get usage data for a specific resource. Otherwise, get aggregated usage data across all resources.

Returns: Monthly usage records for the specified month and year

get/billing/usages/monthly

Request

  • Base URL
    https://api.contextual.ai/v1
  • URL
    https://api.contextual.ai/v1/billing/usages/monthly
  • Auth
    HTTP bearer

Query parameters

yearinteger required
monthinteger required
resource_idstring uuid nullable

Response

Successful Response

Changes