Skip to main content

Text to Pay-Over-Time

Overview#

You can use Sunbit's webhooks to do anything from getting notified when a customer makes a payment, to incorporating customer actions into your reporting, customer outreach, and/or marketing automation workflows. The following customer events are currently available:

Text to Pay-Over-Time: Completed, aborted, failed

Important

This is a new version of the Sunbit Text to Pay-Over-Time API and the following update is available: "advisorEmail" attribute in the request body has been replaced with "representativeEmail" in order to be consistent across all APIs and SDKs. Please upgrade to the latest version by 12/31/2022.

Body#

{  "eventType": "TEXT_TO_PAY_COMPLETED",  "payload": {    "purchaseId": "99-999-999",    "location": "retailer4",    "purchaseAmount": 120.0,    "purchaseDate": "2021-11-04 01:01:02",    "invoice": null,    "associateName": "Jason",    "representativeName": "Jason",    "representativeEmail": "jason@email.com",    "referral": "9999",    "merchantFeeAmount": 5  }}

Definitions#

AttributeTypeDescription
eventTypetextThe type of event triggered by the customer action:
TEXT_TO_PAY_ABORTED
TEXT_TO_PAY_COMPLETED
TEXT_TO_PAY_FAILED
purchaseIdtextThe purchase Id that is generated by Sunbit and returned after a successful Sunbit flow. This purchase ID should be used for transaction management -Lookup, Void and refund (add URL for each).
locationtextThe same Location which was sent in the API.
purchaseAmountnumberThe max amount the customer was approved for.
purchaseDatetextThe date of the purchase. Format: YYYY-MM-DD HH:MM:SS.
invoicetextA number which is manually inputted in the Sunbit POS .
associateNametextThe name of the representative that provided by the integrator. Equal to the associateName which was provided in text-to-pay-over-time request. //Will be deprecated on 31/12/2022
representativeNametextThe name of the representative that provided by the integrator. Equal to the representativeName which was provided in text-to-pay-over-time request.
representativeEmailtextThe email of the representative that provided by the integrator. Equal to the representativeName which was provided in text-to-pay-over-time request.
referraltextAn external transaction identifier sent by the integrator for Text to Pay-Over-Time and used to match the webhook to the request.
merchantFeeAmountnumberThe amount that was deducted as merchant fees from the total purchase amount.