{ "$id": "templateDocument", "title": "template document", "description": "A template document", "type": "object", "properties": { "_id": { "$ref": "#/definitions/ObjectId" }, "name": { "$ref": "#/definitions/templateName" }, "device": { "$ref": "#/definitions/groupName" }, "command": { "$ref": "#/definitions/command" }, "template": { "$ref": "#/definitions/template" }, "text": { "$ref": "#/definitions/text" }, "type": { "type": "string", "const": "custom" } }, "required": [ "name", "device", "command", "template", "text", "type" ], "definitions": { "templateName": { "type": "string", "examples": [ "My Template" ] }, "groupName": { "type": "string", "examples": [ "Device Group A" ] }, "command": { "type": "string", "examples": [ "show hostname" ] }, "template": { "type": "string", "examples": [ "Value HOSTNAME (.+?)\n\nStart\n ^${HOSTNAME}\\s*$$ -> Record" ] }, "text": { "type": "string", "examples": [ "hostname" ] }, "ObjectId": { "type": "string", "pattern": "^[0-9a-f]{24}$" } } }