Add room, person, and equipment booking with scheduling, inventory, and lifecycle management to any Convex app using @mrfinch/booking.
npm install @mrfinch/bookingA Convex component for booking rooms, people, and equipment. Manage timezone-aware availability, prevent conflicting bookings, and reserve multiple resources atomically. Supports equipment pools, confirmation, cancellation, rescheduling, and token-based booking management. Use the backend API for custom interfaces or the included React Booker for single-resource booking flows.
Install @mrfinch/booking, register the component in convex/convex.config.ts using app.use(booking), then render the Booker component wrapped in BookingProvider with your event type and resource IDs. The component manages availability, slot selection, contact details, and confirmation in its own database.
@mrfinch/booking provides a multi-resource API that reserves several resources in a single atomic operation, which is also how pool quantities are tracked. Single-resource booking flows will reject pool resources, so use the multi-resource API when combining rooms, people, or equipment into one booking.
@mrfinch/booking supports confirmation, decline, cancellation, and atomic rescheduling as part of its lifecycle API. Host functions call components.booking.* after performing their own authorization and policy checks, and provisional bookings can be expired under host control.
@mrfinch/booking includes optional Resend integration for notifications and token-based management links. You can also supply a custom email renderer to use your own design, following the email guide in the component documentation.
No. Browser clients call host functions that you write and control. Those host functions perform authorization and policy checks before calling components.booking.* internally. The old public makeBookingAPI factory was removed in version 0.4.0 and must be replaced with authorized host wrappers.
@mrfinch/booking requires Convex 1.46 or newer. Install it alongside the component with npm install @mrfinch/booking convex@^1.46.0. Node 24 LTS is recommended for development.
Yes. The React Booker and its peer dependencies are optional. Backend-only apps can skip installing convex-helpers, react-hook-form, @hookform/resolvers, and lucide-react, and interact with the component entirely through host functions calling components.booking.*.
@mrfinch/booking supports weekly hours, date overrides, and IANA timezones in its schedule model. Booking timestamps are stored as Unix milliseconds and availability is tracked on a 15-minute grid.
@mrfinch/booking exposes its schema and modules for use with convex-test. After installing convex-test and Vitest, import bookingComponent from @mrfinch/booking/test and call bookingComponent.register(t) before invoking host functions in your tests. Pass a second argument to register if you mounted the component under a non-default name.