Skip to content

steakscience/random-google-photos

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 

Repository files navigation

Send random Google Photos image

This script takes a random image from a Google Photos album and sends it as an email attachment.

This allows you to use Google Photos with services like IFTTT which doesn’t support Google Photos.

Note: This script is based off of dfkoz's and Ben Lind's gist.

Ben Lind's script sends images inline. In this version, images are sent as attachments. A lot of code has been rewritten to use Google Photos as a source instead.

Usage

  1. Must have a Google Photos album
  2. Log into Google Drive, and click CREATE -> Script -> Blank Project.
  3. Delete all of the default code, and paste the code in random-image-emailer.gs into your project.
  4. Create another file appsscript.json and copy the contents from this repo.
  5. Follow the instructions in random-image-emailer.gs to get the albumID and put it in.
  6. You may also need to create a Google Cloud Platform project. This will allow you to create a test credential to link to this project.
  7. You can test the script by selecting Run -> sendRandomImage.
  8. Click Resources -> Current Project's Triggers, and set up the email to run as often as you would like.

About

Send random Google Photos image to IFTTT

Topics

Resources

Stars

Watchers

Forks

Languages

  • JavaScript 100.0%