Skip to content

Commit 35f897b

Browse files
Convert UIResource documentation to TypeDoc comments
Replace inline comments with comprehensive TypeDoc comments that explain the purpose and usage of each property. Add examples and clarify constraints (MUST/SHOULD) for better developer understanding. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
1 parent 5e8946c commit 35f897b

File tree

1 file changed

+49
-5
lines changed

1 file changed

+49
-5
lines changed

specification/draft/apps.mdx

Lines changed: 49 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -53,11 +53,55 @@ UI resources are declared using the standard MCP resource pattern with specific
5353

5454
```typescript
5555
interface UIResource {
56-
uri: string; // MUST start with 'ui://'
57-
name: string; // Human-readable identifier
58-
description?: string; // Description of the UI resource
59-
mimeType: string; // SHOULD be 'text/vnd.mcp.ui+html' in MVP
60-
_meta?: UIResourceMeta // Resource Metadata
56+
/**
57+
* Unique identifier for the UI resource
58+
*
59+
* MUST use the `ui://` URI scheme to distinguish UI resources from other
60+
* MCP resource types.
61+
*
62+
* @example
63+
* "ui://weather-dashboard"
64+
*/
65+
uri: string;
66+
67+
/**
68+
* Human-readable display name for the UI resource
69+
*
70+
* Used for listing and identifying the resource in host interfaces.
71+
*
72+
* @example
73+
* "Weather Dashboard"
74+
*/
75+
name: string;
76+
77+
/**
78+
* Optional description of the UI resource's purpose and functionality
79+
*
80+
* Provides context about what the UI does and when to use it.
81+
*
82+
* @example
83+
* "Interactive weather visualization with real-time updates"
84+
*/
85+
description?: string;
86+
87+
/**
88+
* MIME type of the UI content
89+
*
90+
* SHOULD be `text/vnd.mcp.ui+html` for HTML-based UIs in the initial MVP.
91+
* Other content types are reserved for future extensions.
92+
*
93+
* @example
94+
* "text/vnd.mcp.ui+html"
95+
*/
96+
mimeType: string;
97+
98+
/**
99+
* Resource metadata for security and rendering configuration
100+
*
101+
* Includes Content Security Policy configuration, dedicated domain settings,
102+
* and visual preferences.
103+
*/
104+
_meta?: UIResourceMeta
61105
}
62106

63107
interface UiResourceMeta {

0 commit comments

Comments
 (0)