Project created with NestJS framework, MongoDB with Mongoose and Docker compose. Also used external dog API to get random dog images and breeds.
- Create .env file in the root directory and add the following variables:
APP_PORT=3000
MONGODB_URL=mongodb://mongodb:27017/Dogs
- Run the following command in the root directory:
docker-compose up --build
Check the swagger documentation to see all the endpoints and their functionalities:
http://localhost:3000/api
- Use GET /quiz endpoint to get a random dog image and 3 breeds to choose from
- Use POST /quiz endpoint to check if the answer is correct
Quiz objects are stored in the database and can be accessed with GET /quiz/:id endpoint