【发布时间】:2022-01-18 18:09:43
【问题描述】:
通过将Authorizattion Code 设置为授权类型,我可以在 Postman 中获取访问令牌。然而,我正在寻找的实际东西是 ID 令牌。有谁知道如何从邮递员那里获取 Google ID 令牌?我想使用此 ID 令牌向后端服务器进行身份验证。
【问题讨论】:
标签: oauth-2.0 oauth postman google-oauth openid-connect
通过将Authorizattion Code 设置为授权类型,我可以在 Postman 中获取访问令牌。然而,我正在寻找的实际东西是 ID 令牌。有谁知道如何从邮递员那里获取 Google ID 令牌?我想使用此 ID 令牌向后端服务器进行身份验证。
【问题讨论】:
标签: oauth-2.0 oauth postman google-oauth openid-connect
Id 令牌用于 Open Id 连接或登录。
为了获得一个 Id 令牌,您只需要传递配置文件的范围,然后 google 将返回一个 id 令牌
{
"access_token": "[Redacted]",
"id_token": "[Redacted]",
"expires_in": 3599,
"token_type": "Bearer",
"scope": "https://www.googleapis.com/auth/userinfo.profile",
"refresh_token": "[Redacted]"
}
【讨论】: