API reference
agar-extension
Import
Section titled “Import”import * as api from "@fungi.computer/shiitake/agar-extension";Exports
Section titled “Exports”| Kind | Export | Description |
|---|---|---|
| function | agentExtensionMethods() | Serve one Shiitake extension from this App backend. Spread the result into
defineAppBackend({ methods }); the build writes the three methods into the
Release’s API, which is how a Release declares itself an Agent extension. An
extension requesting a capability hosting lacks fails here, at build. |
agentExtensionMethods()function
Section titled “agentExtensionMethods()”function agentExtensionMethods<Context>( extension,): Readonly<Record<string, AppBackendMethod<Context>>>;Serve one Shiitake extension from this App backend. Spread the result into
defineAppBackend({ methods }); the build writes the three methods into the
Release’s API, which is how a Release declares itself an Agent extension. An
extension requesting a capability hosting lacks fails here, at build.
Type Parameters
Section titled “Type Parameters”| Type Parameter | Default type |
|---|---|
Context |
void |
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
extension |
RosteredExtensionV0 |
Returns
Section titled “Returns”Readonly<Record<string, AppBackendMethod<Context>>>