@limetech/n8n-nodes-lime 0.3.8 → 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.
- package/CHANGELOG.md +7 -0
- package/dist/nodes/lime-crm/LimeCrmNode.node.js +13 -0
- package/dist/nodes/lime-crm/LimeCrmNode.node.js.map +1 -1
- package/dist/nodes/lime-crm/commons/constants.d.ts +1 -0
- package/dist/nodes/lime-crm/commons/constants.js +2 -1
- package/dist/nodes/lime-crm/commons/constants.js.map +1 -1
- package/dist/nodes/lime-crm/commons/index.d.ts +1 -1
- package/dist/nodes/lime-crm/commons/index.js +2 -1
- package/dist/nodes/lime-crm/commons/index.js.map +1 -1
- package/dist/nodes/lime-crm/resources/limeQuery/index.d.ts +6 -0
- package/dist/nodes/lime-crm/resources/limeQuery/index.js +66 -0
- package/dist/nodes/lime-crm/resources/limeQuery/index.js.map +1 -0
- package/dist/nodes/lime-crm/resources/limeQuery/operations/query.operation.d.ts +9 -0
- package/dist/nodes/lime-crm/resources/limeQuery/operations/query.operation.js +191 -0
- package/dist/nodes/lime-crm/resources/limeQuery/operations/query.operation.js.map +1 -0
- package/dist/nodes/lime-crm/resources/limeType/index.d.ts +3 -3
- package/dist/nodes/lime-crm/transport/index.d.ts +1 -0
- package/dist/nodes/lime-crm/transport/index.js +3 -1
- package/dist/nodes/lime-crm/transport/index.js.map +1 -1
- package/dist/nodes/lime-crm/transport/limeQuery.d.ts +10 -0
- package/dist/nodes/lime-crm/transport/limeQuery.js +15 -0
- package/dist/nodes/lime-crm/transport/limeQuery.js.map +1 -0
- package/dist/package.json +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/nodes/lime-crm/LimeCrmNode.node.ts +14 -0
- package/nodes/lime-crm/commons/constants.ts +1 -0
- package/nodes/lime-crm/commons/index.ts +1 -0
- package/nodes/lime-crm/resources/limeQuery/index.ts +40 -0
- package/nodes/lime-crm/resources/limeQuery/operations/query.operation.ts +222 -0
- package/nodes/lime-crm/transport/index.ts +1 -0
- package/nodes/lime-crm/transport/limeQuery.ts +28 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,10 @@
|
|
|
1
|
+
# [1.8.0](https://github.com/Lundalogik/lime-n8n/compare/v1.7.2...v1.8.0) (2025-10-10)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Features
|
|
5
|
+
|
|
6
|
+
* **lime-crm:** add support for the Query API ([a34a011](https://github.com/Lundalogik/lime-n8n/commit/a34a011b0e48bc7f5d15e39af22764cf3f512d68))
|
|
7
|
+
|
|
1
8
|
## [1.7.2](https://github.com/Lundalogik/lime-n8n/compare/v1.7.1...v1.7.2) (2025-10-07)
|
|
2
9
|
|
|
3
10
|
|
|
@@ -4,6 +4,7 @@ exports.LimeCrmTrigger = exports.LimeCrmNode = void 0;
|
|
|
4
4
|
const erpConnector_1 = require("./resources/erpConnector");
|
|
5
5
|
const limeType_1 = require("./resources/limeType");
|
|
6
6
|
const limeObject_1 = require("./resources/limeObject");
|
|
7
|
+
const limeQuery_1 = require("./resources/limeQuery");
|
|
7
8
|
const commons_1 = require("./commons");
|
|
8
9
|
const methods_1 = require("./methods");
|
|
9
10
|
class LimeCrmNode {
|
|
@@ -49,12 +50,18 @@ class LimeCrmNode {
|
|
|
49
50
|
value: commons_1.ERP_CONNECTOR_RESOURCE,
|
|
50
51
|
description: 'Integrate data between ERP and Lime CRM',
|
|
51
52
|
},
|
|
53
|
+
{
|
|
54
|
+
name: 'Lime Query',
|
|
55
|
+
value: commons_1.LIME_QUERY_RESOURCE,
|
|
56
|
+
description: 'Easily gather a particular set of limeobjects',
|
|
57
|
+
},
|
|
52
58
|
],
|
|
53
59
|
default: commons_1.LIMEOBJECT_RESOURCE,
|
|
54
60
|
},
|
|
55
61
|
...limeType_1.limeTypeFields,
|
|
56
62
|
...limeObject_1.limeObjectFields,
|
|
57
63
|
...erpConnector_1.erpConnectorFields,
|
|
64
|
+
...limeQuery_1.queryFields,
|
|
58
65
|
],
|
|
59
66
|
};
|
|
60
67
|
this.methods = {
|
|
@@ -91,6 +98,12 @@ class LimeCrmNode {
|
|
|
91
98
|
i,
|
|
92
99
|
});
|
|
93
100
|
}
|
|
101
|
+
else if (resource === commons_1.LIME_QUERY_RESOURCE) {
|
|
102
|
+
responseData = await limeQuery_1.queryOperations.call(this, {
|
|
103
|
+
operation,
|
|
104
|
+
i,
|
|
105
|
+
});
|
|
106
|
+
}
|
|
94
107
|
returnData.push({ json: responseData });
|
|
95
108
|
}
|
|
96
109
|
catch (error) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LimeCrmNode.node.js","sourceRoot":"","sources":["../../../nodes/lime-crm/LimeCrmNode.node.ts"],"names":[],"mappings":";;;AAUA,2DAGkC;AAClC,mDAA0E;AAC1E,uDAAgF;
|
|
1
|
+
{"version":3,"file":"LimeCrmNode.node.js","sourceRoot":"","sources":["../../../nodes/lime-crm/LimeCrmNode.node.ts"],"names":[],"mappings":";;;AAUA,2DAGkC;AAClC,mDAA0E;AAC1E,uDAAgF;AAChF,qDAAqE;AAErE,uCAMmB;AAEnB,uCAImB;AAEnB,MAAa,WAAW;IAAxB;QACI,gBAAW,GAAyB;YAChC,WAAW,EAAE,UAAU;YACvB,IAAI,EAAE,SAAS;YACf,IAAI,EAAE,0BAA0B;YAChC,KAAK,EAAE,CAAC,WAAW,CAAC;YACpB,OAAO,EAAE,CAAC;YACV,QAAQ,EACJ,8DAA8D;YAClE,WAAW,EAAE,0BAA0B;YACvC,QAAQ,EAAE;gBACN,IAAI,EAAE,UAAU;aACnB;YACD,MAAM,EAAE,QAAyB;YACjC,OAAO,EAAE,QAAyB;YAClC,WAAW,EAAE;gBACT;oBACI,IAAI,EAAE,qCAA2B;oBACjC,QAAQ,EAAE,IAAI;iBACjB;aACJ;YACD,UAAU,EAAE;gBACR;oBACI,WAAW,EAAE,UAAU;oBACvB,IAAI,EAAE,UAAU;oBAChB,IAAI,EAAE,SA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CE = "limeObject";
|
|
3
3
|
export declare const LIMETYPE_RESOURCE = "limeType";
|
|
4
4
|
export declare const ERP_CONNECTOR_RESOURCE = "erpConnector";
|
|
5
|
+
export declare const LIME_QUERY_RESOURCE = "limeQuery";
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.ERP_CONNECTOR_RESOURCE = exports.LIMETYPE_RESOURCE = exports.LIMEOBJECT_RESOURCE = exports.LIME_CRM_API_CREDENTIAL_KEY = void 0;
|
|
3
|
+
exports.LIME_QUERY_RESOURCE = exports.ERP_CONNECTOR_RESOURCE = exports.LIMETYPE_RESOURCE = exports.LIMEOBJECT_RESOURCE = exports.LIME_CRM_API_CREDENTIAL_KEY = void 0;
|
|
4
4
|
exports.LIME_CRM_API_CREDENTIAL_KEY = 'limeCrmApi';
|
|
5
5
|
exports.LIMEOBJECT_RESOURCE = 'limeObject';
|
|
6
6
|
exports.LIMETYPE_RESOURCE = 'limeType';
|
|
7
7
|
exports.ERP_CONNECTOR_RESOURCE = 'erpConnector';
|
|
8
|
+
exports.LIME_QUERY_RESOURCE = 'limeQuery';
|
|
8
9
|
//# sourceMappingURL=constants.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../../nodes/lime-crm/commons/constants.ts"],"names":[],"mappings":";;;AAEa,QAAA,2BAA2B,GAAG,YAAY,CAAC;AAI3C,QAAA,mBAAmB,GAAG,YAAY,CAAC;AACnC,QAAA,iBAAiB,GAAG,UAAU,CAAC;AAC/B,QAAA,sBAAsB,GAAG,cAAc,CAAC"}
|
|
1
|
+
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../../nodes/lime-crm/commons/constants.ts"],"names":[],"mappings":";;;AAEa,QAAA,2BAA2B,GAAG,YAAY,CAAC;AAI3C,QAAA,mBAAmB,GAAG,YAAY,CAAC;AACnC,QAAA,iBAAiB,GAAG,UAAU,CAAC;AAC/B,QAAA,sBAAsB,GAAG,cAAc,CAAC;AACxC,QAAA,mBAAmB,GAAG,WAAW,CAAC"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { LIME_CRM_API_CREDENTIAL_KEY, LIMEOBJECT_RESOURCE, LIMETYPE_RESOURCE, ERP_CONNECTOR_RESOURCE, } from './constants';
|
|
1
|
+
export { LIME_CRM_API_CREDENTIAL_KEY, LIMEOBJECT_RESOURCE, LIMETYPE_RESOURCE, ERP_CONNECTOR_RESOURCE, LIME_QUERY_RESOURCE, } from './constants';
|
|
2
2
|
export { Webhook, getWebhook } from './webhook';
|
|
3
3
|
export { LimeType, LimeTypeProperty } from './limetype';
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.getWebhook = exports.ERP_CONNECTOR_RESOURCE = exports.LIMETYPE_RESOURCE = exports.LIMEOBJECT_RESOURCE = exports.LIME_CRM_API_CREDENTIAL_KEY = void 0;
|
|
3
|
+
exports.getWebhook = exports.LIME_QUERY_RESOURCE = exports.ERP_CONNECTOR_RESOURCE = exports.LIMETYPE_RESOURCE = exports.LIMEOBJECT_RESOURCE = exports.LIME_CRM_API_CREDENTIAL_KEY = void 0;
|
|
4
4
|
var constants_1 = require("./constants");
|
|
5
5
|
Object.defineProperty(exports, "LIME_CRM_API_CREDENTIAL_KEY", { enumerable: true, get: function () { return constants_1.LIME_CRM_API_CREDENTIAL_KEY; } });
|
|
6
6
|
Object.defineProperty(exports, "LIMEOBJECT_RESOURCE", { enumerable: true, get: function () { return constants_1.LIMEOBJECT_RESOURCE; } });
|
|
7
7
|
Object.defineProperty(exports, "LIMETYPE_RESOURCE", { enumerable: true, get: function () { return constants_1.LIMETYPE_RESOURCE; } });
|
|
8
8
|
Object.defineProperty(exports, "ERP_CONNECTOR_RESOURCE", { enumerable: true, get: function () { return constants_1.ERP_CONNECTOR_RESOURCE; } });
|
|
9
|
+
Object.defineProperty(exports, "LIME_QUERY_RESOURCE", { enumerable: true, get: function () { return constants_1.LIME_QUERY_RESOURCE; } });
|
|
9
10
|
var webhook_1 = require("./webhook");
|
|
10
11
|
Object.defineProperty(exports, "getWebhook", { enumerable: true, get: function () { return webhook_1.getWebhook; } });
|
|
11
12
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../nodes/lime-crm/commons/index.ts"],"names":[],"mappings":";;;AAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../nodes/lime-crm/commons/index.ts"],"names":[],"mappings":";;;AAAA,yCAMqB;AALjB,wHAAA,2BAA2B,OAAA;AAC3B,gHAAA,mBAAmB,OAAA;AACnB,8GAAA,iBAAiB,OAAA;AACjB,mHAAA,sBAAsB,OAAA;AACtB,gHAAA,mBAAmB,OAAA;AAEvB,qCAAgD;AAA9B,qGAAA,UAAU,OAAA"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { IExecuteFunctions, INodeProperties } from 'n8n-workflow';
|
|
2
|
+
export declare const queryFields: INodeProperties[];
|
|
3
|
+
export declare function queryOperations(this: IExecuteFunctions, { operation, i }: {
|
|
4
|
+
operation: string;
|
|
5
|
+
i: number;
|
|
6
|
+
}): Promise<import("../../../nodeResponse").NodeResponse<import("../../transport/limeQuery").QueryResponse> | null>;
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
35
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
+
exports.queryFields = void 0;
|
|
37
|
+
exports.queryOperations = queryOperations;
|
|
38
|
+
const query = __importStar(require("./operations/query.operation"));
|
|
39
|
+
const commons_1 = require("../../commons");
|
|
40
|
+
exports.queryFields = [
|
|
41
|
+
{
|
|
42
|
+
displayName: 'Operation',
|
|
43
|
+
name: 'operation',
|
|
44
|
+
type: 'options',
|
|
45
|
+
noDataExpression: true,
|
|
46
|
+
displayOptions: {
|
|
47
|
+
show: {
|
|
48
|
+
resource: [commons_1.LIME_QUERY_RESOURCE],
|
|
49
|
+
},
|
|
50
|
+
},
|
|
51
|
+
options: [
|
|
52
|
+
{
|
|
53
|
+
...query.description,
|
|
54
|
+
},
|
|
55
|
+
],
|
|
56
|
+
default: 'query',
|
|
57
|
+
},
|
|
58
|
+
...query.properties,
|
|
59
|
+
];
|
|
60
|
+
async function queryOperations({ operation, i }) {
|
|
61
|
+
if (operation === 'query') {
|
|
62
|
+
return await query.execute.call(this, i);
|
|
63
|
+
}
|
|
64
|
+
return null;
|
|
65
|
+
}
|
|
66
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../nodes/lime-crm/resources/limeQuery/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA+BA,0CAQC;AAjCD,oEAAsD;AACtD,2CAAoD;AAEvC,QAAA,WAAW,GAAsB;IAC1C;QACI,WAAW,EAAE,WAAW;QACxB,IAAI,EAAE,WAAW;QACjB,IAAI,EAAE,SAA8B;QACpC,gBAAgB,EAAE,IAAI;QACtB,cAAc,EAAE;YACZ,IAAI,EAAE;gBACF,QAAQ,EAAE,CAAC,6BAAmB,CAAC;aAClC;SACJ;QACD,OAAO,EAAE;YACL;gBACI,GAAG,KAAK,CAAC,WAAW;aACvB;SACJ;QACD,OAAO,EAAE,OAAO;KACnB;IAED,GAAG,KAAK,CAAC,UAAU;CACtB,CAAC;AAEK,KAAK,UAAU,eAAe,CAEjC,EAAE,SAAS,EAAE,CAAC,EAAoC;IAElD,IAAI,SAAS,KAAK,OAAO,EAAE,CAAC;QACxB,OAAO,MAAM,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC;IAC7C,CAAC;IACD,OAAO,IAAI,CAAC;AAChB,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { IExecuteFunctions, INodeProperties } from 'n8n-workflow';
|
|
2
|
+
export declare const description: {
|
|
3
|
+
name: string;
|
|
4
|
+
value: string;
|
|
5
|
+
description: string;
|
|
6
|
+
action: string;
|
|
7
|
+
};
|
|
8
|
+
export declare const properties: INodeProperties[];
|
|
9
|
+
export declare function execute(this: IExecuteFunctions, i: number): Promise<import("../../../../nodeResponse").NodeResponse<import("../../../transport/limeQuery").QueryResponse>>;
|
|
@@ -0,0 +1,191 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.properties = exports.description = void 0;
|
|
4
|
+
exports.execute = execute;
|
|
5
|
+
const transport_1 = require("../../../transport");
|
|
6
|
+
const commons_1 = require("../../../commons");
|
|
7
|
+
exports.description = {
|
|
8
|
+
name: 'Query',
|
|
9
|
+
value: 'query',
|
|
10
|
+
description: 'Query objects with Lime Query API',
|
|
11
|
+
action: 'Query objects',
|
|
12
|
+
};
|
|
13
|
+
exports.properties = [
|
|
14
|
+
{
|
|
15
|
+
displayName: 'Lime Type',
|
|
16
|
+
name: 'limeType',
|
|
17
|
+
type: 'options',
|
|
18
|
+
typeOptions: {
|
|
19
|
+
loadOptionsMethod: 'getLimeTypes',
|
|
20
|
+
},
|
|
21
|
+
required: true,
|
|
22
|
+
default: '',
|
|
23
|
+
description: 'The type of entity to query',
|
|
24
|
+
displayOptions: {
|
|
25
|
+
show: {
|
|
26
|
+
resource: [commons_1.LIME_QUERY_RESOURCE],
|
|
27
|
+
operation: ['query'],
|
|
28
|
+
},
|
|
29
|
+
},
|
|
30
|
+
},
|
|
31
|
+
{
|
|
32
|
+
displayName: 'Response Format (JSON)',
|
|
33
|
+
name: 'responseFormat',
|
|
34
|
+
type: 'json',
|
|
35
|
+
required: true,
|
|
36
|
+
default: '{}',
|
|
37
|
+
description: 'Information that should be included in the response',
|
|
38
|
+
displayOptions: {
|
|
39
|
+
show: {
|
|
40
|
+
resource: [commons_1.LIME_QUERY_RESOURCE],
|
|
41
|
+
operation: ['query'],
|
|
42
|
+
},
|
|
43
|
+
},
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
displayName: 'Filter (JSON)',
|
|
47
|
+
name: 'filter',
|
|
48
|
+
type: 'json',
|
|
49
|
+
default: '{}',
|
|
50
|
+
description: "The filter DSL defining the query's conditions",
|
|
51
|
+
displayOptions: {
|
|
52
|
+
show: {
|
|
53
|
+
resource: [commons_1.LIME_QUERY_RESOURCE],
|
|
54
|
+
operation: ['query'],
|
|
55
|
+
},
|
|
56
|
+
},
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
displayName: 'Limit',
|
|
60
|
+
name: 'limit',
|
|
61
|
+
type: 'number',
|
|
62
|
+
default: null,
|
|
63
|
+
description: 'The maximum number of records to return',
|
|
64
|
+
displayOptions: {
|
|
65
|
+
show: {
|
|
66
|
+
resource: [commons_1.LIME_QUERY_RESOURCE],
|
|
67
|
+
operation: ['query'],
|
|
68
|
+
},
|
|
69
|
+
},
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
|
+
displayName: 'Order By',
|
|
73
|
+
name: 'orderBy',
|
|
74
|
+
type: 'fixedCollection',
|
|
75
|
+
typeOptions: {
|
|
76
|
+
multipleValues: true,
|
|
77
|
+
},
|
|
78
|
+
default: {},
|
|
79
|
+
description: 'The list of properties by which to order the query results',
|
|
80
|
+
displayOptions: {
|
|
81
|
+
show: {
|
|
82
|
+
resource: [commons_1.LIME_QUERY_RESOURCE],
|
|
83
|
+
operation: ['query'],
|
|
84
|
+
},
|
|
85
|
+
},
|
|
86
|
+
options: [
|
|
87
|
+
{
|
|
88
|
+
name: 'orderByFields',
|
|
89
|
+
displayName: 'Order By Fields',
|
|
90
|
+
values: [
|
|
91
|
+
{
|
|
92
|
+
displayName: 'Property Name',
|
|
93
|
+
name: 'propertyName',
|
|
94
|
+
type: 'string',
|
|
95
|
+
description: 'Name of the property to order by',
|
|
96
|
+
default: '',
|
|
97
|
+
required: true,
|
|
98
|
+
},
|
|
99
|
+
{
|
|
100
|
+
displayName: 'Sort Direction',
|
|
101
|
+
name: 'sortDirection',
|
|
102
|
+
type: 'options',
|
|
103
|
+
default: 'ASC',
|
|
104
|
+
description: 'Ordering direction',
|
|
105
|
+
options: [
|
|
106
|
+
{ name: 'ASC', value: 'ASC' },
|
|
107
|
+
{ name: 'DESC', value: 'DESC' },
|
|
108
|
+
],
|
|
109
|
+
},
|
|
110
|
+
],
|
|
111
|
+
},
|
|
112
|
+
],
|
|
113
|
+
},
|
|
114
|
+
{
|
|
115
|
+
displayName: 'Offset',
|
|
116
|
+
name: 'offset',
|
|
117
|
+
type: 'number',
|
|
118
|
+
default: null,
|
|
119
|
+
description: 'The offset from which to start returning records. This operation requires the `Order By` field to be set',
|
|
120
|
+
displayOptions: {
|
|
121
|
+
show: {
|
|
122
|
+
resource: [commons_1.LIME_QUERY_RESOURCE],
|
|
123
|
+
operation: ['query'],
|
|
124
|
+
},
|
|
125
|
+
},
|
|
126
|
+
},
|
|
127
|
+
{
|
|
128
|
+
displayName: 'Active Object',
|
|
129
|
+
name: 'activeObject',
|
|
130
|
+
type: 'fixedCollection',
|
|
131
|
+
default: {},
|
|
132
|
+
description: "A dict with keys 'limetype' and 'id' representing the active object in the context of the query",
|
|
133
|
+
displayOptions: {
|
|
134
|
+
show: {
|
|
135
|
+
resource: [commons_1.LIME_QUERY_RESOURCE],
|
|
136
|
+
operation: ['query'],
|
|
137
|
+
},
|
|
138
|
+
},
|
|
139
|
+
options: [
|
|
140
|
+
{
|
|
141
|
+
name: 'activeObjectFields',
|
|
142
|
+
displayName: 'Active Object Fields',
|
|
143
|
+
values: [
|
|
144
|
+
{
|
|
145
|
+
displayName: 'Lime Type',
|
|
146
|
+
name: 'limetype',
|
|
147
|
+
type: 'options',
|
|
148
|
+
description: 'Name of the limetype',
|
|
149
|
+
default: '',
|
|
150
|
+
typeOptions: {
|
|
151
|
+
loadOptionsMethod: 'getLimeTypes',
|
|
152
|
+
},
|
|
153
|
+
required: true,
|
|
154
|
+
},
|
|
155
|
+
{
|
|
156
|
+
displayName: 'Lime Object ID',
|
|
157
|
+
name: 'id',
|
|
158
|
+
type: 'number',
|
|
159
|
+
default: 0,
|
|
160
|
+
description: 'ID representing the object in the context of the query',
|
|
161
|
+
required: true,
|
|
162
|
+
},
|
|
163
|
+
],
|
|
164
|
+
},
|
|
165
|
+
],
|
|
166
|
+
},
|
|
167
|
+
];
|
|
168
|
+
async function execute(i) {
|
|
169
|
+
const limeType = this.getNodeParameter('limeType', i);
|
|
170
|
+
const responseFormat = this.getNodeParameter('responseFormat', i);
|
|
171
|
+
const filter = this.getNodeParameter('filter', i);
|
|
172
|
+
const limit = this.getNodeParameter('limit', i);
|
|
173
|
+
const offset = this.getNodeParameter('offset', i);
|
|
174
|
+
const orderByCollection = this.getNodeParameter('orderBy', i);
|
|
175
|
+
const activeObjectCollection = this.getNodeParameter('activeObject', i);
|
|
176
|
+
const orderBy = orderByCollection.orderByFields &&
|
|
177
|
+
orderByCollection.orderByFields.map((field) => ({
|
|
178
|
+
[field.propertyName]: field.sortDirection,
|
|
179
|
+
}));
|
|
180
|
+
const q = JSON.stringify({
|
|
181
|
+
limetype: limeType,
|
|
182
|
+
responseFormat: JSON.parse(responseFormat),
|
|
183
|
+
filter: JSON.parse(filter),
|
|
184
|
+
limit: limit,
|
|
185
|
+
offset: offset,
|
|
186
|
+
orderBy: orderBy,
|
|
187
|
+
});
|
|
188
|
+
const activeObject = JSON.stringify(activeObjectCollection.activeObjectFields);
|
|
189
|
+
return (0, transport_1.queryLimeObjects)(this, q, activeObject);
|
|
190
|
+
}
|
|
191
|
+
//# sourceMappingURL=query.operation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"query.operation.js","sourceRoot":"","sources":["../../../../../../nodes/lime-crm/resources/limeQuery/operations/query.operation.ts"],"names":[],"mappings":";;;AA0LA,0BAmCC;AA3ND,kDAAsD;AACtD,8CAAuD;AAE1C,QAAA,WAAW,GAAG;IACvB,IAAI,EAAE,OAAO;IACb,KAAK,EAAE,OAAO;IACd,WAAW,EAAE,mCAAmC;IAChD,MAAM,EAAE,eAAe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AAC;IAE5B,MAAM,OAAO,GACT,iBAAiB,CAAC,aAAa;QAC/B,iBAAiB,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC;YAC5C,CAAC,KAAK,CAAC,YAAY,CAAC,EAAE,KAAK,CAAC,aAAa;SAC5C,CAAC,CAAC,CAAC;IAER,MAAM,CAAC,GAAG,IAAI,CAAC,SAAS,CAAC;QACrB,QAAQ,EAAE,QAAQ;QAClB,cAAc,EAAE,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC;QAC1C,MAAM,EAAE,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC;QAC1B,KAAK,EAAE,KAAK;QACZ,MAAM,EAAE,MAAM;QACd,OAAO,EAAE,OAAO;KACnB,CAAC,CAAC;IAEH,MAAM,YAAY,GAAG,IAAI,CAAC,SAAS,CAC/B,sBAAsB,CAAC,kBAAkB,CAC5C,CAAC;IAEF,OAAO,IAAA,4BAAgB,EAAC,IAAI,EAAE,CAAC,EAAE,YAAY,CAAC,CAAC;AACnD,CAAC"}
|
|
@@ -8,13 +8,13 @@ export declare function limeTypeOperations(this: IExecuteFunctions, { operation,
|
|
|
8
8
|
error: string;
|
|
9
9
|
status?: number;
|
|
10
10
|
metadata?: Record<string, unknown>;
|
|
11
|
-
} | {
|
|
12
|
-
success: true;
|
|
13
|
-
data: import("../../commons").LimeTypeProperty[];
|
|
14
11
|
} | {
|
|
15
12
|
success: true;
|
|
16
13
|
data: import("../../commons").LimeType[];
|
|
17
14
|
} | {
|
|
18
15
|
success: true;
|
|
19
16
|
data: import("../../commons").LimeType;
|
|
17
|
+
} | {
|
|
18
|
+
success: true;
|
|
19
|
+
data: import("../../commons").LimeTypeProperty[];
|
|
20
20
|
} | null>;
|
|
@@ -2,4 +2,5 @@ export { getSubscription, deleteSubscription, createSubscription, listSubscripti
|
|
|
2
2
|
export { getLimeTypesFromApi, getProperties } from './limetypes';
|
|
3
3
|
export { createLimeObject, deleteLimeObject, updateLimeObject, getLimeObject, fetchManyLimeObjects, } from './limeobjects';
|
|
4
4
|
export { startCreateOrUpdateObjectsTask } from './erpConnector';
|
|
5
|
+
export { queryLimeObjects } from './limeQuery';
|
|
5
6
|
export { callLimeApi } from './commons';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.callLimeApi = exports.startCreateOrUpdateObjectsTask = exports.fetchManyLimeObjects = exports.getLimeObject = exports.updateLimeObject = exports.deleteLimeObject = exports.createLimeObject = exports.getProperties = exports.getLimeTypesFromApi = exports.listSubscriptionsWithExistingData = exports.createSubscription = exports.deleteSubscription = exports.getSubscription = void 0;
|
|
3
|
+
exports.callLimeApi = exports.queryLimeObjects = exports.startCreateOrUpdateObjectsTask = exports.fetchManyLimeObjects = exports.getLimeObject = exports.updateLimeObject = exports.deleteLimeObject = exports.createLimeObject = exports.getProperties = exports.getLimeTypesFromApi = exports.listSubscriptionsWithExistingData = exports.createSubscription = exports.deleteSubscription = exports.getSubscription = void 0;
|
|
4
4
|
var webhooks_1 = require("./webhooks");
|
|
5
5
|
Object.defineProperty(exports, "getSubscription", { enumerable: true, get: function () { return webhooks_1.getSubscription; } });
|
|
6
6
|
Object.defineProperty(exports, "deleteSubscription", { enumerable: true, get: function () { return webhooks_1.deleteSubscription; } });
|
|
@@ -17,6 +17,8 @@ Object.defineProperty(exports, "getLimeObject", { enumerable: true, get: functio
|
|
|
17
17
|
Object.defineProperty(exports, "fetchManyLimeObjects", { enumerable: true, get: function () { return limeobjects_1.fetchManyLimeObjects; } });
|
|
18
18
|
var erpConnector_1 = require("./erpConnector");
|
|
19
19
|
Object.defineProperty(exports, "startCreateOrUpdateObjectsTask", { enumerable: true, get: function () { return erpConnector_1.startCreateOrUpdateObjectsTask; } });
|
|
20
|
+
var limeQuery_1 = require("./limeQuery");
|
|
21
|
+
Object.defineProperty(exports, "queryLimeObjects", { enumerable: true, get: function () { return limeQuery_1.queryLimeObjects; } });
|
|
20
22
|
var commons_1 = require("./commons");
|
|
21
23
|
Object.defineProperty(exports, "callLimeApi", { enumerable: true, get: function () { return commons_1.callLimeApi; } });
|
|
22
24
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../nodes/lime-crm/transport/index.ts"],"names":[],"mappings":";;;AAAA,uCAKoB;AAJhB,2GAAA,eAAe,OAAA;AACf,8GAAA,kBAAkB,OAAA;AAClB,8GAAA,kBAAkB,OAAA;AAClB,6HAAA,iCAAiC,OAAA;AAErC,yCAAiE;AAAxD,gHAAA,mBAAmB,OAAA;AAAE,0GAAA,aAAa,OAAA;AAE3C,6CAMuB;AALnB,+GAAA,gBAAgB,OAAA;AAChB,+GAAA,gBAAgB,OAAA;AAChB,+GAAA,gBAAgB,OAAA;AAChB,4GAAA,aAAa,OAAA;AACb,mHAAA,oBAAoB,OAAA;AAExB,+CAAgE;AAAvD,8HAAA,8BAA8B,OAAA;AACvC,qCAAwC;AAA/B,sGAAA,WAAW,OAAA"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../nodes/lime-crm/transport/index.ts"],"names":[],"mappings":";;;AAAA,uCAKoB;AAJhB,2GAAA,eAAe,OAAA;AACf,8GAAA,kBAAkB,OAAA;AAClB,8GAAA,kBAAkB,OAAA;AAClB,6HAAA,iCAAiC,OAAA;AAErC,yCAAiE;AAAxD,gHAAA,mBAAmB,OAAA;AAAE,0GAAA,aAAa,OAAA;AAE3C,6CAMuB;AALnB,+GAAA,gBAAgB,OAAA;AAChB,+GAAA,gBAAgB,OAAA;AAChB,+GAAA,gBAAgB,OAAA;AAChB,4GAAA,aAAa,OAAA;AACb,mHAAA,oBAAoB,OAAA;AAExB,+CAAgE;AAAvD,8HAAA,8BAA8B,OAAA;AACvC,yCAA+C;AAAtC,6GAAA,gBAAgB,OAAA;AACzB,qCAAwC;AAA/B,sGAAA,WAAW,OAAA"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { IAllExecuteFunctions } from 'n8n-workflow';
|
|
2
|
+
import { NodeResponse } from '../../nodeResponse';
|
|
3
|
+
interface IncludedProperties {
|
|
4
|
+
[key: string]: IncludedProperties | string | number | boolean | null;
|
|
5
|
+
}
|
|
6
|
+
export interface QueryResponse {
|
|
7
|
+
objects: IncludedProperties[];
|
|
8
|
+
}
|
|
9
|
+
export declare function queryLimeObjects(nodeContext: IAllExecuteFunctions, q: string, activeObject: string): Promise<NodeResponse<QueryResponse>>;
|
|
10
|
+
export {};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.queryLimeObjects = queryLimeObjects;
|
|
4
|
+
const commons_1 = require("./commons");
|
|
5
|
+
const LIME_QUERY_URL = '/api/v1/query/';
|
|
6
|
+
async function queryLimeObjects(nodeContext, q, activeObject) {
|
|
7
|
+
const queryParameters = {
|
|
8
|
+
q: q,
|
|
9
|
+
activeObject: activeObject,
|
|
10
|
+
};
|
|
11
|
+
return await (0, commons_1.callLimeApi)(nodeContext, 'GET', LIME_QUERY_URL, {
|
|
12
|
+
qs: queryParameters,
|
|
13
|
+
});
|
|
14
|
+
}
|
|
15
|
+
//# sourceMappingURL=limeQuery.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"limeQuery.js","sourceRoot":"","sources":["../../../../nodes/lime-crm/transport/limeQuery.ts"],"names":[],"mappings":";;AAcA,4CAaC;AAzBD,uCAAwC;AAExC,MAAM,cAAc,GAAG,gBAAgB,CAAC;AAUjC,KAAK,UAAU,gBAAgB,CAClC,WAAiC,EACjC,CAAS,EACT,YAAoB;IAEpB,MAAM,eAAe,GAAG;QACpB,CAAC,EAAE,CAAC;QACJ,YAAY,EAAE,YAAY;KAC7B,CAAC;IAEF,OAAO,MAAM,IAAA,qBAAW,EAAC,WAAW,EAAE,KAAK,EAAE,cAAc,EAAE;QACzD,EAAE,EAAE,eAAe;KACtB,CAAC,CAAC;AACP,CAAC"}
|