Migration to SensePass Elements
When using the SDK with SensePass Elements, onboarding with Apple Pay enables paying without a intermediate pop-up.
Installing a fresh SDK
Follow the documentation for installing SensePass element SDK:
Upgrading from SDK Version 1.0.9/1.1.0 (or below)
Update the SensePass SDK
javascript
link to version 1.1.1 (or above). For example: if your’e usinghttps://js.sensepass.com/scripts/[email protected]
-> you should update it tohttps://js.sensepass.com/scripts/[email protected]
.Update your configuration
object
with akey
stringpayButtonId
and avalue
string of your choosing, for example:const paymentElementId = "my-payment-button"; const spSdkConfig = { mode: "sandbox", // "sandbox" | "production" debug: true, // optional for logs visualizer: true, // optional visual logs, requires HTML with id="sensepass-front-end-visualizer" clientId: "aee8d2cdc1cb...", // Client ID methodType: "manual_capture", // type for the transaction, defaults to "manual_capture", enum: "manual_capture" | "tokenize" | "authorize" payButtonId: paymentElementId // id for the payment-button (element) the customer will click to start the payment process };
Update your
HTML
element that invokes thepay
method from the SDK with anid
attribute andvalue
from step #2, e.g.id="my-payment-button"
.
Onboarding your domain for Apple Pay
Send SensePass the domain(s) you’ll use Apple Pay on. For example: - www.my-store.com - my-subdomain.my-store.com - my-other-store.com
Open public access from your website(s) to a file from the base path of your url. For example: - https://www.my-store.com/.well-known/apple-developer-merchantid-domain-association.txt. * This will let Apple validate your domain is associated with SensePass’s Apple account.
Receive from SensePass the
apple-developer-merchantid-domain-association.txt
file(s) and store them in your website(s). * SensePass will send you the file(s) in a.zip
named to match it’s domain. Make sure to store the .zip content in its correct website.Inform SensePass all
apple-developer-merchantid-domain-association.txt
file(s) are stored and publicly accessible.Receive confirmation from SensePass that your domain(s) are Apple Pay ready.
Its very important to store the files & inform SensePass ASAP because the file(s) can expire.
Last updated
Was this helpful?