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

# Report subscription usage



## OpenAPI

````yaml specs/billing_api_docs.json post /api/v1/subscriptions/billing-metric/report-usage
openapi: 3.0.1
info:
  title: Billing API
  description: Billing service for managing subscriptions, payments, and entitlements
  contact: {}
  version: '1.0'
servers:
  - url: https://dev-billing-api.iqraa.ai/api/v1
security: []
tags:
  - name: Customers
    description: Customers related endpoints
  - name: Subscriptions
    description: Subscription related endpoints
  - name: Plans
    description: Plans related endpoints
  - name: Entitlements
    description: Entitlements related endpoints
  - name: Payments
    description: Payments related endpoints
  - name: Emails
    description: Email related endpoints
paths:
  /api/v1/subscriptions/billing-metric/report-usage:
    post:
      tags:
        - Subscriptions
      summary: Report subscription usage
      operationId: SubscriptionController_reportUsage
      parameters:
        - name: x-admin-api-key
          in: header
          description: The API key to access the admin API
          required: true
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SubscriptionReportUsageDto'
      responses:
        '201':
          description: Usage reported successfully
        '400':
          description: Bad request
      security:
        - bearer: []
components:
  schemas:
    SubscriptionReportUsageDto:
      type: object
      properties:
        externalSubscriptionId:
          type: string
          description: Unique identifier of the subscription in your application
          example: 0c7b0eb6-3411-4dd3-9e24-d2a8edbb504a
        billableMetricCode:
          type: string
          description: Code that identifies a targeted billable metric
          example: storage
        properties:
          type: object
          example:
            gb: 100
      required:
        - externalSubscriptionId
        - billableMetricCode
        - properties
  securitySchemes:
    bearer:
      scheme: bearer
      bearerFormat: opaque
      type: http

````