stream-chat 8.11.0 → 8.12.1
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 +585 -558
- 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 +585 -558
- package/dist/browser.js.map +1 -1
- package/dist/index.es.js +585 -558
- package/dist/index.es.js.map +1 -1
- package/dist/index.js +585 -558
- package/dist/index.js.map +1 -1
- package/dist/types/channel.d.ts +2 -10
- package/dist/types/channel.d.ts.map +1 -1
- package/dist/types/client.d.ts +21 -17
- package/dist/types/client.d.ts.map +1 -1
- package/dist/types/types.d.ts +27 -1
- package/dist/types/types.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/channel.ts +4 -14
- package/src/client.ts +25 -16
- package/src/types.ts +30 -0
package/dist/browser.es.js
CHANGED
|
@@ -1638,12 +1638,12 @@ var Channel = /*#__PURE__*/function () {
|
|
|
1638
1638
|
case 0:
|
|
1639
1639
|
options = _args4.length > 1 && _args4[1] !== undefined ? _args4[1] : {};
|
|
1640
1640
|
|
|
1641
|
-
if (!(options.offset &&
|
|
1641
|
+
if (!(options.offset && options.next)) {
|
|
1642
1642
|
_context4.next = 3;
|
|
1643
1643
|
break;
|
|
1644
1644
|
}
|
|
1645
1645
|
|
|
1646
|
-
throw Error("Cannot specify offset with
|
|
1646
|
+
throw Error("Cannot specify offset with next");
|
|
1647
1647
|
|
|
1648
1648
|
case 3:
|
|
1649
1649
|
// Return a list of channels
|
|
@@ -6837,6 +6837,8 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
6837
6837
|
|
|
6838
6838
|
_defineProperty(this, "updateUser", this.upsertUser);
|
|
6839
6839
|
|
|
6840
|
+
_defineProperty(this, "_unblockMessage", this.unblockMessage);
|
|
6841
|
+
|
|
6840
6842
|
_defineProperty(this, "markAllRead", this.markChannelsRead);
|
|
6841
6843
|
|
|
6842
6844
|
_defineProperty(this, "_isUsingServerAuth", function () {
|
|
@@ -8181,12 +8183,12 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8181
8183
|
case 0:
|
|
8182
8184
|
options = _args20.length > 2 && _args20[2] !== undefined ? _args20[2] : {};
|
|
8183
8185
|
|
|
8184
|
-
if (!(options.offset &&
|
|
8186
|
+
if (!(options.offset && options.next)) {
|
|
8185
8187
|
_context20.next = 3;
|
|
8186
8188
|
break;
|
|
8187
8189
|
}
|
|
8188
8190
|
|
|
8189
|
-
throw Error("Cannot specify offset with
|
|
8191
|
+
throw Error("Cannot specify offset with next");
|
|
8190
8192
|
|
|
8191
8193
|
case 3:
|
|
8192
8194
|
payload = _objectSpread(_objectSpread({
|
|
@@ -8347,6 +8349,36 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8347
8349
|
|
|
8348
8350
|
return getDevices;
|
|
8349
8351
|
}()
|
|
8352
|
+
}, {
|
|
8353
|
+
key: "getUnreadCount",
|
|
8354
|
+
value: function () {
|
|
8355
|
+
var _getUnreadCount = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee23(userID) {
|
|
8356
|
+
return _regeneratorRuntime.wrap(function _callee23$(_context23) {
|
|
8357
|
+
while (1) {
|
|
8358
|
+
switch (_context23.prev = _context23.next) {
|
|
8359
|
+
case 0:
|
|
8360
|
+
_context23.next = 2;
|
|
8361
|
+
return this.get(this.baseURL + '/unread', userID ? {
|
|
8362
|
+
user_id: userID
|
|
8363
|
+
} : {});
|
|
8364
|
+
|
|
8365
|
+
case 2:
|
|
8366
|
+
return _context23.abrupt("return", _context23.sent);
|
|
8367
|
+
|
|
8368
|
+
case 3:
|
|
8369
|
+
case "end":
|
|
8370
|
+
return _context23.stop();
|
|
8371
|
+
}
|
|
8372
|
+
}
|
|
8373
|
+
}, _callee23, this);
|
|
8374
|
+
}));
|
|
8375
|
+
|
|
8376
|
+
function getUnreadCount(_x25) {
|
|
8377
|
+
return _getUnreadCount.apply(this, arguments);
|
|
8378
|
+
}
|
|
8379
|
+
|
|
8380
|
+
return getUnreadCount;
|
|
8381
|
+
}()
|
|
8350
8382
|
/**
|
|
8351
8383
|
* removeDevice - Removes the device with the given id. Clientside users can only delete their own devices
|
|
8352
8384
|
*
|
|
@@ -8358,12 +8390,12 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8358
8390
|
}, {
|
|
8359
8391
|
key: "removeDevice",
|
|
8360
8392
|
value: function () {
|
|
8361
|
-
var _removeDevice = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8362
|
-
return _regeneratorRuntime.wrap(function
|
|
8393
|
+
var _removeDevice = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee24(id, userID) {
|
|
8394
|
+
return _regeneratorRuntime.wrap(function _callee24$(_context24) {
|
|
8363
8395
|
while (1) {
|
|
8364
|
-
switch (
|
|
8396
|
+
switch (_context24.prev = _context24.next) {
|
|
8365
8397
|
case 0:
|
|
8366
|
-
|
|
8398
|
+
_context24.next = 2;
|
|
8367
8399
|
return this.delete(this.baseURL + '/devices', _objectSpread({
|
|
8368
8400
|
id: id
|
|
8369
8401
|
}, userID ? {
|
|
@@ -8371,17 +8403,17 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8371
8403
|
} : {}));
|
|
8372
8404
|
|
|
8373
8405
|
case 2:
|
|
8374
|
-
return
|
|
8406
|
+
return _context24.abrupt("return", _context24.sent);
|
|
8375
8407
|
|
|
8376
8408
|
case 3:
|
|
8377
8409
|
case "end":
|
|
8378
|
-
return
|
|
8410
|
+
return _context24.stop();
|
|
8379
8411
|
}
|
|
8380
8412
|
}
|
|
8381
|
-
},
|
|
8413
|
+
}, _callee24, this);
|
|
8382
8414
|
}));
|
|
8383
8415
|
|
|
8384
|
-
function removeDevice(
|
|
8416
|
+
function removeDevice(_x26, _x27) {
|
|
8385
8417
|
return _removeDevice.apply(this, arguments);
|
|
8386
8418
|
}
|
|
8387
8419
|
|
|
@@ -8398,15 +8430,15 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8398
8430
|
}, {
|
|
8399
8431
|
key: "getRateLimits",
|
|
8400
8432
|
value: function () {
|
|
8401
|
-
var _getRateLimits = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8433
|
+
var _getRateLimits = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee25(params) {
|
|
8402
8434
|
var _ref7, serverSide, web, android, ios, endpoints;
|
|
8403
8435
|
|
|
8404
|
-
return _regeneratorRuntime.wrap(function
|
|
8436
|
+
return _regeneratorRuntime.wrap(function _callee25$(_context25) {
|
|
8405
8437
|
while (1) {
|
|
8406
|
-
switch (
|
|
8438
|
+
switch (_context25.prev = _context25.next) {
|
|
8407
8439
|
case 0:
|
|
8408
8440
|
_ref7 = params || {}, serverSide = _ref7.serverSide, web = _ref7.web, android = _ref7.android, ios = _ref7.ios, endpoints = _ref7.endpoints;
|
|
8409
|
-
return
|
|
8441
|
+
return _context25.abrupt("return", this.get(this.baseURL + '/rate_limits', {
|
|
8410
8442
|
server_side: serverSide,
|
|
8411
8443
|
web: web,
|
|
8412
8444
|
android: android,
|
|
@@ -8416,13 +8448,13 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8416
8448
|
|
|
8417
8449
|
case 2:
|
|
8418
8450
|
case "end":
|
|
8419
|
-
return
|
|
8451
|
+
return _context25.stop();
|
|
8420
8452
|
}
|
|
8421
8453
|
}
|
|
8422
|
-
},
|
|
8454
|
+
}, _callee25, this);
|
|
8423
8455
|
}));
|
|
8424
8456
|
|
|
8425
|
-
function getRateLimits(
|
|
8457
|
+
function getRateLimits(_x28) {
|
|
8426
8458
|
return _getRateLimits.apply(this, arguments);
|
|
8427
8459
|
}
|
|
8428
8460
|
|
|
@@ -8453,6 +8485,8 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8453
8485
|
}, {
|
|
8454
8486
|
key: "channel",
|
|
8455
8487
|
value: function channel(channelType, channelIDOrCustom) {
|
|
8488
|
+
var _custom$members;
|
|
8489
|
+
|
|
8456
8490
|
var custom = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
|
8457
8491
|
|
|
8458
8492
|
if (!this.userID && !this._isUsingServerAuth()) {
|
|
@@ -8461,18 +8495,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8461
8495
|
|
|
8462
8496
|
if (~channelType.indexOf(':')) {
|
|
8463
8497
|
throw Error("Invalid channel group ".concat(channelType, ", can't contain the : character"));
|
|
8498
|
+
} // support channel("messaging", {options})
|
|
8499
|
+
|
|
8500
|
+
|
|
8501
|
+
if (channelIDOrCustom && _typeof(channelIDOrCustom) === 'object') {
|
|
8502
|
+
return this.getChannelByMembers(channelType, channelIDOrCustom);
|
|
8503
|
+
} // // support channel("messaging", undefined, {options})
|
|
8504
|
+
|
|
8505
|
+
|
|
8506
|
+
if (!channelIDOrCustom && _typeof(custom) === 'object' && (_custom$members = custom.members) !== null && _custom$members !== void 0 && _custom$members.length) {
|
|
8507
|
+
return this.getChannelByMembers(channelType, custom);
|
|
8464
8508
|
} // support channel("messaging", null, {options})
|
|
8465
8509
|
// support channel("messaging", undefined, {options})
|
|
8466
8510
|
// support channel("messaging", "", {options})
|
|
8467
8511
|
|
|
8468
8512
|
|
|
8469
|
-
if (channelIDOrCustom
|
|
8513
|
+
if (!channelIDOrCustom) {
|
|
8470
8514
|
return new Channel(this, channelType, undefined, custom);
|
|
8471
|
-
} // support channel("messaging", {options})
|
|
8472
|
-
|
|
8473
|
-
|
|
8474
|
-
if (_typeof(channelIDOrCustom) === 'object') {
|
|
8475
|
-
return this.getChannelByMembers(channelType, channelIDOrCustom);
|
|
8476
8515
|
}
|
|
8477
8516
|
|
|
8478
8517
|
return this.getChannelById(channelType, channelIDOrCustom, custom);
|
|
@@ -8506,26 +8545,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8506
8545
|
* @return {Promise<{ users: { [key: string]: UserResponse<StreamChatGenerics> } }>} list of updated users
|
|
8507
8546
|
*/
|
|
8508
8547
|
function () {
|
|
8509
|
-
var _partialUpdateUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8510
|
-
return _regeneratorRuntime.wrap(function
|
|
8548
|
+
var _partialUpdateUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee26(partialUserObject) {
|
|
8549
|
+
return _regeneratorRuntime.wrap(function _callee26$(_context26) {
|
|
8511
8550
|
while (1) {
|
|
8512
|
-
switch (
|
|
8551
|
+
switch (_context26.prev = _context26.next) {
|
|
8513
8552
|
case 0:
|
|
8514
|
-
|
|
8553
|
+
_context26.next = 2;
|
|
8515
8554
|
return this.partialUpdateUsers([partialUserObject]);
|
|
8516
8555
|
|
|
8517
8556
|
case 2:
|
|
8518
|
-
return
|
|
8557
|
+
return _context26.abrupt("return", _context26.sent);
|
|
8519
8558
|
|
|
8520
8559
|
case 3:
|
|
8521
8560
|
case "end":
|
|
8522
|
-
return
|
|
8561
|
+
return _context26.stop();
|
|
8523
8562
|
}
|
|
8524
8563
|
}
|
|
8525
|
-
},
|
|
8564
|
+
}, _callee26, this);
|
|
8526
8565
|
}));
|
|
8527
8566
|
|
|
8528
|
-
function partialUpdateUser(
|
|
8567
|
+
function partialUpdateUser(_x29) {
|
|
8529
8568
|
return _partialUpdateUser.apply(this, arguments);
|
|
8530
8569
|
}
|
|
8531
8570
|
|
|
@@ -8542,29 +8581,29 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8542
8581
|
}, {
|
|
8543
8582
|
key: "upsertUsers",
|
|
8544
8583
|
value: function () {
|
|
8545
|
-
var _upsertUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8584
|
+
var _upsertUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee27(users) {
|
|
8546
8585
|
var userMap, _iterator4, _step4, userObject;
|
|
8547
8586
|
|
|
8548
|
-
return _regeneratorRuntime.wrap(function
|
|
8587
|
+
return _regeneratorRuntime.wrap(function _callee27$(_context27) {
|
|
8549
8588
|
while (1) {
|
|
8550
|
-
switch (
|
|
8589
|
+
switch (_context27.prev = _context27.next) {
|
|
8551
8590
|
case 0:
|
|
8552
8591
|
userMap = {};
|
|
8553
8592
|
_iterator4 = _createForOfIteratorHelper(users);
|
|
8554
|
-
|
|
8593
|
+
_context27.prev = 2;
|
|
8555
8594
|
|
|
8556
8595
|
_iterator4.s();
|
|
8557
8596
|
|
|
8558
8597
|
case 4:
|
|
8559
8598
|
if ((_step4 = _iterator4.n()).done) {
|
|
8560
|
-
|
|
8599
|
+
_context27.next = 11;
|
|
8561
8600
|
break;
|
|
8562
8601
|
}
|
|
8563
8602
|
|
|
8564
8603
|
userObject = _step4.value;
|
|
8565
8604
|
|
|
8566
8605
|
if (userObject.id) {
|
|
8567
|
-
|
|
8606
|
+
_context27.next = 8;
|
|
8568
8607
|
break;
|
|
8569
8608
|
}
|
|
8570
8609
|
|
|
@@ -8574,44 +8613,44 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8574
8613
|
userMap[userObject.id] = userObject;
|
|
8575
8614
|
|
|
8576
8615
|
case 9:
|
|
8577
|
-
|
|
8616
|
+
_context27.next = 4;
|
|
8578
8617
|
break;
|
|
8579
8618
|
|
|
8580
8619
|
case 11:
|
|
8581
|
-
|
|
8620
|
+
_context27.next = 16;
|
|
8582
8621
|
break;
|
|
8583
8622
|
|
|
8584
8623
|
case 13:
|
|
8585
|
-
|
|
8586
|
-
|
|
8624
|
+
_context27.prev = 13;
|
|
8625
|
+
_context27.t0 = _context27["catch"](2);
|
|
8587
8626
|
|
|
8588
|
-
_iterator4.e(
|
|
8627
|
+
_iterator4.e(_context27.t0);
|
|
8589
8628
|
|
|
8590
8629
|
case 16:
|
|
8591
|
-
|
|
8630
|
+
_context27.prev = 16;
|
|
8592
8631
|
|
|
8593
8632
|
_iterator4.f();
|
|
8594
8633
|
|
|
8595
|
-
return
|
|
8634
|
+
return _context27.finish(16);
|
|
8596
8635
|
|
|
8597
8636
|
case 19:
|
|
8598
|
-
|
|
8637
|
+
_context27.next = 21;
|
|
8599
8638
|
return this.post(this.baseURL + '/users', {
|
|
8600
8639
|
users: userMap
|
|
8601
8640
|
});
|
|
8602
8641
|
|
|
8603
8642
|
case 21:
|
|
8604
|
-
return
|
|
8643
|
+
return _context27.abrupt("return", _context27.sent);
|
|
8605
8644
|
|
|
8606
8645
|
case 22:
|
|
8607
8646
|
case "end":
|
|
8608
|
-
return
|
|
8647
|
+
return _context27.stop();
|
|
8609
8648
|
}
|
|
8610
8649
|
}
|
|
8611
|
-
},
|
|
8650
|
+
}, _callee27, this, [[2, 13, 16, 19]]);
|
|
8612
8651
|
}));
|
|
8613
8652
|
|
|
8614
|
-
function upsertUsers(
|
|
8653
|
+
function upsertUsers(_x30) {
|
|
8615
8654
|
return _upsertUsers.apply(this, arguments);
|
|
8616
8655
|
}
|
|
8617
8656
|
|
|
@@ -8659,72 +8698,72 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8659
8698
|
* @return {Promise<{ users: { [key: string]: UserResponse<StreamChatGenerics> } }>}
|
|
8660
8699
|
*/
|
|
8661
8700
|
function () {
|
|
8662
|
-
var _partialUpdateUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8701
|
+
var _partialUpdateUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee28(users) {
|
|
8663
8702
|
var _iterator5, _step5, userObject;
|
|
8664
8703
|
|
|
8665
|
-
return _regeneratorRuntime.wrap(function
|
|
8704
|
+
return _regeneratorRuntime.wrap(function _callee28$(_context28) {
|
|
8666
8705
|
while (1) {
|
|
8667
|
-
switch (
|
|
8706
|
+
switch (_context28.prev = _context28.next) {
|
|
8668
8707
|
case 0:
|
|
8669
8708
|
_iterator5 = _createForOfIteratorHelper(users);
|
|
8670
|
-
|
|
8709
|
+
_context28.prev = 1;
|
|
8671
8710
|
|
|
8672
8711
|
_iterator5.s();
|
|
8673
8712
|
|
|
8674
8713
|
case 3:
|
|
8675
8714
|
if ((_step5 = _iterator5.n()).done) {
|
|
8676
|
-
|
|
8715
|
+
_context28.next = 9;
|
|
8677
8716
|
break;
|
|
8678
8717
|
}
|
|
8679
8718
|
|
|
8680
8719
|
userObject = _step5.value;
|
|
8681
8720
|
|
|
8682
8721
|
if (userObject.id) {
|
|
8683
|
-
|
|
8722
|
+
_context28.next = 7;
|
|
8684
8723
|
break;
|
|
8685
8724
|
}
|
|
8686
8725
|
|
|
8687
8726
|
throw Error('User ID is required when updating a user');
|
|
8688
8727
|
|
|
8689
8728
|
case 7:
|
|
8690
|
-
|
|
8729
|
+
_context28.next = 3;
|
|
8691
8730
|
break;
|
|
8692
8731
|
|
|
8693
8732
|
case 9:
|
|
8694
|
-
|
|
8733
|
+
_context28.next = 14;
|
|
8695
8734
|
break;
|
|
8696
8735
|
|
|
8697
8736
|
case 11:
|
|
8698
|
-
|
|
8699
|
-
|
|
8737
|
+
_context28.prev = 11;
|
|
8738
|
+
_context28.t0 = _context28["catch"](1);
|
|
8700
8739
|
|
|
8701
|
-
_iterator5.e(
|
|
8740
|
+
_iterator5.e(_context28.t0);
|
|
8702
8741
|
|
|
8703
8742
|
case 14:
|
|
8704
|
-
|
|
8743
|
+
_context28.prev = 14;
|
|
8705
8744
|
|
|
8706
8745
|
_iterator5.f();
|
|
8707
8746
|
|
|
8708
|
-
return
|
|
8747
|
+
return _context28.finish(14);
|
|
8709
8748
|
|
|
8710
8749
|
case 17:
|
|
8711
|
-
|
|
8750
|
+
_context28.next = 19;
|
|
8712
8751
|
return this.patch(this.baseURL + '/users', {
|
|
8713
8752
|
users: users
|
|
8714
8753
|
});
|
|
8715
8754
|
|
|
8716
8755
|
case 19:
|
|
8717
|
-
return
|
|
8756
|
+
return _context28.abrupt("return", _context28.sent);
|
|
8718
8757
|
|
|
8719
8758
|
case 20:
|
|
8720
8759
|
case "end":
|
|
8721
|
-
return
|
|
8760
|
+
return _context28.stop();
|
|
8722
8761
|
}
|
|
8723
8762
|
}
|
|
8724
|
-
},
|
|
8763
|
+
}, _callee28, this, [[1, 11, 14, 17]]);
|
|
8725
8764
|
}));
|
|
8726
8765
|
|
|
8727
|
-
function partialUpdateUsers(
|
|
8766
|
+
function partialUpdateUsers(_x31) {
|
|
8728
8767
|
return _partialUpdateUsers.apply(this, arguments);
|
|
8729
8768
|
}
|
|
8730
8769
|
|
|
@@ -8733,26 +8772,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8733
8772
|
}, {
|
|
8734
8773
|
key: "deleteUser",
|
|
8735
8774
|
value: function () {
|
|
8736
|
-
var _deleteUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8737
|
-
return _regeneratorRuntime.wrap(function
|
|
8775
|
+
var _deleteUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee29(userID, params) {
|
|
8776
|
+
return _regeneratorRuntime.wrap(function _callee29$(_context29) {
|
|
8738
8777
|
while (1) {
|
|
8739
|
-
switch (
|
|
8778
|
+
switch (_context29.prev = _context29.next) {
|
|
8740
8779
|
case 0:
|
|
8741
|
-
|
|
8780
|
+
_context29.next = 2;
|
|
8742
8781
|
return this.delete(this.baseURL + "/users/".concat(userID), params);
|
|
8743
8782
|
|
|
8744
8783
|
case 2:
|
|
8745
|
-
return
|
|
8784
|
+
return _context29.abrupt("return", _context29.sent);
|
|
8746
8785
|
|
|
8747
8786
|
case 3:
|
|
8748
8787
|
case "end":
|
|
8749
|
-
return
|
|
8788
|
+
return _context29.stop();
|
|
8750
8789
|
}
|
|
8751
8790
|
}
|
|
8752
|
-
},
|
|
8791
|
+
}, _callee29, this);
|
|
8753
8792
|
}));
|
|
8754
8793
|
|
|
8755
|
-
function deleteUser(
|
|
8794
|
+
function deleteUser(_x32, _x33) {
|
|
8756
8795
|
return _deleteUser.apply(this, arguments);
|
|
8757
8796
|
}
|
|
8758
8797
|
|
|
@@ -8769,28 +8808,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8769
8808
|
}, {
|
|
8770
8809
|
key: "restoreUsers",
|
|
8771
8810
|
value: function () {
|
|
8772
|
-
var _restoreUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8773
|
-
return _regeneratorRuntime.wrap(function
|
|
8811
|
+
var _restoreUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee30(user_ids) {
|
|
8812
|
+
return _regeneratorRuntime.wrap(function _callee30$(_context30) {
|
|
8774
8813
|
while (1) {
|
|
8775
|
-
switch (
|
|
8814
|
+
switch (_context30.prev = _context30.next) {
|
|
8776
8815
|
case 0:
|
|
8777
|
-
|
|
8816
|
+
_context30.next = 2;
|
|
8778
8817
|
return this.post(this.baseURL + "/users/restore", {
|
|
8779
8818
|
user_ids: user_ids
|
|
8780
8819
|
});
|
|
8781
8820
|
|
|
8782
8821
|
case 2:
|
|
8783
|
-
return
|
|
8822
|
+
return _context30.abrupt("return", _context30.sent);
|
|
8784
8823
|
|
|
8785
8824
|
case 3:
|
|
8786
8825
|
case "end":
|
|
8787
|
-
return
|
|
8826
|
+
return _context30.stop();
|
|
8788
8827
|
}
|
|
8789
8828
|
}
|
|
8790
|
-
},
|
|
8829
|
+
}, _callee30, this);
|
|
8791
8830
|
}));
|
|
8792
8831
|
|
|
8793
|
-
function restoreUsers(
|
|
8832
|
+
function restoreUsers(_x34) {
|
|
8794
8833
|
return _restoreUsers.apply(this, arguments);
|
|
8795
8834
|
}
|
|
8796
8835
|
|
|
@@ -8808,26 +8847,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8808
8847
|
}, {
|
|
8809
8848
|
key: "reactivateUser",
|
|
8810
8849
|
value: function () {
|
|
8811
|
-
var _reactivateUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8812
|
-
return _regeneratorRuntime.wrap(function
|
|
8850
|
+
var _reactivateUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee31(userID, options) {
|
|
8851
|
+
return _regeneratorRuntime.wrap(function _callee31$(_context31) {
|
|
8813
8852
|
while (1) {
|
|
8814
|
-
switch (
|
|
8853
|
+
switch (_context31.prev = _context31.next) {
|
|
8815
8854
|
case 0:
|
|
8816
|
-
|
|
8855
|
+
_context31.next = 2;
|
|
8817
8856
|
return this.post(this.baseURL + "/users/".concat(userID, "/reactivate"), _objectSpread({}, options));
|
|
8818
8857
|
|
|
8819
8858
|
case 2:
|
|
8820
|
-
return
|
|
8859
|
+
return _context31.abrupt("return", _context31.sent);
|
|
8821
8860
|
|
|
8822
8861
|
case 3:
|
|
8823
8862
|
case "end":
|
|
8824
|
-
return
|
|
8863
|
+
return _context31.stop();
|
|
8825
8864
|
}
|
|
8826
8865
|
}
|
|
8827
|
-
},
|
|
8866
|
+
}, _callee31, this);
|
|
8828
8867
|
}));
|
|
8829
8868
|
|
|
8830
|
-
function reactivateUser(
|
|
8869
|
+
function reactivateUser(_x35, _x36) {
|
|
8831
8870
|
return _reactivateUser.apply(this, arguments);
|
|
8832
8871
|
}
|
|
8833
8872
|
|
|
@@ -8845,28 +8884,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8845
8884
|
}, {
|
|
8846
8885
|
key: "reactivateUsers",
|
|
8847
8886
|
value: function () {
|
|
8848
|
-
var _reactivateUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8849
|
-
return _regeneratorRuntime.wrap(function
|
|
8887
|
+
var _reactivateUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee32(user_ids, options) {
|
|
8888
|
+
return _regeneratorRuntime.wrap(function _callee32$(_context32) {
|
|
8850
8889
|
while (1) {
|
|
8851
|
-
switch (
|
|
8890
|
+
switch (_context32.prev = _context32.next) {
|
|
8852
8891
|
case 0:
|
|
8853
|
-
|
|
8892
|
+
_context32.next = 2;
|
|
8854
8893
|
return this.post(this.baseURL + "/users/reactivate", _objectSpread({
|
|
8855
8894
|
user_ids: user_ids
|
|
8856
8895
|
}, options));
|
|
8857
8896
|
|
|
8858
8897
|
case 2:
|
|
8859
|
-
return
|
|
8898
|
+
return _context32.abrupt("return", _context32.sent);
|
|
8860
8899
|
|
|
8861
8900
|
case 3:
|
|
8862
8901
|
case "end":
|
|
8863
|
-
return
|
|
8902
|
+
return _context32.stop();
|
|
8864
8903
|
}
|
|
8865
8904
|
}
|
|
8866
|
-
},
|
|
8905
|
+
}, _callee32, this);
|
|
8867
8906
|
}));
|
|
8868
8907
|
|
|
8869
|
-
function reactivateUsers(
|
|
8908
|
+
function reactivateUsers(_x37, _x38) {
|
|
8870
8909
|
return _reactivateUsers.apply(this, arguments);
|
|
8871
8910
|
}
|
|
8872
8911
|
|
|
@@ -8884,26 +8923,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8884
8923
|
}, {
|
|
8885
8924
|
key: "deactivateUser",
|
|
8886
8925
|
value: function () {
|
|
8887
|
-
var _deactivateUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8888
|
-
return _regeneratorRuntime.wrap(function
|
|
8926
|
+
var _deactivateUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee33(userID, options) {
|
|
8927
|
+
return _regeneratorRuntime.wrap(function _callee33$(_context33) {
|
|
8889
8928
|
while (1) {
|
|
8890
|
-
switch (
|
|
8929
|
+
switch (_context33.prev = _context33.next) {
|
|
8891
8930
|
case 0:
|
|
8892
|
-
|
|
8931
|
+
_context33.next = 2;
|
|
8893
8932
|
return this.post(this.baseURL + "/users/".concat(userID, "/deactivate"), _objectSpread({}, options));
|
|
8894
8933
|
|
|
8895
8934
|
case 2:
|
|
8896
|
-
return
|
|
8935
|
+
return _context33.abrupt("return", _context33.sent);
|
|
8897
8936
|
|
|
8898
8937
|
case 3:
|
|
8899
8938
|
case "end":
|
|
8900
|
-
return
|
|
8939
|
+
return _context33.stop();
|
|
8901
8940
|
}
|
|
8902
8941
|
}
|
|
8903
|
-
},
|
|
8942
|
+
}, _callee33, this);
|
|
8904
8943
|
}));
|
|
8905
8944
|
|
|
8906
|
-
function deactivateUser(
|
|
8945
|
+
function deactivateUser(_x39, _x40) {
|
|
8907
8946
|
return _deactivateUser.apply(this, arguments);
|
|
8908
8947
|
}
|
|
8909
8948
|
|
|
@@ -8921,28 +8960,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8921
8960
|
}, {
|
|
8922
8961
|
key: "deactivateUsers",
|
|
8923
8962
|
value: function () {
|
|
8924
|
-
var _deactivateUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8925
|
-
return _regeneratorRuntime.wrap(function
|
|
8963
|
+
var _deactivateUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee34(user_ids, options) {
|
|
8964
|
+
return _regeneratorRuntime.wrap(function _callee34$(_context34) {
|
|
8926
8965
|
while (1) {
|
|
8927
|
-
switch (
|
|
8966
|
+
switch (_context34.prev = _context34.next) {
|
|
8928
8967
|
case 0:
|
|
8929
|
-
|
|
8968
|
+
_context34.next = 2;
|
|
8930
8969
|
return this.post(this.baseURL + "/users/deactivate", _objectSpread({
|
|
8931
8970
|
user_ids: user_ids
|
|
8932
8971
|
}, options));
|
|
8933
8972
|
|
|
8934
8973
|
case 2:
|
|
8935
|
-
return
|
|
8974
|
+
return _context34.abrupt("return", _context34.sent);
|
|
8936
8975
|
|
|
8937
8976
|
case 3:
|
|
8938
8977
|
case "end":
|
|
8939
|
-
return
|
|
8978
|
+
return _context34.stop();
|
|
8940
8979
|
}
|
|
8941
8980
|
}
|
|
8942
|
-
},
|
|
8981
|
+
}, _callee34, this);
|
|
8943
8982
|
}));
|
|
8944
8983
|
|
|
8945
|
-
function deactivateUsers(
|
|
8984
|
+
function deactivateUsers(_x41, _x42) {
|
|
8946
8985
|
return _deactivateUsers.apply(this, arguments);
|
|
8947
8986
|
}
|
|
8948
8987
|
|
|
@@ -8951,26 +8990,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8951
8990
|
}, {
|
|
8952
8991
|
key: "exportUser",
|
|
8953
8992
|
value: function () {
|
|
8954
|
-
var _exportUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8955
|
-
return _regeneratorRuntime.wrap(function
|
|
8993
|
+
var _exportUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee35(userID, options) {
|
|
8994
|
+
return _regeneratorRuntime.wrap(function _callee35$(_context35) {
|
|
8956
8995
|
while (1) {
|
|
8957
|
-
switch (
|
|
8996
|
+
switch (_context35.prev = _context35.next) {
|
|
8958
8997
|
case 0:
|
|
8959
|
-
|
|
8998
|
+
_context35.next = 2;
|
|
8960
8999
|
return this.get(this.baseURL + "/users/".concat(userID, "/export"), _objectSpread({}, options));
|
|
8961
9000
|
|
|
8962
9001
|
case 2:
|
|
8963
|
-
return
|
|
9002
|
+
return _context35.abrupt("return", _context35.sent);
|
|
8964
9003
|
|
|
8965
9004
|
case 3:
|
|
8966
9005
|
case "end":
|
|
8967
|
-
return
|
|
9006
|
+
return _context35.stop();
|
|
8968
9007
|
}
|
|
8969
9008
|
}
|
|
8970
|
-
},
|
|
9009
|
+
}, _callee35, this);
|
|
8971
9010
|
}));
|
|
8972
9011
|
|
|
8973
|
-
function exportUser(
|
|
9012
|
+
function exportUser(_x43, _x44) {
|
|
8974
9013
|
return _exportUser.apply(this, arguments);
|
|
8975
9014
|
}
|
|
8976
9015
|
|
|
@@ -8986,28 +9025,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8986
9025
|
}, {
|
|
8987
9026
|
key: "banUser",
|
|
8988
9027
|
value: function () {
|
|
8989
|
-
var _banUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8990
|
-
return _regeneratorRuntime.wrap(function
|
|
9028
|
+
var _banUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee36(targetUserID, options) {
|
|
9029
|
+
return _regeneratorRuntime.wrap(function _callee36$(_context36) {
|
|
8991
9030
|
while (1) {
|
|
8992
|
-
switch (
|
|
9031
|
+
switch (_context36.prev = _context36.next) {
|
|
8993
9032
|
case 0:
|
|
8994
|
-
|
|
9033
|
+
_context36.next = 2;
|
|
8995
9034
|
return this.post(this.baseURL + '/moderation/ban', _objectSpread({
|
|
8996
9035
|
target_user_id: targetUserID
|
|
8997
9036
|
}, options));
|
|
8998
9037
|
|
|
8999
9038
|
case 2:
|
|
9000
|
-
return
|
|
9039
|
+
return _context36.abrupt("return", _context36.sent);
|
|
9001
9040
|
|
|
9002
9041
|
case 3:
|
|
9003
9042
|
case "end":
|
|
9004
|
-
return
|
|
9043
|
+
return _context36.stop();
|
|
9005
9044
|
}
|
|
9006
9045
|
}
|
|
9007
|
-
},
|
|
9046
|
+
}, _callee36, this);
|
|
9008
9047
|
}));
|
|
9009
9048
|
|
|
9010
|
-
function banUser(
|
|
9049
|
+
function banUser(_x45, _x46) {
|
|
9011
9050
|
return _banUser.apply(this, arguments);
|
|
9012
9051
|
}
|
|
9013
9052
|
|
|
@@ -9023,28 +9062,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9023
9062
|
}, {
|
|
9024
9063
|
key: "unbanUser",
|
|
9025
9064
|
value: function () {
|
|
9026
|
-
var _unbanUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9027
|
-
return _regeneratorRuntime.wrap(function
|
|
9065
|
+
var _unbanUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee37(targetUserID, options) {
|
|
9066
|
+
return _regeneratorRuntime.wrap(function _callee37$(_context37) {
|
|
9028
9067
|
while (1) {
|
|
9029
|
-
switch (
|
|
9068
|
+
switch (_context37.prev = _context37.next) {
|
|
9030
9069
|
case 0:
|
|
9031
|
-
|
|
9070
|
+
_context37.next = 2;
|
|
9032
9071
|
return this.delete(this.baseURL + '/moderation/ban', _objectSpread({
|
|
9033
9072
|
target_user_id: targetUserID
|
|
9034
9073
|
}, options));
|
|
9035
9074
|
|
|
9036
9075
|
case 2:
|
|
9037
|
-
return
|
|
9076
|
+
return _context37.abrupt("return", _context37.sent);
|
|
9038
9077
|
|
|
9039
9078
|
case 3:
|
|
9040
9079
|
case "end":
|
|
9041
|
-
return
|
|
9080
|
+
return _context37.stop();
|
|
9042
9081
|
}
|
|
9043
9082
|
}
|
|
9044
|
-
},
|
|
9083
|
+
}, _callee37, this);
|
|
9045
9084
|
}));
|
|
9046
9085
|
|
|
9047
|
-
function unbanUser(
|
|
9086
|
+
function unbanUser(_x47, _x48) {
|
|
9048
9087
|
return _unbanUser.apply(this, arguments);
|
|
9049
9088
|
}
|
|
9050
9089
|
|
|
@@ -9060,28 +9099,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9060
9099
|
}, {
|
|
9061
9100
|
key: "shadowBan",
|
|
9062
9101
|
value: function () {
|
|
9063
|
-
var _shadowBan = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9064
|
-
return _regeneratorRuntime.wrap(function
|
|
9102
|
+
var _shadowBan = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee38(targetUserID, options) {
|
|
9103
|
+
return _regeneratorRuntime.wrap(function _callee38$(_context38) {
|
|
9065
9104
|
while (1) {
|
|
9066
|
-
switch (
|
|
9105
|
+
switch (_context38.prev = _context38.next) {
|
|
9067
9106
|
case 0:
|
|
9068
|
-
|
|
9107
|
+
_context38.next = 2;
|
|
9069
9108
|
return this.banUser(targetUserID, _objectSpread({
|
|
9070
9109
|
shadow: true
|
|
9071
9110
|
}, options));
|
|
9072
9111
|
|
|
9073
9112
|
case 2:
|
|
9074
|
-
return
|
|
9113
|
+
return _context38.abrupt("return", _context38.sent);
|
|
9075
9114
|
|
|
9076
9115
|
case 3:
|
|
9077
9116
|
case "end":
|
|
9078
|
-
return
|
|
9117
|
+
return _context38.stop();
|
|
9079
9118
|
}
|
|
9080
9119
|
}
|
|
9081
|
-
},
|
|
9120
|
+
}, _callee38, this);
|
|
9082
9121
|
}));
|
|
9083
9122
|
|
|
9084
|
-
function shadowBan(
|
|
9123
|
+
function shadowBan(_x49, _x50) {
|
|
9085
9124
|
return _shadowBan.apply(this, arguments);
|
|
9086
9125
|
}
|
|
9087
9126
|
|
|
@@ -9097,28 +9136,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9097
9136
|
}, {
|
|
9098
9137
|
key: "removeShadowBan",
|
|
9099
9138
|
value: function () {
|
|
9100
|
-
var _removeShadowBan = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9101
|
-
return _regeneratorRuntime.wrap(function
|
|
9139
|
+
var _removeShadowBan = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee39(targetUserID, options) {
|
|
9140
|
+
return _regeneratorRuntime.wrap(function _callee39$(_context39) {
|
|
9102
9141
|
while (1) {
|
|
9103
|
-
switch (
|
|
9142
|
+
switch (_context39.prev = _context39.next) {
|
|
9104
9143
|
case 0:
|
|
9105
|
-
|
|
9144
|
+
_context39.next = 2;
|
|
9106
9145
|
return this.unbanUser(targetUserID, _objectSpread({
|
|
9107
9146
|
shadow: true
|
|
9108
9147
|
}, options));
|
|
9109
9148
|
|
|
9110
9149
|
case 2:
|
|
9111
|
-
return
|
|
9150
|
+
return _context39.abrupt("return", _context39.sent);
|
|
9112
9151
|
|
|
9113
9152
|
case 3:
|
|
9114
9153
|
case "end":
|
|
9115
|
-
return
|
|
9154
|
+
return _context39.stop();
|
|
9116
9155
|
}
|
|
9117
9156
|
}
|
|
9118
|
-
},
|
|
9157
|
+
}, _callee39, this);
|
|
9119
9158
|
}));
|
|
9120
9159
|
|
|
9121
|
-
function removeShadowBan(
|
|
9160
|
+
function removeShadowBan(_x51, _x52) {
|
|
9122
9161
|
return _removeShadowBan.apply(this, arguments);
|
|
9123
9162
|
}
|
|
9124
9163
|
|
|
@@ -9135,15 +9174,15 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9135
9174
|
}, {
|
|
9136
9175
|
key: "muteUser",
|
|
9137
9176
|
value: function () {
|
|
9138
|
-
var _muteUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9177
|
+
var _muteUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee40(targetID, userID) {
|
|
9139
9178
|
var options,
|
|
9140
|
-
|
|
9141
|
-
return _regeneratorRuntime.wrap(function
|
|
9179
|
+
_args40 = arguments;
|
|
9180
|
+
return _regeneratorRuntime.wrap(function _callee40$(_context40) {
|
|
9142
9181
|
while (1) {
|
|
9143
|
-
switch (
|
|
9182
|
+
switch (_context40.prev = _context40.next) {
|
|
9144
9183
|
case 0:
|
|
9145
|
-
options =
|
|
9146
|
-
|
|
9184
|
+
options = _args40.length > 2 && _args40[2] !== undefined ? _args40[2] : {};
|
|
9185
|
+
_context40.next = 3;
|
|
9147
9186
|
return this.post(this.baseURL + '/moderation/mute', _objectSpread(_objectSpread({
|
|
9148
9187
|
target_id: targetID
|
|
9149
9188
|
}, userID ? {
|
|
@@ -9151,17 +9190,17 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9151
9190
|
} : {}), options));
|
|
9152
9191
|
|
|
9153
9192
|
case 3:
|
|
9154
|
-
return
|
|
9193
|
+
return _context40.abrupt("return", _context40.sent);
|
|
9155
9194
|
|
|
9156
9195
|
case 4:
|
|
9157
9196
|
case "end":
|
|
9158
|
-
return
|
|
9197
|
+
return _context40.stop();
|
|
9159
9198
|
}
|
|
9160
9199
|
}
|
|
9161
|
-
},
|
|
9200
|
+
}, _callee40, this);
|
|
9162
9201
|
}));
|
|
9163
9202
|
|
|
9164
|
-
function muteUser(
|
|
9203
|
+
function muteUser(_x53, _x54) {
|
|
9165
9204
|
return _muteUser.apply(this, arguments);
|
|
9166
9205
|
}
|
|
9167
9206
|
|
|
@@ -9177,12 +9216,12 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9177
9216
|
}, {
|
|
9178
9217
|
key: "unmuteUser",
|
|
9179
9218
|
value: function () {
|
|
9180
|
-
var _unmuteUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9181
|
-
return _regeneratorRuntime.wrap(function
|
|
9219
|
+
var _unmuteUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee41(targetID, currentUserID) {
|
|
9220
|
+
return _regeneratorRuntime.wrap(function _callee41$(_context41) {
|
|
9182
9221
|
while (1) {
|
|
9183
|
-
switch (
|
|
9222
|
+
switch (_context41.prev = _context41.next) {
|
|
9184
9223
|
case 0:
|
|
9185
|
-
|
|
9224
|
+
_context41.next = 2;
|
|
9186
9225
|
return this.post(this.baseURL + '/moderation/unmute', _objectSpread({
|
|
9187
9226
|
target_id: targetID
|
|
9188
9227
|
}, currentUserID ? {
|
|
@@ -9190,17 +9229,17 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9190
9229
|
} : {}));
|
|
9191
9230
|
|
|
9192
9231
|
case 2:
|
|
9193
|
-
return
|
|
9232
|
+
return _context41.abrupt("return", _context41.sent);
|
|
9194
9233
|
|
|
9195
9234
|
case 3:
|
|
9196
9235
|
case "end":
|
|
9197
|
-
return
|
|
9236
|
+
return _context41.stop();
|
|
9198
9237
|
}
|
|
9199
9238
|
}
|
|
9200
|
-
},
|
|
9239
|
+
}, _callee41, this);
|
|
9201
9240
|
}));
|
|
9202
9241
|
|
|
9203
|
-
function unmuteUser(
|
|
9242
|
+
function unmuteUser(_x55, _x56) {
|
|
9204
9243
|
return _unmuteUser.apply(this, arguments);
|
|
9205
9244
|
}
|
|
9206
9245
|
|
|
@@ -9235,31 +9274,31 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9235
9274
|
}, {
|
|
9236
9275
|
key: "flagMessage",
|
|
9237
9276
|
value: function () {
|
|
9238
|
-
var _flagMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9277
|
+
var _flagMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee42(targetMessageID) {
|
|
9239
9278
|
var options,
|
|
9240
|
-
|
|
9241
|
-
return _regeneratorRuntime.wrap(function
|
|
9279
|
+
_args42 = arguments;
|
|
9280
|
+
return _regeneratorRuntime.wrap(function _callee42$(_context42) {
|
|
9242
9281
|
while (1) {
|
|
9243
|
-
switch (
|
|
9282
|
+
switch (_context42.prev = _context42.next) {
|
|
9244
9283
|
case 0:
|
|
9245
|
-
options =
|
|
9246
|
-
|
|
9284
|
+
options = _args42.length > 1 && _args42[1] !== undefined ? _args42[1] : {};
|
|
9285
|
+
_context42.next = 3;
|
|
9247
9286
|
return this.post(this.baseURL + '/moderation/flag', _objectSpread({
|
|
9248
9287
|
target_message_id: targetMessageID
|
|
9249
9288
|
}, options));
|
|
9250
9289
|
|
|
9251
9290
|
case 3:
|
|
9252
|
-
return
|
|
9291
|
+
return _context42.abrupt("return", _context42.sent);
|
|
9253
9292
|
|
|
9254
9293
|
case 4:
|
|
9255
9294
|
case "end":
|
|
9256
|
-
return
|
|
9295
|
+
return _context42.stop();
|
|
9257
9296
|
}
|
|
9258
9297
|
}
|
|
9259
|
-
},
|
|
9298
|
+
}, _callee42, this);
|
|
9260
9299
|
}));
|
|
9261
9300
|
|
|
9262
|
-
function flagMessage(
|
|
9301
|
+
function flagMessage(_x57) {
|
|
9263
9302
|
return _flagMessage.apply(this, arguments);
|
|
9264
9303
|
}
|
|
9265
9304
|
|
|
@@ -9275,31 +9314,31 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9275
9314
|
}, {
|
|
9276
9315
|
key: "flagUser",
|
|
9277
9316
|
value: function () {
|
|
9278
|
-
var _flagUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9317
|
+
var _flagUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee43(targetID) {
|
|
9279
9318
|
var options,
|
|
9280
|
-
|
|
9281
|
-
return _regeneratorRuntime.wrap(function
|
|
9319
|
+
_args43 = arguments;
|
|
9320
|
+
return _regeneratorRuntime.wrap(function _callee43$(_context43) {
|
|
9282
9321
|
while (1) {
|
|
9283
|
-
switch (
|
|
9322
|
+
switch (_context43.prev = _context43.next) {
|
|
9284
9323
|
case 0:
|
|
9285
|
-
options =
|
|
9286
|
-
|
|
9324
|
+
options = _args43.length > 1 && _args43[1] !== undefined ? _args43[1] : {};
|
|
9325
|
+
_context43.next = 3;
|
|
9287
9326
|
return this.post(this.baseURL + '/moderation/flag', _objectSpread({
|
|
9288
9327
|
target_user_id: targetID
|
|
9289
9328
|
}, options));
|
|
9290
9329
|
|
|
9291
9330
|
case 3:
|
|
9292
|
-
return
|
|
9331
|
+
return _context43.abrupt("return", _context43.sent);
|
|
9293
9332
|
|
|
9294
9333
|
case 4:
|
|
9295
9334
|
case "end":
|
|
9296
|
-
return
|
|
9335
|
+
return _context43.stop();
|
|
9297
9336
|
}
|
|
9298
9337
|
}
|
|
9299
|
-
},
|
|
9338
|
+
}, _callee43, this);
|
|
9300
9339
|
}));
|
|
9301
9340
|
|
|
9302
|
-
function flagUser(
|
|
9341
|
+
function flagUser(_x58) {
|
|
9303
9342
|
return _flagUser.apply(this, arguments);
|
|
9304
9343
|
}
|
|
9305
9344
|
|
|
@@ -9315,31 +9354,31 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9315
9354
|
}, {
|
|
9316
9355
|
key: "unflagMessage",
|
|
9317
9356
|
value: function () {
|
|
9318
|
-
var _unflagMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9357
|
+
var _unflagMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee44(targetMessageID) {
|
|
9319
9358
|
var options,
|
|
9320
|
-
|
|
9321
|
-
return _regeneratorRuntime.wrap(function
|
|
9359
|
+
_args44 = arguments;
|
|
9360
|
+
return _regeneratorRuntime.wrap(function _callee44$(_context44) {
|
|
9322
9361
|
while (1) {
|
|
9323
|
-
switch (
|
|
9362
|
+
switch (_context44.prev = _context44.next) {
|
|
9324
9363
|
case 0:
|
|
9325
|
-
options =
|
|
9326
|
-
|
|
9364
|
+
options = _args44.length > 1 && _args44[1] !== undefined ? _args44[1] : {};
|
|
9365
|
+
_context44.next = 3;
|
|
9327
9366
|
return this.post(this.baseURL + '/moderation/unflag', _objectSpread({
|
|
9328
9367
|
target_message_id: targetMessageID
|
|
9329
9368
|
}, options));
|
|
9330
9369
|
|
|
9331
9370
|
case 3:
|
|
9332
|
-
return
|
|
9371
|
+
return _context44.abrupt("return", _context44.sent);
|
|
9333
9372
|
|
|
9334
9373
|
case 4:
|
|
9335
9374
|
case "end":
|
|
9336
|
-
return
|
|
9375
|
+
return _context44.stop();
|
|
9337
9376
|
}
|
|
9338
9377
|
}
|
|
9339
|
-
},
|
|
9378
|
+
}, _callee44, this);
|
|
9340
9379
|
}));
|
|
9341
9380
|
|
|
9342
|
-
function unflagMessage(
|
|
9381
|
+
function unflagMessage(_x59) {
|
|
9343
9382
|
return _unflagMessage.apply(this, arguments);
|
|
9344
9383
|
}
|
|
9345
9384
|
|
|
@@ -9355,31 +9394,31 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9355
9394
|
}, {
|
|
9356
9395
|
key: "unflagUser",
|
|
9357
9396
|
value: function () {
|
|
9358
|
-
var _unflagUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9397
|
+
var _unflagUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee45(targetID) {
|
|
9359
9398
|
var options,
|
|
9360
|
-
|
|
9361
|
-
return _regeneratorRuntime.wrap(function
|
|
9399
|
+
_args45 = arguments;
|
|
9400
|
+
return _regeneratorRuntime.wrap(function _callee45$(_context45) {
|
|
9362
9401
|
while (1) {
|
|
9363
|
-
switch (
|
|
9402
|
+
switch (_context45.prev = _context45.next) {
|
|
9364
9403
|
case 0:
|
|
9365
|
-
options =
|
|
9366
|
-
|
|
9404
|
+
options = _args45.length > 1 && _args45[1] !== undefined ? _args45[1] : {};
|
|
9405
|
+
_context45.next = 3;
|
|
9367
9406
|
return this.post(this.baseURL + '/moderation/unflag', _objectSpread({
|
|
9368
9407
|
target_user_id: targetID
|
|
9369
9408
|
}, options));
|
|
9370
9409
|
|
|
9371
9410
|
case 3:
|
|
9372
|
-
return
|
|
9411
|
+
return _context45.abrupt("return", _context45.sent);
|
|
9373
9412
|
|
|
9374
9413
|
case 4:
|
|
9375
9414
|
case "end":
|
|
9376
|
-
return
|
|
9415
|
+
return _context45.stop();
|
|
9377
9416
|
}
|
|
9378
9417
|
}
|
|
9379
|
-
},
|
|
9418
|
+
}, _callee45, this);
|
|
9380
9419
|
}));
|
|
9381
9420
|
|
|
9382
|
-
function unflagUser(
|
|
9421
|
+
function unflagUser(_x60) {
|
|
9383
9422
|
return _unflagUser.apply(this, arguments);
|
|
9384
9423
|
}
|
|
9385
9424
|
|
|
@@ -9396,29 +9435,29 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9396
9435
|
}, {
|
|
9397
9436
|
key: "getCallToken",
|
|
9398
9437
|
value: function () {
|
|
9399
|
-
var _getCallToken = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9438
|
+
var _getCallToken = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee46(callID) {
|
|
9400
9439
|
var options,
|
|
9401
|
-
|
|
9402
|
-
return _regeneratorRuntime.wrap(function
|
|
9440
|
+
_args46 = arguments;
|
|
9441
|
+
return _regeneratorRuntime.wrap(function _callee46$(_context46) {
|
|
9403
9442
|
while (1) {
|
|
9404
|
-
switch (
|
|
9443
|
+
switch (_context46.prev = _context46.next) {
|
|
9405
9444
|
case 0:
|
|
9406
|
-
options =
|
|
9407
|
-
|
|
9445
|
+
options = _args46.length > 1 && _args46[1] !== undefined ? _args46[1] : {};
|
|
9446
|
+
_context46.next = 3;
|
|
9408
9447
|
return this.post(this.baseURL + "/calls/".concat(callID), _objectSpread({}, options));
|
|
9409
9448
|
|
|
9410
9449
|
case 3:
|
|
9411
|
-
return
|
|
9450
|
+
return _context46.abrupt("return", _context46.sent);
|
|
9412
9451
|
|
|
9413
9452
|
case 4:
|
|
9414
9453
|
case "end":
|
|
9415
|
-
return
|
|
9454
|
+
return _context46.stop();
|
|
9416
9455
|
}
|
|
9417
9456
|
}
|
|
9418
|
-
},
|
|
9457
|
+
}, _callee46, this);
|
|
9419
9458
|
}));
|
|
9420
9459
|
|
|
9421
|
-
function getCallToken(
|
|
9460
|
+
function getCallToken(_x61) {
|
|
9422
9461
|
return _getCallToken.apply(this, arguments);
|
|
9423
9462
|
}
|
|
9424
9463
|
|
|
@@ -9441,30 +9480,30 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9441
9480
|
}, {
|
|
9442
9481
|
key: "_queryFlags",
|
|
9443
9482
|
value: function () {
|
|
9444
|
-
var _queryFlags2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9483
|
+
var _queryFlags2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee47() {
|
|
9445
9484
|
var filterConditions,
|
|
9446
9485
|
options,
|
|
9447
|
-
|
|
9448
|
-
return _regeneratorRuntime.wrap(function
|
|
9486
|
+
_args47 = arguments;
|
|
9487
|
+
return _regeneratorRuntime.wrap(function _callee47$(_context47) {
|
|
9449
9488
|
while (1) {
|
|
9450
|
-
switch (
|
|
9489
|
+
switch (_context47.prev = _context47.next) {
|
|
9451
9490
|
case 0:
|
|
9452
|
-
filterConditions =
|
|
9453
|
-
options =
|
|
9454
|
-
|
|
9491
|
+
filterConditions = _args47.length > 0 && _args47[0] !== undefined ? _args47[0] : {};
|
|
9492
|
+
options = _args47.length > 1 && _args47[1] !== undefined ? _args47[1] : {};
|
|
9493
|
+
_context47.next = 4;
|
|
9455
9494
|
return this.post(this.baseURL + '/moderation/flags', _objectSpread({
|
|
9456
9495
|
filter_conditions: filterConditions
|
|
9457
9496
|
}, options));
|
|
9458
9497
|
|
|
9459
9498
|
case 4:
|
|
9460
|
-
return
|
|
9499
|
+
return _context47.abrupt("return", _context47.sent);
|
|
9461
9500
|
|
|
9462
9501
|
case 5:
|
|
9463
9502
|
case "end":
|
|
9464
|
-
return
|
|
9503
|
+
return _context47.stop();
|
|
9465
9504
|
}
|
|
9466
9505
|
}
|
|
9467
|
-
},
|
|
9506
|
+
}, _callee47, this);
|
|
9468
9507
|
}));
|
|
9469
9508
|
|
|
9470
9509
|
function _queryFlags() {
|
|
@@ -9490,30 +9529,30 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9490
9529
|
}, {
|
|
9491
9530
|
key: "_queryFlagReports",
|
|
9492
9531
|
value: function () {
|
|
9493
|
-
var _queryFlagReports2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9532
|
+
var _queryFlagReports2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee48() {
|
|
9494
9533
|
var filterConditions,
|
|
9495
9534
|
options,
|
|
9496
|
-
|
|
9497
|
-
return _regeneratorRuntime.wrap(function
|
|
9535
|
+
_args48 = arguments;
|
|
9536
|
+
return _regeneratorRuntime.wrap(function _callee48$(_context48) {
|
|
9498
9537
|
while (1) {
|
|
9499
|
-
switch (
|
|
9538
|
+
switch (_context48.prev = _context48.next) {
|
|
9500
9539
|
case 0:
|
|
9501
|
-
filterConditions =
|
|
9502
|
-
options =
|
|
9503
|
-
|
|
9540
|
+
filterConditions = _args48.length > 0 && _args48[0] !== undefined ? _args48[0] : {};
|
|
9541
|
+
options = _args48.length > 1 && _args48[1] !== undefined ? _args48[1] : {};
|
|
9542
|
+
_context48.next = 4;
|
|
9504
9543
|
return this.post(this.baseURL + '/moderation/reports', _objectSpread({
|
|
9505
9544
|
filter_conditions: filterConditions
|
|
9506
9545
|
}, options));
|
|
9507
9546
|
|
|
9508
9547
|
case 4:
|
|
9509
|
-
return
|
|
9548
|
+
return _context48.abrupt("return", _context48.sent);
|
|
9510
9549
|
|
|
9511
9550
|
case 5:
|
|
9512
9551
|
case "end":
|
|
9513
|
-
return
|
|
9552
|
+
return _context48.stop();
|
|
9514
9553
|
}
|
|
9515
9554
|
}
|
|
9516
|
-
},
|
|
9555
|
+
}, _callee48, this);
|
|
9517
9556
|
}));
|
|
9518
9557
|
|
|
9519
9558
|
function _queryFlagReports() {
|
|
@@ -9540,90 +9579,78 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9540
9579
|
}, {
|
|
9541
9580
|
key: "_reviewFlagReport",
|
|
9542
9581
|
value: function () {
|
|
9543
|
-
var _reviewFlagReport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9582
|
+
var _reviewFlagReport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee49(id, reviewResult) {
|
|
9544
9583
|
var options,
|
|
9545
|
-
|
|
9546
|
-
return _regeneratorRuntime.wrap(function
|
|
9584
|
+
_args49 = arguments;
|
|
9585
|
+
return _regeneratorRuntime.wrap(function _callee49$(_context49) {
|
|
9547
9586
|
while (1) {
|
|
9548
|
-
switch (
|
|
9587
|
+
switch (_context49.prev = _context49.next) {
|
|
9549
9588
|
case 0:
|
|
9550
|
-
options =
|
|
9551
|
-
|
|
9589
|
+
options = _args49.length > 2 && _args49[2] !== undefined ? _args49[2] : {};
|
|
9590
|
+
_context49.next = 3;
|
|
9552
9591
|
return this.patch(this.baseURL + "/moderation/reports/".concat(id), _objectSpread({
|
|
9553
9592
|
review_result: reviewResult
|
|
9554
9593
|
}, options));
|
|
9555
9594
|
|
|
9556
9595
|
case 3:
|
|
9557
|
-
return
|
|
9596
|
+
return _context49.abrupt("return", _context49.sent);
|
|
9558
9597
|
|
|
9559
9598
|
case 4:
|
|
9560
9599
|
case "end":
|
|
9561
|
-
return
|
|
9600
|
+
return _context49.stop();
|
|
9562
9601
|
}
|
|
9563
9602
|
}
|
|
9564
|
-
},
|
|
9603
|
+
}, _callee49, this);
|
|
9565
9604
|
}));
|
|
9566
9605
|
|
|
9567
|
-
function _reviewFlagReport(
|
|
9606
|
+
function _reviewFlagReport(_x62, _x63) {
|
|
9568
9607
|
return _reviewFlagReport2.apply(this, arguments);
|
|
9569
9608
|
}
|
|
9570
9609
|
|
|
9571
9610
|
return _reviewFlagReport;
|
|
9572
9611
|
}()
|
|
9573
9612
|
/**
|
|
9574
|
-
*
|
|
9613
|
+
* unblockMessage - unblocks message blocked by automod
|
|
9575
9614
|
*
|
|
9576
|
-
* Note: Do not use this.
|
|
9577
|
-
* It is present for internal usage only.
|
|
9578
|
-
* This function can, and will, break and/or be removed at any point in time.
|
|
9579
9615
|
*
|
|
9580
|
-
* @private
|
|
9581
9616
|
* @param {string} targetMessageID
|
|
9582
9617
|
* @param {string} [options.user_id] currentUserID, only used with serverside auth
|
|
9583
9618
|
* @returns {Promise<APIResponse>}
|
|
9584
9619
|
*/
|
|
9585
9620
|
|
|
9586
9621
|
}, {
|
|
9587
|
-
key: "
|
|
9622
|
+
key: "unblockMessage",
|
|
9588
9623
|
value: function () {
|
|
9589
|
-
var
|
|
9624
|
+
var _unblockMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee50(targetMessageID) {
|
|
9590
9625
|
var options,
|
|
9591
|
-
|
|
9592
|
-
return _regeneratorRuntime.wrap(function
|
|
9626
|
+
_args50 = arguments;
|
|
9627
|
+
return _regeneratorRuntime.wrap(function _callee50$(_context50) {
|
|
9593
9628
|
while (1) {
|
|
9594
|
-
switch (
|
|
9629
|
+
switch (_context50.prev = _context50.next) {
|
|
9595
9630
|
case 0:
|
|
9596
|
-
options =
|
|
9597
|
-
|
|
9631
|
+
options = _args50.length > 1 && _args50[1] !== undefined ? _args50[1] : {};
|
|
9632
|
+
_context50.next = 3;
|
|
9598
9633
|
return this.post(this.baseURL + '/moderation/unblock_message', _objectSpread({
|
|
9599
9634
|
target_message_id: targetMessageID
|
|
9600
9635
|
}, options));
|
|
9601
9636
|
|
|
9602
9637
|
case 3:
|
|
9603
|
-
return
|
|
9638
|
+
return _context50.abrupt("return", _context50.sent);
|
|
9604
9639
|
|
|
9605
9640
|
case 4:
|
|
9606
9641
|
case "end":
|
|
9607
|
-
return
|
|
9642
|
+
return _context50.stop();
|
|
9608
9643
|
}
|
|
9609
9644
|
}
|
|
9610
|
-
},
|
|
9645
|
+
}, _callee50, this);
|
|
9611
9646
|
}));
|
|
9612
9647
|
|
|
9613
|
-
function
|
|
9614
|
-
return
|
|
9648
|
+
function unblockMessage(_x64) {
|
|
9649
|
+
return _unblockMessage.apply(this, arguments);
|
|
9615
9650
|
}
|
|
9616
9651
|
|
|
9617
|
-
return
|
|
9618
|
-
}()
|
|
9619
|
-
/**
|
|
9620
|
-
* @deprecated use markChannelsRead instead
|
|
9621
|
-
*
|
|
9622
|
-
* markAllRead - marks all channels for this user as read
|
|
9623
|
-
* @param {MarkAllReadOptions<StreamChatGenerics>} [data]
|
|
9624
|
-
*
|
|
9625
|
-
* @return {Promise<APIResponse>}
|
|
9626
|
-
*/
|
|
9652
|
+
return unblockMessage;
|
|
9653
|
+
}() // alias for backwards compatibility
|
|
9627
9654
|
|
|
9628
9655
|
}, {
|
|
9629
9656
|
key: "markChannelsRead",
|
|
@@ -9637,23 +9664,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9637
9664
|
* @return {Promise<APIResponse>}
|
|
9638
9665
|
*/
|
|
9639
9666
|
function () {
|
|
9640
|
-
var _markChannelsRead = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9667
|
+
var _markChannelsRead = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee51() {
|
|
9641
9668
|
var data,
|
|
9642
|
-
|
|
9643
|
-
return _regeneratorRuntime.wrap(function
|
|
9669
|
+
_args51 = arguments;
|
|
9670
|
+
return _regeneratorRuntime.wrap(function _callee51$(_context51) {
|
|
9644
9671
|
while (1) {
|
|
9645
|
-
switch (
|
|
9672
|
+
switch (_context51.prev = _context51.next) {
|
|
9646
9673
|
case 0:
|
|
9647
|
-
data =
|
|
9648
|
-
|
|
9674
|
+
data = _args51.length > 0 && _args51[0] !== undefined ? _args51[0] : {};
|
|
9675
|
+
_context51.next = 3;
|
|
9649
9676
|
return this.post(this.baseURL + '/channels/read', _objectSpread({}, data));
|
|
9650
9677
|
|
|
9651
9678
|
case 3:
|
|
9652
9679
|
case "end":
|
|
9653
|
-
return
|
|
9680
|
+
return _context51.stop();
|
|
9654
9681
|
}
|
|
9655
9682
|
}
|
|
9656
|
-
},
|
|
9683
|
+
}, _callee51, this);
|
|
9657
9684
|
}));
|
|
9658
9685
|
|
|
9659
9686
|
function markChannelsRead() {
|
|
@@ -9728,28 +9755,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9728
9755
|
}, {
|
|
9729
9756
|
key: "translateMessage",
|
|
9730
9757
|
value: function () {
|
|
9731
|
-
var _translateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9732
|
-
return _regeneratorRuntime.wrap(function
|
|
9758
|
+
var _translateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee52(messageId, language) {
|
|
9759
|
+
return _regeneratorRuntime.wrap(function _callee52$(_context52) {
|
|
9733
9760
|
while (1) {
|
|
9734
|
-
switch (
|
|
9761
|
+
switch (_context52.prev = _context52.next) {
|
|
9735
9762
|
case 0:
|
|
9736
|
-
|
|
9763
|
+
_context52.next = 2;
|
|
9737
9764
|
return this.post(this.baseURL + "/messages/".concat(messageId, "/translate"), {
|
|
9738
9765
|
language: language
|
|
9739
9766
|
});
|
|
9740
9767
|
|
|
9741
9768
|
case 2:
|
|
9742
|
-
return
|
|
9769
|
+
return _context52.abrupt("return", _context52.sent);
|
|
9743
9770
|
|
|
9744
9771
|
case 3:
|
|
9745
9772
|
case "end":
|
|
9746
|
-
return
|
|
9773
|
+
return _context52.stop();
|
|
9747
9774
|
}
|
|
9748
9775
|
}
|
|
9749
|
-
},
|
|
9776
|
+
}, _callee52, this);
|
|
9750
9777
|
}));
|
|
9751
9778
|
|
|
9752
|
-
function translateMessage(
|
|
9779
|
+
function translateMessage(_x65, _x66) {
|
|
9753
9780
|
return _translateMessage.apply(this, arguments);
|
|
9754
9781
|
}
|
|
9755
9782
|
|
|
@@ -9851,14 +9878,14 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9851
9878
|
}, {
|
|
9852
9879
|
key: "updateMessage",
|
|
9853
9880
|
value: function () {
|
|
9854
|
-
var _updateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9881
|
+
var _updateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee53(message, userId, options) {
|
|
9855
9882
|
var clonedMessage, reservedMessageFields;
|
|
9856
|
-
return _regeneratorRuntime.wrap(function
|
|
9883
|
+
return _regeneratorRuntime.wrap(function _callee53$(_context53) {
|
|
9857
9884
|
while (1) {
|
|
9858
|
-
switch (
|
|
9885
|
+
switch (_context53.prev = _context53.next) {
|
|
9859
9886
|
case 0:
|
|
9860
9887
|
if (message.id) {
|
|
9861
|
-
|
|
9888
|
+
_context53.next = 2;
|
|
9862
9889
|
break;
|
|
9863
9890
|
}
|
|
9864
9891
|
|
|
@@ -9895,23 +9922,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9895
9922
|
});
|
|
9896
9923
|
}
|
|
9897
9924
|
|
|
9898
|
-
|
|
9925
|
+
_context53.next = 10;
|
|
9899
9926
|
return this.post(this.baseURL + "/messages/".concat(message.id), _objectSpread({
|
|
9900
9927
|
message: clonedMessage
|
|
9901
9928
|
}, options));
|
|
9902
9929
|
|
|
9903
9930
|
case 10:
|
|
9904
|
-
return
|
|
9931
|
+
return _context53.abrupt("return", _context53.sent);
|
|
9905
9932
|
|
|
9906
9933
|
case 11:
|
|
9907
9934
|
case "end":
|
|
9908
|
-
return
|
|
9935
|
+
return _context53.stop();
|
|
9909
9936
|
}
|
|
9910
9937
|
}
|
|
9911
|
-
},
|
|
9938
|
+
}, _callee53, this);
|
|
9912
9939
|
}));
|
|
9913
9940
|
|
|
9914
|
-
function updateMessage(
|
|
9941
|
+
function updateMessage(_x67, _x68, _x69) {
|
|
9915
9942
|
return _updateMessage.apply(this, arguments);
|
|
9916
9943
|
}
|
|
9917
9944
|
|
|
@@ -9934,14 +9961,14 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9934
9961
|
}, {
|
|
9935
9962
|
key: "partialUpdateMessage",
|
|
9936
9963
|
value: function () {
|
|
9937
|
-
var _partialUpdateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9964
|
+
var _partialUpdateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee54(id, partialMessageObject, userId, options) {
|
|
9938
9965
|
var user;
|
|
9939
|
-
return _regeneratorRuntime.wrap(function
|
|
9966
|
+
return _regeneratorRuntime.wrap(function _callee54$(_context54) {
|
|
9940
9967
|
while (1) {
|
|
9941
|
-
switch (
|
|
9968
|
+
switch (_context54.prev = _context54.next) {
|
|
9942
9969
|
case 0:
|
|
9943
9970
|
if (id) {
|
|
9944
|
-
|
|
9971
|
+
_context54.next = 2;
|
|
9945
9972
|
break;
|
|
9946
9973
|
}
|
|
9947
9974
|
|
|
@@ -9956,23 +9983,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9956
9983
|
};
|
|
9957
9984
|
}
|
|
9958
9985
|
|
|
9959
|
-
|
|
9986
|
+
_context54.next = 6;
|
|
9960
9987
|
return this.put(this.baseURL + "/messages/".concat(id), _objectSpread(_objectSpread(_objectSpread({}, partialMessageObject), options), {}, {
|
|
9961
9988
|
user: user
|
|
9962
9989
|
}));
|
|
9963
9990
|
|
|
9964
9991
|
case 6:
|
|
9965
|
-
return
|
|
9992
|
+
return _context54.abrupt("return", _context54.sent);
|
|
9966
9993
|
|
|
9967
9994
|
case 7:
|
|
9968
9995
|
case "end":
|
|
9969
|
-
return
|
|
9996
|
+
return _context54.stop();
|
|
9970
9997
|
}
|
|
9971
9998
|
}
|
|
9972
|
-
},
|
|
9999
|
+
}, _callee54, this);
|
|
9973
10000
|
}));
|
|
9974
10001
|
|
|
9975
|
-
function partialUpdateMessage(
|
|
10002
|
+
function partialUpdateMessage(_x70, _x71, _x72, _x73) {
|
|
9976
10003
|
return _partialUpdateMessage.apply(this, arguments);
|
|
9977
10004
|
}
|
|
9978
10005
|
|
|
@@ -9981,11 +10008,11 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9981
10008
|
}, {
|
|
9982
10009
|
key: "deleteMessage",
|
|
9983
10010
|
value: function () {
|
|
9984
|
-
var _deleteMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10011
|
+
var _deleteMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee55(messageID, hardDelete) {
|
|
9985
10012
|
var params;
|
|
9986
|
-
return _regeneratorRuntime.wrap(function
|
|
10013
|
+
return _regeneratorRuntime.wrap(function _callee55$(_context55) {
|
|
9987
10014
|
while (1) {
|
|
9988
|
-
switch (
|
|
10015
|
+
switch (_context55.prev = _context55.next) {
|
|
9989
10016
|
case 0:
|
|
9990
10017
|
params = {};
|
|
9991
10018
|
|
|
@@ -9995,21 +10022,21 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9995
10022
|
};
|
|
9996
10023
|
}
|
|
9997
10024
|
|
|
9998
|
-
|
|
10025
|
+
_context55.next = 4;
|
|
9999
10026
|
return this.delete(this.baseURL + "/messages/".concat(messageID), params);
|
|
10000
10027
|
|
|
10001
10028
|
case 4:
|
|
10002
|
-
return
|
|
10029
|
+
return _context55.abrupt("return", _context55.sent);
|
|
10003
10030
|
|
|
10004
10031
|
case 5:
|
|
10005
10032
|
case "end":
|
|
10006
|
-
return
|
|
10033
|
+
return _context55.stop();
|
|
10007
10034
|
}
|
|
10008
10035
|
}
|
|
10009
|
-
},
|
|
10036
|
+
}, _callee55, this);
|
|
10010
10037
|
}));
|
|
10011
10038
|
|
|
10012
|
-
function deleteMessage(
|
|
10039
|
+
function deleteMessage(_x74, _x75) {
|
|
10013
10040
|
return _deleteMessage.apply(this, arguments);
|
|
10014
10041
|
}
|
|
10015
10042
|
|
|
@@ -10018,26 +10045,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10018
10045
|
}, {
|
|
10019
10046
|
key: "getMessage",
|
|
10020
10047
|
value: function () {
|
|
10021
|
-
var _getMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10022
|
-
return _regeneratorRuntime.wrap(function
|
|
10048
|
+
var _getMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee56(messageID) {
|
|
10049
|
+
return _regeneratorRuntime.wrap(function _callee56$(_context56) {
|
|
10023
10050
|
while (1) {
|
|
10024
|
-
switch (
|
|
10051
|
+
switch (_context56.prev = _context56.next) {
|
|
10025
10052
|
case 0:
|
|
10026
|
-
|
|
10053
|
+
_context56.next = 2;
|
|
10027
10054
|
return this.get(this.baseURL + "/messages/".concat(encodeURIComponent(messageID)));
|
|
10028
10055
|
|
|
10029
10056
|
case 2:
|
|
10030
|
-
return
|
|
10057
|
+
return _context56.abrupt("return", _context56.sent);
|
|
10031
10058
|
|
|
10032
10059
|
case 3:
|
|
10033
10060
|
case "end":
|
|
10034
|
-
return
|
|
10061
|
+
return _context56.stop();
|
|
10035
10062
|
}
|
|
10036
10063
|
}
|
|
10037
|
-
},
|
|
10064
|
+
}, _callee56, this);
|
|
10038
10065
|
}));
|
|
10039
10066
|
|
|
10040
|
-
function getMessage(
|
|
10067
|
+
function getMessage(_x76) {
|
|
10041
10068
|
return _getMessage.apply(this, arguments);
|
|
10042
10069
|
}
|
|
10043
10070
|
|
|
@@ -10046,7 +10073,7 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10046
10073
|
}, {
|
|
10047
10074
|
key: "getUserAgent",
|
|
10048
10075
|
value: function getUserAgent() {
|
|
10049
|
-
return this.userAgent || "stream-chat-javascript-client-".concat(this.node ? 'node' : 'browser', "-", "8.
|
|
10076
|
+
return this.userAgent || "stream-chat-javascript-client-".concat(this.node ? 'node' : 'browser', "-", "8.12.1");
|
|
10050
10077
|
}
|
|
10051
10078
|
}, {
|
|
10052
10079
|
key: "setUserAgent",
|
|
@@ -10265,28 +10292,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10265
10292
|
}, {
|
|
10266
10293
|
key: "sendUserCustomEvent",
|
|
10267
10294
|
value: function () {
|
|
10268
|
-
var _sendUserCustomEvent = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10269
|
-
return _regeneratorRuntime.wrap(function
|
|
10295
|
+
var _sendUserCustomEvent = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee57(targetUserID, event) {
|
|
10296
|
+
return _regeneratorRuntime.wrap(function _callee57$(_context57) {
|
|
10270
10297
|
while (1) {
|
|
10271
|
-
switch (
|
|
10298
|
+
switch (_context57.prev = _context57.next) {
|
|
10272
10299
|
case 0:
|
|
10273
|
-
|
|
10300
|
+
_context57.next = 2;
|
|
10274
10301
|
return this.post("".concat(this.baseURL, "/users/").concat(targetUserID, "/event"), {
|
|
10275
10302
|
event: event
|
|
10276
10303
|
});
|
|
10277
10304
|
|
|
10278
10305
|
case 2:
|
|
10279
|
-
return
|
|
10306
|
+
return _context57.abrupt("return", _context57.sent);
|
|
10280
10307
|
|
|
10281
10308
|
case 3:
|
|
10282
10309
|
case "end":
|
|
10283
|
-
return
|
|
10310
|
+
return _context57.stop();
|
|
10284
10311
|
}
|
|
10285
10312
|
}
|
|
10286
|
-
},
|
|
10313
|
+
}, _callee57, this);
|
|
10287
10314
|
}));
|
|
10288
10315
|
|
|
10289
|
-
function sendUserCustomEvent(
|
|
10316
|
+
function sendUserCustomEvent(_x77, _x78) {
|
|
10290
10317
|
return _sendUserCustomEvent.apply(this, arguments);
|
|
10291
10318
|
}
|
|
10292
10319
|
|
|
@@ -10354,32 +10381,32 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10354
10381
|
}, {
|
|
10355
10382
|
key: "createSegment",
|
|
10356
10383
|
value: function () {
|
|
10357
|
-
var _createSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10384
|
+
var _createSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee58(params) {
|
|
10358
10385
|
var _yield$this$post, segment;
|
|
10359
10386
|
|
|
10360
|
-
return _regeneratorRuntime.wrap(function
|
|
10387
|
+
return _regeneratorRuntime.wrap(function _callee58$(_context58) {
|
|
10361
10388
|
while (1) {
|
|
10362
|
-
switch (
|
|
10389
|
+
switch (_context58.prev = _context58.next) {
|
|
10363
10390
|
case 0:
|
|
10364
|
-
|
|
10391
|
+
_context58.next = 2;
|
|
10365
10392
|
return this.post(this.baseURL + "/segments", {
|
|
10366
10393
|
segment: params
|
|
10367
10394
|
});
|
|
10368
10395
|
|
|
10369
10396
|
case 2:
|
|
10370
|
-
_yield$this$post =
|
|
10397
|
+
_yield$this$post = _context58.sent;
|
|
10371
10398
|
segment = _yield$this$post.segment;
|
|
10372
|
-
return
|
|
10399
|
+
return _context58.abrupt("return", segment);
|
|
10373
10400
|
|
|
10374
10401
|
case 5:
|
|
10375
10402
|
case "end":
|
|
10376
|
-
return
|
|
10403
|
+
return _context58.stop();
|
|
10377
10404
|
}
|
|
10378
10405
|
}
|
|
10379
|
-
},
|
|
10406
|
+
}, _callee58, this);
|
|
10380
10407
|
}));
|
|
10381
10408
|
|
|
10382
|
-
function createSegment(
|
|
10409
|
+
function createSegment(_x79) {
|
|
10383
10410
|
return _createSegment.apply(this, arguments);
|
|
10384
10411
|
}
|
|
10385
10412
|
|
|
@@ -10395,15 +10422,15 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10395
10422
|
}, {
|
|
10396
10423
|
key: "querySegments",
|
|
10397
10424
|
value: function () {
|
|
10398
|
-
var _querySegments = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10425
|
+
var _querySegments = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee59(filters) {
|
|
10399
10426
|
var options,
|
|
10400
|
-
|
|
10401
|
-
return _regeneratorRuntime.wrap(function
|
|
10427
|
+
_args59 = arguments;
|
|
10428
|
+
return _regeneratorRuntime.wrap(function _callee59$(_context59) {
|
|
10402
10429
|
while (1) {
|
|
10403
|
-
switch (
|
|
10430
|
+
switch (_context59.prev = _context59.next) {
|
|
10404
10431
|
case 0:
|
|
10405
|
-
options =
|
|
10406
|
-
|
|
10432
|
+
options = _args59.length > 1 && _args59[1] !== undefined ? _args59[1] : {};
|
|
10433
|
+
_context59.next = 3;
|
|
10407
10434
|
return this.get(this.baseURL + "/segments", {
|
|
10408
10435
|
payload: _objectSpread({
|
|
10409
10436
|
filter_conditions: filters
|
|
@@ -10411,17 +10438,17 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10411
10438
|
});
|
|
10412
10439
|
|
|
10413
10440
|
case 3:
|
|
10414
|
-
return
|
|
10441
|
+
return _context59.abrupt("return", _context59.sent);
|
|
10415
10442
|
|
|
10416
10443
|
case 4:
|
|
10417
10444
|
case "end":
|
|
10418
|
-
return
|
|
10445
|
+
return _context59.stop();
|
|
10419
10446
|
}
|
|
10420
10447
|
}
|
|
10421
|
-
},
|
|
10448
|
+
}, _callee59, this);
|
|
10422
10449
|
}));
|
|
10423
10450
|
|
|
10424
|
-
function querySegments(
|
|
10451
|
+
function querySegments(_x80) {
|
|
10425
10452
|
return _querySegments.apply(this, arguments);
|
|
10426
10453
|
}
|
|
10427
10454
|
|
|
@@ -10439,32 +10466,32 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10439
10466
|
}, {
|
|
10440
10467
|
key: "updateSegment",
|
|
10441
10468
|
value: function () {
|
|
10442
|
-
var _updateSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10469
|
+
var _updateSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee60(id, params) {
|
|
10443
10470
|
var _yield$this$put, segment;
|
|
10444
10471
|
|
|
10445
|
-
return _regeneratorRuntime.wrap(function
|
|
10472
|
+
return _regeneratorRuntime.wrap(function _callee60$(_context60) {
|
|
10446
10473
|
while (1) {
|
|
10447
|
-
switch (
|
|
10474
|
+
switch (_context60.prev = _context60.next) {
|
|
10448
10475
|
case 0:
|
|
10449
|
-
|
|
10476
|
+
_context60.next = 2;
|
|
10450
10477
|
return this.put(this.baseURL + "/segments/".concat(id), {
|
|
10451
10478
|
segment: params
|
|
10452
10479
|
});
|
|
10453
10480
|
|
|
10454
10481
|
case 2:
|
|
10455
|
-
_yield$this$put =
|
|
10482
|
+
_yield$this$put = _context60.sent;
|
|
10456
10483
|
segment = _yield$this$put.segment;
|
|
10457
|
-
return
|
|
10484
|
+
return _context60.abrupt("return", segment);
|
|
10458
10485
|
|
|
10459
10486
|
case 5:
|
|
10460
10487
|
case "end":
|
|
10461
|
-
return
|
|
10488
|
+
return _context60.stop();
|
|
10462
10489
|
}
|
|
10463
10490
|
}
|
|
10464
|
-
},
|
|
10491
|
+
}, _callee60, this);
|
|
10465
10492
|
}));
|
|
10466
10493
|
|
|
10467
|
-
function updateSegment(
|
|
10494
|
+
function updateSegment(_x81, _x82) {
|
|
10468
10495
|
return _updateSegment.apply(this, arguments);
|
|
10469
10496
|
}
|
|
10470
10497
|
|
|
@@ -10481,22 +10508,22 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10481
10508
|
}, {
|
|
10482
10509
|
key: "deleteSegment",
|
|
10483
10510
|
value: function () {
|
|
10484
|
-
var _deleteSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10485
|
-
return _regeneratorRuntime.wrap(function
|
|
10511
|
+
var _deleteSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee61(id) {
|
|
10512
|
+
return _regeneratorRuntime.wrap(function _callee61$(_context61) {
|
|
10486
10513
|
while (1) {
|
|
10487
|
-
switch (
|
|
10514
|
+
switch (_context61.prev = _context61.next) {
|
|
10488
10515
|
case 0:
|
|
10489
|
-
return
|
|
10516
|
+
return _context61.abrupt("return", this.delete(this.baseURL + "/segments/".concat(id)));
|
|
10490
10517
|
|
|
10491
10518
|
case 1:
|
|
10492
10519
|
case "end":
|
|
10493
|
-
return
|
|
10520
|
+
return _context61.stop();
|
|
10494
10521
|
}
|
|
10495
10522
|
}
|
|
10496
|
-
},
|
|
10523
|
+
}, _callee61, this);
|
|
10497
10524
|
}));
|
|
10498
10525
|
|
|
10499
|
-
function deleteSegment(
|
|
10526
|
+
function deleteSegment(_x83) {
|
|
10500
10527
|
return _deleteSegment.apply(this, arguments);
|
|
10501
10528
|
}
|
|
10502
10529
|
|
|
@@ -10513,32 +10540,32 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10513
10540
|
}, {
|
|
10514
10541
|
key: "createCampaign",
|
|
10515
10542
|
value: function () {
|
|
10516
|
-
var _createCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10543
|
+
var _createCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee62(params) {
|
|
10517
10544
|
var _yield$this$post2, campaign;
|
|
10518
10545
|
|
|
10519
|
-
return _regeneratorRuntime.wrap(function
|
|
10546
|
+
return _regeneratorRuntime.wrap(function _callee62$(_context62) {
|
|
10520
10547
|
while (1) {
|
|
10521
|
-
switch (
|
|
10548
|
+
switch (_context62.prev = _context62.next) {
|
|
10522
10549
|
case 0:
|
|
10523
|
-
|
|
10550
|
+
_context62.next = 2;
|
|
10524
10551
|
return this.post(this.baseURL + "/campaigns", {
|
|
10525
10552
|
campaign: params
|
|
10526
10553
|
});
|
|
10527
10554
|
|
|
10528
10555
|
case 2:
|
|
10529
|
-
_yield$this$post2 =
|
|
10556
|
+
_yield$this$post2 = _context62.sent;
|
|
10530
10557
|
campaign = _yield$this$post2.campaign;
|
|
10531
|
-
return
|
|
10558
|
+
return _context62.abrupt("return", campaign);
|
|
10532
10559
|
|
|
10533
10560
|
case 5:
|
|
10534
10561
|
case "end":
|
|
10535
|
-
return
|
|
10562
|
+
return _context62.stop();
|
|
10536
10563
|
}
|
|
10537
10564
|
}
|
|
10538
|
-
},
|
|
10565
|
+
}, _callee62, this);
|
|
10539
10566
|
}));
|
|
10540
10567
|
|
|
10541
|
-
function createCampaign(
|
|
10568
|
+
function createCampaign(_x84) {
|
|
10542
10569
|
return _createCampaign.apply(this, arguments);
|
|
10543
10570
|
}
|
|
10544
10571
|
|
|
@@ -10554,15 +10581,15 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10554
10581
|
}, {
|
|
10555
10582
|
key: "queryCampaigns",
|
|
10556
10583
|
value: function () {
|
|
10557
|
-
var _queryCampaigns = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10584
|
+
var _queryCampaigns = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee63(filters) {
|
|
10558
10585
|
var options,
|
|
10559
|
-
|
|
10560
|
-
return _regeneratorRuntime.wrap(function
|
|
10586
|
+
_args63 = arguments;
|
|
10587
|
+
return _regeneratorRuntime.wrap(function _callee63$(_context63) {
|
|
10561
10588
|
while (1) {
|
|
10562
|
-
switch (
|
|
10589
|
+
switch (_context63.prev = _context63.next) {
|
|
10563
10590
|
case 0:
|
|
10564
|
-
options =
|
|
10565
|
-
|
|
10591
|
+
options = _args63.length > 1 && _args63[1] !== undefined ? _args63[1] : {};
|
|
10592
|
+
_context63.next = 3;
|
|
10566
10593
|
return this.get(this.baseURL + "/campaigns", {
|
|
10567
10594
|
payload: _objectSpread({
|
|
10568
10595
|
filter_conditions: filters
|
|
@@ -10570,17 +10597,17 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10570
10597
|
});
|
|
10571
10598
|
|
|
10572
10599
|
case 3:
|
|
10573
|
-
return
|
|
10600
|
+
return _context63.abrupt("return", _context63.sent);
|
|
10574
10601
|
|
|
10575
10602
|
case 4:
|
|
10576
10603
|
case "end":
|
|
10577
|
-
return
|
|
10604
|
+
return _context63.stop();
|
|
10578
10605
|
}
|
|
10579
10606
|
}
|
|
10580
|
-
},
|
|
10607
|
+
}, _callee63, this);
|
|
10581
10608
|
}));
|
|
10582
10609
|
|
|
10583
|
-
function queryCampaigns(
|
|
10610
|
+
function queryCampaigns(_x85) {
|
|
10584
10611
|
return _queryCampaigns.apply(this, arguments);
|
|
10585
10612
|
}
|
|
10586
10613
|
|
|
@@ -10598,32 +10625,32 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10598
10625
|
}, {
|
|
10599
10626
|
key: "updateCampaign",
|
|
10600
10627
|
value: function () {
|
|
10601
|
-
var _updateCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10628
|
+
var _updateCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee64(id, params) {
|
|
10602
10629
|
var _yield$this$put2, campaign;
|
|
10603
10630
|
|
|
10604
|
-
return _regeneratorRuntime.wrap(function
|
|
10631
|
+
return _regeneratorRuntime.wrap(function _callee64$(_context64) {
|
|
10605
10632
|
while (1) {
|
|
10606
|
-
switch (
|
|
10633
|
+
switch (_context64.prev = _context64.next) {
|
|
10607
10634
|
case 0:
|
|
10608
|
-
|
|
10635
|
+
_context64.next = 2;
|
|
10609
10636
|
return this.put(this.baseURL + "/campaigns/".concat(id), {
|
|
10610
10637
|
campaign: params
|
|
10611
10638
|
});
|
|
10612
10639
|
|
|
10613
10640
|
case 2:
|
|
10614
|
-
_yield$this$put2 =
|
|
10641
|
+
_yield$this$put2 = _context64.sent;
|
|
10615
10642
|
campaign = _yield$this$put2.campaign;
|
|
10616
|
-
return
|
|
10643
|
+
return _context64.abrupt("return", campaign);
|
|
10617
10644
|
|
|
10618
10645
|
case 5:
|
|
10619
10646
|
case "end":
|
|
10620
|
-
return
|
|
10647
|
+
return _context64.stop();
|
|
10621
10648
|
}
|
|
10622
10649
|
}
|
|
10623
|
-
},
|
|
10650
|
+
}, _callee64, this);
|
|
10624
10651
|
}));
|
|
10625
10652
|
|
|
10626
|
-
function updateCampaign(
|
|
10653
|
+
function updateCampaign(_x86, _x87) {
|
|
10627
10654
|
return _updateCampaign.apply(this, arguments);
|
|
10628
10655
|
}
|
|
10629
10656
|
|
|
@@ -10640,25 +10667,25 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10640
10667
|
}, {
|
|
10641
10668
|
key: "deleteCampaign",
|
|
10642
10669
|
value: function () {
|
|
10643
|
-
var _deleteCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10670
|
+
var _deleteCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee65(id) {
|
|
10644
10671
|
var params,
|
|
10645
|
-
|
|
10646
|
-
return _regeneratorRuntime.wrap(function
|
|
10672
|
+
_args65 = arguments;
|
|
10673
|
+
return _regeneratorRuntime.wrap(function _callee65$(_context65) {
|
|
10647
10674
|
while (1) {
|
|
10648
|
-
switch (
|
|
10675
|
+
switch (_context65.prev = _context65.next) {
|
|
10649
10676
|
case 0:
|
|
10650
|
-
params =
|
|
10651
|
-
return
|
|
10677
|
+
params = _args65.length > 1 && _args65[1] !== undefined ? _args65[1] : {};
|
|
10678
|
+
return _context65.abrupt("return", this.delete(this.baseURL + "/campaigns/".concat(id), params));
|
|
10652
10679
|
|
|
10653
10680
|
case 2:
|
|
10654
10681
|
case "end":
|
|
10655
|
-
return
|
|
10682
|
+
return _context65.stop();
|
|
10656
10683
|
}
|
|
10657
10684
|
}
|
|
10658
|
-
},
|
|
10685
|
+
}, _callee65, this);
|
|
10659
10686
|
}));
|
|
10660
10687
|
|
|
10661
|
-
function deleteCampaign(
|
|
10688
|
+
function deleteCampaign(_x88) {
|
|
10662
10689
|
return _deleteCampaign.apply(this, arguments);
|
|
10663
10690
|
}
|
|
10664
10691
|
|
|
@@ -10676,33 +10703,33 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10676
10703
|
}, {
|
|
10677
10704
|
key: "scheduleCampaign",
|
|
10678
10705
|
value: function () {
|
|
10679
|
-
var _scheduleCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10706
|
+
var _scheduleCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee66(id, params) {
|
|
10680
10707
|
var scheduledFor, _yield$this$patch, campaign;
|
|
10681
10708
|
|
|
10682
|
-
return _regeneratorRuntime.wrap(function
|
|
10709
|
+
return _regeneratorRuntime.wrap(function _callee66$(_context66) {
|
|
10683
10710
|
while (1) {
|
|
10684
|
-
switch (
|
|
10711
|
+
switch (_context66.prev = _context66.next) {
|
|
10685
10712
|
case 0:
|
|
10686
10713
|
scheduledFor = params.scheduledFor;
|
|
10687
|
-
|
|
10714
|
+
_context66.next = 3;
|
|
10688
10715
|
return this.patch(this.baseURL + "/campaigns/".concat(id, "/schedule"), {
|
|
10689
10716
|
scheduled_for: scheduledFor
|
|
10690
10717
|
});
|
|
10691
10718
|
|
|
10692
10719
|
case 3:
|
|
10693
|
-
_yield$this$patch =
|
|
10720
|
+
_yield$this$patch = _context66.sent;
|
|
10694
10721
|
campaign = _yield$this$patch.campaign;
|
|
10695
|
-
return
|
|
10722
|
+
return _context66.abrupt("return", campaign);
|
|
10696
10723
|
|
|
10697
10724
|
case 6:
|
|
10698
10725
|
case "end":
|
|
10699
|
-
return
|
|
10726
|
+
return _context66.stop();
|
|
10700
10727
|
}
|
|
10701
10728
|
}
|
|
10702
|
-
},
|
|
10729
|
+
}, _callee66, this);
|
|
10703
10730
|
}));
|
|
10704
10731
|
|
|
10705
|
-
function scheduleCampaign(
|
|
10732
|
+
function scheduleCampaign(_x89, _x90) {
|
|
10706
10733
|
return _scheduleCampaign.apply(this, arguments);
|
|
10707
10734
|
}
|
|
10708
10735
|
|
|
@@ -10719,30 +10746,30 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10719
10746
|
}, {
|
|
10720
10747
|
key: "stopCampaign",
|
|
10721
10748
|
value: function () {
|
|
10722
|
-
var _stopCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10749
|
+
var _stopCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee67(id) {
|
|
10723
10750
|
var _yield$this$patch2, campaign;
|
|
10724
10751
|
|
|
10725
|
-
return _regeneratorRuntime.wrap(function
|
|
10752
|
+
return _regeneratorRuntime.wrap(function _callee67$(_context67) {
|
|
10726
10753
|
while (1) {
|
|
10727
|
-
switch (
|
|
10754
|
+
switch (_context67.prev = _context67.next) {
|
|
10728
10755
|
case 0:
|
|
10729
|
-
|
|
10756
|
+
_context67.next = 2;
|
|
10730
10757
|
return this.patch(this.baseURL + "/campaigns/".concat(id, "/stop"));
|
|
10731
10758
|
|
|
10732
10759
|
case 2:
|
|
10733
|
-
_yield$this$patch2 =
|
|
10760
|
+
_yield$this$patch2 = _context67.sent;
|
|
10734
10761
|
campaign = _yield$this$patch2.campaign;
|
|
10735
|
-
return
|
|
10762
|
+
return _context67.abrupt("return", campaign);
|
|
10736
10763
|
|
|
10737
10764
|
case 5:
|
|
10738
10765
|
case "end":
|
|
10739
|
-
return
|
|
10766
|
+
return _context67.stop();
|
|
10740
10767
|
}
|
|
10741
10768
|
}
|
|
10742
|
-
},
|
|
10769
|
+
}, _callee67, this);
|
|
10743
10770
|
}));
|
|
10744
10771
|
|
|
10745
|
-
function stopCampaign(
|
|
10772
|
+
function stopCampaign(_x91) {
|
|
10746
10773
|
return _stopCampaign.apply(this, arguments);
|
|
10747
10774
|
}
|
|
10748
10775
|
|
|
@@ -10759,30 +10786,30 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10759
10786
|
}, {
|
|
10760
10787
|
key: "resumeCampaign",
|
|
10761
10788
|
value: function () {
|
|
10762
|
-
var _resumeCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10789
|
+
var _resumeCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee68(id) {
|
|
10763
10790
|
var _yield$this$patch3, campaign;
|
|
10764
10791
|
|
|
10765
|
-
return _regeneratorRuntime.wrap(function
|
|
10792
|
+
return _regeneratorRuntime.wrap(function _callee68$(_context68) {
|
|
10766
10793
|
while (1) {
|
|
10767
|
-
switch (
|
|
10794
|
+
switch (_context68.prev = _context68.next) {
|
|
10768
10795
|
case 0:
|
|
10769
|
-
|
|
10796
|
+
_context68.next = 2;
|
|
10770
10797
|
return this.patch(this.baseURL + "/campaigns/".concat(id, "/resume"));
|
|
10771
10798
|
|
|
10772
10799
|
case 2:
|
|
10773
|
-
_yield$this$patch3 =
|
|
10800
|
+
_yield$this$patch3 = _context68.sent;
|
|
10774
10801
|
campaign = _yield$this$patch3.campaign;
|
|
10775
|
-
return
|
|
10802
|
+
return _context68.abrupt("return", campaign);
|
|
10776
10803
|
|
|
10777
10804
|
case 5:
|
|
10778
10805
|
case "end":
|
|
10779
|
-
return
|
|
10806
|
+
return _context68.stop();
|
|
10780
10807
|
}
|
|
10781
10808
|
}
|
|
10782
|
-
},
|
|
10809
|
+
}, _callee68, this);
|
|
10783
10810
|
}));
|
|
10784
10811
|
|
|
10785
|
-
function resumeCampaign(
|
|
10812
|
+
function resumeCampaign(_x92) {
|
|
10786
10813
|
return _resumeCampaign.apply(this, arguments);
|
|
10787
10814
|
}
|
|
10788
10815
|
|
|
@@ -10800,30 +10827,30 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10800
10827
|
}, {
|
|
10801
10828
|
key: "testCampaign",
|
|
10802
10829
|
value: function () {
|
|
10803
|
-
var _testCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10830
|
+
var _testCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee69(id, params) {
|
|
10804
10831
|
var users;
|
|
10805
|
-
return _regeneratorRuntime.wrap(function
|
|
10832
|
+
return _regeneratorRuntime.wrap(function _callee69$(_context69) {
|
|
10806
10833
|
while (1) {
|
|
10807
|
-
switch (
|
|
10834
|
+
switch (_context69.prev = _context69.next) {
|
|
10808
10835
|
case 0:
|
|
10809
10836
|
users = params.users;
|
|
10810
|
-
|
|
10837
|
+
_context69.next = 3;
|
|
10811
10838
|
return this.post(this.baseURL + "/campaigns/".concat(id, "/test"), {
|
|
10812
10839
|
users: users
|
|
10813
10840
|
});
|
|
10814
10841
|
|
|
10815
10842
|
case 3:
|
|
10816
|
-
return
|
|
10843
|
+
return _context69.abrupt("return", _context69.sent);
|
|
10817
10844
|
|
|
10818
10845
|
case 4:
|
|
10819
10846
|
case "end":
|
|
10820
|
-
return
|
|
10847
|
+
return _context69.stop();
|
|
10821
10848
|
}
|
|
10822
10849
|
}
|
|
10823
|
-
},
|
|
10850
|
+
}, _callee69, this);
|
|
10824
10851
|
}));
|
|
10825
10852
|
|
|
10826
|
-
function testCampaign(
|
|
10853
|
+
function testCampaign(_x93, _x94) {
|
|
10827
10854
|
return _testCampaign.apply(this, arguments);
|
|
10828
10855
|
}
|
|
10829
10856
|
|
|
@@ -10839,15 +10866,15 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10839
10866
|
}, {
|
|
10840
10867
|
key: "queryRecipients",
|
|
10841
10868
|
value: function () {
|
|
10842
|
-
var _queryRecipients = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10869
|
+
var _queryRecipients = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee70(filters) {
|
|
10843
10870
|
var options,
|
|
10844
|
-
|
|
10845
|
-
return _regeneratorRuntime.wrap(function
|
|
10871
|
+
_args70 = arguments;
|
|
10872
|
+
return _regeneratorRuntime.wrap(function _callee70$(_context70) {
|
|
10846
10873
|
while (1) {
|
|
10847
|
-
switch (
|
|
10874
|
+
switch (_context70.prev = _context70.next) {
|
|
10848
10875
|
case 0:
|
|
10849
|
-
options =
|
|
10850
|
-
|
|
10876
|
+
options = _args70.length > 1 && _args70[1] !== undefined ? _args70[1] : {};
|
|
10877
|
+
_context70.next = 3;
|
|
10851
10878
|
return this.get(this.baseURL + "/recipients", {
|
|
10852
10879
|
payload: _objectSpread({
|
|
10853
10880
|
filter_conditions: filters
|
|
@@ -10855,17 +10882,17 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10855
10882
|
});
|
|
10856
10883
|
|
|
10857
10884
|
case 3:
|
|
10858
|
-
return
|
|
10885
|
+
return _context70.abrupt("return", _context70.sent);
|
|
10859
10886
|
|
|
10860
10887
|
case 4:
|
|
10861
10888
|
case "end":
|
|
10862
|
-
return
|
|
10889
|
+
return _context70.stop();
|
|
10863
10890
|
}
|
|
10864
10891
|
}
|
|
10865
|
-
},
|
|
10892
|
+
}, _callee70, this);
|
|
10866
10893
|
}));
|
|
10867
10894
|
|
|
10868
|
-
function queryRecipients(
|
|
10895
|
+
function queryRecipients(_x95) {
|
|
10869
10896
|
return _queryRecipients.apply(this, arguments);
|
|
10870
10897
|
}
|
|
10871
10898
|
|
|
@@ -10881,24 +10908,24 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10881
10908
|
}, {
|
|
10882
10909
|
key: "enrichURL",
|
|
10883
10910
|
value: function () {
|
|
10884
|
-
var _enrichURL = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10885
|
-
return _regeneratorRuntime.wrap(function
|
|
10911
|
+
var _enrichURL = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee71(url) {
|
|
10912
|
+
return _regeneratorRuntime.wrap(function _callee71$(_context71) {
|
|
10886
10913
|
while (1) {
|
|
10887
|
-
switch (
|
|
10914
|
+
switch (_context71.prev = _context71.next) {
|
|
10888
10915
|
case 0:
|
|
10889
|
-
return
|
|
10916
|
+
return _context71.abrupt("return", this.get(this.baseURL + "/og", {
|
|
10890
10917
|
url: url
|
|
10891
10918
|
}));
|
|
10892
10919
|
|
|
10893
10920
|
case 1:
|
|
10894
10921
|
case "end":
|
|
10895
|
-
return
|
|
10922
|
+
return _context71.stop();
|
|
10896
10923
|
}
|
|
10897
10924
|
}
|
|
10898
|
-
},
|
|
10925
|
+
}, _callee71, this);
|
|
10899
10926
|
}));
|
|
10900
10927
|
|
|
10901
|
-
function enrichURL(
|
|
10928
|
+
function enrichURL(_x96) {
|
|
10902
10929
|
return _enrichURL.apply(this, arguments);
|
|
10903
10930
|
}
|
|
10904
10931
|
|
|
@@ -10915,22 +10942,22 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10915
10942
|
}, {
|
|
10916
10943
|
key: "getTask",
|
|
10917
10944
|
value: function () {
|
|
10918
|
-
var _getTask = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10919
|
-
return _regeneratorRuntime.wrap(function
|
|
10945
|
+
var _getTask = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee72(id) {
|
|
10946
|
+
return _regeneratorRuntime.wrap(function _callee72$(_context72) {
|
|
10920
10947
|
while (1) {
|
|
10921
|
-
switch (
|
|
10948
|
+
switch (_context72.prev = _context72.next) {
|
|
10922
10949
|
case 0:
|
|
10923
|
-
return
|
|
10950
|
+
return _context72.abrupt("return", this.get("".concat(this.baseURL, "/tasks/").concat(id)));
|
|
10924
10951
|
|
|
10925
10952
|
case 1:
|
|
10926
10953
|
case "end":
|
|
10927
|
-
return
|
|
10954
|
+
return _context72.stop();
|
|
10928
10955
|
}
|
|
10929
10956
|
}
|
|
10930
|
-
},
|
|
10957
|
+
}, _callee72, this);
|
|
10931
10958
|
}));
|
|
10932
10959
|
|
|
10933
|
-
function getTask(
|
|
10960
|
+
function getTask(_x97) {
|
|
10934
10961
|
return _getTask.apply(this, arguments);
|
|
10935
10962
|
}
|
|
10936
10963
|
|
|
@@ -10948,31 +10975,31 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10948
10975
|
}, {
|
|
10949
10976
|
key: "deleteChannels",
|
|
10950
10977
|
value: function () {
|
|
10951
|
-
var _deleteChannels = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10978
|
+
var _deleteChannels = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee73(cids) {
|
|
10952
10979
|
var options,
|
|
10953
|
-
|
|
10954
|
-
return _regeneratorRuntime.wrap(function
|
|
10980
|
+
_args73 = arguments;
|
|
10981
|
+
return _regeneratorRuntime.wrap(function _callee73$(_context73) {
|
|
10955
10982
|
while (1) {
|
|
10956
|
-
switch (
|
|
10983
|
+
switch (_context73.prev = _context73.next) {
|
|
10957
10984
|
case 0:
|
|
10958
|
-
options =
|
|
10959
|
-
|
|
10985
|
+
options = _args73.length > 1 && _args73[1] !== undefined ? _args73[1] : {};
|
|
10986
|
+
_context73.next = 3;
|
|
10960
10987
|
return this.post(this.baseURL + "/channels/delete", _objectSpread({
|
|
10961
10988
|
cids: cids
|
|
10962
10989
|
}, options));
|
|
10963
10990
|
|
|
10964
10991
|
case 3:
|
|
10965
|
-
return
|
|
10992
|
+
return _context73.abrupt("return", _context73.sent);
|
|
10966
10993
|
|
|
10967
10994
|
case 4:
|
|
10968
10995
|
case "end":
|
|
10969
|
-
return
|
|
10996
|
+
return _context73.stop();
|
|
10970
10997
|
}
|
|
10971
10998
|
}
|
|
10972
|
-
},
|
|
10999
|
+
}, _callee73, this);
|
|
10973
11000
|
}));
|
|
10974
11001
|
|
|
10975
|
-
function deleteChannels(
|
|
11002
|
+
function deleteChannels(_x98) {
|
|
10976
11003
|
return _deleteChannels.apply(this, arguments);
|
|
10977
11004
|
}
|
|
10978
11005
|
|
|
@@ -10990,13 +11017,13 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10990
11017
|
}, {
|
|
10991
11018
|
key: "deleteUsers",
|
|
10992
11019
|
value: function () {
|
|
10993
|
-
var _deleteUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10994
|
-
return _regeneratorRuntime.wrap(function
|
|
11020
|
+
var _deleteUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee74(user_ids, options) {
|
|
11021
|
+
return _regeneratorRuntime.wrap(function _callee74$(_context74) {
|
|
10995
11022
|
while (1) {
|
|
10996
|
-
switch (
|
|
11023
|
+
switch (_context74.prev = _context74.next) {
|
|
10997
11024
|
case 0:
|
|
10998
11025
|
if (!((options === null || options === void 0 ? void 0 : options.user) !== 'soft' && (options === null || options === void 0 ? void 0 : options.user) !== 'hard')) {
|
|
10999
|
-
|
|
11026
|
+
_context74.next = 2;
|
|
11000
11027
|
break;
|
|
11001
11028
|
}
|
|
11002
11029
|
|
|
@@ -11004,7 +11031,7 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11004
11031
|
|
|
11005
11032
|
case 2:
|
|
11006
11033
|
if (!(options.messages !== undefined && options.messages !== 'soft' && options.messages !== 'hard')) {
|
|
11007
|
-
|
|
11034
|
+
_context74.next = 4;
|
|
11008
11035
|
break;
|
|
11009
11036
|
}
|
|
11010
11037
|
|
|
@@ -11012,30 +11039,30 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11012
11039
|
|
|
11013
11040
|
case 4:
|
|
11014
11041
|
if (!(options.conversations !== undefined && options.conversations !== 'soft' && options.conversations !== 'hard')) {
|
|
11015
|
-
|
|
11042
|
+
_context74.next = 6;
|
|
11016
11043
|
break;
|
|
11017
11044
|
}
|
|
11018
11045
|
|
|
11019
11046
|
throw new Error('Invalid delete user options. conversations must be one of [soft hard]');
|
|
11020
11047
|
|
|
11021
11048
|
case 6:
|
|
11022
|
-
|
|
11049
|
+
_context74.next = 8;
|
|
11023
11050
|
return this.post(this.baseURL + "/users/delete", _objectSpread({
|
|
11024
11051
|
user_ids: user_ids
|
|
11025
11052
|
}, options));
|
|
11026
11053
|
|
|
11027
11054
|
case 8:
|
|
11028
|
-
return
|
|
11055
|
+
return _context74.abrupt("return", _context74.sent);
|
|
11029
11056
|
|
|
11030
11057
|
case 9:
|
|
11031
11058
|
case "end":
|
|
11032
|
-
return
|
|
11059
|
+
return _context74.stop();
|
|
11033
11060
|
}
|
|
11034
11061
|
}
|
|
11035
|
-
},
|
|
11062
|
+
}, _callee74, this);
|
|
11036
11063
|
}));
|
|
11037
11064
|
|
|
11038
|
-
function deleteUsers(
|
|
11065
|
+
function deleteUsers(_x99, _x100) {
|
|
11039
11066
|
return _deleteUsers.apply(this, arguments);
|
|
11040
11067
|
}
|
|
11041
11068
|
|
|
@@ -11056,28 +11083,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11056
11083
|
}, {
|
|
11057
11084
|
key: "_createImportURL",
|
|
11058
11085
|
value: function () {
|
|
11059
|
-
var _createImportURL2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11060
|
-
return _regeneratorRuntime.wrap(function
|
|
11086
|
+
var _createImportURL2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee75(filename) {
|
|
11087
|
+
return _regeneratorRuntime.wrap(function _callee75$(_context75) {
|
|
11061
11088
|
while (1) {
|
|
11062
|
-
switch (
|
|
11089
|
+
switch (_context75.prev = _context75.next) {
|
|
11063
11090
|
case 0:
|
|
11064
|
-
|
|
11091
|
+
_context75.next = 2;
|
|
11065
11092
|
return this.post(this.baseURL + "/import_urls", {
|
|
11066
11093
|
filename: filename
|
|
11067
11094
|
});
|
|
11068
11095
|
|
|
11069
11096
|
case 2:
|
|
11070
|
-
return
|
|
11097
|
+
return _context75.abrupt("return", _context75.sent);
|
|
11071
11098
|
|
|
11072
11099
|
case 3:
|
|
11073
11100
|
case "end":
|
|
11074
|
-
return
|
|
11101
|
+
return _context75.stop();
|
|
11075
11102
|
}
|
|
11076
11103
|
}
|
|
11077
|
-
},
|
|
11104
|
+
}, _callee75, this);
|
|
11078
11105
|
}));
|
|
11079
11106
|
|
|
11080
|
-
function _createImportURL(
|
|
11107
|
+
function _createImportURL(_x101) {
|
|
11081
11108
|
return _createImportURL2.apply(this, arguments);
|
|
11082
11109
|
}
|
|
11083
11110
|
|
|
@@ -11099,33 +11126,33 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11099
11126
|
}, {
|
|
11100
11127
|
key: "_createImport",
|
|
11101
11128
|
value: function () {
|
|
11102
|
-
var _createImport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11129
|
+
var _createImport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee76(path) {
|
|
11103
11130
|
var options,
|
|
11104
|
-
|
|
11105
|
-
return _regeneratorRuntime.wrap(function
|
|
11131
|
+
_args76 = arguments;
|
|
11132
|
+
return _regeneratorRuntime.wrap(function _callee76$(_context76) {
|
|
11106
11133
|
while (1) {
|
|
11107
|
-
switch (
|
|
11134
|
+
switch (_context76.prev = _context76.next) {
|
|
11108
11135
|
case 0:
|
|
11109
|
-
options =
|
|
11136
|
+
options = _args76.length > 1 && _args76[1] !== undefined ? _args76[1] : {
|
|
11110
11137
|
mode: 'upsert'
|
|
11111
11138
|
};
|
|
11112
|
-
|
|
11139
|
+
_context76.next = 3;
|
|
11113
11140
|
return this.post(this.baseURL + "/imports", _objectSpread({
|
|
11114
11141
|
path: path
|
|
11115
11142
|
}, options));
|
|
11116
11143
|
|
|
11117
11144
|
case 3:
|
|
11118
|
-
return
|
|
11145
|
+
return _context76.abrupt("return", _context76.sent);
|
|
11119
11146
|
|
|
11120
11147
|
case 4:
|
|
11121
11148
|
case "end":
|
|
11122
|
-
return
|
|
11149
|
+
return _context76.stop();
|
|
11123
11150
|
}
|
|
11124
11151
|
}
|
|
11125
|
-
},
|
|
11152
|
+
}, _callee76, this);
|
|
11126
11153
|
}));
|
|
11127
11154
|
|
|
11128
|
-
function _createImport(
|
|
11155
|
+
function _createImport(_x102) {
|
|
11129
11156
|
return _createImport2.apply(this, arguments);
|
|
11130
11157
|
}
|
|
11131
11158
|
|
|
@@ -11147,26 +11174,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11147
11174
|
}, {
|
|
11148
11175
|
key: "_getImport",
|
|
11149
11176
|
value: function () {
|
|
11150
|
-
var _getImport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11151
|
-
return _regeneratorRuntime.wrap(function
|
|
11177
|
+
var _getImport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee77(id) {
|
|
11178
|
+
return _regeneratorRuntime.wrap(function _callee77$(_context77) {
|
|
11152
11179
|
while (1) {
|
|
11153
|
-
switch (
|
|
11180
|
+
switch (_context77.prev = _context77.next) {
|
|
11154
11181
|
case 0:
|
|
11155
|
-
|
|
11182
|
+
_context77.next = 2;
|
|
11156
11183
|
return this.get(this.baseURL + "/imports/".concat(id));
|
|
11157
11184
|
|
|
11158
11185
|
case 2:
|
|
11159
|
-
return
|
|
11186
|
+
return _context77.abrupt("return", _context77.sent);
|
|
11160
11187
|
|
|
11161
11188
|
case 3:
|
|
11162
11189
|
case "end":
|
|
11163
|
-
return
|
|
11190
|
+
return _context77.stop();
|
|
11164
11191
|
}
|
|
11165
11192
|
}
|
|
11166
|
-
},
|
|
11193
|
+
}, _callee77, this);
|
|
11167
11194
|
}));
|
|
11168
11195
|
|
|
11169
|
-
function _getImport(
|
|
11196
|
+
function _getImport(_x103) {
|
|
11170
11197
|
return _getImport2.apply(this, arguments);
|
|
11171
11198
|
}
|
|
11172
11199
|
|
|
@@ -11188,26 +11215,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11188
11215
|
}, {
|
|
11189
11216
|
key: "_listImports",
|
|
11190
11217
|
value: function () {
|
|
11191
|
-
var _listImports2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11192
|
-
return _regeneratorRuntime.wrap(function
|
|
11218
|
+
var _listImports2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee78(options) {
|
|
11219
|
+
return _regeneratorRuntime.wrap(function _callee78$(_context78) {
|
|
11193
11220
|
while (1) {
|
|
11194
|
-
switch (
|
|
11221
|
+
switch (_context78.prev = _context78.next) {
|
|
11195
11222
|
case 0:
|
|
11196
|
-
|
|
11223
|
+
_context78.next = 2;
|
|
11197
11224
|
return this.get(this.baseURL + "/imports", options);
|
|
11198
11225
|
|
|
11199
11226
|
case 2:
|
|
11200
|
-
return
|
|
11227
|
+
return _context78.abrupt("return", _context78.sent);
|
|
11201
11228
|
|
|
11202
11229
|
case 3:
|
|
11203
11230
|
case "end":
|
|
11204
|
-
return
|
|
11231
|
+
return _context78.stop();
|
|
11205
11232
|
}
|
|
11206
11233
|
}
|
|
11207
|
-
},
|
|
11234
|
+
}, _callee78, this);
|
|
11208
11235
|
}));
|
|
11209
11236
|
|
|
11210
|
-
function _listImports(
|
|
11237
|
+
function _listImports(_x104) {
|
|
11211
11238
|
return _listImports2.apply(this, arguments);
|
|
11212
11239
|
}
|
|
11213
11240
|
|
|
@@ -11226,28 +11253,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11226
11253
|
}, {
|
|
11227
11254
|
key: "upsertPushProvider",
|
|
11228
11255
|
value: function () {
|
|
11229
|
-
var _upsertPushProvider = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11230
|
-
return _regeneratorRuntime.wrap(function
|
|
11256
|
+
var _upsertPushProvider = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee79(pushProvider) {
|
|
11257
|
+
return _regeneratorRuntime.wrap(function _callee79$(_context79) {
|
|
11231
11258
|
while (1) {
|
|
11232
|
-
switch (
|
|
11259
|
+
switch (_context79.prev = _context79.next) {
|
|
11233
11260
|
case 0:
|
|
11234
|
-
|
|
11261
|
+
_context79.next = 2;
|
|
11235
11262
|
return this.post(this.baseURL + "/push_providers", {
|
|
11236
11263
|
push_provider: pushProvider
|
|
11237
11264
|
});
|
|
11238
11265
|
|
|
11239
11266
|
case 2:
|
|
11240
|
-
return
|
|
11267
|
+
return _context79.abrupt("return", _context79.sent);
|
|
11241
11268
|
|
|
11242
11269
|
case 3:
|
|
11243
11270
|
case "end":
|
|
11244
|
-
return
|
|
11271
|
+
return _context79.stop();
|
|
11245
11272
|
}
|
|
11246
11273
|
}
|
|
11247
|
-
},
|
|
11274
|
+
}, _callee79, this);
|
|
11248
11275
|
}));
|
|
11249
11276
|
|
|
11250
|
-
function upsertPushProvider(
|
|
11277
|
+
function upsertPushProvider(_x105) {
|
|
11251
11278
|
return _upsertPushProvider.apply(this, arguments);
|
|
11252
11279
|
}
|
|
11253
11280
|
|
|
@@ -11266,28 +11293,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11266
11293
|
}, {
|
|
11267
11294
|
key: "deletePushProvider",
|
|
11268
11295
|
value: function () {
|
|
11269
|
-
var _deletePushProvider = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11296
|
+
var _deletePushProvider = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee80(_ref10) {
|
|
11270
11297
|
var type, name;
|
|
11271
|
-
return _regeneratorRuntime.wrap(function
|
|
11298
|
+
return _regeneratorRuntime.wrap(function _callee80$(_context80) {
|
|
11272
11299
|
while (1) {
|
|
11273
|
-
switch (
|
|
11300
|
+
switch (_context80.prev = _context80.next) {
|
|
11274
11301
|
case 0:
|
|
11275
11302
|
type = _ref10.type, name = _ref10.name;
|
|
11276
|
-
|
|
11303
|
+
_context80.next = 3;
|
|
11277
11304
|
return this.delete(this.baseURL + "/push_providers/".concat(type, "/").concat(name));
|
|
11278
11305
|
|
|
11279
11306
|
case 3:
|
|
11280
|
-
return
|
|
11307
|
+
return _context80.abrupt("return", _context80.sent);
|
|
11281
11308
|
|
|
11282
11309
|
case 4:
|
|
11283
11310
|
case "end":
|
|
11284
|
-
return
|
|
11311
|
+
return _context80.stop();
|
|
11285
11312
|
}
|
|
11286
11313
|
}
|
|
11287
|
-
},
|
|
11314
|
+
}, _callee80, this);
|
|
11288
11315
|
}));
|
|
11289
11316
|
|
|
11290
|
-
function deletePushProvider(
|
|
11317
|
+
function deletePushProvider(_x106) {
|
|
11291
11318
|
return _deletePushProvider.apply(this, arguments);
|
|
11292
11319
|
}
|
|
11293
11320
|
|
|
@@ -11304,23 +11331,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11304
11331
|
}, {
|
|
11305
11332
|
key: "listPushProviders",
|
|
11306
11333
|
value: function () {
|
|
11307
|
-
var _listPushProviders = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11308
|
-
return _regeneratorRuntime.wrap(function
|
|
11334
|
+
var _listPushProviders = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee81() {
|
|
11335
|
+
return _regeneratorRuntime.wrap(function _callee81$(_context81) {
|
|
11309
11336
|
while (1) {
|
|
11310
|
-
switch (
|
|
11337
|
+
switch (_context81.prev = _context81.next) {
|
|
11311
11338
|
case 0:
|
|
11312
|
-
|
|
11339
|
+
_context81.next = 2;
|
|
11313
11340
|
return this.get(this.baseURL + "/push_providers");
|
|
11314
11341
|
|
|
11315
11342
|
case 2:
|
|
11316
|
-
return
|
|
11343
|
+
return _context81.abrupt("return", _context81.sent);
|
|
11317
11344
|
|
|
11318
11345
|
case 3:
|
|
11319
11346
|
case "end":
|
|
11320
|
-
return
|
|
11347
|
+
return _context81.stop();
|
|
11321
11348
|
}
|
|
11322
11349
|
}
|
|
11323
|
-
},
|
|
11350
|
+
}, _callee81, this);
|
|
11324
11351
|
}));
|
|
11325
11352
|
|
|
11326
11353
|
function listPushProviders() {
|
|
@@ -11348,26 +11375,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11348
11375
|
}, {
|
|
11349
11376
|
key: "commitMessage",
|
|
11350
11377
|
value: function () {
|
|
11351
|
-
var _commitMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11352
|
-
return _regeneratorRuntime.wrap(function
|
|
11378
|
+
var _commitMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee82(id) {
|
|
11379
|
+
return _regeneratorRuntime.wrap(function _callee82$(_context82) {
|
|
11353
11380
|
while (1) {
|
|
11354
|
-
switch (
|
|
11381
|
+
switch (_context82.prev = _context82.next) {
|
|
11355
11382
|
case 0:
|
|
11356
|
-
|
|
11383
|
+
_context82.next = 2;
|
|
11357
11384
|
return this.post(this.baseURL + "/messages/".concat(id, "/commit"));
|
|
11358
11385
|
|
|
11359
11386
|
case 2:
|
|
11360
|
-
return
|
|
11387
|
+
return _context82.abrupt("return", _context82.sent);
|
|
11361
11388
|
|
|
11362
11389
|
case 3:
|
|
11363
11390
|
case "end":
|
|
11364
|
-
return
|
|
11391
|
+
return _context82.stop();
|
|
11365
11392
|
}
|
|
11366
11393
|
}
|
|
11367
|
-
},
|
|
11394
|
+
}, _callee82, this);
|
|
11368
11395
|
}));
|
|
11369
11396
|
|
|
11370
|
-
function commitMessage(
|
|
11397
|
+
function commitMessage(_x107) {
|
|
11371
11398
|
return _commitMessage.apply(this, arguments);
|
|
11372
11399
|
}
|
|
11373
11400
|
|