The frontend integration for Broadleaf Store Credit is quite simple, relative to other payment integrations.
The out-of-box Store Credit APIs currently only support Broadleaf customer-owned accounts. Therefore, if the customer is logged in, then call the Customer Store Credit API to determine if the customer has a store credit account. If they do, then present it as an available payment method in the checkout flow.
Note
|
This endpoint will also provide the account’s balance. When defining the payment amount, it must be less than or equal to this balance. |
From there, follow this guide to understand how to build a PaymentTransactionServices Payment object based on the store credit account.