bakeboolean
Bake advanced materials into the textures.
Predefinito: true
tripo3d/tripo/convertTripo Convert exports a 3D model to GLTF, FBX, USDZ, OBJ, STL or 3MF, with optional quad remesh, scaling and texture settings.
Prova il modello
Il tuo output apparirà qui
Completa gli input, poi fai clic su Esegui.
Tripo Convert exports a 3D model to GLTF, FBX, USDZ, OBJ, STL or 3MF, with optional quad remesh, scaling and texture settings.
| Field | Type | Default | Notes |
|---|---|---|---|
model_url | string, required | — | URL of the input 3D model (GLB, GLTF, FBX, OBJ or STL, up to 150 MB). |
format | GLTF / FBX / USDZ / OBJ / STL / 3MF, required | FBX | Output format. |
quad | boolean | false | Quad remesh (10,000 faces when face_limit is unset). Forces FBX. |
force_symmetry | boolean | false | Symmetric quad mesh. Only with quad. |
face_limit | integer | — | Target face count. Original when unset. |
texture_size | integer | 4096 | Texture size in pixels. |
texture_format | JPEG / PNG / WEBP / BMP / DPX / HDR / OPEN_EXR / TARGA / TIFF | JPEG | Texture image format. |
bake | boolean | true | Bake advanced materials into the textures. |
pack_uv | boolean | false | Pack all UV islands into one texture. |
export_vertex_colors | boolean | false | Vertex colors (OBJ and GLTF only). |
flatten_bottom | boolean | false | Flatten the bottom of the model. |
flatten_bottom_threshold | number | 0.01 | Depth flattened when flatten_bottom is on. |
pivot_to_center_bottom | boolean | false | Move the pivot to the bottom center. |
scale_factor | number | 1 | Uniform scale. |
with_animation | boolean | true | Keep animations. |
animate_in_place | boolean | false | Remove root motion from animations. |
part_names | array | — | Only process these parts (node names from a segmentation, e.g. tripo_part_0). All parts when unset. |
export_orientation | +x / -x / +y / -y | — | Forward axis of the exported model. |
fbx_preset | blender / 3dsmax / mixamo / bake_scale | blender | FBX target application. |
texture_packaging | embedded / zip | embedded | FBX only: embedded textures, or a zip with the FBX and a .fbm folder. |
url: Converted model file (a .zip when texture_packaging is zip).$0.05 per conversion; $0.10 when any of quad, face_limit, flatten_bottom, flatten_bottom_threshold, texture_size, texture_format, pivot_to_center_bottom or scale_factor is not the default. Failed runs are not charged.
Inizia a costruire
Scegli una delle API supportate con autenticazione unificata e tracciamento dell'utilizzo.
# The quoted heredoc keeps Unicode and shell metacharacters unchanged.
result=$(curl --fail-with-body --silent \
-X POST "https://api.sandbase.ai/v1/run" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
--data-binary @- <<'SANDBASE_JSON'
{
"model": "tripo3d/tripo/convert",
"bake": true,
"quad": false,
"format": "FBX",
"pack_uv": false,
"model_url": "https://static.sandbase.ai/examples/tripo3d/tripo/shared/object.glb",
"fbx_preset": "blender",
"scale_factor": 1,
"texture_size": 4096,
"flatten_bottom": false,
"force_symmetry": false,
"texture_format": "JPEG",
"with_animation": true,
"animate_in_place": false,
"texture_packaging": "embedded",
"export_vertex_colors": false,
"pivot_to_center_bottom": false,
"flatten_bottom_threshold": 0.01
}
SANDBASE_JSON
)
run_id=$(printf '%s' "$result" | jq -r .id)
for attempt in $(seq 1 120); do
status=$(printf '%s' "$result" | jq -r .status)
case "$status" in completed|failed|timeout) break ;; esac
sleep 2
result=$(curl --fail-with-body --silent \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
"https://api.sandbase.ai/v1/run/$run_id")
done
status=$(printf '%s' "$result" | jq -r .status)
[ "$status" = completed ] || { echo "Generation ended: $status" >&2; exit 1; }
printf '%s\n' "$result"Crea una SandBase API key e impostala nell'ambiente del server. Tutte le richieste usano l'autenticazione Bearer.
export SANDBASE_API_KEY="YOUR_API_KEY"Conserva la key sul server. Non esporla nel codice del browser né committarla in un repository.
Esegui POST su /v1/run con questo ID modello e i relativi input. L'esempio di richiesta sopra include invio e polling.
Usa il run ID restituito per fare polling finché lo stato non è completed, failed o timeout. Leggi l'output solo dopo completed.
curl "https://api.sandbase.ai/v1/run/$RUN_ID" \
-H "Authorization: Bearer $SANDBASE_API_KEY"Passa un URL di file accessibile pubblicamente nel campo image, video o audio del modello. I formati supportati e i limiti sono mostrati accanto a ciascun input del Playground.
Usa il controllo upload o replace sui campi immagine supportati nel Playground. I campi URL video accettano un video di driving ospitato; non implicano il supporto al caricamento video.
bakebooleanBake advanced materials into the textures.
Predefinito: true
quadbooleanQuad remesh (10,000 faces when face_limit is unset). Forces FBX.
Predefinito: false
formatstringobbligatorioOutput format.
Predefinito: "FBX"
Valori possibili: "GLTF", "FBX", "USDZ", "OBJ", "STL", "3MF"
pack_uvbooleanPack all UV islands into one texture.
Predefinito: false
model_urlstringobbligatorioURL of the input 3D model (GLB, GLTF, FBX, OBJ or STL, up to 150 MB).
face_limitintegerTarget face count. Original when unset.
Minimo: 1
fbx_presetstringFBX target application.
Predefinito: "blender"
Valori possibili: "blender", "3dsmax", "mixamo", "bake_scale"
part_namesarrayOnly process these parts (node names from a segmentation, e.g. tripo_part_0). All parts when unset.
scale_factornumberUniform scale.
Predefinito: 1
texture_sizeintegerTexture size in pixels.
Predefinito: 4096
flatten_bottombooleanFlatten the bottom of the model.
Predefinito: false
force_symmetrybooleanSymmetric quad mesh. Only with quad.
Predefinito: false
texture_formatstringTexture image format.
Predefinito: "JPEG"
Valori possibili: "JPEG", "PNG", "WEBP", "BMP", "DPX", "HDR", "OPEN_EXR", "TARGA", "TIFF"
with_animationbooleanKeep animations.
Predefinito: true
animate_in_placebooleanRemove root motion from animations.
Predefinito: false
texture_packagingstringFBX only: embedded textures, or a zip with the FBX and a .fbm folder.
Predefinito: "embedded"
Valori possibili: "embedded", "zip"
export_orientationstringForward axis of the exported model.
Valori possibili: "+x", "-x", "+y", "-y"
export_vertex_colorsbooleanVertex colors (OBJ and GLTF only).
Predefinito: false
pivot_to_center_bottombooleanMove the pivot to the bottom center.
Predefinito: false
flatten_bottom_thresholdnumberDepth flattened when flatten_bottom is on.
Predefinito: 0.01
{
"model": "tripo3d/tripo/convert",
"bake": true,
"quad": false,
"format": "FBX",
"pack_uv": false,
"model_url": "https://static.sandbase.ai/examples/tripo3d/tripo/shared/object.glb",
"fbx_preset": "blender",
"scale_factor": 1,
"texture_size": 4096,
"flatten_bottom": false,
"force_symmetry": false,
"texture_format": "JPEG",
"with_animation": true,
"animate_in_place": false,
"texture_packaging": "embedded",
"export_vertex_colors": false,
"pivot_to_center_bottom": false,
"flatten_bottom_threshold": 0.01
}Un run completato espone il risultato in output. Quanto segue è l'esempio salvato del modello, non una nuova generazione.
Non è ancora stato pubblicato alcun output di esempio. Usa Playground → Result → JSON dopo un run completato per ispezionare la risposta.
Questo modello è disponibile anche tramite la API v3 di Tripo. I corpi delle richieste, gli oggetti task e i codici di errore seguono Tripo, quindi il codice Tripo esistente funziona dopo aver cambiato l'URL base in https://api.sandbase.ai/tripo/v3 e inviato una SandBase API key come Authorization: Bearer. Le richieste vengono eseguite sul canale ufficiale di Tripo allo stesso prezzo di /v1/run.
POST https://api.sandbase.ai/tripo/v3/models/convert. model è facoltativo e seleziona la versione dell'algoritmo Tripo; se omesso, viene applicato il valore predefinito di Tripo. L'esempio di richiesta sopra, nella sezione API Tripo v3, mostra una chiamata completa.
Tripo assegna a questi input nomi diversi rispetto allo Schema qui sotto. Tutti gli altri campi mantengono il proprio nome.
| Campo dello schema | Campo Tripo |
|---|---|
model_url | input |
Gli input sono URL pubblici, come stringa o come oggetto con un campo url. Gli id task di Tripo e i valori file_token non sono ancora accettati, il caricamento dei file non è disponibile e webhook_url viene ignorato.
L'invio restituisce data.task_id. Esegui il polling finché data.status non è success, failed o cancelled. In caso di successo, data.output usa i nomi dei campi di Tripo, come model_url, e credits_consumed è l'addebito SandBase a 1 credit = $0.01.
curl "https://api.sandbase.ai/tripo/v3/tasks/$TASK_ID" \
-H "Authorization: Bearer $SANDBASE_API_KEY"POST /tripo/v3/tasks/list con {"task_ids": [...]} restituisce fino a 100 task. GET /tripo/v3/account/balance restituisce il tuo saldo SandBase in crediti.
Gli errori usano l'envelope di Tripo: {"code": 1004, "status": "error", "message": "..."}.
| code | Significato |
|---|---|
2 / 1002 | SandBase API key mancante, non valida o non autorizzata |
1003 | Il corpo non è un oggetto JSON |
1004 | Parametro mancante o non valido. Il messaggio indica il campo Tripo |
1007 / 2000 | Limite di richieste o di concorrenza raggiunto |
2001 | Task non trovato, o creato con un'altra API key |
2002 | Endpoint o funzionalità non supportati su SandBase |
2010 | Saldo SandBase insufficiente o limite di spesa della API key raggiunto |
4001 | Endpoint sconosciuto |
Quando Tripo rifiuta o fallisce un task, questo termina come failed con error_code e error_message di Tripo. I codici relativi alla tua richiesta o al contenuto vengono trasmessi invariati; i codici relativi all'account Tripo a monte sono riportati come 1000.