latestOpenAPI 3.0.32026-08-10119559584.8 KB

6d091bc86a33

Templates

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.

get/templates

Query parameters

namestring

The name of the template.

The value is case-insensitive and it returns results that contain this value.

statusstring

The status of the template.

Possible values are: DRAFT, PUBLISHED or OBSOLETE. The value is case-insensitive. An invalid value results in an error response.

assetTypeIdstring uuid

The ID of the asset type.

latestVersionOnlyboolean

Whether it should only return the latest version of each template. The interaction with the status parameter is as follows:

  • If the status parameter is not set, it returns the latest version of each template regardless of the status.
  • If the status parameter is set to PUBLISHED, it returns the latest published version of each template.
  • If the status parameter is set to DRAFT, it returns the latest draft version of each template.
  • If the status parameter is set to OBSOLETE, it returns the latest obsolete version of each template.
limitinteger

This is the maximum number of results that may be returned. Fewer may be returned than the value of <code>limit</code>.

Do not depend on the number of results being fewer than the <code>limit</code> value to indicate that your query reached the end of the list of data, use the absence of <code>after</code> (see Cursors) instead. For example, if you set <code>limit</code> to 10 and 9 results are returned, there may be more data available.

If not set, the default limit (limit = <code>25</code>) will be used. The maximum value for this parameter is <code>500</code>.

cursorstring

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.

If this parameter is missing, the API returns the resources starting from the first available resource, at index 0.

Response

Example of a response for listing templates.

nextCursorstring

The cursor pointing to the next page. If the cursor is missing, there are no additional pages of resources available after the current one.