xiongwilee / Gracejs

A Nodejs BFF framework, build with koa2(基于koa2的标准前后端分离框架)
https://grace.wilee.me
MIT License
1.39k stars 238 forks source link

github oauth 配置问题 #8

Closed playedclass closed 7 years ago

playedclass commented 8 years ago

源码里的 回调URL填的是网站的,不能用,自己申请的,授权都不成功,回调URL是有什么格式吗 message: "Not Found"

xiongwilee commented 8 years ago

你是在开发环境下吗?有可能是缺一个API配置(开发环境下只有github:'https://github.com/'):

  // controller中请求各类数据前缀和域名的键值对
  api: {
    github_api: 'https://api.github.com/',
    github: 'https://github.com/',
  },
playedclass commented 8 years ago

oauthInfo: { error: "bad_verification_code", error_description: "The code passed is incorrect or expired.", error_uri: "https://developer.github.com/v3/oauth/#bad-verification-code" }

最后是跳转到http://feclub.cn/user/oauth? ,我是用本地开发环境运行的,改了main.development.js的内容还是这个问题

playedclass commented 8 years ago

换成自己的,可以了,谢了

xiongwilee commented 8 years ago

cool