{"name":"3D Build API","description":"Draw it, squish it, print it. A free 3D maker that runs in the browser, built for fingers on an iPad and for AI agents over MCP.","version":"1.1.0","units":"mm","auth":"none","openapi":"https://3dbuild.thetempleofdoom.com/api/v1/openapi.json","health":"https://3dbuild.thetempleofdoom.com/api/v1/health","errors":"{\"error\": {\"code\", \"message\"}}","mcp_card":"https://3dbuild.thetempleofdoom.com/.well-known/mcp.json","llms_txt":"https://3dbuild.thetempleofdoom.com/llms.txt","endpoints":{"GET /api/v1/openapi.json":"OpenAPI 3.1 description","GET /api/v1/health":"Status and version","GET /api/v1/parts":"Part types, parameters, rules and an example","POST /api/v1/models":"Build a model from a JSON spec; returns size, download links and an editor link","GET /api/v1/models/{id}":"Look a built model up again","GET /assets/{id}/model.{stl|glb|3mf|obj}":"Download a file","GET /assets/{id}/preview.png":"Preview picture","GET /assets/{id}/views.png":"Four views: three-quarter, front, side, top"},"mcp":{"streamable_http":"https://3dbuild.thetempleofdoom.com/mcp","sse":"https://3dbuild.thetempleofdoom.com/sse","connect":{"mcpServers":{"build3d":{"type":"http","url":"https://3dbuild.thetempleofdoom.com/mcp"}}},"tools":[{"name":"list_parts","description":"Returns every part type the 3D builder knows (box, cylinder, gear, extrude, revolve, ...) with its parameters, units and defaults, plus the placement rules and a worked example. Call this once before build_model."},{"name":"build_model","description":"Builds a real 3D asset from a list of simple parts (placed, rotated, cut, reshaped) at true millimetre scale and returns a four-view picture plus download links for STL, GLB, 3MF and OBJ, and a link that opens the model in the 3D Build editor. To make \"a mug\" or \"a toy rocket\", break it into parts yourself. The result is a watertight solid suitable for 3D printing. Look at the preview and call again with a corrected spec if it is not right."},{"name":"get_model","description":"Returns the size, download links, four-view picture and the original parts spec of a model built earlier with build_model, so it can be changed and rebuilt."}]},"rules":["All sizes are millimetres. Z is up; the floor is z = 0. X is left-right, Y is front-back.","Each part has a \"type\" plus its size parameters written straight on the part (for example {\"type\":\"box\",\"w\":40,\"d\":20,\"h\":10}). Missing parameters use the defaults.","\"at\": [x, y] puts the centre of the part there and rests it on the floor. \"at\": [x, y, z] puts the centre of the part at that exact point (use this to stack parts or float them).","\"rotate\": [rx, ry, rz] turns the part in degrees about X, then Y, then Z, before it is placed. Cylinders, cones and tubes stand along Z; rotate [90,0,0] lays them along Y, [0,90,0] along X.","\"op\": \"add\" (default) adds a part. \"cut\" removes this shape from every earlier part (or only from the one named in \"target\"). \"intersect\" keeps only the overlap. Parts are processed in order.","\"reshape\": [{\"kind\":\"twist\",\"amount\":90}] twists (degrees over the height), \"taper\" scales the top (0.05-3, 1 = unchanged), \"bend\" bends over (degrees, -180 to 180), \"bulge\" swells the middle (-0.9 to 2).","\"round_edges\": 2 rounds every edge of a simple part by 2 mm. \"hollow\": {\"wall\":2,\"open\":true} makes a cup. Both only work on low-detail parts (boxes, plates, prisms, low quality cylinders).","\"color\" is a hex colour like \"#ff8800\" or a name (red, orange, yellow, green, blue, purple, pink, brown, black, white, grey, cyan, teal, gold, silver). \"name\" labels the part.","Top level: \"name\", \"join\": true to merge everything into one printable solid, \"quality\": \"low\" | \"medium\" | \"high\" (roundness), \"formats\": any of stl, glb, 3mf, obj (default all).","STL, 3MF and OBJ are written in mm, Z up. GLB is written in metres, Y up (the glTF standard) unless \"glb_units\": \"mm\".","\"scale\": 1.5 or [sx, sy, sz] stretches a part (a sphere with scale [1,1,0.5] is a flattened ball). \"mirror\": \"x\" adds a mirrored twin across the plane x = 0 (also \"y\", \"z\", or \"xy\" for four copies).","\"repeat\": {\"count\": 6} makes 6 copies evenly round the Z axis through the origin (place the first one off-centre with \"at\"); add \"angle\": 180 to spread them over part of a circle. \"repeat\": {\"count\": 4, \"step\": [20, 0, 0]} makes a straight row. Mirror and repeat also work on cut parts (bolt circles, rows of slots).","Type \"text\" makes raised stroke lettering (capitals, digits and - . ! + / :): {\"type\":\"text\",\"text\":\"MAX\",\"size\":12,\"h\":2,\"at\":[0,0,5]}. Sit it on a surface, or use \"op\":\"cut\" to engrave. Letters lie flat reading along +X; rotate [90,0,0] stands them upright facing the front.","Type \"hull\" wraps a smooth skin round several parts: {\"type\":\"hull\",\"of\":[{\"type\":\"sphere\",\"d\":30,\"at\":[0,0,15]},{\"type\":\"sphere\",\"d\":12,\"at\":[40,0,6]}]} gives a teardrop body. Use it for organic, blended or tapered shapes.","The picture returned by build_model has four views: top-left three-quarter view, top-right front (camera on -Y looking along +Y, X to the right), bottom-left right side (camera on +X, Y to the right), bottom-right top (X right, Y up). Check all four before telling the user it is done.","Limits: 60 parts, 2000 mm per size, 400 000 triangles, 30 s per build."],"example":{"name":"Mug","join":true,"parts":[{"type":"cylinder","d":80,"h":95,"name":"body"},{"type":"cylinder","d":72,"h":95,"at":[0,0,51.5],"op":"cut"},{"type":"torus","d":60,"t":10,"rotate":[90,0,0],"at":[44,0,48]},{"type":"cylinder","d":71,"h":90,"at":[0,0,50],"op":"cut"}]},"more_examples":[{"name":"Name plate","parts":[{"type":"plate","w":70,"d":24,"h":3,"round":4,"color":"blue","name":"plate"},{"type":"text","text":"MAX","size":12,"h":1.5,"at":[0,0,3.75],"color":"white"},{"type":"cylinder","d":4,"h":10,"at":[30,0,1.5],"op":"cut","target":"plate","mirror":"x"}]},{"name":"Wheel","join":true,"parts":[{"type":"revolve","points":[[4,0],[30,0],[32,2],[32,10],[30,12],[4,12]],"name":"wheel"},{"type":"cylinder","d":10,"h":14,"at":[18,0,6],"op":"cut","repeat":{"count":5}}]},{"name":"Toy fish","parts":[{"type":"hull","color":"orange","name":"body","of":[{"type":"sphere","d":30,"scale":[1,0.6,1],"at":[0,0,20]},{"type":"sphere","d":8,"at":[38,0,20]}]},{"type":"extrude","points":[[0,0],[16,12],[16,-12]],"h":3,"rotate":[90,0,0],"at":[46,0,20],"color":"orange"},{"type":"sphere","d":5,"at":[-9,8,24],"color":"black","mirror":"y"}]}],"spec_schema":{"type":"object","required":["parts"],"additionalProperties":true,"properties":{"name":{"type":"string","description":"Short name for the model, used as its title."},"parts":{"type":"array","minItems":1,"maxItems":60,"description":"The parts, in build order. Sizes in mm, Z up, floor at z = 0. Call list_parts first for every type and its parameters.","items":{"type":"object","required":["type"],"additionalProperties":true,"properties":{"type":{"type":"string","description":"Part type: box, cylinder, sphere, cone, torus, wedge, tube, plate, pyramid, prism, dome, capsule, star, heart, gear, arch, stairs, extrude, revolve, text or hull. Size parameters (w, d, h, ...) go directly on the part."},"at":{"type":"array","items":{"type":"number"},"minItems":2,"maxItems":3,"description":"[x, y] = centre here, resting on the floor. [x, y, z] = centre of the part at this exact point."},"rotate":{"type":"array","items":{"type":"number"},"minItems":3,"maxItems":3,"description":"Degrees about X, Y, Z (applied in that order) before placing."},"op":{"type":"string","enum":["add","cut","intersect"],"description":"add (default), cut this shape out of earlier parts, or keep only the overlap."},"target":{"type":"string","description":"For cut/intersect: the name of the one earlier part to affect. Omit to affect all earlier parts."},"name":{"type":"string","description":"Label for this part."},"color":{"type":"string","description":"Hex colour (#rrggbb) or a simple colour name."},"reshape":{"type":"array","description":"Whole-part deformations applied in order.","items":{"type":"object","required":["kind","amount"],"properties":{"kind":{"type":"string","enum":["twist","taper","bend","bulge"],"description":"Which deformation."},"amount":{"type":"number","description":"twist/bend: degrees. taper: top scale 0.05-3. bulge: -0.9 to 2."}}}},"scale":{"description":"Stretch factor: one number, or [sx, sy, sz].","anyOf":[{"type":"number"},{"type":"array","items":{"type":"number"},"minItems":3,"maxItems":3}]},"mirror":{"type":"string","description":"Also add a mirrored twin across x = 0 (\"x\"), y = 0 (\"y\"), z = 0 (\"z\"), or several (\"xy\")."},"repeat":{"type":"object","description":"Copies: {\"count\": n} evenly round the Z axis, optional \"angle\" (degrees, default 360); or {\"count\": n, \"step\": [dx, dy, dz]} for a straight row.","properties":{"count":{"type":"integer","description":"Total number of copies including the first (1-72)."},"angle":{"type":"number","description":"Total sweep in degrees for copies round the Z axis."},"step":{"type":"array","items":{"type":"number"},"description":"Offset between copies in mm for a straight row."}}},"text":{"type":"string","description":"For type \"text\": the words (capitals, digits, - . ! + / :), up to 40 characters."},"of":{"type":"array","description":"For type \"hull\": the 2-12 parts to wrap a smooth skin around.","items":{"type":"object"}},"round_edges":{"type":"number","description":"Round all edges by this many mm (simple parts only)."},"hollow":{"type":"object","description":"Hollow the part out (simple parts only).","properties":{"wall":{"type":"number","description":"Wall thickness in mm."},"open":{"type":"boolean","description":"Leave the top open, like a cup. Default true."}}},"points":{"type":"array","description":"For extrude: outline [[x,y],...] in mm. For revolve: half profile [[radius,height],...].","items":{"type":"array","items":{"type":"number"}}}}}},"join":{"type":"boolean","description":"Merge all parts into one solid (best for 3D printing). Default false keeps parts and colours separate."},"quality":{"type":"string","enum":["low","medium","high"],"description":"How smooth round shapes are. Default medium."},"formats":{"type":"array","items":{"type":"string","enum":["stl","glb","3mf","obj"]},"description":"Which files to write. Default all four."},"glb_units":{"type":"string","enum":["m","mm"],"description":"GLB scale: metres (standard, default) or raw mm."}}}}