Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Apple Wallet Passes for different PassTypeID - i dont understand how to push #71

Open
haladynkamil opened this issue Sep 4, 2024 · 2 comments

Comments

@haladynkamil
Copy link

Hello, i have a webapp that is able to create apple wallet passes for iOS.
Process more or less looks like this:
User provides his Apple Pass ID and certificate from apple developer, based on that cert i am creating wallet passes that i can send to devices, then devices register to my webServiceURL.

Now i have tested this app while creating the passes from my Apple Pass ID and while using my APNs key from the same developer account and everything works great. What im looking for now is how to send push notifications to devices that have passes with different Apple Pass ID (so from user apple pass ID) with my APNs key.

Apps like PassKit etc. can send those notifications while not requesting user to provide his APNs key, maybe there is something i fundamentally dont understand about this process.

@haladynkamil
Copy link
Author

I just fixed it, for people struggling with the same approach here is the solution:

What Apple requires in terms of passes is to validate yourself using certificate method, for APNs() client you should only use client_cert and use_sandbox=False, where for client_cert it should be a .pem file of COMBINED private key (used to generate CSR for apple) and PassTypeID certificate in ONE file. Do not put team_id or topic, it doesnt matter (they are in the cert anyway) and the push will work.

@Fatal1ty
Copy link
Owner

Fatal1ty commented Sep 5, 2024

@haladynkamil I’m glad you solved the problem. Would you mind opening a PR with this useful information in the README?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants