| 
  • If you are citizen of an European Union member nation, you may not use this service unless you are at least 16 years old.

  • You already know Dokkio is an AI-powered assistant to organize & manage your digital files & messages. Very soon, Dokkio will support Outlook as well as One Drive. Check it out today!

View
 

geo

Page history last edited by Tadas Vilkeliskis 12 years, 3 months ago

About this call


 

Geo returns geographical information about n recent visitors.  This call returns sampled data.

 

Format


 

http://api.chartbeat.com/live/geo/?host=[host]&limit=[limit]&path=[path]&section=[section]&author=[author]&apikey=[apikey]

 

  • host - Required.  The domain name to get recent information about.
  • apikey - Required.  An api key generated here that gives access to this call.
  • section - Optional. Newsbeat only. Limit the geo data to a specific section.
  • author - Optional. Newsbeat only. Limit the geo data to a specific author. 
  • path - Optional.  Give a specific path.  If not given, data is from all paths. (Example, the path of http://chartbeat.com/signup/ is /signup/) 
  • limit - Optional.  Limit the amount of recent data to this number. (Default: 100)
  • jsonp - Optional.  Give the name of a function to wrap the return data in. Learn more here

 

Example


 

http://api.chartbeat.com/live/geo/?host=chartbeat.com&limit=10&apikey=abc123
 

 

Example return:

 

     {

          "regions": {

               "None": 2,

               "27": 1,

               "CA": 1,

               "40": 1

          },

          "lat_lngs": [

               ["32", "35", 1],

               ["14", "101", 1],

               ["-24", "-47", 1],

               ["62", "15", 1],

               ["34", "-118", 1]

          ],

          "countries": {

               "US": 1,

               "BR": 1,

               "SE": 1,

               "TH": 1,

               "IL": 1

          }

     }

 

Return variables


 

  • regions - Map of region code to number of visitors.
  • lat_lngs - Tuple of latitude, longitude, visitors.
  • countries - Map of country code to number of visitors. 

 

Comments (0)

You don't have permission to comment on this page.