everydayhero: Developer

Search Fitness Activities

Fitness Activities Leaderboard

GET https://everydayhero.com/api/v2/search/fitness_activities_totals

Parameters

charity_id : optional String or Array
Charity ID, only totals for that the specified Charity will be retrieved. An Array of IDs can be provided, eg: charity_id[]=au-1&charity_id[]=au-2

campaign_id : optional String or Array
Campaign ID, only totals for that the specified Campaign will be retrieved. An Array of IDs can be provided, eg: campaign_id[]=au-1&campaign_id[]=au-2

page_id : optional String or Array
Page ID, only totals for the specified Pages will be retrieved. An Array of IDs can be provided, eg: page_id[]=111&page_id[]=456

team_id : optional String
team_uid : optional String
team_page_id : optional String
Team ID, only totals for that the specified Team will be retrieved.

start_at : optional String/date-time
Start at date, ISO format: “2014-08-20 05:02:13”, filter totals by a range.

end_at : optional String/date-time
End at date, ISO format: “2014-08-20 05:02:13”, filter totals by a range.

type : optional String
Filter by activity type: e.g. bike, gym, hike, run, sport, swim, walk

include_manual : optional Boolean
Include manually entered activities. Default: false.

exclude_virtual : optional Boolean
Exclude virtual activities. Default: false

group_value : optional String/Array
Return pages matching specific page group value, or any of the provided array values. An Array of values can be provided, eg: group_value[]=QLD&group_value[]=ABC

min_distance_in_meters : optional Integer
Returns pages that have achieved a specified distance value. This is a post-filter action that may reduce the result set lower than the limit.

max_distance_in_meters : optional Integer
Returns pages that are under a specified distance value. This is a post-filter action that may reduce the result set lower than the limit.

exclude_non_virtual : optional Boolean
Exclude non-virtual activities. Default: false

Includes all above paramaters as well as

group_by : optional String
Group results by pages or teams. Default: pages

sort_by : optional String
Sort results by distance_in_meters, duration_in_seconds, elevation_in_meters or calories. Default: distance_in_meters

limit : optional Integer
Returns a specified number of records. Default: 200.

Example

https://everydayhero.com/api/v2/search/fitness_activities_totals.json?campaign_id=au-0&type=bike&group_by=pages

Response

{
  "results": [
    {
      "count": 374,
      "calories": 95173,
      "elevation_in_meters": 0,
      "distance_in_meters": 22419600,
      "duration_in_seconds": 1351500,
      "page": {
        "id": 274309,
        "name": "Sam's Page",
        "url": "https://give.everydayhero.com/au/samantha",
        "target_cents": 58100,
        "charity_name": "Australian Mitochondrial Disease Foundation",
        "image": {
          "original_image_url": "https://d3r0m2twuddj1w.cloudfront.net/assets/pages/images/original/missing-287b7881555195b87fb952fff10d1055.gif",
          "tiny_image_url": "https://d3r0m2twuddj1w.cloudfront.net/assets/pages/images/tiny/missing-86b4014d2c2a8802376800af9035e6f2.gif",
          "small_image_url": "https://d3r0m2twuddj1w.cloudfront.net/assets/pages/images/small/missing-8f1165a727871b3370402cd59ec43690.gif",
          "medium_image_url": "https://d3r0m2twuddj1w.cloudfront.net/assets/pages/images/medium/missing-b2926d047013659ed9e5cb85add1de64.gif",
          "large_image_url": "https://d3r0m2twuddj1w.cloudfront.net/assets/pages/images/large/missing-73dc8fb87713b4c3fd2eba7ba6f3085b.gif",
          "extra_large_image_url": "https://d3r0m2twuddj1w.cloudfront.net/pages/images/extra_large/missing.gif"
        },
        "amount": {
          "cents": 0,
          "currency": {
            "iso_code": "AUD",
            "name": "Australian Dollar",
            "symbol": "$"
          }
        }
      }
    }
  ]
}