unfold-mcp
# Unfold MCP server
<!-- mcp-name: io.github.Bytestay/unfold-mcp -->
[](https://m8ven.ai/mcp/bytestay/unfold-mcp?s=readme)
[](https://github.com/bytestay/unfold-mcp/actions/workflows/ci.yml)
[](https://pypi.org/project/bytestay-unfold-mcp/)
[](https://pypi.org/project/bytestay-unfold-mcp/)
[](LICENSE)
[](https://registry.modelcontextprotocol.io/v0/servers?search=io.github.Bytestay/unfold-mcp)
[](https://glama.ai/mcp/servers/Bytestay/unfold-mcp)
[](https://mcprush.com/to/bytestay-unfold-mcp?ref=badge)
Give your AI agent the content of PDF, Word (DOCX), PowerPoint (PPTX) and Excel (XLSX) documents as Markdown, from a URL or a local file.
The server is open source (MIT). It calls the [Unfold API](https://unfold.bytestay.pt), which is paid, with a free plan.
- You use **your own key, from RapidAPI or api.market**.
- Every tool call is one request on your plan.
- The free Basic plan has 15 requests a month, with a hard limit, so it never runs up a bill.
## 1. Get a key
| marketplace | |
|---|---|
| RapidAPI | [plans](https://rapidapi.com/bytestay-bytestay-default/api/unfold-document-to-markdown-api/pricing) |
| api.market | [store](https://api.market/store/bytestay/unfold) |
## 2. Add the server to your MCP client
The server runs locally over stdio with [uv](https://docs.astral.sh/uv/). Put your key in its environment.
**JSON configuration** (Claude Desktop, Cursor, VS Code and most clients):
```json
{
"mcpServers": {
"unfold": {
"command": "uvx",
"args": ["--from", "bytestay-unfold-mcp", "unfold-mcp"],
"env": { "RAPIDAPI_KEY": "your-rapidapi-key" }
}
}
}
```
**Claude Code:**
```bash
claude mcp add unfold --env RAPIDAPI_KEY=your-rapidapi-key -- uvx --from bytestay-unfold-mcp unfold-mcp
```
### Environment
| variable | meaning |
|---|---|
| `RAPIDAPI_KEY` | your RapidAPI key |
| `API_MARKET_KEY` | your api.market key, used when `RAPIDAPI_KEY` is not set |
| `BYTESTAY_MARKETPLACE` | `rapidapi` or `apimarket`, when both keys are set |
Up to 0.2.7 the setting was `HFL_MARKETPLACE`. The old name still works, with a one-line notice on stderr.
Without a key the server still starts. The first tool call then explains where to get one.
Also listed on Glama:
[](https://glama.ai/mcp/servers/Bytestay/unfold-mcp)
## 3. Tools
| tool | what it does |
|---|---|
| `convert_document(url=… \| path=…, max_chars=20000)` | converts one document to Markdown; give a public URL, or a local file to upload |
The format is detected from the content.
Every tool returns the API's JSON response.
- When the marketplace reports it, `quota_remaining` is added: the requests left on your plan this month.
- Errors are explained in plain words, with what to do next:
- key refused, with the link to subscribe;
- quota reached, with the plans;
- input the API couldn't process, with the API's reason.
## Privacy
- Local files are read only when a tool is given their path, and are uploaded to the API for that one request. Only files inside the working directory (or the folder in `UNFOLD_MCP_ROOT`) are read, symlinks that leave it are refused, and only `.pdf`, `.docx`, `.pptx` and `.xlsx` (the content must match the type) are accepted.
- The API processes inputs in memory and doesn't store them. See the [privacy policy](https://unfold.bytestay.pt/privacy.html).
- Your key is only sent to the marketplace you chose.
## Limits
- Local files up to 10 MB.
- Markdown up to 500,000 characters.
- The server needs Python 3.10+ (uv installs it for you).
## Development
```bash
uv venv && uv pip install -e ".[dev]"
.venv/bin/pytest # unit tests, no network; 100% coverage required
.venv/bin/ruff check src tests scripts
```
`scripts/e2e_stdio.py unfold` runs the server over stdio, as a client would, and calls its tools against the real API. It needs `RAPIDAPI_KEY` or `API_MARKET_KEY`.
## History
Formerly Hybrid Forge Lab. This repository continues `hybridforgelab/unfold-mcp` under the ByteStay name since November 2026, so the older commits come from there.
## Licence
MIT. Unfold itself is a paid API with a free plan, run by [ByteStay](https://bytestay.pt).
TDQS
Scored across 1 tool
With only one tool exposed, there is nothing to confuse it with; an agent cannot misselect. The single tool's purpose (convert a document to Markdown from either a URL or local path) is unambiguous.
convert_document follows a clean verb_noun snake_case convention. There are no competing styles to create inconsistency.
The server is scoped to a single operation, so one tool is defensible, but the surface feels thin: no batch conversion, no format/option discovery, and no way to distinguish large-job handling. It sits at the borderline of a 1-tool server.
The core lifecycle of 'give a document, get Markdown' is fully covered for both URL and local path inputs, including upload handling. Minor gaps remain (batch/multi-file conversion, listing supported formats, or output-to-file options) that an agent must work around.