Skip to main content

3.1 Create PayIn

POST /api/v1/payins

Create one MYR P2P PayIn per request. Send a JSON body and the v1 authentication headers. Sign the timestamp followed by the exact body you send.

Request​

FieldTypeRequiredWhat to send
external_idstringYesYour unique PayIn reference for this shop. Keep it for retries and status lookups.
amountstringYesPositive decimal amount in MYR, for example "125.50".
currencystringYesMYR.
shop_codestringIf using a non-default shopYour assigned MYR shop code. Omit it to use your active default shop.
paymentData.wallet_providerstringYesWallet provider code enabled for the selected MYR P2P shop.
paymentData.bank_codestringYesBank code enabled for the selected shop. Preserve the supplied spelling.
merchant_user_id, merchant_user_ipstringsOptionalYour customer reference and the customer's IP address, when available.
callback_urlURLOptionalPublic HTTPS endpoint for PayIn webhooks.

Send both codes as members of the paymentData object. Replace your_myr_shop, WALLET_CODE and BANK_CODE in the example with values from your integration contact.

{
"external_id": "PIN-MYR-001",
"amount": "125.50",
"currency": "MYR",
"shop_code": "your_myr_shop",
"merchant_user_id": "customer-42",
"merchant_user_ip": "203.0.113.10",
"callback_url": "https://merchant.example.com/webhooks/payin",
"paymentData": {
"wallet_provider": "WALLET_CODE",
"bank_code": "BANK_CODE"
}
}

Response​

A newly created operation returns 201. These are the fields used to identify it and track its status.

{
"id": 12345,
"external_id": "PIN-MYR-001",
"shop_code": "your_myr_shop",
"status": "pending",
"amount": "125.50",
"currency": "MYR",
"transaction_type": "payin"
}

For H2H, the response can also include paymentData with payment instructions available for that operation. Confirm the instruction fields supplied for your shop before building the payer interface. The request fields do not specify a fixed set of response fields. Use the PayIn status endpoint to confirm the outcome.

Retry an uncertain create with the original external_id, shop and request data. An equivalent repeat can return 200 with the existing operation. Reusing the identifier with different payment details can return 409.

A missing wallet_provider or bank_code returns 422 with code: "validation_error" and message: "Invalid paymentData". Inspect errors for the missing field. See API errors.