auth.code2Session
GET
https://api.weixin.qq.com/sns/jscode2session?appid=wxa96c71f1e851272e&secret=c1f522c4b615310f5cd82edf97c0224c&js_code=041Sw9ll2nf9084JhJol2Shw644Sw9l0&grant_type=authorization_code
请求参数
参数名
类型
描述
必填
appid
string
示例:wxa96c71f1e851272e
必填
secret
string
示例:c1f522c4b615310f5cd82edf97c0224c
必填
js_code
string
示例:041Sw9ll2nf9084JhJol2Shw644Sw9l0
必填
grant_type
string
示例:authorization_code
必填
响应参数
参数名
类型
描述
必填
session_key
string
示例:qsXl7QTYr7VG+mq8ewB1xw==
必填
openid
string
示例:o0o1B6F82kL1OJnVSNp5ODcYK2hI
必填