Process Rule
Process a rule defined in the system.
GET https://instance.securid.com/aveksa/command.submit?cmd=processRule
info
The command expects a valid user token for a user that has Rule:Admin privileges. Use the Configure button to change the level of security enforced
Request
Parameters
processRule | |
format | properties - (Default) key=value . most useful when requesting a single object. If multiple objects are returned, values is a csv. ie key=value1,value2,value3 where value1 is the value for the first object, value2 is the value for the 2nd object, etc.json - Useful format for parsing into javascript or other languages. See www.json.org for details. |
rule | The optional name of a rule to specifically process. If this parameter is not specified, all active rules in the system will be evaluated. |
Headers
Bearer token | |
Accept | application/json |
Content-Type | application/json |
Response
Parameters
type | Executed command name |
run-id | The id assigned to the rule processing. |
run-source-xx | The names of the rules that we processed as part of this run where xx is the run id. |
Examples
Request
- Curl
- Python
- Node.js
curl -K -X GET \
"https://instance.securid.com/aveksa/command.submit?cmd=processRule&format=json&rule=myRule" \
-H "Authorization: Bearer <token>" \
-H "Content-Type: application/json"
import requests, json
url = "https://instance.securid.com/aveksa/command.submit"
params = {
"cmd": "processRule",
"format": "json",
"rule": "Attribute Synchronization"
}
headers = {
'Authorization': 'Bearer <token>',
'Content-Type': 'application/json'
}
response = requests.get(url, params=params, headers=headers)
if response.status_code == 200:
data = response.json()
print(data)
else:
print(f"Request failed with status code {response.status_code}")
const axios = require('axios');
const url = "https://instance.securid.com/aveksa/command.submit";
const params = {
"cmd": "processRule",
"format": "json",
"rule": "Attribute Synchronization"
};
const headers = {
'Authorization': 'Bearer <token>',
'Content-Type': 'application/json'
};
axios.get(url, { params, headers })
.then(response => {
if (response.status === 200) {
console.log(response.data);
} else {
console.log(`Request failed with status code ${response.status}`);
}
})
.catch(error => {
console.error('Error:', error);
});
Response
- 200
- 401
- 404
{
"data": {
"type": "processRule",
"run-id": "5497",
"run-source-5497": "Attribute Synchronization"
}
}
<html>
<head>
<title>Error</title>
</head>
<body>The token is not valid for the command 'processRule'. </body>
</html>
<html>
<head>
<title>Error</title>
</head>
<body>The rule Attribute Synch could not be found or it is not active
Query String=cmd=processRule&format=json&rule=Attribute%20Synch</body>
</html>