@wildix/xbees-conversations-client 1.0.63 → 1.0.65
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist-cjs/Conversations.js +6 -0
- package/dist-cjs/commands/ListPinnedMessagesCommand.js +21 -0
- package/dist-cjs/commands/PinMessageCommand.js +21 -0
- package/dist-cjs/commands/UnpinMessageCommand.js +21 -0
- package/dist-cjs/commands/index.js +3 -0
- package/dist-cjs/models/models_0.js +2 -0
- package/dist-cjs/protocols/Aws_restJson1.js +101 -2
- package/dist-es/Conversations.js +6 -0
- package/dist-es/commands/ListPinnedMessagesCommand.js +17 -0
- package/dist-es/commands/PinMessageCommand.js +17 -0
- package/dist-es/commands/UnpinMessageCommand.js +17 -0
- package/dist-es/commands/index.js +3 -0
- package/dist-es/models/models_0.js +2 -0
- package/dist-es/protocols/Aws_restJson1.js +92 -0
- package/dist-types/Conversations.d.ts +21 -0
- package/dist-types/ConversationsClient.d.ts +5 -2
- package/dist-types/commands/ListPinnedMessagesCommand.d.ts +261 -0
- package/dist-types/commands/PartialUpdateMessageCommand.d.ts +5 -1
- package/dist-types/commands/PinMessageCommand.d.ts +73 -0
- package/dist-types/commands/UnpinMessageCommand.d.ts +71 -0
- package/dist-types/commands/UpdateMessageCommand.d.ts +1 -0
- package/dist-types/commands/index.d.ts +3 -0
- package/dist-types/models/models_0.d.ts +110 -1
- package/dist-types/protocols/Aws_restJson1.d.ts +27 -0
- package/package.json +1 -1
|
@@ -31,11 +31,13 @@ const ListInboxTaggedChannelsCommand_1 = require("./commands/ListInboxTaggedChan
|
|
|
31
31
|
const ListInboxTagsCommand_1 = require("./commands/ListInboxTagsCommand");
|
|
32
32
|
const ListMessageReactionsCommand_1 = require("./commands/ListMessageReactionsCommand");
|
|
33
33
|
const ListMessagesCommand_1 = require("./commands/ListMessagesCommand");
|
|
34
|
+
const ListPinnedMessagesCommand_1 = require("./commands/ListPinnedMessagesCommand");
|
|
34
35
|
const MarkReadCommand_1 = require("./commands/MarkReadCommand");
|
|
35
36
|
const MarkUnreadCommand_1 = require("./commands/MarkUnreadCommand");
|
|
36
37
|
const PartialUpdateChannelCommand_1 = require("./commands/PartialUpdateChannelCommand");
|
|
37
38
|
const PartialUpdateMessageCommand_1 = require("./commands/PartialUpdateMessageCommand");
|
|
38
39
|
const PinChannelCommand_1 = require("./commands/PinChannelCommand");
|
|
40
|
+
const PinMessageCommand_1 = require("./commands/PinMessageCommand");
|
|
39
41
|
const ScheduleExternalFlagAdjustmentJobCommand_1 = require("./commands/ScheduleExternalFlagAdjustmentJobCommand");
|
|
40
42
|
const SendActionTriggerResultCommand_1 = require("./commands/SendActionTriggerResultCommand");
|
|
41
43
|
const SendGiphyCommand_1 = require("./commands/SendGiphyCommand");
|
|
@@ -47,6 +49,7 @@ const ShowChannelCommand_1 = require("./commands/ShowChannelCommand");
|
|
|
47
49
|
const TagChannelCommand_1 = require("./commands/TagChannelCommand");
|
|
48
50
|
const TriggerMessageActionCommand_1 = require("./commands/TriggerMessageActionCommand");
|
|
49
51
|
const UnpinChannelCommand_1 = require("./commands/UnpinChannelCommand");
|
|
52
|
+
const UnpinMessageCommand_1 = require("./commands/UnpinMessageCommand");
|
|
50
53
|
const UntagChannelCommand_1 = require("./commands/UntagChannelCommand");
|
|
51
54
|
const UpdateChannelCommand_1 = require("./commands/UpdateChannelCommand");
|
|
52
55
|
const UpdateInboxTagCommand_1 = require("./commands/UpdateInboxTagCommand");
|
|
@@ -83,11 +86,13 @@ const commands = {
|
|
|
83
86
|
ListInboxTagsCommand: ListInboxTagsCommand_1.ListInboxTagsCommand,
|
|
84
87
|
ListMessageReactionsCommand: ListMessageReactionsCommand_1.ListMessageReactionsCommand,
|
|
85
88
|
ListMessagesCommand: ListMessagesCommand_1.ListMessagesCommand,
|
|
89
|
+
ListPinnedMessagesCommand: ListPinnedMessagesCommand_1.ListPinnedMessagesCommand,
|
|
86
90
|
MarkReadCommand: MarkReadCommand_1.MarkReadCommand,
|
|
87
91
|
MarkUnreadCommand: MarkUnreadCommand_1.MarkUnreadCommand,
|
|
88
92
|
PartialUpdateChannelCommand: PartialUpdateChannelCommand_1.PartialUpdateChannelCommand,
|
|
89
93
|
PartialUpdateMessageCommand: PartialUpdateMessageCommand_1.PartialUpdateMessageCommand,
|
|
90
94
|
PinChannelCommand: PinChannelCommand_1.PinChannelCommand,
|
|
95
|
+
PinMessageCommand: PinMessageCommand_1.PinMessageCommand,
|
|
91
96
|
ScheduleExternalFlagAdjustmentJobCommand: ScheduleExternalFlagAdjustmentJobCommand_1.ScheduleExternalFlagAdjustmentJobCommand,
|
|
92
97
|
SendActionTriggerResultCommand: SendActionTriggerResultCommand_1.SendActionTriggerResultCommand,
|
|
93
98
|
SendGiphyCommand: SendGiphyCommand_1.SendGiphyCommand,
|
|
@@ -99,6 +104,7 @@ const commands = {
|
|
|
99
104
|
TagChannelCommand: TagChannelCommand_1.TagChannelCommand,
|
|
100
105
|
TriggerMessageActionCommand: TriggerMessageActionCommand_1.TriggerMessageActionCommand,
|
|
101
106
|
UnpinChannelCommand: UnpinChannelCommand_1.UnpinChannelCommand,
|
|
107
|
+
UnpinMessageCommand: UnpinMessageCommand_1.UnpinMessageCommand,
|
|
102
108
|
UntagChannelCommand: UntagChannelCommand_1.UntagChannelCommand,
|
|
103
109
|
UpdateChannelCommand: UpdateChannelCommand_1.UpdateChannelCommand,
|
|
104
110
|
UpdateInboxTagCommand: UpdateInboxTagCommand_1.UpdateInboxTagCommand,
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ListPinnedMessagesCommand = 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 ListPinnedMessagesCommand 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", "ListPinnedMessages", {})
|
|
15
|
+
.n("ConversationsClient", "ListPinnedMessagesCommand")
|
|
16
|
+
.f(void 0, void 0)
|
|
17
|
+
.ser(Aws_restJson1_1.se_ListPinnedMessagesCommand)
|
|
18
|
+
.de(Aws_restJson1_1.de_ListPinnedMessagesCommand)
|
|
19
|
+
.build() {
|
|
20
|
+
}
|
|
21
|
+
exports.ListPinnedMessagesCommand = ListPinnedMessagesCommand;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.PinMessageCommand = 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 PinMessageCommand 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", "PinMessage", {})
|
|
15
|
+
.n("ConversationsClient", "PinMessageCommand")
|
|
16
|
+
.f(void 0, void 0)
|
|
17
|
+
.ser(Aws_restJson1_1.se_PinMessageCommand)
|
|
18
|
+
.de(Aws_restJson1_1.de_PinMessageCommand)
|
|
19
|
+
.build() {
|
|
20
|
+
}
|
|
21
|
+
exports.PinMessageCommand = PinMessageCommand;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.UnpinMessageCommand = 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 UnpinMessageCommand 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", "UnpinMessage", {})
|
|
15
|
+
.n("ConversationsClient", "UnpinMessageCommand")
|
|
16
|
+
.f(void 0, void 0)
|
|
17
|
+
.ser(Aws_restJson1_1.se_UnpinMessageCommand)
|
|
18
|
+
.de(Aws_restJson1_1.de_UnpinMessageCommand)
|
|
19
|
+
.build() {
|
|
20
|
+
}
|
|
21
|
+
exports.UnpinMessageCommand = UnpinMessageCommand;
|
|
@@ -30,11 +30,13 @@ tslib_1.__exportStar(require("./ListInboxTaggedChannelsCommand"), exports);
|
|
|
30
30
|
tslib_1.__exportStar(require("./ListInboxTagsCommand"), exports);
|
|
31
31
|
tslib_1.__exportStar(require("./ListMessageReactionsCommand"), exports);
|
|
32
32
|
tslib_1.__exportStar(require("./ListMessagesCommand"), exports);
|
|
33
|
+
tslib_1.__exportStar(require("./ListPinnedMessagesCommand"), exports);
|
|
33
34
|
tslib_1.__exportStar(require("./MarkReadCommand"), exports);
|
|
34
35
|
tslib_1.__exportStar(require("./MarkUnreadCommand"), exports);
|
|
35
36
|
tslib_1.__exportStar(require("./PartialUpdateChannelCommand"), exports);
|
|
36
37
|
tslib_1.__exportStar(require("./PartialUpdateMessageCommand"), exports);
|
|
37
38
|
tslib_1.__exportStar(require("./PinChannelCommand"), exports);
|
|
39
|
+
tslib_1.__exportStar(require("./PinMessageCommand"), exports);
|
|
38
40
|
tslib_1.__exportStar(require("./ScheduleExternalFlagAdjustmentJobCommand"), exports);
|
|
39
41
|
tslib_1.__exportStar(require("./SendActionTriggerResultCommand"), exports);
|
|
40
42
|
tslib_1.__exportStar(require("./SendGiphyCommand"), exports);
|
|
@@ -46,6 +48,7 @@ tslib_1.__exportStar(require("./ShowChannelCommand"), exports);
|
|
|
46
48
|
tslib_1.__exportStar(require("./TagChannelCommand"), exports);
|
|
47
49
|
tslib_1.__exportStar(require("./TriggerMessageActionCommand"), exports);
|
|
48
50
|
tslib_1.__exportStar(require("./UnpinChannelCommand"), exports);
|
|
51
|
+
tslib_1.__exportStar(require("./UnpinMessageCommand"), exports);
|
|
49
52
|
tslib_1.__exportStar(require("./UntagChannelCommand"), exports);
|
|
50
53
|
tslib_1.__exportStar(require("./UpdateChannelCommand"), exports);
|
|
51
54
|
tslib_1.__exportStar(require("./UpdateInboxTagCommand"), exports);
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
4
|
-
exports.
|
|
3
|
+
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 = exports.se_SendGiphyCommand = exports.se_SendActionTriggerResultCommand = exports.se_ScheduleExternalFlagAdjustmentJobCommand = exports.se_PinMessageCommand = exports.se_PinChannelCommand = exports.se_PartialUpdateMessageCommand = exports.se_PartialUpdateChannelCommand = exports.se_MarkUnreadCommand = exports.se_MarkReadCommand = exports.se_ListPinnedMessagesCommand = exports.se_ListMessagesCommand = exports.se_ListMessageReactionsCommand = exports.se_ListInboxTagsCommand = exports.se_ListInboxTaggedChannelsCommand = exports.se_ListChannelsCommand = exports.se_ListChannelMembersCommand = exports.se_LeaveChannelCommand = exports.se_JoinChannelCommand = exports.se_InviteCommand = exports.se_HideChannelCommand = exports.se_GetUploadedFileInfoCommand = exports.se_GetOrCreateDirectChannelCommand = exports.se_GetMessageCommand = exports.se_GetInboxStateCommand = exports.se_GetFilePresignedDownloadUrlCommand = exports.se_GetDirectChannelIdCommand = exports.se_GetChannelMemberCommand = exports.se_GetChannelCommand = exports.se_GetActionTriggerResultCommand = exports.se_DescribeEventCommand = exports.se_DeleteMessageReactionCommand = exports.se_DeleteMessageCommand = exports.se_DeleteInboxTagCommand = exports.se_DeleteChannelMemberCommand = exports.se_DeleteChannelCommand = exports.se_CreateInboxTagCommand = exports.se_CreateGroupChannelCommand = exports.se_AddChannelMembersCommand = exports.se_AddChannelMemberCommand = void 0;
|
|
4
|
+
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_PinMessageCommand = exports.de_PinChannelCommand = exports.de_PartialUpdateMessageCommand = exports.de_PartialUpdateChannelCommand = exports.de_MarkUnreadCommand = exports.de_MarkReadCommand = exports.de_ListPinnedMessagesCommand = exports.de_ListMessagesCommand = exports.de_ListMessageReactionsCommand = exports.de_ListInboxTagsCommand = exports.de_ListInboxTaggedChannelsCommand = exports.de_ListChannelsCommand = exports.de_ListChannelMembersCommand = exports.de_LeaveChannelCommand = exports.de_JoinChannelCommand = exports.de_InviteCommand = exports.de_HideChannelCommand = exports.de_GetUploadedFileInfoCommand = exports.de_GetOrCreateDirectChannelCommand = exports.de_GetMessageCommand = exports.de_GetInboxStateCommand = exports.de_GetFilePresignedDownloadUrlCommand = exports.de_GetDirectChannelIdCommand = exports.de_GetChannelMemberCommand = exports.de_GetChannelCommand = exports.de_GetActionTriggerResultCommand = exports.de_DescribeEventCommand = exports.de_DeleteMessageReactionCommand = exports.de_DeleteMessageCommand = exports.de_DeleteInboxTagCommand = exports.de_DeleteChannelMemberCommand = exports.de_DeleteChannelCommand = exports.de_CreateInboxTagCommand = exports.de_CreateGroupChannelCommand = exports.de_AddChannelMembersCommand = exports.de_AddChannelMemberCommand = exports.se_UploadFileCommand = exports.se_UpdateMessageCommand = exports.se_UpdateInboxTagCommand = void 0;
|
|
5
|
+
exports.de_UploadFileCommand = exports.de_UpdateMessageCommand = exports.de_UpdateInboxTagCommand = exports.de_UpdateChannelCommand = exports.de_UntagChannelCommand = exports.de_UnpinMessageCommand = void 0;
|
|
5
6
|
const ConversationsServiceException_1 = require("../models/ConversationsServiceException");
|
|
6
7
|
const models_0_1 = require("../models/models_0");
|
|
7
8
|
const core_1 = require("@smithy/core");
|
|
@@ -517,6 +518,23 @@ const se_ListMessagesCommand = async (input, context) => {
|
|
|
517
518
|
return b.build();
|
|
518
519
|
};
|
|
519
520
|
exports.se_ListMessagesCommand = se_ListMessagesCommand;
|
|
521
|
+
const se_ListPinnedMessagesCommand = async (input, context) => {
|
|
522
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
523
|
+
const headers = {};
|
|
524
|
+
b.bp("/v2/conversations/channels/{channelId}/pinned_messages");
|
|
525
|
+
b.p('channelId', () => input.channelId, '{channelId}', false);
|
|
526
|
+
const query = (0, smithy_client_1.map)({
|
|
527
|
+
[_l]: [() => input.limit !== void 0, () => (input[_l].toString())],
|
|
528
|
+
[_o]: [() => input.offset !== void 0, () => (input[_o].toString())],
|
|
529
|
+
});
|
|
530
|
+
let body;
|
|
531
|
+
b.m("GET")
|
|
532
|
+
.h(headers)
|
|
533
|
+
.q(query)
|
|
534
|
+
.b(body);
|
|
535
|
+
return b.build();
|
|
536
|
+
};
|
|
537
|
+
exports.se_ListPinnedMessagesCommand = se_ListPinnedMessagesCommand;
|
|
520
538
|
const se_MarkReadCommand = async (input, context) => {
|
|
521
539
|
const b = (0, core_1.requestBuilder)(input, context);
|
|
522
540
|
const headers = {};
|
|
@@ -592,6 +610,7 @@ const se_PartialUpdateMessageCommand = async (input, context) => {
|
|
|
592
610
|
let body;
|
|
593
611
|
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
594
612
|
'set': _ => (0, smithy_client_1._json)(_),
|
|
613
|
+
'silent': [],
|
|
595
614
|
'unset': _ => (0, smithy_client_1._json)(_),
|
|
596
615
|
}));
|
|
597
616
|
b.m("PATCH")
|
|
@@ -618,6 +637,30 @@ const se_PinChannelCommand = async (input, context) => {
|
|
|
618
637
|
return b.build();
|
|
619
638
|
};
|
|
620
639
|
exports.se_PinChannelCommand = se_PinChannelCommand;
|
|
640
|
+
const se_PinMessageCommand = async (input, context) => {
|
|
641
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
642
|
+
const headers = {
|
|
643
|
+
'content-type': 'application/json',
|
|
644
|
+
};
|
|
645
|
+
b.bp("/v2/conversations/channels/{channelId}/messages/{messageId}/pin");
|
|
646
|
+
b.p('channelId', () => input.channelId, '{channelId}', false);
|
|
647
|
+
b.p('messageId', () => input.messageId, '{messageId}', false);
|
|
648
|
+
const query = (0, smithy_client_1.map)({
|
|
649
|
+
[_u]: [, input[_uI]],
|
|
650
|
+
});
|
|
651
|
+
let body;
|
|
652
|
+
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
653
|
+
'expiresAfter': [],
|
|
654
|
+
'expiresTill': [],
|
|
655
|
+
'silent': [],
|
|
656
|
+
}));
|
|
657
|
+
b.m("PUT")
|
|
658
|
+
.h(headers)
|
|
659
|
+
.q(query)
|
|
660
|
+
.b(body);
|
|
661
|
+
return b.build();
|
|
662
|
+
};
|
|
663
|
+
exports.se_PinMessageCommand = se_PinMessageCommand;
|
|
621
664
|
const se_ScheduleExternalFlagAdjustmentJobCommand = async (input, context) => {
|
|
622
665
|
const b = (0, core_1.requestBuilder)(input, context);
|
|
623
666
|
const headers = {
|
|
@@ -823,6 +866,24 @@ const se_UnpinChannelCommand = async (input, context) => {
|
|
|
823
866
|
return b.build();
|
|
824
867
|
};
|
|
825
868
|
exports.se_UnpinChannelCommand = se_UnpinChannelCommand;
|
|
869
|
+
const se_UnpinMessageCommand = async (input, context) => {
|
|
870
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
871
|
+
const headers = {};
|
|
872
|
+
b.bp("/v2/conversations/channels/{channelId}/messages/{messageId}/pin");
|
|
873
|
+
b.p('channelId', () => input.channelId, '{channelId}', false);
|
|
874
|
+
b.p('messageId', () => input.messageId, '{messageId}', false);
|
|
875
|
+
const query = (0, smithy_client_1.map)({
|
|
876
|
+
[_u]: [, input[_uI]],
|
|
877
|
+
[_s]: [() => input.silent !== void 0, () => (input[_s].toString())],
|
|
878
|
+
});
|
|
879
|
+
let body;
|
|
880
|
+
b.m("DELETE")
|
|
881
|
+
.h(headers)
|
|
882
|
+
.q(query)
|
|
883
|
+
.b(body);
|
|
884
|
+
return b.build();
|
|
885
|
+
};
|
|
886
|
+
exports.se_UnpinMessageCommand = se_UnpinMessageCommand;
|
|
826
887
|
const se_UntagChannelCommand = async (input, context) => {
|
|
827
888
|
const b = (0, core_1.requestBuilder)(input, context);
|
|
828
889
|
const headers = {
|
|
@@ -910,6 +971,7 @@ const se_UpdateMessageCommand = async (input, context) => {
|
|
|
910
971
|
'forward': _ => (0, smithy_client_1._json)(_),
|
|
911
972
|
'mentions': _ => (0, smithy_client_1._json)(_),
|
|
912
973
|
'quote': _ => (0, smithy_client_1._json)(_),
|
|
974
|
+
'silent': [],
|
|
913
975
|
'text': [],
|
|
914
976
|
}));
|
|
915
977
|
b.m("PUT")
|
|
@@ -1363,6 +1425,21 @@ const de_ListMessagesCommand = async (output, context) => {
|
|
|
1363
1425
|
return contents;
|
|
1364
1426
|
};
|
|
1365
1427
|
exports.de_ListMessagesCommand = de_ListMessagesCommand;
|
|
1428
|
+
const de_ListPinnedMessagesCommand = async (output, context) => {
|
|
1429
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1430
|
+
return de_CommandError(output, context);
|
|
1431
|
+
}
|
|
1432
|
+
const contents = (0, smithy_client_1.map)({
|
|
1433
|
+
$metadata: deserializeMetadata(output),
|
|
1434
|
+
});
|
|
1435
|
+
const data = (0, smithy_client_1.expectNonNull)(((0, smithy_client_1.expectObject)(await parseBody(output.body, context))), "body");
|
|
1436
|
+
const doc = (0, smithy_client_1.take)(data, {
|
|
1437
|
+
'messages': smithy_client_1._json,
|
|
1438
|
+
});
|
|
1439
|
+
Object.assign(contents, doc);
|
|
1440
|
+
return contents;
|
|
1441
|
+
};
|
|
1442
|
+
exports.de_ListPinnedMessagesCommand = de_ListPinnedMessagesCommand;
|
|
1366
1443
|
const de_MarkReadCommand = async (output, context) => {
|
|
1367
1444
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1368
1445
|
return de_CommandError(output, context);
|
|
@@ -1426,6 +1503,17 @@ const de_PinChannelCommand = async (output, context) => {
|
|
|
1426
1503
|
return contents;
|
|
1427
1504
|
};
|
|
1428
1505
|
exports.de_PinChannelCommand = de_PinChannelCommand;
|
|
1506
|
+
const de_PinMessageCommand = async (output, context) => {
|
|
1507
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1508
|
+
return de_CommandError(output, context);
|
|
1509
|
+
}
|
|
1510
|
+
const contents = (0, smithy_client_1.map)({
|
|
1511
|
+
$metadata: deserializeMetadata(output),
|
|
1512
|
+
});
|
|
1513
|
+
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
1514
|
+
return contents;
|
|
1515
|
+
};
|
|
1516
|
+
exports.de_PinMessageCommand = de_PinMessageCommand;
|
|
1429
1517
|
const de_ScheduleExternalFlagAdjustmentJobCommand = async (output, context) => {
|
|
1430
1518
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1431
1519
|
return de_CommandError(output, context);
|
|
@@ -1559,6 +1647,17 @@ const de_UnpinChannelCommand = async (output, context) => {
|
|
|
1559
1647
|
return contents;
|
|
1560
1648
|
};
|
|
1561
1649
|
exports.de_UnpinChannelCommand = de_UnpinChannelCommand;
|
|
1650
|
+
const de_UnpinMessageCommand = async (output, context) => {
|
|
1651
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1652
|
+
return de_CommandError(output, context);
|
|
1653
|
+
}
|
|
1654
|
+
const contents = (0, smithy_client_1.map)({
|
|
1655
|
+
$metadata: deserializeMetadata(output),
|
|
1656
|
+
});
|
|
1657
|
+
await (0, smithy_client_1.collectBody)(output.body, context);
|
|
1658
|
+
return contents;
|
|
1659
|
+
};
|
|
1660
|
+
exports.de_UnpinMessageCommand = de_UnpinMessageCommand;
|
|
1562
1661
|
const de_UntagChannelCommand = async (output, context) => {
|
|
1563
1662
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1564
1663
|
return de_CommandError(output, context);
|
package/dist-es/Conversations.js
CHANGED
|
@@ -28,11 +28,13 @@ import { ListInboxTaggedChannelsCommand, } from "./commands/ListInboxTaggedChann
|
|
|
28
28
|
import { ListInboxTagsCommand, } from "./commands/ListInboxTagsCommand";
|
|
29
29
|
import { ListMessageReactionsCommand, } from "./commands/ListMessageReactionsCommand";
|
|
30
30
|
import { ListMessagesCommand, } from "./commands/ListMessagesCommand";
|
|
31
|
+
import { ListPinnedMessagesCommand, } from "./commands/ListPinnedMessagesCommand";
|
|
31
32
|
import { MarkReadCommand, } from "./commands/MarkReadCommand";
|
|
32
33
|
import { MarkUnreadCommand, } from "./commands/MarkUnreadCommand";
|
|
33
34
|
import { PartialUpdateChannelCommand, } from "./commands/PartialUpdateChannelCommand";
|
|
34
35
|
import { PartialUpdateMessageCommand, } from "./commands/PartialUpdateMessageCommand";
|
|
35
36
|
import { PinChannelCommand, } from "./commands/PinChannelCommand";
|
|
37
|
+
import { PinMessageCommand, } from "./commands/PinMessageCommand";
|
|
36
38
|
import { ScheduleExternalFlagAdjustmentJobCommand, } from "./commands/ScheduleExternalFlagAdjustmentJobCommand";
|
|
37
39
|
import { SendActionTriggerResultCommand, } from "./commands/SendActionTriggerResultCommand";
|
|
38
40
|
import { SendGiphyCommand, } from "./commands/SendGiphyCommand";
|
|
@@ -44,6 +46,7 @@ import { ShowChannelCommand, } from "./commands/ShowChannelCommand";
|
|
|
44
46
|
import { TagChannelCommand, } from "./commands/TagChannelCommand";
|
|
45
47
|
import { TriggerMessageActionCommand, } from "./commands/TriggerMessageActionCommand";
|
|
46
48
|
import { UnpinChannelCommand, } from "./commands/UnpinChannelCommand";
|
|
49
|
+
import { UnpinMessageCommand, } from "./commands/UnpinMessageCommand";
|
|
47
50
|
import { UntagChannelCommand, } from "./commands/UntagChannelCommand";
|
|
48
51
|
import { UpdateChannelCommand, } from "./commands/UpdateChannelCommand";
|
|
49
52
|
import { UpdateInboxTagCommand, } from "./commands/UpdateInboxTagCommand";
|
|
@@ -80,11 +83,13 @@ const commands = {
|
|
|
80
83
|
ListInboxTagsCommand,
|
|
81
84
|
ListMessageReactionsCommand,
|
|
82
85
|
ListMessagesCommand,
|
|
86
|
+
ListPinnedMessagesCommand,
|
|
83
87
|
MarkReadCommand,
|
|
84
88
|
MarkUnreadCommand,
|
|
85
89
|
PartialUpdateChannelCommand,
|
|
86
90
|
PartialUpdateMessageCommand,
|
|
87
91
|
PinChannelCommand,
|
|
92
|
+
PinMessageCommand,
|
|
88
93
|
ScheduleExternalFlagAdjustmentJobCommand,
|
|
89
94
|
SendActionTriggerResultCommand,
|
|
90
95
|
SendGiphyCommand,
|
|
@@ -96,6 +101,7 @@ const commands = {
|
|
|
96
101
|
TagChannelCommand,
|
|
97
102
|
TriggerMessageActionCommand,
|
|
98
103
|
UnpinChannelCommand,
|
|
104
|
+
UnpinMessageCommand,
|
|
99
105
|
UntagChannelCommand,
|
|
100
106
|
UpdateChannelCommand,
|
|
101
107
|
UpdateInboxTagCommand,
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { de_ListPinnedMessagesCommand, se_ListPinnedMessagesCommand, } 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 ListPinnedMessagesCommand extends $Command.classBuilder()
|
|
6
|
+
.m(function (Command, cs, config, o) {
|
|
7
|
+
return [
|
|
8
|
+
getSerdePlugin(config, this.serialize, this.deserialize),
|
|
9
|
+
];
|
|
10
|
+
})
|
|
11
|
+
.s("Conversations", "ListPinnedMessages", {})
|
|
12
|
+
.n("ConversationsClient", "ListPinnedMessagesCommand")
|
|
13
|
+
.f(void 0, void 0)
|
|
14
|
+
.ser(se_ListPinnedMessagesCommand)
|
|
15
|
+
.de(de_ListPinnedMessagesCommand)
|
|
16
|
+
.build() {
|
|
17
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { de_PinMessageCommand, se_PinMessageCommand, } 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 PinMessageCommand extends $Command.classBuilder()
|
|
6
|
+
.m(function (Command, cs, config, o) {
|
|
7
|
+
return [
|
|
8
|
+
getSerdePlugin(config, this.serialize, this.deserialize),
|
|
9
|
+
];
|
|
10
|
+
})
|
|
11
|
+
.s("Conversations", "PinMessage", {})
|
|
12
|
+
.n("ConversationsClient", "PinMessageCommand")
|
|
13
|
+
.f(void 0, void 0)
|
|
14
|
+
.ser(se_PinMessageCommand)
|
|
15
|
+
.de(de_PinMessageCommand)
|
|
16
|
+
.build() {
|
|
17
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { de_UnpinMessageCommand, se_UnpinMessageCommand, } 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 UnpinMessageCommand extends $Command.classBuilder()
|
|
6
|
+
.m(function (Command, cs, config, o) {
|
|
7
|
+
return [
|
|
8
|
+
getSerdePlugin(config, this.serialize, this.deserialize),
|
|
9
|
+
];
|
|
10
|
+
})
|
|
11
|
+
.s("Conversations", "UnpinMessage", {})
|
|
12
|
+
.n("ConversationsClient", "UnpinMessageCommand")
|
|
13
|
+
.f(void 0, void 0)
|
|
14
|
+
.ser(se_UnpinMessageCommand)
|
|
15
|
+
.de(de_UnpinMessageCommand)
|
|
16
|
+
.build() {
|
|
17
|
+
}
|
|
@@ -27,11 +27,13 @@ export * from "./ListInboxTaggedChannelsCommand";
|
|
|
27
27
|
export * from "./ListInboxTagsCommand";
|
|
28
28
|
export * from "./ListMessageReactionsCommand";
|
|
29
29
|
export * from "./ListMessagesCommand";
|
|
30
|
+
export * from "./ListPinnedMessagesCommand";
|
|
30
31
|
export * from "./MarkReadCommand";
|
|
31
32
|
export * from "./MarkUnreadCommand";
|
|
32
33
|
export * from "./PartialUpdateChannelCommand";
|
|
33
34
|
export * from "./PartialUpdateMessageCommand";
|
|
34
35
|
export * from "./PinChannelCommand";
|
|
36
|
+
export * from "./PinMessageCommand";
|
|
35
37
|
export * from "./ScheduleExternalFlagAdjustmentJobCommand";
|
|
36
38
|
export * from "./SendActionTriggerResultCommand";
|
|
37
39
|
export * from "./SendGiphyCommand";
|
|
@@ -43,6 +45,7 @@ export * from "./ShowChannelCommand";
|
|
|
43
45
|
export * from "./TagChannelCommand";
|
|
44
46
|
export * from "./TriggerMessageActionCommand";
|
|
45
47
|
export * from "./UnpinChannelCommand";
|
|
48
|
+
export * from "./UnpinMessageCommand";
|
|
46
49
|
export * from "./UntagChannelCommand";
|
|
47
50
|
export * from "./UpdateChannelCommand";
|
|
48
51
|
export * from "./UpdateInboxTagCommand";
|
|
@@ -484,6 +484,22 @@ export const se_ListMessagesCommand = async (input, context) => {
|
|
|
484
484
|
.b(body);
|
|
485
485
|
return b.build();
|
|
486
486
|
};
|
|
487
|
+
export const se_ListPinnedMessagesCommand = async (input, context) => {
|
|
488
|
+
const b = rb(input, context);
|
|
489
|
+
const headers = {};
|
|
490
|
+
b.bp("/v2/conversations/channels/{channelId}/pinned_messages");
|
|
491
|
+
b.p('channelId', () => input.channelId, '{channelId}', false);
|
|
492
|
+
const query = map({
|
|
493
|
+
[_l]: [() => input.limit !== void 0, () => (input[_l].toString())],
|
|
494
|
+
[_o]: [() => input.offset !== void 0, () => (input[_o].toString())],
|
|
495
|
+
});
|
|
496
|
+
let body;
|
|
497
|
+
b.m("GET")
|
|
498
|
+
.h(headers)
|
|
499
|
+
.q(query)
|
|
500
|
+
.b(body);
|
|
501
|
+
return b.build();
|
|
502
|
+
};
|
|
487
503
|
export const se_MarkReadCommand = async (input, context) => {
|
|
488
504
|
const b = rb(input, context);
|
|
489
505
|
const headers = {};
|
|
@@ -556,6 +572,7 @@ export const se_PartialUpdateMessageCommand = async (input, context) => {
|
|
|
556
572
|
let body;
|
|
557
573
|
body = JSON.stringify(take(input, {
|
|
558
574
|
'set': _ => _json(_),
|
|
575
|
+
'silent': [],
|
|
559
576
|
'unset': _ => _json(_),
|
|
560
577
|
}));
|
|
561
578
|
b.m("PATCH")
|
|
@@ -580,6 +597,29 @@ export const se_PinChannelCommand = async (input, context) => {
|
|
|
580
597
|
.b(body);
|
|
581
598
|
return b.build();
|
|
582
599
|
};
|
|
600
|
+
export const se_PinMessageCommand = async (input, context) => {
|
|
601
|
+
const b = rb(input, context);
|
|
602
|
+
const headers = {
|
|
603
|
+
'content-type': 'application/json',
|
|
604
|
+
};
|
|
605
|
+
b.bp("/v2/conversations/channels/{channelId}/messages/{messageId}/pin");
|
|
606
|
+
b.p('channelId', () => input.channelId, '{channelId}', false);
|
|
607
|
+
b.p('messageId', () => input.messageId, '{messageId}', false);
|
|
608
|
+
const query = map({
|
|
609
|
+
[_u]: [, input[_uI]],
|
|
610
|
+
});
|
|
611
|
+
let body;
|
|
612
|
+
body = JSON.stringify(take(input, {
|
|
613
|
+
'expiresAfter': [],
|
|
614
|
+
'expiresTill': [],
|
|
615
|
+
'silent': [],
|
|
616
|
+
}));
|
|
617
|
+
b.m("PUT")
|
|
618
|
+
.h(headers)
|
|
619
|
+
.q(query)
|
|
620
|
+
.b(body);
|
|
621
|
+
return b.build();
|
|
622
|
+
};
|
|
583
623
|
export const se_ScheduleExternalFlagAdjustmentJobCommand = async (input, context) => {
|
|
584
624
|
const b = rb(input, context);
|
|
585
625
|
const headers = {
|
|
@@ -774,6 +814,23 @@ export const se_UnpinChannelCommand = async (input, context) => {
|
|
|
774
814
|
.b(body);
|
|
775
815
|
return b.build();
|
|
776
816
|
};
|
|
817
|
+
export const se_UnpinMessageCommand = async (input, context) => {
|
|
818
|
+
const b = rb(input, context);
|
|
819
|
+
const headers = {};
|
|
820
|
+
b.bp("/v2/conversations/channels/{channelId}/messages/{messageId}/pin");
|
|
821
|
+
b.p('channelId', () => input.channelId, '{channelId}', false);
|
|
822
|
+
b.p('messageId', () => input.messageId, '{messageId}', false);
|
|
823
|
+
const query = map({
|
|
824
|
+
[_u]: [, input[_uI]],
|
|
825
|
+
[_s]: [() => input.silent !== void 0, () => (input[_s].toString())],
|
|
826
|
+
});
|
|
827
|
+
let body;
|
|
828
|
+
b.m("DELETE")
|
|
829
|
+
.h(headers)
|
|
830
|
+
.q(query)
|
|
831
|
+
.b(body);
|
|
832
|
+
return b.build();
|
|
833
|
+
};
|
|
777
834
|
export const se_UntagChannelCommand = async (input, context) => {
|
|
778
835
|
const b = rb(input, context);
|
|
779
836
|
const headers = {
|
|
@@ -858,6 +915,7 @@ export const se_UpdateMessageCommand = async (input, context) => {
|
|
|
858
915
|
'forward': _ => _json(_),
|
|
859
916
|
'mentions': _ => _json(_),
|
|
860
917
|
'quote': _ => _json(_),
|
|
918
|
+
'silent': [],
|
|
861
919
|
'text': [],
|
|
862
920
|
}));
|
|
863
921
|
b.m("PUT")
|
|
@@ -1280,6 +1338,20 @@ export const de_ListMessagesCommand = async (output, context) => {
|
|
|
1280
1338
|
Object.assign(contents, doc);
|
|
1281
1339
|
return contents;
|
|
1282
1340
|
};
|
|
1341
|
+
export const de_ListPinnedMessagesCommand = async (output, context) => {
|
|
1342
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1343
|
+
return de_CommandError(output, context);
|
|
1344
|
+
}
|
|
1345
|
+
const contents = map({
|
|
1346
|
+
$metadata: deserializeMetadata(output),
|
|
1347
|
+
});
|
|
1348
|
+
const data = __expectNonNull((__expectObject(await parseBody(output.body, context))), "body");
|
|
1349
|
+
const doc = take(data, {
|
|
1350
|
+
'messages': _json,
|
|
1351
|
+
});
|
|
1352
|
+
Object.assign(contents, doc);
|
|
1353
|
+
return contents;
|
|
1354
|
+
};
|
|
1283
1355
|
export const de_MarkReadCommand = async (output, context) => {
|
|
1284
1356
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1285
1357
|
return de_CommandError(output, context);
|
|
@@ -1338,6 +1410,16 @@ export const de_PinChannelCommand = async (output, context) => {
|
|
|
1338
1410
|
await collectBody(output.body, context);
|
|
1339
1411
|
return contents;
|
|
1340
1412
|
};
|
|
1413
|
+
export const de_PinMessageCommand = async (output, context) => {
|
|
1414
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1415
|
+
return de_CommandError(output, context);
|
|
1416
|
+
}
|
|
1417
|
+
const contents = map({
|
|
1418
|
+
$metadata: deserializeMetadata(output),
|
|
1419
|
+
});
|
|
1420
|
+
await collectBody(output.body, context);
|
|
1421
|
+
return contents;
|
|
1422
|
+
};
|
|
1341
1423
|
export const de_ScheduleExternalFlagAdjustmentJobCommand = async (output, context) => {
|
|
1342
1424
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1343
1425
|
return de_CommandError(output, context);
|
|
@@ -1460,6 +1542,16 @@ export const de_UnpinChannelCommand = async (output, context) => {
|
|
|
1460
1542
|
await collectBody(output.body, context);
|
|
1461
1543
|
return contents;
|
|
1462
1544
|
};
|
|
1545
|
+
export const de_UnpinMessageCommand = async (output, context) => {
|
|
1546
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1547
|
+
return de_CommandError(output, context);
|
|
1548
|
+
}
|
|
1549
|
+
const contents = map({
|
|
1550
|
+
$metadata: deserializeMetadata(output),
|
|
1551
|
+
});
|
|
1552
|
+
await collectBody(output.body, context);
|
|
1553
|
+
return contents;
|
|
1554
|
+
};
|
|
1463
1555
|
export const de_UntagChannelCommand = async (output, context) => {
|
|
1464
1556
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1465
1557
|
return de_CommandError(output, context);
|