Summary
Gets a page of template documents.
Description
Gets a page of template documents.
Route
GET /automation-studio/templates
Roles
Parameters
Name | Type | Required | Description |
---|---|---|---|
queryParameters | object | yes | Parameters for filtering, paginating, projecting, and sorting template documents. |
{ "queryParameters": { "limit": 50, "skip": 10, "order": 1, "sort": "name", "include": "description", "exclude": "description", "in": { "_id": "in", "name": "deserunt eiusmod ut id", "group": "Lorem in culpa", "command": "pariatur incididunt adipisicing", "description": "Ut", "template": "occaecat ut pariatur dolore qui", "data": "occaecat Ut commodo sint ea", "type": "amet", "createdBy": "ad", "created": "ut", "lastModifiedBy": "elit", "lastUpdated": "magna" }, "not-in": { "_id": "ex do", "name": "consectetur ad eiusmod ut enim", "group": "aute ut aliquip aliqua", "command": "sed elit", "description": "tempor Lorem ipsum officia", "template": "commodo dolor cupidatat adipisicing", "data": "enim deserunt", "type": "cupidatat commodo ut veniam aliqua", "createdBy": "commodo qui nisi", "created": "sint sunt mollit sed incididunt", "lastModifiedBy": "sint", "lastUpdated": "in nulla velit nostrud" }, "equals": { "_id": "consequat velit", "name": "sed laboris nulla aliquip", "group": "amet tempor quis", "command": "reprehenderit deserunt eiusmod minim", "description": "sit velit in", "template": "enim mollit ipsum", "data": "est mollit et", "type": "sint mollit voluptate", "createdBy": "culpa proident dolore commodo", "created": "ad ea incididunt", "lastModifiedBy": "nisi sunt", "lastUpdated": "eiusmod consequat aliqua" }, "contains": { "_id": "dolore", "name": "adipisicing labore ipsum sint enim", "group": "nulla cupidatat veniam", "command": "dolor", "description": "anim nisi", "template": "magna", "data": "minim incididunt", "type": "qui dolor", "createdBy": "tempor aute fugiat dolore aliqua", "created": "labore nisi officia", "lastModifiedBy": "cupidatat minim", "lastUpdated": "irure nisi" }, "starts-with": { "_id": "enim id velit eu", "name": "ut nostrud", "group": "esse", "command": "cillum nostrud nulla reprehenderit", "description": "tempor eu", "template": "et veniam dolor incididunt", "data": "dolor officia", "type": "enim sed officia anim cupidatat", "createdBy": "voluptate mollit dolore nisi", "created": "veniam est sunt", "lastModifiedBy": "minim occaecat laboris voluptate", "lastUpdated": "aliqua" }, "ends-with": { "_id": "dolor in in aliquip", "name": "incididunt", "group": "ullamco velit reprehenderit dolor", "command": "nostrud incididunt exercitation culpa velit", "description": "sint", "template": "laboris pariatur", "data": "sint dolore et officia cillum", "type": "quis cillum in sunt dolore", "createdBy": "aliquip do", "created": "sint ea eiusmod et", "lastModifiedBy": "anim culpa elit in", "lastUpdated": "et laborum" } } }
{ "type": "object", "properties": { "queryParameters": { "title": "queryParameters", "type": "object", "properties": { "limit": { "type": "integer", "description": "Number of results to return. Used for pagination.", "default": 25, "minimum": 0, "examples": [ 1, 10, 50 ] }, "skip": { "type": "integer", "description": "Number of results to skip. Used for pagination.", "default": 0, "minimum": 0, "examples": [ 1, 10, 50 ] }, "order": { "type": "integer", "description": "Sort direction, 1 for ascending and -1 for descending.", "default": 1, "enum": [ -1, 1 ] }, "sort": { "type": "string", "description": "Field to sort by", "default": "name", "enum": [ "name" ] }, "include": { "type": "string", "description": "Inclusive projection operator formatted as a comma-delineated list. '_id' will be included implicitly unless excluded with 'exclude=_id'. May only be used in conjunction with 'exclude' when 'exclude=_id'.", "examples": [ "name", "description", "name,description" ] }, "exclude": { "type": "string", "description": "Exclusive projection operator formatted as a comma-delineated list. May only be used in conjunction with 'include' when 'exclude=_id'.", "examples": [ "_id", "description", "_id,description" ] }, "in": { "description": "Search for fields exactly matching one of the given list options", "$ref": "template#/definitions/searchableFields" }, "not-in": { "description": "Search for fields not exactly matching one of the given list options", "$ref": "template#/definitions/searchableFields" }, "equals": { "description": "Returns results where the specified fields exactly match the given match string(s).", "$ref": "template#/definitions/searchableFields" }, "contains": { "description": "Returns results where the specified fields contain the given match string(s).", "$ref": "template#/definitions/searchableFields" }, "starts-with": { "description": "Returns results where the specified fields start with the given match string(s).", "$ref": "template#/definitions/searchableFields" }, "ends-with": { "description": "Returns results where the specified fields end in the given match string(s).", "$ref": "template#/definitions/searchableFields" } } } }, "required": [ "queryParameters" ], "additionalProperties": false }
Return
Name | Type | Description |
---|---|---|
result | object | Results for the given search parameters. |
{ "items": [ { "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": "E8f7e5ecdFFbDC00738A6d7f", "createdBy": "0aC8e5Fc9c84Ba074cf67EEe", "created": "2019-11-25T22:51:39.201Z", "lastModifiedBy": "7a60cA6C0a926AF3224AE21C", "lastUpdated": "2019-11-25T22:51:39.201Z", "version": 1 } ], "total": -26862806, "start": -51539978, "end": 51235083, "count": -70576743, "next": null, "previous": "pariatur nulla" }
{ "title": "result", "type": "object", "properties": { "items": { "type": "array", "items": { "$ref": "template" } }, "total": { "type": "integer", "description": "Total number of documents matching the given query parameters." }, "start": { "type": "integer", "description": "Search index of first document in the items array." }, "end": { "type": "integer", "description": "Search index of the last document in the items array." }, "count": { "type": "integer", "description": "Length of the items array." }, "next": { "type": [ "string", "null" ], "description": "URI pointing to the next set of paginated results. Preserves previous search and projection parameters. Null if returning the last page of results." }, "previous": { "type": [ "string", "null" ], "description": "URI pointing to the previous set of paginated results. Preserves previous search and projection parameters. Null if returning the first page of results." } } }