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

Can't translate, getting error.

Open Stanlyhalo opened this issue 5 years ago • 3 comments

I'm getting this error:

{ Error at /rbd/pnpm-volume/d8614593-b135-49f8-804b-3686ad6243fd/node_modules/.registry.npmjs.org/google-translate-api/2.3.0/node_modules/google-translate-api/index.js:105:17 at at process._tickCallback (internal/process/next_tick.js:189:7) code: 'BAD_REQUEST' }

when doing this

translate('Hello', {from: 'en', to: 'es'}).then(res => {
  console.log(res.text);
  console.log(res.from.text.autoCorrected);
  console.log(res.from.text.value);
  console.log(res.from.text.didYouMean);
}).catch(err => {
  console.error(err);
});

Why does this happen. I'm doing everything right.

Stanlyhalo avatar Dec 10 '19 22:12 Stanlyhalo

Having the same problem, any update on this?

Himadri001 avatar Jan 12 '20 09:01 Himadri001

I'm also seeing this error. looks like the underlying issue is a 403. wonder if google locked it down finally?

mistersender avatar Jan 24 '20 21:01 mistersender

I'm also seeing this error. looks like the underlying issue is a 403. wonder if google locked it down finally?

Incorrect token is being generated, check out my open issue

ArtanisTheOne avatar Dec 22 '20 18:12 ArtanisTheOne