Step 2: Create a risk policy set
POST {{apiPath}}/environments/{{envID}}/riskPolicySets
A risk policy is determined by the customer's specific configuration settings as well as intelligence gathered from common use cases, which are then used in event evaluation to calculate risk scores for received events. You need the environment id
property value returned in Step 1 to specify the environment resource in the request URL to create the risk policy resource.
The POST /environments/{{envID}}/riskPolicySets/
creates a new risk policy set in the specified environment. In the request body, you must define at least one risk policy in the riskPolicies
property array, and the risk policy definition must specify a condition
expression and a result
. The priority
property in the risk policy definition is optional. In this scenario, you will define the whitelist and anonymous network detection policies.
Request Body
{"name"=>"Use_Case_Risk_Policy_Set", "description"=>"Custom risk policy set", "defaultResult"=>{"level"=>"Low"}, "riskPolicies"=>[{"name"=>"WHITELIST", "priority"=>1, "result"=>{"level"=>"LOW"}, "condition"=>{"contains"=>"${transaction.ip}", "ipRange"=>["1.1.1.1/16", "2.2.2.2/24"]}}, {"name"=>"ANONYMOUS_NETWORK_DETECTION", "result"=>{"level"=>"HIGH"}, "condition"=>{"value"=>"${details.anonymousNetworkDetected}", "equals"=>true}}]}
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
Authorization | string | ||
Content-Type | string |