Salesforce Integration

Salesforce Opportunity stage. Personalized video. Delivered.

Salesforce's automation complexity is the build challenge - not the HeyGen API. We know both sides. Flow or Apex trigger, video renders, link writes back to the record.

Primary trigger

Opportunity stage

Trigger method

Flow or Apex

Required edition

Enterprise+

How we test

Sandbox-first

30 minutes. You leave with a workflow map, a cost projection, and an integration blueprint - whether or not we build anything.

Scope

What we build.

Salesforce trigger - Flow or Apex

Flow with a webhook callout action for zero-code-deployment builds your Salesforce admin can manage. Apex trigger with Platform Events for complex multi-condition logic, batch handling, or when Flow governor limits are a constraint. We recommend based on your org configuration, not a default.

Outbound REST callout to webhook handler

Our webhook handler receives the trigger payload from Salesforce, verifies it, and queues the render job. Signature verification, idempotency guard, and immediate 200 ACK so Salesforce never times out waiting on a downstream service.

Contact field extraction and payload validation

Name, company, Opportunity name, custom fields - mapped and validated before the payload reaches the HeyGen API. A missing merge field produces an alert, not a video addressed to a blank. Every field mapping is documented in the runbook.

HeyGen render queue

Video render requests are queued, not fired inline. Rate-limit handling, exponential backoff on transient failures, and a dead-letter queue for renders that cannot self-heal. Your Slack gets the error with the Opportunity ID attached - not silence.

Video URL write-back to CRM record

After the render completes, the video link is written back to the Opportunity, Lead, or Contact record via Salesforce REST API. Your reps see the generated link directly on the record without leaving Salesforce.

Failure alerting

Every failure surface has an alert path: Apex callout exceptions, Flow fault paths, HeyGen API errors, and webhook delivery failures. Alerts include the Salesforce record ID, error type, and timestamp so issues are resolved the same day instead of discovered at the QBR.

Every build ships with: architecture diagram, deployment guide, credential inventory, runbook, and a 60-minute recorded handover session. You own the code. No lock-in.
Process

How it works.

01

Opportunity stage triggers the webhook

A deal reaches your target stage in Salesforce - Proposal Sent, Demo Completed, Renewal Window, your pick. A Salesforce Flow or Apex trigger fires an outbound callout to our webhook handler within seconds. No CSV exports, no manual kickoff.

02

HeyGen renders the personalized video

The webhook handler validates the payload, maps CRM fields to video merge variables, and calls the HeyGen API. The contact's name, company, and Opportunity details populate the template. Typical render time: 2-4 minutes. Failures retry automatically with backoff.

03

Video URL writes back to the Salesforce record

After render completes, the video link is written to the Opportunity (or Lead/Contact) via Salesforce REST API. Your rep opens the record, sees the video link, and sends it. Generation status and delivery status both log to the record automatically.

Prerequisites

What you need on your side.

Salesforce Enterprise or Developer sandbox

Enterprise edition or above supports outbound REST callouts from Flow. A Developer Edition sandbox is sufficient for building and testing - we work there first and deploy to production at the final step with your team.

HeyGen with API access

Creator plan or above for API access. We confirm your plan is API-enabled during the audit before you commit to anything. If your current plan does not support the API, the audit tells you exactly which tier you need and what it costs.

Target trigger object and stage

Which object fires the trigger - Opportunity, Lead, or Contact - and which stage or field change should kick off the render. You decide this during the kickoff. We document the trigger logic in the runbook so your admin can adjust it later without us.

A Salesforce admin who can deploy Flow or Apex

Flow builds require an admin to activate the flow in your org. Apex builds require a developer with deployment rights. We provide the complete code and deployment guide - your team does the org-side deploy with us on the call.

Working Pipeline Guarantee

Written acceptance criteria before we build. The pipeline passes those tests or we keep working at no additional cost. If we cannot meet the criteria, the final milestone is waived and you keep everything built, plus all documentation.

FAQ

Questions

Do you use Apex or Flow for the Salesforce trigger?

Both options exist. For most builds we use Salesforce Flow with a webhook callout action - it requires no code deployment and can be managed by your Salesforce admin. For complex trigger logic (multiple conditions, batch handling), we use an Apex trigger with a Platform Event. We recommend based on your org's setup.

Which Salesforce edition do I need?

Enterprise or above for outbound REST callouts from Flow. Developer Edition works for testing. Essentials and Professional editions have limited automation and are typically not sufficient.

Can we write the video link back to a custom Opportunity field?

Yes. We create a custom Text field on the Opportunity (or Lead/Contact, depending on your trigger) and write the video URL back via the Salesforce REST API after the render completes.

Does Kastiv need access to our production Salesforce org?

No. We build and test against a Salesforce Developer Edition sandbox you provide. Credentials to production are provided only at the final deployment step, with your team present.

Salesforce already has the data. We trigger video from it.

30-minute audit, free. Integration blueprint included.

Get your Pipeline Audit

Fixed price. Working Pipeline Guarantee on every build.