When I’m trying to translate simple “19 – 15” the autodetection of source language fails and I get “Bad language pair” exception.
The .NET example contains some kind of wrapper around Google Translate API. It’s located in Google.Apis.Translate.v2.cs file. But this wrapper doesn’t allow to specify source language. So, what is the easiest way to make this?
I think that the most correct way is regenerate Google.Apis.Translate.v2.cs. But I don’t know how to do that.
Although I could deal with rough REST requests, but it looks awkward.
You can specify the Source parameter in the translation ListRequest as in the following snippet: