User

Represents a user in your organization.

Supported Calls

create(), update(), query(), search(), retrieve(), getUpdated(), describeSObjects(), upsert()

Special Access Rules

Fields

Field Field Type Field Properties Description
AboutMe string Create

Filter

Nillable

Update

Information about the user, such as areas of interest or skills.
AccountId reference Filter

Nillable

ID of the Account associated with a Customer Portal user. For information on IDs, seeID Field Type.

This field is blank for Salesforce.com users.

Alias string Create

Filter

Update

Required. The user’s alias. For example, “jsmith.”
CallCenterId reference Create

Filter

Nillable

Update

If Salesforce CRM Call Center is enabled, represents the call center to which this user is assigned.
City string Create

Filter

Nillable

Update

The city associated with the user.
CommunityNickname string Create

Filter

Nillable

Update

Name used to identify this user in the Community application, which includes the ideas and answers features.
CompanyName string Create

Filter

Nillable

Update

The name of the user’s company.
ContactId reference Create

Filter

ID of the Contact associated with this account. The contact must have a value in the AccountID field or an error occurs. For information on IDs, see ID Field Type.
Country string Create

Filter

Nillable

Update

The country associated with the user.
CurrentStatus string Create

Filter

Nillable

Update

A comment on what the user is currently doing.
Note
If you are using Feeds and you update this field, the API automatically adds a post to the UserFeed.
DefaultCurrencyIsoCode picklist Create

Filter

Nillable

Restricted picklist

Update

The user's default currency setting for new records. For example, a user in France could have a DefaultCurrencyIsoCode set to Euros, and that would be their default currency in the application. However, the User object could have currency custom fields stored in a different currency.

Only applicable for organizations that use multiple currencies.

For more information, see CurrencyIsoCode

DefaultDivision picklist Create

Defaulted on create

Filter

Restricted picklistUpdate
The user’s default division. Only applicable if divisions are enabled for your organization. For more information, see the Salesforce.com online help.
DelegatedApproverId reference Create

Filter

Nillable

Update

Id of the user who is a delegated approver for this user.
Department string Create

Filter

Nillable

Update

The company department associated with the user.
Division string Create

Filter

Nillable

Update

The division associated with this user, similar to Department and unrelated to DefaultDivision.
Email email Create

Filter

Update

Required. The user’s email address.
EmailEncodingKey picklist Create

Filter

Restricted picklist

Update

Required. The email encoding for the user, such as “ISO-8859-1” or “UTF-8”.
EmployeeNumber string Create

Filter

Nillable

Update

The user’s employee number.
Extension phone Create

Filter

Nillable

Update

The user’s phone extension number.
Fax phone Create

Filter

Nillable

Update

The user’s fax number.
FederationIdentifier string Create

Filter

Indicates the value that must be listed in the Subject element of a Security Assertion Markup Language (SAML) IDP certificate to authenticate the user for a client application using single sign-on with Salesforce.com. This value must be specified if the SAML User ID Type is Assertion contains Federation ID from the User object. Otherwise, this field cannot be edited.
FirstName string Create

Filter

Nillable

Update

The user’s first name.
ForecastEnabled boolean Create

Defaulted on create

Filter

Update

Indicates whether the user is enabled as a Forecast Manager (true) or not (false) in customizable forecasting. Forecast managers see forecast rollups from users below them in the forecast hierarchy.
IsActive boolean Create

Defaulted on create

Filter

Update

Indicates whether the user has access to log in (true) or not (false). You can modify a User's active status from the Salesforce.com user interface or via the API.
IsPartner boolean Defaulted on create

Filter

Indicates whether the user is a partner who has access to the PRM Portal (true) or not (false). This field is not available for release 9.0 and later. Instead, use UserType with the value PRM.
IsPortalEnabled boolean Defaulted on create

Filter

Update

Indicates whether the user has access to the partner portal or Customer Portal (true) or not (false).
IsPortalSelfRegistered boolean Defaulted on create

Filter

Indicates whether the user is a Customer Portal user who self-registered for your organization's Customer Portal (true) or not (false). This field is not available for release 9.0 and earlier.

For more information on the Customer Portal and self-registration, see Enabling Customer Portal Login and Settings in the Salesforce.com online help.

LanguageLocaleKey picklist Create

Filter

Restricted picklist

Update

Required. The user’s language, such as “French” or “Chinese (Traditional).” Label is Language.
LastLoginDate dateTime Filter

Nillable

The date and time when the user last logged in.
LastName string Create

Filter

Update

Required. The user’s last name.
LocaleSidKey picklist Create

Filter

Restricted picklist

Update

Required. This field is a restricted picklist field. The value of the field affects formatting and parsing of values, especially numeric values, in the user interface. It does not affect the API.

The field values are named according to the language, and country if necessary, using two-letter ISO codes. The set of names is based on the ISO standard. It can often be more convenient to manually set a user’s locale in the Salesforce.com user interface, and then use that value for inserting or updating other users via the API.

Manager picklist Create

Filter

Restricted picklist

Update

User lookup field used to select the user's manager. This establishes a hierarchical relationship, preventing you from selecting a user that directly or indirectly reports to itself.
MobilePhone phone Create

Filter

Nillable

Update

The user’s mobile or cellular phone number.
Name string Filter Concatenation of FirstName and LastName. Limited to 121 characters.
OfflineTrialExpirationDate dateTime Filter

Nillable

The date and time when the user’s Connect Offline trial expires.
Phone phone Create

Filter

Nillable

Update

The user’s phone number.
PortalRole picklist Create

Filter

Nillable

The role of the user in the Customer Portal (either Executive, Manager, User, or PersonAcount).

Prior to API version 16.0, you could set this field to null and Salesforce.com automatically included a portal role. In API version 16.0 and above, when you set this field to null, Salesforce.com does not automatically include a portal role.

PostalCode string Create

Filter

Nillable

Update

The user’s postal or ZIP code. Label is Zip/Postal Code.
ProfileId reference Create

Filter

Update

Required. ID of the user’s Profile. Use this value to cache metadata based on profile. For information on IDs, see ID Field Type. In earlier releases, this was RoleId.
ReceivesAdminInfoEmails boolean Create

Defaulted on create

Filter

Update

Indicates whether the user receives email for administrators from salesforce.com (true) or not (false).
ReceiveInfoEmails boolean Create

Defaulted on create

Filter

Update

Indicates whether the user receives informational email from salesforce.com (true) or not (false).
State string Create

Filter

Nillable

Update

The state associated with the User.
Street textarea Create

Filter

Nillable

Update

The street address associated with the User.
TimeZoneSidKey picklist Create

Filter

Restricted picklist

Update

Required. This field is a restricted picklist field. A User’s time zone affects the offset used when displaying or entering times in the user interface. However, the API does not use a User’s time zone when querying or setting values.

Values for this field are named using region and key city, according to ISO standards. It can often be more convenient to manually set a User’s time zone in the user interface, and then use that value for creating or updating other Users via the API.

Title string Create

Filter

Nillable

Update

The user’s business title, such as “Vice President.”
Username string Create

Filter

Update

Required. Contains the name that a user enters to log into the API or the Salesforce.com user interface. The value for this field must be in the form of an email address. It must also be unique across all Salesforce.com instances. If you try to create() or update() a User with a duplicate value for this field, the operation is rejected.

Each inserted User also counts as a license in Salesforce.com. Every organization has a maximum number of licenses. If you attempt to exceed the maximum number of licenses by inserting User records, the create() call is rejected.

UserPermissionsCallCenterAutoLogin boolean Create

Update

Required if Salesforce CRM Call Center is enabled. Indicates whether the user is enabled to use the auto login feature of the call center (true) or not (false).
UserPermissionsMarketingUser boolean Create

Update

Required. Indicates whether the user is enabled to manage campaigns in the online application (true) or not (false). Label is Marketing User.
UserPermissionsMobileUser boolean Create

Update

Indicates whether the user is allocated one Salesforce Mobile license (true) or not (false). Label is Mobile User. The Salesforce Mobile license grants the user access to the Salesforce Mobile application on supported mobile devices.
UserPermissionsOfflineUser boolean Create

Update

Required. Indicates whether the user is enabled to use Offline Edition (true) or not (false). Label is Offline User.
UserPermissionsSFContentUser boolean Create

Update

Indicates whether the user is allocated one Salesforce CRM Content User License (true) or not (false). Label is Salesforce CRM User. The Salesforce CRM Content User license grants the user access to the Salesforce CRM Content application.
UserPermissionsWirelessUser boolean Create

Update

Required if the Wireless permission is enabled for your organization. Indicates whether the user is enabled to use Wireless Edition (true) or not (false). Label is Wireless User.
Note
As of November 2005, Salesforce.com Wireless Edition is no longer available for purchase. If you are a Professional Edition customer and purchased Wireless Edition prior to November 7, 2005 or are an Enterprise Edition customer who has signed or renewed your Salesforce.com contract prior to November 7, 2005, you may continue using Wireless Edition through the end of your existing contract term.
UserPreferencesActivityRemindersPopup boolean Filter

Nillable

When true, a reminder popup window automatically opens when an activity reminder is due. Corresponds to the Trigger alert when reminder comes due checkbox at Setup | My Personal Information | Reminders in the Salesforce.com user interface. See “Customizing Activity Reminders” in the Salesforce.com online help.
UserPreferencesApexPagesDeveloperMode boolean Filter

Nillable

When true, indicates the user has enabled developer mode for editing Visualforce pages and controllers.
UserPreferencesDisableAutoSubForFeeds boolean Update When false, the user automatically subscribes to feeds for any objects that they create.
UserPreferencesEventRemindersCheckboxDefault boolean Filter

Nillable

When true, a reminder popup is automatically set on the user's events. Corresponds to the By default, set reminder on Events to... checkbox Setup | My Personal Information | Reminders in the online application. This field is related to UserPreference. Also, see Customizing Activity Reminders in the Salesforce.com online help.
UserPreferencesTaskRemindersCheckboxDefault boolean Filter

Nillable

When true, a reminder popup is automatically set on the user's tasks. Corresponds to the By default, set reminder on Tasks to... checkbox at Setup | My Personal Information | Reminders in the online application. This field is related to UserPreference. Also, see Customizing Activity Reminders in the Salesforce.com online help.
UserPreferencesReminderSoundOff boolean Filter

Nillable

When true, a sound automatically plays when an activity reminder is due. Corresponds to the Play a reminder sound checkbox at Setup | My Personal Information | Reminders in the online application. See Customizing Activity Reminders in the Salesforce.com online help.
UserRoleId reference Create

Filter

Nillable

Update

ID of the user’s UserRole. Label is Role ID.
UserType picklist Filter

Nillable

Restricted picklist

The category of user license. Each UserType is associated with one or more UserLicense records. Each UserLicense is associated with one or more profiles. In API version 10.0 and later, valid values include:
  • Standard: Salesforce.com user license. This user type also includes Salesforce.com Platform and Salesforce.com Platform One user licenses. Label is Standard.
  • PowerPartner: PRM user whose access is limited because he or she is a partner and typically accesses the application through a partner portal. Label is Partner.
  • CSPLitePortal: user whose access is limited because he or she is an organization's customer and accesses the application through aCustomer Portal. Label is High Volume Portal.
  • CustomerSuccess: user whose access is limited because he or she is an organization's customer and accesses the application through a Customer Portal. Label is Customer Portal User.
  • PowerCustomerSuccess: user whose access is limited because he or she is an organization's customer and accesses the application through a Customer Portal. Label is Customer Portal Manager.

    Users with this license type can view and edit data they directly own or data owned by or shared with users below them in the Customer Portal role hierarchy.

WirelessEmail email Create

Filter

Nillable

Update

Wireless email address associated with this user. For use with Salesforce.com Wireless Edition. This field is available only if the Wireless and Email permissions are enabled for your organization.
Note
As of November 2005, Salesforce.com Wireless Edition is no longer available for purchase. If you are a Professional Edition customer and purchased Wireless Edition prior to November 7, 2005 or are an Enterprise Edition customer who has signed or renewed your Salesforce.com contract prior to November 7, 2005, you may continue using Wireless Edition through the end of your existing contract term.

Usage

Use this object to query information about users and to provision and modify users in your organization. Unlike other objects, the records in the User table represent actual users—not data owned by users. All Users have access to use query() or describeSObjects() with User objects.

Deactivate Users

You cannot delete() a User in the Salesforce.com user interface or the API. You can deactivate a User in the Salesforce.com user interface; and you can deactivate or disable a Customer Portal or partner portalUser in the Salesforce.com user interface or the API. Because a User can never be deleted, we recommend that you exercise caution when creating them.
Note
See Disabling and Deactivating Portal Users in the Salesforce.com online help for information on the differences between disabling and deactivating portal users.

Passwords

For security reasons, you cannot query User passwords via the API or the Salesforce.com user interface. However, the API allows you to set and “reset” User passwords using the setPassword() and resetPassword() calls. The password lockout status and the ability to reset the User locked-out status is not available via the API. You must check and reset the User password lockout status using the Salesforce.com user interface.

See Also:
getUserInfo()
create()
update()
query()
search()
retrieve()
upsert()
getUpdated()
getDeleted()
describeSObjects()
Frequently-Occurring Fields
UserRole
UserLicense
© Copyright 2000-2010 salesforce.com, inc. All rights reserved.
Various trademarks held by their respective owners.