@riverbankcms/sdk 0.141.0 → 0.142.0

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 (98) hide show
  1. package/dist/{PreviewEditorSidebar-Q-fy9GYw.mjs → PreviewEditorSidebar-Dk6Dt11f.mjs} +24 -15
  2. package/dist/{PreviewEditorUI-LYGzgk85.mjs → PreviewEditorUI-D6EQTsCA.mjs} +3 -3
  3. package/dist/{PreviewQueryProvider-CN0ewic5.mjs → PreviewQueryProvider-CC-EPkyQ.mjs} +1 -1
  4. package/dist/{SdkPreviewModeRuntime-CoPYI5Jq.mjs → SdkPreviewModeRuntime-DH1n4ytY.mjs} +16 -11
  5. package/dist/{SiteChromeCustomizeContext-D8LePX8x.mjs → SiteChromeCustomizeContext-DunIzY0K.mjs} +117 -21
  6. package/dist/_dts/api/src/billing.d.ts +6 -1
  7. package/dist/_dts/api/src/bookingConfig.d.ts +1 -1
  8. package/dist/_dts/api/src/commercePortalEndpoints.d.ts +2 -2
  9. package/dist/_dts/api/src/endpoints.d.ts +0 -27
  10. package/dist/_dts/api/src/index.d.ts +1 -1
  11. package/dist/_dts/api/src/publicBookingService.d.ts +1 -0
  12. package/dist/_dts/api/src/sdkConfig/layout.d.ts +13 -0
  13. package/dist/_dts/api/src/sdkContracts.d.ts +3 -8
  14. package/dist/_dts/api/src/sitePlatformEndpoints.d.ts +1 -31
  15. package/dist/_dts/api/src/siteRuntimeEndpoints.d.ts +6 -1
  16. package/dist/_dts/billing/src/site-arrangements.d.ts +9 -5
  17. package/dist/_dts/blocks/src/system/blocks/events/shared/schemas.d.ts +56 -0
  18. package/dist/_dts/blocks/src/system/blocks/events/shared/types.d.ts +8 -0
  19. package/dist/_dts/blocks/src/system/runtime/nodes/events/shared/eventCollectionContract.d.ts +56 -0
  20. package/dist/_dts/commerce/src/purchase/stripeCommissionMetadata.d.ts +1 -2
  21. package/dist/_dts/db/src/generated/supabase/database.types.d.ts +3099 -3122
  22. package/dist/_dts/editor-blocks/src/block-editor/ColourFieldOptionsProvider.d.ts +7 -0
  23. package/dist/_dts/editor-blocks/src/block-editor/colourFieldVisibility.d.ts +7 -0
  24. package/dist/_dts/editor-blocks/src/block-editor/preparedManifest.d.ts +2 -0
  25. package/dist/_dts/editor-blocks/src/index.d.ts +1 -0
  26. package/dist/_dts/preview-next/src/client/preview/PreviewEditorSidebar.d.ts +2 -2
  27. package/dist/_dts/preview-next/src/client/preview/PreviewFooterEditorPanel.d.ts +3 -6
  28. package/dist/_dts/preview-next/src/client/preview/PreviewShell.d.ts +2 -2
  29. package/dist/_dts/preview-next/src/client/preview/PreviewShellLayout.d.ts +2 -2
  30. package/dist/_dts/preview-next/src/client/preview/footerInspection.d.ts +16 -0
  31. package/dist/_dts/preview-next/src/client/preview/sdkConfig.d.ts +6 -0
  32. package/dist/_dts/sdk/src/config/types.d.ts +2 -18
  33. package/dist/_dts/sdk/src/config/validation.d.ts +6 -0
  34. package/dist/_dts/sdk/src/public-api/contracts.d.ts +3 -0
  35. package/dist/_dts/sdk/src/version.d.ts +1 -1
  36. package/dist/_dts/theme-core/src/footer/mode.d.ts +10 -1
  37. package/dist/_dts/theme-core/src/schema.d.ts +1 -7
  38. package/dist/_dts/theme-core/src/site-styles/effectivePageDesign.d.ts +32 -0
  39. package/dist/_dts/theme-core/src/site-styles/index.d.ts +1 -0
  40. package/dist/client/{BookingConsentAgreement-xJeYNdnb.mjs → BookingConsentAgreement-CnJeq3_r.mjs} +2 -2
  41. package/dist/client/{DiscountCodeDisclosure-DdT6uzl9.mjs → DiscountCodeDisclosure-BINEO6J9.mjs} +1 -1
  42. package/dist/client/{EventCombined.client-Cp28uYuM.mjs → EventCombined.client-srxNQ6sZ.mjs} +5 -5
  43. package/dist/client/{EventListing.client-CD6AJsMr.mjs → EventListing.client-DbyVyGkX.mjs} +2 -2
  44. package/dist/client/{LeafletStaticMap-DBsAi9-e.mjs → LeafletStaticMap-B-wpijzL.mjs} +1 -1
  45. package/dist/client/{accordion-6dwbOKYR.mjs → accordion-B-iUXU7n.mjs} +1 -1
  46. package/dist/client/{bookingForm-CZE9_qPQ.mjs → bookingForm-BXYPke5q.mjs} +5 -5
  47. package/dist/client/bookings.mjs +19 -9
  48. package/dist/client/{carousel-7VHGQARz.mjs → carousel-Cr4aj63H.mjs} +1 -1
  49. package/dist/client/{cart-Qg_mvQhh.mjs → cart-DibP9WWa.mjs} +3 -3
  50. package/dist/client/{checkout-D84rpgdr.mjs → checkout-CrSBVnL8.mjs} +3 -3
  51. package/dist/client/client.mjs +42 -54
  52. package/dist/client/{context-Ctp3T0Wr.mjs → context-Ces-AgdR.mjs} +1 -1
  53. package/dist/client/{dates-DJKFcI_N.mjs → dates-BXyNeNhB.mjs} +2 -2
  54. package/dist/client/{eventCalendar-CK31z3vs.mjs → eventCalendar-HwpPeqrH.mjs} +7 -7
  55. package/dist/client/{eventCombined-DiXd-ewn.mjs → eventCombined-BpFUkuEI.mjs} +3 -3
  56. package/dist/client/{eventDetails-CTRgt2DK.mjs → eventDetails-DK_agiWy.mjs} +4 -4
  57. package/dist/client/{eventListing-Dy9vi_j_.mjs → eventListing-DhzHqP1c.mjs} +3 -3
  58. package/dist/client/{eventRegistration-CnalYMr2.mjs → eventRegistration-BdQ_Dn2d.mjs} +6 -7
  59. package/dist/client/{form-eUiMveTT.mjs → form-B1frcuzy.mjs} +2 -2
  60. package/dist/client/{headerSection-Dy9kQpB1.mjs → headerSection-CT5z460s.mjs} +2 -2
  61. package/dist/client/hooks.mjs +27 -13
  62. package/dist/client/{locationMap-DalCmWU0.mjs → locationMap-CIQXB9i2.mjs} +2 -2
  63. package/dist/client/{newsletterForm-SDDPvhS0.mjs → newsletterForm-BYNYZSes.mjs} +2 -2
  64. package/dist/client/{pricing-OcMz4SnX.mjs → pricing-CbTlAsmt.mjs} +1 -1
  65. package/dist/client/{productDetail-BQrgHElM.mjs → productDetail-CR7Z3yjS.mjs} +3 -3
  66. package/dist/client/{productList-OnPn_UJj.mjs → productList-DXj00vzR.mjs} +3 -3
  67. package/dist/client/{propsDecoder-zBdsnS-N.mjs → propsDecoder-DiLiBdek.mjs} +19 -8
  68. package/dist/client/rendering/client.mjs +30 -11
  69. package/dist/client/rendering/islands.mjs +17 -17
  70. package/dist/client/rendering.mjs +85 -57
  71. package/dist/client/{scrollToBlock-BNM4Ob2Y.mjs → scrollToBlock-CrcbBf0h.mjs} +1 -1
  72. package/dist/client/{shop-Bv1fPTwQ.mjs → shop-DgqiB_1b.mjs} +6 -6
  73. package/dist/client/{shop-commerce-D4KNGaW8.mjs → shop-commerce-D_J781in.mjs} +5 -5
  74. package/dist/client/{shop-commerce-store-2N5EV0Rc.mjs → shop-commerce-store-PGUbDwqe.mjs} +1 -1
  75. package/dist/client/{shopShared-DvJGdHTV.mjs → shopShared-C_Bb2zwG.mjs} +3 -3
  76. package/dist/client/{useEventFilters-BBBvGDHQ.mjs → useEventFilters-CM17Xpr1.mjs} +5 -5
  77. package/dist/preview-next/before-render.mjs +0 -37
  78. package/dist/preview-next/client/runtime.mjs +4 -4
  79. package/dist/preview-next/keepAlive.mjs +0 -37
  80. package/dist/preview-next/middleware.mjs +0 -37
  81. package/dist/{previewAuthStore-Gjb6r6vz.mjs → previewAuthStore-oVttoRDO.mjs} +0 -37
  82. package/dist/{sdk-runtime-Defnbfzw.mjs → sdk-runtime-DhmuRhIX.mjs} +2 -2
  83. package/dist/{separator-CZXO3Sb0.mjs → separator-C3hlg9LH.mjs} +1 -1
  84. package/dist/server/components.mjs +68 -49
  85. package/dist/server/config-validation.mjs +31 -14
  86. package/dist/server/config.mjs +31 -14
  87. package/dist/server/data.mjs +27 -13
  88. package/dist/server/index.mjs +1 -38
  89. package/dist/server/next.mjs +28 -51
  90. package/dist/server/page-converter.mjs +19 -8
  91. package/dist/server/prebuild.mjs +1 -1
  92. package/dist/server/rendering/server.mjs +68 -51
  93. package/dist/server/rendering.mjs +68 -49
  94. package/dist/server/routing.mjs +40 -17
  95. package/dist/server/server.mjs +28 -51
  96. package/dist/server/theme-bridge.mjs +10 -8
  97. package/dist/server/theme.mjs +10 -8
  98. package/package.json +1 -1
@@ -0,0 +1,13 @@
1
+ import type { FooterMode } from '../../../theme-core/src/footer/mode';
2
+ /** SDK-owned footer implementation and source-controlled content seed. */
3
+ export interface SdkSiteLayoutConfig {
4
+ /** Riverbank footer surfaces used by the site; custom callbacks keep precedence. */
5
+ footerMode?: FooterMode;
6
+ /** Global footer blocks synced by push-config, with dashboard content editing. */
7
+ footerBlocks?: Array<{
8
+ /** Stable source identifier, not a CMS block UUID. */
9
+ id?: string;
10
+ kind: string;
11
+ content?: Record<string, unknown>;
12
+ }>;
13
+ }
@@ -1,3 +1,5 @@
1
+ import type { SdkSiteLayoutConfig } from './sdkConfig/layout';
2
+ export type { SdkSiteLayoutConfig } from './sdkConfig/layout';
1
3
  import type { BlockContentSource, BlockContentSourceKind, FieldDefinition, FieldDefinitionInput, SdkCustomBlock, SdkCustomBlockInput, Theme } from '../../blocks/src/index';
2
4
  import type { ContentTypeSchema } from '../../content-model/src/index';
3
5
  import type { EventPreset, FooterCompositionV1, RichTextDoc } from '../../core/src/index';
@@ -81,13 +83,6 @@ export interface SdkBlockFieldConfig {
81
83
  * Note: This mirrors BlockFieldOptionsMap from @riverbankcms/sdk/config for use in API responses.
82
84
  */
83
85
  export type SdkBlockFieldOptionsMap = Record<string, Record<string, SdkBlockFieldConfig>>;
84
- export interface SdkSiteLayoutConfig {
85
- footerBlocks?: Array<{
86
- id?: string;
87
- kind: string;
88
- content?: Record<string, unknown>;
89
- }>;
90
- }
91
86
  export interface SdkContentTypeTemplateConfig {
92
87
  blocks: unknown[];
93
88
  }
@@ -228,6 +223,7 @@ export declare function formatIgnoredDocumentSyncSectionWarning(section: Ignored
228
223
  export type SyncFooterBlocksResult = {
229
224
  updated: boolean;
230
225
  skipped: boolean;
226
+ reason?: 'unchanged' | 'preserved-dashboard-edit' | 'mode-only';
231
227
  };
232
228
  export type SdkConfigSyncResult = {
233
229
  success: boolean;
@@ -694,7 +690,6 @@ export interface SdkCapabilityCatalogLink {
694
690
  export interface SdkCapabilitiesResponse {
695
691
  apiVersion: string;
696
692
  catalogs: {
697
- theme: SdkCapabilityCatalogLink;
698
693
  blocks: SdkCapabilityCatalogLink;
699
694
  contentTypes: SdkCapabilityCatalogLink;
700
695
  };
@@ -1,4 +1,3 @@
1
- import type { SiteCommandOf } from '@riverbankcms/site-commands';
2
1
  import type { AppearancePresetId } from '../../theme-core/src/site-styles/index';
3
2
  import type { APIEndpoint } from './apiEndpointTypes';
4
3
  import type { AdminCreateSiteRequest, AdminCreateSiteResponse, AdminDeletePriceOverrideRequest, AdminDeletePriceOverrideResponse, AdminDeleteSiteResponse, AdminGetPriceOverrideQuery, AdminGetPriceOverrideResponse, AdminUpsertPriceOverrideRequest, AdminUpsertPriceOverrideResponse } from './accessAdmin';
@@ -8,9 +7,7 @@ import type { CheckRedirectQuery, CheckRedirectResponse, CreateRedirectRuleReque
8
7
  import type { CreateManagementKeyRequest, CreateManagementKeyResponse, CreateSiteApiKeyRequest, CreateSiteApiKeyResponse, CreateSitePreviewKeyRequest, CreateSitePreviewKeyResponse, CreateWebhookRequest, CreateWebhookResponse, DeleteBackupUploadRequest, DeleteBackupUploadResponse, DeleteWebhookResponse, GetSiteApiKeyAccessLogsResponse, ListSitePreviewKeysResponse, GetWebhookResponse, ImportBackupAsNewSiteRequest, ImportBackupAsNewSiteResponse, ImportSiteBackupRequest, ListManagementKeysResponse, ListSiteApiKeysResponse, ListWebhooksResponse, RevokeManagementKeyRequest, RevokeManagementKeyResponse, RevokeSiteApiKeyResponse, SdkDeploymentHealthResponse, SetupSdkDeploymentRevalidationWebhookRequest, SetupSdkDeploymentRevalidationWebhookResponse, SetupSdkRevalidationWebhookRequest, SetupSdkRevalidationWebhookResponse, UpdateWebhookRequest, UpdateWebhookResponse, BackupImportResponse, BackupPreviewRequest, BackupPreviewResponse, CreateBackupUploadUrlRequest, CreateBackupUploadUrlResponse } from './siteInfrastructure';
9
8
  import type { GetSiteInspirationAnalysisResponse, ListSiteInspirationAnalysesResponse } from './siteGeneration';
10
9
  import type { ListGscPropertiesAdminResponse, AuthStatusResponse, CronAppointmentRemindersResponse, CronBillingStatusResponse, CronEventFeedbackEmailsResponse, CronEventOccurrencesResponse, CronEventRemindersResponse, CronMediaJobsQuery, CronMediaJobsResponse, CronNewsletterSendResponse, CronPaymentReconciliationResponse, CronSeoIngestResponse, CronWaitlistExpiryResponse } from './siteOperations';
11
- import type { ApplySiteStyleSelectionBody, ApplySiteStyleSelectionResponse } from './siteRuntimeEndpoints';
12
- import type { ManagementMediaAsset, MediaResolveResponse, PushSdkConfigRequest, PushSdkConfigResponse, SdkAddEventOccurrenceRequest, SdkBackfillIdentifiersResult, SdkEventOccurrenceResponse, SdkGetEntryResponse, SdkGetEventCategoryResponse, SdkGetEventResponse, SdkGetFormResponse, SdkGetPageBlockResponse, SdkPatchPageBlockBody, SdkPatchPageBlockResponse, SdkGetVenueResponse, SdkListEntriesResponse, SdkListEventCategoriesResponse, SdkListEventOccurrencesResponse, SdkListEventsResponse, SdkListFormsResponse, SdkListVenuesResponse, SdkMediaFinalizeUploadResponse, SdkMediaDeleteApplyResponse, SdkMediaDeletePreviewResponse, SdkMediaDownloadResponse, SdkMediaListResponse, SdkMediaUploadUrlResponse, SdkPageResponse, SdkEntryUpsertSlotBlock, SdkPublishOrUnpublishEntryResponse, SdkPullContentTypesResponse, SdkCatalogThemeResponse, SdkCatalogBlocksResponse, SdkCatalogContentTypesResponse, SdkCapabilitiesResponse, SdkCommandApplicationResult, SdkConfigureBookingVerticalRequest, SdkConfigureBookingVerticalResponse, SdkDemoContentResponse, SdkDeleteResponse, SdkPullEntriesAllResponse, SdkPullEntriesByTypeResponse, SdkPullEntriesResponse, SdkPullEventCategoriesResponse, SdkPullEventsResponse, SdkPullFooterResponse, SdkPullFormSchema, SdkPullFormsResponse, SdkPullFormSettings, SdkPullDraftsResponse, SdkPullNavigationResponse, SdkPullPagesResponse, SdkPullSettings, SdkPullSettingsResponse, SdkPullSiteInfoResponse, SdkPullThemeResponse, SdkPullVenue, SdkPullVenuesResponse, SdkUpdateSettingsResponse, SdkUpdateEventOccurrenceRequest, SdkUpsertBlockResponse, SdkUpsertEntryResponse, SdkUpsertPageResponse, SdkUpsertEventCategoryResponse, SdkUpsertEventResponse, SdkUpsertFooterResponse, SdkUpsertFormResponse, SdkUpsertNavigationMenuResponse, SdkUpsertThemeResponse, SdkUpsertVenueResponse } from './sdkContracts';
13
- import type { SdkThemeWireWithoutHeader } from './sdkThemeWire';
10
+ import type { ManagementMediaAsset, MediaResolveResponse, PushSdkConfigRequest, PushSdkConfigResponse, SdkAddEventOccurrenceRequest, SdkBackfillIdentifiersResult, SdkEventOccurrenceResponse, SdkGetEntryResponse, SdkGetEventCategoryResponse, SdkGetEventResponse, SdkGetFormResponse, SdkGetPageBlockResponse, SdkPatchPageBlockBody, SdkPatchPageBlockResponse, SdkGetVenueResponse, SdkListEntriesResponse, SdkListEventCategoriesResponse, SdkListEventOccurrencesResponse, SdkListEventsResponse, SdkListFormsResponse, SdkListVenuesResponse, SdkMediaFinalizeUploadResponse, SdkMediaDeleteApplyResponse, SdkMediaDeletePreviewResponse, SdkMediaDownloadResponse, SdkMediaListResponse, SdkMediaUploadUrlResponse, SdkPageResponse, SdkEntryUpsertSlotBlock, SdkPublishOrUnpublishEntryResponse, SdkPullContentTypesResponse, SdkCatalogBlocksResponse, SdkCatalogContentTypesResponse, SdkCapabilitiesResponse, SdkConfigureBookingVerticalRequest, SdkConfigureBookingVerticalResponse, SdkDemoContentResponse, SdkDeleteResponse, SdkPullEntriesAllResponse, SdkPullEntriesByTypeResponse, SdkPullEntriesResponse, SdkPullEventCategoriesResponse, SdkPullEventsResponse, SdkPullFooterResponse, SdkPullFormSchema, SdkPullFormsResponse, SdkPullFormSettings, SdkPullDraftsResponse, SdkPullNavigationResponse, SdkPullPagesResponse, SdkPullSettings, SdkPullSettingsResponse, SdkPullSiteInfoResponse, SdkPullVenue, SdkPullVenuesResponse, SdkUpdateSettingsResponse, SdkUpdateEventOccurrenceRequest, SdkUpsertBlockResponse, SdkUpsertEntryResponse, SdkUpsertPageResponse, SdkUpsertEventCategoryResponse, SdkUpsertEventResponse, SdkUpsertFooterResponse, SdkUpsertFormResponse, SdkUpsertNavigationMenuResponse, SdkUpsertVenueResponse } from './sdkContracts';
14
11
  import type { FooterCompositionUpdateRequest } from './siteManagementEndpoints';
15
12
  import type { SdkEventUpsertBody } from './sdk-event-upsert';
16
13
  import type { SdkEntryPaginationQueryInput } from './schemas/sdk-entries';
@@ -196,9 +193,6 @@ export type SitePlatformAPIEndpoints = {
196
193
  sdkPullContentTypes: APIEndpoint<never, {
197
194
  siteId: string;
198
195
  }, SdkPullContentTypesResponse>;
199
- sdkCatalogTheme: APIEndpoint<never, {
200
- siteId: string;
201
- }, SdkCatalogThemeResponse>;
202
196
  sdkCatalogBlocks: APIEndpoint<never, {
203
197
  siteId: string;
204
198
  }, SdkCatalogBlocksResponse>;
@@ -226,9 +220,6 @@ export type SitePlatformAPIEndpoints = {
226
220
  sdkPullForms: APIEndpoint<never, {
227
221
  siteId: string;
228
222
  }, SdkPullFormsResponse>;
229
- sdkPullTheme: APIEndpoint<never, {
230
- siteId: string;
231
- }, SdkPullThemeResponse>;
232
223
  sdkPullFooter: APIEndpoint<never, {
233
224
  siteId: string;
234
225
  }, SdkPullFooterResponse>;
@@ -326,27 +317,6 @@ export type SitePlatformAPIEndpoints = {
326
317
  }, {
327
318
  siteId: string;
328
319
  }, SdkUpsertNavigationMenuResponse>;
329
- sdkUpsertTheme: APIEndpoint<Readonly<{
330
- kind: 'update';
331
- /**
332
- * The theme minus its header (#1318 Phase 4d, D17). The server compiles
333
- * `theme.header` from the site's stored selection and header
334
- * preferences and is its only author; a body carrying header bytes is
335
- * rejected rather than silently stripped.
336
- */
337
- theme: SdkThemeWireWithoutHeader;
338
- themeId?: string;
339
- selectionId?: string;
340
- }> | Readonly<{
341
- /** The first theme is compiled authoritatively from this command. */
342
- kind: 'initialize';
343
- command: SiteCommandOf<'applySiteStyleSelection'>;
344
- }>, {
345
- siteId: string;
346
- }, SdkUpsertThemeResponse>;
347
- sdkApplySiteStyleSelection: APIEndpoint<ApplySiteStyleSelectionBody, {
348
- siteId: string;
349
- }, SdkCommandApplicationResult<ApplySiteStyleSelectionResponse>>;
350
320
  sdkUpsertFooter: APIEndpoint<FooterCompositionUpdateRequest, {
351
321
  siteId: string;
352
322
  }, SdkUpsertFooterResponse>;
@@ -175,7 +175,12 @@ export type PageDesignEditorStateResponse = {
175
175
  message: string;
176
176
  } | {
177
177
  kind: 'loaded';
178
- source: 'draft' | 'published-fallback';
178
+ /**
179
+ * `'default'` means no design record was persisted for the page and the
180
+ * site style's defaults were resolved. Clients treat every loaded state
181
+ * the same way; the source is diagnostic only.
182
+ */
183
+ source: 'draft' | 'published-fallback' | 'default';
179
184
  revision: PageDesignRevisionToken;
180
185
  editorModel: PageDesignEditorReadModel;
181
186
  };
@@ -58,12 +58,12 @@ export type SiteBillingSubscriptionSnapshot = Readonly<{
58
58
  origin: BillingSubscriptionOrigin | null;
59
59
  status: string;
60
60
  }> | null;
61
- export type SiteBillingManualReviewReason = 'ambiguous_subscription_origin' | 'active_site_linked_add_on' | 'admin_requested_manual_review' | 'missing_admin_subscription_choice' | 'practitioner_limit_exceeded' | 'live_site_allowance_exceeded' | 'subscription_action_failed' | 'multiple_platform_subscriptions' | 'commission_reconciliation_exhausted';
62
- export declare const SITE_BILLING_MANUAL_REVIEW_REASONS: readonly ["ambiguous_subscription_origin", "active_site_linked_add_on", "admin_requested_manual_review", "missing_admin_subscription_choice", "practitioner_limit_exceeded", "live_site_allowance_exceeded", "subscription_action_failed", "multiple_platform_subscriptions", "commission_reconciliation_exhausted"];
61
+ export type SiteBillingManualReviewReason = 'ambiguous_subscription_origin' | 'active_site_linked_add_on' | 'admin_requested_manual_review' | 'missing_admin_subscription_choice' | 'practitioner_limit_exceeded' | 'live_site_allowance_exceeded' | 'subscription_action_failed' | 'multiple_platform_subscriptions' | 'platform_subscription_recovery_failed' | 'commission_reconciliation_exhausted';
62
+ export declare const SITE_BILLING_MANUAL_REVIEW_REASONS: readonly ["ambiguous_subscription_origin", "active_site_linked_add_on", "admin_requested_manual_review", "missing_admin_subscription_choice", "practitioner_limit_exceeded", "live_site_allowance_exceeded", "subscription_action_failed", "multiple_platform_subscriptions", "platform_subscription_recovery_failed", "commission_reconciliation_exhausted"];
63
63
  export type SiteBillingManualReviewStatus = 'open' | 'resolved';
64
64
  export declare const SITE_BILLING_MANUAL_REVIEW_STATUSES: readonly ["open", "resolved"];
65
- export type SiteBillingManualReviewResolutionAction = 'external_action_completed' | 'no_action_needed' | 'duplicate' | 'superseded_by_arrangement_change' | 'accepted_risk';
66
- export declare const SITE_BILLING_MANUAL_REVIEW_RESOLUTION_ACTIONS: readonly ["external_action_completed", "no_action_needed", "duplicate", "superseded_by_arrangement_change", "accepted_risk"];
65
+ export type SiteBillingManualReviewResolutionAction = 'external_action_completed' | 'no_action_needed' | 'duplicate' | 'superseded_by_arrangement_change' | 'accepted_risk' | 'automatic_reconciliation_succeeded';
66
+ export declare const SITE_BILLING_MANUAL_REVIEW_RESOLUTION_ACTIONS: readonly ["external_action_completed", "no_action_needed", "duplicate", "superseded_by_arrangement_change", "accepted_risk", "automatic_reconciliation_succeeded"];
67
67
  export type SiteBillingManualReviewFailureAction = 'cancel_immediately' | 'cancel_at_period_end' | 'sync_existing_subscription' | 'post_stripe_arrangement_update_failed';
68
68
  export type SiteBillingManualReviewDetailsByReason = Readonly<{
69
69
  ambiguous_subscription_origin: Readonly<{
@@ -99,6 +99,10 @@ export type SiteBillingManualReviewDetailsByReason = Readonly<{
99
99
  multiple_platform_subscriptions: Readonly<{
100
100
  subscriptionIds: readonly string[];
101
101
  }>;
102
+ platform_subscription_recovery_failed: Readonly<{
103
+ subscriptionId: string;
104
+ error: string;
105
+ }>;
102
106
  commission_reconciliation_exhausted: Readonly<{
103
107
  targetKind: 'customer_membership' | 'order_payment_plan';
104
108
  targetId: string;
@@ -112,7 +116,7 @@ export type SiteBillingManualReviewPayload = {
112
116
  details: SiteBillingManualReviewDetailsByReason[TReason];
113
117
  }>;
114
118
  }[SiteBillingManualReviewReason];
115
- export type SiteBillingArrangementPlanManualReviewReason = Exclude<SiteBillingManualReviewReason, 'subscription_action_failed' | 'practitioner_limit_exceeded' | 'live_site_allowance_exceeded' | 'multiple_platform_subscriptions' | 'commission_reconciliation_exhausted'>;
119
+ export type SiteBillingArrangementPlanManualReviewReason = Exclude<SiteBillingManualReviewReason, 'subscription_action_failed' | 'practitioner_limit_exceeded' | 'live_site_allowance_exceeded' | 'multiple_platform_subscriptions' | 'platform_subscription_recovery_failed' | 'commission_reconciliation_exhausted'>;
116
120
  export type SiteBillingArrangementSubscriptionAction = 'not_applicable' | 'sync_attempted' | 'cancelled_immediately' | 'scheduled_cancel_at_period_end' | 'manual_review_required' | 'failed';
117
121
  export declare const SITE_BILLING_ARRANGEMENT_SUBSCRIPTION_ACTIONS: readonly ["not_applicable", "sync_attempted", "cancelled_immediately", "scheduled_cancel_at_period_end", "manual_review_required", "failed"];
118
122
  export declare const SITE_BILLING_ARRANGEMENT_CHANGE_ORIGINS: readonly ["native_arrangement_change", "imported_legacy_cost_history"];
@@ -654,6 +654,20 @@ export declare const publicEventSchema: z.ZodUnion<readonly [z.ZodObject<{
654
654
  }, z.core.$strip>;
655
655
  }, z.core.$strip>]>>;
656
656
  }, z.core.$strip>;
657
+ cancellationPolicy: z.ZodObject<{
658
+ refunds: z.ZodObject<{
659
+ mode: z.ZodEnum<{
660
+ never: "never";
661
+ always: "always";
662
+ cutoff: "cutoff";
663
+ }>;
664
+ cutoffHours: z.ZodNumber;
665
+ method: z.ZodEnum<{
666
+ site_credit: "site_credit";
667
+ original_payment_method: "original_payment_method";
668
+ }>;
669
+ }, z.core.$strip>;
670
+ }, z.core.$strip>;
657
671
  consent: z.ZodNullable<z.ZodType<Readonly<{
658
672
  requirementId: string;
659
673
  title: string;
@@ -1125,6 +1139,20 @@ export declare const publicEventSchema: z.ZodUnion<readonly [z.ZodObject<{
1125
1139
  }, z.core.$strip>;
1126
1140
  }, z.core.$strip>]>>;
1127
1141
  }, z.core.$strip>;
1142
+ cancellationPolicy: z.ZodObject<{
1143
+ refunds: z.ZodObject<{
1144
+ mode: z.ZodEnum<{
1145
+ never: "never";
1146
+ always: "always";
1147
+ cutoff: "cutoff";
1148
+ }>;
1149
+ cutoffHours: z.ZodNumber;
1150
+ method: z.ZodEnum<{
1151
+ site_credit: "site_credit";
1152
+ original_payment_method: "original_payment_method";
1153
+ }>;
1154
+ }, z.core.$strip>;
1155
+ }, z.core.$strip>;
1128
1156
  consent: z.ZodNullable<z.ZodType<Readonly<{
1129
1157
  requirementId: string;
1130
1158
  title: string;
@@ -1621,6 +1649,20 @@ export declare const publicEventsArraySchema: z.ZodArray<z.ZodUnion<readonly [z.
1621
1649
  }, z.core.$strip>;
1622
1650
  }, z.core.$strip>]>>;
1623
1651
  }, z.core.$strip>;
1652
+ cancellationPolicy: z.ZodObject<{
1653
+ refunds: z.ZodObject<{
1654
+ mode: z.ZodEnum<{
1655
+ never: "never";
1656
+ always: "always";
1657
+ cutoff: "cutoff";
1658
+ }>;
1659
+ cutoffHours: z.ZodNumber;
1660
+ method: z.ZodEnum<{
1661
+ site_credit: "site_credit";
1662
+ original_payment_method: "original_payment_method";
1663
+ }>;
1664
+ }, z.core.$strip>;
1665
+ }, z.core.$strip>;
1624
1666
  consent: z.ZodNullable<z.ZodType<Readonly<{
1625
1667
  requirementId: string;
1626
1668
  title: string;
@@ -2092,6 +2134,20 @@ export declare const publicEventsArraySchema: z.ZodArray<z.ZodUnion<readonly [z.
2092
2134
  }, z.core.$strip>;
2093
2135
  }, z.core.$strip>]>>;
2094
2136
  }, z.core.$strip>;
2137
+ cancellationPolicy: z.ZodObject<{
2138
+ refunds: z.ZodObject<{
2139
+ mode: z.ZodEnum<{
2140
+ never: "never";
2141
+ always: "always";
2142
+ cutoff: "cutoff";
2143
+ }>;
2144
+ cutoffHours: z.ZodNumber;
2145
+ method: z.ZodEnum<{
2146
+ site_credit: "site_credit";
2147
+ original_payment_method: "original_payment_method";
2148
+ }>;
2149
+ }, z.core.$strip>;
2150
+ }, z.core.$strip>;
2095
2151
  consent: z.ZodNullable<z.ZodType<Readonly<{
2096
2152
  requirementId: string;
2097
2153
  title: string;
@@ -163,6 +163,14 @@ export type PublicEventBase = {
163
163
  pricing: PublicEventPricing;
164
164
  /** Shared booking payment-terms model for appointments/events/courses. */
165
165
  paymentTerms: BlockBookingPaymentTerms;
166
+ /** The resolved cancellation promise shown before a visitor books. */
167
+ cancellationPolicy: Readonly<{
168
+ refunds: Readonly<{
169
+ mode: 'never' | 'always' | 'cutoff';
170
+ cutoffHours: number;
171
+ method: 'original_payment_method' | 'site_credit';
172
+ }>;
173
+ }>;
166
174
  /** Consent that must be accepted before registration, when configured. */
167
175
  consent: BlockBookingConsent | null;
168
176
  /** Access restriction type */
@@ -605,6 +605,20 @@ export declare const eventCollectionSourceSchemaShape: {
605
605
  }, z.core.$strip>;
606
606
  }, z.core.$strip>]>>;
607
607
  }, z.core.$strip>;
608
+ cancellationPolicy: z.ZodObject<{
609
+ refunds: z.ZodObject<{
610
+ mode: z.ZodEnum<{
611
+ never: "never";
612
+ always: "always";
613
+ cutoff: "cutoff";
614
+ }>;
615
+ cutoffHours: z.ZodNumber;
616
+ method: z.ZodEnum<{
617
+ site_credit: "site_credit";
618
+ original_payment_method: "original_payment_method";
619
+ }>;
620
+ }, z.core.$strip>;
621
+ }, z.core.$strip>;
608
622
  consent: z.ZodNullable<z.ZodType<Readonly<{
609
623
  requirementId: string;
610
624
  title: string;
@@ -1076,6 +1090,20 @@ export declare const eventCollectionSourceSchemaShape: {
1076
1090
  }, z.core.$strip>;
1077
1091
  }, z.core.$strip>]>>;
1078
1092
  }, z.core.$strip>;
1093
+ cancellationPolicy: z.ZodObject<{
1094
+ refunds: z.ZodObject<{
1095
+ mode: z.ZodEnum<{
1096
+ never: "never";
1097
+ always: "always";
1098
+ cutoff: "cutoff";
1099
+ }>;
1100
+ cutoffHours: z.ZodNumber;
1101
+ method: z.ZodEnum<{
1102
+ site_credit: "site_credit";
1103
+ original_payment_method: "original_payment_method";
1104
+ }>;
1105
+ }, z.core.$strip>;
1106
+ }, z.core.$strip>;
1079
1107
  consent: z.ZodNullable<z.ZodType<Readonly<{
1080
1108
  requirementId: string;
1081
1109
  title: string;
@@ -1607,6 +1635,20 @@ export declare const eventCollectionDisplaySchemaShape: {
1607
1635
  }, z.core.$strip>;
1608
1636
  }, z.core.$strip>]>>;
1609
1637
  }, z.core.$strip>;
1638
+ cancellationPolicy: z.ZodObject<{
1639
+ refunds: z.ZodObject<{
1640
+ mode: z.ZodEnum<{
1641
+ never: "never";
1642
+ always: "always";
1643
+ cutoff: "cutoff";
1644
+ }>;
1645
+ cutoffHours: z.ZodNumber;
1646
+ method: z.ZodEnum<{
1647
+ site_credit: "site_credit";
1648
+ original_payment_method: "original_payment_method";
1649
+ }>;
1650
+ }, z.core.$strip>;
1651
+ }, z.core.$strip>;
1610
1652
  consent: z.ZodNullable<z.ZodType<Readonly<{
1611
1653
  requirementId: string;
1612
1654
  title: string;
@@ -2078,6 +2120,20 @@ export declare const eventCollectionDisplaySchemaShape: {
2078
2120
  }, z.core.$strip>;
2079
2121
  }, z.core.$strip>]>>;
2080
2122
  }, z.core.$strip>;
2123
+ cancellationPolicy: z.ZodObject<{
2124
+ refunds: z.ZodObject<{
2125
+ mode: z.ZodEnum<{
2126
+ never: "never";
2127
+ always: "always";
2128
+ cutoff: "cutoff";
2129
+ }>;
2130
+ cutoffHours: z.ZodNumber;
2131
+ method: z.ZodEnum<{
2132
+ site_credit: "site_credit";
2133
+ original_payment_method: "original_payment_method";
2134
+ }>;
2135
+ }, z.core.$strip>;
2136
+ }, z.core.$strip>;
2081
2137
  consent: z.ZodNullable<z.ZodType<Readonly<{
2082
2138
  requirementId: string;
2083
2139
  title: string;
@@ -1,7 +1,7 @@
1
1
  import { type Result } from '../../../core/src/index';
2
2
  import { z } from 'zod';
3
3
  /** Reasons are payment evidence, not an independent pricing policy. */
4
- export declare const STRIPE_COMMISSION_FREE_REASONS: readonly ["managed_billing", "no_commission_plan", "billing_evidence_invalid", "fee_rounds_to_zero", "non_commissionable_scope", "payment_not_stripe"];
4
+ export declare const STRIPE_COMMISSION_FREE_REASONS: readonly ["managed_billing", "no_commission_plan", "billing_evidence_invalid", "fee_rounds_to_zero", "payment_not_stripe"];
5
5
  export type StripeCommissionFreeReason = (typeof STRIPE_COMMISSION_FREE_REASONS)[number];
6
6
  declare const commissionEvidenceSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
7
7
  currency: z.ZodOptional<z.ZodString>;
@@ -12,7 +12,6 @@ declare const commissionEvidenceSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
12
12
  no_commission_plan: "no_commission_plan";
13
13
  billing_evidence_invalid: "billing_evidence_invalid";
14
14
  fee_rounds_to_zero: "fee_rounds_to_zero";
15
- non_commissionable_scope: "non_commissionable_scope";
16
15
  payment_not_stripe: "payment_not_stripe";
17
16
  }>;
18
17
  }, z.core.$strip>, z.ZodObject<{