Skip to content

A personal project I created to learn NestJS with Typescript, Clean/Hexagonal Architecture Principles (ports, useCases, repositories, etc) and Stateless Authentication using JWT and localStorage, as also improve my skills in product development, API development and documentation, SEO, tests, and so on.

AlexGalhardo/api.nerdapi.com

Repository files navigation

api.nerd.api-video-readme.mp4

Introduction

  • A personal project I created to learn and improve my skills in:
    • NestJS
    • Typescript
    • Clean/Hexagonal Architecture Principles (ports, useCases, repositories, etc)
    • Stateless Authentication & Authorization using JWT
    • API (REST) development and documentation
    • Tests (Unit, integration, TDD, etc)
    • Web Scrapping
    • API Requests Handling & Limit & Quota
    • SaaS (Software as a Service) Backend Development
    • And so on
  • This project use 2 databases:
    • JSONs files for simplicity and fast development.
    • PostgresSQL using PrismaORM (migrations, seeds, prisma studio) and Docker

Technologies and Tools Used

Features

  • GitHub Actions for CI/CD
  • Linter and Prettier to format code
  • Unit Tests using mocks
  • Integration Tests
  • Swagger API Documentation
  • Authentication, Authorization and Google & Github Social Login

FrontEnd & Docs

Development Setup Local

  • Clone repository
git clone git@github.com:AlexGalhardo/api.nerdapi.com.git
  • Enter repository
cd api.nerdapi.com/
  • Install dependencies
npm install
  • Setup your enviroment variables
cp .env-example .env
  • Start Docker, PrismaORM, Migrations and Seeds
sh setup.sh
  • To Start Prisma Studio:
npm run prisma:studio
  • Start local server
npm run dev

Build for deploy

  • To created build to deploy run:
npm run build
  • To test build production locally run:
npm run start

Tests

  • Run unit tests:
npm run test
  • Run integrations tests:
npm run test:integration

API

  • You can see the HTTP Requests references inside folder rest-client/

  • You can also import file docs/INSOMNIA_API_NERDAPI_HTTP_REQUESTS_COLLECTION.json to your Insomnia HTTP Client

  • You can also see Swagger API documentation in: http://localhost:4000/api

License

MIT

Copyright (c) August 2023-present, Alex Galhardo

About

A personal project I created to learn NestJS with Typescript, Clean/Hexagonal Architecture Principles (ports, useCases, repositories, etc) and Stateless Authentication using JWT and localStorage, as also improve my skills in product development, API development and documentation, SEO, tests, and so on.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages