diff --git a/include/nbd_proxy.hpp b/include/nbd_proxy.hpp
index e4d709b..62bd324 100644
--- a/include/nbd_proxy.hpp
+++ b/include/nbd_proxy.hpp
@@ -327,15 +327,13 @@
 {
     BMCWEB_LOG_DEBUG << "nbd-proxy.onopen(" << &conn << ")";
 
-    auto openHandler =
+    sdbusplus::message::object_path path("/xyz/openbmc_project/VirtualMedia");
+    dbus::utility::getManagedObjects(
+        "xyz.openbmc_project.VirtualMedia", path,
         [&conn](const boost::system::error_code& ec,
                 const dbus::utility::ManagedObjectType& objects) {
         afterGetManagedObjects(conn, ec, objects);
-    };
-    crow::connections::systemBus->async_method_call(
-        std::move(openHandler), "xyz.openbmc_project.VirtualMedia",
-        "/xyz/openbmc_project/VirtualMedia",
-        "org.freedesktop.DBus.ObjectManager", "GetManagedObjects");
+        });
 
     // We need to wait for dbus and the websockets to hook up before data is
     // sent/received.  Tell the core to hold off messages until the sockets are
diff --git a/include/openbmc_dbus_rest.hpp b/include/openbmc_dbus_rest.hpp
index 0fbef04..4dbf12e 100644
--- a/include/openbmc_dbus_rest.hpp
+++ b/include/openbmc_dbus_rest.hpp
@@ -302,7 +302,9 @@
     BMCWEB_LOG_DEBUG << "getManagedObjectsForEnumerate " << objectName
                      << " object_manager_path " << objectManagerPath
                      << " connection_name " << connectionName;
-    crow::connections::systemBus->async_method_call(
+    sdbusplus::message::object_path path(objectManagerPath);
+    dbus::utility::getManagedObjects(
+        connectionName, path,
         [transaction, objectName,
          connectionName](const boost::system::error_code& ec,
                          const dbus::utility::ManagedObjectType& objects) {
@@ -360,9 +362,7 @@
                 }
             }
         }
-        },
-        connectionName, objectManagerPath, "org.freedesktop.DBus.ObjectManager",
-        "GetManagedObjects");
+        });
 }
 
 inline void findObjectManagerPathForEnumerate(
diff --git a/redfish-core/include/redfish_aggregator.hpp b/redfish-core/include/redfish_aggregator.hpp
index 3b48bda..a6920e8 100644
--- a/redfish-core/include/redfish_aggregator.hpp
+++ b/redfish-core/include/redfish_aggregator.hpp
@@ -756,7 +756,9 @@
             handler)
     {
         BMCWEB_LOG_DEBUG << "Gathering satellite configs";
-        crow::connections::systemBus->async_method_call(
+        sdbusplus::message::object_path path("/xyz/openbmc_project/inventory");
+        dbus::utility::getManagedObjects(
+            "xyz.openbmc_project.EntityManager", path,
             [handler{std::move(handler)}](
                 const boost::system::error_code& ec,
                 const dbus::utility::ManagedObjectType& objects) {
@@ -786,10 +788,7 @@
                     << "No satellite BMCs detected.  Redfish Aggregation not enabled";
             }
             handler(ec, satelliteInfo);
-            },
-            "xyz.openbmc_project.EntityManager",
-            "/xyz/openbmc_project/inventory",
-            "org.freedesktop.DBus.ObjectManager", "GetManagedObjects");
+            });
     }
 
     // Processes the response returned by a satellite BMC and loads its
diff --git a/redfish-core/lib/account_service.hpp b/redfish-core/lib/account_service.hpp
index 6f5f122..91f7804 100644
--- a/redfish-core/lib/account_service.hpp
+++ b/redfish-core/lib/account_service.hpp
@@ -53,7 +53,6 @@
 constexpr const char* ldapEnableInterface = "xyz.openbmc_project.Object.Enable";
 constexpr const char* ldapPrivMapperInterface =
     "xyz.openbmc_project.User.PrivilegeMapper";
-constexpr const char* dbusObjManagerIntf = "org.freedesktop.DBus.ObjectManager";
 constexpr const char* propertyInterface = "org.freedesktop.DBus.Properties";
 
 struct LDAPRoleMapData
@@ -580,7 +579,9 @@
             return;
         }
         std::string service = resp.begin()->first;
-        crow::connections::systemBus->async_method_call(
+        sdbusplus::message::object_path path(ldapRootObject);
+        dbus::utility::getManagedObjects(
+            service, path,
             [callback,
              ldapType](const boost::system::error_code& errorCode,
                        const dbus::utility::ManagedObjectType& ldapObjects) {
@@ -717,8 +718,7 @@
                 }
             }
             callback(true, confData, ldapType);
-            },
-            service, ldapRootObject, dbusObjManagerIntf, "GetManagedObjects");
+            });
         });
 }
 
@@ -1732,7 +1732,9 @@
     {
         thisUser = req.session->username;
     }
-    crow::connections::systemBus->async_method_call(
+    sdbusplus::message::object_path path("/xyz/openbmc_project/user");
+    dbus::utility::getManagedObjects(
+        "xyz.openbmc_project.User.Manager", path,
         [asyncResp, thisUser, effectiveUserPrivileges](
             const boost::system::error_code& ec,
             const dbus::utility::ManagedObjectType& users) {
@@ -1776,9 +1778,7 @@
             }
         }
         asyncResp->res.jsonValue["Members@odata.count"] = memberArray.size();
-        },
-        "xyz.openbmc_project.User.Manager", "/xyz/openbmc_project/user",
-        "org.freedesktop.DBus.ObjectManager", "GetManagedObjects");
+        });
 }
 
 inline void processAfterCreateUser(
@@ -2016,7 +2016,9 @@
         }
     }
 
-    crow::connections::systemBus->async_method_call(
+    sdbusplus::message::object_path path("/xyz/openbmc_project/user");
+    dbus::utility::getManagedObjects(
+        "xyz.openbmc_project.User.Manager", path,
         [asyncResp,
          accountName](const boost::system::error_code& ec,
                       const dbus::utility::ManagedObjectType& users) {
@@ -2148,9 +2150,7 @@
             "/redfish/v1/AccountService/Accounts/" + accountName;
         asyncResp->res.jsonValue["Id"] = accountName;
         asyncResp->res.jsonValue["UserName"] = accountName;
-        },
-        "xyz.openbmc_project.User.Manager", "/xyz/openbmc_project/user",
-        "org.freedesktop.DBus.ObjectManager", "GetManagedObjects");
+        });
 }
 
 inline void
diff --git a/redfish-core/lib/health.hpp b/redfish-core/lib/health.hpp
index ef858a1..c5249f2 100644
--- a/redfish-core/lib/health.hpp
+++ b/redfish-core/lib/health.hpp
@@ -212,7 +212,9 @@
     void getAllStatusAssociations()
     {
         std::shared_ptr<HealthPopulate> self = shared_from_this();
-        crow::connections::systemBus->async_method_call(
+        sdbusplus::message::object_path path("/");
+        dbus::utility::getManagedObjects(
+            "xyz.openbmc_project.ObjectMapper", path,
             [self](const boost::system::error_code& ec,
                    const dbus::utility::ManagedObjectType& resp) {
             if (ec)
@@ -230,9 +232,7 @@
                 }
                 it = self->statuses.erase(it);
             }
-            },
-            "xyz.openbmc_project.ObjectMapper", "/",
-            "org.freedesktop.DBus.ObjectManager", "GetManagedObjects");
+            });
     }
 
     std::shared_ptr<bmcweb::AsyncResp> asyncResp;
diff --git a/redfish-core/lib/hypervisor_system.hpp b/redfish-core/lib/hypervisor_system.hpp
index 52aeb43..c16c171 100644
--- a/redfish-core/lib/hypervisor_system.hpp
+++ b/redfish-core/lib/hypervisor_system.hpp
@@ -311,7 +311,9 @@
 void getHypervisorIfaceData(const std::string& ethIfaceId,
                             CallbackFunc&& callback)
 {
-    crow::connections::systemBus->async_method_call(
+    sdbusplus::message::object_path path("/");
+    dbus::utility::getManagedObjects(
+        "xyz.openbmc_project.Settings", path,
         [ethIfaceId{std::string{ethIfaceId}},
          callback{std::forward<CallbackFunc>(callback)}](
             const boost::system::error_code& error,
@@ -331,9 +333,7 @@
             BMCWEB_LOG_INFO << "Hypervisor Interface not found";
         }
         callback(found, ethData, ipv4Data);
-        },
-        "xyz.openbmc_project.Settings", "/",
-        "org.freedesktop.DBus.ObjectManager", "GetManagedObjects");
+        });
 }
 
 /**
diff --git a/redfish-core/lib/log_services.hpp b/redfish-core/lib/log_services.hpp
index 9ff3cdf..323c22a 100644
--- a/redfish-core/lib/log_services.hpp
+++ b/redfish-core/lib/log_services.hpp
@@ -467,10 +467,12 @@
         return;
     }
 
-    crow::connections::systemBus->async_method_call(
+    sdbusplus::message::object_path path("/xyz/openbmc_project/dump");
+    dbus::utility::getManagedObjects(
+        "xyz.openbmc_project.Dump.Manager", path,
         [asyncResp, entriesPath,
          dumpType](const boost::system::error_code& ec,
-                   dbus::utility::ManagedObjectType& resp) {
+                   const dbus::utility::ManagedObjectType& objects) {
         if (ec)
         {
             BMCWEB_LOG_ERROR << "DumpEntry resp_handler got error " << ec;
@@ -498,6 +500,7 @@
             "/xyz/openbmc_project/dump/" +
             std::string(boost::algorithm::to_lower_copy(dumpType)) + "/entry/";
 
+        dbus::utility::ManagedObjectType resp(objects);
         std::sort(resp.begin(), resp.end(), [](const auto& l, const auto& r) {
             return AlphanumLess<std::string>()(l.first.filename(),
                                                r.first.filename());
@@ -567,9 +570,7 @@
             entriesArray.emplace_back(std::move(thisEntry));
         }
         asyncResp->res.jsonValue["Members@odata.count"] = entriesArray.size();
-        },
-        "xyz.openbmc_project.Dump.Manager", "/xyz/openbmc_project/dump",
-        "org.freedesktop.DBus.ObjectManager", "GetManagedObjects");
+        });
 }
 
 inline void
@@ -583,7 +584,9 @@
         return;
     }
 
-    crow::connections::systemBus->async_method_call(
+    sdbusplus::message::object_path path("/xyz/openbmc_project/dump");
+    dbus::utility::getManagedObjects(
+        "xyz.openbmc_project.Dump.Manager", path,
         [asyncResp, entryID, dumpType,
          entriesPath](const boost::system::error_code& ec,
                       const dbus::utility::ManagedObjectType& resp) {
@@ -667,9 +670,7 @@
                                        entryID);
             return;
         }
-        },
-        "xyz.openbmc_project.Dump.Manager", "/xyz/openbmc_project/dump",
-        "org.freedesktop.DBus.ObjectManager", "GetManagedObjects");
+        });
 }
 
 inline void deleteDumpEntry(const std::shared_ptr<bmcweb::AsyncResp>& asyncResp,
@@ -1564,7 +1565,9 @@
 
         // DBus implementation of EventLog/Entries
         // Make call to Logging Service to find all log entry objects
-        crow::connections::systemBus->async_method_call(
+        sdbusplus::message::object_path path("/xyz/openbmc_project/logging");
+        dbus::utility::getManagedObjects(
+            "xyz.openbmc_project.Logging", path,
             [asyncResp](const boost::system::error_code& ec,
                         const dbus::utility::ManagedObjectType& resp) {
             if (ec)
@@ -1718,9 +1721,7 @@
                 });
             asyncResp->res.jsonValue["Members@odata.count"] =
                 entriesArray.size();
-            },
-            "xyz.openbmc_project.Logging", "/xyz/openbmc_project/logging",
-            "org.freedesktop.DBus.ObjectManager", "GetManagedObjects");
+            });
         });
 }
 
diff --git a/redfish-core/lib/managers.hpp b/redfish-core/lib/managers.hpp
index 5bb4908..b630609 100644
--- a/redfish-core/lib/managers.hpp
+++ b/redfish-core/lib/managers.hpp
@@ -290,7 +290,9 @@
                      const std::vector<std::string>& supportedProfiles,
                      const std::shared_ptr<bmcweb::AsyncResp>& asyncResp)
 {
-    crow::connections::systemBus->async_method_call(
+    sdbusplus::message::object_path objPath(path);
+    dbus::utility::getManagedObjects(
+        connection, objPath,
         [asyncResp, currentProfile, supportedProfiles](
             const boost::system::error_code& ec,
             const dbus::utility::ManagedObjectType& managedObj) {
@@ -688,8 +690,7 @@
                 }
             }
         }
-        },
-        connection, path, objectManagerIface, "GetManagedObjects");
+        });
 }
 
 enum class CreatePIDRet
@@ -1358,7 +1359,10 @@
 
         // todo(james): might make sense to do a mapper call here if this
         // interface gets more traction
-        crow::connections::systemBus->async_method_call(
+        sdbusplus::message::object_path objPath(
+            "/xyz/openbmc_project/inventory");
+        dbus::utility::getManagedObjects(
+            "xyz.openbmc_project.EntityManager", objPath,
             [self](const boost::system::error_code& ec,
                    const dbus::utility::ManagedObjectType& mObj) {
             if (ec)
@@ -1384,10 +1388,7 @@
                 }
             }
             self->managedObj = mObj;
-            },
-            "xyz.openbmc_project.EntityManager",
-            "/xyz/openbmc_project/inventory", objectManagerIface,
-            "GetManagedObjects");
+            });
 
         // at the same time get the profile information
         constexpr std::array<std::string_view, 1> thermalModeIfaces = {
@@ -1779,10 +1780,12 @@
     std::string firmwareId = runningFirmwareTarget.substr(idPos);
 
     // Make sure the image is valid before setting priority
-    crow::connections::systemBus->async_method_call(
-        [asyncResp, firmwareId,
-         runningFirmwareTarget](const boost::system::error_code& ec,
-                                dbus::utility::ManagedObjectType& subtree) {
+    sdbusplus::message::object_path objPath("/xyz/openbmc_project/software");
+    dbus::utility::getManagedObjects(
+        "xyz.openbmc_project.Software.BMC.Updater", objPath,
+        [asyncResp, firmwareId, runningFirmwareTarget](
+            const boost::system::error_code& ec,
+            const dbus::utility::ManagedObjectType& subtree) {
         if (ec)
         {
             BMCWEB_LOG_DEBUG << "D-Bus response error getting objects.";
@@ -1852,10 +1855,7 @@
             "org.freedesktop.DBus.Properties", "Set",
             "xyz.openbmc_project.Software.RedundancyPriority", "Priority",
             dbus::utility::DbusVariantType(static_cast<uint8_t>(0)));
-        },
-        "xyz.openbmc_project.Software.BMC.Updater",
-        "/xyz/openbmc_project/software", "org.freedesktop.DBus.ObjectManager",
-        "GetManagedObjects");
+        });
 }
 
 inline void setDateTime(std::shared_ptr<bmcweb::AsyncResp> asyncResp,
diff --git a/redfish-core/lib/network_protocol.hpp b/redfish-core/lib/network_protocol.hpp
index be84246..35c3dae 100644
--- a/redfish-core/lib/network_protocol.hpp
+++ b/redfish-core/lib/network_protocol.hpp
@@ -98,7 +98,9 @@
 template <typename CallbackFunc>
 void getEthernetIfaceData(CallbackFunc&& callback)
 {
-    crow::connections::systemBus->async_method_call(
+    sdbusplus::message::object_path path("/xyz/openbmc_project/network");
+    dbus::utility::getManagedObjects(
+        "xyz.openbmc_project.Network", path,
         [callback{std::forward<CallbackFunc>(callback)}](
             const boost::system::error_code& errorCode,
             const dbus::utility::ManagedObjectType& dbusData) {
@@ -114,9 +116,7 @@
         extractNTPServersAndDomainNamesData(dbusData, ntpServers, domainNames);
 
         callback(true, ntpServers, domainNames);
-        },
-        "xyz.openbmc_project.Network", "/xyz/openbmc_project/network",
-        "org.freedesktop.DBus.ObjectManager", "GetManagedObjects");
+        });
 }
 
 inline void afterNetworkPortRequest(
diff --git a/redfish-core/lib/processor.hpp b/redfish-core/lib/processor.hpp
index a2c49a6..2d52cd7 100644
--- a/redfish-core/lib/processor.hpp
+++ b/redfish-core/lib/processor.hpp
@@ -225,7 +225,9 @@
 {
     BMCWEB_LOG_DEBUG << "Get available system cpu resources by service.";
 
-    crow::connections::systemBus->async_method_call(
+    sdbusplus::message::object_path path("/xyz/openbmc_project/inventory");
+    dbus::utility::getManagedObjects(
+        service, path,
         [cpuId, service, objPath, asyncResp{std::move(asyncResp)}](
             const boost::system::error_code& ec,
             const dbus::utility::ManagedObjectType& dbusData) {
@@ -288,9 +290,7 @@
             asyncResp->res.jsonValue["TotalCores"] = totalCores;
         }
         return;
-        },
-        service, "/xyz/openbmc_project/inventory",
-        "org.freedesktop.DBus.ObjectManager", "GetManagedObjects");
+        });
 }
 
 /**
diff --git a/redfish-core/lib/sensors.hpp b/redfish-core/lib/sensors.hpp
index f69ea5f..3fbbd2d 100644
--- a/redfish-core/lib/sensors.hpp
+++ b/redfish-core/lib/sensors.hpp
@@ -1449,12 +1449,14 @@
     {
         const std::string& invConnection = *it;
 
-        // Response handler for GetManagedObjects
-        auto respHandler = [sensorsAsyncResp, inventoryItems, invConnections,
-                            callback{std::forward<Callback>(callback)},
-                            invConnectionsIndex](
-                               const boost::system::error_code& ec,
-                               const dbus::utility::ManagedObjectType& resp) {
+        // Get all object paths and their interfaces for current connection
+        sdbusplus::message::object_path path("/xyz/openbmc_project/inventory");
+        dbus::utility::getManagedObjects(
+            invConnection, path,
+            [sensorsAsyncResp, inventoryItems, invConnections,
+             callback{std::forward<Callback>(callback)}, invConnectionsIndex](
+                const boost::system::error_code& ec,
+                const dbus::utility::ManagedObjectType& resp) {
             BMCWEB_LOG_DEBUG << "getInventoryItemsData respHandler enter";
             if (ec)
             {
@@ -1486,13 +1488,7 @@
                                   invConnectionsIndex + 1);
 
             BMCWEB_LOG_DEBUG << "getInventoryItemsData respHandler exit";
-        };
-
-        // Get all object paths and their interfaces for current connection
-        crow::connections::systemBus->async_method_call(
-            std::move(respHandler), invConnection,
-            "/xyz/openbmc_project/inventory",
-            "org.freedesktop.DBus.ObjectManager", "GetManagedObjects");
+            });
     }
 
     BMCWEB_LOG_DEBUG << "getInventoryItemsData exit";
@@ -1606,8 +1602,10 @@
 {
     BMCWEB_LOG_DEBUG << "getInventoryItemAssociations enter";
 
-    // Response handler for GetManagedObjects
-    auto respHandler =
+    // Call GetManagedObjects on the ObjectMapper to get all associations
+    sdbusplus::message::object_path path("/");
+    dbus::utility::getManagedObjects(
+        "xyz.openbmc_project.ObjectMapper", path,
         [callback{std::forward<Callback>(callback)}, sensorsAsyncResp,
          sensorNames](const boost::system::error_code& ec,
                       const dbus::utility::ManagedObjectType& resp) {
@@ -1716,12 +1714,7 @@
         }
         callback(inventoryItems);
         BMCWEB_LOG_DEBUG << "getInventoryItemAssociations respHandler exit";
-    };
-
-    // Call GetManagedObjects on the ObjectMapper to get all associations
-    crow::connections::systemBus->async_method_call(
-        std::move(respHandler), "xyz.openbmc_project.ObjectMapper", "/",
-        "org.freedesktop.DBus.ObjectManager", "GetManagedObjects");
+        });
 
     BMCWEB_LOG_DEBUG << "getInventoryItemAssociations exit";
 }
@@ -2269,8 +2262,10 @@
     // Get managed objects from all services exposing sensors
     for (const std::string& connection : connections)
     {
-        // Response handler to process managed objects
-        auto getManagedObjectsCb =
+        sdbusplus::message::object_path sensorPath(
+            "/xyz/openbmc_project/sensors");
+        dbus::utility::getManagedObjects(
+            connection, sensorPath,
             [sensorsAsyncResp, sensorNames,
              inventoryItems](const boost::system::error_code& ec,
                              const dbus::utility::ManagedObjectType& resp) {
@@ -2482,11 +2477,7 @@
                 }
             }
             BMCWEB_LOG_DEBUG << "getManagedObjectsCb exit";
-        };
-
-        crow::connections::systemBus->async_method_call(
-            getManagedObjectsCb, connection, "/xyz/openbmc_project/sensors",
-            "org.freedesktop.DBus.ObjectManager", "GetManagedObjects");
+            });
     }
     BMCWEB_LOG_DEBUG << "getSensorData exit";
 }
diff --git a/redfish-core/lib/virtual_media.hpp b/redfish-core/lib/virtual_media.hpp
index 5e177ab..81af41f 100644
--- a/redfish-core/lib/virtual_media.hpp
+++ b/redfish-core/lib/virtual_media.hpp
@@ -94,7 +94,9 @@
                        const std::shared_ptr<bmcweb::AsyncResp>& asyncResp,
                        CheckItemHandler&& handler)
 {
-    crow::connections::systemBus->async_method_call(
+    sdbusplus::message::object_path path("/xyz/openbmc_project/VirtualMedia");
+    dbus::utility::getManagedObjects(
+        service, path,
         [service, resName, asyncResp,
          handler](const boost::system::error_code& ec,
                   const dbus::utility::ManagedObjectType& subtree) {
@@ -117,9 +119,7 @@
 
         BMCWEB_LOG_DEBUG << "Parent item not found";
         asyncResp->res.result(boost::beast::http::status::not_found);
-        },
-        service, "/xyz/openbmc_project/VirtualMedia",
-        "org.freedesktop.DBus.ObjectManager", "GetManagedObjects");
+        });
 }
 
 /**
@@ -273,7 +273,10 @@
                               const std::string& name)
 {
     BMCWEB_LOG_DEBUG << "Get available Virtual Media resources.";
-    crow::connections::systemBus->async_method_call(
+    sdbusplus::message::object_path objPath(
+        "/xyz/openbmc_project/VirtualMedia");
+    dbus::utility::getManagedObjects(
+        service, objPath,
         [name, asyncResp{std::move(asyncResp)}](
             const boost::system::error_code& ec,
             const dbus::utility::ManagedObjectType& subtree) {
@@ -299,9 +302,7 @@
             members.emplace_back(std::move(item));
         }
         asyncResp->res.jsonValue["Members@odata.count"] = members.size();
-        },
-        service, "/xyz/openbmc_project/VirtualMedia",
-        "org.freedesktop.DBus.ObjectManager", "GetManagedObjects");
+        });
 }
 
 inline void
@@ -877,10 +878,13 @@
         std::string service = getObjectType.begin()->first;
         BMCWEB_LOG_DEBUG << "GetObjectType: " << service;
 
-        crow::connections::systemBus->async_method_call(
-            [service, resName, action, actionParams,
-             asyncResp](const boost::system::error_code& ec2,
-                        dbus::utility::ManagedObjectType& subtree) mutable {
+        sdbusplus::message::object_path path(
+            "/xyz/openbmc_project/VirtualMedia");
+        dbus::utility::getManagedObjects(
+            service, path,
+            [service, resName, action, actionParams, asyncResp](
+                const boost::system::error_code& ec2,
+                const dbus::utility::ManagedObjectType& subtree) mutable {
             if (ec2)
             {
                 // Not possible in proxy mode
@@ -902,9 +906,7 @@
             }
             BMCWEB_LOG_DEBUG << "Parent item not found";
             messages::resourceNotFound(asyncResp->res, "VirtualMedia", resName);
-            },
-            service, "/xyz/openbmc_project/VirtualMedia",
-            "org.freedesktop.DBus.ObjectManager", "GetManagedObjects");
+            });
         });
 }
 
@@ -941,7 +943,10 @@
         std::string service = getObjectType.begin()->first;
         BMCWEB_LOG_DEBUG << "GetObjectType: " << service;
 
-        crow::connections::systemBus->async_method_call(
+        sdbusplus::message::object_path path(
+            "/xyz/openbmc_project/VirtualMedia");
+        dbus::utility::getManagedObjects(
+            service, path,
             [resName, service, action,
              asyncResp](const boost::system::error_code& ec,
                         const dbus::utility::ManagedObjectType& subtree) {
@@ -964,9 +969,7 @@
             }
             BMCWEB_LOG_DEBUG << "Parent item not found";
             messages::resourceNotFound(asyncResp->res, "VirtualMedia", resName);
-            },
-            service, "/xyz/openbmc_project/VirtualMedia",
-            "org.freedesktop.DBus.ObjectManager", "GetManagedObjects");
+            });
         });
 }
 
