githubEdit

STT Control

These APIs pause and resume real-time Speech-to-Text (STT) inference for a specific stream at runtime, without restarting the server or recreating the stream.

For full STT configuration, see Realtime Speech-to-Text.

Enable STT

Resumes STT inference for the stream. Audio frames are passed to the Whisper model and subtitle cues are generated again.

Request

chevron-rightPOST v1/vhosts/{vhost}/apps/{app}/streams/{stream}:enableStthashtag

Header

Authorization: Basic {credentials}

# Authorization
    Credentials for HTTP Basic Authentication created with <AccessToken>

Body

{}

Responses

chevron-right200 Okhashtag

The request has succeeded

Header

Content-Type: application/json

Body

{
    "statusCode": 200,
    "message": "OK",
    "response": {
        "enabled": true
    }
}

# statusCode
    Same as HTTP Status Code
# message
    A human-readable description of the response code
# response.enabled
    true if STT is now running
chevron-right401 Unauthorizedhashtag

Authentication required

Header

WWW-Authenticate: Basic realm="OvenMediaEngine"

Body

{
    "message": "[HTTP] Authorization header is required to call API (401)",
    "statusCode": 401
}
chevron-right404 Not Foundhashtag

The given vhost, app, or stream name could not be found, or no STT encoder exists for this stream.

Body

chevron-right503 Service Unavailablehashtag

The Transcoder module is not running.

Disable STT

Pauses STT inference. Audio frames are dropped without processing, and subtitle renditions remain in the stream but stop receiving new cues. The underlying STT model and GPU allocations remain loaded.

Request

chevron-rightPOST v1/vhosts/{vhost}/apps/{app}/streams/{stream}:disableStthashtag

Header

Body

Responses

chevron-right200 Okhashtag

The request has succeeded

Header

Body

chevron-right401 Unauthorizedhashtag

Authentication required

Header

Body

chevron-right404 Not Foundhashtag

The given vhost, app, or stream name could not be found, or no STT encoder exists for this stream.

Body

chevron-right503 Service Unavailablehashtag

The Transcoder module is not running.

Get STT Status

Returns the current enabled state and configuration of all active STT renditions for the stream.

Request

chevron-rightPOST v1/vhosts/{vhost}/apps/{app}/streams/{stream}:sttStatushashtag

Header

Body

Responses

chevron-right200 Okhashtag

The request has succeeded

Header

Body

chevron-right401 Unauthorizedhashtag

Authentication required

Header

Body

chevron-right503 Service Unavailablehashtag

The Transcoder module is not running.

Last updated

Was this helpful?