ftc_events_client 0.1.0 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (143) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +351 -101
  3. data/Rakefile +0 -2
  4. data/config.json +1 -1
  5. data/docs/AllianceModelVersion2.md +10 -28
  6. data/docs/AllianceScore2020.md +37 -82
  7. data/docs/AllianceSelectionApi.md +14 -14
  8. data/docs/AllianceSelectionModelVersion2.md +4 -16
  9. data/docs/ApiIndexModel.md +11 -30
  10. data/docs/AutoNavigatedStatus.md +6 -0
  11. data/docs/AwardAssignmentModel.md +13 -34
  12. data/docs/AwardsApi.md +47 -49
  13. data/docs/AwardsModel.md +3 -14
  14. data/docs/BarcodeElement.md +6 -0
  15. data/docs/EndgameParkedStatus.md +6 -0
  16. data/docs/EventMatchResultsModelVersion2.md +3 -14
  17. data/docs/EventRankingsModel.md +3 -14
  18. data/docs/EventScheduleHybridModelVersion2.md +3 -14
  19. data/docs/EventScheduleModelVersion2.md +3 -14
  20. data/docs/FTCEventLevel.md +6 -0
  21. data/docs/GeneralApi.md +9 -11
  22. data/docs/LeagueMemberListModel.md +7 -0
  23. data/docs/LeaguesApi.md +179 -0
  24. data/docs/MatchResultModelVersion2.md +16 -40
  25. data/docs/MatchResultTeamModelVersion2.md +6 -18
  26. data/docs/MatchResultsApi.md +33 -35
  27. data/docs/MatchScoresModel.md +3 -14
  28. data/docs/MatchScoresModelMatchScoresOneOf.md +5 -1
  29. data/docs/OneOfMatchScoresModelMatchScoresItems.md +6 -0
  30. data/docs/RankingsApi.md +16 -17
  31. data/docs/ScheduleApi.md +30 -32
  32. data/docs/ScheduleHybridModelTeamVersion2.md +8 -22
  33. data/docs/ScheduleHybridModelVersion2.md +18 -40
  34. data/docs/ScheduledMatchModelVersion2.md +10 -28
  35. data/docs/ScheduledMatchTeamModelVersion2.md +6 -20
  36. data/docs/ScoreDetailAllianceModel2020.md +39 -86
  37. data/docs/ScoreDetailAllianceModel2021.md +48 -0
  38. data/docs/ScoreDetailModel2019.md +6 -18
  39. data/docs/ScoreDetailModel2020.md +6 -18
  40. data/docs/ScoreDetailModel2021.md +10 -0
  41. data/docs/ScoreDetailModelAlliance2019.md +36 -80
  42. data/docs/ScoreDetailModelSinglePlayer2020.md +6 -20
  43. data/docs/ScoreDetailModelSinglePlayer2021.md +10 -0
  44. data/docs/ScoreDetailSinglePlayer2021.md +39 -0
  45. data/docs/SeasonAwardListingsModel.md +3 -14
  46. data/docs/SeasonAwardsModel.md +6 -20
  47. data/docs/SeasonDataApi.md +35 -37
  48. data/docs/SeasonEventListingsModelVersion2.md +4 -16
  49. data/docs/SeasonEventModelVersion2.md +24 -46
  50. data/docs/SeasonLeagueListingsModelVersion2.md +8 -0
  51. data/docs/SeasonLeagueModelVersion2.md +11 -0
  52. data/docs/SeasonSummaryModelChampionship.md +5 -18
  53. data/docs/SeasonSummaryModelVersion2.md +8 -24
  54. data/docs/SeasonTeamListingsModelVersion2.md +7 -22
  55. data/docs/SeasonTeamModelVersion2.md +14 -36
  56. data/docs/Stone.md +2 -11
  57. data/docs/TeamRankingModel.md +17 -42
  58. data/ftc_events_client.gemspec +5 -5
  59. data/git_push.sh +7 -10
  60. data/lib/ftc_events_client/api/alliance_selection_api.rb +17 -22
  61. data/lib/ftc_events_client/api/awards_api.rb +52 -74
  62. data/lib/ftc_events_client/api/general_api.rb +8 -17
  63. data/lib/ftc_events_client/api/leagues_api.rb +218 -0
  64. data/lib/ftc_events_client/api/match_results_api.rb +44 -45
  65. data/lib/ftc_events_client/api/rankings_api.rb +17 -22
  66. data/lib/ftc_events_client/api/schedule_api.rb +44 -45
  67. data/lib/ftc_events_client/api/season_data_api.rb +30 -53
  68. data/lib/ftc_events_client/api_client.rb +52 -54
  69. data/lib/ftc_events_client/api_error.rb +4 -4
  70. data/lib/ftc_events_client/configuration.rb +6 -76
  71. data/lib/ftc_events_client/models/alliance_model_version2.rb +19 -31
  72. data/lib/ftc_events_client/models/{alliance_score2020.rb → alliance_score_2020.rb} +46 -58
  73. data/lib/ftc_events_client/models/alliance_selection_model_version2.rb +13 -25
  74. data/lib/ftc_events_client/models/api_index_model.rb +20 -32
  75. data/lib/ftc_events_client/models/{tournament_level.rb → auto_navigated_status.rb} +11 -21
  76. data/lib/ftc_events_client/models/award_assignment_model.rb +22 -34
  77. data/lib/ftc_events_client/models/awards_model.rb +12 -24
  78. data/lib/ftc_events_client/models/barcode_element.rb +28 -0
  79. data/lib/ftc_events_client/models/endgame_parked_status.rb +29 -0
  80. data/lib/ftc_events_client/models/event_match_results_model_version2.rb +12 -24
  81. data/lib/ftc_events_client/models/event_rankings_model.rb +12 -24
  82. data/lib/ftc_events_client/models/event_schedule_hybrid_model_version2.rb +12 -24
  83. data/lib/ftc_events_client/models/event_schedule_model_version2.rb +12 -24
  84. data/lib/ftc_events_client/models/ftc_event_level.rb +31 -0
  85. data/lib/ftc_events_client/models/league_member_list_model.rb +209 -0
  86. data/lib/ftc_events_client/models/match_result_model_version2.rb +25 -37
  87. data/lib/ftc_events_client/models/match_result_team_model_version2.rb +26 -29
  88. data/lib/ftc_events_client/models/match_scores_model.rb +12 -24
  89. data/lib/ftc_events_client/models/one_of_match_scores_model_match_scores_items.rb +197 -0
  90. data/lib/ftc_events_client/models/schedule_hybrid_model_team_version2.rb +30 -32
  91. data/lib/ftc_events_client/models/schedule_hybrid_model_version2.rb +46 -38
  92. data/lib/ftc_events_client/models/scheduled_match_model_version2.rb +19 -31
  93. data/lib/ftc_events_client/models/scheduled_match_team_model_version2.rb +15 -27
  94. data/lib/ftc_events_client/models/{score_detail_alliance_model2020.rb → score_detail_alliance_model_2020.rb} +48 -60
  95. data/lib/ftc_events_client/models/score_detail_alliance_model_2021.rb +576 -0
  96. data/lib/ftc_events_client/models/{score_detail_model2019.rb → score_detail_model_2019.rb} +24 -27
  97. data/lib/ftc_events_client/models/{score_detail_model2020.rb → score_detail_model_2020.rb} +24 -27
  98. data/lib/ftc_events_client/models/score_detail_model_2021.rb +236 -0
  99. data/lib/ftc_events_client/models/{score_detail_model_alliance2019.rb → score_detail_model_alliance_2019.rb} +45 -57
  100. data/lib/ftc_events_client/models/{score_detail_model_single_player2020.rb → score_detail_model_single_player_2020.rb} +15 -27
  101. data/lib/ftc_events_client/models/score_detail_model_single_player_2021.rb +233 -0
  102. data/lib/ftc_events_client/models/score_detail_single_player_2021.rb +494 -0
  103. data/lib/ftc_events_client/models/season_award_listings_model.rb +12 -24
  104. data/lib/ftc_events_client/models/season_awards_model.rb +22 -34
  105. data/lib/ftc_events_client/models/season_event_listings_model_version2.rb +13 -25
  106. data/lib/ftc_events_client/models/season_event_model_version2.rb +77 -41
  107. data/lib/ftc_events_client/models/season_league_listings_model_version2.rb +218 -0
  108. data/lib/ftc_events_client/models/season_league_model_version2.rb +247 -0
  109. data/lib/ftc_events_client/models/season_summary_model_championship.rb +14 -26
  110. data/lib/ftc_events_client/models/season_summary_model_version2.rb +17 -29
  111. data/lib/ftc_events_client/models/season_team_listings_model_version2.rb +16 -28
  112. data/lib/ftc_events_client/models/season_team_model_version2.rb +23 -35
  113. data/lib/ftc_events_client/models/stone.rb +6 -15
  114. data/lib/ftc_events_client/models/team_ranking_model.rb +26 -38
  115. data/lib/ftc_events_client/version.rb +4 -5
  116. data/lib/ftc_events_client.rb +22 -12
  117. data/spec/api/leagues_api_spec.rb +77 -0
  118. data/spec/base_object_spec.rb +109 -0
  119. data/spec/configuration_spec.rb +3 -3
  120. data/spec/models/alliance_score_2020_spec.rb +244 -0
  121. data/spec/models/auto_navigated_status_spec.rb +28 -0
  122. data/spec/models/barcode_element_spec.rb +28 -0
  123. data/spec/models/endgame_parked_status_spec.rb +28 -0
  124. data/spec/models/ftc_event_level_spec.rb +28 -0
  125. data/spec/models/league_member_list_model_spec.rb +34 -0
  126. data/spec/models/one_of_match_scores_model_match_scores_items_spec.rb +34 -0
  127. data/spec/models/score_detail_alliance_model2021_spec.rb +280 -0
  128. data/spec/models/score_detail_alliance_model_2020_spec.rb +256 -0
  129. data/spec/models/score_detail_alliance_model_2021_spec.rb +286 -0
  130. data/spec/models/score_detail_model2021_spec.rb +52 -0
  131. data/spec/models/score_detail_model_2019_spec.rb +58 -0
  132. data/spec/models/score_detail_model_2020_spec.rb +58 -0
  133. data/spec/models/score_detail_model_2021_spec.rb +58 -0
  134. data/spec/models/score_detail_model_alliance_2019_spec.rb +238 -0
  135. data/spec/models/score_detail_model_single_player2021_spec.rb +52 -0
  136. data/spec/models/score_detail_model_single_player_2020_spec.rb +58 -0
  137. data/spec/models/score_detail_model_single_player_2021_spec.rb +58 -0
  138. data/spec/models/score_detail_single_player2021_spec.rb +226 -0
  139. data/spec/models/score_detail_single_player_2021_spec.rb +232 -0
  140. data/spec/models/season_league_listings_model_version2_spec.rb +40 -0
  141. data/{lib/ftc_events_client/models/match_scores_model_match_scores_one_of.rb → spec/models/season_league_model_version2_spec.rb} +35 -83
  142. data/update.sh +2 -2
  143. metadata +103 -11
@@ -3,11 +3,10 @@
3
3
 
4
4
  #FTC Events API is a service to return relevant information about the _FIRST_ Tech Challenge (FTC). Information is made available from events operating around the world Information is currently made available after the conclusion of the tournament. The API will provide data as soon as it has synced, and we do not add any artificial delays. ## Documentation Notes ### Timezones All times are listed in the local time to the event venue. HTTP-date values will show their timezone. ### Query Parameters If you specify a parameter, but no value for that parameter, it will be ignored. For example, if you request `URL?teamNumber=` the `teamNumber` parameter would be ignored. For all APIs that accept a query string in addition to the base URI, the order of parameters do not matter, but the name shown in the documentation must match exactly, as does the associated value format as described in details. For response codes that are not HTTP 200 (OK), the documentation will show a body message that represents a possible response value. While the \"title\" of the HTTP Status Code will match those shown in the response codes documentation section exactly, the body of the response will be a more detailed explanation of why that status code is being returned and may not always be exactly as shown in the examples. ### Experimenting with the API This documentation is rendered at both [api-docs](https://ftc-events.firstinspires.org/api-docs) and [try-it-out](https://ftc-events.firstinspires.org/try-it-out). [api-docs](https://ftc-events.firstinspires.org/api-docs) has a three panel, easy to read layout, while [try-it-out](https://ftc-events.firstinspires.org/try-it-out) has a feature that allows you try out endpoints from within the page. Additionally, the Open API Json is availabe at [Open API](https://ftc-events.firstinspires.org/swagger/v2.0/swagger.json). This can be imported into a tool such as [Postman](https://www.postman.com) for experimentation as well. ### Last-Modified, FMS-OnlyModifiedSince, and If-Modified-Since Headers The FTC Events API utilizes the `Last-Modified` and `If-Modified-Since` Headers to communicate with consumers regarding the age of the data they are requesting. With a couple of exceptions, all calls will return a `Last-Modified` Header set with the time at which the data at that endpoint was last modified. The Header will always be set in the HTTP-date format, as described in the HTTP Protocol. There are two exceptions: the `Last-Modified` Header is not set if the endpoint returns no results (such as a request for a schedule with no matches). Consumers should keep track of the `Last-Modified` Header, and return it on subsequent calls to the same endpoint as the If-Modified-Since. The server will recognize this request, and will only return a result if the data has been modified since the last request. If no changes have been made, an HTTP 304 will be returned. If data has been modified, ALL data on that call will be returned (for \"only modified\" data, see below). The FTC Events API also allows a custom header used to filter the return data to a specific subset. This is done by specifying a `FMS-OnlyModifiedSince` header with each call. As with the `If-Modified-Since` header, consumers should keep track of the Last-Modified Header, and return it on subsequent calls to the same endpoint as the `FMS-OnlyModifiedSince` Header. The server will recognize this request, and will only return a result if the data has been modified since the last request, and, if returned, the data will only be those portions modified since the included date. If no changes, have been made, an HTTP 304 will be returned. Using this method, the server and consumer save processing time by only receiving modified data that is in need of update on the consumer side. If the Headers are improperly passed (such as the wrong Day of Week for the matching date, or a date in the future), the endpoint will simply ignore the Header and return all results. If both headers are specified, the request will be denied. ## Response Codes The FTC Events API HTTP Status Codes correspond with the [common codes](http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html), but occasionally with different \"titles\". The \"title\" used by the API is shown next to each of the below possible response HTTP Status Codes. Throughout the documentation, Apiary may automatically show the common \"title\" in example returns (like \"Not Found\" for 404) but on the production server, the \"title\" will instead match those listed below. ### HTTP 200 - \"OK\" The request has succeeded. An entity corresponding to the requested resource is sent in the response. This will be returned as the HTTP Status Code for all request that succeed, even if the body is empty (such as an event that has no rankings, but with a valid season and event code were used) ### HTTP 304 - \"Not Modified\" When utilizing a Header that allows filtered data returns, such as `If-Modified-Since`, this response indicates that no data meets the request. ### HTTP 400 - \"Invalid Season Requested\"/\"Malformed Parameter Format In Request\"/\"Missing Parameter In Request\"/\"Invalid API Version Requested\": The request could not be understood by the server due to malformed syntax. The client SHOULD NOT repeat the request without modifications. Specifically for this API, a 400 response indicates that the requested URI matches with a valid API, but one or more required parameter was malformed or invalid. Examples include an event code that is too short or team number that contains a letter. ### HTTP 401 - \"Unauthorized\" All requests against the API require authentication via a valid user token. Failing to provide one, or providing an invalid one, will warrant a 401 response. The client MAY repeat the request with a suitable Authorization header field. ### HTTP 404 - \"Invalid Event Requested\" Even though the 404 code usually indicates any not found status, a 404 will only be issued in this API when an event cannot be found for the requested season and event code. If the request didn't match a valid API or there were malformed parameters, the response would not receive a 404 but rather a 400 or 501. If this HTTP code is received, the season was a valid season and the event code matched the acceptable style of an event code, but there were no records of an event matching the combination of that season and event code. For example, HTTP 404 would be issued when the event had a different code in the requested season (the codes can change year to year based on event location). ### HTTP 500 - \"Internal Server Error\" The server encountered an unexpected condition which prevented it from fulfilling the request. This is a code sent directly by the server, and has no special alternate definition specific to this API. ### HTTP 501 - \"Request Did Not Match Any Current API Pattern\" The server does not support the functionality required to fulfill the request. Specifically, the request pattern did not match any of the possible APIs, and thus processing was discontinued. This code is also issued when too many optional parameters were included in a single request and fulfilling it would make the result confusing or misleading. Each API will specify which parameters or combination of parameters can be used at the same time. ### HTTP 503 - \"Service Unavailable\" The server is currently unable to handle the request due to a temporary overloading or maintenance of the server. The implication is that this is a temporary condition which will be alleviated after some delay. If known, the length of the delay MAY be indicated in a `Retry-After` header. This code will not always appear, sometimes the server may outright refuse the connection instead. This is a code sent directly by the server, and has no special alternate definition specific to this API. ## Authorization In order to make calls against the FTC Events API, you must include an HTTP Header called `Authorization` with the value set as specified below. If a request is made without this header, processing stops and an HTTP 401 is issued. All `Authorization` headers follow the same format: ``` Authorization: Basic 000000000000000000000000000000000000000000000000000000000000 ``` Where the Zeros are replaced by your Token. The Token can be formed by taking your username and your AuthorizationKey and adding a colon. For example, if your username is `sampleuser` and your AuthorizationKey is `7eaa6338-a097-4221-ac04-b6120fcc4d49` you would have this string: ``` sampleuser:7eaa6338-a097-4221-ac04-b6120fcc4d49 ``` This string must then be encoded using Base64 Encoded to form the Token, which will be the same length as the example above, but include letters and numbers. For our example, we would have: ``` c2FtcGxldXNlcjo3ZWFhNjMzOC1hMDk3LTQyMjEtYWMwNC1iNjEyMGZjYzRkNDk= ``` Most API client libraries can handle computing the authorization header using a username and password for you NOTICE: Publicly distributing an application, code snippet, etc, that has your username and token in it, encoded or not, WILL result in your token being blocked from the API. Each user should apply for their own token. If you wish to acquire a token for your development, you may do so by requesting a token through our automated system on this website.
5
5
 
6
- The version of the OpenAPI document: v2.0
7
-
8
- Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 5.0.0-SNAPSHOT
6
+ OpenAPI spec version: v2.0
10
7
 
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+ Swagger Codegen version: 3.0.29
11
10
  =end
12
11
 
13
12
  # Common files
@@ -18,44 +17,55 @@ require 'ftc_events_client/configuration'
18
17
 
19
18
  # Models
20
19
  require 'ftc_events_client/models/alliance_model_version2'
21
- require 'ftc_events_client/models/alliance_score2020'
20
+ require 'ftc_events_client/models/alliance_score_2020'
22
21
  require 'ftc_events_client/models/alliance_selection_model_version2'
23
22
  require 'ftc_events_client/models/api_index_model'
23
+ require 'ftc_events_client/models/auto_navigated_status'
24
24
  require 'ftc_events_client/models/award_assignment_model'
25
25
  require 'ftc_events_client/models/awards_model'
26
+ require 'ftc_events_client/models/barcode_element'
27
+ require 'ftc_events_client/models/endgame_parked_status'
26
28
  require 'ftc_events_client/models/event_match_results_model_version2'
27
29
  require 'ftc_events_client/models/event_rankings_model'
28
30
  require 'ftc_events_client/models/event_schedule_hybrid_model_version2'
29
31
  require 'ftc_events_client/models/event_schedule_model_version2'
32
+ require 'ftc_events_client/models/ftc_event_level'
33
+ require 'ftc_events_client/models/league_member_list_model'
30
34
  require 'ftc_events_client/models/match_result_model_version2'
31
35
  require 'ftc_events_client/models/match_result_team_model_version2'
32
36
  require 'ftc_events_client/models/match_scores_model'
33
- require 'ftc_events_client/models/match_scores_model_match_scores_one_of'
37
+ require 'ftc_events_client/models/one_of_match_scores_model_match_scores_items'
34
38
  require 'ftc_events_client/models/schedule_hybrid_model_team_version2'
35
39
  require 'ftc_events_client/models/schedule_hybrid_model_version2'
36
40
  require 'ftc_events_client/models/scheduled_match_model_version2'
37
41
  require 'ftc_events_client/models/scheduled_match_team_model_version2'
38
- require 'ftc_events_client/models/score_detail_alliance_model2020'
39
- require 'ftc_events_client/models/score_detail_model2019'
40
- require 'ftc_events_client/models/score_detail_model2020'
41
- require 'ftc_events_client/models/score_detail_model_alliance2019'
42
- require 'ftc_events_client/models/score_detail_model_single_player2020'
42
+ require 'ftc_events_client/models/score_detail_alliance_model_2020'
43
+ require 'ftc_events_client/models/score_detail_alliance_model_2021'
44
+ require 'ftc_events_client/models/score_detail_model_2019'
45
+ require 'ftc_events_client/models/score_detail_model_2020'
46
+ require 'ftc_events_client/models/score_detail_model_2021'
47
+ require 'ftc_events_client/models/score_detail_model_alliance_2019'
48
+ require 'ftc_events_client/models/score_detail_model_single_player_2020'
49
+ require 'ftc_events_client/models/score_detail_model_single_player_2021'
50
+ require 'ftc_events_client/models/score_detail_single_player_2021'
43
51
  require 'ftc_events_client/models/season_award_listings_model'
44
52
  require 'ftc_events_client/models/season_awards_model'
45
53
  require 'ftc_events_client/models/season_event_listings_model_version2'
46
54
  require 'ftc_events_client/models/season_event_model_version2'
55
+ require 'ftc_events_client/models/season_league_listings_model_version2'
56
+ require 'ftc_events_client/models/season_league_model_version2'
47
57
  require 'ftc_events_client/models/season_summary_model_championship'
48
58
  require 'ftc_events_client/models/season_summary_model_version2'
49
59
  require 'ftc_events_client/models/season_team_listings_model_version2'
50
60
  require 'ftc_events_client/models/season_team_model_version2'
51
61
  require 'ftc_events_client/models/stone'
52
62
  require 'ftc_events_client/models/team_ranking_model'
53
- require 'ftc_events_client/models/tournament_level'
54
63
 
55
64
  # APIs
56
65
  require 'ftc_events_client/api/alliance_selection_api'
57
66
  require 'ftc_events_client/api/awards_api'
58
67
  require 'ftc_events_client/api/general_api'
68
+ require 'ftc_events_client/api/leagues_api'
59
69
  require 'ftc_events_client/api/match_results_api'
60
70
  require 'ftc_events_client/api/rankings_api'
61
71
  require 'ftc_events_client/api/schedule_api'
@@ -0,0 +1,77 @@
1
+ =begin
2
+ #FTC Events API
3
+
4
+ #FTC Events API is a service to return relevant information about the _FIRST_ Tech Challenge (FTC). Information is made available from events operating around the world Information is currently made available after the conclusion of the tournament. The API will provide data as soon as it has synced, and we do not add any artificial delays. ## Documentation Notes ### Timezones All times are listed in the local time to the event venue. HTTP-date values will show their timezone. ### Query Parameters If you specify a parameter, but no value for that parameter, it will be ignored. For example, if you request `URL?teamNumber=` the `teamNumber` parameter would be ignored. For all APIs that accept a query string in addition to the base URI, the order of parameters do not matter, but the name shown in the documentation must match exactly, as does the associated value format as described in details. For response codes that are not HTTP 200 (OK), the documentation will show a body message that represents a possible response value. While the \"title\" of the HTTP Status Code will match those shown in the response codes documentation section exactly, the body of the response will be a more detailed explanation of why that status code is being returned and may not always be exactly as shown in the examples. ### Experimenting with the API This documentation is rendered at both [api-docs](https://ftc-events.firstinspires.org/api-docs) and [try-it-out](https://ftc-events.firstinspires.org/try-it-out). [api-docs](https://ftc-events.firstinspires.org/api-docs) has a three panel, easy to read layout, while [try-it-out](https://ftc-events.firstinspires.org/try-it-out) has a feature that allows you try out endpoints from within the page. Additionally, the Open API Json is availabe at [Open API](https://ftc-events.firstinspires.org/swagger/v2.0/swagger.json). This can be imported into a tool such as [Postman](https://www.postman.com) for experimentation as well. ### Last-Modified, FMS-OnlyModifiedSince, and If-Modified-Since Headers The FTC Events API utilizes the `Last-Modified` and `If-Modified-Since` Headers to communicate with consumers regarding the age of the data they are requesting. With a couple of exceptions, all calls will return a `Last-Modified` Header set with the time at which the data at that endpoint was last modified. The Header will always be set in the HTTP-date format, as described in the HTTP Protocol. There are two exceptions: the `Last-Modified` Header is not set if the endpoint returns no results (such as a request for a schedule with no matches). Consumers should keep track of the `Last-Modified` Header, and return it on subsequent calls to the same endpoint as the If-Modified-Since. The server will recognize this request, and will only return a result if the data has been modified since the last request. If no changes have been made, an HTTP 304 will be returned. If data has been modified, ALL data on that call will be returned (for \"only modified\" data, see below). The FTC Events API also allows a custom header used to filter the return data to a specific subset. This is done by specifying a `FMS-OnlyModifiedSince` header with each call. As with the `If-Modified-Since` header, consumers should keep track of the Last-Modified Header, and return it on subsequent calls to the same endpoint as the `FMS-OnlyModifiedSince` Header. The server will recognize this request, and will only return a result if the data has been modified since the last request, and, if returned, the data will only be those portions modified since the included date. If no changes, have been made, an HTTP 304 will be returned. Using this method, the server and consumer save processing time by only receiving modified data that is in need of update on the consumer side. If the Headers are improperly passed (such as the wrong Day of Week for the matching date, or a date in the future), the endpoint will simply ignore the Header and return all results. If both headers are specified, the request will be denied. ## Response Codes The FTC Events API HTTP Status Codes correspond with the [common codes](http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html), but occasionally with different \"titles\". The \"title\" used by the API is shown next to each of the below possible response HTTP Status Codes. Throughout the documentation, Apiary may automatically show the common \"title\" in example returns (like \"Not Found\" for 404) but on the production server, the \"title\" will instead match those listed below. ### HTTP 200 - \"OK\" The request has succeeded. An entity corresponding to the requested resource is sent in the response. This will be returned as the HTTP Status Code for all request that succeed, even if the body is empty (such as an event that has no rankings, but with a valid season and event code were used) ### HTTP 304 - \"Not Modified\" When utilizing a Header that allows filtered data returns, such as `If-Modified-Since`, this response indicates that no data meets the request. ### HTTP 400 - \"Invalid Season Requested\"/\"Malformed Parameter Format In Request\"/\"Missing Parameter In Request\"/\"Invalid API Version Requested\": The request could not be understood by the server due to malformed syntax. The client SHOULD NOT repeat the request without modifications. Specifically for this API, a 400 response indicates that the requested URI matches with a valid API, but one or more required parameter was malformed or invalid. Examples include an event code that is too short or team number that contains a letter. ### HTTP 401 - \"Unauthorized\" All requests against the API require authentication via a valid user token. Failing to provide one, or providing an invalid one, will warrant a 401 response. The client MAY repeat the request with a suitable Authorization header field. ### HTTP 404 - \"Invalid Event Requested\" Even though the 404 code usually indicates any not found status, a 404 will only be issued in this API when an event cannot be found for the requested season and event code. If the request didn't match a valid API or there were malformed parameters, the response would not receive a 404 but rather a 400 or 501. If this HTTP code is received, the season was a valid season and the event code matched the acceptable style of an event code, but there were no records of an event matching the combination of that season and event code. For example, HTTP 404 would be issued when the event had a different code in the requested season (the codes can change year to year based on event location). ### HTTP 500 - \"Internal Server Error\" The server encountered an unexpected condition which prevented it from fulfilling the request. This is a code sent directly by the server, and has no special alternate definition specific to this API. ### HTTP 501 - \"Request Did Not Match Any Current API Pattern\" The server does not support the functionality required to fulfill the request. Specifically, the request pattern did not match any of the possible APIs, and thus processing was discontinued. This code is also issued when too many optional parameters were included in a single request and fulfilling it would make the result confusing or misleading. Each API will specify which parameters or combination of parameters can be used at the same time. ### HTTP 503 - \"Service Unavailable\" The server is currently unable to handle the request due to a temporary overloading or maintenance of the server. The implication is that this is a temporary condition which will be alleviated after some delay. If known, the length of the delay MAY be indicated in a `Retry-After` header. This code will not always appear, sometimes the server may outright refuse the connection instead. This is a code sent directly by the server, and has no special alternate definition specific to this API. ## Authorization In order to make calls against the FTC Events API, you must include an HTTP Header called `Authorization` with the value set as specified below. If a request is made without this header, processing stops and an HTTP 401 is issued. All `Authorization` headers follow the same format: ``` Authorization: Basic 000000000000000000000000000000000000000000000000000000000000 ``` Where the Zeros are replaced by your Token. The Token can be formed by taking your username and your AuthorizationKey and adding a colon. For example, if your username is `sampleuser` and your AuthorizationKey is `7eaa6338-a097-4221-ac04-b6120fcc4d49` you would have this string: ``` sampleuser:7eaa6338-a097-4221-ac04-b6120fcc4d49 ``` This string must then be encoded using Base64 Encoded to form the Token, which will be the same length as the example above, but include letters and numbers. For our example, we would have: ``` c2FtcGxldXNlcjo3ZWFhNjMzOC1hMDk3LTQyMjEtYWMwNC1iNjEyMGZjYzRkNDk= ``` Most API client libraries can handle computing the authorization header using a username and password for you NOTICE: Publicly distributing an application, code snippet, etc, that has your username and token in it, encoded or not, WILL result in your token being blocked from the API. Each user should apply for their own token. If you wish to acquire a token for your development, you may do so by requesting a token through our automated system on this website.
5
+
6
+ The version of the OpenAPI document: v2.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 5.0.0-SNAPSHOT
10
+
11
+ =end
12
+
13
+ require 'spec_helper'
14
+ require 'json'
15
+
16
+ # Unit tests for FtcEventsClient::LeaguesApi
17
+ # Automatically generated by openapi-generator (https://openapi-generator.tech)
18
+ # Please update as you see appropriate
19
+ describe 'LeaguesApi' do
20
+ before do
21
+ # run before each test
22
+ @api_instance = FtcEventsClient::LeaguesApi.new
23
+ end
24
+
25
+ after do
26
+ # run after each test
27
+ end
28
+
29
+ describe 'test an instance of LeaguesApi' do
30
+ it 'should create an instance of LeaguesApi' do
31
+ expect(@api_instance).to be_instance_of(FtcEventsClient::LeaguesApi)
32
+ end
33
+ end
34
+
35
+ # unit tests for v20_season_leagues_get
36
+ # League Listings
37
+ # The league listings API returns all FTC leagues in a particular season. You can specify a `regionCode` to filter to leagues within a particular region. To filter to a specific league, supply both a `regionCode` and a `leagueCode`. The returned objects have a `parentLeagueCode` field, which indicates the league is a child league if not null and provides the code of the parent league. The `regionCode` of the parent league will always match the child.
38
+ # @param season Numeric year from which the league listings are requested. Must be 4 digits
39
+ # @param [Hash] opts the optional parameters
40
+ # @option opts [String] :region_code Case-sensitive alphanumeric `regionCode` of a region to filter for.
41
+ # @option opts [String] :league_code Case-sensitive alphanumeric `leagueCode` of the league within the specified region to query.
42
+ # @return [SeasonLeagueListingsModelVersion2]
43
+ describe 'v20_season_leagues_get test' do
44
+ it 'should work' do
45
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
46
+ end
47
+ end
48
+
49
+ # unit tests for v20_season_leagues_members_region_code_league_code_get
50
+ # League Membership
51
+ # The league membership API returns the list of team numbers for the teams that are members of a particular league. Leagues are specified by a `regionCode` in combination with a `leagueCode`.
52
+ # @param season Numeric year. Must be 4 digits
53
+ # @param region_code Case sensitive alphanumeric `regionCode` of the region the league belongs to.
54
+ # @param league_code Case sensitive alphanumeric `leagueCode` of the league.
55
+ # @param [Hash] opts the optional parameters
56
+ # @return [LeagueMemberListModel]
57
+ describe 'v20_season_leagues_members_region_code_league_code_get test' do
58
+ it 'should work' do
59
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
60
+ end
61
+ end
62
+
63
+ # unit tests for v20_season_leagues_rankings_region_code_league_code_get
64
+ # League Rankings
65
+ # The league rankings API returns team ranking detail from a particular league in a particular season. League rankings are only the cumulative rankings from League Meets - they do not include performance at the League Tournament. To get League Tournament Rankings, use the Event Rankings endpoint.
66
+ # @param season Numeric year. Must be 4 digits
67
+ # @param region_code Case sensitive alphanumeric `regionCode` of the region the league belongs to.
68
+ # @param league_code Case sensitive alphanumeric `leagueCode` of the league.
69
+ # @param [Hash] opts the optional parameters
70
+ # @return [EventRankingsModel]
71
+ describe 'v20_season_leagues_rankings_region_code_league_code_get test' do
72
+ it 'should work' do
73
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
74
+ end
75
+ end
76
+
77
+ end
@@ -0,0 +1,109 @@
1
+ require 'spec_helper'
2
+
3
+ class ArrayMapObject < Petstore::Category
4
+ attr_accessor :int_arr, :pet_arr, :int_map, :pet_map, :int_arr_map, :pet_arr_map, :boolean_true_arr, :boolean_false_arr
5
+
6
+ def self.attribute_map
7
+ {
8
+ :int_arr => :int_arr,
9
+ :pet_arr => :pet_arr,
10
+ :int_map => :int_map,
11
+ :pet_map => :pet_map,
12
+ :int_arr_map => :int_arr_map,
13
+ :pet_arr_map => :pet_arr_map,
14
+ :boolean_true_arr => :boolean_true_arr,
15
+ :boolean_false_arr => :boolean_false_arr,
16
+ }
17
+ end
18
+
19
+ def self.swagger_types
20
+ {
21
+ :int_arr => :'Array<Integer>',
22
+ :pet_arr => :'Array<Pet>',
23
+ :int_map => :'Hash<String, Integer>',
24
+ :pet_map => :'Hash<String, Pet>',
25
+ :int_arr_map => :'Hash<String, Array<Integer>>',
26
+ :pet_arr_map => :'Hash<String, Array<Pet>>',
27
+ :boolean_true_arr => :'Array<BOOLEAN>',
28
+ :boolean_false_arr => :'Array<BOOLEAN>',
29
+ }
30
+ end
31
+ end
32
+
33
+ describe 'BaseObject' do
34
+ describe 'boolean values' do
35
+ let(:obj) { Petstore::Cat.new({declawed: false}) }
36
+
37
+ it 'should have values set' do
38
+ expect(obj.declawed).not_to be_nil
39
+ expect(obj.declawed).to eq(false)
40
+ end
41
+ end
42
+
43
+ describe 'array and map properties' do
44
+ let(:obj) { ArrayMapObject.new }
45
+
46
+ let(:data) do
47
+ {int_arr: [123, 456],
48
+ pet_arr: [{name: 'Kitty'}],
49
+ int_map: {'int' => 123},
50
+ pet_map: {'pet' => {name: 'Kitty'}},
51
+ int_arr_map: {'int_arr' => [123, 456]},
52
+ pet_arr_map: {'pet_arr' => [{name: 'Kitty'}]},
53
+ boolean_true_arr: [true, "true", "TruE", 1, "y", "yes", "1", "t", "T"],
54
+ boolean_false_arr: [false, "", 0, "0", "f", nil, "null"],
55
+ }
56
+ end
57
+
58
+ it 'works for #build_from_hash' do
59
+ obj.build_from_hash(data)
60
+
61
+ expect(obj.int_arr).to match_array([123, 456])
62
+
63
+ expect(obj.pet_arr).to be_instance_of(Array)
64
+ expect(obj.pet_arr).to be_instance_of(1)
65
+
66
+ pet = obj.pet_arr.first
67
+ expect(pet).to be_instance_of(Petstore::Pet)
68
+ expect(pet.name).to eq('Kitty')
69
+
70
+ expect(obj.int_map).to be_instance_of(Hash)
71
+ expect(obj.int_map).to eq({'int' => 123})
72
+
73
+ expect(obj.pet_map).to be_instance_of(Hash)
74
+ pet = obj.pet_map['pet']
75
+ expect(pet).to be_instance_of(Petstore::Pet)
76
+ expect(pet.name).to eq('Kitty')
77
+
78
+ expect(obj.int_arr_map).to be_instance_of(Hash)
79
+ arr = obj.int_arr_map['int_arr']
80
+ expect(arr).to match_array([123, 456])
81
+
82
+ expect(obj.pet_arr_map).to be_instance_of(Hash)
83
+ arr = obj.pet_arr_map['pet_arr']
84
+ expect(arr).to be_instance_of(Array)
85
+ expect(arr.size).to eq(1)
86
+ pet = arr.first
87
+ expect(pet).to be_instance_of(Petstore::Pet)
88
+ expect(pet.name).to eq('Kitty')
89
+
90
+ expect(obj.boolean_true_arr).to be_instance_of(Array)
91
+ obj.boolean_true_arr.each do |b|
92
+ expect(b).to eq(true)
93
+ end
94
+
95
+ expect(obj.boolean_false_arr).to be_instance_of(Array)
96
+ obj.boolean_false_arr.each do |b|
97
+ expect(b).to eq(false)
98
+ end
99
+ end
100
+
101
+ it 'works for #to_hash' do
102
+ obj.build_from_hash(data)
103
+ expect_data = data.dup
104
+ expect_data[:boolean_true_arr].map! {true}
105
+ expect_data[:boolean_false_arr].map! {false}
106
+ expect(obj.to_hash).to eq(expect_data)
107
+ end
108
+ end
109
+ end
@@ -18,7 +18,7 @@ describe FtcEventsClient::Configuration do
18
18
  before(:each) do
19
19
  # uncomment below to setup host and base_path
20
20
  # require 'URI'
21
- # uri = URI.parse("http://localhost")
21
+ # uri = URI.parse("https://ftc-api.firstinspires.org")
22
22
  # FtcEventsClient.configure do |c|
23
23
  # c.host = uri.host
24
24
  # c.base_path = uri.path
@@ -28,14 +28,14 @@ describe FtcEventsClient::Configuration do
28
28
  describe '#base_url' do
29
29
  it 'should have the default value' do
30
30
  # uncomment below to test default value of the base path
31
- # expect(config.base_url).to eq("http://localhost")
31
+ # expect(config.base_url).to eq("https://ftc-api.firstinspires.org")
32
32
  end
33
33
 
34
34
  it 'should remove trailing slashes' do
35
35
  [nil, '', '/', '//'].each do |base_path|
36
36
  config.base_path = base_path
37
37
  # uncomment below to test trailing slashes
38
- # expect(config.base_url).to eq("http://localhost")
38
+ # expect(config.base_url).to eq("https://ftc-api.firstinspires.org")
39
39
  end
40
40
  end
41
41
  end
@@ -0,0 +1,244 @@
1
+ =begin
2
+ #FTC Events API
3
+
4
+ #FTC Events API is a service to return relevant information about the _FIRST_ Tech Challenge (FTC). Information is made available from events operating around the world Information is currently made available after the conclusion of the tournament. The API will provide data as soon as it has synced, and we do not add any artificial delays. ## Documentation Notes ### Timezones All times are listed in the local time to the event venue. HTTP-date values will show their timezone. ### Query Parameters If you specify a parameter, but no value for that parameter, it will be ignored. For example, if you request `URL?teamNumber=` the `teamNumber` parameter would be ignored. For all APIs that accept a query string in addition to the base URI, the order of parameters do not matter, but the name shown in the documentation must match exactly, as does the associated value format as described in details. For response codes that are not HTTP 200 (OK), the documentation will show a body message that represents a possible response value. While the \"title\" of the HTTP Status Code will match those shown in the response codes documentation section exactly, the body of the response will be a more detailed explanation of why that status code is being returned and may not always be exactly as shown in the examples. ### Experimenting with the API This documentation is rendered at both [api-docs](https://ftc-events.firstinspires.org/api-docs) and [try-it-out](https://ftc-events.firstinspires.org/try-it-out). [api-docs](https://ftc-events.firstinspires.org/api-docs) has a three panel, easy to read layout, while [try-it-out](https://ftc-events.firstinspires.org/try-it-out) has a feature that allows you try out endpoints from within the page. Additionally, the Open API Json is availabe at [Open API](https://ftc-events.firstinspires.org/swagger/v2.0/swagger.json). This can be imported into a tool such as [Postman](https://www.postman.com) for experimentation as well. ### Last-Modified, FMS-OnlyModifiedSince, and If-Modified-Since Headers The FTC Events API utilizes the `Last-Modified` and `If-Modified-Since` Headers to communicate with consumers regarding the age of the data they are requesting. With a couple of exceptions, all calls will return a `Last-Modified` Header set with the time at which the data at that endpoint was last modified. The Header will always be set in the HTTP-date format, as described in the HTTP Protocol. There are two exceptions: the `Last-Modified` Header is not set if the endpoint returns no results (such as a request for a schedule with no matches). Consumers should keep track of the `Last-Modified` Header, and return it on subsequent calls to the same endpoint as the If-Modified-Since. The server will recognize this request, and will only return a result if the data has been modified since the last request. If no changes have been made, an HTTP 304 will be returned. If data has been modified, ALL data on that call will be returned (for \"only modified\" data, see below). The FTC Events API also allows a custom header used to filter the return data to a specific subset. This is done by specifying a `FMS-OnlyModifiedSince` header with each call. As with the `If-Modified-Since` header, consumers should keep track of the Last-Modified Header, and return it on subsequent calls to the same endpoint as the `FMS-OnlyModifiedSince` Header. The server will recognize this request, and will only return a result if the data has been modified since the last request, and, if returned, the data will only be those portions modified since the included date. If no changes, have been made, an HTTP 304 will be returned. Using this method, the server and consumer save processing time by only receiving modified data that is in need of update on the consumer side. If the Headers are improperly passed (such as the wrong Day of Week for the matching date, or a date in the future), the endpoint will simply ignore the Header and return all results. If both headers are specified, the request will be denied. ## Response Codes The FTC Events API HTTP Status Codes correspond with the [common codes](http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html), but occasionally with different \"titles\". The \"title\" used by the API is shown next to each of the below possible response HTTP Status Codes. Throughout the documentation, Apiary may automatically show the common \"title\" in example returns (like \"Not Found\" for 404) but on the production server, the \"title\" will instead match those listed below. ### HTTP 200 - \"OK\" The request has succeeded. An entity corresponding to the requested resource is sent in the response. This will be returned as the HTTP Status Code for all request that succeed, even if the body is empty (such as an event that has no rankings, but with a valid season and event code were used) ### HTTP 304 - \"Not Modified\" When utilizing a Header that allows filtered data returns, such as `If-Modified-Since`, this response indicates that no data meets the request. ### HTTP 400 - \"Invalid Season Requested\"/\"Malformed Parameter Format In Request\"/\"Missing Parameter In Request\"/\"Invalid API Version Requested\": The request could not be understood by the server due to malformed syntax. The client SHOULD NOT repeat the request without modifications. Specifically for this API, a 400 response indicates that the requested URI matches with a valid API, but one or more required parameter was malformed or invalid. Examples include an event code that is too short or team number that contains a letter. ### HTTP 401 - \"Unauthorized\" All requests against the API require authentication via a valid user token. Failing to provide one, or providing an invalid one, will warrant a 401 response. The client MAY repeat the request with a suitable Authorization header field. ### HTTP 404 - \"Invalid Event Requested\" Even though the 404 code usually indicates any not found status, a 404 will only be issued in this API when an event cannot be found for the requested season and event code. If the request didn't match a valid API or there were malformed parameters, the response would not receive a 404 but rather a 400 or 501. If this HTTP code is received, the season was a valid season and the event code matched the acceptable style of an event code, but there were no records of an event matching the combination of that season and event code. For example, HTTP 404 would be issued when the event had a different code in the requested season (the codes can change year to year based on event location). ### HTTP 500 - \"Internal Server Error\" The server encountered an unexpected condition which prevented it from fulfilling the request. This is a code sent directly by the server, and has no special alternate definition specific to this API. ### HTTP 501 - \"Request Did Not Match Any Current API Pattern\" The server does not support the functionality required to fulfill the request. Specifically, the request pattern did not match any of the possible APIs, and thus processing was discontinued. This code is also issued when too many optional parameters were included in a single request and fulfilling it would make the result confusing or misleading. Each API will specify which parameters or combination of parameters can be used at the same time. ### HTTP 503 - \"Service Unavailable\" The server is currently unable to handle the request due to a temporary overloading or maintenance of the server. The implication is that this is a temporary condition which will be alleviated after some delay. If known, the length of the delay MAY be indicated in a `Retry-After` header. This code will not always appear, sometimes the server may outright refuse the connection instead. This is a code sent directly by the server, and has no special alternate definition specific to this API. ## Authorization In order to make calls against the FTC Events API, you must include an HTTP Header called `Authorization` with the value set as specified below. If a request is made without this header, processing stops and an HTTP 401 is issued. All `Authorization` headers follow the same format: ``` Authorization: Basic 000000000000000000000000000000000000000000000000000000000000 ``` Where the Zeros are replaced by your Token. The Token can be formed by taking your username and your AuthorizationKey and adding a colon. For example, if your username is `sampleuser` and your AuthorizationKey is `7eaa6338-a097-4221-ac04-b6120fcc4d49` you would have this string: ``` sampleuser:7eaa6338-a097-4221-ac04-b6120fcc4d49 ``` This string must then be encoded using Base64 Encoded to form the Token, which will be the same length as the example above, but include letters and numbers. For our example, we would have: ``` c2FtcGxldXNlcjo3ZWFhNjMzOC1hMDk3LTQyMjEtYWMwNC1iNjEyMGZjYzRkNDk= ``` Most API client libraries can handle computing the authorization header using a username and password for you NOTICE: Publicly distributing an application, code snippet, etc, that has your username and token in it, encoded or not, WILL result in your token being blocked from the API. Each user should apply for their own token. If you wish to acquire a token for your development, you may do so by requesting a token through our automated system on this website.
5
+
6
+ OpenAPI spec version: v2.0
7
+
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+ Swagger Codegen version: 3.0.29
10
+ =end
11
+
12
+ require 'spec_helper'
13
+ require 'json'
14
+ require 'date'
15
+
16
+ # Unit tests for FtcEventsClient::AllianceScore2020
17
+ # Automatically generated by swagger-codegen (github.com/swagger-api/swagger-codegen)
18
+ # Please update as you see appropriate
19
+ describe 'AllianceScore2020' do
20
+ before do
21
+ # run before each test
22
+ @instance = FtcEventsClient::AllianceScore2020.new
23
+ end
24
+
25
+ after do
26
+ # run after each test
27
+ end
28
+
29
+ describe 'test an instance of AllianceScore2020' do
30
+ it 'should create an instance of AllianceScore2020' do
31
+ expect(@instance).to be_instance_of(FtcEventsClient::AllianceScore2020)
32
+ end
33
+ end
34
+ describe 'test attribute "adjust"' do
35
+ it 'should work' do
36
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
37
+ end
38
+ end
39
+
40
+ describe 'test attribute "dc_points"' do
41
+ it 'should work' do
42
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
43
+ end
44
+ end
45
+
46
+ describe 'test attribute "auto_points"' do
47
+ it 'should work' do
48
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
49
+ end
50
+ end
51
+
52
+ describe 'test attribute "dc_tower_low"' do
53
+ it 'should work' do
54
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
55
+ end
56
+ end
57
+
58
+ describe 'test attribute "dc_tower_mid"' do
59
+ it 'should work' do
60
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
61
+ end
62
+ end
63
+
64
+ describe 'test attribute "dc_tower_high"' do
65
+ it 'should work' do
66
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
67
+ end
68
+ end
69
+
70
+ describe 'test attribute "navigated1"' do
71
+ it 'should work' do
72
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
73
+ end
74
+ end
75
+
76
+ describe 'test attribute "navigated2"' do
77
+ it 'should work' do
78
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
79
+ end
80
+ end
81
+
82
+ describe 'test attribute "wobble_delivered1"' do
83
+ it 'should work' do
84
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
85
+ end
86
+ end
87
+
88
+ describe 'test attribute "wobble_delivered2"' do
89
+ it 'should work' do
90
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
91
+ end
92
+ end
93
+
94
+ describe 'test attribute "auto_tower_low"' do
95
+ it 'should work' do
96
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
97
+ end
98
+ end
99
+
100
+ describe 'test attribute "auto_tower_mid"' do
101
+ it 'should work' do
102
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
103
+ end
104
+ end
105
+
106
+ describe 'test attribute "auto_tower_high"' do
107
+ it 'should work' do
108
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
109
+ end
110
+ end
111
+
112
+ describe 'test attribute "auto_tower_points"' do
113
+ it 'should work' do
114
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
115
+ end
116
+ end
117
+
118
+ describe 'test attribute "auto_power_shot_left"' do
119
+ it 'should work' do
120
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
121
+ end
122
+ end
123
+
124
+ describe 'test attribute "auto_power_shot_center"' do
125
+ it 'should work' do
126
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
127
+ end
128
+ end
129
+
130
+ describe 'test attribute "auto_power_shot_right"' do
131
+ it 'should work' do
132
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
133
+ end
134
+ end
135
+
136
+ describe 'test attribute "auto_power_shot_points"' do
137
+ it 'should work' do
138
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
139
+ end
140
+ end
141
+
142
+ describe 'test attribute "wobble_rings1"' do
143
+ it 'should work' do
144
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
145
+ end
146
+ end
147
+
148
+ describe 'test attribute "wobble_rings2"' do
149
+ it 'should work' do
150
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
151
+ end
152
+ end
153
+
154
+ describe 'test attribute "wobble_end1"' do
155
+ it 'should work' do
156
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
157
+ end
158
+ end
159
+
160
+ describe 'test attribute "wobble_end2"' do
161
+ it 'should work' do
162
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
163
+ end
164
+ end
165
+
166
+ describe 'test attribute "wobble_end_points"' do
167
+ it 'should work' do
168
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
169
+ end
170
+ end
171
+
172
+ describe 'test attribute "wobble_ring_points"' do
173
+ it 'should work' do
174
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
175
+ end
176
+ end
177
+
178
+ describe 'test attribute "auto_wobble_points"' do
179
+ it 'should work' do
180
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
181
+ end
182
+ end
183
+
184
+ describe 'test attribute "end_power_shot_left"' do
185
+ it 'should work' do
186
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
187
+ end
188
+ end
189
+
190
+ describe 'test attribute "end_power_shot_center"' do
191
+ it 'should work' do
192
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
193
+ end
194
+ end
195
+
196
+ describe 'test attribute "end_power_shot_right"' do
197
+ it 'should work' do
198
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
199
+ end
200
+ end
201
+
202
+ describe 'test attribute "end_power_shot_points"' do
203
+ it 'should work' do
204
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
205
+ end
206
+ end
207
+
208
+ describe 'test attribute "penalty_points"' do
209
+ it 'should work' do
210
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
211
+ end
212
+ end
213
+
214
+ describe 'test attribute "major_penalties"' do
215
+ it 'should work' do
216
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
217
+ end
218
+ end
219
+
220
+ describe 'test attribute "minor_penalties"' do
221
+ it 'should work' do
222
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
223
+ end
224
+ end
225
+
226
+ describe 'test attribute "navigation_points"' do
227
+ it 'should work' do
228
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
229
+ end
230
+ end
231
+
232
+ describe 'test attribute "endgame_points"' do
233
+ it 'should work' do
234
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
235
+ end
236
+ end
237
+
238
+ describe 'test attribute "total_points"' do
239
+ it 'should work' do
240
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
241
+ end
242
+ end
243
+
244
+ end
@@ -0,0 +1,28 @@
1
+ =begin
2
+ #FTC Events API
3
+
4
+ #FTC Events API is a service to return relevant information about the _FIRST_ Tech Challenge (FTC). Information is made available from events operating around the world Information is currently made available after the conclusion of the tournament. The API will provide data as soon as it has synced, and we do not add any artificial delays. ## Documentation Notes ### Timezones All times are listed in the local time to the event venue. HTTP-date values will show their timezone. ### Query Parameters If you specify a parameter, but no value for that parameter, it will be ignored. For example, if you request `URL?teamNumber=` the `teamNumber` parameter would be ignored. For all APIs that accept a query string in addition to the base URI, the order of parameters do not matter, but the name shown in the documentation must match exactly, as does the associated value format as described in details. For response codes that are not HTTP 200 (OK), the documentation will show a body message that represents a possible response value. While the \"title\" of the HTTP Status Code will match those shown in the response codes documentation section exactly, the body of the response will be a more detailed explanation of why that status code is being returned and may not always be exactly as shown in the examples. ### Experimenting with the API This documentation is rendered at both [api-docs](https://ftc-events.firstinspires.org/api-docs) and [try-it-out](https://ftc-events.firstinspires.org/try-it-out). [api-docs](https://ftc-events.firstinspires.org/api-docs) has a three panel, easy to read layout, while [try-it-out](https://ftc-events.firstinspires.org/try-it-out) has a feature that allows you try out endpoints from within the page. Additionally, the Open API Json is availabe at [Open API](https://ftc-events.firstinspires.org/swagger/v2.0/swagger.json). This can be imported into a tool such as [Postman](https://www.postman.com) for experimentation as well. ### Last-Modified, FMS-OnlyModifiedSince, and If-Modified-Since Headers The FTC Events API utilizes the `Last-Modified` and `If-Modified-Since` Headers to communicate with consumers regarding the age of the data they are requesting. With a couple of exceptions, all calls will return a `Last-Modified` Header set with the time at which the data at that endpoint was last modified. The Header will always be set in the HTTP-date format, as described in the HTTP Protocol. There are two exceptions: the `Last-Modified` Header is not set if the endpoint returns no results (such as a request for a schedule with no matches). Consumers should keep track of the `Last-Modified` Header, and return it on subsequent calls to the same endpoint as the If-Modified-Since. The server will recognize this request, and will only return a result if the data has been modified since the last request. If no changes have been made, an HTTP 304 will be returned. If data has been modified, ALL data on that call will be returned (for \"only modified\" data, see below). The FTC Events API also allows a custom header used to filter the return data to a specific subset. This is done by specifying a `FMS-OnlyModifiedSince` header with each call. As with the `If-Modified-Since` header, consumers should keep track of the Last-Modified Header, and return it on subsequent calls to the same endpoint as the `FMS-OnlyModifiedSince` Header. The server will recognize this request, and will only return a result if the data has been modified since the last request, and, if returned, the data will only be those portions modified since the included date. If no changes, have been made, an HTTP 304 will be returned. Using this method, the server and consumer save processing time by only receiving modified data that is in need of update on the consumer side. If the Headers are improperly passed (such as the wrong Day of Week for the matching date, or a date in the future), the endpoint will simply ignore the Header and return all results. If both headers are specified, the request will be denied. ## Response Codes The FTC Events API HTTP Status Codes correspond with the [common codes](http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html), but occasionally with different \"titles\". The \"title\" used by the API is shown next to each of the below possible response HTTP Status Codes. Throughout the documentation, Apiary may automatically show the common \"title\" in example returns (like \"Not Found\" for 404) but on the production server, the \"title\" will instead match those listed below. ### HTTP 200 - \"OK\" The request has succeeded. An entity corresponding to the requested resource is sent in the response. This will be returned as the HTTP Status Code for all request that succeed, even if the body is empty (such as an event that has no rankings, but with a valid season and event code were used) ### HTTP 304 - \"Not Modified\" When utilizing a Header that allows filtered data returns, such as `If-Modified-Since`, this response indicates that no data meets the request. ### HTTP 400 - \"Invalid Season Requested\"/\"Malformed Parameter Format In Request\"/\"Missing Parameter In Request\"/\"Invalid API Version Requested\": The request could not be understood by the server due to malformed syntax. The client SHOULD NOT repeat the request without modifications. Specifically for this API, a 400 response indicates that the requested URI matches with a valid API, but one or more required parameter was malformed or invalid. Examples include an event code that is too short or team number that contains a letter. ### HTTP 401 - \"Unauthorized\" All requests against the API require authentication via a valid user token. Failing to provide one, or providing an invalid one, will warrant a 401 response. The client MAY repeat the request with a suitable Authorization header field. ### HTTP 404 - \"Invalid Event Requested\" Even though the 404 code usually indicates any not found status, a 404 will only be issued in this API when an event cannot be found for the requested season and event code. If the request didn't match a valid API or there were malformed parameters, the response would not receive a 404 but rather a 400 or 501. If this HTTP code is received, the season was a valid season and the event code matched the acceptable style of an event code, but there were no records of an event matching the combination of that season and event code. For example, HTTP 404 would be issued when the event had a different code in the requested season (the codes can change year to year based on event location). ### HTTP 500 - \"Internal Server Error\" The server encountered an unexpected condition which prevented it from fulfilling the request. This is a code sent directly by the server, and has no special alternate definition specific to this API. ### HTTP 501 - \"Request Did Not Match Any Current API Pattern\" The server does not support the functionality required to fulfill the request. Specifically, the request pattern did not match any of the possible APIs, and thus processing was discontinued. This code is also issued when too many optional parameters were included in a single request and fulfilling it would make the result confusing or misleading. Each API will specify which parameters or combination of parameters can be used at the same time. ### HTTP 503 - \"Service Unavailable\" The server is currently unable to handle the request due to a temporary overloading or maintenance of the server. The implication is that this is a temporary condition which will be alleviated after some delay. If known, the length of the delay MAY be indicated in a `Retry-After` header. This code will not always appear, sometimes the server may outright refuse the connection instead. This is a code sent directly by the server, and has no special alternate definition specific to this API. ## Authorization In order to make calls against the FTC Events API, you must include an HTTP Header called `Authorization` with the value set as specified below. If a request is made without this header, processing stops and an HTTP 401 is issued. All `Authorization` headers follow the same format: ``` Authorization: Basic 000000000000000000000000000000000000000000000000000000000000 ``` Where the Zeros are replaced by your Token. The Token can be formed by taking your username and your AuthorizationKey and adding a colon. For example, if your username is `sampleuser` and your AuthorizationKey is `7eaa6338-a097-4221-ac04-b6120fcc4d49` you would have this string: ``` sampleuser:7eaa6338-a097-4221-ac04-b6120fcc4d49 ``` This string must then be encoded using Base64 Encoded to form the Token, which will be the same length as the example above, but include letters and numbers. For our example, we would have: ``` c2FtcGxldXNlcjo3ZWFhNjMzOC1hMDk3LTQyMjEtYWMwNC1iNjEyMGZjYzRkNDk= ``` Most API client libraries can handle computing the authorization header using a username and password for you NOTICE: Publicly distributing an application, code snippet, etc, that has your username and token in it, encoded or not, WILL result in your token being blocked from the API. Each user should apply for their own token. If you wish to acquire a token for your development, you may do so by requesting a token through our automated system on this website.
5
+
6
+ The version of the OpenAPI document: v2.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 5.0.0-SNAPSHOT
10
+
11
+ =end
12
+
13
+ require 'spec_helper'
14
+ require 'json'
15
+ require 'date'
16
+
17
+ # Unit tests for FtcEventsClient::AutoNavigatedStatus
18
+ # Automatically generated by openapi-generator (https://openapi-generator.tech)
19
+ # Please update as you see appropriate
20
+ describe FtcEventsClient::AutoNavigatedStatus do
21
+ let(:instance) { FtcEventsClient::AutoNavigatedStatus.new }
22
+
23
+ describe 'test an instance of AutoNavigatedStatus' do
24
+ it 'should create an instance of AutoNavigatedStatus' do
25
+ expect(instance).to be_instance_of(FtcEventsClient::AutoNavigatedStatus)
26
+ end
27
+ end
28
+ end