Friday, December 26, 2014

Apple Pay - Setup Process Involved.

Did a hands on setting up the App ID for enabling the Apple Pay. Below are few notes on this

- App Vendor need to enable Apple Pay in the bundle ID of the App.
- In order to enable Apple Pay, need to create a Merchant ID in the iTunes account of the App in which it belongs
- Merchant ID is created by a series of steps such as creating a bundle ID, CSR and associating CSR with the created Merchant ID etc
- Once this is done, Application need to enable the Apple Pay in App Capabilities, which will trigger Xcode to validate if Apple Pay is enabled for this bundle ID by checking with the Apple Developer account. 
- Once this is done, Application can include PassKit framework and few code snippets, the Apple Pay feature can be enabled. 
- Apps can check fi the device is able to support Apple Pay and only if yes, can enable the Apple Pay button in the app ui. 
- App can pass the info ( in form of standard and custom fields) to the backend server, the server should be able to handle this token  and extract the info. For the decryption service, the server code can employ third party SDKs and it is normal as per the documentation and samples available. 

Simple code snippets to Demonstrate this concept is getting added in next article.

- When tried with iPhone 6 Plus, was not fully able to test this out because the card validation was failing when adding the card in Passbook app. 

Few other notes:

- Apple pay is not possible within the enterprise app account. (Merchant ID section is not listed for enterprise accounts under Identifiers in Developer account), so we have created the sample using the developer account. 
- Felt like the concept is much similar to Apple Push notification, with a difference that, Apple Push notifications flow from server by encrypting the data with the certificate on the client and the certificate on the server. With Apple pay, the data is encrypted from client (in form of token) and decrypted at the server. 


References:

No comments:

Post a Comment