useTranscription
useTranscription(params?) : Object
Returns information about a meeting's current transcription state, along with helper functions that wrap daily-js
transcription related methods.
useTranscription
can also be used to set up optional callbacks for transcription events.
Params (optional)
An object with the following optional properties:
Parameter | Type | Description | |
---|---|---|---|
Deprecated | onTranscriptionAppData | Function | Callback for the "app-message" event from transcription |
onTranscriptionError | Function | Callback for the "transcription-error" event | |
onTranscriptionMessage | Function | Callback for the "transcription-message" event | |
onTranscriptionStarted | Function | Callback for the "transcription-started" event | |
onTranscriptionStopped | Function | Callback for the "transcription-stopped" event |
Return type
An object with the following properties:
Name | Type | Description |
---|---|---|
error | boolean | true in the event of a "transcription-error" |
isTranscribing | boolean | Returns true after transcription has started |
language | string | Returns the language applied for the transcription. Please check Deepgram's language docs for details. |
model | string | Returns the model applied for transcription. Please check Deepgram's model docs for more details. |
profanity_filter | boolean | Returns true when profanity filter is enabled. Please check Deepgram's profanity filter docs for more details. |
redact | boolean or array | Returns the redaction applied for transcription. Please check Deepgram's redaction docs for more details. |
startedBy | string | Returns the session_id for the participant who initiated the transcription |
startTranscription | Function | See daily-js startTranscription() |
stopTranscription | Function | See daily-js stopTranscription() |
tier | string | This field is deprecated, use model instead |
transcriptions | Transcription[] | Array of Transcription object. See Transcription for more information. |
transcriptionStartDate | Date | Timestamp for when the transcription started |
updatedBy | string | Returns the session_id for the participant who updated the transcription most recently |