轻松实现QQ用户接入
1. 申請合作伙伴ID (PID),Key (PKey)
2. 發送請求
? https://graph.qq.com/oauth2.0/authorize?response_type=code&client_id=100000353&redirect_uri=http://www.wodongni.com/loginReturn.aspx
? redirect_uri:回傳URL
? client_id: 合作伙伴ID (PID)
? 返回:
?? string code = Request.QueryString["code"];
3. https://graph.qq.com/oauth2.0/me?access_token=****access_token
? access_token: 第2部獲取的code 值
?? 返回:
?? callback( {"client_id": 合作伙伴ID(PID),"openid":"****openID"} );
4. https://graph.qq.com/user/get_user_info?access_token=****access_token&oauth_consumer_key=100236353&openid=****openID
?返回:
?{ "ret":0, "msg":"", "nickname":"QQ姓名", "figureurl":"頭像1", "figureurl_1":"頭像2", "figureurl_2":"頭像3", "gender":"男" }
轉載于:https://www.cnblogs.com/rhythmK/archive/2011/12/23/2299420.html
總結
以上是生活随笔為你收集整理的轻松实现QQ用户接入的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 盖瓷砖瓦多少钱一平米,15O平方材料自买
- 下一篇: 托福培训费用多少钱?