@probo/n8n-nodes-probo 0.0.1
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/dist/credentials/ProboApi.credentials.d.ts +10 -0
- package/dist/credentials/ProboApi.credentials.js +50 -0
- package/dist/credentials/ProboApi.credentials.js.map +1 -0
- package/dist/icons/probo-light.svg +24 -0
- package/dist/icons/probo.svg +23 -0
- package/dist/nodes/Probo/GenericFunctions.d.ts +3 -0
- package/dist/nodes/Probo/GenericFunctions.js +69 -0
- package/dist/nodes/Probo/GenericFunctions.js.map +1 -0
- package/dist/nodes/Probo/Probo.node.d.ts +8 -0
- package/dist/nodes/Probo/Probo.node.js +113 -0
- package/dist/nodes/Probo/Probo.node.js.map +1 -0
- package/dist/nodes/Probo/Probo.node.json +19 -0
- package/dist/nodes/Probo/actions/asset/create.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/asset/create.operation.js +207 -0
- package/dist/nodes/Probo/actions/asset/create.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/asset/delete.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/asset/delete.operation.js +37 -0
- package/dist/nodes/Probo/actions/asset/delete.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/asset/get.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/asset/get.operation.js +97 -0
- package/dist/nodes/Probo/actions/asset/get.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/asset/getAll.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/asset/getAll.operation.js +140 -0
- package/dist/nodes/Probo/actions/asset/getAll.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/asset/index.d.ts +8 -0
- package/dist/nodes/Probo/actions/asset/index.js +98 -0
- package/dist/nodes/Probo/actions/asset/index.js.map +1 -0
- package/dist/nodes/Probo/actions/asset/update.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/asset/update.operation.js +204 -0
- package/dist/nodes/Probo/actions/asset/update.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/control/create.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/control/create.operation.js +141 -0
- package/dist/nodes/Probo/actions/control/create.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/control/delete.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/control/delete.operation.js +37 -0
- package/dist/nodes/Probo/actions/control/delete.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/control/get.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/control/get.operation.js +49 -0
- package/dist/nodes/Probo/actions/control/get.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/control/getAll.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/control/getAll.operation.js +92 -0
- package/dist/nodes/Probo/actions/control/getAll.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/control/index.d.ts +8 -0
- package/dist/nodes/Probo/actions/control/index.js +98 -0
- package/dist/nodes/Probo/actions/control/index.js.map +1 -0
- package/dist/nodes/Probo/actions/control/update.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/control/update.operation.js +137 -0
- package/dist/nodes/Probo/actions/control/update.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/datum/create.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/datum/create.operation.js +181 -0
- package/dist/nodes/Probo/actions/datum/create.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/datum/delete.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/datum/delete.operation.js +37 -0
- package/dist/nodes/Probo/actions/datum/delete.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/datum/get.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/datum/get.operation.js +95 -0
- package/dist/nodes/Probo/actions/datum/get.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/datum/getAll.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/datum/getAll.operation.js +138 -0
- package/dist/nodes/Probo/actions/datum/getAll.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/datum/index.d.ts +8 -0
- package/dist/nodes/Probo/actions/datum/index.js +98 -0
- package/dist/nodes/Probo/actions/datum/index.js.map +1 -0
- package/dist/nodes/Probo/actions/datum/update.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/datum/update.operation.js +178 -0
- package/dist/nodes/Probo/actions/datum/update.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/execute/execute.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/execute/execute.operation.js +63 -0
- package/dist/nodes/Probo/actions/execute/execute.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/execute/index.d.ts +4 -0
- package/dist/nodes/Probo/actions/execute/index.js +62 -0
- package/dist/nodes/Probo/actions/execute/index.js.map +1 -0
- package/dist/nodes/Probo/actions/framework/create.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/framework/create.operation.js +81 -0
- package/dist/nodes/Probo/actions/framework/create.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/framework/delete.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/framework/delete.operation.js +37 -0
- package/dist/nodes/Probo/actions/framework/delete.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/framework/get.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/framework/get.operation.js +46 -0
- package/dist/nodes/Probo/actions/framework/get.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/framework/getAll.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/framework/getAll.operation.js +89 -0
- package/dist/nodes/Probo/actions/framework/getAll.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/framework/index.d.ts +8 -0
- package/dist/nodes/Probo/actions/framework/index.js +98 -0
- package/dist/nodes/Probo/actions/framework/index.js.map +1 -0
- package/dist/nodes/Probo/actions/framework/update.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/framework/update.operation.js +76 -0
- package/dist/nodes/Probo/actions/framework/update.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/index.d.ts +13 -0
- package/dist/nodes/Probo/actions/index.js +83 -0
- package/dist/nodes/Probo/actions/index.js.map +1 -0
- package/dist/nodes/Probo/actions/measure/create.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/measure/create.operation.js +99 -0
- package/dist/nodes/Probo/actions/measure/create.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/measure/delete.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/measure/delete.operation.js +37 -0
- package/dist/nodes/Probo/actions/measure/delete.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/measure/get.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/measure/get.operation.js +48 -0
- package/dist/nodes/Probo/actions/measure/get.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/measure/getAll.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/measure/getAll.operation.js +91 -0
- package/dist/nodes/Probo/actions/measure/getAll.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/measure/index.d.ts +8 -0
- package/dist/nodes/Probo/actions/measure/index.js +98 -0
- package/dist/nodes/Probo/actions/measure/index.js.map +1 -0
- package/dist/nodes/Probo/actions/measure/update.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/measure/update.operation.js +128 -0
- package/dist/nodes/Probo/actions/measure/update.operation.js.map +1 -0
- package/dist/package.json +63 -0
- package/dist/tsconfig.tsbuildinfo +1 -0
- package/package.json +63 -0
|
@@ -0,0 +1,178 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.description = void 0;
|
|
4
|
+
exports.execute = execute;
|
|
5
|
+
const GenericFunctions_1 = require("../../GenericFunctions");
|
|
6
|
+
exports.description = [
|
|
7
|
+
{
|
|
8
|
+
displayName: 'Datum ID',
|
|
9
|
+
name: 'id',
|
|
10
|
+
type: 'string',
|
|
11
|
+
displayOptions: {
|
|
12
|
+
show: {
|
|
13
|
+
resource: ['datum'],
|
|
14
|
+
operation: ['update'],
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
default: '',
|
|
18
|
+
description: 'The ID of the datum to update',
|
|
19
|
+
required: true,
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
displayName: 'Name',
|
|
23
|
+
name: 'name',
|
|
24
|
+
type: 'string',
|
|
25
|
+
displayOptions: {
|
|
26
|
+
show: {
|
|
27
|
+
resource: ['datum'],
|
|
28
|
+
operation: ['update'],
|
|
29
|
+
},
|
|
30
|
+
},
|
|
31
|
+
default: '',
|
|
32
|
+
description: 'The name of the datum',
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
displayName: 'Data Classification',
|
|
36
|
+
name: 'dataClassification',
|
|
37
|
+
type: 'options',
|
|
38
|
+
displayOptions: {
|
|
39
|
+
show: {
|
|
40
|
+
resource: ['datum'],
|
|
41
|
+
operation: ['update'],
|
|
42
|
+
},
|
|
43
|
+
},
|
|
44
|
+
options: [
|
|
45
|
+
{
|
|
46
|
+
name: 'Public',
|
|
47
|
+
value: 'PUBLIC',
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
name: 'Internal',
|
|
51
|
+
value: 'INTERNAL',
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
name: 'Confidential',
|
|
55
|
+
value: 'CONFIDENTIAL',
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
name: 'Secret',
|
|
59
|
+
value: 'SECRET',
|
|
60
|
+
},
|
|
61
|
+
],
|
|
62
|
+
default: 'PUBLIC',
|
|
63
|
+
description: 'The classification of the data',
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
displayName: 'Owner ID',
|
|
67
|
+
name: 'ownerId',
|
|
68
|
+
type: 'string',
|
|
69
|
+
displayOptions: {
|
|
70
|
+
show: {
|
|
71
|
+
resource: ['datum'],
|
|
72
|
+
operation: ['update'],
|
|
73
|
+
},
|
|
74
|
+
},
|
|
75
|
+
default: '',
|
|
76
|
+
description: 'The ID of the owner (People)',
|
|
77
|
+
},
|
|
78
|
+
{
|
|
79
|
+
displayName: 'Vendor IDs',
|
|
80
|
+
name: 'vendorIds',
|
|
81
|
+
type: 'string',
|
|
82
|
+
displayOptions: {
|
|
83
|
+
show: {
|
|
84
|
+
resource: ['datum'],
|
|
85
|
+
operation: ['update'],
|
|
86
|
+
},
|
|
87
|
+
},
|
|
88
|
+
default: '',
|
|
89
|
+
description: 'Comma-separated list of vendor IDs',
|
|
90
|
+
},
|
|
91
|
+
{
|
|
92
|
+
displayName: 'Options',
|
|
93
|
+
name: 'options',
|
|
94
|
+
type: 'collection',
|
|
95
|
+
placeholder: 'Add Option',
|
|
96
|
+
default: {},
|
|
97
|
+
displayOptions: {
|
|
98
|
+
show: {
|
|
99
|
+
resource: ['datum'],
|
|
100
|
+
operation: ['update'],
|
|
101
|
+
},
|
|
102
|
+
},
|
|
103
|
+
options: [
|
|
104
|
+
{
|
|
105
|
+
displayName: 'Include Owner',
|
|
106
|
+
name: 'includeOwner',
|
|
107
|
+
type: 'boolean',
|
|
108
|
+
default: false,
|
|
109
|
+
description: 'Whether to include owner details in the response',
|
|
110
|
+
},
|
|
111
|
+
{
|
|
112
|
+
displayName: 'Include Vendors',
|
|
113
|
+
name: 'includeVendors',
|
|
114
|
+
type: 'boolean',
|
|
115
|
+
default: false,
|
|
116
|
+
description: 'Whether to include vendors in the response',
|
|
117
|
+
},
|
|
118
|
+
],
|
|
119
|
+
},
|
|
120
|
+
];
|
|
121
|
+
async function execute(itemIndex) {
|
|
122
|
+
const id = this.getNodeParameter('id', itemIndex);
|
|
123
|
+
const name = this.getNodeParameter('name', itemIndex, '');
|
|
124
|
+
const dataClassification = this.getNodeParameter('dataClassification', itemIndex, '');
|
|
125
|
+
const ownerId = this.getNodeParameter('ownerId', itemIndex, '');
|
|
126
|
+
const vendorIdsStr = this.getNodeParameter('vendorIds', itemIndex, '');
|
|
127
|
+
const options = this.getNodeParameter('options', itemIndex, {});
|
|
128
|
+
const ownerFragment = options.includeOwner
|
|
129
|
+
? `owner {
|
|
130
|
+
id
|
|
131
|
+
fullName
|
|
132
|
+
primaryEmailAddress
|
|
133
|
+
}`
|
|
134
|
+
: '';
|
|
135
|
+
const vendorsFragment = options.includeVendors
|
|
136
|
+
? `vendors(first: 100) {
|
|
137
|
+
edges {
|
|
138
|
+
node {
|
|
139
|
+
id
|
|
140
|
+
name
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
}`
|
|
144
|
+
: '';
|
|
145
|
+
const query = `
|
|
146
|
+
mutation UpdateDatum($input: UpdateDatumInput!) {
|
|
147
|
+
updateDatum(input: $input) {
|
|
148
|
+
datum {
|
|
149
|
+
id
|
|
150
|
+
name
|
|
151
|
+
dataClassification
|
|
152
|
+
${ownerFragment}
|
|
153
|
+
${vendorsFragment}
|
|
154
|
+
createdAt
|
|
155
|
+
updatedAt
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
`;
|
|
160
|
+
const input = { id };
|
|
161
|
+
if (name)
|
|
162
|
+
input.name = name;
|
|
163
|
+
if (dataClassification)
|
|
164
|
+
input.dataClassification = dataClassification;
|
|
165
|
+
if (ownerId)
|
|
166
|
+
input.ownerId = ownerId;
|
|
167
|
+
if (vendorIdsStr) {
|
|
168
|
+
const vendorIds = vendorIdsStr.split(',').map((vid) => vid.trim()).filter(Boolean);
|
|
169
|
+
if (vendorIds.length > 0)
|
|
170
|
+
input.vendorIds = vendorIds;
|
|
171
|
+
}
|
|
172
|
+
const responseData = await GenericFunctions_1.proboApiRequest.call(this, query, { input });
|
|
173
|
+
return {
|
|
174
|
+
json: responseData,
|
|
175
|
+
pairedItem: { item: itemIndex },
|
|
176
|
+
};
|
|
177
|
+
}
|
|
178
|
+
//# sourceMappingURL=update.operation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"update.operation.js","sourceRoot":"","sources":["../../../../../nodes/Probo/actions/datum/update.operation.ts"],"names":[],"mappings":";;;AAuHA,0BAgEC;AAtLD,6DAAyD;AAE5C,QAAA,WAAW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,IAAI,EAAE,SAAS,EAAE;KAC/B,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.description = void 0;
|
|
4
|
+
exports.execute = execute;
|
|
5
|
+
const GenericFunctions_1 = require("../../GenericFunctions");
|
|
6
|
+
exports.description = [
|
|
7
|
+
{
|
|
8
|
+
displayName: 'Query',
|
|
9
|
+
name: 'query',
|
|
10
|
+
type: 'string',
|
|
11
|
+
typeOptions: {
|
|
12
|
+
rows: 5,
|
|
13
|
+
},
|
|
14
|
+
displayOptions: {
|
|
15
|
+
show: {
|
|
16
|
+
resource: ['execute'],
|
|
17
|
+
},
|
|
18
|
+
},
|
|
19
|
+
default: '',
|
|
20
|
+
description: 'The complete GraphQL operation including operation name and variable declarations (e.g., "query GetUser($userId: ID!) { node(ID: $userId) { ID } }" or "mutation UpdateUser($input: UpdateUserInput!) { updateUser(input: $input) { ID } }")',
|
|
21
|
+
required: true,
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
displayName: 'Variables',
|
|
25
|
+
name: 'variables',
|
|
26
|
+
type: 'json',
|
|
27
|
+
displayOptions: {
|
|
28
|
+
show: {
|
|
29
|
+
resource: ['execute'],
|
|
30
|
+
},
|
|
31
|
+
},
|
|
32
|
+
default: '{}',
|
|
33
|
+
description: 'GraphQL variables as JSON object',
|
|
34
|
+
},
|
|
35
|
+
];
|
|
36
|
+
async function execute(itemIndex) {
|
|
37
|
+
const query = this.getNodeParameter('query', itemIndex);
|
|
38
|
+
const variablesParam = this.getNodeParameter('variables', itemIndex);
|
|
39
|
+
const trimmedQuery = query.trim();
|
|
40
|
+
if (!trimmedQuery) {
|
|
41
|
+
throw new Error('GraphQL query cannot be empty');
|
|
42
|
+
}
|
|
43
|
+
const operationMatch = trimmedQuery.match(/^\s*(query|mutation|subscription)\s+(\w+)/i);
|
|
44
|
+
if (!operationMatch) {
|
|
45
|
+
throw new Error('GraphQL operation must start with "query", "mutation", or "subscription" followed by an operation name (e.g., "query GetUser { ... }" or "mutation UpdateUser { ... }")');
|
|
46
|
+
}
|
|
47
|
+
let variables = {};
|
|
48
|
+
if (variablesParam) {
|
|
49
|
+
try {
|
|
50
|
+
variables =
|
|
51
|
+
typeof variablesParam === 'string' ? JSON.parse(variablesParam) : variablesParam;
|
|
52
|
+
}
|
|
53
|
+
catch (error) {
|
|
54
|
+
throw new Error(`Invalid JSON in Variables: ${error instanceof Error ? error.message : String(error)}`);
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
const responseData = await GenericFunctions_1.proboApiRequest.call(this, query, variables);
|
|
58
|
+
return {
|
|
59
|
+
json: responseData,
|
|
60
|
+
pairedItem: { item: itemIndex },
|
|
61
|
+
};
|
|
62
|
+
}
|
|
63
|
+
//# sourceMappingURL=execute.operation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"execute.operation.js","sourceRoot":"","sources":["../../../../../nodes/Probo/actions/execute/execute.operation.ts"],"names":[],"mappings":";;;AAkCA,0BAqCC;AAtED,6DAAyD;AAE5C,QAAA,WAAW,GAAsB;IAC7C;QACC,WAAW,EAAE,OAAO;QACpB,IAAI,EAAE,OAAO;QACb,IAAI,EAAE,QAAQ;QACd,WAAW,EAAE;YACZ,IAAI,EAAE,CAAC;SACP;QACD,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,SAAS,CAAC;aACrB;SACD;QACD,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,8OAA8O;QAC3P,QAAQ,EAAE,IAAI;KACd;IACD;QACC,WAAW,EAAE,WAAW;QACxB,IAAI,EAAE,WAAW;QACjB,IAAI,EAAE,MAAM;QACZ,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,SAAS,CAAC;aACrB;SACD;QACD,OAAO,EAAE,IAAI;QACb,WAAW,EAAE,kCAAkC;KAC/C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(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.execute = exports.description = void 0;
|
|
37
|
+
const executeOp = __importStar(require("./execute.operation"));
|
|
38
|
+
exports.execute = executeOp;
|
|
39
|
+
exports.description = [
|
|
40
|
+
{
|
|
41
|
+
displayName: 'Operation',
|
|
42
|
+
name: 'operation',
|
|
43
|
+
type: 'options',
|
|
44
|
+
noDataExpression: true,
|
|
45
|
+
displayOptions: {
|
|
46
|
+
show: {
|
|
47
|
+
resource: ['execute'],
|
|
48
|
+
},
|
|
49
|
+
},
|
|
50
|
+
options: [
|
|
51
|
+
{
|
|
52
|
+
name: 'Execute',
|
|
53
|
+
value: 'execute',
|
|
54
|
+
description: 'Execute a GraphQL query or mutation',
|
|
55
|
+
action: 'Execute graphql',
|
|
56
|
+
},
|
|
57
|
+
],
|
|
58
|
+
default: 'execute',
|
|
59
|
+
},
|
|
60
|
+
...executeOp.description,
|
|
61
|
+
];
|
|
62
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../nodes/Probo/actions/execute/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,+DAAiD;AA0B3B,4BAAO;AAxBhB,QAAA,WAAW,GAAsB;IAC7C;QACC,WAAW,EAAE,WAAW;QACxB,IAAI,EAAE,WAAW;QACjB,IAAI,EAAE,SAAS;QACf,gBAAgB,EAAE,IAAI;QACtB,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,SAAS,CAAC;aACrB;SACD;QACD,OAAO,EAAE;YACR;gBACC,IAAI,EAAE,SAAS;gBACf,KAAK,EAAE,SAAS;gBAChB,WAAW,EAAE,qCAAqC;gBAClD,MAAM,EAAE,iBAAiB;aACzB;SACD;QACD,OAAO,EAAE,SAAS;KAClB;IACD,GAAG,SAAS,CAAC,WAAW;CACxB,CAAC"}
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.description = void 0;
|
|
4
|
+
exports.execute = execute;
|
|
5
|
+
const GenericFunctions_1 = require("../../GenericFunctions");
|
|
6
|
+
exports.description = [
|
|
7
|
+
{
|
|
8
|
+
displayName: 'Organization ID',
|
|
9
|
+
name: 'organizationId',
|
|
10
|
+
type: 'string',
|
|
11
|
+
displayOptions: {
|
|
12
|
+
show: {
|
|
13
|
+
resource: ['framework'],
|
|
14
|
+
operation: ['create'],
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
default: '',
|
|
18
|
+
description: 'The ID of the organization',
|
|
19
|
+
required: true,
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
displayName: 'Name',
|
|
23
|
+
name: 'name',
|
|
24
|
+
type: 'string',
|
|
25
|
+
displayOptions: {
|
|
26
|
+
show: {
|
|
27
|
+
resource: ['framework'],
|
|
28
|
+
operation: ['create'],
|
|
29
|
+
},
|
|
30
|
+
},
|
|
31
|
+
default: '',
|
|
32
|
+
description: 'The name of the framework',
|
|
33
|
+
required: true,
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
displayName: 'Description',
|
|
37
|
+
name: 'description',
|
|
38
|
+
type: 'string',
|
|
39
|
+
displayOptions: {
|
|
40
|
+
show: {
|
|
41
|
+
resource: ['framework'],
|
|
42
|
+
operation: ['create'],
|
|
43
|
+
},
|
|
44
|
+
},
|
|
45
|
+
default: '',
|
|
46
|
+
description: 'The description of the framework',
|
|
47
|
+
},
|
|
48
|
+
];
|
|
49
|
+
async function execute(itemIndex) {
|
|
50
|
+
const organizationId = this.getNodeParameter('organizationId', itemIndex);
|
|
51
|
+
const name = this.getNodeParameter('name', itemIndex);
|
|
52
|
+
const description = this.getNodeParameter('description', itemIndex, '');
|
|
53
|
+
const query = `
|
|
54
|
+
mutation CreateFramework($input: CreateFrameworkInput!) {
|
|
55
|
+
createFramework(input: $input) {
|
|
56
|
+
frameworkEdge {
|
|
57
|
+
node {
|
|
58
|
+
id
|
|
59
|
+
name
|
|
60
|
+
description
|
|
61
|
+
createdAt
|
|
62
|
+
updatedAt
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
`;
|
|
68
|
+
const variables = {
|
|
69
|
+
input: {
|
|
70
|
+
organizationId,
|
|
71
|
+
name,
|
|
72
|
+
...(description && { description }),
|
|
73
|
+
},
|
|
74
|
+
};
|
|
75
|
+
const responseData = await GenericFunctions_1.proboApiRequest.call(this, query, variables);
|
|
76
|
+
return {
|
|
77
|
+
json: responseData,
|
|
78
|
+
pairedItem: { item: itemIndex },
|
|
79
|
+
};
|
|
80
|
+
}
|
|
81
|
+
//# sourceMappingURL=create.operation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create.operation.js","sourceRoot":"","sources":["../../../../../nodes/Probo/actions/framework/create.operation.ts"],"names":[],"mappings":";;;AA+CA,0BAsCC;AApFD,6DAAyD;AAE5C,QAAA,WAAW,GAAsB;IAC7C;QACC,WAAW,EAAE,iBAAiB;QAC9B,IAAI,EAAE,gBAAgB;QACtB,IAAI,EAAE,QAAQ;QACd,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,WAAW,CAAC;gBACvB,SAAS,EAAE,CAAC,QAAQ,CAAC;aACrB;SACD;QACD,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,4BAA4B;QACzC,QAAQ,EAAE,IAAI;KACd;IACD;QACC,WAAW,EAAE,MAAM;QACnB,IAAI,EAAE,MAAM;QACZ,IAAI,EAAE,QAAQ;QACd,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,WAAW,CAAC;gBACvB,SAAS,EAAE,CAAC,QAAQ,CAAC;aACrB;SACD;QACD,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,2BAA2B;QACxC,QAAQ,EAAE,IAAI;KACd;IACD;QACC,WAAW,EAAE,aAAa;QAC1B,IAAI,EAAE,aAAa;QACnB,IAAI,EAAE,QAAQ;QACd,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,WAAW,CAAC;gBACvB,SAAS,EAAE,CAAC,QAAQ,CAAC;aACrB;SACD;QACD,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,kCAAkC;KAC/C;CACD,CAAC;AAEK,KAAK,UAAU,OAAO,CAE5B,SAAiB;IAEjB,MAAM,cAAc,GAAG,IAAI,CAAC,gBAAgB,CAAC,gBAAgB,EAAE,SAAS,CAAW,CAAC;IACpF,MAAM,IAAI,GAAG,IAAI,CAAC,gBAAgB,CAAC,MAAM,EAAE,SAAS,CAAW,CAAC;IAChE,MAAM,WAAW,GAAG,IAAI,CAAC,gBAAgB,CAAC,aAAa,EAAE,SAAS,EAAE,EAAE,CAAW,CAAC;IAElF,MAAM,KAAK,GAAG;;;;;;;;;;;;;;EAcb,CAAC;IAEF,MAAM,SAAS,GAAG;QACjB,KAAK,EAAE;YACN,cAAc;YACd,IAAI;YACJ,GAAG,CAAC,WAAW,IAAI,EAAE,WAAW,EAAE,CAAC;SACnC;KACD,CAAC;IAEF,MAAM,YAAY,GAAG,MAAM,kCAAe,CAAC,IAAI,CAAC,IAAI,EAAE,KAAK,EAAE,SAAS,CAAC,CAAC;IAExE,OAAO;QACN,IAAI,EAAE,YAAY;QAClB,UAAU,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE;KAC/B,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.description = void 0;
|
|
4
|
+
exports.execute = execute;
|
|
5
|
+
const GenericFunctions_1 = require("../../GenericFunctions");
|
|
6
|
+
exports.description = [
|
|
7
|
+
{
|
|
8
|
+
displayName: 'Framework ID',
|
|
9
|
+
name: 'frameworkId',
|
|
10
|
+
type: 'string',
|
|
11
|
+
displayOptions: {
|
|
12
|
+
show: {
|
|
13
|
+
resource: ['framework'],
|
|
14
|
+
operation: ['delete'],
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
default: '',
|
|
18
|
+
description: 'The ID of the framework to delete',
|
|
19
|
+
required: true,
|
|
20
|
+
},
|
|
21
|
+
];
|
|
22
|
+
async function execute(itemIndex) {
|
|
23
|
+
const frameworkId = this.getNodeParameter('frameworkId', itemIndex);
|
|
24
|
+
const query = `
|
|
25
|
+
mutation DeleteFramework($input: DeleteFrameworkInput!) {
|
|
26
|
+
deleteFramework(input: $input) {
|
|
27
|
+
deletedFrameworkId
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
`;
|
|
31
|
+
const responseData = await GenericFunctions_1.proboApiRequest.call(this, query, { input: { frameworkId } });
|
|
32
|
+
return {
|
|
33
|
+
json: responseData,
|
|
34
|
+
pairedItem: { item: itemIndex },
|
|
35
|
+
};
|
|
36
|
+
}
|
|
37
|
+
//# sourceMappingURL=delete.operation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"delete.operation.js","sourceRoot":"","sources":["../../../../../nodes/Probo/actions/framework/delete.operation.ts"],"names":[],"mappings":";;;AAoBA,0BAoBC;AAvCD,6DAAyD;AAE5C,QAAA,WAAW,GAAsB;IAC7C;QACC,WAAW,EAAE,cAAc;QAC3B,IAAI,EAAE,aAAa;QACnB,IAAI,EAAE,QAAQ;QACd,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,WAAW,CAAC;gBACvB,SAAS,EAAE,CAAC,QAAQ,CAAC;aACrB;SACD;QACD,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,mCAAmC;QAChD,QAAQ,EAAE,IAAI;KACd;CACD,CAAC;AAEK,KAAK,UAAU,OAAO,CAE5B,SAAiB;IAEjB,MAAM,WAAW,GAAG,IAAI,CAAC,gBAAgB,CAAC,aAAa,EAAE,SAAS,CAAW,CAAC;IAE9E,MAAM,KAAK,GAAG;;;;;;EAMb,CAAC;IAEF,MAAM,YAAY,GAAG,MAAM,kCAAe,CAAC,IAAI,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE,KAAK,EAAE,EAAE,WAAW,EAAE,EAAE,CAAC,CAAC;IAEzF,OAAO;QACN,IAAI,EAAE,YAAY;QAClB,UAAU,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE;KAC/B,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.description = void 0;
|
|
4
|
+
exports.execute = execute;
|
|
5
|
+
const GenericFunctions_1 = require("../../GenericFunctions");
|
|
6
|
+
exports.description = [
|
|
7
|
+
{
|
|
8
|
+
displayName: 'Framework ID',
|
|
9
|
+
name: 'frameworkId',
|
|
10
|
+
type: 'string',
|
|
11
|
+
displayOptions: {
|
|
12
|
+
show: {
|
|
13
|
+
resource: ['framework'],
|
|
14
|
+
operation: ['get'],
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
default: '',
|
|
18
|
+
description: 'The ID of the framework',
|
|
19
|
+
required: true,
|
|
20
|
+
},
|
|
21
|
+
];
|
|
22
|
+
async function execute(itemIndex) {
|
|
23
|
+
const frameworkId = this.getNodeParameter('frameworkId', itemIndex);
|
|
24
|
+
const query = `
|
|
25
|
+
query GetFramework($frameworkId: ID!) {
|
|
26
|
+
node(id: $frameworkId) {
|
|
27
|
+
... on Framework {
|
|
28
|
+
id
|
|
29
|
+
name
|
|
30
|
+
description
|
|
31
|
+
createdAt
|
|
32
|
+
updatedAt
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
`;
|
|
37
|
+
const variables = {
|
|
38
|
+
frameworkId,
|
|
39
|
+
};
|
|
40
|
+
const responseData = await GenericFunctions_1.proboApiRequest.call(this, query, variables);
|
|
41
|
+
return {
|
|
42
|
+
json: responseData,
|
|
43
|
+
pairedItem: { item: itemIndex },
|
|
44
|
+
};
|
|
45
|
+
}
|
|
46
|
+
//# sourceMappingURL=get.operation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get.operation.js","sourceRoot":"","sources":["../../../../../nodes/Probo/actions/framework/get.operation.ts"],"names":[],"mappings":";;;AAoBA,0BA8BC;AAjDD,6DAAyD;AAE5C,QAAA,WAAW,GAAsB;IAC7C;QACC,WAAW,EAAE,cAAc;QAC3B,IAAI,EAAE,aAAa;QACnB,IAAI,EAAE,QAAQ;QACd,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,WAAW,CAAC;gBACvB,SAAS,EAAE,CAAC,KAAK,CAAC;aAClB;SACD;QACD,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,yBAAyB;QACtC,QAAQ,EAAE,IAAI;KACd;CACD,CAAC;AAEK,KAAK,UAAU,OAAO,CAE5B,SAAiB;IAEjB,MAAM,WAAW,GAAG,IAAI,CAAC,gBAAgB,CAAC,aAAa,EAAE,SAAS,CAAW,CAAC;IAE9E,MAAM,KAAK,GAAG;;;;;;;;;;;;EAYb,CAAC;IAEF,MAAM,SAAS,GAAG;QACjB,WAAW;KACX,CAAC;IAEF,MAAM,YAAY,GAAG,MAAM,kCAAe,CAAC,IAAI,CAAC,IAAI,EAAE,KAAK,EAAE,SAAS,CAAC,CAAC;IAExE,OAAO;QACN,IAAI,EAAE,YAAY;QAClB,UAAU,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE;KAC/B,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.description = void 0;
|
|
4
|
+
exports.execute = execute;
|
|
5
|
+
const GenericFunctions_1 = require("../../GenericFunctions");
|
|
6
|
+
exports.description = [
|
|
7
|
+
{
|
|
8
|
+
displayName: 'Organization ID',
|
|
9
|
+
name: 'organizationId',
|
|
10
|
+
type: 'string',
|
|
11
|
+
displayOptions: {
|
|
12
|
+
show: {
|
|
13
|
+
resource: ['framework'],
|
|
14
|
+
operation: ['getAll'],
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
default: '',
|
|
18
|
+
description: 'The ID of the organization',
|
|
19
|
+
required: true,
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
displayName: 'Return All',
|
|
23
|
+
name: 'returnAll',
|
|
24
|
+
type: 'boolean',
|
|
25
|
+
displayOptions: {
|
|
26
|
+
show: {
|
|
27
|
+
resource: ['framework'],
|
|
28
|
+
operation: ['getAll'],
|
|
29
|
+
},
|
|
30
|
+
},
|
|
31
|
+
default: false,
|
|
32
|
+
description: 'Whether to return all results or only up to a given limit',
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
displayName: 'Limit',
|
|
36
|
+
name: 'limit',
|
|
37
|
+
type: 'number',
|
|
38
|
+
displayOptions: {
|
|
39
|
+
show: {
|
|
40
|
+
resource: ['framework'],
|
|
41
|
+
operation: ['getAll'],
|
|
42
|
+
returnAll: [false],
|
|
43
|
+
},
|
|
44
|
+
},
|
|
45
|
+
typeOptions: {
|
|
46
|
+
minValue: 1,
|
|
47
|
+
},
|
|
48
|
+
default: 50,
|
|
49
|
+
description: 'Max number of results to return',
|
|
50
|
+
},
|
|
51
|
+
];
|
|
52
|
+
async function execute(itemIndex) {
|
|
53
|
+
const organizationId = this.getNodeParameter('organizationId', itemIndex);
|
|
54
|
+
const returnAll = this.getNodeParameter('returnAll', itemIndex);
|
|
55
|
+
const limit = this.getNodeParameter('limit', itemIndex, 50);
|
|
56
|
+
const query = `
|
|
57
|
+
query GetFrameworks($organizationId: ID!, $first: Int, $after: CursorKey) {
|
|
58
|
+
node(id: $organizationId) {
|
|
59
|
+
... on Organization {
|
|
60
|
+
frameworks(first: $first, after: $after) {
|
|
61
|
+
edges {
|
|
62
|
+
node {
|
|
63
|
+
id
|
|
64
|
+
name
|
|
65
|
+
description
|
|
66
|
+
createdAt
|
|
67
|
+
updatedAt
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
pageInfo {
|
|
71
|
+
hasNextPage
|
|
72
|
+
endCursor
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
`;
|
|
79
|
+
const frameworks = await GenericFunctions_1.proboApiRequestAllItems.call(this, query, { organizationId }, (response) => {
|
|
80
|
+
const data = response === null || response === void 0 ? void 0 : response.data;
|
|
81
|
+
const node = data === null || data === void 0 ? void 0 : data.node;
|
|
82
|
+
return node === null || node === void 0 ? void 0 : node.frameworks;
|
|
83
|
+
}, returnAll, limit);
|
|
84
|
+
return {
|
|
85
|
+
json: { frameworks },
|
|
86
|
+
pairedItem: { item: itemIndex },
|
|
87
|
+
};
|
|
88
|
+
}
|
|
89
|
+
//# sourceMappingURL=getAll.operation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"getAll.operation.js","sourceRoot":"","sources":["../../../../../nodes/Probo/actions/framework/getAll.operation.ts"],"names":[],"mappings":";;;AAkDA,0BAiDC;AAlGD,6DAAiE;AAEpD,QAAA,WAAW,GAAsB;IAC7C;QACC,WAAW,EAAE,iBAAiB;QAC9B,IAAI,EAAE,gBAAgB;QACtB,IAAI,EAAE,QAAQ;QACd,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,WAAW,CAAC;gBACvB,SAAS,EAAE,CAAC,QAAQ,CAAC;aACrB;SACD;QACD,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,4BAA4B;QACzC,QAAQ,EAAE,IAAI;KACd;IACD;QACC,WAAW,EAAE,YAAY;QACzB,IAAI,EAAE,WAAW;QACjB,IAAI,EAAE,SAAS;QACf,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,WAAW,CAAC;gBACvB,SAAS,EAAE,CAAC,QAAQ,CAAC;aACrB;SACD;QACD,OAAO,EAAE,KAAK;QACd,WAAW,EAAE,2DAA2D;KACxE;IACD;QACC,WAAW,EAAE,OAAO;QACpB,IAAI,EAAE,OAAO;QACb,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
|
2
|
+
import * as createOp from './create.operation';
|
|
3
|
+
import * as updateOp from './update.operation';
|
|
4
|
+
import * as deleteOp from './delete.operation';
|
|
5
|
+
import * as getOp from './get.operation';
|
|
6
|
+
import * as getAllOp from './getAll.operation';
|
|
7
|
+
export declare const description: INodeProperties[];
|
|
8
|
+
export { createOp as create, updateOp as update, deleteOp as delete, getOp as get, getAllOp as getAll };
|