mavenagi 1.0.15 → 1.1.0
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 +3 -4
- package/Client.js +51 -12
- package/README.md +14 -1
- package/api/resources/actions/client/Client.d.ts +9 -4
- package/api/resources/actions/client/Client.js +68 -39
- package/api/resources/agents/client/Client.d.ts +9 -4
- package/api/resources/agents/client/Client.js +76 -44
- package/api/resources/analytics/client/Client.d.ts +9 -4
- package/api/resources/analytics/client/Client.js +76 -40
- package/api/resources/analytics/types/ConversationTableResponse.d.ts +3 -3
- package/api/resources/appSettings/client/Client.d.ts +9 -4
- package/api/resources/appSettings/client/Client.js +76 -44
- package/api/resources/appSettings/client/index.d.ts +1 -0
- package/api/resources/commons/errors/BadRequestError.d.ts +2 -1
- package/api/resources/commons/errors/BadRequestError.js +2 -1
- package/api/resources/commons/errors/NotFoundError.d.ts +2 -1
- package/api/resources/commons/errors/NotFoundError.js +2 -1
- package/api/resources/commons/errors/ServerError.d.ts +2 -1
- package/api/resources/commons/errors/ServerError.js +2 -1
- package/api/resources/commons/types/AppUserRequest.d.ts +2 -2
- package/api/resources/commons/types/AppUserResponse.d.ts +2 -2
- package/api/resources/commons/types/ConversationResponse.d.ts +2 -1
- package/api/resources/commons/types/InboxItemFixType.d.ts +14 -0
- package/{dist/api/resources/realtime/types/AudioFormat.js → api/resources/commons/types/InboxItemFixType.js} +4 -4
- package/api/resources/commons/types/UserMessageAttachment.d.ts +16 -0
- package/api/resources/commons/types/index.d.ts +1 -0
- package/api/resources/commons/types/index.js +1 -0
- package/api/resources/conversation/client/Client.d.ts +43 -58
- package/api/resources/conversation/client/Client.js +342 -281
- package/api/resources/conversation/client/index.d.ts +1 -0
- package/api/resources/conversation/types/Attachment.d.ts +18 -1
- package/api/resources/conversation/types/ConversationMessageRequest.d.ts +2 -0
- package/api/resources/conversation/types/index.d.ts +0 -1
- package/api/resources/conversation/types/index.js +0 -1
- package/api/resources/events/client/Client.d.ts +5 -2
- package/api/resources/events/client/Client.js +26 -16
- package/api/resources/inbox/client/Client.d.ts +21 -10
- package/api/resources/inbox/client/Client.js +126 -67
- package/api/resources/inbox/client/index.d.ts +1 -0
- package/api/resources/inbox/client/requests/InboxItemFixRequest.d.ts +7 -1
- package/api/resources/inbox/client/requests/InboxItemIgnoreRequest.d.ts +7 -1
- package/api/resources/inbox/client/requests/InboxItemRequest.d.ts +7 -1
- package/api/resources/inbox/types/ApplyInboxItemFixRequest.d.ts +2 -0
- package/api/resources/inbox/types/InboxSearchRequest.d.ts +4 -0
- package/api/resources/index.d.ts +0 -2
- package/api/resources/index.js +1 -3
- package/api/resources/knowledge/client/Client.d.ts +17 -8
- package/api/resources/knowledge/client/Client.js +168 -87
- package/api/resources/organizations/client/Client.d.ts +7 -3
- package/api/resources/organizations/client/Client.js +51 -28
- package/api/resources/translations/client/Client.d.ts +5 -2
- package/api/resources/translations/client/Client.js +26 -16
- package/api/resources/triggers/client/Client.d.ts +13 -6
- package/api/resources/triggers/client/Client.js +118 -63
- package/api/resources/triggers/client/index.d.ts +1 -0
- package/api/resources/users/client/Client.d.ts +11 -6
- package/api/resources/users/client/Client.js +72 -43
- package/api/resources/users/client/index.d.ts +1 -0
- package/core/auth/BasicAuth.js +3 -3
- package/core/base64.d.ts +2 -0
- package/core/base64.js +26 -0
- package/core/fetcher/APIResponse.d.ts +10 -0
- package/core/fetcher/BinaryResponse.d.ts +20 -0
- package/core/fetcher/BinaryResponse.js +17 -0
- package/core/fetcher/Fetcher.d.ts +3 -2
- package/core/fetcher/Fetcher.js +32 -12
- package/core/fetcher/Headers.d.ts +2 -0
- package/core/fetcher/Headers.js +84 -0
- package/core/fetcher/HttpResponsePromise.d.ts +58 -0
- package/core/fetcher/HttpResponsePromise.js +103 -0
- package/core/fetcher/RawResponse.d.ts +29 -0
- package/core/fetcher/RawResponse.js +44 -0
- package/core/fetcher/ResponseWithBody.d.ts +4 -0
- package/core/fetcher/ResponseWithBody.js +6 -0
- package/core/fetcher/createRequestUrl.d.ts +1 -1
- package/core/fetcher/createRequestUrl.js +3 -7
- package/core/fetcher/getErrorResponseBody.d.ts +1 -0
- package/core/fetcher/getErrorResponseBody.js +44 -0
- package/core/fetcher/getFetchFn.d.ts +1 -4
- package/core/fetcher/getFetchFn.js +1 -52
- package/core/fetcher/getResponseBody.js +34 -33
- package/core/fetcher/index.d.ts +4 -0
- package/core/fetcher/index.js +7 -1
- package/core/headers.d.ts +3 -0
- package/core/headers.js +29 -0
- package/core/index.d.ts +3 -2
- package/core/index.js +4 -3
- package/core/runtime/runtime.js +0 -1
- package/core/{streaming-fetcher → stream}/Stream.d.ts +1 -2
- package/core/url/index.d.ts +2 -0
- package/core/url/index.js +7 -0
- package/core/url/join.d.ts +1 -0
- package/core/url/join.js +49 -0
- package/core/url/qs.d.ts +6 -0
- package/core/url/qs.js +64 -0
- package/dist/Client.d.ts +3 -4
- package/dist/Client.js +51 -12
- package/dist/api/resources/actions/client/Client.d.ts +9 -4
- package/dist/api/resources/actions/client/Client.js +68 -39
- package/dist/api/resources/agents/client/Client.d.ts +9 -4
- package/dist/api/resources/agents/client/Client.js +76 -44
- package/dist/api/resources/analytics/client/Client.d.ts +9 -4
- package/dist/api/resources/analytics/client/Client.js +76 -40
- package/dist/api/resources/analytics/types/ConversationTableResponse.d.ts +3 -3
- package/dist/api/resources/appSettings/client/Client.d.ts +9 -4
- package/dist/api/resources/appSettings/client/Client.js +76 -44
- package/dist/api/resources/appSettings/client/index.d.ts +1 -0
- package/dist/api/resources/commons/errors/BadRequestError.d.ts +2 -1
- package/dist/api/resources/commons/errors/BadRequestError.js +2 -1
- package/dist/api/resources/commons/errors/NotFoundError.d.ts +2 -1
- package/dist/api/resources/commons/errors/NotFoundError.js +2 -1
- package/dist/api/resources/commons/errors/ServerError.d.ts +2 -1
- package/dist/api/resources/commons/errors/ServerError.js +2 -1
- package/dist/api/resources/commons/types/AppUserRequest.d.ts +2 -2
- package/dist/api/resources/commons/types/AppUserResponse.d.ts +2 -2
- package/dist/api/resources/commons/types/ConversationResponse.d.ts +2 -1
- package/dist/api/resources/commons/types/InboxItemFixType.d.ts +14 -0
- package/{api/resources/realtime/types/AudioFormat.js → dist/api/resources/commons/types/InboxItemFixType.js} +4 -4
- package/dist/api/resources/commons/types/UserMessageAttachment.d.ts +16 -0
- package/dist/api/resources/commons/types/index.d.ts +1 -0
- package/dist/api/resources/commons/types/index.js +1 -0
- package/dist/api/resources/conversation/client/Client.d.ts +43 -58
- package/dist/api/resources/conversation/client/Client.js +342 -281
- package/dist/api/resources/conversation/client/index.d.ts +1 -0
- package/dist/api/resources/conversation/types/Attachment.d.ts +18 -1
- package/dist/api/resources/conversation/types/ConversationMessageRequest.d.ts +2 -0
- package/dist/api/resources/conversation/types/index.d.ts +0 -1
- package/dist/api/resources/conversation/types/index.js +0 -1
- package/dist/api/resources/events/client/Client.d.ts +5 -2
- package/dist/api/resources/events/client/Client.js +26 -16
- package/dist/api/resources/inbox/client/Client.d.ts +21 -10
- package/dist/api/resources/inbox/client/Client.js +126 -67
- package/dist/api/resources/inbox/client/index.d.ts +1 -0
- package/dist/api/resources/inbox/client/requests/InboxItemFixRequest.d.ts +7 -1
- package/dist/api/resources/inbox/client/requests/InboxItemIgnoreRequest.d.ts +7 -1
- package/dist/api/resources/inbox/client/requests/InboxItemRequest.d.ts +7 -1
- package/dist/api/resources/inbox/types/ApplyInboxItemFixRequest.d.ts +2 -0
- package/dist/api/resources/inbox/types/InboxSearchRequest.d.ts +4 -0
- package/dist/api/resources/index.d.ts +0 -2
- package/dist/api/resources/index.js +1 -3
- package/dist/api/resources/knowledge/client/Client.d.ts +17 -8
- package/dist/api/resources/knowledge/client/Client.js +168 -87
- package/dist/api/resources/organizations/client/Client.d.ts +7 -3
- package/dist/api/resources/organizations/client/Client.js +51 -28
- package/dist/api/resources/translations/client/Client.d.ts +5 -2
- package/dist/api/resources/translations/client/Client.js +26 -16
- package/dist/api/resources/triggers/client/Client.d.ts +13 -6
- package/dist/api/resources/triggers/client/Client.js +118 -63
- package/dist/api/resources/triggers/client/index.d.ts +1 -0
- package/dist/api/resources/users/client/Client.d.ts +11 -6
- package/dist/api/resources/users/client/Client.js +72 -43
- package/dist/api/resources/users/client/index.d.ts +1 -0
- package/dist/core/auth/BasicAuth.js +3 -3
- package/dist/core/base64.d.ts +2 -0
- package/dist/core/base64.js +26 -0
- package/dist/core/fetcher/APIResponse.d.ts +10 -0
- package/dist/core/fetcher/BinaryResponse.d.ts +20 -0
- package/dist/core/fetcher/BinaryResponse.js +17 -0
- package/dist/core/fetcher/Fetcher.d.ts +3 -2
- package/dist/core/fetcher/Fetcher.js +32 -12
- package/dist/core/fetcher/Headers.d.ts +2 -0
- package/dist/core/fetcher/Headers.js +84 -0
- package/dist/core/fetcher/HttpResponsePromise.d.ts +58 -0
- package/dist/core/fetcher/HttpResponsePromise.js +103 -0
- package/dist/core/fetcher/RawResponse.d.ts +29 -0
- package/dist/core/fetcher/RawResponse.js +44 -0
- package/dist/core/fetcher/ResponseWithBody.d.ts +4 -0
- package/dist/core/fetcher/ResponseWithBody.js +6 -0
- package/dist/core/fetcher/createRequestUrl.d.ts +1 -1
- package/dist/core/fetcher/createRequestUrl.js +3 -7
- package/dist/core/fetcher/getErrorResponseBody.d.ts +1 -0
- package/dist/core/fetcher/getErrorResponseBody.js +44 -0
- package/dist/core/fetcher/getFetchFn.d.ts +1 -4
- package/dist/core/fetcher/getFetchFn.js +1 -52
- package/dist/core/fetcher/getResponseBody.js +34 -33
- package/dist/core/fetcher/index.d.ts +4 -0
- package/dist/core/fetcher/index.js +7 -1
- package/dist/core/headers.d.ts +3 -0
- package/dist/core/headers.js +29 -0
- package/dist/core/index.d.ts +3 -2
- package/dist/core/index.js +4 -3
- package/dist/core/runtime/runtime.js +0 -1
- package/dist/core/{streaming-fetcher → stream}/Stream.d.ts +1 -2
- package/dist/core/url/index.d.ts +2 -0
- package/dist/core/url/index.js +7 -0
- package/dist/core/url/join.d.ts +1 -0
- package/dist/core/url/join.js +49 -0
- package/dist/core/url/qs.d.ts +6 -0
- package/dist/core/url/qs.js +64 -0
- package/dist/errors/MavenAGIError.d.ts +4 -1
- package/dist/errors/MavenAGIError.js +4 -7
- package/dist/index.d.ts +2 -2
- package/dist/index.js +5 -5
- package/dist/serialization/resources/commons/types/InboxItemFixType.d.ts +10 -0
- package/{serialization/resources/realtime/types/AudioFormat.js → dist/serialization/resources/commons/types/InboxItemFixType.js} +2 -2
- package/dist/serialization/resources/commons/types/UserMessageAttachment.d.ts +2 -0
- package/dist/serialization/resources/commons/types/UserMessageAttachment.js +2 -0
- package/dist/serialization/resources/commons/types/index.d.ts +1 -0
- package/dist/serialization/resources/commons/types/index.js +1 -0
- package/dist/serialization/resources/conversation/types/Attachment.d.ts +1 -0
- package/dist/serialization/resources/conversation/types/Attachment.js +1 -0
- package/dist/serialization/resources/conversation/types/ConversationMessageRequest.d.ts +2 -0
- package/dist/serialization/resources/conversation/types/ConversationMessageRequest.js +2 -0
- package/dist/serialization/resources/conversation/types/index.d.ts +0 -1
- package/dist/serialization/resources/conversation/types/index.js +0 -1
- package/dist/serialization/resources/inbox/types/ApplyInboxItemFixRequest.d.ts +2 -0
- package/dist/serialization/resources/inbox/types/ApplyInboxItemFixRequest.js +2 -0
- package/dist/serialization/resources/inbox/types/InboxSearchRequest.d.ts +2 -0
- package/dist/serialization/resources/inbox/types/InboxSearchRequest.js +2 -0
- package/dist/serialization/resources/index.d.ts +0 -2
- package/dist/serialization/resources/index.js +1 -3
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/errors/MavenAGIError.d.ts +4 -1
- package/errors/MavenAGIError.js +4 -7
- package/index.d.ts +2 -2
- package/index.js +5 -5
- package/jest.config.mjs +6 -1
- package/package.json +13 -21
- package/reference.md +16 -98
- package/scripts/rename-to-esm-files.js +10 -2
- package/serialization/resources/commons/types/InboxItemFixType.d.ts +10 -0
- package/{dist/serialization/resources/realtime/types/AudioFormat.js → serialization/resources/commons/types/InboxItemFixType.js} +2 -2
- package/serialization/resources/commons/types/UserMessageAttachment.d.ts +2 -0
- package/serialization/resources/commons/types/UserMessageAttachment.js +2 -0
- package/serialization/resources/commons/types/index.d.ts +1 -0
- package/serialization/resources/commons/types/index.js +1 -0
- package/serialization/resources/conversation/types/Attachment.d.ts +1 -0
- package/serialization/resources/conversation/types/Attachment.js +1 -0
- package/serialization/resources/conversation/types/ConversationMessageRequest.d.ts +2 -0
- package/serialization/resources/conversation/types/ConversationMessageRequest.js +2 -0
- package/serialization/resources/conversation/types/index.d.ts +0 -1
- package/serialization/resources/conversation/types/index.js +0 -1
- package/serialization/resources/inbox/types/ApplyInboxItemFixRequest.d.ts +2 -0
- package/serialization/resources/inbox/types/ApplyInboxItemFixRequest.js +2 -0
- package/serialization/resources/inbox/types/InboxSearchRequest.d.ts +2 -0
- package/serialization/resources/inbox/types/InboxSearchRequest.js +2 -0
- package/serialization/resources/index.d.ts +0 -2
- package/serialization/resources/index.js +1 -3
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/api/resources/conversation/types/GenerateObjectRequest.d.ts +0 -8
- package/api/resources/conversation/types/GenerateObjectRequest.js +0 -5
- package/api/resources/realtime/client/Client.d.ts +0 -36
- package/api/resources/realtime/client/Client.js +0 -90
- package/api/resources/realtime/client/Socket.d.ts +0 -41
- package/api/resources/realtime/client/Socket.js +0 -155
- package/api/resources/realtime/client/index.d.ts +0 -1
- package/api/resources/realtime/client/index.js +0 -2
- package/api/resources/realtime/index.d.ts +0 -2
- package/api/resources/realtime/index.js +0 -18
- package/api/resources/realtime/types/AudioFormat.d.ts +0 -8
- package/api/resources/realtime/types/AudioPublishEvent.d.ts +0 -6
- package/api/resources/realtime/types/AudioPublishEvent.js +0 -5
- package/api/resources/realtime/types/AudioSubscribeEvent.d.ts +0 -6
- package/api/resources/realtime/types/AudioSubscribeEvent.js +0 -5
- package/api/resources/realtime/types/ControlEvent.d.ts +0 -9
- package/api/resources/realtime/types/ControlEvent.js +0 -5
- package/api/resources/realtime/types/HangUpPublishEvent.d.ts +0 -6
- package/api/resources/realtime/types/HangUpPublishEvent.js +0 -5
- package/api/resources/realtime/types/MessageBase.d.ts +0 -6
- package/api/resources/realtime/types/MessageBase.js +0 -5
- package/api/resources/realtime/types/PublishEvent.d.ts +0 -16
- package/api/resources/realtime/types/PublishEvent.js +0 -5
- package/api/resources/realtime/types/SubscribeEvent.d.ts +0 -25
- package/api/resources/realtime/types/SubscribeEvent.js +0 -5
- package/api/resources/realtime/types/index.d.ts +0 -8
- package/api/resources/realtime/types/index.js +0 -24
- package/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.d.ts +0 -30
- package/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.js +0 -247
- package/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts +0 -21
- package/core/fetcher/stream-wrappers/NodePre18StreamWrapper.js +0 -126
- package/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts +0 -31
- package/core/fetcher/stream-wrappers/UndiciStreamWrapper.js +0 -229
- package/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts +0 -18
- package/core/fetcher/stream-wrappers/chooseStreamWrapper.js +0 -59
- package/core/websocket/events.d.ts +0 -36
- package/core/websocket/events.js +0 -27
- package/core/websocket/index.d.ts +0 -1
- package/core/websocket/index.js +0 -17
- package/core/websocket/ws.d.ts +0 -137
- package/core/websocket/ws.js +0 -452
- package/dist/api/resources/conversation/types/GenerateObjectRequest.d.ts +0 -8
- package/dist/api/resources/conversation/types/GenerateObjectRequest.js +0 -5
- package/dist/api/resources/realtime/client/Client.d.ts +0 -36
- package/dist/api/resources/realtime/client/Client.js +0 -90
- package/dist/api/resources/realtime/client/Socket.d.ts +0 -41
- package/dist/api/resources/realtime/client/Socket.js +0 -155
- package/dist/api/resources/realtime/client/index.d.ts +0 -1
- package/dist/api/resources/realtime/client/index.js +0 -2
- package/dist/api/resources/realtime/index.d.ts +0 -2
- package/dist/api/resources/realtime/index.js +0 -18
- package/dist/api/resources/realtime/types/AudioFormat.d.ts +0 -8
- package/dist/api/resources/realtime/types/AudioPublishEvent.d.ts +0 -6
- package/dist/api/resources/realtime/types/AudioPublishEvent.js +0 -5
- package/dist/api/resources/realtime/types/AudioSubscribeEvent.d.ts +0 -6
- package/dist/api/resources/realtime/types/AudioSubscribeEvent.js +0 -5
- package/dist/api/resources/realtime/types/ControlEvent.d.ts +0 -9
- package/dist/api/resources/realtime/types/ControlEvent.js +0 -5
- package/dist/api/resources/realtime/types/HangUpPublishEvent.d.ts +0 -6
- package/dist/api/resources/realtime/types/HangUpPublishEvent.js +0 -5
- package/dist/api/resources/realtime/types/MessageBase.d.ts +0 -6
- package/dist/api/resources/realtime/types/MessageBase.js +0 -5
- package/dist/api/resources/realtime/types/PublishEvent.d.ts +0 -16
- package/dist/api/resources/realtime/types/PublishEvent.js +0 -5
- package/dist/api/resources/realtime/types/SubscribeEvent.d.ts +0 -25
- package/dist/api/resources/realtime/types/SubscribeEvent.js +0 -5
- package/dist/api/resources/realtime/types/index.d.ts +0 -8
- package/dist/api/resources/realtime/types/index.js +0 -24
- package/dist/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.d.ts +0 -30
- package/dist/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.js +0 -247
- package/dist/core/fetcher/stream-wrappers/NodePre18StreamWrapper.d.ts +0 -21
- package/dist/core/fetcher/stream-wrappers/NodePre18StreamWrapper.js +0 -126
- package/dist/core/fetcher/stream-wrappers/UndiciStreamWrapper.d.ts +0 -31
- package/dist/core/fetcher/stream-wrappers/UndiciStreamWrapper.js +0 -229
- package/dist/core/fetcher/stream-wrappers/chooseStreamWrapper.d.ts +0 -18
- package/dist/core/fetcher/stream-wrappers/chooseStreamWrapper.js +0 -59
- package/dist/core/websocket/events.d.ts +0 -36
- package/dist/core/websocket/events.js +0 -27
- package/dist/core/websocket/index.d.ts +0 -1
- package/dist/core/websocket/index.js +0 -17
- package/dist/core/websocket/ws.d.ts +0 -137
- package/dist/core/websocket/ws.js +0 -452
- package/dist/serialization/resources/conversation/types/GenerateObjectRequest.d.ts +0 -13
- package/dist/serialization/resources/conversation/types/GenerateObjectRequest.js +0 -46
- package/dist/serialization/resources/realtime/index.d.ts +0 -1
- package/dist/serialization/resources/realtime/index.js +0 -17
- package/dist/serialization/resources/realtime/types/AudioFormat.d.ts +0 -10
- package/dist/serialization/resources/realtime/types/AudioPublishEvent.d.ts +0 -12
- package/dist/serialization/resources/realtime/types/AudioPublishEvent.js +0 -43
- package/dist/serialization/resources/realtime/types/AudioSubscribeEvent.d.ts +0 -12
- package/dist/serialization/resources/realtime/types/AudioSubscribeEvent.js +0 -43
- package/dist/serialization/resources/realtime/types/ControlEvent.d.ts +0 -15
- package/dist/serialization/resources/realtime/types/ControlEvent.js +0 -48
- package/dist/serialization/resources/realtime/types/HangUpPublishEvent.d.ts +0 -12
- package/dist/serialization/resources/realtime/types/HangUpPublishEvent.js +0 -43
- package/dist/serialization/resources/realtime/types/MessageBase.d.ts +0 -12
- package/dist/serialization/resources/realtime/types/MessageBase.js +0 -43
- package/dist/serialization/resources/realtime/types/PublishEvent.d.ts +0 -18
- package/dist/serialization/resources/realtime/types/PublishEvent.js +0 -51
- package/dist/serialization/resources/realtime/types/SubscribeEvent.d.ts +0 -27
- package/dist/serialization/resources/realtime/types/SubscribeEvent.js +0 -54
- package/dist/serialization/resources/realtime/types/index.d.ts +0 -8
- package/dist/serialization/resources/realtime/types/index.js +0 -24
- package/serialization/resources/conversation/types/GenerateObjectRequest.d.ts +0 -13
- package/serialization/resources/conversation/types/GenerateObjectRequest.js +0 -46
- package/serialization/resources/realtime/index.d.ts +0 -1
- package/serialization/resources/realtime/index.js +0 -17
- package/serialization/resources/realtime/types/AudioFormat.d.ts +0 -10
- package/serialization/resources/realtime/types/AudioPublishEvent.d.ts +0 -12
- package/serialization/resources/realtime/types/AudioPublishEvent.js +0 -43
- package/serialization/resources/realtime/types/AudioSubscribeEvent.d.ts +0 -12
- package/serialization/resources/realtime/types/AudioSubscribeEvent.js +0 -43
- package/serialization/resources/realtime/types/ControlEvent.d.ts +0 -15
- package/serialization/resources/realtime/types/ControlEvent.js +0 -48
- package/serialization/resources/realtime/types/HangUpPublishEvent.d.ts +0 -12
- package/serialization/resources/realtime/types/HangUpPublishEvent.js +0 -43
- package/serialization/resources/realtime/types/MessageBase.d.ts +0 -12
- package/serialization/resources/realtime/types/MessageBase.js +0 -43
- package/serialization/resources/realtime/types/PublishEvent.d.ts +0 -18
- package/serialization/resources/realtime/types/PublishEvent.js +0 -51
- package/serialization/resources/realtime/types/SubscribeEvent.d.ts +0 -27
- package/serialization/resources/realtime/types/SubscribeEvent.js +0 -54
- package/serialization/resources/realtime/types/index.d.ts +0 -8
- package/serialization/resources/realtime/types/index.js +0 -24
- /package/core/{streaming-fetcher → stream}/Stream.js +0 -0
- /package/core/{streaming-fetcher → stream}/index.d.ts +0 -0
- /package/core/{streaming-fetcher → stream}/index.js +0 -0
- /package/dist/core/{streaming-fetcher → stream}/Stream.js +0 -0
- /package/dist/core/{streaming-fetcher → stream}/index.d.ts +0 -0
- /package/dist/core/{streaming-fetcher → stream}/index.js +0 -0
|
@@ -2,8 +2,25 @@
|
|
|
2
2
|
* This file was auto-generated by Fern from our API Definition.
|
|
3
3
|
*/
|
|
4
4
|
export interface Attachment {
|
|
5
|
-
/**
|
|
5
|
+
/**
|
|
6
|
+
* The mime-type of the attachment. Supported types are:
|
|
7
|
+
* - image/jpeg
|
|
8
|
+
* - image/jpg
|
|
9
|
+
* - image/png
|
|
10
|
+
* - image/gif
|
|
11
|
+
* - image/webp
|
|
12
|
+
* - application/pdf
|
|
13
|
+
* - audio/aac
|
|
14
|
+
* - audio/mpeg
|
|
15
|
+
* - audio/mp4
|
|
16
|
+
* - video/mp4
|
|
17
|
+
*
|
|
18
|
+
* Image attachments will be sent to the LLM as additional data.
|
|
19
|
+
* Non-image attachments can be stored and downloaded from the API but will not be sent to the LLM.
|
|
20
|
+
*/
|
|
6
21
|
type: string;
|
|
7
22
|
/** The attachment data, up to 5MB. */
|
|
8
23
|
content: string;
|
|
24
|
+
/** The name of the attachment, if one was provided. */
|
|
25
|
+
name?: string;
|
|
9
26
|
}
|
|
@@ -5,4 +5,6 @@ import * as MavenAGI from "../../../index";
|
|
|
5
5
|
export interface ConversationMessageRequest extends MavenAGI.UserMessageBase {
|
|
6
6
|
/** The ID that uniquely identifies this message within the conversation */
|
|
7
7
|
conversationMessageId: MavenAGI.EntityIdBase;
|
|
8
|
+
/** The attachments to the message. */
|
|
9
|
+
attachments?: MavenAGI.Attachment[];
|
|
8
10
|
}
|
|
@@ -5,7 +5,6 @@ export * from "./ConversationRequest";
|
|
|
5
5
|
export * from "./ConversationMessageRequest";
|
|
6
6
|
export * from "./SubmitActionFormRequest";
|
|
7
7
|
export * from "./FeedbackRequest";
|
|
8
|
-
export * from "./GenerateObjectRequest";
|
|
9
8
|
export * from "./StreamResponse";
|
|
10
9
|
export * from "./AskStreamTextEvent";
|
|
11
10
|
export * from "./AskStreamActionEvent";
|
|
@@ -21,7 +21,6 @@ __exportStar(require("./ConversationRequest"), exports);
|
|
|
21
21
|
__exportStar(require("./ConversationMessageRequest"), exports);
|
|
22
22
|
__exportStar(require("./SubmitActionFormRequest"), exports);
|
|
23
23
|
__exportStar(require("./FeedbackRequest"), exports);
|
|
24
|
-
__exportStar(require("./GenerateObjectRequest"), exports);
|
|
25
24
|
__exportStar(require("./StreamResponse"), exports);
|
|
26
25
|
__exportStar(require("./AskStreamTextEvent"), exports);
|
|
27
26
|
__exportStar(require("./AskStreamActionEvent"), exports);
|
|
@@ -15,6 +15,8 @@ export declare namespace Events {
|
|
|
15
15
|
organizationId: core.Supplier<string>;
|
|
16
16
|
/** Override the X-Agent-Id header */
|
|
17
17
|
agentId: core.Supplier<string>;
|
|
18
|
+
/** Additional headers to include in requests. */
|
|
19
|
+
headers?: Record<string, string | core.Supplier<string | undefined> | undefined>;
|
|
18
20
|
fetcher?: core.FetchFunction;
|
|
19
21
|
}
|
|
20
22
|
interface RequestOptions {
|
|
@@ -29,7 +31,7 @@ export declare namespace Events {
|
|
|
29
31
|
/** Override the X-Agent-Id header */
|
|
30
32
|
agentId?: string;
|
|
31
33
|
/** Additional headers to include in the request. */
|
|
32
|
-
headers?: Record<string, string>;
|
|
34
|
+
headers?: Record<string, string | core.Supplier<string | undefined> | undefined>;
|
|
33
35
|
}
|
|
34
36
|
}
|
|
35
37
|
export declare class Events {
|
|
@@ -48,6 +50,7 @@ export declare class Events {
|
|
|
48
50
|
* @example
|
|
49
51
|
* await client.events.search({})
|
|
50
52
|
*/
|
|
51
|
-
search(request: MavenAGI.EventsSearchRequest, requestOptions?: Events.RequestOptions):
|
|
53
|
+
search(request: MavenAGI.EventsSearchRequest, requestOptions?: Events.RequestOptions): core.HttpResponsePromise<MavenAGI.EventsSearchResponse>;
|
|
54
|
+
private __search;
|
|
52
55
|
protected _getAuthorizationHeader(): Promise<string | undefined>;
|
|
53
56
|
}
|
|
@@ -44,16 +44,13 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
44
44
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
45
45
|
});
|
|
46
46
|
};
|
|
47
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
48
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
49
|
-
};
|
|
50
47
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
51
48
|
exports.Events = void 0;
|
|
52
49
|
const environments = __importStar(require("../../../../environments"));
|
|
53
50
|
const core = __importStar(require("../../../../core"));
|
|
54
51
|
const MavenAGI = __importStar(require("../../../index"));
|
|
52
|
+
const headers_1 = require("../../../../core/headers");
|
|
55
53
|
const serializers = __importStar(require("../../../../serialization/index"));
|
|
56
|
-
const url_join_1 = __importDefault(require("url-join"));
|
|
57
54
|
const errors = __importStar(require("../../../../errors/index"));
|
|
58
55
|
class Events {
|
|
59
56
|
constructor(_options) {
|
|
@@ -73,12 +70,19 @@ class Events {
|
|
|
73
70
|
* await client.events.search({})
|
|
74
71
|
*/
|
|
75
72
|
search(request, requestOptions) {
|
|
73
|
+
return core.HttpResponsePromise.fromPromise(this.__search(request, requestOptions));
|
|
74
|
+
}
|
|
75
|
+
__search(request, requestOptions) {
|
|
76
76
|
return __awaiter(this, void 0, void 0, function* () {
|
|
77
|
-
var _a, _b, _c;
|
|
77
|
+
var _a, _b, _c, _d;
|
|
78
78
|
const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
|
|
79
|
-
url:
|
|
79
|
+
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.MavenAGIEnvironment.Production, "/v1/events/search"),
|
|
80
80
|
method: "POST",
|
|
81
|
-
headers:
|
|
81
|
+
headers: (0, headers_1.mergeHeaders)((_d = this._options) === null || _d === void 0 ? void 0 : _d.headers, (0, headers_1.mergeOnlyDefinedHeaders)({
|
|
82
|
+
Authorization: yield this._getAuthorizationHeader(),
|
|
83
|
+
"X-Organization-Id": requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.organizationId,
|
|
84
|
+
"X-Agent-Id": requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.agentId,
|
|
85
|
+
}), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers),
|
|
82
86
|
contentType: "application/json",
|
|
83
87
|
requestType: "json",
|
|
84
88
|
body: serializers.EventsSearchRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -87,12 +91,15 @@ class Events {
|
|
|
87
91
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
88
92
|
});
|
|
89
93
|
if (_response.ok) {
|
|
90
|
-
return
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
94
|
+
return {
|
|
95
|
+
data: serializers.EventsSearchResponse.parseOrThrow(_response.body, {
|
|
96
|
+
unrecognizedObjectKeys: "passthrough",
|
|
97
|
+
allowUnrecognizedUnionMembers: true,
|
|
98
|
+
allowUnrecognizedEnumValues: true,
|
|
99
|
+
breadcrumbsPrefix: ["response"],
|
|
100
|
+
}),
|
|
101
|
+
rawResponse: _response.rawResponse,
|
|
102
|
+
};
|
|
96
103
|
}
|
|
97
104
|
if (_response.error.reason === "status-code") {
|
|
98
105
|
switch (_response.error.statusCode) {
|
|
@@ -102,25 +109,26 @@ class Events {
|
|
|
102
109
|
allowUnrecognizedUnionMembers: true,
|
|
103
110
|
allowUnrecognizedEnumValues: true,
|
|
104
111
|
breadcrumbsPrefix: ["response"],
|
|
105
|
-
}));
|
|
112
|
+
}), _response.rawResponse);
|
|
106
113
|
case 400:
|
|
107
114
|
throw new MavenAGI.BadRequestError(serializers.ErrorMessage.parseOrThrow(_response.error.body, {
|
|
108
115
|
unrecognizedObjectKeys: "passthrough",
|
|
109
116
|
allowUnrecognizedUnionMembers: true,
|
|
110
117
|
allowUnrecognizedEnumValues: true,
|
|
111
118
|
breadcrumbsPrefix: ["response"],
|
|
112
|
-
}));
|
|
119
|
+
}), _response.rawResponse);
|
|
113
120
|
case 500:
|
|
114
121
|
throw new MavenAGI.ServerError(serializers.ErrorMessage.parseOrThrow(_response.error.body, {
|
|
115
122
|
unrecognizedObjectKeys: "passthrough",
|
|
116
123
|
allowUnrecognizedUnionMembers: true,
|
|
117
124
|
allowUnrecognizedEnumValues: true,
|
|
118
125
|
breadcrumbsPrefix: ["response"],
|
|
119
|
-
}));
|
|
126
|
+
}), _response.rawResponse);
|
|
120
127
|
default:
|
|
121
128
|
throw new errors.MavenAGIError({
|
|
122
129
|
statusCode: _response.error.statusCode,
|
|
123
130
|
body: _response.error.body,
|
|
131
|
+
rawResponse: _response.rawResponse,
|
|
124
132
|
});
|
|
125
133
|
}
|
|
126
134
|
}
|
|
@@ -129,12 +137,14 @@ class Events {
|
|
|
129
137
|
throw new errors.MavenAGIError({
|
|
130
138
|
statusCode: _response.error.statusCode,
|
|
131
139
|
body: _response.error.rawBody,
|
|
140
|
+
rawResponse: _response.rawResponse,
|
|
132
141
|
});
|
|
133
142
|
case "timeout":
|
|
134
143
|
throw new errors.MavenAGITimeoutError("Timeout exceeded when calling POST /v1/events/search.");
|
|
135
144
|
case "unknown":
|
|
136
145
|
throw new errors.MavenAGIError({
|
|
137
146
|
message: _response.error.errorMessage,
|
|
147
|
+
rawResponse: _response.rawResponse,
|
|
138
148
|
});
|
|
139
149
|
}
|
|
140
150
|
});
|
|
@@ -15,6 +15,8 @@ export declare namespace Inbox {
|
|
|
15
15
|
organizationId: core.Supplier<string>;
|
|
16
16
|
/** Override the X-Agent-Id header */
|
|
17
17
|
agentId: core.Supplier<string>;
|
|
18
|
+
/** Additional headers to include in requests. */
|
|
19
|
+
headers?: Record<string, string | core.Supplier<string | undefined> | undefined>;
|
|
18
20
|
fetcher?: core.FetchFunction;
|
|
19
21
|
}
|
|
20
22
|
interface RequestOptions {
|
|
@@ -29,7 +31,7 @@ export declare namespace Inbox {
|
|
|
29
31
|
/** Override the X-Agent-Id header */
|
|
30
32
|
agentId?: string;
|
|
31
33
|
/** Additional headers to include in the request. */
|
|
32
|
-
headers?: Record<string, string>;
|
|
34
|
+
headers?: Record<string, string | core.Supplier<string | undefined> | undefined>;
|
|
33
35
|
}
|
|
34
36
|
}
|
|
35
37
|
export declare class Inbox {
|
|
@@ -48,7 +50,8 @@ export declare class Inbox {
|
|
|
48
50
|
* @example
|
|
49
51
|
* await client.inbox.search({})
|
|
50
52
|
*/
|
|
51
|
-
search(request: MavenAGI.InboxSearchRequest, requestOptions?: Inbox.RequestOptions):
|
|
53
|
+
search(request: MavenAGI.InboxSearchRequest, requestOptions?: Inbox.RequestOptions): core.HttpResponsePromise<MavenAGI.InboxSearchResponse>;
|
|
54
|
+
private __search;
|
|
52
55
|
/**
|
|
53
56
|
* Retrieve details of a specific inbox item by its ID.
|
|
54
57
|
*
|
|
@@ -62,10 +65,12 @@ export declare class Inbox {
|
|
|
62
65
|
*
|
|
63
66
|
* @example
|
|
64
67
|
* await client.inbox.get("inboxItemId", {
|
|
65
|
-
* appId: "appId"
|
|
68
|
+
* appId: "appId",
|
|
69
|
+
* itemType: "DUPLICATE_DOCUMENT"
|
|
66
70
|
* })
|
|
67
71
|
*/
|
|
68
|
-
get(inboxItemId: string, request: MavenAGI.InboxItemRequest, requestOptions?: Inbox.RequestOptions):
|
|
72
|
+
get(inboxItemId: string, request: MavenAGI.InboxItemRequest, requestOptions?: Inbox.RequestOptions): core.HttpResponsePromise<MavenAGI.InboxItem>;
|
|
73
|
+
private __get;
|
|
69
74
|
/**
|
|
70
75
|
* Retrieve a suggested fix. Includes document information if the fix is a Missing Knowledge suggestion.
|
|
71
76
|
*
|
|
@@ -79,10 +84,12 @@ export declare class Inbox {
|
|
|
79
84
|
*
|
|
80
85
|
* @example
|
|
81
86
|
* await client.inbox.getFix("inboxItemFixId", {
|
|
82
|
-
* appId: "appId"
|
|
87
|
+
* appId: "appId",
|
|
88
|
+
* fixType: "REMOVE_DOCUMENT"
|
|
83
89
|
* })
|
|
84
90
|
*/
|
|
85
|
-
getFix(inboxItemFixId: string, request: MavenAGI.InboxItemFixRequest, requestOptions?: Inbox.RequestOptions):
|
|
91
|
+
getFix(inboxItemFixId: string, request: MavenAGI.InboxItemFixRequest, requestOptions?: Inbox.RequestOptions): core.HttpResponsePromise<MavenAGI.InboxItemFix>;
|
|
92
|
+
private __getFix;
|
|
86
93
|
/**
|
|
87
94
|
* Apply a fix to an inbox item with a specific document.
|
|
88
95
|
*
|
|
@@ -96,10 +103,12 @@ export declare class Inbox {
|
|
|
96
103
|
*
|
|
97
104
|
* @example
|
|
98
105
|
* await client.inbox.applyFix("inboxItemFixId", {
|
|
99
|
-
* appId: "appId"
|
|
106
|
+
* appId: "appId",
|
|
107
|
+
* fixType: "REMOVE_DOCUMENT"
|
|
100
108
|
* })
|
|
101
109
|
*/
|
|
102
|
-
applyFix(inboxItemFixId: string, request: MavenAGI.ApplyInboxItemFixRequest, requestOptions?: Inbox.RequestOptions):
|
|
110
|
+
applyFix(inboxItemFixId: string, request: MavenAGI.ApplyInboxItemFixRequest, requestOptions?: Inbox.RequestOptions): core.HttpResponsePromise<void>;
|
|
111
|
+
private __applyFix;
|
|
103
112
|
/**
|
|
104
113
|
* Ignore a specific inbox item by its ID.
|
|
105
114
|
*
|
|
@@ -113,9 +122,11 @@ export declare class Inbox {
|
|
|
113
122
|
*
|
|
114
123
|
* @example
|
|
115
124
|
* await client.inbox.ignore("inboxItemId", {
|
|
116
|
-
* appId: "appId"
|
|
125
|
+
* appId: "appId",
|
|
126
|
+
* itemType: "DUPLICATE_DOCUMENT"
|
|
117
127
|
* })
|
|
118
128
|
*/
|
|
119
|
-
ignore(inboxItemId: string, request: MavenAGI.InboxItemIgnoreRequest, requestOptions?: Inbox.RequestOptions):
|
|
129
|
+
ignore(inboxItemId: string, request: MavenAGI.InboxItemIgnoreRequest, requestOptions?: Inbox.RequestOptions): core.HttpResponsePromise<void>;
|
|
130
|
+
private __ignore;
|
|
120
131
|
protected _getAuthorizationHeader(): Promise<string | undefined>;
|
|
121
132
|
}
|