Use the College Basketball Data API to query game, team, player, recruiting, and analytics data. Request an API key at CollegeBasketballData.com.
This Python package is automatically generated by the OpenAPI Generator project:
- API version: 1.28.0
- Package version: 1.28.0
- Generator version: 7.12.0
- Build package: org.openapitools.codegen.languages.PythonPydanticV1ClientCodegen
Python 3.7+
pip install cbbd@1.28.0(you may need to run pip with root permission: sudo pip install cbbd@1.28.0)
Then import the package:
importcbbdPlease follow the installation procedure and then run the following:
importtimeimportcbbdfromcbbd.restimportApiExceptionfrompprintimportpprint# Defining the host is optional and defaults to https://api.collegebasketballdata.com# See configuration.py for a list of all supported configuration parameters.configuration=cbbd.Configuration(
host="https://api.collegebasketballdata.com"
)
# The client must configure the authentication and authorization parameters# in accordance with the API server security policy.# Examples for each auth method are provided below, use the example that# satisfies your auth use case.# Configure Bearer authorization: apiKeyconfiguration=cbbd.Configuration(
access_token=os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API clientwithcbbd.ApiClient(configuration) asapi_client:
# Create an instance of the API classapi_instance=cbbd.ConferencesApi(api_client)
conference='conference_example'# str | Filters results to the specified conference abbreviation. (optional)try:
api_response=api_instance.get_conference_history(conference=conference)
print("The response of ConferencesApi->get_conference_history:\n")
pprint(api_response)
exceptApiExceptionase:
print("Exception when calling ConferencesApi->get_conference_history: %s\n"%e)All URIs are relative to https://api.collegebasketballdata.com
| Class | Method | HTTP request | Description |
|---|---|---|---|
| ConferencesApi | get_conference_history | GET /conferences/history | |
| ConferencesApi | get_conferences | GET /conferences | |
| DraftApi | get_draft_picks | GET /draft/picks | |
| DraftApi | get_draft_positions | GET /draft/positions | |
| DraftApi | get_draft_teams | GET /draft/teams | |
| GamesApi | get_broadcasts | GET /games/media | |
| GamesApi | get_game_players | GET /games/players | |
| GamesApi | get_game_teams | GET /games/teams | |
| GamesApi | get_games | GET /games | |
| GamesApi | get_scoreboard | GET /scoreboard | |
| LinesApi | get_lines | GET /lines | |
| LinesApi | get_providers | GET /lines/providers | |
| LineupsApi | get_lineup_stats_by_game | GET /lineups/game/{gameId} | |
| LineupsApi | get_lineups_by_team_season | GET /lineups/team | |
| PlaysApi | get_play_types | GET /plays/types | |
| PlaysApi | get_plays | GET /plays/game/{gameId} | |
| PlaysApi | get_plays_by_date | GET /plays/date | |
| PlaysApi | get_plays_by_player_id | GET /plays/player/{playerId} | |
| PlaysApi | get_plays_by_team | GET /plays/team | |
| PlaysApi | get_plays_by_tournament | GET /plays/tournament | |
| PlaysApi | get_substitutions_by_game | GET /substitutions/game/{gameId} | |
| PlaysApi | get_substitutions_by_player_id | GET /substitutions/player/{playerId} | |
| PlaysApi | get_substitutions_by_team | GET /substitutions/team | |
| RankingsApi | get_rankings | GET /rankings | |
| RatingsApi | get_adjusted_efficiency | GET /ratings/adjusted | |
| RatingsApi | get_elo | GET /ratings/elo | |
| RatingsApi | get_srs | GET /ratings/srs | |
| RecruitingApi | get_portal_transfers | GET /recruiting/portal | |
| RecruitingApi | get_recruits | GET /recruiting/players | |
| RecruitingApi | get_team_recruiting_rankings | GET /recruiting/teams | |
| StatsApi | get_player_season_shooting_stats | GET /stats/player/shooting/season | |
| StatsApi | get_player_season_stats | GET /stats/player/season | |
| StatsApi | get_team_leaderboard_stats | GET /stats/team/leaderboard | |
| StatsApi | get_team_season_shooting_stats | GET /stats/team/shooting/season | |
| StatsApi | get_team_season_stats | GET /stats/team/season | |
| TeamsApi | get_team_roster | GET /teams/roster | |
| TeamsApi | get_teams | GET /teams | |
| VenuesApi | get_venues | GET /venues |
- AdjustedEfficiencyInfo
- AdjustedEfficiencyInfoRankings
- ConferenceHistory
- ConferenceHistoryTeamsInner
- ConferenceInfo
- DraftPick
- DraftPosition
- DraftTeam
- GameBoxScorePlayers
- GameBoxScorePlayersPlayersInner
- GameBoxScoreTeam
- GameBoxScoreTeamStats
- GameBoxScoreTeamStatsPoints
- GameInfo
- GameLineInfo
- GameLines
- GameMediaInfo
- GameMediaInfoBroadcastsInner
- GameStatus
- LineProviderInfo
- LineupStats
- LineupUnitStats
- LineupUnitStatsFourFactors
- LineupUnitStatsTwoPointers
- PlayInfo
- PlayInfoOnFloorInner
- PlayInfoParticipantsInner
- PlayTypeInfo
- PlayerSeasonShootingStats
- PlayerSeasonStats
- PlayerSeasonStatsWinShares
- PlayerSubsititution
- PlayerSubsititutionSubIn
- PollTeamInfo
- Recruit
- RecruitCommittedTo
- RecruitHometown
- ScoreboardGame
- ScoreboardGameBetting
- ScoreboardGameHomeTeam
- SeasonShootingStats
- SeasonShootingStatsAttemptsBreakdown
- SeasonShootingStatsDunks
- SeasonType
- ShootingStats
- ShotInfo
- ShotInfoLocation
- ShotInfoShooter
- ShotTypeBreakdown
- SrsInfo
- TeamElo
- TeamInfo
- TeamLeaderboardAdjustedEfficiency
- TeamLeaderboardAdjustedEfficiencyRankings
- TeamRecruitingRanking
- TeamRoster
- TeamRosterPlayer
- TeamRosterPlayerHometown
- TeamSeasonStats
- TeamSeasonUnitStats
- TeamSeasonUnitStatsFieldGoals
- TeamSeasonUnitStatsFouls
- TeamSeasonUnitStatsFourFactors
- TeamSeasonUnitStatsPoints
- TeamSeasonUnitStatsRebounds
- TeamSeasonUnitStatsTurnovers
- TeamStatsLeaderboardConference
- TeamStatsLeaderboardRecord
- TeamStatsLeaderboardRecordSummary
- TeamStatsLeaderboardShotProfile
- TeamStatsLeaderboardShotProfileAtRim
- TeamStatsLeaderboardShotProfileDistribution
- TeamStatsLeaderboardShotProfileDunk
- TeamStatsLeaderboardShotProfileFreeThrows
- TeamStatsLeaderboardShotProfileTipIn
- TeamStatsLeaderboardShotProfileTwoPointJumper
- TeamStatsLeaderboardSummary
- TeamStatsLeaderboardUnitStats
- TeamStatsLeaderboardUnitStatsFieldGoals
- TeamStatsLeaderboardUnitStatsFouls
- TeamStatsLeaderboardUnitStatsPoints
- TeamStatsLeaderboardUnitStatsRebounds
- TeamStatsLeaderboardUnitStatsTurnovers
- Transfer
- TransferEligibility
- TransferOrigin
- VenueInfo
Authentication schemes defined for the API:
- Type: Bearer authentication