CryptoNotify is a comprehensive cryptocurrency tracking and notification platform built with Next.js, MongoDB, CoinGecko API, and Kestra for automated notifications.
- Real-time cryptocurrency price tracking
- Personalized price threshold alerts
- User authentication
- Detailed crypto insights
- Email notifications for price changes
- Frontend: Next.js 14
- Database: MongoDB
- Authentication: NextAuth.js
- Price Data: CoinGecko API
- Notification Workflow: Kestra
- Styling: Tailwind CSS
- Node.js (v18+)
- MongoDB
- CoinGecko API Key
- SMTP Email Service
- Clone the repository
git clone https://github.com/yourusername/cryptopulse.git
cd cryptopulse- Install dependencies
npm install- Create
.env.localfile
# MongoDB Connection
MONGODB_URI=your_mongodb_connection_string
# NextAuth Configuration
NEXTAUTH_SECRET=your_nextauth_secret
NEXTAUTH_URL=http://localhost:3000
# CoinGecko API
COINGECKO_API_URL=https://api.coingecko.com/api/v3
# Email Service
EMAIL_SERVICE_USER=your_email
EMAIL_SERVICE_PASS=your_email_password
# Kestra Configuration
KESTRA_API_ENDPOINT=your_kestra_endpointcryptopulse/
├── app/
│ ├── api/
│ │ ├── auth/
│ │ ├── blockchains/
│ │ ├── coins/
│ │ ├── cron/
│ │ ├── updatethreshold/
│ │ ├── user/
│ │ └── userthresholds/
│ ├── dashboard/
│ │ └── page.tsx
│ ├── explore/
│ │ └── page.tsx
│ ├── [cryptoId]/
│ │ └── page.jsx
│ ├── models/
│ ├── layout.tsx
│ ├── page.tsx
│ └── globals.css
├── components/
│ ├── blockchain/
│ ├── ui/
│ ├── Navbar.tsx
│ ├── SearchBar.tsx
│ ├── ThresholdForm.tsx
│ ├── auth-dialog.tsx
│ ├── user-menu.tsx
│ ├── theme-provider.tsx
│ ├── theme-toggle.tsx
│ └── ClientSessionProvider.tsx
├── public/
│ ├── Analytics.png
│ ├── AlertDashboard.png
│ ├── CryptoNotify.png
│ └── logo.png
├── lib/
│ ├── api.ts
│ ├── cache.ts
│ ├── mongodb.ts
│ └── utils.ts
├── hooks/
│ ├── useDebounce.ts
│ ├── use-toast.ts
│ └── useBlockchainSearch.ts
├── types/
│ └── blockchain.ts
├── kestra/
│ └── crypto-price-monitor.yaml
├── package.json
├── tailwind.config.ts
├── tsconfig.json
└── ... (other config and system files)
- Google, Email providers
- Custom login/signup flows
// lib/coingecko.js
export async function fetchCryptoData(cryptoId) {
const response = await fetch(`https://api.coingecko.com/api/v3/coins/${cryptoId}`);
return response.json();
}
export async function fetchMarketData() {
const response = await fetch('https://api.coingecko.com/api/v3/coins/markets?vs_currency=usd&order=market_cap_desc&per_page=100');
return response.json();
}id: crypto-price-monitor
namespace: crypto.alerts
tasks:
- id: fetch-crypto-prices
type: io.kestra.core.tasks.scripts.Python
script: |
# Fetch prices and check thresholds
def monitor_crypto_prices():
# MongoDB connection
# Fetch user watchlists
# Compare current prices with thresholds
# Trigger notifications
pass
triggers:
- id: every-5-minutes
type: io.kestra.core.triggers.Cron
config:
cron: "*/5 * * * *"
## Running the Project
```bash
# Development Mode
npm run dev
# Production Build
npm run build
npm start
- Environment variable protection
- Secure API key management
- Rate limiting on crypto data fetching
- Crypto-themed background animations
- Project introduction
- Technology stack overview
- Cryptocurrency market data
- Comprehensive crypto statistics
- Price history graphs
- Market sentiment indicators
- User's crypto watchlist
- Threshold management
- Notification preferences
- Fork the repository
- Create your feature branch
- Commit your changes
- Push to the branch
- Create a Pull Request
Happy HackFrost 2024




