Google Feed APi & JSON

Using google feed API to download a google alert feed and convert to json

[ note: the below command as is copy paste might now work, after copy paste on terminal, change start quote of https and end quote before test_id to single quote from keyboard. ]

$ curl -e http://www.my-ajax-site.com ‘https://ajax.googleapis.com/ajax/services/feed/load?v=1.0&num=1&q=https://www.google.com/alerts/feeds/14384131864905067124/13622349005191651788&callback=rssReader.parse&context=’test_id

 

Above command returns json like below, [ Note: in above command you can change URL, id i.e. test_id and “num” ( we are using num=1 for testing ] /* callback */rssReader.parse(‘test_id’, {“feed”:{“feedUrl”:”https://www.google.com/alerts/feeds/14384131864905067124/13622349005191651788″,”title”:”Google Alert – agriculture”,”link”:””,”author”:””,”description”:””,”type”:”atom10″,”entries”:[{“title”:”UPDATE 2-US top court rules for California farmers over government raisin program”,”link”:”https://www.google.com/url?rctu003dju0026sau003dtu0026urlu003dhttp://in.reuters.com/article/2015/06/22/usa-court-raisins-idINL1N0Z80TV20150622u0026ctu003dgau0026cdu003dCAIyHmNlZDA1YTEzMDg0MTJhMzc6Y28uaW46ZW46SU46Ugu0026usgu003dAFQjCNFVa1VlKOOuT6WnEws9OQ34WWXGwQ”,”author”:””,”publishedDate”:”Mon, 22 Jun 2015 09:41:15 -0700″,”contentSnippet”:”The U.S. Department of Agriculture program traces its roots to the Agricultural Marketing Agreement Act, which was passed in …”,”content”:”The U.S. Department of u003cbu003eAgricultureu003c/bu003e program traces its roots to the u003cbu003eAgriculturalu003c/bu003e Marketing Agreement Act, which was passed in 1937 to control the …”,”categories”:[]}]}}, 200, null, 200)

READ  BinUtils Basics

 

Reference : https://developers.google.com/feed/v1/jsondevguide

Leave a Reply

Your email address will not be published. Required fields are marked *