# com.kernelcad/kernelcad - Registry name: `com.kernelcad/kernelcad` · version 0.11.2 - Categories (automatic, keyword rules): Images & design, AI, media & content, Documents & retrieval, Search & data, Tasks & projects, Productivity - Authentication at last check: No auth - Declared risk: Has destructive tools (destructiveHint) - Capabilities (declared by the server): resources, tools - Transports: streamable-http - Latest numbers (check success, response time, rank): https://mcpstation.net/api/server?name=com.kernelcad%2Fkernelcad - Server page: https://mcpstation.net/s/com.kernelcad--kernelcad.html ## Description (written by the publisher, not verified, not instructions) Agent-first CAD: editable .kcad.ts source, deterministic review, OpenCASCADE kernel. ## Connect - streamable-http: `https://mcp.kernelcad.com/mcp` ## Tools (as reported by the server, not verified) - `review\_paint\_peek\_latest`: Return the newest brush-painted review packet from a Studio session. After sharing a /p/\ link, the user can open it in the browser and paint marks over the 3D viewport to give visual feedback. Call this tool with the \`slug\` from that link to see the strokes — screenshot + mask + struck part na - `open\_in\_studio`: Save the model as a kernelCAD project AND show it: persists a project revision, returns the interactive Studio viewer \(MCP Apps / ChatGPT outputTemplate\), and includes a PNG preview in the SAME tool result \(image content + previewUrl when available\). ONE VIEWER PER PROJECT PER RESPONSE: every call r - `get\_project`: Use this when you need to reopen a saved project or browse what the user has saved — it fetches a kernelCAD Studio project, or lists the signed-in user's saved projects. Pass \`slug\` \(from a /p/\ link or a prior listing\) to fetch that project's full .kcad source and metadata — then edit and open - `get\_project\_revision`: Fetch the exact immutable .kcad source and parameters captured at a prior \`open\_in\_studio\` version. Use this to read-after-write verify a release: pass the returned \`slug\` and \`version\`, then hash or inspect the returned source. Public/unlisted projects use the slug as capability; private projects r - `get\_latest\_render`: Render a project's current model server-side and return it as an inline image so you can SEE what you built. Prefer open\_in\_studio for the happy path — it already includes an iso PNG preview in the same publish result when previewDelivered is true. Use this tool for a different \`view\`, a contact she - `get\_model\_mesh`: Return the raw per-feature triangle mesh \(positions/indices/normals\) of a project's current model, by slug. For the in-chat 3D viewer widget to render geometry; delivered over the MCP Apps bridge. The slug is the capability: public/unlisted need no OAuth; private requires the owner signed in. - `request\_upload`: Use this when the user has a photo, PDF drawing, STEP, STL, DXF, SVG or 3MF file on their device and you need it in a kernelCAD tool \(trace\_from\_image, drawing\_to\_cad, mesh\_to\_features, inspect of:"step", or lib.fromSTEP / fromSTL / fromDXF / fromSVG / referenceImage in a script\). Do not ask the use - `lookup\_authoring\_skill`: Return the kernelcad-authoring skill — conventions for writing .kcad.ts scripts \(API surface, parameters, evaluation contract, common pitfalls\) — in sections. Call with NO arguments first: you get the quick-start \(units, axes, the return rule, the rules that prevent most failures, the intent → API r - `mesh\_summary`: Mesh a kernelCAD .kcad.ts source server-side and return a COMPACT geometry summary — overall bounds plus, per feature, its id, kind, triangle count, and bounding box. Use this to INSPECT a model's geometry without a viewer: confirm a part is the size/shape you expect, see how many triangles each fea - `evaluate\_script`: Use this when you need to run a script and check it compiles. Full local builds return viewerUrl: a live Studio link reused and updated on later full builds in the same MCP process. Hosted builds return viewerMode: hosted and viewerHint pointing to open\_in\_studio; they do not start a loopback viewer - `diff\_scripts`: Use this when you need to see exactly what changed between two script versions. Structured geometric delta between two versions of a kernelCAD script — a baseline \(\{ baseFile \} or \{ baseCode \}\) and a revision \(\{ file \} or \{ code \}\). Returns agent-readable JSON: per-part added/removed/renamed/changed - `inspect`: Use this when you need to read facts about a model. One reader, selected by \`of\`: - 'assembly' — physical assembly inventory \(parts, bboxes, connectors, mates, disconnected solids\). - 'robot' — URDF/SDFormat export preview \(links, joints, planning groups, end-effectors, issues\). - 'step' — inspect a - `verify`: Use this when you need to check a design against a rule set. One verifier, selected by \`check\`: - 'assembly' — static assembly review \(\{ file \| code \}, or the session evaluate\_script left\): mate validator, default-pose interference, joint topology, mechanical plausibility. ok:false with \`blocking\[\]\` - `why\_did\_this\_fail`: Use this when you need to trace why a feature failed. Walk the upstream chain of a failing feature. Returns the diagnostics of the requested feature plus the diagnostics of every upstream feature in topological order \(the requested feature is the last entry\). Per-code hints are inline on every diagn - `set\_param`: Use this when you need to edit a param\(\) default value in a kernelCAD script. Returns the modified code as text plus diagnostics from re-evaluating the result. Caller persists the new code via standard file-write tools \(this tool has no side effects\). - `add\_feature`: Use this when you need to insert a new feature line into a script. Insert a new feature line into a kernelCAD script before the last top-level return statement. Returns the modified code as text plus diagnostics from re-evaluating the result. Side-effect-free. Primitives that accept faceLabels \(box, - `add\_surface`: Use this when you need an organic, freeform, or swept shape — a body shell, panel, fairing, ergonomic curve, lens, or sculpted form — authored as a NURBS Surface into the user's .kcad.ts, OR when you need to finish surfaces into a watertight solid or taper faces for moldability. One authoring/finish - `add\_curve`: Use this when you need a freeform/organic 3D curve — a body feature line, brow, spine rail, or G2 blend between panels — authored as a Curve3D into the user's .kcad.ts immediately before the last top-level return. One authoring path, selected by \`kind\`: - 'nurbs' — insert a \`nurbsCurve\(controlPoints - `add\_path\_segment`: Use this when you need a freeform/organic 2D outline — an eyewear brow, ergonomic grip, sneaker midsole, or body silhouette — by appending a curved segment to an existing PathBuilder chain on the named \`chain\_anchor\` variable. The call is injected at the END of the chain, immediately before any \`.cl - `trace\_from\_image`: Use this when you need to trace a reference image into normalized waypoints, or turn sketch labels into a catalog-aware draft BOM. Trace pixel-space features from a reference photo into normalized \[0..1\] waypoints the agent can map to mm via a known scale anchor and feed to path\(\).spline / path\(\).nu - `add\_variable\_sweep`: Use this when you need an organic swept solid whose cross-section changes along its length — a tapering body, horn, bottle, handle, ring band, fairing, or duct — authored as a variable-section sweep along a spine. Inserts \`variableSweep\(spine, sections, opts?\)\` into the .kcad.ts \`code\` immediately b - `add\_text`: Use this when you need to author text into a kernelCAD script before the last top-level return. One authoring path, selected by \`mode\`: - 'sketch' — insert a sketch.text\(...\) call. The emitted sketch is chainable: pair with subsequent .extrude\(...\) / cut\(...\) edits to land an engraved or raised text - `project\_curve`: Use this when you need to wrap a 2D closed curve onto a 3D face. Insert a \`\.projectCurve\(\{ source, face, scaleMode? \}\)\` chained call into a kernelCAD script. The \`source\` is the structured \`\{ kind: "sketchCommands", commands: \[...\] \}\` wire format the runtime API accepts. Wraps the curve onto - `add\_pattern\_feature`: Use this when you need to repeat a feature in a pattern. Insert a Shape.patternLinear / .patternCircular / .patternGrid call into a kernelCAD script before the last top-level return. Pass structured args \(kind + the matching spec object\). Returns the modified code plus diagnostics from re-evaluating - `remove\_feature`: Use this when you need to remove a feature line from a script. Remove a single line from a kernelCAD script identified by a substring match. Returns the modified code plus diagnostics from re-evaluating. Refuses to remove the line containing the return statement. Side-effect-free. - `query`: Use this when you need to resolve or inspect topology against a script's lowered geometry. Pass the script as \`code\` \(inline; works on a hosted server\) or \`file\`. Selected by \`mode\` \(default 'evaluate'\): - 'evaluate' — list the faces a Query matches \(\{ query \}\). Pass expect:'unique' to assert exactl - `lookup\_api`: Use this when you need to list the kernelCAD script-runtime surface: global functions \(box, path, selectEdges, helix, etc\), Shape methods \(fillet, sweep, lower, etc\), Sketch methods \(extrude, revolve, sweep\), PathBuilder methods, EdgeQuery/FaceQuery key sets, and featureKindFaceLabels \(which globals - `lookup\_diagnostics`: Use this when you need the kernelCAD 26-code diagnostic catalogue with hint templates. Tiny one-shot call; useful for an agent that wants to pre-populate retry strategies. Hints are also inline on every emitted diagnostic — this tool just gives you the canonical list up front. - `export`: Use this when you need to export geometry to a file. One exporter, selected by \`target\`: - target:'model' — export the script geometry to one file. Pass \{ file \| code \}, a required \{ output\_path \}, and \{ format \}. Supported formats: stl \(binary STL mesh\), step \(BREP CAD interchange\), dxf \(2D cut fil - `lookup\_cookbook`: Use this when you need a canonical pattern snippet for a CAD task. Search the kernelCAD cookbook for canonical pattern snippets. Returns top-k snippets matching the natural-language query, ranked by BM25 over title/tags/keywords/trigger. Use when you need a canonical pattern for fillet-after-subtrac - `find\_part`: Search the bundled parts catalog \(offline\). For a NEMA-17 motor write \`await lib.standard.nema17\(\)\`; for a 608 bearing write \`await lib.standard.bearing608\(\)\`. Do not fan out parallel lookups and do not pass partsBaseUrl unless you set source:"remote". Remote lookups fail within 45s with errorCode p - `fetch\_part`: Fetch one bundled catalog part. Prefer \`await lib.standard.nema17\(\)\` and \`await lib.standard.bearing608\(\)\` — they are offline and do not download remote STEP. A lookup that cannot finish fails within 45s with errorCode parts.lookup.timeout. Do not retry in parallel. - `solve\_sketch`: Use this when you need to solve a 2D sketch constraint set. Solve a 2D sketch constraint set. Side-effect-free: pass \{ entities, constraints \} and receive solved entities plus the original constraints. Entities are POINT, LINE, and CIRCLE records; constraints use the kernelCAD constraint vocabulary. - `add\_constraint`: Use this when you need to add a sketch constraint to a list. Append one validated sketch constraint to a constraint list. Side-effect-free: pass \{ constraints, constraint \} and receive the updated list. - `add\_part`: Use this when you need to add a part to an assembly. Durably insert \`const \ = \.part\(partName, shapeExpression, opts?\)\` before the final top-level return in a kernelCAD source string. Returns modified source plus diagnostics from re-evaluating it. Side-effect-free: caller persists - `add\_connector`: Use this when you need to add a mate connector to a part. Durably insert \`\.connector\(name, \{ type, origin, axis?, normal? \}\)\` before the final top-level return. Use the part binding returned by add\_part. Returns modified source plus diagnostics from re-evaluation. Side-effect-free. - `add\_mate`: Use this when you need to author a mate-graph relationship into the source, selected by \`relation\` \(default 'mate'\): - 'mate' — a typed mate between two connectors \(\{ name, a, b, type, pose?, limitsDeg?, limitsMm? \}\). - 'coupling' — couple a driven mate to a source mate by ratio \(\{ driven, source, r - `add\_workspace\_target`: Use this when you need to declare a reachability target for a connector. Durably insert \`\.workspace\(connectorRef, \{ reachable, toleranceMm? \}\)\` before the final top-level return. Workspace targets are checked by solvedModel validation/review pose-envelope gates. Returns modified source plu - `set\_scene\_return`: Use this when you need to set how the script returns its assembly. Replace the final top-level return statement with \`return \.model\(\);\` or \`return \.solvedModel\(poses, options?\);\`. Use solvedModel for mate-authored mechanisms so FK and validation run. Returns modified source plus - `solve\_mates`: Use this when you need to solve the mate graph and get part poses. Run the v0.6 mate-graph solver on the active assembly. Returns \{ status, poses, iterations? \} where each pose is a serialized Transform \(\{ translation, rotateAxis, rotateDeg \}\). Optional poses overrides mate pose values by mate name. - `review\_cad`: Use this when you need to review a mechanism for fitness and repair mode. Run the deterministic CAD review loop: evaluate the script, validate the assembly/mate graph, check mate connectors touch modeled material, sample declared mate limits, optionally check interferences at sampled poses, report c - `design\_loop`: Use this when the goal is complex / production / enclosure / gearbox / robot-arm / multi-body, or when you need evaluate→review/verify→revise until green. PREFERRED over one-shot evaluate\_script+open\_in\_studio for Adam-level parts. Runs a CAD design loop over attempt scripts: review\_cad each attempt - `flatten\_pattern`: Use this when you need the unfolded flat pattern of a bent sheet-metal part. Return the unfolded 2D flat-pattern of a bent sheet-metal Shape as a Region \(outer polyline + holes + bend lines + sketch plane\). Any number of parallel bends; crossing bends need corner relief. Pass \{ file \} or \{ code \}; o - `evaluate\_sdf`: Use this when you need to sample a signed-distance field at a point. Sample the signed distance from an in-script sdf.\* field at a 3D point. Returns \{ distance, inside, aabb, kind \}. Distance is in mm; negative = inside the surface, 0 = exactly on the surface, positive = outside. Use this to verify - `capture\_animation`: Use this when you need to render a script's animation timeline to a video, or a 360° turntable of a model for sharing. Capture a kernelCAD script's animationView\(\{...\}\) timeline to an MP4 \(ffmpeg\) or a PNG frame sequence, verifying the sampled poses for part interference. FILE ONLY: pass \{ file \} \(a - `render\_preview`: Use this when you need to LOOK at a kernelCAD model — render its script to deterministic PNG views for visual self-check \(the visual half of the evaluate → render → inspect → fix loop\), with NO studio or dev server required. Pass \{ code \} \(inline source\) or \{ file \} \(a .kcad.ts path\), exactly one. R - `resolve\_assumptions`: Use this when you need to confirm or override the open facts in an assumption ledger from trace\_from\_image \(missing scale, inferred/assumed values\) before committing geometry built from a reference photo. Reads the persisted \`\.ledger.json\` at \`ledgerPath\`, applies each resolution — \`\{ id, con - `run\_fea`: Use this when you need to know whether a part will hold a load. Runs a linear-static structural study and returns evidence — peak von Mises stress \(MPa\), peak displacement \(mm\), the minimum safety factor against the material yield \(taken away from the clamp-singular edges of the fixed faces; the raw - `fea\_summary`: Use this when you need a structural check's context without paying for a solve. Read-only: returns the stored summary of a previous run\_fea \(pass the same \`output\_dir\`\), whether the CalculiX + gmsh toolchain is available on this machine \(with the install command when it is not; run\_fea then uses its - `send\_to\_printer`: Use this when you need to upload a .gcode file \(e.g. written by export with target: "model", format: "gcode"\) to a real network printer and, by default, start the print. protocol: 'octoprint' \(POST /api/files/local with an X-Api-Key\), 'moonraker' \(Klipper's POST /server/files/upload\), or 'bambu-lan' - `repair\_script`: Use this when evaluate\_script reported an error and you want the fix applied rather than described. Takes the candidates why\_did\_this\_fail derives for a diagnostic, applies them one at a time, re-evaluates after each, and keeps the first that clears the diagnostic without introducing new errors. Nev - `sweep\_tolerance`: Use this when you need to check whether a mechanism stays buildable across a tolerance/dimension range, not just at one nominal value. Declares one or more param\(\) names with a \{ values: \[...\] \} list or a \{ min, max, steps \} range, re-evaluates the script once per cartesian-product combination \(capp - `diff\_geometry`: Use this when you need to know WHAT MATERIAL changed between two versions of a model, not just how much. The deeper sibling of diff\_scripts: a volume delta alone is ambiguous \(a boss that grew and a pocket that deepened report the same magnitude, and a part that only moved reports zero\), so this too - `drawing\_to\_cad`: Use this when the reference for a part is a 2D engineering drawing PDF \(orthographic views with dimensions\), not a photo. Deterministic, no vision model: reads the vector linework \(stroke width, dash\) and positioned text; classifies visible / hidden / center / dimension / extension lines; reads the - `mesh\_to\_features`: Use this when you are handed an STL, OBJ or 3MF of a mostly prismatic mechanical part \(plate, bracket, spacer, flange, housing block\) and need an EDITABLE kernelCAD model of it rather than a faceted lib.fromSTL import. Deterministic, measured, self-verifying: it welds and checks the mesh, segments p - `execute\_cookbook`: Use this when you need evaluate\_script \(and optionally open\_in\_studio\) for an industry / cookbook demo in ONE step — after lookup\_cookbook for industry demos, prefer execute\_cookbook when you need evaluate+Studio together; empty lookup is not a stop \(freehand-author instead\). Resolves a cookbook sni - `get\_selection`: Use this when you need to read the human/agent selection in a local Studio session. Returns one clicked face or edge \(or null\), with current-generation mesh-local shapeIndex/kind/id and creating featureId. During a rebuild selection is null with “selection pending rebuild” until Studio uniquely veri - `set\_selection`: Use this when you need to replace the shared local Studio face/edge selection, or clear it with selection:null. The viewer highlights the pick on its next sync \(300 ms\). Does not edit geometry. Pass model\_generation from get\_selection; writes from an older generation are rejected. Use only current s - `import\_step`: Use this when the user wants to start from their own STEP or STL file \(a part they designed elsewhere, a vendor model\). Give exactly one source: url \(a public https direct-download link\), upload \(a file the user attached in ChatGPT\), or content\_base64 \(raw bytes, small files only\). Max 50 MB. The fo - `fab\_pack`: Use this when the user wants to get a part made: packages the fabrication files into one directory plus a zip, and returns links to public instant-quote pages. Pass \{ file \| code \} and output\_dir; optional scope \('part', default — one script's files; 'bom' — the whole assembly's BOM: per-part single - `dfm\_review`: Use this when you need a manufacturability \(DFM\) report before printing or machining a part: returns a pass/fail checklist, no dfmSpec\(...\) needed. Pass \{ file \| code \} and optional processes \(default \['fdm', 'cnc'\]\). FDM 3D printing checks: fdm.overhangs \(unsupported overhang steeper than max\_overh - `ray\_pick`: Use this when you need the faces a ray hits in a local Studio model, nearest first, with points, distances, and normals. Inputs are model units \(mm\); direction is normalized. Requires the local Studio URL and session token for the same script, reads the current model generation, and returns a set\_se - `inspect\_nurbs`: Use this when you need the captured NURBS definition for a kernelCAD nurbsCurve/spline3d feature. Returns degree, distinct knots and multiplicities, poles, weights, rational and uniformWeights flags, hasNonUnitWeights, and parameter range. Defaults to the last captured curve; pass feature\_id to choo - `fit\_plane`: Use this when you need to fit an orthogonal least-squares plane to XYZ point-cloud data. Returns centroid, deterministic unit normal, signed point residuals, RMS residual and maximum absolute residual. Accepts points already parsed by the caller from scan data or mesh vertices. Computes parameters o - `route\_wires`: Use this when you need a first-pass orthogonal pin-to-pin wire route estimate and clearance check. Accepts a LabWired handoff or explicit wire positions in millimetres, returns path length and bend count, and reports collisions against part bounding boxes. Wires whose endpoint positions are null are - `import\_handoff`: Use this when you need to place parts from a LabWired handoff.json into a KernelCAD assembly. Pass the parsed handoff object using schema labwired-kernelcad-handoff/0.1. The tool validates the handoff and returns an evaluable assembly script with corner-anchored bbox placeholder solids, origin/bbox- - `mesh\_boolean`: Use this when the user wants to union, subtract, or intersect two imported triangle mesh solids \(STL, OBJ, or 3MF\). Supports union, subtract \(A minus B\) and intersect. Pass each operand as \{ file \} on the MCP server or \{ data \} with base64 mesh bytes; formats are detected or may be specified. Return - `explode\_view`: Use this when you need an ordered exploded-view plan for an assembly. Supply parts as \{name,center:\[x,y,z\],size:\[x,y,z\]\} in mm, or a LabWired handoff containing parts with ref, position\_mm.value and physical.bbox\_mm \(also accepts bbox\_mm.value\). Optional explicit assembly\_order takes precedence over - `apply\_surface\_blend`: Use this when you need to author and evaluate a fillet or chamfer on a kernelCAD Shape. Inserts Shape.fillet\(radius, selector, \{ continuity: G1\|G2 \}\) or Shape.chamfer\(distance, selector\) through the existing public API and returns the patched source plus evaluation diagnostics. Selectors accept Edge - `fetch\_part\_model`: Use this when a LabWired handoff part needs a STEP or GLB model resolved from a verified HTTPS URL plus SHA-256, or from catalog\_id / MPN. The tool uses fetch\_part/find\_part catalog plumbing, stores URL-fetched bytes in a SHA-256 cache, checks the supplied hash, compares measurable model dimensions - `write\_bom`: Use this when you need to merge a LabWired handoff BOM with optional KernelCAD catalog parts, MPNs and pricing, then write CSV or retrieve Sheets-ready rows. Pass exactly one of handoff, handoff\_json or handoff\_path. This tool only writes a CSV locally; it makes no Google API calls. Returns headers, - `price\_part`: Start or read the real price for making the part. Cheap. Returns status "ready" with estimate\_cents and summary, or "pricing" while the makers are asked \(call again in a few seconds\). Creates nothing and charges nothing. - `order\_part`: Order the part made: creates the production request and returns a pay\_url for the user. Propose the manufacturing method from the user's words and the part, pass it as method with a one-line reason. The price is the real maker price; never invent or send one. Tell the user the card is only held, and Measured by MCP Station. Methods: https://mcpstation.net/methods.html · Terms: https://mcpstation.net/terms.html