@stream-io/video-client 0.0.2-alpha.2 → 0.0.2-alpha.3

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/index.cjs.js CHANGED
@@ -8586,7 +8586,6 @@ class Call {
8586
8586
  * @param data the request data.
8587
8587
  */
8588
8588
  this.updateCallMembers = (data) => __awaiter(this, void 0, void 0, function* () {
8589
- // FIXME: OL: implement kick-users
8590
8589
  return this.streamClient.post(`${this.streamClientBasePath}/members`, data);
8591
8590
  });
8592
8591
  /**
@@ -9095,13 +9094,20 @@ class Call {
9095
9094
  });
9096
9095
  };
9097
9096
  /**
9098
- * Performs HTTP request to retrieve the list of recordings for the current call
9099
- * Updates the call state with provided array of CallRecording objects
9097
+ * Retrieves the list of recordings for the current call or call session.
9098
+ * Updates the call state with the returned array of CallRecording objects.
9099
+ *
9100
+ * If `callSessionId` is provided, it will return the recordings for that call session.
9101
+ * Otherwise, all recordings for the current call will be returned.
9102
+ *
9103
+ * @param callSessionId the call session id to retrieve recordings for.
9100
9104
  */
9101
- this.queryRecordings = () => __awaiter(this, void 0, void 0, function* () {
9102
- // FIXME: this is a temporary setting to take call ID as session ID
9103
- const sessionId = this.id;
9104
- const response = yield this.streamClient.get(`${this.streamClientBasePath}/${sessionId}/recordings`);
9105
+ this.queryRecordings = (callSessionId) => __awaiter(this, void 0, void 0, function* () {
9106
+ let endpoint = this.streamClientBasePath;
9107
+ if (callSessionId) {
9108
+ endpoint = `${endpoint}/${callSessionId}`;
9109
+ }
9110
+ const response = yield this.streamClient.get(`${endpoint}/recordings`);
9105
9111
  this.state.setCallRecordingsList(response.recordings);
9106
9112
  return response;
9107
9113
  });
@@ -10875,7 +10881,7 @@ class StreamClient {
10875
10881
  }
10876
10882
  getUserAgent() {
10877
10883
  return (this.userAgent ||
10878
- `stream-video-javascript-client-${this.node ? 'node' : 'browser'}-${"0.0.2-alpha.1"}`);
10884
+ `stream-video-javascript-client-${this.node ? 'node' : 'browser'}-${"0.0.2-alpha.2"}`);
10879
10885
  }
10880
10886
  setUserAgent(userAgent) {
10881
10887
  this.userAgent = userAgent;