Checkout
Show the Checkout Frame
To show the checkout frame, call:
gle("Checkout", "CART_TOKEN","HTML CONTAINER ID");
In-Cart Express Payment Methods Integration with Global‑e
Global‑e offers a streamlined implementation of in-cart express payment methods for shoppers.
With this option, shoppers can access express payment methods directly from the Cart page, making the checkout process faster and more efficient.
Currently, Global‑e supports the following in-cart express payment methods:
AmazonPay
PayPal Express
Supported In-Cart Express Payment Methods
The following table lists the in-cart express payment methods currently supported by Global‑e and their corresponding Global‑e functions.
Payment Method | Function | Error Object |
---|---|---|
|
| None |
|
| Error Types: 1 - Cart validation 2 - Issue with the PayPal response |
Note that you can find these functions in the Global‑e object.
For example:
GlobalE.CheckoutWithAmazonPayV2('40a51c57-cdac-40d2-b8dc-ad94d9fd6c1f', alert('Error'))
Function Parameters
When implementing in-cart express payment methods, use the following parameters:
| A valid Global‑e Cart Token that can be retrieved from |
| A function invoked in case of a failure, such as an invalid Cart Token. You can use this function to redirect the shopper to the regular checkout, show an error message, and more. |
Implementation Steps
To implement in-cart express payment methods:
Generate a Global‑e Cart Token or use an existing one, if it is still valid.
Call the appropriate function based on the payment method selected by the shopper; for example,
CheckoutWithAmazonPayV2
for AmazonPay orCheckoutWithPayPalExpress
for PayPal.
The shopper is redirected to the payment method page (Amazon or PayPal).