@eka-care/ekascribe-ts-sdk 1.4.32 → 1.4.34

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -17,6 +17,7 @@ export const getConfigV2 = async () => {
17
17
  };
18
18
  }
19
19
  catch (error) {
20
+ // This catch block now only handles actual network errors, timeouts, etc.
20
21
  console.log('Error in getConfigV2 api: ', error);
21
22
  return {
22
23
  code: SDK_STATUS_CODE.INTERNAL_SERVER_ERROR,
@@ -125,7 +125,6 @@ class VadWebClient {
125
125
  this.frame_size = FRAME_SIZE;
126
126
  this.speech_pad_frames = PRE_SPEECH_PAD_FRAMES;
127
127
  this.micVad = {};
128
- this.initVad();
129
128
  }
130
129
  /**
131
130
  * Check for continuous silence and trigger periodic warnings
@@ -1,5 +1,5 @@
1
1
  import { GET_CLIENT_ID, GET_AUTH_TOKEN } from './helper';
2
- const API_TIMEOUT_MS = 5000;
2
+ const API_TIMEOUT_MS = 10000;
3
3
  export default async function fetchWrapper(url, options = {}, timeoutMs = API_TIMEOUT_MS) {
4
4
  const controller = new AbortController();
5
5
  let timeoutId = null;
@@ -25,6 +25,7 @@ export default async function fetchWrapper(url, options = {}, timeoutMs = API_TI
25
25
  if (response.status === 401 || response.status === 403) {
26
26
  console.log('unauthorized - fetch wrapper ', response.status);
27
27
  }
28
+ // Always return the response, even for error status codes
28
29
  return response;
29
30
  }
30
31
  catch (error) {
@@ -14,7 +14,7 @@ const startVoiceRecording = async () => {
14
14
  message: 'Microphone access is required to start recording. Please recheck access.',
15
15
  };
16
16
  }
17
- // await vadInstance?.initVad();
17
+ await vadInstance?.initVad();
18
18
  console.log(vadInstance, 'vad in start recording');
19
19
  const micVad = vadInstance?.getMicVad();
20
20
  console.log(micVad, 'mic vad in start recording');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@eka-care/ekascribe-ts-sdk",
3
- "version": "1.4.32",
3
+ "version": "1.4.34",
4
4
  "main": "dist/index.js",
5
5
  "repository": "git@github.com:eka-care/eka-js-sdk.git",
6
6
  "author": "Sanikagoyal28 <sanikagoyal9@gmail.com>",