{"_id":"@cloudwerxlab/base64-to-url-mcp","name":"@cloudwerxlab/base64-to-url-mcp","dist-tags":{"latest":"1.0.0"},"versions":{"1.0.0":{"name":"@cloudwerxlab/base64-to-url-mcp","version":"1.0.0","description":"MCP server that converts base64 images and image URLs into markdown for display in chat","main":"index.js","bin":{"base64-to-url-mcp":"index.js"},"type":"module","scripts":{"start":"node index.js","publish":"npm publish --access public"},"keywords":["mcp","model-context-protocol","images","base64","openwebui","llm-tools"],"author":{"name":"cloudwerxlab"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/cloudwerxlab/base64-to-url-mcp.git"},"dependencies":{"@modelcontextprotocol/sdk":"*","express":"^4.18.2","zod":"^3.21.4","uuid":"^9.0.0"},"_id":"@cloudwerxlab/base64-to-url-mcp@1.0.0","gitHead":"1a9ba92c14c39f8b01f36b8bb8ca64cf65f94786","bugs":{"url":"https://github.com/cloudwerxlab/base64-to-url-mcp/issues"},"homepage":"https://github.com/cloudwerxlab/base64-to-url-mcp#readme","_nodeVersion":"22.13.1","_npmVersion":"10.9.2","dist":{"integrity":"sha512-droCz0VKQfTHrgcmdfWTDew7snnEtjPe/pRWhE9jY0EhvMaD6BdaDi/lVGWqyLo3d/gy85EeMJqbSLjECE8WEQ==","shasum":"b8ecd258e70a5445664d3332f3a10ed320d99c06","tarball":"https://registry.npmjs.org/@cloudwerxlab/base64-to-url-mcp/-/base64-to-url-mcp-1.0.0.tgz","fileCount":4,"unpackedSize":7251,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIG398p/4wxDZn7bxVdP36pJ1R0CZIWI4Sgj4xcLgwzn0AiEAtqrrDBxdLWzeb+FBMoelemY82U7QNR7+NRWEHV6SfHI="}]},"_npmUser":{"name":"cloudwerxlab","email":"cloudwerxlaboratories@gmail.com"},"directories":{},"maintainers":[{"name":"cloudwerxlab","email":"cloudwerxlaboratories@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/base64-to-url-mcp_1.0.0_1746811178805_0.4758843884410604"},"_hasShrinkwrap":false}},"time":{"created":"2025-05-09T17:19:38.707Z","1.0.0":"2025-05-09T17:19:39.017Z","modified":"2025-05-09T17:19:39.288Z"},"maintainers":[{"name":"cloudwerxlab","email":"cloudwerxlaboratories@gmail.com"}],"description":"MCP server that converts base64 images and image URLs into markdown for display in chat","homepage":"https://github.com/cloudwerxlab/base64-to-url-mcp#readme","keywords":["mcp","model-context-protocol","images","base64","openwebui","llm-tools"],"repository":{"type":"git","url":"git+https://github.com/cloudwerxlab/base64-to-url-mcp.git"},"author":{"name":"cloudwerxlab"},"bugs":{"url":"https://github.com/cloudwerxlab/base64-to-url-mcp/issues"},"license":"MIT","readme":"# Base64MCP\r\n\r\nThis is a Model Context Protocol (MCP) server that provides tools to convert base64-encoded images and image URLs into markdown-formatted image embeds for display in LLM chat interfaces (e.g., OpenWebUI chat).\r\n\r\n## Tools\r\n\r\n- **base64-to-url**: Accepts base64-encoded image data (optionally prefixed with data URI), saves it as an image file, and returns a markdown snippet with a URL to display the image.\r\n- **display-url**: Accepts an image URL and returns a markdown snippet to display the image.\r\n\r\n## Usage\r\n\r\n1. Install dependencies:\r\n   ```bash\r\n   npm install\r\n   ```\r\n\r\n2. Start the MCP server:\r\n   ```bash\r\n   npm start\r\n   ```\r\n\r\n3. MCP endpoint:\r\n\r\n   - POST requests: `http://localhost:4000/mcp`\r\n   - Static images served at: `http://localhost:4000/images/`\r\n\r\n## Tool Integration\r\n\r\nClients (e.g., OpenWebUI chat) should always use the `base64-to-url` tool when they have base64-encoded image data, and the `display-url` tool when they have a direct image URL. The server will return a markdown snippet for the client to render as an image.\r\n\r\n## Example Cursor JSON\r\n\r\nHere is an example of how an LLM client (e.g., Cursor) can invoke the `base64-to-url` tool to upload base64 image data:\r\n\r\n```json\r\n{\r\n  \"jsonrpc\": \"2.0\",\r\n  \"id\": 1,\r\n  \"method\": \"base64-to-url\",\r\n  \"params\": {\r\n    \"data\": \"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAA...\"\r\n  }\r\n}\r\n```\r\n\r\nTo display an existing image URL using the `display-url` tool:\r\n\r\n```json\r\n{\r\n  \"jsonrpc\": \"2.0\",\r\n  \"id\": 2,\r\n  \"method\": \"display-url\",\r\n  \"params\": {\r\n    \"url\": \"https://example.com/path/to/image.jpg\"\r\n  }\r\n}\r\n```\r\n\r\n## Example mcpservers.json\r\n\r\nClients that support loading servers from a `mcpservers.json` file (e.g., Cursor) can register this server with an entry like:\r\n\r\n```json\r\n{\r\n  \"mcpServers\": {\r\n    \"base64-to-url-mcp\": {\r\n      \"command\": \"npx\",\r\n      \"args\": [\"-y\", \"@cloudwerxlab/base64-to-url-mcp\"],\r\n      \"env\": {\r\n        \"BASE_URL\": \"http://localhost:4000\"\r\n      }\r\n    }\r\n  }\r\n}\r\n```\r\n\r\nAdjust the server name, package name, and `BASE_URL` as needed based on your environment. ","readmeFilename":"README.md","_rev":"1-e11c89867503f417eec6980297a48aa0"}