MCPcopy Create free account
hub / github.com/modelcontextprotocol/mcpb / buildManifest

Function buildManifest

src/cli/init.ts:809–935  ·  view source on GitHub ↗
(
  basicInfo: {
    name: string;
    displayName: string;
    version: string;
    description: string;
    authorName: string;
  },
  longDescription: string | undefined,
  authorInfo: {
    authorEmail: string;
    authorUrl: string;
  },
  urls: {
    homepage: string;
    documentation: string;
    support: string;
  },
  visualAssets: {
    icon: string;
    icons: Array<{
      src: string;
      size: string;
      theme?: string;
    }>;
    screenshots: string[];
  },
  serverConfig: {
    serverType: "node" | "python" | "binary";
    entryPoint: string;
    mcp_config: {
      command: string;
      args: string[];
      env?: Record<string, string>;
    };
  },
  tools: Array<{ name: string; description?: string }>,
  toolsGenerated: boolean,
  prompts: Array<{
    name: string;
    description?: string;
    arguments?: string[];
    text: string;
  }>,
  promptsGenerated: boolean,
  compatibility:
    | {
        claude_desktop?: string;
        platforms?: ("darwin" | "win32" | "linux")[];
        runtimes?: { python?: string; node?: string };
      }
    | undefined,
  userConfig: Record<
    string,
    {
      type: "string" | "number" | "boolean" | "directory" | "file";
      title: string;
      description: string;
      required?: boolean;
      default?: string | number | boolean | string[];
      multiple?: boolean;
      sensitive?: boolean;
      min?: number;
      max?: number;
    }
  >,
  optionalFields: {
    keywords: string;
    license: string;
    repository?: { type: string; url: string };
  },
  // localization?: {
  //   resources: string;
  //   default_locale: string;
  // },
)

Source from the content-addressed store, hash-verified

807}
808
809export function buildManifest(
810 basicInfo: {
811 name: string;
812 displayName: string;
813 version: string;
814 description: string;
815 authorName: string;
816 },
817 longDescription: string | undefined,
818 authorInfo: {
819 authorEmail: string;
820 authorUrl: string;
821 },
822 urls: {
823 homepage: string;
824 documentation: string;
825 support: string;
826 },
827 visualAssets: {
828 icon: string;
829 icons: Array<{
830 src: string;
831 size: string;
832 theme?: string;
833 }>;
834 screenshots: string[];
835 },
836 serverConfig: {
837 serverType: "node" | "python" | "binary";
838 entryPoint: string;
839 mcp_config: {
840 command: string;
841 args: string[];
842 env?: Record<string, string>;
843 };
844 },
845 tools: Array<{ name: string; description?: string }>,
846 toolsGenerated: boolean,
847 prompts: Array<{
848 name: string;
849 description?: string;
850 arguments?: string[];
851 text: string;
852 }>,
853 promptsGenerated: boolean,
854 compatibility:
855 | {
856 claude_desktop?: string;
857 platforms?: ("darwin" | "win32" | "linux")[];
858 runtimes?: { python?: string; node?: string };
859 }
860 | undefined,
861 userConfig: Record<
862 string,
863 {
864 type: "string" | "number" | "boolean" | "directory" | "file";
865 title: string;
866 description: string;

Callers 2

init.test.tsFile · 0.85
initExtensionFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…