Best answer

How to run a zap and avoid loops


Userlevel 4
Badge +4

Hello, I already solved the problem to avoid loops with a Zap by adding a certain value within the last step of a Zap (I added a filter that looks for this value, if it exists it would stop running the Zap). It is described here: 

 

But now I do have an “advanced” version of this problem. I have to connect two apps (Zoho CRM and a invoicing tool) and I need to sync all contact/address updates from Zoho CRM to the invoicing tool. The workflow looks like this at the moment: 

01-Updated contact in Zoho CRM (Trigger) → 02-Find contact in Invoicing Tool → 03-Update contact in Invoicing Tool → 04-Update contact in Zoho CRM again (it adds some contact information back from the invoicing tool to certain fields in Zoho CRM to be sure/compare all address fields have been updated correct in the invoiceing tool) → Stop Zap

The big problem is that Step 04 would re-trigger the complete Zap and it would end in a loop by starting with step 01 etc. 

 

So I was looking for a method to add a certain value like a date, unique id (that is increasing by a number/value) etc. each time the Zap runs. 

And I thought about comparing dates: What is today’s date and if it is not the date that was set in the last step of the Zap it would continue the Zap. But this would not solve the problem. 

Do you have any ideas how to avoid loops for Zaps that need to run multiple times. 

I really appreciate any help. 

icon

Best answer by michael291 6 May 2021, 16:44

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.

4 replies

Userlevel 7
Badge +14

@michael291 

Maybe try using Zoho CRMWorkflow Rules to give yourself a finer level of control: https://help.zoho.com/portal/en/kb/crm/automate-business-processes/workflow-management/articles/configuring-workflow-rules#Execute_Based_on_Record_Action

Userlevel 7
Badge +12

Alternatively, but not task friendly, you could use storage by Zapier to store the last time the Zap was run for the contact and implement a filter to only continue if x amount of time has passed. 

Userlevel 4
Badge +4

@Troy Tessalone Thanks a lot. I will have a look on it. Meanwhile I found a solution: 

  1. I added a dropdown/select in Zoho CRM with the name “Trigger Addressupdate” containing the values “Yes” and “No”.
  2. I then created a workflow in Zoho CRM: When certain address fields will be changed to any value the dropdown “Trigger Addressupdate” will change to “Yes”.
  3. This is triggering the Zap and updating the corresponding address in the Invoicing Tool. In the last step of the Zap the dropdown “Trigger Adressupdate” will be changed to “No” again (which is the default value).
  4. The second step of this Zap contains a filter (Continue if… the field “Trigger Addressupdate” contains “Yes”). This will avoid a loop. 
Userlevel 4
Badge +4

@GetUWired I was thinking about a similar solution, but I was a bit struggling with Storage (my Zap ended up in a big loop :-().