> For the complete documentation index, see [llms.txt](https://developer.collibra.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developer.collibra.com/api/references/assessments/templates.md).

# Templates

Retrieve templates data.

## List templates

> This API version is deprecated and will be removed in future releases. We recommend you to use the V2 version of this API, which is available at \`/rest/assessments/v2\`.\
> Returns a list of all available templates. The templates are sorted by \`name\` in alphabetical order.<br>

```json
{"openapi":"3.0.3","info":{"title":"Collibra Assessments API","version":"1.0.0"},"tags":[{"name":"Templates","description":"Retrieve templates data."}],"servers":[{"url":"/rest/assessments/v1"}],"security":[{"basicAuth":[]},{"jwtAuth":[]}],"components":{"securitySchemes":{"basicAuth":{"description":"This API requires Basic HTTP authentication.","type":"http","scheme":"basic"},"jwtAuth":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"Collibra REST API authentication using JSON Web Token."}},"parameters":{"Limit":{"name":"limit","in":"query","description":"The maximum number of resources to retrieve.\n\nIf not set, the default limit of `10` is be used. The maximum value for this parameter is `50`.\n","schema":{"type":"integer","default":10,"minimum":1,"maximum":50}},"Cursor":{"name":"cursor","in":"query","description":"The cursor pointing to the first resource to be included in the response. This cursor cannot be created and must have been extracted from a response returned by a previous API call.\n\nIf this parameter is missing, the API returns the resources starting from the first available resource, at index `0`.\n","schema":{"type":"string"}}},"responses":{"ListTemplates200":{"description":"Example of a response for listing templates.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PagedTemplates"}}}},"InvalidRequest400":{"description":"The request is not valid.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StandardErrorResponse"}}}},"InvalidRequest401":{"description":"The client is not authenticated.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StandardErrorResponse"}}}},"InvalidRequest403":{"description":"The user lacks permissions.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StandardErrorResponse"}}}},"InvalidRequest500":{"description":"There was an error processing the request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StandardErrorResponse"}}}}},"schemas":{"PagedTemplates":{"description":"A page object containing templates.","type":"object","properties":{"nextCursor":{"description":"The cursor pointing to the next page. If the cursor is missing, there are no additional pages of resources available after the current one.","type":"string"},"results":{"type":"array","items":{"$ref":"#/components/schemas/Template"}}},"required":["results"]},"Template":{"description":"A template object.","type":"object","allOf":[{"$ref":"#/components/schemas/BaseTemplate"},{"type":"object","properties":{"name":{"description":"The name of the template.","type":"string"},"version":{"description":"The version of the template.","type":"integer"},"status":{"description":"The status of the template.","type":"string"},"assetType":{"$ref":"#/components/schemas/AssetType"},"notification":{"description":"Flag to indicate if notifications are on or off for the template.","type":"boolean"}},"required":["name","version","status"]}]},"BaseTemplate":{"description":"A base template object.","type":"object","properties":{"id":{"description":"The ID of the template.","type":"string","format":"uuid"}},"required":["id"]},"AssetType":{"description":"The object for an asset type in Collibra.","type":"object","properties":{"id":{"description":"The ID of the Collibra asset type.","type":"string","format":"uuid"},"name":{"description":"The name of the Collibra asset type.","type":"string"}},"required":["id","name"]},"StandardErrorResponse":{"description":"A standard error response object.","type":"object","properties":{"statusCode":{"description":"HTTP response code.","type":"integer"},"titleMessage":{"description":"The title of the error message.","type":"string"},"helpMessage":{"description":"A message containing actions you can take regarding the error.","type":"string"},"userMessage":{"description":"A user friendly error message.","type":"string"},"errorCode":{"description":"An error code identifier.","type":"string"}},"required":["statusCode","userMessage"]}}},"paths":{"/templates":{"get":{"tags":["Templates"],"deprecated":true,"summary":"List templates","description":"This API version is deprecated and will be removed in future releases. We recommend you to use the V2 version of this API, which is available at `/rest/assessments/v2`.\nReturns a list of all available templates. The templates are sorted by `name` in alphabetical order.\n","operationId":"listTemplates","parameters":[{"in":"query","name":"name","schema":{"type":"string"},"description":"The name of the template. \n\nThe value is case-insensitive and it returns results that contain this value.\n"},{"in":"query","name":"status","schema":{"type":"string"},"description":"The status of the template. \n\nPossible values are: `DRAFT`, `PUBLISHED` or `OBSOLETE`. The value is case-insensitive. An invalid value results in an error response.\n"},{"in":"query","name":"assetTypeId","schema":{"type":"string","format":"uuid"},"description":"The ID of the asset type."},{"in":"query","name":"latestVersionOnly","schema":{"type":"boolean"},"description":"Whether it should only return the latest version of each template. The interaction with the `status` parameter is as follows:\n- If the `status` parameter is not set, it returns the latest version of each template regardless of the status.\n- If the `status` parameter is set to `PUBLISHED`, it returns the latest published version of each template.\n- If the `status` parameter is set to `DRAFT`, it returns the latest draft version of each template.\n- If the `status` parameter is set to `OBSOLETE`, it returns the latest obsolete version of each template.\n"},{"$ref":"#/components/parameters/Limit"},{"$ref":"#/components/parameters/Cursor"}],"responses":{"200":{"$ref":"#/components/responses/ListTemplates200"},"400":{"$ref":"#/components/responses/InvalidRequest400"},"401":{"$ref":"#/components/responses/InvalidRequest401"},"403":{"$ref":"#/components/responses/InvalidRequest403"},"500":{"$ref":"#/components/responses/InvalidRequest500"}}}}}}
```

## Get Template by ID

> This API version is deprecated and will be removed in future releases. We recommend you to use the V2 version of this API, which is available at \`/rest/assessments/v2\`. Returns the latest published version of a template for the specified template Id.

```json
{"openapi":"3.0.3","info":{"title":"Collibra Assessments API","version":"1.0.0"},"tags":[{"name":"Templates","description":"Retrieve templates data."}],"servers":[{"url":"/rest/assessments/v1"}],"security":[{"basicAuth":[]},{"jwtAuth":[]}],"components":{"securitySchemes":{"basicAuth":{"description":"This API requires Basic HTTP authentication.","type":"http","scheme":"basic"},"jwtAuth":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"Collibra REST API authentication using JSON Web Token."}},"responses":{"GetTemplate200":{"description":"Example of a response for get template.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Template"}}}},"InvalidRequest400":{"description":"The request is not valid.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StandardErrorResponse"}}}},"InvalidRequest401":{"description":"The client is not authenticated.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StandardErrorResponse"}}}},"InvalidRequest403":{"description":"The user lacks permissions.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StandardErrorResponse"}}}},"InvalidRequest404":{"description":"Resource not found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StandardErrorResponse"}}}},"InvalidRequest500":{"description":"There was an error processing the request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StandardErrorResponse"}}}}},"schemas":{"Template":{"description":"A template object.","type":"object","allOf":[{"$ref":"#/components/schemas/BaseTemplate"},{"type":"object","properties":{"name":{"description":"The name of the template.","type":"string"},"version":{"description":"The version of the template.","type":"integer"},"status":{"description":"The status of the template.","type":"string"},"assetType":{"$ref":"#/components/schemas/AssetType"},"notification":{"description":"Flag to indicate if notifications are on or off for the template.","type":"boolean"}},"required":["name","version","status"]}]},"BaseTemplate":{"description":"A base template object.","type":"object","properties":{"id":{"description":"The ID of the template.","type":"string","format":"uuid"}},"required":["id"]},"AssetType":{"description":"The object for an asset type in Collibra.","type":"object","properties":{"id":{"description":"The ID of the Collibra asset type.","type":"string","format":"uuid"},"name":{"description":"The name of the Collibra asset type.","type":"string"}},"required":["id","name"]},"StandardErrorResponse":{"description":"A standard error response object.","type":"object","properties":{"statusCode":{"description":"HTTP response code.","type":"integer"},"titleMessage":{"description":"The title of the error message.","type":"string"},"helpMessage":{"description":"A message containing actions you can take regarding the error.","type":"string"},"userMessage":{"description":"A user friendly error message.","type":"string"},"errorCode":{"description":"An error code identifier.","type":"string"}},"required":["statusCode","userMessage"]}}},"paths":{"/templates/{id}":{"get":{"tags":["Templates"],"deprecated":true,"summary":"Get Template by ID","description":"This API version is deprecated and will be removed in future releases. We recommend you to use the V2 version of this API, which is available at `/rest/assessments/v2`. Returns the latest published version of a template for the specified template Id.","operationId":"getTemplate","parameters":[{"in":"path","name":"id","schema":{"type":"string","format":"uuid"},"description":"The ID of the template.","required":true}],"responses":{"200":{"$ref":"#/components/responses/GetTemplate200"},"400":{"$ref":"#/components/responses/InvalidRequest400"},"401":{"$ref":"#/components/responses/InvalidRequest401"},"403":{"$ref":"#/components/responses/InvalidRequest403"},"404":{"$ref":"#/components/responses/InvalidRequest404"},"500":{"$ref":"#/components/responses/InvalidRequest500"}}}}}}
```
