node package manager
Stop writing boring code. Discover, share, and reuse within your team. Create a free org »

transitandtrails

transitandtrails

I am a Node.js client for the Transit & Trails API.

Installation

npm install transitandtrails

Usage

var TransitAndTrails = require("transitandtrails");
 
var tnt = new TransitAndTrails({
  key: "<API key>"
});
 
tnt.getTrailhead(292, function(err, trailhead) {
  if (err) {
    throw err;
  }
 
  console.log(trailhead);
};

Environment Variables

  • TNT_API_KEY - (optional) API key.
  • TNT_URL_PREFIX - (optional) alternate URL prefix. Defaults to https://www.transitandtrails.org.

License

Copyright (c) 2013 Seth Fitzsimmons

Published under the MIT license.