1
Collections
bookings with fields: room (Select), starts_at (DateTime, required, timezone_required), customer_name (Text), customer_email (Text, format email), status (Select: pending, confirmed, cancelled).3
beforeInsert: block double bookings
4
afterInsert: send the confirmation
5
Test
Create two bookings for the same room and time. The second must fail with “This time slot is already booked”. Check the hook’s executions and your inbox.
