diff --git a/include/ibm/locks.hpp b/include/ibm/locks.hpp
index 7b00708..66eb926 100644
--- a/include/ibm/locks.hpp
+++ b/include/ibm/locks.hpp
@@ -42,7 +42,7 @@
     boost::container::flat_map<uint32_t, LockRequests> lockTable;
 
     /*
-     * This function implements the logic for validating an incomming
+     * This function implements the logic for validating an incoming
      * lock request/requests.
      *
      * Returns : True (if Valid)
@@ -52,7 +52,7 @@
     bool isValidLockRequest(const LockRequest);
 
     /*
-     * This function implements the logic of checking if the incomming
+     * This function implements the logic of checking if the incoming
      * multi-lock request is not having conflicting requirements.
      *
      * Returns : True (if conflicting)
@@ -74,7 +74,7 @@
 
     /*
      * This function implements the logic of checking the conflicting
-     * locks from a incomming single/multi lock requests with the already
+     * locks from a incoming single/multi lock requests with the already
      * existing lock request in the lock table.
      *
      */
@@ -135,7 +135,7 @@
   public:
     /*
      * This function implements the logic for acquiring a lock on a
-     * resource if the incomming request is legitimate without any
+     * resource if the incoming request is legitimate without any
      * conflicting requirements & without any conflicting requirement
      * with the exsiting locks in the lock table.
      *
diff --git a/include/ibm/management_console_rest.hpp b/include/ibm/management_console_rest.hpp
index 87beb04..9f8f8d2 100644
--- a/include/ibm/management_console_rest.hpp
+++ b/include/ibm/management_console_rest.hpp
@@ -5,6 +5,7 @@
 #include <async_resp.hpp>
 #include <boost/algorithm/string.hpp>
 #include <boost/container/flat_set.hpp>
+#include <error_messages.hpp>
 #include <filesystem>
 #include <fstream>
 #include <ibm/locks.hpp>
@@ -406,6 +407,13 @@
         }
     }
 }
+void handleRelaseAllAPI(const crow::Request &req, crow::Response &res)
+{
+    crow::ibm_mc_lock::Lock::getInstance().releaseLock(req.session->uniqueId);
+    res.result(boost::beast::http::status::ok);
+    res.end();
+    return;
+}
 
 void handleReleaseLockAPI(const crow::Request &req, crow::Response &res,
                           const std::vector<uint32_t> &listTransactionIds)
@@ -581,19 +589,34 @@
             });
     BMCWEB_ROUTE(app, "/ibm/v1/HMC/LockService/Actions/LockService.ReleaseLock")
         .requires({"ConfigureComponents", "ConfigureManager"})
-        .methods("POST"_method)(
-            [](const crow::Request &req, crow::Response &res) {
-                std::vector<uint32_t> listTransactionIds;
+        .methods(
+            "POST"_method)([](const crow::Request &req, crow::Response &res) {
+            std::string type;
+            std::vector<uint32_t> listTransactionIds;
 
-                if (!redfish::json_util::readJson(req, res, "TransactionIDs",
-                                                  listTransactionIds))
-                {
-                    res.result(boost::beast::http::status::bad_request);
-                    res.end();
-                    return;
-                }
+            if (!redfish::json_util::readJson(req, res, "Type", type,
+                                              "TransactionIDs",
+                                              listTransactionIds))
+            {
+                res.result(boost::beast::http::status::bad_request);
+                res.end();
+                return;
+            }
+            if (type == "Transaction")
+            {
                 handleReleaseLockAPI(req, res, listTransactionIds);
-            });
+            }
+            else if (type == "Session")
+            {
+                handleRelaseAllAPI(req, res);
+            }
+            else
+            {
+                BMCWEB_LOG_DEBUG << " Value of Type : " << type
+                                 << "is Not a Valid key";
+                redfish::messages::propertyValueNotInList(res, type, "Type");
+            }
+        });
     BMCWEB_ROUTE(app, "/ibm/v1/HMC/LockService/Actions/LockService.GetLockList")
         .requires({"ConfigureComponents", "ConfigureManager"})
         .methods("POST"_method)(
