Skip to content

Latest commit

 

History

History
executable file
·
513 lines (348 loc) · 17.6 KB

DistrictApi.md

File metadata and controls

executable file
·
513 lines (348 loc) · 17.6 KB

swagger.api.DistrictApi

Load the API package

import 'package:swagger/api.dart';

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

Method HTTP request Description
getDistrictEvents GET /district/{district_key}/events
getDistrictEventsKeys GET /district/{district_key}/events/keys
getDistrictEventsSimple GET /district/{district_key}/events/simple
getDistrictRankings GET /district/{district_key}/rankings
getDistrictTeams GET /district/{district_key}/teams
getDistrictTeamsKeys GET /district/{district_key}/teams/keys
getDistrictTeamsSimple GET /district/{district_key}/teams/simple
getDistrictsByYear GET /districts/{year}
getEventDistrictPoints GET /event/{event_key}/district_points
getTeamDistricts GET /team/{team_key}/districts

getDistrictEvents

List getDistrictEvents(districtKey, ifModifiedSince)

Gets a list of events in the given district.

Example

import 'package:swagger/api.dart';
// TODO Configure API key authorization: apiKey
//swagger.api.Configuration.apiKey{'X-TBA-Auth-Key'} = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//swagger.api.Configuration.apiKeyPrefix{'X-TBA-Auth-Key'} = "Bearer";

var api_instance = new DistrictApi();
var districtKey = districtKey_example; // String | TBA District Key, eg `2016fim`
var ifModifiedSince = ifModifiedSince_example; // String | Value of the `Last-Modified` header in the most recently cached response by the client.

try { 
    var result = api_instance.getDistrictEvents(districtKey, ifModifiedSince);
    print(result);
} catch (e) {
    print("Exception when calling DistrictApi->getDistrictEvents: $e\n");
}

Parameters

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

Return type

List

Authorization

apiKey

HTTP request headers

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

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

getDistrictEventsKeys

List getDistrictEventsKeys(districtKey, ifModifiedSince)

Gets a list of event keys for events in the given district.

Example

import 'package:swagger/api.dart';
// TODO Configure API key authorization: apiKey
//swagger.api.Configuration.apiKey{'X-TBA-Auth-Key'} = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//swagger.api.Configuration.apiKeyPrefix{'X-TBA-Auth-Key'} = "Bearer";

var api_instance = new DistrictApi();
var districtKey = districtKey_example; // String | TBA District Key, eg `2016fim`
var ifModifiedSince = ifModifiedSince_example; // String | Value of the `Last-Modified` header in the most recently cached response by the client.

try { 
    var result = api_instance.getDistrictEventsKeys(districtKey, ifModifiedSince);
    print(result);
} catch (e) {
    print("Exception when calling DistrictApi->getDistrictEventsKeys: $e\n");
}

Parameters

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

Return type

List

Authorization

apiKey

HTTP request headers

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

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

getDistrictEventsSimple

List getDistrictEventsSimple(districtKey, ifModifiedSince)

Gets a short-form list of events in the given district.

Example

import 'package:swagger/api.dart';
// TODO Configure API key authorization: apiKey
//swagger.api.Configuration.apiKey{'X-TBA-Auth-Key'} = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//swagger.api.Configuration.apiKeyPrefix{'X-TBA-Auth-Key'} = "Bearer";

var api_instance = new DistrictApi();
var districtKey = districtKey_example; // String | TBA District Key, eg `2016fim`
var ifModifiedSince = ifModifiedSince_example; // String | Value of the `Last-Modified` header in the most recently cached response by the client.

try { 
    var result = api_instance.getDistrictEventsSimple(districtKey, ifModifiedSince);
    print(result);
} catch (e) {
    print("Exception when calling DistrictApi->getDistrictEventsSimple: $e\n");
}

Parameters

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

Return type

List

Authorization

apiKey

HTTP request headers

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

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

getDistrictRankings

List getDistrictRankings(districtKey, ifModifiedSince)

Gets a list of team district rankings for the given district.

Example

import 'package:swagger/api.dart';
// TODO Configure API key authorization: apiKey
//swagger.api.Configuration.apiKey{'X-TBA-Auth-Key'} = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//swagger.api.Configuration.apiKeyPrefix{'X-TBA-Auth-Key'} = "Bearer";

var api_instance = new DistrictApi();
var districtKey = districtKey_example; // String | TBA District Key, eg `2016fim`
var ifModifiedSince = ifModifiedSince_example; // String | Value of the `Last-Modified` header in the most recently cached response by the client.

try { 
    var result = api_instance.getDistrictRankings(districtKey, ifModifiedSince);
    print(result);
} catch (e) {
    print("Exception when calling DistrictApi->getDistrictRankings: $e\n");
}

Parameters

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

Return type

List

Authorization

apiKey

HTTP request headers

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

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

getDistrictTeams

List getDistrictTeams(districtKey, ifModifiedSince)

Gets a list of Team objects that competed in events in the given district.

Example

import 'package:swagger/api.dart';
// TODO Configure API key authorization: apiKey
//swagger.api.Configuration.apiKey{'X-TBA-Auth-Key'} = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//swagger.api.Configuration.apiKeyPrefix{'X-TBA-Auth-Key'} = "Bearer";

var api_instance = new DistrictApi();
var districtKey = districtKey_example; // String | TBA District Key, eg `2016fim`
var ifModifiedSince = ifModifiedSince_example; // String | Value of the `Last-Modified` header in the most recently cached response by the client.

try { 
    var result = api_instance.getDistrictTeams(districtKey, ifModifiedSince);
    print(result);
} catch (e) {
    print("Exception when calling DistrictApi->getDistrictTeams: $e\n");
}

Parameters

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

Return type

List

Authorization

apiKey

HTTP request headers

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

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

getDistrictTeamsKeys

List getDistrictTeamsKeys(districtKey, ifModifiedSince)

Gets a list of Team objects that competed in events in the given district.

Example

import 'package:swagger/api.dart';
// TODO Configure API key authorization: apiKey
//swagger.api.Configuration.apiKey{'X-TBA-Auth-Key'} = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//swagger.api.Configuration.apiKeyPrefix{'X-TBA-Auth-Key'} = "Bearer";

var api_instance = new DistrictApi();
var districtKey = districtKey_example; // String | TBA District Key, eg `2016fim`
var ifModifiedSince = ifModifiedSince_example; // String | Value of the `Last-Modified` header in the most recently cached response by the client.

try { 
    var result = api_instance.getDistrictTeamsKeys(districtKey, ifModifiedSince);
    print(result);
} catch (e) {
    print("Exception when calling DistrictApi->getDistrictTeamsKeys: $e\n");
}

Parameters

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

Return type

List

Authorization

apiKey

HTTP request headers

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

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

getDistrictTeamsSimple

List getDistrictTeamsSimple(districtKey, ifModifiedSince)

Gets a short-form list of Team objects that competed in events in the given district.

Example

import 'package:swagger/api.dart';
// TODO Configure API key authorization: apiKey
//swagger.api.Configuration.apiKey{'X-TBA-Auth-Key'} = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//swagger.api.Configuration.apiKeyPrefix{'X-TBA-Auth-Key'} = "Bearer";

var api_instance = new DistrictApi();
var districtKey = districtKey_example; // String | TBA District Key, eg `2016fim`
var ifModifiedSince = ifModifiedSince_example; // String | Value of the `Last-Modified` header in the most recently cached response by the client.

try { 
    var result = api_instance.getDistrictTeamsSimple(districtKey, ifModifiedSince);
    print(result);
} catch (e) {
    print("Exception when calling DistrictApi->getDistrictTeamsSimple: $e\n");
}

Parameters

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

Return type

List

Authorization

apiKey

HTTP request headers

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

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

getDistrictsByYear

List getDistrictsByYear(year, ifModifiedSince)

Gets a list of districts and their corresponding district key, for the given year.

Example

import 'package:swagger/api.dart';
// TODO Configure API key authorization: apiKey
//swagger.api.Configuration.apiKey{'X-TBA-Auth-Key'} = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//swagger.api.Configuration.apiKeyPrefix{'X-TBA-Auth-Key'} = "Bearer";

var api_instance = new DistrictApi();
var year = 56; // int | Competition Year (or Season). Must be 4 digits.
var ifModifiedSince = ifModifiedSince_example; // String | Value of the `Last-Modified` header in the most recently cached response by the client.

try { 
    var result = api_instance.getDistrictsByYear(year, ifModifiedSince);
    print(result);
} catch (e) {
    print("Exception when calling DistrictApi->getDistrictsByYear: $e\n");
}

Parameters

Name Type Description Notes
year int 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

Authorization

apiKey

HTTP request headers

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

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

getEventDistrictPoints

EventDistrictPoints getEventDistrictPoints(eventKey, ifModifiedSince)

Gets a list of team rankings for the Event.

Example

import 'package:swagger/api.dart';
// TODO Configure API key authorization: apiKey
//swagger.api.Configuration.apiKey{'X-TBA-Auth-Key'} = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//swagger.api.Configuration.apiKeyPrefix{'X-TBA-Auth-Key'} = "Bearer";

var api_instance = new DistrictApi();
var eventKey = eventKey_example; // String | TBA Event Key, eg `2016nytr`
var ifModifiedSince = ifModifiedSince_example; // String | Value of the `Last-Modified` header in the most recently cached response by the client.

try { 
    var result = api_instance.getEventDistrictPoints(eventKey, ifModifiedSince);
    print(result);
} catch (e) {
    print("Exception when calling DistrictApi->getEventDistrictPoints: $e\n");
}

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

EventDistrictPoints

Authorization

apiKey

HTTP request headers

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

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

getTeamDistricts

List getTeamDistricts(teamKey, ifModifiedSince)

Gets an array of districts representing each year the team was in a district. Will return an empty array if the team was never in a district.

Example

import 'package:swagger/api.dart';
// TODO Configure API key authorization: apiKey
//swagger.api.Configuration.apiKey{'X-TBA-Auth-Key'} = 'YOUR_API_KEY';
// uncomment below to setup prefix (e.g. Bearer) for API key, if needed
//swagger.api.Configuration.apiKeyPrefix{'X-TBA-Auth-Key'} = "Bearer";

var api_instance = new DistrictApi();
var teamKey = teamKey_example; // String | TBA Team Key, eg `frc254`
var ifModifiedSince = ifModifiedSince_example; // String | Value of the `Last-Modified` header in the most recently cached response by the client.

try { 
    var result = api_instance.getTeamDistricts(teamKey, ifModifiedSince);
    print(result);
} catch (e) {
    print("Exception when calling DistrictApi->getTeamDistricts: $e\n");
}

Parameters

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

Return type

List

Authorization

apiKey

HTTP request headers

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

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