Summary
autoSelectErrors Task
Description
Select and classify all the errors from compliance report
Route
POST /golden_config/autoSelectErrors
Roles
admin
engineering
support
Parameters
DetailsExampleSchema
Name |
Type |
Required |
Description |
complianceErrors |
object |
yes |
Array of compliance errors |
Copied to Clipboard
{
"complianceErrors": {
"errors": [
{
"query": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:version",
"condition": "cant",
"value": "opHI",
"severity": "error",
"comparison": "regex",
"ruleId": "918442ef-9808-c338-1b3d-83b0ae476c73",
"templateVariable": "zeLsoPlcr"
},
{
"query": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:version",
"condition": "cant",
"value": false,
"severity": "warning",
"comparison": "regex",
"ruleId": "ca85e850-1d52-f6cf-a7c4-9ec148aa3f65",
"templateVariable": "QiJ"
},
{
"query": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:ip/ios:default-gateway",
"condition": "cant",
"value": false,
"severity": "warning",
"comparison": "regex",
"ruleId": "28f65ea1-9cdb-b155-ec0c-b3e6aafd57ee",
"templateVariable": "RbbevbrESQ"
},
{
"query": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:hostname",
"condition": "must",
"value": false,
"severity": "notices",
"comparison": "string",
"ruleId": "900fd8fd-76b6-02a4-1134-683e30b60b46",
"templateVariable": "kSQe"
}
]
}
}
Copied to Clipboard
{
"type": "object",
"properties": {
"complianceErrors": {
"type": "object",
"properties": {
"errors": {
"type": "array",
"items": {
"$ref": "complianceError"
},
"minItems": 1
}
},
"required": [
"errors"
]
}
},
"required": [
"complianceErrors"
],
"additionalProperties": false
}
Return
DetailsExampleSchema
Name |
Type |
Description |
errors |
object |
Object with errors classified as deletion, regular or regex. |
Copied to Clipboard
{
"regularErrors": [
{
"xpath": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:hostname",
"value": true
},
{
"xpath": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:version",
"value": false
},
{
"xpath": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:version",
"value": 88766360.65619561
},
{
"xpath": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:version",
"value": 56236868.43490395
}
],
"regexErrors": [
{
"xpath": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:hostname",
"value": 45693745.88262406
},
{
"xpath": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:ip/ios:default-gateway",
"value": "yysxU"
},
{
"xpath": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:hostname",
"value": true
},
{
"xpath": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:version",
"value": "OPDgr"
}
],
"deletionErrors": [
{
"xpath": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:hostname",
"value": true
},
{
"xpath": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:version",
"value": false
},
{
"xpath": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:ip/ios:default-gateway",
"value": -7761969.103704706
}
]
}