ROUTE 01 · BUILD IT YOURSELF

Build your café training app with AI.

A practical guide for the hands-on owner: lower cash cost, more learning, testing, and ownership.

Start the build ↓

WHO THIS IS FOR

You can do this if you are willing to test.

You do not need to be a professional developer. You do need to be comfortable creating accounts, following technical steps, and working through a few rough edges.

Before you begin

  • Define what staff must learn and what counts as complete.
  • List recipes, stages, lessons, hospitality standards, and roles.
  • Start with one location and a small recipe set.
  • Use test profiles before entering real staff data.

ACCOUNTS TO CREATE

The simple stack

ChatGPT or coding assistant$20/month for ChatGPT Plus; free tiers can work for early experiments.
GitHubFree source-code storage for public and private repositories.
SupabaseDatabase, staff progress, and image storage. Free for up to two active projects.
NetlifyHosting and serverless functions. Start free, then upgrade as support needs grow.

BUILD SEQUENCE

Take it one reliable step at a time.

  1. Write your training flow before opening a tool.
  2. Create your GitHub repository, Supabase project, and Netlify site.
  3. Generate a first version using the prompt below.
  4. Run database migrations and add environment variables.
  5. Deploy a private test version to Netlify.
  6. Test as a staff member and admin on phone and desktop.
  7. Enter real staff and content only after the test flow is reliable.

COPY AND PASTE PROMPT

Give this to your coding assistant.

Build prompt
Build a production-ready, white-label, multi-tenant café training platform.

Product:
A branded employee training app for cafés, beverage shops, and hospitality teams. Each business can customize its brand, locations, curriculum, staff roster, recipes, learning stages, badges, and reports without changing code.

Use this exact tech stack:
- Frontend: vanilla JavaScript, HTML, CSS
- Hosting: Netlify
- Backend APIs: Netlify Functions
- Database and authentication data: Supabase Postgres
- File storage: Supabase Storage for uploaded recipe, lesson, and brand images
- Deployment: Netlify CLI and netlify.toml
- Keep the frontend static and use Netlify Functions for all privileged database operations
- Do not expose Supabase service-role credentials to the browser

Architecture:
- Build a multi-tenant system from day one
- Every tenant-owned record must include organization_id
- Location-specific records must include location_id when applicable
- Every Netlify Function must validate the authenticated user's organization and role before reading or writing data
- Never allow cross-organization data access
- Use Supabase Row Level Security where possible, plus server-side authorization in Netlify Functions
- Keep configuration data-driven; do not hardcode a company name, location, colors, badge names, or curriculum labels

URL structure:
- Use organization slug URLs such as:
  - app.example.com/{organization-slug}
  - app.example.com/{organization-slug}/admin
- Make the current organization resolve from the URL slug
- Support a future custom-domain mapping model

Roles:
- Platform Owner: manages all organizations
- Organization Admin: manages branding, locations, curriculum, staff, and reports for their organization
- Location Admin: manages one or more assigned locations
- Shift Lead: views location progress and can manager-verify skills
- Staff: completes assigned training only

Supabase schema:
Create migrations for at least these tables:

organizations
- id, slug, name, active, created_at

organization_brand_settings
- organization_id, logo_url, favicon_url, primary_color, secondary_color, accent_color, background_color
- heading_font, body_font, footer_text, app_title, welcome_heading, welcome_description
- training_labels JSONB, updated_at

locations
- id, organization_id, name, slug, active, timezone, created_at

profiles
- id, organization_id, primary_location_id, display_name, login_name, role, active, pin_hash, created_at

profile_locations
- profile_id, location_id

training_courses
- id, organization_id, title, slug, description, active, sort_order

training_lessons
- id, organization_id, course_id, title, slug, description, image_url, content JSONB, quiz JSONB
- estimated_minutes, active, sort_order

training_modules
- id, organization_id, location_id nullable, title, slug, description, icon, required, active, sort_order
- prerequisite_module_id nullable, completion_threshold

training_recipes
- id, organization_id, title, slug, category, tags JSONB, seasonal, season, required, active
- image_url, steps JSONB, source, sort_order

training_module_recipes
- id, organization_id, module_id, recipe_id, required, sort_order

training_progress
- id, organization_id, profile_id, lesson_kind, lesson_id, best_score, total_questions, completed_at, updated_at

training_attempts
- id, organization_id, profile_id, lesson_kind, lesson_id, score, total_questions, created_at

training_manager_verifications
- id, organization_id, profile_id, recipe_id, verified_by_profile_id, verified_at

training_learning_sessions
- id, organization_id, profile_id, planned_minutes, started_at, ended_at, end_reason

badges
- id, organization_id, name, slug, description, icon_type, icon_value, color, rule_type
- rule_configuration JSONB, display_order, active

profile_badges
- id, organization_id, profile_id, badge_id, earned_at

Use UUID primary keys, foreign keys, indexes on organization_id and profile_id, and created_at/updated_at fields where useful.

Branding:
Create a Brand Settings admin page where organization admins can:
- Set organization name
- Upload logo and favicon
- Set brand colors
- Set homepage heading and supporting copy
- Set footer copy
- Set custom terms for Basics, Hospitality, Recipes, Stages, Manager, Staff, and PIN
- Preview the branded staff experience before saving

Locations:
- Organization admins can create and deactivate locations
- Staff belong to a primary location
- Curriculum can be organization-wide or overridden for a location
- Recipes can be active only at selected locations
- Seasonal recipes can be enabled per location
- Reports can filter by location

Staff login:
- Staff select their name, displayed as First Name + Last Initial
- Staff enter a six-digit location/company PIN
- Staff choose a timed training block
- Track inactivity for staff only
- Reset inactivity based on typing, touch, pointer activity, scrolling, focus, input events, and form changes
- Log staff out after 5 minutes of no activity
- Show a modal at the end of a training block with Continue Training and Finish options
- Admin, Platform Owner, and Location Admin accounts must be exempt from inactivity logout, countdowns, time-up prompts, and Continue Later controls

Training areas:
1. Basics
2. Hospitality / Our Why
3. Recipe Training

Basics:
- Admin-editable course landing page
- Ordered lessons with image, content, and knowledge check
- Previous and Next lesson controls
- Correct feedback in green
- Incorrect feedback in red with the correct answer
- Scroll to top when advancing lessons
- Completion persists to Supabase

Hospitality:
- Configurable pillars
- Multiple scenarios per pillar
- Shuffle answer order
- Track pillar completion per employee
- Display progress in staff, admin, and reporting views

Recipes:
- Admin can create, edit, delete, activate/deactivate, and import recipes from Excel or Word
- Recipe fields: title, category, tags, seasonal status, season, required status, active status, image, source, and ordered steps
- Desktop recipe detail: portrait image left, steps right
- Mobile recipe detail: image above steps
- When no image exists, steps use the full width
- Image lightbox on click
- Recipe cards should not require thumbnail photos
- Recipe quizzes require perfect scores for quiz mastery
- Manager verification also counts as recipe mastery
- Prevent duplicate quiz submissions
- Disable selected answers immediately and show a loading indicator
- Show correct or incorrect feedback after each answer
- Show the correct answer at quiz completion if the final answer was wrong

Stages:
- Recipes grouped into ordered stages
- Support prerequisite stages
- Recipes may be viewable before unlocked, but quizzes remain locked
- A stage is complete when all currently active, required recipes are mastered
- Inactive recipes must never count against completion, badges, progress, or recommendations
- Use "Incomplete" for unlocked stages that are not completed
- On the staff home page, recommend the first incomplete required recipe in the earliest unlocked, incomplete stage

Seasonal recipes:
- Default recommendation: assign seasonal recipes to their functional skill stage, such as Tea, Matcha, Espresso, or Lemonade
- Seasonal recipes should be optional by default
- Seasonal recipes can be activated/deactivated by location
- Add a dedicated Seasonal Stage only when an organization needs a separate, required campaign menu
- Admin Recipe Builder filters:
  - All recipes / seasonal only / non-seasonal
  - Stage
  - Unassigned
  - Search recipe title, category, and tags
  - Multiple search words narrow the result set

Badges:
Provide default badges but make all badge names, visuals, and rules configurable:
- Basics
- Hospitality
- Tea Master
- Espresso Pro
- Matcha Maven
- Trained

Default rules:
- Basics: all active Basics lessons completed
- Hospitality: all configured hospitality pillars completed
- Tea Master: all active required Tea-stage recipes mastered
- Espresso Pro: all active required Espresso-stage recipes mastered
- Matcha Maven: all active required Matcha-stage recipes mastered
- Trained: all active required training across Basics, Hospitality, and required stages completed

Badge behavior:
- Use simple custom UI badges: a small colored circle with a distinct mark and restrained label
- Show earned badges in Login roster, Staff Home page, Staff Progress page, and relevant completed stage cards
- If a person earns Trained, show only the Trained badge
- For fully trained staff, show:
  - "CONGRATULATIONS"
  - "You're fully trained!"
  - "You've completed the [Organization Name] training path."

Admin dashboard:
Create tabs for Team, Recipes, Stages, Basics, Hospitality, Brand, Locations, Badges, and Reports.

Team:
- Staff cards with Basics, Hospitality, Recipes, and badge progress
- Search by name and role
- Change roles
- Activate/deactivate staff without deleting history
- Open a recipe verification checklist
- Save manager verification changes in a batch
- Do not reset the checklist after a single selection

Reports:
- Filter by organization, location, role, training area, stage, badge, and date range
- Show completion percentages, recent training activity, and employees close to completing a stage
- Export CSV

Netlify:
- Create netlify.toml
- Publish static files from dist
- Place all APIs in netlify/functions
- Use environment variables:
  - SUPABASE_URL
  - SUPABASE_ANON_KEY if needed client-side
  - SUPABASE_SERVICE_ROLE_KEY server-side only
- Add redirects so SPA routes work on refresh
- Provide local development instructions using netlify dev
- Provide production deployment instructions using:
  npx netlify deploy --prod --dir=dist --functions=netlify/functions

Supabase:
- Provide SQL migrations
- Set RLS policies for tenant separation
- Provide seed data for two sample organizations, multiple locations, admins, leads, staff, courses, lessons, hospitality scenarios, stages, recipes, and badges
- Store image uploads in organization-scoped Supabase Storage paths

Quality:
- Responsive desktop, tablet, and mobile design
- Accessible keyboard navigation, focus states, labels, semantic controls, and screen-reader status updates
- Avoid duplicate submissions
- Show saving/loading feedback for network actions
- Keep data behavior consistent across Home, Progress, stages, badges, admin dashboard, and reports

Deliver:
1. Full source code
2. netlify.toml
3. Netlify Functions
4. Supabase migrations and seed scripts
5. Environment variable documentation
6. Local setup instructions
7. Netlify deployment instructions
8. A concise README explaining the multi-tenant architecture and how to onboard a new organization

Always test with a test staff profile first. Back up curriculum and staff data before major changes.