For some unique customization, we need to create customer extension attribute to fulfil client requirements in magento2. In this blog, I created extension attribute with different datatype.is_happy_customer booleanhappy_message stringhappy_number inthappy_list arrayhappy_object objectFirst create file etc/extension_attributes.xml Now we need to create interface and model for HappyObjectCreate interface at app/code/MageDad/Module/Api/Data/HappyObjectInterface.php Create model at app/code/MageDad/Module/Model/HappyObject.php Now we create plugin for bind attribute value of extension attribute.Create di.xml at app/code/MageDad/Module/etc/di.xml Create plugin at app/code/MageDad/Module/Plugin/CustomerPlugin.php Above code in line $happy…
Tag