@wildix/xbees-conversations-client 1.1.1 → 1.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist-cjs/Conversations.js +2 -0
- package/dist-cjs/commands/CreateKiteChannelCommand.js +21 -0
- package/dist-cjs/commands/index.js +1 -0
- package/dist-cjs/models/models_0.js +39 -9
- package/dist-cjs/protocols/Aws_restJson1.js +76 -4
- package/dist-es/Conversations.js +2 -0
- package/dist-es/commands/CreateKiteChannelCommand.js +17 -0
- package/dist-es/commands/index.js +1 -0
- package/dist-es/models/models_0.js +36 -8
- package/dist-es/protocols/Aws_restJson1.js +72 -2
- package/dist-types/Conversations.d.ts +7 -0
- package/dist-types/ConversationsClient.d.ts +3 -2
- package/dist-types/commands/CreateKiteChannelCommand.d.ts +326 -0
- package/dist-types/commands/SendMessageCommand.d.ts +2 -2
- package/dist-types/commands/UpdateMessageCommand.d.ts +2 -2
- package/dist-types/commands/index.d.ts +1 -0
- package/dist-types/models/models_0.d.ts +211 -95
- package/dist-types/protocols/Aws_restJson1.d.ts +9 -0
- package/package.json +2 -2
|
@@ -6,6 +6,7 @@ const AddChannelMemberCommand_1 = require("./commands/AddChannelMemberCommand");
|
|
|
6
6
|
const AddChannelMembersCommand_1 = require("./commands/AddChannelMembersCommand");
|
|
7
7
|
const CreateGroupChannelCommand_1 = require("./commands/CreateGroupChannelCommand");
|
|
8
8
|
const CreateInboxTagCommand_1 = require("./commands/CreateInboxTagCommand");
|
|
9
|
+
const CreateKiteChannelCommand_1 = require("./commands/CreateKiteChannelCommand");
|
|
9
10
|
const DeleteChannelCommand_1 = require("./commands/DeleteChannelCommand");
|
|
10
11
|
const DeleteChannelMemberCommand_1 = require("./commands/DeleteChannelMemberCommand");
|
|
11
12
|
const DeleteInboxTagCommand_1 = require("./commands/DeleteInboxTagCommand");
|
|
@@ -61,6 +62,7 @@ const commands = {
|
|
|
61
62
|
AddChannelMembersCommand: AddChannelMembersCommand_1.AddChannelMembersCommand,
|
|
62
63
|
CreateGroupChannelCommand: CreateGroupChannelCommand_1.CreateGroupChannelCommand,
|
|
63
64
|
CreateInboxTagCommand: CreateInboxTagCommand_1.CreateInboxTagCommand,
|
|
65
|
+
CreateKiteChannelCommand: CreateKiteChannelCommand_1.CreateKiteChannelCommand,
|
|
64
66
|
DeleteChannelCommand: DeleteChannelCommand_1.DeleteChannelCommand,
|
|
65
67
|
DeleteChannelMemberCommand: DeleteChannelMemberCommand_1.DeleteChannelMemberCommand,
|
|
66
68
|
DeleteInboxTagCommand: DeleteInboxTagCommand_1.DeleteInboxTagCommand,
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CreateKiteChannelCommand = exports.$Command = void 0;
|
|
4
|
+
const Aws_restJson1_1 = require("../protocols/Aws_restJson1");
|
|
5
|
+
const middleware_serde_1 = require("@smithy/middleware-serde");
|
|
6
|
+
const smithy_client_1 = require("@smithy/smithy-client");
|
|
7
|
+
Object.defineProperty(exports, "$Command", { enumerable: true, get: function () { return smithy_client_1.Command; } });
|
|
8
|
+
class CreateKiteChannelCommand extends smithy_client_1.Command.classBuilder()
|
|
9
|
+
.m(function (Command, cs, config, o) {
|
|
10
|
+
return [
|
|
11
|
+
(0, middleware_serde_1.getSerdePlugin)(config, this.serialize, this.deserialize),
|
|
12
|
+
];
|
|
13
|
+
})
|
|
14
|
+
.s("Conversations", "CreateKiteChannel", {})
|
|
15
|
+
.n("ConversationsClient", "CreateKiteChannelCommand")
|
|
16
|
+
.f(void 0, void 0)
|
|
17
|
+
.ser(Aws_restJson1_1.se_CreateKiteChannelCommand)
|
|
18
|
+
.de(Aws_restJson1_1.de_CreateKiteChannelCommand)
|
|
19
|
+
.build() {
|
|
20
|
+
}
|
|
21
|
+
exports.CreateKiteChannelCommand = CreateKiteChannelCommand;
|
|
@@ -5,6 +5,7 @@ tslib_1.__exportStar(require("./AddChannelMemberCommand"), exports);
|
|
|
5
5
|
tslib_1.__exportStar(require("./AddChannelMembersCommand"), exports);
|
|
6
6
|
tslib_1.__exportStar(require("./CreateGroupChannelCommand"), exports);
|
|
7
7
|
tslib_1.__exportStar(require("./CreateInboxTagCommand"), exports);
|
|
8
|
+
tslib_1.__exportStar(require("./CreateKiteChannelCommand"), exports);
|
|
8
9
|
tslib_1.__exportStar(require("./DeleteChannelCommand"), exports);
|
|
9
10
|
tslib_1.__exportStar(require("./DeleteChannelMemberCommand"), exports);
|
|
10
11
|
tslib_1.__exportStar(require("./DeleteInboxTagCommand"), exports);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.MessageActionNotFoundException = exports.TaggedChannelsLimitReachedException = exports.ConversationsServiceException = exports.PinnedChannelsLimitReachedException = exports.MessageUnsetFields = exports.GroupChannelUnsetOptions = exports.MarkUnreadChannelsLimitReachedException = exports.TagNotFoundException = exports.TriggerNotFoundException = exports.WebhookEventType = exports.MessageWhatsAppStatus = exports.MessageType = exports.MessageSmsStatus = exports.
|
|
3
|
+
exports.MessageActionNotFoundException = exports.TaggedChannelsLimitReachedException = exports.ConversationsServiceException = exports.PinnedChannelsLimitReachedException = exports.MessageUnsetFields = exports.GroupChannelUnsetOptions = exports.MarkUnreadChannelsLimitReachedException = exports.TagNotFoundException = exports.TriggerNotFoundException = exports.WebhookEventType = exports.MessageWhatsAppStatus = exports.MessageType = exports.MessageSmsStatus = exports.ReactionType = exports.MessageNotFoundException = exports.MemberNotFoundException = exports.TargetNotFoundException = exports.TargetNotEligibleException = exports.TargetNotEligibleReason = exports.Element = exports.TagsLimitReachedException = exports.ChannelAlreadyExistException = exports.ChannelWhatsAppStatus = exports.ChannelContextSource = exports.ChannelContextEventAttendeeStatus = exports.ChannelAccess = exports.MemberAlreadyExistException = exports.ChannelNotFoundException = exports.ChannelMemberRole = exports.ActionTriggerStatus = exports.ActionElement = exports.ButtonVariant = exports.ButtonHandler = exports.ChannelType = exports.FileNotFoundException = exports.ConversationFileCategory = exports.RateLimitExceededException = exports.ForbiddenException = exports.ValidationException = void 0;
|
|
4
4
|
const ConversationsServiceException_1 = require("./ConversationsServiceException");
|
|
5
5
|
class ValidationException extends ConversationsServiceException_1.ConversationsServiceException {
|
|
6
6
|
constructor(opts) {
|
|
@@ -167,6 +167,44 @@ class TagsLimitReachedException extends ConversationsServiceException_1.Conversa
|
|
|
167
167
|
}
|
|
168
168
|
}
|
|
169
169
|
exports.TagsLimitReachedException = TagsLimitReachedException;
|
|
170
|
+
var Element;
|
|
171
|
+
(function (Element) {
|
|
172
|
+
Element.visit = (value, visitor) => {
|
|
173
|
+
if (value.actions !== undefined)
|
|
174
|
+
return visitor.actions(value.actions);
|
|
175
|
+
return visitor._(value.$unknown[0], value.$unknown[1]);
|
|
176
|
+
};
|
|
177
|
+
})(Element = exports.Element || (exports.Element = {}));
|
|
178
|
+
exports.TargetNotEligibleReason = {
|
|
179
|
+
NO_LICENSE: "no_license",
|
|
180
|
+
};
|
|
181
|
+
class TargetNotEligibleException extends ConversationsServiceException_1.ConversationsServiceException {
|
|
182
|
+
constructor(opts) {
|
|
183
|
+
super({
|
|
184
|
+
name: "TargetNotEligibleException",
|
|
185
|
+
$fault: "client",
|
|
186
|
+
...opts
|
|
187
|
+
});
|
|
188
|
+
this.name = "TargetNotEligibleException";
|
|
189
|
+
this.$fault = "client";
|
|
190
|
+
Object.setPrototypeOf(this, TargetNotEligibleException.prototype);
|
|
191
|
+
this.reason = opts.reason;
|
|
192
|
+
}
|
|
193
|
+
}
|
|
194
|
+
exports.TargetNotEligibleException = TargetNotEligibleException;
|
|
195
|
+
class TargetNotFoundException extends ConversationsServiceException_1.ConversationsServiceException {
|
|
196
|
+
constructor(opts) {
|
|
197
|
+
super({
|
|
198
|
+
name: "TargetNotFoundException",
|
|
199
|
+
$fault: "client",
|
|
200
|
+
...opts
|
|
201
|
+
});
|
|
202
|
+
this.name = "TargetNotFoundException";
|
|
203
|
+
this.$fault = "client";
|
|
204
|
+
Object.setPrototypeOf(this, TargetNotFoundException.prototype);
|
|
205
|
+
}
|
|
206
|
+
}
|
|
207
|
+
exports.TargetNotFoundException = TargetNotFoundException;
|
|
170
208
|
class MemberNotFoundException extends ConversationsServiceException_1.ConversationsServiceException {
|
|
171
209
|
constructor(opts) {
|
|
172
210
|
super({
|
|
@@ -204,14 +242,6 @@ exports.ReactionType = {
|
|
|
204
242
|
THUMBSUP: "thumbsup",
|
|
205
243
|
WHITE_CHECK_MARK: "white_check_mark",
|
|
206
244
|
};
|
|
207
|
-
var Element;
|
|
208
|
-
(function (Element) {
|
|
209
|
-
Element.visit = (value, visitor) => {
|
|
210
|
-
if (value.actions !== undefined)
|
|
211
|
-
return visitor.actions(value.actions);
|
|
212
|
-
return visitor._(value.$unknown[0], value.$unknown[1]);
|
|
213
|
-
};
|
|
214
|
-
})(Element = exports.Element || (exports.Element = {}));
|
|
215
245
|
exports.MessageSmsStatus = {
|
|
216
246
|
DELIVERED: "delivered",
|
|
217
247
|
ERROR: "error",
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
4
|
-
exports.
|
|
5
|
-
exports.de_UploadFileCommand = exports.de_UpdateMessageCommand = exports.de_UpdateInboxTagCommand = exports.de_UpdateChannelCommand = exports.de_UntagChannelCommand = exports.de_UnpinMessageCommand = void 0;
|
|
3
|
+
exports.se_UntagChannelCommand = exports.se_UnpinMessageCommand = exports.se_UnpinChannelCommand = exports.se_TriggerMessageActionCommand = exports.se_TagChannelCommand = exports.se_ShowChannelCommand = exports.se_SendTypingStopCommand = exports.se_SendTypingStartCommand = exports.se_SendMessageReactionCommand = exports.se_SendMessageCommand = exports.se_SendGiphyCommand = exports.se_SendActionTriggerResultCommand = exports.se_ScheduleExternalFlagAdjustmentJobCommand = exports.se_PinMessageCommand = exports.se_PinChannelCommand = exports.se_PartialUpdateMessageCommand = exports.se_PartialUpdateChannelCommand = exports.se_MarkUnreadCommand = exports.se_MarkReadCommand = exports.se_ListPinnedMessagesCommand = exports.se_ListMessagesCommand = exports.se_ListMessageReactionsCommand = exports.se_ListInboxTagsCommand = exports.se_ListInboxTaggedChannelsCommand = exports.se_ListChannelsCommand = exports.se_ListChannelMembersCommand = exports.se_LeaveChannelCommand = exports.se_JoinChannelCommand = exports.se_InviteCommand = exports.se_HideChannelCommand = exports.se_GetUploadedFileInfoCommand = exports.se_GetOrCreateDirectChannelCommand = exports.se_GetMessageCommand = exports.se_GetInboxStateCommand = exports.se_GetFilePresignedDownloadUrlCommand = exports.se_GetDirectChannelIdCommand = exports.se_GetChannelMemberCommand = exports.se_GetChannelCommand = exports.se_GetActionTriggerResultCommand = exports.se_DescribeEventCommand = exports.se_DeleteMessageReactionCommand = exports.se_DeleteMessageCommand = exports.se_DeleteInboxTagCommand = exports.se_DeleteChannelMemberCommand = exports.se_DeleteChannelCommand = exports.se_CreateKiteChannelCommand = exports.se_CreateInboxTagCommand = exports.se_CreateGroupChannelCommand = exports.se_AddChannelMembersCommand = exports.se_AddChannelMemberCommand = void 0;
|
|
4
|
+
exports.de_TagChannelCommand = exports.de_ShowChannelCommand = exports.de_SendTypingStopCommand = exports.de_SendTypingStartCommand = exports.de_SendMessageReactionCommand = exports.de_SendMessageCommand = exports.de_SendGiphyCommand = exports.de_SendActionTriggerResultCommand = exports.de_ScheduleExternalFlagAdjustmentJobCommand = exports.de_PinMessageCommand = exports.de_PinChannelCommand = exports.de_PartialUpdateMessageCommand = exports.de_PartialUpdateChannelCommand = exports.de_MarkUnreadCommand = exports.de_MarkReadCommand = exports.de_ListPinnedMessagesCommand = exports.de_ListMessagesCommand = exports.de_ListMessageReactionsCommand = exports.de_ListInboxTagsCommand = exports.de_ListInboxTaggedChannelsCommand = exports.de_ListChannelsCommand = exports.de_ListChannelMembersCommand = exports.de_LeaveChannelCommand = exports.de_JoinChannelCommand = exports.de_InviteCommand = exports.de_HideChannelCommand = exports.de_GetUploadedFileInfoCommand = exports.de_GetOrCreateDirectChannelCommand = exports.de_GetMessageCommand = exports.de_GetInboxStateCommand = exports.de_GetFilePresignedDownloadUrlCommand = exports.de_GetDirectChannelIdCommand = exports.de_GetChannelMemberCommand = exports.de_GetChannelCommand = exports.de_GetActionTriggerResultCommand = exports.de_DescribeEventCommand = exports.de_DeleteMessageReactionCommand = exports.de_DeleteMessageCommand = exports.de_DeleteInboxTagCommand = exports.de_DeleteChannelMemberCommand = exports.de_DeleteChannelCommand = exports.de_CreateKiteChannelCommand = exports.de_CreateInboxTagCommand = exports.de_CreateGroupChannelCommand = exports.de_AddChannelMembersCommand = exports.de_AddChannelMemberCommand = exports.se_UploadFileCommand = exports.se_UpdateMessageCommand = exports.se_UpdateInboxTagCommand = exports.se_UpdateChannelCommand = void 0;
|
|
5
|
+
exports.de_UploadFileCommand = exports.de_UpdateMessageCommand = exports.de_UpdateInboxTagCommand = exports.de_UpdateChannelCommand = exports.de_UntagChannelCommand = exports.de_UnpinMessageCommand = exports.de_UnpinChannelCommand = exports.de_TriggerMessageActionCommand = void 0;
|
|
6
6
|
const ConversationsServiceException_1 = require("../models/ConversationsServiceException");
|
|
7
7
|
const models_0_1 = require("../models/models_0");
|
|
8
8
|
const core_1 = require("@smithy/core");
|
|
@@ -102,6 +102,30 @@ const se_CreateInboxTagCommand = async (input, context) => {
|
|
|
102
102
|
return b.build();
|
|
103
103
|
};
|
|
104
104
|
exports.se_CreateInboxTagCommand = se_CreateInboxTagCommand;
|
|
105
|
+
const se_CreateKiteChannelCommand = async (input, context) => {
|
|
106
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
107
|
+
const headers = {
|
|
108
|
+
'content-type': 'application/json',
|
|
109
|
+
};
|
|
110
|
+
b.bp("/v2/conversations/kite");
|
|
111
|
+
const query = (0, smithy_client_1.map)({
|
|
112
|
+
[_u]: [, input[_uI]],
|
|
113
|
+
});
|
|
114
|
+
let body;
|
|
115
|
+
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
116
|
+
'channelId': [],
|
|
117
|
+
'initialMessage': _ => (0, smithy_client_1._json)(_),
|
|
118
|
+
'targetId': [],
|
|
119
|
+
'targetRouteId': [],
|
|
120
|
+
'welcomeMessages': _ => (0, smithy_client_1._json)(_),
|
|
121
|
+
}));
|
|
122
|
+
b.m("POST")
|
|
123
|
+
.h(headers)
|
|
124
|
+
.q(query)
|
|
125
|
+
.b(body);
|
|
126
|
+
return b.build();
|
|
127
|
+
};
|
|
128
|
+
exports.se_CreateKiteChannelCommand = se_CreateKiteChannelCommand;
|
|
105
129
|
const se_DeleteChannelCommand = async (input, context) => {
|
|
106
130
|
const b = (0, core_1.requestBuilder)(input, context);
|
|
107
131
|
const headers = {};
|
|
@@ -959,8 +983,8 @@ const se_UpdateMessageCommand = async (input, context) => {
|
|
|
959
983
|
'content-type': 'application/json',
|
|
960
984
|
};
|
|
961
985
|
b.bp("/v2/conversations/channels/{channelId}/messages/{messageId}");
|
|
962
|
-
b.p('channelId', () => input.channelId, '{channelId}', false);
|
|
963
986
|
b.p('messageId', () => input.messageId, '{messageId}', false);
|
|
987
|
+
b.p('channelId', () => input.channelId, '{channelId}', false);
|
|
964
988
|
const query = (0, smithy_client_1.map)({
|
|
965
989
|
[_u]: [, input[_uI]],
|
|
966
990
|
});
|
|
@@ -1065,6 +1089,21 @@ const de_CreateInboxTagCommand = async (output, context) => {
|
|
|
1065
1089
|
return contents;
|
|
1066
1090
|
};
|
|
1067
1091
|
exports.de_CreateInboxTagCommand = de_CreateInboxTagCommand;
|
|
1092
|
+
const de_CreateKiteChannelCommand = async (output, context) => {
|
|
1093
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1094
|
+
return de_CommandError(output, context);
|
|
1095
|
+
}
|
|
1096
|
+
const contents = (0, smithy_client_1.map)({
|
|
1097
|
+
$metadata: deserializeMetadata(output),
|
|
1098
|
+
});
|
|
1099
|
+
const data = (0, smithy_client_1.expectNonNull)(((0, smithy_client_1.expectObject)(await parseBody(output.body, context))), "body");
|
|
1100
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
1101
|
+
'channel': smithy_client_1._json,
|
|
1102
|
+
});
|
|
1103
|
+
Object.assign(contents, doc);
|
|
1104
|
+
return contents;
|
|
1105
|
+
};
|
|
1106
|
+
exports.de_CreateKiteChannelCommand = de_CreateKiteChannelCommand;
|
|
1068
1107
|
const de_DeleteChannelCommand = async (output, context) => {
|
|
1069
1108
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1070
1109
|
return de_CommandError(output, context);
|
|
@@ -1758,6 +1797,12 @@ const de_CommandError = async (output, context) => {
|
|
|
1758
1797
|
case "TagsLimitReachedException":
|
|
1759
1798
|
case "wildix.xbees.conversations#TagsLimitReachedException":
|
|
1760
1799
|
throw await de_TagsLimitReachedExceptionRes(parsedOutput, context);
|
|
1800
|
+
case "TargetNotEligibleException":
|
|
1801
|
+
case "wildix.xbees.conversations#TargetNotEligibleException":
|
|
1802
|
+
throw await de_TargetNotEligibleExceptionRes(parsedOutput, context);
|
|
1803
|
+
case "TargetNotFoundException":
|
|
1804
|
+
case "wildix.xbees.conversations#TargetNotFoundException":
|
|
1805
|
+
throw await de_TargetNotFoundExceptionRes(parsedOutput, context);
|
|
1761
1806
|
case "MemberNotFoundException":
|
|
1762
1807
|
case "wildix.xbees.conversations#MemberNotFoundException":
|
|
1763
1808
|
throw await de_MemberNotFoundExceptionRes(parsedOutput, context);
|
|
@@ -2011,6 +2056,33 @@ const de_TagsLimitReachedExceptionRes = async (parsedOutput, context) => {
|
|
|
2011
2056
|
});
|
|
2012
2057
|
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
2013
2058
|
};
|
|
2059
|
+
const de_TargetNotEligibleExceptionRes = async (parsedOutput, context) => {
|
|
2060
|
+
const contents = (0, smithy_client_1.map)({});
|
|
2061
|
+
const data = parsedOutput.body;
|
|
2062
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
2063
|
+
'message': smithy_client_1.expectString,
|
|
2064
|
+
'reason': smithy_client_1.expectString,
|
|
2065
|
+
});
|
|
2066
|
+
Object.assign(contents, doc);
|
|
2067
|
+
const exception = new models_0_1.TargetNotEligibleException({
|
|
2068
|
+
$metadata: deserializeMetadata(parsedOutput),
|
|
2069
|
+
...contents
|
|
2070
|
+
});
|
|
2071
|
+
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
2072
|
+
};
|
|
2073
|
+
const de_TargetNotFoundExceptionRes = async (parsedOutput, context) => {
|
|
2074
|
+
const contents = (0, smithy_client_1.map)({});
|
|
2075
|
+
const data = parsedOutput.body;
|
|
2076
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
2077
|
+
'message': smithy_client_1.expectString,
|
|
2078
|
+
});
|
|
2079
|
+
Object.assign(contents, doc);
|
|
2080
|
+
const exception = new models_0_1.TargetNotFoundException({
|
|
2081
|
+
$metadata: deserializeMetadata(parsedOutput),
|
|
2082
|
+
...contents
|
|
2083
|
+
});
|
|
2084
|
+
return (0, smithy_client_1.decorateServiceException)(exception, parsedOutput.body);
|
|
2085
|
+
};
|
|
2014
2086
|
const de_TriggerNotFoundExceptionRes = async (parsedOutput, context) => {
|
|
2015
2087
|
const contents = (0, smithy_client_1.map)({});
|
|
2016
2088
|
const data = parsedOutput.body;
|
package/dist-es/Conversations.js
CHANGED
|
@@ -3,6 +3,7 @@ import { AddChannelMemberCommand, } from "./commands/AddChannelMemberCommand";
|
|
|
3
3
|
import { AddChannelMembersCommand, } from "./commands/AddChannelMembersCommand";
|
|
4
4
|
import { CreateGroupChannelCommand, } from "./commands/CreateGroupChannelCommand";
|
|
5
5
|
import { CreateInboxTagCommand, } from "./commands/CreateInboxTagCommand";
|
|
6
|
+
import { CreateKiteChannelCommand, } from "./commands/CreateKiteChannelCommand";
|
|
6
7
|
import { DeleteChannelCommand, } from "./commands/DeleteChannelCommand";
|
|
7
8
|
import { DeleteChannelMemberCommand, } from "./commands/DeleteChannelMemberCommand";
|
|
8
9
|
import { DeleteInboxTagCommand, } from "./commands/DeleteInboxTagCommand";
|
|
@@ -58,6 +59,7 @@ const commands = {
|
|
|
58
59
|
AddChannelMembersCommand,
|
|
59
60
|
CreateGroupChannelCommand,
|
|
60
61
|
CreateInboxTagCommand,
|
|
62
|
+
CreateKiteChannelCommand,
|
|
61
63
|
DeleteChannelCommand,
|
|
62
64
|
DeleteChannelMemberCommand,
|
|
63
65
|
DeleteInboxTagCommand,
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { de_CreateKiteChannelCommand, se_CreateKiteChannelCommand, } from "../protocols/Aws_restJson1";
|
|
2
|
+
import { getSerdePlugin } from "@smithy/middleware-serde";
|
|
3
|
+
import { Command as $Command } from "@smithy/smithy-client";
|
|
4
|
+
export { $Command };
|
|
5
|
+
export class CreateKiteChannelCommand extends $Command.classBuilder()
|
|
6
|
+
.m(function (Command, cs, config, o) {
|
|
7
|
+
return [
|
|
8
|
+
getSerdePlugin(config, this.serialize, this.deserialize),
|
|
9
|
+
];
|
|
10
|
+
})
|
|
11
|
+
.s("Conversations", "CreateKiteChannel", {})
|
|
12
|
+
.n("ConversationsClient", "CreateKiteChannelCommand")
|
|
13
|
+
.f(void 0, void 0)
|
|
14
|
+
.ser(se_CreateKiteChannelCommand)
|
|
15
|
+
.de(de_CreateKiteChannelCommand)
|
|
16
|
+
.build() {
|
|
17
|
+
}
|
|
@@ -2,6 +2,7 @@ export * from "./AddChannelMemberCommand";
|
|
|
2
2
|
export * from "./AddChannelMembersCommand";
|
|
3
3
|
export * from "./CreateGroupChannelCommand";
|
|
4
4
|
export * from "./CreateInboxTagCommand";
|
|
5
|
+
export * from "./CreateKiteChannelCommand";
|
|
5
6
|
export * from "./DeleteChannelCommand";
|
|
6
7
|
export * from "./DeleteChannelMemberCommand";
|
|
7
8
|
export * from "./DeleteInboxTagCommand";
|
|
@@ -156,6 +156,42 @@ export class TagsLimitReachedException extends __BaseException {
|
|
|
156
156
|
Object.setPrototypeOf(this, TagsLimitReachedException.prototype);
|
|
157
157
|
}
|
|
158
158
|
}
|
|
159
|
+
export var Element;
|
|
160
|
+
(function (Element) {
|
|
161
|
+
Element.visit = (value, visitor) => {
|
|
162
|
+
if (value.actions !== undefined)
|
|
163
|
+
return visitor.actions(value.actions);
|
|
164
|
+
return visitor._(value.$unknown[0], value.$unknown[1]);
|
|
165
|
+
};
|
|
166
|
+
})(Element || (Element = {}));
|
|
167
|
+
export const TargetNotEligibleReason = {
|
|
168
|
+
NO_LICENSE: "no_license",
|
|
169
|
+
};
|
|
170
|
+
export class TargetNotEligibleException extends __BaseException {
|
|
171
|
+
constructor(opts) {
|
|
172
|
+
super({
|
|
173
|
+
name: "TargetNotEligibleException",
|
|
174
|
+
$fault: "client",
|
|
175
|
+
...opts
|
|
176
|
+
});
|
|
177
|
+
this.name = "TargetNotEligibleException";
|
|
178
|
+
this.$fault = "client";
|
|
179
|
+
Object.setPrototypeOf(this, TargetNotEligibleException.prototype);
|
|
180
|
+
this.reason = opts.reason;
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
export class TargetNotFoundException extends __BaseException {
|
|
184
|
+
constructor(opts) {
|
|
185
|
+
super({
|
|
186
|
+
name: "TargetNotFoundException",
|
|
187
|
+
$fault: "client",
|
|
188
|
+
...opts
|
|
189
|
+
});
|
|
190
|
+
this.name = "TargetNotFoundException";
|
|
191
|
+
this.$fault = "client";
|
|
192
|
+
Object.setPrototypeOf(this, TargetNotFoundException.prototype);
|
|
193
|
+
}
|
|
194
|
+
}
|
|
159
195
|
export class MemberNotFoundException extends __BaseException {
|
|
160
196
|
constructor(opts) {
|
|
161
197
|
super({
|
|
@@ -191,14 +227,6 @@ export const ReactionType = {
|
|
|
191
227
|
THUMBSUP: "thumbsup",
|
|
192
228
|
WHITE_CHECK_MARK: "white_check_mark",
|
|
193
229
|
};
|
|
194
|
-
export var Element;
|
|
195
|
-
(function (Element) {
|
|
196
|
-
Element.visit = (value, visitor) => {
|
|
197
|
-
if (value.actions !== undefined)
|
|
198
|
-
return visitor.actions(value.actions);
|
|
199
|
-
return visitor._(value.$unknown[0], value.$unknown[1]);
|
|
200
|
-
};
|
|
201
|
-
})(Element || (Element = {}));
|
|
202
230
|
export const MessageSmsStatus = {
|
|
203
231
|
DELIVERED: "delivered",
|
|
204
232
|
ERROR: "error",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ConversationsServiceException as __BaseException } from "../models/ConversationsServiceException";
|
|
2
|
-
import { ChannelAlreadyExistException, ChannelNotFoundException, ConversationsServiceException, FileNotFoundException, ForbiddenException, MarkUnreadChannelsLimitReachedException, MemberAlreadyExistException, MemberNotFoundException, MessageActionNotFoundException, MessageNotFoundException, PinnedChannelsLimitReachedException, RateLimitExceededException, TagNotFoundException, TaggedChannelsLimitReachedException, TagsLimitReachedException, TriggerNotFoundException, ValidationException, } from "../models/models_0";
|
|
2
|
+
import { ChannelAlreadyExistException, ChannelNotFoundException, ConversationsServiceException, FileNotFoundException, ForbiddenException, MarkUnreadChannelsLimitReachedException, MemberAlreadyExistException, MemberNotFoundException, MessageActionNotFoundException, MessageNotFoundException, PinnedChannelsLimitReachedException, RateLimitExceededException, TagNotFoundException, TaggedChannelsLimitReachedException, TagsLimitReachedException, TargetNotEligibleException, TargetNotFoundException, TriggerNotFoundException, ValidationException, } from "../models/models_0";
|
|
3
3
|
import { requestBuilder as rb } from "@smithy/core";
|
|
4
4
|
import { decorateServiceException as __decorateServiceException, expectNonNull as __expectNonNull, expectObject as __expectObject, expectString as __expectString, strictParseInt32 as __strictParseInt32, _json, collectBody, map, take, withBaseException, } from "@smithy/smithy-client";
|
|
5
5
|
export const se_AddChannelMemberCommand = async (input, context) => {
|
|
@@ -93,6 +93,29 @@ export const se_CreateInboxTagCommand = async (input, context) => {
|
|
|
93
93
|
.b(body);
|
|
94
94
|
return b.build();
|
|
95
95
|
};
|
|
96
|
+
export const se_CreateKiteChannelCommand = async (input, context) => {
|
|
97
|
+
const b = rb(input, context);
|
|
98
|
+
const headers = {
|
|
99
|
+
'content-type': 'application/json',
|
|
100
|
+
};
|
|
101
|
+
b.bp("/v2/conversations/kite");
|
|
102
|
+
const query = map({
|
|
103
|
+
[_u]: [, input[_uI]],
|
|
104
|
+
});
|
|
105
|
+
let body;
|
|
106
|
+
body = JSON.stringify(take(input, {
|
|
107
|
+
'channelId': [],
|
|
108
|
+
'initialMessage': _ => _json(_),
|
|
109
|
+
'targetId': [],
|
|
110
|
+
'targetRouteId': [],
|
|
111
|
+
'welcomeMessages': _ => _json(_),
|
|
112
|
+
}));
|
|
113
|
+
b.m("POST")
|
|
114
|
+
.h(headers)
|
|
115
|
+
.q(query)
|
|
116
|
+
.b(body);
|
|
117
|
+
return b.build();
|
|
118
|
+
};
|
|
96
119
|
export const se_DeleteChannelCommand = async (input, context) => {
|
|
97
120
|
const b = rb(input, context);
|
|
98
121
|
const headers = {};
|
|
@@ -903,8 +926,8 @@ export const se_UpdateMessageCommand = async (input, context) => {
|
|
|
903
926
|
'content-type': 'application/json',
|
|
904
927
|
};
|
|
905
928
|
b.bp("/v2/conversations/channels/{channelId}/messages/{messageId}");
|
|
906
|
-
b.p('channelId', () => input.channelId, '{channelId}', false);
|
|
907
929
|
b.p('messageId', () => input.messageId, '{messageId}', false);
|
|
930
|
+
b.p('channelId', () => input.channelId, '{channelId}', false);
|
|
908
931
|
const query = map({
|
|
909
932
|
[_u]: [, input[_uI]],
|
|
910
933
|
});
|
|
@@ -1003,6 +1026,20 @@ export const de_CreateInboxTagCommand = async (output, context) => {
|
|
|
1003
1026
|
Object.assign(contents, doc);
|
|
1004
1027
|
return contents;
|
|
1005
1028
|
};
|
|
1029
|
+
export const de_CreateKiteChannelCommand = async (output, context) => {
|
|
1030
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1031
|
+
return de_CommandError(output, context);
|
|
1032
|
+
}
|
|
1033
|
+
const contents = map({
|
|
1034
|
+
$metadata: deserializeMetadata(output),
|
|
1035
|
+
});
|
|
1036
|
+
const data = __expectNonNull((__expectObject(await parseBody(output.body, context))), "body");
|
|
1037
|
+
const doc = take(data, {
|
|
1038
|
+
'channel': _json,
|
|
1039
|
+
});
|
|
1040
|
+
Object.assign(contents, doc);
|
|
1041
|
+
return contents;
|
|
1042
|
+
};
|
|
1006
1043
|
export const de_DeleteChannelCommand = async (output, context) => {
|
|
1007
1044
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1008
1045
|
return de_CommandError(output, context);
|
|
@@ -1647,6 +1684,12 @@ const de_CommandError = async (output, context) => {
|
|
|
1647
1684
|
case "TagsLimitReachedException":
|
|
1648
1685
|
case "wildix.xbees.conversations#TagsLimitReachedException":
|
|
1649
1686
|
throw await de_TagsLimitReachedExceptionRes(parsedOutput, context);
|
|
1687
|
+
case "TargetNotEligibleException":
|
|
1688
|
+
case "wildix.xbees.conversations#TargetNotEligibleException":
|
|
1689
|
+
throw await de_TargetNotEligibleExceptionRes(parsedOutput, context);
|
|
1690
|
+
case "TargetNotFoundException":
|
|
1691
|
+
case "wildix.xbees.conversations#TargetNotFoundException":
|
|
1692
|
+
throw await de_TargetNotFoundExceptionRes(parsedOutput, context);
|
|
1650
1693
|
case "MemberNotFoundException":
|
|
1651
1694
|
case "wildix.xbees.conversations#MemberNotFoundException":
|
|
1652
1695
|
throw await de_MemberNotFoundExceptionRes(parsedOutput, context);
|
|
@@ -1900,6 +1943,33 @@ const de_TagsLimitReachedExceptionRes = async (parsedOutput, context) => {
|
|
|
1900
1943
|
});
|
|
1901
1944
|
return __decorateServiceException(exception, parsedOutput.body);
|
|
1902
1945
|
};
|
|
1946
|
+
const de_TargetNotEligibleExceptionRes = async (parsedOutput, context) => {
|
|
1947
|
+
const contents = map({});
|
|
1948
|
+
const data = parsedOutput.body;
|
|
1949
|
+
const doc = take(data, {
|
|
1950
|
+
'message': __expectString,
|
|
1951
|
+
'reason': __expectString,
|
|
1952
|
+
});
|
|
1953
|
+
Object.assign(contents, doc);
|
|
1954
|
+
const exception = new TargetNotEligibleException({
|
|
1955
|
+
$metadata: deserializeMetadata(parsedOutput),
|
|
1956
|
+
...contents
|
|
1957
|
+
});
|
|
1958
|
+
return __decorateServiceException(exception, parsedOutput.body);
|
|
1959
|
+
};
|
|
1960
|
+
const de_TargetNotFoundExceptionRes = async (parsedOutput, context) => {
|
|
1961
|
+
const contents = map({});
|
|
1962
|
+
const data = parsedOutput.body;
|
|
1963
|
+
const doc = take(data, {
|
|
1964
|
+
'message': __expectString,
|
|
1965
|
+
});
|
|
1966
|
+
Object.assign(contents, doc);
|
|
1967
|
+
const exception = new TargetNotFoundException({
|
|
1968
|
+
$metadata: deserializeMetadata(parsedOutput),
|
|
1969
|
+
...contents
|
|
1970
|
+
});
|
|
1971
|
+
return __decorateServiceException(exception, parsedOutput.body);
|
|
1972
|
+
};
|
|
1903
1973
|
const de_TriggerNotFoundExceptionRes = async (parsedOutput, context) => {
|
|
1904
1974
|
const contents = map({});
|
|
1905
1975
|
const data = parsedOutput.body;
|
|
@@ -3,6 +3,7 @@ import { AddChannelMemberCommandInput, AddChannelMemberCommandOutput } from "./c
|
|
|
3
3
|
import { AddChannelMembersCommandInput, AddChannelMembersCommandOutput } from "./commands/AddChannelMembersCommand";
|
|
4
4
|
import { CreateGroupChannelCommandInput, CreateGroupChannelCommandOutput } from "./commands/CreateGroupChannelCommand";
|
|
5
5
|
import { CreateInboxTagCommandInput, CreateInboxTagCommandOutput } from "./commands/CreateInboxTagCommand";
|
|
6
|
+
import { CreateKiteChannelCommandInput, CreateKiteChannelCommandOutput } from "./commands/CreateKiteChannelCommand";
|
|
6
7
|
import { DeleteChannelCommandInput, DeleteChannelCommandOutput } from "./commands/DeleteChannelCommand";
|
|
7
8
|
import { DeleteChannelMemberCommandInput, DeleteChannelMemberCommandOutput } from "./commands/DeleteChannelMemberCommand";
|
|
8
9
|
import { DeleteInboxTagCommandInput, DeleteInboxTagCommandOutput } from "./commands/DeleteInboxTagCommand";
|
|
@@ -79,6 +80,12 @@ export interface Conversations {
|
|
|
79
80
|
createInboxTag(args: CreateInboxTagCommandInput, options?: __HttpHandlerOptions): Promise<CreateInboxTagCommandOutput>;
|
|
80
81
|
createInboxTag(args: CreateInboxTagCommandInput, cb: (err: any, data?: CreateInboxTagCommandOutput) => void): void;
|
|
81
82
|
createInboxTag(args: CreateInboxTagCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: CreateInboxTagCommandOutput) => void): void;
|
|
83
|
+
/**
|
|
84
|
+
* @see {@link CreateKiteChannelCommand}
|
|
85
|
+
*/
|
|
86
|
+
createKiteChannel(args: CreateKiteChannelCommandInput, options?: __HttpHandlerOptions): Promise<CreateKiteChannelCommandOutput>;
|
|
87
|
+
createKiteChannel(args: CreateKiteChannelCommandInput, cb: (err: any, data?: CreateKiteChannelCommandOutput) => void): void;
|
|
88
|
+
createKiteChannel(args: CreateKiteChannelCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: CreateKiteChannelCommandOutput) => void): void;
|
|
82
89
|
/**
|
|
83
90
|
* @see {@link DeleteChannelCommand}
|
|
84
91
|
*/
|
|
@@ -2,6 +2,7 @@ import { AddChannelMemberCommandInput, AddChannelMemberCommandOutput } from "./c
|
|
|
2
2
|
import { AddChannelMembersCommandInput, AddChannelMembersCommandOutput } from "./commands/AddChannelMembersCommand";
|
|
3
3
|
import { CreateGroupChannelCommandInput, CreateGroupChannelCommandOutput } from "./commands/CreateGroupChannelCommand";
|
|
4
4
|
import { CreateInboxTagCommandInput, CreateInboxTagCommandOutput } from "./commands/CreateInboxTagCommand";
|
|
5
|
+
import { CreateKiteChannelCommandInput, CreateKiteChannelCommandOutput } from "./commands/CreateKiteChannelCommand";
|
|
5
6
|
import { DeleteChannelCommandInput, DeleteChannelCommandOutput } from "./commands/DeleteChannelCommand";
|
|
6
7
|
import { DeleteChannelMemberCommandInput, DeleteChannelMemberCommandOutput } from "./commands/DeleteChannelMemberCommand";
|
|
7
8
|
import { DeleteInboxTagCommandInput, DeleteInboxTagCommandOutput } from "./commands/DeleteInboxTagCommand";
|
|
@@ -62,11 +63,11 @@ export { __Client };
|
|
|
62
63
|
/**
|
|
63
64
|
* @public
|
|
64
65
|
*/
|
|
65
|
-
export type ServiceInputTypes = AddChannelMemberCommandInput | AddChannelMembersCommandInput | CreateGroupChannelCommandInput | CreateInboxTagCommandInput | DeleteChannelCommandInput | DeleteChannelMemberCommandInput | DeleteInboxTagCommandInput | DeleteMessageCommandInput | DeleteMessageReactionCommandInput | DescribeEventCommandInput | GetActionTriggerResultCommandInput | GetChannelCommandInput | GetChannelMemberCommandInput | GetDirectChannelIdCommandInput | GetFilePresignedDownloadUrlCommandInput | GetInboxStateCommandInput | GetMessageCommandInput | GetOrCreateDirectChannelCommandInput | GetUploadedFileInfoCommandInput | HideChannelCommandInput | InviteCommandInput | JoinChannelCommandInput | LeaveChannelCommandInput | ListChannelMembersCommandInput | ListChannelsCommandInput | ListInboxTaggedChannelsCommandInput | ListInboxTagsCommandInput | ListMessageReactionsCommandInput | ListMessagesCommandInput | ListPinnedMessagesCommandInput | MarkReadCommandInput | MarkUnreadCommandInput | PartialUpdateChannelCommandInput | PartialUpdateMessageCommandInput | PinChannelCommandInput | PinMessageCommandInput | ScheduleExternalFlagAdjustmentJobCommandInput | SendActionTriggerResultCommandInput | SendGiphyCommandInput | SendMessageCommandInput | SendMessageReactionCommandInput | SendTypingStartCommandInput | SendTypingStopCommandInput | ShowChannelCommandInput | TagChannelCommandInput | TriggerMessageActionCommandInput | UnpinChannelCommandInput | UnpinMessageCommandInput | UntagChannelCommandInput | UpdateChannelCommandInput | UpdateInboxTagCommandInput | UpdateMessageCommandInput | UploadFileCommandInput;
|
|
66
|
+
export type ServiceInputTypes = AddChannelMemberCommandInput | AddChannelMembersCommandInput | CreateGroupChannelCommandInput | CreateInboxTagCommandInput | CreateKiteChannelCommandInput | DeleteChannelCommandInput | DeleteChannelMemberCommandInput | DeleteInboxTagCommandInput | DeleteMessageCommandInput | DeleteMessageReactionCommandInput | DescribeEventCommandInput | GetActionTriggerResultCommandInput | GetChannelCommandInput | GetChannelMemberCommandInput | GetDirectChannelIdCommandInput | GetFilePresignedDownloadUrlCommandInput | GetInboxStateCommandInput | GetMessageCommandInput | GetOrCreateDirectChannelCommandInput | GetUploadedFileInfoCommandInput | HideChannelCommandInput | InviteCommandInput | JoinChannelCommandInput | LeaveChannelCommandInput | ListChannelMembersCommandInput | ListChannelsCommandInput | ListInboxTaggedChannelsCommandInput | ListInboxTagsCommandInput | ListMessageReactionsCommandInput | ListMessagesCommandInput | ListPinnedMessagesCommandInput | MarkReadCommandInput | MarkUnreadCommandInput | PartialUpdateChannelCommandInput | PartialUpdateMessageCommandInput | PinChannelCommandInput | PinMessageCommandInput | ScheduleExternalFlagAdjustmentJobCommandInput | SendActionTriggerResultCommandInput | SendGiphyCommandInput | SendMessageCommandInput | SendMessageReactionCommandInput | SendTypingStartCommandInput | SendTypingStopCommandInput | ShowChannelCommandInput | TagChannelCommandInput | TriggerMessageActionCommandInput | UnpinChannelCommandInput | UnpinMessageCommandInput | UntagChannelCommandInput | UpdateChannelCommandInput | UpdateInboxTagCommandInput | UpdateMessageCommandInput | UploadFileCommandInput;
|
|
66
67
|
/**
|
|
67
68
|
* @public
|
|
68
69
|
*/
|
|
69
|
-
export type ServiceOutputTypes = AddChannelMemberCommandOutput | AddChannelMembersCommandOutput | CreateGroupChannelCommandOutput | CreateInboxTagCommandOutput | DeleteChannelCommandOutput | DeleteChannelMemberCommandOutput | DeleteInboxTagCommandOutput | DeleteMessageCommandOutput | DeleteMessageReactionCommandOutput | DescribeEventCommandOutput | GetActionTriggerResultCommandOutput | GetChannelCommandOutput | GetChannelMemberCommandOutput | GetDirectChannelIdCommandOutput | GetFilePresignedDownloadUrlCommandOutput | GetInboxStateCommandOutput | GetMessageCommandOutput | GetOrCreateDirectChannelCommandOutput | GetUploadedFileInfoCommandOutput | HideChannelCommandOutput | InviteCommandOutput | JoinChannelCommandOutput | LeaveChannelCommandOutput | ListChannelMembersCommandOutput | ListChannelsCommandOutput | ListInboxTaggedChannelsCommandOutput | ListInboxTagsCommandOutput | ListMessageReactionsCommandOutput | ListMessagesCommandOutput | ListPinnedMessagesCommandOutput | MarkReadCommandOutput | MarkUnreadCommandOutput | PartialUpdateChannelCommandOutput | PartialUpdateMessageCommandOutput | PinChannelCommandOutput | PinMessageCommandOutput | ScheduleExternalFlagAdjustmentJobCommandOutput | SendActionTriggerResultCommandOutput | SendGiphyCommandOutput | SendMessageCommandOutput | SendMessageReactionCommandOutput | SendTypingStartCommandOutput | SendTypingStopCommandOutput | ShowChannelCommandOutput | TagChannelCommandOutput | TriggerMessageActionCommandOutput | UnpinChannelCommandOutput | UnpinMessageCommandOutput | UntagChannelCommandOutput | UpdateChannelCommandOutput | UpdateInboxTagCommandOutput | UpdateMessageCommandOutput | UploadFileCommandOutput;
|
|
70
|
+
export type ServiceOutputTypes = AddChannelMemberCommandOutput | AddChannelMembersCommandOutput | CreateGroupChannelCommandOutput | CreateInboxTagCommandOutput | CreateKiteChannelCommandOutput | DeleteChannelCommandOutput | DeleteChannelMemberCommandOutput | DeleteInboxTagCommandOutput | DeleteMessageCommandOutput | DeleteMessageReactionCommandOutput | DescribeEventCommandOutput | GetActionTriggerResultCommandOutput | GetChannelCommandOutput | GetChannelMemberCommandOutput | GetDirectChannelIdCommandOutput | GetFilePresignedDownloadUrlCommandOutput | GetInboxStateCommandOutput | GetMessageCommandOutput | GetOrCreateDirectChannelCommandOutput | GetUploadedFileInfoCommandOutput | HideChannelCommandOutput | InviteCommandOutput | JoinChannelCommandOutput | LeaveChannelCommandOutput | ListChannelMembersCommandOutput | ListChannelsCommandOutput | ListInboxTaggedChannelsCommandOutput | ListInboxTagsCommandOutput | ListMessageReactionsCommandOutput | ListMessagesCommandOutput | ListPinnedMessagesCommandOutput | MarkReadCommandOutput | MarkUnreadCommandOutput | PartialUpdateChannelCommandOutput | PartialUpdateMessageCommandOutput | PinChannelCommandOutput | PinMessageCommandOutput | ScheduleExternalFlagAdjustmentJobCommandOutput | SendActionTriggerResultCommandOutput | SendGiphyCommandOutput | SendMessageCommandOutput | SendMessageReactionCommandOutput | SendTypingStartCommandOutput | SendTypingStopCommandOutput | ShowChannelCommandOutput | TagChannelCommandOutput | TriggerMessageActionCommandOutput | UnpinChannelCommandOutput | UnpinMessageCommandOutput | UntagChannelCommandOutput | UpdateChannelCommandOutput | UpdateInboxTagCommandOutput | UpdateMessageCommandOutput | UploadFileCommandOutput;
|
|
70
71
|
/**
|
|
71
72
|
* @public
|
|
72
73
|
*/
|
|
@@ -0,0 +1,326 @@
|
|
|
1
|
+
import { ConversationsClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../ConversationsClient";
|
|
2
|
+
import { CreateKiteChannelInput, CreateKiteChannelOutput } from "../models/models_0";
|
|
3
|
+
import { Command as $Command } from "@smithy/smithy-client";
|
|
4
|
+
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
5
|
+
/**
|
|
6
|
+
* @public
|
|
7
|
+
*/
|
|
8
|
+
export type { __MetadataBearer };
|
|
9
|
+
export { $Command };
|
|
10
|
+
/**
|
|
11
|
+
* @public
|
|
12
|
+
*
|
|
13
|
+
* The input for {@link CreateKiteChannelCommand}.
|
|
14
|
+
*/
|
|
15
|
+
export interface CreateKiteChannelCommandInput extends CreateKiteChannelInput {
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* @public
|
|
19
|
+
*
|
|
20
|
+
* The output of {@link CreateKiteChannelCommand}.
|
|
21
|
+
*/
|
|
22
|
+
export interface CreateKiteChannelCommandOutput extends CreateKiteChannelOutput, __MetadataBearer {
|
|
23
|
+
}
|
|
24
|
+
declare const CreateKiteChannelCommand_base: {
|
|
25
|
+
new (input: CreateKiteChannelCommandInput): import("@smithy/smithy-client").CommandImpl<CreateKiteChannelCommandInput, CreateKiteChannelCommandOutput, ConversationsClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
|
|
26
|
+
new (__0_0: CreateKiteChannelCommandInput): import("@smithy/smithy-client").CommandImpl<CreateKiteChannelCommandInput, CreateKiteChannelCommandOutput, ConversationsClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
|
|
27
|
+
getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions;
|
|
28
|
+
};
|
|
29
|
+
/**
|
|
30
|
+
* Creates a new kite channel with specified widget or email.
|
|
31
|
+
* @example
|
|
32
|
+
* Use a bare-bones client and the command you need to make an API call.
|
|
33
|
+
* ```javascript
|
|
34
|
+
* import { ConversationsClient, CreateKiteChannelCommand } from "@wildix/xbees-conversations-client"; // ES Modules import
|
|
35
|
+
* // const { ConversationsClient, CreateKiteChannelCommand } = require("@wildix/xbees-conversations-client"); // CommonJS import
|
|
36
|
+
* const client = new ConversationsClient(config);
|
|
37
|
+
* const input = { // CreateKiteChannelInput
|
|
38
|
+
* userId: "STRING_VALUE",
|
|
39
|
+
* channelId: "STRING_VALUE",
|
|
40
|
+
* targetId: "STRING_VALUE", // required
|
|
41
|
+
* targetRouteId: "STRING_VALUE",
|
|
42
|
+
* welcomeMessages: [ // WelcomeMessagesList
|
|
43
|
+
* { // WelcomeMessage
|
|
44
|
+
* text: "STRING_VALUE",
|
|
45
|
+
* elements: [ // ElementsList
|
|
46
|
+
* { // Element Union: only one key present
|
|
47
|
+
* actions: [ // ActionsElementsList
|
|
48
|
+
* { // ActionElement Union: only one key present
|
|
49
|
+
* button: { // ButtonElement
|
|
50
|
+
* text: "STRING_VALUE", // required
|
|
51
|
+
* variant: "contained" || "outlined",
|
|
52
|
+
* disabled: true || false,
|
|
53
|
+
* handler: { // ButtonHandler Union: only one key present
|
|
54
|
+
* link: { // ButtonLinkHandler
|
|
55
|
+
* url: "STRING_VALUE", // required
|
|
56
|
+
* },
|
|
57
|
+
* reply: { // ButtonReplyHandler
|
|
58
|
+
* text: "STRING_VALUE",
|
|
59
|
+
* },
|
|
60
|
+
* action: { // ButtonActionHandler
|
|
61
|
+
* id: "STRING_VALUE", // required
|
|
62
|
+
* },
|
|
63
|
+
* },
|
|
64
|
+
* },
|
|
65
|
+
* },
|
|
66
|
+
* ],
|
|
67
|
+
* },
|
|
68
|
+
* ],
|
|
69
|
+
* attachments: [ // MessageAttachmentList
|
|
70
|
+
* { // MessageAttachment
|
|
71
|
+
* id: "STRING_VALUE", // required
|
|
72
|
+
* fsId: "STRING_VALUE", // required
|
|
73
|
+
* mime: "STRING_VALUE",
|
|
74
|
+
* name: "STRING_VALUE", // required
|
|
75
|
+
* size: Number("int"), // required
|
|
76
|
+
* width: Number("int"),
|
|
77
|
+
* height: Number("int"),
|
|
78
|
+
* thumbnail: "STRING_VALUE",
|
|
79
|
+
* },
|
|
80
|
+
* ],
|
|
81
|
+
* quote: { // MessageQuote
|
|
82
|
+
* messageId: "STRING_VALUE", // required
|
|
83
|
+
* channelId: "STRING_VALUE", // required
|
|
84
|
+
* user: { // User
|
|
85
|
+
* id: "STRING_VALUE", // required
|
|
86
|
+
* name: "STRING_VALUE",
|
|
87
|
+
* email: "STRING_VALUE",
|
|
88
|
+
* phone: "STRING_VALUE",
|
|
89
|
+
* picture: "STRING_VALUE",
|
|
90
|
+
* locale: "STRING_VALUE",
|
|
91
|
+
* timeZone: "STRING_VALUE",
|
|
92
|
+
* company: "STRING_VALUE",
|
|
93
|
+
* bot: true || false,
|
|
94
|
+
* pbxDomain: "STRING_VALUE",
|
|
95
|
+
* pbxPort: "STRING_VALUE",
|
|
96
|
+
* pbxExtension: "STRING_VALUE",
|
|
97
|
+
* pbxSerial: "STRING_VALUE",
|
|
98
|
+
* pbxUserId: "STRING_VALUE",
|
|
99
|
+
* createdAt: "STRING_VALUE",
|
|
100
|
+
* updatedAt: "STRING_VALUE",
|
|
101
|
+
* },
|
|
102
|
+
* text: "STRING_VALUE",
|
|
103
|
+
* attachments: [
|
|
104
|
+
* {
|
|
105
|
+
* id: "STRING_VALUE", // required
|
|
106
|
+
* fsId: "STRING_VALUE", // required
|
|
107
|
+
* mime: "STRING_VALUE",
|
|
108
|
+
* name: "STRING_VALUE", // required
|
|
109
|
+
* size: Number("int"), // required
|
|
110
|
+
* width: Number("int"),
|
|
111
|
+
* height: Number("int"),
|
|
112
|
+
* thumbnail: "STRING_VALUE",
|
|
113
|
+
* },
|
|
114
|
+
* ],
|
|
115
|
+
* forward: { // MessageForward
|
|
116
|
+
* forwardCompany: "STRING_VALUE",
|
|
117
|
+
* forwardDate: "STRING_VALUE", // required
|
|
118
|
+
* forwardEmail: "STRING_VALUE",
|
|
119
|
+
* forwardName: "STRING_VALUE",
|
|
120
|
+
* messageId: "STRING_VALUE", // required
|
|
121
|
+
* channelId: "STRING_VALUE", // required
|
|
122
|
+
* },
|
|
123
|
+
* mentions: [ // UsersList
|
|
124
|
+
* {
|
|
125
|
+
* id: "STRING_VALUE", // required
|
|
126
|
+
* name: "STRING_VALUE",
|
|
127
|
+
* email: "STRING_VALUE",
|
|
128
|
+
* phone: "STRING_VALUE",
|
|
129
|
+
* picture: "STRING_VALUE",
|
|
130
|
+
* locale: "STRING_VALUE",
|
|
131
|
+
* timeZone: "STRING_VALUE",
|
|
132
|
+
* company: "STRING_VALUE",
|
|
133
|
+
* bot: true || false,
|
|
134
|
+
* pbxDomain: "STRING_VALUE",
|
|
135
|
+
* pbxPort: "STRING_VALUE",
|
|
136
|
+
* pbxExtension: "STRING_VALUE",
|
|
137
|
+
* pbxSerial: "STRING_VALUE",
|
|
138
|
+
* pbxUserId: "STRING_VALUE",
|
|
139
|
+
* createdAt: "STRING_VALUE",
|
|
140
|
+
* updatedAt: "STRING_VALUE",
|
|
141
|
+
* },
|
|
142
|
+
* ],
|
|
143
|
+
* giphy: { // MessageGiphy
|
|
144
|
+
* id: "STRING_VALUE", // required
|
|
145
|
+
* size: "STRING_VALUE", // required
|
|
146
|
+
* url: "STRING_VALUE", // required
|
|
147
|
+
* height: "STRING_VALUE", // required
|
|
148
|
+
* width: "STRING_VALUE", // required
|
|
149
|
+
* },
|
|
150
|
+
* createdAt: "STRING_VALUE", // required
|
|
151
|
+
* updatedAt: "STRING_VALUE",
|
|
152
|
+
* },
|
|
153
|
+
* forward: {
|
|
154
|
+
* forwardCompany: "STRING_VALUE",
|
|
155
|
+
* forwardDate: "STRING_VALUE", // required
|
|
156
|
+
* forwardEmail: "STRING_VALUE",
|
|
157
|
+
* forwardName: "STRING_VALUE",
|
|
158
|
+
* messageId: "STRING_VALUE", // required
|
|
159
|
+
* channelId: "STRING_VALUE", // required
|
|
160
|
+
* },
|
|
161
|
+
* messageId: "STRING_VALUE", // required
|
|
162
|
+
* mentions: [ // UsersIdList
|
|
163
|
+
* "STRING_VALUE",
|
|
164
|
+
* ],
|
|
165
|
+
* user: "<User>", // required
|
|
166
|
+
* },
|
|
167
|
+
* ],
|
|
168
|
+
* initialMessage: { // InitialMessage
|
|
169
|
+
* text: "STRING_VALUE",
|
|
170
|
+
* elements: [
|
|
171
|
+
* {// Union: only one key present
|
|
172
|
+
* actions: [
|
|
173
|
+
* {// Union: only one key present
|
|
174
|
+
* button: {
|
|
175
|
+
* text: "STRING_VALUE", // required
|
|
176
|
+
* variant: "contained" || "outlined",
|
|
177
|
+
* disabled: true || false,
|
|
178
|
+
* handler: {// Union: only one key present
|
|
179
|
+
* link: {
|
|
180
|
+
* url: "STRING_VALUE", // required
|
|
181
|
+
* },
|
|
182
|
+
* reply: {
|
|
183
|
+
* text: "STRING_VALUE",
|
|
184
|
+
* },
|
|
185
|
+
* action: {
|
|
186
|
+
* id: "STRING_VALUE", // required
|
|
187
|
+
* },
|
|
188
|
+
* },
|
|
189
|
+
* },
|
|
190
|
+
* },
|
|
191
|
+
* ],
|
|
192
|
+
* },
|
|
193
|
+
* ],
|
|
194
|
+
* attachments: "<MessageAttachmentList>",
|
|
195
|
+
* quote: {
|
|
196
|
+
* messageId: "STRING_VALUE", // required
|
|
197
|
+
* channelId: "STRING_VALUE", // required
|
|
198
|
+
* user: "<User>", // required
|
|
199
|
+
* text: "STRING_VALUE",
|
|
200
|
+
* attachments: "<MessageAttachmentList>",
|
|
201
|
+
* forward: {
|
|
202
|
+
* forwardCompany: "STRING_VALUE",
|
|
203
|
+
* forwardDate: "STRING_VALUE", // required
|
|
204
|
+
* forwardEmail: "STRING_VALUE",
|
|
205
|
+
* forwardName: "STRING_VALUE",
|
|
206
|
+
* messageId: "STRING_VALUE", // required
|
|
207
|
+
* channelId: "STRING_VALUE", // required
|
|
208
|
+
* },
|
|
209
|
+
* mentions: [
|
|
210
|
+
* "<User>",
|
|
211
|
+
* ],
|
|
212
|
+
* giphy: {
|
|
213
|
+
* id: "STRING_VALUE", // required
|
|
214
|
+
* size: "STRING_VALUE", // required
|
|
215
|
+
* url: "STRING_VALUE", // required
|
|
216
|
+
* height: "STRING_VALUE", // required
|
|
217
|
+
* width: "STRING_VALUE", // required
|
|
218
|
+
* },
|
|
219
|
+
* createdAt: "STRING_VALUE", // required
|
|
220
|
+
* updatedAt: "STRING_VALUE",
|
|
221
|
+
* },
|
|
222
|
+
* forward: "<MessageForward>",
|
|
223
|
+
* messageId: "STRING_VALUE", // required
|
|
224
|
+
* mentions: [
|
|
225
|
+
* "STRING_VALUE",
|
|
226
|
+
* ],
|
|
227
|
+
* },
|
|
228
|
+
* };
|
|
229
|
+
* const command = new CreateKiteChannelCommand(input);
|
|
230
|
+
* const response = await client.send(command);
|
|
231
|
+
* // { // CreateKiteChannelOutput
|
|
232
|
+
* // channel: { // Channel
|
|
233
|
+
* // subject: "STRING_VALUE",
|
|
234
|
+
* // description: "STRING_VALUE",
|
|
235
|
+
* // picture: "STRING_VALUE",
|
|
236
|
+
* // pictureColor: "STRING_VALUE",
|
|
237
|
+
* // access: "private" || "public",
|
|
238
|
+
* // company: "STRING_VALUE",
|
|
239
|
+
* // context: { // ChannelContext
|
|
240
|
+
* // source: "kite",
|
|
241
|
+
* // target: "STRING_VALUE",
|
|
242
|
+
* // events: [ // ChannelContextEventList
|
|
243
|
+
* // { // ChannelContextEvent
|
|
244
|
+
* // id: "STRING_VALUE",
|
|
245
|
+
* // owner: "STRING_VALUE",
|
|
246
|
+
* // start: "STRING_VALUE",
|
|
247
|
+
* // end: "STRING_VALUE",
|
|
248
|
+
* // summary: "STRING_VALUE",
|
|
249
|
+
* // attendees: [ // ChannelContextEventAttendeeList
|
|
250
|
+
* // { // ChannelContextEventAttendee
|
|
251
|
+
* // email: "STRING_VALUE", // required
|
|
252
|
+
* // name: "STRING_VALUE",
|
|
253
|
+
* // status: "accepted" || "tentative" || "declined" || "none", // required
|
|
254
|
+
* // },
|
|
255
|
+
* // ],
|
|
256
|
+
* // },
|
|
257
|
+
* // ],
|
|
258
|
+
* // },
|
|
259
|
+
* // kite: true || false,
|
|
260
|
+
* // kiteTarget: "STRING_VALUE",
|
|
261
|
+
* // kiteVariant: "STRING_VALUE",
|
|
262
|
+
* // kiteAssign: "STRING_VALUE",
|
|
263
|
+
* // kiteServiceName: "STRING_VALUE",
|
|
264
|
+
* // kiteDefaultSubject: "STRING_VALUE",
|
|
265
|
+
* // service: "STRING_VALUE",
|
|
266
|
+
* // serviceTitle: "STRING_VALUE",
|
|
267
|
+
* // serviceRecipient: "STRING_VALUE",
|
|
268
|
+
* // assignee: { // User
|
|
269
|
+
* // id: "STRING_VALUE", // required
|
|
270
|
+
* // name: "STRING_VALUE",
|
|
271
|
+
* // email: "STRING_VALUE",
|
|
272
|
+
* // phone: "STRING_VALUE",
|
|
273
|
+
* // picture: "STRING_VALUE",
|
|
274
|
+
* // locale: "STRING_VALUE",
|
|
275
|
+
* // timeZone: "STRING_VALUE",
|
|
276
|
+
* // company: "STRING_VALUE",
|
|
277
|
+
* // bot: true || false,
|
|
278
|
+
* // pbxDomain: "STRING_VALUE",
|
|
279
|
+
* // pbxPort: "STRING_VALUE",
|
|
280
|
+
* // pbxExtension: "STRING_VALUE",
|
|
281
|
+
* // pbxSerial: "STRING_VALUE",
|
|
282
|
+
* // pbxUserId: "STRING_VALUE",
|
|
283
|
+
* // createdAt: "STRING_VALUE",
|
|
284
|
+
* // updatedAt: "STRING_VALUE",
|
|
285
|
+
* // },
|
|
286
|
+
* // telephony: true || false,
|
|
287
|
+
* // sms: true || false,
|
|
288
|
+
* // mms: true || false,
|
|
289
|
+
* // whatsapp: true || false,
|
|
290
|
+
* // whatsappStatus: "24h_channel_closed",
|
|
291
|
+
* // broadcast: true || false,
|
|
292
|
+
* // external: true || false,
|
|
293
|
+
* // channelId: "STRING_VALUE", // required
|
|
294
|
+
* // channelType: "direct" || "group", // required
|
|
295
|
+
* // memberCount: Number("int"), // required
|
|
296
|
+
* // createdAt: "STRING_VALUE", // required
|
|
297
|
+
* // createdBy: "STRING_VALUE", // required
|
|
298
|
+
* // updatedAt: "STRING_VALUE",
|
|
299
|
+
* // },
|
|
300
|
+
* // };
|
|
301
|
+
*
|
|
302
|
+
* ```
|
|
303
|
+
*
|
|
304
|
+
* @param CreateKiteChannelCommandInput - {@link CreateKiteChannelCommandInput}
|
|
305
|
+
* @returns {@link CreateKiteChannelCommandOutput}
|
|
306
|
+
* @see {@link CreateKiteChannelCommandInput} for command's `input` shape.
|
|
307
|
+
* @see {@link CreateKiteChannelCommandOutput} for command's `response` shape.
|
|
308
|
+
* @see {@link ConversationsClientResolvedConfig | config} for ConversationsClient's `config` shape.
|
|
309
|
+
*
|
|
310
|
+
* @throws {@link TargetNotFoundException} (client fault)
|
|
311
|
+
*
|
|
312
|
+
* @throws {@link TargetNotEligibleException} (client fault)
|
|
313
|
+
*
|
|
314
|
+
* @throws {@link ValidationException} (client fault)
|
|
315
|
+
*
|
|
316
|
+
* @throws {@link ForbiddenException} (client fault)
|
|
317
|
+
*
|
|
318
|
+
* @throws {@link RateLimitExceededException} (client fault)
|
|
319
|
+
*
|
|
320
|
+
* @throws {@link ConversationsServiceException}
|
|
321
|
+
* <p>Base exception class for all service exceptions from Conversations service.</p>
|
|
322
|
+
*
|
|
323
|
+
* @public
|
|
324
|
+
*/
|
|
325
|
+
export declare class CreateKiteChannelCommand extends CreateKiteChannelCommand_base {
|
|
326
|
+
}
|
|
@@ -152,12 +152,12 @@ declare const SendMessageCommand_base: {
|
|
|
152
152
|
* messageId: "STRING_VALUE", // required
|
|
153
153
|
* channelId: "STRING_VALUE", // required
|
|
154
154
|
* },
|
|
155
|
-
* channelId: "STRING_VALUE", // required
|
|
156
|
-
* userId: "STRING_VALUE",
|
|
157
155
|
* messageId: "STRING_VALUE",
|
|
158
156
|
* mentions: [ // UsersIdList
|
|
159
157
|
* "STRING_VALUE",
|
|
160
158
|
* ],
|
|
159
|
+
* channelId: "STRING_VALUE", // required
|
|
160
|
+
* userId: "STRING_VALUE",
|
|
161
161
|
* };
|
|
162
162
|
* const command = new SendMessageCommand(input);
|
|
163
163
|
* const response = await client.send(command);
|
|
@@ -152,12 +152,12 @@ declare const UpdateMessageCommand_base: {
|
|
|
152
152
|
* messageId: "STRING_VALUE", // required
|
|
153
153
|
* channelId: "STRING_VALUE", // required
|
|
154
154
|
* },
|
|
155
|
-
* channelId: "STRING_VALUE", // required
|
|
156
155
|
* messageId: "STRING_VALUE", // required
|
|
157
|
-
* userId: "STRING_VALUE",
|
|
158
156
|
* mentions: [ // UsersIdList
|
|
159
157
|
* "STRING_VALUE",
|
|
160
158
|
* ],
|
|
159
|
+
* channelId: "STRING_VALUE", // required
|
|
160
|
+
* userId: "STRING_VALUE",
|
|
161
161
|
* silent: true || false,
|
|
162
162
|
* };
|
|
163
163
|
* const command = new UpdateMessageCommand(input);
|
|
@@ -2,6 +2,7 @@ export * from "./AddChannelMemberCommand";
|
|
|
2
2
|
export * from "./AddChannelMembersCommand";
|
|
3
3
|
export * from "./CreateGroupChannelCommand";
|
|
4
4
|
export * from "./CreateInboxTagCommand";
|
|
5
|
+
export * from "./CreateKiteChannelCommand";
|
|
5
6
|
export * from "./DeleteChannelCommand";
|
|
6
7
|
export * from "./DeleteChannelMemberCommand";
|
|
7
8
|
export * from "./DeleteInboxTagCommand";
|
|
@@ -613,6 +613,200 @@ export declare class TagsLimitReachedException extends __BaseException {
|
|
|
613
613
|
*/
|
|
614
614
|
constructor(opts: __ExceptionOptionType<TagsLimitReachedException, __BaseException>);
|
|
615
615
|
}
|
|
616
|
+
/**
|
|
617
|
+
* @public
|
|
618
|
+
*/
|
|
619
|
+
export interface MessageAttachment {
|
|
620
|
+
id: string;
|
|
621
|
+
/**
|
|
622
|
+
* This *is* documentation about the field. Describe here what fsId and how to get it.
|
|
623
|
+
* @public
|
|
624
|
+
*/
|
|
625
|
+
fsId: string;
|
|
626
|
+
mime?: string;
|
|
627
|
+
name: string;
|
|
628
|
+
size: number;
|
|
629
|
+
width?: number;
|
|
630
|
+
height?: number;
|
|
631
|
+
thumbnail?: string;
|
|
632
|
+
}
|
|
633
|
+
/**
|
|
634
|
+
* @public
|
|
635
|
+
*/
|
|
636
|
+
export type Element = Element.ActionsMember | Element.$UnknownMember;
|
|
637
|
+
/**
|
|
638
|
+
* @public
|
|
639
|
+
*/
|
|
640
|
+
export declare namespace Element {
|
|
641
|
+
interface ActionsMember {
|
|
642
|
+
actions: (ActionElement)[];
|
|
643
|
+
$unknown?: never;
|
|
644
|
+
}
|
|
645
|
+
/**
|
|
646
|
+
* @public
|
|
647
|
+
*/
|
|
648
|
+
interface $UnknownMember {
|
|
649
|
+
actions?: never;
|
|
650
|
+
$unknown: [string, any];
|
|
651
|
+
}
|
|
652
|
+
interface Visitor<T> {
|
|
653
|
+
actions: (value: (ActionElement)[]) => T;
|
|
654
|
+
_: (name: string, value: any) => T;
|
|
655
|
+
}
|
|
656
|
+
const visit: <T>(value: Element, visitor: Visitor<T>) => T;
|
|
657
|
+
}
|
|
658
|
+
/**
|
|
659
|
+
* @public
|
|
660
|
+
*/
|
|
661
|
+
export interface MessageForward {
|
|
662
|
+
forwardCompany?: string;
|
|
663
|
+
forwardDate: string;
|
|
664
|
+
forwardEmail?: string;
|
|
665
|
+
forwardName?: string;
|
|
666
|
+
messageId: string;
|
|
667
|
+
channelId: string;
|
|
668
|
+
}
|
|
669
|
+
/**
|
|
670
|
+
* @public
|
|
671
|
+
*/
|
|
672
|
+
export interface MessageGiphy {
|
|
673
|
+
id: string;
|
|
674
|
+
size: string;
|
|
675
|
+
url: string;
|
|
676
|
+
height: string;
|
|
677
|
+
width: string;
|
|
678
|
+
}
|
|
679
|
+
/**
|
|
680
|
+
* @public
|
|
681
|
+
*/
|
|
682
|
+
export interface MessageQuote {
|
|
683
|
+
messageId: string;
|
|
684
|
+
channelId: string;
|
|
685
|
+
user: User;
|
|
686
|
+
text?: string;
|
|
687
|
+
attachments?: (MessageAttachment)[];
|
|
688
|
+
forward?: MessageForward;
|
|
689
|
+
mentions?: (User)[];
|
|
690
|
+
giphy?: MessageGiphy;
|
|
691
|
+
createdAt: string;
|
|
692
|
+
updatedAt?: string;
|
|
693
|
+
}
|
|
694
|
+
/**
|
|
695
|
+
* @public
|
|
696
|
+
*/
|
|
697
|
+
export interface InitialMessage {
|
|
698
|
+
text?: string;
|
|
699
|
+
elements?: (Element)[];
|
|
700
|
+
attachments?: (MessageAttachment)[];
|
|
701
|
+
quote?: MessageQuote;
|
|
702
|
+
forward?: MessageForward;
|
|
703
|
+
/**
|
|
704
|
+
* The unique identifier of the message. If not provided, an ID will be auto-generated.
|
|
705
|
+
* @public
|
|
706
|
+
*/
|
|
707
|
+
messageId: string;
|
|
708
|
+
/**
|
|
709
|
+
* A list of user IDs mentioned in the message.
|
|
710
|
+
* @public
|
|
711
|
+
*/
|
|
712
|
+
mentions?: (string)[];
|
|
713
|
+
}
|
|
714
|
+
/**
|
|
715
|
+
* @public
|
|
716
|
+
*/
|
|
717
|
+
export interface WelcomeMessage {
|
|
718
|
+
text?: string;
|
|
719
|
+
elements?: (Element)[];
|
|
720
|
+
attachments?: (MessageAttachment)[];
|
|
721
|
+
quote?: MessageQuote;
|
|
722
|
+
forward?: MessageForward;
|
|
723
|
+
/**
|
|
724
|
+
* The unique identifier of the message. If not provided, an ID will be auto-generated.
|
|
725
|
+
* @public
|
|
726
|
+
*/
|
|
727
|
+
messageId: string;
|
|
728
|
+
/**
|
|
729
|
+
* A list of user IDs mentioned in the message.
|
|
730
|
+
* @public
|
|
731
|
+
*/
|
|
732
|
+
mentions?: (string)[];
|
|
733
|
+
user: User;
|
|
734
|
+
}
|
|
735
|
+
/**
|
|
736
|
+
* @public
|
|
737
|
+
*/
|
|
738
|
+
export interface CreateKiteChannelInput {
|
|
739
|
+
/**
|
|
740
|
+
* The unique identifier of the user when a service token is used.
|
|
741
|
+
* @public
|
|
742
|
+
*/
|
|
743
|
+
userId?: string;
|
|
744
|
+
/**
|
|
745
|
+
* The unique identifier for the new group channel. If not provided, the system will generate one.
|
|
746
|
+
* @public
|
|
747
|
+
*/
|
|
748
|
+
channelId?: string;
|
|
749
|
+
/**
|
|
750
|
+
* The unique identifier of the Kite widget or email of the agent (example: 36cv69ao or vadim.ruban@wildix.com).
|
|
751
|
+
* @public
|
|
752
|
+
*/
|
|
753
|
+
targetId: string;
|
|
754
|
+
/**
|
|
755
|
+
* The unique identifier of the route for time-based configuration.
|
|
756
|
+
* @public
|
|
757
|
+
*/
|
|
758
|
+
targetRouteId?: string;
|
|
759
|
+
/**
|
|
760
|
+
* A list of welcome messages is created during channel creation to preserve the same state as the client has on the interface. If welcomeMessages or initialMessage are not specified, the system will generate a 'conversation was created' system message.
|
|
761
|
+
* @public
|
|
762
|
+
*/
|
|
763
|
+
welcomeMessages?: (WelcomeMessage)[];
|
|
764
|
+
/**
|
|
765
|
+
* A message to be added to the conversation for the user. If welcomeMessages or initialMessage are not specified, the system will generate a 'conversation was created' system message.
|
|
766
|
+
* @public
|
|
767
|
+
*/
|
|
768
|
+
initialMessage?: InitialMessage;
|
|
769
|
+
}
|
|
770
|
+
/**
|
|
771
|
+
* @public
|
|
772
|
+
*/
|
|
773
|
+
export interface CreateKiteChannelOutput {
|
|
774
|
+
channel: Channel;
|
|
775
|
+
}
|
|
776
|
+
/**
|
|
777
|
+
* @public
|
|
778
|
+
* @enum
|
|
779
|
+
*/
|
|
780
|
+
export declare const TargetNotEligibleReason: {
|
|
781
|
+
readonly NO_LICENSE: "no_license";
|
|
782
|
+
};
|
|
783
|
+
/**
|
|
784
|
+
* @public
|
|
785
|
+
*/
|
|
786
|
+
export type TargetNotEligibleReason = typeof TargetNotEligibleReason[keyof typeof TargetNotEligibleReason];
|
|
787
|
+
/**
|
|
788
|
+
* @public
|
|
789
|
+
*/
|
|
790
|
+
export declare class TargetNotEligibleException extends __BaseException {
|
|
791
|
+
readonly name: "TargetNotEligibleException";
|
|
792
|
+
readonly $fault: "client";
|
|
793
|
+
reason?: TargetNotEligibleReason;
|
|
794
|
+
/**
|
|
795
|
+
* @internal
|
|
796
|
+
*/
|
|
797
|
+
constructor(opts: __ExceptionOptionType<TargetNotEligibleException, __BaseException>);
|
|
798
|
+
}
|
|
799
|
+
/**
|
|
800
|
+
* @public
|
|
801
|
+
*/
|
|
802
|
+
export declare class TargetNotFoundException extends __BaseException {
|
|
803
|
+
readonly name: "TargetNotFoundException";
|
|
804
|
+
readonly $fault: "client";
|
|
805
|
+
/**
|
|
806
|
+
* @internal
|
|
807
|
+
*/
|
|
808
|
+
constructor(opts: __ExceptionOptionType<TargetNotFoundException, __BaseException>);
|
|
809
|
+
}
|
|
616
810
|
/**
|
|
617
811
|
* @public
|
|
618
812
|
*/
|
|
@@ -779,69 +973,6 @@ export interface DeleteMessageReactionOutput {
|
|
|
779
973
|
*/
|
|
780
974
|
export interface DescribeEventInput {
|
|
781
975
|
}
|
|
782
|
-
/**
|
|
783
|
-
* @public
|
|
784
|
-
*/
|
|
785
|
-
export interface MessageAttachment {
|
|
786
|
-
id: string;
|
|
787
|
-
/**
|
|
788
|
-
* This *is* documentation about the field. Describe here what fsId and how to get it.
|
|
789
|
-
* @public
|
|
790
|
-
*/
|
|
791
|
-
fsId: string;
|
|
792
|
-
mime?: string;
|
|
793
|
-
name: string;
|
|
794
|
-
size: number;
|
|
795
|
-
width?: number;
|
|
796
|
-
height?: number;
|
|
797
|
-
thumbnail?: string;
|
|
798
|
-
}
|
|
799
|
-
/**
|
|
800
|
-
* @public
|
|
801
|
-
*/
|
|
802
|
-
export type Element = Element.ActionsMember | Element.$UnknownMember;
|
|
803
|
-
/**
|
|
804
|
-
* @public
|
|
805
|
-
*/
|
|
806
|
-
export declare namespace Element {
|
|
807
|
-
interface ActionsMember {
|
|
808
|
-
actions: (ActionElement)[];
|
|
809
|
-
$unknown?: never;
|
|
810
|
-
}
|
|
811
|
-
/**
|
|
812
|
-
* @public
|
|
813
|
-
*/
|
|
814
|
-
interface $UnknownMember {
|
|
815
|
-
actions?: never;
|
|
816
|
-
$unknown: [string, any];
|
|
817
|
-
}
|
|
818
|
-
interface Visitor<T> {
|
|
819
|
-
actions: (value: (ActionElement)[]) => T;
|
|
820
|
-
_: (name: string, value: any) => T;
|
|
821
|
-
}
|
|
822
|
-
const visit: <T>(value: Element, visitor: Visitor<T>) => T;
|
|
823
|
-
}
|
|
824
|
-
/**
|
|
825
|
-
* @public
|
|
826
|
-
*/
|
|
827
|
-
export interface MessageForward {
|
|
828
|
-
forwardCompany?: string;
|
|
829
|
-
forwardDate: string;
|
|
830
|
-
forwardEmail?: string;
|
|
831
|
-
forwardName?: string;
|
|
832
|
-
messageId: string;
|
|
833
|
-
channelId: string;
|
|
834
|
-
}
|
|
835
|
-
/**
|
|
836
|
-
* @public
|
|
837
|
-
*/
|
|
838
|
-
export interface MessageGiphy {
|
|
839
|
-
id: string;
|
|
840
|
-
size: string;
|
|
841
|
-
url: string;
|
|
842
|
-
height: string;
|
|
843
|
-
width: string;
|
|
844
|
-
}
|
|
845
976
|
/**
|
|
846
977
|
* @public
|
|
847
978
|
*/
|
|
@@ -851,21 +982,6 @@ export interface Reaction {
|
|
|
851
982
|
messageId?: string;
|
|
852
983
|
user?: User;
|
|
853
984
|
}
|
|
854
|
-
/**
|
|
855
|
-
* @public
|
|
856
|
-
*/
|
|
857
|
-
export interface MessageQuote {
|
|
858
|
-
messageId: string;
|
|
859
|
-
channelId: string;
|
|
860
|
-
user: User;
|
|
861
|
-
text?: string;
|
|
862
|
-
attachments?: (MessageAttachment)[];
|
|
863
|
-
forward?: MessageForward;
|
|
864
|
-
mentions?: (User)[];
|
|
865
|
-
giphy?: MessageGiphy;
|
|
866
|
-
createdAt: string;
|
|
867
|
-
updatedAt?: string;
|
|
868
|
-
}
|
|
869
985
|
/**
|
|
870
986
|
* @public
|
|
871
987
|
* @enum
|
|
@@ -1543,7 +1659,7 @@ export interface ListChannelsInput {
|
|
|
1543
1659
|
*/
|
|
1544
1660
|
userId?: string;
|
|
1545
1661
|
/**
|
|
1546
|
-
* The maximum number of channels to return. The value must be between 1 and
|
|
1662
|
+
* The maximum number of channels to return. The value must be between 1 and 30.
|
|
1547
1663
|
* @public
|
|
1548
1664
|
*/
|
|
1549
1665
|
limit?: number;
|
|
@@ -2082,25 +2198,25 @@ export interface SendMessageInput {
|
|
|
2082
2198
|
quote?: MessageQuote;
|
|
2083
2199
|
forward?: MessageForward;
|
|
2084
2200
|
/**
|
|
2085
|
-
* The unique identifier of the
|
|
2201
|
+
* The unique identifier of the message. If not provided, an ID will be auto-generated.
|
|
2086
2202
|
* @public
|
|
2087
2203
|
*/
|
|
2088
|
-
|
|
2204
|
+
messageId?: string;
|
|
2089
2205
|
/**
|
|
2090
|
-
*
|
|
2206
|
+
* A list of user IDs mentioned in the message.
|
|
2091
2207
|
* @public
|
|
2092
2208
|
*/
|
|
2093
|
-
|
|
2209
|
+
mentions?: (string)[];
|
|
2094
2210
|
/**
|
|
2095
|
-
* The unique identifier of the
|
|
2211
|
+
* The unique identifier of the channel to which the message is sent.
|
|
2096
2212
|
* @public
|
|
2097
2213
|
*/
|
|
2098
|
-
|
|
2214
|
+
channelId: string;
|
|
2099
2215
|
/**
|
|
2100
|
-
*
|
|
2216
|
+
* The unique identifier of the user when a service token is used.
|
|
2101
2217
|
* @public
|
|
2102
2218
|
*/
|
|
2103
|
-
|
|
2219
|
+
userId?: string;
|
|
2104
2220
|
}
|
|
2105
2221
|
/**
|
|
2106
2222
|
* @public
|
|
@@ -2444,25 +2560,25 @@ export interface UpdateMessageInput {
|
|
|
2444
2560
|
quote?: MessageQuote;
|
|
2445
2561
|
forward?: MessageForward;
|
|
2446
2562
|
/**
|
|
2447
|
-
* The unique identifier of the
|
|
2563
|
+
* The unique identifier of the message to update.
|
|
2448
2564
|
* @public
|
|
2449
2565
|
*/
|
|
2450
|
-
|
|
2566
|
+
messageId: string;
|
|
2451
2567
|
/**
|
|
2452
|
-
*
|
|
2568
|
+
* A list of user IDs mentioned in the message.
|
|
2453
2569
|
* @public
|
|
2454
2570
|
*/
|
|
2455
|
-
|
|
2571
|
+
mentions?: (string)[];
|
|
2456
2572
|
/**
|
|
2457
|
-
* The unique identifier of the
|
|
2573
|
+
* The unique identifier of the channel containing the message.
|
|
2458
2574
|
* @public
|
|
2459
2575
|
*/
|
|
2460
|
-
|
|
2576
|
+
channelId: string;
|
|
2461
2577
|
/**
|
|
2462
|
-
*
|
|
2578
|
+
* The unique identifier of the user when a service token is used.
|
|
2463
2579
|
* @public
|
|
2464
2580
|
*/
|
|
2465
|
-
|
|
2581
|
+
userId?: string;
|
|
2466
2582
|
/**
|
|
2467
2583
|
* Set to true to suppress the updated indicator. Defaults to false.
|
|
2468
2584
|
* @public
|
|
@@ -2,6 +2,7 @@ import { AddChannelMemberCommandInput, AddChannelMemberCommandOutput } from "../
|
|
|
2
2
|
import { AddChannelMembersCommandInput, AddChannelMembersCommandOutput } from "../commands/AddChannelMembersCommand";
|
|
3
3
|
import { CreateGroupChannelCommandInput, CreateGroupChannelCommandOutput } from "../commands/CreateGroupChannelCommand";
|
|
4
4
|
import { CreateInboxTagCommandInput, CreateInboxTagCommandOutput } from "../commands/CreateInboxTagCommand";
|
|
5
|
+
import { CreateKiteChannelCommandInput, CreateKiteChannelCommandOutput } from "../commands/CreateKiteChannelCommand";
|
|
5
6
|
import { DeleteChannelCommandInput, DeleteChannelCommandOutput } from "../commands/DeleteChannelCommand";
|
|
6
7
|
import { DeleteChannelMemberCommandInput, DeleteChannelMemberCommandOutput } from "../commands/DeleteChannelMemberCommand";
|
|
7
8
|
import { DeleteInboxTagCommandInput, DeleteInboxTagCommandOutput } from "../commands/DeleteInboxTagCommand";
|
|
@@ -69,6 +70,10 @@ export declare const se_CreateGroupChannelCommand: (input: CreateGroupChannelCom
|
|
|
69
70
|
* serializeAws_restJson1CreateInboxTagCommand
|
|
70
71
|
*/
|
|
71
72
|
export declare const se_CreateInboxTagCommand: (input: CreateInboxTagCommandInput, context: __SerdeContext) => Promise<__HttpRequest>;
|
|
73
|
+
/**
|
|
74
|
+
* serializeAws_restJson1CreateKiteChannelCommand
|
|
75
|
+
*/
|
|
76
|
+
export declare const se_CreateKiteChannelCommand: (input: CreateKiteChannelCommandInput, context: __SerdeContext) => Promise<__HttpRequest>;
|
|
72
77
|
/**
|
|
73
78
|
* serializeAws_restJson1DeleteChannelCommand
|
|
74
79
|
*/
|
|
@@ -281,6 +286,10 @@ export declare const de_CreateGroupChannelCommand: (output: __HttpResponse, cont
|
|
|
281
286
|
* deserializeAws_restJson1CreateInboxTagCommand
|
|
282
287
|
*/
|
|
283
288
|
export declare const de_CreateInboxTagCommand: (output: __HttpResponse, context: __SerdeContext) => Promise<CreateInboxTagCommandOutput>;
|
|
289
|
+
/**
|
|
290
|
+
* deserializeAws_restJson1CreateKiteChannelCommand
|
|
291
|
+
*/
|
|
292
|
+
export declare const de_CreateKiteChannelCommand: (output: __HttpResponse, context: __SerdeContext) => Promise<CreateKiteChannelCommandOutput>;
|
|
284
293
|
/**
|
|
285
294
|
* deserializeAws_restJson1DeleteChannelCommand
|
|
286
295
|
*/
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wildix/xbees-conversations-client",
|
|
3
3
|
"description": "@wildix/xbees-conversations-client client",
|
|
4
|
-
"version": "1.1.
|
|
4
|
+
"version": "1.1.3",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
|
|
7
7
|
"build:cjs": "tsc -p tsconfig.cjs.json",
|
|
@@ -76,4 +76,4 @@
|
|
|
76
76
|
"react-native": {
|
|
77
77
|
"./dist-es/runtimeConfig": "./dist-es/runtimeConfig.native"
|
|
78
78
|
}
|
|
79
|
-
}
|
|
79
|
+
}
|