@fonoster/common 0.7.0 → 0.7.2
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.
- package/dist/protos/applications.proto +1 -1
- package/dist/protos/voice.proto +0 -5
- package/dist/voice/PlaybackControl.d.ts +5 -5
- package/dist/voice/PlaybackControl.js +5 -5
- package/dist/voice/Stream.d.ts +3 -8
- package/dist/voice/Stream.js +0 -2
- package/dist/voice/voice.d.ts +1 -0
- package/dist/voice/voice.js +1 -0
- package/package.json +3 -3
package/dist/protos/voice.proto
CHANGED
|
@@ -274,9 +274,6 @@ message StartStreamRequest {
|
|
|
274
274
|
WAV = 0;
|
|
275
275
|
}
|
|
276
276
|
StreamAudioFormat format = 3;
|
|
277
|
-
|
|
278
|
-
// Enable VAD (Voice Activity Detection)
|
|
279
|
-
bool enableVad = 4;
|
|
280
277
|
}
|
|
281
278
|
|
|
282
279
|
// Response to a start stream request
|
|
@@ -310,8 +307,6 @@ message StreamPayload {
|
|
|
310
307
|
AUDIO_IN = 0;
|
|
311
308
|
AUDIO_OUT = 1;
|
|
312
309
|
ERROR = 2;
|
|
313
|
-
VOICE_ACTIVITY_START = 3;
|
|
314
|
-
VOICE_ACTIVITY_END = 4;
|
|
315
310
|
}
|
|
316
311
|
StreamMessageType type = 3;
|
|
317
312
|
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { VerbRequest } from "./Verb";
|
|
2
2
|
declare enum PlaybackControlAction {
|
|
3
|
-
STOP = "
|
|
4
|
-
RESTART = "
|
|
5
|
-
PAUSE = "
|
|
6
|
-
UNPAUSE = "
|
|
7
|
-
FORWARD = "
|
|
3
|
+
STOP = "STOP",
|
|
4
|
+
RESTART = "RESTART",
|
|
5
|
+
PAUSE = "PAUSE",
|
|
6
|
+
UNPAUSE = "UNPAUSE",
|
|
7
|
+
FORWARD = "FORWARD"
|
|
8
8
|
}
|
|
9
9
|
type PlaybackControlRequest = VerbRequest & {
|
|
10
10
|
playbackRef: string;
|
|
@@ -3,9 +3,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.PlaybackControlAction = void 0;
|
|
4
4
|
var PlaybackControlAction;
|
|
5
5
|
(function (PlaybackControlAction) {
|
|
6
|
-
PlaybackControlAction["STOP"] = "
|
|
7
|
-
PlaybackControlAction["RESTART"] = "
|
|
8
|
-
PlaybackControlAction["PAUSE"] = "
|
|
9
|
-
PlaybackControlAction["UNPAUSE"] = "
|
|
10
|
-
PlaybackControlAction["FORWARD"] = "
|
|
6
|
+
PlaybackControlAction["STOP"] = "STOP";
|
|
7
|
+
PlaybackControlAction["RESTART"] = "RESTART";
|
|
8
|
+
PlaybackControlAction["PAUSE"] = "PAUSE";
|
|
9
|
+
PlaybackControlAction["UNPAUSE"] = "UNPAUSE";
|
|
10
|
+
PlaybackControlAction["FORWARD"] = "FORWARD";
|
|
11
11
|
})(PlaybackControlAction || (exports.PlaybackControlAction = PlaybackControlAction = {}));
|
package/dist/voice/Stream.d.ts
CHANGED
|
@@ -10,14 +10,11 @@ declare enum StreamAudioFormat {
|
|
|
10
10
|
declare enum StreamMessageType {
|
|
11
11
|
AUDIO_IN = "AUDIO_IN",
|
|
12
12
|
AUDIO_OUT = "AUDIO_OUT",
|
|
13
|
-
ERROR = "ERROR"
|
|
14
|
-
VOICE_ACTIVITY_START = "VOICE_ACTIVITY_START",
|
|
15
|
-
VOICE_ACTIVITY_STOP = "VOICE_ACTIVITY_STOP"
|
|
13
|
+
ERROR = "ERROR"
|
|
16
14
|
}
|
|
17
15
|
type StreamOptions = {
|
|
18
|
-
direction
|
|
19
|
-
format
|
|
20
|
-
enableVad: boolean;
|
|
16
|
+
direction?: StreamDirection;
|
|
17
|
+
format?: StreamAudioFormat;
|
|
21
18
|
};
|
|
22
19
|
type StartStreamRequest = VerbRequest & StreamOptions;
|
|
23
20
|
type StartStreamResponse = VerbResponse & {
|
|
@@ -29,10 +26,8 @@ type StopStreamRequest = VerbRequest & {
|
|
|
29
26
|
type StreamPayload = {
|
|
30
27
|
sessionRef: string;
|
|
31
28
|
streamRef: string;
|
|
32
|
-
direction: StreamDirection;
|
|
33
29
|
format: StreamAudioFormat;
|
|
34
30
|
type: StreamMessageType;
|
|
35
|
-
enableVad?: boolean;
|
|
36
31
|
data?: Buffer;
|
|
37
32
|
code?: string;
|
|
38
33
|
message?: string;
|
package/dist/voice/Stream.js
CHANGED
|
@@ -34,6 +34,4 @@ var StreamMessageType;
|
|
|
34
34
|
StreamMessageType["AUDIO_IN"] = "AUDIO_IN";
|
|
35
35
|
StreamMessageType["AUDIO_OUT"] = "AUDIO_OUT";
|
|
36
36
|
StreamMessageType["ERROR"] = "ERROR";
|
|
37
|
-
StreamMessageType["VOICE_ACTIVITY_START"] = "VOICE_ACTIVITY_START";
|
|
38
|
-
StreamMessageType["VOICE_ACTIVITY_STOP"] = "VOICE_ACTIVITY_STOP";
|
|
39
37
|
})(StreamMessageType || (exports.StreamMessageType = StreamMessageType = {}));
|
package/dist/voice/voice.d.ts
CHANGED
|
@@ -43,6 +43,7 @@ declare enum StreamContent {
|
|
|
43
43
|
START_STREAM_REQUEST = "startStreamRequest",
|
|
44
44
|
START_STREAM_RESPONSE = "startStreamResponse",
|
|
45
45
|
STOP_STREAM_REQUEST = "stopStreamRequest",
|
|
46
|
+
STOP_STREAM_RESPONSE = "stopStreamResponse",
|
|
46
47
|
STREAM_PAYLOAD = "streamPayload",
|
|
47
48
|
START_STREAM_GATHER_REQUEST = "startStreamGatherRequest",
|
|
48
49
|
START_STREAM_GATHER_RESPONSE = "startStreamGatherResponse",
|
package/dist/voice/voice.js
CHANGED
|
@@ -40,6 +40,7 @@ var StreamContent;
|
|
|
40
40
|
StreamContent["START_STREAM_REQUEST"] = "startStreamRequest";
|
|
41
41
|
StreamContent["START_STREAM_RESPONSE"] = "startStreamResponse";
|
|
42
42
|
StreamContent["STOP_STREAM_REQUEST"] = "stopStreamRequest";
|
|
43
|
+
StreamContent["STOP_STREAM_RESPONSE"] = "stopStreamResponse";
|
|
43
44
|
StreamContent["STREAM_PAYLOAD"] = "streamPayload";
|
|
44
45
|
StreamContent["START_STREAM_GATHER_REQUEST"] = "startStreamGatherRequest";
|
|
45
46
|
StreamContent["START_STREAM_GATHER_RESPONSE"] = "startStreamGatherResponse";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fonoster/common",
|
|
3
|
-
"version": "0.7.
|
|
3
|
+
"version": "0.7.2",
|
|
4
4
|
"description": "Common library for Fonoster projects",
|
|
5
5
|
"author": "Pedro Sanders <psanders@fonoster.com>",
|
|
6
6
|
"homepage": "https://github.com/fonoster/fonoster#readme",
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
"clean": "rimraf ./dist node_modules tsconfig.tsbuildinfo"
|
|
19
19
|
},
|
|
20
20
|
"dependencies": {
|
|
21
|
-
"@fonoster/logger": "^0.7.
|
|
21
|
+
"@fonoster/logger": "^0.7.2",
|
|
22
22
|
"@grpc/grpc-js": "~1.10.6",
|
|
23
23
|
"@grpc/proto-loader": "^0.7.12",
|
|
24
24
|
"grpc-health-check": "^2.0.2",
|
|
@@ -42,5 +42,5 @@
|
|
|
42
42
|
"devDependencies": {
|
|
43
43
|
"@types/nodemailer": "^6.4.14"
|
|
44
44
|
},
|
|
45
|
-
"gitHead": "
|
|
45
|
+
"gitHead": "6d858d9920132dfef0dba8965e5005f44de61563"
|
|
46
46
|
}
|