diff --git a/include/sessions.hpp b/include/sessions.hpp
index 1176cfc..e455809 100644
--- a/include/sessions.hpp
+++ b/include/sessions.hpp
@@ -43,6 +43,7 @@
     std::string sessionToken;
     std::string username;
     std::string csrfToken;
+    std::string clientId;
     std::chrono::time_point<std::chrono::steady_clock> lastUpdated;
     PersistenceType persistence;
     bool cookieAuth = false;
@@ -96,6 +97,10 @@
             {
                 userSession->username = *thisValue;
             }
+            else if (element.key() == "client_id")
+            {
+                userSession->clientId = *thisValue;
+            }
             else
             {
                 BMCWEB_LOG_ERROR
@@ -207,7 +212,7 @@
     std::shared_ptr<UserSession> generateUserSession(
         const std::string_view username,
         PersistenceType persistence = PersistenceType::TIMEOUT,
-        bool isConfigureSelfOnly = false)
+        bool isConfigureSelfOnly = false, const std::string_view clientId = "")
     {
         // TODO(ed) find a secure way to not generate session identifiers if
         // persistence is set to SINGLE_REQUEST
@@ -254,11 +259,10 @@
                 return nullptr;
             }
         }
-
-        auto session = std::make_shared<UserSession>(
-            UserSession{uniqueId, sessionToken, std::string(username),
-                        csrfToken, std::chrono::steady_clock::now(),
-                        persistence, false, isConfigureSelfOnly});
+        auto session = std::make_shared<UserSession>(UserSession{
+            uniqueId, sessionToken, std::string(username), csrfToken,
+            std::string(clientId), std::chrono::steady_clock::now(),
+            persistence, false, isConfigureSelfOnly});
         auto it = authTokens.emplace(std::make_pair(sessionToken, session));
         // Only need to write to disk if session isn't about to be destroyed.
         needWrite = persistence == PersistenceType::TIMEOUT;
@@ -423,10 +427,19 @@
         if (p->persistence !=
             crow::persistent_data::PersistenceType::SINGLE_REQUEST)
         {
+#ifdef BMCWEB_ENABLE_IBM_MANAGEMENT_CONSOLE
+            j = nlohmann::json{{"unique_id", p->uniqueId},
+                               {"session_token", p->sessionToken},
+                               {"username", p->username},
+                               {"csrf_token", p->csrfToken},
+                               { "client_id",
+                                 p->clientId }};
+#else
             j = nlohmann::json{{"unique_id", p->uniqueId},
                                {"session_token", p->sessionToken},
                                {"username", p->username},
                                {"csrf_token", p->csrfToken}};
+#endif
         }
     }
 };
