Summary
Create Smart Template
Description
Create a Smart Template from native Config
Route
POST /smart_template/st/autogenerate
Roles
admin
Parameters
DetailsExampleSchema
Name |
Type |
Required |
Description |
operating_system |
string |
yes |
NED ID |
native_config |
string |
yes |
Native device configuration |
Copied to Clipboard
{
"operating_system": "ios",
"native_config": "hostname someHost"
}
Copied to Clipboard
{
"type": "object",
"properties": {
"operating_system": {
"type": "string",
"examples": [
"ios",
"junos",
"iosxr"
]
},
"native_config": {
"type": "string",
"examples": [
"hostname someHost",
"interface GigabitEthernet1/1"
]
}
},
"required": [
"operating_system",
"native_config"
],
"additionalProperties": false
}
Return
DetailsExampleSchema
Name |
Type |
Description |
config |
object |
Smart Template object |
Copied to Clipboard
{
"faml": {
"_attr": {
"type": "leaf",
"ns": "http://tail-f.com/ns/ncs",
"prefix": "ios",
"condition": "cant",
"severity": "notices"
},
"_value": "U"
},
"form": {
"name": "Form 123",
"children": [
{
"properties": {
"type": "leafref",
"path": "/ncs:devices/ncs:device/ncs:name",
"min": null,
"max": "4",
"minLength": "1",
"maxLength": "4",
"default": false,
"direction": "vertical",
"required": false,
"enforce": false,
"hidden": true
},
"id": "et laborum reprehenderit",
"type": "container",
"element": "{\"type\":\"service_model\",\"id\":{\"name\":\"/ncs:services/devices:stringified_json\"}",
"name": "vlan_id_123",
"display_name": "vlan",
"source_type": "service_model",
"source": "/ncs:services/abc_devices:ios.device",
"key": "key545385c3-fc66-491b-bf6f-abc2214366dc"
},
{
"properties": {
"type": "leafref",
"path": "/ncs:devices/ncs:device/ncs:name",
"min": null,
"max": "4",
"minLength": "1",
"maxLength": "4",
"default": true,
"direction": "vertical",
"required": true,
"enforce": true,
"hidden": true
},
"id": "quis in",
"type": "container",
"element": "{\"type\":\"service_model\",\"id\":{\"name\":\"/ncs:services/devices:stringified_json\"}",
"name": "vlan_id_123",
"display_name": "vlan",
"source_type": "service_model",
"source": "/ncs:services/abc_devices:ios.device",
"key": "service.vlanid"
}
],
"elements": [
{
"type": "service_model",
"id": {
"name": "/ncs:services/test_devices:service_name"
}
},
{
"type": "service_model",
"id": {
"name": "/ncs:services/test_devices:service_name"
}
},
{
"type": "service_model",
"id": {
"name": "/ncs:services/test_devices:service_name"
}
},
{
"type": "service_model",
"id": {
"name": "/ncs:services/test_devices:service_name"
}
},
{
"type": "service_model",
"id": {
"name": "/ncs:services/test_devices:service_name"
}
}
],
"_id": "805a8486-efdf-f8dc-0516-83f1cbe4e469",
"groups": [
"da7c1cbf8b35f28eb67068bf",
"3463e6ae2c4dd70d419e14f7",
"f70ce92ff1a1d825fe81a0a9",
"53f41ef8e09f5f8c47ec5b18",
"6323a66342daa84e20e33868"
],
"created": "1952-05-16T21:59:11.763Z",
"created_by": "31d5fa64dbc0c166e959b7d0",
"last_updated": "2013-03-27T04:19:02.047Z",
"last_updated_by": "bbdffbed20cf4acf57d36e4d",
"tags": [
"aliquip dolore in",
"consequat dolore commodo eiusmod enim",
"consequat Excepteur labore amet",
"sed",
"laborum qui ullamco"
]
}
}