MCP Integration

Model Context Protocol integration for AI assistants like Claude.

Overview

Conjure implements the Model Context Protocol (MCP), enabling AI assistants like Claude, ChatGPT, and others to interact with CAD software through natural language. MCP provides a standardized interface for AI tools to discover and execute CAD operations.

What is MCP?

Model Context Protocol is an open standard developed by Anthropic that allows AI models to safely interact with external systems through well-defined tools and capabilities.

Architecture

Conjure's MCP integration follows a three-tier architecture:

1

AI Assistant

Claude or other AI with MCP support interprets user requests and selects appropriate tools.

2

Conjure Server

Validates requests, checks rate limits, orchestrates tool execution, and routes commands to adapters.

3

CAD Adapter

Local FreeCAD or Fusion 360 adapter executes operations and returns results.

MCP Tools

Conjure exposes CAD operations as MCP tools. Tools are grouped by category and gated by subscription tier.

Tool Categories

Primitives

Create basic 3D shapes

  • • create_box
  • • create_cylinder
  • • create_sphere
  • • create_cone
  • • create_torus
  • • create_helix

Boolean Operations

Combine or subtract shapes

  • • boolean_fuse
  • • boolean_cut
  • • boolean_intersect

Transforms

Move and manipulate objects

  • • move_object
  • • rotate_object
  • • copy_object
  • • delete_object

Modifiers

Add features to geometry

  • • create_fillet
  • • create_chamfer
  • • extrude

Queries

Inspect design state

  • • get_state
  • • get_object_details
  • • list_objects
  • • get_bounding_box

Standards Premium

Engineering standards library

  • • search_standards
  • • get_standard_spec
  • • calculate_thread_geometry
  • • design_socket_cutout

Using MCP Tools

List Available Tools

Query available tools for your subscription tier:

Request

curl -H "X-API-Key: your_api_key" \
  https://conjure.lautrek.com/api/v1/mcp/tools

Response

{
  "tier": "pro",
  "tools": [
    {
      "name": "create_box",
      "description": "Create a rectangular box primitive",
      "category": "primitives",
      "operation_cost": 1,
      "requires_adapter": true
    },
    {
      "name": "search_standards",
      "description": "Search engineering standards library",
      "category": "standards",
      "operation_cost": 1,
      "requires_adapter": false
    }
  ],
  "total_count": 25
}

Execute a Tool

Execute an MCP tool with parameters:

Request

curl -X POST \
  -H "X-API-Key: your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
    "tool_name": "create_box",
    "parameters": {
      "length": 50.0,
      "width": 30.0,
      "height": 20.0
    }
  }' \
  https://conjure.lautrek.com/api/v1/mcp/execute

Response

{
  "success": true,
  "result": {
    "object_id": "Box001",
    "type": "Part::Box",
    "bounding_box": {
      "min": [0, 0, 0],
      "max": [50, 30, 20]
    }
  },
  "execution_time_ms": 45.2,
  "commands_executed": 1
}

Tool Discovery

AI assistants discover available tools through the MCP protocol. Each tool includes:

Tool Schema

{
  "name": "create_box",
  "description": "Create a rectangular box primitive in the CAD document",
  "inputSchema": {
    "type": "object",
    "properties": {
      "length": {
        "type": "number",
        "description": "Length of the box in mm",
        "minimum": 0.01
      },
      "width": {
        "type": "number",
        "description": "Width of the box in mm",
        "minimum": 0.01
      },
      "height": {
        "type": "number",
        "description": "Height of the box in mm",
        "minimum": 0.01
      },
      "position": {
        "type": "array",
        "description": "Position [x, y, z] in mm",
        "items": { "type": "number" },
        "default": [0, 0, 0]
      }
    },
    "required": ["length", "width", "height"]
  }
}

Adapter Requirements

Most MCP tools require a connected CAD adapter. Check adapter status:

Request

curl -H "X-API-Key: your_api_key" \
  https://conjure.lautrek.com/api/v1/adapter/status

Response

{
  "adapters": [
    {
      "adapter_id": "adapter_xyz789",
      "adapter_type": "freecad",
      "status": "active",
      "connected_at": "2025-01-15T10:30:00",
      "last_heartbeat": "2025-01-15T10:35:00",
      "healthy": true,
      "capabilities": ["primitives", "booleans", "transforms"]
    }
  ],
  "total_connected": 1
}
No Adapter Connected: If no adapter is connected, tool execution will return an error asking the user to start their local CAD adapter.

AI Assistant Integration

Claude Desktop / Claude Code

Add Conjure to your Claude MCP configuration file. Claude uses stdio transport to communicate with MCP servers, so we use the @anthropic/mcp-proxy to bridge to Conjure's SSE endpoint.

Configuration File Locations

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json
  • Linux (Claude Code): ~/.claude.json

Configuration

{
  "mcpServers": {
    "conjure": {
      "command": "npx",
      "args": ["-y", "@anthropic/mcp-proxy", "--", "sse", "https://conjure.lautrek.com/api/v1/mcp/sse"],
      "env": {
        "CONJURE_API_KEY": "YOUR_API_KEY_HERE"
      }
    }
  }
}

Replace YOUR_API_KEY_HERE with your actual Conjure API key. After saving, restart Claude Desktop or Claude Code for changes to take effect.

Requires Node.js: The MCP proxy is installed automatically via npx, but requires Node.js 18+ to be installed on your system. Download Node.js

Direct API Integration

For custom applications, you can connect directly to the Conjure API:

SSE Endpoint (for MCP clients)

https://conjure.lautrek.com/api/v1/mcp/sse

Use the X-API-Key header or CONJURE_API_KEY environment variable for authentication.

Python Example (Direct API)

import requests

API_KEY = "your_conjure_api_key"
BASE_URL = "https://conjure.lautrek.com/api/v1"

# List available MCP tools
response = requests.get(
    f"{BASE_URL}/mcp/tools",
    headers={"X-API-Key": API_KEY}
)
tools = response.json()
print(f"Available tools: {tools['total_count']}")

# Execute a tool
result = requests.post(
    f"{BASE_URL}/mcp/execute",
    headers={
        "X-API-Key": API_KEY,
        "Content-Type": "application/json"
    },
    json={
        "tool_name": "create_box",
        "parameters": {
            "length": 50.0,
            "width": 50.0,
            "height": 50.0
        }
    }
)
print(result.json())

Example Workflows

Simple Shape Creation

"Create a cylinder 20mm diameter and 40mm tall"

  1. AI selects create_cylinder tool
  2. Server validates user tier and rate limits
  3. Command routed to connected FreeCAD adapter
  4. Cylinder created in CAD document
  5. Result returned to AI with object ID and dimensions

Complex Assembly

"Create a phone stand with 60 degree angle"

  1. AI breaks down into multiple tools:
    • create_box for base
    • create_box for back support
    • rotate_object to angle support
    • boolean_fuse to join parts
    • create_fillet for smooth edges
  2. Each tool executed sequentially on adapter
  3. AI monitors progress and adjusts if errors occur
  4. Final design returned with visualization

Engineering Standards Query Premium

"What's the thread geometry for M8 x 1.25?"

  1. AI selects calculate_thread_geometry tool
  2. Server executes locally (no adapter required)
  3. Returns pitch diameter, minor diameter, thread depth
  4. AI presents formatted results to user

Next Steps