createOrder Method
Overview
The createOrder method initializes a payment order at the processor.
Request Fields
| Field | Type | Required | Description |
|---|---|---|---|
merchantOrderId | string | Yes | Your order reference |
amount | Money | Yes | Expected amount |
webhookUrl | string | No | Notification URL |
Response Fields
| Field | Type | Description |
|---|---|---|
connectorOrderId | string | Connector's order ID |
status | PaymentStatus | STARTED |
sessionToken | array | Wallet session data |
Example
$request = [
'merchantOrderId' => 'order_001',
'amount' => ['minorAmount' => 1000, 'currency' => 'USD'],
'webhookUrl' => 'https://your-app.com/webhooks'
];
$response = $paymentClient->createOrder($request);