Pictory
  1. API Reference
Pictory
  • API Flows
    • Text to Video API Flow
      • Step 1: Authenticate
      • Step 2: Generate Video Preview from Text
      • Step 3: GET Video Preview & Default Settings
      • Step 4: Render Video
      • Step 4: Render PUT
      • Step 5: GET Video Download URL
    • Video Editing API Flow
      • Step 1: Authenticate
      • Step 2: Obtain Pictory Upload URL
      • Step 3: Upload video to Pictory
      • Step 4: v2 Transcribe Uploaded Video
      • Step 5: GET Default Transcription & Highlights Settings
      • Step 6: Render Video
      • Step 7: GET Video Download URL
    • Bulk Video Generation APIs
      • Step 1: Authenticate
      • Step2: Upload Project
      • Step3: Update Variables
      • Step 4: Get Video Preview
      • Step 5: Render Video
      • Step 6: GET Video Download URL
  • API Reference
    • /v1/oauth2/token
      POST
    • /v1/video/storyboard
      POST
    • /v1/job/{job_id}
      GET
    • /v1/media/generateUrl
      POST
    • Upload video to Pictory
      PUT
    • /v2/transcription (Transcript & Highlights)
      POST
    • /v2 GET Default Transcription & Highlights Settings
      GET
    • /v1/transcription
      POST
    • /v1 GET Default Transcription Settings
      GET
    • /v1/transcription/highlights
      POST
    • /v2/transcription/highlights
      POST
    • /v1 GET Default Highlight Settings
      GET
    • /v1/video/storyboard/fonts
      GET
    • Create Template
      POST
    • Update Template
      PUT
    • Get Templates
      GET
    • Create Template Video
      POST
    • Get Template By Id
      GET
    • Delete Template By Id
      DELETE
    • /v1/video/render
      POST
    • v1/media/search
      GET
  1. API Reference

/v1/video/render

Develop Env
https://dev.your-api-server.com
Develop Env
https://dev.your-api-server.com
POST
/v1/video/render
This call Renders the video for download.
The video download link can be obtained from the /v1/job/{job_id} call response body once the job has successfully completed.
"videoURL": "https://d3uryq9bhgb5qr.cloudfront.net/EnterpriseSubscription/PictoryQAVidyard/702f8260-c56a-4fbc-9741-ddc44df24aa2/VIDEO/testvideo.mp4"
Default video settings data is obtained from the renderParams response body object of the GET Video Preview & Default Settings API call. This data is auto-captured in the Postman environment
To view the capture method see API call Tests.
To view the stored data in the Postman environment, see values: audio_settings, output_settings, scene_settings.
For custom settings, manually replace request body with renderParams data.
Refer to Pictory Web App Storyboard for all setting values.
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://dev.your-api-server.com/v1/video/render' \
--header 'Authorization: {{access_token}}' \
--header 'X-Pictory-User-Id: {{X-Pictory-User-Id}}' \
--header 'Content-Type: application/json' \
--data-raw '{
    "audio": { 
        "video_volume": 1, //Volume: 0-1 (1 = 100%)
        "audio_id": "549", //Auto-generated when AI-selected audio
        "audio_library": "track", //Auto-generated when AI-selected audio
        "src": "https://tracks.melod.ie/track_versions/1668/MEL182_01_1_Decorate_The_Christmas_Tree_%28Full%29_Maike_Watson.mp3?1632615758", //Auto-generated when AI-selected audio
        "track_volume": 0.5, // Decimal range: 0-1 (0.5 = 50% volume)
        "tts": "https://pictory-audios.s3.us-east-2.amazonaws.com/polly/production/projects/PictoryQAVidyard/a49594c5745e42e28d23562ef91699b2.mp3" //AI-generated text-to-speech file
    },
    "output": { //Settings for the video file output
        "name": "Santa Claus.mp4", // Name of the output video file
        "description": "Santa Claus is coming to town",
        "format": "mp4", //Supports only mp4
        "title": "Santa Claus",
        "width": 1920, // 1920x1080 is 1080p; 1280x720 is 720p
        "height": 1080
    },
    "scenes": [ //Each video scene has its own data format
        {
            "background": {
                "src": [
                    {
                        "url": "https://dm0qx8t0i9gc9.cloudfront.net/watermarks/video/HJDS012pYkysh5h0a/videoblocks-176z_winter_021219_5_sbbt1bfmgn__3a36a68d6a9e04708f8b9307bfe5f751__P480.mp4?type=preview&origin=VIDEOBLOCKS&timestamp_ms=1686596540699&publicKey=NFKFzias7JkF35W3n9edUuQV1Rnn7udTDco3ZbvzlsXgiAzLXO0a15shkgbMNmXZ&organizationId=103776&apiVersion=2.0&stockItemId=347545181&resolution=480p&endUserId=718890439cf9899e412f4e3d6c8148c452fb5959&projectId=dev&searchId=d63d38e0-49b1-4726-bcf4-f9684fd7a0d1&searchPageId=a3e87291-674a-4de9-afc1-d14b1e7462e8", //Background Video or Image URL
                        "asset_id": 10845705, //For AI visuals, use autogenerated ID
                        "type": "video", //Video or image
                        "library": "story_blocks", //3rd party stock visual library
                        "mode": "fit", //Crop or fit
                        "frame": null, //For AI visuals, use autogenerated value
                        "loop_video": true, //Loop visual throughout the scene
                        "mute": true, //Mute video sound. Usually true for Text to Video API flows
                        "resource_id": 10845705, //For AI visuals, use autogenerated ID
                        "sessionId": "4da0886e-0df1-4b53-8a08-d33c04bbf48c" //For AI visuals, use autogenerated ID
                    }
                ],
                "color": "rgba(255,255,255,255)", //Accepts rgba or hex value
                "bg_animation": {
                    "animation": "pan-right" //For 3rd party images. Animations: pan-up/down/right/left, zoom-in
                }
            },
            "time": 7.368, //Scene duration in seconds
            "keywords": [], //Keywords to highlight in video the text
            "sub_scenes": [ //Each scene contains a sub-scene
                {
                    "time": 7.368, //Sub-scene text duration in seconds
                    "location": {
                        "start_x": 50, //Text'\''s center x-coordinate in video
                        "start_y": 929.28 //Text'\''s end y-coordinate in video
                    },
                    "displayItems": [],
                    "text_lines": [ //Settings for subtitle display
                        {
                            "text": "In the North Pole, beneath the shimmering stars, Santa Claus, with a merry twinkle in his eyes,",
                            "text_animation": [ //Animations for the text
                                {
                                    "animation": "slide-in-left", //Animations: expand-out, slide-in-left, fade-in, slide-in-left, slide-in-right
                                    "source": "templates",
                                    "speed": 1.4, //Text animation speed. Percentage range from 0-2
                                    "type": "start" //Supply a start and an end
                                },
                                {
                                    "animation": "none",
                                    "source": "templates",
                                    "speed": 0.5,
                                    "type": "end" //Supply a start and an end
                                }
                            ],
                            "text_bg_animation": [ //Background text animations
                                {
                                    "animation": "slide-in-left",
                                    "source": "templates",
                                    "speed": 1.4,
                                    "type": "start" //Supply a start and an end
                                },
                                {
                                    "animation": "none",
                                    "source": "templates",
                                    "speed": 0.5,
                                    "type": "end" //Supply a start and an end
                                }
                            ]
                        },
                        {
                            "text": "gears up for his Christmas ride.",
                            "text_animation": [ 
                                {
                                    "animation": "slide-in-left",
                                    "source": "templates",
                                    "speed": 1.4,
                                    "type": "start" 
                                },
                                {
                                    "animation": "none",
                                    "source": "templates",
                                    "speed": 0.5,
                                    "type": "end" 
                                }
                            ],
                            "text_bg_animation": [
                                {
                                    "animation": "slide-in-left",
                                    "source": "templates",
                                    "speed": 1.4,
                                    "type": "start"
                                },
                                {
                                    "animation": "none",
                                    "source": "templates",
                                    "speed": 0.5,
                                    "type": "end"
                                }
                            ]
                        }
                    ],
                    "subtitle": "", //Complete subtitle text for the sub scene
                    "showSceneNumber": "Scene 1", //Scene name
                    "font": { //Subtitle font. See {{PictoryApiBaseUrl}}/video/storyboard/fonts for options
                        "name": "Arial.ttf",
                        "size": 32,
                        "line_spacing": 1.2,
                        "color": "rgba(255,255,255,255)", //Accepts rgba or hex color
                        "backcolor": "rgba(17,17,17,153)", //Accepts rgba or hex color
                        "keycolor": "rgba(226,226,170,255)", //Accepts rgba or hex color
                        "textShadowColor": "rgba(255,255,255,1)", //Accepts rgba or hex color
                        "textShadowWidthFr": 0,
                        "line_height": 55.328,
                        "case": null,
                        "decoration": [],
                        "fullWidth": false
                    }
                }
            ],
            "music": true, //Enable background music
            "tts": true, //Enable AI Text to Speech
            "subtitle": true, //Displays subtitles for scene
            "subtitles": [ //Scene subtitle text
                {
                    "text": "In the North Pole, beneath the shimmering stars, Santa Claus, with a merry twinkle in his eyes, gears up for his Christmas ride.",
                    "time": 7.368 //Subtitle display duration in seconds
                }
            ]
        },
        {} //Videos typically contain multiple scenes (scene objects) containing similar options
    ],
    "next_generation_video": true, //Default: true for Text to Video Flow
    "containsTextToImage": true //Default: true for Text to Video Flow
}'
Response Response Example
{
    "data": {
        "job_id": "45050149-0402-4b81-8664-6016349b87d5"
    },
    "success": true
}

Request

Header Params
Authorization
string 
required
Example:
{{access_token}}
X-Pictory-User-Id
string 
required
Used for logging purposes
Example:
{{X-Pictory-User-Id}}
Body Params application/json
audio
object 
required
video_volume
integer 
required
audio_id
string 
required
audio_library
string 
required
src
string 
required
track_volume
number 
required
tts
string 
required
output
object 
required
name
string 
required
description
string 
required
format
string 
required
title
string 
required
width
integer 
required
height
integer 
required
scenes
array [object {8}] 
required
background
object 
optional
time
number 
optional
keywords
array
optional
sub_scenes
array [object {7}] 
optional
music
boolean 
optional
tts
boolean 
optional
subtitle
boolean 
optional
subtitles
array [object {2}] 
optional
next_generation_video
boolean 
required
containsTextToImage
boolean 
required
Examples

Responses

🟢200/v1/video/render
application/json
Body
data
object 
required
job_id
string 
required
success
boolean 
required
Modified at 2024-07-10 08:41:40
Previous
Delete Template By Id
Next
v1/media/search
Built with