From 216a6392a16899b90da1bb6a53791b31ecbfa699 Mon Sep 17 00:00:00 2001
From: "harshith.karkera" <harshith.karkera@niveussolutions.com>
Date: Tue, 4 Mar 2025 10:23:27 +0530
Subject: [PATCH] API End points file Added

---
 API-Endpoints.txt | 90 +++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 90 insertions(+)
 create mode 100644 API-Endpoints.txt

diff --git a/API-Endpoints.txt b/API-Endpoints.txt
new file mode 100644
index 0000000..1548b57
--- /dev/null
+++ b/API-Endpoints.txt
@@ -0,0 +1,90 @@
+API Endpoints 
+
+Run the Project : node server.js
+Run the Testing : npm test
+
+Base URL: http://localhost:3000
+
+User APIs
+
+Create a User
+
+URL: http://localhost:3000/users
+
+Endpoint: POST /users
+
+Description: Creates a new user.
+
+Request Body (JSON):
+
+{
+  "name": "Vijay Sharma",
+  "email": "vijay@example.com",
+  "age": 25
+}
+
+Response (JSON):
+
+{
+  "_id": "1234567890",
+  "name": "Vijay Sharma",
+  "email": "vijay@example.com",
+  "age": 25
+}
+
+---------------------------------------------------
+
+Get All Users
+
+URL: http://localhost:3000/users
+
+Endpoint: GET /users
+
+Description: Retrieves the list of all users.
+
+Response (JSON):
+
+[
+  {
+    "_id": "1234567890",
+    "name": "Vijay Sharma",
+    "email": "vijay@example.com",
+    "age": 25
+  },
+  {
+    "_id": "0987654321",
+    "name": "Sumith",
+    "email": "sumith@example.com",
+    "age": 30
+  }
+]
+
+-----------------------------------------------
+
+Update a User
+
+URL: http://localhost:3000/users/{id}
+
+Endpoint: PUT /users/:id
+
+Description: Updates user details by ID.
+
+Request Body (JSON):
+
+{
+  "name": "Kumar",
+  "age": 30
+}
+
+Response (JSON):
+
+{
+  "_id": "1234567890",
+  "name": "Kumar",
+  "email": "sumith@example.com",
+  "age": 30
+}
+
+
+---------------------------------------
+
-- 
GitLab