Get Started
Screenshot of n8n workflow
FREE TEMPLATE
Automate HeyGen Video Creation
7
Views
0
Downloads
10
Nodes
Download Template
Free
Preview Template
Utility Rating
6 / 10
Business Function
Marketing
Automation Orchestrator
n8n
Integrations
HeyGen
Trigger Type
Manual trigger
Approx setup time ≈ 25 min
Need help setting up this template?
Ask in our free Futurise community
About
Community
Courses
Events
Members
Templates

How to Automate HeyGen Video Creation?

Leon Petrou
FREE TEMPLATE
Automate HeyGen Video Creation
7
Views
0
Downloads
10
Nodes
Download Template
Free
Preview Template
Utility Rating
6 / 10
Business Function
Marketing
Automation Orchestrator
n8n
Integrations
HeyGen
Trigger Type
Manual trigger
Approximate setup time ≈ 25 minutes
Need help setting up this template?
Ask in our free Futurise community

Description

Create on demand AI videos from simple text and receive a ready to share link when rendering finishes. Great for marketing and sales teams that need quick spokesperson clips for product updates, ads, and outreach without editing software.

The run starts manually. A config step stores the avatar id, voice id, and the script. An HTTP request sends these details to the video generate endpoint. The flow waits ten seconds, then checks the status with the video id. A decision step looks for a completed state. If the video is still processing, the loop waits and checks again. When done, the final step outputs the video_url so you can copy it or pass it to another system.

You need a HeyGen account, API credits, and an API key. Add an HTTP Header credential in n8n named X Api Key and apply it to both HTTP nodes. Paste your avatar and voice ids plus the script in the config node. Expect production time to drop from hours to minutes and scale the number of videos you can ship each week. Adjust the wait time if your queue is busy or if you hit rate limits.

Copy link

Tools Required

n8n
Sign up
$24 / mo or $20 / mo billed annually to use n8n in the cloud. However, the local or self-hosted n8n Community Edition is free.
HeyGen
Sign up
Free: $0 / mo, 10 API credits / mo; watermark included

What this workflow does?

  • Manual start for controlled test runs and demos
  • Config step stores avatar_id, voice_id, and text in one place
  • HTTP POST creates a new video using the HeyGen API
  • Wait node pauses for 10 seconds to avoid tight polling
  • HTTP GET checks video status using the returned video_id
  • If node loops until the status is completed
  • Final Set step outputs data.video_url for easy sharing
  • Single API key header credential reused across both calls

What are the benefits?

  • Reduce manual production from 2 hours to 5 minutes per video
  • Automate 90% of status checks with a safe polling loop
  • Handle up to 10 times more video requests without extra staff
  • Improve handoff accuracy by extracting the exact video_url
  • Run everything in n8n to avoid switching between tools

How to set this up?

  1. Import the template into n8n: Create a new workflow in n8n > Click the three dots menu > Select 'Import from File' > Choose the downloaded JSON file.
  2. You'll need accounts with HeyGen. See the Tools Required section above for links to create accounts with these services.
  3. In your HeyGen account, create an API key and make sure you have API credits available.
  4. In the n8n credentials manager, create an HTTP Header credential. Set the header name to X-Api-Key and the value to your HeyGen API key. Give the credential a clear name.
  5. Open the Create Video HTTP node and select your HeyGen header credential. Open the Get Video Status HTTP node and select the same credential so both calls use the same key.
  6. Open the Config Set node and fill avatar_id, voice_id, and text. Use valid IDs from your HeyGen dashboard and a short script for the first test.
  7. Optionally adjust the Wait node amount to 10 to 30 seconds. Longer waits reduce API calls if your videos take more time to render.
  8. Click Execute workflow and start a test run. In the Create Video output, confirm that data.video_id appears.
  9. Let the loop run. When the If node detects completed, check the Output step for data.video_url. Open the link to confirm the video plays.
  10. Troubleshooting: If you get unauthorized, check the X Api Key header and key value. If status never completes, increase the wait time. If avatar or voice IDs are invalid, replace them with valid IDs from HeyGen. Make sure both HTTP nodes use the same HeyGen credential.

Need help or want to customize this?

Similar Templates

See More Templates

These templates were sourced from publicly available materials across the web, including n8n’s official website, YouTube and public GitHub repositories. We have consolidated and categorized them for easy search and filtering, and supplemented them with links to integrations, step-by-step setup instructions, and personalized support in the Futurise community. Content in this library is provided for education, evaluation and internal use. Users are responsible for checking and complying with the license terms with the author of the templates before commercial use or redistribution.Where an original author was identified, attribution has been provided. Some templates did not include author information. If you know who created this template, please let us know so we can add the appropriate credit and reference link. If you are the author and would like this template removed from the library, email us at info@futurise.com and we will remove it promptly.