This application will encapsulate rudimentary features and workflow repeated for most mern applications. This will be a fully functioning app with User Create, Update and Delete with authentication-authorization capabilities.
1. Signup: User can register by creating a new account using an email address.
2. User List: Any visitor can see the list of all registered users.
3. Authentication: Registered users can sign in and sign out.
4. Protected User Profile: only registered users can view individual user details after signing in.
5. Authorized user Edit and Delete: Only a registered and authenticated user can edit or remove their own user account details.
Operation | API route | HTTP method |
---|---|---|
create a user | /api/users | POST |
List all users | /api/users | GET |
Fetch a user | /api/users/:userId | GET |
Update a user | /api/users/:userId | PUT |
Delete a user | /api/users/:userId | DELETE |
User sign-in | /auth/signin | POST |
User sign-out | /auth/signout | GET |
- Node
- NPM
- MongoDB
- Make sure MongoDB is running on your system
- Clone this repository
- Open command line in the cloned folder,
- To install dependencies, run npm install
- To run the application for development, run npm run development
- Open localhost:3000 in the browser