@atomoz/workflows-nodes 0.1.13 → 0.1.15

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 (196) hide show
  1. package/package.json +49 -51
  2. package/src/index.d.ts +0 -2
  3. package/src/index.d.ts.map +0 -1
  4. package/src/index.js +0 -1
  5. package/src/nodes/consts/index.d.ts +0 -3
  6. package/src/nodes/consts/index.d.ts.map +0 -1
  7. package/src/nodes/consts/index.js +0 -2
  8. package/src/nodes/consts/node-colors.d.ts +0 -7
  9. package/src/nodes/consts/node-colors.d.ts.map +0 -1
  10. package/src/nodes/consts/node-colors.js +0 -6
  11. package/src/nodes/consts/node-functions.d.ts +0 -20
  12. package/src/nodes/consts/node-functions.d.ts.map +0 -1
  13. package/src/nodes/consts/node-functions.js +0 -29
  14. package/src/nodes/consts/nodes.d.ts +0 -3
  15. package/src/nodes/consts/nodes.d.ts.map +0 -1
  16. package/src/nodes/consts/nodes.js +0 -30
  17. package/src/nodes/consts/schemas.d.ts +0 -30
  18. package/src/nodes/consts/schemas.d.ts.map +0 -1
  19. package/src/nodes/consts/schemas.js +0 -7
  20. package/src/nodes/ia/agent/data.d.ts +0 -11
  21. package/src/nodes/ia/agent/data.d.ts.map +0 -1
  22. package/src/nodes/ia/agent/data.js +0 -111
  23. package/src/nodes/ia/agent/function.d.ts +0 -2
  24. package/src/nodes/ia/agent/function.d.ts.map +0 -1
  25. package/src/nodes/ia/agent/function.js +0 -90
  26. package/src/nodes/ia/agent/index.d.ts +0 -3
  27. package/src/nodes/ia/agent/index.d.ts.map +0 -1
  28. package/src/nodes/ia/agent/index.js +0 -2
  29. package/src/nodes/ia/index.d.ts +0 -5
  30. package/src/nodes/ia/index.d.ts.map +0 -1
  31. package/src/nodes/ia/index.js +0 -4
  32. package/src/nodes/ia/message/index.d.ts +0 -2
  33. package/src/nodes/ia/message/index.d.ts.map +0 -1
  34. package/src/nodes/ia/message/index.js +0 -1
  35. package/src/nodes/ia/message/message.d.ts +0 -10
  36. package/src/nodes/ia/message/message.d.ts.map +0 -1
  37. package/src/nodes/ia/message/message.js +0 -118
  38. package/src/nodes/ia/supervisor/data.d.ts +0 -10
  39. package/src/nodes/ia/supervisor/data.d.ts.map +0 -1
  40. package/src/nodes/ia/supervisor/data.js +0 -84
  41. package/src/nodes/ia/supervisor/function.d.ts +0 -2
  42. package/src/nodes/ia/supervisor/function.d.ts.map +0 -1
  43. package/src/nodes/ia/supervisor/function.js +0 -227
  44. package/src/nodes/ia/supervisor/index.d.ts +0 -3
  45. package/src/nodes/ia/supervisor/index.d.ts.map +0 -1
  46. package/src/nodes/ia/supervisor/index.js +0 -2
  47. package/src/nodes/ia/tool/data.d.ts +0 -16
  48. package/src/nodes/ia/tool/data.d.ts.map +0 -1
  49. package/src/nodes/ia/tool/data.js +0 -70
  50. package/src/nodes/ia/tool/function.d.ts +0 -4
  51. package/src/nodes/ia/tool/function.d.ts.map +0 -1
  52. package/src/nodes/ia/tool/function.js +0 -36
  53. package/src/nodes/ia/tool/index.d.ts +0 -3
  54. package/src/nodes/ia/tool/index.d.ts.map +0 -1
  55. package/src/nodes/ia/tool/index.js +0 -2
  56. package/src/nodes/index.d.ts +0 -9
  57. package/src/nodes/index.d.ts.map +0 -1
  58. package/src/nodes/index.js +0 -8
  59. package/src/nodes/inputs/chat/chat.d.ts +0 -4
  60. package/src/nodes/inputs/chat/chat.d.ts.map +0 -1
  61. package/src/nodes/inputs/chat/chat.js +0 -51
  62. package/src/nodes/inputs/http/delete/data.d.ts +0 -3
  63. package/src/nodes/inputs/http/delete/data.d.ts.map +0 -1
  64. package/src/nodes/inputs/http/delete/data.js +0 -57
  65. package/src/nodes/inputs/http/delete/function.d.ts +0 -2
  66. package/src/nodes/inputs/http/delete/function.d.ts.map +0 -1
  67. package/src/nodes/inputs/http/delete/function.js +0 -28
  68. package/src/nodes/inputs/http/delete/index.d.ts +0 -4
  69. package/src/nodes/inputs/http/delete/index.d.ts.map +0 -1
  70. package/src/nodes/inputs/http/delete/index.js +0 -3
  71. package/src/nodes/inputs/http/delete/schema.d.ts +0 -16
  72. package/src/nodes/inputs/http/delete/schema.d.ts.map +0 -1
  73. package/src/nodes/inputs/http/delete/schema.js +0 -7
  74. package/src/nodes/inputs/http/get/data.d.ts +0 -3
  75. package/src/nodes/inputs/http/get/data.d.ts.map +0 -1
  76. package/src/nodes/inputs/http/get/data.js +0 -58
  77. package/src/nodes/inputs/http/get/function.d.ts +0 -2
  78. package/src/nodes/inputs/http/get/function.d.ts.map +0 -1
  79. package/src/nodes/inputs/http/get/function.js +0 -25
  80. package/src/nodes/inputs/http/get/index.d.ts +0 -4
  81. package/src/nodes/inputs/http/get/index.d.ts.map +0 -1
  82. package/src/nodes/inputs/http/get/index.js +0 -3
  83. package/src/nodes/inputs/http/get/schema.d.ts +0 -16
  84. package/src/nodes/inputs/http/get/schema.d.ts.map +0 -1
  85. package/src/nodes/inputs/http/get/schema.js +0 -7
  86. package/src/nodes/inputs/http/index.d.ts +0 -8
  87. package/src/nodes/inputs/http/index.d.ts.map +0 -1
  88. package/src/nodes/inputs/http/index.js +0 -10
  89. package/src/nodes/inputs/http/patch/data.d.ts +0 -3
  90. package/src/nodes/inputs/http/patch/data.d.ts.map +0 -1
  91. package/src/nodes/inputs/http/patch/data.js +0 -70
  92. package/src/nodes/inputs/http/patch/function.d.ts +0 -2
  93. package/src/nodes/inputs/http/patch/function.d.ts.map +0 -1
  94. package/src/nodes/inputs/http/patch/function.js +0 -36
  95. package/src/nodes/inputs/http/patch/index.d.ts +0 -4
  96. package/src/nodes/inputs/http/patch/index.d.ts.map +0 -1
  97. package/src/nodes/inputs/http/patch/index.js +0 -3
  98. package/src/nodes/inputs/http/patch/schema.d.ts +0 -21
  99. package/src/nodes/inputs/http/patch/schema.d.ts.map +0 -1
  100. package/src/nodes/inputs/http/patch/schema.js +0 -8
  101. package/src/nodes/inputs/http/post/data.d.ts +0 -3
  102. package/src/nodes/inputs/http/post/data.d.ts.map +0 -1
  103. package/src/nodes/inputs/http/post/data.js +0 -70
  104. package/src/nodes/inputs/http/post/function.d.ts +0 -2
  105. package/src/nodes/inputs/http/post/function.d.ts.map +0 -1
  106. package/src/nodes/inputs/http/post/function.js +0 -36
  107. package/src/nodes/inputs/http/post/index.d.ts +0 -4
  108. package/src/nodes/inputs/http/post/index.d.ts.map +0 -1
  109. package/src/nodes/inputs/http/post/index.js +0 -3
  110. package/src/nodes/inputs/http/post/schema.d.ts +0 -21
  111. package/src/nodes/inputs/http/post/schema.d.ts.map +0 -1
  112. package/src/nodes/inputs/http/post/schema.js +0 -8
  113. package/src/nodes/inputs/http/put/data.d.ts +0 -3
  114. package/src/nodes/inputs/http/put/data.d.ts.map +0 -1
  115. package/src/nodes/inputs/http/put/data.js +0 -70
  116. package/src/nodes/inputs/http/put/function.d.ts +0 -2
  117. package/src/nodes/inputs/http/put/function.d.ts.map +0 -1
  118. package/src/nodes/inputs/http/put/function.js +0 -36
  119. package/src/nodes/inputs/http/put/index.d.ts +0 -4
  120. package/src/nodes/inputs/http/put/index.d.ts.map +0 -1
  121. package/src/nodes/inputs/http/put/index.js +0 -3
  122. package/src/nodes/inputs/http/put/schema.d.ts +0 -21
  123. package/src/nodes/inputs/http/put/schema.d.ts.map +0 -1
  124. package/src/nodes/inputs/http/put/schema.js +0 -8
  125. package/src/nodes/inputs/http/schemas.d.ts +0 -18
  126. package/src/nodes/inputs/http/schemas.d.ts.map +0 -1
  127. package/src/nodes/inputs/http/schemas.js +0 -17
  128. package/src/nodes/inputs/http/utils.d.ts +0 -21
  129. package/src/nodes/inputs/http/utils.d.ts.map +0 -1
  130. package/src/nodes/inputs/http/utils.js +0 -63
  131. package/src/nodes/inputs/index.d.ts +0 -5
  132. package/src/nodes/inputs/index.d.ts.map +0 -1
  133. package/src/nodes/inputs/index.js +0 -4
  134. package/src/nodes/inputs/manual/trigger.d.ts +0 -4
  135. package/src/nodes/inputs/manual/trigger.d.ts.map +0 -1
  136. package/src/nodes/inputs/manual/trigger.js +0 -39
  137. package/src/nodes/output-node/index.d.ts +0 -4
  138. package/src/nodes/output-node/index.d.ts.map +0 -1
  139. package/src/nodes/output-node/index.js +0 -123
  140. package/src/nodes/outputs/chat/output.d.ts +0 -4
  141. package/src/nodes/outputs/chat/output.d.ts.map +0 -1
  142. package/src/nodes/outputs/chat/output.js +0 -48
  143. package/src/nodes/outputs/http-output.d.ts +0 -4
  144. package/src/nodes/outputs/http-output.d.ts.map +0 -1
  145. package/src/nodes/outputs/http-output.js +0 -76
  146. package/src/nodes/processors/concat.d.ts +0 -9
  147. package/src/nodes/processors/concat.d.ts.map +0 -1
  148. package/src/nodes/processors/concat.js +0 -68
  149. package/src/nodes/processors/custom-code.d.ts +0 -4
  150. package/src/nodes/processors/custom-code.d.ts.map +0 -1
  151. package/src/nodes/processors/custom-code.js +0 -54
  152. package/src/nodes/processors/index.d.ts +0 -2
  153. package/src/nodes/processors/index.d.ts.map +0 -1
  154. package/src/nodes/processors/index.js +0 -1
  155. package/src/nodes/processors/transform.d.ts +0 -3
  156. package/src/nodes/processors/transform.d.ts.map +0 -1
  157. package/src/nodes/processors/transform.js +0 -48
  158. package/src/nodes/social/index.d.ts +0 -2
  159. package/src/nodes/social/index.d.ts.map +0 -1
  160. package/src/nodes/social/index.js +0 -1
  161. package/src/nodes/social/whatsapp/index.d.ts +0 -4
  162. package/src/nodes/social/whatsapp/index.d.ts.map +0 -1
  163. package/src/nodes/social/whatsapp/index.js +0 -3
  164. package/src/nodes/social/whatsapp/message-trigger/data.d.ts +0 -3
  165. package/src/nodes/social/whatsapp/message-trigger/data.d.ts.map +0 -1
  166. package/src/nodes/social/whatsapp/message-trigger/data.js +0 -55
  167. package/src/nodes/social/whatsapp/message-trigger/index.d.ts +0 -2
  168. package/src/nodes/social/whatsapp/message-trigger/index.d.ts.map +0 -1
  169. package/src/nodes/social/whatsapp/message-trigger/index.js +0 -1
  170. package/src/nodes/social/whatsapp/send-message/data.d.ts +0 -8
  171. package/src/nodes/social/whatsapp/send-message/data.d.ts.map +0 -1
  172. package/src/nodes/social/whatsapp/send-message/data.js +0 -46
  173. package/src/nodes/social/whatsapp/send-message/functions.d.ts +0 -3
  174. package/src/nodes/social/whatsapp/send-message/functions.d.ts.map +0 -1
  175. package/src/nodes/social/whatsapp/send-message/functions.js +0 -32
  176. package/src/nodes/social/whatsapp/send-message/index.d.ts +0 -3
  177. package/src/nodes/social/whatsapp/send-message/index.d.ts.map +0 -1
  178. package/src/nodes/social/whatsapp/send-message/index.js +0 -2
  179. package/src/nodes/social/whatsapp/send-template/data.d.ts +0 -8
  180. package/src/nodes/social/whatsapp/send-template/data.d.ts.map +0 -1
  181. package/src/nodes/social/whatsapp/send-template/data.js +0 -42
  182. package/src/nodes/social/whatsapp/send-template/functions.d.ts +0 -5
  183. package/src/nodes/social/whatsapp/send-template/functions.d.ts.map +0 -1
  184. package/src/nodes/social/whatsapp/send-template/functions.js +0 -60
  185. package/src/nodes/social/whatsapp/send-template/index.d.ts +0 -3
  186. package/src/nodes/social/whatsapp/send-template/index.d.ts.map +0 -1
  187. package/src/nodes/social/whatsapp/send-template/index.js +0 -2
  188. package/src/nodes/types/base-node.d.ts +0 -17
  189. package/src/nodes/types/base-node.d.ts.map +0 -1
  190. package/src/nodes/types/base-node.js +0 -1
  191. package/src/nodes/types/base-node.types.d.ts +0 -144
  192. package/src/nodes/types/base-node.types.d.ts.map +0 -1
  193. package/src/nodes/types/base-node.types.js +0 -1
  194. package/src/utils/llm-factory.d.ts +0 -16
  195. package/src/utils/llm-factory.d.ts.map +0 -1
  196. package/src/utils/llm-factory.js +0 -110
@@ -1,36 +0,0 @@
1
- // "use server";
2
- export const HttpPostInputNodeFunction = (params) => {
3
- const { request, fieldValues } = params;
4
- const { queryParams: configQueryParams, headers: configHeaders, body: configBody } = fieldValues || {};
5
- if (request.method !== 'POST') {
6
- throw new Error('Método HTTP inválido');
7
- }
8
- const actualData = {
9
- queryParams: request?.query || {},
10
- headers: request?.headers || {},
11
- body: request?.body || {},
12
- ip: request?.ip || '127.0.0.1',
13
- };
14
- if (configQueryParams) {
15
- const requiredParams = configQueryParams.filter((p) => p.required);
16
- const missingParams = requiredParams.filter((p) => !actualData.queryParams[p.key]);
17
- if (missingParams.length > 0) {
18
- throw new Error(`Parâmetros obrigatórios ausentes: ${missingParams.map((p) => p.key).join(', ')}`);
19
- }
20
- }
21
- if (configHeaders) {
22
- const requiredHeaders = configHeaders.filter((h) => h.required);
23
- const missingHeaders = requiredHeaders.filter((h) => !actualData.headers[h.key.toLowerCase()]);
24
- if (missingHeaders.length > 0) {
25
- throw new Error(`Headers obrigatórios ausentes: ${missingHeaders.map((h) => h.key).join(', ')}`);
26
- }
27
- }
28
- if (configBody) {
29
- const requiredBodyFields = configBody.filter((f) => f.required);
30
- const missingBodyFields = requiredBodyFields.filter((f) => !actualData.body[f.key]);
31
- if (missingBodyFields.length > 0) {
32
- throw new Error(`Campos obrigatórios do body ausentes: ${missingBodyFields.map((f) => f.key).join(', ')}`);
33
- }
34
- }
35
- return actualData;
36
- };
@@ -1,4 +0,0 @@
1
- export * from './data';
2
- export * from './function';
3
- export * from './schema';
4
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../../libs/nodes/src/nodes/inputs/http/post/index.ts"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAC;AACvB,cAAc,YAAY,CAAC;AAC3B,cAAc,UAAU,CAAC"}
@@ -1,3 +0,0 @@
1
- export * from './data';
2
- export * from './function';
3
- export * from './schema';
@@ -1,21 +0,0 @@
1
- import { z } from "zod";
2
- export declare const HttpPostInputNodeSchema: z.ZodObject<{
3
- route: z.ZodString;
4
- queryParams: z.ZodOptional<z.ZodArray<z.ZodObject<{
5
- key: z.ZodString;
6
- value: z.ZodOptional<z.ZodString>;
7
- required: z.ZodOptional<z.ZodBoolean>;
8
- }, z.core.$strip>>>;
9
- headers: z.ZodOptional<z.ZodArray<z.ZodObject<{
10
- key: z.ZodString;
11
- value: z.ZodOptional<z.ZodString>;
12
- required: z.ZodOptional<z.ZodBoolean>;
13
- }, z.core.$strip>>>;
14
- body: z.ZodOptional<z.ZodArray<z.ZodObject<{
15
- key: z.ZodString;
16
- value: z.ZodOptional<z.ZodAny>;
17
- required: z.ZodOptional<z.ZodBoolean>;
18
- }, z.core.$strip>>>;
19
- }, z.core.$strip>;
20
- export type HttpPostInputNodeType = z.infer<typeof HttpPostInputNodeSchema>;
21
- //# sourceMappingURL=schema.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../../../../../../libs/nodes/src/nodes/inputs/http/post/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;iBAKlC,CAAC;AAEH,MAAM,MAAM,qBAAqB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC"}
@@ -1,8 +0,0 @@
1
- import { z } from "zod";
2
- import { RouteSchema, QueryParamSchema, HeaderSchema, BodyFieldSchema } from "../schemas";
3
- export const HttpPostInputNodeSchema = z.object({
4
- route: RouteSchema,
5
- queryParams: z.array(QueryParamSchema).optional().describe("Query parameters configuration"),
6
- headers: z.array(HeaderSchema).optional().describe("Headers configuration"),
7
- body: z.array(BodyFieldSchema).optional().describe("Body fields configuration"),
8
- });
@@ -1,3 +0,0 @@
1
- import { NodeData } from "../../../types/base-node";
2
- export declare const HttpPutInputNode: NodeData;
3
- //# sourceMappingURL=data.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"data.d.ts","sourceRoot":"","sources":["../../../../../../../../libs/nodes/src/nodes/inputs/http/put/data.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AAEpD,eAAO,MAAM,gBAAgB,EAAE,QAqE9B,CAAC"}
@@ -1,70 +0,0 @@
1
- export const HttpPutInputNode = {
2
- label: 'Http PUT Input',
3
- type: 'HttpPutInput',
4
- category: 'input',
5
- icon: '📝',
6
- description: 'Node que representa uma rota PUT HTTP para atualização completa de recursos',
7
- tags: {
8
- execution: 'sync',
9
- group: 'HTTP'
10
- },
11
- fields: [
12
- {
13
- id: 'route',
14
- label: 'Route',
15
- type: 'route',
16
- required: true,
17
- placeholder: '/produtos/{id}',
18
- },
19
- {
20
- id: 'queryParams',
21
- label: 'Query Params',
22
- type: 'keyValue',
23
- required: false,
24
- handle: {
25
- type: 'output',
26
- label: 'Query Params',
27
- name: 'queryParams',
28
- fieldType: 'keyValue',
29
- }
30
- },
31
- {
32
- id: 'headers',
33
- label: 'Headers',
34
- type: 'keyValue',
35
- required: false,
36
- handle: {
37
- type: 'output',
38
- label: 'Headers',
39
- name: 'headers',
40
- fieldType: 'keyValue',
41
- }
42
- },
43
- {
44
- id: 'body',
45
- label: 'Body',
46
- type: 'object',
47
- required: false,
48
- handle: {
49
- type: 'output',
50
- label: 'Body',
51
- name: 'body',
52
- fieldType: 'object',
53
- required: false
54
- }
55
- },
56
- {
57
- id: 'ip',
58
- label: 'Request IP',
59
- type: 'string',
60
- required: false,
61
- typeable: false,
62
- handle: {
63
- type: 'output',
64
- label: 'IP',
65
- name: 'ip',
66
- fieldType: 'string',
67
- }
68
- }
69
- ]
70
- };
@@ -1,2 +0,0 @@
1
- export declare const HttpPutInputNodeFunction: (params: any) => any;
2
- //# sourceMappingURL=function.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"function.d.ts","sourceRoot":"","sources":["../../../../../../../../libs/nodes/src/nodes/inputs/http/put/function.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,wBAAwB,GAAI,QAAQ,GAAG,KAAG,GAwCtD,CAAC"}
@@ -1,36 +0,0 @@
1
- // "use server";
2
- export const HttpPutInputNodeFunction = (params) => {
3
- const { request, fieldValues } = params;
4
- const { queryParams: configQueryParams, headers: configHeaders, body: configBody } = fieldValues || {};
5
- if (request.method !== 'PUT') {
6
- throw new Error('Método HTTP inválido');
7
- }
8
- const actualData = {
9
- queryParams: request?.query || {},
10
- headers: request?.headers || {},
11
- body: request?.body || {},
12
- ip: request?.ip || '127.0.0.1',
13
- };
14
- if (configQueryParams) {
15
- const requiredParams = configQueryParams.filter((p) => p.required);
16
- const missingParams = requiredParams.filter((p) => !actualData.queryParams[p.key]);
17
- if (missingParams.length > 0) {
18
- throw new Error(`Parâmetros obrigatórios ausentes: ${missingParams.map((p) => p.key).join(', ')}`);
19
- }
20
- }
21
- if (configHeaders) {
22
- const requiredHeaders = configHeaders.filter((h) => h.required);
23
- const missingHeaders = requiredHeaders.filter((h) => !actualData.headers[h.key.toLowerCase()]);
24
- if (missingHeaders.length > 0) {
25
- throw new Error(`Headers obrigatórios ausentes: ${missingHeaders.map((h) => h.key).join(', ')}`);
26
- }
27
- }
28
- if (configBody) {
29
- const requiredBodyFields = configBody.filter((f) => f.required);
30
- const missingBodyFields = requiredBodyFields.filter((f) => !actualData.body[f.key]);
31
- if (missingBodyFields.length > 0) {
32
- throw new Error(`Campos obrigatórios do body ausentes: ${missingBodyFields.map((f) => f.key).join(', ')}`);
33
- }
34
- }
35
- return actualData;
36
- };
@@ -1,4 +0,0 @@
1
- export * from './data';
2
- export * from './function';
3
- export * from './schema';
4
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../../libs/nodes/src/nodes/inputs/http/put/index.ts"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAC;AACvB,cAAc,YAAY,CAAC;AAC3B,cAAc,UAAU,CAAC"}
@@ -1,3 +0,0 @@
1
- export * from './data';
2
- export * from './function';
3
- export * from './schema';
@@ -1,21 +0,0 @@
1
- import { z } from "zod";
2
- export declare const HttpPutInputNodeSchema: z.ZodObject<{
3
- route: z.ZodString;
4
- queryParams: z.ZodOptional<z.ZodArray<z.ZodObject<{
5
- key: z.ZodString;
6
- value: z.ZodOptional<z.ZodString>;
7
- required: z.ZodOptional<z.ZodBoolean>;
8
- }, z.core.$strip>>>;
9
- headers: z.ZodOptional<z.ZodArray<z.ZodObject<{
10
- key: z.ZodString;
11
- value: z.ZodOptional<z.ZodString>;
12
- required: z.ZodOptional<z.ZodBoolean>;
13
- }, z.core.$strip>>>;
14
- body: z.ZodOptional<z.ZodArray<z.ZodObject<{
15
- key: z.ZodString;
16
- value: z.ZodOptional<z.ZodAny>;
17
- required: z.ZodOptional<z.ZodBoolean>;
18
- }, z.core.$strip>>>;
19
- }, z.core.$strip>;
20
- export type HttpPutInputNodeType = z.infer<typeof HttpPutInputNodeSchema>;
21
- //# sourceMappingURL=schema.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../../../../../../libs/nodes/src/nodes/inputs/http/put/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;iBAKjC,CAAC;AAEH,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAC"}
@@ -1,8 +0,0 @@
1
- import { z } from "zod";
2
- import { RouteSchema, QueryParamSchema, HeaderSchema, BodyFieldSchema } from "../schemas";
3
- export const HttpPutInputNodeSchema = z.object({
4
- route: RouteSchema,
5
- queryParams: z.array(QueryParamSchema).optional().describe("Query parameters configuration"),
6
- headers: z.array(HeaderSchema).optional().describe("Headers configuration"),
7
- body: z.array(BodyFieldSchema).optional().describe("Body fields configuration"),
8
- });
@@ -1,18 +0,0 @@
1
- import { z } from "zod";
2
- export declare const QueryParamSchema: z.ZodObject<{
3
- key: z.ZodString;
4
- value: z.ZodOptional<z.ZodString>;
5
- required: z.ZodOptional<z.ZodBoolean>;
6
- }, z.core.$strip>;
7
- export declare const HeaderSchema: z.ZodObject<{
8
- key: z.ZodString;
9
- value: z.ZodOptional<z.ZodString>;
10
- required: z.ZodOptional<z.ZodBoolean>;
11
- }, z.core.$strip>;
12
- export declare const BodyFieldSchema: z.ZodObject<{
13
- key: z.ZodString;
14
- value: z.ZodOptional<z.ZodAny>;
15
- required: z.ZodOptional<z.ZodBoolean>;
16
- }, z.core.$strip>;
17
- export declare const RouteSchema: z.ZodString;
18
- //# sourceMappingURL=schemas.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"schemas.d.ts","sourceRoot":"","sources":["../../../../../../../libs/nodes/src/nodes/inputs/http/schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,gBAAgB;;;;iBAI3B,CAAC;AAEH,eAAO,MAAM,YAAY;;;;iBAIvB,CAAC;AAEH,eAAO,MAAM,eAAe;;;;iBAI1B,CAAC;AAEH,eAAO,MAAM,WAAW,aAAyC,CAAC"}
@@ -1,17 +0,0 @@
1
- import { z } from "zod";
2
- export const QueryParamSchema = z.object({
3
- key: z.string(),
4
- value: z.string().optional(),
5
- required: z.boolean().optional()
6
- });
7
- export const HeaderSchema = z.object({
8
- key: z.string(),
9
- value: z.string().optional(),
10
- required: z.boolean().optional()
11
- });
12
- export const BodyFieldSchema = z.object({
13
- key: z.string(),
14
- value: z.any().optional(),
15
- required: z.boolean().optional()
16
- });
17
- export const RouteSchema = z.string().describe("HTTP route path");
@@ -1,21 +0,0 @@
1
- export declare const HTTP_NODE_TYPES: {
2
- readonly GET: "HttpGetInput";
3
- readonly POST: "HttpPostInput";
4
- readonly PUT: "HttpPutInput";
5
- readonly DELETE: "HttpDeleteInput";
6
- readonly PATCH: "HttpPatchInput";
7
- };
8
- export declare const HTTP_METHODS: readonly ["GET", "POST", "PUT", "DELETE", "PATCH"];
9
- export type HttpMethod = typeof HTTP_METHODS[number];
10
- export type HttpNodeType = typeof HTTP_NODE_TYPES[keyof typeof HTTP_NODE_TYPES];
11
- export declare const getHttpNodesTypes: () => string[];
12
- export declare const getHttpNodeTypesArray: () => HttpNodeType[];
13
- export declare const isHttpInputNode: (nodeType: string) => boolean;
14
- export declare const isHttpMethodNode: (nodeType: string, method: HttpMethod) => boolean;
15
- export declare const extractHttpMethodFromNodeType: (nodeType: string) => HttpMethod;
16
- export declare const getHttpMethodFromNodeType: (nodeType: string) => HttpMethod;
17
- export declare const isAnyHttpInputNode: (nodeType: string) => boolean;
18
- export declare const getHttpNodeTypeStrings: () => string[];
19
- export declare const isHttpInputFriendlyId: (friendlyId: string) => boolean;
20
- export declare const getHttpMethodFromFriendlyId: (friendlyId: string) => HttpMethod;
21
- //# sourceMappingURL=utils.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../../../../../libs/nodes/src/nodes/inputs/http/utils.ts"],"names":[],"mappings":"AAOA,eAAO,MAAM,eAAe;;;;;;CAMlB,CAAC;AAEX,eAAO,MAAM,YAAY,oDAAqD,CAAC;AAE/E,MAAM,MAAM,UAAU,GAAG,OAAO,YAAY,CAAC,MAAM,CAAC,CAAC;AACrD,MAAM,MAAM,YAAY,GAAG,OAAO,eAAe,CAAC,MAAM,OAAO,eAAe,CAAC,CAAC;AAGhF,eAAO,MAAM,iBAAiB,QAAO,MAAM,EAQ1C,CAAC;AAGF,eAAO,MAAM,qBAAqB,QAAO,YAAY,EAEpD,CAAC;AAGF,eAAO,MAAM,eAAe,GAAI,UAAU,MAAM,KAAG,OAElD,CAAC;AAGF,eAAO,MAAM,gBAAgB,GAAI,UAAU,MAAM,EAAE,QAAQ,UAAU,KAAG,OAEvE,CAAC;AAGF,eAAO,MAAM,6BAA6B,GAAI,UAAU,MAAM,KAAG,UAOhE,CAAC;AAGF,eAAO,MAAM,yBAAyB,aAVkB,MAAM,KAAG,UAUK,CAAC;AAGvE,eAAO,MAAM,kBAAkB,GAAI,UAAU,MAAM,KAAG,OAErD,CAAC;AAGF,eAAO,MAAM,sBAAsB,QAAO,MAAM,EAE/C,CAAC;AAGF,eAAO,MAAM,qBAAqB,GAAI,YAAY,MAAM,KAAG,OAE1D,CAAC;AAGF,eAAO,MAAM,2BAA2B,GAAI,YAAY,MAAM,KAAG,UAEhE,CAAC"}
@@ -1,63 +0,0 @@
1
- import { HttpGetInputNode } from "./get/data";
2
- import { HttpPatchInputNode } from "./patch/data";
3
- import { HttpDeleteInputNode } from './delete/data';
4
- import { HttpPostInputNode } from './post/data';
5
- import { HttpPutInputNode } from './put/data';
6
- // HTTP Node Types
7
- export const HTTP_NODE_TYPES = {
8
- GET: 'HttpGetInput',
9
- POST: 'HttpPostInput',
10
- PUT: 'HttpPutInput',
11
- DELETE: 'HttpDeleteInput',
12
- PATCH: 'HttpPatchInput',
13
- };
14
- export const HTTP_METHODS = ['GET', 'POST', 'PUT', 'DELETE', 'PATCH'];
15
- // Get all HTTP node types
16
- export const getHttpNodesTypes = () => {
17
- return [
18
- HttpGetInputNode,
19
- HttpPostInputNode,
20
- HttpPutInputNode,
21
- HttpDeleteInputNode,
22
- HttpPatchInputNode,
23
- ].map(node => node.type);
24
- };
25
- // Get HTTP node types as array
26
- export const getHttpNodeTypesArray = () => {
27
- return Object.values(HTTP_NODE_TYPES);
28
- };
29
- // Check if a node type is an HTTP input node
30
- export const isHttpInputNode = (nodeType) => {
31
- return getHttpNodeTypesArray().some(httpType => nodeType.includes(httpType));
32
- };
33
- // Check if a node type is a specific HTTP method
34
- export const isHttpMethodNode = (nodeType, method) => {
35
- return nodeType.includes(HTTP_NODE_TYPES[method]);
36
- };
37
- // Extract HTTP method from node type
38
- export const extractHttpMethodFromNodeType = (nodeType) => {
39
- for (const [method, nodeTypeValue] of Object.entries(HTTP_NODE_TYPES)) {
40
- if (nodeType.includes(nodeTypeValue)) {
41
- return method;
42
- }
43
- }
44
- return 'GET'; // Default fallback
45
- };
46
- // Get HTTP method from node type (alias for consistency)
47
- export const getHttpMethodFromNodeType = extractHttpMethodFromNodeType;
48
- // Check if a node type is any HTTP input node
49
- export const isAnyHttpInputNode = (nodeType) => {
50
- return nodeType.includes('Http') && nodeType.includes('Input');
51
- };
52
- // Get all HTTP node type strings for filtering
53
- export const getHttpNodeTypeStrings = () => {
54
- return Object.values(HTTP_NODE_TYPES);
55
- };
56
- // Check if a friendlyId is an HTTP input
57
- export const isHttpInputFriendlyId = (friendlyId) => {
58
- return friendlyId.includes('Http') && friendlyId.includes('Input');
59
- };
60
- // Get HTTP method from friendlyId
61
- export const getHttpMethodFromFriendlyId = (friendlyId) => {
62
- return extractHttpMethodFromNodeType(friendlyId);
63
- };
@@ -1,5 +0,0 @@
1
- export * from './http/get';
2
- export * from './http/post';
3
- export * from './chat/chat';
4
- export * from './manual/trigger';
5
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../libs/nodes/src/nodes/inputs/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,aAAa,CAAC;AAC5B,cAAc,kBAAkB,CAAC"}
@@ -1,4 +0,0 @@
1
- export * from './http/get';
2
- export * from './http/post';
3
- export * from './chat/chat';
4
- export * from './manual/trigger';
@@ -1,4 +0,0 @@
1
- import { NodeData } from "../../types/base-node";
2
- export declare const ManualTriggerNodeFunction: (params: any) => any;
3
- export declare const ManualTriggerNode: NodeData;
4
- //# sourceMappingURL=trigger.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"trigger.d.ts","sourceRoot":"","sources":["../../../../../../../libs/nodes/src/nodes/inputs/manual/trigger.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAGjD,eAAO,MAAM,yBAAyB,GAAI,QAAQ,GAAG,KAAG,GAIvD,CAAC;AAEF,eAAO,MAAM,iBAAiB,EAAE,QAgC/B,CAAC"}
@@ -1,39 +0,0 @@
1
- // Função do node ManualTrigger: apenas retorna os valores configurados
2
- export const ManualTriggerNodeFunction = (params) => {
3
- const { fieldValues } = params || {};
4
- // Normaliza: para keyValue manter array; para simples retornar literal
5
- return fieldValues || {};
6
- };
7
- export const ManualTriggerNode = {
8
- label: 'Manual Trigger',
9
- type: 'ManualTrigger',
10
- category: 'input',
11
- icon: '🖐️',
12
- description: 'Dispara fluxo manualmente e envia campos dinâmicos',
13
- tags: {
14
- execution: 'sync',
15
- group: 'Custom'
16
- },
17
- fields: [
18
- {
19
- id: 'stringExample',
20
- label: 'String Example',
21
- type: 'string',
22
- handle: { type: 'output', label: 'String', name: 'stringExample', fieldType: 'string' },
23
- placeholder: 'Ex.: valor literal',
24
- },
25
- {
26
- id: 'numberExample',
27
- label: 'Number Example',
28
- type: 'number',
29
- handle: { type: 'output', label: 'Number', name: 'numberExample', fieldType: 'number' },
30
- placeholder: 'Ex.: 123',
31
- },
32
- {
33
- id: 'keyValue1',
34
- label: 'Key/Value 1',
35
- type: 'keyValue',
36
- handle: { type: 'output', label: 'Key/Value', name: 'keyValue1', fieldType: 'keyValue' },
37
- }
38
- ]
39
- };
@@ -1,4 +0,0 @@
1
- import { NodeData } from "../types/base-node";
2
- export declare const HttpOutputNodeFunction: (params: any) => any;
3
- export declare const OutputNode: NodeData;
4
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../libs/nodes/src/nodes/output-node/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAE9C,eAAO,MAAM,sBAAsB,GAAI,QAAQ,GAAG,KAAG,GAwClD,CAAC;AAwBJ,eAAO,MAAM,UAAU,EAAE,QAiExB,CAAC"}
@@ -1,123 +0,0 @@
1
- export const HttpOutputNodeFunction = (params) => {
2
- const { fieldValues, results } = params;
3
- // Usar fieldValues.data como dados de resposta (contém os placeholders configurados)
4
- let responseData = fieldValues?.data || {};
5
- // Se responseData é um objeto com placeholders, processar
6
- if (typeof responseData === 'object' && responseData !== null) {
7
- // Processar placeholders usando os inputs resolvidos
8
- const processedData = {};
9
- for (const [key, value] of Object.entries(responseData)) {
10
- if (typeof value === 'string' && value.includes('{{')) {
11
- // Processar placeholders usando os results
12
- processedData[key] = processPlaceholders(value, results);
13
- }
14
- else {
15
- processedData[key] = value;
16
- }
17
- }
18
- responseData = processedData;
19
- }
20
- else if (typeof responseData === 'string') {
21
- // Se é uma string simples, criar um objeto com a string
22
- responseData = { value: responseData };
23
- }
24
- // Configurações padrão
25
- const status = fieldValues?.status || 200;
26
- const headers = fieldValues?.headers || {};
27
- // Validações
28
- if (status && (status < 100 || status > 599)) {
29
- throw new Error(`Status HTTP inválido: ${status}`);
30
- }
31
- return {
32
- status,
33
- headers,
34
- data: responseData,
35
- isHttpResponse: true
36
- };
37
- };
38
- function processPlaceholders(value, results) {
39
- // Substituir placeholders por valores dos results
40
- return value.replace(/\{\{(.*?)\}\}/g, (match, placeholder) => {
41
- // Extrair friendlyId e campo do placeholder
42
- const parts = placeholder.split('-');
43
- const friendlyId = parts[0];
44
- const fieldName = parts[1];
45
- const keyName = parts.length > 2 ? parts[2] : undefined;
46
- const sourceResult = results[friendlyId];
47
- if (sourceResult) {
48
- if (keyName) {
49
- return sourceResult[fieldName]?.[keyName] || keyName;
50
- }
51
- else {
52
- return sourceResult[fieldName] || '';
53
- }
54
- }
55
- return match; // Manter placeholder se não encontrar
56
- });
57
- }
58
- export const OutputNode = {
59
- label: 'Http Output Node',
60
- type: 'HttpOutput',
61
- category: 'output',
62
- icon: '📤',
63
- description: 'Node de saída do workflow que aceita qualquer entrada e retorna ela diretamente',
64
- group: 'HTTP',
65
- tags: {
66
- execution: 'sync',
67
- group: 'HTTP'
68
- },
69
- fields: [
70
- {
71
- id: 'status',
72
- label: 'Status Code',
73
- type: 'select',
74
- required: true,
75
- defaultValue: 200,
76
- options: [
77
- { label: '200 - OK', value: 200 },
78
- { label: '201 - Created', value: 201 },
79
- { label: '204 - No Content', value: 204 },
80
- { label: '400 - Bad Request', value: 400 },
81
- { label: '401 - Unauthorized', value: 401 },
82
- { label: '403 - Forbidden', value: 403 },
83
- { label: '404 - Not Found', value: 404 },
84
- { label: '422 - Unprocessable Entity', value: 422 },
85
- { label: '500 - Internal Server Error', value: 500 }
86
- ],
87
- handle: {
88
- type: 'output',
89
- label: 'Status',
90
- name: 'status',
91
- fieldType: 'number',
92
- required: true
93
- }
94
- },
95
- {
96
- id: 'headers',
97
- label: 'Response Headers',
98
- type: 'keyValue',
99
- required: false,
100
- defaultValue: {},
101
- handle: {
102
- type: 'output',
103
- label: 'Headers',
104
- name: 'headers',
105
- fieldType: 'object',
106
- required: false
107
- }
108
- },
109
- {
110
- id: 'data',
111
- label: 'Response Data',
112
- type: 'json',
113
- required: true,
114
- handle: {
115
- type: 'input',
116
- label: 'Data',
117
- name: 'data',
118
- fieldType: 'json',
119
- required: true
120
- }
121
- }
122
- ]
123
- };
@@ -1,4 +0,0 @@
1
- import { NodeData } from "../../types/base-node";
2
- export declare const ChatOutputNodeFunction: (params: any) => Promise<any>;
3
- export declare const ChatOutputNode: NodeData;
4
- //# sourceMappingURL=output.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"output.d.ts","sourceRoot":"","sources":["../../../../../../../libs/nodes/src/nodes/outputs/chat/output.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAEjD,eAAO,MAAM,sBAAsB,GAAU,QAAQ,GAAG,KAAG,OAAO,CAAC,GAAG,CAiBrE,CAAC;AAEF,eAAO,MAAM,cAAc,EAAE,QAyB5B,CAAC"}