The discussion revolves around manually triggering webhooks in Discourse. Parker1090 wants to trigger a webhook for around 30 topics in a specific category, but lacks experience with Ruby. pfaffman suggests generating the webhook using curl or Postman instead.
Parker1090 explains that they have an endpoint processing webhooks from a specific category and prefers a manual trigger to avoid generating signatures for each topic. pfaffman proposes editing the topics, such as adding and deleting a tag, but ultimately Parker1090 resolves the issue by manually editing the posts, which triggers the webhooks.
(pfaffman](/t/-/156097/6) commends the solution, noting that sometimes brute force is the quickest approach, rather than automation.
I did find a post on this but didn’t want to revive a 3-year-old thread.
I can’t even class myself as a novice when it comes to Ruby because I just haven’t used it. But basically, I have around 30 topics in a specific category that I want to trigger a webhook for (either new topic or post edited).
I’ve got as far as entering the command from the aforementioned topic but now I’m lost. What should “post” represent? I’ve tried the post ID in various ways, but I’m getting no where and can’t seem to find any answers.
Appreciate this may be an easy action for some, but I literally have zero experience with ruby, other than running the odd command I’ve found on this forum.
Basically I’ve built an endpoint that processes webhooks triggered from a specific category.
Postman is normally my go to, but didn’t want to hassle of generating a signature for each one (although admittedly, I could disable it temporarily).
My thought process was to some how manually trigger a webhook and just let the script do it’s job as it normally would. But certainly open to ideas - moreso when it makes life easier!
I’m not sure how to trigger a web hook without wading in the code. Maybe actually edit the topics? You could, say, add a tag to them and then delete it. Look at the bulk operations howto for some ideas.