Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jagoda11/pirple-nodejs-fullstack-pizza-app
π NodeJS-Pirple-Pizza-System: Backend & CLI for pizza delivery with user auth, menu management, and order processing. π
https://github.com/jagoda11/pirple-nodejs-fullstack-pizza-app
api authentication backend backend-development cli ecommerce full-stack javascript jwt mailgun menu-management nodejs pirple pizza-delivery routing stripe-integration user-authentication
Last synced: 6 days ago
JSON representation
π NodeJS-Pirple-Pizza-System: Backend & CLI for pizza delivery with user auth, menu management, and order processing. π
- Host: GitHub
- URL: https://github.com/jagoda11/pirple-nodejs-fullstack-pizza-app
- Owner: Jagoda11
- Created: 2021-02-11T17:39:21.000Z (almost 4 years ago)
- Default Branch: master
- Last Pushed: 2024-11-08T02:24:37.000Z (6 days ago)
- Last Synced: 2024-11-08T03:26:57.459Z (6 days ago)
- Topics: api, authentication, backend, backend-development, cli, ecommerce, full-stack, javascript, jwt, mailgun, menu-management, nodejs, pirple, pizza-delivery, routing, stripe-integration, user-authentication
- Language: JavaScript
- Homepage:
- Size: 749 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Pirple NodeJS FullStack Pizza Appπ
![GitHub Issues](https://img.shields.io/github/issues/Jagoda11/Pirple-NodeJS-FullStack-Pizza-App?color=pink)
![GitHub Last Commit](https://img.shields.io/github/last-commit/Jagoda11/Pirple-NodeJS-FullStack-Pizza-App?color=green)
![Build Status](https://github.com/Jagoda11/Pirple-NodeJS-FullStack-Pizza-App/actions/workflows/update-and-scan.yml/badge.svg?branch=master)## Homework Assignment #4
- Build a CLI interface that would allow the manager of the pizza place to:
To start the CLI: `nodemon cli/index.js` π
1. View all the current menu items β
Run: `list menu`2. View all the recent orders in the system (orders placed in the last 24 hours) β
Run: `list orders`3. Lookup the details of a specific order by order ID β
Run: `get order `
// You can use `get order 0`4. View all the users who have signed up in the last 24 hours β
Run: `list users`5. Lookup the details of a specific user by email address β
Run: `get user `
You can use: `get user [email protected]` // temporary email## Homework Assignment #3
- In order to test run `node index.js` and browse to π
Details (Scenario):
It is time to build a simple frontend for the Pizza-Delivery API you created in Homework Assignment #2. Please create a web app that allows customers to:
1. Signup on the site β
2. View all the items available to order β
3. Fill up a shopping cart β
4. Place an order (with fake credit card credentials), and receive an email receipt β
## Homework Assignment #2
## User login π§βπΌ
### POST /users/login
`body: {email: String, password: String}`
### User logout π
#### POST /users/logout
`header: authorization`
### Add user π
#### POST /users
`body: {email: String, name: String, password: String, street_address: String}`
### Update user π§
#### PUT /users/:id
`param: id`
`body: {email: String, name: String, password: String, street_address: String}`
### Delete user β
#### DELETE /users/:id
`param: id`
### Get menu items π
#### GET /menu
`header: authorization`
### Add item to the shopping cart π
#### POST /shopping-cart/add
`header: authorization`
`body: {itemId: String}`### Checkout an order π³
#### POST /order/checkout
`header: authorization`
`body: {cardNumber: String}`Details (Scenario):
You are building the API for a pizza-delivery company. Here's the spec from your project manager:
1. New users can be created, their information can be edited, and they can be deleted. We should store their name, email address, and street address. β (remaining: store users on desk instead of memory)
2. Users can log in and log out by creating or destroying a token. β
3. When a user is logged in, they should be able to GET all the possible menu items (these items can be hardcoded into the system). β
4. A logged-in user should be able to fill a shopping cart with menu items. β
5. **Create an Order with Stripe Integration** ππ
A logged-in user should be able to create an order. Integrate with the Stripe.com Sandbox to process payments. Utilize Stripe's sandbox for testing purposes. Explore the [Stripe testing documentation](https://stripe.com/docs/testing#cards) and the [charges API](https://stripe.com/docs/api/charges/) to understand how to use fake tokens for server-side testing.6. **Email Receipt with Mailgun Integration** ππ
Once an order is placed, email the user a receipt. This should be done by integrating with the Mailgun.com sandbox. Each Mailgun account has a sandbox domain (like `[email protected]`) that allows sending emails without DNS setup. For more details, visit the [Mailgun FAQ](https://documentation.mailgun.com/en/latest/faqs.html#how-do-i-pick-a-domain-name-for-my-mailgun-account).Important Note: If you use external libraries (NPM) to integrate with Stripe or Mailgun, you will not pass this assignment. You must write your API calls from scratch.
This is an open-ended assignment. You may take any direction you'd like to go with it, as long as your project includes the requirements. It can include anything else you wish as well.
And please: Don't forget to document how a client should interact with the API you create!
## Continuous Integration π΄
This project now includes a **GitHub Actions** workflow that automatically updates npm dependencies and performs a vulnerability scanπ§. The workflow runs daily at 2 AM UTC and whenever changes are pushed to the `master` branch. It ensures that the project stays up-to-date.
The workflow performs the following tasks:
- Updates all β¬οΈ npm dependencies.
- Runs a vulnerability scan using the Debricked CLI.π¨
- Automatically commits and pushes πchanges to the repository if dependencies are updated.