diff --git a/dcmihandler.cpp b/dcmihandler.cpp
index 11a3730..0508b81 100644
--- a/dcmihandler.cpp
+++ b/dcmihandler.cpp
@@ -95,6 +95,27 @@
     }
 }
 
+void setPcapEnable(sdbusplus::bus::bus& bus, bool enabled)
+{
+    auto service = ipmi::getService(bus, PCAP_INTERFACE, PCAP_PATH);
+
+    auto method = bus.new_method_call(service.c_str(),
+                                      PCAP_PATH,
+                                      "org.freedesktop.DBus.Properties",
+                                      "Set");
+
+    method.append(PCAP_INTERFACE, POWER_CAP_ENABLE_PROP);
+    method.append(sdbusplus::message::variant<bool>(enabled));
+
+    auto reply = bus.call(method);
+
+    if (reply.is_method_error())
+    {
+        log<level::ERR>("Error in setPcapEnabled property");
+        elog<InternalFailure>();
+    }
+}
+
 void readAssetTagObjectTree(dcmi::assettag::ObjectTree& objectTree)
 {
     static constexpr auto mapperBusName = "xyz.openbmc_project.ObjectMapper";
@@ -288,6 +309,45 @@
     return IPMI_CC_OK;
 }
 
+ipmi_ret_t applyPowerLimit(ipmi_netfn_t netfn, ipmi_cmd_t cmd,
+                           ipmi_request_t request, ipmi_response_t response,
+                           ipmi_data_len_t data_len, ipmi_context_t context)
+{
+    auto requestData = reinterpret_cast<const dcmi::ApplyPowerLimitRequest*>
+                   (request);
+    std::vector<uint8_t> outPayload(sizeof(dcmi::ApplyPowerLimitResponse));
+    auto responseData = reinterpret_cast<dcmi::ApplyPowerLimitResponse*>
+            (outPayload.data());
+
+    if (requestData->groupID != dcmi::groupExtId)
+    {
+        *data_len = 0;
+        return IPMI_CC_INVALID_FIELD_REQUEST;
+    }
+
+    sdbusplus::bus::bus sdbus {ipmid_get_sd_bus_connection()};
+
+    try
+    {
+        dcmi::setPcapEnable(sdbus,
+                            static_cast<bool>(requestData->powerLimitAction));
+    }
+    catch (InternalFailure& e)
+    {
+        *data_len = 0;
+        return IPMI_CC_UNSPECIFIED_ERROR;
+    }
+
+    log<level::INFO>("Set Power Cap Enable",
+                     entry("POWERCAPENABLE=%u", requestData->powerLimitAction));
+
+    responseData->groupID = dcmi::groupExtId;
+    memcpy(response, outPayload.data(), outPayload.size());
+    *data_len = outPayload.size();
+
+    return IPMI_CC_OK;
+}
+
 ipmi_ret_t getAssetTag(ipmi_netfn_t netfn, ipmi_cmd_t cmd,
                        ipmi_request_t request, ipmi_response_t response,
                        ipmi_data_len_t data_len, ipmi_context_t context)
@@ -435,6 +495,11 @@
     ipmi_register_callback(NETFUN_GRPEXT, IPMI_CMD_DCMI_SET_POWER_LIMIT, NULL, setPowerLimit,
                            PRIVILEGE_OPERATOR);
 
+    // <Activate/Deactivate Power Limit>
+    printf("Registering NetFn:[0x%X], Cmd:[0x%X]\n",NETFUN_GRPEXT, IPMI_CMD_DCMI_APPLY_POWER_LIMIT);
+    ipmi_register_callback(NETFUN_GRPEXT, IPMI_CMD_DCMI_APPLY_POWER_LIMIT, NULL, applyPowerLimit,
+                           PRIVILEGE_OPERATOR);
+
     // <Get Asset Tag>
     printf("Registering NetFn:[0x%X], Cmd:[0x%X]\n",NETFUN_GRPEXT, IPMI_CMD_DCMI_GET_ASSET_TAG);
     ipmi_register_callback(NETFUN_GRPEXT, IPMI_CMD_DCMI_GET_ASSET_TAG, NULL, getAssetTag,
diff --git a/dcmihandler.hpp b/dcmihandler.hpp
index e318294..cb46d5c 100644
--- a/dcmihandler.hpp
+++ b/dcmihandler.hpp
@@ -12,6 +12,7 @@
     // Get capability bits
     IPMI_CMD_DCMI_GET_POWER_LIMIT = 0x03,
     IPMI_CMD_DCMI_SET_POWER_LIMIT = 0x04,
+    IPMI_CMD_DCMI_APPLY_POWER_LIMIT = 0x05,
     IPMI_CMD_DCMI_GET_ASSET_TAG = 0x06,
     IPMI_CMD_DCMI_SET_ASSET_TAG = 0x08,
 };
@@ -178,6 +179,33 @@
     uint8_t groupID;            //!< Group extension identification.
 } __attribute__((packed));
 
+/** @brief Enable or disable the power capping
+ *
+ *  @param[in] bus - dbus connection
+ *  @param[in] enabled - enable/disable
+ */
+void setPcapEnable(sdbusplus::bus::bus& bus, bool enabled);
+
+/** @struct ApplyPowerLimitRequest
+ *
+ *  DCMI payload for Activate/Deactivate Power Limit command request.
+ */
+struct ApplyPowerLimitRequest
+{
+    uint8_t groupID;            //!< Group extension identification.
+    uint8_t powerLimitAction;   //!< Power limit activation
+    uint16_t reserved;          //!< Reserved
+} __attribute__((packed));
+
+/** @struct ApplyPowerLimitResponse
+ *
+ *  DCMI payload for Acticate/Deactivate Power Limit command response.
+ */
+struct ApplyPowerLimitResponse
+{
+    uint8_t groupID;            //!< Group extension identification.
+} __attribute__((packed));
+
 } // namespace dcmi
 
 #endif
