curl --request POST \
--url http://localhost:6699/api/v1/export/transcript \
--header 'Content-Type: application/json' \
--header 'X-License-Key: <api-key>' \
--data '
{
"segments": [
[
123
]
],
"format": "txt",
"display_name": "Transcript",
"output_path": "<string>",
"include_silences": true,
"frame_rate": 123,
"media_path": "<string>",
"start_timecode": "01:00:00:00"
}
'import requests
url = "http://localhost:6699/api/v1/export/transcript"
payload = {
"segments": [[123]],
"format": "txt",
"display_name": "Transcript",
"output_path": "<string>",
"include_silences": True,
"frame_rate": 123,
"media_path": "<string>",
"start_timecode": "01:00:00:00"
}
headers = {
"X-License-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-License-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
segments: [[123]],
format: 'txt',
display_name: 'Transcript',
output_path: '<string>',
include_silences: true,
frame_rate: 123,
media_path: '<string>',
start_timecode: '01:00:00:00'
})
};
fetch('http://localhost:6699/api/v1/export/transcript', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_PORT => "6699",
CURLOPT_URL => "http://localhost:6699/api/v1/export/transcript",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'segments' => [
[
123
]
],
'format' => 'txt',
'display_name' => 'Transcript',
'output_path' => '<string>',
'include_silences' => true,
'frame_rate' => 123,
'media_path' => '<string>',
'start_timecode' => '01:00:00:00'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-License-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "http://localhost:6699/api/v1/export/transcript"
payload := strings.NewReader("{\n \"segments\": [\n [\n 123\n ]\n ],\n \"format\": \"txt\",\n \"display_name\": \"Transcript\",\n \"output_path\": \"<string>\",\n \"include_silences\": true,\n \"frame_rate\": 123,\n \"media_path\": \"<string>\",\n \"start_timecode\": \"01:00:00:00\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-License-Key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("http://localhost:6699/api/v1/export/transcript")
.header("X-License-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"segments\": [\n [\n 123\n ]\n ],\n \"format\": \"txt\",\n \"display_name\": \"Transcript\",\n \"output_path\": \"<string>\",\n \"include_silences\": true,\n \"frame_rate\": 123,\n \"media_path\": \"<string>\",\n \"start_timecode\": \"01:00:00:00\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("http://localhost:6699/api/v1/export/transcript")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url)
request["X-License-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"segments\": [\n [\n 123\n ]\n ],\n \"format\": \"txt\",\n \"display_name\": \"Transcript\",\n \"output_path\": \"<string>\",\n \"include_silences\": true,\n \"frame_rate\": 123,\n \"media_path\": \"<string>\",\n \"start_timecode\": \"01:00:00:00\"\n}"
response = http.request(request)
puts response.read_body{
"output_path": "<string>",
"format": "<string>",
"row_count": 123
}Export transcript to file
Export transcript segments to a file in TXT, CSV, DOCX, PDF, SRT, or
Avid SubCap format. If output_path is omitted, saves to ~/Desktop/ using
the sanitized display_name without its extension: <name>.txt, .csv,
.docx, .pdf, or .srt, and <name> SubCap.txt for subcap. An existing
file at the destination is overwritten; missing parent folders are created.
Each segment is a [start_seconds, text, end_seconds] array or a
{start_seconds, end_seconds, text} object. An array’s optional fourth field
is its speaker display label. The fourth field from /transcriptions is a media
path, so remove or replace it before exporting those segments. Segments from
/transcriptions/range can be sent as they are; their speaker_names arrays are
not used as labels.
Captions (srt, subcap). Each segment with text becomes one cue, with whitespace collapsed to single spaces. Speaker labels are left out and include_silences is ignored. Cues are sorted by start time. Each cue lasts at least 0.04 s, but a cue that overlaps the next one ends where the next starts.
- srt: SubRip in UTF-8 with CRLF line endings and
HH:MM:SS,mmmtimes in source-clip time, counted from 0. - subcap: Avid DS caption file for Media Composer’s SubCap effect, UTF-16 LE with a byte order mark and CRLF line endings. Times are non-drop-frame timecode at the rounded frame rate (23.976 is counted as 24, 29.97 as 30), counted from start_timecode. This assumes the clip sits at the start of the sequence. Every cue gets at least one frame, and cues never overlap.
curl --request POST \
--url http://localhost:6699/api/v1/export/transcript \
--header 'Content-Type: application/json' \
--header 'X-License-Key: <api-key>' \
--data '
{
"segments": [
[
123
]
],
"format": "txt",
"display_name": "Transcript",
"output_path": "<string>",
"include_silences": true,
"frame_rate": 123,
"media_path": "<string>",
"start_timecode": "01:00:00:00"
}
'import requests
url = "http://localhost:6699/api/v1/export/transcript"
payload = {
"segments": [[123]],
"format": "txt",
"display_name": "Transcript",
"output_path": "<string>",
"include_silences": True,
"frame_rate": 123,
"media_path": "<string>",
"start_timecode": "01:00:00:00"
}
headers = {
"X-License-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-License-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
segments: [[123]],
format: 'txt',
display_name: 'Transcript',
output_path: '<string>',
include_silences: true,
frame_rate: 123,
media_path: '<string>',
start_timecode: '01:00:00:00'
})
};
fetch('http://localhost:6699/api/v1/export/transcript', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_PORT => "6699",
CURLOPT_URL => "http://localhost:6699/api/v1/export/transcript",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'segments' => [
[
123
]
],
'format' => 'txt',
'display_name' => 'Transcript',
'output_path' => '<string>',
'include_silences' => true,
'frame_rate' => 123,
'media_path' => '<string>',
'start_timecode' => '01:00:00:00'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-License-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "http://localhost:6699/api/v1/export/transcript"
payload := strings.NewReader("{\n \"segments\": [\n [\n 123\n ]\n ],\n \"format\": \"txt\",\n \"display_name\": \"Transcript\",\n \"output_path\": \"<string>\",\n \"include_silences\": true,\n \"frame_rate\": 123,\n \"media_path\": \"<string>\",\n \"start_timecode\": \"01:00:00:00\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-License-Key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("http://localhost:6699/api/v1/export/transcript")
.header("X-License-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"segments\": [\n [\n 123\n ]\n ],\n \"format\": \"txt\",\n \"display_name\": \"Transcript\",\n \"output_path\": \"<string>\",\n \"include_silences\": true,\n \"frame_rate\": 123,\n \"media_path\": \"<string>\",\n \"start_timecode\": \"01:00:00:00\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("http://localhost:6699/api/v1/export/transcript")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url)
request["X-License-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"segments\": [\n [\n 123\n ]\n ],\n \"format\": \"txt\",\n \"display_name\": \"Transcript\",\n \"output_path\": \"<string>\",\n \"include_silences\": true,\n \"frame_rate\": 123,\n \"media_path\": \"<string>\",\n \"start_timecode\": \"01:00:00:00\"\n}"
response = http.request(request)
puts response.read_body{
"output_path": "<string>",
"format": "<string>",
"row_count": 123
}Authorizations
Body
List of segments. Each is a [start_seconds, text, end_seconds] array, optionally with a fourth speaker display label, or an object with start_seconds, end_seconds, and text, like the segments /transcriptions/range returns. An object's optional speaker_name or speaker string becomes its speaker label.
- (number | string)[]
- object
Was this page helpful?

