Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

136
Views
Filter response for trigger in Zapier CLI

I'm using Zapier Platform CLI and I'm having issues with firing the correct triggers.

I'm working with a legacy codebase. When you create a webhook, all events go to the URL you've provided. You can't subscribe to just one event.

With this in mind, I've created a RESTHook-style controller in our app. You can preform CRUD actions on webhooks, but you still get subscribed to every event. However, each event has it's name in the response, like so:

{ "event": "user.create", "id": 0, // ... }

In short, here's what I'm wondering:

What is the preferred way to filter events so that each trigger only responds to the appropriate event? I wouldn't want the order.create trigger firing on user.update.

I've looked in the examples and the docs, but I couldn't find anything that touches on this. Any advice or links are appreciated!

Thank you!

over 4 years ago · Santiago Trujillo
1 answers
Answer question

0

David here, from the Zapier Platform team. Sorry for the slow circle here.

The easiest way to do this is in the perform function for your hook (there's an example here).

Your code would have something like

if (bundle.cleanedRequest.event !== 'order.create') {
  return [] // noop
}

// process hook into order
return [order]

Hope that clears it up. ​Let me know if you've got any other questions!

over 4 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!