Please enter the password to view.
Checkout SDK
Overview
You can use Sunbit’s webhooks to do anything from getting notified when a patient makes a payment, to incorporating patient actions into your reporting, customer outreach, and/or marketing automation workflows. The following patient events are currently available: Completed, Aborted, Failed
Completed status is when the patient completes the checkout process and payment was successful. Aborted status means the patient ended the checkout flow and aborted the session. Failed status translates to the patient was declined and the payment was unsuccessful.
Body
{
“eventType”: “CHECKOUT_SDK_COMPLETED”,
“payload”: {
“purchaseId”: “99-999-999”,
“location”: “los-angeles-medical-office”,
“purchaseAmount”: 590.99,
“purchaseDate”: “2024-03-13 01:02:02”,
“invoice”: null,
“representativeName”: “Waylon”,
“representativeEmail”: “[email protected]”,
“referral”: “9999”,
“merchantFeeAmount”: 5
}
}
Definitions
Attribute | Type | Description |
---|---|---|
eventType | text | The type of event triggered by the customer action: CHECKOUT_SDK_ABORTED CHECKOUT_SDK_COMPLETED CHECKOUT_SDK_FAILED |
purchaseId | text | The 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. |
location | text | The same Location which was sent in the API. |
purchaseAmount | number | The max amount the customer was approved for. |
purchaseDate | text | The date of the purchase. Format: YYYY-MM-DD HH:MM:SS |
invoice | text | A number which is manually inputted in the Sunbit POS. |
representativeName | text | The name of the representative that provided by the integrator. |
representativeEmail | text | The email of the representative that provided by the integrator. |
referral | text | An external transaction identifier sent by the integrator and used to match the webhook to the request. |
merchantFeeAmount | number | The amount that was deducted as merchant fees from the total purchase amount. |