Create an approval policy

POST
/approval_policies

Create a new approval policy.

Headers

Auth
AuthorizationstringRequired
Bearer authentication of the form Bearer <token>, where token is your auth token.
x-monite-versionstringRequired
x-monite-entity-idstringRequired

The ID of the entity that owns the requested resource.

Request

This endpoint expects an object.
namestringRequired

The name of the approval policy.

descriptionstringRequired

A brief description of the approval policy.

scriptlist of booleans or doubles or strings or lists of any or maps from strings to anyRequired

A list of JSON objects that represents the approval policy script. The script contains the logic that determines whether an action should be sent to approval. This field is required, and it should contain at least one script object.

start_datedatetimeOptional

The start datetime for the approval policy (will be converted to UTC).

end_datedatetimeOptional

The end datetime for the approval policy (will be converted to UTC).

triggerboolean or double or string or list of any or map from strings to anyOptional

A JSON object that represents the trigger for the approval policy. The trigger specifies the event that will trigger the policy to be evaluated.

Response

This endpoint returns an object.
namestring

The name of the approval policy.

descriptionstring

A brief description of the approval policy.

scriptlist of booleans or doubles or strings or lists of any or maps from strings to any

A list of JSON objects that represents the approval policy script. The script contains the logic that determines whether an action should be sent to approval. This field is required, and it should contain at least one script object.

idstring
status"active" or "pending"
Allowed values: activepending

The current status of the approval policy.

created_atdatetime
updated_atdatetime
created_bystring
start_datedatetimeOptional

The start datetime for the approval policy (will be converted to UTC).

end_datedatetimeOptional

The end datetime for the approval policy (will be converted to UTC).

triggerboolean or double or string or list of any or map from strings to anyOptional

A JSON object that represents the trigger for the approval policy. The trigger specifies the event that will trigger the policy to be evaluated.

updated_bystringOptional

Errors