NBA.Stats.TeamYearByYearStats (nba_api_ex v0.1.0)
View SourceProvides functions to interact with the NBA stats API for TeamYearByYearStats.
See get/2 for parameter and usage details.
Summary
Functions
Parameters
params: A keyword list of parameters to filter the data.TeamID: (Required) The team ID.- Type(s):
Integer - Default:
nil
- Type(s):
LeagueID: The league ID (2-digit string).- Type(s):
String - Default:
"00" - Valueset:
"00""10"
- Type(s):
PerMode: The per mode for stats.- Type(s):
String - Default:
"Totals" - Valueset:
"Totals""PerGame"
- Type(s):
SeasonType: The season type.- Type(s):
String - Default:
"Regular Season" - Valueset:
"Regular Season""Pre Season""Playoffs""All Star"
- Type(s):
opts: A keyword list of additional options for the request, such as headers or timeout settings.- For a full list of options, see the Req documentation.
Returns
{:ok, data}: On success, returns the data from the API.{:error, reason}: On failure, returns an error tuple with the reason.
Example
iex> NBA.Stats.TeamYearByYearStats.get(TeamID: 1610612744)
{:ok, %{"TeamYearByYearStats" => [%{...}, ...]}}