Skip to main content

MCP server for Base64 file conversion (stdio transport)

Project description

MCP Base64 Server

A Python MCP (Model Context Protocol) server for Base64 file conversion with stdio transport.

Features

  • encode_file_to_base64: Encode any file to base64 string
  • decode_base64_to_file: Decode base64 content to file
  • Binary-safe: Handles both text and binary files correctly

Usage

IDE Configuration

For IDE plugins, add this server to your MCP configuration JSON:

{
  "mcpServers": {
    "base64": {
      "command": "uvx",
      "args": [
        "mcp-base64"
      ]
    }
  }
}

Direct Execution

git clone https://github.com/Wuodan/mcp-base64.git
cd mcp-base64
python3 -m venv .venv
./.venv/bin/python -m pip install -e .
./.venv/bin/python -m mcp_base64.server

Tools

encode_file_to_base64(file_path: str) -> str

Encodes a file to base64 string.

Parameters:

  • file_path (str): Absolute path to file to encode

Returns: Base64 encoded string

decode_base64_to_file(base64_content: str, file_path: str) -> str

Decodes base64 string to file.

Parameters:

  • base64_content (str): Base64 encoded content
  • file_path (str): Absolute path where to save decoded file

Returns: Success message with file path

Development

Install development dependencies:

./.venv/bin/python -m pip install -r requirements-dev.txt -e .

Run tests:

./.venv/bin/python -m pytest -q

Run linting:

./scripts/lint.sh

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mcp_base64-0.1.6.tar.gz (29.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mcp_base64-0.1.6-py3-none-any.whl (12.6 kB view details)

Uploaded Python 3

File details

Details for the file mcp_base64-0.1.6.tar.gz.

File metadata

  • Download URL: mcp_base64-0.1.6.tar.gz
  • Upload date:
  • Size: 29.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for mcp_base64-0.1.6.tar.gz
Algorithm Hash digest
SHA256 f573d806b31a7ca07050e4a8cecac1f972449c4f162a0bff5e90e73dc073241a
MD5 8fda6fb6f0c2b9529ff6e1e1596ec091
BLAKE2b-256 7b27dbb9b867dfc057b71ae9bb5c2818b32e0586ee7676ae80bd1afae6bcd22b

See more details on using hashes here.

Provenance

The following attestation bundles were made for mcp_base64-0.1.6.tar.gz:

Publisher: release.yml on Wuodan/mcp-base64

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file mcp_base64-0.1.6-py3-none-any.whl.

File metadata

  • Download URL: mcp_base64-0.1.6-py3-none-any.whl
  • Upload date:
  • Size: 12.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for mcp_base64-0.1.6-py3-none-any.whl
Algorithm Hash digest
SHA256 393abf268ad5a2353fce57df641ce74120575a605f089165f7a37f1cb9203ac5
MD5 a9bff2d0fea89ac5e6f169cf045d5caa
BLAKE2b-256 a28a33a2429dce6aa2fe1a5ca2bd2d8fd4c449b5f0e80278316c5e99a0755cdd

See more details on using hashes here.

Provenance

The following attestation bundles were made for mcp_base64-0.1.6-py3-none-any.whl:

Publisher: release.yml on Wuodan/mcp-base64

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page