Intermediate~20 min setupAI & CommunicationVerified April 2026
OpenAI logo
Slack logo

How to Monitor Slack Feedback with OpenAI Sentiment Analysis using N8n

Automatically classify messages in your #feedback Slack channel as positive, neutral, or negative using OpenAI's GPT models and N8n workflows.

Steps and UI details are based on platform versions at time of writing — check each platform for the latest interface.

Best for

Teams that need custom sentiment routing logic and want to avoid per-execution costs at high volumes.

Not ideal for

Non-technical teams that need reliable, maintenance-free automation without custom code requirements.

Sync type

real-time

Use case type

notification

Real-World Example

💡

A 25-person B2B SaaS company uses this to triage customer feedback in their #feedback Slack channel. Positive feedback gets a celebration emoji and gets logged for testimonial opportunities. Negative feedback immediately alerts the customer success team in a private channel with the original message and customer context. Before automation, the CS team checked the feedback channel manually twice per day and often missed urgent issues for 4-6 hours.

What Will This Cost?

Drag the slider to your expected monthly volume.

/mo
505005K50K

Each platform counts differently — Zapier: 1 task per trigger. Make: 1 operation per module per record. n8n: 1 execution per run.

Prices shown for annual billing. Based on published pricing as of April 2026.

Estimated ROI

1000

min saved/mo

$583

labor value/mo

Free

no platform cost

Based on ~2 min manual effort per operation at $35/hr fully loaded labor cost.

Implementation

Skip the setup

Import this workflow directly into n8n

Copy the pre-built n8n blueprint and paste it straight into n8n. All modules, filters, and field mappings are already configured — you just need to connect your accounts.

Before You Start

Make sure you have everything ready.

Slack workspace admin access to add N8n app and invite it to channels
OpenAI API key with available credits (minimum $5 balance recommended)
N8n instance running (cloud or self-hosted) with Slack and OpenAI nodes available
An active #feedback channel with regular message activity for testing

Field Mapping

Map these fields between your apps.

FieldAPI Name
Required
Message Texttext
Channel IDchannel
Message Timestampts
User IDuser
Sentiment Scoresentiment
1 optional field▸ show
Thread Timestampthread_ts

Step-by-Step Setup

1

Workflow > Add Node > Slack Trigger

Set up Slack trigger node

Create a new workflow and configure the Slack trigger to monitor your feedback channel. This node will fire whenever a new message is posted to the specified channel.

  1. 1Click the + button to add a new node
  2. 2Search for 'Slack' and select 'Slack Trigger'
  3. 3Choose 'On New Message Posted to Channel' from the events dropdown
  4. 4Connect your Slack workspace using OAuth2
What you should see: You should see a connected Slack trigger node with a green connection indicator.
Common mistake — Make sure to select 'On New Message Posted to Channel' not 'On Message Updated' — the latter triggers on edits and reactions too.
n8n
+
click +
search apps
OpenAI
OP
OpenAI
Set up Slack trigger node
OpenAI
OP
module added
2

Slack Trigger > Parameters

Configure channel monitoring

Specify which channel to monitor and set up message filtering. This prevents the workflow from analyzing bot messages or system notifications.

  1. 1In the Channel field, type '#feedback' or select from the dropdown
  2. 2Toggle 'Listen to Bot Messages' to OFF
  3. 3Set 'Include Threads' to YES if you want to analyze thread replies
  4. 4Click 'Test Step' to verify the connection
What you should see: The test should show recent messages from your #feedback channel with user names and timestamps.
Common mistake — If your channel doesn't appear in the dropdown, the N8n Slack app needs to be invited to that channel first.
3

Workflow > IF Node > Conditions

Add message filtering logic

Create an IF node to filter out unwanted messages like empty posts, URLs-only messages, or messages shorter than 10 characters. This saves API calls to OpenAI.

  1. 1Add an IF node after the Slack trigger
  2. 2Set condition to 'String' > 'Length' > 'Larger' > '10'
  3. 3Map the input to {{$node['Slack Trigger'].json['text']}}
  4. 4Connect the 'true' output to continue the workflow
What you should see: The IF node should show green checkmarks and display the filtering logic correctly.
Common mistake — Filters are the most common place setups break. Double-check the field name and value exactly match what your app sends — a single capital letter difference will block everything.
OpenAI
OP
trigger
filter
Condition
matches criteria?
yes — passes through
no — skipped
Slack
SL
notified
4

Workflow > Add Node > OpenAI > Chat

Connect OpenAI node

Add the OpenAI node and configure it for text analysis. You'll use the chat completion endpoint with GPT-3.5-turbo for fast, cost-effective sentiment analysis.

  1. 1Add an OpenAI node after the IF node's true output
  2. 2Select 'Chat' as the resource type
  3. 3Choose 'Create a Chat Completion' as the operation
  4. 4Add your OpenAI API key in the credentials section
What you should see: The OpenAI node appears with a credentials field and model selection dropdown populated.
Common mistake — Use gpt-3.5-turbo, not gpt-4 — sentiment analysis doesn't need GPT-4's advanced reasoning and costs 10x more.
5

OpenAI Node > Parameters > Messages

Configure sentiment analysis prompt

Set up the system prompt to ensure consistent sentiment classification. The prompt instructs GPT to return only 'positive', 'negative', or 'neutral' for reliable parsing.

  1. 1Set Model to 'gpt-3.5-turbo'
  2. 2In System Message, enter: 'Analyze the sentiment of this customer feedback. Respond with only one word: positive, negative, or neutral.'
  3. 3Map User Message to {{$node['Slack Trigger'].json['text']}}
  4. 4Set Max Tokens to 10 and Temperature to 0
What you should see: The prompt configuration shows the mapped Slack message text and system instructions.
Common mistake — Keep Temperature at 0 for consistent results — higher values make GPT responses unpredictable for classification tasks.
6

Workflow > Add Node > Code > JavaScript

Add sentiment parsing logic

Use a Code node to extract and clean the sentiment result from OpenAI's response. This handles edge cases where GPT returns extra words or formatting.

  1. 1Add a Code node after the OpenAI node
  2. 2Select JavaScript as the language
  3. 3Add code to parse the sentiment from the OpenAI response
  4. 4Include logic to default to 'neutral' if parsing fails
What you should see: The Code node should show a JavaScript editor with your sentiment parsing logic.
Common mistake — Always include a fallback to 'neutral' — sometimes GPT returns explanations instead of single-word classifications.
7

Workflow > Add Node > Switch > Routes

Set up Slack response routing

Create a Switch node to route different sentiment types to different Slack actions. This lets you customize the response based on whether feedback is positive, negative, or neutral.

  1. 1Add a Switch node after the Code node
  2. 2Create three routes: positive, negative, neutral
  3. 3Set the input value to {{$node['Code'].json['sentiment']}}
  4. 4Configure each route to match the exact string values
What you should see: The Switch node displays three output paths labeled with sentiment types.
Common mistake — Match exact strings including case — 'Positive' won't match 'positive' and will default to the fallback route.
8

Switch > Positive Route > Slack Node

Configure positive feedback actions

Set up what happens when positive feedback is detected. This typically involves posting to a different channel or adding reaction emojis to celebrate good feedback.

  1. 1Connect a Slack node to the 'positive' output
  2. 2Choose 'Add Reaction' as the operation
  3. 3Map the channel and timestamp from the trigger
  4. 4Set the reaction emoji to 'thumbsup' or 'tada'
What you should see: The Slack node shows reaction configuration with mapped channel and timestamp fields.
9

Switch > Negative Route > Slack Node

Handle negative feedback alerts

Configure escalation for negative feedback by posting to a management channel or mentioning specific team members. Critical feedback needs immediate attention.

  1. 1Connect another Slack node to the 'negative' output
  2. 2Choose 'Post Message' as the operation
  3. 3Set channel to '#customer-success' or your escalation channel
  4. 4Create a message template with the original feedback and user
What you should see: The negative route shows a Slack node configured to post escalation messages.
Common mistake — Don't post negative feedback back to the original channel — use a private escalation channel to avoid public drama.
10

Switch > Neutral Route > Slack Node

Log neutral feedback

Set up simple logging for neutral feedback that doesn't require immediate action but should be tracked for analysis. A simple emoji reaction works well.

  1. 1Connect a Slack node to the 'neutral' output
  2. 2Choose 'Add Reaction' as the operation
  3. 3Map channel and timestamp fields
  4. 4Set reaction to 'eyes' or 'memo' to indicate processing
What you should see: The neutral route shows a configured reaction node for acknowledgment.
11

Workflow > Execute Workflow

Test the complete workflow

Run end-to-end tests with sample messages to verify sentiment classification and routing work correctly. Test all three sentiment types to confirm each path executes properly.

  1. 1Click 'Execute Workflow' in the top right
  2. 2Post a test message to your #feedback channel
  3. 3Check that the workflow triggered and completed successfully
  4. 4Verify the correct Slack action was taken based on sentiment
What you should see: The workflow execution panel shows green checkmarks for all nodes and the expected Slack reaction or message appears.
Common mistake — Test during business hours when your #feedback channel has natural activity — empty channels won't trigger properly.
n8n
▶ Run once
executed
OpenAI
Slack
Slack
🔔 notification
received
12

Workflow > Settings > Error Handling

Activate continuous monitoring

Enable the workflow to run automatically on new messages. Set up error handling to prevent workflow failures from breaking ongoing monitoring.

  1. 1Click the 'Active' toggle in the top right
  2. 2Go to Settings > Error Handling
  3. 3Set 'Continue on Fail' to ON for all nodes
  4. 4Configure webhook timeout to 30 seconds
What you should see: The workflow shows as 'Active' with a green indicator and error handling configured.
Common mistake — Without 'Continue on Fail', one OpenAI API error will stop monitoring all future messages until you manually restart.

Drop this into an n8n Code node.

JavaScript — Code Node// Clean and validate GPT sentiment response
▸ Show code
// Clean and validate GPT sentiment response
const response = $node['OpenAI'].json['choices'][0]['message']['content'].toLowerCase().trim();
const sentiment = ['positive', 'negative', 'neutral'].find(s => response.includes(s)) || 'neutral';

... expand to see full code

// Clean and validate GPT sentiment response
const response = $node['OpenAI'].json['choices'][0]['message']['content'].toLowerCase().trim();
const sentiment = ['positive', 'negative', 'neutral'].find(s => response.includes(s)) || 'neutral';
return [{json: {sentiment, confidence: response.length < 20 ? 'high' : 'low'}}];

Scaling Beyond 100+ messages/day+ Records

If your volume exceeds 100+ messages/day records, apply these adjustments.

1

Add queue management

Use N8n's Wait node to add 2-3 second delays between OpenAI API calls. This prevents rate limiting when multiple feedback messages arrive simultaneously.

2

Batch process during off-hours

Switch to a scheduled workflow that processes accumulated messages every 30 minutes instead of real-time processing. This reduces API costs and improves reliability.

3

Implement smart filtering

Add keyword detection to skip obvious spam or automated messages before hitting the OpenAI API. Simple regex for URLs, repeated characters, or common bot patterns saves significant costs.

Going live

Production Checklist

Before you turn this on for real, confirm each item.

Troubleshooting

Common errors and how to fix them.

Frequently Asked Questions

Common questions about this workflow.

Analysis

VerdictWhy n8n for this workflow

Use N8n for this if you need custom sentiment logic beyond simple positive/negative classification or want to route different sentiment types to different channels. N8n's Code nodes let you add custom parsing for edge cases where GPT returns unexpected responses. You also get unlimited free executions for self-hosted instances. Pick Zapier instead if your team needs a setup-and-forget solution — N8n requires more technical maintenance.

Cost

This workflow costs practically nothing to run. Each message uses 2-3 N8n executions (trigger, OpenAI call, Slack action). At 200 feedback messages per month, that's 600 executions total. N8n cloud's Starter plan includes 5,000 executions for $20/month, so you're well under the limit. OpenAI costs about $0.0001 per sentiment analysis with GPT-3.5-turbo, adding $0.02/month. Zapier would cost $30/month for the same volume since it needs a paid plan for multi-step workflows.

Tradeoffs

Zapier wins on reliability — their Slack trigger fires within 15 seconds while N8n sometimes has 1-2 minute delays during peak usage. Make handles high-volume scenarios better with built-in rate limiting and automatic retries for OpenAI API timeouts. But N8n gives you granular control over the sentiment classification logic. You can add custom scoring, handle sarcasm detection, or route based on multiple criteria that the other platforms can't match without complex workarounds.

You'll hit OpenAI rate limits if your feedback channel gets busy — the free tier allows 3 requests per minute. Upgrade to a paid OpenAI plan or add delay nodes between API calls. N8n's Slack trigger sometimes misses messages posted within seconds of each other due to webhook processing delays. The Code node will break if GPT returns JSON instead of plain text, which happens about 1% of the time with creative prompts.

Ideas for what to build next

  • Add sentiment trending dashboardConnect a Google Sheets node to log all sentiment results with timestamps. Build a simple dashboard to track feedback sentiment trends over time.
  • Create escalation workflows for negative feedbackExtend negative sentiment routing to create Notion tasks or send emails to account managers for immediate customer outreach and resolution.
  • Implement keyword-based routingAdd Code nodes to detect specific topics like 'billing', 'bug', or 'feature request' and route to appropriate team channels regardless of sentiment.

Related guides

Was this guide helpful?
OpenAI + Slack overviewn8n profile →