Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Where to get client_id and client_secret of Salesforce API for Rails 3.2.11

I've been following a tutorial from: http://wiki.developerforce.com/page/Accessing_Salesforce_Data_From_Ruby

But, I'm stuck with the part where you need to supply the keys:

host: login.salesforce.com        # Use test.salesforce.com for sandbox
client_secret: 1234567890         # This is the Consumer Secret from Salesforce
client_id: somebigidthinghere     # This is the Consumer Key from Salesforce
sobject_module: SFDC_Models       # See below for details on using modules
debugging: true                   # Can be useful while developing
username: [email protected]
password: mypasswordplusmysecuritytoken

Where can I get the client_secret and client_id. The tutorial from the official API site of Salesforce is kind of outdated. http://www.salesforce.com/us/developer/docs/api_rest/index.htm

And some other tutorials didn't even mention where to exactly get it.

I already created an account in http://developer.force.com/

And even created a custom app, correct me if I'm wrong.

Then don't know where to find the keys that I need.

Any workarounds will be appreciated.

like image 561
xirukitepe Avatar asked Aug 27 '13 11:08

xirukitepe


People also ask

How do I pass a client ID and secret in REST API?

The Client ID and Client Secret are found in the Admin > LaunchPoint menu by selecting the custom service, and clicking View Details. The Identity URL is found in the Admin > Web Services menu in the REST API section. access_token – The token that you pass with subsequent calls to authenticate with the target instance.


2 Answers

When you log in to developer.force.com, In the left nav

Build -> 
  Create ->
    Apps

The bottom of that page has "Connected Apps". Click "New" to add the app you created. You'll set your callback URL, description etc. Once you hit save you'll see your consumer id and secret.

like image 54
trh Avatar answered Nov 15 '22 19:11

trh


The structure of the salesforce admin panel has changed slightly since this question was answered. Here is how you now access the screen referred to in the answer by trh:

enter image description here

like image 25
Peter Berg Avatar answered Nov 15 '22 18:11

Peter Berg