Embedded Payments Session Integration
Step 1 (backend)
Sample request
{
"merchantId": "1cc7b594-b80f-4227-a0fa-299c4c6ce8ab",
"data": {
"type":"payment_session",
"amount": 12.50,
"currencyCode": "USD",
"paymentMethods": ["CC_DC","ACH"],
"oneTimeOnly":true,
"salesTax": 2.50,
"orderNumber": "A350",
"startDate": "20220510",
"endDate": "20221115",
"description": "A coffee cup in the morning",
"saveCardConsent": true,
"internalTransactionID": "ID1",
"customer":{
"first_name":"John",
"last_name":"Doe",
"business_name":"",
"address":{
"street":"100 Main Street",
"unit":"80",
"city":"Austin",
"state":"Texas",
"country":"us",
"postal_code":"76707",
},
"email":"[email protected]",
"phone":{
"country_code":"1",
"subscriber":"8042773232"
}
},
"success_text":"Thank you! Your payment has been successfully processed`",
"failure_text":"Payment failed. Please try again",
"metadata": {
"customerId": "123",
"email" : "[email protected]"
}
}
}Sample response
Step 2 (client side)
2a. Display the payment session web component, use a custom callback handler to receive the transaction response on the client side.
2b. Display the payment session using client side JS
Step 3 (webhook event)
Sample webhook
Step 4 (transaction details)
Sample response
Last updated