Skip to main content
Glama
stevenyuser

NBA MCP Server

by stevenyuser

get_league_team_standings

Retrieve NBA team standings for a specific season and season type using the NBA MCP Server. Input the season in 'YYYY-YY' format and specify the season type (e.g., 'Regular Season') to access accurate standings data.

Instructions

Get league team standings for a given season and season type.

Args: season: str The season in the format 'YYYY-YY'. season_type: str The type of season. Pattern: "Regular Season", "Pre Season"

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
seasonYes
season_typeYes

Implementation Reference

  • The handler function for the 'get_league_team_standings' tool, decorated with @mcp.tool for registration. It fetches league standings using nba_api's leaguestandingsv3.LeagueStandingsV3 endpoint.
    @mcp.tool def get_league_team_standings(season: str, season_type: str) -> dict: """ Get league team standings for a given season and season type. Args: season: str The season in the format 'YYYY-YY'. season_type: str The type of season. Pattern: "Regular Season", "Pre Season" """ try: standings = leaguestandingsv3.LeagueStandingsV3(league_id="00", season=season, season_type=season_type) return standings.get_dict() except Exception as e: return {"error": str(e)}

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/stevenyuser/nba_mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server