node js with gmail api, The API returned an error: Error: unauthorized_client
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: Edit: The error is happening on on this piece of code: var gmail = google.gmail('v1'); gmail.users.labels.list({ auth: auth, userId: 'me', }, function(err, response) { if (err) { console.log('The API returned an error: ' + err); return; } I am using gmail api with Node js. When I go through their quickstart guide I keep getting this error. https://developers.google.com/gmail/api/quickstart/nodejs The API returned an error: Error: unauthorized_client Keep in mind, I went through the quickstart with my email adress, everything was fine. No