Skip to main content
POST
Script from a video

Authorizations

Authorization
string
header
required

A workspace API key.

Body

application/json
sourceUrl
string<uri>
required

The video to watch and build on. Required — this capability starts from footage.

referenceUrls
string<uri>[]

Up to twenty further sources to read while writing. Consulted, not summarised.

Maximum array length: 20
angle
string

The take to write toward, e.g. "for someone who has never invested".

Maximum string length: 500
audience
string

Who is watching. Sets vocabulary and pace.

Maximum string length: 200
niche
string

The subject area, for terminology and framing.

Maximum string length: 200
presenterName
string

Who the script is written for to say.

Maximum string length: 120
channelName
string

The channel it is for, used in the intro.

Maximum string length: 120
language
string

Output language. Defaults to English.

Maximum string length: 60
targetDurationMinutes
number

How long the finished video should run. The script is written to that length.

Required range: 1 <= x <= 60
titleOptions
integer

How many title candidates to return alongside the script.

Required range: 1 <= x <= 20
brandContext
string

Anything the writer should know about your brand: voice, claims, things to avoid.

Maximum string length: 4000
products
object[]
Maximum array length: 5
projectId
string

The project to file this work under. Optional: omit it and one is created for you, and its id comes back on the response — read it from there rather than assuming. Pass the same id across calls when you want the script, the render and the thumbnail to land in one container. A project this workspace does not own answers not_found; the work is never silently filed somewhere else.

Required string length: 1 - 200

Response

Success.

success
boolean
required
projectId
string
required

The project this work was filed under. Read it from here — a call that sent no projectId had one created, and this is where its id comes back.

Example:

"prj_9x2a4c"

credits
number
required

What this call actually cost, which is not always what was quoted.

Example:

300

script
any
required

The finished script, its title options and the claim ledger the fact-check produced.

groundingSources
any[]
required

What was consulted while writing. Empty when nothing was searched.

creditBalance
number

Your balance after the charge. Absent when billing is disabled for the workspace.

Example:

3900

{key}
any