{"id":32774007,"url":"https://github.com/crabstechnologies/notes-api","last_synced_at":"2026-05-04T09:34:10.185Z","repository":{"id":319871345,"uuid":"1079910744","full_name":"crabstechnologies/notes-api","owner":"crabstechnologies","description":"🧠 Simple Notes API built with NestJS, TypeORM, SQLite, and Swagger — a clean CRUD backend for learning and portfolio projects.","archived":false,"fork":false,"pushed_at":"2025-10-23T16:03:38.000Z","size":142,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-11-04T10:11:35.778Z","etag":null,"topics":["api","backend","crud","learning-project","nestjs","nodejs","sqlite","swagger","typeorm","typescript"],"latest_commit_sha":null,"homepage":"http://localhost:3000/docs","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/crabstechnologies.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-10-20T15:16:42.000Z","updated_at":"2025-10-23T16:03:42.000Z","dependencies_parsed_at":"2025-10-20T17:39:03.173Z","dependency_job_id":null,"html_url":"https://github.com/crabstechnologies/notes-api","commit_stats":null,"previous_names":["crabstechnologies/notes-api"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/crabstechnologies/notes-api","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crabstechnologies%2Fnotes-api","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crabstechnologies%2Fnotes-api/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crabstechnologies%2Fnotes-api/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crabstechnologies%2Fnotes-api/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/crabstechnologies","download_url":"https://codeload.github.com/crabstechnologies/notes-api/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/crabstechnologies%2Fnotes-api/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32601596,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-03T22:12:39.696Z","status":"online","status_checked_at":"2026-05-04T02:00:06.625Z","response_time":58,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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","crud","learning-project","nestjs","nodejs","sqlite","swagger","typeorm","typescript"],"created_at":"2025-11-04T10:01:20.065Z","updated_at":"2026-05-04T09:34:10.179Z","avatar_url":"https://github.com/crabstechnologies.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"![NestJS](https://img.shields.io/badge/NestJS-E0234E?style=for-the-badge\u0026logo=nestjs\u0026logoColor=white)\n![TypeScript](https://img.shields.io/badge/TypeScript-3178C6?style=for-the-badge\u0026logo=typescript\u0026logoColor=white)\n![TypeORM](https://img.shields.io/badge/TypeORM-FF6C37?style=for-the-badge\u0026logo=typeorm\u0026logoColor=white)\n![Swagger](https://img.shields.io/badge/Swagger-85EA2D?style=for-the-badge\u0026logo=swagger\u0026logoColor=black)\n![SQLite](https://img.shields.io/badge/SQLite-07405E?style=for-the-badge\u0026logo=sqlite\u0026logoColor=white)\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE)\n\n# 🧠 Notes API — NestJS + TypeORM + SQLite\n\nA clean, production-ready **REST API** built with **NestJS**, demonstrating how to design a modular, well-documented backend service using **TypeORM**, **SQLite**, and **Swagger**.  \nThis project is beginner-friendly but follows industry best practices — perfect for learning or showcasing your backend skills.\n\n---\n\n## 🚀 Features\n\n✅ **CRUD Operations**     — Create, Read, Update, Delete notes  \n✅ **Validation**          — Strong input validation using `class-validator`  \n✅ **Auto Docs**           — Built-in Swagger UI (`/docs`)  \n✅ **TypeORM Integration** — SQLite for simplicity (zero setup)  \n✅ **Seed Script**         — Preloads demo data for quick testing  \n✅ **Unit Tests**          — Example service test with Jest  \n✅ **Clean Architecture**  — Organized modules, DTOs, and entities\n\n---\n\n## 🧰 Tech Stack\n\n| Layer             | Technology                           |\n|-------------------|--------------------------------------|\n| Framework         | [NestJS](https://nestjs.com/)        |\n| ORM               | [TypeORM](https://typeorm.io/)       |\n| Database          | SQLite                               |\n| Validation        | class-validator / class-transformer  |\n| Documentation     | Swagger (OpenAPI)                    |\n| Testing           | Jest                                 |\n| Package Manager   | Yarn                                 |\n\n---\n\n## 📦 Installation\n\nClone and install dependencies:\n\n```bash\ngit clone https://github.com/\u003cyour-username\u003e/notes-api.git\ncd notes-api\nyarn install\n```\n---\n\n## ⚙️ Running the App\n\n# Development mode (auto-reloads)\n```bash\nyarn start:dev\n```\n# Production build\n```bash\nyarn build\nyarn start:prod\n```\n### Database schema sync (TypeORM)\n\nTypeORM's automatic schema sync is controlled via the `TYPEORM_SYNC` environment\nvariable:\n\n```bash\n# .env (local development)\nTYPEORM_SYNC=true\n```\nFor production deployments the flag **must** be set to `false` to protect data\nmigrations. The provided `yarn start:prod` script already enforces this by\nrunning `TYPEORM_SYNC=false node dist/main`. If you use a different process\nmanager, make sure to export the variable yourself (for Windows PowerShell use\n`$env:TYPEORM_SYNC = 'false'`).\n\n---\n\n## 🌱 Seeding Sample Data\n\nYou can prefill the database with example notes:\n\n```bash\nyarn seed\n```\nThis will insert two demo notes:\n“Welcome” — first seeded note ✨\n“Second” — edit or delete it in Thunder Client!\n\n---\n\n## 🔍 API Endpoints Overview\n\n| Method  | Endpoint    | Description         |\n|---------|-------------|---------------------|\n| POST    | /notes      | Create a new note   |\n| GET     | /notes      | Get all notes       |\n| GET     | /notes/:id  | Get a specific note |\n| PATCH   | /notes/:id  | Update a note       |\n| DELETE  | /notes/:id  | Delete a note       |\n\n---\n\n## 🧪 Testing\n\n```bash\nyarn test\n```\nYou’ll find example tests under src/notes/notes.service.spec.ts.\n\n---\n\n## 🧩 Project Structure\n```bash\nsrc\n├── app.module.ts             # Root module\n├── main.ts                   # Entry point + Swagger setup\n└── notes\n    ├── dto                   # Data transfer objects (validation)\n    ├── entities              # TypeORM entities\n    ├── notes.controller.ts\n    ├── notes.module.ts\n    └── notes.service.ts\n```\n---\n\n## 🧠 Learning Objectives\n\nThis project demonstrates:\n\u003cul\u003e\n    \u003cli\u003eClean modular design in NestJS\u003c/li\u003e\n    \u003cli\u003eDTO + validation + transformation flow\u003c/li\u003e\n    \u003cli\u003eDatabase persistence with TypeORM\u003c/li\u003e\n    \u003cli\u003eSwagger documentation automation\u003c/li\u003e\n    \u003cli\u003eDependency injection and testing with Jest\u003c/li\u003e\n\u003c/ul\u003e\n\n---\n\n## ⭐ If you like this project, consider giving it a star on GitHub, it helps others discover learning-friendly NestJS examples!\n\n---\n\n## 📄 License\n\nThis project is licensed under the [MIT License](LICENSE).","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcrabstechnologies%2Fnotes-api","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcrabstechnologies%2Fnotes-api","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcrabstechnologies%2Fnotes-api/lists"}