Retrieve a template version
lob_template_versions_getRetrieve a specific version of a template using its template ID and version ID.
Instructions
Retrieve a specific version of a template.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| template_id | Yes | Template ID (`tmpl_…`). | |
| version_id | Yes | Template version ID (`vrsn_…`). |
Implementation Reference
- src/tools/templates.ts:295-302 (registration)Registration of the lob_template_versions_get tool. It reads the template_id and version_id from input, and makes a GET request to the Lob API endpoint /templates/{template_id}/versions/{version_id}.
registerTool(server, { name: "lob_template_versions_get", annotations: { title: "Retrieve a template version", ...ToolAnnotationPresets.read }, description: "Retrieve a specific version of a template.", inputSchema: { template_id: TEMPLATE_ID, version_id: VERSION_ID }, handler: async ({ template_id, version_id }) => lob.request({ method: "GET", path: `/templates/${template_id}/versions/${version_id}` }), }); - src/tools/templates.ts:299-299 (schema)Input schema for lob_template_versions_get requiring template_id and version_id (defined as constants elsewhere).
inputSchema: { template_id: TEMPLATE_ID, version_id: VERSION_ID }, - src/tools/templates.ts:300-301 (handler)Handler that destructures template_id and version_id from args and makes a GET request to the Lob API to retrieve a specific template version.
handler: async ({ template_id, version_id }) => lob.request({ method: "GET", path: `/templates/${template_id}/versions/${version_id}` }),