Skip to main content

Artifact bundle

The artifact bundle is everything the server needs to run, produced by one build. The plugin writes it to build/mcp/bundle.json (or to the directory set by outputDir).

What's in it​

MemberDescription
formatVersionLayout version of the bundle. The runtime rejects bundles newer than it can read, with a message saying which version to upgrade to
manifestThe build that produced it: server name and version, site URL, build time, document and skill counts, and which indexers ran
docsEvery extracted page (title, description, Markdown, headings), keyed by its document ID, the page's full URL
searchIndexThe search index, if an indexer produced one. The built-in local indexer does by default
skillsThe packaged Agent Skills, if any
extrasFiles contributed by custom indexers, keyed by filename. Only a matching search provider reads them

Files in build/mcp/​

FilePurpose
bundle.jsonThe bundle. This is the file to import in your function.
docs.json, search-index.json, skills.json, manifest.jsonThe same members as separate files, kept through 2.x for deployments that read them individually. Deprecated, and removed in 3.0
other filesIndexer extras, written by custom indexers

Using it​

  • Serverless and edge: import it as JSON and pass it as artifacts:

    import bundle from '../build/mcp/bundle.json' with { type: 'json' };
    createWebRequestHandler({ artifacts: bundle });
  • Node: pass the directory as artifactsDir, or read it yourself with readArtifactBundle('./build/mcp').

The bundle is plain JSON and contains only your published pages, so it's safe to serve publicly. Its size grows with your docs, and most of it is the Markdown and the search index. Check it with ls -lh build/mcp/bundle.json if your platform limits function size.