MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.

    Error with GooglePhotos API

    Scheduled Pinned Locked Moved Unsolved Troubleshooting
    21 Posts 3 Posters 7.7k Views 3 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • S Offline
      sdetweil @bugsounet
      last edited by

      @bugsounet eh? works for me every time…

      Sam

      How to add modules

      learning how to use browser developers window for css changes

      bugsounetB 1 Reply Last reply Reply Quote 0
      • bugsounetB Offline
        bugsounet Banned @sdetweil
        last edited by bugsounet

        @sdetweil just create new credentials and see ;)

        For old compatibility:
        d1162e22-eaa4-4b76-95b1-8892de29cca2-image.png

        S 1 Reply Last reply Reply Quote 0
        • S Offline
          sdetweil @bugsounet
          last edited by

          @bugsounet so it should have worked for either type

          Sam

          How to add modules

          learning how to use browser developers window for css changes

          1 Reply Last reply Reply Quote 0
          • D Offline
            dum
            last edited by

            I’m sorry. what should I do?
            The credentials.json file is generated automatically from the google developers console… :astonished_face:

            S 1 Reply Last reply Reply Quote 0
            • S Offline
              sdetweil @dum
              last edited by

              @dum @bugsounet suggests you pick a different app type, and download a new credentials file

              Sam

              How to add modules

              learning how to use browser developers window for css changes

              D 1 Reply Last reply Reply Quote 0
              • D Offline
                dum @sdetweil
                last edited by

                @sdetweil thanks for the suggestion, I tried “desktop app” with same result.
                the other app types require more data which I dont know how to fill.

                S 1 Reply Last reply Reply Quote 0
                • S Offline
                  sdetweil @dum
                  last edited by

                  @dum u need to pick Web Application (1st entry)

                  need the redirect uri…

                  where on your system can the api call back to put up the verification screen

                  http://localhost:6500

                  should work… its all fake…

                  Sam

                  How to add modules

                  learning how to use browser developers window for css changes

                  1 Reply Last reply Reply Quote 0
                  • D Offline
                    dum
                    last edited by

                    thanks. I understand I need to write “localhost” the same as you have done.
                    But no luck. still error in generate_token:

                    pi-photoframe@raspberrypi:~/MagicMirror/modules/MMM-GooglePhotos $ node generate_token.js
                    [GPHOTOS:CORE] TypeError: Cannot read properties of undefined (reading 'client_id')
                    /home/pi-photoframe/MagicMirror/modules/MMM-GooglePhotos/GPhotos.js:133
                          throw e
                          ^
                    
                    TypeError: Cannot read properties of undefined (reading 'client_id')
                        at new Auth (/home/pi-photoframe/MagicMirror/modules/MMM-GooglePhotos/GPhotos.js:35:44)
                        at GPhotos.onAuthReady (/home/pi-photoframe/MagicMirror/modules/MMM-GooglePhotos/GPhotos.js:130:14)
                        at GPhotos.generateToken (/home/pi-photoframe/MagicMirror/modules/MMM-GooglePhotos/GPhotos.js:141:10)
                        at Object.<anonymous> (/home/pi-photoframe/MagicMirror/modules/MMM-GooglePhotos/generate_token.js:10:9)
                        at Module._compile (node:internal/modules/cjs/loader:1165:14)
                        at Object.Module._extensions..js (node:internal/modules/cjs/loader:1219:10)
                        at Module.load (node:internal/modules/cjs/loader:1043:32)
                        at Function.Module._load (node:internal/modules/cjs/loader:878:12)
                        at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12)
                        at node:internal/main/run_main_module:22:47
                    
                    D S 2 Replies Last reply Reply Quote 0
                    • D Offline
                      dum @dum
                      last edited by

                      By the way!!! I can start magic mirror… but I’m really trying to set a google photos photframe… the rest of the modules can be checked later.

                      1 Reply Last reply Reply Quote 0
                      • S Offline
                        sdetweil @dum
                        last edited by

                        @dum said in Error with GooglePhotos API:

                        node generate_token.js

                        ah, you should be using

                        node generate_token_v2.js

                        from the doc at
                        https://github.com/hermanho/MMM-GooglePhotos

                        Now, open your termial
                        cd ~/MagicMirror/modules/MMM-GooglePhotos
                        node generate_token_v2.js
                        

                        Sam

                        How to add modules

                        learning how to use browser developers window for css changes

                        D 1 Reply Last reply Reply Quote 0
                        • D Offline
                          dum @sdetweil
                          last edited by

                          @sdetweil thanks, next step passed using “Desktop app”
                          But now, google blocks the access even when I try to grant it:
                          c3b3d4a3-3f21-4874-947d-857a031c8efe-image.png

                          S 1 Reply Last reply Reply Quote 0
                          • S Offline
                            sdetweil @dum
                            last edited by

                            @dum u don’t want desktop. you want web

                            Sam

                            How to add modules

                            learning how to use browser developers window for css changes

                            D 2 Replies Last reply Reply Quote 1
                            • D Offline
                              dum @sdetweil
                              last edited by

                              This post is deleted!
                              1 Reply Last reply Reply Quote 0
                              • D Offline
                                dum @sdetweil
                                last edited by

                                @sdetweil
                                in
                                https://github.com/hermanho/MMM-GooglePhotos
                                they say crearly and as “IMPORTANT!!” to select desktop :dizzy_face: :face_with_monocle:
                                f2c64242-b117-477f-b3e3-11d980d1f9d8-image.png

                                bugsounetB 1 Reply Last reply Reply Quote 0
                                • bugsounetB Offline
                                  bugsounet Banned @dum
                                  last edited by

                                  So… select it… and apply the rules!
                                  What do you want us to tell you…

                                  (I forget that I work with the google team!)

                                  Do it yourself :)

                                  1 Reply Last reply Reply Quote 0
                                  • D Offline
                                    dum
                                    last edited by

                                    dear @bugsounet & @sdetweil
                                    thanks for your support, I didn’t mean to be rude, I suppose that I was frustrated for all the time I spent, while you were trying to help someone that you didn’t know and without experience :confounded_face:
                                    But finally I made it work!!!
                                    For future readers that may have my same problem, following:
                                    https://github.com/hermanho/MMM-GooglePhotos

                                    Finally I used “desktop app”, but the biggest issue was to allow the user:
                                    85321209-20f0-42f7-b70a-072f8f971c57-image.png

                                    S 1 Reply Last reply Reply Quote 0
                                    • S Offline
                                      sdetweil @dum
                                      last edited by

                                      @dum cool. never had to do that

                                      Sam

                                      How to add modules

                                      learning how to use browser developers window for css changes

                                      1 Reply Last reply Reply Quote 0

                                      Hello! It looks like you're interested in this conversation, but you don't have an account yet.

                                      Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

                                      With your input, this post could be even better 💗

                                      Register Login
                                      • 1
                                      • 2
                                      • 1 / 2
                                      • First post
                                        Last post
                                      Enjoying MagicMirror? Please consider a donation!
                                      MagicMirror created by Michael Teeuw.
                                      Forum managed by Sam, technical setup by Karsten.
                                      This forum is using NodeBB as its core | Contributors
                                      Contact | Privacy Policy