Is it possible to write a Postman POST to test a web hook?

Asking because I don’t know, well have tried something but get a 504 error (timeout) so am clearly needing to learn more…
Need to be able to demonstrate to someone the web hook works from outside. It does from your test button but not from their API

\edit
just check my OttoReceiver file and that data is there, the 504 error is something else at play.

Have you tried adding the API key as a header instead of a query parameter? Not sure if we’ve updated the docs for this everywhere, but you can use this header

Authorization: Bearer dk_yourkeyhere

Otherwise you may need to post more detail about what you’re seeing

I doubt it is the API Key. If that was missing you would get an unauthorized error.

Did you try the built in test that you can do from the Webhooks page.


I apologize, I haven’t finished all the docs on the Webhook stuff yet.

Todd

I was just trying to find an easy external way of testing the web hook, from outside so I could pass that information to a jot forms support request where the form wasn’t triggering the web hook on submit.

Trying to do some root cause…

I see,

well you can use the “Copy” option there to copy the URL so at least you know it isn’t a typo in the URL you are entering in postman.

Toss

I had done that and used Postman to do a post to that url with a simple JSON body, but got a 504 timeout error, when I checked later the payload had arrived in my OttoReceiver file - so in fact I had tested it

Do you get the same result when you try the built in test function? IE does this only happen with Postman.

Todd

The built in test works exactly as expected.
The issue is, just as saying ‘well it works here for a customer service call’, troubleshooting list is
Does it work internally
Does it work externally
Does it work from the service I have hooked the webhook to

Sorry John,

I am just not sure I am following. Here is what I think you are saying.

  • The web hook works from the Test button. (This just makes a post from the browser. Should be very similar to Postman)
  • It does NOT work when you try to do it from Postman.

If that is the case I would like to know more because it should work from Postman. If it doesn’t then we need to track down why. Is there anything else you can tell us that might help us recreate the issue?

Todd

It does work from Postman - and by that I mean the payload and channel end up as a new record in my receiver file - but Postman got a 504 error which initially made me think it had not worked…

Hmmm Postman should not get a 504. It should get a 200. Webhooks must return a 2xx level response to the caller otherwise the caller may call again. So If that is what it is happening I would like to try to recreate it. So far I have been unable to. I always get something like this.

Todd

we have determined that your OttoReceiver script needs to exit with a JSON value right now.

This feels like a bug. We will investigate it and fix it if we can.

Todd

I have used apple Shortcuts for Testing Otto web hooks.