@stream-io/feeds-client 0.2.14 → 0.2.16
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/CHANGELOG.md +14 -0
- package/dist/cjs/index.js +1 -1
- package/dist/cjs/react-bindings.js +2 -2
- package/dist/cjs/react-bindings.js.map +1 -1
- package/dist/es/index.mjs +2 -2
- package/dist/es/react-bindings.mjs +2 -2
- package/dist/es/react-bindings.mjs.map +1 -1
- package/dist/{index-B08vVRSZ.js → index-CaFrpjpl.js} +27 -6
- package/dist/index-CaFrpjpl.js.map +1 -0
- package/dist/{index-B3HHiF9S.mjs → index-J3MkoYPN.mjs} +27 -6
- package/dist/index-J3MkoYPN.mjs.map +1 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/types/feeds-client/feeds-client.d.ts +6 -0
- package/dist/types/feeds-client/feeds-client.d.ts.map +1 -1
- package/dist/types/gen/feeds/FeedsApi.d.ts +5 -2
- package/dist/types/gen/feeds/FeedsApi.d.ts.map +1 -1
- package/dist/types/gen/models/index.d.ts +7 -0
- package/dist/types/gen/models/index.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/bindings/react/hooks/util/useReactionActions.ts +1 -1
- package/src/feeds-client/feeds-client.ts +15 -7
- package/src/gen/feeds/FeedsApi.ts +30 -2
- package/src/gen/models/index.ts +10 -0
- package/dist/index-B08vVRSZ.js.map +0 -1
- package/dist/index-B3HHiF9S.mjs.map +0 -1
|
@@ -1770,7 +1770,7 @@ class FeedsApi {
|
|
|
1770
1770
|
decoders.PollVoteResponse?.(response.body);
|
|
1771
1771
|
return { ...response.body, metadata: response.metadata };
|
|
1772
1772
|
}
|
|
1773
|
-
async
|
|
1773
|
+
async addActivityReaction(request) {
|
|
1774
1774
|
const pathParams = {
|
|
1775
1775
|
activity_id: request?.activity_id
|
|
1776
1776
|
};
|
|
@@ -1980,9 +1980,9 @@ class FeedsApi {
|
|
|
1980
1980
|
}
|
|
1981
1981
|
async addComment(request) {
|
|
1982
1982
|
const body = {
|
|
1983
|
-
comment: request?.comment,
|
|
1984
1983
|
object_id: request?.object_id,
|
|
1985
1984
|
object_type: request?.object_type,
|
|
1985
|
+
comment: request?.comment,
|
|
1986
1986
|
create_notification_activity: request?.create_notification_activity,
|
|
1987
1987
|
parent_id: request?.parent_id,
|
|
1988
1988
|
skip_push: request?.skip_push,
|
|
@@ -2402,6 +2402,24 @@ class FeedsApi {
|
|
|
2402
2402
|
decoders.CreateFeedsBatchResponse?.(response.body);
|
|
2403
2403
|
return { ...response.body, metadata: response.metadata };
|
|
2404
2404
|
}
|
|
2405
|
+
async ownCapabilitiesBatch(request) {
|
|
2406
|
+
const queryParams = {
|
|
2407
|
+
connection_id: request?.connection_id
|
|
2408
|
+
};
|
|
2409
|
+
const body = {
|
|
2410
|
+
feeds: request?.feeds
|
|
2411
|
+
};
|
|
2412
|
+
const response = await this.apiClient.sendRequest(
|
|
2413
|
+
"POST",
|
|
2414
|
+
"/api/v2/feeds/feeds/own_capabilities/batch",
|
|
2415
|
+
void 0,
|
|
2416
|
+
queryParams,
|
|
2417
|
+
body,
|
|
2418
|
+
"application/json"
|
|
2419
|
+
);
|
|
2420
|
+
decoders.OwnCapabilitiesBatchResponse?.(response.body);
|
|
2421
|
+
return { ...response.body, metadata: response.metadata };
|
|
2422
|
+
}
|
|
2405
2423
|
async _queryFeeds(request) {
|
|
2406
2424
|
const queryParams = {
|
|
2407
2425
|
connection_id: request?.connection_id
|
|
@@ -3722,7 +3740,7 @@ const getRateLimitFromResponseHeader = (response_headers) => {
|
|
|
3722
3740
|
};
|
|
3723
3741
|
return result;
|
|
3724
3742
|
};
|
|
3725
|
-
const version = "0.2.
|
|
3743
|
+
const version = "0.2.16";
|
|
3726
3744
|
class ApiClient {
|
|
3727
3745
|
constructor(apiKey, tokenManager, connectionIdManager, options) {
|
|
3728
3746
|
this.apiKey = apiKey;
|
|
@@ -6474,13 +6492,16 @@ class FeedsClient extends FeedsApi {
|
|
|
6474
6492
|
}
|
|
6475
6493
|
return response;
|
|
6476
6494
|
};
|
|
6477
|
-
this.
|
|
6478
|
-
const response = await super.
|
|
6495
|
+
this.addActivityReaction = async (request) => {
|
|
6496
|
+
const response = await super.addActivityReaction(request);
|
|
6479
6497
|
for (const feed of Object.values(this.activeFeeds)) {
|
|
6480
6498
|
handleActivityReactionAdded.bind(feed)(response, false);
|
|
6481
6499
|
}
|
|
6482
6500
|
return response;
|
|
6483
6501
|
};
|
|
6502
|
+
this.addReaction = (request) => {
|
|
6503
|
+
return this.addActivityReaction(request);
|
|
6504
|
+
};
|
|
6484
6505
|
this.deleteActivityReaction = async (request) => {
|
|
6485
6506
|
const response = await super.deleteActivityReaction(request);
|
|
6486
6507
|
for (const feed of Object.values(this.activeFeeds)) {
|
|
@@ -6859,4 +6880,4 @@ exports.replaceUniqueArrayMerge = replaceUniqueArrayMerge;
|
|
|
6859
6880
|
exports.shouldUpdateState = shouldUpdateState;
|
|
6860
6881
|
exports.uniqueArrayMerge = uniqueArrayMerge;
|
|
6861
6882
|
exports.updateEntityInArray = updateEntityInArray;
|
|
6862
|
-
//# sourceMappingURL=index-
|
|
6883
|
+
//# sourceMappingURL=index-CaFrpjpl.js.map
|