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": 1, "skip": 10, "order": 1, "sort": "name", "exclude-project-members": true, "include": "name,description", "exclude": "description", "in": "proident ex", "not-in": "incididunt id irure deserunt", "equals": "do irure labore veniam ut", "contains": "nulla Ut exercitation dolor", "starts-with": "deserunt labore consequat eu voluptate", "ends-with": "ipsum velit do ut" } }
{ "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" ] }, "exclude-project-members": { "type": "boolean", "description": "Flag which removes workflows from the results which are members of a project" }, "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", "type": "string" }, "not-in": { "description": "Search for fields not exactly matching one of the given list options", "type": "string" }, "equals": { "description": "Returns results where the specified fields exactly match the given match string(s).", "type": "string" }, "contains": { "description": "Returns results where the specified fields contain the given match string(s).", "type": "string" }, "starts-with": { "description": "Returns results where the specified fields start with the given match string(s).", "type": "string" }, "ends-with": { "description": "Returns results where the specified fields end in the given match string(s).", "type": "string" } } } }, "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": "9db05aeAC0f4A2AF6e5aCbD9", "namespace": { "type": "project", "name": "incididunt", "accessControl": { "read": [ "ut ullamco", "ullamco enim veniam tempor mollit", "aute Excepteur officia ad ut", "nisi dolor consectetur" ], "write": [ "eu nulla in consequat", "pariatur" ], "execute": [ "aliquip aute minim" ], "manage": [ "pariatur dolore" ] } }, "createdBy": "6EDEBd5dCCfFC67bCcbFFd50", "created": "2019-11-25T22:51:39.201Z", "lastUpdatedBy": "f052a9CBfEA462EcF3E6dEFa", "lastUpdated": "2019-11-25T22:51:39.201Z", "version": 1, "tags": [ { "_id": "2dACcf504AF92Be3C22afe18", "name": "ad veniam mollit" }, { "_id": "ACBcfC478Bb9Ad5a5fB0c5a9", "name": "ea aliquip quis in eiusmod" } ] }, { "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": "a785Bfcd70FeFfBD54d1B23f", "namespace": { "type": "project", "name": "et esse", "accessControl": { "read": [ "nisi cupidatat" ], "write": [ "incididunt minim pariatur", "Duis sit adipisicing nulla" ], "execute": [ "adipisicing quis laborum" ], "manage": [ "ad Lorem in ullamco ea", "aliqua ad enim" ] } }, "createdBy": "F2e26DF2FCa47DA0fA0fd449", "created": "2019-11-25T22:51:39.201Z", "lastUpdatedBy": "b2CefC8c1b5bcfFd0c616069", "lastUpdated": "2019-11-25T22:51:39.201Z", "version": 1, "tags": [ { "_id": "3e2dCE4B2a9b96Ca26322E1F", "name": "enim et nisi Excepteur" } ] } ], "total": 37889432, "start": 94595690, "end": 46683358, "count": -6899590, "next": null, "previous": "est aute" }
{ "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": { "description": "URI pointing to the next set of paginated results. Preserves previous search and projection parameters. Null if returning the last page of results.", "oneOf": [ { "type": "string" }, { "type": "null" } ] }, "previous": { "description": "URI pointing to the previous set of paginated results. Preserves previous search and projection parameters. Null if returning the first page of results.", "oneOf": [ { "type": "string" }, { "type": "null" } ] } } }