Stable Diffusion
  1. 文字转视频
Stable Diffusion
  • Stable Diffusion API 文档
  • A1111 调度程序
  • Stable Diffusion API
    • 概述
    • 文本到图像
      POST
    • 图像到图像
      POST
    • 修复
      POST
    • 获取排队图像
      POST
    • 系统负载
      POST
  • 训练模型
    • 概述
    • Lora 模型
      POST
    • Dreambooth 模型 (V2)
      POST
    • Dreambooth 模型
      POST
    • 训练状态
      POST
    • 获取模型列表
      POST
    • 删除训练
      POST
    • 取消训练
      POST
    • 裁剪 Base64 图像
      POST
  • 文字转视频
    • 概述
    • 创建视频
      POST
    • 将文本训练为视频
      POST
  • 社区模型 API V4
    • 概述
    • 文本转图像
      POST
    • LoRA
      POST
    • LoRA 多功能设备
      POST
    • 图像到图像
      POST
    • 修复
      POST
    • 获取排队图像接口
      POST
    • 重新加载模型接口
      POST
  • 管理信息系统
    • 概述
    • 裁剪 Base64 图像
    • 删除图像
    • 获取训练过的模型列表
    • 获取公共型号列表
    • 清除用户缓存
    • 购买 Dreambooth 模型
    • 购买订阅计划
    • 取消订阅计划
    • NSFW 图像检查
    • 上传模型
    • 创建房间内部接口
  • 控制网
    • 概述
    • ControlNet 主要终端
    • ControlNet 多功能终端
  • 企业计划
    • 概述
    • 系统详情
    • 重新启动服务器终端
    • 更新服务器
    • 更新 S3 详细信息
    • 清楚缓存
    • 列表调度程序
    • 负载模型
    • 验证模型
    • 获取所有模型
    • 删除模型
    • Controlnet
    • 文字转图像
    • 文字转视频
    • 图像到图像
    • 修复
    • 超分辨率
    • 上传图片
    • 同步模型
    • 负载 Vae
    • NSFW 图像检查
    • 获取排队图像
  • Dreambooth 沙盒
    • 概述
    • 创建 Dreambooth 请求(沙盒)
    • 获取训练状态(沙盒)
  • 图像编辑
    • 概述
    • 外部绘画
    • Blip 扩散
    • 魔术混合接口
    • 图像深度
    • 图像混合器
    • 图像引导编辑
    • 删除背景
    • 超分辨率
    • 混合画布
  • 文本转 3D
    • 概述
    • 文本转 3D
    • 图像转 3D
  • 未经审查的聊天
    POST
  1. 文字转视频

将文本训练为视频

开发环境
https://stablediffusionapi.com/v1
开发环境
https://stablediffusionapi.com/v1
POST
https://stablediffusionapi.com/api/v4/dreambooth/text2video
该端点用于根据经过训练或公共模型的文本提示创建视频。
您可以对经过训练的模型以及任何公共模型进行 API 调用。
此端点根据请求正文中传递的文本生成并返回视频。
POST向https://stablediffusionapi.com/api/v4/dreambooth/text2video端点发出请求,并将所需参数作为请求正文传递。
该接口还支持调度程序。使用请求正文中的“scheduler”参数来设置要从以下列表中使用的特定调度程序:
DDPMScheduler
DDIMScheduler
PNDMScheduler
LMSDiscreteScheduler
EulerDiscreteScheduler
EulerAncestralDiscreteScheduler
DPMSolverMultistepScheduler
HeunDiscreteScheduler
KDPM2DiscreteScheduler
DPMSolverSinglestepScheduler
KDPM2AncestralDiscreteScheduler
UniPCMultistepScheduler
DDIMInverseScheduler
DEISMultistepScheduler
IPNDMScheduler
KarrasVeScheduler
ScoreSdeVeScheduler
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://stablediffusionapi.com/api/v4/dreambooth/text2video' \
--header 'Content-Type: application/json' \
--data-raw '{
  "key": "",
  "model_id": "your_model_id",
  "prompt": "a cat sitting on a bench",
  "negative_prompt": null,
  "width": "512",
  "height": "512",
  "scheduler": null,
  "num_inference_steps": "30",
  "enhance_prompt": "yes",
  "guidance_scale": 7.5,
  "strength": 0.7,
  "seed": null,
  "webhook": null,
  "track_id": null
}'
响应示例响应示例
{
  "status": "processing",
  "tip": "for faster speed, keep resolution upto 512x512",
  "eta": 21.880000000000003,
  "messege": "Try to fetch request after given estimated time",
  "fetch_result": "https://stablediffusionapi.com/api/v3/dreambooth/fetch/13801718",
  "id": 13801718,
  "output": [],
  "meta": {
    "prompt": "mdjrny-v4 style a cat sitting on a bench DSLR photography, sharp focus, Unreal Engine 5, Octane Render, Redshift, ((cinematic lighting)), f/1.4, ISO 200, 1/160s, 8K, RAW, unedited, symmetrical balance, in-frame",
    "model_id": "midjourney",
    "scheduler": "UniPCMultistepScheduler",
    "safetychecker": "no",
    "negative_prompt": " ((out of frame)), ((extra fingers)), mutated hands, ((poorly drawn hands)), ((poorly drawn face)), (((mutation))), (((deformed))), (((tiling))), ((naked)), ((tile)), ((fleshpile)), ((ugly)), (((abstract))), blurry, ((bad anatomy)), ((bad proportions)), ((extra limbs)), cloned face, glitchy, ((extra breasts)), ((double torso)), ((extra arms)), ((extra hands)), ((mangled fingers)), ((missing breasts)), (missing lips), ((ugly face)), ((fat)), ((extra legs))",
    "W": 512,
    "H": 512,
    "guidance_scale": 7.5,
    "steps": 20,
    "strength": 0.55,
    "full_url": "no",
    "seconds": 5,
    "multi_lingual": "no",
    "seed": 3532512439,
    "outdir": "out",
    "file_prefix": "d06b5499-eb10-4292-8256-9c269c36199f",
    "num_frames": 40
  }
}

请求参数

Body 参数application/json
key
string 
必需
您的 API 密钥用于请求授权。
model_id
string 
必需
要使用的模型的 ID。它可以是公共的,也可以是您训练有素的模型。
prompt
string 
必需
文本提示,包含您想要在视频中生成的内容的描述。
negative_prompt
null 
必需
您不希望出现在视频中的项目。
width
string 
必需
最大高度:宽度:1024x1024。
height
string 
必需
最大高度:宽度:1024x1024。
scheduler
null 
必需
用它来设置调度程序。
num_inference_steps
string 
必需
去噪步骤数(最小值:1;最大值:50)。
enhance_prompt
string 
必需
增强提示以获得更好的结果;默认值:是,选项:是/否。
guidance_scale
number 
必需
无分类器指导的量表(最小值:1;最大值:20)。
strength
number 
必需
使用init image时提示强度。1.0 对应于初始化映像中信息的完全破坏。
seed
null 
必需
种子用于重现结果,相同的种子将再次给您相同的结果。为随机数传递null 。
webhook
null 
必需
设置 URL 以在视频生成完成后获取 POST API 调用。
track_id
null 
必需
此 ID 在 Webhook API 调用的响应中返回。这将用于识别 Webhook 请求。
示例

返回响应

🟢200成功
application/json
Body
status
string 
必需
tip
string 
必需
eta
number 
必需
messege
string 
必需
fetch_result
string 
必需
id
integer 
必需
output
array[string]
必需
meta
object 
必需
prompt
string 
必需
model_id
string 
必需
scheduler
string 
必需
safetychecker
string 
必需
negative_prompt
string 
必需
W
integer 
必需
H
integer 
必需
guidance_scale
number 
必需
steps
integer 
必需
strength
number 
必需
full_url
string 
必需
seconds
integer 
必需
multi_lingual
string 
必需
seed
integer 
必需
outdir
string 
必需
file_prefix
string 
必需
num_frames
integer 
必需
上一页
创建视频
下一页
概述
Built with