This operation is to create transaction and generate QR code.
Request
AccessToken will be share separately
Body Params application/json
Reference number from merchant system
Currency code ISO 4217(USD, KHR...)
Serial number of QR code display device or terminal
(You need to map the device code in your system)
Payment channel code
(You can get channel code from GetBillerProfile function)
purpose_of_transaction
string
requiredBill issue date or bill number
Phone number of the customer
Email address of the customer
The URL that will redirect to when customer cancel the payment
The URL that will redirect to after payment completed
The language displayed on the checkout page, default is km
km : Khmer
en : English
{
"identity_code": "174952172035635",
"currency": "KHR",
"amount": 105800.00,
"device_code": "T1",
"channel_code": "1",
"purpose_of_transaction": "INV23001",
"customer_code": "12340001",
"customer_name": "Chea Samnang",
"customer_phone": "010888999",
"customer_email": "example@gmail.com",
"description": "",
"cancel_url": "https://example.com/checkout/cancel",
"redirect_url": "https://checkoutapidemo-demo.bill24.net/checkout/redirect",
"language": "km"
}
Request samples
curl --location --request POST 'https://merchantapi-demo.bill24.io/transaction/v2/init' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'token: {AccessToken}' \
--header 'Content-Type: application/json' \
--data-raw '{
"identity_code": "174952172035635",
"currency": "KHR",
"amount": 105800.00,
"device_code": "T1",
"channel_code": "1",
"purpose_of_transaction": "INV23001",
"customer_code": "12340001",
"customer_name": "Chea Samnang",
"customer_phone": "010888999",
"customer_email": "example@gmail.com",
"description": "",
"cancel_url": "https://example.com/checkout/cancel",
"redirect_url": "https://checkoutapidemo-demo.bill24.net/checkout/redirect",
"language": "km"
}'
Responses
application/json Response message in Khmer
Reference number from merchant system
Bill24 hosted checkout page
Raw KHQR data, biller need to convert to image
{
"code": "SUCCESS",
"message": "Transaction initiation success.",
"message_kh": ប្រតិបត្តិការបង្កើតជោគជ័យ",
"data": {
"identity_code": "174952172035635",
"payment_link": "https:/bill24.io/pay/Bill24_EYhKXzwC0",
"khqr_string": "00020101021229450014wing_khqr@wing011009666645540209WingBank52045999530384054041.005802KH5915Kranh Virackbot6010PhnomPenh9917001316847322197766304E117"
}
}
Modified at 2025-03-06 10:42:15