API
템플릿 조회
id 또는 slug를 받습니다. 가장 최신 버전이 본문까지 포함해 전부 반환됩니다.
GETapi.openemail.uk/templates/{id}
본인 키로 워크스페이스에 실제 호출을 실행합니다.
GET /templates/{id}
id 또는 slug를 받습니다. 가장 최신 버전이 본문까지 포함해 전부 반환됩니다.
예시
templates:read가 필요합니다. id에는 tpl_ 접두사가 붙고 slug에는 붙을 수 없으므로, 이 경로에서 두 체계가 충돌할 일은 없습니다.
curl "$OE/templates/order-shipped" -H "$AUTH"{ "object": "template", "id": "tpl_9c1f0a4b7e05d3862c1f0a44", "name": "Order shipped", "slug": "order-shipped", "status": "active", "publishedVersion": 3, "latestVersion": 4, "subject": "Order {{orderId}} is on its way", "engine": "html", "slots": [], "props": [{ "key": "orderId", "kind": "text", "required": true, "default": null }], "latest": { "object": "template_version", "id": "tplv_5d31c2a8…", "templateId": "tpl_9c1f0a4b7e05d3862c1f0a44", "version": 4, "state": "draft", "engine": "html", "subject": "Order {{orderId}} is on its way", "slots": [], "props": [{ "key": "orderId", "kind": "text", "required": true, "default": null }], "document": null, "html": "<p>Hello {{customer}}, {{orderId}} left the warehouse.</p>", "createdAt": "2026-08-28T16:03:10.000Z", "publishedAt": null }, "createdAt": "2026-08-01T09:12:44.000Z", "updatedAt": "2026-08-28T16:03:10.000Z"}latest는 가장 최신 버전이며, 게시되지 않은 수정이 있다면 그 초안입니다. 그 옆의 필드들(subject, engine, slots, props)은 게시된 버전을 설명하는데, 발송이 해석하는 대상이 바로 그것이기 때문입니다.
document는 블록 트리이며 engine: "html"에서는 null입니다. html은 제출된 그대로의 마크업이며 engine: "blocks"에서는 null입니다. 둘 중 어느 것도 단건 조회에서만 실립니다. 버전마다 전체 트리를 담은 목록은 아무도 원하지 않는 페이로드입니다.