{
  "name": "Rapportage",
  "nodes": [
    {
      "parameters": {},
      "type": "n8n-nodes-base.scheduleTrigger",
      "typeVersion": 1,
      "position": [250, 300],
      "id": "schedule-1",
      "name": "Dagelijkse trigger"
    },
    {
      "parameters": {
        "url": "https://api.example.com/metrics",
        "options": {}
      },
      "type": "n8n-nodes-base.httpRequest",
      "typeVersion": 1,
      "position": [450, 300],
      "id": "http-1",
      "name": "Haal metrics"
    },
    {
      "parameters": {
        "jsCode": "const metrics = $json[0].json;\nconst summary = {\n  date: new Date().toISOString().split('T')[0],\n  total: metrics.length,\n  avg: metrics.reduce((a, b) => a + b.value, 0) / metrics.length\n};\nreturn [{ json: summary }];"
      },
      "type": "n8n-nodes-base.code",
      "typeVersion": 1,
      "position": [650, 300],
      "id": "code-1",
      "name": "Samenvatting"
    },
    {
      "parameters": {
        "message": "Rapportage van {{ $json.date }}: {{ $json.total }} items, gemiddelde {{ $json.avg }}."
      },
      "type": "n8n-nodes-base.slack",
      "typeVersion": 1,
      "position": [850, 300],
      "id": "slack-1",
      "name": "Post naar Slack"
    }
  ],
  "connections": {
    "Dagelijkse trigger": {
      "main": [[{"node": "Haal metrics", "type": "main", "index": 0}]]
    },
    "Haal metrics": {
      "main": [[{"node": "Samenvatting", "type": "main", "index": 0}]]
    },
    "Samenvatting": {
      "main": [[{"node": "Post naar Slack", "type": "main", "index": 0}]]
    }
  },
  "settings": {
    "executionOrder": "v1"
  },
  "tags": []
}
