@wildix/xbees-conversations-client 1.1.19 → 1.1.20
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/SendSystemMessageCommand.js +21 -0
- package/dist-cjs/commands/index.js +1 -0
- package/dist-cjs/models/models_0.js +9 -1
- package/dist-cjs/protocols/Aws_restJson1.js +35 -2
- package/dist-es/Conversations.js +2 -0
- package/dist-es/commands/SendSystemMessageCommand.js +17 -0
- package/dist-es/commands/index.js +1 -0
- package/dist-es/models/models_0.js +8 -0
- package/dist-es/protocols/Aws_restJson1.js +31 -0
- package/dist-types/Conversations.d.ts +7 -0
- package/dist-types/ConversationsClient.d.ts +3 -2
- package/dist-types/commands/SendSystemMessageCommand.d.ts +247 -0
- package/dist-types/commands/index.d.ts +1 -0
- package/dist-types/models/models_0.d.ts +56 -0
- package/dist-types/protocols/Aws_restJson1.d.ts +9 -0
- package/package.json +2 -2
|
@@ -54,6 +54,7 @@ const SendActionTriggerResultCommand_1 = require("./commands/SendActionTriggerRe
|
|
|
54
54
|
const SendGiphyCommand_1 = require("./commands/SendGiphyCommand");
|
|
55
55
|
const SendMessageCommand_1 = require("./commands/SendMessageCommand");
|
|
56
56
|
const SendMessageReactionCommand_1 = require("./commands/SendMessageReactionCommand");
|
|
57
|
+
const SendSystemMessageCommand_1 = require("./commands/SendSystemMessageCommand");
|
|
57
58
|
const SendTypingStartCommand_1 = require("./commands/SendTypingStartCommand");
|
|
58
59
|
const SendTypingStopCommand_1 = require("./commands/SendTypingStopCommand");
|
|
59
60
|
const ShowChannelCommand_1 = require("./commands/ShowChannelCommand");
|
|
@@ -120,6 +121,7 @@ const commands = {
|
|
|
120
121
|
SendGiphyCommand: SendGiphyCommand_1.SendGiphyCommand,
|
|
121
122
|
SendMessageCommand: SendMessageCommand_1.SendMessageCommand,
|
|
122
123
|
SendMessageReactionCommand: SendMessageReactionCommand_1.SendMessageReactionCommand,
|
|
124
|
+
SendSystemMessageCommand: SendSystemMessageCommand_1.SendSystemMessageCommand,
|
|
123
125
|
SendTypingStartCommand: SendTypingStartCommand_1.SendTypingStartCommand,
|
|
124
126
|
SendTypingStopCommand: SendTypingStopCommand_1.SendTypingStopCommand,
|
|
125
127
|
ShowChannelCommand: ShowChannelCommand_1.ShowChannelCommand,
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SendSystemMessageCommand = 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 SendSystemMessageCommand 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", "SendSystemMessage", {})
|
|
15
|
+
.n("ConversationsClient", "SendSystemMessageCommand")
|
|
16
|
+
.f(void 0, void 0)
|
|
17
|
+
.ser(Aws_restJson1_1.se_SendSystemMessageCommand)
|
|
18
|
+
.de(Aws_restJson1_1.de_SendSystemMessageCommand)
|
|
19
|
+
.build() {
|
|
20
|
+
}
|
|
21
|
+
exports.SendSystemMessageCommand = SendSystemMessageCommand;
|
|
@@ -53,6 +53,7 @@ tslib_1.__exportStar(require("./SendActionTriggerResultCommand"), exports);
|
|
|
53
53
|
tslib_1.__exportStar(require("./SendGiphyCommand"), exports);
|
|
54
54
|
tslib_1.__exportStar(require("./SendMessageCommand"), exports);
|
|
55
55
|
tslib_1.__exportStar(require("./SendMessageReactionCommand"), exports);
|
|
56
|
+
tslib_1.__exportStar(require("./SendSystemMessageCommand"), exports);
|
|
56
57
|
tslib_1.__exportStar(require("./SendTypingStartCommand"), exports);
|
|
57
58
|
tslib_1.__exportStar(require("./SendTypingStopCommand"), exports);
|
|
58
59
|
tslib_1.__exportStar(require("./ShowChannelCommand"), 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.MessageType = exports.ReactionType = exports.MessageNotFoundException = exports.MemberNotFoundException = exports.TargetNotFoundException = exports.TargetNotEligibleException = exports.TargetNotEligibleReason = exports.MessageWhatsAppStatus = exports.MessageSmsStatus = exports.Element = exports.TagsLimitReachedException = exports.ChannelAlreadyExistException = exports.ChannelWhatsAppStatus = exports.ChannelContextSource = exports.ChannelContextEventAttendeeStatus = exports.ChannelAccess = exports.AssignChannelVariant = exports.AssignChannelServiceRequest = exports.AssignChannelAssigneeRequest = 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;
|
|
3
|
+
exports.MessageActionNotFoundException = exports.TaggedChannelsLimitReachedException = exports.SystemMessage = exports.ConversationsServiceException = exports.PinnedChannelsLimitReachedException = exports.MessageUnsetFields = exports.GroupChannelUnsetOptions = exports.MarkUnreadChannelsLimitReachedException = exports.TagNotFoundException = exports.TriggerNotFoundException = exports.WebhookEventType = exports.MessageType = exports.ReactionType = exports.MessageNotFoundException = exports.MemberNotFoundException = exports.TargetNotFoundException = exports.TargetNotEligibleException = exports.TargetNotEligibleReason = exports.MessageWhatsAppStatus = exports.MessageSmsStatus = exports.Element = exports.TagsLimitReachedException = exports.ChannelAlreadyExistException = exports.ChannelWhatsAppStatus = exports.ChannelContextSource = exports.ChannelContextEventAttendeeStatus = exports.ChannelAccess = exports.AssignChannelVariant = exports.AssignChannelServiceRequest = exports.AssignChannelAssigneeRequest = 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
|
name = "ValidationException";
|
|
@@ -389,6 +389,14 @@ class ConversationsServiceException extends ConversationsServiceException_1.Conv
|
|
|
389
389
|
}
|
|
390
390
|
}
|
|
391
391
|
exports.ConversationsServiceException = ConversationsServiceException;
|
|
392
|
+
var SystemMessage;
|
|
393
|
+
(function (SystemMessage) {
|
|
394
|
+
SystemMessage.visit = (value, visitor) => {
|
|
395
|
+
if (value.whatsAppClosed !== undefined)
|
|
396
|
+
return visitor.whatsAppClosed(value.whatsAppClosed);
|
|
397
|
+
return visitor._(value.$unknown[0], value.$unknown[1]);
|
|
398
|
+
};
|
|
399
|
+
})(SystemMessage || (exports.SystemMessage = SystemMessage = {}));
|
|
392
400
|
class TaggedChannelsLimitReachedException extends ConversationsServiceException_1.ConversationsServiceException {
|
|
393
401
|
name = "TaggedChannelsLimitReachedException";
|
|
394
402
|
$fault = "client";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.se_SendGiphyCommand = exports.se_SendActionTriggerResultCommand = exports.se_ScheduleExternalFlagAdjustmentJobCommand = exports.se_QueryChannelsCommand = 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_ListChannelMembersReadStatusCommand = exports.se_ListChannelMembersCommand = exports.se_LeaveChannelCommand = exports.se_JoinChannelCommand = exports.se_InviteCommand = exports.se_HideChannelCommand = exports.se_GetWhatsAppChannelIdCommand = exports.se_GetUploadedFileInfoCommand = exports.se_GetTokenCommand = exports.se_GetTelephonyChannelIdCommand = exports.se_GetSmsChannelIdCommand = exports.se_GetOrCreateWhatsAppChannelCommand = exports.se_GetOrCreateTelephonyChannelCommand = exports.se_GetOrCreateSmsChannelCommand = 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_AssignChannelCommand = exports.se_AddChannelMembersCommand = exports.se_AddChannelMemberCommand = void 0;
|
|
4
|
-
exports.
|
|
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 = 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_QueryChannelsCommand = 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 = void 0;
|
|
4
|
+
exports.de_ListChannelsCommand = exports.de_ListChannelMembersReadStatusCommand = exports.de_ListChannelMembersCommand = exports.de_LeaveChannelCommand = exports.de_JoinChannelCommand = exports.de_InviteCommand = exports.de_HideChannelCommand = exports.de_GetWhatsAppChannelIdCommand = exports.de_GetUploadedFileInfoCommand = exports.de_GetTokenCommand = exports.de_GetTelephonyChannelIdCommand = exports.de_GetSmsChannelIdCommand = exports.de_GetOrCreateWhatsAppChannelCommand = exports.de_GetOrCreateTelephonyChannelCommand = exports.de_GetOrCreateSmsChannelCommand = 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_AssignChannelCommand = exports.de_AddChannelMembersCommand = exports.de_AddChannelMemberCommand = exports.se_UploadFileCommand = exports.se_UpdateMessageCommand = exports.se_UpdateInboxTagCommand = exports.se_UpdateChannelCommand = 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_SendSystemMessageCommand = exports.se_SendMessageReactionCommand = exports.se_SendMessageCommand = 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 = exports.de_TagChannelCommand = exports.de_ShowChannelCommand = exports.de_SendTypingStopCommand = exports.de_SendTypingStartCommand = exports.de_SendSystemMessageCommand = exports.de_SendMessageReactionCommand = exports.de_SendMessageCommand = exports.de_SendGiphyCommand = exports.de_SendActionTriggerResultCommand = exports.de_ScheduleExternalFlagAdjustmentJobCommand = exports.de_QueryChannelsCommand = 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 = 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("@aws-sdk/core");
|
|
@@ -998,6 +998,24 @@ const se_SendMessageReactionCommand = async (input, context) => {
|
|
|
998
998
|
return b.build();
|
|
999
999
|
};
|
|
1000
1000
|
exports.se_SendMessageReactionCommand = se_SendMessageReactionCommand;
|
|
1001
|
+
const se_SendSystemMessageCommand = async (input, context) => {
|
|
1002
|
+
const b = (0, core_2.requestBuilder)(input, context);
|
|
1003
|
+
const headers = {
|
|
1004
|
+
'content-type': 'application/json',
|
|
1005
|
+
};
|
|
1006
|
+
b.bp("/v2/conversations/channels/{channelId}/system-messages");
|
|
1007
|
+
b.p('channelId', () => input.channelId, '{channelId}', false);
|
|
1008
|
+
let body;
|
|
1009
|
+
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
1010
|
+
'message': _ => (0, smithy_client_1._json)(_),
|
|
1011
|
+
'userId': [],
|
|
1012
|
+
}));
|
|
1013
|
+
b.m("POST")
|
|
1014
|
+
.h(headers)
|
|
1015
|
+
.b(body);
|
|
1016
|
+
return b.build();
|
|
1017
|
+
};
|
|
1018
|
+
exports.se_SendSystemMessageCommand = se_SendSystemMessageCommand;
|
|
1001
1019
|
const se_SendTypingStartCommand = async (input, context) => {
|
|
1002
1020
|
const b = (0, core_2.requestBuilder)(input, context);
|
|
1003
1021
|
const headers = {};
|
|
@@ -1981,6 +1999,21 @@ const de_SendMessageReactionCommand = async (output, context) => {
|
|
|
1981
1999
|
return contents;
|
|
1982
2000
|
};
|
|
1983
2001
|
exports.de_SendMessageReactionCommand = de_SendMessageReactionCommand;
|
|
2002
|
+
const de_SendSystemMessageCommand = async (output, context) => {
|
|
2003
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2004
|
+
return de_CommandError(output, context);
|
|
2005
|
+
}
|
|
2006
|
+
const contents = (0, smithy_client_1.map)({
|
|
2007
|
+
$metadata: deserializeMetadata(output),
|
|
2008
|
+
});
|
|
2009
|
+
const data = (0, smithy_client_1.expectNonNull)(((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context))), "body");
|
|
2010
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
2011
|
+
'message': smithy_client_1._json,
|
|
2012
|
+
});
|
|
2013
|
+
Object.assign(contents, doc);
|
|
2014
|
+
return contents;
|
|
2015
|
+
};
|
|
2016
|
+
exports.de_SendSystemMessageCommand = de_SendSystemMessageCommand;
|
|
1984
2017
|
const de_SendTypingStartCommand = async (output, context) => {
|
|
1985
2018
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1986
2019
|
return de_CommandError(output, context);
|
package/dist-es/Conversations.js
CHANGED
|
@@ -51,6 +51,7 @@ import { SendActionTriggerResultCommand, } from "./commands/SendActionTriggerRes
|
|
|
51
51
|
import { SendGiphyCommand, } from "./commands/SendGiphyCommand";
|
|
52
52
|
import { SendMessageCommand, } from "./commands/SendMessageCommand";
|
|
53
53
|
import { SendMessageReactionCommand, } from "./commands/SendMessageReactionCommand";
|
|
54
|
+
import { SendSystemMessageCommand, } from "./commands/SendSystemMessageCommand";
|
|
54
55
|
import { SendTypingStartCommand, } from "./commands/SendTypingStartCommand";
|
|
55
56
|
import { SendTypingStopCommand, } from "./commands/SendTypingStopCommand";
|
|
56
57
|
import { ShowChannelCommand, } from "./commands/ShowChannelCommand";
|
|
@@ -117,6 +118,7 @@ const commands = {
|
|
|
117
118
|
SendGiphyCommand,
|
|
118
119
|
SendMessageCommand,
|
|
119
120
|
SendMessageReactionCommand,
|
|
121
|
+
SendSystemMessageCommand,
|
|
120
122
|
SendTypingStartCommand,
|
|
121
123
|
SendTypingStopCommand,
|
|
122
124
|
ShowChannelCommand,
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { de_SendSystemMessageCommand, se_SendSystemMessageCommand, } 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 SendSystemMessageCommand extends $Command.classBuilder()
|
|
6
|
+
.m(function (Command, cs, config, o) {
|
|
7
|
+
return [
|
|
8
|
+
getSerdePlugin(config, this.serialize, this.deserialize),
|
|
9
|
+
];
|
|
10
|
+
})
|
|
11
|
+
.s("Conversations", "SendSystemMessage", {})
|
|
12
|
+
.n("ConversationsClient", "SendSystemMessageCommand")
|
|
13
|
+
.f(void 0, void 0)
|
|
14
|
+
.ser(se_SendSystemMessageCommand)
|
|
15
|
+
.de(de_SendSystemMessageCommand)
|
|
16
|
+
.build() {
|
|
17
|
+
}
|
|
@@ -50,6 +50,7 @@ export * from "./SendActionTriggerResultCommand";
|
|
|
50
50
|
export * from "./SendGiphyCommand";
|
|
51
51
|
export * from "./SendMessageCommand";
|
|
52
52
|
export * from "./SendMessageReactionCommand";
|
|
53
|
+
export * from "./SendSystemMessageCommand";
|
|
53
54
|
export * from "./SendTypingStartCommand";
|
|
54
55
|
export * from "./SendTypingStopCommand";
|
|
55
56
|
export * from "./ShowChannelCommand";
|
|
@@ -369,6 +369,14 @@ export class ConversationsServiceException extends __BaseException {
|
|
|
369
369
|
Object.setPrototypeOf(this, ConversationsServiceException.prototype);
|
|
370
370
|
}
|
|
371
371
|
}
|
|
372
|
+
export var SystemMessage;
|
|
373
|
+
(function (SystemMessage) {
|
|
374
|
+
SystemMessage.visit = (value, visitor) => {
|
|
375
|
+
if (value.whatsAppClosed !== undefined)
|
|
376
|
+
return visitor.whatsAppClosed(value.whatsAppClosed);
|
|
377
|
+
return visitor._(value.$unknown[0], value.$unknown[1]);
|
|
378
|
+
};
|
|
379
|
+
})(SystemMessage || (SystemMessage = {}));
|
|
372
380
|
export class TaggedChannelsLimitReachedException extends __BaseException {
|
|
373
381
|
name = "TaggedChannelsLimitReachedException";
|
|
374
382
|
$fault = "client";
|
|
@@ -941,6 +941,23 @@ export const se_SendMessageReactionCommand = async (input, context) => {
|
|
|
941
941
|
.b(body);
|
|
942
942
|
return b.build();
|
|
943
943
|
};
|
|
944
|
+
export const se_SendSystemMessageCommand = async (input, context) => {
|
|
945
|
+
const b = rb(input, context);
|
|
946
|
+
const headers = {
|
|
947
|
+
'content-type': 'application/json',
|
|
948
|
+
};
|
|
949
|
+
b.bp("/v2/conversations/channels/{channelId}/system-messages");
|
|
950
|
+
b.p('channelId', () => input.channelId, '{channelId}', false);
|
|
951
|
+
let body;
|
|
952
|
+
body = JSON.stringify(take(input, {
|
|
953
|
+
'message': _ => _json(_),
|
|
954
|
+
'userId': [],
|
|
955
|
+
}));
|
|
956
|
+
b.m("POST")
|
|
957
|
+
.h(headers)
|
|
958
|
+
.b(body);
|
|
959
|
+
return b.build();
|
|
960
|
+
};
|
|
944
961
|
export const se_SendTypingStartCommand = async (input, context) => {
|
|
945
962
|
const b = rb(input, context);
|
|
946
963
|
const headers = {};
|
|
@@ -1860,6 +1877,20 @@ export const de_SendMessageReactionCommand = async (output, context) => {
|
|
|
1860
1877
|
await collectBody(output.body, context);
|
|
1861
1878
|
return contents;
|
|
1862
1879
|
};
|
|
1880
|
+
export const de_SendSystemMessageCommand = async (output, context) => {
|
|
1881
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1882
|
+
return de_CommandError(output, context);
|
|
1883
|
+
}
|
|
1884
|
+
const contents = map({
|
|
1885
|
+
$metadata: deserializeMetadata(output),
|
|
1886
|
+
});
|
|
1887
|
+
const data = __expectNonNull((__expectObject(await parseBody(output.body, context))), "body");
|
|
1888
|
+
const doc = take(data, {
|
|
1889
|
+
'message': _json,
|
|
1890
|
+
});
|
|
1891
|
+
Object.assign(contents, doc);
|
|
1892
|
+
return contents;
|
|
1893
|
+
};
|
|
1863
1894
|
export const de_SendTypingStartCommand = async (output, context) => {
|
|
1864
1895
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1865
1896
|
return de_CommandError(output, context);
|
|
@@ -51,6 +51,7 @@ import { SendActionTriggerResultCommandInput, SendActionTriggerResultCommandOutp
|
|
|
51
51
|
import { SendGiphyCommandInput, SendGiphyCommandOutput } from "./commands/SendGiphyCommand";
|
|
52
52
|
import { SendMessageCommandInput, SendMessageCommandOutput } from "./commands/SendMessageCommand";
|
|
53
53
|
import { SendMessageReactionCommandInput, SendMessageReactionCommandOutput } from "./commands/SendMessageReactionCommand";
|
|
54
|
+
import { SendSystemMessageCommandInput, SendSystemMessageCommandOutput } from "./commands/SendSystemMessageCommand";
|
|
54
55
|
import { SendTypingStartCommandInput, SendTypingStartCommandOutput } from "./commands/SendTypingStartCommand";
|
|
55
56
|
import { SendTypingStopCommandInput, SendTypingStopCommandOutput } from "./commands/SendTypingStopCommand";
|
|
56
57
|
import { ShowChannelCommandInput, ShowChannelCommandOutput } from "./commands/ShowChannelCommand";
|
|
@@ -386,6 +387,12 @@ export interface Conversations {
|
|
|
386
387
|
sendMessageReaction(args: SendMessageReactionCommandInput, options?: __HttpHandlerOptions): Promise<SendMessageReactionCommandOutput>;
|
|
387
388
|
sendMessageReaction(args: SendMessageReactionCommandInput, cb: (err: any, data?: SendMessageReactionCommandOutput) => void): void;
|
|
388
389
|
sendMessageReaction(args: SendMessageReactionCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: SendMessageReactionCommandOutput) => void): void;
|
|
390
|
+
/**
|
|
391
|
+
* @see {@link SendSystemMessageCommand}
|
|
392
|
+
*/
|
|
393
|
+
sendSystemMessage(args: SendSystemMessageCommandInput, options?: __HttpHandlerOptions): Promise<SendSystemMessageCommandOutput>;
|
|
394
|
+
sendSystemMessage(args: SendSystemMessageCommandInput, cb: (err: any, data?: SendSystemMessageCommandOutput) => void): void;
|
|
395
|
+
sendSystemMessage(args: SendSystemMessageCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: SendSystemMessageCommandOutput) => void): void;
|
|
389
396
|
/**
|
|
390
397
|
* @see {@link SendTypingStartCommand}
|
|
391
398
|
*/
|
|
@@ -50,6 +50,7 @@ import { SendActionTriggerResultCommandInput, SendActionTriggerResultCommandOutp
|
|
|
50
50
|
import { SendGiphyCommandInput, SendGiphyCommandOutput } from "./commands/SendGiphyCommand";
|
|
51
51
|
import { SendMessageCommandInput, SendMessageCommandOutput } from "./commands/SendMessageCommand";
|
|
52
52
|
import { SendMessageReactionCommandInput, SendMessageReactionCommandOutput } from "./commands/SendMessageReactionCommand";
|
|
53
|
+
import { SendSystemMessageCommandInput, SendSystemMessageCommandOutput } from "./commands/SendSystemMessageCommand";
|
|
53
54
|
import { SendTypingStartCommandInput, SendTypingStartCommandOutput } from "./commands/SendTypingStartCommand";
|
|
54
55
|
import { SendTypingStopCommandInput, SendTypingStopCommandOutput } from "./commands/SendTypingStopCommand";
|
|
55
56
|
import { ShowChannelCommandInput, ShowChannelCommandOutput } from "./commands/ShowChannelCommand";
|
|
@@ -73,11 +74,11 @@ export { __Client };
|
|
|
73
74
|
/**
|
|
74
75
|
* @public
|
|
75
76
|
*/
|
|
76
|
-
export type ServiceInputTypes = AddChannelMemberCommandInput | AddChannelMembersCommandInput | AssignChannelCommandInput | CreateGroupChannelCommandInput | CreateInboxTagCommandInput | CreateKiteChannelCommandInput | DeleteChannelCommandInput | DeleteChannelMemberCommandInput | DeleteInboxTagCommandInput | DeleteMessageCommandInput | DeleteMessageReactionCommandInput | DescribeEventCommandInput | GetActionTriggerResultCommandInput | GetChannelCommandInput | GetChannelMemberCommandInput | GetDirectChannelIdCommandInput | GetFilePresignedDownloadUrlCommandInput | GetInboxStateCommandInput | GetMessageCommandInput | GetOrCreateDirectChannelCommandInput | GetOrCreateSmsChannelCommandInput | GetOrCreateTelephonyChannelCommandInput | GetOrCreateWhatsAppChannelCommandInput | GetSmsChannelIdCommandInput | GetTelephonyChannelIdCommandInput | GetTokenCommandInput | GetUploadedFileInfoCommandInput | GetWhatsAppChannelIdCommandInput | HideChannelCommandInput | InviteCommandInput | JoinChannelCommandInput | LeaveChannelCommandInput | ListChannelMembersCommandInput | ListChannelMembersReadStatusCommandInput | ListChannelsCommandInput | ListInboxTaggedChannelsCommandInput | ListInboxTagsCommandInput | ListMessageReactionsCommandInput | ListMessagesCommandInput | ListPinnedMessagesCommandInput | MarkReadCommandInput | MarkUnreadCommandInput | PartialUpdateChannelCommandInput | PartialUpdateMessageCommandInput | PinChannelCommandInput | PinMessageCommandInput | QueryChannelsCommandInput | ScheduleExternalFlagAdjustmentJobCommandInput | SendActionTriggerResultCommandInput | SendGiphyCommandInput | SendMessageCommandInput | SendMessageReactionCommandInput | SendTypingStartCommandInput | SendTypingStopCommandInput | ShowChannelCommandInput | TagChannelCommandInput | TriggerMessageActionCommandInput | UnpinChannelCommandInput | UnpinMessageCommandInput | UntagChannelCommandInput | UpdateChannelCommandInput | UpdateInboxTagCommandInput | UpdateMessageCommandInput | UploadFileCommandInput;
|
|
77
|
+
export type ServiceInputTypes = AddChannelMemberCommandInput | AddChannelMembersCommandInput | AssignChannelCommandInput | CreateGroupChannelCommandInput | CreateInboxTagCommandInput | CreateKiteChannelCommandInput | DeleteChannelCommandInput | DeleteChannelMemberCommandInput | DeleteInboxTagCommandInput | DeleteMessageCommandInput | DeleteMessageReactionCommandInput | DescribeEventCommandInput | GetActionTriggerResultCommandInput | GetChannelCommandInput | GetChannelMemberCommandInput | GetDirectChannelIdCommandInput | GetFilePresignedDownloadUrlCommandInput | GetInboxStateCommandInput | GetMessageCommandInput | GetOrCreateDirectChannelCommandInput | GetOrCreateSmsChannelCommandInput | GetOrCreateTelephonyChannelCommandInput | GetOrCreateWhatsAppChannelCommandInput | GetSmsChannelIdCommandInput | GetTelephonyChannelIdCommandInput | GetTokenCommandInput | GetUploadedFileInfoCommandInput | GetWhatsAppChannelIdCommandInput | HideChannelCommandInput | InviteCommandInput | JoinChannelCommandInput | LeaveChannelCommandInput | ListChannelMembersCommandInput | ListChannelMembersReadStatusCommandInput | ListChannelsCommandInput | ListInboxTaggedChannelsCommandInput | ListInboxTagsCommandInput | ListMessageReactionsCommandInput | ListMessagesCommandInput | ListPinnedMessagesCommandInput | MarkReadCommandInput | MarkUnreadCommandInput | PartialUpdateChannelCommandInput | PartialUpdateMessageCommandInput | PinChannelCommandInput | PinMessageCommandInput | QueryChannelsCommandInput | ScheduleExternalFlagAdjustmentJobCommandInput | SendActionTriggerResultCommandInput | SendGiphyCommandInput | SendMessageCommandInput | SendMessageReactionCommandInput | SendSystemMessageCommandInput | SendTypingStartCommandInput | SendTypingStopCommandInput | ShowChannelCommandInput | TagChannelCommandInput | TriggerMessageActionCommandInput | UnpinChannelCommandInput | UnpinMessageCommandInput | UntagChannelCommandInput | UpdateChannelCommandInput | UpdateInboxTagCommandInput | UpdateMessageCommandInput | UploadFileCommandInput;
|
|
77
78
|
/**
|
|
78
79
|
* @public
|
|
79
80
|
*/
|
|
80
|
-
export type ServiceOutputTypes = AddChannelMemberCommandOutput | AddChannelMembersCommandOutput | AssignChannelCommandOutput | CreateGroupChannelCommandOutput | CreateInboxTagCommandOutput | CreateKiteChannelCommandOutput | DeleteChannelCommandOutput | DeleteChannelMemberCommandOutput | DeleteInboxTagCommandOutput | DeleteMessageCommandOutput | DeleteMessageReactionCommandOutput | DescribeEventCommandOutput | GetActionTriggerResultCommandOutput | GetChannelCommandOutput | GetChannelMemberCommandOutput | GetDirectChannelIdCommandOutput | GetFilePresignedDownloadUrlCommandOutput | GetInboxStateCommandOutput | GetMessageCommandOutput | GetOrCreateDirectChannelCommandOutput | GetOrCreateSmsChannelCommandOutput | GetOrCreateTelephonyChannelCommandOutput | GetOrCreateWhatsAppChannelCommandOutput | GetSmsChannelIdCommandOutput | GetTelephonyChannelIdCommandOutput | GetTokenCommandOutput | GetUploadedFileInfoCommandOutput | GetWhatsAppChannelIdCommandOutput | HideChannelCommandOutput | InviteCommandOutput | JoinChannelCommandOutput | LeaveChannelCommandOutput | ListChannelMembersCommandOutput | ListChannelMembersReadStatusCommandOutput | ListChannelsCommandOutput | ListInboxTaggedChannelsCommandOutput | ListInboxTagsCommandOutput | ListMessageReactionsCommandOutput | ListMessagesCommandOutput | ListPinnedMessagesCommandOutput | MarkReadCommandOutput | MarkUnreadCommandOutput | PartialUpdateChannelCommandOutput | PartialUpdateMessageCommandOutput | PinChannelCommandOutput | PinMessageCommandOutput | QueryChannelsCommandOutput | ScheduleExternalFlagAdjustmentJobCommandOutput | SendActionTriggerResultCommandOutput | SendGiphyCommandOutput | SendMessageCommandOutput | SendMessageReactionCommandOutput | SendTypingStartCommandOutput | SendTypingStopCommandOutput | ShowChannelCommandOutput | TagChannelCommandOutput | TriggerMessageActionCommandOutput | UnpinChannelCommandOutput | UnpinMessageCommandOutput | UntagChannelCommandOutput | UpdateChannelCommandOutput | UpdateInboxTagCommandOutput | UpdateMessageCommandOutput | UploadFileCommandOutput;
|
|
81
|
+
export type ServiceOutputTypes = AddChannelMemberCommandOutput | AddChannelMembersCommandOutput | AssignChannelCommandOutput | CreateGroupChannelCommandOutput | CreateInboxTagCommandOutput | CreateKiteChannelCommandOutput | DeleteChannelCommandOutput | DeleteChannelMemberCommandOutput | DeleteInboxTagCommandOutput | DeleteMessageCommandOutput | DeleteMessageReactionCommandOutput | DescribeEventCommandOutput | GetActionTriggerResultCommandOutput | GetChannelCommandOutput | GetChannelMemberCommandOutput | GetDirectChannelIdCommandOutput | GetFilePresignedDownloadUrlCommandOutput | GetInboxStateCommandOutput | GetMessageCommandOutput | GetOrCreateDirectChannelCommandOutput | GetOrCreateSmsChannelCommandOutput | GetOrCreateTelephonyChannelCommandOutput | GetOrCreateWhatsAppChannelCommandOutput | GetSmsChannelIdCommandOutput | GetTelephonyChannelIdCommandOutput | GetTokenCommandOutput | GetUploadedFileInfoCommandOutput | GetWhatsAppChannelIdCommandOutput | HideChannelCommandOutput | InviteCommandOutput | JoinChannelCommandOutput | LeaveChannelCommandOutput | ListChannelMembersCommandOutput | ListChannelMembersReadStatusCommandOutput | ListChannelsCommandOutput | ListInboxTaggedChannelsCommandOutput | ListInboxTagsCommandOutput | ListMessageReactionsCommandOutput | ListMessagesCommandOutput | ListPinnedMessagesCommandOutput | MarkReadCommandOutput | MarkUnreadCommandOutput | PartialUpdateChannelCommandOutput | PartialUpdateMessageCommandOutput | PinChannelCommandOutput | PinMessageCommandOutput | QueryChannelsCommandOutput | ScheduleExternalFlagAdjustmentJobCommandOutput | SendActionTriggerResultCommandOutput | SendGiphyCommandOutput | SendMessageCommandOutput | SendMessageReactionCommandOutput | SendSystemMessageCommandOutput | SendTypingStartCommandOutput | SendTypingStopCommandOutput | ShowChannelCommandOutput | TagChannelCommandOutput | TriggerMessageActionCommandOutput | UnpinChannelCommandOutput | UnpinMessageCommandOutput | UntagChannelCommandOutput | UpdateChannelCommandOutput | UpdateInboxTagCommandOutput | UpdateMessageCommandOutput | UploadFileCommandOutput;
|
|
81
82
|
/**
|
|
82
83
|
* @public
|
|
83
84
|
*/
|
|
@@ -0,0 +1,247 @@
|
|
|
1
|
+
import { ConversationsClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../ConversationsClient";
|
|
2
|
+
import { SendSystemMessageInput, SendSystemMessageOutput } 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 SendSystemMessageCommand}.
|
|
14
|
+
*/
|
|
15
|
+
export interface SendSystemMessageCommandInput extends SendSystemMessageInput {
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* @public
|
|
19
|
+
*
|
|
20
|
+
* The output of {@link SendSystemMessageCommand}.
|
|
21
|
+
*/
|
|
22
|
+
export interface SendSystemMessageCommandOutput extends SendSystemMessageOutput, __MetadataBearer {
|
|
23
|
+
}
|
|
24
|
+
declare const SendSystemMessageCommand_base: {
|
|
25
|
+
new (input: SendSystemMessageCommandInput): import("@smithy/smithy-client").CommandImpl<SendSystemMessageCommandInput, SendSystemMessageCommandOutput, ConversationsClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
|
|
26
|
+
new (__0_0: SendSystemMessageCommandInput): import("@smithy/smithy-client").CommandImpl<SendSystemMessageCommandInput, SendSystemMessageCommandOutput, ConversationsClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
|
|
27
|
+
getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions;
|
|
28
|
+
};
|
|
29
|
+
/**
|
|
30
|
+
* Sends a system message to a specified channel. This operation available with S2S authorization only.
|
|
31
|
+
* @example
|
|
32
|
+
* Use a bare-bones client and the command you need to make an API call.
|
|
33
|
+
* ```javascript
|
|
34
|
+
* import { ConversationsClient, SendSystemMessageCommand } from "@wildix/xbees-conversations-client"; // ES Modules import
|
|
35
|
+
* // const { ConversationsClient, SendSystemMessageCommand } = require("@wildix/xbees-conversations-client"); // CommonJS import
|
|
36
|
+
* const client = new ConversationsClient(config);
|
|
37
|
+
* const input = { // SendSystemMessageInput
|
|
38
|
+
* channelId: "STRING_VALUE", // required
|
|
39
|
+
* userId: "STRING_VALUE",
|
|
40
|
+
* message: { // SystemMessage Union: only one key present
|
|
41
|
+
* whatsAppClosed: {},
|
|
42
|
+
* },
|
|
43
|
+
* };
|
|
44
|
+
* const command = new SendSystemMessageCommand(input);
|
|
45
|
+
* const response = await client.send(command);
|
|
46
|
+
* // { // SendSystemMessageOutput
|
|
47
|
+
* // message: { // Message
|
|
48
|
+
* // text: "STRING_VALUE",
|
|
49
|
+
* // elements: [ // ElementsList
|
|
50
|
+
* // { // Element Union: only one key present
|
|
51
|
+
* // template: { // MessageTemplateConfig
|
|
52
|
+
* // whatsapp: { // TemplateWithParameters
|
|
53
|
+
* // name: "STRING_VALUE", // required
|
|
54
|
+
* // parameters: [ // ListTemplateParameter // required
|
|
55
|
+
* // { // TemplateParameter
|
|
56
|
+
* // name: "STRING_VALUE", // required
|
|
57
|
+
* // value: "STRING_VALUE", // required
|
|
58
|
+
* // },
|
|
59
|
+
* // ],
|
|
60
|
+
* // },
|
|
61
|
+
* // },
|
|
62
|
+
* // actions: [ // ActionsElementsList
|
|
63
|
+
* // { // ActionElement Union: only one key present
|
|
64
|
+
* // button: { // ButtonElement
|
|
65
|
+
* // text: "STRING_VALUE", // required
|
|
66
|
+
* // handler: { // ButtonHandler Union: only one key present
|
|
67
|
+
* // link: { // ButtonLinkHandler
|
|
68
|
+
* // url: "STRING_VALUE", // required
|
|
69
|
+
* // },
|
|
70
|
+
* // reply: { // ButtonReplyHandler
|
|
71
|
+
* // text: "STRING_VALUE",
|
|
72
|
+
* // },
|
|
73
|
+
* // action: { // ButtonActionHandler
|
|
74
|
+
* // id: "STRING_VALUE", // required
|
|
75
|
+
* // },
|
|
76
|
+
* // },
|
|
77
|
+
* // variant: "contained" || "outlined",
|
|
78
|
+
* // disabled: true || false,
|
|
79
|
+
* // },
|
|
80
|
+
* // },
|
|
81
|
+
* // ],
|
|
82
|
+
* // },
|
|
83
|
+
* // ],
|
|
84
|
+
* // attachments: [ // MessageAttachmentList
|
|
85
|
+
* // { // MessageAttachment
|
|
86
|
+
* // id: "STRING_VALUE", // required
|
|
87
|
+
* // fsId: "STRING_VALUE", // required
|
|
88
|
+
* // mime: "STRING_VALUE",
|
|
89
|
+
* // name: "STRING_VALUE", // required
|
|
90
|
+
* // size: Number("int"), // required
|
|
91
|
+
* // width: Number("int"),
|
|
92
|
+
* // height: Number("int"),
|
|
93
|
+
* // thumbnail: "STRING_VALUE",
|
|
94
|
+
* // },
|
|
95
|
+
* // ],
|
|
96
|
+
* // quote: { // MessageQuote
|
|
97
|
+
* // messageId: "STRING_VALUE", // required
|
|
98
|
+
* // channelId: "STRING_VALUE", // required
|
|
99
|
+
* // user: { // User
|
|
100
|
+
* // id: "STRING_VALUE", // required
|
|
101
|
+
* // name: "STRING_VALUE",
|
|
102
|
+
* // email: "STRING_VALUE",
|
|
103
|
+
* // phone: "STRING_VALUE",
|
|
104
|
+
* // picture: "STRING_VALUE",
|
|
105
|
+
* // locale: "STRING_VALUE",
|
|
106
|
+
* // timeZone: "STRING_VALUE",
|
|
107
|
+
* // company: "STRING_VALUE",
|
|
108
|
+
* // bot: true || false,
|
|
109
|
+
* // pbxDomain: "STRING_VALUE",
|
|
110
|
+
* // pbxPort: "STRING_VALUE",
|
|
111
|
+
* // pbxExtension: "STRING_VALUE",
|
|
112
|
+
* // pbxSerial: "STRING_VALUE",
|
|
113
|
+
* // pbxUserId: "STRING_VALUE",
|
|
114
|
+
* // createdAt: "STRING_VALUE",
|
|
115
|
+
* // updatedAt: "STRING_VALUE",
|
|
116
|
+
* // },
|
|
117
|
+
* // text: "STRING_VALUE",
|
|
118
|
+
* // attachments: [
|
|
119
|
+
* // {
|
|
120
|
+
* // id: "STRING_VALUE", // required
|
|
121
|
+
* // fsId: "STRING_VALUE", // required
|
|
122
|
+
* // mime: "STRING_VALUE",
|
|
123
|
+
* // name: "STRING_VALUE", // required
|
|
124
|
+
* // size: Number("int"), // required
|
|
125
|
+
* // width: Number("int"),
|
|
126
|
+
* // height: Number("int"),
|
|
127
|
+
* // thumbnail: "STRING_VALUE",
|
|
128
|
+
* // },
|
|
129
|
+
* // ],
|
|
130
|
+
* // forward: { // MessageForward
|
|
131
|
+
* // forwardCompany: "STRING_VALUE",
|
|
132
|
+
* // forwardDate: "STRING_VALUE", // required
|
|
133
|
+
* // forwardEmail: "STRING_VALUE",
|
|
134
|
+
* // forwardName: "STRING_VALUE",
|
|
135
|
+
* // messageId: "STRING_VALUE", // required
|
|
136
|
+
* // channelId: "STRING_VALUE", // required
|
|
137
|
+
* // },
|
|
138
|
+
* // mentions: [ // UsersList
|
|
139
|
+
* // {
|
|
140
|
+
* // id: "STRING_VALUE", // required
|
|
141
|
+
* // name: "STRING_VALUE",
|
|
142
|
+
* // email: "STRING_VALUE",
|
|
143
|
+
* // phone: "STRING_VALUE",
|
|
144
|
+
* // picture: "STRING_VALUE",
|
|
145
|
+
* // locale: "STRING_VALUE",
|
|
146
|
+
* // timeZone: "STRING_VALUE",
|
|
147
|
+
* // company: "STRING_VALUE",
|
|
148
|
+
* // bot: true || false,
|
|
149
|
+
* // pbxDomain: "STRING_VALUE",
|
|
150
|
+
* // pbxPort: "STRING_VALUE",
|
|
151
|
+
* // pbxExtension: "STRING_VALUE",
|
|
152
|
+
* // pbxSerial: "STRING_VALUE",
|
|
153
|
+
* // pbxUserId: "STRING_VALUE",
|
|
154
|
+
* // createdAt: "STRING_VALUE",
|
|
155
|
+
* // updatedAt: "STRING_VALUE",
|
|
156
|
+
* // },
|
|
157
|
+
* // ],
|
|
158
|
+
* // giphy: { // MessageGiphy
|
|
159
|
+
* // id: "STRING_VALUE", // required
|
|
160
|
+
* // size: "STRING_VALUE", // required
|
|
161
|
+
* // url: "STRING_VALUE", // required
|
|
162
|
+
* // height: "STRING_VALUE", // required
|
|
163
|
+
* // width: "STRING_VALUE", // required
|
|
164
|
+
* // },
|
|
165
|
+
* // createdAt: "STRING_VALUE", // required
|
|
166
|
+
* // updatedAt: "STRING_VALUE",
|
|
167
|
+
* // },
|
|
168
|
+
* // forward: {
|
|
169
|
+
* // forwardCompany: "STRING_VALUE",
|
|
170
|
+
* // forwardDate: "STRING_VALUE", // required
|
|
171
|
+
* // forwardEmail: "STRING_VALUE",
|
|
172
|
+
* // forwardName: "STRING_VALUE",
|
|
173
|
+
* // messageId: "STRING_VALUE", // required
|
|
174
|
+
* // channelId: "STRING_VALUE", // required
|
|
175
|
+
* // },
|
|
176
|
+
* // whatsapp: true || false,
|
|
177
|
+
* // whatsappStatus: "trying" || "sent" || "delivered" || "error",
|
|
178
|
+
* // sms: true || false,
|
|
179
|
+
* // smsStatus: "sent" || "delivered" || "trying" || "error",
|
|
180
|
+
* // type: "regular" || "system", // required
|
|
181
|
+
* // giphy: {
|
|
182
|
+
* // id: "STRING_VALUE", // required
|
|
183
|
+
* // size: "STRING_VALUE", // required
|
|
184
|
+
* // url: "STRING_VALUE", // required
|
|
185
|
+
* // height: "STRING_VALUE", // required
|
|
186
|
+
* // width: "STRING_VALUE", // required
|
|
187
|
+
* // },
|
|
188
|
+
* // silent: true || false,
|
|
189
|
+
* // event: "STRING_VALUE",
|
|
190
|
+
* // messageId: "STRING_VALUE", // required
|
|
191
|
+
* // channelId: "STRING_VALUE", // required
|
|
192
|
+
* // user: "<User>", // required
|
|
193
|
+
* // edit: true || false,
|
|
194
|
+
* // mentions: [
|
|
195
|
+
* // "<User>",
|
|
196
|
+
* // ],
|
|
197
|
+
* // latestReactions: [ // ReactionList
|
|
198
|
+
* // { // Reaction
|
|
199
|
+
* // type: "STRING_VALUE",
|
|
200
|
+
* // userId: "STRING_VALUE",
|
|
201
|
+
* // messageId: "STRING_VALUE",
|
|
202
|
+
* // user: "<User>",
|
|
203
|
+
* // },
|
|
204
|
+
* // ],
|
|
205
|
+
* // reactionCounts: { // ReactionCounts
|
|
206
|
+
* // "<keys>": Number("int"),
|
|
207
|
+
* // },
|
|
208
|
+
* // createdAt: "STRING_VALUE", // required
|
|
209
|
+
* // updatedAt: "STRING_VALUE",
|
|
210
|
+
* // },
|
|
211
|
+
* // };
|
|
212
|
+
*
|
|
213
|
+
* ```
|
|
214
|
+
*
|
|
215
|
+
* @param SendSystemMessageCommandInput - {@link SendSystemMessageCommandInput}
|
|
216
|
+
* @returns {@link SendSystemMessageCommandOutput}
|
|
217
|
+
* @see {@link SendSystemMessageCommandInput} for command's `input` shape.
|
|
218
|
+
* @see {@link SendSystemMessageCommandOutput} for command's `response` shape.
|
|
219
|
+
* @see {@link ConversationsClientResolvedConfig | config} for ConversationsClient's `config` shape.
|
|
220
|
+
*
|
|
221
|
+
* @throws {@link ChannelNotFoundException} (client fault)
|
|
222
|
+
*
|
|
223
|
+
* @throws {@link ValidationException} (client fault)
|
|
224
|
+
*
|
|
225
|
+
* @throws {@link ForbiddenException} (client fault)
|
|
226
|
+
*
|
|
227
|
+
* @throws {@link RateLimitExceededException} (client fault)
|
|
228
|
+
*
|
|
229
|
+
* @throws {@link ConversationsServiceException}
|
|
230
|
+
* <p>Base exception class for all service exceptions from Conversations service.</p>
|
|
231
|
+
*
|
|
232
|
+
*
|
|
233
|
+
* @public
|
|
234
|
+
*/
|
|
235
|
+
export declare class SendSystemMessageCommand extends SendSystemMessageCommand_base {
|
|
236
|
+
/** @internal type navigation helper, not in runtime. */
|
|
237
|
+
protected static __types: {
|
|
238
|
+
api: {
|
|
239
|
+
input: SendSystemMessageInput;
|
|
240
|
+
output: SendSystemMessageOutput;
|
|
241
|
+
};
|
|
242
|
+
sdk: {
|
|
243
|
+
input: SendSystemMessageCommandInput;
|
|
244
|
+
output: SendSystemMessageCommandOutput;
|
|
245
|
+
};
|
|
246
|
+
};
|
|
247
|
+
}
|
|
@@ -50,6 +50,7 @@ export * from "./SendActionTriggerResultCommand";
|
|
|
50
50
|
export * from "./SendGiphyCommand";
|
|
51
51
|
export * from "./SendMessageCommand";
|
|
52
52
|
export * from "./SendMessageReactionCommand";
|
|
53
|
+
export * from "./SendSystemMessageCommand";
|
|
53
54
|
export * from "./SendTypingStartCommand";
|
|
54
55
|
export * from "./SendTypingStopCommand";
|
|
55
56
|
export * from "./ShowChannelCommand";
|
|
@@ -2785,6 +2785,62 @@ export interface SendMessageReactionInput {
|
|
|
2785
2785
|
*/
|
|
2786
2786
|
export interface SendMessageReactionOutput {
|
|
2787
2787
|
}
|
|
2788
|
+
/**
|
|
2789
|
+
* @public
|
|
2790
|
+
*/
|
|
2791
|
+
export interface WhatsAppClosedSystemMessage {
|
|
2792
|
+
}
|
|
2793
|
+
/**
|
|
2794
|
+
* @public
|
|
2795
|
+
*/
|
|
2796
|
+
export type SystemMessage = SystemMessage.WhatsAppClosedMember | SystemMessage.$UnknownMember;
|
|
2797
|
+
/**
|
|
2798
|
+
* @public
|
|
2799
|
+
*/
|
|
2800
|
+
export declare namespace SystemMessage {
|
|
2801
|
+
/**
|
|
2802
|
+
* A message indicating that the WhatsApp channel has been closed after 24 hours. This message type has empty payload.
|
|
2803
|
+
* @public
|
|
2804
|
+
*/
|
|
2805
|
+
interface WhatsAppClosedMember {
|
|
2806
|
+
whatsAppClosed: WhatsAppClosedSystemMessage;
|
|
2807
|
+
$unknown?: never;
|
|
2808
|
+
}
|
|
2809
|
+
/**
|
|
2810
|
+
* @public
|
|
2811
|
+
*/
|
|
2812
|
+
interface $UnknownMember {
|
|
2813
|
+
whatsAppClosed?: never;
|
|
2814
|
+
$unknown: [string, any];
|
|
2815
|
+
}
|
|
2816
|
+
interface Visitor<T> {
|
|
2817
|
+
whatsAppClosed: (value: WhatsAppClosedSystemMessage) => T;
|
|
2818
|
+
_: (name: string, value: any) => T;
|
|
2819
|
+
}
|
|
2820
|
+
const visit: <T>(value: SystemMessage, visitor: Visitor<T>) => T;
|
|
2821
|
+
}
|
|
2822
|
+
/**
|
|
2823
|
+
* @public
|
|
2824
|
+
*/
|
|
2825
|
+
export interface SendSystemMessageInput {
|
|
2826
|
+
/**
|
|
2827
|
+
* The unique identifier of the channel to which the message is sent.
|
|
2828
|
+
* @public
|
|
2829
|
+
*/
|
|
2830
|
+
channelId: string;
|
|
2831
|
+
/**
|
|
2832
|
+
* The unique identifier of the user when a service token is used.
|
|
2833
|
+
* @public
|
|
2834
|
+
*/
|
|
2835
|
+
userId?: string | undefined;
|
|
2836
|
+
message: SystemMessage;
|
|
2837
|
+
}
|
|
2838
|
+
/**
|
|
2839
|
+
* @public
|
|
2840
|
+
*/
|
|
2841
|
+
export interface SendSystemMessageOutput {
|
|
2842
|
+
message: Message;
|
|
2843
|
+
}
|
|
2788
2844
|
/**
|
|
2789
2845
|
* @public
|
|
2790
2846
|
*/
|
|
@@ -50,6 +50,7 @@ import { SendActionTriggerResultCommandInput, SendActionTriggerResultCommandOutp
|
|
|
50
50
|
import { SendGiphyCommandInput, SendGiphyCommandOutput } from "../commands/SendGiphyCommand";
|
|
51
51
|
import { SendMessageCommandInput, SendMessageCommandOutput } from "../commands/SendMessageCommand";
|
|
52
52
|
import { SendMessageReactionCommandInput, SendMessageReactionCommandOutput } from "../commands/SendMessageReactionCommand";
|
|
53
|
+
import { SendSystemMessageCommandInput, SendSystemMessageCommandOutput } from "../commands/SendSystemMessageCommand";
|
|
53
54
|
import { SendTypingStartCommandInput, SendTypingStartCommandOutput } from "../commands/SendTypingStartCommand";
|
|
54
55
|
import { SendTypingStopCommandInput, SendTypingStopCommandOutput } from "../commands/SendTypingStopCommand";
|
|
55
56
|
import { ShowChannelCommandInput, ShowChannelCommandOutput } from "../commands/ShowChannelCommand";
|
|
@@ -272,6 +273,10 @@ export declare const se_SendMessageCommand: (input: SendMessageCommandInput, con
|
|
|
272
273
|
* serializeAws_restJson1SendMessageReactionCommand
|
|
273
274
|
*/
|
|
274
275
|
export declare const se_SendMessageReactionCommand: (input: SendMessageReactionCommandInput, context: __SerdeContext) => Promise<__HttpRequest>;
|
|
276
|
+
/**
|
|
277
|
+
* serializeAws_restJson1SendSystemMessageCommand
|
|
278
|
+
*/
|
|
279
|
+
export declare const se_SendSystemMessageCommand: (input: SendSystemMessageCommandInput, context: __SerdeContext) => Promise<__HttpRequest>;
|
|
275
280
|
/**
|
|
276
281
|
* serializeAws_restJson1SendTypingStartCommand
|
|
277
282
|
*/
|
|
@@ -528,6 +533,10 @@ export declare const de_SendMessageCommand: (output: __HttpResponse, context: __
|
|
|
528
533
|
* deserializeAws_restJson1SendMessageReactionCommand
|
|
529
534
|
*/
|
|
530
535
|
export declare const de_SendMessageReactionCommand: (output: __HttpResponse, context: __SerdeContext) => Promise<SendMessageReactionCommandOutput>;
|
|
536
|
+
/**
|
|
537
|
+
* deserializeAws_restJson1SendSystemMessageCommand
|
|
538
|
+
*/
|
|
539
|
+
export declare const de_SendSystemMessageCommand: (output: __HttpResponse, context: __SerdeContext) => Promise<SendSystemMessageCommandOutput>;
|
|
531
540
|
/**
|
|
532
541
|
* deserializeAws_restJson1SendTypingStartCommand
|
|
533
542
|
*/
|
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.20",
|
|
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",
|
|
@@ -80,4 +80,4 @@
|
|
|
80
80
|
"react-native": {
|
|
81
81
|
"./dist-es/runtimeConfig": "./dist-es/runtimeConfig.native"
|
|
82
82
|
}
|
|
83
|
-
}
|
|
83
|
+
}
|