Create policy

Creates a policy (scan template).

Note: Policies are referred to as scan templates in the user interface. The term policy is only used by the API. The two terms refer to the same feature.

Requires the Standard [32] user role or the VM.VM_SCAN.VM_SCAN_USER_TEMPLATE.CREATE custom role privilege. See Roles.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Body Params
string
required

Specifies the unique identifier (UUID) of the Tenable-provided template the policy is based on. To get the available template UUIDs, use List templates with a type of policy. A policy cannot be moved to a different template after it is created.

settings
object
required

Specifies the scan settings to store in the policy. A policy stores the same settings as a scan configuration, apart from scan targets, and the settings a policy accepts depend on the template it is based on. For the meaning of a setting that is not listed here, see the request body of Create scan, or get the form definition for the template with Get template details.

plugins
object

Specifies the plugin families to enable or disable for the policy, keyed by plugin family name. Only templates that expose plugin selection, such as the Advanced Network Scan template, accept this property.

audits
object

Specifies the compliance audits to attach to the policy, grouped by the target the audit applies to. Required for a policy based on a compliance template, which cannot be created without at least one audit. For the structure, see the audits object in the request body of Create scan.

credentials
object

Specifies the credentials to attach to the policy, grouped by credential category and type. Required for a policy based on a credentialed template, such as Credentialed Patch Audit, which cannot be created without at least one credential. For the structure, see the credentials object in the request body of Create scan.

scap
object

Specifies the SCAP and OVAL content to attach to the policy. Required for a policy based on a SCAP template, which cannot be created without SCAP content.

Headers
string
enum
Defaults to application/json

Generated from available response content types

Allowed:
Responses

403

Returned if you do not have the required permissions to create a policy (scan template).

Language
Credentials
Header
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json
text/html