GSuite API:授权应用及其用户

时间:2018-05-06 18:19:31

标签: gsuite

我试图获取一份清单:

  • 所有经过我的同事授权的第三方应用程序
  • 哪位同事已经授权哪个申请
  • 该应用程序的范围(阅读电子邮件,添加事件,......)

我可以使用CustomerUsageReports API获取授权应用程序列表以及使用它们的员工数量:

72 => {#110
+"client_id": "<censoredjustincase>.apps.googleusercontent.com"
+"client_name": "Slack"
+"num_users": "15"
}

但是这并没有让我知道谁使用它以及使用哪个范围。

我还可以获取过去x天内所有授权事件的列表:

    {#41
  +"kind": "admin#reports#activity"
  +"actor": {#26
    +"email": "<censored>"
    +"profileId": "<censored>"
  }
  +"events": array:1 [
    0 => {#25
      +"name": "authorize"
      +"parameters": array:3 [
        0 => {#23
          +"name": "client_id"
          +"value": "<censored>.apps.googleusercontent.com"
        }
        1 => {#24
          +"name": "app_name"
          +"value": "ProsperWorks CRM"
        }
        2 => {#37
          +"name": "scope"
          +"multiValue": array:2 [
            0 => "https://www.googleapis.com/auth/userinfo.email"
            1 => "https://www.googleapis.com/auth/userinfo.profile"
          ]
        }
      ]
    }
  ]
}

但是,此事件列表仅限于过去180天。无论在那段时间之前授权的任何应用程序可能都不会再出现,我猜想。

有谁知道如何获得授权第三方应用程序的完整列表及其范围和用户?

0 个答案:

没有答案
相关问题