Skip to main content

Workspace Widget Overview

@interopio/workspace-widget is a TypeScript package that ships the self-contained HTML for the built-in Workspace Widget MCP App. @interopio/mcp-core consumes it as the resource for its getWorkspaceWidget system tool, but the widget HTML is published as its own package so it can be versioned and rebuilt independently of MCP Core.

Installation​

npm install @interopio/workspace-widget

Main API​

The package exposes a single function:

function getHTML(): Promise<string>;

getHTML() resolves to a complete, self-contained HTML5 document string — all JavaScript and CSS are inlined, so the result can be served, embedded, or handed to an MCP App resource without further bundling.

import { getHTML } from "@interopio/workspace-widget";

const html = await getHTML();
  • Examples for wiring the widget into an MCP Core server, directly or over HTTP
  • MCP Core: System Tools for the getWorkspaceWidget tool this resource powers
  • Workspace Widget for the full widget behavior: modes, interaction workflow, and custom notifications