n8n-nodes-keephub 1.3.4 → 1.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (64) hide show
  1. package/README.md +152 -53
  2. package/dist/credentials/KeephubBearerApi.credentials.d.ts +11 -0
  3. package/dist/credentials/KeephubBearerApi.credentials.d.ts.map +1 -0
  4. package/dist/credentials/KeephubBearerApi.credentials.js +63 -0
  5. package/dist/credentials/KeephubBearerApi.credentials.js.map +1 -0
  6. package/dist/credentials/{KeephubApi.credentials.d.ts → KeephubLoginApi.credentials.d.ts} +2 -2
  7. package/dist/credentials/KeephubLoginApi.credentials.d.ts.map +1 -0
  8. package/dist/credentials/{KeephubApi.credentials.js → KeephubLoginApi.credentials.js} +9 -59
  9. package/dist/credentials/KeephubLoginApi.credentials.js.map +1 -0
  10. package/dist/index.d.ts +1 -0
  11. package/dist/index.d.ts.map +1 -0
  12. package/dist/index.js +5 -0
  13. package/dist/index.js.map +1 -0
  14. package/dist/nodes/Keephub/Keephub.node.d.ts.map +1 -1
  15. package/dist/nodes/Keephub/Keephub.node.js +33 -3
  16. package/dist/nodes/Keephub/Keephub.node.js.map +1 -1
  17. package/dist/nodes/Keephub/actions/content/findByContentPool.d.ts.map +1 -1
  18. package/dist/nodes/Keephub/actions/content/findByContentPool.js +1 -6
  19. package/dist/nodes/Keephub/actions/content/findByContentPool.js.map +1 -1
  20. package/dist/nodes/Keephub/actions/content/findByGroup.d.ts.map +1 -1
  21. package/dist/nodes/Keephub/actions/content/findByGroup.js +1 -6
  22. package/dist/nodes/Keephub/actions/content/findByGroup.js.map +1 -1
  23. package/dist/nodes/Keephub/actions/content/findByOrgunit.d.ts.map +1 -1
  24. package/dist/nodes/Keephub/actions/content/findByOrgunit.js +1 -6
  25. package/dist/nodes/Keephub/actions/content/findByOrgunit.js.map +1 -1
  26. package/dist/nodes/Keephub/actions/orgchart/getAncestors.d.ts.map +1 -1
  27. package/dist/nodes/Keephub/actions/orgchart/getAncestors.js +2 -1
  28. package/dist/nodes/Keephub/actions/orgchart/getAncestors.js.map +1 -1
  29. package/dist/nodes/Keephub/actions/orgchart/getChildren.d.ts.map +1 -1
  30. package/dist/nodes/Keephub/actions/orgchart/getChildren.js +12 -20
  31. package/dist/nodes/Keephub/actions/orgchart/getChildren.js.map +1 -1
  32. package/dist/nodes/Keephub/actions/task/create.d.ts.map +1 -1
  33. package/dist/nodes/Keephub/actions/task/create.js +23 -8
  34. package/dist/nodes/Keephub/actions/task/create.js.map +1 -1
  35. package/dist/nodes/Keephub/actions/task/getByOrgunit.d.ts.map +1 -1
  36. package/dist/nodes/Keephub/actions/task/getByOrgunit.js +1 -6
  37. package/dist/nodes/Keephub/actions/task/getByOrgunit.js.map +1 -1
  38. package/dist/nodes/Keephub/actions/user/findByGroup.js +3 -3
  39. package/dist/nodes/Keephub/actions/user/findByGroup.js.map +1 -1
  40. package/dist/nodes/Keephub/actions/user/findByOrgunit.js +3 -3
  41. package/dist/nodes/Keephub/actions/user/findByOrgunit.js.map +1 -1
  42. package/dist/nodes/Keephub/descriptions/ContentDescription.d.ts +2 -175
  43. package/dist/nodes/Keephub/descriptions/ContentDescription.d.ts.map +1 -1
  44. package/dist/nodes/Keephub/descriptions/ContentDescription.js +10 -16
  45. package/dist/nodes/Keephub/descriptions/ContentDescription.js.map +1 -1
  46. package/dist/nodes/Keephub/descriptions/FormSubmissionDescription.d.ts +2 -38
  47. package/dist/nodes/Keephub/descriptions/FormSubmissionDescription.d.ts.map +1 -1
  48. package/dist/nodes/Keephub/descriptions/FormSubmissionDescription.js.map +1 -1
  49. package/dist/nodes/Keephub/descriptions/OrgchartDescription.d.ts.map +1 -1
  50. package/dist/nodes/Keephub/descriptions/OrgchartDescription.js +31 -13
  51. package/dist/nodes/Keephub/descriptions/OrgchartDescription.js.map +1 -1
  52. package/dist/nodes/Keephub/descriptions/TaskDescription.d.ts +2 -194
  53. package/dist/nodes/Keephub/descriptions/TaskDescription.d.ts.map +1 -1
  54. package/dist/nodes/Keephub/descriptions/TaskDescription.js +39 -31
  55. package/dist/nodes/Keephub/descriptions/TaskDescription.js.map +1 -1
  56. package/dist/nodes/Keephub/descriptions/UserDescription.d.ts +2 -38
  57. package/dist/nodes/Keephub/descriptions/UserDescription.d.ts.map +1 -1
  58. package/dist/nodes/Keephub/descriptions/UserDescription.js.map +1 -1
  59. package/dist/nodes/Keephub/utils/helpers.d.ts.map +1 -1
  60. package/dist/nodes/Keephub/utils/helpers.js +57 -37
  61. package/dist/nodes/Keephub/utils/helpers.js.map +1 -1
  62. package/package.json +5 -3
  63. package/dist/credentials/KeephubApi.credentials.d.ts.map +0 -1
  64. package/dist/credentials/KeephubApi.credentials.js.map +0 -1
package/README.md CHANGED
@@ -82,11 +82,25 @@ npm install -g n8n-nodes-keephub
82
82
 
83
83
  ### 1️⃣ Set Up Credentials
84
84
 
85
+ Keephub supports **two separate credential types**. Choose the one that matches your setup:
86
+
87
+ **Option A — Bearer Token** (recommended for API integrations):
88
+ 1. In n8n, go to **Credentials** 🔐
89
+ 2. Create **New** → Search for **Keephub Bearer API**
90
+ 3. Fill in:
91
+ - **Client URL**: `https://yourcompany.keephub.io`
92
+ - **Bearer Token**: Your API token
93
+ - **Language** (optional): Default is `en`
94
+ 4. Test & Save ✔️
95
+
96
+ **Option B — Login Credentials** (username & password):
85
97
  1. In n8n, go to **Credentials** 🔐
86
- 2. Create **New** → Search for **Keephub API**
87
- 3. Fill in your credentials:
88
- - **Client URL**: https://yourcompany.keephub.io
89
- - **Auth Type**: Choose Bearer Token or Username/Password
98
+ 2. Create **New** → Search for **Keephub Login API**
99
+ 3. Fill in:
100
+ - **Client URL**: `https://yourcompany.keephub.io`
101
+ - **Login Name**: Your username
102
+ - **Password**: Your password
103
+ - **Token Endpoint** (optional): Custom token endpoint path
90
104
  - **Language** (optional): Default is `en`
91
105
  4. Test & Save ✔️
92
106
 
@@ -94,9 +108,10 @@ npm install -g n8n-nodes-keephub
94
108
 
95
109
  1. Click **+** to add a node
96
110
  2. Search for **Keephub**
97
- 3. Select your resource and operation
98
- 4. Configure parameters
99
- 5. Run! 🏃
111
+ 3. Select your **Authentication** method (Bearer Token or Login Credentials)
112
+ 4. Select your resource and operation
113
+ 5. Configure parameters
114
+ 6. Run! 🏃
100
115
 
101
116
  ### 3️⃣ Example: Get User Info
102
117
 
@@ -179,8 +194,8 @@ Output:
179
194
  "resource": "content",
180
195
  "operation": "findByOrgunit",
181
196
  "orgunitId": "root0077",
182
- "limit": 50,
183
197
  "options": {
198
+ "limit": 50,
184
199
  "skip": 0,
185
200
  "sortBy": "createdAt",
186
201
  "sortOrder": 1
@@ -188,17 +203,16 @@ Output:
188
203
  }
189
204
  ```
190
205
 
191
- Content Filtering Parameters:
192
-
193
- Limit (optional, default: 50): Maximum number of results to return
206
+ **Content Filtering Parameters:**
194
207
 
195
- Options:
208
+ - **Orgunit ID** (required): The organization unit ID
196
209
 
197
- Skip: Number of results to skip (pagination)
210
+ **Options** (all optional):
198
211
 
199
- Sort Field: Field to sort by (e.g., createdAt, updatedAt)
200
-
201
- Sort Order: 1 for ascending, -1 for descending
212
+ - **Limit**: Maximum number of results (default: 50)
213
+ - **Skip**: Number of results to skip (pagination)
214
+ - **Sort Field**: Field to sort by (e.g., `createdAt`, `updatedAt`)
215
+ - **Sort Order**: `1` for ascending, `-1` for descending
202
216
 
203
217
  ---
204
218
 
@@ -213,24 +227,40 @@ Sort Order: 1 for ascending, -1 for descending
213
227
  | 📊 **Get Progress** | Check task template progress |
214
228
  | 📈 **Get Status Counts** | View task completion statistics |
215
229
 
216
- **Example:**
230
+ **Example - Create Task with JSON Body:**
217
231
 
218
- ```javascript
232
+ ```json
219
233
  {
220
- "resource": "task",
221
- "operation": "create",
222
- "defineTaskInput": "json",
223
- "taskJsonBody": {
224
- "title": { "en": "Q4 Performance Review" },
225
- "template": {
226
- "form": {
227
- "fields": [
228
- { "name": "rating", "type": "number" },
229
- { "name": "feedback", "type": "text" }
230
- ]
231
- }
232
- }
233
- }
234
+ "resource": "task",
235
+ "operation": "create",
236
+ "defineTaskInput": "json",
237
+ "taskJsonBody": {
238
+ "title": { "en": "Q4 Performance Review" },
239
+ "template": {
240
+ "form": {
241
+ "fields": [
242
+ { "name": "rating", "type": "number" },
243
+ { "name": "feedback", "type": "text" }
244
+ ]
245
+ }
246
+ }
247
+ }
248
+ }
249
+ ```
250
+
251
+ **Example - Create Task with Additional Fields:**
252
+
253
+ ```json
254
+ {
255
+ "resource": "task",
256
+ "operation": "create",
257
+ "defineTaskInput": "fields",
258
+ "taskTitle": "Q4 Performance Review",
259
+ "taskType": "form",
260
+ "additionalFields": {
261
+ "taskMessage": "Please complete your review by end of quarter.",
262
+ "taskNotification": true
263
+ }
234
264
  }
235
265
  ```
236
266
 
@@ -241,8 +271,8 @@ Sort Order: 1 for ascending, -1 for descending
241
271
  "resource": "task",
242
272
  "operation": "getTaskByOrgunit",
243
273
  "orgunitId": "root0077",
244
- "limit": 50,
245
274
  "options": {
275
+ "limit": 50,
246
276
  "skip": 0,
247
277
  "sortBy": "template.dueDate",
248
278
  "sortOrder": 1,
@@ -252,23 +282,28 @@ Sort Order: 1 for ascending, -1 for descending
252
282
  }
253
283
  ```
254
284
 
255
- Parameters:
256
-
257
- Orgunit ID (required): The organization unit ID to filter tasks
285
+ **Task Create Parameters:**
258
286
 
259
- Limit (optional, default: 50): Maximum number of results to return
287
+ - **Task Title** (required): Name of the task
288
+ - **Task Type** (required): `form`, `confirmation`, or `read`
260
289
 
261
- Options:
290
+ **Additional Fields** (optional):
262
291
 
263
- Skip: Number of results to skip (pagination)
292
+ - **Message**: Custom message body for the task
293
+ - **Send Notification**: Whether to notify assigned users (`true`/`false`)
264
294
 
265
- Sort Field: Field to sort by (e.g., template.dueDate)
295
+ **Task Get by Orgunit Parameters:**
266
296
 
267
- Sort Order: 1 for ascending, -1 for descending
297
+ - **Orgunit ID** (required): The organization unit ID to filter tasks
268
298
 
269
- Start Date After: Filter tasks created/updated after this date (dateTime picker)
299
+ **Options** (all optional):
270
300
 
271
- Start Date Before: Filter tasks created/updated before this date (dateTime picker)
301
+ - **Limit**: Maximum number of results (default: 50)
302
+ - **Skip**: Number of results to skip (pagination)
303
+ - **Sort Field**: Field to sort by (e.g., `template.dueDate`)
304
+ - **Sort Order**: `1` for ascending, `-1` for descending
305
+ - **Start Date After**: Filter tasks after this date
306
+ - **Start Date Before**: Filter tasks before this date
272
307
 
273
308
  ---
274
309
 
@@ -314,36 +349,75 @@ Start Date Before: Filter tasks created/updated before this date (dateTime picke
314
349
  | **Get Children** | Retrieve all children/descendants |
315
350
  | **Get Parent** | Fetch the parent node of an orgchart node |
316
351
 
317
- **Example:**
352
+ **Example - Get Children with Depth Limit:**
318
353
 
319
- ```javascript
354
+ ```json
355
+ {
356
+ "resource": "orgchart",
357
+ "operation": "getChildren",
358
+ "orgunitId": "node123",
359
+ "additionalFields": {
360
+ "limit": 100
361
+ }
362
+ }
363
+ ```
364
+
365
+ **Example - Get Ancestors with Depth Limit:**
366
+
367
+ ```json
320
368
  {
321
- resource: "orgchart",
322
- operation: "getChildren",
323
- nodeId: "node123"
369
+ "resource": "orgchart",
370
+ "operation": "getAncestors",
371
+ "orgunitId": "node123",
372
+ "additionalFields": {
373
+ "depthLimit": 3
374
+ }
324
375
  }
325
376
  ```
326
377
 
378
+ **Optional Additional Fields:**
379
+
380
+ - **Get Children** → `limit`: Maximum number of child nodes to return (default: 0 = unlimited)
381
+ - **Get Ancestors** → `depthLimit`: How many levels up to traverse (default: 0 = unlimited)
382
+
327
383
  ---
328
384
 
329
385
  ## 🔐 Credentials Setup
330
386
 
331
- ### Bearer Token Authentication
387
+ Keephub uses **two separate credential types** — select the matching authentication method from the **Authentication** dropdown on the Keephub node.
388
+
389
+ ### 🔑 Keephub Bearer API
332
390
 
333
391
  ```
334
392
  ✓ Most secure for API integrations
335
393
  ✓ Use existing API tokens from Keephub
336
394
  ✓ Perfect for server-to-server communication
395
+ ✓ Uses IAuthenticateGeneric — token sent automatically in headers
337
396
  ```
338
397
 
339
- ### Username/Password Authentication
398
+ | Field | Description |
399
+ | -------------- | ------------------------------------ |
400
+ | **Client URL** | Your Keephub instance base URL |
401
+ | **Bearer Token** | API bearer token |
402
+ | **Language** | Language code (default: `en`) |
403
+
404
+ ### 🔒 Keephub Login API
340
405
 
341
406
  ```
342
- ✓ Automatic token generation
407
+ ✓ Automatic token generation from username/password
343
408
  ✓ Simple to set up
344
- Credentials securely stored in n8n
409
+ Token refreshed dynamically per request
410
+ ✓ Credentials securely stored and encrypted in n8n
345
411
  ```
346
412
 
413
+ | Field | Description |
414
+ | ------------------ | ----------------------------------------------- |
415
+ | **Client URL** | Your Keephub instance base URL |
416
+ | **Login Name** | Username for authentication |
417
+ | **Password** | Password for authentication |
418
+ | **Token Endpoint** | Custom token path (default: `/api/v2/auth/token`) |
419
+ | **Language** | Language code (default: `en`) |
420
+
347
421
  **All credentials are encrypted** 🔒 and never exposed in logs or workflows.
348
422
 
349
423
  ---
@@ -390,6 +464,13 @@ Send thank you message
390
464
 
391
465
  ## ⚙️ Node Configuration
392
466
 
467
+ ### Authentication
468
+
469
+ The Keephub node provides an **Authentication** dropdown at the top of the configuration panel:
470
+
471
+ - **Bearer Token** → uses the **Keephub Bearer API** credential
472
+ - **Login Credentials** → uses the **Keephub Login API** credential
473
+
393
474
  ### Input Data
394
475
 
395
476
  - All parameters support dynamic expressions with `{{ }}`
@@ -475,7 +556,8 @@ n8n-nodes-keephub/
475
556
  │ └── utils/
476
557
  │ └── helpers.ts
477
558
  ├── credentials/
478
- └── KeephubApi.credentials.ts
559
+ ├── KeephubBearerApi.credentials.ts
560
+ │ └── KeephubLoginApi.credentials.ts
479
561
  ├── package.json
480
562
  └── README.md
481
563
  ```
@@ -544,6 +626,23 @@ npm run lint
544
626
  - 🔧 Added externalRef of orgunit to the output of the Get submission orgunits node
545
627
  - 🧹 Fixed typo that was causing README rendering issues
546
628
 
629
+ ### v1.4.0 (2026-02-09) 🔐
630
+
631
+ - 🔑 **Split credentials** into two separate types: **Keephub Bearer API** and **Keephub Login API**
632
+ - 🛡️ Added `IAuthenticateGeneric` to Bearer credential for automatic header injection
633
+ - 🔀 Added **Authentication** selector dropdown to the node UI (Bearer Token / Login Credentials)
634
+ - 🔌 Updated `inputs`/`outputs` to use `NodeConnectionTypes.Main` (n8n best practice)
635
+ - 📦 Moved non-required fields into **Additional Fields** / **Options** collections:
636
+ - Content: Limit, Skip, Sort Field, Sort Order → Options
637
+ - Orgchart: Depth Limit, Result Limit → Additional Fields
638
+ - Task: Message, Send Notification → Additional Fields; Limit → Options
639
+ - 🧹 Updated helpers to dynamically resolve credentials based on authentication selector
640
+ - 📖 Updated README documentation to reflect all changes
641
+
642
+ ### v1.4.1 (2026-02-19)
643
+
644
+ - 🖼️ Changed Image assets to better match n8n's dark theme
645
+
547
646
  ---
548
647
 
549
648
  ## 🤝 Contributing
@@ -0,0 +1,11 @@
1
+ import { IAuthenticateGeneric, ICredentialTestRequest, ICredentialType, INodeProperties } from 'n8n-workflow';
2
+ export declare class KeephubBearerApi implements ICredentialType {
3
+ name: string;
4
+ displayName: string;
5
+ documentationUrl: string;
6
+ icon: "file:Keephub.svg";
7
+ properties: INodeProperties[];
8
+ authenticate: IAuthenticateGeneric;
9
+ test: ICredentialTestRequest;
10
+ }
11
+ //# sourceMappingURL=KeephubBearerApi.credentials.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"KeephubBearerApi.credentials.d.ts","sourceRoot":"","sources":["../../credentials/KeephubBearerApi.credentials.ts"],"names":[],"mappings":"AAAA,OAAO,EACN,oBAAoB,EACpB,sBAAsB,EACtB,eAAe,EACf,eAAe,EACf,MAAM,cAAc,CAAC;AAEtB,qBAAa,gBAAiB,YAAW,eAAe;IACvD,IAAI,SAAsB;IAC1B,WAAW,SAA8B;IACzC,gBAAgB,SAA0C;IAC1D,IAAI,EAAG,kBAAkB,CAAU;IAEnC,UAAU,EAAE,eAAe,EAAE,CAmC3B;IAEF,YAAY,EAAE,oBAAoB,CAOhC;IAEF,IAAI,EAAE,sBAAsB,CAK1B;CACF"}
@@ -0,0 +1,63 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.KeephubBearerApi = void 0;
4
+ class KeephubBearerApi {
5
+ constructor() {
6
+ this.name = 'keephubBearerApi';
7
+ this.displayName = 'Keephub Bearer Token API';
8
+ this.documentationUrl = 'https://dev.api.keephub.io/api-docs/';
9
+ this.icon = 'file:Keephub.svg';
10
+ this.properties = [
11
+ {
12
+ displayName: 'Client URL',
13
+ name: 'clientUrl',
14
+ type: 'string',
15
+ default: '',
16
+ placeholder: 'https://kega.keephub.io',
17
+ description: 'Your Keephub instance URL (e.g. https://kega.keephub.io)',
18
+ required: true,
19
+ },
20
+ {
21
+ displayName: 'Bearer Token (JWT)',
22
+ name: 'bearerToken',
23
+ type: 'string',
24
+ typeOptions: {
25
+ password: true,
26
+ },
27
+ default: '',
28
+ placeholder: 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...',
29
+ description: 'Your JWT Bearer token from Keephub',
30
+ required: true,
31
+ },
32
+ {
33
+ displayName: 'Language',
34
+ name: 'language',
35
+ type: 'options',
36
+ options: [
37
+ { name: 'English', value: 'en' },
38
+ { name: 'Dutch', value: 'nl' },
39
+ { name: 'Spanish', value: 'es' },
40
+ { name: 'French', value: 'fr' },
41
+ ],
42
+ default: 'en',
43
+ description: 'Default language for API requests',
44
+ },
45
+ ];
46
+ this.authenticate = {
47
+ type: 'generic',
48
+ properties: {
49
+ headers: {
50
+ Authorization: '=Bearer {{$credentials.bearerToken}}',
51
+ },
52
+ },
53
+ };
54
+ this.test = {
55
+ request: {
56
+ baseURL: '={{$credentials.clientUrl}}',
57
+ url: '/api/user/current',
58
+ },
59
+ };
60
+ }
61
+ }
62
+ exports.KeephubBearerApi = KeephubBearerApi;
63
+ //# sourceMappingURL=KeephubBearerApi.credentials.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"KeephubBearerApi.credentials.js","sourceRoot":"","sources":["../../credentials/KeephubBearerApi.credentials.ts"],"names":[],"mappings":";;;AAOA,MAAa,gBAAgB;IAA7B;QACC,SAAI,GAAG,kBAAkB,CAAC;QAC1B,gBAAW,GAAG,0BAA0B,CAAC;QACzC,qBAAgB,GAAG,sCAAsC,CAAC;QAC1D,SAAI,GAAG,kBAA2B,CAAC;QAEnC,eAAU,GAAsB;YAC/B;gBACC,WAAW,EAAE,YAAY;gBACzB,IAAI,EAAE,WAAW;gBACjB,IAAI,EAAE,QAAQ;gBACd,OAAO,EAAE,EAAE;gBACX,WAAW,EAAE,yBAAyB;gBACtC,WAAW,EAAE,0DAA0D;gBACvE,QAAQ,EAAE,IAAI;aACd;YACD;gBACC,WAAW,EAAE,oBAAoB;gBACjC,IAAI,EAAE,aAAa;gBACnB,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE;oBACZ,QAAQ,EAAE,IAAI;iBACd;gBACD,OAAO,EAAE,EAAE;gBACX,WAAW,EAAE,yCAAyC;gBACtD,WAAW,EAAE,oCAAoC;gBACjD,QAAQ,EAAE,IAAI;aACd;YACD;gBACC,WAAW,EAAE,UAAU;gBACvB,IAAI,EAAE,UAAU;gBAChB,IAAI,EAAE,SAAS;gBACf,OAAO,EAAE;oBACR,EAAE,IAAI,EAAE,SAAS,EAAE,KAAK,EAAE,IAAI,EAAE;oBAChC,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE;oBAC9B,EAAE,IAAI,EAAE,SAAS,EAAE,KAAK,EAAE,IAAI,EAAE;oBAChC,EAAE,IAAI,EAAE,QAAQ,EAAE,KAAK,EAAE,IAAI,EAAE;iBAC/B;gBACD,OAAO,EAAE,IAAI;gBACb,WAAW,EAAE,mCAAmC;aAChD;SACD,CAAC;QAEF,iBAAY,GAAyB;YACpC,IAAI,EAAE,SAAS;YACf,UAAU,EAAE;gBACX,OAAO,EAAE;oBACR,aAAa,EAAE,sCAAsC;iBACrD;aACD;SACD,CAAC;QAEF,SAAI,GAA2B;YAC9B,OAAO,EAAE;gBACR,OAAO,EAAE,6BAA6B;gBACtC,GAAG,EAAE,mBAAmB;aACxB;SACD,CAAC;IACH,CAAC;CAAA;AA1DD,4CA0DC"}
@@ -1,5 +1,5 @@
1
1
  import { ICredentialTestRequest, ICredentialType, INodeProperties } from 'n8n-workflow';
2
- export declare class KeephubApi implements ICredentialType {
2
+ export declare class KeephubLoginApi implements ICredentialType {
3
3
  name: string;
4
4
  displayName: string;
5
5
  documentationUrl: string;
@@ -7,4 +7,4 @@ export declare class KeephubApi implements ICredentialType {
7
7
  properties: INodeProperties[];
8
8
  test: ICredentialTestRequest;
9
9
  }
10
- //# sourceMappingURL=KeephubApi.credentials.d.ts.map
10
+ //# sourceMappingURL=KeephubLoginApi.credentials.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"KeephubLoginApi.credentials.d.ts","sourceRoot":"","sources":["../../credentials/KeephubLoginApi.credentials.ts"],"names":[],"mappings":"AAAA,OAAO,EACN,sBAAsB,EACtB,eAAe,EACf,eAAe,EACf,MAAM,cAAc,CAAC;AAEtB,qBAAa,eAAgB,YAAW,eAAe;IACtD,IAAI,SAAqB;IACzB,WAAW,SAAuB;IAClC,gBAAgB,SAA0C;IAC1D,IAAI,EAAG,kBAAkB,CAAU;IAEnC,UAAU,EAAE,eAAe,EAAE,CAmD3B;IAEF,IAAI,EAAE,sBAAsB,CAK1B;CACF"}
@@ -1,10 +1,10 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.KeephubApi = void 0;
4
- class KeephubApi {
3
+ exports.KeephubLoginApi = void 0;
4
+ class KeephubLoginApi {
5
5
  constructor() {
6
- this.name = 'keephubApi';
7
- this.displayName = 'Keephub API';
6
+ this.name = 'keephubLoginApi';
7
+ this.displayName = 'Keephub Login API';
8
8
  this.documentationUrl = 'https://dev.api.keephub.io/api-docs/';
9
9
  this.icon = 'file:Keephub.svg';
10
10
  this.properties = [
@@ -15,54 +15,16 @@ class KeephubApi {
15
15
  default: '',
16
16
  placeholder: 'https://kega.keephub.io',
17
17
  description: 'Your Keephub instance URL (e.g. https://kega.keephub.io)',
18
- },
19
- {
20
- displayName: 'Authentication Type',
21
- name: 'authType',
22
- type: 'options',
23
- options: [
24
- {
25
- name: 'Bearer Token',
26
- value: 'bearerToken',
27
- description: 'Use a JWT Bearer token directly',
28
- },
29
- {
30
- name: 'Get Token via API',
31
- value: 'apiCredentials',
32
- description: 'Use loginName/password to get a token',
33
- },
34
- ],
35
- default: 'bearerToken',
36
- description: 'Choose how you want to authenticate',
37
- },
38
- {
39
- displayName: 'Bearer Token (JWT)',
40
- name: 'bearerToken',
41
- type: 'string',
42
- typeOptions: {
43
- password: true,
44
- },
45
- displayOptions: {
46
- show: {
47
- authType: ['bearerToken'],
48
- },
49
- },
50
- default: '',
51
- placeholder: 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...',
52
- description: 'Your JWT Bearer token from Keephub',
18
+ required: true,
53
19
  },
54
20
  {
55
21
  displayName: 'Login Name',
56
22
  name: 'loginName',
57
23
  type: 'string',
58
- displayOptions: {
59
- show: {
60
- authType: ['apiCredentials'],
61
- },
62
- },
63
24
  default: '',
64
25
  placeholder: 'loginName',
65
26
  description: 'Your Keephub Login Name or email',
27
+ required: true,
66
28
  },
67
29
  {
68
30
  displayName: 'Password',
@@ -71,13 +33,9 @@ class KeephubApi {
71
33
  typeOptions: {
72
34
  password: true,
73
35
  },
74
- displayOptions: {
75
- show: {
76
- authType: ['apiCredentials'],
77
- },
78
- },
79
36
  default: '',
80
37
  description: 'Your Keephub password',
38
+ required: true,
81
39
  },
82
40
  {
83
41
  displayName: 'Language',
@@ -96,11 +54,6 @@ class KeephubApi {
96
54
  displayName: 'Token Endpoint',
97
55
  name: 'tokenEndpoint',
98
56
  type: 'string',
99
- displayOptions: {
100
- show: {
101
- authType: ['apiCredentials'],
102
- },
103
- },
104
57
  default: '/authentication',
105
58
  description: 'The endpoint to get your token (/authentication for Keephub)',
106
59
  typeOptions: { password: true },
@@ -110,12 +63,9 @@ class KeephubApi {
110
63
  request: {
111
64
  baseURL: '={{$credentials.clientUrl}}',
112
65
  url: '/api/user/current',
113
- headers: {
114
- Authorization: '=Bearer {{$credentials.bearerToken}}',
115
- },
116
66
  },
117
67
  };
118
68
  }
119
69
  }
120
- exports.KeephubApi = KeephubApi;
121
- //# sourceMappingURL=KeephubApi.credentials.js.map
70
+ exports.KeephubLoginApi = KeephubLoginApi;
71
+ //# sourceMappingURL=KeephubLoginApi.credentials.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"KeephubLoginApi.credentials.js","sourceRoot":"","sources":["../../credentials/KeephubLoginApi.credentials.ts"],"names":[],"mappings":";;;AAMA,MAAa,eAAe;IAA5B;QACC,SAAI,GAAG,iBAAiB,CAAC;QACzB,gBAAW,GAAG,mBAAmB,CAAC;QAClC,qBAAgB,GAAG,sCAAsC,CAAC;QAC1D,SAAI,GAAG,kBAA2B,CAAC;QAEnC,eAAU,GAAsB;YAC/B;gBACC,WAAW,EAAE,YAAY;gBACzB,IAAI,EAAE,WAAW;gBACjB,IAAI,EAAE,QAAQ;gBACd,OAAO,EAAE,EAAE;gBACX,WAAW,EAAE,yBAAyB;gBACtC,WAAW,EAAE,0DAA0D;gBACvE,QAAQ,EAAE,IAAI;aACd;YACD;gBACC,WAAW,EAAE,YAAY;gBACzB,IAAI,EAAE,WAAW;gBACjB,IAAI,EAAE,QAAQ;gBACd,OAAO,EAAE,EAAE;gBACX,WAAW,EAAE,WAAW;gBACxB,WAAW,EAAE,kCAAkC;gBAC/C,QAAQ,EAAE,IAAI;aACd;YACD;gBACC,WAAW,EAAE,UAAU;gBACvB,IAAI,EAAE,UAAU;gBAChB,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE;oBACZ,QAAQ,EAAE,IAAI;iBACd;gBACD,OAAO,EAAE,EAAE;gBACX,WAAW,EAAE,uBAAuB;gBACpC,QAAQ,EAAE,IAAI;aACd;YACD;gBACC,WAAW,EAAE,UAAU;gBACvB,IAAI,EAAE,UAAU;gBAChB,IAAI,EAAE,SAAS;gBACf,OAAO,EAAE;oBACR,EAAE,IAAI,EAAE,SAAS,EAAE,KAAK,EAAE,IAAI,EAAE;oBAChC,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE;oBAC9B,EAAE,IAAI,EAAE,SAAS,EAAE,KAAK,EAAE,IAAI,EAAE;oBAChC,EAAE,IAAI,EAAE,QAAQ,EAAE,KAAK,EAAE,IAAI,EAAE;iBAC/B;gBACD,OAAO,EAAE,IAAI;gBACb,WAAW,EAAE,mCAAmC;aAChD;YACD;gBACC,WAAW,EAAE,gBAAgB;gBAC7B,IAAI,EAAE,eAAe;gBACrB,IAAI,EAAE,QAAQ;gBACd,OAAO,EAAE,iBAAiB;gBAC1B,WAAW,EAAE,8DAA8D;gBAC3E,WAAW,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE;aAC/B;SACD,CAAC;QAEF,SAAI,GAA2B;YAC9B,OAAO,EAAE;gBACR,OAAO,EAAE,6BAA6B;gBACtC,GAAG,EAAE,mBAAmB;aACxB;SACD,CAAC;IACH,CAAC;CAAA;AAjED,0CAiEC"}
@@ -0,0 +1 @@
1
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":""}
package/dist/index.js ADDED
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ // n8n-nodes-keephub - Community node package for Keephub API integration
3
+ // This file is required for the package "main" entry point.
4
+ // n8n discovers nodes and credentials via the "n8n" section in package.json.
5
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":";AAAA,yEAAyE;AACzE,4DAA4D;AAC5D,6EAA6E"}
@@ -1 +1 @@
1
- {"version":3,"file":"Keephub.node.d.ts","sourceRoot":"","sources":["../../../nodes/Keephub/Keephub.node.ts"],"names":[],"mappings":"AAAA,OAAO,EACN,iBAAiB,EACjB,kBAAkB,EAElB,SAAS,EACT,oBAAoB,EAEpB,MAAM,cAAc,CAAC;AAYtB,qBAAa,OAAQ,YAAW,SAAS;IACxC,WAAW,EAAE,oBAAoB,CAwC/B;IAEI,OAAO,CAAC,IAAI,EAAE,iBAAiB,GAAG,OAAO,CAAC,kBAAkB,EAAE,EAAE,CAAC;CA2EvE"}
1
+ {"version":3,"file":"Keephub.node.d.ts","sourceRoot":"","sources":["../../../nodes/Keephub/Keephub.node.ts"],"names":[],"mappings":"AAAA,OAAO,EACN,iBAAiB,EACjB,kBAAkB,EAClB,SAAS,EACT,oBAAoB,EAGpB,MAAM,cAAc,CAAC;AAYtB,qBAAa,OAAQ,YAAW,SAAS;IACxC,WAAW,EAAE,oBAAoB,CAsE/B;IAEI,OAAO,CAAC,IAAI,EAAE,iBAAiB,GAAG,OAAO,CAAC,kBAAkB,EAAE,EAAE,CAAC;CA2EvE"}
@@ -57,15 +57,45 @@ class Keephub {
57
57
  defaults: {
58
58
  name: 'Keephub',
59
59
  },
60
- inputs: ['main'],
61
- outputs: ['main'],
60
+ inputs: [n8n_workflow_1.NodeConnectionTypes.Main],
61
+ outputs: [n8n_workflow_1.NodeConnectionTypes.Main],
62
62
  credentials: [
63
63
  {
64
- name: 'keephubApi',
64
+ name: 'keephubBearerApi',
65
65
  required: true,
66
+ displayOptions: {
67
+ show: {
68
+ authentication: ['bearerToken'],
69
+ },
70
+ },
71
+ },
72
+ {
73
+ name: 'keephubLoginApi',
74
+ required: true,
75
+ displayOptions: {
76
+ show: {
77
+ authentication: ['loginCredentials'],
78
+ },
79
+ },
66
80
  },
67
81
  ],
68
82
  properties: [
83
+ {
84
+ displayName: 'Authentication',
85
+ name: 'authentication',
86
+ type: 'options',
87
+ options: [
88
+ {
89
+ name: 'Bearer Token',
90
+ value: 'bearerToken',
91
+ },
92
+ {
93
+ name: 'Login Credentials',
94
+ value: 'loginCredentials',
95
+ },
96
+ ],
97
+ default: 'bearerToken',
98
+ },
69
99
  {
70
100
  displayName: 'Resource',
71
101
  name: 'resource',
@@ -1 +1 @@
1
- {"version":3,"file":"Keephub.node.js","sourceRoot":"","sources":["../../../nodes/Keephub/Keephub.node.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,+CAOsB;AACtB,kEAAoD;AACpD,sFAAwE;AACxE,0EAA4D;AAC5D,4DAA8C;AAC9C,4DAA8C;AAC9C,0EAAkE;AAClE,wFAAgF;AAChF,4EAAoE;AACpE,oEAA4D;AAC5D,oEAA4D;AAE5D,MAAa,OAAO;IAApB;QACC,gBAAW,GAAyB;YACnC,WAAW,EAAE,SAAS;YACtB,IAAI,EAAE,SAAS;YACf,IAAI,EAAE,kBAAkB;YACxB,KAAK,EAAE,CAAC,WAAW,CAAC;YACpB,OAAO,EAAE,CAAC;YACV,WAAW,EAAE,2BAA2B;YACxC,QAAQ,EAAE;gBACT,IAAI,EAAE,SAAS;aACf;YACD,MAAM,EAAE,CAAC,MAAM,CAAC;YAChB,OAAO,EAAE,CAAC,MAAM,CAAC;YACjB,WAAW,EAAE;gBACZ;oBACC,IAAI,EAAE,YAAY;oBAClB,QAAQ,EAAE,IAAI;iBACd;aACD;YACD,UAAU,EAAE;gBACX;oBACC,WAAW,EAAE,UAAU;oBACvB,IAAI,EAAE,UAAU;oBAChB,IAAI,EAAE,SAAS;oBACf,gBAAgB,EAAE,IAAI;oBACtB,OAAO,EAAE;wBACR,EAAE,IAAI,EAAE,SAAS,EAAE,KAAK,EAAE,SAAS,EAAE;wBACrC,EAAE,IAAI,EAAE,iBAAiB,EAAE,KAAK,EAAE,gBAAgB,EAAE;wBACpD,EAAE,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE,UAAU,EAAE;wBACvC,EAAE,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM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ACf,IAAI,EAAE,EAAE,KAAK,EAAE,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,eAAe,EAAE;wBACzE,UAAU,EAAE,EAAE,IAAI,EAAE,CAAC,EAAE;qBACvB,CAAC,CAAC;oBACH,SAAS;gBACV,CAAC;gBACD,MAAM,KAAK,CAAC;YACb,CAAC;QACF,CAAC;QAED,OAAO,CAAC,UAAU,CAAC,CAAC;IACrB,CAAC;CACD;AAtHD,0BAsHC"}
1
+ {"version":3,"file":"Keephub.node.js","sourceRoot":"","sources":["../../../nodes/Keephub/Keephub.node.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,+CAOsB;AACtB,kEAAoD;AACpD,sFAAwE;AACxE,0EAA4D;AAC5D,4DAA8C;AAC9C,4DAA8C;AAC9C,0EAAkE;AAClE,wFAAgF;AAChF,4EAAoE;AACpE,oEAA4D;AAC5D,oEAA4D;AAE5D,MAAa,OAAO;IAApB;QACC,gBAAW,GAAyB;YACnC,WAAW,EAAE,SAAS;YACtB,IAAI,EAAE,SAAS;YACf,IAAI,EAAE,kBAAkB;YACxB,KAAK,EAAE,CAAC,WAAW,CAAC;YACpB,OAAO,EAAE,CAAC;YACV,WAAW,EAAE,2BAA2B;YACxC,QAAQ,EAAE;gBACT,IAAI,EAAE,SAAS;aACf;YACD,MAAM,EAAE,CAAC,kCAAmB,CAAC,IAAI,CAAC;YAClC,OAAO,EAAE,CAAC,kCAAmB,CAAC,IAAI,CAAC;YACnC,WAAW,EAAE;gBACZ;oBACC,IAAI,EAAE,kBAAkB;oBACxB,QAAQ,EAAE,IAAI;oBACd,cAAc,EAAE;wBACf,IAAI,EAAE;4BACL,cAAc,EAAE,CAAC,aAAa,CAAC;yBAC/B;qBACD;iBACD;gBACD;oBACC,IAAI,EAAE,iBAAiB;oBACvB,QAAQ,EAAE,IAAI;oBACd,cAAc,EAAE;wBACf,IAAI,EAAE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,gBAAgB,CAAC,WAAW,EAAE,CAAC,CAAW,CAAC;QAElE,8DAA8D;QAC9D,MAAM,OAAO,GAAI,YAAoB,CAAC,QAAQ,CAAC,EAAE,CAAC,SAAS,CAAC,CAAC;QAE7D,IAAI,CAAC,OAAO,EAAE,CAAC;YACd,MAAM,IAAI,iCAAkB,CAC3B,IAAI,CAAC,OAAO,EAAE,EACd,sBAAsB,SAAS,mBAAmB,QAAQ,GAAG,CAC7D,CAAC;QACH,CAAC;QAED,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;YACvC,IAAI,CAAC;gBACJ,MAAM,MAAM,GAAG,MAAM,OAAO,CAAC,IAAI,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;gBACrD,UAAU,CAAC,IAAI,CAAC,GAAG,MAAM,CAAC,CAAC;YAC5B,CAAC;YAAC,OAAO,KAAK,EAAE,CAAC;gBAChB,IAAI,IAAI,CAAC,cAAc,EAAE,EAAE,CAAC;oBAC3B,UAAU,CAAC,IAAI,CAAC;wBACf,IAAI,EAAE,EAAE,KAAK,EAAE,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,eAAe,EAAE;wBACzE,UAAU,EAAE,EAAE,IAAI,EAAE,CAAC,EAAE;qBACvB,CAAC,CAAC;oBACH,SAAS;gBACV,CAAC;gBACD,MAAM,KAAK,CAAC;YACb,CAAC;QACF,CAAC;QAED,OAAO,CAAC,UAAU,CAAC,CAAC;IACrB,CAAC;CACD;AApJD,0BAoJC"}
@@ -1 +1 @@
1
- {"version":3,"file":"findByContentPool.d.ts","sourceRoot":"","sources":["../../../../../nodes/Keephub/actions/content/findByContentPool.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAe,iBAAiB,EAAE,MAAM,cAAc,CAAC;AAIvF,wBAAsB,OAAO,CAC5B,IAAI,EAAE,iBAAiB,EACvB,IAAI,EAAE,kBAAkB,EACxB,KAAK,EAAE,MAAM,GACX,OAAO,CAAC,kBAAkB,EAAE,CAAC,CA4D/B"}
1
+ {"version":3,"file":"findByContentPool.d.ts","sourceRoot":"","sources":["../../../../../nodes/Keephub/actions/content/findByContentPool.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAe,iBAAiB,EAAE,MAAM,cAAc,CAAC;AAIvF,wBAAsB,OAAO,CAC5B,IAAI,EAAE,iBAAiB,EACvB,IAAI,EAAE,kBAAkB,EACxB,KAAK,EAAE,MAAM,GACX,OAAO,CAAC,kBAAkB,EAAE,CAAC,CAsD/B"}
@@ -5,18 +5,13 @@ const n8n_workflow_1 = require("n8n-workflow");
5
5
  const helpers_1 = require("../../utils/helpers");
6
6
  async function execute(item, index) {
7
7
  const contentPoolId = this.getNodeParameter('filterContentPoolId', index);
8
- const limit = this.getNodeParameter('limit', index, 50);
9
8
  const options = this.getNodeParameter('options', index, {});
9
+ const limit = options.limit || 50;
10
10
  if (!contentPoolId || contentPoolId.trim().length === 0) {
11
11
  throw new n8n_workflow_1.NodeOperationError(this.getNode(), 'Content Pool ID cannot be empty', {
12
12
  itemIndex: index,
13
13
  });
14
14
  }
15
- if (limit < 1) {
16
- throw new n8n_workflow_1.NodeOperationError(this.getNode(), 'Limit must be greater than 0', {
17
- itemIndex: index,
18
- });
19
- }
20
15
  try {
21
16
  const skip = options.skip || 0;
22
17
  const sortBy = options.sortBy || '';