Skip to content

Latest commit

 

History

History
658 lines (478 loc) · 22.8 KB

MatchApi.md

File metadata and controls

658 lines (478 loc) · 22.8 KB

MatchApi

All URIs are relative to https://www.thebluealliance.com/api/v3

Method HTTP request Description
getEventMatches GET /event/{event_key}/matches
getEventMatchesKeys GET /event/{event_key}/matches/keys
getEventMatchesSimple GET /event/{event_key}/matches/simple
getMatch GET /match/{match_key}
getMatchSimple GET /match/{match_key}/simple
getTeamEventMatches GET /team/{team_key}/event/{event_key}/matches
getTeamEventMatchesKeys GET /team/{team_key}/event/{event_key}/matches/keys
getTeamEventMatchesSimple GET /team/{team_key}/event/{event_key}/matches/simple
getTeamMatchesByYear GET /team/{team_key}/matches/{year}
getTeamMatchesByYearKeys GET /team/{team_key}/matches/{year}/keys
getTeamMatchesByYearSimple GET /team/{team_key}/matches/{year}/simple

getEventMatches

List<Match> getEventMatches(eventKey, ifModifiedSince)

Gets a list of matches for the given event.

Example

// Import classes:
//import net.thefletcher.tbaapi.v3client.ApiClient;
//import net.thefletcher.tbaapi.v3client.ApiException;
//import net.thefletcher.tbaapi.v3client.Configuration;
//import net.thefletcher.tbaapi.v3client.auth.*;
//import net.thefletcher.tbaapi.v3client.api.MatchApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: apiKey
ApiKeyAuth apiKey = (ApiKeyAuth) defaultClient.getAuthentication("apiKey");
apiKey.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//apiKey.setApiKeyPrefix("Token");

MatchApi apiInstance = new MatchApi();
String eventKey = "eventKey_example"; // String | TBA Event Key, eg `2016nytr`
String ifModifiedSince = "ifModifiedSince_example"; // String | Value of the `Last-Modified` header in the most recently cached response by the client.
try {
    List<Match> result = apiInstance.getEventMatches(eventKey, ifModifiedSince);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling MatchApi#getEventMatches");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
eventKey String TBA Event Key, eg `2016nytr`
ifModifiedSince String Value of the `Last-Modified` header in the most recently cached response by the client. [optional]

Return type

List<Match>

Authorization

apiKey

HTTP request headers

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

getEventMatchesKeys

List<String> getEventMatchesKeys(eventKey, ifModifiedSince)

Gets a list of match keys for the given event.

Example

// Import classes:
//import net.thefletcher.tbaapi.v3client.ApiClient;
//import net.thefletcher.tbaapi.v3client.ApiException;
//import net.thefletcher.tbaapi.v3client.Configuration;
//import net.thefletcher.tbaapi.v3client.auth.*;
//import net.thefletcher.tbaapi.v3client.api.MatchApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: apiKey
ApiKeyAuth apiKey = (ApiKeyAuth) defaultClient.getAuthentication("apiKey");
apiKey.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//apiKey.setApiKeyPrefix("Token");

MatchApi apiInstance = new MatchApi();
String eventKey = "eventKey_example"; // String | TBA Event Key, eg `2016nytr`
String ifModifiedSince = "ifModifiedSince_example"; // String | Value of the `Last-Modified` header in the most recently cached response by the client.
try {
    List<String> result = apiInstance.getEventMatchesKeys(eventKey, ifModifiedSince);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling MatchApi#getEventMatchesKeys");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
eventKey String TBA Event Key, eg `2016nytr`
ifModifiedSince String Value of the `Last-Modified` header in the most recently cached response by the client. [optional]

Return type

List<String>

Authorization

apiKey

HTTP request headers

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

getEventMatchesSimple

List<MatchSimple> getEventMatchesSimple(eventKey, ifModifiedSince)

Gets a short-form list of matches for the given event.

Example

// Import classes:
//import net.thefletcher.tbaapi.v3client.ApiClient;
//import net.thefletcher.tbaapi.v3client.ApiException;
//import net.thefletcher.tbaapi.v3client.Configuration;
//import net.thefletcher.tbaapi.v3client.auth.*;
//import net.thefletcher.tbaapi.v3client.api.MatchApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: apiKey
ApiKeyAuth apiKey = (ApiKeyAuth) defaultClient.getAuthentication("apiKey");
apiKey.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//apiKey.setApiKeyPrefix("Token");

MatchApi apiInstance = new MatchApi();
String eventKey = "eventKey_example"; // String | TBA Event Key, eg `2016nytr`
String ifModifiedSince = "ifModifiedSince_example"; // String | Value of the `Last-Modified` header in the most recently cached response by the client.
try {
    List<MatchSimple> result = apiInstance.getEventMatchesSimple(eventKey, ifModifiedSince);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling MatchApi#getEventMatchesSimple");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
eventKey String TBA Event Key, eg `2016nytr`
ifModifiedSince String Value of the `Last-Modified` header in the most recently cached response by the client. [optional]

Return type

List<MatchSimple>

Authorization

apiKey

HTTP request headers

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

getMatch

Match getMatch(matchKey, ifModifiedSince)

Gets a `Match` object for the given match key.

Example

// Import classes:
//import net.thefletcher.tbaapi.v3client.ApiClient;
//import net.thefletcher.tbaapi.v3client.ApiException;
//import net.thefletcher.tbaapi.v3client.Configuration;
//import net.thefletcher.tbaapi.v3client.auth.*;
//import net.thefletcher.tbaapi.v3client.api.MatchApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: apiKey
ApiKeyAuth apiKey = (ApiKeyAuth) defaultClient.getAuthentication("apiKey");
apiKey.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//apiKey.setApiKeyPrefix("Token");

MatchApi apiInstance = new MatchApi();
String matchKey = "matchKey_example"; // String | TBA Match Key, eg `2016nytr_qm1`
String ifModifiedSince = "ifModifiedSince_example"; // String | Value of the `Last-Modified` header in the most recently cached response by the client.
try {
    Match result = apiInstance.getMatch(matchKey, ifModifiedSince);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling MatchApi#getMatch");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
matchKey String TBA Match Key, eg `2016nytr_qm1`
ifModifiedSince String Value of the `Last-Modified` header in the most recently cached response by the client. [optional]

Return type

Match

Authorization

apiKey

HTTP request headers

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

getMatchSimple

MatchSimple getMatchSimple(matchKey, ifModifiedSince)

Gets a short-form `Match` object for the given match key.

Example

// Import classes:
//import net.thefletcher.tbaapi.v3client.ApiClient;
//import net.thefletcher.tbaapi.v3client.ApiException;
//import net.thefletcher.tbaapi.v3client.Configuration;
//import net.thefletcher.tbaapi.v3client.auth.*;
//import net.thefletcher.tbaapi.v3client.api.MatchApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: apiKey
ApiKeyAuth apiKey = (ApiKeyAuth) defaultClient.getAuthentication("apiKey");
apiKey.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//apiKey.setApiKeyPrefix("Token");

MatchApi apiInstance = new MatchApi();
String matchKey = "matchKey_example"; // String | TBA Match Key, eg `2016nytr_qm1`
String ifModifiedSince = "ifModifiedSince_example"; // String | Value of the `Last-Modified` header in the most recently cached response by the client.
try {
    MatchSimple result = apiInstance.getMatchSimple(matchKey, ifModifiedSince);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling MatchApi#getMatchSimple");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
matchKey String TBA Match Key, eg `2016nytr_qm1`
ifModifiedSince String Value of the `Last-Modified` header in the most recently cached response by the client. [optional]

Return type

MatchSimple

Authorization

apiKey

HTTP request headers

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

getTeamEventMatches

List<Match> getTeamEventMatches(teamKey, eventKey, ifModifiedSince)

Gets a list of matches for the given team and event.

Example

// Import classes:
//import net.thefletcher.tbaapi.v3client.ApiClient;
//import net.thefletcher.tbaapi.v3client.ApiException;
//import net.thefletcher.tbaapi.v3client.Configuration;
//import net.thefletcher.tbaapi.v3client.auth.*;
//import net.thefletcher.tbaapi.v3client.api.MatchApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: apiKey
ApiKeyAuth apiKey = (ApiKeyAuth) defaultClient.getAuthentication("apiKey");
apiKey.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//apiKey.setApiKeyPrefix("Token");

MatchApi apiInstance = new MatchApi();
String teamKey = "teamKey_example"; // String | TBA Team Key, eg `frc254`
String eventKey = "eventKey_example"; // String | TBA Event Key, eg `2016nytr`
String ifModifiedSince = "ifModifiedSince_example"; // String | Value of the `Last-Modified` header in the most recently cached response by the client.
try {
    List<Match> result = apiInstance.getTeamEventMatches(teamKey, eventKey, ifModifiedSince);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling MatchApi#getTeamEventMatches");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
teamKey String TBA Team Key, eg `frc254`
eventKey String TBA Event Key, eg `2016nytr`
ifModifiedSince String Value of the `Last-Modified` header in the most recently cached response by the client. [optional]

Return type

List<Match>

Authorization

apiKey

HTTP request headers

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

getTeamEventMatchesKeys

List<String> getTeamEventMatchesKeys(teamKey, eventKey, ifModifiedSince)

Gets a list of match keys for matches for the given team and event.

Example

// Import classes:
//import net.thefletcher.tbaapi.v3client.ApiClient;
//import net.thefletcher.tbaapi.v3client.ApiException;
//import net.thefletcher.tbaapi.v3client.Configuration;
//import net.thefletcher.tbaapi.v3client.auth.*;
//import net.thefletcher.tbaapi.v3client.api.MatchApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: apiKey
ApiKeyAuth apiKey = (ApiKeyAuth) defaultClient.getAuthentication("apiKey");
apiKey.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//apiKey.setApiKeyPrefix("Token");

MatchApi apiInstance = new MatchApi();
String teamKey = "teamKey_example"; // String | TBA Team Key, eg `frc254`
String eventKey = "eventKey_example"; // String | TBA Event Key, eg `2016nytr`
String ifModifiedSince = "ifModifiedSince_example"; // String | Value of the `Last-Modified` header in the most recently cached response by the client.
try {
    List<String> result = apiInstance.getTeamEventMatchesKeys(teamKey, eventKey, ifModifiedSince);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling MatchApi#getTeamEventMatchesKeys");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
teamKey String TBA Team Key, eg `frc254`
eventKey String TBA Event Key, eg `2016nytr`
ifModifiedSince String Value of the `Last-Modified` header in the most recently cached response by the client. [optional]

Return type

List<String>

Authorization

apiKey

HTTP request headers

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

getTeamEventMatchesSimple

List<Match> getTeamEventMatchesSimple(teamKey, eventKey, ifModifiedSince)

Gets a short-form list of matches for the given team and event.

Example

// Import classes:
//import net.thefletcher.tbaapi.v3client.ApiClient;
//import net.thefletcher.tbaapi.v3client.ApiException;
//import net.thefletcher.tbaapi.v3client.Configuration;
//import net.thefletcher.tbaapi.v3client.auth.*;
//import net.thefletcher.tbaapi.v3client.api.MatchApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: apiKey
ApiKeyAuth apiKey = (ApiKeyAuth) defaultClient.getAuthentication("apiKey");
apiKey.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//apiKey.setApiKeyPrefix("Token");

MatchApi apiInstance = new MatchApi();
String teamKey = "teamKey_example"; // String | TBA Team Key, eg `frc254`
String eventKey = "eventKey_example"; // String | TBA Event Key, eg `2016nytr`
String ifModifiedSince = "ifModifiedSince_example"; // String | Value of the `Last-Modified` header in the most recently cached response by the client.
try {
    List<Match> result = apiInstance.getTeamEventMatchesSimple(teamKey, eventKey, ifModifiedSince);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling MatchApi#getTeamEventMatchesSimple");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
teamKey String TBA Team Key, eg `frc254`
eventKey String TBA Event Key, eg `2016nytr`
ifModifiedSince String Value of the `Last-Modified` header in the most recently cached response by the client. [optional]

Return type

List<Match>

Authorization

apiKey

HTTP request headers

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

getTeamMatchesByYear

List<Match> getTeamMatchesByYear(teamKey, year, ifModifiedSince)

Gets a list of matches for the given team and year.

Example

// Import classes:
//import net.thefletcher.tbaapi.v3client.ApiClient;
//import net.thefletcher.tbaapi.v3client.ApiException;
//import net.thefletcher.tbaapi.v3client.Configuration;
//import net.thefletcher.tbaapi.v3client.auth.*;
//import net.thefletcher.tbaapi.v3client.api.MatchApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: apiKey
ApiKeyAuth apiKey = (ApiKeyAuth) defaultClient.getAuthentication("apiKey");
apiKey.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//apiKey.setApiKeyPrefix("Token");

MatchApi apiInstance = new MatchApi();
String teamKey = "teamKey_example"; // String | TBA Team Key, eg `frc254`
BigDecimal year = new BigDecimal(); // BigDecimal | Competition Year (or Season). Must be 4 digits.
String ifModifiedSince = "ifModifiedSince_example"; // String | Value of the `Last-Modified` header in the most recently cached response by the client.
try {
    List<Match> result = apiInstance.getTeamMatchesByYear(teamKey, year, ifModifiedSince);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling MatchApi#getTeamMatchesByYear");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
teamKey String TBA Team Key, eg `frc254`
year BigDecimal Competition Year (or Season). Must be 4 digits.
ifModifiedSince String Value of the `Last-Modified` header in the most recently cached response by the client. [optional]

Return type

List<Match>

Authorization

apiKey

HTTP request headers

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

getTeamMatchesByYearKeys

List<String> getTeamMatchesByYearKeys(teamKey, year, ifModifiedSince)

Gets a list of match keys for matches for the given team and year.

Example

// Import classes:
//import net.thefletcher.tbaapi.v3client.ApiClient;
//import net.thefletcher.tbaapi.v3client.ApiException;
//import net.thefletcher.tbaapi.v3client.Configuration;
//import net.thefletcher.tbaapi.v3client.auth.*;
//import net.thefletcher.tbaapi.v3client.api.MatchApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: apiKey
ApiKeyAuth apiKey = (ApiKeyAuth) defaultClient.getAuthentication("apiKey");
apiKey.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//apiKey.setApiKeyPrefix("Token");

MatchApi apiInstance = new MatchApi();
String teamKey = "teamKey_example"; // String | TBA Team Key, eg `frc254`
BigDecimal year = new BigDecimal(); // BigDecimal | Competition Year (or Season). Must be 4 digits.
String ifModifiedSince = "ifModifiedSince_example"; // String | Value of the `Last-Modified` header in the most recently cached response by the client.
try {
    List<String> result = apiInstance.getTeamMatchesByYearKeys(teamKey, year, ifModifiedSince);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling MatchApi#getTeamMatchesByYearKeys");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
teamKey String TBA Team Key, eg `frc254`
year BigDecimal Competition Year (or Season). Must be 4 digits.
ifModifiedSince String Value of the `Last-Modified` header in the most recently cached response by the client. [optional]

Return type

List<String>

Authorization

apiKey

HTTP request headers

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

getTeamMatchesByYearSimple

List<MatchSimple> getTeamMatchesByYearSimple(teamKey, year, ifModifiedSince)

Gets a short-form list of matches for the given team and year.

Example

// Import classes:
//import net.thefletcher.tbaapi.v3client.ApiClient;
//import net.thefletcher.tbaapi.v3client.ApiException;
//import net.thefletcher.tbaapi.v3client.Configuration;
//import net.thefletcher.tbaapi.v3client.auth.*;
//import net.thefletcher.tbaapi.v3client.api.MatchApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure API key authorization: apiKey
ApiKeyAuth apiKey = (ApiKeyAuth) defaultClient.getAuthentication("apiKey");
apiKey.setApiKey("YOUR API KEY");
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//apiKey.setApiKeyPrefix("Token");

MatchApi apiInstance = new MatchApi();
String teamKey = "teamKey_example"; // String | TBA Team Key, eg `frc254`
BigDecimal year = new BigDecimal(); // BigDecimal | Competition Year (or Season). Must be 4 digits.
String ifModifiedSince = "ifModifiedSince_example"; // String | Value of the `Last-Modified` header in the most recently cached response by the client.
try {
    List<MatchSimple> result = apiInstance.getTeamMatchesByYearSimple(teamKey, year, ifModifiedSince);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling MatchApi#getTeamMatchesByYearSimple");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
teamKey String TBA Team Key, eg `frc254`
year BigDecimal Competition Year (or Season). Must be 4 digits.
ifModifiedSince String Value of the `Last-Modified` header in the most recently cached response by the client. [optional]

Return type

List<MatchSimple>

Authorization

apiKey

HTTP request headers

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