I'm sending mails using this code:

$mailer = acymailing_get('helper.mailer');
$mailer->report	=false;
$mailer->trackEmail	=true;
$mailer->autoAddUser	=true;
$mailer->sendOne(46,$user_email);

Is there a way to add attachment to mail?

Hi, I asked same thing and the answer was "no". I´m wondering because this is really needed at some points. Hope the development team is going to add this feature asap.

Got news: when using the code api, you can add attachments when creating a mail like this:

$attachment = new stdClass();
$attachment->filename = $filepath;
$attachment->size = filesize(ACYM_ROOT.$filepath);

$mail->attachments = json_encode(
[
$attachment
]
);

The $filepath variable must contain the path of the file relative to the site's root folder.