https://github.com/jaebradley/nba-stats-client
🏀 JavaScript Client for stats from NBA.com
https://github.com/jaebradley/nba-stats-client
javascript nba nba-stats npm-package
Last synced: 6 months ago
JSON representation
🏀 JavaScript Client for stats from NBA.com
- Host: GitHub
- URL: https://github.com/jaebradley/nba-stats-client
- Owner: jaebradley
- License: mit
- Created: 2016-10-03T01:51:22.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2022-02-09T19:18:46.000Z (over 3 years ago)
- Last Synced: 2025-03-25T17:46:49.856Z (7 months ago)
- Topics: javascript, nba, nba-stats, npm-package
- Language: JavaScript
- Homepage: https://www.npmjs.com/package/nba-stats-client
- Size: 4.89 MB
- Stars: 31
- Watchers: 4
- Forks: 2
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# NBA Stats Client

[](https://codecov.io/gh/jaebradley/nba-stats-client)
[](https://www.npmjs.com/package/nba-stats-client)

[](https://www.npmjs.com/package/nba-stats-client)
## Installation
```bash
npm install nba-stats-client
```## API
```javascript
import {
getGames,
getBoxScore,
getPlayByPlay,
};// gets games for a particular date
const games = await getGames({ year: 2018, month: 1, day: 1 });// gets box score for a particular game (based on NBA.com's unique ID) and date
const boxScore = await getBoxScore({ year: 2018, month: 1, day: 1, gameId: '1234' });// gets play by play events for a particular game (based on NBA.com's unique ID) and date
const playByPlay = await getPlayByPlay({ year: 2018, month: 1, day: 1, gameId: '1234' });
```