Capture DropCam (Nest Cam) frames to Google Drive
Updated June 17, 2019: This is now broken for Nest/DropCam devices. It will still work for anything that has a web accessible image URL. Clint points out in the comments below that you can fix up the URL for Nest cams but it looks like you need to be logged into nest.com so it doesn't work from Apps Script. Google is also retiring Works with Nest because they're "...reimagining how technology and services can deliver simple and helpful experiences in your home..." which apparently translates to only working with Google Assistant. I'll update this post if I figure out a work around.
Here's an easy way to capture frames from a DropCam to Google Drive. This only works if you have a public feed for your DropCam.
Go to the public page for your DropCam (Settings -> Public -> Short URL Link) and then view source for that page. Near the top you can find the still image URL for your DropCam:
<meta property="og:image" content="https://nexusapi.dropcam.com/get_image?uuid=12345&height=200" />
In Google Drive create a new Apps Script (If you don't already have Apps Script you can find it via Connect more apps...). Paste in the following code:
Replace the uuid parameter in the URL with the uuid from the still image URL for your DropCam. Note that the height parameter in the script has been changed to 1280 to get the largest possible image. A timestamp is being used to add a random cache busting parameter to the still image URL and is also used as the filename for the image.
The script will save the images to a folder called DCFrames - either create this folder in your drive or change this parameter to the desired folder.
Run the script and check that it's working. If everything looks good go to Resources -> Current project's triggers in the Apps Script editor. You can now set up a timer to save a frame as frequently as every minute (which I'm using to collect frames to make a daily time lapse movie). You can also ask Apps Script to send you an email when the script fails.
Updated 2015-07-01: DropCam is now Nest Cam - assuming that Nest keep the API going everything should keep working as above for both types of camera.
- Get an email when your security camera sees something new (Apps Script + Cloud Vision)
- How to backup Google Photos to Google Drive automatically after July 2019 with Apps Script
- West of West Portal
All comments are moderated. Your email address is used to display a Gravatar and optionally for notification of new comments and to sign up for the newsletter.