{
  "name": "Manage KlickTipp contacts via Telegram Bot with GPT-5 mini agent",
  "nodes": [
    {
      "id": "9989921d-2df3-40fe-9f0a-090e637763d8",
      "name": "When chat message received",
      "type": "@n8n/n8n-nodes-langchain.chatTrigger",
      "position": [
        1680,
        -512
      ]
    },
    {
      "id": "25d78214-6214-489f-ab3f-c7113b813838",
      "name": "OpenAI Chat Model",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        2560,
        -496
      ]
    },
    {
      "id": "5b7ea68f-8a51-4413-af04-3cca7f1ca86f",
      "name": "Sticky Note4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        2512,
        -976
      ],
      "parameters": {
        "width": 600,
        "height": 636,
        "content": "## 2. Connect any Agent with a KlickTipp tools"
      }
    },
    {
      "id": "92ab0e41-049b-43ac-8f39-e5b02e7562e7",
      "name": "Simple Memory",
      "type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
      "position": [
        2736,
        -496
      ]
    },
    {
      "id": "0069ee54-c56f-4e45-ab66-8f02bb3b312b",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1040,
        -976
      ],
      "parameters": {
        "width": 580,
        "height": 2056,
        "content": "Community Node Disclaimer: As this workflow relies on a community node, it is limited to self-hosted environments.\n\n### How It Works\n\n**AI Agent and KlickTipp Tools Integration via Telegram:**\nThis co"
      }
    },
    {
      "id": "20256111-b1fe-44c3-a2f9-ed1525b9e84b",
      "name": "List Contacts",
      "type": "n8n-nodes-klicktipp.klicktippTool",
      "position": [
        2672,
        -192
      ]
    },
    {
      "id": "35250ba6-bad1-4926-98ff-007e2f60ed21",
      "name": "Get Contact",
      "type": "n8n-nodes-klicktipp.klicktippTool",
      "position": [
        2928,
        -192
      ]
    },
    {
      "id": "8aebefc8-34b7-4f66-b773-772ccf3deebb",
      "name": "Get Contact ID",
      "type": "n8n-nodes-klicktipp.klicktippTool",
      "position": [
        3184,
        -192
      ]
    },
    {
      "id": "8ff3ff81-0476-49d1-9627-840e12e50761",
      "name": "List Tagged Contacts",
      "type": "n8n-nodes-klicktipp.klicktippTool",
      "position": [
        3456,
        -192
      ]
    },
    {
      "id": "f4177135-1a7e-4245-8931-0ac75465756f",
      "name": "List Tags",
      "type": "n8n-nodes-klicktipp.klicktippTool",
      "position": [
        3984,
        -192
      ]
    },
    {
      "id": "8e59d336-79ad-4f6e-8256-f44ab9e2ea27",
      "name": "Update Contact",
      "type": "n8n-nodes-klicktipp.klicktippTool",
      "position": [
        2800,
        -192
      ]
    },
    {
      "id": "6463b625-e410-48cd-97e1-88b0d97b32ea",
      "name": "Delete Contact",
      "type": "n8n-nodes-klicktipp.klicktippTool",
      "position": [
        3056,
        -192
      ]
    },
    {
      "id": "9fbb16a9-6e96-4e75-a1a5-c096fddc1951",
      "name": "Unsubscribe Contact",
      "type": "n8n-nodes-klicktipp.klicktippTool",
      "position": [
        3312,
        -192
      ]
    },
    {
      "id": "3c620b1b-55e5-40b4-b371-10dde8c1cefa",
      "name": "Create Tag",
      "type": "n8n-nodes-klicktipp.klicktippTool",
      "position": [
        4112,
        -192
      ]
    },
    {
      "id": "c451d3cb-6323-432c-a98b-8a8c10d8d386",
      "name": "Get Tag",
      "type": "n8n-nodes-klicktipp.klicktippTool",
      "position": [
        4240,
        -192
      ]
    },
    {
      "id": "46150de8-a733-4d60-ae45-2019913fce9c",
      "name": "Delete Tag",
      "type": "n8n-nodes-klicktipp.klicktippTool",
      "position": [
        4368,
        -192
      ]
    },
    {
      "id": "4aac4674-be12-4126-9bbd-8bc570c296af",
      "name": "Update Tag",
      "type": "n8n-nodes-klicktipp.klicktippTool",
      "position": [
        4496,
        -192
      ]
    },
    {
      "id": "7477e0b7-ace7-42f7-8cb8-8ed997592d85",
      "name": "List Opt-in Processes",
      "type": "n8n-nodes-klicktipp.klicktippTool",
      "position": [
        1664,
        -192
      ]
    },
    {
      "id": "43bda647-d273-4768-a429-0a8abff9bec0",
      "name": "Get Opt-in Process",
      "type": "n8n-nodes-klicktipp.klicktippTool",
      "position": [
        1792,
        -192
      ]
    },
    {
      "id": "88414a45-3d7e-41db-8845-1a31f163ab87",
      "name": "List Data Fields",
      "type": "n8n-nodes-klicktipp.klicktippTool",
      "position": [
        2000,
        -192
      ]
    },
    {
      "id": "98642fcd-bb96-4883-856b-7affb03ddffd",
      "name": "Get Data Field",
      "type": "n8n-nodes-klicktipp.klicktippTool",
      "position": [
        2128,
        -192
      ]
    },
    {
      "id": "004e895c-361b-464d-b258-889363d369bb",
      "name": "Untag Contact",
      "type": "n8n-nodes-klicktipp.klicktippTool",
      "position": [
        2336,
        -192
      ]
    },
    {
      "id": "15134ced-fb09-47f2-a818-4885d62ab47b",
      "name": "Tag Contact",
      "type": "n8n-nodes-klicktipp.klicktippTool",
      "position": [
        2480,
        -192
      ]
    },
    {
      "id": "79a23888-f41f-4a9c-a045-cefcf7abfb15",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1632,
        -320
      ],
      "parameters": {
        "width": 300,
        "height": 288,
        "content": "## Opt-in Processes\n"
      }
    },
    {
      "id": "155a5b36-8de4-4f74-bf00-37bc62b0c081",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        3952,
        -320
      ],
      "parameters": {
        "width": 668,
        "height": 288,
        "content": "## Tag Operations\n"
      }
    },
    {
      "id": "ecd5521a-899e-4010-b3a8-d4ff6b701f8a",
      "name": "Get Redirect URL",
      "type": "n8n-nodes-klicktipp.klicktippTool",
      "position": [
        3792,
        -192
      ]
    },
    {
      "id": "093cb61d-f110-4920-a2cb-b9b4c6681060",
      "name": "Sticky Note6",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1952,
        -320
      ],
      "parameters": {
        "width": 300,
        "height": 288,
        "content": "## Data Fields\n"
      }
    },
    {
      "id": "18244673-ef94-4d9c-9a7b-f1d4ff460812",
      "name": "Sticky Note7",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        2272,
        -320
      ],
      "parameters": {
        "width": 332,
        "height": 288,
        "content": "## Contact Tagging\n"
      }
    },
    {
      "id": "a37cbe4b-7ad2-483c-be0e-ca52b67753b3",
      "name": "Sticky Note8",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        3744,
        -320
      ],
      "parameters": {
        "width": 184,
        "height": 288,
        "content": "## Redirects\n"
      }
    },
    {
      "id": "b0775e10-e8ed-4fed-bc11-c5674f36ccd4",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        2624,
        -320
      ],
      "parameters": {
        "width": 1104,
        "height": 292,
        "content": "## Contact Management"
      }
    },
    {
      "id": "d3537987-67eb-45bd-8100-0c39635bf112",
      "name": "Timestamp to date",
      "type": "@n8n/n8n-nodes-langchain.toolCode",
      "position": [
        4704,
        -192
      ]
    },
    {
      "id": "61919f98-d3bc-463d-ac83-c9cefc8113a5",
      "name": "Sticky Note5",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        4640,
        -320
      ],
      "parameters": {
        "width": 368,
        "height": 288,
        "content": "## Additional Tools"
      }
    },
    {
      "id": "15729f44-2d72-42a1-9255-b100c685d8af",
      "name": "Date to timestamp",
      "type": "@n8n/n8n-nodes-langchain.toolCode",
      "position": [
        4864,
        -192
      ]
    },
    {
      "id": "017aaa9a-0315-4e58-aa95-b853b132a68d",
      "name": "Telegram Trigger",
      "type": "n8n-nodes-base.telegramTrigger",
      "position": [
        1680,
        -848
      ]
    },
    {
      "id": "43e27fbf-5dd2-490a-af4d-4db8559fc499",
      "name": "Download voice file",
      "type": "n8n-nodes-base.telegram",
      "position": [
        2128,
        -944
      ]
    },
    {
      "id": "e5a8bd05-e780-46b3-802a-23272a2e4bea",
      "name": "Transcribe audio",
      "type": "@n8n/n8n-nodes-langchain.openAi",
      "position": [
        2352,
        -944
      ]
    },
    {
      "id": "2c4490d8-0df0-46df-a833-b166058057b4",
      "name": "Telegram",
      "type": "n8n-nodes-base.telegram",
      "position": [
        3424,
        -944
      ]
    },
    {
      "id": "24fed1b4-e71c-4a4a-a9eb-f6150776ee8d",
      "name": "No Operation, do nothing",
      "type": "n8n-nodes-base.noOp",
      "position": [
        3424,
        -512
      ]
    },
    {
      "id": "348c9850-4a12-4f03-a09a-5d46bcde4ef2",
      "name": "Sticky Note9",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1632,
        -976
      ],
      "parameters": {
        "width": 868,
        "height": 380,
        "content": "## 1.  Message from the Telegram bot\n"
      }
    },
    {
      "id": "c5a1203d-c011-4ecf-bc11-615e390f58c5",
      "name": "Sticky Note10",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1632,
        -576
      ],
      "parameters": {
        "width": 868,
        "height": 236,
        "content": "## 1.  Message from the n8n chat\n"
      }
    },
    {
      "id": "0479362b-ca2c-4aa9-ad53-721e91950df5",
      "name": "Sticky Note11",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        3120,
        -976
      ],
      "parameters": {
        "width": 476,
        "height": 636,
        "content": "## 3. Output"
      }
    },
    {
      "id": "63ba982b-6c63-4af8-b1c3-135ed49a721e",
      "name": "KlickTipp Agent",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        2736,
        -736
      ]
    },
    {
      "id": "8df2a333-e451-46a9-b429-36bb5fa66c95",
      "name": "Set text from the n8n chat",
      "type": "n8n-nodes-base.set",
      "position": [
        2352,
        -512
      ]
    },
    {
      "id": "7081bd79-6837-4f2d-b1f2-f74840a46ac8",
      "name": "Set text from Telegram",
      "type": "n8n-nodes-base.set",
      "position": [
        2352,
        -752
      ]
    },
    {
      "id": "e0340f07-3c1f-427b-8b4d-c6e1ab28cf9f",
      "name": "Check the message type",
      "type": "n8n-nodes-base.switch",
      "position": [
        1904,
        -848
      ]
    },
    {
      "id": "7633d54b-5675-42ad-95ca-9c13c47c44a0",
      "name": "Check the source",
      "type": "n8n-nodes-base.switch",
      "position": [
        3200,
        -736
      ]
    },
    {
      "id": "1714cac9-abd2-4ae0-8219-f00cea32a69d",
      "name": "Add or Update Contact",
      "type": "n8n-nodes-klicktipp.klicktippTool",
      "position": [
        3600,
        -192
      ]
    }
  ],
  "connections": {
    "Get Tag": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "List Tags": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Create Tag": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Delete Tag": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Update Tag": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Get Contact": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Tag Contact": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "List Contacts": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Simple Memory": {
      "ai_memory": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_memory",
            "index": 0
          }
        ]
      ]
    },
    "Untag Contact": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Delete Contact": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Get Contact ID": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Get Data Field": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Update Contact": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "KlickTipp Agent": {
      "main": [
        [
          {
            "node": "Check the source",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Check the source": {
      "main": [
        [
          {
            "node": "Telegram",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "No Operation, do nothing",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get Redirect URL": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "List Data Fields": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Telegram Trigger": {
      "main": [
        [
          {
            "node": "Check the message type",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Transcribe audio": {
      "main": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Date to timestamp": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model": {
      "ai_languageModel": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Timestamp to date": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Get Opt-in Process": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Download voice file": {
      "main": [
        [
          {
            "node": "Transcribe audio",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Unsubscribe Contact": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "List Tagged Contacts": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Add or Update Contact": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "List Opt-in Processes": {
      "ai_tool": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Check the message type": {
      "main": [
        [
          {
            "node": "Download voice file",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Set text from Telegram",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Set text from Telegram": {
      "main": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Set text from the n8n chat": {
      "main": [
        [
          {
            "node": "KlickTipp Agent",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "When chat message received": {
      "main": [
        [
          {
            "node": "Set text from the n8n chat",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}