Google Language API Deprecated #70

GoogleCodeExporter opened this Issue Mar 14, 2015 · 22 comments


None yet
1 participant
What will happen with the plugin now that Google discontinued the Google 
Language API Family?

Original issue reported on by on 31 May 2011 at 7:21

I wanted to support the Microsoft API anyway:
it even provides a method for array translation (just as Google's v2 API), 
which eliminates almost all bugs with this plugin, and will make it a bit 
faster too. The quality of the translation is not any worse I think, so there's 
nothing to worry about.

Original comment by balazs.endresz on 1 Jun 2011 at 8:24

  • Changed title: Google Language API Deprecated
  • Changed state: Accepted
This is excellent news.  Can't wait for the official release with MS Bing 
support.  Thanks for this great plugin.

Original comment by on 23 Aug 2011 at 1:48

I just finished converting my jQuery Translator code from Google to Bing. It 
seems to work pretty well. Keeping the Bing Id somewhat secret is a challenge. 
Everything else is pretty straight forward. Also, you need to add to your 
translator page something like "Powered by Microsoft Translator." Just waiting 
on the final build, but you can do all the work based on the current trunk 
build now. 

Original comment by on 23 Aug 2011 at 3:43

I didn't give it a version number because this was just my first commit with MS 
support, and I'd rather have only the curious try it at this point.

And I've just found a page that says that you don't even necessarily need an 
API key but you can use a token in case you do:
but this needs to be re-generated every day -- not the best solution either.

Thanks for the heads-up anyway!

Original comment by balazs.endresz on 23 Aug 2011 at 9:14

  • Changed state: Started
Did you see this?

Important: Google Translate API v2 is now available as a paid service. The 
courtesy limit for existing Translate API v2 projects created prior to August 
24, 2011 will be reduced to zero on December 1, 2011. In addition, the number 
of requests your application can make per day will be limited. Google Translate 
API v1 will be shut off completely on the same date (December 1, 2011); it was 
officially deprecated on May 26, 2011. These changes are being made due to the 
substantial economic burden caused by extensive abuse. For website 
translations, we encourage you to use the Google Website Translator gadget.

Original comment by on 2 Sep 2011 at 1:33

Yes, I did. Why exactly do you ask?

Original comment by balazs.endresz on 2 Sep 2011 at 2:08

I think that isn't way to get back to Google Translate API. jQuey Translate is 
a free plugin, is stranger to use a paid API.

Original comment by on 2 Sep 2011 at 2:20

How does that affect your current code base? We may decide to go with the paid 
service but wondered if the plug-in would still support that? My personal 
experience is that Bing appears to work very well and the only draw back 
appears to be that Bing supports fewer languages than Google. 

Original comment by on 2 Sep 2011 at 2:39

I haven't thought about supporting paid APIs yet, now the primary backend is 
going to be the MS Translator, but it's not that hard to make it work with 
other translation services either. And if there's a demand for it I might even 
support Google v2 API as well.

Nonetheless, I find it hard to believe that they couldn't have set up some 
mechanism against abuse, especially since they kept the client-side "Translator 
gadget", which is technically the same as this plugin.

Original comment by balazs.endresz on 2 Sep 2011 at 2:51

Cool. MS Translator works really well. I think you mentioned previously that 
you hadn't completed your work on the plug-in for MS. When do you think it will 
be ready? I'm using the trunk code and I haven't had any problems and it works 
exactly the same as Google did. 

Original comment by on 2 Sep 2011 at 2:58

If there won't be any problems then it is in fact completed :) I'll just have 
to remove the redundant Google v1 code after 1st December.

As for the future, I'd like to use the TranslateArray method internally, which 
would potentially eliminate a lot of bugs but that would require a complete 
rewrite of the most sensitive parts of the plugin. In contrast moving to the MS 
API required only some trivial modifications, and fortunately there haven't 
been any unexpected side effects yet.

Original comment by balazs.endresz on 2 Sep 2011 at 3:47

It looks like this is now incompatible with jQuery 1.4 (and 1.3)? Is it 1.5+? 

It would help a lot if you'd give a full example of usage, as this was 
nontrivial for me (and I'm not getting it fully yet).

Original comment by on 25 Sep 2011 at 3:27

Everything works the same way, you just have to call 
$.translate.load(bingAppId); right after you include the plugin. I can't recall 
any compatibility problems with different versions of jQuery with the Google 
back-end but it looks like the MS Translator isn't working with 1.4. It's 
probably because it uses jQuery.ajax directly, which had some rewrites in the 
past few years. (I've just opened issue #73)

Original comment by balazs.endresz on 25 Sep 2011 at 4:13

Thanks - I can't even get the MS api to work with their test snippet. They seem 
to have moved and changed the API? See, 
which has a somewhat different API. I tried the example in and just got 
"ArgumentException: Invalid appId\u000d\u000aParameter name: appId : 
ID=3737.V2_Json.GetLanguagesForTranslate.31E23565". I put debugging in there, 
and the appId is in fact the key I got from - is 
it possible that the keys they're handing out are no longer compatible with the api?

Original comment by on 25 Sep 2011 at 5:34

Unfortunately, I can't really comment on that, I used their API only once when 
I put it in this plugin a couple of months ago. My API key is 40 characters 
long if that helps. And this how it works using jQuery:

                url: "",
                dataType: "jsonp",
                jsonp: "oncomplete",
                crossDomain: true,
                context: this,
                data: {appId: appId, form: from, to: to, contentType: "text/html", text: text}
            }).success(function(data, status){

Original comment by balazs.endresz on 25 Sep 2011 at 5:47

Thanks for your excellent, responsive maintenance of this. Would you be willing 
to get a new token and try it to see if it can be made to work? It just 
requires a different MS id.

Original comment by on 26 Sep 2011 at 12:16


Original comment by on 26 Sep 2011 at 12:19 did you manage yourself to overcome the "ArgumentException: 
Invalid appId" error message? I'm getting the same one, and can't figure out 
why it doesn't work. This is Microsoft shot to get more popular, they're 
screwing things up.

Original comment by on 2 Nov 2011 at 10:48

Are folks saying this URL doesn't work?

var serviceUrl = "";

Then on the call the code appends your id are a query string variable. This 
works fine and my code is sitting in our QA environment to be deployed on 
11/30. All your transaction with the API need your ID in the transmission. Here 
is a piece of sample code I modified from code for my purposes that will give 
you an id of what is going on:

    function langDetect(a) {
        var sQuery = a;
        if(sQuery == ""){ sQuery = jQuery("#input-text").val(); }
        var serviceUrl = "";
        var langCode = "";
            type : "GET",
            url : serviceUrl + "Detect",
            dataType : "jsonp",
            jsonp : "oncomplete",
            crossDomain: true,
            data : { appId : bid, text : sQuery } 
            var langCode = c;
            if(langCode != "gl"){
            sLang = jQuery.translate.toLanguage(langCode,"capitalize");
            sLangDected = (sLang + " - detected");
            jQuery("select.jq-translate-ui option[value='" + langCode + "']").remove(); 
            jQuery("select.jq-translate-ui option[value='novalue']").remove(); 
            jQuery("select.jq-translate-ui").append('<option value="' +  langCode + '" selected="selected">' + sLangDected  + '</option>');
            } else {


So this function detects the language entered into a textbox by a user and then 
populates a drop down box with all the available translator languages, with the 
the language of the text selected. Something I needed but not specifically 
available in the plugin.

Original comment by on 2 Nov 2011 at 1:46

No, I still get "ArgumentException: Invalid appId\u000d\u000aParameter name: 
appId : ID=3835.V2_Json.GetLanguagesForTranslate.1F40CE2E"

IMO this just isn't working at all yet. I suspect that the Microsoft service 
doesn't work, but it may be that they've changed the interface or something.  
Note that the 2000 free transactions per month on this service is a pretty slim 
number for most people, so this may not be worth it after all.

I'm going to do some experimenting with just using Google's Translate tools:

Original comment by on 15 Nov 2011 at 2:18

I'm also getting the "ArgumentException: Invalid appId." Is there a workaround 
for this?

Original comment by on 26 Apr 2012 at 10:38

Seems like Microsoft boys are playing again with their APIs, since the Bing 
AppIds are no longer supported. I'm trying to sign up for a Microsoft Azure 
account, but I can't get it work, when I try to sign in, it continues loading 
until it fails, like a timeout. 

Is this happening to somebody else?

Original comment by on 26 May 2012 at 8:39

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment