User Profile & Settings


GET/openapiv2/user/user-id/

http://sandboxapi.ihealthlabs.com/openapiv2/user/05dffbe0dd*****.json/?client_id=ddb9cbc759*****&client_secret=4738f9d00e*****&redirect_uri=http%3a%2f%2f+yourcallback.com%2f%3fthis%3dthat&access_token=xpoBt0ThQQ*****&sc=d63493704c*****&sv=59bb35f102*****&locale=en_US

The Request Content:
Important,
In the URL, 05dffbe0dd***** means the UserID retrieved by AccessToken, which is required; otherwise, the user information cannot be accessed.
In the URL, the value of userinfo.json is the format of the data you want to fetch, we can support two different kinds of file packages, .json and .xml.

Required Parameters:

Parameter

Description

Client_id

The ID for the client request

client_secret

The key for the request

access_token

The token for access

sc

The serial number for the user

sv

This is type of one on one value based on sv

Optional Parameters:

Parameter

Default

Description

backtype

Json/xml

Set the returned result to json or xml

locale

Default(example
in Appendix)

Set the locale / units returned

The Response Content

The following table shows the description of all the returning parameters:

Parameter

Description

HeightUnit

HeightUnit(The explanation of value)

WeightUnit

WeightUnit(The explanation of value)

dateofbirth

User birthday

gender

User gender

height

User height

logo

User portrait

nickname

User nickname

userid

Uniquely identifies the user

weight

User weight




GET/openapiv2/application/userinfo/

http://sandboxapi.ihealthlabs.com/openapiv2/application/userinfo.json/?client_id=ddb9cbc759*****&client_secret=4738f9d00e*****&redirect_uri=http%3a%2f%2f+yourcallback.com%2f%3fthis%3dthat&access_token=xpoBt0ThQQ*****&sc=d63493704c*****&sv=59bb35f102*****&locale=en_US

The Request Content:
Important,
In the URL, the value of userinfo.json is the format of the data you want to fetch, we can support two different kinds of file packages, .json and .xml.

Required Parameters:

Parameter

Description

Client_id

The ID for the client request

client_secret

The key for the request

access_token

The token for access

sc

The serial number for the user

sv

This is type of one on one value based on sv

Optional Parameters:

Parameter

Default

Description

start_time

Datetime now

The Unix time of when the userinfo data starts,
ex:1331554332(starting from 1970-01-01 0:0:0 until
the present date and time, the unit is seconds) When
it is null, the userinfo data would start from one year
ago

page_index

First page

The page index of data, which starts from 1

end_time

Over the past year

The Unix time of when the userinfo data ends, it must
be later than start_time. ex: 1331554332

backtype

Json/xml

Set the returned result to json or xml

locale

Default(example
in Appendix)

Set the locale / units returned

The Response Content

The following table shows the description of all the returning parameters:

Parameter

Description

UserInfoList

The data detail of userinfo
userid:unique identity of user
nickname:nickname of user
gender:gender of user
height:height of user
weight :weight of user
dateofbirth:dateofbirth of user
logo:Avatar logo

CurrentRecordCount

The count of current page

NextPageUrl

The url of next page

PageLength

The length of one page

PageNumber

The total page count of data records

PrevPageUrl

The url of previous page

RecordCount

The total number of data records

HeightUnit

Height Unit(The explanation of value)

Weight Unit

Weight Unit(The explanation of value)