Summary
Applies value to the errors from templateVariables
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": "must",
"value": true,
"severity": "warning",
"comparison": "regex",
"ruleId": "fb9fefab-a05e-f0d1-5cff-2d349b96899a",
"templateVariable": "PRyajVIVTUD"
},
{
"query": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:ip/ios:default-gateway",
"condition": "cant",
"value": "lWdjhh",
"severity": "warning",
"comparison": "regex",
"ruleId": "2e8499ac-89ff-fac2-f508-760b953c6504",
"templateVariable": "FCzID"
}
]
},
"templateVariables": {
"UeFTO": "eu aliquip irure",
"k": "in aliqua",
"ODG": "est"
}
}
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": 75179002.94892243,
"severity": "warning",
"comparison": "regex",
"ruleId": "77466127-5ff2-5588-8606-9ba74756118f",
"templateVariable": "drXtFz"
},
{
"query": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:hostname",
"condition": "cant",
"value": "FX",
"severity": "notices",
"comparison": "regex",
"ruleId": "c577cd94-f63c-c404-6505-fcd47cdf05d7",
"templateVariable": "dnKntCwhaw"
},
{
"query": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:hostname",
"condition": "cant",
"value": false,
"severity": "notices",
"comparison": "string",
"ruleId": "b608aaed-73b8-42b1-3952-417e5edd2b6c",
"templateVariable": "Y"
},
{
"query": "/ncs:devices/ncs:device[ncs:name='ios0']/ncs:config/ios:version",
"condition": "cant",
"value": "ssy",
"severity": "notices",
"comparison": "string",
"ruleId": "1fc29c6c-dfd9-ab62-fb1b-ea6cec726e50",
"templateVariable": "Fboin"
}
]
}
Copied to Clipboard
{
"type": "object",
"properties": {
"errors": {
"type": "array",
"items": {
"$ref": "complianceError"
},
"minItems": 1
}
},
"required": [
"errors"
]
}