google-translate-api icon indicating copy to clipboard operation
google-translate-api copied to clipboard

Why it's unlimited?

Open cnskyboy88 opened this issue 6 years ago • 4 comments

I estimate we will invoke 100K times and totally 34 million characters per month, does this support?

cnskyboy88 avatar May 15 '18 10:05 cnskyboy88

Your server will probably get blocked by Google

aattoade avatar May 25 '18 08:05 aattoade

I have the same question. As I know, we will be charged for the Translate API.

nvtuan305 avatar May 25 '18 15:05 nvtuan305

Hey. Google tightened the restrictions and now from a single IP address can make very few queries. I added the use of a proxy server (IPv4, IPv6). Maybe my solution will help you.

https://github.com/extensionsapp/translatte

const translatte = require('translatte');

// Translate string to English using proxy
translatte('Вы говорите на русском?', {
    from: 'ru',
    to: 'en',
    agents: [
        'Mozilla/5.0 (Windows NT 10.0; ...',
        'Mozilla/4.0 (Windows NT 10.0; ...',
        'Mozilla/5.0 (Windows NT 10.0; ...'
    ],
    proxies: [
        'LOGIN:[email protected]:12345',
        'LOGIN:[email protected]:54321'
    ]
}).then(res => {
    console.log(res);
}).catch(err => {
    console.error(err);
});
// { text: 'Do you speak Russian?', 
//   from: { 
//     language: { 
//       didYouMean: false, 
//       iso: 'ru' 
//     }, 
//     text: { 
//       autoCorrected: false, 
//       value: '', 
//       didYouMean: false 
//     } 
//   },
//   raw: '' }

extensionsapp avatar Sep 24 '18 19:09 extensionsapp

I estimate we will invoke 100K times and totally 34 million characters per month, does this support?

Sounds like this is going to abuse the service. Better off paying for the real API service.

motss avatar Feb 14 '20 02:02 motss