@farming-labs/docs 0.2.75 → 0.2.77

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (38) hide show
  1. package/dist/{agent-DxTa3PLB.mjs → agent-D4hNGatV.mjs} +2 -2
  2. package/dist/{agent-cAPjC2jb.d.mts → agent-DRKj42ht.d.mts} +18 -2
  3. package/dist/{agent-BHqaZx-X.mjs → agent-SRIJ-oF8.mjs} +26 -6
  4. package/dist/{agent-evals-21LZ_uEl.mjs → agent-evals-DmFoKy_y.mjs} +1 -1
  5. package/dist/{agent-export-3VheegEK.mjs → agent-export-CM-p9_YD.mjs} +7 -7
  6. package/dist/agent-skills-bundle.d.mts +1 -1
  7. package/dist/{agent-skills-server-noFn1l_p.mjs → agent-skills-server-B2EXn2QD.mjs} +1 -1
  8. package/dist/{agent-skills-server-Cix64aGB.d.mts → agent-skills-server-CJ4D0G9P.d.mts} +2 -2
  9. package/dist/agent-skills-vite.d.mts +3 -3
  10. package/dist/agent-skills-vite.mjs +2 -2
  11. package/dist/{agents-ByTdP0Hl.mjs → agents-BeLDNCnE.mjs} +7 -16
  12. package/dist/cli/index.mjs +15 -15
  13. package/dist/client/react.d.mts +1 -1
  14. package/dist/{cloud-ask-ai-Bt0rzFbe.d.mts → cloud-ask-ai-BCgHPxew.d.mts} +1 -1
  15. package/dist/{dev-Cc1cFFj-.mjs → dev-kjaxOOla.mjs} +8 -2
  16. package/dist/docs-cloud-server.d.mts +2 -2
  17. package/dist/{doctor-C34VVF85.mjs → doctor-DhMVKHjp.mjs} +56 -24
  18. package/dist/{golden-evaluations-D_oDJwGv.mjs → golden-evaluations-VzE6juQl.mjs} +7 -3
  19. package/dist/index.d.mts +5 -5
  20. package/dist/index.mjs +6 -6
  21. package/dist/{mcp-Bnqfu8P5.mjs → mcp-CZkQJXtA.mjs} +6 -6
  22. package/dist/mcp.d.mts +26 -5
  23. package/dist/mcp.mjs +366 -61
  24. package/dist/{prompt-references-CfyYOa_W.mjs → prompt-references-B6L3AD98.mjs} +3 -3
  25. package/dist/{retrieval-digest-CFOcSKTo.d.mts → retrieval-digest-rponR4jM.d.mts} +24 -6
  26. package/dist/{review-Dw6oCQX3.mjs → review-nxoV8jIm.mjs} +5 -5
  27. package/dist/{robots-DaYBoy_A.mjs → robots-CgH6Stqn.mjs} +2 -2
  28. package/dist/{robots-KWLujSLI.mjs → robots-CiQT8mX2.mjs} +3 -3
  29. package/dist/{search-DBdmbUkc.mjs → search-BTUIkhnT.mjs} +6 -6
  30. package/dist/{search-BmC8wVr0.mjs → search-Da2AKaFJ.mjs} +624 -122
  31. package/dist/server.d.mts +9 -7
  32. package/dist/server.mjs +7 -7
  33. package/dist/{sitemap-CrzG5Wpf.mjs → sitemap-e0_GeCWJ.mjs} +6 -6
  34. package/dist/{sitemap-server-B9LZQ1FE.mjs → sitemap-server-DHaxyPAd.mjs} +12 -3
  35. package/dist/{standards-discovery-BwL5ffGx.mjs → standards-discovery-BKlEnK_H.mjs} +32 -4
  36. package/dist/{standards-discovery-DBI1PD7m.d.mts → standards-discovery-BbslY4id.d.mts} +34 -7
  37. package/dist/{types-BDRwrExu.d.mts → types-B-5Kzmkn.d.mts} +68 -1
  38. package/package.json +1 -1
@@ -1,6 +1,6 @@
1
- import { B as findDocsMarkdownPage, at as renderDocsMarkdownDocument } from "./agent-BHqaZx-X.mjs";
1
+ import { B as findDocsMarkdownPage, at as renderDocsMarkdownDocument } from "./agent-SRIJ-oF8.mjs";
2
2
  import { v as normalizePageAgentFrontmatter, x as stripGeneratedPageAgentContractMarkdown } from "./markdown-sections-7OoA7ylx.mjs";
3
- import { F as serializeGeneratedAgentDocument, M as hashGeneratedAgentContent, P as parseGeneratedAgentDocument, j as GENERATED_AGENT_PROVENANCE_VERSION } from "./search-BmC8wVr0.mjs";
3
+ import { F as GENERATED_AGENT_PROVENANCE_VERSION, I as hashGeneratedAgentContent, R as parseGeneratedAgentDocument, z as serializeGeneratedAgentDocument } from "./search-Da2AKaFJ.mjs";
4
4
  import { createFilesystemDocsMcpSource } from "./mcp.mjs";
5
5
  import { _ as resolveDocsContentDir, a as loadDocsConfigModule, c as loadProjectEnv, d as readNavTitle, f as readNumberProperty, g as resolveDocsConfigPath, h as readTopLevelStringProperty, l as readBooleanProperty, p as readStringProperty, t as extractNestedObjectLiteral, u as readEnvReferenceProperty } from "./config-Wcdj-D0a.mjs";
6
6
  import { createRequire } from "node:module";
@@ -1,5 +1,5 @@
1
- import { Bn as LlmsTxtSectionConfig, G as DocsAgentFeedbackData, Ln as LlmsTxtConfig, Mt as DocsI18nConfig, Nn as FeedbackConfig, Rn as LlmsTxtMaxCharsConfig, Rt as DocsMcpConfig, cr as ResolvedDocsRelatedLink, er as PageAgentFrontmatter, in as DocsRobotsConfig, kt as DocsConfig, un as DocsSearchConfig, wn as DocsSitemapConfig, xn as DocsSearchSourcePage, zn as LlmsTxtMaxCharsMode } from "./types-BDRwrExu.mjs";
2
- import { I as DocsDiscoveryApiRouteOptions, L as DocsPublishedAgentSkill, O as DocsA2AAgentCardOptions } from "./standards-discovery-DBI1PD7m.mjs";
1
+ import { Bn as LlmsTxtMaxCharsConfig, Cn as DocsSearchSourcePage, En as DocsSitemapConfig, Fn as FeedbackConfig, G as DocsAgentFeedbackData, Hn as LlmsTxtSectionConfig, Mt as DocsI18nConfig, Rt as DocsMcpConfig, Vn as LlmsTxtMaxCharsMode, an as DocsRobotsConfig, fn as DocsSearchConfig, kt as DocsConfig, nr as PageAgentFrontmatter, ur as ResolvedDocsRelatedLink, zn as LlmsTxtConfig } from "./types-B-5Kzmkn.mjs";
2
+ import { O as DocsA2AAgentCardOptions, R as DocsDiscoveryApiRouteOptions, z as DocsPublishedAgentSkill } from "./standards-discovery-BbslY4id.mjs";
3
3
  import { DocsMcpPage, DocsMcpResolvedConfig } from "./mcp.mjs";
4
4
 
5
5
  //#region src/i18n.d.ts
@@ -147,6 +147,8 @@ interface DocsOpenApiDiscoveryConfig {
147
147
  source?: "generated" | "configured";
148
148
  specUrl?: string;
149
149
  apiReferencePath?: string;
150
+ /** Product API targets described by this OpenAPI document. */
151
+ catalogTargets?: readonly string[];
150
152
  }
151
153
  interface DocsOpenApiResolvedDiscoveryConfig {
152
154
  enabled: boolean;
@@ -156,6 +158,8 @@ interface DocsOpenApiResolvedDiscoveryConfig {
156
158
  source?: "generated" | "configured";
157
159
  specUrl?: string;
158
160
  apiReferencePath?: string;
161
+ /** Product API targets described by this OpenAPI document. */
162
+ catalogTargets?: readonly string[];
159
163
  }
160
164
  type DocsConfigMapJsonPrimitive = string | number | boolean | null;
161
165
  type DocsConfigMapJsonValue = DocsConfigMapJsonPrimitive | DocsConfigMapJsonValue[] | {
@@ -211,6 +215,14 @@ interface DocsDiagnosticsFeature {
211
215
  };
212
216
  responseFormat?: "docs-search.v1";
213
217
  warningsField?: "warnings";
218
+ /** Opaque continuation token accepted by structured search. */
219
+ cursorParam?: "cursor";
220
+ /** Optional continuation token returned when another result page is available. */
221
+ nextCursorField?: "nextCursor";
222
+ /** Boolean structured-response field indicating whether another page is available. */
223
+ hasMoreField?: "hasMore";
224
+ /** Structured-response field containing the total matches across all pages. */
225
+ totalField?: "total";
214
226
  provider?: string;
215
227
  mode?: string;
216
228
  transport?: "GET" | "POST" | "GET/HEAD" | "GET/POST";
@@ -823,6 +835,10 @@ declare function buildDocsAgentDiscoverySpec({
823
835
  };
824
836
  repeatedFilterParams: string[];
825
837
  warningsField: string;
838
+ cursorParam: string;
839
+ nextCursorField: string;
840
+ hasMoreField: string;
841
+ totalField: string;
826
842
  };
827
843
  agents: {
828
844
  enabled: boolean;
@@ -1,5 +1,5 @@
1
1
  import { S as upsertPageAgentContractMarkdown, b as renderPageAgentFrontmatterYamlLines, o as findDocsMarkdownSection, p as PAGE_AGENT_CONTRACT_FIELD_SCHEMA, s as parseDocsMarkdownSections } from "./markdown-sections-7OoA7ylx.mjs";
2
- import { F as isDocsStandardsDiscoveryRequest, I as resolveDocsDiscoveryApiRoute, M as createDocsStandardsResponse, S as DOCS_AGENT_MANIFEST_FORMAT, T as DOCS_AGENT_MANIFEST_VERSION, _ as DEFAULT_API_CATALOG_FORMAT, a as DEFAULT_A2A_AGENT_CARD_ROUTE, b as DEFAULT_LEGACY_SKILLS_INDEX_ROUTE, c as DEFAULT_AGENT_SKILLS_ARCHIVE_ROUTE_PATTERN, d as DEFAULT_AGENT_SKILLS_ROUTE_PATTERN, k as buildDocsApiCatalog, l as DEFAULT_AGENT_SKILLS_INDEX_FORMAT, n as API_CATALOG_MEDIA_TYPE, r as API_CATALOG_PROFILE_URI, t as AGENT_SKILLS_DISCOVERY_SCHEMA_URI, u as DEFAULT_AGENT_SKILLS_INDEX_ROUTE, v as DEFAULT_API_CATALOG_ROUTE, w as DOCS_AGENT_MANIFEST_SCHEMA_URI } from "./standards-discovery-BwL5ffGx.mjs";
2
+ import { F as isDocsStandardsDiscoveryRequest, I as resolveDocsDiscoveryApiRoute, M as createDocsStandardsResponse, S as DOCS_AGENT_MANIFEST_FORMAT, T as DOCS_AGENT_MANIFEST_VERSION, _ as DEFAULT_API_CATALOG_FORMAT, a as DEFAULT_A2A_AGENT_CARD_ROUTE, b as DEFAULT_LEGACY_SKILLS_INDEX_ROUTE, c as DEFAULT_AGENT_SKILLS_ARCHIVE_ROUTE_PATTERN, d as DEFAULT_AGENT_SKILLS_ROUTE_PATTERN, k as buildDocsApiCatalog, l as DEFAULT_AGENT_SKILLS_INDEX_FORMAT, n as API_CATALOG_MEDIA_TYPE, r as API_CATALOG_PROFILE_URI, t as AGENT_SKILLS_DISCOVERY_SCHEMA_URI, u as DEFAULT_AGENT_SKILLS_INDEX_ROUTE, v as DEFAULT_API_CATALOG_ROUTE, w as DOCS_AGENT_MANIFEST_SCHEMA_URI } from "./standards-discovery-BKlEnK_H.mjs";
3
3
  import { createProcessor } from "@mdx-js/mdx";
4
4
 
5
5
  //#region src/mcp-auth.ts
@@ -2435,6 +2435,10 @@ function buildDocsDiagnostics(config, options = {}) {
2435
2435
  },
2436
2436
  responseFormat: "docs-search.v1",
2437
2437
  warningsField: "warnings",
2438
+ cursorParam: "cursor",
2439
+ nextCursorField: "nextCursor",
2440
+ hasMoreField: "hasMore",
2441
+ totalField: "total",
2438
2442
  provider: search.provider,
2439
2443
  transport: "GET"
2440
2444
  },
@@ -3275,7 +3279,13 @@ async function createDocsStandardsDiscoveryResponse({ request, preferredSkillDoc
3275
3279
  mcpRoute: mcp.enabled ? mcp.route : null,
3276
3280
  protectedResourceMetadataRoutes,
3277
3281
  feedbackRoutes: feedback?.enabled ? [feedbackRoute, feedbackSchemaRoute] : [],
3278
- openapiRoute: openapiConfig.enabled ? openapiUrl ?? `${resolvedApiRoute}?format=openapi` : null,
3282
+ openapiDefinitions: openapiConfig.enabled && openapiConfig.catalogTargets?.length ? [{
3283
+ route: openapiUrl ?? `${resolvedApiRoute}?format=openapi`,
3284
+ targets: openapiConfig.catalogTargets.map((route) => ({
3285
+ route,
3286
+ title: "Product API"
3287
+ }))
3288
+ }] : [],
3279
3289
  apiReferenceRoute: openapiConfig.enabled && openapiConfig.apiReferencePath ? openapiConfig.apiReferencePath : null
3280
3290
  }) : void 0
3281
3291
  });
@@ -4541,7 +4551,11 @@ function buildDocsAgentDiscoverySpec({ origin, entry = "docs", apiRoute, apiCata
4541
4551
  "package",
4542
4552
  "tags"
4543
4553
  ],
4544
- warningsField: "warnings"
4554
+ warningsField: "warnings",
4555
+ cursorParam: "cursor",
4556
+ nextCursorField: "nextCursor",
4557
+ hasMoreField: "hasMore",
4558
+ totalField: "total"
4545
4559
  },
4546
4560
  agents: {
4547
4561
  enabled: true,
@@ -4682,16 +4696,22 @@ function resolveDocsOpenApiDiscoveryConfig(openapi) {
4682
4696
  enabled: true,
4683
4697
  url: DEFAULT_OPENAPI_SCHEMA_ROUTE,
4684
4698
  urlSource: "default",
4685
- source: "generated"
4699
+ source: "generated",
4700
+ catalogTargets: ["/"]
4686
4701
  };
4687
4702
  if (openapi.enabled === false) return { enabled: false };
4703
+ const specUrl = openapi.specUrl?.trim();
4704
+ const source = openapi.source ?? (specUrl ? "configured" : "generated");
4705
+ const requestRelativeSpecUrl = specUrl?.startsWith("/") && !specUrl.startsWith("//");
4706
+ const catalogTargets = openapi.catalogTargets === void 0 ? source === "generated" || requestRelativeSpecUrl ? ["/"] : void 0 : Array.from(new Set(openapi.catalogTargets.filter((target) => typeof target === "string").map((target) => target.trim()).filter(Boolean)));
4688
4707
  return {
4689
4708
  enabled: true,
4690
4709
  url: openapi.url ?? DEFAULT_OPENAPI_SCHEMA_ROUTE,
4691
4710
  urlSource: openapi.urlSource ?? (openapi.url === void 0 ? "default" : "configured"),
4692
- source: openapi.source ?? "generated",
4711
+ source,
4693
4712
  specUrl: openapi.specUrl,
4694
- apiReferencePath: openapi.apiReferencePath
4713
+ apiReferencePath: openapi.apiReferencePath,
4714
+ catalogTargets
4695
4715
  };
4696
4716
  }
4697
4717
  function resolveDocsOpenApiDiscoveryUrl(openapi, apiRoute) {
@@ -1,5 +1,5 @@
1
1
  import { S as upsertPageAgentContractMarkdown, l as stripDocsGeneratedAgentContractMarkers, o as findDocsMarkdownSection } from "./markdown-sections-7OoA7ylx.mjs";
2
- import { C as agentVersionConstraintsOverlap, D as normalizeAgentVersion, E as normalizeAgentScopeValues, S as agentVersionConstraintMatches, T as normalizeAgentLocale, b as resolveSearchRequestConfig, f as normalizeDocsSearchFilters, p as performDocsSearch, t as buildDocsAskAIContext, w as normalizeAgentFramework, x as agentVersionConstraintGroupsOverlap } from "./search-BmC8wVr0.mjs";
2
+ import { C as agentVersionConstraintGroupsOverlap, D as normalizeAgentLocale, E as normalizeAgentFramework, O as normalizeAgentScopeValues, S as resolveSearchRequestConfig, T as agentVersionConstraintsOverlap, k as normalizeAgentVersion, m as performDocsSearch, n as buildDocsAskAIContext, p as normalizeDocsSearchFilters, w as agentVersionConstraintMatches } from "./search-Da2AKaFJ.mjs";
3
3
  import { buildDocsMcpContext } from "./mcp.mjs";
4
4
  import { i as validateCodeBlockPlans, n as planCodeBlockTargets, r as resolveDocsCodeBlocksValidateConfig, t as extractCodeBlocksFromMarkdown } from "./code-blocks-DnNVNK2M.mjs";
5
5
  import { existsSync, mkdirSync, readFileSync, writeFileSync } from "node:fs";
@@ -1,14 +1,14 @@
1
- import { A as buildDocsAgentDiscoverySpec, Bt as renderDocsSitemapMarkdown, Ht as resolveDocsSitemapConfig, Lt as buildDocsSitemapManifest, S as DEFAULT_SKILL_MD_WELL_KNOWN_ROUTE, Vt as renderDocsSitemapXml, a as DEFAULT_AGENT_MD_ROUTE, at as renderDocsMarkdownDocument, c as DEFAULT_AGENT_SPEC_WELL_KNOWN_JSON_ROUTE, g as DEFAULT_LLMS_FULL_TXT_WELL_KNOWN_ROUTE, h as DEFAULT_LLMS_FULL_TXT_ROUTE, it as renderDocsLlmsTxt, l as DEFAULT_AGENT_SPEC_WELL_KNOWN_ROUTE, lt as resolveDocsAgentFeedbackConfig, n as DEFAULT_AGENTS_MD_WELL_KNOWN_ROUTE, o as DEFAULT_AGENT_MD_WELL_KNOWN_ROUTE, rt as renderDocsAgentsDocument, st as renderDocsSkillDocument, t as DEFAULT_AGENTS_MD_ROUTE, v as DEFAULT_LLMS_TXT_ROUTE, wt as toDocsMarkdownUrl, x as DEFAULT_SKILL_MD_ROUTE, y as DEFAULT_LLMS_TXT_WELL_KNOWN_ROUTE } from "./agent-BHqaZx-X.mjs";
1
+ import { A as buildDocsAgentDiscoverySpec, Bt as renderDocsSitemapMarkdown, Ht as resolveDocsSitemapConfig, Lt as buildDocsSitemapManifest, S as DEFAULT_SKILL_MD_WELL_KNOWN_ROUTE, Vt as renderDocsSitemapXml, a as DEFAULT_AGENT_MD_ROUTE, at as renderDocsMarkdownDocument, c as DEFAULT_AGENT_SPEC_WELL_KNOWN_JSON_ROUTE, g as DEFAULT_LLMS_FULL_TXT_WELL_KNOWN_ROUTE, h as DEFAULT_LLMS_FULL_TXT_ROUTE, it as renderDocsLlmsTxt, l as DEFAULT_AGENT_SPEC_WELL_KNOWN_ROUTE, lt as resolveDocsAgentFeedbackConfig, n as DEFAULT_AGENTS_MD_WELL_KNOWN_ROUTE, o as DEFAULT_AGENT_MD_WELL_KNOWN_ROUTE, rt as renderDocsAgentsDocument, st as renderDocsSkillDocument, t as DEFAULT_AGENTS_MD_ROUTE, v as DEFAULT_LLMS_TXT_ROUTE, wt as toDocsMarkdownUrl, x as DEFAULT_SKILL_MD_ROUTE, y as DEFAULT_LLMS_TXT_WELL_KNOWN_ROUTE } from "./agent-SRIJ-oF8.mjs";
2
2
  import "./markdown-sections-7OoA7ylx.mjs";
3
- import { A as buildDocsLegacySkillsIndex, D as buildDocsA2AAgentCard, L as resolveDocsPublishedAgentSkill, O as buildDocsAgentSkillsIndex, a as DEFAULT_A2A_AGENT_CARD_ROUTE, b as DEFAULT_LEGACY_SKILLS_INDEX_ROUTE, f as DEFAULT_AGENT_SKILLS_ROUTE_PREFIX, u as DEFAULT_AGENT_SKILLS_INDEX_ROUTE, x as DEFAULT_LEGACY_SKILLS_ROUTE_PREFIX } from "./standards-discovery-BwL5ffGx.mjs";
4
- import "./search-BmC8wVr0.mjs";
3
+ import { A as buildDocsLegacySkillsIndex, D as buildDocsA2AAgentCard, L as resolveDocsPublishedAgentSkill, O as buildDocsAgentSkillsIndex, a as DEFAULT_A2A_AGENT_CARD_ROUTE, b as DEFAULT_LEGACY_SKILLS_INDEX_ROUTE, f as DEFAULT_AGENT_SKILLS_ROUTE_PREFIX, u as DEFAULT_AGENT_SKILLS_INDEX_ROUTE, x as DEFAULT_LEGACY_SKILLS_ROUTE_PREFIX } from "./standards-discovery-BKlEnK_H.mjs";
4
+ import "./search-Da2AKaFJ.mjs";
5
5
  import { t as resolveDocsI18n } from "./i18n-hHVWcflJ.mjs";
6
- import { c as renderDocsRobotsGeneratedBlock, f as upsertDocsRobotsGeneratedBlock, i as DOCS_ROBOTS_GENERATED_BLOCK_START, r as DOCS_ROBOTS_GENERATED_BLOCK_END, u as resolveDocsRobotsConfig } from "./robots-DaYBoy_A.mjs";
7
- import "./sitemap-server-B9LZQ1FE.mjs";
8
- import "./agent-evals-21LZ_uEl.mjs";
6
+ import { c as renderDocsRobotsGeneratedBlock, f as upsertDocsRobotsGeneratedBlock, i as DOCS_ROBOTS_GENERATED_BLOCK_START, r as DOCS_ROBOTS_GENERATED_BLOCK_END, u as resolveDocsRobotsConfig } from "./robots-CgH6Stqn.mjs";
7
+ import "./sitemap-server-DHaxyPAd.mjs";
8
+ import "./agent-evals-DmFoKy_y.mjs";
9
9
  import { createFilesystemDocsMcpSource, resolveDocsMcpConfig } from "./mcp.mjs";
10
10
  import "./code-blocks-DnNVNK2M.mjs";
11
- import { t as resolveConfiguredAgentSkills } from "./agent-skills-server-noFn1l_p.mjs";
11
+ import { t as resolveConfiguredAgentSkills } from "./agent-skills-server-B2EXn2QD.mjs";
12
12
  import "./server.mjs";
13
13
  import { _ as resolveDocsContentDir, a as loadDocsConfigModule, d as readNavTitle, g as resolveDocsConfigPath, h as readTopLevelStringProperty, l as readBooleanProperty, m as readTopLevelBooleanProperty, p as readStringProperty, r as extractTopLevelConfigObject, t as extractNestedObjectLiteral } from "./config-Wcdj-D0a.mjs";
14
14
  import { t as detectFramework } from "./utils-DpiIioYb.mjs";
@@ -1,4 +1,4 @@
1
- import { L as DocsPublishedAgentSkill } from "./standards-discovery-DBI1PD7m.mjs";
1
+ import { z as DocsPublishedAgentSkill } from "./standards-discovery-BbslY4id.mjs";
2
2
 
3
3
  //#region src/agent-skills-bundle.d.ts
4
4
  /**
@@ -1,4 +1,4 @@
1
- import { f as DEFAULT_AGENT_SKILLS_ROUTE_PREFIX, j as buildDocsPublishedAgentSkill } from "./standards-discovery-BwL5ffGx.mjs";
1
+ import { f as DEFAULT_AGENT_SKILLS_ROUTE_PREFIX, j as buildDocsPublishedAgentSkill } from "./standards-discovery-BKlEnK_H.mjs";
2
2
  import { existsSync, lstatSync, readFileSync, readdirSync, realpathSync, statSync } from "node:fs";
3
3
  import path from "node:path";
4
4
  import { createHash } from "node:crypto";
@@ -1,5 +1,5 @@
1
- import { $ as DocsAgentSkillsInput } from "./types-BDRwrExu.mjs";
2
- import { L as DocsPublishedAgentSkill } from "./standards-discovery-DBI1PD7m.mjs";
1
+ import { $ as DocsAgentSkillsInput } from "./types-B-5Kzmkn.mjs";
2
+ import { z as DocsPublishedAgentSkill } from "./standards-discovery-BbslY4id.mjs";
3
3
 
4
4
  //#region src/agent-skills-server.d.ts
5
5
  interface ResolveConfiguredAgentSkillsOptions {
@@ -1,6 +1,6 @@
1
- import { $ as DocsAgentSkillsInput } from "./types-BDRwrExu.mjs";
2
- import { L as DocsPublishedAgentSkill } from "./standards-discovery-DBI1PD7m.mjs";
3
- import { t as ResolveConfiguredAgentSkillsOptions } from "./agent-skills-server-Cix64aGB.mjs";
1
+ import { $ as DocsAgentSkillsInput } from "./types-B-5Kzmkn.mjs";
2
+ import { z as DocsPublishedAgentSkill } from "./standards-discovery-BbslY4id.mjs";
3
+ import { t as ResolveConfiguredAgentSkillsOptions } from "./agent-skills-server-CJ4D0G9P.mjs";
4
4
 
5
5
  //#region src/agent-skills-vite.d.ts
6
6
  declare const DOCS_AGENT_SKILLS_BUNDLE_MODULE = "@farming-labs/docs/agent-skills-bundle";
@@ -1,5 +1,5 @@
1
- import "./standards-discovery-BwL5ffGx.mjs";
2
- import { t as resolveConfiguredAgentSkills } from "./agent-skills-server-noFn1l_p.mjs";
1
+ import "./standards-discovery-BKlEnK_H.mjs";
2
+ import { t as resolveConfiguredAgentSkills } from "./agent-skills-server-B2EXn2QD.mjs";
3
3
 
4
4
  //#region src/agent-skills-vite.ts
5
5
  const DOCS_AGENT_SKILLS_BUNDLE_MODULE = "@farming-labs/docs/agent-skills-bundle";
@@ -1,12 +1,12 @@
1
- import { a as DEFAULT_AGENT_MD_ROUTE, b as DEFAULT_OPENAPI_SCHEMA_ROUTE, lt as resolveDocsAgentFeedbackConfig, n as DEFAULT_AGENTS_MD_WELL_KNOWN_ROUTE, o as DEFAULT_AGENT_MD_WELL_KNOWN_ROUTE, rt as renderDocsAgentsDocument, t as DEFAULT_AGENTS_MD_ROUTE } from "./agent-BHqaZx-X.mjs";
1
+ import { a as DEFAULT_AGENT_MD_ROUTE, lt as resolveDocsAgentFeedbackConfig, n as DEFAULT_AGENTS_MD_WELL_KNOWN_ROUTE, o as DEFAULT_AGENT_MD_WELL_KNOWN_ROUTE, rt as renderDocsAgentsDocument, t as DEFAULT_AGENTS_MD_ROUTE } from "./agent-SRIJ-oF8.mjs";
2
2
  import "./markdown-sections-7OoA7ylx.mjs";
3
- import "./standards-discovery-BwL5ffGx.mjs";
4
- import "./search-BmC8wVr0.mjs";
5
- import { S as resolveApiReferenceConfig } from "./sitemap-server-B9LZQ1FE.mjs";
6
- import "./agent-evals-21LZ_uEl.mjs";
3
+ import "./standards-discovery-BKlEnK_H.mjs";
4
+ import "./search-Da2AKaFJ.mjs";
5
+ import { C as resolveApiReferenceOpenApiDiscovery } from "./sitemap-server-DHaxyPAd.mjs";
6
+ import "./agent-evals-DmFoKy_y.mjs";
7
7
  import { resolveDocsMcpConfig } from "./mcp.mjs";
8
8
  import "./code-blocks-DnNVNK2M.mjs";
9
- import "./agent-skills-server-noFn1l_p.mjs";
9
+ import "./agent-skills-server-B2EXn2QD.mjs";
10
10
  import "./server.mjs";
11
11
  import { a as loadDocsConfigModule, d as readNavTitle, g as resolveDocsConfigPath, h as readTopLevelStringProperty, l as readBooleanProperty, p as readStringProperty, t as extractNestedObjectLiteral } from "./config-Wcdj-D0a.mjs";
12
12
  import { t as detectFramework } from "./utils-DpiIioYb.mjs";
@@ -129,16 +129,7 @@ function writeIfNeeded(filePath, content, options) {
129
129
  return "changed";
130
130
  }
131
131
  function resolveOpenApiDiscovery(config) {
132
- const apiReference = resolveApiReferenceConfig(config?.apiReference);
133
- if (!apiReference.enabled) return { enabled: false };
134
- return {
135
- enabled: true,
136
- url: DEFAULT_OPENAPI_SCHEMA_ROUTE,
137
- urlSource: "default",
138
- source: apiReference.specUrl ? "configured" : "generated",
139
- specUrl: apiReference.specUrl,
140
- apiReferencePath: `/${apiReference.path}`
141
- };
132
+ return resolveApiReferenceOpenApiDiscovery(config?.apiReference);
142
133
  }
143
134
  async function generateAgents(options = {}) {
144
135
  const rootDir = process.cwd();
@@ -111,7 +111,7 @@ async function main() {
111
111
  const { init } = await import("../init-DAkI0Lkf.mjs");
112
112
  await init(initOptions);
113
113
  } else if (parsedCommand.command === "dev") {
114
- const { dev } = await import("../dev-Cc1cFFj-.mjs");
114
+ const { dev } = await import("../dev-kjaxOOla.mjs");
115
115
  await dev(devOptions);
116
116
  } else if (parsedCommand.command === "deploy") {
117
117
  const { runCloudDeploy } = await import("../cloud-pdNC-tyj.mjs");
@@ -141,10 +141,10 @@ async function main() {
141
141
  printCloudHelp();
142
142
  process.exit(1);
143
143
  } else if (parsedCommand.command === "mcp") {
144
- const { runMcp } = await import("../mcp-Bnqfu8P5.mjs");
144
+ const { runMcp } = await import("../mcp-CZkQJXtA.mjs");
145
145
  await runMcp(mcpOptions);
146
146
  } else if (parsedCommand.command === "agent" && subcommand === "compact") {
147
- const { compactAgentDocs, parseAgentCompactArgs, printAgentCompactHelp } = await import("../agent-DxTa3PLB.mjs").then((n) => n.t);
147
+ const { compactAgentDocs, parseAgentCompactArgs, printAgentCompactHelp } = await import("../agent-D4hNGatV.mjs").then((n) => n.t);
148
148
  const agentCompactOptions = parseAgentCompactArgs(args.slice(2));
149
149
  if (agentCompactOptions.help) {
150
150
  printAgentCompactHelp();
@@ -152,7 +152,7 @@ async function main() {
152
152
  }
153
153
  await compactAgentDocs(agentCompactOptions);
154
154
  } else if (parsedCommand.command === "agent" && subcommand === "export") {
155
- const { exportAgentBundle, parseAgentExportArgs, printAgentExportHelp } = await import("../agent-export-3VheegEK.mjs");
155
+ const { exportAgentBundle, parseAgentExportArgs, printAgentExportHelp } = await import("../agent-export-CM-p9_YD.mjs");
156
156
  const agentExportOptions = parseAgentExportArgs(args.slice(2));
157
157
  if (agentExportOptions.help) {
158
158
  printAgentExportHelp();
@@ -162,13 +162,13 @@ async function main() {
162
162
  } else if (parsedCommand.command === "agent") {
163
163
  console.error(pc.red(`Unknown agent subcommand: ${subcommand ?? "(missing)"}`));
164
164
  console.error();
165
- const { printAgentCompactHelp } = await import("../agent-DxTa3PLB.mjs").then((n) => n.t);
166
- const { printAgentExportHelp } = await import("../agent-export-3VheegEK.mjs");
165
+ const { printAgentCompactHelp } = await import("../agent-D4hNGatV.mjs").then((n) => n.t);
166
+ const { printAgentExportHelp } = await import("../agent-export-CM-p9_YD.mjs");
167
167
  printAgentCompactHelp();
168
168
  printAgentExportHelp();
169
169
  process.exit(1);
170
170
  } else if (parsedCommand.command === "agents" && subcommand === "generate") {
171
- const { generateAgents, parseAgentsGenerateArgs, printAgentsGenerateHelp } = await import("../agents-ByTdP0Hl.mjs");
171
+ const { generateAgents, parseAgentsGenerateArgs, printAgentsGenerateHelp } = await import("../agents-BeLDNCnE.mjs");
172
172
  const agentsOptions = parseAgentsGenerateArgs(args.slice(2));
173
173
  if (agentsOptions.help) {
174
174
  printAgentsGenerateHelp();
@@ -178,11 +178,11 @@ async function main() {
178
178
  } else if (parsedCommand.command === "agents") {
179
179
  console.error(pc.red(`Unknown agents subcommand: ${subcommand ?? "(missing)"}`));
180
180
  console.error();
181
- const { printAgentsGenerateHelp } = await import("../agents-ByTdP0Hl.mjs");
181
+ const { printAgentsGenerateHelp } = await import("../agents-BeLDNCnE.mjs");
182
182
  printAgentsGenerateHelp();
183
183
  process.exit(1);
184
184
  } else if (parsedCommand.command === "doctor") {
185
- const { parseDoctorArgs, printDoctorHelp, runDoctor } = await import("../doctor-C34VVF85.mjs");
185
+ const { parseDoctorArgs, printDoctorHelp, runDoctor } = await import("../doctor-DhMVKHjp.mjs");
186
186
  const doctorOptions = parseDoctorArgs(args.slice(1));
187
187
  if (doctorOptions.help) {
188
188
  printDoctorHelp();
@@ -190,7 +190,7 @@ async function main() {
190
190
  }
191
191
  await runDoctor(doctorOptions);
192
192
  } else if (parsedCommand.command === "review") {
193
- const { parseReviewArgs, printReviewHelp, runReview } = await import("../review-Dw6oCQX3.mjs");
193
+ const { parseReviewArgs, printReviewHelp, runReview } = await import("../review-nxoV8jIm.mjs");
194
194
  const reviewOptions = parseReviewArgs(args.slice(1));
195
195
  if (reviewOptions.help) {
196
196
  printReviewHelp();
@@ -212,7 +212,7 @@ async function main() {
212
212
  printCodeBlocksValidateHelp();
213
213
  process.exit(1);
214
214
  } else if (parsedCommand.command === "search" && subcommand === "sync") {
215
- const { syncSearch } = await import("../search-DBdmbUkc.mjs");
215
+ const { syncSearch } = await import("../search-BTUIkhnT.mjs");
216
216
  await syncSearch(searchSyncOptions);
217
217
  } else if (parsedCommand.command === "search") {
218
218
  console.error(pc.red(`Unknown search subcommand: ${subcommand ?? "(missing)"}`));
@@ -220,7 +220,7 @@ async function main() {
220
220
  printHelp();
221
221
  process.exit(1);
222
222
  } else if (parsedCommand.command === "sitemap" && subcommand === "generate") {
223
- const { generateSitemap, parseSitemapGenerateArgs, printSitemapGenerateHelp } = await import("../sitemap-CrzG5Wpf.mjs");
223
+ const { generateSitemap, parseSitemapGenerateArgs, printSitemapGenerateHelp } = await import("../sitemap-e0_GeCWJ.mjs");
224
224
  const sitemapOptions = parseSitemapGenerateArgs(args.slice(2));
225
225
  if (sitemapOptions.help) {
226
226
  printSitemapGenerateHelp();
@@ -230,11 +230,11 @@ async function main() {
230
230
  } else if (parsedCommand.command === "sitemap") {
231
231
  console.error(pc.red(`Unknown sitemap subcommand: ${subcommand ?? "(missing)"}`));
232
232
  console.error();
233
- const { printSitemapGenerateHelp } = await import("../sitemap-CrzG5Wpf.mjs");
233
+ const { printSitemapGenerateHelp } = await import("../sitemap-e0_GeCWJ.mjs");
234
234
  printSitemapGenerateHelp();
235
235
  process.exit(1);
236
236
  } else if (parsedCommand.command === "robots" && subcommand === "generate") {
237
- const { generateRobots, parseRobotsGenerateArgs, printRobotsGenerateHelp } = await import("../robots-KWLujSLI.mjs");
237
+ const { generateRobots, parseRobotsGenerateArgs, printRobotsGenerateHelp } = await import("../robots-CiQT8mX2.mjs");
238
238
  const robotsOptions = parseRobotsGenerateArgs(args.slice(2));
239
239
  if (robotsOptions.help) {
240
240
  printRobotsGenerateHelp();
@@ -244,7 +244,7 @@ async function main() {
244
244
  } else if (parsedCommand.command === "robots") {
245
245
  console.error(pc.red(`Unknown robots subcommand: ${subcommand ?? "(missing)"}`));
246
246
  console.error();
247
- const { printRobotsGenerateHelp } = await import("../robots-KWLujSLI.mjs");
247
+ const { printRobotsGenerateHelp } = await import("../robots-CiQT8mX2.mjs");
248
248
  printRobotsGenerateHelp();
249
249
  process.exit(1);
250
250
  } else if (parsedCommand.command === "downgrade") {
@@ -1,4 +1,4 @@
1
- import { rt as DocsAnalyticsConfig } from "../types-BDRwrExu.mjs";
1
+ import { rt as DocsAnalyticsConfig } from "../types-B-5Kzmkn.mjs";
2
2
  import { ReactNode } from "react";
3
3
 
4
4
  //#region src/docs-cloud-client.d.ts
@@ -1,4 +1,4 @@
1
- import { _t as DocsCloudConfig, rt as DocsAnalyticsConfig, t as AIConfig } from "./types-BDRwrExu.mjs";
1
+ import { _t as DocsCloudConfig, rt as DocsAnalyticsConfig, t as AIConfig } from "./types-B-5Kzmkn.mjs";
2
2
 
3
3
  //#region src/cloud-ask-ai.d.ts
4
4
  interface DocsCloudAskAIConfig {
@@ -191,6 +191,7 @@ const managedConfigSchema = z.object({
191
191
  name: z.string().optional(),
192
192
  path: z.string(),
193
193
  route: z.string().optional(),
194
+ catalogTargets: z.array(z.string()).optional(),
194
195
  navigationLabel: z.string().optional()
195
196
  }).passthrough()).optional()
196
197
  }).passthrough().optional(),
@@ -240,11 +241,13 @@ function resolveManagedOpenApiSpec(projectRoot, openapi) {
240
241
  if (configured) {
241
242
  const rawPath = configured.path.trim();
242
243
  const route = normalizeManagedRoutePath(configured.route);
244
+ const catalogTargets = configured.catalogTargets === void 0 ? void 0 : Array.from(new Set(configured.catalogTargets.map((target) => target.trim()).filter(Boolean)));
243
245
  if (isRemoteManagedSpecPath(rawPath) || isRequestRelativeManagedSpecPath(rawPath)) return {
244
246
  name: configured.name?.trim() || "API Reference",
245
247
  route,
246
248
  path: rawPath,
247
249
  specUrl: rawPath,
250
+ catalogTargets,
248
251
  navigationLabel: configured.navigationLabel?.trim() || void 0
249
252
  };
250
253
  return {
@@ -252,6 +255,7 @@ function resolveManagedOpenApiSpec(projectRoot, openapi) {
252
255
  route,
253
256
  path: rawPath,
254
257
  specUrl: DEFAULT_MANAGED_OPENAPI_ENDPOINT,
258
+ catalogTargets,
255
259
  sourcePath: path.resolve(projectRoot, rawPath),
256
260
  navigationLabel: configured.navigationLabel?.trim() || void 0
257
261
  };
@@ -585,12 +589,13 @@ function renderEmptyHomePage() {
585
589
  `;
586
590
  }
587
591
  function renderDocsConfigFile(options) {
592
+ const catalogTargetsLine = options.apiReference?.catalogTargets === void 0 ? "" : ` catalogTargets: ${JSON.stringify(options.apiReference.catalogTargets)},\n`;
588
593
  const apiReferenceBlock = options.apiReference ? ` apiReference: {
589
594
  enabled: true,
590
595
  path: ${JSON.stringify(options.apiReference.path)},
591
596
  renderer: "fumadocs",
592
597
  specUrl: ${JSON.stringify(options.apiReference.specUrl)},
593
- },
598
+ ${catalogTargetsLine} },
594
599
  ` : "";
595
600
  const analyticsBlock = renderManagedAnalyticsBlock(options.analytics);
596
601
  return `import { defineDocs } from "@farming-labs/docs";
@@ -976,7 +981,8 @@ function materializeManagedRuntime(projectRoot) {
976
981
  analytics: project.analytics,
977
982
  apiReference: project.apiReferenceSpec ? {
978
983
  path: apiReferenceRoute,
979
- specUrl: project.apiReferenceSpec.specUrl
984
+ specUrl: project.apiReferenceSpec.specUrl,
985
+ catalogTargets: project.apiReferenceSpec.catalogTargets
980
986
  } : void 0
981
987
  }));
982
988
  if (!project.apiReferenceSpec) writeFileIfChanged(path.join(project.runtimeDir, "api-reference.config.ts"), renderDocsConfigFile({
@@ -1,5 +1,5 @@
1
- import { at as DocsAnalyticsEventInput, it as DocsAnalyticsEvent, rt as DocsAnalyticsConfig } from "./types-BDRwrExu.mjs";
2
- import { n as DocsCloudAskAIResponseOptions, t as DocsCloudAskAIConfig } from "./cloud-ask-ai-Bt0rzFbe.mjs";
1
+ import { at as DocsAnalyticsEventInput, it as DocsAnalyticsEvent, rt as DocsAnalyticsConfig } from "./types-B-5Kzmkn.mjs";
2
+ import { n as DocsCloudAskAIResponseOptions, t as DocsCloudAskAIConfig } from "./cloud-ask-ai-BCgHPxew.mjs";
3
3
 
4
4
  //#region src/docs-cloud-server.d.ts
5
5
  type DocsCloudRuntimeValue<T = string> = T | undefined | null | (() => T | undefined | null);
@@ -1,21 +1,21 @@
1
- import { i as scanDocsPageTargets, n as compactAgentDocs, r as inspectAgentCompactionState } from "./agent-DxTa3PLB.mjs";
2
- import { d as httpLinkHeaderHasTargetRelation, f as AGENT_SKILL_ARCHIVE_MAX_UNCOMPRESSED_BYTES, p as readAgentSkillDocumentFromTar } from "./prompt-references-CfyYOa_W.mjs";
3
- import { $t as getDocsMcpProtectedResourceMetadataRoutes, A as buildDocsAgentDiscoverySpec, F as buildDocsMcpEndpointCandidates, Ft as DEFAULT_SITEMAP_MD_WELL_KNOWN_ROUTE, Ht as resolveDocsSitemapConfig, It as DEFAULT_SITEMAP_XML_ROUTE, M as buildDocsConfigMap, Pt as DEFAULT_SITEMAP_MD_ROUTE, S as DEFAULT_SKILL_MD_WELL_KNOWN_ROUTE, T as DOCS_CONFIG_MAP_TOP_LEVEL_KEYS, Yt as DEFAULT_MCP_PUBLIC_ROUTE, Zt as DEFAULT_MCP_WELL_KNOWN_ROUTE, c as DEFAULT_AGENT_SPEC_WELL_KNOWN_JSON_ROUTE, h as DEFAULT_LLMS_FULL_TXT_ROUTE, i as DEFAULT_AGENT_FEEDBACK_ROUTE, l as DEFAULT_AGENT_SPEC_WELL_KNOWN_ROUTE, n as DEFAULT_AGENTS_MD_WELL_KNOWN_ROUTE, nn as isDocsMcpOAuthScopeToken, on as normalizeDocsMcpAuthorizationServerUrls, t as DEFAULT_AGENTS_MD_ROUTE, v as DEFAULT_LLMS_TXT_ROUTE, x as DEFAULT_SKILL_MD_ROUTE } from "./agent-BHqaZx-X.mjs";
1
+ import { i as scanDocsPageTargets, n as compactAgentDocs, r as inspectAgentCompactionState } from "./agent-D4hNGatV.mjs";
2
+ import { d as httpLinkHeaderHasTargetRelation, f as AGENT_SKILL_ARCHIVE_MAX_UNCOMPRESSED_BYTES, p as readAgentSkillDocumentFromTar } from "./prompt-references-B6L3AD98.mjs";
3
+ import { $t as getDocsMcpProtectedResourceMetadataRoutes, A as buildDocsAgentDiscoverySpec, F as buildDocsMcpEndpointCandidates, Ft as DEFAULT_SITEMAP_MD_WELL_KNOWN_ROUTE, Ht as resolveDocsSitemapConfig, It as DEFAULT_SITEMAP_XML_ROUTE, M as buildDocsConfigMap, Pt as DEFAULT_SITEMAP_MD_ROUTE, S as DEFAULT_SKILL_MD_WELL_KNOWN_ROUTE, T as DOCS_CONFIG_MAP_TOP_LEVEL_KEYS, Yt as DEFAULT_MCP_PUBLIC_ROUTE, Zt as DEFAULT_MCP_WELL_KNOWN_ROUTE, c as DEFAULT_AGENT_SPEC_WELL_KNOWN_JSON_ROUTE, h as DEFAULT_LLMS_FULL_TXT_ROUTE, i as DEFAULT_AGENT_FEEDBACK_ROUTE, l as DEFAULT_AGENT_SPEC_WELL_KNOWN_ROUTE, n as DEFAULT_AGENTS_MD_WELL_KNOWN_ROUTE, nn as isDocsMcpOAuthScopeToken, on as normalizeDocsMcpAuthorizationServerUrls, t as DEFAULT_AGENTS_MD_ROUTE, v as DEFAULT_LLMS_TXT_ROUTE, x as DEFAULT_SKILL_MD_ROUTE } from "./agent-SRIJ-oF8.mjs";
4
4
  import { f as PAGE_AGENT_CONTRACT_FIELDS } from "./markdown-sections-7OoA7ylx.mjs";
5
5
  import { isDocsAgentSkillName, validateDocsAgentSkillFrontmatter } from "./agent-skills-spec.mjs";
6
- import { I as resolveDocsDiscoveryApiRoute, _ as DEFAULT_API_CATALOG_FORMAT, d as DEFAULT_AGENT_SKILLS_ROUTE_PATTERN, f as DEFAULT_AGENT_SKILLS_ROUTE_PREFIX, h as DEFAULT_AGENT_SKILL_FORMAT, l as DEFAULT_AGENT_SKILLS_INDEX_FORMAT, n as API_CATALOG_MEDIA_TYPE, r as API_CATALOG_PROFILE_URI, t as AGENT_SKILLS_DISCOVERY_SCHEMA_URI, u as DEFAULT_AGENT_SKILLS_INDEX_ROUTE, v as DEFAULT_API_CATALOG_ROUTE } from "./standards-discovery-BwL5ffGx.mjs";
7
- import { h as resolveAskAISearchRequestConfig } from "./search-BmC8wVr0.mjs";
8
- import { a as analyzeDocsRobotsTxt, n as DEFAULT_ROBOTS_TXT_ROUTE, u as resolveDocsRobotsConfig } from "./robots-DaYBoy_A.mjs";
6
+ import { I as resolveDocsDiscoveryApiRoute, _ as DEFAULT_API_CATALOG_FORMAT, d as DEFAULT_AGENT_SKILLS_ROUTE_PATTERN, f as DEFAULT_AGENT_SKILLS_ROUTE_PREFIX, h as DEFAULT_AGENT_SKILL_FORMAT, l as DEFAULT_AGENT_SKILLS_INDEX_FORMAT, n as API_CATALOG_MEDIA_TYPE, r as API_CATALOG_PROFILE_URI, t as AGENT_SKILLS_DISCOVERY_SCHEMA_URI, u as DEFAULT_AGENT_SKILLS_INDEX_ROUTE, v as DEFAULT_API_CATALOG_ROUTE } from "./standards-discovery-BKlEnK_H.mjs";
7
+ import { g as resolveAskAISearchRequestConfig } from "./search-Da2AKaFJ.mjs";
8
+ import { a as analyzeDocsRobotsTxt, n as DEFAULT_ROBOTS_TXT_ROUTE, u as resolveDocsRobotsConfig } from "./robots-CgH6Stqn.mjs";
9
9
  import { a as resolveDocsMetadataBaseUrl } from "./metadata-N252j5_a.mjs";
10
- import "./sitemap-server-B9LZQ1FE.mjs";
11
- import { t as runDocsGoldenTasks } from "./agent-evals-21LZ_uEl.mjs";
10
+ import "./sitemap-server-DHaxyPAd.mjs";
11
+ import { t as runDocsGoldenTasks } from "./agent-evals-DmFoKy_y.mjs";
12
12
  import { createFilesystemDocsMcpSource, getDocsConfigSchema, resolveDocsMcpConfig } from "./mcp.mjs";
13
13
  import "./code-blocks-DnNVNK2M.mjs";
14
- import { t as resolveConfiguredAgentSkills } from "./agent-skills-server-noFn1l_p.mjs";
14
+ import { t as resolveConfiguredAgentSkills } from "./agent-skills-server-B2EXn2QD.mjs";
15
15
  import "./server.mjs";
16
16
  import { _ as resolveDocsContentDir, d as readNavTitle, g as resolveDocsConfigPath, h as readTopLevelStringProperty, l as readBooleanProperty, r as extractTopLevelConfigObject, s as loadDocsConfigModuleResultWithProjectEnv, t as extractNestedObjectLiteral } from "./config-Wcdj-D0a.mjs";
17
17
  import { t as detectFramework } from "./utils-DpiIioYb.mjs";
18
- import { i as createAgentUsefulnessPagesFromMcp, n as analyzeAgentSurfaceDrift, r as analyzeAgentUsefulness, t as resolveGoldenEvaluationInput } from "./golden-evaluations-D_oDJwGv.mjs";
18
+ import { i as createAgentUsefulnessPagesFromMcp, n as analyzeAgentSurfaceDrift, r as analyzeAgentUsefulness, t as resolveGoldenEvaluationInput } from "./golden-evaluations-VzE6juQl.mjs";
19
19
  import { existsSync, lstatSync, readFileSync, readdirSync } from "node:fs";
20
20
  import path from "node:path";
21
21
  import { LATEST_PROTOCOL_VERSION } from "@modelcontextprotocol/sdk/types.js";
@@ -1029,18 +1029,52 @@ async function probeMcpRoute(baseUrl, route, expectedTools) {
1029
1029
  detail: `${route} initialize returned HTTP ${initializeResponse.status}: ${String(initializePayload.error?.message ?? "unknown MCP error")}.`
1030
1030
  };
1031
1031
  const sessionId = initializeResponse.headers.get("mcp-session-id") ?? void 0;
1032
- if (sessionId) await postMcpJson(baseUrl, route, {
1032
+ await postMcpJson(baseUrl, route, {
1033
1033
  jsonrpc: "2.0",
1034
1034
  method: "notifications/initialized",
1035
1035
  params: {}
1036
1036
  }, sessionId).catch(() => void 0);
1037
- const toolsResponse = await postMcpJson(baseUrl, route, {
1038
- jsonrpc: "2.0",
1039
- id: "doctor-tools-list",
1040
- method: "tools/list",
1041
- params: {}
1042
- }, sessionId);
1043
- const toolsPayload = await parseMcpResponse(toolsResponse);
1037
+ const toolNames = /* @__PURE__ */ new Set();
1038
+ const seenCursors = /* @__PURE__ */ new Set();
1039
+ let cursor;
1040
+ let toolsListError;
1041
+ let completedToolsList = false;
1042
+ for (let page = 0; page < 20; page += 1) {
1043
+ const toolsResponse = await postMcpJson(baseUrl, route, {
1044
+ jsonrpc: "2.0",
1045
+ id: `doctor-tools-list-${page + 1}`,
1046
+ method: "tools/list",
1047
+ params: cursor !== void 0 ? { cursor } : {}
1048
+ }, sessionId);
1049
+ const toolsPayload = await parseMcpResponse(toolsResponse);
1050
+ if (!toolsResponse.ok || toolsPayload.error) {
1051
+ toolsListError = {
1052
+ status: toolsResponse.status,
1053
+ message: String(toolsPayload.error?.message ?? "unknown MCP error")
1054
+ };
1055
+ break;
1056
+ }
1057
+ const result = toolsPayload.result;
1058
+ for (const tool of result?.tools ?? []) if (typeof tool.name === "string") toolNames.add(tool.name);
1059
+ const nextCursor = result?.nextCursor;
1060
+ if (nextCursor === void 0) {
1061
+ completedToolsList = true;
1062
+ break;
1063
+ }
1064
+ if (typeof nextCursor !== "string" || seenCursors.has(nextCursor)) {
1065
+ toolsListError = {
1066
+ status: toolsResponse.status,
1067
+ message: "server returned an invalid or repeated pagination cursor"
1068
+ };
1069
+ break;
1070
+ }
1071
+ seenCursors.add(nextCursor);
1072
+ cursor = nextCursor;
1073
+ }
1074
+ if (!completedToolsList && !toolsListError) toolsListError = {
1075
+ status: 200,
1076
+ message: "server exceeded the 20-page tools/list safety limit"
1077
+ };
1044
1078
  if (sessionId) await fetchWithTimeout(joinDoctorUrl(baseUrl, route), {
1045
1079
  method: "DELETE",
1046
1080
  headers: {
@@ -1048,20 +1082,18 @@ async function probeMcpRoute(baseUrl, route, expectedTools) {
1048
1082
  "mcp-session-id": sessionId
1049
1083
  }
1050
1084
  }).catch(() => void 0);
1051
- if (!toolsResponse.ok || toolsPayload.error) return {
1085
+ if (toolsListError) return {
1052
1086
  ok: false,
1053
- detail: `${route} tools/list returned HTTP ${toolsResponse.status}: ${String(toolsPayload.error?.message ?? "unknown MCP error")}.`
1087
+ detail: `${route} tools/list returned HTTP ${toolsListError.status}: ${toolsListError.message}.`
1054
1088
  };
1055
- const tools = toolsPayload.result?.tools;
1056
- const toolNames = Array.isArray(tools) ? tools.map((tool) => tool.name).filter((name) => typeof name === "string") : [];
1057
- const missingTools = expectedTools.filter((tool) => !toolNames.includes(tool));
1089
+ const missingTools = expectedTools.filter((tool) => !toolNames.has(tool));
1058
1090
  if (missingTools.length > 0) return {
1059
1091
  ok: false,
1060
1092
  detail: `${route} connected but is missing tools: ${missingTools.join(", ")}.`
1061
1093
  };
1062
1094
  return {
1063
1095
  ok: true,
1064
- detail: `${route} initialized ${sessionId ? "with a session" : "statelessly"} and exposed ${toolNames.length} MCP tool${toolNames.length === 1 ? "" : "s"}.`
1096
+ detail: `${route} initialized ${sessionId ? "with a session" : "statelessly"} and exposed ${toolNames.size} MCP tool${toolNames.size === 1 ? "" : "s"}.`
1065
1097
  };
1066
1098
  } catch (error) {
1067
1099
  return {
@@ -1,6 +1,6 @@
1
- import { Ot as findDocsAudienceMdxTags, jt as resolveDocsAudienceMdxContent } from "./agent-BHqaZx-X.mjs";
1
+ import { Ot as findDocsAudienceMdxTags, jt as resolveDocsAudienceMdxContent } from "./agent-SRIJ-oF8.mjs";
2
2
  import { _ as hasStructuredPageAgentContract, v as normalizePageAgentFrontmatter } from "./markdown-sections-7OoA7ylx.mjs";
3
- import { C as agentVersionConstraintsOverlap, D as normalizeAgentVersion, w as normalizeAgentFramework } from "./search-BmC8wVr0.mjs";
3
+ import { E as normalizeAgentFramework, T as agentVersionConstraintsOverlap, k as normalizeAgentVersion } from "./search-Da2AKaFJ.mjs";
4
4
  import { t as extractCodeBlocksFromMarkdown } from "./code-blocks-DnNVNK2M.mjs";
5
5
  import { existsSync, lstatSync, readFileSync, readdirSync } from "node:fs";
6
6
  import path from "node:path";
@@ -1700,7 +1700,11 @@ function analyzeAgentSurfaceDrift(options) {
1700
1700
  "package",
1701
1701
  "tags"
1702
1702
  ]],
1703
- ["search.warningsField", "warnings"]
1703
+ ["search.warningsField", "warnings"],
1704
+ ["search.cursorParam", "cursor"],
1705
+ ["search.nextCursorField", "nextCursor"],
1706
+ ["search.hasMoreField", "hasMore"],
1707
+ ["search.totalField", "total"]
1704
1708
  ]) compareExpectedValue(issues, options.discovery, "search-scope-mismatch", path, expected, `Discovery ${path}`);
1705
1709
  compareExpectedValue(issues, options.discovery, "mcp-enabled-mismatch", "mcp.enabled", options.expected.mcp.enabled, "Discovery mcp.enabled");
1706
1710
  compareExpectedValue(issues, options.discovery, "mcp-capability-mismatch", "capabilities.mcp", options.expected.mcp.enabled, "Discovery capabilities.mcp");