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

How to insert sObject dynamically using Java and Salesforce API?

I read the blog post "Inserting sObject Dynamically in Salesforce" (, and the solution is implemented in Apex. Is it possible to do similar thing in Java application by using Salesforce remote API?

Best regards,


Yes, you can do similar things via the partner SOAP API, or the REST API.


How to do that (insert sObject dynamically)? API call describeGlobal() does not return sObjects, it returns only DescribeGlobalSObjectResult that gives some description about available objects. Furthermore, SObject in Java does not have put() method as  in Apex example  nor other similar method.