@ai-matrx/records 0.36.0 → 0.37.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.
@@ -2007,6 +2007,10 @@ var DOORS = {
2007
2007
  // VISITOR's three (`booking_public`, `booking_hold`, `booking_confirm`) are
2008
2008
  // deliberately absent: they are server-lane and a browser never calls them.
2009
2009
  bookings: "bookings",
2010
+ // The OWNER's side of a booking page, and the door that had no client method at
2011
+ // all until 2026-09-21: without it the only way to get a booking page was to ask
2012
+ // an agent, which made the agent the ONLY path rather than the faster one.
2013
+ bookingDeclare: "booking_declare",
2010
2014
  // PRODUCTS row 9 — "pull my spreadsheet in". W4-IO built `io_import_open` and
2011
2015
  // `io_import_rows`; lane IMPORT gave a run an IDENTITY (the file's sha-256, so
2012
2016
  // a re-import doubles nothing), a duplicate key, a policy, per-row outcomes
@@ -2139,6 +2143,13 @@ var DOORS = {
2139
2143
  // the summary it would send right now without sending it.
2140
2144
  subscriptionDeclare: "subscription_declare",
2141
2145
  subscriptionPreview: "subscription_preview",
2146
+ // A SUBSCRIPTION IS OVER A SAVED VIEW, so a person who has never saved one has
2147
+ // nothing to subscribe to. These two are the saved-view pair (lane DIGESTS'
2148
+ // `digests_a_saved_view_has_a_door.sql`), unreachable from this client until
2149
+ // 2026-09-21: `views` lists this Table's, `viewDeclare` writes one. A LIST IS A
2150
+ // DOOR, never a grant on `platform.saved_view` behind it.
2151
+ views: "views",
2152
+ viewDeclare: "view_declare",
2142
2153
  // The cadence CATALOGUE a person's screen may ask for. `agg_subscription_cadences`
2143
2154
  // above is the notifier's own and holds no client grant; this door delegates to
2144
2155
  // it, so a picker and the digest runner can never offer different words.
@@ -2905,6 +2916,30 @@ function createRecordsClient(config) {
2905
2916
  "bookings"
2906
2917
  );
2907
2918
  },
2919
+ async bookingDeclare(args) {
2920
+ return callDoor(
2921
+ DOORS.bookingDeclare,
2922
+ {
2923
+ p_organization_id: org,
2924
+ p_table_id: args.table_id,
2925
+ p_title: args.title,
2926
+ p_questions: args.questions,
2927
+ // AN EMPTY OBJECT IS NOT A MISTAKE. The store owns every default, so a
2928
+ // page declared with no availability comes back Monday-to-Friday,
2929
+ // nine-to-five, in the organization's own zone — and the screen draws
2930
+ // what came BACK rather than what it sent.
2931
+ p_availability: args.availability ?? {},
2932
+ p_presentation: args.presentation ?? {},
2933
+ p_submission_cap: args.submission_cap ?? null,
2934
+ p_quarantine_rule_id: args.quarantine_rule_id ?? null,
2935
+ p_notify_rule_id: args.notify_rule_id ?? null,
2936
+ p_form_id: args.form_id ?? null,
2937
+ p_slug: args.slug ?? null,
2938
+ p_home_id: args.home_id ?? null
2939
+ },
2940
+ "bookingDeclare"
2941
+ );
2942
+ },
2908
2943
  async formDeclare(args) {
2909
2944
  return callDoor(
2910
2945
  DOORS.formDeclare,
@@ -3329,6 +3364,20 @@ function createRecordsClient(config) {
3329
3364
  "subscriptionPreview"
3330
3365
  );
3331
3366
  },
3367
+ async views(args) {
3368
+ return callDoor(
3369
+ DOORS.views,
3370
+ { p_organization_id: org, p_table_id: args?.table_id ?? null },
3371
+ "views"
3372
+ );
3373
+ },
3374
+ async viewDeclare({ table_id, spec }) {
3375
+ return callDoor(
3376
+ DOORS.viewDeclare,
3377
+ { p_organization_id: org, p_table_id: table_id, p_spec: spec },
3378
+ "viewDeclare"
3379
+ );
3380
+ },
3332
3381
  async subscriptionMute({ rule_id, muted }) {
3333
3382
  return callDoor(
3334
3383
  DOORS.subscriptionMute,