> For the complete documentation index, see [llms.txt](https://apidocs.cloudinvoice.net/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://apidocs.cloudinvoice.net/documentacao-api/documentos/list.md).

# List

## Lista de Documentos

## Fornece uma Lista dos Documentos existentes.

<mark style="color:blue;">`GET`</mark> `https://api.cloudinvoice.net/documents/`

#### Query Parameters

| Name             | Type    | Description                                                                                                                                                                                                                     |
| ---------------- | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| limit            | integer | Define o número de documentos por pesquisa.                                                                                                                                                                                     |
| offset           | integer | Indica a posição inicial da pesquisa. Retorna a lista de documentos compreendida entre offset:offset+limit.                                                                                                                     |
| ordering         | string  | <p>Define o campo e a direcção a usar na pesquisa de documentos. </p><p></p><p>Campos ordenáveis: id, doc\_key, document\_date, document\_time. Para ordenar de forma descendente, deve usar o sinal de '-' antes do campo.</p> |
| search           | string  | <p>Define o termo de pesquisa a utilizar na lista de documentos. </p><p></p><p>Campos Pesquisados: Id, Chave do Documento, Data do Documento.</p>                                                                               |
| document\_nature | integer | <p>Natureza do Documento</p><p></p><p>Consulte a tabela <a href="/pages/Le16rQ3NG33zktn1PTI4#naturezas-de-documentos-campo-document_nature">Apêndice</a> para mais informação</p>                                               |
| document\_status | integer | <p>Estado do Documento</p><p></p><p>Consulte a tabela <a href="/pages/Le16rQ3NG33zktn1PTI4#estados-dos-documentos-campo-document_status">Apêndice</a> para mais informação</p>                                                  |

{% tabs %}
{% tab title="Exemplo de Pedido" %}

```shell
curl https://api.cloudinvoice.net/documents/
    -H "Content-Type: application/json"
```

{% endtab %}

{% tab title="Exemplo de Resposta" %}

```json
{
    "limit": 10,
    "offset": 0,
    "count": 3279,
    "next": "https://api.cloudinvoice.net/documents/?limit=10&offset=10",
    "previous": null,
    "results":[
        {
            "id": 1,
            "doc_key": "FSI A01/1",
            "document_date": "2023-01-10",
            "document_time": "11:30:48.700759",
            "document_number": 1,
            "our_reference": "",
            "is_valued": true,
            "total_amount": 54.9,
            "total_due_amount": 0.0,
            "due_date": "2023-01-10",
            "document_id": 2,
            "document": {
                "code": "FSI", 
                "document_name": "Factura Simplificada"
            },
            "document_serie_id": 1,
            "document_serie": {
                "code": "A01", 
                "description": "Série A01"
            },
            "document_status_id": 1202,
            "document_status": {
                "code": "F", 
                "description": "Finalizado"
            },
            "warehouse_id": 1,
            "warehouse": {
                "code": 1, 
                "description": "Armazém 1"
            },
            "document_nature_id": 302,
            "document_nature": {
                "code": "FS", 
                "description": "Factura Simplificada"
            },
            "party_id": 1,
            "party": {
                "class": 1601, 
                "code": 1, 
                "name": "Consumidor Final", 
                "fiscal_number": "999999990"
            }
        },
        ...
    ]
}
```

{% endtab %}
{% endtabs %}

Para ver exemplos de pedidos nas várias linguagens, consulte a página[ Exemplos de Pedidos.](/introducao/exemplos-de-pedidos.md)

{% hint style="info" %}
**Notas:** Alguns dos campos do termo de pesquisa geral poderão ser incluídos mediante critérios específicos (Ex: Descrição será incluída na pesquisa geral apenas se o termo de pesquisa contiver 3 ou mais caracteres). Por defeito, o comportamento expectável será obter-se todos os items cujo o texto a pesquisar (search) esteja CONTIDO em pelo menos um dos campos incluídos na pesquisa geral.
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://apidocs.cloudinvoice.net/documentacao-api/documentos/list.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
