vision-opencode-mcp
Provides a tool for reading local images and querying an OpenAI-compatible vision model API to describe them or answer questions about them.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@vision-opencode-mcpWhat's in the image I just pasted?"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
vision-opencode-mcp
Give opencode (or any MCP client) visual reference by calling an OpenAI-compatible vision model API. Exposes one tool:
vision_describe(image_path?, question?)— read a local image and return what the vision model sees. Whenimage_pathis omitted, it automatically picks the newest image (byLastWriteTime) from the pasted-images dir, which is where opencode stores clipboard-pasted images.
Requires only python>=3.10 and the mcp SDK (installed automatically).
Requirements
Python 3.10+
A
VISION_API_KEYfor an OpenAI-compatible vision endpoint (base URL and model are baked in as defaults; override if needed)
Related MCP server: vision-mcp
Install
# from this repo
python -m venv .venv
# Windows:
.venv\Scripts\pip install -e .
# macOS/Linux:
# .venv/bin/pip install -e .
# or with uv (faster)
uv syncThis installs the vision-mcp console script and all dependencies
(mcp, which pulls in mcp-types).
Configure for opencode
Add an mcp entry to your opencode config
(opencode.json or ~/.config/opencode/opencode.json):
{
"mcp": {
"vision": {
"type": "local",
"command": [
"C:\\path\\to\\vision-opencode-mcp\\.venv\\Scripts\\python.exe",
"C:\\path\\to\\vision-opencode-mcp\\server.py"
],
"enabled": true,
"environment": {
"VISION_API_KEY": "your-api-key-here"
}
}
}
}If you installed with uv sync, you can also point at the vision-mcp
console script instead of the venv python:
{
"mcp": {
"vision": {
"type": "local",
"command": ["C:\\path\\to\\vision-opencode-mcp\\.venv\\Scripts\\vision-mcp.exe"],
"enabled": true,
"environment": {
"VISION_API_KEY": "your-api-key-here"
}
}
}
}Restart opencode. The vision_describe tool then appears under the vision
MCP server.
Environment variables
Variable | Default | Required | Description |
| (none) | yes | API key for the vision endpoint. Never hardcoded. |
|
| no | Base URL of the OpenAI-compatible API. |
|
| no | Vision model name. |
| Chrome UA | no | Sent as |
|
| no | HTTP timeout in ms. |
|
| no |
|
|
| no | Directory scanned for the newest image when |
Usage
With image_path:
call vision_describe image_path="D:\pics\shot.png" question="这个截图里报了什么错?"Without image_path (auto-picks the newest pasted image):
call vision_describe question="这张图片里有什么?"CLI (debug)
The repo also ships vision.py, a small command-line version of the same call:
python vision.py <image_path> [question]Prints the model text to stdout; exits 0 on success, 1 on error
(prints ERROR: ...). It reads the same environment variables as the server.
Notes
The API key is read from the environment only — it never appears in the code, so this repo is safe to share.
For clipboard-pasted images in opencode desktop, the tool auto-picks the newest file under the pasted-images dir, so you can just say "看这张图" and the tool picks it up.
Available Tools
1 toolvision_describeA
Give the model visual reference: read a local image file and return what a vision-capable model sees/understands about it. Use whenever you need to see or interpret an image (screenshots, diagrams, photos).
| Name | Required | Description | Default |
|---|---|---|---|
| question | No | Optional free-form question about the image. When empty, the model produces a general detailed description. | |
| image_path | No | Absolute path to a local image file (png/jpg/jpeg/webp/bmp/gif). When omitted/empty, automatically picks the newest image by LastWriteTime under the pasted-images dir (VISION_PASTED_DIR). |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden. It discloses the core behavior (reading a local file and returning a vision-based interpretation) and implies a non-destructive read operation. However, it doesn't mention potential limitations such as unsupported formats (covered in schema), file size constraints, or behavior when the file is missing, leaving some gaps.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is two sentences with no superfluous content. The first sentence identifies the action and outcome, the second gives a concise usage directive. It is well-structured and front-loaded.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple read-only tool with two optional parameters and no output schema, the description adequately covers purpose and usage. The schema handles parameter details. The output is hinted as 'what a vision-capable model sees/understands' but not fully specified, which is a minor gap. Overall, it is complete enough for an agent to invoke correctly.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema provides 100% coverage with clear descriptions for both 'question' and 'image_path', including default behavior for the latter. The tool description does not add additional meaning beyond the schema, so the baseline of 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's function: 'read a local image file and return what a vision-capable model sees/understands about it.' It uses a specific verb ('read') and resource ('local image file'), making the purpose unambiguous. Since there are no sibling tools, distinguishing is not needed, but the description stands on its own.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description explicitly says 'Use whenever you need to see or interpret an image' and provides examples like screenshots, diagrams, and photos. This gives clear context for when to use the tool, though it doesn't mention alternatives because none exist. It's a straightforward usage instruction without exclusions.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
TDQS
With only one tool, there is no possibility of confusion or overlap. The tool's purpose is clearly described and distinct by virtue of being the only option.
The single tool name 'vision_describe' follows a consistent verb_noun pattern. With only one tool, internal naming consistency is trivially maintained.
One tool is borderline thin for a server whose name suggests broader vision capabilities. However, the narrow focus on image description makes the count acceptable, if minimal.
The tool covers the core need of interpreting local image files, but lacks support for remote images or additional vision operations (e.g., OCR, image metadata). These are minor gaps for the stated purpose.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
MCP server for Qwen Image 3 AI image generation
Focused MCP server for OpenAI image/audio generation (v2.0.0). Wraps endpoints via HAPI CLI.
MCP server for NanoBanana AI image generation and editing
MCP server for OpenAI Sora AI video generation
Related MCP Servers
- AlicenseNot gradedqualityCmaintenanceAn MCP server that enables any LLM to describe images from file paths, URLs, or base64 data by forwarding them to a supported vision provider such as OpenAI, Anthropic, or local Ollama models.1,06010MIT
- AlicenseNot gradedqualityBmaintenanceAn MCP server for image recognition and OCR via OpenAI-compatible vision APIs, supporting local files, URLs, and data URLs. Enables natural language image description and text extraction.212MIT
- AlicenseAqualityCmaintenanceMCP server that provides visual question answering, image description, object detection, OCR, and image manipulation tools using OpenAI-compatible vision models.12119GPL 2.0
- AlicenseAqualityCmaintenanceOpenAI-compatible vision recognition MCP server that lets MCP clients see images by routing them to any OpenAI-compatible vision model.1MIT
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/sddzwxy/vision-opencode-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server