Strata MCP Server

Strata MCP Server

Enables LLMs to model, validate, and analyze multi-cloud infrastructure as a typed graph, with tools for IaC import/export, cost estimation, and architecture review.

Category
访问服务器

README

Strata

Live app: strata.mk-dir.com

Strata — a multi-cloud architecture diagram with the service palette, layers/overlays, inspector, validation, and cost estimate

A registry-driven canvas for modeling cloud infrastructure as a typed graph. Drag services onto a canvas, configure them with auto-generated forms, and connect them with typed relationships (contains, routes_to, invokes, peers_with, …) — with a multi-cloud catalog spanning AWS, Google Cloud and Azure. It can also import existing Infrastructure-as-Code — CloudFormation (JSON/YAML), Terraform show -json (AWS/GCP/Azure) and Azure ARM — into the same graph, export the graph back out as IaC, and ingest live cloud state via provider discovery APIs.

On top of the graph sits a layer of pure analysis engines — validation with one-click autofix, true internet-reachability evaluation, an "Explain & Clean" account review (cost + risk + a safe-cleanup checklist), cross-cloud migration mapping, a change/audit receipt between any two versions, tag tinting/filtering, canvas annotations, and a Diagram-as-Code DSL — all exposed both in the UI and over MCP.

MCP server

An LLM/agent can drive Strata over the Model Context Protocol. The server (src/mcp/server.ts) is a thin wrapper over the same pure engines the app uses — registry, validation, IaC import/export, and cost — so an agent can query and transform a graph exactly as the UI does. No DOM, network, or credentials.

Run it (stdio transport; uses npx tsx, no build step):

npm run mcp

Then point an MCP client at that command, e.g.:

{
  "mcpServers": {
    "strata": { "command": "npm", "args": ["run", "mcp"], "cwd": "/path/to/strata" },
  },
}

Tools: list_services, get_service, validate_architecture, suggest_rules, import_iac, export_iac, estimate_cost, review_account (cost + risk + safe-cleanup report), evaluate_reachability (true internet-reachability, not topology), map_to_cloud (cross-cloud equivalence), graph_to_dsl / graph_from_dsl (Diagram-as-Code round-trip), list_autofixes / apply_autofix (deterministic validation fixes), change_receipt (audit receipt of what changed between two graphs), tag_report.

Live cloud discovery is separate — it runs through a Cloud Control SDK route (src/app/api/discover/route.ts); src/aws/mcp.ts is the pure transform behind it. See CONTRIBUTING.md for the architecture.

The core idea: everything visual is derived from a data registry, not hardcoded. Adding a new AWS service is a single catalog entry — no UI changes.

Strata is open source. Contributions welcome.

Documentation

Strata ships its docs as part of the app, served at /docs, in two public sections:

  • User Guide (/docs/guide) — how to use the app: building diagrams, importing IaC, validation, and saving/loading.
  • Architecture & Engineering (/docs/architecture) — how it works internally: the service registry, domain model, persistence, MCP/IaC import, testing, and the roadmap.

The docs are authored as Nextra MDX under src/content/.

Quick Start

Strata is now a single app: npm run dev serves the product at / and the docs at /docs.

npm install
npm run dev
  • Product: http://localhost:3000/
  • Docs: http://localhost:3000/docs

Saved diagrams persist in your browser (localStorage) — no external infrastructure required, and it works on a read-only serverless host. Use Export / Import JSON to move a diagram between browsers or share it. (The server-side Repository + /api/graphs route remain for a future durable backend, but the app no longer relies on them for saving.)

Other scripts

npm run build   # production build (compiles the product and prerenders the docs)
npm run start   # run the production build
npm run lint    # lint
npm test        # run the Vitest suite

Configuration

Env var Default Purpose
AWS_FLOW_REPOSITORY file Backend for the retained server tier (not used by browser-local save).
AWS_FLOW_DATA_DIR .data/graphs Directory for the file-backed store (retained server tier only).
AWS_FLOW_API_TOKEN (unset) If set, the graph API requires Authorization: Bearer <token>.
NEXT_PUBLIC_STRATA_HOSTED (unset) Set to 1 on any shared/hosted deployment (see below).
STRATA_INTEREST_WEBHOOK (unset) Incoming-webhook URL to notify on "coming soon" interest (see below).

"Coming soon" interest notifications

When NEXT_PUBLIC_STRATA_HOSTED=1, clicking a "coming soon" prompt's "I'd use this" button POSTs a tiny { feature, note? } signal to the same-origin /api/interest route (it's skipped locally — there's nothing to collect on a single-user box). That route, with no datastore and no npm dependency:

  • always logs the signal (so it shows in your host's function logs, e.g. Vercel), and
  • if STRATA_INTEREST_WEBHOOK is set, forwards a short message to that incoming-webhook URL. Use whatever gives you a notification with zero infra — a Slack or Discord incoming webhook (phone push), ntfy.sh (push), or a webhook→email relay. The body sends both text (Slack) and content (Discord), so one URL works for either. No credentials are involved, and the endpoint accepts only a small validated payload.

Live discovery & credentials

The Connect to AWS → Live scan flow runs server-side. With no credentials in the request, it uses the server process's default credential chain (env vars / shared profile / SSO / instance role) — fine for a single-user local run, where those are your own credentials.

On a shared/hosted deployment that ambient chain would be the operator's account, so any visitor could enumerate it. Set NEXT_PUBLIC_STRATA_HOSTED=1 (at build and runtime) to disable the ambient fallback: each user must then bring their own AWS credentials, entered in the modal and sent over HTTPS for a single scan. Those keys are used in-memory only — never written to disk, logged, returned, or saved into a diagram. Users should supply temporary, read-only credentials (e.g. aws sts get-session-token, or an assumed ReadOnlyAccess role). The credential-free Paste export tab remains available either way.

Project Structure

src/
  aws/                  Registry + domain model (the data foundation)
    types.ts            ServiceDefinition, ConfigField, RelationshipKind, scopes
    registry.ts         Aggregates catalogs; lookups, search, validateRegistry()
    categories.ts       Category + relationship presentation metadata
    model.ts            InfrastructureGraph / ResourceInstance / Relationship, validateGraph()
    regions.ts          AWS region reference list
    rules.ts            Architecture validation + best-practice rule suggestions
    relationshipClasses.ts  Edge visual encoding (colour/dash/arrowhead per class)
    overlays.ts         Analytical overlays (IAM-trust, network path, heat, reachability, tags) — pure
    reachability.ts     Policy-aware internet-reachability eval (subnets/routes/SG ports) — pure
    review.ts           "Explain & Clean" account review: cost + risk + safe-cleanup checklist — pure
    cloudMap.ts         Cross-cloud equivalence / migration (serviceId+provider rewrite) — pure
    autofix.ts          Deterministic fixes for validation findings (detect + apply) — pure
    receipt.ts          Change/audit receipt between two graphs (drift + cost + findings) — pure
    tags.ts             Tag collection + tint map + tag filter — pure
    annotations.ts      Notes / callouts / zones pinned to the canvas (excluded from rules/cost/IaC) — pure
    dsl.ts              Diagram-as-Code: graph ⇄ YAML round-trip — pure
    iac.ts              IaC import (CloudFormation + Terraform → InfrastructureGraph)
    iacExport.ts        IaC export (InfrastructureGraph → CloudFormation / Terraform scaffold)
    mcp.ts              Pure transform: DiscoveredResource[] → graph (mapDiscoveredToGraph)
    discovery.ts        Cloud Control descriptions → DiscoveredResource[] (no AWS SDK here)
    services/*.ts       Per-category service catalogs (networking.ts is the template)
  canvas/               Pure geometry + containment layout (geometry.ts, layout.ts)
  server/               Retained server tier (kept for a future durable backend)
    repository.ts       Repository interface
    fileRepository.ts   Default file-backed store
    graphSchema.ts      Zod schema for graph validation
    auth.ts             Optional bearer-token guard (AWS_FLOW_API_TOKEN)
    index.ts            getRepository() — backend selection via env
  lib/
    localStore.ts       Browser localStorage save/load (the active persistence path)
    api.ts              Fetch client for the graph + discover APIs (discover is live)
  app/
    (product)/          The Strata canvas app, served at /
    (docs)/             Nextra docs, served at /docs
    api/graphs/         Graph REST Route Handlers (GET/POST, GET/PUT/DELETE by id)
    api/discover/       Live discovery Route Handler (Cloud Control SDK, server-only)
  components/           UI: Palette, Canvas, Inspector, CommandPalette
  hooks/                Canvas state, rendering, interaction, undo/redo
  content/              Nextra MDX docs (User Guide + Architecture), served at /docs

Adding a new AWS service

Append one ServiceDefinition to the matching catalog in src/aws/services/ (use networking.ts as the template) — the palette, colours, icons, inspector form, and search pick it up automatically. See the Service Registry docs.

Architecture

For the full design — registry schema, domain model, the registry-driven UI, the swappable persistence layer, MCP ingestion readiness, and a candid list of gaps and next steps — see the Architecture & Engineering docs (src/content/architecture/).

Roadmap

What's shipped, the active follow-ups, and what's deferred until a backend exists: see ROADMAP.md.

Tech Stack

Next.js (App Router) · React · TypeScript · Tailwind CSS · Nextra (docs).

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选