Skip to content
NEWError doctor and Watchtower: failed n8n runs explained in plain words, and emailed to you. See what is new

Library / Email Automation

Email Automation

Gmailtrigger Workflow

When a new email arrives, it handles email with OpenAI / ChatGPT using Gmail, Jira, Outlook.

What it does

![hctiapi]({{ $env.WEBHOOK_URL }} ## Automated Jira Ticket Creation and Email Attachment This section streamlines the process of logging phishing email reports in Jira, complete with detailed analysis and attachments. The workflow creates two distinct Jira tickets depending on the AI classification of the email: 1. Potentially Malicious: The Create Potentially Malicious Ticket node generates a ticket if the email is flagged as a phishing attempt, including a summary of ChatGPT's analysis and the email’s details. 2. Potentially Benign: If the email is classified as safe, the Create Potentially Benign Ticket node logs a ticket with similar details but under a non-malicious category. The Set Jira ID node ensures the generated ticket's ID is tracked for subsequent operations. Attachments are handled efficiently: - Rename Screenshot prepares the email screenshot for upload. - Upload Screenshot of Email to Jira adds the screenshot to the Jira ticket for visual context. - Rename Email Body Screenshot and Upload Email Body to Jira manage the attachment of the email's text body as a .txt file. This section enhances reporting by automating ticket creation, ensuring all relevant email data is readily available for review by security teams.

The steps

  1. Gmail Trigger
  2. Microsoft Outlook Trigger
  3. Screenshot HTML
  4. Retrieve Screenshot
  5. Set Outlook Variables
  6. Set Gmail Variables
  7. Retrieve Headers of Email
  8. Format Headers
  9. Analyze Email with ChatGPT
  10. Create Potentially Malicious Ticket
  11. Create Potentially Benign Ticket
  12. Rename Screenshot
  13. Set Jira ID
  14. Upload Screenshot of Email to Jira

19 steps in total.

Similar automations