summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.gitignore1
-rw-r--r--python-nba-api.spec386
-rw-r--r--sources1
3 files changed, 388 insertions, 0 deletions
diff --git a/.gitignore b/.gitignore
index e69de29..8b76742 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/nba_api-1.2.tar.gz
diff --git a/python-nba-api.spec b/python-nba-api.spec
new file mode 100644
index 0000000..9cf8951
--- /dev/null
+++ b/python-nba-api.spec
@@ -0,0 +1,386 @@
+%global _empty_manifest_terminate_build 0
+Name: python-nba-api
+Version: 1.2
+Release: 1
+Summary: An API Client package to access the APIs for NBA.com
+License: MIT
+URL: https://github.com/swar/nba_api
+Source0: https://mirrors.nju.edu.cn/pypi/web/packages/03/a4/fdfdb5573effb7efbf09a77c8568a582552d828a5b2aedcc01331a91b6e1/nba_api-1.2.tar.gz
+BuildArch: noarch
+
+Requires: python3-requests
+Requires: python3-numpy
+
+%description
+[![Version: PyPI](https://img.shields.io/pypi/v/nba_api.svg?longCache=true&style=for-the-badge&logo=pypi)](https://pypi.python.org/pypi/nba_api)
+[![Downloads per Month: PyPY](https://img.shields.io/pypi/dm/nba_api.svg?style=for-the-badge)](https://pepy.tech/project/nba-api)
+[![Build: CircleCI](https://img.shields.io/circleci/project/github/swar/nba_api.svg?style=for-the-badge&logo=circleci)](https://circleci.com/gh/swar/nba_api)
+[![License: MIT](https://img.shields.io/github/license/swar/nba_api.svg?style=for-the-badge)](https://github.com/swar/nba_api/blob/master/LICENSE)
+[![Slack](https://img.shields.io/badge/Slack-NBA_API-4A154B?style=for-the-badge&logo=slack)](https://join.slack.com/t/nbaapi/shared_invite/zt-1ipsuai9j-GjZjuP9S2~Uczuny1t74zA)
+
+# nba_api
+
+## An API Client Package to Access the APIs of NBA.com
+
+`nba_api` is an API Client for `www.nba.com`. This package intends to make the APIs of [NBA.com](https://www.nba.com/) easily accessible and provide extensive documentation about them.
+
+# Getting Started
+
+`nba_api` requires Python 3.7+ along with the `requests` and `numpy` packages. While `panadas` is not required, it is required to work with Pandas DataFrames.
+
+```bash
+pip install nba_api
+```
+
+## NBA Official Stats
+
+```python
+from nba_api.stats.endpoints import playercareerstats
+
+# Nikola Jokić
+career = playercareerstats.PlayerCareerStats(player_id='203999')
+
+# pandas data frames (optional: pip install pandas)
+career.get_data_frames()[0]
+
+# json
+career.get_json()
+
+# dictionary
+career.get_dict()
+```
+
+## NBA Live Data
+
+```python
+from nba_api.live.nba.endpoints import scoreboard
+
+# Today's Score Board
+games = scoreboard.ScoreBoard()
+
+# json
+games.get_json()
+
+# dictionary
+games.get_dict()
+```
+
+## Additional Examples
+
+- [Requests/Response Options](https://github.com/swar/nba_api/blob/master/docs/nba_api/stats/examples.md#endpoint-usage-example)
+ - Proxy Support, Custom Headers, and Timeout Settings
+ - Return Types and Raw Responses
+- [Static Data Sets](https://github.com/swar/nba_api/blob/master/docs/nba_api/stats/examples.md#static-usage-examples)
+ - Reduce HTTP requests for common and frequently accessed player and team data.
+- [Jupyter Notebooks](https://github.com/swar/nba_api/tree/master/docs/examples)
+ - Practical examples in Jupyter Notebook format, including making basic calls, finding games, working with play-by-play data, and interacting with live game data.
+
+# Documentation
+
+- [Table of Contents](https://github.com/swar/nba_api/tree/master/docs/table_of_contents.md)
+- [Package Structure](https://github.com/swar/nba_api/tree/master/docs/package_structure.md)
+- [Endpoints](/docs/nba_api/stats/endpoints)
+- Static Data Sets
+ - [players.py](https://github.com/swar/nba_api/tree/master/docs/nba_api/stats/static/players.md)
+ - [teams.py](https://github.com/swar/nba_api/tree/master/docs/nba_api/stats/static/teams.md)
+
+# Join the Community
+## Slack
+
+Join [Slack](https://join.slack.com/t/nbaapi/shared_invite/zt-1ipsuai9j-GjZjuP9S2~Uczuny1t74zA) to get help, help others, provide feedback, see amazing projects, participates in discussions, and collaborate with others from around the world.
+
+## Stack Overflow
+
+Not a Slack fan? No problem. Head over to [StackOverflow](https://stackoverflow.com/questions/tagged/nba-api). Be sure to tag your post with `nba-api`.
+
+# Contributing
+
+*See [Contributing to the NBA_API](https://github.com/swar/nba_api/blob/master/CONTRIBUTING.md) for complete details.*
+
+## Endpoints
+
+A significant purpose of this package is to continuously map and analyze as many endpoints on NBA.com as possible. The documentation and analysis of the endpoints and parameters in this package are some of the most extensive information available. At the same time, NBA.com does not provide information regarding new, changed, or removed endpoints.
+
+If you find a new, changed, or deprecated endpoint, open a [GitHub Issue](https://github.com/swar/nba_api/issues)
+
+## Bugs
+
+Encounter a bug, [report a bug](https://github.com/swar/nba_api/issues).
+
+# License & Terms of Use
+
+## API Client Package
+
+The `nba_api` package is Open Source with an [MIT License](https://github.com/swar/nba_api/blob/master/LICENSE).
+
+## NBA.com
+
+NBA.com has a [Terms of Use](https://www.nba.com/termsofuse) regarding the use of the NBA’s digital platforms.
+
+
+%package -n python3-nba-api
+Summary: An API Client package to access the APIs for NBA.com
+Provides: python-nba-api
+BuildRequires: python3-devel
+BuildRequires: python3-setuptools
+BuildRequires: python3-pip
+%description -n python3-nba-api
+[![Version: PyPI](https://img.shields.io/pypi/v/nba_api.svg?longCache=true&style=for-the-badge&logo=pypi)](https://pypi.python.org/pypi/nba_api)
+[![Downloads per Month: PyPY](https://img.shields.io/pypi/dm/nba_api.svg?style=for-the-badge)](https://pepy.tech/project/nba-api)
+[![Build: CircleCI](https://img.shields.io/circleci/project/github/swar/nba_api.svg?style=for-the-badge&logo=circleci)](https://circleci.com/gh/swar/nba_api)
+[![License: MIT](https://img.shields.io/github/license/swar/nba_api.svg?style=for-the-badge)](https://github.com/swar/nba_api/blob/master/LICENSE)
+[![Slack](https://img.shields.io/badge/Slack-NBA_API-4A154B?style=for-the-badge&logo=slack)](https://join.slack.com/t/nbaapi/shared_invite/zt-1ipsuai9j-GjZjuP9S2~Uczuny1t74zA)
+
+# nba_api
+
+## An API Client Package to Access the APIs of NBA.com
+
+`nba_api` is an API Client for `www.nba.com`. This package intends to make the APIs of [NBA.com](https://www.nba.com/) easily accessible and provide extensive documentation about them.
+
+# Getting Started
+
+`nba_api` requires Python 3.7+ along with the `requests` and `numpy` packages. While `panadas` is not required, it is required to work with Pandas DataFrames.
+
+```bash
+pip install nba_api
+```
+
+## NBA Official Stats
+
+```python
+from nba_api.stats.endpoints import playercareerstats
+
+# Nikola Jokić
+career = playercareerstats.PlayerCareerStats(player_id='203999')
+
+# pandas data frames (optional: pip install pandas)
+career.get_data_frames()[0]
+
+# json
+career.get_json()
+
+# dictionary
+career.get_dict()
+```
+
+## NBA Live Data
+
+```python
+from nba_api.live.nba.endpoints import scoreboard
+
+# Today's Score Board
+games = scoreboard.ScoreBoard()
+
+# json
+games.get_json()
+
+# dictionary
+games.get_dict()
+```
+
+## Additional Examples
+
+- [Requests/Response Options](https://github.com/swar/nba_api/blob/master/docs/nba_api/stats/examples.md#endpoint-usage-example)
+ - Proxy Support, Custom Headers, and Timeout Settings
+ - Return Types and Raw Responses
+- [Static Data Sets](https://github.com/swar/nba_api/blob/master/docs/nba_api/stats/examples.md#static-usage-examples)
+ - Reduce HTTP requests for common and frequently accessed player and team data.
+- [Jupyter Notebooks](https://github.com/swar/nba_api/tree/master/docs/examples)
+ - Practical examples in Jupyter Notebook format, including making basic calls, finding games, working with play-by-play data, and interacting with live game data.
+
+# Documentation
+
+- [Table of Contents](https://github.com/swar/nba_api/tree/master/docs/table_of_contents.md)
+- [Package Structure](https://github.com/swar/nba_api/tree/master/docs/package_structure.md)
+- [Endpoints](/docs/nba_api/stats/endpoints)
+- Static Data Sets
+ - [players.py](https://github.com/swar/nba_api/tree/master/docs/nba_api/stats/static/players.md)
+ - [teams.py](https://github.com/swar/nba_api/tree/master/docs/nba_api/stats/static/teams.md)
+
+# Join the Community
+## Slack
+
+Join [Slack](https://join.slack.com/t/nbaapi/shared_invite/zt-1ipsuai9j-GjZjuP9S2~Uczuny1t74zA) to get help, help others, provide feedback, see amazing projects, participates in discussions, and collaborate with others from around the world.
+
+## Stack Overflow
+
+Not a Slack fan? No problem. Head over to [StackOverflow](https://stackoverflow.com/questions/tagged/nba-api). Be sure to tag your post with `nba-api`.
+
+# Contributing
+
+*See [Contributing to the NBA_API](https://github.com/swar/nba_api/blob/master/CONTRIBUTING.md) for complete details.*
+
+## Endpoints
+
+A significant purpose of this package is to continuously map and analyze as many endpoints on NBA.com as possible. The documentation and analysis of the endpoints and parameters in this package are some of the most extensive information available. At the same time, NBA.com does not provide information regarding new, changed, or removed endpoints.
+
+If you find a new, changed, or deprecated endpoint, open a [GitHub Issue](https://github.com/swar/nba_api/issues)
+
+## Bugs
+
+Encounter a bug, [report a bug](https://github.com/swar/nba_api/issues).
+
+# License & Terms of Use
+
+## API Client Package
+
+The `nba_api` package is Open Source with an [MIT License](https://github.com/swar/nba_api/blob/master/LICENSE).
+
+## NBA.com
+
+NBA.com has a [Terms of Use](https://www.nba.com/termsofuse) regarding the use of the NBA’s digital platforms.
+
+
+%package help
+Summary: Development documents and examples for nba-api
+Provides: python3-nba-api-doc
+%description help
+[![Version: PyPI](https://img.shields.io/pypi/v/nba_api.svg?longCache=true&style=for-the-badge&logo=pypi)](https://pypi.python.org/pypi/nba_api)
+[![Downloads per Month: PyPY](https://img.shields.io/pypi/dm/nba_api.svg?style=for-the-badge)](https://pepy.tech/project/nba-api)
+[![Build: CircleCI](https://img.shields.io/circleci/project/github/swar/nba_api.svg?style=for-the-badge&logo=circleci)](https://circleci.com/gh/swar/nba_api)
+[![License: MIT](https://img.shields.io/github/license/swar/nba_api.svg?style=for-the-badge)](https://github.com/swar/nba_api/blob/master/LICENSE)
+[![Slack](https://img.shields.io/badge/Slack-NBA_API-4A154B?style=for-the-badge&logo=slack)](https://join.slack.com/t/nbaapi/shared_invite/zt-1ipsuai9j-GjZjuP9S2~Uczuny1t74zA)
+
+# nba_api
+
+## An API Client Package to Access the APIs of NBA.com
+
+`nba_api` is an API Client for `www.nba.com`. This package intends to make the APIs of [NBA.com](https://www.nba.com/) easily accessible and provide extensive documentation about them.
+
+# Getting Started
+
+`nba_api` requires Python 3.7+ along with the `requests` and `numpy` packages. While `panadas` is not required, it is required to work with Pandas DataFrames.
+
+```bash
+pip install nba_api
+```
+
+## NBA Official Stats
+
+```python
+from nba_api.stats.endpoints import playercareerstats
+
+# Nikola Jokić
+career = playercareerstats.PlayerCareerStats(player_id='203999')
+
+# pandas data frames (optional: pip install pandas)
+career.get_data_frames()[0]
+
+# json
+career.get_json()
+
+# dictionary
+career.get_dict()
+```
+
+## NBA Live Data
+
+```python
+from nba_api.live.nba.endpoints import scoreboard
+
+# Today's Score Board
+games = scoreboard.ScoreBoard()
+
+# json
+games.get_json()
+
+# dictionary
+games.get_dict()
+```
+
+## Additional Examples
+
+- [Requests/Response Options](https://github.com/swar/nba_api/blob/master/docs/nba_api/stats/examples.md#endpoint-usage-example)
+ - Proxy Support, Custom Headers, and Timeout Settings
+ - Return Types and Raw Responses
+- [Static Data Sets](https://github.com/swar/nba_api/blob/master/docs/nba_api/stats/examples.md#static-usage-examples)
+ - Reduce HTTP requests for common and frequently accessed player and team data.
+- [Jupyter Notebooks](https://github.com/swar/nba_api/tree/master/docs/examples)
+ - Practical examples in Jupyter Notebook format, including making basic calls, finding games, working with play-by-play data, and interacting with live game data.
+
+# Documentation
+
+- [Table of Contents](https://github.com/swar/nba_api/tree/master/docs/table_of_contents.md)
+- [Package Structure](https://github.com/swar/nba_api/tree/master/docs/package_structure.md)
+- [Endpoints](/docs/nba_api/stats/endpoints)
+- Static Data Sets
+ - [players.py](https://github.com/swar/nba_api/tree/master/docs/nba_api/stats/static/players.md)
+ - [teams.py](https://github.com/swar/nba_api/tree/master/docs/nba_api/stats/static/teams.md)
+
+# Join the Community
+## Slack
+
+Join [Slack](https://join.slack.com/t/nbaapi/shared_invite/zt-1ipsuai9j-GjZjuP9S2~Uczuny1t74zA) to get help, help others, provide feedback, see amazing projects, participates in discussions, and collaborate with others from around the world.
+
+## Stack Overflow
+
+Not a Slack fan? No problem. Head over to [StackOverflow](https://stackoverflow.com/questions/tagged/nba-api). Be sure to tag your post with `nba-api`.
+
+# Contributing
+
+*See [Contributing to the NBA_API](https://github.com/swar/nba_api/blob/master/CONTRIBUTING.md) for complete details.*
+
+## Endpoints
+
+A significant purpose of this package is to continuously map and analyze as many endpoints on NBA.com as possible. The documentation and analysis of the endpoints and parameters in this package are some of the most extensive information available. At the same time, NBA.com does not provide information regarding new, changed, or removed endpoints.
+
+If you find a new, changed, or deprecated endpoint, open a [GitHub Issue](https://github.com/swar/nba_api/issues)
+
+## Bugs
+
+Encounter a bug, [report a bug](https://github.com/swar/nba_api/issues).
+
+# License & Terms of Use
+
+## API Client Package
+
+The `nba_api` package is Open Source with an [MIT License](https://github.com/swar/nba_api/blob/master/LICENSE).
+
+## NBA.com
+
+NBA.com has a [Terms of Use](https://www.nba.com/termsofuse) regarding the use of the NBA’s digital platforms.
+
+
+%prep
+%autosetup -n nba-api-1.2
+
+%build
+%py3_build
+
+%install
+%py3_install
+install -d -m755 %{buildroot}/%{_pkgdocdir}
+if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi
+if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi
+if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi
+if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi
+pushd %{buildroot}
+if [ -d usr/lib ]; then
+ find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+if [ -d usr/lib64 ]; then
+ find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+if [ -d usr/bin ]; then
+ find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+if [ -d usr/sbin ]; then
+ find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+touch doclist.lst
+if [ -d usr/share/man ]; then
+ find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst
+fi
+popd
+mv %{buildroot}/filelist.lst .
+mv %{buildroot}/doclist.lst .
+
+%files -n python3-nba-api -f filelist.lst
+%dir %{python3_sitelib}/*
+
+%files help -f doclist.lst
+%{_docdir}/*
+
+%changelog
+* Mon May 15 2023 Python_Bot <Python_Bot@openeuler.org> - 1.2-1
+- Package Spec generated
diff --git a/sources b/sources
new file mode 100644
index 0000000..0033c3f
--- /dev/null
+++ b/sources
@@ -0,0 +1 @@
+1513e5d08cb3b74500653e72ed13bd9c nba_api-1.2.tar.gz