{
  "name": "FinOps Studio — Stripe Paid Invoice to Peppol E-Invoice XML + German DATEV Buchungsstapel CSV",
  "nodes": [
    {
      "parameters": {
        "events": ["invoice.paid"]
      },
      "id": "1",
      "name": "Stripe Invoice Paid Trigger",
      "type": "n8n-nodes-base.stripeTrigger",
      "typeVersion": 1,
      "position": [200, 300]
    },
    {
      "parameters": {
        "method": "POST",
        "url": "https://api.apify.com/v2/acts/finops_studio~eu-einvoice-xml-generator/run-sync-get-dataset-items",
        "sendHeaders": true,
        "headerParameters": {
          "parameters": [
            { "name": "Authorization", "value": "Bearer YOUR_APIFY_API_TOKEN" }
          ]
        },
        "sendBody": true,
        "specifyBody": "json",
        "jsonBody": "{\n  \"format\": \"peppol-ubl-3.0\",\n  \"invoiceNumber\": \"INV-2026-1001\",\n  \"currency\": \"EUR\",\n  \"seller\": { \"name\": \"SaaS Cloud GmbH\", \"vatId\": \"DE123456789\", \"country\": \"DE\", \"city\": \"Berlin\", \"postalCode\": \"10115\", \"street\": \"Torstr. 1\" },\n  \"buyer\": { \"name\": \"EuroClient NV\", \"vatId\": \"BE0123456789\", \"country\": \"BE\", \"city\": \"Brussels\", \"postalCode\": \"1000\", \"street\": \"Rue de la Loi 10\" },\n  \"lines\": [{ \"description\": \"Annual Enterprise Plan\", \"quantity\": 1, \"unitPrice\": \"1000.00\", \"vatRate\": 19 }]\n}"
      },
      "id": "2",
      "name": "Generate EN 16931 Peppol / XRechnung XML",
      "type": "n8n-nodes-base.httpRequest",
      "typeVersion": 4.2,
      "position": [520, 200]
    },
    {
      "parameters": {
        "method": "POST",
        "url": "https://api.apify.com/v2/acts/finops_studio~datev-buchungsstapel-generator/run-sync-get-dataset-items",
        "sendHeaders": true,
        "headerParameters": {
          "parameters": [
            { "name": "Authorization", "value": "Bearer YOUR_APIFY_API_TOKEN" }
          ]
        },
        "sendBody": true,
        "specifyBody": "json",
        "jsonBody": "{\n  \"skr\": \"SKR03\",\n  \"consultantNumber\": \"12345\",\n  \"clientNumber\": \"10001\",\n  \"bookings\": [{ \"date\": \"2026-11-12\", \"amount\": \"1190.00\", \"vatRate\": 19, \"documentRef\": \"INV-2026-1001\", \"description\": \"EuroClient NV Subscription\" }]\n}"
      },
      "id": "3",
      "name": "Generate DATEV EXTF v700 CSV for Steuerberater",
      "type": "n8n-nodes-base.httpRequest",
      "typeVersion": 4.2,
      "position": [520, 420]
    }
  ],
  "connections": {
    "Stripe Invoice Paid Trigger": {
      "main": [
        [
          { "node": "Generate EN 16931 Peppol / XRechnung XML", "type": "main", "index": 0 },
          { "node": "Generate DATEV EXTF v700 CSV for Steuerberater", "type": "main", "index": 0 }
        ]
      ]
    }
  }
}
