PySports: Python module to access cricket scores and more.
Project description
##PySports : Python module to access cricket scores and more.
PySports is a Reusable python app which provides a features to access live scores, upcoming matches, historical matches and more. PySports is rich features and powerful enough, You can start with PySports without installation of any 3rd party packages.
Installation :
You can install PySports from PyPI using pip.
pip install pysports
Configuration :
-
In order to use PySports it required an API Key, You can generate the API Key from CricAPI.com.
-
Open your Text Editor/Python CLI and write the following code.
from pysports.cricapi import CricAPI cric = CricAPI("PASTE_YOUR_CRICAPI_API_KEY_HERE")
- Access Live Score of any matches by PySports.
To access live score of any matches it required the unique_id/match_id of the match.
cric.live_score("INT_UNIQUE_ID")
- Access the list of Upcoming Matches by PySports.
To access the list of upcoming matches write the following code.
cric.upcoming_matches()
- Access the list of Historical Matches by PySports.
To access the list of Historical matches write the following code.
cric.historical_matches()
- Access the Scorecard/Summary of the matches by PySports.
To access the scorecard/summary of the matches it required the unique_id/match_id of the match, Write the following code.
cric.match_summary("INT_UNIQUE_ID")
- Access the Detail of Players by PySports.
To access the details/information of the players it required the pid/player_id of the players, Write the following code.
cric.about_player("INT_PLAYER_ID")
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.