---
title: "Configuration – Chat-based validation rules for order capture"
description: "Qargo has a built-in AI agent that lets users create order capture validation rules themselves just by describing them in plain language. Setting up a validation rule used to mean involving engineering. Now users can describe, test, and enable rules themselves."
url: https://help.qargo.com/us/articles/709425-configuration-chat-based-validation-rules-for-order-capture
locale: us
updated: 2026-06-15
---

# Configuration – Chat-based validation rules for order capture

## Summary {#h_658a965c69}

-   **What is it?**

    -   A conversational _AI agent_ in **Configuration > Rules** that turns a plain-language description into an order capture validation rule.
    -   The agent produces the same underlying rule mechanism used today. No new rule types or entry points are introduced.
-   **Why use it?**

    -   Until now, only Qargo Professional Services could author these rules, so every new rule became an internal ticket.
    -   Chat-based authoring lets users (Super admin / Qargo admin only) create and adjust validation rules directly.
-   **How does it work?**

    -   A rule is described in plain language and refined with the agent over several turns until it is correct.
    -   A rule can be tested against a mock order before saving, directly from the order create screen.
    -   Rules keep working when copied between sandbox and production.

## Prerequisites {#h_32ff22a307}

-   _Super admin_ access: rule authoring is located under **Configuration > Rules**.
-   The _Qargo Intelligence_ (Qi) feature flag must be enabled for the tenant.

## Use cases {#h_0d899200c6}

-   Blocking an order when a required field, such as packaging type, is left empty.
-   Enforcing packaging weight limits or locked pallet-space rules at the point of order capture.
-   Restricting allowed time windows or service-level availability per ZIP code zone.
-   Allowing Admin users to adjust a validation rule without raising a ticket.

## Terminology {#h_5e1e0275da}

| **Term** | **Definition** |
| --- | --- |
| _Validation rule_ | A check applied at order capture that blocks input on the portal and shows a warning in the web app when conditions are not met. |
| _Chat agent_ | The conversational AI assistant that translates a plain-language description into a validation rule. |
| _Master data_ | Reference records such as customers, locations, and packaging types, matched by their code. |
| _Validation mode_ | A test mode that opens the order create screen so a mock order can be built to check a rule. |

## Creating a rule {#h_a8c7cd8a43}

🎥 This video shows the entire process of creating chat-based validation rules:

::embed{src="https://watchclueso.com/embed/v78nwub4k9mnksfi"}

1.  **Navigate** to **Configuration > Rules**.
2.  **Create rule** by clicking the button in the top right-hand corner.
3.  **Describe** the required validation rule to the _chat agent_ in plain language.

::video{src="/media/video/658af29bb044-Validation-rules-S1.mp4"}

1.  **Review** the agent's response and **refine** the description over additional turns until the rule reflects the intended check.
2.  **Confirm** the matched master data items. The agent auto-fills codes, and the resolved list remains editable.

![](https://help.qargo.com/media/f285dd681852-Validation-rules-S2.png)

## Testing a rule before saving {#h_e285348ef9}

1.  **Open** _validation mode_ on the draft rule. A pop-over opens the order create screen.
2.  **Build** a mock order that should trigger the rule.
3.  **Visualize** the rule's effect on the mock order before saving.

::video{src="/media/video/86c2ed464abf-Validation-rules-S3.mp4"}

:::callout{tone="warning"}
‼️ Thorough validation is strongly recommended, because the rule is generated by AI and can still be incorrect even when it appears right.
:::

## Saving a rule {#h_bad7c865dc}

Once validation is complete, the rule must be saved.

1.  **Save rule** by clicking the button next to Validate.
2.  The rule then appears in the **Order capture/edit validation rules overview**.
3.  From there, rules in the account can be **edited**, **deactivated**, or even **removed**.

![](https://help.qargo.com/media/2f92b9b8cc8c-Validation-rules-S4.png)

## How master data is matched {#h_624d991103}

-   Rules reference master data (customers, locations, packaging types, and so on) by _code_ rather than by name.
-   Setting a code on these entities is strongly recommended, because codes are more stable for rule generation.
-   The same rule continues to work when copied between sandbox and production, since codes are consistent across environments.

## Troubleshooting {#h_e419202c4b}

| **Issue** | **Cause / Resolution** |
| --- | --- |
| The agent returns a formatting or syntax error. | The description may be ambiguous. Rephrase the request, or ask the agent to try again over additional turns. |
| The agent cannot find a referenced service or add-on. | A typo or an unrecognized name was used. Reference the entity by its exact name or code. Having a code set is strongly recommended. |
| A saved rule does not behave as expected. | The AI-generated rule may be incorrect. Retest in validation mode with a mock order and refine the description. |

## Limitations {#h_ad51476233}

-   Rules validate input on save. They do not lock fields or limit which options appear in the order form.
-   Rules generated by AI can still be incorrect, so thorough validation is essential.


## Related articles

- [Video: Chat-based validation rules (Qargo Intelligence)](https://help.qargo.com/us/articles/709280-video-chat-based-validation-rules-qargo-intelligence.md)
- [Qargo Intelligence: Assign fields tasks — what, why & how](https://help.qargo.com/us/articles/843273-qargo-intelligence-assign-fields-tasks-what-why-how.md)
- [Configuration - Use rules to auto-assign fields.](https://help.qargo.com/us/articles/545498-configuration-use-rules-to-auto-assign-fields.md)
- [Qi: validation tasks](https://help.qargo.com/us/articles/413235-qi-validation-tasks.md)
- [Integrations – Qargo API – What, why & how](https://help.qargo.com/us/articles/865547-integrations-qargo-api-what-why-how.md)
