Reference

Manifest & result types

The widget manifest, icon, and MCP tool result shapes.

Formal shapes for the manifest and the values MCP tools return. See Manifest & icons for narrative.

WidgetManifest

interface WidgetManifest {
  id: string;
  name: string;
  refreshMs: number;
  htmlHash: string;        // SHA-256 (hex) of the HTML
  version: number;
  publishedAt?: number;    // Unix seconds
  icon?: WidgetIcon;
  builtInSlug?: string;    // set if installed from a shipped template
  builtInVersion?: number;
}

WidgetIcon

interface WidgetIcon {
  kind: "sfSymbol" | "emoji" | "png";
  // sfSymbol: symbol name · emoji: the character ·
  // png: base64 PNG on input, rewritten to the bytes' SHA-256 once stored
  value: string;
}

MCP tool results

// pair_status
interface PairStatus { paired: boolean; connected: boolean; deviceName?: string; }

// publish_widget
interface PublishWidgetResult { id: string; }

// list_widgets
interface ListWidgetsResult { widgets: WidgetManifest[]; activeWidgetId?: string; }

// list_versions
interface WidgetVersion { version: number; htmlHash: string; updatedAt: number; note?: string; }
interface ListVersionsResult { versions: WidgetVersion[]; }

// get_data_endpoint
interface DataEndpoint { url: string; token: string; }

Tool arguments at a glance

ToolRequiredOptional
publish_widgetname, htmlrefreshMs, icon
update_widgetid, htmlicon
set_widget_iconid, icon
set_active_widgetid
delete_widgetid
list_versionsid
revert_widgetid, version
push_dataid, data
get_data_endpointid
register_action (debug)widgetId, actionId, commanddescription, argKeys