@pouchy_ai/companion-sdk - v0.1.0
    Preparing search index...

    Interface RenderInterfacePayload

    Payload of a companion.ui_action event — an Instant UI surface for the host to render. interface is the platform-neutral genui schema: a tree of UI nodes (Text/Slider/Button/Chart/…), an optional state bag input atoms read+write, and optional computed derived values. The SAME shape is drawn by a web embed, a native iOS/Android renderer, or a CLI/TUI — only the renderer differs per platform, never the contract. Kept structurally loose here (the SDK package carries no $lib import); the authoritative schema lives in src/lib/genui/schema.ts and the renderer-contract doc. When the panel sets reportChanges, the user's edits stream back as a normal text turn.

    interface RenderInterfacePayload {
        interface: {
            computed?: Record<string, unknown>;
            nodes: { type: string; [k: string]: unknown }[];
            reportChanges?: boolean;
            state?: Record<string, string | number | boolean>;
            title?: string;
        };
    }
    Index
    interface: {
        computed?: Record<string, unknown>;
        nodes: { type: string; [k: string]: unknown }[];
        reportChanges?: boolean;
        state?: Record<string, string | number | boolean>;
        title?: string;
    }