Skip to content

Outlook Integration. Setting-up for Administrator

Integration

Go to the Administration > Integrations > Outlook. Check Enabled checkbox.

  • You will obtain Client ID and Client Secret in Azure Active Directory admin center.
  • You will need to copy Redirect URI to Azure Active Directory admin center.

Integration

1. Go to aad.portal.azure.com.

2. Create an application.

Follow Azure Active Directory > App registration > Register an application.

App registration

Select needed Supported account types.

Copy Redirect URI from EspoCRM. Note, that type should be set to Web.

App registration

3. Copy Application (client) ID from Azure app to EspoCRM.

Client ID

Client ID

4. Create a secret for Azure app. Copy it to EspoCRM.

Secret

Secret

If the Never option is not available, choose In 2 years. In this case you will need to re-generate the secret in 2 years.

Secret

Secret

5. Save Outlook integration credentials in EspoCRM.

6. Grant required permissions for Azure app.

Note

This step is required for Office365 users. For Outlook, it usually works without this step, but it might be needed either.

Click Api Permissions on the left panel. Click Add a permission. Click Microsoft Graph. Click Delegated permissions. Then, use search to find the needed permissions and enable them.

Permissions that need to be enabled:

  • offline_access – mandatory;
  • Calendars.ReadWrite – optional – for calendar sync;
  • Contacts.ReadWrite – optional – for contacts pushing;
  • IMAP.AccessAsUser.All – optional – for email fetching;
  • SMTP.Send – optional – for email sending.

Permissions

After adding the above listed API permissions, click Grant Admin Consent for (your organization).

Access control

Important: By default, the regular users don’t have access to Outlook Calendar integration. Administrator needs to enable access in Roles. The following scopes need to be enabled:

  • External Accounts;
  • Outlook Calendar;
  • Outlook Contacts.

Roles

Sync scheduling

Sync is run by the scheduled job Outlook Calendar Sync. By default, it is executed every 10 minutes. You can change scheduling at Administration > Scheduled Jobs > Outlook Calendar Sync.

Troubleshooting

Check whether the scheduled job is running Administration > Scheduled Jobs > Outlook Calendar Sync > Log.

Check EspoCRM log at data/logs directory. You can also set the log mode to DEBUG level to obtain more info from the log.

Office 365 configuration

Enabling SMTP

For Office 365 you might need to enable SMTP AUTH for specific mailboxes. See how to do it in the Microsoft documentation.