> ## 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.

# Purchase SMS Package

Purchase an SMS package.

<ParamField body="package_id" type="string" required>
  Package ID
</ParamField>

<ParamField body="payment_method" type="string" required>
  Payment method (e.g., mobile\_money, card)
</ParamField>

<ParamField body="provider" type="string">
  Payment provider (e.g., mpesa, tigopesa)
</ParamField>

## Request Example

<RequestExample>
  ```json theme={null}
  {
    "package_id": "550e8400-e29b-41d4-a716-446655440000",
    "payment_method": "mobile_money",
    "provider": "mpesa"
  }
  ```
</RequestExample>

## Success Response (201)

<ResponseExample>
  ```json theme={null}
  {
    "success": true,
    "purchase": {
      "id": "550e8400-e29b-41d4-a716-446655440000",
      "package_name": "Starter Package",
      "sms_count": 1000,
      "price": 50.00,
      "currency": "USD",
      "status": "pending",
      "payment_url": "https://payment.gateway.com/pay/xyz123",
      "created_at": "2025-11-27T10:30:00Z"
    }
  }
  ```
</ResponseExample>
