The target model
target controls the size a template renders at. One curated template can render
into several sizes, so the same content produces an Instagram square, a story, or an
OG card without re-authoring anything.
Named sizes
Pass target as one of the named screen sizes on POST /v1/render:
target | Aspect | Typical use |
|---|---|---|
square | 1:1 | Feed posts, profile imagery |
portrait | 4:5 | Tall feed posts |
story | 9:16 | Stories / Reels / vertical |
landscape | 16:9 | Wide banners, video frames |
og | 1.91:1 | Open Graph / link-preview cards |
A template advertises which sizes it supports in its ratios array (see
Find a template). Requesting a target the template
doesn't support, or an unknown size, is rejected with 422.
curl -sS -X POST "https://api.lemtika.com/v1/render" \
-H "Authorization: Bearer $LEMTIKA_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "templateId": "tmpl_og_card", "values": { "headline": "Launch day" }, "target": "og" }' \
-o card.png
Omitting target
target is optional. Omit it to render at the template's native authored
dimensions. For the current all-square catalog, that is identical to square.
Output format
target is the size; format is the file type. format defaults to png and also
accepts pdf, jpeg, svg, and webp. For webp, an optional quality (1–100,
default 80) controls lossy compression. See Render for the
full request body.