This workflow corresponds to n8n.io template #13447 — we link there as the canonical source.
This workflow follows the Agent → Agenttool recipe pattern — see all workflows that pair these two integrations.
The workflow JSON
Copy or download the full n8n JSON below. Paste it into a new n8n workflow, add your credentials, activate. Full import guide →
{
"id": "Ecthke7HldQmhEnT50WMp",
"name": "AI-driven content moderation and governance workflow",
"tags": [],
"nodes": [
{
"id": "d43ed7b5-c6e1-4504-af69-9d2de875d01f",
"name": "Content Moderation Webhook",
"type": "n8n-nodes-base.webhook",
"position": [
-448,
288
],
"parameters": {
"path": "content-moderation",
"options": {},
"httpMethod": "POST",
"responseMode": "responseNode"
},
"typeVersion": 2.1
},
{
"id": "71dc6ee9-ecb5-4125-8a17-9456321ef5e3",
"name": "Workflow Configuration",
"type": "n8n-nodes-base.set",
"position": [
-224,
288
],
"parameters": {
"options": {},
"assignments": {
"assignments": [
{
"id": "id-1",
"name": "moderationThreshold",
"type": "number",
"value": 0.75
},
{
"id": "id-2",
"name": "escalationEmail",
"type": "string",
"value": "<__PLACEHOLDER_VALUE__Escalation email address__>"
},
{
"id": "id-3",
"name": "slackChannelId",
"type": "string",
"value": "<__PLACEHOLDER_VALUE__Slack channel ID for moderation alerts__>"
},
{
"id": "id-4",
"name": "severityLevels",
"type": "array",
"value": "[\"LOW\", \"MEDIUM\", \"HIGH\", \"CRITICAL\"]"
}
]
},
"includeOtherFields": true
},
"typeVersion": 3.4
},
{
"id": "f1535304-ab85-4d27-9c92-bc7b6ea20d12",
"name": "Content Signal Agent",
"type": "@n8n/n8n-nodes-langchain.agent",
"position": [
0,
288
],
"parameters": {
"text": "=Content to validate: {{ $json.body.content }}\nUser ID: {{ $json.body.userId }}\nContent Type: {{ $json.body.contentType }}\nModeration Flags: {{ JSON.stringify($json.body.moderationFlags) }}",
"options": {
"systemMessage": "You are a Content Signal Validation Agent specialized in analyzing moderation flags and content signals.\n\nYour task is to:\n1. Analyze the provided content and moderation flags\n2. Validate if the flags are accurate and justified\n3. Assess the severity level (LOW, MEDIUM, HIGH, CRITICAL)\n4. Determine if the content violates community guidelines\n5. Provide a confidence score (0-1) for your assessment\n6. Return structured validation results with clear reasoning\n\nValidation Status Options:\n- VALID: Content passes all checks\n- FLAGGED: Content requires governance review\n- SUSPICIOUS: Unclear signals, needs human review\n\nBe thorough and consider context, intent, and potential false positives."
},
"promptType": "define",
"hasOutputParser": true
},
"typeVersion": 3.1
},
{
"id": "fe8c2b1a-be77-42ca-baf2-2e2551c42bca",
"name": "OpenAI Model - Content Signal",
"type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
"position": [
8,
512
],
"parameters": {
"model": {
"__rl": true,
"mode": "id",
"value": "gpt-4o"
},
"options": {
"temperature": 0.2
},
"builtInTools": {}
},
"credentials": {
"openAiApi": {
"name": "<your credential>"
}
},
"typeVersion": 1.3
},
{
"id": "e10aa0d2-7486-4ecd-b252-ebc34055b40e",
"name": "Structured Output - Content Signal",
"type": "@n8n/n8n-nodes-langchain.outputParserStructured",
"position": [
136,
512
],
"parameters": {
"jsonSchemaExample": "{\n \"validationStatus\": \"VALID\",\n \"severityLevel\": \"LOW\",\n \"confidenceScore\": 0.95,\n \"violationTypes\": [],\n \"reasoning\": \"Content analysis reasoning here\",\n \"requiresGovernanceReview\": false\n}"
},
"typeVersion": 1.3
},
{
"id": "118e87c2-eb1a-4b4b-806b-8a3d0f2fec33",
"name": "Route by Validation Status",
"type": "n8n-nodes-base.switch",
"position": [
352,
272
],
"parameters": {
"rules": {
"values": [
{
"outputKey": "Valid",
"conditions": {
"options": {
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"operator": {
"type": "string",
"operation": "equals"
},
"leftValue": "={{ $json.output.validationStatus }}",
"rightValue": "VALID"
}
]
},
"renameOutput": true
},
{
"outputKey": "Flagged",
"conditions": {
"options": {
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"operator": {
"type": "string",
"operation": "equals"
},
"leftValue": "={{ $json.output.validationStatus }}",
"rightValue": "FLAGGED"
}
]
},
"renameOutput": true
}
]
},
"options": {
"fallbackOutput": "extra",
"renameFallbackOutput": "Suspicious"
}
},
"typeVersion": 3.4
},
{
"id": "4da219ec-2463-4e97-a6f6-a0eabe22bc30",
"name": "Governance Agent",
"type": "@n8n/n8n-nodes-langchain.agent",
"position": [
1000,
464
],
"parameters": {
"text": "=Flagged Content Data:\nContent: {{ $json.body.content }}\nUser ID: {{ $json.body.userId }}\nValidation Results: {{ JSON.stringify($json.output) }}\nSeverity: {{ $json.output.severityLevel }}\nViolation Types: {{ JSON.stringify($json.output.violationTypes) }}",
"options": {
"systemMessage": "You are a Governance Orchestration Agent responsible for coordinating content moderation reviews, appeals, and enforcement actions.\n\nYour task is to:\n1. Analyze flagged content and validation results\n2. Determine the appropriate governance action (REVIEW, APPEAL, ENFORCE)\n3. Call the appropriate specialized agent tool:\n - Review Agent Tool: For detailed content review and policy assessment\n - Appeals Agent Tool: For processing user appeals and reconsideration\n - Enforcement Agent Tool: For determining and executing enforcement actions\n4. Coordinate multi-step governance workflows\n5. Return structured governance decisions with action type and reasoning\n\nAction Types:\n- REVIEW: Content needs detailed policy review\n- APPEAL: User appeal requires processing\n- ENFORCE: Enforcement action required\n- ESCALATE: Human oversight needed\n\nAlways provide clear reasoning and ensure compliance with platform policies."
},
"promptType": "define",
"hasOutputParser": true
},
"typeVersion": 3.1
},
{
"id": "79f1d1c8-add3-4109-97ff-30cc7bb84faa",
"name": "OpenAI Model - Governance",
"type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
"position": [
576,
688
],
"parameters": {
"model": {
"__rl": true,
"mode": "id",
"value": "gpt-4o"
},
"options": {
"temperature": 0.3
},
"builtInTools": {}
},
"credentials": {
"openAiApi": {
"name": "<your credential>"
}
},
"typeVersion": 1.3
},
{
"id": "1df010bf-6c63-4312-a2d2-dfcd987fa9c5",
"name": "Structured Output - Governance",
"type": "@n8n/n8n-nodes-langchain.outputParserStructured",
"position": [
1696,
704
],
"parameters": {
"jsonSchemaExample": "{\n \"actionType\": \"ENFORCE\",\n \"enforcementAction\": \"CONTENT_REMOVAL\",\n \"severityLevel\": \"HIGH\",\n \"requiresEscalation\": true,\n \"reasoning\": \"Governance decision reasoning\",\n \"nextSteps\": [\"Action 1\", \"Action 2\"],\n \"complianceNotes\": \"Compliance considerations\"\n}"
},
"typeVersion": 1.3
},
{
"id": "f359552f-05e5-4ad0-94a3-ece9383278bf",
"name": "Review Agent Tool",
"type": "@n8n/n8n-nodes-langchain.agentTool",
"position": [
704,
688
],
"parameters": {
"text": "={{ $fromAI(\"contentData\", \"Content and validation data for review\", \"json\") }}",
"options": {
"systemMessage": "You are a Content Review Specialist Agent focused on detailed policy assessment and content evaluation.\n\nYour task is to:\n1. Conduct thorough content review against platform policies\n2. Assess context, intent, and potential harm\n3. Identify specific policy violations\n4. Determine appropriate review outcomes\n5. Provide detailed reasoning for decisions\n6. Return structured review results\n\nReview Outcomes:\n- APPROVE: Content is acceptable\n- RESTRICT: Content needs restrictions (age-gate, warning)\n- REMOVE: Content violates policies\n- ESCALATE: Requires human review\n\nConsider nuance, context, and proportionality in all decisions."
},
"hasOutputParser": true,
"toolDescription": "Conducts detailed content review and policy assessment for flagged content"
},
"typeVersion": 3
},
{
"id": "23910949-ef48-45f2-bd78-740e79a3a535",
"name": "OpenAI Model - Review Tool",
"type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
"position": [
656,
896
],
"parameters": {
"model": {
"__rl": true,
"mode": "id",
"value": "gpt-4o"
},
"options": {
"temperature": 0.2
},
"builtInTools": {}
},
"credentials": {
"openAiApi": {
"name": "<your credential>"
}
},
"typeVersion": 1.3
},
{
"id": "ab2e9d0e-4eac-4187-bbfb-f0cd30c0cb54",
"name": "Structured Output - Review Tool",
"type": "@n8n/n8n-nodes-langchain.outputParserStructured",
"position": [
816,
896
],
"parameters": {
"jsonSchemaExample": "{\n \"reviewOutcome\": \"REMOVE\",\n \"policyViolations\": [\"Violation 1\", \"Violation 2\"],\n \"contextualFactors\": \"Context analysis\",\n \"reasoning\": \"Review reasoning\",\n \"recommendedAction\": \"Recommended next steps\"\n}"
},
"typeVersion": 1.3
},
{
"id": "7e868fce-ca0b-4955-a12f-fcb58cbcb5e5",
"name": "Appeals Agent Tool",
"type": "@n8n/n8n-nodes-langchain.agentTool",
"position": [
992,
688
],
"parameters": {
"text": "={{ $fromAI(\"appealData\", \"User appeal data and original decision\", \"json\") }}",
"options": {
"systemMessage": "You are an Appeals Processing Agent specialized in reviewing user appeals and reconsideration requests.\n\nYour task is to:\n1. Review user appeals against original moderation decisions\n2. Assess new evidence or context provided\n3. Determine if original decision should be upheld or overturned\n4. Evaluate appeal validity and user arguments\n5. Provide fair and balanced appeal outcomes\n6. Return structured appeal decisions\n\nAppeal Outcomes:\n- UPHELD: Original decision stands\n- OVERTURNED: Decision reversed, content restored\n- MODIFIED: Partial reversal with conditions\n- ESCALATE: Requires senior review\n\nEnsure fairness, transparency, and consistency in all appeal decisions."
},
"hasOutputParser": true,
"toolDescription": "Processes user appeals and reconsideration requests for moderation decisions"
},
"typeVersion": 3
},
{
"id": "b7a53312-6676-4ba2-ae61-1b99c822d75c",
"name": "OpenAI Model - Appeals Tool",
"type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
"position": [
992,
896
],
"parameters": {
"model": {
"__rl": true,
"mode": "id",
"value": "gpt-4o"
},
"options": {
"temperature": 0.2
},
"builtInTools": {}
},
"credentials": {
"openAiApi": {
"name": "<your credential>"
}
},
"typeVersion": 1.3
},
{
"id": "f9e3952a-02ad-45d7-bf45-4c83911b73fb",
"name": "Structured Output - Appeals Tool",
"type": "@n8n/n8n-nodes-langchain.outputParserStructured",
"position": [
1152,
896
],
"parameters": {
"jsonSchemaExample": "{\n \"appealOutcome\": \"UPHELD\",\n \"originalDecisionValid\": true,\n \"newEvidenceConsidered\": \"Evidence summary\",\n \"reasoning\": \"Appeal decision reasoning\",\n \"userNotification\": \"Message to user\"\n}"
},
"typeVersion": 1.3
},
{
"id": "3c9cd788-5977-47f7-b6a2-769daca995ae",
"name": "Enforcement Agent Tool",
"type": "@n8n/n8n-nodes-langchain.agentTool",
"position": [
1408,
704
],
"parameters": {
"text": "={{ $fromAI(\"enforcementData\", \"Content data and enforcement requirements\", \"json\") }}",
"options": {
"systemMessage": "You are an Enforcement Action Agent responsible for determining and coordinating enforcement measures.\n\nYour task is to:\n1. Determine appropriate enforcement actions based on violations\n2. Consider severity, user history, and platform policies\n3. Coordinate enforcement escalation when needed\n4. Apply proportional and consistent enforcement\n5. Track enforcement actions for compliance\n6. Return structured enforcement decisions\n\nEnforcement Actions:\n- WARNING: Issue warning to user\n- CONTENT_REMOVAL: Remove violating content\n- ACCOUNT_RESTRICTION: Temporary restrictions\n- ACCOUNT_SUSPENSION: Suspend account\n- ACCOUNT_BAN: Permanent ban\n- ESCALATE: Requires legal/compliance review\n\nEnsure all enforcement actions are justified, documented, and compliant with policies."
},
"hasOutputParser": true,
"toolDescription": "Determines and executes enforcement actions for policy violations"
},
"typeVersion": 3
},
{
"id": "c94831a4-3142-4df7-9024-bcda78054c36",
"name": "OpenAI Model - Enforcement Tool",
"type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
"position": [
1424,
912
],
"parameters": {
"model": {
"__rl": true,
"mode": "id",
"value": "gpt-4o"
},
"options": {
"temperature": 0.2
},
"builtInTools": {}
},
"credentials": {
"openAiApi": {
"name": "<your credential>"
}
},
"typeVersion": 1.3
},
{
"id": "dda30abe-9858-4fe6-8d7b-7ae417a83785",
"name": "Structured Output - Enforcement Tool",
"type": "@n8n/n8n-nodes-langchain.outputParserStructured",
"position": [
1600,
912
],
"parameters": {
"jsonSchemaExample": "{\n \"enforcementAction\": \"CONTENT_REMOVAL\",\n \"severityJustification\": \"Severity reasoning\",\n \"userImpact\": \"Impact on user\",\n \"escalationRequired\": true,\n \"complianceNotes\": \"Compliance documentation\",\n \"reasoning\": \"Enforcement reasoning\"\n}"
},
"typeVersion": 1.3
},
{
"id": "59b35ada-eb5d-4b1d-95bd-1fea339bae63",
"name": "Route by Action Type",
"type": "n8n-nodes-base.switch",
"position": [
1888,
592
],
"parameters": {
"rules": {
"values": [
{
"outputKey": "Review",
"conditions": {
"options": {
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"operator": {
"type": "string",
"operation": "equals"
},
"leftValue": "={{ $json.output.actionType }}",
"rightValue": "REVIEW"
}
]
},
"renameOutput": true
},
{
"outputKey": "Enforce",
"conditions": {
"options": {
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"operator": {
"type": "string",
"operation": "equals"
},
"leftValue": "={{ $json.output.actionType }}",
"rightValue": "ENFORCE"
}
]
},
"renameOutput": true
}
]
},
"options": {
"fallbackOutput": "extra",
"renameFallbackOutput": "Other Actions"
}
},
"typeVersion": 3.4
},
{
"id": "795b7a19-525b-4918-bed4-8bc4dd76058f",
"name": "Store Valid Content",
"type": "n8n-nodes-base.dataTable",
"position": [
2464,
256
],
"parameters": {
"options": {},
"dataTableId": {
"__rl": true,
"mode": "name",
"value": "ValidContent"
}
},
"typeVersion": 1.1
},
{
"id": "b5327eb9-f4a0-4351-b6e5-101f96f14960",
"name": "Store Flagged Content",
"type": "n8n-nodes-base.dataTable",
"position": [
2528,
800
],
"parameters": {
"options": {},
"dataTableId": {
"__rl": true,
"mode": "name",
"value": "FlaggedContent"
}
},
"typeVersion": 1.1
},
{
"id": "5008f3c7-610a-4947-aef3-cce51065eb81",
"name": "Store Enforcement Actions",
"type": "n8n-nodes-base.dataTable",
"position": [
2080,
512
],
"parameters": {
"options": {},
"dataTableId": {
"__rl": true,
"mode": "name",
"value": "EnforcementActions"
}
},
"typeVersion": 1.1
},
{
"id": "d5bc62e1-1893-466e-8e7a-83c244aeab19",
"name": "Check Escalation Required",
"type": "n8n-nodes-base.if",
"position": [
2304,
512
],
"parameters": {
"options": {},
"conditions": {
"options": {
"leftValue": "",
"caseSensitive": false,
"typeValidation": "loose"
},
"combinator": "and",
"conditions": [
{
"id": "id-1",
"operator": {
"type": "boolean",
"operation": "equals"
},
"leftValue": "={{ $json.output.escalationRequired }}",
"rightValue": true
}
]
}
},
"typeVersion": 2.3
},
{
"id": "08caa7ef-8cde-4b2e-9ab2-0ee796d3104b",
"name": "Notify Moderation Team",
"type": "n8n-nodes-base.slack",
"position": [
2528,
416
],
"parameters": {
"text": "=\ud83d\udea8 *CRITICAL ENFORCEMENT ESCALATION*\n\n*Action Type:* {{ $json.output.actionType }}\n*Enforcement:* {{ $json.output.enforcementAction }}\n*Severity:* {{ $json.output.severityLevel }}\n\n*User ID:* {{ $json.body.userId }}\n*Content Type:* {{ $json.body.contentType }}\n\n*Reasoning:*\n{{ $json.output.reasoning }}\n\n*Compliance Notes:*\n{{ $json.output.complianceNotes }}\n\n*Next Steps:*\n{{ $json.output.nextSteps.join(\"\\n\") }}\n\n_Requires immediate moderation team review_",
"select": "channel",
"channelId": {
"__rl": true,
"mode": "id",
"value": "={{ $('Workflow Configuration').first().json.slackChannelId }}"
},
"otherOptions": {},
"authentication": "oAuth2"
},
"credentials": {
"slackOAuth2Api": {
"name": "<your credential>"
}
},
"typeVersion": 2.4
},
{
"id": "7de37af4-bf1c-4a0b-960f-4caa85ff14b0",
"name": "Escalation Email",
"type": "n8n-nodes-base.emailSend",
"position": [
2528,
608
],
"parameters": {
"html": "=<html>\n<body style=\"font-family: Arial, sans-serif; line-height: 1.6; color: #333;\">\n<div style=\"background-color: #dc3545; color: white; padding: 20px; border-radius: 5px;\">\n<h2>\ud83d\udea8 CRITICAL CONTENT MODERATION ESCALATION</h2>\n</div>\n\n<div style=\"padding: 20px;\">\n<h3>Enforcement Details</h3>\n<table style=\"width: 100%; border-collapse: collapse;\">\n<tr><td style=\"padding: 8px; border: 1px solid #ddd; font-weight: bold;\">Action Type:</td><td style=\"padding: 8px; border: 1px solid #ddd;\">{{ $json.output.actionType }}</td></tr>\n<tr><td style=\"padding: 8px; border: 1px solid #ddd; font-weight: bold;\">Enforcement Action:</td><td style=\"padding: 8px; border: 1px solid #ddd;\">{{ $json.output.enforcementAction }}</td></tr>\n<tr><td style=\"padding: 8px; border: 1px solid #ddd; font-weight: bold;\">Severity Level:</td><td style=\"padding: 8px; border: 1px solid #ddd;\">{{ $json.output.severityLevel }}</td></tr>\n<tr><td style=\"padding: 8px; border: 1px solid #ddd; font-weight: bold;\">User ID:</td><td style=\"padding: 8px; border: 1px solid #ddd;\">{{ $json.body.userId }}</td></tr>\n<tr><td style=\"padding: 8px; border: 1px solid #ddd; font-weight: bold;\">Content Type:</td><td style=\"padding: 8px; border: 1px solid #ddd;\">{{ $json.body.contentType }}</td></tr>\n</table>\n\n<h3>Reasoning</h3>\n<p style=\"background-color: #f8f9fa; padding: 15px; border-left: 4px solid #dc3545;\">{{ $json.output.reasoning }}</p>\n\n<h3>Compliance Notes</h3>\n<p style=\"background-color: #fff3cd; padding: 15px; border-left: 4px solid #ffc107;\">{{ $json.output.complianceNotes }}</p>\n\n<h3>Next Steps Required</h3>\n<ul>\n{{ $json.output.nextSteps.map(step => `<li>${step}</li>`).join(\"\") }}\n</ul>\n\n<p style=\"margin-top: 30px; padding: 15px; background-color: #f8d7da; border-left: 4px solid #dc3545;\">\n<strong>\u26a0\ufe0f IMMEDIATE ACTION REQUIRED</strong><br>\nThis case requires urgent review and decision by the moderation leadership team.\n</p>\n\n<p style=\"color: #666; font-size: 12px; margin-top: 30px;\">Generated: {{ $now.toFormat(\"yyyy-MM-dd HH:mm:ss\") }}</p>\n</div>\n</body>\n</html>",
"options": {},
"subject": "=CRITICAL: Content Moderation Escalation - {{ $json.output.severityLevel }} Severity",
"toEmail": "={{ $('Workflow Configuration').first().json.escalationEmail }}",
"fromEmail": "<__PLACEHOLDER_VALUE__Sender email address__>"
},
"typeVersion": 2.1
},
{
"id": "61c0ef27-6082-4a75-ac8b-55b519539c1b",
"name": "Merge All Paths",
"type": "n8n-nodes-base.merge",
"position": [
2752,
480
],
"parameters": {
"mode": "combine",
"options": {},
"combineBy": "combineByPosition",
"numberInputs": 4
},
"typeVersion": 3.2
},
{
"id": "e9f1de5a-1e17-49d1-b027-49cc4d40165d",
"name": "Audit Log",
"type": "n8n-nodes-base.dataTable",
"position": [
3200,
512
],
"parameters": {
"options": {},
"dataTableId": {
"__rl": true,
"mode": "name",
"value": "ModerationAuditLog"
}
},
"typeVersion": 1.1
},
{
"id": "39d416be-7c5f-4586-94c8-5801029c0591",
"name": "Prepare Audit Data",
"type": "n8n-nodes-base.code",
"position": [
2976,
512
],
"parameters": {
"jsCode": "// Prepare comprehensive audit log data\nconst items = $input.all();\nconst auditEntries = [];\n\nfor (const item of items) {\n const auditEntry = {\n timestamp: new Date().toISOString(),\n workflow_execution_id: $execution.id,\n workflow_path: item.json.workflow_path || 'unknown',\n \n // Validation results from Content Signal Agent\n validation_status: item.json.validation_status || item.json.status,\n content_id: item.json.content_id,\n content_type: item.json.content_type,\n content_text: item.json.content_text || item.json.content,\n \n // Governance decisions\n governance_decision: item.json.governance_decision || item.json.decision,\n policy_violations: item.json.policy_violations || [],\n severity_level: item.json.severity_level || item.json.severity,\n confidence_score: item.json.confidence_score || item.json.confidence,\n \n // Enforcement actions\n enforcement_action: item.json.enforcement_action || item.json.action,\n action_type: item.json.action_type,\n action_reason: item.json.action_reason || item.json.reason,\n \n // Escalation status\n escalation_required: item.json.escalation_required || false,\n escalation_status: item.json.escalation_status || 'none',\n escalation_notified: item.json.escalation_notified || false,\n \n // Additional metadata\n user_id: item.json.user_id,\n platform: item.json.platform,\n reviewed_by: item.json.reviewed_by || 'ai_agent',\n review_notes: item.json.review_notes || item.json.notes\n };\n \n auditEntries.push({ json: auditEntry });\n}\n\nreturn auditEntries;"
},
"typeVersion": 2
},
{
"id": "ede90078-271b-40b8-a67c-20fe3292102b",
"name": "Sticky Note",
"type": "n8n-nodes-base.stickyNote",
"position": [
864,
-288
],
"parameters": {
"color": 5,
"width": 448,
"height": 336,
"content": "## Prerequisites\nn8n account, OpenAI API key, Google Sheets or DB access, Gmail credentials, defined moderation policies.\n## Use Cases\nMarketplace listing moderation, enterprise HR review screening\n## Customization\nAdjust policy rules, add risk scoring, integrate Slack instead of Gmail\n## Benefits\nImproves moderation accuracy, reduces manual review, enforces governance consistency"
},
"typeVersion": 1
},
{
"id": "c57e0916-5c46-4ae8-bd79-5f478ed4aded",
"name": "Sticky Note1",
"type": "n8n-nodes-base.stickyNote",
"position": [
464,
-208
],
"parameters": {
"width": 336,
"height": 240,
"content": "## Setup Steps\n1. Connect OpenAI API credentials for AI agents.\n2. Configure Google Sheets or database for logging.\n3. Connect Gmail for escalation emails.\n4. Define moderation policies and routing rules.\n5. Activate webhook and test sample content."
},
"typeVersion": 1
},
{
"id": "b33ca13b-c8a1-4996-94fb-e821249b684c",
"name": "Sticky Note2",
"type": "n8n-nodes-base.stickyNote",
"position": [
-480,
-208
],
"parameters": {
"width": 896,
"height": 240,
"content": "## How It Works\nThis workflow automates end-to-end AI-driven content moderation for platforms managing user-generated content, including marketplaces, communities, and enterprise systems. It is designed for product, trust & safety, and governance teams seeking scalable, policy-aligned enforcement without subjective scoring. The workflow validates structured review, goal, and feedback data using a Performance Signal Agent that standardizes moderation signals and removes ambiguity. A Governance Agent then orchestrates policy enforcement, eligibility checks, escalation logic, and audit preparation. Content enters via webhook, is classified, validated, and routed by action type (approve, flag, escalate). Enforcement logic determines whether to store clean content, flag violations, or trigger escalation emails and team notifications. All actions are logged for traceability and compliance. This template solves inconsistent moderation decisions, lack of structured governance controls, and manual escalation overhead by embedding deterministic checkpoints, structured outputs, and audit-ready logging into a single automated pipeline."
},
"typeVersion": 1
},
{
"id": "92b3be9e-45f4-40cd-990f-083cbf89a9ef",
"name": "Sticky Note3",
"type": "n8n-nodes-base.stickyNote",
"position": [
1312,
112
],
"parameters": {
"color": 7,
"width": 512,
"height": 1008,
"content": "## Enforcement & Escalation\nWhat \u2013 Approve, flag, store, or escalate with notifications.\nWhy \u2013 Ensure consistent action handling and compliance tracking."
},
"typeVersion": 1
},
{
"id": "60d60bae-0daa-400b-9a3d-123e5138951b",
"name": "Sticky Note4",
"type": "n8n-nodes-base.stickyNote",
"position": [
320,
112
],
"parameters": {
"color": 7,
"width": 976,
"height": 992,
"content": "## Governance Orchestration\nWhat \u2013 Apply rule-based routing and agent-driven decision logic.\nWhy \u2013 Remove subjective scoring and standardize eligibility checks."
},
"typeVersion": 1
},
{
"id": "30600019-b906-4180-ad8f-b43f78cdb689",
"name": "Sticky Note5",
"type": "n8n-nodes-base.stickyNote",
"position": [
-528,
112
],
"parameters": {
"color": 7,
"width": 832,
"height": 944,
"content": "## Ingest & Validate\nWhat \u2013 Capture content via webhook and normalize signals using AI validation.\nWhy \u2013 Ensure structured, policy-aligned inputs before enforcement decisions."
},
"typeVersion": 1
},
{
"id": "4b9f91db-0447-4248-a8f8-6ebfd4b23617",
"name": "Sticky Note6",
"type": "n8n-nodes-base.stickyNote",
"position": [
1840,
112
],
"parameters": {
"color": 7,
"width": 1488,
"height": 992,
"content": "## Audit & Logging\nWhat \u2013 Merge results and generate structured audit logs.\nWhy \u2013 Maintain transparency, traceability, and review readiness."
},
"typeVersion": 1
}
],
"active": false,
"settings": {
"availableInMCP": false,
"executionOrder": "v1"
},
"versionId": "67b069b3-f40f-483f-b6ed-37a349ba1f04",
"connections": {
"Merge All Paths": {
"main": [
[
{
"node": "Prepare Audit Data",
"type": "main",
"index": 0
}
]
]
},
"Escalation Email": {
"main": [
[
{
"node": "Merge All Paths",
"type": "main",
"index": 3
}
]
]
},
"Governance Agent": {
"main": [
[
{
"node": "Route by Action Type",
"type": "main",
"index": 0
}
]
]
},
"Review Agent Tool": {
"ai_tool": [
[
{
"node": "Governance Agent",
"type": "ai_tool",
"index": 0
}
]
]
},
"Appeals Agent Tool": {
"ai_tool": [
[
{
"node": "Governance Agent",
"type": "ai_tool",
"index": 0
}
]
]
},
"Prepare Audit Data": {
"main": [
[
{
"node": "Audit Log",
"type": "main",
"index": 0
}
]
]
},
"Store Valid Content": {
"main": [
[
{
"node": "Merge All Paths",
"type": "main",
"index": 0
}
]
]
},
"Content Signal Agent": {
"main": [
[
{
"node": "Route by Validation Status",
"type": "main",
"index": 0
}
]
]
},
"Route by Action Type": {
"main": [
[
{
"node": "Store Flagged Content",
"type": "main",
"index": 0
}
],
[
{
"node": "Store Enforcement Actions",
"type": "main",
"index": 0
}
]
]
},
"Store Flagged Content": {
"main": [
[
{
"node": "Merge All Paths",
"type": "main",
"index": 1
}
]
]
},
"Enforcement Agent Tool": {
"ai_tool": [
[
{
"node": "Governance Agent",
"type": "ai_tool",
"index": 0
}
]
]
},
"Notify Moderation Team": {
"main": [
[
{
"node": "Merge All Paths",
"type": "main",
"index": 2
}
]
]
},
"Workflow Configuration": {
"main": [
[
{
"node": "Content Signal Agent",
"type": "main",
"index": 0
}
]
]
},
"Check Escalation Required": {
"main": [
[
{
"node": "Notify Moderation Team",
"type": "main",
"index": 0
},
{
"node": "Escalation Email",
"type": "main",
"index": 0
}
]
]
},
"OpenAI Model - Governance": {
"ai_languageModel": [
[
{
"node": "Governance Agent",
"type": "ai_languageModel",
"index": 0
}
]
]
},
"Store Enforcement Actions": {
"main": [
[
{
"node": "Check Escalation Required",
"type": "main",
"index": 0
}
]
]
},
"Content Moderation Webhook": {
"main": [
[
{
"node": "Workflow Configuration",
"type": "main",
"index": 0
}
]
]
},
"OpenAI Model - Review Tool": {
"ai_languageModel": [
[
{
"node": "Review Agent Tool",
"type": "ai_languageModel",
"index": 0
}
]
]
},
"Route by Validation Status": {
"main": [
[
{
"node": "Store Valid Content",
"type": "main",
"index": 0
}
],
[
{
"node": "Governance Agent",
"type": "main",
"index": 0
}
]
]
},
"OpenAI Model - Appeals Tool": {
"ai_languageModel": [
[
{
"node": "Appeals Agent Tool",
"type": "ai_languageModel",
"index": 0
}
]
]
},
"OpenAI Model - Content Signal": {
"ai_languageModel": [
[
{
"node": "Content Signal Agent",
"type": "ai_languageModel",
"index": 0
}
]
]
},
"Structured Output - Governance": {
"ai_outputParser": [
[
{
"node": "Governance Agent",
"type": "ai_outputParser",
"index": 0
}
]
]
},
"OpenAI Model - Enforcement Tool": {
"ai_languageModel": [
[
{
"node": "Enforcement Agent Tool",
"type": "ai_languageModel",
"index": 0
}
]
]
},
"Structured Output - Review Tool": {
"ai_outputParser": [
[
{
"node": "Review Agent Tool",
"type": "ai_outputParser",
"index": 0
}
]
]
},
"Structured Output - Appeals Tool": {
"ai_outputParser": [
[
{
"node": "Appeals Agent Tool",
"type": "ai_outputParser",
"index": 0
}
]
]
},
"Structured Output - Content Signal": {
"ai_outputParser": [
[
{
"node": "Content Signal Agent",
"type": "ai_outputParser",
"index": 0
}
]
]
},
"Structured Output - Enforcement Tool": {
"ai_outputParser": [
[
{
"node": "Enforcement Agent Tool",
"type": "ai_outputParser",
"index": 0
}
]
]
}
}
}
Credentials you'll need
Each integration node will prompt for credentials when you import. We strip credential IDs before publishing — you'll add your own.
openAiApislackOAuth2Api
For the full experience including quality scoring and batch install features for each workflow upgrade to Pro
About this workflow
This workflow automates end-to-end AI-driven content moderation for platforms managing user-generated content, including marketplaces, communities, and enterprise systems. It is designed for product, trust & safety, and governance teams seeking scalable, policy-aligned…
Source: https://n8n.io/workflows/13447/ — original creator credit. Request a take-down →
Related workflows
Workflows that share integrations, category, or trigger type with this one. All free to copy and import.
This workflow transforms natural language queries into research reports through a five-stage AI pipeline. When triggered via webhook (typically from Google Sheets using the companion [](https://gist.g
This workflow automates enterprise compliance governance using a multi-agent AI architecture. It targets compliance officers, legal teams, and risk managers who need continuous, jurisdiction-aware mon
This workflow automates student academic advising by deploying a multi-agent AI system that triages student queries, routes them intelligently, and escalates when human intervention is needed. Designe
This workflow automates comprehensive data validation and regulatory compliance reporting through intelligent AI-driven analysis. Designed for compliance officers, data governance teams, and regulator
This workflow automates platform trust and safety operations by deploying a multi-agent AI system that detects abuse signals, investigates behaviour, scores risk, checks policy compliance, and enforce