Get Users

get

/documents/api/1.1/users/items

Get information about one or more users for folder and file sharing purposes.

The service uses search text provided with the call to match possible users. The search uses a "fuzzy" search of user names and email addresses to return matching users with the most likely matches listed first.

Request

Supported Media Types
  • application/json
  • application/xml
Query Parameters
info
Type: string
Required: true

Specify a search string used to return matching users. Wildcard characters are not supported.

Response

Supported Media Types
  • application/json
  • application/xml
200 Response

The request was fulfilled.

If no users are matched, count and errorCode will be "0" and items will not be returned.

Body
Folder metadata information.
Root Schema : UsersResponse
Folder metadata information.
Nested Schema : items
Type: array
Minimum Number of Items: 0
Nested Schema : User
User information
Example application/json

{
    "count":"3",
    "errorCode":"0",
    "items":[
        {
            "id":"U0EAA20910FAF3052ACB79E4T00000000001",
            "displayName":"User AA",
            "loginName":"userAALoginName",
            "type":"user"
        },
        {
            "id":"U7ECC74059E0FEDFEC66BF5AT00000000001",
            "displayName":"User BB",
            "loginName":"userBBLoginName",
            "type":"user"
        },
        {
            "id":"UEB4B3EFA6C02D1B46A121B4T00000000001",
            "displayName":"User CC",
            "loginName":"userCCLoginName",
            "type":"user"
        }
    ]
}
400 Response

Required field "info" is not provided.

Examples

The following example returns user information for users whose names contain the specified string.

GET .../users/items?info=user%20A

Request Header

None.

Request Body

None.

HTTP Status Code

HTTP_STATUS = 200

JSON Response

{
    "count": "3",
    "errorCode": "0",
    "items": [
        {
            "type": "user",
            "id": "U0EAA20910FAF3052ACB79E4T00000000001",
            "displayName": "User AA",
            "loginName": "userAALoginName"
        },
        {
            "type": "user",
            "id": "U7ECC74059E0FEDFEC66BF5AT00000000001",
            "displayName": "User BB",
            "loginName": "userBBLoginName"
        },
        {
            "type": "user",
            "id": "UEB4B3EFA6C02D1B46A121B4T00000000001",
            "displayName": "User CC",
            "loginName": "userCCLoginName"
        }
    ]
}