photoshop-python-api-mcp-server
by: loonghao
A Model Context Protocol (MCP) server that interfaces with Adobe Photoshop's Python API. Enables LLMs to execute image editing operations, automate workflows, and manage Photoshop tasks through structured commands and context-aware interactions.
📌Overview
Purpose: This repository serves as a boilerplate for developers to easily set up new projects using best practices and standardized structures.
Overview: The repo-template provides a foundational structure that allows developers to kickstart projects quickly. It aims to streamline the initial setup process and ensure consistency across different projects by providing essential configurations and files.
Key Features:
-
Starter Configuration: Comes with pre-defined configuration files to help quickly set up environments for various programming languages and tools.
-
Version Control Integration: Pre-configured for easy integration with Git, promoting best practices for versioning and collaborative development.
Photoshop MCP Server
A Model Context Protocol (MCP) server for Photoshop integration using photoshop-python-api.
English | ç®€ä½“ä¸æ–‡
Overview
This project provides a bridge between the Model Context Protocol (MCP) and Adobe Photoshop, allowing AI assistants and other MCP clients to control Photoshop programmatically.
Requirements
- Windows OS only: This server uses COM interface which is only available on Windows.
- Adobe Photoshop: Must be installed locally (tested with versions CC2017 through 2024).
- Python: Version 3.10 or higher.
Installation
# Install using pip
pip install photoshop-mcp-server
# Or using uv
uv install photoshop-mcp-server
MCP Host Configuration
This server is designed to work with various MCP hosts. The PS_VERSION
environment variable is used to specify which Photoshop version to connect to (e.g., "2024", "2023", "2022", etc.).
The recommended way to configure the server is using uvx
as the command, which is the official standard format.
Standard Configuration (Recommended)
Add the following to your MCP host configuration (works with Claude Desktop, Windsurf, Cline, and other MCP hosts):
{
"mcpServers": {
"photoshop": {
"command": "uvx",
"args": ["photoshop-mcp-server"],
"env": {
"PS_VERSION": "2024"
}
}
}
}
Configuration Options
- PS_VERSION: Specify the Photoshop version to connect to (e.g., "2024", "2023", "2022", etc.)
- command: Use
uvx
for the standard approach. - args: Use
["photoshop-mcp-server"]
to run the Photoshop MCP server.
Key Features
Available Resources
photoshop://info
- Get Photoshop application information.photoshop://document/info
- Get active document information.photoshop://document/layers
- Get layers in the active document.
Available Tools
The server provides various tools for controlling Photoshop:
- Document Tools: Create, open, and save documents.
- Layer Tools: Create text layers, solid color layers, etc.
- Session Tools: Get information about Photoshop session, active document, selection.
Basic Usage Example
Once configured in your MCP host, you can use the Photoshop MCP server in your AI assistant conversations.
Example conversation:
User: Can you create a new Photoshop document and add a text layer with "Hello World"?
AI Assistant: I'll create a new document and add the text layer for you.
[The AI uses the Photoshop MCP server to:
1. Create a new document using the `create_document` tool
2. Add a text layer using the `create_text_layer` tool with the text "Hello World"]
I've created a new Photoshop document and added a text layer with "Hello World".
License
MIT
Acknowledgements
- photoshop-python-api - Python API for Photoshop
- Model Context Protocol - MCP Python SDK