Hyper3DHyper3D Docs
API Specification

Generate Texture

Generate textures for an uploaded 3D model.

POST
/api/v2/rodin_texture_only
AuthorizationBearer <token>

In: header

Request Body

multipart/form-data

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

curl -X POST "https://example.com/api/v2/rodin_texture_only" \  -F image="[    \"string\"  ]" \  -F model="[    \"string\"  ]"
{  "error": "NO_SUCH_TASK",  "message": "Submitted.",  "uuid": "123e4567-e89b-12d3-a456-426614174000",  "submit_time": "2019-08-24T14:15:22Z",  "jobs": {    "uuids": [      "52faea01-729e-4195-85e8-6050a65315e3"    ],    "subscription_key": "string"  },  "consumed": 0.5}

Input

Upload exactly one reference image and exactly one 3D model as multipart files. Both are required.

Images are accepted as JPEG, PNG, WebP, TIFF, GIF, AVIF, HEIC, HEIF, BMP, or JPEG 2000. Models are accepted as OBJ, STL, glTF/GLB, FBX, or USDZ.

material accepts PBR, Shaded, or All and defaults to PBR. All delivers both PBR and Shaded outputs. resolution accepts Basic (2K) or High (4K) and defaults to Basic.

Examples

curl --fail-with-body --request POST 'https://api.hyper3d.com/api/v2/rodin_texture_only' \
  --header "Authorization: Bearer ${RODIN_API_KEY}" \
  --form 'image=@./reference.png' \
  --form 'model=@./model.glb' \
  --form 'material=PBR' \
  --form 'resolution=Basic'
import os
from pathlib import Path

import requests

with Path("reference.png").open("rb") as image_file, Path("model.glb").open("rb") as model_file:
    response = requests.post(
        "https://api.hyper3d.com/api/v2/rodin_texture_only",
        headers={"Authorization": f"Bearer {os.environ['RODIN_API_KEY']}"},
        files={
            "image": ("reference.png", image_file, "image/png"),
            "model": ("model.glb", model_file, "model/gltf-binary"),
        },
        data={"material": "PBR", "resolution": "Basic"},
        timeout=60,
    )
response.raise_for_status()
print(response.json())

Pricing

Every Generate Texture request costs 0.5 credits, regardless of the uploaded model, reference image, material, resolution, or other input values.

Response and errors

The successful submission response has the same identifier contract as Rodin generation: use jobs.subscription_key for status and top-level uuid for download.

{
  "message": "Submitted.",
  "uuid": "123e4567-e89b-12d3-a456-426614174000",
  "jobs": {
    "uuids": ["223e4567-e89b-12d3-a456-426614174000"],
    "subscription_key": "subscription-key-from-generation-response"
  },
  "consumed": 0.5
}

HTTP 201 means the endpoint handled the request, but the task is accepted only when error is absent or empty and the top-level uuid is non-empty. HTTP 400 indicates invalid fields or files, 401 indicates invalid authentication, and 429 indicates throttling.