Loading...
Loading...
Use when the user wants to create AI music videos (MV)—including generating music from text prompts or using custom lyrics. Triggers: generate MV, music video, make video for this song, lyrics video, create MV, AI music video, music+video, generate video from lyrics.
npx skill4agent add giggle-official/skills giggle-generation-aimvexecute_workflowpython3 (>=3.6)GIGGLE_API_KEYrequestsNo Retry on Error: If script execution encounters an error, do not retry. Report the error to the user directly and stop.
GIGGLE_API_KEYexport GIGGLE_API_KEY=your_api_keyGIGGLE_API_KEYHello! Before using the MV generation feature, you need to configure the API Key. Please go to Giggle.pro to get your API Key, then runin the terminal.export GIGGLE_API_KEY=your_api_key
| Mode | music_generate_type | Required params | Description |
|---|---|---|---|
| Prompt | | prompt, vocal_gender | Describe music in text |
| Custom | | lyrics, style, title | Provide lyrics, style, and title |
"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8z8BQDwAEhQGAhKmMIQAAAABJRU5ErkJggg=="16:99:16promptvocal_gendermalefemaleautoautoinstrumentallyricsstyletitleexecute_workflowcreate_projectsubmit_mv_taskexecute_workflowcreate_and_submitexecute_workflow(
music_generate_type: str, # Mode: prompt / custom
aspect: str, # Aspect ratio: 16:9 or 9:16
project_name: str, # Project name
reference_image: str = "", # Reference image asset_id (mutually exclusive with reference_image_url)
reference_image_url: str = "", # Reference image URL or base64 (mutually exclusive with reference_image)
scene_description: str = "", # Scene description, default empty
subtitle_enabled: bool = False, # Subtitle toggle, default False
# Prompt mode
prompt: str = "",
vocal_gender: str = "auto",
instrumental: bool = False,
# Custom mode
lyrics: str = "",
style: str = "",
title: str = "",
)reference_imagereference_image_url9:1616:9api = MVTrusteeAPI()
result = api.execute_workflow(
music_generate_type="prompt",
aspect="16:9",
project_name="My MV",
reference_image_url="https://example.com/ref.jpg",
prompt="Upbeat pop, sunny beach vibe",
vocal_gender="female"
)result = api.execute_workflow(
music_generate_type="custom",
aspect="9:16",
project_name="Lyrics MV",
reference_image="asset_xxx",
lyrics="Verse 1: Spring breeze on my face...",
style="pop",
title="Spring Song"
)result = api.execute_workflow(
music_generate_type="prompt",
aspect="16:9",
project_name="Scene MV",
reference_image_url="https://...",
prompt="Electronic dance music",
scene_description="City nightscape, neon lights, flowing traffic"
)/api/v1/trustee_mode/mv/submit{
"project_id": "<your-project-id>",
"music_generate_type": "prompt",
"prompt": "A cheerful pop song",
"vocal_gender": "female",
"instrumental": false,
"reference_image_url": "/9j/4AAQSkZJRgABAQAAAQABAAD/2wCEAAkGBxMTEhUT...(base64 image data)",
"scene_description": "A romantic beach walk at sunset, waves gently lapping the shore, pink sky gradient",
"aspect": "16:9",
"subtitle_enabled": false
}reference_imagereference_image_url{
"project_id": "<your-project-id>",
"music_generate_type": "custom",
"lyrics": "Verse 1:\nStanding by the sea watching the sunset\nMemories rush in like waves\n\nChorus:\nLet the sea breeze blow away all worries\nIn this golden moment\nWe found each other\n",
"style": "pop ballad",
"title": "Seaside Memories",
"reference_image": "<asset_id>",
"scene_description": "A couple walking on the beach at dusk, long shadows, orange-red sky gradient",
"aspect": "9:16",
"subtitle_enabled": false
}/api/v1/trustee_mode/mv/query{
"code": 200,
"msg": "success",
"uuid": "<response-uuid>",
"data": {
"project_id": "<your-project-id>",
"video_asset": {
"asset_id": "<asset_id>",
"download_url": "https://assets.giggle.pro/private/...",
"thumbnail_url": "https://assets.giggle.pro/private/...",
"signed_url": "https://assets.giggle.pro/private/...",
"duration": 0
},
"shot_count": 0,
"current_step": "editor",
"completed_steps": "music-generate,storyboard,shot,editor",
"pay_status": "paid",
"status": "completed",
"err_msg": "",
"steps": [...]
}
}pay_statuspendingstepsvideo_asset.download_urlhttps://assets.giggle.pro/private/ai_director/348e4956c7bd4f763b/qzjc7gwkpf.mp4?Policy=...&Key-Pair-Id=...&Signature=...&response-content-disposition=attachmenthttps://assets.giggle.pro/private/ai_director/348e4956c7bd4f763b/qzjc7gwkpf.mp4/api/v1/trustee_mode/mv/pay{
"project_id": "<your-project-id>"
}{
"code": 200,
"msg": "success",
"uuid": "<response-uuid>",
"data": {
"order_id": "<order-id>",
"price": 580
}
}{
"project_id": "<your-project-id>",
"current_step": "shot"
}current_stepmusic-generatestoryboardshoteditorcreate_and_submitcreate_projectsubmit_mv_taskapi = MVTrusteeAPI()
r = api.create_and_submit(
project_name="My MV",
music_generate_type="prompt",
aspect="16:9",
reference_image_url="https://...",
prompt="Upbeat pop"
)
# Returns project_id for manual query/pay later{
"code": 200,
"msg": "success",
"data": {
"project_id": "...",
"download_url": "https://...",
"video_asset": {...},
"status": "completed"
}
}| Scenario | Cause | Solution |
|---|---|---|
| | Verify the key at Giggle.pro account settings and re-export: |
| API rate limit exceeded | Wait a few minutes and retry; avoid submitting multiple projects in rapid succession |
| Network timeout / connection error | Unstable network or API service temporarily unavailable | The script auto-retries up to 5 times with 5-second intervals; check your network if it still fails |
| The project requires payment before proceeding | The workflow function handles this automatically; if running manually, call the pay endpoint with the |
Task step failed ( | A generation step (e.g. | Use the retry endpoint: |
| Workflow timeout (> 1 hour) | MV generation took too long | Query progress manually with the |