@custom-js/n8n-nodes-pdf-toolkit-v2 0.2.0 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/nodes/PdfToolkit/modules/Convert/HtmlToDocx.js +1 -2
- package/dist/nodes/PdfToolkit/modules/Convert/HtmlToPdf.js +1 -2
- package/dist/nodes/PdfToolkit/modules/Convert/JsonToToon.js +1 -2
- package/dist/nodes/PdfToolkit/modules/Convert/MarkdownToHtml.js +1 -2
- package/dist/nodes/PdfToolkit/modules/Convert/PdfToPng.js +3 -7
- package/dist/nodes/PdfToolkit/modules/Convert/PdfToText.js +3 -7
- package/dist/nodes/PdfToolkit/modules/Convert/ToonToJson.js +1 -2
- package/dist/nodes/PdfToolkit/modules/Convert/index.js +1 -2
- package/dist/nodes/PdfToolkit/modules/Data/JsonSelect.js +1 -2
- package/dist/nodes/PdfToolkit/modules/Data/Regex.js +1 -2
- package/dist/nodes/PdfToolkit/modules/Data/index.js +1 -2
- package/dist/nodes/PdfToolkit/modules/PDF/Compress.js +3 -7
- package/dist/nodes/PdfToolkit/modules/PDF/ExtractPages.js +3 -7
- package/dist/nodes/PdfToolkit/modules/PDF/FillForm.js +5 -8
- package/dist/nodes/PdfToolkit/modules/PDF/GenerateInvoice.js +1 -2
- package/dist/nodes/PdfToolkit/modules/PDF/GetFormFields.js +3 -7
- package/dist/nodes/PdfToolkit/modules/PDF/Merge.js +10 -8
- package/dist/nodes/PdfToolkit/modules/PDF/index.js +1 -2
- package/dist/nodes/PdfToolkit/modules/Web/Scrape.js +1 -2
- package/dist/nodes/PdfToolkit/modules/Web/Screenshot.js +1 -2
- package/dist/nodes/PdfToolkit/modules/Web/SslCheck.js +1 -2
- package/dist/nodes/PdfToolkit/modules/Web/index.js +1 -2
- package/package.json +2 -2
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executeHtmlToDocx =
|
|
3
|
+
exports.executeHtmlToDocx = executeHtmlToDocx;
|
|
4
4
|
async function executeHtmlToDocx(executeFunctions, apiHelper, itemIndex) {
|
|
5
5
|
const item = executeFunctions.getInputData()[itemIndex];
|
|
6
6
|
const html = executeFunctions.getNodeParameter('html', itemIndex);
|
|
@@ -21,4 +21,3 @@ async function executeHtmlToDocx(executeFunctions, apiHelper, itemIndex) {
|
|
|
21
21
|
pairedItem: { item: itemIndex }
|
|
22
22
|
};
|
|
23
23
|
}
|
|
24
|
-
exports.executeHtmlToDocx = executeHtmlToDocx;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executeHtmlToPdf =
|
|
3
|
+
exports.executeHtmlToPdf = executeHtmlToPdf;
|
|
4
4
|
async function executeHtmlToPdf(executeFunctions, apiHelper, itemIndex) {
|
|
5
5
|
const item = executeFunctions.getInputData()[itemIndex];
|
|
6
6
|
const html = executeFunctions.getNodeParameter('html', itemIndex);
|
|
@@ -21,4 +21,3 @@ async function executeHtmlToPdf(executeFunctions, apiHelper, itemIndex) {
|
|
|
21
21
|
pairedItem: { item: itemIndex }
|
|
22
22
|
};
|
|
23
23
|
}
|
|
24
|
-
exports.executeHtmlToPdf = executeHtmlToPdf;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executeJsonToToon =
|
|
3
|
+
exports.executeJsonToToon = executeJsonToToon;
|
|
4
4
|
async function executeJsonToToon(executeFunctions, apiHelper, itemIndex) {
|
|
5
5
|
const item = executeFunctions.getInputData()[itemIndex];
|
|
6
6
|
const json = executeFunctions.getNodeParameter('json', itemIndex);
|
|
@@ -12,4 +12,3 @@ async function executeJsonToToon(executeFunctions, apiHelper, itemIndex) {
|
|
|
12
12
|
const response = await apiHelper.makeRequest('make/jsonToToon', body, false, itemIndex);
|
|
13
13
|
return { json: { toon: response }, pairedItem: { item: itemIndex } };
|
|
14
14
|
}
|
|
15
|
-
exports.executeJsonToToon = executeJsonToToon;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executeMarkdownToHtml =
|
|
3
|
+
exports.executeMarkdownToHtml = executeMarkdownToHtml;
|
|
4
4
|
async function executeMarkdownToHtml(executeFunctions, apiHelper, itemIndex) {
|
|
5
5
|
const item = executeFunctions.getInputData()[itemIndex];
|
|
6
6
|
const markdown = executeFunctions.getNodeParameter('markdown', itemIndex);
|
|
@@ -12,4 +12,3 @@ async function executeMarkdownToHtml(executeFunctions, apiHelper, itemIndex) {
|
|
|
12
12
|
const response = await apiHelper.makeRequest('n8n/markdown2html', body, false, itemIndex);
|
|
13
13
|
return { json: { output: response.toString() }, pairedItem: { item: itemIndex } };
|
|
14
14
|
}
|
|
15
|
-
exports.executeMarkdownToHtml = executeMarkdownToHtml;
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executePdfToPng =
|
|
3
|
+
exports.executePdfToPng = executePdfToPng;
|
|
4
4
|
async function executePdfToPng(executeFunctions, apiHelper, itemIndex) {
|
|
5
|
-
var _a;
|
|
6
5
|
const item = executeFunctions.getInputData()[itemIndex];
|
|
7
6
|
const inputType = executeFunctions.getNodeParameter('inputType', itemIndex);
|
|
8
7
|
const body = {
|
|
@@ -14,10 +13,8 @@ async function executePdfToPng(executeFunctions, apiHelper, itemIndex) {
|
|
|
14
13
|
};
|
|
15
14
|
if (inputType === 'binary') {
|
|
16
15
|
const binaryPropertyName = executeFunctions.getNodeParameter('binaryPropertyName', itemIndex);
|
|
17
|
-
const
|
|
18
|
-
|
|
19
|
-
throw new Error(`Binary property ${binaryPropertyName} not found`);
|
|
20
|
-
body.input = { file: Buffer.from(binaryData.data, 'base64') };
|
|
16
|
+
const buffer = await executeFunctions.helpers.getBinaryDataBuffer(itemIndex, binaryPropertyName);
|
|
17
|
+
body.input = { file: buffer };
|
|
21
18
|
}
|
|
22
19
|
else {
|
|
23
20
|
const url = executeFunctions.getNodeParameter('url', itemIndex);
|
|
@@ -35,4 +32,3 @@ async function executePdfToPng(executeFunctions, apiHelper, itemIndex) {
|
|
|
35
32
|
pairedItem: { item: itemIndex }
|
|
36
33
|
};
|
|
37
34
|
}
|
|
38
|
-
exports.executePdfToPng = executePdfToPng;
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executePdfToText =
|
|
3
|
+
exports.executePdfToText = executePdfToText;
|
|
4
4
|
async function executePdfToText(executeFunctions, apiHelper, itemIndex) {
|
|
5
|
-
var _a;
|
|
6
5
|
const item = executeFunctions.getInputData()[itemIndex];
|
|
7
6
|
const inputType = executeFunctions.getNodeParameter('inputType', itemIndex);
|
|
8
7
|
const body = {
|
|
@@ -14,10 +13,8 @@ async function executePdfToText(executeFunctions, apiHelper, itemIndex) {
|
|
|
14
13
|
};
|
|
15
14
|
if (inputType === 'binary') {
|
|
16
15
|
const binaryPropertyName = executeFunctions.getNodeParameter('binaryPropertyName', itemIndex);
|
|
17
|
-
const
|
|
18
|
-
|
|
19
|
-
throw new Error(`Binary property ${binaryPropertyName} not found`);
|
|
20
|
-
body.input = { file: Buffer.from(binaryData.data, 'base64') };
|
|
16
|
+
const buffer = await executeFunctions.helpers.getBinaryDataBuffer(itemIndex, binaryPropertyName);
|
|
17
|
+
body.input = { file: buffer };
|
|
21
18
|
}
|
|
22
19
|
else {
|
|
23
20
|
const url = executeFunctions.getNodeParameter('url', itemIndex);
|
|
@@ -26,4 +23,3 @@ async function executePdfToText(executeFunctions, apiHelper, itemIndex) {
|
|
|
26
23
|
const response = await apiHelper.makeRequest('n8n/pdfToText', body, false, itemIndex);
|
|
27
24
|
return { json: response, pairedItem: { item: itemIndex } };
|
|
28
25
|
}
|
|
29
|
-
exports.executePdfToText = executePdfToText;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executeToonToJson =
|
|
3
|
+
exports.executeToonToJson = executeToonToJson;
|
|
4
4
|
async function executeToonToJson(executeFunctions, apiHelper, itemIndex) {
|
|
5
5
|
const item = executeFunctions.getInputData()[itemIndex];
|
|
6
6
|
const toon = executeFunctions.getNodeParameter('toon', itemIndex);
|
|
@@ -12,4 +12,3 @@ async function executeToonToJson(executeFunctions, apiHelper, itemIndex) {
|
|
|
12
12
|
const response = await apiHelper.makeRequest('make/toonToJson', body, false, itemIndex);
|
|
13
13
|
return { json: response, pairedItem: { item: itemIndex } };
|
|
14
14
|
}
|
|
15
|
-
exports.executeToonToJson = executeToonToJson;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executeConvert =
|
|
3
|
+
exports.executeConvert = executeConvert;
|
|
4
4
|
const PdfToPng_1 = require("./PdfToPng");
|
|
5
5
|
const PdfToText_1 = require("./PdfToText");
|
|
6
6
|
const HtmlToDocx_1 = require("./HtmlToDocx");
|
|
@@ -28,4 +28,3 @@ async function executeConvert(executeFunctions, apiHelper, itemIndex, operation)
|
|
|
28
28
|
throw new Error(`Unknown operation: ${operation}`);
|
|
29
29
|
}
|
|
30
30
|
}
|
|
31
|
-
exports.executeConvert = executeConvert;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executeJsonSelect =
|
|
3
|
+
exports.executeJsonSelect = executeJsonSelect;
|
|
4
4
|
async function executeJsonSelect(executeFunctions, apiHelper, itemIndex) {
|
|
5
5
|
const item = executeFunctions.getInputData()[itemIndex];
|
|
6
6
|
const json = executeFunctions.getNodeParameter('json', itemIndex);
|
|
@@ -13,4 +13,3 @@ async function executeJsonSelect(executeFunctions, apiHelper, itemIndex) {
|
|
|
13
13
|
const response = await apiHelper.makeRequest('make/jsonSelector', body, false, itemIndex);
|
|
14
14
|
return { json: { result: response }, pairedItem: { item: itemIndex } };
|
|
15
15
|
}
|
|
16
|
-
exports.executeJsonSelect = executeJsonSelect;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executeRegex =
|
|
3
|
+
exports.executeRegex = executeRegex;
|
|
4
4
|
async function executeRegex(executeFunctions, apiHelper, itemIndex) {
|
|
5
5
|
const item = executeFunctions.getInputData()[itemIndex];
|
|
6
6
|
const textData = executeFunctions.getNodeParameter('textData', itemIndex);
|
|
@@ -16,4 +16,3 @@ async function executeRegex(executeFunctions, apiHelper, itemIndex) {
|
|
|
16
16
|
const response = await apiHelper.makeRequest('make/regexTool', body, false, itemIndex);
|
|
17
17
|
return { json: { result: response }, pairedItem: { item: itemIndex } };
|
|
18
18
|
}
|
|
19
|
-
exports.executeRegex = executeRegex;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executeData =
|
|
3
|
+
exports.executeData = executeData;
|
|
4
4
|
const JsonSelect_1 = require("./JsonSelect");
|
|
5
5
|
const Regex_1 = require("./Regex");
|
|
6
6
|
async function executeData(executeFunctions, apiHelper, itemIndex, operation) {
|
|
@@ -13,4 +13,3 @@ async function executeData(executeFunctions, apiHelper, itemIndex, operation) {
|
|
|
13
13
|
throw new Error(`Unknown operation: ${operation}`);
|
|
14
14
|
}
|
|
15
15
|
}
|
|
16
|
-
exports.executeData = executeData;
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executeCompress =
|
|
3
|
+
exports.executeCompress = executeCompress;
|
|
4
4
|
async function executeCompress(executeFunctions, apiHelper, itemIndex) {
|
|
5
|
-
var _a;
|
|
6
5
|
const item = executeFunctions.getInputData()[itemIndex];
|
|
7
6
|
const inputType = executeFunctions.getNodeParameter('inputType', itemIndex);
|
|
8
7
|
const body = {
|
|
@@ -14,10 +13,8 @@ async function executeCompress(executeFunctions, apiHelper, itemIndex) {
|
|
|
14
13
|
};
|
|
15
14
|
if (inputType === 'binary') {
|
|
16
15
|
const binaryPropertyName = executeFunctions.getNodeParameter('binaryPropertyName', itemIndex);
|
|
17
|
-
const
|
|
18
|
-
|
|
19
|
-
throw new Error(`Binary property ${binaryPropertyName} not found`);
|
|
20
|
-
body.input = { file: Buffer.from(binaryData.data, 'base64') };
|
|
16
|
+
const buffer = await executeFunctions.helpers.getBinaryDataBuffer(itemIndex, binaryPropertyName);
|
|
17
|
+
body.input = { file: buffer };
|
|
21
18
|
}
|
|
22
19
|
else {
|
|
23
20
|
const url = executeFunctions.getNodeParameter('url', itemIndex);
|
|
@@ -35,4 +32,3 @@ async function executeCompress(executeFunctions, apiHelper, itemIndex) {
|
|
|
35
32
|
pairedItem: { item: itemIndex }
|
|
36
33
|
};
|
|
37
34
|
}
|
|
38
|
-
exports.executeCompress = executeCompress;
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executeExtractPages =
|
|
3
|
+
exports.executeExtractPages = executeExtractPages;
|
|
4
4
|
async function executeExtractPages(executeFunctions, apiHelper, itemIndex) {
|
|
5
|
-
var _a;
|
|
6
5
|
const item = executeFunctions.getInputData()[itemIndex];
|
|
7
6
|
const inputType = executeFunctions.getNodeParameter('inputType', itemIndex);
|
|
8
7
|
const pageRange = executeFunctions.getNodeParameter('pageRange', itemIndex);
|
|
@@ -15,10 +14,8 @@ async function executeExtractPages(executeFunctions, apiHelper, itemIndex) {
|
|
|
15
14
|
};
|
|
16
15
|
if (inputType === 'binary') {
|
|
17
16
|
const binaryPropertyName = executeFunctions.getNodeParameter('binaryPropertyName', itemIndex);
|
|
18
|
-
const
|
|
19
|
-
|
|
20
|
-
throw new Error(`Binary property ${binaryPropertyName} not found`);
|
|
21
|
-
body.input = { file: Buffer.from(binaryData.data, 'base64'), pageRange };
|
|
17
|
+
const buffer = await executeFunctions.helpers.getBinaryDataBuffer(itemIndex, binaryPropertyName);
|
|
18
|
+
body.input = { file: buffer, pageRange };
|
|
22
19
|
}
|
|
23
20
|
else {
|
|
24
21
|
const url = executeFunctions.getNodeParameter('url', itemIndex);
|
|
@@ -36,4 +33,3 @@ async function executeExtractPages(executeFunctions, apiHelper, itemIndex) {
|
|
|
36
33
|
pairedItem: { item: itemIndex }
|
|
37
34
|
};
|
|
38
35
|
}
|
|
39
|
-
exports.executeExtractPages = executeExtractPages;
|
|
@@ -1,16 +1,14 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executeFillForm =
|
|
3
|
+
exports.executeFillForm = executeFillForm;
|
|
4
4
|
async function executeFillForm(executeFunctions, apiHelper, itemIndex) {
|
|
5
|
-
var _a
|
|
5
|
+
var _a;
|
|
6
6
|
const item = executeFunctions.getInputData()[itemIndex];
|
|
7
7
|
const binaryPropertyName = executeFunctions.getNodeParameter('binaryPropertyName', itemIndex);
|
|
8
|
-
const
|
|
9
|
-
|
|
10
|
-
throw new Error(`Binary property ${binaryPropertyName} not found`);
|
|
11
|
-
const formFields = ((_b = executeFunctions.getNodeParameter('formFields', itemIndex)) === null || _b === void 0 ? void 0 : _b.field) || [];
|
|
8
|
+
const buffer = await executeFunctions.helpers.getBinaryDataBuffer(itemIndex, binaryPropertyName);
|
|
9
|
+
const formFields = ((_a = executeFunctions.getNodeParameter('formFields', itemIndex)) === null || _a === void 0 ? void 0 : _a.field) || [];
|
|
12
10
|
const body = {
|
|
13
|
-
input: { file:
|
|
11
|
+
input: { file: buffer, fields: formFields },
|
|
14
12
|
code: `
|
|
15
13
|
const { PDF_FILL_FORM } = require('./utils');
|
|
16
14
|
const pdfInput = input.file;
|
|
@@ -30,4 +28,3 @@ async function executeFillForm(executeFunctions, apiHelper, itemIndex) {
|
|
|
30
28
|
pairedItem: { item: itemIndex }
|
|
31
29
|
};
|
|
32
30
|
}
|
|
33
|
-
exports.executeFillForm = executeFillForm;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executeGenerateInvoice =
|
|
3
|
+
exports.executeGenerateInvoice = executeGenerateInvoice;
|
|
4
4
|
async function executeGenerateInvoice(executeFunctions, apiHelper, itemIndex) {
|
|
5
5
|
const item = executeFunctions.getInputData()[itemIndex];
|
|
6
6
|
const issuer = executeFunctions.getNodeParameter('issuer.issuerValues', itemIndex);
|
|
@@ -33,4 +33,3 @@ async function executeGenerateInvoice(executeFunctions, apiHelper, itemIndex) {
|
|
|
33
33
|
pairedItem: { item: itemIndex }
|
|
34
34
|
};
|
|
35
35
|
}
|
|
36
|
-
exports.executeGenerateInvoice = executeGenerateInvoice;
|
|
@@ -1,15 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executeGetFormFields =
|
|
3
|
+
exports.executeGetFormFields = executeGetFormFields;
|
|
4
4
|
async function executeGetFormFields(executeFunctions, apiHelper, itemIndex) {
|
|
5
|
-
var _a;
|
|
6
5
|
const item = executeFunctions.getInputData()[itemIndex];
|
|
7
6
|
const binaryPropertyName = executeFunctions.getNodeParameter('binaryPropertyName', itemIndex);
|
|
8
|
-
const
|
|
9
|
-
if (!binaryData)
|
|
10
|
-
throw new Error(`Binary property ${binaryPropertyName} not found`);
|
|
7
|
+
const buffer = await executeFunctions.helpers.getBinaryDataBuffer(itemIndex, binaryPropertyName);
|
|
11
8
|
const body = {
|
|
12
|
-
input: { file:
|
|
9
|
+
input: { file: buffer },
|
|
13
10
|
code: `
|
|
14
11
|
const { PDF_GET_FORM_FIELD_NAMES } = require('./utils');
|
|
15
12
|
const pdfInput = input.file;
|
|
@@ -19,4 +16,3 @@ async function executeGetFormFields(executeFunctions, apiHelper, itemIndex) {
|
|
|
19
16
|
const response = await apiHelper.makeRequest('n8n/getFormFieldNames', body, false, itemIndex);
|
|
20
17
|
return { json: response, pairedItem: { item: itemIndex } };
|
|
21
18
|
}
|
|
22
|
-
exports.executeGetFormFields = executeGetFormFields;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executeMerge =
|
|
3
|
+
exports.executeMerge = executeMerge;
|
|
4
4
|
async function executeMerge(executeFunctions, apiHelper, itemIndex) {
|
|
5
5
|
const item = executeFunctions.getInputData()[itemIndex];
|
|
6
6
|
const inputType = executeFunctions.getNodeParameter('inputType', itemIndex);
|
|
@@ -16,12 +16,15 @@ async function executeMerge(executeFunctions, apiHelper, itemIndex) {
|
|
|
16
16
|
if (itemIndex > 0)
|
|
17
17
|
return { json: {}, pairedItem: { item: itemIndex } }; // Skip subsequent items
|
|
18
18
|
const items = executeFunctions.getInputData();
|
|
19
|
-
const
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
19
|
+
const binaryPropertyName = executeFunctions.getNodeParameter('binaryPropertyName', 0);
|
|
20
|
+
const files = await Promise.all(items.map(async (itm, idx) => {
|
|
21
|
+
if (itm.binary && itm.binary[binaryPropertyName]) {
|
|
22
|
+
return await executeFunctions.helpers.getBinaryDataBuffer(idx, binaryPropertyName);
|
|
23
|
+
}
|
|
24
|
+
return null;
|
|
25
|
+
}));
|
|
26
|
+
const validFiles = files.filter(f => f);
|
|
27
|
+
body.input = { files: validFiles };
|
|
25
28
|
}
|
|
26
29
|
else {
|
|
27
30
|
const urls = executeFunctions.getNodeParameter('urls', itemIndex);
|
|
@@ -44,4 +47,3 @@ async function executeMerge(executeFunctions, apiHelper, itemIndex) {
|
|
|
44
47
|
pairedItem: { item: itemIndex }
|
|
45
48
|
};
|
|
46
49
|
}
|
|
47
|
-
exports.executeMerge = executeMerge;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executePDF =
|
|
3
|
+
exports.executePDF = executePDF;
|
|
4
4
|
const Compress_1 = require("./Compress");
|
|
5
5
|
const Merge_1 = require("./Merge");
|
|
6
6
|
const ExtractPages_1 = require("./ExtractPages");
|
|
@@ -25,4 +25,3 @@ async function executePDF(executeFunctions, apiHelper, itemIndex, operation) {
|
|
|
25
25
|
throw new Error(`Unknown operation: ${operation}`);
|
|
26
26
|
}
|
|
27
27
|
}
|
|
28
|
-
exports.executePDF = executePDF;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executeScrape =
|
|
3
|
+
exports.executeScrape = executeScrape;
|
|
4
4
|
async function executeScrape(executeFunctions, apiHelper, itemIndex) {
|
|
5
5
|
const item = executeFunctions.getInputData()[itemIndex];
|
|
6
6
|
const url = executeFunctions.getNodeParameter('url', itemIndex);
|
|
@@ -29,4 +29,3 @@ async function executeScrape(executeFunctions, apiHelper, itemIndex) {
|
|
|
29
29
|
return { json: { output: response.toString() }, pairedItem: { item: itemIndex } };
|
|
30
30
|
}
|
|
31
31
|
}
|
|
32
|
-
exports.executeScrape = executeScrape;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executeScreenshot =
|
|
3
|
+
exports.executeScreenshot = executeScreenshot;
|
|
4
4
|
async function executeScreenshot(executeFunctions, apiHelper, itemIndex) {
|
|
5
5
|
const item = executeFunctions.getInputData()[itemIndex];
|
|
6
6
|
const url = executeFunctions.getNodeParameter('url', itemIndex);
|
|
@@ -21,4 +21,3 @@ async function executeScreenshot(executeFunctions, apiHelper, itemIndex) {
|
|
|
21
21
|
pairedItem: { item: itemIndex }
|
|
22
22
|
};
|
|
23
23
|
}
|
|
24
|
-
exports.executeScreenshot = executeScreenshot;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executeSslCheck =
|
|
3
|
+
exports.executeSslCheck = executeSslCheck;
|
|
4
4
|
async function executeSslCheck(executeFunctions, apiHelper, itemIndex) {
|
|
5
5
|
const item = executeFunctions.getInputData()[itemIndex];
|
|
6
6
|
const domain = executeFunctions.getNodeParameter('domain', itemIndex);
|
|
@@ -12,4 +12,3 @@ async function executeSslCheck(executeFunctions, apiHelper, itemIndex) {
|
|
|
12
12
|
const response = await apiHelper.makeRequest('n8n/sslchecker', body, false, itemIndex);
|
|
13
13
|
return { json: response, pairedItem: { item: itemIndex } };
|
|
14
14
|
}
|
|
15
|
-
exports.executeSslCheck = executeSslCheck;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executeWeb =
|
|
3
|
+
exports.executeWeb = executeWeb;
|
|
4
4
|
const Scrape_1 = require("./Scrape");
|
|
5
5
|
const Screenshot_1 = require("./Screenshot");
|
|
6
6
|
const SslCheck_1 = require("./SslCheck");
|
|
@@ -16,4 +16,3 @@ async function executeWeb(executeFunctions, apiHelper, itemIndex, operation) {
|
|
|
16
16
|
throw new Error(`Unknown operation: ${operation}`);
|
|
17
17
|
}
|
|
18
18
|
}
|
|
19
|
-
exports.executeWeb = executeWeb;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@custom-js/n8n-nodes-pdf-toolkit-v2",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.0",
|
|
4
4
|
"description": "This is official node for interacting with APIs from customjs.space",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"customjs",
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
"devDependencies": {
|
|
35
35
|
"@types/node": "^16.11.7",
|
|
36
36
|
"gulp": "^4.0.2",
|
|
37
|
-
"typescript": "
|
|
37
|
+
"typescript": "^5.0.0"
|
|
38
38
|
},
|
|
39
39
|
"peerDependencies": {
|
|
40
40
|
"n8n-workflow": "^1.64.0"
|