Mohamed yaseen
Mohamed yaseen

Reputation: 65

Do I need APNS certificate as well as VOIP certificate?

Our application is already registered for APNS. Since we are going to implement PushKit, we have created VOIP certificate too. Is it really necessary? Can't we just use the APNS certificate for VOIP push?

Since there are two certificates now, I have to maintain two tokens. One is used to send normal push, and the other one to send VOIP push.

Can't we simply use one token/certificate for both purposes?

Upvotes: 4

Views: 5568

Answers (4)

Rubycon
Rubycon

Reputation: 18346

Actually it's possible to use single certificate for both standard and VoIP pushes

Apple docs and portal is not so obvious and personally I spent lots of time to understand it

But what I can say for 100% sure is the following:

Actually you can create 3 types of certificates:

  • Universal (for Production/Sandbox standard pushes + VoIP)
  • Sandbox-only for standard pushes
  • VoIP-only (for both Prod+Sandbox)

As you can see, you can create a single Universal certificate for everything and just simplify your life - just forget about separate Universal and VoIP certs.

Here is a cool guide I used to generate single Universal certificate which works everywhere https://developers.connectycube.com/ios/how-to-create-apns-certificate

Highly recommended. Personally I do not create separate Sandbox-only and VoIP certs anymore.

Upvotes: 2

Ray
Ray

Reputation: 284

Actually you can use one universal certificate for your voip push and normal push. When you send a normal push, use normal topic and normal token, which is generally your bundle identifier

com.company.appname

When you send a voip push, use voip topic and your pushkit token, which is

com.company.appname.voip

See links in Apple

Upvotes: 12

Hasya
Hasya

Reputation: 9898

Yes, you have to keep / maintain both certificates and both tokens, as APNS and VOIP certificates are totally different in purpose.

Pushkit payload with 'content-available'=> 1 will be silent notification and would not come in notification bar.

Reason is to keep both differently is "Some user may not want to register for VOIP feature" for particular app.

Check something needful here.

Upvotes: 0

Krishna Datt Shukla
Krishna Datt Shukla

Reputation: 997

No, you can't use same certificate and device token for both simple push and VOIP Push. You must need to create separate certificates for both. Because both generates different device token which can't be used for one another.

Upvotes: 0

Related Questions