{"id":26897011,"url":"https://github.com/hardhat-enterprises/smishing-backend","last_synced_at":"2026-04-09T23:03:13.340Z","repository":{"id":285438429,"uuid":"956537496","full_name":"Hardhat-Enterprises/smishing-backend","owner":"Hardhat-Enterprises","description":"Backend of the Smishing Detection project — a mobile security solution designed to combat SMS phishing (smishing) attacks.","archived":false,"fork":false,"pushed_at":"2025-03-31T18:06:26.000Z","size":27,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-31T19:24:29.835Z","etag":null,"topics":["api","backend","expressjs","mongodb","mongoose"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Hardhat-Enterprises.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-03-28T12:24:06.000Z","updated_at":"2025-03-31T18:06:30.000Z","dependencies_parsed_at":"2025-03-31T19:24:35.001Z","dependency_job_id":"3fa46add-5e6e-40b4-a268-3648244a39e4","html_url":"https://github.com/Hardhat-Enterprises/smishing-backend","commit_stats":null,"previous_names":["hardhat-enterprises/smishing-backend"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hardhat-Enterprises%2Fsmishing-backend","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hardhat-Enterprises%2Fsmishing-backend/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hardhat-Enterprises%2Fsmishing-backend/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hardhat-Enterprises%2Fsmishing-backend/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Hardhat-Enterprises","download_url":"https://codeload.github.com/Hardhat-Enterprises/smishing-backend/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246586107,"owners_count":20801026,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["api","backend","expressjs","mongodb","mongoose"],"created_at":"2025-04-01T04:33:01.658Z","updated_at":"2026-04-09T23:03:13.258Z","avatar_url":"https://github.com/Hardhat-Enterprises.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Smishing Detection – Backend\n\nWelcome to the backend of the Smishing Detection project — a mobile security solution designed to combat SMS phishing (smishing) attacks. This repository powers the server-side logic, including user management, database interactions, middleware, and third-party service integrations.\n\n## 📂 Project Structure\n\n```\nsmishing-backend/\n├── .husky/         # Git pre-commit hooks\n|\n├── docs/           # API documentation\n|   └── research/   # Research papers\n|   └── technical/  # Architectural diagrams, API documentation etc.\n|\n├── machine-learning/   # Machine Learning \u0026 AI (TO-DO: Move to seperate repo)\n|   ├── datasets/       # CSV, parquet files (training data, test sets)\n|   ├── notebooks/      # Jupyter notebooks (Model training, evaluation)\n|   └── projects/       # Partially complete/completed student projects\n|\n├── src/\n│   ├── configs/        # MongoDB connection, environment config\n│   ├── controllers/    # Functions handling request logic for user routes\n│   ├── middlewares/    # Auth checks, logging, or other Express middleware\n│   ├── models/         # Mongoose schema/models (e.g., user, post, etc.)\n│   ├── routes/         # Express route definitions (e.g. /users, /login)\n│   ├── services/       # Business logic, 3rd-party integrations (e.g., code for sending emails, external APIs)\n│   ├── utils/          # Utility/helper functions (e.g., JWT generation, password hashing, etc.)\n│   └── index.js        # Entry point, Express app setup, registering routes/middleware\n│\n├── tests/          # Unit/integration tests (Jest/Mocha, etc.)\n│\n├── .env            # Environment variables (DB URI, secrets) - NOT committed\n├── .env.example    # Example .env\n├── .gitattributes\n├── .gitignore\n├── .prettierrc     # Prettier config file\n├── CONTRIBUTING.md\n├── package-lock.json\n├── package.json\n├── README.md\n└── Dockerfile      # (TO-DO) Docker setup for containerizing backend to host in GCP\n```\n\n## 🚀 Getting Started\n\n### Prerequisites\n\n- Node.js 22+\n- MongoDB or MongoDB Atlas\n\n### 1. Fork this Repository\n\n### 2. Clone your Fork\n\n```bash\ngit clone https://github.com/your-username/smishing-backend.git\ncd smishing-backend\n```\n\n### 2. Install Dependencies\n\n```bash\nnpm install\n```\n\n### 3. Setup Environment Variables\n\nCreate a `.env` file using the provided `.env.example` template:\n\n```bash\ncp .env.example .env\n```\n\nFill in required values:\n\n- `MONGO_URI=\u003cyour_mongodb_connection_string\u003e`\n- `PORT` (optional, default `3000`)\n- `EMAIL_USER=\u003cyour_email_address\u003e`\n- `EMAIL_PASS=\u003cyour_app_password\u003e` (generate [here](https://myaccount.google.com/apppasswords))\n- `JWT_SECRET=` (optional, default `mysecret`)\n- `OTP_EXPIRY_MINUTES=` (optional, default `10`)\n- `OTP_LENGTH=` (optional, default `6`)\n- `OTP_LIMIT=` (optional, default `5`)\n- `OTP_LOCKOUT_TIME=` (optional, default `10 * 60 * 1000`)\n\n### 4. Running the Server\n\n```bash\nnpm run dev\n```\n\nThis launches the backend with `nodemon` on `http://localhost:3000`.\n\n## 📜 Scripts\n\n| Command          | Description                   |\n| ---------------- | ----------------------------- |\n| `npm run dev`    | Start in development mode     |\n| `npm run test`   | Run tests                     |\n| `npm run format` | Run code formatter (Prettier) |\n\n## 🤝 Contribution Guidelines\n\nPlease refer to the [contributing guide](CONTRIBUTING.md) for more details\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhardhat-enterprises%2Fsmishing-backend","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhardhat-enterprises%2Fsmishing-backend","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhardhat-enterprises%2Fsmishing-backend/lists"}