I'm trying to create users on the fly via SOAP to my Dev org. I'm able create them and see them in setup. I set a role in addition to calling setUserPassword
.
I'm setting the following fields in my SOAP request.
- callCenterId
- alias
- firstName
- lastName
- emailEncoding
- userPreferencesLightningExperiencePreferred
- userPreferencesPreviewLightning
- userPreferencesHideLightningMigrationModal
- languageLocaleKey
- localSidKey
- Standard User profile via profileId
- timeZoneSidKey
- userName
- userRoleId
- isActive
I'm not able to log the user in reliably thru the UI, just that the username/password were incorrect. Is there some sort of governor that controls the users from logging in right after creation? It looks like there was a wait period of 10 minutes after creation before I could logon. I looked at the logs and there was no record of the logon attempt between the call to create the user and when the user could logon.
It seemed to work after saving the user in setup again (occasionally). Is there some property that I'm not setting?
login.salesforce.com
for production and developer edition orgs. For Sandboxes usetest.salesforce.com
. These will redirect you to the correct pod/instance where your org is hosted.