4
我正在做服務器端oauth,遵循this指南。沒有在YouTube上獲得刷新令牌OAuth
我順利地完成了OAuth的,但我沒有收到refresh_token
在交易授權代碼更新和訪問令牌步:
請求:
POST /o/oauth2/token HTTP/1.1
HOST: accounts.google.com
content-type: application/x-www-form-urlencoded
content-length: 260
code=4/KEOuzih9jwfnHj7Rl1DeqHhcJF0goKPwtwR5IQ09ieg&client_id=****.apps.googleusercontent.com&client_secret=****&redirect_uri=http%3A%2F%2Flocalhost%3A8000%2FsSignIn.html&grant_type=authorization_code
響應:
{
"access_token" : "****",
"expires_in" : 3580,
"token_type" : "Bearer"
}
我錯過了什麼嗎?
感謝阿布舍克!我離線傳遞了access_type,但我沒有啓用提示同意。現在它返回刷新標記。 – jremi