• Register

ACTIVE Network API Forums

API Forum

RSS Feed

Problem with Location filter

    • Manfung
    • Topic created 13 years ago

    Filtering location to UK still bring back USA results.

    http://api.amp.active.com/search?k=&l=51.484576;-0.115356&m=meta:channel=running&f=activities&v=json&api_key=API_KEY http://api.amp.active.com/search?k=&l=london,greater+london,uk-england&m=meta:channel=running&f=activities&v=json&api_key=API_KEY

    resulted in 4 UK and 2 USA results

    Looking at the data it looks like incorrect Lat and Long. Is there any way to filter results on country to avoid bad data?

    Message edited by Manfung 13 years ago

  1. active Admin13 years ago

    Hey Manfung,

    Unfortunately this is a case of us having bad data. The filters you've applied will work in most cases. Also of note, our inventory is admittedly thin in the UK. You're bound to find much more data in the US and Canada.

  2. BMironov13 years ago

    Hello Admin,

    What would be a correct location search criteria for Ontario,Canada? I have tried different combinations of Canada's and Ontario codes but none seems to work. I realize that this could be a "bad data" issue.

    As an example, I have tried to pull information about swim meet "2012 TOP CUP SC" that took place on May 11-13, 2012 and is presenting correctly via MeetMobile. Unfortunately, I failed to get a combination of parameters that would present it via API.

    Any guidance?

    Thanks, Boris

  3. jarredd13 years ago

    Hello Boris,

    I tried the following and it worked:

    http://api.amp.active.com/search?f=activities&v=xml&num=100&k=&l=Ontario%2CCANADA&r=50&m=meta%3AendDate%3Adaterange%3Atoday..&api_key=wuhmn9ye94xn3xnteudxsavw

    Here's the rules for location parameter:

    l = location

    To narrow a search to a geographic area, use the l parameter to specify a location. The formats available are: city,state,country postal code,country state,country postal code (US is assumed country) state (US is assumed country)

    Just remember to escape the ',' in the API call.

    Best Regards,

    Jarred

    Technical Account Manager, Active Network

[ Page 1 of 1 ]