@pipefy/pipefy-process-coder 0.1.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 (92) hide show
  1. package/.agents/skills/ppc-pipefy-flow-authoring/SKILL.md +262 -0
  2. package/.agents/skills/ppc-pipefy-flow-authoring/examples/01-main-2-danfe-consulta.json +247 -0
  3. package/.agents/skills/ppc-pipefy-flow-authoring/examples/01-main-2-webhook-retorno-consulta.json +589 -0
  4. package/.agents/skills/ppc-pipefy-flow-authoring/examples/01-main-4-recebimento-barramento.json +1391 -0
  5. package/.agents/skills/ppc-pipefy-flow-authoring/examples/02-subflow-2-danfe-retorno.json +623 -0
  6. package/.agents/skills/ppc-pipefy-flow-authoring/examples/02-subflow-4-criacao-operacao.json +636 -0
  7. package/.agents/skills/ppc-pipefy-flow-authoring/examples/03-subflow-4-criacao-titulo.json +3642 -0
  8. package/.agents/skills/ppc-pipefy-flow-authoring/examples/04-subflow-4-criacao-cedente.json +863 -0
  9. package/.agents/skills/ppc-pipefy-flow-authoring/examples/04-subflow-4-criacao-sacado.json +799 -0
  10. package/.agents/skills/ppc-pipefy-flow-authoring/examples/README.md +42 -0
  11. package/.agents/skills/ppc-pipefy-flow-authoring/examples/hml-01-subflow-1-titulo-acompanhamento-cobranca.json +581 -0
  12. package/.agents/skills/ppc-pipefy-flow-authoring/examples/hml-01-subflow-1-titulo-nfe-monitoramento.json +503 -0
  13. package/.agents/skills/ppc-pipefy-flow-authoring/examples/hml-01-subflow-1-titulo-retorno-bancario.json +562 -0
  14. package/.agents/skills/ppc-pipefy-flow-authoring/examples/hml-02-subflow-2-retorno-consulta-cedente.json +557 -0
  15. package/.agents/skills/ppc-pipefy-flow-authoring/examples/hml-02-subflow-2-retorno-consulta-sacado.json +609 -0
  16. package/.agents/skills/ppc-pipefy-pipe-authoring/SKILL.md +146 -0
  17. package/.agents/skills/ppc-pipefy-process-design/SKILL.md +127 -0
  18. package/.agents/skills/ppc-pipefy-workspace/SKILL.md +91 -0
  19. package/AGENTS.md +456 -0
  20. package/README.md +808 -0
  21. package/bin/pipe.js +13 -0
  22. package/package.json +35 -0
  23. package/src/apply/adopt.ts +150 -0
  24. package/src/apply/agentops.ts +71 -0
  25. package/src/apply/compile.ts +875 -0
  26. package/src/apply/execute.ts +336 -0
  27. package/src/apply/flowops.ts +399 -0
  28. package/src/apply/idmap.ts +241 -0
  29. package/src/apply/mutations.ts +955 -0
  30. package/src/apply/registry.ts +430 -0
  31. package/src/apply/types.ts +134 -0
  32. package/src/cli/args.ts +88 -0
  33. package/src/cli.ts +211 -0
  34. package/src/codec/flow.ts +199 -0
  35. package/src/codec/pack.ts +103 -0
  36. package/src/codec/roundtrip.ts +94 -0
  37. package/src/codec/unpack.ts +198 -0
  38. package/src/commands/agents.ts +184 -0
  39. package/src/commands/apply.ts +1144 -0
  40. package/src/commands/context.ts +119 -0
  41. package/src/commands/create.ts +79 -0
  42. package/src/commands/diff.ts +314 -0
  43. package/src/commands/flows.ts +414 -0
  44. package/src/commands/misc.ts +644 -0
  45. package/src/commands/plan.ts +331 -0
  46. package/src/commands/pull.ts +567 -0
  47. package/src/commands/runs.ts +83 -0
  48. package/src/commands/skills.ts +137 -0
  49. package/src/commands/verify.ts +253 -0
  50. package/src/config.ts +168 -0
  51. package/src/diff/agents.ts +122 -0
  52. package/src/diff/diff.ts +1130 -0
  53. package/src/diff/flow.ts +318 -0
  54. package/src/diff/html.ts +322 -0
  55. package/src/diff/render.ts +101 -0
  56. package/src/model/payload.ts +154 -0
  57. package/src/model/tree.ts +99 -0
  58. package/src/model/volatile.ts +55 -0
  59. package/src/pipefy/agents.ts +165 -0
  60. package/src/pipefy/automations.ts +219 -0
  61. package/src/pipefy/capability.ts +119 -0
  62. package/src/pipefy/client.ts +267 -0
  63. package/src/pipefy/discovery.ts +209 -0
  64. package/src/pipefy/internal.ts +380 -0
  65. package/src/pipefy/ipaas.ts +365 -0
  66. package/src/pipefy/reconstruct.ts +775 -0
  67. package/src/pipefy/reference.ts +251 -0
  68. package/src/pipefy/snapshot.ts +245 -0
  69. package/src/pipefy/toolkit.ts +200 -0
  70. package/src/pipefy/toolkit_bearer.py +137 -0
  71. package/src/report/integrations.ts +231 -0
  72. package/src/report/run.ts +475 -0
  73. package/src/util/fsx.ts +45 -0
  74. package/src/util/git.ts +32 -0
  75. package/src/util/json.ts +55 -0
  76. package/src/util/log.ts +76 -0
  77. package/src/util/pool.ts +48 -0
  78. package/src/util/slug.ts +26 -0
  79. package/src/util/tui.ts +335 -0
  80. package/src/validate/index.ts +123 -0
  81. package/src/validate/integrity.ts +387 -0
  82. package/src/validate/reference.ts +136 -0
  83. package/src/validate/schema.ts +328 -0
  84. package/src/workspace/agents.ts +290 -0
  85. package/src/workspace/docs.ts +407 -0
  86. package/src/workspace/flows.ts +191 -0
  87. package/src/workspace/layout.ts +165 -0
  88. package/src/workspace/lock.ts +148 -0
  89. package/src/workspace/read.ts +165 -0
  90. package/src/workspace/reference.ts +24 -0
  91. package/src/workspace/stamp.ts +301 -0
  92. package/src/workspace/write.ts +225 -0
@@ -0,0 +1,557 @@
1
+ {
2
+ "name": "✅[PRD][HML][2/2 SUBFLOW][RETORNO CONSULTA/UPDATE] Retorno Cedente",
3
+ "type": "SHARED",
4
+ "summary": "",
5
+ "description": "",
6
+ "tags": [],
7
+ "blogUrl": "",
8
+ "metadata": {
9
+ "externalId": "exampleFlowId02aaaaaa"
10
+ },
11
+ "author": "Integrações Ipaas 000000000",
12
+ "categories": [],
13
+ "pieces": [
14
+ "@activepieces/piece-subflows",
15
+ "@activepieces/piece-pipefy"
16
+ ],
17
+ "flows": [
18
+ {
19
+ "displayName": "✅[PRD][HML][2/2 SUBFLOW][RETORNO CONSULTA/UPDATE] Retorno Cedente",
20
+ "trigger": {
21
+ "name": "trigger",
22
+ "valid": true,
23
+ "displayName": "Callable Flow",
24
+ "nextAction": {
25
+ "name": "step_2",
26
+ "type": "PIECE",
27
+ "valid": true,
28
+ "settings": {
29
+ "input": {
30
+ "auth": "{{connections['exampleConnectionId3']}}",
31
+ "pipeId": "200000004",
32
+ "fieldId": "idcedente",
33
+ "fieldValue": "{{trigger['output']['data']['cedente']['idCedente']}}",
34
+ "organizationId": "100000001"
35
+ },
36
+ "pieceName": "@activepieces/piece-pipefy",
37
+ "actionName": "getCardsByFieldValue",
38
+ "sampleData": {},
39
+ "pieceVersion": "0.1.7",
40
+ "propertySettings": {
41
+ "pipeId": {
42
+ "type": "MANUAL"
43
+ },
44
+ "fieldId": {
45
+ "type": "MANUAL"
46
+ },
47
+ "fieldValue": {
48
+ "type": "MANUAL"
49
+ },
50
+ "organizationId": {
51
+ "type": "MANUAL"
52
+ }
53
+ },
54
+ "errorHandlingOptions": {
55
+ "retryOnFailure": {
56
+ "value": false
57
+ },
58
+ "continueOnFailure": {
59
+ "value": false
60
+ }
61
+ }
62
+ },
63
+ "nextAction": {
64
+ "name": "step_13",
65
+ "skip": false,
66
+ "type": "CODE",
67
+ "valid": true,
68
+ "settings": {
69
+ "input": {
70
+ "cards": "{{step_2['output']['data']['cards']}}",
71
+ "empresaCodigo": "{{trigger['output']['data']['cedente']['codigoEmpresa']}}"
72
+ },
73
+ "sampleData": {},
74
+ "sourceCode": {
75
+ "code": "export const code = async (inputs) => {\n const alvo = String(inputs.empresaCodigo ?? '').trim();\n\n const card = inputs.cards.find(\n c => String(c.fields?.empresacodigo?.value ?? '').trim() === alvo\n );\n\n return {\n cardId: card?.id ?? null,\n encontrado: !!card\n };\n};",
76
+ "packageJson": "{}"
77
+ },
78
+ "errorHandlingOptions": {
79
+ "retryOnFailure": {
80
+ "value": false
81
+ },
82
+ "continueOnFailure": {
83
+ "value": false
84
+ }
85
+ }
86
+ },
87
+ "nextAction": {
88
+ "name": "step_3",
89
+ "skip": false,
90
+ "type": "ROUTER",
91
+ "valid": true,
92
+ "children": [
93
+ {
94
+ "name": "step_6",
95
+ "skip": false,
96
+ "type": "CODE",
97
+ "valid": true,
98
+ "settings": {
99
+ "input": {
100
+ "email": "{{trigger['output']['data']['cedente']['email']}}",
101
+ "cnpjOuCpf": "{{trigger['output']['data']['cedente']['cnpjOuCpf']}}",
102
+ "telefoneContato ": "{{trigger['output']['data']['cedente']['telefoneContato']}}",
103
+ "vinculoGrupoEconomico": "{{trigger['output']['data']['cedente']['vinculoGrupoEconomico']}}"
104
+ },
105
+ "sampleData": {},
106
+ "sourceCode": {
107
+ "code": "export const code = async (inputs) => {\n // Normaliza chaves removendo espaços extras\n const normalizedInputs = {};\n for (const key in inputs) {\n normalizedInputs[key.trim()] = inputs[key];\n }\n inputs = normalizedInputs;\n\n // DDDs válidos no Brasil (nenhum começa com 0 ou 1)\n const DDD_VALIDOS = new Set([\n '11','12','13','14','15','16','17','18','19',\n '21','22','24',\n '27','28',\n '31','32','33','34','35','37','38',\n '41','42','43','44','45','46',\n '47','48','49',\n '51','53','54','55',\n '61',\n '62','63','64',\n '65','66',\n '67',\n '68',\n '69',\n '71','73','74','75','77',\n '79',\n '81','82','83','84','87',\n '85','88','86','89',\n '91','92','93','94','97',\n '95',\n '96',\n '98','99',\n ]);\n\n // ===== Normaliza telefone =====\n let telefoneContato = '';\n let telefoneContatoFormatado = '';\n if (inputs.telefoneContato) {\n let numeros = String(inputs.telefoneContato).replace(/\\D/g, '');\n\n // Remove o 55 inicial se já vier com código do país\n if ((numeros.length === 12 || numeros.length === 13) && numeros.startsWith('55')) {\n numeros = numeros.substring(2);\n }\n\n // Corrige prefixo \"0\" indevido antes do DDD (ex: \"084 3064-6035\" -> \"84 3064-6035\")\n // Nenhum DDD começa com 0, então um \"0\" sobrando aqui sempre indica esse erro de digitação/formatação,\n // seja em número fixo (11 dígitos -> 10) ou celular (12 dígitos -> 11)\n if (numeros.startsWith('0') && (numeros.length === 11 || numeros.length === 12)) {\n numeros = numeros.substring(1);\n }\n\n // Sanity check adicional: se o DDD calculado não é válido, tenta reancorar\n // deslocando um dígito (cobre outros casos de dígito extra vazado no começo)\n const dddCandidato = numeros.substring(0, 2);\n if (!DDD_VALIDOS.has(dddCandidato) && (numeros.length === 11 || numeros.length === 12)) {\n const dddAlternativo = numeros.substring(1, 3);\n if (DDD_VALIDOS.has(dddAlternativo)) {\n numeros = numeros.substring(1);\n }\n }\n\n if (numeros.length === 11) {\n // Celular com DDD\n const ddd = numeros.substring(0, 2);\n const parte1 = numeros.substring(2, 7);\n const parte2 = numeros.substring(7);\n telefoneContato = `55${numeros}`;\n telefoneContatoFormatado = `+55 (${ddd}) ${parte1}-${parte2}`;\n } else if (numeros.length === 10) {\n // Fixo com DDD\n const ddd = numeros.substring(0, 2);\n const parte1 = numeros.substring(2, 6);\n const parte2 = numeros.substring(6);\n telefoneContato = `55${numeros}`;\n telefoneContatoFormatado = `+55 (${ddd}) ${parte1}-${parte2}`;\n } else {\n telefoneContato = numeros;\n telefoneContatoFormatado = numeros;\n }\n }\n\n // ===== Normaliza e-mails =====\n let email = '';\n let emailCheck = true;\n if (inputs.email) {\n const emailStr = String(inputs.email);\n if (!emailStr.includes('@')) {\n email = emailStr;\n emailCheck = false;\n } else {\n const emailRegex = /^[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\\.[A-Za-z]{2,}$/;\n const validos = emailStr\n .split(/[;,\\s]+/)\n .map((e) => e.trim())\n .filter((e) => e && emailRegex.test(e));\n email = Array.from(new Set(validos)).join(', ');\n }\n }\n\n // ===== Identifica e formata CPF/CNPJ =====\n let cpf = '';\n let cnpj = '';\n let tipo = '';\n if (inputs.cnpjOuCpf) {\n const doc = String(inputs.cnpjOuCpf).replace(/\\D/g, '');\n if (doc.length === 11) {\n cpf = `${doc.substring(0, 3)}.${doc.substring(3, 6)}.${doc.substring(6, 9)}-${doc.substring(9)}`;\n tipo = 'cpf';\n } else if (doc.length === 14) {\n cnpj = `${doc.substring(0, 2)}.${doc.substring(2, 5)}.${doc.substring(5, 8)}/${doc.substring(8, 12)}-${doc.substring(12)}`;\n tipo = 'cnpj';\n }\n }\n\n // ===== Normaliza vínculo a grupo econômico =====\n let vinculoGrupoEconomico = '';\n if (inputs.vinculoGrupoEconomico !== undefined && inputs.vinculoGrupoEconomico !== null) {\n const valor = String(inputs.vinculoGrupoEconomico).trim().toLowerCase();\n if (valor === 'true' || valor === 'sim' || valor === '1') {\n vinculoGrupoEconomico = 'Sim';\n } else if (valor === 'false' || valor === 'não' || valor === 'nao' || valor === '0') {\n vinculoGrupoEconomico = 'Não';\n }\n }\n\n return {\n telefoneContato,\n telefoneContatoFormatado,\n email,\n emailCheck,\n tipo,\n cpf,\n cnpj,\n vinculoGrupoEconomico,\n };\n};",
108
+ "packageJson": "{}"
109
+ },
110
+ "errorHandlingOptions": {
111
+ "retryOnFailure": {
112
+ "value": false
113
+ },
114
+ "continueOnFailure": {
115
+ "value": false
116
+ }
117
+ }
118
+ },
119
+ "nextAction": {
120
+ "name": "step_1",
121
+ "skip": true,
122
+ "type": "CODE",
123
+ "valid": true,
124
+ "settings": {
125
+ "input": {
126
+ "email": "{{trigger['output']['data']['cedente']['email']}}",
127
+ "cnpjOuCpf": "{{trigger['output']['data']['cedente']['cnpjOuCpf']}}",
128
+ "telefoneContato ": "{{trigger['output']['data']['cedente']['telefoneContato']}}",
129
+ "vinculoGrupoEconomico": "{{trigger['output']['data']['cedente']['vinculoGrupoEconomico']}}"
130
+ },
131
+ "sampleData": {},
132
+ "sourceCode": {
133
+ "code": "export const code = async (inputs) => {\n // Normaliza chaves removendo espaços extras\n const normalizedInputs = {};\n for (const key in inputs) {\n normalizedInputs[key.trim()] = inputs[key];\n }\n inputs = normalizedInputs;\n // ===== Normaliza telefone =====\n let telefoneContato = '';\n let telefoneContatoFormatado = '';\n if (inputs.telefoneContato) {\n let numeros = String(inputs.telefoneContato).replace(/\\D/g, '');\n // Remove o 55 inicial se já vier com código do país\n if ((numeros.length === 12 || numeros.length === 13) && numeros.startsWith('55')) {\n numeros = numeros.substring(2);\n }\n if (numeros.length === 11) {\n // Celular com DDD\n const ddd = numeros.substring(0, 2);\n const parte1 = numeros.substring(2, 7);\n const parte2 = numeros.substring(7);\n telefoneContato = `55${numeros}`;\n telefoneContatoFormatado = `+55 (${ddd}) ${parte1}-${parte2}`;\n } else if (numeros.length === 10) {\n // Fixo com DDD\n const ddd = numeros.substring(0, 2);\n const parte1 = numeros.substring(2, 6);\n const parte2 = numeros.substring(6);\n telefoneContato = `55${numeros}`;\n telefoneContatoFormatado = `+55 (${ddd}) ${parte1}-${parte2}`;\n } else {\n telefoneContato = numeros;\n telefoneContatoFormatado = numeros;\n }\n }\n // ===== Normaliza e-mails =====\n let email = '';\n let emailCheck = true;\n if (inputs.email) {\n const emailStr = String(inputs.email);\n if (!emailStr.includes('@')) {\n email = emailStr;\n emailCheck = false;\n } else {\n const emailRegex = /^[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\\.[A-Za-z]{2,}$/;\n const validos = emailStr\n .split(/[;,\\s]+/)\n .map((e) => e.trim())\n .filter((e) => e && emailRegex.test(e));\n email = Array.from(new Set(validos)).join(', ');\n }\n }\n // ===== Identifica e formata CPF/CNPJ =====\n let cpf = '';\n let cnpj = '';\n let tipo = '';\n if (inputs.cnpjOuCpf) {\n const doc = String(inputs.cnpjOuCpf).replace(/\\D/g, '');\n if (doc.length === 11) {\n cpf = `${doc.substring(0, 3)}.${doc.substring(3, 6)}.${doc.substring(6, 9)}-${doc.substring(9)}`;\n tipo = 'cpf';\n } else if (doc.length === 14) {\n cnpj = `${doc.substring(0, 2)}.${doc.substring(2, 5)}.${doc.substring(5, 8)}/${doc.substring(8, 12)}-${doc.substring(12)}`;\n tipo = 'cnpj';\n }\n }\n // ===== Normaliza vínculo a grupo econômico =====\n let vinculoGrupoEconomico = '';\n if (inputs.vinculoGrupoEconomico !== undefined && inputs.vinculoGrupoEconomico !== null) {\n const valor = String(inputs.vinculoGrupoEconomico).trim().toLowerCase();\n if (valor === 'true' || valor === 'sim' || valor === '1') {\n vinculoGrupoEconomico = 'Sim';\n } else if (valor === 'false' || valor === 'não' || valor === 'nao' || valor === '0') {\n vinculoGrupoEconomico = 'Não';\n }\n }\n return {\n telefoneContato,\n telefoneContatoFormatado,\n email,\n emailCheck,\n tipo,\n cpf,\n cnpj,\n vinculoGrupoEconomico,\n };\n};",
134
+ "packageJson": "{}"
135
+ },
136
+ "errorHandlingOptions": {
137
+ "retryOnFailure": {
138
+ "value": false
139
+ },
140
+ "continueOnFailure": {
141
+ "value": false
142
+ }
143
+ }
144
+ },
145
+ "nextAction": {
146
+ "name": "step_5",
147
+ "skip": false,
148
+ "type": "PIECE",
149
+ "valid": true,
150
+ "settings": {
151
+ "input": {
152
+ "auth": "{{connections['exampleConnectionId3']}}",
153
+ "cardId": "{{step_13['output']['cardId']}}",
154
+ "pipeId": "200000004",
155
+ "phaseId": "300000003",
156
+ "phaseFields": {
157
+ "cep": "{{trigger['output']['data']['cedente']['cep']}}",
158
+ "cpf": "{{step_6['output']['cpf']}}",
159
+ "cnpj": "{{step_6['output']['cnpj']}}",
160
+ "nome": "{{trigger['output']['data']['cedente']['nome']}}",
161
+ "email": "{{step_6['output']['email']}}",
162
+ "cidade": "{{trigger['output']['data']['cedente']['cidade']}}",
163
+ "estado": "{{trigger['output']['data']['cedente']['estado']}}",
164
+ "endere_o": "{{trigger['output']['data']['cedente']['endereco']}}",
165
+ "data_de_cadastro": "{{trigger['output']['data']['cedente']['dataCadastro']}}",
166
+ "analista_respons_vel": [],
167
+ "id_do_grupo_principal": "{{trigger['output']['data']['cedente']['idGrupoPrincipal']}}",
168
+ "v_nculo_com_grupo_econ_mico": "{{step_6['output']['vinculoGrupoEconomico']}}"
169
+ },
170
+ "organizationId": "100000001"
171
+ },
172
+ "pieceName": "@activepieces/piece-pipefy",
173
+ "actionName": "updateCard",
174
+ "sampleData": {},
175
+ "pieceVersion": "0.1.7",
176
+ "propertySettings": {
177
+ "cardId": {
178
+ "type": "MANUAL"
179
+ },
180
+ "pipeId": {
181
+ "type": "MANUAL"
182
+ },
183
+ "phaseId": {
184
+ "type": "MANUAL"
185
+ },
186
+ "phaseFields": {
187
+ "type": "MANUAL",
188
+ "schema": {
189
+ "cep": {
190
+ "type": "SHORT_TEXT",
191
+ "required": false,
192
+ "description": "\"cedente\"\n\"cep\"",
193
+ "displayName": "CEP"
194
+ },
195
+ "cpf": {
196
+ "type": "SHORT_TEXT",
197
+ "required": false,
198
+ "description": "\"cedente\"\n\"cnpjOuCpf\"",
199
+ "displayName": "CPF"
200
+ },
201
+ "cnpj": {
202
+ "type": "SHORT_TEXT",
203
+ "required": false,
204
+ "description": "\"cedente\"\n\"cnpjOuCpf\"",
205
+ "displayName": "CNPJ"
206
+ },
207
+ "nome": {
208
+ "type": "SHORT_TEXT",
209
+ "required": false,
210
+ "description": "\"cedente\"\n\"nome\"",
211
+ "displayName": "Nome"
212
+ },
213
+ "email": {
214
+ "type": "LONG_TEXT",
215
+ "required": false,
216
+ "description": "\"cedente\"\n\"email\"",
217
+ "displayName": "E-mail"
218
+ },
219
+ "cidade": {
220
+ "type": "SHORT_TEXT",
221
+ "required": false,
222
+ "description": "\"cedente\"\n\"cidade\"",
223
+ "displayName": "Cidade"
224
+ },
225
+ "estado": {
226
+ "type": "SHORT_TEXT",
227
+ "required": false,
228
+ "description": "\"cedente\"\n\"estado\"",
229
+ "displayName": "Estado"
230
+ },
231
+ "d_start": {
232
+ "type": "SHORT_TEXT",
233
+ "required": false,
234
+ "description": "⚙️ Quando o card for criado colocar D Start padrão (Automação)",
235
+ "displayName": "D Start"
236
+ },
237
+ "endere_o": {
238
+ "type": "LONG_TEXT",
239
+ "required": false,
240
+ "description": "\"cedente\"\n\"endereco\"",
241
+ "displayName": "Endereço"
242
+ },
243
+ "idcedente": {
244
+ "type": "SHORT_TEXT",
245
+ "required": false,
246
+ "description": "\"cedente\"\n\"idCedente\"",
247
+ "displayName": "ID Cedente (Barramento)"
248
+ },
249
+ "empresacodigo": {
250
+ "type": "SHORT_TEXT",
251
+ "required": false,
252
+ "description": "\"cedente\"\n\"codigoEmpresa\"",
253
+ "displayName": "empresaCodigo"
254
+ },
255
+ "data_de_cadastro": {
256
+ "type": "SHORT_TEXT",
257
+ "required": false,
258
+ "description": "\"cedente\"\n\"dataCadastro\"",
259
+ "displayName": "Data de cadastro"
260
+ },
261
+ "telefone_de_contato": {
262
+ "type": "NUMBER",
263
+ "required": false,
264
+ "description": "\"cedente\"\n\"telefoneContato\"",
265
+ "displayName": "Telefone de contato"
266
+ },
267
+ "analista_respons_vel": {
268
+ "type": "STATIC_MULTI_SELECT_DROPDOWN",
269
+ "options": {
270
+ "options": [],
271
+ "disabled": false
272
+ },
273
+ "required": false,
274
+ "description": "⚙️ Quando o campo \"Nome do analista responsável\" for preenchido. Buscar nome na base \"DB - Analista responsável\" e popular o campo com o responsável",
275
+ "displayName": "Analista responsável"
276
+ },
277
+ "id_do_grupo_principal": {
278
+ "type": "NUMBER",
279
+ "required": false,
280
+ "description": "\"cedente\"\n\"idGrupoPrincipal\"\n⚙️ vai ser utilizado para quando alterar o responsável de um cedente do grupo muda de todos os outros cedentes deste mesmo grupo",
281
+ "displayName": "ID do grupo principal"
282
+ },
283
+ "observa_es_da_carteira": {
284
+ "type": "LONG_TEXT",
285
+ "required": false,
286
+ "description": "👤 Preenchido pela operação",
287
+ "displayName": "Observações da carteira"
288
+ },
289
+ "db_analista_respons_vel": {
290
+ "type": "SHORT_TEXT",
291
+ "required": false,
292
+ "description": "⚙️ Quando o campo \"Nome do analista responsável\" for preenchido. Buscar nome na base \"DB - Analista responsável\" e popular o campo com o responsável",
293
+ "displayName": "DB - Analista responsável"
294
+ },
295
+ "v_nculo_com_grupo_econ_mico": {
296
+ "type": "STATIC_DROPDOWN",
297
+ "options": {
298
+ "options": [],
299
+ "disabled": false
300
+ },
301
+ "required": false,
302
+ "description": "\"cedente\"\n\"vinculoGrupoEconomico\"",
303
+ "displayName": "Vínculo com grupo econômico"
304
+ },
305
+ "nome_do_analista_respons_vel": {
306
+ "type": "SHORT_TEXT",
307
+ "required": false,
308
+ "description": "\"cedente\"\n\"analistaResponsavel\"",
309
+ "displayName": "Nome do analista responsável"
310
+ }
311
+ }
312
+ },
313
+ "organizationId": {
314
+ "type": "MANUAL"
315
+ },
316
+ "v_nculo_com_grupo_econ_mico": {
317
+ "type": "DYNAMIC"
318
+ }
319
+ },
320
+ "errorHandlingOptions": {
321
+ "retryOnFailure": {
322
+ "value": false
323
+ },
324
+ "continueOnFailure": {
325
+ "value": false
326
+ }
327
+ }
328
+ },
329
+ "nextAction": {
330
+ "name": "step_8",
331
+ "skip": false,
332
+ "type": "PIECE",
333
+ "valid": true,
334
+ "settings": {
335
+ "input": {
336
+ "url": {
337
+ "url": "https://api.pipefy.com/graphql"
338
+ },
339
+ "auth": "{{connections['exampleConnectionId3']}}",
340
+ "body": {
341
+ "data": {
342
+ "query": "mutation {\n updateCardField(\n input: {card_id: \"{{step_13['output']['cardId']}}\", field_id:\"telefone_de_contato\",new_value:\"{{step_6['output']['telefoneContatoFormatado']}}\"}\n ) {\n clientMutationId\n }\n}\n",
343
+ "variables": null
344
+ }
345
+ },
346
+ "method": "POST",
347
+ "headers": {},
348
+ "failsafe": false,
349
+ "body_type": "json",
350
+ "queryParams": {},
351
+ "followRedirects": false,
352
+ "response_is_binary": false
353
+ },
354
+ "pieceName": "@activepieces/piece-pipefy",
355
+ "actionName": "custom_api_call",
356
+ "sampleData": {},
357
+ "pieceVersion": "0.1.7",
358
+ "propertySettings": {
359
+ "url": {
360
+ "type": "MANUAL",
361
+ "schema": {
362
+ "url": {
363
+ "type": "SHORT_TEXT",
364
+ "required": true,
365
+ "description": "You can either use the full URL or the relative path to the base URL\ni.e https://api.pipefy.com/graphql/resource or /resource",
366
+ "displayName": "URL",
367
+ "defaultValue": "https://api.pipefy.com/graphql"
368
+ }
369
+ }
370
+ },
371
+ "body": {
372
+ "type": "MANUAL",
373
+ "schema": {
374
+ "data": {
375
+ "type": "JSON",
376
+ "required": true,
377
+ "displayName": "JSON Body"
378
+ }
379
+ }
380
+ },
381
+ "method": {
382
+ "type": "MANUAL"
383
+ },
384
+ "headers": {
385
+ "type": "MANUAL"
386
+ },
387
+ "timeout": {
388
+ "type": "MANUAL"
389
+ },
390
+ "failsafe": {
391
+ "type": "MANUAL"
392
+ },
393
+ "body_type": {
394
+ "type": "MANUAL"
395
+ },
396
+ "queryParams": {
397
+ "type": "MANUAL"
398
+ },
399
+ "followRedirects": {
400
+ "type": "MANUAL"
401
+ },
402
+ "response_is_binary": {
403
+ "type": "MANUAL"
404
+ }
405
+ },
406
+ "errorHandlingOptions": {
407
+ "retryOnFailure": {
408
+ "value": false
409
+ },
410
+ "continueOnFailure": {
411
+ "value": false
412
+ }
413
+ }
414
+ },
415
+ "nextAction": {
416
+ "name": "step_10",
417
+ "skip": false,
418
+ "type": "PIECE",
419
+ "valid": true,
420
+ "settings": {
421
+ "input": {
422
+ "mode": "simple",
423
+ "response": {
424
+ "response": {}
425
+ }
426
+ },
427
+ "pieceName": "@activepieces/piece-subflows",
428
+ "actionName": "returnResponse",
429
+ "sampleData": {},
430
+ "pieceVersion": "0.4.12",
431
+ "propertySettings": {
432
+ "mode": {
433
+ "type": "MANUAL"
434
+ },
435
+ "response": {
436
+ "type": "MANUAL",
437
+ "schema": {
438
+ "response": {
439
+ "type": "OBJECT",
440
+ "required": true,
441
+ "displayName": "Response"
442
+ }
443
+ }
444
+ }
445
+ },
446
+ "errorHandlingOptions": {
447
+ "retryOnFailure": {
448
+ "value": false
449
+ },
450
+ "continueOnFailure": {
451
+ "value": false
452
+ }
453
+ }
454
+ },
455
+ "displayName": "Retornar",
456
+ "lastUpdatedDate": "2026-08-11T14:44:55.374Z"
457
+ },
458
+ "displayName": "atualização Telefone {\"query\":\"mutation {\\n updateCardField(\\n input: {card_id: \\\"0\\\", field_id:\\\"telefone_de_contato\\\",new_value:\\\"+55 (11) 2222-3333\\\"}\\n ) {\\n clientMutationId\\n }\\n}\\n\",\"variables\":null}",
459
+ "lastUpdatedDate": "2026-08-11T14:44:55.373Z"
460
+ },
461
+ "displayName": "Atualização de campos",
462
+ "lastUpdatedDate": "2026-08-11T14:44:55.373Z"
463
+ },
464
+ "displayName": "Normalização v.1",
465
+ "lastUpdatedDate": "2026-08-11T14:44:55.373Z"
466
+ },
467
+ "displayName": "Normalização",
468
+ "lastUpdatedDate": "2026-08-11T14:44:55.372Z"
469
+ },
470
+ null
471
+ ],
472
+ "settings": {
473
+ "branches": [
474
+ {
475
+ "branchName": "Existe",
476
+ "branchType": "CONDITION",
477
+ "conditions": [
478
+ [
479
+ {
480
+ "operator": "BOOLEAN_IS_TRUE",
481
+ "firstValue": "{{step_13['output']['encontrado']}}"
482
+ }
483
+ ]
484
+ ]
485
+ },
486
+ {
487
+ "branchName": "Otherwise",
488
+ "branchType": "FALLBACK"
489
+ }
490
+ ],
491
+ "sampleData": {},
492
+ "executionType": "EXECUTE_FIRST_MATCH"
493
+ },
494
+ "displayName": "Lista Sacado",
495
+ "lastUpdatedDate": "2026-08-11T14:44:55.372Z"
496
+ },
497
+ "displayName": "Conferência id e codigoEmpresa",
498
+ "lastUpdatedDate": "2026-08-11T14:44:55.372Z"
499
+ },
500
+ "displayName": "Buscar Sacado",
501
+ "lastUpdatedDate": "2026-08-11T14:44:55.372Z"
502
+ },
503
+ "lastUpdatedDate": "2026-08-11T14:44:55.372Z",
504
+ "type": "PIECE_TRIGGER",
505
+ "settings": {
506
+ "sampleData": {},
507
+ "propertySettings": {
508
+ "mode": {
509
+ "type": "MANUAL"
510
+ },
511
+ "exampleData": {
512
+ "type": "MANUAL",
513
+ "schema": {
514
+ "sampleData": {
515
+ "type": "example",
516
+ "required": false,
517
+ "displayName": "example"
518
+ }
519
+ }
520
+ }
521
+ },
522
+ "pieceName": "@activepieces/piece-subflows",
523
+ "pieceVersion": "0.4.12",
524
+ "triggerName": "callableFlow",
525
+ "input": {
526
+ "mode": "advanced",
527
+ "exampleData": {
528
+ "sampleData": {
529
+ "cedente": {
530
+ "cep": "example",
531
+ "nome": "example",
532
+ "email": "example",
533
+ "cidade": "example",
534
+ "estado": "example",
535
+ "endereco": "example",
536
+ "cnpjOuCpf": "example",
537
+ "idCedente": 0,
538
+ "dataCadastro": "example",
539
+ "codigoEmpresa": 0,
540
+ "telefoneContato": "example",
541
+ "idGrupoPrincipal": 0,
542
+ "analistaResponsavel": "example",
543
+ "vinculoGrupoEconomico": false
544
+ },
545
+ "empresaCodigo": 0
546
+ }
547
+ }
548
+ }
549
+ }
550
+ },
551
+ "valid": true,
552
+ "schemaVersion": "22",
553
+ "notes": []
554
+ }
555
+ ],
556
+ "status": "PUBLISHED"
557
+ }