summary refs log tree commit diff
path: root/src/api/start.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/api/start.js')
-rw-r--r--src/api/start.js12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/api/start.js b/src/api/start.js
new file mode 100644

index 0000000..9d9c586 --- /dev/null +++ b/src/api/start.js
@@ -0,0 +1,12 @@ +import express from "express"; + +const app = express(); +const PORT = process.env.PORT || 3000; + +app.get("/", (req, res) => { + res.send("Welcome to the API!"); +}); + +app.listen(PORT, () => { + console.log(`Server is running on http://localhost:${PORT}`); +});