Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/Nyverie/reservafacil/llms.txt

Use this file to discover all available pages before exploring further.

ReservaFácil (CanchaYA) is a sports court booking platform built with Next.js 16, Prisma, and PostgreSQL. It lets end users browse available courts and make reservations, while admins confirm bookings and superadmins manage the full system — users, courts, and revenue reports.

Quickstart

Clone the repo, configure your database, seed test data, and run the app locally in minutes.

Environment Setup

Configure your PostgreSQL database URL, JWT secret, and production URL.

Roles & Permissions

Understand the three-tier role system: USUARIO, ADMIN, and SUPERADMIN.

API Reference

Full REST API documentation for auth, courts, reservations, and user management.

What ReservaFácil Does

ReservaFácil manages the complete lifecycle of a sports court reservation — from browsing available courts to booking a time slot, and from an admin confirming the booking to a superadmin generating revenue reports.

Book Courts

Browse football, tennis, basketball, and volleyball courts. Reserve any available slot with automatic conflict detection.

Manage Reservations

View your booking history, check statuses, and cancel pending reservations.

Admin Panel

Confirm or cancel user bookings, manage courts, and monitor pending reservations.

Get Running in 4 Steps

1

Clone and install dependencies

git clone https://github.com/Nyverie/reservafacil.git
cd reservafacil
npm install
2

Configure environment variables

Copy .env.example to .env.local and fill in your PostgreSQL connection string and JWT secret.
cp .env.example .env.local
3

Set up the database

Run Prisma migrations and seed the database with test accounts and sample courts.
npx prisma db push
npm run seed
4

Start the development server

npm run dev
Open http://localhost:3000 — you’ll be redirected to the login page.
The seed script creates three test accounts: superadmin@reservafacil.com (password: superadmin123), admin@reservafacil.com (password: admin123), and usuario@reservafacil.com (password: usuario123).

Build docs developers (and LLMs) love