Skip to content

MESH-API v0.7.0 Beta First-Class MeshCore Support

Choose a tag to compare

@mr-tbot mr-tbot released this 10 Jun 00:09

MESH-API v0.7.0 BETA — Initial Full MeshCore Support Is Here!

You can now run MESH-API with EITHER a Meshtastic node, a MeshCore node — or BOTH at the same time, with MESH-API handling cross-network routing between them. MeshCore is no longer a half-baked bridge plugin; it is a first-class, core-owned radio on equal footing with Meshtastic. Slash commands, the AI assistant, and every extension now work across both networks, and the WebUI adapts to whichever radios you have connected.

⚠️ These features are widely untested and I am actively seeking community feedback on how to improve the implementation. If you run a Meshtastic-only, MeshCore-only, or dual-radio setup, please tell me what works, what breaks, and what you'd like to see — open a GitHub Issue. Your real-world reports directly shape the MeshCore implementation going forward.

MESH-API

MESH-API bridges Meshtastic and now MeshCore LoRa mesh networks with powerful AI chatbots, an MCP tool server, and 30+ extensions.

Disclaimer: This project is NOT ASSOCIATED with the official Meshtastic or MeshCore projects. It is provided solely as an extension to add AI and advanced features to your mesh network.

BETA Software Warning: v0.7.0 is a Beta with widely untested multi-radio features. Please avoid relying on it for mission-critical tasks or emergencies. Always have backup communication methods available and use responsibly.

I am one robot using other robots to write this code. Some features are still untested in the field. Check the GitHub issues for fixes or feedback!


🚀 Headline Features

MeshCore is now a first-class radio

  • Run Meshtastic only, MeshCore only (fully standalone — no Meshtastic device required), or both with MESH-API as the man-in-the-middle, routing traffic between the two networks.
  • MeshCore connects over serial / TCP / BLE and feeds the same network-agnostic pipeline as Meshtastic, so slash commands, the AI assistant, and every extension/plugin work on either network.
  • Staged startup + exponential backoff so two USB radios on a power-limited host (e.g. a Pi Zero) don't fight over the bus during connect.

WebUI parity for both networks

  • Per-network connection banner (📡 Meshtastic / 🟣 MeshCore, with live status).
  • Available Nodes network filter with collapsible Meshtastic / MeshCore sections.
  • Network badges on nodes and messages, distinct purple map markers for MeshCore, MeshCore channels / group chats in the send form, and DMs to MeshCore contacts — mirroring the Meshtastic experience.
  • A Network selector (Auto / Meshtastic / MeshCore / Both) appears when both radios are present, so you can send to one network or both at once.

MCP (Model Context Protocol) server — turn your mesh into an agentic backend

  • New built-in MCP server at POST /mcp (Streamable HTTP / JSON-RPC 2.0, no async deps). Lets external AI agents — Claude, Perplexity, Hermes, custom agents — call MESH-API core functions and extensions as tools, driving Meshtastic/MeshCore as a backend for advanced workflows.
  • Core tools for sending, listing nodes/messages/channels, AI queries, running commands, and MeshCore contacts. Every extension slash command is auto-exposed as an ext_cmd_* tool, and extensions can add richer typed tools via get_mcp_tools() + call_mcp_tool().
  • Disabled by default; bearer-token auth, Origin allowlist, rate limiting, and a gated emergency tool. See the README for setup (works directly or via the mcp-remote stdio bridge for clients like Claude Desktop).

Firmware & software update notifications

  • Detects the connected Meshtastic/MeshCore device and notifies you (🔄 Updates button + badge) when newer Meshtastic firmware, MeshCore firmware, or MESH-API is available.
  • Stable / beta / alpha release channels selectable per firmware (your device is not always a Heltec V3 — detection adapts to whatever is connected).
  • Optional one-click ESP32 over-USB flashing via esptool (off by default); nRF52/UF2 and MeshCore devices use the web flasher.

New: Hermes AI provider

  • Added Nous Research Hermes as an AI provider (ai_provider: "hermes") via their OpenAI-compatible inference API.

New: Channel Agents — per-channel AI personalities

  • Assign a dedicated AI provider/persona to individual mesh channels so different channels can answer with different models or system prompts.
  • Configurable in config.json (channel_agents block) and surfaced via the WebUI / GET /api/channel_agents. Assigned channels are handled by their agent and bypass the global reply-in-channels gating.

🐛 Bug Fixes

  • #59 — MeshCore-origin messages now reach plugins and the AI. Both radios funnel through one inbound pipeline, so a message that originates on MeshCore reaches Telegram, Discord, the AI provider, and every extension. Thanks to @lameritos for reporting. (GitHub Issue #59)
  • #58 — Reconnect hangs / no reconnection. Bounded Meshtastic (re)connect so a wedged Wi-Fi/TCP link (e.g. after a DHCP IP change) can no longer hang forever, and the connection watchdog is now actually started, with exponential reconnect backoff. Thanks to @lameritos and @droidblastnz. (GitHub Issue #58)
  • MeshCore ping/pong — the node now advertises itself (on connect + periodically) so peers can discover it and DM it; DM sends refresh contacts and retry on a miss.
  • !mc-unknown sender id — MeshCore channel broadcasts (which carry no per-sender crypto identity) no longer collapse every sender onto one id; a stable id is derived from the sender name.
  • OpenAI reasoning models (gpt-5, o1/o3/o4) now use max_completion_tokens, fixing empty AI replies.
  • Logging cascade — hardened script.log truncation against non-UTF-8 bytes that could spin into a RecursionError.

⚙️ New Config

Old configs keep working — the new keys are additive. New blocks in config.json:

  • meshtastic_enabled, default_send_network
  • meshcore (serial/TCP/BLE connection, reconnect tuning, cross-network channel bridging, adverts)
  • mcp (MCP server: enable, auth token, origins, rate limit, emergency gate)
  • firmware (update checks, release channels, optional flashing)
  • hermes_* (Hermes AI provider)
  • channel_agents (per-channel AI provider/persona assignments)

New requirements: meshcore>=2.3.7 (already in requirements.txt). ESP32 firmware flashing additionally needs esptool (commented/optional). Read the changelog in the README.


🐳 Docker

Multi-arch images for x86_64 and ARM64 (Raspberry Pi 4/5) are published to Docker Hub: mrtbot/mesh-api.

docker compose up -d   # dashboard at http://localhost:5000/dashboard

Built and maintained by one developer with the help of AI tools. If MESH-API is useful to you, please consider a donation (PayPal/crypto links in the README) and — most importantly — file issues with your real-world MeshCore experience. 🙏