...
Navigate to the following URL, replacing <ID> with the Id of the record you just created, http://login.salesforce.com/apex/Subscription25__OAuth?tokenId=<ID>
You are now redirected to a new page, copy the URL of that page.
...
Navigating back to the developer console of Salesforce, run the following piece of code. Replace <ID> with the id of the token from Salesforce, replace <CLIENT_ID> with the Client ID copied from the Exact Authorisation Details above, replace <CLIENT_SECRET> with the Client Secret copied from the Exact Authorisation details.
Code Block | ||
---|---|---|
| ||
Subscription25__OAuth_Token__c OAuthToken2 = [ SELECT Subscription25__Client_Id__c, Subscription25__Client_Secret__c FROM Subscription25__OAuth_Token__c WHERE Id = '<ID>' ]; oAuthToken2.Subscription25__Client_Id__c = '<CLIENT_ID>'; oAuthToken2.Subscription25__Client_Secret__c = '<CLIENT_SECRET>'; Database.update(OAuthToken2); |
...