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

# Get Credit Usage

> Credit balance plus the recent ledger entries that explain it.



## OpenAPI

````yaml /openapi.json get /account/credits
openapi: 3.1.0
info:
  title: Corpus API
  description: >-
    Point-in-time financial and governed-document data for the US, India, and
    China.
  version: '2026-07-20'
servers:
  - url: https://corpus-api.onera.app
    description: Production
security: []
paths:
  /account/credits:
    get:
      tags:
        - Account
      summary: Get Credit Usage
      description: Credit balance plus the recent ledger entries that explain it.
      operationId: get_credit_usage_account_credits_get
      parameters:
        - name: limit
          in: query
          required: false
          schema:
            type: integer
            maximum: 1000
            minimum: 1
            default: 100
            title: Limit
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CreditUsageResponse'
        '400':
          description: Invalid parameter combination
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '401':
          description: Missing or invalid API key
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '403':
          description: Insufficient jurisdiction or scope
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: Unknown resource
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '422':
          description: Request schema validation failed
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '429':
          description: Rate limit exceeded
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '503':
          description: Source content is unavailable or still processing
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      security:
        - X-API-KEY: []
components:
  schemas:
    CreditUsageResponse:
      properties:
        account_id:
          type: string
          title: Account Id
        balance:
          type: integer
          title: Balance
        entries:
          items:
            $ref: '#/components/schemas/CreditEntry'
          type: array
          title: Entries
      type: object
      required:
        - account_id
        - balance
        - entries
      title: CreditUsageResponse
    ErrorResponse:
      properties:
        error:
          type: string
          title: Error
        message:
          type: string
          title: Message
        request_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Request Id
      type: object
      required:
        - error
        - message
      title: ErrorResponse
    CreditEntry:
      properties:
        at:
          type: string
          format: date-time
          title: At
        delta:
          type: integer
          title: Delta
        reason:
          type: string
          title: Reason
        route:
          anyOf:
            - type: string
            - type: 'null'
          title: Route
        key_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Key Id
      type: object
      required:
        - at
        - delta
        - reason
      title: CreditEntry
  securitySchemes:
    X-API-KEY:
      type: apiKey
      in: header
      name: X-API-KEY
      description: >-
        Provisioned Corpus API key with the required jurisdiction and operation
        scopes.

````