object template.delete(array templateIds)
This method allows to delete templates.
Deleting a template also removes all of its entities (items, triggers, graphs, etc.) from any hosts or templates it is linked to. To keep these entities, first unlink the template from the relevant hosts or templates using the host.update, host.massremove, template.update, or template.massremove methods.
This method is only available to Admin and Super admin user types. Permissions to call the method can be revoked in user role settings. See User roles for more information.
(array) IDs of the templates to delete.
(object) Returns an object containing the IDs of the deleted templates under the templateids property.
Delete two templates.
Response:
CTemplate::delete() in ui/include/classes/api/services/CTemplate.php.