Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ketankauntia/natours-backend
Built a restfull api with CRUD operations using mongoDb and mongoose. Server side rendering via Pug template, encryption via bycrpt, demo payments via Stripe and authentication.
https://github.com/ketankauntia/natours-backend
bycrypt express jwt mapbox-gl mongodb-atlas mongoose node-js pugjs stripe-api
Last synced: 12 days ago
JSON representation
Built a restfull api with CRUD operations using mongoDb and mongoose. Server side rendering via Pug template, encryption via bycrpt, demo payments via Stripe and authentication.
- Host: GitHub
- URL: https://github.com/ketankauntia/natours-backend
- Owner: ketankauntia
- Created: 2022-06-08T10:01:06.000Z (over 2 years ago)
- Default Branch: master
- Last Pushed: 2022-06-08T10:36:40.000Z (over 2 years ago)
- Last Synced: 2024-10-18T01:48:02.080Z (about 1 month ago)
- Topics: bycrypt, express, jwt, mapbox-gl, mongodb-atlas, mongoose, node-js, pugjs, stripe-api
- Language: JavaScript
- Homepage:
- Size: 79.6 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Natours-Backend
Built a restfull api with CRUD operations using mongoDb and mongoose. Server side rendering with Pug template and authentication added to data stored via encrypting it and checkout the tours with stripe payments.- To run, connect to the database cluster
- Install all node modules using : npm i
- Now start the project using : npm start![image](https://user-images.githubusercontent.com/44080191/172593334-9f714660-2b35-4754-90cb-4287672d616b.png)
-login credentials :
[email protected]
test1234login screen :
![Screenshot (105)](https://user-images.githubusercontent.com/44080191/172594221-790bce01-63b2-41f7-ba6b-27cb2875af80.png)To book a tour, select a tour, and go to the bottom of the tour and click on "BOOK TOUR NOW".
It will be processed and you will be taken to stripe checkout,dev card number : 4242 4242 4242 4242 [only this will work on development server]
![image](https://user-images.githubusercontent.com/44080191/172595307-d1e59303-9693-4ebe-a458-e906703f5218.png)
after sucessfull booking, Go to account and check under bookings, the booking will be shown there :)
## add config.env file to the project to run.
contains :- NODE_ENV = development
- PORT=3000
- DATABASE_PASSWORD =
- DATABASE=- JWT_SECRET=
- JWT_EXPIRES_IN=90d
- JWT_COOKIE_EXPIRES_IN=90- EMAIL_USERNAME=
- EMAIL_PASSWORD=
- EMAIL_HOST=
- EMAIL_PORT=- EMAIL_FROM=
- SENDGRID_USERNAME=
- SENDGRID_PASSWORD=- STRIPE_SECRECT_KEY=
--- x ----
-sendgrid wont work, don't try connecting, use another mailing provider for verification mails.