Skip to content

Add Microsoft Graph Mail Transport and Configuration#8907

Merged
sanjacornelius merged 2 commits into
epic/FOUR-32115from
subtask/FOUR-32165
Jul 15, 2026
Merged

Add Microsoft Graph Mail Transport and Configuration#8907
sanjacornelius merged 2 commits into
epic/FOUR-32115from
subtask/FOUR-32165

Conversation

@sanjacornelius

@sanjacornelius sanjacornelius commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

This PR introduces Microsoft Graph mail support, allowing emails to be sent through the Microsoft Graph API.

Changes

  • Added MicrosoftGraphTransport to send emails through the Microsoft Graph sendMail endpoint.
  • Added MicrosoftGraphMessageConverter to convert mail messages into the payload required by the Graph API.
  • Added MicrosoftGraphTokenProvider to retrieve Microsoft Graph access tokens.
  • Updated OauthMailManager to support Microsoft Graph through:
    - createTransport()
    - createMicrosoftGraphTransport()
  • Registered the microsoft_graph mailer in config/mail.php.
  • Added error handling to throw a TransportException when the Graph API returns an unsuccessful HTTP response.

How to Test

Test Email Server Configuration

  1. Create a new Email Server using microsoft_graph as the driver
  2. Complete all required Microsoft Graph configuration fields
  3. Authorize the Microsoft Graph connection
  4. Select "Send Test Email"
  5. Confirm that the test email is sent successfully

Test Send Email Connector

  1. Create a new process containing a Send Email connector
  2. Configure the connector to use the Microsoft Graph Email Server created above
  3. Run the process
  4. Confirm that the email is sent successfully to the configured recipient

Related Tickets & Packages

ci:connector-send-email:subtask/FOUR-32165
ci:deploy
.

Code Review Checklist

  • I have pulled this code locally and tested it on my instance, along with any associated packages.
  • This code adheres to ProcessMaker Coding Guidelines.
  • This code includes a unit test or an E2E test that tests its functionality, or is covered by an existing test.
  • This solution fixes the bug reported in the original ticket.
  • This solution does not alter the expected output of a component in a way that would break existing Processes.
  • This solution does not implement any breaking changes that would invalidate documentation or cause existing Processes to fail.
  • This solution has been tested with enterprise packages that rely on its functionality and does not introduce bugs in those packages.
  • This code does not duplicate functionality that already exists in the framework or in ProcessMaker.
  • This ticket conforms to the PRD associated with this part of ProcessMaker.

Introduce Microsoft Graph mail support: add MicrosoftGraphTransport and MicrosoftGraphMessageConverter to send emails via the Graph API and a MicrosoftGraphTokenProvider to obtain access tokens. Integrate the transport into OauthMailManager (createTransport/createMicrosoftGraphTransport) and register a 'microsoft_graph' mailer in config/mail.php. Update the admin settings UI to show the authorization button when the mail driver is set to 'microsoft_graph'. The transport posts a sendMail payload to the Graph endpoint and throws a TransportException on HTTP errors.
@vladyrichter

Copy link
Copy Markdown

QA server K8S was successfully deployed https://ci-9a5e85c03c.engk8s.processmaker.net

1 similar comment
@vladyrichter

Copy link
Copy Markdown

QA server K8S was successfully deployed https://ci-9a5e85c03c.engk8s.processmaker.net

@processmaker-sonarqube

Copy link
Copy Markdown

Quality Gate passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarQube

@vladyrichter

Copy link
Copy Markdown

QA server K8S was successfully deployed https://ci-9a5e85c03c.engk8s.processmaker.net

@sanjacornelius
sanjacornelius merged commit f1ccc2a into epic/FOUR-32115 Jul 15, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants