Class: SwaggerClient::AdministrationApi
- Inherits:
-
Object
- Object
- SwaggerClient::AdministrationApi
- Defined in:
- lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/administration_api.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#activate_license(opts = {}) ⇒ Links
License Licenses the product with an activation key or a provided license file.
-
#activate_license_with_http_info(opts = {}) ⇒ Array<(Links, Integer, Hash)>
License Licenses the product with an activation key or a provided license file.
-
#execute_command(opts = {}) ⇒ ConsoleCommandOutput
Console Commands Executes a console command against the Security Console.
-
#execute_command_with_http_info(opts = {}) ⇒ Array<(ConsoleCommandOutput, Integer, Hash)>
Console Commands Executes a console command against the Security Console.
-
#get_info(opts = {}) ⇒ Info
Information Returns system details, including host and version information.
-
#get_info_with_http_info(opts = {}) ⇒ Array<(Info, Integer, Hash)>
Information Returns system details, including host and version information.
-
#get_license(opts = {}) ⇒ License
License Returns the enabled features and limits of the current license.
-
#get_license_with_http_info(opts = {}) ⇒ Array<(License, Integer, Hash)>
License Returns the enabled features and limits of the current license.
-
#get_properties(opts = {}) ⇒ EnvironmentProperties
Properties Returns system details, including host and version information.
-
#get_properties_with_http_info(opts = {}) ⇒ Array<(EnvironmentProperties, Integer, Hash)>
Properties Returns system details, including host and version information.
-
#get_settings(opts = {}) ⇒ Settings
Settings Returns the current administration settings.
-
#get_settings_with_http_info(opts = {}) ⇒ Array<(Settings, Integer, Hash)>
Settings Returns the current administration settings.
-
#initialize(api_client = ApiClient.default) ⇒ AdministrationApi
constructor
A new instance of AdministrationApi.
Constructor Details
#initialize(api_client = ApiClient.default) ⇒ AdministrationApi
Returns a new instance of AdministrationApi.
16 17 18 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/administration_api.rb', line 16 def initialize(api_client = ApiClient.default) @api_client = api_client end |
Instance Attribute Details
#api_client ⇒ Object
Returns the value of attribute api_client.
14 15 16 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/administration_api.rb', line 14 def api_client @api_client end |
Instance Method Details
#activate_license(opts = {}) ⇒ Links
License Licenses the product with an activation key or a provided license file. If both are provided, the license file is preferred. <span class="authorization">Global Administrator</span>
25 26 27 28 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/administration_api.rb', line 25 def activate_license(opts = {}) data, _status_code, _headers = activate_license_with_http_info(opts) data end |
#activate_license_with_http_info(opts = {}) ⇒ Array<(Links, Integer, Hash)>
License Licenses the product with an activation key or a provided license file. If both are provided, the license file is preferred. <span class="authorization">Global Administrator</span>
36 37 38 39 40 41 42 43 44 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 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/administration_api.rb', line 36 def activate_license_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: AdministrationApi.activate_license ...' end # resource path local_var_path = '/api/3/administration/license' # query parameters query_params = opts[:query_params] || {} query_params[:'key'] = opts[:'key'] if !opts[:'key'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json;charset=UTF-8']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data']) # form parameters form_params = opts[:form_params] || {} form_params['license'] = opts[:'license'] if !opts[:'license'].nil? # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'Links' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:POST, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: AdministrationApi#activate_license\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#execute_command(opts = {}) ⇒ ConsoleCommandOutput
Console Commands Executes a console command against the Security Console. <span class="authorization">Global Administrator</span>
82 83 84 85 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/administration_api.rb', line 82 def execute_command(opts = {}) data, _status_code, _headers = execute_command_with_http_info(opts) data end |
#execute_command_with_http_info(opts = {}) ⇒ Array<(ConsoleCommandOutput, Integer, Hash)>
Console Commands Executes a console command against the Security Console. <span class="authorization">Global Administrator</span>
92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/administration_api.rb', line 92 def execute_command_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: AdministrationApi.execute_command ...' end # resource path local_var_path = '/api/3/administration/commands' # 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;charset=UTF-8']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] || @api_client.object_to_http_body(opts[:'body']) return_type = opts[:return_type] || 'ConsoleCommandOutput' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:POST, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: AdministrationApi#execute_command\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_info(opts = {}) ⇒ Info
Information Returns system details, including host and version information.
135 136 137 138 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/administration_api.rb', line 135 def get_info(opts = {}) data, _status_code, _headers = get_info_with_http_info(opts) data end |
#get_info_with_http_info(opts = {}) ⇒ Array<(Info, Integer, Hash)>
Information Returns system details, including host and version information.
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 170 171 172 173 174 175 176 177 178 179 180 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/administration_api.rb', line 144 def get_info_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: AdministrationApi.get_info ...' end # resource path local_var_path = '/api/3/administration/info' # 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;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'Info' auth_names = opts[: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 => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: AdministrationApi#get_info\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_license(opts = {}) ⇒ License
License Returns the enabled features and limits of the current license. <span class="authorization">Global Administrator</span>
185 186 187 188 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/administration_api.rb', line 185 def get_license(opts = {}) data, _status_code, _headers = get_license_with_http_info(opts) data end |
#get_license_with_http_info(opts = {}) ⇒ Array<(License, Integer, Hash)>
License Returns the enabled features and limits of the current license. <span class="authorization">Global Administrator</span>
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 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/administration_api.rb', line 194 def get_license_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: AdministrationApi.get_license ...' end # resource path local_var_path = '/api/3/administration/license' # 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;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'License' auth_names = opts[: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 => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: AdministrationApi#get_license\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_properties(opts = {}) ⇒ EnvironmentProperties
Properties Returns system details, including host and version information.
235 236 237 238 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/administration_api.rb', line 235 def get_properties(opts = {}) data, _status_code, _headers = get_properties_with_http_info(opts) data end |
#get_properties_with_http_info(opts = {}) ⇒ Array<(EnvironmentProperties, Integer, Hash)>
Properties Returns system details, including host and version information.
244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/administration_api.rb', line 244 def get_properties_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: AdministrationApi.get_properties ...' end # resource path local_var_path = '/api/3/administration/properties' # 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;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'EnvironmentProperties' auth_names = opts[: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 => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: AdministrationApi#get_properties\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_settings(opts = {}) ⇒ Settings
Settings Returns the current administration settings. <span class="authorization">Global Administrator</span>
285 286 287 288 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/administration_api.rb', line 285 def get_settings(opts = {}) data, _status_code, _headers = get_settings_with_http_info(opts) data end |
#get_settings_with_http_info(opts = {}) ⇒ Array<(Settings, Integer, Hash)>
Settings Returns the current administration settings. <span class="authorization">Global Administrator</span>
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 322 323 324 325 326 327 328 329 330 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/administration_api.rb', line 294 def get_settings_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: AdministrationApi.get_settings ...' end # resource path local_var_path = '/api/3/administration/settings' # 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;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'Settings' auth_names = opts[: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 => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: AdministrationApi#get_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |