Handle NPS survey responses with OpenAI, Gmail, and Google Sheets

Go to Workflow
0 views
Built by Incrementors Incrementors
Created on July 28, 2026

Description

Quick Overview
This workflow runs every 6 hours to read new NPS survey responses from Google Sheets, generates a personalized reply with OpenAI, and sends the email via Gmail. It then routes promoters, passives, and detractors for follow-up actions and marks each response as processed.

How it works
Runs on a schedule every 6 hours.
Reads NPS responses from a Google Sheets tab and keeps only rows where Status equals "new".
Validates required fields, parses the 0–10 NPS score, and classifies each response as Promoter, Passive, or Detractor.
Sends the response context to OpenAI (Chat Completions) to generate a concise, personalized email body and builds a segment-specific subject line.
Sends the personalized reply to the respondent using Gmail.
For promoters, appends the comment as a quote to a separate Google Sheets testimonials tab and updates the original row’s Status to "Processed".
For passives, updates the original Google Sheets row’s Status to "Processed", and for detractors, emails an alert to a support inbox via Gmail and then updates Status to "Processed".

Setup
Add credentials for Google Sheets, Gmail, and OpenAI in n8n.
Replace YOUR_NPS_SHEET_ID with your Google Sheets document ID in all Google Sheets steps.
Ensure your spreadsheet has an "nps-responses" tab with a Status column (values "new" and "Processed") and a "promoter-quotes" tab with the expected columns.
Replace YOUR_SUPPORT_TEAM_EMAIL with the inbox that should receive detractor alerts.
Review the OpenAI prompt and the Gmail sender name/formatting to match your brand voice before activating the workflow.

Nodes Used (4)

Code
n8n-nodes-base.code
Gmail
n8n-nodes-base.gmail
Google Sheets
n8n-nodes-base.googleSheets
HTTP Request
n8n-nodes-base.httpRequest