APNS Development x Production Certificates

I am confused on how OneSignal deals with the Dev & Production certificates.

On the OneSignal Apple Certificate upload window you see a message:

(Certificate Environment will be automatically detected)

So I understand that I can upload both certificates (Dev & Production) that OneSignal will use the correct one, right?

But I am not seeing that happening here.

I created a brand new app on OneSignal and upload the Dev Certificates. Push worked fine.

Then I uploaded the Production certificate and the Push stopped working (App built under a Dev Provisioning Profile).

When I go to the AppSettings page, I see:

iOS (APNS) (Production Certificate) Bundle ID: com.my.app Warning! Mismatched push certificate error, check that your app's provisioning profile (type and bundle id) match that of your push certificate. PlayerID: b1708fea-4d2f-11e5-9ce7-affc72c972d5

Well, of course the Provisioning Profile does not match, I am using a Dev one and it appears that OneSignal is trying to use the Production certificate. So, where is the automatically certificate handling by OneSignal?

What am I missing?

Hello,

You can only upload one certificate at a time. We detected the certificate type (Production or Development) so you don’t have select which one it is. We need to know the type so we connect the correct Apple server.

You can upload a Production push certificate to our site always use an Ad-Hoc provisioning profile when building your app in your testing. Or create another development version of your app.

Thanks.

Ah I see…

IMHO, the message ( “(Certificate Environment will be automatically detected)”) is then confusing. Now that you explained, made sense, but I would rephrase it in order to avoid that misunderstanding (if you get more feedback about that, of course).

Thanks for the reply jkasten.

Another suggestion:

I am thinking here, you only need the certificate when actually sending the Push right?  If so, why not allow us to upload both certificates (dev & production) and add a option that would allow us to choose the certificate to use?  You already have a Options section when sending the Push (where we select if the message should go Apple and/or Android).  You could simply add a check-box to the Apple Push sub-section saying “Use Sandbox Certificate”, something like that.

That’s a good suggestion. We actually have something in the works for this exact use case (We’ll have you upload both certificates, then we’ll automatically detect the right one to use for each device).

That would be perfect.

When I first saw the message “(Certificate Environment will be automatically detected)” I wrongly understood that the system was already doing that and my first reaction was: “Wow, this is an amazing feature”.  Glad that it will actually become a feature.

Hello,

You can only upload one certificate at a time. We detected the certificate type (Production or Development) so you don’t have select which one it is. We need to know the type so we connect the correct Apple server.

You can upload a Production push certificate to our site always use an Ad-Hoc provisioning profile when building your app in your testing. Or create another development version of your app.

Thanks.

Ah I see…

IMHO, the message ( “(Certificate Environment will be automatically detected)”) is then confusing. Now that you explained, made sense, but I would rephrase it in order to avoid that misunderstanding (if you get more feedback about that, of course).

Thanks for the reply jkasten.

Another suggestion:

I am thinking here, you only need the certificate when actually sending the Push right?  If so, why not allow us to upload both certificates (dev & production) and add a option that would allow us to choose the certificate to use?  You already have a Options section when sending the Push (where we select if the message should go Apple and/or Android).  You could simply add a check-box to the Apple Push sub-section saying “Use Sandbox Certificate”, something like that.

That’s a good suggestion. We actually have something in the works for this exact use case (We’ll have you upload both certificates, then we’ll automatically detect the right one to use for each device).

That would be perfect.

When I first saw the message “(Certificate Environment will be automatically detected)” I wrongly understood that the system was already doing that and my first reaction was: “Wow, this is an amazing feature”.  Glad that it will actually become a feature.