# Cadastrando Departamentos

Para este exemplo iremos criar uma estrutura de departamentos com a seguinte disposição:

> * Informática
>   * Notebook
>   * Desktop

Antes iremos criar o departamento "**Pai**" chamado "**Informática**", para isto, clique em "**Produtos -> Departamentos"** e após clique em "**Cadastrar**":

![](https://3873222052-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8H19OxR4N0phXKpriO%2F-M8gTa3jkMtYsewhXsfy%2F-M8gVBjW_N98asrg4MuJ%2F2020-05-31_17h51_12.png?alt=media\&token=9810163a-d2e8-4eb2-9ad4-14aaf168959b)

No campo "**Departamento Pai**" selecione "**Departamento Raiz**", isto indica ao sistema que este é o departamento principal.

No campo campo "**Nome**" preencha com "**Informática**":

![](https://3873222052-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8H19OxR4N0phXKpriO%2F-M8gTa3jkMtYsewhXsfy%2F-M8gVvsYTRQ5ryl_4Yib%2F2020-05-31_17h53_55.png?alt=media\&token=b7088150-7775-4b13-82e7-25473eea493f)

Clique em "**Cadastrar Departamento**" no final da página.

Agora já temos o departamento principal, iremos criar os **dois sub-departamentos**.

Acesse o cadastro de departamentos, no campo "**Departamento Pai**" selecione "**Informática**" e no campo "**Nome**" preencha com "**Notebook**":

![](https://3873222052-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8H19OxR4N0phXKpriO%2F-M8gTa3jkMtYsewhXsfy%2F-M8gWHWGVuutXXxltFyM%2F2020-05-31_17h55_54.png?alt=media\&token=8e5a7446-73d8-451b-9349-ec516a8107e0)

Faça a mesma coisa para o sub-departamento "**Desktop**":

![](https://3873222052-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8H19OxR4N0phXKpriO%2F-M8gTa3jkMtYsewhXsfy%2F-M8gWRsfQOdnihXlbndE%2F2020-05-31_17h56_39.png?alt=media\&token=8058f80d-ad39-46fa-90a0-5f3651d3e8e7)

**Pronto!** Criamos um departamento principal e dois sub-departamentos.

**Vamos ver como fica no site:**

![](https://3873222052-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M8H19OxR4N0phXKpriO%2F-M8gTa3jkMtYsewhXsfy%2F-M8gWhBOU9xUXMpwX1XG%2F2020-05-31_17h57_33.png?alt=media\&token=32e714b5-9ea2-4b7f-868a-8db0046df0c1)


---

# 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://ajuda.toplojas.com.br/departamentos/cadastrando-departamento.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.
