cd /news/ai-agents/flisk-mcp-resources-give-your-agents… · home › topics › ai-agents › article
[ARTICLE · art-156733] src=dev.to ↗ pub= topic=ai-agents verified=true sentiment=↑ positive

Flisk MCP Resources: Give Your Agents Tools That Run Next to Your Services

Flisk introduced an 'mcp' resource type that scaffolds a stateless Model Context Protocol server running inside a project's local stack, built by Docker, started with 'flisk up', routed through Traefik, and gated on a /health route. The generated server, written in TypeScript on the MCP SDK with Streamable HTTP transport, registers a placeholder 'echo' tool and validates arguments with zod schemas so bad input returns an MCP error instead of crashing. The scaffold ships without authentication and is intended only for local development behind *.localhost.

by read2 min views3 publishedOct 24, 2026

Agents are only as useful as the tools they can call. An mcp resource in Flisk is a Model Context Protocol server that runs in the same local stack as your services. Docker builds it, flisk up starts it, Traefik routes to it, and its health route gates startup order.

flisk resource docs-mcp --type mcp --stack shop
flisk up shop

The scaffold writes a service.json with appType: "mcp", a port from 4000 to 5999, and /health as the health path. It has no framework or language setting and no backend features such as Prisma. The server source lives in src/index.ts, built on the MCP TypeScript SDK with the Streamable HTTP transport. It registers one placeholder tool, echo, so you can see the shape before you add your own.

The server answers three paths. POST /mcp is the endpoint clients use. GET /mcp returns 405 with Allow: POST, because the scaffold is stateless and does not open server-to-client streams. GET /health returns a small JSON status, which Traefik uses.

It is stateless on purpose. Each request gets a fresh server instance, so there is no session to lose when the container restarts.

Through Traefik, the resource is routed like a backend, with the name prefix stripped. A resource called docs-mcp in a project called shop is at http://api.shop.localhost/api/docs-mcp/mcp.

You can check it with a raw JSON-RPC call. The accept header must list both application/json and text/event-stream:

curl -s -X POST http://api.shop.localhost/api/docs-mcp/mcp \
  -H 'content-type: application/json' -H 'accept: application/json, text/event-stream' \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}'

Tools are registered in buildServer() in src/index.ts, with the SDK's registerTool. Arguments are described with zod schemas. Invalid arguments come back as an MCP error result rather than a crash, which keeps an agent's mistake from taking the server down.

The scaffold has no authentication. The docs say it is meant for local development behind *.localhost. Do not expose it beyond your machine without adding auth, and do not give it tools that change production data.

The tools you add are your code. A tool that runs a query can run any query you let it run, so scope what the tool can reach.

A tool that lives in the same stack as the database it queries is tested under the same conditions as the rest of the system: the same network, the same start order, and the same readiness checks. A tool that runs as a loose script outside the stack is harder to keep honest.

An mcp resource is a stateless MCP server in your stack, reached through the gateway, with a health route and a placeholder tool. Add tools in buildServer(), validate their arguments, and keep the server local until you have added authentication.

── more in #ai-agents 4 stories · sorted by recency
── more on @flisk 3 stories trending now
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain — perfect for shipping the agent you just read about.

$git push zahid main
→ Live at https://your-agent.zahid.host ✓
Get free account → Pricing
from €0/mo · no card required
LIVE [news/flisk-mcp-resources-…] indexed:0 read:2min 2026-10-24 · —