Universal OAuth Module API
Universal OAuth Module API
APP 注意:
通用页面代码及API参考
手机,短信验证码登录
微信授权登录
is_bind = false,用户不存在
is_bind = false,用户存在
is_bind = true
iOS 苹果授权登录接口
手机,密码注册
发送手机验证码,注册和找回密码时需要
手机,密码登录
找回密码/重置密码
用户解绑
用户退出登录
Universal
OAuth Module API
APP 注意:
APP 请求的header中,要通过 Referer 携带指定的APPID的参数,和微信小程序逻辑一致,小程序即便设置也不会被覆盖,所以仅通过 H5 编译条件区分,如下:
注意 header 里定义的
appid
header.appid 针对 H5
header.Referer 针对小程序和APP
网络请求的配置和使用,参考模版:
uapp new MyProject
,uapp new 命令使用的也是下面的模版。
src/common/http/index.js · uappkit/platform - 码云 - 开源中国 (gitee.com)
通用页面代码及
API
参考
登录页:
https://gist.github.com/zencodex/ce0564a4fd9d3e0df7ec441ccc11f262
我的页:
https://gist.github.com/zencodex/a7028269cf5f52e353144d9e7b15afdd
激活页:
https://gist.github.com/zencodex/277e4ec8995ee65de9917437b50259e8
API
封装:
https://gist.github.com/zencodex/2d2097f20b87d1ec7339c10e50cdabd8