Domain Setup
Register your domains and host the Apple Pay domain association file
Before the embedded checkout can load in your application, complete both steps on this page. They're required for every embedded checkout integration.
Required for every integration
Complete both steps before you go live, including hosting the domain association file, even if you don't plan to offer Apple Pay from the start. Organisations connected to your integration may already have Apple Pay enabled. Apple Pay only appears on domains that already host the association file.
Register your domains
The checkout only renders on domains registered with Esenda. On any other domain, the browser blocks the iframe and the payer sees an empty or error frame.
You'll be asked for your domains during onboarding, so have the full list ready before you start. Include:
- every environment you use (for example production, staging and local development)
- each subdomain separately, such as
app.example.comandcheckout.example.com - the full origin, including the protocol (
https://)
https://app.example.com
https://staging.example.com
https://checkout.example.comHost the domain association file
Apple Pay only appears in the checkout if each domain hosting the iframe can prove it's registered for Apple Pay. You do this by serving Esenda's domain association file from every domain you registered above.
Download the domain association file
Host the file exactly as downloaded, without a file extension and without changing its contents, at this path on each domain:
https://YOUR_DOMAIN/.well-known/apple-developer-merchantid-domain-associationCheck that:
- the file is reachable over HTTPS with a
200response - the URL doesn't redirect
- the file is publicly accessible, with no login, IP restriction or bot protection in front of it
If the file is missing or unreachable, Apple Pay may not appear in the checkout. If it does appear, the payment will fail at the final step, because Apple can’t verify your domain.
When you submit an organisation application, esenda checks the file on each embedded payment domain and reports the result in apple_pay_verification_status.
Next steps
- Authenticate and create a Checkout Session Request.
- Embed the checkout with Iframe Setup.