Operations with a Specific User
This resource provides access to a specific user in Hub and YouTrack.
Resource | <Hub Service URL>/api/rest/users/{userID} |
Returned entity | User. For the description of the entity attributes, see User Attributes. |
Supported methods |
|
User Attributes
Represents a user in Hub and YouTrack.
Attributes
This table describes attributes of the User
entity.
To receive an attribute in the response from the server, specify it explicitly in the
fields
request parameter.To update an attribute, provide it in the body of a POST request.
Field | Type | Description |
---|---|---|
id | String | The unique identifier of the user. |
aliases | Set.<alias> | The set of IDs of user accounts that have been merged into this account. |
avatar | avatar | The avatar of the user. |
banned | Boolean | This flag indicates whether the user account is banned. |
creationTime | Long | The timestamp when the user account was created. |
details | Set.<details> | A set of login credentials associated with the account. These credentials point to various built-in and federated authentication modules. |
groups | Set.<userGroup> | The list of groups where the user belongs. |
guest | Boolean | This flag indicates whether the user account is the guest account. |
lastAccessTime | Long | The timestamp when the user account last logged in to the system. |
licenses | Set.<license> | The list of licenses that the user has. |
login | String | The login of the user. |
name | String | The full name of the user. |
permanentTokens | Set.<permanentToken> | The list of permanent tokens of the user. |
profile | profile | The user profile details, such as email, locale preferences, and custom user attributes. |
favoriteProjects | Set.<project> | The set of favourite projects of the user. |
projectRoles | Set.<projectRole> | The set of project roles that this user has been granted directly. |
teams | Set.<projectTeam> | The list of project teams where the user belongs. |
type | String | The type of the entity. In this case, it's |
userType | userType | The type of the user account. |
VCSUserNames | Set.<vcsUserName> | The list of VCS usernames of the user. |
Read a Specific User
Get the specific user.
Request Syntax
Request Parameters
Parameter | Type | Description |
---|---|---|
fields | String | Optional. Returns only the specified subset of the fields for the user. Use Fields Syntax to define the subset. |
Sample
Request
Response Body
Update a Specific User
Update a specific user.
Request Syntax
Request Parameters
Parameter | Type | Description |
---|---|---|
fields | String | A list of User attributes that should be returned in the response. If no field is specified, only the |
Sample
In this sample, we are updating the full name of a specific user.
Request
Request Body
Response Body
Delete a Specific User
Delete a specific user.
Request Syntax
Request Parameters
Parameter | Type | Description |
---|---|---|
fields | String | A list of User attributes that should be returned in the response. If no field is specified, only the |
Sample
In this sample, we are deleting a specific user.