Best answer

Remove duplicates from Digest

  • 9 February 2022
  • 7 replies
  • 147 views

Userlevel 1

I am building a zap involving the digest step. It basically logs changes from an issue tracker for a weekly review.

However, there are quite a few duplicate entries at the end of the week which is to be expected, given the trigger setup (unfortunately there is no way around that).

Is it possible to remove duplicate entries from the digest before sending it to the next step (Slack in my case)?

icon

Best answer by Troy Tessalone 9 February 2022, 16:40

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.

7 replies

Userlevel 7
Badge +12

Hi @ubuntudroid 

can you share screenshots of the zap that sends to slack? including the data? You may need code to remove the entries but it should be doable. 

Userlevel 7
Badge +14

Hi @ubuntudroid 

Try logging these in a GSheet or Airtable, then check against that log to determine if a new record should be created or if an existing record is found (e.g. Find else Create), before proceeding to be added to the Digest.

Userlevel 1

Hi @ubuntudroid 

can you share screenshots of the zap that sends to slack? including the data? You may need code to remove the entries but it should be doable. 

The digested data is just a simple list of URLs:

https://link/to/first/issue
https://link/to/second/issue
https://link/to/first/issue
https://link/to/third/issue

If I get you right, @GetUWired, you are suggesting a code step in between which takes care of deduplicating?

Userlevel 1

Hi @ubuntudroid 

Try logging these in a GSheet or Airtable, then check against that log to determine if a new record should be created or if an existing record is found (e.g. Find else Create), before proceeding to be added to the Digest.

That’s a good idea, @Troy Tessalone. I’m going to try this out if the code step proposed by @GetUWired doesn’t work for some reason, as I would prefer to not add another tool to the chain if possible.

Userlevel 7
Badge +14

@ubuntudroid 

Might be useful:

 

Userlevel 7
Badge +12

Yep and it looks like that article Troy shared is perfect! 

Sheets would be no code of course but would just work out okay as you would have to loop through everything returned from the digest ( sheets can only find/create 1 row at a time ) and then you’d have to figure out a way to get everyone back into 1 output or you’d end up sending multiple notifications to Slack.. 

Userlevel 1

Deduplication with @Troy Tessalone’s code step works great, exactly what I needed! Thanks both of you!