My requirement is-
I am sending an email to specific contacts then the receiver will be having a notification system, so when the receiver receives it then it should notify the user without refreshing the page as shown below image.
I know we can do something like- insert data into CDS, refresh the page get it display on front page but I don't want that I want it to be Live.
Note: in .net we can use a socket and achieve this. Do we have something like this in powerapps portal?
How can I achieve that?
A simpler implementation might be your very recommendation of just using records in CDS, but have (perhaps in your header) a small JS timer to query for new 'notifications' every 30s or few minutes or so. Keep in mind that you might still need to think of a way to store if this particular user has already seen this notification, unless it persists for X amount of time or you don't care about it showing on each query/page.
Be mindful that if you are essentially polling CDS/Dataverse that each poll will be a API request and depending on your users licencing (including if they are Internal vs External users) you may very well find that you exceed the daily API limits.
If the API limits are a problem you would probably have to come up with a complicated mechanism such as you have Ajax on your site talking to Azure (probably via the Oauth explicit grant flow functionality), code in azure then polling an Azure Service Bus to check if a new message has arrived (or working with Listener). And code on the Dataverse side to push to the Azure Service Bus when the update (response/receipt ) occurred in Dataverse. (and there are probably a number of technical challenges and of course additional costs to overcome with something like this also)
Wouldn't it be easier to just send the Contact an Email or SMS?
Hi @justinburch ,
Hi @Anonymous, I'm not aware of any capability built directly that you could leverage, as my limited experiences involved Azure resources.
There is no current PowerApps Portal publish/subscribe functionality - and you have to be mindful of the API limits if you are just polling Dataverse/CDS, that is why I suggested what I did as it is a way you could potentially make it work.
(The one thing you can do is make Entity Lists RSS feeds, but as per the doco this is not secure and should not be used for any thing that should not be publicly available)