Skip to content
This repository was archived by the owner on Sep 8, 2024. It is now read-only.

Latest commit

 

History

History
60 lines (48 loc) · 1.57 KB

File metadata and controls

60 lines (48 loc) · 1.57 KB

users Endpoint

The users endpoint retrieves the data about a specific user.

Endpoint

users/:id

Method

GET

URL Parameters

id: The ID of the user you want to check.

Possible error messages

Insufficient permissions (not being logged in)

{
    "data": [
        "You are not authorized to access this resource."
    ],
    "status": "notAuthorized",
}

id is missing

{
    "data": [
        "id is required"
    ],
    "status": "requestError",
}

Data returned

{
    'data': [{                          // Contains the requested data
        'avatarID': 'xxx',              // Their AvatarID (e.g.: 'base01')
        'badge': 'xxx',                 // Their badge (e.g.: '80sb01')
        'gRole': 0,                     // Their service wide role (0 = None; 3 = Brand Ambassador (BA); 5 = Admin)
        'guest': false,                 // Is the user a guest?
        'id': -1,                       // Their ID
        'joined': 'xxx',                // String representation of the time they joined plug (e.g.: '2014-07-23 22:47:00.573000')
        'language': 'xx',               // ISO 639-1 representation of their used language
        'level': 1,                     // Their level
        'slug': 'xxx',                  // URL conform representation of their name (also used for the profile page)
        'sub': 0,                       // Is the user a subscriber? (0 = false; 1 = true)
        'username': 'xxx',              // Their username
    }],
    'meta': {},
    'status': 'ok',
    'time': 'xx.xxxxxxxxxxx'
}