Class: Conductor::Http::Api::GatewayAuthResourceApi

Inherits:
Object
  • Object
show all
Defined in:
lib/conductor/http/api/gateway_auth_resource_api.rb

Overview

GatewayAuthResourceApi - API for gateway authentication config (Orkes)

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(api_client = nil) ⇒ GatewayAuthResourceApi

Returns a new instance of GatewayAuthResourceApi.



12
13
14
# File 'lib/conductor/http/api/gateway_auth_resource_api.rb', line 12

def initialize(api_client = nil)
  @api_client = api_client || ApiClient.new
end

Instance Attribute Details

#api_clientObject

Returns the value of attribute api_client.



10
11
12
# File 'lib/conductor/http/api/gateway_auth_resource_api.rb', line 10

def api_client
  @api_client
end

Instance Method Details

#create_config(body) ⇒ Object

Create gateway auth config



17
18
19
20
# File 'lib/conductor/http/api/gateway_auth_resource_api.rb', line 17

def create_config(body)
  @api_client.call_api('/gateway/config/auth', 'POST', body: body, return_type: 'String',
                                                       return_http_data_only: true)
end

#delete_config(id) ⇒ Object

Delete gateway auth config



41
42
43
44
# File 'lib/conductor/http/api/gateway_auth_resource_api.rb', line 41

def delete_config(id)
  @api_client.call_api('/gateway/config/auth/{id}', 'DELETE', path_params: { id: id },
                                                              return_http_data_only: true)
end

#get_config(id) ⇒ Object

Get gateway auth config by ID



23
24
25
26
# File 'lib/conductor/http/api/gateway_auth_resource_api.rb', line 23

def get_config(id)
  @api_client.call_api('/gateway/config/auth/{id}', 'GET', path_params: { id: id },
                                                           return_type: 'AuthenticationConfig', return_http_data_only: true)
end

#list_configsObject

List all gateway auth configs



29
30
31
32
# File 'lib/conductor/http/api/gateway_auth_resource_api.rb', line 29

def list_configs
  @api_client.call_api('/gateway/config/auth', 'GET', return_type: 'Array<AuthenticationConfig>',
                                                      return_http_data_only: true)
end

#update_config(id, body) ⇒ Object

Update gateway auth config



35
36
37
38
# File 'lib/conductor/http/api/gateway_auth_resource_api.rb', line 35

def update_config(id, body)
  @api_client.call_api('/gateway/config/auth/{id}', 'PUT', path_params: { id: id }, body: body,
                                                           return_http_data_only: true)
end