@wildix/xbees-conversations-client 1.1.19 → 1.1.21

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.
@@ -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";
@@ -350,6 +350,7 @@ exports.GroupChannelUnsetOptions = {
350
350
  PICTURE: "picture",
351
351
  PICTURE_COLOR: "pictureColor",
352
352
  SUBJECT: "subject",
353
+ WHATSAPP_STATUS: "whatsappStatus",
353
354
  };
354
355
  exports.MessageUnsetFields = {
355
356
  ATTACHMENTS: "attachments",
@@ -389,6 +390,14 @@ class ConversationsServiceException extends ConversationsServiceException_1.Conv
389
390
  }
390
391
  }
391
392
  exports.ConversationsServiceException = ConversationsServiceException;
393
+ var SystemMessage;
394
+ (function (SystemMessage) {
395
+ SystemMessage.visit = (value, visitor) => {
396
+ if (value.whatsAppClosed !== undefined)
397
+ return visitor.whatsAppClosed(value.whatsAppClosed);
398
+ return visitor._(value.$unknown[0], value.$unknown[1]);
399
+ };
400
+ })(SystemMessage || (exports.SystemMessage = SystemMessage = {}));
392
401
  class TaggedChannelsLimitReachedException extends ConversationsServiceException_1.ConversationsServiceException {
393
402
  name = "TaggedChannelsLimitReachedException";
394
403
  $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.de_ListInboxTaggedChannelsCommand = 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_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_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");
@@ -101,6 +101,7 @@ const se_CreateGroupChannelCommand = async (input, context) => {
101
101
  'picture': [],
102
102
  'pictureColor': [],
103
103
  'subject': [],
104
+ 'whatsappStatus': [],
104
105
  }));
105
106
  b.m("POST")
106
107
  .h(headers)
@@ -998,6 +999,24 @@ const se_SendMessageReactionCommand = async (input, context) => {
998
999
  return b.build();
999
1000
  };
1000
1001
  exports.se_SendMessageReactionCommand = se_SendMessageReactionCommand;
1002
+ const se_SendSystemMessageCommand = async (input, context) => {
1003
+ const b = (0, core_2.requestBuilder)(input, context);
1004
+ const headers = {
1005
+ 'content-type': 'application/json',
1006
+ };
1007
+ b.bp("/v2/conversations/channels/{channelId}/system-messages");
1008
+ b.p('channelId', () => input.channelId, '{channelId}', false);
1009
+ let body;
1010
+ body = JSON.stringify((0, smithy_client_1.take)(input, {
1011
+ 'message': _ => (0, smithy_client_1._json)(_),
1012
+ 'userId': [],
1013
+ }));
1014
+ b.m("POST")
1015
+ .h(headers)
1016
+ .b(body);
1017
+ return b.build();
1018
+ };
1019
+ exports.se_SendSystemMessageCommand = se_SendSystemMessageCommand;
1001
1020
  const se_SendTypingStartCommand = async (input, context) => {
1002
1021
  const b = (0, core_2.requestBuilder)(input, context);
1003
1022
  const headers = {};
@@ -1157,6 +1176,7 @@ const se_UpdateChannelCommand = async (input, context) => {
1157
1176
  'pictureColor': [],
1158
1177
  'silent': [],
1159
1178
  'subject': [],
1179
+ 'whatsappStatus': [],
1160
1180
  }));
1161
1181
  b.m("PUT")
1162
1182
  .h(headers)
@@ -1981,6 +2001,21 @@ const de_SendMessageReactionCommand = async (output, context) => {
1981
2001
  return contents;
1982
2002
  };
1983
2003
  exports.de_SendMessageReactionCommand = de_SendMessageReactionCommand;
2004
+ const de_SendSystemMessageCommand = async (output, context) => {
2005
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
2006
+ return de_CommandError(output, context);
2007
+ }
2008
+ const contents = (0, smithy_client_1.map)({
2009
+ $metadata: deserializeMetadata(output),
2010
+ });
2011
+ const data = (0, smithy_client_1.expectNonNull)(((0, smithy_client_1.expectObject)(await (0, core_1.parseJsonBody)(output.body, context))), "body");
2012
+ const doc = (0, smithy_client_1.take)(data, {
2013
+ 'message': smithy_client_1._json,
2014
+ });
2015
+ Object.assign(contents, doc);
2016
+ return contents;
2017
+ };
2018
+ exports.de_SendSystemMessageCommand = de_SendSystemMessageCommand;
1984
2019
  const de_SendTypingStartCommand = async (output, context) => {
1985
2020
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1986
2021
  return de_CommandError(output, context);
@@ -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";
@@ -332,6 +332,7 @@ export const GroupChannelUnsetOptions = {
332
332
  PICTURE: "picture",
333
333
  PICTURE_COLOR: "pictureColor",
334
334
  SUBJECT: "subject",
335
+ WHATSAPP_STATUS: "whatsappStatus",
335
336
  };
336
337
  export const MessageUnsetFields = {
337
338
  ATTACHMENTS: "attachments",
@@ -369,6 +370,14 @@ export class ConversationsServiceException extends __BaseException {
369
370
  Object.setPrototypeOf(this, ConversationsServiceException.prototype);
370
371
  }
371
372
  }
373
+ export var SystemMessage;
374
+ (function (SystemMessage) {
375
+ SystemMessage.visit = (value, visitor) => {
376
+ if (value.whatsAppClosed !== undefined)
377
+ return visitor.whatsAppClosed(value.whatsAppClosed);
378
+ return visitor._(value.$unknown[0], value.$unknown[1]);
379
+ };
380
+ })(SystemMessage || (SystemMessage = {}));
372
381
  export class TaggedChannelsLimitReachedException extends __BaseException {
373
382
  name = "TaggedChannelsLimitReachedException";
374
383
  $fault = "client";
@@ -93,6 +93,7 @@ export const se_CreateGroupChannelCommand = async (input, context) => {
93
93
  'picture': [],
94
94
  'pictureColor': [],
95
95
  'subject': [],
96
+ 'whatsappStatus': [],
96
97
  }));
97
98
  b.m("POST")
98
99
  .h(headers)
@@ -941,6 +942,23 @@ export const se_SendMessageReactionCommand = async (input, context) => {
941
942
  .b(body);
942
943
  return b.build();
943
944
  };
945
+ export const se_SendSystemMessageCommand = async (input, context) => {
946
+ const b = rb(input, context);
947
+ const headers = {
948
+ 'content-type': 'application/json',
949
+ };
950
+ b.bp("/v2/conversations/channels/{channelId}/system-messages");
951
+ b.p('channelId', () => input.channelId, '{channelId}', false);
952
+ let body;
953
+ body = JSON.stringify(take(input, {
954
+ 'message': _ => _json(_),
955
+ 'userId': [],
956
+ }));
957
+ b.m("POST")
958
+ .h(headers)
959
+ .b(body);
960
+ return b.build();
961
+ };
944
962
  export const se_SendTypingStartCommand = async (input, context) => {
945
963
  const b = rb(input, context);
946
964
  const headers = {};
@@ -1092,6 +1110,7 @@ export const se_UpdateChannelCommand = async (input, context) => {
1092
1110
  'pictureColor': [],
1093
1111
  'silent': [],
1094
1112
  'subject': [],
1113
+ 'whatsappStatus': [],
1095
1114
  }));
1096
1115
  b.m("PUT")
1097
1116
  .h(headers)
@@ -1860,6 +1879,20 @@ export const de_SendMessageReactionCommand = async (output, context) => {
1860
1879
  await collectBody(output.body, context);
1861
1880
  return contents;
1862
1881
  };
1882
+ export const de_SendSystemMessageCommand = async (output, context) => {
1883
+ if (output.statusCode !== 200 && output.statusCode >= 300) {
1884
+ return de_CommandError(output, context);
1885
+ }
1886
+ const contents = map({
1887
+ $metadata: deserializeMetadata(output),
1888
+ });
1889
+ const data = __expectNonNull((__expectObject(await parseBody(output.body, context))), "body");
1890
+ const doc = take(data, {
1891
+ 'message': _json,
1892
+ });
1893
+ Object.assign(contents, doc);
1894
+ return contents;
1895
+ };
1863
1896
  export const de_SendTypingStartCommand = async (output, context) => {
1864
1897
  if (output.statusCode !== 200 && output.statusCode >= 300) {
1865
1898
  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
  */
@@ -64,6 +64,7 @@ declare const CreateGroupChannelCommand_base: {
64
64
  * broadcastId: "STRING_VALUE",
65
65
  * },
66
66
  * },
67
+ * whatsappStatus: "24h_channel_closed",
67
68
  * userId: "STRING_VALUE",
68
69
  * channelId: "STRING_VALUE",
69
70
  * members: [ // UsersIdList
@@ -68,9 +68,10 @@ declare const PartialUpdateChannelCommand_base: {
68
68
  * broadcastId: "STRING_VALUE",
69
69
  * },
70
70
  * },
71
+ * whatsappStatus: "24h_channel_closed",
71
72
  * },
72
73
  * unset: [ // PartialUpdateChannelUnsetOptions
73
- * "subject" || "description" || "picture" || "pictureColor" || "access" || "broadcast" || "context" || "contextPtt" || "contextEvents",
74
+ * "subject" || "description" || "picture" || "pictureColor" || "access" || "broadcast" || "context" || "contextPtt" || "contextEvents" || "whatsappStatus",
74
75
  * ],
75
76
  * };
76
77
  * const command = new PartialUpdateChannelCommand(input);
@@ -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
+ }
@@ -64,6 +64,7 @@ declare const UpdateChannelCommand_base: {
64
64
  * broadcastId: "STRING_VALUE",
65
65
  * },
66
66
  * },
67
+ * whatsappStatus: "24h_channel_closed",
67
68
  * channelId: "STRING_VALUE", // required
68
69
  * userId: "STRING_VALUE",
69
70
  * silent: true || false,
@@ -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";
@@ -764,6 +764,7 @@ export interface CreateGroupChannelInput {
764
764
  * @public
765
765
  */
766
766
  context?: ChannelContext | undefined;
767
+ whatsappStatus?: ChannelWhatsAppStatus | undefined;
767
768
  /**
768
769
  * The unique identifier of the user when a service token is used.
769
770
  * @public
@@ -2397,6 +2398,7 @@ export interface PartialUpdateChannelSetOptions {
2397
2398
  * @public
2398
2399
  */
2399
2400
  context?: ChannelContext | undefined;
2401
+ whatsappStatus?: ChannelWhatsAppStatus | undefined;
2400
2402
  }
2401
2403
  /**
2402
2404
  * @public
@@ -2412,6 +2414,7 @@ export declare const GroupChannelUnsetOptions: {
2412
2414
  readonly PICTURE: "picture";
2413
2415
  readonly PICTURE_COLOR: "pictureColor";
2414
2416
  readonly SUBJECT: "subject";
2417
+ readonly WHATSAPP_STATUS: "whatsappStatus";
2415
2418
  };
2416
2419
  /**
2417
2420
  * @public
@@ -2785,6 +2788,62 @@ export interface SendMessageReactionInput {
2785
2788
  */
2786
2789
  export interface SendMessageReactionOutput {
2787
2790
  }
2791
+ /**
2792
+ * @public
2793
+ */
2794
+ export interface WhatsAppClosedSystemMessage {
2795
+ }
2796
+ /**
2797
+ * @public
2798
+ */
2799
+ export type SystemMessage = SystemMessage.WhatsAppClosedMember | SystemMessage.$UnknownMember;
2800
+ /**
2801
+ * @public
2802
+ */
2803
+ export declare namespace SystemMessage {
2804
+ /**
2805
+ * A message indicating that the WhatsApp channel has been closed after 24 hours. This message type has empty payload.
2806
+ * @public
2807
+ */
2808
+ interface WhatsAppClosedMember {
2809
+ whatsAppClosed: WhatsAppClosedSystemMessage;
2810
+ $unknown?: never;
2811
+ }
2812
+ /**
2813
+ * @public
2814
+ */
2815
+ interface $UnknownMember {
2816
+ whatsAppClosed?: never;
2817
+ $unknown: [string, any];
2818
+ }
2819
+ interface Visitor<T> {
2820
+ whatsAppClosed: (value: WhatsAppClosedSystemMessage) => T;
2821
+ _: (name: string, value: any) => T;
2822
+ }
2823
+ const visit: <T>(value: SystemMessage, visitor: Visitor<T>) => T;
2824
+ }
2825
+ /**
2826
+ * @public
2827
+ */
2828
+ export interface SendSystemMessageInput {
2829
+ /**
2830
+ * The unique identifier of the channel to which the message is sent.
2831
+ * @public
2832
+ */
2833
+ channelId: string;
2834
+ /**
2835
+ * The unique identifier of the user when a service token is used.
2836
+ * @public
2837
+ */
2838
+ userId?: string | undefined;
2839
+ message: SystemMessage;
2840
+ }
2841
+ /**
2842
+ * @public
2843
+ */
2844
+ export interface SendSystemMessageOutput {
2845
+ message: Message;
2846
+ }
2788
2847
  /**
2789
2848
  * @public
2790
2849
  */
@@ -3038,6 +3097,7 @@ export interface UpdateChannelInput {
3038
3097
  * @public
3039
3098
  */
3040
3099
  context?: ChannelContext | undefined;
3100
+ whatsappStatus?: ChannelWhatsAppStatus | undefined;
3041
3101
  /**
3042
3102
  * The unique identifier of the channel to be updated.
3043
3103
  * @public
@@ -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.19",
4
+ "version": "1.1.21",
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
+ }