mavenagi 1.2.10 → 1.2.11
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/Client.d.ts +6 -0
- package/Client.js +32 -22
- package/api/resources/auth/client/Client.d.ts +33 -0
- package/api/resources/auth/client/Client.js +171 -0
- package/api/resources/auth/client/index.d.ts +1 -0
- package/api/resources/auth/client/index.js +2 -0
- package/api/resources/auth/index.d.ts +2 -0
- package/api/resources/auth/index.js +18 -0
- package/api/resources/auth/types/SessionTokenRequest.d.ts +3 -0
- package/api/resources/auth/types/SessionTokenRequest.js +3 -0
- package/api/resources/auth/types/SessionTokenResponse.d.ts +6 -0
- package/api/resources/auth/types/SessionTokenResponse.js +3 -0
- package/api/resources/auth/types/index.d.ts +2 -0
- package/api/resources/auth/types/index.js +18 -0
- package/api/resources/commons/types/ActionBase.d.ts +1 -11
- package/api/resources/commons/types/ActionParameterType.d.ts +3 -0
- package/api/resources/commons/types/ActionParameterType.js +3 -0
- package/api/resources/commons/types/ActionProperties.d.ts +13 -0
- package/api/resources/commons/types/ActionProperties.js +3 -0
- package/api/resources/commons/types/ActionUser.d.ts +46 -0
- package/api/resources/commons/types/ActionUser.js +3 -0
- package/api/resources/commons/types/EntityType.d.ts +1 -0
- package/api/resources/commons/types/EntityType.js +1 -0
- package/api/resources/commons/types/EventField.d.ts +1 -0
- package/api/resources/commons/types/EventField.js +1 -0
- package/api/resources/commons/types/UserEvent.d.ts +2 -0
- package/api/resources/commons/types/index.d.ts +3 -0
- package/api/resources/commons/types/index.js +3 -0
- package/api/resources/index.d.ts +4 -0
- package/api/resources/index.js +5 -1
- package/api/resources/knowledge/types/KnowledgeDocumentRequest.d.ts +1 -1
- package/api/resources/triggers/types/index.d.ts +0 -1
- package/api/resources/triggers/types/index.js +0 -1
- package/api/resources/websockets/client/Client.d.ts +22 -0
- package/api/resources/websockets/client/Client.js +89 -0
- package/api/resources/websockets/client/Socket.d.ts +48 -0
- package/api/resources/websockets/client/Socket.js +172 -0
- package/api/resources/websockets/client/index.d.ts +1 -0
- package/api/resources/websockets/client/index.js +2 -0
- package/api/resources/websockets/index.d.ts +2 -0
- package/api/resources/websockets/index.js +18 -0
- package/api/resources/websockets/types/AgentAudioChunk.d.ts +9 -0
- package/api/resources/websockets/types/AgentAudioChunk.js +3 -0
- package/api/resources/websockets/types/AgentTranscript.d.ts +9 -0
- package/api/resources/websockets/types/AgentTranscript.js +3 -0
- package/api/resources/websockets/types/AudioFormat.d.ts +7 -0
- package/api/resources/websockets/types/AudioFormat.js +10 -0
- package/api/resources/websockets/types/Config.d.ts +15 -0
- package/api/resources/websockets/types/Config.js +3 -0
- package/api/resources/websockets/types/ConversationEnded.d.ts +7 -0
- package/api/resources/websockets/types/ConversationEnded.js +3 -0
- package/api/resources/websockets/types/ConversationReady.d.ts +6 -0
- package/api/resources/websockets/types/ConversationReady.js +3 -0
- package/api/resources/websockets/types/Error_.d.ts +9 -0
- package/api/resources/websockets/types/Error_.js +3 -0
- package/api/resources/websockets/types/ServerEventBase.d.ts +6 -0
- package/api/resources/websockets/types/ServerEventBase.js +3 -0
- package/api/resources/websockets/types/UserAudioChunk.d.ts +8 -0
- package/api/resources/websockets/types/UserAudioChunk.js +3 -0
- package/api/resources/websockets/types/UserFinishedSpeaking.d.ts +7 -0
- package/api/resources/websockets/types/UserFinishedSpeaking.js +3 -0
- package/api/resources/websockets/types/UserStartedSpeaking.d.ts +7 -0
- package/api/resources/websockets/types/UserStartedSpeaking.js +3 -0
- package/api/resources/websockets/types/UserTranscript.d.ts +9 -0
- package/api/resources/websockets/types/UserTranscript.js +3 -0
- package/api/resources/websockets/types/index.d.ts +12 -0
- package/api/resources/websockets/types/index.js +28 -0
- package/core/index.d.ts +1 -0
- package/core/index.js +1 -0
- package/core/websocket/events.d.ts +36 -0
- package/core/websocket/events.js +27 -0
- package/core/websocket/index.d.ts +1 -0
- package/core/websocket/index.js +17 -0
- package/core/websocket/ws.d.ts +147 -0
- package/core/websocket/ws.js +444 -0
- package/dist/Client.d.ts +6 -0
- package/dist/Client.js +32 -22
- package/dist/api/resources/auth/client/Client.d.ts +33 -0
- package/dist/api/resources/auth/client/Client.js +171 -0
- package/dist/api/resources/auth/client/index.d.ts +1 -0
- package/dist/api/resources/auth/client/index.js +2 -0
- package/dist/api/resources/auth/index.d.ts +2 -0
- package/dist/api/resources/auth/index.js +18 -0
- package/dist/api/resources/auth/types/SessionTokenRequest.d.ts +3 -0
- package/dist/api/resources/auth/types/SessionTokenRequest.js +3 -0
- package/dist/api/resources/auth/types/SessionTokenResponse.d.ts +6 -0
- package/dist/api/resources/auth/types/SessionTokenResponse.js +3 -0
- package/dist/api/resources/auth/types/index.d.ts +2 -0
- package/dist/api/resources/auth/types/index.js +18 -0
- package/dist/api/resources/commons/types/ActionBase.d.ts +1 -11
- package/dist/api/resources/commons/types/ActionParameterType.d.ts +3 -0
- package/dist/api/resources/commons/types/ActionParameterType.js +3 -0
- package/dist/api/resources/commons/types/ActionProperties.d.ts +13 -0
- package/dist/api/resources/commons/types/ActionProperties.js +3 -0
- package/dist/api/resources/commons/types/ActionUser.d.ts +46 -0
- package/dist/api/resources/commons/types/ActionUser.js +3 -0
- package/dist/api/resources/commons/types/EntityType.d.ts +1 -0
- package/dist/api/resources/commons/types/EntityType.js +1 -0
- package/dist/api/resources/commons/types/EventField.d.ts +1 -0
- package/dist/api/resources/commons/types/EventField.js +1 -0
- package/dist/api/resources/commons/types/UserEvent.d.ts +2 -0
- package/dist/api/resources/commons/types/index.d.ts +3 -0
- package/dist/api/resources/commons/types/index.js +3 -0
- package/dist/api/resources/index.d.ts +4 -0
- package/dist/api/resources/index.js +5 -1
- package/dist/api/resources/knowledge/types/KnowledgeDocumentRequest.d.ts +1 -1
- package/dist/api/resources/triggers/types/index.d.ts +0 -1
- package/dist/api/resources/triggers/types/index.js +0 -1
- package/dist/api/resources/websockets/client/Client.d.ts +22 -0
- package/dist/api/resources/websockets/client/Client.js +89 -0
- package/dist/api/resources/websockets/client/Socket.d.ts +48 -0
- package/dist/api/resources/websockets/client/Socket.js +172 -0
- package/dist/api/resources/websockets/client/index.d.ts +1 -0
- package/dist/api/resources/websockets/client/index.js +2 -0
- package/dist/api/resources/websockets/index.d.ts +2 -0
- package/dist/api/resources/websockets/index.js +18 -0
- package/dist/api/resources/websockets/types/AgentAudioChunk.d.ts +9 -0
- package/dist/api/resources/websockets/types/AgentAudioChunk.js +3 -0
- package/dist/api/resources/websockets/types/AgentTranscript.d.ts +9 -0
- package/dist/api/resources/websockets/types/AgentTranscript.js +3 -0
- package/dist/api/resources/websockets/types/AudioFormat.d.ts +7 -0
- package/dist/api/resources/websockets/types/AudioFormat.js +10 -0
- package/dist/api/resources/websockets/types/Config.d.ts +15 -0
- package/dist/api/resources/websockets/types/Config.js +3 -0
- package/dist/api/resources/websockets/types/ConversationEnded.d.ts +7 -0
- package/dist/api/resources/websockets/types/ConversationEnded.js +3 -0
- package/dist/api/resources/websockets/types/ConversationReady.d.ts +6 -0
- package/dist/api/resources/websockets/types/ConversationReady.js +3 -0
- package/dist/api/resources/websockets/types/Error_.d.ts +9 -0
- package/dist/api/resources/websockets/types/Error_.js +3 -0
- package/dist/api/resources/websockets/types/ServerEventBase.d.ts +6 -0
- package/dist/api/resources/websockets/types/ServerEventBase.js +3 -0
- package/dist/api/resources/websockets/types/UserAudioChunk.d.ts +8 -0
- package/dist/api/resources/websockets/types/UserAudioChunk.js +3 -0
- package/dist/api/resources/websockets/types/UserFinishedSpeaking.d.ts +7 -0
- package/dist/api/resources/websockets/types/UserFinishedSpeaking.js +3 -0
- package/dist/api/resources/websockets/types/UserStartedSpeaking.d.ts +7 -0
- package/dist/api/resources/websockets/types/UserStartedSpeaking.js +3 -0
- package/dist/api/resources/websockets/types/UserTranscript.d.ts +9 -0
- package/dist/api/resources/websockets/types/UserTranscript.js +3 -0
- package/dist/api/resources/websockets/types/index.d.ts +12 -0
- package/dist/api/resources/websockets/types/index.js +28 -0
- package/dist/core/index.d.ts +1 -0
- package/dist/core/index.js +1 -0
- package/dist/core/websocket/events.d.ts +36 -0
- package/dist/core/websocket/events.js +27 -0
- package/dist/core/websocket/index.d.ts +1 -0
- package/dist/core/websocket/index.js +17 -0
- package/dist/core/websocket/ws.d.ts +147 -0
- package/dist/core/websocket/ws.js +444 -0
- package/dist/serialization/resources/auth/index.d.ts +1 -0
- package/dist/serialization/resources/auth/index.js +17 -0
- package/dist/serialization/resources/auth/types/SessionTokenRequest.d.ts +9 -0
- package/dist/serialization/resources/auth/types/SessionTokenRequest.js +41 -0
- package/dist/serialization/resources/auth/types/SessionTokenResponse.d.ts +10 -0
- package/dist/serialization/resources/auth/types/SessionTokenResponse.js +42 -0
- package/dist/serialization/resources/auth/types/index.d.ts +2 -0
- package/dist/serialization/resources/auth/types/index.js +18 -0
- package/dist/serialization/resources/commons/types/ActionBase.d.ts +3 -8
- package/dist/serialization/resources/commons/types/ActionBase.js +5 -9
- package/dist/serialization/resources/commons/types/ActionParameterType.d.ts +1 -1
- package/dist/serialization/resources/commons/types/ActionParameterType.js +1 -0
- package/dist/serialization/resources/commons/types/ActionProperties.d.ts +14 -0
- package/dist/serialization/resources/commons/types/ActionProperties.js +47 -0
- package/dist/serialization/resources/commons/types/ActionUser.d.ts +17 -0
- package/dist/serialization/resources/commons/types/ActionUser.js +49 -0
- package/dist/serialization/resources/commons/types/EntityType.d.ts +1 -1
- package/dist/serialization/resources/commons/types/EntityType.js +1 -0
- package/dist/serialization/resources/commons/types/EventField.d.ts +1 -1
- package/dist/serialization/resources/commons/types/EventField.js +1 -0
- package/dist/serialization/resources/commons/types/UserEvent.d.ts +1 -0
- package/dist/serialization/resources/commons/types/UserEvent.js +1 -0
- package/dist/serialization/resources/commons/types/index.d.ts +3 -0
- package/dist/serialization/resources/commons/types/index.js +3 -0
- package/dist/serialization/resources/index.d.ts +5 -0
- package/dist/serialization/resources/index.js +6 -1
- package/dist/serialization/resources/knowledge/types/KnowledgeDocumentRequest.d.ts +1 -1
- package/dist/serialization/resources/knowledge/types/KnowledgeDocumentRequest.js +1 -1
- package/dist/serialization/resources/triggers/types/EventTriggerBase.d.ts +1 -1
- package/dist/serialization/resources/triggers/types/EventTriggerBase.js +1 -1
- package/dist/serialization/resources/triggers/types/index.d.ts +0 -1
- package/dist/serialization/resources/triggers/types/index.js +0 -1
- package/dist/serialization/resources/websockets/client/index.d.ts +1 -0
- package/dist/serialization/resources/websockets/client/index.js +17 -0
- package/dist/serialization/resources/websockets/client/socket/WebsocketsSocketResponse.d.ts +15 -0
- package/dist/serialization/resources/websockets/client/socket/WebsocketsSocketResponse.js +56 -0
- package/dist/serialization/resources/websockets/client/socket/index.d.ts +1 -0
- package/dist/serialization/resources/websockets/client/socket/index.js +5 -0
- package/dist/serialization/resources/websockets/index.d.ts +2 -0
- package/dist/serialization/resources/websockets/index.js +18 -0
- package/dist/serialization/resources/websockets/types/AgentAudioChunk.d.ts +11 -0
- package/dist/serialization/resources/websockets/types/AgentAudioChunk.js +45 -0
- package/dist/serialization/resources/websockets/types/AgentTranscript.d.ts +11 -0
- package/dist/serialization/resources/websockets/types/AgentTranscript.js +45 -0
- package/dist/serialization/resources/websockets/types/AudioFormat.d.ts +7 -0
- package/dist/serialization/resources/websockets/types/AudioFormat.js +39 -0
- package/dist/serialization/resources/websockets/types/Config.d.ts +14 -0
- package/dist/serialization/resources/websockets/types/Config.js +46 -0
- package/dist/serialization/resources/websockets/types/ConversationEnded.d.ts +10 -0
- package/dist/serialization/resources/websockets/types/ConversationEnded.js +44 -0
- package/dist/serialization/resources/websockets/types/ConversationReady.d.ts +9 -0
- package/dist/serialization/resources/websockets/types/ConversationReady.js +41 -0
- package/dist/serialization/resources/websockets/types/Error_.d.ts +12 -0
- package/dist/serialization/resources/websockets/types/Error_.js +46 -0
- package/dist/serialization/resources/websockets/types/ServerEventBase.d.ts +9 -0
- package/dist/serialization/resources/websockets/types/ServerEventBase.js +41 -0
- package/dist/serialization/resources/websockets/types/UserAudioChunk.d.ts +10 -0
- package/dist/serialization/resources/websockets/types/UserAudioChunk.js +42 -0
- package/dist/serialization/resources/websockets/types/UserFinishedSpeaking.d.ts +10 -0
- package/dist/serialization/resources/websockets/types/UserFinishedSpeaking.js +44 -0
- package/dist/serialization/resources/websockets/types/UserStartedSpeaking.d.ts +10 -0
- package/dist/serialization/resources/websockets/types/UserStartedSpeaking.js +44 -0
- package/dist/serialization/resources/websockets/types/UserTranscript.d.ts +11 -0
- package/dist/serialization/resources/websockets/types/UserTranscript.js +45 -0
- package/dist/serialization/resources/websockets/types/index.d.ts +12 -0
- package/dist/serialization/resources/websockets/types/index.js +28 -0
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +5 -1
- package/reference.md +73 -5
- package/serialization/resources/auth/index.d.ts +1 -0
- package/serialization/resources/auth/index.js +17 -0
- package/serialization/resources/auth/types/SessionTokenRequest.d.ts +9 -0
- package/serialization/resources/auth/types/SessionTokenRequest.js +41 -0
- package/serialization/resources/auth/types/SessionTokenResponse.d.ts +10 -0
- package/serialization/resources/auth/types/SessionTokenResponse.js +42 -0
- package/serialization/resources/auth/types/index.d.ts +2 -0
- package/serialization/resources/auth/types/index.js +18 -0
- package/serialization/resources/commons/types/ActionBase.d.ts +3 -8
- package/serialization/resources/commons/types/ActionBase.js +5 -9
- package/serialization/resources/commons/types/ActionParameterType.d.ts +1 -1
- package/serialization/resources/commons/types/ActionParameterType.js +1 -0
- package/serialization/resources/commons/types/ActionProperties.d.ts +14 -0
- package/serialization/resources/commons/types/ActionProperties.js +47 -0
- package/serialization/resources/commons/types/ActionUser.d.ts +17 -0
- package/serialization/resources/commons/types/ActionUser.js +49 -0
- package/serialization/resources/commons/types/EntityType.d.ts +1 -1
- package/serialization/resources/commons/types/EntityType.js +1 -0
- package/serialization/resources/commons/types/EventField.d.ts +1 -1
- package/serialization/resources/commons/types/EventField.js +1 -0
- package/serialization/resources/commons/types/UserEvent.d.ts +1 -0
- package/serialization/resources/commons/types/UserEvent.js +1 -0
- package/serialization/resources/commons/types/index.d.ts +3 -0
- package/serialization/resources/commons/types/index.js +3 -0
- package/serialization/resources/index.d.ts +5 -0
- package/serialization/resources/index.js +6 -1
- package/serialization/resources/knowledge/types/KnowledgeDocumentRequest.d.ts +1 -1
- package/serialization/resources/knowledge/types/KnowledgeDocumentRequest.js +1 -1
- package/serialization/resources/triggers/types/EventTriggerBase.d.ts +1 -1
- package/serialization/resources/triggers/types/EventTriggerBase.js +1 -1
- package/serialization/resources/triggers/types/index.d.ts +0 -1
- package/serialization/resources/triggers/types/index.js +0 -1
- package/serialization/resources/websockets/client/index.d.ts +1 -0
- package/serialization/resources/websockets/client/index.js +17 -0
- package/serialization/resources/websockets/client/socket/WebsocketsSocketResponse.d.ts +15 -0
- package/serialization/resources/websockets/client/socket/WebsocketsSocketResponse.js +56 -0
- package/serialization/resources/websockets/client/socket/index.d.ts +1 -0
- package/serialization/resources/websockets/client/socket/index.js +5 -0
- package/serialization/resources/websockets/index.d.ts +2 -0
- package/serialization/resources/websockets/index.js +18 -0
- package/serialization/resources/websockets/types/AgentAudioChunk.d.ts +11 -0
- package/serialization/resources/websockets/types/AgentAudioChunk.js +45 -0
- package/serialization/resources/websockets/types/AgentTranscript.d.ts +11 -0
- package/serialization/resources/websockets/types/AgentTranscript.js +45 -0
- package/serialization/resources/websockets/types/AudioFormat.d.ts +7 -0
- package/serialization/resources/websockets/types/AudioFormat.js +39 -0
- package/serialization/resources/websockets/types/Config.d.ts +14 -0
- package/serialization/resources/websockets/types/Config.js +46 -0
- package/serialization/resources/websockets/types/ConversationEnded.d.ts +10 -0
- package/serialization/resources/websockets/types/ConversationEnded.js +44 -0
- package/serialization/resources/websockets/types/ConversationReady.d.ts +9 -0
- package/serialization/resources/websockets/types/ConversationReady.js +41 -0
- package/serialization/resources/websockets/types/Error_.d.ts +12 -0
- package/serialization/resources/websockets/types/Error_.js +46 -0
- package/serialization/resources/websockets/types/ServerEventBase.d.ts +9 -0
- package/serialization/resources/websockets/types/ServerEventBase.js +41 -0
- package/serialization/resources/websockets/types/UserAudioChunk.d.ts +10 -0
- package/serialization/resources/websockets/types/UserAudioChunk.js +42 -0
- package/serialization/resources/websockets/types/UserFinishedSpeaking.d.ts +10 -0
- package/serialization/resources/websockets/types/UserFinishedSpeaking.js +44 -0
- package/serialization/resources/websockets/types/UserStartedSpeaking.d.ts +10 -0
- package/serialization/resources/websockets/types/UserStartedSpeaking.js +44 -0
- package/serialization/resources/websockets/types/UserTranscript.d.ts +11 -0
- package/serialization/resources/websockets/types/UserTranscript.js +45 -0
- package/serialization/resources/websockets/types/index.d.ts +12 -0
- package/serialization/resources/websockets/types/index.js +28 -0
- package/version.d.ts +1 -1
- package/version.js +1 -1
- /package/api/resources/{triggers → commons}/types/EventTriggerType.d.ts +0 -0
- /package/api/resources/{triggers → commons}/types/EventTriggerType.js +0 -0
- /package/dist/api/resources/{triggers → commons}/types/EventTriggerType.d.ts +0 -0
- /package/dist/api/resources/{triggers → commons}/types/EventTriggerType.js +0 -0
- /package/dist/serialization/resources/{triggers → commons}/types/EventTriggerType.d.ts +0 -0
- /package/dist/serialization/resources/{triggers → commons}/types/EventTriggerType.js +0 -0
- /package/serialization/resources/{triggers → commons}/types/EventTriggerType.d.ts +0 -0
- /package/serialization/resources/{triggers → commons}/types/EventTriggerType.js +0 -0
package/api/resources/index.d.ts
CHANGED
|
@@ -11,6 +11,8 @@ export * from "./appSettings/client/requests";
|
|
|
11
11
|
export * from "./appSettings/types";
|
|
12
12
|
export * as assets from "./assets";
|
|
13
13
|
export * from "./assets/types";
|
|
14
|
+
export * as auth from "./auth";
|
|
15
|
+
export * from "./auth/types";
|
|
14
16
|
export * as commons from "./commons";
|
|
15
17
|
export * from "./commons/errors";
|
|
16
18
|
export * from "./commons/types";
|
|
@@ -41,3 +43,5 @@ export * from "./triggers/types";
|
|
|
41
43
|
export * as users from "./users";
|
|
42
44
|
export * from "./users/client/requests";
|
|
43
45
|
export * from "./users/types";
|
|
46
|
+
export * as websockets from "./websockets";
|
|
47
|
+
export * from "./websockets/types";
|
package/api/resources/index.js
CHANGED
|
@@ -36,7 +36,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
36
36
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
37
37
|
};
|
|
38
38
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
exports.users = exports.triggers = exports.translations = exports.segments = exports.organizations = exports.knowledge = exports.inbox = exports.events = exports.customers = exports.conversation = exports.commons = exports.assets = exports.appSettings = exports.analytics = exports.agents = exports.actions = void 0;
|
|
39
|
+
exports.websockets = exports.users = exports.triggers = exports.translations = exports.segments = exports.organizations = exports.knowledge = exports.inbox = exports.events = exports.customers = exports.conversation = exports.commons = exports.auth = exports.assets = exports.appSettings = exports.analytics = exports.agents = exports.actions = void 0;
|
|
40
40
|
exports.actions = __importStar(require("./actions"));
|
|
41
41
|
__exportStar(require("./actions/client/requests"), exports);
|
|
42
42
|
__exportStar(require("./actions/types"), exports);
|
|
@@ -50,6 +50,8 @@ __exportStar(require("./appSettings/client/requests"), exports);
|
|
|
50
50
|
__exportStar(require("./appSettings/types"), exports);
|
|
51
51
|
exports.assets = __importStar(require("./assets"));
|
|
52
52
|
__exportStar(require("./assets/types"), exports);
|
|
53
|
+
exports.auth = __importStar(require("./auth"));
|
|
54
|
+
__exportStar(require("./auth/types"), exports);
|
|
53
55
|
exports.commons = __importStar(require("./commons"));
|
|
54
56
|
__exportStar(require("./commons/errors"), exports);
|
|
55
57
|
__exportStar(require("./commons/types"), exports);
|
|
@@ -80,3 +82,5 @@ __exportStar(require("./triggers/types"), exports);
|
|
|
80
82
|
exports.users = __importStar(require("./users"));
|
|
81
83
|
__exportStar(require("./users/client/requests"), exports);
|
|
82
84
|
__exportStar(require("./users/types"), exports);
|
|
85
|
+
exports.websockets = __importStar(require("./websockets"));
|
|
86
|
+
__exportStar(require("./websockets/types"), exports);
|
|
@@ -28,7 +28,7 @@ export interface KnowledgeDocumentRequest extends MavenAGI.BaseKnowledgeDocument
|
|
|
28
28
|
/** The title of the document. Will be shown as part of answers. */
|
|
29
29
|
title: string;
|
|
30
30
|
/** ID of the asset associated with this document. This asset will be transformed into text and set as the content of the document. The following types are supported: `application/pdf`, `text/plain`. Either this or content is required, but not both */
|
|
31
|
-
assetId?: MavenAGI.
|
|
31
|
+
assetId?: MavenAGI.EntityIdWithoutAgent;
|
|
32
32
|
/** The content of the document. Not shown directly to users. May be provided in HTML or markdown. HTML will be converted to markdown automatically. Images are not currently supported and will be ignored. Either this or assetId is required, but not both */
|
|
33
33
|
content?: string;
|
|
34
34
|
/** Metadata for the knowledge document. */
|
|
@@ -3,6 +3,5 @@ export * from "./EventTriggerRequest";
|
|
|
3
3
|
export * from "./EventTriggerResponse";
|
|
4
4
|
export * from "./EventTriggersSearchRequest";
|
|
5
5
|
export * from "./EventTriggersSearchResponse";
|
|
6
|
-
export * from "./EventTriggerType";
|
|
7
6
|
export * from "./TriggerField";
|
|
8
7
|
export * from "./TriggerPartialUpdate";
|
|
@@ -19,6 +19,5 @@ __exportStar(require("./EventTriggerRequest"), exports);
|
|
|
19
19
|
__exportStar(require("./EventTriggerResponse"), exports);
|
|
20
20
|
__exportStar(require("./EventTriggersSearchRequest"), exports);
|
|
21
21
|
__exportStar(require("./EventTriggersSearchResponse"), exports);
|
|
22
|
-
__exportStar(require("./EventTriggerType"), exports);
|
|
23
22
|
__exportStar(require("./TriggerField"), exports);
|
|
24
23
|
__exportStar(require("./TriggerPartialUpdate"), exports);
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { BaseClientOptions } from "../../../../BaseClient";
|
|
2
|
+
import { WebsocketsSocket } from "./Socket";
|
|
3
|
+
export declare namespace Websockets {
|
|
4
|
+
interface Options extends BaseClientOptions {
|
|
5
|
+
}
|
|
6
|
+
interface ConnectArgs {
|
|
7
|
+
version?: string | undefined;
|
|
8
|
+
Authorization: string;
|
|
9
|
+
/** Arbitrary headers to send with the websocket connect request. */
|
|
10
|
+
headers?: Record<string, string>;
|
|
11
|
+
/** Enable debug mode on the websocket. Defaults to false. */
|
|
12
|
+
debug?: boolean;
|
|
13
|
+
/** Number of reconnect attempts. Defaults to 30. */
|
|
14
|
+
reconnectAttempts?: number;
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
export declare class Websockets {
|
|
18
|
+
protected readonly _options: Websockets.Options;
|
|
19
|
+
constructor(_options: Websockets.Options);
|
|
20
|
+
connect(args: Websockets.ConnectArgs): Promise<WebsocketsSocket>;
|
|
21
|
+
protected _getAuthorizationHeader(): Promise<string | undefined>;
|
|
22
|
+
}
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
4
|
+
if (k2 === undefined) k2 = k;
|
|
5
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
7
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
8
|
+
}
|
|
9
|
+
Object.defineProperty(o, k2, desc);
|
|
10
|
+
}) : (function(o, m, k, k2) {
|
|
11
|
+
if (k2 === undefined) k2 = k;
|
|
12
|
+
o[k2] = m[k];
|
|
13
|
+
}));
|
|
14
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
15
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
16
|
+
}) : function(o, v) {
|
|
17
|
+
o["default"] = v;
|
|
18
|
+
});
|
|
19
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
20
|
+
var ownKeys = function(o) {
|
|
21
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
22
|
+
var ar = [];
|
|
23
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
24
|
+
return ar;
|
|
25
|
+
};
|
|
26
|
+
return ownKeys(o);
|
|
27
|
+
};
|
|
28
|
+
return function (mod) {
|
|
29
|
+
if (mod && mod.__esModule) return mod;
|
|
30
|
+
var result = {};
|
|
31
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
32
|
+
__setModuleDefault(result, mod);
|
|
33
|
+
return result;
|
|
34
|
+
};
|
|
35
|
+
})();
|
|
36
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
37
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
38
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
39
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
40
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
41
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
42
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
43
|
+
});
|
|
44
|
+
};
|
|
45
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
46
|
+
exports.Websockets = void 0;
|
|
47
|
+
const core = __importStar(require("../../../../core"));
|
|
48
|
+
const headers_1 = require("../../../../core/headers");
|
|
49
|
+
const environments = __importStar(require("../../../../environments"));
|
|
50
|
+
const Socket_1 = require("./Socket");
|
|
51
|
+
class Websockets {
|
|
52
|
+
constructor(_options) {
|
|
53
|
+
this._options = _options;
|
|
54
|
+
}
|
|
55
|
+
connect(args) {
|
|
56
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
57
|
+
var _a, _b;
|
|
58
|
+
const { version, headers, debug, reconnectAttempts } = args;
|
|
59
|
+
const _queryParams = {};
|
|
60
|
+
if (version != null) {
|
|
61
|
+
_queryParams.version = version;
|
|
62
|
+
}
|
|
63
|
+
const _headers = (0, headers_1.mergeHeaders)((0, headers_1.mergeOnlyDefinedHeaders)({ Authorization: args.Authorization }), headers);
|
|
64
|
+
const socket = new core.ReconnectingWebSocket({
|
|
65
|
+
url: core.url.join((_b = (_a = (yield core.Supplier.get(this._options.baseUrl))) !== null && _a !== void 0 ? _a : (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.MavenAGIEnvironment.Production, "/v1/realtime/conversations"),
|
|
66
|
+
protocols: [],
|
|
67
|
+
queryParameters: _queryParams,
|
|
68
|
+
headers: _headers,
|
|
69
|
+
options: { debug: debug !== null && debug !== void 0 ? debug : false, maxRetries: reconnectAttempts !== null && reconnectAttempts !== void 0 ? reconnectAttempts : 30 },
|
|
70
|
+
});
|
|
71
|
+
return new Socket_1.WebsocketsSocket({ socket });
|
|
72
|
+
});
|
|
73
|
+
}
|
|
74
|
+
_getAuthorizationHeader() {
|
|
75
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
76
|
+
var _a, _b;
|
|
77
|
+
const appId = (_a = (yield core.Supplier.get(this._options.appId))) !== null && _a !== void 0 ? _a : process === null || process === void 0 ? void 0 : process.env.MAVENAGI_APP_ID;
|
|
78
|
+
const appSecret = (_b = (yield core.Supplier.get(this._options.appSecret))) !== null && _b !== void 0 ? _b : process === null || process === void 0 ? void 0 : process.env.MAVENAGI_APP_SECRET;
|
|
79
|
+
if (appId != null && appSecret != null) {
|
|
80
|
+
return core.BasicAuth.toAuthorizationHeader({
|
|
81
|
+
username: appId,
|
|
82
|
+
password: appSecret,
|
|
83
|
+
});
|
|
84
|
+
}
|
|
85
|
+
return undefined;
|
|
86
|
+
});
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
exports.Websockets = Websockets;
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import * as core from "../../../../core";
|
|
2
|
+
import type * as MavenAGI from "../../../index";
|
|
3
|
+
export declare namespace WebsocketsSocket {
|
|
4
|
+
interface Args {
|
|
5
|
+
socket: core.ReconnectingWebSocket;
|
|
6
|
+
}
|
|
7
|
+
type Response = MavenAGI.ConversationReady | MavenAGI.AgentAudioChunk | MavenAGI.UserTranscript | MavenAGI.AgentTranscript | MavenAGI.ConversationEnded | MavenAGI.UserStartedSpeaking | MavenAGI.UserFinishedSpeaking | MavenAGI.Error_;
|
|
8
|
+
type EventHandlers = {
|
|
9
|
+
open?: () => void;
|
|
10
|
+
message?: (message: Response) => void;
|
|
11
|
+
close?: (event: core.CloseEvent) => void;
|
|
12
|
+
error?: (error: Error) => void;
|
|
13
|
+
};
|
|
14
|
+
}
|
|
15
|
+
export declare class WebsocketsSocket {
|
|
16
|
+
readonly socket: core.ReconnectingWebSocket;
|
|
17
|
+
protected readonly eventHandlers: WebsocketsSocket.EventHandlers;
|
|
18
|
+
private handleOpen;
|
|
19
|
+
private handleMessage;
|
|
20
|
+
private handleClose;
|
|
21
|
+
private handleError;
|
|
22
|
+
constructor(args: WebsocketsSocket.Args);
|
|
23
|
+
/** The current state of the connection; this is one of the readyState constants. */
|
|
24
|
+
get readyState(): number;
|
|
25
|
+
/**
|
|
26
|
+
* @param event - The event to attach to.
|
|
27
|
+
* @param callback - The callback to run when the event is triggered.
|
|
28
|
+
* Usage:
|
|
29
|
+
* ```typescript
|
|
30
|
+
* this.on('open', () => {
|
|
31
|
+
* console.log('The websocket is open');
|
|
32
|
+
* });
|
|
33
|
+
* ```
|
|
34
|
+
*/
|
|
35
|
+
on<T extends keyof WebsocketsSocket.EventHandlers>(event: T, callback: WebsocketsSocket.EventHandlers[T]): void;
|
|
36
|
+
sendConfig(message: MavenAGI.Config): void;
|
|
37
|
+
sendUserAudioChunk(message: MavenAGI.UserAudioChunk): void;
|
|
38
|
+
/** Connect to the websocket and register event handlers. */
|
|
39
|
+
connect(): WebsocketsSocket;
|
|
40
|
+
/** Close the websocket and unregister event handlers. */
|
|
41
|
+
close(): void;
|
|
42
|
+
/** Returns a promise that resolves when the websocket is open. */
|
|
43
|
+
waitForOpen(): Promise<core.ReconnectingWebSocket>;
|
|
44
|
+
/** Asserts that the websocket is open. */
|
|
45
|
+
private assertSocketIsOpen;
|
|
46
|
+
/** Send a binary payload to the websocket. */
|
|
47
|
+
protected sendBinary(payload: ArrayBufferLike | Blob | ArrayBufferView): void;
|
|
48
|
+
}
|
|
@@ -0,0 +1,172 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
4
|
+
if (k2 === undefined) k2 = k;
|
|
5
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
7
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
8
|
+
}
|
|
9
|
+
Object.defineProperty(o, k2, desc);
|
|
10
|
+
}) : (function(o, m, k, k2) {
|
|
11
|
+
if (k2 === undefined) k2 = k;
|
|
12
|
+
o[k2] = m[k];
|
|
13
|
+
}));
|
|
14
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
15
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
16
|
+
}) : function(o, v) {
|
|
17
|
+
o["default"] = v;
|
|
18
|
+
});
|
|
19
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
20
|
+
var ownKeys = function(o) {
|
|
21
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
22
|
+
var ar = [];
|
|
23
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
24
|
+
return ar;
|
|
25
|
+
};
|
|
26
|
+
return ownKeys(o);
|
|
27
|
+
};
|
|
28
|
+
return function (mod) {
|
|
29
|
+
if (mod && mod.__esModule) return mod;
|
|
30
|
+
var result = {};
|
|
31
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
32
|
+
__setModuleDefault(result, mod);
|
|
33
|
+
return result;
|
|
34
|
+
};
|
|
35
|
+
})();
|
|
36
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
37
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
38
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
39
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
40
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
41
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
42
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
43
|
+
});
|
|
44
|
+
};
|
|
45
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
46
|
+
exports.WebsocketsSocket = void 0;
|
|
47
|
+
const core = __importStar(require("../../../../core"));
|
|
48
|
+
const json_1 = require("../../../../core/json");
|
|
49
|
+
const serializers = __importStar(require("../../../../serialization/index"));
|
|
50
|
+
const Config_1 = require("../../../../serialization/resources/websockets/types/Config");
|
|
51
|
+
const UserAudioChunk_1 = require("../../../../serialization/resources/websockets/types/UserAudioChunk");
|
|
52
|
+
class WebsocketsSocket {
|
|
53
|
+
constructor(args) {
|
|
54
|
+
this.eventHandlers = {};
|
|
55
|
+
this.handleOpen = () => {
|
|
56
|
+
var _a, _b;
|
|
57
|
+
(_b = (_a = this.eventHandlers).open) === null || _b === void 0 ? void 0 : _b.call(_a);
|
|
58
|
+
};
|
|
59
|
+
this.handleMessage = (event) => {
|
|
60
|
+
var _a, _b, _c, _d;
|
|
61
|
+
const data = (0, json_1.fromJson)(event.data);
|
|
62
|
+
const parsedResponse = serializers.WebsocketsSocketResponse.parse(data, {
|
|
63
|
+
unrecognizedObjectKeys: "passthrough",
|
|
64
|
+
allowUnrecognizedUnionMembers: true,
|
|
65
|
+
allowUnrecognizedEnumValues: true,
|
|
66
|
+
});
|
|
67
|
+
if (parsedResponse.ok) {
|
|
68
|
+
(_b = (_a = this.eventHandlers).message) === null || _b === void 0 ? void 0 : _b.call(_a, parsedResponse.value);
|
|
69
|
+
}
|
|
70
|
+
else {
|
|
71
|
+
(_d = (_c = this.eventHandlers).error) === null || _d === void 0 ? void 0 : _d.call(_c, new Error("Received unknown message type"));
|
|
72
|
+
}
|
|
73
|
+
};
|
|
74
|
+
this.handleClose = (event) => {
|
|
75
|
+
var _a, _b;
|
|
76
|
+
(_b = (_a = this.eventHandlers).close) === null || _b === void 0 ? void 0 : _b.call(_a, event);
|
|
77
|
+
};
|
|
78
|
+
this.handleError = (event) => {
|
|
79
|
+
var _a, _b;
|
|
80
|
+
const message = event.message;
|
|
81
|
+
(_b = (_a = this.eventHandlers).error) === null || _b === void 0 ? void 0 : _b.call(_a, new Error(message));
|
|
82
|
+
};
|
|
83
|
+
this.socket = args.socket;
|
|
84
|
+
this.socket.addEventListener("open", this.handleOpen);
|
|
85
|
+
this.socket.addEventListener("message", this.handleMessage);
|
|
86
|
+
this.socket.addEventListener("close", this.handleClose);
|
|
87
|
+
this.socket.addEventListener("error", this.handleError);
|
|
88
|
+
}
|
|
89
|
+
/** The current state of the connection; this is one of the readyState constants. */
|
|
90
|
+
get readyState() {
|
|
91
|
+
return this.socket.readyState;
|
|
92
|
+
}
|
|
93
|
+
/**
|
|
94
|
+
* @param event - The event to attach to.
|
|
95
|
+
* @param callback - The callback to run when the event is triggered.
|
|
96
|
+
* Usage:
|
|
97
|
+
* ```typescript
|
|
98
|
+
* this.on('open', () => {
|
|
99
|
+
* console.log('The websocket is open');
|
|
100
|
+
* });
|
|
101
|
+
* ```
|
|
102
|
+
*/
|
|
103
|
+
on(event, callback) {
|
|
104
|
+
this.eventHandlers[event] = callback;
|
|
105
|
+
}
|
|
106
|
+
sendConfig(message) {
|
|
107
|
+
this.assertSocketIsOpen();
|
|
108
|
+
const jsonPayload = Config_1.Config.jsonOrThrow(message, {
|
|
109
|
+
unrecognizedObjectKeys: "passthrough",
|
|
110
|
+
allowUnrecognizedUnionMembers: true,
|
|
111
|
+
allowUnrecognizedEnumValues: true,
|
|
112
|
+
});
|
|
113
|
+
this.socket.send(JSON.stringify(jsonPayload));
|
|
114
|
+
}
|
|
115
|
+
sendUserAudioChunk(message) {
|
|
116
|
+
this.assertSocketIsOpen();
|
|
117
|
+
const jsonPayload = UserAudioChunk_1.UserAudioChunk.jsonOrThrow(message, {
|
|
118
|
+
unrecognizedObjectKeys: "passthrough",
|
|
119
|
+
allowUnrecognizedUnionMembers: true,
|
|
120
|
+
allowUnrecognizedEnumValues: true,
|
|
121
|
+
});
|
|
122
|
+
this.socket.send(JSON.stringify(jsonPayload));
|
|
123
|
+
}
|
|
124
|
+
/** Connect to the websocket and register event handlers. */
|
|
125
|
+
connect() {
|
|
126
|
+
this.socket.reconnect();
|
|
127
|
+
this.socket.addEventListener("open", this.handleOpen);
|
|
128
|
+
this.socket.addEventListener("message", this.handleMessage);
|
|
129
|
+
this.socket.addEventListener("close", this.handleClose);
|
|
130
|
+
this.socket.addEventListener("error", this.handleError);
|
|
131
|
+
return this;
|
|
132
|
+
}
|
|
133
|
+
/** Close the websocket and unregister event handlers. */
|
|
134
|
+
close() {
|
|
135
|
+
this.socket.close();
|
|
136
|
+
this.handleClose({ code: 1000 });
|
|
137
|
+
this.socket.removeEventListener("open", this.handleOpen);
|
|
138
|
+
this.socket.removeEventListener("message", this.handleMessage);
|
|
139
|
+
this.socket.removeEventListener("close", this.handleClose);
|
|
140
|
+
this.socket.removeEventListener("error", this.handleError);
|
|
141
|
+
}
|
|
142
|
+
/** Returns a promise that resolves when the websocket is open. */
|
|
143
|
+
waitForOpen() {
|
|
144
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
145
|
+
if (this.socket.readyState === core.ReconnectingWebSocket.OPEN) {
|
|
146
|
+
return this.socket;
|
|
147
|
+
}
|
|
148
|
+
return new Promise((resolve, reject) => {
|
|
149
|
+
this.socket.addEventListener("open", () => {
|
|
150
|
+
resolve(this.socket);
|
|
151
|
+
});
|
|
152
|
+
this.socket.addEventListener("error", (event) => {
|
|
153
|
+
reject(event);
|
|
154
|
+
});
|
|
155
|
+
});
|
|
156
|
+
});
|
|
157
|
+
}
|
|
158
|
+
/** Asserts that the websocket is open. */
|
|
159
|
+
assertSocketIsOpen() {
|
|
160
|
+
if (!this.socket) {
|
|
161
|
+
throw new Error("Socket is not connected.");
|
|
162
|
+
}
|
|
163
|
+
if (this.socket.readyState !== core.ReconnectingWebSocket.OPEN) {
|
|
164
|
+
throw new Error("Socket is not open.");
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
/** Send a binary payload to the websocket. */
|
|
168
|
+
sendBinary(payload) {
|
|
169
|
+
this.socket.send(payload);
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
exports.WebsocketsSocket = WebsocketsSocket;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./client"), exports);
|
|
18
|
+
__exportStar(require("./types"), exports);
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.AudioFormat = void 0;
|
|
5
|
+
exports.AudioFormat = {
|
|
6
|
+
Pcm44100: "PCM_44100",
|
|
7
|
+
Pcm16000: "PCM_16000",
|
|
8
|
+
Pcm8000: "PCM_8000",
|
|
9
|
+
Mulaw8000: "MULAW_8000",
|
|
10
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import type * as MavenAGI from "../../../index";
|
|
2
|
+
/**
|
|
3
|
+
* Initialize conversation with configuration parameters
|
|
4
|
+
*/
|
|
5
|
+
export interface Config {
|
|
6
|
+
type: "config";
|
|
7
|
+
/** The user text to send into the conversation. */
|
|
8
|
+
inputFormat: MavenAGI.AudioFormat;
|
|
9
|
+
/** The user text to send into the conversation. */
|
|
10
|
+
outputFormat: MavenAGI.AudioFormat;
|
|
11
|
+
/** The conversation ID which was created prior to starting this conversation. */
|
|
12
|
+
conversationId: string;
|
|
13
|
+
/** The app ID this conversation ID is associated with. */
|
|
14
|
+
appId: string;
|
|
15
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export * from "./AgentAudioChunk";
|
|
2
|
+
export * from "./AgentTranscript";
|
|
3
|
+
export * from "./AudioFormat";
|
|
4
|
+
export * from "./Config";
|
|
5
|
+
export * from "./ConversationEnded";
|
|
6
|
+
export * from "./ConversationReady";
|
|
7
|
+
export * from "./Error_";
|
|
8
|
+
export * from "./ServerEventBase";
|
|
9
|
+
export * from "./UserAudioChunk";
|
|
10
|
+
export * from "./UserFinishedSpeaking";
|
|
11
|
+
export * from "./UserStartedSpeaking";
|
|
12
|
+
export * from "./UserTranscript";
|