0
votes

I'm trying to use my .NET backend to register/send push notifications to my mobile devices.

Therefore, i'm following this article.

From my understanding:

  • POST: api/register registers the PNS handle the device has with Notification Hub.
  • PUT api/register/{registrationId} creates or updates the registration with Notification Hub.

Now my question is, why does this need to be a 2 stepped process?

Why can't the app on start/load, simply always call POST: api/register with the PNS handle, which can then create the registrationId (if necessary), and then use the existing (or newly created) registrationId to create the registration with ANH? Why does the app even need to store the registrationId?

Can someone please un-confuse me :)

1

1 Answers

-1
votes

As for the Put and Post in the article, it is to separate the registration id creation (POST) and registration id registration (PUT).

As for the REST APIs for Notification Hubs, https://msdn.microsoft.com/en-us/library/azure/dn495630.aspx will be the "create and update" that you are talking about.