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

# Quickstart

> Check your balance, create your first order and track its status.

**1. Get your API key**

We email your key (`bpk_xxxxxxxx_...`) to you when your account is created. Store it in server-side secret storage. See [Authentication](https://docs.balaipedia.com/authentication.md).

**2. Check your balance**

```bash theme={null}
curl https://orders.balaipedia.com/v1/balance \
  -H "Authorization: Bearer YOUR_KEY"
```

```json theme={null}
{"object":"balance","balance":42.35,"currency":"USD","price_per_order":0.15}
```

**3. Create an order**

We recommend sending an `Idempotency-Key` header (optional; 8-64 characters, e.g. a UUID) so a retry never creates the same order twice.

```bash theme={null}
curl -X POST https://orders.balaipedia.com/v1/orders \
  -H "Authorization: Bearer YOUR_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: 6f1c2f7e-9a4b-4d0e-8f3a-1b2c3d4e5f60" \
  -d '{"email":"buyer@gmail.com","name":"Budi","lang":"en","reference":"ORD-10293"}'
```

Save the returned `id` (e.g. `BP-7K3M9QXA`) with your own order. See [Create order](https://docs.balaipedia.com/api-reference/create-order.md).

**4. Track the status**

Register a [webhook](https://docs.balaipedia.com/webhooks.md) to receive status changes, or poll [Get order status](https://docs.balaipedia.com/api-reference/get-order.md) as a fallback.

```bash theme={null}
curl https://orders.balaipedia.com/v1/orders/BP-7K3M9QXA \
  -H "Authorization: Bearer YOUR_KEY"
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.