Document recommended extension tools and install-time credentials

This commit is contained in:
Sander Grootendorst
2026-11-26 22:42:47 +01:00
parent 34fec292ba
commit 747f2b48bf
14 changed files with 122 additions and 8 deletions
+2
View File
@@ -6,4 +6,6 @@ Run `isa-ext update-skill` in an extension root to install or refresh `skills/*`
The development skill covers extension contracts and packaging. The UI-control skill locates an optional native host checkout and delegates to its current automation workflow. Neither skill requires host source changes for ordinary extension work.
To offer library tools or your own MCP server, follow the manifest example and installation walkthrough. It covers credential entry, selecting actions and group access. [Recommend tools during installation](skills/isa-extension-development/references/24-tool-recommendations.md)
Canonical specification: the ISA Warden monorepo's `chat-ui-3/docs/extensions/`. Maintainers should refresh the reference snapshot when that contract changes and publish it here separately from host releases.
@@ -36,6 +36,8 @@ descriptors live inline in the source `extension.json`. Follow the complete
[model-recommendation author workflow](21-model-recommendations.md#212-author-workflow)
before publishing them.
Declare recommended services inline under `toolRecommendations`. Schema 1 supports MCP and API library entries. Schema 2 also supports an extension-supplied MCP endpoint. The packager validates and publishes the block in the package-root manifest. The installer obtains credentials from the administrator. [Tool recommendations](24-tool-recommendations.md)
### 3.3 Recommended source layout
For complex extensions, a source layout separate from packaged assets is recommended.
@@ -54,6 +54,8 @@ Example:
The optional `modelRecommendations` field is documented in
[section 4.7](#47-model-recommendations).
Use `toolRecommendations` to suggest library connections or your own MCP server during dashboard installation. [Tool recommendations](#49-tool-recommendations)
The optional `modEntry` field is valid only with the `mod` permission and is documented in [section 4.8](#48-privileged-host-modules).
The optional `minimumIsaWardenVersion` field is the install-time compatibility gate and declares the oldest compatible ISA Warden host as an exact semantic version, for example `"0.7.39"`. Discovery, validation, preview, install, and update reject a malformed value or a manifest whose minimum is newer than the running host. Dashboard packages copy this field into their distribution manifest, and the public and payload values must match exactly. This gate does not version runtime command APIs; extensions must continue detecting runtime capabilities by checking the host-advertised command arrays. Omit the field when the extension has no explicit minimum beyond the host's existing manifest contract.
@@ -330,3 +332,17 @@ The registration `extensionId` must exactly match the installed manifest. The ho
The activation context contains `extensionId`, `document`, `mountPoints`, `minimizeExtensionView()`, `onDispose(callback)`, `appendStyle(cssText)`, `appendRoot(mountPointName = 'appShell')`, and `addEventListener(target, type, listener, options)`. The named `appShell` and `extensionToolbar` mount points are backed by host elements marked `data-isa-extension-mod-mount="appShell"` and `data-isa-extension-mod-mount="extensionToolbar"`. A mod whose primary result is a host theme may call `minimizeExtensionView()` after activation so the themed host becomes visible while the extension and its tracked contributions remain active. `appendStyle`, `appendRoot`, and `addEventListener` create tracked contributions owned by the extension; `activate` may additionally return one cleanup function. The host runs registered and returned cleanup and removes all tracked contributions when the view reloads, closes, is uninstalled, fails activation, or is replaced.
These lifecycle helpers reduce accidental leaks; they are not a security sandbox. Once accepted, a mod runs in the host realm and can directly access the document. Request `mod` only when iframe theme tokens and bridge APIs cannot implement the feature.
### 4.9 Tool recommendations
The optional `toolRecommendations` block lists connections that the administrator can set up while adding, replacing or editing an extension. Each item contains a `kind` and may include a user-facing `reason`.
| `kind` | Required fields | Supported schema versions |
| --- | --- | --- |
| `mcp` | `catalogId` for an ISA MCP library service, for example `pdok` | 1 and 2 |
| `api` | `catalogId` for a published API definition, for example `wefact` | 1 and 2 |
| `customMcp` | `name`, fixed HTTPS `url` and `auth` (`none` or `bearer`) for a server implementing MCP over Streamable HTTP | 2 |
Use `schemaVersion` as a JSON integer and `items` as an array of 1–32 distinct recommendations. Catalog IDs are case-sensitive and contain 1–64 ASCII letters, digits, underscores or hyphens. A custom server name contains 1–128 UTF-8 bytes of readable text. The URL accepts up to 4,096 UTF-8 bytes and excludes credentials, query strings and fragments. An optional reason must contain non-whitespace text within 1,024 UTF-8 bytes. The packager validates these fields and includes the block in the public distribution manifest.
For a custom MCP server the installer displays the destination and handles credential entry, action selection and optional group linking. Bridge permissions govern runtime access. See the authoring examples, administrator walkthrough and compatibility notes. [Tool recommendations](24-tool-recommendations.md) · [Example extension.json](examples/tool-recommendations-v2.json)
@@ -28,6 +28,8 @@ additional administrator review:
The complete publisher and administrator procedure is in
[Model recommendations](21-model-recommendations.md).
The dashboard shows tool recommendations when adding an extension, replacing a package or editing an installed extension. The administrator can set up a missing library service, or enter any required bearer token and select actions for a custom MCP endpoint directly in the installer. Existing connections can be reused and linked to an authorized group. Setup is optional. [Tool recommendations](24-tool-recommendations.md)
An existing `normalHttp` model matches only when its normalized URL and output
filename match and the workspace model contains every declared model type. An
existing `openAICompatibleAPI` model matches only when its normalized base URL
@@ -99,6 +99,10 @@ Common non-filesystem commands include:
- `search_documents`
- `read_document`
## External MCP tools
Declare `mcp_list_resources` to discover the connections and actions authorized for the launch group. Declare `mcp_invoke_tool` to invoke a discovered action. Use the returned `serverId`, tool `id` and `inputSchema` to build the request. Check the returned MCP `isError` flag. The dashboard owns the connection credentials and executes the call under the active user, workspace and group. [Recommend tools during installation](24-tool-recommendations.md)
## Atomic JSON workspace files
Atomic JSON commands provide operation-based updates to any valid JSON workspace file covered by the extension's ordinary exact-file or folder grant. The extension must declare `atomic_json_read` or `atomic_json_write`; the host supplies and enforces the immutable workspace, group, and extension scope. The target is an absolute canonical `path`, and traversal or access outside the granted scope is rejected.
@@ -53,13 +53,13 @@ allowed = user_has_rights
AND host_policy_allows_extension_use
```
### 12.3 Tools, servers, and future MCP
### 12.3 Tools and external MCP servers
The dashboard model already includes tools and servers in workspace resources.
Extensions should only be allowed to use resources that are visible and allowed for the current user and workspace context.
If future extension-facing MCP/server invocation APIs are introduced, they must follow the same delegated-user authority model.
External MCP connections belong to the workspace. Use explicit group links and the applicable bridge permissions for a launch group. The administrator enters any required token during setup and chooses the allowed actions. Credentials stay on the dashboard. [Tool recommendations](24-tool-recommendations.md) · [External MCP tools](07-host-command-api-reference.md#external-mcp-tools)
### 12.4 Model recommendation authority
@@ -26,6 +26,8 @@ remote-provider data handling and costs, and that uninstalling the extension
does not remove provisioned models. Follow
[Model recommendations](21-model-recommendations.md).
For a recommended tool, document which feature uses it and how the feature behaves if setup is skipped. For a custom MCP endpoint, identify who operates it, what data the service receives and which credential the administrator should enter during installation. The package contains only public setup metadata. [Tool recommendations](24-tool-recommendations.md)
### 13.2 Lifecycle topics that must be documented
- publication
@@ -8,6 +8,7 @@ Packaging:
- Run the extension root `npm run build`.
- Confirm `dist/<id>.isax/extension.json` exists.
- For tool recommendations, check the public fields in the generated manifest. Test entering any required bearer token in the installer, selecting actions, reusing an existing connection, skipping setup and discovering the tool in the intended group. [Tool recommendations](24-tool-recommendations.md)
- Confirm `dist/<id>.isax/payload.tar.xz` exists.
- Confirm the distribution `payloadSha256` matches the packaged payload.
- If the source requests `mod`, confirm the package-root manifest contains the normalized `permissions` and exact `modEntry`, and confirm the payload contains that module.
@@ -45,6 +45,7 @@ Implemented runtime behavior documented here:
- Version 1 model recommendations in dashboard extension manifests, including
add-flow validation, exact workspace matching, administrator review, and
workspace-only creation through the existing model API.
- Optional recommendations for MCP library services, published API definitions and publisher-supplied Streamable HTTP MCP endpoints. Administrators can enter credentials and choose actions during installation. [Tool recommendations](24-tool-recommendations.md)
- Optional speaker-aware segments from configured diarization-capable remote
providers. Support is advertised per transcription model; speaker identities
remain opaque until an extension or user maps them explicitly.
@@ -61,7 +62,7 @@ Planned or intentionally absent behavior:
- Automatic extension workspace folders at launch.
- Runtime access to arbitrary group-visible files without a local user grant.
- Marketplace policy automation beyond the currently implemented host checks.
- Recommendation bundles for tools, agents, servers, groups, or files.
- Recommendation bundles for agents, model servers, groups, or files.
- Runtime lookup by recommendation key, automatic group linking, automatic
recommendation processing on extension update, and model cleanup on
extension uninstall.
@@ -77,5 +78,4 @@ When extending this specification:
- Label implemented runtime APIs as implemented.
- Label broader ecosystem ideas as planned or policy guidance.
- Do not present future MCP/server invocation behavior as available unless it is
backed by implemented source.
- At runtime the dashboard invokes authorized group connections using the server and tool IDs returned by discovery. [External MCP tools](07-host-command-api-reference.md#external-mcp-tools)
@@ -5,9 +5,7 @@ that make the extension useful. During the dashboard **Add Extension** flow,
the host reviews those declarations with the administrator and can add selected
missing model records to the workspace before adding the extension.
This is an implemented, model-only provisioning aid. It is not a general
resource bundle and does not currently provision tools, agents, servers,
groups, files, or model-to-group links.
Extensions can also recommend library connections and their own MCP endpoints during installation. [Tool recommendations](24-tool-recommendations.md)
## 21.1 What a recommendation does
@@ -32,6 +32,8 @@ The command fetches `https://git.isawarden.com/ISAWarden/extension-skills`, read
The `isa-extension-development` skill includes a versioned specification snapshot for bridge contracts, styling, persistence, workers, and packaging. The `isa-extension-ui-control` skill covers native app interaction through the host's current selector automation workflow. Keep project-specific RSX behavior and validation instructions in that project's `AGENTS.md`; shared skills remain generic.
When adopting custom MCP recommendations, update the pinned packager and manifest crate from a template that supports `toolRecommendations.schemaVersion` 2. After building, inspect the package-root manifest. The installed guide includes a complete sample with bearer authentication and a catalog service. [Recommend tools during installation](24-tool-recommendations.md)
## Locate the optional native host
```bash
@@ -0,0 +1,60 @@
# Recommend tools during extension installation
An extension can offer a connection to its own MCP server when an administrator installs it. The author supplies the server name, address and authentication method in `extension.json`. During installation the administrator can enter a token, select the allowed actions and link the connection to a group. The MCP service must already be running and reachable from the ISA dashboard server.
## Choose how to declare the service
| Service used by the extension | Manifest item | Who supplies its settings |
| --- | --- | --- |
| Your own server implementing MCP over Streamable HTTP | `kind: "customMcp"`, with `name`, `url` and `auth` | The extension supplies the HTTPS endpoint and authentication method. The administrator supplies credentials during setup. |
| A service in the ISA MCP library, such as PDOK | `kind: "mcp"`, with `catalogId: "pdok"` | ISA supplies the adapter and its setup form. Use this entry for PDOK postcode or address lookups. |
| An HTTP API published in the operator's API library, such as WeFact | `kind: "api"`, with the published `catalogId` | The dashboard operator supplies the API definition and actions. The administrator selects actions and supplies any API key. |
## Add your own server
Put the following block in the source `extension.json`. Replace the example address with the exact Streamable HTTP endpoint of your service. The downloadable example is a complete manifest that also offers the PDOK library connection. [Example extension.json](examples/tool-recommendations-v2.json)
```json
{
"toolRecommendations": {
"schemaVersion": 2,
"items": [
{
"kind": "customMcp",
"name": "Materials catalogue",
"url": "https://mcp.example.org/materials",
"auth": "bearer",
"reason": "Looks up product specifications for a selected material."
}
]
}
}
```
- Use `"auth": "none"` for a service that accepts anonymous requests. With `"auth": "bearer"` the administrator enters a token in ISA Warden, which the dashboard sends to that endpoint as an HTTP bearer credential. Provider-specific OAuth sign-in is available through the corresponding supported library entries.
- Supply an absolute HTTPS URL, including the MCP path and any required port. The URL may contain up to 4,096 UTF-8 bytes. Keep credentials, query strings, fragments, whitespace and backslashes out of it. Use a `name` of 1–128 UTF-8 bytes and an optional plain-text `reason` of up to 1,024 UTF-8 bytes. Keep tokens, headers and commands out of the package.
- Schema version 2 accepts all three item kinds in one list of 1–32 recommendations. Version 1 remains valid for `mcp` and `api` catalog items. Each catalog item uses a unique pair of kind and case-sensitive catalog ID. Each custom endpoint can appear once. Hostname case and the default HTTPS port normalize to the same URL. Distinct paths, including a trailing slash after a path, can identify different endpoints.
## Package and verify
1. Use an `isa-ext` packager and ISA Warden host/dashboard that support the schema you declare. In standalone projects with a bundled packager, update both `tools/isa-ext` and `tools/isa-extension-manifest`, including their Cargo manifests and lockfiles. The `update-skill` command refreshes development instructions separately.
2. Run the extension's full build, normally `npm run build`. Open **`dist/<id>.isax/extension.json`** and check that `toolRecommendations`, the schema version and the endpoint survived packaging. An older packager can omit an unfamiliar field.
3. Preview the generated `.isax` directory or its package URL in **Add Extension**. Check the server name, destination, authentication and reason as an administrator would. Package preview reads metadata. The first request to the recommended server starts when the administrator chooses to fetch its tools.
## What the administrator does
1. In **Recommended tools**, choose **Set up** for the desired service, or continue with the extension and return later through **Edit Extension**. The form identifies a custom endpoint as supplied by the extension and shows the address that will receive the request.
2. Enter the token if required and choose **Connect and fetch tools**. The dashboard contacts the server using its normal MCP network policy. Select the advertised actions this workspace connection should expose.
3. Choose the intended group if appropriate and confirm adding the connection. Creating a connection requires workspace tool-management rights. Linking it to a group requires group-link rights. The extension install can also finish with the recommendation skipped.
4. If the workspace already has a compatible connection, use it. When multiple accounts exist, choose the specific connection for the group. ISA matches custom servers by their canonical endpoint and authentication method. If the dashboard cannot identify an older connection's authentication, review it in **Tools**. A different endpoint or authentication method requires its own review. Credentials stay with the workspace connection. Uninstalling the extension leaves the connection and its existing consumers in place.
## Use the connection from the extension
Declare `mcp_list_resources` for discovery and `mcp_invoke_tool` for calls in the extension's `permissions`. Discover the server and tool IDs in the active group and use the returned input schema. If several connections offer the same action, let the user select the appropriate account. Handle a missing group connection in the feature that uses it. [External MCP tools](07-host-command-api-reference.md#external-mcp-tools)
| Symptom | What to check |
| --- | --- |
| The recommendation is missing from the installer | Inspect the generated package-root manifest and the versions of the packager and host. |
| Fetching tools fails | Check the exact MCP path, dashboard reachability and any required token. The endpoint must speak MCP over Streamable HTTP. For a private deployment the dashboard operator's existing network policy must allow the destination. |
| The connection exists but the extension cannot find its tool | Verify the current group link, the enabled action names and the extension's bridge permissions. Check the agent link as well when using an agent. |
| A package update points at a new address | Review the new destination and supply its credentials during setup. Background updates do not register new connections. |
@@ -36,3 +36,4 @@ If a capability is not documented here, it must not be assumed to exist.
22. [Dashboard extension workers](extension-workers.md)
23. [Standalone repositories and agent skills](22-standalone-development.md)
24. [Recommend tools and custom MCP servers during installation](24-tool-recommendations.md)
@@ -0,0 +1,24 @@
{
"id": "materials-lookup",
"name": "Materials lookup",
"version": "1.0.0",
"entry": "index.html",
"permissions": ["mcp_list_resources", "mcp_invoke_tool"],
"toolRecommendations": {
"schemaVersion": 2,
"items": [
{
"kind": "customMcp",
"name": "Materials catalogue",
"url": "https://mcp.example.org/materials",
"auth": "bearer",
"reason": "Looks up product specifications for a selected material."
},
{
"kind": "mcp",
"catalogId": "pdok",
"reason": "Finds coordinates for project postcodes and supplier addresses."
}
]
}
}