我们如何列出Google云端硬盘上特定文件夹中的所有文件 [英] How can we list all files from a specific folder on Google Drive

查看:136
本文介绍了我们如何列出Google云端硬盘上特定文件夹中的所有文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们注意到Google Drive API Javascript 允许您列出特定文件夹中的所有文件,但它只提供文件中的基本细节。如果我们想知道更多信息,例如文件名,我们需要为每个文件再次查询API。有没有一种方法可以列出文件的更多细节,例如单个文件夹列表查询中的文件名?

We noticed that Google Drive API Javascript allows you to list all files from an specific folder, however it brings just basic details from the file. If we want to know more such as the file name we need to query the API again for each single file. Is there a way that we can list more details of the file such as the file name from a single folder list query?

谢谢

Thanks

推荐答案

我猜你使用过 Children.list()。它只列出不是你想要的功能的孩子的ID。您应该使用参数q =' Files.list() {{FOLDER_ID}}'在父母身上,它会列出您想要的特定文件夹的所有文件及其详细信息。

I guess you used Children.list(). It only lists id of children which is not the function you want. You should rather use Files.list() with parameter q="'{{FOLDER_ID}}' in parents" and it will list all the files and its details of children of specific folder you want.

这篇关于我们如何列出Google云端硬盘上特定文件夹中的所有文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆