mavenagi 1.2.64 → 1.2.65
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/BaseClient.js +2 -2
- package/api/resources/actions/client/Client.js +3 -3
- package/api/resources/agents/client/Client.js +5 -5
- package/api/resources/agents/client/requests/AgentPatchRequest.d.ts +10 -2
- package/api/resources/agents/types/Agent.d.ts +3 -1
- package/api/resources/agents/types/AgentPrompting.d.ts +12 -2
- package/api/resources/appDirectory/client/Client.js +5 -5
- package/api/resources/assets/client/Client.js +1 -1
- package/api/resources/capabilities/client/Client.d.ts +33 -0
- package/api/resources/capabilities/client/Client.js +126 -3
- package/api/resources/capabilities/client/requests/SimulateCapabilityByTypeRequest.d.ts +14 -0
- package/api/resources/capabilities/client/requests/SimulateCapabilityByTypeRequest.js +3 -0
- package/api/resources/capabilities/client/requests/index.d.ts +1 -0
- package/api/resources/capabilities/types/ActionSimulationInput.d.ts +5 -0
- package/api/resources/capabilities/types/ActionSimulationInput.js +3 -0
- package/api/resources/capabilities/types/CapabilitySimulationInput.d.ts +11 -0
- package/api/resources/capabilities/types/CapabilitySimulationInput.js +3 -0
- package/api/resources/capabilities/types/CapabilitySimulationResult.d.ts +10 -0
- package/api/resources/capabilities/types/CapabilitySimulationResult.js +3 -0
- package/api/resources/capabilities/types/ConversationContextSimulationInput.d.ts +14 -0
- package/api/resources/capabilities/types/ConversationContextSimulationInput.js +3 -0
- package/api/resources/capabilities/types/SimulatedUser.d.ts +9 -0
- package/api/resources/capabilities/types/SimulatedUser.js +3 -0
- package/api/resources/capabilities/types/SimulatedUserData.d.ts +6 -0
- package/api/resources/capabilities/types/SimulatedUserData.js +3 -0
- package/api/resources/capabilities/types/index.d.ts +6 -0
- package/api/resources/capabilities/types/index.js +6 -0
- package/api/resources/charters/client/Client.js +4 -4
- package/api/resources/charters/types/CharterBase.d.ts +5 -1
- package/api/resources/charters/types/CharterChildrenExclusionPolicy.d.ts +2 -0
- package/api/resources/charters/types/CharterChildrenExclusionPolicy.js +2 -0
- package/api/resources/charters/types/CharterContent.d.ts +2 -0
- package/api/resources/charters/types/CharterPatchReferences.d.ts +2 -0
- package/api/resources/charters/types/CharterReferences.d.ts +2 -0
- package/api/resources/charters/types/CharterResponse.d.ts +5 -1
- package/api/resources/charters/types/CharterStatus.d.ts +4 -0
- package/api/resources/charters/types/CharterStatus.js +4 -0
- package/api/resources/charters/types/CharterSummary.d.ts +5 -1
- package/api/resources/charters/types/index.d.ts +0 -1
- package/api/resources/charters/types/index.js +0 -1
- package/api/resources/commons/types/ActionExecutionStatus.d.ts +6 -0
- package/api/resources/commons/types/ActionExecutionStatus.js +9 -0
- package/api/resources/commons/types/ActionProperties.d.ts +1 -1
- package/api/resources/commons/types/AdditionalDataKey.d.ts +3 -0
- package/api/resources/commons/types/AdditionalDataKey.js +3 -0
- package/api/resources/commons/types/AppUserRequest.d.ts +11 -0
- package/api/resources/commons/types/BotLogicCharterDetail.d.ts +2 -0
- package/api/resources/commons/types/BotMessage.d.ts +5 -0
- package/api/resources/commons/types/BotMessageStatusReason.d.ts +13 -0
- package/api/resources/commons/types/BotMessageStatusReason.js +16 -0
- package/api/resources/commons/types/Capability.d.ts +4 -0
- package/api/resources/commons/types/Capability.js +4 -0
- package/api/resources/commons/types/CapabilityStatus.d.ts +2 -2
- package/api/resources/commons/types/CapabilityStatus.js +2 -2
- package/api/resources/commons/types/ConversationAnalysis.d.ts +1 -1
- package/api/resources/commons/types/ConversationMetadataValueSource.d.ts +7 -0
- package/api/resources/commons/types/ConversationMetadataValueSource.js +3 -0
- package/api/resources/commons/types/ConversationSummary.d.ts +5 -3
- package/api/resources/commons/types/ConversationValueSource.d.ts +10 -0
- package/api/resources/commons/types/ConversationValueSource.js +3 -0
- package/api/resources/commons/types/EntityType.d.ts +5 -0
- package/api/resources/commons/types/EntityType.js +5 -0
- package/api/resources/commons/types/ErrorReason.d.ts +4 -1
- package/api/resources/commons/types/ErrorReason.js +4 -1
- package/api/resources/commons/types/EventFilter.d.ts +1 -0
- package/api/resources/commons/types/ExecuteActionResponse.d.ts +14 -0
- package/api/resources/commons/types/ExecuteActionResponse.js +3 -0
- package/api/resources/commons/types/ExecutionMode.d.ts +10 -0
- package/api/resources/commons/types/ExecutionMode.js +13 -0
- package/api/resources/commons/types/FunctionVersionBinding.d.ts +11 -0
- package/api/resources/commons/types/FunctionVersionBinding.js +3 -0
- package/api/resources/commons/types/InboxItemDuplicateDocuments.d.ts +1 -1
- package/api/resources/commons/types/InboxItemStatus.d.ts +1 -1
- package/api/resources/commons/types/InboxItemStatus.js +1 -1
- package/api/resources/commons/types/LlmInclusionStatus.d.ts +3 -0
- package/api/resources/commons/types/LlmInclusionStatus.js +3 -0
- package/api/resources/commons/types/MetadataConversationValueFilter.d.ts +15 -0
- package/api/resources/commons/types/MetadataConversationValueFilter.js +3 -0
- package/api/resources/commons/types/MetadataFilter.d.ts +33 -6
- package/api/resources/commons/types/Quality.d.ts +2 -0
- package/api/resources/commons/types/Quality.js +2 -0
- package/api/resources/commons/types/QualityReason.d.ts +4 -0
- package/api/resources/commons/types/QualityReason.js +4 -0
- package/api/resources/commons/types/RelationshipType.d.ts +2 -2
- package/api/resources/commons/types/RelationshipType.js +2 -2
- package/api/resources/commons/types/ResolutionStatus.d.ts +2 -0
- package/api/resources/commons/types/ResolutionStatus.js +2 -0
- package/api/resources/commons/types/ResponseConfig.d.ts +2 -0
- package/api/resources/commons/types/SimulationActionBehavior.d.ts +18 -0
- package/api/resources/commons/types/SimulationActionBehavior.js +3 -0
- package/api/resources/commons/types/SimulationActionCallApp.d.ts +1 -0
- package/api/resources/commons/types/SimulationActionCallApp.js +3 -0
- package/api/resources/commons/types/SimulationActionMock.d.ts +6 -0
- package/api/resources/commons/types/SimulationActionMock.js +3 -0
- package/api/resources/commons/types/SimulationContext.d.ts +19 -0
- package/api/resources/commons/types/SystemEventName.d.ts +5 -2
- package/api/resources/commons/types/SystemEventName.js +5 -2
- package/api/resources/commons/types/UserEvent.d.ts +1 -1
- package/api/resources/commons/types/UserEventName.d.ts +1 -1
- package/api/resources/commons/types/UserEventName.js +1 -1
- package/api/resources/commons/types/index.d.ts +12 -0
- package/api/resources/commons/types/index.js +12 -0
- package/api/resources/conversation/client/Client.d.ts +11 -7
- package/api/resources/conversation/client/Client.js +21 -17
- package/api/resources/conversation/client/requests/ConversationDeleteRequest.d.ts +1 -1
- package/api/resources/conversation/types/BillableFilterField.d.ts +3 -3
- package/api/resources/conversation/types/BillableFilterField.js +3 -3
- package/api/resources/conversation/types/ConversationField.d.ts +8 -0
- package/api/resources/conversation/types/ConversationField.js +8 -0
- package/api/resources/conversation/types/ConversationFilter.d.ts +7 -1
- package/api/resources/conversation/types/ConversationPatchRequest.d.ts +1 -1
- package/api/resources/customers/client/Client.js +2 -2
- package/api/resources/customers/types/CustomerFilter.d.ts +2 -0
- package/api/resources/customers/types/CustomerResponse.d.ts +2 -2
- package/api/resources/events/client/Client.js +1 -1
- package/api/resources/inbox/client/Client.js +6 -6
- package/api/resources/integrations/client/Client.js +1 -1
- package/api/resources/intelligentFields/client/Client.d.ts +3 -2
- package/api/resources/intelligentFields/client/Client.js +6 -5
- package/api/resources/intelligentFields/types/EnumOption.d.ts +1 -1
- package/api/resources/intelligentFields/types/IntelligentFieldBase.d.ts +1 -1
- package/api/resources/intelligentFields/types/IntelligentFieldCore.d.ts +5 -1
- package/api/resources/intelligentFields/types/IntelligentFieldType.d.ts +1 -1
- package/api/resources/intelligentFields/types/IntelligentFieldType.js +1 -1
- package/api/resources/knowledge/client/Client.js +13 -13
- package/api/resources/knowledge/types/KnowledgeBaseIndexingStatus.d.ts +1 -1
- package/api/resources/knowledge/types/KnowledgeBaseIndexingStatus.js +1 -1
- package/api/resources/knowledge/types/KnowledgeBaseResponse.d.ts +3 -1
- package/api/resources/knowledge/types/KnowledgeBaseType.d.ts +2 -0
- package/api/resources/knowledge/types/KnowledgeBaseType.js +2 -0
- package/api/resources/knowledge/types/KnowledgeBaseVersion.d.ts +2 -0
- package/api/resources/knowledge/types/KnowledgeBaseVersionStatus.d.ts +4 -0
- package/api/resources/knowledge/types/KnowledgeBaseVersionStatus.js +4 -0
- package/api/resources/organizations/client/Client.js +4 -4
- package/api/resources/segments/client/Client.d.ts +1 -1
- package/api/resources/segments/client/Client.js +4 -4
- package/api/resources/segments/types/SegmentStatus.d.ts +4 -0
- package/api/resources/segments/types/SegmentStatus.js +4 -0
- package/api/resources/triggers/client/Client.js +3 -3
- package/api/resources/triggers/types/EventTriggerBase.d.ts +2 -0
- package/api/resources/users/client/Client.d.ts +42 -1
- package/api/resources/users/client/Client.js +116 -4
- package/api/resources/users/types/AgentUser.d.ts +3 -0
- package/api/resources/users/types/AgentUserFilter.d.ts +4 -0
- package/api/resources/voiceConversations/client/Client.d.ts +1 -1
- package/api/resources/voiceConversations/client/Socket.d.ts +2 -2
- package/api/resources/voiceConversations/client/Socket.js +16 -17
- package/core/fetcher/Fetcher.js +33 -3
- package/core/fetcher/getErrorResponseBody.js +20 -7
- package/core/fetcher/getResponseBody.d.ts +16 -0
- package/core/fetcher/getResponseBody.js +27 -22
- package/core/fetcher/makePassthroughRequest.js +20 -4
- package/core/fetcher/makeRequest.d.ts +6 -1
- package/core/fetcher/makeRequest.js +38 -5
- package/core/fetcher/requestWithRetries.d.ts +1 -1
- package/core/fetcher/requestWithRetries.js +23 -2
- package/core/fetcher/signals.d.ts +1 -0
- package/core/fetcher/signals.js +3 -2
- package/core/stream/Stream.d.ts +3 -0
- package/core/stream/Stream.js +5 -0
- package/core/url/encodePathParam.d.ts +3 -1
- package/core/url/encodePathParam.js +8 -2
- package/core/websocket/ws.d.ts +16 -2
- package/core/websocket/ws.js +110 -20
- package/errors/MavenAGIError.js +16 -2
- package/package.json +1 -1
- package/reference.md +188 -11
- package/serialization/resources/capabilities/types/ActionSimulationInput.d.ts +10 -0
- package/serialization/resources/capabilities/types/ActionSimulationInput.js +44 -0
- package/serialization/resources/capabilities/types/CapabilitySimulationInput.d.ts +11 -0
- package/serialization/resources/capabilities/types/CapabilitySimulationInput.js +47 -0
- package/serialization/resources/capabilities/types/CapabilitySimulationResult.d.ts +11 -0
- package/serialization/resources/capabilities/types/CapabilitySimulationResult.js +47 -0
- package/serialization/resources/capabilities/types/ConversationContextSimulationInput.d.ts +12 -0
- package/serialization/resources/capabilities/types/ConversationContextSimulationInput.js +46 -0
- package/serialization/resources/capabilities/types/SimulatedUser.d.ts +10 -0
- package/serialization/resources/capabilities/types/SimulatedUser.js +44 -0
- package/serialization/resources/capabilities/types/SimulatedUserData.d.ts +10 -0
- package/serialization/resources/capabilities/types/SimulatedUserData.js +42 -0
- package/serialization/resources/capabilities/types/index.d.ts +6 -0
- package/serialization/resources/capabilities/types/index.js +6 -0
- package/serialization/resources/charters/types/CharterContent.d.ts +1 -1
- package/serialization/resources/charters/types/CharterContent.js +1 -1
- package/serialization/resources/charters/types/CharterResponse.d.ts +1 -1
- package/serialization/resources/charters/types/CharterResponse.js +1 -1
- package/serialization/resources/charters/types/CharterSummary.d.ts +1 -1
- package/serialization/resources/charters/types/CharterSummary.js +1 -1
- package/serialization/resources/charters/types/index.d.ts +0 -1
- package/serialization/resources/charters/types/index.js +0 -1
- package/serialization/resources/commons/types/ActionExecutionStatus.d.ts +7 -0
- package/serialization/resources/commons/types/ActionExecutionStatus.js +39 -0
- package/serialization/resources/commons/types/AdditionalDataKey.d.ts +1 -1
- package/serialization/resources/commons/types/AdditionalDataKey.js +1 -0
- package/serialization/resources/commons/types/AppUserRequest.d.ts +2 -0
- package/serialization/resources/commons/types/AppUserRequest.js +2 -0
- package/serialization/resources/commons/types/BotLogicCharterDetail.d.ts +2 -0
- package/serialization/resources/commons/types/BotLogicCharterDetail.js +2 -0
- package/serialization/resources/commons/types/BotMessage.d.ts +2 -0
- package/serialization/resources/commons/types/BotMessage.js +2 -0
- package/serialization/resources/commons/types/BotMessageStatusReason.d.ts +7 -0
- package/serialization/resources/commons/types/BotMessageStatusReason.js +43 -0
- package/serialization/resources/commons/types/ConversationMetadataValueSource.d.ts +9 -0
- package/serialization/resources/commons/types/ConversationMetadataValueSource.js +41 -0
- package/serialization/resources/commons/types/ConversationValueSource.d.ts +11 -0
- package/serialization/resources/commons/types/ConversationValueSource.js +47 -0
- package/serialization/resources/commons/types/EntityType.d.ts +1 -1
- package/serialization/resources/commons/types/EntityType.js +5 -0
- package/serialization/resources/commons/types/ErrorReason.d.ts +1 -1
- package/serialization/resources/commons/types/ErrorReason.js +1 -0
- package/serialization/resources/commons/types/ExecuteActionResponse.d.ts +13 -0
- package/serialization/resources/commons/types/ExecuteActionResponse.js +45 -0
- package/serialization/resources/commons/types/ExecutionMode.d.ts +7 -0
- package/serialization/resources/commons/types/ExecutionMode.js +39 -0
- package/serialization/resources/commons/types/FunctionVersionBinding.d.ts +11 -0
- package/serialization/resources/commons/types/FunctionVersionBinding.js +43 -0
- package/serialization/resources/commons/types/MetadataConversationValueFilter.d.ts +11 -0
- package/serialization/resources/commons/types/MetadataConversationValueFilter.js +43 -0
- package/serialization/resources/commons/types/MetadataFilter.d.ts +5 -1
- package/serialization/resources/commons/types/MetadataFilter.js +2 -0
- package/serialization/resources/commons/types/SimulationActionBehavior.d.ts +15 -0
- package/serialization/resources/commons/types/SimulationActionBehavior.js +49 -0
- package/serialization/resources/commons/types/SimulationActionCallApp.d.ts +7 -0
- package/serialization/resources/commons/types/SimulationActionCallApp.js +39 -0
- package/serialization/resources/commons/types/SimulationActionMock.d.ts +12 -0
- package/serialization/resources/commons/types/SimulationActionMock.js +44 -0
- package/serialization/resources/commons/types/SimulationContext.d.ts +4 -0
- package/serialization/resources/commons/types/SimulationContext.js +4 -0
- package/serialization/resources/commons/types/SystemEventName.d.ts +1 -1
- package/serialization/resources/commons/types/SystemEventName.js +1 -0
- package/serialization/resources/commons/types/index.d.ts +12 -0
- package/serialization/resources/commons/types/index.js +12 -0
- package/serialization/resources/users/types/AgentUser.d.ts +2 -0
- package/serialization/resources/users/types/AgentUser.js +2 -0
- package/serialization/resources/users/types/AgentUserFilter.d.ts +2 -0
- package/serialization/resources/users/types/AgentUserFilter.js +2 -0
- package/version.d.ts +1 -1
- package/version.js +1 -1
- /package/api/resources/{charters → commons}/types/CharterType.d.ts +0 -0
- /package/api/resources/{charters → commons}/types/CharterType.js +0 -0
- /package/serialization/resources/{charters → commons}/types/CharterType.d.ts +0 -0
- /package/serialization/resources/{charters → commons}/types/CharterType.js +0 -0
|
@@ -298,7 +298,7 @@ class KnowledgeClient {
|
|
|
298
298
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
299
299
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
300
300
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
301
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId)}`),
|
|
301
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId, errors.MavenAGIError)}`),
|
|
302
302
|
method: "GET",
|
|
303
303
|
headers: _headers,
|
|
304
304
|
queryString: core.url
|
|
@@ -406,7 +406,7 @@ class KnowledgeClient {
|
|
|
406
406
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
407
407
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
408
408
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
409
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId)}/refresh`),
|
|
409
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId, errors.MavenAGIError)}/refresh`),
|
|
410
410
|
method: "POST",
|
|
411
411
|
headers: _headers,
|
|
412
412
|
contentType: "application/json",
|
|
@@ -506,7 +506,7 @@ class KnowledgeClient {
|
|
|
506
506
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
507
507
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
508
508
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
509
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId)}/cancel`),
|
|
509
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId, errors.MavenAGIError)}/cancel`),
|
|
510
510
|
method: "POST",
|
|
511
511
|
headers: _headers,
|
|
512
512
|
contentType: "application/json",
|
|
@@ -599,7 +599,7 @@ class KnowledgeClient {
|
|
|
599
599
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
600
600
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
601
601
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
602
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId)}/rollback`),
|
|
602
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId, errors.MavenAGIError)}/rollback`),
|
|
603
603
|
method: "POST",
|
|
604
604
|
headers: _headers,
|
|
605
605
|
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
@@ -703,7 +703,7 @@ class KnowledgeClient {
|
|
|
703
703
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
704
704
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
705
705
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
706
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId)}`),
|
|
706
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId, errors.MavenAGIError)}`),
|
|
707
707
|
method: "PATCH",
|
|
708
708
|
headers: _headers,
|
|
709
709
|
contentType: "application/merge-patch+json",
|
|
@@ -812,7 +812,7 @@ class KnowledgeClient {
|
|
|
812
812
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
813
813
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
814
814
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
815
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId)}/version`),
|
|
815
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId, errors.MavenAGIError)}/version`),
|
|
816
816
|
method: "POST",
|
|
817
817
|
headers: _headers,
|
|
818
818
|
contentType: "application/json",
|
|
@@ -921,7 +921,7 @@ class KnowledgeClient {
|
|
|
921
921
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
922
922
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
923
923
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
924
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId)}/version/finalize`),
|
|
924
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId, errors.MavenAGIError)}/version/finalize`),
|
|
925
925
|
method: "POST",
|
|
926
926
|
headers: _headers,
|
|
927
927
|
contentType: "application/json",
|
|
@@ -1040,7 +1040,7 @@ class KnowledgeClient {
|
|
|
1040
1040
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
1041
1041
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
1042
1042
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
1043
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId)}/version/progress`),
|
|
1043
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId, errors.MavenAGIError)}/version/progress`),
|
|
1044
1044
|
method: "POST",
|
|
1045
1045
|
headers: _headers,
|
|
1046
1046
|
contentType: "application/json",
|
|
@@ -1148,7 +1148,7 @@ class KnowledgeClient {
|
|
|
1148
1148
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
1149
1149
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
1150
1150
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
1151
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId)}/versions`),
|
|
1151
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId, errors.MavenAGIError)}/versions`),
|
|
1152
1152
|
method: "GET",
|
|
1153
1153
|
headers: _headers,
|
|
1154
1154
|
queryString: core.url
|
|
@@ -1373,7 +1373,7 @@ class KnowledgeClient {
|
|
|
1373
1373
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
1374
1374
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
1375
1375
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
1376
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId)}/document`),
|
|
1376
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId, errors.MavenAGIError)}/document`),
|
|
1377
1377
|
method: "POST",
|
|
1378
1378
|
headers: _headers,
|
|
1379
1379
|
contentType: "application/json",
|
|
@@ -1485,7 +1485,7 @@ class KnowledgeClient {
|
|
|
1485
1485
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
1486
1486
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
1487
1487
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
1488
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId)}/${core.url.encodePathParam(knowledgeDocumentReferenceId)}/document`),
|
|
1488
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId, errors.MavenAGIError)}/${core.url.encodePathParam(knowledgeDocumentReferenceId, errors.MavenAGIError)}/document`),
|
|
1489
1489
|
method: "DELETE",
|
|
1490
1490
|
headers: _headers,
|
|
1491
1491
|
contentType: "application/json",
|
|
@@ -1586,7 +1586,7 @@ class KnowledgeClient {
|
|
|
1586
1586
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
1587
1587
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
1588
1588
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
1589
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/versions/${core.url.encodePathParam(knowledgeBaseVersionReferenceId)}/documents/${core.url.encodePathParam(knowledgeDocumentReferenceId)}`),
|
|
1589
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/versions/${core.url.encodePathParam(knowledgeBaseVersionReferenceId, errors.MavenAGIError)}/documents/${core.url.encodePathParam(knowledgeDocumentReferenceId, errors.MavenAGIError)}`),
|
|
1590
1590
|
method: "GET",
|
|
1591
1591
|
headers: _headers,
|
|
1592
1592
|
queryString: core.url
|
|
@@ -1697,7 +1697,7 @@ class KnowledgeClient {
|
|
|
1697
1697
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
1698
1698
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
1699
1699
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
1700
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId)}/${core.url.encodePathParam(knowledgeDocumentReferenceId)}/document`),
|
|
1700
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/knowledge/${core.url.encodePathParam(knowledgeBaseReferenceId, errors.MavenAGIError)}/${core.url.encodePathParam(knowledgeDocumentReferenceId, errors.MavenAGIError)}/document`),
|
|
1701
1701
|
method: "PATCH",
|
|
1702
1702
|
headers: _headers,
|
|
1703
1703
|
contentType: "application/merge-patch+json",
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/** The indexing status of the knowledge base version */
|
|
1
|
+
/** The indexing status of the knowledge base version. In the Agent Designer "Refresh Log", `BUILDING`, `INDEXING` and `INDEXED` show as "Syncing", `PUBLISHED` as "Synced", and `SUPERSEDED`, `ROLLING_BACK` and `ROLLED_BACK` as "Interrupted". */
|
|
2
2
|
export declare const KnowledgeBaseIndexingStatus: {
|
|
3
3
|
readonly Building: "BUILDING";
|
|
4
4
|
readonly Indexing: "INDEXING";
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// This file was auto-generated by Fern from our API Definition.
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
4
|
exports.KnowledgeBaseIndexingStatus = void 0;
|
|
5
|
-
/** The indexing status of the knowledge base version */
|
|
5
|
+
/** The indexing status of the knowledge base version. In the Agent Designer "Refresh Log", `BUILDING`, `INDEXING` and `INDEXED` show as "Syncing", `PUBLISHED` as "Synced", and `SUPERSEDED`, `ROLLING_BACK` and `ROLLED_BACK` as "Interrupted". */
|
|
6
6
|
exports.KnowledgeBaseIndexingStatus = {
|
|
7
7
|
Building: "BUILDING",
|
|
8
8
|
Indexing: "INDEXING",
|
|
@@ -55,9 +55,11 @@ export interface KnowledgeBaseResponse extends MavenAGI.KnowledgeBaseProperties
|
|
|
55
55
|
* The status of the most recent version of the knowledge base.
|
|
56
56
|
* The `activeVersionId` will only be populated if this status is `SUCCEEDED`.
|
|
57
57
|
* Use the `listKnowledgeBaseVersions` endpoint to get the full list of versions.
|
|
58
|
+
*
|
|
59
|
+
* Shown in Agent Designer as "Refresh status".
|
|
58
60
|
*/
|
|
59
61
|
mostRecentVersionStatus: MavenAGI.KnowledgeBaseVersionStatus;
|
|
60
|
-
/** The type of the knowledge base. Can not be changed once created. */
|
|
62
|
+
/** The type of the knowledge base. Can not be changed once created. Shown in Agent Designer as "Source". */
|
|
61
63
|
type: MavenAGI.KnowledgeBaseType;
|
|
62
64
|
/** Metadata for the knowledge base. */
|
|
63
65
|
metadata: Record<string, string>;
|
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
/** The status of the knowledge base version */
|
|
2
2
|
export declare const KnowledgeBaseVersionStatus: {
|
|
3
|
+
/**
|
|
4
|
+
* Shown in Agent Designer as "Success". */
|
|
3
5
|
readonly Succeeded: "SUCCEEDED";
|
|
4
6
|
readonly Failed: "FAILED";
|
|
7
|
+
/**
|
|
8
|
+
* Shown in Agent Designer as "Processing". */
|
|
5
9
|
readonly InProgress: "IN_PROGRESS";
|
|
6
10
|
/**
|
|
7
11
|
* Stopped before completing, by a cancel request rather than a failure. */
|
|
@@ -4,8 +4,12 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
4
4
|
exports.KnowledgeBaseVersionStatus = void 0;
|
|
5
5
|
/** The status of the knowledge base version */
|
|
6
6
|
exports.KnowledgeBaseVersionStatus = {
|
|
7
|
+
/**
|
|
8
|
+
* Shown in Agent Designer as "Success". */
|
|
7
9
|
Succeeded: "SUCCEEDED",
|
|
8
10
|
Failed: "FAILED",
|
|
11
|
+
/**
|
|
12
|
+
* Shown in Agent Designer as "Processing". */
|
|
9
13
|
InProgress: "IN_PROGRESS",
|
|
10
14
|
/**
|
|
11
15
|
* Stopped before completing, by a cancel request rather than a failure. */
|
|
@@ -94,7 +94,7 @@ class OrganizationsClient {
|
|
|
94
94
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
95
95
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
96
96
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
97
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/organizations/${core.url.encodePathParam(organizationReferenceId)}`),
|
|
97
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/organizations/${core.url.encodePathParam(organizationReferenceId, errors.MavenAGIError)}`),
|
|
98
98
|
method: "POST",
|
|
99
99
|
headers: _headers,
|
|
100
100
|
contentType: "application/json",
|
|
@@ -195,7 +195,7 @@ class OrganizationsClient {
|
|
|
195
195
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
196
196
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
197
197
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
198
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/organizations/${core.url.encodePathParam(organizationReferenceId)}`),
|
|
198
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/organizations/${core.url.encodePathParam(organizationReferenceId, errors.MavenAGIError)}`),
|
|
199
199
|
method: "GET",
|
|
200
200
|
headers: _headers,
|
|
201
201
|
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
@@ -299,7 +299,7 @@ class OrganizationsClient {
|
|
|
299
299
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
300
300
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
301
301
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
302
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/organizations/${core.url.encodePathParam(organizationReferenceId)}`),
|
|
302
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/organizations/${core.url.encodePathParam(organizationReferenceId, errors.MavenAGIError)}`),
|
|
303
303
|
method: "PATCH",
|
|
304
304
|
headers: _headers,
|
|
305
305
|
contentType: "application/json",
|
|
@@ -404,7 +404,7 @@ class OrganizationsClient {
|
|
|
404
404
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
405
405
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
406
406
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
407
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/organizations/${core.url.encodePathParam(organizationReferenceId)}`),
|
|
407
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/organizations/${core.url.encodePathParam(organizationReferenceId, errors.MavenAGIError)}`),
|
|
408
408
|
method: "DELETE",
|
|
409
409
|
headers: _headers,
|
|
410
410
|
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
@@ -118,7 +118,7 @@ export declare class SegmentsClient {
|
|
|
118
118
|
*
|
|
119
119
|
* Soft delete a segment. Only INACTIVE segments can be deleted.
|
|
120
120
|
*
|
|
121
|
-
* Deleted segments are excluded from search results but can still be retrieved by ID for archival purposes. Creating a
|
|
121
|
+
* Deleted segments are excluded from search results but can still be retrieved by ID for archival purposes. Creating a segment with the same referenceId as a deleted segment reclaims it: the segment keeps its identity, and every other setting comes from the request.
|
|
122
122
|
*
|
|
123
123
|
* Deleted segments cannot be modified.
|
|
124
124
|
*
|
|
@@ -313,7 +313,7 @@ class SegmentsClient {
|
|
|
313
313
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
314
314
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
315
315
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
316
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/segments/${core.url.encodePathParam(segmentReferenceId)}`),
|
|
316
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/segments/${core.url.encodePathParam(segmentReferenceId, errors.MavenAGIError)}`),
|
|
317
317
|
method: "GET",
|
|
318
318
|
headers: _headers,
|
|
319
319
|
queryString: core.url
|
|
@@ -421,7 +421,7 @@ class SegmentsClient {
|
|
|
421
421
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
422
422
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
423
423
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
424
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/segments/${core.url.encodePathParam(segmentReferenceId)}`),
|
|
424
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/segments/${core.url.encodePathParam(segmentReferenceId, errors.MavenAGIError)}`),
|
|
425
425
|
method: "PATCH",
|
|
426
426
|
headers: _headers,
|
|
427
427
|
contentType: "application/merge-patch+json",
|
|
@@ -498,7 +498,7 @@ class SegmentsClient {
|
|
|
498
498
|
*
|
|
499
499
|
* Soft delete a segment. Only INACTIVE segments can be deleted.
|
|
500
500
|
*
|
|
501
|
-
* Deleted segments are excluded from search results but can still be retrieved by ID for archival purposes. Creating a
|
|
501
|
+
* Deleted segments are excluded from search results but can still be retrieved by ID for archival purposes. Creating a segment with the same referenceId as a deleted segment reclaims it: the segment keeps its identity, and every other setting comes from the request.
|
|
502
502
|
*
|
|
503
503
|
* Deleted segments cannot be modified.
|
|
504
504
|
*
|
|
@@ -533,7 +533,7 @@ class SegmentsClient {
|
|
|
533
533
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
534
534
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
535
535
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
536
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/segments/${core.url.encodePathParam(segmentReferenceId)}`),
|
|
536
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/segments/${core.url.encodePathParam(segmentReferenceId, errors.MavenAGIError)}`),
|
|
537
537
|
method: "DELETE",
|
|
538
538
|
headers: _headers,
|
|
539
539
|
queryString: core.url
|
|
@@ -3,7 +3,11 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
4
|
exports.SegmentStatus = void 0;
|
|
5
5
|
exports.SegmentStatus = {
|
|
6
|
+
/**
|
|
7
|
+
* Shown in Agent Designer as "Live". */
|
|
6
8
|
Active: "ACTIVE",
|
|
9
|
+
/**
|
|
10
|
+
* Shown in Agent Designer as "Draft". */
|
|
7
11
|
Inactive: "INACTIVE",
|
|
8
12
|
Deleted: "DELETED",
|
|
9
13
|
};
|
|
@@ -314,7 +314,7 @@ class TriggersClient {
|
|
|
314
314
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
315
315
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
316
316
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
317
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/triggers/${core.url.encodePathParam(triggerReferenceId)}`),
|
|
317
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/triggers/${core.url.encodePathParam(triggerReferenceId, errors.MavenAGIError)}`),
|
|
318
318
|
method: "GET",
|
|
319
319
|
headers: _headers,
|
|
320
320
|
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
@@ -417,7 +417,7 @@ class TriggersClient {
|
|
|
417
417
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
418
418
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
419
419
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
420
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/triggers/${core.url.encodePathParam(triggerReferenceId)}`),
|
|
420
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/triggers/${core.url.encodePathParam(triggerReferenceId, errors.MavenAGIError)}`),
|
|
421
421
|
method: "DELETE",
|
|
422
422
|
headers: _headers,
|
|
423
423
|
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
@@ -515,7 +515,7 @@ class TriggersClient {
|
|
|
515
515
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
516
516
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
517
517
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
518
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/triggers/${core.url.encodePathParam(triggerReferenceId)}`),
|
|
518
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/triggers/${core.url.encodePathParam(triggerReferenceId, errors.MavenAGIError)}`),
|
|
519
519
|
method: "PATCH",
|
|
520
520
|
headers: _headers,
|
|
521
521
|
contentType: "application/merge-patch+json",
|
|
@@ -17,6 +17,8 @@ export interface EventTriggerBase {
|
|
|
17
17
|
* removes one; PATCH changes or removes a condition without re-registering.
|
|
18
18
|
*
|
|
19
19
|
* Only allowed on `EVENT_CREATED`; the other trigger types reject it.
|
|
20
|
+
*
|
|
21
|
+
* Shown in Agent Designer as "When".
|
|
20
22
|
*/
|
|
21
23
|
condition?: MavenAGI.EventCondition;
|
|
22
24
|
}
|
|
@@ -52,6 +52,42 @@ export declare class UsersClient {
|
|
|
52
52
|
*/
|
|
53
53
|
getAgentUser(agentUserId: string, requestOptions?: UsersClient.RequestOptions): core.HttpResponsePromise<MavenAGI.AgentUser>;
|
|
54
54
|
private __getAgentUser;
|
|
55
|
+
/**
|
|
56
|
+
* @beta This endpoint is in development and may change.
|
|
57
|
+
*
|
|
58
|
+
* Deletes the identifiers and user data that every app has saved for an agent user.
|
|
59
|
+
* This is the same as calling `DELETE /users/{userId}` for each of the agent user's app users.
|
|
60
|
+
*
|
|
61
|
+
* The agent user and its app users still exist afterwards, with no identifiers or user data.
|
|
62
|
+
* Apps can keep writing to them; a later create or update adds data back to the same users.
|
|
63
|
+
*
|
|
64
|
+
* Conversations, their messages and events are not modified, apart from the intelligent field values below. To wipe a conversation, use `DELETE /conversations/{conversationId}`.
|
|
65
|
+
*
|
|
66
|
+
* If the ID belongs to an agent user that has been merged into another, the agent user it was merged into is wiped.
|
|
67
|
+
*
|
|
68
|
+
* <Warning>This is a destructive operation and cannot be undone.</Warning>
|
|
69
|
+
*
|
|
70
|
+
* ### Intelligent fields
|
|
71
|
+
*
|
|
72
|
+
* The agent user's intelligent field values are deleted too, and removed from their `INTELLIGENT_FIELD_VALUE_CHANGED` events; the events themselves are kept.
|
|
73
|
+
* Unlike `DELETE /users/{userId}`, the wipe does not recompute the values. They can be computed again later from the user's remaining conversations, for example after the user sends another message; wipe those conversations first to prevent that.
|
|
74
|
+
*
|
|
75
|
+
* @param {string} agentUserId - The ID of the agent user to wipe.
|
|
76
|
+
* @param {UsersClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
77
|
+
*
|
|
78
|
+
* @throws {@link MavenAGI.NotFoundError}
|
|
79
|
+
* @throws {@link MavenAGI.BadRequestError}
|
|
80
|
+
* @throws {@link MavenAGI.PayloadTooLargeError}
|
|
81
|
+
* @throws {@link MavenAGI.TooManyRequestsError}
|
|
82
|
+
* @throws {@link MavenAGI.ServerError}
|
|
83
|
+
* @throws {@link errors.MavenAGIError}
|
|
84
|
+
* @throws {@link errors.MavenAGITimeoutError}
|
|
85
|
+
*
|
|
86
|
+
* @example
|
|
87
|
+
* await client.users.deleteAgentUser("aus_1234567890")
|
|
88
|
+
*/
|
|
89
|
+
deleteAgentUser(agentUserId: string, requestOptions?: UsersClient.RequestOptions): core.HttpResponsePromise<void>;
|
|
90
|
+
private __deleteAgentUser;
|
|
55
91
|
/**
|
|
56
92
|
* Update an app user or create it if it doesn't exist.
|
|
57
93
|
*
|
|
@@ -106,9 +142,14 @@ export declare class UsersClient {
|
|
|
106
142
|
get(userId: string, request?: MavenAGI.UserGetRequest, requestOptions?: UsersClient.RequestOptions): core.HttpResponsePromise<MavenAGI.AppUserResponse>;
|
|
107
143
|
private __get;
|
|
108
144
|
/**
|
|
109
|
-
* Deletes all identifiers and user data saved by the specified app.
|
|
145
|
+
* Deletes all identifiers and user data saved by the specified app for this user.
|
|
110
146
|
* Does not modify data or identifiers saved by other apps.
|
|
111
147
|
*
|
|
148
|
+
* The app user still exists afterwards, with no identifiers or user data, and the app can keep writing to it.
|
|
149
|
+
* Conversations, their messages and events are not modified.
|
|
150
|
+
* The agent user's intelligent field values are not deleted; they are recomputed without this app's data.
|
|
151
|
+
* To wipe a conversation, use `DELETE /conversations/{conversationId}`. To wipe every app's data for a user, use `DELETE /agentusers/{agentUserId}`.
|
|
152
|
+
*
|
|
112
153
|
* If this user is linked to a user from another app, it will not be unlinked. Unlinking of users is not yet supported.
|
|
113
154
|
*
|
|
114
155
|
* <Warning>This is a destructive operation and cannot be undone.</Warning>
|
|
@@ -191,7 +191,7 @@ class UsersClient {
|
|
|
191
191
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
192
192
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
193
193
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
194
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/agentusers/${core.url.encodePathParam(agentUserId)}`),
|
|
194
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/agentusers/${core.url.encodePathParam(agentUserId, errors.MavenAGIError)}`),
|
|
195
195
|
method: "GET",
|
|
196
196
|
headers: _headers,
|
|
197
197
|
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
@@ -260,6 +260,113 @@ class UsersClient {
|
|
|
260
260
|
return (0, handleNonStatusCodeError_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/v1/agentusers/{agentUserId}");
|
|
261
261
|
});
|
|
262
262
|
}
|
|
263
|
+
/**
|
|
264
|
+
* @beta This endpoint is in development and may change.
|
|
265
|
+
*
|
|
266
|
+
* Deletes the identifiers and user data that every app has saved for an agent user.
|
|
267
|
+
* This is the same as calling `DELETE /users/{userId}` for each of the agent user's app users.
|
|
268
|
+
*
|
|
269
|
+
* The agent user and its app users still exist afterwards, with no identifiers or user data.
|
|
270
|
+
* Apps can keep writing to them; a later create or update adds data back to the same users.
|
|
271
|
+
*
|
|
272
|
+
* Conversations, their messages and events are not modified, apart from the intelligent field values below. To wipe a conversation, use `DELETE /conversations/{conversationId}`.
|
|
273
|
+
*
|
|
274
|
+
* If the ID belongs to an agent user that has been merged into another, the agent user it was merged into is wiped.
|
|
275
|
+
*
|
|
276
|
+
* <Warning>This is a destructive operation and cannot be undone.</Warning>
|
|
277
|
+
*
|
|
278
|
+
* ### Intelligent fields
|
|
279
|
+
*
|
|
280
|
+
* The agent user's intelligent field values are deleted too, and removed from their `INTELLIGENT_FIELD_VALUE_CHANGED` events; the events themselves are kept.
|
|
281
|
+
* Unlike `DELETE /users/{userId}`, the wipe does not recompute the values. They can be computed again later from the user's remaining conversations, for example after the user sends another message; wipe those conversations first to prevent that.
|
|
282
|
+
*
|
|
283
|
+
* @param {string} agentUserId - The ID of the agent user to wipe.
|
|
284
|
+
* @param {UsersClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
285
|
+
*
|
|
286
|
+
* @throws {@link MavenAGI.NotFoundError}
|
|
287
|
+
* @throws {@link MavenAGI.BadRequestError}
|
|
288
|
+
* @throws {@link MavenAGI.PayloadTooLargeError}
|
|
289
|
+
* @throws {@link MavenAGI.TooManyRequestsError}
|
|
290
|
+
* @throws {@link MavenAGI.ServerError}
|
|
291
|
+
* @throws {@link errors.MavenAGIError}
|
|
292
|
+
* @throws {@link errors.MavenAGITimeoutError}
|
|
293
|
+
*
|
|
294
|
+
* @example
|
|
295
|
+
* await client.users.deleteAgentUser("aus_1234567890")
|
|
296
|
+
*/
|
|
297
|
+
deleteAgentUser(agentUserId, requestOptions) {
|
|
298
|
+
return core.HttpResponsePromise.fromPromise(this.__deleteAgentUser(agentUserId, requestOptions));
|
|
299
|
+
}
|
|
300
|
+
__deleteAgentUser(agentUserId, requestOptions) {
|
|
301
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
302
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
303
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
304
|
+
const _headers = (0, headers_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_1.mergeOnlyDefinedHeaders)({
|
|
305
|
+
"X-Organization-Id": (_b = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.organizationId) !== null && _b !== void 0 ? _b : (_c = this._options) === null || _c === void 0 ? void 0 : _c.organizationId,
|
|
306
|
+
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
307
|
+
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
308
|
+
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
309
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/agentusers/${core.url.encodePathParam(agentUserId, errors.MavenAGIError)}`),
|
|
310
|
+
method: "DELETE",
|
|
311
|
+
headers: _headers,
|
|
312
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
313
|
+
timeoutMs: ((_l = (_j = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _j !== void 0 ? _j : (_k = this._options) === null || _k === void 0 ? void 0 : _k.timeoutInSeconds) !== null && _l !== void 0 ? _l : 60) * 1000,
|
|
314
|
+
maxRetries: (_m = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _m !== void 0 ? _m : (_o = this._options) === null || _o === void 0 ? void 0 : _o.maxRetries,
|
|
315
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
316
|
+
fetchFn: (_p = this._options) === null || _p === void 0 ? void 0 : _p.fetch,
|
|
317
|
+
logging: this._options.logging,
|
|
318
|
+
});
|
|
319
|
+
if (_response.ok) {
|
|
320
|
+
return { data: undefined, rawResponse: _response.rawResponse };
|
|
321
|
+
}
|
|
322
|
+
if (_response.error.reason === "status-code") {
|
|
323
|
+
switch (_response.error.statusCode) {
|
|
324
|
+
case 404:
|
|
325
|
+
throw new MavenAGI.NotFoundError(serializers.ErrorMessage.parseOrThrow(_response.error.body, {
|
|
326
|
+
unrecognizedObjectKeys: "passthrough",
|
|
327
|
+
allowUnrecognizedUnionMembers: true,
|
|
328
|
+
allowUnrecognizedEnumValues: true,
|
|
329
|
+
breadcrumbsPrefix: ["response"],
|
|
330
|
+
}), _response.rawResponse);
|
|
331
|
+
case 400:
|
|
332
|
+
throw new MavenAGI.BadRequestError(serializers.ErrorMessage.parseOrThrow(_response.error.body, {
|
|
333
|
+
unrecognizedObjectKeys: "passthrough",
|
|
334
|
+
allowUnrecognizedUnionMembers: true,
|
|
335
|
+
allowUnrecognizedEnumValues: true,
|
|
336
|
+
breadcrumbsPrefix: ["response"],
|
|
337
|
+
}), _response.rawResponse);
|
|
338
|
+
case 413:
|
|
339
|
+
throw new MavenAGI.PayloadTooLargeError(serializers.ErrorMessage.parseOrThrow(_response.error.body, {
|
|
340
|
+
unrecognizedObjectKeys: "passthrough",
|
|
341
|
+
allowUnrecognizedUnionMembers: true,
|
|
342
|
+
allowUnrecognizedEnumValues: true,
|
|
343
|
+
breadcrumbsPrefix: ["response"],
|
|
344
|
+
}), _response.rawResponse);
|
|
345
|
+
case 429:
|
|
346
|
+
throw new MavenAGI.TooManyRequestsError(serializers.ErrorMessage.parseOrThrow(_response.error.body, {
|
|
347
|
+
unrecognizedObjectKeys: "passthrough",
|
|
348
|
+
allowUnrecognizedUnionMembers: true,
|
|
349
|
+
allowUnrecognizedEnumValues: true,
|
|
350
|
+
breadcrumbsPrefix: ["response"],
|
|
351
|
+
}), _response.rawResponse);
|
|
352
|
+
case 500:
|
|
353
|
+
throw new MavenAGI.ServerError(serializers.ErrorMessage.parseOrThrow(_response.error.body, {
|
|
354
|
+
unrecognizedObjectKeys: "passthrough",
|
|
355
|
+
allowUnrecognizedUnionMembers: true,
|
|
356
|
+
allowUnrecognizedEnumValues: true,
|
|
357
|
+
breadcrumbsPrefix: ["response"],
|
|
358
|
+
}), _response.rawResponse);
|
|
359
|
+
default:
|
|
360
|
+
throw new errors.MavenAGIError({
|
|
361
|
+
statusCode: _response.error.statusCode,
|
|
362
|
+
body: _response.error.body,
|
|
363
|
+
rawResponse: _response.rawResponse,
|
|
364
|
+
});
|
|
365
|
+
}
|
|
366
|
+
}
|
|
367
|
+
return (0, handleNonStatusCodeError_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "DELETE", "/v1/agentusers/{agentUserId}");
|
|
368
|
+
});
|
|
369
|
+
}
|
|
263
370
|
/**
|
|
264
371
|
* Update an app user or create it if it doesn't exist.
|
|
265
372
|
*
|
|
@@ -409,7 +516,7 @@ class UsersClient {
|
|
|
409
516
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
410
517
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
411
518
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
412
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/users/${core.url.encodePathParam(userId)}`),
|
|
519
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/users/${core.url.encodePathParam(userId, errors.MavenAGIError)}`),
|
|
413
520
|
method: "GET",
|
|
414
521
|
headers: _headers,
|
|
415
522
|
queryString: core.url
|
|
@@ -483,9 +590,14 @@ class UsersClient {
|
|
|
483
590
|
});
|
|
484
591
|
}
|
|
485
592
|
/**
|
|
486
|
-
* Deletes all identifiers and user data saved by the specified app.
|
|
593
|
+
* Deletes all identifiers and user data saved by the specified app for this user.
|
|
487
594
|
* Does not modify data or identifiers saved by other apps.
|
|
488
595
|
*
|
|
596
|
+
* The app user still exists afterwards, with no identifiers or user data, and the app can keep writing to it.
|
|
597
|
+
* Conversations, their messages and events are not modified.
|
|
598
|
+
* The agent user's intelligent field values are not deleted; they are recomputed without this app's data.
|
|
599
|
+
* To wipe a conversation, use `DELETE /conversations/{conversationId}`. To wipe every app's data for a user, use `DELETE /agentusers/{agentUserId}`.
|
|
600
|
+
*
|
|
489
601
|
* If this user is linked to a user from another app, it will not be unlinked. Unlinking of users is not yet supported.
|
|
490
602
|
*
|
|
491
603
|
* <Warning>This is a destructive operation and cannot be undone.</Warning>
|
|
@@ -521,7 +633,7 @@ class UsersClient {
|
|
|
521
633
|
"X-Agent-Id": (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.agentId,
|
|
522
634
|
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
523
635
|
const _response = yield ((_f = this._options.fetcher) !== null && _f !== void 0 ? _f : core.fetcher)({
|
|
524
|
-
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/users/${core.url.encodePathParam(userId)}`),
|
|
636
|
+
url: core.url.join((_h = (_g = (yield core.Supplier.get(this._options.baseUrl))) !== null && _g !== void 0 ? _g : (yield core.Supplier.get(this._options.environment))) !== null && _h !== void 0 ? _h : environments.MavenAGIEnvironment.Production, `/v1/users/${core.url.encodePathParam(userId, errors.MavenAGIError)}`),
|
|
525
637
|
method: "DELETE",
|
|
526
638
|
headers: _headers,
|
|
527
639
|
queryString: core.url
|
|
@@ -10,6 +10,7 @@ import type * as MavenAGI from "../../../index";
|
|
|
10
10
|
* type: MavenAGI.AppUserIdentifyingPropertyType.Email
|
|
11
11
|
* }],
|
|
12
12
|
* defaultName: "Joe",
|
|
13
|
+
* executionMode: MavenAGI.ExecutionMode.Live,
|
|
13
14
|
* users: [{
|
|
14
15
|
* userId: {
|
|
15
16
|
* type: MavenAGI.EntityType.UserProfile,
|
|
@@ -61,4 +62,6 @@ export interface AgentUser {
|
|
|
61
62
|
users: MavenAGI.AppUserSummary[];
|
|
62
63
|
/** Latest successful values of the agent user's intelligent fields. */
|
|
63
64
|
intelligentFieldValues?: MavenAGI.IntelligentFieldValueResponse[];
|
|
65
|
+
/** The execution mode the agent user lives in. Its app users all share it. */
|
|
66
|
+
executionMode: MavenAGI.ExecutionMode;
|
|
64
67
|
}
|