AI-Native Web Traffic Debugging Tool
RelayCraft uses a modular 3-layer architecture to provide reliable traffic debugging with a modern interface.
graph LR
%% Style definitions
classDef client fill:#f9f9f9,stroke:#333,stroke-width:2px,color:#333
classDef engine fill:#e3f2fd,stroke:#1565c0,stroke-width:2px,color:#000
classDef backend fill:#fff3e0,stroke:#e65100,stroke-width:2px,color:#000
classDef frontend fill:#e8f5e9,stroke:#2e7d32,stroke-width:2px,color:#000
classDef ai fill:#f3e5f5,stroke:#7b1fa2,stroke-width:2px,color:#000,stroke-dasharray: 5 5
%% Node definitions
Traffic(["๐ Web Traffic<br/>(HTTP/HTTPS/WS)"]):::client
subgraph Core ["RelayCraft Architecture"]
direction LR
Engine["<b>Engine Layer</b><br/>Python / mitmproxy"]:::engine
Backend["<b>System Layer</b><br/>Tauri / Rust"]:::backend
UI["<b>UI Layer</b><br/>React / Zustand"]:::frontend
end
MCP["<b>๐ค AI Agent</b><br/>Claude, Cursor, etc."]:::ai
%% Connections
Traffic <==>|Proxy/Intercept| Engine
Engine <==>|IPC / HTTP API| Backend
Backend <==>|Tauri Commands| UI
MCP <.->|Model Context Protocol| Backend
RelayCraft is an AI-native network debugging tool for modern development. Built with Tauri, React, and Rust, it combines a proxy engine, AI-assisted workflows, and an extensible plugin system โ all running locally, with zero accounts required.
- ๐ค AI-Native Workflows: Create rewrite rules in natural language, analyze failed requests, and search traffic with plain language in one interface.
- ๐ MCP Server: Expose live traffic data and rule management to any external AI tool (Claude Desktop, Cursor, etc.) via the Model Context Protocol. Let your AI agent debug alongside you.
- ๐๏ธ Modern Architecture: A lightweight core built with Tauri and Rust, powered by the mitmproxy engine.
- ๐ก๏ธ Privacy First: Your data stays yours. Fully offline, zero accounts, local storage, local AI support, open source, and no telemetry.
- ๐ Scriptable & Extensible: Build custom traffic logic with mitmproxy Python hooks and extend the workspace through plugins and theming.
- ๐ก Capture: Inspect HTTP, HTTPS, and WebSocket traffic in real-time.
- ๐ Filter: Filter by method, domain, status code, or content type using a powerful query syntax.
- ๐ Detail Inspection: JSON highlighting, image previews, and structured header/body views.
- ๐ฆ Export: One-click export to cURL, HAR, or Relay Session (.relay).
Manage traffic behavior with a visual rule builder โ no config files needed. Supports 6 rule types:
| Action | Description |
|---|---|
| Map Local | Return custom content or redirect to a local file. |
| Map Remote | Forward traffic to a different URL or environment. |
| Rewrite Header | Modify request or response headers dynamically. |
| Rewrite Body | Change request/response content (JSON / Regex / Text). |
| Throttling | Simulate network conditions with custom Latency, Packet Loss, and Bandwidth limits. |
| Block Request | Intercept and block matching requests instantly. |
Real-time control to pause, edit, and resume flows in both Request and Response phases.
- Smart Matching: Support for wildcard path matching and RegEx for precise interception.
- On-the-fly Editing: Modify headers and body content before they reach the server or client.
- Edge Case Simulation: Useful for testing error handling, mock responses, and race-condition debugging.
A built-in API client designed for debugging, deeply integrated with your traffic history.
- Direct Replay: Swiftly replay any captured flow with a dedicated visual editor.
- Format Support: Full management of headers and body content (Raw, Form-Data, JSON).
- cURL Integration: Import requests from cURL strings with a single click.
- Instant Preview: View formatted responses (JSON, HTML, Assets) directly in the composer panel.
Use the mitmproxy Python ecosystem for scenarios beyond visual rules.
- Native Hooks: Write custom logic using standard mitmproxy event hooks.
- Modern Editor: Powered by CodeMirror 6 with syntax highlighting and auto-formatting.
- Dedicated Logging: Script outputs are centralized in a dedicated tab within the system logs for easy troubleshooting.
Global Ctrl(โ) + K command center with context-aware AI across every workflow:
- Natural Language Rules: Describe what you want intercepted or rewritten; AI builds the rule.
- Request Analysis: Generate request summaries and diagnostics, including rule hits, potential security issues, and optimization hints.
- Smart Search: Find specific traffic using natural language queries.
- Script Generation: Generate Python mitmproxy scripts from plain descriptions.
RelayCraft runs a built-in MCP (Model Context Protocol) server, letting any compatible AI client connect and work with your live traffic data.
Tip
This allows you to say to Claude or Cursor: "Find the failed requests from my local dev server and create a rule to mock a 500 error for all /api/v1/auth calls."
Read tools (no auth required โ zero config):
list_sessions/list_flows/get_flow/search_flows/get_session_stats/list_rules
Write tools (Bearer token, shown in Settings โ Integrations):
create_ruleโ create any of the 6 rule types using natural language parametersdelete_rule/toggle_ruleโ manage rules in the sessionreplay_requestโ replay captured traffic through the proxy
Compatible with Claude Desktop, Cursor, Windsurf, and any tool supporting the MCP HTTP transport.
- Node.js 20.19+ or 22.12+ (Vite compatibility; Node 21 is not supported)
- pnpm 9+ (install; this repo uses lockfile v9)
- Rust (stable toolchain)
- Python (3.10+)
# 1. Clone the repository
git clone https://github.com/relaycraft/relaycraft.git
cd relaycraft
# 2. Set up the Python Engine
# Follow the instructions in engine-core/README.md
# to build and place the engine binary in the required directory.
# 3. Install frontend dependencies
pnpm install
# 4. Start development mode
pnpm tauri devPre-built binaries for macOS, Windows, and Linux are available on the Releases Page.
- Contributing Guide โ Learn how to contribute to the project.
- Roadmap โ Product direction and upcoming milestones (GitHub Discussion).
- Commercial Use โ Sponsorship and enterprise licensing information.
- Plugin Registry โ Explore community-built plugins.
RelayCraft is open-sourced under the GNU GPL v3 or later. See the LICENSE file for details.
Crafted with โค๏ธ by the RelayCraft Team.

