{
  "id": "wf_demo_refund",
  "name": "Refund request \u2014 unsafe retry",
  "active": false,
  "versionId": "retryproof-demo-v1",
  "nodes": [
    {
      "id": "webhook_refund",
      "name": "Refund webhook",
      "type": "n8n-nodes-base.webhook",
      "typeVersion": 2.1,
      "position": [
        180,
        300
      ],
      "parameters": {
        "httpMethod": "POST",
        "path": "refund-requested"
      }
    },
    {
      "id": "normalize_event",
      "name": "Normalize event",
      "type": "n8n-nodes-base.set",
      "typeVersion": 3.4,
      "position": [
        430,
        300
      ],
      "parameters": {
        "mode": "manual",
        "eventId": "={{ $json.event.id }}",
        "amount": "={{ $json.event.amount }}"
      }
    },
    {
      "id": "http_refund",
      "name": "Create refund",
      "type": "n8n-nodes-base.httpRequest",
      "typeVersion": 4.2,
      "position": [
        680,
        300
      ],
      "parameters": {
        "method": "POST",
        "url": "mock://refunds",
        "body": {
          "event_id": "={{ $json.event.id }}",
          "amount": "={{ $json.event.amount }}"
        }
      },
      "credentials": {
        "httpHeaderAuth": {
          "name": "<your credential>"
        }
      }
    },
    {
      "id": "respond_ok",
      "name": "Acknowledge",
      "type": "n8n-nodes-base.respondToWebhook",
      "typeVersion": 1.4,
      "position": [
        930,
        300
      ],
      "parameters": {
        "respondWith": "json",
        "received": true
      }
    }
  ],
  "connections": {
    "Refund webhook": {
      "main": [
        [
          {
            "node": "Normalize event",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Normalize event": {
      "main": [
        [
          {
            "node": "Create refund",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Create refund": {
      "main": [
        [
          {
            "node": "Acknowledge",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  },
  "settings": {
    "executionOrder": "v1"
  }
}