GET Users/{id}

Get user by id. User Authorization Required.

Request Information

URI Parameters

NameDescriptionTypeAdditional information
id

The user's id.

integer

Default value is 0

Body Parameters

None.

Response Information

Resource Description

The user.

ResponseInstanceOfUser
NameDescriptionTypeAdditional information
Data

User

None.

ResultType

ResultType

None.

Messages

Collection of string

None.

Links

Links

None.

ApiBaseUrl

string

None.

responseObjectType

string

None.

Response Formats

application/json, text/json

Sample:
{
  "data": {
    "userId": 1,
    "allPassId": 1,
    "userName": "sample string 1",
    "email": "sample string 2",
    "firstName": "sample string 3",
    "lastName": "sample string 4",
    "postalCode": "sample string 5",
    "facebookId": 1,
    "userScore": {
      "userId": 1,
      "questions": 2,
      "correct": 3,
      "percentCorrect": 4.0,
      "userName": "sample string 5",
      "apiUrl": {
        "href": "/userstats/sample string 7"
      },
      "resourceObjectType": "userStats"
    },
    "userKey": "MNzK7OlAv6+4qYaZLtd/8g==",
    "apiUrl": {
      "href": "/users/sample string 12"
    },
    "resourceObjectType": "user"
  },
  "resultType": {
    "code": 0,
    "message": "Success"
  },
  "messages": [
    "sample string 1",
    "sample string 2"
  ],
  "links": {},
  "apiBaseUrl": "sample string 1",
  "responseObjectType": "responseInstance<user>"
}

application/xml, text/xml

Sample:
<ResponseInstance xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
  <ApiBaseUrl>sample string 1</ApiBaseUrl>
  <Links>
    <First i:nil="true" />
    <Last i:nil="true" />
    <Next i:nil="true" />
    <Previous i:nil="true" />
    <Self i:nil="true" />
  </Links>
  <Messages xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:string>sample string 1</d2p1:string>
    <d2p1:string>sample string 2</d2p1:string>
  </Messages>
  <ResultType>
    <Code>Success</Code>
    <Message>Success</Message>
  </ResultType>
  <responseObjectType>responseInstance&lt;user&gt;</responseObjectType>
  <Data>
    <ApiUrl>
      <href>/users/sample string 12</href>
    </ApiUrl>
    <ResourceObjectType>user</ResourceObjectType>
    <AccessToken i:nil="true" />
    <AllPassId>1</AllPassId>
    <Email>sample string 2</Email>
    <FacebookId>1</FacebookId>
    <FirstName>sample string 3</FirstName>
    <LastName>sample string 4</LastName>
    <Password i:nil="true" />
    <PostalCode>sample string 5</PostalCode>
    <UserId>1</UserId>
    <UserKey>MNzK7OlAv6+4qYaZLtd/8g==</UserKey>
    <UserName>sample string 1</UserName>
    <UserScore>
      <ApiUrl>
        <href>/userstats/sample string 7</href>
      </ApiUrl>
      <ResourceObjectType>userStats</ResourceObjectType>
      <Correct>3</Correct>
      <PercentCorrect>4</PercentCorrect>
      <Questions>2</Questions>
      <UserId>1</UserId>
      <UserName>sample string 5</UserName>
    </UserScore>
  </Data>
</ResponseInstance>