Home Wordpress How to Connect SupportCandy to Microsoft Exchange with DavMail

How to Connect SupportCandy to Microsoft Exchange with DavMail

1
Technical diagram showing WordPress SupportCandy integration with Microsoft Exchange via DavMail bridge

Modern versions of SupportCandy removed the legacy “Local Exchange” connector and now only ship three piping options—Basic IMAP, Gmail API and Microsoft Exchange API12. If your mailboxes sit on on-prem Exchange, hybrid Exchange or Office 365 tenants where the Exchange API route is blocked or requires complicated Azure registration, you can still bring every support email straight into WordPress: run DavMail as an IMAP bridge and let SupportCandy consume it like any other mail server.

Below is a complete, SEO-optimised step-by-step guide you can copy-paste into your tech blog.

Why DavMail?

  1. Protocol Translation – DavMail speaks EWS/OWA on the back end and exposes standard ports (IMAP, POP, SMTP, CalDAV, LDAP) on the front end3.
  2. Works with MFA & Modern Auth – The O365Modern and O365Interactive modes log in via OAuth2, so Office 365 tenants with MFA are covered45.
  3. Runs Anywhere – Java application; works on Windows, macOS, Linux or inside a Docker/LXC container.
  4. Keeps SupportCandy Simple – SupportCandy only sees “localhost:1143” (or 993 if you enable SSL) and imports tickets through its familiar IMAP screen6.

Prerequisites

ComponentMinimum versionNotes
WordPress5.6+Required by SupportCandy7.
SupportCandy Core3.xPlus the Email Piping add-on.
Java Runtime8+Needed to run DavMail.
Exchange2007+ (EWS) or Office 365OWA/EWS URL must be reachable from the DavMail host4.

Step 1 – Download & Install DavMail

Windows

  1. Grab the installer from SourceForge (davmail-win64.exe).
  2. Run as Administrator; leave default ports (1143 IMAP, 1025 SMTP, 1080 CalDAV, etc.) for a workstation setup3.

Linux (system-wide service)

bashsudo apt install davmail
sudo systemctl enable davmail

Docker one-liner

bashdocker run -d \
  -e DAVMAIL_URL=https://outlook.office365.com/EWS/Exchange.asmx \
  -e DAVMAIL_MODE=O365Modern \
  -p 1143:1143 -p 1025:1025 \
  --name davmail gatewayapps/davmail

Step 2 – Configure DavMail

Open davmail.properties (GUI → Settings… or /etc/davmail.properties).

Essential entries:

text# Talk to Exchange
davmail.url=https://outlook.office365.com/EWS/Exchange.asmx   # or on-prem OWA/EWS URL
davmail.mode=O365Modern                                       # O365Modern, O365Interactive or EWS[8][50]

# IMAP gateway
davmail.imapPort=1143                                         # switch to 993 if you want SSL[7]

# Run headless on a server
davmail.server=true

Save & restart DavMail.


Test with Telnet:

bashtelnet localhost 1143
* OK IMAP4rev1 DavMail server ready
  1. Generate a PKCS#12 keystore or import a CA certificate8.
bash
keytool -genkey -storetype PKCS12 -keystore /opt/davmail.p12 \
        -keypass CHANGEIT -storepass CHANGEIT \
        -dname "CN=support.example.com,OU=IT,O=Company,L=City,C=US"
  1. Add to davmail.properties:
text
davmail.ssl.keystoreType=PKCS12
davmail.ssl.keystoreFile=/opt/davmail.p12
davmail.ssl.keyPass=CHANGEIT
davmail.ssl.keystorePass=CHANGEIT
davmail.imapPort=993            # secure IMAPS
davmail.smtpPort=465            # secure SMTPS[44]
  1. Restart and re-test: openssl s_client -connect localhost:993.

Step 4 – Point SupportCandy to DavMail

  1. Support → Settings → Email Piping → IMAP.
  2. Fill the form:
textEmail address:  support@example.com
Password:        <mailbox password or app-password>
Incoming server: 127.0.0.1
Port:            1143   (or 993 with SSL)
Encryption:      None   (or SSL)

SupportCandy will now fetch every mail arriving in the Exchange inbox and turn it into tickets. Remember that the docs state Exchange is “not allowed” over basic IMAP6; DavMail circumvents that because the Exchange side is EWS while SupportCandy sees standard IMAP.

Step 5 – Run DavMail as a Service

Systemd example (/etc/systemd/system/davmail.service)

text
[Unit]
Description=DavMail Exchange Gateway
After=network.target

[Service]
ExecStart=/usr/bin/davmail /etc/davmail.properties
SuccessExitStatus=143
Restart=always
User=davmail

[Install]
WantedBy=multi-user.target
bash
sudo systemctl daemon-reload
sudo systemctl start davmail
sudo systemctl enable davmail

Troubleshooting Cheat-Sheet

SymptomLikely CauseFix
Port already in use in DavMail logs9Another process (or previous DavMail instance) bound to 1143/1025fuser -k -n tcp 1143 then restart service.
Broken pipe or timeout during large messages10Exchange throttling or client idleIncrease davmail.timeout (ms) in properties to 120000.
MFA loop in O365Using EWS mode on a tenant with modern auth enforcedSwitch to O365Modern or O365Interactive5.
SupportCandy fetches nothingWrong port/encryptionMatch 1143→None or 993→SSL. Check mailbox credentials.
Emails duplicate or not marked readSet “Leave a copy on server” in SupportCandy to off and enable “Mark message read after fetch”.

Final Thoughts

Until SupportCandy re-introduces a first-party on-prem Exchange connector, DavMail is the quickest, zero-cost workaround to keep your Microsoft Exchange or Office 365 mailboxes flowing into WordPress. Combined with SupportCandy’s robust ticket management and DavMail’s OAuth-compatible gateway, you get enterprise-grade helpdesk automation without paid SaaS fees or complex Azure permissions.

Plug it in, secure it, and let your agents focus on solving tickets—not wrestling with Exchange APIs.

Happy bridging!

1 Comment

Leave a reply

Please enter your comment!
Please enter your name here

English
English
English
Deutsch
Español
Italiano
Français
Exit mobile version