Get what a template is drawn with
The published brand kit (or its defaults before one is published), where its files are, and the published components the template uses: what `render` compiles with, for drawing it while it’s edited (D112). The template’s own brand overrides are in its document.
The published brand kit (or its defaults before one is published), where its files are, and the published components the template uses: what render compiles with, for drawing it while it’s edited (D112). The template’s own brand overrides are in its document.
apiKey readAuthorizationBearer <token>A workspace API key (pf_…), created under Developers → API keys.
Scope: read
id*stringuuidOK
application/json- response
brandKit*brandKitVersionId*|uuidassetUrls*components*componentNames*curl -X GET 'https://api.postforge.dev/v1/templates/497f6eca-6276-4993-bfeb-53cbbbba6f08/inputs'{ "brandKit": { "logo": { "assetId": "9179b887-04ef-4ce5-ab3a-b5bbd39ea3c8", "darkAssetId": "7f2d7a5c-c164-4dc5-9d6f-b92860b4df8d" }, "colors": { "roles": { "background": "string", "surface": "string", "text": "string", "muted": "string", "primary": "string", "on_primary": "string", "secondary": "string", "on_secondary": "string", "border": "string" }, "custom": [ { "key": "string", "label": "string", "value": "string" } ] }, "fonts": [ { "key": "string", "font": { "source": "system", "family": "Arial" } } ], "text": { "font": "string", "fontSize": 12, "lineHeight": 1, "mobile": { "fontSize": 12, "lineHeight": 1 } }, "headings": { "h1": { "font": "string", "fontSize": 16, "lineHeight": 1, "mobile": { "fontSize": 16, "lineHeight": 1 }, "fontWeight": 400 }, "h2": { "font": "string", "fontSize": 14, "lineHeight": 1, "mobile": { "fontSize": 14, "lineHeight": 1 }, "fontWeight": 400 }, "h3": { "font": "string", "fontSize": 12, "lineHeight": 1, "mobile": { "fontSize": 12, "lineHeight": 1 }, "fontWeight": 400 } }, "links": { "color": "string", "underline": true }, "buttons": [ { "key": "string", "label": "string", "background": "string", "color": "string", "border": { "color": "string", "width": 1 }, "font": "string", "fontSize": 12, "fontWeight": 400, "radius": 0, "paddingY": 4, "paddingX": 8, "mobile": { "fontSize": 12, "paddingY": 4, "paddingX": 8 } }, { "key": "string", "label": "string", "background": "string", "color": "string", "border": { "color": "string", "width": 1 }, "font": "string", "fontSize": 12, "fontWeight": 400, "radius": 0, "paddingY": 4, "paddingX": 8, "mobile": { "fontSize": 12, "paddingY": 4, "paddingX": 8 } }, { "key": "string", "label": "string", "background": "string", "color": "string", "border": { "color": "string", "width": 1 }, "font": "string", "fontSize": 12, "fontWeight": 400, "radius": 0, "paddingY": 4, "paddingX": 8, "mobile": { "fontSize": 12, "paddingY": 4, "paddingX": 8 } }, { "key": "string", "label": "string", "background": "string", "color": "string", "border": { "color": "string", "width": 1 }, "font": "string", "fontSize": 12, "fontWeight": 400, "radius": 0, "paddingY": 4, "paddingX": 8, "mobile": { "fontSize": 12, "paddingY": 4, "paddingX": 8 } } ], "footer": { "companyName": "string", "postalAddress": "string", "note": { "property1": "string", "property2": "string" } }, "socials": { "links": [ { "network": "instagram", "url": "http://example.com" } ], "iconStyle": "color" } }, "brandKitVersionId": "3b9a8a08-c7ae-486b-89c3-d6e86a124ded", "assetUrls": { "property1": "http://example.com", "property2": "http://example.com" }, "components": { "property1": { "description": "string", "props": [ { "type": "text", "default": "string", "key": "string", "label": "string", "description": "string", "required": true } ], "slots": [ { "key": "string", "label": "string", "min": 0, "max": 1 } ], "body": { "kind": "nodes", "nodes": [ { "id": "string", "name": "string", "visibility": { "locales": [ "string" ], "hideOn": "mobile" }, "repeat": { "over": "string", "as": "string", "limit": 1 }, "type": "heading", "level": 1, "text": { "property1": { "type": "doc", "content": [ { "type": "paragraph", "content": [ { "type": "text", "text": "string", "marks": [ { "type": "bold" } ] } ] } ] }, "property2": { "type": "doc", "content": [ { "type": "paragraph", "content": [ { "type": "text", "text": "string", "marks": [ { "type": "bold" } ] } ] } ] } }, "style": { "font": "string", "fontSize": 0, "lineHeight": 0.8, "fontWeight": 400, "color": { "token": "string" }, "align": "left" }, "padding": [ 0, 0, 0, 0 ] } ] } }, "property2": { "description": "string", "props": [ { "type": "text", "default": "string", "key": "string", "label": "string", "description": "string", "required": true } ], "slots": [ { "key": "string", "label": "string", "min": 0, "max": 1 } ], "body": { "kind": "nodes", "nodes": [ { "id": "string", "name": "string", "visibility": { "locales": [ "string" ], "hideOn": "mobile" }, "repeat": { "over": "string", "as": "string", "limit": 1 }, "type": "heading", "level": 1, "text": { "property1": { "type": "doc", "content": [ { "type": "paragraph", "content": [ { "type": "text", "text": "string", "marks": [ { "type": "bold" } ] } ] } ] }, "property2": { "type": "doc", "content": [ { "type": "paragraph", "content": [ { "type": "text", "text": "string", "marks": [ { "type": "bold" } ] } ] } ] } }, "style": { "font": "string", "fontSize": 0, "lineHeight": 0.8, "fontWeight": 400, "color": { "token": "string" }, "align": "left" }, "padding": [ 0, 0, 0, 0 ] } ] } } }, "componentNames": { "property1": "string", "property2": "string" }}Restore a template version POST
Saves a copy of an older version as the latest: the one in use.
Render a template POST
The template as a recipient would get it, in one locale: its HTML and plain text, with the published brand kit and components, and what an email sending it would be refused for there. A version (the latest when absent), and a profile to fill it in for, strictly (a variable it doesn’t have is a 422); without one, empty values show their fallbacks.