Skip to content
Search Documentation
Search across all documentation pages
Videos

The Video object

A video is a hosted media asset managed by Transcodely. You give it a source — a public URL, a direct upload, or a managed transcoding job — and Transcodely transcodes it into an adaptive rendition ladder, stores the output, and serves it over a CDN with a ready-to-embed player. Each video tracks its own lifecycle, visibility, renditions, storage size, and encoding cost.

Base path: transcodely.v1.VideoService Requires: an app-scoped API key (ak_), or the X-Organization-ID header for portal sessions. Hosting does not need to be enabled first: creating a video enables it on the target app automatically, which is why the first call on a new app can take a few seconds longer. If that provisioning fails, the call returns unavailable with error code hosting_provisioning_failed and creates nothing — retry in a moment.

The fastest way in is Create a video from a URL: one call turns a public URL into a hosted, embeddable video.


Attributes

AttributeTypeDescription
idstringUnique identifier. Prefixed with vid_.
objectstringResource type discriminator. Always "video".
app_idstringParent app that owns the video. Prefixed with app_.
sourcestringHow the video was created. One of upload (direct upload or URL ingest) or job (produced by a managed transcoding job).
statusstringCurrent lifecycle status. One of uploading, processing, ready, error, archived, deleted.
visibilitystringAccess control. One of public, unlisted, private.
titlestringOptional display title. Omitted if unset.
descriptionstringOptional description. Omitted if unset.
tagsarray of stringsFree-form tags for categorization (max 20).
input_size_bytesintegerSize of the uploaded source file, in bytes. Populated after an upload is verified; absent for URL ingest.
input_content_typestringMIME type of the uploaded source file (e.g. video/mp4).
job_idstringTranscoding job that produced (or is producing) this video. Prefixed with job_.
presetstringPreset ID or slug used to drive the auto-transcode. Omitted when the app’s default auto-profile ladder is used.
playback_urlstringHLS manifest URL served over the CDN, signed with a short-lived token. Computed per request for ready videos — including private ones, which are issued only on your own authenticated reads. Absent when the app has no CDN hostname configured — see Playback, embeds, and posters.
embed_urlstringHosted player page URL, {player_base}/v/{id}. Present only for ready, non-private videos when a player base URL is configured.
embed_codestringReady-to-paste responsive <iframe> snippet (16:9, fluid width). Present under the same conditions as embed_url.
poster_urlstringPoster image URL. Same per-request rules as playback_url (see above). Absent when the video has no generated poster.
hover_preview_urlstringAnimated WebP hover-preview loop, generated when the upload requested hover previews. Absent otherwise (and absent when the source was long enough that only the MP4 loop was produced — see thumbnails). Served over the CDN, signed like playback_url.
hover_preview_mp4_urlstringMuted MP4 hover-preview loop, the companion to hover_preview_url. Absent when hover previews were not requested. Served over the CDN, signed like playback_url.
duration_secondsnumberMedia duration in seconds. Populated after processing. For a shortened video, the length of the part that was encoded.
truncationobjectPresent only when just the beginning of the source was encoded because it was longer than a limit: today, the free tier’s output-duration limit. Set as soon as the source has been measured, so a video still processing carries it. See The truncation object.
renditionsarray of objectsEncoded renditions available for playback. See The rendition object.
text_tracksarray of objectsSidecar text tracks attached to the video, such as generated captions. Auto-generated tracks list their transcript files in transcript_renditions (json, txt, md), each with a per-request signed_url. A track produced by translation carries translated_from, the language it was translated from; it is empty on recognized and customer-supplied tracks. An AI-recognized track carries cue_style, the resolved caption style its cues were cut with (the preset and all three limits); it is absent on translations, customer-supplied tracks and tracks generated before caption styles existed. A language can carry its AI captions in several styles, one track per style: style_variant names the style (compact, standard or long), is_default marks the one the player selects and translations are made from, and stale marks a track cut from older captions than the language’s latest (see Restyle captions). An AI track’s label is the English name of its language, followed by its style when it is not the default: Bulgarian and Bulgarian (compact). A caption file you attached with Attach a caption file has uploaded: true, its transcript files too, and a status: ready once it is served, processing while its upload is awaited, failed with a plain failure_message when the file was refused (or, attached while the video was processing, its cues turned out to end more than 5 seconds after the video); url and transcript_renditions are absent until it is ready. Every other track is always ready. See Transcripts & Insights.
insightsarray of objectsAI insights, one per transcript language, from the captions job that requested them or from GenerateInsights. Each moves from pending to ready or failed. A GenerateInsights entry still pending for a language that already has ready insights is listed first, ahead of the entry it will replace. If that entry fails, the ready insights stay and the failed entry is no longer listed; video.insights.failed reports it. Signed URLs are computed per request. See The TranscriptInsights object.
highlightsarray of objectsHighlight clips of the video, in the order they occur in it, from GenerateHighlights or the create-time highlights option. Each moves from pending to ready or failed. Empty until highlights are requested. A new GenerateHighlights call replaces the whole list. Signed URLs are computed per request, under the same rules as poster_url. See The highlight object.
output_size_bytesintegerTotal size of all stored renditions, in bytes.
encoding_costnumberCost of the transcoding job that produced this video, in EUR. Omitted until the job completes.
created_atstringISO 8601 timestamp.
updated_atstringISO 8601 timestamp.
ready_atstringISO 8601 timestamp of when the video reached ready. Omitted until then.
source_pinnedbooleanWhether this video’s original source file is retained. Source files are deleted when the app’s retention window ends (delete_source_after_days, 7 days after the video is ready by default); a retained source is kept until it is released or the video is deleted, and is billed as storage on the invoice line “Retained source videos”. Settable at creation and via Update a video. See the Source Lifecycle guide.
source_expires_atstringISO 8601 timestamp of when the original source will be deleted: the scheduled time once a deletion is scheduled, otherwise the video’s ready time plus the app’s retention window, and never sooner than 72 hours from now. Absent when the source is retained, already deleted, or not subject to retention (the video is not ready, or has no stored source). Read-only.
source_scheduled_for_deletion_atstringISO 8601 timestamp of when the original source is scheduled to be deleted. Present only once a deletion has been scheduled, at least 72 hours ahead, with the video.source_scheduled_for_deletion webhook; cleared on retain, on a retention window change, and on delete. Read-only.
source_deleted_atstringISO 8601 timestamp of when the original source was deleted. Set exactly once — the authoritative “source is gone” signal. Re-processing can then only use a progressive (single-file) rendition; a video with only HLS/DASH renditions needs its source uploaded again. Read-only.
guide_pagestringThis video’s own guide page setting. One of default (follow the app’s hosting_config.guide_pages_enabled, so a later change to the app default moves this video too), on or off. Always present, webhook payloads included. Set it with Update a video.
guide_page_enabledbooleanThe effective guide page setting: true when guide_page is on, false when it is off, and the app’s hosting_config.guide_pages_enabled (unset meaning false) when it is default. Server-set; present on every VideoService response and absent in video.* webhook payloads — see Webhook events.
guide_urlstringThe guide page URL, {player_base}/v/{id}/guide. Present only when the page would render: guide_page_enabled is true, the video is ready and not private (the embed_url rule), and it has ready insights or a generated transcript to show. Durable: it never expires.
{
  "id": "vid_a1b2c3d4e5f6g7",
  "object": "video",
  "app_id": "app_k1l2m3n4o5",
  "source": "upload",
  "status": "ready",
  "visibility": "public",
  "title": "Product demo",
  "description": "Q3 product walkthrough",
  "tags": ["marketing", "demo"],
  "input_size_bytes": 132710400,
  "input_content_type": "video/mp4",
  "job_id": "job_a1b2c3d4e5f6",
  "preset": "web_1080p_standard",
  "playback_url": "https://cdn.example.com/vid_a1b2c3d4e5f6g7/hls/master.m3u8",
  "embed_url": "https://play.transcodely.com/v/vid_a1b2c3d4e5f6g7",
  "embed_code": "<div style="position:relative;padding-top:56.25%"><iframe src="https://play.transcodely.com/v/vid_a1b2c3d4e5f6g7" title="Product demo" loading="lazy" style="position:absolute;inset:0;width:100%;height:100%;border:0" allow="autoplay; fullscreen; picture-in-picture" allowfullscreen></iframe></div>",
  "poster_url": "https://cdn.example.com/vid_a1b2c3d4e5f6g7/hls/poster.jpg",
  "duration_seconds": 128.5,
  "renditions": [
    { "id": "ren_a1b2c3d4e5f6g7", "resolution": "1080p", "codec": "h264", "bitrate_kbps": 5000, "width": 1920, "height": 1080, "size_bytes": 80530636 },
    { "id": "ren_b2c3d4e5f6g7h8", "resolution": "720p", "codec": "h264", "bitrate_kbps": 2800, "width": 1280, "height": 720, "size_bytes": 45088768 }
  ],
  "output_size_bytes": 125619404,
  "encoding_cost": 0.03,
  "created_at": "2026-05-24T10:00:00Z",
  "updated_at": "2026-05-24T10:03:30Z",
  "ready_at": "2026-05-24T10:03:30Z",
  "guide_page": "default",
  "guide_page_enabled": false
}

Statuses

StatusDescription
uploadingA presigned upload URL has been issued and the file has not been finalized yet.
processingThe source (uploaded file or ingested URL) is being probed and transcoded.
readyTranscoding finished and the video is available for playback.
errorProcessing failed. The video is not playable.
archivedNot actively served; storage is retained.
deletedSoft-deleted and pending storage cleanup.

uploading, processing, and archived are non-terminal; ready, error, and deleted are terminal.

Visibility

Visibility controls who can reach a ready video. It defaults to unlisted when omitted, and can be changed any time with Update a video.

ValueDescription
publicAnyone with the playback or embed URL can watch.
unlistedReachable only via its direct URL; not surfaced in any public index.
privateOff the public player and embed — the player page returns 404 and embed_url/embed_code are never issued, even after ready. playback_url and poster_url are returned on the owning app’s authenticated reads (Get/List/Watch), always signed and time-limited; an unsigned URL is never issued for a private video. If the app’s CDN zone has no signing key, both fields are absent rather than unsigned — see Playback, embeds, and posters.

Sources

SourceDescription
uploadCreated via Create a video from a URL, CreateUpload, or CreateMultipartUpload and transcoded automatically.
jobCreated by a managed transcoding job — see ingesting from a storage origin.

The truncation object

A hosted video on an organization with no usable payment method (the free tier) whose source is longer than the free tier’s output-duration limit, 2 minutes, is encoded as its first 2 minutes instead of failing. The renditions, poster, thumbnails, hover previews, captions, transcript and insights all cover that part, and duration_seconds is its length. truncation says so:

AttributeTypeDescription
reasonstringWhy the source was shortened. Always free_tier_limit today.
source_duration_secondsnumberLength of the whole source, in seconds, as measured when it was read.
encoded_duration_secondsnumberLength of the part that was encoded, counted from the start of the source. Always less than source_duration_seconds.
{
  "id": "vid_a1b2c3d4e5f6g7",
  "object": "video",
  "status": "ready",
  "duration_seconds": 120,
  "truncation": {
    "reason": "free_tier_limit",
    "source_duration_seconds": 330.1,
    "encoded_duration_seconds": 120
  }
}

Adding a payment method lifts the limit for videos uploaded afterwards; a video already shortened stays shortened, so add a payment method and upload the file again to get all of it. Only hosted videos are shortened (uploads, Create a video from a URL, the CLI’s upload, the MCP create_video_from_url tool, bulk-import items). A job that long is refused with output_duration_limit_exceeded, and so is a hosted video on an account limited for an unpaid invoice or over a duration limit of its plan.

If the shortened processing fails, the video is error and keeps truncation, which then describes the processing that was attempted. A job you create with input_video_id on a shortened video reads the whole original file, like any job you create; to keep it to the part the video covers (for example to caption it), send clip with start_seconds: 0 and end_seconds set to encoded_duration_seconds.

The rendition object

Each rendition is one encoded variant produced by the transcode. A ready video’s renditions array is its adaptive ladder.

FieldTypeDescription
idstringUnique identifier. Prefixed with ren_.
resolutionstringResolution label (e.g. 1080p, 720p).
codecstringVideo codec (e.g. h264, h265).
bitrate_kbpsintegerAverage bitrate in kilobits per second.
widthintegerFrame width in pixels.
heightintegerFrame height in pixels.
size_bytesintegerEncoded size of this rendition, in bytes.

Playback, embeds, and posters

Playback and embed fields are computed per request — never stored on the video. playback_url and poster_url are returned for any ready video, private included. embed_url and embed_code are the public surface and are returned only for ready, non-private videos. All four are absent while the video is uploading/processing or in error.

playback_url and poster_url are signed and time-limited — BunnyCDN HS256 directory tokens, valid ~6 hours by default. Signing is a property of the CDN zone, not of the video: token auth is all-or-nothing per zone, so every URL the API hands out is signed, whatever the visibility. A raw, unsigned CDN link is rejected at the edge. Because the token expires and each response mints a fresh one, always play the value from the latest Get/List/Watch response rather than caching it.

For private videos the URLs are issued only on the owning app’s authenticated reads, and an unsigned URL is never issued for them at all — an unsigned URL is uncontrolled once handed out. If a zone has no usable signing key, playback_url and poster_url come back absent rather than unsigned, so a private video is never downgraded to open delivery.

Signing controls delivery, not discovery: what keeps a private video off the open web is the player 404 and the withheld embed_url/embed_code, not the token on the URL. Treat a signed URL as a short-lived capability — anyone holding it can play that video until it expires.

FieldDepends onWhat it is
playback_urlready video + a CDN hostname and signing key on the app; for private, also your own authenticated readHLS manifest (.../hls/master.m3u8) served over the CDN, signed with a ~6-hour token.
poster_urlready video that has a generated poster, same app conditions as playback_urlPoster image URL. Same rules as playback_url (see above). Absent when the video has no poster.
embed_urlready, non-private video + a player base URL configuredThe hosted player page: {player_base}/v/{video_id}.
embed_codesame as embed_urlA responsive iframe you can paste into any page.
guide_urlsame as embed_url, plus guide_page_enabled and ready insights or a generated transcriptThe hosted guide page: {player_base}/v/{video_id}/guide. Durable, never signed.

The embed snippet is a responsive 16:9 wrapper — it scales to the container’s width rather than a fixed size, and the title (the video’s title, or Video player when unset) names the iframe for accessibility:

<div style="position:relative;padding-top:56.25%"><iframe
  src="https://play.transcodely.com/v/vid_a1b2c3d4e5f6g7"
  title="Product demo" loading="lazy"
  style="position:absolute;inset:0;width:100%;height:100%;border:0"
  allow="autoplay; fullscreen; picture-in-picture"
  allowfullscreen></iframe></div>

If you only have the video ID and a player base URL, you can construct the embed URL yourself as {player_base}/v/{video_id} — it is the same value the API returns in embed_url.

The hosted player

The player page serves one player for every video: HLS through a pinned hls.js release loaded with Subresource Integrity, the video’s caption tracks, and its AI chapters on the seek bar when the video has ready insights. Caption tracks are listed once per language, with the label you gave the track or, when it has none, the language in its own words (bul shows as Български); the first sidecar track is on by default. On Apple devices the control bar carries an AirPlay button. When the video has a caption track, a transcript drawer opens from the control bar: a searchable transcript built from the track’s JSON transcript rendition, every sentence seeking the player when clicked (apps whose CDN zone does not yet serve .json with CORS get the caption file’s cues instead of word timings). The page honours the URL flags and the message API below.


Embed API

The hosted player can be driven from the page that embeds it, over postMessage, without reloading the iframe: seek to a transcript timestamp, play or pause, switch captions, and follow playback state. The player page also honours a few URL parameters on load; the message API is what you use once the frame is already on the page.

URL parameters (on embed_url, combinable):

ParameterWhat it does
t=SECONDS (or #t=SECONDS)Starts playback at that second.
autoplay=1Starts playing as soon as the media can play — always muted, because browsers refuse audible autoplay without a gesture on your page. Unmute with transcodely:unmute after the viewer interacts, or leave it to the player’s own button.
muted=1Starts muted.
loop=1Restarts from the beginning when playback ends.

Each flag is on for 1 or true and off otherwise. autoplay, muted and loop are reported back in every transcodely:state message.

Send commands with iframe.contentWindow.postMessage(message, 'https://play.transcodely.com') (use your own player base URL if it differs). Every message is a plain object with a type that starts with transcodely:. Anything else is ignored, and so is every message that does not come from the page that embeds the player: another frame on your page cannot drive it.

Commands (page → player):

MessageFieldsWhat it does
transcodely:seekseconds (number)Seeks to that second. Safe to send before the player is ready: the seek is applied once the media loads. A second past the end seeks to the end.
transcodely:playStarts playback. Subject to the browser’s autoplay policy: without a prior user gesture on your page, unmuted playback may be refused.
transcodely:pausePauses.
transcodely:mute / transcodely:unmuteMutes / unmutes.
transcodely:captionslanguage (string or null)Shows the caption track with that language code (as listed in transcodely:ready), or turns captions off with null. An unknown language changes nothing.
transcodely:get-stateAsks for a transcodely:state message, sent back to the requesting window.

Events (player → page). Listen with window.addEventListener('message', …) and check event.origin against your player base URL. Unsolicited events are posted to the parent frame; the reply to transcodely:get-state goes to the window that asked.

MessageFieldsWhen
transcodely:readyvideoId, duration (seconds), captions (array of { language, label })When the player can play: once per page load, and again if the player recovers after a transcodely:error. Commands sent earlier are not lost, but this is the signal that they will apply immediately from now on.
transcodely:statevideoId, currentTime, duration, paused, playing, ended, muted, autoplay, loop, captions (the showing track’s language, or null)On play, pause, end, seek, volume or caption changes, in reply to transcodely:get-state, and during playback at most every 250 ms.
transcodely:errorvideoId, codeWhen playback gives up. expired: the signed playback URL is no longer accepted — reload the iframe for a fresh one. load_failed: the media could not be loaded for another reason (a blocked delivery network, a dropped connection).

A transcript whose timestamps drive the embedded player:

const frame = document.querySelector('iframe');
const PLAYER = 'https://play.transcodely.com';
let ready = false;

window.addEventListener('message', (event) => {
  if (event.origin !== PLAYER || event.source !== frame.contentWindow) return;
  if (event.data.type === 'transcodely:ready') ready = true;
  if (event.data.type === 'transcodely:state') console.warn('at', event.data.currentTime);
});

function jumpTo(seconds) {
  if (!ready) { frame.src = `${PLAYER}/v/vid_a1b2c3d4e5f6g7?t=${seconds}`; return; }
  frame.contentWindow.postMessage({ type: 'transcodely:seek', seconds }, PLAYER);
  frame.contentWindow.postMessage({ type: 'transcodely:play' }, PLAYER);
}

The commands can do nothing a viewer could not do with the player’s own controls, and the events carry only playback state, so the player accepts commands from any embedding origin — there is no allow-list to configure.


Guide pages

A guide page is a hosted, shareable page per video at {player_base}/v/{video_id}/guide: the same player on top, the video’s AI insights as cards (summary, chapters, key points, questions it covers, highlights, terms, topics) and the full transcript with timestamps that seek the in-page player. It exists only for a ready video that is public or unlisted and has ready insights or a generated transcript; a private video never gets one, and a page with nothing to show answers 404. It is off until you turn it on.

Two settings decide it:

  • The app default: hosting_config.guide_pages_enabled on Update hosting configuration. Unset means false.
  • The video’s own setting: guide_page, set with Update a video. default follows the app default (and keeps following it when the default changes later); on and off pin the video whatever the app says.

guide_page_enabled on the video is the resolved value, and guide_url is issued only when the page would actually render. Turning a page off can take up to five minutes to show through a shared cache: public pages are served with Cache-Control: public, max-age=300, unlisted ones are never cached.

The page is in the language of the caption track. ?lang=<iso639-2> picks among the languages that have ready insights or a generated transcript; a language switcher appears when there is more than one, and each language is an hreflang alternate. Public pages carry Open Graph tags and, when the video has chapters, the same schema.org VideoObject JSON-LD as the player page, with the chapters as key moments linking back to the guide at ?t=SECONDS; unlisted pages carry noindex. Plays started from the guide count in playback analytics like any other play; opening the page is not counted as a view. The MCP get_video tool returns guide_page, guide_page_enabled and playback.guide_url under the same rules.

# Turn guide pages on for every video in the app that is not pinned off
curl -X POST https://api.transcodely.com/transcodely.v1.AppService/UpdateHostingConfig 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{"id": "app_k1l2m3n4o5", "hosting_config": {"guide_pages_enabled": true}}'

# Pin one video off, whatever the app default says
curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/Update 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{"id": "vid_a1b2c3d4e5f6g7", "guide_page": "off"}'

Hover previews

Set hover_previews: true on any upload call — CreateFromUrl, CreateUpload, or CreateMultipartUpload — to generate a short animated preview for the video, ideal for hover-to-play cards in a grid. It is free: hover previews are an animated thumbnail under the hood, and thumbnails add no cost.

When enabled, the API attaches an animated thumbnail spec with smart defaults (a ~4-second loop, 12 fps, 320 px wide) to the hosted transcode. Once processing finishes, the produced loops surface on the video as hover_preview_url (the animated WebP) and hover_preview_mp4_url (the muted MP4). Either may be absent — for example the WebP is skipped for loops longer than 10 seconds, leaving the video MP4-only.

To tune the loop — duration, fps, width, or explicit sample offsets — drive a managed job with an explicit animated thumbnails spec instead of the boolean shortcut.


Create a video from a URL

POST /transcodely.v1.VideoService/CreateFromUrl

The one-call path: hand Transcodely a publicly-reachable http(s) URL and it creates a hosted video, fetches and transcodes the source, and makes it embeddable — no upload handshake. The video is created directly in processing; the worker downloads the URL at transcode time (the API never fetches it). Playback and embed URLs populate once it reaches ready, which you learn via video.ready or Watch.

Only http:// and https:// URLs are accepted. Storage-origin schemes (gs://, s3://) are rejected here — ingest those from a storage origin instead. Private/internal addresses are rejected up front and again, authoritatively, when the worker fetches (SSRF defense).

Because no bytes are uploaded, no video.uploaded event fires for URL ingest — the video.ready / video.failed events cover the outcome.

ParameterTypeRequiredDescription
app_idstringYesApp to create the video under (app_ prefix). Must have hosting enabled.
urlstringYesPublic http(s) source URL (max 2048 chars).
titlestringNoDisplay title (max 255 chars).
descriptionstringNoDescription (max 2000 chars).
tagsarrayNoUp to 20 tags.
visibilitystringNopublic, unlisted, or private. Defaults to unlisted.
presetstringNoPreset ID or slug to drive the transcode. Defaults to the app’s auto-profile ladder.
hover_previewsbooleanNoWhen true, generate free animated hover previews — a WebP loop plus a muted MP4 — for the hosted video. Defaults to false.
auto_captionsbooleanNoWhen true, generate AI captions inline with the transcode: the managed job’s output carries a generated WebVTT subtitle track (language auto-detected), produced by the same job and on the same worker as the encode, and listed in the streaming manifest so players discover it natively. The track surfaces in text_tracks once ready. Free: the video is hosted with Transcodely, so the job’s captions fee row is written at €0 (a transcode-only job pays €0.01 per source minute). Defaults to false. See AI captions.
auto_insightsbooleanNoWhen true, also run AI insights over the inline captions: summary, key points, chapters, questions, key terms, highlights and topics. Requires auto_captions: true; rejected with invalid_argument otherwise. Billed as the insights + insights_job fees on the transcode job (list price €0.05 per video + €0.005 per source minute), on top of the captions fee. Rejected with parameter_unsupported on deployments that do not run insights. Defaults to false.
auto_translationsarray of stringsNoAlso translate the inline AI captions into these languages: ISO 639-2 codes, at most 10, distinct. Requires auto_captions: true; rejected with invalid_argument, code parameter_incompatible, otherwise. Each language gets its own caption track, transcript files and, on HLS, a caption rendition; with auto_insights the insights are translated too. Billed as the captions_translation fee: €0.02 per source minute per delivered language (minimum €0.05 per video per language) at list price. The caption text (never the audio or video) is sent to Anthropic. See Translating captions.
highlightsobjectNoCut highlight clips automatically once the video’s AI insights are ready: {"enabled": true}, plus optional max_count, min_seconds, max_seconds and padding_seconds (see HighlightsConfig). Requires auto_insights: true; rejected with invalid_argument, code parameter_incompatible, otherwise. Billed as the clips’ rendered minutes only. If the cut is refused (a spend limit, no usable moment, …), highlights gets one failed entry carrying the refusal’s code and video.highlights.failed fires. Omitted or enabled: false: no automatic highlights.
cue_styleobjectNoHow the inline AI captions are cut into cues: preset (compact, standard or long) and optional max_chars_per_line (20 to 60), max_lines (1 to 3) and max_cue_duration_ms (2000 to 10000). See Caption style. Omitted: the app’s default cue_style, else standard. Requires auto_captions: true; rejected with invalid_argument, code parameter_incompatible, otherwise. No effect on pricing.
source_pinnedbooleanNoRetain the original source file from the start, exactly as setting source_pinned later would. Source files are otherwise deleted when the app’s retention window ends (7 days after the video is ready by default). A retained source is kept until it is released or the video is deleted, and is billed as storage on the invoice line “Retained source videos”. Omitted or false: the source is temporary and not billed. See Source Lifecycle.

Returns

Returns the created Video in processing status. Poll Get, or Watch/subscribe to video.ready, then use its embed_url.

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/CreateFromUrl 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{
    "app_id": "app_k1l2m3n4o5",
    "url": "https://example.com/source/product-demo.mp4",
    "title": "Product demo",
    "visibility": "public"
  }'
{
  "video": {
    "id": "vid_a1b2c3d4e5f6g7",
    "object": "video",
    "app_id": "app_k1l2m3n4o5",
    "source": "upload",
    "status": "processing",
    "visibility": "public",
    "title": "Product demo",
    "tags": [],
    "output_size_bytes": 0,
    "created_at": "2026-05-24T10:00:00Z",
    "updated_at": "2026-05-24T10:00:00Z"
  }
}

SDK support: typed one-call helpers for URL ingest are on the way. Until the SDK releases publish, call the CreateFromUrl endpoint directly with any Connect/JSON client (as above). The Get and Watch follow-ups below are already available in the SDKs.

Wait for the video to become playable, then embed it:

// Poll until ready, then use the embed snippet.
for await (const event of client.videos.watch("vid_a1b2c3d4e5f6g7")) {
  if (event.eventType === "completed") break;
}
const video = await client.videos.get("vid_a1b2c3d4e5f6g7");
// embedCode is only issued for `public`/`unlisted` videos once they are ready.
if (video.status === "ready" && video.embedCode) {
  document.body.insertAdjacentHTML("beforeend", video.embedCode);
}
for event in client.videos.watch("vid_a1b2c3d4e5f6g7"):
    if event.event_type == "completed":
        break
video = client.videos.get("vid_a1b2c3d4e5f6g7")
if video.status == "ready":
    print(video.embed_url)
stream := client.Videos.Watch(ctx, "vid_a1b2c3d4e5f6g7")
defer stream.Close()
for stream.Next() {
    if stream.Current().GetEventType() == "completed" {
        break
    }
}
video, err := client.Videos.Get(ctx, "vid_a1b2c3d4e5f6g7")

From a storage origin

CreateFromUrl only accepts http(s) URLs. To ingest from a storage origin (gs://, s3://) into managed hosting, create a managed transcoding job with JobService.Create and set managed: true. The job writes its output to managed hosting and creates a source: "job" video; the create response carries a top-level video_id.

curl -X POST https://api.transcodely.com/transcodely.v1.JobService/Create 
  -H "Authorization: Bearer ak_abc123" 
  -H "X-Organization-ID: org_f6g7h8i9j0" 
  -H "Content-Type: application/json" 
  -d '{
    "input_url": "gs://my-bucket/source/product-demo.mp4",
    "managed": true,
    "outputs": [
      {
        "type": "hls",
        "video": [
          {"codec": "h264", "resolution": "1080p", "quality": "standard"},
          {"codec": "h264", "resolution": "720p", "quality": "standard"}
        ]
      }
    ]
  }'
{
  "job": {
    "id": "job_a1b2c3d4e5f6",
    "object": "job",
    "status": "pending"
  },
  "video_id": "vid_a1b2c3d4e5f6g7"
}

Upload a video

When your source is a local file rather than a URL, upload it directly. The two-step handshake sends the bytes straight from your client to storage, never through the API:

  1. Call CreateUpload to reserve a vid_ record and get a presigned PUT URL.
  2. PUT the file to that URL.
  3. Call CompleteUpload to verify the bytes landed and kick off transcoding.

Use this single-part flow for files up to roughly 100 MB. For anything larger — or when you want resumable, parallel part uploads — use the multipart flow instead. The hard ceiling for either flow is 5 GB.

Create an upload

POST /transcodely.v1.VideoService/CreateUpload

Reserves a video (status uploading) and returns a time-limited presigned URL. PUT your file to upload_url before upload_expires_at (about one hour).

ParameterTypeRequiredDescription
app_idstringYesApp to create the video under (app_ prefix). Must have hosting enabled.
filenamestringYesOriginal filename (1–255 chars). Used for content-type detection and display.
content_typestringYesMIME type of the file (e.g. video/mp4).
size_bytesintegerYesFile size in bytes (1–5368709120, i.e. up to 5 GB).
titlestringNoDisplay title (max 255 chars).
descriptionstringNoDescription (max 2000 chars).
tagsarrayNoUp to 20 tags.
visibilitystringNopublic, unlisted, or private. Defaults to unlisted.
presetstringNoPreset ID or slug to drive the auto-transcode. Defaults to the app’s auto-profile ladder.
hover_previewsbooleanNoWhen true, generate free animated hover previews — a WebP loop plus a muted MP4 — for the hosted video. Defaults to false.
auto_captionsbooleanNoWhen true, generate AI captions inline with the transcode: the managed job’s output carries a generated WebVTT subtitle track (language auto-detected), produced by the same job and on the same worker as the encode, and listed in the streaming manifest so players discover it natively. The track surfaces in text_tracks once ready. Free: the video is hosted with Transcodely, so the job’s captions fee row is written at €0 (a transcode-only job pays €0.01 per source minute). Defaults to false. See AI captions.
auto_insightsbooleanNoWhen true, also run AI insights over the inline captions: summary, key points, chapters, questions, key terms, highlights and topics. Requires auto_captions: true; rejected with invalid_argument otherwise. Billed as the insights + insights_job fees on the transcode job (list price €0.05 per video + €0.005 per source minute), on top of the captions fee. Rejected with parameter_unsupported on deployments that do not run insights. Defaults to false.
auto_translationsarray of stringsNoAlso translate the inline AI captions into these languages: ISO 639-2 codes, at most 10, distinct. Requires auto_captions: true; rejected with invalid_argument, code parameter_incompatible, otherwise. Each language gets its own caption track, transcript files and, on HLS, a caption rendition; with auto_insights the insights are translated too. Billed as the captions_translation fee: €0.02 per source minute per delivered language (minimum €0.05 per video per language) at list price. The caption text (never the audio or video) is sent to Anthropic. See Translating captions.
highlightsobjectNoCut highlight clips automatically once the video’s AI insights are ready: {"enabled": true}, plus optional max_count, min_seconds, max_seconds and padding_seconds (see HighlightsConfig). Requires auto_insights: true; rejected with invalid_argument, code parameter_incompatible, otherwise. Billed as the clips’ rendered minutes only. If the cut is refused (a spend limit, no usable moment, …), highlights gets one failed entry carrying the refusal’s code and video.highlights.failed fires. Omitted or enabled: false: no automatic highlights.
cue_styleobjectNoHow the inline AI captions are cut into cues: preset (compact, standard or long) and optional max_chars_per_line (20 to 60), max_lines (1 to 3) and max_cue_duration_ms (2000 to 10000). See Caption style. Omitted: the app’s default cue_style, else standard. Requires auto_captions: true; rejected with invalid_argument, code parameter_incompatible, otherwise. No effect on pricing.
source_pinnedbooleanNoRetain the original source file from the start, exactly as setting source_pinned later would. Source files are otherwise deleted when the app’s retention window ends (7 days after the video is ready by default). A retained source is kept until it is released or the video is deleted, and is billed as storage on the invoice line “Retained source videos”. Omitted or false: the source is temporary and not billed. See Source Lifecycle.

Returns

Returns the created Video (status uploading), the presigned upload_url, and upload_expires_at.

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/CreateUpload 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{
    "app_id": "app_k1l2m3n4o5",
    "filename": "product-demo.mp4",
    "content_type": "video/mp4",
    "size_bytes": 132710400,
    "title": "Product demo",
    "visibility": "public"
  }'
const { video, uploadUrl } = await client.videos.createUpload({
  appId: "app_k1l2m3n4o5",
  filename: "product-demo.mp4",
  contentType: "video/mp4",
  sizeBytes: 132710400n,
  title: "Product demo",
  visibility: "public",
});

// Upload the bytes straight to storage.
await fetch(uploadUrl, {
  method: "PUT",
  headers: { "Content-Type": "video/mp4" },
  body: fileBlob,
});
res = client.videos.create_upload(
    app_id="app_k1l2m3n4o5",
    filename="product-demo.mp4",
    content_type="video/mp4",
    size_bytes=132710400,
    title="Product demo",
    visibility="public",
)

with open("product-demo.mp4", "rb") as f:
    requests.put(res.upload_url, data=f, headers={"Content-Type": "video/mp4"})
res, err := client.Videos.CreateUpload(ctx, &transcodely.UploadCreateParams{
    AppId:       "app_k1l2m3n4o5",
    Filename:    "product-demo.mp4",
    ContentType: "video/mp4",
    SizeBytes:   132710400,
    Title:       proto.String("Product demo"),
    Visibility:  proto.String("public"),
})
// PUT the file bytes to res.GetUploadUrl().
{
  "video": {
    "id": "vid_a1b2c3d4e5f6g7",
    "object": "video",
    "app_id": "app_k1l2m3n4o5",
    "source": "upload",
    "status": "uploading",
    "visibility": "public",
    "title": "Product demo",
    "tags": [],
    "input_content_type": "video/mp4",
    "output_size_bytes": 0,
    "created_at": "2026-05-24T10:00:00Z",
    "updated_at": "2026-05-24T10:00:00Z"
  },
  "upload_url": "https://storage.example.com/uploads/vid_a1b2c3d4e5f6g7?X-Amz-Signature=...",
  "upload_expires_at": "2026-05-24T11:00:00Z"
}

Complete the upload

POST /transcodely.v1.VideoService/CompleteUpload

Signals that the PUT finished. Transcodely verifies the object exists, transitions the video to processing, and creates the auto-transcode job. This is when the video.uploaded webhook fires.

ParameterTypeRequiredDescription
idstringYesVideo ID from CreateUpload.

Returns

Returns the completion response, which carries the Video with status transitioned to processing. The TypeScript and Python SDKs hand you that response envelope — read .video off it. The Go SDK unwraps it for you and returns the Video directly.

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/CompleteUpload 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{"id": "vid_a1b2c3d4e5f6g7"}'
const res = await client.videos.completeUpload({ id: "vid_a1b2c3d4e5f6g7" });
const video = res.video;
res = client.videos.complete_upload(id="vid_a1b2c3d4e5f6g7")
video = res.video
video, err := client.Videos.CompleteUpload(ctx, &transcodely.UploadCompleteParams{
    Id: "vid_a1b2c3d4e5f6g7",
})
{
  "video": {
    "id": "vid_a1b2c3d4e5f6g7",
    "object": "video",
    "app_id": "app_k1l2m3n4o5",
    "source": "upload",
    "status": "processing",
    "visibility": "public",
    "title": "Product demo",
    "tags": [],
    "input_size_bytes": 132710400,
    "input_content_type": "video/mp4",
    "job_id": "job_a1b2c3d4e5f6",
    "output_size_bytes": 0,
    "created_at": "2026-05-24T10:00:00Z",
    "updated_at": "2026-05-24T10:00:30Z"
  }
}

To follow the video from here to ready, Watch it, poll Get, or subscribe to video.ready.


Upload large files with multipart

Multipart uploads split a file into parts (25 MB each by default, 5 MB minimum except the last part) that upload in parallel and can be retried individually. Use it for large files, flaky networks, or resumable upload UIs. The flow:

  1. CreateMultipartUpload — reserves the video and returns an upload_id plus presigned URLs for the first batch of parts (up to 50).
  2. GetUploadPartUrls — fetch URLs for later parts, or refresh expired ones (up to 100 per call).
  3. PUT each part and keep the ETag response header for each.
  4. CompleteMultipartUpload — submit every part’s ETag to assemble the file and start processing.
  5. AbortMultipartUpload — cancel instead; this discards the parts and deletes the video record.

Start a multipart upload

POST /transcodely.v1.VideoService/CreateMultipartUpload
ParameterTypeRequiredDescription
app_idstringYesApp to create the video under. Must have hosting enabled.
filenamestringYesOriginal filename (1–255 chars).
content_typestringYesMIME type of the file.
size_bytesintegerYesFile size in bytes (up to 5 GB).
total_partsintegerYesNumber of parts, ceil(size_bytes / part_size_bytes) (1–10000).
part_size_bytesintegerNoBytes per part. Defaults to 25 MB; minimum 5 MB.
titlestringNoDisplay title.
descriptionstringNoDescription.
tagsarrayNoUp to 20 tags.
visibilitystringNopublic, unlisted, or private. Defaults to unlisted.
presetstringNoPreset ID or slug to drive the auto-transcode.
hover_previewsbooleanNoWhen true, generate free animated hover previews — a WebP loop plus a muted MP4 — for the hosted video. Defaults to false.
auto_captionsbooleanNoWhen true, generate AI captions inline with the transcode: the managed job’s output carries a generated WebVTT subtitle track (language auto-detected), produced by the same job and on the same worker as the encode, and listed in the streaming manifest so players discover it natively. The track surfaces in text_tracks once ready. Free: the video is hosted with Transcodely, so the job’s captions fee row is written at €0 (a transcode-only job pays €0.01 per source minute). Defaults to false. See AI captions.
auto_insightsbooleanNoWhen true, also run AI insights over the inline captions: summary, key points, chapters, questions, key terms, highlights and topics. Requires auto_captions: true; rejected with invalid_argument otherwise. Billed as the insights + insights_job fees on the transcode job (list price €0.05 per video + €0.005 per source minute), on top of the captions fee. Rejected with parameter_unsupported on deployments that do not run insights. Defaults to false.
auto_translationsarray of stringsNoAlso translate the inline AI captions into these languages: ISO 639-2 codes, at most 10, distinct. Requires auto_captions: true; rejected with invalid_argument, code parameter_incompatible, otherwise. Each language gets its own caption track, transcript files and, on HLS, a caption rendition; with auto_insights the insights are translated too. Billed as the captions_translation fee: €0.02 per source minute per delivered language (minimum €0.05 per video per language) at list price. The caption text (never the audio or video) is sent to Anthropic. See Translating captions.
highlightsobjectNoCut highlight clips automatically once the video’s AI insights are ready: {"enabled": true}, plus optional max_count, min_seconds, max_seconds and padding_seconds (see HighlightsConfig). Requires auto_insights: true; rejected with invalid_argument, code parameter_incompatible, otherwise. Billed as the clips’ rendered minutes only. If the cut is refused (a spend limit, no usable moment, …), highlights gets one failed entry carrying the refusal’s code and video.highlights.failed fires. Omitted or enabled: false: no automatic highlights.
cue_styleobjectNoHow the inline AI captions are cut into cues: preset (compact, standard or long) and optional max_chars_per_line (20 to 60), max_lines (1 to 3) and max_cue_duration_ms (2000 to 10000). See Caption style. Omitted: the app’s default cue_style, else standard. Requires auto_captions: true; rejected with invalid_argument, code parameter_incompatible, otherwise. No effect on pricing.
source_pinnedbooleanNoRetain the original source file from the start, exactly as setting source_pinned later would. Source files are otherwise deleted when the app’s retention window ends (7 days after the video is ready by default). A retained source is kept until it is released or the video is deleted, and is billed as storage on the invoice line “Retained source videos”. Omitted or false: the source is temporary and not billed. See Source Lifecycle.

Returns

Returns the Video (status uploading), the S3 upload_id, the first batch of presigned part URLs, and urls_expire_at.

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/CreateMultipartUpload 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{
    "app_id": "app_k1l2m3n4o5",
    "filename": "conference-recording.mp4",
    "content_type": "video/mp4",
    "size_bytes": 2147483648,
    "total_parts": 82
  }'
const res = await client.videos.createMultipartUpload({
  appId: "app_k1l2m3n4o5",
  filename: "conference-recording.mp4",
  contentType: "video/mp4",
  sizeBytes: 2147483648n,
  totalParts: 82,
});

// res.parts holds the first 50 presigned URLs; fetch the rest with getUploadPartUrls.
res = client.videos.create_multipart_upload(
    app_id="app_k1l2m3n4o5",
    filename="conference-recording.mp4",
    content_type="video/mp4",
    size_bytes=2147483648,
    total_parts=82,
)
res, err := client.Videos.CreateMultipartUpload(ctx, &transcodely.MultipartCreateParams{
    AppId:       "app_k1l2m3n4o5",
    Filename:    "conference-recording.mp4",
    ContentType: "video/mp4",
    SizeBytes:   2147483648,
    TotalParts:  82,
})
{
  "video": {
    "id": "vid_c3d4e5f6g7h8i9",
    "object": "video",
    "app_id": "app_k1l2m3n4o5",
    "source": "upload",
    "status": "uploading",
    "visibility": "unlisted",
    "tags": [],
    "input_content_type": "video/mp4",
    "output_size_bytes": 0,
    "created_at": "2026-05-24T10:00:00Z",
    "updated_at": "2026-05-24T10:00:00Z"
  },
  "upload_id": "a1b2c3d4e5f6-multipart-session-0d1e2f",
  "parts": [
    { "part_number": 1, "upload_url": "https://storage.example.com/...part=1&sig=..." },
    { "part_number": 2, "upload_url": "https://storage.example.com/...part=2&sig=..." }
  ],
  "urls_expire_at": "2026-05-24T11:00:00Z"
}

Fetch more part URLs

POST /transcodely.v1.VideoService/GetUploadPartUrls

Request fresh presigned URLs for specific part numbers — for parts beyond the first batch, or to refresh URLs that expired mid-upload.

ParameterTypeRequiredDescription
idstringYesVideo ID from CreateMultipartUpload.
upload_idstringYesThe upload_id from CreateMultipartUpload.
part_numbersarrayYes1-based part numbers to sign (1–100 per call).

Returns

Returns presigned URLs for the requested parts and urls_expire_at.

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/GetUploadPartUrls 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{
    "id": "vid_c3d4e5f6g7h8i9",
    "upload_id": "a1b2c3d4e5f6-multipart-session-0d1e2f",
    "part_numbers": [51, 52, 53]
  }'
{
  "parts": [
    { "part_number": 51, "upload_url": "https://storage.example.com/...part=51&sig=..." },
    { "part_number": 52, "upload_url": "https://storage.example.com/...part=52&sig=..." }
  ],
  "urls_expire_at": "2026-05-24T11:30:00Z"
}

Complete a multipart upload

POST /transcodely.v1.VideoService/CompleteMultipartUpload

Assembles the uploaded parts and starts processing. Submit every part with the ETag that storage returned when you PUT it.

ParameterTypeRequiredDescription
idstringYesVideo ID.
upload_idstringYesThe upload_id from CreateMultipartUpload.
partsarrayYesAll parts as { part_number, etag }, ordered 1..N.

Returns

Returns the completion response, which carries the Video with status transitioned to processing. As with CompleteUpload, the TypeScript and Python SDKs return that envelope — read .video off it — while the Go SDK unwraps it for you.

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/CompleteMultipartUpload 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{
    "id": "vid_c3d4e5f6g7h8i9",
    "upload_id": "a1b2c3d4e5f6-multipart-session-0d1e2f",
    "parts": [
      { "part_number": 1, "etag": ""9a0364b9e99bb480dd25e1f0284c8555"" },
      { "part_number": 2, "etag": ""c4ca4238a0b923820dcc509a6f75849b"" }
    ]
  }'
const res = await client.videos.completeMultipartUpload({
  id: "vid_c3d4e5f6g7h8i9",
  uploadId: "a1b2c3d4e5f6-multipart-session-0d1e2f",
  parts: uploadedParts, // [{ partNumber, etag }, ...]
});
const video = res.video;
res = client.videos.complete_multipart_upload(
    id="vid_c3d4e5f6g7h8i9",
    upload_id="a1b2c3d4e5f6-multipart-session-0d1e2f",
    parts=uploaded_parts,  # [{"part_number": 1, "etag": "..."}, ...]
)
video = res.video
video, err := client.Videos.CompleteMultipartUpload(ctx, &transcodely.MultipartCompleteParams{
    Id:       "vid_c3d4e5f6g7h8i9",
    UploadId: "a1b2c3d4e5f6-multipart-session-0d1e2f",
    Parts:    uploadedParts, // []*transcodely.CompletedPart
})

Abort a multipart upload

POST /transcodely.v1.VideoService/AbortMultipartUpload

Cancels an in-progress multipart upload, cleans up the uploaded parts, and deletes the video record. Use it when the user cancels or the client gives up.

ParameterTypeRequiredDescription
idstringYesVideo ID.
upload_idstringYesThe upload_id from CreateMultipartUpload.

Returns an empty response.

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/AbortMultipartUpload 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{
    "id": "vid_c3d4e5f6g7h8i9",
    "upload_id": "a1b2c3d4e5f6-multipart-session-0d1e2f"
  }'
await client.videos.abortMultipartUpload({
  id: "vid_c3d4e5f6g7h8i9",
  uploadId: "a1b2c3d4e5f6-multipart-session-0d1e2f",
});
client.videos.abort_multipart_upload(
    id="vid_c3d4e5f6g7h8i9",
    upload_id="a1b2c3d4e5f6-multipart-session-0d1e2f",
)
err := client.Videos.AbortMultipartUpload(ctx, &transcodely.MultipartAbortParams{
    Id:       "vid_c3d4e5f6g7h8i9",
    UploadId: "a1b2c3d4e5f6-multipart-session-0d1e2f",
})

Retrieve a video

POST /transcodely.v1.VideoService/Get
ParameterTypeRequiredDescription
idstringYesVideo ID (vid_ prefix).

Returns

Returns the Video, including its renditions and — for playable videos — playback and embed fields.

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/Get 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{"id": "vid_a1b2c3d4e5f6g7"}'
const video = await client.videos.get("vid_a1b2c3d4e5f6g7");
video = client.videos.get("vid_a1b2c3d4e5f6g7")
video, err := client.Videos.Get(ctx, "vid_a1b2c3d4e5f6g7")
{
  "video": {
    "id": "vid_a1b2c3d4e5f6g7",
    "object": "video",
    "app_id": "app_k1l2m3n4o5",
    "source": "upload",
    "status": "ready",
    "visibility": "public",
    "title": "Product demo",
    "tags": ["marketing", "demo"],
    "input_size_bytes": 132710400,
    "input_content_type": "video/mp4",
    "job_id": "job_a1b2c3d4e5f6",
    "playback_url": "https://cdn.example.com/vid_a1b2c3d4e5f6g7/hls/master.m3u8",
    "embed_url": "https://play.transcodely.com/v/vid_a1b2c3d4e5f6g7",
    "poster_url": "https://cdn.example.com/vid_a1b2c3d4e5f6g7/hls/poster.jpg",
    "duration_seconds": 128.5,
    "renditions": [
      { "id": "ren_a1b2c3d4e5f6g7", "resolution": "1080p", "codec": "h264", "bitrate_kbps": 5000, "width": 1920, "height": 1080, "size_bytes": 80530636 }
    ],
    "output_size_bytes": 80530636,
    "encoding_cost": 0.03,
    "created_at": "2026-05-24T10:00:00Z",
    "updated_at": "2026-05-24T10:03:30Z",
    "ready_at": "2026-05-24T10:03:30Z"
  }
}

List videos

POST /transcodely.v1.VideoService/List

Lists videos newest-first with page-token pagination.

ParameterTypeRequiredDescription
page_sizeintegerNoItems per page (1–100). Defaults to 20.
page_tokenstringNoToken from a previous response’s next_page_token.
statusstringNoFilter by status (e.g. ready, processing).
app_idstringNoFilter to a specific app (app_ prefix). API-key callers may omit it (their key’s app is used) or pass their own app; a different app is rejected with permission_denied. Portal callers pass it to scope to one app, or omit it to list across every app in the org.

Returns

Returns a list of Video objects, a next_page_token (absent on the last page), and total_count.

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/List 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{"page_size": 20, "status": "ready"}'
for await (const video of client.videos.list({ pageSize: 20, status: "ready" }).autoPage()) {
  console.log(video.id, video.title);
}
for video in client.videos.list(page_size=20, status="ready").auto_paging_iter():
    print(video.id, video.title)
iter := client.Videos.List(ctx, &transcodely.VideoListParams{
    PageSize: 20,
    Status:   proto.String("ready"),
})
defer iter.Close()
for iter.Next() {
    video := iter.Current()
    fmt.Println(video.GetId(), video.GetTitle())
}
if err := iter.Err(); err != nil {
    log.Fatal(err)
}
{
  "videos": [
    {
      "id": "vid_a1b2c3d4e5f6g7",
      "object": "video",
      "app_id": "app_k1l2m3n4o5",
      "source": "upload",
      "status": "ready",
      "visibility": "public",
      "title": "Product demo",
      "tags": ["marketing"],
      "duration_seconds": 128.5,
      "output_size_bytes": 125619404,
      "created_at": "2026-05-24T10:00:00Z",
      "updated_at": "2026-05-24T10:03:30Z",
      "ready_at": "2026-05-24T10:03:30Z"
    }
  ],
  "next_page_token": "eyJpZCI6InZpZF9hMWIyYzNkNGU1ZjZnNyJ9",
  "total_count": 42
}

Update a video

POST /transcodely.v1.VideoService/Update

Updates a video’s mutable metadata. Only the fields you send are applied.

ParameterTypeRequiredDescription
idstringYesVideo ID.
titlestringNoNew title.
descriptionstringNoNew description.
tagsarrayNoNew tag list. Replaces the existing tags — but because proto3 repeated fields carry no presence, an empty list reads as “unchanged”, not “clear”. To remove all tags, use clear_tags.
visibilitystringNoNew visibility: public, unlisted, or private.
clear_tagsbooleanNoSet true to remove all tags. Mutually exclusive with a non-empty tags list.
source_pinnedbooleanNoRetain (true) or release (false) this video’s original source. Retaining keeps it past the app’s retention window, immediately clears any pending deletion, and bills it as storage (“Retained source videos” on the invoice). Releasing deletes nothing on the spot: the source goes back to its window and, if that has passed, is scheduled no sooner than 72 hours out with a fresh warning. The response carries the resulting source_expires_at. See the Source Lifecycle guide.
guide_pagestringNoThis video’s guide page: on or off pins it, default clears the pin so the video follows the app’s hosting_config.guide_pages_enabled again. Omit it to leave the video as it is. The response carries the resulting guide_page_enabled and, when the page would render, guide_url.

Returns

Returns the updated Video.

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/Update 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{
    "id": "vid_a1b2c3d4e5f6g7",
    "title": "Product demo (2026 edition)",
    "visibility": "unlisted"
  }'
const video = await client.videos.update({
  id: "vid_a1b2c3d4e5f6g7",
  title: "Product demo (2026 edition)",
  visibility: "unlisted",
});
video = client.videos.update(
    id="vid_a1b2c3d4e5f6g7",
    title="Product demo (2026 edition)",
    visibility="unlisted",
)
video, err := client.Videos.Update(ctx, &transcodely.VideoUpdateParams{
    Id:         "vid_a1b2c3d4e5f6g7",
    Title:      proto.String("Product demo (2026 edition)"),
    Visibility: proto.String("unlisted"),
})
{
  "video": {
    "id": "vid_a1b2c3d4e5f6g7",
    "object": "video",
    "app_id": "app_k1l2m3n4o5",
    "source": "upload",
    "status": "ready",
    "visibility": "unlisted",
    "title": "Product demo (2026 edition)",
    "tags": ["marketing", "demo"],
    "output_size_bytes": 125619404,
    "created_at": "2026-05-24T10:00:00Z",
    "updated_at": "2026-05-24T12:00:00Z",
    "ready_at": "2026-05-24T10:03:30Z",
    "guide_page": "default",
    "guide_page_enabled": false
  }
}

To remove all tags in one call, send clear_tags:

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/Update 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{"id": "vid_a1b2c3d4e5f6g7", "clear_tags": true}'

Delete a video

POST /transcodely.v1.VideoService/Delete

Soft-deletes the video and schedules cleanup of its stored renditions. Fires the video.deleted webhook. Returns an empty response.

ParameterTypeRequiredDescription
idstringYesVideo ID.
curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/Delete 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{"id": "vid_a1b2c3d4e5f6g7"}'
await client.videos.delete("vid_a1b2c3d4e5f6g7");
client.videos.delete("vid_a1b2c3d4e5f6g7")
err := client.Videos.Delete(ctx, "vid_a1b2c3d4e5f6g7")

Generate insights from captions

POST /transcodely.v1.VideoService/GenerateInsights

Generates AI insights from a hosted video’s existing captions: AI captions, or a caption file attached with Attach a caption file, which is read when a language has both. Nothing is transcribed again: the pass reads the caption track’s transcript, so only the insights fee is billed, €0.05 per video plus €0.005 per minute of source at list price. The fee is charged only when the insights become ready; a failed pass costs nothing. Tracks captioned before the TXT and Markdown transcripts existed gain those two files on the way.

The entry comes back pending and is listed on Video.insights straight away. video.insights.ready or video.insights.failed fires when it finishes.

While an entry for the same video and language is pending, the call returns that entry and bills nothing new. Once it is ready or failed, a new call generates, and bills, a new entry. A new entry replaces the ready one only when it becomes ready itself.

ParameterTypeRequiredDescription
idstringYesVideo ID.
languagestringNoISO 639-2 language of the caption track to use, such as eng: AI captions or an uploaded caption file. Optional when the video’s captions are in exactly one language. Required when they are in several: the call is refused with parameter_required, listing the available languages. A language with no caption track is refused with parameter_invalid, also listing them.
hintstringNoFree-text guidance about the content, its audience or the tone you want, at most 300 characters. Same meaning as the hint on a captions job’s insights.
glossarystringNoNames and terms as they should be spelled in the insights text, one term per line, at most 4000 characters. Same meaning as the glossary on a captions job’s insights, minus the caption correction: this pass reads captions that already exist and never rewrites them. No effect on pricing. Echoed as glossary on the entry.
app_idstringNoThe app the video belongs to. API-key callers may omit it or pass their own app.

Refused with failed_precondition and code captions_required when the video has no captions, and insights_transcript_unavailable when its caption track has no transcript. Deployments without insights refuse it with parameter_unsupported.

Returns

Returns the TranscriptInsights entry in insights, with source video and its fee_eur.

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/GenerateInsights 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{
    "id": "vid_a1b2c3d4e5f6g7",
    "language": "eng"
  }'
{
  "insights": {
    "id": "ins_a1b2c3d4e5f6g7",
    "source": "video",
    "video_id": "vid_a1b2c3d4e5f6g7",
    "language": "eng",
    "status": "pending",
    "fee_eur": 0.10
  }
}

Translate captions

POST /transcodely.v1.VideoService/TranslateCaptions

Translates a hosted video’s existing captions into other languages, without transcribing again. The source is the language’s uploaded caption file when it has one (subtitles before captions), else its AI captions’ default style. Creates one captions-only job on the video that reads the source track’s transcript and writes, per target language: a caption track (replacing any existing auto-generated track in that language when the job completes), its transcript files and, when the video streams as HLS and its stream carries the source language’s AI captions, a caption rendition in the manifest (otherwise the translations are attached as sidecar files, in_manifest: false). Every cue keeps the source cue’s timing. The original source file is not needed.

With include_insights (the default) and ready insights in the source language, the insights are translated too and appear as one more Video.insights entry per language, with translated_from set. video.insights.ready fires for each. Highlights stay in the source language.

Billed as the captions_translation fee: €0.02 per source minute per language at list price, with a minimum of €0.05 per video per language, charged only for languages actually delivered. No captions fee and no processing fee.

While a translation job for this video and a target language is still running, that language is not requested again: the response lists it under in_flight with the job that carries it, and the new job, if any, covers only the other languages. Once a job has finished, a new call translates, and bills, again.

Regenerating the source captions does not re-translate. Existing translations stay and the dashboard marks them stale; call TranslateCaptions again to update them.

ParameterTypeRequiredDescription
idstringYesVideo ID.
target_languagesarray of stringsYesLanguages to translate into: ISO 639-2 codes, 1 to 10, distinct. See the supported languages.
source_languagestringNoISO 639-2 language of the captions to translate from: AI captions or an uploaded caption file. Optional when the video’s captions that are not themselves translations are in exactly one language. Required when they are in several: refused with parameter_required, listing the available languages. A translated track cannot be a source; naming one is refused with captions_required, and so is a video whose only captions were supplied on a transcode job.
include_insightsbooleanNoAlso translate the video’s ready insights in source_language. Defaults to true.
app_idstringNoThe app the video belongs to. API-key callers may omit it or pass their own app.

Refused with failed_precondition and code captions_required when the video has no AI captions and no uploaded caption file, or the source language only has translations, and insights_transcript_unavailable when the source track has no transcript. Refused with invalid_argument, code parameter_invalid, when a target equals the source language or is not a supported language; the violation lists the supported codes. Account refusals (spend limit, past due, suspended) are the same as for creating a job. Deployments without translation refuse it with parameter_unsupported.

Refused with unavailable and code translation_busy when the call could not start within about 10 seconds because other caption translations, of this video or many at once, were being started at the same moment. Nothing was created or billed; retry the same request after a few seconds. A create with input_video_id and translations on its generate track can be refused the same way.

Returns

FieldTypeDescription
job_idstringThe job created for the languages not already in flight. Empty when every requested language was in flight.
video_idstringThe video.
source_languagestringThe language translated from, in its ISO 639-2/B form (ger even when the track is stored as deu).
target_languagesarray of stringsThe languages the new job translates into, normalized (deu comes back as ger). Empty when job_id is empty.
in_flightarray of objectsRequested languages an earlier, still-running job already covers, each with language and job_id.
estimated_fee_eurnumberEstimated fee for the new job in EUR at your rate: source minutes × languages × rate. 0 when job_id is empty.
insights_includedbooleanWhether the insights in source_language will be translated once the job completes.
curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/TranslateCaptions 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{
    "id": "vid_a1b2c3d4e5f6g7",
    "source_language": "bul",
    "target_languages": ["eng", "deu"]
  }'
{
  "job_id": "job_a1b2c3d4e5f6",
  "video_id": "vid_a1b2c3d4e5f6g7",
  "source_language": "bul",
  "target_languages": ["eng", "ger"],
  "in_flight": [],
  "estimated_fee_eur": 1.92,
  "insights_included": true
}

Restyle captions

POST /transcodely.v1.VideoService/RestyleCaptions

Cuts a hosted video’s existing AI captions into cues of another caption style, without transcribing again. The words and their timings come from the language’s stored transcript; only how they are grouped into cues changes. Creates a captions-only job on the video. Insights are kept as they are.

A language keeps one caption track per style (style_variant on the track: the preset of its cue_style). When the language has no track in the requested style yet, the job adds one next to the existing styles, and viewers can switch between them in the player’s captions menu. The new style is not the default unless make_default is set. When the language already has a track in that style, the job re-cuts it in place. Either way, when the job completes, that track’s caption file, its transcript files and, when the video streams as HLS, its caption rendition are written, its updated_at moves and its cue_style shows the new style. No other style of the language is touched.

Deployments that do not offer several styles per language yet re-cut the language’s default track in place instead, whatever its style, and answer adds_variant: false.

Free: no captions fee, no translation fee and no processing fee.

Translations are made from the language’s default style and are not re-cut. They keep their cues; when the default style’s cues change (re-cut in place, or a new default), they are marked stale. Call TranslateCaptions again to bring them onto the new cues.

ParameterTypeRequiredDescription
idstringYesVideo ID.
languagestringNoISO 639-2 language of the AI captions to restyle. Optional when the video has exactly one language of AI captions that is not a translation. Required when it has several: refused with parameter_required, listing the available languages.
cue_styleobjectNoThe style to cut the cues in, with the same rules as cue_style on a generate track. Omitted, or for the limits it leaves unset, the app’s default cue_style applies, else standard, so an empty request re-cuts old captions into the current default. Its preset decides which style of the language the job writes.
make_defaultbooleanNoMake the restyled style the language’s default once the job completes, as Set the default caption style does. Defaults to false: a new style is added next to the default without changing what viewers see first.
app_idstringNoThe app the video belongs to. API-key callers may omit it or pass their own app.

Refused with failed_precondition and code captions_required when the video has no AI captions or language names a translated track, insights_transcript_unavailable when the track has no transcript or the video’s duration is not known yet, and captions_job_in_flight when a captions job (a generation, a translation or another restyle) of the same language is still running on the video; the message names that job. Refused with unavailable and code translation_busy when the call could not start within about 10 seconds because other caption jobs on the video were being started at the same moment: nothing was created, and the same request can be retried after a few seconds. Account refusals are the same as for creating a job.

Returns

Returns the captions-only job that cuts the cues in job_id (follow it with Retrieve a job or the job.* webhooks), the video_id, the language in its ISO 639-2/B form, the cue_style the job cuts the cues in, resolved (the preset the limits started from and all three limits), the style_variant it writes, and adds_variant: true when the job adds a new style of the language, false when it re-cuts an existing one in place.

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/RestyleCaptions 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{
    "id": "vid_a1b2c3d4e5f6g7",
    "language": "eng",
    "cue_style": { "preset": "compact" }
  }'
{
  "job_id": "job_a1b2c3d4e5f6",
  "video_id": "vid_a1b2c3d4e5f6g7",
  "language": "eng",
  "cue_style": {
    "preset": "compact",
    "max_chars_per_line": 42,
    "max_lines": 1,
    "max_cue_duration_ms": 4000
  },
  "style_variant": "compact",
  "adds_variant": true
}

Set the default caption style

POST /transcodely.v1.VideoService/SetDefaultCaptionStyle

Makes another of a language’s caption styles its default: the one the player selects for the language, the one labelled with the language name alone, and the one translations are made from. The previous default stays available as <Language> (<style>). When the video streams as HLS, its master playlist is rewritten so the language’s default rendition plays the new default’s captions, and the playlist is purged from the CDN. Translations of the language are marked stale: translate again to bring them onto the new default’s cues. Free.

Setting the current default again succeeds and changes nothing.

ParameterTypeRequiredDescription
idstringYesVideo ID.
languagestringYesISO 639-2 language of the AI captions. Both the bibliographic and the terminologic form are accepted.
style_variantenumYesThe style to make the default: compact, standard or long.
app_idstringNoThe app the video belongs to. API-key callers may omit it or pass their own app.

Refused with not_found when the video has no AI caption track of that language in that style, and with failed_precondition and code captions_job_in_flight while a captions job (a generation, a translation or a restyle) of the language is still running on the video; the message names that job. Refused with unavailable and code translation_busy when other caption changes on the video were being started at the same moment, and caption_manifest_busy when the video’s playlist kept changing while it was being rewritten: nothing was changed, and the same request can be retried after a few seconds.

Returns

Returns the video, with its text_tracks as they are now.

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/SetDefaultCaptionStyle 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{
    "id": "vid_a1b2c3d4e5f6g7",
    "language": "bul",
    "style_variant": "compact"
  }'

Delete a caption style

POST /transcodely.v1.VideoService/DeleteCaptionStyle

Removes one style of a language’s AI captions: the caption track, its entry in the video’s HLS master playlist (purged from the CDN) and its files. The default style cannot be removed, which also keeps a language’s only style: make another style the default first with Set the default caption style, or regenerate the captions. Free.

ParameterTypeRequiredDescription
idstringYesVideo ID.
languagestringYesISO 639-2 language of the AI captions. Both the bibliographic and the terminologic form are accepted.
style_variantenumYesThe style to remove: compact, standard or long. Not the language’s default.
app_idstringNoThe app the video belongs to. API-key callers may omit it or pass their own app.

Refused with not_found when the video has no AI caption track of that language in that style, with invalid_argument and code parameter_invalid when that track is the language’s default, and with the same captions_job_in_flight, translation_busy and caption_manifest_busy refusals as Set the default caption style.

Returns

Returns the video, with its text_tracks as they are now.

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/DeleteCaptionStyle 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{
    "id": "vid_a1b2c3d4e5f6g7",
    "language": "bul",
    "style_variant": "standard"
  }'

Attach a caption file

POST /transcodely.v1.VideoService/CreateTextTrack

Attaches a caption file you already have, SubRip (.srt) or WebVTT (.vtt), to a hosted video as a text track with uploaded: true and auto_generated: false. The video may be ready or still processing; the app’s managed hosting must be on. Free: no fee, no pricing rule, no webhook.

Two ways to hand over the file:

  • By URL (source.url): Transcodely downloads the file during the call (at most 5 MB, within about 15 seconds), checks it and attaches it, so the track is ready in the response. URLs that resolve to private or internal addresses are refused.
  • By upload (source.upload, with the file’s exact size_bytes): the track comes back processing with a presigned upload_url, signed for exactly that many bytes. PUT the file to it (any Content-Type) before upload_url_expires_at, then call Complete a caption upload. A PUT of any other length is refused by storage.

The file rules:

  • SubRip or WebVTT, detected from the content, not from a file name. The track is stored as WebVTT (format: "webvtt").
  • UTF-8. A UTF-8 byte-order mark is accepted; UTF-16, UTF-32 and other encodings are refused with a message to re-save the file as UTF-8.
  • At most 5 MB.
  • Every cue parseable and ending after it starts, and cue start times in order. Overlapping cues are accepted.
  • No cue ending more than 5 seconds after the end of the video. While the video is still processing its duration may not be known yet; the check then runs when processing finishes, and a track whose cues end too late is marked failed with the reason in failure_message and never published.

A ready track is listed in text_tracks with its url and its transcript files (json, txt, md, built from the cues with their markup removed), shown in the hosted player and, when the video streams as HLS, added to its master playlist as a subtitles rendition (in_manifest: true; the playlist is purged from the CDN). The menu shows label, else the language’s own name (Deutsch), followed by (CC) for kind: "captions". While the video is still processing, or when it streams only as DASH, the track is attached as a sidecar file (in_manifest: false); a video that finishes processing later gets it in its HLS playlist too.

A video holds one uploaded track per language and kind. A second one is refused with already_exists unless replace is true: the new track then gets a new ID, and the old one is removed once the new one is ready. AI captions and tracks supplied on a transcode job never conflict with an uploaded track.

An uploaded track can be the source of TranslateCaptions and GenerateInsights, and is preferred over AI captions of the same language (subtitles before captions). A language’s translations are marked stale when the track they are translated from changes: an upload that becomes the language’s source (the first one over AI captions, or a replace), or the removal of the upload that was. While a running translation job or a pending GenerateInsights pass reads an uploaded track, it cannot be replaced or deleted.

ParameterTypeRequiredDescription
video_idstringYesThe hosted video (vid_ prefix).
languagestringYesLanguage of the captions: an ISO 639-1 (en), ISO 639-2 (eng, deu or ger) or BCP 47 (en-US) code. Stored and echoed as ISO 639-2/B (eng); a region subtag is not kept. One of the supported languages; anything else is refused with parameter_invalid.
kindstringNosubtitles (the default) or captions: subtitles for the deaf and hard of hearing, which also describe sounds, and are marked as such in the HLS stream.
labelstringNoName shown in the player’s caption menu, such as English (CC). At most 64 characters, in any script; no comma, equals sign, double quote or control character. When omitted, label is the language’s English name (English, English (CC) for captions).
replacebooleanNoReplace the video’s uploaded track of this language and kind instead of refusing with already_exists. Defaults to false.
sourceobjectYesExactly one of url (a public http(s) URL of the file, at most 2048 characters) or upload ({"size_bytes": <the file's exact size in bytes, 1 to 5000000>}).
app_idstringNoThe app the video belongs to. API-key callers may omit it or pass their own app.

Refused with invalid_argument and code text_track_invalid when the file is not valid (the message says what is wrong and where, such as Cue 2 ends at 00:01:01.000, but the video is only 00:00:30.000 long) or a source.url could not be downloaded, and text_track_too_large when it is over 5 MB. Refused with already_exists when the video already has an uploaded track of that language and kind and replace is false; with failed_precondition when the app’s managed hosting is off or the video is not ready or processing (still uploading, failed, archived); with not_found (video_not_found) for a video of another app; with failed_precondition and code captions_job_in_flight when replace would remove a track that a running translation job or a pending GenerateInsights pass is reading (the message names it); and with unavailable (caption_manifest_busy, translation_busy) when the video’s captions were being changed at the same moment: nothing was attached, retry in a few seconds.

Returns

Returns the new track in text_track: ready for source.url, processing for source.upload. For source.upload the response also carries upload_url, the presigned URL to PUT the file to, and upload_url_expires_at, when it stops working (an hour after the call).

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/CreateTextTrack 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{
    "video_id": "vid_a1b2c3d4e5f6g7",
    "language": "en",
    "kind": "subtitles",
    "source": { "url": "https://example.com/lesson.en.srt" }
  }'
{
  "text_track": {
    "id": "trk_a1b2c3d4e5f6g7",
    "kind": "subtitles",
    "language": "eng",
    "label": "English",
    "format": "webvtt",
    "auto_generated": false,
    "uploaded": true,
    "status": "ready",
    "in_manifest": true,
    "url": "https://cdn.example.com/vid_a1b2c3d4e5f6g7/captions/trk_a1b2c3d4e5f6g7.vtt",
    "transcript_renditions": [
      { "format": "json", "signed_url": "https://cdn.example.com/vid_a1b2c3d4e5f6g7/captions/trk_a1b2c3d4e5f6g7.transcript.json" },
      { "format": "txt", "signed_url": "https://cdn.example.com/vid_a1b2c3d4e5f6g7/captions/trk_a1b2c3d4e5f6g7.transcript.txt" },
      { "format": "md", "signed_url": "https://cdn.example.com/vid_a1b2c3d4e5f6g7/captions/trk_a1b2c3d4e5f6g7.transcript.md" }
    ],
    "created_at": "2026-05-24T10:05:00Z"
  }
}

With an upload source instead:

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/CreateTextTrack 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{
    "video_id": "vid_a1b2c3d4e5f6g7",
    "language": "de",
    "kind": "captions",
    "source": { "upload": { "size_bytes": 48213 } }
  }'

# PUT the file to the upload_url from the response
curl -X PUT --upload-file lesson.de.vtt "<upload_url>"
{
  "text_track": {
    "id": "trk_h8i9j0k1l2m3n4",
    "kind": "captions",
    "language": "ger",
    "label": "German (CC)",
    "format": "webvtt",
    "auto_generated": false,
    "uploaded": true,
    "status": "processing",
    "in_manifest": false,
    "created_at": "2026-05-24T10:05:00Z"
  },
  "upload_url": "https://storage.example.com/outputs/vid_a1b2c3d4e5f6g7/captions/trk_h8i9j0k1l2m3n4.upload?X-Amz-Signature=...",
  "upload_url_expires_at": "2026-05-24T11:05:00Z"
}

Complete a caption upload

POST /transcodely.v1.VideoService/CompleteTextTrackUpload

Finishes a track created with source.upload once its file has been PUT to upload_url. The file is read, checked and attached exactly as a source.url file is, and the track comes back ready.

A file that is refused marks the track failed with a plain failure_message and returns the same text_track_invalid or text_track_too_large error; create the track again with a corrected file. A file that was never uploaded is refused with failed_precondition and code text_track_upload_missing, and the track stays processing, so the upload can be retried. Calling it again on a ready track returns the track unchanged; on a failed one, the refusal again. A track superseded by a later CreateTextTrack of the same language and kind is not_found (text_track_not_found).

ParameterTypeRequiredDescription
video_idstringYesThe hosted video.
text_track_idstringYesThe track CreateTextTrack returned (trk_ prefix).
app_idstringNoThe app the video belongs to. API-key callers may omit it or pass their own app.

Returns

Returns the track, ready, in text_track.

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/CompleteTextTrackUpload 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{
    "video_id": "vid_a1b2c3d4e5f6g7",
    "text_track_id": "trk_h8i9j0k1l2m3n4"
  }'

Delete a caption file

POST /transcodely.v1.VideoService/DeleteTextTrack

Removes a track attached with Attach a caption file: its entry in the video’s HLS master playlist (purged from the CDN), the track and its files. Free. Only uploaded tracks can be removed here; AI caption styles are removed with Delete a caption style. Translations are kept; only those made from this track are marked stale, others are not affected.

ParameterTypeRequiredDescription
video_idstringYesThe hosted video.
text_track_idstringYesThe uploaded track to remove (trk_ prefix).
app_idstringNoThe app the video belongs to. API-key callers may omit it or pass their own app.

Refused with not_found (text_track_not_found) for a track that is not an uploaded track of this video, with failed_precondition and code captions_job_in_flight while a running translation job or a pending GenerateInsights pass reads the track (the message names it), and with unavailable (caption_manifest_busy, translation_busy) when the video’s captions were being changed at the same moment: nothing was changed, retry in a few seconds.

Returns

Returns the video, with its text_tracks as they are now.

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/DeleteTextTrack 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{
    "video_id": "vid_a1b2c3d4e5f6g7",
    "text_track_id": "trk_a1b2c3d4e5f6g7"
  }'

Generate highlights

POST /transcodely.v1.VideoService/GenerateHighlights

Cuts up to max_count (default 5) short MP4 highlight clips from a hosted video, around the verbatim quotes its ready AI insights picked. Each clip is rendered at the codec and resolution of the video’s top rendition. The highlights come back pending and are listed on Video.highlights straight away. video.highlights.ready, or video.highlights.failed when none could be rendered, fires once every one of them has finished.

Each highlight is rendered by its own clip job on the video, billed as its rendered (clipped) minutes at your encoding rate and nothing else: highlight clips carry no processing fee. Those jobs count toward your concurrency and queue limits and appear in your job list, tagged with transcodely_kind: video_highlight in their metadata.

While any highlight of the video is pending, the call returns the current highlights and bills nothing new. Once all are ready or failed, a new call replaces them with a new set, and the old clips are deleted.

ParameterTypeRequiredDescription
idstringYesVideo ID.
languagestringNoISO 639-2 language of the AI insights to cut from, such as eng. Optional when the video has ready insights in exactly one language. Required when it has several: the call is refused with parameter_required, listing them.
configobjectNoHow to choose the clips: max_count (1 to 10, default 5), min_seconds (1 to 300, default 8), max_seconds (1 to 300 and not below min_seconds, default 60) and padding_seconds (0 to 10, default 1.5). Omitted fields take their defaults. enabled is ignored here. See Choose the clips.
app_idstringNoThe app the video belongs to. API-key callers may omit it or pass their own app.

Refused with failed_precondition and code highlights_require_insights when the video has no ready AI insights in the language, and highlights_no_moments when the insights picked no quote inside the video. Also refused with failed_precondition while the video is still processing and when the app’s managed hosting is off. Account refusals (spend limit, past due, suspended app) are the same as for creating a job.

Returns

Returns the video’s highlights in highlights: the new set, each pending (or failed when an account limit refused its job), or the set already pending.

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/GenerateHighlights 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{
    "id": "vid_a1b2c3d4e5f6g7",
    "config": { "max_count": 3 }
  }'
{
  "highlights": [
    {
      "id": "hl_a1b2c3d4e5f6g7",
      "start_seconds": 18.5,
      "end_seconds": 31.5,
      "title": "Patience is the secret ingredient.",
      "status": "pending",
      "job_id": "job_a1b2c3d4e5f6",
      "language": "eng",
      "created_at": "2026-10-31T10:00:00Z"
    }
  ]
}

The highlight object

AttributeTypeDescription
idstringUnique identifier. Prefixed with hl_.
start_secondsnumberWhere the clip starts in the video, in seconds.
end_secondsnumberWhere the clip ends in the video, in seconds.
titlestringThe quote the clip was cut around, shortened to at most 120 characters.
statusstringOne of pending (its clip job is queued or rendering), ready (rendered; URLs available) or failed.
error_codestringWhy the highlight failed. Present only when status is failed. See Highlight clips.
playback_urlstringMP4 URL of the clip, signed on token-auth apps. Present only when status is ready, under the same rules as poster_url.
poster_urlstringPoster frame URL, from the first frame of the clip. Same rules as playback_url.
duration_secondsnumberRendered length in seconds, as measured. Present once ready.
job_idstringThe clip job that renders it. Present once the job was created.
languagestringISO 639-2 language of the insights the quote came from.
created_atstringISO 8601 timestamp of when the highlight was requested.

Watch a video

POST /transcodely.v1.VideoService/Watch

Streams a video’s state in real time. The server sends the current state immediately, then pushes updates as the video moves through processing. This is a server-streaming RPC; the stream closes when the video reaches a terminal state (ready or error). It is the simplest way to know when a video becomes playable.

ParameterTypeRequiredDescription
idstringYesVideo ID.

Stream events

Each message carries the current Video and an event_type:

EventDescription
snapshotInitial state, sent on connect.
status_changeThe video’s status transitioned.
progressTranscoding progress advanced.
completedTerminal state reached. The stream closes after this.

The server periodically re-sends the latest state as a keepalive; these arrive as regular progress (or status_change/completed) events, so there is no separate heartbeat event to handle.

curl -N -X POST https://api.transcodely.com/transcodely.v1.VideoService/Watch 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{"id": "vid_a1b2c3d4e5f6g7"}'
for await (const event of client.videos.watch("vid_a1b2c3d4e5f6g7")) {
  console.log(event.eventType, event.video?.status);
  if (event.eventType === "completed") break;
}
for event in client.videos.watch("vid_a1b2c3d4e5f6g7"):
    print(event.event_type, event.video.status)
    if event.event_type == "completed":
        break
stream := client.Videos.Watch(ctx, "vid_a1b2c3d4e5f6g7")
defer stream.Close()
for stream.Next() {
    event := stream.Current()
    fmt.Println(event.GetEventType(), event.GetVideo().GetStatus())
    if event.GetEventType() == "completed" {
        break
    }
}
if err := stream.Err(); err != nil {
    log.Fatal(err)
}
{"result": {"video": {"id": "vid_a1b2c3d4e5f6g7", "status": "processing"}, "event_type": "snapshot"}}
{"result": {"video": {"id": "vid_a1b2c3d4e5f6g7", "status": "ready"}, "event_type": "completed"}}

Get usage

POST /transcodely.v1.VideoService/GetUsage

Returns aggregated hosting usage and cost for a billing period, plus a per-day breakdown. App-scoped keys report their app; portal sessions report across the whole organization. All monetary fields are in the currency returned with the summary (EUR today).

ParameterTypeRequiredDescription
billing_monthstringNoMonth in YYYY-MM form (e.g. 2026-05). Defaults to the current billing month.

Returns

Returns a usage summary.

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/GetUsage 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{"billing_month": "2026-05"}'
const { usage } = await client.videos.getUsage({ billingMonth: "2026-05" });
console.log(usage?.totalCost, usage?.currency);
res = client.videos.get_usage(billing_month="2026-05")
print(res.usage.total_cost, res.usage.currency)
usage, err := client.Videos.GetUsage(ctx, "2026-05")
{
  "usage": {
    "billing_month": "2026-05",
    "videos_encoded": 128,
    "encoding_minutes": 742.5,
    "encoding_cost": 3.71,
    "storage_gb_avg": 54.2,
    "storage_cost": 0.81,
    "videos_hosted": 96,
    "retained_source_gb_avg": 12.5,
    "retained_source_cost": 0.25,
    "egress_gb": 310,
    "egress_cost": 3.2,
    "egress_by_region": [
      { "region": "europe", "egress_bytes": 289910292480, "egress_gb": 270, "egress_cost": 2.7 },
      { "region": "north_america", "egress_bytes": 37580963840, "egress_gb": 35, "egress_cost": 0.35 },
      { "region": "asia_oceania", "egress_bytes": 5368709120, "egress_gb": 5, "egress_cost": 0.15 }
    ],
    "total_requests": 148902,
    "total_cost": 7.97,
    "currency": "EUR",
    "hosting_estimated_from": "",
    "daily": [
      {
        "date": "2026-05-01",
        "storage_bytes": 51539607552,
        "egress_bytes": 9663676416,
        "request_count": 4820,
        "encoding_cost": 0.12,
        "egress_by_region": [
          { "region": "europe", "egress_bytes": 8589934592 },
          { "region": "north_america", "egress_bytes": 1073741824 }
        ]
      },
      {
        "date": "2026-05-02",
        "storage_bytes": 53687091200,
        "egress_bytes": 10737418240,
        "request_count": 5133,
        "encoding_cost": 0.09,
        "egress_by_region": [
          { "region": "europe", "egress_bytes": 9663676416 },
          { "region": "asia_oceania", "egress_bytes": 1073741824 }
        ]
      }
    ]
  }
}

Usage summary

FieldTypeDescription
billing_monthstringThe billing month, YYYY-MM.
videos_encodedintegerVideos transcoded in the period.
encoding_minutesnumberTotal encoded minutes.
encoding_costnumberEncoding cost for the period.
storage_gb_avgnumberAverage stored gigabytes of deliverables (renditions, manifests, posters) over the period. Original source files are not included.
storage_costnumberDeliverables storage cost for the period, to date: the invoice line “Hosting — storage”. Days the accrual job has already billed are reported at the amount billed, so a closed month matches your invoice. For the current month this is cost so far, not a projection of the full month.
videos_hostedintegerVideos actively hosted.
retained_source_gb_avgnumberAverage gigabytes of retained original source files (videos with source_pinned) over the period. Sources inside their retention window are free and not counted.
retained_source_costnumberCost of retained original source files for the period, to date: the invoice line “Retained source videos”. Billed like storage_cost, at the same storage rate.
egress_gbnumberGigabytes served to viewers, where 1 GB = 2^30 bytes (1 GiB), the unit the per-GB prices and invoice quantities use. Delivery is metered once per UTC day.
egress_costnumberEgress (delivery) cost for the period. Accrued days are reported at the amount billed; days not yet accrued are estimated at your current rate. If the rate for some not-yet-billed delivery cannot be determined, that delivery is still counted in egress_gb but left out of this estimate until it is billed; its day is then covered by hosting_estimated_from.
egress_by_regionarray of objectsThe period’s delivery broken down by the delivery region that served it: one entry per region with usage, in the order delivery_regions lists the regions (europe, north_america, asia_oceania, south_america, middle_east_africa), with the entry for delivery metered before regional pricing (empty region), if any, last. The entries’ egress_bytes add up exactly to the period’s delivered bytes; their egress_gb and egress_cost add up to the summary’s egress_gb and egress_cost to within 0.000001 (costs are exact to 0.000001 EUR, and the totals are computed from the exact amounts, not by adding the entries). See Delivery by region.
total_requestsintegerCDN requests served.
total_costnumberSum of encoding, storage, retained source and egress cost.
currencystringISO 4217 currency for all cost fields (e.g. EUR).
hosting_estimated_fromstringFirst day (YYYY-MM-DD) of the period whose storage and egress cost is still estimated rather than accrued. Hosting is accrued daily through the previous day, so a period with live storage or delivery normally has an estimated tail. Empty when no day with hosting usage is still unaccrued, which is when storage_cost and egress_cost match your invoice.
dailyarray of objectsPer-day usage breakdown, oldest first. Only days with recorded activity are present (no zero-fill). See Daily usage.

Daily usage

One entry per active day in the billing period. All monetary fields use the summary’s currency.

FieldTypeDescription
datestringCalendar day, YYYY-MM-DD (UTC).
storage_bytesintegerStored deliverable bytes as of this day’s snapshot (point-in-time, not an increment). Retained source files are not included.
egress_bytesintegerBytes delivered by the CDN during this day. Delivery is metered once per UTC day, so the current day reads zero until it has been collected.
request_countintegerCDN requests served during this day.
encoding_costnumberEncoding cost for videos created on this day.
egress_by_regionarray of objectsThis day’s delivery by the delivery region that served it, one entry per region with usage, ordered as in the summary’s egress_by_region. Entries sum to egress_bytes. Each entry has region and egress_bytes, described in Daily delivery by region.

Delivery by region

One entry in the summary’s egress_by_region. Delivery is billed per GB at the rate of the region that served it, so an app with fewer regions enabled has its far-away viewers served, and billed, from the nearest enabled region.

FieldTypeDescription
regionstringThe delivery region that served the bytes: europe, north_america, asia_oceania, south_america or middle_east_africa. Empty for delivery metered before delivery was priced per region, which is billed at the former single delivery rate.
egress_bytesintegerBytes delivered from this region in the period.
egress_gbnumberThe same, in GB: egress_bytes / 2^30 (1 GB = 1 GiB, as in the summary’s egress_gb).
egress_costnumberDelivery cost for this region, with the same semantics as the summary’s egress_cost: delivery already billed at the rate it was billed at, delivery not billed yet (see hosting_estimated_from) estimated at your current rate for the region.

Daily delivery by region

One entry in a daily row’s egress_by_region.

FieldTypeDescription
regionstringThe delivery region that served the bytes, or empty for delivery metered before delivery was priced per region.
egress_bytesintegerBytes delivered from this region on the day.

Playback analytics

Every hosted video collects lightweight playback metrics — plays, watch time, and unique viewers — aggregated per UTC day. Data comes from a best-effort, anonymous beacon fired by the player and embed page: it identifies a view by a per-pageview session ID (a random UUID — no cookies, no PII). A play is counted once per pageview that starts playback; watch time is derived from periodic heartbeats (roughly 10-second granularity, so it is approximate); unique viewers counts distinct per-pageview sessions. Events roll up hourly, so the most recent activity can lag by up to an hour.

Get video stats

POST /transcodely.v1.VideoService/GetStats

Returns a single video’s daily series and range totals.

ParameterTypeRequiredDescription
video_idstringYesVideo ID (vid_ prefix).
start_datestringNoInclusive UTC range start, YYYY-MM-DD. Omitted means all retained history.
end_datestringNoInclusive UTC range end, YYYY-MM-DD. Omitted means up to today.

Returns

A daily array of daily stats (oldest first, only days with activity) plus a totals object summing them.

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/GetStats 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{"video_id": "vid_a1b2c3d4e5f6g7", "start_date": "2026-05-01", "end_date": "2026-05-31"}'

SDK support: typed helpers (getStats / get_stats) ship with the next SDK release; until then call the endpoint directly with any Connect/JSON client.

{
  "daily": [
    { "date": "2026-05-01", "plays": 320, "watch_seconds": 184500, "unique_viewers": 271 },
    { "date": "2026-05-02", "plays": 298, "watch_seconds": 171200, "unique_viewers": 256 }
  ],
  "totals": { "plays": 618, "watch_seconds": 355700, "unique_viewers": 527 }
}

Daily stats

FieldTypeDescription
datestringUTC day, YYYY-MM-DD.
playsintegerPlayback starts (one per pageview that began playing).
watch_secondsintegerApproximate watch time in seconds (heartbeat count × ~10s).
unique_viewersintegerDistinct per-pageview sessions.

totals carries the same three metrics summed across the returned days. Unique viewers are summed per day, so a viewer active on several days counts once per day (exact only for a single-day range).

List top videos

POST /transcodely.v1.VideoService/ListTopVideos

Returns an app’s videos ranked by plays (then watch time) over a date range — the leaderboard behind the dashboard’s top-videos view.

ParameterTypeRequiredDescription
app_idstringNoApp to rank (app_ prefix). API-key callers may omit it (their key’s app is used); portal callers pass it to scope the leaderboard, or omit to use the org’s first app.
start_datestringNoInclusive UTC range start, YYYY-MM-DD.
end_datestringNoInclusive UTC range end, YYYY-MM-DD.
limitintegerNoMax videos to return (1–100). Defaults to 10.

Returns

An items array of ranked videos, highest plays first.

curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/ListTopVideos 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{"start_date": "2026-05-01", "end_date": "2026-05-31", "limit": 10}'

SDK support: typed helpers (listTopVideos / list_top_videos) ship with the next SDK release; until then call the endpoint directly.

{
  "items": [
    {
      "video_id": "vid_a1b2c3d4e5f6g7",
      "title": "Product demo",
      "poster_url": "https://cdn.example.com/vid_a1b2c3d4e5f6g7/hls/poster.jpg",
      "plays": 618,
      "watch_seconds": 355700,
      "unique_viewers": 527
    }
  ]
}

Ranked video fields

FieldTypeDescription
video_idstringVideo ID (vid_ prefix).
titlestringVideo title, if set.
poster_urlstringPoster image URL. Absent when no CDN is configured or the video has no poster.
playsintegerTotal plays over the range.
watch_secondsintegerTotal approximate watch seconds over the range.
unique_viewersintegerUnique viewers over the range (summed per day).

Get SEO markup

POST /transcodely.v1.VideoService/GetSeoMarkup

Returns ready-to-paste markup for showing the video on your own page: a schema.org VideoObject as JSON-LD (with chapter key moments when the video has ready insights), a video sitemap entry, and a server-renderable HTML fragment with the summary, chapters and full transcript. See the Video SEO guide for where each piece goes. The video must be ready and public or unlisted; any other video is refused with failed_precondition. embedUrl and thumbnailUrl in the markup are stable player URLs that never expire.

ParameterTypeRequiredDescription
video_idstringYesVideo ID (vid_ prefix).
watch_urlstringYesAbsolute https:// URL of your page that shows the video. Used as the sitemap location and as the base of every chapter link.
deep_link_paramstringNoQuery parameter your page reads to start playback at a time, in whole seconds. Default t.
languagestringNoISO 639-2 language of the transcript and insights to use. Default: the video’s first generated transcript.

SEO markup response

AttributeTypeDescription
json_ldstringschema.org VideoObject JSON-LD, ready to place inside <script type="application/ld+json">. Has hasPart Clip entries linking to watch_url at each chapter start when insights are ready. Never carries a transcript property.
sitemap_entrystringA <url> entry for a video sitemap, to add to your sitemap’s <urlset>.
html_fragmentstringSemantic HTML with no scripts and no styles: a <section class="tx-insights"> with the summary, key points and chapter links when insights are ready, and the full transcript inside <details><summary>Transcript</summary>…</details>.
curl -X POST https://api.transcodely.com/transcodely.v1.VideoService/GetSeoMarkup 
  -H "Authorization: Bearer ak_abc123" 
  -H "Content-Type: application/json" 
  -d '{"video_id": "vid_a1b2c3d4e5f6g7", "watch_url": "https://example.com/watch/42"}'
{
  "json_ld": "{"@context":"https://schema.org","@type":"VideoObject",…}",
  "sitemap_entry": "<url><loc>https://example.com/watch/42</loc><video:video>…</video:video></url>",
  "html_fragment": "<section class="tx-insights">…</section>"
}

Webhook events

Register a webhook endpoint to be notified about hosted videos. These events fire:

EventWhen it firesdata payload
video.uploadedAn upload (single-part or multipart) is completed and the video enters processing. Does not fire for URL ingest.A Video snapshot with status: "processing".
video.readyProcessing finished and the video is playable.A full Video snapshot with status: "ready", its renditions, and duration_seconds (and truncation when the video was shortened).
video.failedProcessing failed.A Video snapshot with status: "error".
video.deletedA video is deleted.A Video snapshot with status: "deleted".
video.source_scheduled_for_deletionA hosted video’s original source has been scheduled for deletion because its retention window ends, at least 72 hours ahead. Retained sources never are. See Source Lifecycle.A Video snapshot with source_scheduled_for_deletion_at and source_expires_at set to the deletion time.
video.insights.readyInsights requested with GenerateInsights, or translated after TranslateCaptions, are ready.The TranscriptInsights entry, with video_id and language.
video.insights.failedInsights requested with GenerateInsights could not be produced. Nothing is charged.The TranscriptInsights entry, with error_code saying why.
video.highlights.readyEvery highlight clip of a set (GenerateHighlights or the create-time highlights option) finished and at least one rendered. Fires once per set.A Video snapshot with highlights; failed ones carry error_code.
video.highlights.failedEvery highlight clip of a set finished and none rendered, or a create-time highlights request was refused (one failed highlight carrying the refusal’s code).A Video snapshot with highlights.

Apart from the two video.insights.* events, the data payload is a Video snapshot that mirrors Get, except the request-time playback/embed/poster URLs (including each highlight’s playback_url and poster_url) are omitted — those are computed per request and have no stable value at emit time. To get live URLs, call Get for the video, or construct the embed URL yourself as {player_base}/v/{video_id}. The guide page fields follow the same split: guide_page (the video’s own setting) is in every payload, but guide_page_enabled and guide_url are absent, because a snapshot does not resolve the app default — read the effective value from Get.

video.ready is the event to drive playback readiness off of — it’s the webhook equivalent of a Watch completed:

{
  "id": "evt_a1b2c3d4e5f6g7h8",
  "type": "video.ready",
  "data": {
    "id": "vid_a1b2c3d4e5f6g7",
    "object": "video",
    "status": "ready",
    "duration_seconds": 128.5,
    "renditions": [
      { "id": "ren_a1b2c3d4e5f6g7", "resolution": "1080p", "codec": "h264" }
    ],
    "created_at": "2026-05-24T10:00:00Z",
    "updated_at": "2026-05-24T10:03:30Z"
  }
}

See the Webhooks API for endpoint management, signing, and delivery, and the Webhooks concept guide for the full envelope and signature-verification details.


Errors

Connect codeCause
unauthenticatedAPI key missing/invalid, or the caller lacks access to the app.
failed_preconditionHosting is not enabled on the app; or CompleteUpload was called before the file was uploaded, or on a video that is not in uploading state; or CompleteTextTrackUpload was called before the caption file was uploaded (text_track_upload_missing).
not_foundThe vid_ doesn’t exist, was deleted, or belongs to another app; or the trk_ is not an uploaded caption track of this video (text_track_not_found).
already_existsCreateTextTrack for a language and kind the video already has an uploaded track of, without replace: true.
unavailablecaption_manifest_busy or translation_busy: the video’s captions were being changed at the same moment. Nothing was changed; retry in a few seconds.
invalid_argumentRequest validation failed (e.g. size_bytes over the 5 GB limit, an out-of-range part count, or — for CreateFromUrl — a non-http(s), private/internal, or otherwise invalid url), or the multipart parts don’t match what was uploaded. A caption file that is not valid is text_track_invalid, one over 5 MB text_track_too_large.
permission_deniedapp_id names an app the caller can’t access (e.g. an API key passing a different app).
internalUnexpected server error — retry idempotent reads.

Run this against your own file

A free account runs standard-quality encodes up to 2 minutes, one at a time (a longer upload is shortened to its first 2 minutes), so the Quickstart runs with nothing set up but an API key.