n8n-nodes-codex 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (100) hide show
  1. package/LICENSE.md +19 -0
  2. package/README.md +108 -0
  3. package/dist/credentials/CodexApi.credentials.d.ts +10 -0
  4. package/dist/credentials/CodexApi.credentials.js +92 -0
  5. package/dist/credentials/CodexApi.credentials.js.map +1 -0
  6. package/dist/icons/codex-dark.svg +7 -0
  7. package/dist/icons/codex-light.svg +7 -0
  8. package/dist/icons/codex.svg +7 -0
  9. package/dist/icons/github.dark.svg +3 -0
  10. package/dist/icons/github.svg +3 -0
  11. package/dist/nodes/Codex/Codex.node.d.ts +4 -0
  12. package/dist/nodes/Codex/Codex.node.js +133 -0
  13. package/dist/nodes/Codex/Codex.node.js.map +1 -0
  14. package/dist/nodes/Codex/resources/admin/index.d.ts +2 -0
  15. package/dist/nodes/Codex/resources/admin/index.js +489 -0
  16. package/dist/nodes/Codex/resources/admin/index.js.map +1 -0
  17. package/dist/nodes/Codex/resources/apiKey/index.d.ts +2 -0
  18. package/dist/nodes/Codex/resources/apiKey/index.js +233 -0
  19. package/dist/nodes/Codex/resources/apiKey/index.js.map +1 -0
  20. package/dist/nodes/Codex/resources/book/get.d.ts +2 -0
  21. package/dist/nodes/Codex/resources/book/get.js +5 -0
  22. package/dist/nodes/Codex/resources/book/get.js.map +1 -0
  23. package/dist/nodes/Codex/resources/book/index.d.ts +2 -0
  24. package/dist/nodes/Codex/resources/book/index.js +450 -0
  25. package/dist/nodes/Codex/resources/book/index.js.map +1 -0
  26. package/dist/nodes/Codex/resources/book/list.d.ts +2 -0
  27. package/dist/nodes/Codex/resources/book/list.js +81 -0
  28. package/dist/nodes/Codex/resources/book/list.js.map +1 -0
  29. package/dist/nodes/Codex/resources/book/updateMetadata.d.ts +2 -0
  30. package/dist/nodes/Codex/resources/book/updateMetadata.js +98 -0
  31. package/dist/nodes/Codex/resources/book/updateMetadata.js.map +1 -0
  32. package/dist/nodes/Codex/resources/book/updateProgress.d.ts +2 -0
  33. package/dist/nodes/Codex/resources/book/updateProgress.js +46 -0
  34. package/dist/nodes/Codex/resources/book/updateProgress.js.map +1 -0
  35. package/dist/nodes/Codex/resources/duplicate/index.d.ts +2 -0
  36. package/dist/nodes/Codex/resources/duplicate/index.js +162 -0
  37. package/dist/nodes/Codex/resources/duplicate/index.js.map +1 -0
  38. package/dist/nodes/Codex/resources/filesystem/index.d.ts +2 -0
  39. package/dist/nodes/Codex/resources/filesystem/index.js +64 -0
  40. package/dist/nodes/Codex/resources/filesystem/index.js.map +1 -0
  41. package/dist/nodes/Codex/resources/genre/index.d.ts +2 -0
  42. package/dist/nodes/Codex/resources/genre/index.js +83 -0
  43. package/dist/nodes/Codex/resources/genre/index.js.map +1 -0
  44. package/dist/nodes/Codex/resources/library/create.d.ts +2 -0
  45. package/dist/nodes/Codex/resources/library/create.js +94 -0
  46. package/dist/nodes/Codex/resources/library/create.js.map +1 -0
  47. package/dist/nodes/Codex/resources/library/delete.d.ts +2 -0
  48. package/dist/nodes/Codex/resources/library/delete.js +5 -0
  49. package/dist/nodes/Codex/resources/library/delete.js.map +1 -0
  50. package/dist/nodes/Codex/resources/library/get.d.ts +2 -0
  51. package/dist/nodes/Codex/resources/library/get.js +5 -0
  52. package/dist/nodes/Codex/resources/library/get.js.map +1 -0
  53. package/dist/nodes/Codex/resources/library/index.d.ts +2 -0
  54. package/dist/nodes/Codex/resources/library/index.js +360 -0
  55. package/dist/nodes/Codex/resources/library/index.js.map +1 -0
  56. package/dist/nodes/Codex/resources/library/list.d.ts +2 -0
  57. package/dist/nodes/Codex/resources/library/list.js +5 -0
  58. package/dist/nodes/Codex/resources/library/list.js.map +1 -0
  59. package/dist/nodes/Codex/resources/library/scan.d.ts +2 -0
  60. package/dist/nodes/Codex/resources/library/scan.js +37 -0
  61. package/dist/nodes/Codex/resources/library/scan.js.map +1 -0
  62. package/dist/nodes/Codex/resources/library/update.d.ts +2 -0
  63. package/dist/nodes/Codex/resources/library/update.js +73 -0
  64. package/dist/nodes/Codex/resources/library/update.js.map +1 -0
  65. package/dist/nodes/Codex/resources/metric/index.d.ts +2 -0
  66. package/dist/nodes/Codex/resources/metric/index.js +154 -0
  67. package/dist/nodes/Codex/resources/metric/index.js.map +1 -0
  68. package/dist/nodes/Codex/resources/misc/index.d.ts +2 -0
  69. package/dist/nodes/Codex/resources/misc/index.js +216 -0
  70. package/dist/nodes/Codex/resources/misc/index.js.map +1 -0
  71. package/dist/nodes/Codex/resources/series/get.d.ts +2 -0
  72. package/dist/nodes/Codex/resources/series/get.js +5 -0
  73. package/dist/nodes/Codex/resources/series/get.js.map +1 -0
  74. package/dist/nodes/Codex/resources/series/index.d.ts +2 -0
  75. package/dist/nodes/Codex/resources/series/index.js +1348 -0
  76. package/dist/nodes/Codex/resources/series/index.js.map +1 -0
  77. package/dist/nodes/Codex/resources/series/list.d.ts +2 -0
  78. package/dist/nodes/Codex/resources/series/list.js +108 -0
  79. package/dist/nodes/Codex/resources/series/list.js.map +1 -0
  80. package/dist/nodes/Codex/resources/series/updateMetadata.d.ts +2 -0
  81. package/dist/nodes/Codex/resources/series/updateMetadata.js +116 -0
  82. package/dist/nodes/Codex/resources/series/updateMetadata.js.map +1 -0
  83. package/dist/nodes/Codex/resources/tag/index.d.ts +2 -0
  84. package/dist/nodes/Codex/resources/tag/index.js +83 -0
  85. package/dist/nodes/Codex/resources/tag/index.js.map +1 -0
  86. package/dist/nodes/Codex/resources/task/index.d.ts +2 -0
  87. package/dist/nodes/Codex/resources/task/index.js +241 -0
  88. package/dist/nodes/Codex/resources/task/index.js.map +1 -0
  89. package/dist/nodes/Codex/resources/user/index.d.ts +2 -0
  90. package/dist/nodes/Codex/resources/user/index.js +362 -0
  91. package/dist/nodes/Codex/resources/user/index.js.map +1 -0
  92. package/dist/nodes/Codex/resources/userPreference/index.d.ts +2 -0
  93. package/dist/nodes/Codex/resources/userPreference/index.js +358 -0
  94. package/dist/nodes/Codex/resources/userPreference/index.js.map +1 -0
  95. package/dist/nodes/Codex/shared/descriptions.d.ts +6 -0
  96. package/dist/nodes/Codex/shared/descriptions.js +94 -0
  97. package/dist/nodes/Codex/shared/descriptions.js.map +1 -0
  98. package/dist/package.json +60 -0
  99. package/dist/tsconfig.tsbuildinfo +1 -0
  100. package/package.json +60 -0
package/LICENSE.md ADDED
@@ -0,0 +1,19 @@
1
+ Copyright 2022 n8n
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining a copy of
4
+ this software and associated documentation files (the "Software"), to deal in
5
+ the Software without restriction, including without limitation the rights to
6
+ use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
7
+ of the Software, and to permit persons to whom the Software is furnished to do
8
+ so, subject to the following conditions:
9
+
10
+ The above copyright notice and this permission notice shall be included in all
11
+ copies or substantial portions of the Software.
12
+
13
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
19
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,108 @@
1
+ # n8n-nodes-codex
2
+
3
+ This is an n8n community node for [Codex](https://codex.4sh.dev), a self-hosted digital library management system for comics, manga, and ebooks.
4
+
5
+ [n8n](https://n8n.io/) is a [fair-code licensed](https://docs.n8n.io/reference/license/) workflow automation platform.
6
+
7
+ ## Installation
8
+
9
+ Follow the [installation guide](https://docs.n8n.io/integrations/community-nodes/installation/) in the n8n community nodes documentation.
10
+
11
+ ## Credentials
12
+
13
+ To use this node, you need to configure Codex API credentials:
14
+
15
+ 1. In n8n, go to **Credentials** > **New**
16
+ 2. Search for "Codex API"
17
+ 3. Enter your Codex server URL (e.g., `https://your-codex-server.com`)
18
+ 4. Choose your authentication method:
19
+ - **API Key**: Use an API key generated from your Codex server
20
+ - **JWT Token**: Use a JWT token for authentication
21
+
22
+ ## Resources
23
+
24
+ This node supports the following Codex resources:
25
+
26
+ | Resource | Operations |
27
+ |----------|------------|
28
+ | **Admin** | Server administration operations |
29
+ | **API Key** | Create, Delete, Get, List, Update API keys |
30
+ | **Book** | Analyze, Delete Progress, Get, List, Update Metadata, Update Progress |
31
+ | **Duplicate** | Duplicate detection and management |
32
+ | **Filesystem** | File and directory operations |
33
+ | **Genre** | Genre management |
34
+ | **Library** | Scan, Analyze, Get Books, Get Series, and 20+ more operations |
35
+ | **Metrics** | Analytics and usage metrics |
36
+ | **Miscellaneous** | Settings, Setup, Thumbnails, Progress, Scans |
37
+ | **Series** | Series management operations |
38
+ | **Tag** | Tag management |
39
+ | **Task** | Background task operations |
40
+ | **User** | User management |
41
+ | **User Preference** | Preferences, Ratings, Integrations |
42
+
43
+ ## Compatibility
44
+
45
+ - Requires n8n version 1.0.0 or later
46
+ - Tested with Codex API v1
47
+
48
+ ## Usage
49
+
50
+ ### Example: List all books in a library
51
+
52
+ 1. Add a **Codex** node to your workflow
53
+ 2. Select your Codex credentials
54
+ 3. Choose **Library** as the resource
55
+ 4. Choose **Get All Books** as the operation
56
+ 5. Enter the Library ID
57
+ 6. Execute the workflow
58
+
59
+ ### Example: Track reading progress
60
+
61
+ 1. Add a **Codex** node to your workflow
62
+ 2. Select **Book** as the resource
63
+ 3. Choose **Update Progress** as the operation
64
+ 4. Enter the Book ID and progress data
65
+ 5. Execute the workflow
66
+
67
+ ## Development
68
+
69
+ ```bash
70
+ # Install dependencies
71
+ npm install
72
+
73
+ # Build the node
74
+ npm run build
75
+
76
+ # Run in development mode with hot reload
77
+ npm run dev
78
+
79
+ # Lint the code
80
+ npm run lint
81
+
82
+ # Fix linting issues
83
+ npm run lint:fix
84
+ ```
85
+
86
+ ### Local Testing with Docker
87
+
88
+ A Docker Compose configuration is included for local development:
89
+
90
+ ```bash
91
+ # Start Codex and n8n containers
92
+ npm run docker:up
93
+
94
+ # View logs
95
+ npm run docker:logs
96
+
97
+ # Stop containers
98
+ npm run docker:down
99
+ ```
100
+
101
+ ## Resources
102
+
103
+ - [n8n Community Nodes Documentation](https://docs.n8n.io/integrations/community-nodes/)
104
+ - [Codex Documentation](https://codex.4sh.dev)
105
+
106
+ ## License
107
+
108
+ [MIT](LICENSE.md)
@@ -0,0 +1,10 @@
1
+ import type { ICredentialDataDecryptedObject, ICredentialTestRequest, ICredentialType, Icon, IHttpRequestOptions, INodeProperties } from 'n8n-workflow';
2
+ export declare class CodexApi implements ICredentialType {
3
+ name: string;
4
+ displayName: string;
5
+ icon: Icon;
6
+ documentationUrl: string;
7
+ properties: INodeProperties[];
8
+ authenticate(credentials: ICredentialDataDecryptedObject, requestOptions: IHttpRequestOptions): Promise<IHttpRequestOptions>;
9
+ test: ICredentialTestRequest;
10
+ }
@@ -0,0 +1,92 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.CodexApi = void 0;
4
+ class CodexApi {
5
+ constructor() {
6
+ this.name = 'codexApi';
7
+ this.displayName = 'Codex API';
8
+ this.icon = 'file:../icons/codex.svg';
9
+ this.documentationUrl = 'https://codex.4sh.dev/docs/api';
10
+ this.properties = [
11
+ {
12
+ displayName: 'Base URL',
13
+ name: 'baseUrl',
14
+ type: 'string',
15
+ default: '',
16
+ description: 'The base URL of your Codex instance',
17
+ placeholder: 'https://codex.example.com',
18
+ required: true,
19
+ },
20
+ {
21
+ displayName: 'Authentication Method',
22
+ name: 'authenticationMethod',
23
+ type: 'options',
24
+ options: [
25
+ {
26
+ name: 'API Key',
27
+ value: 'apiKey',
28
+ },
29
+ {
30
+ name: 'JWT Token',
31
+ value: 'jwt',
32
+ },
33
+ ],
34
+ default: 'apiKey',
35
+ },
36
+ {
37
+ displayName: 'API Key',
38
+ name: 'apiKey',
39
+ type: 'string',
40
+ typeOptions: { password: true },
41
+ default: '',
42
+ displayOptions: {
43
+ show: {
44
+ authenticationMethod: ['apiKey'],
45
+ },
46
+ },
47
+ description: 'API key generated from the Codex web UI or API',
48
+ },
49
+ {
50
+ displayName: 'JWT Token',
51
+ name: 'jwtToken',
52
+ type: 'string',
53
+ typeOptions: { password: true },
54
+ default: '',
55
+ displayOptions: {
56
+ show: {
57
+ authenticationMethod: ['jwt'],
58
+ },
59
+ },
60
+ description: 'JWT token obtained via POST /api/v1/auth/login',
61
+ },
62
+ ];
63
+ this.test = {
64
+ request: {
65
+ baseURL: '={{$credentials?.baseUrl}}',
66
+ url: '/api/v1/libraries',
67
+ method: 'GET',
68
+ headers: {
69
+ Accept: 'application/json',
70
+ },
71
+ },
72
+ };
73
+ }
74
+ async authenticate(credentials, requestOptions) {
75
+ const authenticationMethod = credentials.authenticationMethod;
76
+ if (authenticationMethod === 'apiKey') {
77
+ requestOptions.headers = {
78
+ ...requestOptions.headers,
79
+ 'X-API-Key': credentials.apiKey,
80
+ };
81
+ }
82
+ else if (authenticationMethod === 'jwt') {
83
+ requestOptions.headers = {
84
+ ...requestOptions.headers,
85
+ Authorization: `Bearer ${credentials.jwtToken}`,
86
+ };
87
+ }
88
+ return requestOptions;
89
+ }
90
+ }
91
+ exports.CodexApi = CodexApi;
92
+ //# sourceMappingURL=CodexApi.credentials.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CodexApi.credentials.js","sourceRoot":"","sources":["../../credentials/CodexApi.credentials.ts"],"names":[],"mappings":";;;AASA,MAAa,QAAQ;IAArB;QACC,SAAI,GAAG,UAAU,CAAC;QAElB,gBAAW,GAAG,WAAW,CAAC;QAE1B,SAAI,GAAS,yBAAyB,CAAC;QAEvC,qBAAgB,GAAG,gCAAgC,CAAC;QAEpD,eAAU,GAAsB;YAC/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CAAC,YAAY,CACjB,WAA2C,EAC3C,cAAmC;QAEnC,MAAM,oBAAoB,GAAG,WAAW,CAAC,oBAA8B,CAAC;QAExE,IAAI,oBAAoB,KAAK,QAAQ,EAAE,CAAC;YACvC,cAAc,CAAC,OAAO,GAAG;gBACxB,GAAG,cAAc,CAAC,OAAO;gBACzB,WAAW,EAAE,WAAW,CAAC,MAAgB;aACzC,CAAC;QACH,CAAC;aAAM,IAAI,oBAAoB,KAAK,KAAK,EAAE,CAAC;YAC3C,cAAc,CAAC,OAAO,GAAG;gBACxB,GAAG,cAAc,CAAC,OAAO;gBACzB,aAAa,EAAE,UAAU,WAAW,CAAC,QAAkB,EAAE;aACzD,CAAC;QACH,CAAC;QAED,OAAO,cAAc,CAAC;IACvB,CAAC;CAYD;AA9FD,4BA8FC"}
@@ -0,0 +1,7 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="#ffffff" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
2
+ <path d="M4 19.5A2.5 2.5 0 0 1 6.5 17H20"/>
3
+ <path d="M6.5 2H20v20H6.5A2.5 2.5 0 0 1 4 19.5v-15A2.5 2.5 0 0 1 6.5 2z"/>
4
+ <path d="M8 7h8"/>
5
+ <path d="M8 11h8"/>
6
+ <path d="M8 15h4"/>
7
+ </svg>
@@ -0,0 +1,7 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="#000000" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
2
+ <path d="M4 19.5A2.5 2.5 0 0 1 6.5 17H20"/>
3
+ <path d="M6.5 2H20v20H6.5A2.5 2.5 0 0 1 4 19.5v-15A2.5 2.5 0 0 1 6.5 2z"/>
4
+ <path d="M8 7h8"/>
5
+ <path d="M8 11h8"/>
6
+ <path d="M8 15h4"/>
7
+ </svg>
@@ -0,0 +1,7 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
2
+ <path d="M4 19.5A2.5 2.5 0 0 1 6.5 17H20"/>
3
+ <path d="M6.5 2H20v20H6.5A2.5 2.5 0 0 1 4 19.5v-15A2.5 2.5 0 0 1 6.5 2z"/>
4
+ <path d="M8 7h8"/>
5
+ <path d="M8 11h8"/>
6
+ <path d="M8 15h4"/>
7
+ </svg>
@@ -0,0 +1,3 @@
1
+ <svg width="40" height="40" viewBox="0 0 40 40" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M20.0165 0C8.94791 0 0 9.01388 0 20.1653C0 29.0792 5.73324 36.6246 13.6868 39.2952C14.6812 39.496 15.0454 38.8613 15.0454 38.3274C15.0454 37.8599 15.0126 36.2575 15.0126 34.5879C9.4445 35.79 8.28498 32.1841 8.28498 32.1841C7.39015 29.847 6.06429 29.2463 6.06429 29.2463C4.24185 28.011 6.19704 28.011 6.19704 28.011C8.21861 28.1446 9.27938 30.081 9.27938 30.081C11.0686 33.1522 13.9518 32.2844 15.1118 31.7502C15.2773 30.4481 15.8079 29.5467 16.3713 29.046C11.9303 28.5785 7.25781 26.8425 7.25781 19.0967C7.25781 16.8932 8.05267 15.0905 9.31216 13.6884C9.11344 13.1877 8.41732 11.1174 9.51128 8.34644C9.51128 8.34644 11.2014 7.81217 15.0122 10.4164C16.6438 9.97495 18.3263 9.7504 20.0165 9.74851C21.7067 9.74851 23.4295 9.98246 25.0205 10.4164C28.8317 7.81217 30.5218 8.34644 30.5218 8.34644C31.6158 11.1174 30.9192 13.1877 30.7205 13.6884C32.0132 15.0905 32.7753 16.8932 32.7753 19.0967C32.7753 26.8425 28.1028 28.5449 23.6287 29.046C24.358 29.6802 24.9873 30.882 24.9873 32.7851C24.9873 35.4893 24.9545 37.6596 24.9545 38.327C24.9545 38.8613 25.3192 39.496 26.3132 39.2956C34.2667 36.6242 39.9999 29.0792 39.9999 20.1653C40.0327 9.01388 31.052 0 20.0165 0Z" fill="white"/>
3
+ </svg>
@@ -0,0 +1,3 @@
1
+ <svg width="40" height="40" viewBox="0 0 40 40" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M20.0165 0C8.94791 0 0 9.01388 0 20.1653C0 29.0792 5.73324 36.6246 13.6868 39.2952C14.6812 39.496 15.0454 38.8613 15.0454 38.3274C15.0454 37.8599 15.0126 36.2575 15.0126 34.5879C9.4445 35.79 8.28498 32.1841 8.28498 32.1841C7.39015 29.847 6.06429 29.2463 6.06429 29.2463C4.24185 28.011 6.19704 28.011 6.19704 28.011C8.21861 28.1446 9.27938 30.081 9.27938 30.081C11.0686 33.1522 13.9518 32.2844 15.1118 31.7502C15.2773 30.4481 15.8079 29.5467 16.3713 29.046C11.9303 28.5785 7.25781 26.8425 7.25781 19.0967C7.25781 16.8932 8.05267 15.0905 9.31216 13.6884C9.11344 13.1877 8.41732 11.1174 9.51128 8.34644C9.51128 8.34644 11.2014 7.81217 15.0122 10.4164C16.6438 9.97495 18.3263 9.7504 20.0165 9.74851C21.7067 9.74851 23.4295 9.98246 25.0205 10.4164C28.8317 7.81217 30.5218 8.34644 30.5218 8.34644C31.6158 11.1174 30.9192 13.1877 30.7205 13.6884C32.0132 15.0905 32.7753 16.8932 32.7753 19.0967C32.7753 26.8425 28.1028 28.5449 23.6287 29.046C24.358 29.6802 24.9873 30.882 24.9873 32.7851C24.9873 35.4893 24.9545 37.6596 24.9545 38.327C24.9545 38.8613 25.3192 39.496 26.3132 39.2956C34.2667 36.6242 39.9999 29.0792 39.9999 20.1653C40.0327 9.01388 31.052 0 20.0165 0Z" fill="#24292F"/>
3
+ </svg>
@@ -0,0 +1,4 @@
1
+ import { type INodeType, type INodeTypeDescription } from 'n8n-workflow';
2
+ export declare class Codex implements INodeType {
3
+ description: INodeTypeDescription;
4
+ }
@@ -0,0 +1,133 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.Codex = void 0;
4
+ const n8n_workflow_1 = require("n8n-workflow");
5
+ const admin_1 = require("./resources/admin");
6
+ const apiKey_1 = require("./resources/apiKey");
7
+ const book_1 = require("./resources/book");
8
+ const duplicate_1 = require("./resources/duplicate");
9
+ const filesystem_1 = require("./resources/filesystem");
10
+ const genre_1 = require("./resources/genre");
11
+ const library_1 = require("./resources/library");
12
+ const metric_1 = require("./resources/metric");
13
+ const misc_1 = require("./resources/misc");
14
+ const series_1 = require("./resources/series");
15
+ const tag_1 = require("./resources/tag");
16
+ const task_1 = require("./resources/task");
17
+ const user_1 = require("./resources/user");
18
+ const userPreference_1 = require("./resources/userPreference");
19
+ class Codex {
20
+ constructor() {
21
+ this.description = {
22
+ displayName: 'Codex',
23
+ name: 'codex',
24
+ icon: { light: 'file:../../icons/codex-light.svg', dark: 'file:../../icons/codex-dark.svg' },
25
+ group: ['input'],
26
+ version: 1,
27
+ subtitle: '={{$parameter["operation"] + ": " + $parameter["resource"]}}',
28
+ description: 'Interact with the Codex digital library API',
29
+ defaults: {
30
+ name: 'Codex',
31
+ },
32
+ usableAsTool: true,
33
+ inputs: [n8n_workflow_1.NodeConnectionTypes.Main],
34
+ outputs: [n8n_workflow_1.NodeConnectionTypes.Main],
35
+ credentials: [
36
+ {
37
+ name: 'codexApi',
38
+ required: true,
39
+ },
40
+ ],
41
+ requestDefaults: {
42
+ baseURL: '={{$credentials?.baseUrl}}',
43
+ headers: {
44
+ Accept: 'application/json',
45
+ 'Content-Type': 'application/json',
46
+ },
47
+ },
48
+ properties: [
49
+ {
50
+ displayName: 'Resource',
51
+ name: 'resource',
52
+ type: 'options',
53
+ noDataExpression: true,
54
+ options: [
55
+ {
56
+ name: 'Admin',
57
+ value: 'admin',
58
+ },
59
+ {
60
+ name: 'API Key',
61
+ value: 'apiKey',
62
+ },
63
+ {
64
+ name: 'Book',
65
+ value: 'book',
66
+ },
67
+ {
68
+ name: 'Duplicate',
69
+ value: 'duplicate',
70
+ },
71
+ {
72
+ name: 'Filesystem',
73
+ value: 'filesystem',
74
+ },
75
+ {
76
+ name: 'Genre',
77
+ value: 'genre',
78
+ },
79
+ {
80
+ name: 'Library',
81
+ value: 'library',
82
+ },
83
+ {
84
+ name: 'Metric',
85
+ value: 'metric',
86
+ },
87
+ {
88
+ name: 'Miscellaneous',
89
+ value: 'misc',
90
+ },
91
+ {
92
+ name: 'Series',
93
+ value: 'series',
94
+ },
95
+ {
96
+ name: 'Tag',
97
+ value: 'tag',
98
+ },
99
+ {
100
+ name: 'Task',
101
+ value: 'task',
102
+ },
103
+ {
104
+ name: 'User',
105
+ value: 'user',
106
+ },
107
+ {
108
+ name: 'User Preference',
109
+ value: 'userPreference',
110
+ },
111
+ ],
112
+ default: 'library',
113
+ },
114
+ ...admin_1.adminDescription,
115
+ ...apiKey_1.apiKeyDescription,
116
+ ...book_1.bookDescription,
117
+ ...duplicate_1.duplicateDescription,
118
+ ...filesystem_1.filesystemDescription,
119
+ ...genre_1.genreDescription,
120
+ ...library_1.libraryDescription,
121
+ ...metric_1.metricDescription,
122
+ ...misc_1.miscDescription,
123
+ ...series_1.seriesDescription,
124
+ ...tag_1.tagDescription,
125
+ ...task_1.taskDescription,
126
+ ...user_1.userDescription,
127
+ ...userPreference_1.userPreferenceDescription,
128
+ ],
129
+ };
130
+ }
131
+ }
132
+ exports.Codex = Codex;
133
+ //# sourceMappingURL=Codex.node.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Codex.node.js","sourceRoot":"","sources":["../../../nodes/Codex/Codex.node.ts"],"names":[],"mappings":";;;AAAA,+CAA8F;AAC9F,6CAAqD;AACrD,+CAAuD;AACvD,2CAAmD;AACnD,qDAA6D;AAC7D,uDAA+D;AAC/D,6CAAqD;AACrD,iDAAyD;AACzD,+CAAuD;AACvD,2CAAmD;AACnD,+CAAuD;AACvD,yCAAiD;AACjD,2CAAmD;AACnD,2CAAmD;AACnD,+DAAuE;AAEvE,MAAa,KAAK;IAAlB;QACC,gBAAW,G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QAAQ;4BACd,KAAK,EAAE,QAAQ;yBACf;wBACD;4BACC,IAAI,EAAE,eAAe;4BACrB,KAAK,EAAE,MAAM;yBACb;wBACD;4BACC,IAAI,EAAE,QAAQ;4BACd,KAAK,EAAE,QAAQ;yBACf;wBACD;4BACC,IAAI,EAAE,KAAK;4BACX,KAAK,EAAE,KAAK;yBACZ;wBACD;4BACC,IAAI,EAAE,MAAM;4BACZ,KAAK,EAAE,MAAM;yBACb;wBACD;4BACC,IAAI,EAAE,MAAM;4BACZ,KAAK,EAAE,MAAM;yBACb;wBACD;4BACC,IAAI,EAAE,iBAAiB;4BACvB,KAAK,EAAE,gBAAgB;yBACvB;qBACD;oBACD,OAAO,EAAE,SAAS;iBAClB;gBACD,GAAG,wBAAgB;gBACnB,GAAG,0BAAiB;gBACpB,GAAG,sBAAe;gBAClB,GAAG,gCAAoB;gBACvB,GAAG,kCAAqB;gBACxB,GAAG,wBAAgB;gBACnB,GAAG,4BAAkB;gBACrB,GAAG,0BAAiB;gBACpB,GAAG,sBAAe;gBAClB,GAAG,0BAAiB;gBACpB,GAAG,oBAAc;gBACjB,GAAG,sBAAe;gBAClB,GAAG,sBAAe;gBAClB,GAAG,0CAAyB;aAC5B;SACD,CAAC;IACH,CAAC;CAAA;AA9GD,sBA8GC"}
@@ -0,0 +1,2 @@
1
+ import type { INodeProperties } from 'n8n-workflow';
2
+ export declare const adminDescription: INodeProperties[];