REST API调用可通过“ identitytoolkit / v3 / relyingparty / signupNewUser?key = ..”创建匿名用户,效果很好-它返回localId以及idToken和refreshToken-
POST https://www.googleapis.com/identitytoolkit/v3/relyingparty/signupNewUser?key=...
响应
{
"kind": "identitytoolkit#SignupNewUserResponse",
"idToken": "...",
"refreshToken": "...",
"expiresIn": "3600",
"localId": "..."
}
现在我需要通过Admin SDK复制相同的内容(至于.NET,这是一个非常有限的版本),所以我下一步-
POST https://www.googleapis.com/identitytoolkit/v3/relyingparty/signupNewUser
Authorization: Bearer %access_token%
我得到的就是这个-
{
"kind": "identitytoolkit#SignupNewUserResponse",
"email": "",
"localId": "..."
}
因此,idToken和refreshToken均不会返回。关于如何解决此问题的任何想法?