- Change McpbManifest type to point to v0.2 schema instead of McpbManifestAny - Add DEFAULT_MANIFEST_VERSION export to browser.ts - Update test fixtures to use manifest_version "0.2" when using McpbManifest type - Keep @deprecated annotation directing users to McpbManifestAny for multi-version support This maintains backwards compatibility for existing code using McpbManifest while encouraging new code to use McpbManifestAny for broader version support. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
70 lines
2.1 KiB
TypeScript
70 lines
2.1 KiB
TypeScript
import type * as z from "zod";
|
|
|
|
import type { McpbManifestSchema as McpbManifestSchemaAny } from "./schemas/any.js";
|
|
import type { McpbManifestSchema as McpbManifestSchemaV0_2 } from "./schemas/0.2.js";
|
|
import type {
|
|
McpbManifestAuthorSchema,
|
|
McpbManifestCompatibilitySchema,
|
|
McpbManifestMcpConfigSchema,
|
|
McpbManifestPlatformOverrideSchema,
|
|
McpbManifestPromptSchema,
|
|
McpbManifestRepositorySchema,
|
|
McpbManifestServerSchema,
|
|
McpbManifestToolSchema,
|
|
McpbSignatureInfoSchema,
|
|
McpbUserConfigurationOptionSchema,
|
|
McpbUserConfigValuesSchema,
|
|
McpServerConfigSchema,
|
|
} from "./schemas/0.3.js";
|
|
|
|
export type McpServerConfig = z.infer<typeof McpServerConfigSchema>;
|
|
|
|
export type McpbManifestAuthor = z.infer<typeof McpbManifestAuthorSchema>;
|
|
|
|
export type McpbManifestRepository = z.infer<
|
|
typeof McpbManifestRepositorySchema
|
|
>;
|
|
|
|
export type McpbManifestPlatformOverride = z.infer<
|
|
typeof McpbManifestPlatformOverrideSchema
|
|
>;
|
|
|
|
export type McpbManifestMcpConfig = z.infer<typeof McpbManifestMcpConfigSchema>;
|
|
|
|
export type McpbManifestServer = z.infer<typeof McpbManifestServerSchema>;
|
|
|
|
export type McpbManifestCompatibility = z.infer<
|
|
typeof McpbManifestCompatibilitySchema
|
|
>;
|
|
|
|
export type McpbManifestTool = z.infer<typeof McpbManifestToolSchema>;
|
|
|
|
export type McpbManifestPrompt = z.infer<typeof McpbManifestPromptSchema>;
|
|
|
|
export type McpbUserConfigurationOption = z.infer<
|
|
typeof McpbUserConfigurationOptionSchema
|
|
>;
|
|
|
|
export type McpbUserConfigValues = z.infer<typeof McpbUserConfigValuesSchema>;
|
|
|
|
/**
|
|
* McpbManifest type representing the union of all manifest versions
|
|
*/
|
|
export type McpbManifestAny = z.infer<typeof McpbManifestSchemaAny>;
|
|
|
|
/**
|
|
* McpbManifest type for v0.2 (default version) for backwards compatibility
|
|
* @deprecated Use McpbManifestAny instead to support all manifest versions.
|
|
*/
|
|
export type McpbManifest = z.infer<typeof McpbManifestSchemaV0_2>;
|
|
|
|
/**
|
|
* Information about a MCPB package signature
|
|
*/
|
|
export type McpbSignatureInfo = z.infer<typeof McpbSignatureInfoSchema>;
|
|
|
|
export interface Logger {
|
|
log: (...args: unknown[]) => void;
|
|
error: (...args: unknown[]) => void;
|
|
warn: (...args: unknown[]) => void;
|
|
}
|