stream-chat 8.20.0 → 8.22.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/browser.es.js +331 -286
- package/dist/browser.es.js.map +1 -1
- package/dist/browser.full-bundle.min.js +1 -1
- package/dist/browser.full-bundle.min.js.map +1 -1
- package/dist/browser.js +331 -286
- package/dist/browser.js.map +1 -1
- package/dist/index.es.js +331 -286
- package/dist/index.es.js.map +1 -1
- package/dist/index.js +331 -286
- package/dist/index.js.map +1 -1
- package/dist/types/channel.d.ts.map +1 -1
- package/dist/types/client.d.ts +15 -0
- package/dist/types/client.d.ts.map +1 -1
- package/dist/types/events.d.ts +1 -0
- package/dist/types/events.d.ts.map +1 -1
- package/dist/types/types.d.ts +2 -0
- package/dist/types/types.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/channel.ts +1 -0
- package/src/client.ts +19 -0
- package/src/events.ts +1 -0
- package/src/types.ts +2 -0
package/dist/index.es.js
CHANGED
|
@@ -3794,6 +3794,7 @@ var Channel = /*#__PURE__*/function () {
|
|
|
3794
3794
|
break;
|
|
3795
3795
|
|
|
3796
3796
|
case 'message.updated':
|
|
3797
|
+
case 'message.undeleted':
|
|
3797
3798
|
if (event.message) {
|
|
3798
3799
|
this._extendEventWithOwnReactions(event);
|
|
3799
3800
|
|
|
@@ -10856,16 +10857,31 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10856
10857
|
|
|
10857
10858
|
return deleteMessage;
|
|
10858
10859
|
}()
|
|
10860
|
+
/**
|
|
10861
|
+
* undeleteMessage - Undelete a message
|
|
10862
|
+
*
|
|
10863
|
+
* undeletes a message that was previous soft deleted. Hard deleted messages
|
|
10864
|
+
* cannot be undeleted. This is only allowed to be called from server-side
|
|
10865
|
+
* clients.
|
|
10866
|
+
*
|
|
10867
|
+
* @param {string} messageID The id of the message to undelete
|
|
10868
|
+
* @param {string} userID The id of the user who undeleted the message
|
|
10869
|
+
*
|
|
10870
|
+
* @return {{ message: MessageResponse<StreamChatGenerics> }} Response that includes the message
|
|
10871
|
+
*/
|
|
10872
|
+
|
|
10859
10873
|
}, {
|
|
10860
|
-
key: "
|
|
10874
|
+
key: "undeleteMessage",
|
|
10861
10875
|
value: function () {
|
|
10862
|
-
var
|
|
10876
|
+
var _undeleteMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee58(messageID, userID) {
|
|
10863
10877
|
return _regeneratorRuntime.wrap(function _callee58$(_context58) {
|
|
10864
10878
|
while (1) {
|
|
10865
10879
|
switch (_context58.prev = _context58.next) {
|
|
10866
10880
|
case 0:
|
|
10867
10881
|
_context58.next = 2;
|
|
10868
|
-
return this.
|
|
10882
|
+
return this.post(this.baseURL + "/messages/".concat(messageID, "/undelete"), {
|
|
10883
|
+
undeleted_by: userID
|
|
10884
|
+
});
|
|
10869
10885
|
|
|
10870
10886
|
case 2:
|
|
10871
10887
|
return _context58.abrupt("return", _context58.sent);
|
|
@@ -10878,7 +10894,35 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10878
10894
|
}, _callee58, this);
|
|
10879
10895
|
}));
|
|
10880
10896
|
|
|
10881
|
-
function
|
|
10897
|
+
function undeleteMessage(_x77, _x78) {
|
|
10898
|
+
return _undeleteMessage.apply(this, arguments);
|
|
10899
|
+
}
|
|
10900
|
+
|
|
10901
|
+
return undeleteMessage;
|
|
10902
|
+
}()
|
|
10903
|
+
}, {
|
|
10904
|
+
key: "getMessage",
|
|
10905
|
+
value: function () {
|
|
10906
|
+
var _getMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee59(messageID, options) {
|
|
10907
|
+
return _regeneratorRuntime.wrap(function _callee59$(_context59) {
|
|
10908
|
+
while (1) {
|
|
10909
|
+
switch (_context59.prev = _context59.next) {
|
|
10910
|
+
case 0:
|
|
10911
|
+
_context59.next = 2;
|
|
10912
|
+
return this.get(this.baseURL + "/messages/".concat(encodeURIComponent(messageID)), _objectSpread({}, options));
|
|
10913
|
+
|
|
10914
|
+
case 2:
|
|
10915
|
+
return _context59.abrupt("return", _context59.sent);
|
|
10916
|
+
|
|
10917
|
+
case 3:
|
|
10918
|
+
case "end":
|
|
10919
|
+
return _context59.stop();
|
|
10920
|
+
}
|
|
10921
|
+
}
|
|
10922
|
+
}, _callee59, this);
|
|
10923
|
+
}));
|
|
10924
|
+
|
|
10925
|
+
function getMessage(_x79, _x80) {
|
|
10882
10926
|
return _getMessage.apply(this, arguments);
|
|
10883
10927
|
}
|
|
10884
10928
|
|
|
@@ -10899,13 +10943,13 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10899
10943
|
}, {
|
|
10900
10944
|
key: "queryThreads",
|
|
10901
10945
|
value: function () {
|
|
10902
|
-
var _queryThreads = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10946
|
+
var _queryThreads = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee60(options) {
|
|
10903
10947
|
var _this5 = this;
|
|
10904
10948
|
|
|
10905
10949
|
var opts, res;
|
|
10906
|
-
return _regeneratorRuntime.wrap(function
|
|
10950
|
+
return _regeneratorRuntime.wrap(function _callee60$(_context60) {
|
|
10907
10951
|
while (1) {
|
|
10908
|
-
switch (
|
|
10952
|
+
switch (_context60.prev = _context60.next) {
|
|
10909
10953
|
case 0:
|
|
10910
10954
|
opts = _objectSpread({
|
|
10911
10955
|
limit: 10,
|
|
@@ -10913,12 +10957,12 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10913
10957
|
reply_limit: 3,
|
|
10914
10958
|
watch: true
|
|
10915
10959
|
}, options);
|
|
10916
|
-
|
|
10960
|
+
_context60.next = 3;
|
|
10917
10961
|
return this.post(this.baseURL + "/threads", opts);
|
|
10918
10962
|
|
|
10919
10963
|
case 3:
|
|
10920
|
-
res =
|
|
10921
|
-
return
|
|
10964
|
+
res = _context60.sent;
|
|
10965
|
+
return _context60.abrupt("return", {
|
|
10922
10966
|
threads: res.threads.map(function (thread) {
|
|
10923
10967
|
return new Thread(_this5, thread);
|
|
10924
10968
|
}),
|
|
@@ -10927,13 +10971,13 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10927
10971
|
|
|
10928
10972
|
case 5:
|
|
10929
10973
|
case "end":
|
|
10930
|
-
return
|
|
10974
|
+
return _context60.stop();
|
|
10931
10975
|
}
|
|
10932
10976
|
}
|
|
10933
|
-
},
|
|
10977
|
+
}, _callee60, this);
|
|
10934
10978
|
}));
|
|
10935
10979
|
|
|
10936
|
-
function queryThreads(
|
|
10980
|
+
function queryThreads(_x81) {
|
|
10937
10981
|
return _queryThreads.apply(this, arguments);
|
|
10938
10982
|
}
|
|
10939
10983
|
|
|
@@ -10954,19 +10998,19 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10954
10998
|
}, {
|
|
10955
10999
|
key: "getThread",
|
|
10956
11000
|
value: function () {
|
|
10957
|
-
var _getThread = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11001
|
+
var _getThread = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee61(messageId) {
|
|
10958
11002
|
var options,
|
|
10959
11003
|
opts,
|
|
10960
11004
|
res,
|
|
10961
|
-
|
|
10962
|
-
return _regeneratorRuntime.wrap(function
|
|
11005
|
+
_args61 = arguments;
|
|
11006
|
+
return _regeneratorRuntime.wrap(function _callee61$(_context61) {
|
|
10963
11007
|
while (1) {
|
|
10964
|
-
switch (
|
|
11008
|
+
switch (_context61.prev = _context61.next) {
|
|
10965
11009
|
case 0:
|
|
10966
|
-
options =
|
|
11010
|
+
options = _args61.length > 1 && _args61[1] !== undefined ? _args61[1] : {};
|
|
10967
11011
|
|
|
10968
11012
|
if (messageId) {
|
|
10969
|
-
|
|
11013
|
+
_context61.next = 3;
|
|
10970
11014
|
break;
|
|
10971
11015
|
}
|
|
10972
11016
|
|
|
@@ -10978,22 +11022,22 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10978
11022
|
reply_limit: 3,
|
|
10979
11023
|
watch: true
|
|
10980
11024
|
}, options);
|
|
10981
|
-
|
|
11025
|
+
_context61.next = 6;
|
|
10982
11026
|
return this.get(this.baseURL + "/threads/".concat(messageId), opts);
|
|
10983
11027
|
|
|
10984
11028
|
case 6:
|
|
10985
|
-
res =
|
|
10986
|
-
return
|
|
11029
|
+
res = _context61.sent;
|
|
11030
|
+
return _context61.abrupt("return", new Thread(this, res.thread));
|
|
10987
11031
|
|
|
10988
11032
|
case 8:
|
|
10989
11033
|
case "end":
|
|
10990
|
-
return
|
|
11034
|
+
return _context61.stop();
|
|
10991
11035
|
}
|
|
10992
11036
|
}
|
|
10993
|
-
},
|
|
11037
|
+
}, _callee61, this);
|
|
10994
11038
|
}));
|
|
10995
11039
|
|
|
10996
|
-
function getThread(
|
|
11040
|
+
function getThread(_x82) {
|
|
10997
11041
|
return _getThread.apply(this, arguments);
|
|
10998
11042
|
}
|
|
10999
11043
|
|
|
@@ -11011,15 +11055,15 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11011
11055
|
}, {
|
|
11012
11056
|
key: "partialUpdateThread",
|
|
11013
11057
|
value: function () {
|
|
11014
|
-
var _partialUpdateThread = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11058
|
+
var _partialUpdateThread = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee62(messageId, partialThreadObject) {
|
|
11015
11059
|
var reservedThreadFields, _key5;
|
|
11016
11060
|
|
|
11017
|
-
return _regeneratorRuntime.wrap(function
|
|
11061
|
+
return _regeneratorRuntime.wrap(function _callee62$(_context62) {
|
|
11018
11062
|
while (1) {
|
|
11019
|
-
switch (
|
|
11063
|
+
switch (_context62.prev = _context62.next) {
|
|
11020
11064
|
case 0:
|
|
11021
11065
|
if (messageId) {
|
|
11022
|
-
|
|
11066
|
+
_context62.next = 2;
|
|
11023
11067
|
break;
|
|
11024
11068
|
}
|
|
11025
11069
|
|
|
@@ -11029,43 +11073,43 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11029
11073
|
// check for reserved fields from ThreadResponse type within partialThreadObject's set and unset.
|
|
11030
11074
|
// Throw error if any of the reserved field is found.
|
|
11031
11075
|
reservedThreadFields = ['created_at', 'id', 'last_message_at', 'type', 'updated_at', 'user', 'reply_count', 'participants', 'channel'];
|
|
11032
|
-
|
|
11076
|
+
_context62.t0 = _regeneratorRuntime.keys(_objectSpread(_objectSpread({}, partialThreadObject.set), partialThreadObject.unset));
|
|
11033
11077
|
|
|
11034
11078
|
case 4:
|
|
11035
|
-
if ((
|
|
11036
|
-
|
|
11079
|
+
if ((_context62.t1 = _context62.t0()).done) {
|
|
11080
|
+
_context62.next = 10;
|
|
11037
11081
|
break;
|
|
11038
11082
|
}
|
|
11039
11083
|
|
|
11040
|
-
_key5 =
|
|
11084
|
+
_key5 = _context62.t1.value;
|
|
11041
11085
|
|
|
11042
11086
|
if (!reservedThreadFields.includes(_key5)) {
|
|
11043
|
-
|
|
11087
|
+
_context62.next = 8;
|
|
11044
11088
|
break;
|
|
11045
11089
|
}
|
|
11046
11090
|
|
|
11047
11091
|
throw Error("You cannot set ".concat(_key5, " field on Thread object. ").concat(_key5, " is reserved for server-side use. Please omit ").concat(_key5, " from your set object."));
|
|
11048
11092
|
|
|
11049
11093
|
case 8:
|
|
11050
|
-
|
|
11094
|
+
_context62.next = 4;
|
|
11051
11095
|
break;
|
|
11052
11096
|
|
|
11053
11097
|
case 10:
|
|
11054
|
-
|
|
11098
|
+
_context62.next = 12;
|
|
11055
11099
|
return this.patch(this.baseURL + "/threads/".concat(messageId), partialThreadObject);
|
|
11056
11100
|
|
|
11057
11101
|
case 12:
|
|
11058
|
-
return
|
|
11102
|
+
return _context62.abrupt("return", _context62.sent);
|
|
11059
11103
|
|
|
11060
11104
|
case 13:
|
|
11061
11105
|
case "end":
|
|
11062
|
-
return
|
|
11106
|
+
return _context62.stop();
|
|
11063
11107
|
}
|
|
11064
11108
|
}
|
|
11065
|
-
},
|
|
11109
|
+
}, _callee62, this);
|
|
11066
11110
|
}));
|
|
11067
11111
|
|
|
11068
|
-
function partialUpdateThread(
|
|
11112
|
+
function partialUpdateThread(_x83, _x84) {
|
|
11069
11113
|
return _partialUpdateThread.apply(this, arguments);
|
|
11070
11114
|
}
|
|
11071
11115
|
|
|
@@ -11074,7 +11118,7 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11074
11118
|
}, {
|
|
11075
11119
|
key: "getUserAgent",
|
|
11076
11120
|
value: function getUserAgent() {
|
|
11077
|
-
return this.userAgent || "stream-chat-javascript-client-".concat(this.node ? 'node' : 'browser', "-", "8.
|
|
11121
|
+
return this.userAgent || "stream-chat-javascript-client-".concat(this.node ? 'node' : 'browser', "-", "8.22.0");
|
|
11078
11122
|
}
|
|
11079
11123
|
}, {
|
|
11080
11124
|
key: "setUserAgent",
|
|
@@ -11293,28 +11337,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11293
11337
|
}, {
|
|
11294
11338
|
key: "sendUserCustomEvent",
|
|
11295
11339
|
value: function () {
|
|
11296
|
-
var _sendUserCustomEvent = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11297
|
-
return _regeneratorRuntime.wrap(function
|
|
11340
|
+
var _sendUserCustomEvent = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee63(targetUserID, event) {
|
|
11341
|
+
return _regeneratorRuntime.wrap(function _callee63$(_context63) {
|
|
11298
11342
|
while (1) {
|
|
11299
|
-
switch (
|
|
11343
|
+
switch (_context63.prev = _context63.next) {
|
|
11300
11344
|
case 0:
|
|
11301
|
-
|
|
11345
|
+
_context63.next = 2;
|
|
11302
11346
|
return this.post("".concat(this.baseURL, "/users/").concat(targetUserID, "/event"), {
|
|
11303
11347
|
event: event
|
|
11304
11348
|
});
|
|
11305
11349
|
|
|
11306
11350
|
case 2:
|
|
11307
|
-
return
|
|
11351
|
+
return _context63.abrupt("return", _context63.sent);
|
|
11308
11352
|
|
|
11309
11353
|
case 3:
|
|
11310
11354
|
case "end":
|
|
11311
|
-
return
|
|
11355
|
+
return _context63.stop();
|
|
11312
11356
|
}
|
|
11313
11357
|
}
|
|
11314
|
-
},
|
|
11358
|
+
}, _callee63, this);
|
|
11315
11359
|
}));
|
|
11316
11360
|
|
|
11317
|
-
function sendUserCustomEvent(
|
|
11361
|
+
function sendUserCustomEvent(_x85, _x86) {
|
|
11318
11362
|
return _sendUserCustomEvent.apply(this, arguments);
|
|
11319
11363
|
}
|
|
11320
11364
|
|
|
@@ -11411,11 +11455,11 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11411
11455
|
}, {
|
|
11412
11456
|
key: "createSegment",
|
|
11413
11457
|
value: function () {
|
|
11414
|
-
var _createSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11458
|
+
var _createSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee64(type, id, name, data) {
|
|
11415
11459
|
var body;
|
|
11416
|
-
return _regeneratorRuntime.wrap(function
|
|
11460
|
+
return _regeneratorRuntime.wrap(function _callee64$(_context64) {
|
|
11417
11461
|
while (1) {
|
|
11418
|
-
switch (
|
|
11462
|
+
switch (_context64.prev = _context64.next) {
|
|
11419
11463
|
case 0:
|
|
11420
11464
|
this.validateServerSideAuth();
|
|
11421
11465
|
body = {
|
|
@@ -11424,17 +11468,17 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11424
11468
|
name: name,
|
|
11425
11469
|
data: data
|
|
11426
11470
|
};
|
|
11427
|
-
return
|
|
11471
|
+
return _context64.abrupt("return", this.post(this.baseURL + "/segments", body));
|
|
11428
11472
|
|
|
11429
11473
|
case 3:
|
|
11430
11474
|
case "end":
|
|
11431
|
-
return
|
|
11475
|
+
return _context64.stop();
|
|
11432
11476
|
}
|
|
11433
11477
|
}
|
|
11434
|
-
},
|
|
11478
|
+
}, _callee64, this);
|
|
11435
11479
|
}));
|
|
11436
11480
|
|
|
11437
|
-
function createSegment(
|
|
11481
|
+
function createSegment(_x87, _x88, _x89, _x90) {
|
|
11438
11482
|
return _createSegment.apply(this, arguments);
|
|
11439
11483
|
}
|
|
11440
11484
|
|
|
@@ -11453,23 +11497,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11453
11497
|
}, {
|
|
11454
11498
|
key: "createUserSegment",
|
|
11455
11499
|
value: function () {
|
|
11456
|
-
var _createUserSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11457
|
-
return _regeneratorRuntime.wrap(function
|
|
11500
|
+
var _createUserSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee65(id, name, data) {
|
|
11501
|
+
return _regeneratorRuntime.wrap(function _callee65$(_context65) {
|
|
11458
11502
|
while (1) {
|
|
11459
|
-
switch (
|
|
11503
|
+
switch (_context65.prev = _context65.next) {
|
|
11460
11504
|
case 0:
|
|
11461
11505
|
this.validateServerSideAuth();
|
|
11462
|
-
return
|
|
11506
|
+
return _context65.abrupt("return", this.createSegment('user', id, name, data));
|
|
11463
11507
|
|
|
11464
11508
|
case 2:
|
|
11465
11509
|
case "end":
|
|
11466
|
-
return
|
|
11510
|
+
return _context65.stop();
|
|
11467
11511
|
}
|
|
11468
11512
|
}
|
|
11469
|
-
},
|
|
11513
|
+
}, _callee65, this);
|
|
11470
11514
|
}));
|
|
11471
11515
|
|
|
11472
|
-
function createUserSegment(
|
|
11516
|
+
function createUserSegment(_x91, _x92, _x93) {
|
|
11473
11517
|
return _createUserSegment.apply(this, arguments);
|
|
11474
11518
|
}
|
|
11475
11519
|
|
|
@@ -11488,23 +11532,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11488
11532
|
}, {
|
|
11489
11533
|
key: "createChannelSegment",
|
|
11490
11534
|
value: function () {
|
|
11491
|
-
var _createChannelSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11492
|
-
return _regeneratorRuntime.wrap(function
|
|
11535
|
+
var _createChannelSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee66(id, name, data) {
|
|
11536
|
+
return _regeneratorRuntime.wrap(function _callee66$(_context66) {
|
|
11493
11537
|
while (1) {
|
|
11494
|
-
switch (
|
|
11538
|
+
switch (_context66.prev = _context66.next) {
|
|
11495
11539
|
case 0:
|
|
11496
11540
|
this.validateServerSideAuth();
|
|
11497
|
-
return
|
|
11541
|
+
return _context66.abrupt("return", this.createSegment('channel', id, name, data));
|
|
11498
11542
|
|
|
11499
11543
|
case 2:
|
|
11500
11544
|
case "end":
|
|
11501
|
-
return
|
|
11545
|
+
return _context66.stop();
|
|
11502
11546
|
}
|
|
11503
11547
|
}
|
|
11504
|
-
},
|
|
11548
|
+
}, _callee66, this);
|
|
11505
11549
|
}));
|
|
11506
11550
|
|
|
11507
|
-
function createChannelSegment(
|
|
11551
|
+
function createChannelSegment(_x94, _x95, _x96) {
|
|
11508
11552
|
return _createChannelSegment.apply(this, arguments);
|
|
11509
11553
|
}
|
|
11510
11554
|
|
|
@@ -11513,23 +11557,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11513
11557
|
}, {
|
|
11514
11558
|
key: "getSegment",
|
|
11515
11559
|
value: function () {
|
|
11516
|
-
var _getSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11517
|
-
return _regeneratorRuntime.wrap(function
|
|
11560
|
+
var _getSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee67(id) {
|
|
11561
|
+
return _regeneratorRuntime.wrap(function _callee67$(_context67) {
|
|
11518
11562
|
while (1) {
|
|
11519
|
-
switch (
|
|
11563
|
+
switch (_context67.prev = _context67.next) {
|
|
11520
11564
|
case 0:
|
|
11521
11565
|
this.validateServerSideAuth();
|
|
11522
|
-
return
|
|
11566
|
+
return _context67.abrupt("return", this.get(this.baseURL + "/segments/".concat(id)));
|
|
11523
11567
|
|
|
11524
11568
|
case 2:
|
|
11525
11569
|
case "end":
|
|
11526
|
-
return
|
|
11570
|
+
return _context67.stop();
|
|
11527
11571
|
}
|
|
11528
11572
|
}
|
|
11529
|
-
},
|
|
11573
|
+
}, _callee67, this);
|
|
11530
11574
|
}));
|
|
11531
11575
|
|
|
11532
|
-
function getSegment(
|
|
11576
|
+
function getSegment(_x97) {
|
|
11533
11577
|
return _getSegment.apply(this, arguments);
|
|
11534
11578
|
}
|
|
11535
11579
|
|
|
@@ -11547,23 +11591,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11547
11591
|
}, {
|
|
11548
11592
|
key: "updateSegment",
|
|
11549
11593
|
value: function () {
|
|
11550
|
-
var _updateSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11551
|
-
return _regeneratorRuntime.wrap(function
|
|
11594
|
+
var _updateSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee68(id, data) {
|
|
11595
|
+
return _regeneratorRuntime.wrap(function _callee68$(_context68) {
|
|
11552
11596
|
while (1) {
|
|
11553
|
-
switch (
|
|
11597
|
+
switch (_context68.prev = _context68.next) {
|
|
11554
11598
|
case 0:
|
|
11555
11599
|
this.validateServerSideAuth();
|
|
11556
|
-
return
|
|
11600
|
+
return _context68.abrupt("return", this.put(this.baseURL + "/segments/".concat(id), data));
|
|
11557
11601
|
|
|
11558
11602
|
case 2:
|
|
11559
11603
|
case "end":
|
|
11560
|
-
return
|
|
11604
|
+
return _context68.stop();
|
|
11561
11605
|
}
|
|
11562
11606
|
}
|
|
11563
|
-
},
|
|
11607
|
+
}, _callee68, this);
|
|
11564
11608
|
}));
|
|
11565
11609
|
|
|
11566
|
-
function updateSegment(
|
|
11610
|
+
function updateSegment(_x98, _x99) {
|
|
11567
11611
|
return _updateSegment.apply(this, arguments);
|
|
11568
11612
|
}
|
|
11569
11613
|
|
|
@@ -11581,27 +11625,27 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11581
11625
|
}, {
|
|
11582
11626
|
key: "addSegmentTargets",
|
|
11583
11627
|
value: function () {
|
|
11584
|
-
var _addSegmentTargets = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11628
|
+
var _addSegmentTargets = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee69(id, targets) {
|
|
11585
11629
|
var body;
|
|
11586
|
-
return _regeneratorRuntime.wrap(function
|
|
11630
|
+
return _regeneratorRuntime.wrap(function _callee69$(_context69) {
|
|
11587
11631
|
while (1) {
|
|
11588
|
-
switch (
|
|
11632
|
+
switch (_context69.prev = _context69.next) {
|
|
11589
11633
|
case 0:
|
|
11590
11634
|
this.validateServerSideAuth();
|
|
11591
11635
|
body = {
|
|
11592
11636
|
target_ids: targets
|
|
11593
11637
|
};
|
|
11594
|
-
return
|
|
11638
|
+
return _context69.abrupt("return", this.post(this.baseURL + "/segments/".concat(id, "/addtargets"), body));
|
|
11595
11639
|
|
|
11596
11640
|
case 3:
|
|
11597
11641
|
case "end":
|
|
11598
|
-
return
|
|
11642
|
+
return _context69.stop();
|
|
11599
11643
|
}
|
|
11600
11644
|
}
|
|
11601
|
-
},
|
|
11645
|
+
}, _callee69, this);
|
|
11602
11646
|
}));
|
|
11603
11647
|
|
|
11604
|
-
function addSegmentTargets(
|
|
11648
|
+
function addSegmentTargets(_x100, _x101) {
|
|
11605
11649
|
return _addSegmentTargets.apply(this, arguments);
|
|
11606
11650
|
}
|
|
11607
11651
|
|
|
@@ -11610,33 +11654,33 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11610
11654
|
}, {
|
|
11611
11655
|
key: "querySegmentTargets",
|
|
11612
11656
|
value: function () {
|
|
11613
|
-
var _querySegmentTargets = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11657
|
+
var _querySegmentTargets = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee70(id) {
|
|
11614
11658
|
var filter,
|
|
11615
11659
|
sort,
|
|
11616
11660
|
options,
|
|
11617
|
-
|
|
11618
|
-
return _regeneratorRuntime.wrap(function
|
|
11661
|
+
_args70 = arguments;
|
|
11662
|
+
return _regeneratorRuntime.wrap(function _callee70$(_context70) {
|
|
11619
11663
|
while (1) {
|
|
11620
|
-
switch (
|
|
11664
|
+
switch (_context70.prev = _context70.next) {
|
|
11621
11665
|
case 0:
|
|
11622
|
-
filter =
|
|
11623
|
-
sort =
|
|
11624
|
-
options =
|
|
11666
|
+
filter = _args70.length > 1 && _args70[1] !== undefined ? _args70[1] : {};
|
|
11667
|
+
sort = _args70.length > 2 && _args70[2] !== undefined ? _args70[2] : [];
|
|
11668
|
+
options = _args70.length > 3 && _args70[3] !== undefined ? _args70[3] : {};
|
|
11625
11669
|
this.validateServerSideAuth();
|
|
11626
|
-
return
|
|
11670
|
+
return _context70.abrupt("return", this.post(this.baseURL + "/segments/".concat(id, "/targets/query"), _objectSpread({
|
|
11627
11671
|
filter: filter || {},
|
|
11628
11672
|
sort: sort || []
|
|
11629
11673
|
}, options)));
|
|
11630
11674
|
|
|
11631
11675
|
case 5:
|
|
11632
11676
|
case "end":
|
|
11633
|
-
return
|
|
11677
|
+
return _context70.stop();
|
|
11634
11678
|
}
|
|
11635
11679
|
}
|
|
11636
|
-
},
|
|
11680
|
+
}, _callee70, this);
|
|
11637
11681
|
}));
|
|
11638
11682
|
|
|
11639
|
-
function querySegmentTargets(
|
|
11683
|
+
function querySegmentTargets(_x102) {
|
|
11640
11684
|
return _querySegmentTargets.apply(this, arguments);
|
|
11641
11685
|
}
|
|
11642
11686
|
|
|
@@ -11654,27 +11698,27 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11654
11698
|
}, {
|
|
11655
11699
|
key: "removeSegmentTargets",
|
|
11656
11700
|
value: function () {
|
|
11657
|
-
var _removeSegmentTargets = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11701
|
+
var _removeSegmentTargets = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee71(id, targets) {
|
|
11658
11702
|
var body;
|
|
11659
|
-
return _regeneratorRuntime.wrap(function
|
|
11703
|
+
return _regeneratorRuntime.wrap(function _callee71$(_context71) {
|
|
11660
11704
|
while (1) {
|
|
11661
|
-
switch (
|
|
11705
|
+
switch (_context71.prev = _context71.next) {
|
|
11662
11706
|
case 0:
|
|
11663
11707
|
this.validateServerSideAuth();
|
|
11664
11708
|
body = {
|
|
11665
11709
|
target_ids: targets
|
|
11666
11710
|
};
|
|
11667
|
-
return
|
|
11711
|
+
return _context71.abrupt("return", this.post(this.baseURL + "/segments/".concat(id, "/deletetargets"), body));
|
|
11668
11712
|
|
|
11669
11713
|
case 3:
|
|
11670
11714
|
case "end":
|
|
11671
|
-
return
|
|
11715
|
+
return _context71.stop();
|
|
11672
11716
|
}
|
|
11673
11717
|
}
|
|
11674
|
-
},
|
|
11718
|
+
}, _callee71, this);
|
|
11675
11719
|
}));
|
|
11676
11720
|
|
|
11677
|
-
function removeSegmentTargets(
|
|
11721
|
+
function removeSegmentTargets(_x103, _x104) {
|
|
11678
11722
|
return _removeSegmentTargets.apply(this, arguments);
|
|
11679
11723
|
}
|
|
11680
11724
|
|
|
@@ -11692,29 +11736,29 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11692
11736
|
}, {
|
|
11693
11737
|
key: "querySegments",
|
|
11694
11738
|
value: function () {
|
|
11695
|
-
var _querySegments = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11739
|
+
var _querySegments = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee72(filter, sort) {
|
|
11696
11740
|
var options,
|
|
11697
|
-
|
|
11698
|
-
return _regeneratorRuntime.wrap(function
|
|
11741
|
+
_args72 = arguments;
|
|
11742
|
+
return _regeneratorRuntime.wrap(function _callee72$(_context72) {
|
|
11699
11743
|
while (1) {
|
|
11700
|
-
switch (
|
|
11744
|
+
switch (_context72.prev = _context72.next) {
|
|
11701
11745
|
case 0:
|
|
11702
|
-
options =
|
|
11746
|
+
options = _args72.length > 2 && _args72[2] !== undefined ? _args72[2] : {};
|
|
11703
11747
|
this.validateServerSideAuth();
|
|
11704
|
-
return
|
|
11748
|
+
return _context72.abrupt("return", this.post(this.baseURL + "/segments/query", _objectSpread({
|
|
11705
11749
|
filter: filter,
|
|
11706
11750
|
sort: sort
|
|
11707
11751
|
}, options)));
|
|
11708
11752
|
|
|
11709
11753
|
case 3:
|
|
11710
11754
|
case "end":
|
|
11711
|
-
return
|
|
11755
|
+
return _context72.stop();
|
|
11712
11756
|
}
|
|
11713
11757
|
}
|
|
11714
|
-
},
|
|
11758
|
+
}, _callee72, this);
|
|
11715
11759
|
}));
|
|
11716
11760
|
|
|
11717
|
-
function querySegments(
|
|
11761
|
+
function querySegments(_x105, _x106) {
|
|
11718
11762
|
return _querySegments.apply(this, arguments);
|
|
11719
11763
|
}
|
|
11720
11764
|
|
|
@@ -11731,23 +11775,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11731
11775
|
}, {
|
|
11732
11776
|
key: "deleteSegment",
|
|
11733
11777
|
value: function () {
|
|
11734
|
-
var _deleteSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11735
|
-
return _regeneratorRuntime.wrap(function
|
|
11778
|
+
var _deleteSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee73(id) {
|
|
11779
|
+
return _regeneratorRuntime.wrap(function _callee73$(_context73) {
|
|
11736
11780
|
while (1) {
|
|
11737
|
-
switch (
|
|
11781
|
+
switch (_context73.prev = _context73.next) {
|
|
11738
11782
|
case 0:
|
|
11739
11783
|
this.validateServerSideAuth();
|
|
11740
|
-
return
|
|
11784
|
+
return _context73.abrupt("return", this.delete(this.baseURL + "/segments/".concat(id)));
|
|
11741
11785
|
|
|
11742
11786
|
case 2:
|
|
11743
11787
|
case "end":
|
|
11744
|
-
return
|
|
11788
|
+
return _context73.stop();
|
|
11745
11789
|
}
|
|
11746
11790
|
}
|
|
11747
|
-
},
|
|
11791
|
+
}, _callee73, this);
|
|
11748
11792
|
}));
|
|
11749
11793
|
|
|
11750
|
-
function deleteSegment(
|
|
11794
|
+
function deleteSegment(_x107) {
|
|
11751
11795
|
return _deleteSegment.apply(this, arguments);
|
|
11752
11796
|
}
|
|
11753
11797
|
|
|
@@ -11765,23 +11809,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11765
11809
|
}, {
|
|
11766
11810
|
key: "segmentTargetExists",
|
|
11767
11811
|
value: function () {
|
|
11768
|
-
var _segmentTargetExists = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11769
|
-
return _regeneratorRuntime.wrap(function
|
|
11812
|
+
var _segmentTargetExists = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee74(segmentId, targetId) {
|
|
11813
|
+
return _regeneratorRuntime.wrap(function _callee74$(_context74) {
|
|
11770
11814
|
while (1) {
|
|
11771
|
-
switch (
|
|
11815
|
+
switch (_context74.prev = _context74.next) {
|
|
11772
11816
|
case 0:
|
|
11773
11817
|
this.validateServerSideAuth();
|
|
11774
|
-
return
|
|
11818
|
+
return _context74.abrupt("return", this.get(this.baseURL + "/segments/".concat(segmentId, "/target/").concat(targetId)));
|
|
11775
11819
|
|
|
11776
11820
|
case 2:
|
|
11777
11821
|
case "end":
|
|
11778
|
-
return
|
|
11822
|
+
return _context74.stop();
|
|
11779
11823
|
}
|
|
11780
11824
|
}
|
|
11781
|
-
},
|
|
11825
|
+
}, _callee74, this);
|
|
11782
11826
|
}));
|
|
11783
11827
|
|
|
11784
|
-
function segmentTargetExists(
|
|
11828
|
+
function segmentTargetExists(_x108, _x109) {
|
|
11785
11829
|
return _segmentTargetExists.apply(this, arguments);
|
|
11786
11830
|
}
|
|
11787
11831
|
|
|
@@ -11798,23 +11842,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11798
11842
|
}, {
|
|
11799
11843
|
key: "createCampaign",
|
|
11800
11844
|
value: function () {
|
|
11801
|
-
var _createCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11802
|
-
return _regeneratorRuntime.wrap(function
|
|
11845
|
+
var _createCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee75(params) {
|
|
11846
|
+
return _regeneratorRuntime.wrap(function _callee75$(_context75) {
|
|
11803
11847
|
while (1) {
|
|
11804
|
-
switch (
|
|
11848
|
+
switch (_context75.prev = _context75.next) {
|
|
11805
11849
|
case 0:
|
|
11806
11850
|
this.validateServerSideAuth();
|
|
11807
|
-
return
|
|
11851
|
+
return _context75.abrupt("return", this.post(this.baseURL + "/campaigns", _objectSpread({}, params)));
|
|
11808
11852
|
|
|
11809
11853
|
case 2:
|
|
11810
11854
|
case "end":
|
|
11811
|
-
return
|
|
11855
|
+
return _context75.stop();
|
|
11812
11856
|
}
|
|
11813
11857
|
}
|
|
11814
|
-
},
|
|
11858
|
+
}, _callee75, this);
|
|
11815
11859
|
}));
|
|
11816
11860
|
|
|
11817
|
-
function createCampaign(
|
|
11861
|
+
function createCampaign(_x110) {
|
|
11818
11862
|
return _createCampaign.apply(this, arguments);
|
|
11819
11863
|
}
|
|
11820
11864
|
|
|
@@ -11823,23 +11867,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11823
11867
|
}, {
|
|
11824
11868
|
key: "getCampaign",
|
|
11825
11869
|
value: function () {
|
|
11826
|
-
var _getCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11827
|
-
return _regeneratorRuntime.wrap(function
|
|
11870
|
+
var _getCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee76(id) {
|
|
11871
|
+
return _regeneratorRuntime.wrap(function _callee76$(_context76) {
|
|
11828
11872
|
while (1) {
|
|
11829
|
-
switch (
|
|
11873
|
+
switch (_context76.prev = _context76.next) {
|
|
11830
11874
|
case 0:
|
|
11831
11875
|
this.validateServerSideAuth();
|
|
11832
|
-
return
|
|
11876
|
+
return _context76.abrupt("return", this.get(this.baseURL + "/campaigns/".concat(id)));
|
|
11833
11877
|
|
|
11834
11878
|
case 2:
|
|
11835
11879
|
case "end":
|
|
11836
|
-
return
|
|
11880
|
+
return _context76.stop();
|
|
11837
11881
|
}
|
|
11838
11882
|
}
|
|
11839
|
-
},
|
|
11883
|
+
}, _callee76, this);
|
|
11840
11884
|
}));
|
|
11841
11885
|
|
|
11842
|
-
function getCampaign(
|
|
11886
|
+
function getCampaign(_x111) {
|
|
11843
11887
|
return _getCampaign.apply(this, arguments);
|
|
11844
11888
|
}
|
|
11845
11889
|
|
|
@@ -11848,26 +11892,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11848
11892
|
}, {
|
|
11849
11893
|
key: "startCampaign",
|
|
11850
11894
|
value: function () {
|
|
11851
|
-
var _startCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11852
|
-
return _regeneratorRuntime.wrap(function
|
|
11895
|
+
var _startCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee77(id, options) {
|
|
11896
|
+
return _regeneratorRuntime.wrap(function _callee77$(_context77) {
|
|
11853
11897
|
while (1) {
|
|
11854
|
-
switch (
|
|
11898
|
+
switch (_context77.prev = _context77.next) {
|
|
11855
11899
|
case 0:
|
|
11856
11900
|
this.validateServerSideAuth();
|
|
11857
|
-
return
|
|
11901
|
+
return _context77.abrupt("return", this.post(this.baseURL + "/campaigns/".concat(id, "/start"), {
|
|
11858
11902
|
scheduled_for: options === null || options === void 0 ? void 0 : options.scheduledFor,
|
|
11859
11903
|
stop_at: options === null || options === void 0 ? void 0 : options.stopAt
|
|
11860
11904
|
}));
|
|
11861
11905
|
|
|
11862
11906
|
case 2:
|
|
11863
11907
|
case "end":
|
|
11864
|
-
return
|
|
11908
|
+
return _context77.stop();
|
|
11865
11909
|
}
|
|
11866
11910
|
}
|
|
11867
|
-
},
|
|
11911
|
+
}, _callee77, this);
|
|
11868
11912
|
}));
|
|
11869
11913
|
|
|
11870
|
-
function startCampaign(
|
|
11914
|
+
function startCampaign(_x112, _x113) {
|
|
11871
11915
|
return _startCampaign.apply(this, arguments);
|
|
11872
11916
|
}
|
|
11873
11917
|
|
|
@@ -11883,30 +11927,30 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11883
11927
|
}, {
|
|
11884
11928
|
key: "queryCampaigns",
|
|
11885
11929
|
value: function () {
|
|
11886
|
-
var _queryCampaigns = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11887
|
-
return _regeneratorRuntime.wrap(function
|
|
11930
|
+
var _queryCampaigns = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee78(filter, sort, options) {
|
|
11931
|
+
return _regeneratorRuntime.wrap(function _callee78$(_context78) {
|
|
11888
11932
|
while (1) {
|
|
11889
|
-
switch (
|
|
11933
|
+
switch (_context78.prev = _context78.next) {
|
|
11890
11934
|
case 0:
|
|
11891
11935
|
this.validateServerSideAuth();
|
|
11892
|
-
|
|
11936
|
+
_context78.next = 3;
|
|
11893
11937
|
return this.post(this.baseURL + "/campaigns/query", _objectSpread({
|
|
11894
11938
|
filter: filter,
|
|
11895
11939
|
sort: sort
|
|
11896
11940
|
}, options || {}));
|
|
11897
11941
|
|
|
11898
11942
|
case 3:
|
|
11899
|
-
return
|
|
11943
|
+
return _context78.abrupt("return", _context78.sent);
|
|
11900
11944
|
|
|
11901
11945
|
case 4:
|
|
11902
11946
|
case "end":
|
|
11903
|
-
return
|
|
11947
|
+
return _context78.stop();
|
|
11904
11948
|
}
|
|
11905
11949
|
}
|
|
11906
|
-
},
|
|
11950
|
+
}, _callee78, this);
|
|
11907
11951
|
}));
|
|
11908
11952
|
|
|
11909
|
-
function queryCampaigns(
|
|
11953
|
+
function queryCampaigns(_x114, _x115, _x116) {
|
|
11910
11954
|
return _queryCampaigns.apply(this, arguments);
|
|
11911
11955
|
}
|
|
11912
11956
|
|
|
@@ -11924,23 +11968,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11924
11968
|
}, {
|
|
11925
11969
|
key: "updateCampaign",
|
|
11926
11970
|
value: function () {
|
|
11927
|
-
var _updateCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11928
|
-
return _regeneratorRuntime.wrap(function
|
|
11971
|
+
var _updateCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee79(id, params) {
|
|
11972
|
+
return _regeneratorRuntime.wrap(function _callee79$(_context79) {
|
|
11929
11973
|
while (1) {
|
|
11930
|
-
switch (
|
|
11974
|
+
switch (_context79.prev = _context79.next) {
|
|
11931
11975
|
case 0:
|
|
11932
11976
|
this.validateServerSideAuth();
|
|
11933
|
-
return
|
|
11977
|
+
return _context79.abrupt("return", this.put(this.baseURL + "/campaigns/".concat(id), params));
|
|
11934
11978
|
|
|
11935
11979
|
case 2:
|
|
11936
11980
|
case "end":
|
|
11937
|
-
return
|
|
11981
|
+
return _context79.stop();
|
|
11938
11982
|
}
|
|
11939
11983
|
}
|
|
11940
|
-
},
|
|
11984
|
+
}, _callee79, this);
|
|
11941
11985
|
}));
|
|
11942
11986
|
|
|
11943
|
-
function updateCampaign(
|
|
11987
|
+
function updateCampaign(_x117, _x118) {
|
|
11944
11988
|
return _updateCampaign.apply(this, arguments);
|
|
11945
11989
|
}
|
|
11946
11990
|
|
|
@@ -11957,23 +12001,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11957
12001
|
}, {
|
|
11958
12002
|
key: "deleteCampaign",
|
|
11959
12003
|
value: function () {
|
|
11960
|
-
var _deleteCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11961
|
-
return _regeneratorRuntime.wrap(function
|
|
12004
|
+
var _deleteCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee80(id) {
|
|
12005
|
+
return _regeneratorRuntime.wrap(function _callee80$(_context80) {
|
|
11962
12006
|
while (1) {
|
|
11963
|
-
switch (
|
|
12007
|
+
switch (_context80.prev = _context80.next) {
|
|
11964
12008
|
case 0:
|
|
11965
12009
|
this.validateServerSideAuth();
|
|
11966
|
-
return
|
|
12010
|
+
return _context80.abrupt("return", this.delete(this.baseURL + "/campaigns/".concat(id)));
|
|
11967
12011
|
|
|
11968
12012
|
case 2:
|
|
11969
12013
|
case "end":
|
|
11970
|
-
return
|
|
12014
|
+
return _context80.stop();
|
|
11971
12015
|
}
|
|
11972
12016
|
}
|
|
11973
|
-
},
|
|
12017
|
+
}, _callee80, this);
|
|
11974
12018
|
}));
|
|
11975
12019
|
|
|
11976
|
-
function deleteCampaign(
|
|
12020
|
+
function deleteCampaign(_x119) {
|
|
11977
12021
|
return _deleteCampaign.apply(this, arguments);
|
|
11978
12022
|
}
|
|
11979
12023
|
|
|
@@ -11990,31 +12034,31 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11990
12034
|
}, {
|
|
11991
12035
|
key: "stopCampaign",
|
|
11992
12036
|
value: function () {
|
|
11993
|
-
var _stopCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
12037
|
+
var _stopCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee81(id) {
|
|
11994
12038
|
var _yield$this$patch, campaign;
|
|
11995
12039
|
|
|
11996
|
-
return _regeneratorRuntime.wrap(function
|
|
12040
|
+
return _regeneratorRuntime.wrap(function _callee81$(_context81) {
|
|
11997
12041
|
while (1) {
|
|
11998
|
-
switch (
|
|
12042
|
+
switch (_context81.prev = _context81.next) {
|
|
11999
12043
|
case 0:
|
|
12000
12044
|
this.validateServerSideAuth();
|
|
12001
|
-
|
|
12045
|
+
_context81.next = 3;
|
|
12002
12046
|
return this.patch(this.baseURL + "/campaigns/".concat(id, "/stop"));
|
|
12003
12047
|
|
|
12004
12048
|
case 3:
|
|
12005
|
-
_yield$this$patch =
|
|
12049
|
+
_yield$this$patch = _context81.sent;
|
|
12006
12050
|
campaign = _yield$this$patch.campaign;
|
|
12007
|
-
return
|
|
12051
|
+
return _context81.abrupt("return", campaign);
|
|
12008
12052
|
|
|
12009
12053
|
case 6:
|
|
12010
12054
|
case "end":
|
|
12011
|
-
return
|
|
12055
|
+
return _context81.stop();
|
|
12012
12056
|
}
|
|
12013
12057
|
}
|
|
12014
|
-
},
|
|
12058
|
+
}, _callee81, this);
|
|
12015
12059
|
}));
|
|
12016
12060
|
|
|
12017
|
-
function stopCampaign(
|
|
12061
|
+
function stopCampaign(_x120) {
|
|
12018
12062
|
return _stopCampaign.apply(this, arguments);
|
|
12019
12063
|
}
|
|
12020
12064
|
|
|
@@ -12030,24 +12074,24 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
12030
12074
|
}, {
|
|
12031
12075
|
key: "enrichURL",
|
|
12032
12076
|
value: function () {
|
|
12033
|
-
var _enrichURL = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
12034
|
-
return _regeneratorRuntime.wrap(function
|
|
12077
|
+
var _enrichURL = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee82(url) {
|
|
12078
|
+
return _regeneratorRuntime.wrap(function _callee82$(_context82) {
|
|
12035
12079
|
while (1) {
|
|
12036
|
-
switch (
|
|
12080
|
+
switch (_context82.prev = _context82.next) {
|
|
12037
12081
|
case 0:
|
|
12038
|
-
return
|
|
12082
|
+
return _context82.abrupt("return", this.get(this.baseURL + "/og", {
|
|
12039
12083
|
url: url
|
|
12040
12084
|
}));
|
|
12041
12085
|
|
|
12042
12086
|
case 1:
|
|
12043
12087
|
case "end":
|
|
12044
|
-
return
|
|
12088
|
+
return _context82.stop();
|
|
12045
12089
|
}
|
|
12046
12090
|
}
|
|
12047
|
-
},
|
|
12091
|
+
}, _callee82, this);
|
|
12048
12092
|
}));
|
|
12049
12093
|
|
|
12050
|
-
function enrichURL(
|
|
12094
|
+
function enrichURL(_x121) {
|
|
12051
12095
|
return _enrichURL.apply(this, arguments);
|
|
12052
12096
|
}
|
|
12053
12097
|
|
|
@@ -12064,22 +12108,22 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
12064
12108
|
}, {
|
|
12065
12109
|
key: "getTask",
|
|
12066
12110
|
value: function () {
|
|
12067
|
-
var _getTask = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
12068
|
-
return _regeneratorRuntime.wrap(function
|
|
12111
|
+
var _getTask = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee83(id) {
|
|
12112
|
+
return _regeneratorRuntime.wrap(function _callee83$(_context83) {
|
|
12069
12113
|
while (1) {
|
|
12070
|
-
switch (
|
|
12114
|
+
switch (_context83.prev = _context83.next) {
|
|
12071
12115
|
case 0:
|
|
12072
|
-
return
|
|
12116
|
+
return _context83.abrupt("return", this.get("".concat(this.baseURL, "/tasks/").concat(id)));
|
|
12073
12117
|
|
|
12074
12118
|
case 1:
|
|
12075
12119
|
case "end":
|
|
12076
|
-
return
|
|
12120
|
+
return _context83.stop();
|
|
12077
12121
|
}
|
|
12078
12122
|
}
|
|
12079
|
-
},
|
|
12123
|
+
}, _callee83, this);
|
|
12080
12124
|
}));
|
|
12081
12125
|
|
|
12082
|
-
function getTask(
|
|
12126
|
+
function getTask(_x122) {
|
|
12083
12127
|
return _getTask.apply(this, arguments);
|
|
12084
12128
|
}
|
|
12085
12129
|
|
|
@@ -12097,31 +12141,31 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
12097
12141
|
}, {
|
|
12098
12142
|
key: "deleteChannels",
|
|
12099
12143
|
value: function () {
|
|
12100
|
-
var _deleteChannels = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
12144
|
+
var _deleteChannels = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee84(cids) {
|
|
12101
12145
|
var options,
|
|
12102
|
-
|
|
12103
|
-
return _regeneratorRuntime.wrap(function
|
|
12146
|
+
_args84 = arguments;
|
|
12147
|
+
return _regeneratorRuntime.wrap(function _callee84$(_context84) {
|
|
12104
12148
|
while (1) {
|
|
12105
|
-
switch (
|
|
12149
|
+
switch (_context84.prev = _context84.next) {
|
|
12106
12150
|
case 0:
|
|
12107
|
-
options =
|
|
12108
|
-
|
|
12151
|
+
options = _args84.length > 1 && _args84[1] !== undefined ? _args84[1] : {};
|
|
12152
|
+
_context84.next = 3;
|
|
12109
12153
|
return this.post(this.baseURL + "/channels/delete", _objectSpread({
|
|
12110
12154
|
cids: cids
|
|
12111
12155
|
}, options));
|
|
12112
12156
|
|
|
12113
12157
|
case 3:
|
|
12114
|
-
return
|
|
12158
|
+
return _context84.abrupt("return", _context84.sent);
|
|
12115
12159
|
|
|
12116
12160
|
case 4:
|
|
12117
12161
|
case "end":
|
|
12118
|
-
return
|
|
12162
|
+
return _context84.stop();
|
|
12119
12163
|
}
|
|
12120
12164
|
}
|
|
12121
|
-
},
|
|
12165
|
+
}, _callee84, this);
|
|
12122
12166
|
}));
|
|
12123
12167
|
|
|
12124
|
-
function deleteChannels(
|
|
12168
|
+
function deleteChannels(_x123) {
|
|
12125
12169
|
return _deleteChannels.apply(this, arguments);
|
|
12126
12170
|
}
|
|
12127
12171
|
|
|
@@ -12139,17 +12183,17 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
12139
12183
|
}, {
|
|
12140
12184
|
key: "deleteUsers",
|
|
12141
12185
|
value: function () {
|
|
12142
|
-
var _deleteUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
12186
|
+
var _deleteUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee85(user_ids) {
|
|
12143
12187
|
var options,
|
|
12144
|
-
|
|
12145
|
-
return _regeneratorRuntime.wrap(function
|
|
12188
|
+
_args85 = arguments;
|
|
12189
|
+
return _regeneratorRuntime.wrap(function _callee85$(_context85) {
|
|
12146
12190
|
while (1) {
|
|
12147
|
-
switch (
|
|
12191
|
+
switch (_context85.prev = _context85.next) {
|
|
12148
12192
|
case 0:
|
|
12149
|
-
options =
|
|
12193
|
+
options = _args85.length > 1 && _args85[1] !== undefined ? _args85[1] : {};
|
|
12150
12194
|
|
|
12151
12195
|
if (!(typeof options.user !== 'undefined' && !['soft', 'hard', 'pruning'].includes(options.user))) {
|
|
12152
|
-
|
|
12196
|
+
_context85.next = 3;
|
|
12153
12197
|
break;
|
|
12154
12198
|
}
|
|
12155
12199
|
|
|
@@ -12157,7 +12201,7 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
12157
12201
|
|
|
12158
12202
|
case 3:
|
|
12159
12203
|
if (!(typeof options.conversations !== 'undefined' && !['soft', 'hard'].includes(options.conversations))) {
|
|
12160
|
-
|
|
12204
|
+
_context85.next = 5;
|
|
12161
12205
|
break;
|
|
12162
12206
|
}
|
|
12163
12207
|
|
|
@@ -12165,30 +12209,30 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
12165
12209
|
|
|
12166
12210
|
case 5:
|
|
12167
12211
|
if (!(typeof options.messages !== 'undefined' && !['soft', 'hard', 'pruning'].includes(options.messages))) {
|
|
12168
|
-
|
|
12212
|
+
_context85.next = 7;
|
|
12169
12213
|
break;
|
|
12170
12214
|
}
|
|
12171
12215
|
|
|
12172
12216
|
throw new Error('Invalid delete user options. messages must be one of [soft hard pruning]');
|
|
12173
12217
|
|
|
12174
12218
|
case 7:
|
|
12175
|
-
|
|
12219
|
+
_context85.next = 9;
|
|
12176
12220
|
return this.post(this.baseURL + "/users/delete", _objectSpread({
|
|
12177
12221
|
user_ids: user_ids
|
|
12178
12222
|
}, options));
|
|
12179
12223
|
|
|
12180
12224
|
case 9:
|
|
12181
|
-
return
|
|
12225
|
+
return _context85.abrupt("return", _context85.sent);
|
|
12182
12226
|
|
|
12183
12227
|
case 10:
|
|
12184
12228
|
case "end":
|
|
12185
|
-
return
|
|
12229
|
+
return _context85.stop();
|
|
12186
12230
|
}
|
|
12187
12231
|
}
|
|
12188
|
-
},
|
|
12232
|
+
}, _callee85, this);
|
|
12189
12233
|
}));
|
|
12190
12234
|
|
|
12191
|
-
function deleteUsers(
|
|
12235
|
+
function deleteUsers(_x124) {
|
|
12192
12236
|
return _deleteUsers.apply(this, arguments);
|
|
12193
12237
|
}
|
|
12194
12238
|
|
|
@@ -12209,28 +12253,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
12209
12253
|
}, {
|
|
12210
12254
|
key: "_createImportURL",
|
|
12211
12255
|
value: function () {
|
|
12212
|
-
var _createImportURL2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
12213
|
-
return _regeneratorRuntime.wrap(function
|
|
12256
|
+
var _createImportURL2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee86(filename) {
|
|
12257
|
+
return _regeneratorRuntime.wrap(function _callee86$(_context86) {
|
|
12214
12258
|
while (1) {
|
|
12215
|
-
switch (
|
|
12259
|
+
switch (_context86.prev = _context86.next) {
|
|
12216
12260
|
case 0:
|
|
12217
|
-
|
|
12261
|
+
_context86.next = 2;
|
|
12218
12262
|
return this.post(this.baseURL + "/import_urls", {
|
|
12219
12263
|
filename: filename
|
|
12220
12264
|
});
|
|
12221
12265
|
|
|
12222
12266
|
case 2:
|
|
12223
|
-
return
|
|
12267
|
+
return _context86.abrupt("return", _context86.sent);
|
|
12224
12268
|
|
|
12225
12269
|
case 3:
|
|
12226
12270
|
case "end":
|
|
12227
|
-
return
|
|
12271
|
+
return _context86.stop();
|
|
12228
12272
|
}
|
|
12229
12273
|
}
|
|
12230
|
-
},
|
|
12274
|
+
}, _callee86, this);
|
|
12231
12275
|
}));
|
|
12232
12276
|
|
|
12233
|
-
function _createImportURL(
|
|
12277
|
+
function _createImportURL(_x125) {
|
|
12234
12278
|
return _createImportURL2.apply(this, arguments);
|
|
12235
12279
|
}
|
|
12236
12280
|
|
|
@@ -12252,33 +12296,33 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
12252
12296
|
}, {
|
|
12253
12297
|
key: "_createImport",
|
|
12254
12298
|
value: function () {
|
|
12255
|
-
var _createImport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
12299
|
+
var _createImport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee87(path) {
|
|
12256
12300
|
var options,
|
|
12257
|
-
|
|
12258
|
-
return _regeneratorRuntime.wrap(function
|
|
12301
|
+
_args87 = arguments;
|
|
12302
|
+
return _regeneratorRuntime.wrap(function _callee87$(_context87) {
|
|
12259
12303
|
while (1) {
|
|
12260
|
-
switch (
|
|
12304
|
+
switch (_context87.prev = _context87.next) {
|
|
12261
12305
|
case 0:
|
|
12262
|
-
options =
|
|
12306
|
+
options = _args87.length > 1 && _args87[1] !== undefined ? _args87[1] : {
|
|
12263
12307
|
mode: 'upsert'
|
|
12264
12308
|
};
|
|
12265
|
-
|
|
12309
|
+
_context87.next = 3;
|
|
12266
12310
|
return this.post(this.baseURL + "/imports", _objectSpread({
|
|
12267
12311
|
path: path
|
|
12268
12312
|
}, options));
|
|
12269
12313
|
|
|
12270
12314
|
case 3:
|
|
12271
|
-
return
|
|
12315
|
+
return _context87.abrupt("return", _context87.sent);
|
|
12272
12316
|
|
|
12273
12317
|
case 4:
|
|
12274
12318
|
case "end":
|
|
12275
|
-
return
|
|
12319
|
+
return _context87.stop();
|
|
12276
12320
|
}
|
|
12277
12321
|
}
|
|
12278
|
-
},
|
|
12322
|
+
}, _callee87, this);
|
|
12279
12323
|
}));
|
|
12280
12324
|
|
|
12281
|
-
function _createImport(
|
|
12325
|
+
function _createImport(_x126) {
|
|
12282
12326
|
return _createImport2.apply(this, arguments);
|
|
12283
12327
|
}
|
|
12284
12328
|
|
|
@@ -12300,26 +12344,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
12300
12344
|
}, {
|
|
12301
12345
|
key: "_getImport",
|
|
12302
12346
|
value: function () {
|
|
12303
|
-
var _getImport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
12304
|
-
return _regeneratorRuntime.wrap(function
|
|
12347
|
+
var _getImport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee88(id) {
|
|
12348
|
+
return _regeneratorRuntime.wrap(function _callee88$(_context88) {
|
|
12305
12349
|
while (1) {
|
|
12306
|
-
switch (
|
|
12350
|
+
switch (_context88.prev = _context88.next) {
|
|
12307
12351
|
case 0:
|
|
12308
|
-
|
|
12352
|
+
_context88.next = 2;
|
|
12309
12353
|
return this.get(this.baseURL + "/imports/".concat(id));
|
|
12310
12354
|
|
|
12311
12355
|
case 2:
|
|
12312
|
-
return
|
|
12356
|
+
return _context88.abrupt("return", _context88.sent);
|
|
12313
12357
|
|
|
12314
12358
|
case 3:
|
|
12315
12359
|
case "end":
|
|
12316
|
-
return
|
|
12360
|
+
return _context88.stop();
|
|
12317
12361
|
}
|
|
12318
12362
|
}
|
|
12319
|
-
},
|
|
12363
|
+
}, _callee88, this);
|
|
12320
12364
|
}));
|
|
12321
12365
|
|
|
12322
|
-
function _getImport(
|
|
12366
|
+
function _getImport(_x127) {
|
|
12323
12367
|
return _getImport2.apply(this, arguments);
|
|
12324
12368
|
}
|
|
12325
12369
|
|
|
@@ -12341,26 +12385,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
12341
12385
|
}, {
|
|
12342
12386
|
key: "_listImports",
|
|
12343
12387
|
value: function () {
|
|
12344
|
-
var _listImports2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
12345
|
-
return _regeneratorRuntime.wrap(function
|
|
12388
|
+
var _listImports2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee89(options) {
|
|
12389
|
+
return _regeneratorRuntime.wrap(function _callee89$(_context89) {
|
|
12346
12390
|
while (1) {
|
|
12347
|
-
switch (
|
|
12391
|
+
switch (_context89.prev = _context89.next) {
|
|
12348
12392
|
case 0:
|
|
12349
|
-
|
|
12393
|
+
_context89.next = 2;
|
|
12350
12394
|
return this.get(this.baseURL + "/imports", options);
|
|
12351
12395
|
|
|
12352
12396
|
case 2:
|
|
12353
|
-
return
|
|
12397
|
+
return _context89.abrupt("return", _context89.sent);
|
|
12354
12398
|
|
|
12355
12399
|
case 3:
|
|
12356
12400
|
case "end":
|
|
12357
|
-
return
|
|
12401
|
+
return _context89.stop();
|
|
12358
12402
|
}
|
|
12359
12403
|
}
|
|
12360
|
-
},
|
|
12404
|
+
}, _callee89, this);
|
|
12361
12405
|
}));
|
|
12362
12406
|
|
|
12363
|
-
function _listImports(
|
|
12407
|
+
function _listImports(_x128) {
|
|
12364
12408
|
return _listImports2.apply(this, arguments);
|
|
12365
12409
|
}
|
|
12366
12410
|
|
|
@@ -12379,28 +12423,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
12379
12423
|
}, {
|
|
12380
12424
|
key: "upsertPushProvider",
|
|
12381
12425
|
value: function () {
|
|
12382
|
-
var _upsertPushProvider = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
12383
|
-
return _regeneratorRuntime.wrap(function
|
|
12426
|
+
var _upsertPushProvider = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee90(pushProvider) {
|
|
12427
|
+
return _regeneratorRuntime.wrap(function _callee90$(_context90) {
|
|
12384
12428
|
while (1) {
|
|
12385
|
-
switch (
|
|
12429
|
+
switch (_context90.prev = _context90.next) {
|
|
12386
12430
|
case 0:
|
|
12387
|
-
|
|
12431
|
+
_context90.next = 2;
|
|
12388
12432
|
return this.post(this.baseURL + "/push_providers", {
|
|
12389
12433
|
push_provider: pushProvider
|
|
12390
12434
|
});
|
|
12391
12435
|
|
|
12392
12436
|
case 2:
|
|
12393
|
-
return
|
|
12437
|
+
return _context90.abrupt("return", _context90.sent);
|
|
12394
12438
|
|
|
12395
12439
|
case 3:
|
|
12396
12440
|
case "end":
|
|
12397
|
-
return
|
|
12441
|
+
return _context90.stop();
|
|
12398
12442
|
}
|
|
12399
12443
|
}
|
|
12400
|
-
},
|
|
12444
|
+
}, _callee90, this);
|
|
12401
12445
|
}));
|
|
12402
12446
|
|
|
12403
|
-
function upsertPushProvider(
|
|
12447
|
+
function upsertPushProvider(_x129) {
|
|
12404
12448
|
return _upsertPushProvider.apply(this, arguments);
|
|
12405
12449
|
}
|
|
12406
12450
|
|
|
@@ -12419,28 +12463,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
12419
12463
|
}, {
|
|
12420
12464
|
key: "deletePushProvider",
|
|
12421
12465
|
value: function () {
|
|
12422
|
-
var _deletePushProvider = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
12466
|
+
var _deletePushProvider = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee91(_ref10) {
|
|
12423
12467
|
var type, name;
|
|
12424
|
-
return _regeneratorRuntime.wrap(function
|
|
12468
|
+
return _regeneratorRuntime.wrap(function _callee91$(_context91) {
|
|
12425
12469
|
while (1) {
|
|
12426
|
-
switch (
|
|
12470
|
+
switch (_context91.prev = _context91.next) {
|
|
12427
12471
|
case 0:
|
|
12428
12472
|
type = _ref10.type, name = _ref10.name;
|
|
12429
|
-
|
|
12473
|
+
_context91.next = 3;
|
|
12430
12474
|
return this.delete(this.baseURL + "/push_providers/".concat(type, "/").concat(name));
|
|
12431
12475
|
|
|
12432
12476
|
case 3:
|
|
12433
|
-
return
|
|
12477
|
+
return _context91.abrupt("return", _context91.sent);
|
|
12434
12478
|
|
|
12435
12479
|
case 4:
|
|
12436
12480
|
case "end":
|
|
12437
|
-
return
|
|
12481
|
+
return _context91.stop();
|
|
12438
12482
|
}
|
|
12439
12483
|
}
|
|
12440
|
-
},
|
|
12484
|
+
}, _callee91, this);
|
|
12441
12485
|
}));
|
|
12442
12486
|
|
|
12443
|
-
function deletePushProvider(
|
|
12487
|
+
function deletePushProvider(_x130) {
|
|
12444
12488
|
return _deletePushProvider.apply(this, arguments);
|
|
12445
12489
|
}
|
|
12446
12490
|
|
|
@@ -12457,23 +12501,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
12457
12501
|
}, {
|
|
12458
12502
|
key: "listPushProviders",
|
|
12459
12503
|
value: function () {
|
|
12460
|
-
var _listPushProviders = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
12461
|
-
return _regeneratorRuntime.wrap(function
|
|
12504
|
+
var _listPushProviders = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee92() {
|
|
12505
|
+
return _regeneratorRuntime.wrap(function _callee92$(_context92) {
|
|
12462
12506
|
while (1) {
|
|
12463
|
-
switch (
|
|
12507
|
+
switch (_context92.prev = _context92.next) {
|
|
12464
12508
|
case 0:
|
|
12465
|
-
|
|
12509
|
+
_context92.next = 2;
|
|
12466
12510
|
return this.get(this.baseURL + "/push_providers");
|
|
12467
12511
|
|
|
12468
12512
|
case 2:
|
|
12469
|
-
return
|
|
12513
|
+
return _context92.abrupt("return", _context92.sent);
|
|
12470
12514
|
|
|
12471
12515
|
case 3:
|
|
12472
12516
|
case "end":
|
|
12473
|
-
return
|
|
12517
|
+
return _context92.stop();
|
|
12474
12518
|
}
|
|
12475
12519
|
}
|
|
12476
|
-
},
|
|
12520
|
+
}, _callee92, this);
|
|
12477
12521
|
}));
|
|
12478
12522
|
|
|
12479
12523
|
function listPushProviders() {
|
|
@@ -12501,26 +12545,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
12501
12545
|
}, {
|
|
12502
12546
|
key: "commitMessage",
|
|
12503
12547
|
value: function () {
|
|
12504
|
-
var _commitMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
12505
|
-
return _regeneratorRuntime.wrap(function
|
|
12548
|
+
var _commitMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee93(id) {
|
|
12549
|
+
return _regeneratorRuntime.wrap(function _callee93$(_context93) {
|
|
12506
12550
|
while (1) {
|
|
12507
|
-
switch (
|
|
12551
|
+
switch (_context93.prev = _context93.next) {
|
|
12508
12552
|
case 0:
|
|
12509
|
-
|
|
12553
|
+
_context93.next = 2;
|
|
12510
12554
|
return this.post(this.baseURL + "/messages/".concat(id, "/commit"));
|
|
12511
12555
|
|
|
12512
12556
|
case 2:
|
|
12513
|
-
return
|
|
12557
|
+
return _context93.abrupt("return", _context93.sent);
|
|
12514
12558
|
|
|
12515
12559
|
case 3:
|
|
12516
12560
|
case "end":
|
|
12517
|
-
return
|
|
12561
|
+
return _context93.stop();
|
|
12518
12562
|
}
|
|
12519
12563
|
}
|
|
12520
|
-
},
|
|
12564
|
+
}, _callee93, this);
|
|
12521
12565
|
}));
|
|
12522
12566
|
|
|
12523
|
-
function commitMessage(
|
|
12567
|
+
function commitMessage(_x131) {
|
|
12524
12568
|
return _commitMessage.apply(this, arguments);
|
|
12525
12569
|
}
|
|
12526
12570
|
|
|
@@ -12564,6 +12608,7 @@ var EVENT_MAP = {
|
|
|
12564
12608
|
'message.new': true,
|
|
12565
12609
|
'message.read': true,
|
|
12566
12610
|
'message.updated': true,
|
|
12611
|
+
'message.undeleted': true,
|
|
12567
12612
|
'notification.added_to_channel': true,
|
|
12568
12613
|
'notification.channel_deleted': true,
|
|
12569
12614
|
'notification.channel_mutes_updated': true,
|