Changelog
Changelog
Section titled “Changelog”All notable changes to The Booking Kit will be documented in this file.
0.2.0 (2026-03-25)
Section titled “0.2.0 (2026-03-25)”Slot Release Strategies (E-23)
Section titled “Slot Release Strategies (E-23)”Control when time slots become visible to customers — fill earlier gaps first, use rolling release windows, or incentivize early bookings with discounts.
@thebookingkit/core
Section titled “@thebookingkit/core”- New:
applySlotRelease()— three slot release strategies:fill_earlier_first: Hide afternoon slots until morning reaches a fill threshold (barbers, salons)rolling_window: Only show slots within N hours/days from now (restaurants releasing dinner day-of)discount_incentive: Annotate harder-to-fill slots withreleaseMetadata.discountPercent(no filtering)
- New:
computeWindowFillRates()— exported helper for custom fill rate computation - Extended:
SlotComputeOptionswith optionalslotReleasefield - Extended:
Slotwith optionalreleaseMetadatafor discount annotations - New: Feature guide: Slot Release Strategies
Resource & Capacity-Based Booking (E-22)
Section titled “Resource & Capacity-Based Booking (E-22)”Book restaurant tables, yoga mats, meeting rooms, tennis courts, and any physical bookable unit with capacity-aware scheduling.
@thebookingkit/core
Section titled “@thebookingkit/core”- New:
getResourceAvailableSlots()— capacity-aware slot computation across resource pools (per-resource pipeline, then merge) - New:
assignResource()— auto-assign best resource with 4 strategies:best_fit,first_available,round_robin,largest_first - New:
isResourceSlotAvailable()— quick availability check for a specific resource or any-in-pool - New:
getResourcePoolSummary()— admin utilization metrics with per-type breakdown - New:
ResourceUnavailableErrorwith typed reasons (no_capacity,no_matching_type,all_booked) - New: 9 resource types:
ResourceInput,ResourceSlot,AvailableResource,ResourceAssignmentStrategy, and more - New: Shared pipeline extraction (
slot-pipeline.ts) — RRULE expansion and override masking shared between provider and resource engines - Extended:
BookingInputwith optionalresourceIdandguestCount(backward-compatible) - Performance: 50-resource / 30-day computation in ~45ms
Conflict Detection Decomposition
Section titled “Conflict Detection Decomposition”Extracted reusable conflict detection primitives from the kiosk module for use across any booking flow.
@thebookingkit/core
Section titled “@thebookingkit/core”- New:
findConflicts()— generic booking overlap detection. Checks half-open intervals, excludes inactive statuses, supports self-exclusion viaexcludeId - New:
canReschedule()— status check for reschedulable bookings (onlyconfirmedandpending) - New:
describeConflicts()— human-readable conflict descriptions with custom time formatter support - New: Types:
ConflictCheckBooking,ConflictDetail - Refactored:
validateRescheduleandvalidateBreakBlocknow delegate tofindConflicts()— eliminates duplicated overlap logic
@thebookingkit/db
Section titled “@thebookingkit/db”- New:
resourcestable — bookable physical units with type, capacity, and location - New:
resource_availability_rulesandresource_availability_overridestables - New:
bookings.resource_idnullable FK withEXCLUDE USING gistconstraint (scoped toresource_id IS NOT NULL) - New: Updated
create_booking()function with optionalp_resource_idparameter - New: Migration
0005_resources.sql(idempotent)
@thebookingkit/d1
Section titled “@thebookingkit/d1”- New:
d1ResourceAvailabilityRowsToInputs()andd1ResourceOverrideRowsToInputs()converters - New:
D1ResourceBookingLockfor resource-scoped advisory locking - New: 14 domain-scoped DDL constants for all core tables (
ORGANIZATIONS_DDL,TEAMS_DDL,PROVIDERS_DDL, etc.) - New:
ALL_DDL— convenience aggregate for initializing a complete D1 database in one call - New:
d1AvailabilityRuleRowsToInputs()— converter for provider availability rules (was missing)
@thebookingkit/server
Section titled “@thebookingkit/server”- New: 12 webhook triggers:
BOOKING_COMPLETED,RESOURCE_BOOKED,RESOURCE_RELEASED,WALK_IN_ADDED,WALK_IN_STARTED,WALK_IN_COMPLETED,WALK_IN_CANCELLED,SLOT_RELEASED,RECURRING_SERIES_CREATED,OCCURRENCE_CANCELLED,OCCURRENCE_RESCHEDULED,PAYMENT_REFUNDED - New: 5 background job names for walk-in, resource, recurring, and slot release workflows
- Security: Replaced manual XOR with
crypto.timingSafeEqual, added error logging inwithAuth, JSON/HTML escaping in templates - Branding: Webhook headers renamed from
X-SlotKit-*toX-BookingKit-*
Testing
Section titled “Testing”- New: 42 integration tests validating end-to-end booking flows across all modules (barber shop, restaurant, team scheduling, walk-in queue, cross-feature composition, seats/groups)
- New: 101 D1 DDL structure tests
- Total test count: 1,213 across the monorepo
Documentation & Demo
Section titled “Documentation & Demo”- Updated: Introduction now explicitly mentions resource booking and all booking types (restaurants, hotels, yoga, coworking, courts)
- Updated: Quick-start with correct v0.2.0 API signatures + resource booking quick start section
- Updated: Examples page with 3 new resource-based use cases (restaurant, hotel, coworking)
- Updated: Schema docs with resource tables in main grid
- New: Feature guide: Resource & Capacity Booking
- New: Feature guide: Slot Release Strategies
- New: API reference: Resource Engine API
- New: Interactive restaurant reservation demo (Olive & Vine Bistro)
Branding
Section titled “Branding”- All “SlotKit” references renamed to “BookingKit” / “The Booking Kit” across the monorepo
- CLI types:
SlotKitManifest→BookingKitManifest,SlotKitConfig→BookingKitConfig(deprecated aliases retained)
0.1.5 (2026-03-12)
Section titled “0.1.5 (2026-03-12)”QA Audit — 49 Critical & High Priority Bug Fixes
Section titled “QA Audit — 49 Critical & High Priority Bug Fixes”This release includes a comprehensive QA audit across all packages, fixing 49 bugs across scheduling logic, database constraints, server security, D1 adapter edge cases, and CLI stability.
@thebookingkit/core (13 fixes)
Section titled “@thebookingkit/core (13 fixes)”- Critical: Midnight-crossing availability windows now produce correct slots; single
nowreference in slot filter prevents time drift; RRULEdtstartpreserved whenBYDAYis present - High: Booking limit counters increment after validation; overlapping booking intervals merged before wait time calculation; array responses handled element-wise in condition evaluation
- Medium: Multi-select validation rejects invalid options; break-to-override returns specific time window; HTML escaping in embed snippets
- Low: Slug generation handles special characters; cancellation fee validation throws on invalid timing; queue reordering preserves unmentioned entries; auto-reject deadlines clamped to minimum 1 hour
@thebookingkit/db (10 fixes)
Section titled “@thebookingkit/db (10 fixes)”- Critical: EXCLUDE constraint now excludes
rescheduledstatus; audit trigger usesupdatedfallback; metadata initialization fixed - High:
teams.slugandeventTypes.slugnow have unique constraints - High: Audit trigger status→enum cast replaced with explicit
CASEexpression to prevent silent cast failures on future enum additions;bookingEvents.bookingIdusesonDelete: restrictto protect audit integrity - Medium:
WalkInQueuetype exports added; pgcrypto extension added to setup migration; integration testANY(array)queries fixed to useinArray()andsql.join - Low: Added vitest test script;
drizzle.config.tsschema path corrected to compiled output
@thebookingkit/d1 (13 fixes)
Section titled “@thebookingkit/d1 (13 fixes)”- Critical: SQL identifier validation prevents injection; table name validation in migrations
- High: Lock acquisition only retries on UNIQUE constraint errors; other errors re-thrown immediately
- Medium: DST-aware day boundary computation; 1ms adjustment for midnight exclusion; hour normalization and validation; stricter time range validation; stale lock cleanup timing; date codec refactored to reject ambiguous formats
- Low: Out-of-range time rejection; unused import removed
@thebookingkit/server (14 fixes)
Section titled “@thebookingkit/server (14 fixes)”- Critical: Full 256-bit HMAC signatures in booking tokens; constant-time comparison for token verification
- High: Error handling sanitizes stack traces; role hierarchy enforces admin > provider > member; SSRF validation on webhook subscriptions and fire_webhook action; UUID validation in slot query params
- Medium: Multi-tenancy scope assertions throw on null resource; recursive template injection prevented; XSS prevention in email templates; 90-day date range limit for DoS prevention; slug validation prevents path traversal; timezone-aware time/date formatting in workflows
- Low: ICS carriage return stripping prevents line structure injection
@thebookingkit/cli (16 fixes)
Section titled “@thebookingkit/cli (16 fixes)”- Critical: Registry HTTPS validation; adapter input validation prevents shell injection
- High: Manifest JSON parse errors wrapped with helpful messages; partial install state preserved; null-check on registry responses; directory escape prevention; circular dependency detection
- Medium: Dynamic version from package.json; default manifest factory creates fresh instances; migration filename warnings; path traversal prevention
- Low: Config template shape fixed; quote/backslash injection prevention; unused import removed; adapter config validation
0.1.3 (2026-03-10)
Section titled “0.1.3 (2026-03-10)”KioskCalendar — Drag-and-Drop & Schedule Map
Section titled “KioskCalendar — Drag-and-Drop & Schedule Map”- Fixed:
onEventDropandonEventResizecallbacks were defined as props but never wired to the underlying calendar. Events can now be dragged to reschedule and (optionally) reassign resources. - Added:
resizableprop (defaultfalse) — opt-in to allow event duration changes by dragging the bottom edge. - Added:
scheduleMapprop andKioskScheduleEntryinterface — pass per-resource working hours to automatically dim off-hours slots with thetbk-slot-offCSS class. - Added:
draggableAccessor— events with terminal statuses (completed, cancelled, no_show, rejected) are automatically non-draggable.
Component Bug Fixes
Section titled “Component Bug Fixes”- BreakBlockForm: “Block rest of day” quick action now flows through react-hook-form validation instead of bypassing it.
- WalkInEntryForm: Fixed missing dependencies in
useEffectforonServiceChangecallback. - PaymentGate: Clarified misleading comment about Stripe confirmation flow.
Registry & Docs
Section titled “Registry & Docs”kiosk-calendarnow correctly listsreact-big-calendaranddate-fnsas npm dependencies andbooking-status-badgeas a component dependency.- Updated kiosk-calendar documentation with new props, schedule map usage example, and CSS class reference.
- Comprehensive documentation added for all booking, kiosk, and admin components.
Infrastructure
Section titled “Infrastructure”- Renamed CLI config generation function for branding consistency.
- Updated package metadata, repository URLs, and GitHub links across all packages.
- Swapped domains — demo app becomes main site, docs becomes subdomain.
- Added publishing instructions and launch preparation documents.
0.1.2 (2026-03-09)
Section titled “0.1.2 (2026-03-09)”Maintenance
Section titled “Maintenance”- Bumped all packages to v0.1.2.
- Redesigned demo as single-page scroll showcase.
- Wired registry build into docs deploy pipeline.
- Removed client references from examples, fixed package scope.
- Added npm registry READMEs for all packages.
- Added comparison and examples pages, fixed card alignment in docs.
- Renamed scope from
slotkittothebookingkitacross entire codebase.
0.1.1 (2026-03-09)
Section titled “0.1.1 (2026-03-09)”Initial Release
Section titled “Initial Release”We are excited to announce the first public release of The Booking Kit!
Packages Published:
Section titled “Packages Published:”@thebookingkit/core@0.1.1@thebookingkit/server@0.1.1@thebookingkit/cli@0.1.1@thebookingkit/d1@0.1.1
Key Features:
Section titled “Key Features:”- Headless Core Engine: Timezone-aware slot computation and RRULE expansion.
- D1 Adapter: Specialized support for Cloudflare D1 / SQLite with canonical date encoding.
- Server Utilities: Multi-tenancy, JWT-based management tokens, and workflow automation.
- UI Components: copy-paste source code for Calendar, Slot Picker, and Walk-in Entry.
- CLI:
initandaddcommands for rapid project setup.
For detailed changes per package, visit the GitHub repository.