Request Method :: POST
Description -
This API is used to map a device to a user through VPA ID, device serial number and device type.
Base URL: To be shared later.
Endpoint URL: /soundbox_trigger

 

Request Body Parameters

Parameters Parameter description (with examples) Data type Mandatory/Optional
customer_name Customer Name.
E.g. - abc
String Mandatory
txn_currency Transaction Currency
E.g. - rupee
String Mandatory
txn_amount Transaction Amount
E.g. - 19
String Mandatory
ref_n Reference Number
E.g. - 12345
String Mandatory
status Status
E.g. - Success
String Mandatory
time_stamp Timestamp String Optional
customer_vpa Customer VPA String Optional
merchant_vpa Merchant VPA.
E.g. - iserveu29
String Mandatory
tr_id TR ID String Optional
merchant_id Merchant ID. String Optional
serial_number Serial Number.
E.g. - 6966333
String Mandatory
checksum Checksum. String Optional
bank_code Bank Code. String Optional
txn-type Transaction Type.
E.g. - UPI
String Mandatory

 

Sample Request Body

Response Body Parameters

Parameters Parameter description(with examples) Data Type
status Status.
E.g. - 0
Integer
message Message.
E.g. - Message successfully sent
String
errors Errors (Only in case of Failed Responses) String
type Error Type
E.g. - field
String
msg Error related Message.
E.g. - merchant_vpa is mandatory
String
path Path
E.g. - merchant_vpa
String
location Location.
E.g. - body
String

 

Sample Response Body(Success)


{
"status": 0,
"message": "Message successfully sent"
}

Sample Response Body(FAILED)


If merchant_vpa is missing :

{
"status": 1,
"message": "merchant_vpa is mandatory",
"errors": [
{
"type": "field",
"msg": "merchant_vpa is mandatory",
"path": "merchant_vpa",
"location": "body"
}
]
}

In case of invalid merchant_vpa or merchant_vpa not mapped with the device :

{
"status": 1,
"message": "ERR001 VPA Not found in database"
}

In case the device is not active :

{
"status": 1,
"message": "ERR002 Device is inactive"
}

Error in the case of publishing a message :

{
"status": 1,
"message": `ERR0004 Error in publish`
}

Error getting YPP external server error :

{
"status": 1,
"message": `ERR0006 Error getting from YPP API`
}

Invalid Device type :

{
"status": 1,
"message": `ERR0007 Invalid device type`
}

Invalid Base Url :

{
"status": 0,
"message": "ERR0008 The url you are trying to reach is not hosted on our server"
}