Previous Topic: PoliciesNext Topic: Example


createPolicy—Create a Policy

This action creates a policy.

This action has the following format:

comconf action=createPolicy
[name=policy_name]
pType=policy_type
[comment=comment]
[{configuration=identifier}]
name

Specifies the name of the policy to be created.

pType

Specifies the type of the policy to be created.

The following values are valid:

COMPUTER

Specifies a policy for computers and computer groups

IndividualComputer

Specifies a tailored computer settings

comment

Specifies a comment on or description of the policy

configuration

Specifies the UUID of a configuration the created policy will be assigned to.

If "configuration" is not coded then the policy is not assigned to any configuration.

This parameter is mandatory for policies of type "IndividualComputers".

In case of success the policy remains unsealed and the action presents the identifier of the created policy object at standard output in the following form:

Identifier:xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx