Frequently Asked Questions

Where does the data come from?

Multiple sources including user-generated content, the public domain, and content created by our editors. All content is constantly evaluated for completeness, organization, and accuracy.

How do I acccess outdoor data?

You'll need to sign up to get a unique API key. This key will be used in your application to make requests and will allow us to track usage. You can also use this "test" key (which is subject to change): 4016165acc967a9800153c77a3528d83

How do I submit items to the API?

While the API itself is read-only, there are a couple ways to add items to the data service. Read more here.

What are the terms of service? 

The Trail API terms of service are subject to change (we'll notify registered users) but here's the jist:

  • At a minimum, your app or website must include a link to TrailAPI.com (unless you're using our white label solution) and the text "Copyright 2012 TrailAPI." For individual park or trail results, we also ask that you include the 'url' link somewhere on your page with the text "More details" or similar.
  • It's OK to cache information from TrailAPI in your database but you should check each record at least once every 7 days for updates/deletions. If your TrailAPI key expires you'll need to remove any TrailAPI data from your database.
  • In the future we may elect to rate-limit Trail API requests. Free account holders will have an opportunity to purchase additional request blocks.
  • If you have any questions about usage, contact info@trailapi.com.

Blue Spruce Ventures reserves the right to continually review and evaluate all uses of the API, including those that appear more competitive than complementary in nature. The company reserves the right to terminate your rights to use any TrailAPI content at any time. We'll always try our best to contact you to resolve any issues that may arise.

How do I query the API?

API requests require an API Key [use 4016165acc967a9800153c77a3528d83 if you don't have a key yet]. The request should use the following url: https://outdoor-data-api.herokuapp.com/api.json and should include the api_key parameter.

for example https://outdoor-data-api.herokuapp.com/api.json?api_key=API\_KEY\_GOES\_HERE

API requests from javascript require an additional parameter, callback, which specifies the callback method of the JSONP response. This is to circumvent the Same Origin Policy restrictions.

Search Parameters Names

These parameters can be passed to the api to modify the search:

  • limit: the number of results returned. defaults to 100

Activities

  • activity type name (ex. hiking, camping)
    • q[activities_activity_type_name_cont], q[children_activities_activity_type_name_cont]: a 'like' search
    • q[activities_activity_type_name_eq], q[children_activities_activity_type_name_eq]: an 'equals' search
  • specific item name (ex. yellow river trail, thunder rock campground)
    • q[activities_activity_name_eq], q[activities_activity_name_cont]: item name equal or like search
  • length
    • q[activities_length_gteq]: length value greater than or equal to
    • q[activities_length_lteq]: length value less than or equal to

Places

  • city
    • q[city_eq], q[city_cont]: search for city using like or equals
  • state
    • q[state_eq], q[state_cont]: search for state using like or equals
  • country
    • q[country_eq], q[country_cont]: search for country using like or equals
  • name
    • q[name_eq], q[name_cont]: search for place name using like or equals

Location Search using latitude, longitude, and geocoding

  • radius: width of search radius, in miles. default = 10
  • lat: latitude value
  • lon: longitude value

What do the API results look like?

Here's what a typical data record looks like for a search of all activities near Vail, CO.

{
	places: [
		{
			city: "Avon",
			state: "Colorado",
			country: "United States",
			name: "Beaver Creek Ski Resort",
			parent_id: null,
			unique_id: 721,
			directions: "From Denver, take I-70 West to exit 167, Avon.  Follow the signs to the Beaver Creek Ski resort.  There is no parking once you're up the mountain so be sure to make arrangements.",
			lat: 39.63121,
			lon: -106.52535,
			description: null,
			date_created: null,
			children: [ ],
			activities: [
				{
					name: "Beaver Creek Ski Resort",
					unique_id: "1-711",
					place_id: 721,
					activity_type_id: 5,
					activity_type_name: "mountain biking",
					url: "http://www.singletracks.com/bike-trails/beaver-creek-ski-resort.html",
					attribs: {"length": ""5""},
					description: "There are tons of trails here but only a few are serviced by the summer lift.  If you are in great shape (or too cheap to buy a ticket), skip the lift and ride up the mountain (all 2000 vertical feet).  The "Blue" trails are the singletrack options and they can be pretty challenging for most riders.  The singletrack was mostly washed out and very rooty and steep in sections.  If you choose the "Green" trails, be prepared to take the road all the way to the bottom.  Overall, not one of the best lift serviced downhills available.  Go to Keystone instead (although the scenery is tough to beat).",
					length: 5,
					activity_type: {
						created_at: "2012-08-15T16:12:35Z",
						id: 5,
						name: "mountain biking",
						updated_at: "2012-08-15T16:12:35Z"
					},
					thumbnail: "http://www.singletracks.com/images/uploads/2011/07/IMG_0416-0-thumb.jpg",
					rank: null,
					rating: 3.8
				},
				{ ... },
				{ ... },
				{ ... },
				{ ... }
			]
		},
		{ ... }
	]
}
			

 

© 2014 Blue Spruce Ventures LLC. All rights reserved.