πŸ’¬ Turn webinar recordings into Salesforce follow-up emails with WayinVideo and GPT-4o-mini

⚑ 19 views Β· πŸ’¬ Lead Nurturing & AI Sales Agents

Description

Description

Submit your webinar recording URL along with the webinar title, host name, company name, date, and CTA link and the workflow automatically handles every follow-up. WayinVideo summarizes the webinar and extracts numbered highlights, then GPT-4o-mini writes a personalized 150–200 word email per registered Salesforce lead β€” addressing them by first name, referencing their role and company, and citing 2–3 specific things covered in the webinar. Gmail sends each email, Salesforce logs a completed Task activity on each lead record, and Google Sheets logs every send with the Salesforce Task ID. Built for marketing teams, sales teams, and agencies who want to follow up with every registered lead immediately after a webinar ends β€” without writing a single email manually.


What This Workflow Does


Setup Requirements

Tools Needed

Credentials Required

> ⚠️ WayinVideo API key appears in 2 steps β€” replace YOUR_WAYINVIDEO_API_KEY in both 2. WayinVideo β€” Submit Summarization and 4. WayinVideo β€” Get Summary Results. Missing either one will cause the workflow to fail.

Estimated Setup Time: 30–40 minutes


Step-by-Step Setup

  1. Import the workflow β€” Open n8n β†’ Workflows β†’ Import from JSON β†’ paste the workflow JSON β†’ click Import

  2. Get your WayinVideo API key β€” Log in to your WayinVideo account β†’ go to Account Settings β†’ copy your API key

  3. Add your WayinVideo API key to node 2 β€” Open node 2. WayinVideo β€” Submit Summarization β†’ find the Authorization header value Bearer YOUR_WAYINVIDEO_API_KEY β†’ replace YOUR_WAYINVIDEO_API_KEY with your actual key

  4. Add your WayinVideo API key to node 4 β€” Open node 4. WayinVideo β€” Get Summary Results β†’ find the same Authorization header β†’ replace YOUR_WAYINVIDEO_API_KEY with the same key

  5. Connect OpenAI β€” Open node 10. OpenAI β€” GPT-4o-mini Model β†’ click the credential dropdown β†’ add your OpenAI API key β†’ test the connection

  6. Verify your Salesforce custom field β€” In your Salesforce org, confirm the Lead object has a field with the API name Webinar_Name__c that is populated at registration time. If your field has a different API name, open node 8. Salesforce β€” Query Registered Leads and update the SOQL query to use your actual field name.

  7. Connect Salesforce for lead query β€” Open node 8. Salesforce β€” Query Registered Leads β†’ click the credential dropdown β†’ add Salesforce OAuth2 β†’ complete the authorization flow in your browser

  8. Connect Salesforce for task logging β€” Open node 13. Salesforce β€” Log Email as Activity β†’ click the credential dropdown β†’ select the same Salesforce OAuth2 credential

  9. Connect Gmail β€” Open node 12. Gmail β€” Send Follow-Up Email β†’ click the credential dropdown β†’ add Gmail OAuth2 β†’ complete the Google authorization flow

  10. Create your Google Sheet tab β€” Open your Google Sheet β†’ add a tab named exactly Follow-up Log β†’ add these 10 column headers in row 1: Webinar Title, Lead Email, Lead Name, Lead Company, Email Subject, Personalized Intro, Salesforce Lead ID, Salesforce Task ID, Sent Status, Sent On

  11. Get your Google Sheet ID β€” Open your Google Sheet in a browser β†’ copy the string between /d/ and /edit in the URL β€” this is your Sheet ID

  12. Connect Google Sheets β€” Open node 14. Google Sheets β€” Log Follow-Up β†’ click the document field β†’ replace YOUR_GOOGLE_SHEET_ID by selecting your spreadsheet or entering the Sheet ID manually β†’ click the credential dropdown β†’ add Google Sheets OAuth2 β†’ authorize access

  13. Activate the workflow β€” Toggle the workflow to Active β†’ copy the Form URL from node 1. Form β€” Webinar URL + Details β†’ open it in a browser to submit your first webinar


How It Works (Step by Step)

Step 1 β€” Form: Webinar URL + Details You open the form URL and fill in six fields: the webinar recording URL, the webinar title (which must match the value in your Salesforce Webinar_Name__c field exactly), the host or speaker name, the company or brand name, the webinar date, and the CTA link for the follow-up email. Submitting the form starts the entire pipeline.

Step 2 β€” HTTP: WayinVideo β€” Submit Summarization The webinar URL is sent to WayinVideo’s Summarization API. WayinVideo accepts the job and returns a task ID confirming the summarization has started.

Step 3 β€” Wait: 90 Seconds The workflow pauses 90 seconds before the first status check, giving WayinVideo time to process the recording.

Step 4 β€” HTTP: WayinVideo β€” Get Summary Results A GET request checks the summarization results endpoint using the task ID. It returns the current status and, once complete, the summary text, highlights array, and tags array.

Step 5 β€” IF: Summary Complete? This is the polling gate. If the status equals SUCCEEDED (YES path), the summary is ready and the workflow moves forward. If still processing (NO path), the workflow routes to 6. Wait β€” 30 Seconds Retry which pauses 30 seconds then loops back to step 4. This repeats until SUCCEEDED.

Step 6 β€” Wait: 30 Seconds Retry When the summary is not yet ready, the workflow waits 30 seconds then returns to step 4 for another check.

Step 7 β€” Code: Extract Summary Data The summary text, numbered highlights (formatted as 1. highlight, 2. highlight, etc.), and tags are extracted from the WayinVideo results. All six form inputs are also packaged here. Everything is assembled into one clean object that feeds both the Salesforce query and the GPT email prompt.

Step 8 β€” Salesforce: Query Registered Leads A SOQL query runs against your Salesforce org to fetch all leads where Webinar_Name__c matches the webinar title you entered in the form, with a limit of 500 leads. The results include each lead’s first name, last name, email, company, and job title. Each lead becomes one email to send.

Step 9 β€” AI Agent: Write Personalized Email GPT-4o-mini receives the full lead details (first name, last name, email, company, job title) alongside the webinar context (title, host name, company, date, CTA link, recording URL, full summary, and numbered highlights). It writes a 150–200 word email in three labeled sections: a subject line 45–55 characters long referencing the webinar topic, a 1–2 sentence personalized opening that references the lead’s role or company, and the full email body starting with β€œHi [FirstName]” β€” warm in tone, referencing 2–3 specific highlights, including the recording URL and CTA link, and ending with the host’s name as the signature.

Step 10 β€” OpenAI: GPT-4o-mini Model This is the language model powering the personalized email writing for each lead.

Step 11 β€” Code: Parse Email Output The three labeled sections β€” SUBJECT_LINE, PERSONALIZED_INTRO, and EMAIL_BODY β€” are extracted from the GPT output using regex. Lead details from step 8 and webinar details from step 7 are also packaged for the Gmail, Salesforce, and Sheets steps. If the subject line is not found, a fallback subject using the webinar title is used.

Step 12 β€” Gmail: Send Follow-Up Email The personalized email is sent to the lead’s email address using the full email body from GPT. The sender name is set to your company name from the form. Each lead receives their own individual email β€” not a broadcast.

Step 13 β€” Salesforce: Log Email as Activity A completed Task is created in Salesforce linked to the lead’s record using their Salesforce Lead ID as the WhoId. The Task is marked Completed with today’s date, Normal priority, and a description that includes the webinar title, email subject, and the lead’s email address. This means your CRM reflects the follow-up as done immediately.

Step 14 β€” Google Sheets: Log Follow-Up One row is appended to your Follow-up Log tab with all 10 columns: webinar title, lead email, lead full name, lead company, email subject, personalized intro, Salesforce Lead ID, Salesforce Task ID (returned by step 13), Sent Status set to Sent, and the current timestamp.

The final result is a personalized email sent to every registered lead, a completed CRM Task on every lead record, and a full send log in Google Sheets β€” all triggered by one form submission.


Key Features

βœ… Personalized per lead using their first name, title, and company β€” Every email addresses the lead by name and frames the webinar highlights around their specific role β€” not a mass blast βœ… Webinar highlights referenced in every email β€” GPT cites 2–3 numbered highlights from the actual webinar content β€” making each email feel relevant to what the lead attended βœ… Salesforce Task logged with WhoId association β€” Each completed Task is linked to the correct lead record via WhoId β€” your CRM shows the follow-up is done without any manual logging βœ… Recording URL included in every email β€” Every lead gets a link to rewatch the recording so they can engage further without needing a separate reminder email βœ… Up to 500 leads processed per run β€” The Salesforce SOQL query fetches up to 500 registered leads so even large webinars are covered in one form submission βœ… Sender name set to your company β€” Gmail sends each email with your company or brand name as the sender β€” not a generic n8n address βœ… Salesforce Task ID captured in Google Sheets β€” The sheet log includes the Task ID returned by Salesforce so you can cross-reference sends against CRM records at any time


Customisation Options

Add a retry limit to stop infinite polling β€” Before node 6. Wait β€” 30 Seconds Retry, add a Set step that increments a poll counter, then add a second IF check to stop after 15 polls and send a Gmail error notification to the form submitter instead of looping indefinitely.

Use a different Salesforce field to match leads β€” In node 8. Salesforce β€” Query Registered Leads, edit the SOQL query to use a different field if your org does not use Webinar_Name__c β€” for example Campaign_Name__c or a tag field β€” as long as it identifies which leads attended which webinar.

Add a Salesforce lead status update after sending β€” After node 13. Salesforce β€” Log Email as Activity, add a Salesforce Update step that sets the lead’s Status to β€œWebinar Follow-Up Sent” so your sales team can filter CRM views by follow-up status.

Add a Slack notification when all emails are sent β€” After the last lead row is processed, add a Slack step that posts the webinar title and total number of emails sent to a #marketing or #sales channel so your team knows the follow-up campaign is complete.

Change the email length β€” In the system prompt of node 9. AI Agent β€” Write Personalized Email, change the rule from 150-200 words to 100-150 words for shorter emails or 200-250 words for more detailed follow-ups depending on your audience preference.


Troubleshooting

WayinVideo returning an error on submission:

Salesforce query returning zero leads:

Gmail sending errors:

Salesforce Task not being created:

Google Sheets not logging rows:


Support

Need help setting this up or want a custom version built for your team or agency?

πŸ“§ Email:info@isawow.com 🌐 Website:https://isawow.com

πŸ”— Nodes Used

Google Sheets, HTTP Request, Salesforce, Gmail, AI Agent, OpenAI Chat Model

πŸ“₯ Import

Download workflow.json and import into n8n: Workflow menu β†’ Import from File

πŸ“– Importing guide Β· πŸ”‘ Credential setup