Templates / Automate customer retention with AI risk prediction, Stripe coupons & personalized Gmail

Automate customer retention with AI risk prediction, Stripe coupons & personalized Gmail

Needs changes

by HayatoFujita/藤田隼人 ✓ · 170 views · created 2025-12-20 · Lead Nurturing, AI Summarization

Needs changes. This template uses 1 thing(s) that n8n 3.0 removes: OpenAI (legacy). 1 breaking item(s) found. Static check, last run 2026-10-19.

What this workflow does

This workflow has 22 nodes and runs on a schedule (every 3 hours). Along the way it connects Postgres, Gmail and Google Sheets. It also calls api.stripe.com over HTTP.

How it runs

Trigger: On a schedule (every 3 hours).

  1. 対象顧客リスト取得 (CRM) (HTTP Request): calls an HTTP API
  2. サポートチケット情報取得 (HTTP Request): calls an HTTP API
  3. サポート指標集計 (Code): runs custom JavaScript code
  4. 製品利用ログ取得 (Postgres): run a query
  5. データ統合 (CRM+サポート) (Merge): merges the data from its input branches
  6. データ統合 (全データ) (Merge): merges the data from its input branches
  7. AI解約リスク予測 (OpenAI): work with chat completion
  8. 高リスク顧客フィルタ (If): checks a condition and branches into true / false
  9. 特別オファー生成 (HTTP Request): calls api.stripe.com (POST)
  10. 未更新ログ取得 (Google Sheets): uses Google Sheets

…plus 11 more steps. See the full node list below.

Services it uses

PostgresGmailGoogle Sheets

HTTP calls to: api.stripe.com

Before you upgrade to n8n 3.0

1 thing in this workflow is removed in n8n 3.0. Fix it before you upgrade:

  • OpenAI (legacy) in AI解約リスク予測, リテンションメール生成: replace with OpenAI node (AI section).

Rather not rewrite it? Many of these flows can be rebuilt in Make (free plan).

Removed in 3.0Replace with
OpenAI (legacy)
AI解約リスク予測, リテンションメール生成
OpenAI node (AI section)

Nodes used (9)

From the author

Predict churn risk from customer data and send retention emails via OpenAI 👥 Who’s it for This workflow is designed for Customer Success Managers, Growth Teams, and SaaS Business Owners who want to proactively reduce churn using AI. It automates the analysis…

Excerpt from HayatoFujita/藤田隼人's description on n8n.io.

View the original on n8n.io → Check your own copy

Get the weekly “what broke” email

New templates, newly broken ones, and n8n release changes. One short email a week.

Form not loading? Subscribe here.