Booking System Setup Instructions

Quick Start Guide

1. Environment Variables (Required)

Add these to your Netlify dashboard under Site Settings → Environment Variables:

# Resend (Required for emails)
RESEND_API_KEY=re_xxxxx...  # Get from Resend dashboard
OWNER_EMAIL=your-email@gmail.com  # Where you receive bookings
FROM_EMAIL=your-email@gmail.com  # Must be verified in Resend

# Stripe (Required) 
STRIPE_PUBLIC_KEY=pk_test_...  # Use test keys first!
STRIPE_SECRET_KEY=sk_test_...
STRIPE_WEBHOOK_SECRET=whsec_...  # Set up after creating webhook

# Site URL
URL=https://your-site.netlify.app

2. Resend Setup

  1. Create Account: Sign up at resend.com (free - 100 emails/day forever)
  2. Verify Domain (or use their test domain):
  3. Get API Key:

3. Stripe Setup

  1. Create Account: Sign up at stripe.com
  2. Get API Keys: Developers → API Keys
  3. Set Up Webhook:

4. Install Dependencies

# In the netlify/functions directory
cd netlify/functions
npm install

5. Deploy to Netlify

git add .
git commit -m "Add booking system"
git push

Netlify will automatically:

6. Test the System

Test with Test Data:

  1. Go to your Domino hire page
  2. Fill in the booking form
  3. Check Netlify Forms dashboard for submission
  4. Check your email for approval request
  5. Click approve → Customer gets payment link
  6. Use Stripe test card: 4242 4242 4242 4242
  7. Check for confirmation emails

Stripe Test Cards:

7. Go Live

When ready for real payments:

  1. Switch to Stripe live keys (start with pk_live_ and sk_live_)
  2. Update webhook with live endpoint
  3. Update all environment variables in Netlify
  4. Test with a small real payment

Monitoring

Check for Bookings:

  1. Netlify Forms: Dashboard → Forms (always saves submissions)
  2. SendGrid: Activity Feed shows all emails
  3. Stripe: Payments dashboard shows all transactions
  4. Function Logs: Netlify → Functions → View logs

Daily Checklist:

Troubleshooting

Not receiving emails?

  1. Check Netlify Forms (submission always saved there)
  2. Check Resend dashboard → Emails for delivery status
  3. Verify FROM_EMAIL is correct (use onboarding@resend.dev for testing)
  4. Check spam folder
  5. Check environment variables are set

Payment not working?

  1. Verify Stripe keys are correct
  2. Check webhook is configured
  3. Look at Stripe Dashboard → Developers → Logs
  4. Check Netlify Function logs

Function errors?

  1. Check logs: Netlify → Functions → [function-name]
  2. Verify all environment variables are set
  3. Make sure dependencies are installed

Important URLs

Support

Next Steps

  1. Set up all environment variables ✓
  2. Test with test payments ✓
  3. Switch to live keys when ready
  4. Consider adding: