fn_ruby 0.1.29

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (65) hide show
  1. checksums.yaml +7 -0
  2. data/Gemfile +7 -0
  3. data/LICENSE +201 -0
  4. data/README.md +110 -0
  5. data/Rakefile +8 -0
  6. data/VERSION +1 -0
  7. data/docs/App.md +9 -0
  8. data/docs/AppWrapper.md +9 -0
  9. data/docs/AppsApi.md +244 -0
  10. data/docs/AppsWrapper.md +9 -0
  11. data/docs/Error.md +8 -0
  12. data/docs/ErrorBody.md +9 -0
  13. data/docs/NewTask.md +9 -0
  14. data/docs/Route.md +17 -0
  15. data/docs/RouteWrapper.md +10 -0
  16. data/docs/RoutesApi.md +262 -0
  17. data/docs/RoutesWrapper.md +9 -0
  18. data/docs/Task.md +18 -0
  19. data/docs/TaskWrapper.md +8 -0
  20. data/docs/TasksApi.md +50 -0
  21. data/docs/Version.md +8 -0
  22. data/docs/VersionApi.md +48 -0
  23. data/fn_ruby.gemspec +46 -0
  24. data/git_push.sh +55 -0
  25. data/lib/fn_ruby/api/apps_api.rb +297 -0
  26. data/lib/fn_ruby/api/routes_api.rb +327 -0
  27. data/lib/fn_ruby/api/tasks_api.rb +72 -0
  28. data/lib/fn_ruby/api/version_api.rb +72 -0
  29. data/lib/fn_ruby/api_client.rb +388 -0
  30. data/lib/fn_ruby/api_error.rb +38 -0
  31. data/lib/fn_ruby/configuration.rb +202 -0
  32. data/lib/fn_ruby/models/app.rb +201 -0
  33. data/lib/fn_ruby/models/app_wrapper.rb +202 -0
  34. data/lib/fn_ruby/models/apps_wrapper.rb +204 -0
  35. data/lib/fn_ruby/models/error.rb +188 -0
  36. data/lib/fn_ruby/models/error_body.rb +197 -0
  37. data/lib/fn_ruby/models/new_task.rb +204 -0
  38. data/lib/fn_ruby/models/route.rb +328 -0
  39. data/lib/fn_ruby/models/route_wrapper.rb +211 -0
  40. data/lib/fn_ruby/models/routes_wrapper.rb +204 -0
  41. data/lib/fn_ruby/models/task.rb +329 -0
  42. data/lib/fn_ruby/models/task_wrapper.rb +193 -0
  43. data/lib/fn_ruby/models/version.rb +188 -0
  44. data/lib/fn_ruby/version.rb +15 -0
  45. data/lib/fn_ruby.rb +55 -0
  46. data/spec/api/apps_api_spec.rb +95 -0
  47. data/spec/api/routes_api_spec.rb +100 -0
  48. data/spec/api/tasks_api_spec.rb +46 -0
  49. data/spec/api/version_api_spec.rb +46 -0
  50. data/spec/api_client_spec.rb +226 -0
  51. data/spec/configuration_spec.rb +42 -0
  52. data/spec/models/app_spec.rb +48 -0
  53. data/spec/models/app_wrapper_spec.rb +48 -0
  54. data/spec/models/apps_wrapper_spec.rb +48 -0
  55. data/spec/models/error_body_spec.rb +48 -0
  56. data/spec/models/error_spec.rb +42 -0
  57. data/spec/models/new_task_spec.rb +48 -0
  58. data/spec/models/route_spec.rb +104 -0
  59. data/spec/models/route_wrapper_spec.rb +54 -0
  60. data/spec/models/routes_wrapper_spec.rb +48 -0
  61. data/spec/models/task_spec.rb +106 -0
  62. data/spec/models/task_wrapper_spec.rb +42 -0
  63. data/spec/models/version_spec.rb +42 -0
  64. data/spec/spec_helper.rb +111 -0
  65. metadata +305 -0
@@ -0,0 +1,297 @@
1
+ =begin
2
+ #IronFunctions
3
+
4
+ #The open source serverless platform.
5
+
6
+ OpenAPI spec version: 0.1.29
7
+
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+ Swagger Codegen version: 2.2.3
10
+
11
+ =end
12
+
13
+ require "uri"
14
+
15
+ module OracleFunctions
16
+ class AppsApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+
23
+ # Delete an app.
24
+ # Delete an app.
25
+ # @param app Name of the app.
26
+ # @param [Hash] opts the optional parameters
27
+ # @return [nil]
28
+ def apps_app_delete(app, opts = {})
29
+ apps_app_delete_with_http_info(app, opts)
30
+ return nil
31
+ end
32
+
33
+ # Delete an app.
34
+ # Delete an app.
35
+ # @param app Name of the app.
36
+ # @param [Hash] opts the optional parameters
37
+ # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
38
+ def apps_app_delete_with_http_info(app, opts = {})
39
+ if @api_client.config.debugging
40
+ @api_client.config.logger.debug "Calling API: AppsApi.apps_app_delete ..."
41
+ end
42
+ # verify the required parameter 'app' is set
43
+ if @api_client.config.client_side_validation && app.nil?
44
+ fail ArgumentError, "Missing the required parameter 'app' when calling AppsApi.apps_app_delete"
45
+ end
46
+ # resource path
47
+ local_var_path = "/apps/{app}".sub('{' + 'app' + '}', app.to_s)
48
+
49
+ # query parameters
50
+ query_params = {}
51
+
52
+ # header parameters
53
+ header_params = {}
54
+ # HTTP header 'Accept' (if needed)
55
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
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 = nil
64
+ auth_names = []
65
+ data, status_code, headers = @api_client.call_api(:DELETE, 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
+ if @api_client.config.debugging
72
+ @api_client.config.logger.debug "API called: AppsApi#apps_app_delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
73
+ end
74
+ return data, status_code, headers
75
+ end
76
+
77
+ # Get information for a app.
78
+ # This gives more details about a app, such as statistics.
79
+ # @param app name of the app.
80
+ # @param [Hash] opts the optional parameters
81
+ # @return [AppWrapper]
82
+ def apps_app_get(app, opts = {})
83
+ data, _status_code, _headers = apps_app_get_with_http_info(app, opts)
84
+ return data
85
+ end
86
+
87
+ # Get information for a app.
88
+ # This gives more details about a app, such as statistics.
89
+ # @param app name of the app.
90
+ # @param [Hash] opts the optional parameters
91
+ # @return [Array<(AppWrapper, Fixnum, Hash)>] AppWrapper data, response status code and response headers
92
+ def apps_app_get_with_http_info(app, opts = {})
93
+ if @api_client.config.debugging
94
+ @api_client.config.logger.debug "Calling API: AppsApi.apps_app_get ..."
95
+ end
96
+ # verify the required parameter 'app' is set
97
+ if @api_client.config.client_side_validation && app.nil?
98
+ fail ArgumentError, "Missing the required parameter 'app' when calling AppsApi.apps_app_get"
99
+ end
100
+ # resource path
101
+ local_var_path = "/apps/{app}".sub('{' + 'app' + '}', app.to_s)
102
+
103
+ # query parameters
104
+ query_params = {}
105
+
106
+ # header parameters
107
+ header_params = {}
108
+ # HTTP header 'Accept' (if needed)
109
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
110
+ # HTTP header 'Content-Type'
111
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
112
+
113
+ # form parameters
114
+ form_params = {}
115
+
116
+ # http body (model)
117
+ post_body = nil
118
+ auth_names = []
119
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
120
+ :header_params => header_params,
121
+ :query_params => query_params,
122
+ :form_params => form_params,
123
+ :body => post_body,
124
+ :auth_names => auth_names,
125
+ :return_type => 'AppWrapper')
126
+ if @api_client.config.debugging
127
+ @api_client.config.logger.debug "API called: AppsApi#apps_app_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
128
+ end
129
+ return data, status_code, headers
130
+ end
131
+
132
+ # Updates an app.
133
+ # You can set app level settings here.
134
+ # @param app name of the app.
135
+ # @param body App to post.
136
+ # @param [Hash] opts the optional parameters
137
+ # @return [AppWrapper]
138
+ def apps_app_patch(app, body, opts = {})
139
+ data, _status_code, _headers = apps_app_patch_with_http_info(app, body, opts)
140
+ return data
141
+ end
142
+
143
+ # Updates an app.
144
+ # You can set app level settings here.
145
+ # @param app name of the app.
146
+ # @param body App to post.
147
+ # @param [Hash] opts the optional parameters
148
+ # @return [Array<(AppWrapper, Fixnum, Hash)>] AppWrapper data, response status code and response headers
149
+ def apps_app_patch_with_http_info(app, body, opts = {})
150
+ if @api_client.config.debugging
151
+ @api_client.config.logger.debug "Calling API: AppsApi.apps_app_patch ..."
152
+ end
153
+ # verify the required parameter 'app' is set
154
+ if @api_client.config.client_side_validation && app.nil?
155
+ fail ArgumentError, "Missing the required parameter 'app' when calling AppsApi.apps_app_patch"
156
+ end
157
+ # verify the required parameter 'body' is set
158
+ if @api_client.config.client_side_validation && body.nil?
159
+ fail ArgumentError, "Missing the required parameter 'body' when calling AppsApi.apps_app_patch"
160
+ end
161
+ # resource path
162
+ local_var_path = "/apps/{app}".sub('{' + 'app' + '}', app.to_s)
163
+
164
+ # query parameters
165
+ query_params = {}
166
+
167
+ # header parameters
168
+ header_params = {}
169
+ # HTTP header 'Accept' (if needed)
170
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
171
+ # HTTP header 'Content-Type'
172
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
173
+
174
+ # form parameters
175
+ form_params = {}
176
+
177
+ # http body (model)
178
+ post_body = @api_client.object_to_http_body(body)
179
+ auth_names = []
180
+ data, status_code, headers = @api_client.call_api(:PATCH, local_var_path,
181
+ :header_params => header_params,
182
+ :query_params => query_params,
183
+ :form_params => form_params,
184
+ :body => post_body,
185
+ :auth_names => auth_names,
186
+ :return_type => 'AppWrapper')
187
+ if @api_client.config.debugging
188
+ @api_client.config.logger.debug "API called: AppsApi#apps_app_patch\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
189
+ end
190
+ return data, status_code, headers
191
+ end
192
+
193
+ # Get all app names.
194
+ # Get a list of all the apps in the system.
195
+ # @param [Hash] opts the optional parameters
196
+ # @return [AppsWrapper]
197
+ def apps_get(opts = {})
198
+ data, _status_code, _headers = apps_get_with_http_info(opts)
199
+ return data
200
+ end
201
+
202
+ # Get all app names.
203
+ # Get a list of all the apps in the system.
204
+ # @param [Hash] opts the optional parameters
205
+ # @return [Array<(AppsWrapper, Fixnum, Hash)>] AppsWrapper data, response status code and response headers
206
+ def apps_get_with_http_info(opts = {})
207
+ if @api_client.config.debugging
208
+ @api_client.config.logger.debug "Calling API: AppsApi.apps_get ..."
209
+ end
210
+ # resource path
211
+ local_var_path = "/apps"
212
+
213
+ # query parameters
214
+ query_params = {}
215
+
216
+ # header parameters
217
+ header_params = {}
218
+ # HTTP header 'Accept' (if needed)
219
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
220
+ # HTTP header 'Content-Type'
221
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
222
+
223
+ # form parameters
224
+ form_params = {}
225
+
226
+ # http body (model)
227
+ post_body = nil
228
+ auth_names = []
229
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
230
+ :header_params => header_params,
231
+ :query_params => query_params,
232
+ :form_params => form_params,
233
+ :body => post_body,
234
+ :auth_names => auth_names,
235
+ :return_type => 'AppsWrapper')
236
+ if @api_client.config.debugging
237
+ @api_client.config.logger.debug "API called: AppsApi#apps_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
238
+ end
239
+ return data, status_code, headers
240
+ end
241
+
242
+ # Post new app
243
+ # Insert a new app
244
+ # @param body App to post.
245
+ # @param [Hash] opts the optional parameters
246
+ # @return [AppWrapper]
247
+ def apps_post(body, opts = {})
248
+ data, _status_code, _headers = apps_post_with_http_info(body, opts)
249
+ return data
250
+ end
251
+
252
+ # Post new app
253
+ # Insert a new app
254
+ # @param body App to post.
255
+ # @param [Hash] opts the optional parameters
256
+ # @return [Array<(AppWrapper, Fixnum, Hash)>] AppWrapper data, response status code and response headers
257
+ def apps_post_with_http_info(body, opts = {})
258
+ if @api_client.config.debugging
259
+ @api_client.config.logger.debug "Calling API: AppsApi.apps_post ..."
260
+ end
261
+ # verify the required parameter 'body' is set
262
+ if @api_client.config.client_side_validation && body.nil?
263
+ fail ArgumentError, "Missing the required parameter 'body' when calling AppsApi.apps_post"
264
+ end
265
+ # resource path
266
+ local_var_path = "/apps"
267
+
268
+ # query parameters
269
+ query_params = {}
270
+
271
+ # header parameters
272
+ header_params = {}
273
+ # HTTP header 'Accept' (if needed)
274
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
275
+ # HTTP header 'Content-Type'
276
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
277
+
278
+ # form parameters
279
+ form_params = {}
280
+
281
+ # http body (model)
282
+ post_body = @api_client.object_to_http_body(body)
283
+ auth_names = []
284
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
285
+ :header_params => header_params,
286
+ :query_params => query_params,
287
+ :form_params => form_params,
288
+ :body => post_body,
289
+ :auth_names => auth_names,
290
+ :return_type => 'AppWrapper')
291
+ if @api_client.config.debugging
292
+ @api_client.config.logger.debug "API called: AppsApi#apps_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
293
+ end
294
+ return data, status_code, headers
295
+ end
296
+ end
297
+ end
@@ -0,0 +1,327 @@
1
+ =begin
2
+ #IronFunctions
3
+
4
+ #The open source serverless platform.
5
+
6
+ OpenAPI spec version: 0.1.29
7
+
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+ Swagger Codegen version: 2.2.3
10
+
11
+ =end
12
+
13
+ require "uri"
14
+
15
+ module OracleFunctions
16
+ class RoutesApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+
23
+ # Get route list by app name.
24
+ # This will list routes for a particular app.
25
+ # @param app Name of app for this set of routes.
26
+ # @param [Hash] opts the optional parameters
27
+ # @return [RoutesWrapper]
28
+ def apps_app_routes_get(app, opts = {})
29
+ data, _status_code, _headers = apps_app_routes_get_with_http_info(app, opts)
30
+ return data
31
+ end
32
+
33
+ # Get route list by app name.
34
+ # This will list routes for a particular app.
35
+ # @param app Name of app for this set of routes.
36
+ # @param [Hash] opts the optional parameters
37
+ # @return [Array<(RoutesWrapper, Fixnum, Hash)>] RoutesWrapper data, response status code and response headers
38
+ def apps_app_routes_get_with_http_info(app, opts = {})
39
+ if @api_client.config.debugging
40
+ @api_client.config.logger.debug "Calling API: RoutesApi.apps_app_routes_get ..."
41
+ end
42
+ # verify the required parameter 'app' is set
43
+ if @api_client.config.client_side_validation && app.nil?
44
+ fail ArgumentError, "Missing the required parameter 'app' when calling RoutesApi.apps_app_routes_get"
45
+ end
46
+ # resource path
47
+ local_var_path = "/apps/{app}/routes".sub('{' + 'app' + '}', app.to_s)
48
+
49
+ # query parameters
50
+ query_params = {}
51
+
52
+ # header parameters
53
+ header_params = {}
54
+ # HTTP header 'Accept' (if needed)
55
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
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 = 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 => 'RoutesWrapper')
72
+ if @api_client.config.debugging
73
+ @api_client.config.logger.debug "API called: RoutesApi#apps_app_routes_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
74
+ end
75
+ return data, status_code, headers
76
+ end
77
+
78
+ # Create new Route
79
+ # Create a new route in an app, if app doesn't exists, it creates the app
80
+ # @param app name of the app.
81
+ # @param body One route to post.
82
+ # @param [Hash] opts the optional parameters
83
+ # @return [RouteWrapper]
84
+ def apps_app_routes_post(app, body, opts = {})
85
+ data, _status_code, _headers = apps_app_routes_post_with_http_info(app, body, opts)
86
+ return data
87
+ end
88
+
89
+ # Create new Route
90
+ # Create a new route in an app, if app doesn&#39;t exists, it creates the app
91
+ # @param app name of the app.
92
+ # @param body One route to post.
93
+ # @param [Hash] opts the optional parameters
94
+ # @return [Array<(RouteWrapper, Fixnum, Hash)>] RouteWrapper data, response status code and response headers
95
+ def apps_app_routes_post_with_http_info(app, body, opts = {})
96
+ if @api_client.config.debugging
97
+ @api_client.config.logger.debug "Calling API: RoutesApi.apps_app_routes_post ..."
98
+ end
99
+ # verify the required parameter 'app' is set
100
+ if @api_client.config.client_side_validation && app.nil?
101
+ fail ArgumentError, "Missing the required parameter 'app' when calling RoutesApi.apps_app_routes_post"
102
+ end
103
+ # verify the required parameter 'body' is set
104
+ if @api_client.config.client_side_validation && body.nil?
105
+ fail ArgumentError, "Missing the required parameter 'body' when calling RoutesApi.apps_app_routes_post"
106
+ end
107
+ # resource path
108
+ local_var_path = "/apps/{app}/routes".sub('{' + 'app' + '}', app.to_s)
109
+
110
+ # query parameters
111
+ query_params = {}
112
+
113
+ # header parameters
114
+ header_params = {}
115
+ # HTTP header 'Accept' (if needed)
116
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
117
+ # HTTP header 'Content-Type'
118
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
119
+
120
+ # form parameters
121
+ form_params = {}
122
+
123
+ # http body (model)
124
+ post_body = @api_client.object_to_http_body(body)
125
+ auth_names = []
126
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
127
+ :header_params => header_params,
128
+ :query_params => query_params,
129
+ :form_params => form_params,
130
+ :body => post_body,
131
+ :auth_names => auth_names,
132
+ :return_type => 'RouteWrapper')
133
+ if @api_client.config.debugging
134
+ @api_client.config.logger.debug "API called: RoutesApi#apps_app_routes_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
135
+ end
136
+ return data, status_code, headers
137
+ end
138
+
139
+ # Deletes the route
140
+ # Deletes the route.
141
+ # @param app Name of app for this set of routes.
142
+ # @param route Route name
143
+ # @param [Hash] opts the optional parameters
144
+ # @return [nil]
145
+ def apps_app_routes_route_delete(app, route, opts = {})
146
+ apps_app_routes_route_delete_with_http_info(app, route, opts)
147
+ return nil
148
+ end
149
+
150
+ # Deletes the route
151
+ # Deletes the route.
152
+ # @param app Name of app for this set of routes.
153
+ # @param route Route name
154
+ # @param [Hash] opts the optional parameters
155
+ # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
156
+ def apps_app_routes_route_delete_with_http_info(app, route, opts = {})
157
+ if @api_client.config.debugging
158
+ @api_client.config.logger.debug "Calling API: RoutesApi.apps_app_routes_route_delete ..."
159
+ end
160
+ # verify the required parameter 'app' is set
161
+ if @api_client.config.client_side_validation && app.nil?
162
+ fail ArgumentError, "Missing the required parameter 'app' when calling RoutesApi.apps_app_routes_route_delete"
163
+ end
164
+ # verify the required parameter 'route' is set
165
+ if @api_client.config.client_side_validation && route.nil?
166
+ fail ArgumentError, "Missing the required parameter 'route' when calling RoutesApi.apps_app_routes_route_delete"
167
+ end
168
+ # resource path
169
+ local_var_path = "/apps/{app}/routes/{route}".sub('{' + 'app' + '}', app.to_s).sub('{' + 'route' + '}', route.to_s)
170
+
171
+ # query parameters
172
+ query_params = {}
173
+
174
+ # header parameters
175
+ header_params = {}
176
+ # HTTP header 'Accept' (if needed)
177
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
178
+ # HTTP header 'Content-Type'
179
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
180
+
181
+ # form parameters
182
+ form_params = {}
183
+
184
+ # http body (model)
185
+ post_body = nil
186
+ auth_names = []
187
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
188
+ :header_params => header_params,
189
+ :query_params => query_params,
190
+ :form_params => form_params,
191
+ :body => post_body,
192
+ :auth_names => auth_names)
193
+ if @api_client.config.debugging
194
+ @api_client.config.logger.debug "API called: RoutesApi#apps_app_routes_route_delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
195
+ end
196
+ return data, status_code, headers
197
+ end
198
+
199
+ # Gets route by name
200
+ # Gets a route by name.
201
+ # @param app Name of app for this set of routes.
202
+ # @param route Route name
203
+ # @param [Hash] opts the optional parameters
204
+ # @return [RouteWrapper]
205
+ def apps_app_routes_route_get(app, route, opts = {})
206
+ data, _status_code, _headers = apps_app_routes_route_get_with_http_info(app, route, opts)
207
+ return data
208
+ end
209
+
210
+ # Gets route by name
211
+ # Gets a route by name.
212
+ # @param app Name of app for this set of routes.
213
+ # @param route Route name
214
+ # @param [Hash] opts the optional parameters
215
+ # @return [Array<(RouteWrapper, Fixnum, Hash)>] RouteWrapper data, response status code and response headers
216
+ def apps_app_routes_route_get_with_http_info(app, route, opts = {})
217
+ if @api_client.config.debugging
218
+ @api_client.config.logger.debug "Calling API: RoutesApi.apps_app_routes_route_get ..."
219
+ end
220
+ # verify the required parameter 'app' is set
221
+ if @api_client.config.client_side_validation && app.nil?
222
+ fail ArgumentError, "Missing the required parameter 'app' when calling RoutesApi.apps_app_routes_route_get"
223
+ end
224
+ # verify the required parameter 'route' is set
225
+ if @api_client.config.client_side_validation && route.nil?
226
+ fail ArgumentError, "Missing the required parameter 'route' when calling RoutesApi.apps_app_routes_route_get"
227
+ end
228
+ # resource path
229
+ local_var_path = "/apps/{app}/routes/{route}".sub('{' + 'app' + '}', app.to_s).sub('{' + 'route' + '}', route.to_s)
230
+
231
+ # query parameters
232
+ query_params = {}
233
+
234
+ # header parameters
235
+ header_params = {}
236
+ # HTTP header 'Accept' (if needed)
237
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
238
+ # HTTP header 'Content-Type'
239
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
240
+
241
+ # form parameters
242
+ form_params = {}
243
+
244
+ # http body (model)
245
+ post_body = nil
246
+ auth_names = []
247
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
248
+ :header_params => header_params,
249
+ :query_params => query_params,
250
+ :form_params => form_params,
251
+ :body => post_body,
252
+ :auth_names => auth_names,
253
+ :return_type => 'RouteWrapper')
254
+ if @api_client.config.debugging
255
+ @api_client.config.logger.debug "API called: RoutesApi#apps_app_routes_route_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
256
+ end
257
+ return data, status_code, headers
258
+ end
259
+
260
+ # Update a Route
261
+ # Update a route
262
+ # @param app name of the app.
263
+ # @param route route path.
264
+ # @param body One route to post.
265
+ # @param [Hash] opts the optional parameters
266
+ # @return [RouteWrapper]
267
+ def apps_app_routes_route_patch(app, route, body, opts = {})
268
+ data, _status_code, _headers = apps_app_routes_route_patch_with_http_info(app, route, body, opts)
269
+ return data
270
+ end
271
+
272
+ # Update a Route
273
+ # Update a route
274
+ # @param app name of the app.
275
+ # @param route route path.
276
+ # @param body One route to post.
277
+ # @param [Hash] opts the optional parameters
278
+ # @return [Array<(RouteWrapper, Fixnum, Hash)>] RouteWrapper data, response status code and response headers
279
+ def apps_app_routes_route_patch_with_http_info(app, route, body, opts = {})
280
+ if @api_client.config.debugging
281
+ @api_client.config.logger.debug "Calling API: RoutesApi.apps_app_routes_route_patch ..."
282
+ end
283
+ # verify the required parameter 'app' is set
284
+ if @api_client.config.client_side_validation && app.nil?
285
+ fail ArgumentError, "Missing the required parameter 'app' when calling RoutesApi.apps_app_routes_route_patch"
286
+ end
287
+ # verify the required parameter 'route' is set
288
+ if @api_client.config.client_side_validation && route.nil?
289
+ fail ArgumentError, "Missing the required parameter 'route' when calling RoutesApi.apps_app_routes_route_patch"
290
+ end
291
+ # verify the required parameter 'body' is set
292
+ if @api_client.config.client_side_validation && body.nil?
293
+ fail ArgumentError, "Missing the required parameter 'body' when calling RoutesApi.apps_app_routes_route_patch"
294
+ end
295
+ # resource path
296
+ local_var_path = "/apps/{app}/routes/{route}".sub('{' + 'app' + '}', app.to_s).sub('{' + 'route' + '}', route.to_s)
297
+
298
+ # query parameters
299
+ query_params = {}
300
+
301
+ # header parameters
302
+ header_params = {}
303
+ # HTTP header 'Accept' (if needed)
304
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
305
+ # HTTP header 'Content-Type'
306
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
307
+
308
+ # form parameters
309
+ form_params = {}
310
+
311
+ # http body (model)
312
+ post_body = @api_client.object_to_http_body(body)
313
+ auth_names = []
314
+ data, status_code, headers = @api_client.call_api(:PATCH, local_var_path,
315
+ :header_params => header_params,
316
+ :query_params => query_params,
317
+ :form_params => form_params,
318
+ :body => post_body,
319
+ :auth_names => auth_names,
320
+ :return_type => 'RouteWrapper')
321
+ if @api_client.config.debugging
322
+ @api_client.config.logger.debug "API called: RoutesApi#apps_app_routes_route_patch\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
323
+ end
324
+ return data, status_code, headers
325
+ end
326
+ end
327
+ end
@@ -0,0 +1,72 @@
1
+ =begin
2
+ #IronFunctions
3
+
4
+ #The open source serverless platform.
5
+
6
+ OpenAPI spec version: 0.1.29
7
+
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+ Swagger Codegen version: 2.2.3
10
+
11
+ =end
12
+
13
+ require "uri"
14
+
15
+ module OracleFunctions
16
+ class TasksApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+
23
+ # Get next task.
24
+ # Gets the next task in the queue, ready for processing. Consumers should start processing tasks in order. No other consumer can retrieve this task.
25
+ # @param [Hash] opts the optional parameters
26
+ # @return [TaskWrapper]
27
+ def tasks_get(opts = {})
28
+ data, _status_code, _headers = tasks_get_with_http_info(opts)
29
+ return data
30
+ end
31
+
32
+ # Get next task.
33
+ # Gets the next task in the queue, ready for processing. Consumers should start processing tasks in order. No other consumer can retrieve this task.
34
+ # @param [Hash] opts the optional parameters
35
+ # @return [Array<(TaskWrapper, Fixnum, Hash)>] TaskWrapper data, response status code and response headers
36
+ def tasks_get_with_http_info(opts = {})
37
+ if @api_client.config.debugging
38
+ @api_client.config.logger.debug "Calling API: TasksApi.tasks_get ..."
39
+ end
40
+ # resource path
41
+ local_var_path = "/tasks"
42
+
43
+ # query parameters
44
+ query_params = {}
45
+
46
+ # header parameters
47
+ header_params = {}
48
+ # HTTP header 'Accept' (if needed)
49
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
50
+ # HTTP header 'Content-Type'
51
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
52
+
53
+ # form parameters
54
+ form_params = {}
55
+
56
+ # http body (model)
57
+ post_body = nil
58
+ auth_names = []
59
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
60
+ :header_params => header_params,
61
+ :query_params => query_params,
62
+ :form_params => form_params,
63
+ :body => post_body,
64
+ :auth_names => auth_names,
65
+ :return_type => 'TaskWrapper')
66
+ if @api_client.config.debugging
67
+ @api_client.config.logger.debug "API called: TasksApi#tasks_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
68
+ end
69
+ return data, status_code, headers
70
+ end
71
+ end
72
+ end