{
  "name": "00 \u2014 Reset documents table",
  "settings": {
    "executionOrder": "v1"
  },
  "nodes": [
    {
      "parameters": {
        "httpMethod": "POST",
        "path": "reset-documents",
        "responseMode": "lastNode",
        "options": {}
      },
      "id": "a0000000-0000-4000-8000-000000000001",
      "name": "Webhook",
      "type": "n8n-nodes-base.webhook",
      "typeVersion": 2,
      "position": [
        -400,
        0
      ]
    },
    {
      "parameters": {
        "operation": "delete",
        "tableId": "documents",
        "filterType": "manual",
        "matchType": "allFilters",
        "filters": {
          "conditions": [
            {
              "keyName": "id",
              "condition": "gte",
              "keyValue": "1"
            }
          ]
        }
      },
      "id": "a0000000-0000-4000-8000-000000000002",
      "name": "Delete All Rows",
      "type": "n8n-nodes-base.supabase",
      "typeVersion": 1,
      "position": [
        -180,
        0
      ],
      "credentials": {
        "supabaseApi": {
          "name": "<your credential>"
        }
      },
      "notes": "Empties the vector store so an ingestion can be replayed without duplicating chunks. Destructive by design \u2014 run it only before a full re-ingest."
    }
  ],
  "connections": {
    "Webhook": {
      "main": [
        [
          {
            "node": "Delete All Rows",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}