Update a video

Usable endpoint to synchronise actual video information, including name, tags and slides.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…

📘

How to create proper structure

The structure of the video is quite complex, so If you want to create/update the structure of the slide from API, the best way to do it would be to create the layout in the Elai UI, retrieve it using GET /videos/:videoId, and use the structure from response JSON body.

🚧

Update slide status

By default, we don't re-render each slide if you don't change it. So if you want any slide to be re-rendered, you need to change its status in your PATCH call to 'edited'. Please make sure slides[].status = 'edited' is set for each slide you want to be re-rendered.

{
    "tags": [],
    "status": "draft",
    "verified": true,
    "public": true,
    "id": "628533740e4e642def3141ab",
    "name": "Greetings for {{name}}",
    "userId": "627b9a3fe5a60082d0cecc3e",
    "accountId": "627b9a3fe5a60082d0cecc3f",
    "createdAt": "2022-05-18T17:57:08.004Z",
    "updatedAt": "2022-05-18T17:57:11.339Z",
    "slides": [
        {
            "id": 1634592244043,
            "speech": "Hello {{name}} with voice!",
            "avatar": {
                "code": "zara.regular",
                "gif": "https://elai-media.s3.eu-west-2.amazonaws.com/avatars/zara.gif",
                "thumbnail": "https://elai-media.s3.eu-west-2.amazonaws.com/avatars/zara.jpg",
                "canvas": "https://elai-media.s3.eu-west-2.amazonaws.com/avatars/zara.png",
                "tilt": {
                    "top": -0.02
                },
                "gender": "female"
            },
            "language": "English",
            "voice": "en-US-AriaNeural",
            "voiceType": "text",
            "animation": "fade_in",
            "canvas": {
                "version": "4.4.0",
                "background": "#ffffff",
                "objects": [
                    {
                        "type": "avatar",
                        "left": 350,
                        "top": 144.6,
                        "scaleX": 0.6,
                        "scaleY": 0.6,
                        "avatarType": "transparent",
                        "src": "https://elai-media.s3.eu-west-2.amazonaws.com/avatars/zara.png",
                        "fill": "#a56ced",
                        "animation": {
                            "type": null
                        },
                        "width": 360,
                        "height": 360
                    }
                ]
            },
            "newlyAdded": false,
            "duration": null,
            "approxDuration": 1.7333333333333334,
            "status": "edited",
            "played": true,
            "internal": {
                "audioUrl": "https://elai-media.s3.eu-west-2.amazonaws.com/videos/628533740e4e642def3141ab/1634592244043/speech.mp3"
            }
        }
    ],
    "data": {
        "subtitlesEnabled": "burn",
        "subtitlesUrl": "https://elai-us-prod.s3.us-east-2.amazonaws.com/development/videos/64ba260366858c187fc671dc/subtitles.srt?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAW6FMUIGA6NPIQQ5B%2F20230721%2Fus-east-2%2Fs3%2Faws4_request&X-Amz-Date=20230721T125838Z&X-Amz-Expires=604800&X-Amz-Signature=cf79be93031e30a5889c01ac85fc0fd053d35b4ff54fdc432c5e8e905f52c73a&X-Amz-SignedHeaders=host&response-cache-control=public%2C%20max-age%3D31536000%2C%20immutable"
    },
}
{
    "tags": ["welcome", "template"],
    "name": "Greetings for {{name}}",
    "subtitlesEnabled": 'burn'
    "slides": [
        {
            "id": 1634592244043,
            "speech": "Hello {{name}} with voice!",
            "bg": {
                "type": "color",
                "color": "#FFFFFF",
                "position": {
                    "x": 0,
                    "y": 0,
                    "zoom": 1
                },
                "trimStart": 0
            },
            "avatar": {
                "code": "zara.regular",
                "name": "Casual",
                "gif": "https://elai-media.s3.eu-west-2.amazonaws.com/avatars/zara.gif",
                "thumbnail": "https://elai-media.s3.eu-west-2.amazonaws.com/avatars/zara.png",
                "tilt": {
                    "top": -4,
                    "left": -13.5
                },
                "gender": "female"
            },
            "avatarProps": {
                "size": 66,
                "position": 55,
                "verticalPosition": 0,
                "type": "transparent",
                "color": "#f88074"
            },
            "language": "English",
            "voice": "en-US-JennyNeural",
            "voiceType": "text",
            "animation": null,
            "duration": 2.4,
            "approxDuration": 1.7333333333333334,
            "status": "inQueue",
            "canvas": {
                "version": "4.4.0",
                "objects": []
            },
            "played": true,
            "internal": {
                "audioUrl": "https://elai-media.s3.eu-west-2.amazonaws.com/videos/628533740e4e642def3141ab/1634592244043/speech.mp3"
            }
        }
    ],
}

👍

Slide structure

More details about slide structure can be found here

Path Params
string
required

Video identifier

Body Params
string

Video name

slides
array of objects

Prepared slides

slides
tags
array of strings

Video tags

tags
boolean
Defaults to false

If the video is publicly available.

data
object

Additional params and settings

string

Id of the folder where to put your video to. By default video will be created in the root .

template
object

Make your video as Template

Responses

Language
Credentials
Header
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json