SIFA Bug Reporting Workflow¶
This workflow processes issue reports about the SIFA system, automatically routing them to both Jira (via email) and Slack for team visibility. It handles reports with or without file attachments, formats phone numbers consistently, and ensures all relevant stakeholders are notified when users experience problems with SIFA.
Purpose¶
No business context provided yet — add a context.md to enrich this documentation.
How It Works¶
- Receive Report: A webhook receives issue reports from an external form or application
- Check for Attachments: The workflow determines if the report includes file attachments (screenshots, videos, etc.)
- Process Attachments (if present): Base64-encoded files are converted to proper binary attachments and phone numbers are formatted to Kenyan standard (+254)
- Format Phone Numbers (if no attachments): Phone numbers are still standardized to +254 format
- Send to Jira: An HTML-formatted email is sent to Jira's email-to-ticket system with all report details
- Notify Slack: A formatted message is posted to the team Slack channel
- Upload Files to Slack (if attachments exist): Files are uploaded separately to the Slack channel for easy access
Workflow Diagram¶
graph TD
A[Webhook] --> B[Has Attachment?]
B -->|Yes| C[Convert Base64 to Files]
B -->|No| D[Format Phone]
C --> E[Email to Jira with files]
C --> F[Slack Message with files]
C --> G[Upload File to Slack]
D --> H[Email to Jira no file]
H --> I[Slack no attachments]
Trigger¶
Webhook: POST endpoint at /webhook/634b5fb3-6433-417a-b742-d0ef9cd33d70
- Accepts JSON payloads with issue report data
- Configured to allow requests from any origin (*)
Nodes Used¶
| Node Type | Purpose |
|---|---|
| Webhook | Receives incoming issue reports via HTTP POST |
| If | Determines whether the report includes file attachments |
| Code | Converts base64 attachments to binary files and formats phone numbers |
| Code | Formats phone numbers for reports without attachments |
| Gmail | Sends HTML-formatted emails to Jira's ticket creation system |
| Slack | Posts formatted messages to the team channel |
| Slack | Uploads file attachments to Slack |
External Services & Credentials Required¶
Gmail¶
- Credential:
gmailOAuth2(Gmail account) - Purpose: Send issue reports to Jira via email-to-ticket
- Recipient:
kt@experienceeducate.atlassian.net
Slack¶
- Credential:
slackApi(Slack account) - Purpose: Post notifications and upload files
- Channel:
C0AMKASPRK9(specific team channel)
Environment Variables¶
No environment variables are used in this workflow. All configuration is handled through node parameters and credentials.
Data Flow¶
Input (Webhook Body)¶
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | |
Output¶
- Jira Email: HTML table with all report details, attachments included if present
- Slack Message: Formatted notification with key details and attachment count
- Slack Files: Individual file uploads for each attachment
Phone Number Formatting¶
- Input:
0712287952or712287952or254712287952 - Output:
+254712287952(standardized Kenyan format)
Error Handling¶
This workflow does not include explicit error handling nodes. If any node fails: - The workflow execution will stop at the failed node - Subsequent notifications may not be sent - Manual intervention may be required to process the report
Known Limitations¶
- No error handling or retry logic for failed email/Slack deliveries
- File uploads to Slack are limited to the first attachment (
file_0) - No validation of input data format or required fields
- Webhook accepts requests from any origin, which may pose security considerations
Related Workflows¶
No related workflows specified in the current context.
Setup Instructions¶
-
Import Workflow: Import the JSON configuration into your n8n instance
-
Configure Credentials:
- Set up Gmail OAuth2 credential for sending emails to Jira
- Configure Slack API credential with appropriate permissions for posting messages and uploading files
-
Update Configuration:
- Verify the Jira email address (
kt@experienceeducate.atlassian.net) is correct - Confirm the Slack channel ID (
C0AMKASPRK9) points to your desired notification channel - Adjust the webhook path if needed for security
- Verify the Jira email address (
-
Test the Workflow:
- Send a test POST request to the webhook endpoint
- Verify emails are received in Jira and converted to tickets
- Check that Slack notifications appear in the correct channel
-
Activate: Enable the workflow to start processing live issue reports
Note: Ensure your n8n instance can reach both Gmail and Slack APIs, and that the webhook endpoint is accessible from your issue reporting application.