This module allows users to track their domain names and receive automatic email reminders before expiration dates.
- List all domain names with expiration dates
- Track registrar information with clickable links
- Monitor auto-renewal status
- Sort domains by name, registrar, or expiration date
- Configure email reminders (1 month and/or 1 week before expiration)
- Visual indicators for expiring and expired domains
Add the following to your .env file:
# Resend API Key for sending emails
RESEND_API_KEY=re_xxxxxxxxxxxxx
# Email sender address (must be verified in Resend)
EMAIL_FROM=noreply@yourdomain.com
# Secret token for cron job authentication
CRON_SECRET_DOMAIN_NAME_MODULE=your-secret-token-hereRun the Prisma migration to create the necessary database tables:
pnpm prisma migrate dev --name add_domain_names- Create an account at resend.com
- Get your API key from the dashboard
- Add and verify your sending domain
- Update
EMAIL_FROMwith your verified email address
- Click the "Add Domain" button
- Fill in the domain information:
- Domain name (e.g., example.com)
- Registrar (e.g., Porkbun, Namecheap)
- Registrar URL (optional, for quick access)
- Expiration date
- Auto-renewal status
- Email reminder preferences
- Edit: Click the edit icon to modify domain information
- Delete: Click the delete icon to remove a domain
- Sort: Click column headers to sort by registrar, domain, or expiration date
The system will automatically send email reminders based on your preferences:
- 1 Month Reminder: Sent 30 days before expiration (if enabled)
- 1 Week Reminder: Sent 7 days before expiration (if enabled)
Emails include:
- Domain name
- Registrar with clickable link
- Expiration date
- Auto-renewal status
You can set up automated reminders using a cron service like:
Add to your vercel.json:
{
"crons": [
{
"path": "/api/cron/domain-reminders",
"schedule": "0 9 * * *"
}
]
}Create a scheduled job that calls:
GET https://yourdomain.com/api/cron/domain-reminders
Headers:
Authorization: Bearer your-cron-secret-token
You can also manually trigger reminders by calling the API endpoint:
curl -X GET https://yourdomain.com/api/cron/domain-reminders \
-H "Authorization: Bearer your-cron-secret-token"- The cron endpoint is protected by a secret token
- Only authenticated users can view and manage their domains
- Email addresses are never exposed to other users
- Verify your
RESEND_API_KEYis correct - Ensure your sending domain is verified in Resend
- Check that
EMAIL_FROMmatches a verified email address - Review Resend dashboard for error logs
- Verify
CRON_SECRET_DOMAIN_NAME_MODULEmatches in both your environment and cron service - Check cron service logs for errors
- Ensure the endpoint is accessible from the internet
- Ensure you're logged in
- Check browser console for errors
- Verify database migration completed successfully