n8n-nodes-ancoremate 1.23.4 → 1.23.6

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.
@@ -66,7 +66,7 @@ class AncoreMateOAuth2Api {
66
66
  "baseURL": "https://ancorecloud.com/ancoremate",
67
67
  "url": "/v1/connection",
68
68
  "headers": {
69
- "X-AncoreMate-Client": "n8n/1.23.4"
69
+ "X-AncoreMate-Client": "n8n/1.23.6"
70
70
  }
71
71
  }
72
72
  };
@@ -4,7 +4,7 @@ exports.AncoreMateAppData = void 0;
4
4
  const n8n_workflow_1 = require("n8n-workflow");
5
5
  const runtime_1 = require("../shared/runtime");
6
6
  const BASE_URL = 'https://ancorecloud.com/ancoremate';
7
- const CLIENT = 'n8n/1.23.4';
7
+ const CLIENT = 'n8n/1.23.6';
8
8
  const OPERATIONS = {
9
9
  "createBookmark": {
10
10
  "method": "POST",
@@ -4,7 +4,7 @@ exports.AncoreMateApps = void 0;
4
4
  const n8n_workflow_1 = require("n8n-workflow");
5
5
  const runtime_1 = require("../shared/runtime");
6
6
  const BASE_URL = 'https://ancorecloud.com/ancoremate';
7
- const CLIENT = 'n8n/1.23.4';
7
+ const CLIENT = 'n8n/1.23.6';
8
8
  const OPERATIONS = {
9
9
  "changeAppOwner": {
10
10
  "method": "PUT",
@@ -4,7 +4,7 @@ exports.AncoreMateAppsTrigger = void 0;
4
4
  const n8n_workflow_1 = require("n8n-workflow");
5
5
  const runtime_1 = require("../shared/runtime");
6
6
  const BASE_URL = 'https://ancorecloud.com/ancoremate';
7
- const CLIENT = 'n8n/1.23.4';
7
+ const CLIENT = 'n8n/1.23.6';
8
8
  const EVENTS = {
9
9
  "whenAppCreated": {
10
10
  "path": "/v1/triggers/app-created",
@@ -4,7 +4,7 @@ exports.AncoreMateAutomations = void 0;
4
4
  const n8n_workflow_1 = require("n8n-workflow");
5
5
  const runtime_1 = require("../shared/runtime");
6
6
  const BASE_URL = 'https://ancorecloud.com/ancoremate';
7
- const CLIENT = 'n8n/1.23.4';
7
+ const CLIENT = 'n8n/1.23.6';
8
8
  const OPERATIONS = {
9
9
  "copyAutomation": {
10
10
  "method": "POST",
@@ -4,7 +4,7 @@ exports.AncoreMateAutomationsTrigger = void 0;
4
4
  const n8n_workflow_1 = require("n8n-workflow");
5
5
  const runtime_1 = require("../shared/runtime");
6
6
  const BASE_URL = 'https://ancorecloud.com/ancoremate';
7
- const CLIENT = 'n8n/1.23.4';
7
+ const CLIENT = 'n8n/1.23.6';
8
8
  const EVENTS = {
9
9
  "whenAutomationCreated": {
10
10
  "path": "/v1/triggers/automation-created",
@@ -4,7 +4,7 @@ exports.AncoreMateCatalog = void 0;
4
4
  const n8n_workflow_1 = require("n8n-workflow");
5
5
  const runtime_1 = require("../shared/runtime");
6
6
  const BASE_URL = 'https://ancorecloud.com/ancoremate';
7
- const CLIENT = 'n8n/1.23.4';
7
+ const CLIENT = 'n8n/1.23.6';
8
8
  const OPERATIONS = {
9
9
  "changeGlossaryTermStatus": {
10
10
  "method": "PUT",
@@ -4,7 +4,7 @@ exports.AncoreMateContent = void 0;
4
4
  const n8n_workflow_1 = require("n8n-workflow");
5
5
  const runtime_1 = require("../shared/runtime");
6
6
  const BASE_URL = 'https://ancorecloud.com/ancoremate';
7
- const CLIENT = 'n8n/1.23.4';
7
+ const CLIENT = 'n8n/1.23.6';
8
8
  const OPERATIONS = {
9
9
  "getQlikConnection": {
10
10
  "method": "GET",
@@ -4,7 +4,7 @@ exports.AncoreMateReloads = void 0;
4
4
  const n8n_workflow_1 = require("n8n-workflow");
5
5
  const runtime_1 = require("../shared/runtime");
6
6
  const BASE_URL = 'https://ancorecloud.com/ancoremate';
7
- const CLIENT = 'n8n/1.23.4';
7
+ const CLIENT = 'n8n/1.23.6';
8
8
  const OPERATIONS = {
9
9
  "getQlikConnection": {
10
10
  "method": "GET",
@@ -4,7 +4,7 @@ exports.AncoreMateReloadsTrigger = void 0;
4
4
  const n8n_workflow_1 = require("n8n-workflow");
5
5
  const runtime_1 = require("../shared/runtime");
6
6
  const BASE_URL = 'https://ancorecloud.com/ancoremate';
7
- const CLIENT = 'n8n/1.23.4';
7
+ const CLIENT = 'n8n/1.23.6';
8
8
  const EVENTS = {
9
9
  "whenAppReloadFinished": {
10
10
  "path": "/v1/triggers/app-reload-finished",
@@ -4,7 +4,7 @@ exports.AncoreMateSpacesAndAccess = void 0;
4
4
  const n8n_workflow_1 = require("n8n-workflow");
5
5
  const runtime_1 = require("../shared/runtime");
6
6
  const BASE_URL = 'https://ancorecloud.com/ancoremate';
7
- const CLIENT = 'n8n/1.23.4';
7
+ const CLIENT = 'n8n/1.23.6';
8
8
  const OPERATIONS = {
9
9
  "addSpaceMember": {
10
10
  "method": "POST",
@@ -4,7 +4,7 @@ exports.AncoreShare = void 0;
4
4
  const n8n_workflow_1 = require("n8n-workflow");
5
5
  const runtime_1 = require("../shared/runtime");
6
6
  const BASE_URL = 'https://ancorecloud.com/ancoremate';
7
- const CLIENT = 'n8n/1.23.4';
7
+ const CLIENT = 'n8n/1.23.6';
8
8
  const OPERATIONS = {
9
9
  "downloadAncoreShareFile": {
10
10
  "method": "POST",
@@ -4,7 +4,7 @@ exports.AncoreShareTrigger = void 0;
4
4
  const n8n_workflow_1 = require("n8n-workflow");
5
5
  const runtime_1 = require("../shared/runtime");
6
6
  const BASE_URL = 'https://ancorecloud.com/ancoremate';
7
- const CLIENT = 'n8n/1.23.4';
7
+ const CLIENT = 'n8n/1.23.6';
8
8
  const EVENTS = {
9
9
  "whenAncoreShareReportFinished": {
10
10
  "path": "/v1/triggers/ancoreshare-report-finished",
@@ -9,7 +9,7 @@ exports.loadOptions = loadOptions;
9
9
  const n8n_workflow_1 = require("n8n-workflow");
10
10
  const CREDENTIAL = 'ancoreMateOAuth2Api';
11
11
  const MAX_WAIT_MS = 6 * 60 * 60 * 1000;
12
- async function request(client, method, url, qs, body, fileResponse = false) {
12
+ async function request(client, method, url, qs, body, fileResponse = false, read = method === 'GET') {
13
13
  const file = Buffer.isBuffer(body);
14
14
  const headers = { Accept: fileResponse ? '*/*' : 'application/json', 'X-AncoreMate-Client': client };
15
15
  if (file) {
@@ -29,14 +29,29 @@ async function request(client, method, url, qs, body, fileResponse = false) {
29
29
  if (body !== undefined) {
30
30
  options.body = body;
31
31
  }
32
- return (await this.helpers.httpRequestWithAuthentication.call(this, CREDENTIAL, options));
32
+ const send = async () => (await this.helpers.httpRequestWithAuthentication.call(this, CREDENTIAL, options));
33
+ return read
34
+ ? await send().catch(async (error) => (isClosedConnection(error) ? await send() : Promise.reject(error)))
35
+ : await send();
36
+ }
37
+ function isClosedConnection(error) {
38
+ var _a, _b;
39
+ let current = error;
40
+ for (let depth = 0; current !== undefined && current !== null && depth < 5; depth++) {
41
+ const value = current;
42
+ if (/ECONNRESET|EPIPE|socket hang up|closed unexpectedly/i.test(`${String((_a = value.code) !== null && _a !== void 0 ? _a : '')} ${String((_b = value.message) !== null && _b !== void 0 ? _b : '')}`)) {
43
+ return true;
44
+ }
45
+ current = value.cause;
46
+ }
47
+ return false;
33
48
  }
34
49
  function header(response, name) {
35
50
  const value = response.headers[name.toLowerCase()];
36
51
  return Array.isArray(value) ? value[0] : value;
37
52
  }
38
53
  async function send(baseUrl, client, spec, path, qs, body) {
39
- let response = await request.call(this, client, spec.method, baseUrl + path, qs, body, spec.fileOutput);
54
+ let response = await request.call(this, client, spec.method, baseUrl + path, qs, body, spec.fileOutput, spec.method === 'GET' || spec.read);
40
55
  const started = Date.now();
41
56
  while (spec.async && response.statusCode === 202) {
42
57
  const location = header(response, 'location');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "n8n-nodes-ancoremate",
3
- "version": "1.23.4",
3
+ "version": "1.23.6",
4
4
  "description": "n8n nodes for Qlik Cloud® automation by ancoreSoft. Qlik®, Qlik Cloud® and Qlik Sense® are trademarks of QlikTech International AB. ancoreMate is not affiliated with or endorsed by Qlik.",
5
5
  "keywords": [
6
6
  "n8n-community-node-package",