Fix type error in buildManifest return type

Changed return type to use the specific v0.2 manifest schema type since the
function returns a manifest with DEFAULT_MANIFEST_VERSION (0.2).

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Joan Xie 2025-11-01 20:37:15 -07:00
commit e7d6ea3e68
No known key found for this signature in database

View file

@ -3,7 +3,8 @@ import { existsSync, readFileSync, writeFileSync } from "fs";
import { basename, join, resolve } from "path";
import { DEFAULT_MANIFEST_VERSION } from "../shared/constants.js";
import type { McpbManifest } from "../types.js";
import type { McpbManifestSchema as McpbManifestSchemaV0_2 } from "../schemas/0.2.js";
import type * as z from "zod";
interface PackageJson {
name?: string;
@ -878,7 +879,7 @@ export function buildManifest(
resources: string;
default_locale: string;
},
): McpbManifest {
): z.infer<typeof McpbManifestSchemaV0_2> {
const { name, displayName, version, description, authorName } = basicInfo;
const { authorEmail, authorUrl } = authorInfo;
const { serverType, entryPoint, mcp_config } = serverConfig;