From ee68575ea4b75ddf704c562542a0b15a58dadbea Mon Sep 17 00:00:00 2001 From: rammohan-kore Date: Tue, 13 Aug 2024 18:58:19 +0530 Subject: [PATCH] Feat/844 Sending callSid in the custom-stt start message (#848) * https://github.com/jambonz/jambonz-feature-server/issues/844 sending callSid in options, so that the callSid is sent to stt websocket in case of custom websocket * feat/844: checking for existance of task.cs.callSid * feat/844: changed the condition to task.cs?.callSid --- lib/utils/transcription-utils.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/utils/transcription-utils.js b/lib/utils/transcription-utils.js index 40986f12..60965c11 100644 --- a/lib/utils/transcription-utils.js +++ b/lib/utils/transcription-utils.js @@ -848,7 +848,8 @@ module.exports = (logger) => { {hints: rOpts.hints}), ...(rOpts.hints?.length > 0 && typeof rOpts.hints[0] === 'object' && {hints: JSON.stringify(rOpts.hints)}), - ...(typeof rOpts.hintsBoost === 'number' && {hintsBoost: rOpts.hintsBoost}) + ...(typeof rOpts.hintsBoost === 'number' && {hintsBoost: rOpts.hintsBoost}), + ...(task.cs?.callSid && {callSid: task.cs.callSid}) }; opts = { ...opts,