All Projects → victoria-lo → TAPI

victoria-lo / TAPI

Licence: other
Full Node.js demo REST API for tea built for the Node.js MongoDB Beginner Series at lo-victoria.com/series/lets-build-a-nodejs-rest-api

Programming Languages

javascript
184084 projects - #8 most used programming language
HTML
75241 projects
CSS
56736 projects
Procfile
174 projects

Table of contents 👀

General info

TAPI or T-API is a Tea REST API made to show some love for the beverage.

The TEA Object 🍵

Properties Description Type
name the tea name String
image an image url String
description the description String
keywords words associated with the tea String
origin country where the tea is first made String
brew_time time to brew in minutes Number
temperature best temperature in Celsius to drink Number
comments any comments posted about the tea Array of String

Routes

Routes HTTP Methods Description
/tea GET Displays all tea
/tea POST Creates a new tea
/tea DELETE Deletes all tea
/tea/:name GET Displays a specific tea, given its name
/tea/:name POST Adds a comment to a specific tea, given its name
/tea/:name DELETE Deletes a specific tea, given its name

Technologies

Project is created with:

  • Node version: 12.14.1
  • Express version: 4.17.1
  • Mongoose version: 5.9.25
  • Multer version: 1.4.2
  • MongoDB Atlas

👉 Deployed at: https://tea-api-vic-lo.herokuapp.com/

Note: heroku can load the page quite slow sp please wait a while. Once it loads, it should run smoothly. Please let me know if you find any bugs or errors at [email protected]

How I built it

👉 Check out the series here!

Setup

To run this project locally, clone repo and add an .env file in the root:

MONGODB_URI='mongodb+srv://username:[email protected]/database_name'

Then execute in command prompt:

$ cd tapi
$ npm install
$ npm start or node server.js

Next Steps

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].