KingBuilds MCP Server
This is a production-ready MCP server providing four core tools for sandboxed file operations, web scraping, data transformation, and authenticated HTTP requests.
File Operations: Read, write, and list files within a sandboxed directory (
/app), with path traversal protection, size limits, and automatic parent directory creation.Web Scraping: Fetch public web pages to extract titles, visible text (scripts/styles stripped), outgoing links, or specific elements via CSS selectors. Includes SSRF protection blocking private/loopback addresses.
Data Transformation: Convert between JSON and CSV formats, and perform aggregations (sum, average, min, max, count, unique) on structured or flat data.
HTTP Requests: Make authenticated HTTP requests (GET, POST, PUT, PATCH, DELETE, HEAD) to public APIs with custom headers, query params, and flexible request bodies. Supports server-managed authentication (Bearer token or API key) and SSRF protection on every redirect hop.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@KingBuilds MCP Serverscrape the title and links from https://example.com"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
KingBuilds MCP Server
Production-ready reference MCP server with 4 tools:
file_ops — Sandboxed file read/write/list within allowed directory
web_scraper — Clean HTML extraction (title, text, links, CSS selectors)
data_transform — JSON↔CSV conversion + aggregation (sum/avg/count/min/max/filter/sort)
http_request — Authenticated HTTP requests with SSRF protection
Architecture
This server is built on the Soliven architecture — the autonomous build agent running on this VPS. Shared patterns:
Component | Purpose | Soliven Reference |
| Path traversal protection, SSRF-safe URL validation | Soliven sandbox |
| Safe HTTP client with redirect validation | Soliven outbound requests |
| Pydantic Settings with | Soliven config |
Dual transport | stdio (Claude Desktop) + HTTP/SSE (web) | Soliven multi-interface |
Structured logging | Consistent format across all tools | Soliven observability |
Related MCP server: Enhanced Fetch MCP
Quickstart
# Install
pip install -e .
# Run stdio transport (for Claude Desktop)
mcp-server-stdio
# Run HTTP/SSE server
mcp-server-httpConfiguration
Environment variables:
ALLOWED_DIR— Sandbox directory for file operations (default:./data)MCP_TRANSPORT—stdioorstreamable-http(default:streamable-http)MCP_HOST— Host to bind (default:0.0.0.0)MCP_PORT— Port for HTTP transport (default:8080)MAX_FILE_BYTES— Max file size for read/write (default:1048576)REQUEST_TIMEOUT— HTTP request timeout seconds (default:30)
Tools
file_ops
read_file(path: str)— Read UTF-8 text filewrite_file(path: str, content: str, overwrite: bool)— Write filelist_directory(path: str)— List directory contents
Example prompts:
"Read the README.md file and summarize it"
"Create a file called todo.txt with my task list"
"List all files in the data directory"
web_scraper
fetch_page(url: str, selector: str = None)— Fetch and extract HTML content
Example prompts:
"Fetch the latest headlines from Hacker News"
"Get the title and main text from this article URL"
"Extract all links from this page matching
.titleline a"
data_transform
transform_data(data: list, operation: str, **kwargs)— Transform data
Example prompts:
"Convert this JSON data to CSV"
"Calculate the average score from this data"
"Sum these numbers: [10, 20, 30, 40, 50]"
"Count unique values in the 'category' field"
http_request
http_request(method: str, url: str, headers: dict, body: dict, auth: dict)— Make HTTP requests
Example prompts:
"Call this API endpoint and return the JSON response"
"POST this data to the webhook with Bearer auth"
Example Tool Calls (MCP JSON-RPC)
file_ops
{"name": "read_file", "arguments": {"path": "README.md"}}
{"name": "write_file", "arguments": {"path": "notes.txt", "content": "Hello from MCP!", "overwrite": true}}
{"name": "list_directory", "arguments": {"path": "."}}web_scraper
{"name": "scrape_web_page", "arguments": {"url": "https://example.com"}}
{"name": "scrape_web_page", "arguments": {"url": "https://news.ycombinator.com", "selector": ".titleline a", "max_links": 10}}data_transform
{"name": "transform_data", "arguments": {"data": "[{\"name\": \"Alice\", \"age\": 30}, {\"name\": \"Bob\", \"age\": 25}]", "input_format": "json", "operation": "convert", "output_format": "csv"}}
{"name": "transform_data", "arguments": {"data": "[10, 20, 30, 40, 50]", "input_format": "json", "operation": "sum"}}
{"name": "transform_data", "arguments": {"data": "[{\"score\": 85}, {\"score\": 92}, {\"score\": 78}]", "input_format": "json", "operation": "average", "field": "score"}}http_request
{"name": "http_request", "arguments": {"method": "GET", "url": "https://api.github.com/users/octocat"}}
{"name": "http_request", "arguments": {"method": "POST", "url": "https://api.example.com/data", "headers": {"Content-Type": "application/json"}, "body": {"key": "value"}, "auth": {"scheme": "bearer", "token": "your-token-here"}}}Claude Desktop Config
{
"mcpServers": {
"kingbuilds-mcp": {
"command": "mcp-server-stdio",
"env": {
"ALLOWED_DIR": "/home/user/data"
}
}
}
}Deployment
# Docker
docker-compose up -d
# Systemd
sudo cp deploy/systemd/claude-mcp-server.service /etc/systemd/system/
sudo systemctl enable --now claude-mcp-serverSecurity
File operations sandboxed to
ALLOWED_DIRwith path traversal protectionSSRF protection: private/loopback/link-local IPs blocked by default
Request size/timeouts enforced
Input validation on all tool inputs
License
MIT
Available Tools
6 toolshttp_requestA
Make an authenticated HTTP request to a public API. The server attaches its own configured credential (bearer token or API key) — do not attempt to pass Authorization headers yourself, they will be ignored. GET/POST/PUT/PATCH/DELETE/HEAD supported. Blocks requests to private, loopback, link-local, and other non-public addresses, and re-validates every redirect hop.
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | ||
| body | No | ||
| method | No | GET | |
| headers | No | ||
| json_body | No | ||
| query_params | No |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Without annotations, the description discloses key behaviors: automatic credential attachment, ignoring Authorization headers, blocking non-public addresses, and redirect validation. No rate limits or error details are mentioned.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Three concise sentences front-load the purpose, then provide specific behavioral details and constraints. Every sentence adds value.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Covers major behavioral aspects and constraints. Lack of parameter-level details is a gap, but output schema exists to describe return values. Could mention error handling or response format.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 0%, so the description must compensate. It adds context about methods and Authorization header restrictions, but does not explain parameters like body, json_body, query_params, or headers beyond the auth note. Parameter names are self-explanatory, but more detail would help.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: making authenticated HTTP requests to public APIs, listing supported HTTP methods, and explicitly distinguishing itself from sibling tools by noting it handles authentication and blocks non-public addresses.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Provides clear context for when to use (public APIs) and what not to do (avoid Authorization headers). However, it does not explicitly state when alternatives like scrape_web_page might be more appropriate.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_directoryA
List files and subdirectories within the server's sandboxed directory (/app). Path is relative to that directory ('' or '.' for the root).
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | . |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided. The description discloses the base directory and relative path, but lacks details on permissions, error behavior for invalid paths, whether hidden files are listed, or depth of listing. Basic behavior is clear but not comprehensive.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences with front-loaded purpose. No redundant information. Every sentence adds value.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Low complexity tool with one parameter. Output schema likely covers return format. The description provides the essential context (base path, relative paths) but could mention recursion or sorting behavior. Adequate for the simplicity.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema has 0% description coverage for the path parameter. The description adds meaning by explaining path is relative to /app and defaults to '.', which compensates. However, it does not mention if subdirectory traversal or patterns are supported.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states it lists files and subdirectories within the sandboxed directory /app. The verb 'list' and resource are explicit. The sibling tools include read_file and write_file, so this is distinct.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage for exploring the sandboxed directory. It explains path relative to root and default. However, it does not explicitly state when not to use or mention alternatives like read_file for file contents.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
read_fileA
Read a UTF-8 text file from within the server's sandboxed directory (/app). Path is relative to that directory. Refuses files above the configured size limit or outside the sandbox.
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries full burden and discloses key behaviors: reads UTF-8, respects sandbox boundaries, enforces size limits. However, it does not mention error responses or encoding handling beyond UTF-8.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences, front-loaded with action, immediately clarify constraints. No wasted words.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's simplicity (1 param, output schema exists), the description covers core constraints. It does not describe return format, but the output schema presumably does so.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The description adds meaning to the 'path' parameter by clarifying it is relative to /app, which the schema lacks. However, it does not specify allowed formats or restrictions (e.g., no parent directory traversal).
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool reads UTF-8 text files, specifies the sandboxed directory, and implicitly distinguishes from siblings like write_file and list_directory by focusing on reading file contents.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides context (sandbox, size limit) but does not explicitly state when to use this tool versus alternatives (e.g., list_directory for browsing, http_request for external files). Usage is implied but not contrasted.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
scrape_web_pageA
Fetch a public web page and extract its content. Without selector, returns the page title, visible text (script/style stripped), and outgoing links. With selector, returns the text of every element matching that CSS selector instead. Blocks requests to private, loopback, link-local, and other non-public addresses.
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | ||
| selector | No | ||
| max_links | No |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Despite no annotations, the description discloses key behaviors: it blocks non-public addresses, returns different content with/without selector, and specifies exact return components (title, text, links). However, it does not mention error handling, rate limiting, or behavior for invalid selectors, which are minor gaps.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is concise with four sentences, each adding essential information: core function, selector behavior, security constraint, and return details. No redundancy or fluff.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool has an output schema (so return format is covered), the description explains core behavior, selector usage, and security. However, it omits explanation of `max_links` and edge cases like non-matching selectors, leaving slight gaps for an agent.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, so the description must compensate. It explains `url` (the page to fetch) and `selector` (CSS selector for targeted extraction), but does not explain `max_links` (default 50) – likely limiting outgoing links, but not stated. Partial compensation, one parameter unclear.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool fetches a public web page and extracts content, distinguishing behavior with or without a CSS selector. It also clarifies it blocks non-public addresses, making the purpose unambiguous and different from siblings like http_request or read_file.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage for public web pages and mentions blocking of private addresses, but it does not explicitly guide when to use this tool over alternatives (e.g., http_request for raw content) or state when not to use it. Usage context is implied but not fully explicit.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
transform_dataA
Transform or aggregate tabular/record data. operation='convert' converts between JSON (array of objects) and CSV (requires output_format). operation in {sum, average, min, max, count, unique} aggregates a single field across the records (omit field if data is a flat JSON array of numbers).
| Name | Required | Description | Default |
|---|---|---|---|
| data | Yes | ||
| field | No | ||
| operation | Yes | ||
| input_format | Yes | ||
| output_format | No |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the full burden. It explains the two operational modes and specific parameter behavior (omit field for flat arrays). However, it lacks disclosure of side effects, error handling, performance implications, or output format expectations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is exceptionally concise—two sentences that front-load the general purpose and then dive into specifics. Every sentence adds value without redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool has 5 parameters and no annotations, the description adequately covers two major use cases but lacks details on edge cases, return structure (though an output schema exists), and behavior for all combinations of parameters.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, so the description adds critical meaning: it explains operation values, field omission rule, and output_format necessity. Yet input_format and data format expectations remain unspecified, leaving some parameters underdocumented.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states that the tool transforms or aggregates tabular/record data, and specifies two modes: conversion and aggregation. It provides operation names and distinguishes between them.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description gives explicit guidance on when to use conversion (operation='convert') versus aggregation operations, and includes a special case for flat arrays. Although no comparisons to sibling tools are needed, it provides clear operation-specific context.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
write_fileA
Write UTF-8 text to a file within the server's sandboxed directory (/app). Path is relative to that directory. Creates parent directories as needed; refuses to write outside the sandbox or above the configured size limit.
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | ||
| content | Yes | ||
| overwrite | No |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Discloses key behaviors: UTF-8 encoding, sandbox directory, parent directory creation, and size limit refusal. Lacks details on overwrite=false behavior and encoding error handling, but good given no annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two concise sentences, front-loaded with main action, no redundant information.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Covers sandbox, encoding, directory creation, size limit, but lacks error handling details and default overwrite behavior. Output schema exists but not referenced.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Describes path as relative and content as UTF-8 text, but does not mention the overwrite parameter. With 0% schema coverage, partially compensates.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Clearly states it writes UTF-8 text to a file within a sandboxed directory, distinguishing from sibling tools like read_file and list_directory.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Implies usage via sandbox context but does not explicitly state when not to use or provide alternatives beyond the sandbox restriction.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
6 tool updates
v0.1.0- First observed
http_request - First observed
list_directory - First observed
read_file - First observed
scrape_web_page - First observed
transform_data - First observed
write_file
TDQS
Scored across 6 tools
Each tool targets a distinct operation: HTTP requests, directory listing, file reading, web scraping, data transformation, and file writing. No two tools overlap in purpose, making selection unambiguous.
Five of six tools follow a verb_noun pattern (list_directory, read_file, scrape_web_page, transform_data, write_file). http_request breaks the pattern as it is noun_noun, creating a minor inconsistency.
With six tools, the server offers a focused set covering file operations, web access, and data manipulation. The count is appropriate for the scope and doesn't feel sparse or bloated.
The set covers core capabilities: file read/write, directory listing, HTTP requests, web scraping, and data transformation. Missing operations like file deletion or appending are minor gaps given the sandboxed environment.
Maintenance
Related MCP Connectors
Sandbox workspace tools: search, file read, DB queries, integrations. Returns synthetic data.
Manage websites, help documents and customer-support conversations with safe, scoped tools.
Host static HTML pages, generate PDFs, screenshots, scrape JS sites, run sandboxed JavaScript.
Prompt-injection scanning and safe webpage fetching for AI agents reading untrusted content.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceProvides secure filesystem operations, HTTP fetching with SSRF protection, JSON validation, artifact logging, and optional Redis key-value storage through both stdio and HTTP transports. Features production-ready security controls including sandbox enforcement, allowlist validation, and comprehensive input validation.Apache 2.0
- AlicenseNot gradedqualityDmaintenanceProvides advanced web scraping with HTTP client, smart content extraction to Markdown, browser automation via Playwright, screenshot/PDF generation, and Docker sandbox execution environments.1MIT
- AlicenseNot gradedqualityAmaintenanceProvides sandboxed code execution for AI agents with support for Python, JavaScript, and shell commands. Includes comprehensive safety features like destructive pattern blocking, timeout protection, and restricted file access for secure production use.9 npm65 PyPIMIT
- FlicenseCqualityDmaintenanceProvides secure file system, web fetching, and Google Cloud Storage access for AI IDEs.6-