API Pulse is a modern, full-stack API monitoring and alerting platform. It leverages Next.js 14, Supabase, AWS Lambda, and SQS to provide scalable, real-time monitoring, alerting, and analytics for your APIs.
- 🔍 API Monitoring: Monitor multiple API endpoints for uptime, performance, and reliability
- 📊 Dashboard: Real-time dashboard with status cards, analytics, and incident history
- 🛠️ Bulk Operations: Enable, disable, or delete multiple monitors at once
- 📧 Alerts: Email notifications via Resend and (optionally) SMS via Twilio
- 🔐 Authentication: Secure user authentication with Supabase
- ⚡ Real-time: Live updates and notifications
- ☁️ Serverless Backend: AWS Lambda workers process monitoring jobs from SQS queues
- 🕒 Custom Intervals: Flexible scheduling for each monitor
- 🏷️ Tagging & Filtering: Organize and filter monitors by status, interval, or name
- 🎨 Modern UI: Built with shadcn/ui, Lucide icons, and Tailwind CSS
- Frontend: Next.js 14 (App Router, React Server/Client Components)
- Backend: API routes (Next.js), AWS Lambda (monitoring worker)
- Database: Supabase (PostgreSQL, RLS enabled)
- Queueing: AWS SQS (multiple queues for checks, alerts, priority, DLQ)
- Authentication: Supabase Auth
- Styling: Tailwind CSS, shadcn/ui, Lucide icons
- Email: Resend (email alerts), Twilio (optional SMS)
- Deployment: Vercel, AWS
- Node.js 18+
- npm or yarn
- Supabase account (for database and auth)
- AWS account (for Lambda, SQS, IAM)
- Resend account (for email alerts)
- (Optional) Twilio account (for SMS alerts)
- Clone the repository
- Install dependencies:
npm install
- Copy environment variables:
- See the list of required variables in the section below. Create a
.envfile in the root directory.
- See the list of required variables in the section below. Create a
- Update
.envwith your configuration mentioned in the next section. - Start the development server:
npm run dev
- Open http://localhost:3000 in your browser
You must set the following environment variables in .env:
CRON_SECRET- Auth secret for the schedulerNEXT_PUBLIC_SUPABASE_URL- Your Supabase project URLNEXT_PUBLIC_SUPABASE_ANON_KEY- Supabase anon/public keySUPABASE_SERVICE_ROLE_KEY- Supabase service role key (for backend jobs)RESEND_API_KEY- Resend API key for email alertsRESEND_FROM_EMAIL- Email to send messages fromAWS_REGION- AWS region for Lambda/SQSAWS_ACCESS_KEY_ID- AWS access key for Lambda/SQSAWS_SECRET_ACCESS_KEY- AWS secret key for Lambda/SQSSQS_QUEUE_MONITORCHECKS- SQS queue URL for monitor checksSQS_QUEUE_PRIORITYCHECKS- SQS queue URL for priority checksSQS_QUEUE_ALERTPROCESSING- SQS queue URL for alert processingSQS_QUEUE_SCHEDULER- SQS queue URL for schedulerSQS_QUEUE_DLQ_FIFO- SQS dead letter queue (FIFO) URLSQS_QUEUE_DLQ_STANDARD- SQS dead letter queue (standard) URL- (Optional)
TWILIO_ACCOUNT_SID,TWILIO_AUTH_TOKEN,TWILIO_PHONE_NUMBER- for SMS alerts
You can check your environment config with:
npm run test-sqs configThe application uses Supabase with Row Level Security (RLS) enabled. Main tables:
monitors: API endpoint definitions and configmonitoring_history: Historical check resultsalert_rules: Alerting rules per monitornotification_channels: Email/SMS destinationsalert_logs: Stores all alert events and notification delivery logs
- Frontend: Next.js 14 (App Router, React Server/Client Components)
- API Routes: All backend logic in
app/api/(monitors, alerts, notification channels, etc.) - Supabase: Stores user, monitor, and history data
- AWS Lambda: Runs monitoring jobs, triggered by SQS events
- AWS SQS: Queues for monitor checks, priority checks, alerts, and DLQ
- AWS EventBridge: Triggers the scheduler Lambda on a schedule (replaces Vercel Cron)
- CloudWatch: Logs, alarms, and dashboards for Lambda and SQS
- Infrastructure as Code: CloudFormation YAML in
infrastructure/aws/
npm run dev- Start development servernpm run build- Build for productionnpm run start- Start production servernpm run lint- Run ESLintnpm run type-check- Run TypeScript checksnpm run test-sqs test- Run SQS client integration testnpm run test-sqs health- Check SQS queue healthnpm run test-sqs config- Check environment config
See infrastructure/aws/lambda-infrastructure.yaml for CloudFormation resources:
- Lambda worker, IAM roles, SQS queues, event source mappings, CloudWatch alarms, and dashboards
MIT