Skip to main content

Javascript to verify webhook challenge

  • June 1, 2022
  • 2 replies
  • 1679 views

I’m trying to use javascript to verify a webhook as suggested here: https://api.developer.monday.com/docs/webhooks-1#sample-payload-for-webhook-events

However, it doesn’t work. Any ideas?
Below is my javascript:

<script type="text/javascript">
        
        app.post("/", function (req, res) {
            console.log(JSON.stringify(req.body, 0, 2));
            res.status(200).send(req.body);
        })
     
    </script>

2 replies

Matias.Monday
Forum|alt.badge.img
  • monday.com Team Member
  • June 6, 2022

Hello @bobpotter!

That is strange.

I just used the same script and it worked for me.

Which error are you getting?

Are you running your project when you try to create the connection?


  • Author
  • Participating Frequently
  • June 6, 2022

Thanks for responding. I never did get the Javascript working. I get an “app” is undefined error. However, I found a better way (for me) using C#. So, I’m no longer trying to use the Javascript method.