{
  "name": "Process WhatsApp PDFs with AWS Textract OCR via S3",
  "nodes": [
    {
      "id": "e7886fe8-d9c6-4b65-9670-1fe6f4fe3889",
      "name": "AWS GetDocumentAnalysis",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -1168,
        -448
      ]
    },
    {
      "id": "50ea7ddb-e2e3-4c57-be98-1f2db5669201",
      "name": "AWS StartDocumentAnalysis",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -1616,
        -448
      ]
    },
    {
      "id": "ac51229d-ec18-4900-a87f-e572a11ebf8f",
      "name": "Download File from S3",
      "type": "n8n-nodes-base.awsS3",
      "position": [
        -1840,
        -448
      ]
    },
    {
      "id": "5c690c78-dac9-4654-a6f2-4c69147f261d",
      "name": "Upload File to S3",
      "type": "n8n-nodes-base.awsS3",
      "position": [
        -2064,
        -448
      ]
    },
    {
      "id": "822414b6-a00b-4370-b435-a2361267b4f7",
      "name": "File Download",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -2288,
        -448
      ]
    },
    {
      "id": "74c15e4b-acc2-4e80-8001-b8592cf4aa59",
      "name": "Get PDF",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -2512,
        -448
      ]
    },
    {
      "id": "4b4920e8-2fa8-4bf1-913a-e658bea83736",
      "name": "WhatsApp Trigger",
      "type": "n8n-nodes-base.whatsAppTrigger",
      "position": [
        -2736,
        -448
      ]
    },
    {
      "id": "29c7c835-7a51-4cc9-abf9-9cf3cb9ce73c",
      "name": "Wait for Processing Time",
      "type": "n8n-nodes-base.wait",
      "position": [
        -1392,
        -448
      ]
    },
    {
      "id": "c6d13085-5dc3-4f5e-9085-bf9dd93d8102",
      "name": "Extract Text",
      "type": "n8n-nodes-base.code",
      "position": [
        -944,
        -448
      ]
    },
    {
      "id": "5751ca71-fb58-4506-947d-f95c9ef41a29",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -3616,
        -656
      ],
      "parameters": {
        "width": 752,
        "height": 528,
        "content": "## 🟨 **MAIN STICKY — WhatsApp PDF OCR Workflow**\n\n**How it Works**\n\nThis workflow automatically extracts text from PDF documents sent via WhatsApp. When a message containing a PDF arrives, the file is"
      }
    },
    {
      "id": "8eb1a8b8-a3a9-4f77-b6d5-2a92e1f7919d",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -2800,
        -656
      ],
      "parameters": {
        "width": 656,
        "height": 528,
        "content": "## Whatsapp Input"
      }
    },
    {
      "id": "dc4fc46b-93d3-4193-ae55-febb76236415",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -2128,
        -656
      ],
      "parameters": {
        "width": 432,
        "height": 528,
        "content": "## AWS S3 Handling"
      }
    },
    {
      "id": "252dd1ba-471d-4cb8-9dad-64c899098a6e",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1664,
        -656
      ],
      "parameters": {
        "width": 640,
        "height": 528,
        "content": "## AWS Textract Processing"
      }
    },
    {
      "id": "137923f7-dd0a-4138-b4b8-b298f29a6d49",
      "name": "Sticky Note4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1008,
        -656
      ],
      "parameters": {
        "width": 256,
        "height": 528,
        "content": "## Output Cleanup"
      }
    }
  ],
  "connections": {
    "Get PDF": {
      "main": [
        [
          {
            "node": "File Download",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Extract Text": {
      "main": [
        []
      ]
    },
    "File Download": {
      "main": [
        [
          {
            "node": "Upload File to S3",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "WhatsApp Trigger": {
      "main": [
        [
          {
            "node": "Get PDF",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Upload File to S3": {
      "main": [
        [
          {
            "node": "Download File from S3",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Download File from S3": {
      "main": [
        [
          {
            "node": "AWS StartDocumentAnalysis",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "AWS GetDocumentAnalysis": {
      "main": [
        [
          {
            "node": "Extract Text",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Wait for Processing Time": {
      "main": [
        [
          {
            "node": "AWS GetDocumentAnalysis",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "AWS StartDocumentAnalysis": {
      "main": [
        [
          {
            "node": "Wait for Processing Time",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}