n8n-nodes-multiple-upload-request 0.2.1 → 0.4.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 (76) hide show
  1. package/dist/credentials/CustomHeaderAuthApi.credentials.d.ts +2 -1
  2. package/dist/credentials/CustomHeaderAuthApi.credentials.js +8 -0
  3. package/dist/credentials/CustomHeaderAuthApi.credentials.js.map +1 -1
  4. package/dist/nodes/MultipleUploadRequest/MultipleUploadRequest.node.js +255 -158
  5. package/dist/nodes/MultipleUploadRequest/MultipleUploadRequest.node.js.map +1 -1
  6. package/dist/nodes/MultipleUploadRequest/description.js +92 -3
  7. package/dist/nodes/MultipleUploadRequest/description.js.map +1 -1
  8. package/dist/nodes/MultipleUploadRequest/utils.js +2 -1
  9. package/dist/nodes/MultipleUploadRequest/utils.js.map +1 -1
  10. package/dist/nodes/{Example/Example.node.d.ts → ParallelExecuteWorkflow/ParallelExecuteWorkflow.node.d.ts} +1 -1
  11. package/dist/nodes/ParallelExecuteWorkflow/ParallelExecuteWorkflow.node.js +185 -0
  12. package/dist/nodes/ParallelExecuteWorkflow/ParallelExecuteWorkflow.node.js.map +1 -0
  13. package/dist/nodes/ParallelExecuteWorkflow/ParallelExecuteWorkflow.node.json +18 -0
  14. package/dist/nodes/ParallelExecuteWorkflow/concurrency.d.ts +3 -0
  15. package/dist/nodes/ParallelExecuteWorkflow/concurrency.js +38 -0
  16. package/dist/nodes/ParallelExecuteWorkflow/concurrency.js.map +1 -0
  17. package/dist/nodes/ParallelExecuteWorkflow/description.d.ts +2 -0
  18. package/dist/nodes/ParallelExecuteWorkflow/description.js +99 -0
  19. package/dist/nodes/ParallelExecuteWorkflow/description.js.map +1 -0
  20. package/dist/nodes/ParallelExecuteWorkflow/parallel.svg +11 -0
  21. package/dist/package.json +7 -7
  22. package/dist/tsconfig.tsbuildinfo +1 -1
  23. package/package.json +7 -7
  24. package/dist/credentials/GithubIssuesApi.credentials.d.ts +0 -10
  25. package/dist/credentials/GithubIssuesApi.credentials.js +0 -37
  26. package/dist/credentials/GithubIssuesApi.credentials.js.map +0 -1
  27. package/dist/credentials/GithubIssuesOAuth2Api.credentials.d.ts +0 -9
  28. package/dist/credentials/GithubIssuesOAuth2Api.credentials.js +0 -54
  29. package/dist/credentials/GithubIssuesOAuth2Api.credentials.js.map +0 -1
  30. package/dist/icons/github.dark.svg +0 -3
  31. package/dist/icons/github.svg +0 -3
  32. package/dist/nodes/Example/Example.node.js +0 -61
  33. package/dist/nodes/Example/Example.node.js.map +0 -1
  34. package/dist/nodes/Example/Example.node.json +0 -18
  35. package/dist/nodes/Example/example.dark.svg +0 -13
  36. package/dist/nodes/Example/example.svg +0 -13
  37. package/dist/nodes/GithubIssues/GithubIssues.node.d.ts +0 -14
  38. package/dist/nodes/GithubIssues/GithubIssues.node.js +0 -101
  39. package/dist/nodes/GithubIssues/GithubIssues.node.js.map +0 -1
  40. package/dist/nodes/GithubIssues/GithubIssues.node.json +0 -18
  41. package/dist/nodes/GithubIssues/listSearch/getIssues.d.ts +0 -2
  42. package/dist/nodes/GithubIssues/listSearch/getIssues.js +0 -28
  43. package/dist/nodes/GithubIssues/listSearch/getIssues.js.map +0 -1
  44. package/dist/nodes/GithubIssues/listSearch/getRepositories.d.ts +0 -2
  45. package/dist/nodes/GithubIssues/listSearch/getRepositories.js +0 -31
  46. package/dist/nodes/GithubIssues/listSearch/getRepositories.js.map +0 -1
  47. package/dist/nodes/GithubIssues/listSearch/getUsers.d.ts +0 -2
  48. package/dist/nodes/GithubIssues/listSearch/getUsers.js +0 -29
  49. package/dist/nodes/GithubIssues/listSearch/getUsers.js.map +0 -1
  50. package/dist/nodes/GithubIssues/resources/issue/create.d.ts +0 -2
  51. package/dist/nodes/GithubIssues/resources/issue/create.js +0 -75
  52. package/dist/nodes/GithubIssues/resources/issue/create.js.map +0 -1
  53. package/dist/nodes/GithubIssues/resources/issue/get.d.ts +0 -2
  54. package/dist/nodes/GithubIssues/resources/issue/get.js +0 -15
  55. package/dist/nodes/GithubIssues/resources/issue/get.js.map +0 -1
  56. package/dist/nodes/GithubIssues/resources/issue/getAll.d.ts +0 -2
  57. package/dist/nodes/GithubIssues/resources/issue/getAll.js +0 -125
  58. package/dist/nodes/GithubIssues/resources/issue/getAll.js.map +0 -1
  59. package/dist/nodes/GithubIssues/resources/issue/index.d.ts +0 -2
  60. package/dist/nodes/GithubIssues/resources/issue/index.js +0 -76
  61. package/dist/nodes/GithubIssues/resources/issue/index.js.map +0 -1
  62. package/dist/nodes/GithubIssues/resources/issueComment/getAll.d.ts +0 -2
  63. package/dist/nodes/GithubIssues/resources/issueComment/getAll.js +0 -66
  64. package/dist/nodes/GithubIssues/resources/issueComment/getAll.js.map +0 -1
  65. package/dist/nodes/GithubIssues/resources/issueComment/index.d.ts +0 -2
  66. package/dist/nodes/GithubIssues/resources/issueComment/index.js +0 -48
  67. package/dist/nodes/GithubIssues/resources/issueComment/index.js.map +0 -1
  68. package/dist/nodes/GithubIssues/shared/descriptions.d.ts +0 -4
  69. package/dist/nodes/GithubIssues/shared/descriptions.js +0 -151
  70. package/dist/nodes/GithubIssues/shared/descriptions.js.map +0 -1
  71. package/dist/nodes/GithubIssues/shared/transport.d.ts +0 -2
  72. package/dist/nodes/GithubIssues/shared/transport.js +0 -16
  73. package/dist/nodes/GithubIssues/shared/transport.js.map +0 -1
  74. package/dist/nodes/GithubIssues/shared/utils.d.ts +0 -3
  75. package/dist/nodes/GithubIssues/shared/utils.js +0 -17
  76. package/dist/nodes/GithubIssues/shared/utils.js.map +0 -1
@@ -1,8 +1,9 @@
1
- import type { ICredentialType, INodeProperties, Icon } from 'n8n-workflow';
1
+ import type { IAuthenticateGeneric, ICredentialType, INodeProperties, Icon } from 'n8n-workflow';
2
2
  export declare class CustomHeaderAuthApi implements ICredentialType {
3
3
  name: string;
4
4
  displayName: string;
5
5
  documentationUrl: string;
6
6
  icon: Icon;
7
7
  properties: INodeProperties[];
8
+ authenticate: IAuthenticateGeneric;
8
9
  }
@@ -26,6 +26,14 @@ class CustomHeaderAuthApi {
26
26
  description: 'The value of the custom header',
27
27
  },
28
28
  ];
29
+ this.authenticate = {
30
+ type: 'generic',
31
+ properties: {
32
+ headers: {
33
+ '={{$credentials.headerName}}': '={{$credentials.headerValue}}',
34
+ },
35
+ },
36
+ };
29
37
  }
30
38
  }
31
39
  exports.CustomHeaderAuthApi = CustomHeaderAuthApi;
@@ -1 +1 @@
1
- {"version":3,"file":"CustomHeaderAuthApi.credentials.js","sourceRoot":"","sources":["../../credentials/CustomHeaderAuthApi.credentials.ts"],"names":[],"mappings":";;;AAMA,MAAa,mBAAmB;IAAhC;QACC,SAAI,GAAG,qBAAqB,CAAC;QAC7B,gBAAW,GAAG,wBAAwB,CAAC;QACvC,qBAAgB,GAAG,sEAAsE,CAAC;QAC1F,SAAI,GAAS,gDAAgD,CAAC;QAC9D,eAAU,GAAsB;YAC/B;gBACC,WAAW,EAAE,aAAa;gBAC1B,IAAI,EAAE,YAAY;gBAClB,IAAI,EAAE,QAAQ;gBACd,OAAO,EAAE,WAAW;gBACpB,QAAQ,EAAE,IAAI;gBACd,WAAW,EAAE,iDAAiD;aAC9D;YACD;gBACC,WAAW,EAAE,cAAc;gBAC3B,IAAI,EAAE,aAAa;gBACnB,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE;gBAC/B,OAAO,EAAE,EAAE;gBACX,QAAQ,EAAE,IAAI;gBACd,WAAW,EAAE,gCAAgC;aAC7C;SACD,CAAC;IACH,CAAC;CAAA;AAxBD,kDAwBC"}
1
+ {"version":3,"file":"CustomHeaderAuthApi.credentials.js","sourceRoot":"","sources":["../../credentials/CustomHeaderAuthApi.credentials.ts"],"names":[],"mappings":";;;AAOA,MAAa,mBAAmB;IAAhC;QACC,SAAI,GAAG,qBAAqB,CAAC;QAC7B,gBAAW,GAAG,wBAAwB,CAAC;QACvC,qBAAgB,GAAG,sEAAsE,CAAC;QAC1F,SAAI,GAAS,gDAAgD,CAAC;QAC9D,eAAU,GAAsB;YAC/B;gBACC,WAAW,EAAE,aAAa;gBAC1B,IAAI,EAAE,YAAY;gBAClB,IAAI,EAAE,QAAQ;gBACd,OAAO,EAAE,WAAW;gBACpB,QAAQ,EAAE,IAAI;gBACd,WAAW,EAAE,iDAAiD;aAC9D;YACD;gBACC,WAAW,EAAE,cAAc;gBAC3B,IAAI,EAAE,aAAa;gBACnB,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE;gBAC/B,OAAO,EAAE,EAAE;gBACX,QAAQ,EAAE,IAAI;gBACd,WAAW,EAAE,gCAAgC;aAC7C;SACD,CAAC;QAEF,iBAAY,GAAyB;YACpC,IAAI,EAAE,SAAS;YACf,UAAU,EAAE;gBACX,OAAO,EAAE;oBACR,8BAA8B,EAAE,+BAA+B;iBAC/D;aACD;SACD,CAAC;IACH,CAAC;CAAA;AAjCD,kDAiCC"}
@@ -1,9 +1,14 @@
1
1
  "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
2
5
  Object.defineProperty(exports, "__esModule", { value: true });
3
6
  exports.MultipleUploadRequest = void 0;
4
7
  const n8n_workflow_1 = require("n8n-workflow");
8
+ const form_data_1 = __importDefault(require("form-data"));
5
9
  const description_1 = require("./description");
6
10
  const utils_1 = require("./utils");
11
+ const concurrency_1 = require("../ParallelExecuteWorkflow/concurrency");
7
12
  class MultipleUploadRequest {
8
13
  constructor() {
9
14
  this.description = {
@@ -11,8 +16,8 @@ class MultipleUploadRequest {
11
16
  name: 'multipleUploadRequest',
12
17
  icon: 'file:upload.svg',
13
18
  group: ['transform'],
14
- version: 1,
15
- description: 'Upload multiple binary files with pattern filtering',
19
+ version: [1, 2],
20
+ description: 'Upload multiple binary files with pattern filtering and parallel execution',
16
21
  defaults: {
17
22
  name: 'Multiple Upload Request',
18
23
  },
@@ -44,171 +49,263 @@ class MultipleUploadRequest {
44
49
  }
45
50
  async execute() {
46
51
  const items = this.getInputData();
47
- const returnData = [];
48
- for (let itemIndex = 0; itemIndex < items.length; itemIndex++) {
49
- try {
50
- const requestMethod = this.getNodeParameter('requestMethod', itemIndex);
51
- const url = this.getNodeParameter('url', itemIndex);
52
- const sendMethod = this.getNodeParameter('sendMethod', itemIndex, 'multipart');
53
- const fileFieldName = this.getNodeParameter('fileFieldName', itemIndex, 'files');
54
- const filePattern = this.getNodeParameter('filePattern', itemIndex, '*');
55
- const binaryPropertyName = this.getNodeParameter('binaryPropertyName', itemIndex, 'data');
56
- const options = this.getNodeParameter('options', itemIndex, {});
57
- if (!url) {
58
- throw new n8n_workflow_1.NodeOperationError(this.getNode(), 'URL is required', { itemIndex });
59
- }
60
- const item = items[itemIndex];
61
- if (!item.binary) {
62
- throw new n8n_workflow_1.NodeOperationError(this.getNode(), 'No binary data found in input. Please connect a node that provides binary data.', { itemIndex });
63
- }
64
- const propertyNames = binaryPropertyName.split(',').map((name) => name.trim());
65
- let allBinaryFiles = {};
66
- for (const propName of propertyNames) {
67
- if (item.binary[propName]) {
68
- allBinaryFiles[propName] = item.binary[propName];
69
- }
70
- }
71
- if (Object.keys(allBinaryFiles).length === 0) {
72
- allBinaryFiles = item.binary;
73
- }
74
- const filteredFiles = (0, utils_1.filterBinaryFiles)(allBinaryFiles, filePattern);
75
- if (Object.keys(filteredFiles).length === 0) {
76
- throw new n8n_workflow_1.NodeOperationError(this.getNode(), `No binary files match the pattern: ${filePattern}`, { itemIndex });
77
- }
78
- let requestOptions;
79
- if (sendMethod === 'base64') {
80
- const base64Files = [];
81
- for (const [key, binaryData] of Object.entries(filteredFiles)) {
82
- const buffer = await this.helpers.getBinaryDataBuffer(itemIndex, key);
83
- base64Files.push({
84
- filename: binaryData.fileName || key,
85
- mimeType: binaryData.mimeType || 'application/octet-stream',
86
- data: buffer.toString('base64'),
87
- });
88
- }
89
- const jsonBody = {
90
- [fileFieldName]: base64Files,
91
- };
92
- if (options.formFields) {
93
- const formFields = options.formFields.field;
94
- if (formFields && Array.isArray(formFields)) {
95
- for (const field of formFields) {
96
- if (field.name) {
97
- jsonBody[field.name] = field.value;
98
- }
99
- }
100
- }
101
- }
102
- requestOptions = {
103
- method: requestMethod,
104
- url,
105
- body: jsonBody,
106
- headers: {
107
- 'Content-Type': 'application/json',
108
- },
109
- };
110
- }
111
- else {
112
- const formData = {};
113
- for (const [key, binaryData] of Object.entries(filteredFiles)) {
114
- const buffer = await this.helpers.getBinaryDataBuffer(itemIndex, key);
115
- formData[key] = {
116
- value: buffer,
117
- options: {
118
- filename: binaryData.fileName || key,
119
- contentType: binaryData.mimeType || 'application/octet-stream',
120
- },
121
- };
122
- }
123
- if (options.formFields) {
124
- const formFields = options.formFields.field;
125
- if (formFields && Array.isArray(formFields)) {
126
- for (const field of formFields) {
127
- if (field.name) {
128
- formData[field.name] = field.value;
129
- }
130
- }
131
- }
132
- }
133
- requestOptions = {
134
- method: requestMethod,
135
- url,
136
- headers: {},
137
- };
138
- Object.assign(requestOptions, { formData });
139
- }
140
- if (options.queryParameters) {
141
- const queryParams = options.queryParameters.parameter;
142
- if (queryParams && Array.isArray(queryParams)) {
143
- const qs = {};
144
- for (const param of queryParams) {
145
- if (param.name) {
146
- qs[param.name] = param.value;
147
- }
148
- }
149
- requestOptions.qs = qs;
150
- }
151
- }
152
- if (options.headers) {
153
- const headers = options.headers.header;
154
- if (headers && Array.isArray(headers)) {
155
- for (const header of headers) {
156
- if (header.name) {
157
- requestOptions.headers[header.name] = header.value;
158
- }
159
- }
160
- }
161
- }
162
- if (options.timeout) {
163
- requestOptions.timeout = options.timeout;
164
- }
165
- if (options.ignoreSSL) {
166
- requestOptions.skipSslCertificateValidation = options.ignoreSSL;
167
- }
168
- const authentication = this.getNodeParameter('authentication', itemIndex);
169
- let response;
170
- if (authentication === 'none') {
171
- response = await this.helpers.httpRequest(requestOptions);
172
- }
173
- else if (authentication === 'customHeader') {
174
- const credentials = await this.getCredentials('customHeaderAuthApi');
175
- const headerName = credentials.headerName;
176
- const headerValue = credentials.headerValue;
177
- if (!requestOptions.headers) {
178
- requestOptions.headers = {};
179
- }
180
- requestOptions.headers[headerName] = headerValue;
181
- response = await this.helpers.httpRequest(requestOptions);
182
- }
183
- else {
184
- response = await this.helpers.httpRequestWithAuthentication.call(this, authentication, requestOptions);
185
- }
52
+ const executionMode = this.getNodeParameter('executionMode', 0, 'sequential');
53
+ if (executionMode === 'parallel') {
54
+ return executeParallel.call(this, items);
55
+ }
56
+ else {
57
+ return executeSequential.call(this, items);
58
+ }
59
+ }
60
+ }
61
+ exports.MultipleUploadRequest = MultipleUploadRequest;
62
+ async function executeSequential(items) {
63
+ const returnData = [];
64
+ for (let itemIndex = 0; itemIndex < items.length; itemIndex++) {
65
+ try {
66
+ const result = await processItem.call(this, items, itemIndex);
67
+ returnData.push({
68
+ json: result,
69
+ pairedItem: { item: itemIndex },
70
+ });
71
+ }
72
+ catch (error) {
73
+ if (this.continueOnFail()) {
186
74
  returnData.push({
187
- json: response,
75
+ json: { error: error.message },
188
76
  pairedItem: { item: itemIndex },
189
77
  });
78
+ continue;
79
+ }
80
+ if (error.context) {
81
+ error.context.itemIndex = itemIndex;
82
+ throw error;
83
+ }
84
+ throw new n8n_workflow_1.NodeOperationError(this.getNode(), error, { itemIndex });
85
+ }
86
+ }
87
+ return [returnData];
88
+ }
89
+ async function executeParallel(items) {
90
+ const concurrencyLimit = this.getNodeParameter('concurrencyLimit', 0, 0);
91
+ const onError = this.getNodeParameter('options.onError', 0, 'stopAll');
92
+ const limit = (0, concurrency_1.createConcurrencyLimiter)(concurrencyLimit);
93
+ const promises = items.map((_, itemIndex) => limit(() => processItem.call(this, items, itemIndex).then((result) => ({ itemIndex, result }))));
94
+ if (onError === 'continueOthers') {
95
+ const settled = await Promise.allSettled(promises);
96
+ const returnData = [];
97
+ for (let i = 0; i < settled.length; i++) {
98
+ const outcome = settled[i];
99
+ if (outcome.status === 'fulfilled') {
100
+ returnData.push({
101
+ json: outcome.value.result,
102
+ pairedItem: { item: outcome.value.itemIndex },
103
+ });
190
104
  }
191
- catch (error) {
192
- if (this.continueOnFail()) {
193
- returnData.push({
194
- json: {
195
- error: error.message,
105
+ else {
106
+ returnData.push({
107
+ json: {
108
+ error: outcome.reason.message || 'Unknown error',
109
+ itemIndex: i,
110
+ status: 'failed',
111
+ },
112
+ pairedItem: { item: i },
113
+ });
114
+ }
115
+ }
116
+ return [returnData];
117
+ }
118
+ else {
119
+ try {
120
+ const results = await Promise.all(promises);
121
+ const returnData = results.map(({ itemIndex, result }) => ({
122
+ json: result,
123
+ pairedItem: { item: itemIndex },
124
+ }));
125
+ return [returnData];
126
+ }
127
+ catch (error) {
128
+ if (this.continueOnFail()) {
129
+ return [
130
+ [
131
+ {
132
+ json: { error: error.message },
133
+ pairedItem: { item: 0 },
196
134
  },
197
- pairedItem: { item: itemIndex },
198
- });
199
- continue;
135
+ ],
136
+ ];
137
+ }
138
+ throw error;
139
+ }
140
+ }
141
+ }
142
+ async function processItem(items, itemIndex) {
143
+ const requestMethod = this.getNodeParameter('requestMethod', itemIndex);
144
+ const url = this.getNodeParameter('url', itemIndex);
145
+ const sendMethod = this.getNodeParameter('sendMethod', itemIndex, 'multipart');
146
+ const options = this.getNodeParameter('options', itemIndex, {});
147
+ if (!url) {
148
+ throw new n8n_workflow_1.NodeOperationError(this.getNode(), 'URL is required', { itemIndex });
149
+ }
150
+ let requestOptions;
151
+ if (sendMethod === 'jsonBody') {
152
+ requestOptions = await buildJsonBodyRequest.call(this, itemIndex, requestMethod, url);
153
+ }
154
+ else if (sendMethod === 'base64') {
155
+ requestOptions = await buildBase64Request.call(this, items, itemIndex, requestMethod, url, options);
156
+ }
157
+ else {
158
+ requestOptions = await buildMultipartRequest.call(this, items, itemIndex, requestMethod, url, options);
159
+ }
160
+ applyCommonOptions(requestOptions, options);
161
+ const authentication = this.getNodeParameter('authentication', itemIndex);
162
+ return executeHttpRequest.call(this, authentication, requestOptions);
163
+ }
164
+ async function buildJsonBodyRequest(itemIndex, requestMethod, url) {
165
+ const jsonBodyContent = this.getNodeParameter('jsonBodyContent', itemIndex, '{}');
166
+ const body = (0, n8n_workflow_1.jsonParse)(jsonBodyContent, {
167
+ errorMessage: 'Invalid JSON body. Please check your JSON syntax.',
168
+ });
169
+ return {
170
+ method: requestMethod,
171
+ url,
172
+ body,
173
+ headers: {
174
+ 'Content-Type': 'application/json',
175
+ },
176
+ };
177
+ }
178
+ async function buildBase64Request(items, itemIndex, requestMethod, url, options) {
179
+ const fileFieldName = this.getNodeParameter('fileFieldName', itemIndex, 'files');
180
+ const filteredFiles = getFilteredBinaryFiles.call(this, items, itemIndex);
181
+ const base64Files = [];
182
+ for (const [key, binaryData] of Object.entries(filteredFiles)) {
183
+ const buffer = await this.helpers.getBinaryDataBuffer(itemIndex, key);
184
+ base64Files.push({
185
+ filename: binaryData.fileName || key,
186
+ mimeType: binaryData.mimeType || 'application/octet-stream',
187
+ data: buffer.toString('base64'),
188
+ });
189
+ }
190
+ const jsonBody = {
191
+ [fileFieldName]: base64Files,
192
+ };
193
+ addFormFieldsToJsonBody(jsonBody, options);
194
+ return {
195
+ method: requestMethod,
196
+ url,
197
+ body: jsonBody,
198
+ headers: {
199
+ 'Content-Type': 'application/json',
200
+ },
201
+ };
202
+ }
203
+ async function buildMultipartRequest(items, itemIndex, requestMethod, url, options) {
204
+ var _a;
205
+ const fileFieldName = this.getNodeParameter('fileFieldName', itemIndex, 'files');
206
+ const filteredFiles = getFilteredBinaryFiles.call(this, items, itemIndex);
207
+ const form = new form_data_1.default();
208
+ let fileIndex = 0;
209
+ for (const [key, binaryData] of Object.entries(filteredFiles)) {
210
+ const buffer = await this.helpers.getBinaryDataBuffer(itemIndex, key);
211
+ const fieldKey = `${fileFieldName}[${fileIndex}]`;
212
+ form.append(fieldKey, buffer, {
213
+ filename: binaryData.fileName || key,
214
+ contentType: binaryData.mimeType || 'application/octet-stream',
215
+ });
216
+ fileIndex++;
217
+ }
218
+ if (options.formFields) {
219
+ const formFields = options.formFields.field;
220
+ if (formFields && Array.isArray(formFields)) {
221
+ for (const field of formFields) {
222
+ if (field.name) {
223
+ form.append(field.name, String((_a = field.value) !== null && _a !== void 0 ? _a : ''));
200
224
  }
201
- if (error.context) {
202
- error.context.itemIndex = itemIndex;
203
- throw error;
225
+ }
226
+ }
227
+ }
228
+ return {
229
+ method: requestMethod,
230
+ url,
231
+ body: form,
232
+ headers: form.getHeaders(),
233
+ };
234
+ }
235
+ function getFilteredBinaryFiles(items, itemIndex) {
236
+ const filePattern = this.getNodeParameter('filePattern', itemIndex, '*');
237
+ const binaryPropertyName = this.getNodeParameter('binaryPropertyName', itemIndex, 'data');
238
+ const item = items[itemIndex];
239
+ if (!item.binary) {
240
+ throw new n8n_workflow_1.NodeOperationError(this.getNode(), 'No binary data found in input. Please connect a node that provides binary data.', { itemIndex });
241
+ }
242
+ const propertyNames = binaryPropertyName.split(',').map((name) => name.trim());
243
+ let allBinaryFiles = {};
244
+ for (const propName of propertyNames) {
245
+ if (item.binary[propName]) {
246
+ allBinaryFiles[propName] = item.binary[propName];
247
+ }
248
+ }
249
+ if (Object.keys(allBinaryFiles).length === 0) {
250
+ allBinaryFiles = item.binary;
251
+ }
252
+ const filteredFiles = (0, utils_1.filterBinaryFiles)(allBinaryFiles, filePattern);
253
+ if (Object.keys(filteredFiles).length === 0) {
254
+ throw new n8n_workflow_1.NodeOperationError(this.getNode(), `No binary files match the pattern: ${filePattern}`, { itemIndex });
255
+ }
256
+ return filteredFiles;
257
+ }
258
+ function addFormFieldsToJsonBody(jsonBody, options) {
259
+ if (options.formFields) {
260
+ const formFields = options.formFields.field;
261
+ if (formFields && Array.isArray(formFields)) {
262
+ for (const field of formFields) {
263
+ if (field.name) {
264
+ jsonBody[field.name] = field.value;
204
265
  }
205
- throw new n8n_workflow_1.NodeOperationError(this.getNode(), error, {
206
- itemIndex,
207
- });
208
266
  }
209
267
  }
210
- return [returnData];
211
268
  }
212
269
  }
213
- exports.MultipleUploadRequest = MultipleUploadRequest;
270
+ function applyCommonOptions(requestOptions, options) {
271
+ if (options.queryParameters) {
272
+ const queryParams = options.queryParameters.parameter;
273
+ if (queryParams && Array.isArray(queryParams)) {
274
+ const qs = {};
275
+ for (const param of queryParams) {
276
+ if (param.name) {
277
+ qs[param.name] = param.value;
278
+ }
279
+ }
280
+ requestOptions.qs = qs;
281
+ }
282
+ }
283
+ if (options.headers) {
284
+ const headers = options.headers.header;
285
+ if (headers && Array.isArray(headers)) {
286
+ for (const header of headers) {
287
+ if (header.name) {
288
+ requestOptions.headers[header.name] = header.value;
289
+ }
290
+ }
291
+ }
292
+ }
293
+ if (options.timeout) {
294
+ requestOptions.timeout = options.timeout;
295
+ }
296
+ if (options.ignoreSSL) {
297
+ requestOptions.skipSslCertificateValidation = options.ignoreSSL;
298
+ }
299
+ }
300
+ async function executeHttpRequest(authentication, requestOptions) {
301
+ if (authentication === 'none') {
302
+ return this.helpers.httpRequest(requestOptions);
303
+ }
304
+ else if (authentication === 'customHeader') {
305
+ return this.helpers.httpRequestWithAuthentication.call(this, 'customHeaderAuthApi', requestOptions);
306
+ }
307
+ else {
308
+ return this.helpers.httpRequestWithAuthentication.call(this, 'bearerTokenAuthApi', requestOptions);
309
+ }
310
+ }
214
311
  //# sourceMappingURL=MultipleUploadRequest.node.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"MultipleUploadRequest.node.js","sourceRoot":"","sources":["../../../nodes/MultipleUploadRequest/MultipleUploadRequest.node.ts"],"names":[],"mappings":";;;AAUA,+CAAuE;AACvE,+CAAiE;AACjE,mCAA4C;AAE5C,MAAa,qBAAqB;IAAlC;QACC,gBAAW,GAAyB;YACnC,WAAW,EAAE,yBAAyB;YACtC,IAAI,EAAE,uBAAuB;YAC7B,IAAI,EAAE,iBAAiB;YACvB,KAAK,EAAE,CAAC,WAAW,CAAC;YACpB,OAAO,EAAE,CAAC;YACV,WAAW,EAAE,qDAAqD;YAClE,Q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AAS,GAAG,SAAS,CAAC;oBACpC,MAAM,KAAK,CAAC;gBACb,CAAC;gBAED,MAAM,IAAI,iCAAkB,CAAC,IAAI,CAAC,OAAO,EAAE,EAAE,KAAK,EAAE;oBACnD,SAAS;iBACT,CAAC,CAAC;YACJ,CAAC;QACF,CAAC;QAED,OAAO,CAAC,UAAU,CAAC,CAAC;IACrB,CAAC;CACD;AA3QD,sDA2QC"}
1
+ {"version":3,"file":"MultipleUploadRequest.node.js","sourceRoot":"","sources":["../../../nodes/MultipleUploadRequest/MultipleUploadRequest.node.ts"],"names":[],"mappings":";;;;;;AAUA,+CAAkF;AAClF,0DAAiC;AACjC,+CAAiE;AACjE,mCAA4C;AAC5C,wEAAkF;AAElF,MAAa,qBAAqB;IAAlC;QACC,gBAAW,GAAyB;YACnC,WAAW,EAAE,yBAAyB;YACtC,IAAI,EAAE,uBAAuB;YAC7B,IAAI,EAAE,iBAAiB;YACvB,KAAK,EAAE,CAAC,WAAW,CAAC;YACpB,OAAO,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC;YACf,WAAW,EAAE,4EAA4E;YACzF,QAAQ,EAAE;gBACT,IAAI,EAAE,yBAAyB;aAC/B;YACD,MAAM,EAAE,CAAC,kCAAmB,CAAC,IAAI,CAAC;YAClC,OAAO,EAAE,CAAC,kCAAmB,CAAC,IAAI,CAAC;YACnC,WAAW,EAAE;gBACZ;oBACC,IAAI,EAAE,oBAAoB;oBAC1B,QAAQ,EAAE,IAAI;oBACd,cAAc,EAAE;wBACf,IAAI,EAAE;4BACL,cAAc,EAAE,CAAC,QAAQ,CAAC;yBAC1B;qBACD;iBACD;gBACD;oBACC,IAAI,EAAE,qBAAqB;oBAC3B,QAAQ,EAAE,IAAI;oBACd,cAAc,EAAE;wBACf,IAAI,EAAE;4BACL,cAAc,EAAE,CAAC,cAAc,CAAC;yBAChC;qBACD;iBACD;aACD;YACD,UAAU,EAAE,8CAAgC;YAC5C,YAAY,EAAE,IAAI;SAClB,CAAC;IAYH,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AAC;AACF,CAAC"}
@@ -68,20 +68,41 @@ exports.multipleUploadRequestDescription = [
68
68
  value: 'base64',
69
69
  description: 'Send files as base64-encoded strings in JSON body',
70
70
  },
71
+ {
72
+ name: 'JSON Body (Raw)',
73
+ value: 'jsonBody',
74
+ description: 'Send a raw JSON body. Paste or use an expression for the full request body instead of filling individual fields.',
75
+ },
71
76
  ],
72
77
  default: 'multipart',
73
78
  description: 'How to send the files to the endpoint',
74
79
  },
80
+ {
81
+ displayName: 'JSON Body',
82
+ name: 'jsonBodyContent',
83
+ type: 'json',
84
+ typeOptions: {
85
+ rows: 10,
86
+ },
87
+ displayOptions: {
88
+ show: {
89
+ sendMethod: ['jsonBody'],
90
+ },
91
+ },
92
+ default: '{}',
93
+ required: true,
94
+ description: 'The raw JSON body to send with the request. Use n8n expressions to include dynamic data. Binary files are NOT attached in this mode.',
95
+ },
75
96
  {
76
97
  displayName: 'File Field Name',
77
98
  name: 'fileFieldName',
78
99
  type: 'string',
79
100
  default: 'files',
80
101
  placeholder: 'files',
81
- description: 'The field name for files in the request. For multipart: each file uses this as prefix. For base64: the JSON array key.',
102
+ description: 'The field name for files in the request. For multipart: each file uses this as prefix (e.g. files[0], files[1]). For base64: the JSON array key.',
82
103
  displayOptions: {
83
- show: {
84
- sendMethod: ['base64'],
104
+ hide: {
105
+ sendMethod: ['jsonBody'],
85
106
  },
86
107
  },
87
108
  },
@@ -92,6 +113,11 @@ exports.multipleUploadRequestDescription = [
92
113
  default: '*',
93
114
  placeholder: '*.jpg or image_*.png',
94
115
  description: 'Pattern to filter binary files. Use * to match any characters and ? to match a single character. Leave as * to upload all binary files.',
116
+ displayOptions: {
117
+ hide: {
118
+ sendMethod: ['jsonBody'],
119
+ },
120
+ },
95
121
  },
96
122
  {
97
123
  displayName: 'Binary Property Name',
@@ -99,6 +125,45 @@ exports.multipleUploadRequestDescription = [
99
125
  type: 'string',
100
126
  default: 'data',
101
127
  description: 'Name of the binary property which contains the files to upload. Multiple properties can be comma-separated.',
128
+ displayOptions: {
129
+ hide: {
130
+ sendMethod: ['jsonBody'],
131
+ },
132
+ },
133
+ },
134
+ {
135
+ displayName: 'Execution Mode',
136
+ name: 'executionMode',
137
+ type: 'options',
138
+ options: [
139
+ {
140
+ name: 'Sequential',
141
+ value: 'sequential',
142
+ description: 'Process each input item one at a time (default behavior)',
143
+ },
144
+ {
145
+ name: 'Parallel (Promise.all)',
146
+ value: 'parallel',
147
+ description: 'Process all input items simultaneously. All HTTP requests are fired in parallel and the node waits for all to complete.',
148
+ },
149
+ ],
150
+ default: 'sequential',
151
+ description: 'How to process multiple input items',
152
+ },
153
+ {
154
+ displayName: 'Concurrency Limit',
155
+ name: 'concurrencyLimit',
156
+ type: 'number',
157
+ default: 0,
158
+ typeOptions: {
159
+ minValue: 0,
160
+ },
161
+ displayOptions: {
162
+ show: {
163
+ executionMode: ['parallel'],
164
+ },
165
+ },
166
+ description: 'Maximum number of HTTP requests to run simultaneously. Set to 0 for unlimited. Use a limit to avoid overwhelming the target API.',
102
167
  },
103
168
  {
104
169
  displayName: 'Options',
@@ -178,6 +243,30 @@ exports.multipleUploadRequestDescription = [
178
243
  default: false,
179
244
  description: 'Whether to ignore SSL certificate errors',
180
245
  },
246
+ {
247
+ displayName: 'On Error',
248
+ name: 'onError',
249
+ type: 'options',
250
+ options: [
251
+ {
252
+ name: 'Stop All (Promise.all)',
253
+ value: 'stopAll',
254
+ description: 'If any request fails, stop and report the error immediately (only applies in Parallel mode)',
255
+ },
256
+ {
257
+ name: 'Continue Others (Promise.allSettled)',
258
+ value: 'continueOthers',
259
+ description: 'Continue other requests even if some fail, output errors as items (only applies in Parallel mode)',
260
+ },
261
+ ],
262
+ default: 'stopAll',
263
+ description: 'How to handle errors when running in Parallel mode. In Sequential mode, use the built-in "Continue On Fail" setting.',
264
+ displayOptions: {
265
+ show: {
266
+ '/executionMode': ['parallel'],
267
+ },
268
+ },
269
+ },
181
270
  {
182
271
  displayName: 'Query Parameters',
183
272
  name: 'queryParameters',