Skip to content

Simple app to save and show reviews (food, hotel, everything you want)

Notifications You must be signed in to change notification settings

eckon/simple-review-api

Repository files navigation

Simple Review API

check-compile workflow check-lint workflow check-format workflow run-test workflow

API Documentation

A swagger documentation can be found under /docs

The live endpoint can be found under https://simple-review-api.herokuapp.com/docs/

Usage

  • create a Collection and link all the reviews to the created Collection
  • no authentication is needed, "safety" is given by collections being hidden

Installation

$ npm install

Production

# production mode
$ npm run start:prod

Development

# watch mode
$ npm run start:dev

# database
$ docker-compose up

Test

# unit tests
$ npm run test

# e2e tests
$ npm run test:e2e

# test coverage
$ npm run test:cov

Dev

Heroku

The backend is being hosted by heroku. It uses ci/cd to generate and deploy it. Also the database is hosted on heroku. Some parts of the repository are only for the heroku implementation.

These are mainly for the start of the application and how to connect to the heroku database.

  • Procfile
    • tells heroku the entry point of the application

Structure

  • Collection have multiple Reviews that describe a common thing (food review, hotel review, etc.)
    • these will allow a connection between multiple Reviews, meaning that two Reviewers are always different entities, when they are not in the same collection (even if they are the same in reality)
  • Review is one rating for a specific thing, it will be connected to other Reviews via a Collection
  • additional meta data like completions etc. are linked by the Collection
    • meaning if we want to get all possible already created Reviewers for a new Review then this can only be achieved by requesting the data from the Collection which internally requests different data from the Reviews

About

Simple app to save and show reviews (food, hotel, everything you want)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published