Before place order checkout action plugin Magento 2.

You can create a plugin for Before Place order action In Magento 2 using beforePlace() method.

When you required to check or set data before place order in Magento 2, You can use a plugin for OrderManagementInterface interface place() method.

place() method from the Magento\Sales\Api\OrderManagementInterface interface class used to Place order operation in Magento 2 from checkout page.

You just need to define plugin definition in di.xml file to create a plugin.

Create a Global di.xml file inside etc/di.xml file,

Now you need to create OrderManagement.php file inside your module Plugin folder.

Path: app\code\Rbj\Order\Plugin\OrderManagement.php

$subject contains the many functions you can explore the functions using get_class_methods($subject);

You can fetch $order object using the above way and based on your custom conditions you can get required data from the order object.

You can set data before place order using the above way.