1. Conduid
  2. AI
  3. Ocp Viewer MCP
MCP server · AI

Ocp Viewer MCP

MCP server for capturing screenshots from OCP CAD Viewer - lets AI assistants see your 3D CAD models

Unclaimed MIT last commit 10 months ago ai
53Fair

Scored 5 days ago · breakdown

About Ocp Viewer MCP

Ocp Viewer MCP is an MCP server published by dmilad in the AI category: mCP server for capturing screenshots from OCP CAD Viewer - lets AI assistants see your 3D CAD models.

The repository has 4 stars and 2 forks, with the last commit 10 months ago. Six months or more without a commit doesn't mean the server is broken, but check the open issues before depending on it in production.

Install

From source
git clone https://github.com/dmilad/ocp-viewer-mcp

This server has no ConduID identity, so agent calls to it are not receipted. Pin the version you install and review the source before granting it credentials.

Ask AI

✦

Ask AI about Ocp Viewer MCP

Powered by Claude · Grounded in docs

I know everything about Ocp Viewer MCP. Ask me about installation, configuration, usage, or troubleshooting.

Security checks

Static checks derived from the repository 5 days ago. Heuristics on the source, not an audit.

  • ✓README presentThe repository ships documentation.
  • ✓License declaredUsable under a stated license.
  • ✓Tests presentA test suite exists in the repository.
  • !Dependencies pinnedNo lockfile. Installs can pull different code over time.
  • ✓No dynamic code executionSource scan found no eval, dynamic Function, or shell execution.
  • !Scoped permissionsDoesn't declare a permission scope. Assume it can do anything its process can.

Releases

v0.1.0v0.1.0 - Initial Release · 25 Dec 2025Initial Release First release of the OCP Viewer MCP Server. Features `capture_ocp_screenshot` tool for capturing screenshots from OCP CAD Viewer Configurable port (default: 3939) Configurable render wait time Returns screenshots as…

README

OCP Viewer MCP Server

PyPI version

An MCP (Model Context Protocol) server that captures screenshots from the OCP CAD Viewer, allowing AI assistants like Cursor to "see" your 3D CAD models.

What it does

When working with CAD tools like CadQuery or Build123d, you can display models in the OCP CAD Viewer using show(). This MCP server lets you ask an AI assistant to capture what's currently displayed, enabling visual feedback and AI-assisted CAD development.

Example workflow:

  1. You're designing a part in a Jupyter notebook with CadQuery
  2. You run show(my_part) to display it in the OCP viewer
  3. You ask the AI: "capture the current view - does this geometry look correct?"
  4. The AI captures a screenshot and can analyze the 3D model visually

Installation

pip install ocp-viewer-mcp

Requirements:

Configuration

Cursor

Add to your ~/.cursor/mcp.json:

{
  "mcpServers": {
    "ocp-viewer": {
      "command": "python",
      "args": ["-m", "ocp_viewer_mcp.server"]
    }
  }
}

If you're using a virtual environment (recommended), specify the full Python path:

{
  "mcpServers": {
    "ocp-viewer": {
      "command": "/path/to/your/venv/bin/python",
      "args": ["-m", "ocp_viewer_mcp.server"]
    }
  }
}

Claude Desktop

Add to your Claude Desktop config (~/Library/Application Support/Claude/claude_desktop_config.json on macOS):

{
  "mcpServers": {
    "ocp-viewer": {
      "command": "python",
      "args": ["-m", "ocp_viewer_mcp.server"]
    }
  }
}

Usage

  1. Open your CadQuery/Build123d project in Cursor or VS Code
  2. Start the OCP CAD Viewer (Cmd+Shift+P → "OCP CAD Viewer: Open Viewer")
  3. Display a model using show(your_model) in a notebook or script
  4. Ask the AI to capture the view:
    • "Capture the current OCP view"
    • "Show me what the model looks like"
    • "Take a screenshot of the CAD viewer"

Tool Reference

capture_ocp_screenshot

Captures a screenshot of the OCP CAD Viewer.

Parameter Type Default Description
port integer 3939 The port where OCP viewer is running
wait_ms integer 1000 Milliseconds to wait for rendering

Returns: A PNG screenshot as a base64-encoded image.

Troubleshooting

"Could not connect to OCP viewer"

  • Make sure the OCP CAD Viewer is open in VS Code/Cursor
  • Check that the viewer backend is running (look for "Viewer backend started" in terminal)
  • Verify the port (default is 3939)

"ocp_vscode not installed"

The MCP server needs ocp-vscode installed in the same Python environment:

pip install ocp-vscode

Screenshot not capturing

  • Make sure a model is displayed (run show(something) first)
  • Try increasing wait_ms if the model is complex

Development

# Clone the repo
git clone https://github.com/dmilad/ocp-viewer-mcp.git
cd ocp-viewer-mcp

# Install with Poetry
poetry install

# Run locally
poetry run python -m ocp_viewer_mcp.server

Contributing

Contributions are welcome! Please open an issue first to discuss what you'd like to change.

License

MIT

Related Projects

  • OCP CAD Viewer - The VS Code extension this MCP server integrates with
  • CadQuery - Python parametric CAD scripting
  • Build123d - Python CAD scripting with a builder pattern
  • MCP - Model Context Protocol specification

README fetched from the repository 5 days ago. The original is authoritative.

Questions

About Ocp Viewer MCP

How do I install Ocp Viewer MCP?

No package has been published for this server, so install it from source: clone the repository and follow its README.

Is Ocp Viewer MCP safe to use with an AI agent?

Its trust score is 53 out of 100 (fair). It passes 4 of the 6 static security checks run so far; the failures are listed above. It has no ConduID identity yet, so agent calls to it are not receipted.

Is Ocp Viewer MCP still maintained?

The last commit was 10 months ago and 1 open issues. That's long enough that you should check whether the maintainer is responding to issues before depending on it.