@taistudio/n8n-nodes-planka 26.1.10 → 26.1.12
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.
|
@@ -0,0 +1,2743 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Planka = void 0;
|
|
4
|
+
const GenericFunctions_1 = require("./GenericFunctions");
|
|
5
|
+
class Planka {
|
|
6
|
+
constructor() {
|
|
7
|
+
this.description = {
|
|
8
|
+
displayName: 'Planka',
|
|
9
|
+
name: 'planka',
|
|
10
|
+
icon: 'file:planka.png',
|
|
11
|
+
group: ['transform'],
|
|
12
|
+
version: 1,
|
|
13
|
+
subtitle: '={{$parameter["operation"] + ": " + $parameter["resource"]}}',
|
|
14
|
+
description: 'Interact with Planka API',
|
|
15
|
+
defaults: {
|
|
16
|
+
name: 'Planka',
|
|
17
|
+
},
|
|
18
|
+
inputs: ['main'],
|
|
19
|
+
outputs: ['main'],
|
|
20
|
+
credentials: [
|
|
21
|
+
{
|
|
22
|
+
name: 'plankaApi',
|
|
23
|
+
required: true,
|
|
24
|
+
},
|
|
25
|
+
],
|
|
26
|
+
properties: [
|
|
27
|
+
{
|
|
28
|
+
displayName: 'Resource',
|
|
29
|
+
name: 'resource',
|
|
30
|
+
type: 'options',
|
|
31
|
+
noDataExpression: true,
|
|
32
|
+
options: [
|
|
33
|
+
{
|
|
34
|
+
name: '🏢 PROJECT',
|
|
35
|
+
value: 'project',
|
|
36
|
+
description: 'Complete project and administrator management',
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
name: '📋 BOARD',
|
|
40
|
+
value: 'board',
|
|
41
|
+
description: 'Management of boards, lists, tags, and members',
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
name: '📝 CARD',
|
|
45
|
+
value: 'card',
|
|
46
|
+
description: 'Management of cards, tasks, comments, and attachments',
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
name: '👤 USER',
|
|
50
|
+
value: 'user',
|
|
51
|
+
description: 'Complete system user management',
|
|
52
|
+
},
|
|
53
|
+
],
|
|
54
|
+
default: 'project',
|
|
55
|
+
description: 'Main resource to use',
|
|
56
|
+
},
|
|
57
|
+
// Operaciones para cada recurso principal
|
|
58
|
+
{
|
|
59
|
+
displayName: 'Operation',
|
|
60
|
+
name: 'operation',
|
|
61
|
+
type: 'options',
|
|
62
|
+
displayOptions: {
|
|
63
|
+
show: {
|
|
64
|
+
resource: [
|
|
65
|
+
'project',
|
|
66
|
+
],
|
|
67
|
+
},
|
|
68
|
+
},
|
|
69
|
+
options: [
|
|
70
|
+
{
|
|
71
|
+
name: '➕ Create Project',
|
|
72
|
+
value: 'createProject',
|
|
73
|
+
description: 'Create a new project in Planka',
|
|
74
|
+
action: 'Create a project',
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
name: '🔍 Get Project',
|
|
78
|
+
value: 'getProject',
|
|
79
|
+
description: 'Get details of a specific project by ID',
|
|
80
|
+
action: 'Get a project by ID',
|
|
81
|
+
},
|
|
82
|
+
{
|
|
83
|
+
name: '📋 Get All Projects',
|
|
84
|
+
value: 'getAllProjects',
|
|
85
|
+
description: 'Get a list of all available projects',
|
|
86
|
+
action: 'Get all projects',
|
|
87
|
+
},
|
|
88
|
+
{
|
|
89
|
+
name: '✏️ Update Project',
|
|
90
|
+
value: 'updateProject',
|
|
91
|
+
description: 'Update information for an existing project',
|
|
92
|
+
action: 'Update a project',
|
|
93
|
+
},
|
|
94
|
+
{
|
|
95
|
+
name: '🗑️ Delete Project',
|
|
96
|
+
value: 'deleteProject',
|
|
97
|
+
description: 'Permanently delete a project',
|
|
98
|
+
action: 'Delete a project',
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
name: '🖼️ Update Project Background',
|
|
102
|
+
value: 'updateProjectBackgroundImage',
|
|
103
|
+
description: 'Change the background image of a project',
|
|
104
|
+
action: 'Update project background image',
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
name: '👤 Add Manager to Project',
|
|
108
|
+
value: 'addProjectManager',
|
|
109
|
+
description: 'Add a user as project administrator',
|
|
110
|
+
action: 'Add a manager to a project',
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
name: '🚫 Remove Manager from Project',
|
|
114
|
+
value: 'deleteProjectManager',
|
|
115
|
+
description: 'Remove a project administrator',
|
|
116
|
+
action: 'Delete a project manager',
|
|
117
|
+
},
|
|
118
|
+
],
|
|
119
|
+
default: 'getAllProjects',
|
|
120
|
+
},
|
|
121
|
+
{
|
|
122
|
+
displayName: 'Operation',
|
|
123
|
+
name: 'operation',
|
|
124
|
+
type: 'options',
|
|
125
|
+
displayOptions: {
|
|
126
|
+
show: {
|
|
127
|
+
resource: [
|
|
128
|
+
'board',
|
|
129
|
+
],
|
|
130
|
+
},
|
|
131
|
+
},
|
|
132
|
+
options: [
|
|
133
|
+
{
|
|
134
|
+
name: '➕ Create Board',
|
|
135
|
+
value: 'createBoard',
|
|
136
|
+
description: 'Create a new board in a project',
|
|
137
|
+
action: 'Create a board',
|
|
138
|
+
},
|
|
139
|
+
{
|
|
140
|
+
name: '🔍 Get Board',
|
|
141
|
+
value: 'getBoard',
|
|
142
|
+
description: 'Get details of a specific board',
|
|
143
|
+
action: 'Get a board by ID',
|
|
144
|
+
},
|
|
145
|
+
{
|
|
146
|
+
name: '✏️ Update Board',
|
|
147
|
+
value: 'updateBoard',
|
|
148
|
+
description: 'Modify information on an existing dashboard',
|
|
149
|
+
action: 'Update a board',
|
|
150
|
+
},
|
|
151
|
+
{
|
|
152
|
+
name: '🗑️ Delete Board',
|
|
153
|
+
value: 'deleteBoard',
|
|
154
|
+
description: 'Permanently delete a board',
|
|
155
|
+
action: 'Delete a board',
|
|
156
|
+
},
|
|
157
|
+
{
|
|
158
|
+
name: '👤 Add Member to Board',
|
|
159
|
+
value: 'createBoardMembership',
|
|
160
|
+
description: 'Add a member to a board',
|
|
161
|
+
action: 'Add a member to a board',
|
|
162
|
+
},
|
|
163
|
+
{
|
|
164
|
+
name: '🔄 Update Board Membership',
|
|
165
|
+
value: 'updateBoardMembership',
|
|
166
|
+
description: "Update a member's permissions on the board",
|
|
167
|
+
action: 'Update a board membership',
|
|
168
|
+
},
|
|
169
|
+
{
|
|
170
|
+
name: '🚫 Remove Member from Board',
|
|
171
|
+
value: 'deleteBoardMembership',
|
|
172
|
+
description: 'Remove a board member',
|
|
173
|
+
action: 'Remove a member from a board',
|
|
174
|
+
},
|
|
175
|
+
{
|
|
176
|
+
name: '📃 Create Board List',
|
|
177
|
+
value: 'createBoardList',
|
|
178
|
+
description: 'Create a new list on the board',
|
|
179
|
+
action: 'Create a board list',
|
|
180
|
+
},
|
|
181
|
+
{
|
|
182
|
+
name: '✏️ Update Board List',
|
|
183
|
+
value: 'updateBoardList',
|
|
184
|
+
description: 'Modify an existing list on the board',
|
|
185
|
+
action: 'Update a board list',
|
|
186
|
+
},
|
|
187
|
+
{
|
|
188
|
+
name: '🗑️ Delete Board List',
|
|
189
|
+
value: 'deleteBoardList',
|
|
190
|
+
description: 'Permanently delete a list from the board',
|
|
191
|
+
action: 'Delete a board list',
|
|
192
|
+
},
|
|
193
|
+
{
|
|
194
|
+
name: '🔀 Sort Board List',
|
|
195
|
+
value: 'sortBoardList',
|
|
196
|
+
description: 'Sort cards within a list',
|
|
197
|
+
action: 'Sort cards in a board list',
|
|
198
|
+
},
|
|
199
|
+
{
|
|
200
|
+
name: '🏷️ Create Board Label',
|
|
201
|
+
value: 'createBoardLabel',
|
|
202
|
+
description: 'Create a new label on the board',
|
|
203
|
+
action: 'Create a board label',
|
|
204
|
+
},
|
|
205
|
+
{
|
|
206
|
+
name: '✏️ Update Board Label',
|
|
207
|
+
value: 'updateBoardLabel',
|
|
208
|
+
description: 'Modify an existing label on the board',
|
|
209
|
+
action: 'Update a board label',
|
|
210
|
+
},
|
|
211
|
+
{
|
|
212
|
+
name: '🗑️ Delete Board Label',
|
|
213
|
+
value: 'deleteBoardLabel',
|
|
214
|
+
description: 'Permanently delete a label from the board.',
|
|
215
|
+
action: 'Delete a board label',
|
|
216
|
+
},
|
|
217
|
+
],
|
|
218
|
+
default: 'createBoard',
|
|
219
|
+
},
|
|
220
|
+
{
|
|
221
|
+
displayName: 'Operation',
|
|
222
|
+
name: 'operation',
|
|
223
|
+
type: 'options',
|
|
224
|
+
displayOptions: {
|
|
225
|
+
show: {
|
|
226
|
+
resource: [
|
|
227
|
+
'card',
|
|
228
|
+
],
|
|
229
|
+
},
|
|
230
|
+
},
|
|
231
|
+
options: [
|
|
232
|
+
{
|
|
233
|
+
name: '➕ Create Card',
|
|
234
|
+
value: 'createCard',
|
|
235
|
+
description: 'Create a new card in a list',
|
|
236
|
+
action: 'Create a card',
|
|
237
|
+
},
|
|
238
|
+
{
|
|
239
|
+
name: '🔍 Get Card',
|
|
240
|
+
value: 'getCard',
|
|
241
|
+
description: 'Get details of a specific card',
|
|
242
|
+
action: 'Get a card by ID',
|
|
243
|
+
},
|
|
244
|
+
{
|
|
245
|
+
name: '✏️ Update Card',
|
|
246
|
+
value: 'updateCard',
|
|
247
|
+
description: 'Modify information on an existing card',
|
|
248
|
+
action: 'Update a card',
|
|
249
|
+
},
|
|
250
|
+
{
|
|
251
|
+
name: '🗑️ Delete Card',
|
|
252
|
+
value: 'deleteCard',
|
|
253
|
+
description: 'Permanently delete a card',
|
|
254
|
+
action: 'Delete a card',
|
|
255
|
+
},
|
|
256
|
+
{
|
|
257
|
+
name: '🏷️ Add Label to Card',
|
|
258
|
+
value: 'addCardLabel',
|
|
259
|
+
description: 'Add a label to a card',
|
|
260
|
+
action: 'Add a label to a card',
|
|
261
|
+
},
|
|
262
|
+
{
|
|
263
|
+
name: '🚫 Remove Label from Card',
|
|
264
|
+
value: 'removeCardLabel',
|
|
265
|
+
description: 'Remove a label from a card',
|
|
266
|
+
action: 'Remove a label from a card',
|
|
267
|
+
},
|
|
268
|
+
{
|
|
269
|
+
name: '👤 Add Member to Card',
|
|
270
|
+
value: 'addCardMember',
|
|
271
|
+
description: 'Assign a member to a card',
|
|
272
|
+
action: 'Add a member to a card',
|
|
273
|
+
},
|
|
274
|
+
{
|
|
275
|
+
name: '🚫 Remove Member from Card',
|
|
276
|
+
value: 'removeCardMember',
|
|
277
|
+
description: 'Unassign a member from a card',
|
|
278
|
+
action: 'Remove a member from a card',
|
|
279
|
+
},
|
|
280
|
+
{
|
|
281
|
+
name: '✅ Create Task in Card',
|
|
282
|
+
value: 'createCardTask',
|
|
283
|
+
description: 'Create a new task within a card',
|
|
284
|
+
action: 'Create a task in a card',
|
|
285
|
+
},
|
|
286
|
+
{
|
|
287
|
+
name: '🔄 Update Task',
|
|
288
|
+
value: 'updateCardTask',
|
|
289
|
+
description: 'Modify an existing task',
|
|
290
|
+
action: 'Update a task',
|
|
291
|
+
},
|
|
292
|
+
{
|
|
293
|
+
name: '🗑️ Delete Task',
|
|
294
|
+
value: 'deleteCardTask',
|
|
295
|
+
description: 'Permanently delete a task',
|
|
296
|
+
action: 'Delete a task',
|
|
297
|
+
},
|
|
298
|
+
{
|
|
299
|
+
name: '📎 Create Attachment in Card',
|
|
300
|
+
value: 'createCardAttachment',
|
|
301
|
+
description: 'Attach a file to a card',
|
|
302
|
+
action: 'Create an attachment in a card',
|
|
303
|
+
},
|
|
304
|
+
{
|
|
305
|
+
name: '✏️ Update Attachment',
|
|
306
|
+
value: 'updateCardAttachment',
|
|
307
|
+
description: 'Modify an attachment',
|
|
308
|
+
action: 'Update an attachment',
|
|
309
|
+
},
|
|
310
|
+
{
|
|
311
|
+
name: '🗑️ Delete Attachment',
|
|
312
|
+
value: 'deleteCardAttachment',
|
|
313
|
+
description: 'Permanently delete an attachment',
|
|
314
|
+
action: 'Delete an attachment',
|
|
315
|
+
},
|
|
316
|
+
{
|
|
317
|
+
name: '📋 Get All Card Actions',
|
|
318
|
+
value: 'getAllCardActions',
|
|
319
|
+
description: 'Get all actions performed on a card',
|
|
320
|
+
action: 'Get all actions of a card',
|
|
321
|
+
},
|
|
322
|
+
{
|
|
323
|
+
name: '💬 Create Comment on Card',
|
|
324
|
+
value: 'createCardComment',
|
|
325
|
+
description: 'Añadir un comentario a una tarjeta',
|
|
326
|
+
action: 'Create a comment on a card',
|
|
327
|
+
},
|
|
328
|
+
{
|
|
329
|
+
name: '✏️ Update Comment',
|
|
330
|
+
value: 'updateCardComment',
|
|
331
|
+
description: 'Edit an existing comment',
|
|
332
|
+
action: 'Update a comment on a card',
|
|
333
|
+
},
|
|
334
|
+
{
|
|
335
|
+
name: '🗑️ Delete Comment',
|
|
336
|
+
value: 'deleteCardComment',
|
|
337
|
+
description: 'Permanently delete a comment',
|
|
338
|
+
action: 'Delete a comment from a card',
|
|
339
|
+
},
|
|
340
|
+
],
|
|
341
|
+
default: 'createCard',
|
|
342
|
+
},
|
|
343
|
+
{
|
|
344
|
+
displayName: 'Operation',
|
|
345
|
+
name: 'operation',
|
|
346
|
+
type: 'options',
|
|
347
|
+
displayOptions: {
|
|
348
|
+
show: {
|
|
349
|
+
resource: [
|
|
350
|
+
'user',
|
|
351
|
+
],
|
|
352
|
+
},
|
|
353
|
+
},
|
|
354
|
+
options: [
|
|
355
|
+
{
|
|
356
|
+
name: '➕ Create User',
|
|
357
|
+
value: 'createUser',
|
|
358
|
+
description: 'Create a new user in the system',
|
|
359
|
+
action: 'Create a user',
|
|
360
|
+
},
|
|
361
|
+
{
|
|
362
|
+
name: '🔍 Get User',
|
|
363
|
+
value: 'getUser',
|
|
364
|
+
description: 'Obtain information from a specific user',
|
|
365
|
+
action: 'Get a user by ID',
|
|
366
|
+
},
|
|
367
|
+
{
|
|
368
|
+
name: '📋 Get All Users',
|
|
369
|
+
value: 'getAllUsers',
|
|
370
|
+
description: 'List all registered users',
|
|
371
|
+
action: 'Get all users',
|
|
372
|
+
},
|
|
373
|
+
{
|
|
374
|
+
name: '✏️ Update User',
|
|
375
|
+
value: 'updateUser',
|
|
376
|
+
description: 'Modify data of an existing user',
|
|
377
|
+
action: 'Update a user',
|
|
378
|
+
},
|
|
379
|
+
{
|
|
380
|
+
name: '🗑️ Delete User',
|
|
381
|
+
value: 'deleteUser',
|
|
382
|
+
description: 'Permanently delete a user',
|
|
383
|
+
action: 'Delete a user',
|
|
384
|
+
},
|
|
385
|
+
{
|
|
386
|
+
name: '📧 Update User Email',
|
|
387
|
+
value: 'updateUserEmail',
|
|
388
|
+
description: "Change a user's email address",
|
|
389
|
+
action: 'Update user email',
|
|
390
|
+
},
|
|
391
|
+
{
|
|
392
|
+
name: '🔑 Update User Password',
|
|
393
|
+
value: 'updateUserPassword',
|
|
394
|
+
description: "Change a user's password",
|
|
395
|
+
action: 'Update user password',
|
|
396
|
+
},
|
|
397
|
+
{
|
|
398
|
+
name: '👤 Update User Username',
|
|
399
|
+
value: 'updateUserUsername',
|
|
400
|
+
description: 'Change username',
|
|
401
|
+
action: 'Update user username',
|
|
402
|
+
},
|
|
403
|
+
],
|
|
404
|
+
default: 'getAllUsers',
|
|
405
|
+
},
|
|
406
|
+
// Project fields
|
|
407
|
+
{
|
|
408
|
+
displayName: 'Project ID',
|
|
409
|
+
name: 'projectId',
|
|
410
|
+
type: 'string',
|
|
411
|
+
displayOptions: {
|
|
412
|
+
show: {
|
|
413
|
+
resource: [
|
|
414
|
+
'project',
|
|
415
|
+
],
|
|
416
|
+
operation: [
|
|
417
|
+
'getProject',
|
|
418
|
+
'updateProject',
|
|
419
|
+
'deleteProject',
|
|
420
|
+
'updateProjectBackgroundImage',
|
|
421
|
+
],
|
|
422
|
+
},
|
|
423
|
+
},
|
|
424
|
+
required: true,
|
|
425
|
+
default: '',
|
|
426
|
+
description: 'The ID of the project',
|
|
427
|
+
},
|
|
428
|
+
{
|
|
429
|
+
displayName: 'Name',
|
|
430
|
+
name: 'name',
|
|
431
|
+
type: 'string',
|
|
432
|
+
displayOptions: {
|
|
433
|
+
show: {
|
|
434
|
+
resource: [
|
|
435
|
+
'project',
|
|
436
|
+
],
|
|
437
|
+
operation: [
|
|
438
|
+
'createProject',
|
|
439
|
+
'updateProject',
|
|
440
|
+
],
|
|
441
|
+
},
|
|
442
|
+
},
|
|
443
|
+
required: true,
|
|
444
|
+
default: '',
|
|
445
|
+
description: 'Name of the project',
|
|
446
|
+
},
|
|
447
|
+
// Project additional fields - reemplazados por parámetros individuales
|
|
448
|
+
{
|
|
449
|
+
displayName: 'Background Name',
|
|
450
|
+
name: 'backgroundName',
|
|
451
|
+
type: 'string',
|
|
452
|
+
default: '',
|
|
453
|
+
displayOptions: {
|
|
454
|
+
show: {
|
|
455
|
+
resource: ['project'],
|
|
456
|
+
operation: ['createProject', 'updateProject'],
|
|
457
|
+
},
|
|
458
|
+
},
|
|
459
|
+
description: 'Name of the background',
|
|
460
|
+
},
|
|
461
|
+
{
|
|
462
|
+
displayName: 'Background Type',
|
|
463
|
+
name: 'backgroundType',
|
|
464
|
+
type: 'options',
|
|
465
|
+
options: [
|
|
466
|
+
{
|
|
467
|
+
name: 'Gradient',
|
|
468
|
+
value: 'gradient',
|
|
469
|
+
},
|
|
470
|
+
{
|
|
471
|
+
name: 'Image',
|
|
472
|
+
value: 'image',
|
|
473
|
+
},
|
|
474
|
+
],
|
|
475
|
+
default: 'gradient',
|
|
476
|
+
displayOptions: {
|
|
477
|
+
show: {
|
|
478
|
+
resource: ['project'],
|
|
479
|
+
operation: ['createProject', 'updateProject'],
|
|
480
|
+
},
|
|
481
|
+
},
|
|
482
|
+
description: 'Type of background',
|
|
483
|
+
},
|
|
484
|
+
{
|
|
485
|
+
displayName: 'Background Image',
|
|
486
|
+
name: 'backgroundImage',
|
|
487
|
+
type: 'string',
|
|
488
|
+
default: '',
|
|
489
|
+
displayOptions: {
|
|
490
|
+
show: {
|
|
491
|
+
resource: ['project'],
|
|
492
|
+
operation: ['createProject', 'updateProject'],
|
|
493
|
+
},
|
|
494
|
+
},
|
|
495
|
+
description: 'URL of the background image',
|
|
496
|
+
},
|
|
497
|
+
{
|
|
498
|
+
displayName: 'Background Image File',
|
|
499
|
+
name: 'backgroundImageFile',
|
|
500
|
+
type: 'string',
|
|
501
|
+
displayOptions: {
|
|
502
|
+
show: {
|
|
503
|
+
resource: [
|
|
504
|
+
'project',
|
|
505
|
+
],
|
|
506
|
+
operation: [
|
|
507
|
+
'updateProjectBackgroundImage',
|
|
508
|
+
],
|
|
509
|
+
},
|
|
510
|
+
},
|
|
511
|
+
required: true,
|
|
512
|
+
default: '',
|
|
513
|
+
description: 'File to upload as background image',
|
|
514
|
+
},
|
|
515
|
+
// Board fields
|
|
516
|
+
{
|
|
517
|
+
displayName: 'Project ID',
|
|
518
|
+
name: 'projectId',
|
|
519
|
+
type: 'string',
|
|
520
|
+
displayOptions: {
|
|
521
|
+
show: {
|
|
522
|
+
resource: [
|
|
523
|
+
'board',
|
|
524
|
+
],
|
|
525
|
+
operation: [
|
|
526
|
+
'createBoard',
|
|
527
|
+
],
|
|
528
|
+
},
|
|
529
|
+
},
|
|
530
|
+
required: true,
|
|
531
|
+
default: '',
|
|
532
|
+
description: 'The ID of the project to create the board in',
|
|
533
|
+
},
|
|
534
|
+
{
|
|
535
|
+
displayName: 'Board ID',
|
|
536
|
+
name: 'boardId',
|
|
537
|
+
type: 'string',
|
|
538
|
+
displayOptions: {
|
|
539
|
+
show: {
|
|
540
|
+
resource: [
|
|
541
|
+
'board',
|
|
542
|
+
],
|
|
543
|
+
operation: [
|
|
544
|
+
'getBoard',
|
|
545
|
+
'updateBoard',
|
|
546
|
+
'deleteBoard',
|
|
547
|
+
],
|
|
548
|
+
},
|
|
549
|
+
},
|
|
550
|
+
required: true,
|
|
551
|
+
default: '',
|
|
552
|
+
description: 'The ID of the board',
|
|
553
|
+
},
|
|
554
|
+
{
|
|
555
|
+
displayName: 'Name',
|
|
556
|
+
name: 'name',
|
|
557
|
+
type: 'string',
|
|
558
|
+
displayOptions: {
|
|
559
|
+
show: {
|
|
560
|
+
resource: [
|
|
561
|
+
'board',
|
|
562
|
+
],
|
|
563
|
+
operation: [
|
|
564
|
+
'createBoard',
|
|
565
|
+
'updateBoard',
|
|
566
|
+
],
|
|
567
|
+
},
|
|
568
|
+
},
|
|
569
|
+
required: true,
|
|
570
|
+
default: '',
|
|
571
|
+
description: 'Name of the board',
|
|
572
|
+
},
|
|
573
|
+
{
|
|
574
|
+
displayName: 'Position',
|
|
575
|
+
name: 'position',
|
|
576
|
+
type: 'number',
|
|
577
|
+
displayOptions: {
|
|
578
|
+
show: {
|
|
579
|
+
resource: [
|
|
580
|
+
'board',
|
|
581
|
+
],
|
|
582
|
+
operation: [
|
|
583
|
+
'createBoard',
|
|
584
|
+
'updateBoard',
|
|
585
|
+
],
|
|
586
|
+
},
|
|
587
|
+
},
|
|
588
|
+
default: 1,
|
|
589
|
+
description: 'Position of the board',
|
|
590
|
+
},
|
|
591
|
+
// Card fields
|
|
592
|
+
{
|
|
593
|
+
displayName: 'List ID',
|
|
594
|
+
name: 'listId',
|
|
595
|
+
type: 'string',
|
|
596
|
+
displayOptions: {
|
|
597
|
+
show: {
|
|
598
|
+
resource: [
|
|
599
|
+
'card',
|
|
600
|
+
],
|
|
601
|
+
operation: [
|
|
602
|
+
'createCard',
|
|
603
|
+
],
|
|
604
|
+
},
|
|
605
|
+
},
|
|
606
|
+
required: true,
|
|
607
|
+
default: '',
|
|
608
|
+
description: 'The ID of the list to create the card in',
|
|
609
|
+
},
|
|
610
|
+
{
|
|
611
|
+
displayName: 'Card ID',
|
|
612
|
+
name: 'cardId',
|
|
613
|
+
type: 'string',
|
|
614
|
+
displayOptions: {
|
|
615
|
+
show: {
|
|
616
|
+
resource: [
|
|
617
|
+
'card',
|
|
618
|
+
],
|
|
619
|
+
operation: [
|
|
620
|
+
'getCard',
|
|
621
|
+
'updateCard',
|
|
622
|
+
'deleteCard',
|
|
623
|
+
],
|
|
624
|
+
},
|
|
625
|
+
},
|
|
626
|
+
required: true,
|
|
627
|
+
default: '',
|
|
628
|
+
description: 'The ID of the card',
|
|
629
|
+
},
|
|
630
|
+
{
|
|
631
|
+
displayName: 'Name',
|
|
632
|
+
name: 'name',
|
|
633
|
+
type: 'string',
|
|
634
|
+
displayOptions: {
|
|
635
|
+
show: {
|
|
636
|
+
resource: [
|
|
637
|
+
'card',
|
|
638
|
+
],
|
|
639
|
+
operation: [
|
|
640
|
+
'createCard',
|
|
641
|
+
'updateCard',
|
|
642
|
+
],
|
|
643
|
+
},
|
|
644
|
+
},
|
|
645
|
+
required: true,
|
|
646
|
+
default: '',
|
|
647
|
+
description: 'Name of the card',
|
|
648
|
+
},
|
|
649
|
+
// Card additional fields - replaced by individual parameters
|
|
650
|
+
{
|
|
651
|
+
displayName: 'Description',
|
|
652
|
+
name: 'description',
|
|
653
|
+
type: 'string',
|
|
654
|
+
default: '',
|
|
655
|
+
displayOptions: {
|
|
656
|
+
show: {
|
|
657
|
+
resource: ['card'],
|
|
658
|
+
operation: ['createCard', 'updateCard'],
|
|
659
|
+
},
|
|
660
|
+
},
|
|
661
|
+
description: 'Description of the card',
|
|
662
|
+
},
|
|
663
|
+
{
|
|
664
|
+
displayName: "Type",
|
|
665
|
+
name: "type",
|
|
666
|
+
default: "project",
|
|
667
|
+
type: "options",
|
|
668
|
+
options: [
|
|
669
|
+
{
|
|
670
|
+
name: "Project",
|
|
671
|
+
value: "project"
|
|
672
|
+
},
|
|
673
|
+
{
|
|
674
|
+
name: "Story",
|
|
675
|
+
value: "story"
|
|
676
|
+
}
|
|
677
|
+
],
|
|
678
|
+
displayOptions: {
|
|
679
|
+
show: {
|
|
680
|
+
resource: ['card'],
|
|
681
|
+
operation: ['createCard', 'updateCard'],
|
|
682
|
+
},
|
|
683
|
+
}
|
|
684
|
+
},
|
|
685
|
+
{
|
|
686
|
+
displayName: 'Due Date',
|
|
687
|
+
name: 'dueDate',
|
|
688
|
+
type: 'dateTime',
|
|
689
|
+
default: '',
|
|
690
|
+
displayOptions: {
|
|
691
|
+
show: {
|
|
692
|
+
resource: ['card'],
|
|
693
|
+
operation: ['createCard', 'updateCard'],
|
|
694
|
+
},
|
|
695
|
+
},
|
|
696
|
+
description: 'Due date of the card',
|
|
697
|
+
},
|
|
698
|
+
{
|
|
699
|
+
displayName: 'Position',
|
|
700
|
+
name: 'position',
|
|
701
|
+
type: 'number',
|
|
702
|
+
default: 1,
|
|
703
|
+
displayOptions: {
|
|
704
|
+
show: {
|
|
705
|
+
resource: ['card'],
|
|
706
|
+
operation: ['createCard', 'updateCard'],
|
|
707
|
+
},
|
|
708
|
+
},
|
|
709
|
+
description: 'Position of the card in the list',
|
|
710
|
+
},
|
|
711
|
+
{
|
|
712
|
+
displayName: 'Is Due Date Completed',
|
|
713
|
+
name: 'isDueDateCompleted',
|
|
714
|
+
type: 'boolean',
|
|
715
|
+
default: false,
|
|
716
|
+
displayOptions: {
|
|
717
|
+
show: {
|
|
718
|
+
resource: ['card'],
|
|
719
|
+
operation: ['createCard', 'updateCard'],
|
|
720
|
+
},
|
|
721
|
+
},
|
|
722
|
+
description: 'Whether the due date is completed',
|
|
723
|
+
},
|
|
724
|
+
// Task fields
|
|
725
|
+
{
|
|
726
|
+
displayName: 'Card ID',
|
|
727
|
+
name: 'cardId',
|
|
728
|
+
type: 'string',
|
|
729
|
+
displayOptions: {
|
|
730
|
+
show: {
|
|
731
|
+
resource: [
|
|
732
|
+
'card',
|
|
733
|
+
],
|
|
734
|
+
operation: [
|
|
735
|
+
'createCardTask',
|
|
736
|
+
],
|
|
737
|
+
},
|
|
738
|
+
},
|
|
739
|
+
required: true,
|
|
740
|
+
default: '',
|
|
741
|
+
description: 'The ID of the card to create the task in',
|
|
742
|
+
},
|
|
743
|
+
{
|
|
744
|
+
displayName: 'Task ID',
|
|
745
|
+
name: 'taskId',
|
|
746
|
+
type: 'string',
|
|
747
|
+
displayOptions: {
|
|
748
|
+
show: {
|
|
749
|
+
resource: [
|
|
750
|
+
'card',
|
|
751
|
+
],
|
|
752
|
+
operation: [
|
|
753
|
+
'updateCardTask',
|
|
754
|
+
'deleteCardTask',
|
|
755
|
+
],
|
|
756
|
+
},
|
|
757
|
+
},
|
|
758
|
+
required: true,
|
|
759
|
+
default: '',
|
|
760
|
+
description: 'The ID of the task',
|
|
761
|
+
},
|
|
762
|
+
{
|
|
763
|
+
displayName: 'Task Name',
|
|
764
|
+
name: 'taskName',
|
|
765
|
+
type: 'string',
|
|
766
|
+
displayOptions: {
|
|
767
|
+
show: {
|
|
768
|
+
resource: [
|
|
769
|
+
'card',
|
|
770
|
+
],
|
|
771
|
+
operation: [
|
|
772
|
+
'createCardTask',
|
|
773
|
+
'updateCardTask',
|
|
774
|
+
],
|
|
775
|
+
},
|
|
776
|
+
},
|
|
777
|
+
required: true,
|
|
778
|
+
default: '',
|
|
779
|
+
description: 'Name of the task',
|
|
780
|
+
},
|
|
781
|
+
// Task additional fields
|
|
782
|
+
{
|
|
783
|
+
displayName: 'Task Position',
|
|
784
|
+
name: 'taskPosition',
|
|
785
|
+
type: 'number',
|
|
786
|
+
default: 1,
|
|
787
|
+
displayOptions: {
|
|
788
|
+
show: {
|
|
789
|
+
resource: ['card'],
|
|
790
|
+
operation: ['createCardTask', 'updateCardTask'],
|
|
791
|
+
},
|
|
792
|
+
},
|
|
793
|
+
description: 'Position of the task in the card',
|
|
794
|
+
},
|
|
795
|
+
{
|
|
796
|
+
displayName: 'Is Completed',
|
|
797
|
+
name: 'taskIsCompleted',
|
|
798
|
+
type: 'boolean',
|
|
799
|
+
default: false,
|
|
800
|
+
displayOptions: {
|
|
801
|
+
show: {
|
|
802
|
+
resource: ['card'],
|
|
803
|
+
operation: ['createCardTask', 'updateCardTask'],
|
|
804
|
+
},
|
|
805
|
+
},
|
|
806
|
+
description: 'Whether the task is completed',
|
|
807
|
+
},
|
|
808
|
+
// User fields
|
|
809
|
+
{
|
|
810
|
+
displayName: 'User ID',
|
|
811
|
+
name: 'userId',
|
|
812
|
+
type: 'string',
|
|
813
|
+
displayOptions: {
|
|
814
|
+
show: {
|
|
815
|
+
resource: [
|
|
816
|
+
'user',
|
|
817
|
+
],
|
|
818
|
+
operation: [
|
|
819
|
+
'getUser',
|
|
820
|
+
'updateUser',
|
|
821
|
+
'deleteUser',
|
|
822
|
+
'updateUserEmail',
|
|
823
|
+
'updateUserPassword',
|
|
824
|
+
'updateUserUsername',
|
|
825
|
+
],
|
|
826
|
+
},
|
|
827
|
+
},
|
|
828
|
+
required: true,
|
|
829
|
+
default: '',
|
|
830
|
+
description: 'The ID of the user',
|
|
831
|
+
},
|
|
832
|
+
{
|
|
833
|
+
displayName: 'Email',
|
|
834
|
+
name: 'email',
|
|
835
|
+
type: 'string',
|
|
836
|
+
displayOptions: {
|
|
837
|
+
show: {
|
|
838
|
+
resource: [
|
|
839
|
+
'user',
|
|
840
|
+
],
|
|
841
|
+
operation: [
|
|
842
|
+
'createUser',
|
|
843
|
+
'updateUser',
|
|
844
|
+
'updateUserEmail',
|
|
845
|
+
],
|
|
846
|
+
},
|
|
847
|
+
},
|
|
848
|
+
required: true,
|
|
849
|
+
default: '',
|
|
850
|
+
description: 'Email of the user',
|
|
851
|
+
},
|
|
852
|
+
{
|
|
853
|
+
displayName: 'Password',
|
|
854
|
+
name: 'password',
|
|
855
|
+
type: 'string',
|
|
856
|
+
typeOptions: {
|
|
857
|
+
password: true,
|
|
858
|
+
},
|
|
859
|
+
displayOptions: {
|
|
860
|
+
show: {
|
|
861
|
+
resource: [
|
|
862
|
+
'user',
|
|
863
|
+
],
|
|
864
|
+
operation: [
|
|
865
|
+
'createUser',
|
|
866
|
+
'updateUserPassword',
|
|
867
|
+
],
|
|
868
|
+
},
|
|
869
|
+
},
|
|
870
|
+
required: true,
|
|
871
|
+
default: '',
|
|
872
|
+
description: 'Password of the user',
|
|
873
|
+
},
|
|
874
|
+
{
|
|
875
|
+
displayName: 'Name',
|
|
876
|
+
name: 'name',
|
|
877
|
+
type: 'string',
|
|
878
|
+
displayOptions: {
|
|
879
|
+
show: {
|
|
880
|
+
resource: [
|
|
881
|
+
'user',
|
|
882
|
+
],
|
|
883
|
+
operation: [
|
|
884
|
+
'createUser',
|
|
885
|
+
'updateUser',
|
|
886
|
+
],
|
|
887
|
+
},
|
|
888
|
+
},
|
|
889
|
+
required: true,
|
|
890
|
+
default: '',
|
|
891
|
+
description: 'Name of the user',
|
|
892
|
+
},
|
|
893
|
+
{
|
|
894
|
+
displayName: 'Username',
|
|
895
|
+
name: 'username',
|
|
896
|
+
type: 'string',
|
|
897
|
+
displayOptions: {
|
|
898
|
+
show: {
|
|
899
|
+
resource: [
|
|
900
|
+
'user',
|
|
901
|
+
],
|
|
902
|
+
operation: [
|
|
903
|
+
'createUser',
|
|
904
|
+
'updateUser',
|
|
905
|
+
'updateUserUsername',
|
|
906
|
+
],
|
|
907
|
+
},
|
|
908
|
+
},
|
|
909
|
+
required: true,
|
|
910
|
+
default: '',
|
|
911
|
+
description: 'Username of the user',
|
|
912
|
+
},
|
|
913
|
+
// User additional fields - replaced by individual parameters
|
|
914
|
+
{
|
|
915
|
+
displayName: 'Phone',
|
|
916
|
+
name: 'phone',
|
|
917
|
+
type: 'string',
|
|
918
|
+
default: '',
|
|
919
|
+
displayOptions: {
|
|
920
|
+
show: {
|
|
921
|
+
resource: ['user'],
|
|
922
|
+
operation: ['createUser', 'updateUser'],
|
|
923
|
+
},
|
|
924
|
+
},
|
|
925
|
+
description: 'Phone number of the user',
|
|
926
|
+
},
|
|
927
|
+
{
|
|
928
|
+
displayName: 'Organization',
|
|
929
|
+
name: 'organization',
|
|
930
|
+
type: 'string',
|
|
931
|
+
default: '',
|
|
932
|
+
displayOptions: {
|
|
933
|
+
show: {
|
|
934
|
+
resource: ['user'],
|
|
935
|
+
operation: ['createUser', 'updateUser'],
|
|
936
|
+
},
|
|
937
|
+
},
|
|
938
|
+
description: 'Organization of the user',
|
|
939
|
+
},
|
|
940
|
+
{
|
|
941
|
+
displayName: 'Language',
|
|
942
|
+
name: 'language',
|
|
943
|
+
type: 'string',
|
|
944
|
+
default: '',
|
|
945
|
+
displayOptions: {
|
|
946
|
+
show: {
|
|
947
|
+
resource: ['user'],
|
|
948
|
+
operation: ['createUser', 'updateUser'],
|
|
949
|
+
},
|
|
950
|
+
},
|
|
951
|
+
description: 'Language preference of the user',
|
|
952
|
+
},
|
|
953
|
+
{
|
|
954
|
+
displayName: 'Subscribe to Own Cards',
|
|
955
|
+
name: 'subscribeToOwnCards',
|
|
956
|
+
type: 'boolean',
|
|
957
|
+
default: true,
|
|
958
|
+
displayOptions: {
|
|
959
|
+
show: {
|
|
960
|
+
resource: ['user'],
|
|
961
|
+
operation: ['createUser', 'updateUser'],
|
|
962
|
+
},
|
|
963
|
+
},
|
|
964
|
+
description: 'Whether the user should be subscribed to their own cards',
|
|
965
|
+
},
|
|
966
|
+
{
|
|
967
|
+
displayName: 'Is Admin',
|
|
968
|
+
name: 'isAdmin',
|
|
969
|
+
type: 'boolean',
|
|
970
|
+
default: false,
|
|
971
|
+
displayOptions: {
|
|
972
|
+
show: {
|
|
973
|
+
resource: ['user'],
|
|
974
|
+
operation: ['createUser', 'updateUser'],
|
|
975
|
+
},
|
|
976
|
+
},
|
|
977
|
+
description: 'Whether the user is an administrator',
|
|
978
|
+
},
|
|
979
|
+
// Operaciones para Board Memberships
|
|
980
|
+
{
|
|
981
|
+
displayName: 'Operation',
|
|
982
|
+
name: 'operation',
|
|
983
|
+
type: 'options',
|
|
984
|
+
displayOptions: {
|
|
985
|
+
show: {
|
|
986
|
+
resource: [
|
|
987
|
+
'boardMembership',
|
|
988
|
+
],
|
|
989
|
+
},
|
|
990
|
+
},
|
|
991
|
+
options: [
|
|
992
|
+
{
|
|
993
|
+
name: 'Add Member to Board',
|
|
994
|
+
value: 'createBoardMembership',
|
|
995
|
+
description: 'Add a member to a board',
|
|
996
|
+
action: 'Add a member to a board',
|
|
997
|
+
},
|
|
998
|
+
{
|
|
999
|
+
name: 'Update Board Membership',
|
|
1000
|
+
value: 'updateBoardMembership',
|
|
1001
|
+
description: 'Update a board membership',
|
|
1002
|
+
action: 'Update a board membership',
|
|
1003
|
+
},
|
|
1004
|
+
{
|
|
1005
|
+
name: 'Remove Member from Board',
|
|
1006
|
+
value: 'deleteBoardMembership',
|
|
1007
|
+
description: 'Remove a member from a board',
|
|
1008
|
+
action: 'Remove a member from a board',
|
|
1009
|
+
},
|
|
1010
|
+
],
|
|
1011
|
+
default: 'createBoardMembership',
|
|
1012
|
+
},
|
|
1013
|
+
// Board Membership fields
|
|
1014
|
+
{
|
|
1015
|
+
displayName: 'Board ID',
|
|
1016
|
+
name: 'boardId',
|
|
1017
|
+
type: 'string',
|
|
1018
|
+
displayOptions: {
|
|
1019
|
+
show: {
|
|
1020
|
+
resource: [
|
|
1021
|
+
'board',
|
|
1022
|
+
],
|
|
1023
|
+
operation: [
|
|
1024
|
+
'createBoardMembership',
|
|
1025
|
+
],
|
|
1026
|
+
},
|
|
1027
|
+
},
|
|
1028
|
+
required: true,
|
|
1029
|
+
default: '',
|
|
1030
|
+
description: 'ID of the board to which the member will be added',
|
|
1031
|
+
},
|
|
1032
|
+
{
|
|
1033
|
+
displayName: 'User ID',
|
|
1034
|
+
name: 'userId',
|
|
1035
|
+
type: 'string',
|
|
1036
|
+
displayOptions: {
|
|
1037
|
+
show: {
|
|
1038
|
+
resource: [
|
|
1039
|
+
'board',
|
|
1040
|
+
],
|
|
1041
|
+
operation: [
|
|
1042
|
+
'createBoardMembership',
|
|
1043
|
+
],
|
|
1044
|
+
},
|
|
1045
|
+
},
|
|
1046
|
+
required: true,
|
|
1047
|
+
default: '',
|
|
1048
|
+
description: 'User ID that will be added as a board member',
|
|
1049
|
+
},
|
|
1050
|
+
{
|
|
1051
|
+
displayName: 'Membership ID',
|
|
1052
|
+
name: 'membershipId',
|
|
1053
|
+
type: 'string',
|
|
1054
|
+
displayOptions: {
|
|
1055
|
+
show: {
|
|
1056
|
+
resource: [
|
|
1057
|
+
'board',
|
|
1058
|
+
],
|
|
1059
|
+
operation: [
|
|
1060
|
+
'updateBoardMembership',
|
|
1061
|
+
'deleteBoardMembership',
|
|
1062
|
+
],
|
|
1063
|
+
},
|
|
1064
|
+
},
|
|
1065
|
+
required: true,
|
|
1066
|
+
default: '',
|
|
1067
|
+
description: 'Board Membership ID',
|
|
1068
|
+
},
|
|
1069
|
+
{
|
|
1070
|
+
displayName: 'Role',
|
|
1071
|
+
name: 'role',
|
|
1072
|
+
type: 'options',
|
|
1073
|
+
displayOptions: {
|
|
1074
|
+
show: {
|
|
1075
|
+
resource: [
|
|
1076
|
+
'board',
|
|
1077
|
+
],
|
|
1078
|
+
operation: [
|
|
1079
|
+
'createBoardMembership',
|
|
1080
|
+
'updateBoardMembership',
|
|
1081
|
+
],
|
|
1082
|
+
},
|
|
1083
|
+
},
|
|
1084
|
+
options: [
|
|
1085
|
+
{
|
|
1086
|
+
name: 'Admin',
|
|
1087
|
+
value: 'admin',
|
|
1088
|
+
},
|
|
1089
|
+
{
|
|
1090
|
+
name: 'Editor',
|
|
1091
|
+
value: 'editor',
|
|
1092
|
+
},
|
|
1093
|
+
],
|
|
1094
|
+
required: true,
|
|
1095
|
+
default: 'editor',
|
|
1096
|
+
description: "Member's role on the board",
|
|
1097
|
+
},
|
|
1098
|
+
// Operaciones para Board Labels
|
|
1099
|
+
{
|
|
1100
|
+
displayName: 'Operation',
|
|
1101
|
+
name: 'operation',
|
|
1102
|
+
type: 'options',
|
|
1103
|
+
displayOptions: {
|
|
1104
|
+
show: {
|
|
1105
|
+
resource: [
|
|
1106
|
+
'boardLabel',
|
|
1107
|
+
],
|
|
1108
|
+
},
|
|
1109
|
+
},
|
|
1110
|
+
options: [
|
|
1111
|
+
{
|
|
1112
|
+
name: 'Create a Board Label',
|
|
1113
|
+
value: 'createBoardLabel',
|
|
1114
|
+
description: 'Create a board label',
|
|
1115
|
+
action: 'Create a board label',
|
|
1116
|
+
},
|
|
1117
|
+
{
|
|
1118
|
+
name: 'Update a Board Label',
|
|
1119
|
+
value: 'updateBoardLabel',
|
|
1120
|
+
description: 'Update a board label',
|
|
1121
|
+
action: 'Update a board label',
|
|
1122
|
+
},
|
|
1123
|
+
{
|
|
1124
|
+
name: 'Delete a Board Label',
|
|
1125
|
+
value: 'deleteBoardLabel',
|
|
1126
|
+
description: 'Delete a board label',
|
|
1127
|
+
action: 'Delete a board label',
|
|
1128
|
+
},
|
|
1129
|
+
],
|
|
1130
|
+
default: 'createBoardLabel',
|
|
1131
|
+
},
|
|
1132
|
+
// Board Label fields
|
|
1133
|
+
{
|
|
1134
|
+
displayName: 'Board ID',
|
|
1135
|
+
name: 'boardId',
|
|
1136
|
+
type: 'string',
|
|
1137
|
+
displayOptions: {
|
|
1138
|
+
show: {
|
|
1139
|
+
resource: [
|
|
1140
|
+
'board',
|
|
1141
|
+
],
|
|
1142
|
+
operation: [
|
|
1143
|
+
'createBoardLabel',
|
|
1144
|
+
],
|
|
1145
|
+
},
|
|
1146
|
+
},
|
|
1147
|
+
required: true,
|
|
1148
|
+
default: '',
|
|
1149
|
+
description: 'ID of the board where the label will be created',
|
|
1150
|
+
},
|
|
1151
|
+
{
|
|
1152
|
+
displayName: 'Label ID',
|
|
1153
|
+
name: 'labelId',
|
|
1154
|
+
type: 'string',
|
|
1155
|
+
displayOptions: {
|
|
1156
|
+
show: {
|
|
1157
|
+
resource: [
|
|
1158
|
+
'board',
|
|
1159
|
+
],
|
|
1160
|
+
operation: [
|
|
1161
|
+
'updateBoardLabel',
|
|
1162
|
+
'deleteBoardLabel',
|
|
1163
|
+
],
|
|
1164
|
+
},
|
|
1165
|
+
},
|
|
1166
|
+
required: true,
|
|
1167
|
+
default: '',
|
|
1168
|
+
description: 'Board label ID',
|
|
1169
|
+
},
|
|
1170
|
+
{
|
|
1171
|
+
displayName: 'Name',
|
|
1172
|
+
name: 'name',
|
|
1173
|
+
type: 'string',
|
|
1174
|
+
displayOptions: {
|
|
1175
|
+
show: {
|
|
1176
|
+
resource: [
|
|
1177
|
+
'board',
|
|
1178
|
+
],
|
|
1179
|
+
operation: [
|
|
1180
|
+
'createBoardLabel',
|
|
1181
|
+
'updateBoardLabel',
|
|
1182
|
+
],
|
|
1183
|
+
},
|
|
1184
|
+
},
|
|
1185
|
+
default: '',
|
|
1186
|
+
description: 'Label name',
|
|
1187
|
+
},
|
|
1188
|
+
{
|
|
1189
|
+
displayName: 'Color',
|
|
1190
|
+
name: 'color',
|
|
1191
|
+
type: 'string',
|
|
1192
|
+
displayOptions: {
|
|
1193
|
+
show: {
|
|
1194
|
+
resource: [
|
|
1195
|
+
'board',
|
|
1196
|
+
],
|
|
1197
|
+
operation: [
|
|
1198
|
+
'createBoardLabel',
|
|
1199
|
+
'updateBoardLabel',
|
|
1200
|
+
],
|
|
1201
|
+
},
|
|
1202
|
+
},
|
|
1203
|
+
required: true,
|
|
1204
|
+
default: '#4680FF',
|
|
1205
|
+
description: 'Label color in hexadecimal format (for example, #FF0000 for red)',
|
|
1206
|
+
},
|
|
1207
|
+
// Operaciones para Board Lists
|
|
1208
|
+
{
|
|
1209
|
+
displayName: 'Operation',
|
|
1210
|
+
name: 'operation',
|
|
1211
|
+
type: 'options',
|
|
1212
|
+
displayOptions: {
|
|
1213
|
+
show: {
|
|
1214
|
+
resource: [
|
|
1215
|
+
'boardList',
|
|
1216
|
+
],
|
|
1217
|
+
},
|
|
1218
|
+
},
|
|
1219
|
+
options: [
|
|
1220
|
+
{
|
|
1221
|
+
name: 'Create a Board List',
|
|
1222
|
+
value: 'createBoardList',
|
|
1223
|
+
description: 'Create a board list',
|
|
1224
|
+
action: 'Create a board list',
|
|
1225
|
+
},
|
|
1226
|
+
{
|
|
1227
|
+
name: 'Update a Board List',
|
|
1228
|
+
value: 'updateBoardList',
|
|
1229
|
+
description: 'Update a board list',
|
|
1230
|
+
action: 'Update a board list',
|
|
1231
|
+
},
|
|
1232
|
+
{
|
|
1233
|
+
name: 'Delete a Board List',
|
|
1234
|
+
value: 'deleteBoardList',
|
|
1235
|
+
description: 'Delete a board list',
|
|
1236
|
+
action: 'Delete a board list',
|
|
1237
|
+
},
|
|
1238
|
+
{
|
|
1239
|
+
name: 'Sort Cards in a List',
|
|
1240
|
+
value: 'sortBoardList',
|
|
1241
|
+
description: 'Sort cards in a list',
|
|
1242
|
+
action: 'Sort cards in a list',
|
|
1243
|
+
},
|
|
1244
|
+
],
|
|
1245
|
+
default: 'createBoardList',
|
|
1246
|
+
},
|
|
1247
|
+
// Board List fields
|
|
1248
|
+
{
|
|
1249
|
+
displayName: 'Board ID',
|
|
1250
|
+
name: 'boardId',
|
|
1251
|
+
type: 'string',
|
|
1252
|
+
displayOptions: {
|
|
1253
|
+
show: {
|
|
1254
|
+
resource: [
|
|
1255
|
+
'board',
|
|
1256
|
+
],
|
|
1257
|
+
operation: [
|
|
1258
|
+
'createBoardList',
|
|
1259
|
+
],
|
|
1260
|
+
},
|
|
1261
|
+
},
|
|
1262
|
+
required: true,
|
|
1263
|
+
default: '',
|
|
1264
|
+
description: 'ID of the board where the list will be created',
|
|
1265
|
+
},
|
|
1266
|
+
{
|
|
1267
|
+
displayName: 'List ID',
|
|
1268
|
+
name: 'listId',
|
|
1269
|
+
type: 'string',
|
|
1270
|
+
displayOptions: {
|
|
1271
|
+
show: {
|
|
1272
|
+
resource: [
|
|
1273
|
+
'board',
|
|
1274
|
+
],
|
|
1275
|
+
operation: [
|
|
1276
|
+
'updateBoardList',
|
|
1277
|
+
'deleteBoardList',
|
|
1278
|
+
'sortBoardList',
|
|
1279
|
+
],
|
|
1280
|
+
},
|
|
1281
|
+
},
|
|
1282
|
+
required: true,
|
|
1283
|
+
default: '',
|
|
1284
|
+
description: 'Board list ID',
|
|
1285
|
+
},
|
|
1286
|
+
{
|
|
1287
|
+
displayName: 'Name',
|
|
1288
|
+
name: 'name',
|
|
1289
|
+
type: 'string',
|
|
1290
|
+
displayOptions: {
|
|
1291
|
+
show: {
|
|
1292
|
+
resource: [
|
|
1293
|
+
'board',
|
|
1294
|
+
],
|
|
1295
|
+
operation: [
|
|
1296
|
+
'createBoardList',
|
|
1297
|
+
'updateBoardList',
|
|
1298
|
+
],
|
|
1299
|
+
},
|
|
1300
|
+
},
|
|
1301
|
+
required: true,
|
|
1302
|
+
default: '',
|
|
1303
|
+
description: 'List name',
|
|
1304
|
+
},
|
|
1305
|
+
{
|
|
1306
|
+
displayName: 'Position',
|
|
1307
|
+
name: 'position',
|
|
1308
|
+
type: 'number',
|
|
1309
|
+
displayOptions: {
|
|
1310
|
+
show: {
|
|
1311
|
+
resource: [
|
|
1312
|
+
'board',
|
|
1313
|
+
],
|
|
1314
|
+
operation: [
|
|
1315
|
+
'createBoardList',
|
|
1316
|
+
'updateBoardList',
|
|
1317
|
+
],
|
|
1318
|
+
},
|
|
1319
|
+
},
|
|
1320
|
+
default: 1,
|
|
1321
|
+
description: 'List position on the board',
|
|
1322
|
+
},
|
|
1323
|
+
{
|
|
1324
|
+
displayName: 'Card IDs',
|
|
1325
|
+
name: 'cardIds',
|
|
1326
|
+
type: 'string',
|
|
1327
|
+
displayOptions: {
|
|
1328
|
+
show: {
|
|
1329
|
+
resource: [
|
|
1330
|
+
'board',
|
|
1331
|
+
],
|
|
1332
|
+
operation: [
|
|
1333
|
+
'sortBoardList',
|
|
1334
|
+
],
|
|
1335
|
+
},
|
|
1336
|
+
},
|
|
1337
|
+
required: true,
|
|
1338
|
+
default: '',
|
|
1339
|
+
description: 'Card IDs separated by commas, in the order in which they should be sorted',
|
|
1340
|
+
},
|
|
1341
|
+
{
|
|
1342
|
+
displayName: 'Color',
|
|
1343
|
+
name: 'color',
|
|
1344
|
+
type: 'options',
|
|
1345
|
+
displayOptions: {
|
|
1346
|
+
show: {
|
|
1347
|
+
resource: [
|
|
1348
|
+
'boardList',
|
|
1349
|
+
],
|
|
1350
|
+
operation: [
|
|
1351
|
+
'createBoardList',
|
|
1352
|
+
'updateBoardList',
|
|
1353
|
+
],
|
|
1354
|
+
},
|
|
1355
|
+
},
|
|
1356
|
+
options: [
|
|
1357
|
+
{
|
|
1358
|
+
name: 'Berry Red',
|
|
1359
|
+
value: 'berry-red',
|
|
1360
|
+
},
|
|
1361
|
+
{
|
|
1362
|
+
name: 'Pumpkin Orange',
|
|
1363
|
+
value: 'pumpkin-orange',
|
|
1364
|
+
},
|
|
1365
|
+
{
|
|
1366
|
+
name: 'Lagoon Blue',
|
|
1367
|
+
value: 'lagoon-blue',
|
|
1368
|
+
},
|
|
1369
|
+
{
|
|
1370
|
+
name: 'Pink Tulip',
|
|
1371
|
+
value: 'pink-tulip',
|
|
1372
|
+
},
|
|
1373
|
+
{
|
|
1374
|
+
name: 'Light Mud',
|
|
1375
|
+
value: 'light-mud',
|
|
1376
|
+
},
|
|
1377
|
+
{
|
|
1378
|
+
name: 'Orange Peel',
|
|
1379
|
+
value: 'orange-peel',
|
|
1380
|
+
},
|
|
1381
|
+
{
|
|
1382
|
+
name: 'Bright Moss',
|
|
1383
|
+
value: 'bright-moss',
|
|
1384
|
+
},
|
|
1385
|
+
{
|
|
1386
|
+
name: 'Antique Blue',
|
|
1387
|
+
value: 'antique-blue',
|
|
1388
|
+
},
|
|
1389
|
+
{
|
|
1390
|
+
name: 'Dark Granite',
|
|
1391
|
+
value: 'dark-granite',
|
|
1392
|
+
},
|
|
1393
|
+
{
|
|
1394
|
+
name: 'Lagune Blue',
|
|
1395
|
+
value: 'lagune-blue',
|
|
1396
|
+
},
|
|
1397
|
+
{
|
|
1398
|
+
name: 'Sunny Grass',
|
|
1399
|
+
value: 'sunny-grass',
|
|
1400
|
+
},
|
|
1401
|
+
{
|
|
1402
|
+
name: 'Morning Sky',
|
|
1403
|
+
value: 'morning-sky',
|
|
1404
|
+
},
|
|
1405
|
+
{
|
|
1406
|
+
name: 'Light Orange',
|
|
1407
|
+
value: 'light-orange',
|
|
1408
|
+
},
|
|
1409
|
+
{
|
|
1410
|
+
name: 'Midnight Blue',
|
|
1411
|
+
value: 'midnight-blue',
|
|
1412
|
+
},
|
|
1413
|
+
{
|
|
1414
|
+
name: 'Tank Green',
|
|
1415
|
+
value: 'tank-green',
|
|
1416
|
+
},
|
|
1417
|
+
{
|
|
1418
|
+
name: 'Gun Metal',
|
|
1419
|
+
value: 'gun-metal',
|
|
1420
|
+
},
|
|
1421
|
+
{
|
|
1422
|
+
name: 'Wet Moss',
|
|
1423
|
+
value: 'wet-moss',
|
|
1424
|
+
},
|
|
1425
|
+
{
|
|
1426
|
+
name: 'Red Burgundy',
|
|
1427
|
+
value: 'red-burgundy',
|
|
1428
|
+
},
|
|
1429
|
+
{
|
|
1430
|
+
name: 'Light Concrete',
|
|
1431
|
+
value: 'light-concrete',
|
|
1432
|
+
},
|
|
1433
|
+
{
|
|
1434
|
+
name: 'Apricot Red',
|
|
1435
|
+
value: 'apricot-red',
|
|
1436
|
+
},
|
|
1437
|
+
{
|
|
1438
|
+
name: 'Desert Sand',
|
|
1439
|
+
value: 'desert-sand',
|
|
1440
|
+
},
|
|
1441
|
+
{
|
|
1442
|
+
name: 'Navy Blue',
|
|
1443
|
+
value: 'navy-blue',
|
|
1444
|
+
},
|
|
1445
|
+
{
|
|
1446
|
+
name: 'Egg Yellow',
|
|
1447
|
+
value: 'egg-yellow',
|
|
1448
|
+
},
|
|
1449
|
+
{
|
|
1450
|
+
name: 'Coral Green',
|
|
1451
|
+
value: 'coral-green',
|
|
1452
|
+
},
|
|
1453
|
+
{
|
|
1454
|
+
name: 'Light Cocoa',
|
|
1455
|
+
value: 'light-cocoa',
|
|
1456
|
+
},
|
|
1457
|
+
],
|
|
1458
|
+
default: 'berry-red',
|
|
1459
|
+
description: 'Color of the list',
|
|
1460
|
+
},
|
|
1461
|
+
// Operaciones para Card Memberships
|
|
1462
|
+
{
|
|
1463
|
+
displayName: 'Operation',
|
|
1464
|
+
name: 'operation',
|
|
1465
|
+
type: 'options',
|
|
1466
|
+
displayOptions: {
|
|
1467
|
+
show: {
|
|
1468
|
+
resource: [
|
|
1469
|
+
'cardMembership',
|
|
1470
|
+
],
|
|
1471
|
+
},
|
|
1472
|
+
},
|
|
1473
|
+
options: [
|
|
1474
|
+
{
|
|
1475
|
+
name: 'Add Member to Card',
|
|
1476
|
+
value: 'addCardMember',
|
|
1477
|
+
description: 'Add a member to a card',
|
|
1478
|
+
action: 'Add a member to a card',
|
|
1479
|
+
},
|
|
1480
|
+
{
|
|
1481
|
+
name: 'Remove Member from Card',
|
|
1482
|
+
value: 'removeCardMember',
|
|
1483
|
+
description: 'Remove a member from a card',
|
|
1484
|
+
action: 'Remove a member from a card',
|
|
1485
|
+
},
|
|
1486
|
+
],
|
|
1487
|
+
default: 'addCardMember',
|
|
1488
|
+
},
|
|
1489
|
+
// Card Membership fields
|
|
1490
|
+
{
|
|
1491
|
+
displayName: 'Card ID',
|
|
1492
|
+
name: 'cardId',
|
|
1493
|
+
type: 'string',
|
|
1494
|
+
displayOptions: {
|
|
1495
|
+
show: {
|
|
1496
|
+
resource: [
|
|
1497
|
+
'cardMembership',
|
|
1498
|
+
],
|
|
1499
|
+
operation: [
|
|
1500
|
+
'addCardMember',
|
|
1501
|
+
'removeCardMember',
|
|
1502
|
+
],
|
|
1503
|
+
},
|
|
1504
|
+
},
|
|
1505
|
+
required: true,
|
|
1506
|
+
default: '',
|
|
1507
|
+
description: 'The ID of the card',
|
|
1508
|
+
},
|
|
1509
|
+
{
|
|
1510
|
+
displayName: 'User ID',
|
|
1511
|
+
name: 'userId',
|
|
1512
|
+
type: 'string',
|
|
1513
|
+
displayOptions: {
|
|
1514
|
+
show: {
|
|
1515
|
+
resource: [
|
|
1516
|
+
'cardMembership',
|
|
1517
|
+
],
|
|
1518
|
+
operation: [
|
|
1519
|
+
'addCardMember',
|
|
1520
|
+
'removeCardMember',
|
|
1521
|
+
],
|
|
1522
|
+
},
|
|
1523
|
+
},
|
|
1524
|
+
required: true,
|
|
1525
|
+
default: '',
|
|
1526
|
+
description: 'The ID of the user to add/remove',
|
|
1527
|
+
},
|
|
1528
|
+
// Operaciones para Card Labels
|
|
1529
|
+
{
|
|
1530
|
+
displayName: 'Operation',
|
|
1531
|
+
name: 'operation',
|
|
1532
|
+
type: 'options',
|
|
1533
|
+
displayOptions: {
|
|
1534
|
+
show: {
|
|
1535
|
+
resource: [
|
|
1536
|
+
'cardLabel',
|
|
1537
|
+
],
|
|
1538
|
+
},
|
|
1539
|
+
},
|
|
1540
|
+
options: [
|
|
1541
|
+
{
|
|
1542
|
+
name: 'Add Label to Card',
|
|
1543
|
+
value: 'addCardLabel',
|
|
1544
|
+
description: 'Add a label to a card',
|
|
1545
|
+
action: 'Add a label to a card',
|
|
1546
|
+
},
|
|
1547
|
+
{
|
|
1548
|
+
name: 'Remove Label from Card',
|
|
1549
|
+
value: 'removeCardLabel',
|
|
1550
|
+
description: 'Remove a label from a card',
|
|
1551
|
+
action: 'Remove a label from a card',
|
|
1552
|
+
},
|
|
1553
|
+
],
|
|
1554
|
+
default: 'addCardLabel',
|
|
1555
|
+
},
|
|
1556
|
+
// Card Label fields
|
|
1557
|
+
{
|
|
1558
|
+
displayName: 'Card ID',
|
|
1559
|
+
name: 'cardId',
|
|
1560
|
+
type: 'string',
|
|
1561
|
+
displayOptions: {
|
|
1562
|
+
show: {
|
|
1563
|
+
resource: [
|
|
1564
|
+
'cardLabel',
|
|
1565
|
+
],
|
|
1566
|
+
operation: [
|
|
1567
|
+
'addCardLabel',
|
|
1568
|
+
'removeCardLabel',
|
|
1569
|
+
],
|
|
1570
|
+
},
|
|
1571
|
+
},
|
|
1572
|
+
required: true,
|
|
1573
|
+
default: '',
|
|
1574
|
+
description: 'The ID of the card',
|
|
1575
|
+
},
|
|
1576
|
+
{
|
|
1577
|
+
displayName: 'Label ID',
|
|
1578
|
+
name: 'labelId',
|
|
1579
|
+
type: 'string',
|
|
1580
|
+
displayOptions: {
|
|
1581
|
+
show: {
|
|
1582
|
+
resource: [
|
|
1583
|
+
'cardLabel',
|
|
1584
|
+
],
|
|
1585
|
+
operation: [
|
|
1586
|
+
'addCardLabel',
|
|
1587
|
+
'removeCardLabel',
|
|
1588
|
+
],
|
|
1589
|
+
},
|
|
1590
|
+
},
|
|
1591
|
+
required: true,
|
|
1592
|
+
default: '',
|
|
1593
|
+
description: 'The ID of the label to add/remove',
|
|
1594
|
+
},
|
|
1595
|
+
// Operaciones para Card Tasks
|
|
1596
|
+
{
|
|
1597
|
+
displayName: 'Operation',
|
|
1598
|
+
name: 'operation',
|
|
1599
|
+
type: 'options',
|
|
1600
|
+
displayOptions: {
|
|
1601
|
+
show: {
|
|
1602
|
+
resource: [
|
|
1603
|
+
'cardTask',
|
|
1604
|
+
],
|
|
1605
|
+
},
|
|
1606
|
+
},
|
|
1607
|
+
options: [
|
|
1608
|
+
{
|
|
1609
|
+
name: 'Create a Task in a Card',
|
|
1610
|
+
value: 'createCardTask',
|
|
1611
|
+
description: 'Create a task in a card',
|
|
1612
|
+
action: 'Create a task in a card',
|
|
1613
|
+
},
|
|
1614
|
+
{
|
|
1615
|
+
name: 'Update a Task',
|
|
1616
|
+
value: 'updateCardTask',
|
|
1617
|
+
description: 'Update a task',
|
|
1618
|
+
action: 'Update a task',
|
|
1619
|
+
},
|
|
1620
|
+
{
|
|
1621
|
+
name: 'Delete a Task',
|
|
1622
|
+
value: 'deleteCardTask',
|
|
1623
|
+
description: 'Delete a task',
|
|
1624
|
+
action: 'Delete a task',
|
|
1625
|
+
},
|
|
1626
|
+
],
|
|
1627
|
+
default: 'createCardTask',
|
|
1628
|
+
},
|
|
1629
|
+
// Card Task fields - Removing duplicated fields
|
|
1630
|
+
{
|
|
1631
|
+
displayName: 'Card ID',
|
|
1632
|
+
name: 'cardId',
|
|
1633
|
+
type: 'string',
|
|
1634
|
+
displayOptions: {
|
|
1635
|
+
show: {
|
|
1636
|
+
resource: [
|
|
1637
|
+
'cardTask',
|
|
1638
|
+
],
|
|
1639
|
+
operation: [
|
|
1640
|
+
'createCardTask',
|
|
1641
|
+
],
|
|
1642
|
+
},
|
|
1643
|
+
},
|
|
1644
|
+
required: true,
|
|
1645
|
+
default: '',
|
|
1646
|
+
description: 'The ID of the card to create the task in',
|
|
1647
|
+
},
|
|
1648
|
+
{
|
|
1649
|
+
displayName: 'Task ID',
|
|
1650
|
+
name: 'taskId',
|
|
1651
|
+
type: 'string',
|
|
1652
|
+
displayOptions: {
|
|
1653
|
+
show: {
|
|
1654
|
+
resource: [
|
|
1655
|
+
'cardTask',
|
|
1656
|
+
],
|
|
1657
|
+
operation: [
|
|
1658
|
+
'updateCardTask',
|
|
1659
|
+
'deleteCardTask',
|
|
1660
|
+
],
|
|
1661
|
+
},
|
|
1662
|
+
},
|
|
1663
|
+
required: true,
|
|
1664
|
+
default: '',
|
|
1665
|
+
description: 'The ID of the task',
|
|
1666
|
+
},
|
|
1667
|
+
{
|
|
1668
|
+
displayName: 'Task Name',
|
|
1669
|
+
name: 'taskName',
|
|
1670
|
+
type: 'string',
|
|
1671
|
+
displayOptions: {
|
|
1672
|
+
show: {
|
|
1673
|
+
resource: [
|
|
1674
|
+
'cardTask',
|
|
1675
|
+
],
|
|
1676
|
+
operation: [
|
|
1677
|
+
'createCardTask',
|
|
1678
|
+
'updateCardTask',
|
|
1679
|
+
],
|
|
1680
|
+
},
|
|
1681
|
+
},
|
|
1682
|
+
required: true,
|
|
1683
|
+
default: '',
|
|
1684
|
+
description: 'Name of the task',
|
|
1685
|
+
},
|
|
1686
|
+
// Task additional fields
|
|
1687
|
+
{
|
|
1688
|
+
displayName: 'Task Position',
|
|
1689
|
+
name: 'taskPosition',
|
|
1690
|
+
type: 'number',
|
|
1691
|
+
default: 1,
|
|
1692
|
+
displayOptions: {
|
|
1693
|
+
show: {
|
|
1694
|
+
resource: ['cardTask'],
|
|
1695
|
+
operation: ['createCardTask', 'updateCardTask'],
|
|
1696
|
+
},
|
|
1697
|
+
},
|
|
1698
|
+
description: 'Position of the task in the card',
|
|
1699
|
+
},
|
|
1700
|
+
{
|
|
1701
|
+
displayName: 'Is Completed',
|
|
1702
|
+
name: 'taskIsCompleted',
|
|
1703
|
+
type: 'boolean',
|
|
1704
|
+
default: false,
|
|
1705
|
+
displayOptions: {
|
|
1706
|
+
show: {
|
|
1707
|
+
resource: ['cardTask'],
|
|
1708
|
+
operation: ['createCardTask', 'updateCardTask'],
|
|
1709
|
+
},
|
|
1710
|
+
},
|
|
1711
|
+
description: 'Whether the task is completed',
|
|
1712
|
+
},
|
|
1713
|
+
// Operaciones para Card Attachments
|
|
1714
|
+
{
|
|
1715
|
+
displayName: 'Operation',
|
|
1716
|
+
name: 'operation',
|
|
1717
|
+
type: 'options',
|
|
1718
|
+
displayOptions: {
|
|
1719
|
+
show: {
|
|
1720
|
+
resource: [
|
|
1721
|
+
'cardAttachment',
|
|
1722
|
+
],
|
|
1723
|
+
},
|
|
1724
|
+
},
|
|
1725
|
+
options: [
|
|
1726
|
+
{
|
|
1727
|
+
name: 'Create an Attachment in a Card',
|
|
1728
|
+
value: 'createCardAttachment',
|
|
1729
|
+
description: 'Create an attachment in a card',
|
|
1730
|
+
action: 'Create an attachment in a card',
|
|
1731
|
+
},
|
|
1732
|
+
{
|
|
1733
|
+
name: 'Update an Attachment',
|
|
1734
|
+
value: 'updateCardAttachment',
|
|
1735
|
+
description: 'Update an attachment',
|
|
1736
|
+
action: 'Update an attachment',
|
|
1737
|
+
},
|
|
1738
|
+
{
|
|
1739
|
+
name: 'Delete an Attachment',
|
|
1740
|
+
value: 'deleteCardAttachment',
|
|
1741
|
+
description: 'Delete an attachment',
|
|
1742
|
+
action: 'Delete an attachment',
|
|
1743
|
+
},
|
|
1744
|
+
],
|
|
1745
|
+
default: 'createCardAttachment',
|
|
1746
|
+
},
|
|
1747
|
+
// Card Attachment fields
|
|
1748
|
+
{
|
|
1749
|
+
displayName: 'Card ID',
|
|
1750
|
+
name: 'cardId',
|
|
1751
|
+
type: 'string',
|
|
1752
|
+
displayOptions: {
|
|
1753
|
+
show: {
|
|
1754
|
+
resource: [
|
|
1755
|
+
'card',
|
|
1756
|
+
],
|
|
1757
|
+
operation: [
|
|
1758
|
+
'createCardAttachment',
|
|
1759
|
+
],
|
|
1760
|
+
},
|
|
1761
|
+
},
|
|
1762
|
+
required: true,
|
|
1763
|
+
default: '',
|
|
1764
|
+
description: 'The ID of the card to create the attachment in',
|
|
1765
|
+
},
|
|
1766
|
+
{
|
|
1767
|
+
displayName: 'Attachment ID',
|
|
1768
|
+
name: 'attachmentId',
|
|
1769
|
+
type: 'string',
|
|
1770
|
+
displayOptions: {
|
|
1771
|
+
show: {
|
|
1772
|
+
resource: [
|
|
1773
|
+
'card',
|
|
1774
|
+
],
|
|
1775
|
+
operation: [
|
|
1776
|
+
'updateCardAttachment',
|
|
1777
|
+
'deleteCardAttachment',
|
|
1778
|
+
],
|
|
1779
|
+
},
|
|
1780
|
+
},
|
|
1781
|
+
required: true,
|
|
1782
|
+
default: '',
|
|
1783
|
+
description: 'The ID of the attachment',
|
|
1784
|
+
},
|
|
1785
|
+
{
|
|
1786
|
+
displayName: 'File',
|
|
1787
|
+
name: 'file',
|
|
1788
|
+
type: 'string',
|
|
1789
|
+
displayOptions: {
|
|
1790
|
+
show: {
|
|
1791
|
+
resource: [
|
|
1792
|
+
'card',
|
|
1793
|
+
],
|
|
1794
|
+
operation: [
|
|
1795
|
+
'createCardAttachment',
|
|
1796
|
+
],
|
|
1797
|
+
},
|
|
1798
|
+
},
|
|
1799
|
+
required: true,
|
|
1800
|
+
default: '',
|
|
1801
|
+
description: 'File to attach (URL or file path)',
|
|
1802
|
+
},
|
|
1803
|
+
{
|
|
1804
|
+
displayName: 'Attachment Name',
|
|
1805
|
+
name: 'attachmentName',
|
|
1806
|
+
type: 'string',
|
|
1807
|
+
displayOptions: {
|
|
1808
|
+
show: {
|
|
1809
|
+
resource: [
|
|
1810
|
+
'card',
|
|
1811
|
+
],
|
|
1812
|
+
operation: [
|
|
1813
|
+
'createCardAttachment',
|
|
1814
|
+
'updateCardAttachment',
|
|
1815
|
+
],
|
|
1816
|
+
},
|
|
1817
|
+
},
|
|
1818
|
+
required: true,
|
|
1819
|
+
default: '',
|
|
1820
|
+
description: 'Name of the attachment',
|
|
1821
|
+
},
|
|
1822
|
+
// Operaciones para Card Actions
|
|
1823
|
+
{
|
|
1824
|
+
displayName: 'Operation',
|
|
1825
|
+
name: 'operation',
|
|
1826
|
+
type: 'options',
|
|
1827
|
+
displayOptions: {
|
|
1828
|
+
show: {
|
|
1829
|
+
resource: [
|
|
1830
|
+
'cardComment',
|
|
1831
|
+
],
|
|
1832
|
+
},
|
|
1833
|
+
},
|
|
1834
|
+
options: [
|
|
1835
|
+
{
|
|
1836
|
+
name: 'Get All Actions of a Card',
|
|
1837
|
+
value: 'getAllCardActions',
|
|
1838
|
+
description: 'Get all actions of a card',
|
|
1839
|
+
action: 'Get all actions of a card',
|
|
1840
|
+
},
|
|
1841
|
+
{
|
|
1842
|
+
name: 'Create Comment on a Card',
|
|
1843
|
+
value: 'createCardComment',
|
|
1844
|
+
description: 'Create a comment on a card',
|
|
1845
|
+
action: 'Create a comment on a card',
|
|
1846
|
+
},
|
|
1847
|
+
{
|
|
1848
|
+
name: 'Update Comment on a Card',
|
|
1849
|
+
value: 'updateCardComment',
|
|
1850
|
+
description: 'Update a comment on a card',
|
|
1851
|
+
action: 'Update a comment on a card',
|
|
1852
|
+
},
|
|
1853
|
+
{
|
|
1854
|
+
name: 'Delete Comment from a Card',
|
|
1855
|
+
value: 'deleteCardComment',
|
|
1856
|
+
description: 'Delete a comment from a card',
|
|
1857
|
+
action: 'Delete a comment from a card',
|
|
1858
|
+
},
|
|
1859
|
+
],
|
|
1860
|
+
default: 'getAllCardActions',
|
|
1861
|
+
},
|
|
1862
|
+
// Card Action fields
|
|
1863
|
+
{
|
|
1864
|
+
displayName: 'Card ID',
|
|
1865
|
+
name: 'cardId',
|
|
1866
|
+
type: 'string',
|
|
1867
|
+
displayOptions: {
|
|
1868
|
+
show: {
|
|
1869
|
+
resource: [
|
|
1870
|
+
'card',
|
|
1871
|
+
],
|
|
1872
|
+
operation: [
|
|
1873
|
+
'getAllCardActions',
|
|
1874
|
+
'createCardComment',
|
|
1875
|
+
],
|
|
1876
|
+
},
|
|
1877
|
+
},
|
|
1878
|
+
required: true,
|
|
1879
|
+
default: '',
|
|
1880
|
+
description: 'The ID of the card',
|
|
1881
|
+
},
|
|
1882
|
+
{
|
|
1883
|
+
displayName: 'Comment ID',
|
|
1884
|
+
name: 'commentId',
|
|
1885
|
+
type: 'string',
|
|
1886
|
+
displayOptions: {
|
|
1887
|
+
show: {
|
|
1888
|
+
resource: [
|
|
1889
|
+
'card',
|
|
1890
|
+
],
|
|
1891
|
+
operation: [
|
|
1892
|
+
'updateCardComment',
|
|
1893
|
+
'deleteCardComment',
|
|
1894
|
+
],
|
|
1895
|
+
},
|
|
1896
|
+
},
|
|
1897
|
+
required: true,
|
|
1898
|
+
default: '',
|
|
1899
|
+
description: 'The ID of the comment',
|
|
1900
|
+
},
|
|
1901
|
+
{
|
|
1902
|
+
displayName: 'Comment Text',
|
|
1903
|
+
name: 'commentText',
|
|
1904
|
+
type: 'string',
|
|
1905
|
+
displayOptions: {
|
|
1906
|
+
show: {
|
|
1907
|
+
resource: [
|
|
1908
|
+
'card',
|
|
1909
|
+
],
|
|
1910
|
+
operation: [
|
|
1911
|
+
'createCardComment',
|
|
1912
|
+
'updateCardComment',
|
|
1913
|
+
],
|
|
1914
|
+
},
|
|
1915
|
+
},
|
|
1916
|
+
required: true,
|
|
1917
|
+
default: '',
|
|
1918
|
+
description: 'The text content of the comment',
|
|
1919
|
+
},
|
|
1920
|
+
{
|
|
1921
|
+
displayName: 'With Details',
|
|
1922
|
+
name: 'withDetails',
|
|
1923
|
+
type: 'boolean',
|
|
1924
|
+
default: false,
|
|
1925
|
+
displayOptions: {
|
|
1926
|
+
show: {
|
|
1927
|
+
resource: ['card'],
|
|
1928
|
+
operation: ['getAllCardActions'],
|
|
1929
|
+
},
|
|
1930
|
+
},
|
|
1931
|
+
description: 'Whether to include additional details in the response',
|
|
1932
|
+
},
|
|
1933
|
+
// Operaciones para Project Managers
|
|
1934
|
+
{
|
|
1935
|
+
displayName: 'Operation',
|
|
1936
|
+
name: 'operation',
|
|
1937
|
+
type: 'options',
|
|
1938
|
+
displayOptions: {
|
|
1939
|
+
show: {
|
|
1940
|
+
resource: [
|
|
1941
|
+
'projectManager',
|
|
1942
|
+
],
|
|
1943
|
+
},
|
|
1944
|
+
},
|
|
1945
|
+
options: [
|
|
1946
|
+
{
|
|
1947
|
+
name: 'Add Manager to Project',
|
|
1948
|
+
value: 'addProjectManager',
|
|
1949
|
+
description: 'Add a manager to a project',
|
|
1950
|
+
action: 'Add a manager to a project',
|
|
1951
|
+
},
|
|
1952
|
+
{
|
|
1953
|
+
name: 'Remove Manager from Project',
|
|
1954
|
+
value: 'deleteProjectManager',
|
|
1955
|
+
description: 'Delete a project manager',
|
|
1956
|
+
action: 'Delete a project manager',
|
|
1957
|
+
},
|
|
1958
|
+
],
|
|
1959
|
+
default: 'addProjectManager',
|
|
1960
|
+
},
|
|
1961
|
+
// Project Manager fields
|
|
1962
|
+
{
|
|
1963
|
+
displayName: 'Project ID',
|
|
1964
|
+
name: 'projectId',
|
|
1965
|
+
type: 'string',
|
|
1966
|
+
displayOptions: {
|
|
1967
|
+
show: {
|
|
1968
|
+
resource: [
|
|
1969
|
+
'project',
|
|
1970
|
+
],
|
|
1971
|
+
operation: [
|
|
1972
|
+
'addProjectManager',
|
|
1973
|
+
],
|
|
1974
|
+
},
|
|
1975
|
+
},
|
|
1976
|
+
required: true,
|
|
1977
|
+
default: '',
|
|
1978
|
+
description: 'Project ID to which the administrator will be added',
|
|
1979
|
+
},
|
|
1980
|
+
{
|
|
1981
|
+
displayName: 'User ID',
|
|
1982
|
+
name: 'userId',
|
|
1983
|
+
type: 'string',
|
|
1984
|
+
displayOptions: {
|
|
1985
|
+
show: {
|
|
1986
|
+
resource: [
|
|
1987
|
+
'project',
|
|
1988
|
+
],
|
|
1989
|
+
operation: [
|
|
1990
|
+
'addProjectManager',
|
|
1991
|
+
],
|
|
1992
|
+
},
|
|
1993
|
+
},
|
|
1994
|
+
required: true,
|
|
1995
|
+
default: '',
|
|
1996
|
+
description: 'User ID that will be added as administrator',
|
|
1997
|
+
},
|
|
1998
|
+
{
|
|
1999
|
+
displayName: 'Manager ID',
|
|
2000
|
+
name: 'managerId',
|
|
2001
|
+
type: 'string',
|
|
2002
|
+
displayOptions: {
|
|
2003
|
+
show: {
|
|
2004
|
+
resource: [
|
|
2005
|
+
'project',
|
|
2006
|
+
],
|
|
2007
|
+
operation: [
|
|
2008
|
+
'deleteProjectManager',
|
|
2009
|
+
],
|
|
2010
|
+
},
|
|
2011
|
+
},
|
|
2012
|
+
required: true,
|
|
2013
|
+
default: '',
|
|
2014
|
+
description: 'ID of the project manager to be deleted',
|
|
2015
|
+
},
|
|
2016
|
+
// Card Member fields
|
|
2017
|
+
{
|
|
2018
|
+
displayName: 'Card ID',
|
|
2019
|
+
name: 'cardId',
|
|
2020
|
+
type: 'string',
|
|
2021
|
+
displayOptions: {
|
|
2022
|
+
show: {
|
|
2023
|
+
resource: [
|
|
2024
|
+
'card',
|
|
2025
|
+
],
|
|
2026
|
+
operation: [
|
|
2027
|
+
'addCardMember',
|
|
2028
|
+
],
|
|
2029
|
+
},
|
|
2030
|
+
},
|
|
2031
|
+
required: true,
|
|
2032
|
+
default: '',
|
|
2033
|
+
description: 'ID of the card where the member will be added',
|
|
2034
|
+
},
|
|
2035
|
+
{
|
|
2036
|
+
displayName: 'User ID',
|
|
2037
|
+
name: 'userId',
|
|
2038
|
+
type: 'string',
|
|
2039
|
+
displayOptions: {
|
|
2040
|
+
show: {
|
|
2041
|
+
resource: [
|
|
2042
|
+
'card',
|
|
2043
|
+
],
|
|
2044
|
+
operation: [
|
|
2045
|
+
'addCardMember',
|
|
2046
|
+
'removeCardMember',
|
|
2047
|
+
],
|
|
2048
|
+
},
|
|
2049
|
+
},
|
|
2050
|
+
required: true,
|
|
2051
|
+
default: '',
|
|
2052
|
+
description: 'ID of the user to be added/removed from the card',
|
|
2053
|
+
},
|
|
2054
|
+
// Card Label fields for the card resource
|
|
2055
|
+
{
|
|
2056
|
+
displayName: 'Card ID',
|
|
2057
|
+
name: 'cardId',
|
|
2058
|
+
type: 'string',
|
|
2059
|
+
displayOptions: {
|
|
2060
|
+
show: {
|
|
2061
|
+
resource: [
|
|
2062
|
+
'card',
|
|
2063
|
+
],
|
|
2064
|
+
operation: [
|
|
2065
|
+
'addCardLabel',
|
|
2066
|
+
'removeCardLabel',
|
|
2067
|
+
],
|
|
2068
|
+
},
|
|
2069
|
+
},
|
|
2070
|
+
required: true,
|
|
2071
|
+
default: '',
|
|
2072
|
+
description: 'ID of the card',
|
|
2073
|
+
},
|
|
2074
|
+
{
|
|
2075
|
+
displayName: 'Label ID',
|
|
2076
|
+
name: 'labelId',
|
|
2077
|
+
type: 'string',
|
|
2078
|
+
displayOptions: {
|
|
2079
|
+
show: {
|
|
2080
|
+
resource: [
|
|
2081
|
+
'card',
|
|
2082
|
+
],
|
|
2083
|
+
operation: [
|
|
2084
|
+
'addCardLabel',
|
|
2085
|
+
'removeCardLabel',
|
|
2086
|
+
],
|
|
2087
|
+
},
|
|
2088
|
+
},
|
|
2089
|
+
required: true,
|
|
2090
|
+
default: '',
|
|
2091
|
+
description: 'ID of the label to add/remove',
|
|
2092
|
+
},
|
|
2093
|
+
],
|
|
2094
|
+
};
|
|
2095
|
+
}
|
|
2096
|
+
async execute() {
|
|
2097
|
+
const items = this.getInputData();
|
|
2098
|
+
const returnData = [];
|
|
2099
|
+
const resource = this.getNodeParameter('resource', 0);
|
|
2100
|
+
const operation = this.getNodeParameter('operation', 0);
|
|
2101
|
+
let responseData;
|
|
2102
|
+
for (let i = 0; i < items.length; i++) {
|
|
2103
|
+
try {
|
|
2104
|
+
if (resource === 'project') {
|
|
2105
|
+
// *********************************************************************
|
|
2106
|
+
// PROJECT
|
|
2107
|
+
// *********************************************************************
|
|
2108
|
+
if (operation === 'createProject') {
|
|
2109
|
+
// ----------------------------------
|
|
2110
|
+
// project:create
|
|
2111
|
+
// ----------------------------------
|
|
2112
|
+
const name = this.getNodeParameter('name', i);
|
|
2113
|
+
const backgroundName = this.getNodeParameter('backgroundName', i);
|
|
2114
|
+
const backgroundType = this.getNodeParameter('backgroundType', i);
|
|
2115
|
+
const backgroundImage = this.getNodeParameter('backgroundImage', i);
|
|
2116
|
+
const body = {
|
|
2117
|
+
name,
|
|
2118
|
+
background: backgroundName,
|
|
2119
|
+
backgroundType,
|
|
2120
|
+
backgroundImage,
|
|
2121
|
+
};
|
|
2122
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'POST', '/projects', body);
|
|
2123
|
+
}
|
|
2124
|
+
else if (operation === 'deleteProject') {
|
|
2125
|
+
// ----------------------------------
|
|
2126
|
+
// project:delete
|
|
2127
|
+
// ----------------------------------
|
|
2128
|
+
const projectId = this.getNodeParameter('projectId', i);
|
|
2129
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'DELETE', `/projects/${projectId}`);
|
|
2130
|
+
}
|
|
2131
|
+
else if (operation === 'getProject') {
|
|
2132
|
+
// ----------------------------------
|
|
2133
|
+
// project:get
|
|
2134
|
+
// ----------------------------------
|
|
2135
|
+
const projectId = this.getNodeParameter('projectId', i);
|
|
2136
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'GET', `/projects/${projectId}`);
|
|
2137
|
+
}
|
|
2138
|
+
else if (operation === 'getAllProjects') {
|
|
2139
|
+
// ----------------------------------
|
|
2140
|
+
// project:getAll
|
|
2141
|
+
// ----------------------------------
|
|
2142
|
+
responseData = await GenericFunctions_1.plankaApiRequestAllItems.call(this, 'GET', '/projects');
|
|
2143
|
+
}
|
|
2144
|
+
else if (operation === 'updateProject') {
|
|
2145
|
+
// ----------------------------------
|
|
2146
|
+
// project:update
|
|
2147
|
+
// ----------------------------------
|
|
2148
|
+
const projectId = this.getNodeParameter('projectId', i);
|
|
2149
|
+
const name = this.getNodeParameter('name', i);
|
|
2150
|
+
const backgroundName = this.getNodeParameter('backgroundName', i);
|
|
2151
|
+
const backgroundType = this.getNodeParameter('backgroundType', i);
|
|
2152
|
+
const backgroundImage = this.getNodeParameter('backgroundImage', i);
|
|
2153
|
+
const body = {
|
|
2154
|
+
name,
|
|
2155
|
+
background: backgroundName,
|
|
2156
|
+
backgroundType,
|
|
2157
|
+
backgroundImage,
|
|
2158
|
+
};
|
|
2159
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'PATCH', `/projects/${projectId}`, body);
|
|
2160
|
+
}
|
|
2161
|
+
else if (operation === 'updateProjectBackgroundImage') {
|
|
2162
|
+
// ----------------------------------
|
|
2163
|
+
// project:updateBackgroundImage
|
|
2164
|
+
// ----------------------------------
|
|
2165
|
+
const projectId = this.getNodeParameter('projectId', i);
|
|
2166
|
+
const backgroundImageFile = this.getNodeParameter('backgroundImageFile', i);
|
|
2167
|
+
const formData = {
|
|
2168
|
+
file: backgroundImageFile,
|
|
2169
|
+
};
|
|
2170
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'PATCH', `/projects/${projectId}/background-image`, formData, {
|
|
2171
|
+
headers: {
|
|
2172
|
+
'Content-Type': 'multipart/form-data',
|
|
2173
|
+
},
|
|
2174
|
+
});
|
|
2175
|
+
}
|
|
2176
|
+
}
|
|
2177
|
+
else if (resource === 'projectManager') {
|
|
2178
|
+
// *********************************************************************
|
|
2179
|
+
// PROJECT MANAGER
|
|
2180
|
+
// *********************************************************************
|
|
2181
|
+
if (operation === 'addProjectManager') {
|
|
2182
|
+
// ----------------------------------
|
|
2183
|
+
// projectManager:add
|
|
2184
|
+
// ----------------------------------
|
|
2185
|
+
const projectId = this.getNodeParameter('projectId', i);
|
|
2186
|
+
const userId = this.getNodeParameter('userId', i);
|
|
2187
|
+
const body = {
|
|
2188
|
+
userId,
|
|
2189
|
+
};
|
|
2190
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'POST', `/projects/${projectId}/managers`, body);
|
|
2191
|
+
}
|
|
2192
|
+
else if (operation === 'deleteProjectManager') {
|
|
2193
|
+
// ----------------------------------
|
|
2194
|
+
// projectManager:delete
|
|
2195
|
+
// ----------------------------------
|
|
2196
|
+
const managerId = this.getNodeParameter('managerId', i);
|
|
2197
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'DELETE', `/project-managers/${managerId}`);
|
|
2198
|
+
}
|
|
2199
|
+
}
|
|
2200
|
+
else if (resource === 'board') {
|
|
2201
|
+
// *********************************************************************
|
|
2202
|
+
// BOARD
|
|
2203
|
+
// *********************************************************************
|
|
2204
|
+
if (operation === 'createBoard') {
|
|
2205
|
+
// ----------------------------------
|
|
2206
|
+
// board:create
|
|
2207
|
+
// ----------------------------------
|
|
2208
|
+
const projectId = this.getNodeParameter('projectId', i);
|
|
2209
|
+
const name = this.getNodeParameter('name', i);
|
|
2210
|
+
const position = this.getNodeParameter('position', i);
|
|
2211
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'POST', `/projects/${projectId}/boards`, {
|
|
2212
|
+
name,
|
|
2213
|
+
position,
|
|
2214
|
+
});
|
|
2215
|
+
}
|
|
2216
|
+
else if (operation === 'deleteBoard') {
|
|
2217
|
+
// ----------------------------------
|
|
2218
|
+
// board:delete
|
|
2219
|
+
// ----------------------------------
|
|
2220
|
+
const boardId = this.getNodeParameter('boardId', i);
|
|
2221
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'DELETE', `/boards/${boardId}`);
|
|
2222
|
+
}
|
|
2223
|
+
else if (operation === 'getBoard') {
|
|
2224
|
+
// ----------------------------------
|
|
2225
|
+
// board:get
|
|
2226
|
+
// ----------------------------------
|
|
2227
|
+
const boardId = this.getNodeParameter('boardId', i);
|
|
2228
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'GET', `/boards/${boardId}`);
|
|
2229
|
+
}
|
|
2230
|
+
else if (operation === 'updateBoard') {
|
|
2231
|
+
// ----------------------------------
|
|
2232
|
+
// board:update
|
|
2233
|
+
// ----------------------------------
|
|
2234
|
+
const boardId = this.getNodeParameter('boardId', i);
|
|
2235
|
+
const updateFields = {
|
|
2236
|
+
name: this.getNodeParameter('name', i),
|
|
2237
|
+
position: this.getNodeParameter('position', i),
|
|
2238
|
+
};
|
|
2239
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'PATCH', `/boards/${boardId}`, updateFields);
|
|
2240
|
+
}
|
|
2241
|
+
}
|
|
2242
|
+
else if (resource === 'boardMembership') {
|
|
2243
|
+
// *********************************************************************
|
|
2244
|
+
// BOARD MEMBERSHIP
|
|
2245
|
+
// *********************************************************************
|
|
2246
|
+
if (operation === 'createBoardMembership') {
|
|
2247
|
+
// ----------------------------------
|
|
2248
|
+
// boardMembership:create
|
|
2249
|
+
// ----------------------------------
|
|
2250
|
+
const boardId = this.getNodeParameter('boardId', i);
|
|
2251
|
+
const userId = this.getNodeParameter('userId', i);
|
|
2252
|
+
const role = this.getNodeParameter('role', i);
|
|
2253
|
+
const canComment = this.getNodeParameter('canComment', i);
|
|
2254
|
+
const body = {
|
|
2255
|
+
userId,
|
|
2256
|
+
role,
|
|
2257
|
+
canComment,
|
|
2258
|
+
};
|
|
2259
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'POST', `/boards/${boardId}/memberships`, body);
|
|
2260
|
+
}
|
|
2261
|
+
else if (operation === 'deleteBoardMembership') {
|
|
2262
|
+
// ----------------------------------
|
|
2263
|
+
// boardMembership:delete
|
|
2264
|
+
// ----------------------------------
|
|
2265
|
+
const membershipId = this.getNodeParameter('membershipId', i);
|
|
2266
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'DELETE', `/boards/membership/${membershipId}`);
|
|
2267
|
+
}
|
|
2268
|
+
else if (operation === 'updateBoardMembership') {
|
|
2269
|
+
// ----------------------------------
|
|
2270
|
+
// boardMembership:update
|
|
2271
|
+
// ----------------------------------
|
|
2272
|
+
const membershipId = this.getNodeParameter('membershipId', i);
|
|
2273
|
+
const userId = this.getNodeParameter('userId', i);
|
|
2274
|
+
const role = this.getNodeParameter('role', i);
|
|
2275
|
+
const canComment = this.getNodeParameter('canComment', i);
|
|
2276
|
+
const body = {
|
|
2277
|
+
userId,
|
|
2278
|
+
role,
|
|
2279
|
+
canComment,
|
|
2280
|
+
};
|
|
2281
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'PATCH', `/boards/membership/${membershipId}`, body);
|
|
2282
|
+
}
|
|
2283
|
+
}
|
|
2284
|
+
else if (resource === 'boardList') {
|
|
2285
|
+
// *********************************************************************
|
|
2286
|
+
// BOARD LIST
|
|
2287
|
+
// *********************************************************************
|
|
2288
|
+
if (operation === 'createBoardList') {
|
|
2289
|
+
// ----------------------------------
|
|
2290
|
+
// boardList:create
|
|
2291
|
+
// ----------------------------------
|
|
2292
|
+
const boardId = this.getNodeParameter('boardId', i);
|
|
2293
|
+
const name = this.getNodeParameter('name', i);
|
|
2294
|
+
const position = this.getNodeParameter('position', i);
|
|
2295
|
+
const color = this.getNodeParameter('color', i);
|
|
2296
|
+
const body = {
|
|
2297
|
+
name,
|
|
2298
|
+
position,
|
|
2299
|
+
color,
|
|
2300
|
+
};
|
|
2301
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'POST', `/boards/${boardId}/lists`, body);
|
|
2302
|
+
}
|
|
2303
|
+
else if (operation === 'deleteBoardList') {
|
|
2304
|
+
// ----------------------------------
|
|
2305
|
+
// boardList:delete
|
|
2306
|
+
// ----------------------------------
|
|
2307
|
+
const listId = this.getNodeParameter('listId', i);
|
|
2308
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'DELETE', `/lists/${listId}`);
|
|
2309
|
+
}
|
|
2310
|
+
else if (operation === 'updateBoardList') {
|
|
2311
|
+
// ----------------------------------
|
|
2312
|
+
// boardList:update
|
|
2313
|
+
// ----------------------------------
|
|
2314
|
+
const listId = this.getNodeParameter('listId', i);
|
|
2315
|
+
const name = this.getNodeParameter('name', i);
|
|
2316
|
+
const position = this.getNodeParameter('position', i);
|
|
2317
|
+
const color = this.getNodeParameter('color', i);
|
|
2318
|
+
const body = {
|
|
2319
|
+
name,
|
|
2320
|
+
position,
|
|
2321
|
+
color,
|
|
2322
|
+
};
|
|
2323
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'PATCH', `/lists/${listId}`, body);
|
|
2324
|
+
}
|
|
2325
|
+
else if (operation === 'sortBoardList') {
|
|
2326
|
+
// ----------------------------------
|
|
2327
|
+
// boardList:sort
|
|
2328
|
+
// ----------------------------------
|
|
2329
|
+
const listId = this.getNodeParameter('listId', i);
|
|
2330
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'POST', `/lists/${listId}/sort`);
|
|
2331
|
+
}
|
|
2332
|
+
}
|
|
2333
|
+
else if (resource === 'boardLabel') {
|
|
2334
|
+
// *********************************************************************
|
|
2335
|
+
// BOARD LABEL
|
|
2336
|
+
// *********************************************************************
|
|
2337
|
+
if (operation === 'createBoardLabel') {
|
|
2338
|
+
// ----------------------------------
|
|
2339
|
+
// boardLabel:create
|
|
2340
|
+
// ----------------------------------
|
|
2341
|
+
const boardId = this.getNodeParameter('boardId', i);
|
|
2342
|
+
const name = this.getNodeParameter('name', i);
|
|
2343
|
+
const position = this.getNodeParameter('position', i);
|
|
2344
|
+
const color = this.getNodeParameter('color', i);
|
|
2345
|
+
const body = {
|
|
2346
|
+
name,
|
|
2347
|
+
position,
|
|
2348
|
+
color,
|
|
2349
|
+
};
|
|
2350
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'POST', `/boards/${boardId}/labels`, body);
|
|
2351
|
+
}
|
|
2352
|
+
else if (operation === 'deleteBoardLabel') {
|
|
2353
|
+
// ----------------------------------
|
|
2354
|
+
// boardLabel:delete
|
|
2355
|
+
// ----------------------------------
|
|
2356
|
+
const labelId = this.getNodeParameter('labelId', i);
|
|
2357
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'DELETE', `/labels/${labelId}`);
|
|
2358
|
+
}
|
|
2359
|
+
else if (operation === 'updateBoardLabel') {
|
|
2360
|
+
// ----------------------------------
|
|
2361
|
+
// boardLabel:update
|
|
2362
|
+
// ----------------------------------
|
|
2363
|
+
const labelId = this.getNodeParameter('labelId', i);
|
|
2364
|
+
const name = this.getNodeParameter('name', i);
|
|
2365
|
+
const position = this.getNodeParameter('position', i);
|
|
2366
|
+
const color = this.getNodeParameter('color', i);
|
|
2367
|
+
const body = {
|
|
2368
|
+
name,
|
|
2369
|
+
position,
|
|
2370
|
+
color,
|
|
2371
|
+
};
|
|
2372
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'PATCH', `/labels/${labelId}`, body);
|
|
2373
|
+
}
|
|
2374
|
+
}
|
|
2375
|
+
else if (resource === 'card') {
|
|
2376
|
+
// *********************************************************************
|
|
2377
|
+
// CARD
|
|
2378
|
+
// *********************************************************************
|
|
2379
|
+
if (operation === 'createCard') {
|
|
2380
|
+
// ----------------------------------
|
|
2381
|
+
// card:create
|
|
2382
|
+
// ----------------------------------
|
|
2383
|
+
const listId = this.getNodeParameter('listId', i);
|
|
2384
|
+
const name = this.getNodeParameter('name', i);
|
|
2385
|
+
const description = this.getNodeParameter('description', i);
|
|
2386
|
+
const type = this.getNodeParameter('type', i);
|
|
2387
|
+
const dueDate = this.getNodeParameter('dueDate', i);
|
|
2388
|
+
const position = this.getNodeParameter('position', i);
|
|
2389
|
+
const body = {
|
|
2390
|
+
name,
|
|
2391
|
+
description,
|
|
2392
|
+
type,
|
|
2393
|
+
dueDate,
|
|
2394
|
+
position,
|
|
2395
|
+
};
|
|
2396
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'POST', `/lists/${listId}/cards`, body);
|
|
2397
|
+
}
|
|
2398
|
+
else if (operation === 'deleteCard') {
|
|
2399
|
+
// ----------------------------------
|
|
2400
|
+
// card:delete
|
|
2401
|
+
// ----------------------------------
|
|
2402
|
+
const cardId = this.getNodeParameter('cardId', i);
|
|
2403
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'DELETE', `/cards/${cardId}`);
|
|
2404
|
+
}
|
|
2405
|
+
else if (operation === 'getCard') {
|
|
2406
|
+
// ----------------------------------
|
|
2407
|
+
// card:get
|
|
2408
|
+
// ----------------------------------
|
|
2409
|
+
const cardId = this.getNodeParameter('cardId', i);
|
|
2410
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'GET', `/cards/${cardId}`);
|
|
2411
|
+
}
|
|
2412
|
+
else if (operation === 'updateCard') {
|
|
2413
|
+
// ----------------------------------
|
|
2414
|
+
// card:update
|
|
2415
|
+
// ----------------------------------
|
|
2416
|
+
const cardId = this.getNodeParameter('cardId', i);
|
|
2417
|
+
const name = this.getNodeParameter('name', i);
|
|
2418
|
+
const description = this.getNodeParameter('description', i);
|
|
2419
|
+
const dueDate = this.getNodeParameter('dueDate', i);
|
|
2420
|
+
const position = this.getNodeParameter('position', i);
|
|
2421
|
+
const body = {
|
|
2422
|
+
name,
|
|
2423
|
+
description,
|
|
2424
|
+
dueDate,
|
|
2425
|
+
position,
|
|
2426
|
+
};
|
|
2427
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'PATCH', `/cards/${cardId}`, body);
|
|
2428
|
+
}
|
|
2429
|
+
}
|
|
2430
|
+
else if (resource === 'cardTask') {
|
|
2431
|
+
// *********************************************************************
|
|
2432
|
+
// TASK
|
|
2433
|
+
// *********************************************************************
|
|
2434
|
+
if (operation === 'createCardTask') {
|
|
2435
|
+
// ----------------------------------
|
|
2436
|
+
// task:create
|
|
2437
|
+
// ----------------------------------
|
|
2438
|
+
const cardId = this.getNodeParameter('cardId', i);
|
|
2439
|
+
const name = this.getNodeParameter('taskName', i);
|
|
2440
|
+
const position = this.getNodeParameter('taskPosition', i);
|
|
2441
|
+
const isCompleted = this.getNodeParameter('taskIsCompleted', i);
|
|
2442
|
+
const body = {
|
|
2443
|
+
name,
|
|
2444
|
+
position,
|
|
2445
|
+
isCompleted,
|
|
2446
|
+
};
|
|
2447
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'POST', `/cards/${cardId}/tasks`, body);
|
|
2448
|
+
}
|
|
2449
|
+
else if (operation === 'updateCardTask') {
|
|
2450
|
+
// ----------------------------------
|
|
2451
|
+
// task:update
|
|
2452
|
+
// ----------------------------------
|
|
2453
|
+
const taskId = this.getNodeParameter('taskId', i);
|
|
2454
|
+
const name = this.getNodeParameter('taskName', i);
|
|
2455
|
+
const position = this.getNodeParameter('taskPosition', i);
|
|
2456
|
+
const isCompleted = this.getNodeParameter('taskIsCompleted', i);
|
|
2457
|
+
const body = {
|
|
2458
|
+
name,
|
|
2459
|
+
position,
|
|
2460
|
+
isCompleted,
|
|
2461
|
+
};
|
|
2462
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'PATCH', `/tasks/${taskId}`, body);
|
|
2463
|
+
}
|
|
2464
|
+
else if (operation === 'deleteCardTask') {
|
|
2465
|
+
// ----------------------------------
|
|
2466
|
+
// task:delete
|
|
2467
|
+
// ----------------------------------
|
|
2468
|
+
const taskId = this.getNodeParameter('taskId', i);
|
|
2469
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'DELETE', `/tasks/${taskId}`);
|
|
2470
|
+
}
|
|
2471
|
+
}
|
|
2472
|
+
else if (resource === 'cardLabel') {
|
|
2473
|
+
// *********************************************************************
|
|
2474
|
+
// CARD LABEL
|
|
2475
|
+
// *********************************************************************
|
|
2476
|
+
if (operation === 'addCardLabel') {
|
|
2477
|
+
// ----------------------------------
|
|
2478
|
+
// cardLabel:add
|
|
2479
|
+
// ----------------------------------
|
|
2480
|
+
const cardId = this.getNodeParameter('cardId', i);
|
|
2481
|
+
const labelId = this.getNodeParameter('labelId', i);
|
|
2482
|
+
const body = {
|
|
2483
|
+
labelId,
|
|
2484
|
+
};
|
|
2485
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'POST', `/cards/${cardId}/labels`, body);
|
|
2486
|
+
}
|
|
2487
|
+
else if (operation === 'removeCardLabel') {
|
|
2488
|
+
// ----------------------------------
|
|
2489
|
+
// cardLabel:remove
|
|
2490
|
+
// ----------------------------------
|
|
2491
|
+
const cardId = this.getNodeParameter('cardId', i);
|
|
2492
|
+
const labelId = this.getNodeParameter('labelId', i);
|
|
2493
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'DELETE', `/cards/${cardId}/labels/${labelId}`);
|
|
2494
|
+
}
|
|
2495
|
+
}
|
|
2496
|
+
else if (resource === 'cardMembership') {
|
|
2497
|
+
// *********************************************************************
|
|
2498
|
+
// CARD MEMBERSHIP
|
|
2499
|
+
// *********************************************************************
|
|
2500
|
+
if (operation === 'addCardMember') {
|
|
2501
|
+
// ----------------------------------
|
|
2502
|
+
// cardMembership:add
|
|
2503
|
+
// ----------------------------------
|
|
2504
|
+
const cardId = this.getNodeParameter('cardId', i);
|
|
2505
|
+
const userId = this.getNodeParameter('userId', i);
|
|
2506
|
+
const body = {
|
|
2507
|
+
userId,
|
|
2508
|
+
};
|
|
2509
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'POST', `/cards/${cardId}/memberships`, body);
|
|
2510
|
+
}
|
|
2511
|
+
else if (operation === 'removeCardMember') {
|
|
2512
|
+
// ----------------------------------
|
|
2513
|
+
// cardMembership:remove
|
|
2514
|
+
// ----------------------------------
|
|
2515
|
+
const cardId = this.getNodeParameter('cardId', i);
|
|
2516
|
+
const userId = this.getNodeParameter('userId', i);
|
|
2517
|
+
const body = {
|
|
2518
|
+
userId,
|
|
2519
|
+
};
|
|
2520
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'DELETE', `/cards/${cardId}/memberships`, body);
|
|
2521
|
+
}
|
|
2522
|
+
}
|
|
2523
|
+
else if (resource === 'cardAttachment') {
|
|
2524
|
+
// *********************************************************************
|
|
2525
|
+
// CARD ATTACHMENT
|
|
2526
|
+
// *********************************************************************
|
|
2527
|
+
if (operation === 'createCardAttachment') {
|
|
2528
|
+
// ----------------------------------
|
|
2529
|
+
// cardAttachment:create
|
|
2530
|
+
// ----------------------------------
|
|
2531
|
+
const cardId = this.getNodeParameter('cardId', i);
|
|
2532
|
+
const file = this.getNodeParameter('file', i);
|
|
2533
|
+
const name = this.getNodeParameter('attachmentName', i);
|
|
2534
|
+
const formData = {
|
|
2535
|
+
file,
|
|
2536
|
+
name,
|
|
2537
|
+
};
|
|
2538
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'POST', `/cards/${cardId}/attachments`, formData, {
|
|
2539
|
+
headers: {
|
|
2540
|
+
'Content-Type': 'multipart/form-data',
|
|
2541
|
+
},
|
|
2542
|
+
});
|
|
2543
|
+
}
|
|
2544
|
+
else if (operation === 'updateCardAttachment') {
|
|
2545
|
+
// ----------------------------------
|
|
2546
|
+
// cardAttachment:update
|
|
2547
|
+
// ----------------------------------
|
|
2548
|
+
const attachmentId = this.getNodeParameter('attachmentId', i);
|
|
2549
|
+
const name = this.getNodeParameter('attachmentName', i);
|
|
2550
|
+
const body = {
|
|
2551
|
+
name,
|
|
2552
|
+
};
|
|
2553
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'PATCH', `/attachments/${attachmentId}`, body);
|
|
2554
|
+
}
|
|
2555
|
+
else if (operation === 'deleteCardAttachment') {
|
|
2556
|
+
// ----------------------------------
|
|
2557
|
+
// cardAttachment:delete
|
|
2558
|
+
// ----------------------------------
|
|
2559
|
+
const attachmentId = this.getNodeParameter('attachmentId', i);
|
|
2560
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'DELETE', `/attachments/${attachmentId}`);
|
|
2561
|
+
}
|
|
2562
|
+
}
|
|
2563
|
+
else if (resource === 'cardComment') {
|
|
2564
|
+
// *********************************************************************
|
|
2565
|
+
// CARD ACTION
|
|
2566
|
+
// *********************************************************************
|
|
2567
|
+
if (operation === 'getAllCardActions') {
|
|
2568
|
+
// ----------------------------------
|
|
2569
|
+
// cardAction:getAll
|
|
2570
|
+
// ----------------------------------
|
|
2571
|
+
const cardId = this.getNodeParameter('cardId', i);
|
|
2572
|
+
const withDetails = this.getNodeParameter('withDetails', i);
|
|
2573
|
+
const qs = {
|
|
2574
|
+
withDetails,
|
|
2575
|
+
};
|
|
2576
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'GET', `/cards/${cardId}/actions`, {}, qs);
|
|
2577
|
+
}
|
|
2578
|
+
else if (operation === 'createCardComment') {
|
|
2579
|
+
// ----------------------------------
|
|
2580
|
+
// cardAction:createComment
|
|
2581
|
+
// ----------------------------------
|
|
2582
|
+
const cardId = this.getNodeParameter('cardId', i);
|
|
2583
|
+
const text = this.getNodeParameter('commentText', i);
|
|
2584
|
+
const body = {
|
|
2585
|
+
text,
|
|
2586
|
+
};
|
|
2587
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'POST', `/cards/${cardId}/comment-actions`, body);
|
|
2588
|
+
}
|
|
2589
|
+
else if (operation === 'updateCardComment') {
|
|
2590
|
+
// ----------------------------------
|
|
2591
|
+
// cardAction:updateComment
|
|
2592
|
+
// ----------------------------------
|
|
2593
|
+
const commentId = this.getNodeParameter('commentId', i);
|
|
2594
|
+
const text = this.getNodeParameter('commentText', i);
|
|
2595
|
+
const body = {
|
|
2596
|
+
text,
|
|
2597
|
+
};
|
|
2598
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'PATCH', `/comment-actions/${commentId}`, body);
|
|
2599
|
+
}
|
|
2600
|
+
else if (operation === 'deleteCardComment') {
|
|
2601
|
+
// ----------------------------------
|
|
2602
|
+
// cardAction:deleteComment
|
|
2603
|
+
// ----------------------------------
|
|
2604
|
+
const commentId = this.getNodeParameter('commentId', i);
|
|
2605
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'DELETE', `/comment-actions/${commentId}`);
|
|
2606
|
+
}
|
|
2607
|
+
}
|
|
2608
|
+
else if (resource === 'user') {
|
|
2609
|
+
// *********************************************************************
|
|
2610
|
+
// USER
|
|
2611
|
+
// *********************************************************************
|
|
2612
|
+
if (operation === 'createUser') {
|
|
2613
|
+
// ----------------------------------
|
|
2614
|
+
// user:create
|
|
2615
|
+
// ----------------------------------
|
|
2616
|
+
const name = this.getNodeParameter('name', i);
|
|
2617
|
+
const email = this.getNodeParameter('email', i);
|
|
2618
|
+
const password = this.getNodeParameter('password', i);
|
|
2619
|
+
const username = this.getNodeParameter('username', i);
|
|
2620
|
+
const phone = this.getNodeParameter('phone', i);
|
|
2621
|
+
const organization = this.getNodeParameter('organization', i);
|
|
2622
|
+
const language = this.getNodeParameter('language', i);
|
|
2623
|
+
const subscribeToOwnCards = this.getNodeParameter('subscribeToOwnCards', i);
|
|
2624
|
+
const isAdmin = this.getNodeParameter('isAdmin', i);
|
|
2625
|
+
const body = {
|
|
2626
|
+
name,
|
|
2627
|
+
email,
|
|
2628
|
+
password,
|
|
2629
|
+
username,
|
|
2630
|
+
phone,
|
|
2631
|
+
organization,
|
|
2632
|
+
language,
|
|
2633
|
+
subscribeToOwnCards,
|
|
2634
|
+
isAdmin,
|
|
2635
|
+
};
|
|
2636
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'POST', '/users', body);
|
|
2637
|
+
}
|
|
2638
|
+
else if (operation === 'deleteUser') {
|
|
2639
|
+
// ----------------------------------
|
|
2640
|
+
// user:delete
|
|
2641
|
+
// ----------------------------------
|
|
2642
|
+
const userId = this.getNodeParameter('userId', i);
|
|
2643
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'DELETE', `/users/${userId}`);
|
|
2644
|
+
}
|
|
2645
|
+
else if (operation === 'getUser') {
|
|
2646
|
+
// ----------------------------------
|
|
2647
|
+
// user:get
|
|
2648
|
+
// ----------------------------------
|
|
2649
|
+
const userId = this.getNodeParameter('userId', i);
|
|
2650
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'GET', `/users/${userId}`);
|
|
2651
|
+
}
|
|
2652
|
+
else if (operation === 'getAllUsers') {
|
|
2653
|
+
// ----------------------------------
|
|
2654
|
+
// user:getAll
|
|
2655
|
+
// ----------------------------------
|
|
2656
|
+
responseData = await GenericFunctions_1.plankaApiRequestAllItems.call(this, 'GET', '/users');
|
|
2657
|
+
}
|
|
2658
|
+
else if (operation === 'updateUser') {
|
|
2659
|
+
// ----------------------------------
|
|
2660
|
+
// user:update
|
|
2661
|
+
// ----------------------------------
|
|
2662
|
+
const userId = this.getNodeParameter('userId', i);
|
|
2663
|
+
const name = this.getNodeParameter('name', i);
|
|
2664
|
+
const email = this.getNodeParameter('email', i);
|
|
2665
|
+
const password = this.getNodeParameter('password', i);
|
|
2666
|
+
const username = this.getNodeParameter('username', i);
|
|
2667
|
+
const phone = this.getNodeParameter('phone', i);
|
|
2668
|
+
const organization = this.getNodeParameter('organization', i);
|
|
2669
|
+
const language = this.getNodeParameter('language', i);
|
|
2670
|
+
const subscribeToOwnCards = this.getNodeParameter('subscribeToOwnCards', i);
|
|
2671
|
+
const isAdmin = this.getNodeParameter('isAdmin', i);
|
|
2672
|
+
const body = {
|
|
2673
|
+
name,
|
|
2674
|
+
email,
|
|
2675
|
+
password,
|
|
2676
|
+
username,
|
|
2677
|
+
phone,
|
|
2678
|
+
organization,
|
|
2679
|
+
language,
|
|
2680
|
+
subscribeToOwnCards,
|
|
2681
|
+
isAdmin,
|
|
2682
|
+
};
|
|
2683
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'PATCH', `/users/${userId}`, body);
|
|
2684
|
+
}
|
|
2685
|
+
else if (operation === 'updateUserEmail') {
|
|
2686
|
+
// ----------------------------------
|
|
2687
|
+
// user:updateEmail
|
|
2688
|
+
// ----------------------------------
|
|
2689
|
+
const userId = this.getNodeParameter('userId', i);
|
|
2690
|
+
const email = this.getNodeParameter('email', i);
|
|
2691
|
+
const body = {
|
|
2692
|
+
email,
|
|
2693
|
+
};
|
|
2694
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'PATCH', `/users/${userId}/email`, body);
|
|
2695
|
+
}
|
|
2696
|
+
else if (operation === 'updateUserPassword') {
|
|
2697
|
+
// ----------------------------------
|
|
2698
|
+
// user:updatePassword
|
|
2699
|
+
// ----------------------------------
|
|
2700
|
+
const userId = this.getNodeParameter('userId', i);
|
|
2701
|
+
const password = this.getNodeParameter('password', i);
|
|
2702
|
+
const body = {
|
|
2703
|
+
password,
|
|
2704
|
+
};
|
|
2705
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'PATCH', `/users/${userId}/password`, body);
|
|
2706
|
+
}
|
|
2707
|
+
else if (operation === 'updateUserUsername') {
|
|
2708
|
+
// ----------------------------------
|
|
2709
|
+
// user:updateUsername
|
|
2710
|
+
// ----------------------------------
|
|
2711
|
+
const userId = this.getNodeParameter('userId', i);
|
|
2712
|
+
const username = this.getNodeParameter('username', i);
|
|
2713
|
+
const body = {
|
|
2714
|
+
username,
|
|
2715
|
+
};
|
|
2716
|
+
responseData = await GenericFunctions_1.plankaApiRequest.call(this, 'PATCH', `/users/${userId}/username`, body);
|
|
2717
|
+
}
|
|
2718
|
+
}
|
|
2719
|
+
if (Array.isArray(responseData)) {
|
|
2720
|
+
returnData.push.apply(returnData, responseData.map(item => ({ json: item })));
|
|
2721
|
+
}
|
|
2722
|
+
else if (responseData !== undefined) {
|
|
2723
|
+
returnData.push({ json: responseData });
|
|
2724
|
+
}
|
|
2725
|
+
}
|
|
2726
|
+
catch (error) {
|
|
2727
|
+
if (this.continueOnFail()) {
|
|
2728
|
+
if (error instanceof Error) {
|
|
2729
|
+
returnData.push({ json: { error: error.message } });
|
|
2730
|
+
}
|
|
2731
|
+
else {
|
|
2732
|
+
returnData.push({ json: { error: 'An unknown error occurred' } });
|
|
2733
|
+
}
|
|
2734
|
+
continue;
|
|
2735
|
+
}
|
|
2736
|
+
throw error;
|
|
2737
|
+
}
|
|
2738
|
+
}
|
|
2739
|
+
return [returnData];
|
|
2740
|
+
}
|
|
2741
|
+
}
|
|
2742
|
+
exports.Planka = Planka;
|
|
2743
|
+
//# sourceMappingURL=Planka.node.js.map
|