@farm.js/core 0.1.35 → 0.1.37
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.
- package/dist/{metadata-BnLDsUOS.d.ts → agent-mcp-BC0bAGVF.d.mts} +45 -2
- package/dist/agent-mcp-handler-LPJ2CADR.mjs +19 -0
- package/dist/agent-mcp-handler-SJAHFSPI.cjs +19 -0
- package/dist/{metadata-WGpBYcGn.d.mts → agent-mcp-jyDHbQKe.d.ts} +45 -2
- package/dist/agent-runtime.cjs +6 -4
- package/dist/agent-runtime.d.mts +1 -1
- package/dist/agent-runtime.d.ts +1 -1
- package/dist/agent-runtime.mjs +5 -3
- package/dist/api/client.cjs +3 -3
- package/dist/api/client.mjs +2 -2
- package/dist/api/route-manager.cjs +9 -9
- package/dist/api/route-manager.d.mts +10 -4
- package/dist/api/route-manager.d.ts +10 -4
- package/dist/api/route-manager.mjs +8 -8
- package/dist/api/runtime.cjs +6 -6
- package/dist/api/runtime.d.mts +4 -62
- package/dist/api/runtime.d.ts +4 -62
- package/dist/api/runtime.mjs +5 -5
- package/dist/api.cjs +13 -12
- package/dist/api.d.mts +3 -3
- package/dist/api.d.ts +3 -3
- package/dist/api.mjs +12 -11
- package/dist/{app-BXB3JZYc.d.ts → app-CKO3iN1c.d.ts} +17 -3
- package/dist/{app-D_j9AAVL.d.mts → app-Cbkj9ufe.d.mts} +17 -3
- package/dist/app-markdown.cjs +6 -4
- package/dist/app-markdown.d.mts +3 -3
- package/dist/app-markdown.d.ts +3 -3
- package/dist/app-markdown.mjs +5 -3
- package/dist/{chunk-F7JZENPF.cjs → chunk-3A4KGQYI.cjs} +38 -30
- package/dist/{chunk-4MMGO7YW.cjs → chunk-3IP27TCG.cjs} +43 -32
- package/dist/{chunk-FDR64H6B.mjs → chunk-3KGDJLJK.mjs} +41 -2
- package/dist/{chunk-UJD4PHYB.mjs → chunk-4E5WBPEG.mjs} +72 -354
- package/dist/{chunk-KXWRO25S.cjs → chunk-4GPOC4LN.cjs} +3 -3
- package/dist/{chunk-Z2HLU4IX.cjs → chunk-4GWRFP22.cjs} +23 -2
- package/dist/{chunk-4KU5Q7C2.mjs → chunk-4P6ULFMD.mjs} +253 -67
- package/dist/chunk-4WQ6PGSJ.cjs +367 -0
- package/dist/{chunk-SMHH4VDG.mjs → chunk-4WVJLURN.mjs} +1 -1
- package/dist/{chunk-2F2ER724.cjs → chunk-5BXGGEC7.cjs} +27 -22
- package/dist/{chunk-3BHT4WMP.cjs → chunk-5D2JIPLH.cjs} +8 -8
- package/dist/{chunk-AHGECQEW.mjs → chunk-666CKENS.mjs} +1 -1
- package/dist/{chunk-GFHLGIYC.cjs → chunk-6LGFV2CQ.cjs} +8 -8
- package/dist/chunk-6SJ2KJTA.mjs +314 -0
- package/dist/{chunk-PFQKNERH.cjs → chunk-6TJITR2B.cjs} +457 -218
- package/dist/{chunk-73MC7ZL6.cjs → chunk-75X755YZ.cjs} +2 -2
- package/dist/{chunk-3UH7MRCP.cjs → chunk-7DWNJI73.cjs} +13 -13
- package/dist/{chunk-7L5V3KQO.cjs → chunk-7O5M4UKW.cjs} +2 -2
- package/dist/{chunk-BJPBQNIE.cjs → chunk-7SQ5SGYZ.cjs} +2 -2
- package/dist/{chunk-27ZWSI3W.cjs → chunk-ADOAUDQ6.cjs} +2 -2
- package/dist/{chunk-CP6X4AEU.mjs → chunk-AJQTP4OO.mjs} +1 -1
- package/dist/{chunk-YKX5BK66.cjs → chunk-ATWHHSY2.cjs} +7 -7
- package/dist/{chunk-EFCQPQMG.cjs → chunk-B5PFZLKV.cjs} +89 -8
- package/dist/{chunk-FNO7A7CM.cjs → chunk-BHY547NB.cjs} +34 -16
- package/dist/{chunk-JHWOVJ3M.mjs → chunk-BUGNQIHC.mjs} +5 -0
- package/dist/{chunk-7GLPRTTF.cjs → chunk-CGBDNNSM.cjs} +2 -2
- package/dist/chunk-CI6E3UOH.cjs +314 -0
- package/dist/{chunk-2G2NNLE2.mjs → chunk-CQMVIOYP.mjs} +5 -5
- package/dist/{chunk-X6W5FFH6.cjs → chunk-CVH2BXPY.cjs} +8 -8
- package/dist/{chunk-TKSCR644.cjs → chunk-D3C5LBQY.cjs} +2 -2
- package/dist/{chunk-PZNL3WEG.mjs → chunk-DMEPTZTI.mjs} +22 -11
- package/dist/chunk-DTSROJ5J.mjs +367 -0
- package/dist/{chunk-DBNKI4NF.cjs → chunk-ECKF2BAM.cjs} +6 -2
- package/dist/{chunk-GQ3Z3IZI.cjs → chunk-EMMQ64QW.cjs} +18 -18
- package/dist/{chunk-6DU6UFUE.mjs → chunk-EXG5LD6B.mjs} +16 -8
- package/dist/{chunk-HUMR6LSU.mjs → chunk-F5QO4FNE.mjs} +1 -1
- package/dist/{chunk-YULD7ICZ.mjs → chunk-FBOJ55OM.mjs} +1 -1
- package/dist/{chunk-IHNMMXHV.mjs → chunk-FGRYBX5X.mjs} +15 -10
- package/dist/{chunk-D227TIEN.cjs → chunk-FWE7LEQC.cjs} +13 -13
- package/dist/{chunk-3BU22U3M.cjs → chunk-G2TEB74S.cjs} +5 -2
- package/dist/{chunk-G5RT7EXW.mjs → chunk-HEVMCTSR.mjs} +21 -6
- package/dist/{chunk-W7LF2J2S.mjs → chunk-HMRSWN47.mjs} +1 -1
- package/dist/{chunk-JG6DJF5A.mjs → chunk-HZFM2LWQ.mjs} +22 -1
- package/dist/{chunk-UAORZ7QA.mjs → chunk-IAIYV4RZ.mjs} +2 -2
- package/dist/{chunk-F2SE2VDO.mjs → chunk-IHQIOZLC.mjs} +1 -1
- package/dist/{chunk-2NNMOPDN.mjs → chunk-J3ANCZKA.mjs} +4 -1
- package/dist/{chunk-C4SPBWFM.cjs → chunk-JEZO6VUR.cjs} +10 -1
- package/dist/{chunk-SC2WYWPF.mjs → chunk-JPNFPAZ4.mjs} +3 -3
- package/dist/{chunk-F6Z3Y5KL.mjs → chunk-K3SAEIM3.mjs} +5 -2
- package/dist/{chunk-QAU5JD57.mjs → chunk-K4I4O5TS.mjs} +289 -50
- package/dist/{chunk-KN7K4VQN.mjs → chunk-KDTBF3UU.mjs} +1 -1
- package/dist/{chunk-OMVAU7NT.cjs → chunk-KIIMAWOJ.cjs} +11 -1
- package/dist/{chunk-43FMW62B.mjs → chunk-KMTGADN3.mjs} +28 -0
- package/dist/{chunk-QORUJDIV.mjs → chunk-KPFKMDM7.mjs} +2 -2
- package/dist/{chunk-YSCV4SJF.cjs → chunk-L5H2GSUC.cjs} +4 -4
- package/dist/{chunk-YDQZGSDS.mjs → chunk-LBDP3YT3.mjs} +1 -1
- package/dist/{chunk-6ETPZTJI.mjs → chunk-LBGILORX.mjs} +116 -55
- package/dist/{chunk-IPXLADVO.cjs → chunk-LOFKRKO7.cjs} +122 -61
- package/dist/{chunk-ULAWS2PA.cjs → chunk-LPFV45AY.cjs} +29 -26
- package/dist/{chunk-3KZS4SUS.mjs → chunk-MCIZVNOQ.mjs} +1 -1
- package/dist/{chunk-RU3M2FIK.cjs → chunk-MRMI32SN.cjs} +87 -369
- package/dist/{chunk-XCMCS4DA.mjs → chunk-ND2CWPOD.mjs} +2 -2
- package/dist/{chunk-XCACDAZZ.cjs → chunk-NDILNQ4L.cjs} +25 -10
- package/dist/{chunk-6TJOML4E.mjs → chunk-NFMDCAOS.mjs} +14 -11
- package/dist/{chunk-UXFQ3UDA.cjs → chunk-NICDYKBS.cjs} +42 -3
- package/dist/{chunk-EZDQRNQ7.mjs → chunk-NNSAQX3U.mjs} +23 -5
- package/dist/{chunk-YC6V7PWE.cjs → chunk-NQ6QFZWD.cjs} +1 -1
- package/dist/{chunk-PDOCJ6RY.mjs → chunk-O6WAEAX3.mjs} +1 -1
- package/dist/{chunk-U4KT7QP3.cjs → chunk-OW67PDDS.cjs} +14 -1
- package/dist/{chunk-77GNHH2Z.cjs → chunk-PMQHMWZU.cjs} +3 -3
- package/dist/chunk-PTZ2TVNE.cjs +178 -0
- package/dist/{chunk-6WCPV6G2.mjs → chunk-Q2KB32T4.mjs} +1 -1
- package/dist/{chunk-ICUQICNC.cjs → chunk-Q5FYSK45.cjs} +718 -532
- package/dist/{chunk-5SJWVY6R.mjs → chunk-QHSH7IH4.mjs} +9 -0
- package/dist/{chunk-Q3VLETLE.mjs → chunk-RRMVL6CJ.mjs} +4 -4
- package/dist/{chunk-IZY3V5XW.mjs → chunk-S3VWVTVA.mjs} +14 -1
- package/dist/{chunk-FFFW3OQ7.cjs → chunk-S6FJO323.cjs} +2 -2
- package/dist/{chunk-VFQT3LAO.cjs → chunk-SDOTRX3V.cjs} +5 -5
- package/dist/chunk-SGBZPZUW.mjs +75 -0
- package/dist/{chunk-BMWDEBXO.cjs → chunk-SHLXACIO.cjs} +31 -3
- package/dist/{chunk-ZXGAFZDO.cjs → chunk-T5OJPTVN.cjs} +2 -2
- package/dist/{chunk-2ELDTQRN.mjs → chunk-TDNWPAVR.mjs} +1 -1
- package/dist/{chunk-VZJR7UTG.cjs → chunk-TE2G5ION.cjs} +2 -2
- package/dist/{chunk-IHNIDL6H.cjs → chunk-TO4GJ56K.cjs} +22 -11
- package/dist/{chunk-4JHOT46A.mjs → chunk-TPLJVC7E.mjs} +86 -5
- package/dist/{chunk-NRSN7G7E.mjs → chunk-TW4GYDBJ.mjs} +1 -1
- package/dist/{chunk-XBML5KMG.cjs → chunk-U6MPZ35Q.cjs} +24 -14
- package/dist/chunk-UH6QN5NL.mjs +178 -0
- package/dist/{chunk-FTFYRMQQ.cjs → chunk-UJZLSXUB.cjs} +53 -28
- package/dist/chunk-UXHS27O6.cjs +75 -0
- package/dist/{chunk-DQQOKWYA.cjs → chunk-VR4GD5I3.cjs} +3 -3
- package/dist/{chunk-22LTEMGQ.mjs → chunk-VXAWRDK7.mjs} +14 -4
- package/dist/{chunk-62XKI4Z3.cjs → chunk-W2YDNK66.cjs} +6 -3
- package/dist/{chunk-VPTDD5XF.cjs → chunk-WBKEZXWE.cjs} +5 -0
- package/dist/{chunk-EJQT6KZN.cjs → chunk-WC5UV2HQ.cjs} +2 -2
- package/dist/{chunk-SAZVVAJH.mjs → chunk-WQ7T2263.mjs} +18 -7
- package/dist/chunk-WRPHYQVY.mjs +109 -0
- package/dist/chunk-WT4TGLXT.cjs +109 -0
- package/dist/{chunk-SOMHP6GF.mjs → chunk-XOPOIFTJ.mjs} +2 -2
- package/dist/{chunk-3PXS2MHU.mjs → chunk-YCKO6FRS.mjs} +1 -1
- package/dist/{chunk-C35ZBVRD.mjs → chunk-YWMZUGIS.mjs} +6 -2
- package/dist/{chunk-HMIJDL7S.mjs → chunk-Z5BEWYVO.mjs} +31 -6
- package/dist/{chunk-OKZUAXHF.mjs → chunk-Z7LA7MHQ.mjs} +1 -1
- package/dist/{chunk-Y7RKTKYI.mjs → chunk-ZMMBIVQM.mjs} +10 -0
- package/dist/{client-plugins-HIyulDym.d.ts → client-plugins-C8DjftDF.d.ts} +112 -5
- package/dist/{client-plugins-CvIslxWi.d.mts → client-plugins-CV4eJ9De.d.mts} +112 -5
- package/dist/client-plugins.d.mts +1 -1
- package/dist/client-plugins.d.ts +1 -1
- package/dist/client.cjs +8 -8
- package/dist/client.d.mts +5 -5
- package/dist/client.d.ts +5 -5
- package/dist/client.mjs +7 -7
- package/dist/config.d.mts +1 -1
- package/dist/config.d.ts +1 -1
- package/dist/{devtools-EAUY43BS.cjs → devtools-JXFQNWSH.cjs} +11 -10
- package/dist/{devtools-EE5RIBTH.mjs → devtools-KVOY2TCZ.mjs} +10 -9
- package/dist/docs.cjs +13 -12
- package/dist/docs.d.mts +2 -2
- package/dist/docs.d.ts +2 -2
- package/dist/docs.mjs +12 -11
- package/dist/headers.cjs +4 -4
- package/dist/headers.mjs +3 -3
- package/dist/i18n/client.cjs +11 -11
- package/dist/i18n/client.mjs +3 -3
- package/dist/image/server.cjs +3 -3
- package/dist/image/server.mjs +2 -2
- package/dist/image/sharp.cjs +10 -10
- package/dist/image/sharp.mjs +2 -2
- package/dist/index.cjs +61 -54
- package/dist/index.d.mts +14 -14
- package/dist/index.d.ts +14 -14
- package/dist/index.mjs +60 -53
- package/dist/integrations.cjs +8 -4
- package/dist/integrations.d.mts +1 -1
- package/dist/integrations.d.ts +1 -1
- package/dist/integrations.mjs +7 -3
- package/dist/internal/app-markdown-runtime.cjs +5 -3
- package/dist/internal/app-markdown-runtime.d.mts +19 -5
- package/dist/internal/app-markdown-runtime.d.ts +19 -5
- package/dist/internal/app-markdown-runtime.mjs +4 -2
- package/dist/internal/build-runtime.cjs +38 -34
- package/dist/internal/build-runtime.d.mts +3 -3
- package/dist/internal/build-runtime.d.ts +3 -3
- package/dist/internal/build-runtime.mjs +37 -33
- package/dist/internal/cli-runtime.cjs +17 -16
- package/dist/internal/cli-runtime.mjs +16 -15
- package/dist/internal/client-error-overlay.cjs +4 -4
- package/dist/internal/client-error-overlay.mjs +1 -1
- package/dist/internal/client-runtime.cjs +2 -2
- package/dist/internal/client-runtime.mjs +1 -1
- package/dist/internal/compression-runtime.d.mts +1 -1
- package/dist/internal/compression-runtime.d.ts +1 -1
- package/dist/internal/config-runtime.cjs +11 -10
- package/dist/internal/config-runtime.d.mts +2 -2
- package/dist/internal/config-runtime.d.ts +2 -2
- package/dist/internal/config-runtime.mjs +10 -9
- package/dist/internal/infra-analytics-runtime.cjs +5 -5
- package/dist/internal/infra-analytics-runtime.mjs +3 -3
- package/dist/internal/isolated-boundary.cjs +2 -2
- package/dist/internal/isolated-boundary.d.mts +0 -1
- package/dist/internal/isolated-boundary.d.ts +0 -1
- package/dist/internal/isolated-boundary.mjs +1 -1
- package/dist/internal/metadata-image-runtime.cjs +3 -3
- package/dist/internal/metadata-image-runtime.mjs +2 -2
- package/dist/internal/product-telemetry-runtime.cjs +2 -2
- package/dist/internal/product-telemetry-runtime.mjs +1 -1
- package/dist/internal/production-runtime.cjs +27 -48
- package/dist/internal/production-runtime.d.mts +67 -27
- package/dist/internal/production-runtime.d.ts +67 -27
- package/dist/internal/production-runtime.mjs +34 -55
- package/dist/{layers-BRQF5ETU.mjs → layers-UTB43B7A.mjs} +1 -1
- package/dist/layers-VUWIOFEO.cjs +18 -0
- package/dist/markdown.cjs +1 -1
- package/dist/markdown.d.mts +1 -1
- package/dist/markdown.d.ts +1 -1
- package/dist/markdown.mjs +1 -1
- package/dist/middleware.cjs +10 -10
- package/dist/middleware.d.mts +6 -4
- package/dist/middleware.d.ts +6 -4
- package/dist/middleware.mjs +9 -9
- package/dist/navigation.cjs +7 -7
- package/dist/navigation.d.mts +4 -4
- package/dist/navigation.d.ts +4 -4
- package/dist/navigation.mjs +6 -6
- package/dist/{nitro-OVPLKPE2.cjs → nitro-7F65EZZS.cjs} +3 -3
- package/dist/{nitro-MXRDCXWZ.mjs → nitro-MPZJGPXK.mjs} +2 -2
- package/dist/plugin.cjs +31 -28
- package/dist/plugin.d.mts +1 -1
- package/dist/plugin.d.ts +1 -1
- package/dist/plugin.mjs +30 -27
- package/dist/{production-runtime-Crq6CJ-2.d.ts → production-runtime-C2kkrPVZ.d.ts} +1 -1
- package/dist/{production-runtime-0sRnuYc-.d.mts → production-runtime-Du_FHb2-.d.mts} +1 -1
- package/dist/query/client.cjs +9 -9
- package/dist/query/client.mjs +4 -4
- package/dist/{render-plan-8ozZh2Qv.d.ts → render-plan-BnnPTpus.d.ts} +1 -1
- package/dist/{render-plan-gs9GGPzw.d.mts → render-plan-Cgx7v8tJ.d.mts} +1 -1
- package/dist/renderer/react/server.cjs +3 -3
- package/dist/renderer/react/server.mjs +1 -1
- package/dist/renderer-client.cjs +12 -12
- package/dist/renderer-client.d.mts +3 -3
- package/dist/renderer-client.d.ts +3 -3
- package/dist/renderer-client.mjs +4 -4
- package/dist/{request-B5G8rLBH.d.ts → request-BNWr7r5e.d.ts} +1 -1
- package/dist/{request-fkhiynXe.d.mts → request-sKayKcop.d.mts} +1 -1
- package/dist/request.cjs +3 -3
- package/dist/request.d.mts +2 -2
- package/dist/request.d.ts +2 -2
- package/dist/request.mjs +2 -2
- package/dist/{route-rendering-lS5nUMua.d.ts → route-rendering-Bx4Auw6Q.d.ts} +1 -1
- package/dist/{route-rendering-CLnS7AZj.d.mts → route-rendering-DWFp3Yq4.d.mts} +1 -1
- package/dist/{router-ifU8Dui1.d.mts → router-BK6K42Ij.d.mts} +1 -1
- package/dist/{router-4iuiYnOW.d.ts → router-DnW_2tQi.d.ts} +1 -1
- package/dist/routes.cjs +2 -2
- package/dist/routes.d.mts +1 -1
- package/dist/routes.d.ts +1 -1
- package/dist/routes.mjs +1 -1
- package/dist/runtime-CA3Ei5k_.d.ts +69 -0
- package/dist/runtime-DJDaCMd_.d.mts +69 -0
- package/dist/server-action-security.cjs +3 -3
- package/dist/server-action-security.mjs +2 -2
- package/dist/server-fn.cjs +5 -5
- package/dist/server-fn.mjs +4 -4
- package/dist/server-plugins.cjs +5 -5
- package/dist/server-plugins.d.mts +2 -2
- package/dist/server-plugins.d.ts +2 -2
- package/dist/server-plugins.mjs +4 -4
- package/dist/server-query.cjs +6 -6
- package/dist/server-query.mjs +5 -5
- package/dist/server.cjs +57 -54
- package/dist/server.d.mts +7 -7
- package/dist/server.d.ts +7 -7
- package/dist/server.mjs +35 -32
- package/dist/{spa-router-Bq7VCOwx.d.mts → spa-router-D6fUA4Rn.d.mts} +2 -2
- package/dist/{spa-router-DaJk5Re4.d.ts → spa-router-Mwbd7g2L.d.ts} +2 -2
- package/dist/testing.cjs +13 -13
- package/dist/testing.d.mts +1 -1
- package/dist/testing.d.ts +1 -1
- package/dist/testing.mjs +10 -10
- package/dist/theme/server.cjs +4 -4
- package/dist/theme/server.mjs +3 -3
- package/dist/{utils-BXLmFsVR.d.ts → utils-BwVcAfUR.d.ts} +1 -1
- package/dist/{utils-XJn0c9bj.d.mts → utils-p9Hs-jCc.d.mts} +1 -1
- package/dist/version.cjs +2 -2
- package/dist/version.mjs +1 -1
- package/dist/vite.cjs +31 -28
- package/dist/vite.d.mts +1 -1
- package/dist/vite.d.ts +1 -1
- package/dist/vite.mjs +30 -27
- package/dist/workflows.cjs +3 -3
- package/dist/workflows.mjs +2 -2
- package/package.json +1 -1
- package/types/middleware.d.ts +5 -1
- package/dist/chunk-FXEF4PPL.mjs +0 -47
- package/dist/chunk-XD32KALF.cjs +0 -47
- package/dist/layers-4PNE2HOY.cjs +0 -18
- /package/dist/{chunk-SJNMVDDF.cjs → chunk-FUCSUGDM.cjs} +0 -0
- /package/dist/{chunk-UDNPLXW7.mjs → chunk-MYIZXDZA.mjs} +0 -0
|
@@ -1,23 +1,24 @@
|
|
|
1
1
|
export { _runWithAfterRequest } from '../after.mjs';
|
|
2
|
-
import {
|
|
3
|
-
export {
|
|
4
|
-
export { m as mergeRouteRenderingDirectiveConfig } from '../route-rendering-
|
|
2
|
+
import { aJ as FarmMCPCatalogDetails, fN as APIRequestRuntime, bT as ResolvedFarmMCPConfig, aE as FarmMCPServerRegistration, fO as FarmLlmsTxtLink, I as FarmConfig, _ as FarmContextFactoryInput } from '../client-plugins-CV4eJ9De.mjs';
|
|
3
|
+
export { fY as FarmLlmsTxtUserConfig, fZ as ResolvedFarmLlmsTxtConfig, g2 as applyFarmCspNonceToResponse, fS as collectFarmLlmsTxtPages, fQ as createFarmAgentRobots, fT as createFarmDefaultLlmsTxt, fR as createFarmDefaultSitemap, fW as createFarmLlmsFullRenderer, fU as createFarmLlmsMarkdownReader, fP as createFarmMetadataRouteResponse, g as getFarmRedirectError, i as isFarmNotFoundError, b as isFarmRedirectError, f_ as manageFarmDocumentPreloads, f$ as manageFarmHtmlPreloads, g0 as manageFarmLinkHeaderPreloads, aI as registerFarmMCPServer, fV as renderFarmLlmsFullTxt, g1 as reportFarmPreloadWarnings, fX as resolveFarmLlmsTxtConfig, g3 as resolveFarmSecurityConfig } from '../client-plugins-CV4eJ9De.mjs';
|
|
4
|
+
export { m as mergeRouteRenderingDirectiveConfig } from '../route-rendering-DWFp3Yq4.mjs';
|
|
5
5
|
import { R as ResolvedFarmServerConfig } from '../workflows-jZ4BcdoZ.mjs';
|
|
6
6
|
export { a as FarmServerConfig, y as bufferFarmRequestBody, z as cloneFarmRequestWithContext, A as createFarmNodeRequestAbortSignal, B as createFarmRequestBodyErrorResponse, C as matchesFarmIfNoneMatch, E as readFarmRequestBody, G as readNodeRequestBody, H as resolveFarmServerConfig } from '../workflows-jZ4BcdoZ.mjs';
|
|
7
|
-
export { _ as _getRequestReadCount, a as _runWithCurrentRequest, g as getCurrentRequest, r as resolveFarmWebRequestOrigin } from '../request-
|
|
7
|
+
export { _ as _getRequestReadCount, a as _runWithCurrentRequest, g as getCurrentRequest, r as resolveFarmWebRequestOrigin } from '../request-sKayKcop.mjs';
|
|
8
8
|
export { configureFarmCache, createFarmCacheKey, getFarmDataCache, normalizeRevalidatePath } from '../cache.mjs';
|
|
9
9
|
import { k as FarmI18nUserConfig, R as ResolvedFarmI18nConfig } from '../types-CnH8DOqo.mjs';
|
|
10
10
|
export { c as createFarmLocaleCookie, g as getFarmLocaleVaryHeaders } from '../resolver-khasx3fU.mjs';
|
|
11
11
|
import { F as FarmLocalePathConfig } from '../index-BJJfLxJo.mjs';
|
|
12
12
|
export { l as localizeFarmHref, a as localizeFarmPathname, s as stripFarmLocaleFromPathname } from '../index-BJJfLxJo.mjs';
|
|
13
|
-
|
|
14
|
-
export {
|
|
13
|
+
import { F as FarmDefaultMCPPage } from '../agent-mcp-BC0bAGVF.mjs';
|
|
14
|
+
export { a as addMetadataImageReference, b as addMetadataMarkdownAlternate, g as collectFarmDefaultMCPPages, m as mergeMetadata, d as mergeModuleViewport, r as renderMetadataHead, e as renderViewportHead, h as resolveFarmDefaultMCPServer, f as resolveFarmNotFoundMetadata } from '../agent-mcp-BC0bAGVF.mjs';
|
|
15
|
+
export { _ as _runWithMiddlewareContext, c as _runWithMiddlewareData, e as applyProductionMiddlewareHeaders, d as createProductionMiddlewareRunner } from '../production-runtime-Du_FHb2-.mjs';
|
|
15
16
|
export { L as configureFarmObservability, P as emitFarmEvent, Q as runWithFarmRequestSpan } from '../observability-CoXunYhS.mjs';
|
|
16
17
|
export { f as createFarmInstrumentationLifecycle, r as resolveFarmInstrumentationRuntime } from '../instrumentation-runtime-CE06JLHZ.mjs';
|
|
17
18
|
export { _setDefaultFarmThemeConfig, getTheme } from '../theme/server.mjs';
|
|
18
19
|
import { c as FarmThemeRuntime, d as FarmThemeConfig, R as ResolvedFarmThemeConfig, a as FarmThemePreference } from '../types-DQnyD3VD.mjs';
|
|
19
20
|
export { d as applyFarmBasePath, r as resolveFarmTrailingSlashRedirect, s as searchParamsToObject, b as setFarmBasePath, a as setFarmTrailingSlashPreference, c as stripFarmBasePath } from '../base-path-BU16ETmo.mjs';
|
|
20
|
-
export { m as matchFarmPageRoute, p as parseRoutePath } from '../utils-
|
|
21
|
+
export { m as matchFarmPageRoute, p as parseRoutePath } from '../utils-p9Hs-jCc.mjs';
|
|
21
22
|
import 'node:http';
|
|
22
23
|
import '../lifecycle-DK06VuKP.mjs';
|
|
23
24
|
import '../integration-api-0y4FXJpC.mjs';
|
|
@@ -61,18 +62,6 @@ interface FarmAppManifestWebMCPTool {
|
|
|
61
62
|
inputSchemaSource: "literal" | "computed" | "none";
|
|
62
63
|
}
|
|
63
64
|
|
|
64
|
-
/**
|
|
65
|
-
* `/.well-known/farmjs`: one document describing a Farm app, so tools can discover it
|
|
66
|
-
* instead of each rebuilding the picture: Farm's version, renderer and packages, the app's
|
|
67
|
-
* MCP servers with every tool (however it was defined) and its schemas, their resources and
|
|
68
|
-
* prompts, its WebMCP browser tools, its integrations, its agent surfaces and its plugins.
|
|
69
|
-
* Never environment values, settings or secrets.
|
|
70
|
-
*
|
|
71
|
-
* Development serves it to anyone on the dev server. Production answers only a request
|
|
72
|
-
* signed for the app's Farm Infra key, so the public never reads the app's internals; any
|
|
73
|
-
* other request gets a 404. Kept free of Node built-ins: Web Crypto only.
|
|
74
|
-
*/
|
|
75
|
-
|
|
76
65
|
type FarmAppManifestToolSource = "endpoint" | "defineTool" | "serverFunction";
|
|
77
66
|
interface FarmAppManifestTool {
|
|
78
67
|
name: string;
|
|
@@ -80,7 +69,7 @@ interface FarmAppManifestTool {
|
|
|
80
69
|
description?: string;
|
|
81
70
|
/** How the app defined it: an API endpoint, `defineTool`, or a server function. */
|
|
82
71
|
source: FarmAppManifestToolSource;
|
|
83
|
-
/** The endpoint's method and route, for `source: "endpoint"`. */
|
|
72
|
+
/** The endpoint's method and route, for `source: "endpoint"`. Only in Farm Infra's view. */
|
|
84
73
|
method?: string;
|
|
85
74
|
path?: string;
|
|
86
75
|
readOnlyHint?: boolean;
|
|
@@ -107,6 +96,11 @@ interface FarmAppManifest {
|
|
|
107
96
|
name: string;
|
|
108
97
|
version: string;
|
|
109
98
|
path: string;
|
|
99
|
+
/**
|
|
100
|
+
* `"required"` when the server runs `authorize`: an anonymous client lists nothing,
|
|
101
|
+
* so the public view leaves `tools`, `resources` and `prompts` empty.
|
|
102
|
+
*/
|
|
103
|
+
authorization: "none" | "required";
|
|
110
104
|
tools: FarmAppManifestTool[];
|
|
111
105
|
resources: NonNullable<ServerDetails["resources"]>;
|
|
112
106
|
prompts: NonNullable<ServerDetails["prompts"]>;
|
|
@@ -141,18 +135,30 @@ interface FarmAppManifestInput {
|
|
|
141
135
|
integrations: FarmAppManifest["integrations"];
|
|
142
136
|
agent: FarmAppManifest["agent"];
|
|
143
137
|
plugins: string[];
|
|
144
|
-
/**
|
|
138
|
+
/**
|
|
139
|
+
* `analytics: false` turns off Farm Infra's signed view: the app talks to no Farm Infra.
|
|
140
|
+
* The public manifest is still served; `agent.manifest: false` turns that off.
|
|
141
|
+
*/
|
|
145
142
|
analytics: boolean;
|
|
143
|
+
/**
|
|
144
|
+
* The default read-only MCP server (`agent.mcp`) while the app would serve it. Set by the
|
|
145
|
+
* server at runtime, not serialized: it answers only while no other MCP server is listed.
|
|
146
|
+
*/
|
|
147
|
+
defaultMCP?: () => {
|
|
148
|
+
name: string;
|
|
149
|
+
version: string;
|
|
150
|
+
path: string;
|
|
151
|
+
} | undefined;
|
|
146
152
|
}
|
|
147
153
|
type Env = Record<string, string | undefined>;
|
|
148
154
|
/**
|
|
149
|
-
* Answers `/.well-known/farmjs
|
|
150
|
-
*
|
|
155
|
+
* Answers `/.well-known/farmjs.json` for anyone. A request Farm Infra signed for the app's
|
|
156
|
+
* `FARMJS_API_KEY` gets the full view, unless `analytics` is off; any other read gets the
|
|
157
|
+
* public one.
|
|
151
158
|
*/
|
|
152
|
-
declare function createFarmAppManifestResponse(request: Request, input: FarmAppManifestInput, options
|
|
153
|
-
development: boolean;
|
|
159
|
+
declare function createFarmAppManifestResponse(request: Request, input: FarmAppManifestInput, options?: {
|
|
154
160
|
env?: Env;
|
|
155
|
-
}): Promise<Response
|
|
161
|
+
}): Promise<Response>;
|
|
156
162
|
|
|
157
163
|
/**
|
|
158
164
|
* Compare a caller-supplied secret against the configured one without leaking
|
|
@@ -306,11 +312,45 @@ declare function _isFarmOwnedResponse(response: Response): boolean;
|
|
|
306
312
|
*/
|
|
307
313
|
declare function _withFarmResponseHeaders(response: Response, edit: (headers: Headers) => void): Response;
|
|
308
314
|
|
|
315
|
+
/**
|
|
316
|
+
* The protocol side of the default MCP server (`agent.mcp`, see `agent-mcp.ts`): stateless
|
|
317
|
+
* Streamable HTTP with JSON responses, and three read-only tools over the app's public pages.
|
|
318
|
+
* A small JSON-RPC implementation rather than the MCP SDK, so apps that never receive an
|
|
319
|
+
* MCP request carry no SDK.
|
|
320
|
+
*
|
|
321
|
+
* Kept free of Node built-ins: the production server runs on edge runtimes too.
|
|
322
|
+
*/
|
|
323
|
+
|
|
324
|
+
interface FarmDefaultMCPContext {
|
|
325
|
+
server: {
|
|
326
|
+
name: string;
|
|
327
|
+
version: string;
|
|
328
|
+
title?: string;
|
|
329
|
+
};
|
|
330
|
+
/** The app's public pages for this request's origin. */
|
|
331
|
+
listPages: () => FarmDefaultMCPPage[] | Promise<FarmDefaultMCPPage[]>;
|
|
332
|
+
/** Reads a Markdown URL anonymously; null when the page does not answer with Markdown. */
|
|
333
|
+
readMarkdown: (url: string) => Promise<string | null>;
|
|
334
|
+
basePath?: string;
|
|
335
|
+
}
|
|
336
|
+
/**
|
|
337
|
+
* Answers one request to the default MCP endpoint: stateless Streamable HTTP, JSON
|
|
338
|
+
* responses, no sessions, and no server-initiated stream (GET answers 405).
|
|
339
|
+
*/
|
|
340
|
+
declare function handleFarmDefaultMCPRequest(request: Request, context: FarmDefaultMCPContext): Promise<Response>;
|
|
341
|
+
|
|
309
342
|
interface FarmAiCatalogInput {
|
|
310
343
|
/** The app's basePath; the catalog lives beneath it, like the API catalog. */
|
|
311
344
|
basePath?: string;
|
|
312
345
|
/** The app's public API path, which maps to Farm's canonical `/api`. */
|
|
313
346
|
apiServerBasePath?: string;
|
|
347
|
+
/**
|
|
348
|
+
* The default read-only server (`agent.mcp`), when this app would serve it. It is
|
|
349
|
+
* listed only while no other MCP server is, the same rule that decides whether it answers.
|
|
350
|
+
*/
|
|
351
|
+
defaultMCP?: () => (FarmMCPServerRegistration & {
|
|
352
|
+
path: `/${string}`;
|
|
353
|
+
}) | undefined;
|
|
314
354
|
}
|
|
315
355
|
/**
|
|
316
356
|
* The llms.txt links for the app's MCP servers: each endpoint, then the catalog
|
|
@@ -424,4 +464,4 @@ declare function appendFarmRedirectQuery(destination: string, search: string): s
|
|
|
424
464
|
|
|
425
465
|
declare function appendFarmLinkHeader(headers: Headers, value: string): void;
|
|
426
466
|
|
|
427
|
-
export { _isFarmOwnedResponse, _markFarmOwnedResponse, _runWithAPIRequestRuntime, _withFarmResponseHeaders, appendFarmLinkHeader, appendFarmRedirectQuery, applyFarmPreviewRobotsTag, applyFarmThemeDocument, compareRouteSpecificity, createDefaultErrorMarkup, createFarmAiCatalogResponse, createFarmApiCatalogResponse, createFarmAppManifestResponse, createFarmLayoutSelector, createFarmLegacyRequest, createFarmProductionLifecycle, createFarmThemeDocumentParts, createLateNotFoundRecovery, createLateRedirectRecovery, ensureFarmDocumentMeta, farmSecretsMatch, generateNativeMCPPluginSource, getDefaultErrorStatusText, getRoutePatternSpecificity, isInRouteGroupScope as isInFarmRouteGroupScope, listFarmMCPLlmsTxtLinks, renderFarmLegacyErrorHtml, renderFarmLegacyHtml, renderFarmLocaleAlternateLinks, resolveDefaultErrorStatus, resolveFarmI18nConfig, resolveFarmPreviewDeployment, resolveFarmRouteContext, serializeFarmInlineValue, withFarmRouteContext };
|
|
467
|
+
export { _isFarmOwnedResponse, _markFarmOwnedResponse, _runWithAPIRequestRuntime, _withFarmResponseHeaders, appendFarmLinkHeader, appendFarmRedirectQuery, applyFarmPreviewRobotsTag, applyFarmThemeDocument, compareRouteSpecificity, createDefaultErrorMarkup, createFarmAiCatalogResponse, createFarmApiCatalogResponse, createFarmAppManifestResponse, createFarmLayoutSelector, createFarmLegacyRequest, createFarmProductionLifecycle, createFarmThemeDocumentParts, createLateNotFoundRecovery, createLateRedirectRecovery, ensureFarmDocumentMeta, farmSecretsMatch, generateNativeMCPPluginSource, getDefaultErrorStatusText, getRoutePatternSpecificity, handleFarmDefaultMCPRequest, isInRouteGroupScope as isInFarmRouteGroupScope, listFarmMCPLlmsTxtLinks, renderFarmLegacyErrorHtml, renderFarmLegacyHtml, renderFarmLocaleAlternateLinks, resolveDefaultErrorStatus, resolveFarmI18nConfig, resolveFarmPreviewDeployment, resolveFarmRouteContext, serializeFarmInlineValue, withFarmRouteContext };
|
|
@@ -1,23 +1,24 @@
|
|
|
1
1
|
export { _runWithAfterRequest } from '../after.js';
|
|
2
|
-
import {
|
|
3
|
-
export {
|
|
4
|
-
export { m as mergeRouteRenderingDirectiveConfig } from '../route-rendering-
|
|
2
|
+
import { aJ as FarmMCPCatalogDetails, fN as APIRequestRuntime, bT as ResolvedFarmMCPConfig, aE as FarmMCPServerRegistration, fO as FarmLlmsTxtLink, I as FarmConfig, _ as FarmContextFactoryInput } from '../client-plugins-C8DjftDF.js';
|
|
3
|
+
export { fY as FarmLlmsTxtUserConfig, fZ as ResolvedFarmLlmsTxtConfig, g2 as applyFarmCspNonceToResponse, fS as collectFarmLlmsTxtPages, fQ as createFarmAgentRobots, fT as createFarmDefaultLlmsTxt, fR as createFarmDefaultSitemap, fW as createFarmLlmsFullRenderer, fU as createFarmLlmsMarkdownReader, fP as createFarmMetadataRouteResponse, g as getFarmRedirectError, i as isFarmNotFoundError, b as isFarmRedirectError, f_ as manageFarmDocumentPreloads, f$ as manageFarmHtmlPreloads, g0 as manageFarmLinkHeaderPreloads, aI as registerFarmMCPServer, fV as renderFarmLlmsFullTxt, g1 as reportFarmPreloadWarnings, fX as resolveFarmLlmsTxtConfig, g3 as resolveFarmSecurityConfig } from '../client-plugins-C8DjftDF.js';
|
|
4
|
+
export { m as mergeRouteRenderingDirectiveConfig } from '../route-rendering-Bx4Auw6Q.js';
|
|
5
5
|
import { R as ResolvedFarmServerConfig } from '../workflows-jZ4BcdoZ.js';
|
|
6
6
|
export { a as FarmServerConfig, y as bufferFarmRequestBody, z as cloneFarmRequestWithContext, A as createFarmNodeRequestAbortSignal, B as createFarmRequestBodyErrorResponse, C as matchesFarmIfNoneMatch, E as readFarmRequestBody, G as readNodeRequestBody, H as resolveFarmServerConfig } from '../workflows-jZ4BcdoZ.js';
|
|
7
|
-
export { _ as _getRequestReadCount, a as _runWithCurrentRequest, g as getCurrentRequest, r as resolveFarmWebRequestOrigin } from '../request-
|
|
7
|
+
export { _ as _getRequestReadCount, a as _runWithCurrentRequest, g as getCurrentRequest, r as resolveFarmWebRequestOrigin } from '../request-BNWr7r5e.js';
|
|
8
8
|
export { configureFarmCache, createFarmCacheKey, getFarmDataCache, normalizeRevalidatePath } from '../cache.js';
|
|
9
9
|
import { k as FarmI18nUserConfig, R as ResolvedFarmI18nConfig } from '../types-CnH8DOqo.js';
|
|
10
10
|
export { c as createFarmLocaleCookie, g as getFarmLocaleVaryHeaders } from '../resolver-DadfRL6F.js';
|
|
11
11
|
import { F as FarmLocalePathConfig } from '../index-CwoOP-MW.js';
|
|
12
12
|
export { l as localizeFarmHref, a as localizeFarmPathname, s as stripFarmLocaleFromPathname } from '../index-CwoOP-MW.js';
|
|
13
|
-
|
|
14
|
-
export {
|
|
13
|
+
import { F as FarmDefaultMCPPage } from '../agent-mcp-jyDHbQKe.js';
|
|
14
|
+
export { a as addMetadataImageReference, b as addMetadataMarkdownAlternate, g as collectFarmDefaultMCPPages, m as mergeMetadata, d as mergeModuleViewport, r as renderMetadataHead, e as renderViewportHead, h as resolveFarmDefaultMCPServer, f as resolveFarmNotFoundMetadata } from '../agent-mcp-jyDHbQKe.js';
|
|
15
|
+
export { _ as _runWithMiddlewareContext, c as _runWithMiddlewareData, e as applyProductionMiddlewareHeaders, d as createProductionMiddlewareRunner } from '../production-runtime-C2kkrPVZ.js';
|
|
15
16
|
export { L as configureFarmObservability, P as emitFarmEvent, Q as runWithFarmRequestSpan } from '../observability-CoXunYhS.js';
|
|
16
17
|
export { f as createFarmInstrumentationLifecycle, r as resolveFarmInstrumentationRuntime } from '../instrumentation-runtime-CE06JLHZ.js';
|
|
17
18
|
export { _setDefaultFarmThemeConfig, getTheme } from '../theme/server.js';
|
|
18
19
|
import { c as FarmThemeRuntime, d as FarmThemeConfig, R as ResolvedFarmThemeConfig, a as FarmThemePreference } from '../types-DQnyD3VD.js';
|
|
19
20
|
export { d as applyFarmBasePath, r as resolveFarmTrailingSlashRedirect, s as searchParamsToObject, b as setFarmBasePath, a as setFarmTrailingSlashPreference, c as stripFarmBasePath } from '../base-path-BU16ETmo.js';
|
|
20
|
-
export { m as matchFarmPageRoute, p as parseRoutePath } from '../utils-
|
|
21
|
+
export { m as matchFarmPageRoute, p as parseRoutePath } from '../utils-BwVcAfUR.js';
|
|
21
22
|
import 'node:http';
|
|
22
23
|
import '../lifecycle-DK06VuKP.js';
|
|
23
24
|
import '../integration-api-BPJo5oXb.js';
|
|
@@ -61,18 +62,6 @@ interface FarmAppManifestWebMCPTool {
|
|
|
61
62
|
inputSchemaSource: "literal" | "computed" | "none";
|
|
62
63
|
}
|
|
63
64
|
|
|
64
|
-
/**
|
|
65
|
-
* `/.well-known/farmjs`: one document describing a Farm app, so tools can discover it
|
|
66
|
-
* instead of each rebuilding the picture: Farm's version, renderer and packages, the app's
|
|
67
|
-
* MCP servers with every tool (however it was defined) and its schemas, their resources and
|
|
68
|
-
* prompts, its WebMCP browser tools, its integrations, its agent surfaces and its plugins.
|
|
69
|
-
* Never environment values, settings or secrets.
|
|
70
|
-
*
|
|
71
|
-
* Development serves it to anyone on the dev server. Production answers only a request
|
|
72
|
-
* signed for the app's Farm Infra key, so the public never reads the app's internals; any
|
|
73
|
-
* other request gets a 404. Kept free of Node built-ins: Web Crypto only.
|
|
74
|
-
*/
|
|
75
|
-
|
|
76
65
|
type FarmAppManifestToolSource = "endpoint" | "defineTool" | "serverFunction";
|
|
77
66
|
interface FarmAppManifestTool {
|
|
78
67
|
name: string;
|
|
@@ -80,7 +69,7 @@ interface FarmAppManifestTool {
|
|
|
80
69
|
description?: string;
|
|
81
70
|
/** How the app defined it: an API endpoint, `defineTool`, or a server function. */
|
|
82
71
|
source: FarmAppManifestToolSource;
|
|
83
|
-
/** The endpoint's method and route, for `source: "endpoint"`. */
|
|
72
|
+
/** The endpoint's method and route, for `source: "endpoint"`. Only in Farm Infra's view. */
|
|
84
73
|
method?: string;
|
|
85
74
|
path?: string;
|
|
86
75
|
readOnlyHint?: boolean;
|
|
@@ -107,6 +96,11 @@ interface FarmAppManifest {
|
|
|
107
96
|
name: string;
|
|
108
97
|
version: string;
|
|
109
98
|
path: string;
|
|
99
|
+
/**
|
|
100
|
+
* `"required"` when the server runs `authorize`: an anonymous client lists nothing,
|
|
101
|
+
* so the public view leaves `tools`, `resources` and `prompts` empty.
|
|
102
|
+
*/
|
|
103
|
+
authorization: "none" | "required";
|
|
110
104
|
tools: FarmAppManifestTool[];
|
|
111
105
|
resources: NonNullable<ServerDetails["resources"]>;
|
|
112
106
|
prompts: NonNullable<ServerDetails["prompts"]>;
|
|
@@ -141,18 +135,30 @@ interface FarmAppManifestInput {
|
|
|
141
135
|
integrations: FarmAppManifest["integrations"];
|
|
142
136
|
agent: FarmAppManifest["agent"];
|
|
143
137
|
plugins: string[];
|
|
144
|
-
/**
|
|
138
|
+
/**
|
|
139
|
+
* `analytics: false` turns off Farm Infra's signed view: the app talks to no Farm Infra.
|
|
140
|
+
* The public manifest is still served; `agent.manifest: false` turns that off.
|
|
141
|
+
*/
|
|
145
142
|
analytics: boolean;
|
|
143
|
+
/**
|
|
144
|
+
* The default read-only MCP server (`agent.mcp`) while the app would serve it. Set by the
|
|
145
|
+
* server at runtime, not serialized: it answers only while no other MCP server is listed.
|
|
146
|
+
*/
|
|
147
|
+
defaultMCP?: () => {
|
|
148
|
+
name: string;
|
|
149
|
+
version: string;
|
|
150
|
+
path: string;
|
|
151
|
+
} | undefined;
|
|
146
152
|
}
|
|
147
153
|
type Env = Record<string, string | undefined>;
|
|
148
154
|
/**
|
|
149
|
-
* Answers `/.well-known/farmjs
|
|
150
|
-
*
|
|
155
|
+
* Answers `/.well-known/farmjs.json` for anyone. A request Farm Infra signed for the app's
|
|
156
|
+
* `FARMJS_API_KEY` gets the full view, unless `analytics` is off; any other read gets the
|
|
157
|
+
* public one.
|
|
151
158
|
*/
|
|
152
|
-
declare function createFarmAppManifestResponse(request: Request, input: FarmAppManifestInput, options
|
|
153
|
-
development: boolean;
|
|
159
|
+
declare function createFarmAppManifestResponse(request: Request, input: FarmAppManifestInput, options?: {
|
|
154
160
|
env?: Env;
|
|
155
|
-
}): Promise<Response
|
|
161
|
+
}): Promise<Response>;
|
|
156
162
|
|
|
157
163
|
/**
|
|
158
164
|
* Compare a caller-supplied secret against the configured one without leaking
|
|
@@ -306,11 +312,45 @@ declare function _isFarmOwnedResponse(response: Response): boolean;
|
|
|
306
312
|
*/
|
|
307
313
|
declare function _withFarmResponseHeaders(response: Response, edit: (headers: Headers) => void): Response;
|
|
308
314
|
|
|
315
|
+
/**
|
|
316
|
+
* The protocol side of the default MCP server (`agent.mcp`, see `agent-mcp.ts`): stateless
|
|
317
|
+
* Streamable HTTP with JSON responses, and three read-only tools over the app's public pages.
|
|
318
|
+
* A small JSON-RPC implementation rather than the MCP SDK, so apps that never receive an
|
|
319
|
+
* MCP request carry no SDK.
|
|
320
|
+
*
|
|
321
|
+
* Kept free of Node built-ins: the production server runs on edge runtimes too.
|
|
322
|
+
*/
|
|
323
|
+
|
|
324
|
+
interface FarmDefaultMCPContext {
|
|
325
|
+
server: {
|
|
326
|
+
name: string;
|
|
327
|
+
version: string;
|
|
328
|
+
title?: string;
|
|
329
|
+
};
|
|
330
|
+
/** The app's public pages for this request's origin. */
|
|
331
|
+
listPages: () => FarmDefaultMCPPage[] | Promise<FarmDefaultMCPPage[]>;
|
|
332
|
+
/** Reads a Markdown URL anonymously; null when the page does not answer with Markdown. */
|
|
333
|
+
readMarkdown: (url: string) => Promise<string | null>;
|
|
334
|
+
basePath?: string;
|
|
335
|
+
}
|
|
336
|
+
/**
|
|
337
|
+
* Answers one request to the default MCP endpoint: stateless Streamable HTTP, JSON
|
|
338
|
+
* responses, no sessions, and no server-initiated stream (GET answers 405).
|
|
339
|
+
*/
|
|
340
|
+
declare function handleFarmDefaultMCPRequest(request: Request, context: FarmDefaultMCPContext): Promise<Response>;
|
|
341
|
+
|
|
309
342
|
interface FarmAiCatalogInput {
|
|
310
343
|
/** The app's basePath; the catalog lives beneath it, like the API catalog. */
|
|
311
344
|
basePath?: string;
|
|
312
345
|
/** The app's public API path, which maps to Farm's canonical `/api`. */
|
|
313
346
|
apiServerBasePath?: string;
|
|
347
|
+
/**
|
|
348
|
+
* The default read-only server (`agent.mcp`), when this app would serve it. It is
|
|
349
|
+
* listed only while no other MCP server is, the same rule that decides whether it answers.
|
|
350
|
+
*/
|
|
351
|
+
defaultMCP?: () => (FarmMCPServerRegistration & {
|
|
352
|
+
path: `/${string}`;
|
|
353
|
+
}) | undefined;
|
|
314
354
|
}
|
|
315
355
|
/**
|
|
316
356
|
* The llms.txt links for the app's MCP servers: each endpoint, then the catalog
|
|
@@ -424,4 +464,4 @@ declare function appendFarmRedirectQuery(destination: string, search: string): s
|
|
|
424
464
|
|
|
425
465
|
declare function appendFarmLinkHeader(headers: Headers, value: string): void;
|
|
426
466
|
|
|
427
|
-
export { _isFarmOwnedResponse, _markFarmOwnedResponse, _runWithAPIRequestRuntime, _withFarmResponseHeaders, appendFarmLinkHeader, appendFarmRedirectQuery, applyFarmPreviewRobotsTag, applyFarmThemeDocument, compareRouteSpecificity, createDefaultErrorMarkup, createFarmAiCatalogResponse, createFarmApiCatalogResponse, createFarmAppManifestResponse, createFarmLayoutSelector, createFarmLegacyRequest, createFarmProductionLifecycle, createFarmThemeDocumentParts, createLateNotFoundRecovery, createLateRedirectRecovery, ensureFarmDocumentMeta, farmSecretsMatch, generateNativeMCPPluginSource, getDefaultErrorStatusText, getRoutePatternSpecificity, isInRouteGroupScope as isInFarmRouteGroupScope, listFarmMCPLlmsTxtLinks, renderFarmLegacyErrorHtml, renderFarmLegacyHtml, renderFarmLocaleAlternateLinks, resolveDefaultErrorStatus, resolveFarmI18nConfig, resolveFarmPreviewDeployment, resolveFarmRouteContext, serializeFarmInlineValue, withFarmRouteContext };
|
|
467
|
+
export { _isFarmOwnedResponse, _markFarmOwnedResponse, _runWithAPIRequestRuntime, _withFarmResponseHeaders, appendFarmLinkHeader, appendFarmRedirectQuery, applyFarmPreviewRobotsTag, applyFarmThemeDocument, compareRouteSpecificity, createDefaultErrorMarkup, createFarmAiCatalogResponse, createFarmApiCatalogResponse, createFarmAppManifestResponse, createFarmLayoutSelector, createFarmLegacyRequest, createFarmProductionLifecycle, createFarmThemeDocumentParts, createLateNotFoundRecovery, createLateRedirectRecovery, ensureFarmDocumentMeta, farmSecretsMatch, generateNativeMCPPluginSource, getDefaultErrorStatusText, getRoutePatternSpecificity, handleFarmDefaultMCPRequest, isInRouteGroupScope as isInFarmRouteGroupScope, listFarmMCPLlmsTxtLinks, renderFarmLegacyErrorHtml, renderFarmLegacyHtml, renderFarmLocaleAlternateLinks, resolveDefaultErrorStatus, resolveFarmI18nConfig, resolveFarmPreviewDeployment, resolveFarmRouteContext, serializeFarmInlineValue, withFarmRouteContext };
|
|
@@ -1,20 +1,19 @@
|
|
|
1
1
|
import {
|
|
2
|
+
handleFarmDefaultMCPRequest
|
|
3
|
+
} from "../chunk-6SJ2KJTA.mjs";
|
|
4
|
+
import {
|
|
5
|
+
createFarmLayoutSelector,
|
|
2
6
|
generateNativeMCPPluginSource
|
|
3
|
-
} from "../chunk-
|
|
7
|
+
} from "../chunk-WRPHYQVY.mjs";
|
|
4
8
|
import {
|
|
5
9
|
applyProductionMiddlewareHeaders,
|
|
6
10
|
createProductionMiddlewareRunner
|
|
7
|
-
} from "../chunk-
|
|
11
|
+
} from "../chunk-FGRYBX5X.mjs";
|
|
8
12
|
import {
|
|
9
13
|
createFarmInstrumentationLifecycle,
|
|
10
14
|
resolveFarmInstrumentationRuntime
|
|
11
15
|
} from "../chunk-H77NVNJ2.mjs";
|
|
12
|
-
import
|
|
13
|
-
matchSegmentParts,
|
|
14
|
-
normalizePathname,
|
|
15
|
-
parseRoutePattern,
|
|
16
|
-
splitNormalizedPathname
|
|
17
|
-
} from "../chunk-OT6ZEW74.mjs";
|
|
16
|
+
import "../chunk-OT6ZEW74.mjs";
|
|
18
17
|
import {
|
|
19
18
|
applyFarmThemeDocument,
|
|
20
19
|
createDefaultErrorMarkup,
|
|
@@ -27,12 +26,15 @@ import {
|
|
|
27
26
|
createLateRedirectRecovery,
|
|
28
27
|
ensureFarmDocumentMeta,
|
|
29
28
|
getDefaultErrorStatusText,
|
|
30
|
-
getRouteGroupScope,
|
|
31
29
|
isInRouteGroupScope,
|
|
32
30
|
listFarmMCPLlmsTxtLinks,
|
|
33
31
|
renderFarmLocaleAlternateLinks,
|
|
34
32
|
resolveDefaultErrorStatus
|
|
35
|
-
} from "../chunk-
|
|
33
|
+
} from "../chunk-LBGILORX.mjs";
|
|
34
|
+
import {
|
|
35
|
+
collectFarmDefaultMCPPages,
|
|
36
|
+
resolveFarmDefaultMCPServer
|
|
37
|
+
} from "../chunk-UH6QN5NL.mjs";
|
|
36
38
|
import {
|
|
37
39
|
mergeRouteRenderingDirectiveConfig
|
|
38
40
|
} from "../chunk-DAO7JGTS.mjs";
|
|
@@ -43,23 +45,26 @@ import "../chunk-XAXTTBUT.mjs";
|
|
|
43
45
|
import {
|
|
44
46
|
_setDefaultFarmThemeConfig,
|
|
45
47
|
getTheme
|
|
46
|
-
} from "../chunk-
|
|
48
|
+
} from "../chunk-TDNWPAVR.mjs";
|
|
47
49
|
import {
|
|
48
50
|
applyFarmCspNonceToResponse,
|
|
49
51
|
applyFarmPreviewRobotsTag,
|
|
50
|
-
collectFarmLlmsTxtPages,
|
|
51
52
|
createFarmAgentRobots,
|
|
52
|
-
|
|
53
|
-
createFarmLlmsFullRenderer,
|
|
54
|
-
createFarmLlmsMarkdownReader,
|
|
53
|
+
createFarmDefaultSitemap,
|
|
55
54
|
manageFarmDocumentPreloads,
|
|
56
55
|
manageFarmHtmlPreloads,
|
|
57
56
|
manageFarmLinkHeaderPreloads,
|
|
58
|
-
renderFarmLlmsFullTxt,
|
|
59
57
|
reportFarmPreloadWarnings,
|
|
60
|
-
resolveFarmLlmsTxtConfig,
|
|
61
58
|
resolveFarmSecurityConfig
|
|
62
|
-
} from "../chunk-
|
|
59
|
+
} from "../chunk-4E5WBPEG.mjs";
|
|
60
|
+
import {
|
|
61
|
+
collectFarmLlmsTxtPages,
|
|
62
|
+
createFarmDefaultLlmsTxt,
|
|
63
|
+
createFarmLlmsFullRenderer,
|
|
64
|
+
createFarmLlmsMarkdownReader,
|
|
65
|
+
renderFarmLlmsFullTxt,
|
|
66
|
+
resolveFarmLlmsTxtConfig
|
|
67
|
+
} from "../chunk-DTSROJ5J.mjs";
|
|
63
68
|
import "../chunk-WWIKMBRN.mjs";
|
|
64
69
|
import "../chunk-MVL2RAJW.mjs";
|
|
65
70
|
import {
|
|
@@ -73,8 +78,8 @@ import {
|
|
|
73
78
|
import {
|
|
74
79
|
_runWithMiddlewareContext,
|
|
75
80
|
_runWithMiddlewareData
|
|
76
|
-
} from "../chunk-
|
|
77
|
-
import "../chunk-
|
|
81
|
+
} from "../chunk-J3ANCZKA.mjs";
|
|
82
|
+
import "../chunk-HZFM2LWQ.mjs";
|
|
78
83
|
import {
|
|
79
84
|
_runWithAPIRequestRuntime
|
|
80
85
|
} from "../chunk-R3DS7A2T.mjs";
|
|
@@ -99,7 +104,7 @@ import {
|
|
|
99
104
|
readFarmRequestBody,
|
|
100
105
|
readNodeRequestBody,
|
|
101
106
|
resolveFarmServerConfig
|
|
102
|
-
} from "../chunk-
|
|
107
|
+
} from "../chunk-ZMMBIVQM.mjs";
|
|
103
108
|
import {
|
|
104
109
|
resolveFarmI18nConfig
|
|
105
110
|
} from "../chunk-BCMSYSN2.mjs";
|
|
@@ -110,13 +115,13 @@ import {
|
|
|
110
115
|
import {
|
|
111
116
|
searchParamsToObject
|
|
112
117
|
} from "../chunk-QVKYGNVM.mjs";
|
|
113
|
-
import "../chunk-BTHHUD7Q.mjs";
|
|
114
118
|
import {
|
|
115
119
|
configureFarmObservability,
|
|
116
120
|
emitFarmEvent,
|
|
117
121
|
runWithFarmRequestSpan
|
|
118
122
|
} from "../chunk-FUZEBRP3.mjs";
|
|
119
|
-
import "../chunk-
|
|
123
|
+
import "../chunk-BTHHUD7Q.mjs";
|
|
124
|
+
import "../chunk-YCKO6FRS.mjs";
|
|
120
125
|
import {
|
|
121
126
|
resolveFarmTrailingSlashRedirect,
|
|
122
127
|
setFarmTrailingSlashPreference
|
|
@@ -163,9 +168,9 @@ import {
|
|
|
163
168
|
_runWithCurrentRequest,
|
|
164
169
|
getCurrentRequest,
|
|
165
170
|
resolveFarmWebRequestOrigin
|
|
166
|
-
} from "../chunk-
|
|
171
|
+
} from "../chunk-3KGDJLJK.mjs";
|
|
167
172
|
import "../chunk-CQ6OSQ3K.mjs";
|
|
168
|
-
import "../chunk-
|
|
173
|
+
import "../chunk-S3VWVTVA.mjs";
|
|
169
174
|
import {
|
|
170
175
|
localizeFarmHref,
|
|
171
176
|
localizeFarmPathname,
|
|
@@ -184,36 +189,6 @@ import {
|
|
|
184
189
|
__name
|
|
185
190
|
} from "../chunk-LPEX4YW6.mjs";
|
|
186
191
|
|
|
187
|
-
// src/routing/layout-selector.ts
|
|
188
|
-
function createFarmLayoutSelector(layouts, resolveRouteDirectory) {
|
|
189
|
-
const prepared = layouts.map((layout) => {
|
|
190
|
-
const segments = layout.pattern === "/" ? [] : parseRoutePattern(layout.pattern);
|
|
191
|
-
return {
|
|
192
|
-
layout,
|
|
193
|
-
segments: segments.length === 0 ? null : segments,
|
|
194
|
-
groupScope: getRouteGroupScope(layout.pattern)
|
|
195
|
-
};
|
|
196
|
-
});
|
|
197
|
-
return (pathname, routeDirectory) => {
|
|
198
|
-
const applicable = [];
|
|
199
|
-
let parts;
|
|
200
|
-
let directory = routeDirectory;
|
|
201
|
-
for (const { layout, segments, groupScope } of prepared) {
|
|
202
|
-
if (segments !== null) {
|
|
203
|
-
parts ?? (parts = splitNormalizedPathname(normalizePathname(pathname.replace(/\/$/, "") || "/")));
|
|
204
|
-
if (matchSegmentParts(segments, parts, true) === null) continue;
|
|
205
|
-
}
|
|
206
|
-
if (groupScope !== null) {
|
|
207
|
-
if (directory === void 0) directory = resolveRouteDirectory?.(pathname) ?? null;
|
|
208
|
-
if (!isInRouteGroupScope(directory, groupScope)) continue;
|
|
209
|
-
}
|
|
210
|
-
applicable.push(layout);
|
|
211
|
-
}
|
|
212
|
-
return applicable;
|
|
213
|
-
};
|
|
214
|
-
}
|
|
215
|
-
__name(createFarmLayoutSelector, "createFarmLayoutSelector");
|
|
216
|
-
|
|
217
192
|
// src/production-lifecycle.ts
|
|
218
193
|
function createFarmProductionLifecycle(options) {
|
|
219
194
|
let state = "starting";
|
|
@@ -534,6 +509,7 @@ export {
|
|
|
534
509
|
applyProductionMiddlewareHeaders,
|
|
535
510
|
bufferFarmRequestBody,
|
|
536
511
|
cloneFarmRequestWithContext,
|
|
512
|
+
collectFarmDefaultMCPPages,
|
|
537
513
|
collectFarmLlmsTxtPages,
|
|
538
514
|
compareRouteSpecificity,
|
|
539
515
|
configureFarmCache,
|
|
@@ -545,6 +521,7 @@ export {
|
|
|
545
521
|
createFarmAppManifestResponse,
|
|
546
522
|
createFarmCacheKey,
|
|
547
523
|
createFarmDefaultLlmsTxt,
|
|
524
|
+
createFarmDefaultSitemap,
|
|
548
525
|
createFarmInstrumentationLifecycle,
|
|
549
526
|
createFarmLayoutSelector,
|
|
550
527
|
createFarmLegacyRequest,
|
|
@@ -570,6 +547,7 @@ export {
|
|
|
570
547
|
getFarmRedirectError,
|
|
571
548
|
getRoutePatternSpecificity,
|
|
572
549
|
getTheme,
|
|
550
|
+
handleFarmDefaultMCPRequest,
|
|
573
551
|
isFarmNotFoundError,
|
|
574
552
|
isFarmRedirectError,
|
|
575
553
|
isInRouteGroupScope as isInFarmRouteGroupScope,
|
|
@@ -597,6 +575,7 @@ export {
|
|
|
597
575
|
renderViewportHead,
|
|
598
576
|
reportFarmPreloadWarnings,
|
|
599
577
|
resolveDefaultErrorStatus,
|
|
578
|
+
resolveFarmDefaultMCPServer,
|
|
600
579
|
resolveFarmI18nConfig,
|
|
601
580
|
resolveFarmInstrumentationRuntime,
|
|
602
581
|
resolveFarmLlmsTxtConfig,
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
var _chunkWBKEZXWEcjs = require('./chunk-WBKEZXWE.cjs');
|
|
9
|
+
require('./chunk-UYIHRDE4.cjs');
|
|
10
|
+
require('./chunk-S3JO3N4H.cjs');
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
exports.createFarmConfigResolutionPlugin = _chunkWBKEZXWEcjs.createFarmConfigResolutionPlugin; exports.getFarmAppDirectories = _chunkWBKEZXWEcjs.getFarmAppDirectories; exports.getFarmLayerAliases = _chunkWBKEZXWEcjs.getFarmLayerAliases; exports.getFarmSourceRoots = _chunkWBKEZXWEcjs.getFarmSourceRoots; exports.loadFarmConfigFile = _chunkWBKEZXWEcjs.loadFarmConfigFile; exports.resolveFarmLayers = _chunkWBKEZXWEcjs.resolveFarmLayers;
|
package/dist/markdown.cjs
CHANGED
|
@@ -17,8 +17,8 @@
|
|
|
17
17
|
var _chunkEUV4YR3Vcjs = require('./chunk-EUV4YR3V.cjs');
|
|
18
18
|
require('./chunk-J63ZH5OQ.cjs');
|
|
19
19
|
require('./chunk-75RZHGLS.cjs');
|
|
20
|
-
require('./chunk-KNBBQHO2.cjs');
|
|
21
20
|
require('./chunk-E3UK5IIB.cjs');
|
|
21
|
+
require('./chunk-KNBBQHO2.cjs');
|
|
22
22
|
require('./chunk-G7HXGLEC.cjs');
|
|
23
23
|
require('./chunk-S3A45T7F.cjs');
|
|
24
24
|
require('./chunk-FJ3M4CUX.cjs');
|
package/dist/markdown.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export { fm as ApplyMarkdownNegotiationHeadersOptions, fl as CreateMarkdownMirrorResponseOptions, z as FARM_MARKDOWN_CONTENT_TYPE, fj as FarmMarkdownMirrorTarget, aF as FarmMarkdownResolvedConfig, fi as FarmMarkdownResolvedRoute, fh as FarmMarkdownRouteInput, cI as FarmMarkdownUserConfig, fB as FarmPageFormAction, fz as FarmPageFormField, fy as FarmPageFormOption, fA as FarmPageFormSubmit, fk as ResolveMarkdownMirrorTargetOptions, fq as applyMarkdownNegotiationHeaders, A as createFarmMarkdownErrorBody, fp as createMarkdownMirrorResponse, fC as extractFarmPageActions, fs as farmAcceptQuality, B as farmRequestWantsMarkdown, fv as getFarmMarkdownAlternatePath, fu as getFarmMarkdownMirrorPath, fr as htmlToMarkdown, fw as isFarmMarkdownMirrorExposed, fx as matchesFarmMarkdownRoutePattern, ft as requestAcceptsMarkdown, fn as resolveMarkdownConfig, fo as resolveMarkdownMirrorTarget } from './client-plugins-CV4eJ9De.mjs';
|
|
2
2
|
import './lifecycle-DK06VuKP.mjs';
|
|
3
3
|
import './integration-api-0y4FXJpC.mjs';
|
|
4
4
|
import './endpoint-CCHFqyTE.mjs';
|
package/dist/markdown.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export { fm as ApplyMarkdownNegotiationHeadersOptions, fl as CreateMarkdownMirrorResponseOptions, z as FARM_MARKDOWN_CONTENT_TYPE, fj as FarmMarkdownMirrorTarget, aF as FarmMarkdownResolvedConfig, fi as FarmMarkdownResolvedRoute, fh as FarmMarkdownRouteInput, cI as FarmMarkdownUserConfig, fB as FarmPageFormAction, fz as FarmPageFormField, fy as FarmPageFormOption, fA as FarmPageFormSubmit, fk as ResolveMarkdownMirrorTargetOptions, fq as applyMarkdownNegotiationHeaders, A as createFarmMarkdownErrorBody, fp as createMarkdownMirrorResponse, fC as extractFarmPageActions, fs as farmAcceptQuality, B as farmRequestWantsMarkdown, fv as getFarmMarkdownAlternatePath, fu as getFarmMarkdownMirrorPath, fr as htmlToMarkdown, fw as isFarmMarkdownMirrorExposed, fx as matchesFarmMarkdownRoutePattern, ft as requestAcceptsMarkdown, fn as resolveMarkdownConfig, fo as resolveMarkdownMirrorTarget } from './client-plugins-C8DjftDF.js';
|
|
2
2
|
import './lifecycle-DK06VuKP.js';
|
|
3
3
|
import './integration-api-BPJo5oXb.js';
|
|
4
4
|
import './endpoint-CA-TNX60.js';
|
package/dist/markdown.mjs
CHANGED
|
@@ -17,8 +17,8 @@ import {
|
|
|
17
17
|
} from "./chunk-WWIKMBRN.mjs";
|
|
18
18
|
import "./chunk-MVL2RAJW.mjs";
|
|
19
19
|
import "./chunk-ZLAT2CWY.mjs";
|
|
20
|
-
import "./chunk-BTHHUD7Q.mjs";
|
|
21
20
|
import "./chunk-FUZEBRP3.mjs";
|
|
21
|
+
import "./chunk-BTHHUD7Q.mjs";
|
|
22
22
|
import "./chunk-O7BH5O46.mjs";
|
|
23
23
|
import "./chunk-7LTCDQRS.mjs";
|
|
24
24
|
import "./chunk-Z3HATSKO.mjs";
|