Webhooks Integration - how to synchronice databases

Hello,

I’m currently working to integrate my client’s web application with Discourse webhooks. While integrating with webhooks is well documented, straight forward process, I’m wondering how to synchronize Discourse database (categories, topics and posts) with my web application database.

I’m having trouble finding interface in admin panel that would allow me to fire webhooks for categories, topics and posts created before my integration.

Is it possible? Do you support this functionality? What are other options - e.g using API endpoints?

Have a great day,
Peter

Webhooks are fired when an action occurs on the Discourse site, so they will not be useful for getting details about historical activity on the site. You can get a lot of details about the Discourse site through the API. This would be a good approach for categories, groups, and badges. There are API endpoints for those tables, so you can get the data with a single request and then save it on your client’s web application. For a PHP example of how to get categories, see: https://github.com/discourse/wp-discourse/blob/master/lib/utilities.php#L78.

3 Likes

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.