A company has a web page that needs to get Account record information, given its Salesforce record ID, from JavaScript on the page and then display it. Which method of integration is optimal?
I'd say D
https://trailhead.salesforce.com/content/learn/modules/apex_integration_services/apex_integration_webservices
"By making your methods callable through the web, your external applications can integrate with Salesforce to perform all sorts of nifty operations."
A web page that needs to retrieve account info from SF sounds like an external application to me,
I said D myself, but I think the confusion comes from that cast that I thought 'Rest API' implied that Salesforce was using a callout to an external service whereas the external service is using the API (without a custom class) to get the information. The reason why it mentions Javascript is because REST supports JSON whereas SOAP does not, it only supports XML.
The correct is A you don't need to expose the apex rest service and write a test class for just retrieving an account, just call a rest API https://developer.salesforce.com/docs/atlas.en-us.api_rest.meta/api_rest/dome_get_field_values.htm
Correct is D because from the web page you need to access Sf
upvoted 3 times
...
Log in to ExamTopics
Sign in:
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
nibbio
Highly Voted 2 years, 11 months agogsori
Most Recent 3 months, 1 week agothneeb
1 year, 9 months agolorenac2
1 year, 10 months agoamilaveer
1 year, 10 months agoRonin192
1 year, 11 months agonkarmi
2 years agolevian
2 years, 1 month agoOmShantiVeg
2 years, 4 months ago