bart-sdk
v1.0.2
Published
BART SDK for NodeJS
Downloads
25
Maintainers
Readme
BART API Client SDK
it helps to consume bart API easier.
Install
$ npm install bart-sdk
API
const client = require('../src/bart').createClient();
Returns a BartClient
object
BartClient
stations
client.stations((err, stations)=>{console.dir(stations});
/*
result:
[
{
"name": "12th St. Oakland City Center",
"abbr": "12TH",
"latitude": "37.803664",
"longitude": "-122.271604",
"address": "1245 Broadway",
"city": "Oakland",
"county": "alameda",
"state": "CA",
"zipcode": "94612"
},
{
"name": "16th St. Mission",
"abbr": "16TH",
"latitude": "37.765062",
"longitude": "-122.419694",
"address": "2000 Mission Street",
"city": "San Francisco",
"county": "sanfrancisco",
"state": "CA",
"zipcode": "94110"
},
...
]
*/
Tests
Tests included use Mocha. Use npm test
to run the tests
$ npm test
Contributing
Contributions to the project are welcome. Feel free to fork and improve. I accept pull requests when tests are included.