Skip to content

Latest commit

 

History

History
351 lines (267 loc) · 9.49 KB

TeamsApi.md

File metadata and controls

351 lines (267 loc) · 9.49 KB

CFBSharp.Api.TeamsApi

All URIs are relative to https://api.collegefootballdata.com

Method HTTP request Description
GetFbsTeams GET /teams/fbs FBS team list
GetRoster GET /roster Team rosters
GetTalent GET /talent Team talent composite rankings
GetTeamMatchup GET /teams/matchup Team matchup history
GetTeams GET /teams Team information

GetFbsTeams

ICollection GetFbsTeams (int? year = null)

FBS team list

Information on major division teams

Example

using System;
using System.Diagnostics;
using CFBSharp.Api;
using CFBSharp.Client;
using CFBSharp.Model;

namespace Example
{
    public class GetFbsTeamsExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.AddApiKey("Authorization", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.AddApiKeyPrefix("Authorization", "Bearer");

            var apiInstance = new TeamsApi();
            var year = 56;  // int? | Year filter (optional) 

            try
            {
                // FBS team list
                ICollection<Team> result = apiInstance.GetFbsTeams(year);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling TeamsApi.GetFbsTeams: " + e.Message );
            }
        }
    }
}

Parameters

Name Type Description Notes
year int? Year filter [optional]

Return type

ICollection

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetRoster

ICollection GetRoster (string team = null, int? year = null)

Team rosters

Roster data

Example

using System;
using System.Diagnostics;
using CFBSharp.Api;
using CFBSharp.Client;
using CFBSharp.Model;

namespace Example
{
    public class GetRosterExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.AddApiKey("Authorization", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.AddApiKeyPrefix("Authorization", "Bearer");

            var apiInstance = new TeamsApi();
            var team = team_example;  // string | Team name (optional) 
            var year = 56;  // int? | Season year (optional) 

            try
            {
                // Team rosters
                ICollection<Player> result = apiInstance.GetRoster(team, year);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling TeamsApi.GetRoster: " + e.Message );
            }
        }
    }
}

Parameters

Name Type Description Notes
team string Team name [optional]
year int? Season year [optional]

Return type

ICollection

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetTalent

ICollection GetTalent (int? year = null)

Team talent composite rankings

Team talent composite

Example

using System;
using System.Diagnostics;
using CFBSharp.Api;
using CFBSharp.Client;
using CFBSharp.Model;

namespace Example
{
    public class GetTalentExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.AddApiKey("Authorization", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.AddApiKeyPrefix("Authorization", "Bearer");

            var apiInstance = new TeamsApi();
            var year = 56;  // int? | Year filter (optional) 

            try
            {
                // Team talent composite rankings
                ICollection<TeamTalent> result = apiInstance.GetTalent(year);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling TeamsApi.GetTalent: " + e.Message );
            }
        }
    }
}

Parameters

Name Type Description Notes
year int? Year filter [optional]

Return type

ICollection

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetTeamMatchup

TeamMatchup GetTeamMatchup (string team1, string team2, int? minYear = null, int? maxYear = null)

Team matchup history

Matchup history

Example

using System;
using System.Diagnostics;
using CFBSharp.Api;
using CFBSharp.Client;
using CFBSharp.Model;

namespace Example
{
    public class GetTeamMatchupExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.AddApiKey("Authorization", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.AddApiKeyPrefix("Authorization", "Bearer");

            var apiInstance = new TeamsApi();
            var team1 = team1_example;  // string | First team
            var team2 = team2_example;  // string | Second team
            var minYear = 56;  // int? | Minimum year (optional) 
            var maxYear = 56;  // int? | Maximum year (optional) 

            try
            {
                // Team matchup history
                TeamMatchup result = apiInstance.GetTeamMatchup(team1, team2, minYear, maxYear);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling TeamsApi.GetTeamMatchup: " + e.Message );
            }
        }
    }
}

Parameters

Name Type Description Notes
team1 string First team
team2 string Second team
minYear int? Minimum year [optional]
maxYear int? Maximum year [optional]

Return type

TeamMatchup

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetTeams

ICollection GetTeams (string conference = null)

Team information

Get team information

Example

using System;
using System.Diagnostics;
using CFBSharp.Api;
using CFBSharp.Client;
using CFBSharp.Model;

namespace Example
{
    public class GetTeamsExample
    {
        public void main()
        {
            // Configure API key authorization: ApiKeyAuth
            Configuration.Default.AddApiKey("Authorization", "YOUR_API_KEY");
            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
            // Configuration.Default.AddApiKeyPrefix("Authorization", "Bearer");

            var apiInstance = new TeamsApi();
            var conference = conference_example;  // string | Conference abbreviation filter (optional) 

            try
            {
                // Team information
                ICollection<Team> result = apiInstance.GetTeams(conference);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling TeamsApi.GetTeams: " + e.Message );
            }
        }
    }
}

Parameters

Name Type Description Notes
conference string Conference abbreviation filter [optional]

Return type

ICollection

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]