- Apple Pay Essentials
- Ernest Bruce
- 464字
- 2021-07-16 13:02:49
Enabling Apple Pay in your app
For your app to be able to use Apple Pay, you must have an Apple merchant identifier and merchant certificate. Apple uses the certificate to encrypt payment information in the payment token. Your payment gateway (Stripe, Worldpay, and so on) uses the certificate to decrypt information in the payment token.
Creating your app's Apple Pay merchant identifier
You must have access to your team's Member Center portal and your payment gateway's certificate management facilities.
Create your merchant identifier in your team's Member Center page through the following steps:
- In Member Center, click on Certificates, Identifiers & Profiles.
- Under iOS Apps, click on Identifiers.
- Under Identifiers, click on Merchant IDs.
- Click on Continue (if this is your first merchant identifier) or on the plus sign (+) button in the upper-right corner of the page.
- Enter a description for the merchant identifier in the Description field, for example
MerchantApp merchant identifier
. - Enter the identifier string in the ID field, for example
merchant.com.company.merchantapp
. - Click on Continue and then click on Register.
- Click on Done.
Request an Apple Pay certificate from your payment gateway by performing the following:
- In your payment gateway's certificate management page, create an Apple Pay certificate.
- Download the Certificate Signing Request (CSR) file to your Mac.
Now, follow these steps to create your app merchant certificate in Member Center:
- In the Certificates, Identifiers & Profiles page, under iOS Apps, under Certificates, click on All.
- Then, select Apple Pay Certificate and click on Continue.
- Under Which Merchant ID would you like to use?, select the appropriate merchant identifier and click on Continue.
- Under Generate your certificate, click on Choose File.
- Choose the CSR file you obtained from your payment gateway.
- Next, click on Generate and then click on Download to download your app merchant certificate to your Mac.
Upload your app merchant certificate to your payment gateway via the following steps:
- In your payment gateway's certificate management page, upload the merchant certificate you downloaded from the Member Center portal.
- Confirm that your merchant certificate is listed in your payment gateway account.
Installing your app's Apple Pay merchant certificate on your Mac
Double-click on the merchant certificate you downloaded earlier from Member Center. Keychain Access will then open and install the certificate along with your other certificates.
Enabling Apple Pay in your app's Xcode project
To provide your app with access to Apple Pay, you need to turn on the Apple Pay capability in the Xcode project. Perform the following:
- First, open your project in Xcode.
- Select the target that builds the app to open the target editor.
- Then, click on Capabilities.
- Find the Apple Pay capability and toggle the corresponding switch to its on position.
- In the dialog that appears, select the appropriate development team, and click on Choose.
- Python爬蟲(chóng)開(kāi)發(fā)與項(xiàng)目實(shí)戰(zhàn)
- Building Mobile Applications Using Kendo UI Mobile and ASP.NET Web API
- jQuery從入門到精通 (軟件開(kāi)發(fā)視頻大講堂)
- Java面向?qū)ο蟪绦蜷_(kāi)發(fā)及實(shí)戰(zhàn)
- Nginx實(shí)戰(zhàn):基于Lua語(yǔ)言的配置、開(kāi)發(fā)與架構(gòu)詳解
- Multithreading in C# 5.0 Cookbook
- 劍指大數(shù)據(jù):企業(yè)級(jí)數(shù)據(jù)倉(cāng)庫(kù)項(xiàng)目實(shí)戰(zhàn)(在線教育版)
- Test-Driven Machine Learning
- 從零開(kāi)始學(xué)C#
- 軟件供應(yīng)鏈安全:源代碼缺陷實(shí)例剖析
- Python項(xiàng)目實(shí)戰(zhàn)從入門到精通
- Scratch趣味編程:陪孩子像搭積木一樣學(xué)編程
- 大學(xué)計(jì)算機(jī)基礎(chǔ)實(shí)驗(yàn)指導(dǎo)
- Learning Python Data Visualization
- 深入理解Java虛擬機(jī):JVM高級(jí)特性與最佳實(shí)踐