locked
CreateOrUpdateInstalltionAsync with template creates two registrations - one native and one template RRS feed

  • Question

  • Hi there,

    I'm using CreateOrUpdateInstallationAsync to register an installation ID with a single template but when I look in Server Explorer in Visual Studio there are two registrations created rather than one - one with type native and one with type template. If I don't specify a template I just get the one native as expected but by specifying a template I would have expected just one with type template - how do I prevent the (unused / not required) native registration from being created as well?

    Thanks,

    Derek 

    Monday, June 13, 2016 7:44 PM

Answers

  • Hi Derek,

    This is a legacy design that is resulting in you seeing two registrations. This basically means your installation is created successfully and you are able to 1. send to the device (hence the native registration), and 2. send with template (hence the template registration). You shouldn't worry about creating unused native registration because the whole native/template is a concept from registration models. When you create an installation with template, you can send both natively and with templates. And it's actually just one installation.

    Mimi

    Monday, June 13, 2016 8:22 PM

All replies

  • Hi Derek,

    This is a legacy design that is resulting in you seeing two registrations. This basically means your installation is created successfully and you are able to 1. send to the device (hence the native registration), and 2. send with template (hence the template registration). You shouldn't worry about creating unused native registration because the whole native/template is a concept from registration models. When you create an installation with template, you can send both natively and with templates. And it's actually just one installation.

    Mimi

    Monday, June 13, 2016 8:22 PM
  • Hi Derek,

    This behavior surprised me as well. Good to know that this is by design. I do however have another problem. I am using the Api to register a device (currently only windows) using the installation model through a back end service and things work as described above. I get 2 registrations. First is native, with a default tag added which is $InstallationId:{123} and a second registration (template) with a default Tag added being "$InstallationId:{123}, nameofmytemplate".  Even though the native works as expected and I can send/receive notifications with various tag expressions that I formed, I can't get notification using the template. I am sending the notification using the

    SendTemplateNotificationAsync(templateParams); I tried various tag combinations.I also tried broadcasting (omitting any tags). The error message I get is "The Notification was received and dropped by the Push Notification Service". I am probably missing something, but can't figure it out. Any Hints? Thanks.


    Anything's possible...just have to write the code

    Thursday, February 16, 2017 3:28 PM
  • Hi Mimi,

    I was asking the same derek question and your answer made it clear so I thank you.

    I take this opportunity to ask you another questions:

    Why are android devices registered twice as native and as template, while Apple (with APN) only as native? I'm pretty sure I'm doing the same things and I would also like Apple devices to be registerd as Template.

    Thanks,

    Filippo

    Wednesday, October 18, 2017 1:55 PM