Summary
Create a config parser.
Description
Create rules for a parser for breaking down configs in GC.
Route
POST /configuration_manager/configurations/parser
Roles
admin
apiwrite
Parameters
DetailsExampleSchema
Name |
Type |
Required |
Description |
name |
string |
yes |
Name of the config parser. |
lexRules |
array |
yes |
Lex rules that define the configuration model. |
template |
enum |
yes |
Allowed values are: [ cisco-ios, f5-bigip ] - Name of the config parser. |
Copied to Clipboard
{
"name": "commodo dolor aliquip",
"lexRules": [
[
"^}",
"close_statement_block"
],
[
"^}",
"close_statement_block"
],
[
"^{",
"open_statement_block"
],
[
"^{",
"open_statement_block"
]
],
"template": "cisco-ios"
}
Copied to Clipboard
{
"type": "object",
"properties": {
"name": {
"title": "name",
"type": "string",
"minLength": 1
},
"lexRules": {
"title": "lexRules",
"items": {
"title": "lexRule",
"type": "array",
"items": {
"type": "string"
},
"examples": [
[
"^{",
"open_statement_block"
],
[
"^}",
"close_statement_block"
]
]
}
},
"template": {
"title": "template",
"type": "string",
"enum": [
"cisco-ios",
"f5-bigip"
]
}
},
"required": [
"name",
"lexRules",
"template"
],
"additionalProperties": false
}
Return
DetailsExampleSchema
Name |
Type |
Description |
data |
object |
- |
Copied to Clipboard
{
"title": "data",
"type": "object",
"properties": {}
}