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
Laxmi N 6Laxmi N 6 

Using Rest API how to get all field values of the object?

E.X:  r=requests.get(instance+url+"services/data/v42.0/querry?q=Select * from contact", headers=headers)

is giving malformed query error. however I am able to select fields and get the data.

PS:  we can get all the fields from describe endpoint (meta data) /services/data/V42.0/sobjects/Contact/describe.

I am looking for if there is any endpoint for fetching all the data of objects. I do not want to specify 350 fields in the select query

VinayVinay (Salesforce Developers) 
Hi Laxmi,

You can try below snippet.
 
/services/data/v48.0/sobjects/Account/0016F00003dWzih(id)
https://salesforce.stackexchange.com/questions/191335/how-to-get-all-field-values-from-sobject-using-rest-api

Hope above information was helpful.

Please mark as Best Answer so that it can help others in the future.

Thanks,
Vinay Kumar