LoopFour

Customer Success

Workflow patterns for customer success and retention teams

Customer Success Workflows

Automate onboarding, health monitoring, renewal management, and proactive customer engagement across your customer success stack.

Why Automate Customer Success?

Customer success teams face unique challenges:

  • Manual onboarding delays time-to-value for new customers
  • Health score updates require pulling data from multiple systems
  • Renewal tracking relies on spreadsheets and calendar reminders
  • Churn signals often detected too late to intervene
  • NPS and feedback collection is inconsistent

Workflow automation solves these by:

  • Triggering onboarding instantly when subscriptions start
  • Calculating health scores automatically from usage data
  • Alerting CSMs proactively when accounts need attention
  • Standardizing customer communication touchpoints
  • Ensuring no renewal falls through the cracks

Common Workflow Patterns

Automated Onboarding

Trigger: New subscription created in Stripe Actions: Create customer records, send welcome email, notify team

Automatically set up new customers across all systems when they subscribe.

{
  "name": "Customer Onboarding",
  "trigger": {
    "type": "webhook",
    "provider": "stripe",
    "events": ["customer.subscription.created"]
  },
  "steps": [
    {
      "id": "get-customer",
      "type": "action",
      "config": {
        "connector": "stripe",
        "action": "getCustomer",
        "customerId": "{{input.data.object.customer}}"
      }
    },
    {
      "id": "create-qb-customer",
      "type": "action",
      "config": {
        "connector": "quickbooks",
        "action": "createCustomer",
        "DisplayName": "{{steps.get-customer.output.name}}",
        "PrimaryEmailAddr": {
          "Address": "{{steps.get-customer.output.email}}"
        }
      },
      "onError": { "action": "continue" }
    },
    {
      "id": "create-hubspot-contact",
      "type": "action",
      "config": {
        "connector": "hubspot",
        "action": "createContact",
        "email": "{{steps.get-customer.output.email}}",
        "properties": {
          "firstname": "{{steps.get-customer.output.name | split: ' ' | first}}",
          "lastname": "{{steps.get-customer.output.name | split: ' ' | last}}",
          "lifecyclestage": "customer",
          "stripe_customer_id": "{{steps.get-customer.output.id}}",
          "subscription_start_date": "{{now | date: '%Y-%m-%d'}}"
        }
      }
    },
    {
      "id": "send-welcome-email",
      "type": "email",
      "config": {
        "action": "send",
        "provider": "sendgrid",
        "to": "{{steps.get-customer.output.email}}",
        "from": "success@company.com",
        "subject": "Welcome to Company!",
        "body": {
          "html": "<h1>Welcome, {{steps.get-customer.output.name}}!</h1><p>We're excited to have you on board.</p><h2>Getting Started</h2><ol><li><a href='https://app.company.com/setup'>Complete your setup</a></li><li><a href='https://docs.company.com'>Read our documentation</a></li><li><a href='https://company.com/book-onboarding'>Book your onboarding call</a></li></ol>"
        }
      }
    },
    {
      "id": "notify-cs-team",
      "type": "slack",
      "config": {
        "action": "sendMessage",
        "channel": "#new-customers",
        "blocks": [
          {
            "type": "header",
            "text": { "type": "plain_text", "text": "New Customer!" }
          },
          {
            "type": "section",
            "fields": [
              { "type": "mrkdwn", "text": "*Name:*\n{{steps.get-customer.output.name}}" },
              { "type": "mrkdwn", "text": "*Email:*\n{{steps.get-customer.output.email}}" },
              { "type": "mrkdwn", "text": "*Plan:*\n{{input.data.object.items.data.[0].plan.nickname}}" },
              { "type": "mrkdwn", "text": "*MRR:*\n${{input.data.object.items.data.[0].plan.amount | divided_by: 100}}" }
            ]
          },
          {
            "type": "actions",
            "elements": [
              {
                "type": "button",
                "text": { "type": "plain_text", "text": "View in Stripe" },
                "url": "https://dashboard.stripe.com/customers/{{steps.get-customer.output.id}}"
              }
            ]
          }
        ]
      }
    }
  ]
}

Benefits:

  • Customer set up across all systems instantly
  • Welcome email sent automatically
  • CS team notified with full context
  • No manual data entry required

Full Customer Onboarding Tutorial →


Health Score Monitoring

Trigger: Scheduled daily Actions: Calculate usage metrics, update health score, alert on low scores

Automatically calculate and track customer health scores.

{
  "name": "Daily Health Score Update",
  "trigger": {
    "type": "schedule",
    "cron": "0 6 * * *"
  },
  "steps": [
    {
      "id": "get-active-customers",
      "type": "action",
      "config": {
        "connector": "hubspot",
        "action": "searchContacts",
        "filter": {
          "lifecyclestage": { "$eq": "customer" }
        }
      }
    },
    {
      "id": "calculate-health-scores",
      "type": "loop",
      "config": {
        "items": "{{steps.get-active-customers.output.results}}",
        "step": {
          "type": "transform",
          "config": {
            "operation": "map",
            "data": {
              "contactId": "{{item.id}}",
              "email": "{{item.properties.email}}",
              "loginScore": "{{#if (gt item.properties.days_since_login 30)}}0{{else if (gt item.properties.days_since_login 14)}}25{{else if (gt item.properties.days_since_login 7)}}50{{else}}100{{/if}}",
              "usageScore": "{{#if (gt item.properties.feature_usage_pct 80)}}100{{else if (gt item.properties.feature_usage_pct 50)}}75{{else if (gt item.properties.feature_usage_pct 25)}}50{{else}}25{{/if}}",
              "supportScore": "{{#if (eq item.properties.open_tickets 0)}}100{{else if (lt item.properties.open_tickets 3)}}75{{else}}50{{/if}}",
              "healthScore": "{{(loginScore + usageScore + supportScore) / 3}}"
            }
          }
        }
      }
    },
    {
      "id": "update-health-scores",
      "type": "loop",
      "config": {
        "items": "{{steps.calculate-health-scores.output}}",
        "step": {
          "type": "action",
          "config": {
            "connector": "hubspot",
            "action": "updateContact",
            "contactId": "{{item.contactId}}",
            "properties": {
              "health_score": "{{item.healthScore}}",
              "health_score_updated": "{{now | date: '%Y-%m-%d'}}"
            }
          }
        }
      }
    },
    {
      "id": "find-at-risk",
      "type": "transform",
      "config": {
        "operation": "filter",
        "data": "{{steps.calculate-health-scores.output}}",
        "condition": "{{item.healthScore < 50}}"
      }
    },
    {
      "id": "alert-at-risk",
      "type": "condition",
      "config": {
        "if": "{{steps.find-at-risk.output.length > 0}}",
        "then": "notify-at-risk",
        "else": "end"
      }
    },
    {
      "id": "notify-at-risk",
      "type": "slack",
      "config": {
        "action": "sendMessage",
        "channel": "#cs-alerts",
        "blocks": [
          {
            "type": "header",
            "text": { "type": "plain_text", "text": "At-Risk Customers Alert" }
          },
          {
            "type": "section",
            "text": {
              "type": "mrkdwn",
              "text": "{{steps.find-at-risk.output.length}} customers have health scores below 50:\n\n{{#each steps.find-at-risk.output}}• {{this.email}} (Score: {{this.healthScore}})\n{{/each}}"
            }
          }
        ]
      }
    }
  ]
}

Benefits:

  • Health scores updated consistently
  • At-risk accounts identified automatically
  • CSM team alerted proactively
  • Data-driven customer management

Renewal Management

Trigger: 90 days before subscription renewal Actions: Create renewal opportunity, notify CSM, send customer email

Proactively manage renewals before they become urgent.

{
  "name": "Renewal Management",
  "trigger": {
    "type": "schedule",
    "cron": "0 8 * * 1"
  },
  "steps": [
    {
      "id": "find-upcoming-renewals",
      "type": "action",
      "config": {
        "connector": "stripe",
        "action": "listSubscriptions",
        "status": "active",
        "current_period_end": {
          "$gte": "{{now | dateAdd: 60, 'days' | date: '%s'}}",
          "$lte": "{{now | dateAdd: 90, 'days' | date: '%s'}}"
        }
      }
    },
    {
      "id": "process-renewals",
      "type": "loop",
      "config": {
        "items": "{{steps.find-upcoming-renewals.output.data}}",
        "step": {
          "type": "action",
          "config": {
            "connector": "hubspot",
            "action": "createDeal",
            "properties": {
              "dealname": "{{item.customer.name}} - Renewal",
              "dealstage": "renewal_upcoming",
              "amount": "{{item.items.data.[0].price.unit_amount | divided_by: 100 | multiply: 12}}",
              "closedate": "{{item.current_period_end | date: '%Y-%m-%d'}}",
              "deal_type": "renewal",
              "stripe_subscription_id": "{{item.id}}"
            }
          }
        }
      }
    },
    {
      "id": "notify-csms",
      "type": "slack",
      "config": {
        "action": "sendMessage",
        "channel": "#cs-renewals",
        "blocks": [
          {
            "type": "header",
            "text": { "type": "plain_text", "text": "Upcoming Renewals (60-90 days)" }
          },
          {
            "type": "section",
            "text": {
              "type": "mrkdwn",
              "text": "{{steps.find-upcoming-renewals.output.data.length}} renewals coming up:\n\n{{#each steps.find-upcoming-renewals.output.data}}• {{this.customer.name}} - ${{this.items.data.[0].price.unit_amount | divided_by: 100}}/mo - Renews {{this.current_period_end | date: '%B %d'}}\n{{/each}}"
            }
          }
        ]
      }
    }
  ]
}

Churn Prevention

Trigger: Health score drops below threshold Actions: Create urgent task, notify manager, send check-in email

Automatically intervene when customer health declines.

{
  "name": "Churn Prevention",
  "trigger": {
    "type": "webhook",
    "provider": "hubspot",
    "events": ["contact.propertyChange"],
    "filter": {
      "propertyName": { "$eq": "health_score" }
    }
  },
  "steps": [
    {
      "id": "get-contact",
      "type": "action",
      "config": {
        "connector": "hubspot",
        "action": "getContact",
        "contactId": "{{input.objectId}}"
      }
    },
    {
      "id": "check-threshold",
      "type": "condition",
      "config": {
        "if": "{{steps.get-contact.output.properties.health_score < 40}}",
        "then": "trigger-intervention",
        "else": "end"
      }
    },
    {
      "id": "trigger-intervention",
      "type": "slack",
      "config": {
        "action": "sendMessage",
        "channel": "#cs-urgent",
        "blocks": [
          {
            "type": "header",
            "text": { "type": "plain_text", "text": "Churn Risk Alert" }
          },
          {
            "type": "section",
            "fields": [
              { "type": "mrkdwn", "text": "*Customer:*\n{{steps.get-contact.output.properties.firstname}} {{steps.get-contact.output.properties.lastname}}" },
              { "type": "mrkdwn", "text": "*Company:*\n{{steps.get-contact.output.properties.company}}" },
              { "type": "mrkdwn", "text": "*Health Score:*\n{{steps.get-contact.output.properties.health_score}}" },
              { "type": "mrkdwn", "text": "*MRR:*\n${{steps.get-contact.output.properties.mrr}}" }
            ]
          },
          {
            "type": "context",
            "elements": [
              { "type": "mrkdwn", "text": "Last login: {{steps.get-contact.output.properties.last_login_date}} | Open tickets: {{steps.get-contact.output.properties.open_tickets}}" }
            ]
          },
          {
            "type": "actions",
            "elements": [
              {
                "type": "button",
                "text": { "type": "plain_text", "text": "View Customer" },
                "style": "primary",
                "url": "https://app.hubspot.com/contacts/PORTAL/contact/{{input.objectId}}"
              },
              {
                "type": "button",
                "text": { "type": "plain_text", "text": "Schedule Call" },
                "url": "https://meetings.hubspot.com/csm-calendar"
              }
            ]
          }
        ]
      }
    },
    {
      "id": "send-checkin-email",
      "type": "email",
      "config": {
        "action": "send",
        "provider": "gmail",
        "to": "{{steps.get-contact.output.properties.email}}",
        "from": "success@company.com",
        "subject": "How can we help?",
        "body": {
          "html": "<p>Hi {{steps.get-contact.output.properties.firstname}},</p><p>I noticed it's been a while since we connected. I wanted to check in and see how things are going with Company.</p><p>Are there any challenges I can help with? I'd love to schedule a quick call to make sure you're getting the most out of your subscription.</p><p><a href='https://meetings.hubspot.com/csm-calendar'>Book a time that works for you</a></p><p>Looking forward to connecting!</p>"
        }
      }
    },
    {
      "id": "update-status",
      "type": "action",
      "config": {
        "connector": "hubspot",
        "action": "updateContact",
        "contactId": "{{input.objectId}}",
        "properties": {
          "customer_status": "At Risk",
          "churn_intervention_date": "{{now | date: '%Y-%m-%d'}}"
        }
      }
    }
  ]
}

Benefits:

  • Immediate intervention on health drops
  • CS team notified with context
  • Automated customer outreach
  • Full tracking of intervention

NPS Survey Automation

Trigger: 30 days after subscription start Actions: Send NPS survey, collect response, update customer record

Automatically collect NPS feedback at the right time.

{
  "name": "NPS Survey",
  "trigger": {
    "type": "schedule",
    "cron": "0 10 * * *"
  },
  "steps": [
    {
      "id": "find-eligible-customers",
      "type": "action",
      "config": {
        "connector": "hubspot",
        "action": "searchContacts",
        "filter": {
          "lifecyclestage": { "$eq": "customer" },
          "subscription_start_date": {
            "$gte": "{{now | dateAdd: -31, 'days' | date: '%Y-%m-%d'}}",
            "$lte": "{{now | dateAdd: -29, 'days' | date: '%Y-%m-%d'}}"
          },
          "nps_sent_date": { "$not_exists": true }
        }
      }
    },
    {
      "id": "send-nps-surveys",
      "type": "loop",
      "config": {
        "items": "{{steps.find-eligible-customers.output.results}}",
        "step": {
          "type": "email",
          "config": {
            "action": "send",
            "provider": "sendgrid",
            "to": "{{item.properties.email}}",
            "from": "feedback@company.com",
            "subject": "How likely are you to recommend Company?",
            "body": {
              "html": "<p>Hi {{item.properties.firstname}},</p><p>You've been using Company for about a month now. We'd love your feedback!</p><p><strong>How likely are you to recommend Company to a friend or colleague?</strong></p><p><a href='https://survey.company.com/nps?score=10&contact={{item.id}}'>10 - Extremely likely</a> | <a href='https://survey.company.com/nps?score=9&contact={{item.id}}'>9</a> | <a href='https://survey.company.com/nps?score=8&contact={{item.id}}'>8</a> | <a href='https://survey.company.com/nps?score=7&contact={{item.id}}'>7</a> | <a href='https://survey.company.com/nps?score=6&contact={{item.id}}'>6</a> | <a href='https://survey.company.com/nps?score=5&contact={{item.id}}'>5</a> | <a href='https://survey.company.com/nps?score=4&contact={{item.id}}'>4</a> | <a href='https://survey.company.com/nps?score=3&contact={{item.id}}'>3</a> | <a href='https://survey.company.com/nps?score=2&contact={{item.id}}'>2</a> | <a href='https://survey.company.com/nps?score=1&contact={{item.id}}'>1</a> | <a href='https://survey.company.com/nps?score=0&contact={{item.id}}'>0 - Not at all likely</a></p><p>Thank you for your feedback!</p>"
            }
          }
        }
      }
    },
    {
      "id": "update-sent-dates",
      "type": "loop",
      "config": {
        "items": "{{steps.find-eligible-customers.output.results}}",
        "step": {
          "type": "action",
          "config": {
            "connector": "hubspot",
            "action": "updateContact",
            "contactId": "{{item.id}}",
            "properties": {
              "nps_sent_date": "{{now | date: '%Y-%m-%d'}}"
            }
          }
        }
      }
    },
    {
      "id": "notify-cs",
      "type": "slack",
      "config": {
        "action": "sendMessage",
        "channel": "#cs-feedback",
        "text": "NPS surveys sent to {{steps.find-eligible-customers.output.results.length}} customers today."
      }
    }
  ]
}

Expansion Opportunity Detection

Trigger: Usage exceeds plan limits Actions: Create upsell opportunity, notify AE, send upgrade email

Automatically identify and act on expansion opportunities.

{
  "name": "Expansion Opportunity",
  "trigger": {
    "type": "webhook",
    "provider": "custom",
    "events": ["usage.threshold_exceeded"]
  },
  "steps": [
    {
      "id": "get-customer",
      "type": "action",
      "config": {
        "connector": "hubspot",
        "action": "getContact",
        "email": "{{input.customer_email}}"
      }
    },
    {
      "id": "create-upsell-deal",
      "type": "action",
      "config": {
        "connector": "hubspot",
        "action": "createDeal",
        "properties": {
          "dealname": "{{steps.get-customer.output.properties.company}} - Upgrade",
          "dealstage": "expansion_identified",
          "deal_type": "expansion",
          "amount": "{{input.upgrade_value}}",
          "notes": "Customer exceeded {{input.metric_name}}: {{input.current_usage}} / {{input.limit}}"
        },
        "associations": [{
          "to": "{{steps.get-customer.output.id}}",
          "type": "contact"
        }]
      }
    },
    {
      "id": "notify-ae",
      "type": "slack",
      "config": {
        "action": "sendMessage",
        "channel": "#expansion-opps",
        "blocks": [
          {
            "type": "header",
            "text": { "type": "plain_text", "text": "Expansion Opportunity" }
          },
          {
            "type": "section",
            "fields": [
              { "type": "mrkdwn", "text": "*Customer:*\n{{steps.get-customer.output.properties.company}}" },
              { "type": "mrkdwn", "text": "*Current Plan:*\n{{steps.get-customer.output.properties.subscription_plan}}" },
              { "type": "mrkdwn", "text": "*Metric:*\n{{input.metric_name}}" },
              { "type": "mrkdwn", "text": "*Usage:*\n{{input.current_usage}} / {{input.limit}} ({{input.usage_pct}}%)" }
            ]
          },
          {
            "type": "actions",
            "elements": [
              {
                "type": "button",
                "text": { "type": "plain_text", "text": "View Deal" },
                "style": "primary",
                "url": "https://app.hubspot.com/contacts/PORTAL/deal/{{steps.create-upsell-deal.output.id}}"
              }
            ]
          }
        ]
      }
    },
    {
      "id": "send-upgrade-email",
      "type": "email",
      "config": {
        "action": "send",
        "provider": "gmail",
        "to": "{{input.customer_email}}",
        "from": "success@company.com",
        "subject": "You're outgrowing your plan!",
        "body": {
          "html": "<p>Hi {{steps.get-customer.output.properties.firstname}},</p><p>Great news - you've been getting a lot of value from Company! You're currently using {{input.usage_pct}}% of your {{input.metric_name}} limit.</p><p>To ensure uninterrupted service, you might want to consider upgrading to our {{input.recommended_plan}} plan.</p><p><a href='https://app.company.com/upgrade'>View upgrade options</a></p><p>Questions? Reply to this email or book a call with your success manager.</p>"
        }
      }
    }
  ]
}

Key Integrations

IntegrationUse Cases
StripeSubscriptions, billing, customer data
HubSpotCRM, contacts, deals, health tracking
SalesforceCRM, accounts, opportunities
QuickBooksCustomer records, invoicing
SlackTeam notifications, alerts
EmailCustomer communication, surveys

Best Practices

1. Health Score Components

Build composite health scores from multiple signals:

{
  "healthScore": "{{(loginScore * 0.3) + (usageScore * 0.4) + (supportScore * 0.3)}}"
}

2. Tiered Interventions

Different actions for different severity levels:

{
  "id": "route-by-severity",
  "type": "condition",
  "config": {
    "if": "{{healthScore < 30}}",
    "then": "urgent-intervention",
    "else": {
      "if": "{{healthScore < 50}}",
      "then": "standard-intervention",
      "else": "monitor"
    }
  }
}

3. Timing Matters

Send communications at optimal times:

{
  "trigger": {
    "type": "schedule",
    "cron": "0 10 * * 2"
  }
}

4. Track Everything

Always log actions taken:

{
  "id": "log-intervention",
  "type": "action",
  "config": {
    "connector": "hubspot",
    "action": "updateContact",
    "properties": {
      "last_intervention_date": "{{now}}",
      "intervention_type": "churn_prevention"
    }
  }
}

Getting Started

  1. Customer Onboarding Tutorial - Start with automated onboarding
  2. Stripe Integration Guide - Set up subscription tracking
  3. HubSpot Integration Guide - Connect your CRM
  4. Email Block Reference - Learn email automation