Skip to main content

User object

A user object contains information about a Slack workspace user.

If you develop for an Enterprise organization, there's a lot to consider about the most important field in a user object: the id or user_id. Learn more about global IDs and migration.

Example

{
"user": {
"id": "U123ABC456",
"team_id": "T123ABC456",
"name": "sherlock",
"deleted": false,
"color": "99a949",
"real_name": "Sherlock Holmes",
"tz": "Europe/London",
"tz_label": "Greenwich Mean Time",
"tz_offset": 0,
"profile": {
"title": "Senior Detective",
"phone": "(000) 000-0000",
"skype": "",
"real_name": "Sherlock Holmes",
"real_name_normalized": "Sherlock Holmes",
"display_name": "sherlock",
"display_name_normalized": "sherlock",
"fields": {
"Xf111AAA111": {
"value": "1 dog: Sherlock Bones",
"alt": ""
},
"Xf222BBB222": {
"value": "no tree nuts!",
"alt": ""
}
},
"status_text": "elementary, my dear watson ",
"status_emoji": ":thinking-face:",
"status_emoji_display_info": [
{
"emoji_name": "thinking-face",
"display_url": "https://emoji.slack-edge.com/T123ABC456/thinking-face/123...abc.png"
}
],
"status_expiration": 0,
"avatar_hash": "b187f5128ba4",
"start_date": "2015-12-25",
"image_original": "https://avatars.slack-edge.com/2021-10-21/..._...__original.jpg",
"is_custom_image": true,
"email": "sholmes@example.com",
"pronouns": "they/them",
"huddle_state": "default_unset",
"huddle_state_expiration_ts": 0,
"first_name": "Sherlock",
"last_name": "Holmes",
"image_24": "https://avatars.slack-edge.com/2021-10-21/..._...__24.jpg",
"image_32": "https://avatars.slack-edge.com/2021-10-21/..._...__32.jpg",
"image_48": "https://avatars.slack-edge.com/2021-10-21/..._...__48.jpg",
"image_72": "https://avatars.slack-edge.com/2021-10-21/..._...__72.jpg",
"image_192": "https://avatars.slack-edge.com/2021-10-21/..._...__192.jpg",
"image_512": "https://avatars.slack-edge.com/2021-10-21/..._...__512.jpg",
"image_1024": "https://avatars.slack-edge.com/2021-10-21/..._...__1024.jpg",
"status_text_canonical": "",
"team": "T0123ABC456"
},
"is_admin": false,
"is_owner": false,
"is_primary_owner": false,
"is_restricted": false,
"is_ultra_restricted": false,
"is_bot": false,
"is_app_user": false,
"updated": 1675264590,
"is_email_confirmed": true,
"who_can_share_contact_card": "EVERYONE",
"enterprise_user": {
"id": "U123ABC456",
"enterprise_id": "E123ABC456",
"enterprise_name": "Sherlock Holmes Detective Agency",
"is_admin": false,
"is_owner": false,
"is_primary_owner": false,
"teams": [
"T123ABC456",
"T789DEF000"
]
}
}
}

Common fields

The composition of user objects can vary greatly depending on the API being used, or the context of each Slack workspace. Data that has not been supplied may not be present at all, may be null, or may contain an empty string. One example where the profile information varies is getting data for a user connected through Slack Connect; an example of that type of user object can be found in the External members section of the Slack Connect page.

Therefore, consider the following a list of potential user object fields you might encounter.

FieldTypeDescription
always_activeBooleanIndicates that a bot user is set to be constantly active in presence status.
colorStringUsed in some clients to display a special username color.
deletedBooleanThis user has been deactivated when the value of this field is true. Otherwise the value is false, or the field may not appear at all.
enterprise_idString (enterprise_id)Enterprise org ID (enterprise variant top-level field).
enterprise_nameStringEnterprise org name (enterprise variant top-level field).
enterprise_userObjectAn object containing info related to an Enterprise org user. See our Enterprise org documentation for more detail.
enterprise_user.enterprise_idStringA unique ID for the Enterprise organization this user belongs to.
enterprise_user.enterprise_nameStringA display name for the Enterprise organization.
enterprise_user.idStringThis user's ID - some Enterprise org users have a kind of dual identity — a local, workspace-centric user ID as well as a org-wise user ID, called the Enterprise user ID. In most cases these IDs can be used interchangeably, but when it is provided, we strongly recommend using this Enterprise user id over the root level user id field.
enterprise_user.is_adminBooleanIndicates whether the user is an Admin of the Enterprise organization.
enterprise_user.is_ownerBooleanIndicates whether the user is an Owner of the Enterprise organization.
enterprise_user.is_primary_ownerBooleanWhether the user is the primary owner of the enterprise.
enterprise_user.teamsString[]An array of workspace IDs that are in the Enterprise organization.
first_loginIntegerUnix timestamp of user's first login.
has_2faBooleanDescribes whether two-factor authentication is enabled for this user. Only visible if the user executing the call is an admin.
idStringIdentifier for this workspace user. It is unique to the workspace containing the user. Use this field together with team_id as a unique key when storing related data or when specifying the user in API requests. We recommend considering the format of the string to be an opaque value, and not to rely on a particular structure.
is_adminBooleanIndicates whether the user is an Admin of the current workspace.
is_agentforce_botBooleanWhether this is an Agentforce bot user.
is_app_userBooleanIndicates whether the user is an authorized user of the calling app.
is_botBooleanIndicates whether the user is actually a bot user. Bleep bloop. Note that Slackbot is special, so is_bot will be false for it.
is_email_confirmedBooleanWhether the user's email address has been confirmed.
is_externalBooleanWhether the user is external to the workspace.
is_forgottenBooleanWhether the user has been GDPR-forgotten.
is_invited_userBooleanOnly present (and always true) when a user has been invited but has not yet signed in. Once the user signs in, this field is no longer present.
is_ownerBooleanIndicates whether the user is an Owner of the current workspace.
is_primary_ownerBooleanIndicates whether the user is the Primary Owner of the current workspace.
is_profile_only_userBooleanWhether this is a profile-only user (enterprise variant).
is_restrictedBooleanIndicates whether or not the user is a guest user. Use in combination with the is_ultra_restricted field to check if the user is a single-channel guest user.
is_strangerBooleanIf true, this user belongs to a different workspace than the one associated with your app's token, and isn't in any shared channels visible to your app. If false (or this field is not present), the user is either from the same workspace as associated with your app's token, or they are from a different workspace, but are in a shared channel that your app has access to. Read our shared channels docs for more detail.
is_ultra_restrictedBooleanIndicates whether or not the user is a single-channel guest.
is_workflow_botBooleanWhether this is a workflow bot user.
localeStringContains a IETF language code that represents this user's chosen display language for Slack clients. Useful for localizing your apps.
manual_presenceStringUser's manually-set presence value.
nameStringDon't use this. It once indicated the preferred username for a user, but that behavior has fundamentally changed since.
presenceStringUser's current presence status (e.g. "active", "away").
profileObjectThe profile object contains the default fields of a user's workspace profile. A user's custom profile fields may be discovered using users.profile.get.
real_nameStringUser's full real name (top-level copy from profile).
restricted_user_typeIntegerNumeric type classification for restricted/guest users.
suspendedBooleanWhether the user account is suspended (non-enterprise variant).
teamString (team_id)Workspace ID (non-enterprise variant).
team_idString (team_id)Workspace ID the user belongs to.
team_profileObjectTeam profile fields and sections definitions.
teamsArray of team_idWorkspace IDs the user belongs to (enterprise variant).
two_factor_typeEnum (String)Indicates the type of two-factor authentication in use. Only present if has_2fa is true. The value will be either app or sms.
tzStringA human-readable string for the geographic timezone-related region this user has specified in their account.
tz_labelStringDescribes the commonly used name of the tz timezone.
tz_offsetNumberIndicates the number of seconds to offset UTC time by for this user's tz. Changes silently if changed due to daylight savings.
updatedNumberA Unix timestamp indicating when the user object was last updated.
who_can_share_contact_cardStringContact card sharing permission setting.

Profile fields

The following fields are the default fields of a user's workspace profile. A user may have additional custom fields, though! Use users.profile.get to view all the user's profile fields.

FieldTypeDescription
always_activeBooleanIndicates that a bot user is set to be constantly active in presence status.
api_app_idString (app_id)App ID associated with this bot/app user.
avatar_hashStringHash of the user's profile image.
bot_idString (bot_id)Bot ID if this is a bot user profile.
display_nameStringThe display name the user has chosen to identify themselves by in their workspace profile. Do not use this field as a unique identifier for a user, as it may change at any time. Instead, use id and team_id in concert.
display_name_normalizedStringThe display_name field, but with any non-Latin characters filtered out.
emailStringA valid email address. It cannot have spaces, and it must have an @ and a domain. It cannot be in use by another member of the same team. Changing a user's email address will send an email to both the old and new addresses, and also post a slackbot to the user informing them of the change. This field can only be changed by admins for users on paid teams.
fieldsObjectAll the custom profile fields for the user.
first_nameStringThe user's first name. The name slackbot cannot be used. Updating first_name will update the first name within real_name.
guest_expiration_tsInteger or nullUnix timestamp when the guest account expires.
guest_invited_byString or nullUser ID of who invited this guest.
huddle_stateEnumUser's current huddle status. Possible values: default_unset, in_a_huddle, available_for_huddle.
huddle_state_call_idString or nullCall ID of the active huddle.
huddle_state_channel_idString or nullChannel ID of the active huddle.
huddle_state_expiration_tsIntegerWhen the huddle state expires.
image_*StringThese various fields will contain https URLs that point to square ratio, web-viewable images (GIFs, JPEGs, or PNGs) that represent different sizes of a user's profile picture.
image_24String (URI) or null24px profile image URL.
image_1024String (URI) or null1024px profile image URL.
image_originalString (URI) or nullOriginal profile image URL.
is_agentforce_botBooleanWhether this is an Agentforce bot.
is_app_userBooleanWhether this is an app user (profile-level copy).
is_custom_imageBooleanWhether the user uploaded a custom profile image.
is_restrictedBoolean or nullGuest user status (profile-level copy).
is_sidekick_botBooleanWhether this is a Sidekick bot.
is_ultra_restrictedBoolean or nullSingle-channel guest status (profile-level copy).
last_avatar_image_hashStringHash of the last avatar image.
last_nameStringThe user's last name. The name slackbot cannot be used. Updating last_name will update the second name within real_name.
memberships_countIntegerNumber of channel memberships.
nameString or nullName (profile-level copy).
phoneStringThe user's phone number, in any format.
pronounsStringThe pronouns the user prefers to be addressed by.
real_nameStringThe user's first and last name. Updating this field will update first_name and last_name. If only one name is provided, the value of last_name will be cleared.
real_name_normalizedStringThe real_name field, but with any non-Latin characters filtered out.
restricted_user_typeInteger or nullNumeric restricted user type (profile-level copy).
skypeStringA shadow from a bygone era. It will always be an empty string and cannot be set otherwise.
start_dateStringThe date the person joined the organization. Only available if Slack Atlas is enabled.
status_clear_on_focus_endBooleanWhether to clear status when focus mode ends.
status_emojiStringThe displayed emoji that is enabled for the Slack team, such as :train:.
status_emoji_display_infoArray of objectsRich emoji display info (each has emoji_name, optional display_alias, display_url, unicode).
status_expirationIntegerThe Unix timestamp of when the status will expire. Providing 0 or omitting this field results in a custom status that will not expire.
status_textStringThe displayed text of up to 100 characters. We strongly encourage brevity.
status_text_canonicalString or nullCanonical/system status text.
teamStringThe ID of the team the user is on.
titleStringThe user's title.
updatedIntegerProfile last updated timestamp.
user_idStringUser ID (profile-level copy).
usernameString or nullUsername.
who_can_share_contact_cardStringContact card sharing permission.
Accessing Email Addresses

The users:read.email OAuth scope is now required to access the email field in user objects returned by the users.list and users.info web API methods. users:read is no longer a sufficient scope for this data field. Learn more.