Skip to main content

Sora2 MCP Server - 基于 Sora2 视频模型的 MCP 服务器实现

Project description

Sora2 MCP Server

基于 Sora2 视频模型的 MCP 服务器实现,支持视频生成功能。

功能特性

  • 视频生成 (generate_video): 根据提示词生成视频
  • 基于图片生成视频 (generate_video_with_image): 基于参考图片生成视频
  • 故事板视频 (generate_storyboard_video): 根据故事板格式的提示词生成视频
  • 角色客串视频 (generate_video_with_character): 生成带有角色客串的视频
  • 模型列表 (list_models): 列出所有可用模型及其特性
  • 任务查询 (get_video_task): 查询视频生成任务状态

可用模型

模型名称 描述
sora-2 标准版,支持基本视频生成功能
sora-2-pro 专业版,支持高清和更长时长 (25秒)

环境变量

变量名 必需 默认值 描述
SORA2_API_KEY - API 密钥
SORA2_API_BASE_URL https://api.lightai.io API 基础 URL

安装

pip install shuttlet_sora2_mcp

或使用 uvx 直接运行(无需安装):

uvx shuttlet_sora2_mcp

Cursor MCP 配置

在 Cursor 的 ~/.cursor/mcp.json 中添加以下配置:

{
  "mcpServers": {
    "sora2": {
      "command": "uvx",
      "args": [
        "shuttlet_sora2_mcp"
      ],
      "env": {
        "SORA2_API_KEY": "your-api-key-here",
        "SORA2_API_BASE_URL": "https://api.lightai.io"
      }
    }
  }
}

⚠️ 请将 your-api-key-here 替换为你的实际 API 密钥。

使用示例

配置完成后,在 Cursor 中可以使用以下工具:

生成视频

生成一个可爱的小猫在花园里玩耍的视频,竖屏,5秒

基于图片生成视频

基于这张图片生成一个视频,展示图片中的场景动态效果

生成故事板视频

生成一个故事板视频:
Shot 1:
duration: 7.5sec
Scene: 飞机起飞

Shot 2:
duration: 7.5sec
Scene: 飞机降落

生成角色客串视频

生成一个视频:@{角色1Username} 在一个舞台上和 @{角色2Username} 牵手跳舞

查看可用模型

列出所有可用的 Sora2 模型

查询任务状态

查询视频生成任务状态,任务 ID: task_123456

许可证

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

shuttlet_sora2_mcp-0.1.0.tar.gz (3.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

shuttlet_sora2_mcp-0.1.0-py3-none-any.whl (5.3 kB view details)

Uploaded Python 3

File details

Details for the file shuttlet_sora2_mcp-0.1.0.tar.gz.

File metadata

  • Download URL: shuttlet_sora2_mcp-0.1.0.tar.gz
  • Upload date:
  • Size: 3.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for shuttlet_sora2_mcp-0.1.0.tar.gz
Algorithm Hash digest
SHA256 f5b086833576c3c3911441b6945f7179411ef3821ca406e921684878829a573a
MD5 15d0038780bcf467ffcb32a7247f92fd
BLAKE2b-256 f12339d784744dd1f6a89aeb54a5a390f06e1578ab776246d1fb099677af73b0

See more details on using hashes here.

File details

Details for the file shuttlet_sora2_mcp-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: shuttlet_sora2_mcp-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 5.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for shuttlet_sora2_mcp-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 0948d2b1c519c5cf6ebc391ad3b9d98c9abb71a1f10fb8dc40810f5ae0566f34
MD5 852d4456f086c1e35408c9821e3a3902
BLAKE2b-256 135bb59b678e97b7e5b431fa74bfa441254388d8fd143c5f833e12847d63f5f4

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page