title: Troubleshooting Zapier Webhook POSTING to Flask Server
body: <p>I am trying to use my Flask server to receive webhooks in a POST from a Zap, but I'm getting a 500 Internal Server Error when I test.</p>
  <pre><code>Traceback (most recent call last):
    File &quot;/usr/local/lib/python3.9/dist-packages/flask/app.py&quot;, line 2073, in wsgi_app
      response = self.full_dispatch_request()
    File &quot;/usr/local/lib/python3.9/dist-packages/flask/app.py&quot;, line 1518, in full_dispatch_request
      rv = self.handle_user_exception(e)
    File &quot;/usr/local/lib/python3.9/dist-packages/flask/app.py&quot;, line 1516, in full_dispatch_request
      rv = self.dispatch_request()
    File &quot;/usr/local/lib/python3.9/dist-packages/flask/app.py&quot;, line 1502, in dispatch_request
      return self.ensure_sync(self.view_functions[rule.endpoint])(**req.view_args)
  TypeError: receive_webhook() missing 1 required positional argument: 'request'
  </code></pre>
  <p>Here is my handler for the webhook:</p>
  <pre><code>@app.route(&quot;/webhook&quot;, methods=['POST'])
  def receive_webhook(request):
      print(request.json)
  
      return request.json
  </code></pre>
  <p>Here's a screenshot of my Zap I am trying to send the POST from<a href="https://i.stack.imgur.com/fFC9O.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/fFC9O.png" alt="Zap Screenshot" /></a>
  Thanks for any assistance.</p>
  <p>It seems like Zapier is calling my handler with no argument. Shouldn’t it be passing the payload as that <code>request</code> argument or am I misunderstanding something here?</p>
  <p>Edit: Also, if it's relevant, I'm using Nginx and Gunicorn for hosting. On an Ubuntu Linode.</p>