2023-03-31 16:00:37 +00:00
|
|
|
{
|
|
|
|
"active": false,
|
2023-04-25 16:00:22 +00:00
|
|
|
"connections": {
|
2023-12-04 11:00:06 +00:00
|
|
|
"Success?": {
|
2023-04-25 16:00:22 +00:00
|
|
|
"main": [
|
|
|
|
[
|
|
|
|
{
|
2023-12-04 11:00:06 +00:00
|
|
|
"node": "Wait",
|
|
|
|
"type": "main",
|
|
|
|
"index": 0
|
|
|
|
}
|
|
|
|
]
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"Wait": {
|
|
|
|
"main": [
|
|
|
|
[
|
|
|
|
{
|
|
|
|
"node": "HTTP Request1",
|
|
|
|
"type": "main",
|
|
|
|
"index": 0
|
|
|
|
}
|
|
|
|
]
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"HTTP Request1": {
|
|
|
|
"main": [
|
|
|
|
[
|
|
|
|
{
|
|
|
|
"node": "Success?",
|
|
|
|
"type": "main",
|
|
|
|
"index": 0
|
|
|
|
},
|
|
|
|
{
|
2023-12-04 23:00:09 +00:00
|
|
|
"node": "Item Lists",
|
|
|
|
"type": "main",
|
|
|
|
"index": 0
|
|
|
|
}
|
|
|
|
]
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"When clicking \"Execute Workflow\"": {
|
|
|
|
"main": [
|
|
|
|
[
|
|
|
|
{
|
|
|
|
"node": "Wait",
|
|
|
|
"type": "main",
|
|
|
|
"index": 0
|
|
|
|
}
|
|
|
|
]
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"Item Lists": {
|
|
|
|
"main": [
|
|
|
|
[
|
|
|
|
{
|
|
|
|
"node": "Edit Fields2",
|
|
|
|
"type": "main",
|
|
|
|
"index": 0
|
|
|
|
}
|
|
|
|
]
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"Edit Fields2": {
|
|
|
|
"main": [
|
|
|
|
[
|
|
|
|
{
|
|
|
|
"node": "Spreadsheet File",
|
|
|
|
"type": "main",
|
|
|
|
"index": 0
|
|
|
|
}
|
|
|
|
]
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"Spreadsheet File": {
|
|
|
|
"main": [
|
|
|
|
[
|
|
|
|
{
|
|
|
|
"node": "Write Binary File",
|
2023-04-25 16:00:22 +00:00
|
|
|
"type": "main",
|
|
|
|
"index": 0
|
|
|
|
}
|
|
|
|
]
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
2023-12-04 11:00:06 +00:00
|
|
|
"createdAt": "2023-12-04T08:45:57.778Z",
|
|
|
|
"id": "o9uPy8XY0bMFCS9H",
|
|
|
|
"meta": null,
|
2023-03-31 16:00:37 +00:00
|
|
|
"name": "My workflow",
|
|
|
|
"nodes": [
|
2023-04-25 16:00:22 +00:00
|
|
|
{
|
2023-12-04 11:00:06 +00:00
|
|
|
"parameters": {
|
2023-12-04 23:00:09 +00:00
|
|
|
"fields": {
|
|
|
|
"values": [
|
|
|
|
{
|
|
|
|
"name": "Id",
|
|
|
|
"stringValue": "={{ $json.Id || \"none\" }}"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "OrderRef",
|
|
|
|
"stringValue": "={{ $json.OrderNumber || \"none\" }}"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "CustomerId",
|
|
|
|
"stringValue": "={{ $json.Customer.Id }}"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "date",
|
|
|
|
"stringValue": "={{ $json.CreatedAt }}"
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"include": "none",
|
|
|
|
"options": {
|
|
|
|
"includeBinary": false
|
|
|
|
}
|
2023-12-04 11:00:06 +00:00
|
|
|
},
|
|
|
|
"id": "5cd78676-a0bd-4536-8759-f996d97b4254",
|
|
|
|
"name": "Edit Fields2",
|
|
|
|
"type": "n8n-nodes-base.set",
|
|
|
|
"typeVersion": 3.1,
|
|
|
|
"position": [
|
2023-12-04 23:00:09 +00:00
|
|
|
480,
|
|
|
|
-1780
|
2023-12-04 11:00:06 +00:00
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"parameters": {
|
|
|
|
"conditions": {
|
|
|
|
"number": [
|
|
|
|
{
|
2023-12-05 11:00:34 +00:00
|
|
|
"value1": "={{ $json.body.Data }}",
|
|
|
|
"operation": "isNotEmpty"
|
2023-12-04 11:00:06 +00:00
|
|
|
}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"id": "4f308b2e-f65b-4879-a566-6e6ebafbf125",
|
|
|
|
"name": "Success?",
|
|
|
|
"type": "n8n-nodes-base.if",
|
2023-04-25 16:00:22 +00:00
|
|
|
"typeVersion": 1,
|
|
|
|
"position": [
|
2023-12-04 23:00:09 +00:00
|
|
|
80,
|
2023-12-04 11:00:06 +00:00
|
|
|
-1340
|
2023-04-25 16:00:22 +00:00
|
|
|
]
|
|
|
|
},
|
2023-03-31 16:00:37 +00:00
|
|
|
{
|
|
|
|
"parameters": {
|
2023-12-04 11:00:06 +00:00
|
|
|
"unit": "seconds"
|
2023-03-31 16:00:37 +00:00
|
|
|
},
|
2023-12-04 11:00:06 +00:00
|
|
|
"id": "c06f9de4-8423-4104-bf3b-fe9eb49e447e",
|
|
|
|
"name": "Wait",
|
|
|
|
"type": "n8n-nodes-base.wait",
|
2023-03-31 16:00:37 +00:00
|
|
|
"typeVersion": 1,
|
|
|
|
"position": [
|
2023-12-04 23:00:09 +00:00
|
|
|
680,
|
2023-12-04 11:00:06 +00:00
|
|
|
-1360
|
|
|
|
],
|
|
|
|
"webhookId": "de46ac63-1976-47ce-a91c-2d96bbd61bad"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"parameters": {
|
|
|
|
"url": "https://app.billbee.io/api/v1/orders",
|
|
|
|
"authentication": "genericCredentialType",
|
|
|
|
"genericAuthType": "httpBasicAuth",
|
|
|
|
"sendQuery": true,
|
|
|
|
"queryParameters": {
|
|
|
|
"parameters": [
|
|
|
|
{
|
|
|
|
"name": "pageSize",
|
2023-12-05 11:00:34 +00:00
|
|
|
"value": "2"
|
2023-12-04 11:00:06 +00:00
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "page",
|
2023-12-05 11:00:34 +00:00
|
|
|
"value": "=1"
|
2023-12-04 23:00:09 +00:00
|
|
|
},
|
|
|
|
{
|
|
|
|
"name": "minOrderDate",
|
|
|
|
"value": "2023-01-01"
|
2023-12-04 11:00:06 +00:00
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
|
|
|
"sendHeaders": true,
|
|
|
|
"headerParameters": {
|
|
|
|
"parameters": [
|
|
|
|
{
|
|
|
|
"name": "X-Billbee-Api-Key",
|
|
|
|
"value": "2855BE2C-1D67-4AB0-9DEB-3073E6D27B1C"
|
|
|
|
}
|
|
|
|
]
|
|
|
|
},
|
2023-12-04 23:00:09 +00:00
|
|
|
"options": {
|
|
|
|
"response": {
|
|
|
|
"response": {
|
|
|
|
"fullResponse": true
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2023-12-04 11:00:06 +00:00
|
|
|
},
|
|
|
|
"id": "25d5e4e0-a202-46c7-9df8-b72721fe0861",
|
|
|
|
"name": "HTTP Request1",
|
|
|
|
"type": "n8n-nodes-base.httpRequest",
|
|
|
|
"typeVersion": 4.1,
|
|
|
|
"position": [
|
|
|
|
-260,
|
|
|
|
-1340
|
2023-03-31 16:00:37 +00:00
|
|
|
],
|
2023-04-25 16:00:22 +00:00
|
|
|
"credentials": {
|
2023-12-04 11:00:06 +00:00
|
|
|
"httpBasicAuth": {
|
2023-12-05 11:00:34 +00:00
|
|
|
"id": "xANPcw3p1Nh0wF9J",
|
|
|
|
"name": "Unnamed credential"
|
2023-04-25 16:00:22 +00:00
|
|
|
}
|
|
|
|
}
|
2023-12-04 23:00:09 +00:00
|
|
|
},
|
|
|
|
{
|
|
|
|
"parameters": {},
|
|
|
|
"id": "6ba1ecc5-aec7-4a22-a00b-b3e434f54926",
|
|
|
|
"name": "When clicking \"Execute Workflow\"",
|
|
|
|
"type": "n8n-nodes-base.manualTrigger",
|
|
|
|
"typeVersion": 1,
|
|
|
|
"position": [
|
|
|
|
1280,
|
|
|
|
-1620
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"parameters": {
|
|
|
|
"fieldToSplitOut": "body.Data",
|
|
|
|
"options": {}
|
|
|
|
},
|
|
|
|
"id": "47eb34b6-dabd-4ef9-bba6-b31225a7535a",
|
|
|
|
"name": "Item Lists",
|
|
|
|
"type": "n8n-nodes-base.itemLists",
|
|
|
|
"typeVersion": 3,
|
|
|
|
"position": [
|
|
|
|
300,
|
|
|
|
-1780
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"parameters": {
|
|
|
|
"fileName": "/var/lib/n8n/foo.csv",
|
|
|
|
"options": {
|
|
|
|
"append": true
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"id": "fbe45256-ff55-45c8-a61c-fab25ae795c4",
|
|
|
|
"name": "Write Binary File",
|
|
|
|
"type": "n8n-nodes-base.writeBinaryFile",
|
|
|
|
"typeVersion": 1,
|
|
|
|
"position": [
|
|
|
|
960,
|
|
|
|
-1780
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"parameters": {
|
|
|
|
"operation": "toFile",
|
|
|
|
"fileFormat": "csv",
|
|
|
|
"options": {
|
|
|
|
"headerRow": false
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"id": "abe8462e-d3d0-4d19-a178-ba3b79e8df11",
|
|
|
|
"name": "Spreadsheet File",
|
|
|
|
"type": "n8n-nodes-base.spreadsheetFile",
|
|
|
|
"typeVersion": 2,
|
|
|
|
"position": [
|
|
|
|
720,
|
|
|
|
-1780
|
|
|
|
]
|
2023-03-31 16:00:37 +00:00
|
|
|
}
|
|
|
|
],
|
|
|
|
"pinData": {},
|
2023-12-04 11:00:06 +00:00
|
|
|
"settings": {
|
|
|
|
"executionOrder": "v1"
|
|
|
|
},
|
2023-03-31 16:00:37 +00:00
|
|
|
"staticData": null,
|
|
|
|
"tags": [],
|
|
|
|
"triggerCount": 0,
|
2023-12-05 11:00:34 +00:00
|
|
|
"updatedAt": "2023-12-05T10:36:16.000Z",
|
|
|
|
"versionId": "0126ae60-1dbe-45ce-8edc-7ca2df444b30"
|
2023-03-31 16:00:37 +00:00
|
|
|
}
|