Package Exports
- tba-api
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (tba-api) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
tba-api-node
Simple Node API Library for The Blue Alliance
Usage
Installation
npm install tba-api
Headers
The Blue Alliance API V2 requires users to identify with a username, app description, and app version. The authentication can be read about in more detail here. Authentication using this library is simple:
const tba = require('tba-api');
tba.initHeaders(username, app_description, app_version)For example:
const tba = require('tba-api');
tba.initHeaders('astronautlevel', 'tba-api-test-app', 'v0.0.1')Method Overview
Team Requests
getTeamList(pageNum, callback)
getTeam(teamNum, callback)
getTeamEvents(teamNum[, year], callback)
getTeamEventAwards(teamNum, eventCode, callback)
getTeamEventMatches(teamNum, eventCode, callback)
getYearsParticipated(teamNum, callback)
getTeamMedia(teamNum[, year], callback)
getTeamEventHistory(teamNum, callback)
getTeamAwardHistory(teamNum, callback)
getTeamRobotHistory(teamNum, callback)
getTeamDistrictHistory(teamNum, callback)
Event Requests
getEventList(year, callback)
getEvent(eventCode, callback)
getEventTeams(eventCode, callback)
getEventMatches(eventCode, callback)
getEventStats(eventCode, callback)
getEventRankings(eventCode, callback)
getEventAwards(eventCode, callback)
getEventDistrictPoints(eventCode, callback)
Match Requests
getSingleMatch(matchKey, callback)
District Requests
getDistrictList(year, callback)
getDistrictEvents(district, year, callback)
getDistrictRankings(district, year, callback)
getDistrictTeams(district, year, callback)