stream-chat 8.1.3 → 8.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/browser.es.js +524 -428
- 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 +524 -428
- package/dist/browser.js.map +1 -1
- package/dist/index.es.js +524 -428
- package/dist/index.es.js.map +1 -1
- package/dist/index.js +524 -428
- package/dist/index.js.map +1 -1
- package/dist/types/client.d.ts +39 -12
- package/dist/types/client.d.ts.map +1 -1
- package/dist/types/types.d.ts +13 -0
- package/dist/types/types.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/client.ts +47 -11
- package/src/types.ts +16 -0
package/dist/index.es.js
CHANGED
|
@@ -8685,7 +8685,7 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8685
8685
|
*
|
|
8686
8686
|
* @param {string[]} user_ids which users to restore
|
|
8687
8687
|
*
|
|
8688
|
-
* @return {APIResponse}
|
|
8688
|
+
* @return {APIResponse} An API response
|
|
8689
8689
|
*/
|
|
8690
8690
|
|
|
8691
8691
|
}, {
|
|
@@ -8718,6 +8718,15 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8718
8718
|
|
|
8719
8719
|
return restoreUsers;
|
|
8720
8720
|
}()
|
|
8721
|
+
/**
|
|
8722
|
+
* reactivateUser - Reactivate one user
|
|
8723
|
+
*
|
|
8724
|
+
* @param {string} userID which user to reactivate
|
|
8725
|
+
* @param {ReactivateUserOptions} [options]
|
|
8726
|
+
*
|
|
8727
|
+
* @return {UserResponse} Reactivated user
|
|
8728
|
+
*/
|
|
8729
|
+
|
|
8721
8730
|
}, {
|
|
8722
8731
|
key: "reactivateUser",
|
|
8723
8732
|
value: function () {
|
|
@@ -8746,16 +8755,27 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8746
8755
|
|
|
8747
8756
|
return reactivateUser;
|
|
8748
8757
|
}()
|
|
8758
|
+
/**
|
|
8759
|
+
* reactivateUsers - Reactivate many users asynchronously
|
|
8760
|
+
*
|
|
8761
|
+
* @param {string[]} user_ids which users to reactivate
|
|
8762
|
+
* @param {ReactivateUsersOptions} [options]
|
|
8763
|
+
*
|
|
8764
|
+
* @return {TaskResponse} A task ID
|
|
8765
|
+
*/
|
|
8766
|
+
|
|
8749
8767
|
}, {
|
|
8750
|
-
key: "
|
|
8768
|
+
key: "reactivateUsers",
|
|
8751
8769
|
value: function () {
|
|
8752
|
-
var
|
|
8770
|
+
var _reactivateUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee31(user_ids, options) {
|
|
8753
8771
|
return _regeneratorRuntime.wrap(function _callee31$(_context31) {
|
|
8754
8772
|
while (1) {
|
|
8755
8773
|
switch (_context31.prev = _context31.next) {
|
|
8756
8774
|
case 0:
|
|
8757
8775
|
_context31.next = 2;
|
|
8758
|
-
return this.post(this.baseURL + "/users/"
|
|
8776
|
+
return this.post(this.baseURL + "/users/reactivate", _objectSpread({
|
|
8777
|
+
user_ids: user_ids
|
|
8778
|
+
}, options));
|
|
8759
8779
|
|
|
8760
8780
|
case 2:
|
|
8761
8781
|
return _context31.abrupt("return", _context31.sent);
|
|
@@ -8768,22 +8788,31 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8768
8788
|
}, _callee31, this);
|
|
8769
8789
|
}));
|
|
8770
8790
|
|
|
8771
|
-
function
|
|
8772
|
-
return
|
|
8791
|
+
function reactivateUsers(_x36, _x37) {
|
|
8792
|
+
return _reactivateUsers.apply(this, arguments);
|
|
8773
8793
|
}
|
|
8774
8794
|
|
|
8775
|
-
return
|
|
8795
|
+
return reactivateUsers;
|
|
8776
8796
|
}()
|
|
8797
|
+
/**
|
|
8798
|
+
* deactivateUser - Deactivate one user
|
|
8799
|
+
*
|
|
8800
|
+
* @param {string} userID which user to deactivate
|
|
8801
|
+
* @param {DeactivateUsersOptions} [options]
|
|
8802
|
+
*
|
|
8803
|
+
* @return {UserResponse} Deactivated user
|
|
8804
|
+
*/
|
|
8805
|
+
|
|
8777
8806
|
}, {
|
|
8778
|
-
key: "
|
|
8807
|
+
key: "deactivateUser",
|
|
8779
8808
|
value: function () {
|
|
8780
|
-
var
|
|
8809
|
+
var _deactivateUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee32(userID, options) {
|
|
8781
8810
|
return _regeneratorRuntime.wrap(function _callee32$(_context32) {
|
|
8782
8811
|
while (1) {
|
|
8783
8812
|
switch (_context32.prev = _context32.next) {
|
|
8784
8813
|
case 0:
|
|
8785
8814
|
_context32.next = 2;
|
|
8786
|
-
return this.
|
|
8815
|
+
return this.post(this.baseURL + "/users/".concat(userID, "/deactivate"), _objectSpread({}, options));
|
|
8787
8816
|
|
|
8788
8817
|
case 2:
|
|
8789
8818
|
return _context32.abrupt("return", _context32.sent);
|
|
@@ -8796,7 +8825,74 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8796
8825
|
}, _callee32, this);
|
|
8797
8826
|
}));
|
|
8798
8827
|
|
|
8799
|
-
function
|
|
8828
|
+
function deactivateUser(_x38, _x39) {
|
|
8829
|
+
return _deactivateUser.apply(this, arguments);
|
|
8830
|
+
}
|
|
8831
|
+
|
|
8832
|
+
return deactivateUser;
|
|
8833
|
+
}()
|
|
8834
|
+
/**
|
|
8835
|
+
* deactivateUsers - Deactivate many users asynchronously
|
|
8836
|
+
*
|
|
8837
|
+
* @param {string[]} user_ids which users to deactivate
|
|
8838
|
+
* @param {DeactivateUsersOptions} [options]
|
|
8839
|
+
*
|
|
8840
|
+
* @return {TaskResponse} A task ID
|
|
8841
|
+
*/
|
|
8842
|
+
|
|
8843
|
+
}, {
|
|
8844
|
+
key: "deactivateUsers",
|
|
8845
|
+
value: function () {
|
|
8846
|
+
var _deactivateUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee33(user_ids, options) {
|
|
8847
|
+
return _regeneratorRuntime.wrap(function _callee33$(_context33) {
|
|
8848
|
+
while (1) {
|
|
8849
|
+
switch (_context33.prev = _context33.next) {
|
|
8850
|
+
case 0:
|
|
8851
|
+
_context33.next = 2;
|
|
8852
|
+
return this.post(this.baseURL + "/users/deactivate", _objectSpread({
|
|
8853
|
+
user_ids: user_ids
|
|
8854
|
+
}, options));
|
|
8855
|
+
|
|
8856
|
+
case 2:
|
|
8857
|
+
return _context33.abrupt("return", _context33.sent);
|
|
8858
|
+
|
|
8859
|
+
case 3:
|
|
8860
|
+
case "end":
|
|
8861
|
+
return _context33.stop();
|
|
8862
|
+
}
|
|
8863
|
+
}
|
|
8864
|
+
}, _callee33, this);
|
|
8865
|
+
}));
|
|
8866
|
+
|
|
8867
|
+
function deactivateUsers(_x40, _x41) {
|
|
8868
|
+
return _deactivateUsers.apply(this, arguments);
|
|
8869
|
+
}
|
|
8870
|
+
|
|
8871
|
+
return deactivateUsers;
|
|
8872
|
+
}()
|
|
8873
|
+
}, {
|
|
8874
|
+
key: "exportUser",
|
|
8875
|
+
value: function () {
|
|
8876
|
+
var _exportUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee34(userID, options) {
|
|
8877
|
+
return _regeneratorRuntime.wrap(function _callee34$(_context34) {
|
|
8878
|
+
while (1) {
|
|
8879
|
+
switch (_context34.prev = _context34.next) {
|
|
8880
|
+
case 0:
|
|
8881
|
+
_context34.next = 2;
|
|
8882
|
+
return this.get(this.baseURL + "/users/".concat(userID, "/export"), _objectSpread({}, options));
|
|
8883
|
+
|
|
8884
|
+
case 2:
|
|
8885
|
+
return _context34.abrupt("return", _context34.sent);
|
|
8886
|
+
|
|
8887
|
+
case 3:
|
|
8888
|
+
case "end":
|
|
8889
|
+
return _context34.stop();
|
|
8890
|
+
}
|
|
8891
|
+
}
|
|
8892
|
+
}, _callee34, this);
|
|
8893
|
+
}));
|
|
8894
|
+
|
|
8895
|
+
function exportUser(_x42, _x43) {
|
|
8800
8896
|
return _exportUser.apply(this, arguments);
|
|
8801
8897
|
}
|
|
8802
8898
|
|
|
@@ -8812,28 +8908,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8812
8908
|
}, {
|
|
8813
8909
|
key: "banUser",
|
|
8814
8910
|
value: function () {
|
|
8815
|
-
var _banUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8816
|
-
return _regeneratorRuntime.wrap(function
|
|
8911
|
+
var _banUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee35(targetUserID, options) {
|
|
8912
|
+
return _regeneratorRuntime.wrap(function _callee35$(_context35) {
|
|
8817
8913
|
while (1) {
|
|
8818
|
-
switch (
|
|
8914
|
+
switch (_context35.prev = _context35.next) {
|
|
8819
8915
|
case 0:
|
|
8820
|
-
|
|
8916
|
+
_context35.next = 2;
|
|
8821
8917
|
return this.post(this.baseURL + '/moderation/ban', _objectSpread({
|
|
8822
8918
|
target_user_id: targetUserID
|
|
8823
8919
|
}, options));
|
|
8824
8920
|
|
|
8825
8921
|
case 2:
|
|
8826
|
-
return
|
|
8922
|
+
return _context35.abrupt("return", _context35.sent);
|
|
8827
8923
|
|
|
8828
8924
|
case 3:
|
|
8829
8925
|
case "end":
|
|
8830
|
-
return
|
|
8926
|
+
return _context35.stop();
|
|
8831
8927
|
}
|
|
8832
8928
|
}
|
|
8833
|
-
},
|
|
8929
|
+
}, _callee35, this);
|
|
8834
8930
|
}));
|
|
8835
8931
|
|
|
8836
|
-
function banUser(
|
|
8932
|
+
function banUser(_x44, _x45) {
|
|
8837
8933
|
return _banUser.apply(this, arguments);
|
|
8838
8934
|
}
|
|
8839
8935
|
|
|
@@ -8849,28 +8945,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8849
8945
|
}, {
|
|
8850
8946
|
key: "unbanUser",
|
|
8851
8947
|
value: function () {
|
|
8852
|
-
var _unbanUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8853
|
-
return _regeneratorRuntime.wrap(function
|
|
8948
|
+
var _unbanUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee36(targetUserID, options) {
|
|
8949
|
+
return _regeneratorRuntime.wrap(function _callee36$(_context36) {
|
|
8854
8950
|
while (1) {
|
|
8855
|
-
switch (
|
|
8951
|
+
switch (_context36.prev = _context36.next) {
|
|
8856
8952
|
case 0:
|
|
8857
|
-
|
|
8953
|
+
_context36.next = 2;
|
|
8858
8954
|
return this.delete(this.baseURL + '/moderation/ban', _objectSpread({
|
|
8859
8955
|
target_user_id: targetUserID
|
|
8860
8956
|
}, options));
|
|
8861
8957
|
|
|
8862
8958
|
case 2:
|
|
8863
|
-
return
|
|
8959
|
+
return _context36.abrupt("return", _context36.sent);
|
|
8864
8960
|
|
|
8865
8961
|
case 3:
|
|
8866
8962
|
case "end":
|
|
8867
|
-
return
|
|
8963
|
+
return _context36.stop();
|
|
8868
8964
|
}
|
|
8869
8965
|
}
|
|
8870
|
-
},
|
|
8966
|
+
}, _callee36, this);
|
|
8871
8967
|
}));
|
|
8872
8968
|
|
|
8873
|
-
function unbanUser(
|
|
8969
|
+
function unbanUser(_x46, _x47) {
|
|
8874
8970
|
return _unbanUser.apply(this, arguments);
|
|
8875
8971
|
}
|
|
8876
8972
|
|
|
@@ -8886,28 +8982,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8886
8982
|
}, {
|
|
8887
8983
|
key: "shadowBan",
|
|
8888
8984
|
value: function () {
|
|
8889
|
-
var _shadowBan = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8890
|
-
return _regeneratorRuntime.wrap(function
|
|
8985
|
+
var _shadowBan = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee37(targetUserID, options) {
|
|
8986
|
+
return _regeneratorRuntime.wrap(function _callee37$(_context37) {
|
|
8891
8987
|
while (1) {
|
|
8892
|
-
switch (
|
|
8988
|
+
switch (_context37.prev = _context37.next) {
|
|
8893
8989
|
case 0:
|
|
8894
|
-
|
|
8990
|
+
_context37.next = 2;
|
|
8895
8991
|
return this.banUser(targetUserID, _objectSpread({
|
|
8896
8992
|
shadow: true
|
|
8897
8993
|
}, options));
|
|
8898
8994
|
|
|
8899
8995
|
case 2:
|
|
8900
|
-
return
|
|
8996
|
+
return _context37.abrupt("return", _context37.sent);
|
|
8901
8997
|
|
|
8902
8998
|
case 3:
|
|
8903
8999
|
case "end":
|
|
8904
|
-
return
|
|
9000
|
+
return _context37.stop();
|
|
8905
9001
|
}
|
|
8906
9002
|
}
|
|
8907
|
-
},
|
|
9003
|
+
}, _callee37, this);
|
|
8908
9004
|
}));
|
|
8909
9005
|
|
|
8910
|
-
function shadowBan(
|
|
9006
|
+
function shadowBan(_x48, _x49) {
|
|
8911
9007
|
return _shadowBan.apply(this, arguments);
|
|
8912
9008
|
}
|
|
8913
9009
|
|
|
@@ -8923,28 +9019,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8923
9019
|
}, {
|
|
8924
9020
|
key: "removeShadowBan",
|
|
8925
9021
|
value: function () {
|
|
8926
|
-
var _removeShadowBan = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
8927
|
-
return _regeneratorRuntime.wrap(function
|
|
9022
|
+
var _removeShadowBan = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee38(targetUserID, options) {
|
|
9023
|
+
return _regeneratorRuntime.wrap(function _callee38$(_context38) {
|
|
8928
9024
|
while (1) {
|
|
8929
|
-
switch (
|
|
9025
|
+
switch (_context38.prev = _context38.next) {
|
|
8930
9026
|
case 0:
|
|
8931
|
-
|
|
9027
|
+
_context38.next = 2;
|
|
8932
9028
|
return this.unbanUser(targetUserID, _objectSpread({
|
|
8933
9029
|
shadow: true
|
|
8934
9030
|
}, options));
|
|
8935
9031
|
|
|
8936
9032
|
case 2:
|
|
8937
|
-
return
|
|
9033
|
+
return _context38.abrupt("return", _context38.sent);
|
|
8938
9034
|
|
|
8939
9035
|
case 3:
|
|
8940
9036
|
case "end":
|
|
8941
|
-
return
|
|
9037
|
+
return _context38.stop();
|
|
8942
9038
|
}
|
|
8943
9039
|
}
|
|
8944
|
-
},
|
|
9040
|
+
}, _callee38, this);
|
|
8945
9041
|
}));
|
|
8946
9042
|
|
|
8947
|
-
function removeShadowBan(
|
|
9043
|
+
function removeShadowBan(_x50, _x51) {
|
|
8948
9044
|
return _removeShadowBan.apply(this, arguments);
|
|
8949
9045
|
}
|
|
8950
9046
|
|
|
@@ -8961,15 +9057,15 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8961
9057
|
}, {
|
|
8962
9058
|
key: "muteUser",
|
|
8963
9059
|
value: function () {
|
|
8964
|
-
var _muteUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9060
|
+
var _muteUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee39(targetID, userID) {
|
|
8965
9061
|
var options,
|
|
8966
|
-
|
|
8967
|
-
return _regeneratorRuntime.wrap(function
|
|
9062
|
+
_args39 = arguments;
|
|
9063
|
+
return _regeneratorRuntime.wrap(function _callee39$(_context39) {
|
|
8968
9064
|
while (1) {
|
|
8969
|
-
switch (
|
|
9065
|
+
switch (_context39.prev = _context39.next) {
|
|
8970
9066
|
case 0:
|
|
8971
|
-
options =
|
|
8972
|
-
|
|
9067
|
+
options = _args39.length > 2 && _args39[2] !== undefined ? _args39[2] : {};
|
|
9068
|
+
_context39.next = 3;
|
|
8973
9069
|
return this.post(this.baseURL + '/moderation/mute', _objectSpread(_objectSpread({
|
|
8974
9070
|
target_id: targetID
|
|
8975
9071
|
}, userID ? {
|
|
@@ -8977,17 +9073,17 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
8977
9073
|
} : {}), options));
|
|
8978
9074
|
|
|
8979
9075
|
case 3:
|
|
8980
|
-
return
|
|
9076
|
+
return _context39.abrupt("return", _context39.sent);
|
|
8981
9077
|
|
|
8982
9078
|
case 4:
|
|
8983
9079
|
case "end":
|
|
8984
|
-
return
|
|
9080
|
+
return _context39.stop();
|
|
8985
9081
|
}
|
|
8986
9082
|
}
|
|
8987
|
-
},
|
|
9083
|
+
}, _callee39, this);
|
|
8988
9084
|
}));
|
|
8989
9085
|
|
|
8990
|
-
function muteUser(
|
|
9086
|
+
function muteUser(_x52, _x53) {
|
|
8991
9087
|
return _muteUser.apply(this, arguments);
|
|
8992
9088
|
}
|
|
8993
9089
|
|
|
@@ -9003,12 +9099,12 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9003
9099
|
}, {
|
|
9004
9100
|
key: "unmuteUser",
|
|
9005
9101
|
value: function () {
|
|
9006
|
-
var _unmuteUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9007
|
-
return _regeneratorRuntime.wrap(function
|
|
9102
|
+
var _unmuteUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee40(targetID, currentUserID) {
|
|
9103
|
+
return _regeneratorRuntime.wrap(function _callee40$(_context40) {
|
|
9008
9104
|
while (1) {
|
|
9009
|
-
switch (
|
|
9105
|
+
switch (_context40.prev = _context40.next) {
|
|
9010
9106
|
case 0:
|
|
9011
|
-
|
|
9107
|
+
_context40.next = 2;
|
|
9012
9108
|
return this.post(this.baseURL + '/moderation/unmute', _objectSpread({
|
|
9013
9109
|
target_id: targetID
|
|
9014
9110
|
}, currentUserID ? {
|
|
@@ -9016,17 +9112,17 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9016
9112
|
} : {}));
|
|
9017
9113
|
|
|
9018
9114
|
case 2:
|
|
9019
|
-
return
|
|
9115
|
+
return _context40.abrupt("return", _context40.sent);
|
|
9020
9116
|
|
|
9021
9117
|
case 3:
|
|
9022
9118
|
case "end":
|
|
9023
|
-
return
|
|
9119
|
+
return _context40.stop();
|
|
9024
9120
|
}
|
|
9025
9121
|
}
|
|
9026
|
-
},
|
|
9122
|
+
}, _callee40, this);
|
|
9027
9123
|
}));
|
|
9028
9124
|
|
|
9029
|
-
function unmuteUser(
|
|
9125
|
+
function unmuteUser(_x54, _x55) {
|
|
9030
9126
|
return _unmuteUser.apply(this, arguments);
|
|
9031
9127
|
}
|
|
9032
9128
|
|
|
@@ -9061,31 +9157,31 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9061
9157
|
}, {
|
|
9062
9158
|
key: "flagMessage",
|
|
9063
9159
|
value: function () {
|
|
9064
|
-
var _flagMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9160
|
+
var _flagMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee41(targetMessageID) {
|
|
9065
9161
|
var options,
|
|
9066
|
-
|
|
9067
|
-
return _regeneratorRuntime.wrap(function
|
|
9162
|
+
_args41 = arguments;
|
|
9163
|
+
return _regeneratorRuntime.wrap(function _callee41$(_context41) {
|
|
9068
9164
|
while (1) {
|
|
9069
|
-
switch (
|
|
9165
|
+
switch (_context41.prev = _context41.next) {
|
|
9070
9166
|
case 0:
|
|
9071
|
-
options =
|
|
9072
|
-
|
|
9167
|
+
options = _args41.length > 1 && _args41[1] !== undefined ? _args41[1] : {};
|
|
9168
|
+
_context41.next = 3;
|
|
9073
9169
|
return this.post(this.baseURL + '/moderation/flag', _objectSpread({
|
|
9074
9170
|
target_message_id: targetMessageID
|
|
9075
9171
|
}, options));
|
|
9076
9172
|
|
|
9077
9173
|
case 3:
|
|
9078
|
-
return
|
|
9174
|
+
return _context41.abrupt("return", _context41.sent);
|
|
9079
9175
|
|
|
9080
9176
|
case 4:
|
|
9081
9177
|
case "end":
|
|
9082
|
-
return
|
|
9178
|
+
return _context41.stop();
|
|
9083
9179
|
}
|
|
9084
9180
|
}
|
|
9085
|
-
},
|
|
9181
|
+
}, _callee41, this);
|
|
9086
9182
|
}));
|
|
9087
9183
|
|
|
9088
|
-
function flagMessage(
|
|
9184
|
+
function flagMessage(_x56) {
|
|
9089
9185
|
return _flagMessage.apply(this, arguments);
|
|
9090
9186
|
}
|
|
9091
9187
|
|
|
@@ -9101,31 +9197,31 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9101
9197
|
}, {
|
|
9102
9198
|
key: "flagUser",
|
|
9103
9199
|
value: function () {
|
|
9104
|
-
var _flagUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9200
|
+
var _flagUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee42(targetID) {
|
|
9105
9201
|
var options,
|
|
9106
|
-
|
|
9107
|
-
return _regeneratorRuntime.wrap(function
|
|
9202
|
+
_args42 = arguments;
|
|
9203
|
+
return _regeneratorRuntime.wrap(function _callee42$(_context42) {
|
|
9108
9204
|
while (1) {
|
|
9109
|
-
switch (
|
|
9205
|
+
switch (_context42.prev = _context42.next) {
|
|
9110
9206
|
case 0:
|
|
9111
|
-
options =
|
|
9112
|
-
|
|
9207
|
+
options = _args42.length > 1 && _args42[1] !== undefined ? _args42[1] : {};
|
|
9208
|
+
_context42.next = 3;
|
|
9113
9209
|
return this.post(this.baseURL + '/moderation/flag', _objectSpread({
|
|
9114
9210
|
target_user_id: targetID
|
|
9115
9211
|
}, options));
|
|
9116
9212
|
|
|
9117
9213
|
case 3:
|
|
9118
|
-
return
|
|
9214
|
+
return _context42.abrupt("return", _context42.sent);
|
|
9119
9215
|
|
|
9120
9216
|
case 4:
|
|
9121
9217
|
case "end":
|
|
9122
|
-
return
|
|
9218
|
+
return _context42.stop();
|
|
9123
9219
|
}
|
|
9124
9220
|
}
|
|
9125
|
-
},
|
|
9221
|
+
}, _callee42, this);
|
|
9126
9222
|
}));
|
|
9127
9223
|
|
|
9128
|
-
function flagUser(
|
|
9224
|
+
function flagUser(_x57) {
|
|
9129
9225
|
return _flagUser.apply(this, arguments);
|
|
9130
9226
|
}
|
|
9131
9227
|
|
|
@@ -9141,31 +9237,31 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9141
9237
|
}, {
|
|
9142
9238
|
key: "unflagMessage",
|
|
9143
9239
|
value: function () {
|
|
9144
|
-
var _unflagMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9240
|
+
var _unflagMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee43(targetMessageID) {
|
|
9145
9241
|
var options,
|
|
9146
|
-
|
|
9147
|
-
return _regeneratorRuntime.wrap(function
|
|
9242
|
+
_args43 = arguments;
|
|
9243
|
+
return _regeneratorRuntime.wrap(function _callee43$(_context43) {
|
|
9148
9244
|
while (1) {
|
|
9149
|
-
switch (
|
|
9245
|
+
switch (_context43.prev = _context43.next) {
|
|
9150
9246
|
case 0:
|
|
9151
|
-
options =
|
|
9152
|
-
|
|
9247
|
+
options = _args43.length > 1 && _args43[1] !== undefined ? _args43[1] : {};
|
|
9248
|
+
_context43.next = 3;
|
|
9153
9249
|
return this.post(this.baseURL + '/moderation/unflag', _objectSpread({
|
|
9154
9250
|
target_message_id: targetMessageID
|
|
9155
9251
|
}, options));
|
|
9156
9252
|
|
|
9157
9253
|
case 3:
|
|
9158
|
-
return
|
|
9254
|
+
return _context43.abrupt("return", _context43.sent);
|
|
9159
9255
|
|
|
9160
9256
|
case 4:
|
|
9161
9257
|
case "end":
|
|
9162
|
-
return
|
|
9258
|
+
return _context43.stop();
|
|
9163
9259
|
}
|
|
9164
9260
|
}
|
|
9165
|
-
},
|
|
9261
|
+
}, _callee43, this);
|
|
9166
9262
|
}));
|
|
9167
9263
|
|
|
9168
|
-
function unflagMessage(
|
|
9264
|
+
function unflagMessage(_x58) {
|
|
9169
9265
|
return _unflagMessage.apply(this, arguments);
|
|
9170
9266
|
}
|
|
9171
9267
|
|
|
@@ -9181,31 +9277,31 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9181
9277
|
}, {
|
|
9182
9278
|
key: "unflagUser",
|
|
9183
9279
|
value: function () {
|
|
9184
|
-
var _unflagUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9280
|
+
var _unflagUser = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee44(targetID) {
|
|
9185
9281
|
var options,
|
|
9186
|
-
|
|
9187
|
-
return _regeneratorRuntime.wrap(function
|
|
9282
|
+
_args44 = arguments;
|
|
9283
|
+
return _regeneratorRuntime.wrap(function _callee44$(_context44) {
|
|
9188
9284
|
while (1) {
|
|
9189
|
-
switch (
|
|
9285
|
+
switch (_context44.prev = _context44.next) {
|
|
9190
9286
|
case 0:
|
|
9191
|
-
options =
|
|
9192
|
-
|
|
9287
|
+
options = _args44.length > 1 && _args44[1] !== undefined ? _args44[1] : {};
|
|
9288
|
+
_context44.next = 3;
|
|
9193
9289
|
return this.post(this.baseURL + '/moderation/unflag', _objectSpread({
|
|
9194
9290
|
target_user_id: targetID
|
|
9195
9291
|
}, options));
|
|
9196
9292
|
|
|
9197
9293
|
case 3:
|
|
9198
|
-
return
|
|
9294
|
+
return _context44.abrupt("return", _context44.sent);
|
|
9199
9295
|
|
|
9200
9296
|
case 4:
|
|
9201
9297
|
case "end":
|
|
9202
|
-
return
|
|
9298
|
+
return _context44.stop();
|
|
9203
9299
|
}
|
|
9204
9300
|
}
|
|
9205
|
-
},
|
|
9301
|
+
}, _callee44, this);
|
|
9206
9302
|
}));
|
|
9207
9303
|
|
|
9208
|
-
function unflagUser(
|
|
9304
|
+
function unflagUser(_x59) {
|
|
9209
9305
|
return _unflagUser.apply(this, arguments);
|
|
9210
9306
|
}
|
|
9211
9307
|
|
|
@@ -9222,29 +9318,29 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9222
9318
|
}, {
|
|
9223
9319
|
key: "getCallToken",
|
|
9224
9320
|
value: function () {
|
|
9225
|
-
var _getCallToken = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9321
|
+
var _getCallToken = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee45(callID) {
|
|
9226
9322
|
var options,
|
|
9227
|
-
|
|
9228
|
-
return _regeneratorRuntime.wrap(function
|
|
9323
|
+
_args45 = arguments;
|
|
9324
|
+
return _regeneratorRuntime.wrap(function _callee45$(_context45) {
|
|
9229
9325
|
while (1) {
|
|
9230
|
-
switch (
|
|
9326
|
+
switch (_context45.prev = _context45.next) {
|
|
9231
9327
|
case 0:
|
|
9232
|
-
options =
|
|
9233
|
-
|
|
9328
|
+
options = _args45.length > 1 && _args45[1] !== undefined ? _args45[1] : {};
|
|
9329
|
+
_context45.next = 3;
|
|
9234
9330
|
return this.post(this.baseURL + "/calls/".concat(callID), _objectSpread({}, options));
|
|
9235
9331
|
|
|
9236
9332
|
case 3:
|
|
9237
|
-
return
|
|
9333
|
+
return _context45.abrupt("return", _context45.sent);
|
|
9238
9334
|
|
|
9239
9335
|
case 4:
|
|
9240
9336
|
case "end":
|
|
9241
|
-
return
|
|
9337
|
+
return _context45.stop();
|
|
9242
9338
|
}
|
|
9243
9339
|
}
|
|
9244
|
-
},
|
|
9340
|
+
}, _callee45, this);
|
|
9245
9341
|
}));
|
|
9246
9342
|
|
|
9247
|
-
function getCallToken(
|
|
9343
|
+
function getCallToken(_x60) {
|
|
9248
9344
|
return _getCallToken.apply(this, arguments);
|
|
9249
9345
|
}
|
|
9250
9346
|
|
|
@@ -9267,30 +9363,30 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9267
9363
|
}, {
|
|
9268
9364
|
key: "_queryFlags",
|
|
9269
9365
|
value: function () {
|
|
9270
|
-
var _queryFlags2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9366
|
+
var _queryFlags2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee46() {
|
|
9271
9367
|
var filterConditions,
|
|
9272
9368
|
options,
|
|
9273
|
-
|
|
9274
|
-
return _regeneratorRuntime.wrap(function
|
|
9369
|
+
_args46 = arguments;
|
|
9370
|
+
return _regeneratorRuntime.wrap(function _callee46$(_context46) {
|
|
9275
9371
|
while (1) {
|
|
9276
|
-
switch (
|
|
9372
|
+
switch (_context46.prev = _context46.next) {
|
|
9277
9373
|
case 0:
|
|
9278
|
-
filterConditions =
|
|
9279
|
-
options =
|
|
9280
|
-
|
|
9374
|
+
filterConditions = _args46.length > 0 && _args46[0] !== undefined ? _args46[0] : {};
|
|
9375
|
+
options = _args46.length > 1 && _args46[1] !== undefined ? _args46[1] : {};
|
|
9376
|
+
_context46.next = 4;
|
|
9281
9377
|
return this.post(this.baseURL + '/moderation/flags', _objectSpread({
|
|
9282
9378
|
filter_conditions: filterConditions
|
|
9283
9379
|
}, options));
|
|
9284
9380
|
|
|
9285
9381
|
case 4:
|
|
9286
|
-
return
|
|
9382
|
+
return _context46.abrupt("return", _context46.sent);
|
|
9287
9383
|
|
|
9288
9384
|
case 5:
|
|
9289
9385
|
case "end":
|
|
9290
|
-
return
|
|
9386
|
+
return _context46.stop();
|
|
9291
9387
|
}
|
|
9292
9388
|
}
|
|
9293
|
-
},
|
|
9389
|
+
}, _callee46, this);
|
|
9294
9390
|
}));
|
|
9295
9391
|
|
|
9296
9392
|
function _queryFlags() {
|
|
@@ -9316,30 +9412,30 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9316
9412
|
}, {
|
|
9317
9413
|
key: "_queryFlagReports",
|
|
9318
9414
|
value: function () {
|
|
9319
|
-
var _queryFlagReports2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9415
|
+
var _queryFlagReports2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee47() {
|
|
9320
9416
|
var filterConditions,
|
|
9321
9417
|
options,
|
|
9322
|
-
|
|
9323
|
-
return _regeneratorRuntime.wrap(function
|
|
9418
|
+
_args47 = arguments;
|
|
9419
|
+
return _regeneratorRuntime.wrap(function _callee47$(_context47) {
|
|
9324
9420
|
while (1) {
|
|
9325
|
-
switch (
|
|
9421
|
+
switch (_context47.prev = _context47.next) {
|
|
9326
9422
|
case 0:
|
|
9327
|
-
filterConditions =
|
|
9328
|
-
options =
|
|
9329
|
-
|
|
9423
|
+
filterConditions = _args47.length > 0 && _args47[0] !== undefined ? _args47[0] : {};
|
|
9424
|
+
options = _args47.length > 1 && _args47[1] !== undefined ? _args47[1] : {};
|
|
9425
|
+
_context47.next = 4;
|
|
9330
9426
|
return this.post(this.baseURL + '/moderation/reports', _objectSpread({
|
|
9331
9427
|
filter_conditions: filterConditions
|
|
9332
9428
|
}, options));
|
|
9333
9429
|
|
|
9334
9430
|
case 4:
|
|
9335
|
-
return
|
|
9431
|
+
return _context47.abrupt("return", _context47.sent);
|
|
9336
9432
|
|
|
9337
9433
|
case 5:
|
|
9338
9434
|
case "end":
|
|
9339
|
-
return
|
|
9435
|
+
return _context47.stop();
|
|
9340
9436
|
}
|
|
9341
9437
|
}
|
|
9342
|
-
},
|
|
9438
|
+
}, _callee47, this);
|
|
9343
9439
|
}));
|
|
9344
9440
|
|
|
9345
9441
|
function _queryFlagReports() {
|
|
@@ -9366,31 +9462,31 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9366
9462
|
}, {
|
|
9367
9463
|
key: "_reviewFlagReport",
|
|
9368
9464
|
value: function () {
|
|
9369
|
-
var _reviewFlagReport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9465
|
+
var _reviewFlagReport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee48(id, reviewResult) {
|
|
9370
9466
|
var options,
|
|
9371
|
-
|
|
9372
|
-
return _regeneratorRuntime.wrap(function
|
|
9467
|
+
_args48 = arguments;
|
|
9468
|
+
return _regeneratorRuntime.wrap(function _callee48$(_context48) {
|
|
9373
9469
|
while (1) {
|
|
9374
|
-
switch (
|
|
9470
|
+
switch (_context48.prev = _context48.next) {
|
|
9375
9471
|
case 0:
|
|
9376
|
-
options =
|
|
9377
|
-
|
|
9472
|
+
options = _args48.length > 2 && _args48[2] !== undefined ? _args48[2] : {};
|
|
9473
|
+
_context48.next = 3;
|
|
9378
9474
|
return this.patch(this.baseURL + "/moderation/reports/".concat(id), _objectSpread({
|
|
9379
9475
|
review_result: reviewResult
|
|
9380
9476
|
}, options));
|
|
9381
9477
|
|
|
9382
9478
|
case 3:
|
|
9383
|
-
return
|
|
9479
|
+
return _context48.abrupt("return", _context48.sent);
|
|
9384
9480
|
|
|
9385
9481
|
case 4:
|
|
9386
9482
|
case "end":
|
|
9387
|
-
return
|
|
9483
|
+
return _context48.stop();
|
|
9388
9484
|
}
|
|
9389
9485
|
}
|
|
9390
|
-
},
|
|
9486
|
+
}, _callee48, this);
|
|
9391
9487
|
}));
|
|
9392
9488
|
|
|
9393
|
-
function _reviewFlagReport(
|
|
9489
|
+
function _reviewFlagReport(_x61, _x62) {
|
|
9394
9490
|
return _reviewFlagReport2.apply(this, arguments);
|
|
9395
9491
|
}
|
|
9396
9492
|
|
|
@@ -9412,31 +9508,31 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9412
9508
|
}, {
|
|
9413
9509
|
key: "_unblockMessage",
|
|
9414
9510
|
value: function () {
|
|
9415
|
-
var _unblockMessage2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9511
|
+
var _unblockMessage2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee49(targetMessageID) {
|
|
9416
9512
|
var options,
|
|
9417
|
-
|
|
9418
|
-
return _regeneratorRuntime.wrap(function
|
|
9513
|
+
_args49 = arguments;
|
|
9514
|
+
return _regeneratorRuntime.wrap(function _callee49$(_context49) {
|
|
9419
9515
|
while (1) {
|
|
9420
|
-
switch (
|
|
9516
|
+
switch (_context49.prev = _context49.next) {
|
|
9421
9517
|
case 0:
|
|
9422
|
-
options =
|
|
9423
|
-
|
|
9518
|
+
options = _args49.length > 1 && _args49[1] !== undefined ? _args49[1] : {};
|
|
9519
|
+
_context49.next = 3;
|
|
9424
9520
|
return this.post(this.baseURL + '/moderation/unblock_message', _objectSpread({
|
|
9425
9521
|
target_message_id: targetMessageID
|
|
9426
9522
|
}, options));
|
|
9427
9523
|
|
|
9428
9524
|
case 3:
|
|
9429
|
-
return
|
|
9525
|
+
return _context49.abrupt("return", _context49.sent);
|
|
9430
9526
|
|
|
9431
9527
|
case 4:
|
|
9432
9528
|
case "end":
|
|
9433
|
-
return
|
|
9529
|
+
return _context49.stop();
|
|
9434
9530
|
}
|
|
9435
9531
|
}
|
|
9436
|
-
},
|
|
9532
|
+
}, _callee49, this);
|
|
9437
9533
|
}));
|
|
9438
9534
|
|
|
9439
|
-
function _unblockMessage(
|
|
9535
|
+
function _unblockMessage(_x63) {
|
|
9440
9536
|
return _unblockMessage2.apply(this, arguments);
|
|
9441
9537
|
}
|
|
9442
9538
|
|
|
@@ -9463,23 +9559,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9463
9559
|
* @return {Promise<APIResponse>}
|
|
9464
9560
|
*/
|
|
9465
9561
|
function () {
|
|
9466
|
-
var _markChannelsRead = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9562
|
+
var _markChannelsRead = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee50() {
|
|
9467
9563
|
var data,
|
|
9468
|
-
|
|
9469
|
-
return _regeneratorRuntime.wrap(function
|
|
9564
|
+
_args50 = arguments;
|
|
9565
|
+
return _regeneratorRuntime.wrap(function _callee50$(_context50) {
|
|
9470
9566
|
while (1) {
|
|
9471
|
-
switch (
|
|
9567
|
+
switch (_context50.prev = _context50.next) {
|
|
9472
9568
|
case 0:
|
|
9473
|
-
data =
|
|
9474
|
-
|
|
9569
|
+
data = _args50.length > 0 && _args50[0] !== undefined ? _args50[0] : {};
|
|
9570
|
+
_context50.next = 3;
|
|
9475
9571
|
return this.post(this.baseURL + '/channels/read', _objectSpread({}, data));
|
|
9476
9572
|
|
|
9477
9573
|
case 3:
|
|
9478
9574
|
case "end":
|
|
9479
|
-
return
|
|
9575
|
+
return _context50.stop();
|
|
9480
9576
|
}
|
|
9481
9577
|
}
|
|
9482
|
-
},
|
|
9578
|
+
}, _callee50, this);
|
|
9483
9579
|
}));
|
|
9484
9580
|
|
|
9485
9581
|
function markChannelsRead() {
|
|
@@ -9554,28 +9650,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9554
9650
|
}, {
|
|
9555
9651
|
key: "translateMessage",
|
|
9556
9652
|
value: function () {
|
|
9557
|
-
var _translateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9558
|
-
return _regeneratorRuntime.wrap(function
|
|
9653
|
+
var _translateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee51(messageId, language) {
|
|
9654
|
+
return _regeneratorRuntime.wrap(function _callee51$(_context51) {
|
|
9559
9655
|
while (1) {
|
|
9560
|
-
switch (
|
|
9656
|
+
switch (_context51.prev = _context51.next) {
|
|
9561
9657
|
case 0:
|
|
9562
|
-
|
|
9658
|
+
_context51.next = 2;
|
|
9563
9659
|
return this.post(this.baseURL + "/messages/".concat(messageId, "/translate"), {
|
|
9564
9660
|
language: language
|
|
9565
9661
|
});
|
|
9566
9662
|
|
|
9567
9663
|
case 2:
|
|
9568
|
-
return
|
|
9664
|
+
return _context51.abrupt("return", _context51.sent);
|
|
9569
9665
|
|
|
9570
9666
|
case 3:
|
|
9571
9667
|
case "end":
|
|
9572
|
-
return
|
|
9668
|
+
return _context51.stop();
|
|
9573
9669
|
}
|
|
9574
9670
|
}
|
|
9575
|
-
},
|
|
9671
|
+
}, _callee51, this);
|
|
9576
9672
|
}));
|
|
9577
9673
|
|
|
9578
|
-
function translateMessage(
|
|
9674
|
+
function translateMessage(_x64, _x65) {
|
|
9579
9675
|
return _translateMessage.apply(this, arguments);
|
|
9580
9676
|
}
|
|
9581
9677
|
|
|
@@ -9677,14 +9773,14 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9677
9773
|
}, {
|
|
9678
9774
|
key: "updateMessage",
|
|
9679
9775
|
value: function () {
|
|
9680
|
-
var _updateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9776
|
+
var _updateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee52(message, userId, options) {
|
|
9681
9777
|
var clonedMessage, reservedMessageFields;
|
|
9682
|
-
return _regeneratorRuntime.wrap(function
|
|
9778
|
+
return _regeneratorRuntime.wrap(function _callee52$(_context52) {
|
|
9683
9779
|
while (1) {
|
|
9684
|
-
switch (
|
|
9780
|
+
switch (_context52.prev = _context52.next) {
|
|
9685
9781
|
case 0:
|
|
9686
9782
|
if (message.id) {
|
|
9687
|
-
|
|
9783
|
+
_context52.next = 2;
|
|
9688
9784
|
break;
|
|
9689
9785
|
}
|
|
9690
9786
|
|
|
@@ -9721,23 +9817,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9721
9817
|
});
|
|
9722
9818
|
}
|
|
9723
9819
|
|
|
9724
|
-
|
|
9820
|
+
_context52.next = 10;
|
|
9725
9821
|
return this.post(this.baseURL + "/messages/".concat(message.id), _objectSpread({
|
|
9726
9822
|
message: clonedMessage
|
|
9727
9823
|
}, options));
|
|
9728
9824
|
|
|
9729
9825
|
case 10:
|
|
9730
|
-
return
|
|
9826
|
+
return _context52.abrupt("return", _context52.sent);
|
|
9731
9827
|
|
|
9732
9828
|
case 11:
|
|
9733
9829
|
case "end":
|
|
9734
|
-
return
|
|
9830
|
+
return _context52.stop();
|
|
9735
9831
|
}
|
|
9736
9832
|
}
|
|
9737
|
-
},
|
|
9833
|
+
}, _callee52, this);
|
|
9738
9834
|
}));
|
|
9739
9835
|
|
|
9740
|
-
function updateMessage(
|
|
9836
|
+
function updateMessage(_x66, _x67, _x68) {
|
|
9741
9837
|
return _updateMessage.apply(this, arguments);
|
|
9742
9838
|
}
|
|
9743
9839
|
|
|
@@ -9760,14 +9856,14 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9760
9856
|
}, {
|
|
9761
9857
|
key: "partialUpdateMessage",
|
|
9762
9858
|
value: function () {
|
|
9763
|
-
var _partialUpdateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9859
|
+
var _partialUpdateMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee53(id, partialMessageObject, userId, options) {
|
|
9764
9860
|
var user;
|
|
9765
|
-
return _regeneratorRuntime.wrap(function
|
|
9861
|
+
return _regeneratorRuntime.wrap(function _callee53$(_context53) {
|
|
9766
9862
|
while (1) {
|
|
9767
|
-
switch (
|
|
9863
|
+
switch (_context53.prev = _context53.next) {
|
|
9768
9864
|
case 0:
|
|
9769
9865
|
if (id) {
|
|
9770
|
-
|
|
9866
|
+
_context53.next = 2;
|
|
9771
9867
|
break;
|
|
9772
9868
|
}
|
|
9773
9869
|
|
|
@@ -9782,23 +9878,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9782
9878
|
};
|
|
9783
9879
|
}
|
|
9784
9880
|
|
|
9785
|
-
|
|
9881
|
+
_context53.next = 6;
|
|
9786
9882
|
return this.put(this.baseURL + "/messages/".concat(id), _objectSpread(_objectSpread(_objectSpread({}, partialMessageObject), options), {}, {
|
|
9787
9883
|
user: user
|
|
9788
9884
|
}));
|
|
9789
9885
|
|
|
9790
9886
|
case 6:
|
|
9791
|
-
return
|
|
9887
|
+
return _context53.abrupt("return", _context53.sent);
|
|
9792
9888
|
|
|
9793
9889
|
case 7:
|
|
9794
9890
|
case "end":
|
|
9795
|
-
return
|
|
9891
|
+
return _context53.stop();
|
|
9796
9892
|
}
|
|
9797
9893
|
}
|
|
9798
|
-
},
|
|
9894
|
+
}, _callee53, this);
|
|
9799
9895
|
}));
|
|
9800
9896
|
|
|
9801
|
-
function partialUpdateMessage(
|
|
9897
|
+
function partialUpdateMessage(_x69, _x70, _x71, _x72) {
|
|
9802
9898
|
return _partialUpdateMessage.apply(this, arguments);
|
|
9803
9899
|
}
|
|
9804
9900
|
|
|
@@ -9807,11 +9903,11 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9807
9903
|
}, {
|
|
9808
9904
|
key: "deleteMessage",
|
|
9809
9905
|
value: function () {
|
|
9810
|
-
var _deleteMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9906
|
+
var _deleteMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee54(messageID, hardDelete) {
|
|
9811
9907
|
var params;
|
|
9812
|
-
return _regeneratorRuntime.wrap(function
|
|
9908
|
+
return _regeneratorRuntime.wrap(function _callee54$(_context54) {
|
|
9813
9909
|
while (1) {
|
|
9814
|
-
switch (
|
|
9910
|
+
switch (_context54.prev = _context54.next) {
|
|
9815
9911
|
case 0:
|
|
9816
9912
|
params = {};
|
|
9817
9913
|
|
|
@@ -9821,21 +9917,21 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9821
9917
|
};
|
|
9822
9918
|
}
|
|
9823
9919
|
|
|
9824
|
-
|
|
9920
|
+
_context54.next = 4;
|
|
9825
9921
|
return this.delete(this.baseURL + "/messages/".concat(messageID), params);
|
|
9826
9922
|
|
|
9827
9923
|
case 4:
|
|
9828
|
-
return
|
|
9924
|
+
return _context54.abrupt("return", _context54.sent);
|
|
9829
9925
|
|
|
9830
9926
|
case 5:
|
|
9831
9927
|
case "end":
|
|
9832
|
-
return
|
|
9928
|
+
return _context54.stop();
|
|
9833
9929
|
}
|
|
9834
9930
|
}
|
|
9835
|
-
},
|
|
9931
|
+
}, _callee54, this);
|
|
9836
9932
|
}));
|
|
9837
9933
|
|
|
9838
|
-
function deleteMessage(
|
|
9934
|
+
function deleteMessage(_x73, _x74) {
|
|
9839
9935
|
return _deleteMessage.apply(this, arguments);
|
|
9840
9936
|
}
|
|
9841
9937
|
|
|
@@ -9844,26 +9940,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9844
9940
|
}, {
|
|
9845
9941
|
key: "getMessage",
|
|
9846
9942
|
value: function () {
|
|
9847
|
-
var _getMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
9848
|
-
return _regeneratorRuntime.wrap(function
|
|
9943
|
+
var _getMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee55(messageID) {
|
|
9944
|
+
return _regeneratorRuntime.wrap(function _callee55$(_context55) {
|
|
9849
9945
|
while (1) {
|
|
9850
|
-
switch (
|
|
9946
|
+
switch (_context55.prev = _context55.next) {
|
|
9851
9947
|
case 0:
|
|
9852
|
-
|
|
9948
|
+
_context55.next = 2;
|
|
9853
9949
|
return this.get(this.baseURL + "/messages/".concat(messageID));
|
|
9854
9950
|
|
|
9855
9951
|
case 2:
|
|
9856
|
-
return
|
|
9952
|
+
return _context55.abrupt("return", _context55.sent);
|
|
9857
9953
|
|
|
9858
9954
|
case 3:
|
|
9859
9955
|
case "end":
|
|
9860
|
-
return
|
|
9956
|
+
return _context55.stop();
|
|
9861
9957
|
}
|
|
9862
9958
|
}
|
|
9863
|
-
},
|
|
9959
|
+
}, _callee55, this);
|
|
9864
9960
|
}));
|
|
9865
9961
|
|
|
9866
|
-
function getMessage(
|
|
9962
|
+
function getMessage(_x75) {
|
|
9867
9963
|
return _getMessage.apply(this, arguments);
|
|
9868
9964
|
}
|
|
9869
9965
|
|
|
@@ -9872,7 +9968,7 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
9872
9968
|
}, {
|
|
9873
9969
|
key: "getUserAgent",
|
|
9874
9970
|
value: function getUserAgent() {
|
|
9875
|
-
return this.userAgent || "stream-chat-javascript-client-".concat(this.node ? 'node' : 'browser', "-", "8.
|
|
9971
|
+
return this.userAgent || "stream-chat-javascript-client-".concat(this.node ? 'node' : 'browser', "-", "8.2.0");
|
|
9876
9972
|
}
|
|
9877
9973
|
}, {
|
|
9878
9974
|
key: "setUserAgent",
|
|
@@ -10079,28 +10175,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10079
10175
|
}, {
|
|
10080
10176
|
key: "sendUserCustomEvent",
|
|
10081
10177
|
value: function () {
|
|
10082
|
-
var _sendUserCustomEvent = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10083
|
-
return _regeneratorRuntime.wrap(function
|
|
10178
|
+
var _sendUserCustomEvent = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee56(targetUserID, event) {
|
|
10179
|
+
return _regeneratorRuntime.wrap(function _callee56$(_context56) {
|
|
10084
10180
|
while (1) {
|
|
10085
|
-
switch (
|
|
10181
|
+
switch (_context56.prev = _context56.next) {
|
|
10086
10182
|
case 0:
|
|
10087
|
-
|
|
10183
|
+
_context56.next = 2;
|
|
10088
10184
|
return this.post("".concat(this.baseURL, "/users/").concat(targetUserID, "/event"), {
|
|
10089
10185
|
event: event
|
|
10090
10186
|
});
|
|
10091
10187
|
|
|
10092
10188
|
case 2:
|
|
10093
|
-
return
|
|
10189
|
+
return _context56.abrupt("return", _context56.sent);
|
|
10094
10190
|
|
|
10095
10191
|
case 3:
|
|
10096
10192
|
case "end":
|
|
10097
|
-
return
|
|
10193
|
+
return _context56.stop();
|
|
10098
10194
|
}
|
|
10099
10195
|
}
|
|
10100
|
-
},
|
|
10196
|
+
}, _callee56, this);
|
|
10101
10197
|
}));
|
|
10102
10198
|
|
|
10103
|
-
function sendUserCustomEvent(
|
|
10199
|
+
function sendUserCustomEvent(_x76, _x77) {
|
|
10104
10200
|
return _sendUserCustomEvent.apply(this, arguments);
|
|
10105
10201
|
}
|
|
10106
10202
|
|
|
@@ -10168,32 +10264,32 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10168
10264
|
}, {
|
|
10169
10265
|
key: "createSegment",
|
|
10170
10266
|
value: function () {
|
|
10171
|
-
var _createSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10267
|
+
var _createSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee57(params) {
|
|
10172
10268
|
var _yield$this$post, segment;
|
|
10173
10269
|
|
|
10174
|
-
return _regeneratorRuntime.wrap(function
|
|
10270
|
+
return _regeneratorRuntime.wrap(function _callee57$(_context57) {
|
|
10175
10271
|
while (1) {
|
|
10176
|
-
switch (
|
|
10272
|
+
switch (_context57.prev = _context57.next) {
|
|
10177
10273
|
case 0:
|
|
10178
|
-
|
|
10274
|
+
_context57.next = 2;
|
|
10179
10275
|
return this.post(this.baseURL + "/segments", {
|
|
10180
10276
|
segment: params
|
|
10181
10277
|
});
|
|
10182
10278
|
|
|
10183
10279
|
case 2:
|
|
10184
|
-
_yield$this$post =
|
|
10280
|
+
_yield$this$post = _context57.sent;
|
|
10185
10281
|
segment = _yield$this$post.segment;
|
|
10186
|
-
return
|
|
10282
|
+
return _context57.abrupt("return", segment);
|
|
10187
10283
|
|
|
10188
10284
|
case 5:
|
|
10189
10285
|
case "end":
|
|
10190
|
-
return
|
|
10286
|
+
return _context57.stop();
|
|
10191
10287
|
}
|
|
10192
10288
|
}
|
|
10193
|
-
},
|
|
10289
|
+
}, _callee57, this);
|
|
10194
10290
|
}));
|
|
10195
10291
|
|
|
10196
|
-
function createSegment(
|
|
10292
|
+
function createSegment(_x78) {
|
|
10197
10293
|
return _createSegment.apply(this, arguments);
|
|
10198
10294
|
}
|
|
10199
10295
|
|
|
@@ -10209,15 +10305,15 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10209
10305
|
}, {
|
|
10210
10306
|
key: "querySegments",
|
|
10211
10307
|
value: function () {
|
|
10212
|
-
var _querySegments = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10308
|
+
var _querySegments = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee58(filters) {
|
|
10213
10309
|
var options,
|
|
10214
|
-
|
|
10215
|
-
return _regeneratorRuntime.wrap(function
|
|
10310
|
+
_args58 = arguments;
|
|
10311
|
+
return _regeneratorRuntime.wrap(function _callee58$(_context58) {
|
|
10216
10312
|
while (1) {
|
|
10217
|
-
switch (
|
|
10313
|
+
switch (_context58.prev = _context58.next) {
|
|
10218
10314
|
case 0:
|
|
10219
|
-
options =
|
|
10220
|
-
|
|
10315
|
+
options = _args58.length > 1 && _args58[1] !== undefined ? _args58[1] : {};
|
|
10316
|
+
_context58.next = 3;
|
|
10221
10317
|
return this.get(this.baseURL + "/segments", {
|
|
10222
10318
|
payload: _objectSpread({
|
|
10223
10319
|
filter_conditions: filters
|
|
@@ -10225,17 +10321,17 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10225
10321
|
});
|
|
10226
10322
|
|
|
10227
10323
|
case 3:
|
|
10228
|
-
return
|
|
10324
|
+
return _context58.abrupt("return", _context58.sent);
|
|
10229
10325
|
|
|
10230
10326
|
case 4:
|
|
10231
10327
|
case "end":
|
|
10232
|
-
return
|
|
10328
|
+
return _context58.stop();
|
|
10233
10329
|
}
|
|
10234
10330
|
}
|
|
10235
|
-
},
|
|
10331
|
+
}, _callee58, this);
|
|
10236
10332
|
}));
|
|
10237
10333
|
|
|
10238
|
-
function querySegments(
|
|
10334
|
+
function querySegments(_x79) {
|
|
10239
10335
|
return _querySegments.apply(this, arguments);
|
|
10240
10336
|
}
|
|
10241
10337
|
|
|
@@ -10253,32 +10349,32 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10253
10349
|
}, {
|
|
10254
10350
|
key: "updateSegment",
|
|
10255
10351
|
value: function () {
|
|
10256
|
-
var _updateSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10352
|
+
var _updateSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee59(id, params) {
|
|
10257
10353
|
var _yield$this$put, segment;
|
|
10258
10354
|
|
|
10259
|
-
return _regeneratorRuntime.wrap(function
|
|
10355
|
+
return _regeneratorRuntime.wrap(function _callee59$(_context59) {
|
|
10260
10356
|
while (1) {
|
|
10261
|
-
switch (
|
|
10357
|
+
switch (_context59.prev = _context59.next) {
|
|
10262
10358
|
case 0:
|
|
10263
|
-
|
|
10359
|
+
_context59.next = 2;
|
|
10264
10360
|
return this.put(this.baseURL + "/segments/".concat(id), {
|
|
10265
10361
|
segment: params
|
|
10266
10362
|
});
|
|
10267
10363
|
|
|
10268
10364
|
case 2:
|
|
10269
|
-
_yield$this$put =
|
|
10365
|
+
_yield$this$put = _context59.sent;
|
|
10270
10366
|
segment = _yield$this$put.segment;
|
|
10271
|
-
return
|
|
10367
|
+
return _context59.abrupt("return", segment);
|
|
10272
10368
|
|
|
10273
10369
|
case 5:
|
|
10274
10370
|
case "end":
|
|
10275
|
-
return
|
|
10371
|
+
return _context59.stop();
|
|
10276
10372
|
}
|
|
10277
10373
|
}
|
|
10278
|
-
},
|
|
10374
|
+
}, _callee59, this);
|
|
10279
10375
|
}));
|
|
10280
10376
|
|
|
10281
|
-
function updateSegment(
|
|
10377
|
+
function updateSegment(_x80, _x81) {
|
|
10282
10378
|
return _updateSegment.apply(this, arguments);
|
|
10283
10379
|
}
|
|
10284
10380
|
|
|
@@ -10295,22 +10391,22 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10295
10391
|
}, {
|
|
10296
10392
|
key: "deleteSegment",
|
|
10297
10393
|
value: function () {
|
|
10298
|
-
var _deleteSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10299
|
-
return _regeneratorRuntime.wrap(function
|
|
10394
|
+
var _deleteSegment = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee60(id) {
|
|
10395
|
+
return _regeneratorRuntime.wrap(function _callee60$(_context60) {
|
|
10300
10396
|
while (1) {
|
|
10301
|
-
switch (
|
|
10397
|
+
switch (_context60.prev = _context60.next) {
|
|
10302
10398
|
case 0:
|
|
10303
|
-
return
|
|
10399
|
+
return _context60.abrupt("return", this.delete(this.baseURL + "/segments/".concat(id)));
|
|
10304
10400
|
|
|
10305
10401
|
case 1:
|
|
10306
10402
|
case "end":
|
|
10307
|
-
return
|
|
10403
|
+
return _context60.stop();
|
|
10308
10404
|
}
|
|
10309
10405
|
}
|
|
10310
|
-
},
|
|
10406
|
+
}, _callee60, this);
|
|
10311
10407
|
}));
|
|
10312
10408
|
|
|
10313
|
-
function deleteSegment(
|
|
10409
|
+
function deleteSegment(_x82) {
|
|
10314
10410
|
return _deleteSegment.apply(this, arguments);
|
|
10315
10411
|
}
|
|
10316
10412
|
|
|
@@ -10327,32 +10423,32 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10327
10423
|
}, {
|
|
10328
10424
|
key: "createCampaign",
|
|
10329
10425
|
value: function () {
|
|
10330
|
-
var _createCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10426
|
+
var _createCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee61(params) {
|
|
10331
10427
|
var _yield$this$post2, campaign;
|
|
10332
10428
|
|
|
10333
|
-
return _regeneratorRuntime.wrap(function
|
|
10429
|
+
return _regeneratorRuntime.wrap(function _callee61$(_context61) {
|
|
10334
10430
|
while (1) {
|
|
10335
|
-
switch (
|
|
10431
|
+
switch (_context61.prev = _context61.next) {
|
|
10336
10432
|
case 0:
|
|
10337
|
-
|
|
10433
|
+
_context61.next = 2;
|
|
10338
10434
|
return this.post(this.baseURL + "/campaigns", {
|
|
10339
10435
|
campaign: params
|
|
10340
10436
|
});
|
|
10341
10437
|
|
|
10342
10438
|
case 2:
|
|
10343
|
-
_yield$this$post2 =
|
|
10439
|
+
_yield$this$post2 = _context61.sent;
|
|
10344
10440
|
campaign = _yield$this$post2.campaign;
|
|
10345
|
-
return
|
|
10441
|
+
return _context61.abrupt("return", campaign);
|
|
10346
10442
|
|
|
10347
10443
|
case 5:
|
|
10348
10444
|
case "end":
|
|
10349
|
-
return
|
|
10445
|
+
return _context61.stop();
|
|
10350
10446
|
}
|
|
10351
10447
|
}
|
|
10352
|
-
},
|
|
10448
|
+
}, _callee61, this);
|
|
10353
10449
|
}));
|
|
10354
10450
|
|
|
10355
|
-
function createCampaign(
|
|
10451
|
+
function createCampaign(_x83) {
|
|
10356
10452
|
return _createCampaign.apply(this, arguments);
|
|
10357
10453
|
}
|
|
10358
10454
|
|
|
@@ -10368,15 +10464,15 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10368
10464
|
}, {
|
|
10369
10465
|
key: "queryCampaigns",
|
|
10370
10466
|
value: function () {
|
|
10371
|
-
var _queryCampaigns = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10467
|
+
var _queryCampaigns = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee62(filters) {
|
|
10372
10468
|
var options,
|
|
10373
|
-
|
|
10374
|
-
return _regeneratorRuntime.wrap(function
|
|
10469
|
+
_args62 = arguments;
|
|
10470
|
+
return _regeneratorRuntime.wrap(function _callee62$(_context62) {
|
|
10375
10471
|
while (1) {
|
|
10376
|
-
switch (
|
|
10472
|
+
switch (_context62.prev = _context62.next) {
|
|
10377
10473
|
case 0:
|
|
10378
|
-
options =
|
|
10379
|
-
|
|
10474
|
+
options = _args62.length > 1 && _args62[1] !== undefined ? _args62[1] : {};
|
|
10475
|
+
_context62.next = 3;
|
|
10380
10476
|
return this.get(this.baseURL + "/campaigns", {
|
|
10381
10477
|
payload: _objectSpread({
|
|
10382
10478
|
filter_conditions: filters
|
|
@@ -10384,17 +10480,17 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10384
10480
|
});
|
|
10385
10481
|
|
|
10386
10482
|
case 3:
|
|
10387
|
-
return
|
|
10483
|
+
return _context62.abrupt("return", _context62.sent);
|
|
10388
10484
|
|
|
10389
10485
|
case 4:
|
|
10390
10486
|
case "end":
|
|
10391
|
-
return
|
|
10487
|
+
return _context62.stop();
|
|
10392
10488
|
}
|
|
10393
10489
|
}
|
|
10394
|
-
},
|
|
10490
|
+
}, _callee62, this);
|
|
10395
10491
|
}));
|
|
10396
10492
|
|
|
10397
|
-
function queryCampaigns(
|
|
10493
|
+
function queryCampaigns(_x84) {
|
|
10398
10494
|
return _queryCampaigns.apply(this, arguments);
|
|
10399
10495
|
}
|
|
10400
10496
|
|
|
@@ -10412,32 +10508,32 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10412
10508
|
}, {
|
|
10413
10509
|
key: "updateCampaign",
|
|
10414
10510
|
value: function () {
|
|
10415
|
-
var _updateCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10511
|
+
var _updateCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee63(id, params) {
|
|
10416
10512
|
var _yield$this$put2, campaign;
|
|
10417
10513
|
|
|
10418
|
-
return _regeneratorRuntime.wrap(function
|
|
10514
|
+
return _regeneratorRuntime.wrap(function _callee63$(_context63) {
|
|
10419
10515
|
while (1) {
|
|
10420
|
-
switch (
|
|
10516
|
+
switch (_context63.prev = _context63.next) {
|
|
10421
10517
|
case 0:
|
|
10422
|
-
|
|
10518
|
+
_context63.next = 2;
|
|
10423
10519
|
return this.put(this.baseURL + "/campaigns/".concat(id), {
|
|
10424
10520
|
campaign: params
|
|
10425
10521
|
});
|
|
10426
10522
|
|
|
10427
10523
|
case 2:
|
|
10428
|
-
_yield$this$put2 =
|
|
10524
|
+
_yield$this$put2 = _context63.sent;
|
|
10429
10525
|
campaign = _yield$this$put2.campaign;
|
|
10430
|
-
return
|
|
10526
|
+
return _context63.abrupt("return", campaign);
|
|
10431
10527
|
|
|
10432
10528
|
case 5:
|
|
10433
10529
|
case "end":
|
|
10434
|
-
return
|
|
10530
|
+
return _context63.stop();
|
|
10435
10531
|
}
|
|
10436
10532
|
}
|
|
10437
|
-
},
|
|
10533
|
+
}, _callee63, this);
|
|
10438
10534
|
}));
|
|
10439
10535
|
|
|
10440
|
-
function updateCampaign(
|
|
10536
|
+
function updateCampaign(_x85, _x86) {
|
|
10441
10537
|
return _updateCampaign.apply(this, arguments);
|
|
10442
10538
|
}
|
|
10443
10539
|
|
|
@@ -10454,25 +10550,25 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10454
10550
|
}, {
|
|
10455
10551
|
key: "deleteCampaign",
|
|
10456
10552
|
value: function () {
|
|
10457
|
-
var _deleteCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10553
|
+
var _deleteCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee64(id) {
|
|
10458
10554
|
var params,
|
|
10459
|
-
|
|
10460
|
-
return _regeneratorRuntime.wrap(function
|
|
10555
|
+
_args64 = arguments;
|
|
10556
|
+
return _regeneratorRuntime.wrap(function _callee64$(_context64) {
|
|
10461
10557
|
while (1) {
|
|
10462
|
-
switch (
|
|
10558
|
+
switch (_context64.prev = _context64.next) {
|
|
10463
10559
|
case 0:
|
|
10464
|
-
params =
|
|
10465
|
-
return
|
|
10560
|
+
params = _args64.length > 1 && _args64[1] !== undefined ? _args64[1] : {};
|
|
10561
|
+
return _context64.abrupt("return", this.delete(this.baseURL + "/campaigns/".concat(id), params));
|
|
10466
10562
|
|
|
10467
10563
|
case 2:
|
|
10468
10564
|
case "end":
|
|
10469
|
-
return
|
|
10565
|
+
return _context64.stop();
|
|
10470
10566
|
}
|
|
10471
10567
|
}
|
|
10472
|
-
},
|
|
10568
|
+
}, _callee64, this);
|
|
10473
10569
|
}));
|
|
10474
10570
|
|
|
10475
|
-
function deleteCampaign(
|
|
10571
|
+
function deleteCampaign(_x87) {
|
|
10476
10572
|
return _deleteCampaign.apply(this, arguments);
|
|
10477
10573
|
}
|
|
10478
10574
|
|
|
@@ -10490,33 +10586,33 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10490
10586
|
}, {
|
|
10491
10587
|
key: "scheduleCampaign",
|
|
10492
10588
|
value: function () {
|
|
10493
|
-
var _scheduleCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10589
|
+
var _scheduleCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee65(id, params) {
|
|
10494
10590
|
var scheduledFor, _yield$this$patch, campaign;
|
|
10495
10591
|
|
|
10496
|
-
return _regeneratorRuntime.wrap(function
|
|
10592
|
+
return _regeneratorRuntime.wrap(function _callee65$(_context65) {
|
|
10497
10593
|
while (1) {
|
|
10498
|
-
switch (
|
|
10594
|
+
switch (_context65.prev = _context65.next) {
|
|
10499
10595
|
case 0:
|
|
10500
10596
|
scheduledFor = params.scheduledFor;
|
|
10501
|
-
|
|
10597
|
+
_context65.next = 3;
|
|
10502
10598
|
return this.patch(this.baseURL + "/campaigns/".concat(id, "/schedule"), {
|
|
10503
10599
|
scheduled_for: scheduledFor
|
|
10504
10600
|
});
|
|
10505
10601
|
|
|
10506
10602
|
case 3:
|
|
10507
|
-
_yield$this$patch =
|
|
10603
|
+
_yield$this$patch = _context65.sent;
|
|
10508
10604
|
campaign = _yield$this$patch.campaign;
|
|
10509
|
-
return
|
|
10605
|
+
return _context65.abrupt("return", campaign);
|
|
10510
10606
|
|
|
10511
10607
|
case 6:
|
|
10512
10608
|
case "end":
|
|
10513
|
-
return
|
|
10609
|
+
return _context65.stop();
|
|
10514
10610
|
}
|
|
10515
10611
|
}
|
|
10516
|
-
},
|
|
10612
|
+
}, _callee65, this);
|
|
10517
10613
|
}));
|
|
10518
10614
|
|
|
10519
|
-
function scheduleCampaign(
|
|
10615
|
+
function scheduleCampaign(_x88, _x89) {
|
|
10520
10616
|
return _scheduleCampaign.apply(this, arguments);
|
|
10521
10617
|
}
|
|
10522
10618
|
|
|
@@ -10533,30 +10629,30 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10533
10629
|
}, {
|
|
10534
10630
|
key: "stopCampaign",
|
|
10535
10631
|
value: function () {
|
|
10536
|
-
var _stopCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10632
|
+
var _stopCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee66(id) {
|
|
10537
10633
|
var _yield$this$patch2, campaign;
|
|
10538
10634
|
|
|
10539
|
-
return _regeneratorRuntime.wrap(function
|
|
10635
|
+
return _regeneratorRuntime.wrap(function _callee66$(_context66) {
|
|
10540
10636
|
while (1) {
|
|
10541
|
-
switch (
|
|
10637
|
+
switch (_context66.prev = _context66.next) {
|
|
10542
10638
|
case 0:
|
|
10543
|
-
|
|
10639
|
+
_context66.next = 2;
|
|
10544
10640
|
return this.patch(this.baseURL + "/campaigns/".concat(id, "/stop"));
|
|
10545
10641
|
|
|
10546
10642
|
case 2:
|
|
10547
|
-
_yield$this$patch2 =
|
|
10643
|
+
_yield$this$patch2 = _context66.sent;
|
|
10548
10644
|
campaign = _yield$this$patch2.campaign;
|
|
10549
|
-
return
|
|
10645
|
+
return _context66.abrupt("return", campaign);
|
|
10550
10646
|
|
|
10551
10647
|
case 5:
|
|
10552
10648
|
case "end":
|
|
10553
|
-
return
|
|
10649
|
+
return _context66.stop();
|
|
10554
10650
|
}
|
|
10555
10651
|
}
|
|
10556
|
-
},
|
|
10652
|
+
}, _callee66, this);
|
|
10557
10653
|
}));
|
|
10558
10654
|
|
|
10559
|
-
function stopCampaign(
|
|
10655
|
+
function stopCampaign(_x90) {
|
|
10560
10656
|
return _stopCampaign.apply(this, arguments);
|
|
10561
10657
|
}
|
|
10562
10658
|
|
|
@@ -10573,30 +10669,30 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10573
10669
|
}, {
|
|
10574
10670
|
key: "resumeCampaign",
|
|
10575
10671
|
value: function () {
|
|
10576
|
-
var _resumeCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10672
|
+
var _resumeCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee67(id) {
|
|
10577
10673
|
var _yield$this$patch3, campaign;
|
|
10578
10674
|
|
|
10579
|
-
return _regeneratorRuntime.wrap(function
|
|
10675
|
+
return _regeneratorRuntime.wrap(function _callee67$(_context67) {
|
|
10580
10676
|
while (1) {
|
|
10581
|
-
switch (
|
|
10677
|
+
switch (_context67.prev = _context67.next) {
|
|
10582
10678
|
case 0:
|
|
10583
|
-
|
|
10679
|
+
_context67.next = 2;
|
|
10584
10680
|
return this.patch(this.baseURL + "/campaigns/".concat(id, "/resume"));
|
|
10585
10681
|
|
|
10586
10682
|
case 2:
|
|
10587
|
-
_yield$this$patch3 =
|
|
10683
|
+
_yield$this$patch3 = _context67.sent;
|
|
10588
10684
|
campaign = _yield$this$patch3.campaign;
|
|
10589
|
-
return
|
|
10685
|
+
return _context67.abrupt("return", campaign);
|
|
10590
10686
|
|
|
10591
10687
|
case 5:
|
|
10592
10688
|
case "end":
|
|
10593
|
-
return
|
|
10689
|
+
return _context67.stop();
|
|
10594
10690
|
}
|
|
10595
10691
|
}
|
|
10596
|
-
},
|
|
10692
|
+
}, _callee67, this);
|
|
10597
10693
|
}));
|
|
10598
10694
|
|
|
10599
|
-
function resumeCampaign(
|
|
10695
|
+
function resumeCampaign(_x91) {
|
|
10600
10696
|
return _resumeCampaign.apply(this, arguments);
|
|
10601
10697
|
}
|
|
10602
10698
|
|
|
@@ -10614,30 +10710,30 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10614
10710
|
}, {
|
|
10615
10711
|
key: "testCampaign",
|
|
10616
10712
|
value: function () {
|
|
10617
|
-
var _testCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10713
|
+
var _testCampaign = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee68(id, params) {
|
|
10618
10714
|
var users;
|
|
10619
|
-
return _regeneratorRuntime.wrap(function
|
|
10715
|
+
return _regeneratorRuntime.wrap(function _callee68$(_context68) {
|
|
10620
10716
|
while (1) {
|
|
10621
|
-
switch (
|
|
10717
|
+
switch (_context68.prev = _context68.next) {
|
|
10622
10718
|
case 0:
|
|
10623
10719
|
users = params.users;
|
|
10624
|
-
|
|
10720
|
+
_context68.next = 3;
|
|
10625
10721
|
return this.post(this.baseURL + "/campaigns/".concat(id, "/test"), {
|
|
10626
10722
|
users: users
|
|
10627
10723
|
});
|
|
10628
10724
|
|
|
10629
10725
|
case 3:
|
|
10630
|
-
return
|
|
10726
|
+
return _context68.abrupt("return", _context68.sent);
|
|
10631
10727
|
|
|
10632
10728
|
case 4:
|
|
10633
10729
|
case "end":
|
|
10634
|
-
return
|
|
10730
|
+
return _context68.stop();
|
|
10635
10731
|
}
|
|
10636
10732
|
}
|
|
10637
|
-
},
|
|
10733
|
+
}, _callee68, this);
|
|
10638
10734
|
}));
|
|
10639
10735
|
|
|
10640
|
-
function testCampaign(
|
|
10736
|
+
function testCampaign(_x92, _x93) {
|
|
10641
10737
|
return _testCampaign.apply(this, arguments);
|
|
10642
10738
|
}
|
|
10643
10739
|
|
|
@@ -10653,15 +10749,15 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10653
10749
|
}, {
|
|
10654
10750
|
key: "queryRecipients",
|
|
10655
10751
|
value: function () {
|
|
10656
|
-
var _queryRecipients = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10752
|
+
var _queryRecipients = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee69(filters) {
|
|
10657
10753
|
var options,
|
|
10658
|
-
|
|
10659
|
-
return _regeneratorRuntime.wrap(function
|
|
10754
|
+
_args69 = arguments;
|
|
10755
|
+
return _regeneratorRuntime.wrap(function _callee69$(_context69) {
|
|
10660
10756
|
while (1) {
|
|
10661
|
-
switch (
|
|
10757
|
+
switch (_context69.prev = _context69.next) {
|
|
10662
10758
|
case 0:
|
|
10663
|
-
options =
|
|
10664
|
-
|
|
10759
|
+
options = _args69.length > 1 && _args69[1] !== undefined ? _args69[1] : {};
|
|
10760
|
+
_context69.next = 3;
|
|
10665
10761
|
return this.get(this.baseURL + "/recipients", {
|
|
10666
10762
|
payload: _objectSpread({
|
|
10667
10763
|
filter_conditions: filters
|
|
@@ -10669,17 +10765,17 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10669
10765
|
});
|
|
10670
10766
|
|
|
10671
10767
|
case 3:
|
|
10672
|
-
return
|
|
10768
|
+
return _context69.abrupt("return", _context69.sent);
|
|
10673
10769
|
|
|
10674
10770
|
case 4:
|
|
10675
10771
|
case "end":
|
|
10676
|
-
return
|
|
10772
|
+
return _context69.stop();
|
|
10677
10773
|
}
|
|
10678
10774
|
}
|
|
10679
|
-
},
|
|
10775
|
+
}, _callee69, this);
|
|
10680
10776
|
}));
|
|
10681
10777
|
|
|
10682
|
-
function queryRecipients(
|
|
10778
|
+
function queryRecipients(_x94) {
|
|
10683
10779
|
return _queryRecipients.apply(this, arguments);
|
|
10684
10780
|
}
|
|
10685
10781
|
|
|
@@ -10695,24 +10791,24 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10695
10791
|
}, {
|
|
10696
10792
|
key: "enrichURL",
|
|
10697
10793
|
value: function () {
|
|
10698
|
-
var _enrichURL = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10699
|
-
return _regeneratorRuntime.wrap(function
|
|
10794
|
+
var _enrichURL = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee70(url) {
|
|
10795
|
+
return _regeneratorRuntime.wrap(function _callee70$(_context70) {
|
|
10700
10796
|
while (1) {
|
|
10701
|
-
switch (
|
|
10797
|
+
switch (_context70.prev = _context70.next) {
|
|
10702
10798
|
case 0:
|
|
10703
|
-
return
|
|
10799
|
+
return _context70.abrupt("return", this.get(this.baseURL + "/og", {
|
|
10704
10800
|
url: url
|
|
10705
10801
|
}));
|
|
10706
10802
|
|
|
10707
10803
|
case 1:
|
|
10708
10804
|
case "end":
|
|
10709
|
-
return
|
|
10805
|
+
return _context70.stop();
|
|
10710
10806
|
}
|
|
10711
10807
|
}
|
|
10712
|
-
},
|
|
10808
|
+
}, _callee70, this);
|
|
10713
10809
|
}));
|
|
10714
10810
|
|
|
10715
|
-
function enrichURL(
|
|
10811
|
+
function enrichURL(_x95) {
|
|
10716
10812
|
return _enrichURL.apply(this, arguments);
|
|
10717
10813
|
}
|
|
10718
10814
|
|
|
@@ -10729,22 +10825,22 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10729
10825
|
}, {
|
|
10730
10826
|
key: "getTask",
|
|
10731
10827
|
value: function () {
|
|
10732
|
-
var _getTask = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10733
|
-
return _regeneratorRuntime.wrap(function
|
|
10828
|
+
var _getTask = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee71(id) {
|
|
10829
|
+
return _regeneratorRuntime.wrap(function _callee71$(_context71) {
|
|
10734
10830
|
while (1) {
|
|
10735
|
-
switch (
|
|
10831
|
+
switch (_context71.prev = _context71.next) {
|
|
10736
10832
|
case 0:
|
|
10737
|
-
return
|
|
10833
|
+
return _context71.abrupt("return", this.get("".concat(this.baseURL, "/tasks/").concat(id)));
|
|
10738
10834
|
|
|
10739
10835
|
case 1:
|
|
10740
10836
|
case "end":
|
|
10741
|
-
return
|
|
10837
|
+
return _context71.stop();
|
|
10742
10838
|
}
|
|
10743
10839
|
}
|
|
10744
|
-
},
|
|
10840
|
+
}, _callee71, this);
|
|
10745
10841
|
}));
|
|
10746
10842
|
|
|
10747
|
-
function getTask(
|
|
10843
|
+
function getTask(_x96) {
|
|
10748
10844
|
return _getTask.apply(this, arguments);
|
|
10749
10845
|
}
|
|
10750
10846
|
|
|
@@ -10762,31 +10858,31 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10762
10858
|
}, {
|
|
10763
10859
|
key: "deleteChannels",
|
|
10764
10860
|
value: function () {
|
|
10765
|
-
var _deleteChannels = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10861
|
+
var _deleteChannels = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee72(cids) {
|
|
10766
10862
|
var options,
|
|
10767
|
-
|
|
10768
|
-
return _regeneratorRuntime.wrap(function
|
|
10863
|
+
_args72 = arguments;
|
|
10864
|
+
return _regeneratorRuntime.wrap(function _callee72$(_context72) {
|
|
10769
10865
|
while (1) {
|
|
10770
|
-
switch (
|
|
10866
|
+
switch (_context72.prev = _context72.next) {
|
|
10771
10867
|
case 0:
|
|
10772
|
-
options =
|
|
10773
|
-
|
|
10868
|
+
options = _args72.length > 1 && _args72[1] !== undefined ? _args72[1] : {};
|
|
10869
|
+
_context72.next = 3;
|
|
10774
10870
|
return this.post(this.baseURL + "/channels/delete", _objectSpread({
|
|
10775
10871
|
cids: cids
|
|
10776
10872
|
}, options));
|
|
10777
10873
|
|
|
10778
10874
|
case 3:
|
|
10779
|
-
return
|
|
10875
|
+
return _context72.abrupt("return", _context72.sent);
|
|
10780
10876
|
|
|
10781
10877
|
case 4:
|
|
10782
10878
|
case "end":
|
|
10783
|
-
return
|
|
10879
|
+
return _context72.stop();
|
|
10784
10880
|
}
|
|
10785
10881
|
}
|
|
10786
|
-
},
|
|
10882
|
+
}, _callee72, this);
|
|
10787
10883
|
}));
|
|
10788
10884
|
|
|
10789
|
-
function deleteChannels(
|
|
10885
|
+
function deleteChannels(_x97) {
|
|
10790
10886
|
return _deleteChannels.apply(this, arguments);
|
|
10791
10887
|
}
|
|
10792
10888
|
|
|
@@ -10798,19 +10894,19 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10798
10894
|
* @param {string[]} user_ids which users to delete
|
|
10799
10895
|
* @param {DeleteUserOptions} options Configuration how to delete users
|
|
10800
10896
|
*
|
|
10801
|
-
* @return {
|
|
10897
|
+
* @return {TaskResponse} A task ID
|
|
10802
10898
|
*/
|
|
10803
10899
|
|
|
10804
10900
|
}, {
|
|
10805
10901
|
key: "deleteUsers",
|
|
10806
10902
|
value: function () {
|
|
10807
|
-
var _deleteUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10808
|
-
return _regeneratorRuntime.wrap(function
|
|
10903
|
+
var _deleteUsers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee73(user_ids, options) {
|
|
10904
|
+
return _regeneratorRuntime.wrap(function _callee73$(_context73) {
|
|
10809
10905
|
while (1) {
|
|
10810
|
-
switch (
|
|
10906
|
+
switch (_context73.prev = _context73.next) {
|
|
10811
10907
|
case 0:
|
|
10812
10908
|
if (!((options === null || options === void 0 ? void 0 : options.user) !== 'soft' && (options === null || options === void 0 ? void 0 : options.user) !== 'hard')) {
|
|
10813
|
-
|
|
10909
|
+
_context73.next = 2;
|
|
10814
10910
|
break;
|
|
10815
10911
|
}
|
|
10816
10912
|
|
|
@@ -10818,7 +10914,7 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10818
10914
|
|
|
10819
10915
|
case 2:
|
|
10820
10916
|
if (!(options.messages !== undefined && options.messages !== 'soft' && options.messages !== 'hard')) {
|
|
10821
|
-
|
|
10917
|
+
_context73.next = 4;
|
|
10822
10918
|
break;
|
|
10823
10919
|
}
|
|
10824
10920
|
|
|
@@ -10826,30 +10922,30 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10826
10922
|
|
|
10827
10923
|
case 4:
|
|
10828
10924
|
if (!(options.conversations !== undefined && options.conversations !== 'soft' && options.conversations !== 'hard')) {
|
|
10829
|
-
|
|
10925
|
+
_context73.next = 6;
|
|
10830
10926
|
break;
|
|
10831
10927
|
}
|
|
10832
10928
|
|
|
10833
10929
|
throw new Error('Invalid delete user options. conversations must be one of [soft hard]');
|
|
10834
10930
|
|
|
10835
10931
|
case 6:
|
|
10836
|
-
|
|
10932
|
+
_context73.next = 8;
|
|
10837
10933
|
return this.post(this.baseURL + "/users/delete", _objectSpread({
|
|
10838
10934
|
user_ids: user_ids
|
|
10839
10935
|
}, options));
|
|
10840
10936
|
|
|
10841
10937
|
case 8:
|
|
10842
|
-
return
|
|
10938
|
+
return _context73.abrupt("return", _context73.sent);
|
|
10843
10939
|
|
|
10844
10940
|
case 9:
|
|
10845
10941
|
case "end":
|
|
10846
|
-
return
|
|
10942
|
+
return _context73.stop();
|
|
10847
10943
|
}
|
|
10848
10944
|
}
|
|
10849
|
-
},
|
|
10945
|
+
}, _callee73, this);
|
|
10850
10946
|
}));
|
|
10851
10947
|
|
|
10852
|
-
function deleteUsers(
|
|
10948
|
+
function deleteUsers(_x98, _x99) {
|
|
10853
10949
|
return _deleteUsers.apply(this, arguments);
|
|
10854
10950
|
}
|
|
10855
10951
|
|
|
@@ -10870,28 +10966,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10870
10966
|
}, {
|
|
10871
10967
|
key: "_createImportURL",
|
|
10872
10968
|
value: function () {
|
|
10873
|
-
var _createImportURL2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10874
|
-
return _regeneratorRuntime.wrap(function
|
|
10969
|
+
var _createImportURL2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee74(filename) {
|
|
10970
|
+
return _regeneratorRuntime.wrap(function _callee74$(_context74) {
|
|
10875
10971
|
while (1) {
|
|
10876
|
-
switch (
|
|
10972
|
+
switch (_context74.prev = _context74.next) {
|
|
10877
10973
|
case 0:
|
|
10878
|
-
|
|
10974
|
+
_context74.next = 2;
|
|
10879
10975
|
return this.post(this.baseURL + "/import_urls", {
|
|
10880
10976
|
filename: filename
|
|
10881
10977
|
});
|
|
10882
10978
|
|
|
10883
10979
|
case 2:
|
|
10884
|
-
return
|
|
10980
|
+
return _context74.abrupt("return", _context74.sent);
|
|
10885
10981
|
|
|
10886
10982
|
case 3:
|
|
10887
10983
|
case "end":
|
|
10888
|
-
return
|
|
10984
|
+
return _context74.stop();
|
|
10889
10985
|
}
|
|
10890
10986
|
}
|
|
10891
|
-
},
|
|
10987
|
+
}, _callee74, this);
|
|
10892
10988
|
}));
|
|
10893
10989
|
|
|
10894
|
-
function _createImportURL(
|
|
10990
|
+
function _createImportURL(_x100) {
|
|
10895
10991
|
return _createImportURL2.apply(this, arguments);
|
|
10896
10992
|
}
|
|
10897
10993
|
|
|
@@ -10913,33 +11009,33 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10913
11009
|
}, {
|
|
10914
11010
|
key: "_createImport",
|
|
10915
11011
|
value: function () {
|
|
10916
|
-
var _createImport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11012
|
+
var _createImport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee75(path) {
|
|
10917
11013
|
var options,
|
|
10918
|
-
|
|
10919
|
-
return _regeneratorRuntime.wrap(function
|
|
11014
|
+
_args75 = arguments;
|
|
11015
|
+
return _regeneratorRuntime.wrap(function _callee75$(_context75) {
|
|
10920
11016
|
while (1) {
|
|
10921
|
-
switch (
|
|
11017
|
+
switch (_context75.prev = _context75.next) {
|
|
10922
11018
|
case 0:
|
|
10923
|
-
options =
|
|
11019
|
+
options = _args75.length > 1 && _args75[1] !== undefined ? _args75[1] : {
|
|
10924
11020
|
mode: 'upsert'
|
|
10925
11021
|
};
|
|
10926
|
-
|
|
11022
|
+
_context75.next = 3;
|
|
10927
11023
|
return this.post(this.baseURL + "/imports", _objectSpread({
|
|
10928
11024
|
path: path
|
|
10929
11025
|
}, options));
|
|
10930
11026
|
|
|
10931
11027
|
case 3:
|
|
10932
|
-
return
|
|
11028
|
+
return _context75.abrupt("return", _context75.sent);
|
|
10933
11029
|
|
|
10934
11030
|
case 4:
|
|
10935
11031
|
case "end":
|
|
10936
|
-
return
|
|
11032
|
+
return _context75.stop();
|
|
10937
11033
|
}
|
|
10938
11034
|
}
|
|
10939
|
-
},
|
|
11035
|
+
}, _callee75, this);
|
|
10940
11036
|
}));
|
|
10941
11037
|
|
|
10942
|
-
function _createImport(
|
|
11038
|
+
function _createImport(_x101) {
|
|
10943
11039
|
return _createImport2.apply(this, arguments);
|
|
10944
11040
|
}
|
|
10945
11041
|
|
|
@@ -10961,26 +11057,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
10961
11057
|
}, {
|
|
10962
11058
|
key: "_getImport",
|
|
10963
11059
|
value: function () {
|
|
10964
|
-
var _getImport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
10965
|
-
return _regeneratorRuntime.wrap(function
|
|
11060
|
+
var _getImport2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee76(id) {
|
|
11061
|
+
return _regeneratorRuntime.wrap(function _callee76$(_context76) {
|
|
10966
11062
|
while (1) {
|
|
10967
|
-
switch (
|
|
11063
|
+
switch (_context76.prev = _context76.next) {
|
|
10968
11064
|
case 0:
|
|
10969
|
-
|
|
11065
|
+
_context76.next = 2;
|
|
10970
11066
|
return this.get(this.baseURL + "/imports/".concat(id));
|
|
10971
11067
|
|
|
10972
11068
|
case 2:
|
|
10973
|
-
return
|
|
11069
|
+
return _context76.abrupt("return", _context76.sent);
|
|
10974
11070
|
|
|
10975
11071
|
case 3:
|
|
10976
11072
|
case "end":
|
|
10977
|
-
return
|
|
11073
|
+
return _context76.stop();
|
|
10978
11074
|
}
|
|
10979
11075
|
}
|
|
10980
|
-
},
|
|
11076
|
+
}, _callee76, this);
|
|
10981
11077
|
}));
|
|
10982
11078
|
|
|
10983
|
-
function _getImport(
|
|
11079
|
+
function _getImport(_x102) {
|
|
10984
11080
|
return _getImport2.apply(this, arguments);
|
|
10985
11081
|
}
|
|
10986
11082
|
|
|
@@ -11002,26 +11098,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11002
11098
|
}, {
|
|
11003
11099
|
key: "_listImports",
|
|
11004
11100
|
value: function () {
|
|
11005
|
-
var _listImports2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11006
|
-
return _regeneratorRuntime.wrap(function
|
|
11101
|
+
var _listImports2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee77(options) {
|
|
11102
|
+
return _regeneratorRuntime.wrap(function _callee77$(_context77) {
|
|
11007
11103
|
while (1) {
|
|
11008
|
-
switch (
|
|
11104
|
+
switch (_context77.prev = _context77.next) {
|
|
11009
11105
|
case 0:
|
|
11010
|
-
|
|
11106
|
+
_context77.next = 2;
|
|
11011
11107
|
return this.get(this.baseURL + "/imports", options);
|
|
11012
11108
|
|
|
11013
11109
|
case 2:
|
|
11014
|
-
return
|
|
11110
|
+
return _context77.abrupt("return", _context77.sent);
|
|
11015
11111
|
|
|
11016
11112
|
case 3:
|
|
11017
11113
|
case "end":
|
|
11018
|
-
return
|
|
11114
|
+
return _context77.stop();
|
|
11019
11115
|
}
|
|
11020
11116
|
}
|
|
11021
|
-
},
|
|
11117
|
+
}, _callee77, this);
|
|
11022
11118
|
}));
|
|
11023
11119
|
|
|
11024
|
-
function _listImports(
|
|
11120
|
+
function _listImports(_x103) {
|
|
11025
11121
|
return _listImports2.apply(this, arguments);
|
|
11026
11122
|
}
|
|
11027
11123
|
|
|
@@ -11040,28 +11136,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11040
11136
|
}, {
|
|
11041
11137
|
key: "upsertPushProvider",
|
|
11042
11138
|
value: function () {
|
|
11043
|
-
var _upsertPushProvider = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11044
|
-
return _regeneratorRuntime.wrap(function
|
|
11139
|
+
var _upsertPushProvider = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee78(pushProvider) {
|
|
11140
|
+
return _regeneratorRuntime.wrap(function _callee78$(_context78) {
|
|
11045
11141
|
while (1) {
|
|
11046
|
-
switch (
|
|
11142
|
+
switch (_context78.prev = _context78.next) {
|
|
11047
11143
|
case 0:
|
|
11048
|
-
|
|
11144
|
+
_context78.next = 2;
|
|
11049
11145
|
return this.post(this.baseURL + "/push_providers", {
|
|
11050
11146
|
push_provider: pushProvider
|
|
11051
11147
|
});
|
|
11052
11148
|
|
|
11053
11149
|
case 2:
|
|
11054
|
-
return
|
|
11150
|
+
return _context78.abrupt("return", _context78.sent);
|
|
11055
11151
|
|
|
11056
11152
|
case 3:
|
|
11057
11153
|
case "end":
|
|
11058
|
-
return
|
|
11154
|
+
return _context78.stop();
|
|
11059
11155
|
}
|
|
11060
11156
|
}
|
|
11061
|
-
},
|
|
11157
|
+
}, _callee78, this);
|
|
11062
11158
|
}));
|
|
11063
11159
|
|
|
11064
|
-
function upsertPushProvider(
|
|
11160
|
+
function upsertPushProvider(_x104) {
|
|
11065
11161
|
return _upsertPushProvider.apply(this, arguments);
|
|
11066
11162
|
}
|
|
11067
11163
|
|
|
@@ -11080,28 +11176,28 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11080
11176
|
}, {
|
|
11081
11177
|
key: "deletePushProvider",
|
|
11082
11178
|
value: function () {
|
|
11083
|
-
var _deletePushProvider = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11179
|
+
var _deletePushProvider = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee79(_ref9) {
|
|
11084
11180
|
var type, name;
|
|
11085
|
-
return _regeneratorRuntime.wrap(function
|
|
11181
|
+
return _regeneratorRuntime.wrap(function _callee79$(_context79) {
|
|
11086
11182
|
while (1) {
|
|
11087
|
-
switch (
|
|
11183
|
+
switch (_context79.prev = _context79.next) {
|
|
11088
11184
|
case 0:
|
|
11089
11185
|
type = _ref9.type, name = _ref9.name;
|
|
11090
|
-
|
|
11186
|
+
_context79.next = 3;
|
|
11091
11187
|
return this.delete(this.baseURL + "/push_providers/".concat(type, "/").concat(name));
|
|
11092
11188
|
|
|
11093
11189
|
case 3:
|
|
11094
|
-
return
|
|
11190
|
+
return _context79.abrupt("return", _context79.sent);
|
|
11095
11191
|
|
|
11096
11192
|
case 4:
|
|
11097
11193
|
case "end":
|
|
11098
|
-
return
|
|
11194
|
+
return _context79.stop();
|
|
11099
11195
|
}
|
|
11100
11196
|
}
|
|
11101
|
-
},
|
|
11197
|
+
}, _callee79, this);
|
|
11102
11198
|
}));
|
|
11103
11199
|
|
|
11104
|
-
function deletePushProvider(
|
|
11200
|
+
function deletePushProvider(_x105) {
|
|
11105
11201
|
return _deletePushProvider.apply(this, arguments);
|
|
11106
11202
|
}
|
|
11107
11203
|
|
|
@@ -11118,23 +11214,23 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11118
11214
|
}, {
|
|
11119
11215
|
key: "listPushProviders",
|
|
11120
11216
|
value: function () {
|
|
11121
|
-
var _listPushProviders = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11122
|
-
return _regeneratorRuntime.wrap(function
|
|
11217
|
+
var _listPushProviders = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee80() {
|
|
11218
|
+
return _regeneratorRuntime.wrap(function _callee80$(_context80) {
|
|
11123
11219
|
while (1) {
|
|
11124
|
-
switch (
|
|
11220
|
+
switch (_context80.prev = _context80.next) {
|
|
11125
11221
|
case 0:
|
|
11126
|
-
|
|
11222
|
+
_context80.next = 2;
|
|
11127
11223
|
return this.get(this.baseURL + "/push_providers");
|
|
11128
11224
|
|
|
11129
11225
|
case 2:
|
|
11130
|
-
return
|
|
11226
|
+
return _context80.abrupt("return", _context80.sent);
|
|
11131
11227
|
|
|
11132
11228
|
case 3:
|
|
11133
11229
|
case "end":
|
|
11134
|
-
return
|
|
11230
|
+
return _context80.stop();
|
|
11135
11231
|
}
|
|
11136
11232
|
}
|
|
11137
|
-
},
|
|
11233
|
+
}, _callee80, this);
|
|
11138
11234
|
}));
|
|
11139
11235
|
|
|
11140
11236
|
function listPushProviders() {
|
|
@@ -11162,26 +11258,26 @@ var StreamChat = /*#__PURE__*/function () {
|
|
|
11162
11258
|
}, {
|
|
11163
11259
|
key: "commitMessage",
|
|
11164
11260
|
value: function () {
|
|
11165
|
-
var _commitMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
11166
|
-
return _regeneratorRuntime.wrap(function
|
|
11261
|
+
var _commitMessage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee81(id) {
|
|
11262
|
+
return _regeneratorRuntime.wrap(function _callee81$(_context81) {
|
|
11167
11263
|
while (1) {
|
|
11168
|
-
switch (
|
|
11264
|
+
switch (_context81.prev = _context81.next) {
|
|
11169
11265
|
case 0:
|
|
11170
|
-
|
|
11266
|
+
_context81.next = 2;
|
|
11171
11267
|
return this.post(this.baseURL + "/messages/".concat(id, "/commit"));
|
|
11172
11268
|
|
|
11173
11269
|
case 2:
|
|
11174
|
-
return
|
|
11270
|
+
return _context81.abrupt("return", _context81.sent);
|
|
11175
11271
|
|
|
11176
11272
|
case 3:
|
|
11177
11273
|
case "end":
|
|
11178
|
-
return
|
|
11274
|
+
return _context81.stop();
|
|
11179
11275
|
}
|
|
11180
11276
|
}
|
|
11181
|
-
},
|
|
11277
|
+
}, _callee81, this);
|
|
11182
11278
|
}));
|
|
11183
11279
|
|
|
11184
|
-
function commitMessage(
|
|
11280
|
+
function commitMessage(_x106) {
|
|
11185
11281
|
return _commitMessage.apply(this, arguments);
|
|
11186
11282
|
}
|
|
11187
11283
|
|