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
SwayampravaSwayamprava 

What is the difference in Http Callout and Rest integration?

1.As much I know , Rest API also use HTTP call out , So i want to know what more we do in REST that is not included in HTTP callout.

 
SandhyaSandhya (Salesforce Developers) 
Hi,

An HTTP callout is code that you write within Salesforce to (generally) call out to an external API over HTTP.
REST and SOAP are types of APIs.
So, you could make a callout to an external SOAP API or a REST API. Think of doing a callout as wanting to communicate with someone, the protocol (REST or SOAP) is the format of the communication, and HTTP is the method of communicating. If you mix them up it doesn't work, like trying to send a fax to someone's cell phone number. In that example, the phone line is the method (HTTP), the fax is the protocol(SOAP or REST) and making the call is the callout.
Salesforce also has it's own SOAP and REST APIs, but those would generally be used by code ran outside of Salesforce to create/read/update/delete Salesforce data.

https://salesforce.stackexchange.com/questions/138325/what-is-the-difference-in-http-callout-and-soap-rest-api
 
Please mark it as solved if my reply was helpful. It will make it available for other as the proper solution.
                                             
Best Regards
Sandhya
 
Raj VakatiRaj Vakati
An Apex callout enables you to tightly integrate your Apex code with an external service. The callout makes a call to an external web service or sends an HTTP request from Apex code, and then receives the response.
Apex callouts come in two flavors.
Web service callouts to SOAP web services use XML, and typically require a WSDL document for code generation.
HTTP callouts to services typically use REST with JSON.


With Rest Service 

You can expose your Apex class and methods so that external applications can access your code and your application through the REST architecture. This is done by defining your Apex class with the @RestResource annotation to expose it as a REST resource. Similarly, add annotations to your methods to expose them through REST. For example, you can add the @HttpGet annotation to your method to expose it as a REST resource that can be called by an HTTP GET request. For more information, see Apex REST Annotations