Heygen Integration for AI Agents

Securely connect your AI agents and chatbots (Claude, ChatGPT, Cursor, etc) with Heygen MCP or direct API to generate videos, automate editing, fetch video status, and manage assets through natural language.
Heygen Logo
Gradient Top
Gradient Middle
Gradient Bottom
divider

Supported Tools

Tools
Add new assetCreates a new asset in the heygen platform.
Add contact to personalized video projectThis endpoint allows you to add one or more contacts to a specific personalized video project in the heygen platform.
Retrieve audience video detailsRetrieves detailed information about the audience for personalized videos.
Fetch personalized video project detailRetrieves detailed information about a specific personalized video project in the heygen platform.
Post talking photo binary imageCreates a talking photo by processing an uploaded image file.
List streaming avatarsRetrieves a list of available avatars for streaming purposes in the heygen platform.
Create streaming token with expiryCreates a new streaming token for use with heygen's real-time avatar and voice chat services.
Post streaming ice candidatesThis endpoint is used to submit ice (interactive connectivity establishment) candidate information for a specific streaming session in the heygen platform.
Interrupt streaming sessionInterrupts an ongoing streaming session with an interactive avatar.
Retrieve streaming listRetrieves a list of active or available streaming sessions or content within the heygen platform.
Set streaming quality endpointInitiates a new streaming session with heygen, allowing users to start an avatar-based stream with specified quality settings.
Start streaming sessionInitiates a new streaming session for real-time communication in the heygen platform.
Stop streaming sessionThe streaming.
Post streaming task sessionThe streamingtask endpoint initiates a real-time speaking task for an ai-driven avatar within an active streaming session.
List avatars endpointRetrieves a list of available avatars from the heygen platform.
List talking photo entriesRetrieves a list of talking photos created using the heygen platform.
Delete videoThe video.
List videosRetrieves a list of videos associated with the user's account on the heygen platform.
Retrieve video statusRetrieves the current status of a video in the heygen platform.
List voice endpointsRetrieves a comprehensive list of all available voices in the heygen platform.
Add webhook endpointAdds a new webhook endpoint to receive real-time notifications for specified heygen events.
Delete webhook endpointDeletes a specific webhook endpoint from the heygen system.
List webhook endpointsRetrieves a list of all webhook endpoints configured for your heygen account.
List webhooksRetrieves a list of all webhooks configured for your heygen account.
Retrieve avatars collectionRetrieves a list of available avatars from the heygen platform.
Delete talking photo by idDeletes a specific talking photo from the heygen platform using its unique identifier.
Generate video template with variablesThis endpoint generates a customized video based on a pre-existing template using heygen's ai-driven platform.
Get template by idRetrieves a specific template from the heygen platform using its unique identifier.
Retrieve all templatesRetrieves a list of available avatar templates from the heygen platform.
Retrieve user remaining quotaRetrieves the current remaining quota for the authenticated user on the heygen platform.
Generate video with inputsGenerates a customized video using heygen's ai-driven platform.
Post video translate requestThe translatevideo endpoint enables the translation of video content from one language to another.
Retrieve video translation by idRetrieves the current status of a video translation job in the heygen platform.
Retrieve video translation target languagesRetrieves a list of all available target languages supported by heygen's video translation feature.
List available voicesRetrieves a list of available voice models and options that can be used with heygen's ai-driven video creation platform.

Connect Heygen MCP Tool with your Agent

Python
TypeScript

Install Composio

python
pip install composio claude-agent-sdk
Install the Composio SDK and Claude Agent SDK

Create Tool Router Session

python
from composio import Composio
from claude_agent_sdk import ClaudeSDKClient, ClaudeAgentOptions

composio = Composio(api_key='your-composio-api-key')
session = composio.create(user_id='your-user-id')
url = session.mcp.url
Initialize the Composio client and create a Tool Router session

Connect to AI Agent

python
import asyncio

options = ClaudeAgentOptions(
    permission_mode='bypassPermissions',
    mcp_servers={
        'tool_router': {
            'type': 'http',
            'url': url,
            'headers': {
                'x-api-key': 'your-composio-api-key'
            }
        }
    },
    system_prompt='You are a helpful assistant with access to Heygen tools.',
    max_turns=10
)

async def main():
    async with ClaudeSDKClient(options=options) as client:
        await client.query('List streaming avatars available for video generation')
        async for message in client.receive_response():
            if hasattr(message, 'content'):
                for block in message.content:
                    if hasattr(block, 'text'):
                        print(block.text)

asyncio.run(main())
Use the MCP server with your AI agent

Connect Heygen API Tool with your Agent

Python
TypeScript

Install Composio

python
pip install composio_openai
Install the Composio SDK

Initialize Composio and Create Tool Router Session

python
from openai import OpenAI
from composio import Composio
from composio_openai import OpenAIResponsesProvider

composio = Composio(provider=OpenAIResponsesProvider())
openai = OpenAI()
session = composio.create(user_id='your-user-id')
Import and initialize Composio client, then create a Tool Router session

Execute Heygen Tools via Tool Router with Your Agent

python
tools = session.tools
response = openai.responses.create(
  model='gpt-4.1',
  tools=tools,
  input=[{
    'role': 'user',
    'content': 'Generate a talking photo from this uploaded image'
  }]
)
result = composio.provider.handle_tool_calls(
  response=response,
  user_id='your-user-id'
)
print(result)
Get tools from Tool Router session and execute Heygen actions with your Agent

Why Use Composio?

AI Native Heygen Integration

  • Supports both Heygen MCP and direct API based integrations
  • Structured, LLM-friendly schemas for reliable tool execution
  • Rich coverage for creating, editing, and managing Heygen videos

Managed Auth

  • Built-in API key management for Heygen
  • Central place to manage, scope, and revoke Heygen access
  • Per user and per environment credentials instead of hard-coded keys

Agent Optimized Design

  • Tools are tuned using real error and success rates to improve reliability over time
  • Comprehensive execution logs so you always know what ran, when, and on whose behalf

Enterprise Grade Security

  • Fine-grained RBAC so you control which agents and users can access Heygen
  • Scoped, least privilege access to Heygen resources
  • Full audit trail of agent actions to support review and compliance

Frequently Asked Questions

Do I need my own developer credentials to use Heygen with Composio?

Yes, Heygen requires you to configure your own API key credentials. Once set up, Composio handles secure credential storage and API request handling for you.

Can I use multiple toolkits together?

Yes! Composio's Tool Router enables agents to use multiple toolkits. Learn more.

Is Composio secure?

Composio is SOC 2 and ISO 27001 compliant with all data encrypted in transit and at rest. Learn more.

What if the API changes?

Composio maintains and updates all toolkit integrations automatically, so your agents always work with the latest API versions.

Used by agents from

Context
ASU
Letta
glean
HubSpot
Agent.ai
Altera
DataStax
Entelligence
Rolai
Context
ASU
Letta
glean
HubSpot
Agent.ai
Altera
DataStax
Entelligence
Rolai
Context
ASU
Letta
glean
HubSpot
Agent.ai
Altera
DataStax
Entelligence
Rolai

Never worry about agent reliability

We handle tool reliability, observability, and security so you never have to second-guess an agent action.