Retrieve a template
Fetch one saved template. The path segment accepts either the template id or its slug.
GET
/v1/templates/{id}01 Path parameters
idstringRequired
The template
id (e.g. tmpl_8XQ2k9) or its slug (e.g. order-receipt).02 Request
curl https://api.drin.run/v1/templates/order-receipt \
-H "Authorization: Bearer $DRIN_API_KEY"03 Response
{
"id": "tmpl_8XQ2k9",
"slug": "order-receipt",
"name": "Order Receipt",
"subject": "Receipt {{orderId}}",
"html": "<p>Hi {{firstName}}, thanks for your order.</p>",
"text": null,
"variables": ["firstName", "orderId"],
"createdAt": "2026-06-02T10:00:00.000Z",
"updatedAt": "2026-06-02T10:00:00.000Z"
}Not foundA template that doesn't exist in your project returns
404 not_found. Templates are project-scoped — a slug from another project won't resolve here.