Skip to content

Latest commit

 

History

History
251 lines (173 loc) · 6.95 KB

ScanTemplateApi.md

File metadata and controls

251 lines (173 loc) · 6.95 KB

rapid7vmconsole.ScanTemplateApi

All URIs are relative to https://localhost:3780

Method HTTP request Description
create_scan_template POST /api/3/scan_templates Scan Templates
delete_scan_template DELETE /api/3/scan_templates/{id} Scan Template
get_scan_template GET /api/3/scan_templates/{id} Scan Template
get_scan_templates GET /api/3/scan_templates Scan Templates
update_scan_template PUT /api/3/scan_templates/{id} Scan Template

create_scan_template

CreatedReferenceScanTemplateIDLink create_scan_template(scan_template=scan_template)

Scan Templates

Creates a new scan template.

Example

from __future__ import print_function
import time
import rapid7vmconsole
from rapid7vmconsole.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = rapid7vmconsole.ScanTemplateApi()
scan_template = rapid7vmconsole.ScanTemplate() # ScanTemplate | The details of the scan template. (optional)

try:
    # Scan Templates
    api_response = api_instance.create_scan_template(scan_template=scan_template)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling ScanTemplateApi->create_scan_template: %s\n" % e)

Parameters

Name Type Description Notes
scan_template ScanTemplate The details of the scan template. [optional]

Return type

CreatedReferenceScanTemplateIDLink

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json;charset=UTF-8

[Back to top] [Back to API list] [Back to Model list] [Back to README]

delete_scan_template

Links delete_scan_template(id)

Scan Template

Deletes a scan template.

Example

from __future__ import print_function
import time
import rapid7vmconsole
from rapid7vmconsole.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = rapid7vmconsole.ScanTemplateApi()
id = 'id_example' # str | The identifier of the scan template

try:
    # Scan Template
    api_response = api_instance.delete_scan_template(id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling ScanTemplateApi->delete_scan_template: %s\n" % e)

Parameters

Name Type Description Notes
id str The identifier of the scan template

Return type

Links

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json;charset=UTF-8

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_scan_template

ScanTemplate get_scan_template(id)

Scan Template

Returns a scan template.

Example

from __future__ import print_function
import time
import rapid7vmconsole
from rapid7vmconsole.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = rapid7vmconsole.ScanTemplateApi()
id = 'id_example' # str | The identifier of the scan template

try:
    # Scan Template
    api_response = api_instance.get_scan_template(id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling ScanTemplateApi->get_scan_template: %s\n" % e)

Parameters

Name Type Description Notes
id str The identifier of the scan template

Return type

ScanTemplate

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json;charset=UTF-8

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_scan_templates

ResourcesScanTemplate get_scan_templates()

Scan Templates

Returns all scan templates.

Example

from __future__ import print_function
import time
import rapid7vmconsole
from rapid7vmconsole.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = rapid7vmconsole.ScanTemplateApi()

try:
    # Scan Templates
    api_response = api_instance.get_scan_templates()
    pprint(api_response)
except ApiException as e:
    print("Exception when calling ScanTemplateApi->get_scan_templates: %s\n" % e)

Parameters

This endpoint does not need any parameter.

Return type

ResourcesScanTemplate

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json;charset=UTF-8

[Back to top] [Back to API list] [Back to Model list] [Back to README]

update_scan_template

Links update_scan_template(id, scan_template=scan_template)

Scan Template

Updates a scan template.

Example

from __future__ import print_function
import time
import rapid7vmconsole
from rapid7vmconsole.rest import ApiException
from pprint import pprint

# create an instance of the API class
api_instance = rapid7vmconsole.ScanTemplateApi()
id = 'id_example' # str | The identifier of the scan template
scan_template = rapid7vmconsole.ScanTemplate() # ScanTemplate | The details of the scan template. (optional)

try:
    # Scan Template
    api_response = api_instance.update_scan_template(id, scan_template=scan_template)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling ScanTemplateApi->update_scan_template: %s\n" % e)

Parameters

Name Type Description Notes
id str The identifier of the scan template
scan_template ScanTemplate The details of the scan template. [optional]

Return type

Links

Authorization

No authorization required

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json;charset=UTF-8

[Back to top] [Back to API list] [Back to Model list] [Back to README]