api-mcp
v0.1.11MCP server that runs the Yichus API engine (Yichus/Mcp Bosatsu config) over stdio
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
api_tools
List the specialist tool families this server offers beyond the core tools, or open one. With no arguments it returns the core tool names and each family's name, one-line summary and tool names. With family it returns that family's tools with their descriptions and input schemas, and an MCP server that lists only the core tools adds them to its tool list. Any catalog tool can be called by name whether or not it is listed.
| Parameter | Type | Description |
|---|---|---|
family | string | Optional family name from the no-argument answer, such as access or proofs. Omit to list the families. |
api_guide
Return the pre-written agent guide for building a Bosatsu API with checked access rules. Call this first. Deterministic documentation; no model-generated advice. With no arguments it returns the table of contents, each section's title with one line on what it covers; with section it returns the full text of the sections whose title contains that text (case-insensitive) and, on no match, the list of titles; with full true it returns every section (full is ignored when section is given).
| Parameter | Type | Description |
|---|---|---|
full | boolean | Optional; true returns the full text of every section (about 100k characters). |
section | string | Optional title, or part of one: the full text of the matching sections is returned. Omit for the table of contents. |
api_scaffold
Generate a Yichus-first Bosatsu API module: structs, Yichus/Access rules, owner-scoped or public handlers, and a Yichus/Service routing table, plus a matching Yichus/Frontend::FrontendSpec (frontendSource) for api_frontend. The result compiles and verifies; edit it, then api_verify.
| Parameter | Type | Description |
|---|---|---|
package_name * | string | Bosatsu package, PascalCase segments separated by slashes, e.g. My/Notes/Api |
resources * | array | JSON array of {name, fields:[{name,type}], policy}. type is String, Int, or Bool. policy is owner or public. |
service_name * | string | snake_case service name, e.g. notes |
api_verify
Rerun the available safety checks from the typed IR of the given Bosatsu sources. Reports which properties still hold after edits. Topology is an input: undeclared defaults to multi-instance, where RMW and interleaving findings are violations. When the sources declare a Yichus/Organize AbstractionSpec or GroupSpec, the declared-structure property checks every declared claim the way api_organize's abstractions and layers lenses do: proven when all converge, violated when any declared claim diverges (a generator that does not hold its declared guard responsibility, a member that does not use its…
| Parameter | Type | Description |
|---|---|---|
sources * | array | JSON array of {fileName, source} Bosatsu files for the API module. |
block_on_warnings | array | Optional JSON array of property ids (for example ["rmw-transactions", "integrity"]) or ["all"]. An id must name a property this verdict has; declared-structure exists only when the sources declare a s… |
instances | string | Deployment topology: 1 for a single engine instance, many (default) for multiple instances sharing one DB. It changes the read-modify-write and interleaving findings, never lost-edits. |
api_compile
Parse and type-check Bosatsu API sources in memory (CompileKernel). No filesystem.
| Parameter | Type | Description |
|---|---|---|
sources * | array | JSON array of {fileName, source} Bosatsu files. |
api_report
Build the program-report-2.0 map from the typed IR for whatever style of program the sources are (CRUD, flow, dist, escrow, unrouted IO). overview.surfaces names the present IR surfaces; needed names missing declarations with snippets. Pass format html for a self-contained HTML document.
| Parameter | Type | Description |
|---|---|---|
sources * | array | JSON array of {fileName, source} Bosatsu files for the module. |
detail | string | summary (default) keeps shape to per-package counts plus the IO/notable bindings; full enumerates every binding. |
format | string | json (default) for the raw report, html for a self-contained HTML document. |
instances | string | Deployment topology: 1 for a single engine instance, many (default) for multiple instances sharing one DB. |
protocol_case | object | Optional protocol-case-1.0 JSON; attaches a separate bounded protocol verdict without changing universal proof claims. |
title | string | Optional title for the HTML document. |
api_add_artifact
Return a paste-ready Bosatsu snippet for a report artifact (AccessSpec, ServiceDef, DistSpec, EscrowSpec, FlowSpec, Spec, FrontendSpec). Pass kind. Pass the same sources as api_report to fill names from the IR, or omit sources for a generic template. If the kind does not apply to those sources, the tool says so instead of emitting a misleading snippet.
| Parameter | Type | Description |
|---|---|---|
kind * | string | access, service, dist, escrow, flow, spec, or frontend |
name | string | Optional binding/service name for generic templates. |
policy | string | owner or public. Used for generic access templates. |
resource | string | Optional table or cell name for generic access/escrow/spec templates. |
sources | array | Optional JSON array of {fileName, source}. When present, the snippet is filled from the typed IR. |
api_law_check
Check declared Yichus/Law obligations. Mode sampled (default) uses seeded generation: holds is bounded observation, never proof. Mode exhaustive checks every value of an accepted finite type or every distinct value of a Bosatsu FiniteObligation list; holds-exhaustive says every value of the type held, and holds-on-listed says only the listed values were checked. Unsupported domains, exceeded limits, unfinished witnesses, and worker failures never become a pass. Violated and inconclusive both mean not done. When the program declares routes, reach lists, for each law whose check it could read, t…
| Parameter | Type | Description |
|---|---|---|
sources * | array | JSON array of {fileName, source} Bosatsu files including the Obligation bindings. |
maximum | integer | Maximum finite inputs per obligation in exhaustive mode (default 256, hard cap 4096). |
mode | string | sampled (default) or exhaustive; exhaustive never falls back to a seeded pass. |
module_name | string | Optional module name for the verdict artifact (default Laws). |
runs | integer | Optional generated inputs per obligation (default 200). |
seed | integer | Optional run seed; the whole run replays from this one number (default 41). |
shrink | integer | Optional shrink budget per counterexample (default 200). |
api_why
Evaluate ONE binding on concrete typed inputs and report why the output is what it is. Pick the binding from a diagram or report by its Pkg/Name::binding id. Provide inputs as JSON (missing ones are seeded deterministically); the tool returns the typed inputs and output with named rendering, soundFacts (static dataflow: per-parameter influence that holds for EVERY input), and observed (bounded seeded runs: touched bindings, per-parameter and per-field vary-one-fix-rest differentials). soundFacts and observed are disjoint on purpose: an observed-constant result is NOT independence, and every ob…
| Parameter | Type | Description |
|---|---|---|
binding * | string | The binding to evaluate, as Pkg/Name::binding (the id shown on diagrams and reports). |
sources * | array | JSON array of {fileName, source} Bosatsu files for the module. |
inputs | object | Optional JSON object {param: value} of provided inputs. Values use the same JSON encoding api types use; a nullary enum constructor is written {"Ctor": {}} (the form the tool prints), and the bare obj… |
observe | boolean | Optional; false skips the differential runs and returns only the evaluation plus soundFacts (default true). |
rows | object | Optional JSON object {table: [row, ...]} seeding the in-memory world for an IO handler run. |
seed | integer | Optional run seed; the whole run replays byte-identically from this one number (default 41). |
variations | integer | Optional variations per differential axis (default 5). |