I have an endpoint created and I am getting the groupID but I am unable to get all the categories associated with the group.

This is what I have right now:

$categoriesGroup = Craft::$app->categories->getGroupById($catId);

I can't seem to get an array of entries from that.

1 Answer 1

$categories = Category::find()->groupId($id)->all();

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.