-
Notifications
You must be signed in to change notification settings - Fork 0
/
app.js
34 lines (28 loc) · 854 Bytes
/
app.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
const connectToMongo = require("./db.js");
require("dotenv").config();
const express = require("express");
var cors = require("cors");
const app = express();
const port = 4000;
connectToMongo();
app.use(cors());
app.use(express.json());
express.urlencoded({ extended: false });
//Available Routes
app.use("/start-backend/api", require("./routes/auth"));
app.use("/start-backend/otp", require("./routes/otp"));
app.use("/start-backend/paytm", require("./routes/paytm"));
app.use("/start-backend/easebuzz", require("./routes/easebuzz"));
app.use("/start-backend/thinkexam", require("./routes/thinkExam"));
app.get("/start-backend", (req, res) => {
res.send({
status: 200,
data: {
message: "Vohooo! Working!",
},
});
});
app.listen();
// app.listen(port, () => {
// console.log(`Example app listening on port ${port}`);
// });