💳Payment on the Merchant's website
After completing an order and selecting the "Pay with DCM platform" option, the Merchant sends a JWT request using the POST method. To enable this scenario, integration with the "Emitters" method must be configured beforehand.
Endpoint
{{url_host}}//api/v1/merchants/order?jwt={{JWT}}&custom=true
Process Description:
For Desktop Users: Merchant must display key elements of the payment page, including: DCM platform QR code and logos of participating banks.
For Mobile Users: The Merchant must generate clickable bank logos embedded with deep links. These deep links should include the JWT received in the response to the order creation request.
Payload запиту
{
"sub": "623e460b-9ffd-41df", - Merchant identifier (uid)
"exp": 1719493881, - Order expiration time
"iat": 1707105971, - Order creation time
"amt": 1000, - Order amount
"cur": "UAH", - Order currency
"ref": "d4ee06f", - Order number in the Merchant's accounting system
"prp": "Payment for goods/services", - Payment purpose
"url": "https://www.city24.com", - Redirect URL for returning the buyer to the Merchant's website
"fri": { - Information about the ultimate beneficiary of the funds (optional)
"frn": "Kyivpark LLC", - Name
"frc": "0987654321", - Tax number
"fra": "UA55386780956567", - Account number (IBAN)
"frb": "300335", - Servicing bank's code
"frm": "7791" - Merchant category code
}
The "sub" field is provided by the Bank after the Merchant is registered with DCM platform
The "exp" and "iat" fields use the Unix Timestamp format. Can be used for convenience - https://www.unixtimestamp.com/
The "ref" field must contain a unique value.
The order is signed using the Merchant’s private key.
Response (example)
{
"id":"3aa202bc-6b20-445d-89698274b11c66d0",
"jwt": ""eyJhbGciOiJSUzI1NiIsImtpZCI6Ijl........_5qgFg",
"link_deeplinks":"https://api.admin.smaug.armenotech.dev/api/v1/merchants/order?id=3aa202bc-6b20-445d-8969-8274b11c66d0&mobile=1",
"link_qr":"https://api.admin.smaug.armenotech.dev/api/v1/merchants/order?id=3aa202bc-6b20-445d-8969-8274b11c66d0&mobile=0"
"qr_code_data": "/9j/2wCEAAgGBgc......IBAwM"
}
In case of order expiration, an Expiration callback in an open format is sent to the Merchant's address.
Example expiration callback:
{
"amount":21,
"amount_matched":"null",
"callback_guid":"null",
"code":4001,
"currency":"UAH",
"order_id":"7af01d72-b46b-4e2c-b6db-02eb64541f62",
"payment_message_external_id":"null",
"payment_message_guid":"00000000-0000-0000-0000-000000000000",
"purpose":"null",
"reason":"Order is expired",
"receiver_account_iban":"null",
"ref_found":"null",
"ref_number":"q81277312392323",
"sender_account_iban":"null",
"status":"reject"
}