Log in
Model

CheckCategoryIsActive

Magento\CatalogGraphQl\Model\Resolver\Category\CheckCategoryIsActive

What it does

This class validates whether a category exists and is active in Magento 2's GraphQL API.

Developers use this to ensure GraphQL queries only return active categories, throwing a GraphQlNoSuchEntityException if the category is inactive or doesn't exist.

It's typically called by category-related GraphQL resolvers before returning category data.

Public Methods

  • execute()