Set Cron Node From CMS

Hello,

Can we set a cron from data coming from a cms ?
I’d like to change it from the CMS and it will set the n8n cron node automatically
Thanks

Yes,

First get some current good cron, (replace set to request probably)
After in other cron use get data

{
  "nodes": [
    {
      "parameters": {
        "triggerTimes": {
          "item": [
            {
              "mode": "everyMinute"
            }
          ]
        }
      },
      "name": "Cron",
      "type": "n8n-nodes-base.cron",
      "typeVersion": 1,
      "position": [
        -2000,
        300
      ]
    },
    {
      "parameters": {
        "keepOnlySet": true,
        "values": {
          "string": [
            {
              "name": "cron",
              "value": "* * * * *"
            }
          ]
        },
        "options": {}
      },
      "name": "Set",
      "type": "n8n-nodes-base.set",
      "typeVersion": 1,
      "position": [
        -1780,
        300
      ]
    },
    {
      "parameters": {
        "triggerTimes": {
          "item": [
            {
              "mode": "custom",
              "cronExpression": "={{$node[\"Set\"].parameter[\"values\"][\"string\"][0][\"value\"]}}"
            }
          ]
        }
      },
      "name": "Cron1",
      "type": "n8n-nodes-base.cron",
      "typeVersion": 1,
      "position": [
        -2020,
        560
      ]
    },
    {
      "parameters": {
        "webhookUri": "https://discord.com/api/webhooks/922278105257766973/zRv_-XE9b_Az67k6WAEJWvUB-t6TSTJJMc-yRH9NSEfMN_NBia6U4W8hyBgRHEQzX7V0",
        "text": "oki doki"
      },
      "name": "Discord",
      "type": "n8n-nodes-base.discord",
      "typeVersion": 1,
      "position": [
        -1780,
        560
      ]
    }
  ],
  "connections": {
    "Cron": {
      "main": [
        [
          {
            "node": "Set",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Cron1": {
      "main": [
        [
          {
            "node": "Discord",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}