Overview
Di Gusto is a luxury Italian lifestyle platform delivering AI-powered culinary storytelling. It provides subscribers with interactive stories, curated recipes, wine guides, and rich cultural content — all infused with cutting-edge generative AI for imagery, video, and music.
The platform spans iOS, Android, and Web, built on a modern serverless stack that prioritises performance, scalability, and a premium user experience.
Platform Highlights
Architecture
Di Gusto follows a multi-tier architecture with clear separation between client, API, data, and AI layers. All services communicate over HTTPS; sensitive operations are gated behind Supabase RLS policies and Edge Function authorization.
| Layer | Technology | Notes |
|---|---|---|
| Frontend | React Native Expo ~52 TypeScript | Universal app — iOS, Android, Web. Web build deployed to Vercel. |
| Backend / DB | Supabase PostgreSQL 15 RLS | Project ID: hvzvoihvmvbcagtspmwu. Edge Functions for server-side logic. |
| AI / Media | Vertex AI Imagen 3 Veo 2 Lyria | All AI calls proxied through Supabase Edge Functions to protect GCP credentials. |
| CMS | Sanity v3 | Project ID: kuho1qzi. Hosted at cms.digusto.ai. |
| Payments | Stripe StoreKit 2 | Stripe for web subscriptions + token purchases. StoreKit for native iOS IAP. |
| CDN / DNS | Cloudflare | Proxies all subdomains under digusto.ai. SSL managed by Cloudflare. |
| Hosting | Vercel Expo EAS | Vercel for web; Expo EAS Build + Submit for native app stores. |
| CI / CD | GitHub Actions | Automated deploy on push to main, dev, staging branches. |
Data Flow
Client requests flow through Cloudflare's CDN to either the Vercel edge (web) or directly to Supabase (API). AI generation requests are always server-side via Edge Functions — never client-direct — to protect GCP credentials and enforce rate limiting.
Expo App
CDN + WAF
Auth + API
Deno Runtime
GCP
Setup
Prerequisites
| Tool | Version | Install |
|---|---|---|
| Node.js | 20+ |
nodejs.org or nvm install 20 |
| Expo CLI | latest | npm install -g expo-cli |
| Supabase CLI | latest | brew install supabase/tap/supabase |
| Git | 2.x+ | System package manager |
| Xcode (iOS) | 15+ | Mac App Store — required for iOS simulator |
Local Development
git clone https://github.com/digusto/digusto-app.git
cd digusto-app
npm install --legacy-peer-deps
--legacy-peer-deps flag is required due to React Native peer dependency constraints in Expo 52.cp .env.example .env.local
npx expo start
w for web, i for iOS simulator, a for Android emulator.Environment Variables
| Variable | Description | Required |
|---|---|---|
| SUPABASE_URL | Supabase project URL (e.g. https://hvzvoihvmvbcagtspmwu.supabase.co) |
Required |
| SUPABASE_ANON_KEY | Public anon key — safe to expose to clients | Required |
| SANITY_PROJECT_ID | Sanity project ID: kuho1qzi |
Required |
| SANITY_DATASET | Usually production |
Required |
| STRIPE_PK | Stripe publishable key (starts with pk_) |
Required |
| EXPO_PUBLIC_APP_ENV | development | staging | production |
Optional |
| SENTRY_DSN | Sentry error tracking DSN | Optional |
.env.local file is gitignored. Never commit SUPABASE_SERVICE_ROLE_KEY, GCP credentials, or Stripe secret keys to version control.
API & Edge Functions
Server-side business logic is implemented as Supabase Edge Functions (Deno runtime). They are deployed to https://hvzvoihvmvbcagtspmwu.supabase.co/functions/v1/.
Core Edge Functions
Authentication
All Edge Functions validate the Supabase JWT from the Authorization: Bearer <token> header. Unauthenticated requests receive 401. Admin-only functions additionally check the user role claim.
// Client-side call example
const { data, error } = await supabase.functions.invoke('generate-image', {
body: {
prompt: 'Rustic Sicilian arancini on marble, golden hour',
style: 'editorial',
aspectRatio: '16:9',
},
});
Rate Limiting
AI generation endpoints are rate-limited per user tier: Free (5/day), Subscriber (50/day), Premium (unlimited). Limits are enforced in the Edge Function using a Redis-backed counter in Supabase.
Components
The component library is documented and previewed at sb.digusto.ai (Storybook). Below is an overview of the major component categories.
Design System
Di Gusto uses a custom design system with IBM Plex Sans as the primary typeface. The palette centres on warm gold (#e4d5b7) on deep zinc (#09090b) for a premium feel. Component tokens are defined in constants/theme.ts.
export const theme = {
colors: {
bg: '#09090b',
gold: '#e4d5b7',
goldDim: '#b8a88a',
text: '#fafafa',
textMuted: '#71717a',
},
radii: { sm: 6, md: 12, lg: 20, full: 9999 },
spacing: { xs: 4, sm: 8, md: 16, lg: 24, xl: 40 },
};
Database
Supabase project ID: hvzvoihvmvbcagtspmwu — hosted on ap-southeast-1. PostgreSQL 15 with Row Level Security enforced on all user-scoped tables.
Schema Overview
RLS Policies
All tables use auth.uid()-based policies. Users can only read and write their own rows. Service role is used exclusively from Edge Functions for cross-user operations (e.g. referral crediting).
-- Example: users can only read their own profile
CREATE POLICY "user_profiles_select"
ON user_profiles
FOR SELECT USING (auth.uid() = id);
CREATE POLICY "user_profiles_update"
ON user_profiles
FOR UPDATE USING (auth.uid() = id);
Migrations
# Apply pending migrations to remote Supabase
supabase db push
# Generate migration from local schema diff
supabase db diff --use-migra -f my_migration_name
# Run migrations locally (requires Docker)
supabase start
supabase db reset
Deployment
Web (Vercel)
npm run build:web
dist/. Expo uses Metro bundler with web target.vercel --prod
main → digusto.ai. Feature branches get preview URLs.Mobile (Expo EAS)
# Build for iOS (App Store distribution)
eas build --platform ios --profile production
# Build for Android
eas build --platform android --profile production
# Submit to App Store
eas submit --platform ios
GitHub Actions CI
Pushes to main, dev, and staging trigger the following pipeline:
main deploys to digusto.ai (production) ·
staging deploys to staging.digusto.ai ·
dev deploys to dev.digusto.ai
Supabase Edge Functions
# Deploy all edge functions
supabase functions deploy
# Deploy single function
supabase functions deploy generate-image
# Tail function logs
supabase functions logs generate-image --scroll
Subdomains
All subdomains are served under digusto.ai, managed via Cloudflare DNS. Web properties are hosted on Vercel; non-web services use CNAME or A records to their respective providers.
dev branch
Dev
staging branch
Staging
DNS Configuration
All subdomains point to Vercel via CNAME records with Cloudflare proxy disabled (dns_only) so Vercel can manage TLS certificates.
# All web subdomains
*.digusto.ai CNAME cname.vercel-dns.com (dns_only)
# Sanity (hosted by Sanity.io)
cms.digusto.ai CNAME cms.sanity.io