{
  "name": "Spurvik EU AI Act Guard — Art. 50 Notice, HMAC Digest & Approval Gate",
  "nodes": [
    {
      "parameters": {
        "content": "## Spurvik EU AI Act Guard Starter (`n8n-nodes-spurvik@1.0.4`)\n1. Install community node **`n8n-nodes-spurvik@1.0.4`** (*Settings → Community nodes*).\n2. Open each Spurvik node and select a **`spurvikApi`** credential with a **Signing Secret** (`>= 16` chars). Add a **Slack Webhook URL** on that credential (and replace `callbackBaseUrl` on node 3 with your own endpoint) before testing the approval branch.\n3. **Optional EU Console Sync**: Set a **Spurvik Console API Key** (`https://console.spurvik.com/signup` — Free €0 for 10k events/mo · Pro €19/mo) on `spurvikApi` to sync hashed receipts and approval events to `fra1`.\n4. **n8n Execution Retention**: Spurvik nodes omit prompt fields from their node output, but n8n saves incoming node inputs on executions by default — set `EXECUTIONS_DATA_SAVE_ON_SUCCESS=none` and `EXECUTIONS_DATA_SAVE_MANUAL_EXECUTIONS=false` on your n8n instance.",
        "height": 260,
        "width": 680
      },
      "id": "a1c0b810-1111-4c00-8000-000000000001",
      "name": "Setup Notes",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [220, 60]
    },
    {
      "parameters": {},
      "id": "a1c0b810-1111-4c00-8000-000000000002",
      "name": "When clicking 'Test workflow'",
      "type": "n8n-nodes-base.manualTrigger",
      "typeVersion": 1,
      "position": [220, 420]
    },
    {
      "parameters": {
        "assignments": {
          "assignments": [
            {
              "id": "f1",
              "name": "promptText",
              "value": "Refund order #4821 for EUR 320 and notify the customer.",
              "type": "string"
            },
            {
              "id": "f2",
              "name": "outputText",
              "value": "I have prepared refund #4821 (EUR 320) and queued it for human review.",
              "type": "string"
            },
            {
              "id": "f3",
              "name": "requiresApproval",
              "value": true,
              "type": "boolean"
            }
          ]
        },
        "options": {}
      },
      "id": "a1c0b810-1111-4c00-8000-000000000003",
      "name": "Sample AI Step Output",
      "type": "n8n-nodes-base.set",
      "typeVersion": 3.4,
      "position": [440, 420]
    },
    {
      "parameters": {
        "operation": "art12_hmac_log",
        "systemName": "Support Assistant",
        "inputField": "promptText",
        "consoleBaseUrl": "https://console.spurvik.com",
        "passThroughFields": ""
      },
      "id": "a1c0b810-1111-4c00-8000-000000000004",
      "name": "1. Record HMAC-SHA256 Digest (No Prompt in Output)",
      "type": "n8n-nodes-spurvik.spurvikEuAiActGuard",
      "typeVersion": 1,
      "position": [720, 300]
    },
    {
      "parameters": {
        "operation": "art50_disclosure",
        "systemName": "Support Assistant",
        "inputField": "promptText",
        "outputField": "outputText",
        "noticeText": "",
        "consoleBaseUrl": "https://console.spurvik.com",
        "passThroughFields": "requiresApproval"
      },
      "id": "a1c0b810-1111-4c00-8000-000000000005",
      "name": "2. Prepend Art. 50(1) AI Interaction Notice",
      "type": "n8n-nodes-spurvik.spurvikEuAiActGuard",
      "typeVersion": 1,
      "position": [720, 520]
    },
    {
      "parameters": {
        "conditions": {
          "options": {
            "caseSensitive": true,
            "leftValue": "",
            "typeValidation": "strict",
            "version": 2
          },
          "conditions": [
            {
              "id": "c1",
              "leftValue": "={{ $json.requiresApproval }}",
              "rightValue": true,
              "operator": {
                "type": "boolean",
                "operation": "true",
                "singleValue": true
              }
            }
          ],
          "combinator": "and"
        },
        "options": {}
      },
      "id": "a1c0b810-1111-4c00-8000-000000000006",
      "name": "Approval Required?",
      "type": "n8n-nodes-base.if",
      "typeVersion": 2.2,
      "position": [980, 520]
    },
    {
      "parameters": {
        "operation": "art14_ask_human",
        "systemName": "Support Assistant",
        "channel": "slack",
        "approverTarget": "",
        "callbackBaseUrl": "https://your-service.example.com/api/spurvik-gate",
        "actionName": "billing.refund",
        "actionSummary": "Refund order #4821 (EUR 320) awaiting human sign-off",
        "consoleBaseUrl": "https://console.spurvik.com",
        "passThroughFields": ""
      },
      "id": "a1c0b810-1111-4c00-8000-000000000007",
      "name": "3. Send Signed Slack Approval Links",
      "type": "n8n-nodes-spurvik.spurvikEuAiActGuard",
      "typeVersion": 1,
      "position": [1240, 460]
    }
  ],
  "connections": {
    "When clicking 'Test workflow'": {
      "main": [
        [
          {
            "node": "Sample AI Step Output",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Sample AI Step Output": {
      "main": [
        [
          {
            "node": "1. Record HMAC-SHA256 Digest (No Prompt in Output)",
            "type": "main",
            "index": 0
          },
          {
            "node": "2. Prepend Art. 50(1) AI Interaction Notice",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "2. Prepend Art. 50(1) AI Interaction Notice": {
      "main": [
        [
          {
            "node": "Approval Required?",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Approval Required?": {
      "main": [
        [
          {
            "node": "3. Send Signed Slack Approval Links",
            "type": "main",
            "index": 0
          }
        ],
        []
      ]
    }
  },
  "pinData": {},
  "settings": {
    "executionOrder": "v1"
  },
  "meta": {
    "templateCredsSetupCompleted": false
  }
}
