문제

I want both name , email and other profile information for a user once he/she logs in using google oauth.

incidentally , if I use

https://www.googleapis.com/auth/userinfo.email

as the scope , it will give me the user email id and if I use

https://www.googleapis.com/auth/userinfo.profile , it will give me other info like url and image etc.

But how can I get both the email and other relevant information using one such API scope?

도움이 되었습니까?

해결책

just join them with "+" separator, as `scope' parameter.

see http://code.google.com/intl/ja/apis/accounts/docs/OAuth2WebServer.html#formingtheurl

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top