Skip to main content

Method pay

URL: POST - /partner/merchant/confirm/pay

The method allows you to send a request to pay for the merchant's services via the client's bank card. Upon successful processing of the request, the system returns a unique identifier of a one-time verification code. A one-time verification code will be sent to the client in the form of an SMS message. To confirm the payment, the partner must send the received ID and verification code using the merchant/confirm/pay/verify method.

Header parameters

ParameterTypeDescription
client-id *authorizationUnique Partner ID
client-secret *authorizationUnique authentication key for VIA API

Request parameters

ParameterTypeDescription
merchantId *stringVIA Merchant ID
card *objectBank Card Data object
card.pan *stringClient's bank card number
card.expiry *stringValidity period of the client's bank card
externalId *stringUnique Partner Request ID
amount *integerThe amount of payment in cents (1/100 part of the base currency unit)
currency *stringCurrency:
«UZS» - Uzbek sum
notestringNotes, remarks, etc.
accounts *stringData object regarding merchant services.
The parameters and their values of the accounts object are determined depending on the merchant's service for which the payment is made.
For example:
A phone number is sent to pay for the mobile operator's service.

Request sample

curl POST '/partner/merchant/confirm/pay' \
--header 'client-id: system' \
--header 'client-secret: system123' \
--data '{
"merchantId": "mrt_qwegFC1lHGaAzJIRphv4LdU10zX",
"card": {
"pan": "8600490100151968",
"expiry": "1023"
},
"externalId": "test_1"
"amount": 10000,
"currency": "UZS",
"note": "",
"accounts": {
"account": "123123"
},
}'

Response parameters

ParameterTypeDescription
verifyIdstringID of the verification code

Example response if successful

{
"verifyId": "trx_2VQGS1Eeu4DNsfuKxbFO1vftNy4"
}

Example response in case of error

{
"status": {
"code": "1234",
"message": "Error while executing the request"
},
"error": {
"path": "URL Path",
"message": {
"uz": "Error message in Uzbek",
"ru": "Error message in Russian",
"en": "Error message in English"
}
}
}