Hey, I've experienced the same exact issue while implementing this.
I was able to resolve it by setting some properties (cardholderName and/or primaryAccountSuffix) to the configuration before passing it to the PKAddPaymentPassViewController initializer.
This the code for presenting this controller, which I execute when the user taps on the "Add to Wallet" button:
guard let configuration = PKAddPaymentPassRequestConfiguration(encryptionScheme: .ECC_V2) else {
print("Configuration was not initialized! ⚠️")
return
}
configuration.cardholderName = "FirstName LastName"
configuration.primaryAccountSuffix = "0000" // last 4 digits
configuration.localizedDescription = "MasterCard Credit" // card description name
guard let walletController = PKAddPaymentPassViewController(requestConfiguration: configuration, delegate: self) else {
print("Wallet View Controller was not initialized! ⚠️")
return
}
self.present(walletController, animated: true)