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,163 @@
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 ServerGroupControllerApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+ # Retrieve a server group's details
23
+ # @param application_name applicationName
24
+ # @param account account
25
+ # @param region region
26
+ # @param server_group_name serverGroupName
27
+ # @param [Hash] opts the optional parameters
28
+ # @option opts [String] :x_rate_limit_app X-RateLimit-App
29
+ # @option opts [String] :include_details includeDetails (default to true)
30
+ # @return [Object]
31
+ def get_server_group_details_using_get(application_name, account, region, server_group_name, opts = {})
32
+ data, _status_code, _headers = get_server_group_details_using_get_with_http_info(application_name, account, region, server_group_name, opts)
33
+ data
34
+ end
35
+
36
+ # Retrieve a server group's details
37
+ # @param application_name applicationName
38
+ # @param account account
39
+ # @param region region
40
+ # @param server_group_name serverGroupName
41
+ # @param [Hash] opts the optional parameters
42
+ # @option opts [String] :x_rate_limit_app X-RateLimit-App
43
+ # @option opts [String] :include_details includeDetails
44
+ # @return [Array<(Object, Fixnum, Hash)>] Object data, response status code and response headers
45
+ def get_server_group_details_using_get_with_http_info(application_name, account, region, server_group_name, opts = {})
46
+ if @api_client.config.debugging
47
+ @api_client.config.logger.debug 'Calling API: ServerGroupControllerApi.get_server_group_details_using_get ...'
48
+ end
49
+ # verify the required parameter 'application_name' is set
50
+ if @api_client.config.client_side_validation && application_name.nil?
51
+ fail ArgumentError, "Missing the required parameter 'application_name' when calling ServerGroupControllerApi.get_server_group_details_using_get"
52
+ end
53
+ # verify the required parameter 'account' is set
54
+ if @api_client.config.client_side_validation && account.nil?
55
+ fail ArgumentError, "Missing the required parameter 'account' when calling ServerGroupControllerApi.get_server_group_details_using_get"
56
+ end
57
+ # verify the required parameter 'region' is set
58
+ if @api_client.config.client_side_validation && region.nil?
59
+ fail ArgumentError, "Missing the required parameter 'region' when calling ServerGroupControllerApi.get_server_group_details_using_get"
60
+ end
61
+ # verify the required parameter 'server_group_name' is set
62
+ if @api_client.config.client_side_validation && server_group_name.nil?
63
+ fail ArgumentError, "Missing the required parameter 'server_group_name' when calling ServerGroupControllerApi.get_server_group_details_using_get"
64
+ end
65
+ # resource path
66
+ local_var_path = '/applications/{applicationName}/serverGroups/{account}/{region}/{serverGroupName}'.sub('{' + 'applicationName' + '}', application_name.to_s).sub('{' + 'account' + '}', account.to_s).sub('{' + 'region' + '}', region.to_s).sub('{' + 'serverGroupName' + '}', server_group_name.to_s)
67
+
68
+ # query parameters
69
+ query_params = {}
70
+ query_params[:'includeDetails'] = opts[:'include_details'] if !opts[:'include_details'].nil?
71
+
72
+ # header parameters
73
+ header_params = {}
74
+ # HTTP header 'Accept' (if needed)
75
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
76
+ # HTTP header 'Content-Type'
77
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
78
+ header_params[:'X-RateLimit-App'] = opts[:'x_rate_limit_app'] if !opts[:'x_rate_limit_app'].nil?
79
+
80
+ # form parameters
81
+ form_params = {}
82
+
83
+ # http body (model)
84
+ post_body = nil
85
+ auth_names = []
86
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
87
+ :header_params => header_params,
88
+ :query_params => query_params,
89
+ :form_params => form_params,
90
+ :body => post_body,
91
+ :auth_names => auth_names,
92
+ :return_type => 'Object')
93
+ if @api_client.config.debugging
94
+ @api_client.config.logger.debug "API called: ServerGroupControllerApi#get_server_group_details_using_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
95
+ end
96
+ return data, status_code, headers
97
+ end
98
+ # Retrieve a list of server groups for a given application
99
+ # @param application_name applicationName
100
+ # @param [Hash] opts the optional parameters
101
+ # @option opts [String] :expand expand (default to false)
102
+ # @option opts [String] :cloud_provider cloudProvider
103
+ # @option opts [String] :clusters clusters
104
+ # @option opts [String] :x_rate_limit_app X-RateLimit-App
105
+ # @return [Array<Object>]
106
+ def get_server_groups_for_application_using_get(application_name, opts = {})
107
+ data, _status_code, _headers = get_server_groups_for_application_using_get_with_http_info(application_name, opts)
108
+ data
109
+ end
110
+
111
+ # Retrieve a list of server groups for a given application
112
+ # @param application_name applicationName
113
+ # @param [Hash] opts the optional parameters
114
+ # @option opts [String] :expand expand
115
+ # @option opts [String] :cloud_provider cloudProvider
116
+ # @option opts [String] :clusters clusters
117
+ # @option opts [String] :x_rate_limit_app X-RateLimit-App
118
+ # @return [Array<(Array<Object>, Fixnum, Hash)>] Array<Object> data, response status code and response headers
119
+ def get_server_groups_for_application_using_get_with_http_info(application_name, opts = {})
120
+ if @api_client.config.debugging
121
+ @api_client.config.logger.debug 'Calling API: ServerGroupControllerApi.get_server_groups_for_application_using_get ...'
122
+ end
123
+ # verify the required parameter 'application_name' is set
124
+ if @api_client.config.client_side_validation && application_name.nil?
125
+ fail ArgumentError, "Missing the required parameter 'application_name' when calling ServerGroupControllerApi.get_server_groups_for_application_using_get"
126
+ end
127
+ # resource path
128
+ local_var_path = '/applications/{applicationName}/serverGroups'.sub('{' + 'applicationName' + '}', application_name.to_s)
129
+
130
+ # query parameters
131
+ query_params = {}
132
+ query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?
133
+ query_params[:'cloudProvider'] = opts[:'cloud_provider'] if !opts[:'cloud_provider'].nil?
134
+ query_params[:'clusters'] = opts[:'clusters'] if !opts[:'clusters'].nil?
135
+
136
+ # header parameters
137
+ header_params = {}
138
+ # HTTP header 'Accept' (if needed)
139
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
140
+ # HTTP header 'Content-Type'
141
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
142
+ header_params[:'X-RateLimit-App'] = opts[:'x_rate_limit_app'] if !opts[:'x_rate_limit_app'].nil?
143
+
144
+ # form parameters
145
+ form_params = {}
146
+
147
+ # http body (model)
148
+ post_body = nil
149
+ auth_names = []
150
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
151
+ :header_params => header_params,
152
+ :query_params => query_params,
153
+ :form_params => form_params,
154
+ :body => post_body,
155
+ :auth_names => auth_names,
156
+ :return_type => 'Array<Object>')
157
+ if @api_client.config.debugging
158
+ @api_client.config.logger.debug "API called: ServerGroupControllerApi#get_server_groups_for_application_using_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
159
+ end
160
+ return data, status_code, headers
161
+ end
162
+ end
163
+ end
@@ -0,0 +1,75 @@
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 ServerGroupManagerControllerApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+ # Retrieve a list of server group managers for an application
23
+ # @param application application
24
+ # @param [Hash] opts the optional parameters
25
+ # @return [Array<Object>]
26
+ def get_server_group_managers_for_application_using_get(application, opts = {})
27
+ data, _status_code, _headers = get_server_group_managers_for_application_using_get_with_http_info(application, opts)
28
+ data
29
+ end
30
+
31
+ # Retrieve a list of server group managers for an application
32
+ # @param application application
33
+ # @param [Hash] opts the optional parameters
34
+ # @return [Array<(Array<Object>, Fixnum, Hash)>] Array<Object> data, response status code and response headers
35
+ def get_server_group_managers_for_application_using_get_with_http_info(application, opts = {})
36
+ if @api_client.config.debugging
37
+ @api_client.config.logger.debug 'Calling API: ServerGroupManagerControllerApi.get_server_group_managers_for_application_using_get ...'
38
+ end
39
+ # verify the required parameter 'application' is set
40
+ if @api_client.config.client_side_validation && application.nil?
41
+ fail ArgumentError, "Missing the required parameter 'application' when calling ServerGroupManagerControllerApi.get_server_group_managers_for_application_using_get"
42
+ end
43
+ # resource path
44
+ local_var_path = '/applications/{application}/serverGroupManagers'.sub('{' + 'application' + '}', application.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(:GET, 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 => 'Array<Object>')
69
+ if @api_client.config.debugging
70
+ @api_client.config.logger.debug "API called: ServerGroupManagerControllerApi#get_server_group_managers_for_application_using_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
71
+ end
72
+ return data, status_code, headers
73
+ end
74
+ end
75
+ end
@@ -0,0 +1,142 @@
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 SnapshotControllerApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+ # Get current snapshot
23
+ # @param application application
24
+ # @param account account
25
+ # @param [Hash] opts the optional parameters
26
+ # @return [Hash<String, Object>]
27
+ def get_current_snapshot_using_get(application, account, opts = {})
28
+ data, _status_code, _headers = get_current_snapshot_using_get_with_http_info(application, account, opts)
29
+ data
30
+ end
31
+
32
+ # Get current snapshot
33
+ # @param application application
34
+ # @param account account
35
+ # @param [Hash] opts the optional parameters
36
+ # @return [Array<(Hash<String, Object>, Fixnum, Hash)>] Hash<String, Object> data, response status code and response headers
37
+ def get_current_snapshot_using_get_with_http_info(application, account, opts = {})
38
+ if @api_client.config.debugging
39
+ @api_client.config.logger.debug 'Calling API: SnapshotControllerApi.get_current_snapshot_using_get ...'
40
+ end
41
+ # verify the required parameter 'application' is set
42
+ if @api_client.config.client_side_validation && application.nil?
43
+ fail ArgumentError, "Missing the required parameter 'application' when calling SnapshotControllerApi.get_current_snapshot_using_get"
44
+ end
45
+ # verify the required parameter 'account' is set
46
+ if @api_client.config.client_side_validation && account.nil?
47
+ fail ArgumentError, "Missing the required parameter 'account' when calling SnapshotControllerApi.get_current_snapshot_using_get"
48
+ end
49
+ # resource path
50
+ local_var_path = '/applications/{application}/snapshots/{account}'.sub('{' + 'application' + '}', application.to_s).sub('{' + 'account' + '}', account.to_s)
51
+
52
+ # query parameters
53
+ query_params = {}
54
+
55
+ # header parameters
56
+ header_params = {}
57
+ # HTTP header 'Accept' (if needed)
58
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
59
+ # HTTP header 'Content-Type'
60
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
61
+
62
+ # form parameters
63
+ form_params = {}
64
+
65
+ # http body (model)
66
+ post_body = nil
67
+ auth_names = []
68
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
69
+ :header_params => header_params,
70
+ :query_params => query_params,
71
+ :form_params => form_params,
72
+ :body => post_body,
73
+ :auth_names => auth_names,
74
+ :return_type => 'Hash<String, Object>')
75
+ if @api_client.config.debugging
76
+ @api_client.config.logger.debug "API called: SnapshotControllerApi#get_current_snapshot_using_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
77
+ end
78
+ return data, status_code, headers
79
+ end
80
+ # Get snapshot history
81
+ # @param application application
82
+ # @param account account
83
+ # @param [Hash] opts the optional parameters
84
+ # @option opts [Integer] :limit limit (default to 20)
85
+ # @return [Array<Object>]
86
+ def get_snapshot_history_using_get(application, account, opts = {})
87
+ data, _status_code, _headers = get_snapshot_history_using_get_with_http_info(application, account, opts)
88
+ data
89
+ end
90
+
91
+ # Get snapshot history
92
+ # @param application application
93
+ # @param account account
94
+ # @param [Hash] opts the optional parameters
95
+ # @option opts [Integer] :limit limit
96
+ # @return [Array<(Array<Object>, Fixnum, Hash)>] Array<Object> data, response status code and response headers
97
+ def get_snapshot_history_using_get_with_http_info(application, account, opts = {})
98
+ if @api_client.config.debugging
99
+ @api_client.config.logger.debug 'Calling API: SnapshotControllerApi.get_snapshot_history_using_get ...'
100
+ end
101
+ # verify the required parameter 'application' is set
102
+ if @api_client.config.client_side_validation && application.nil?
103
+ fail ArgumentError, "Missing the required parameter 'application' when calling SnapshotControllerApi.get_snapshot_history_using_get"
104
+ end
105
+ # verify the required parameter 'account' is set
106
+ if @api_client.config.client_side_validation && account.nil?
107
+ fail ArgumentError, "Missing the required parameter 'account' when calling SnapshotControllerApi.get_snapshot_history_using_get"
108
+ end
109
+ # resource path
110
+ local_var_path = '/applications/{application}/snapshots/{account}/history'.sub('{' + 'application' + '}', application.to_s).sub('{' + 'account' + '}', account.to_s)
111
+
112
+ # query parameters
113
+ query_params = {}
114
+ query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
115
+
116
+ # header parameters
117
+ header_params = {}
118
+ # HTTP header 'Accept' (if needed)
119
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
120
+ # HTTP header 'Content-Type'
121
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
122
+
123
+ # form parameters
124
+ form_params = {}
125
+
126
+ # http body (model)
127
+ post_body = nil
128
+ auth_names = []
129
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
130
+ :header_params => header_params,
131
+ :query_params => query_params,
132
+ :form_params => form_params,
133
+ :body => post_body,
134
+ :auth_names => auth_names,
135
+ :return_type => 'Array<Object>')
136
+ if @api_client.config.debugging
137
+ @api_client.config.logger.debug "API called: SnapshotControllerApi#get_snapshot_history_using_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
138
+ end
139
+ return data, status_code, headers
140
+ end
141
+ end
142
+ end
@@ -0,0 +1,78 @@
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 SubnetControllerApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+ # Retrieve a list of subnets for a given cloud provider
23
+ # @param cloud_provider cloudProvider
24
+ # @param [Hash] opts the optional parameters
25
+ # @option opts [String] :x_rate_limit_app X-RateLimit-App
26
+ # @return [Array<Object>]
27
+ def all_by_cloud_provider_using_get1(cloud_provider, opts = {})
28
+ data, _status_code, _headers = all_by_cloud_provider_using_get1_with_http_info(cloud_provider, opts)
29
+ data
30
+ end
31
+
32
+ # Retrieve a list of subnets for a given cloud provider
33
+ # @param cloud_provider cloudProvider
34
+ # @param [Hash] opts the optional parameters
35
+ # @option opts [String] :x_rate_limit_app X-RateLimit-App
36
+ # @return [Array<(Array<Object>, Fixnum, Hash)>] Array<Object> data, response status code and response headers
37
+ def all_by_cloud_provider_using_get1_with_http_info(cloud_provider, opts = {})
38
+ if @api_client.config.debugging
39
+ @api_client.config.logger.debug 'Calling API: SubnetControllerApi.all_by_cloud_provider_using_get1 ...'
40
+ end
41
+ # verify the required parameter 'cloud_provider' is set
42
+ if @api_client.config.client_side_validation && cloud_provider.nil?
43
+ fail ArgumentError, "Missing the required parameter 'cloud_provider' when calling SubnetControllerApi.all_by_cloud_provider_using_get1"
44
+ end
45
+ # resource path
46
+ local_var_path = '/subnets/{cloudProvider}'.sub('{' + 'cloudProvider' + '}', cloud_provider.to_s)
47
+
48
+ # query parameters
49
+ query_params = {}
50
+
51
+ # header parameters
52
+ header_params = {}
53
+ # HTTP header 'Accept' (if needed)
54
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
55
+ # HTTP header 'Content-Type'
56
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
57
+ header_params[:'X-RateLimit-App'] = opts[:'x_rate_limit_app'] if !opts[:'x_rate_limit_app'].nil?
58
+
59
+ # form parameters
60
+ form_params = {}
61
+
62
+ # http body (model)
63
+ post_body = nil
64
+ auth_names = []
65
+ data, status_code, headers = @api_client.call_api(:GET, 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 => 'Array<Object>')
72
+ if @api_client.config.debugging
73
+ @api_client.config.logger.debug "API called: SubnetControllerApi#all_by_cloud_provider_using_get1\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
74
+ end
75
+ return data, status_code, headers
76
+ end
77
+ end
78
+ end