Javascript to verify webhook challenge

I’m trying to use javascript to verify a webhook as suggested here: Webhooks

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

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

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?

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.