Status
App contract for fungi.computer: typed backend methods, host capabilities and the App frontend connection
Stability
Section titled “Stability”Agar declares source version 0.5.0. Until 1.0, a minor release can change the public API, so pin the version you test against.
Package qualification does not publish a release. Check the npm registry before choosing a released version.
Limits and errors
Section titled “Limits and errors”A plain top-level page has no host to connect to; connectApp needs a
host-mounted iframe. Capability operations fail with typed AppError codes when
the host denies, revokes or lacks the capability. Method schemas validate input
and output on every call; a handler cannot return data its output schema
rejects.
Contribute and license
Section titled “Contribute and license”Run pnpm --filter @fungi.computer/agar test for the SDK suites and
pnpm --filter @fungi.computer/agar build to compile the package. The package
uses the MIT license in LICENSE.
Shared Gill declarations, row codecs and clients live in
@fungi.computer/gills. Define an App’s compact views with defineAppGill from
@fungi.computer/agar/gills next to its defineAppMethod exports, then pass
them as gills to defineAppBackend. buildAppDeclaration generates their
Release metadata; do not repeat it in package.json.
Each Gill names a declared read method and a page limit from 1 to 200. Its
input mapping receives {params, after, limit} and must forward that limit to
the source method. Source methods must accept the limit and return one page with
their own valid continuation. The rows projection receives the method’s parsed
JSON output and a second { params } argument containing the placement values,
so navigation can retain the repository or other selected App context even when
the source output does not repeat it. It must not filter away source rows:
shorten text while keeping each row’s identity and navigation parameters. The
helper bounds display text and the 240 KiB reply while preserving all rows and
the source’s next; it refuses a page whose navigation alone exceeds the
budget.
A Gill’s source runs through the method’s existing input/handler/output parsing
and trusted caller context. A write source or an undeclared method is refused.
Placement may declare up to four Computer/repository/branch parameters, and a
storage marker or binding change feed. Repository or branch parameters may name
options: "<own read method>". An options request calls that read method with
{limit, params, after?}; params contains the values chosen so far. Its
output is {options: [{value, label, detail?}], next?}, and it retains its own
capability requirements. Computer choices are host-owned; there is no picker
registry. backend.gill and the client return GillReply, a row/error response
or an options page. A row’s open.params is an intent within that App, with no
URL or recipient App ID.
Agent extension backends compose agentExtensionMethods from
@fungi.computer/shiitake/agar-extension with defineAppBackend. The extension
adapter belongs to Shiitake; Agar does not depend on the Agent runtime.