Obtener datos de múltiples fuentes RSS a Telegram
Este es unBuilding Blocksflujo de automatización del dominio deautomatización que contiene 11 nodos.Utiliza principalmente nodos como If, Cron, Function, Telegram, RssFeedRead. Obtener datos de múltiples fuentes RSS en Telegram
- •Bot Token de Telegram
Nodos utilizados (11)
Categoría
{
"nodes": [
{
"name": "Leer Fuente RSS",
"type": "n8n-nodes-base.rssFeedRead",
"position": [
420,
-20
],
"parameters": {
"url": "={{$node[\"SplitInBatches\"].json[\"url\"]}}"
},
"typeVersion": 1,
"id": "Leer-Fuente-RSS-0"
},
{
"name": "Dividir en Lotes",
"type": "n8n-nodes-base.splitInBatches",
"position": [
200,
-20
],
"parameters": {
"options": {},
"batchSize": 1
},
"typeVersion": 1,
"id": "Dividir-en-Lotes-1"
},
{
"name": "Cron",
"type": "n8n-nodes-base.cron",
"position": [
-240,
-20
],
"parameters": {
"triggerTimes": {
"item": [
{
"mode": "everyX",
"unit": "minutes",
"value": 10
}
]
}
},
"typeVersion": 1,
"id": "Cron-2"
},
{
"name": "Obtener solo RSS nuevos",
"type": "n8n-nodes-base.function",
"position": [
640,
-20
],
"parameters": {
"functionCode": "const staticData = getWorkflowStaticData('global');\nconst newRSSIds = items.map(item => item.json[\"isoDate\"]);\nconst oldRSSIds = staticData.oldRSSIds; \n\nif (!oldRSSIds) {\n staticData.oldRSSIds = newRSSIds;\n return items;\n}\n\n\nconst actualNewRSSIds = newRSSIds.filter((id) => !oldRSSIds.includes(id));\nconst actualNewRSS = items.filter((data) => actualNewRSSIds.includes(data.json['isoDate']));\nstaticData.oldRSSIds = [...actualNewRSSIds, ...oldRSSIds];\n\nreturn actualNewRSS;\n"
},
"typeVersion": 1,
"id": "Obtener-solo-RSS-nuevos-3"
},
{
"name": "Telegram_IT",
"type": "n8n-nodes-base.telegram",
"position": [
1220,
460
],
"parameters": {
"text": "={{$json[\"title\"]}}\n{{$json[\"link\"]}}",
"chatId": "TelegramID",
"additionalFields": {}
},
"credentials": {
"telegramApi": {
"id": "2",
"name": "IT_RSS"
}
},
"typeVersion": 1,
"id": "Telegram_IT-4"
},
{
"name": "Telegram_Security",
"type": "n8n-nodes-base.telegram",
"position": [
1220,
220
],
"parameters": {
"text": "={{$json[\"title\"]}}\n{{$json[\"link\"]}}",
"chatId": "TelegramID",
"additionalFields": {}
},
"credentials": {
"telegramApi": {
"id": "4",
"name": "Security_RSS"
}
},
"typeVersion": 1,
"id": "Telegram_Security-5"
},
{
"name": "Fuente RSS",
"type": "n8n-nodes-base.function",
"position": [
-20,
-20
],
"parameters": {
"functionCode": "return [\n {\n json: {\n url: 'https://feeds.feedburner.com/UnikosHardware',\n }\n },\n {\n json: {\n url: 'http://www.ithome.com.tw/rss.php',\n }\n },\n {\n json: {\n url: 'http://feeds.feedburner.com/playpc',\n }\n },\n {\n json: {\n url: 'https://lab.ocf.tw/feed/',\n }\n },\n {\n json: {\n url: 'https://techcommunity.microsoft.com/plugins/custom/microsoft/o365/custom-blog-rss?tid=3754543230341459569&board=microsoft_365blog',\n }\n }\n];"
},
"typeVersion": 1,
"id": "Fuente-RSS-6"
},
{
"name": "Telegram_M365",
"type": "n8n-nodes-base.telegram",
"position": [
1220,
-40
],
"parameters": {
"text": "={{$json[\"title\"]}}\n{{$json[\"link\"]}}",
"chatId": "TelegramID",
"additionalFields": {}
},
"credentials": {
"telegramApi": {
"id": "5",
"name": "M365_RSS"
}
},
"typeVersion": 1,
"id": "Telegram_M365-7"
},
{
"name": "SI-2",
"type": "n8n-nodes-base.if",
"position": [
880,
240
],
"parameters": {
"conditions": {
"string": [
{
"value1": "={{$json[\"title\"]}}",
"value2": "資安|資訊安全|安全|外洩|監控|威脅|漏洞|封鎖|修補|攻擊|入侵|個資|隱私|私密|騙|社交工程|釣魚|駭|Security|security|Secure|secure",
"operation": "regex"
}
]
},
"combineOperation": "any"
},
"typeVersion": 1,
"id": "SI-2-8"
},
{
"name": "SI-1",
"type": "n8n-nodes-base.if",
"position": [
880,
-20
],
"parameters": {
"conditions": {
"string": [
{
"value1": "={{$json[\"link\"]}}",
"value2": "techcommunity.microsoft.com",
"operation": "contains"
}
]
}
},
"typeVersion": 1,
"id": "SI-1-9"
},
{
"name": "Función Limpiar",
"type": "n8n-nodes-base.function",
"position": [
-20,
-180
],
"parameters": {
"functionCode": "// Get the global workflow static data\nconst staticData = getWorkflowStaticData('global');\n// Update its data\nstaticData.oldRSSIds = new Date().getTime();\n// Delete data\ndelete staticData.oldRSSIds;\n\nreturn [\n {\n json: {}\n }\n]"
},
"typeVersion": 1,
"id": "Funci-n-Limpiar-10"
}
],
"connections": {
"Cron-2": {
"main": [
[
{
"node": "Fuente-RSS-6",
"type": "main",
"index": 0
}
]
]
},
"SI-1-9": {
"main": [
[
{
"node": "Telegram_M365-7",
"type": "main",
"index": 0
}
],
[
{
"node": "SI-2-8",
"type": "main",
"index": 0
}
]
]
},
"SI-2-8": {
"main": [
[
{
"node": "Telegram_Security-5",
"type": "main",
"index": 0
}
],
[
{
"node": "Telegram_IT-4",
"type": "main",
"index": 0
}
]
]
},
"Fuente-RSS-6": {
"main": [
[
{
"node": "Dividir-en-Lotes-1",
"type": "main",
"index": 0
}
]
]
},
"Leer-Fuente-RSS-0": {
"main": [
[
{
"node": "Dividir-en-Lotes-1",
"type": "main",
"index": 0
},
{
"node": "Obtener-solo-RSS-nuevos-3",
"type": "main",
"index": 0
}
]
]
},
"Dividir-en-Lotes-1": {
"main": [
[
{
"node": "Leer-Fuente-RSS-0",
"type": "main",
"index": 0
}
]
]
},
"Obtener-solo-RSS-nuevos-3": {
"main": [
[
{
"node": "SI-1-9",
"type": "main",
"index": 0
}
]
]
}
}
}¿Cómo usar este flujo de trabajo?
Copie el código de configuración JSON de arriba, cree un nuevo flujo de trabajo en su instancia de n8n y seleccione "Importar desde JSON", pegue la configuración y luego modifique la configuración de credenciales según sea necesario.
¿En qué escenarios es adecuado este flujo de trabajo?
Intermedio - Bloques de construcción
¿Es de pago?
Este flujo de trabajo es completamente gratuito, puede importarlo y usarlo directamente. Sin embargo, tenga en cuenta que los servicios de terceros utilizados en el flujo de trabajo (como la API de OpenAI) pueden requerir un pago por su cuenta.
Flujos de trabajo relacionados recomendados
Valor
@valorvieCompartir este flujo de trabajo