spinnaker-gate-ruby-client 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (156) hide show
  1. checksums.yaml +7 -0
  2. data/Gemfile +8 -0
  3. data/Gemfile.lock +85 -0
  4. data/LICENSE +201 -0
  5. data/README.md +240 -0
  6. data/Rakefile +8 -0
  7. data/docs/Account.md +14 -0
  8. data/docs/AccountDetails.md +19 -0
  9. data/docs/AmazonInfrastructureControllerApi.md +128 -0
  10. data/docs/ApplicationControllerApi.md +754 -0
  11. data/docs/ArtifactControllerApi.md +111 -0
  12. data/docs/AuthControllerApi.md +212 -0
  13. data/docs/BakeControllerApi.md +143 -0
  14. data/docs/BuildControllerApi.md +493 -0
  15. data/docs/ClusterControllerApi.md +475 -0
  16. data/docs/ConcourseControllerApi.md +161 -0
  17. data/docs/CredentialsControllerApi.md +129 -0
  18. data/docs/EcsServerGroupEventsControllerApi.md +66 -0
  19. data/docs/ExecutionsControllerApi.md +133 -0
  20. data/docs/FirewallControllerApi.md +171 -0
  21. data/docs/GrantedAuthority.md +8 -0
  22. data/docs/HashMapstringobject.md +7 -0
  23. data/docs/HttpEntity.md +8 -0
  24. data/docs/ImageControllerApi.md +178 -0
  25. data/docs/InstanceControllerApi.md +122 -0
  26. data/docs/JobControllerApi.md +69 -0
  27. data/docs/LoadBalancerControllerApi.md +217 -0
  28. data/docs/Mapstringstring.md +7 -0
  29. data/docs/NetworkControllerApi.md +105 -0
  30. data/docs/PipelineConfigControllerApi.md +144 -0
  31. data/docs/PipelineControllerApi.md +1074 -0
  32. data/docs/PipelineTemplateDependent.md +10 -0
  33. data/docs/PipelineTemplatesControllerApi.md +350 -0
  34. data/docs/ProjectControllerApi.md +196 -0
  35. data/docs/PubsubSubscriptionControllerApi.md +48 -0
  36. data/docs/ReorderPipelinesCommand.md +9 -0
  37. data/docs/ReorderPipelinesControllerApi.md +54 -0
  38. data/docs/ResponseEntity.md +10 -0
  39. data/docs/SearchControllerApi.md +68 -0
  40. data/docs/SecurityGroupControllerApi.md +171 -0
  41. data/docs/ServerGroupControllerApi.md +125 -0
  42. data/docs/ServerGroupManagerControllerApi.md +54 -0
  43. data/docs/SnapshotControllerApi.md +110 -0
  44. data/docs/SubnetControllerApi.md +58 -0
  45. data/docs/TaskControllerApi.md +291 -0
  46. data/docs/User.md +18 -0
  47. data/docs/V2CanaryConfigControllerApi.md +259 -0
  48. data/docs/V2CanaryControllerApi.md +356 -0
  49. data/docs/V2PipelineTemplatesControllerApi.md +356 -0
  50. data/docs/Version.md +8 -0
  51. data/docs/VersionControllerApi.md +48 -0
  52. data/docs/WebhookControllerApi.md +105 -0
  53. data/git_push.sh +55 -0
  54. data/lib/swagger_client.rb +85 -0
  55. data/lib/swagger_client/api/amazon_infrastructure_controller_api.rb +161 -0
  56. data/lib/swagger_client/api/application_controller_api.rb +868 -0
  57. data/lib/swagger_client/api/artifact_controller_api.rb +141 -0
  58. data/lib/swagger_client/api/auth_controller_api.rb +258 -0
  59. data/lib/swagger_client/api/bake_controller_api.rb +179 -0
  60. data/lib/swagger_client/api/build_controller_api.rb +588 -0
  61. data/lib/swagger_client/api/cluster_controller_api.rb +591 -0
  62. data/lib/swagger_client/api/concourse_controller_api.rb +209 -0
  63. data/lib/swagger_client/api/credentials_controller_api.rb +163 -0
  64. data/lib/swagger_client/api/ecs_server_group_events_controller_api.rb +101 -0
  65. data/lib/swagger_client/api/executions_controller_api.rb +169 -0
  66. data/lib/swagger_client/api/firewall_controller_api.rb +209 -0
  67. data/lib/swagger_client/api/image_controller_api.rb +222 -0
  68. data/lib/swagger_client/api/instance_controller_api.rb +160 -0
  69. data/lib/swagger_client/api/job_controller_api.rb +99 -0
  70. data/lib/swagger_client/api/load_balancer_controller_api.rb +258 -0
  71. data/lib/swagger_client/api/network_controller_api.rb +127 -0
  72. data/lib/swagger_client/api/pipeline_config_controller_api.rb +176 -0
  73. data/lib/swagger_client/api/pipeline_controller_api.rb +1268 -0
  74. data/lib/swagger_client/api/pipeline_templates_controller_api.rb +404 -0
  75. data/lib/swagger_client/api/project_controller_api.rb +234 -0
  76. data/lib/swagger_client/api/pubsub_subscription_controller_api.rb +69 -0
  77. data/lib/swagger_client/api/reorder_pipelines_controller_api.rb +75 -0
  78. data/lib/swagger_client/api/search_controller_api.rb +94 -0
  79. data/lib/swagger_client/api/security_group_controller_api.rb +209 -0
  80. data/lib/swagger_client/api/server_group_controller_api.rb +163 -0
  81. data/lib/swagger_client/api/server_group_manager_controller_api.rb +75 -0
  82. data/lib/swagger_client/api/snapshot_controller_api.rb +142 -0
  83. data/lib/swagger_client/api/subnet_controller_api.rb +78 -0
  84. data/lib/swagger_client/api/task_controller_api.rb +345 -0
  85. data/lib/swagger_client/api/v2_canary_config_controller_api.rb +300 -0
  86. data/lib/swagger_client/api/v2_canary_controller_api.rb +421 -0
  87. data/lib/swagger_client/api/v2_pipeline_templates_controller_api.rb +412 -0
  88. data/lib/swagger_client/api/version_controller_api.rb +69 -0
  89. data/lib/swagger_client/api/webhook_controller_api.rb +135 -0
  90. data/lib/swagger_client/api_client.rb +388 -0
  91. data/lib/swagger_client/api_error.rb +38 -0
  92. data/lib/swagger_client/configuration.rb +202 -0
  93. data/lib/swagger_client/models/account.rb +241 -0
  94. data/lib/swagger_client/models/account_details.rb +286 -0
  95. data/lib/swagger_client/models/granted_authority.rb +183 -0
  96. data/lib/swagger_client/models/hash_mapstringobject.rb +174 -0
  97. data/lib/swagger_client/models/http_entity.rb +183 -0
  98. data/lib/swagger_client/models/mapstringstring.rb +174 -0
  99. data/lib/swagger_client/models/pipeline_template_dependent.rb +201 -0
  100. data/lib/swagger_client/models/reorder_pipelines_command.rb +194 -0
  101. data/lib/swagger_client/models/response_entity.rb +235 -0
  102. data/lib/swagger_client/models/user.rb +279 -0
  103. data/lib/swagger_client/models/version.rb +183 -0
  104. data/lib/swagger_client/version.rb +15 -0
  105. data/spec/api/amazon_infrastructure_controller_api_spec.rb +65 -0
  106. data/spec/api/application_controller_api_spec.rb +218 -0
  107. data/spec/api/artifact_controller_api_spec.rb +60 -0
  108. data/spec/api/auth_controller_api_spec.rb +86 -0
  109. data/spec/api/bake_controller_api_spec.rb +68 -0
  110. data/spec/api/build_controller_api_spec.rb +155 -0
  111. data/spec/api/cluster_controller_api_spec.rb +155 -0
  112. data/spec/api/concourse_controller_api_spec.rb +73 -0
  113. data/spec/api/credentials_controller_api_spec.rb +70 -0
  114. data/spec/api/ecs_server_group_events_controller_api_spec.rb +50 -0
  115. data/spec/api/executions_controller_api_spec.rb +72 -0
  116. data/spec/api/firewall_controller_api_spec.rb +77 -0
  117. data/spec/api/image_controller_api_spec.rb +80 -0
  118. data/spec/api/instance_controller_api_spec.rb +64 -0
  119. data/spec/api/job_controller_api_spec.rb +51 -0
  120. data/spec/api/load_balancer_controller_api_spec.rb +87 -0
  121. data/spec/api/network_controller_api_spec.rb +58 -0
  122. data/spec/api/pipeline_config_controller_api_spec.rb +68 -0
  123. data/spec/api/pipeline_controller_api_spec.rb +296 -0
  124. data/spec/api/pipeline_templates_controller_api_spec.rb +118 -0
  125. data/spec/api/project_controller_api_spec.rb +81 -0
  126. data/spec/api/pubsub_subscription_controller_api_spec.rb +45 -0
  127. data/spec/api/reorder_pipelines_controller_api_spec.rb +46 -0
  128. data/spec/api/search_controller_api_spec.rb +52 -0
  129. data/spec/api/security_group_controller_api_spec.rb +77 -0
  130. data/spec/api/server_group_controller_api_spec.rb +66 -0
  131. data/spec/api/server_group_manager_controller_api_spec.rb +46 -0
  132. data/spec/api/snapshot_controller_api_spec.rb +60 -0
  133. data/spec/api/subnet_controller_api_spec.rb +47 -0
  134. data/spec/api/task_controller_api_spec.rb +103 -0
  135. data/spec/api/v2_canary_config_controller_api_spec.rb +96 -0
  136. data/spec/api/v2_canary_controller_api_spec.rb +123 -0
  137. data/spec/api/v2_pipeline_templates_controller_api_spec.rb +121 -0
  138. data/spec/api/version_controller_api_spec.rb +45 -0
  139. data/spec/api/webhook_controller_api_spec.rb +60 -0
  140. data/spec/api_client_spec.rb +226 -0
  141. data/spec/configuration_spec.rb +42 -0
  142. data/spec/models/account_details_spec.rb +107 -0
  143. data/spec/models/account_spec.rb +77 -0
  144. data/spec/models/granted_authority_spec.rb +41 -0
  145. data/spec/models/hash_mapstringobject_spec.rb +35 -0
  146. data/spec/models/http_entity_spec.rb +41 -0
  147. data/spec/models/mapstringstring_spec.rb +35 -0
  148. data/spec/models/pipeline_template_dependent_spec.rb +53 -0
  149. data/spec/models/reorder_pipelines_command_spec.rb +47 -0
  150. data/spec/models/response_entity_spec.rb +57 -0
  151. data/spec/models/user_spec.rb +101 -0
  152. data/spec/models/version_spec.rb +41 -0
  153. data/spec/spec_helper.rb +111 -0
  154. data/spinnaker_gate_ruby_client-1.0.0.gem +0 -0
  155. data/spinnaker_gate_ruby_client.gemspec +45 -0
  156. metadata +427 -0
@@ -0,0 +1,345 @@
1
+ =begin
2
+ #Spinnaker API
3
+
4
+ #No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
5
+
6
+ OpenAPI spec version: 1.0.0
7
+
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+ Swagger Codegen version: 2.4.7
10
+
11
+ =end
12
+
13
+ require 'uri'
14
+
15
+ module SwaggerClient
16
+ class TaskControllerApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+ # Cancel task
23
+ # @param id id
24
+ # @param [Hash] opts the optional parameters
25
+ # @return [Hash<String, Object>]
26
+ def cancel_task_using_put1(id, opts = {})
27
+ data, _status_code, _headers = cancel_task_using_put1_with_http_info(id, opts)
28
+ data
29
+ end
30
+
31
+ # Cancel task
32
+ # @param id id
33
+ # @param [Hash] opts the optional parameters
34
+ # @return [Array<(Hash<String, Object>, Fixnum, Hash)>] Hash<String, Object> data, response status code and response headers
35
+ def cancel_task_using_put1_with_http_info(id, opts = {})
36
+ if @api_client.config.debugging
37
+ @api_client.config.logger.debug 'Calling API: TaskControllerApi.cancel_task_using_put1 ...'
38
+ end
39
+ # verify the required parameter 'id' is set
40
+ if @api_client.config.client_side_validation && id.nil?
41
+ fail ArgumentError, "Missing the required parameter 'id' when calling TaskControllerApi.cancel_task_using_put1"
42
+ end
43
+ # resource path
44
+ local_var_path = '/tasks/{id}/cancel'.sub('{' + 'id' + '}', id.to_s)
45
+
46
+ # query parameters
47
+ query_params = {}
48
+
49
+ # header parameters
50
+ header_params = {}
51
+ # HTTP header 'Accept' (if needed)
52
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
53
+ # HTTP header 'Content-Type'
54
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
55
+
56
+ # form parameters
57
+ form_params = {}
58
+
59
+ # http body (model)
60
+ post_body = nil
61
+ auth_names = []
62
+ data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
63
+ :header_params => header_params,
64
+ :query_params => query_params,
65
+ :form_params => form_params,
66
+ :body => post_body,
67
+ :auth_names => auth_names,
68
+ :return_type => 'Hash<String, Object>')
69
+ if @api_client.config.debugging
70
+ @api_client.config.logger.debug "API called: TaskControllerApi#cancel_task_using_put1\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
71
+ end
72
+ return data, status_code, headers
73
+ end
74
+ # Cancel tasks
75
+ # @param ids ids
76
+ # @param [Hash] opts the optional parameters
77
+ # @return [Hash<String, Object>]
78
+ def cancel_tasks_using_put(ids, opts = {})
79
+ data, _status_code, _headers = cancel_tasks_using_put_with_http_info(ids, opts)
80
+ data
81
+ end
82
+
83
+ # Cancel tasks
84
+ # @param ids ids
85
+ # @param [Hash] opts the optional parameters
86
+ # @return [Array<(Hash<String, Object>, Fixnum, Hash)>] Hash<String, Object> data, response status code and response headers
87
+ def cancel_tasks_using_put_with_http_info(ids, opts = {})
88
+ if @api_client.config.debugging
89
+ @api_client.config.logger.debug 'Calling API: TaskControllerApi.cancel_tasks_using_put ...'
90
+ end
91
+ # verify the required parameter 'ids' is set
92
+ if @api_client.config.client_side_validation && ids.nil?
93
+ fail ArgumentError, "Missing the required parameter 'ids' when calling TaskControllerApi.cancel_tasks_using_put"
94
+ end
95
+ # resource path
96
+ local_var_path = '/tasks/cancel'
97
+
98
+ # query parameters
99
+ query_params = {}
100
+ query_params[:'ids'] = @api_client.build_collection_param(ids, :multi)
101
+
102
+ # header parameters
103
+ header_params = {}
104
+ # HTTP header 'Accept' (if needed)
105
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
106
+ # HTTP header 'Content-Type'
107
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
108
+
109
+ # form parameters
110
+ form_params = {}
111
+
112
+ # http body (model)
113
+ post_body = nil
114
+ auth_names = []
115
+ data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
116
+ :header_params => header_params,
117
+ :query_params => query_params,
118
+ :form_params => form_params,
119
+ :body => post_body,
120
+ :auth_names => auth_names,
121
+ :return_type => 'Hash<String, Object>')
122
+ if @api_client.config.debugging
123
+ @api_client.config.logger.debug "API called: TaskControllerApi#cancel_tasks_using_put\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
124
+ end
125
+ return data, status_code, headers
126
+ end
127
+ # Delete task
128
+ # @param id id
129
+ # @param [Hash] opts the optional parameters
130
+ # @return [Hash<String, Object>]
131
+ def delete_task_using_delete(id, opts = {})
132
+ data, _status_code, _headers = delete_task_using_delete_with_http_info(id, opts)
133
+ data
134
+ end
135
+
136
+ # Delete task
137
+ # @param id id
138
+ # @param [Hash] opts the optional parameters
139
+ # @return [Array<(Hash<String, Object>, Fixnum, Hash)>] Hash<String, Object> data, response status code and response headers
140
+ def delete_task_using_delete_with_http_info(id, opts = {})
141
+ if @api_client.config.debugging
142
+ @api_client.config.logger.debug 'Calling API: TaskControllerApi.delete_task_using_delete ...'
143
+ end
144
+ # verify the required parameter 'id' is set
145
+ if @api_client.config.client_side_validation && id.nil?
146
+ fail ArgumentError, "Missing the required parameter 'id' when calling TaskControllerApi.delete_task_using_delete"
147
+ end
148
+ # resource path
149
+ local_var_path = '/tasks/{id}'.sub('{' + 'id' + '}', id.to_s)
150
+
151
+ # query parameters
152
+ query_params = {}
153
+
154
+ # header parameters
155
+ header_params = {}
156
+ # HTTP header 'Accept' (if needed)
157
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
158
+ # HTTP header 'Content-Type'
159
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
160
+
161
+ # form parameters
162
+ form_params = {}
163
+
164
+ # http body (model)
165
+ post_body = nil
166
+ auth_names = []
167
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
168
+ :header_params => header_params,
169
+ :query_params => query_params,
170
+ :form_params => form_params,
171
+ :body => post_body,
172
+ :auth_names => auth_names,
173
+ :return_type => 'Hash<String, Object>')
174
+ if @api_client.config.debugging
175
+ @api_client.config.logger.debug "API called: TaskControllerApi#delete_task_using_delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
176
+ end
177
+ return data, status_code, headers
178
+ end
179
+ # Get task details
180
+ # @param id id
181
+ # @param task_details_id taskDetailsId
182
+ # @param [Hash] opts the optional parameters
183
+ # @option opts [String] :x_rate_limit_app X-RateLimit-App
184
+ # @return [Hash<String, Object>]
185
+ def get_task_details_using_get1(id, task_details_id, opts = {})
186
+ data, _status_code, _headers = get_task_details_using_get1_with_http_info(id, task_details_id, opts)
187
+ data
188
+ end
189
+
190
+ # Get task details
191
+ # @param id id
192
+ # @param task_details_id taskDetailsId
193
+ # @param [Hash] opts the optional parameters
194
+ # @option opts [String] :x_rate_limit_app X-RateLimit-App
195
+ # @return [Array<(Hash<String, Object>, Fixnum, Hash)>] Hash<String, Object> data, response status code and response headers
196
+ def get_task_details_using_get1_with_http_info(id, task_details_id, opts = {})
197
+ if @api_client.config.debugging
198
+ @api_client.config.logger.debug 'Calling API: TaskControllerApi.get_task_details_using_get1 ...'
199
+ end
200
+ # verify the required parameter 'id' is set
201
+ if @api_client.config.client_side_validation && id.nil?
202
+ fail ArgumentError, "Missing the required parameter 'id' when calling TaskControllerApi.get_task_details_using_get1"
203
+ end
204
+ # verify the required parameter 'task_details_id' is set
205
+ if @api_client.config.client_side_validation && task_details_id.nil?
206
+ fail ArgumentError, "Missing the required parameter 'task_details_id' when calling TaskControllerApi.get_task_details_using_get1"
207
+ end
208
+ # resource path
209
+ local_var_path = '/tasks/{id}/details/{taskDetailsId}'.sub('{' + 'id' + '}', id.to_s).sub('{' + 'taskDetailsId' + '}', task_details_id.to_s)
210
+
211
+ # query parameters
212
+ query_params = {}
213
+
214
+ # header parameters
215
+ header_params = {}
216
+ # HTTP header 'Accept' (if needed)
217
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
218
+ # HTTP header 'Content-Type'
219
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
220
+ header_params[:'X-RateLimit-App'] = opts[:'x_rate_limit_app'] if !opts[:'x_rate_limit_app'].nil?
221
+
222
+ # form parameters
223
+ form_params = {}
224
+
225
+ # http body (model)
226
+ post_body = nil
227
+ auth_names = []
228
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
229
+ :header_params => header_params,
230
+ :query_params => query_params,
231
+ :form_params => form_params,
232
+ :body => post_body,
233
+ :auth_names => auth_names,
234
+ :return_type => 'Hash<String, Object>')
235
+ if @api_client.config.debugging
236
+ @api_client.config.logger.debug "API called: TaskControllerApi#get_task_details_using_get1\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
237
+ end
238
+ return data, status_code, headers
239
+ end
240
+ # Get task
241
+ # @param id id
242
+ # @param [Hash] opts the optional parameters
243
+ # @return [Hash<String, Object>]
244
+ def get_task_using_get1(id, opts = {})
245
+ data, _status_code, _headers = get_task_using_get1_with_http_info(id, opts)
246
+ data
247
+ end
248
+
249
+ # Get task
250
+ # @param id id
251
+ # @param [Hash] opts the optional parameters
252
+ # @return [Array<(Hash<String, Object>, Fixnum, Hash)>] Hash<String, Object> data, response status code and response headers
253
+ def get_task_using_get1_with_http_info(id, opts = {})
254
+ if @api_client.config.debugging
255
+ @api_client.config.logger.debug 'Calling API: TaskControllerApi.get_task_using_get1 ...'
256
+ end
257
+ # verify the required parameter 'id' is set
258
+ if @api_client.config.client_side_validation && id.nil?
259
+ fail ArgumentError, "Missing the required parameter 'id' when calling TaskControllerApi.get_task_using_get1"
260
+ end
261
+ # resource path
262
+ local_var_path = '/tasks/{id}'.sub('{' + 'id' + '}', id.to_s)
263
+
264
+ # query parameters
265
+ query_params = {}
266
+
267
+ # header parameters
268
+ header_params = {}
269
+ # HTTP header 'Accept' (if needed)
270
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
271
+ # HTTP header 'Content-Type'
272
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
273
+
274
+ # form parameters
275
+ form_params = {}
276
+
277
+ # http body (model)
278
+ post_body = nil
279
+ auth_names = []
280
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
281
+ :header_params => header_params,
282
+ :query_params => query_params,
283
+ :form_params => form_params,
284
+ :body => post_body,
285
+ :auth_names => auth_names,
286
+ :return_type => 'Hash<String, Object>')
287
+ if @api_client.config.debugging
288
+ @api_client.config.logger.debug "API called: TaskControllerApi#get_task_using_get1\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
289
+ end
290
+ return data, status_code, headers
291
+ end
292
+ # Create task
293
+ # @param map map
294
+ # @param [Hash] opts the optional parameters
295
+ # @return [Hash<String, Object>]
296
+ def task_using_post1(map, opts = {})
297
+ data, _status_code, _headers = task_using_post1_with_http_info(map, opts)
298
+ data
299
+ end
300
+
301
+ # Create task
302
+ # @param map map
303
+ # @param [Hash] opts the optional parameters
304
+ # @return [Array<(Hash<String, Object>, Fixnum, Hash)>] Hash<String, Object> data, response status code and response headers
305
+ def task_using_post1_with_http_info(map, opts = {})
306
+ if @api_client.config.debugging
307
+ @api_client.config.logger.debug 'Calling API: TaskControllerApi.task_using_post1 ...'
308
+ end
309
+ # verify the required parameter 'map' is set
310
+ if @api_client.config.client_side_validation && map.nil?
311
+ fail ArgumentError, "Missing the required parameter 'map' when calling TaskControllerApi.task_using_post1"
312
+ end
313
+ # resource path
314
+ local_var_path = '/tasks'
315
+
316
+ # query parameters
317
+ query_params = {}
318
+
319
+ # header parameters
320
+ header_params = {}
321
+ # HTTP header 'Accept' (if needed)
322
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
323
+ # HTTP header 'Content-Type'
324
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
325
+
326
+ # form parameters
327
+ form_params = {}
328
+
329
+ # http body (model)
330
+ post_body = @api_client.object_to_http_body(map)
331
+ auth_names = []
332
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
333
+ :header_params => header_params,
334
+ :query_params => query_params,
335
+ :form_params => form_params,
336
+ :body => post_body,
337
+ :auth_names => auth_names,
338
+ :return_type => 'Hash<String, Object>')
339
+ if @api_client.config.debugging
340
+ @api_client.config.logger.debug "API called: TaskControllerApi#task_using_post1\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
341
+ end
342
+ return data, status_code, headers
343
+ end
344
+ end
345
+ end
@@ -0,0 +1,300 @@
1
+ =begin
2
+ #Spinnaker API
3
+
4
+ #No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
5
+
6
+ OpenAPI spec version: 1.0.0
7
+
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+ Swagger Codegen version: 2.4.7
10
+
11
+ =end
12
+
13
+ require 'uri'
14
+
15
+ module SwaggerClient
16
+ class V2CanaryConfigControllerApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+ # Create a canary configuration
23
+ # @param config config
24
+ # @param [Hash] opts the optional parameters
25
+ # @option opts [String] :configuration_account_name configurationAccountName
26
+ # @return [Object]
27
+ def create_canary_config_using_post(config, opts = {})
28
+ data, _status_code, _headers = create_canary_config_using_post_with_http_info(config, opts)
29
+ data
30
+ end
31
+
32
+ # Create a canary configuration
33
+ # @param config config
34
+ # @param [Hash] opts the optional parameters
35
+ # @option opts [String] :configuration_account_name configurationAccountName
36
+ # @return [Array<(Object, Fixnum, Hash)>] Object data, response status code and response headers
37
+ def create_canary_config_using_post_with_http_info(config, opts = {})
38
+ if @api_client.config.debugging
39
+ @api_client.config.logger.debug 'Calling API: V2CanaryConfigControllerApi.create_canary_config_using_post ...'
40
+ end
41
+ # verify the required parameter 'config' is set
42
+ if @api_client.config.client_side_validation && config.nil?
43
+ fail ArgumentError, "Missing the required parameter 'config' when calling V2CanaryConfigControllerApi.create_canary_config_using_post"
44
+ end
45
+ # resource path
46
+ local_var_path = '/v2/canaryConfig'
47
+
48
+ # query parameters
49
+ query_params = {}
50
+ query_params[:'configurationAccountName'] = opts[:'configuration_account_name'] if !opts[:'configuration_account_name'].nil?
51
+
52
+ # header parameters
53
+ header_params = {}
54
+ # HTTP header 'Accept' (if needed)
55
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
56
+ # HTTP header 'Content-Type'
57
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
58
+
59
+ # form parameters
60
+ form_params = {}
61
+
62
+ # http body (model)
63
+ post_body = @api_client.object_to_http_body(config)
64
+ auth_names = []
65
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
66
+ :header_params => header_params,
67
+ :query_params => query_params,
68
+ :form_params => form_params,
69
+ :body => post_body,
70
+ :auth_names => auth_names,
71
+ :return_type => 'Object')
72
+ if @api_client.config.debugging
73
+ @api_client.config.logger.debug "API called: V2CanaryConfigControllerApi#create_canary_config_using_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
74
+ end
75
+ return data, status_code, headers
76
+ end
77
+ # Delete a canary configuration
78
+ # @param id id
79
+ # @param [Hash] opts the optional parameters
80
+ # @option opts [String] :configuration_account_name configurationAccountName
81
+ # @return [nil]
82
+ def delete_canary_config_using_delete(id, opts = {})
83
+ delete_canary_config_using_delete_with_http_info(id, opts)
84
+ nil
85
+ end
86
+
87
+ # Delete a canary configuration
88
+ # @param id id
89
+ # @param [Hash] opts the optional parameters
90
+ # @option opts [String] :configuration_account_name configurationAccountName
91
+ # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
92
+ def delete_canary_config_using_delete_with_http_info(id, opts = {})
93
+ if @api_client.config.debugging
94
+ @api_client.config.logger.debug 'Calling API: V2CanaryConfigControllerApi.delete_canary_config_using_delete ...'
95
+ end
96
+ # verify the required parameter 'id' is set
97
+ if @api_client.config.client_side_validation && id.nil?
98
+ fail ArgumentError, "Missing the required parameter 'id' when calling V2CanaryConfigControllerApi.delete_canary_config_using_delete"
99
+ end
100
+ # resource path
101
+ local_var_path = '/v2/canaryConfig/{id}'.sub('{' + 'id' + '}', id.to_s)
102
+
103
+ # query parameters
104
+ query_params = {}
105
+ query_params[:'configurationAccountName'] = opts[:'configuration_account_name'] if !opts[:'configuration_account_name'].nil?
106
+
107
+ # header parameters
108
+ header_params = {}
109
+ # HTTP header 'Accept' (if needed)
110
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
111
+ # HTTP header 'Content-Type'
112
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
113
+
114
+ # form parameters
115
+ form_params = {}
116
+
117
+ # http body (model)
118
+ post_body = nil
119
+ auth_names = []
120
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
121
+ :header_params => header_params,
122
+ :query_params => query_params,
123
+ :form_params => form_params,
124
+ :body => post_body,
125
+ :auth_names => auth_names)
126
+ if @api_client.config.debugging
127
+ @api_client.config.logger.debug "API called: V2CanaryConfigControllerApi#delete_canary_config_using_delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
128
+ end
129
+ return data, status_code, headers
130
+ end
131
+ # Retrieve a canary configuration by id
132
+ # @param id id
133
+ # @param [Hash] opts the optional parameters
134
+ # @option opts [String] :configuration_account_name configurationAccountName
135
+ # @return [Object]
136
+ def get_canary_config_using_get(id, opts = {})
137
+ data, _status_code, _headers = get_canary_config_using_get_with_http_info(id, opts)
138
+ data
139
+ end
140
+
141
+ # Retrieve a canary configuration by id
142
+ # @param id id
143
+ # @param [Hash] opts the optional parameters
144
+ # @option opts [String] :configuration_account_name configurationAccountName
145
+ # @return [Array<(Object, Fixnum, Hash)>] Object data, response status code and response headers
146
+ def get_canary_config_using_get_with_http_info(id, opts = {})
147
+ if @api_client.config.debugging
148
+ @api_client.config.logger.debug 'Calling API: V2CanaryConfigControllerApi.get_canary_config_using_get ...'
149
+ end
150
+ # verify the required parameter 'id' is set
151
+ if @api_client.config.client_side_validation && id.nil?
152
+ fail ArgumentError, "Missing the required parameter 'id' when calling V2CanaryConfigControllerApi.get_canary_config_using_get"
153
+ end
154
+ # resource path
155
+ local_var_path = '/v2/canaryConfig/{id}'.sub('{' + 'id' + '}', id.to_s)
156
+
157
+ # query parameters
158
+ query_params = {}
159
+ query_params[:'configurationAccountName'] = opts[:'configuration_account_name'] if !opts[:'configuration_account_name'].nil?
160
+
161
+ # header parameters
162
+ header_params = {}
163
+ # HTTP header 'Accept' (if needed)
164
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
165
+ # HTTP header 'Content-Type'
166
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
167
+
168
+ # form parameters
169
+ form_params = {}
170
+
171
+ # http body (model)
172
+ post_body = nil
173
+ auth_names = []
174
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
175
+ :header_params => header_params,
176
+ :query_params => query_params,
177
+ :form_params => form_params,
178
+ :body => post_body,
179
+ :auth_names => auth_names,
180
+ :return_type => 'Object')
181
+ if @api_client.config.debugging
182
+ @api_client.config.logger.debug "API called: V2CanaryConfigControllerApi#get_canary_config_using_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
183
+ end
184
+ return data, status_code, headers
185
+ end
186
+ # Retrieve a list of canary configurations
187
+ # @param [Hash] opts the optional parameters
188
+ # @option opts [String] :application application
189
+ # @option opts [String] :configuration_account_name configurationAccountName
190
+ # @return [Array<Object>]
191
+ def get_canary_configs_using_get(opts = {})
192
+ data, _status_code, _headers = get_canary_configs_using_get_with_http_info(opts)
193
+ data
194
+ end
195
+
196
+ # Retrieve a list of canary configurations
197
+ # @param [Hash] opts the optional parameters
198
+ # @option opts [String] :application application
199
+ # @option opts [String] :configuration_account_name configurationAccountName
200
+ # @return [Array<(Array<Object>, Fixnum, Hash)>] Array<Object> data, response status code and response headers
201
+ def get_canary_configs_using_get_with_http_info(opts = {})
202
+ if @api_client.config.debugging
203
+ @api_client.config.logger.debug 'Calling API: V2CanaryConfigControllerApi.get_canary_configs_using_get ...'
204
+ end
205
+ # resource path
206
+ local_var_path = '/v2/canaryConfig'
207
+
208
+ # query parameters
209
+ query_params = {}
210
+ query_params[:'application'] = opts[:'application'] if !opts[:'application'].nil?
211
+ query_params[:'configurationAccountName'] = opts[:'configuration_account_name'] if !opts[:'configuration_account_name'].nil?
212
+
213
+ # header parameters
214
+ header_params = {}
215
+ # HTTP header 'Accept' (if needed)
216
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
217
+ # HTTP header 'Content-Type'
218
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
219
+
220
+ # form parameters
221
+ form_params = {}
222
+
223
+ # http body (model)
224
+ post_body = nil
225
+ auth_names = []
226
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
227
+ :header_params => header_params,
228
+ :query_params => query_params,
229
+ :form_params => form_params,
230
+ :body => post_body,
231
+ :auth_names => auth_names,
232
+ :return_type => 'Array<Object>')
233
+ if @api_client.config.debugging
234
+ @api_client.config.logger.debug "API called: V2CanaryConfigControllerApi#get_canary_configs_using_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
235
+ end
236
+ return data, status_code, headers
237
+ end
238
+ # Update a canary configuration
239
+ # @param id id
240
+ # @param config config
241
+ # @param [Hash] opts the optional parameters
242
+ # @option opts [String] :configuration_account_name configurationAccountName
243
+ # @return [Object]
244
+ def update_canary_config_using_put(id, config, opts = {})
245
+ data, _status_code, _headers = update_canary_config_using_put_with_http_info(id, config, opts)
246
+ data
247
+ end
248
+
249
+ # Update a canary configuration
250
+ # @param id id
251
+ # @param config config
252
+ # @param [Hash] opts the optional parameters
253
+ # @option opts [String] :configuration_account_name configurationAccountName
254
+ # @return [Array<(Object, Fixnum, Hash)>] Object data, response status code and response headers
255
+ def update_canary_config_using_put_with_http_info(id, config, opts = {})
256
+ if @api_client.config.debugging
257
+ @api_client.config.logger.debug 'Calling API: V2CanaryConfigControllerApi.update_canary_config_using_put ...'
258
+ end
259
+ # verify the required parameter 'id' is set
260
+ if @api_client.config.client_side_validation && id.nil?
261
+ fail ArgumentError, "Missing the required parameter 'id' when calling V2CanaryConfigControllerApi.update_canary_config_using_put"
262
+ end
263
+ # verify the required parameter 'config' is set
264
+ if @api_client.config.client_side_validation && config.nil?
265
+ fail ArgumentError, "Missing the required parameter 'config' when calling V2CanaryConfigControllerApi.update_canary_config_using_put"
266
+ end
267
+ # resource path
268
+ local_var_path = '/v2/canaryConfig/{id}'.sub('{' + 'id' + '}', id.to_s)
269
+
270
+ # query parameters
271
+ query_params = {}
272
+ query_params[:'configurationAccountName'] = opts[:'configuration_account_name'] if !opts[:'configuration_account_name'].nil?
273
+
274
+ # header parameters
275
+ header_params = {}
276
+ # HTTP header 'Accept' (if needed)
277
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
278
+ # HTTP header 'Content-Type'
279
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
280
+
281
+ # form parameters
282
+ form_params = {}
283
+
284
+ # http body (model)
285
+ post_body = @api_client.object_to_http_body(config)
286
+ auth_names = []
287
+ data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
288
+ :header_params => header_params,
289
+ :query_params => query_params,
290
+ :form_params => form_params,
291
+ :body => post_body,
292
+ :auth_names => auth_names,
293
+ :return_type => 'Object')
294
+ if @api_client.config.debugging
295
+ @api_client.config.logger.debug "API called: V2CanaryConfigControllerApi#update_canary_config_using_put\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
296
+ end
297
+ return data, status_code, headers
298
+ end
299
+ end
300
+ end