后续期限,寻找行动项 [英] Term for followup, looking for actionitems

查看:42
本文介绍了后续期限,寻找行动项的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想写一个快速的脚本来提醒自己,放在Google驱动器之外的各种Google文档中的后续操作项可以从API list()中受益.但是,似乎followup:actionitems搜索查询不适用于该API,因为未知搜索项.它返回400错误.

I wanted to write a quick script to remind myself of follow-up action items put on the various google documents, out of google drive to benefit from the API list(). However, it seems the followup:actionitems search query is not working with the API, as the search term is not known. It returns a 400 error.

例如,执行以下操作:

results = service.files().list(q="followup:actionitems",
                                   pageSize=50,
                                   pageToken=page_token,
                                   fields="nextPageToken, files(id, name)").execute()

导致:

Traceback (most recent call last):
  File "./reminder.py", line 49, in <module>
    main()
  File "./reminder.py", line 38, in main
    fields="nextPageToken, files(id, name)").execute()
  File "/home/x/.virtualenvs/gdocs-followup-reminder-7WeAWiqi/lib/python3.7/site-packages/googleapiclient/_helpers.py", line 130, in positional_wrapper
    return wrapped(*args, **kwargs)
  File "/home/x/.virtualenvs/gdocs-followup-reminder-7WeAWiqi/lib/python3.7/site-packages/googleapiclient/http.py", line 856, in execute
    raise HttpError(resp, content, uri=self.uri)
googleapiclient.errors.HttpError: <HttpError 400 when requesting https://www.googleapis.com/drive/v3/files?q=followup%3Aactionitems&pageSize=50&fields=nextPageToken%2C+files%28id%2C+name%29&alt=json returned "Invalid Value">

有什么我想念的吗?使用方法不正确吗?还是计划将来使用呢?

Is there something I am missing? Not the right usage? Or is it planned to have that in the future?

推荐答案

您可以将q参数设置为

fullText contains 'followup:actionitems' and trashed = false

返回与Google云端硬盘用户界面相同的文件

returns the same files as Google Drive UI does

这篇关于后续期限,寻找行动项的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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