Search for a command to run...
This is an Enterprise only private endpoint. Checkout the Enterprise Pricing to get access.
Create multiple studio templates in a single API call. This endpoint is ideal for importing templates in bulk from external systems or migrating existing template libraries.
For detailed information about the template data structure, see Anatomy of a Template.
https://api.orshot.com/v1/studio/templates/bulk-createawait fetch("https://api.orshot.com/v1/studio/templates/bulk-create", {
method: "POST",
headers: {
"Content-Type": "application/json",
Authorization: "Bearer <ORSHOT_API_KEY>",
},
body: JSON.stringify({
templates: [
{
name: "Instagram Post - Square",
description: "1:1 aspect ratio for Instagram feed",
canvas_width: 1080,
canvas_height: 1080
},
{
name: "Instagram Story",
description: "9:16 aspect ratio for Instagram stories",
canvas_width: 1080,
canvas_height: 1920
},
{
name: "Facebook Cover",
description: "Facebook page cover photo",
canvas_width: 820,
canvas_height: 312
},
{
name: "Twitter Header",
description: "Twitter profile header image",
canvas_width: 1500,
canvas_height: 500
},
{
name: "LinkedIn Banner",
description: "LinkedIn company page banner",
canvas_width: 1128,
canvas_height: 191
}
]
}),
});| Limit | Value |
|---|---|
| Requests per minute | 30 |
| Max templates per request | 50 |
| Parameter | Type | Required | Description |
|---|---|---|---|
templates | Array | Yes | Array of template objects to create |
Each template in the templates array should include:
| Field | Type | Required | Description |
|---|---|---|---|
name | String | Yes | Name of the template (max 255 characters) |
description | String | No | Description of the template |
canvas_width | Integer | Yes | Width of the canvas in pixels (1-5000) |
canvas_height | Integer | Yes | Height of the canvas in pixels (1-5000) |
pages_data | Array | No | Array of page objects with elements |
thumbnail_url | String | No | URL to a thumbnail image |
| Field | Type | Description |
|---|---|---|
success | Boolean | Whether the operation completed (may be partial success) |
created | Integer | Number of templates successfully created |
failed | Integer | Number of templates that failed validation |
templates | Array | Array of successfully created template summaries |
errors | Array | Array of error objects for failed templates (only if any failed) |
| Field | Type | Description |
|---|---|---|
index | Integer | Index of the failed template in the original array |
name | String | Name of the template that failed |
errors | Array | List of validation error messages |
You can also include full page structures with elements for each template:
await fetch("https://api.orshot.com/v1/studio/templates/bulk-create", {
method: "POST",
headers: {
"Content-Type": "application/json",
Authorization: "Bearer <ORSHOT_API_KEY>",
},
body: JSON.stringify({
templates: [
{
name: "Product Card A",
canvas_width: 800,
canvas_height: 600,
pages_data: [
{
id: "page-uuid-1",
name: "Page 1",
canvas: { width: 800, height: 600, backgroundColor: "#f5f5f5" },
elements: [
{
id: "title-1",
type: "text",
x: 50,
y: 50,
width: 700,
height: 60,
content: "Product Title",
parameterId: "title",
parameterizable: true,
},
],
},
],
},
{
name: "Product Card B",
canvas_width: 800,
canvas_height: 600,
pages_data: [
{
id: "page-uuid-2",
name: "Page 1",
canvas: { width: 800, height: 600, backgroundColor: "#ffffff" },
elements: [
{
id: "title-2",
type: "text",
x: 50,
y: 50,
width: 700,
height: 60,
content: "Product Title",
parameterId: "title",
parameterizable: true,
},
],
},
],
},
],
}),
});| Status Code | Error | Description |
|---|---|---|
| 400 | Validation failed | templates array is missing, empty, or exceeds 50 items |
| 400 | All templates failed validation | Every template in the array had validation errors |
| 403 | Access Forbidden | Invalid or missing API key |
| 429 | Rate limit exceeded | Too many requests (max 30/min) |
| 500 | Internal server error | Server-side error |
created and failed counts in the responsepages_data follows the Orshot Studio format