---
schema: rendered-html/v1
title: "User | Developer Portal for YouTrack and Hub Documentation"
source_url: https://www.jetbrains.com/help/youtrack/devportal/v1-User.html
generated_at: 2026-06-11T15:19:38.542182+00:00
---

Feedback

Thanks for your feedback!

Was this page helpful?

YesNo

Developer Portal for YouTrack and Hub

- Developer Portal
- Apps
- MCP Tools
- YouTrack Workflows
- JavaScript Workflow Quick Start Guide
- Create a Workflow
- Edit a Workflow
- Workflow Rule Types
- Transactions
- Use Cases for Workflows
- Web-based Workflow Editor
- Using an External Code Editor
- Default Workflows
- Custom Workflow Repository
- JavaScript Workflow Reference
- Rule-specific Properties
- Context
- Requirements
- Using the Workflow API
- Building Integrations with Slack
- Using REST API Methods in JavaScript Workflows
- Working with Dates and Times
- Working with Periods
- Localized Workflow Messages
- Troubleshooting Workflows
- Remote Debugger
- YouTrack Workflow API
- Change Log
- date-time
- entities
- AbstractVcsItem
- Agile
- AppGlobalStorage
- Article
- ArticleAttachment
- ArticleComment
- BaseArticle
- BaseArticleAttachment
- BaseArticleComment
- BaseComment
- BaseEntity
- BaseWorkItem
- Build
- BundleElementCondition
- BundleProjectCustomField
- Calendar
- Calendar24x7
- ChangesProcessor
- Channel
- EnumField
- FeedbackForm
- Field
- FieldBasedBundleValuesCondition
- FieldBasedUserValuesCondition
- FieldBasedValuesCondition
- Fields
- Gantt
- GroupProjectCustomField
- Issue
- IssueAttachment
- IssueComment
- IssueLinkPrototype
- IssueTag
- IssueWorkItem
- Iterator
- JsonForArticleAddAttachment
- JsonForArticleAddComment
- JsonForArticleConstructor
- JsonForIssueAddAttachment
- JsonForIssueAddComment
- JsonForIssueAddWorkItem
- JsonForIssueCommentAddAttachment
- JsonForIssueConstructor
- JsonForUserNotify
- MailboxChannel
- OwnedField
- PeriodProjectCustomField
- PersistentFile
- Project
- ProjectCustomField
- ProjectTeam
- ProjectType
- ProjectVersion
- PullRequest
- PullRequestState
- Requirement
- Requirements
- [SavedQuery](jetbrains__com__help__youtrack__devportal__v1-savedquery.md)
- [Set](jetbrains__com__help__youtrack__devportal__v1-set.md)
- [SimpleCalendar](jetbrains__com__help__youtrack__devportal__v1-simplecalendar.md)
- [SimpleProjectCustomField](jetbrains__com__help__youtrack__devportal__v1-simpleprojectcustomfield.md)
- [Sprint](jetbrains__com__help__youtrack__devportal__v1-sprint.md)
- [State](jetbrains__com__help__youtrack__devportal__v1-state.md)
- [Tag](jetbrains__com__help__youtrack__devportal__v1-tag.md)
- [TextProjectCustomField](jetbrains__com__help__youtrack__devportal__v1-textprojectcustomfield.md)
- [User](v1-User.html)
- [UserAttributes](jetbrains__com__help__youtrack__devportal__v1-userattributes.md)
- [UserCondition](jetbrains__com__help__youtrack__devportal__v1-usercondition.md)
- UserGroup
- UserProjectCustomField
- UserType
- VcsChange
- VcsServer
- WatchFolder
- WorkItemAttributeValue
- WorkItemAttributes
- WorkItemProjectAttribute
- WorkItemType
- http
- license
- notifications
- search
- strings
- workflow
- YouTrack Import Scripts
- YouTrack Form API
- YouTrack REST API
- Hub REST API

1. YouTrack Workflows
2. JavaScript Workflow Reference
3. YouTrack Workflow API
4. entities
5. [User](#0)

# User﻿

Last modified: 14 May 2026

Represents a user account in YouTrack.

Extends BaseEntity.

## Properties﻿

| Name | Type | Description |
| **static** current | User | Read-only.   The current (logged in) user. |
| **static** fieldType | String | Read-only.   Field type. Used when defining rule requirements. |
| attributes | UserAttributes | Read-only.   Custom user attributes.    Available since 2021.1.7000 |
| avatarUrl | String | Read-only.   The absolute URL of the image that is used as the avatar for a user account. May point to an external service, like Gravatar.    Available since 2019.3 |
| becomesRemoved | Boolean | Read-only.   When `true`, the entity is removed in the current transaction. Otherwise, `false`. This property can become `true` only in on-change rules when the rule is triggered on the removal of an issue or an article. In the rule code, the `runOn` rule property must contain the `removal` parameter set to `true`.    Available since 2017.4.37915  ``` runOn: {removal: true} ``` |
| email | String | Read-only.   The email address of the user. |
| extensionProperties | Object | The object containing extension properties for this entity and their values. Extension properties are custom properties that might be added to core YouTrack entities by an app. For details about extension properties, see <https://www.jetbrains.com/help/youtrack/devportal/apps-extension-properties.html>.    Available since 2024.3  ``` const entities = require('@jetbrains/youtrack-scripting-api/entities');  exports.rule = entities.Issue.action({     command: 'test',     action: function (ctx) {         const printValues = () => {             return 'stringProp:' + ctx.issue.extensionProperties.stringProp + ';'                 + 'integerProp:' + ctx.issue.extensionProperties.integerProp + ';'                 + 'booleanProp:' + ctx.issue.extensionProperties.booleanProp + ';'                 + 'issueProp:' + ctx.issue.extensionProperties.issueProp?.id + ';'                 + 'issuesProp:' + ctx.issue.extensionProperties.issuesProp?.first()?.id + ';'         }         ctx.issue.addComment(printValues());     } }); ``` |
| firstDayOfWeeks | Number | Read-only.   First day of week as set in the user's profile settings. 0 is for Sunday, 1 is for Monday, etc.    Available since 2019.1.50122 |
| fullName | String | Read-only.   The full name of the user as seen in their profile. |
| groups | Set.<NestedUserGroup> | Read-only.   The list of user's groups.    Available since 2025.3 |
| isBanned | Boolean | Read-only.   If the user is currently banned, this property is `true`. |
| isEmailVerified | Boolean | Read-only.   Indicates whether the user has a verified email address in their profile.    Available since 2023.1 |
| isNew | Boolean | Read-only.   When `true`, the entity is created in the current transaction. Otherwise, `false`.    Available since 2018.2.42351 |
| isOnline | Boolean | Read-only.   If the user has interacted with YouTrack in any way within the last five minutes.    Available since 2022.1 |
| isSystem | Boolean | Read-only.   When `true`, the user functions as a system user. System users are user accounts utilized for running imports, integrations, and other automations.    Available since 2022.2 |
| language | String | Read-only.   The display language selected in the general settings of the user profile.    Available since 2022.1 |
| login | String | Read-only.   The login of the user. |
| pinnedSavedQueries | Set.<SavedQuery> | Read-only.   Returns pinned by the user saved queries.    Available since 2025.3 |
| registered | Number | Read-only.   The date when the user was registered.    Available since 2024.3 |
| ringId | String | Read-only.   ID of the user in Hub. You can use this ID for operations in Hub, and for matching users between YouTrack and Hub.    Available since 2020.6.3000 |
| teams | Set.<ProjectTeam> | Read-only.   The list of project teams that the user belongs to.    Available since 2025.3 |
| timeZoneId | String | Read-only.   The ID of the local time zone selected in the general settings of the user profile. |
| type | UserType | Read-only.   The user type assigned to the user account for licensing purposes. Possible values include: `UserType.STANDARD\_USER` (a standard user), `UserType.AGENT` (a helpdesk agent), and `UserType.REPORTER` (a helpdesk reporter).    Available since 2026.2 |
| visibleName | String | Read-only.   The full name of the user or the login if the full name is not set. |

## Methods﻿

### findByEmail﻿

static findByEmail(email)

Finds users by email.

Available since 2018.2.41100

**Parameters**

| Name | Type | Description |
| email | String | The email to search for. |

**Return Value**

| Type | Description |
| --- | --- |
| Set.<User> | Users with the specified email. |

### findByExtensionProperties﻿

static findByExtensionProperties(extensionPropertiesQuery)

Searches for User entities with extension properties that match the specified query.

Available since 2024.3.43260

**Parameters**

| Name | Type | Description |
| extensionPropertiesQuery | Object | The extension properties query, defined as a set of key-value pairs representing properties and their corresponding values. |

**Return Value**

| Type | Description |
| --- | --- |
| Set.<User> | The set of User entities that contain the specified extension properties. |

**Example**

{
   property1: "value1",
   property2: "value2"
}

### findByLogin﻿

static findByLogin(login)

Finds a user by login.

**Parameters**

| Name | Type | Description |
| login | String | The login of the user account to search for. |

**Return Value**

| Type | Description |
| --- | --- |
| User | The specified user, or null when a user with the specified login is not found. |

### findUniqueByEmail﻿

static findUniqueByEmail(email)

Finds a user by email.

Available since 2018.2.41100

**Parameters**

| Name | Type | Description |
| email | String | The email of the user account to search for. |

**Return Value**

| Type | Description |
| --- | --- |
| User | The specified user, or null when a user with the specified email is not found or there are multiple users with the specified email. |

### becomes﻿

becomes(fieldName, expected)

Checks whether a field is set to an expected value in the current transaction.

**Parameters**

| Name | Type | Description |
| fieldName | string | The name of the field to check. |
| expected | string | The expected value. |

**Return Value**

| Type | Description |
| --- | --- |
| boolean | If the field is set to the expected value, returns `true`. |

### canBeReadBy﻿

canBeReadBy(fieldName, user)

Checks whether a user has permission to read the field.

**Parameters**

| Name | Type | Description |
| fieldName | string | The name of the field. |
| user | User | The user for whom the permission to read the field is checked. |

**Return Value**

| Type | Description |
| --- | --- |
| boolean | If the user can read the field, returns `true`. |

### canBeWrittenBy﻿

canBeWrittenBy(fieldName, user)

Checks whether a user has permission to update the field.

**Parameters**

| Name | Type | Description |
| fieldName | string | The name of the field. |
| user | User | The user for whom the permission to update the field is checked. |

**Return Value**

| Type | Description |
| --- | --- |
| boolean | If the user can update the field, returns `true`. |

### canLinkIssue﻿

canLinkIssue(issue)

Checks whether the user is permitted to link the specified issue to any other issue.

**Parameters**

| Name | Type | Description |
| issue | Issue | The issue to link. |

**Return Value**

| Type | Description |
| --- | --- |
| Boolean | If the user can link the issue, returns `true`. |

### canUnvoteIssue﻿

canUnvoteIssue(issue)

Checks whether the user is able to remove their vote from the specified issue.

**Parameters**

| Name | Type | Description |
| issue | Issue | The issue to check. |

**Return Value**

| Type | Description |
| --- | --- |
| Boolean | If the user can vote for the issue, returns `true`. |

### canVoteIssue﻿

canVoteIssue(issue)

Checks whether the user is able to vote for the specified issue.

**Parameters**

| Name | Type | Description |
| issue | Issue | The issue to check. |

**Return Value**

| Type | Description |
| --- | --- |
| Boolean | If the user can vote for the issue, returns `true`. |

### getSharedTag﻿

getSharedTag(name)

Returns a tag with the specified name that is shared with but not owned by the user. If such a tag does not exist, a null value is returned.

**Parameters**

| Name | Type | Description |
| name | String | The name of the tag. |

**Return Value**

| Type | Description |
| --- | --- |
| Tag | The tag. |

### getTag﻿

getTag(name, createIfNotExists)

Returns a tag that is visible to the user.

**Parameters**

| Name | Type | Description |
| name | String | The name of the tag. |
| createIfNotExists | Boolean | If `true` and the specified tag does not exist or is not visible to the user and the user has permission to create tags, a new tag with the specified name is created. |

**Return Value**

| Type | Description |
| --- | --- |
| Tag | The tag. |

### hasPermission﻿

hasPermission(permissionKey, project)

Checks whether the user has the specified permission.

Available since 2025.3

**Parameters**

| Name | Type | Description |
| permissionKey | String | The permission key to check. For the complete list of available permission keys, see <https://www.jetbrains.com/help/youtrack/devportal/app-permissions.html>. |
| project | Project | The project to check for the specified permission assignment. If omitted, checks if the user has the global role. |

**Return Value**

| Type | Description |
| --- | --- |
| Boolean | If the user has the permission, returns `true`. |

### hasRole﻿

hasRole(roleName, project)

Checks whether the user is granted the specified role in the specified project. When the project parameter is not specified, checks whether the user has the specified role in any project.

**Parameters**

| Name | Type | Description |
| roleName | String | The name of the role to check for. |
| project | Project | The project to check for the specified role assignment. If omitted, checks if the user has the global role. |

**Return Value**

| Type | Description |
| --- | --- |
| Boolean | If the user is granted the specified role, returns `true`. |

### is﻿

is(fieldName, expected)

Checks whether a field is equal to an expected value.

Available since 2019.2.55603

**Parameters**

| Name | Type | Description |
| fieldName | string | The name of the field to check. |
| expected | string | The expected value. |

**Return Value**

| Type | Description |
| --- | --- |
| boolean | If the field is equal to the expected value, returns `true`. |

### isChanged﻿

isChanged(fieldName)

Checks whether the value of a field is changed in the current transaction.

**Parameters**

| Name | Type | Description |
| fieldName | string | The name of the field to check. |

**Return Value**

| Type | Description |
| --- | --- |
| boolean | If the value of the field is changed in the current transaction, returns `true`. |

### isInGroup﻿

isInGroup(groupName)

Checks whether the user is a member of the specified group.

**Parameters**

| Name | Type | Description |
| groupName | String | The name of the group to check for. |

**Return Value**

| Type | Description |
| --- | --- |
| Boolean | If the user is a member of the specified group, returns `true`. |

### isVotedForIssue﻿

isVotedForIssue(issue)

Check whether the user has voted for the specified issue.

Available since 2025.3

**Parameters**

| Name | Type | Description |
| issue | Issue | The issue to check the vote is added. |

**Return Value**

| Type | Description |
| --- | --- |
| Boolean | If the user has voted for the issue, returns `true`. |

### isWatchingIssue﻿

isWatchingIssue(issue)

Checks whether the current user is added as a watcher for the specified issue.

Available since 2025.3

**Parameters**

| Name | Type | Description |
| issue | Issue | The issue to check for the watcher assignment. |

**Return Value**

| Type | Description |
| --- | --- |
| Boolean | If the user is added as a watcher for the issue, returns `true`. |

### notify﻿

notify(subject, body, ignoreNotifyOnOwnChangesSetting, project)

Sends an email notification to the email address that is set in the user profile.

**Parameters**

| Name | Type | Description |
| subject | String, JsonForUserNotify | The subject line of the email notification. Alternatively, pass a JSON specified by JsonForUserNotify |
| body | String | The message text of the email notification. |
| ignoreNotifyOnOwnChangesSetting | Boolean | If `false`, the message is not sent when changes are performed on behalf of the current user. Otherwise, the message is sent anyway. |
| project | Project | When set, the email address that is used as the 'From' address for the specified project is used to send the message. |

### notifyOnCase﻿

notifyOnCase(caseName, parameters, projectDocument)

Sends a notification to all notification channels configured for the user.

Available since 2023.1

**Parameters**

| Name | Type | Description |
| caseName | string | The name of the notification case as seen on the notification templates configuration page. |
| parameters | Object | A JSON object that provides required parameters for the notification to render. Particular parameters depend on the notification case. |
| projectDocument | Issue, Article | An issue or an article that this notification is about. The difference between providing it as a separately vs. passing it among other parameters is that in the former case the notification will be merged with other notifications on that issue/article. |

### oldValue﻿

oldValue(fieldName)

Returns the previous value of a single-value field before an update was applied. If the field is not changed in the transaction, returns null.

**Parameters**

| Name | Type | Description |
| fieldName | string | The name of the field. |

**Return Value**

| Type | Description |
| --- | --- |
| Object | If the field is changed in the current transaction, the previous value of the field. Otherwise, null. |

### required﻿

required(fieldName, message)

Asserts that a value is set for a field. If a value for the required field is not set, the specified message is displayed in the user interface.

**Parameters**

| Name | Type | Description |
| fieldName | string | The name of the field to check. |
| message | string | The message that is displayed to the user that describes the field requirement. |

### sendMail﻿

sendMail(subject, body)

Sends an email notification to the email address that is set in the user profile. An alias for notify(subject, body, true).

**Parameters**

| Name | Type | Description |
| subject | String | The subject line of the email notification. |
| body | String | The message text of the email notification. |

### unvoteIssue﻿

unvoteIssue(issue)

Removes a vote on behalf of the user from the issue, if allowed.

**Parameters**

| Name | Type | Description |
| issue | Issue | The issue from which the vote is removed. |

### unwatchArticle﻿

unwatchArticle(article)

Removes the current user from the list of watchers for the article (removes the `Star` tag).

Available since 2023.1

**Parameters**

| Name | Type | Description |
| article | BaseArticle | The article from which the user is removed as a watcher. |

### unwatchIssue﻿

unwatchIssue(issue)

Removes the current user from the list of watchers for the issue (removes the `Star` tag).

**Parameters**

| Name | Type | Description |
| issue | Issue | The issue from which the user is removed as a watcher. |

### voteIssue﻿

voteIssue(issue)

Adds a vote on behalf of the user to the issue, if allowed.

**Parameters**

| Name | Type | Description |
| issue | Issue | The issue to which the vote is added. |

### was﻿

was(fieldName, expected)

Checks whether a field was equal to an expected value prior to the current transaction.

Available since 2019.2.55603

**Parameters**

| Name | Type | Description |
| fieldName | string | The name of the field to check. |
| expected | string | The expected value. |

**Return Value**

| Type | Description |
| --- | --- |
| boolean | If the field was equal to the expected value, returns `true`. |

### watchArticle﻿

watchArticle(article)

Adds the current user to the article as a watcher (adds the `Star` tag).

Available since 2023.1

**Parameters**

| Name | Type | Description |
| article | BaseArticle | The article to which the user is added as a watcher. |

### watchIssue﻿

watchIssue(issue)

Adds the current user to the issue as a watcher (adds the `Star` tag).

**Parameters**

| Name | Type | Description |
| issue | Issue | The issue to which the user is added as a watcher. |

- [User](/help/youtrack/devportal/v1-User.html)
- [Properties](/help/youtrack/devportal/v1-User.html#properties)
- [Methods](/help/youtrack/devportal/v1-User.html#methods)
- [findByEmail](/help/youtrack/devportal/v1-User.html#findByEmail)
- [findByExtensionProperties](/help/youtrack/devportal/v1-User.html#findByExtensionProperties)
- [findByLogin](/help/youtrack/devportal/v1-User.html#findByLogin)
- [findUniqueByEmail](/help/youtrack/devportal/v1-User.html#findUniqueByEmail)
- [becomes](/help/youtrack/devportal/v1-User.html#becomes)
- [canBeReadBy](/help/youtrack/devportal/v1-User.html#canBeReadBy)
- [canBeWrittenBy](/help/youtrack/devportal/v1-User.html#canBeWrittenBy)
- [canLinkIssue](/help/youtrack/devportal/v1-User.html#canLinkIssue)
- [canUnvoteIssue](/help/youtrack/devportal/v1-User.html#canUnvoteIssue)
- [canVoteIssue](/help/youtrack/devportal/v1-User.html#canVoteIssue)
- [getSharedTag](/help/youtrack/devportal/v1-User.html#getSharedTag)
- [getTag](/help/youtrack/devportal/v1-User.html#getTag)
- [hasPermission](/help/youtrack/devportal/v1-User.html#hasPermission)
- [hasRole](/help/youtrack/devportal/v1-User.html#hasRole)
- [is](/help/youtrack/devportal/v1-User.html#is)
- [isChanged](/help/youtrack/devportal/v1-User.html#isChanged)
- [isInGroup](/help/youtrack/devportal/v1-User.html#isInGroup)
- [isVotedForIssue](/help/youtrack/devportal/v1-User.html#isVotedForIssue)
- [isWatchingIssue](/help/youtrack/devportal/v1-User.html#isWatchingIssue)
- [notify](/help/youtrack/devportal/v1-User.html#notify)
- [notifyOnCase](/help/youtrack/devportal/v1-User.html#notifyOnCase)
- [oldValue](/help/youtrack/devportal/v1-User.html#oldValue)
- [required](/help/youtrack/devportal/v1-User.html#required)
- [sendMail](/help/youtrack/devportal/v1-User.html#sendMail)
- [unvoteIssue](/help/youtrack/devportal/v1-User.html#unvoteIssue)
- [unwatchArticle](/help/youtrack/devportal/v1-User.html#unwatchArticle)
- [unwatchIssue](/help/youtrack/devportal/v1-User.html#unwatchIssue)
- [voteIssue](/help/youtrack/devportal/v1-User.html#voteIssue)
- [was](/help/youtrack/devportal/v1-User.html#was)
- [watchArticle](/help/youtrack/devportal/v1-User.html#watchArticle)
- [watchIssue](/help/youtrack/devportal/v1-User.html#watchIssue)

[TextProjectCustomField](jetbrains__com__help__youtrack__devportal__v1-textprojectcustomfield.md)[UserAttributes](jetbrains__com__help__youtrack__devportal__v1-userattributes.md)

- Privacy & Security
- Terms Of Use
- Trademarks
- Legal

Copyright © 2000–2026 JetBrains s.r.o.
