The Operations
Brain of irfaninvest

Every visit, lead, ad dirham and phone call from irfaninvest.com — captured, analysed and acted on automatically. Marketing analytics, an AI voice agent and lead operations in one password-gated dashboard.

Page views · 30d
449
Users · 28d
4.7k
Leads tracked
128
Voice calls
10
Sync cadence
30 min
Next lead call-back
≤ 2 minutes
Next.js 16React 19Tailwind 4Supabasen8nVapiTwilioClaude AIGA4Google AdsRecharts
About the software

One codebase, four systems, zero manual work

irfanapp is the server-rendered Next.js companion to irfaninvest.com. It ingests marketing data from Google, lead data from the website, and voice data from the AI call agent — then turns them into decisions: who to call, what to say, and which campaign is paying for itself.

28
API endpoints — 12 of them n8n ingest webhooks
11
live dashboard tabs, from Marketing to Voice
2 min
from form submission to the first AI phone call
Modules

Everything the sales floor needs, nothing it doesn't

Marketing Analytics

GA4 traffic, Google Ads spend and campaign performance unified in one view — synced from n8n every 30 minutes.

Lead Pipeline

Website forms and the AI chat flow straight into Supabase and Google Sheets, deduplicated and scored automatically.

AI Voice Agent

"Sam" calls every new lead within 2 minutes via Vapi + Twilio, books consultations and records full transcripts.

AI Insights

Claude analyses every call and lead: buyer persona, sentiment, objections and a recommended closing strategy — 17 signals per conversation.

Inside the stack

In the spotlight

Architecture

Server-rendered Next.js — no database keys ever reach the browser

All Supabase access lives in 28 API routes. The public site and this dashboard share one database, cleanly separated.

Automation

Two live n8n workflows keep every number fresh

A 30-minute pipeline syncs GA4, Ads, forms and AI conversations; a 2-minute watcher auto-calls brand-new leads.

Security

Password gate, HMAC sessions and row-level security

Every page and data API sits behind an httpOnly signed cookie; Supabase RLS blocks anonymous access to content tables.

Voice AI

From hang-up to insight in under a minute

Vapi posts the end-of-call report to n8n, which writes the transcript, psychology profile and call record to two report sheets and this dashboard.

From ad click to booked consultation — one pipeline

  • 1Visitor clicks a Google Ad and submits a form on irfaninvest.com
  • 2Edge function stores the lead in Supabase and mirrors it to Google Sheets
  • 3"Sam" — the AI voice agent — calls within 2 minutes, in the caller's language
  • 4Transcript, psychology profile and call record land in the dashboard and report sheets
See it live
irfaninvest.com · form / chat / call
Supabase leads · call_attempts
│ ▲
n8n 30-min sync · 2-min auto-call
Vapi +1 775 451 2951 · "Sam"
irfanapp /dashboard · 11 tabs
FAQ

Frequently asked questions

How do leads flow through the system?

A visitor submits a form on irfaninvest.com → a Supabase edge function stores the lead and mirrors it to Google Sheets → n8n picks it up, and the dashboard shows it within 30 minutes (voice-eligible leads are called within 2).

Which AI models power it?

Claude (Anthropic) runs the voice agent "Sam", the post-call psychology analysis and the AI Insights tab. GPT-4o-mini handles lead qualification inside n8n.

What happens after a phone call ends?

Vapi sends the end-of-call report to n8n: the lead status updates in the dashboard, the call record lands in the report-after-call sheet, and the transcript plus 17-field buyer-psychology profile lands in the conversation sheet.

How is the dashboard secured?

A shared password issues a 30-day HMAC-signed httpOnly cookie; the Next.js proxy gates every page and data API. Machines (n8n) authenticate with a separate header secret. Supabase RLS protects the shared tables.

How is it integrated with irfaninvest.com?

Same Supabase project, same Peyda brand font, same lead schema. The site writes leads; this app reads, scores, calls and reports on them — nothing is duplicated.

How fresh is the data?

GA4, Google Ads, form leads and AI conversations sync every 30 minutes. New-lead auto-calling runs every 2 minutes. A public /api/health probe reports database latency live.