Setup individual user webhooks for a desktop application | Community
Skip to main content

Hello, currently creating a Desktop Compose app to work as a always on top mini display. I’m running a Ktor http server with the application and generating the users OAuth with a Redirect URL of: localhost:8080/callback which lets me use the rest api.

The issue I'm having is when trying to use Webhooks, I don’t see how I would be able to setup an endpoint URL for each user who runs the application. My understanding is I’d have to run a single server that accepts every single users notification and forward correct notifications to the individual users? Looking for solutions as the only option I can see is to poll conversations every few seconds.

Hey ​@Connor Blakesly! Emily here from Support Engineering at Intercom 👋🏼

 

You are correct that webhooks require a single, publicly accessible endpoint to receive notifications. Each webhook subscription is tied to an endpoint URL, and Intercom will send notifications to that URL for all relevant events. This means you cannot have a unique webhook endpoint for each user running a local instance of your app (e.g., localhost:8080/callback), as Intercom cannot reach local addresses.

The typical solution is to run a central server that receives all webhook notifications. Your server would then be responsible for routing or forwarding the relevant notifications to the correct user instance, possibly using a real-time communication method (such as WebSockets or similar) to push updates to each user's desktop app.

Polling the API every few seconds is less efficient and not recommended compared to using webhooks with a central server approach.


Hi thanks for reply. In terms of security, would a public app like this be approved on the store? If I were to initially receive every users webhook notification isn’t this a big security risk? My knowledge in web applications is not the best, but is there a reason for this design approach? I assume other people have requested instance only webhooks for individual users.