class SwaggerClient::SecurityGroupControllerApi
Attributes
Public Class Methods
# File lib/swagger_client/api/security_group_controller_api.rb, line 19 def initialize(api_client = ApiClient.default) @api_client = api_client end
Public Instance Methods
Retrieve a list of security groups for a given account, grouped by region @param account account @param [Hash] opts the optional parameters @option opts [String] :provider provider (default to aws) @option opts [String] :region region @option opts [String] :x_rate_limit_app X-RateLimit-App @return [Object]
# File lib/swagger_client/api/security_group_controller_api.rb, line 29 def all_by_account_using_get1(account, opts = {}) data, _status_code, _headers = all_by_account_using_get1_with_http_info(account, opts) data end
Retrieve a list of security groups for a given account, grouped by region @param account account @param [Hash] opts the optional parameters @option opts [String] :provider provider @option opts [String] :region region @option opts [String] :x_rate_limit_app X-RateLimit-App @return [Array<(Object, Fixnum, Hash)>] Object data, response status code and response headers
# File lib/swagger_client/api/security_group_controller_api.rb, line 41 def all_by_account_using_get1_with_http_info(account, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: SecurityGroupControllerApi.all_by_account_using_get1 ...' end # verify the required parameter 'account' is set if @api_client.config.client_side_validation && account.nil? fail ArgumentError, "Missing the required parameter 'account' when calling SecurityGroupControllerApi.all_by_account_using_get1" end # resource path local_var_path = '/securityGroups/{account}'.sub('{' + 'account' + '}', account.to_s) # query parameters query_params = {} query_params[:'provider'] = opts[:'provider'] if !opts[:'provider'].nil? query_params[:'region'] = opts[:'region'] if !opts[:'region'].nil? # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) header_params[:'X-RateLimit-App'] = opts[:'x_rate_limit_app'] if !opts[:'x_rate_limit_app'].nil? # form parameters form_params = {} # http body (model) post_body = nil auth_names = [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'Object') if @api_client.config.debugging @api_client.config.logger.debug "API called: SecurityGroupControllerApi#all_by_account_using_get1\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Retrieve a list of security groups, grouped by account, cloud provider, and region @param [Hash] opts the optional parameters @option opts [String] :id id @option opts [String] :x_rate_limit_app X-RateLimit-App @return [Object]
# File lib/swagger_client/api/security_group_controller_api.rb, line 88 def all_using_get5(opts = {}) data, _status_code, _headers = all_using_get5_with_http_info(opts) data end
Retrieve a list of security groups, grouped by account, cloud provider, and region @param [Hash] opts the optional parameters @option opts [String] :id id @option opts [String] :x_rate_limit_app X-RateLimit-App @return [Array<(Object, Fixnum, Hash)>] Object data, response status code and response headers
# File lib/swagger_client/api/security_group_controller_api.rb, line 98 def all_using_get5_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: SecurityGroupControllerApi.all_using_get5 ...' end # resource path local_var_path = '/securityGroups' # query parameters query_params = {} query_params[:'id'] = opts[:'id'] if !opts[:'id'].nil? # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) header_params[:'X-RateLimit-App'] = opts[:'x_rate_limit_app'] if !opts[:'x_rate_limit_app'].nil? # form parameters form_params = {} # http body (model) post_body = nil auth_names = [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'Object') if @api_client.config.debugging @api_client.config.logger.debug "API called: SecurityGroupControllerApi#all_using_get5\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end
Retrieve a security group's details @param account account @param region region @param name name @param [Hash] opts the optional parameters @option opts [String] :provider provider (default to aws) @option opts [String] :vpc_id vpcId @option opts [String] :x_rate_limit_app X-RateLimit-App @return [Object]
# File lib/swagger_client/api/security_group_controller_api.rb, line 144 def get_security_group_using_get1(account, region, name, opts = {}) data, _status_code, _headers = get_security_group_using_get1_with_http_info(account, region, name, opts) data end
Retrieve a security group's details @param account account @param region region @param name name @param [Hash] opts the optional parameters @option opts [String] :provider provider @option opts [String] :vpc_id vpcId @option opts [String] :x_rate_limit_app X-RateLimit-App @return [Array<(Object, Fixnum, Hash)>] Object data, response status code and response headers
# File lib/swagger_client/api/security_group_controller_api.rb, line 158 def get_security_group_using_get1_with_http_info(account, region, name, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: SecurityGroupControllerApi.get_security_group_using_get1 ...' end # verify the required parameter 'account' is set if @api_client.config.client_side_validation && account.nil? fail ArgumentError, "Missing the required parameter 'account' when calling SecurityGroupControllerApi.get_security_group_using_get1" end # verify the required parameter 'region' is set if @api_client.config.client_side_validation && region.nil? fail ArgumentError, "Missing the required parameter 'region' when calling SecurityGroupControllerApi.get_security_group_using_get1" end # verify the required parameter 'name' is set if @api_client.config.client_side_validation && name.nil? fail ArgumentError, "Missing the required parameter 'name' when calling SecurityGroupControllerApi.get_security_group_using_get1" end # resource path local_var_path = '/securityGroups/{account}/{region}/{name}'.sub('{' + 'account' + '}', account.to_s).sub('{' + 'region' + '}', region.to_s).sub('{' + 'name' + '}', name.to_s) # query parameters query_params = {} query_params[:'provider'] = opts[:'provider'] if !opts[:'provider'].nil? query_params[:'vpcId'] = opts[:'vpc_id'] if !opts[:'vpc_id'].nil? # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['*/*']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) header_params[:'X-RateLimit-App'] = opts[:'x_rate_limit_app'] if !opts[:'x_rate_limit_app'].nil? # form parameters form_params = {} # http body (model) post_body = nil auth_names = [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'Object') if @api_client.config.debugging @api_client.config.logger.debug "API called: SecurityGroupControllerApi#get_security_group_using_get1\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end