0

I want to add extension attribute to the default API to identify the visual and text swatches http://localhost/m2.4/rest/V1/products/attribute-sets/4/attributes API.

1 Answer 1

0

@adi Please see this below link

Answered

Follow the steps as mentioned and replace

Magento\Sales\Api\Data\OrderItemInterface to Magento\Catalog\Api\Data\ProductAttributeInterface

It will work

Change the code as required

2
  • its not working for me as i needed for rest/V1/products/attribute-sets/4/attributes API Commented Mar 30, 2021 at 9:23
  • @adimaheshwary I edit my answer please look into it.
    – Ankit
    Commented Mar 31, 2021 at 5:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.