2/oauth2/access token/en

跳转到: 导航, 搜索
(Created page with '==oauth2/access_token== Access_token interface of OAuth2. ==URL== https://api.weibo.com/oauth2/access_token ==HTTP Request Method== POST ==Request Parameters== {| border="1" c…')
 
第16行: 第16行:
 
!width="70%" style="text-align:center;font-weight:bolder;border:1px solid #cccccc"|Description  
 
!width="70%" style="text-align:center;font-weight:bolder;border:1px solid #cccccc"|Description  
 
{{api_args|client_id|true|string|AppKey created when a application is created.}}
 
{{api_args|client_id|true|string|AppKey created when a application is created.}}
{{api_args|client_secret|true|string|AppSecret created when a application is created}}
+
{{api_args|client_secret|true|string|AppSecret created when a application is created.}}
 
{{api_args|grant_type|true|string|Request type.It can be authorization_code,password,refresh_token.}}
 
{{api_args|grant_type|true|string|Request type.It can be authorization_code,password,refresh_token.}}
 
|}
 
|}

2012年1月30日 (一) 20:48的版本

oauth2/access_token

Access_token interface of OAuth2.

URL

https://api.weibo.com/oauth2/access_token

HTTP Request Method

POST

Request Parameters

  Requires Type and Range Description
client_id true string AppKey created when a application is created.
client_secret true string AppSecret created when a application is created.
grant_type true string Request type.It can be authorization_code,password,refresh_token.


grant_type is authorization_code
  Requires Type and Range Description
code true string The code value returned when call 'authorize' interface.
redirect_uri true string Callback address.It need to be the same with the callback address filled when created the application.


grant_type is password
  Requires Type and Range Description
username true string Username of the authorization user.
password true string Password of the authorization user.


grant_type is refresh_token
  Requires Type and Range Description
refresh_token true string Returned refresh token.

Response

 {
       "access_token": "ACCESS_TOKEN",
       "expires_in": 1234,
       "refresh_token": "REFRESH_TOKEN"
 }