function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
mukesh guptamukesh gupta 

Salesforce API integrate with javascript

Hi Expert,
 I have created a connected app and now I want to access the salesforce account object in another javascript project, how to access this object in javascript i am using below below code  
var clientId = "4MVG98dostKihXN5oBoP6A8TICyfESSuGPgzHBiJq8XH4PuqTtB.pxOTyitM4r46cHGX2d1tXRl4Jp0Ab58";    
var consumerSecret = "2388376451203";     //Authorization endpoint    
var authEndPoint = "";     //response_type must be set to token    
var responseType = "token";     //This is the callback URL from the connected app     var redirectURI = "";     //Construct the URL with the required parameters    
var requestURL = authEndPoint+'?client_id='+clientId+'&response_type='+responseType+'&redirect_uri='+redirectURI;  

Can you please suggest   

Shruti SShruti S
If you want to access Salesforce via Javascript, I would highly recommend using a bulletproof library called JSforce. Take a look at this link that explains how you can do authentication and various other things -
rishi jaykar 1rishi jaykar 1
you can go through by: