Text Processing
Generate clean URL slugs from any text, with built-in Chinese-to-Pinyin conversion. Collapse separators, lowercase, and optional max-length word-aware truncation.
Call this tool from your code in three languages.
curl -X POST 'https://api.elysiatools.com/en/api/tools/slug-generator' \
-H 'Content-Type: application/json' \
-d '{"text":"你好世界 这是第一篇文章","chineseMode":"pinyin","pinyinStyle":"no-tone","separator":"hyphen","case":"lowercase","maxLength":0}'Send a POST request with your inputs as JSON. File parameters require a separate upload first.
POST https://api.elysiatools.com/en/api/tools/slug-generator| Name | Type | Required | Description |
|---|---|---|---|
| text | textarea | Yes | — |
| chineseMode | select | Yes | — |
| pinyinStyle | select | Yes | — |
| separator | select | Yes | — |
| case | select | Yes | — |
| maxLength |
Add this tool to your Model Context Protocol server so AI agents can list and call it.
Add this block to your MCP client configuration:
{
"mcpServers": {
"elysiatools-slug-generator": {
"name": "slug-generator",
"description": "Generate clean URL slugs from any text, with built-in Chinese-to-Pinyin conversion. Collapse separators, lowercase, and optional max-length word-aware truncation.",
"baseUrl": "https://api.elysiatools.com/mcp/sse?toolId=slug-generator",
"command": "",
"args": [],
"env": {},
"isActive": true,
"type": "sse"
}
}
}After connecting to the SSE endpoint, list the exposed tools:
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/list"
}Invoke the tool by its id, passing arguments built from its parameters:
{
"jsonrpc": "2.0",
"id": 2,
"method": "tools/call",
"params": {
"name": "slug-generator",
"arguments": {
"text": "你好世界 这是第一篇文章",
"chineseMode": "pinyin",
"pinyinStyle": "no-tone",
"separator": "hyphen",
"case": "lowercase",
"maxLength": 0
}
}
}Questions or issues? Contact [email protected]
| number |
| No |
| — |
Text result
{
"result": "Processed text content",
"error": "Error message (optional)",
"message": "Notification message (optional)",
"metadata": {
"key": "value"
}
}