You want to retrieve file IDs from an event. If my understanding is correct, how about this sample script?
Sample script :
var inStorePartiesCalendarID = "### calendar ID ###";
var eventId = "### Event ID ###";
var res = Calendar.Events.get(inStorePartiesCalendarID, eventId, {fields: "attachments/fileId"});
var fileIds = res.attachments.map(function(e){return e.fileId});
Logger.log(fileIds)
Note :
- This sample script supposes that you have already known the event ID. If you need the method for retrieving the event IDs. Please tell me.
- If you want to retrieve the file ID and filename of the attachment file, please use
attachments(fileId,title)
for fields
.
References :
If I misunderstand your question, I'm sorry.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…