style_options,
playback_options, autoplay_options, captions_options, chapters_options,
quiz_options, and so on, the same groups the dashboard editor writes to. This page
covers the four calls that manage them through the API: save a draft, deploy, list past
deploys, and restore one. Both need a token with videos:write.
The payload is partial, and merges by key
Send only the option groups, or the fields inside them, that you want to change. Whatever you omit is left exactly as it already is, because the server takes your payload and merges it recursively over the current settings with PHP’sarray_replace_recursive, key by key, all the way down.
background_color was never in your payload, so it survives untouched.
Your payload is filtered to the option groups the video already exposes before anything
else happens. A top-level group outside that set is dropped silently: no error, no
422, and a 200 response that looks like it worked.Five groups behave this way today and cannot be set through this API at all, even
though the validation schema accepts them: actions_options, cloak_options,
headline_options, pitch_time_options and share_options. Send any of them and you
get a 200 with nothing changed. Use the dashboard editor for those.Nested keys are not filtered. Only the top-level group name has to be one the video
already carries, which is why an option with no dashboard toggle can still be set here
as long as its group is a real one.style_options. main_color, style_options.background_color, progress_options.background_color and
progress_options.bar_color among them) are hard-required in the schema. In practice
this only bites if your existing settings somehow do not already satisfy them; a normal
partial update to unrelated fields will not trip it.
Any top-level key you send that is not a real option group is dropped silently rather
than rejected: only the option groups the video already carries are read out of your
request body, which is the same filter that drops the five groups listed above.
Save a draft
integer
required
The video’s numeric id.
object
Any subset of the option-group columns. See Get settings
for the full shape.
curl
200 OK
version is always null here: a draft never
gets a version id, only a deploy does.
Deploy
integer
required
The video’s numeric id.
object
Any subset of the option-group columns, merged the same way as
/draft, over the
video’s current live settings.string
An optional label stored on the version this call creates. Shows up in the deploys
list.
curl
200 OK
1
Merge and validate
Same partial-merge-and-validate as
/draft, but against live settings.2
Recompile the player bundle
Synchronously. This calls out to build the bundle and push it to two CDNs. It is
not queued and there is no background job id to poll: the HTTP request itself does
not return until this finishes.
3
Snapshot a version
Only after the compile and CDN push both succeed. This is what makes deploy safe:
if the bundle build or the CDN push fails, the call throws before any version is
snapshotted or marked live, and the previously live settings keep serving. You get
a
500 and nothing changed.4
Fan out
Busts the AI-segment settings cache and fires the
video.settings.deployed
webhook, {"video_id": <id>, "version_id": <id>}.embed_url is the public URL for the video’s embed page on the version
this call published.
List past deploys
integer
required
The video’s numeric id.
curl
200 OK
Every row carries its full
settings_snapshot, the complete option-group object at
that point in time, not a diff. A workspace with a long deploy history will get a
large payload back; page through it with ?page=. Only deploys and restores create a
version. Draft saves never appear here.Restore a version
integer
required
The video’s numeric id.
integer
required
A version id from the deploys list above.
curl
200 OK
settings_snapshot
back onto the video wholesale, replacing the live settings entirely, then recompiles
synchronously (same throw-before-live-marking guarantee as deploy) and snapshots a new
version labeled Restored from version 104. It does not fire a webhook.
Errors
401: INVALID_TOKEN
401: INVALID_TOKEN
The token is wrong, expired, or revoked.
403: INSUFFICIENT_SCOPE
403: INSUFFICIENT_SCOPE
All four calls need
videos:write.404
404
No video with that id (or, for restore, no version with that id on this video) in
your workspace. Laravel’s default body:
{"message": "No query results for model [App\\Models\\WorkspaceVideo] 512"}.422
422
The merged settings failed validation.
{"message": "The given data was invalid.", "errors": {"style_options.main_color": ["The style options.main color field is required."]}}. This can fire even on a small partial payload, since validation
runs on the full merged object.429
429
Rate limited. 60 writes per minute per token. Deploy’s own compile time adds to
this, so a burst of deploys is slower to clear than a burst of any other write.
500
500
Deploy or restore failed to compile or push to the CDN. No custom error code: this
is an uncaught server error. Nothing was published, the video is still serving its
previous live settings, and no version was created. Retry the call.