{
"type": "object",
"properties": {
"templates": {
"title": "templates",
"description": "Array of template documents to import. If '_id' is provided, it will be replaced with an autogenerated '_id'. If a template's name is already used in the templates collection, it will be renamed with a numeric suffix.",
"type": "array",
"items": {
"$ref": "templateImport"
}
}
},
"required": [
"templates"
],
"additionalProperties": false
}
Return
DetailsExampleSchema
Name
Type
Description
response
object
Results from each individual import operation.
Copied to Clipboard
{
"imported": [
{
"message": "nisi Ut",
"original": {
"_id": "b0d89246c871c6348266eb1a",
"name": "test",
"group": "Sample group",
"command": "show ip br",
"description": "description",
"template": "Value FIRST_WORD (S+)\n\nStart\n ^FIRST_WORD.* -> Record",
"data": "some sample text to match against",
"type": "test",
"createdBy": "0bc8175fd3f106c698451aa1",
"created": "2019-11-25T22:51:39.201Z",
"lastModifiedBy": "d14d8e506285dff317107951",
"lastUpdated": "2019-11-25T22:51:39.201Z",
"version": 1,
"tags": [
{
"_id": "7d44a9cb46393d1cd9dc0c78",
"name": "qui cillum"
},
{
"_id": "b36d5e25e715afe2d5e01104",
"name": "esse exercitation aliquip ut mollit"
},
{
"_id": "63d880cb62709466da17f88e",
"name": "labore exercitation"
}
]
},
"created": {
"name": "test",
"group": "Sample group",
"command": "show ip br",
"description": "description",
"template": "Value FIRST_WORD (S+)\n\nStart\n ^FIRST_WORD.* -> Record",
"data": "some sample text to match against",
"type": "test",
"_id": "4fF88eDD02B25eDB11B1ff9f",
"createdBy": "F2Fdfebab4eF18EE0ceDF554",
"created": "2019-11-25T22:51:39.201Z",
"lastUpdatedBy": "a02AE2E1F08AefC212fbb723",
"lastUpdated": "2019-11-25T22:51:39.201Z",
"version": 1,
"tags": [
{
"_id": "D8a8f02Bb4B1E8A3f508F16E",
"name": "qui ea sed proident",
"description": "A user-defined object to help group documents."
},
{
"_id": "B97C40Fa0Cd49A3EABCA9Ac3",
"name": "dolor sint officia",
"description": "A user-defined object to help group documents."
}
]
},
"edit": "proident aute consequat",
"success": false
}
]
}
Copied to Clipboard
{
"title": "response",
"type": "object",
"properties": {
"imported": {
"type": "array",
"items": {
"type": "object",
"properties": {
"success": {
"type": "boolean",
"description": "Status flag denoting the success (true) or failure (false) of the template's import operation."
},
"message": {
"type": "string",
"description": "Message containing either confirmation of the import operation or the reason for the failure of the import operation."
},
"original": {
"description": "The original template given in the import array.",
"$ref": "templateImport"
},
"created": {
"description": "The imported template as it exists after being imported.",
"oneOf": [
{
"$ref": "template"
},
{
"type": "null"
}
]
},
"edit": {
"description": "URI to the edit page for the imported template.",
"type": [
"string",
"null"
]
}
},
"required": [
"status",
"message",
"original",
"created",
"edit"
]
}
}
}
}