Normally, REST service is faster than SOAP service . Compared to SOAP, data transfered by REST services usually is smaller. SOAP requires a complete
SOAP envelope, which wraps the actual data. In REST services, you can transfer the data only, without a wrapping envelope. Particularly, most of Translator APIs use GET method, thus using
In addition, since the issue is related to Bing, I would recommend you to post a thread at:
While Ming's answer is generally correct for any API with these flavors, for the Translator API it really doesn't make a difference. The size of the packet determines network latency, which has only a small contribution to the overall latency: translation
is a relatively complex and thus slow operation, compared to the time the packet spends traveling.
Use whatever is most convenient:
- If you are a .Net/C# developer, use SOAP. You get all the convenience of the Visual Studio IDE. Just add
http://api.microsofttranslator.com/v2/soap.svc as a web reference, and you are good to go, don't need to think about parameters and character encodings or anything.
- If you write an in-browser app, you are pretty much locked into JScript, unless you handle all translation logic server-side.
- If you are a PHP or other server-side script developer, use REST. Be aware that you need to do all encoding by hand: the source string needs to be HTML- and URLEncoded UTF-8.
- If you are using other data sources for instance from Azure Marketplace, you can also use the OData protocol.