Giter Club home page Giter Club logo

blog_api's Introduction

Blog_API

Tech

This API was developed on NodeJS. Using Postman as platform to test and iterate with the BlogAppAPI that storages the users info and blogs in a MongoDB database in the cloud.

Server: Node, Express

Database: MongoDB

Tools: Postman

Environmental Variables

To run this project you will need to add the following variables to your .env file:

MONGODB_URI PORT= SECRET_KEY

Instructions on Installing

npm install express --save

npm install morgan --save

npm install helmet --save

npm install mongoose --save

npm install express-validator --save

npm install jsonwebtoken --save

npm install dotenv --save

npm install bcrypt --save

MiddleWare

Morgan - benefits: It provides flexibility in defining the format of log messages It allows you to overwrite the output destination for your logs

     - Reason for it: To pick up the request object and log whatever you need, like information such as the method used,
     the origin IP, the requested URL etc.

Helmet.js - fills in the gap between Node.js and Express.js by securing HTTP headers that are returned by your Express apps

JWT - defines a compact and self-contained way for securely transmitting information between parties Screen Shot 2022-06-21 at 10 07 57 AM

Schemas used

-User Schema - username: string, required - email: string, required - birthday: date, required - age: number - password: string, required

-Blog Schema - created_by: string, required - created_at: date, required - blog_title: string, required - blog_content: string, required - private: boolean, required

blog_api's People

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.