You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is not my understanding from what I read in the docs:
The topic of the remote notification, which is typically the bundle ID for your app. The certificate you create in Member Center must include the capability for this topic.
If your certificate includes multiple topics, you must specify a value for this header.
If you omit this header and your APNs certificate does not specify multiple topics, the APNs server uses the certificate’s Subject as the default topic.
So, the topic is only needed if the certificate includes multiple topics.
That being said, how do you suggest that you pass in a default topic for notifications?
You are correct. In my case, Certificate had more than one topic.
If we can either set config for Apnotic for default topic using mattr_accessor and then use it when building headers for request or we can fetch topic for certificate like the following implementation.(1st one will be easier to implement) https://github.com/alloy/lowdown/blob/master/lib/lowdown/certificate.rb
I think it makes sense to add an optional topic to Connection while keeping the per-notification override in place.
That should make it a bit more usable for people who only need to send pushes to one topic but need to specify it because the cert contains more than one.
Push notification api requires topic to be passed with the request. Can we pass default topic for notifications?
The text was updated successfully, but these errors were encountered: