获取access_token
access_token是调用授权关系接口的调用凭证
URL
https://api.linkstars.com/authorize/token
支持格式
JSON
HTTP请求方式
POST
是否需要登录
否
请求参数
参数名称 |
必选 |
类型及范围 |
说明 |
code |
true |
string |
临时授权码 |
client_id |
true |
string |
APP_KEY用户身份唯一凭证(管理中心获取) |
client_secret |
true |
string |
APP_SECRET(管理中心获取) |
redirect_uri |
false |
string |
回调地址 |
grant_type |
false |
string |
这里默认为authorization_code |
scope |
false |
string |
这里默认为base |
注意事项
返回结果
{
”error”:10000,
”msg”:”success”,
data:{"access_token":TOKEN,
"expires_in":7200,
"token_type":1,
”refresh_token”:”Ol43HJ8ndf8Fkurkjld_QW3kid”
}
}
返回字段说明
返回值字段 |
字段类型 |
字段说明 |
access_token |
string |
全局唯一票据 |
expires_in |
string |
票据可用时间(秒) |
token_type |
string |
票据类型 |
refresh_token |
string |
刷新access_token凭证 |