Skip to content

docs: sync public pages, API/MCP docs, and guides to actual functionality#230

Merged
mkreyman merged 3 commits into
masterfrom
docs/verify-against-functionality
Jul 1, 2026
Merged

docs: sync public pages, API/MCP docs, and guides to actual functionality#230
mkreyman merged 3 commits into
masterfrom
docs/verify-against-functionality

Conversation

@mkreyman

@mkreyman mkreyman commented Jul 1, 2026

Copy link
Copy Markdown
Owner

Why

Audited every public surface an AI agent (or human) reads to understand loopctl — the loopctl.com landing/docs pages, the API discovery endpoints, the README, the MCP server README, the orchestration guide, and the CHANGELOG — against ground truth (router.ex and mcp-server/index.js's TOOLS array). Goal: docs match reality so agents can accurately educate their users about what loopctl does and how to use it.

Four parallel read-only audits produced the findings; each was independently re-verified against source before applying (that caught a wrong count — see below).

What changed

Tool count → 69 (verified against the TOOLS array; the 70th name: is the new Server() registration, not a tool)

  • Was 57 on the landing/docs pages, 65 in README / mcp-server README / CLAUDE.md.
  • Documented the 4 previously-undocumented tools: knowledge_conflicts, knowledge_resolve_conflict, knowledge_curation_log, knowledge_retrieval_metrics.

README

  • UI-test endpoints corrected to /projects/:project_id/ui-tests (the documented /ui_test_runs paths were unreachable — 404).
  • GET / serves the HTML landing page (it does not redirect).
  • Added a Chain-of-Custody v2 dispatch-pattern note to the auth flow (env-var keys are the deprecated path).

Orchestration guide

  • verified_status values are unverified/verified/rejected (doc said pass/fail, which aren't in the enum).
  • Agents report reported_done (doc said completed).
  • initial_verified_status on import is honored only for a superadmin caller and its only value is verified — documented the anti-RBAC-bypass guard (the old example used a user key + "pass", which silently produced non-verified stories).
  • Clarified reject semantics (auto_reset_on_rejection).

mcp-server README

  • knowledge_export has no obsidian format, and its download needs LOOPCTL_USER_KEY.

MCP server version

  • The handshake advertised version: "1.2.0" while the npm package is 2.30.0 — an unintentional divergence. Now derived from package.json at startup so it tracks the package version and can't drift again.

Public pages / discovery (code)

  • GET /api/v1/ now returns discovery, routes, wiki, and mcp_server pointers so agents hitting the API root have a path forward instead of dead-ending (+ OpenAPI schema + test).
  • GET /api/v1/routes is now described as a curated index (not the exhaustive surface), points to the OpenAPI spec, and lists the CoC v2 dispatch routes, recover-cap, acceptance_criteria, and the new knowledge endpoints.
  • Wiki index category order is derived from the categories actually present (drops retired :convention, includes all active categories) so no article is ever silently hidden.
  • Landing page: "three agent-facing roles" (the hierarchy has four incl. superadmin).

CHANGELOG

  • Backfilled the shipped agents'-KB endpoints (conflict resolution/merge, retrieval metrics, curation log, creativity primitives) that had no CHANGELOG entry.

Verification

  • mix precommit green: 3091 tests, 0 failures; compile (warnings-as-errors), mix format, credo --strict, and dialyzer all clean.
  • Every claim edited was checked against source (router.ex, story.ex enum, import_export.ex superadmin gate, index.js tool defs/handlers, export format enum).

Notes

  • The mcp-server README's 1.2.0 deprecation notes are unchanged and still accurate — they describe when the knowledge_agent_usage parameter behavior changed, not the current server version.

mkreyman added 3 commits June 30, 2026 22:28
…lity

Audited every public surface (loopctl.com landing/docs pages, API discovery
endpoints, README, mcp-server README, orchestration guide, CHANGELOG) against
ground truth (router.ex, mcp-server/index.js TOOLS) and fixed all drift so
agents can accurately educate users about loopctl.

Tool count
- Corrected the MCP tool count to 69 (was 57 on the landing/docs pages, 65 in
  README/mcp-server README/CLAUDE.md). Verified against the TOOLS array.
- Documented the 4 previously-undocumented tools: knowledge_conflicts,
  knowledge_resolve_conflict, knowledge_curation_log, knowledge_retrieval_metrics.

README
- UI-test endpoints are nested under /projects/:project_id/ui-tests (were
  unreachable /ui_test_runs paths).
- GET / serves the HTML landing page (does not redirect).
- Added a Chain of Custody v2 dispatch-pattern note to the auth flow.

Orchestration guide
- verified_status values are unverified/verified/rejected (not pass/fail).
- Agents report reported_done (not 'completed').
- initial_verified_status on import is honored only for a superadmin caller and
  its only value is 'verified'; documented the anti-RBAC-bypass guard.
- Clarified reject semantics (auto_reset_on_rejection).

mcp-server README
- knowledge_export has no 'obsidian' format and its download needs LOOPCTL_USER_KEY.

Public pages / discovery (code)
- GET /api/v1/ now returns discovery/routes/wiki/mcp_server pointers so agents
  don't dead-end at the API root (+ OpenAPI schema + test).
- GET /api/v1/routes described as a curated index (not exhaustive), points to the
  OpenAPI spec, and now lists the CoC v2 dispatch routes, recover-cap,
  acceptance_criteria, and the new knowledge endpoints.
- Wiki index category order derived from present categories (drops retired
  :convention, includes all active categories) so no article is silently hidden.
- Landing page: 'three agent-facing roles' wording.

CHANGELOG
- Backfilled the shipped agents'-KB endpoints (conflict resolution/merge,
  retrieval metrics, curation log, creativity primitives).

mix precommit green (3091 tests, 0 failures; format, credo --strict, dialyzer).
…ed 1.2.0)

The MCP server advertised version "1.2.0" in the handshake while the published
npm package is 2.30.0 — an unintentional divergence. Derive the version from
package.json at startup (npm always ships package.json in the tarball) so the
handshake version tracks the package version and can't drift again.

The mcp-server README's 1.2.0 deprecation notes stay accurate — they describe
when the knowledge_agent_usage parameter behavior changed, not the current
server version.
Sonnet 5 (API id 'claude-sonnet-5', released 2026-06-30) is the current
Sonnet-tier model. Updated the illustrative model_name example strings in the
OpenAPI schema, the MCP report_token_usage/report_story tool descriptions, and
the PRD token-usage example from the prior claude-sonnet-4-5.

Cosmetic only: model_name is a free-form string and cost_millicents is
caller-reported, so recording a new model needs no code change. Test fixtures
and historical user-story specs are intentionally left as-is.
@mkreyman mkreyman merged commit 7f3c9c9 into master Jul 1, 2026
9 checks passed
@mkreyman mkreyman deleted the docs/verify-against-functionality branch July 1, 2026 16:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant