Log in
Model

Option\Repository

Magento\Catalog\Model\Product\Option\Repository

What it does

This repository class manages product custom options (like size, color, personalization fields) in Magento 2.

Developers use it to retrieve, save, delete, and duplicate custom options for products through a service contract interface, making it the primary way to programmatically handle product options via API or custom modules.

Public Methods

  • getList()
  • getProductOptions()
  • get()
  • delete()
  • duplicate()
  • save()
  • deleteByIdentifier()