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

# guides

# Billing & Payment Operations

Process payments and establish billing agreements with customers.

## What is Billing & Payment Operations?

<Card title="Core Payment Processing" icon="credit-card">
  Handle one time payments and establish recurring billing agreements with customers through their banks using secure payment ids.
</Card>

## Key Operations

<CardGroup cols={2}>
  <Card title="Billing Intent" icon="handshake">
    Establish billing agreements with customers
  </Card>

  <Card title="Customer Billing" icon="money-bill">
    Process payments using established agreements
  </Card>
</CardGroup>

## How It Works

<Steps>
  <Step title="Create Billing Intent">Request permission from customer to establish billing agreement</Step>
  <Step title="Customer Approval">Customer approves through their bank (approve\_once or approve\_recurring)</Step>
  <Step title="Receive Payment ID">Get encrypted payment id for future billing</Step>
  <Step title="Process Payments">Use payment id to bill customer</Step>
</Steps>

### Create Billing Intent

<CodeGroup>
  ```json Request theme={null}
  {
    "lookupIDs": ["customer-lookup-phrase"],
    "currency": "NGN",
    "description": "Netflix subscription billing authorization"
  }
  ```

  ```bash cURL theme={null}
  curl -X POST "https://api.peere.network/v1/billing/intent" \
    -H "Authorization: Bearer YOUR_TOKEN" \
    -H "Content-Type: application/json" \
    -d '{
      "lookupIDs": ["customer-lookup-phrase"],
      "currency": "NGN",
      "description": "Netflix subscription billing authorization"
    }'
  ```
</CodeGroup>

### Bill Customer

<CodeGroup>
  ```json Request theme={null}
  {
    "paymentIDs": ["customer-agreement-phrase"],
    "amount": 1500,
    "currency": "NGN",
    "description": "Netflix Premium - January 2024"
  }
  ```

  ```bash cURL theme={null}
  curl -X POST "https://api.peere.network/v1/customer/bill" \
    -H "Authorization: Bearer YOUR_TOKEN" \
    -H "Content-Type: application/json" \
    -d '{
      "paymentIDs": ["customer-agreement-phrase"],
      "amount": 1500,
      "currency": "NGN",
      "description": "Netflix Premium - January 2024"
    }'
  ```
</CodeGroup>

## Customer Decision Types

<CardGroup cols={2}>
  <Card title="approve_once" icon="check" color="#4377e7">
    Customer must approve each transaction individually
  </Card>

  <Card title="approve_recurring" icon="arrows-rotate" color="#10b981">
    Automatic approval for future transactions (trusted merchants)
  </Card>
</CardGroup>

## Use Cases

<Tabs>
  <Tab title="One Time Payments">Process single payments for purchases or services with customer approval.</Tab>
  <Tab title="Subscription Billing">Set up recurring billing for subscriptions with customer authorization.</Tab>
  <Tab title="On Demand Billing">Bill customers when they use your service (like ride sharing or utilities).</Tab>
</Tabs>

<Note>You'll receive customer decisions via webhook notifications. See [Webhooks Documentation](/guides/getting-started/webhooks) for implementation details.</Note>

## Next Steps

After implementing billing operations:

1. [Recurring Billing](/merchant-apis/recurring-billing/overview) for automated subscriptions
2. [Transaction Management](/merchant-apis/transaction-management/overview) to track payments
3. [Refund Management](/merchant-apis/refund-management/overview) to handle refunds
