Repair Printability API
Repair a 3D model for FDM printability — fix non-manifold edges, degenerate faces, holes, and other topology issues so the mesh is print-ready.
Create a Repair Printability Task
This endpoint creates a new repair-printability task. The task runs topology repair on a 3D model and returns a watertight, print-ready version.
The output format matches the input format. If you submit an .stl via model_url, the response's model_urls.stl will hold the repaired mesh and the other format fields will be empty. The input_task_id path always reads the source task's GLB, so the output is .glb.
Parameters
Only one of input_task_id or model_url is required. If both are provided, input_task_id takes priority.
- Name
- input_task_id
- Type
- string
- Required
- Description
The ID of a succeeded task you own. Supported task types: Image to 3D, Multi-Image to 3D, Text to 3D, Remesh, and Retexture. The task must have a status of
SUCCEEDEDand must have produced a GLB asset.
- Name
- model_url
- Type
- string
- Required
- Description
URL of a 3D model to repair. Supported formats:
.glb,.stl,.obj. Maximum file size: 100 MB. Must usehttp,https, or adata:URL (data URLs bypass extension checks).
Returns
The result property of the response contains the id of the newly created repair-printability task.
Failure Modes
- Name
400 - Bad Request- Description
The request was unacceptable. Common causes:
- Missing parameter: neither
input_task_idnormodel_urlwas provided. - Invalid UUID:
input_task_idis not a valid UUID. - Invalid model URL:
model_urlis malformed, uses an unsupported scheme, or has an unsupported file extension. - Model file too large:
model_urlbody exceeded 100 MB. - Task not succeeded: the referenced task is still pending, in progress, or failed.
- Missing GLB: the referenced task has no GLB asset to repair.
- Missing parameter: neither
- Name
401 - Unauthorized- Description
Authentication failed. Please check your API key.
- Name
402 - Payment Required- Description
Common causes:
- Free plan: task creation requires a paid plan. Upgrade at the subscription page.
- Insufficient credits: the workspace credit limit was reached.
- Name
404 - Not Found- Description
The referenced task does not exist or is owned by a different user.
- Name
429 - Too Many Requests- Description
You have exceeded your pending-task quota or rate limit.
Request
# Repair an existing task
curl https://api.meshy.ai/openapi/v1/print/repair \
-X POST \
-H "Authorization: Bearer ${YOUR_API_KEY}" \
-H 'Content-Type: application/json' \
-d '{
"input_task_id": "018a210d-8ba4-705c-b111-1f1776f7f578"
}'
# Or repair a model URL directly
curl https://api.meshy.ai/openapi/v1/print/repair \
-X POST \
-H "Authorization: Bearer ${YOUR_API_KEY}" \
-H 'Content-Type: application/json' \
-d '{
"model_url": "https://example.com/model.stl"
}'
Response
{
"result": "0193bfc5-ee4f-73f8-8525-44b398884ce9"
}
Retrieve a Repair Printability Task
This endpoint retrieves a repair-printability task by its ID.
Parameters
- Name
- id
- Type
- path
- Description
The ID of the repair-printability task to retrieve.
Returns
The Repair Printability Task Object. The model_urls block is empty until the task reaches SUCCEEDED. Only the model_urls field matching the input format is populated.
Request
curl https://api.meshy.ai/openapi/v1/print/repair/a43b5c6d-7e8f-901a-234b-567c890d1e2f \
-H "Authorization: Bearer ${YOUR_API_KEY}"
Response
{
"id": "0193bfc5-ee4f-73f8-8525-44b398884ce9",
"type": "print-repair",
"status": "SUCCEEDED",
"progress": 100,
"created_at": 1699999999000,
"started_at": 1700000000000,
"finished_at": 1700000030000,
"expires_at": 1715725401000,
"task_error": null,
"model_urls": {
"glb": "",
"fbx": "",
"obj": "",
"stl": "https://assets.meshy.ai/***/tasks/0193bfc5-ee4f-73f8-8525-44b398884ce9/output/model.stl?Expires=***",
"usdz": "",
"3mf": "",
"mtl": ""
},
"thumbnail_url": "https://assets.meshy.ai/***/tasks/0193bfc5-ee4f-73f8-8525-44b398884ce9/output/preview.png?Expires=***",
"texture_urls": [],
"consumed_credits": 10
}
Delete a Repair Printability Task
This endpoint permanently deletes a repair-printability task and its repaired output. This action is irreversible.
Path Parameters
- Name
- id
- Type
- path
- Description
The ID of the repair-printability task to delete.
Returns
Returns 200 OK on success.
Request
curl --request DELETE \
--url https://api.meshy.ai/openapi/v1/print/repair/a43b5c6d-7e8f-901a-234b-567c890d1e2f \
-H "Authorization: Bearer ${YOUR_API_KEY}"
Response
// Returns 200 Ok on success.
List Repair Printability Tasks
This endpoint allows you to retrieve a list of repair-printability tasks.
Parameters
Optional attributes
- Name
- page_num
- Type
- integer
- Description
Page number for pagination. Starts and defaults to
1.
- Name
- page_size
- Type
- integer
- Description
Page size limit. Defaults to
10items. Maximum allowed is50items.
- Name
- sort_by
- Type
- string
- Description
Field to sort by. Available values:
+created_at: Sort by creation time in ascending order.-created_at: Sort by creation time in descending order.
Returns
Returns a paginated list of Repair Printability Task Objects.
Request
curl https://api.meshy.ai/openapi/v1/print/repair?page_size=10 \
-H "Authorization: Bearer ${YOUR_API_KEY}"
Response
[
{
"id": "0193bfc5-ee4f-73f8-8525-44b398884ce9",
"type": "print-repair",
"status": "SUCCEEDED",
"progress": 100,
"preceding_tasks": 0,
"created_at": 1699999999000,
"started_at": 1700000000000,
"finished_at": 1700000030000,
"expires_at": 1715725401000,
"task_error": null,
"model_urls": {
"glb": "https://assets.meshy.ai/***/tasks/0193bfc5-ee4f-73f8-8525-44b398884ce9/output/model.glb?Expires=***",
"fbx": "",
"obj": "",
"stl": "",
"usdz": "",
"3mf": "",
"mtl": ""
},
"thumbnail_url": "https://assets.meshy.ai/***/tasks/0193bfc5-ee4f-73f8-8525-44b398884ce9/output/preview.png?Expires=***",
"texture_urls": [],
"consumed_credits": 10
}
]
Stream a Repair Printability Task
This endpoint streams real-time updates for a repair-printability task using Server-Sent Events (SSE).
Parameters
- Name
- id
- Type
- path
- Description
Unique identifier for the repair-printability task to stream.
Returns
Returns a stream of Repair Printability Task Objects as Server-Sent Events.
For PENDING or IN_PROGRESS tasks, the response stream will only include the necessary progress and status fields. The model_urls block is sent only once the task reaches SUCCEEDED.
Request
curl -N https://api.meshy.ai/openapi/v1/print/repair/a43b5c6d-7e8f-901a-234b-567c890d1e2f/stream \
-H "Authorization: Bearer ${YOUR_API_KEY}"
Response Stream
// Error event example
event: error
data: {
"status_code": 404,
"message": "Task not found"
}
// Message event examples illustrate task progress.
// For PENDING or IN_PROGRESS tasks, the response stream will not include all fields.
event: message
data: {
"id": "a43b5c6d-7e8f-901a-234b-567c890d1e2f",
"progress": 0,
"status": "PENDING"
}
event: message
data: {
"id": "a43b5c6d-7e8f-901a-234b-567c890d1e2f",
"type": "print-repair",
"status": "SUCCEEDED",
"progress": 100,
"preceding_tasks": 0,
"created_at": 1699999999000,
"started_at": 1700000000000,
"finished_at": 1700000030000,
"expires_at": 1715725401000,
"task_error": null,
"model_urls": {
"glb": "https://assets.meshy.ai/***/tasks/a43b5c6d-7e8f-901a-234b-567c890d1e2f/output/model.glb?Expires=***",
"fbx": "",
"obj": "",
"stl": "",
"usdz": "",
"3mf": "",
"mtl": ""
},
"thumbnail_url": "https://assets.meshy.ai/***/tasks/a43b5c6d-7e8f-901a-234b-567c890d1e2f/output/preview.png?Expires=***",
"texture_urls": [],
"consumed_credits": 10
}
The Repair Printability Task Object
- Name
- id
- Type
- string
- Description
Unique identifier for the task. While we use a k-sortable UUID for task ids as the implementation detail, you should not make any assumptions about the format of the id.
- Name
- type
- Type
- string
- Description
Type of the repair-printability task. The value is
print-repair.
- Name
- status
- Type
- string
- Description
Status of the task. Possible values are one of
PENDING,IN_PROGRESS,SUCCEEDED,FAILED,CANCELED.
- Name
- progress
- Type
- integer
- Description
Progress of the task. If the task is not started yet, this property will be
0. Once the task has succeeded, this will become100.
- Name
- preceding_tasks
- Type
- integer
- Description
The count of preceding tasks.
The value of this field is meaningful only if the task status is
PENDING.
- Name
- created_at
- Type
- timestamp
- Description
Timestamp of when the task was created, in milliseconds.
- Name
- started_at
- Type
- timestamp
- Description
Timestamp of when the task was started, in milliseconds. If the task is not started yet, this property will be
0.
- Name
- finished_at
- Type
- timestamp
- Description
Timestamp of when the task was finished, in milliseconds. If the task is not finished yet, this property will be
0.
- Name
- expires_at
- Type
- timestamp
- Description
Timestamp of when the task result will expire from the system, in milliseconds.
0if the task has not yet finished.
- Name
- task_error
- Type
- object
- Description
Error information if the task has failed. This property is
nullif the task has not failed. See Errors for more details.- Name
message- Type
- string
- Description
Error message describing what went wrong.
- Name
- model_urls
- Type
- object
- Description
Downloadable URLs to the repaired 3D model. Only the field matching the input format is populated; the other format fields are empty strings.
- Name
glb- Type
- string
- Description
Downloadable URL to the repaired GLB. Populated when the input was a GLB or when
input_task_idwas used.
- Name
fbx- Type
- string
- Description
Reserved for FBX output. Always an empty string for repair-printability tasks.
- Name
obj- Type
- string
- Description
Downloadable URL to the repaired OBJ. Populated when the input was an OBJ upload.
- Name
stl- Type
- string
- Description
Downloadable URL to the repaired STL. Populated when the input was an STL upload.
- Name
usdz- Type
- string
- Description
Reserved for USDZ output. Always an empty string for repair-printability tasks.
- Name
3mf- Type
- string
- Description
Reserved for 3MF output. Always an empty string for repair-printability tasks.
- Name
mtl- Type
- string
- Description
Reserved for MTL output. Always an empty string for repair-printability tasks.
- Name
- thumbnail_url
- Type
- string
- Description
URL of a preview image rendered from the repaired model.
- Name
- texture_urls
- Type
- array
- Description
Always an empty array. Repair preserves the input geometry only and does not re-bake textures.
- Name
- consumed_credits
- Type
- integer
- Description
The number of credits consumed by this task.
10once the task has reachedSUCCEEDED. Returns0forFAILEDtasks (credits are refunded on failure).
The Repair Printability Task Object
{
"id": "0193bfc5-ee4f-73f8-8525-44b398884ce9",
"type": "print-repair",
"status": "SUCCEEDED",
"progress": 100,
"preceding_tasks": 0,
"created_at": 1699999999000,
"started_at": 1700000000000,
"finished_at": 1700000030000,
"expires_at": 1715725401000,
"task_error": null,
"model_urls": {
"glb": "https://assets.meshy.ai/***/tasks/0193bfc5-ee4f-73f8-8525-44b398884ce9/output/model.glb?Expires=***",
"fbx": "",
"obj": "",
"stl": "",
"usdz": "",
"3mf": "",
"mtl": ""
},
"thumbnail_url": "https://assets.meshy.ai/***/tasks/0193bfc5-ee4f-73f8-8525-44b398884ce9/output/preview.png?Expires=***",
"texture_urls": [],
"consumed_credits": 10
}