Initiate Synapse Payment
Initiate Synapse Payment
InitiateSynapsePayment()
The merchant initiates this call to start the payment flow of the partner.
Request Attributes
| ELEMENT | TYPE | DESCRIPTION |
|---|---|---|
| merchantClientId | string | Merchant's clientId shared by Synapse during the integration process. |
| paymentPayload | string | AES encrypted payload merchant server received in response to Initiate Transaction S2S call. |
Response Attributes
| ELEMENT | TYPE | DESCRIPTION |
|---|---|---|
| success | boolean | true |
Error Code
| ERROR CODE | ERROR MESSAGE |
|---|---|
| 161 | Payment initiation failed |
| 3 | Something Went Wrong |
Sample Request :
var request = {
merchantId: "MOCK-MERCHANT-101",
payload: `AES encrypted payload merchant server received in response to Initiate Transaction S2S call.`
}
Sample Code
const initiatePayment = () => {
sdk
.initiateSynapsePayment(JSON.stringify(request))
.then((val) => validateResponse(val));
})
.catch((error) => console.log(error));
};