Solved

Can push notification URL be dynamic as a function of CompanyId?

  • 10 August 2021
  • 3 replies
  • 132 views

Userlevel 3
Badge

Hello, 

Our push notifications are part of our customization project, and we publish our customization project to all three of our tenants to keep them in sync. When we do this, the push notification URL is set to the same value for all three tenants, whereas we need each tenant to use its own specific push notification URL. Is it possible for the push notification URL to be dynamic? We’d like each tenant to use different  push notification URL depending on the CompanyId of the tenant.

Thank you, 

Dave

icon

Best answer by jinin 27 November 2021, 18:17

View original

3 replies

Userlevel 7
Badge +11

Hi @dhollinden 

Can you please extend the customization plugin and customize the url to have the company ID as param ?

sample url - https://secure.domain.com/whatever.csp?myparam1=x&myparam2=y

Example:

public class CustomizationPluginExtn : CustomizationPlugin
    {
        public override void UpdateDatabase()
        {

          // - -- write the code to Initialize the Push notification graph and assign the url with companyId as parameter.

         }

}

When ever package publish, dynamically delete the existing Push notification and create new. So we can avoid the duplicate record creations.

Userlevel 3
Badge

Thank you, @jinin 

Your solution makes a lot of sense. And perhaps with that approach, we could actually assign different URLs based on the companyid, rather than place companyid on the querystring. 

We’ll definitely keep your solution in mind. We already addressed our situation a different way by sending the push notifications from all tenants to the same lambda function, which then routes the notifications to their proper destination based on companyid. 

Many thanks, 

Dave

Userlevel 7
Badge +11

@dhollinden  Thank you for your update!!

Reply


About Acumatica ERP system
Acumatica Cloud ERP provides the best business management solution for transforming your company to thrive in the new digital economy. Built on a future-proof platform with open architecture for rapid integrations, scalability, and ease of use, Acumatica delivers unparalleled value to small and midmarket organizations. Connected Business. Delivered.
© 2008 — 2024  Acumatica, Inc. All rights reserved