TRELLIS.2 4B API

TRELLIS.2 image-to-3D model that turns a reference image into a textured GLB asset with resolution, seed, mesh, texture, and export controls.

Microsoft3D GenerationNative InferenceNew

About TRELLIS.2 4B

TRELLIS.2 image-to-3D model that turns a reference image into a textured GLB asset with resolution, seed, mesh, texture, and export controls.

image to 3dglb outputpbr materialsseed controlcommercial ready

TRELLIS.2 4B specs

Model ID
trellis-2-4b
Provider
Microsoft
Category
3D Generation
Input
image
Output
3D
Endpoints
POST /v1/3d/generations

TRELLIS.2 4B API pricingSave up to 90%

Live pay-as-you-go rates from the EmpirioLabs catalog. You are billed only for what you use, with no monthly minimum.

Type
Spec
Rate
512 asset
per request
$0.25$0.025
1024 asset
per request
$0.30$0.249
1536 asset
per request
$0.499
Compare on the full pricing page

How to call the TRELLIS.2 4B API

TRELLIS.2 4B runs through POST /v1/3d/generations. The request returns a job_id right away; poll GET /v1/jobs/{job_id} until the job completes and read the output URLs from the result. Get an API key from the EmpirioLabs dashboard.

cURL: submit the job
curl https://api.empiriolabs.ai/v1/3d/generations \
  -H "Authorization: Bearer $EMPIRIOLABS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "trellis-2-4b",
    "prompt": "Describe what you want TRELLIS.2 4B to generate."
  }'
cURL: poll for the result
curl https://api.empiriolabs.ai/v1/jobs/JOB_ID \
  -H "Authorization: Bearer $EMPIRIOLABS_API_KEY"
Python
import requests

response = requests.post(
    "https://api.empiriolabs.ai/v1/3d/generations",
    headers={"Authorization": "Bearer YOUR_EMPIRIOLABS_API_KEY"},
    json={
        "model": "trellis-2-4b",
        "prompt": "Describe what you want TRELLIS.2 4B to generate.",
    },
)
job = response.json()

# Generation runs as an async job. Poll until it completes.
import time
while True:
    status = requests.get(
        f"https://api.empiriolabs.ai/v1/jobs/{job['job_id']}",
        headers={"Authorization": "Bearer YOUR_EMPIRIOLABS_API_KEY"},
    ).json()
    if status.get("status") in ("completed", "failed"):
        print(status)
        break
    time.sleep(5)
Full TRELLIS.2 4B API reference

TRELLIS.2 4B API parameters

Request parameters supported by the TRELLIS.2 4B API on EmpirioLabs. Defaults apply when a field is omitted.

ParameterTypeDefaultRange / valuesDescription
imageimage--Reference image URL, data URI, or uploaded image object.
resolutionenum1024512, 1024, 1536Voxel grid resolution. Higher values are slower and more detailed.
pipeline_typeenum1024_cascade512, 1024_cascade, 1536_cascadeExplicit TRELLIS pipeline. Leave on 1024 cascade unless you need the 512 or 1536 path.
seedinteger420 to 2147483647Random seed for reproducible generations.
preprocess_imagebooleantrue-Remove background and normalize the reference image before generation.
max_num_tokensinteger491521024 to 131072Maximum sparse tokens used for cascade generation.
ss_sampling_stepsinteger121 to 64Sampler steps for sparse structure generation.
ss_guidance_strengthnumber7.50 to 20Guidance strength for sparse structure generation.
ss_guidance_rescalenumber0.70 to 2Guidance rescale for sparse structure generation.
ss_guidance_interval_startnumber0.60 to 1Start of the sparse-structure guidance interval.
ss_guidance_interval_endnumber10 to 1End of the sparse-structure guidance interval.
ss_rescale_tnumber50 to 20Rescale temperature for sparse structure generation.
shape_slat_sampling_stepsinteger121 to 64Sampler steps for shape structured latent generation.
shape_slat_guidance_strengthnumber7.50 to 20Guidance strength for shape structured latent generation.
21 more parameters in the docs

Good to know

Defaults

  • 1024 cascade pipeline
  • 12 sampler steps per stage
  • 2048 texture size
  • 500k decimation target
  • GLB output

Controls

Supports image URL or upload, 512/1024/1536 resolution, seed, pipeline type, sampler guidance/interval/rescale controls, texture size, mesh decimation, remeshing, UV unwrap tuning, and URL or base64 output. Billing is per generated 3D asset.

TRELLIS.2 4B API: common questions

How much does the TRELLIS.2 4B API cost?

On EmpirioLabs, TRELLIS.2 4B is billed pay as you go: 512 asset $0.025 (was $0.25) per request; 1024 asset $0.249 (was $0.30) per request; 1536 asset $0.499 per request. The live rate card on this page always matches what the API charges.

Which endpoint does TRELLIS.2 4B use?

TRELLIS.2 4B is served through POST /v1/3d/generations on api.empiriolabs.ai with standard bearer-token authentication.

Can I try TRELLIS.2 4B in the browser before integrating?

Yes. The EmpirioLabs playground runs TRELLIS.2 4B in the browser with the same parameters the API exposes, so you can test prompts before writing code.

How do I get a TRELLIS.2 4B API key?

Create an EmpirioLabs account, then generate a key under API Keys in the dashboard. Billing is pay-as-you-go credits, so you only pay for the requests you make.

Ready to use better endpoints?

Explore our models, or contact us about business inquiries, custom deployments, or anything else.