[N8N Backup] MyToys.json (new)

This commit is contained in:
m3tam3re 2023-01-18 19:04:04 +01:00
commit 95131f60fa
1 changed files with 294 additions and 0 deletions

294
workflows/MyToys.json Normal file
View File

@ -0,0 +1,294 @@
{
"active": false,
"connections": {
"Code": {
"main": [
[
{
"node": "Rückmeldung CSV erzeugen",
"type": "main",
"index": 0
}
]
]
},
"Auftragsdaten CSV einlesen": {
"main": [
[
{
"node": "Set",
"type": "main",
"index": 0
}
]
]
}
},
"createdAt": "2023-01-17T13:26:26.485Z",
"id": 1,
"name": "MyToys",
"nodes": [
{
"parameters": {
"protocol": "sftp",
"operation": "list"
},
"id": "77792d6c-723a-4021-a25b-866c87195fea",
"name": "FTP",
"type": "n8n-nodes-base.ftp",
"typeVersion": 1,
"position": [
320,
-80
],
"credentials": {
"sftp": {
"id": "1",
"name": "SFTP MyToys"
}
}
},
{
"parameters": {
"jsCode": "// Loop over input items and add a new field\n// called 'myNewField' to the JSON of each one\nfor (const item of $input.all()) {\n item.json.TB_ORDER_ID = \"order_id\";\n item.json.ORDER_PAID = 0;\n item.json.TYPE = \"ship\";\n item.json.PARCEL_TYPE = \"DPD_STD_NATIONAL\";\n item.json.SHIP_CODE = \"12345-track-me\";\n item.json.IDCODE_RETURN_PROP\nOSAL = \"\";\n item.json.COMMENT_INTERN = \"Hier könnte Dein INTERNER Kommentar interner stehen.\";\n item.json.COMMENT = \"Hier könnte Dein Kommentar interner stehen.\"\n}\n\nreturn $input.all();"
},
"id": "fb6645ac-6ef7-46a8-92cd-67ecb9549c79",
"name": "Code",
"type": "n8n-nodes-base.code",
"typeVersion": 1,
"position": [
840,
480
]
},
{
"parameters": {
"keepOnlySet": true,
"values": {
"string": [
{
"name": "BillbeeShopID",
"value": "97989"
},
{
"name": "X-Billbee-Api-Key",
"value": "={{$env['BILLBEE_API_KEY']}}"
}
]
},
"options": {}
},
"id": "b9512729-4416-4712-a2fb-7aaa63af9f61",
"name": "Billbee ShopID + Token",
"type": "n8n-nodes-base.set",
"typeVersion": 1,
"position": [
380,
180
]
},
{
"parameters": {
"authentication": "basicAuth",
"requestMethod": "POST",
"url": "=https://app.billbee.io/api/v1/orders?shopId={{$node[\"Billbee ShopID + Token\"].parameter[\"values\"][\"string\"][0][\"value\"]}}",
"options": {},
"headerParametersUi": {
"parameter": [
{
"name": "={{$node[\"Billbee ShopID + Token\"].parameter[\"values\"][\"string\"][1][\"name\"]}}",
"value": "={{$env[\"BILLBEE_API_KEY\"}}"
}
]
}
},
"name": "Bestellung an Billbee senden",
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 1,
"position": [
1540,
140
],
"id": "c81d1331-8653-4693-ada1-6697dc9ee038",
"credentials": {
"httpBasicAuth": {
"id": "2",
"name": "Billbee"
}
}
},
{
"parameters": {
"operation": "toFile",
"fileFormat": "csv",
"options": {
"fileName": "=DESADV_ORD_{{$now}}.csv",
"headerRow": true
}
},
"id": "8ad49263-f0f0-4be8-84e3-7cee543e356b",
"name": "Rückmeldung CSV erzeugen",
"type": "n8n-nodes-base.spreadsheetFile",
"typeVersion": 1,
"position": [
1240,
520
]
},
{
"parameters": {
"options": {
"headerRow": true
}
},
"id": "5de70737-ab1b-48e7-8fd7-3a722fbc00a9",
"name": "Auftragsdaten CSV einlesen",
"type": "n8n-nodes-base.spreadsheetFile",
"typeVersion": 1,
"position": [
740,
180
]
},
{
"parameters": {
"keepOnlySet": true,
"values": {
"string": [
{
"name": "Ordernumber",
"value": "={{ $json[\"TB_ORDER_ID\"] }}"
},
{
"name": "InvoiceAddress.Company",
"value": "={{ $json[\"CUST_SELL_EXTENSION\"] }}"
},
{
"name": "InvoiceAddress.Street",
"value": "={{ $json[\"CUST_SELL_STREET_NO\"] }}"
},
{
"name": "InvoiceAddress.City",
"value": "={{ $json[\"CUST_SHIP_CITY\"] }}"
},
{
"name": "InvoiceAddress.Country",
"value": "={{ $json[\"CUST_SELL_COUNTRY_CODE\"] }}"
}
],
"number": [
{
"name": "OrderDate",
"value": "={{ $json[\"ORDER_DATE\"] }}"
}
]
},
"options": {
"dotNotation": true
}
},
"id": "1860ac81-13fb-4b9d-a150-c88e00a80439",
"name": "Set",
"type": "n8n-nodes-base.set",
"typeVersion": 1,
"position": [
980,
180
]
}
],
"pinData": {
"Auftragsdaten CSV einlesen": [
{
"json": {
"TB_ORDER_ID": "orderid",
"CHANNEL_KEY": "",
"CHANNEL_ORDER_ID": "Kanal order id",
"CHANNEL_ORDER_NR": "",
"ORDER_DATE": "datum der Bestellung",
"IDCODE_SHIP": "",
"GPLCODE": "",
"TOTAL_AMOUNT": "",
"SHIPPING_COSTS": "",
"PAYMENT_TYPE": "",
"PAYMENT_COSTS": "",
"PAYMENT_TRANSACTION_ID": "",
"PAYMENT_TRANSACTION_NR": "",
"PAYMENT_TRANSACTION_NAME": "",
"DIRECTDEBIT_ACCOUNTNAME": "",
"DIRECTDEBIT_ACCOUNTNR": "",
"DIRECTDEBIT_BANKNAME": "",
"DIRECTDEBIT_BANKCODE": "",
"CUSTOMER_COMMENT": "",
"TB_CUST_SHIP_ID": "",
"CHANNEL_CUST_SHIP_ID": "",
"CUST_SHIP_SALUTATION": "Lieferadresse Anrede",
"CUST_SHIP_SURNAME": "",
"CUST_SHIP_FIRSTNAME": "Lieferadresse Vorname",
"CUST_SHIP_EXTENSION": "Lieferadresse Zusatz",
"CUST_SHIP_STREET_NO": "Lieferadresse Strasse Husnummer",
"CUST_SHIP_ZIP": "Lieferadresse PLZ",
"CUST_SHIP_CITY": "Lieferadresse Stadt",
"CUST_SHIP_COUNTRY_CODE": "Lieferadresse Land",
"CUST_SHIP_TEL_PRIV": "Lieferadresse Telefon Privat",
"CUST_SHIP_TEL_OFFICE": "Lieferadresse Telefon Büro",
"CUST_SHIP_EMAIL": "Lieferadresse Telefon Email",
"CUST_SHIP_BIRTHDATE": "",
"TB_SELL_CUST_ID": "",
"CHANNEL_SELL_CUST_ID": "",
"CUST_SELL_SALUTATION": "Anrede",
"CUST_SELL_SURNAME": "",
"CUST_SELL_FIRSTNAME": "Vorname",
"CUST_SELL_EXTENSION": "Zusatz",
"CUST_SELL_STREET_NO": "Strasse Hausnummer",
"CUST_SELL_ZIP": "PLZ",
"CUST_SELL_CITY": "Stadt",
"CUST_SELL_COUNTRY_CODE": "Land",
"CUST_SELL_TEL_PRIV": "Tele privat",
"CUST_SELL_TEL_OFFICE": "Tele büro",
"CUST_SELL_EMAIL": "Email",
"CUST_SELL_BIRTHDATE": "",
"CUST_BIRTHDATE": "",
"POS_LFDNR": "Nummer Artikelposition",
"POS_TB_ID": "",
"POS_CHANNEL_ID": "",
"POS_A_ID": "",
"POS_ANR": "Artikelnummer",
"POS_ANR2": "",
"POS_EAN": "EAN",
"POS_TEXT": "Produktbezeichnung",
"POS_QUANTITY": "Menge",
"POS_DELIVERY_TIME": "Lieferzeit",
"POS_SALESPRICE": "Verkaufspreis",
"POS_ANR_CHANNEL": "",
"DIRECTDEBIT_IBAN": "",
"DIRECTDEBIT_BIC": "",
"CUST_SHIP_TEL_MOBILE": "",
"CUST_SELL_TEL_MOBILE": "",
"ORDER_STATUS": "",
"POS_TRANSFER_PRICE": "Kanal EInkaufspreis",
"PAYMENT_DATA": "",
"SERVICE_Code{1}": "",
"SERVICE_Desc{1}": "",
"SERVICE_Price{1}": "",
"SERVICE_Code{2}": "",
"SERVICE_Desc{2}": "",
"SERVICE_Price{2}": "",
"SERVICE_Code{3}": "",
"SERVICE_Desc{3}": "",
"SERVICE_Price{3}": ""
}
},
{
"json": {
"name": "Second item",
"code": 2
}
}
]
},
"settings": {},
"staticData": null,
"tags": [],
"updatedAt": "2023-01-18T17:56:42.913Z"
}