Skip to content
atlassian-dc-mcp
Esc
↑↓navigate↵open⌘Jpreview

Find users by username

Finds users.

GET/api/2/user/search
Authorization
AuthorizationBasic auth · headerrequired

In order to use basic authorization, provide username:password Base64 encoded in the 'Authorization' header.

or
AuthorizationBearer token · headerrequired

Personal Access Token — Administration > Profile > Personal Access Tokens

AuthorizationBasic auth · headerrequired

In order to use basic authorization, provide username:password Base64 encoded in the 'Authorization' header.

Query parameters
includeInactiveboolean

If true, then inactive users are included in the results (default false)

maxResultsinteger<int32>

The maximum number of users to return (defaults to 50). The maximum allowed value is 100 (The combination of maxResults and startAt is limited to the first 100 results). If you specify a value that is higher than this number, your search results will be truncated. If you send a request with startAt=98 and maxResults=20, it will only return 2 users.

includeActiveboolean

If true, then active users are included in the results (default true)

startAtinteger<int32>

The index of the first user to return (0-based). Please note that the startAt parameter will be deprecated in a future release of Jira 10.3.x

usernamestring

A query string used to search username, name or e-mail address

Responses
200

Returns a list of users.

activeboolean
applicationRolesSimpleListWrapperApplicationRoleBean
Show properties
callbackListWrapperCallbackApplicationRoleBean
maxResultsinteger<int32>
pagingCallbackListWrapperCallbackApplicationRoleBean
sizeinteger<int32>
avatarUrlsobject
deletedboolean
displayNamestring
emailAddressstring
expandstring
groupsSimpleListWrapperGroupJsonBean
Show properties
callbackListWrapperCallbackGroupJsonBean
maxResultsinteger<int32>
pagingCallbackListWrapperCallbackGroupJsonBean
sizeinteger<int32>
keystring
lastLoginTimestring
localestring
namestring
selfstring<uri>
timeZonestring
400

Returned if an invalid parameter value was provided with more details in the response body.

401

Returned if the current user is not authenticated.

404

Returned if the requested user is not found.

Try it
Server
Authorization
Parameters
Request
curl -X GET 'http://jira.example.com/rest/api/2/user/search' \
  -H 'Authorization: Basic YOUR_CREDENTIALS' \
  -H 'Accept: application/json'
Response
{
  "active": true,
  "applicationRoles": [
    "jira-core",
    "jira-admin",
    "important"
  ],
  "avatarUrls": {
    "48x48": "http://www.example.com/jira/secure/useravatar?size=large&ownerId=fred",
    "24x24": "http://www.example.com/jira/secure/useravatar?size=small&ownerId=fred",
    "16x16": "http://www.example.com/jira/secure/useravatar?size=xsmall&ownerId=fred",
    "32x32": "http://www.example.com/jira/secure/useravatar?size=medium&ownerId=fred"
  },
  "deleted": false,
  "displayName": "Fred F. User",
  "emailAddress": "fred@example.com",
  "expand": "string",
  "groups": {
    "callback": {},
    "maxResults": 0,
    "pagingCallback": {},
    "size": 0
  },
  "key": "JIRAUSER10100",
  "lastLoginTime": "2023-08-30T16:37:01+1000",
  "locale": "en_AU",
  "name": "fred",
  "self": "http://www.example.com/jira/rest/api/2.0/user?username=fred",
  "timeZone": "Australia/Sydney"
}

Was this page helpful?