FDS Restful API

OAuth related api supported by FDS

Version: 1.0.0

/


GET

Summary: get OAuth store token

Description: OAuth authentication, please read FDS documentation before using OAuth authentication, and send appliction to us via email

Parameters

Name Located in Description Required Schema
storageAccessToken query placeholer,no need to have value Yes string
appId query appId applied on dev.xiaomi.com Yes string
oauthAccessToken query access token when using third party OAuth authentication Yes string
oauthOpenId query must have through XiaoMiOAuth to authenticate,user's OpenID No string
oauthAppId query appId through third party OAuth authentication Yes string
oauthProvider query third party's OAuth,could be XiaoMi, QQ, Sina, RenRen Yes string
oauthMacKey query must have when using XiaoMiOAuth to authenticate, the signature key returned when obtaining the authorization code No string
oauthMacAlgorithm query must have when using XiaoMiOAuth to authenticate,the signature algorithm returned when obtaining the authorization code No string

Responses

Code Description Schema
200 OAuth store token StorageAccessTokenResult

Models


StorageAccessTokenResult

Name Type Description Required
token string access token FDS created No
expireTime long The period of validity(1 week) No

command line examples

curl --request GET \
  --url 'https://cnbj0.fds.api.xiaomi.com/?storageAccessToken=&appId=2882303761517436430&oauthAppId=2882303761517454151&oauthAccessToken=V2xxxxhcQ&oauthProvider=XiaoMi&oauthMacAlgorithm=HmacSHA1&oauthMacKey=I60xxxxdo' \
  --header 'cache-control: no-cache'
< HTTP/1.1 200 OK
< Server: Tengine
< Date: Sat, 04 Feb 2017 09:46:25 GMT
< Content-Type: application/json
< Content-Length: 167
< Connection: keep-alive
< Access-Control-Allow-Credentials: true
< Access-Control-Max-Age: 1728000
< Access-Control-Allow-Methods: GET, POST, PUT, HEAD, DELETE, OPTIONS
< Access-Control-Allow-Headers: DNT,X-Mx-ReqToken,Keep-Alive,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Authorization,Content-MD5
< Access-Control-Expose-Headers: content-md5, upload-time, x-xiaomi-meta-content-length
< 
* Connection #0 to host files.fds.api.xiaomi.com left intact
* Closing connection #0
{"expireTime":1486806381536,"token":"2idxxxAO"}

results matching ""

    No results matching ""