Auto backup (2022-07-17T21:00:58.022Z)
This commit is contained in:
@@ -156,6 +156,7 @@
|
||||
"parameters": {
|
||||
"docId": "d61nLm6Fn99jwqxd6hdT9d",
|
||||
"tableId": "Items",
|
||||
"returnAll": true,
|
||||
"additionalOptions": {
|
||||
"filter": {
|
||||
"filterProperties": [
|
||||
@@ -327,7 +328,7 @@
|
||||
"chatId": "1684481",
|
||||
"binaryData": true,
|
||||
"additionalFields": {
|
||||
"caption": "=#{{$node[\"Set\"].json[\"tag\"]}}\n<b>{{$json[\"title\"]}} - {{$json[\"price\"]}}</b>\n<i>{{$node[\"HTML Extract1\"].json[\"city\"]}}</i>\n<a href=\"{{$node[\"Merge1\"].json[\"link\"]}}\">Подробнее</a>",
|
||||
"caption": "=#{{$node[\"Set\"].json[\"tag\"]}}\n<b>{{$json[\"title\"]}} - {{$json[\"price\"]}}</b>\n📍 <i>{{$node[\"Merge1\"].json[\"city\"]}}</i>\n<a href=\"{{$node[\"Merge1\"].json[\"link\"]}}\">Подробнее</a>",
|
||||
"parse_mode": "HTML"
|
||||
}
|
||||
},
|
||||
@@ -359,7 +360,7 @@
|
||||
},
|
||||
{
|
||||
"name": "city",
|
||||
"value": "={{$node[\"HTML Extract1\"].json[\"city\"]}}"
|
||||
"value": "={{$node[\"Merge1\"].json[\"city\"]}}"
|
||||
},
|
||||
{
|
||||
"name": "date",
|
||||
@@ -551,7 +552,7 @@
|
||||
}
|
||||
},
|
||||
"createdAt": "2022-05-27T16:18:47.443Z",
|
||||
"updatedAt": "2022-07-15T17:16:33.702Z",
|
||||
"updatedAt": "2022-07-17T08:43:44.330Z",
|
||||
"settings": {
|
||||
"errorWorkflow": "25"
|
||||
},
|
||||
|
||||
163
flows/28.json
163
flows/28.json
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"id": 28,
|
||||
"name": "usd",
|
||||
"name": "currncy",
|
||||
"active": true,
|
||||
"nodes": [
|
||||
{
|
||||
@@ -59,11 +59,11 @@
|
||||
"values": {
|
||||
"number": [
|
||||
{
|
||||
"name": "sale",
|
||||
"name": "sale_usd",
|
||||
"value": "={{$json[\"sale\"].substr(0,5)}}"
|
||||
},
|
||||
{
|
||||
"name": "buy",
|
||||
"name": "buy_usd",
|
||||
"value": "={{$json[\"buy\"].substr(0,5)}}"
|
||||
}
|
||||
],
|
||||
@@ -97,8 +97,8 @@
|
||||
"type": "n8n-nodes-base.grist",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
660,
|
||||
300
|
||||
880,
|
||||
380
|
||||
],
|
||||
"credentials": {
|
||||
"gristApi": {
|
||||
@@ -125,6 +125,92 @@
|
||||
-140,
|
||||
480
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"url": "https://minfin.com.ua/currency/auction/eur/buy/chernigov/",
|
||||
"responseFormat": "string",
|
||||
"options": {}
|
||||
},
|
||||
"name": "HTTP Request1",
|
||||
"type": "n8n-nodes-base.httpRequest",
|
||||
"typeVersion": 2,
|
||||
"position": [
|
||||
60,
|
||||
480
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"extractionValues": {
|
||||
"values": [
|
||||
{
|
||||
"key": "buy",
|
||||
"cssSelector": "div.buy > span.Typography.cardHeadlineL ",
|
||||
"returnValue": "html"
|
||||
},
|
||||
{
|
||||
"key": "sale",
|
||||
"cssSelector": "div.sale > span.Typography.cardHeadlineL",
|
||||
"returnValue": "html"
|
||||
}
|
||||
]
|
||||
},
|
||||
"options": {}
|
||||
},
|
||||
"name": "HTML Extract1",
|
||||
"type": "n8n-nodes-base.htmlExtract",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
260,
|
||||
480
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"keepOnlySet": true,
|
||||
"values": {
|
||||
"number": [
|
||||
{
|
||||
"name": "sale_eur",
|
||||
"value": "={{$json[\"sale\"].substr(0,5)}}"
|
||||
},
|
||||
{
|
||||
"name": "buy_eur",
|
||||
"value": "={{$json[\"buy\"].substr(0,5)}}"
|
||||
}
|
||||
],
|
||||
"string": [
|
||||
{
|
||||
"name": "date",
|
||||
"value": "={{$now.toString()}}"
|
||||
}
|
||||
]
|
||||
},
|
||||
"options": {
|
||||
"dotNotation": false
|
||||
}
|
||||
},
|
||||
"name": "Set1",
|
||||
"type": "n8n-nodes-base.set",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
440,
|
||||
480
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"mode": "mergeByIndex",
|
||||
"join": "outer"
|
||||
},
|
||||
"name": "Merge",
|
||||
"type": "n8n-nodes-base.merge",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
660,
|
||||
380
|
||||
]
|
||||
}
|
||||
],
|
||||
"connections": {
|
||||
@@ -165,7 +251,7 @@
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "Grist",
|
||||
"node": "Merge",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
@@ -179,14 +265,75 @@
|
||||
"node": "HTTP Request",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
},
|
||||
{
|
||||
"node": "HTTP Request1",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"HTML Extract1": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "Set1",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"HTTP Request1": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "HTML Extract1",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Set1": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "Merge",
|
||||
"type": "main",
|
||||
"index": 1
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Grist": {
|
||||
"main": [
|
||||
[]
|
||||
]
|
||||
},
|
||||
"Merge": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "Grist",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
}
|
||||
},
|
||||
"createdAt": "2022-05-30T05:02:38.795Z",
|
||||
"updatedAt": "2022-06-21T03:20:12.113Z",
|
||||
"updatedAt": "2022-07-17T09:22:06.673Z",
|
||||
"settings": {},
|
||||
"staticData": null,
|
||||
"tags": []
|
||||
"tags": [
|
||||
{
|
||||
"id": "2",
|
||||
"name": "my",
|
||||
"createdAt": "2022-05-19T09:37:15.931Z",
|
||||
"updatedAt": "2022-05-19T09:37:15.931Z"
|
||||
}
|
||||
]
|
||||
}
|
||||
568
flows/54.json
Normal file
568
flows/54.json
Normal file
@@ -0,0 +1,568 @@
|
||||
{
|
||||
"id": 54,
|
||||
"name": "olx forbidden west",
|
||||
"active": true,
|
||||
"nodes": [
|
||||
{
|
||||
"parameters": {},
|
||||
"name": "Start",
|
||||
"type": "n8n-nodes-base.start",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
180,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"url": "https://www.olx.ua/d/elektronika/igry-i-igrovye-pristavki/igry-dlya-pristavok/q-horizon-forbidden-west/?currency=UAH&search%5Border%5D=created_at:desc&search%5Bfilter_enum_console_manufacturers%5D%5B0%5D=2272",
|
||||
"responseFormat": "string",
|
||||
"options": {}
|
||||
},
|
||||
"name": "HTTP Request",
|
||||
"type": "n8n-nodes-base.httpRequest",
|
||||
"typeVersion": 2,
|
||||
"position": [
|
||||
400,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"extractionValues": {
|
||||
"values": [
|
||||
{
|
||||
"key": "items",
|
||||
"cssSelector": "div.css-19ucd76",
|
||||
"returnValue": "html",
|
||||
"returnArray": true
|
||||
}
|
||||
]
|
||||
},
|
||||
"options": {}
|
||||
},
|
||||
"name": "HTML Extract",
|
||||
"type": "n8n-nodes-base.htmlExtract",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
560,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"fieldToSplitOut": "items",
|
||||
"options": {}
|
||||
},
|
||||
"name": "Item Lists",
|
||||
"type": "n8n-nodes-base.itemLists",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
720,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"dataPropertyName": "items",
|
||||
"extractionValues": {
|
||||
"values": [
|
||||
{
|
||||
"key": "link",
|
||||
"cssSelector": "a.css-1bbgabe",
|
||||
"returnValue": "attribute",
|
||||
"attribute": "href"
|
||||
},
|
||||
{
|
||||
"key": "city",
|
||||
"cssSelector": "p.css-p6wsjo-Text.eu5v0x0"
|
||||
}
|
||||
]
|
||||
},
|
||||
"options": {}
|
||||
},
|
||||
"name": "HTML Extract1",
|
||||
"type": "n8n-nodes-base.htmlExtract",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
900,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"triggerTimes": {
|
||||
"item": [
|
||||
{
|
||||
"mode": "everyX",
|
||||
"value": 15,
|
||||
"unit": "minutes"
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"name": "Cron2",
|
||||
"type": "n8n-nodes-base.cron",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
180,
|
||||
480
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"values": {
|
||||
"string": [
|
||||
{
|
||||
"name": "link",
|
||||
"value": "=https://m.olx.ua{{$json[\"link\"]}}"
|
||||
},
|
||||
{
|
||||
"name": "tag",
|
||||
"value": "forbidden_west"
|
||||
}
|
||||
]
|
||||
},
|
||||
"options": {}
|
||||
},
|
||||
"name": "Set",
|
||||
"type": "n8n-nodes-base.set",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
1280,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"conditions": {
|
||||
"string": [
|
||||
{
|
||||
"value1": "={{$json[\"link\"]}}",
|
||||
"operation": "isNotEmpty"
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"name": "IF",
|
||||
"type": "n8n-nodes-base.if",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
1080,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"docId": "d61nLm6Fn99jwqxd6hdT9d",
|
||||
"tableId": "Items",
|
||||
"returnAll": true,
|
||||
"additionalOptions": {
|
||||
"filter": {
|
||||
"filterProperties": [
|
||||
{
|
||||
"field": "tag",
|
||||
"values": "forbidden_west"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"name": "Grist1",
|
||||
"type": "n8n-nodes-base.grist",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
1280,
|
||||
500
|
||||
],
|
||||
"credentials": {
|
||||
"gristApi": {
|
||||
"id": "21",
|
||||
"name": "Grist account"
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"mode": "removeKeyMatches",
|
||||
"propertyName1": "link",
|
||||
"propertyName2": "link"
|
||||
},
|
||||
"name": "Merge1",
|
||||
"type": "n8n-nodes-base.merge",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
1500,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"operation": "create",
|
||||
"docId": "d61nLm6Fn99jwqxd6hdT9d",
|
||||
"tableId": "Items",
|
||||
"dataToSend": "autoMapInputs"
|
||||
},
|
||||
"name": "Grist",
|
||||
"type": "n8n-nodes-base.grist",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
2280,
|
||||
500
|
||||
],
|
||||
"credentials": {
|
||||
"gristApi": {
|
||||
"id": "21",
|
||||
"name": "Grist account"
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"url": "={{$json[\"link\"]}}",
|
||||
"responseFormat": "string",
|
||||
"options": {}
|
||||
},
|
||||
"name": "HTTP Request1",
|
||||
"type": "n8n-nodes-base.httpRequest",
|
||||
"typeVersion": 2,
|
||||
"position": [
|
||||
1700,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"extractionValues": {
|
||||
"values": [
|
||||
{
|
||||
"key": "price",
|
||||
"cssSelector": "h3.css-okktvh-Text.eu5v0x0"
|
||||
},
|
||||
{
|
||||
"key": "content",
|
||||
"cssSelector": "div.css-g5mtbi-Text"
|
||||
},
|
||||
{
|
||||
"key": "image",
|
||||
"cssSelector": "img.css-1bmvjcs",
|
||||
"returnValue": "attribute",
|
||||
"attribute": "src"
|
||||
},
|
||||
{
|
||||
"key": "title",
|
||||
"cssSelector": "h1.css-r9zjja-Text.eu5v0x0"
|
||||
}
|
||||
]
|
||||
},
|
||||
"options": {
|
||||
"trimValues": true
|
||||
}
|
||||
},
|
||||
"name": "HTML Extract2",
|
||||
"type": "n8n-nodes-base.htmlExtract",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
1880,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"operation": "multiStep",
|
||||
"operations": {
|
||||
"operations": [
|
||||
{
|
||||
"operation": "resize",
|
||||
"width": 300,
|
||||
"height": -1,
|
||||
"resizeOption": "onlyIfLarger"
|
||||
},
|
||||
{
|
||||
"operation": "crop",
|
||||
"width": 300,
|
||||
"height": 100,
|
||||
"positionY": 75
|
||||
}
|
||||
]
|
||||
},
|
||||
"options": {}
|
||||
},
|
||||
"name": "Edit Image",
|
||||
"type": "n8n-nodes-base.editImage",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
2280,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"url": "={{$json[\"image\"]}}",
|
||||
"responseFormat": "file",
|
||||
"options": {}
|
||||
},
|
||||
"name": "HTTP Request2",
|
||||
"type": "n8n-nodes-base.httpRequest",
|
||||
"typeVersion": 2,
|
||||
"position": [
|
||||
2100,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"functionCode": "// Code here will run once per input item.\n// More info and help: https://docs.n8n.io/nodes/n8n-nodes-base.functionItem\n// Tip: You can use luxon for dates and $jmespath for querying JSON structures\n\n// Add a new field called 'myNewField' to the JSON of the item\nitem.trim_content = $json[\"content\"].slice(0,250);\n\n// You can write logs to the browser console\nconsole.log('Done!');\n\nreturn item;"
|
||||
},
|
||||
"name": "FunctionItem",
|
||||
"type": "n8n-nodes-base.functionItem",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
2000,
|
||||
60
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"operation": "sendPhoto",
|
||||
"chatId": "1684481",
|
||||
"binaryData": true,
|
||||
"additionalFields": {
|
||||
"caption": "=#{{$node[\"Set\"].json[\"tag\"]}}\n<b>{{$json[\"title\"]}} - {{$json[\"price\"]}}</b>\n📍 <i>{{$node[\"Merge1\"].json[\"city\"]}}</i>\n<a href=\"{{$node[\"Merge1\"].json[\"link\"]}}\">Подробнее</a>",
|
||||
"parse_mode": "HTML"
|
||||
}
|
||||
},
|
||||
"name": "Telegram",
|
||||
"type": "n8n-nodes-base.telegram",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
2520,
|
||||
300
|
||||
],
|
||||
"credentials": {
|
||||
"telegramApi": {
|
||||
"id": "31",
|
||||
"name": "Telegram account"
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"values": {
|
||||
"string": [
|
||||
{
|
||||
"name": "link",
|
||||
"value": "={{$node[\"Merge1\"].json[\"link\"]}}"
|
||||
},
|
||||
{
|
||||
"name": "tag",
|
||||
"value": "={{$node[\"Set\"].json[\"tag\"]}}"
|
||||
},
|
||||
{
|
||||
"name": "city",
|
||||
"value": "={{$node[\"Merge1\"].json[\"city\"]}}"
|
||||
},
|
||||
{
|
||||
"name": "date",
|
||||
"value": "={{$now.toString()}}"
|
||||
}
|
||||
]
|
||||
},
|
||||
"options": {}
|
||||
},
|
||||
"name": "Set1",
|
||||
"type": "n8n-nodes-base.set",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
2100,
|
||||
500
|
||||
]
|
||||
}
|
||||
],
|
||||
"connections": {
|
||||
"Start": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "HTTP Request",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"HTTP Request": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "HTML Extract",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"HTML Extract": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "Item Lists",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Item Lists": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "HTML Extract1",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Cron2": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "HTTP Request",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"HTML Extract1": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "IF",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"IF": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "Set",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Set": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "Merge1",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Grist1": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "Merge1",
|
||||
"type": "main",
|
||||
"index": 1
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Merge1": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "HTTP Request1",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"HTTP Request1": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "HTML Extract2",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"HTML Extract2": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "Set1",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
},
|
||||
{
|
||||
"node": "HTTP Request2",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Edit Image": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "Telegram",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"HTTP Request2": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "Edit Image",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Set1": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "Grist",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
}
|
||||
},
|
||||
"createdAt": "2022-07-17T07:56:32.590Z",
|
||||
"updatedAt": "2022-07-17T08:44:28.572Z",
|
||||
"settings": {
|
||||
"errorWorkflow": "25"
|
||||
},
|
||||
"staticData": null,
|
||||
"tags": [
|
||||
{
|
||||
"id": "3",
|
||||
"name": "olx",
|
||||
"createdAt": "2022-06-21T19:20:51.822Z",
|
||||
"updatedAt": "2022-06-21T19:20:51.822Z"
|
||||
}
|
||||
]
|
||||
}
|
||||
579
flows/55.json
Normal file
579
flows/55.json
Normal file
@@ -0,0 +1,579 @@
|
||||
{
|
||||
"id": 55,
|
||||
"name": "olx playstation5",
|
||||
"active": true,
|
||||
"nodes": [
|
||||
{
|
||||
"parameters": {},
|
||||
"name": "Start",
|
||||
"type": "n8n-nodes-base.start",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
180,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"url": "https://www.olx.ua/d/elektronika/igry-i-igrovye-pristavki/pristavki/q-playstation-5/?currency=UAH&search%5Border%5D=created_at:desc",
|
||||
"responseFormat": "string",
|
||||
"options": {}
|
||||
},
|
||||
"name": "HTTP Request",
|
||||
"type": "n8n-nodes-base.httpRequest",
|
||||
"typeVersion": 2,
|
||||
"position": [
|
||||
400,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"extractionValues": {
|
||||
"values": [
|
||||
{
|
||||
"key": "items",
|
||||
"cssSelector": "div.css-19ucd76",
|
||||
"returnValue": "html",
|
||||
"returnArray": true
|
||||
}
|
||||
]
|
||||
},
|
||||
"options": {}
|
||||
},
|
||||
"name": "HTML Extract",
|
||||
"type": "n8n-nodes-base.htmlExtract",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
560,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"fieldToSplitOut": "items",
|
||||
"options": {}
|
||||
},
|
||||
"name": "Item Lists",
|
||||
"type": "n8n-nodes-base.itemLists",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
720,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"dataPropertyName": "items",
|
||||
"extractionValues": {
|
||||
"values": [
|
||||
{
|
||||
"key": "link",
|
||||
"cssSelector": "a.css-1bbgabe",
|
||||
"returnValue": "attribute",
|
||||
"attribute": "href"
|
||||
},
|
||||
{
|
||||
"key": "city",
|
||||
"cssSelector": "p.css-p6wsjo-Text.eu5v0x0"
|
||||
}
|
||||
]
|
||||
},
|
||||
"options": {}
|
||||
},
|
||||
"name": "HTML Extract1",
|
||||
"type": "n8n-nodes-base.htmlExtract",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
900,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"triggerTimes": {
|
||||
"item": [
|
||||
{
|
||||
"mode": "everyX",
|
||||
"value": 15,
|
||||
"unit": "minutes"
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"name": "Cron2",
|
||||
"type": "n8n-nodes-base.cron",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
180,
|
||||
480
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"values": {
|
||||
"string": [
|
||||
{
|
||||
"name": "link",
|
||||
"value": "=https://m.olx.ua{{$json[\"link\"]}}"
|
||||
},
|
||||
{
|
||||
"name": "tag",
|
||||
"value": "playstation5"
|
||||
}
|
||||
]
|
||||
},
|
||||
"options": {}
|
||||
},
|
||||
"name": "Set",
|
||||
"type": "n8n-nodes-base.set",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
1280,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"conditions": {
|
||||
"string": [
|
||||
{
|
||||
"value1": "={{$json[\"link\"]}}",
|
||||
"operation": "isNotEmpty"
|
||||
},
|
||||
{
|
||||
"value1": "={{$json[\"link\"]}}",
|
||||
"operation": "contains",
|
||||
"value2": "playstation-5"
|
||||
},
|
||||
{
|
||||
"value1": "={{$json[\"city\"]}}",
|
||||
"operation": "contains",
|
||||
"value2": "Сегодня"
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"name": "IF",
|
||||
"type": "n8n-nodes-base.if",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
1080,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"docId": "d61nLm6Fn99jwqxd6hdT9d",
|
||||
"tableId": "Items",
|
||||
"returnAll": true,
|
||||
"additionalOptions": {
|
||||
"filter": {
|
||||
"filterProperties": [
|
||||
{
|
||||
"field": "tag",
|
||||
"values": "playstation5"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"name": "Grist1",
|
||||
"type": "n8n-nodes-base.grist",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
1280,
|
||||
500
|
||||
],
|
||||
"credentials": {
|
||||
"gristApi": {
|
||||
"id": "21",
|
||||
"name": "Grist account"
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"mode": "removeKeyMatches",
|
||||
"propertyName1": "link",
|
||||
"propertyName2": "link"
|
||||
},
|
||||
"name": "Merge1",
|
||||
"type": "n8n-nodes-base.merge",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
1500,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"operation": "create",
|
||||
"docId": "d61nLm6Fn99jwqxd6hdT9d",
|
||||
"tableId": "Items",
|
||||
"dataToSend": "autoMapInputs"
|
||||
},
|
||||
"name": "Grist",
|
||||
"type": "n8n-nodes-base.grist",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
2280,
|
||||
500
|
||||
],
|
||||
"credentials": {
|
||||
"gristApi": {
|
||||
"id": "21",
|
||||
"name": "Grist account"
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"url": "={{$json[\"link\"]}}",
|
||||
"responseFormat": "string",
|
||||
"options": {}
|
||||
},
|
||||
"name": "HTTP Request1",
|
||||
"type": "n8n-nodes-base.httpRequest",
|
||||
"typeVersion": 2,
|
||||
"position": [
|
||||
1700,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"extractionValues": {
|
||||
"values": [
|
||||
{
|
||||
"key": "price",
|
||||
"cssSelector": "h3.css-okktvh-Text.eu5v0x0"
|
||||
},
|
||||
{
|
||||
"key": "content",
|
||||
"cssSelector": "div.css-g5mtbi-Text"
|
||||
},
|
||||
{
|
||||
"key": "image",
|
||||
"cssSelector": "img.css-1bmvjcs",
|
||||
"returnValue": "attribute",
|
||||
"attribute": "src"
|
||||
},
|
||||
{
|
||||
"key": "title",
|
||||
"cssSelector": "h1.css-r9zjja-Text.eu5v0x0"
|
||||
}
|
||||
]
|
||||
},
|
||||
"options": {
|
||||
"trimValues": true
|
||||
}
|
||||
},
|
||||
"name": "HTML Extract2",
|
||||
"type": "n8n-nodes-base.htmlExtract",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
1880,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"operation": "multiStep",
|
||||
"operations": {
|
||||
"operations": [
|
||||
{
|
||||
"operation": "resize",
|
||||
"width": 300,
|
||||
"height": -1,
|
||||
"resizeOption": "onlyIfLarger"
|
||||
},
|
||||
{
|
||||
"operation": "crop",
|
||||
"width": 300,
|
||||
"height": 100,
|
||||
"positionY": 75
|
||||
}
|
||||
]
|
||||
},
|
||||
"options": {}
|
||||
},
|
||||
"name": "Edit Image",
|
||||
"type": "n8n-nodes-base.editImage",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
2280,
|
||||
300
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"url": "={{$json[\"image\"]}}",
|
||||
"allowUnauthorizedCerts": true,
|
||||
"responseFormat": "file",
|
||||
"options": {}
|
||||
},
|
||||
"name": "HTTP Request2",
|
||||
"type": "n8n-nodes-base.httpRequest",
|
||||
"typeVersion": 2,
|
||||
"position": [
|
||||
2100,
|
||||
280
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"functionCode": "// Code here will run once per input item.\n// More info and help: https://docs.n8n.io/nodes/n8n-nodes-base.functionItem\n// Tip: You can use luxon for dates and $jmespath for querying JSON structures\n\n// Add a new field called 'myNewField' to the JSON of the item\nitem.trim_content = $json[\"content\"].slice(0,250);\n\n// You can write logs to the browser console\nconsole.log('Done!');\n\nreturn item;"
|
||||
},
|
||||
"name": "FunctionItem",
|
||||
"type": "n8n-nodes-base.functionItem",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
2000,
|
||||
60
|
||||
]
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"operation": "sendPhoto",
|
||||
"chatId": "1684481",
|
||||
"binaryData": true,
|
||||
"additionalFields": {
|
||||
"caption": "=#{{$node[\"Set\"].json[\"tag\"]}}\n<b>{{$json[\"title\"]}} - {{$json[\"price\"]}}</b>\n📍 <i>{{$node[\"Merge1\"].json[\"city\"]}}</i>\n<a href=\"{{$node[\"Merge1\"].json[\"link\"]}}\">Подробнее</a>",
|
||||
"parse_mode": "HTML"
|
||||
}
|
||||
},
|
||||
"name": "Telegram",
|
||||
"type": "n8n-nodes-base.telegram",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
2520,
|
||||
300
|
||||
],
|
||||
"credentials": {
|
||||
"telegramApi": {
|
||||
"id": "31",
|
||||
"name": "Telegram account"
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"parameters": {
|
||||
"values": {
|
||||
"string": [
|
||||
{
|
||||
"name": "link",
|
||||
"value": "={{$node[\"Merge1\"].json[\"link\"]}}"
|
||||
},
|
||||
{
|
||||
"name": "tag",
|
||||
"value": "={{$node[\"Set\"].json[\"tag\"]}}"
|
||||
},
|
||||
{
|
||||
"name": "city",
|
||||
"value": "={{$node[\"Merge1\"].json[\"city\"]}}"
|
||||
},
|
||||
{
|
||||
"name": "date",
|
||||
"value": "={{$now.toString()}}"
|
||||
}
|
||||
]
|
||||
},
|
||||
"options": {}
|
||||
},
|
||||
"name": "Set1",
|
||||
"type": "n8n-nodes-base.set",
|
||||
"typeVersion": 1,
|
||||
"position": [
|
||||
2100,
|
||||
500
|
||||
]
|
||||
}
|
||||
],
|
||||
"connections": {
|
||||
"Start": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "HTTP Request",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"HTTP Request": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "HTML Extract",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"HTML Extract": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "Item Lists",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Item Lists": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "HTML Extract1",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Cron2": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "HTTP Request",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"HTML Extract1": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "IF",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"IF": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "Set",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Set": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "Merge1",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Grist1": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "Merge1",
|
||||
"type": "main",
|
||||
"index": 1
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Merge1": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "HTTP Request1",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"HTTP Request1": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "HTML Extract2",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"HTML Extract2": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "Set1",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
},
|
||||
{
|
||||
"node": "HTTP Request2",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Edit Image": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "Telegram",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"HTTP Request2": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "Edit Image",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
"Set1": {
|
||||
"main": [
|
||||
[
|
||||
{
|
||||
"node": "Grist",
|
||||
"type": "main",
|
||||
"index": 0
|
||||
}
|
||||
]
|
||||
]
|
||||
}
|
||||
},
|
||||
"createdAt": "2022-07-17T08:02:11.870Z",
|
||||
"updatedAt": "2022-07-17T19:10:52.343Z",
|
||||
"settings": {
|
||||
"errorWorkflow": "25"
|
||||
},
|
||||
"staticData": null,
|
||||
"tags": [
|
||||
{
|
||||
"id": "3",
|
||||
"name": "olx",
|
||||
"createdAt": "2022-06-21T19:20:51.822Z",
|
||||
"updatedAt": "2022-06-21T19:20:51.822Z"
|
||||
}
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user