---
search:
  tags:
    - administration
    - GET
seo:
  description: >-
    Returns the complete document template including its… Reference for the GET
    /administration/document-templates/{id} endpoint in the Leadtime Public API
    API.
sidebar:
  badge: GET
  label: Get document template details
title: Get document template details
type: openapi-operation
---
Returns the complete document template including its content and custom variables.

**What is returned:**
- Full template metadata (name, description, language, type)
- Template content as HTML (converted from internal IDoc format)
- All custom variables defined for this template
- Creation and update timestamps with user information

**Content format:**
The content is returned as HTML, which may include:
- Static text and formatting (headings, lists, tables, etc.)
- Variable placeholders (e.g., `<span data-type="variable" data-id="project.name">...</span>`)
- Conditional sections that show/hide based on variable values
- Page breaks for document structure

**Custom variables:**
Each template can define custom variables that extend beyond the standard system variables. These are returned with their type, default values, and whether they are required.

<Operation source="api-reference" id="documenttemplatescontroller-getdocumenttemplate" />
