---
name: fastmesh-universal-sdk-publisher
description: Agent handbook for W5-T05 FastMesh Universal SDK & MCP Publisher (https://sdk.fastmesh.dev, port 9045) — one-command npx fastmesh-mcp and uvx fastmesh-mcp access to 46+ deterministic *.fastmesh.dev engines with a <2.5 KB MCP Superbus tool surface, hard max_cost_micros budget locks, $0-on-miss receipts, and strict Zero Data Resale.
---

# FastMesh Universal SDK & MCP Publisher (`sdk.fastmesh.dev`) — Agent Skill Handbook

> **Hard Guarantees**: Zero third-party runtime dependencies on npm (Node `>=18`) and PyPI (pure Python 3 stdlib `>=3.9`) · Serialized MCP `tools/list` strictly **`< 2,500` bytes** (`< 2.5 KB`) · Hard caller budget lock via `max_cost_micros` / `X-Max-Cost-Micros` · **Strictly `$0` billed (`billed_micros: 0`, `billable: false`)** on search misses, HTTP `422` validation errors, budget refusals, and upstream errors · **Strict Zero Data Resale (`zero_data_resale: true`)** · Zero plaintext secrets ever written to disk.

## Integration Surfaces

| Surface | Endpoint / Command | Protocol & Guarantees |
| :--- | :--- | :--- |
| **Node.js One-Liner (npm)** | `npx -y fastmesh-mcp` | Zero dependencies, stdio MCP + CLI (`search`, `list`, `call`, `balance`, `topup`, `doctor`) |
| **Python One-Liner (PyPI)** | `uvx fastmesh-mcp` | Pure Python 3 stdlib, sync + concurrent `call_batch()`, stdio MCP + CLI |
| **POSIX Installer** | `curl -fsSL https://sdk.fastmesh.dev/install.sh \| sh` | Detects `npx`, `uvx`, or `python3`; prints portable MCP JSON; zero secrets |
| **Live Remote MCP Server** | `POST https://sdk.fastmesh.dev/mcp` | JSON-RPC 2.0 (`initialize`, `tools/list` `< 2500` bytes, `tools/call`) |
| **FastMesh Superbus MCP** | `https://mcp.fastmesh.dev/mcp` | Unified routing hub for all `46+` `*.fastmesh.dev` engines |
| **Package & Release API** | `GET https://sdk.fastmesh.dev/api/packages` | npm, PyPI wheel/sdist, GitHub Release SHA-256 checksums, safe publish status |
| **Endpoint Catalog API** | `GET https://sdk.fastmesh.dev/api/endpoints` | Search/filter all `46+` `*.fastmesh.dev` engines by query, category, or status |
| **OpenAPI 3.1.0 Spec** | `GET https://sdk.fastmesh.dev/openapi.json` | Machine-readable contract for all routes |
| **Treg Hub (0% Commission)** | `singularity.fastmesh-universal-sdk-publisher` | `$0.005` verified call, hard cap `$0.10`, strictly `$0` on miss/422/budget lock |
| **Causal Bazaar Hand** | `t05_fastmesh_universal_sdk_publisher_hand_v1` | `is_public=1`, `card_id: t05_fastmesh_universal_sdk_publisher_v1`, `price_micros: 10000` |
| **10-Second Prepaid Top-Up** | `https://pay.fastmesh.dev` | Starter (`$19`), Pro (`$79`), Scale (`$249`) never-expiring credit packs |

Support: `support@fastmesh.dev`

---

## 1. Calling Live Remote `/mcp` (JSON-RPC 2.0)

Exposed compact meta-tools (`tools/list` strictly `< 2,500` bytes):
1. `fastmesh_search` — Search `46+` `*.fastmesh.dev` engines (`$0` on zero-match miss)
2. `fastmesh_package_status` — Inspect npm, PyPI, GitHub Release checksums and safe Vault publish readiness
3. `fastmesh_install_snippet` — Generate portable MCP client config (`npx`, `uvx`, `python`, `curl`, `http_mcp`)
4. `fastmesh_topup_quote` — Calculate estimated call spend and return direct `pay.fastmesh.dev` / Creem checkout links

```bash
# 1. Inspect <2.5 KB MCP tools/list surface
curl -fsSL -X POST "https://sdk.fastmesh.dev/mcp" \
  -H "Content-Type: application/json" \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/list","params":{}}'

# 2. Search engines with a hard max_cost_micros budget lock
curl -fsSL -X POST "https://sdk.fastmesh.dev/mcp" \
  -H "Content-Type: application/json" \
  -H "X-Max-Cost-Micros: 100000" \
  -d '{
    "jsonrpc": "2.0",
    "id": 2,
    "method": "tools/call",
    "params": {
      "name": "fastmesh_search",
      "arguments": {"query": "verify", "limit": 10, "max_cost_micros": 100000}
    }
  }'
```

---

## 2. Portable MCP Client Configuration (`npx` & `uvx`)

Works with any MCP-compatible coding editor, terminal, or autonomous AI agent runtime:

```json
{
  "mcpServers": {
    "fastmesh": {
      "command": "npx",
      "args": ["-y", "fastmesh-mcp"],
      "env": {
        "FASTMESH_MCP_URL": "https://mcp.fastmesh.dev/mcp",
        "FASTMESH_MAX_COST_MICROS": "100000"
      }
    }
  }
}
```

Python `uvx` equivalent:

```json
{
  "mcpServers": {
    "fastmesh": {
      "command": "uvx",
      "args": ["fastmesh-mcp"],
      "env": {
        "FASTMESH_MCP_URL": "https://mcp.fastmesh.dev/mcp",
        "FASTMESH_MAX_COST_MICROS": "100000"
      }
    }
  }
}
```

---

## 3. Hard `max_cost_micros` Budget Lock & `$0`-on-Miss Receipts

- Every tool call checks `max_cost_micros` (argument or `X-Max-Cost-Micros` header) before execution.
- If `max_cost_micros` is below the call cost, the server refuses immediately with `error_code: "budget_exceeded"`, `billed_micros: 0`, `billable: false`, and a deterministic `receipt_sha256`.
- If `fastmesh_search` matches zero engines or `fastmesh_topup_quote` targets an unknown engine, the response returns `billed_micros: 0`, `billable: false`, `zero_on_miss: true`.

---

## 4. Creem Prepaid Packs & Webhook Security (`POST /webhooks/creem`)

| Pack | SKU ID | Flat Price | Credits Granted |
| :--- | :--- | :---: | :--- |
| **Starter** | `sku_sdk_universal_starter_19` | **$19** | `2,000` credits (`20,000,000` micros, never expires) |
| **Pro** | `sku_sdk_universal_pro_79` | **$79** | `10,000` credits (`100,000,000` micros, never expires) |
| **Scale** | `sku_sdk_universal_scale_249` | **$249** | `40,000` credits (`400,000,000` micros, never expires) |

`POST /webhooks/creem` validates `creem-signature` / `X-Creem-Signature` using HMAC-SHA256 (`CREEM_WEBHOOK_SECRET`), rejects invalid signatures with HTTP `401`, and enforces SQLite WAL idempotency on `event_id`.

---

## 5. Causal Bazaar Local Hand CLI

```bash
python3 run_hand.py --self-test
python3 run_hand.py --operation search_endpoints --query diff
python3 run_hand.py --operation generate_install_config --runtime uvx
python3 run_hand.py --operation publish_readiness
python3 run_hand.py --operation estimate_topup --engine scicom --tier pro
```

Support: `support@fastmesh.dev`
