Skip to main content

Post filter rules

Post filter rules are conditional rules applied after all delivery options have been calculated during checkout.

J
Written by Jakub Talarek

What is it?

Post filter rules are conditional rules applied after all delivery options have been calculated during checkout. They let you fine-tune the final list of delivery methods shown to customers — for example, hiding a redundant option or displaying a fallback method when preferred ones are unavailable.

Post filter rules work alongside Filter rules, but at a different stage:

  • Filter rules run before contacting carriers — they use product, customer, and cart data to decide which carrier products to request

  • Post filter rules run after carrier responses — they adjust the final list based on which delivery methods are actually available

Post filter rules are simpler: they only check whether a specific delivery method is present or absent, and then show or hide another method accordingly.

Note: Post filter rules are only supported in Checkout V2.


Key benefits

  • Remove redundant options — when two carriers return similar delivery methods, hide one to keep checkout clean

  • Enable fallback logic — show a backup delivery method only when preferred options are unavailable

  • Fine-tune without complexity — simple if/then rules that don't require product or cart data

  • No performance impact — rules filter an existing list, no additional carrier API calls


How it works

  1. Customer reaches checkout — Ingrid calculates all available delivery options

  2. Filter rules are applied (before carrier contact)

  3. Carriers are contacted for availability, ETAs, and pickup points

  4. Post filter rules are applied — the final list is refined based on which methods are available

  5. Price rules are applied and the final delivery options are shown to the customer


Common use cases

Hide a delivery method when a preferred option is available

You offer two pick-up point carriers. When the preferred carrier is available, hide the fallback to avoid showing duplicate options.

Rule on the fallback carrier product:

!session.categories.exists(c, c.options.exists(o, o.shipping_method == "preferred-carrier-id"))

How it reads: "Show this method only if the preferred carrier is NOT available."

Result: Customers see one clean pick-up point option. If the preferred carrier has an outage, the fallback appears automatically.

Hide a method when any of several preferred options is available

You want to hide a fallback when any of your preferred delivery methods is available.

Rule:

!session.categories.exists(c, c.options.exists(o, o.shipping_method == "preferred-a" || o.shipping_method == "preferred-b"))

How it reads: "Show this method only if neither preferred-a nor preferred-b is available."

Show a fallback when nothing else is available

You have strict size and weight limits on your carrier products. When a customer's cart exceeds all limits, no delivery options would appear. You want a "manual handling" fallback that only shows as a last resort.

Rule on the fallback carrier product:

session.categories.all(c, c.options.all(o, o.shipping_method == "manual-fallback"))

How it reads: "Show this method only when it is the only option left."

Result: Customers always see at least one delivery option, even when all standard carriers are unavailable.

Note: This pattern requires a Custom Shipping Option (CSO) to be configured first. Contact your Ingrid representative for setup.


How to set it up

  1. In the Ingrid Merchant Platform, navigate to Delivery Checkout → Regions → [Select Region] → Carrier Products

  2. Find the carrier product you want to add a post filter rule to

  3. In the Post filter rules text field, enter the rule expression

  4. Save your configuration

  5. Test using the Checkout Playground to verify delivery options appear or disappear correctly

Rule syntax reference

What you want to do

Expression

Show only if method X is not available

!session.categories.exists(c, c.options.exists(o, o.shipping_method == "method-x"))

Show only if neither X nor Y is available

!session.categories.exists(c, c.options.exists(o, o.shipping_method == "method-x" \|\| o.shipping_method == "method-y"))

Show only when nothing else is available

session.categories.all(c, c.options.all(o, o.shipping_method == "this-method"))

Replace "method-x" with the actual shipping method ID of the carrier product (e.g. "inpost-std", "pnl-mph"). You can find the shipping method ID in the carrier product configuration in the Ingrid Merchant Platform.


Frequently Asked Questions

Q: What's the difference between filter rules and post filter rules?
A: Filter rules run before contacting carriers and can use product, customer, and cart data for complex conditions (e.g. "don't offer express for orders over 20kg"). Post filter rules run after carrier responses and only check which delivery methods are present or absent (e.g. "hide fallback when preferred carrier is available").

Q: Can I use post filter rules in Checkout V1?
A: No. Post filter rules are only supported in Checkout V2. For V1, similar functionality is available through session_post_processing.json configuration.

Q: Where do I find the shipping method ID?
A: In the Ingrid Merchant Platform, go to Delivery Checkout → Regions → [Region] → Carrier Products. The shipping method ID is shown as "External method id" for each carrier product.

Q: Can I add multiple post filter rules to one carrier product?
A: Yes. All conditions must be true for the method to be shown (AND logic). If any rule's condition is false, the method is hidden.

Q: Can post filter rules change delivery prices or times?
A: No. Post filter rules can only show or hide delivery methods. They cannot modify prices, delivery times, or any other attributes.

Q: What happens if my rule has a syntax error?
A: The rule will not be applied and the delivery method will behave as if no post filter rule is set. Always test your rules using the Checkout Playground after saving.


Related documentation

Did this answer your question?