Summary
Apply value to errors
Description
Selects the errors and changes their value using values from templateVariables
Route
POST /golden_config/applyTemplateVariables
Roles
admin
engineering
support
Parameters
DetailsExampleSchema
Name |
Type |
Required |
Description |
complianceErrors |
object |
yes |
Array of errors, device and tree information |
templateVariables |
object |
yes |
An array or object of template variables and the values associated with them |
Copied to Clipboard
{
"complianceErrors": {
"errors": [
{
"query": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:hostname",
"condition": "cant",
"value": 68219322.77848065,
"severity": "warning",
"comparison": "string",
"ruleId": "e1d35374-7f1f-e3dd-1bf0-3053f7f71cfa",
"templateVariable": "nMSe"
},
{
"query": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:version",
"condition": "cant",
"value": "KDYgATdLWz",
"severity": "warning",
"comparison": "string",
"ruleId": "35d2b40d-8995-84c6-1393-5b7e8b867dcf",
"templateVariable": "IVnTncOR"
},
{
"query": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:hostname",
"condition": "must",
"value": 77735054.76410133,
"severity": "error",
"comparison": "regex",
"ruleId": "5776ac1b-bc37-5237-c8b1-4ba020c7c888",
"templateVariable": "VWobzdtZta"
},
{
"query": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:version",
"condition": "cant",
"value": -91089680.82451545,
"severity": "notices",
"comparison": "regex",
"ruleId": "b567620f-4efe-ee01-bd53-cec59bacbe48",
"templateVariable": "QcfT"
}
]
},
"templateVariables": {
"Ut": "ipsum cillum ex",
"DI8": "ex",
"ndepu379G": "sed magna mollit eiusmod"
}
}
Copied to Clipboard
{
"type": "object",
"properties": {
"complianceErrors": {
"type": "object",
"properties": {
"errors": {
"type": "array",
"items": {
"$ref": "complianceError"
},
"minItems": 1
}
},
"required": [
"errors"
]
},
"templateVariables": {
"$ref": "templateVariables"
}
},
"required": [
"complianceErrors",
"templateVariables"
],
"additionalProperties": false
}
Return
DetailsExampleSchema
Name |
Type |
Description |
complianceErrors |
object |
Array of errors, device and tree information |
Copied to Clipboard
{
"errors": [
{
"query": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:ip/ios:default-gateway",
"condition": "cant",
"value": false,
"severity": "notices",
"comparison": "regex",
"ruleId": "c2d3adba-9be7-1da7-6e57-80b44c0d751e",
"templateVariable": "VSMw"
},
{
"query": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:hostname",
"condition": "cant",
"value": "KYX",
"severity": "warning",
"comparison": "string",
"ruleId": "34ef341b-0bf1-0c98-312d-ac95c02c8a12",
"templateVariable": "exzKTZJcjbI"
}
]
}
Copied to Clipboard
{
"type": "object",
"properties": {
"errors": {
"type": "array",
"items": {
"$ref": "complianceError"
},
"minItems": 1
}
},
"required": [
"errors"
]
}