Class: EmbedWorkflow::ActionsApi
- Inherits:
-
Object
- Object
- EmbedWorkflow::ActionsApi
- Defined in:
- lib/embed_workflow/api/actions_api.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#initialize(api_client = ApiClient.default) ⇒ ActionsApi
constructor
A new instance of ActionsApi.
-
#list_actions(**opts) ⇒ ListActions200Response
List actions.
-
#list_actions_with_http_info(opts = {}) ⇒ Array<(ListActions200Response, Integer, Hash)>
List actions.
-
#list_completed_actions(status:, **opts) ⇒ ListActions200Response
List completed actions.
-
#list_completed_actions_with_http_info(status, opts = {}) ⇒ Array<(ListActions200Response, Integer, Hash)>
List completed actions.
-
#list_failed_actions(status:, **opts) ⇒ ListActions200Response
List failed actions.
-
#list_failed_actions_with_http_info(status, opts = {}) ⇒ Array<(ListActions200Response, Integer, Hash)>
List failed actions.
-
#list_scheduled_actions(status:, **opts) ⇒ ListActions200Response
List scheduled actions.
-
#list_scheduled_actions_with_http_info(status, opts = {}) ⇒ Array<(ListActions200Response, Integer, Hash)>
List scheduled actions.
-
#list_workflow_actions(workflow_id:, **opts) ⇒ ListActions200Response
List workflow actions.
-
#list_workflow_actions_with_http_info(workflow_id, opts = {}) ⇒ Array<(ListActions200Response, Integer, Hash)>
List workflow actions.
-
#retry_action(hashid:, user_key:, hook_id:, **opts) ⇒ Object
Retry action.
-
#retry_action_with_http_info(hashid, opts = {}) ⇒ Array<(Object, Integer, Hash)>
Retry action.
Constructor Details
#initialize(api_client = ApiClient.default) ⇒ ActionsApi
Returns a new instance of ActionsApi.
19 20 21 |
# File 'lib/embed_workflow/api/actions_api.rb', line 19 def initialize(api_client = ApiClient.default) @api_client = api_client end |
Instance Attribute Details
#api_client ⇒ Object
Returns the value of attribute api_client.
17 18 19 |
# File 'lib/embed_workflow/api/actions_api.rb', line 17 def api_client @api_client end |
Instance Method Details
#list_actions(**opts) ⇒ ListActions200Response
List actions
31 32 33 34 |
# File 'lib/embed_workflow/api/actions_api.rb', line 31 def list_actions(**opts) data, _status_code, _headers = list_actions_with_http_info(opts) data end |
#list_actions_with_http_info(opts = {}) ⇒ Array<(ListActions200Response, Integer, Hash)>
List actions
45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 |
# File 'lib/embed_workflow/api/actions_api.rb', line 45 def list_actions_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ActionsApi.list_actions ...' end # resource path local_var_path = '/api/v1/actions' # query parameters query_params = opts[:query_params] || {} query_params[:'starting_after'] = opts[:'starting_after'] if !opts[:'starting_after'].nil? query_params[:'ending_before'] = opts[:'ending_before'] if !opts[:'ending_before'].nil? query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil? query_params[:'status'] = opts[:'status'] if !opts[:'status'].nil? query_params[:'execution_id'] = opts[:'execution_id'] if !opts[:'execution_id'].nil? query_params[:'workflow_id'] = opts[:'workflow_id'] if !opts[:'workflow_id'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'ListActions200Response' # auth_names auth_names = opts[:debug_auth_names] || ['bearer'] = opts.merge( :operation => :"ActionsApi.list_actions", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: ActionsApi#list_actions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_completed_actions(status:, **opts) ⇒ ListActions200Response
List completed actions
104 105 106 107 |
# File 'lib/embed_workflow/api/actions_api.rb', line 104 def list_completed_actions(status:, **opts) data, _status_code, _headers = list_completed_actions_with_http_info(status, opts) data end |
#list_completed_actions_with_http_info(status, opts = {}) ⇒ Array<(ListActions200Response, Integer, Hash)>
List completed actions
118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 |
# File 'lib/embed_workflow/api/actions_api.rb', line 118 def list_completed_actions_with_http_info(status, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ActionsApi.list_completed_actions ...' end # verify the required parameter 'status' is set if @api_client.config.client_side_validation && status.nil? fail ArgumentError, "Missing the required parameter 'status' when calling ActionsApi.list_completed_actions" end # resource path local_var_path = '/api/v1/actions/completed'.sub('{' + 'status' + '}', CGI.escape(status.to_s)) # query parameters query_params = opts[:query_params] || {} query_params[:'starting_after'] = opts[:'starting_after'] if !opts[:'starting_after'].nil? query_params[:'ending_before'] = opts[:'ending_before'] if !opts[:'ending_before'].nil? query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil? query_params[:'execution_id'] = opts[:'execution_id'] if !opts[:'execution_id'].nil? query_params[:'workflow_id'] = opts[:'workflow_id'] if !opts[:'workflow_id'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'ListActions200Response' # auth_names auth_names = opts[:debug_auth_names] || ['bearer'] = opts.merge( :operation => :"ActionsApi.list_completed_actions", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: ActionsApi#list_completed_actions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_failed_actions(status:, **opts) ⇒ ListActions200Response
List failed actions
180 181 182 183 |
# File 'lib/embed_workflow/api/actions_api.rb', line 180 def list_failed_actions(status:, **opts) data, _status_code, _headers = list_failed_actions_with_http_info(status, opts) data end |
#list_failed_actions_with_http_info(status, opts = {}) ⇒ Array<(ListActions200Response, Integer, Hash)>
List failed actions
194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 |
# File 'lib/embed_workflow/api/actions_api.rb', line 194 def list_failed_actions_with_http_info(status, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ActionsApi.list_failed_actions ...' end # verify the required parameter 'status' is set if @api_client.config.client_side_validation && status.nil? fail ArgumentError, "Missing the required parameter 'status' when calling ActionsApi.list_failed_actions" end # resource path local_var_path = '/api/v1/actions/failed'.sub('{' + 'status' + '}', CGI.escape(status.to_s)) # query parameters query_params = opts[:query_params] || {} query_params[:'starting_after'] = opts[:'starting_after'] if !opts[:'starting_after'].nil? query_params[:'ending_before'] = opts[:'ending_before'] if !opts[:'ending_before'].nil? query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil? query_params[:'execution_id'] = opts[:'execution_id'] if !opts[:'execution_id'].nil? query_params[:'workflow_id'] = opts[:'workflow_id'] if !opts[:'workflow_id'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'ListActions200Response' # auth_names auth_names = opts[:debug_auth_names] || ['bearer'] = opts.merge( :operation => :"ActionsApi.list_failed_actions", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: ActionsApi#list_failed_actions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_scheduled_actions(status:, **opts) ⇒ ListActions200Response
List scheduled actions
256 257 258 259 |
# File 'lib/embed_workflow/api/actions_api.rb', line 256 def list_scheduled_actions(status:, **opts) data, _status_code, _headers = list_scheduled_actions_with_http_info(status, opts) data end |
#list_scheduled_actions_with_http_info(status, opts = {}) ⇒ Array<(ListActions200Response, Integer, Hash)>
List scheduled actions
270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 |
# File 'lib/embed_workflow/api/actions_api.rb', line 270 def list_scheduled_actions_with_http_info(status, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ActionsApi.list_scheduled_actions ...' end # verify the required parameter 'status' is set if @api_client.config.client_side_validation && status.nil? fail ArgumentError, "Missing the required parameter 'status' when calling ActionsApi.list_scheduled_actions" end # resource path local_var_path = '/api/v1/actions/scheduled'.sub('{' + 'status' + '}', CGI.escape(status.to_s)) # query parameters query_params = opts[:query_params] || {} query_params[:'starting_after'] = opts[:'starting_after'] if !opts[:'starting_after'].nil? query_params[:'ending_before'] = opts[:'ending_before'] if !opts[:'ending_before'].nil? query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil? query_params[:'execution_id'] = opts[:'execution_id'] if !opts[:'execution_id'].nil? query_params[:'workflow_id'] = opts[:'workflow_id'] if !opts[:'workflow_id'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'ListActions200Response' # auth_names auth_names = opts[:debug_auth_names] || ['bearer'] = opts.merge( :operation => :"ActionsApi.list_scheduled_actions", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: ActionsApi#list_scheduled_actions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_workflow_actions(workflow_id:, **opts) ⇒ ListActions200Response
List workflow actions
330 331 332 333 |
# File 'lib/embed_workflow/api/actions_api.rb', line 330 def list_workflow_actions(workflow_id:, **opts) data, _status_code, _headers = list_workflow_actions_with_http_info(workflow_id, opts) data end |
#list_workflow_actions_with_http_info(workflow_id, opts = {}) ⇒ Array<(ListActions200Response, Integer, Hash)>
List workflow actions
342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 |
# File 'lib/embed_workflow/api/actions_api.rb', line 342 def list_workflow_actions_with_http_info(workflow_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ActionsApi.list_workflow_actions ...' end # verify the required parameter 'workflow_id' is set if @api_client.config.client_side_validation && workflow_id.nil? fail ArgumentError, "Missing the required parameter 'workflow_id' when calling ActionsApi.list_workflow_actions" end # resource path local_var_path = '/api/v1/workflows/{workflow_id}/actions'.sub('{' + 'workflow_id' + '}', CGI.escape(workflow_id.to_s)) # query parameters query_params = opts[:query_params] || {} query_params[:'starting_after'] = opts[:'starting_after'] if !opts[:'starting_after'].nil? query_params[:'ending_before'] = opts[:'ending_before'] if !opts[:'ending_before'].nil? query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'ListActions200Response' # auth_names auth_names = opts[:debug_auth_names] || ['bearer'] = opts.merge( :operation => :"ActionsApi.list_workflow_actions", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: ActionsApi#list_workflow_actions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#retry_action(hashid:, user_key:, hook_id:, **opts) ⇒ Object
Retry action
400 401 402 403 404 405 406 407 408 |
# File 'lib/embed_workflow/api/actions_api.rb', line 400 def retry_action(hashid:, user_key:, hook_id:, **opts) opts[:'retry_action_request'] = { user_key: user_key, hook_id: hook_id, **opts.reject { |k, _| k.to_s.start_with?('debug_') } } data, _status_code, _headers = retry_action_with_http_info(hashid, opts) data end |
#retry_action_with_http_info(hashid, opts = {}) ⇒ Array<(Object, Integer, Hash)>
Retry action
415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 |
# File 'lib/embed_workflow/api/actions_api.rb', line 415 def retry_action_with_http_info(hashid, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ActionsApi.retry_action ...' end # verify the required parameter 'hashid' is set if @api_client.config.client_side_validation && hashid.nil? fail ArgumentError, "Missing the required parameter 'hashid' when calling ActionsApi.retry_action" end # resource path local_var_path = '/api/v1/actions/{hashid}/retry'.sub('{' + 'hashid' + '}', CGI.escape(hashid.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # HTTP header 'Content-Type' content_type = @api_client.select_header_content_type(['application/json']) if !content_type.nil? header_params['Content-Type'] = content_type end # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:'retry_action_request']) # return_type return_type = opts[:debug_return_type] || 'Object' # auth_names auth_names = opts[:debug_auth_names] || ['bearer'] = opts.merge( :operation => :"ActionsApi.retry_action", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:POST, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: ActionsApi#retry_action\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |