How to Get all Bundle item options details by SKU Magento 2.

You can get the list of Bundle item options details of bundle products by SKU using Magento 2.

Bundle products have multiple options to generate a single bundle item. The bundle will be generated using dropdown, radio and checkbox options. You can see all the options from the admin panel, edit bundle product, Bundle item section of the product.

Magento 2 Sample data bundle products SKU 24-WG080 has four options available. We can get all the four options details by Passing bundle product SKU  using below snippet code,

You can use getList() method from the interface Magento\Bundle\Api\ProductOptionRepositoryInterface to fetch detail of options.

Call Method to get details of each option,

bundle-options

Bundle product options detailsOutput:
An array of OptionInterface.

Error On SKU invalid: The product that was requested doesn’t exist. Verify the product and try again.

You can get the details of the specific option of bundle product by link, Bundle Option details.