Skip to content

API for a social network web application where users can share their thoughts, react to friends’ thoughts, and create a friend list.. Module 18 NoSQL Challenge: Social Network API

License

Notifications You must be signed in to change notification settings

CypherNyx/social-mind-reader

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

28 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Social Mind Reader 🧠

Module 18 - NoSQL Challenge: Social Network API

License: MIT

A social network API built with Node.js, Express, MongoDB and Mongoose.Users can share their thoughts, react to friends’ thoughts, and create a friend list..

MongoDB Mongoose ODM JavaScript NodeJS Express.js

Table of Contents

Demo

To see how the API works using Insomnia, see the walk-through demonstration video here: Link to video Demo ➡️

Description 📖

This API allows users to share thoughts, react to friends' thoughts, and create a friend list. It uses a non-relational MongoDB database and Mongoose ODM to model the data.

Features ✨

  • 👥 Sign up and login to your user account (username, email, and password)
  • 🤝 Add and remove friend relationships between users
  • 💭 Create, update, get, and delete thoughts
  • 👍 Create and delete reactions to thoughts
  • 🛣 Uses Mongoose models and controllers for RESTful API structure

Installation 💾

To use this API first, you'll need to have Node.js installed on your computer. Once you have Node.js set up, you can follow these steps to install and use the application:

  1. Clone this GitHub repository to your local machine.
git clone https://github.com/CypherNyx/social-mind-reader.git
  1. Open a terminal or command prompt and navigate to the cloned repository's directory.
  2. Run the install command in your terminal
npm install
  1. After installing all necessary dependencies, Start your server by running this command on your terminal:
npm start
  1. The server will start on port 3001. Routes can be tested in a Insomnia, Postman or the REST client of your choice. insomnia

Routes 🛣

The following API CRUD routes have been created to find, create, update, or delete users, friends, thoughts, and reactions in the user's database.

📁 User Routes

/api/users

  • 👥 Find all users: GET /api/users
  • 🆕 Create new user: POST /api/users
  • 🔎 Find user by Id: GET /api/users/:userId
  • ✏️ Update user by Id: PUT /api/users/:userId
  • 🗑 Delete user by Id: DELETE /api/users/:userId
  • 🤝 Add a friend: POST /api/users/:userId/friends/:friendId
  • 👋 Delete a friend: DELETE /api/users/:userId/friends/:friendId

📁 Thought Routes

/api/thoughts

  • 💬 Find all thoughts: GET /api/thoughts
  • 🆕 Create new thought: POST /api/thoughts
  • 🔎 Find thought by Id: GET /api/thoughts/:thoughtId
  • ✏️ Update thought by Id: PUT /api/thoughts/:thoughtId
  • 🗑 Delete a thought by Id: DELETE /api/thoughts/:thoughtId

📁 Reaction Routes

/api/reactions

  • 👍 Add a reaction: POST /api/thoughts/:thoughtId/reactions
  • 🗑 Delete a reaction: DELETE /api/thoughts/:thoughtId/reactions/:reactionId

Technologies 🛠️:

  • JavaScript
  • Node.js
  • Express.js
  • MongoDB
  • Mongoose ODM


Contributing

Pull requests are welcome. Please open an issue first to discuss any proposed changes or additions.

License

License: MIT

https://opensource.org/licenses/MIT
This project is open source and available under the MIT License.


Questions

GitHub CypherNyx
Email: dguido.dev@gmail.com

About

API for a social network web application where users can share their thoughts, react to friends’ thoughts, and create a friend list.. Module 18 NoSQL Challenge: Social Network API

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published