Text Transformation & Formatting MCP Server for the Cline Marketplace
npm install @iflow-mcp/text-toolkit
A Text Transformation & Formatting MCP Server for the Cline Marketplace that provides developers with common text manipulation functions directly within their workflow.
> Transform, format, and analyze text without leaving your AI assistant workflow.
| Tool | Description |
| ---- | ----------- |
| case_to_camel | Convert text to camelCase |
| case_to_pascal | Convert text to PascalCase |
| case_to_snake | Convert text to snake_case |
| case_to_kebab | Convert text to kebab-case |
| case_to_constant | Convert text to CONSTANT_CASE |
| case_to_dot | Convert text to dot.case |
| case_to_no | Convert text to no case |
| case_to_pascal_snake | Convert text to Pascal_Snake_Case |
| case_to_path | Convert text to path/case |
| case_to_sentence | Convert text to Sentence case |
| case_to_train | Convert text to Train-Case |
| case_to_capital | Convert text to Capital Case |
| encode_base64 | Encode text to Base64 |
| decode_base64 | Decode Base64 to text |
| encode_url | Encode text for URLs |
| decode_url | Decode URL-encoded text |
| encode_html | Encode HTML entities |
| decode_html | Decode HTML entities |
| format_json | Format and beautify JSON |
| format_xml | Format and beautify XML |
| format_sql | Format and beautify SQL |
| format_html | Format and beautify HTML |
| count_characters | Count characters in text |
| count_words | Count words in text |
| count_lines | Count lines in text |
| analyze_readability | Calculate readability metrics |
| string_trim | Trim whitespace from text |
| string_substring | Extract a substring |
| string_replace | Replace text |
| string_split | Split text into an array |
| string_join | Join an array into text |
| generate_uuid | Generate a UUID |
| validate_uuid | Validate a UUID |
| generate_md5 | Generate MD5 hash |
| generate_sha1 | Generate SHA-1 hash |
| generate_sha256 | Generate SHA-256 hash |
| generate_sha512 | Generate SHA-512 hash |
| generate_hmac | Generate HMAC hash |
| generate_lorem_ipsum | Generate lorem ipsum text |
| regex_test | Test a regex pattern against text |
| regex_replace | Replace text using a regex pattern |
| regex_extract | Extract matches using a regex pattern |
| regex_split | Split text using a regex pattern |
- Node.js 16.x or higher - The TextToolkit MCP server requires Node.js 16+ to run properly.
To run the TextToolkit MCP server using Node.js npx, use the following command:
``bash`
npx -y @cicatriz/text-toolkit@latest
#### Cursor
To add this server to Cursor IDE:
1. Go to Cursor Settings > MCP
2. Click + Add new Global MCP Server
3. Add the following configuration to your global .cursor/mcp.json file:
`json`
{
"mcpServers": {
"text-toolkit": {
"command": "npx",
"args": [
"-y",
"@cicatriz/text-toolkit"
]
}
}
}
See the Cursor documentation for more details.
#### Windsurf
To set up MCP with Cascade, navigate to Windsurf - Settings > Advanced Settings or Command Palette > Open Windsurf Settings Page.
Scroll down to the Cascade section and add the TextToolkit MCP server directly in mcp_config.json:
`json`
{
"mcpServers": {
"text-toolkit": {
"command": "npx",
"args": [
"-y",
"@cicatriz/text-toolkit"
]
}
}
}
#### Cline
Add the following JSON manually to your cline_mcp_settings.json via Cline MCP Server setting:
`json`
{
"mcpServers": {
"text-toolkit": {
"command": "npx",
"args": [
"-y",
"@cicatriz/text-toolkit"
]
}
}
}
#### Roo Code
Access the MCP settings by clicking Edit MCP Settings in Roo Code settings or using the Roo Code: Open MCP Config command in VS Code's command palette:
`json`
{
"mcpServers": {
"text-toolkit": {
"command": "npx",
"args": [
"-y",
"@cicatriz/text-toolkit"
]
}
}
}
#### Claude
Add the following to your claude_desktop_config.json file:
`json`
{
"mcpServers": {
"text-toolkit": {
"command": "npx",
"args": [
"-y",
"@cicatriz/text-toolkit"
]
}
}
}
See the Claude Desktop documentation for more details.
#### CLI
You can also run it as CLI by running the following command:
`bash`
npx -y @cicatriz/text-toolkit@latest
#### Install from npm
`bashInstall globally from npm
npm install -g @cicatriz/text-toolkit
#### Manual Installation
`bash
Clone the repository
git clone https://github.com/Cicatriiz/text-toolkit.git
cd text-toolkitInstall dependencies
npm installBuild the project
npm run buildRun the server
node dist/index.js
`💬 Usage
$3
`bash
Start in stdio mode (default)
text-toolkitStart in SSE mode on a specific port
text-toolkit --sse --port=8000Display version
text-toolkit --version
`$3
You can test the TextToolkit MCP server using the MCP Inspector:
`bash
Install the MCP Inspector
npm install -g @modelcontextprotocol/inspectorRun the inspector against your server
mcp-inspector @cicatriz/text-toolkit
`$3
The repository includes example scripts demonstrating how to use the TextToolkit MCP server:
`bash
Run the case transformation example
node examples/case-transform-example.js
`This example demonstrates how to:
1. Connect to the TextToolkit MCP server
2. List available tools
3. Transform text to different cases
4. Use custom options for transformations
🔧 Available Tools
$3
Converts text to camelCase.
Parameters:
-
text: The text to transform
- delimiter (optional): The character to use between words
- locale (optional): Locale for case conversion
- mergeAmbiguousCharacters (optional): Whether to merge ambiguous charactersExample:
`json
{
"text": "hello world test"
}
`Response:
`json
{
"result": "helloWorldTest"
}
`$3
Converts text to PascalCase.
Parameters:
-
text: The text to transform
- delimiter (optional): The character to use between words
- locale (optional): Locale for case conversion
- mergeAmbiguousCharacters (optional): Whether to merge ambiguous charactersExample:
`json
{
"text": "hello world test"
}
`Response:
`json
{
"result": "HelloWorldTest"
}
`$3
Encodes text to Base64.
Parameters:
-
text: The text to encodeExample:
`json
{
"text": "hello world"
}
`Response:
`json
{
"result": "aGVsbG8gd29ybGQ="
}
`$3
Decodes Base64 to text.
Parameters:
-
text: The Base64 string to decodeExample:
`json
{
"text": "aGVsbG8gd29ybGQ="
}
`Response:
`json
{
"result": "hello world"
}
`$3
Formats and beautifies JSON.
Parameters:
-
text: The JSON text to format
- indent_size (optional): Number of spaces for indentation (1-8). Defaults to 2.Example:
`json
{
"text": "{\"name\":\"John\",\"age\":30,\"city\":\"New York\"}",
"indent_size": 4
}
`Response:
`json
{
"result": "{\n \"name\": \"John\",\n \"age\": 30,\n \"city\": \"New York\"\n}"
}
`$3
Counts characters in text.
Parameters:
-
text: The text to analyzeExample:
`json
{
"text": "hello world"
}
`Response:
`json
{
"total_characters": 11,
"characters_without_spaces": 10
}
`$3
Replaces text.
Parameters:
-
text: The text to perform replacements on
- search: The string to search for
- replace: The string to replace with
- replace_all (optional): Whether to replace all occurrences. Defaults to true.Example:
`json
{
"text": "hello world",
"search": "world",
"replace": "universe"
}
`Response:
`json
{
"result": "hello universe"
}
`$3
Generates a UUID.
Parameters:
-
version (optional): UUID version to generate (v1, v4, v5, nil). Defaults to v4.
- namespace (optional): Namespace for v5 UUID (required for v5)
- name (optional): Name for v5 UUID (required for v5)
- uppercase (optional): Whether to return the UUID in uppercase. Defaults to false.Example:
`json
{
"version": "v4"
}
`Response:
`json
{
"uuid": "f47ac10b-58cc-4372-a567-0e02b2c3d479"
}
`$3
Generates lorem ipsum text.
Parameters:
-
count (optional): Number of units to generate. Defaults to 5.
- units (optional): Type of units to generate (words, sentences, paragraphs). Defaults to sentences.
- paragraphLowerBound (optional): Minimum sentences per paragraph. Defaults to 3.
- paragraphUpperBound (optional): Maximum sentences per paragraph. Defaults to 7.
- sentenceLowerBound (optional): Minimum words per sentence. Defaults to 5.
- sentenceUpperBound (optional): Maximum words per sentence. Defaults to 15.
- format (optional): Output format (plain, html). Defaults to plain.Example:
`json
{
"count": 2,
"units": "sentences"
}
`Response:
`json
{
"text": "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Ut hendrerit ipsum in nulla euismod, vel ultrices nisi tincidunt."
}
`$3
Tests a regex pattern against text.
Parameters:
-
text: The text to test against the pattern
- pattern: The regex pattern to test
- flags (optional): Regex flags (e.g., 'g', 'i', 'gi'). Defaults to 'g'.Example:
`json
{
"text": "hello world",
"pattern": "\\w+",
"flags": "g"
}
`Response:
`json
{
"matches": ["hello", "world"],
"match_count": 2,
"is_match": true
}
`💬 Example Queries in Claude Desktop
- "Convert 'hello world' to camelCase"
- "Encode 'hello world' to Base64"
- "Format this JSON: {\"name\":\"John\",\"age\":30}"
- "Count the characters in 'hello world'"
- "Replace 'world' with 'universe' in 'hello world'"
- "Generate a UUID"
- "Generate 2 sentences of lorem ipsum"
- "Test if 'hello world' matches the regex pattern '\\w+'"
- "Convert 'Hello World' to snake_case"
- "Decode this Base64 string: aGVsbG8gd29ybGQ="
💻 Technical Details
$3
TextToolkit is built using the Model Context Protocol (MCP) specification, which allows it to integrate seamlessly with Claude Desktop and other MCP-compatible clients. The server is implemented in TypeScript and uses the following architecture:
- Core Services: Implements text transformation, encoding/decoding, and formatting
- MCP Server: Handles JSON-RPC requests from clients
- Utility Functions: Provides helper functions for text operations
- Testing Framework: Includes comprehensive test scripts for verifying functionality
$3
- change-case - For case transformation operations
- crypto-js - For hash generation
- js-beautify - For code formatting and beautification
- uuid - For UUID generation and validation
- lorem-ipsum - For placeholder text generation
- @modelcontextprotocol/sdk - For MCP server implementation
$3
- Node.js 16.x or higher
- npm 7.x or higher
📝 Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
1. Fork the repository
2. Create your feature branch (
git checkout -b feature/amazing-feature)
3. Commit your changes (git commit -m 'Add some amazing feature')
4. Push to the branch (git push origin feature/amazing-feature)
5. Open a Pull Request🔍 Testing
TextToolkit includes comprehensive test scripts that can be used to verify the functionality of the MCP server. The test scripts can be used to test both stdio and SSE modes.
$3
`bash
Test stdio mode
node test-comprehensive.jsTest SSE mode
node test-sse-comprehensive.js
``TextToolkit processes all data locally and does not send any information to external servers. Your text data and queries remain private on your device.
MIT
Cicatriz