Skip to content

Commit d83982a

Browse files
get a meeting details
1 parent feff376 commit d83982a

File tree

5 files changed

+229
-4
lines changed

5 files changed

+229
-4
lines changed

Diff for: README.md

+5
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,11 @@ Now you can date a Zoom meeting with AI's help
2121
- `delete the latest meeting`
2222
- `delete the 86226580854 meeting`
2323

24+
### 4. get a meeting detail
25+
26+
- `Retrieve the latest meeting's details`
27+
- `Retrieve 86226580854 meeting's details`
28+
2429
## 2 Steps to play with zoom-mcp-server
2530

2631
- Get Zoom Client ID, Zoom Client Secret and Account ID

Diff for: common/types.ts

+169
Original file line numberDiff line numberDiff line change
@@ -109,3 +109,172 @@ export const ZoomListMeetingsSchema = z.object({
109109
}),
110110
),
111111
});
112+
113+
export const ZoomMeetingDetailSchema = z.object({
114+
assistant_id: z.string().optional(),
115+
host_email: z.string().optional(),
116+
host_id: z.string().optional(),
117+
id: z.number(),
118+
uuid: z.string(),
119+
agenda: z.string().optional(),
120+
created_at: z.string().optional(),
121+
duration: z.number().optional(),
122+
encrypted_password: z.string().optional(),
123+
pstn_password: z.string().optional(),
124+
h323_password: z.string().optional(),
125+
join_url: z.string().optional(),
126+
chat_join_url: z.string().optional(),
127+
occurrences: z
128+
.array(
129+
z.object({
130+
duration: z.number().optional(),
131+
occurrence_id: z.string().optional(),
132+
start_time: z.string().optional(),
133+
status: z.string().optional(),
134+
}),
135+
)
136+
.optional(),
137+
password: z.string().optional(),
138+
pmi: z.string().optional(),
139+
pre_schedule: z.boolean().optional(),
140+
recurrence: z
141+
.object({
142+
end_date_time: z.string().optional(),
143+
end_times: z.number().optional(),
144+
monthly_day: z.number().optional(),
145+
monthly_week: z.number().optional(),
146+
monthly_week_day: z.number().optional(),
147+
repeat_interval: z.number().optional(),
148+
type: z.number().optional(),
149+
weekly_days: z.string().optional(),
150+
})
151+
.optional(),
152+
settings: ZoomMeetingSettingsSchema.extend({
153+
approved_or_denied_countries_or_regions: z
154+
.object({
155+
approved_list: z.array(z.string()).optional(),
156+
denied_list: z.array(z.string()).optional(),
157+
enable: z.boolean().optional(),
158+
method: z.string().optional(),
159+
})
160+
.optional(),
161+
authentication_exception: z
162+
.array(
163+
z.object({
164+
email: z.string().optional(),
165+
name: z.string().optional(),
166+
join_url: z.string().optional(),
167+
}),
168+
)
169+
.optional(),
170+
breakout_room: z
171+
.object({
172+
enable: z.boolean().optional(),
173+
rooms: z
174+
.array(
175+
z.object({
176+
name: z.string().optional(),
177+
participants: z.array(z.string()).optional(),
178+
}),
179+
)
180+
.optional(),
181+
})
182+
.optional(),
183+
global_dial_in_numbers: z
184+
.array(
185+
z.object({
186+
city: z.string().optional(),
187+
country: z.string().optional(),
188+
country_name: z.string().optional(),
189+
number: z.string().optional(),
190+
type: z.string().optional(),
191+
}),
192+
)
193+
.optional(),
194+
language_interpretation: z
195+
.object({
196+
enable: z.boolean().optional(),
197+
interpreters: z
198+
.array(
199+
z.object({
200+
email: z.string().optional(),
201+
languages: z.string().optional(),
202+
interpreter_languages: z.string().optional(),
203+
}),
204+
)
205+
.optional(),
206+
})
207+
.optional(),
208+
sign_language_interpretation: z
209+
.object({
210+
enable: z.boolean().optional(),
211+
interpreters: z
212+
.array(
213+
z.object({
214+
email: z.string().optional(),
215+
sign_language: z.string().optional(),
216+
}),
217+
)
218+
.optional(),
219+
})
220+
.optional(),
221+
meeting_invitees: z
222+
.array(
223+
z.object({
224+
email: z.string().optional(),
225+
internal_user: z.boolean().optional(),
226+
}),
227+
)
228+
.optional(),
229+
continuous_meeting_chat: z
230+
.object({
231+
enable: z.boolean().optional(),
232+
auto_add_invited_external_users: z.boolean().optional(),
233+
auto_add_meeting_participants: z.boolean().optional(),
234+
who_is_added: z.string().optional(),
235+
channel_id: z.string().optional(),
236+
})
237+
.optional(),
238+
resources: z
239+
.array(
240+
z.object({
241+
resource_type: z.string().optional(),
242+
resource_id: z.string().optional(),
243+
permission_level: z.string().optional(),
244+
}),
245+
)
246+
.optional(),
247+
question_and_answer: z
248+
.object({
249+
enable: z.boolean().optional(),
250+
allow_submit_questions: z.boolean().optional(),
251+
allow_anonymous_questions: z.boolean().optional(),
252+
question_visibility: z.string().optional(),
253+
attendees_can_comment: z.boolean().optional(),
254+
attendees_can_upvote: z.boolean().optional(),
255+
})
256+
.optional(),
257+
auto_start_meeting_summary: z.boolean().optional(),
258+
who_will_receive_summary: z.number().optional(),
259+
auto_start_ai_companion_questions: z.boolean().optional(),
260+
who_can_ask_questions: z.number().optional(),
261+
summary_template_id: z.string().optional(),
262+
}).optional(),
263+
start_time: z.string().optional(),
264+
start_url: z.string().optional(),
265+
status: z.string().optional(),
266+
timezone: z.string().optional(),
267+
topic: z.string().optional(),
268+
tracking_fields: z
269+
.array(
270+
z.object({
271+
field: z.string().optional(),
272+
value: z.string().optional(),
273+
visible: z.boolean().optional(),
274+
}),
275+
)
276+
.optional(),
277+
type: z.number().optional(),
278+
dynamic_host_key: z.string().optional(),
279+
creation_source: z.string().optional(),
280+
});

Diff for: index.ts

+34-2
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ import {
1414
CreateMeetingOptionsSchema,
1515
deleteMeeting,
1616
DeleteMeetingOptionsSchema,
17+
getAMeetingDetails,
18+
GetMeetingOptionsSchema,
1719
ListMeetingOptionsSchema,
1820
listMeetings,
1921
} from "./operations/meeting.js";
@@ -37,6 +39,7 @@ enum PromptName {
3739
LIST_MEETINGS = "list_meetings",
3840
CREATE_A_MEETING = "create_meeting",
3941
DELETE_A_MEETING = "delete_a_meeting",
42+
GET_A_MEETING_DETAILS = "get_a_meeting_details",
4043
}
4144

4245
server.setRequestHandler(ListPromptsRequestSchema, async () => {
@@ -54,6 +57,10 @@ server.setRequestHandler(ListPromptsRequestSchema, async () => {
5457
name: PromptName.DELETE_A_MEETING,
5558
description: "A prompt to delete a meeting",
5659
},
60+
{
61+
name: PromptName.GET_A_MEETING_DETAILS,
62+
description: "A prompt to get a meeting's details",
63+
},
5764
],
5865
};
5966
});
@@ -97,6 +104,18 @@ server.setRequestHandler(GetPromptRequestSchema, async (request) => {
97104
},
98105
],
99106
};
107+
} else if (name === PromptName.GET_A_MEETING_DETAILS) {
108+
return {
109+
messages: [
110+
{
111+
role: "user",
112+
content: {
113+
type: "text",
114+
text: "Get a zoom meeting's details",
115+
},
116+
},
117+
],
118+
};
100119
}
101120
throw new Error(`Unknown prompt: ${name}`);
102121
});
@@ -115,10 +134,15 @@ server.setRequestHandler(ListToolsRequestSchema, async () => {
115134
inputSchema: zodToJsonSchema(ListMeetingOptionsSchema),
116135
},
117136
{
118-
name: "delete_meeting",
137+
name: "delete_a_meeting",
119138
description: "Delete a meeting with a given ID",
120139
inputSchema: zodToJsonSchema(DeleteMeetingOptionsSchema),
121140
},
141+
{
142+
name: "get_a_meeting_details",
143+
description: "Retrieve the meeting's details with a given ID",
144+
inputSchema: zodToJsonSchema(GetMeetingOptionsSchema),
145+
},
122146
],
123147
};
124148
});
@@ -145,13 +169,21 @@ server.setRequestHandler(CallToolRequestSchema, async (request) => {
145169
};
146170
}
147171

148-
case "delete_meeting": {
172+
case "delete_a_meeting": {
149173
const args = DeleteMeetingOptionsSchema.parse(request.params.arguments);
150174
const result = await deleteMeeting(args);
151175
return {
152176
content: [{ type: "text", text: result }],
153177
};
154178
}
179+
180+
case "get_a_meeting_details": {
181+
const args = GetMeetingOptionsSchema.parse(request.params.arguments);
182+
const result = await getAMeetingDetails(args);
183+
return {
184+
content: [{ type: "text", text: JSON.stringify(result, null, 2) }],
185+
};
186+
}
155187
}
156188
} catch (error) {
157189
if (error instanceof z.ZodError) {

Diff for: operations/meeting.ts

+20-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
import { z } from "zod";
22
import { zoomRequest } from "../common/util.js";
3-
import { ZoomListMeetingsSchema, ZoomMeetingSchema } from "../common/types.js";
3+
import {
4+
ZoomListMeetingsSchema,
5+
ZoomMeetingDetailSchema,
6+
ZoomMeetingSchema,
7+
} from "../common/types.js";
48

59
export const CreateMeetingOptionsSchema = z.object({
610
agenda: z
@@ -37,9 +41,14 @@ export const DeleteMeetingOptionsSchema = z.object({
3741
id: z.number().describe("The ID of the meeting to delete."),
3842
});
3943

44+
export const GetMeetingOptionsSchema = z.object({
45+
id: z.number().describe("The ID of the meeting."),
46+
});
47+
4048
export type CreateMeetingOptions = z.infer<typeof CreateMeetingOptionsSchema>;
4149
export type ListMeetingOptions = z.infer<typeof ListMeetingOptionsSchema>;
4250
export type DeleteMeetingOptions = z.infer<typeof DeleteMeetingOptionsSchema>;
51+
export type GetMeetingOptions = z.infer<typeof GetMeetingOptionsSchema>;
4352

4453
export async function createMeeting(options: CreateMeetingOptions) {
4554
const response = await zoomRequest(
@@ -78,3 +87,13 @@ export async function deleteMeeting(options: DeleteMeetingOptions) {
7887
);
7988
return response;
8089
}
90+
91+
export async function getAMeetingDetails(options: GetMeetingOptions) {
92+
const response = await zoomRequest(
93+
`https://api.zoom.us/v2/meetings/${options.id}`,
94+
{
95+
method: "GET",
96+
},
97+
);
98+
return ZoomMeetingDetailSchema.parse(response);
99+
}

Diff for: package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"build": "tsc && shx chmod +x dist/*.js",
77
"prepare": "husky",
88
"watch": "tsc --watch",
9-
"inspector": "npx @modelcontextprotocol/inspector dist/index.js"
9+
"inspector": "npx @modelcontextprotocol/inspector -- node dist/index.js -e ZOOM_ACCOUNT_ID=$ZOOM_ACCOUNT_ID -e ZOOM_CLIENT_ID=$ZOOM_CLIENT_ID -e ZOOM_CLIENT_SECRET=$ZOOM_CLIENT_SECRET"
1010
},
1111
"repository": {
1212
"type": "git",

0 commit comments

Comments
 (0)