Your AI Digital Safety Agent
ScamShield AI is an AI-powered digital safety assistant that helps users identify suspicious messages, understand scam indicators, assess risk, and receive practical recovery guidance.
It combines a React frontend, FastAPI backend, and Google Gemini AI to provide an easy-to-use scam detection experience.
Paste a suspicious SMS, WhatsApp message, email, job offer, investment message, or payment request and let ScamShield analyze it.
The system provides:
- Scam type
- Risk score
- Risk level
- Confidence score
- Explanation of suspicious indicators
- Recommended actions
Upload a screenshot of a suspicious conversation or message and analyze its contents using AI.
If you have already interacted with a scam, ScamShield provides personalized guidance and recommended next steps.
The application includes sample scenarios such as:
- ๐ผ Job scams
- ๐ฆ OTP scams
- ๐ฐ Investment scams
โโโโโโโโโโโโโโโโโโโโโโโโ
โ React.js โ
โ Frontend โ
โ Vercel โ
โโโโโโโโโโโโฌโโโโโโโโโโโโ
โ
โ REST API
โผ
โโโโโโโโโโโโโโโโโโโโโโโโ
โ FastAPI โ
โ Backend โ
โ Render โ
โโโโโโโโโโโโฌโโโโโโโโโโโโ
โ
โผ
โโโโโโโโโโโโโโโโโโโโโโโโ
โ Google Gemini AI โ
โ Scam Analysis โ
โโโโโโโโโโโโโโโโโโโโโโโโ
- React.js
- JavaScript
- HTML
- CSS
- Vercel
- Python
- FastAPI
- Uvicorn
- Pydantic
- REST APIs
- Render
- Google Gemini AI
- Google Gen AI SDK
- Git
- GitHub
- VS Code
- Python Virtual Environment
ScamShield-AI/
โ
โโโ backend/
โ โโโ main.py
โ โโโ gemini_service.py
โ โโโ requirements.txt
โ โโโ venv/
โ
โโโ frontend/
โ โโโ src/
โ โ โโโ App.jsx
โ โ โโโ ...
โ โโโ package.json
โ โโโ ...
โ
โโโ README.md
Note: Do not commit the
venv/directory to GitHub. Add it to.gitignore.
| Method | Endpoint | Purpose |
|---|---|---|
| GET | / |
Backend health/home endpoint |
| POST | /analyze |
Analyze a suspicious message |
| POST | /recovery |
Generate recovery guidance |
| POST | /analyze-screenshot |
Analyze a suspicious screenshot |
curl -X POST \
"https://scamshield-ai-dfc5.onrender.com/analyze" \
-H "Content-Type: application/json" \
-d '{
"message": "Congratulations! You have been selected for a work-from-home job. Pay โน1499 as a refundable registration fee within 20 minutes."
}'{
"scam_type": "Fake Job / Advance-Fee Scam",
"risk_score": 95,
"risk_level": "CRITICAL",
"confidence": 98,
"summary": "This message displays clear indicators of an employment scam.",
"indicators": [
"Demands an upfront payment or registration fee",
"Uses artificial urgency",
"Claims job selection without a prior application process"
],
"recommended_actions": [
"Do not pay any money or share bank/personal details.",
"Block and report the sender immediately."
]
}git clone https://github.com/ramritheesh/ScamShield-AI.git
cd ScamShield-AINavigate to the backend:
cd backendCreate a virtual environment:
python3 -m venv venvActivate it:
source venv/bin/activateInstall dependencies:
pip install -r requirements.txtCreate a .env file inside the backend directory:
GEMINI_API_KEY=your_google_gemini_api_keyStart the FastAPI server:
uvicorn main:app --reloadThe backend will be available at:
http://127.0.0.1:8000
FastAPI Swagger documentation:
http://127.0.0.1:8000/docs
Open another terminal:
cd frontendInstall dependencies:
npm installStart the development server:
npm run devOpen the URL shown by Vite, usually:
http://localhost:5173
ScamShield requires a Gemini API key.
Create:
backend/.env
Add:
GEMINI_API_KEY=your_google_gemini_api_keyNever commit your API key to GitHub.
Add the following to .gitignore:
.env
venv/
__pycache__/
*.pyc
For production deployment, configure GEMINI_API_KEY in the backend hosting platform's environment variables.
The React frontend is deployed using Vercel.
The FastAPI backend is deployed using Render.
Production architecture:
User
โ
โผ
Vercel
React Frontend
โ
โ HTTPS REST API
โผ
Render
FastAPI Backend
โ
โผ
Google Gemini API
Congratulations! You have been selected for a work-from-home job.
Pay โน1499 as a refundable registration fee within 20 minutes.
Your account will be blocked today.
Share the OTP you received to verify your account immediately.
Invest โน5000 today and get guaranteed returns of โน50,000 within one week.
Limited slots available. Pay now.
These examples demonstrate common warning signs such as:
- Artificial urgency
- Requests for money
- OTP requests
- Guaranteed returns
- Pressure to act immediately
- Requests for sensitive information
Online scams often rely on:
- Urgency
- Fear
- Attractive rewards
- Fake job opportunities
- Impersonation
- Requests for sensitive information
- Advance payments
ScamShield AI provides users with a second layer of protection by helping them pause, understand the warning signs, and make safer decisions.
Detect. Understand. Recover.
Planned improvements include:
- ๐ Multilingual scam detection
- ๐ URL and link safety analysis
- ๐ฑ Sender and phone number risk analysis
- ๐ง Improved scam classification
- ๐ผ๏ธ Advanced OCR for screenshots
- ๐ Scam trend analytics
- ๐ Real-time scam alerts
- ๐ก๏ธ Browser and mobile integration
- ๐ฌ More personalized recovery workflows
ScamShield AI is an assistive tool and should not be treated as a guaranteed scam detector.
AI-generated results may occasionally be incorrect. Users should independently verify suspicious communications through official channels.
Never share:
- Passwords
- OTPs
- Bank details
- UPI PINs
- Credit/debit card details
- Other sensitive information
Ram Ritheesh
Built as an AI-powered digital safety project using:
React.js โข FastAPI โข Python โข Google Gemini AI
Contributions, ideas, and improvements are welcome.
git checkout -b feature/your-featuregit add .
git commit -m "Add your feature"git push origin feature/your-featureThis project is intended for educational and demonstration purposes.