← All N8N workflows
AI & researchAggregateChain LLMCodeExecute WorkflowExecute Workflow Trigger

history channel slack and split out and slack

Configured with Aggregate, Chain LLM, Execute Workflow, Execute Workflow Trigger, and additional nodes. Review the connections and setup before adapting this template.

Workflow preview
MessagingGet Last Week'sMessagesSlackTransformSimplify MessageEdit FieldsCodeGroup By UserCodeTransformSplit OutSplit OutCodeMessages to ItemsCodeMessagingGet UserSlackTransformAggregateAggregateTransformSplit Out1Split OutMessagingGet ThreadSlackTransformAggregate1AggregateTransformSimplify ThreadCommentsEdit FieldsRoutingFilterFilterRoutingMessage RefNo OpTransformSplit Out2Split OutTransformMap Reply UserIdsEdit FieldsMessagingGet Reply UsersSlackAI & modelsGoogle Gemini ChatModelLM Chat Google GeminiAI & modelsSummarise ThreadsChain LLMTransformAggregate2AggregateTransformAggregate Reply UsersAggregateTransformReply UsersEdit FieldsAI & modelsGoogle Gemini ChatModel1LM Chat Google GeminiRoutingLoop Over ItemsLoop Over ItemsTransformAggregate3Edit FieldsTransformAggregate4AggregateTriggerWhen Executed byAnother WorkflowExecute Workflow TriggerRoutingSwitchSwitchSubworkflowMap Users to MessagesExecute WorkflowTransformGet User InfoEdit FieldsSubworkflowFetch Message RepliesExecute WorkflowRoutingHas ReplyUsers?IfCodeMessages to Items1CodeTransformAggregate ResultsEdit FieldsAI & modelsTeam Member WeeklyReport AgentChain LLMTransformMerge with ResultsEdit FieldsAI & modelsTeam Weekly ReportAgentChain LLMAI & modelsGoogle Gemini ChatModel2LM Chat Google GeminiMessagingPost Report in TeamChannelSlackSubworkflowSummarize MessageThreadsExecute WorkflowTriggerMonday @ 6amSchedule Trigger

Node categories in this workflow

  • Messaging
  • Transform
  • Code
  • Routing
  • AI & models
  • Trigger
  • Subworkflow

Icons describe general node roles, inferred from node types. Inspect the parameters for the configured action.

Drag to pan; use + and − to zoom. Reconstructed from the exported node positions; nothing runs here. Dashed lines represent non-main connections. Full node names and notes appear below.

How it works

The exported workflow contains the following configured nodes. Their connections are shown above; inspect the JSON for the complete logic, expressions, and external actions.

Workflow node names, types, and operations
NodeCategoryTypeOperation
Get Last Week's MessagesMessagingSlackchannel / history
Simplify MessageTransformEdit FieldsSee node parameters
Group By UserCodeCodeSee node parameters
Split OutTransformSplit OutSee node parameters
Messages to ItemsCodeCodeSee node parameters
Get UserMessagingSlackuser
AggregateTransformAggregateSee node parameters
Split Out1TransformSplit OutSee node parameters
Get ThreadMessagingSlackchannel / replies
Aggregate1TransformAggregateSee node parameters
Simplify Thread CommentsTransformEdit FieldsSee node parameters
FilterRoutingFilterSee node parameters
Message RefRoutingNo OpSee node parameters
Split Out2TransformSplit OutSee node parameters
Map Reply UserIdsTransformEdit FieldsSee node parameters
Get Reply UsersMessagingSlackuser
Google Gemini Chat ModelAI & modelsLM Chat Google GeminiSee node parameters
Summarise ThreadsAI & modelsChain LLMSee node parameters
Aggregate2TransformAggregateSee node parameters
Aggregate Reply UsersTransformAggregateSee node parameters
Reply UsersTransformEdit FieldsSee node parameters
Google Gemini Chat Model1AI & modelsLM Chat Google GeminiSee node parameters
Loop Over ItemsRoutingLoop Over ItemsSee node parameters
Aggregate3TransformEdit FieldsSee node parameters
Aggregate4TransformAggregateSee node parameters
When Executed by Another WorkflowTriggerExecute Workflow TriggerSee node parameters
SwitchRoutingSwitchSee node parameters
Map Users to MessagesSubworkflowExecute WorkflowSee node parameters
Get User InfoTransformEdit FieldsSee node parameters
Fetch Message RepliesSubworkflowExecute WorkflowSee node parameters
Has ReplyUsers?RoutingIfSee node parameters
Messages to Items1CodeCodeSee node parameters
Aggregate ResultsTransformEdit FieldsSee node parameters
Team Member Weekly Report AgentAI & modelsChain LLMSee node parameters
Merge with ResultsTransformEdit FieldsSee node parameters
Team Weekly Report AgentAI & modelsChain LLMSee node parameters
Google Gemini Chat Model2AI & modelsLM Chat Google GeminiSee node parameters
Post Report in Team ChannelMessagingSlackSee node parameters
Summarize Message ThreadsSubworkflowExecute WorkflowSee node parameters
Monday @ 6amTriggerSchedule TriggerSee node parameters

Setup

  1. Download the JSON and import it into an isolated n8n instance. Leave the workflow inactive.
  2. Connect your own credentials through n8n’s credential store. Replace REPLACE_WITH_* values with your resource identifiers.
  3. Inspect API destinations, Code nodes, database queries, file paths, and outbound actions.
  4. Run with synthetic data and harmless destinations. Enable triggers only after checking the actual outputs.

Requirements

An n8n instance with the listed node types and compatible versions. Service-connected workflows may require accounts, credentials, or paid APIs.

Credential types declared in the source

  • googlePalmApi
  • slackApi

Workflow notes

1. Fetch All Activity from Last Week

1. Fetch All Activity from Last Week

Learn more about the Slack node

We'll start by fetching all activity in our team channel over the last 7 days and group them by the message author. We can do this using the Slack node with a DateTime filter. This will give us the raw data to pick apart and analyse for reporting purposes.

2. Summarise Messages Threads & Conversations

2. Summarise Messages Threads & Conversations

Learn more about the Execute Workflow node

We'll do some more data mining by fetching all replies for each of these top level channel messages. By doing so, we get the full context of the conversation and can hopefully pick up some decisions, discoveries or concerns to add to our report. This data mining does require juggling a lot of "items" which becomes hard to manage so we'll use subworkflows to simplify this work.

Once the data mining is complete, we can summarize each thread with AI and ensure we're capturing only the significant events which are report-worthy.

3. Generate Activity Reports for Each Team Member

3. Generate Activity Reports for Each Team Member

Learn more about the Basic LLM node

With our summarized threads which are grouped per user, we can aggregate them and give them to the AI again to generate a weekly report for the team member. This could include their wins, challenges, learnings or decisions - it really is up to you as to what the report looks like.

A fun part of this output is getting to decide the tone of voice and delivery of the report. Don't be a bore and consider adding some personality and flair!

4. Generate Final Report for Whole Team

4. Generate Final Report for Whole Team

Learn more about the Basic LLM node

In this step, we go one level higher and aggregate all individual team member reports together into a big team report. In this way, the overview can group similar activities and generalise activities in a broader sense. The message output will also be shorter which some may find easier to digest.

5. Post Report on Team Channel (on Monday Morning!)

5. Post Report on Team Channel (on Monday Morning!)

Learn more about the Slack node

Finally, we can post the weekly report in the team channel. This is a great way to automate quick recaps for the team after the weekend break, get others back on track if they've been away or update client team who may pop in now and again to collaborate.

5. SubWorkflows

5. SubWorkflows

Read more about Execute Workflow Trigger

Incorporating Subworkflows into your main workflow is an advanced technique and sometimes necessary if you're working with a lot of nested items or loops.

In this scenario, we perform quite a few lookups to get the data we need; users, messages and replies, which in template terms would require many loop nodes to string together. However, when you nest loops nodes within loop nodes, item reference becomes difficult to keep track of.

Using subworkflows, we can break down each loop into a separate execution which handles items and item references in a simpler, linear way. The result is predictable data flow throughout our template.

Try It Out!

Try It Out!

This n8n template lets you summarize individual team member activity on slack for the past week and generates a report.

For remote teams, chat is a crucial communication tool to ensure work gets done but with so many conversations happening at once and in multiple threads, ideas, information and decisions usually live in the moment and get lost just as quickly - and all together forgotten by the weekend!

Using this template, this doesn't have to be the case. Have AI crawl through last week's activity, summarize all threads and generate a casual and snappy report to bring the team back into focus for the current week. A project manager's dream!

How it works

  • A scheduled trigger is set to run every Monday at 6am to gather all team channel messages within the last week.
  • Each message thread are grouped by user and data mined for replies.
  • Combined, an AI analyses the raw messages to pull out interesting observations and highlights.
  • The summarized threads of the user are then combined together and passed to another AI agent to generate a higher level overview of their week. These are referred to as the individual reports.
  • Next, all individual reports are summarized together into a team weekly report. This allows understanding of group and similar activities.
  • Finally, the team weekly report is posted back to the channel. The timing is important as it should be the first message of the week and ready for the team to glance over coffee.

How to use

  • Ideally works best per project and where most of the comms happens on a single channel. Avoid combining channels and instead duplicate this workflow for more channels.
  • You may need to filter for specific team members if you want specific team updates.
  • Customise the report to suit your organisation, team or the channel. You may prefer to be more formal if clients or external stakeholders are also present.

Requirements

  • Slack for chat platform
  • Gemini for LLM

Customising this workflow

  • If the slack channel is busy enough already, consider posting the final report to email.
  • Pull in project metrics to include in your report. As extra context, it may be interesting to tie the messages to production performance.
  • Use an AI Agent to query for knowledgebase or tickets relevant to the messages. This may be useful for attaching links or references to add context.

Need Help?

Join the Discord or ask in the Forum!

Happy Hacking!

history channel slack and split out and slack

history channel slack and split out and slack

Purpose and structure

This folder contains the history channel slack and split out and slack workflow. Its executable nodes use aggregate, chainLlm, code, executeWorkflow, executeWorkflowTrigger, filter, if, lmChatGoogleGemini, noOp, scheduleTrigger, set, slack, splitInBatches, splitOut, switch. The table and connection map below are derived from the JSON, not an inferred guarantee of behavior.

Setup

Import inactive. Configure your own credentials and replace REPLACE_WITH_* values. Review external destinations and Code nodes before running.

Entry points

When Executed by Another Workflow, Monday @ 6am

Verification

Sanitized source candidate; not runtime-tested. This overview is generated from node metadata. Read the folder README for the connection map, credential types, and license.

Attribution

https://github.com/Zie619/n8n-workflows/blob/94007c1445d9258a7da116646b79473e7c7c3282/workflows/Splitout/0921_Splitout_Code_Send_Scheduled.json MIT; preserve source notices.

More in AI & research