-
-
Save diramazioni/5c834e3e6d7d590ac08a530615aa91c4 to your computer and use it in GitHub Desktop.
[n8n] Webhook send binary bug
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"meta": { | |
"templateCredsSetupCompleted": true, | |
"instanceId": "dde92b23ec8ad53d33ff02dc2a916e6b809358c3f4fb484668669e400dca75cb" | |
}, | |
"nodes": [ | |
{ | |
"parameters": { | |
"operation": "convertToHtmlTable", | |
"options": {} | |
}, | |
"id": "eea34b3f-5459-4651-a19a-7428e0f7f16a", | |
"name": "HTML1", | |
"type": "n8n-nodes-base.html", | |
"typeVersion": 1.2, | |
"position": [ | |
620, | |
1180 | |
] | |
}, | |
{ | |
"parameters": { | |
"html": "<!DOCTYPE html>\n\n<html>\n<head>\n <meta charset=\"UTF-8\" />\n <title>Questionari inviati</title>\n</head>\n<body>\n <h1>Questionari inviati</h1>\n <div class=\"container\">\n{{ $json.table }}\n </div>\n</body>\n</html>\n\n<style>\n.container {\n background-color: #ffffff;\n text-align: center;\n padding: 16px;\n border-radius: 8px;\n}\n\nh1 {\n color: #ff6d5a;\n font-size: 24px;\n font-weight: bold;\n padding: 8px;\n margin: auto\n}\n\nh2 {\n color: #909399;\n font-size: 18px;\n font-weight: bold;\n padding: 8px;\n}\n</style>\n\n<script>\nconsole.log(\"Hello World!\");\n</script>" | |
}, | |
"id": "b99ba194-7b8e-4698-8b67-1f4966188100", | |
"name": "HTML2", | |
"type": "n8n-nodes-base.html", | |
"typeVersion": 1.2, | |
"position": [ | |
800, | |
1180 | |
] | |
}, | |
{ | |
"parameters": { | |
"operation": "toBinary", | |
"sourceProperty": "html", | |
"options": { | |
"dataIsBase64": true, | |
"fileName": "index.html", | |
"mimeType": "text/html" | |
} | |
}, | |
"id": "b243b356-be08-4d15-b865-b560224be665", | |
"name": "Convert to HTML", | |
"type": "n8n-nodes-base.convertToFile", | |
"typeVersion": 1, | |
"position": [ | |
1040, | |
1180 | |
] | |
}, | |
{ | |
"parameters": { | |
"method": "POST", | |
"url": "https://demo.gotenberg.dev/forms/chromium/convert/html", | |
"sendHeaders": true, | |
"headerParameters": { | |
"parameters": [ | |
{ | |
"name": "Gotenberg-Output-Filename", | |
"value": "report" | |
} | |
] | |
}, | |
"sendBody": true, | |
"contentType": "multipart-form-data", | |
"bodyParameters": { | |
"parameters": [ | |
{ | |
"parameterType": "formBinaryData", | |
"name": "files", | |
"inputDataFieldName": "data" | |
} | |
] | |
}, | |
"options": {} | |
}, | |
"id": "ca94eceb-b67a-429e-ad45-378f76046776", | |
"name": "demo api for PDF", | |
"type": "n8n-nodes-base.httpRequest", | |
"typeVersion": 4.1, | |
"position": [ | |
1220, | |
1180 | |
] | |
}, | |
{ | |
"parameters": { | |
"path": "questionario", | |
"formTitle": "test form", | |
"formFields": { | |
"values": [ | |
{ | |
"fieldLabel": "name" | |
}, | |
{ | |
"fieldLabel": "email" | |
} | |
] | |
}, | |
"responseMode": "responseNode" | |
}, | |
"id": "16b3c3e8-b2d7-46f2-95d5-cea63350c082", | |
"name": "test-form", | |
"type": "n8n-nodes-base.formTrigger", | |
"typeVersion": 2, | |
"position": [ | |
360, | |
1180 | |
], | |
"webhookId": "deff863a-4186-4b2c-80c6-f47a6e55dfae" | |
}, | |
{ | |
"parameters": { | |
"respondWith": "binary", | |
"options": {} | |
}, | |
"id": "a24fadaa-b895-4dbc-8f01-5f7bb33c828f", | |
"name": "Respond to Webhook3", | |
"type": "n8n-nodes-base.respondToWebhook", | |
"typeVersion": 1, | |
"position": [ | |
1380, | |
1380 | |
] | |
} | |
], | |
"connections": { | |
"HTML1": { | |
"main": [ | |
[ | |
{ | |
"node": "HTML2", | |
"type": "main", | |
"index": 0 | |
} | |
] | |
] | |
}, | |
"HTML2": { | |
"main": [ | |
[ | |
{ | |
"node": "Convert to HTML", | |
"type": "main", | |
"index": 0 | |
} | |
] | |
] | |
}, | |
"Convert to HTML": { | |
"main": [ | |
[ | |
{ | |
"node": "demo api for PDF", | |
"type": "main", | |
"index": 0 | |
} | |
] | |
] | |
}, | |
"demo api for PDF": { | |
"main": [ | |
[ | |
{ | |
"node": "Respond to Webhook3", | |
"type": "main", | |
"index": 0 | |
} | |
] | |
] | |
}, | |
"test-form": { | |
"main": [ | |
[ | |
{ | |
"node": "HTML1", | |
"type": "main", | |
"index": 0 | |
} | |
] | |
] | |
} | |
}, | |
"pinData": {} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment