n8n-nodes-runrunit 0.2.17 → 0.3.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 (52) hide show
  1. package/README.md +46 -57
  2. package/dist/credentials/RunrunitApi.credentials.d.ts +3 -3
  3. package/dist/credentials/RunrunitApi.credentials.js +17 -57
  4. package/dist/credentials/RunrunitApi.credentials.js.map +1 -1
  5. package/dist/nodes/Runrunit/Runrunit.node.d.ts +4 -0
  6. package/dist/nodes/Runrunit/Runrunit.node.js +56 -0
  7. package/dist/nodes/Runrunit/Runrunit.node.js.map +1 -0
  8. package/dist/nodes/Runrunit/{RunrunitApi.node.json → Runrunit.node.json} +3 -3
  9. package/dist/nodes/Runrunit/resources/company/getAll.d.ts +2 -0
  10. package/dist/nodes/Runrunit/resources/company/getAll.js +62 -0
  11. package/dist/nodes/Runrunit/resources/company/getAll.js.map +1 -0
  12. package/dist/nodes/Runrunit/resources/company/index.d.ts +2 -0
  13. package/dist/nodes/Runrunit/resources/company/index.js +35 -0
  14. package/dist/nodes/Runrunit/resources/company/index.js.map +1 -0
  15. package/dist/nodes/Runrunit/resources/user/create.d.ts +2 -0
  16. package/dist/nodes/Runrunit/resources/user/create.js +27 -0
  17. package/dist/nodes/Runrunit/resources/user/create.js.map +1 -0
  18. package/dist/nodes/Runrunit/resources/user/get.d.ts +2 -0
  19. package/dist/nodes/Runrunit/resources/user/get.js +18 -0
  20. package/dist/nodes/Runrunit/resources/user/get.js.map +1 -0
  21. package/dist/nodes/Runrunit/resources/user/index.d.ts +2 -0
  22. package/dist/nodes/Runrunit/resources/user/index.js +61 -0
  23. package/dist/nodes/Runrunit/resources/user/index.js.map +1 -0
  24. package/dist/nodes/Runrunit/runrunit.dark.svg +12 -12
  25. package/dist/nodes/Runrunit/runrunit.svg +12 -12
  26. package/dist/package.json +10 -21
  27. package/dist/tsconfig.tsbuildinfo +1 -1
  28. package/package.json +48 -59
  29. package/LICENSE.md +0 -19
  30. package/dist/icons/runrunit.dark.svg +0 -13
  31. package/dist/icons/runrunit.svg +0 -13
  32. package/dist/nodes/Runrunit/RunrunitApi.node.d.ts +0 -6
  33. package/dist/nodes/Runrunit/RunrunitApi.node.js +0 -402
  34. package/dist/nodes/Runrunit/RunrunitApi.node.js.map +0 -1
  35. package/dist/nodes/Runrunit/resources/Tasks/create.d.ts +0 -2
  36. package/dist/nodes/Runrunit/resources/Tasks/create.js +0 -71
  37. package/dist/nodes/Runrunit/resources/Tasks/create.js.map +0 -1
  38. package/dist/nodes/Runrunit/resources/Tasks/delete.d.ts +0 -2
  39. package/dist/nodes/Runrunit/resources/Tasks/delete.js +0 -5
  40. package/dist/nodes/Runrunit/resources/Tasks/delete.js.map +0 -1
  41. package/dist/nodes/Runrunit/resources/Tasks/get.d.ts +0 -2
  42. package/dist/nodes/Runrunit/resources/Tasks/get.js +0 -23
  43. package/dist/nodes/Runrunit/resources/Tasks/get.js.map +0 -1
  44. package/dist/nodes/Runrunit/resources/Tasks/index.d.ts +0 -2
  45. package/dist/nodes/Runrunit/resources/Tasks/index.js +0 -111
  46. package/dist/nodes/Runrunit/resources/Tasks/index.js.map +0 -1
  47. package/dist/nodes/Runrunit/resources/Tasks/options.d.ts +0 -2
  48. package/dist/nodes/Runrunit/resources/Tasks/options.js +0 -5
  49. package/dist/nodes/Runrunit/resources/Tasks/options.js.map +0 -1
  50. package/dist/nodes/Runrunit/resources/Tasks/update.d.ts +0 -2
  51. package/dist/nodes/Runrunit/resources/Tasks/update.js +0 -71
  52. package/dist/nodes/Runrunit/resources/Tasks/update.js.map +0 -1
package/README.md CHANGED
@@ -1,57 +1,46 @@
1
- # n8n-nodes-runrunit
2
-
3
- ![version](https://img.shields.io/badge/version-2.0.12.13-blue) ![n8n](https://img.shields.io/badge/n8n-community-orange) ![Runrun.it](https://img.shields.io/badge/Runrun.it-REST%20API-blue)
4
-
5
- Node para integração do [Runrun.it](https://runrun.it/) com o [n8n](https://n8n.io/), compatível com a API REST.
6
-
7
- ## Funcionalidades
8
- - Autenticação automática via initSession (sem precisar criar node HTTP manual)
9
- - Suporte a operações de CRUD para Tickets, Changes, Problems, Computers, Softwares e comentários
10
- - Gerenciamento automático do Session-Token
11
- - Compatível com n8n Cloud e Self-hosted
12
- - Credenciais seguras (Runrun.it URL, App Token, Username, Password)
13
-
14
- --
15
-
16
- Nota rápida: para a criação/atualização de usuários em `Administration/User` o node agora espera o payload como JSON bruto no campo `Input (raw)`.
17
- Use a opção `Send raw body` para enviar exatamente esse JSON (sem o wrapper `{ "input": ... }`). Campos individuais como Name/Email/Password foram removidos do formulário para evitar ambiguidade.
18
-
19
- ## 🚀 Instalação
20
-
21
- 1. Clone ou baixe este repositório
22
- 2. Execute `npm install` para instalar as dependências
23
- 3. Use os scripts disponíveis para build/dev:
24
- - `npm run build` — build de produção
25
- - `npm run dev` — modo desenvolvimento
26
-
27
- ## 🔧 Configuração no n8n
28
-
29
- 1. Importe o node customizado no painel do n8n
30
- 2. Crie uma credencial do tipo **Runrun.it API** informando:
31
- - Runrun.it URL (ex: https://runrun.seudominio.com/api.php)
32
- - App Token
33
- - Username
34
- - Password
35
- 3. Use o node "Runrun.it API" nos seus fluxos, escolhendo a operação desejada (Get, Add, Update, Comment)
36
-
37
- ## 🧩 Exemplo de Uso
38
-
39
- - Buscar um ticket:
40
- - Operation: Get
41
- - Item Type: Ticket
42
- - Item ID: 123
43
- - Criar um novo computador:
44
- - Operation: Add
45
- - Item Type: Computer
46
- - Payload: `{ "name": "PC-01", "serial": "123456" }`
47
-
48
- ## 📁 Estrutura do Projeto
49
-
50
- - `credentials/RunrunItApi.credentials.ts` — definição das credenciais
51
- - `nodes/RunrunIt/RunrunItApi.node.ts` — implementação principal do node
52
- - `nodes/RunrunIt/resources/` — módulos separados por área do Runrun.it
53
- - `n8n-nodes-glpi-instructions.md` — instruções detalhadas e exemplos
54
-
55
- ## 📜 Licença
56
-
57
- MIT — veja o arquivo [LICENSE.md](LICENSE.md)
1
+ # n8n-nodes-runrunit
2
+
3
+ This is an n8n community node. It lets you use _app/service name_ in your n8n workflows.
4
+
5
+ _App/service name_ is _one or two sentences describing the service this node integrates with_.
6
+
7
+ [n8n](https://n8n.io/) is a [fair-code licensed](https://docs.n8n.io/sustainable-use-license/) workflow automation platform.
8
+
9
+ [Installation](#installation)
10
+ [Operations](#operations)
11
+ [Credentials](#credentials)
12
+ [Compatibility](#compatibility)
13
+ [Usage](#usage)
14
+ [Resources](#resources)
15
+ [Version history](#version-history)
16
+
17
+ ## Installation
18
+
19
+ Follow the [installation guide](https://docs.n8n.io/integrations/community-nodes/installation/) in the n8n community nodes documentation.
20
+
21
+ ## Operations
22
+
23
+ _List the operations supported by your node._
24
+
25
+ ## Credentials
26
+
27
+ _If users need to authenticate with the app/service, provide details here. You should include prerequisites (such as signing up with the service), available authentication methods, and how to set them up._
28
+
29
+ ## Compatibility
30
+
31
+ _State the minimum n8n version, as well as which versions you test against. You can also include any known version incompatibility issues._
32
+
33
+ ## Usage
34
+
35
+ _This is an optional section. Use it to help users with any difficult or confusing aspects of the node._
36
+
37
+ _By the time users are looking for community nodes, they probably already know n8n basics. But if you expect new users, you can link to the [Try it out](https://docs.n8n.io/try-it-out/) documentation to help them get started._
38
+
39
+ ## Resources
40
+
41
+ * [n8n community nodes documentation](https://docs.n8n.io/integrations/#community-nodes)
42
+ * _Link to app/service documentation._
43
+
44
+ ## Version history
45
+
46
+ _This is another optional section. If your node has multiple versions, include a short description of available versions and what changed, as well as any compatibility impact._
@@ -1,9 +1,9 @@
1
- import type { ICredentialType, ICredentialTestRequest, INodeProperties, Icon } from 'n8n-workflow';
1
+ import type { IAuthenticateGeneric, ICredentialTestRequest, ICredentialType, INodeProperties } from 'n8n-workflow';
2
2
  export declare class RunrunitApi implements ICredentialType {
3
3
  name: string;
4
4
  displayName: string;
5
- icon: Icon;
6
5
  documentationUrl: string;
7
- test: ICredentialTestRequest;
8
6
  properties: INodeProperties[];
7
+ authenticate: IAuthenticateGeneric;
8
+ test: ICredentialTestRequest;
9
9
  }
@@ -4,72 +4,32 @@ exports.RunrunitApi = void 0;
4
4
  class RunrunitApi {
5
5
  constructor() {
6
6
  this.name = 'runrunitApi';
7
- this.displayName = 'Runrun.it API';
8
- this.icon = { light: 'file:../icons/runrunit.svg', dark: 'file:../icons/runrunit.dark.svg' };
9
- this.documentationUrl = 'https://atendimento.centrium.com.br/api.php/v2.1/doc.JSON';
10
- this.test = {
11
- request: {
12
- url: '={{$credentials.host.replace(/\\/+$/, "") + "/api.php"}}/token',
13
- method: 'POST',
14
- headers: {
15
- 'Content-Type': 'application/json',
16
- },
17
- body: '={"grant_type":"password","client_id":"' + "{{$credentials.clientId}}" + '","client_secret":"' + "{{$credentials.clientSecret}}" + '","username":"' + "{{$credentials.username}}" + '","password":"' + "{{$credentials.password}}" + '","scope":"' + "{{$credentials.scope}}" + '"}',
18
- },
19
- };
7
+ this.displayName = 'Runrunit API';
8
+ this.documentationUrl = 'https://github.com/org/-runrunit?tab=readme-ov-file#credentials';
20
9
  this.properties = [
21
10
  {
22
- displayName: 'Runrun.it URL',
23
- name: 'host',
24
- type: 'string',
25
- default: '',
26
- placeholder: 'https://runrun.example.com',
27
- required: true,
28
- description: 'URL base do Runrun.it (sem /api.php - será adicionado automaticamente)',
29
- },
30
- {
31
- displayName: 'Scope',
32
- name: 'scope',
33
- type: 'string',
34
- default: 'api graphql',
35
- required: true,
36
- description: 'Escopos de acesso para o token OAuth2 (ex: api graphql)',
37
- },
38
- {
39
- displayName: 'Client ID',
40
- name: 'clientId',
41
- type: 'string',
42
- required: true,
43
- default: '',
44
- description: 'Client ID gerado no Runrun.it (Setup > OAuth Clients)',
45
- },
46
- {
47
- displayName: 'Client Secret',
48
- name: 'clientSecret',
11
+ displayName: 'API Key',
12
+ name: 'apiKey',
49
13
  type: 'string',
50
14
  typeOptions: { password: true },
51
15
  required: true,
52
16
  default: '',
53
- description: 'Client Secret gerado no Runrun.it',
54
17
  },
55
- {
56
- displayName: 'Username',
57
- name: 'username',
58
- type: 'string',
59
- required: true,
60
- default: '',
61
- description: 'Usuário do Runrun.it a ser autenticado',
18
+ ];
19
+ this.authenticate = {
20
+ type: 'generic',
21
+ properties: {
22
+ headers: {
23
+ 'x-api-key': '={{$credentials.apiKey}}',
24
+ },
62
25
  },
63
- {
64
- displayName: 'Password',
65
- name: 'password',
66
- type: 'string',
67
- typeOptions: { password: true },
68
- required: true,
69
- default: '',
70
- description: 'Senha do usuário do Runrun.it',
26
+ };
27
+ this.test = {
28
+ request: {
29
+ baseURL: 'https://runrun.it/api/v1',
30
+ url: '/v1/user',
71
31
  },
72
- ];
32
+ };
73
33
  }
74
34
  }
75
35
  exports.RunrunitApi = RunrunitApi;
@@ -1 +1 @@
1
- {"version":3,"file":"RunrunitApi.credentials.js","sourceRoot":"","sources":["../../credentials/RunrunitApi.credentials.ts"],"names":[],"mappings":";;;AAEA,MAAa,WAAW;IAAxB;QACC,SAAI,GAAG,aAAa,CAAC;QAErB,gBAAW,GAAG,eAAe,CAAC;QAE9B,SAAI,GAAS,EAAE,KAAK,EAAE,4BAA4B,EAAE,IAAI,EAAE,iCAAiC,EAAE,CAAC;QAE9F,qBAAgB,GAAG,2DAA2D,CAAC;QAE/E,SAAI,GAA2B;YAC9B,OAAO,EAAE;gBACR,GAAG,EAAE,gEAAgE;gBACrE,MAAM,EAAE,MAAM;gBACd,OAAO,EAAE;oBACR,cAAc,EAAE,kBAAkB;iBAClC;gBACD,IAAI,EACH,yCAAyC,GAAG,2BAA2B,GAAG,qBAAqB,GAAG,+BAA+B,GAAG,gBAAgB,GAAG,2BAA2B,GAAG,gBAAgB,GAAG,2BAA2B,GAAG,aAAa,GAAG,wBAAwB,GAAG,IAAI;aACtR;SACD,CAAC;QAEF,eAAU,GAAsB;YAC/B;gBACC,WAAW,EAAE,eAAe;gBAC5B,IAAI,EAAE,MAAM;gBACZ,IAAI,EAAE,QAAQ;gBACd,OAAO,EAAE,EAAE;gBACX,WAAW,EAAE,4BAA4B;gBACzC,QAAQ,EAAE,IAAI;gBACd,WAAW,EAAE,wEAAwE;aACrF;YAED;gBACC,WAAW,EAAE,OAAO;gBACpB,IAAI,EAAE,OAAO;gBACb,IAAI,EAAE,QAAQ;gBACd,OAAO,EAAE,aAAa;gBACtB,QAAQ,EAAE,IAAI;gBACd,WAAW,EAAE,yDAAyD;aACtE;YACD;gBACC,WAAW,EAAE,WAAW;gBACxB,IAAI,EAAE,UAAU;gBAChB,IAAI,EAAE,QAAQ;gBACd,QAAQ,EAAE,IAAI;gBACd,OAAO,EAAE,EAAE;gBACX,WAAW,EAAE,uDAAuD;aACpE;YACD;gBACC,WAAW,EAAE,eAAe;gBAC5B,IAAI,EAAE,cAAc;gBACpB,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE;gBAC/B,QAAQ,EAAE,IAAI;gBACd,OAAO,EAAE,EAAE;gBACX,WAAW,EAAE,mCAAmC;aAChD;YACD;gBACC,WAAW,EAAE,UAAU;gBACvB,IAAI,EAAE,UAAU;gBAChB,IAAI,EAAE,QAAQ;gBACd,QAAQ,EAAE,IAAI;gBACd,OAAO,EAAE,EAAE;gBACX,WAAW,EAAE,wCAAwC;aACrD;YACD;gBACC,WAAW,EAAE,UAAU;gBACvB,IAAI,EAAE,UAAU;gBAChB,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE;gBAC/B,QAAQ,EAAE,IAAI;gBACd,OAAO,EAAE,EAAE;gBACX,WAAW,EAAE,+BAA+B;aAC5C;SACD,CAAC;IACH,CAAC;CAAA;AA3ED,kCA2EC"}
1
+ {"version":3,"file":"RunrunitApi.credentials.js","sourceRoot":"","sources":["../../credentials/RunrunitApi.credentials.ts"],"names":[],"mappings":";;;AAOA,MAAa,WAAW;IAAxB;QACC,SAAI,GAAG,aAAa,CAAC;QAErB,gBAAW,GAAG,cAAc,CAAC;QAG7B,qBAAgB,GAAG,iEAAiE,CAAC;QAErF,eAAU,GAAsB;YAC/B;gBACC,WAAW,EAAE,SAAS;gBACtB,IAAI,EAAE,QAAQ;gBACd,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE;gBAC/B,QAAQ,EAAE,IAAI;gBACd,OAAO,EAAE,EAAE;aACX;SACD,CAAC;QAEF,iBAAY,GAAyB;YACpC,IAAI,EAAE,SAAS;YACf,UAAU,EAAE;gBACX,OAAO,EAAE;oBACR,WAAW,EAAE,0BAA0B;iBACvC;aACD;SACD,CAAC;QAEF,SAAI,GAA2B;YAC9B,OAAO,EAAE;gBACR,OAAO,EAAE,0BAA0B;gBACnC,GAAG,EAAE,UAAU;aACf;SACD,CAAC;IACH,CAAC;CAAA;AAlCD,kCAkCC"}
@@ -0,0 +1,4 @@
1
+ import { type INodeType, type INodeTypeDescription } from 'n8n-workflow';
2
+ export declare class Runrunit implements INodeType {
3
+ description: INodeTypeDescription;
4
+ }
@@ -0,0 +1,56 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.Runrunit = void 0;
4
+ const n8n_workflow_1 = require("n8n-workflow");
5
+ const user_1 = require("./resources/user");
6
+ const company_1 = require("./resources/company");
7
+ class Runrunit {
8
+ constructor() {
9
+ this.description = {
10
+ displayName: 'Runrunit',
11
+ name: 'runrunit',
12
+ icon: { light: 'file:runrunit.svg', dark: 'file:runrunit.dark.svg' },
13
+ group: ['transform'],
14
+ version: 1,
15
+ subtitle: '={{$parameter["operation"] + ": " + $parameter["resource"]}}',
16
+ description: 'Interact with the Runrunit API',
17
+ defaults: {
18
+ name: 'Runrunit',
19
+ },
20
+ usableAsTool: true,
21
+ inputs: [n8n_workflow_1.NodeConnectionTypes.Main],
22
+ outputs: [n8n_workflow_1.NodeConnectionTypes.Main],
23
+ credentials: [{ name: 'runrunitApi', required: true }],
24
+ requestDefaults: {
25
+ baseURL: 'https://runrun.it/api/v1',
26
+ headers: {
27
+ Accept: 'application/json',
28
+ 'Content-Type': 'application/json',
29
+ },
30
+ },
31
+ properties: [
32
+ {
33
+ displayName: 'Resource',
34
+ name: 'resource',
35
+ type: 'options',
36
+ noDataExpression: true,
37
+ options: [
38
+ {
39
+ name: 'User',
40
+ value: 'user',
41
+ },
42
+ {
43
+ name: 'Company',
44
+ value: 'company',
45
+ },
46
+ ],
47
+ default: 'user',
48
+ },
49
+ ...user_1.userDescription,
50
+ ...company_1.companyDescription,
51
+ ],
52
+ };
53
+ }
54
+ }
55
+ exports.Runrunit = Runrunit;
56
+ //# sourceMappingURL=Runrunit.node.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Runrunit.node.js","sourceRoot":"","sources":["../../../nodes/Runrunit/Runrunit.node.ts"],"names":[],"mappings":";;;AAAA,+CAA8F;AAC9F,2CAAmD;AACnD,iDAAyD;AAEzD,MAAa,QAAQ;IAArB;QACC,gBAAW,GAAyB;YACnC,WAAW,EAAE,UAAU;YACvB,IAAI,EAAE,UAAU;YAChB,IAAI,EAAE,EAAE,KAAK,EAAE,mBAAmB,EAAE,IAAI,EAAE,wBAAwB,EAAE;YACpE,KAAK,EAAE,CAAC,WAAW,CAAC;YACpB,OAAO,EAAE,CAAC;YACV,QAAQ,EAAE,8DAA8D;YACxE,WAAW,EAAE,gCAAgC;YAC7C,QAAQ,EAAE;gBACT,IAAI,EAAE,UAAU;aAChB;YACD,YAAY,EAAE,IAAI;YAClB,MAAM,EAAE,CAAC,kCAAmB,CAAC,IAAI,CAAC;YAClC,OAAO,EAAE,CAAC,kCAAmB,CAAC,IAAI,CAAC;YACnC,WAAW,EAAE,CAAC,EAAE,IAAI,EAAE,aAAa,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;YACtD,eAAe,EAAE;gBAChB,OAAO,EAAE,0BAA0B;gBACnC,OAAO,EAAE;oBACR,MAAM,EAAE,kBAAkB;oBAC1B,cAAc,EAAE,kBAAkB;iBAClC;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;4BACC,IAAI,EAAE,MAAM;4BACZ,KAAK,EAAE,MAAM;yBACb;wBACD;4BACC,IAAI,EAAE,SAAS;4BACf,KAAK,EAAE,SAAS;yBAChB;qBACD;oBACD,OAAO,EAAE,MAAM;iBACf;gBACD,GAAG,sBAAe;gBAClB,GAAG,4BAAkB;aACrB;SACD,CAAC;IACH,CAAC;CAAA;AA7CD,4BA6CC"}
@@ -2,16 +2,16 @@
2
2
  "node": "n8n-nodes-runrunit",
3
3
  "nodeVersion": "1.0",
4
4
  "codexVersion": "1.0",
5
- "categories": ["Productivity", "IT Management"],
5
+ "categories": ["Development", "Developer Tools"],
6
6
  "resources": {
7
7
  "credentialDocumentation": [
8
8
  {
9
- "url": "https://github.com/glpi-project/glpi/blob/master/apirest.md"
9
+ "url": "https://github.com/org/repo?tab=readme-ov-file#credentials"
10
10
  }
11
11
  ],
12
12
  "primaryDocumentation": [
13
13
  {
14
- "url": "https://github.com/glpi-project/glpi/blob/master/apirest.md"
14
+ "url": "https://github.com/org/repo?tab=readme-ov-file"
15
15
  }
16
16
  ]
17
17
  }
@@ -0,0 +1,2 @@
1
+ import type { INodeProperties } from 'n8n-workflow';
2
+ export declare const companyGetManyDescription: INodeProperties[];
@@ -0,0 +1,62 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.companyGetManyDescription = void 0;
4
+ const showOnlyForCompanyGetMany = {
5
+ operation: ['getAll'],
6
+ resource: ['company'],
7
+ };
8
+ exports.companyGetManyDescription = [
9
+ {
10
+ displayName: 'Limit',
11
+ name: 'limit',
12
+ type: 'number',
13
+ displayOptions: {
14
+ show: {
15
+ ...showOnlyForCompanyGetMany,
16
+ returnAll: [false],
17
+ },
18
+ },
19
+ typeOptions: {
20
+ minValue: 1,
21
+ maxValue: 100,
22
+ },
23
+ default: 50,
24
+ routing: {
25
+ send: {
26
+ type: 'query',
27
+ property: 'limit',
28
+ },
29
+ output: {
30
+ maxResults: '={{$value}}',
31
+ },
32
+ },
33
+ description: 'Max number of results to return',
34
+ },
35
+ {
36
+ displayName: 'Return All',
37
+ name: 'returnAll',
38
+ type: 'boolean',
39
+ displayOptions: {
40
+ show: showOnlyForCompanyGetMany,
41
+ },
42
+ default: false,
43
+ description: 'Whether to return all results or only up to a given limit',
44
+ routing: {
45
+ send: {
46
+ paginate: '={{ $value }}',
47
+ },
48
+ operations: {
49
+ pagination: {
50
+ type: 'offset',
51
+ properties: {
52
+ limitParameter: 'limit',
53
+ offsetParameter: 'offset',
54
+ pageSize: 100,
55
+ type: 'query',
56
+ },
57
+ },
58
+ },
59
+ },
60
+ },
61
+ ];
62
+ //# sourceMappingURL=getAll.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getAll.js","sourceRoot":"","sources":["../../../../../nodes/Runrunit/resources/company/getAll.ts"],"names":[],"mappings":";;;AAEA,MAAM,yBAAyB,GAAG;IACjC,SAAS,EAAE,CAAC,QAAQ,CAAC;IACrB,QAAQ,EAAE,CAAC,SAAS,CAAC;CACrB,CAAC;AAEW,QAAA,yBAAyB,GAAsB;IAC3D;QACC,WAAW,EAAE,OAAO;QACpB,IAAI,EAAE,OAAO;QACb,IAAI,EAAE,QAAQ;QACd,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,GAAG,yBAAyB;gBAC5B,SAAS,EAAE,CAAC,KAAK,CAAC;aAClB;SACD;QACD,WAAW,EAAE;YACZ,QAAQ,EAAE,CAAC;YACX,QAAQ,EAAE,GAAG;SACb;QACD,OAAO,EAAE,EAAE;QACX,OAAO,EAAE;YACR,IAAI,EAAE;gBACL,IAAI,EAAE,OAAO;gBACb,QAAQ,EAAE,OAAO;aACjB;YACD,MAAM,EAAE;gBACP,UAAU,EAAE,aAAa;aACzB;SACD;QACD,WAAW,EAAE,iCAAiC;KAC9C;IACD;QACC,WAAW,EAAE,YAAY;QACzB,IAAI,EAAE,WAAW;QACjB,IAAI,EAAE,SAAS;QACf,cAAc,EAAE;YACf,IAAI,EAAE,yBAAyB;SAC/B;QACD,OAAO,EAAE,KAAK;QACd,WAAW,EAAE,2DAA2D;QACxE,OAAO,EAAE;YACR,IAAI,EAAE;gBACL,QAAQ,EAAE,eAAe;aACzB;YACD,UAAU,EAAE;gBACX,UAAU,EAAE;oBACX,IAAI,EAAE,QAAQ;oBACd,UAAU,EAAE;wBACX,cAAc,EAAE,OAAO;wBACvB,eAAe,EAAE,QAAQ;wBACzB,QAAQ,EAAE,GAAG;wBACb,IAAI,EAAE,OAAO;qBACb;iBACD;aACD;SACD;KACD;CACD,CAAC"}
@@ -0,0 +1,2 @@
1
+ import type { INodeProperties } from 'n8n-workflow';
2
+ export declare const companyDescription: INodeProperties[];
@@ -0,0 +1,35 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.companyDescription = void 0;
4
+ const getAll_1 = require("./getAll");
5
+ const showOnlyForCompanies = {
6
+ resource: ['company'],
7
+ };
8
+ exports.companyDescription = [
9
+ {
10
+ displayName: 'Operation',
11
+ name: 'operation',
12
+ type: 'options',
13
+ noDataExpression: true,
14
+ displayOptions: {
15
+ show: showOnlyForCompanies,
16
+ },
17
+ options: [
18
+ {
19
+ name: 'Get Many',
20
+ value: 'getAll',
21
+ action: 'Get companies',
22
+ description: 'Get companies',
23
+ routing: {
24
+ request: {
25
+ method: 'GET',
26
+ url: '/companies',
27
+ },
28
+ },
29
+ },
30
+ ],
31
+ default: 'getAll',
32
+ },
33
+ ...getAll_1.companyGetManyDescription,
34
+ ];
35
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../nodes/Runrunit/resources/company/index.ts"],"names":[],"mappings":";;;AACA,qCAAqD;AAErD,MAAM,oBAAoB,GAAG;IAC5B,QAAQ,EAAE,CAAC,SAAS,CAAC;CACrB,CAAC;AAEW,QAAA,kBAAkB,GAAsB;IACpD;QACC,WAAW,EAAE,WAAW;QACxB,IAAI,EAAE,WAAW;QACjB,IAAI,EAAE,SAAS;QACf,gBAAgB,EAAE,IAAI;QACtB,cAAc,EAAE;YACf,IAAI,EAAE,oBAAoB;SAC1B;QACD,OAAO,EAAE;YACR;gBACC,IAAI,EAAE,UAAU;gBAChB,KAAK,EAAE,QAAQ;gBACf,MAAM,EAAE,eAAe;gBACvB,WAAW,EAAE,eAAe;gBAC5B,OAAO,EAAE;oBACR,OAAO,EAAE;wBACR,MAAM,EAAE,KAAK;wBACb,GAAG,EAAE,YAAY;qBACjB;iBACD;aACD;SACD;QACD,OAAO,EAAE,QAAQ;KACjB;IACD,GAAG,kCAAyB;CAC5B,CAAC"}
@@ -0,0 +1,2 @@
1
+ import type { INodeProperties } from 'n8n-workflow';
2
+ export declare const userCreateDescription: INodeProperties[];
@@ -0,0 +1,27 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.userCreateDescription = void 0;
4
+ const showOnlyForUserCreate = {
5
+ operation: ['create'],
6
+ resource: ['user'],
7
+ };
8
+ exports.userCreateDescription = [
9
+ {
10
+ displayName: 'Name',
11
+ name: 'name',
12
+ type: 'string',
13
+ default: '',
14
+ required: true,
15
+ displayOptions: {
16
+ show: showOnlyForUserCreate,
17
+ },
18
+ description: 'The name of the user',
19
+ routing: {
20
+ send: {
21
+ type: 'body',
22
+ property: 'name',
23
+ },
24
+ },
25
+ },
26
+ ];
27
+ //# sourceMappingURL=create.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"create.js","sourceRoot":"","sources":["../../../../../nodes/Runrunit/resources/user/create.ts"],"names":[],"mappings":";;;AAEA,MAAM,qBAAqB,GAAG;IAC7B,SAAS,EAAE,CAAC,QAAQ,CAAC;IACrB,QAAQ,EAAE,CAAC,MAAM,CAAC;CAClB,CAAC;AAEW,QAAA,qBAAqB,GAAsB;IACvD;QACC,WAAW,EAAE,MAAM;QACnB,IAAI,EAAE,MAAM;QACZ,IAAI,EAAE,QAAQ;QACd,OAAO,EAAE,EAAE;QACX,QAAQ,EAAE,IAAI;QACd,cAAc,EAAE;YACf,IAAI,EAAE,qBAAqB;SAC3B;QACD,WAAW,EAAE,sBAAsB;QACnC,OAAO,EAAE;YACR,IAAI,EAAE;gBACL,IAAI,EAAE,MAAM;gBACZ,QAAQ,EAAE,MAAM;aAChB;SACD;KACD;CACD,CAAC"}
@@ -0,0 +1,2 @@
1
+ import type { INodeProperties } from 'n8n-workflow';
2
+ export declare const userGetDescription: INodeProperties[];
@@ -0,0 +1,18 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.userGetDescription = void 0;
4
+ const showOnlyForUserGet = {
5
+ operation: ['get'],
6
+ resource: ['user'],
7
+ };
8
+ exports.userGetDescription = [
9
+ {
10
+ displayName: 'User ID',
11
+ name: 'userId',
12
+ type: 'string',
13
+ displayOptions: { show: showOnlyForUserGet },
14
+ default: '',
15
+ description: "The user's ID to retrieve",
16
+ },
17
+ ];
18
+ //# sourceMappingURL=get.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"get.js","sourceRoot":"","sources":["../../../../../nodes/Runrunit/resources/user/get.ts"],"names":[],"mappings":";;;AAEA,MAAM,kBAAkB,GAAG;IAC1B,SAAS,EAAE,CAAC,KAAK,CAAC;IAClB,QAAQ,EAAE,CAAC,MAAM,CAAC;CAClB,CAAC;AAEW,QAAA,kBAAkB,GAAsB;IACpD;QACC,WAAW,EAAE,SAAS;QACtB,IAAI,EAAE,QAAQ;QACd,IAAI,EAAE,QAAQ;QACd,cAAc,EAAE,EAAE,IAAI,EAAE,kBAAkB,EAAE;QAC5C,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,2BAA2B;KACxC;CACD,CAAC"}
@@ -0,0 +1,2 @@
1
+ import type { INodeProperties } from 'n8n-workflow';
2
+ export declare const userDescription: INodeProperties[];
@@ -0,0 +1,61 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.userDescription = void 0;
4
+ const create_1 = require("./create");
5
+ const get_1 = require("./get");
6
+ const showOnlyForUsers = {
7
+ resource: ['user'],
8
+ };
9
+ exports.userDescription = [
10
+ {
11
+ displayName: 'Operation',
12
+ name: 'operation',
13
+ type: 'options',
14
+ noDataExpression: true,
15
+ displayOptions: {
16
+ show: showOnlyForUsers,
17
+ },
18
+ options: [
19
+ {
20
+ name: 'Get Many',
21
+ value: 'getAll',
22
+ action: 'Get users',
23
+ description: 'Get many users',
24
+ routing: {
25
+ request: {
26
+ method: 'GET',
27
+ url: '/users',
28
+ },
29
+ },
30
+ },
31
+ {
32
+ name: 'Get',
33
+ value: 'get',
34
+ action: 'Get a user',
35
+ description: 'Get the data of a single user',
36
+ routing: {
37
+ request: {
38
+ method: 'GET',
39
+ url: '=/users/{{$parameter.userId}}',
40
+ },
41
+ },
42
+ },
43
+ {
44
+ name: 'Create',
45
+ value: 'create',
46
+ action: 'Create a new user',
47
+ description: 'Create a new user',
48
+ routing: {
49
+ request: {
50
+ method: 'POST',
51
+ url: '/users',
52
+ },
53
+ },
54
+ },
55
+ ],
56
+ default: 'getAll',
57
+ },
58
+ ...get_1.userGetDescription,
59
+ ...create_1.userCreateDescription,
60
+ ];
61
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../nodes/Runrunit/resources/user/index.ts"],"names":[],"mappings":";;;AACA,qCAAiD;AACjD,+BAA2C;AAE3C,MAAM,gBAAgB,GAAG;IACxB,QAAQ,EAAE,CAAC,MAAM,CAAC;CAClB,CAAC;AAEW,QAAA,eAAe,GAAsB;IACjD;QACC,WAAW,EAAE,WAAW;QACxB,IAAI,EAAE,WAAW;QACjB,IAAI,EAAE,SAAS;QACf,gBAAgB,EAAE,IAAI;QACtB,cAAc,EAAE;YACf,IAAI,EAAE,gBAAgB;SACtB;QACD,OAAO,EAAE;YACR;gBACC,IAAI,EAAE,UAAU;gBAChB,KAAK,EAAE,QAAQ;gBACf,MAAM,EAAE,WAAW;gBACnB,WAAW,EAAE,gBAAgB;gBAC7B,OAAO,EAAE;oBACR,OAAO,EAAE;wBACR,MAAM,EAAE,KAAK;wBACb,GAAG,EAAE,QAAQ;qBACb;iBACD;aACD;YACD;gBACC,IAAI,EAAE,KAAK;gBACX,KAAK,EAAE,KAAK;gBACZ,MAAM,EAAE,YAAY;gBACpB,WAAW,EAAE,+BAA+B;gBAC5C,OAAO,EAAE;oBACR,OAAO,EAAE;wBACR,MAAM,EAAE,KAAK;wBACb,GAAG,EAAE,+BAA+B;qBACpC;iBACD;aACD;YACD;gBACC,IAAI,EAAE,QAAQ;gBACd,KAAK,EAAE,QAAQ;gBACf,MAAM,EAAE,mBAAmB;gBAC3B,WAAW,EAAE,mBAAmB;gBAChC,OAAO,EAAE;oBACR,OAAO,EAAE;wBACR,MAAM,EAAE,MAAM;wBACd,GAAG,EAAE,QAAQ;qBACb;iBACD;aACD;SACD;QACD,OAAO,EAAE,QAAQ;KACjB;IACD,GAAG,wBAAkB;IACrB,GAAG,8BAAqB;CACxB,CAAC"}
@@ -1,13 +1,13 @@
1
- <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512" width="512" height="512">
2
- <defs>
3
- <filter id="shadow-dark" x="-20%" y="-20%" width="140%" height="140%">
4
- <feDropShadow dx="-25" dy="25" stdDeviation="15" flood-color="#1a2530" flood-opacity="0.8"/>
5
- </filter>
6
- </defs>
7
-
8
- <g filter="url(#shadow-dark)">
9
- <rect x="32" y="32" width="448" height="448" rx="64" ry="64" fill="#2d3e50"/>
10
-
11
- <path d="M372,256c0,70.1-50.2,127.3-116.5,127.3S139,326.1,139,256s50.2-127.3,116.5-127.3S372,185.9,372,256ZM193.3,256c0,44,31.2,77.3,69.2,77.3s69.2-33.3,69.2-77.3-31.2-77.3-69.2-77.3S193.3,212,193.3,256Z" fill="#ffffff"/>
12
- </g>
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="aquamarine"
2
+ stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-cpu">
3
+ <rect x="4" y="4" width="16" height="16" rx="2" ry="2"></rect>
4
+ <rect x="9" y="9" width="6" height="6"></rect>
5
+ <line x1="9" y1="1" x2="9" y2="4"></line>
6
+ <line x1="15" y1="1" x2="15" y2="4"></line>
7
+ <line x1="9" y1="20" x2="9" y2="23"></line>
8
+ <line x1="15" y1="20" x2="15" y2="23"></line>
9
+ <line x1="20" y1="9" x2="23" y2="9"></line>
10
+ <line x1="20" y1="14" x2="23" y2="14"></line>
11
+ <line x1="1" y1="9" x2="4" y2="9"></line>
12
+ <line x1="1" y1="14" x2="4" y2="14"></line>
13
13
  </svg>
@@ -1,13 +1,13 @@
1
- <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512" width="512" height="512">
2
- <defs>
3
- <filter id="shadow" x="-20%" y="-20%" width="140%" height="140%">
4
- <feDropShadow dx="-25" dy="25" stdDeviation="10" flood-color="#ddd" flood-opacity="0.7"/>
5
- </filter>
6
- </defs>
7
-
8
- <g filter="url(#shadow)">
9
- <rect x="32" y="32" width="448" height="448" rx="64" ry="64" fill="#ffffff"/>
10
-
11
- <path d="M372,256c0,70.1-50.2,127.3-116.5,127.3S139,326.1,139,256s50.2-127.3,116.5-127.3S372,185.9,372,256ZM193.3,256c0,44,31.2,77.3,69.2,77.3s69.2-33.3,69.2-77.3-31.2-77.3-69.2-77.3S193.3,212,193.3,256Z" fill="#ff4c15"/>
12
- </g>
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="darkblue"
2
+ stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-cpu">
3
+ <rect x="4" y="4" width="16" height="16" rx="2" ry="2"></rect>
4
+ <rect x="9" y="9" width="6" height="6"></rect>
5
+ <line x1="9" y1="1" x2="9" y2="4"></line>
6
+ <line x1="15" y1="1" x2="15" y2="4"></line>
7
+ <line x1="9" y1="20" x2="9" y2="23"></line>
8
+ <line x1="15" y1="20" x2="15" y2="23"></line>
9
+ <line x1="20" y1="9" x2="23" y2="9"></line>
10
+ <line x1="20" y1="14" x2="23" y2="14"></line>
11
+ <line x1="1" y1="9" x2="4" y2="9"></line>
12
+ <line x1="1" y1="14" x2="4" y2="14"></line>
13
13
  </svg>