Skip to main content

Craft real CAD with Claude. MCP server for Onshape.

Project description

shapecraft

Craft real CAD with Claude. Any shape. Any tool.

Status: v0.1.2-alpha — auth + reads working, writes under active repair. Live integration testing against Onshape revealed that the feature-write path silently produced solver errors in v0.1.0 / v0.1.1 (HTTP 200 but featureStatus=ERROR). v0.1.2a1 makes add_feature raise on solver rejection so failures surface immediately. Systematic feature-payload fixes land in v0.1.3. See CHANGELOG.md for the full list of known-broken tools.

shapecraft gives Claude first-class tools to drive professional parametric CAD. The MCP surface covers document/workspace management, sketch primitives + splines + constraints, every core feature (extrude/revolve/loft/fillet/chamfer/pattern/boolean/thicken), offset planes, variable tables, FeatureScript evaluation, exports to STL/STEP/GLTF, and assembly operations with 4 mate types — but most feature-write tools are currently producing solver-rejected payloads and will raise OnshapeError until v0.1.3 lands.

Install

uvx shapecraft   # or: pip install shapecraft

Register with Claude Code

claude mcp add shapecraft \
  -s user \
  -e ONSHAPE_ACCESS_KEY=<your_key> \
  -e ONSHAPE_SECRET_KEY=<your_secret> \
  -- uvx shapecraft

Get your keys at dev-portal.onshape.com.

Tools (MCP surface covers ~48 operations, many currently failing at the solver — see CHANGELOG)

  • shapecraft_list_documents
  • shapecraft_create_document
  • shapecraft_create_part_studio
  • shapecraft_sketch_rectangle
  • shapecraft_sketch_spline (NEW vs hedless)
  • shapecraft_offset_plane (NEW)
  • shapecraft_extrude with symmetric + reverse flags (upgraded)
  • shapecraft_loft (NEW)

Plus build_coincident_constraint helper (sketch constraint builder — first of 7 coming in T1).

See the design spec for the full T1 → T3 roadmap.

Development

python3 -m venv venv
./venv/bin/pip install -e ".[dev]"
./venv/bin/pytest tests/unit -v

Integration tests (tests/integration/) hit live Onshape and require ONSHAPE_ACCESS_KEY/ONSHAPE_SECRET_KEY env vars.

Releasing

  1. Bump version in pyproject.toml
  2. Update CHANGELOG.md
  3. git tag v0.1.0 && git push --tags
  4. release.yml publishes to PyPI via trusted publishing (configure once at pypi.org)

License

MIT. See LICENSE.

Credits

Inspired by hedless/onshape-mcp (MIT per its README) — shapecraft is an independent reimplementation that covers a broader slice of the Onshape REST and FeatureScript API.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

shapecraft-0.1.2a1.tar.gz (99.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

shapecraft-0.1.2a1-py3-none-any.whl (38.2 kB view details)

Uploaded Python 3

File details

Details for the file shapecraft-0.1.2a1.tar.gz.

File metadata

  • Download URL: shapecraft-0.1.2a1.tar.gz
  • Upload date:
  • Size: 99.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for shapecraft-0.1.2a1.tar.gz
Algorithm Hash digest
SHA256 fd8e828c757e4bd63b3ba19fd9a61c30a70a3ccde7359f14507dd252a0757d79
MD5 adb6c73bfd15962cf34a1021940e3e1b
BLAKE2b-256 96f40ea4e0d2a286913b5c6e80a70404307ce86d610e9c734f9db85b994841d9

See more details on using hashes here.

Provenance

The following attestation bundles were made for shapecraft-0.1.2a1.tar.gz:

Publisher: release.yml on NewTurn2017/shapecraft

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file shapecraft-0.1.2a1-py3-none-any.whl.

File metadata

  • Download URL: shapecraft-0.1.2a1-py3-none-any.whl
  • Upload date:
  • Size: 38.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for shapecraft-0.1.2a1-py3-none-any.whl
Algorithm Hash digest
SHA256 06eb2004d501906c4b775e53f03bc14cc7a28903b5cc15ee58a2718259e1c765
MD5 e0aa7744406124c5e06c8b6b9c721f49
BLAKE2b-256 ca75ed8d660d918dcf90a38a517d1f3174eab505a3d376fd1b86c16e22464951

See more details on using hashes here.

Provenance

The following attestation bundles were made for shapecraft-0.1.2a1-py3-none-any.whl:

Publisher: release.yml on NewTurn2017/shapecraft

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page