whmcs-email-center-module/README.md

43 lines
2.8 KiB
Markdown

<p align="center"><img src="assets/logo.png" alt="MozOut" width="280"></p>
# MozOut WHMCS E-mail Center module
<!-- badges:start -->
[![Release](https://git.mozout.com/mozout-com/whmcs-email-center-module/badges/release.svg)](https://git.mozout.com/mozout-com/whmcs-email-center-module/releases) [![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)
<!-- badges:end -->
[Português](README-pt.md)
> API: `https://api.mozout.com`, built in. Create your key in the [API Center](https://www.my.mozout.com/api-center.php) of My MozOut. Documentation: https://docs.mozout.com
English | [Português](README-pt.md)
This module makes your WHMCS send every email (invoices, tickets, notices) through the E-mail Center API instead of SMTP.
## Install
1. Download `mozout_email_center.zip` from the [latest release](https://git.mozout.com/mozout-com/whmcs-email-center-module/releases/latest) and unzip it in the main folder of your WHMCS (the one with `configuration.php`). The files go straight to `modules/mail/mozout_email_center`. Do not use "Download ZIP" on the code page: it adds an extra folder and WHMCS will not find the module.
2. In WHMCS, open System Settings > General Settings > Mail > Configure Mail Provider and choose «E-mail Center (API)».
3. Choose the provider (MozOut) and paste the API key. Create the key on the API page of your account, with the `email_center:write` permission. In "Expected mode" choose Sandbox or Production: the key is refused if it is in the other mode.
4. Click «Test». The module checks the key and the account and sends a test email. With a `sandbox_` key the email is simulated and does not really go out.
## Before you start
- E-mail Center must be active on your account.
- The sender must be at a domain verified in E-mail Center. If the WHMCS sender is not, type a verified address in «Sender»: replies still go to the WHMCS address.
## When sending fails
The error shows in Utilities > Logs > Email Message Log, with the reason and the request reference (for example: no credits, monthly limit, domain not verified, revoked key). Requests and answers, without the key and without the email bodies, go to the Module Log.
## Languages (lang/)
The code holds the English texts only. The screen texts and error messages are in `lang/english.php` and `lang/portuguese.php`, arrays where the key is the English text. The settings screen follows the administrator's language; any WHMCS language whose name starts with «portuguese» (portuguese-pt, portuguese-br, ...) uses `portuguese.php`, the rest `english.php`. The «Error language» setting chooses the language of the messages in the email log. A text missing from a file falls back to English.
Requirements: WHMCS 8, PHP 7.4 or 8.x with cURL.
---
Maintained by RLX Holdings.