public ITeam GetTeamById(int id) { var team = ApiUtility.GetDeserializeObject <StatTeamApi>($"{baseApiUrl}{endpoints[ApiEndpoints.Teams]}/{id}").Teams.FirstOrDefault(); return(team ?? null); }
public IList <RosterPlayer> GetTeamRoster(int id) { var apiTeamRoster = ApiUtility.GetDeserializeObject <StatPlayerApi>($"{baseApiUrl}{endpoints[ApiEndpoints.Teams]}/{id}/roster"); return(apiTeamRoster.Roster ?? null); }
public IList <ITeam> GetAllTeams() { var apiTeams = ApiUtility.GetDeserializeObject <StatTeamApi>($"{baseApiUrl}{endpoints[ApiEndpoints.Teams]}"); return(apiTeams.Teams ?? null); }