I'm actually trying to set up a OAuth login with WeChat for my web application. So, I have create a account on wechat, and I used a Test account to have all access unlimited.
So, on the test account configuration, I have successfully validate the token from wechat (see here : http://admin.wechat.com/wiki/index.php?title=Getting_Started).
On the doc, OAuth is explain here : http://admin.wechat.com/wiki/index.php?title=User_Profile_via_Web
We must redirect user to this URL for login: https://open.weixin.qq.com/connect/oauth2/authorize?appid=APPID&redirect_uri=REDIRECT_URI&response_type=code&scope=SCOPE&state=STATE#wechat_redirect
I have replace APPID by my test account AppId, my redirect URI like : http://wechat.mydomain.net, SCOPE by the correct one (snsapi_userinfo) and remove the state param (optional). But, I had a error on Wechat :
Oops! Something went wrong:(
After hours of research, I set the domain on "Api permission list", in " Webpage Account"
But I always have this error. Maybe I missing something, but I don't find what.
There is my final URL called :
https://open.weixin.qq.com/connect/oauth2/authorize?appid=wx8ytvf5838cc7t33d&redirect_uri=http://wechat.mydomain.net/wechat/callback&response_type=code&scope=snsapi_userinfo&connect_redirect=1#wechat_redirect
Thanks for your help !