Hello,
I’m trying to create Authentication middleware for bad status code response. I already try create new function called checkAvailability, it work but it seems like it will trigger everytime I turn on new zapier. also I’m trying to use z.request but I think I can’t do that.
![](https://uploads-us-west-2.insided.com/zapier-ca/attachment/94dca8d5-6473-4f19-addd-4bd92d67b4d9.png)
![](https://uploads-us-west-2.insided.com/zapier-ca/attachment/aa9c0213-45bd-48e6-b9cd-3e18cbca0eb2.png)
And also why it trigger twice?
![](https://uploads-us-west-2.insided.com/zapier-ca/attachment/3de8a4ed-63d6-42b9-aa72-93f7c237f0ba.png)