Template id was missing from request

Id Should not be necessary when sending a full request via Json; however, I am getting this error even when using the Studio Editor:

{
“timeline”: {
“background”: “#000000”,
“tracks”: [
{
“clips”: [
{
“fit”: “none”,
“scale”: 1,
“length”: “end”,
“asset”: {
“voice”: “Kevin”,
“text”: “Hey {{ VOICEOVER }}”,
“type”: “text-to-speech”
},
“start”: 0,
“alias”: “TTS”
}
]
},
{
“clips”: [
{
“length”: “auto”,
“asset”: {
“type”: “caption”,
“src”: “alias://TTS”,
“font”: {
“color”: “#ed0202”,
“size”: “22”
},
“background”: {
“color”: “#13d9e7
}
},
“start”: “auto”
}
]
},
{
“clips”: [
{
“length”: “end”,
“fit”: “crop”,
“asset”: {
“type”: “image-to-video”,
“src”: “{{ IMAGE_1 }}”,
“prompt”: “Slowly orbit left around the object”,
“aspectRatio”: “16:9”
},
“start”: 0
}
]
}
]
},
“output”: {
“format”: “mp4”,
“fps”: 25,
“size”: {
“width”: 720,
“height”: 1280
}
},
“merge”: [
{
“find”: “VOICEOVER”,
“replace”: “Place Holder Voice Over”
},
{
“find”: “IMAGE_1_PROMPT”,
“replace”: “Place Holder Text to Image”
},
{
“find”: “CAPTION”,
“replace”: “Place Holder Caption”
},
{
“find”: “IMAGE_1”,
“replace”: “https://inspiration.gvargas.com:4313/n2f5v2lbge_a74e9v2snc.jpg
}
]
}

Response:

{
  "success": false,
  "message": "Bad Request",
  "response": "Template id was missing from request"
}

Are you potentially using the wrong endpoint?

For requests with just the JSON payload:

POST https://api.shotstack.io/edit/v1/render

For requests with the template ID:

POST https://api.shotstack.io/edit/v1/templates/render
1 Like