Tripo H3.1
This guide shows how to generate 3D assets using the Tripo H3.1 model via the Leonardo.AI REST API.
Sample Request
curl --request POST \
--url https://cloud.leonardo.ai/api/rest/v2/generations \
--header 'accept: application/json' \
--header 'authorization: Bearer <YOUR_API_KEY>' \
--header 'content-type: application/json' \
--data '
{
"model": "tripo3d/tripo-h3.1",
"public": false,
"parameters": {
"prompt": "A weathered wooden treasure chest with iron fittings and a brass lock",
"quantity": 1,
"output_format": "glb",
"geometry_resolution": "standard",
"should_texture": true,
"texture_quality": "hd",
"enable_pbr": true,
"seed": 12345
}
}
'API Request Endpoint, Headers, Parameters
Endpoint
https://cloud.leonardo.ai/api/rest/v2/generationsHeaders
--header "accept: application/json" \
--header "authorization: Bearer <YOUR_API_KEY>" \
--header "content-type: application/json"Body Parameters
| Parameter | Type | Definition |
|---|---|---|
enable_pbr | boolean | Adds metallic, roughness, and normal maps for physically based rendering. Applies only when should_texture is true. Default is true. |
geometry_resolution | string | Geometry detail level. Valid values are standard and detailed (captures finer surface detail). Default is standard. |
guidances.image_reference | array | Reference images of the object to generate. Maximum 4 items. Each item includes an image object and an optional order (integer, minimum 0). image.type accepts UPLOADED, GENERATED, VARIATION, URL, or BASE64. Use image.id for UPLOADED, GENERATED, and VARIATION, image.url for URL, and image.data (base64-encoded image bytes) for BASE64. |
model | string | Specifies the model used for generation. Set to tripo3d/tripo-h3.1. |
output_format | string | Mesh file format for the generated 3D asset. Set to glb. |
prompt | string | Describes the object to generate. Required when no image references are provided. Not used when image references are provided. Maximum 1024 characters. |
public | boolean | Controls whether the generated asset is public (true) or private (false). |
quantity | integer | Number of assets generated per request. Set to 1. |
seed | integer | Seed value for generation. Range: 0–2147483647. |
should_texture | boolean | Adds a texture to the generated mesh. When false, the mesh is untextured geometry. Default is true. |
texture_quality | string | Resolution of the texture. Valid values are standard and hd (sharper, more detailed texture). Applies only when should_texture is true. Default is standard. |
Constraints
promptis required whenguidances.image_referenceis not provided, and accepts up to 1024 characters.promptis not used whenguidances.image_referenceis provided.guidances.image_referenceaccepts up to 4 reference images per request.quantityis fixed at1. Only a single asset is generated per request.output_formatis fixed atglb.seedaccepts values from0to2147483647.texture_qualityandenable_pbrapply only whenshould_textureistrue.
Updated about 11 hours ago
Did this page help you?
