Best answer

Is it possible to have 2 API requests made in the same Zap?

  • 29 November 2021
  • 6 replies
  • 372 views

Hi, 
I want to call 2 API requests in the same trigger 
and I want to include the response of  the 2 APIs in the result 

icon

Best answer by jesse 24 February 2022, 22:56

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.

6 replies

Userlevel 7
Badge +14

Hi @Eyaaa 

Can you please clarify your question.

Do you mean have 2 different apps trigger the same Zap?

OR

Do you mean have 2 different API requests made in the same Zap?

 

App APIs can be used in Zaps with the Webhooks app.

Check out the available Zap triggers/actions: https://zapier.com/apps/webhook/integrations#triggers-and-actions

Hi @Troy Tessalone ,

I want  2 different API requests made in the same Zap?

Userlevel 7
Badge +14

@Eyaaa

App APIs can be used in Zaps with the Webhooks app.

Check out the available Zap actions: https://zapier.com/apps/webhook/integrations#triggers-and-actions

 

thank you 
I also want to know if there is another solution by switching to the code mode and trying to make 2 API requests 

Userlevel 7
Badge +14

@Eyaaa 

Code app supports making API requests: https://zapier.com/apps/code/help

Userlevel 7
Badge +9

Hey @Eyaaa it looks like our support team responded to you regarding this question and said:

That is possible to do. It looks like you are already using code mode. You will need to write javascript to chain those requests and promise handlers together. You can find more information on how to make HTTP requests here: https://github.com/zapier/zapier-platform/blob/master/packages/cli/README.md#making-http-requests (The documentation is for the CLI platform but you can use the same in Code mode). 
 
Just to be upfront I want to let you know that we don't offer support on how to structure your code and how to write Javascript. Code Mode is an advanced feature and we'd recommend using it if you have some experience in writing JS Code. But we're more than happy to answer questions around specific parts of our docs or help troubleshoot any platform errors you may encounter.

 

Due to this being Code-related, I am going to move this post into the “Code and Webhooks” category to get the right sets of eyes on this, should you have any follow-up questions. :slight_smile: