1. How to create users in Salesforce withHow to create users in Salesforce with
AnypointAnypoint
By Vamsi Krishna MBy Vamsi Krishna M
2. ●
Create an empty project in Anypoint Studio.
●
Now we need to use the Transformers and Connectors of this list:
– HTTP
– Salesforce
– DataMapper
– XML to JSON
●
Connect them in the order of the last list.
3. ●
We need to configure the connectors, first HTTP Connector:
– In the HTTP Connector options, create a listener:
– Go the the Basic Setting and type on path /Salesforce:
– You should see your Http Conector like this:
4. ●
Configure the Salesforce Connector, in my case i use the Basic
Configuration in Connector Configuration and these are the settings to
configure:
– Username
– Password
– Security Token
– Salesforce URL
– I Use Proxy ( NN )
5. ●
Once that the connector has been created we need to select in Operation the
Create Single option:
– Now in information there's a label named sObject Type so we need to select
the object User of Salesforce in my case there's a label named Usuario but is
the same object User.
– Now we select the Create Object manually of the sObject Field Mappings area
and press the custom button.
6. ●
Once the custom button has been pressed we need to configure the required
fields to create an user in Salesforce, These are:
– UserRoleID
– LocaleSidKey
– LastName
– LanguageLocaleKey
– Email
– FirstName
– TimeZoneSidKey
– CommunityNickname
– ProfileId
– EmailEncodingKey
– Alias
– Username
●
This is an example of the Ouput XML of the object:
7. ●
Now we need to create a mapping between the Saleforce saveresult and a XML to
convert to JSON:
– First select in Output the Type XML
– Go down and select the radio From Imput and press Copy Structure
– Now press the button Create Mapping
8. ●
We finish, now we are able to create an user in salesforce:
●
Run the project and open your browser and type:
●
When an user is created in salesforce returns a key like this: