abraflexi-mailer

abraflexi-mailer

External mailer for Abra Flexi

desktop applicationUtility
Install
apt install abraflexi-mailer
Description

Send AbraFlexi documents and its attachments via email Add Mailer's applications into MultiFlexi

๐ŸŒ Homepage๐Ÿ› Issues๐Ÿ“‹ Package details

License: MIT Packaging: deb

Document Sender for AbraFlexi

Package Logo

Scripts for sending documents are available:

SendUnsent.php - sends unsent documents in bulk directly from AbraFlexi in the standard way

SendUnsentAttachments.php - finds unsent documents, attaches attachments to them, and sends them via the default PHP mailer or SMTP

Documents are sent to addresses according to the following key:

  1. "contactEmail" from the document
  2. company email
  3. primary contact email
  4. contact email

If an address with the prefix cc is found in the document note, e.g., "cc:email@example.com, cc:copy@example.com", a copy will also be sent to these emails.

Configuration

Configuration is done by entering directives into the .env file, defining them as constants, or setting environment variables. The Debian package expects the configuration file in the /etc/abraflexi-mailer folder, where a sample file .env.template is available.

Mail Transport (MAIL_DSN)

The mailer now uses the MAIL_DSN variable, following the Symfony mailer DSN format. The previously used EASE_SMTP is deprecated.

Example for SMTP:

MAIL_DSN="smtp://username:password@mail.example.com:587?encryption=tls&auth_mode=plain"

Replace username, password, and mail.example.com with your actual SMTP credentials and server.

APP_NAME=AbraFlexiMailer                        - application name in syslog
APP_DEBUG=true                                  - enable debug mode
MUTE=true                                       - do not send messages to recipients but to

MAIL_DSN="smtp://username:password@mail.example.com:587?encryption=tls&auth_mode=plain"  - mail transport DSN (Symfony format)
EASE_MAILTO=info@vitexsoftware.cz               - messages are sent here if mute is active

ABRAFLEXI_URL="https://demo.abraflexi.eu:5434"
ABRAFLEXI_LOGIN="winstrom"
ABRAFLEXI_PASSWORD="winstrom"
ABRAFLEXI_COMPANY="demo"
ABRAFLEXI_CUSTOMER="demo"

ADD_LOGO=true                                   - include company logo in the email
ADD_QRCODE=true                                 - include QR payment image in the email
MAIL_CC=info@vitexsoftware.cz                   - send all emails also in copy to this address
MAIL_FROM=office@vitexsoftware.cz               - sender address

EASE_LOGGER="console|syslog"                    - logging method
SEND_LOCKED=False                               - try to temporarily unlock a locked document
DRY_RUN=False                                   - if enabled, does not write the date and sending status to documents

Templates

It is assumed that the template is named according to the record type, e.g., invoice-issued.ftl and is stored in the "templates" folder ( /usr/share/abraflexi-mailer/templates in Debian )

The following variables can be used in the templates:

  • ${application} โ€“ Application name, i.e., "AbraFlexi BulkMail"
  • ${user} โ€“ User object, which can be further worked with
  • ${company} โ€“ Company settings
  • ${uzivatelJmeno} โ€“ Your first name
  • ${uzivatelPrijmeni} โ€“ Your last name
  • ${titulJmenoPrijmeni} โ€“ Your full name, including achieved titles
  • ${nazevFirmy} โ€“ Company name
  • ${doklad} โ€“ Document to be sent

Bulk Mailer

If we want to send emails to all clients from Nerudova Street in Prague:

abraflexi-bulkmail templates/template.ftl "(city='Prague' AND street='Nerudova')"

When used in a template, the variables for each sent message are filled from https://demo.flexibee.eu/c/demo_de/addressbook/properties

Dependencies

This tool uses the following libraries for its functionality:

Acknowledgements

This software would not have been created without the support of:

Spoje.Net

Other software for AbraFlexi

MultiFlexi

AbraFlexi Mailer is ready to run as a MultiFlexi application. See the full list of ready-to-run applications within the MultiFlexi platform on the application list page.

Since version 1.3.8, all produced reports conform to the MultiFlexi report schema, ensuring proper integration and monitoring capabilities within the MultiFlexi ecosystem.

MultiFlexi App

Debian/Ubuntu

For Linux, .deb packages are available. Please use the repo:

    echo "deb http://repo.vitexsoftware.com $(lsb_release -sc) main" | sudo tee /etc/apt/sources.list.d/vitexsoftware.list
    sudo wget -O /etc/apt/trusted.gpg.d/vitexsoftware.gpg http://repo.vitexsoftware.cz/keyring.gpg
    sudo apt update
    sudo apt install abraflexi-mailer

After installing the package, the following new commands are available in the system:

  • abraflexi-send - sends a document
  • abraflexi-send-unsent - sends unsent documents
  • abraflexi-send-attachments - sends a document with attachments (TODO)
  • abraflexi-send-unsent-attachments - sends unsent documents with attachments
  • abraflexi-show-unsent - lists unsent documents
  • abraflexi-bulkmail - sends emails to contacts from the address book in bulk
  • abraflexi-potvrzeni-prijeti-uhrady - sends payment receipt confirmation to the customer
  • abraflexi-potvrzeni-prijeti-faktury - sends invoice receipt confirmation to the supplier
  • abraflexi-potvrzeni-odeslani-uhrady - sends payment sent (bank order) confirmation to the supplier

Confirmation Commands

The confirmation commands accept a document identifier via --docid parameter or DOCID environment variable. Based on the document ID, the recipient is determined from the address book and a confirmation email is sent.

abraflexi-potvrzeni-prijeti-uhrady --docid=VF1-0001/2026
DOCID=123 abraflexi-potvrzeni-prijeti-faktury

Additional environment variables for confirmations:

  • MAIL_SIGNATURE - email signature text appended to the message
  • SEND_INFO_TO - Cc address for confirmation copies

Exit Codes

This application uses the following exit codes:

  • 0: Success
  • 1: General error / Missing document ID
  • 2: Failed to send email
  • 3: Cannot read document from AbraFlexi
abraflexi-mailer

abraflexi-mailer 0.1

 pool/bionic/main/a/abraflexi-mailer/abraflexi-mailer_0.1_all.deb abraflexi-mailer
External mailer for Abra Flexi
Filename pool/bionic/main/a/abraflexi-mailer/abraflexi-mailer_0.1_all.deb
Version0.1
Age in days1933
Release date2021 06. 29.
Size6.82 KB
id855
Nameabraflexi-mailer
Package
Appname
Essential
Vendor
License
Distributionbionic
Suitemain
Source
Architecturebinary-i386
MultiArch
MaintainerVรญtฤ›zslav Dvoล™รกk
InstalledSize48
Dependsdebconf (>= 0.5) , debconf-2.0 , php-vitexsoftware-abraflexi-bricks , php-cli
PreDepends
Breaks
Enhances
Replacesflexibee-mailer
Sectionweb
Priorityoptional
DescriptionExternal mailer for Abra Flexi
LongDescriptionSend AbraFlexi documents and its attachments via email
AutoBuiltPackage
Filenamepool/bionic/main/a/abraflexi-mailer/abraflexi-mailer_0.1_all.deb
MD5sum2682133acf53d1c7bb5755a12875f3ab
SHA1a1cf6ce5553592388e853b15ab865cd80159cbdd
SHA256a79eb1414f56f641e537f2124cbdcd8bb498bfd9c3723f1a0242e132af166ca2
SHA512b5516083ad8f1fdec6211a01f6f890db90d14f7a149bdbbc2c1460d878e645d6bce32de1df6adc5b887d1239366f6fa6288e99878b1cdf03320f414402cb3d7f
Size6988
Auto-Built-Package
Homepagehttps://github.com/VitexSoftware/php-abraflexi-mailer
Provides
Suggestsabraflexi-server , php-abraflexi-config
Existing
fileMtime2021-06-29 23:07:46
created2021-05-07 13:25:42
updated2021-06-29 23:07:46
./
./etc/
./etc/abraflexi-mailer/
./etc/abraflexi-mailer/.env.template366
./usr/
./usr/bin/
./usr/bin/abraflexi-send73
./usr/bin/abraflexi-send-unsent60
./usr/bin/abraflexi-send-unsent-with-attachments71
./usr/bin/abraflexi-show-unsent62
./usr/lib/
./usr/lib/abraflexi-mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Mailer.php6821
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Templater.php4193
./usr/lib/abraflexi-mailer/SendDocument.php2058
./usr/lib/abraflexi-mailer/SendUnsent.php579
./usr/lib/abraflexi-mailer/SendUnsentAttachments.php1800
./usr/lib/abraflexi-mailer/ShowUnsent.php1030
./usr/lib/abraflexi-mailer/composer.json1102
./usr/share/
./usr/share/doc/
./usr/share/doc/abraflexi-mailer/
./usr/share/doc/abraflexi-mailer/changelog.gz174
./usr/share/doc/abraflexi-mailer/copyright495
./
./etc/
./etc/abraflexi-mailer/
./etc/abraflexi-mailer/.env.template366
./usr/
./usr/bin/
./usr/bin/abraflexi-send73
./usr/bin/abraflexi-send-unsent60
./usr/bin/abraflexi-send-unsent-with-attachments71
./usr/bin/abraflexi-show-unsent62
./usr/lib/
./usr/lib/abraflexi-mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Mailer.php6821
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Templater.php4193
./usr/lib/abraflexi-mailer/SendDocument.php2058
./usr/lib/abraflexi-mailer/SendUnsent.php579
./usr/lib/abraflexi-mailer/SendUnsentAttachments.php1800
./usr/lib/abraflexi-mailer/ShowUnsent.php1030
./usr/lib/abraflexi-mailer/composer.json1102
./usr/share/
./usr/share/doc/
./usr/share/doc/abraflexi-mailer/
./usr/share/doc/abraflexi-mailer/changelog.gz174
./usr/share/doc/abraflexi-mailer/copyright495
./
./etc/
./etc/abraflexi-mailer/
./etc/abraflexi-mailer/.env.template366
./usr/
./usr/bin/
./usr/bin/abraflexi-send73
./usr/bin/abraflexi-send-unsent60
./usr/bin/abraflexi-send-unsent-with-attachments71
./usr/bin/abraflexi-show-unsent62
./usr/lib/
./usr/lib/abraflexi-mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Mailer.php6821
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Templater.php4193
./usr/lib/abraflexi-mailer/SendDocument.php2058
./usr/lib/abraflexi-mailer/SendUnsent.php579
./usr/lib/abraflexi-mailer/SendUnsentAttachments.php1800
./usr/lib/abraflexi-mailer/ShowUnsent.php1030
./usr/lib/abraflexi-mailer/composer.json1102
./usr/share/
./usr/share/doc/
./usr/share/doc/abraflexi-mailer/
./usr/share/doc/abraflexi-mailer/changelog.gz174
./usr/share/doc/abraflexi-mailer/copyright495
./
./etc/
./etc/abraflexi-mailer/
./etc/abraflexi-mailer/.env.template366
./usr/
./usr/bin/
./usr/bin/abraflexi-send73
./usr/bin/abraflexi-send-unsent60
./usr/bin/abraflexi-send-unsent-with-attachments71
./usr/bin/abraflexi-show-unsent62
./usr/lib/
./usr/lib/abraflexi-mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Mailer.php6821
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Templater.php4193
./usr/lib/abraflexi-mailer/SendDocument.php2058
./usr/lib/abraflexi-mailer/SendUnsent.php579
./usr/lib/abraflexi-mailer/SendUnsentAttachments.php1800
./usr/lib/abraflexi-mailer/ShowUnsent.php1030
./usr/lib/abraflexi-mailer/composer.json1102
./usr/share/
./usr/share/doc/
./usr/share/doc/abraflexi-mailer/
./usr/share/doc/abraflexi-mailer/changelog.gz174
./usr/share/doc/abraflexi-mailer/copyright495
./
./etc/
./etc/abraflexi-mailer/
./etc/abraflexi-mailer/.env.template366
./usr/
./usr/bin/
./usr/bin/abraflexi-send73
./usr/bin/abraflexi-send-unsent60
./usr/bin/abraflexi-send-unsent-with-attachments71
./usr/bin/abraflexi-show-unsent62
./usr/lib/
./usr/lib/abraflexi-mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Mailer.php6821
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Templater.php4193
./usr/lib/abraflexi-mailer/SendDocument.php2058
./usr/lib/abraflexi-mailer/SendUnsent.php579
./usr/lib/abraflexi-mailer/SendUnsentAttachments.php1800
./usr/lib/abraflexi-mailer/ShowUnsent.php1030
./usr/lib/abraflexi-mailer/composer.json1102
./usr/share/
./usr/share/doc/
./usr/share/doc/abraflexi-mailer/
./usr/share/doc/abraflexi-mailer/changelog.gz174
./usr/share/doc/abraflexi-mailer/copyright495
./
./usr/
./usr/bin/
./usr/bin/abraflexi-bulkmail63
./usr/bin/abraflexi-send67
./usr/bin/abraflexi-send-unsent64
./usr/bin/abraflexi-send-unsent-with-attachments78
./usr/bin/abraflexi-show-unsent64
./usr/lib/
./usr/lib/abraflexi-mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Body.php509
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/DocumentMailer.php11670
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Templater.php7426
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/mailbody.php446
./usr/lib/abraflexi-mailer/AbraFlexi/SablonaMail.php622
./usr/lib/abraflexi-mailer/BulkMail.php2406
./usr/lib/abraflexi-mailer/SendDocument.php2573
./usr/lib/abraflexi-mailer/SendUnsent.php962
./usr/lib/abraflexi-mailer/SendUnsentWithAttachments.php4255
./usr/lib/abraflexi-mailer/ShowUnsent.php2134
./usr/lib/abraflexi-mailer/composer.json1047
./usr/share/
./usr/share/doc/
./usr/share/doc/abraflexi-mailer/
./usr/share/doc/abraflexi-mailer/.env.template384
./usr/share/doc/abraflexi-mailer/changelog.gz473
./usr/share/doc/abraflexi-mailer/copyright495
./usr/share/locale/
./usr/share/locale/cs_CZ/
./usr/share/locale/cs_CZ/LC_MESSAGES/
./usr/share/locale/cs_CZ/LC_MESSAGES/abraflexi-mailer.mo1769
./usr/share/locale/en_US/
./usr/share/locale/en_US/LC_MESSAGES/
./usr/share/locale/en_US/LC_MESSAGES/abraflexi-mailer.mo1686
./
./usr/
./usr/bin/
./usr/bin/abraflexi-bulkmail63
./usr/bin/abraflexi-send67
./usr/bin/abraflexi-send-unsent64
./usr/bin/abraflexi-send-unsent-with-attachments78
./usr/bin/abraflexi-show-unsent64
./usr/lib/
./usr/lib/abraflexi-mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Body.php509
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/DocumentMailer.php11670
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Templater.php7426
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/mailbody.php446
./usr/lib/abraflexi-mailer/AbraFlexi/SablonaMail.php622
./usr/lib/abraflexi-mailer/BulkMail.php2406
./usr/lib/abraflexi-mailer/SendDocument.php2573
./usr/lib/abraflexi-mailer/SendUnsent.php962
./usr/lib/abraflexi-mailer/SendUnsentWithAttachments.php4255
./usr/lib/abraflexi-mailer/ShowUnsent.php2134
./usr/lib/abraflexi-mailer/composer.json1047
./usr/share/
./usr/share/doc/
./usr/share/doc/abraflexi-mailer/
./usr/share/doc/abraflexi-mailer/.env.template384
./usr/share/doc/abraflexi-mailer/changelog.gz469
./usr/share/doc/abraflexi-mailer/copyright495
./usr/share/locale/
./usr/share/locale/cs_CZ/
./usr/share/locale/cs_CZ/LC_MESSAGES/
./usr/share/locale/cs_CZ/LC_MESSAGES/abraflexi-mailer.mo1769
./usr/share/locale/en_US/
./usr/share/locale/en_US/LC_MESSAGES/
./usr/share/locale/en_US/LC_MESSAGES/abraflexi-mailer.mo1686
./
./usr/
./usr/bin/
./usr/bin/abraflexi-bulkmail63
./usr/bin/abraflexi-send67
./usr/bin/abraflexi-send-unsent64
./usr/bin/abraflexi-send-unsent-with-attachments78
./usr/bin/abraflexi-show-unsent64
./usr/lib/
./usr/lib/abraflexi-mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Body.php509
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/DocumentMailer.php11670
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Templater.php7426
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/mailbody.php446
./usr/lib/abraflexi-mailer/AbraFlexi/SablonaMail.php622
./usr/lib/abraflexi-mailer/BulkMail.php2406
./usr/lib/abraflexi-mailer/SendDocument.php2573
./usr/lib/abraflexi-mailer/SendUnsent.php962
./usr/lib/abraflexi-mailer/SendUnsentWithAttachments.php4255
./usr/lib/abraflexi-mailer/ShowUnsent.php2134
./usr/lib/abraflexi-mailer/composer.json1047
./usr/share/
./usr/share/doc/
./usr/share/doc/abraflexi-mailer/
./usr/share/doc/abraflexi-mailer/.env.template384
./usr/share/doc/abraflexi-mailer/changelog.gz472
./usr/share/doc/abraflexi-mailer/copyright495
./usr/share/locale/
./usr/share/locale/cs_CZ/
./usr/share/locale/cs_CZ/LC_MESSAGES/
./usr/share/locale/cs_CZ/LC_MESSAGES/abraflexi-mailer.mo1769
./usr/share/locale/en_US/
./usr/share/locale/en_US/LC_MESSAGES/
./usr/share/locale/en_US/LC_MESSAGES/abraflexi-mailer.mo1686
./
./usr/
./usr/bin/
./usr/bin/abraflexi-bulkmail63
./usr/bin/abraflexi-send67
./usr/bin/abraflexi-send-unsent64
./usr/bin/abraflexi-send-unsent-with-attachments78
./usr/bin/abraflexi-show-unsent64
./usr/lib/
./usr/lib/abraflexi-mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Body.php509
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/DocumentMailer.php11670
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Templater.php7426
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/mailbody.php446
./usr/lib/abraflexi-mailer/AbraFlexi/SablonaMail.php622
./usr/lib/abraflexi-mailer/BulkMail.php2406
./usr/lib/abraflexi-mailer/SendDocument.php2573
./usr/lib/abraflexi-mailer/SendUnsent.php962
./usr/lib/abraflexi-mailer/SendUnsentWithAttachments.php4255
./usr/lib/abraflexi-mailer/ShowUnsent.php2134
./usr/lib/abraflexi-mailer/composer.json1047
./usr/share/
./usr/share/doc/
./usr/share/doc/abraflexi-mailer/
./usr/share/doc/abraflexi-mailer/.env.template384
./usr/share/doc/abraflexi-mailer/changelog.gz471
./usr/share/doc/abraflexi-mailer/copyright495
./usr/share/locale/
./usr/share/locale/cs_CZ/
./usr/share/locale/cs_CZ/LC_MESSAGES/
./usr/share/locale/cs_CZ/LC_MESSAGES/abraflexi-mailer.mo1769
./usr/share/locale/en_US/
./usr/share/locale/en_US/LC_MESSAGES/
./usr/share/locale/en_US/LC_MESSAGES/abraflexi-mailer.mo1686
./
./usr/
./usr/bin/
./usr/bin/abraflexi-bulkmail63
./usr/bin/abraflexi-send67
./usr/bin/abraflexi-send-unsent64
./usr/bin/abraflexi-send-unsent-with-attachments78
./usr/bin/abraflexi-show-unsent64
./usr/lib/
./usr/lib/abraflexi-mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Body.php509
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/DocumentMailer.php11670
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Templater.php7426
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/mailbody.php446
./usr/lib/abraflexi-mailer/AbraFlexi/SablonaMail.php622
./usr/lib/abraflexi-mailer/BulkMail.php2406
./usr/lib/abraflexi-mailer/SendDocument.php2573
./usr/lib/abraflexi-mailer/SendUnsent.php962
./usr/lib/abraflexi-mailer/SendUnsentWithAttachments.php4255
./usr/lib/abraflexi-mailer/ShowUnsent.php2134
./usr/lib/abraflexi-mailer/composer.json1047
./usr/share/
./usr/share/doc/
./usr/share/doc/abraflexi-mailer/
./usr/share/doc/abraflexi-mailer/.env.template384
./usr/share/doc/abraflexi-mailer/changelog.gz470
./usr/share/doc/abraflexi-mailer/copyright495
./usr/share/locale/
./usr/share/locale/cs_CZ/
./usr/share/locale/cs_CZ/LC_MESSAGES/
./usr/share/locale/cs_CZ/LC_MESSAGES/abraflexi-mailer.mo1769
./usr/share/locale/en_US/
./usr/share/locale/en_US/LC_MESSAGES/
./usr/share/locale/en_US/LC_MESSAGES/abraflexi-mailer.mo1686
./
./usr/
./usr/bin/
./usr/bin/abraflexi-bulkmail63
./usr/bin/abraflexi-send67
./usr/bin/abraflexi-send-unsent64
./usr/bin/abraflexi-send-unsent-with-attachments78
./usr/bin/abraflexi-show-unsent64
./usr/lib/
./usr/lib/abraflexi-mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Body.php509
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/DocumentMailer.php11670
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Templater.php7426
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/mailbody.php446
./usr/lib/abraflexi-mailer/AbraFlexi/SablonaMail.php622
./usr/lib/abraflexi-mailer/BulkMail.php2406
./usr/lib/abraflexi-mailer/SendDocument.php2573
./usr/lib/abraflexi-mailer/SendUnsent.php962
./usr/lib/abraflexi-mailer/SendUnsentWithAttachments.php4255
./usr/lib/abraflexi-mailer/ShowUnsent.php2134
./usr/lib/abraflexi-mailer/composer.json1047
./usr/share/
./usr/share/doc/
./usr/share/doc/abraflexi-mailer/
./usr/share/doc/abraflexi-mailer/.env.template384
./usr/share/doc/abraflexi-mailer/changelog.gz471
./usr/share/doc/abraflexi-mailer/copyright495
./usr/share/locale/
./usr/share/locale/cs_CZ/
./usr/share/locale/cs_CZ/LC_MESSAGES/
./usr/share/locale/cs_CZ/LC_MESSAGES/abraflexi-mailer.mo1769
./usr/share/locale/en_US/
./usr/share/locale/en_US/LC_MESSAGES/
./usr/share/locale/en_US/LC_MESSAGES/abraflexi-mailer.mo1686
./
./usr/
./usr/bin/
./usr/bin/abraflexi-bulkmail63
./usr/bin/abraflexi-send67
./usr/bin/abraflexi-send-unsent64
./usr/bin/abraflexi-send-unsent-with-attachments78
./usr/bin/abraflexi-show-unsent64
./usr/lib/
./usr/lib/abraflexi-mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Body.php509
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/CompanyLogo.php2653
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/DocumentMailer.php11815
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Templater.php8114
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/mailbody.php446
./usr/lib/abraflexi-mailer/BulkMail.php2812
./usr/lib/abraflexi-mailer/SendDocument.php2573
./usr/lib/abraflexi-mailer/SendUnsent.php962
./usr/lib/abraflexi-mailer/SendUnsentWithAttachments.php4271
./usr/lib/abraflexi-mailer/ShowUnsent.php2134
./usr/lib/abraflexi-mailer/composer.json820
./usr/share/
./usr/share/doc/
./usr/share/doc/abraflexi-mailer/
./usr/share/doc/abraflexi-mailer/changelog.gz643
./usr/share/doc/abraflexi-mailer/copyright495
./usr/share/doc/abraflexi-mailer/example.env384
./usr/share/locale/
./usr/share/locale/cs_CZ/
./usr/share/locale/cs_CZ/LC_MESSAGES/
./usr/share/locale/cs_CZ/LC_MESSAGES/abraflexi-mailer.mo2611
./usr/share/locale/en_US/
./usr/share/locale/en_US/LC_MESSAGES/
./usr/share/locale/en_US/LC_MESSAGES/abraflexi-mailer.mo2493
./
./usr/
./usr/bin/
./usr/bin/abraflexi-bulkmail63
./usr/bin/abraflexi-send67
./usr/bin/abraflexi-send-unsent64
./usr/bin/abraflexi-send-unsent-with-attachments78
./usr/bin/abraflexi-show-unsent64
./usr/lib/
./usr/lib/abraflexi-mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Body.php509
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/DocumentMailer.php11834
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Templater.php8224
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/mailbody.php446
./usr/lib/abraflexi-mailer/AbraFlexi/SablonaMail.php622
./usr/lib/abraflexi-mailer/BulkMail.php2812
./usr/lib/abraflexi-mailer/SendDocument.php2573
./usr/lib/abraflexi-mailer/SendUnsent.php962
./usr/lib/abraflexi-mailer/SendUnsentWithAttachments.php4271
./usr/lib/abraflexi-mailer/ShowUnsent.php2134
./usr/lib/abraflexi-mailer/composer.json1047
./usr/share/
./usr/share/doc/
./usr/share/doc/abraflexi-mailer/
./usr/share/doc/abraflexi-mailer/.env.template384
./usr/share/doc/abraflexi-mailer/changelog.gz634
./usr/share/doc/abraflexi-mailer/copyright495
./usr/share/locale/
./usr/share/locale/cs_CZ/
./usr/share/locale/cs_CZ/LC_MESSAGES/
./usr/share/locale/cs_CZ/LC_MESSAGES/abraflexi-mailer.mo2364
./usr/share/locale/en_US/
./usr/share/locale/en_US/LC_MESSAGES/
./usr/share/locale/en_US/LC_MESSAGES/abraflexi-mailer.mo2245
./
./usr/
./usr/bin/
./usr/bin/abraflexi-bulkmail63
./usr/bin/abraflexi-send67
./usr/bin/abraflexi-send-unsent64
./usr/bin/abraflexi-send-unsent-with-attachments78
./usr/bin/abraflexi-show-unsent64
./usr/lib/
./usr/lib/abraflexi-mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Body.php509
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/CompanyLogo.php2653
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/DocumentMailer.php11815
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Templater.php8114
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/mailbody.php446
./usr/lib/abraflexi-mailer/BulkMail.php2812
./usr/lib/abraflexi-mailer/SendDocument.php2573
./usr/lib/abraflexi-mailer/SendUnsent.php962
./usr/lib/abraflexi-mailer/SendUnsentWithAttachments.php4271
./usr/lib/abraflexi-mailer/ShowUnsent.php2134
./usr/lib/abraflexi-mailer/composer.json820
./usr/share/
./usr/share/doc/
./usr/share/doc/abraflexi-mailer/
./usr/share/doc/abraflexi-mailer/changelog.gz645
./usr/share/doc/abraflexi-mailer/copyright495
./usr/share/doc/abraflexi-mailer/example.env384
./usr/share/locale/
./usr/share/locale/cs_CZ/
./usr/share/locale/cs_CZ/LC_MESSAGES/
./usr/share/locale/cs_CZ/LC_MESSAGES/abraflexi-mailer.mo2611
./usr/share/locale/en_US/
./usr/share/locale/en_US/LC_MESSAGES/
./usr/share/locale/en_US/LC_MESSAGES/abraflexi-mailer.mo2493
./
./usr/
./usr/bin/
./usr/bin/abraflexi-bulkmail63
./usr/bin/abraflexi-send67
./usr/bin/abraflexi-send-unsent64
./usr/bin/abraflexi-send-unsent-with-attachments78
./usr/bin/abraflexi-show-unsent64
./usr/lib/
./usr/lib/abraflexi-mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Body.php509
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/DocumentMailer.php11834
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Templater.php7740
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/mailbody.php446
./usr/lib/abraflexi-mailer/AbraFlexi/SablonaMail.php622
./usr/lib/abraflexi-mailer/BulkMail.php2812
./usr/lib/abraflexi-mailer/SendDocument.php2573
./usr/lib/abraflexi-mailer/SendUnsent.php962
./usr/lib/abraflexi-mailer/SendUnsentWithAttachments.php4271
./usr/lib/abraflexi-mailer/ShowUnsent.php2134
./usr/lib/abraflexi-mailer/composer.json1047
./usr/share/
./usr/share/doc/
./usr/share/doc/abraflexi-mailer/
./usr/share/doc/abraflexi-mailer/.env.template384
./usr/share/doc/abraflexi-mailer/changelog.gz550
./usr/share/doc/abraflexi-mailer/copyright495
./usr/share/locale/
./usr/share/locale/cs_CZ/
./usr/share/locale/cs_CZ/LC_MESSAGES/
./usr/share/locale/cs_CZ/LC_MESSAGES/abraflexi-mailer.mo2364
./usr/share/locale/en_US/
./usr/share/locale/en_US/LC_MESSAGES/
./usr/share/locale/en_US/LC_MESSAGES/abraflexi-mailer.mo2245
./
./usr/
./usr/bin/
./usr/bin/abraflexi-bulkmail63
./usr/bin/abraflexi-send67
./usr/bin/abraflexi-send-unsent64
./usr/bin/abraflexi-send-unsent-with-attachments78
./usr/bin/abraflexi-show-unsent64
./usr/lib/
./usr/lib/abraflexi-mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Body.php509
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/CompanyLogo.php2653
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/DocumentMailer.php11815
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Templater.php8114
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/mailbody.php446
./usr/lib/abraflexi-mailer/BulkMail.php2812
./usr/lib/abraflexi-mailer/SendDocument.php2573
./usr/lib/abraflexi-mailer/SendUnsent.php962
./usr/lib/abraflexi-mailer/SendUnsentWithAttachments.php4271
./usr/lib/abraflexi-mailer/ShowUnsent.php2134
./usr/lib/abraflexi-mailer/composer.json820
./usr/share/
./usr/share/doc/
./usr/share/doc/abraflexi-mailer/
./usr/share/doc/abraflexi-mailer/changelog.gz644
./usr/share/doc/abraflexi-mailer/copyright495
./usr/share/doc/abraflexi-mailer/example.env384
./usr/share/locale/
./usr/share/locale/cs_CZ/
./usr/share/locale/cs_CZ/LC_MESSAGES/
./usr/share/locale/cs_CZ/LC_MESSAGES/abraflexi-mailer.mo2611
./usr/share/locale/en_US/
./usr/share/locale/en_US/LC_MESSAGES/
./usr/share/locale/en_US/LC_MESSAGES/abraflexi-mailer.mo2493
./
./usr/
./usr/bin/
./usr/bin/abraflexi-bulkmail63
./usr/bin/abraflexi-send67
./usr/bin/abraflexi-send-unsent64
./usr/bin/abraflexi-send-unsent-with-attachments78
./usr/bin/abraflexi-show-unsent64
./usr/lib/
./usr/lib/abraflexi-mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Body.php509
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/CompanyLogo.php2653
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/DocumentMailer.php11815
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/Templater.php8114
./usr/lib/abraflexi-mailer/AbraFlexi/Mailer/mailbody.php446
./usr/lib/abraflexi-mailer/BulkMail.php2812
./usr/lib/abraflexi-mailer/SendDocument.php2573
./usr/lib/abraflexi-mailer/SendUnsent.php962
./usr/lib/abraflexi-mailer/SendUnsentWithAttachments.php4271
./usr/lib/abraflexi-mailer/ShowUnsent.php2134
./usr/lib/abraflexi-mailer/composer.json820
./usr/share/
./usr/share/doc/
./usr/share/doc/abraflexi-mailer/
./usr/share/doc/abraflexi-mailer/changelog.gz642
./usr/share/doc/abraflexi-mailer/copyright495
./usr/share/doc/abraflexi-mailer/example.env384
./usr/share/locale/
./usr/share/locale/cs_CZ/
./usr/share/locale/cs_CZ/LC_MESSAGES/
./usr/share/locale/cs_CZ/LC_MESSAGES/abraflexi-mailer.mo2611
./usr/share/locale/en_US/
./usr/share/locale/en_US/LC_MESSAGES/
./usr/share/locale/en_US/LC_MESSAGES/abraflexi-mailer.mo2493

License: MIT Packaging: deb

Document Sender for AbraFlexi

Package Logo

Scripts for sending documents are available:

SendUnsent.php - sends unsent documents in bulk directly from AbraFlexi in the standard way

SendUnsentAttachments.php - finds unsent documents, attaches attachments to them, and sends them via the default PHP mailer or SMTP

Documents are sent to addresses according to the following key:

  1. "contactEmail" from the document
  2. company email
  3. primary contact email
  4. contact email

If an address with the prefix cc is found in the document note, e.g., "cc:email@example.com, cc:copy@example.com", a copy will also be sent to these emails.

Configuration

Configuration is done by entering directives into the .env file, defining them as constants, or setting environment variables. The Debian package expects the configuration file in the /etc/abraflexi-mailer folder, where a sample file .env.template is available.

Mail Transport (MAIL_DSN)

The mailer now uses the MAIL_DSN variable, following the Symfony mailer DSN format. The previously used EASE_SMTP is deprecated.

Example for SMTP:

MAIL_DSN="smtp://username:password@mail.example.com:587?encryption=tls&auth_mode=plain"

Replace username, password, and mail.example.com with your actual SMTP credentials and server.

APP_NAME=AbraFlexiMailer                        - application name in syslog
APP_DEBUG=true                                  - enable debug mode
MUTE=true                                       - do not send messages to recipients but to

MAIL_DSN="smtp://username:password@mail.example.com:587?encryption=tls&auth_mode=plain"  - mail transport DSN (Symfony format)
EASE_MAILTO=info@vitexsoftware.cz               - messages are sent here if mute is active

ABRAFLEXI_URL="https://demo.abraflexi.eu:5434"
ABRAFLEXI_LOGIN="winstrom"
ABRAFLEXI_PASSWORD="winstrom"
ABRAFLEXI_COMPANY="demo"
ABRAFLEXI_CUSTOMER="demo"

ADD_LOGO=true                                   - include company logo in the email
ADD_QRCODE=true                                 - include QR payment image in the email
MAIL_CC=info@vitexsoftware.cz                   - send all emails also in copy to this address
MAIL_FROM=office@vitexsoftware.cz               - sender address

EASE_LOGGER="console|syslog"                    - logging method
SEND_LOCKED=False                               - try to temporarily unlock a locked document
DRY_RUN=False                                   - if enabled, does not write the date and sending status to documents

Templates

It is assumed that the template is named according to the record type, e.g., invoice-issued.ftl and is stored in the "templates" folder ( /usr/share/abraflexi-mailer/templates in Debian )

The following variables can be used in the templates:

  • ${application} โ€“ Application name, i.e., "AbraFlexi BulkMail"
  • ${user} โ€“ User object, which can be further worked with
  • ${company} โ€“ Company settings
  • ${uzivatelJmeno} โ€“ Your first name
  • ${uzivatelPrijmeni} โ€“ Your last name
  • ${titulJmenoPrijmeni} โ€“ Your full name, including achieved titles
  • ${nazevFirmy} โ€“ Company name
  • ${doklad} โ€“ Document to be sent

Bulk Mailer

If we want to send emails to all clients from Nerudova Street in Prague:

abraflexi-bulkmail templates/template.ftl "(city='Prague' AND street='Nerudova')"

When used in a template, the variables for each sent message are filled from https://demo.flexibee.eu/c/demo_de/addressbook/properties

Dependencies

This tool uses the following libraries for its functionality:

Acknowledgements

This software would not have been created without the support of:

Spoje.Net

Other software for AbraFlexi

MultiFlexi

AbraFlexi Mailer is ready to run as a MultiFlexi application. See the full list of ready-to-run applications within the MultiFlexi platform on the application list page.

Since version 1.3.8, all produced reports conform to the MultiFlexi report schema, ensuring proper integration and monitoring capabilities within the MultiFlexi ecosystem.

MultiFlexi App

Debian/Ubuntu

For Linux, .deb packages are available. Please use the repo:

    echo "deb http://repo.vitexsoftware.com $(lsb_release -sc) main" | sudo tee /etc/apt/sources.list.d/vitexsoftware.list
    sudo wget -O /etc/apt/trusted.gpg.d/vitexsoftware.gpg http://repo.vitexsoftware.cz/keyring.gpg
    sudo apt update
    sudo apt install abraflexi-mailer

After installing the package, the following new commands are available in the system:

  • abraflexi-send - sends a document
  • abraflexi-send-unsent - sends unsent documents
  • abraflexi-send-attachments - sends a document with attachments (TODO)
  • abraflexi-send-unsent-attachments - sends unsent documents with attachments
  • abraflexi-show-unsent - lists unsent documents
  • abraflexi-bulkmail - sends emails to contacts from the address book in bulk
  • abraflexi-potvrzeni-prijeti-uhrady - sends payment receipt confirmation to the customer
  • abraflexi-potvrzeni-prijeti-faktury - sends invoice receipt confirmation to the supplier
  • abraflexi-potvrzeni-odeslani-uhrady - sends payment sent (bank order) confirmation to the supplier

Confirmation Commands

The confirmation commands accept a document identifier via --docid parameter or DOCID environment variable. Based on the document ID, the recipient is determined from the address book and a confirmation email is sent.

abraflexi-potvrzeni-prijeti-uhrady --docid=VF1-0001/2026
DOCID=123 abraflexi-potvrzeni-prijeti-faktury

Additional environment variables for confirmations:

  • MAIL_SIGNATURE - email signature text appended to the message
  • SEND_INFO_TO - Cc address for confirmation copies

Exit Codes

This application uses the following exit codes:

  • 0: Success
  • 1: General error / Missing document ID
  • 2: Failed to send email
  • 3: Cannot read document from AbraFlexi
VersionDownload/Install countLast hit