MCP Server Framework - v1.0.0
    Preparing search index...

    Interface AppResourceDefinition

    Resource definition embedded within an AppDefinition.

    Declares the UI resource that backs the MCP App. The resource is registered automatically when defineApp() is called.

    interface AppResourceDefinition {
        description?: string;
        mimeType?: string;
        name?: string;
        read: () => | string
        | Uint8Array<ArrayBufferLike>
        | Promise<string | Uint8Array<ArrayBufferLike>>;
        uri: string;
    }
    Index

    Properties

    description?: string

    Optional resource description (defaults to app description)

    mimeType?: string

    MIME type of the resource content (default: 'text/html;profile=mcp-app')

    name?: string

    Optional resource name (defaults to app name)

    read: () => | string
    | Uint8Array<ArrayBufferLike>
    | Promise<string | Uint8Array<ArrayBufferLike>>

    Read the resource content.

    Type Declaration

      • (): | string
        | Uint8Array<ArrayBufferLike>
        | Promise<string | Uint8Array<ArrayBufferLike>>
      • Returns
            | string
            | Uint8Array<ArrayBufferLike>
            | Promise<string | Uint8Array<ArrayBufferLike>>

        Resource content as string (text) or Uint8Array (binary)

    uri: string

    Static resource URI — must use ui:// scheme (e.g., 'ui://calculator')