Basic information
About Code Snippet Image Mcp Server
An MCP (Model Context Protocol) server that generates beautiful code snippet images to post to social media.
Code Snippet Image Mcp Server is a MCP server in the Developer Tools category listed in the AddMCP.net directory, published by suhaibkhan. It exposes 1 tool, including create_code_image. Supported transport: stdio. License: MIT. Source code is hosted on github.com. Related topics: code-generation, code-snippets, coding, linkedin, social-media.
Setup
{
"mcpServers": {
"code-snippet-image-mcp-server": {
"command": "npx",
"args": [
"-y",
"code-snippet-image-mcp-server",
"/custom/output/directory"
]
}
}
}
{
"mcpServers": {
"code-snippet-image-mcp-server": {
"command": "npx",
"args": [
"-y",
"code-snippet-image-mcp-server",
"/custom/output/directory"
]
}
}
}
{
"servers": {
"code-snippet-image-mcp-server": {
"command": "npx",
"args": [
"-y",
"code-snippet-image-mcp-server",
"/custom/output/directory"
]
}
}
}
Code Snippet Image Mcp Server config
Add this server to your MCP-compatible client using the configuration below.
{
"mcpServers": {
"code-snippet-image-mcp-server": {
"command": "npx",
"args": [
"-y",
"code-snippet-image-mcp-server",
"/custom/output/directory"
]
}
}
}
Code Snippet Image Mcp Server tools
-
create_code_image
— Generate a beautiful code snippet image with syntax highlighting and styling
backgroundColor:string, code:string*, height:number, language:string, padding:number, showLineNumbers:boolean, theme:string, title:string, width:number
Overview
What is Code Snippet Image Mcp Server?
It is an MCP server that converts code snippets into beautiful images. It integrates with any MCP-compatible client and is intended for developers who want to share or present code in a visually appealing format.
How to use Code Snippet Image Mcp Server?
Add the server to your MCP configuration file using the npx -y code-snippet-image-mcp-server command, optionally specifying a custom output directory. The server provides the create_code_image tool with parameters for code, language, theme, title, dimensions, padding, background color, and line numbers.
Key features of Code Snippet Image Mcp Server
- Generate beautiful code snippet images
- Syntax highlighting with multiple programming languages
- Customizable color themes (default: dracula)
- Adjustable image width, height, and padding
- Toggle line number visibility
Frequently asked questions
1 What programming languages are supported for syntax highlighting?
The language parameter accepts any language identifier supported by the underlying highlighter; the default is "javascript".
2 What themes are available?
The theme parameter allows any valid theme name; the default is "dracula".
3 Where are the generated images saved?
The images are saved to the custom output directory specified as the command-line argument when starting the server.
4 Does the server require Node.js?
Yes, because it is run via npx, Node.js must be installed on the system.
5 How can I change the output directory?
Pass the desired directory path as the first argument in the args array of the MCP configuration (e.g., "/custom/output/directory").
Comments
No comments yet
Be the first to share feedback about this listing. Sign in to leave a comment.
Sign In