Log in
Interface

ProductCustomOptionTypeInterface

Magento\Catalog\Api\Data\ProductCustomOptionTypeInterface

What it does

This interface defines the structure for product custom option types in Magento 2.

Developers use it when working with customizable product options to access or set the option type's label (display name), code (internal identifier), and group (category like 'text', 'select', 'date', or 'file').

It's particularly useful when creating or retrieving information about different types of custom options that can be added to products, such as text fields, dropdowns, or file uploads.

Public Methods

  • getLabel()
  • setLabel()
  • getCode()
  • setCode()
  • getGroup()
  • setGroup()
  • getExtensionAttributes()
  • setExtensionAttributes()