Spiritme
  1. videos
Spiritme
  • avatars
    • avatars_list
      GET
  • batch-video-templates
    • batch_video_templates_list
      GET
    • batch_video_templates_create
      POST
    • batch_video_templates_retrieve
      GET
  • batch-videos
    • batch_videos_list
      GET
    • batch_videos_create
      POST
    • batch_videos_retrieve
      GET
  • files
    • files_list
      GET
    • files_create
      POST
    • files_retrieve
      GET
    • files_destroy
      DELETE
    • files_children_list
      GET
  • schema
    • schema_retrieve
      GET
  • tts
    • tts_languages_list
      GET
    • tts_voices_list
      GET
  • users
    • users_current_retrieve
      GET
    • users_current_destroy
      DELETE
  • videos
    • videos_list
      GET
    • videos_create
      POST
    • videos_retrieve
      GET
    • videos_update
      PUT
    • videos_destroy
      DELETE
    • videos_publish_create
      POST
  1. videos

videos_create

开发环境
http://dev-cn.your-api-server.com
开发环境
http://dev-cn.your-api-server.com
POST
/api/videos/
videos
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request POST 'http://dev-cn.your-api-server.com/api/videos/' \
--header 'Authorization;' \
--data-urlencode 'slides='
响应示例响应示例
{
    "id": 0,
    "cd": "2019-08-24T14:15:22Z",
    "gd": "2019-08-24T14:15:22Z",
    "name": "New video",
    "slides": [
        {
            "id": 0,
            "audio_source": {
                "text": "string",
                "voice": {
                    "id": 0,
                    "name": "string",
                    "label": "string",
                    "provider": "amazon",
                    "sex": "male",
                    "language": "string",
                    "language_code": "string"
                },
                "file": {
                    "id": 0,
                    "name": "string",
                    "duration": 0,
                    "tag": "general",
                    "file": "http://example.com",
                    "compressed_file": "http://example.com"
                }
            },
            "layers": [
                {
                    "avatar": {
                        "id": 0,
                        "name": "string",
                        "preview": "http://example.com",
                        "frame_width": 0,
                        "frame_height": 0
                    },
                    "media": {
                        "id": 0,
                        "name": "string",
                        "tag": "general",
                        "file": "http://example.com",
                        "compressed_file": "http://example.com",
                        "width": 0,
                        "height": 0
                    },
                    "x": -1,
                    "y": -1,
                    "scale": 1,
                    "crop": {
                        "left_upper_x": 0,
                        "left_upper_y": 0,
                        "right_lower_x": 0,
                        "right_lower_y": 0
                    },
                    "view_type": "rectangular"
                }
            ],
            "background": {
                "id": 0,
                "name": "string",
                "tag": "general",
                "file": "http://example.com",
                "compressed_file": "http://example.com",
                "width": 0,
                "height": 0
            }
        }
    ],
    "webhook": {
        "id": 0,
        "cd": "2019-08-24T14:15:22Z",
        "url": "http://example.com"
    },
    "resolution": {
        "width": 1920,
        "height": 1080
    },
    "auto_emotions_markup": false,
    "status": "draft",
    "result": "http://example.com",
    "thumbnail": "http://example.com"
}

请求参数

Header 参数
Authorization
string 
必需
默认值:
Token <api-key>
Body 参数application/x-www-form-urlencoded
name
string 
可选
>= 1 字符<= 80 字符
默认值:
New video
示例值:
New video
slides
array[object (SlideRequest) {3}] 
必需
audio_source
object (AudioSourceRequest) 
必需
layers
array[object (LayerRequest) {7}] 
必需
background
null  | allOf {1} 
可选
webhook
null  | allOf {1} 
可选
object (WebhookNestedRequest) 
可选
resolution
object 
可选
默认值:
{"width":1920,"height":1080}
示例值:
{ "width": 1920, "height": 1080 }
width
integer 
可选
>= 500<= 3840
默认值:
1920
height
integer 
可选
>= 500<= 3840
默认值:
1080
auto_emotions_markup
boolean 
可选
默认值:
false
示例值:
false

返回响应

🟢201成功
application/json
Body
id
integer 
只读必需
cd
string <date-time>
Created datetime
只读必需
gd
string <date-time> | null 
Generated datetime
只读必需
name
string 
可选
<= 80 字符
默认值:
New video
slides
array[object (Slide) {4}] 
必需
id
integer 
只读必需
audio_source
object (AudioSource) 
必需
layers
array[object (Layer) {7}] 
必需
background
null  | allOf {1} 
可选
webhook
null  | allOf {1} 
可选
object (WebhookNested) 
可选
resolution
object 
可选
默认值:
{"width":1920,"height":1080}
width
integer 
可选
>= 500<= 3840
默认值:
1920
height
integer 
可选
>= 500<= 3840
默认值:
1080
auto_emotions_markup
boolean 
可选
默认值:
false
status
enum<string> 
只读必需
枚举值:
draftin_queueexecutingerrorinsufficient_balance_errorsuccesscleared
result
string <uri> | null 
只读必需
thumbnail
string <uri>
只读必需
Thumbnail for video
修改于 2024-03-28 09:50:16
上一页
videos_list
下一页
videos_retrieve
Built with