Interface GiftCardComponentCallback
-
- All Implemented Interfaces:
-
com.adyen.checkout.components.core.ComponentCallback,com.adyen.checkout.components.core.internal.BaseComponentCallback
public interface GiftCardComponentCallback implements ComponentCallback<GiftCardComponentState>
Implement this callback to interact with a GiftCardComponent.
-
-
Method Summary
Modifier and Type Method Description abstract UnitonRequestOrder()In this method you should make a network call to the /orders endpoint of the Checkout API through your server. abstract UnitonBalanceCheck(PaymentComponentState<?>Â paymentComponentState)In this method you should make a network call to the /paymentMethods/balance endpoint of the Checkout API through your server. -
-
Method Detail
-
onRequestOrder
abstract Unit onRequestOrder()
In this method you should make a network call to the /orders endpoint of the Checkout API through your server. This method is called when the user is trying to pay a part of the amount using a partial payment method.
You should eventually call GiftCardComponent.resolveOrderResponse with a com.adyen.checkout.components.core.OrderResponse that you will receive in the response of the API call.
See https://docs.adyen.com/api-explorer/ for more information on the API documentation.
-
onBalanceCheck
abstract Unit onBalanceCheck(PaymentComponentState<?>Â paymentComponentState)
In this method you should make a network call to the /paymentMethods/balance endpoint of the Checkout API through your server. This method is called right after the user enters their partial payment method details and submits them.
We provide a PaymentComponentState which has a PaymentComponentData object containing a non-serialized version of the partial payment method JSON. Use PaymentMethodDetails.SERIALIZER to serialize it to a JSONObject.
You should eventually call GiftCardComponent.resolveBalanceResult with a com.adyen.checkout.components.core.BalanceResult that you will receive in the response of the API call.
See https://docs.adyen.com/api-explorer/ for more information on the API documentation.
- Parameters:
paymentComponentState- The state from the partial payment method component.
-
-
-
-