Class: SwaggerClient::ReportApi
- Inherits:
-
Object
- Object
- SwaggerClient::ReportApi
- Defined in:
- lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#create_report(opts = {}) ⇒ CreatedReferenceintLink
Reports Configures a new report for generation.
-
#create_report_with_http_info(opts = {}) ⇒ Array<(CreatedReferenceintLink, Integer, Hash)>
Reports Configures a new report for generation.
-
#delete_report(site_idte_id, opts = {}) ⇒ Links
Report Deletes the configuration of a report.
-
#delete_report_instance(site_idte_id, instance, opts = {}) ⇒ Links
Report History Deletes an instance of a generated report.
-
#delete_report_instance_with_http_info(site_idte_id, instance, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Report History Deletes an instance of a generated report.
-
#delete_report_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Report Deletes the configuration of a report.
-
#download_report(site_idte_id, instance, opts = {}) ⇒ String
Report Download Returns the contents of a generated report.
-
#download_report_with_http_info(site_idte_id, instance, opts = {}) ⇒ Array<(String, Integer, Hash)>
Report Download Returns the contents of a generated report.
-
#generate_report(site_idte_id, opts = {}) ⇒ ReferenceWithReportIDLink
Report Generation Generates a configured report and returns the instance identifier of the report.
-
#generate_report_with_http_info(site_idte_id, opts = {}) ⇒ Array<(ReferenceWithReportIDLink, Integer, Hash)>
Report Generation Generates a configured report and returns the instance identifier of the report.
-
#get_report(site_idte_id, opts = {}) ⇒ Report
Report Returns the configuration details of a report.
-
#get_report_formats(opts = {}) ⇒ ResourcesAvailableReportFormat
Report Formats Returns all available report formats.
-
#get_report_formats_with_http_info(opts = {}) ⇒ Array<(ResourcesAvailableReportFormat, Integer, Hash)>
Report Formats Returns all available report formats.
-
#get_report_instance(site_idte_id, instance, opts = {}) ⇒ ReportInstance
Report History Returns the details for a generation of the report.
-
#get_report_instance_with_http_info(site_idte_id, instance, opts = {}) ⇒ Array<(ReportInstance, Integer, Hash)>
Report History Returns the details for a generation of the report.
-
#get_report_instances(site_idte_id, opts = {}) ⇒ ResourcesReportInstance
Report Histories Returns all historical details for generation of the report over time.
-
#get_report_instances_with_http_info(site_idte_id, opts = {}) ⇒ Array<(ResourcesReportInstance, Integer, Hash)>
Report Histories Returns all historical details for generation of the report over time.
-
#get_report_template(site_idte_id, opts = {}) ⇒ ReportTemplate
Report Template Returns the details of a report template.
-
#get_report_template_with_http_info(site_idte_id, opts = {}) ⇒ Array<(ReportTemplate, Integer, Hash)>
Report Template Returns the details of a report template.
-
#get_report_templates(opts = {}) ⇒ ResourcesReportTemplate
Report Templates Returns all available report templates.
-
#get_report_templates_with_http_info(opts = {}) ⇒ Array<(ResourcesReportTemplate, Integer, Hash)>
Report Templates Returns all available report templates.
-
#get_report_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Report, Integer, Hash)>
Report Returns the configuration details of a report.
-
#get_reports(opts = {}) ⇒ PageOfReport
Reports Returns all defined report configurations.
-
#get_reports_with_http_info(opts = {}) ⇒ Array<(PageOfReport, Integer, Hash)>
Reports Returns all defined report configurations.
-
#initialize(api_client = ApiClient.default) ⇒ ReportApi
constructor
A new instance of ReportApi.
-
#update_report(site_idte_id, opts = {}) ⇒ Links
Report Updates the configuration details of a report.
-
#update_report_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Report Updates the configuration details of a report.
Constructor Details
#initialize(api_client = ApiClient.default) ⇒ ReportApi
Returns a new instance of ReportApi.
16 17 18 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_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/report_api.rb', line 14 def api_client @api_client end |
Instance Method Details
#create_report(opts = {}) ⇒ CreatedReferenceintLink
Reports Configures a new report for generation. Report types are controlled through either or both a format and template. Non-templatized (‘export`) report formats do not require a template and have their output format preset. Templatized (`document` and `file`) report formats support a report template that governs the content of the output and the output format can be chosen from a list of supported formats.
24 25 26 27 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 24 def create_report(opts = {}) data, _status_code, _headers = create_report_with_http_info(opts) data end |
#create_report_with_http_info(opts = {}) ⇒ Array<(CreatedReferenceintLink, Integer, Hash)>
Reports Configures a new report for generation. Report types are controlled through either or both a format and template. Non-templatized (`export`) report formats do not require a template and have their output format preset. Templatized (`document` and `file`) report formats support a report template that governs the content of the output and the output format can be chosen from a list of supported formats.
34 35 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 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 34 def create_report_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ReportApi.create_report ...' end # resource path local_var_path = '/api/3/reports' # 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] || 'CreatedReferenceintLink' 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: ReportApi#create_report\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#delete_report(site_idte_id, opts = {}) ⇒ Links
Report Deletes the configuration of a report.
78 79 80 81 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 78 def delete_report(site_idte_id, opts = {}) data, _status_code, _headers = delete_report_with_http_info(site_idte_id, opts) data end |
#delete_report_instance(site_idte_id, instance, opts = {}) ⇒ Links
Report History Deletes an instance of a generated report.
135 136 137 138 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 135 def delete_report_instance(site_idte_id, instance, opts = {}) data, _status_code, _headers = delete_report_instance_with_http_info(site_idte_id, instance, opts) data end |
#delete_report_instance_with_http_info(site_idte_id, instance, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Report History Deletes an instance of a generated report.
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 181 182 183 184 185 186 187 188 189 190 191 192 193 194 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 146 def delete_report_instance_with_http_info(site_idte_id, instance, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ReportApi.delete_report_instance ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling ReportApi.delete_report_instance" end # verify the required parameter 'instance' is set if @api_client.config.client_side_validation && instance.nil? fail ArgumentError, "Missing the required parameter 'instance' when calling ReportApi.delete_report_instance" end # verify enum value if @api_client.config.client_side_validation && !['latest', 'integer <<int32>>'].include?(instance) fail ArgumentError, "invalid value for 'instance', must be one of latest, integer <<int32>>" end # resource path local_var_path = '/api/3/reports/{id}/history/{instance}'.sub('{' + 'id' + '}', site_idte_id.to_s).sub('{' + 'instance' + '}', instance.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;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # 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(:DELETE, 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: ReportApi#delete_report_instance\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#delete_report_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Report Deletes the configuration of a report.
88 89 90 91 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 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 88 def delete_report_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ReportApi.delete_report ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling ReportApi.delete_report" end # resource path local_var_path = '/api/3/reports/{id}'.sub('{' + 'id' + '}', site_idte_id.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;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # 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(:DELETE, 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: ReportApi#delete_report\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#download_report(site_idte_id, instance, opts = {}) ⇒ String
Report Download Returns the contents of a generated report. The report content is usually returned in a GZip compressed format.
201 202 203 204 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 201 def download_report(site_idte_id, instance, opts = {}) data, _status_code, _headers = download_report_with_http_info(site_idte_id, instance, opts) data end |
#download_report_with_http_info(site_idte_id, instance, opts = {}) ⇒ Array<(String, Integer, Hash)>
Report Download Returns the contents of a generated report. The report content is usually returned in a GZip compressed format.
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 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 212 def download_report_with_http_info(site_idte_id, instance, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ReportApi.download_report ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling ReportApi.download_report" end # verify the required parameter 'instance' is set if @api_client.config.client_side_validation && instance.nil? fail ArgumentError, "Missing the required parameter 'instance' when calling ReportApi.download_report" end # verify enum value if @api_client.config.client_side_validation && !['latest', 'integer <<int32>>'].include?(instance) fail ArgumentError, "invalid value for 'instance', must be one of latest, integer <<int32>>" end # resource path local_var_path = '/api/3/reports/{id}/history/{instance}/output'.sub('{' + 'id' + '}', site_idte_id.to_s).sub('{' + 'instance' + '}', instance.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/octet-stream', 'application/json;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'String' 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: ReportApi#download_report\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#generate_report(site_idte_id, opts = {}) ⇒ ReferenceWithReportIDLink
Report Generation Generates a configured report and returns the instance identifier of the report.
266 267 268 269 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 266 def generate_report(site_idte_id, opts = {}) data, _status_code, _headers = generate_report_with_http_info(site_idte_id, opts) data end |
#generate_report_with_http_info(site_idte_id, opts = {}) ⇒ Array<(ReferenceWithReportIDLink, Integer, Hash)>
Report Generation Generates a configured report and returns the instance identifier of the report.
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 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 276 def generate_report_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ReportApi.generate_report ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling ReportApi.generate_report" end # resource path local_var_path = '/api/3/reports/{id}/generate'.sub('{' + 'id' + '}', site_idte_id.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;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'ReferenceWithReportIDLink' 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: ReportApi#generate_report\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_report(site_idte_id, opts = {}) ⇒ Report
Report Returns the configuration details of a report.
322 323 324 325 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 322 def get_report(site_idte_id, opts = {}) data, _status_code, _headers = get_report_with_http_info(site_idte_id, opts) data end |
#get_report_formats(opts = {}) ⇒ ResourcesAvailableReportFormat
Report Formats Returns all available report formats. A report format indicates an output file format specification (e.g. PDF, XML, etc). Some printable formats may be templated, and others may not. The supported templates for each formated are provided.
377 378 379 380 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 377 def get_report_formats(opts = {}) data, _status_code, _headers = get_report_formats_with_http_info(opts) data end |
#get_report_formats_with_http_info(opts = {}) ⇒ Array<(ResourcesAvailableReportFormat, Integer, Hash)>
Report Formats Returns all available report formats. A report format indicates an output file format specification (e.g. PDF, XML, etc). Some printable formats may be templated, and others may not. The supported templates for each formated are provided.
386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 386 def get_report_formats_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ReportApi.get_report_formats ...' end # resource path local_var_path = '/api/3/report_formats' # 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] || 'ResourcesAvailableReportFormat' 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: ReportApi#get_report_formats\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_report_instance(site_idte_id, instance, opts = {}) ⇒ ReportInstance
Report History Returns the details for a generation of the report.
429 430 431 432 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 429 def get_report_instance(site_idte_id, instance, opts = {}) data, _status_code, _headers = get_report_instance_with_http_info(site_idte_id, instance, opts) data end |
#get_report_instance_with_http_info(site_idte_id, instance, opts = {}) ⇒ Array<(ReportInstance, Integer, Hash)>
Report History Returns the details for a generation of the report.
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 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 440 def get_report_instance_with_http_info(site_idte_id, instance, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ReportApi.get_report_instance ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling ReportApi.get_report_instance" end # verify the required parameter 'instance' is set if @api_client.config.client_side_validation && instance.nil? fail ArgumentError, "Missing the required parameter 'instance' when calling ReportApi.get_report_instance" end # verify enum value if @api_client.config.client_side_validation && !['latest', 'integer <<int32>>'].include?(instance) fail ArgumentError, "invalid value for 'instance', must be one of latest, integer <<int32>>" end # resource path local_var_path = '/api/3/reports/{id}/history/{instance}'.sub('{' + 'id' + '}', site_idte_id.to_s).sub('{' + 'instance' + '}', instance.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;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'ReportInstance' 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: ReportApi#get_report_instance\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_report_instances(site_idte_id, opts = {}) ⇒ ResourcesReportInstance
Report Histories Returns all historical details for generation of the report over time.
494 495 496 497 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 494 def get_report_instances(site_idte_id, opts = {}) data, _status_code, _headers = get_report_instances_with_http_info(site_idte_id, opts) data end |
#get_report_instances_with_http_info(site_idte_id, opts = {}) ⇒ Array<(ResourcesReportInstance, Integer, Hash)>
Report Histories Returns all historical details for generation of the report over time.
504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 504 def get_report_instances_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ReportApi.get_report_instances ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling ReportApi.get_report_instances" end # resource path local_var_path = '/api/3/reports/{id}/history'.sub('{' + 'id' + '}', site_idte_id.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;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'ResourcesReportInstance' 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: ReportApi#get_report_instances\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_report_template(site_idte_id, opts = {}) ⇒ ReportTemplate
Report Template Returns the details of a report template. Report templates govern the contents generated within a report.
550 551 552 553 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 550 def get_report_template(site_idte_id, opts = {}) data, _status_code, _headers = get_report_template_with_http_info(site_idte_id, opts) data end |
#get_report_template_with_http_info(site_idte_id, opts = {}) ⇒ Array<(ReportTemplate, Integer, Hash)>
Report Template Returns the details of a report template. Report templates govern the contents generated within a report.
560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 560 def get_report_template_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ReportApi.get_report_template ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling ReportApi.get_report_template" end # resource path local_var_path = '/api/3/report_templates/{id}'.sub('{' + 'id' + '}', site_idte_id.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;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'ReportTemplate' 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: ReportApi#get_report_template\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_report_templates(opts = {}) ⇒ ResourcesReportTemplate
Report Templates Returns all available report templates.
605 606 607 608 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 605 def get_report_templates(opts = {}) data, _status_code, _headers = get_report_templates_with_http_info(opts) data end |
#get_report_templates_with_http_info(opts = {}) ⇒ Array<(ResourcesReportTemplate, Integer, Hash)>
Report Templates Returns all available report templates.
614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 614 def get_report_templates_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ReportApi.get_report_templates ...' end # resource path local_var_path = '/api/3/report_templates' # 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] || 'ResourcesReportTemplate' 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: ReportApi#get_report_templates\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_report_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Report, Integer, Hash)>
Report Returns the configuration details of a report.
332 333 334 335 336 337 338 339 340 341 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 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 332 def get_report_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ReportApi.get_report ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling ReportApi.get_report" end # resource path local_var_path = '/api/3/reports/{id}'.sub('{' + 'id' + '}', site_idte_id.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;charset=UTF-8']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'Report' 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: ReportApi#get_report\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_reports(opts = {}) ⇒ PageOfReport
Reports Returns all defined report configurations.
658 659 660 661 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 658 def get_reports(opts = {}) data, _status_code, _headers = get_reports_with_http_info(opts) data end |
#get_reports_with_http_info(opts = {}) ⇒ Array<(PageOfReport, Integer, Hash)>
Reports Returns all defined report configurations.
670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 670 def get_reports_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ReportApi.get_reports ...' end # resource path local_var_path = '/api/3/reports' # query parameters query_params = opts[:query_params] || {} query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil? query_params[:'size'] = opts[:'size'] if !opts[:'size'].nil? query_params[:'sort'] = @api_client.build_collection_param(opts[:'sort'], :multi) if !opts[:'sort'].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']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'PageOfReport' 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: ReportApi#get_reports\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#update_report(site_idte_id, opts = {}) ⇒ Links
Report Updates the configuration details of a report.
716 717 718 719 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 716 def update_report(site_idte_id, opts = {}) data, _status_code, _headers = update_report_with_http_info(site_idte_id, opts) data end |
#update_report_with_http_info(site_idte_id, opts = {}) ⇒ Array<(Links, Integer, Hash)>
Report Updates the configuration details of a report.
727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 |
# File 'lib/service/api/rapid7_insightvm_client/lib/swagger_client/api/report_api.rb', line 727 def update_report_with_http_info(site_idte_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: ReportApi.update_report ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && site_idte_id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling ReportApi.update_report" end # resource path local_var_path = '/api/3/reports/{id}'.sub('{' + 'id' + '}', site_idte_id.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;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] || 'Links' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:PUT, 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: ReportApi#update_report\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |