Process rules

put

https://oaainstall-host/risk-analyzer/risk/v1/processrulessecurely

Runs rules for a given session (request) and checkpoint.

Request

There are no request parameters for this operation.

Supported Media Types
Request Body - application/xml ()
Root Schema : schema
Type: object
Process rule request object
Show Source
Nested Schema : checkpointList
Type: array
List of checkpoints to be executed. Currently, only one checkpoint per request is supported.
Show Source
Nested Schema : contextMap
Type: array
additional context for rule evaluation.
Show Source
Nested Schema : KeyValPair
Type: object
Key-value pair which can be used generically.
Show Source
Request Body - application/json ()
Root Schema : schema
Type: object
Process rule request object
Show Source
Nested Schema : checkpointList
Type: array
List of checkpoints to be executed. Currently, only one checkpoint per request is supported.
Show Source
Nested Schema : contextMap
Type: array
additional context for rule evaluation.
Show Source
Nested Schema : KeyValPair
Type: object
Key-value pair which can be used generically.
Show Source
Back to Top

Response

Supported Media Types

200 Response

Rules processed for the authentication context.
Body ()
Root Schema : ProcessRiskResponse
Type: object
Reponse object for processed rules
Show Source
Nested Schema : alertMessageList
Type: array
List of alerts as per the rules executed
Show Source
Nested Schema : allActions
Type: array
List of actions.
Show Source
Nested Schema : ProcessRiskApiResponse
Type: object
Rule api response for the process rule stating the request status
Show Source
Nested Schema : resultMap
Type: array
Use this to get result of each requested checkpoint. Since there is one checkpoint per rule evaluation request, this field is not used.
Show Source
Nested Schema : StatusResponse
Type: object
Status information for API call
Show Source
Nested Schema : KeyValPair
Type: object
Key-value pair which can be used generically.
Show Source
Nested Schema : SessionUserData
Type: object
user related data
Show Source

400 Response

Invalid input
Body ()
Root Schema : ProcessRiskApiResponse
Type: object
Rule api response for the process rule stating the request status
Show Source

401 Response

Unauthorized

500 Response

Internal server error

503 Response

Service Unavailable
Back to Top

Examples

The following example shows a sample request and response for processing rules for a given session (request) and checkpoint.

cURL Command to Process Rules in JSON Format

curl --location --request PUT '<RISK>/risk-analyzer/risk/v1/processrulessecurely' \
--header 'Content-Type: application/json' \
--header 'Authorization: Basic <Base64Encoded(<username>:<password>)>'  \
--data '{
    "requestId":"96eb744b-b84e-4c13-8b78-06b64ad81d94",
    "checkpointList": [
        1600
    ],
    "transactionId": 1,
    "contextMap": [
        {
            "key": "Dummy",
            "value": "Value"
        }
    ]
    }
}'

Sample Response in JSON Format

{
    "allActions": [
        "Block"
    ],
    "result": "Block",
    "score": 1000,
    "transactionLogId": 6,
    "resultMap": [],
    "alertMessageList": [
        "sessActionMapId=279;loginId=testuser;userId=testuser;deviceId=85;ip=10.175.171.219;lastTransactionId=6;msg=Purchased Item Exceeds Limit"
    ],
    "runtimeType": 1600,
    "deviceId": 85,
    "statusResponse": {
        "responseCode": "0",
        "responseMessage": "",
        "status": true
    }
}

cURL Command to Process Rules in XML Format

curl --location --request PUT '<RISK>/risk-analyzer/risk/v1/processrulessecurely' \
--header 'Content-Type: application/xml' \
--header 'Accept: application/xml' \
--header 'Authorization: Basic <Base64Encoded(<username>:<password>)>'  \
--data '
       <?xml version="1.0" encoding="UTF-8"?>
       <ProcessRiskRequest>
            <requestId>96eb744b-b84e-4c13-8b78-06b64ad81d94</requestId>
	     <checkpointList>1600</checkpointList>
	     <transactionId>1</transactionId>
	     <contextMap>
		<key>Dummy</key>
		<value>Value</value>
	     </contextMap>
        </ProcessRiskRequest>
'

Sample Response in XML Format

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ProcessRiskResponse>
	<allActions>Block</allActions>
	<result>Block</result>
	<score>1000</score>
	<transactionLogId>6</transactionLogId>
	<alertMessageList>sessActionMapId=279;loginId=testuser;userId=testuser;deviceId=85;ip=10.175.171.219;lastTransactionId=6;msg=Purchased Item Exceeds Limit</alertMessageList>
	<runtimeType>1600</runtimeType>
	<deviceId>85</deviceId>
	<statusResponse>
		<responseCode>0</responseCode>
		<responseMessage></responseMessage>
		<status>true</status>
	</statusResponse>
</ProcessRiskResponse>
Back to Top