Templates API
Templates are pre-configured 3D models that serve as the foundation for creating products. Each template defines the shape, structure, and available texture slots for your products.
List Templates
Retrieve all available templates from your Veez.ai account.
Endpoint
GET /template/
Request Example
curl -s -H "Authorization: Bearer $VEEZAI_API_TOKEN" \
https://app.veez.ai/api/template/
Response
[
{
"id": 278,
"name": "Sachet souple San Marco",
"description": "",
"designation": "x1 250g moulu",
"date_modification": "2025-02-19 14:13:58",
"url_image": "template/278/templateImage/1101/ADCFF561AB2B5E4D6BBB97083EC8B850.png",
"lora": "unavailable"
},
{
"id": 279,
"name": "Sachet Souple",
"description": "",
"designation": "x2 250g moulu",
"date_modification": "2024-12-04 17:34:20",
"url_image": "template/279/templateImage/1102/A2AC897D07ED3F49CB38245CEAFECC68.png",
"lora": "available"
}
]
Response Fields
| Field | Type | Description |
|---|---|---|
id | integer | Unique identifier for the template |
name | string | Display name of the template |
description | string | Template description (may be empty) |
designation | string | Product designation or size information |
date_modification | string | Last modification timestamp (ISO format) |
url_image | string | Preview image URL for the template |
lora | string | LoRA availability ("available" or "unavailable") |
LoRA Availability
Templates with "lora": "available" support AI-generated predictions. Templates with "unavailable" can only be used for static 3D renders.
Get Template Details
Retrieve detailed information about a specific template, including required texture slots.
Endpoint
GET /template/{template_id}
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
template_id | integer | ✅ | The template ID from the list endpoint |
Request Example
curl -s -H "Authorization: Bearer $VEEZAI_API_TOKEN" \
https://app.veez.ai/api/template/279
Response
{
"id": 279,
"name": "Sachet Souple",
"description": "",
"designation": "x2 250g moulu",
"date_modification": "2024-12-04 17:34:20",
"url_image": "template/279/templateImage/1102/A2AC897D07ED3F49CB38245CEAFECC68.png",
"loraScene": "available",
"textures": [
{
"key": "TEX01",
"name": "Design Pack",
"required": 1
},
{
"key": "TEX02",
"name": "Couche Metal",
"required": 0
}
]
}
Additional Fields
| Field | Type | Description |
|---|---|---|
loraScene | string | LoRA scene availability ("available" or "unavailable") |
textures | array | List of texture slots for this template |
textures[].key | string | Unique identifier for the texture slot (e.g., "TEX01") |
textures[].name | string | Human-readable name for the texture slot |
textures[].required | integer | 1 if texture is required, 0 if optional |
Understanding Textures
Each template defines specific texture slots where you can apply your custom images:
Required vs Optional Textures
- Required (
required: 1): Must be provided when creating a product - Optional (
required: 0): Can be left empty for default appearance
Texture Keys
Texture keys like TEX01, TEX02 are used when creating products to specify which image goes in which slot.
Example Workflow
# 1. List templates to find one you like
curl -H "Authorization: Bearer $TOKEN" \
https://app.veez.ai/api/template/
# 2. Get template details to see required textures
curl -H "Authorization: Bearer $TOKEN" \
https://app.veez.ai/api/template/279
# 3. Create product with textures for TEX01 and TEX02
curl -X POST https://app.veez.ai/api/product/ \
-H "Authorization: Bearer $TOKEN" \
-F "template_id=279" \
-F "texture[0]=@my-design.jpg" \
-F "texture[0][key]=TEX01" \
-F "texture[1]=@metal-texture.jpg" \
-F "texture[1][key]=TEX02"
Error Responses
404 Template Not Found
{
"error": "Not Found",
"message": "Template with ID 999 does not exist"
}
401 Unauthorized
{
"error": "Unauthorized",
"message": "Invalid or missing API token"
}
Next Steps
Once you've selected a template:
- Create a Product - Apply your textures to the template
- Generate LoRA - Enable AI predictions (if supported)
- Create Predictions - Generate AI images