> For the complete documentation index, see [llms.txt](https://overleaf-pro.ayaka.space/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://overleaf-pro.ayaka.space/on-premises/pt/configuracao/overleaf-toolkit/email-delivery.md).

# Entrega de e-mails

O Overleaf suporta o envio de emails através de dois métodos: Simple Mail Transfer Protocol (SMTP) e [Amazon Simple Email Service (SES)](https://aws.amazon.com/ses/). O SMTP pode ser usado se tiver um servidor de email ativado no seu localhost que esteja a escutar ligações locais.

## Configuração

O email é configurado utilizando as seguintes variáveis de ambiente.

#### Configuração do remetente

| Nome                          | Descrição                                                                                                                                                         |
| ----------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `OVERLEAF_EMAIL_FROM_ADDRESS` | <p>O endereço de origem, por ex. <a href="mailto:support@mycompany.com"><code>'<support@mycompany.com>'</code></a><br><br>- <strong>Obrigatório</strong>: sim</p> |
| `OVERLEAF_EMAIL_REPLY_TO`     | O endereço de resposta, por ex. `'noreply@mycompany.com'`                                                                                                         |

#### SMTP

| Nome                                    | Descrição                                                                                                                                                                                                                                                                                     |
| --------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `OVERLEAF_EMAIL_SMTP_HOST`              | O nome de anfitrião ou endereço IP ao qual se ligar. Tem de estar acessível a partir do contentor Docker                                                                                                                                                                                      |
| `OVERLEAF_EMAIL_SMTP_PORT`              | A porta à qual se ligar                                                                                                                                                                                                                                                                       |
| `OVERLEAF_EMAIL_SMTP_SECURE`            | Se `true` a ligação usará TLS ao ligar ao servidor. Se `false` ou não estiver definido, então o TLS é usado se o servidor suportar a `STARTTLS` extensão. Na maioria dos casos, defina este valor como `true` se estiver a ligar à porta `465`. Para a porta `587` ou `25` mantenha-o `false` |
| `OVERLEAF_EMAIL_SMTP_USER`              | O nome de utilizador que deve ser usado para autenticação no servidor SMTP                                                                                                                                                                                                                    |
| `OVERLEAF_EMAIL_SMTP_PASS`              | A palavra-passe associada ao nome de utilizador SMTP                                                                                                                                                                                                                                          |
| `OVERLEAF_EMAIL_SMTP_TLS_REJECT_UNAUTH` | Se `false` isto abriria uma ligação a um servidor TLS com um certificado TLS autoassinado ou inválido                                                                                                                                                                                         |
| `OVERLEAF_EMAIL_SMTP_IGNORE_TLS`        | Quando `true` e `OVERLEAF_EMAIL_SMTP_SECURE` é `false` então o TLS não é usado mesmo que o servidor suporte a `STARTTLS` extensão                                                                                                                                                             |
| `OVERLEAF_EMAIL_SMTP_NAME`              | Nome de anfitrião opcional para validação TLS se `OVERLEAF_EMAIL_SMTP_HOST` foi definido para um endereço IP, o padrão é o nome de anfitrião da máquina.                                                                                                                                      |
| `OVERLEAF_EMAIL_SMTP_LOGGER`            | Quando `true` imprime mensagens de registo para `web.log`.                                                                                                                                                                                                                                    |

#### Interface SMTP do Amazon SES

Pode ler mais sobre como usar a interface SMTP do Amazon SES para enviar emails [aqui](https://docs.aws.amazon.com/ses/latest/dg/send-email-smtp.html).

| Nome                       | Descrição                                                                                                |
| -------------------------- | -------------------------------------------------------------------------------------------------------- |
| `OVERLEAF_EMAIL_SMTP_HOST` | O nome de anfitrião ou endereço IP ao qual se ligar. Tem de estar acessível a partir do contentor Docker |
| `OVERLEAF_EMAIL_SMTP_PORT` | A porta à qual se ligar                                                                                  |
| `OVERLEAF_EMAIL_SMTP_USER` | O nome de utilizador que deve ser usado para autenticação no servidor SMTP                               |
| `OVERLEAF_EMAIL_SMTP_PASS` | A palavra-passe associada ao nome de utilizador SMTP                                                     |

#### API do Amazon SES

Pode ler mais sobre como usar a API do Amazon SES para enviar emails [aqui](https://docs.aws.amazon.com/ses/latest/dg/send-email-api.html).

| Nome                                   | Descrição                                                 |
| -------------------------------------- | --------------------------------------------------------- |
| `OVERLEAF_EMAIL_AWS_SES_ACCESS_KEY_ID` | Se estiver a usar o AWS SES, a chave de acesso            |
| `OVERLEAF_EMAIL_AWS_SES_SECRET_KEY`    | Se estiver a usar o AWS SES, a chave secreta              |
| `OVERLEAF_EMAIL_AWS_SES_REGION`        | Se não estiver definido, a região predefinida é US-EAST-1 |

#### AWS SES com funções de instância

| Nome                    | Descrição                                                                                                                                                  |
| ----------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `OVERLEAF_EMAIL_DRIVER` | Quando isto estiver definido como `ses`, o sistema de email usará o método da API SES e confiará nas funções de instância configuradas para enviar emails. |

#### Personalização

| Nome                           | Descrição                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| ------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `OVERLEAF_CUSTOM_EMAIL_FOOTER` | <p>HTML personalizado que é acrescentado a todos os emails. por ex.<br><br><strong>Exemplo</strong>: <code>"\<div>Este sistema é gerido pelo departamento x \</div> \<div> Se tiver alguma questão, consulte a nossa FAQ \<a href='</code><a href="https://docs.overleaf.com/on-premises/configuration/overleaf-toolkit/https:/somwhere.com&#x27;%3Ehere&#x26;#x3C;/a%3E&#x26;#x3C;/div%3E"><code>[https://somwhere.com'>aqui\&#x26;#x3C;/a>\&#x26;#x3C;/div>](https://overleaf-pro.ayaka.space/on-premises/pt/configuracao/overleaf-toolkit/https:/somwhere.com'>aqui\&#x26;#x3C;/a>\&#x26;#x3C;/div>)</code></a><code>"</code></p> |


---

# 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://overleaf-pro.ayaka.space/on-premises/pt/configuracao/overleaf-toolkit/email-delivery.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.
