Documentation Index
Fetch the complete documentation index at: https://mintlify.com/Jesus-Puertos/h-ayuntamiento/llms.txt
Use this file to discover all available pages before exploring further.
System Requirements
Before installing, ensure your system meets these requirements:Node.js
Version 18.14.1 or higherDownload from nodejs.org
Package Manager
npm, yarn, or pnpmnpm comes with Node.js
Git
Latest stable versionFor cloning the repository
Supabase Account
Free tier availableSign up at supabase.com
Install Dependencies
Install Packages
Choose your preferred package manager:This installs all dependencies from
package.json:- Astro (v5.16.6) - SSR framework
- React (v19.2.3) - UI components
- Supabase (v2.93.2) - Backend services
- TailwindCSS (v4.1.18) - Styling
- Three.js (v0.182.0) - 3D graphics
- GSAP (v3.14.2) - Animations
- And 30+ other packages
Environment Setup
Configure Supabase Credentials
Edit Get these values from Supabase:
.env with your Supabase project details:.env
- Go to app.supabase.com
- Select your project
- Navigate to Settings > API
- Copy Project URL →
PUBLIC_SUPABASE_URL - Copy anon public key →
PUBLIC_SUPABASE_ANON_KEY
Configure OAuth Providers (Optional)
For Google/Facebook login, add OAuth credentials:Google OAuth:
- Go to console.cloud.google.com
- Create a new project or select existing
- Enable Google+ API
- Go to Credentials > Create OAuth 2.0 Client ID
- Add authorized redirect URI:
- In Supabase: Authentication > Providers > Google
- Enable Google and paste Client ID and Secret
- Go to developers.facebook.com
- Create an app
- Add Facebook Login product
- Add OAuth redirect URI:
https://your-project.supabase.co/auth/v1/callback - In Supabase: Authentication > Providers > Facebook
- Enable Facebook and paste App ID and Secret
OAuth is optional. The platform also supports email/password authentication out of the box.
Database Setup
Create Supabase Project
- Go to app.supabase.com
- Click New Project
- Enter project details:
- Name:
zongolica-turismo - Database Password: (save this securely)
- Region: Choose closest to your users (e.g., South America - São Paulo)
- Name:
- Click Create new project (takes ~2 minutes)
Run Database Migration
Go to SQL Editor in Supabase and run this schema:Click Run to execute the migration.
supabase-setup.sql
Configure Storage Bucket
The SQL script creates a
tickets bucket. Verify it:- Go to Storage in Supabase
- Confirm
ticketsbucket exists - Ensure it’s set to Public
- This bucket stores generated route ticket images
Build and Deploy
Deploy to Vercel
The platform is optimized for Vercel deployment:
- Push your code to GitHub/GitLab/Bitbucket
- Go to vercel.com
- Click Import Project
- Select your repository
- Configure build settings:
- Framework Preset: Astro
- Build Command:
npm run build - Output Directory:
dist
- Add environment variables:
PUBLIC_SUPABASE_URLPUBLIC_SUPABASE_ANON_KEY- Any other variables from your
.env
- Click Deploy
Update OAuth Redirect URLs
After deployment, update OAuth settings:In Supabase (Authentication > URL Configuration):
- Site URL:
https://your-domain.com - Redirect URLs:
https://your-domain.com/auth/callbackhttp://localhost:4321/auth/callback(for development)
- Add authorized redirect URI:
https://your-project.supabase.co/auth/v1/callback
- Add OAuth redirect URI:
https://your-project.supabase.co/auth/v1/callback
Verify Installation
Check Homepage
Visit your deployed site and verify:
- Government portal loads
- Navigation works
- Images display correctly
Test Authentication
- Go to
/turismo - Click to start onboarding
- Try logging in with Google/Email
- Verify redirect works
Test Tourism Features
- Complete the onboarding flow
- Verify preferences are saved
- Check that route ticket is generated
- Try sharing a route
Production Checklist
- Update all OAuth redirect URLs to production domain
- Enable email confirmation in Supabase
- Set up CORS policies in Supabase if needed
- Configure rate limiting for auth endpoints
- Add analytics (Google Analytics, Plausible, etc.)
- Optimize images with CDN
- Set up monitoring and error tracking
- Review RLS policies for security
- Test all user flows end-to-end
- Set up automated backups in Supabase
Supabase Free Tier Limits
The free tier is suitable for development and moderate production use:
- Database: 500 MB
- Storage: 1 GB
- Bandwidth: 2 GB/month
- Auth Users: Unlimited
- API Requests: Unlimited
Next Steps
Government Portal Features
Learn about institutional pages and services
Tourism System
Explore the Xochitlanis onboarding and gamification
Multilingual Support
Configure and manage translations
Authentication
Deep dive into user management
