Variants
Create Variants Bulk
Create multiple variants in one request (single export_type per batch).
When combine_pdf=true (Plus+ only, PDF export), renders all items into one multi-page PDF via a single Chromium print pass instead of per-item files.
post/v1/template/{template_id}/variant/bulk
Request
- Base URL: https://layerre.com (the document declares no server; this is the origin it was published from)
- URL: https://layerre.com/v1/template/{template_id}/variant/bulk
- Auth: HTTP bearer
Path parameters
template_idstring uuid required
Request body
Example request
{
"items": [
{
"overrides": [
{
"properties": {
"width": 100,
"height": 100,
"color": "#FF0000",
"text": "Hello World",
"font_size": 16,
"font_name": "Arial",
"text_direction": "rtl",
"line_spacing": 1000,
"vertical_align": "middle",
"img_url": "https://example.com/image.png",
"opacity": 1
}
}
]
}
]
}Response
Bulk variant creation completed (may be partial)
Example response
{
"results": [
{
"variant": {
"url": "https://example.com/variant.png",
"width": 800,
"height": 600,
"overrides": [
{
"properties": {
"width": 100,
"height": 100,
"color": "#FF0000",
"text": "Hello World",
"font_size": 16,
"font_name": "Arial",
"text_direction": "rtl",
"line_spacing": 1000,
"vertical_align": "middle",
"img_url": "https://example.com/image.png",
"opacity": 1
}
}
]
}
}
],
"combined_pdf": {
"variant": {
"url": "https://example.com/variant.png",
"width": 800,
"height": 600,
"overrides": [
{
"properties": {
"width": 100,
"height": 100,
"color": "#FF0000",
"text": "Hello World",
"font_size": 16,
"font_name": "Arial",
"text_direction": "rtl",
"line_spacing": 1000,
"vertical_align": "middle",
"img_url": "https://example.com/image.png",
"opacity": 1
}
}
]
}
}
}Changes
No recorded changes to this operation across all 1 revision of this API.