jgauth / MMM-GoogleTasks

21 stars 29 forks source link

cannot node authenticate #24

Open Ukhupacha opened 1 year ago

Ukhupacha commented 1 year ago

Hi,

I cant seem to authenticate with my credentials.json

This is the following error I get, can aynone help me?

root@MagicMirror:~/Magicmirror/modules/MMM-GoogleTasks # node authenticate.js 
/root/Magicmirror/modules/MMM-GoogleTasks/authenticate.js:25
      client_id, client_secret, redirect_uris[0]);
                                             ^

TypeError: Cannot read properties of undefined (reading '0')
    at authorize (/root/Magicmirror/modules/MMM-GoogleTasks/authenticate.js:25:46)
    at /root/Magicmirror/modules/MMM-GoogleTasks/authenticate.js:13:3
    at FSReqCallback.readFileAfterClose [as oncomplete] (node:internal/fs/read_file_context:68:3)

Node.js v18.14.0

I have magicmirror working nicely, I followed the instructions for authentication and downloaded a json file.

XDmToter commented 11 months ago

I am getting the same error. I am running Node.JS v20.8.0

/opt/MagicMirror/modules/MMM-GoogleTasks/authenticate.js:25
      client_id, client_secret, redirect_uris[0]);
                                             ^

TypeError: Cannot read properties of undefined (reading '0')
    at authorize (/opt/MagicMirror/modules/MMM-GoogleTasks/authenticate.js:25:46)
    at /opt/MagicMirror/modules/MMM-GoogleTasks/authenticate.js:13:3
    at FSReqCallback.readFileAfterClose [as oncomplete] (node:internal/fs/read/context:68:3)

Node.js v20.8.0
XDmToter commented 11 months ago

Should this "redirect_uris" be included in the credentials.json file? It is not. I see an "auth_uri", but no "redirect_uris"