Intellipaat Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in Salesforce by (11.9k points)

I have been building a console app the uses the Salesforce SOAP API, and now need to use the Salesforce API in a web app.

Am I correct to assume that SOAP is better suited for a non-web-based app, and REST is better for a web app?

If I were to create a wrapper that would be used in either reporting from local apps or posting to salesforce from our websites, should I expose both the REST and SOAP API's, depending on what the app is? Or should I just stick to using one? What are the deciding factors I should look at if I just need to pick one?

1 Answer

0 votes
by (32.1k points)
There are the following things which need to be taken care of:

1) The soap API includes a few things which are not available in the REST API, most prominently describe the layout, queryAll, getDeleted and getUpdated.

2) You can directly update bulk data in the SOAP API, but you'll need to use the Async Bulk API to do that from REST.

3) The REST API can access binary data (files, attachments, content, etc) without the overhead of base64 encoding/decoding.

4) The REST API contains a few things not available in the SOAP API, which includes the API for chatter, and accesses to the recently accessed records lists.

So, depending on exactly what your app is trying to do may push you one way or the other.

Related questions

0 votes
1 answer
0 votes
1 answer
0 votes
1 answer

31k questions

32.8k answers

501 comments

693 users

Browse Categories

...