@sonordev/site-kit 8.5.0 → 8.5.2

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 (97) hide show
  1. package/CHANGELOG.md +10 -0
  2. package/README.md +4 -2
  3. package/agent-manifest.json +1 -1
  4. package/dist/{AnalyticsProvider-3HIPZXXN.js → AnalyticsProvider-HSJMHYBA.js} +6 -6
  5. package/dist/{ArticleViewTracker-3W5K63XV.js → ArticleViewTracker-XEA6ZY67.js} +7 -7
  6. package/dist/{BlocksPopup-VC5RQNUH.js → BlocksPopup-DUTOENMQ.js} +4 -4
  7. package/dist/{ChatWidget-ADJIZSDI.js → ChatWidget-PMVQTSEU.js} +6 -6
  8. package/dist/{FileField-JE2DVD3L.js → FileField-F7BG4XAZ.js} +3 -3
  9. package/dist/{FormSpotlight-KC62XBWL.js → FormSpotlight-RTPJPLQ3.js} +1 -1
  10. package/dist/{FormStage-XZD7EJBR.js → FormStage-UANGD66Z.js} +1 -1
  11. package/dist/{ManagedForm-TAFIWJ2B.js → ManagedForm-4AACRHEY.js} +7 -7
  12. package/dist/{ManagedNewsletterForm-5EHG2KP5.js → ManagedNewsletterForm-RWKFWZ72.js} +9 -9
  13. package/dist/{SignalCore-MXMF76SO.js → SignalCore-XULLPKPX.js} +5 -5
  14. package/dist/{SiteChat-KU3ML77D.js → SiteChat-P4CRBRJZ.js} +1 -1
  15. package/dist/{SiteDesignReporter-PUX3K532.js → SiteDesignReporter-QDVP4WMK.js} +5 -5
  16. package/dist/{SitePopups-IQ7FOHYF.js → SitePopups-US6VQN7X.js} +6 -6
  17. package/dist/{SitemapSync-JELTXYVM.js → SitemapSync-5FBRDGHG.js} +4 -4
  18. package/dist/_client/booking-widget.js +7 -5
  19. package/dist/affiliates/index.js +3 -3
  20. package/dist/analytics/index.js +6 -6
  21. package/dist/articles/index.js +1 -1
  22. package/dist/articles/server-ui.js +3 -3
  23. package/dist/articles/server.js +2 -2
  24. package/dist/chat/index.js +7 -7
  25. package/dist/{chunk-62AGFUP7.js → chunk-24NM64IV.js} +3 -3
  26. package/dist/{chunk-UAEAI7RS.js → chunk-27LYZVPP.js} +1 -1
  27. package/dist/{chunk-KBWRFZFP.js → chunk-2QFIYYMP.js} +1 -1
  28. package/dist/{chunk-TIP7B2IK.js → chunk-3PT6SO65.js} +3 -3
  29. package/dist/{chunk-VLDFUSTX.js → chunk-5BRHTBPO.js} +8 -2
  30. package/dist/{chunk-RA3N2VKJ.js → chunk-7HRYSLY2.js} +2 -2
  31. package/dist/{chunk-APTUCAXU.js → chunk-A7RZQI6H.js} +1 -1
  32. package/dist/{chunk-2UQ7AVYN.js → chunk-ANVHRT35.js} +1 -1
  33. package/dist/{chunk-2TPHS7KZ.js → chunk-CFSIGEUW.js} +1 -1
  34. package/dist/{chunk-XZ7I5E3I.js → chunk-DLTLXYOV.js} +1 -1
  35. package/dist/{chunk-AM7O5C4L.js → chunk-EQHGPB3J.js} +1 -1
  36. package/dist/{chunk-JL3JG4AH.js → chunk-FVXCQC7W.js} +1 -1
  37. package/dist/{chunk-D6K32TQM.js → chunk-GDQKDL3E.js} +2 -2
  38. package/dist/{chunk-BXKBRV6F.js → chunk-GLLFIE2R.js} +1 -1
  39. package/dist/{chunk-RVMN4QB7.js → chunk-GTVOB5RN.js} +1 -1
  40. package/dist/{chunk-2KTN6HBF.js → chunk-HNYECNCU.js} +2 -2
  41. package/dist/{chunk-NAU56CSZ.js → chunk-I4LMZNBN.js} +1 -1
  42. package/dist/{chunk-LKWLWD2L.js → chunk-ITQND6IB.js} +2 -2
  43. package/dist/{chunk-FBAHUETP.js → chunk-IXA7ZB6U.js} +1 -1
  44. package/dist/{chunk-PO2TRJPY.js → chunk-MTDVV5P3.js} +14 -7
  45. package/dist/{chunk-EVM4UCDI.js → chunk-N4ZCNYWF.js} +1 -1
  46. package/dist/{chunk-G5USOD3Z.js → chunk-OEA7U4HJ.js} +1 -1
  47. package/dist/{chunk-ZS4XW2PJ.js → chunk-OFQ3BU52.js} +1 -1
  48. package/dist/{chunk-H64ZZ76J.js → chunk-Q4Y3WIHE.js} +1 -1
  49. package/dist/{chunk-2VVC2HHY.js → chunk-T6U6J3QK.js} +1 -1
  50. package/dist/{chunk-53XFJAJI.js → chunk-UGZ3B5AK.js} +9 -9
  51. package/dist/{chunk-XVCUCZIF.js → chunk-YW3LNSBM.js} +1 -1
  52. package/dist/{chunk-7XSAO3B2.js → chunk-ZDUTXHM6.js} +2 -2
  53. package/dist/{chunk-2BZC7QMO.js → chunk-ZSU7KTIE.js} +1 -1
  54. package/dist/client/index.js +6 -6
  55. package/dist/config/index.d.ts +3 -1
  56. package/dist/config/index.js +1 -1
  57. package/dist/fleet/index.js +4 -4
  58. package/dist/forms/index.js +9 -9
  59. package/dist/forms/server.js +2 -2
  60. package/dist/images/index.js +4 -4
  61. package/dist/index.js +1 -1
  62. package/dist/layout/AiDiscoveryLinks.d.ts +4 -0
  63. package/dist/layout/SiteKitLayout.d.ts +5 -2
  64. package/dist/layout/client.js +9 -9
  65. package/dist/layout/index.d.ts +1 -0
  66. package/dist/layout/index.js +18 -12
  67. package/dist/llms/discovery-headers.d.ts +10 -2
  68. package/dist/llms/index.js +5 -5
  69. package/dist/maps/index.js +3 -3
  70. package/dist/mcp/sonor.js +8 -6
  71. package/dist/proxy/index.d.ts +3 -0
  72. package/dist/proxy/index.js +1 -1
  73. package/dist/revalidate/index.js +2 -2
  74. package/dist/runtime/index.js +3 -3
  75. package/dist/seo/client.js +4 -4
  76. package/dist/seo/index.js +4 -4
  77. package/dist/seo/llms.js +5 -5
  78. package/dist/seo/register-sitemap-cli.js +1 -1
  79. package/dist/seo/sitemap.js +2 -2
  80. package/dist/server/index.js +2 -2
  81. package/dist/shared/version.d.ts +1 -1
  82. package/dist/signal/index.js +2 -2
  83. package/dist/sitemap/index.js +2 -2
  84. package/dist/sync/api.d.ts +3 -0
  85. package/dist/sync/index.js +7 -5
  86. package/dist/website/images.js +4 -4
  87. package/dist/website/index.js +5 -5
  88. package/dist/website/popups.js +6 -6
  89. package/dist/{writeLLMsTxt-CH4GGLQ3.js → writeLLMsTxt-BAK5XMRR.js} +1 -1
  90. package/package.json +1 -1
  91. package/src/layout/README.md +33 -1
  92. package/src/llms/README.md +32 -53
  93. package/src/mcp/README.md +4 -3
  94. package/src/proxy/README.md +10 -3
  95. package/src/sync/README.md +8 -0
  96. package/dist/{chunk-ZKADJNR2.js → chunk-IPQKQEWI.js} +1 -1
  97. /package/dist/{chunk-E2TI6JFT.js → chunk-URZTBPZO.js} +0 -0
@@ -1,8 +1,8 @@
1
1
  import '../chunk-B7T2SFUF.js';
2
2
  export { readAnalyticsIdentity } from '../chunk-5ROTTMBL.js';
3
3
  import '../chunk-5TM3WPCI.js';
4
- export { sonorFetch } from '../chunk-D6K32TQM.js';
5
- import '../chunk-G5USOD3Z.js';
4
+ export { sonorFetch } from '../chunk-GDQKDL3E.js';
5
+ import '../chunk-OEA7U4HJ.js';
6
6
  export { DEFAULT_SONOR_API_URL, getClientApiConfig, readPublishedApiConfig } from '../chunk-W7OPEMGJ.js';
7
- import '../chunk-2TPHS7KZ.js';
7
+ import '../chunk-CFSIGEUW.js';
8
8
  import '../chunk-PKBMQBKP.js';
@@ -1,10 +1,10 @@
1
1
  'use client';
2
- export { SitemapSync } from '../chunk-AM7O5C4L.js';
2
+ export { SitemapSync } from '../chunk-EQHGPB3J.js';
3
3
  import '../chunk-YVKRYQRG.js';
4
4
  import '../chunk-DLM4FFNH.js';
5
5
  import '../chunk-EKBEOXTH.js';
6
- import '../chunk-D6K32TQM.js';
7
- import '../chunk-G5USOD3Z.js';
6
+ import '../chunk-GDQKDL3E.js';
7
+ import '../chunk-OEA7U4HJ.js';
8
8
  import '../chunk-W7OPEMGJ.js';
9
- import '../chunk-2TPHS7KZ.js';
9
+ import '../chunk-CFSIGEUW.js';
10
10
  import '../chunk-PKBMQBKP.js';
package/dist/seo/index.js CHANGED
@@ -2,7 +2,7 @@ export { ManagedNoScripts, ManagedScripts } from '../chunk-MVLMXC44.js';
2
2
  import { pickManagedLlmSchemaForJsonLd } from '../chunk-NZ4RXN3G.js';
3
3
  import { withoutSchemaPlaceholders } from '../chunk-VWWITFWM.js';
4
4
  import { safeJsonLd } from '../chunk-4KZ6W3ZH.js';
5
- export { SitemapSync } from '../chunk-AM7O5C4L.js';
5
+ export { SitemapSync } from '../chunk-EQHGPB3J.js';
6
6
  import { getManagedMetadata, mergeAlternates } from '../chunk-URJN75ZG.js';
7
7
  export { generateSitemap, getABVariant, getManagedMetadata, getManagedMetadataWithAB, getRedirect, getRobotsDirective, isIndexable } from '../chunk-URJN75ZG.js';
8
8
  import { getSchemaMarkups, getSEOPageData, getEntityEnhancedSchema, getFAQData, getInternalLinks, pruneSchemaTypes } from '../chunk-Y35BWW2C.js';
@@ -18,10 +18,10 @@ import '../chunk-FESKKJAS.js';
18
18
  import '../chunk-A4CC4ZG3.js';
19
19
  import '../chunk-DLM4FFNH.js';
20
20
  import '../chunk-EKBEOXTH.js';
21
- import '../chunk-D6K32TQM.js';
22
- import '../chunk-G5USOD3Z.js';
21
+ import '../chunk-GDQKDL3E.js';
22
+ import '../chunk-OEA7U4HJ.js';
23
23
  import '../chunk-W7OPEMGJ.js';
24
- import '../chunk-2TPHS7KZ.js';
24
+ import '../chunk-CFSIGEUW.js';
25
25
  import '../chunk-PKBMQBKP.js';
26
26
  import { Suspense } from 'react';
27
27
  import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
package/dist/seo/llms.js CHANGED
@@ -1,10 +1,10 @@
1
- export { createLLMsFullTxtHandler, createLLMsTxtHandler, formatSourcedFactsSection, llmsResponseHeaders } from '../chunk-ZS4XW2PJ.js';
2
- export { buildAiDiscoveryHeaders, wantsLlmsDiscoveryLink } from '../chunk-PO2TRJPY.js';
1
+ export { createLLMsFullTxtHandler, createLLMsTxtHandler, formatSourcedFactsSection, llmsResponseHeaders } from '../chunk-OFQ3BU52.js';
2
+ export { buildAiDiscoveryHeaders, wantsLlmsDiscoveryLink } from '../chunk-MTDVV5P3.js';
3
3
  export { AI_RETRIEVAL_CRAWLERS, AI_TRAINING_CRAWLERS, buildAiCrawlerRules, createRobotsTxtHandler } from '../chunk-QLTDFUJ7.js';
4
- export { LEGACY_PUBLICATION_PATH, SEO_REVALIDATION_MAX_BODY_BYTES, SEO_REVALIDATION_MAX_ITEMS, createLlmsRevalidateHandler, createSeoRevalidationHandler, parseSeoRevalidationPayload } from '../chunk-RVMN4QB7.js';
4
+ export { LEGACY_PUBLICATION_PATH, SEO_REVALIDATION_MAX_BODY_BYTES, SEO_REVALIDATION_MAX_ITEMS, createLlmsRevalidateHandler, createSeoRevalidationHandler, parseSeoRevalidationPayload } from '../chunk-GTVOB5RN.js';
5
5
  export { AEOBlock, AEOCitedContent, AEOClaim, AEOComparison, AEODefinition, AEOEntity, AEOProvenanceList, AEOStep, AEOSteps, AEOSummary, DEFAULT_SPEAKABLE_SELECTORS, SpeakableSchema, createSpeakableSchema, getSpeakableSelectorsForPage } from '../chunk-PSAG45YF.js';
6
6
  import '../chunk-XTRZGXB2.js';
7
- export { AGENT_ACCESS_HEADING, appendAgentAccessSection, describesMcp, detectMcpServer, formatAgentAccessSection, generateLLMsFullTxt, generateLLMsTxt, writeLLMsTxtToPublic } from '../chunk-E2TI6JFT.js';
7
+ export { AGENT_ACCESS_HEADING, appendAgentAccessSection, describesMcp, detectMcpServer, formatAgentAccessSection, generateLLMsFullTxt, generateLLMsTxt, writeLLMsTxtToPublic } from '../chunk-URZTBPZO.js';
8
8
  export { getBusinessInfo, getFAQItems, getLLMsData, getOptimizedLLMsTxt, getPageSummaries, getServices } from '../chunk-XA7Q2VQA.js';
9
9
  import '../chunk-5D7ZISUP.js';
10
10
  import '../chunk-4K735O3J.js';
@@ -16,5 +16,5 @@ import '../chunk-YVKRYQRG.js';
16
16
  import '../chunk-FESKKJAS.js';
17
17
  import '../chunk-A4CC4ZG3.js';
18
18
  import '../chunk-W7OPEMGJ.js';
19
- import '../chunk-2TPHS7KZ.js';
19
+ import '../chunk-CFSIGEUW.js';
20
20
  import '../chunk-PKBMQBKP.js';
@@ -458,7 +458,7 @@ async function registerLocalSitemap(options) {
458
458
  }
459
459
  if (options.writeLlms && result.success) {
460
460
  try {
461
- const { writeLLMsTxtToPublic } = await import('../writeLLMsTxt-CH4GGLQ3.js');
461
+ const { writeLLMsTxtToPublic } = await import('../writeLLMsTxt-BAK5XMRR.js');
462
462
  const written = await writeLLMsTxtToPublic({
463
463
  // Resolved here too: the sync's own `site` is scoped to the branch that
464
464
  // posts, and this runs on the skip path as well.
@@ -1,5 +1,5 @@
1
- export { createSitemap, getPortfolioPaths, syncSitemapToPortal } from '../chunk-FBAHUETP.js';
2
- import '../chunk-E2TI6JFT.js';
1
+ export { createSitemap, getPortfolioPaths, syncSitemapToPortal } from '../chunk-IXA7ZB6U.js';
2
+ import '../chunk-URZTBPZO.js';
3
3
  import '../chunk-XA7Q2VQA.js';
4
4
  import '../chunk-Z22QVHT4.js';
5
5
  import '../chunk-5D7ZISUP.js';
@@ -1,8 +1,8 @@
1
1
  import '../chunk-34ZYJTQR.js';
2
- export { resolveClientCredential } from '../chunk-2VVC2HHY.js';
2
+ export { resolveClientCredential } from '../chunk-T6U6J3QK.js';
3
3
  import '../chunk-UAYAJPEP.js';
4
4
  export { SITE_CACHE_TAGS } from '../chunk-6KU7STM3.js';
5
5
  export { isNextControlFlow, requireServerApiConfig, resolveApiOrigin, resolveServerApiConfig, serverApiFetch } from '../chunk-C7TLGL3R.js';
6
6
  import '../chunk-MH2DSGC6.js';
7
- import '../chunk-2TPHS7KZ.js';
7
+ import '../chunk-CFSIGEUW.js';
8
8
  import '../chunk-PKBMQBKP.js';
@@ -7,4 +7,4 @@
7
7
  * it matches package.json at publish time, and version.test.ts asserts it in
8
8
  * dev, so it can't silently drift.
9
9
  */
10
- export declare const SITE_KIT_VERSION = "8.5.0";
10
+ export declare const SITE_KIT_VERSION = "8.5.2";
@@ -1,6 +1,6 @@
1
1
  'use client';
2
- import { useSignalExperiment, useSignalEvent } from '../chunk-XVCUCZIF.js';
3
- export { SignalBridge, useSignal, useSignalConfig, useSignalEvent, useSignalExperiment, useSignalOutcome } from '../chunk-XVCUCZIF.js';
2
+ import { useSignalExperiment, useSignalEvent } from '../chunk-YW3LNSBM.js';
3
+ export { SignalBridge, useSignal, useSignalConfig, useSignalEvent, useSignalExperiment, useSignalOutcome } from '../chunk-YW3LNSBM.js';
4
4
  import '../chunk-PKBMQBKP.js';
5
5
  import React, { useEffect } from 'react';
6
6
  import { jsx, Fragment } from 'react/jsx-runtime';
@@ -1,5 +1,5 @@
1
- export { createSitemap, getPortfolioPaths, syncSitemapToPortal } from '../chunk-FBAHUETP.js';
2
- import '../chunk-E2TI6JFT.js';
1
+ export { createSitemap, getPortfolioPaths, syncSitemapToPortal } from '../chunk-IXA7ZB6U.js';
2
+ import '../chunk-URZTBPZO.js';
3
3
  import '../chunk-XA7Q2VQA.js';
4
4
  import '../chunk-Z22QVHT4.js';
5
5
  import '../chunk-5D7ZISUP.js';
@@ -50,6 +50,9 @@ export declare function createBooking(bookingData: {
50
50
  timezone?: string;
51
51
  holdId?: string;
52
52
  sessionId?: string;
53
+ /** Analytics identity, distinct from the booking hold's sessionId. */
54
+ visitorId?: string;
55
+ analyticsSessionId?: string;
53
56
  sourceUrl?: string;
54
57
  }, apiUrl?: string, apiKey?: string): Promise<BookingResult>;
55
58
  /**
@@ -1,7 +1,9 @@
1
- export { BookingWidget } from '../chunk-NAU56CSZ.js';
2
- export { createBooking, createSlotHold, detectTimezone, fetchAvailability, fetchAvailableDates, fetchBookingTypeDetails, fetchBookingTypes, formatDate, formatDuration, formatTime, prepareMeeting, releaseSlotHold } from '../chunk-VLDFUSTX.js';
3
- import '../chunk-D6K32TQM.js';
4
- import '../chunk-G5USOD3Z.js';
1
+ export { BookingWidget } from '../chunk-I4LMZNBN.js';
2
+ export { createBooking, createSlotHold, detectTimezone, fetchAvailability, fetchAvailableDates, fetchBookingTypeDetails, fetchBookingTypes, formatDate, formatDuration, formatTime, prepareMeeting, releaseSlotHold } from '../chunk-5BRHTBPO.js';
3
+ import '../chunk-5ROTTMBL.js';
4
+ import '../chunk-5TM3WPCI.js';
5
+ import '../chunk-GDQKDL3E.js';
6
+ import '../chunk-OEA7U4HJ.js';
5
7
  import '../chunk-W7OPEMGJ.js';
6
- import '../chunk-2TPHS7KZ.js';
8
+ import '../chunk-CFSIGEUW.js';
7
9
  import '../chunk-PKBMQBKP.js';
@@ -1,6 +1,6 @@
1
- export { ManagedImage, assignImageToSlot, clearImageSlot, fetchManagedImage, fetchManagedImages, listImageFiles, uploadImage } from '../chunk-H64ZZ76J.js';
1
+ export { ManagedImage, assignImageToSlot, clearImageSlot, fetchManagedImage, fetchManagedImages, listImageFiles, uploadImage } from '../chunk-Q4Y3WIHE.js';
2
2
  export { ManagedFavicon, getManagedFaviconUrl } from '../chunk-GW7GSBO7.js';
3
- import '../chunk-D6K32TQM.js';
4
- import '../chunk-G5USOD3Z.js';
5
- import '../chunk-2TPHS7KZ.js';
3
+ import '../chunk-GDQKDL3E.js';
4
+ import '../chunk-OEA7U4HJ.js';
5
+ import '../chunk-CFSIGEUW.js';
6
6
  import '../chunk-PKBMQBKP.js';
@@ -1,14 +1,14 @@
1
1
  'use client';
2
- export { SiteDesignReporter } from '../chunk-APTUCAXU.js';
3
- export { SITE_DESIGN_PATH, cleanFontStack, colorToHex, getSiteDesignTokens, measureSiteDesign, readDeclaredDesign, sendSiteDesign } from '../chunk-RA3N2VKJ.js';
2
+ export { SiteDesignReporter } from '../chunk-A7RZQI6H.js';
3
+ export { SITE_DESIGN_PATH, cleanFontStack, colorToHex, getSiteDesignTokens, measureSiteDesign, readDeclaredDesign, sendSiteDesign } from '../chunk-7HRYSLY2.js';
4
4
  export { DEFAULT_POPUP_TOKENS, PopupBlocks } from '../chunk-BF7TZYC3.js';
5
5
  import '../chunk-IHG36STL.js';
6
6
  import '../chunk-YC7ELZS3.js';
7
7
  import '../chunk-S22FSH7C.js';
8
8
  import '../chunk-DLM4FFNH.js';
9
9
  import '../chunk-EKBEOXTH.js';
10
- import '../chunk-D6K32TQM.js';
11
- import '../chunk-G5USOD3Z.js';
10
+ import '../chunk-GDQKDL3E.js';
11
+ import '../chunk-OEA7U4HJ.js';
12
12
  import '../chunk-W7OPEMGJ.js';
13
- import '../chunk-2TPHS7KZ.js';
13
+ import '../chunk-CFSIGEUW.js';
14
14
  import '../chunk-PKBMQBKP.js';
@@ -1,17 +1,17 @@
1
1
  'use client';
2
- export { SitePopups } from '../chunk-62AGFUP7.js';
2
+ export { SitePopups } from '../chunk-24NM64IV.js';
3
3
  import '../chunk-27FISYK4.js';
4
4
  export { DEFAULT_POPUP_TOKENS, PopupBlocks } from '../chunk-BF7TZYC3.js';
5
5
  import '../chunk-IHG36STL.js';
6
6
  import '../chunk-5ROTTMBL.js';
7
7
  import '../chunk-S22FSH7C.js';
8
- import '../chunk-ZKADJNR2.js';
9
- import '../chunk-5TM3WPCI.js';
8
+ import '../chunk-IPQKQEWI.js';
10
9
  import '../chunk-GJWI74ZZ.js';
10
+ import '../chunk-5TM3WPCI.js';
11
11
  import '../chunk-DLM4FFNH.js';
12
12
  import '../chunk-EKBEOXTH.js';
13
- import '../chunk-D6K32TQM.js';
14
- import '../chunk-G5USOD3Z.js';
13
+ import '../chunk-GDQKDL3E.js';
14
+ import '../chunk-OEA7U4HJ.js';
15
15
  import '../chunk-W7OPEMGJ.js';
16
- import '../chunk-2TPHS7KZ.js';
16
+ import '../chunk-CFSIGEUW.js';
17
17
  import '../chunk-PKBMQBKP.js';
@@ -1,4 +1,4 @@
1
- export { writeLLMsTxtToPublic } from './chunk-E2TI6JFT.js';
1
+ export { writeLLMsTxtToPublic } from './chunk-URZTBPZO.js';
2
2
  import './chunk-XA7Q2VQA.js';
3
3
  import './chunk-5D7ZISUP.js';
4
4
  import './chunk-4K735O3J.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sonordev/site-kit",
3
- "version": "8.5.0",
3
+ "version": "8.5.2",
4
4
  "type": "module",
5
5
  "packageManager": "pnpm@11.5.3",
6
6
  "description": "Sonor's Next.js foundation: SEO, analytics, forms, chat, booking, AI visibility and agent tools. Add @sonordev/press-kit for publications or @sonordev/commerce-kit for selling. Legacy article imports remain compatible in 8.x.",
@@ -40,7 +40,8 @@ interface SiteKitLayoutProps {
40
40
  favicon?: boolean // Default: true
41
41
  managedScripts?: boolean // Default: true
42
42
  debug?: boolean // Default: false
43
- showLlmsTxtFooterLink?: boolean // Default: false (prefer middleware discovery headers)
43
+ llmsDiscovery?: AiDiscoveryHeadersOptions | false // Default: false; static HTML links
44
+ showLlmsTxtFooterLink?: boolean // Default: false (prefer llmsDiscovery)
44
45
  speculation?: boolean | { mode?: 'prerender' | 'prefetch'; exclude?: string[] } // Default: false
45
46
  }
46
47
  ```
@@ -67,3 +68,34 @@ Since 4.0.0 none of these wrap your page. `{children}` renders first and every m
67
68
  ## Note
68
69
 
69
70
  `SiteKitProvider` was **removed in 4.0.0**. It wrapped the whole tree client-side, which broke RSC. Migrate an older layout with `npx sonor-setup codemod --only provider-to-layout --write`.
71
+
72
+ ## AI discovery without changing preload headers
73
+
74
+ ```tsx
75
+ <SiteKitLayout llmsDiscovery={{ siteUrl: 'https://example.com', mcpServerCard: true }}>
76
+ {children}
77
+ </SiteKitLayout>
78
+ ```
79
+
80
+ This emits server-rendered `<link rel="describedby">` for `/llms.txt` and an optional
81
+ `<link rel="service-desc">` for the public MCP server card. React places them in
82
+ `<head>`. No client JavaScript, request reads, extra fetches, or changes to Next's
83
+ font and stylesheet preload headers are needed.
84
+
85
+ For a separate public layout, import `AiDiscoveryLinks` from
86
+ `@sonordev/site-kit/layout` and render it with the same props. Both forms accept
87
+ `AiDiscoveryHeadersOptions`: `siteUrl`, optional `llmsPath`, `mcpServerCard`
88
+ (`true` or a custom URL/path), `languageAlternates`, and `includeTypeParameter`.
89
+ They share URL construction and alternate filtering with `buildAiDiscoveryHeaders`.
90
+
91
+ Remove `llmsDiscovery` from `createProxy` and `llmsTxtDiscoveryLink` from
92
+ `withSiteKitConfig` when moving to HTML discovery. Those HTTP options remain
93
+ compatible but are deprecated: host adapters can replace Next's preload `Link`
94
+ header with the discovery value. Appending at the proxy cannot reliably merge
95
+ headers generated later by the framework.
96
+
97
+ Layout-level discovery links name only the configured **public resources**, even
98
+ on private child routes; they don't include the current URL, preview token, or
99
+ article content. Private preview cache, indexing, and reporting rules stay in
100
+ place. If private pages must contain no discovery tags at all, render
101
+ `AiDiscoveryLinks` in a public route-group layout instead of the root layout.
@@ -18,7 +18,7 @@ site-kit (npm: @sonordev/site-kit/llms)
18
18
  ├─ generateLLMsTxt() ← builds markdown from Sonor data
19
19
  ├─ createLLMsTxtHandler() ← zero-config Next.js route handler
20
20
  ├─ buildAiDiscoveryHeaders() ← Link header for crawler discovery
21
- ├─ createProxy({ llmsDiscovery }) ← sends the Link header from proxy.ts
21
+ ├─ AiDiscoveryLinks (layout entry) ← static public-resource links in <head>
22
22
  ├─ buildAiCrawlerRules() / createRobotsTxtHandler() ← robots.txt for AI crawlers
23
23
  ├─ writeLLMsTxtToPublic() ← build-time static file generation
24
24
  ├─ createLlmsRevalidateHandler() ← on-demand ISR cache bust
@@ -30,7 +30,7 @@ site-kit (npm: @sonordev/site-kit/llms)
30
30
  Next.js Site
31
31
  ├─ /llms.txt ← route handler (dynamic or static)
32
32
  ├─ /llms-full.txt ← extended version (more pages/FAQ)
33
- ├─ Link header ← rel="describedby" on all HTML responses
33
+ ├─ HTML links ← rel="describedby" for public AI resources
34
34
  ├─ robots.txt ← allows AI crawlers to access /llms.txt
35
35
  └─ JSON-LD in <head> ← managed_llm_schema per page
36
36
  ```
@@ -75,67 +75,45 @@ Both handlers:
75
75
  - Never read the incoming `Request`, so the route prerenders statically (○) instead of
76
76
  bailing out with a "Dynamic server usage" error during `next build`
77
77
 
78
- ### Step 2: Discovery header (required)
78
+ ### Step 2: Discovery links (required)
79
79
 
80
- **Proxy (recommended)**
80
+ **HTML discovery (recommended)**
81
81
 
82
- ```ts
83
- // proxy.ts
84
- import { createProxy } from '@sonordev/site-kit/proxy'
85
-
86
- export default createProxy({
87
- llmsDiscovery: { siteUrl: 'https://example.com' },
88
- })
82
+ ```tsx
83
+ // app/layout.tsx
84
+ import { SiteKitLayout } from '@sonordev/site-kit/layout'
89
85
 
90
- // Inlined: an imported `config.matcher` is a build error. See the proxy README.
91
- export const config = {
92
- matcher: [
93
- '/((?!_next/static|_next/image|favicon\\.ico|.*\\.(?:ico|png|jpg|jpeg|gif|webp|svg|woff2?)$).*)',
94
- ],
95
- }
86
+ <SiteKitLayout llmsDiscovery={{ siteUrl: 'https://example.com', mcpServerCard: true }}>
87
+ {children}
88
+ </SiteKitLayout>
96
89
  ```
97
90
 
98
- This adds `Link: <https://example.com/llms.txt>; rel="describedby"; type="text/markdown"`
99
- to every request that could be for a page: GET or HEAD, with an Accept header
100
- that allows HTML or no Accept header at all. Requests with no Accept header
101
- count because that's how curl and many crawlers and AI fetchers ask, and
102
- they're who the header is for (they used to be skipped). Skipped:
103
- file-like paths (`/llms.txt`, `/sitemap.xml`), `/api/` routes, Accept headers
104
- that name only non-HTML types, and Next's RSC navigation requests. The rule is
105
- `wantsLlmsDiscoveryLink`, exported from `@sonordev/site-kit/llms`.
106
-
107
- **No proxy? next.config**
108
-
109
- ```ts
110
- // next.config.ts
111
- import { withSiteKitConfig } from '@sonordev/site-kit/config'
112
-
113
- export default withSiteKitConfig({ llmsTxtDiscoveryLink: true })
114
- ```
91
+ This renders public-resource links in the HTML head without changing Next's
92
+ resource preload headers. You can also render `AiDiscoveryLinks` from the same
93
+ entry in a public layout. See [layout discovery](../layout/README.md#ai-discovery-without-changing-preload-headers)
94
+ for options and private-route semantics.
115
95
 
116
- This sends the same header from next.config `headers()`, on every route. It
117
- reads the origin from `NEXT_PUBLIC_SITE_URL`. If you also set
118
- `nextConfig.headers`, yours replaces the helper's, so merge
119
- `buildAiDiscoveryHeaders({ siteUrl })` into it yourself.
96
+ **HTTP compatibility**
120
97
 
121
- **Not from the root layout.** Older versions of this README showed
122
- `export async function headers()` in `app/layout.tsx`. That isn't a Next API:
123
- `headers()` is a next.config option, and exported from a layout it's an
124
- ordinary function nobody calls, so it sends nothing. `sonor-setup geo` fails a
125
- site wired that way and says so. Move it to the proxy.
98
+ `buildAiDiscoveryHeaders` remains available where you control the final response
99
+ and can merge all `Link` values. Proxy `llmsDiscovery` and next.config
100
+ `llmsTxtDiscoveryLink` still work, but are deprecated: some host adapters replace
101
+ Next's font/style preload headers when either option sets `Link`. Remove that
102
+ configuration when moving to HTML discovery; changing `set` to `append` in the
103
+ proxy doesn't merge headers generated downstream.
126
104
 
127
- `buildAiDiscoveryHeaders` builds the header value for either place, including
128
- multilingual alternates:
105
+ Both renderers use the same options, including multilingual alternates:
129
106
 
130
- ```ts
131
- buildAiDiscoveryHeaders({
132
- siteUrl: 'https://example.com',
133
- languageAlternates: [
134
- { hreflang: 'fr', href: 'https://example.com/fr/llms.txt' },
135
- ],
136
- })
107
+ ```tsx
108
+ <AiDiscoveryLinks
109
+ siteUrl="https://example.com"
110
+ languageAlternates={[{ hreflang: 'fr', href: 'https://example.com/fr/llms.txt' }]}
111
+ />
137
112
  ```
138
113
 
114
+ A layout export named `headers()` isn't a Next API and sends no headers. Render
115
+ the links instead; `sonor-setup geo` recognizes both supported discovery forms.
116
+
139
117
  ### Step 3: robots.txt (required)
140
118
 
141
119
  Name the AI crawlers explicitly with the kit's curated lists rather than a
@@ -726,7 +704,8 @@ import {
726
704
  createLLMsTxtHandler, createLLMsFullTxtHandler, llmsResponseHeaders,
727
705
  } from '@sonordev/site-kit/llms'
728
706
 
729
- // Discovery
707
+ // Discovery: HTML for Next layouts, HTTP for controlled response merging
708
+ import { AiDiscoveryLinks } from '@sonordev/site-kit/layout'
730
709
  import { buildAiDiscoveryHeaders } from '@sonordev/site-kit/llms'
731
710
 
732
711
  // API data fetchers (React cache()-wrapped)
package/src/mcp/README.md CHANGED
@@ -136,8 +136,9 @@ tool keeps failing.
136
136
 
137
137
  **Discovery.** llms.txt gains an "Agent access" section pointing at the
138
138
  endpoint and card (automatic in the build-time file once `/api/mcp` exists),
139
- and `createProxy({ llmsDiscovery: { siteUrl, mcpServerCard: true } })` adds
140
- `Link: <.../.well-known/mcp-server-card>; rel="service-desc"`.
139
+ and `SiteKitLayout llmsDiscovery={{ siteUrl, mcpServerCard: true }}` adds an HTML
140
+ `<link rel="service-desc">` to `/.well-known/mcp-server-card`, preserving Next's
141
+ resource preload headers. `AiDiscoveryLinks` from the layout entry works on its own too.
141
142
 
142
143
  ### A custom MCP server is left alone
143
144
 
@@ -151,7 +152,7 @@ hands off:
151
152
  | `npx sonor-setup mcp` | writes the wiring (skips files that exist) | **writes nothing**, not even missing files, and says what's opt-in (`--force` replaces it, knowingly) |
152
153
  | llms.txt "Agent access" section | added at build | **not added** (`writeLLMsTxtToPublic({ mcp: true })` opts in) |
153
154
  | Tool-call reporting to Sonor | `onToolCall: reportToolCallsToSonor()` | the same line, if you want it; nothing without it |
154
- | Proxy `service-desc` link | `llmsDiscovery.mcpServerCard: true` | the same, opt-in |
155
+ | HTML `service-desc` link | `SiteKitLayout` with `llmsDiscovery.mcpServerCard: true` | the same, opt-in |
155
156
  | Mixing in built-in tools | n/a | `tools: [...sonorMcpTools({ businessName, exclude }), ...yourTools]` |
156
157
 
157
158
  "Built-in" means the site's `/api/mcp` server comes from `sonorMcpServer` or
@@ -1,6 +1,6 @@
1
1
  # Proxy — `@sonordev/site-kit/proxy`
2
2
 
3
- Composable Next.js Proxy factory. Zero-config redirects + security headers. Opt-in AI discovery headers.
3
+ Composable Next.js Proxy factory. Zero-config redirects + security headers. Legacy opt-in AI discovery headers remain supported.
4
4
 
5
5
  Next 16 renamed the `middleware` file convention to `proxy`. This module is
6
6
  also served on `@sonordev/site-kit/middleware`, with `createMiddleware` as an
@@ -30,13 +30,20 @@ With options:
30
30
  ```ts
31
31
  export default createProxy({
32
32
  securityHeaders: { frameAncestors: ["'self'", 'https://partner.example.com'] },
33
- llmsDiscovery: { siteUrl: 'https://example.com' },
34
33
  before: (req) => {
35
34
  // Custom auth check, geolocation, etc.
36
35
  },
37
36
  })
38
37
  ```
39
38
 
39
+ ## AI discovery
40
+
41
+ Use `SiteKitLayout llmsDiscovery={{ siteUrl }}` or `AiDiscoveryLinks` from
42
+ `@sonordev/site-kit/layout`. They render HTML links while leaving Next's font and
43
+ stylesheet preload headers intact. The proxy's `llmsDiscovery` option remains
44
+ compatible but is deprecated: host adapters can replace downstream `Link`
45
+ headers, even if a proxy uses `append`. Remove the proxy option when migrating.
46
+
40
47
  ## The matcher must be inlined
41
48
 
42
49
  **`export const config = siteKitMatcher` is a build error.** Next statically
@@ -74,7 +81,7 @@ Two Next 16 traps to know:
74
81
  interface SiteKitProxyConfig {
75
82
  redirects?: boolean | RedirectConfig // Sonor-managed redirects (default: true)
76
83
  securityHeaders?: boolean | SecurityHeadersConfig // Security headers (default: true)
77
- llmsDiscovery?: LlmsDiscoveryConfig | false // AI crawler discovery header
84
+ llmsDiscovery?: LlmsDiscoveryConfig | false // Deprecated; use layout HTML discovery
78
85
  identity?: boolean | IdentityConfig // Opt-in edge identity pass
79
86
 
80
87
  before?: (req: NextRequest) => NextResponse | undefined | Promise<NextResponse | undefined>
@@ -112,6 +112,14 @@ Each booking gives the guest one calendar invitation, and `invitation` says who
112
112
 
113
113
  APIs older than the field don't send it; treat a missing `invitation` like `'sonor'`. `calendarLinks` is still sent for every booking so older widgets keep working. If you build your own success screen with `createBooking`, check `invitation` before you render `calendarLinks`.
114
114
 
115
+ `createBooking` attaches the browser's existing analytics `visitorId` and
116
+ `analyticsSessionId` automatically, including for custom booking screens. Sonor
117
+ links that journey to the contact resolved from the accepted booking. These IDs
118
+ are separate from `sessionId`, which owns a slot hold; don't replace a hold's
119
+ session with the analytics session. With analytics disabled, no tracking IDs or
120
+ visits are invented. Custom callers can pass their existing analytics IDs
121
+ explicitly. The contact identity is resolved by Sonor, never supplied by the browser.
122
+
115
123
  ## Features
116
124
 
117
125
  - Automatic timezone detection
@@ -1,6 +1,6 @@
1
1
  'use client';
2
- import { VISITOR_ID_KEY, memoryIdentity, SESSION_ID_KEY, SESSION_TIME_KEY } from './chunk-5TM3WPCI.js';
3
2
  import { uuid } from './chunk-GJWI74ZZ.js';
3
+ import { VISITOR_ID_KEY, memoryIdentity, SESSION_ID_KEY, SESSION_TIME_KEY } from './chunk-5TM3WPCI.js';
4
4
  import { useState } from 'react';
5
5
 
6
6
  function getOrCreateVisitorId() {
File without changes