| Options | Description | Typical Use Case |
|---|---|---|
| Charge only | Create and collect payment directly, no order required. | One‑off payments, server‑side billing, fastest integration. |
| Order + Charge | Create an order first, then one or more charges under it. | Checkouts needing retries, shared expiry, consolidated reporting. |
Option 1: Charge‑only
Create a Charge directly (noorder_id). A charge is a single attempt to collect funds via a specific method (e.g., bank transfer, QRIS, e‑wallet, card).
Body Parameters
Body Parameters
| Field | Type | Required | Description |
|---|---|---|---|
amount | integer | ✅ | The total amount for which the payment was created. Example: “10000” or “10000.23” for amount with decimal value |
currency | string | ✅ | Currency of payment |
channel_code | string | ✅ | Channel code used to select the payment method provider. Use routing payment channels mapping for full list of channel codes. |
channel_properties | object | conditional | Parameters that contain information required by the payment route provider to initiate payment processing. |
reference_id | string | optional | Merchant’s payment reference ID |
order_id | string | optional | Order ID associated with this charge |
metadata | object | optional | Arbitrary key‑value |
description | string | optional | A custom description for the charge. |
Request Example : Charge‑only (QRIS)
Request Example : Charge‑only (QRIS)
Response Example
Response Example
Charge Lifecycle & Actions
Charge Lifecycle & Actions
- Statuses:
pending,succeeded,failed,expired,canceled - Actions enum
REDIRECT_CUSTOMER→ send customer to provider / 3DS pagePRESENT_TO_CUSTOMER→ display QR / VA / instructionsNONE→ no action needed
Rules
• A charge has its own expiry (actions.expires_atwhere applicable).
• Avoid multiple concurrent charges for the same intent.
• Use idempotency and webhooks to finalize outcome.
Option 2: Order + Charge
An Order represents payment intent and provides a shared lifecycle over multiple attempts (charges). Use when you need retries, consolidated reporting, and global expiry across attempts.Body Parameters
Body Parameters
| Field | Type | Required | Description |
|---|---|---|---|
amount | integer | ✅ | Minor units |
currency | string | ✅ | ISO 4217 |
customer_id | string | optional | Link to an existing customer |
allowed_channels | object | optional | e.g. “qris”, “dana” |
reference_id | string | optional | Merchant’s payment reference ID |
expires_at | string | optional | ISO 8601 timestamp |
description | string | optional | Human‑readable summary |
metadata | object | optional | Arbitrary key‑value |
items | object | optional | Order items |
Request Example : Create Order
Request Example : Create Order
Response Example
Response Example
Order rules
• Amount / currency fixed at order creation.
• Charge expiry cannot exceed order expiry.
• Only one successful charge per order.
• On first success → order becomessucceeded.
Webhooks
Charge‑only Events
Charge‑only Events
| Event | Description |
|---|---|
charge.pending | Charge initiated, awaiting completion |
charge.succeeded | Funds confirmed captured |
charge.failed | Provider decline or timeout |
charge.expired | Charge window elapsed |
charge.canceled | Manually canceled by merchant |
Example : charge.succeeded
Example : charge.succeeded
Order + Charge Events
Order + Charge Events
| Event | Description |
|---|---|
order.created | New order created |
order.succeeded | First charge succeeded; order closed |
order.canceled | Order canceled by merchant |
order.expired | Order reached expiry time |
charge.pending | Charge initiated under order |
charge.succeeded | Charge under order succeeded |
charge.failed | Charge under order failed |
Example : order.succeeded
Example : order.succeeded
Objects & Schemas
Charge Object
Charge Object
| Field | Type | Description |
|---|---|---|
id | string | Charge identifier |
amount | integer | Minor units |
currency | string | ISO 4217 |
status | string | pending | succeeded | failed | expired | canceled |
channel_code | string | Please refer to collection type table (e.g.qris | dana | bca_va | card) |
channel_properties | object | Channel-code specific params (if provided) |
reference_id | string | Merchant‑side reference/trace ID |
actions | object | See Actions enum |
order_id | string | Present when charge is under an order |
customer_id | string | Optional customer linkage |
created_at | string | ISO 8601 |
captured_at | string | ISO 8601 (when succeeded) |
expires_at | string | ISO 8601 (charge window, if any) |
metadata | object | Arbitrary key‑value |
Order Object
Order Object
| Field | Type | Description |
|---|---|---|
id | string | Order identifier |
object | string | Always "order" |
amount | integer | Minor units |
currency | string | ISO 4217 |
status | string | pending | succeeded | canceled | expired |
expires_at | string | Global expiry across attempts |
created_at | string | ISO 8601 |
customer_id | string | Optional linkage |
metadata | object | Arbitrary key‑value |