{
  "workflow": {
    "id": 2166,
    "name": "Watchdog: Auto Resume Workflows",
    "views": 1134,
    "recentViews": 0,
    "totalViews": 1134,
    "createdAt": "2024-03-06T23:01:10.753Z",
    "description": "If you have multiple users managing workflows, there may come a time where a user “accidentally” turns off a workflow. Or, if you have workflows that automatically turn off other workflows, that code might “accidentally” turn off the wrong one.\n\nIn either case, here’s a workflow that can attempt to “auto-start” accidentally disabled workflows:\n![image.png](fileId:776)\n\nHow it works:\n\nWhen activated, then every 4 hours, the workflow will search all other workflows that have the `auto_resume:true` tag present.\nIf any other workflow has `auto_resume:true` set but is currently turned off, then this workflow will turn it back on.\n\nOf course, this watchdog won’t work if the watchdog workflow is turned off. That said, we’ve found this useful in recovering from accidental actions that cause production workflows to be turned off.",
    "workflow": {
      "id": "kZarev2IMUaKHhCI",
      "meta": {
        "instanceId": "f4b99447bb6b56ad425b30ab755dc982ee1c258e7ce783958190eabedd1bcbb0"
      },
      "name": "Auto - Resume Disabled Workflows",
      "tags": [
        {
          "id": "YZS563bPtiBYp1aL",
          "name": "auto_resume:true",
          "createdAt": "2024-02-29T19:38:26.858Z",
          "updatedAt": "2024-02-29T19:38:26.858Z"
        },
        {
          "id": "53XXAtg9v7XIaREI",
          "name": "owner:darien",
          "createdAt": "2024-02-10T03:20:58.515Z",
          "updatedAt": "2024-02-10T03:20:58.515Z"
        }
      ],
      "nodes": [
        {
          "id": "fc7224f0-96d6-4c6d-a7c5-afbd49d60fc8",
          "name": "When clicking \"Test workflow\"",
          "type": "n8n-nodes-base.manualTrigger",
          "position": [
            820,
            700
          ],
          "parameters": {},
          "typeVersion": 1
        },
        {
          "id": "50661eea-325f-4131-92f6-0e3112ea6714",
          "name": "Get Auto Resume Workflows",
          "type": "n8n-nodes-base.n8n",
          "position": [
            1040,
            600
          ],
          "parameters": {
            "filters": {
              "tags": "auto_resume:true"
            }
          },
          "credentials": {
            "n8nApi": {
              "id": "credential-id",
              "name": "n8nApi Credential"
            }
          },
          "retryOnFail": true,
          "typeVersion": 1
        },
        {
          "id": "3c845ca2-4a6d-40ed-ad11-b92c425f852d",
          "name": "Find Deactivated Workflows",
          "type": "n8n-nodes-base.filter",
          "position": [
            1260,
            600
          ],
          "parameters": {
            "options": {},
            "conditions": {
              "options": {
                "leftValue": "",
                "caseSensitive": true,
                "typeValidation": "strict"
              },
              "combinator": "and",
              "conditions": [
                {
                  "id": "ce7b707c-d74e-4ca8-8081-53b15ff3f8a3",
                  "operator": {
                    "type": "boolean",
                    "operation": "false",
                    "singleValue": true
                  },
                  "leftValue": "={{ $json.active }}",
                  "rightValue": ""
                }
              ]
            }
          },
          "typeVersion": 2
        },
        {
          "id": "74b79f56-532e-4446-9b28-77874098ba10",
          "name": "Schedule Trigger",
          "type": "n8n-nodes-base.scheduleTrigger",
          "position": [
            820,
            520
          ],
          "parameters": {
            "rule": {
              "interval": [
                {
                  "field": "hours",
                  "hoursInterval": 4
                }
              ]
            }
          },
          "notesInFlow": false,
          "typeVersion": 1.1
        },
        {
          "id": "318960c8-e2bb-4486-ad5a-8c3a7e6db8a3",
          "name": "Activate Workflow",
          "type": "n8n-nodes-base.n8n",
          "position": [
            1460,
            600
          ],
          "parameters": {
            "operation": "activate",
            "workflowId": {
              "__rl": true,
              "mode": "id",
              "value": "={{ $json.id }}"
            }
          },
          "credentials": {
            "n8nApi": {
              "id": "credential-id",
              "name": "n8nApi Credential"
            }
          },
          "retryOnFail": true,
          "typeVersion": 1
        }
      ],
      "active": true,
      "pinData": {},
      "settings": {
        "executionOrder": "v1"
      },
      "versionId": "ff4414a4-de17-43a6-9da2-144a6e4cb773",
      "connections": {
        "Schedule Trigger": {
          "main": [
            [
              {
                "node": "Get Auto Resume Workflows",
                "type": "main",
                "index": 0
              }
            ]
          ]
        },
        "Get Auto Resume Workflows": {
          "main": [
            [
              {
                "node": "Find Deactivated Workflows",
                "type": "main",
                "index": 0
              }
            ]
          ]
        },
        "Find Deactivated Workflows": {
          "main": [
            [
              {
                "node": "Activate Workflow",
                "type": "main",
                "index": 0
              }
            ]
          ]
        },
        "When clicking \"Test workflow\"": {
          "main": [
            [
              {
                "node": "Get Auto Resume Workflows",
                "type": "main",
                "index": 0
              }
            ]
          ]
        }
      }
    },
    "lastUpdatedBy": 16,
    "workflowInfo": {
      "nodeCount": 5,
      "nodeTypes": {
        "n8n-nodes-base.n8n": {
          "count": 2
        },
        "n8n-nodes-base.filter": {
          "count": 1
        },
        "n8n-nodes-base.manualTrigger": {
          "count": 1
        },
        "n8n-nodes-base.scheduleTrigger": {
          "count": 1
        }
      }
    },
    "status": "published",
    "readyToDemo": null,
    "user": {
      "name": "Darien Kindlund",
      "username": "dkindlund",
      "bio": "15+ years in Security Research. Built various n8n automations to leverage LLMs for advanced research and analysis.",
      "verified": false,
      "links": [
        "https://darien.kindlund.com"
      ],
      "avatar": "https://gravatar.com/avatar/78b885c599fd95ff121b86393f5621d6db0430aa9c28d0aee0fde0202642fda6?r=pg&d=retro&size=200"
    },
    "nodes": [
      {
        "id": 826,
        "icon": "file:n8n.svg",
        "name": "n8n-nodes-base.n8n",
        "codex": {
          "data": {
            "alias": [
              "Workflow",
              "Execution"
            ],
            "resources": {
              "primaryDocumentation": [
                {
                  "url": "https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.n8n/"
                }
              ],
              "credentialDocumentation": [
                {
                  "url": "https://docs.n8n.io/api/authentication/"
                }
              ]
            },
            "categories": [
              "Development",
              "Core Nodes"
            ],
            "nodeVersion": "1.0",
            "codexVersion": "1.0",
            "subcategories": {
              "Core Nodes": [
                "Helpers",
                "Other Trigger Nodes"
              ]
            }
          }
        },
        "group": "[\"transform\"]",
        "defaults": {
          "name": "n8n"
        },
        "iconData": {
          "type": "file",
          "fileBuffer": "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGZpbGw9Im5vbmUiIHZpZXdCb3g9IjAgMCAyMzAgMTIwIj48cGF0aCBmaWxsPSIjRUE0QjcxIiBmaW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jI3IDAgMTItNS4zNzMgMTItMTJzLTUuMzczLTEyLTEyLTEyLTEyIDUuMzczLTEyIDEyIDUuMzczIDEyIDEyIDEyTTI0IDcyYzYuNjI3IDAgMTItNS4zNzMgMTItMTJzLTUuMzczLTEyLTEyLTEyLTEyIDUuMzczLTEyIDEyIDUuMzczIDEyIDEyIDEybTcyLTEyYzAgNi42MjctNS4zNzMgMTItMTIgMTJzLTEyLTUuMzczLTEyLTEyIDUuMzczLTEyIDEyLTEyIDEyIDUuMzczIDEyIDEybTk2IDM2YzAgNi42MjctNS4zNzMgMTItMTIgMTJzLTEyLTUuMzczLTEyLTEyIDUuMzczLTEyIDEyLTEyIDEyIDUuMzczIDEyIDEyIiBjbGlwLXJ1bGU9ImV2ZW5vZGQiLz48L3N2Zz4="
        },
        "displayName": "n8n",
        "typeVersion": 1,
        "nodeCategories": [
          {
            "id": 5,
            "name": "Development"
          },
          {
            "id": 9,
            "name": "Core Nodes"
          }
        ]
      },
      {
        "id": 838,
        "icon": "fa:mouse-pointer",
        "name": "n8n-nodes-base.manualTrigger",
        "codex": {
          "data": {
            "resources": {
              "generic": [],
              "primaryDocumentation": [
                {
                  "url": "https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.manualworkflowtrigger/"
                }
              ]
            },
            "categories": [
              "Core Nodes"
            ],
            "nodeVersion": "1.0",
            "codexVersion": "1.0"
          }
        },
        "group": "[\"trigger\"]",
        "defaults": {
          "name": "When clicking ‘Execute workflow’",
          "color": "#909298"
        },
        "iconData": {
          "icon": "mouse-pointer",
          "type": "icon"
        },
        "displayName": "Manual Trigger",
        "typeVersion": 1,
        "nodeCategories": [
          {
            "id": 9,
            "name": "Core Nodes"
          }
        ]
      },
      {
        "id": 839,
        "icon": "fa:clock",
        "name": "n8n-nodes-base.scheduleTrigger",
        "codex": {
          "data": {
            "alias": [
              "Time",
              "Scheduler",
              "Polling",
              "Cron",
              "Interval"
            ],
            "resources": {
              "generic": [],
              "primaryDocumentation": [
                {
                  "url": "https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.scheduletrigger/"
                }
              ]
            },
            "categories": [
              "Core Nodes"
            ],
            "nodeVersion": "1.0",
            "codexVersion": "1.0"
          }
        },
        "group": "[\"trigger\",\"schedule\"]",
        "defaults": {
          "name": "Schedule Trigger",
          "color": "#31C49F"
        },
        "iconData": {
          "icon": "clock",
          "type": "icon"
        },
        "displayName": "Schedule Trigger",
        "typeVersion": 1,
        "nodeCategories": [
          {
            "id": 9,
            "name": "Core Nodes"
          }
        ]
      },
      {
        "id": 844,
        "icon": "fa:filter",
        "name": "n8n-nodes-base.filter",
        "codex": {
          "data": {
            "alias": [
              "Router",
              "Filter",
              "Condition",
              "Logic",
              "Boolean",
              "Branch"
            ],
            "details": "The Filter node can be used to filter items based on a condition. If the condition is met, the item will be passed on to the next node. If the condition is not met, the item will be omitted. Conditions can be combined together by AND(meet all conditions), or OR(meet at least one condition).",
            "resources": {
              "generic": [],
              "primaryDocumentation": [
                {
                  "url": "https://docs.n8n.io/integrations/builtin/core-nodes/n8n-nodes-base.filter/"
                }
              ]
            },
            "categories": [
              "Core Nodes"
            ],
            "nodeVersion": "1.0",
            "codexVersion": "1.0",
            "subcategories": {
              "Core Nodes": [
                "Flow",
                "Data Transformation"
              ]
            }
          }
        },
        "group": "[\"transform\"]",
        "defaults": {
          "name": "Filter",
          "color": "#229eff"
        },
        "iconData": {
          "icon": "filter",
          "type": "icon"
        },
        "displayName": "Filter",
        "typeVersion": 2,
        "nodeCategories": [
          {
            "id": 9,
            "name": "Core Nodes"
          }
        ]
      }
    ],
    "categories": [
      {
        "id": 16,
        "name": "DevOps"
      }
    ],
    "image": [
      {
        "id": 776,
        "url": "https://n8niostorageaccount.blob.core.windows.net/n8nio-strapi-blobs-prod/assets/image_852fff2fef.png"
      }
    ]
  }
}