n8n-nodes-qlik-cloud 1.0.1 → 1.0.3
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/icons/icons/qlik.svg +1 -0
- package/dist/nodes/QlikCloud/QlikCloud.node.js +84 -3
- package/dist/nodes/QlikCloud/resources/assistants/index.d.ts +7 -0
- package/dist/nodes/QlikCloud/resources/assistants/index.js +401 -8
- package/package.json +4 -3
- package/specifications/assistants.json +4531 -0
- package/specifications/assistants.json:MSOAVINFO +0 -0
- package/specifications/assistants.json:Zone.Identifier +0 -0
- package/src/icons/qlik.svg +1 -0
- package/src/nodes/QlikCloud/QlikCloud.node.ts +123 -3
- package/src/nodes/QlikCloud/resources/assistants/index.ts +407 -7
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" id="Layer_1" viewBox="0 0 71.39 29.74"><defs><style>.cls-2{stroke-width:0;fill:#54565a}</style></defs><path d="M70.47 27.52c.05-.07.07-.15.07-.24s-.02-.17-.07-.24-.1-.11-.16-.14a.38.38 0 0 0-.17-.04h-.66v1.31h.29v-.44h.29l.23.44h.32l-.27-.51a.47.47 0 0 0 .15-.13Zm-.71-.45h.27s.07.01.12.04c.04.03.07.08.07.16s-.02.14-.07.18c-.05.04-.09.06-.13.06h-.27v-.44Z" class="cls-2"/><path d="M71.28 26.97c-.07-.17-.17-.32-.31-.45-.13-.13-.28-.23-.45-.31s-.36-.11-.55-.11-.38.04-.55.11-.32.18-.45.31-.23.28-.3.45c-.07.17-.11.36-.11.55s.04.38.11.55c.07.17.17.32.3.45.13.13.28.23.45.31s.36.11.55.11.38-.04.55-.11.32-.18.45-.31.23-.28.31-.45c.07-.17.11-.36.11-.55s-.04-.38-.11-.55Zm-.37 1.1c-.1.16-.23.29-.39.39-.16.1-.34.15-.54.15s-.38-.05-.54-.15c-.16-.1-.29-.23-.39-.39-.1-.16-.15-.34-.15-.54s.05-.38.15-.54c.1-.16.23-.29.39-.39.16-.1.34-.15.54-.15s.38.05.54.15c.16.1.29.23.39.39.1.16.15.34.15.54s-.05.38-.15.54ZM34.9.65h2.96v28.32H34.9zM42.95 9.19h2.95v19.78h-2.95z" class="cls-2"/><circle cx="44.45" cy="2.67" r="2.02" class="cls-2"/><path d="M66.62 9.19h-4.11l-8.52 7.46-.02-16h-2.94v28.32h2.94v-9.14l8.75 9.14h4.1L56.39 18.39l10.23-9.2zM14.87 26.69c-6.53 0-11.82-5.29-11.82-11.82 0-2.77.96-5.32 2.55-7.34L3.44 5.34A14.922 14.922 0 0 0 0 14.87c0 8.21 6.66 14.87 14.87 14.87 3.56 0 6.83-1.25 9.39-3.34l-2.16-2.19c-2 1.55-4.5 2.47-7.23 2.47Z" class="cls-2"/><path fill="#009445" stroke-width="0" d="m26.31 24.34.17-.17a14.83 14.83 0 0 0 3.26-9.3C29.74 6.66 23.08 0 14.87 0c-3.54 0-6.79 1.24-9.34 3.3-.74.6-1.41 1.26-2.03 1.98-.02.02-.03.04-.05.06l2.16 2.19s.04-.05.06-.07c.59-.74 1.27-1.4 2.02-1.97a11.74 11.74 0 0 1 7.18-2.44c6.53 0 11.82 5.29 11.82 11.82 0 2.75-.94 5.29-2.52 7.3-.57.73-1.23 1.39-1.95 1.96l-.12.09 2.16 2.19 2.54 2.57h4.1l-4.59-4.64Z"/></svg>
|
|
@@ -92,6 +92,15 @@ async function handleAssistantsResource(operation, context) {
|
|
|
92
92
|
if (options.limit) {
|
|
93
93
|
qs.limit = options.limit;
|
|
94
94
|
}
|
|
95
|
+
if (options.next) {
|
|
96
|
+
qs.next = options.next;
|
|
97
|
+
}
|
|
98
|
+
if (options.prev) {
|
|
99
|
+
qs.prev = options.prev;
|
|
100
|
+
}
|
|
101
|
+
if (options.sort) {
|
|
102
|
+
qs.sort = options.sort;
|
|
103
|
+
}
|
|
95
104
|
return await transport_1.qlikApiRequest.call(context, 'GET', '/api/v1/assistants', undefined, qs);
|
|
96
105
|
}
|
|
97
106
|
if (operation === 'get') {
|
|
@@ -100,13 +109,33 @@ async function handleAssistantsResource(operation, context) {
|
|
|
100
109
|
}
|
|
101
110
|
if (operation === 'create') {
|
|
102
111
|
const name = context.getNodeParameter('name', 0);
|
|
112
|
+
const title = context.getNodeParameter('title', 0);
|
|
113
|
+
const description = context.getNodeParameter('description', 0);
|
|
114
|
+
const spaceId = context.getNodeParameter('spaceId', 0);
|
|
103
115
|
const options = context.getNodeParameter('options', 0);
|
|
104
|
-
const body = { name };
|
|
105
|
-
if (options.
|
|
106
|
-
body.
|
|
116
|
+
const body = { name, title, description, spaceId };
|
|
117
|
+
if (options.tags) {
|
|
118
|
+
body.tags = options.tags.split(',').map((tag) => tag.trim());
|
|
119
|
+
}
|
|
120
|
+
if (options.knowledgeBases) {
|
|
121
|
+
body.knowledgeBases = options.knowledgeBases.split(',').map((kb) => kb.trim());
|
|
122
|
+
}
|
|
123
|
+
if (options.welcomeMessage) {
|
|
124
|
+
body.welcomeMessage = options.welcomeMessage;
|
|
125
|
+
}
|
|
126
|
+
if (options.customProperties) {
|
|
127
|
+
body.customProperties = typeof options.customProperties === 'string'
|
|
128
|
+
? JSON.parse(options.customProperties)
|
|
129
|
+
: options.customProperties;
|
|
107
130
|
}
|
|
108
131
|
return await transport_1.qlikApiRequest.call(context, 'POST', '/api/v1/assistants', body);
|
|
109
132
|
}
|
|
133
|
+
if (operation === 'update') {
|
|
134
|
+
const assistantId = context.getNodeParameter('assistantId', 0);
|
|
135
|
+
const body = context.getNodeParameter('body', 0);
|
|
136
|
+
const patchOps = typeof body === 'string' ? JSON.parse(body) : body;
|
|
137
|
+
return await transport_1.qlikApiRequest.call(context, 'PATCH', `/api/v1/assistants/${assistantId}`, patchOps);
|
|
138
|
+
}
|
|
110
139
|
if (operation === 'search') {
|
|
111
140
|
const assistantId = context.getNodeParameter('assistantId', 0);
|
|
112
141
|
const query = context.getNodeParameter('query', 0);
|
|
@@ -120,6 +149,58 @@ async function handleAssistantsResource(operation, context) {
|
|
|
120
149
|
}
|
|
121
150
|
return await transport_1.qlikApiRequest.call(context, 'POST', `/api/v1/assistants/${assistantId}/actions/search`, body);
|
|
122
151
|
}
|
|
152
|
+
if (operation === 'getFeedback') {
|
|
153
|
+
const assistantId = context.getNodeParameter('assistantId', 0);
|
|
154
|
+
return await transport_1.qlikApiRequest.call(context, 'GET', `/api/v1/assistants/${assistantId}/feedback`);
|
|
155
|
+
}
|
|
156
|
+
if (operation === 'bulkSearchSources') {
|
|
157
|
+
const assistantId = context.getNodeParameter('assistantId', 0);
|
|
158
|
+
const chunkIds = context.getNodeParameter('chunkIds', 0);
|
|
159
|
+
const body = typeof chunkIds === 'string' ? JSON.parse(chunkIds) : chunkIds;
|
|
160
|
+
return await transport_1.qlikApiRequest.call(context, 'POST', `/api/v1/assistants/${assistantId}/sources/plaintexts`, { chunkIds: body });
|
|
161
|
+
}
|
|
162
|
+
if (operation === 'listStarters') {
|
|
163
|
+
const assistantId = context.getNodeParameter('assistantId', 0);
|
|
164
|
+
const options = context.getNodeParameter('options', 0);
|
|
165
|
+
const qs = {};
|
|
166
|
+
if (options.limit) {
|
|
167
|
+
qs.limit = options.limit;
|
|
168
|
+
}
|
|
169
|
+
return await transport_1.qlikApiRequest.call(context, 'GET', `/api/v1/assistants/${assistantId}/starters`, undefined, qs);
|
|
170
|
+
}
|
|
171
|
+
if (operation === 'createStarter') {
|
|
172
|
+
const assistantId = context.getNodeParameter('assistantId', 0);
|
|
173
|
+
const question = context.getNodeParameter('question', 0);
|
|
174
|
+
const options = context.getNodeParameter('options', 0);
|
|
175
|
+
const body = { question };
|
|
176
|
+
if (options.followups) {
|
|
177
|
+
body.followups = typeof options.followups === 'string'
|
|
178
|
+
? JSON.parse(options.followups)
|
|
179
|
+
: options.followups;
|
|
180
|
+
}
|
|
181
|
+
if (options.additionalContext) {
|
|
182
|
+
body.additionalContext = options.additionalContext;
|
|
183
|
+
}
|
|
184
|
+
return await transport_1.qlikApiRequest.call(context, 'POST', `/api/v1/assistants/${assistantId}/starters`, body);
|
|
185
|
+
}
|
|
186
|
+
if (operation === 'listThreads') {
|
|
187
|
+
const assistantId = context.getNodeParameter('assistantId', 0);
|
|
188
|
+
const options = context.getNodeParameter('options', 0);
|
|
189
|
+
const qs = {};
|
|
190
|
+
if (options.limit) {
|
|
191
|
+
qs.limit = options.limit;
|
|
192
|
+
}
|
|
193
|
+
if (options.filter) {
|
|
194
|
+
qs.filter = options.filter;
|
|
195
|
+
}
|
|
196
|
+
return await transport_1.qlikApiRequest.call(context, 'GET', `/api/v1/assistants/${assistantId}/threads`, undefined, qs);
|
|
197
|
+
}
|
|
198
|
+
if (operation === 'createThread') {
|
|
199
|
+
const assistantId = context.getNodeParameter('assistantId', 0);
|
|
200
|
+
const name = context.getNodeParameter('name', 0);
|
|
201
|
+
const body = { name };
|
|
202
|
+
return await transport_1.qlikApiRequest.call(context, 'POST', `/api/v1/assistants/${assistantId}/threads`, body);
|
|
203
|
+
}
|
|
123
204
|
if (operation === 'delete') {
|
|
124
205
|
const assistantId = context.getNodeParameter('assistantId', 0);
|
|
125
206
|
await transport_1.qlikApiRequest.call(context, 'DELETE', `/api/v1/assistants/${assistantId}`);
|
|
@@ -2,6 +2,13 @@ import type { INodeProperties } from 'n8n-workflow';
|
|
|
2
2
|
export declare const assistantsGetAllDescription: INodeProperties[];
|
|
3
3
|
export declare const assistantsGetDescription: INodeProperties[];
|
|
4
4
|
export declare const assistantsCreateDescription: INodeProperties[];
|
|
5
|
+
export declare const assistantsUpdateDescription: INodeProperties[];
|
|
5
6
|
export declare const assistantsSearchDescription: INodeProperties[];
|
|
7
|
+
export declare const assistantsGetFeedbackDescription: INodeProperties[];
|
|
8
|
+
export declare const assistantsBulkSearchSourcesDescription: INodeProperties[];
|
|
6
9
|
export declare const assistantsDeleteDescription: INodeProperties[];
|
|
10
|
+
export declare const assistantsListStartersDescription: INodeProperties[];
|
|
11
|
+
export declare const assistantsCreateStarterDescription: INodeProperties[];
|
|
12
|
+
export declare const assistantsListThreadsDescription: INodeProperties[];
|
|
13
|
+
export declare const assistantsCreateThreadDescription: INodeProperties[];
|
|
7
14
|
export declare const assistantDescription: INodeProperties[];
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.assistantDescription = exports.assistantsDeleteDescription = exports.assistantsSearchDescription = exports.assistantsCreateDescription = exports.assistantsGetDescription = exports.assistantsGetAllDescription = void 0;
|
|
3
|
+
exports.assistantDescription = exports.assistantsCreateThreadDescription = exports.assistantsListThreadsDescription = exports.assistantsCreateStarterDescription = exports.assistantsListStartersDescription = exports.assistantsDeleteDescription = exports.assistantsBulkSearchSourcesDescription = exports.assistantsGetFeedbackDescription = exports.assistantsSearchDescription = exports.assistantsUpdateDescription = exports.assistantsCreateDescription = exports.assistantsGetDescription = exports.assistantsGetAllDescription = void 0;
|
|
4
|
+
// Get All Assistants
|
|
4
5
|
exports.assistantsGetAllDescription = [
|
|
5
6
|
{
|
|
6
7
|
displayName: 'Options',
|
|
@@ -20,11 +21,33 @@ exports.assistantsGetAllDescription = [
|
|
|
20
21
|
name: 'limit',
|
|
21
22
|
type: 'number',
|
|
22
23
|
default: 50,
|
|
23
|
-
description: '
|
|
24
|
+
description: 'The number of assistants to get',
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
displayName: 'Next Page',
|
|
28
|
+
name: 'next',
|
|
29
|
+
type: 'string',
|
|
30
|
+
default: '',
|
|
31
|
+
description: 'Optional parameter to request the next page',
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
displayName: 'Previous Page',
|
|
35
|
+
name: 'prev',
|
|
36
|
+
type: 'string',
|
|
37
|
+
default: '',
|
|
38
|
+
description: 'Optional parameter to request the previous page',
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
displayName: 'Sort By',
|
|
42
|
+
name: 'sort',
|
|
43
|
+
type: 'string',
|
|
44
|
+
default: '',
|
|
45
|
+
description: 'Optional resource field name to sort on (e.g., name). Prefix with `-` for descending order',
|
|
24
46
|
},
|
|
25
47
|
],
|
|
26
48
|
},
|
|
27
49
|
];
|
|
50
|
+
// Get Single Assistant
|
|
28
51
|
exports.assistantsGetDescription = [
|
|
29
52
|
{
|
|
30
53
|
displayName: 'Assistant ID',
|
|
@@ -41,9 +64,10 @@ exports.assistantsGetDescription = [
|
|
|
41
64
|
description: 'The ID of the assistant to retrieve',
|
|
42
65
|
},
|
|
43
66
|
];
|
|
67
|
+
// Create Assistant
|
|
44
68
|
exports.assistantsCreateDescription = [
|
|
45
69
|
{
|
|
46
|
-
displayName: '
|
|
70
|
+
displayName: 'Name',
|
|
47
71
|
name: 'name',
|
|
48
72
|
type: 'string',
|
|
49
73
|
default: '',
|
|
@@ -54,7 +78,49 @@ exports.assistantsCreateDescription = [
|
|
|
54
78
|
operation: ['create'],
|
|
55
79
|
},
|
|
56
80
|
},
|
|
57
|
-
description: '
|
|
81
|
+
description: 'The name of the assistant',
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
displayName: 'Title',
|
|
85
|
+
name: 'title',
|
|
86
|
+
type: 'string',
|
|
87
|
+
default: '',
|
|
88
|
+
required: true,
|
|
89
|
+
displayOptions: {
|
|
90
|
+
show: {
|
|
91
|
+
resource: ['assistants'],
|
|
92
|
+
operation: ['create'],
|
|
93
|
+
},
|
|
94
|
+
},
|
|
95
|
+
description: 'The title of the assistant',
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
displayName: 'Description',
|
|
99
|
+
name: 'description',
|
|
100
|
+
type: 'string',
|
|
101
|
+
default: '',
|
|
102
|
+
required: true,
|
|
103
|
+
displayOptions: {
|
|
104
|
+
show: {
|
|
105
|
+
resource: ['assistants'],
|
|
106
|
+
operation: ['create'],
|
|
107
|
+
},
|
|
108
|
+
},
|
|
109
|
+
description: 'The description of the assistant',
|
|
110
|
+
},
|
|
111
|
+
{
|
|
112
|
+
displayName: 'Space ID',
|
|
113
|
+
name: 'spaceId',
|
|
114
|
+
type: 'string',
|
|
115
|
+
default: '',
|
|
116
|
+
required: true,
|
|
117
|
+
displayOptions: {
|
|
118
|
+
show: {
|
|
119
|
+
resource: ['assistants'],
|
|
120
|
+
operation: ['create'],
|
|
121
|
+
},
|
|
122
|
+
},
|
|
123
|
+
description: 'Unique identifier of the space to contain the assistant',
|
|
58
124
|
},
|
|
59
125
|
{
|
|
60
126
|
displayName: 'Options',
|
|
@@ -70,15 +136,68 @@ exports.assistantsCreateDescription = [
|
|
|
70
136
|
},
|
|
71
137
|
options: [
|
|
72
138
|
{
|
|
73
|
-
displayName: '
|
|
74
|
-
name: '
|
|
139
|
+
displayName: 'Tags',
|
|
140
|
+
name: 'tags',
|
|
141
|
+
type: 'string',
|
|
142
|
+
default: '',
|
|
143
|
+
description: 'Comma-separated list of tags for the assistant',
|
|
144
|
+
},
|
|
145
|
+
{
|
|
146
|
+
displayName: 'Knowledge Bases',
|
|
147
|
+
name: 'knowledgeBases',
|
|
75
148
|
type: 'string',
|
|
76
149
|
default: '',
|
|
77
|
-
description: '
|
|
150
|
+
description: 'Comma-separated list of knowledge base IDs',
|
|
151
|
+
},
|
|
152
|
+
{
|
|
153
|
+
displayName: 'Welcome Message',
|
|
154
|
+
name: 'welcomeMessage',
|
|
155
|
+
type: 'string',
|
|
156
|
+
default: '',
|
|
157
|
+
description: 'Initial message in the chat conversation',
|
|
158
|
+
},
|
|
159
|
+
{
|
|
160
|
+
displayName: 'Custom Properties (JSON)',
|
|
161
|
+
name: 'customProperties',
|
|
162
|
+
type: 'json',
|
|
163
|
+
default: '{}',
|
|
164
|
+
description: 'Freeform JSON to allow custom customization options',
|
|
78
165
|
},
|
|
79
166
|
],
|
|
80
167
|
},
|
|
81
168
|
];
|
|
169
|
+
// Update Assistant
|
|
170
|
+
exports.assistantsUpdateDescription = [
|
|
171
|
+
{
|
|
172
|
+
displayName: 'Assistant ID',
|
|
173
|
+
name: 'assistantId',
|
|
174
|
+
type: 'string',
|
|
175
|
+
default: '',
|
|
176
|
+
required: true,
|
|
177
|
+
displayOptions: {
|
|
178
|
+
show: {
|
|
179
|
+
resource: ['assistants'],
|
|
180
|
+
operation: ['update'],
|
|
181
|
+
},
|
|
182
|
+
},
|
|
183
|
+
description: 'The ID of the assistant to update',
|
|
184
|
+
},
|
|
185
|
+
{
|
|
186
|
+
displayName: 'JSON Patch Operations',
|
|
187
|
+
name: 'body',
|
|
188
|
+
type: 'json',
|
|
189
|
+
default: '[]',
|
|
190
|
+
required: true,
|
|
191
|
+
displayOptions: {
|
|
192
|
+
show: {
|
|
193
|
+
resource: ['assistants'],
|
|
194
|
+
operation: ['update'],
|
|
195
|
+
},
|
|
196
|
+
},
|
|
197
|
+
description: 'Array of JSON Patch operations to apply to the assistant',
|
|
198
|
+
},
|
|
199
|
+
];
|
|
200
|
+
// Search Assistant
|
|
82
201
|
exports.assistantsSearchDescription = [
|
|
83
202
|
{
|
|
84
203
|
displayName: 'Assistant ID',
|
|
@@ -150,6 +269,55 @@ exports.assistantsSearchDescription = [
|
|
|
150
269
|
],
|
|
151
270
|
},
|
|
152
271
|
];
|
|
272
|
+
// Get Feedback
|
|
273
|
+
exports.assistantsGetFeedbackDescription = [
|
|
274
|
+
{
|
|
275
|
+
displayName: 'Assistant ID',
|
|
276
|
+
name: 'assistantId',
|
|
277
|
+
type: 'string',
|
|
278
|
+
default: '',
|
|
279
|
+
required: true,
|
|
280
|
+
displayOptions: {
|
|
281
|
+
show: {
|
|
282
|
+
resource: ['assistants'],
|
|
283
|
+
operation: ['getFeedback'],
|
|
284
|
+
},
|
|
285
|
+
},
|
|
286
|
+
description: 'The ID of the assistant to get feedback for',
|
|
287
|
+
},
|
|
288
|
+
];
|
|
289
|
+
// Bulk Search Source Chunks
|
|
290
|
+
exports.assistantsBulkSearchSourcesDescription = [
|
|
291
|
+
{
|
|
292
|
+
displayName: 'Assistant ID',
|
|
293
|
+
name: 'assistantId',
|
|
294
|
+
type: 'string',
|
|
295
|
+
default: '',
|
|
296
|
+
required: true,
|
|
297
|
+
displayOptions: {
|
|
298
|
+
show: {
|
|
299
|
+
resource: ['assistants'],
|
|
300
|
+
operation: ['bulkSearchSources'],
|
|
301
|
+
},
|
|
302
|
+
},
|
|
303
|
+
description: 'The ID of the assistant to search sources for',
|
|
304
|
+
},
|
|
305
|
+
{
|
|
306
|
+
displayName: 'Chunk IDs',
|
|
307
|
+
name: 'chunkIds',
|
|
308
|
+
type: 'json',
|
|
309
|
+
default: '[]',
|
|
310
|
+
required: true,
|
|
311
|
+
displayOptions: {
|
|
312
|
+
show: {
|
|
313
|
+
resource: ['assistants'],
|
|
314
|
+
operation: ['bulkSearchSources'],
|
|
315
|
+
},
|
|
316
|
+
},
|
|
317
|
+
description: 'Array of chunk IDs to search for',
|
|
318
|
+
},
|
|
319
|
+
];
|
|
320
|
+
// Delete Assistant
|
|
153
321
|
exports.assistantsDeleteDescription = [
|
|
154
322
|
{
|
|
155
323
|
displayName: 'Assistant ID',
|
|
@@ -166,6 +334,182 @@ exports.assistantsDeleteDescription = [
|
|
|
166
334
|
description: 'The ID of the assistant to delete',
|
|
167
335
|
},
|
|
168
336
|
];
|
|
337
|
+
// List Starters
|
|
338
|
+
exports.assistantsListStartersDescription = [
|
|
339
|
+
{
|
|
340
|
+
displayName: 'Assistant ID',
|
|
341
|
+
name: 'assistantId',
|
|
342
|
+
type: 'string',
|
|
343
|
+
default: '',
|
|
344
|
+
required: true,
|
|
345
|
+
displayOptions: {
|
|
346
|
+
show: {
|
|
347
|
+
resource: ['assistants'],
|
|
348
|
+
operation: ['listStarters'],
|
|
349
|
+
},
|
|
350
|
+
},
|
|
351
|
+
description: 'The ID of the assistant',
|
|
352
|
+
},
|
|
353
|
+
{
|
|
354
|
+
displayName: 'Options',
|
|
355
|
+
name: 'options',
|
|
356
|
+
type: 'collection',
|
|
357
|
+
placeholder: 'Add Option',
|
|
358
|
+
default: {},
|
|
359
|
+
displayOptions: {
|
|
360
|
+
show: {
|
|
361
|
+
resource: ['assistants'],
|
|
362
|
+
operation: ['listStarters'],
|
|
363
|
+
},
|
|
364
|
+
},
|
|
365
|
+
options: [
|
|
366
|
+
{
|
|
367
|
+
displayName: 'Limit',
|
|
368
|
+
name: 'limit',
|
|
369
|
+
type: 'number',
|
|
370
|
+
default: 50,
|
|
371
|
+
description: 'The number of starters to get',
|
|
372
|
+
},
|
|
373
|
+
],
|
|
374
|
+
},
|
|
375
|
+
];
|
|
376
|
+
// Create Starter
|
|
377
|
+
exports.assistantsCreateStarterDescription = [
|
|
378
|
+
{
|
|
379
|
+
displayName: 'Assistant ID',
|
|
380
|
+
name: 'assistantId',
|
|
381
|
+
type: 'string',
|
|
382
|
+
default: '',
|
|
383
|
+
required: true,
|
|
384
|
+
displayOptions: {
|
|
385
|
+
show: {
|
|
386
|
+
resource: ['assistants'],
|
|
387
|
+
operation: ['createStarter'],
|
|
388
|
+
},
|
|
389
|
+
},
|
|
390
|
+
description: 'The ID of the assistant',
|
|
391
|
+
},
|
|
392
|
+
{
|
|
393
|
+
displayName: 'Question',
|
|
394
|
+
name: 'question',
|
|
395
|
+
type: 'string',
|
|
396
|
+
default: '',
|
|
397
|
+
required: true,
|
|
398
|
+
displayOptions: {
|
|
399
|
+
show: {
|
|
400
|
+
resource: ['assistants'],
|
|
401
|
+
operation: ['createStarter'],
|
|
402
|
+
},
|
|
403
|
+
},
|
|
404
|
+
description: 'Starter sample question',
|
|
405
|
+
},
|
|
406
|
+
{
|
|
407
|
+
displayName: 'Options',
|
|
408
|
+
name: 'options',
|
|
409
|
+
type: 'collection',
|
|
410
|
+
placeholder: 'Add Option',
|
|
411
|
+
default: {},
|
|
412
|
+
displayOptions: {
|
|
413
|
+
show: {
|
|
414
|
+
resource: ['assistants'],
|
|
415
|
+
operation: ['createStarter'],
|
|
416
|
+
},
|
|
417
|
+
},
|
|
418
|
+
options: [
|
|
419
|
+
{
|
|
420
|
+
displayName: 'Followups (JSON)',
|
|
421
|
+
name: 'followups',
|
|
422
|
+
type: 'json',
|
|
423
|
+
default: '[]',
|
|
424
|
+
description: 'List of followup questions',
|
|
425
|
+
},
|
|
426
|
+
{
|
|
427
|
+
displayName: 'Additional Context',
|
|
428
|
+
name: 'additionalContext',
|
|
429
|
+
type: 'string',
|
|
430
|
+
default: '',
|
|
431
|
+
description: 'Optional context for the question',
|
|
432
|
+
},
|
|
433
|
+
],
|
|
434
|
+
},
|
|
435
|
+
];
|
|
436
|
+
// List Threads
|
|
437
|
+
exports.assistantsListThreadsDescription = [
|
|
438
|
+
{
|
|
439
|
+
displayName: 'Assistant ID',
|
|
440
|
+
name: 'assistantId',
|
|
441
|
+
type: 'string',
|
|
442
|
+
default: '',
|
|
443
|
+
required: true,
|
|
444
|
+
displayOptions: {
|
|
445
|
+
show: {
|
|
446
|
+
resource: ['assistants'],
|
|
447
|
+
operation: ['listThreads'],
|
|
448
|
+
},
|
|
449
|
+
},
|
|
450
|
+
description: 'The ID of the assistant',
|
|
451
|
+
},
|
|
452
|
+
{
|
|
453
|
+
displayName: 'Options',
|
|
454
|
+
name: 'options',
|
|
455
|
+
type: 'collection',
|
|
456
|
+
placeholder: 'Add Option',
|
|
457
|
+
default: {},
|
|
458
|
+
displayOptions: {
|
|
459
|
+
show: {
|
|
460
|
+
resource: ['assistants'],
|
|
461
|
+
operation: ['listThreads'],
|
|
462
|
+
},
|
|
463
|
+
},
|
|
464
|
+
options: [
|
|
465
|
+
{
|
|
466
|
+
displayName: 'Limit',
|
|
467
|
+
name: 'limit',
|
|
468
|
+
type: 'number',
|
|
469
|
+
default: 50,
|
|
470
|
+
description: 'The number of threads to get',
|
|
471
|
+
},
|
|
472
|
+
{
|
|
473
|
+
displayName: 'Filter',
|
|
474
|
+
name: 'filter',
|
|
475
|
+
type: 'string',
|
|
476
|
+
default: '',
|
|
477
|
+
description: 'Optional parameter to filter threads',
|
|
478
|
+
},
|
|
479
|
+
],
|
|
480
|
+
},
|
|
481
|
+
];
|
|
482
|
+
// Create Thread
|
|
483
|
+
exports.assistantsCreateThreadDescription = [
|
|
484
|
+
{
|
|
485
|
+
displayName: 'Assistant ID',
|
|
486
|
+
name: 'assistantId',
|
|
487
|
+
type: 'string',
|
|
488
|
+
default: '',
|
|
489
|
+
required: true,
|
|
490
|
+
displayOptions: {
|
|
491
|
+
show: {
|
|
492
|
+
resource: ['assistants'],
|
|
493
|
+
operation: ['createThread'],
|
|
494
|
+
},
|
|
495
|
+
},
|
|
496
|
+
description: 'The ID of the assistant',
|
|
497
|
+
},
|
|
498
|
+
{
|
|
499
|
+
displayName: 'Thread Name',
|
|
500
|
+
name: 'name',
|
|
501
|
+
type: 'string',
|
|
502
|
+
default: '',
|
|
503
|
+
required: true,
|
|
504
|
+
displayOptions: {
|
|
505
|
+
show: {
|
|
506
|
+
resource: ['assistants'],
|
|
507
|
+
operation: ['createThread'],
|
|
508
|
+
},
|
|
509
|
+
},
|
|
510
|
+
description: 'The name of the thread',
|
|
511
|
+
},
|
|
512
|
+
];
|
|
169
513
|
exports.assistantDescription = [
|
|
170
514
|
{
|
|
171
515
|
displayName: 'Operation',
|
|
@@ -196,17 +540,59 @@ exports.assistantDescription = [
|
|
|
196
540
|
action: 'Create an assistant',
|
|
197
541
|
description: 'Create a new assistant',
|
|
198
542
|
},
|
|
543
|
+
{
|
|
544
|
+
name: 'Update',
|
|
545
|
+
value: 'update',
|
|
546
|
+
action: 'Update an assistant',
|
|
547
|
+
description: 'Update assistant properties',
|
|
548
|
+
},
|
|
199
549
|
{
|
|
200
550
|
name: 'Search',
|
|
201
551
|
value: 'search',
|
|
202
552
|
action: 'Search assistant sources',
|
|
203
553
|
description: 'Perform search in assistant sources',
|
|
204
554
|
},
|
|
555
|
+
{
|
|
556
|
+
name: 'Get Feedback',
|
|
557
|
+
value: 'getFeedback',
|
|
558
|
+
action: 'Get assistant feedback',
|
|
559
|
+
description: 'Retrieve feedback summary for the assistant',
|
|
560
|
+
},
|
|
561
|
+
{
|
|
562
|
+
name: 'Bulk Search Sources',
|
|
563
|
+
value: 'bulkSearchSources',
|
|
564
|
+
action: 'Bulk search source chunks',
|
|
565
|
+
description: 'Perform a bulk search for source chunks',
|
|
566
|
+
},
|
|
567
|
+
{
|
|
568
|
+
name: 'List Starters',
|
|
569
|
+
value: 'listStarters',
|
|
570
|
+
action: 'List assistant starters',
|
|
571
|
+
description: 'Retrieve list of starters for the assistant',
|
|
572
|
+
},
|
|
573
|
+
{
|
|
574
|
+
name: 'Create Starter',
|
|
575
|
+
value: 'createStarter',
|
|
576
|
+
action: 'Create an assistant starter',
|
|
577
|
+
description: 'Create a new starter for the assistant',
|
|
578
|
+
},
|
|
579
|
+
{
|
|
580
|
+
name: 'List Threads',
|
|
581
|
+
value: 'listThreads',
|
|
582
|
+
action: 'List assistant threads',
|
|
583
|
+
description: 'Retrieve list of threads for the assistant',
|
|
584
|
+
},
|
|
585
|
+
{
|
|
586
|
+
name: 'Create Thread',
|
|
587
|
+
value: 'createThread',
|
|
588
|
+
action: 'Create an assistant thread',
|
|
589
|
+
description: 'Create a new thread for the assistant',
|
|
590
|
+
},
|
|
205
591
|
{
|
|
206
592
|
name: 'Delete',
|
|
207
593
|
value: 'delete',
|
|
208
594
|
action: 'Delete an assistant',
|
|
209
|
-
description: 'Delete an assistant',
|
|
595
|
+
description: 'Delete an assistant and all its resources',
|
|
210
596
|
},
|
|
211
597
|
],
|
|
212
598
|
default: 'getAll',
|
|
@@ -214,6 +600,13 @@ exports.assistantDescription = [
|
|
|
214
600
|
...exports.assistantsGetAllDescription,
|
|
215
601
|
...exports.assistantsGetDescription,
|
|
216
602
|
...exports.assistantsCreateDescription,
|
|
603
|
+
...exports.assistantsUpdateDescription,
|
|
217
604
|
...exports.assistantsSearchDescription,
|
|
605
|
+
...exports.assistantsGetFeedbackDescription,
|
|
606
|
+
...exports.assistantsBulkSearchSourcesDescription,
|
|
607
|
+
...exports.assistantsListStartersDescription,
|
|
608
|
+
...exports.assistantsCreateStarterDescription,
|
|
609
|
+
...exports.assistantsListThreadsDescription,
|
|
610
|
+
...exports.assistantsCreateThreadDescription,
|
|
218
611
|
...exports.assistantsDeleteDescription,
|
|
219
612
|
];
|
package/package.json
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "n8n-nodes-qlik-cloud",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.3",
|
|
4
4
|
"description": "n8n node for Qlik Cloud REST APIs integration",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
7
7
|
"scripts": {
|
|
8
|
-
"build": "tsc",
|
|
8
|
+
"build": "tsc && npm run copy-assets",
|
|
9
|
+
"copy-assets": "cp -r src/icons dist/icons || true",
|
|
9
10
|
"dev": "tsc --watch",
|
|
10
11
|
"lint": "eslint src/",
|
|
11
12
|
"test": "jest"
|
|
@@ -26,7 +27,7 @@
|
|
|
26
27
|
"api",
|
|
27
28
|
"automation"
|
|
28
29
|
],
|
|
29
|
-
"author": "
|
|
30
|
+
"author": "Clever Anjos (cleveranjos@gmail.com)",
|
|
30
31
|
"license": "MIT",
|
|
31
32
|
"devDependencies": {
|
|
32
33
|
"@types/node": "^18.0.0",
|