@maxhealth.tech/prefab / mcp / McpTextResourceContents
Type Alias: McpTextResourceContents
type McpTextResourceContents = object;Defined in: mcp/types.ts:54
Text resource contents (has text, never blob).
Declared as a type alias, not an interface, and the difference is load-bearing. The SDK's resource types are passthrough ({ [x: string]: unknown }), and TypeScript grants an implicit index signature only to type aliases of object types — never to interfaces, since an interface can be reopened by declaration merging and so its key set is not final. Declaring this as an interface makes it fail to satisfy the SDK's shape with "Index signature for type 'string' is missing", which a consumer can only work around by casting.
Properties
uri
uri: string;Defined in: mcp/types.ts:55
mimeType?
optional mimeType?: string;Defined in: mcp/types.ts:56
text
text: string;Defined in: mcp/types.ts:57
_meta?
optional _meta?: Record<string, unknown>;Defined in: mcp/types.ts:58