# How to assign documents to a product when it is created

Create a business rule with a "product is created"-[trigger](/reference/settings/data-governance/business-rules/business-rule-details/triggers/trigger-details.md).  Then set up [conditions](/reference/settings/data-governance/business-rules/business-rule-details/conditions/condition-details.md) that will check what kind of documents that should be attached.\
\
In this example the [attribute](/fundamental-concepts/workflows-and-automation.md) "Article" is checked.&#x20;

<figure><img src="/files/kwiJnMpFKTlmLTo2prUF" alt=""><figcaption><p>Business rule trigger</p></figcaption></figure>

If the [attribute](/fundamental-concepts/workflows-and-automation.md) is a type we know needs a document attached we can update that document using the "Update attribute"-action.\
\
In this case the Documents [attribute](/fundamental-concepts/workflows-and-automation.md) is updated.

<figure><img src="/files/zgOCqe5M1xWK4JDmiAYU" alt=""><figcaption></figcaption></figure>

The "else"-case is left empty so if future products that does not fit into the other [conditions](/reference/settings/data-governance/business-rules/business-rule-details/conditions/condition-details.md) are created they will not have documents attached to them.&#x20;


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.struct.com/tutorials/guides/how-to-use-business-rules/how-to-assign-documents-to-a-product-when-it-is-created.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
