Read the statement by Michael Teeuw here.
MMM-GooglePhotos
-
@kapsolas
The picture was not created by you, right?
I’ll research and try to fix it. -
Correct.
The setup is as follows:
- I created a shared album
- Invited my wife to it
- I uploaded photos
- My wife uploaded photos
When I tried to set up the plugin, I discovered it was failing. I modified the code to print the body to the console and saw the message from the Google Photos API.
The response is:
error:
{ code: 400,
message: ‘The media item is not in the user’s library. It was contributed by another user to a shared album that this user joined to.’
status: ’ INVALID_ARGUMENT’ }
}If we could get this to work, it would be a nice way to use GooglePhotos act like an online digital photo frame. Anyone with access to the shared album can upload photos.
-
@kapsolas
I guess the reason is the scope rule. “readonly” is set for the scope of API using. I’ll change it to “https://www.googleapis.com/auth/photoslibrary.sharing”, but it’s just guessing. Test will be needed.
After fixing, I’ll tell you.
(Today, I purchased my new MBP and am migrating, so I’m not ready to develop something, so it’ll take somewhat time.) -
@kapsolas
Fixed. (I think). Try it. (justgit pull
, no need tonpm install
)mediaItem:search
API could access photos shared from others, butmediaItem/ID
API couldn’t. It looks so weird. Anyway, I changed it to usemediaItem:search
. The only risk is expiration of temporary image URL, so you’d better keepscanInterval
under 1 hour. -
Awesome! That worked and solved it!
I’ll need to pay around a bit with the sizes in the config (hopefully not the code) to see if I can get the images to display in the screen fully.
For now the images are being cropped as they are larger than the display area on the screen.
Again thank you!
-
@kapsolas set the
mode
tocover
orcontain
.cover
will be fit your entire region as large as possible but cropped,contain
will show the entire image but has some black tape aroundtop and bottom
orleft and right
by the ratio of photo width/height like movie film. -
Hello i use node auth_and_test.js but i dont have any album ID in terminal only info : auth_and_test started.
What to do to get album ID ?? -
If you don’t see any response, it may be because an error is being returned by Google. Errors in the script are suppressed now.
If you are familiar with updating the code, you can add a console.log(body) message to see the error.
-
@kapsolas said in MMM-GooglePhotos:
console.log(body)
in auth_andtes is console log error and i dont have any just info in console:
auth_and_test started
so i dont have i thing any error but no album ID :/ -
@kivlow At your first execution, have you countered allowance process?