Skip to main content

Retrieve a document


📝 Use correct API token

It is important that the correct API token is used for document retrieval. Only the token linked to the TranscriptSession can be used.


📎 URL

GET https://api.scriptix.io/api/v3/speech-to-text/session/${sessionId}/document/${documentId}


🔐 Request headers

The following headers need to be present:

ParameterValueDescription
X-Zoom-S2T-KeyScriptix Batch API TokenAPI key belonging to TranscriptSession

🔢 Request path arguments

ArgumentDescription
sessionIdScriptix Transcript Session ID returned from a Batch Session
documentIdScriptix Document ID returned from creating a document

🔍 Request query parameters

KeyTypeDescription
formatstringDefault: json
Returns the document in the specified format. See supported document formats.

Supported Document Formats

The following formats are supported when retrieving a document using the format query parameter:

FormatDescription
jsonScriptix ExtendedDocumentModel JSON response
sbvSBV subtitle format
srtSRT subtitle format
ttmlTTML subtitle format
vttVTT subtitle format
docxMicrosoft Word document
templateAI generated template (either with a specific format or summarization)
stlSubtitle format for broadcast
htmlHTML document

🔁 Response Codes

Status codeDescription
200Document in requested format
400Bad request
401Unauthorized — no valid authentication found
403Forbidden — access to resource is not allowed
404Not found — the transcript session is not found or doesn't match the API token

Retrieve Document Response

✅ HTTP 200 OK

The response will be in the following format:

Format: APIResultResponse<DocumentModel>

{
"result": {
"id": "12780b54-5575-44e4-bbca-0a410b432183",
"created": "2021-01-25T10:31:46.960411+00:00",
"last_modified": "2021-01-25T10:31:46.960411+00:00",
"filename": "Example document",
"type": "caption",
"document": [
{
"start": 525,
"stop": 6252,
"speaker": "M1",
"text": "This is just an example.\non two lines."
}
]
}
}

TTML Example Output

Below is an example of a TTML subtitle document generated by Scriptix:

<?xml version="1.0" encoding="UTF-8"?>
<tt xmlns="http://www.w3.org/ns/ttml" xml:lang="en-us">
<head>
<metadata xmlns:ttm="http://www.w3.org/ns/ttml#metadata">
<ttm:title>Scriptix TTML</ttm:title>
</metadata>
<styling xmlns:tts="http://www.w3.org/ns/ttml#styling">
<style xml:id="s1" tts:textAlign="center" tts:fontFamily="Arial" tts:fontSize="100%"/>
</styling>
<layout xmlns:tts="http://www.w3.org/ns/ttml#layout">
<region xml:id="bottom" tts:displayAlign="after" tts:extent="80% 40%" tts:origin="10% 50%"/>
</layout>
</head>
<body region="bottom" style="s1">
<div>
<p begin="00:00:00.000" end="00:00:02.850" style="s1" region="bottom">the quick brown fox jumps over the</p>
<p begin="00:00:02.850" end="00:00:03.570" style="s1" region="bottom">lazy dog</p>
</div>
</body>
</tt>

Subtitle Format Examples

SBV

00:00:00.000 --> 00:00:02.850
the quick brown fox jumps over the

00:00:02.850 --> 00:00:03.570
lazy dog

SRT

srt
Copy
Edit
1
00:00:00.000 --> 00:00:02.850
the quick brown fox jumps over the

2
00:00:02.850 --> 00:00:03.570
lazy dog

VTT

vtt
Copy
Edit
WEBVTT

NOTE This file has been generated by Scriptix

00:00.000 --> 00:02.850
the quick brown fox jumps over the

00:02.850 --> 00:03.570
lazy dog