n8n-nodes-scraperapi 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.
- package/LICENSE +21 -0
- package/README.md +185 -0
- package/dist/credentials/ScraperApiApi.credentials.d.ts +9 -0
- package/dist/credentials/ScraperApiApi.credentials.js +47 -0
- package/dist/credentials/ScraperApiApi.credentials.js.map +1 -0
- package/dist/nodes/ScraperApi/GenericFunctions.d.ts +23 -0
- package/dist/nodes/ScraperApi/GenericFunctions.js +111 -0
- package/dist/nodes/ScraperApi/GenericFunctions.js.map +1 -0
- package/dist/nodes/ScraperApi/ScraperApi.node.d.ts +5 -0
- package/dist/nodes/ScraperApi/ScraperApi.node.js +326 -0
- package/dist/nodes/ScraperApi/ScraperApi.node.js.map +1 -0
- package/dist/nodes/ScraperApi/descriptions/BatchDescription.d.ts +3 -0
- package/dist/nodes/ScraperApi/descriptions/BatchDescription.js +143 -0
- package/dist/nodes/ScraperApi/descriptions/BatchDescription.js.map +1 -0
- package/dist/nodes/ScraperApi/descriptions/CrawlDescription.d.ts +3 -0
- package/dist/nodes/ScraperApi/descriptions/CrawlDescription.js +103 -0
- package/dist/nodes/ScraperApi/descriptions/CrawlDescription.js.map +1 -0
- package/dist/nodes/ScraperApi/descriptions/ExtractDescription.d.ts +3 -0
- package/dist/nodes/ScraperApi/descriptions/ExtractDescription.js +157 -0
- package/dist/nodes/ScraperApi/descriptions/ExtractDescription.js.map +1 -0
- package/dist/nodes/ScraperApi/descriptions/MapDescription.d.ts +3 -0
- package/dist/nodes/ScraperApi/descriptions/MapDescription.js +63 -0
- package/dist/nodes/ScraperApi/descriptions/MapDescription.js.map +1 -0
- package/dist/nodes/ScraperApi/descriptions/SearchDescription.d.ts +3 -0
- package/dist/nodes/ScraperApi/descriptions/SearchDescription.js +148 -0
- package/dist/nodes/ScraperApi/descriptions/SearchDescription.js.map +1 -0
- package/dist/nodes/ScraperApi/descriptions/StatisticsDescription.d.ts +3 -0
- package/dist/nodes/ScraperApi/descriptions/StatisticsDescription.js +48 -0
- package/dist/nodes/ScraperApi/descriptions/StatisticsDescription.js.map +1 -0
- package/dist/nodes/ScraperApi/descriptions/WebhookDescription.d.ts +3 -0
- package/dist/nodes/ScraperApi/descriptions/WebhookDescription.js +93 -0
- package/dist/nodes/ScraperApi/descriptions/WebhookDescription.js.map +1 -0
- package/dist/nodes/ScraperApi/descriptions/shared.d.ts +15 -0
- package/dist/nodes/ScraperApi/descriptions/shared.js +91 -0
- package/dist/nodes/ScraperApi/descriptions/shared.js.map +1 -0
- package/dist/nodes/ScraperApi/scraper-geonode.svg +252 -0
- package/dist/nodes/ScraperApiTrigger/ScraperApiTrigger.node.d.ts +12 -0
- package/dist/nodes/ScraperApiTrigger/ScraperApiTrigger.node.js +169 -0
- package/dist/nodes/ScraperApiTrigger/ScraperApiTrigger.node.js.map +1 -0
- package/dist/nodes/ScraperApiTrigger/scraper-geonode.svg +252 -0
- package/dist/package.json +63 -0
- package/dist/tsconfig.tsbuildinfo +1 -0
- package/index.js +1 -0
- package/package.json +63 -0
|
@@ -0,0 +1,157 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.extractFields = exports.extractOperations = void 0;
|
|
4
|
+
const shared_1 = require("./shared");
|
|
5
|
+
const runShow = { resource: ['extract'], operation: ['run'] };
|
|
6
|
+
const listShow = { resource: ['extract'], operation: ['listJobs'] };
|
|
7
|
+
exports.extractOperations = [
|
|
8
|
+
{
|
|
9
|
+
displayName: 'Operation',
|
|
10
|
+
name: 'operation',
|
|
11
|
+
type: 'options',
|
|
12
|
+
noDataExpression: true,
|
|
13
|
+
displayOptions: { show: { resource: ['extract'] } },
|
|
14
|
+
options: [
|
|
15
|
+
{
|
|
16
|
+
name: 'Run Extraction',
|
|
17
|
+
value: 'run',
|
|
18
|
+
action: 'Extract content from a URL',
|
|
19
|
+
description: 'Extract clean markdown or HTML from any URL',
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
name: 'Get Job',
|
|
23
|
+
value: 'getJob',
|
|
24
|
+
action: 'Get an extraction job result',
|
|
25
|
+
description: 'Retrieve a single async extraction job',
|
|
26
|
+
},
|
|
27
|
+
{
|
|
28
|
+
name: 'List Jobs',
|
|
29
|
+
value: 'listJobs',
|
|
30
|
+
action: 'List extraction jobs',
|
|
31
|
+
description: 'List and filter extraction jobs',
|
|
32
|
+
},
|
|
33
|
+
],
|
|
34
|
+
default: 'run',
|
|
35
|
+
},
|
|
36
|
+
];
|
|
37
|
+
exports.extractFields = [
|
|
38
|
+
{
|
|
39
|
+
displayName: 'URL',
|
|
40
|
+
name: 'url',
|
|
41
|
+
type: 'string',
|
|
42
|
+
required: true,
|
|
43
|
+
default: '',
|
|
44
|
+
placeholder: 'https://example.com',
|
|
45
|
+
description: 'The URL to extract content from',
|
|
46
|
+
displayOptions: { show: runShow },
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
displayName: 'Output Formats',
|
|
50
|
+
name: 'formats',
|
|
51
|
+
type: 'multiOptions',
|
|
52
|
+
options: [
|
|
53
|
+
{ name: 'HTML', value: 'html' },
|
|
54
|
+
{ name: 'Markdown', value: 'markdown' },
|
|
55
|
+
],
|
|
56
|
+
default: ['html'],
|
|
57
|
+
description: 'Output formats to return',
|
|
58
|
+
displayOptions: { show: runShow },
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
displayName: 'Render JavaScript',
|
|
62
|
+
name: 'render_js',
|
|
63
|
+
type: 'boolean',
|
|
64
|
+
default: false,
|
|
65
|
+
description: 'Whether to use a headless browser to render the page (slower, more expensive)',
|
|
66
|
+
displayOptions: { show: runShow },
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
displayName: 'Processing Mode',
|
|
70
|
+
name: 'processing_mode',
|
|
71
|
+
type: 'options',
|
|
72
|
+
options: [
|
|
73
|
+
{ name: 'Sync (Block Until Done)', value: 'sync' },
|
|
74
|
+
{ name: 'Async (Queue and Return Job ID)', value: 'async' },
|
|
75
|
+
],
|
|
76
|
+
default: 'sync',
|
|
77
|
+
description: 'Processing mode: sync blocks until done; async returns a job ID',
|
|
78
|
+
displayOptions: { show: runShow },
|
|
79
|
+
},
|
|
80
|
+
...(0, shared_1.pollingFields)({ ...runShow, processing_mode: ['async'] }, { waitDefault: true, intervalMs: 2000, timeoutMs: 300000 }),
|
|
81
|
+
{
|
|
82
|
+
displayName: 'Extract Links',
|
|
83
|
+
name: 'extract_links',
|
|
84
|
+
type: 'boolean',
|
|
85
|
+
default: false,
|
|
86
|
+
description: 'Whether to extract all links found on the page',
|
|
87
|
+
displayOptions: { show: runShow },
|
|
88
|
+
},
|
|
89
|
+
(0, shared_1.proxyCollection)(runShow),
|
|
90
|
+
{
|
|
91
|
+
displayName: 'Custom Headers',
|
|
92
|
+
name: 'headers',
|
|
93
|
+
type: 'fixedCollection',
|
|
94
|
+
typeOptions: { multipleValues: true },
|
|
95
|
+
placeholder: 'Add Header',
|
|
96
|
+
default: {},
|
|
97
|
+
displayOptions: { show: runShow },
|
|
98
|
+
options: [
|
|
99
|
+
{
|
|
100
|
+
displayName: 'Header',
|
|
101
|
+
name: 'header',
|
|
102
|
+
values: [
|
|
103
|
+
{ displayName: 'Name', name: 'name', type: 'string', default: '' },
|
|
104
|
+
{ displayName: 'Value', name: 'value', type: 'string', default: '' },
|
|
105
|
+
],
|
|
106
|
+
},
|
|
107
|
+
],
|
|
108
|
+
},
|
|
109
|
+
{
|
|
110
|
+
displayName: 'Job ID',
|
|
111
|
+
name: 'jobId',
|
|
112
|
+
type: 'string',
|
|
113
|
+
required: true,
|
|
114
|
+
default: '',
|
|
115
|
+
description: 'The extraction job ID returned from an async run',
|
|
116
|
+
displayOptions: { show: { resource: ['extract'], operation: ['getJob'] } },
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
displayName: 'Filters',
|
|
120
|
+
name: 'filters',
|
|
121
|
+
type: 'collection',
|
|
122
|
+
placeholder: 'Add Filter',
|
|
123
|
+
default: {},
|
|
124
|
+
displayOptions: { show: listShow },
|
|
125
|
+
options: [
|
|
126
|
+
{ displayName: 'End Date', name: 'end_date', type: 'dateTime', default: '' },
|
|
127
|
+
{ displayName: 'Job ID', name: 'job_id', type: 'string', default: '' },
|
|
128
|
+
{
|
|
129
|
+
displayName: 'Output Format',
|
|
130
|
+
name: 'output',
|
|
131
|
+
type: 'options',
|
|
132
|
+
options: [
|
|
133
|
+
{ name: 'HTML', value: 'html' },
|
|
134
|
+
{ name: 'Markdown', value: 'markdown' },
|
|
135
|
+
],
|
|
136
|
+
default: 'html',
|
|
137
|
+
},
|
|
138
|
+
{ displayName: 'Start Date', name: 'start_date', type: 'dateTime', default: '' },
|
|
139
|
+
{
|
|
140
|
+
displayName: 'Status',
|
|
141
|
+
name: 'status',
|
|
142
|
+
type: 'options',
|
|
143
|
+
options: [
|
|
144
|
+
{ name: 'Cancelled', value: 'cancelled' },
|
|
145
|
+
{ name: 'Completed', value: 'completed' },
|
|
146
|
+
{ name: 'Failed', value: 'failed' },
|
|
147
|
+
{ name: 'Processing', value: 'processing' },
|
|
148
|
+
{ name: 'Queued', value: 'queued' },
|
|
149
|
+
],
|
|
150
|
+
default: 'queued',
|
|
151
|
+
},
|
|
152
|
+
{ displayName: 'URL', name: 'url', type: 'string', default: '' },
|
|
153
|
+
],
|
|
154
|
+
},
|
|
155
|
+
...(0, shared_1.paginationFields)(listShow),
|
|
156
|
+
];
|
|
157
|
+
//# sourceMappingURL=ExtractDescription.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ExtractDescription.js","sourceRoot":"","sources":["../../../../nodes/ScraperApi/descriptions/ExtractDescription.ts"],"names":[],"mappings":";;;AAEA,qCAA4E;AAE5E,MAAM,OAAO,GAAG,EAAE,QAAQ,EAAE,CAAC,SAAS,CAAC,EAAE,SAAS,EAAE,CAAC,KAAK,CAAC,EAAE,CAAC;AAC9D,MAAM,QAAQ,GA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AAE;iBACxC;gBACD,OAAO,EAAE,MAAM;aAChB;YACD,EAAE,WAAW,EAAE,YAAY,EAAE,IAAI,EAAE,YAAY,EAAE,IAAI,EAAE,UAAU,EAAE,OAAO,EAAE,EAAE,EAAE;YAChF;gBACE,WAAW,EAAE,QAAQ;gBACrB,IAAI,EAAE,QAAQ;gBACd,IAAI,EAAE,SAAS;gBACf,OAAO,EAAE;oBACP,EAAE,IAAI,EAAE,WAAW,EAAE,KAAK,EAAE,WAAW,EAAE;oBACzC,EAAE,IAAI,EAAE,WAAW,EAAE,KAAK,EAAE,WAAW,EAAE;oBACzC,EAAE,IAAI,EAAE,QAAQ,EAAE,KAAK,EAAE,QAAQ,EAAE;oBACnC,EAAE,IAAI,EAAE,YAAY,EAAE,KAAK,EAAE,YAAY,EAAE;oBAC3C,EAAE,IAAI,EAAE,QAAQ,EAAE,KAAK,EAAE,QAAQ,EAAE;iBACpC;gBACD,OAAO,EAAE,QAAQ;aAClB;YACD,EAAE,WAAW,EAAE,KAAK,EAAE,IAAI,EAAE,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,OAAO,EAAE,EAAE,EAAE;SACjE;KACF;IACD,GAAG,IAAA,yBAAgB,EAAC,QAAQ,CAAC;CAC9B,CAAC"}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.mapFields = exports.mapOperations = void 0;
|
|
4
|
+
exports.mapOperations = [
|
|
5
|
+
{
|
|
6
|
+
displayName: 'Operation',
|
|
7
|
+
name: 'operation',
|
|
8
|
+
type: 'options',
|
|
9
|
+
noDataExpression: true,
|
|
10
|
+
displayOptions: { show: { resource: ['map'] } },
|
|
11
|
+
options: [
|
|
12
|
+
{
|
|
13
|
+
name: 'Discover URLs',
|
|
14
|
+
value: 'discover',
|
|
15
|
+
action: 'Discover urls under a base url',
|
|
16
|
+
description: 'Combine sitemap parsing with optional search results to map a site',
|
|
17
|
+
},
|
|
18
|
+
],
|
|
19
|
+
default: 'discover',
|
|
20
|
+
},
|
|
21
|
+
];
|
|
22
|
+
exports.mapFields = [
|
|
23
|
+
{
|
|
24
|
+
displayName: 'URL',
|
|
25
|
+
name: 'url',
|
|
26
|
+
type: 'string',
|
|
27
|
+
required: true,
|
|
28
|
+
default: '',
|
|
29
|
+
placeholder: 'https://example.com',
|
|
30
|
+
description: 'Base URL to discover links from',
|
|
31
|
+
displayOptions: { show: { resource: ['map'], operation: ['discover'] } },
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
displayName: 'Options',
|
|
35
|
+
name: 'options',
|
|
36
|
+
type: 'collection',
|
|
37
|
+
placeholder: 'Add Option',
|
|
38
|
+
default: {},
|
|
39
|
+
displayOptions: { show: { resource: ['map'], operation: ['discover'] } },
|
|
40
|
+
options: [
|
|
41
|
+
{
|
|
42
|
+
displayName: 'Search Keyword',
|
|
43
|
+
name: 'search',
|
|
44
|
+
type: 'string',
|
|
45
|
+
default: '',
|
|
46
|
+
description: 'Optional keyword to filter discovered links',
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
displayName: 'Include Subdomains',
|
|
50
|
+
name: 'include_subdomains',
|
|
51
|
+
type: 'boolean',
|
|
52
|
+
default: true,
|
|
53
|
+
},
|
|
54
|
+
{
|
|
55
|
+
displayName: 'Ignore Query Parameters',
|
|
56
|
+
name: 'ignore_query_parameters',
|
|
57
|
+
type: 'boolean',
|
|
58
|
+
default: true,
|
|
59
|
+
},
|
|
60
|
+
],
|
|
61
|
+
},
|
|
62
|
+
];
|
|
63
|
+
//# sourceMappingURL=MapDescription.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MapDescription.js","sourceRoot":"","sources":["../../../../nodes/ScraperApi/descriptions/MapDescription.ts"],"names":[],"mappings":";;;AAEa,QAAA,aAAa,GAAsB;IAC9C;QACE,WAAW,EAAE,WAAW;QACxB,IAAI,EAAE,WAAW;QACjB,IAAI,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AS;gBACf,OAAO,EAAE,IAAI;aACd;SACF;KACF;CACF,CAAC"}
|
|
@@ -0,0 +1,148 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.searchFields = exports.searchOperations = void 0;
|
|
4
|
+
const shared_1 = require("./shared");
|
|
5
|
+
const runShow = { resource: ['search'], operation: ['run'] };
|
|
6
|
+
const listShow = { resource: ['search'], operation: ['listJobs'] };
|
|
7
|
+
exports.searchOperations = [
|
|
8
|
+
{
|
|
9
|
+
displayName: 'Operation',
|
|
10
|
+
name: 'operation',
|
|
11
|
+
type: 'options',
|
|
12
|
+
noDataExpression: true,
|
|
13
|
+
displayOptions: { show: { resource: ['search'] } },
|
|
14
|
+
options: [
|
|
15
|
+
{
|
|
16
|
+
name: 'Run Search',
|
|
17
|
+
value: 'run',
|
|
18
|
+
action: 'Run a search query',
|
|
19
|
+
description: 'Search the web and return ranked results',
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
name: 'Get Job',
|
|
23
|
+
value: 'getJob',
|
|
24
|
+
action: 'Get a search job',
|
|
25
|
+
description: 'Retrieve a single search job by ID',
|
|
26
|
+
},
|
|
27
|
+
{
|
|
28
|
+
name: 'List Jobs',
|
|
29
|
+
value: 'listJobs',
|
|
30
|
+
action: 'List search jobs',
|
|
31
|
+
description: 'List and filter past search jobs',
|
|
32
|
+
},
|
|
33
|
+
],
|
|
34
|
+
default: 'run',
|
|
35
|
+
},
|
|
36
|
+
];
|
|
37
|
+
exports.searchFields = [
|
|
38
|
+
{
|
|
39
|
+
displayName: 'Query',
|
|
40
|
+
name: 'query',
|
|
41
|
+
type: 'string',
|
|
42
|
+
required: true,
|
|
43
|
+
default: '',
|
|
44
|
+
placeholder: 'best running shoes',
|
|
45
|
+
description: 'The search query to run',
|
|
46
|
+
displayOptions: { show: runShow },
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
displayName: 'Options',
|
|
50
|
+
name: 'options',
|
|
51
|
+
type: 'collection',
|
|
52
|
+
placeholder: 'Add Option',
|
|
53
|
+
default: {},
|
|
54
|
+
displayOptions: { show: runShow },
|
|
55
|
+
options: [
|
|
56
|
+
{
|
|
57
|
+
displayName: 'Engine',
|
|
58
|
+
name: 'engine',
|
|
59
|
+
type: 'options',
|
|
60
|
+
options: [
|
|
61
|
+
{ name: 'Brave', value: 'brave' },
|
|
62
|
+
{ name: 'DuckDuckGo', value: 'duckduckgo' },
|
|
63
|
+
{ name: 'Naver', value: 'naver' },
|
|
64
|
+
],
|
|
65
|
+
default: 'brave',
|
|
66
|
+
description: 'Search engine to query. Leave this option out to let the API choose.',
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
displayName: 'Locale',
|
|
70
|
+
name: 'locale',
|
|
71
|
+
type: 'string',
|
|
72
|
+
default: '',
|
|
73
|
+
placeholder: 'en-US',
|
|
74
|
+
description: 'Language and region to search in, such as en-US or ko-KR',
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
displayName: 'Page',
|
|
78
|
+
name: 'page',
|
|
79
|
+
type: 'number',
|
|
80
|
+
default: 1,
|
|
81
|
+
typeOptions: { minValue: 1 },
|
|
82
|
+
description: 'Result page to return',
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
displayName: 'Safe Search',
|
|
86
|
+
name: 'safe',
|
|
87
|
+
type: 'options',
|
|
88
|
+
options: [
|
|
89
|
+
{ name: 'Moderate', value: 'moderate' },
|
|
90
|
+
{ name: 'Off', value: 'off' },
|
|
91
|
+
{ name: 'Strict', value: 'strict' },
|
|
92
|
+
],
|
|
93
|
+
default: 'off',
|
|
94
|
+
description: 'How strictly to filter adult content',
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
displayName: 'Time Range',
|
|
98
|
+
name: 'time_range',
|
|
99
|
+
type: 'options',
|
|
100
|
+
options: [
|
|
101
|
+
{ name: 'Day', value: 'day' },
|
|
102
|
+
{ name: 'Month', value: 'month' },
|
|
103
|
+
{ name: 'Week', value: 'week' },
|
|
104
|
+
{ name: 'Year', value: 'year' },
|
|
105
|
+
],
|
|
106
|
+
default: 'week',
|
|
107
|
+
description: 'Restrict results to content published within this period',
|
|
108
|
+
},
|
|
109
|
+
],
|
|
110
|
+
},
|
|
111
|
+
{
|
|
112
|
+
displayName: 'Job ID',
|
|
113
|
+
name: 'jobId',
|
|
114
|
+
type: 'string',
|
|
115
|
+
required: true,
|
|
116
|
+
default: '',
|
|
117
|
+
description: 'The search job ID returned by a previous run',
|
|
118
|
+
displayOptions: { show: { resource: ['search'], operation: ['getJob'] } },
|
|
119
|
+
},
|
|
120
|
+
{
|
|
121
|
+
displayName: 'Filters',
|
|
122
|
+
name: 'filters',
|
|
123
|
+
type: 'collection',
|
|
124
|
+
placeholder: 'Add Filter',
|
|
125
|
+
default: {},
|
|
126
|
+
displayOptions: { show: listShow },
|
|
127
|
+
options: [
|
|
128
|
+
{ displayName: 'End Date', name: 'end_date', type: 'dateTime', default: '' },
|
|
129
|
+
{ displayName: 'Query', name: 'query', type: 'string', default: '' },
|
|
130
|
+
{ displayName: 'Start Date', name: 'start_date', type: 'dateTime', default: '' },
|
|
131
|
+
{
|
|
132
|
+
displayName: 'Status',
|
|
133
|
+
name: 'status',
|
|
134
|
+
type: 'options',
|
|
135
|
+
options: [
|
|
136
|
+
{ name: 'Cancelled', value: 'cancelled' },
|
|
137
|
+
{ name: 'Completed', value: 'completed' },
|
|
138
|
+
{ name: 'Failed', value: 'failed' },
|
|
139
|
+
{ name: 'Processing', value: 'processing' },
|
|
140
|
+
{ name: 'Queued', value: 'queued' },
|
|
141
|
+
],
|
|
142
|
+
default: 'queued',
|
|
143
|
+
},
|
|
144
|
+
],
|
|
145
|
+
},
|
|
146
|
+
...(0, shared_1.paginationFields)(listShow),
|
|
147
|
+
];
|
|
148
|
+
//# sourceMappingURL=SearchDescription.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SearchDescription.js","sour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AQ;gBACd,IAAI,EAAE,SAAS;gBACf,OAAO,EAAE;oBACP,EAAE,IAAI,EAAE,WAAW,EAAE,KAAK,EAAE,WAAW,EAAE;oBACzC,EAAE,IAAI,EAAE,WAAW,EAAE,KAAK,EAAE,WAAW,EAAE;oBACzC,EAAE,IAAI,EAAE,QAAQ,EAAE,KAAK,EAAE,QAAQ,EAAE;oBACnC,EAAE,IAAI,EAAE,YAAY,EAAE,KAAK,EAAE,YAAY,EAAE;oBAC3C,EAAE,IAAI,EAAE,QAAQ,EAAE,KAAK,EAAE,QAAQ,EAAE;iBACpC;gBACD,OAAO,EAAE,QAAQ;aAClB;SACF;KACF;IACD,GAAG,IAAA,yBAAgB,EAAC,QAAQ,CAAC;CAC9B,CAAC"}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.statisticsFields = exports.statisticsOperations = void 0;
|
|
4
|
+
exports.statisticsOperations = [
|
|
5
|
+
{
|
|
6
|
+
displayName: 'Operation',
|
|
7
|
+
name: 'operation',
|
|
8
|
+
type: 'options',
|
|
9
|
+
noDataExpression: true,
|
|
10
|
+
displayOptions: { show: { resource: ['statistics'] } },
|
|
11
|
+
options: [
|
|
12
|
+
{
|
|
13
|
+
name: 'Get',
|
|
14
|
+
value: 'get',
|
|
15
|
+
action: 'Get extraction statistics',
|
|
16
|
+
description: 'Retrieve aggregated extraction statistics for a date range',
|
|
17
|
+
},
|
|
18
|
+
],
|
|
19
|
+
default: 'get',
|
|
20
|
+
},
|
|
21
|
+
];
|
|
22
|
+
exports.statisticsFields = [
|
|
23
|
+
{
|
|
24
|
+
displayName: 'Filters',
|
|
25
|
+
name: 'filters',
|
|
26
|
+
type: 'collection',
|
|
27
|
+
placeholder: 'Add Filter',
|
|
28
|
+
default: {},
|
|
29
|
+
displayOptions: { show: { resource: ['statistics'], operation: ['get'] } },
|
|
30
|
+
options: [
|
|
31
|
+
{
|
|
32
|
+
displayName: 'Start Date',
|
|
33
|
+
name: 'start_date',
|
|
34
|
+
type: 'dateTime',
|
|
35
|
+
default: '',
|
|
36
|
+
description: 'Defaults to 30 days ago',
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
displayName: 'End Date',
|
|
40
|
+
name: 'end_date',
|
|
41
|
+
type: 'dateTime',
|
|
42
|
+
default: '',
|
|
43
|
+
description: 'Defaults to now',
|
|
44
|
+
},
|
|
45
|
+
],
|
|
46
|
+
},
|
|
47
|
+
];
|
|
48
|
+
//# sourceMappingURL=StatisticsDescription.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"StatisticsDescription.js","sourceRoot":"","sources":["../../../../nodes/ScraperApi/descriptions/StatisticsDescription.ts"],"names":[],"mappings":";;;AAEa,QAAA,oBAAoB,GAAsB;IACrD;QACE,WAAW,EAAE,WAAW;QACxB,IAAI,EAAE,WAAW;QACjB,IAAI,EAAE,SAAS;QACf,gBAAgB,EAAE,IAAI;QACtB,cAAc,EAAE,EAAE,IAAI,EAAE,EAAE,QAAQ,EAAE,CAAC,YAAY,CAAC,EAAE,EAAE;QACtD,OAAO,EAAE;YACP;gBACE,IAAI,EAAE,KAAK;gBACX,KAAK,EAAE,KAAK;gBACZ,MAAM,EAAE,2BAA2B;gBACnC,WAAW,EAAE,4DAA4D;aAC1E;SACF;QACD,OAAO,EAAE,KAAK;KACf;CACF,CAAC;AAEW,QAAA,gBAAgB,GAAsB;IACjD;QACE,WAAW,EAAE,SAAS;QACtB,IAAI,EAAE,SAAS;QACf,IAAI,EAAE,YAAY;QAClB,WAAW,EAAE,YAAY;QACzB,OAAO,EAAE,EAAE;QACX,cAAc,EAAE,EAAE,IAAI,EAAE,EAAE,QAAQ,EAAE,CAAC,YAAY,CAAC,EAAE,SAAS,EAAE,CAAC,KAAK,CAAC,EAAE,EAAE;QAC1E,OAAO,EAAE;YACP;gBACE,WAAW,EAAE,YAAY;gBACzB,IAAI,EAAE,YAAY;gBAClB,IAAI,EAAE,UAAU;gBAChB,OAAO,EAAE,EAAE;gBACX,WAAW,EAAE,yBAAyB;aACvC;YACD;gBACE,WAAW,EAAE,UAAU;gBACvB,IAAI,EAAE,UAAU;gBAChB,IAAI,EAAE,UAAU;gBAChB,OAAO,EAAE,EAAE;gBACX,WAAW,EAAE,iBAAiB;aAC/B;SACF;KACF;CACF,CAAC"}
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.webhookFields = exports.webhookOperations = void 0;
|
|
4
|
+
const shared_1 = require("./shared");
|
|
5
|
+
const createShow = { resource: ['webhook'], operation: ['create'] };
|
|
6
|
+
const idShow = {
|
|
7
|
+
resource: ['webhook'],
|
|
8
|
+
operation: ['get', 'update', 'delete', 'rotateSecret', 'listDeliveries'],
|
|
9
|
+
};
|
|
10
|
+
const listShow = { resource: ['webhook'], operation: ['list', 'listDeliveries'] };
|
|
11
|
+
exports.webhookOperations = [
|
|
12
|
+
{
|
|
13
|
+
displayName: 'Operation',
|
|
14
|
+
name: 'operation',
|
|
15
|
+
type: 'options',
|
|
16
|
+
noDataExpression: true,
|
|
17
|
+
displayOptions: { show: { resource: ['webhook'] } },
|
|
18
|
+
options: [
|
|
19
|
+
{ name: 'Create', value: 'create', action: 'Register a webhook' },
|
|
20
|
+
{ name: 'Delete', value: 'delete', action: 'Delete a webhook' },
|
|
21
|
+
{ name: 'Get', value: 'get', action: 'Get a webhook' },
|
|
22
|
+
{ name: 'List', value: 'list', action: 'List webhooks' },
|
|
23
|
+
{ name: 'List Deliveries', value: 'listDeliveries', action: 'List webhook deliveries' },
|
|
24
|
+
{ name: 'Rotate Secret', value: 'rotateSecret', action: 'Rotate webhook signing secret' },
|
|
25
|
+
{ name: 'Update', value: 'update', action: 'Update a webhook' },
|
|
26
|
+
],
|
|
27
|
+
default: 'list',
|
|
28
|
+
},
|
|
29
|
+
];
|
|
30
|
+
exports.webhookFields = [
|
|
31
|
+
{
|
|
32
|
+
displayName: 'Target URL',
|
|
33
|
+
name: 'url',
|
|
34
|
+
type: 'string',
|
|
35
|
+
required: true,
|
|
36
|
+
default: '',
|
|
37
|
+
placeholder: 'https://my-app.example.com/hooks/scraper',
|
|
38
|
+
displayOptions: { show: createShow },
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
displayName: 'Event Type',
|
|
42
|
+
name: 'event_type',
|
|
43
|
+
type: 'options',
|
|
44
|
+
options: shared_1.eventTypeOptions,
|
|
45
|
+
default: 'extract_completed',
|
|
46
|
+
displayOptions: { show: createShow },
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
displayName: 'Description',
|
|
50
|
+
name: 'description',
|
|
51
|
+
type: 'string',
|
|
52
|
+
default: '',
|
|
53
|
+
displayOptions: { show: createShow },
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
displayName: 'Webhook ID',
|
|
57
|
+
name: 'webhookId',
|
|
58
|
+
type: 'string',
|
|
59
|
+
required: true,
|
|
60
|
+
default: '',
|
|
61
|
+
displayOptions: { show: idShow },
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
displayName: 'Update Fields',
|
|
65
|
+
name: 'updateFields',
|
|
66
|
+
type: 'collection',
|
|
67
|
+
placeholder: 'Add Field',
|
|
68
|
+
default: {},
|
|
69
|
+
displayOptions: { show: { resource: ['webhook'], operation: ['update'] } },
|
|
70
|
+
options: [
|
|
71
|
+
{ displayName: 'Target URL', name: 'url', type: 'string', default: '' },
|
|
72
|
+
{ displayName: 'Description', name: 'description', type: 'string', default: '' },
|
|
73
|
+
{ displayName: 'Active', name: 'is_active', type: 'boolean', default: true },
|
|
74
|
+
{
|
|
75
|
+
displayName: 'Event Type',
|
|
76
|
+
name: 'event_type',
|
|
77
|
+
type: 'options',
|
|
78
|
+
options: shared_1.eventTypeOptions,
|
|
79
|
+
default: 'extract_completed',
|
|
80
|
+
},
|
|
81
|
+
],
|
|
82
|
+
},
|
|
83
|
+
...(0, shared_1.paginationFields)(listShow),
|
|
84
|
+
{
|
|
85
|
+
displayName: 'Delivery Status',
|
|
86
|
+
name: 'deliveryStatus',
|
|
87
|
+
type: 'string',
|
|
88
|
+
default: '',
|
|
89
|
+
description: 'Optional status filter for deliveries (e.g. delivered, failed)',
|
|
90
|
+
displayOptions: { show: { resource: ['webhook'], operation: ['listDeliveries'] } },
|
|
91
|
+
},
|
|
92
|
+
];
|
|
93
|
+
//# sourceMappingURL=WebhookDescription.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"WebhookDescription.js","sourceRoot":"","sources":["../../../../nodes/ScraperApi/descriptions/WebhookDescription.ts"],"names":[],"mappings":";;;AAEA,qCAA8D;AAE9D,MAAM,UAAU,GAAG,EAAE,QAAQ,EAAE,CAAC,SAAS,CAAC,EAAE,SAAS,EAAE,CAAC,QAAQ,CAAC,EAAE,CAAC;AACpE,MAAM,MAAM,GAAG;IACb,QAAQ,EAAE,CAAC,SAAS,CAAC;IACrB,SAAS,EAAE,CAAC,KAAK,EAAE,QAAQ,EAAE,QAAQ,EAAE,cAAc,EAAE,gBAAgB,CAAC;CACzE,CAAC;AACF,MAAM,QAAQ,GAAG,EAAE,QAAQ,EAAE,CAAC,SAAS,CAAC,EAAE,SAAS,EAAE,CAAC,MAAM,EAAE,gBAAgB,CAAC,EAAE,CAAC;AAErE,QAAA,iBAAiB,GAAsB;IAClD;QACE,WAAW,EAAE,WAAW;QACxB,IAAI,EAAE,WAAW;QACjB,IAAI,EAAE,SAAS;QACf,gBAAgB,EAAE,IAAI;QACtB,cAAc,EAAE,EAAE,IAAI,EAAE,EAAE,QAAQ,EAAE,CAAC,SAAS,CAAC,EAAE,EAAE;QACnD,OAAO,EAAE;YACP,EAAE,IAAI,EAAE,QAAQ,EAAE,KAAK,EAAE,QAAQ,EAAE,MAAM,EAAE,oBAAoB,EAAE;YACjE,EAAE,IAAI,EAAE,QAAQ,EAAE,K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
4
|
+
value: string;
|
|
5
|
+
}[];
|
|
6
|
+
type Show = NonNullable<INodeProperties['displayOptions']>['show'];
|
|
7
|
+
export declare function proxyCollection(show: Show): INodeProperties;
|
|
8
|
+
export declare function paginationFields(show: Show): INodeProperties[];
|
|
9
|
+
export interface PollingDefaults {
|
|
10
|
+
waitDefault: boolean;
|
|
11
|
+
intervalMs: number;
|
|
12
|
+
timeoutMs: number;
|
|
13
|
+
}
|
|
14
|
+
export declare function pollingFields(show: Show, defaults: PollingDefaults): INodeProperties[];
|
|
15
|
+
export {};
|