360 Secure SkillHub
360 安全技能中心

Tomoviee Video Background Music

通过 Python 客户端调用 Tomoviee AI 的 tm_video_scoring 接口,提交视频 URL 与可选风格提示,异步轮询任务状态并返回生成结果;需要 app_key 与 app_secret 生成鉴权 token。

wondershare-boop
wondershare-boop
热度 56.29
最近更新 2026-05-11 17:29:21
分类:创作依赖:代码执行 / 第三方 API应用场景:视频编辑 / 工作流

安装技能

复制下面的话术发给你的 Agent,它会通过 secure-skills 检索并安装该技能。

执行命令安装此 skill: npx secure-skills-cli add tomoviee-video-background-music
Metadata
name
tomoviee-video-scoring
description
Generate music tailored to video content. Use when users request video_soundtrack operations or related tasks.

Tomoviee AI - 视频配乐 (Video Soundtrack)

Overview

Generate music tailored to video content.

API: tm_video_scoring

Quick Start

Authentication

python scripts/generate_auth_token.py YOUR_APP_KEY YOUR_APP_SECRET

Python Client

from scripts.tomoviee_video_soundtrack_client import TomovieeClient

client = TomovieeClient("app_key", "app_secret")

API Usage

Basic Example

task_id = client._make_request({
    video='https://example.com/my-video.mp4'
    prompt='Modern tech product music, clean'
})

result = client.poll_until_complete(task_id)
import json
output = json.loads(result['result'])

Parameters

  • video (required): Video URL (MP4, <200M)
  • prompt: Optional style guidance
  • duration: Audio duration (5-900, default: 20)

Async Workflow

  1. Create task: Get task_id from API call
  2. Poll for completion: Use poll_until_complete(task_id)
  3. Extract result: Parse returned JSON for output URLs

Status codes:

  • 1 = Queued
  • 2 = Processing
  • 3 = Success (ready)
  • 4 = Failed
  • 5 = Cancelled
  • 6 = Timeout

Resources

scripts/

  • tomoviee_video_soundtrack_client.py - API client
  • generate_auth_token.py - Auth token generator

references/

See bundled reference documents for detailed API documentation and examples.

External Resources