Method: projects.getAuthorization
HTTP 请求
GET https://gsuiteaddons.googleapis.com/v1/{name=projects/*/authorization}
网址采用 gRPC 转码语法。
路径参数
参数 |
name |
string
必需。要获取 Google Workspace 插件授权信息的项目的名称。 示例:projects/my_project/authorization 。
必须对指定的资源 name 具有以下 IAM 权限才能进行授权:
gsuiteaddons.authorizations.get
|
响应正文
调用部署端点时使用的授权信息。
如果成功,响应正文将包含结构如下的数据:
JSON 表示法 |
{
"name": string,
"serviceAccountEmail": string,
"oauthClientId": string
} |
字段 |
name |
string
此资源的规范全称。示例:projects/123/authorization
|
serviceAccountEmail |
string
用于对向插件回调端点发出的请求进行身份验证的服务账号的电子邮件地址。
|
oauthClientId |
string
用于代表插件为用户获取 OAuth 访问令牌的 OAuth 客户端 ID。
|
授权范围
需要以下 OAuth 范围:
https://www.googleapis.com/auth/cloud-platform
如需了解详情,请参阅 OAuth 2.0 Overview。
如未另行说明,那么本页面中的内容已根据知识共享署名 4.0 许可获得了许可,并且代码示例已根据 Apache 2.0 许可获得了许可。有关详情,请参阅 Google 开发者网站政策。Java 是 Oracle 和/或其关联公司的注册商标。
最后更新时间 (UTC):2025-01-23。
[null,null,["最后更新时间 (UTC):2025-01-23。"],[[["Retrieves Google Workspace Add-on authorization details for a specific project."],["Requires project name as a path parameter and an empty request body."],["Response includes authorization name, service account email, and OAuth client ID."],["Needs `https://www.googleapis.com/auth/cloud-platform` OAuth scope for authorization."]]],["This document details retrieving authorization information for Google Workspace add-on deployments within a project. It uses a `GET` HTTP request to a specific URL containing the project name. The request body must be empty. The response, formatted in JSON, includes the project's canonical name, service account email, and OAuth client ID. Authorization requires a `gsuiteaddons.authorizations.get` IAM permission and the `https://www.googleapis.com/auth/cloud-platform` OAuth scope.\n"]]