WePay’s embedded checkout relies on the client’s browser accepting WePay cookies in order to successfully display the iframe.
Some browsers do not support third-party cookies. A prime example is Safari, which blocks third-party cookies by default. Rather than generating a support ticket and putting the onus on the payer to change this setting or use a different browser, you can implement the
Here’s how to implement:
- For each embedded checkout page, generate another URI which will host the same
checkout_urireturned in the /checkout/create response.
- These URIs should be predictable, so that you can include it in the /checkout/create request on the
That’s it! Once implemented, the iframe will force a redirect to wepay.com and then to the fallback URI that you’ve set when a third-party cookie error occurs. When your fallback URI is loaded, the browser will already have WePay cookies and the iframe will load successfully without third-party cookie errors.
- Create embedded checkout and serve to the payer.
- Payer’s browser returns a thrid-party cookies error.
- Fallback URI protocol:
- Redirect to wepay.com.
- Redirect to supplied
- Re-load the iframe without third-party cookies error.
- Payer successfully completes payment.