Best answer

Send the info about the Zap as part of rest hook subscription call

  • 9 November 2019
  • 5 replies

Userlevel 1

In my Zapier App, I am call the resthook API hosted on my app's server to pass on the bundle.targetUrl webhook URL where the data can be reported and trigger the app.

I want to send more information, as part of this resthook API call. Things like which action app is used as part of this Zap, what all fields have been mapped in the action app, which of them is required etc.

I want this so that I can configure my app more precisely to decide when exactly to report the data and trigger the Zap.

I think the answer to this question is in the bundle variable. But I am not able to find the exact structure of this variable what all data does it hold and if it holds other data about the Zap mentioned above.

For reference this is the current code for subscribeHook function in my app:


const subscribeHook = (z, bundle) => {

 const data = {

  url: bundle.targetUrl,

  event: ['new_conversation'],


 // You can build requests and our client will helpfully inject all the variables

 // you need to complete. You can also register middleware to control this.

 const options = {

  url: `${_sharedBaseUrl}/api/v1/convbot/${bundle.inputData.chatbot}/resthook`,

  method: 'POST',

  json: data,



 return z.request(options)

  .then((response) => JSON.parse(response.content));




Best answer by matthew 15 November 2019, 22:33

View original

This post has been closed for comments. Please create a new post if you need help or have a question about this topic.

5 replies

Userlevel 7
Badge +12

As far as I know, that's not possible. You can't get information about the zap running your app from the bundle object. However, you can get the Zap ID from which is available in performSubscribe and performUnsubscribe methods.

For reference, you can find more information about the content of bundle in the documentation here

Userlevel 1

Thanks @ikbelkirasan for you response.

Do you know, what kind of information I can fetch from the Zap_ID?

If I can get the above information from Zapier on a separate API call, using Zap_ID, that will work for me.



Userlevel 7
Badge +12

@Vinit_Agrawal I'm afraid that's not possible. Unfortunately, Zapier doesn't have an API that can be used for that.

Userlevel 7

Zapier Manager native app offers "Search Zap by ID" and then will return more info on that zap:








My Awesome Zap










However the current fields don't provide the info you're looking (which apps used etc.) There have been a lot of requests for the Zapier Manager app to include more granular info, and if this comes about could be used in your use-case.

We don't offer an API that exposes this information for apps that use REST Hooks — and it's not currently on our roadmap to offer such an API or expand the information that we give to apps for the purposes of REST Hook registration.

That said, I've gone ahead and added this to our internal product database just so the developer platform product team are aware of the level of interest in having such an API and/or exposing more information to developers. I can't make any specific promises but we'd post about this publicly in the event we decide to develop this further.