# `PhoenixKit.Modules.Shop.Import.Filter`
[🔗](https://github.com/BeamLabEU/phoenix_kit/blob/v1.7.63/lib/modules/shop/import/filter.ex#L1)

Filter products for import based on configurable rules.

Supports both legacy hardcoded keywords (for backward compatibility)
and configurable ImportConfig-based filtering.

## Configuration-based filtering

    config = Shop.get_default_import_config()
    Filter.should_include?(rows, config)
    Filter.categorize(title, config)

## Legacy filtering (backward compatible)

    Filter.should_include?(rows)  # Uses hardcoded defaults
    Filter.categorize(title)      # Uses hardcoded defaults

# `categorize`
[🔗](https://github.com/BeamLabEU/phoenix_kit/blob/v1.7.63/lib/modules/shop/import/filter.ex#L108)

Categorize product based on title keywords.

## With config

    Filter.categorize(title, config)

Uses category_rules from config. Returns default_category_slug if no match.

## Without config (legacy)

    Filter.categorize(title)

Uses hardcoded category rules. Returns "other-3d" if no match.

# `should_include?`
[🔗](https://github.com/BeamLabEU/phoenix_kit/blob/v1.7.63/lib/modules/shop/import/filter.ex#L60)

Check if product should be included in import.

## With config

    Filter.should_include?(rows, config)

Returns true if:
- Config has `skip_filter: true`, OR
- Title matches at least one include keyword AND
- Title does NOT match any exclude keyword/phrase

## Without config (legacy)

    Filter.should_include?(rows)

Uses hardcoded default keywords for backward compatibility.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
