n8n Masterclass IModule 8

8.2Client Onboarding Automation with n8n

25 min 13 code blocks Practice Lab Quiz (4Q)

Client Onboarding Automation with n8n

Signing a new automation client should feel like pressing a button, not spending a week setting things up. Every hour you spend on manual onboarding is an hour you're not earning. This lesson teaches you to automate the client onboarding process itself — from contract signed to workflows running in under 2 hours.

The Onboarding Problem

code
MANUAL ONBOARDING (without automation):

Day 1: Client signs contract
Day 2: You ask for credentials (Shopify, email, etc.)
Day 3-4: Client slowly sends credentials over WhatsApp messages
Day 5: You set up Google Sheets, configure workflows
Day 6: You test everything
Day 7: You realize you forgot to ask for their WhatsApp Business number
Day 8-10: Back and forth on missing info
Day 11: Finally live

Total: 8-11 days, 6-8 hours of your time

AUTOMATED ONBOARDING:

Hour 0: Client fills out onboarding form
Hour 1: n8n creates all infrastructure automatically
Hour 2: You do a final QC check, flip the switch
Total: 2 hours, 30 minutes of your time

The Automated Onboarding Pipeline

code
┌──────────────────────────────────────────────────┐
│           CLIENT ONBOARDING PIPELINE              │
│                                                   │
│  1. INTAKE FORM   → Client submits all details    │
│  2. VALIDATION    → n8n checks all fields         │
│  3. PROVISIONING  → Create sheets, configs, creds │
│  4. WORKFLOW SETUP→ Clone templates, configure     │
│  5. TESTING       → Auto-run test workflows       │
│  6. NOTIFICATION  → Alert you + welcome client    │
│  7. HANDOFF       → Client receives dashboard     │
│                                                   │
└──────────────────────────────────────────────────┘

Step 1: The Client Intake Form

Typeform / Google Forms Questionnaire

code
CLIENT ONBOARDING FORM

Section 1: Business Details
- Company name: ___
- Contact person: ___
- Email: ___
- WhatsApp: +92___
- Website: ___
- City: [Karachi / Lahore / Islamabad / Other]

Section 2: Services Selected
☐ Order sync (Shopify/WooCommerce)
☐ Lead nurture (email follow-ups)
☐ Social media posting
☐ Inventory alerts
☐ Daily/weekly reports
☐ Customer WhatsApp notifications
☐ Custom automation: ___

Section 3: Platform Credentials
(Only show if relevant service selected)

If Shopify:
- Shopify store URL: ___
- Shopify Admin API token: ___

If WooCommerce:
- Website URL: ___
- Consumer Key: ___
- Consumer Secret: ___

If Email:
- SMTP server: ___
- Email: ___
- App password: ___

Section 4: Preferences
- Reporting frequency: [Daily / Weekly / Monthly]
- Alert channel: [Email / WhatsApp / Slack / All]
- Timezone: [Asia/Karachi (default)]
- Preferred language: [English / Urdu / Both]

Section 5: Agreement
☐ I agree to the service terms
- Signature: ___
- Date: ___

Form-to-Webhook Connection

code
Typeform → Settings → Webhooks → Add:
URL: https://your-n8n.com/webhook/client-onboarding
Method: POST

Google Forms → Use n8n's Google Forms Trigger node:
[Google Forms Trigger: On form submission]

Step 2: Validation Workflow

code
[Webhook/Form Trigger: New onboarding submission]
    │
    ▼
[Function Node: Validate all fields]

    const errors = [];
    const data = $json;

    // Required fields
    if (!data.company_name) errors.push("Missing company name");
    if (!data.email) errors.push("Missing email");
    if (!data.whatsapp || !data.whatsapp.startsWith("+92"))
      errors.push("Invalid WhatsApp (must start with +92)");

    // Conditional validation
    if (data.services.includes("order_sync")) {
      if (!data.shopify_url) errors.push("Shopify URL required for order sync");
      if (!data.shopify_token) errors.push("Shopify token required");
    }

    // Generate client_id
    const client_id = data.company_name
      .toLowerCase()
      .replace(/[^a-z0-9]/g, '')
      .substring(0, 10);

    return [{
      json: {
        ...data,
        client_id,
        valid: errors.length === 0,
        errors
      }
    }];
    │
    ▼
[IF: Valid?]
    │
    ├── YES → Continue to provisioning
    │
    └── NO → [Gmail: Send "missing info" email to client]
              Subject: "Action needed: Complete your onboarding"
              Body: "We need the following before we can proceed:
                     {{errors.join('\n')}}"

Step 3: Automated Provisioning

Create Client Google Sheet

code
[Google Sheets: Create new spreadsheet]
    Title: "[CLIENT_ID] — Automation Dashboard"
    │
    ▼
[Google Sheets: Create tabs]
    Tabs:
    - "Orders" (columns: order_id, customer, amount, status, date)
    - "Leads" (columns: name, email, phone, source, status, date)
    - "Alerts" (columns: type, message, timestamp, resolved)
    - "Reports" (columns: date, metric, value)
    │
    ▼
[Google Sheets: Share with client email]
    Email: {{$json.email}}
    Permission: Viewer (they can see but not edit automation data)

Add to Client Config

code
[Google Sheets: Append to "Client Config" sheet]
    client_id: {{$json.client_id}}
    client_name: {{$json.company_name}}
    email: {{$json.email}}
    whatsapp: {{$json.whatsapp}}
    sheet_id: {{$json.new_sheet_id}}  ← from the created sheet
    shopify_url: {{$json.shopify_url}}
    shopify_token: {{$json.shopify_token}}
    timezone: {{$json.timezone}}
    active: true
    onboarded_date: {{$now.toISO()}}
    │
    ▼
[Google Sheets: Append to "Services" sheet]
    One row per selected service:
    client_id | service | enabled | schedule | config_json

Step 4: Workflow Setup

Clone and Configure Template Workflows

For Pattern 2 architecture (previous lesson), new clients don't need new workflows — they just need a config row. But for Pattern 1 (separate workflows per client):

code
[n8n API: Duplicate workflow]
    Method: POST
    URL: http://localhost:5678/api/v1/workflows
    Body: {
      "name": "[{{client_id}}] Order Sync",
      "nodes": [... template nodes with client_id injected ...],
      "active": false  ← don't activate yet
    }
    │
    ▼
[Repeat for each selected service]
    │
    ▼
[n8n API: Create credentials]
    Store client's Shopify token, email creds, etc.
    as named credentials: "[CLIENT_ID] - Shopify - API"

For Pattern 2: Just Enable Services

code
[Google Sheets: Update "Services" sheet]
    Set enabled = true for each service the client purchased
    │
    ▼
[Done — template workflows will pick up the new client
 on their next scheduled run]

Step 5: Automated Testing

code
[After provisioning]
    │
    ▼
[Test: Shopify API connection]
    HTTP Request: GET {{shopify_url}}/admin/api/2024-04/shop.json
    Headers: X-Shopify-Access-Token: {{shopify_token}}
    │
    ├── 200 OK → ✅ Shopify connected
    └── Error → ❌ Log: "Shopify token invalid"
    │
    ▼
[Test: Google Sheets access]
    Google Sheets: Read first row of client's sheet
    │
    ├── Success → ✅ Sheets connected
    └── Error → ❌ Log: "Sheet access failed"
    │
    ▼
[Test: WhatsApp (WATI)]
    Send test message: "Your AutomatePK setup is being configured!"
    │
    ├── Delivered → ✅ WhatsApp connected
    └── Error → ❌ Log: "WhatsApp send failed"
    │
    ▼
[Compile test results]
    All passed? → Ready for activation
    Any failed? → Flag for manual review

Step 6: Notifications

Internal Alert (To You)

code
[Slack / Email: New client onboarded]

🎉 *New Client Onboarded*

*Company:* {{$json.company_name}}
*Contact:* {{$json.contact_person}} ({{$json.email}})
*Services:* {{$json.services.join(', ')}}
*Sheet:* {{$json.sheet_url}}

*Test Results:*
✅ Shopify: Connected
✅ Google Sheets: Created & shared
✅ WhatsApp: Test message delivered
❌ Email SMTP: Failed — needs manual check

*Action:* Review and activate workflows
*Link:* {{n8n_dashboard_url}}

Client Welcome Email

code
[Gmail: Welcome email]

Subject: Welcome to AutomatePK — Your Automation is Live! 🚀

Hi {{$json.contact_person}},

Your automation setup is complete. Here's what's now running:

{{#each services}}
✅ {{this.name}} — {{this.description}}
   Schedule: {{this.schedule}}
{{/each}}

Your Dashboard:
{{$json.sheet_url}}

What to Expect:
- You'll receive [daily/weekly] reports via [email/WhatsApp]
- If anything needs attention, you'll get an instant alert
- I'll check in next Monday to review the first week's performance

Questions? Reply to this email or WhatsApp me at +92-XXX-XXXXXXX.

Best regards,
[Your Name]
AutomatePK

The Complete Onboarding Workflow

code
[Form Trigger: Client submission]
    │
    ▼
[Validate fields] → Missing? → [Email: Request missing info] → STOP
    │
    ▼ (All valid)
[Create Google Sheet + tabs]
    │
    ▼
[Add to Client Config sheet]
    │
    ▼
[Add to Services sheet]
    │
    ▼
[Test all connections]
    │
    ▼
[Compile results]
    │
    ├── All passed → [Activate workflows]
    │                │
    │                ▼
    │                [Send welcome email to client]
    │                [Send Slack alert to you]
    │
    └── Some failed → [Send partial setup alert to you]
                      [Email client: "Almost ready, need X fixed"]
Practice Lab

Practice Lab

Task 1: Build the Intake Form Create a Google Form or Typeform with all the fields listed above. Connect it to an n8n webhook. Test that the form submission triggers your workflow and all data arrives correctly.

Task 2: Build the Provisioning Workflow Create a workflow that takes form data and automatically creates a Google Sheet with the correct tabs, adds the client to a config sheet, and sends you an alert. Test with 2 fictional clients.

Task 3: Build the Testing Module Add automated connection testing to your onboarding workflow. Test at least 2 connections (Google Sheets + one API). Generate a pass/fail report and email it to yourself.

Pakistan Case Study

Meet Haris — runs "SmartOps" automation agency from Islamabad, serving 12 clients.

His onboarding before automation:

  • Average onboarding time: 8 days
  • His time per onboarding: 6 hours
  • Credentials lost in WhatsApp threads: happened twice
  • Client experience: "It took a while to get started"

His automated onboarding system:

Built the complete pipeline in one weekend (14 hours):

  1. Typeform intake with conditional logic
  2. Validation workflow (catches 80% of issues before he sees them)
  3. Auto-provisioning (Sheet creation, config update)
  4. Connection testing (Shopify, email, WhatsApp, Sheets)
  5. Welcome email with dashboard link

Results:

  • Onboarding time: 8 days → 2 hours (form to live)
  • His time per onboarding: 6 hours → 30 minutes (just final QC)
  • Credential management: all in config sheet, not scattered in WhatsApp
  • Client experience: "It felt like working with a big company"
  • Onboarding 3 clients in one week: was impossible before, now easy

Revenue impact:

  • Could now take on clients faster (no bottleneck at onboarding)
  • Grew from 8 to 12 clients in 2 months (was stuck at 8 for 4 months before)
  • Started charging PKR 10,000 "setup fee" (clients gladly pay — the experience is professional)
  • Setup fee revenue: PKR 120,000/year (12 clients × PKR 10,000)
  • Time saved: 5.5 hours × 12 clients = 66 hours/year = 8.25 workdays back

His pitch: "Your automation goes live within 24 hours of signing. Fill out this form, and I handle the rest."

Key Takeaways

  • Automated onboarding turns an 8-day process into a 2-hour process
  • The pipeline: intake form → validation → provisioning → testing → notification
  • Intake forms should be comprehensive — ask for everything upfront to avoid back-and-forth
  • Validation catches missing info before you waste time on manual review
  • Auto-provisioning creates sheets, configs, and credentials without your involvement
  • Automated connection testing verifies everything works before going live
  • Welcome emails make the client experience feel premium and professional
  • Charge a setup fee — the professional onboarding experience justifies it
  • With automated onboarding, your growth bottleneck shifts from setup to sales

Next lesson: Selling automation services — pricing packages, proposals, and building a profitable automation business.

Lesson Summary

Includes hands-on practice lab13 runnable code examples4-question knowledge check below

Quiz: Client Onboarding Automation with n8n

4 questions to test your understanding. Score 60% or higher to pass.