Browse our Products

Aspose.Email for Java 22.6 Release Notes

All Changes

KeySummaryCategory
EMAILJAVA-35052SendGrid client implementationFeature
EMAILJAVA-35051Mailgun clients implementationFeature
EMAILNET-40606Extract DTSTAMP from PST and save as ICS changes DTSTAMP to current timestampEnhancement
EMAILNET-40611POP client does not AUTH automatically if CAPA command is not supportedBug
EMAILNET-40620Word to EML conversion generate body content as attachmentBug
EMAILNET-40622Formatting not retained for DOCX as bodyBug
EMAILNET-40612VCardContactSave omits data after resaving VCFBug
EMAILNET-40613Questionmarks when loaded FromMailMessageBug
EMAILJAVA-35066PDF conversion issue from EMLBug

New Features

Working with MailGun and SendGrid delivery services

We’ve added the ability to send messages using MailGun or SendGrid services. We have created a unified API, so the first thing is to initialize options depending on which service is going to be used for sending messages.

MailGun client options.

String domain = "YOUR_MAILGUN_DOMEN";
String privApiKey = "YOUR_MAILGUN_PRIVATE_API_KEY";
MailgunClientOptions opt = new MailgunClientOptions();
opt.setDomain(domain);
opt.setApiKey(privApiKey);

SendGrid client options.

String privApiKey = "YOUR_SENDGRID_PRIVATE_API_KEY";
SendGridClientOptions opt = new SendGridClientOptions();
opt.setApiKey(privApiKey);

Then, call the required client instance using the builder.

IDeliveryServiceClient client = DeliveryServiceClientFactory.get(opt);

Finally, prepare and send an email message.

MailMessage eml = new MailMessage("fromAddress", "toAddress", "subject", "body");

DeliveryServiceResponse resp = client.send(eml);

if (!resp.isSuccessful()) {
    for (String error : resp.getErrorMessages()) {
        System.out.println(error);
    }
}

New Enhancements

Extracting calendar item from PST and save as ICS with original timestamp.

Changes in public API:

MapiCalendarIcsSaveOptions - Allows to specify additional options when saving MapiCalendar to Ics format. MapiCalendarIcsSaveOptions.setKeepOriginalDateTimeStamp - Allows keep original DateTimeStamp value in output file.

Code samples:

MapiCalendar cal = (MapiCalendar) pst.extractMessage(messageInfo).toMapiMessageItem();

if (cal != null) {
    MapiCalendarIcsSaveOptions so = new MapiCalendarIcsSaveOptions();
    so.setKeepOriginalDateTimeStamp(true);
    cal.save("cal.ics", so);
}