Create and monitor asynchronous AI music video tasks from Dify Workflows, Chatflows, and Agents.
- Website: https://beatapi.io/
- API documentation: https://docs.beatapi.io/
- Create an API key: https://beatapi.io/dashboard/apikeys
- Source code: https://github.com/erickkkyt/beatapi-dify-plugin
Starts a BeatAPI music-video workflow using one to seven public HTTPS image
URLs and one public HTTPS audio URL. It returns a task ID immediately, so long
renders do not block the Dify tool call.
The tool exposes BeatAPI's optional creative, quality, aspect-ratio, lip-sync,
subtitle, duration-fallback, and composition controls. auto composition is the
default and returns a finished hosted video. manual returns a storyboard that
can be edited and composed through the BeatAPI API.
Returns the current task status, stage, output, usage, request ID, and public
error fields. Poll every 5-10 seconds until the task reaches succeeded or
failed; manual tasks can pause at storyboard_ready for later editing.
In Dify, open Plugins > Install Plugin > GitHub, then enter:
erickkkyt/beatapi-dify-plugin
- Create a revocable API key at https://beatapi.io/dashboard/apikeys.
- Open Tools > BeatAPI > Authorize in Dify.
- Paste the API key. Dify verifies it with
GET /v1/usage. - Add Create Music Video Task and Get Task to a Workflow, Chatflow, or Agent.
The API key is sent only in the Authorization: Bearer header to
https://api.beatapi.io. Never place it in prompts or tool parameters.
- Produce or collect a public image URL and a 10-180 second public audio URL.
- Call Create Music Video Task.
- Store the returned
id. - Wait 5-10 seconds and call Get Task with that ID.
- Repeat with a bounded loop until the task reaches a terminal state.
- Read the hosted video URL from the task output.
The plugin requires Python 3.12 and the Dify CLI.
uv sync
cp .env.example .env
uv run python -m mainRun the behavior tests:
PYTHONPATH=. uv run python -m unittest discover -s tests -vPackage the plugin from the parent directory:
dify plugin package ./beatapiEmail support@beatapi.io or visit https://beatapi.io/.