@riverbankcms/sdk 0.70.0 → 0.70.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 (52) hide show
  1. package/dist/_dts/ai/src/contracts/commandExposure.d.ts +8 -0
  2. package/dist/_dts/ai/src/contracts/feedback.d.ts +55 -0
  3. package/dist/_dts/ai/src/contracts/proposals.d.ts +34764 -0
  4. package/dist/_dts/ai/src/contracts.d.ts +5 -0
  5. package/dist/_dts/ai/src/designer/rfc6902.d.ts +16 -0
  6. package/dist/_dts/ai/src/designer/themePatch.d.ts +50 -0
  7. package/dist/_dts/api/src/aiPlayground.d.ts +1 -1
  8. package/dist/_dts/api/src/appointmentSetup.d.ts +19 -0
  9. package/dist/_dts/api/src/availability.d.ts +84 -2
  10. package/dist/_dts/api/src/bookingManagementEndpoints.d.ts +10 -1
  11. package/dist/_dts/api/src/contentRuntime.d.ts +1 -0
  12. package/dist/_dts/api/src/endpoints.d.ts +29 -0
  13. package/dist/_dts/api/src/sitePlatformEndpoints.d.ts +4 -0
  14. package/dist/_dts/api/src/siteRuntimeEndpoints.d.ts +29 -1
  15. package/dist/_dts/api/src/types.d.ts +1 -1
  16. package/dist/_dts/billing/src/components/index.d.ts +41 -0
  17. package/dist/_dts/db/src/generated/supabase/database.types.d.ts +219 -0
  18. package/dist/_dts/preview-next/src/client/preview/PreviewEditorSidebar.d.ts +2 -1
  19. package/dist/_dts/preview-next/src/client/preview/PreviewShell.d.ts +2 -1
  20. package/dist/_dts/preview-next/src/client/preview/PreviewShellLayout.d.ts +2 -1
  21. package/dist/_dts/preview-next/src/client/preview/SiteChromeCustomizeContext.d.ts +3 -1
  22. package/dist/_dts/preview-next/src/client/preview/StyleConfigurator.d.ts +3 -1
  23. package/dist/_dts/preview-next/src/client/preview/StyleConfigurator.state.d.ts +1 -0
  24. package/dist/_dts/preview-next/src/client/preview/styleConfiguratorApplyPayload.d.ts +8 -0
  25. package/dist/_dts/preview-next/src/client/preview/styleConfiguratorSnapshot.d.ts +1 -0
  26. package/dist/_dts/sdk/src/cli/commands/style.d.ts +19 -0
  27. package/dist/_dts/sdk/src/client/management/index.d.ts +2 -1
  28. package/dist/_dts/sdk/src/client/management/theme.d.ts +3 -1
  29. package/dist/_dts/sdk/src/client/management/types.d.ts +23 -0
  30. package/dist/_dts/sdk/src/public-api/contracts.d.ts +1 -0
  31. package/dist/_dts/sdk/src/version.d.ts +1 -1
  32. package/dist/_dts/site-commands/src/commands.d.ts +25 -7
  33. package/dist/_dts/site-commands/src/metadata.d.ts +2 -2
  34. package/dist/cli/index.mjs +168 -10
  35. package/dist/client/client.mjs +56 -2
  36. package/dist/client/hooks.mjs +55 -1
  37. package/dist/client/rendering.mjs +55 -1
  38. package/dist/preview-next/before-render.mjs +39 -0
  39. package/dist/preview-next/client/runtime.mjs +152 -38
  40. package/dist/preview-next/middleware.mjs +39 -0
  41. package/dist/server/components.mjs +55 -1
  42. package/dist/server/config-validation.mjs +55 -1
  43. package/dist/server/config.mjs +55 -1
  44. package/dist/server/data.mjs +55 -1
  45. package/dist/server/index.mjs +40 -1
  46. package/dist/server/next.mjs +56 -2
  47. package/dist/server/prebuild.mjs +1 -1
  48. package/dist/server/rendering/server.mjs +55 -1
  49. package/dist/server/rendering.mjs +55 -1
  50. package/dist/server/routing.mjs +56 -2
  51. package/dist/server/server.mjs +56 -2
  52. package/package.json +1 -1
@@ -19328,6 +19328,24 @@ var ENDPOINT_DEFINITIONS = {
19328
19328
  "server:internal_error"
19329
19329
  ]
19330
19330
  },
19331
+ setServiceSpecificAvailability: {
19332
+ path: "/sites/{siteId}/bookings/resources/{resourceId}/service-availability",
19333
+ method: "PUT",
19334
+ auth: "user",
19335
+ responseKind: "json",
19336
+ errors: [
19337
+ "validation:invalid_input",
19338
+ "resource:not_found",
19339
+ "server:internal_error"
19340
+ ]
19341
+ },
19342
+ deleteServiceSpecificAvailability: {
19343
+ path: "/sites/{siteId}/bookings/resources/{resourceId}/service-availability/{scheduleId}",
19344
+ method: "DELETE",
19345
+ auth: "user",
19346
+ responseKind: "json",
19347
+ errors: ["resource:not_found", "server:internal_error"]
19348
+ },
19331
19349
  listBlackouts: {
19332
19350
  path: "/sites/{siteId}/bookings/resources/{resourceId}/blackouts",
19333
19351
  method: "GET",
@@ -20963,6 +20981,20 @@ var ENDPOINT_DEFINITIONS = {
20963
20981
  auth: "user",
20964
20982
  responseKind: "json"
20965
20983
  },
20984
+ applySiteStyleSelection: {
20985
+ path: "/sites/{siteId}/theme/style-selection/apply",
20986
+ method: "POST",
20987
+ tags: [TAG_TEMPLATES.siteCollection, TAG_TEMPLATES.siteTheme],
20988
+ auth: "user",
20989
+ errors: [
20990
+ "validation:invalid_input",
20991
+ "auth:forbidden",
20992
+ "resource:not_found",
20993
+ "resource:conflict",
20994
+ "server:internal_error"
20995
+ ],
20996
+ responseKind: "json"
20997
+ },
20966
20998
  saveSiteChromeLookSelection: {
20967
20999
  path: "/sites/{siteId}/theme/site-chrome-look",
20968
21000
  method: "POST",
@@ -23706,6 +23738,13 @@ var ENDPOINT_DEFINITIONS = {
23706
23738
  auth: "service",
23707
23739
  responseKind: "json"
23708
23740
  },
23741
+ sdkApplySiteStyleSelection: {
23742
+ path: "/sdk/{siteId}/theme/style-selection/apply",
23743
+ method: "POST",
23744
+ auth: "service",
23745
+ responseKind: "json",
23746
+ errors: ["validation:invalid_input", "resource:not_found", "resource:conflict", "server:internal_error"]
23747
+ },
23709
23748
  sdkUpsertFooter: {
23710
23749
  path: "/sdk/{siteId}/footer",
23711
23750
  method: "POST",
@@ -34679,11 +34718,26 @@ var appointmentSetupWeeklyWindowDraftSchema = z.object({
34679
34718
  startTime: z.string(),
34680
34719
  endTime: z.string()
34681
34720
  });
34721
+ var appointmentSetupStartTimePolicyDraftSchema = z.discriminatedUnion("kind", [
34722
+ z.object({ kind: z.literal("automatic_spacing") }),
34723
+ z.object({
34724
+ kind: z.literal("regular_interval"),
34725
+ intervalMinutes: z.union([
34726
+ z.literal(10),
34727
+ z.literal(15),
34728
+ z.literal(20),
34729
+ z.literal(30),
34730
+ z.literal(45),
34731
+ z.literal(60)
34732
+ ])
34733
+ })
34734
+ ]);
34682
34735
  var appointmentSetupAvailabilityDraftSchema = z.object({
34683
34736
  kind: z.literal("weekly_windows"),
34684
34737
  resourceRef: appointmentSetupRefSchema,
34685
34738
  serviceRef: appointmentSetupRefSchema.nullable(),
34686
- windows: z.array(appointmentSetupWeeklyWindowDraftSchema)
34739
+ windows: z.array(appointmentSetupWeeklyWindowDraftSchema),
34740
+ startTimePolicy: appointmentSetupStartTimePolicyDraftSchema.optional()
34687
34741
  });
34688
34742
  var APPOINTMENT_DEFAULT_MIN_LEAD_MINUTES_MAX = 28 * 24 * 60;
34689
34743
  var APPOINTMENT_DEFAULT_MAX_BOOKING_NOTICE_MINUTES_MAX = 10 * 365 * 24 * 60;
@@ -36532,11 +36586,51 @@ function createFormOperations(http) {
36532
36586
  }
36533
36587
 
36534
36588
  // src/client/management/theme.ts
36589
+ function buildApplySiteStyleSelectionCommand(input) {
36590
+ return {
36591
+ type: "applySiteStyleSelection",
36592
+ ref: input.siteStyleId,
36593
+ input: {
36594
+ siteStyleId: input.siteStyleId,
36595
+ buttonPersonalityId: input.buttonPersonalityId,
36596
+ paletteVariantId: input.paletteVariantId,
36597
+ paletteOverrides: input.paletteOverrides,
36598
+ headerLookId: input.headerLookId,
36599
+ footerLookId: input.footerLookId,
36600
+ baseSelectionVersion: input.baseSelectionVersion
36601
+ }
36602
+ };
36603
+ }
36604
+ function applySiteStyleSelectionBodyFromCommand(command, selectionId) {
36605
+ const baseSelectionVersion = command.input.baseSelectionVersion;
36606
+ if (baseSelectionVersion === void 0) {
36607
+ throw new Error("applySiteStyleSelection command is missing baseSelectionVersion");
36608
+ }
36609
+ return {
36610
+ siteStyleId: command.input.siteStyleId,
36611
+ buttonPersonalityId: command.input.buttonPersonalityId,
36612
+ paletteVariantId: command.input.paletteVariantId,
36613
+ paletteOverrides: command.input.paletteOverrides,
36614
+ headerLookId: command.input.headerLookId,
36615
+ footerLookId: command.input.footerLookId,
36616
+ baseSelectionVersion,
36617
+ selectionId
36618
+ };
36619
+ }
36535
36620
  function createThemeOperations(http) {
36536
36621
  return {
36537
36622
  async upsert(input) {
36538
36623
  const result = await http.post("/theme", input);
36539
36624
  return result;
36625
+ },
36626
+ async applySelection(input) {
36627
+ const command = buildApplySiteStyleSelectionCommand(input);
36628
+ const body = applySiteStyleSelectionBodyFromCommand(command, input.selectionId);
36629
+ const result = await http.post(
36630
+ "/theme/style-selection/apply",
36631
+ body
36632
+ );
36633
+ return result;
36540
36634
  }
36541
36635
  };
36542
36636
  }
@@ -44215,6 +44309,7 @@ var recipeIdentifierSchema = z.string().regex(
44215
44309
  "Use lowercase letters, numbers, and hyphens."
44216
44310
  );
44217
44311
  var currencySchema = z.string().regex(/^[A-Z]{3}$/u);
44312
+ var hexColorSchema2 = z.string().regex(/^#[0-9a-f]{6}$/u, "Hex must be #RRGGBB (lowercase)");
44218
44313
  var isoDateTimeSchema = z.string().datetime({ offset: true });
44219
44314
  var ianaTimezoneSchema = z.string().trim().min(1).max(64).refine(isValidIanaTimezone, {
44220
44315
  message: "Invalid IANA timezone"
@@ -44364,11 +44459,20 @@ var configureSiteIdentityCommandSchema = z.object({
44364
44459
  seoIndexing: z.enum(["index", "noindex", "noindex_demo"]).optional()
44365
44460
  }).strict()
44366
44461
  }).strict();
44367
- var applySiteStyleCommandSchema = z.object({
44368
- type: z.literal("applySiteStyle"),
44462
+ var styleSelectionVersionSchema = nonNegativeIntegerSchema;
44463
+ var styleCatalogIdSchema = z.string().trim().min(1);
44464
+ var paletteOverridesSchema2 = z.record(z.string().trim().min(1), hexColorSchema2).readonly();
44465
+ var applySiteStyleSelectionCommandSchema = z.object({
44466
+ type: z.literal("applySiteStyleSelection"),
44369
44467
  ref: siteStyleRefSchema,
44370
44468
  input: z.object({
44371
- styleKey: z.string().min(1)
44469
+ siteStyleId: siteStyleRefSchema,
44470
+ buttonPersonalityId: styleCatalogIdSchema.nullable(),
44471
+ paletteVariantId: styleCatalogIdSchema.nullable(),
44472
+ paletteOverrides: paletteOverridesSchema2.nullable(),
44473
+ headerLookId: styleCatalogIdSchema.nullable(),
44474
+ footerLookId: styleCatalogIdSchema.nullable(),
44475
+ baseSelectionVersion: styleSelectionVersionSchema.optional()
44372
44476
  }).strict()
44373
44477
  }).strict();
44374
44478
  var upsertMediaAssetCommandSchema = z.object({
@@ -45097,7 +45201,7 @@ var configureAppointmentAvailabilityCommandSchema = z.object({
45097
45201
  var siteCommandSchema = z.discriminatedUnion("type", [
45098
45202
  configureSiteIdentityCommandSchema,
45099
45203
  configureBookingSettingsCommandSchema,
45100
- applySiteStyleCommandSchema,
45204
+ applySiteStyleSelectionCommandSchema,
45101
45205
  upsertMediaAssetCommandSchema,
45102
45206
  upsertPageCommandSchema,
45103
45207
  upsertBlockTreeCommandSchema,
@@ -45238,7 +45342,7 @@ var siteCommandMetadata = {
45238
45342
  capability: "bookings.settings.write",
45239
45343
  support: "supported"
45240
45344
  },
45241
- applySiteStyle: {
45345
+ applySiteStyleSelection: {
45242
45346
  scope: "style",
45243
45347
  risk: "low",
45244
45348
  writeSemantics: "upsert",
@@ -45247,7 +45351,7 @@ var siteCommandMetadata = {
45247
45351
  conflictPolicy: "update_existing",
45248
45352
  previewability: "static_preview",
45249
45353
  allowedRuntimes: ["development", "staging", "demo", "production"],
45250
- intendedExposure: ["recipe", "sdk_cli", "onboarding_planner", "internal_apply"],
45354
+ intendedExposure: ["recipe", "sdk_cli", "onboarding_planner", "ai_proposal", "internal_apply"],
45251
45355
  capability: "theme.write",
45252
45356
  support: "supported"
45253
45357
  },
@@ -45812,7 +45916,7 @@ function commandRefContributions(command) {
45812
45916
  case "configureSiteIdentity":
45813
45917
  case "configureBookingSettings":
45814
45918
  return { provides: [], requires: [] };
45815
- case "applySiteStyle":
45919
+ case "applySiteStyleSelection":
45816
45920
  return { provides: [{ ref: command.ref, field: "ref" }], requires: [] };
45817
45921
  case "upsertMediaAsset":
45818
45922
  case "upsertPage":
@@ -46236,7 +46340,7 @@ function matchSiteCommand(command, match) {
46236
46340
  return match(command);
46237
46341
  case "configureBookingSettings":
46238
46342
  return match(command);
46239
- case "applySiteStyle":
46343
+ case "applySiteStyleSelection":
46240
46344
  return match(command);
46241
46345
  case "upsertMediaAsset":
46242
46346
  return match(command);
@@ -54145,7 +54249,7 @@ var SimpleCache = class {
54145
54249
  };
54146
54250
 
54147
54251
  // src/version.ts
54148
- var SDK_VERSION = "0.70.0";
54252
+ var SDK_VERSION = "0.70.2";
54149
54253
 
54150
54254
  // src/client/error.ts
54151
54255
  var RiverbankApiError = class _RiverbankApiError extends Error {
@@ -60779,6 +60883,59 @@ Examples:
60779
60883
  }
60780
60884
  })
60781
60885
  );
60886
+ function buildStyleSelectionApplyInputFromOptions(options) {
60887
+ const baseSelectionVersion = Number(options.baseSelectionVersion);
60888
+ if (!Number.isInteger(baseSelectionVersion) || baseSelectionVersion < 0) {
60889
+ throw new Error("--base-selection-version must be a non-negative integer");
60890
+ }
60891
+ return {
60892
+ siteStyleId: options.siteStyleId,
60893
+ buttonPersonalityId: options.buttonPersonalityId ?? null,
60894
+ paletteVariantId: options.paletteVariantId ?? null,
60895
+ paletteOverrides: parsePaletteOverrides(options.paletteOverrides),
60896
+ headerLookId: options.headerLookId ?? null,
60897
+ footerLookId: options.footerLookId ?? null,
60898
+ baseSelectionVersion,
60899
+ selectionId: options.selectionId ?? null
60900
+ };
60901
+ }
60902
+ function parsePaletteOverrides(value) {
60903
+ if (value === void 0 || value.trim() === "") {
60904
+ return null;
60905
+ }
60906
+ const parsed = JSON.parse(value);
60907
+ if (!isStringRecord(parsed)) {
60908
+ throw new Error("--palette-overrides must be a JSON object with string values");
60909
+ }
60910
+ return parsed;
60911
+ }
60912
+ function isStringRecord(value) {
60913
+ if (typeof value !== "object" || value === null || Array.isArray(value)) {
60914
+ return false;
60915
+ }
60916
+ return Object.values(value).every((entry) => typeof entry === "string");
60917
+ }
60918
+ var applyCommand = new Command("apply").description("Apply a curated site-style selection").requiredOption("--site-style-id <id>", "Site style ID, e.g. site-style:calm-studio").requiredOption("--base-selection-version <version>", "Current style selection version").option("--selection-id <id>", "Current style selection row ID").option("--button-personality-id <id>", "Button personality ID").option("--palette-variant-id <id>", "Palette variant ID").option("--palette-overrides <json>", "JSON object of palette token overrides").option("--header-look-id <id>", "Header look ID").option("--footer-look-id <id>", "Footer look ID").action(
60919
+ withErrorHandling(async (options, command) => {
60920
+ const { output, client } = createCommandContext(command);
60921
+ const input = buildStyleSelectionApplyInputFromOptions(options);
60922
+ const commandIr = buildApplySiteStyleSelectionCommand(input);
60923
+ output.info(`Applying site style: ${input.siteStyleId}`);
60924
+ const result = await client.theme.applySelection(input);
60925
+ output.success("Site style applied", {
60926
+ command: commandIr,
60927
+ themeId: result.themeId,
60928
+ selectionId: result.selectionId,
60929
+ selectionVersion: result.selectionVersion,
60930
+ savedAt: result.savedAt
60931
+ });
60932
+ })
60933
+ );
60934
+ var styleCommand = new Command("style").description("Manage curated site styles").addHelpText("after", `
60935
+ Examples:
60936
+ $ riverbankcms style apply --site-style-id site-style:calm-studio --base-selection-version 3
60937
+ $ riverbankcms style apply --site-style-id site-style:calm-studio --base-selection-version 3 --palette-variant-id soft-natural-sage
60938
+ `).addCommand(applyCommand);
60782
60939
 
60783
60940
  // src/cli/index.ts
60784
60941
  config({ path: ".env.local" });
@@ -60829,6 +60986,7 @@ program.addCommand(auditCommand);
60829
60986
  program.addCommand(compareCommand);
60830
60987
  program.addCommand(eventCommand);
60831
60988
  program.addCommand(courseCommand2);
60989
+ program.addCommand(styleCommand);
60832
60990
  program.addCommand(manifestCommand);
60833
60991
  program.addCommand(envCommand);
60834
60992
  program.addCommand(migrateCommand);
@@ -65556,6 +65556,24 @@ var ENDPOINT_DEFINITIONS = {
65556
65556
  "server:internal_error"
65557
65557
  ]
65558
65558
  },
65559
+ setServiceSpecificAvailability: {
65560
+ path: "/sites/{siteId}/bookings/resources/{resourceId}/service-availability",
65561
+ method: "PUT",
65562
+ auth: "user",
65563
+ responseKind: "json",
65564
+ errors: [
65565
+ "validation:invalid_input",
65566
+ "resource:not_found",
65567
+ "server:internal_error"
65568
+ ]
65569
+ },
65570
+ deleteServiceSpecificAvailability: {
65571
+ path: "/sites/{siteId}/bookings/resources/{resourceId}/service-availability/{scheduleId}",
65572
+ method: "DELETE",
65573
+ auth: "user",
65574
+ responseKind: "json",
65575
+ errors: ["resource:not_found", "server:internal_error"]
65576
+ },
65559
65577
  listBlackouts: {
65560
65578
  path: "/sites/{siteId}/bookings/resources/{resourceId}/blackouts",
65561
65579
  method: "GET",
@@ -67191,6 +67209,20 @@ var ENDPOINT_DEFINITIONS = {
67191
67209
  auth: "user",
67192
67210
  responseKind: "json"
67193
67211
  },
67212
+ applySiteStyleSelection: {
67213
+ path: "/sites/{siteId}/theme/style-selection/apply",
67214
+ method: "POST",
67215
+ tags: [TAG_TEMPLATES.siteCollection, TAG_TEMPLATES.siteTheme],
67216
+ auth: "user",
67217
+ errors: [
67218
+ "validation:invalid_input",
67219
+ "auth:forbidden",
67220
+ "resource:not_found",
67221
+ "resource:conflict",
67222
+ "server:internal_error"
67223
+ ],
67224
+ responseKind: "json"
67225
+ },
67194
67226
  saveSiteChromeLookSelection: {
67195
67227
  path: "/sites/{siteId}/theme/site-chrome-look",
67196
67228
  method: "POST",
@@ -69934,6 +69966,13 @@ var ENDPOINT_DEFINITIONS = {
69934
69966
  auth: "service",
69935
69967
  responseKind: "json"
69936
69968
  },
69969
+ sdkApplySiteStyleSelection: {
69970
+ path: "/sdk/{siteId}/theme/style-selection/apply",
69971
+ method: "POST",
69972
+ auth: "service",
69973
+ responseKind: "json",
69974
+ errors: ["validation:invalid_input", "resource:not_found", "resource:conflict", "server:internal_error"]
69975
+ },
69937
69976
  sdkUpsertFooter: {
69938
69977
  path: "/sdk/{siteId}/footer",
69939
69978
  method: "POST",
@@ -82691,11 +82730,26 @@ var appointmentSetupWeeklyWindowDraftSchema = z69.object({
82691
82730
  startTime: z69.string(),
82692
82731
  endTime: z69.string()
82693
82732
  });
82733
+ var appointmentSetupStartTimePolicyDraftSchema = z69.discriminatedUnion("kind", [
82734
+ z69.object({ kind: z69.literal("automatic_spacing") }),
82735
+ z69.object({
82736
+ kind: z69.literal("regular_interval"),
82737
+ intervalMinutes: z69.union([
82738
+ z69.literal(10),
82739
+ z69.literal(15),
82740
+ z69.literal(20),
82741
+ z69.literal(30),
82742
+ z69.literal(45),
82743
+ z69.literal(60)
82744
+ ])
82745
+ })
82746
+ ]);
82694
82747
  var appointmentSetupAvailabilityDraftSchema = z69.object({
82695
82748
  kind: z69.literal("weekly_windows"),
82696
82749
  resourceRef: appointmentSetupRefSchema,
82697
82750
  serviceRef: appointmentSetupRefSchema.nullable(),
82698
- windows: z69.array(appointmentSetupWeeklyWindowDraftSchema)
82751
+ windows: z69.array(appointmentSetupWeeklyWindowDraftSchema),
82752
+ startTimePolicy: appointmentSetupStartTimePolicyDraftSchema.optional()
82699
82753
  });
82700
82754
  var APPOINTMENT_DEFAULT_MIN_LEAD_MINUTES_MAX = 28 * 24 * 60;
82701
82755
  var APPOINTMENT_DEFAULT_MAX_BOOKING_NOTICE_MINUTES_MAX = 10 * 365 * 24 * 60;
@@ -84242,7 +84296,7 @@ var SimpleCache = class {
84242
84296
  };
84243
84297
 
84244
84298
  // src/version.ts
84245
- var SDK_VERSION = "0.70.0";
84299
+ var SDK_VERSION = "0.70.2";
84246
84300
 
84247
84301
  // src/client/error.ts
84248
84302
  var RiverbankApiError = class _RiverbankApiError extends Error {
@@ -1202,6 +1202,24 @@ var ENDPOINT_DEFINITIONS = {
1202
1202
  "server:internal_error"
1203
1203
  ]
1204
1204
  },
1205
+ setServiceSpecificAvailability: {
1206
+ path: "/sites/{siteId}/bookings/resources/{resourceId}/service-availability",
1207
+ method: "PUT",
1208
+ auth: "user",
1209
+ responseKind: "json",
1210
+ errors: [
1211
+ "validation:invalid_input",
1212
+ "resource:not_found",
1213
+ "server:internal_error"
1214
+ ]
1215
+ },
1216
+ deleteServiceSpecificAvailability: {
1217
+ path: "/sites/{siteId}/bookings/resources/{resourceId}/service-availability/{scheduleId}",
1218
+ method: "DELETE",
1219
+ auth: "user",
1220
+ responseKind: "json",
1221
+ errors: ["resource:not_found", "server:internal_error"]
1222
+ },
1205
1223
  listBlackouts: {
1206
1224
  path: "/sites/{siteId}/bookings/resources/{resourceId}/blackouts",
1207
1225
  method: "GET",
@@ -2837,6 +2855,20 @@ var ENDPOINT_DEFINITIONS = {
2837
2855
  auth: "user",
2838
2856
  responseKind: "json"
2839
2857
  },
2858
+ applySiteStyleSelection: {
2859
+ path: "/sites/{siteId}/theme/style-selection/apply",
2860
+ method: "POST",
2861
+ tags: [TAG_TEMPLATES.siteCollection, TAG_TEMPLATES.siteTheme],
2862
+ auth: "user",
2863
+ errors: [
2864
+ "validation:invalid_input",
2865
+ "auth:forbidden",
2866
+ "resource:not_found",
2867
+ "resource:conflict",
2868
+ "server:internal_error"
2869
+ ],
2870
+ responseKind: "json"
2871
+ },
2840
2872
  saveSiteChromeLookSelection: {
2841
2873
  path: "/sites/{siteId}/theme/site-chrome-look",
2842
2874
  method: "POST",
@@ -5580,6 +5612,13 @@ var ENDPOINT_DEFINITIONS = {
5580
5612
  auth: "service",
5581
5613
  responseKind: "json"
5582
5614
  },
5615
+ sdkApplySiteStyleSelection: {
5616
+ path: "/sdk/{siteId}/theme/style-selection/apply",
5617
+ method: "POST",
5618
+ auth: "service",
5619
+ responseKind: "json",
5620
+ errors: ["validation:invalid_input", "resource:not_found", "resource:conflict", "server:internal_error"]
5621
+ },
5583
5622
  sdkUpsertFooter: {
5584
5623
  path: "/sdk/{siteId}/footer",
5585
5624
  method: "POST",
@@ -31469,11 +31508,26 @@ var appointmentSetupWeeklyWindowDraftSchema = z63.object({
31469
31508
  startTime: z63.string(),
31470
31509
  endTime: z63.string()
31471
31510
  });
31511
+ var appointmentSetupStartTimePolicyDraftSchema = z63.discriminatedUnion("kind", [
31512
+ z63.object({ kind: z63.literal("automatic_spacing") }),
31513
+ z63.object({
31514
+ kind: z63.literal("regular_interval"),
31515
+ intervalMinutes: z63.union([
31516
+ z63.literal(10),
31517
+ z63.literal(15),
31518
+ z63.literal(20),
31519
+ z63.literal(30),
31520
+ z63.literal(45),
31521
+ z63.literal(60)
31522
+ ])
31523
+ })
31524
+ ]);
31472
31525
  var appointmentSetupAvailabilityDraftSchema = z63.object({
31473
31526
  kind: z63.literal("weekly_windows"),
31474
31527
  resourceRef: appointmentSetupRefSchema,
31475
31528
  serviceRef: appointmentSetupRefSchema.nullable(),
31476
- windows: z63.array(appointmentSetupWeeklyWindowDraftSchema)
31529
+ windows: z63.array(appointmentSetupWeeklyWindowDraftSchema),
31530
+ startTimePolicy: appointmentSetupStartTimePolicyDraftSchema.optional()
31477
31531
  });
31478
31532
  var APPOINTMENT_DEFAULT_MIN_LEAD_MINUTES_MAX = 28 * 24 * 60;
31479
31533
  var APPOINTMENT_DEFAULT_MAX_BOOKING_NOTICE_MINUTES_MAX = 10 * 365 * 24 * 60;
@@ -77814,6 +77814,24 @@ var ENDPOINT_DEFINITIONS = {
77814
77814
  "server:internal_error"
77815
77815
  ]
77816
77816
  },
77817
+ setServiceSpecificAvailability: {
77818
+ path: "/sites/{siteId}/bookings/resources/{resourceId}/service-availability",
77819
+ method: "PUT",
77820
+ auth: "user",
77821
+ responseKind: "json",
77822
+ errors: [
77823
+ "validation:invalid_input",
77824
+ "resource:not_found",
77825
+ "server:internal_error"
77826
+ ]
77827
+ },
77828
+ deleteServiceSpecificAvailability: {
77829
+ path: "/sites/{siteId}/bookings/resources/{resourceId}/service-availability/{scheduleId}",
77830
+ method: "DELETE",
77831
+ auth: "user",
77832
+ responseKind: "json",
77833
+ errors: ["resource:not_found", "server:internal_error"]
77834
+ },
77817
77835
  listBlackouts: {
77818
77836
  path: "/sites/{siteId}/bookings/resources/{resourceId}/blackouts",
77819
77837
  method: "GET",
@@ -79449,6 +79467,20 @@ var ENDPOINT_DEFINITIONS = {
79449
79467
  auth: "user",
79450
79468
  responseKind: "json"
79451
79469
  },
79470
+ applySiteStyleSelection: {
79471
+ path: "/sites/{siteId}/theme/style-selection/apply",
79472
+ method: "POST",
79473
+ tags: [TAG_TEMPLATES.siteCollection, TAG_TEMPLATES.siteTheme],
79474
+ auth: "user",
79475
+ errors: [
79476
+ "validation:invalid_input",
79477
+ "auth:forbidden",
79478
+ "resource:not_found",
79479
+ "resource:conflict",
79480
+ "server:internal_error"
79481
+ ],
79482
+ responseKind: "json"
79483
+ },
79452
79484
  saveSiteChromeLookSelection: {
79453
79485
  path: "/sites/{siteId}/theme/site-chrome-look",
79454
79486
  method: "POST",
@@ -82192,6 +82224,13 @@ var ENDPOINT_DEFINITIONS = {
82192
82224
  auth: "service",
82193
82225
  responseKind: "json"
82194
82226
  },
82227
+ sdkApplySiteStyleSelection: {
82228
+ path: "/sdk/{siteId}/theme/style-selection/apply",
82229
+ method: "POST",
82230
+ auth: "service",
82231
+ responseKind: "json",
82232
+ errors: ["validation:invalid_input", "resource:not_found", "resource:conflict", "server:internal_error"]
82233
+ },
82195
82234
  sdkUpsertFooter: {
82196
82235
  path: "/sdk/{siteId}/footer",
82197
82236
  method: "POST",
@@ -83466,11 +83505,26 @@ var appointmentSetupWeeklyWindowDraftSchema = z71.object({
83466
83505
  startTime: z71.string(),
83467
83506
  endTime: z71.string()
83468
83507
  });
83508
+ var appointmentSetupStartTimePolicyDraftSchema = z71.discriminatedUnion("kind", [
83509
+ z71.object({ kind: z71.literal("automatic_spacing") }),
83510
+ z71.object({
83511
+ kind: z71.literal("regular_interval"),
83512
+ intervalMinutes: z71.union([
83513
+ z71.literal(10),
83514
+ z71.literal(15),
83515
+ z71.literal(20),
83516
+ z71.literal(30),
83517
+ z71.literal(45),
83518
+ z71.literal(60)
83519
+ ])
83520
+ })
83521
+ ]);
83469
83522
  var appointmentSetupAvailabilityDraftSchema = z71.object({
83470
83523
  kind: z71.literal("weekly_windows"),
83471
83524
  resourceRef: appointmentSetupRefSchema,
83472
83525
  serviceRef: appointmentSetupRefSchema.nullable(),
83473
- windows: z71.array(appointmentSetupWeeklyWindowDraftSchema)
83526
+ windows: z71.array(appointmentSetupWeeklyWindowDraftSchema),
83527
+ startTimePolicy: appointmentSetupStartTimePolicyDraftSchema.optional()
83474
83528
  });
83475
83529
  var APPOINTMENT_DEFAULT_MIN_LEAD_MINUTES_MAX = 28 * 24 * 60;
83476
83530
  var APPOINTMENT_DEFAULT_MAX_BOOKING_NOTICE_MINUTES_MAX = 10 * 365 * 24 * 60;
@@ -1231,6 +1231,24 @@ var ENDPOINT_DEFINITIONS = {
1231
1231
  "server:internal_error"
1232
1232
  ]
1233
1233
  },
1234
+ setServiceSpecificAvailability: {
1235
+ path: "/sites/{siteId}/bookings/resources/{resourceId}/service-availability",
1236
+ method: "PUT",
1237
+ auth: "user",
1238
+ responseKind: "json",
1239
+ errors: [
1240
+ "validation:invalid_input",
1241
+ "resource:not_found",
1242
+ "server:internal_error"
1243
+ ]
1244
+ },
1245
+ deleteServiceSpecificAvailability: {
1246
+ path: "/sites/{siteId}/bookings/resources/{resourceId}/service-availability/{scheduleId}",
1247
+ method: "DELETE",
1248
+ auth: "user",
1249
+ responseKind: "json",
1250
+ errors: ["resource:not_found", "server:internal_error"]
1251
+ },
1234
1252
  listBlackouts: {
1235
1253
  path: "/sites/{siteId}/bookings/resources/{resourceId}/blackouts",
1236
1254
  method: "GET",
@@ -2866,6 +2884,20 @@ var ENDPOINT_DEFINITIONS = {
2866
2884
  auth: "user",
2867
2885
  responseKind: "json"
2868
2886
  },
2887
+ applySiteStyleSelection: {
2888
+ path: "/sites/{siteId}/theme/style-selection/apply",
2889
+ method: "POST",
2890
+ tags: [TAG_TEMPLATES.siteCollection, TAG_TEMPLATES.siteTheme],
2891
+ auth: "user",
2892
+ errors: [
2893
+ "validation:invalid_input",
2894
+ "auth:forbidden",
2895
+ "resource:not_found",
2896
+ "resource:conflict",
2897
+ "server:internal_error"
2898
+ ],
2899
+ responseKind: "json"
2900
+ },
2869
2901
  saveSiteChromeLookSelection: {
2870
2902
  path: "/sites/{siteId}/theme/site-chrome-look",
2871
2903
  method: "POST",
@@ -5609,6 +5641,13 @@ var ENDPOINT_DEFINITIONS = {
5609
5641
  auth: "service",
5610
5642
  responseKind: "json"
5611
5643
  },
5644
+ sdkApplySiteStyleSelection: {
5645
+ path: "/sdk/{siteId}/theme/style-selection/apply",
5646
+ method: "POST",
5647
+ auth: "service",
5648
+ responseKind: "json",
5649
+ errors: ["validation:invalid_input", "resource:not_found", "resource:conflict", "server:internal_error"]
5650
+ },
5612
5651
  sdkUpsertFooter: {
5613
5652
  path: "/sdk/{siteId}/footer",
5614
5653
  method: "POST",