A stable version will be available this fall.
The first thing you want to do is make sure the API is available in your browser:
if(ApplePaySession) ApplePaySession.canMakePayments()
Then the transaction itself:
var request = { countryCode: 'US', currencyCode: 'USD', supportedNetworks: ['visa', 'masterCard'], merchantCapabilities: ['supports3DS'], total: { label: 'Your Label', amount: '10.00' }, } var session = new ApplePaySession(1, request);
From the official website, how to get started: https://developer.apple.com/reference/applepayjs/applepaysession
After the session, you can manage it: 
And you can listen to events and change your stream based on this: 
I'm currently working on integration between Apple Pay JS and the Stripe API, so I will release a draft on GitHub this summer.
www.eugenehp.tk
source share