public function getCustomerTaxClasses()
    {
        /** @var \Magento\Tax\Model\ResourceModel\TaxClass\Collection $taxCollection */
        $classes       = [];
        $defaultTaxId  = $this->customerGroup->getNotLoggedInGroup()->getTaxClassId();
        $taxCollection = $this->taxClass->getCollection();
        $taxCollection->setClassTypeFilter(ClassModel::TAX_CLASS_TYPE_CUSTOMER);

        /** @var ClassModel $tax */
        foreach ($taxCollection as $tax) {
            $classes[] = [
                'id'         => $tax->getId(),
                'key'        => $tax->getClassName(),
                'is_default' => intval($defaultTaxId == $tax->getId()),
            ];
        }

        return $classes;
    }
public function getCustomerTaxClasses()
    {
        /** @var \Magento\Tax\Model\ResourceModel\TaxClass\Collection $taxCollection */
        $classes       = [];
        $defaultTaxId  = $this->customerGroup->getNotLoggedInGroup()->getTaxClassId();
        $taxCollection = $this->taxClass->getCollection();
        $taxCollection->setClassTypeFilter(ClassModel::TAX_CLASS_TYPE_CUSTOMER);

        /** @var ClassModel $tax */
        foreach ($taxCollection as $tax) {
            $classes[] = [
                'id'         => $tax->getId(),
                'key'        => $tax->getClassName(),
                'is_default' => intval($defaultTaxId == $tax->getId()),
            ];
        }

        return $classes;
    }
public function getCustomerTaxClasses ( ) { /** @var \Magento\Tax\Model\ResourceModel\TaxClass\Collection $taxCollection */ $ classes = [ ] ; $ defaultTaxId = $ this -> customerGroup -> getNotLoggedInGroup ( ) -> getTaxClassId ( ) ; $ taxCollection = $ this -> taxClass -> getCollection ( ) ; $ taxCollection -> setClassTypeFilter ( ClassModel :: TAX_CLASS_TYPE_CUSTOMER ) ; /** @var ClassModel $tax */ foreach ( $ taxCollection as $ tax ) { $ classes [ ] = [ 'id' => $ tax -> getId ( ) , 'key' => $ tax -> getClassName ( ) , 'is_default' => intval ( $ defaultTaxId == $ tax -> getId ( ) ) , ] ; } return $ classes ; }
Retrieves all customer related tax classes
for Merchant API to pick up

@return array
Retrieves all customer related tax classes for Merchant API to pick up