STL mesh check: open edges, non-manifold edges, inverted normals
Checks a binary or ASCII STL mesh of up to 4000 triangles for a 3D-printing or CAD agent: open (boundary) edges, edges shared by more than two triangles, inconsistent winding, degenerate and duplicate triangles, normals that disagree with the vertex order, and an inside-out (negative signed volume) closed mesh, with triangle indices as witnesses. Input is base64 of the STL file (up to 200084 bytes). It does not measure wall thickness, repair the mesh, check self-intersections, or know the model units; a pass means closed, manifold, consistently wound and outward-facing, not printable.
What you get
A slicer failing on a non-manifold edge after a ten-minute export costs a retry loop; this names the edge and triangle first.
Call it
Send the JSON body below to https://agents.writerslogic.com/api/v1/mesh-check. An unpaid request answers 402 with the price and how to pay; a request that fails with a 5xx status is not charged.
curl -i -X POST https://agents.writerslogic.com/api/v1/mesh-check \
-H 'content-type: application/json' \
-d '{"data":"c29saWQgdGV0cmEKZmFjZXQgbm9ybWFsIDAgMCAtMQogb3V0ZXIgbG9vcAogIHZlcnRleCAwIDAgMAogIHZlcnRleCAwIDEgMAogIHZlcnRleCAxIDAgMAogZW5kbG9vcAplbmRmYWNldApmYWNldCBub3JtYWwgLTEgMCAwCiBvdXRlciBsb29wCiAgdmVydGV4IDAgMCAwCiAgdmVydGV4IDAgMCAxCiAgdmVydGV4IDAgMSAwCiBlbmRsb29wCmVuZGZhY2V0CmZhY2V0IG5vcm1hbCAwIC0xIDAKIG91dGVyIGxvb3AKICB2ZXJ0ZXggMCAwIDAKICB2ZXJ0ZXggMSAwIDAKICB2ZXJ0ZXggMCAwIDEKIGVuZGxvb3AKZW5kZmFjZXQKZmFjZXQgbm9ybWFsIDAuNTc3MzUwIDAuNTc3MzUwIDAuNTc3MzUwCiBvdXRlciBsb29wCiAgdmVydGV4IDEgMCAwCiAgdmVydGV4IDAgMSAwCiAgdmVydGV4IDAgMCAxCiBlbmRsb29wCmVuZGZhY2V0CmVuZHNvbGlkIHRldHJhCg=="}'
Input
| Field | Type | Required | Description |
|---|---|---|---|
data | string; length 0..266780 | yes | Padded base64 of the STL file, binary or ASCII. |
weldTolerance | number; 0..1 | no | Vertices closer than this (grid-snapped, model units) are treated as the same vertex. Default 0: exact float32 equality. |
Example request body
{
"data": "c29saWQgdGV0cmEKZmFjZXQgbm9ybWFsIDAgMCAtMQogb3V0ZXIgbG9vcAogIHZlcnRleCAwIDAgMAogIHZlcnRleCAwIDEgMAogIHZlcnRleCAxIDAgMAogZW5kbG9vcAplbmRmYWNldApmYWNldCBub3JtYWwgLTEgMCAwCiBvdXRlciBsb29wCiAgdmVydGV4IDAgMCAwCiAgdmVydGV4IDAgMCAxCiAgdmVydGV4IDAgMSAwCiBlbmRsb29wCmVuZGZhY2V0CmZhY2V0IG5vcm1hbCAwIC0xIDAKIG91dGVyIGxvb3AKICB2ZXJ0ZXggMCAwIDAKICB2ZXJ0ZXggMSAwIDAKICB2ZXJ0ZXggMCAwIDEKIGVuZGxvb3AKZW5kZmFjZXQKZmFjZXQgbm9ybWFsIDAuNTc3MzUwIDAuNTc3MzUwIDAuNTc3MzUwCiBvdXRlciBsb29wCiAgdmVydGV4IDEgMCAwCiAgdmVydGV4IDAgMSAwCiAgdmVydGV4IDAgMCAxCiBlbmRsb29wCmVuZGZhY2V0CmVuZHNvbGlkIHRldHJhCg=="
}
Result
The response is { "data": ..., "_provenance": ... }. data carries these fields; _provenance is a signed W3C Verifiable Credential with a C2PA-style manifest, checked free at POST /api/v1/verify-provenance.
| Field | Type | Required | Description |
|---|---|---|---|
status | string; one of "pass", "fail", "unknown", "unsupported" | no | pass: every rule held. fail: a rule was violated (see witnesses). unknown: the input lacks the evidence to decide. unsupported: outside what this engine covers. Missing evidence is never a pass. |
format | string; one of "binary", "ascii" | no | |
triangles | integer | no | |
vertices | integer | no | Distinct vertices after welding. |
edges | integer | no | |
components | integer | no | Vertex-connected shells. |
boundaryEdges | integer | no | Edges used by exactly one triangle (holes). |
nonManifoldEdges | integer | no | Edges used by more than two triangles. |
inconsistentEdges | integer | no | Edges whose two triangles traverse it in the same direction. |
degenerateTriangles | integer | no | |
duplicateTriangles | integer | no | |
flippedNormals | integer | no | Triangles whose stored normal opposes the right-hand-rule normal. |
zeroNormals | integer | no | |
closed | boolean | no | |
eulerCharacteristic | one of | no | V - E + F. |
signedVolume | one of | no | Only for a closed mesh; negative means inside-out. |
surfaceArea | one of | no | |
bbox | one of | no | |
notes | array<string> | no | |
witnesses | array<object> | no | |
versions | object | no | Every semantic dependency of this answer (engine, tables and their as-of dates, tokenizer, calendar, rounding profile). |
limits | array<string> | no | |
deterministic | boolean | no | Always true: pure code, no model. |
Pay and connect
Available through: x402 (USDC on Base), MCP. MCP clients reach it through the infra-preflight-kit package.
Machine-readable
- This agent as JSON (schemas, example, OpenAPI operation)
- Free signed sample response
- OpenAPI 3.1 · Catalog · Index of every agent