I have a website (let’s call it the “host site”) that includes a self-hosted Discourse forum for discussion and private messaging.
At the moment I use a Discourse web hook to notify the host site of any new forum posts, so the host site is able to display an update count badge (the orange circles below) so users can see if there have been any new forum posts since their last visit:
What I’d like to do is to take this integration one step further and also display an icon on the host site if the user has unread private messages on the forum. This will be slightly more tricky than the existing integration, as it needs to take into account the “read” state of messages (i.e. reduce the message count when a message has been read)
What would be my best approach here, please?