Post

Replies

Boosts

Views

Activity

Reply to How to check if Payment Pass already exists in Wallet
From what I understand the passes method returns the list of passes that have already been added to the wallet of the device. Similarly, the remoteSecureElementPasses method returns the list of passes that have already been added to a paired Apple Watch. Given a pass identifier I want to show the "Add to Apple Wallet" button if either of the following is true: The pass is not present in the current device's passes (passes). There is a paired Apple Watch AND the pass is not present in the Apple Watch passes (remoteSecureElementPasses). The problem arises on point 2. Since remoteSecureElementPasses returns an empty list if the pass has not been added to the Apple Watch yet OR if there is no paired Apple Watch, I can't decide wether to show the button or not: If pass has not been added, I should show the button If there is not paired Apple Watch, I should hide the button How can I tell these two cases apart?
Dec ’21