【问题标题】:What is wrong with the Google groups api discovery URL?Google 群组 api 发现 URL 有什么问题?
【发布时间】:2021-03-09 13:40:45
【问题描述】:

我正在尝试使用 Python 脚本来管理 Google 群组。该脚本基本上是 Google 提供的以下 quickstart.py 脚本,仅修改为适用于组而不是文档。 (见here。)

尝试这样做时:

service = build('groups', 'v1', credentials=creds)

返回如下错误:

googleapiclient.errors.HttpError: <HttpError 502 when requesting https://groups.googleapis.com/$discovery/rest?version=v1 returned "Bad Gateway">

在浏览器中快速检查该 URL 会导致 502 错误。

但是,检查其他 api 发现 URL 似乎工作正常。例如:浏览到

https://notebooks.googleapis.com/$discovery/rest?version=v1

按预期以 JSON 格式返回请求的发现信息。

我已经搜索并阅读了文档以分散注意力,但似乎无法找到组发现 URL 的问题。任何帮助将不胜感激。

【问题讨论】:

    标签: python google-api google-groups google-groups-api


    【解决方案1】:

    我看错了方向。基于另一个错误的更多搜索发现我应该使用管理 URL:

    https://admin.googleapis.com/$discovery/rest?version=directory_v1
    

    感谢 this post 让我参与其中。

    【讨论】:

      猜你喜欢
      • 2015-08-27
      • 1970-01-01
      • 2016-07-17
      • 2018-04-16
      • 2021-05-01
      • 2021-05-02
      • 1970-01-01
      • 2014-11-04
      相关资源
      最近更新 更多