ftc_events_client 0.2.2 → 0.3.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (190) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +101 -5
  3. data/build.sh +0 -0
  4. data/config.json +1 -1
  5. data/docs/AdvancementApi.md +120 -0
  6. data/docs/AdvancementModel.md +9 -0
  7. data/docs/AdvancementSlot.md +13 -0
  8. data/docs/AdvancementSourceModel.md +10 -0
  9. data/docs/AllianceModelVersion2.md +3 -0
  10. data/docs/AllianceSelectionApi.md +56 -1
  11. data/docs/AllianceSelectionDetailModel.md +8 -0
  12. data/docs/ApiAdvancementStatus.md +6 -0
  13. data/docs/AutoNavigation.md +6 -0
  14. data/docs/AwardAssignmentModel.md +1 -0
  15. data/docs/AwardsApi.md +1 -1
  16. data/docs/Coordinate.md +12 -0
  17. data/docs/CoordinateEqualityComparer.md +6 -0
  18. data/docs/CoordinateSequence.md +17 -0
  19. data/docs/CoordinateSequenceFactory.md +7 -0
  20. data/docs/Dimension.md +6 -0
  21. data/docs/EndGameLocation.md +6 -0
  22. data/docs/Envelope.md +18 -0
  23. data/docs/FieldSide.md +6 -0
  24. data/docs/GeneralApi.md +1 -1
  25. data/docs/Geometry.md +30 -0
  26. data/docs/GeometryFactory.md +10 -0
  27. data/docs/GeometryOverlay.md +6 -0
  28. data/docs/JunctionElement.md +6 -0
  29. data/docs/LeaguesApi.md +1 -1
  30. data/docs/MatchResultsApi.md +1 -1
  31. data/docs/NtsGeometryServices.md +11 -0
  32. data/docs/OgcGeometryType.md +6 -0
  33. data/docs/Ordinates.md +6 -0
  34. data/docs/Point.md +35 -0
  35. data/docs/PrecisionModel.md +11 -0
  36. data/docs/PrecisionModels.md +6 -0
  37. data/docs/RankingsApi.md +1 -1
  38. data/docs/ScheduleApi.md +1 -1
  39. data/docs/ScheduleHybridModelTeamVersion2.md +2 -0
  40. data/docs/ScheduleHybridModelVersion2.md +2 -0
  41. data/docs/ScheduledMatchTeamModelVersion2.md +3 -0
  42. data/docs/ScoreDetailAllianceModel2022.md +42 -0
  43. data/docs/ScoreDetailAllianceModel2023.md +44 -0
  44. data/docs/ScoreDetailModel2021.md +1 -0
  45. data/docs/ScoreDetailModel2022.md +11 -0
  46. data/docs/ScoreDetailModel2023.md +11 -0
  47. data/docs/ScoreDetailModelSinglePlayer2021.md +1 -0
  48. data/docs/ScoreDetailModelSinglePlayer2022.md +11 -0
  49. data/docs/ScoreDetailModelSinglePlayer2023.md +11 -0
  50. data/docs/ScoreDetailSinglePlayer2022.md +35 -0
  51. data/docs/ScoreDetailSinglePlayer2023.md +36 -0
  52. data/docs/SeasonDataApi.md +1 -1
  53. data/docs/SeasonEventModelVersion2.md +3 -0
  54. data/docs/SeasonLeagueModelVersion2.md +2 -0
  55. data/docs/SeasonTeamModelVersion2.md +3 -0
  56. data/docs/SelectionModel.md +9 -0
  57. data/docs/SelectionResult.md +6 -0
  58. data/docs/TeamRankingModel.md +2 -0
  59. data/ftc_events_client-0.3.0.gem +0 -0
  60. data/ftc_events_client.gemspec +1 -1
  61. data/git_push.sh +0 -0
  62. data/lib/ftc_events_client/api/advancement_api.rb +147 -0
  63. data/lib/ftc_events_client/api/alliance_selection_api.rb +63 -1
  64. data/lib/ftc_events_client/api/awards_api.rb +1 -1
  65. data/lib/ftc_events_client/api/general_api.rb +1 -1
  66. data/lib/ftc_events_client/api/leagues_api.rb +1 -1
  67. data/lib/ftc_events_client/api/match_results_api.rb +1 -1
  68. data/lib/ftc_events_client/api/rankings_api.rb +1 -1
  69. data/lib/ftc_events_client/api/schedule_api.rb +1 -1
  70. data/lib/ftc_events_client/api/season_data_api.rb +1 -1
  71. data/lib/ftc_events_client/api_client.rb +3 -13
  72. data/lib/ftc_events_client/api_error.rb +1 -1
  73. data/lib/ftc_events_client/configuration.rb +3 -3
  74. data/lib/ftc_events_client/models/advancement_model.rb +231 -0
  75. data/lib/ftc_events_client/models/advancement_slot.rb +269 -0
  76. data/lib/ftc_events_client/models/advancement_source_model.rb +242 -0
  77. data/lib/ftc_events_client/models/alliance_model_version2.rb +32 -2
  78. data/lib/ftc_events_client/models/alliance_score_2020.rb +1 -1
  79. data/lib/ftc_events_client/models/alliance_selection_detail_model.rb +218 -0
  80. data/lib/ftc_events_client/models/alliance_selection_model_version2.rb +1 -1
  81. data/lib/ftc_events_client/models/api_advancement_status.rb +31 -0
  82. data/lib/ftc_events_client/models/api_index_model.rb +1 -1
  83. data/lib/ftc_events_client/models/auto_navigated_status.rb +1 -1
  84. data/lib/ftc_events_client/models/auto_navigation.rb +29 -0
  85. data/lib/ftc_events_client/models/award_assignment_model.rb +12 -2
  86. data/lib/ftc_events_client/models/awards_model.rb +1 -1
  87. data/lib/ftc_events_client/models/barcode_element.rb +1 -1
  88. data/lib/ftc_events_client/models/coordinate.rb +251 -0
  89. data/lib/ftc_events_client/models/coordinate_equality_comparer.rb +197 -0
  90. data/lib/ftc_events_client/models/coordinate_sequence.rb +296 -0
  91. data/lib/ftc_events_client/models/coordinate_sequence_factory.rb +206 -0
  92. data/lib/ftc_events_client/models/dimension.rb +33 -0
  93. data/lib/ftc_events_client/models/end_game_location.rb +29 -0
  94. data/lib/ftc_events_client/models/endgame_parked_status.rb +1 -1
  95. data/lib/ftc_events_client/models/envelope.rb +305 -0
  96. data/lib/ftc_events_client/models/event_match_results_model_version2.rb +1 -1
  97. data/lib/ftc_events_client/models/event_rankings_model.rb +1 -1
  98. data/lib/ftc_events_client/models/event_schedule_hybrid_model_version2.rb +1 -1
  99. data/lib/ftc_events_client/models/event_schedule_model_version2.rb +1 -1
  100. data/lib/ftc_events_client/models/field_side.rb +28 -0
  101. data/lib/ftc_events_client/models/ftc_event_level.rb +1 -1
  102. data/lib/ftc_events_client/models/geometry.rb +418 -0
  103. data/lib/ftc_events_client/models/geometry_factory.rb +233 -0
  104. data/lib/ftc_events_client/models/geometry_overlay.rb +197 -0
  105. data/lib/ftc_events_client/models/junction_element.rb +32 -0
  106. data/lib/ftc_events_client/models/league_member_list_model.rb +1 -1
  107. data/lib/ftc_events_client/models/match_result_model_version2.rb +1 -1
  108. data/lib/ftc_events_client/models/match_result_team_model_version2.rb +1 -1
  109. data/lib/ftc_events_client/models/match_scores_model.rb +1 -1
  110. data/lib/ftc_events_client/models/nts_geometry_services.rb +242 -0
  111. data/lib/ftc_events_client/models/ogc_geometry_type.rb +42 -0
  112. data/lib/ftc_events_client/models/one_of_match_scores_model_match_scores_items.rb +1 -1
  113. data/lib/ftc_events_client/models/ordinates.rb +66 -0
  114. data/lib/ftc_events_client/models/point.rb +463 -0
  115. data/lib/ftc_events_client/models/precision_model.rb +242 -0
  116. data/lib/ftc_events_client/models/precision_models.rb +29 -0
  117. data/lib/ftc_events_client/models/schedule_hybrid_model_team_version2.rb +26 -6
  118. data/lib/ftc_events_client/models/schedule_hybrid_model_version2.rb +22 -2
  119. data/lib/ftc_events_client/models/scheduled_match_model_version2.rb +1 -1
  120. data/lib/ftc_events_client/models/scheduled_match_team_model_version2.rb +32 -2
  121. data/lib/ftc_events_client/models/score_detail_alliance_model_2020.rb +1 -1
  122. data/lib/ftc_events_client/models/score_detail_alliance_model_2021.rb +1 -1
  123. data/lib/ftc_events_client/models/score_detail_alliance_model_2022.rb +540 -0
  124. data/lib/ftc_events_client/models/score_detail_alliance_model_2023.rb +540 -0
  125. data/lib/ftc_events_client/models/score_detail_model_2019.rb +1 -1
  126. data/lib/ftc_events_client/models/score_detail_model_2020.rb +1 -1
  127. data/lib/ftc_events_client/models/score_detail_model_2021.rb +11 -2
  128. data/lib/ftc_events_client/models/score_detail_model_2022.rb +245 -0
  129. data/lib/ftc_events_client/models/score_detail_model_2023.rb +245 -0
  130. data/lib/ftc_events_client/models/score_detail_model_alliance_2019.rb +1 -1
  131. data/lib/ftc_events_client/models/score_detail_model_single_player_2020.rb +1 -1
  132. data/lib/ftc_events_client/models/score_detail_model_single_player_2021.rb +11 -2
  133. data/lib/ftc_events_client/models/score_detail_model_single_player_2022.rb +242 -0
  134. data/lib/ftc_events_client/models/score_detail_model_single_player_2023.rb +242 -0
  135. data/lib/ftc_events_client/models/score_detail_single_player_2021.rb +1 -1
  136. data/lib/ftc_events_client/models/score_detail_single_player_2022.rb +474 -0
  137. data/lib/ftc_events_client/models/score_detail_single_player_2023.rb +467 -0
  138. data/lib/ftc_events_client/models/season_award_listings_model.rb +1 -1
  139. data/lib/ftc_events_client/models/season_awards_model.rb +1 -1
  140. data/lib/ftc_events_client/models/season_event_listings_model_version2.rb +1 -1
  141. data/lib/ftc_events_client/models/season_event_model_version2.rb +30 -2
  142. data/lib/ftc_events_client/models/season_league_listings_model_version2.rb +1 -1
  143. data/lib/ftc_events_client/models/season_league_model_version2.rb +22 -2
  144. data/lib/ftc_events_client/models/season_summary_model_championship.rb +1 -1
  145. data/lib/ftc_events_client/models/season_summary_model_version2.rb +1 -1
  146. data/lib/ftc_events_client/models/season_team_listings_model_version2.rb +1 -1
  147. data/lib/ftc_events_client/models/season_team_model_version2.rb +36 -6
  148. data/lib/ftc_events_client/models/selection_model.rb +224 -0
  149. data/lib/ftc_events_client/models/selection_result.rb +29 -0
  150. data/lib/ftc_events_client/models/stone.rb +1 -1
  151. data/lib/ftc_events_client/models/team_ranking_model.rb +22 -2
  152. data/lib/ftc_events_client/version.rb +2 -2
  153. data/lib/ftc_events_client.rb +36 -1
  154. data/spec/api/advancement_api_spec.rb +61 -0
  155. data/spec/models/advancement_model_spec.rb +52 -0
  156. data/spec/models/advancement_slot_spec.rb +76 -0
  157. data/spec/models/advancement_source_model_spec.rb +58 -0
  158. data/spec/models/alliance_selection_detail_model_spec.rb +46 -0
  159. data/spec/models/api_advancement_status_spec.rb +34 -0
  160. data/spec/models/auto_navigation_spec.rb +34 -0
  161. data/spec/models/coordinate_equality_comparer_spec.rb +34 -0
  162. data/spec/models/coordinate_sequence_factory_spec.rb +40 -0
  163. data/spec/models/coordinate_sequence_spec.rb +100 -0
  164. data/spec/models/coordinate_spec.rb +70 -0
  165. data/spec/models/dimension_spec.rb +34 -0
  166. data/spec/models/end_game_location_spec.rb +34 -0
  167. data/spec/models/envelope_spec.rb +106 -0
  168. data/spec/models/field_side_spec.rb +34 -0
  169. data/spec/models/geometry_factory_spec.rb +58 -0
  170. data/spec/models/geometry_overlay_spec.rb +34 -0
  171. data/spec/models/geometry_spec.rb +178 -0
  172. data/spec/models/junction_element_spec.rb +34 -0
  173. data/spec/models/nts_geometry_services_spec.rb +64 -0
  174. data/spec/models/ogc_geometry_type_spec.rb +34 -0
  175. data/spec/models/ordinates_spec.rb +34 -0
  176. data/spec/models/point_spec.rb +208 -0
  177. data/spec/models/precision_model_spec.rb +64 -0
  178. data/spec/models/precision_models_spec.rb +34 -0
  179. data/spec/models/score_detail_alliance_model_2022_spec.rb +250 -0
  180. data/spec/models/score_detail_alliance_model_2023_spec.rb +262 -0
  181. data/spec/models/score_detail_model_2022_spec.rb +64 -0
  182. data/spec/models/score_detail_model_2023_spec.rb +64 -0
  183. data/spec/models/score_detail_model_single_player_2022_spec.rb +64 -0
  184. data/spec/models/score_detail_model_single_player_2023_spec.rb +64 -0
  185. data/spec/models/score_detail_single_player_2022_spec.rb +208 -0
  186. data/spec/models/score_detail_single_player_2023_spec.rb +214 -0
  187. data/spec/models/selection_model_spec.rb +52 -0
  188. data/spec/models/selection_result_spec.rb +34 -0
  189. data/update.sh +1 -1
  190. metadata +145 -3
@@ -6,7 +6,7 @@
6
6
  OpenAPI spec version: v2.0
7
7
 
8
8
  Generated by: https://github.com/swagger-api/swagger-codegen.git
9
- Swagger Codegen version: 3.0.29
9
+ Swagger Codegen version: 3.0.52
10
10
  =end
11
11
 
12
12
  # Common files
@@ -16,38 +16,70 @@ require 'ftc_events_client/version'
16
16
  require 'ftc_events_client/configuration'
17
17
 
18
18
  # Models
19
+ require 'ftc_events_client/models/advancement_model'
20
+ require 'ftc_events_client/models/advancement_slot'
21
+ require 'ftc_events_client/models/advancement_source_model'
19
22
  require 'ftc_events_client/models/alliance_model_version2'
20
23
  require 'ftc_events_client/models/alliance_score_2020'
24
+ require 'ftc_events_client/models/alliance_selection_detail_model'
21
25
  require 'ftc_events_client/models/alliance_selection_model_version2'
26
+ require 'ftc_events_client/models/api_advancement_status'
22
27
  require 'ftc_events_client/models/api_index_model'
23
28
  require 'ftc_events_client/models/auto_navigated_status'
29
+ require 'ftc_events_client/models/auto_navigation'
24
30
  require 'ftc_events_client/models/award_assignment_model'
25
31
  require 'ftc_events_client/models/awards_model'
26
32
  require 'ftc_events_client/models/barcode_element'
33
+ require 'ftc_events_client/models/coordinate'
34
+ require 'ftc_events_client/models/coordinate_equality_comparer'
35
+ require 'ftc_events_client/models/coordinate_sequence'
36
+ require 'ftc_events_client/models/coordinate_sequence_factory'
37
+ require 'ftc_events_client/models/dimension'
38
+ require 'ftc_events_client/models/end_game_location'
27
39
  require 'ftc_events_client/models/endgame_parked_status'
40
+ require 'ftc_events_client/models/envelope'
28
41
  require 'ftc_events_client/models/event_match_results_model_version2'
29
42
  require 'ftc_events_client/models/event_rankings_model'
30
43
  require 'ftc_events_client/models/event_schedule_hybrid_model_version2'
31
44
  require 'ftc_events_client/models/event_schedule_model_version2'
32
45
  require 'ftc_events_client/models/ftc_event_level'
46
+ require 'ftc_events_client/models/field_side'
47
+ require 'ftc_events_client/models/geometry'
48
+ require 'ftc_events_client/models/geometry_factory'
49
+ require 'ftc_events_client/models/geometry_overlay'
50
+ require 'ftc_events_client/models/junction_element'
33
51
  require 'ftc_events_client/models/league_member_list_model'
34
52
  require 'ftc_events_client/models/match_result_model_version2'
35
53
  require 'ftc_events_client/models/match_result_team_model_version2'
36
54
  require 'ftc_events_client/models/match_scores_model'
55
+ require 'ftc_events_client/models/nts_geometry_services'
56
+ require 'ftc_events_client/models/ogc_geometry_type'
37
57
  require 'ftc_events_client/models/one_of_match_scores_model_match_scores_items'
58
+ require 'ftc_events_client/models/ordinates'
59
+ require 'ftc_events_client/models/point'
60
+ require 'ftc_events_client/models/precision_model'
61
+ require 'ftc_events_client/models/precision_models'
38
62
  require 'ftc_events_client/models/schedule_hybrid_model_team_version2'
39
63
  require 'ftc_events_client/models/schedule_hybrid_model_version2'
40
64
  require 'ftc_events_client/models/scheduled_match_model_version2'
41
65
  require 'ftc_events_client/models/scheduled_match_team_model_version2'
42
66
  require 'ftc_events_client/models/score_detail_alliance_model_2020'
43
67
  require 'ftc_events_client/models/score_detail_alliance_model_2021'
68
+ require 'ftc_events_client/models/score_detail_alliance_model_2022'
69
+ require 'ftc_events_client/models/score_detail_alliance_model_2023'
44
70
  require 'ftc_events_client/models/score_detail_model_2019'
45
71
  require 'ftc_events_client/models/score_detail_model_2020'
46
72
  require 'ftc_events_client/models/score_detail_model_2021'
73
+ require 'ftc_events_client/models/score_detail_model_2022'
74
+ require 'ftc_events_client/models/score_detail_model_2023'
47
75
  require 'ftc_events_client/models/score_detail_model_alliance_2019'
48
76
  require 'ftc_events_client/models/score_detail_model_single_player_2020'
49
77
  require 'ftc_events_client/models/score_detail_model_single_player_2021'
78
+ require 'ftc_events_client/models/score_detail_model_single_player_2022'
79
+ require 'ftc_events_client/models/score_detail_model_single_player_2023'
50
80
  require 'ftc_events_client/models/score_detail_single_player_2021'
81
+ require 'ftc_events_client/models/score_detail_single_player_2022'
82
+ require 'ftc_events_client/models/score_detail_single_player_2023'
51
83
  require 'ftc_events_client/models/season_award_listings_model'
52
84
  require 'ftc_events_client/models/season_awards_model'
53
85
  require 'ftc_events_client/models/season_event_listings_model_version2'
@@ -58,10 +90,13 @@ require 'ftc_events_client/models/season_summary_model_championship'
58
90
  require 'ftc_events_client/models/season_summary_model_version2'
59
91
  require 'ftc_events_client/models/season_team_listings_model_version2'
60
92
  require 'ftc_events_client/models/season_team_model_version2'
93
+ require 'ftc_events_client/models/selection_model'
94
+ require 'ftc_events_client/models/selection_result'
61
95
  require 'ftc_events_client/models/stone'
62
96
  require 'ftc_events_client/models/team_ranking_model'
63
97
 
64
98
  # APIs
99
+ require 'ftc_events_client/api/advancement_api'
65
100
  require 'ftc_events_client/api/alliance_selection_api'
66
101
  require 'ftc_events_client/api/awards_api'
67
102
  require 'ftc_events_client/api/general_api'
@@ -0,0 +1,61 @@
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.52
10
+ =end
11
+
12
+ require 'spec_helper'
13
+ require 'json'
14
+
15
+ # Unit tests for FtcEventsClient::AdvancementApi
16
+ # Automatically generated by swagger-codegen (github.com/swagger-api/swagger-codegen)
17
+ # Please update as you see appropriate
18
+ describe 'AdvancementApi' do
19
+ before do
20
+ # run before each test
21
+ @instance = FtcEventsClient::AdvancementApi.new
22
+ end
23
+
24
+ after do
25
+ # run after each test
26
+ end
27
+
28
+ describe 'test an instance of AdvancementApi' do
29
+ it 'should create an instance of AdvancementApi' do
30
+ expect(@instance).to be_instance_of(FtcEventsClient::AdvancementApi)
31
+ end
32
+ end
33
+
34
+ # unit tests for v20_season_advancement_event_code_get
35
+ # Event Advancement
36
+ # The event advancement endpoint returns details about teams advancing from a particular event in a particular season.
37
+ # @param season Numeric year of the event from which the event advancement is requested. Must be 4 digits > 2022
38
+ # @param event_code Case insensitive alphanumeric `eventCode` of the event from which the advancement results are requested. Must be at least 3 characters.
39
+ # @param [Hash] opts the optional parameters
40
+ # @option opts [BOOLEAN] :exclude_skipped `excludeSkipped=true` to exclude skipped advancement slots. Slots are skipped if no team meets the criteria, the team has already advanced, or the team was ineligible.
41
+ # @return [AdvancementModel]
42
+ describe 'v20_season_advancement_event_code_get test' do
43
+ it 'should work' do
44
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
45
+ end
46
+ end
47
+
48
+ # unit tests for v20_season_advancement_event_code_source_get
49
+ # Advancement Source
50
+ # The advancement source API returns details about where teams advanced to a specified event from.
51
+ # @param season Numeric year of the event from which the advancement is requested. Must be 4 digits >= 2022
52
+ # @param event_code Case insensitive alphanumeric `eventCode` of the event for which teams advanced to. Must be at least 3 characters.
53
+ # @param [Hash] opts the optional parameters
54
+ # @return [Array<AdvancementSourceModel>]
55
+ describe 'v20_season_advancement_event_code_source_get test' do
56
+ it 'should work' do
57
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
58
+ end
59
+ end
60
+
61
+ end
@@ -0,0 +1,52 @@
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.52
10
+ =end
11
+
12
+ require 'spec_helper'
13
+ require 'json'
14
+ require 'date'
15
+
16
+ # Unit tests for FtcEventsClient::AdvancementModel
17
+ # Automatically generated by swagger-codegen (github.com/swagger-api/swagger-codegen)
18
+ # Please update as you see appropriate
19
+ describe 'AdvancementModel' do
20
+ before do
21
+ # run before each test
22
+ @instance = FtcEventsClient::AdvancementModel.new
23
+ end
24
+
25
+ after do
26
+ # run after each test
27
+ end
28
+
29
+ describe 'test an instance of AdvancementModel' do
30
+ it 'should create an instance of AdvancementModel' do
31
+ expect(@instance).to be_instance_of(FtcEventsClient::AdvancementModel)
32
+ end
33
+ end
34
+ describe 'test attribute "advances_to"' 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 "slots"' 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 "advancement"' 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
+ end
@@ -0,0 +1,76 @@
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.52
10
+ =end
11
+
12
+ require 'spec_helper'
13
+ require 'json'
14
+ require 'date'
15
+
16
+ # Unit tests for FtcEventsClient::AdvancementSlot
17
+ # Automatically generated by swagger-codegen (github.com/swagger-api/swagger-codegen)
18
+ # Please update as you see appropriate
19
+ describe 'AdvancementSlot' do
20
+ before do
21
+ # run before each test
22
+ @instance = FtcEventsClient::AdvancementSlot.new
23
+ end
24
+
25
+ after do
26
+ # run after each test
27
+ end
28
+
29
+ describe 'test an instance of AdvancementSlot' do
30
+ it 'should create an instance of AdvancementSlot' do
31
+ expect(@instance).to be_instance_of(FtcEventsClient::AdvancementSlot)
32
+ end
33
+ end
34
+ describe 'test attribute "team"' 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 "team_id"' 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 "team_profile_id"' 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 "display_team"' 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 "slot"' 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 "criteria"' 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 "status"' 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
+ end
@@ -0,0 +1,58 @@
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.52
10
+ =end
11
+
12
+ require 'spec_helper'
13
+ require 'json'
14
+ require 'date'
15
+
16
+ # Unit tests for FtcEventsClient::AdvancementSourceModel
17
+ # Automatically generated by swagger-codegen (github.com/swagger-api/swagger-codegen)
18
+ # Please update as you see appropriate
19
+ describe 'AdvancementSourceModel' do
20
+ before do
21
+ # run before each test
22
+ @instance = FtcEventsClient::AdvancementSourceModel.new
23
+ end
24
+
25
+ after do
26
+ # run after each test
27
+ end
28
+
29
+ describe 'test an instance of AdvancementSourceModel' do
30
+ it 'should create an instance of AdvancementSourceModel' do
31
+ expect(@instance).to be_instance_of(FtcEventsClient::AdvancementSourceModel)
32
+ end
33
+ end
34
+ describe 'test attribute "advanced_from"' 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 "advanced_from_region"' 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 "slots"' 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 "advancement"' 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
+ end
@@ -0,0 +1,46 @@
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.52
10
+ =end
11
+
12
+ require 'spec_helper'
13
+ require 'json'
14
+ require 'date'
15
+
16
+ # Unit tests for FtcEventsClient::AllianceSelectionDetailModel
17
+ # Automatically generated by swagger-codegen (github.com/swagger-api/swagger-codegen)
18
+ # Please update as you see appropriate
19
+ describe 'AllianceSelectionDetailModel' do
20
+ before do
21
+ # run before each test
22
+ @instance = FtcEventsClient::AllianceSelectionDetailModel.new
23
+ end
24
+
25
+ after do
26
+ # run after each test
27
+ end
28
+
29
+ describe 'test an instance of AllianceSelectionDetailModel' do
30
+ it 'should create an instance of AllianceSelectionDetailModel' do
31
+ expect(@instance).to be_instance_of(FtcEventsClient::AllianceSelectionDetailModel)
32
+ end
33
+ end
34
+ describe 'test attribute "selections"' 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 "count"' 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
+ end
@@ -0,0 +1,34 @@
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.52
10
+ =end
11
+
12
+ require 'spec_helper'
13
+ require 'json'
14
+ require 'date'
15
+
16
+ # Unit tests for FtcEventsClient::ApiAdvancementStatus
17
+ # Automatically generated by swagger-codegen (github.com/swagger-api/swagger-codegen)
18
+ # Please update as you see appropriate
19
+ describe 'ApiAdvancementStatus' do
20
+ before do
21
+ # run before each test
22
+ @instance = FtcEventsClient::ApiAdvancementStatus.new
23
+ end
24
+
25
+ after do
26
+ # run after each test
27
+ end
28
+
29
+ describe 'test an instance of ApiAdvancementStatus' do
30
+ it 'should create an instance of ApiAdvancementStatus' do
31
+ expect(@instance).to be_instance_of(FtcEventsClient::ApiAdvancementStatus)
32
+ end
33
+ end
34
+ end
@@ -0,0 +1,34 @@
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.52
10
+ =end
11
+
12
+ require 'spec_helper'
13
+ require 'json'
14
+ require 'date'
15
+
16
+ # Unit tests for FtcEventsClient::AutoNavigation
17
+ # Automatically generated by swagger-codegen (github.com/swagger-api/swagger-codegen)
18
+ # Please update as you see appropriate
19
+ describe 'AutoNavigation' do
20
+ before do
21
+ # run before each test
22
+ @instance = FtcEventsClient::AutoNavigation.new
23
+ end
24
+
25
+ after do
26
+ # run after each test
27
+ end
28
+
29
+ describe 'test an instance of AutoNavigation' do
30
+ it 'should create an instance of AutoNavigation' do
31
+ expect(@instance).to be_instance_of(FtcEventsClient::AutoNavigation)
32
+ end
33
+ end
34
+ end