Reputation: 41
I'm the developer on a comprehensive Apple TV app for the Nest called Feather (featherapp.co). One issue that I've run into is that users are expecting to be able to view the live feed of their cameras.
Has anyone determined any way of accessing the live feed of the camera? I've done quite a bit of reverse engineering but I believe the stream itself is protected by some sort of DRM.
It looks like it's an RTMP stream that takes a format like below:
rtmps://oculus387-vir.dropcam.com/nexus/[cameraid]
with some parameters
_sessionToken,_isHD,_camera.uuid,time
I've tried a number of things but I'm never really able to establish a connection to the source. I'm a little out of my depth here, as an application developer getting into the more hardcore streaming technology. Any insight would be really appreciated!
Upvotes: 3
Views: 5984
Reputation: 31209
This should now be possible with Device Access.
GenerateRtspStream
Request a token to access an RTSP live stream URL.
RTSP live stream URLs cannot be shared between clients. A stream URL can only be used by one client at a time. If multiple clients want to stream from the same camera at the same time, RTSP commands must be sent for each individual client, and each individual client must use its own stream URL.
Source: https://developers.google.com/nest/device-access/traits/device/camera-live-stream#generatertspstream
Upvotes: 2
Reputation: 1
you can't acesses the live stream in any normal way but you may be able to get one frame per second from the old android api. I have tried this but i think they patched it or it doesn't work with the new cameras
#! /bin/bash
i=00
while [ $i -lt 300 ]
do
curl 'https://home.nest.com/dropcam/api/cameras/_your camera url etc' -H 'Cookie: YOUR_COOKIE ETC' -H 'Accept: application/json, text/javascript, */*; q=0.01' -H 'Referer: https://home.nest.com/' -H 'X-Requested-With: XMLHttpRequest' -H 'Connection: keep-alive' --compressed -o nest\ testing/$i.jpeg
let i+=1
echo $i
done
ffmpeg -r 25 -start_number 1 -f image2 -i "%04d.jpg" -vcodec png video.avi
o.avi
Upvotes: 0