This site contains the documentation that is relevant to older WSO2 product versions and offerings.
For the latest WSO2 documentation, visit https://wso2.com/documentation/.
Creating a Connected Application using Salesforce
- Go to https://developer.salesforce.com/, and sign up to get a free developer environment.
- Go to Setup -> Create -> Apps, and click New. This creates a new connected application.
- Specify a name for your application, your email address as well as any other information applicable to your application.
- Select Enable OAuth Settings.
- Specify a callback URL. Depending on the OAuth flow you use, this is typically the URL that your browser is redirected to, after successful authentication. Since this URL is used in some of the OAuth flows to pass an access token, the URL must use secure HTTP or a custom URI scheme.
- Add all supported OAuth scopes as Selected OAuth Scopes. These OAuth scopes include permission given by the user running the connected application.
- Specify a Info URL. This is where a user can go for more information about your application.
- Click Save. Once you navigate to the application that you created, you can see the following:
- Consumer Key created and displayed.Â
- Consumer Secret created.
- OAuth endpoints are the URLs you use to make OAuth authentication requests. For token requests you can send a POST request to Salesforce via https://login.salesforce.com/services/oauth2/token.
- You need to send a payload as follows to https://login.salesforce.com/services/oauth2/token.
grant_type=password&client_id=<your_client_consumer key>&client_secret=<your_client_consumer secret>&username=<your_username>&password=<your_password>
In here as "your_password" you need to append the user’s security token to their password .A security token is an automatically-generated key from Salesforce. For example, if a user's password is mypassword, and their security token is XXXXXXXXXX, then the value provided for this parmeter must be mypasswordXXXXXXXXXX
To get security token please go to My Setting->Personal->Reset my Security Token as captured below.
Then your new security token will be sent to your gmail
Once you send the request to https://login.salesforce.com/services/oauth2/token using above mentioned payload, you will get a response like below with access token
"id":"https://login.salesforce.com/id/00D50xxxxxxxxxx01fg5OAAQ",
"issued_at":"1296509381665",
"instance_url":"https://na1.salesforce.com",
"signature":"+Nbl5EOl/xxxxxxxxxxxxxxxxx=",
"access_token":"00D50000000IZ3Z!xxxxxxxxxxxxxxxxx"
- You can use that access token in yourÂ
salesforcebulk.init
 configuration.