Getting it into your agent
It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.
git clone --depth 1 https://github.com/sabbour/agentweavernpx agentmods add skills/sabbour/agentweaver/mcp-harnessWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/sabbour/agentweaver/mcp-harness)<a href="https://agentmods.dev/skills/sabbour/agentweaver/mcp-harness"><img src="https://agentmods.dev/badge/skills/sabbour/agentweaver/mcp-harness.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00000 | $0.02265 |
| Opus 5 | $0.00000 | $0.01132 |
| Sonnet 5 | $0.00000 | $0.00453 |
| Haiku 4.5 | $0.00000 | $0.00227 |
Grade A, and why
mcp-harness scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 182 lines — stays where its author put it; the contents beside it link to each section on GitHub.
MCP harness CLI contract
Use this harness to validate Agentweaver's MCP protocol surface, capture the
complete tools/call request/response evidence, and emit a normalized
agentweaver.persona-judge-verdict/v1 JSON verdict. It is for MCP end-to-end
validation, MCP tool-contract regression checks, and investigation of an
MCP-reported issue; use the API or UI harness for those surfaces.
Run all commands below from the repository root. The harness requires Node 18 or newer. Install its dependencies and run its unit tests before changing it:
npm --prefix scripts/mcp-harness install
npm --prefix scripts/mcp-harness test
There are two entry points, for two different jobs:
run-persona.mjs— full dynamic persona scenario validation (no fixed script; a dispatched sub-agent drives the live tool menu). Use this to validate how the MCP surface behaves for a real persona.smoke/mcp-cli-smoke.mjs— a fast, fixed deterministic connectivity + capability tripwire. Use this for a quick "is the server reachable and does it still satisfy the capability contract" check.
Both transports work the same for either entry point:
- stdio (
--target stdio) spawns a local subprocess via--server-command/--server-args. There is no network target validation —stdiois only a transport selector, never a URL. - http (
--target <url>) requires a real base URL that must include the exact/mcppathname (e.g.https://<host>/mcp; the bare origin and/mcp/are not the endpoint). Any HTTPS host is accepted; HTTP is loopback-only. URL credentials/fragments and TLS bypasses are rejected. http transport also requires OAuth: transientAGENTWEAVER_TOKENmust be an Agentweaver broker token for the exact/mcpresource withmcp:invoke, obtained through the app's OAuth flow. Raw Entra and GitHub tokens are rejected. Stdio transport still usesAGENTWEAVER_TOKENfor downstream API calls.
Driving a persona scenario (the only way — dynamic, no fixed scripts)
What ships with it
33 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- agent-driver/AGENT.md 9.8 KB
- agent-driver/tools.mjs 1.2 KB runs code
- convert-cli-native.mjs 3.1 KB runs code
- dispatch/.gitignore 14 B
- findings/.gitignore 14 B
- lib/approval-safety.mjs 901 B runs code
- lib/capabilities-contract.mjs 3.4 KB runs code
- lib/mcp-p0.mjs 633 B runs code
- lib/reporter.mjs 377 B runs code
- lib/smoke-confirm-gate.mjs 1.2 KB runs code
- lib/transcript.mjs 1.9 KB runs code
- mcp-client/client.mjs 3.0 KB runs code
- mcp-client/prompt-safety.mjs 1.9 KB runs code
- mcp-client/transport-http.mjs 750 B runs code
- mcp-client/transport-stdio.mjs 638 B runs code
- package-lock.json 40 KB
- package.json 454 B
- README.md 4.3 KB
- required-capabilities.json 2.0 KB
- run-persona.mjs 24 KB runs code
- smoke/mcp-cli-smoke.mjs 12 KB runs code
- test/approval-safety.test.mjs 911 B runs code
- test/capabilities-contract.test.mjs 1.5 KB runs code
- test/client-ownership.test.mjs 2.1 KB runs code
- test/injection-resistance.test.mjs 2.1 KB runs code
- test/mcp-cli-smoke.test.mjs 11 KB runs code
- test/run-persona.test.mjs 18 KB runs code
- test/smoke-confirm-gate.test.mjs 5.3 KB runs code
- test/target-guard.test.mjs 692 B runs code
- test/transport-http.test.mjs 2.0 KB runs code
- test/transport-stdio.test.mjs 849 B runs code
- transcripts/.gitignore 14 B
- verdicts/.gitignore 14 B
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 2d ago Changed · +8 lines 4eba3cd0b132
- 4d ago First seen · 174 lines · 0 tokens per session scan A 896acf3ecc86
mcp-harness is a skill published in the GitHub repository sabbour/agentweaver (5 stars, last pushed 2d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 2,265 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.
Other skills, from other repositories
routing-calibration-loop
Calibrates routing changes against a live router endpoint with executable probes, local DSL validation, versioned deploys, and structured failure review. Use when tuning signals, projections, decisions, or maintained route examples against a real apiserver.
behavior-contract
Bug condition/postcondition formalization as testable Behavior Contracts. Defines invariants that must be preserved across fixes.
quality-hooks
Language-specific auto-lint/format/typecheck pipeline. Supports Python (ruff+pyright), TypeScript (prettier+eslint+tsc), Go (gofmt+golangci-lint). Auto-fix and convergence loops.
ward
Ward the codebase — an ad-hoc test-gap audit that reveals unguarded code (untested functions, uncovered edge cases, missing error-handling and integration tests) and conjures ready-to-paste test skeletons as protective wards against regression, surfaced inline in the session. Scoped to your current diff by default, or…
dos-self-improve
Run the DOS self-improvement loop: propose a candidate, verify it in an isolated worktree, measure suite/truth/metric gates, and keep only confirmed gains. Use for recursive improvement; use dos-enforce-tune for policy knobs.
test-runner
Use this skill when orchestrating agentic end-to-end tests. Resolves target + profile, dispatches the right driver(s) (playwright for web today, peekaboo for macOS (issue #381)), invokes the ux-evaluator agent (opus, read-only) against driver artifacts, reconciles findings with the open issue tracker via…