When you create a policy, you specify the following:
- Conditions of the policy, including standard and custom conditions.
- A workflow of steps.
To create a policy:
- Navigate to Policies.
- Click Create a policy.
- Enter the policy details, as follows:
| Page | Details |
|---|---|
| General information | General details of the policy:
|
| Conditions | Conditions a proposed intent must fulfill for the policy to apply:
You can view the conditions in JSON format in the Preview tab. |
| Workflows | Details of the approval workflow to apply to the intent:
The submitter of the intent is always the first approver, so the role of the first step must correspond with the user role that can create the specified entities. |
| Summary | This page is for review and submission only. |
- Click Submit for approval and sign the operation with the app.
The new policy is created when the intent is successfully executed.
Custom conditions consist of two key-value pairs in JSON format: type and expression. The expression is written as a JavaScript expression.
When Ripple Custody tests the conditions after intent submission, if the expression evaluates to true, then the policy is eligible to apply to the current intent.
Creation of custom conditions is a technical task best performed by users with a good understanding of JSON and JavaScript.
For more information on how to write custom conditions, see Conditions in the API documentation.