In my previous article Seamless EDI implementation through Web Services, I covered various types of web services. Perhaps, if you’re still worried about choosing between SOAP or REST for your EDI implementation, this brief comparative review should help you make a choice. But in any case, you should remember that the focus of your decision must concentrate on which web service best responds to your needs.
First, look at the difference between the SOAP and REST request and response packets.
Here is a SOAP request and response packets:
Here is a REST request and response:
Difference between REST and SOAP approaches
SOAP actively uses XML to encode requests and responses, as well as strong data typing, ensuring the integrity of the information is intact, during transmission between the client and the server. On the other hand, requests and responses in REST can be transmitted in ASCII, XML, JSON or any other formats that can be recognized by both the client and the server. In addition, there are no built-in data type requirements in the REST model. As a result, the request and response packets in REST are much smaller than their corresponding SOAP packets.
In the SOAP model, the HTTP data transfer layer is a “passive observer,” and its role is limited to sending SOAP requests from a client to the server using the POST method. Service request details, such as the remote procedure name and input arguments, are encoded in the request body. Opposite of SOAP the REST architecture, considers the HTTP data transfer layer as an active participant in an interaction using existing HTTP methods, such as GET, POST, PUT, and DELETE, to indicate the type of service requested. Therefore, from a developer’s perspective, REST requests are generally simpler to be formulated and understood since they use existing and well-understood HTTP interfaces.
The SOAP model allows service developers to describe its APIs in a Web Service Description Language (WSDL) file format. Creating these files is quite difficult, but it’s well worth the effort since SOAP clients can automatically retrieve detailed information from these files. For example, about the names and method signatures, input and output types and return values. On the other hand, the REST model avoids the complexity of WSDL in favor of a more intuitive interface based on the standard HTTP methods described above.
At the “heart” of REST is the concept of resources, while SOAP uses interfaces based on objects and methods. The SOAP interface can contain an almost unlimited number of methods; the REST interface, in contrast, is limited to four possible operations, corresponding to the four HTTP methods.
Useful link: Download EDI Web Service overview.
This EDI Web Service overview covers the following topics:
- What is EDI2XML Web Services?
- Advantages of using EDI2XML HTTP service
- Who is EDI Web Service for?
The best Web Service for EDI
EDI2XML Web Service, is for developers, systems integrators and businesses, interested in building their own EDI (Electronic Data Interchange) integration flows and programs. Normally, these individuals, are capable of interacting with external API and Web Services to translate EDI to XML and XML to EDI, and have the resources and expertise to work with Web Services and HTTP requests in order to achieve their goals. EDI2XML web service, is the premier choice for IT people as a reliable service to accomplish such Integration projects.
The best way to discover how REST works for EDI is to try our free 15- days trial version of EDI2XML Web Service.