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

# Get Billing History

Get billing history including purchases, payments, and usage.

<ParamField query="page" type="integer">
  Page number (default: 1)
</ParamField>

<ParamField query="page_size" type="integer">
  Items per page (default: 20, max: 100)
</ParamField>

<ParamField query="type" type="string">
  Filter by type (purchase, payment, usage)
</ParamField>

<Warning>
  Requires authentication. Include the access token in the Authorization header.
</Warning>

## Success Response (200)

<ResponseField name="count" type="integer">
  Total number of billing records
</ResponseField>

<ResponseField name="next" type="string">
  URL to next page (nullable)
</ResponseField>

<ResponseField name="previous" type="string">
  URL to previous page (nullable)
</ResponseField>

<ResponseField name="results" type="array">
  Array of billing history objects
</ResponseField>

<ResponseField name="results[].id" type="string">
  Billing record ID
</ResponseField>

<ResponseField name="results[].type" type="string">
  Record type (purchase, payment, usage)
</ResponseField>

<ResponseField name="results[].description" type="string">
  Description of the transaction
</ResponseField>

<ResponseField name="results[].amount" type="float">
  Transaction amount (negative for usage)
</ResponseField>

<ResponseField name="results[].currency" type="string">
  Currency code
</ResponseField>

<ResponseField name="results[].status" type="string">
  Transaction status
</ResponseField>

<ResponseField name="results[].created_at" type="string">
  Creation timestamp (ISO 8601)
</ResponseField>

<ResponseExample>
  ```json theme={null}
  {
    "count": 50,
    "next": "https://mifumosms.mifumolabs.com/api/billing/history/?page=2",
    "previous": null,
    "results": [
      {
        "id": "550e8400-e29b-41d4-a716-446655440000",
        "type": "purchase",
        "description": "Starter Package - 1000 SMS",
        "amount": 50.00,
        "currency": "USD",
        "status": "completed",
        "created_at": "2025-11-01T10:00:00Z"
      },
      {
        "id": "550e8400-e29b-41d4-a716-446655440001",
        "type": "usage",
        "description": "SMS Usage - 500 messages",
        "amount": -25.00,
        "currency": "USD",
        "status": "completed",
        "created_at": "2025-11-15T10:00:00Z"
      }
    ]
  }
  ```
</ResponseExample>
