n8n-nodes-crawl4ai-onuro 0.2.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.
Files changed (71) hide show
  1. package/LICENSE +21 -0
  2. package/LICENSE.md +19 -0
  3. package/README.md +129 -0
  4. package/dist/credentials/Crawl4aiApi.credentials.d.ts +7 -0
  5. package/dist/credentials/Crawl4aiApi.credentials.js +228 -0
  6. package/dist/credentials/Crawl4aiApi.credentials.js.map +1 -0
  7. package/dist/nodes/Crawl4aiBasicCrawler/Crawl4aiBasicCrawler.node.d.ts +5 -0
  8. package/dist/nodes/Crawl4aiBasicCrawler/Crawl4aiBasicCrawler.node.js +37 -0
  9. package/dist/nodes/Crawl4aiBasicCrawler/Crawl4aiBasicCrawler.node.js.map +1 -0
  10. package/dist/nodes/Crawl4aiBasicCrawler/actions/crawlMultipleUrls.operation.d.ts +4 -0
  11. package/dist/nodes/Crawl4aiBasicCrawler/actions/crawlMultipleUrls.operation.js +421 -0
  12. package/dist/nodes/Crawl4aiBasicCrawler/actions/crawlMultipleUrls.operation.js.map +1 -0
  13. package/dist/nodes/Crawl4aiBasicCrawler/actions/crawlSingleUrl.operation.d.ts +4 -0
  14. package/dist/nodes/Crawl4aiBasicCrawler/actions/crawlSingleUrl.operation.js +422 -0
  15. package/dist/nodes/Crawl4aiBasicCrawler/actions/crawlSingleUrl.operation.js.map +1 -0
  16. package/dist/nodes/Crawl4aiBasicCrawler/actions/operations.d.ts +8 -0
  17. package/dist/nodes/Crawl4aiBasicCrawler/actions/operations.js +67 -0
  18. package/dist/nodes/Crawl4aiBasicCrawler/actions/operations.js.map +1 -0
  19. package/dist/nodes/Crawl4aiBasicCrawler/actions/processRawHtml.operation.d.ts +4 -0
  20. package/dist/nodes/Crawl4aiBasicCrawler/actions/processRawHtml.operation.js +148 -0
  21. package/dist/nodes/Crawl4aiBasicCrawler/actions/processRawHtml.operation.js.map +1 -0
  22. package/dist/nodes/Crawl4aiBasicCrawler/actions/router.d.ts +2 -0
  23. package/dist/nodes/Crawl4aiBasicCrawler/actions/router.js +37 -0
  24. package/dist/nodes/Crawl4aiBasicCrawler/actions/router.js.map +1 -0
  25. package/dist/nodes/Crawl4aiBasicCrawler/crawl4ai.svg +6 -0
  26. package/dist/nodes/Crawl4aiBasicCrawler/helpers/apiClient.d.ts +15 -0
  27. package/dist/nodes/Crawl4aiBasicCrawler/helpers/apiClient.js +271 -0
  28. package/dist/nodes/Crawl4aiBasicCrawler/helpers/apiClient.js.map +1 -0
  29. package/dist/nodes/Crawl4aiBasicCrawler/helpers/formatters.d.ts +5 -0
  30. package/dist/nodes/Crawl4aiBasicCrawler/helpers/formatters.js +96 -0
  31. package/dist/nodes/Crawl4aiBasicCrawler/helpers/formatters.js.map +1 -0
  32. package/dist/nodes/Crawl4aiBasicCrawler/helpers/interfaces.d.ts +119 -0
  33. package/dist/nodes/Crawl4aiBasicCrawler/helpers/interfaces.js +3 -0
  34. package/dist/nodes/Crawl4aiBasicCrawler/helpers/interfaces.js.map +1 -0
  35. package/dist/nodes/Crawl4aiBasicCrawler/helpers/utils.d.ts +8 -0
  36. package/dist/nodes/Crawl4aiBasicCrawler/helpers/utils.js +80 -0
  37. package/dist/nodes/Crawl4aiBasicCrawler/helpers/utils.js.map +1 -0
  38. package/dist/nodes/Crawl4aiContentExtractor/Crawl4aiContentExtractor.node.d.ts +5 -0
  39. package/dist/nodes/Crawl4aiContentExtractor/Crawl4aiContentExtractor.node.js +38 -0
  40. package/dist/nodes/Crawl4aiContentExtractor/Crawl4aiContentExtractor.node.js.map +1 -0
  41. package/dist/nodes/Crawl4aiContentExtractor/actions/cssExtractor.operation.d.ts +4 -0
  42. package/dist/nodes/Crawl4aiContentExtractor/actions/cssExtractor.operation.js +295 -0
  43. package/dist/nodes/Crawl4aiContentExtractor/actions/cssExtractor.operation.js.map +1 -0
  44. package/dist/nodes/Crawl4aiContentExtractor/actions/jsonExtractor.operation.d.ts +4 -0
  45. package/dist/nodes/Crawl4aiContentExtractor/actions/jsonExtractor.operation.js +328 -0
  46. package/dist/nodes/Crawl4aiContentExtractor/actions/jsonExtractor.operation.js.map +1 -0
  47. package/dist/nodes/Crawl4aiContentExtractor/actions/llmExtractor.operation.d.ts +4 -0
  48. package/dist/nodes/Crawl4aiContentExtractor/actions/llmExtractor.operation.js +417 -0
  49. package/dist/nodes/Crawl4aiContentExtractor/actions/llmExtractor.operation.js.map +1 -0
  50. package/dist/nodes/Crawl4aiContentExtractor/actions/operations.d.ts +8 -0
  51. package/dist/nodes/Crawl4aiContentExtractor/actions/operations.js +67 -0
  52. package/dist/nodes/Crawl4aiContentExtractor/actions/operations.js.map +1 -0
  53. package/dist/nodes/Crawl4aiContentExtractor/actions/router.d.ts +2 -0
  54. package/dist/nodes/Crawl4aiContentExtractor/actions/router.js +37 -0
  55. package/dist/nodes/Crawl4aiContentExtractor/actions/router.js.map +1 -0
  56. package/dist/nodes/Crawl4aiContentExtractor/crawl4ai.svg +6 -0
  57. package/dist/nodes/Crawl4aiContentExtractor/helpers/apiClient.d.ts +1 -0
  58. package/dist/nodes/Crawl4aiContentExtractor/helpers/apiClient.js +7 -0
  59. package/dist/nodes/Crawl4aiContentExtractor/helpers/apiClient.js.map +1 -0
  60. package/dist/nodes/Crawl4aiContentExtractor/helpers/formatters.d.ts +1 -0
  61. package/dist/nodes/Crawl4aiContentExtractor/helpers/formatters.js +8 -0
  62. package/dist/nodes/Crawl4aiContentExtractor/helpers/formatters.js.map +1 -0
  63. package/dist/nodes/Crawl4aiContentExtractor/helpers/interfaces.d.ts +1 -0
  64. package/dist/nodes/Crawl4aiContentExtractor/helpers/interfaces.js +3 -0
  65. package/dist/nodes/Crawl4aiContentExtractor/helpers/interfaces.js.map +1 -0
  66. package/dist/nodes/Crawl4aiContentExtractor/helpers/utils.d.ts +9 -0
  67. package/dist/nodes/Crawl4aiContentExtractor/helpers/utils.js +93 -0
  68. package/dist/nodes/Crawl4aiContentExtractor/helpers/utils.js.map +1 -0
  69. package/dist/tsconfig.tsbuildinfo +1 -0
  70. package/index.js +14 -0
  71. package/package.json +68 -0
@@ -0,0 +1,328 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.description = void 0;
4
+ exports.execute = execute;
5
+ const n8n_workflow_1 = require("n8n-workflow");
6
+ const utils_1 = require("../helpers/utils");
7
+ exports.description = [
8
+ {
9
+ displayName: 'URL',
10
+ name: 'url',
11
+ type: 'string',
12
+ required: true,
13
+ default: '',
14
+ placeholder: 'https://example.com/api/data.json',
15
+ description: 'The URL of the JSON data to extract',
16
+ displayOptions: {
17
+ show: {
18
+ operation: ['jsonExtractor'],
19
+ },
20
+ },
21
+ },
22
+ {
23
+ displayName: 'JSON Path',
24
+ name: 'jsonPath',
25
+ type: 'string',
26
+ default: '',
27
+ placeholder: 'data.items',
28
+ description: 'Path to the JSON data to extract (leave empty for entire JSON response)',
29
+ displayOptions: {
30
+ show: {
31
+ operation: ['jsonExtractor'],
32
+ },
33
+ },
34
+ },
35
+ {
36
+ displayName: 'Source Type',
37
+ name: 'sourceType',
38
+ type: 'options',
39
+ options: [
40
+ {
41
+ name: 'Direct JSON URL',
42
+ value: 'direct',
43
+ description: 'URL returns JSON directly',
44
+ },
45
+ {
46
+ name: 'JSON in Script Tag',
47
+ value: 'script',
48
+ description: 'JSON is embedded in a <script> tag',
49
+ },
50
+ {
51
+ name: 'JSON-LD',
52
+ value: 'jsonld',
53
+ description: 'JSON-LD structured data',
54
+ },
55
+ ],
56
+ default: 'direct',
57
+ description: 'Where to find the JSON data on the page',
58
+ displayOptions: {
59
+ show: {
60
+ operation: ['jsonExtractor'],
61
+ },
62
+ },
63
+ },
64
+ {
65
+ displayName: 'Script Selector',
66
+ name: 'scriptSelector',
67
+ type: 'string',
68
+ default: '',
69
+ placeholder: 'script#__NEXT_DATA__',
70
+ description: 'CSS selector for the script tag containing JSON data',
71
+ displayOptions: {
72
+ show: {
73
+ operation: ['jsonExtractor'],
74
+ sourceType: ['script'],
75
+ },
76
+ },
77
+ },
78
+ {
79
+ displayName: 'Browser Options',
80
+ name: 'browserOptions',
81
+ type: 'collection',
82
+ placeholder: 'Add Option',
83
+ default: {},
84
+ displayOptions: {
85
+ show: {
86
+ operation: ['jsonExtractor'],
87
+ },
88
+ },
89
+ options: [
90
+ {
91
+ displayName: 'Headless Mode',
92
+ name: 'headless',
93
+ type: 'boolean',
94
+ default: true,
95
+ description: 'Whether to run browser in headless mode',
96
+ },
97
+ {
98
+ displayName: 'Enable JavaScript',
99
+ name: 'javaScriptEnabled',
100
+ type: 'boolean',
101
+ default: true,
102
+ description: 'Whether to enable JavaScript execution',
103
+ },
104
+ {
105
+ displayName: 'Timeout (MS)',
106
+ name: 'timeout',
107
+ type: 'number',
108
+ default: 30000,
109
+ description: 'Maximum time to wait for the browser to load the page',
110
+ },
111
+ {
112
+ displayName: 'JavaScript Code',
113
+ name: 'jsCode',
114
+ type: 'string',
115
+ typeOptions: {
116
+ rows: 4,
117
+ },
118
+ default: '',
119
+ placeholder: 'window.scrollTo(0, document.body.scrollHeight);',
120
+ description: 'JavaScript code to execute before extraction',
121
+ },
122
+ ],
123
+ },
124
+ {
125
+ displayName: 'Options',
126
+ name: 'options',
127
+ type: 'collection',
128
+ placeholder: 'Add Option',
129
+ default: {},
130
+ displayOptions: {
131
+ show: {
132
+ operation: ['jsonExtractor'],
133
+ },
134
+ },
135
+ options: [
136
+ {
137
+ displayName: 'Cache Mode',
138
+ name: 'cacheMode',
139
+ type: 'options',
140
+ options: [
141
+ {
142
+ name: 'Enabled (Read/Write)',
143
+ value: 'enabled',
144
+ description: 'Use cache if available, save new results to cache',
145
+ },
146
+ {
147
+ name: 'Bypass (Force Fresh)',
148
+ value: 'bypass',
149
+ description: 'Ignore cache, always fetch fresh content',
150
+ },
151
+ {
152
+ name: 'Only (Read Only)',
153
+ value: 'only',
154
+ description: 'Only use cache, do not make new requests',
155
+ },
156
+ ],
157
+ default: 'enabled',
158
+ description: 'How to use the cache when crawling',
159
+ },
160
+ {
161
+ displayName: 'Include Full Content',
162
+ name: 'includeFullContent',
163
+ type: 'boolean',
164
+ default: false,
165
+ description: 'Whether to include the full JSON content in addition to the extracted data',
166
+ },
167
+ {
168
+ displayName: 'Headers',
169
+ name: 'headers',
170
+ type: 'string',
171
+ typeOptions: {
172
+ rows: 2,
173
+ },
174
+ default: '',
175
+ placeholder: '{"accept": "application/json"}',
176
+ description: 'Headers to send with the request (JSON format)',
177
+ },
178
+ ],
179
+ },
180
+ ];
181
+ async function execute(items, nodeOptions) {
182
+ var _a, _b;
183
+ const allResults = [];
184
+ for (let i = 0; i < items.length; i++) {
185
+ try {
186
+ const url = this.getNodeParameter('url', i, '');
187
+ const jsonPath = this.getNodeParameter('jsonPath', i, '');
188
+ const sourceType = this.getNodeParameter('sourceType', i, 'direct');
189
+ const scriptSelector = this.getNodeParameter('scriptSelector', i, '');
190
+ const browserOptions = this.getNodeParameter('browserOptions', i, {});
191
+ const options = this.getNodeParameter('options', i, {});
192
+ if (!url) {
193
+ throw new n8n_workflow_1.NodeOperationError(this.getNode(), 'URL cannot be empty.', { itemIndex: i });
194
+ }
195
+ if (!(0, utils_1.isValidUrl)(url)) {
196
+ throw new n8n_workflow_1.NodeOperationError(this.getNode(), `Invalid URL: ${url}`, { itemIndex: i });
197
+ }
198
+ if (sourceType === 'script' && !scriptSelector) {
199
+ throw new n8n_workflow_1.NodeOperationError(this.getNode(), 'Script selector is required when source type is "JSON in Script Tag".', { itemIndex: i });
200
+ }
201
+ let headers;
202
+ if (options.headers && typeof options.headers === 'string') {
203
+ try {
204
+ headers = JSON.parse(options.headers);
205
+ }
206
+ catch (error) {
207
+ throw new n8n_workflow_1.NodeOperationError(this.getNode(), 'Headers must be a valid JSON object.', { itemIndex: i });
208
+ }
209
+ }
210
+ const browserConfig = (0, utils_1.createBrowserConfig)(browserOptions);
211
+ const crawler = await (0, utils_1.getCrawl4aiClient)(this);
212
+ const extractionStrategy = {
213
+ type: 'JsonCssExtractionStrategy',
214
+ params: {
215
+ schema: {
216
+ type: 'dict',
217
+ value: {
218
+ name: 'json_extraction',
219
+ baseSelector: sourceType === 'jsonld' ? 'script[type="application/ld+json"]' : scriptSelector || 'body',
220
+ fields: [
221
+ {
222
+ name: 'content',
223
+ selector: sourceType === 'jsonld' ? '' : scriptSelector || 'pre',
224
+ type: 'text',
225
+ }
226
+ ],
227
+ },
228
+ },
229
+ },
230
+ };
231
+ const result = await crawler.arun(url, {
232
+ extractionStrategy: sourceType === 'direct' ? undefined : extractionStrategy,
233
+ browserConfig,
234
+ cacheMode: options.cacheMode || 'enabled',
235
+ jsCode: browserOptions.jsCode,
236
+ headers,
237
+ });
238
+ let jsonData = null;
239
+ if (result.success) {
240
+ if (sourceType === 'direct') {
241
+ try {
242
+ if (result.extracted_content) {
243
+ jsonData = JSON.parse(result.extracted_content);
244
+ }
245
+ else if (result.text) {
246
+ jsonData = JSON.parse(result.text);
247
+ }
248
+ }
249
+ catch (error) {
250
+ const jsonMatch = (_a = result.text) === null || _a === void 0 ? void 0 : _a.match(/\{[\s\S]*\}|\[[\s\S]*\]/);
251
+ if (jsonMatch) {
252
+ try {
253
+ jsonData = JSON.parse(jsonMatch[0]);
254
+ }
255
+ catch {
256
+ jsonData = { content: result.text };
257
+ }
258
+ }
259
+ }
260
+ }
261
+ else {
262
+ if (result.extracted_content) {
263
+ try {
264
+ const extractedData = JSON.parse(result.extracted_content);
265
+ if (Array.isArray(extractedData) && extractedData.length > 0) {
266
+ const content = extractedData[0].content;
267
+ jsonData = JSON.parse(content);
268
+ }
269
+ }
270
+ catch (error) {
271
+ jsonData = { error: 'Failed to parse JSON from script tag' };
272
+ }
273
+ }
274
+ }
275
+ if (jsonPath && jsonData) {
276
+ const pathParts = jsonPath.split('.');
277
+ let currentData = jsonData;
278
+ for (const part of pathParts) {
279
+ if (currentData && typeof currentData === 'object' && part in currentData) {
280
+ currentData = currentData[part];
281
+ }
282
+ else {
283
+ currentData = null;
284
+ break;
285
+ }
286
+ }
287
+ jsonData = currentData;
288
+ }
289
+ }
290
+ const output = {
291
+ url,
292
+ success: result.success,
293
+ };
294
+ if (!result.success && result.error_message) {
295
+ output.error = result.error_message;
296
+ }
297
+ else if (jsonData) {
298
+ output.data = jsonData;
299
+ if (options.includeFullContent === true) {
300
+ output.fullContent = result.text || result.extracted_content;
301
+ }
302
+ }
303
+ else {
304
+ output.error = 'No JSON data found or failed to parse JSON';
305
+ output.success = false;
306
+ }
307
+ allResults.push({
308
+ json: output,
309
+ pairedItem: { item: i },
310
+ });
311
+ }
312
+ catch (error) {
313
+ if (this.continueOnFail()) {
314
+ const node = this.getNode();
315
+ const errorItemIndex = (_b = error.itemIndex) !== null && _b !== void 0 ? _b : i;
316
+ allResults.push({
317
+ json: items[i].json,
318
+ error: new n8n_workflow_1.NodeOperationError(node, error.message, { itemIndex: errorItemIndex }),
319
+ pairedItem: { item: i },
320
+ });
321
+ continue;
322
+ }
323
+ throw error;
324
+ }
325
+ }
326
+ return allResults;
327
+ }
328
+ //# sourceMappingURL=jsonExtractor.operation.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"jsonExtractor.operation.js","sourceRoot":"","sources":["../../../../nodes/Crawl4aiContentExtractor/actions/jsonExtractor.operation.ts"],"names":[],"mappings":";;;AAiMA,0BAuLC;AAlXD,+CAAkD;AAIlD,4CAI0B;AAGb,QAAA,WAAW,GAAsB;IAC7C;QACC,WAAW,EAAE,KAAK;QAClB,IAAI,EAAE,KAAK;QACX,IAAI,EAAE,QAAQ;QACd,QAAQ,EAAE,IAAI;QACd,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,mCAAmC;QAChD,WAAW,EAAE,qCAAqC;QAClD,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,SAAS,EAAE,CAAC,eAAe,CAAC;aAC5B;SACD;KACD;IACD;QACC,WAAW,EAAE,WAAW;QACxB,IAAI,EAAE,UAAU;QAChB,IAAI,EAAE,QAAQ;QACd,OAAO,EAAE,EAAE;QACX,WA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AAU,CAAC;AACnB,CAAC"}
@@ -0,0 +1,4 @@
1
+ import type { IExecuteFunctions, INodeExecutionData, INodeProperties } from 'n8n-workflow';
2
+ import type { Crawl4aiNodeOptions } from '../helpers/interfaces';
3
+ export declare const description: INodeProperties[];
4
+ export declare function execute(this: IExecuteFunctions, items: INodeExecutionData[], nodeOptions: Crawl4aiNodeOptions): Promise<INodeExecutionData[]>;