/ Published in: Bash
URL: https://code.google.com/apis/explorer/
Get album feed from picasa, fields (link @rel=edit, timestamp ) add raw offset value to adjust min:max timestamps from local to UTC plug the adjusted timestamps into latitude request
Note: that if you have latitude/history setting=ON , then any time any app uses the location Provider, the returned value (lat/long) winds up on Latitude.
Expand |
Embed | Plain Text
--oauth2 playground authenticated request on picasa for an album feed... GET /data/feed/api/user/default/albumid/5720219664565209553?fields=entry/link[@rel="edit"],entry/gphoto:timestamp HTTP/1.1 Host: picasaweb.google.com Authorization: OAuth ya29.AHES... <?xml version='1.0' encoding='UTF-8'?> <feed xmlns='http://www.w3.org/2005/Atom' xmlns:gphoto='http://schemas.google.com/photos/2007'><entry> <link rel='edit' type='application/atom+xml' href='https://picasaweb.google.com/data/entry/api/user/113172267863552078400/albumid/5720219664565209553/photoid/5720219691294532386/11'/> <gphoto:timestamp>1331807465000 ... <gphoto:timestamp>1331810092000</gphoto:timestamp></entry></feed> -- adjust first/last timestamps by rawoffset due to TZ settings on the camera -- call latitude using the api Explorer w/ oauth 2 access granted GET https://www.googleapis.com/latitude/v1/location?max-results=100&max-time=1331835292000&min-time=1331832665000&pp=1&key={YOUR_API_KEY} Authorization: OAuth ya29.AHES6ZQR.... Response 200 OK - Hide headers - cache-control: private, max-age=0, must-revalidate, no-transform content-type: application/json; charset=UTF-8 date: Mon, 19 Mar 2012 02:07:30 GMT etag: "cvzYuLoLPgEy7KdPdboxcryL9PM/Bm-Z2ysk9f9syMfpz1VcXVD6p5c" expires: Mon, 19 Mar 2012 02:07:30 GMT server: GSE { "data": { "kind": "latitude#locationFeed", "items": [ { "kind": "latitude#location", "timestampMs": "1331835283382", "latitude": 37.7749295, "longitude": -122.4194155 }, { "kind": "latitude#location", "timestampMs": "1331835242217", "latitude": 37.7749295, "longitude": -122.4194155 }, { "kind": "latitude#location", "timestampMs": "1331835202609", "latitude": 37.7749295, "longitude": -122.4194155 }, { "kind": "latitude#location", "timestampMs": "1331835140225", "latitude": 37.7749295, "longitude": -122.4194155 },
You need to login to post a comment.
