I'm trying to publish multilevel shoot using Street View Publish API but levels are not showing on Google map.
I have sent this below python request for Upload the metadata of the photo:
Request for level 1:
metadata_upload_url = "https://streetviewpublish.googleapis.com/v1/photo?key={}".format(API_KEY)
headers = {"Authorization": "Bearer {}".format(ACCESS_KEY), "Content-Length": "0",
"Content-Type": "application/json"}
data = {
"uploadReference": {
"uploadUrl": "https://streetviewpublish.googleapis.com/media/user/100547264652003378315/photo/5844140439745949662"
},
"pose": {
"latLngPair": {
"latitude": 18.51314,
"longitude": 73.85670
},
"heading": 0.0,
"pitch": 0.0,
"level": {
"number": 1,
"name": "arr"
}
},
"places": [{
"placeId": "ChIJb3sWh27AwjsRkiAc5rqoVvs",
}],
}
meta_photo_request = requests.post(metadata_upload_url, json=data, headers=headers)
photoid = meta_photo_request.json()['photoId']['id']
Request for level 2:
metadata_upload_url = "https://streetviewpublish.googleapis.com/v1/photo?key={}".format(API_KEY)
headers = {"Authorization": "Bearer {}".format(ACCESS_KEY), "Content-Length": "0",
"Content-Type": "application/json"}
data = {
"uploadReference": {
"uploadUrl": "https://streetviewpublish.googleapis.com/media/user/100547264652003378315/photo/5844140439745949662"
},
"pose": {
"latLngPair": {
"latitude": 18.51315,
"longitude": 73.85671
},
# "altitude": 500,
"heading": 0.0,
"pitch": 0.0,
"level": {
"number": 2,
"name": "brr"
}
},
"places": [{
"placeId": "ChIJb3sWh27AwjsRkiAc5rqoVvs",
}],
}
meta_photo_request = requests.post(metadata_upload_url, json=data, headers=headers)
photoid = meta_photo_request.json()['photoId']['id']
Result with status 200
{
"results": [
{
"status": {
"code": 200
},
"photo": {
"photoId": {
"id": "CAoSLEFGMVFpcE5UOXQzcDBwa0kwTGVROG81Nm1Qc05HdFo4djROUjB4YXM0UGNf"
},
"pose": {
"latLngPair": {
"latitude": 18.51315,
"longitude": 73.856709999999993
},
"altitude": "NaN",
"pitch": "NaN",
"roll": "NaN",
"level": {}
},
"connections": [
{
"target": {
"id": "CAoSLEFGMVFpcE9VaEpXRU03SWZod0dkdFVJUDgwNHhsY0p2YWktcTVldHVmZ0ZV"
}
}
],
"captureTime": "2017-07-27T00:00:00Z",
"places": [
{
"placeId": "ChIJb3sWh27AwjsRkiAc5rqoVvs"
}
],
"thumbnailUrl": "https://lh3.googleusercontent.com/p/AF1QipNT9t3p0pkI0LeQ8o56mPsNGtZ8v4NR0xas4Pc_=-no",
"viewCount": "7",
"shareLink": "https://www.google.com/maps/#18.51315,73.85671,0a,75y/data=!3m6!1e1!3m4!1s-W7huarDveuA%2FWXnJ6zKkzAI%2FAAAAAAAAia8%2FhTVrH8aZO54yds7DERdBRcwHUvgzg_6BACLIBGAYYCw!2e4!3e11!6s%2F%2Flh3.googleusercontent.com%2F-W7huarDveuA%2FWXnJ6zKkzAI%2FAAAAAAAAia8%2FhTVrH8aZO54yds7DERdBRcwHUvgzg_6BACLIBGAYYCw%2Fno%2Fphoto.jpg"
}
},
{
"status": {
"code": 200
},
"photo": {
"photoId": {
"id": "CAoSLEFGMVFpcE9VaEpXRU03SWZod0dkdFVJUDgwNHhsY0p2YWktcTVldHVmZ0ZV"
},
"pose": {
"latLngPair": {
"latitude": 18.51314,
"longitude": 73.8567
},
"altitude": "NaN",
"pitch": "NaN",
"roll": "NaN",
"level": {}
},
"connections": [
{
"target": {
"id": "CAoSLEFGMVFpcE5UOXQzcDBwa0kwTGVROG81Nm1Qc05HdFo4djROUjB4YXM0UGNf"
}
}
],
"captureTime": "2017-07-27T00:00:00Z",
"places": [
{
"placeId": "ChIJb3sWh27AwjsRkiAc5rqoVvs"
}
],
"thumbnailUrl": "https://lh3.googleusercontent.com/p/AF1QipOUhJWEM7IfhwGdtUIP804xlcJvai-q5etufgFU=-no",
"viewCount": "8",
"shareLink": "https://www.google.com/maps/#18.51314,73.8567,0a,75y/data=!3m6!1e1!3m4!1s-huvo4fBlnjw%2FWXnJARb4q7I%2FAAAAAAAAia0%2FJDjPyYRA2L8S4n48xtakPUSglymSICRIACLIBGAYYCw!2e4!3e11!6s%2F%2Flh3.googleusercontent.com%2F-huvo4fBlnjw%2FWXnJARb4q7I%2FAAAAAAAAia0%2FJDjPyYRA2L8S4n48xtakPUSglymSICRIACLIBGAYYCw%2Fno%2Fphoto.jpg"
}
}
]
}
In the result, level object is empty while I have put the level name and number. I'm not getting why it is showing empty.
Can anyone tellme about what step should be follow for publish the multilevel shoot on Google map?
You need to make sure that all photos are very close to each other (~5m) to make the levels control show up.
You could try to send the levels data with a separate photo.update call. Don't forget to use the correct updateMask.
Related
import xml.etree.ElementTree as ET
from zeep import Client, Settings
from zeep.exceptions import Fault, TransportError, XMLSyntaxError
# Set Connection
settings = Settings(strict=False, xml_huge_tree=True)
client = Client('SCHEMA-WSDLs/RateWS.wsdl', settings=settings)
# Set SOAP headers
headers = {
'UPSSecurity': {
'UsernameToken': {
'Username': 'username',
'Password': 'password'
},
'ServiceAccessToken': {
'AccessLicenseNumber': 'asdasdasdasd'
}
}
}
# Create request dictionary
requestDictionary = {
"RequestOption": "Shop",
"TransactionReference": {
"CustomerContext": "Your Customer Context"
}
}
# Create rate request dictionary
rateRequestDictionary = {
"Package": {
"Dimensions": {
"Height": "10",
"Length": "5",
"UnitOfMeasurement": {
"Code": "IN",
"Description": "inches"
},
"Width": "4"
},
"PackageWeight": {
"UnitOfMeasurement": {
"Code": "Lbs",
"Description": "pounds"
},
"Weight": "1"
},
"PackagingType": {
"Code": "02",
"Description": "shop"
}
},
"Service": {
"Code": "03",#3 – Standard List Rates
"Description": "Service Code"
},
"ShipFrom": {
"Address": {
"AddressLine": [
"1 toronto rd",
],
"City": "North York",
"CountryCode": "CA",
"PostalCode": "M3J1C8",
"StateProvinceCode": "ON"
},
"Name": "Name"
},
"ShipTo": {
"Address": {
"AddressLine": "15 Hillpark Trail",
"City": "Brampton",
"CountryCode": "CA",
"PostalCode": "L6S1R1",
"StateProvinceCode": "ON"
},
"Name": "Name"
},
"Shipper": {
"Address": {
"AddressLine": [
"Street Name",
],
"City": "Toronto",
"CountryCode": "CA",
"PostalCode": "M3J1C8",
"StateProvinceCode": "ON"
},
"Name": "ZTL",
"ShipperNumber": "+66666666"
}
}
# Try operation
try:
response = client.service.ProcessRate(_soapheaders=headers, Request=requestDictionary,
Shipment=rateRequestDictionary)
print(response)
except Fault as error:
print(ET.tostring(error.detail))
//
how can i get the value of the rate from the response.. just the amount to charge and the code like ground, express or others...,
i want to make an HTML page to choose between express and ground with the value beside,
json response in htmlso the user can choose, then the value of the shipping goes to the total charges in the cart...,
im just getting started with json and apis call
.... //
I got a resultant json from an API in the following format
[{
"Uid": "40cc6103-1cf0-4735-b882-d14d32018e58",
"Id": "9e1a0057-4570-4a6e-8ff5-88b2facbaf4e",
"Details": {
"Name": "Kiran"
}
}, {
"Uid": "40cc6103-1cf0-4735-b882-d14d32018e58",
"Id": "9e1a0057-4570-4a6e-8ff5-88b2facbaf4e",
"Details": {
"Age": "24"
}
},
{
"Uid": "196f5865-e9fe-4847-86ae-97d0bf57b816",
"Id": "84909ecb-c92e-48a7-bcaa-d478bf3a9220",
"Details": {
"Name": "Shreyas"
}
}
]
since the Uid and Id are same for multiple entires, can I club them togeather with Details key being the comma seperate key,value pair? Something like mentioned below
[{
"Uid": "40cc6103-1cf0-4735-b882-d14d32018e58",
"Id": "9e1a0057-4570-4a6e-8ff5-88b2facbaf4e",
"Details": {
"Name": "Kiran",
"Age": "24"
}
},
{
"Uid": "196f5865-e9fe-4847-86ae-97d0bf57b816",
"Id": "84909ecb-c92e-48a7-bcaa-d478bf3a9220",
"Details": {
"Name": "Shreyas"
}
}]
Please Guide me on this for the approach to be followed. Thanks
What you need is the dictionary function update(). Here's an example:
A = [{
"Uid": "40cc6103-1cf0-4735-b882-d14d32018e58",
"Id": "9e1a0057-4570-4a6e-8ff5-88b2facbaf4e",
"Details": {
"Name": "Kiran"
}
}, {
"Uid": "40cc6103-1cf0-4735-b882-d14d32018e58",
"Id": "9e1a0057-4570-4a6e-8ff5-88b2facbaf4e",
"Details": {
"Age": "24"
}
},
{
"Uid": "196f5865-e9fe-4847-86ae-97d0bf57b816",
"Id": "84909ecb-c92e-48a7-bcaa-d478bf3a9220",
"Details": {
"Name": "Shreyas"
}
}
]
B = []
def find(uid, id_):
for i, d in enumerate(B):
if d['Uid'] == uid and d['Id'] == id_:
return i
return -1
for d in A:
if (i := find(d['Uid'], d['Id'])) < 0:
B.append(d)
else:
B[i]['Details'].update(d['Details'])
print(B)
Prettyfied output:
[
{
"Uid": "40cc6103-1cf0-4735-b882-d14d32018e58",
"Id": "9e1a0057-4570-4a6e-8ff5-88b2facbaf4e",
"Details": {
"Name": "Kiran",
"Age": "24"
}
},
{
"Uid": "196f5865-e9fe-4847-86ae-97d0bf57b816",
"Id": "84909ecb-c92e-48a7-bcaa-d478bf3a9220",
"Details": {
"Name": "Shreyas"
}
}
]
Note:
This could be very inefficient if your API response contains very large numbers of dictionaries. You might need a completely different approach
You should iterate over the list and merge with accumulator with (Uid, Id) as key:
from typing import Dict, List
l = [{
"Uid": "40cc6103-1cf0-4735-b882-d14d32018e58",
"Id": "9e1a0057-4570-4a6e-8ff5-88b2facbaf4e",
"Details": {
"Name": "Kiran"
}
}, {
"Uid": "40cc6103-1cf0-4735-b882-d14d32018e58",
"Id": "9e1a0057-4570-4a6e-8ff5-88b2facbaf4e",
"Details": {
"Age": "24"
}
},
{
"Uid": "196f5865-e9fe-4847-86ae-97d0bf57b816",
"Id": "84909ecb-c92e-48a7-bcaa-d478bf3a9220",
"Details": {
"Name": "Shreyas"
}
}
]
def mergeItem(it: Dict, acc: Dict) -> Dict:
uid = it["Uid"]
id = it["Id"]
if (uid, id) in acc:
acc[(uid, id)] = {"Uid": uid, "Id": id, "Details": {**acc[(uid, id)]["Details"], **it["Details"]}}
else:
acc[(uid, id)] = {"Uid": uid, "Id": id, "Details": it["Details"]}
return acc
def mergeList(a:List) -> Dict:
acc = {}
for v in a:
acc = mergeItem(v, acc)
return acc
print(list(mergeList(l).values()))
# [
# {
# 'Uid': '40cc6103-1cf0-4735-b882-d14d32018e58',
# 'Id': '9e1a0057-4570-4a6e-8ff5-88b2facbaf4e',
# 'Details': {'Name': 'Kiran', 'Age': '24'}},
# {
# 'Uid': '196f5865-e9fe-4847-86ae-97d0bf57b816',
# 'Id': '84909ecb-c92e-48a7-bcaa-d478bf3a9220',
# 'Details': {'Name': 'Shreyas'}
# }
# ]
I have a JSON file like as follows in an Elasticsearch index. I need to sort data if the advertisement does not expire and status is true, and then sort them as desc. How can I achieve this?
I tried using end_date sort, but it did not work. Also I need to show all expired data which end_date are expired.
advertisement = [
{
"id": 1,
"name": "test",
"status": True,
"start_date": "2020-08-09",
"end_date": "2020-09-09",
},
{
"id": 2,
"name": "test2",
"status": False,
"start_date": "2020-08-09",
"end_date": "2020-08-09",
}]
This is my elastic search method.
def elastic_search(category=None):
client = Elasticsearch(host="localhost", port=9200)
query_all = {
'size': 10000,
'query': {
"bool": {
"filter": [
{
"match": {
"name": "test"
}
}]
},
},
"sort": [
{
"end_date": {
"type": "date",
"order": 'desc'
}
}
]
}
resp = client.search(
index="my-index",
body=query_all
)
return resp
This is my es response
http://localhost:9200/my-index/_search
{
"took":96,
"timed_out":false,
"_shards":{
"total":5,
"successful":5,
"skipped":0,
"failed":0
},
"hits":{
"total":36,
"max_score":1.0,
"hits":[
{
"_index":"my-index",
"_type":"doc",
"_id":"52",
"_score":1.0,
"_source":{
"id": 1,
"name": "test",
"status": True,
"start_date": "2020-08-09",
"end_date": "2020-09-09",
}
},
{
"_index":"my-index",
"_type":"doc",
"_id":"60",
"_score":1.0,
"_source":{
"id": 1,
"name": "English test",
"status": True,
"start_date": "2020-08-09",
"end_date": "2020-09-09",
}
},
{
"_index":"my-index",
"_type":"doc",
"_id":"40",
"_score":1.0,
"_source":{
"id": 1,
"name": "Designw test",
"status": false,
"start_date": "2020-08-09",
"end_date": "2020-09-09",
}
},
{
"_index":"my-index",
"_type":"doc",
"_id":"41",
"_score":1.0,
"_source":{
"id": 1,
"name": "Designw New",
"status": false,
"start_date": "2020-08-09",
"end_date": "2020-09-09",
}
},
{
"_index":"my-index",
"_type":"doc",
"_id":"59",
"_score":1.0,
"_source":{
"id": 1,
"name": "Designw New",
"status": false,
"start_date": "2020-08-09",
"end_date": "2020-09-09",
}
},
{
"_index":"my-index",
"_type":"doc",
"_id":"62",
"_score":1.0,
"_source":{
"id": 1,
"name": "Designw New",
"status": false,
"start_date": "2020-08-09",
"end_date": "2020-09-09",
}
}
]
}
}
This is my mapping http://localhost:9200/my-index/_mapping response.
"my-index":{
"mappings":{
"_doc":{
"properties":{
"address":{
"properties":{
"name":{
"type":"text",
"fields":{
"keyword":{
"type":"keyword",
"ignore_above":256
}
}
},
"start_date":{
"type":"text",
"fields":{
"keyword":{
"type":"keyword",
"ignore_above":256
}
}
},
"end_date":{
"type":"text",
"fields":{
"keyword":{
"type":"keyword",
"ignore_above":256
}
}
},
"id":{
"type":"long"
},
"status":{
"type":"text",
"fields":{
"keyword":{
"type":"keyword",
"ignore_above":256
}
}
}
}
}
}
}
}
}
}
Two things regarding the mapping:
There's an address field there that's not found in your actual documents. Remove it.
Your dates should be mapped correctly using the date datatype.
A correct mapping would look like this:
{
"properties":{
"end_date":{
"type":"date",
"format":"yyyy-MM-dd"
},
"start_date":{
"type":"date",
"format":"yyyy-MM-dd"
},
//...other properties
}
}
Once you get the mapping right, this query looks for all non-expired ads w/ a true status and sorts by the longest running:
{
"query": {
"bool": {
"must": [
{
"range": {
"end_date": {
"gt": "now"
}
}
},
{
"term": {
"status": {
"value": true
}
}
}
]
}
},
"sort": [
{
"end_date": {
"order": "desc"
}
}
]
}
Alternatively, if you're looking for the expired ones, change gt to lt which stands for less-than.
I am trying to use the HubSpot CRM API to get "All Deals".
The API endpoint is: https://api.hubapi.com/deals/v1/deal/all?hapikey=demo
The JSON returned looks like this...
{
"deals": [
{
"portalId": 62515,
"dealId": 18039629,
"isDeleted": false,
"associations": {
"associatedVids": [],
"associatedCompanyIds": [],
"associatedDealIds": []
},
"properties": {
"dealname": {
"value": "Company",
"timestamp": 1457040864519,
"source": "API",
"sourceId": null
},
"amount": {
"value": "10",
"timestamp": 1457040864519,
"source": "API",
"sourceId": null
},
"closedate": {
"value": "",
"timestamp": 1457040864519,
"source": "API",
"sourceId": null
},
"hubspot_owner_id": {
"value": "11626092",
"timestamp": 1457046177648,
"source": "SALESFORCE",
"sourceId": null
},
"hs_lastmodifieddate": {
"value": "1457046177662",
"timestamp": 1457046177662,
"source": "CALCULATED",
"sourceId": null
},
"hubspot_owner_assigneddate": {
"value": "1457046177648",
"timestamp": 1457046177648,
"source": "SALESFORCE",
"sourceId": null
},
"num_associated_contacts": {
"value": "0",
"timestamp": 0,
"source": "CALCULATED",
"sourceId": null
},
"hs_createdate": {
"value": "1457040864535",
"timestamp": 1457040864535,
"source": null,
"sourceId": null
},
"createdate": {
"value": "1457040864535",
"timestamp": 1457040864535,
"source": null,
"sourceId": null
},
"hs_salesforceopportunityid": {
"value": "00628000007nRyuAAE",
"timestamp": 1457046177648,
"source": "SALESFORCE",
"sourceId": null
}
},
"imports": []
},
{
"portalId": 62515,
"dealId": 18040854,
"isDeleted": false,
"associations": {
"associatedVids": [],
"associatedCompanyIds": [],
"associatedDealIds": []
},
"properties": {
"dealname": {
"value": "5678",
"timestamp": 1457042290572,
"source": "API",
"sourceId": null
},
"amount": {
"value": "750000.0",
"timestamp": 1457042290572,
"source": "API",
"sourceId": null
},
"closedate": {
"value": "",
"timestamp": 1457042290572,
"source": "API",
"sourceId": null
},
"hs_lastmodifieddate": {
"value": "1457042290592",
"timestamp": 1457042290592,
"source": "CALCULATED",
"sourceId": null
},
"num_associated_contacts": {
"value": "0",
"timestamp": 0,
"source": "CALCULATED",
"sourceId": null
},
"hs_createdate": {
"value": "1457042290592",
"timestamp": 1457042290592,
"source": null,
"sourceId": null
},
"createdate": {
"value": "1457042290592",
"timestamp": 1457042290592,
"source": null,
"sourceId": null
}
},
"imports": []
}
],
"hasMore": true,
"offset": 1467187
}
And I understand that if hasMore==true, then you are supposed to grab the offset and include it in another API call something like this: https://api.hubapi.com/deals/v1/deal/all?hapikey=demo&offset=1467187
And then keep doing that until hasMore==false.
I am using the following code to extract the first chunk of JSON from the API:
import requests
url = "https://api.hubapi.com/deals/v1/deal/all"
querystring = {"hapikey":"demo"}
headers = {
'cache-control': "no-cache"
}
response = requests.request("GET", url, headers=headers, params=querystring)
print(response.text)
So... my question is that now I am getting my JSON, how do I:
1) Read one chunk of JSON
2) If hasMore==true then go do #1 again
3) ElseIf hasMore==false then combine ALL the JSON from ALL iterations of #1 above into one big JSON
4) Return the value from #3
Any help please?
Working solution
import json
import requests
url = "https://api.hubapi.com/deals/v1/deal/all"
querystring = {"hapikey":"demo"}
headers = {
'cache-control': "no-cache"
}
all_deals = []
response = requests.request("GET", url, headers=headers, params=querystring).json()
for deal in response['deals']:
all_deals.append(deal)
hasMore = response['hasMore']
offset = response['offset']
while hasMore:
querystring = {
"hapikey":"demo",
"offset":offset
}
response = requests.request("GET", url, headers=headers, params=querystring).json()
for deal in response['deals']:
all_deals.append(deal)
hasMore = response['hasMore']
offset = response['offset']
print(json.dumps(all_deals))
This question already has answers here:
How to get notification when youtube channel uploads video in python
(2 answers)
Closed 7 months ago.
How can I get the id of latest uploaded video in a specific youtube Channel using Python?
You can request JSON and parse it. The following code gives you the first (most recent) result and stores it in first.
import urllib, json
author = 'Google'
inp = urllib.urlopen(r'http://gdata.youtube.com/feeds/api/videos?max-results=1&alt=json&orderby=published&author=' + author)
resp = json.load(inp)
inp.close()
first = resp['feed']['entry'][0]
# Title of the video
print first['title']
# URL
print first['link'][0]['href']
I just looked through the JSON object in an interactive Python shell. You can build your own query or use the one I posted. Remember to change the author. This is a lower level approach, and #Frederik mentioned something a bit higher level.
The first object looks like this.
{
"author": [
{
"name": {
"$t": "Google"
},
"uri": {
"$t": "http://gdata.youtube.com/feeds/api/users/google"
}
}
],
"category": [
{
"scheme": "http://schemas.google.com/g/2005#kind",
"term": "http://gdata.youtube.com/schemas/2007#video"
},
{
"label": "Science & Technology",
"scheme": "http://gdata.youtube.com/schemas/2007/categories.cat",
"term": "Tech"
},
{
"scheme": "http://gdata.youtube.com/schemas/2007/keywords.cat",
"term": "Google Currents"
},
{
"scheme": "http://gdata.youtube.com/schemas/2007/keywords.cat",
"term": "Google"
},
{
"scheme": "http://gdata.youtube.com/schemas/2007/keywords.cat",
"term": "Currents"
},
{
"scheme": "http://gdata.youtube.com/schemas/2007/keywords.cat",
"term": "Magazine App"
},
{
"scheme": "http://gdata.youtube.com/schemas/2007/keywords.cat",
"term": "Reader App"
},
{
"scheme": "http://gdata.youtube.com/schemas/2007/keywords.cat",
"term": "Android"
},
{
"scheme": "http://gdata.youtube.com/schemas/2007/keywords.cat",
"term": "ios"
},
{
"scheme": "http://gdata.youtube.com/schemas/2007/keywords.cat",
"term": "Android phone"
},
{
"scheme": "http://gdata.youtube.com/schemas/2007/keywords.cat",
"term": "Android tablet"
},
{
"scheme": "http://gdata.youtube.com/schemas/2007/keywords.cat",
"term": "iphone"
},
{
"scheme": "http://gdata.youtube.com/schemas/2007/keywords.cat",
"term": "ipad"
}
],
"content": {
"$t": "Google Currents is a new mobile app that lets you enjoy free online magazines and other content optimized for your Android or Apple phones and tablets. Learn more at www.google.com",
"type": "text"
},
"gd$comments": {
"gd$feedLink": {
"countHint": 463,
"href": "http://gdata.youtube.com/feeds/api/videos/5LOcUkm8m9w/comments"
}
},
"gd$rating": {
"average": 4.7557077,
"max": 5,
"min": 1,
"numRaters": 1752,
"rel": "http://schemas.google.com/g/2005#overall"
},
"id": {
"$t": "http://gdata.youtube.com/feeds/api/videos/5LOcUkm8m9w"
},
"link": [
{
"href": "http://www.youtube.com/watch?v=5LOcUkm8m9w&feature=youtube_gdata",
"rel": "alternate",
"type": "text/html"
},
{
"href": "http://gdata.youtube.com/feeds/api/videos/5LOcUkm8m9w/responses",
"rel": "http://gdata.youtube.com/schemas/2007#video.responses",
"type": "application/atom+xml"
},
{
"href": "http://gdata.youtube.com/feeds/api/videos/5LOcUkm8m9w/related",
"rel": "http://gdata.youtube.com/schemas/2007#video.related",
"type": "application/atom+xml"
},
{
"href": "http://m.youtube.com/details?v=5LOcUkm8m9w",
"rel": "http://gdata.youtube.com/schemas/2007#mobile",
"type": "text/html"
},
{
"href": "http://gdata.youtube.com/feeds/api/videos/5LOcUkm8m9w",
"rel": "self",
"type": "application/atom+xml"
}
],
"media$group": {
"media$category": [
{
"$t": "Tech",
"label": "Science & Technology",
"scheme": "http://gdata.youtube.com/schemas/2007/categories.cat"
}
],
"media$content": [
{
"duration": 94,
"expression": "full",
"isDefault": "true",
"medium": "video",
"type": "application/x-shockwave-flash",
"url": "http://www.youtube.com/v/5LOcUkm8m9w?version=3&f=videos&app=youtube_gdata",
"yt$format": 5
},
{
"duration": 94,
"expression": "full",
"medium": "video",
"type": "video/3gpp",
"url": "rtsp://v1.cache8.c.youtube.com/CiILENy73wIaGQncm7xJUpyz5BMYDSANFEgGUgZ2aWRlb3MM/0/0/0/video.3gp",
"yt$format": 1
},
{
"duration": 94,
"expression": "full",
"medium": "video",
"type": "video/3gpp",
"url": "rtsp://v5.cache4.c.youtube.com/CiILENy73wIaGQncm7xJUpyz5BMYESARFEgGUgZ2aWRlb3MM/0/0/0/video.3gp",
"yt$format": 6
}
],
"media$description": {
"$t": "Google Currents is a new mobile app that lets you enjoy free online magazines and other content optimized for your Android or Apple phones and tablets. Learn more at www.google.com",
"type": "plain"
},
"media$keywords": {
"$t": "Google Currents, Google, Currents, Magazine App, Reader App, Android, ios, Android phone, Android tablet, iphone, ipad"
},
"media$player": [
{
"url": "http://www.youtube.com/watch?v=5LOcUkm8m9w&feature=youtube_gdata_player"
}
],
"media$thumbnail": [
{
"height": 360,
"time": "00:00:47",
"url": "http://i.ytimg.com/vi/5LOcUkm8m9w/0.jpg",
"width": 480
},
{
"height": 90,
"time": "00:00:23.500",
"url": "http://i.ytimg.com/vi/5LOcUkm8m9w/1.jpg",
"width": 120
},
{
"height": 90,
"time": "00:00:47",
"url": "http://i.ytimg.com/vi/5LOcUkm8m9w/2.jpg",
"width": 120
},
{
"height": 90,
"time": "00:01:10.500",
"url": "http://i.ytimg.com/vi/5LOcUkm8m9w/3.jpg",
"width": 120
}
],
"media$title": {
"$t": "Introducing Google Currents",
"type": "plain"
},
"yt$duration": {
"seconds": "94"
}
},
"published": {
"$t": "2011-12-08T09:10:07.000Z"
},
"title": {
"$t": "Introducing Google Currents",
"type": "text"
},
"updated": {
"$t": "2011-12-14T12:57:53.000Z"
},
"yt$hd": {},
"yt$statistics": {
"favoriteCount": "312",
"viewCount": "420050"
}
}