Skip to content

Commit f074e50

Browse files
jocarinojoaojoaocoform
authored
[Components] zoom_admin - fix to get-meeting-recordings (#16940)
* fix: pagination prop and params struct * fix: no need for paginate here * chore: update version * chore: cleanup * chore: update package --------- Co-authored-by: joao <[email protected]> Co-authored-by: joaocoform <[email protected]>
1 parent 06e4dba commit f074e50

File tree

2 files changed

+20
-11
lines changed

2 files changed

+20
-11
lines changed

components/zoom_admin/actions/get-meeting-recordings/get-meeting-recordings.mjs

Lines changed: 19 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
import get from "lodash/get.js";
2-
import { paginate } from "../../common/pagination.mjs";
32
import zoomAdmin from "../../zoom_admin.app.mjs";
43

54
export default {
65
name: "Get meeting recordings",
76
description:
87
"Get all recordings of a meeting. [See the documentation](https://developers.zoom.us/docs/api/meetings/#tag/cloud-recording/GET/meetings/{meetingId}/recordings)",
98
key: "zoom_admin-get-meeting-recordings",
10-
version: "0.0.1",
9+
version: "0.0.2",
1110
type: "action",
1211
props: {
1312
zoomAdmin,
@@ -23,16 +22,26 @@ export default {
2322
description: "Whether to include the download access token in the response",
2423
optional: true,
2524
},
25+
ttl: {
26+
type: "integer",
27+
label: "TTL (seconds)",
28+
description: "Time to live (TTL) of the download_access_token in seconds. Range: 0-604800 (7 days). Only valid when Download Access Token is enabled.",
29+
optional: true,
30+
min: 0,
31+
max: 604800,
32+
},
2633
},
2734
async run({ $ }) {
28-
const res = await paginate(
29-
this.zoomAdmin.listMeetingRecordings,
30-
"recordings",
31-
get(this.meeting, "value", this.meeting),
32-
{
33-
download_access_token: this.downloadAccessToken,
34-
},
35-
);
35+
const params = {};
36+
37+
if (this.downloadAccessToken) {
38+
params.include_fields = "download_access_token";
39+
if (this.ttl !== undefined) {
40+
params.ttl = this.ttl;
41+
}
42+
}
43+
44+
const res = await this.zoomAdmin.listMeetingRecordings(get(this.meeting, "value", this.meeting), params);
3645

3746
$.export("$summary", `"${get(this.meeting, "label", this.meeting)}" meeting recordings successfully fetched`);
3847

components/zoom_admin/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@pipedream/zoom_admin",
3-
"version": "0.8.0",
3+
"version": "0.9.0",
44
"description": "Pipedream Zoom_admin Components",
55
"main": "zoom_admin.app.mjs",
66
"keywords": [

0 commit comments

Comments
 (0)