Skip to main content

Response formats and SSE

The examples below were verified with the same 36.442-second recording. It produced four speech segments, so timestamped and streamed output are easier to compare than with a very short clip.

Non-streaming formats

Leave stream unset or set it to false.

response_formatStatusContent typeResult
json200application/jsonTranscript and KittenML metadata
verbose_json200application/jsonDuration 36.442, language English, four segments
text200text/plainComplete clean transcript
srt200application/x-subripFour timestamped SubRip cues
vtt200text/vttFour timestamped WebVTT cues

JSON

Selected fields from the verified response:

{
"text": "The North Wind and the Sun were disputing which was the stronger. When a traveler came along, wrapped in a warm cloak. They agreed that the one who first succeeded in making the traveler take his cloak off should be considered stronger than the other. Then the north wind blew as hard as he could. But the more he blew, the more closely did the traveler fold his cloak around him. And at last, the north wind gave up the attempt. Then the sun shone out warmly, and immediately the traveler took off his cloak. And so the North Wind was obliged to confess that the sun was the stronger of the two.",
"enriched_text": "[articulate]The (North) (Wind) and the (Sun) were (disputing) which was the (stronger)...[/articulate]",
"accent": "British",
"request_id": "<request-id>"
}

The complete JSON response also contains the full tags array. Enrichment labels and wording are model output and can vary between runs.

Verbose JSON

verbose_json adds task, language, exact duration, and a segments array. This selected-field example omits repeated enrichment and tags:

{
"task": "transcribe",
"language": "English",
"duration": 36.442,
"segments": [
{
"id": 0,
"start": 0.432,
"end": 6.664,
"text": "The North Wind and the Sun were disputing which was the stronger. When a traveler came along, wrapped in a warm cloak."
},
{
"id": 1,
"start": 8.032,
"end": 14.128,
"text": "They agreed that the one who first succeeded in making the traveler take his cloak off should be considered stronger than the other."
},
{
"id": 2,
"start": 15.264,
"end": 25.592,
"text": "Then the north wind blew as hard as he could. But the more he blew, the more closely did the traveler fold his cloak around him. And at last, the north wind gave up the attempt."
},
{
"id": 3,
"start": 26.8,
"end": 36.264,
"text": "Then the sun shone out warmly, and immediately the traveler took off his cloak. And so the North Wind was obliged to confess that the sun was the stronger of the two."
}
]
}

Upload segment start and end values are seconds.

Text

The North Wind and the Sun were disputing which was the stronger. When a traveler came along, wrapped in a warm cloak. They agreed that the one who first succeeded in making the traveler take his cloak off should be considered stronger than the other. Then the north wind blew as hard as he could. But the more he blew, the more closely did the traveler fold his cloak around him. And at last, the north wind gave up the attempt. Then the sun shone out warmly, and immediately the traveler took off his cloak. And so the North Wind was obliged to confess that the sun was the stronger of the two.

SRT

1
00:00:00,432 --> 00:00:06,664
The North Wind and the Sun were disputing which was the stronger. When a traveler came along, wrapped in a warm cloak.

2
00:00:08,032 --> 00:00:14,128
They agreed that the one who first succeeded in making the traveler take his cloak off should be considered stronger than the other.

3
00:00:15,264 --> 00:00:25,592
Then the north wind blew as hard as he could. But the more he blew, the more closely did the traveler fold his cloak around him. And at last, the north wind gave up the attempt.

4
00:00:26,800 --> 00:00:36,264
Then the sun shone out warmly, and immediately the traveler took off his cloak. And so the North Wind was obliged to confess that the sun was the stronger of the two.

VTT

WEBVTT

00:00:00.432 --> 00:00:06.664
The North Wind and the Sun were disputing which was the stronger. When a traveler came along, wrapped in a warm cloak.

00:00:08.032 --> 00:00:14.128
They agreed that the one who first succeeded in making the traveler take his cloak off should be considered stronger than the other.

00:00:15.264 --> 00:00:25.592
Then the north wind blew as hard as he could. But the more he blew, the more closely did the traveler fold his cloak around him. And at last, the north wind gave up the attempt.

00:00:26.800 --> 00:00:36.264
Then the sun shone out warmly, and immediately the traveler took off his cloak. And so the North Wind was obliged to confess that the sun was the stronger of the two.

Finite SSE output

Set stream=true to receive text/event-stream regardless of the accepted response_format value. The same long recording emitted 11 delta events before the terminal event. This is abridged output:

data: {"type":"transcript.text.delta","delta":"The North Wind and the Sun","clean_text":"The North Wind and the Sun","request_id":"<request-id>"}

data: {"type":"transcript.text.delta","delta":" were disputing which was","clean_text":"The North Wind and the Sun were disputing which was","request_id":"<request-id>"}

data: {"type":"transcript.text.delta","delta":" the stronger.","clean_text":"The North Wind and the Sun were disputing which was the stronger.","request_id":"<request-id>"}

... eight more transcript.text.delta events ...

data: {"type":"transcript.text.done","text":"The North Wind and the Sun were disputing which was the stronger. ... And so the North Wind was obliged to confess that the sun was the stronger of the two.","accent":"British","segments":[{"id":0,"start":0.432,"end":6.664},{"id":1,"start":8.032,"end":14.128},{"id":2,"start":15.264,"end":25.592},{"id":3,"start":26.8,"end":36.264}],"request_id":"<request-id>"}

data: [DONE]

There can be zero or more delta events. The transcript.text.done event is authoritative, [DONE] terminates the protocol, and the HTTP response then closes. Streaming can improve time to first transcript output; it does not promise shorter total transcription time.

See Upload transcription for the request command and complete field reference.