@treasuredata/tdx 2026.3.36 → 2026.3.37

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 (219) hide show
  1. package/dist/bin.js +1 -1
  2. package/dist/build-info.json +3 -3
  3. package/dist/cli-categories.js +1 -1
  4. package/dist/cli.js +1 -1
  5. package/dist/commands/activations.js +1 -1
  6. package/dist/commands/agent-command.js +1 -1
  7. package/dist/commands/agent-test-command.js +1 -1
  8. package/dist/commands/api-command.js +1 -1
  9. package/dist/commands/auth-command.js +1 -1
  10. package/dist/commands/auth-login-command.js +1 -1
  11. package/dist/commands/cas-command.js +1 -1
  12. package/dist/commands/cas-segment-command.js +1 -1
  13. package/dist/commands/chat-command.js +1 -1
  14. package/dist/commands/claude-command.js +1 -1
  15. package/dist/commands/claude-statusline-command.js +1 -1
  16. package/dist/commands/claude-usage-command.js +1 -1
  17. package/dist/commands/command.js +1 -1
  18. package/dist/commands/connection-command.js +1 -1
  19. package/dist/commands/databases.js +1 -1
  20. package/dist/commands/delivery-command.js +1 -1
  21. package/dist/commands/describe.js +1 -1
  22. package/dist/commands/engage-campaign-pull-command.js +1 -1
  23. package/dist/commands/engage-campaign-push-command.js +1 -1
  24. package/dist/commands/engage-campaign-validate-command.js +1 -1
  25. package/dist/commands/engage-command.js +1 -1
  26. package/dist/commands/engage-template-pull-command.js +1 -1
  27. package/dist/commands/engage-template-push-command.js +1 -1
  28. package/dist/commands/engage-template-validate-command.js +1 -1
  29. package/dist/commands/job-command.js +1 -1
  30. package/dist/commands/journey-command.js +1 -1
  31. package/dist/commands/journey-validate-command.js +1 -1
  32. package/dist/commands/llm-command.js +1 -1
  33. package/dist/commands/mcp-command.js +1 -1
  34. package/dist/commands/parent-segment-command.js +1 -1
  35. package/dist/commands/policy-command.js +1 -1
  36. package/dist/commands/profile-command.js +1 -1
  37. package/dist/commands/profiles-command.js +1 -1
  38. package/dist/commands/query-command.js +1 -1
  39. package/dist/commands/schedule-command.js +1 -1
  40. package/dist/commands/segment-command.js +1 -1
  41. package/dist/commands/segment-create-command.js +1 -1
  42. package/dist/commands/segment-fields-command.js +1 -1
  43. package/dist/commands/segment-pull-command.js +1 -1
  44. package/dist/commands/segment-push-command.js +1 -1
  45. package/dist/commands/segment-update-command.js +1 -1
  46. package/dist/commands/segment-use-command.js +1 -1
  47. package/dist/commands/segment-validate-command.js +1 -1
  48. package/dist/commands/segments.js +1 -1
  49. package/dist/commands/show.js +1 -1
  50. package/dist/commands/status-command.js +1 -1
  51. package/dist/commands/tables.js +1 -1
  52. package/dist/commands/unset-command.js +1 -1
  53. package/dist/commands/upgrade-command.js +1 -1
  54. package/dist/commands/use-command.js +1 -1
  55. package/dist/commands/user-command.js +1 -1
  56. package/dist/commands/work-command.js +1 -1
  57. package/dist/commands/workflow-command.js +1 -1
  58. package/dist/core/auth.js +1 -1
  59. package/dist/core/command-output.js +1 -1
  60. package/dist/core/config.js +1 -1
  61. package/dist/core/connection-cache.js +1 -1
  62. package/dist/core/constants.js +1 -1
  63. package/dist/core/credential-cache.js +1 -1
  64. package/dist/core/global-context.js +1 -1
  65. package/dist/core/keychain.js +1 -1
  66. package/dist/core/oauth-keychain.js +1 -1
  67. package/dist/core/oauth.js +1 -1
  68. package/dist/core/profile.js +1 -1
  69. package/dist/core/project-config.js +1 -1
  70. package/dist/core/session.js +1 -1
  71. package/dist/core/user-cache.js +1 -1
  72. package/dist/core/version.js +1 -1
  73. package/dist/index.js +1 -1
  74. package/dist/mcp/server.js +1 -1
  75. package/dist/mcp/tools/index.js +1 -1
  76. package/dist/mcp/tools/tdx-run.js +1 -1
  77. package/dist/mcp/tools/tdx-search.js +1 -1
  78. package/dist/mcp/utils.js +1 -1
  79. package/dist/proxy/claude-usage-tracker.js +1 -1
  80. package/dist/proxy/passthrough-server.js +1 -1
  81. package/dist/proxy/sse-usage-parser.js +1 -1
  82. package/dist/sdk/agent/agent-config.js +1 -1
  83. package/dist/sdk/agent/agent-ref-parser.js +1 -1
  84. package/dist/sdk/agent/agent-yaml.js +1 -1
  85. package/dist/sdk/agent/test/evaluator.js +1 -1
  86. package/dist/sdk/agent/test/executor.js +1 -1
  87. package/dist/sdk/agent/test/index.js +1 -1
  88. package/dist/sdk/agent/test/output.js +1 -1
  89. package/dist/sdk/agent/test/parser.js +1 -1
  90. package/dist/sdk/agent/tool-target-registry.js +1 -1
  91. package/dist/sdk/api.js +1 -1
  92. package/dist/sdk/cas/cas-api-client.js +1 -1
  93. package/dist/sdk/cas/cas-audience-yaml.js +1 -1
  94. package/dist/sdk/cas/cas-segment-yaml.js +1 -1
  95. package/dist/sdk/cas/index.js +1 -1
  96. package/dist/sdk/cas/pull-workflow.js +1 -1
  97. package/dist/sdk/cas/push-workflow.js +1 -1
  98. package/dist/sdk/client/cdp-api-client.js +1 -1
  99. package/dist/sdk/client/delivery-api-client.js +1 -1
  100. package/dist/sdk/client/endpoints.js +1 -1
  101. package/dist/sdk/client/engage-api-client.js +1 -1
  102. package/dist/sdk/client/http-client.js +1 -1
  103. package/dist/sdk/client/llm-api-client.js +1 -1
  104. package/dist/sdk/client/oauth-refresh.js +1 -1
  105. package/dist/sdk/client/rate-limiter.js +1 -1
  106. package/dist/sdk/client/td-api-client.js +1 -1
  107. package/dist/sdk/client/trino-api-client.js +1 -1
  108. package/dist/sdk/client/workflow-client.js +1 -1
  109. package/dist/sdk/connection-validator.js +1 -1
  110. package/dist/sdk/connection.js +1 -1
  111. package/dist/sdk/delivery.js +1 -1
  112. package/dist/sdk/engage/campaign-pull.js +1 -1
  113. package/dist/sdk/engage/campaign-push.js +1 -1
  114. package/dist/sdk/engage/campaign-validator.js +1 -1
  115. package/dist/sdk/engage/campaign-yaml.js +1 -1
  116. package/dist/sdk/engage/template-pull.js +1 -1
  117. package/dist/sdk/engage/template-push.js +1 -1
  118. package/dist/sdk/engage/template-validator.js +1 -1
  119. package/dist/sdk/engage/template-yaml.js +1 -1
  120. package/dist/sdk/engage/types/campaign-def.js +1 -1
  121. package/dist/sdk/engage/types/campaign-schema.js +1 -1
  122. package/dist/sdk/engage/types/template-schema.js +1 -1
  123. package/dist/sdk/engage.js +1 -1
  124. package/dist/sdk/errors.js +1 -1
  125. package/dist/sdk/index.js +1 -1
  126. package/dist/sdk/io/index.js +1 -1
  127. package/dist/sdk/io/node-filesystem.js +1 -1
  128. package/dist/sdk/job.js +1 -1
  129. package/dist/sdk/journey.js +1 -1
  130. package/dist/sdk/llm/chat-cache.js +1 -1
  131. package/dist/sdk/llm/index.js +1 -1
  132. package/dist/sdk/llm/llm-backup-utils.js +1 -1
  133. package/dist/sdk/llm/model-factors.js +1 -1
  134. package/dist/sdk/personalization.js +1 -1
  135. package/dist/sdk/policy.js +1 -1
  136. package/dist/sdk/query/index.js +1 -1
  137. package/dist/sdk/query/sql-parser.js +1 -1
  138. package/dist/sdk/realtime.js +1 -1
  139. package/dist/sdk/schedule.js +1 -1
  140. package/dist/sdk/segment/child-segment-yaml.js +1 -1
  141. package/dist/sdk/segment/fields-display.js +1 -1
  142. package/dist/sdk/segment/file-discovery.js +1 -1
  143. package/dist/sdk/segment/journey-utils.js +1 -1
  144. package/dist/sdk/segment/journey-validator.js +1 -1
  145. package/dist/sdk/segment/journey-yaml.js +1 -1
  146. package/dist/sdk/segment/parent-segment-preview.js +1 -1
  147. package/dist/sdk/segment/parent-segment-yaml.js +1 -1
  148. package/dist/sdk/segment/pull-workflow.js +1 -1
  149. package/dist/sdk/segment/push-recovery.js +1 -1
  150. package/dist/sdk/segment/push-workflow.js +1 -1
  151. package/dist/sdk/segment/resolution-context.js +1 -1
  152. package/dist/sdk/segment/segment-path-parser.js +1 -1
  153. package/dist/sdk/segment/segment-ref-parser.js +1 -1
  154. package/dist/sdk/segment/segment-validator.js +1 -1
  155. package/dist/sdk/segment/target-resolution.js +1 -1
  156. package/dist/sdk/segment/tdx-config.js +1 -1
  157. package/dist/sdk/segment/types/activation-schema.js +1 -1
  158. package/dist/sdk/segment/types/journey-def.js +1 -1
  159. package/dist/sdk/segment/types/journey-schema.js +1 -1
  160. package/dist/sdk/segment/types/segment-def.js +1 -1
  161. package/dist/sdk/segment/types/segment-schema.js +1 -1
  162. package/dist/sdk/segment/validate-files.js +1 -1
  163. package/dist/sdk/segment/yaml-validator.js +1 -1
  164. package/dist/sdk/segment.js +1 -1
  165. package/dist/sdk/types/index.js +1 -1
  166. package/dist/sdk/types/progress.js +1 -1
  167. package/dist/sdk/types/workspace.js +1 -1
  168. package/dist/sdk/user.js +1 -1
  169. package/dist/sdk/util/format-detector.js +1 -1
  170. package/dist/sdk/util/formatters.js +1 -1
  171. package/dist/sdk/util/index.js +1 -1
  172. package/dist/sdk/util/paginate.js +1 -1
  173. package/dist/sdk/util/tree-formatter.js +1 -1
  174. package/dist/sdk/workflow/archive-validation.js +1 -1
  175. package/dist/sdk/workflow/clone-workflow.js +1 -1
  176. package/dist/sdk/workflow/index.js +1 -1
  177. package/dist/sdk/workflow/pull-workflow.js +1 -1
  178. package/dist/sdk/workflow/push-workflow.js +1 -1
  179. package/dist/sdk/workflow/tdx-config.js +1 -1
  180. package/dist/sdk/workflow/workflow-utils.js +1 -1
  181. package/dist/sdk/workspace/frontmatter.js +1 -1
  182. package/dist/sdk/workspace/git.js +1 -1
  183. package/dist/sdk/workspace/index.js +1 -1
  184. package/dist/sdk/workspace/templates.js +1 -1
  185. package/dist/sdk/workspace/weekly.js +1 -1
  186. package/dist/sdk/workspace/wikilinks.js +1 -1
  187. package/dist/test-utils/command-runner.js +1 -1
  188. package/dist/test-utils/factories.js +1 -1
  189. package/dist/test-utils/fixtures.js +1 -1
  190. package/dist/test-utils/http-mock.js +1 -1
  191. package/dist/test-utils/index.js +1 -1
  192. package/dist/utils/async.js +1 -1
  193. package/dist/utils/colors.js +1 -1
  194. package/dist/utils/diff.js +1 -1
  195. package/dist/utils/file-permissions.js +1 -1
  196. package/dist/utils/file-reader.js +1 -1
  197. package/dist/utils/github-releases.js +1 -1
  198. package/dist/utils/global-cache.js +1 -1
  199. package/dist/utils/json-loader.js +1 -1
  200. package/dist/utils/local-cache.js +1 -1
  201. package/dist/utils/logger/formatters/default-formatter.js +1 -1
  202. package/dist/utils/logger/formatters/index.js +1 -1
  203. package/dist/utils/logger/handlers/console-handler.js +1 -1
  204. package/dist/utils/logger/handlers/file-handler.js +1 -1
  205. package/dist/utils/logger/handlers/index.js +1 -1
  206. package/dist/utils/logger/handlers/null-handler.js +1 -1
  207. package/dist/utils/logger/index.js +1 -1
  208. package/dist/utils/logger/logger.js +1 -1
  209. package/dist/utils/logger/types.js +1 -1
  210. package/dist/utils/option-validation.js +1 -1
  211. package/dist/utils/process.js +1 -1
  212. package/dist/utils/prompt.js +1 -1
  213. package/dist/utils/spinner.js +1 -1
  214. package/dist/utils/sse-parser.js +1 -1
  215. package/dist/utils/string-utils.js +1 -1
  216. package/dist/utils/table-ref-parser.js +1 -1
  217. package/dist/utils/tdx-logger.js +1 -1
  218. package/dist/utils/version-check.js +1 -1
  219. package/package.json +1 -1
@@ -1 +1 @@
1
- (function(_0x6f979c,_0x3a83af){const _0x101e72=a156_0x42ad,_0x2a1f0f=_0x6f979c();while(!![]){try{const _0x346708=-parseInt(_0x101e72(0x10d))/0x1*(parseInt(_0x101e72(0x10b))/0x2)+parseInt(_0x101e72(0xdf))/0x3*(-parseInt(_0x101e72(0xf0))/0x4)+-parseInt(_0x101e72(0xec))/0x5+parseInt(_0x101e72(0xdc))/0x6+-parseInt(_0x101e72(0xff))/0x7+parseInt(_0x101e72(0xe9))/0x8+parseInt(_0x101e72(0x122))/0x9*(parseInt(_0x101e72(0x121))/0xa);if(_0x346708===_0x3a83af)break;else _0x2a1f0f['push'](_0x2a1f0f['shift']());}catch(_0x425aae){_0x2a1f0f['push'](_0x2a1f0f['shift']());}}}(a156_0x3e57,0x5e135));import{SegmentDefSchema,RuleDefSchema}from'./types/segment-schema.js';function a156_0x3e57(){const _0x105550=['4040841thiDAX','EMPTY_ATTRIBUTE','issues','Attribute\x20\x27','the\x20condition\x20queries\x20the\x20master\x20table\x20instead.\x20','error','Behavior\x20source\x20\x27','Attribute\x20name\x20cannot\x20be\x20empty','success','rule','validationCode','SEGMENT_SCHEMA_ERROR','10DWLTHh','conditions','83343USNWvD','symbol','.operator.type','MISSING_TIME_UNIT','.source','MISSING_OPERATOR_VALUE','match','\x20condition\x20group:\x20Console\x20UI\x20SQL\x20preview\x20does\x20not\x20display\x20nested\x20','\x20condition\x20cannot\x20have\x20an\x20empty\x20conditions\x20array','.conditions','path','push','\x27\x20with\x20behavior\x20source\x20may\x20cause\x20unexpected\x20behavior.\x20','Value','arrayMatching','MISSING_SEGMENT_REFERENCE','EMPTY_CONDITIONS','Rule\x20conditions\x20array\x20cannot\x20be\x20empty.\x20Add\x20at\x20least\x20one\x20condition.','custom','level','70mnYQvd','1226007dlNyxq','BEHAVIOR_SOURCE_MISSING_FILTER','4165818aiWdOF','safeParse','endsWith','24mRQCXD','conditions,\x20consider\x20using\x20\x27In\x27\x20operator:\x20operator:\x20{\x20type:\x20In,\x20value:\x20[\x22val1\x22,\x20\x22val2\x22]\x20}','name','type','Use\x20\x27attribute:\x20\x22\x22\x27\x20with\x20\x27filter.type:\x20And\x27\x20containing\x20\x27type:\x20Column\x27\x20conditions.','.segment','length','INVALID_RULE_TYPE','condition\x20groups\x20correctly.\x20Segment\x20execution\x20is\x20unaffected.\x20For\x20same-attribute\x20Or\x20','invalid_value','3811280ieOgCf','.conditions[','data','2702455mwZhrA','source','.filter','skipSchema','102236kKfgfO','Behavior','\x27\x20with\x20attribute\x20\x27','aggregation','MISSING_BETWEEN_BOUNDS','map','document','rule.type','.attribute','message','attribute','code','NESTED_CONDITION_GROUP','warning','filter'];a156_0x3e57=function(){return _0x105550;};return a156_0x3e57();}import{formatZodPath,flattenZodIssues,getLocationFromPath,pathToArray}from'./yaml-validator.js';export function validateSegmentDef(_0x3f75e9,_0x463662={},_0x26e5d3={}){const _0x3f4c27=a156_0x42ad;if(_0x26e5d3[_0x3f4c27(0xef)])return runSemanticChecks(_0x3f75e9,_0x463662);const _0x1687fe=SegmentDefSchema[_0x3f4c27(0xdd)](_0x3f75e9);if(_0x1687fe[_0x3f4c27(0x107)])return runSemanticChecks(_0x1687fe[_0x3f4c27(0xeb)],_0x463662);return zodErrorsToValidationResult(_0x1687fe['error'],_0x463662);}export function validateRuleDef(_0x5e708a,_0x4faf2f,_0x732f99){const _0x560c62=a156_0x42ad;if(!_0x5e708a)return[];const _0x555399=RuleDefSchema[_0x560c62(0xdd)](_0x5e708a);if(_0x555399[_0x560c62(0x107)])return checkRule(_0x555399['data'],_0x4faf2f,_0x732f99);const _0x4980b4=flattenZodIssues(_0x555399[_0x560c62(0x104)][_0x560c62(0x101)]);return _0x4980b4[_0x560c62(0xf5)](_0x24d7cb=>{const _0x163b52=_0x560c62,_0x5526f3=formatZodPath(_0x24d7cb[_0x163b52(0x117)]),_0x4cfcf9=_0x5526f3?_0x4faf2f+'.'+_0x5526f3:_0x4faf2f,_0x9439a0=mapZodIssueToCode(_0x24d7cb,_0x5526f3),_0x13bc78=getLocationFromPath(_0x732f99[_0x163b52(0xf6)],_0x732f99[_0x163b52(0xed)],pathToArray(_0x4cfcf9));return{'level':_0x163b52(0x104),'path':_0x4cfcf9,'code':_0x9439a0,'message':_0x24d7cb[_0x163b52(0xf9)],..._0x13bc78&&{'location':_0x13bc78}};});}function zodErrorsToValidationResult(_0x1c5573,_0x50e6d5){const _0x1d8cc0=a156_0x42ad,_0x5ecc30=flattenZodIssues(_0x1c5573['issues']),_0x24b756=_0x5ecc30[_0x1d8cc0(0xf5)](_0x63cf08=>{const _0xe73581=_0x1d8cc0,_0x2fc46d=formatZodPath(_0x63cf08[_0xe73581(0x117)]),_0x3ff398=mapZodIssueToCode(_0x63cf08,_0x2fc46d),_0x3062cf=getLocationFromPath(_0x50e6d5[_0xe73581(0xf6)],_0x50e6d5[_0xe73581(0xed)],_0x63cf08[_0xe73581(0x117)][_0xe73581(0xf5)](_0x1b812c=>typeof _0x1b812c===_0xe73581(0x10e)?String(_0x1b812c):_0x1b812c));return{'level':_0xe73581(0x104),'path':_0x2fc46d,'code':_0x3ff398,'message':_0x63cf08[_0xe73581(0xf9)],..._0x3062cf&&{'location':_0x3062cf}};});return{'valid':![],'errors':_0x24b756,'warnings':[]};}function mapZodIssueToCode(_0xf25ff8,_0x4f9048){const _0x2275a7=a156_0x42ad,_0x43aaac=_0xf25ff8[_0x2275a7(0xfb)]===_0x2275a7(0x11f)?_0xf25ff8['params']:undefined;if(_0x4f9048===_0x2275a7(0xe1))return'MISSING_NAME';if(_0x4f9048===_0x2275a7(0xf7)||_0x4f9048['endsWith']('.type')){if(_0xf25ff8['code']===_0x2275a7(0xe8)){if(_0x4f9048==='rule.type'||_0x4f9048[_0x2275a7(0x113)](/\.conditions\[\d+\]\.type$/))return _0x2275a7(0xe6);}}if(_0x4f9048['endsWith'](_0x2275a7(0x10f)))return'INVALID_OPERATOR_TYPE';if(_0x4f9048[_0x2275a7(0xde)]('.operator.value'))return _0x2275a7(0x112);if(_0x43aaac?.[_0x2275a7(0x109)]==='MISSING_BETWEEN_BOUNDS')return _0x2275a7(0xf4);if(_0x43aaac?.['validationCode']===_0x2275a7(0x110))return'MISSING_TIME_UNIT';if(_0x4f9048[_0x2275a7(0xde)](_0x2275a7(0x116))||_0x4f9048===_0x2275a7(0x10c))return'MISSING_CONDITIONS';if(_0x4f9048['includes'](_0x2275a7(0x11b)))return'INVALID_ARRAY_MATCHING';if(_0x4f9048[_0x2275a7(0xde)](_0x2275a7(0xe4)))return _0x2275a7(0x11c);return _0x2275a7(0x10a);}function runSemanticChecks(_0x18b9cd,_0x2b439c){const _0xe897f6=a156_0x42ad,_0x195f12=[];_0x18b9cd[_0xe897f6(0x108)]&&_0x195f12[_0xe897f6(0x118)](...checkRule(_0x18b9cd[_0xe897f6(0x108)],_0xe897f6(0x108),_0x2b439c));const _0x1cda8b=_0x195f12[_0xe897f6(0xfe)](_0x6073fa=>_0x6073fa['level']===_0xe897f6(0x104)),_0x4b077d=_0x195f12[_0xe897f6(0xfe)](_0x1a70a9=>_0x1a70a9[_0xe897f6(0x120)]===_0xe897f6(0xfd));return{'valid':_0x1cda8b['length']===0x0,'errors':_0x1cda8b,'warnings':_0x4b077d};}function checkRule(_0x342ef5,_0x5140ca,_0x5c70f9){const _0x15b55a=a156_0x42ad,_0x357e60=[];if(_0x342ef5[_0x15b55a(0x10c)][_0x15b55a(0xe5)]===0x0)return _0x357e60[_0x15b55a(0x118)]({'level':_0x15b55a(0x104),'path':_0x5140ca+_0x15b55a(0x116),'code':_0x15b55a(0x11d),'message':_0x15b55a(0x11e),'location':getLocationFromPath(_0x5c70f9[_0x15b55a(0xf6)],_0x5c70f9[_0x15b55a(0xed)],pathToArray(_0x5140ca+'.conditions'))}),_0x357e60;return _0x357e60[_0x15b55a(0x118)](...checkConditions(_0x342ef5['conditions'],_0x5140ca,_0x5c70f9)),_0x357e60;}function checkConditions(_0x19bdd7,_0x29196f,_0x36a8e0){const _0x173e94=a156_0x42ad,_0x31c009=[];for(let _0x300aef=0x0;_0x300aef<_0x19bdd7['length'];_0x300aef++){const _0x5b0ca3=_0x19bdd7[_0x300aef],_0x4dd22c=_0x29196f+_0x173e94(0xea)+_0x300aef+']';_0x31c009['push'](...checkCondition(_0x5b0ca3,_0x4dd22c,_0x36a8e0));}return _0x31c009;}function a156_0x42ad(_0x57f1da,_0x4b446f){_0x57f1da=_0x57f1da-0xdc;const _0x3e57b2=a156_0x3e57();let _0x42ad61=_0x3e57b2[_0x57f1da];return _0x42ad61;}function checkCondition(_0x15d6b9,_0x14fa14,_0x241a70){const _0x3839a6=a156_0x42ad,_0x4ee718=[];if(_0x15d6b9['type']==='And'||_0x15d6b9[_0x3839a6(0xe2)]==='Or')return _0x15d6b9['conditions'][_0x3839a6(0xe5)]===0x0?_0x4ee718[_0x3839a6(0x118)]({'level':_0x3839a6(0x104),'path':_0x14fa14+_0x3839a6(0x116),'code':_0x3839a6(0x11d),'message':_0x15d6b9[_0x3839a6(0xe2)]+_0x3839a6(0x115),'location':getLocationFromPath(_0x241a70[_0x3839a6(0xf6)],_0x241a70['source'],pathToArray(_0x14fa14+_0x3839a6(0x116)))}):(_0x4ee718[_0x3839a6(0x118)]({'level':_0x3839a6(0xfd),'path':_0x14fa14,'code':_0x3839a6(0xfc),'message':_0x15d6b9[_0x3839a6(0xe2)]+_0x3839a6(0x114)+_0x3839a6(0xe7)+_0x3839a6(0xe0),'location':getLocationFromPath(_0x241a70[_0x3839a6(0xf6)],_0x241a70['source'],pathToArray(_0x14fa14))}),_0x4ee718[_0x3839a6(0x118)](...checkConditions(_0x15d6b9[_0x3839a6(0x10c)],_0x14fa14,_0x241a70))),_0x4ee718;if(_0x15d6b9[_0x3839a6(0xe2)]===_0x3839a6(0x11a)||_0x15d6b9['type']===_0x3839a6(0xf1)){const _0x4931c9=_0x15d6b9,_0x12e163=_0x4931c9['source'],_0xef97a9=_0x4931c9[_0x3839a6(0xf3)],_0x127ba2=_0x12e163||_0xef97a9;(!_0x4931c9[_0x3839a6(0xfa)]||_0x4931c9[_0x3839a6(0xfa)]==='')&&(!_0x127ba2&&_0x4ee718[_0x3839a6(0x118)]({'level':_0x3839a6(0x104),'path':_0x14fa14+_0x3839a6(0xf8),'code':_0x3839a6(0x100),'message':_0x3839a6(0x106),'location':getLocationFromPath(_0x241a70[_0x3839a6(0xf6)],_0x241a70[_0x3839a6(0xed)],pathToArray(_0x14fa14+_0x3839a6(0xf8)))}));_0x4931c9[_0x3839a6(0xfe)]&&_0x4ee718[_0x3839a6(0x118)](...checkRule(_0x4931c9[_0x3839a6(0xfe)],_0x14fa14+_0x3839a6(0xee),_0x241a70));if(_0x4931c9['source']){const _0x22d302=_0x4931c9[_0x3839a6(0xfa)]&&_0x4931c9[_0x3839a6(0xfa)]!=='';_0x22d302&&!_0x4931c9[_0x3839a6(0xfe)]&&_0x4ee718[_0x3839a6(0x118)]({'level':_0x3839a6(0x104),'path':_0x14fa14+'.source','code':_0x3839a6(0x123),'message':_0x3839a6(0x105)+_0x4931c9['source']+_0x3839a6(0xf2)+_0x4931c9['attribute']+'\x27\x20'+'requires\x20a\x20nested\x20\x27filter\x27.\x20Without\x20filter,\x20the\x20source\x20is\x20silently\x20ignored\x20and\x20'+_0x3839a6(0x103)+_0x3839a6(0xe3),'location':getLocationFromPath(_0x241a70[_0x3839a6(0xf6)],_0x241a70[_0x3839a6(0xed)],pathToArray(_0x14fa14+_0x3839a6(0x111)))}),_0x22d302&&_0x4931c9[_0x3839a6(0xfe)]&&_0x4ee718[_0x3839a6(0x118)]({'level':_0x3839a6(0xfd),'path':_0x14fa14+_0x3839a6(0xf8),'code':'BEHAVIOR_SOURCE_WITH_ATTRIBUTE','message':_0x3839a6(0x102)+_0x4931c9[_0x3839a6(0xfa)]+_0x3839a6(0x119)+'For\x20behavior\x20aggregations,\x20use\x20\x27attribute:\x20\x22\x22\x27\x20with\x20Column\x20conditions\x20in\x20filter.','location':getLocationFromPath(_0x241a70[_0x3839a6(0xf6)],_0x241a70[_0x3839a6(0xed)],pathToArray(_0x14fa14+'.attribute'))});}}return _0x4ee718;}
1
+ function a156_0x19e9(_0x2d2632,_0x24013b){_0x2d2632=_0x2d2632-0x169;const _0x2e3403=a156_0x2e34();let _0x19e9c3=_0x2e3403[_0x2d2632];return _0x19e9c3;}(function(_0x5db9e7,_0x595421){const _0xf68b7a=a156_0x19e9,_0x555eb7=_0x5db9e7();while(!![]){try{const _0x59d1bf=-parseInt(_0xf68b7a(0x1a9))/0x1*(-parseInt(_0xf68b7a(0x16f))/0x2)+-parseInt(_0xf68b7a(0x18a))/0x3+parseInt(_0xf68b7a(0x17e))/0x4*(parseInt(_0xf68b7a(0x179))/0x5)+-parseInt(_0xf68b7a(0x170))/0x6+parseInt(_0xf68b7a(0x178))/0x7+-parseInt(_0xf68b7a(0x1b1))/0x8+-parseInt(_0xf68b7a(0x187))/0x9*(-parseInt(_0xf68b7a(0x181))/0xa);if(_0x59d1bf===_0x595421)break;else _0x555eb7['push'](_0x555eb7['shift']());}catch(_0x36b589){_0x555eb7['push'](_0x555eb7['shift']());}}}(a156_0x2e34,0x56953));import{SegmentDefSchema,RuleDefSchema}from'./types/segment-schema.js';import{formatZodPath,flattenZodIssues,getLocationFromPath,pathToArray}from'./yaml-validator.js';export function validateSegmentDef(_0x20cb34,_0x3d6e53={},_0x3ee055={}){const _0x4ba90b=a156_0x19e9;if(_0x3ee055['skipSchema'])return runSemanticChecks(_0x20cb34,_0x3d6e53);const _0x1d4eb1=SegmentDefSchema[_0x4ba90b(0x16c)](_0x20cb34);if(_0x1d4eb1[_0x4ba90b(0x18e)])return runSemanticChecks(_0x1d4eb1[_0x4ba90b(0x1aa)],_0x3d6e53);return zodErrorsToValidationResult(_0x1d4eb1['error'],_0x3d6e53);}export function validateRuleDef(_0x406187,_0x41b317,_0x1dc8b1){const _0x10cba5=a156_0x19e9;if(!_0x406187)return[];const _0x2e8477=RuleDefSchema[_0x10cba5(0x16c)](_0x406187);if(_0x2e8477[_0x10cba5(0x18e)])return checkRule(_0x2e8477[_0x10cba5(0x1aa)],_0x41b317,_0x1dc8b1);const _0x2882c2=flattenZodIssues(_0x2e8477['error'][_0x10cba5(0x186)]);return _0x2882c2[_0x10cba5(0x1a8)](_0x4d7098=>{const _0x21cd62=_0x10cba5,_0x500014=formatZodPath(_0x4d7098[_0x21cd62(0x182)]),_0x21a18b=_0x500014?_0x41b317+'.'+_0x500014:_0x41b317,_0x436281=mapZodIssueToCode(_0x4d7098,_0x500014),_0xae3471=getLocationFromPath(_0x1dc8b1['document'],_0x1dc8b1[_0x21cd62(0x1a6)],pathToArray(_0x21a18b));return{'level':_0x21cd62(0x190),'path':_0x21a18b,'code':_0x436281,'message':_0x4d7098[_0x21cd62(0x19e)],..._0xae3471&&{'location':_0xae3471}};});}function zodErrorsToValidationResult(_0x32bbb9,_0x570b29){const _0x352db4=flattenZodIssues(_0x32bbb9['issues']),_0x43ad6e=_0x352db4['map'](_0x507c27=>{const _0x23fdf6=a156_0x19e9,_0x574cee=formatZodPath(_0x507c27[_0x23fdf6(0x182)]),_0x3153f2=mapZodIssueToCode(_0x507c27,_0x574cee),_0x43b2d9=getLocationFromPath(_0x570b29['document'],_0x570b29[_0x23fdf6(0x1a6)],_0x507c27[_0x23fdf6(0x182)][_0x23fdf6(0x1a8)](_0x48dd46=>typeof _0x48dd46==='symbol'?String(_0x48dd46):_0x48dd46));return{'level':_0x23fdf6(0x190),'path':_0x574cee,'code':_0x3153f2,'message':_0x507c27['message'],..._0x43b2d9&&{'location':_0x43b2d9}};});return{'valid':![],'errors':_0x43ad6e,'warnings':[]};}function a156_0x2e34(){const _0x43cefa=['map','6FVaeYl','data','Attribute\x20\x27','filter','MISSING_OPERATOR_VALUE','Behavior\x20source\x20\x27','.segment','INVALID_ARRAY_MATCHING','4403192dwZNMH','attribute','length','match','requires\x20a\x20nested\x20\x27filter\x27.\x20Without\x20filter,\x20the\x20source\x20is\x20silently\x20ignored\x20and\x20','INVALID_RULE_TYPE','safeParse','Rule\x20conditions\x20array\x20cannot\x20be\x20empty.\x20Add\x20at\x20least\x20one\x20condition.','BEHAVIOR_SOURCE_WITH_ATTRIBUTE','25782dmBQCE','1108974shrhfb','.conditions[','BEHAVIOR_SOURCE_MISSING_FILTER','.filter','custom','conditions,\x20consider\x20using\x20\x27In\x27\x20operator:\x20operator:\x20{\x20type:\x20In,\x20value:\x20[\x22val1\x22,\x20\x22val2\x22]\x20}','includes','document','977340AqAmcb','3085KebnPw','\x27\x20with\x20behavior\x20source\x20may\x20cause\x20unexpected\x20behavior.\x20','condition\x20groups\x20correctly.\x20Segment\x20execution\x20is\x20unaffected.\x20For\x20same-attribute\x20Or\x20','rule','\x20condition\x20group:\x20Console\x20UI\x20SQL\x20preview\x20does\x20not\x20display\x20nested\x20','3796BjHhWU','type','rule.type','1099350HqEDXD','path','Behavior','conditions','.attribute','issues','27milZNF','.operator.type','arrayMatching','127299hzthQc','name','endsWith','\x27\x20with\x20attribute\x20\x27','success','Value','error','SEGMENT_SCHEMA_ERROR','MISSING_BETWEEN_BOUNDS','For\x20behavior\x20aggregations,\x20use\x20\x27attribute:\x20\x22\x22\x27\x20with\x20Column\x20conditions\x20in\x20filter.','invalid_value','level','params','\x20condition\x20cannot\x20have\x20an\x20empty\x20conditions\x20array','code','Attribute\x20name\x20cannot\x20be\x20empty','.conditions','MISSING_NAME','.type','warning','message','aggregation','EMPTY_CONDITIONS','.source','NESTED_CONDITION_GROUP','And','push','Use\x20\x27attribute:\x20\x22\x22\x27\x20with\x20\x27filter.type:\x20And\x27\x20containing\x20\x27type:\x20Column\x27\x20conditions.','source','validationCode'];a156_0x2e34=function(){return _0x43cefa;};return a156_0x2e34();}function mapZodIssueToCode(_0x8a9ff5,_0x9dda93){const _0x13336d=a156_0x19e9,_0x1d395a=_0x8a9ff5[_0x13336d(0x198)]===_0x13336d(0x174)?_0x8a9ff5[_0x13336d(0x196)]:undefined;if(_0x9dda93===_0x13336d(0x18b))return _0x13336d(0x19b);if(_0x9dda93===_0x13336d(0x180)||_0x9dda93[_0x13336d(0x18c)](_0x13336d(0x19c))){if(_0x8a9ff5['code']===_0x13336d(0x194)){if(_0x9dda93===_0x13336d(0x180)||_0x9dda93[_0x13336d(0x169)](/\.conditions\[\d+\]\.type$/))return _0x13336d(0x16b);}}if(_0x9dda93[_0x13336d(0x18c)](_0x13336d(0x188)))return'INVALID_OPERATOR_TYPE';if(_0x9dda93[_0x13336d(0x18c)]('.operator.value'))return _0x13336d(0x1ad);if(_0x1d395a?.[_0x13336d(0x1a7)]===_0x13336d(0x192))return _0x13336d(0x192);if(_0x1d395a?.[_0x13336d(0x1a7)]==='MISSING_TIME_UNIT')return'MISSING_TIME_UNIT';if(_0x9dda93[_0x13336d(0x18c)](_0x13336d(0x19a))||_0x9dda93===_0x13336d(0x184))return'MISSING_CONDITIONS';if(_0x9dda93[_0x13336d(0x176)](_0x13336d(0x189)))return _0x13336d(0x1b0);if(_0x9dda93[_0x13336d(0x18c)](_0x13336d(0x1af)))return'MISSING_SEGMENT_REFERENCE';return _0x13336d(0x191);}function runSemanticChecks(_0x4f5dbb,_0x38fb42){const _0x320eab=a156_0x19e9,_0x1506fb=[];_0x4f5dbb['rule']&&_0x1506fb['push'](...checkRule(_0x4f5dbb[_0x320eab(0x17c)],_0x320eab(0x17c),_0x38fb42));const _0x16dbc3=_0x1506fb[_0x320eab(0x1ac)](_0x17e340=>_0x17e340[_0x320eab(0x195)]==='error'),_0x435fae=_0x1506fb['filter'](_0x4816e2=>_0x4816e2[_0x320eab(0x195)]==='warning');return{'valid':_0x16dbc3[_0x320eab(0x1b3)]===0x0,'errors':_0x16dbc3,'warnings':_0x435fae};}function checkRule(_0x16303b,_0x178b4d,_0x104a33){const _0x498895=a156_0x19e9,_0xb57f13=[];if(_0x16303b[_0x498895(0x184)]['length']===0x0)return _0xb57f13[_0x498895(0x1a4)]({'level':'error','path':_0x178b4d+_0x498895(0x19a),'code':'EMPTY_CONDITIONS','message':_0x498895(0x16d),'location':getLocationFromPath(_0x104a33['document'],_0x104a33[_0x498895(0x1a6)],pathToArray(_0x178b4d+_0x498895(0x19a)))}),_0xb57f13;return _0xb57f13[_0x498895(0x1a4)](...checkConditions(_0x16303b[_0x498895(0x184)],_0x178b4d,_0x104a33)),_0xb57f13;}function checkConditions(_0x276c7a,_0x1e0db8,_0x240ad2){const _0xf76581=a156_0x19e9,_0xbb375=[];for(let _0x538480=0x0;_0x538480<_0x276c7a[_0xf76581(0x1b3)];_0x538480++){const _0x2ed437=_0x276c7a[_0x538480],_0x59e8fa=_0x1e0db8+_0xf76581(0x171)+_0x538480+']';_0xbb375[_0xf76581(0x1a4)](...checkCondition(_0x2ed437,_0x59e8fa,_0x240ad2));}return _0xbb375;}function checkCondition(_0x241f51,_0x45b49c,_0x495311){const _0xdee9cc=a156_0x19e9,_0x112137=[];if(_0x241f51[_0xdee9cc(0x17f)]===_0xdee9cc(0x1a3)||_0x241f51[_0xdee9cc(0x17f)]==='Or')return _0x241f51[_0xdee9cc(0x184)][_0xdee9cc(0x1b3)]===0x0?_0x112137[_0xdee9cc(0x1a4)]({'level':'error','path':_0x45b49c+_0xdee9cc(0x19a),'code':_0xdee9cc(0x1a0),'message':_0x241f51['type']+_0xdee9cc(0x197),'location':getLocationFromPath(_0x495311['document'],_0x495311[_0xdee9cc(0x1a6)],pathToArray(_0x45b49c+_0xdee9cc(0x19a)))}):(_0x112137[_0xdee9cc(0x1a4)]({'level':_0xdee9cc(0x19d),'path':_0x45b49c,'code':_0xdee9cc(0x1a2),'message':_0x241f51[_0xdee9cc(0x17f)]+_0xdee9cc(0x17d)+_0xdee9cc(0x17b)+_0xdee9cc(0x175),'location':getLocationFromPath(_0x495311[_0xdee9cc(0x177)],_0x495311[_0xdee9cc(0x1a6)],pathToArray(_0x45b49c))}),_0x112137[_0xdee9cc(0x1a4)](...checkConditions(_0x241f51[_0xdee9cc(0x184)],_0x45b49c,_0x495311))),_0x112137;if(_0x241f51[_0xdee9cc(0x17f)]===_0xdee9cc(0x18f)||_0x241f51[_0xdee9cc(0x17f)]===_0xdee9cc(0x183)){const _0x3f3ab9=_0x241f51,_0x47bd52=_0x3f3ab9[_0xdee9cc(0x1a6)],_0x9c8501=_0x3f3ab9[_0xdee9cc(0x19f)],_0x32b343=_0x47bd52||_0x9c8501;(!_0x3f3ab9['attribute']||_0x3f3ab9[_0xdee9cc(0x1b2)]==='')&&(!_0x32b343&&_0x112137[_0xdee9cc(0x1a4)]({'level':_0xdee9cc(0x190),'path':_0x45b49c+_0xdee9cc(0x185),'code':'EMPTY_ATTRIBUTE','message':_0xdee9cc(0x199),'location':getLocationFromPath(_0x495311[_0xdee9cc(0x177)],_0x495311[_0xdee9cc(0x1a6)],pathToArray(_0x45b49c+_0xdee9cc(0x185)))}));_0x3f3ab9[_0xdee9cc(0x1ac)]&&_0x112137[_0xdee9cc(0x1a4)](...checkRule(_0x3f3ab9[_0xdee9cc(0x1ac)],_0x45b49c+_0xdee9cc(0x173),_0x495311));if(_0x3f3ab9[_0xdee9cc(0x1a6)]){const _0xba36dd=_0x3f3ab9[_0xdee9cc(0x1b2)]&&_0x3f3ab9[_0xdee9cc(0x1b2)]!=='';_0xba36dd&&!_0x3f3ab9[_0xdee9cc(0x1ac)]&&_0x112137[_0xdee9cc(0x1a4)]({'level':_0xdee9cc(0x190),'path':_0x45b49c+_0xdee9cc(0x1a1),'code':_0xdee9cc(0x172),'message':_0xdee9cc(0x1ae)+_0x3f3ab9['source']+_0xdee9cc(0x18d)+_0x3f3ab9[_0xdee9cc(0x1b2)]+'\x27\x20'+_0xdee9cc(0x16a)+'the\x20condition\x20queries\x20the\x20master\x20table\x20instead.\x20'+_0xdee9cc(0x1a5),'location':getLocationFromPath(_0x495311['document'],_0x495311['source'],pathToArray(_0x45b49c+'.source'))}),_0xba36dd&&_0x3f3ab9['filter']&&_0x112137[_0xdee9cc(0x1a4)]({'level':_0xdee9cc(0x19d),'path':_0x45b49c+_0xdee9cc(0x185),'code':_0xdee9cc(0x16e),'message':_0xdee9cc(0x1ab)+_0x3f3ab9[_0xdee9cc(0x1b2)]+_0xdee9cc(0x17a)+_0xdee9cc(0x193),'location':getLocationFromPath(_0x495311['document'],_0x495311[_0xdee9cc(0x1a6)],pathToArray(_0x45b49c+_0xdee9cc(0x185)))});}}return _0x112137;}
@@ -1 +1 @@
1
- (function(_0x1b8024,_0x2db6b2){const _0x3a0c03=a157_0x5434,_0x3338b0=_0x1b8024();while(!![]){try{const _0x3b7535=-parseInt(_0x3a0c03(0x128))/0x1*(-parseInt(_0x3a0c03(0x11a))/0x2)+parseInt(_0x3a0c03(0x12b))/0x3+parseInt(_0x3a0c03(0x117))/0x4*(parseInt(_0x3a0c03(0x12e))/0x5)+-parseInt(_0x3a0c03(0x131))/0x6+parseInt(_0x3a0c03(0x141))/0x7*(-parseInt(_0x3a0c03(0x144))/0x8)+-parseInt(_0x3a0c03(0x123))/0x9*(-parseInt(_0x3a0c03(0x13e))/0xa)+parseInt(_0x3a0c03(0x13a))/0xb*(-parseInt(_0x3a0c03(0x139))/0xc);if(_0x3b7535===_0x2db6b2)break;else _0x3338b0['push'](_0x3338b0['shift']());}catch(_0x27ac5f){_0x3338b0['push'](_0x3338b0['shift']());}}}(a157_0x3246,0x306c5));import a157_0x578657 from'path';import{sanitizeFileName}from'../../utils/string-utils.js';import{nodeFileSystem}from'../io/node-filesystem.js';import{isYamlFilePath,resolveYamlFilePath}from'./segment-path-parser.js';import{getSegmentRootDir}from'./tdx-config.js';export function isSuccessfulResolution(_0x167e37){const _0x2d0b81=a157_0x5434;return _0x167e37[_0x2d0b81(0x11d)]!=='error';}export function isScopedResolution(_0xf6f81f){const _0x5475cb=a157_0x5434;return _0xf6f81f[_0x5475cb(0x11d)]===_0x5475cb(0x137)||_0xf6f81f[_0x5475cb(0x11d)]===_0x5475cb(0x129)||_0xf6f81f[_0x5475cb(0x11d)]===_0x5475cb(0x146);}function a157_0x5434(_0x5699e6,_0x4c3e7f){_0x5699e6=_0x5699e6-0x116;const _0x324654=a157_0x3246();let _0x54347c=_0x324654[_0x5699e6];return _0x54347c;}function a157_0x3246(){const _0x319d86=['2443GetLeZ','includes','trim','344whPYGD','resolve','context','scopedFolderPath','File\x20not\x20found:\x20','parent_segment','string','File\x20not\x20found','No\x20tdx.json\x20found\x20for\x20file:\x20','No\x20tdx.json\x20found','readFile','configDir','632HQCgHr','resourceType','tdx.json','104400NRkPUW','journey','Use\x20\x27tdx\x20sg\x20use\x20<parent_name>\x27\x20to\x20set\x20context\x0aOr\x20run\x20\x27tdx\x20sg\x20pull\x20<parent_name>\x27\x20to\x20create\x20the\x20folder\x20structure','type','stat','match','no_parent','isScoped','extname','664515lzlijP','No\x20tdx.json\x20found\x20in\x20or\x20above:\x20','invalid_yaml','Tip:\x20Run\x20\x27tdx\x20sg\x20pull\x20<parent_name>\x27\x20first\x20to\x20create\x20the\x20folder\x20structure\x0a\x20\x20Or\x20set\x20context:\x20\x27tdx\x20sg\x20use\x20<parent_name>\x27','Not\x20a\x20YAML\x20file:\x20','5PnrlPo','file','replace','244509XzPPpU','folderPath','exists','11735dejLhs','isDirectory','Segment\x20and\x20journey\x20files\x20must\x20have\x20.yml\x20or\x20.yaml\x20extension','1172016hfOtMG','root','relative','basename','parse','error','directory','no_config','21492aVgCch','3685DpnAJr','segmentName','startsWith','parentSegment','40ymNPSf','message','dirname'];a157_0x3246=function(){return _0x319d86;};return a157_0x3246();}export function getScopedDetails(_0x342f80){if(isScopedResolution(_0x342f80))return{'isScoped':_0x342f80['isScoped'],'scopedFolderPath':_0x342f80['scopedFolderPath']};return undefined;}async function findTdxConfigAsync(_0x2cac80,_0x1a6e8c){const _0x45d072=a157_0x5434;let _0x2c08a0=a157_0x578657[_0x45d072(0x145)](_0x2cac80);const _0x341233=a157_0x578657[_0x45d072(0x135)](_0x2c08a0)[_0x45d072(0x132)];while(_0x2c08a0!==_0x341233){const _0x89953b=a157_0x578657['join'](_0x2c08a0,_0x45d072(0x119));if(await _0x1a6e8c[_0x45d072(0x12d)](_0x89953b))try{const _0x297726=await _0x1a6e8c[_0x45d072(0x14e)](_0x89953b),_0x47df3a=JSON[_0x45d072(0x135)](_0x297726);if(_0x47df3a[_0x45d072(0x149)]&&typeof _0x47df3a[_0x45d072(0x149)]===_0x45d072(0x14a))return{'configPath':_0x89953b,'configDir':_0x2c08a0,'parentSegment':_0x47df3a[_0x45d072(0x149)]};}catch{}_0x2c08a0=a157_0x578657[_0x45d072(0x140)](_0x2c08a0);}return null;}function calculateScopedPath(_0x35efad,_0x3d6e30){const _0x501b83=a157_0x5434,_0x2342e0=a157_0x578657[_0x501b83(0x133)](_0x3d6e30,_0x35efad),_0x23873a=_0x2342e0!==''&&_0x2342e0!=='.'&&!_0x2342e0[_0x501b83(0x13c)]('..');return{'isScoped':_0x23873a,'scopedFolderPath':_0x23873a?_0x2342e0[_0x501b83(0x12a)](/\\/g,'/'):''};}export async function resolveTarget(_0x1fedf5){const _0x49999c=a157_0x5434,{arg:_0x2c8ca0,contextParent:_0x5052e5,cwd:cwd=process['cwd'](),fs:fs=nodeFileSystem}=_0x1fedf5;if(_0x2c8ca0&&isYamlFilePath(_0x2c8ca0))try{const _0x57c3b1=await resolveYamlFilePath(_0x2c8ca0,fs),_0x6e608d=a157_0x578657['resolve'](_0x2c8ca0),_0x17e543=a157_0x578657[_0x49999c(0x140)](_0x6e608d),_0x16cf8d=await findTdxConfigAsync(_0x17e543,fs);if(!_0x16cf8d){if(_0x5052e5){const _0x480bf0=a157_0x578657[_0x49999c(0x140)](_0x6e608d);return{'type':_0x49999c(0x129),'parentName':_0x5052e5,'targetDir':_0x480bf0,'configRoot':_0x480bf0,'filePath':_0x6e608d,'resourceName':_0x57c3b1['segmentName'],'folderPath':_0x57c3b1[_0x49999c(0x12c)],'resourceType':_0x57c3b1[_0x49999c(0x118)],'isScoped':![],'scopedFolderPath':''};}return{'type':'error','errorCode':_0x49999c(0x138),'message':_0x49999c(0x14c)+_0x2c8ca0,'arg':_0x2c8ca0,'helpText':'Tip:\x20Run\x20\x27tdx\x20sg\x20pull\x20<parent_name>\x27\x20first\x20to\x20create\x20the\x20folder\x20structure\x0a\x20\x20Or\x20set\x20context:\x20\x27tdx\x20sg\x20use\x20<parent_name>\x27'};}const _0x1d6674=calculateScopedPath(_0x17e543,_0x16cf8d['configDir']);return{'type':_0x49999c(0x129),'parentName':_0x16cf8d[_0x49999c(0x13d)],'targetDir':_0x16cf8d['configDir'],'configRoot':_0x16cf8d[_0x49999c(0x116)],'filePath':_0x6e608d,'resourceName':_0x57c3b1[_0x49999c(0x13b)],'folderPath':_0x57c3b1['folderPath'],'resourceType':_0x57c3b1[_0x49999c(0x118)],'isScoped':_0x1d6674[_0x49999c(0x121)],'scopedFolderPath':_0x1d6674[_0x49999c(0x147)]};}catch(_0x2de20c){const _0x11d07f=_0x2de20c instanceof Error?_0x2de20c[_0x49999c(0x13f)]:String(_0x2de20c);if(_0x11d07f[_0x49999c(0x142)](_0x49999c(0x14b)))return{'type':_0x49999c(0x136),'errorCode':'file_not_found','message':_0x49999c(0x148)+_0x2c8ca0,'arg':_0x2c8ca0};if(_0x11d07f[_0x49999c(0x142)](_0x49999c(0x14d))){if(_0x5052e5){const _0x3ae72b=a157_0x578657[_0x49999c(0x145)](_0x2c8ca0);if(await fs[_0x49999c(0x12d)](_0x3ae72b)){const _0x41e29d=a157_0x578657[_0x49999c(0x140)](_0x3ae72b),_0x504640=await fs[_0x49999c(0x14e)](_0x3ae72b),_0x377652=_0x504640[_0x49999c(0x11f)](/^name:\s*["']?([^"'\n]+)["']?/m),_0x2172f6=_0x504640[_0x49999c(0x11f)](/^type:\s*["']?([^"'\n]+)["']?/m),_0x1696af=_0x377652?_0x377652[0x1]['trim']():a157_0x578657[_0x49999c(0x134)](_0x2c8ca0,a157_0x578657[_0x49999c(0x122)](_0x2c8ca0)),_0xed1687=_0x2172f6&&_0x2172f6[0x1][_0x49999c(0x143)]()===_0x49999c(0x11b)?'journey':'segment';return{'type':_0x49999c(0x129),'parentName':_0x5052e5,'targetDir':_0x41e29d,'configRoot':_0x41e29d,'filePath':_0x3ae72b,'resourceName':_0x1696af,'folderPath':'','resourceType':_0xed1687,'isScoped':![],'scopedFolderPath':''};}}return{'type':_0x49999c(0x136),'errorCode':_0x49999c(0x138),'message':'No\x20tdx.json\x20found\x20for\x20file:\x20'+_0x2c8ca0,'arg':_0x2c8ca0,'helpText':'Tip:\x20Run\x20\x27tdx\x20sg\x20pull\x20<parent_name>\x27\x20first\x20to\x20create\x20the\x20folder\x20structure\x0a\x20\x20Or\x20set\x20context:\x20\x27tdx\x20sg\x20use\x20<parent_name>\x27'};}return{'type':'error','errorCode':_0x49999c(0x125),'message':_0x11d07f,'arg':_0x2c8ca0};}if(_0x2c8ca0){const _0x444e0f=a157_0x578657[_0x49999c(0x145)](cwd,_0x2c8ca0);let _0x5bab07=null;try{_0x5bab07=await fs[_0x49999c(0x11e)](_0x444e0f);}catch{}if(_0x5bab07?.[_0x49999c(0x12f)]()){const _0x3c4b16=await findTdxConfigAsync(_0x444e0f,fs);if(_0x3c4b16){const _0x4c1813=calculateScopedPath(_0x444e0f,_0x3c4b16['configDir']);return{'type':'directory','parentName':_0x3c4b16[_0x49999c(0x13d)],'targetDir':_0x444e0f,'configRoot':_0x3c4b16[_0x49999c(0x116)],'isScoped':_0x4c1813[_0x49999c(0x121)],'scopedFolderPath':_0x4c1813[_0x49999c(0x147)]};}if(_0x5052e5)return{'type':_0x49999c(0x137),'parentName':_0x5052e5,'targetDir':_0x444e0f,'configRoot':_0x444e0f,'isScoped':![],'scopedFolderPath':''};return{'type':_0x49999c(0x136),'errorCode':_0x49999c(0x138),'message':_0x49999c(0x124)+_0x2c8ca0,'arg':_0x2c8ca0,'helpText':_0x49999c(0x126)};}if(_0x5bab07?.['isFile']())return{'type':_0x49999c(0x136),'errorCode':'invalid_yaml','message':_0x49999c(0x127)+_0x2c8ca0,'arg':_0x2c8ca0,'helpText':_0x49999c(0x130)};const _0x998b17=sanitizeFileName(_0x2c8ca0),_0x56186b=getSegmentRootDir(_0x998b17,cwd);return{'type':'parent_name','parentName':_0x2c8ca0,'targetDir':_0x56186b,'configRoot':_0x56186b};}const _0x334df2=await findTdxConfigAsync(cwd,fs);if(_0x334df2){const _0x3693cf=calculateScopedPath(cwd,_0x334df2['configDir']);return{'type':_0x49999c(0x146),'parentName':_0x334df2[_0x49999c(0x13d)],'targetDir':cwd,'configRoot':_0x334df2[_0x49999c(0x116)],'isScoped':_0x3693cf[_0x49999c(0x121)],'scopedFolderPath':_0x3693cf[_0x49999c(0x147)]};}if(_0x5052e5){const _0xfbf7e0=sanitizeFileName(_0x5052e5),_0x488942=getSegmentRootDir(_0xfbf7e0,cwd);return{'type':_0x49999c(0x146),'parentName':_0x5052e5,'targetDir':_0x488942,'configRoot':_0x488942,'isScoped':![],'scopedFolderPath':''};}return{'type':'error','errorCode':_0x49999c(0x120),'message':'Parent\x20segment\x20not\x20specified','helpText':_0x49999c(0x11c)};}
1
+ (function(_0x4a16ad,_0x144c20){const _0x116777=a157_0x5f54,_0x490c3a=_0x4a16ad();while(!![]){try{const _0x3b605f=parseInt(_0x116777(0x1cd))/0x1*(-parseInt(_0x116777(0x1b8))/0x2)+parseInt(_0x116777(0x1bb))/0x3*(parseInt(_0x116777(0x1b9))/0x4)+-parseInt(_0x116777(0x1b7))/0x5+-parseInt(_0x116777(0x1ad))/0x6*(parseInt(_0x116777(0x1a1))/0x7)+parseInt(_0x116777(0x1bc))/0x8+parseInt(_0x116777(0x1c3))/0x9+-parseInt(_0x116777(0x1d2))/0xa;if(_0x3b605f===_0x144c20)break;else _0x490c3a['push'](_0x490c3a['shift']());}catch(_0x2a69fb){_0x490c3a['push'](_0x490c3a['shift']());}}}(a157_0x57e1,0x63d0a));import a157_0x4bddb6 from'path';import{sanitizeFileName}from'../../utils/string-utils.js';import{nodeFileSystem}from'../io/node-filesystem.js';function a157_0x57e1(){const _0x183905=['parent_name','segmentName','message','No\x20tdx.json\x20found\x20for\x20file:\x20','resourceType','file_not_found','extname','context','3061tUFKMP','invalid_yaml','File\x20not\x20found','no_config','isScoped','4408600qfaIvC','join','parentSegment','no_parent','folderPath','Parent\x20segment\x20not\x20specified','1592633tsPuBY','No\x20tdx.json\x20found','scopedFolderPath','tdx.json','dirname','parse','isFile','type','string','replace','includes','parent_segment','6PnIREW','match','Use\x20\x27tdx\x20sg\x20use\x20<parent_name>\x27\x20to\x20set\x20context\x0aOr\x20run\x20\x27tdx\x20sg\x20pull\x20<parent_name>\x27\x20to\x20create\x20the\x20folder\x20structure','File\x20not\x20found:\x20','configDir','relative','trim','cwd','directory','journey','1959995oTUihU','2WqgmOO','52eLUGpN','startsWith','62001xdAanu','6415528GrAXPC','error','file','resolve','Tip:\x20Run\x20\x27tdx\x20sg\x20pull\x20<parent_name>\x27\x20first\x20to\x20create\x20the\x20folder\x20structure\x0a\x20\x20Or\x20set\x20context:\x20\x27tdx\x20sg\x20use\x20<parent_name>\x27','exists','root','3615021wJINlY','isDirectory'];a157_0x57e1=function(){return _0x183905;};return a157_0x57e1();}import{isYamlFilePath,resolveYamlFilePath}from'./segment-path-parser.js';import{getSegmentRootDir}from'./tdx-config.js';export function isSuccessfulResolution(_0x195bff){const _0x4b3b8f=a157_0x5f54;return _0x195bff[_0x4b3b8f(0x1a8)]!==_0x4b3b8f(0x1bd);}export function isScopedResolution(_0x45bd21){const _0x452508=a157_0x5f54;return _0x45bd21['type']===_0x452508(0x1b5)||_0x45bd21[_0x452508(0x1a8)]==='file'||_0x45bd21[_0x452508(0x1a8)]==='context';}export function getScopedDetails(_0x262f4b){const _0x71ca2b=a157_0x5f54;if(isScopedResolution(_0x262f4b))return{'isScoped':_0x262f4b[_0x71ca2b(0x1d1)],'scopedFolderPath':_0x262f4b['scopedFolderPath']};return undefined;}async function findTdxConfigAsync(_0x52be09,_0x3e34d2){const _0x369018=a157_0x5f54;let _0x50e3f3=a157_0x4bddb6[_0x369018(0x1bf)](_0x52be09);const _0x4a53b2=a157_0x4bddb6['parse'](_0x50e3f3)[_0x369018(0x1c2)];while(_0x50e3f3!==_0x4a53b2){const _0x5f550a=a157_0x4bddb6[_0x369018(0x1d3)](_0x50e3f3,_0x369018(0x1a4));if(await _0x3e34d2[_0x369018(0x1c1)](_0x5f550a))try{const _0x4a39cf=await _0x3e34d2['readFile'](_0x5f550a),_0x3a4de8=JSON[_0x369018(0x1a6)](_0x4a39cf);if(_0x3a4de8[_0x369018(0x1ac)]&&typeof _0x3a4de8[_0x369018(0x1ac)]===_0x369018(0x1a9))return{'configPath':_0x5f550a,'configDir':_0x50e3f3,'parentSegment':_0x3a4de8[_0x369018(0x1ac)]};}catch{}_0x50e3f3=a157_0x4bddb6[_0x369018(0x1a5)](_0x50e3f3);}return null;}function a157_0x5f54(_0x469837,_0x25c962){_0x469837=_0x469837-0x1a0;const _0x57e1e9=a157_0x57e1();let _0x5f5417=_0x57e1e9[_0x469837];return _0x5f5417;}function calculateScopedPath(_0x9a735,_0x2535a8){const _0x4b189d=a157_0x5f54,_0xe2cbec=a157_0x4bddb6[_0x4b189d(0x1b2)](_0x2535a8,_0x9a735),_0x3cc484=_0xe2cbec!==''&&_0xe2cbec!=='.'&&!_0xe2cbec[_0x4b189d(0x1ba)]('..');return{'isScoped':_0x3cc484,'scopedFolderPath':_0x3cc484?_0xe2cbec[_0x4b189d(0x1aa)](/\\/g,'/'):''};}export async function resolveTarget(_0x342bc8){const _0x57962a=a157_0x5f54,{arg:_0x4a0e58,contextParent:_0x5103a7,cwd:cwd=process[_0x57962a(0x1b4)](),fs:fs=nodeFileSystem}=_0x342bc8;if(_0x4a0e58&&isYamlFilePath(_0x4a0e58))try{const _0x36b539=await resolveYamlFilePath(_0x4a0e58,fs),_0xa31e=a157_0x4bddb6[_0x57962a(0x1bf)](_0x4a0e58),_0x2385d8=a157_0x4bddb6[_0x57962a(0x1a5)](_0xa31e),_0x24c344=await findTdxConfigAsync(_0x2385d8,fs);if(!_0x24c344){if(_0x5103a7){const _0x221543=a157_0x4bddb6['dirname'](_0xa31e);return{'type':_0x57962a(0x1be),'parentName':_0x5103a7,'targetDir':_0x221543,'configRoot':_0x221543,'filePath':_0xa31e,'resourceName':_0x36b539[_0x57962a(0x1c6)],'folderPath':_0x36b539[_0x57962a(0x1d6)],'resourceType':_0x36b539[_0x57962a(0x1c9)],'isScoped':![],'scopedFolderPath':''};}return{'type':_0x57962a(0x1bd),'errorCode':_0x57962a(0x1d0),'message':_0x57962a(0x1c8)+_0x4a0e58,'arg':_0x4a0e58,'helpText':_0x57962a(0x1c0)};}const _0x51c551=calculateScopedPath(_0x2385d8,_0x24c344[_0x57962a(0x1b1)]);return{'type':_0x57962a(0x1be),'parentName':_0x24c344[_0x57962a(0x1d4)],'targetDir':_0x24c344[_0x57962a(0x1b1)],'configRoot':_0x24c344['configDir'],'filePath':_0xa31e,'resourceName':_0x36b539[_0x57962a(0x1c6)],'folderPath':_0x36b539[_0x57962a(0x1d6)],'resourceType':_0x36b539['resourceType'],'isScoped':_0x51c551['isScoped'],'scopedFolderPath':_0x51c551[_0x57962a(0x1a3)]};}catch(_0x15f56d){const _0x1a13d2=_0x15f56d instanceof Error?_0x15f56d[_0x57962a(0x1c7)]:String(_0x15f56d);if(_0x1a13d2[_0x57962a(0x1ab)](_0x57962a(0x1cf)))return{'type':'error','errorCode':_0x57962a(0x1ca),'message':_0x57962a(0x1b0)+_0x4a0e58,'arg':_0x4a0e58};if(_0x1a13d2[_0x57962a(0x1ab)](_0x57962a(0x1a2))){if(_0x5103a7){const _0xef319e=a157_0x4bddb6[_0x57962a(0x1bf)](_0x4a0e58);if(await fs[_0x57962a(0x1c1)](_0xef319e)){const _0x62e17a=a157_0x4bddb6[_0x57962a(0x1a5)](_0xef319e),_0x2e1ac1=await fs['readFile'](_0xef319e),_0x304561=_0x2e1ac1[_0x57962a(0x1ae)](/^name:\s*["']?([^"'\n]+)["']?/m),_0x37a23a=_0x2e1ac1[_0x57962a(0x1ae)](/^type:\s*["']?([^"'\n]+)["']?/m),_0x1ec6f=_0x304561?_0x304561[0x1][_0x57962a(0x1b3)]():a157_0x4bddb6['basename'](_0x4a0e58,a157_0x4bddb6[_0x57962a(0x1cb)](_0x4a0e58)),_0x1417c4=_0x37a23a&&_0x37a23a[0x1][_0x57962a(0x1b3)]()==='journey'?_0x57962a(0x1b6):'segment';return{'type':'file','parentName':_0x5103a7,'targetDir':_0x62e17a,'configRoot':_0x62e17a,'filePath':_0xef319e,'resourceName':_0x1ec6f,'folderPath':'','resourceType':_0x1417c4,'isScoped':![],'scopedFolderPath':''};}}return{'type':_0x57962a(0x1bd),'errorCode':_0x57962a(0x1d0),'message':_0x57962a(0x1c8)+_0x4a0e58,'arg':_0x4a0e58,'helpText':'Tip:\x20Run\x20\x27tdx\x20sg\x20pull\x20<parent_name>\x27\x20first\x20to\x20create\x20the\x20folder\x20structure\x0a\x20\x20Or\x20set\x20context:\x20\x27tdx\x20sg\x20use\x20<parent_name>\x27'};}return{'type':'error','errorCode':_0x57962a(0x1ce),'message':_0x1a13d2,'arg':_0x4a0e58};}if(_0x4a0e58){const _0x5060cf=a157_0x4bddb6[_0x57962a(0x1bf)](cwd,_0x4a0e58);let _0x18ccf3=null;try{_0x18ccf3=await fs['stat'](_0x5060cf);}catch{}if(_0x18ccf3?.[_0x57962a(0x1c4)]()){const _0x219fd5=await findTdxConfigAsync(_0x5060cf,fs);if(_0x219fd5){const _0x28edbd=calculateScopedPath(_0x5060cf,_0x219fd5['configDir']);return{'type':_0x57962a(0x1b5),'parentName':_0x219fd5[_0x57962a(0x1d4)],'targetDir':_0x5060cf,'configRoot':_0x219fd5[_0x57962a(0x1b1)],'isScoped':_0x28edbd[_0x57962a(0x1d1)],'scopedFolderPath':_0x28edbd[_0x57962a(0x1a3)]};}if(_0x5103a7)return{'type':_0x57962a(0x1b5),'parentName':_0x5103a7,'targetDir':_0x5060cf,'configRoot':_0x5060cf,'isScoped':![],'scopedFolderPath':''};return{'type':_0x57962a(0x1bd),'errorCode':'no_config','message':'No\x20tdx.json\x20found\x20in\x20or\x20above:\x20'+_0x4a0e58,'arg':_0x4a0e58,'helpText':'Tip:\x20Run\x20\x27tdx\x20sg\x20pull\x20<parent_name>\x27\x20first\x20to\x20create\x20the\x20folder\x20structure\x0a\x20\x20Or\x20set\x20context:\x20\x27tdx\x20sg\x20use\x20<parent_name>\x27'};}if(_0x18ccf3?.[_0x57962a(0x1a7)]())return{'type':_0x57962a(0x1bd),'errorCode':_0x57962a(0x1ce),'message':'Not\x20a\x20YAML\x20file:\x20'+_0x4a0e58,'arg':_0x4a0e58,'helpText':'Segment\x20and\x20journey\x20files\x20must\x20have\x20.yml\x20or\x20.yaml\x20extension'};const _0x60f8ee=sanitizeFileName(_0x4a0e58),_0xf35e12=getSegmentRootDir(_0x60f8ee,cwd);return{'type':_0x57962a(0x1c5),'parentName':_0x4a0e58,'targetDir':_0xf35e12,'configRoot':_0xf35e12};}const _0x225ea7=await findTdxConfigAsync(cwd,fs);if(_0x225ea7){const _0x324ded=calculateScopedPath(cwd,_0x225ea7['configDir']);return{'type':_0x57962a(0x1cc),'parentName':_0x225ea7['parentSegment'],'targetDir':cwd,'configRoot':_0x225ea7[_0x57962a(0x1b1)],'isScoped':_0x324ded[_0x57962a(0x1d1)],'scopedFolderPath':_0x324ded[_0x57962a(0x1a3)]};}if(_0x5103a7){const _0x510641=sanitizeFileName(_0x5103a7),_0x1a2c0b=getSegmentRootDir(_0x510641,cwd);return{'type':_0x57962a(0x1cc),'parentName':_0x5103a7,'targetDir':_0x1a2c0b,'configRoot':_0x1a2c0b,'isScoped':![],'scopedFolderPath':''};}return{'type':_0x57962a(0x1bd),'errorCode':_0x57962a(0x1d5),'message':_0x57962a(0x1a0),'helpText':_0x57962a(0x1af)};}
@@ -1 +1 @@
1
- const a158_0x46aa0d=a158_0x3378;(function(_0xddd1a7,_0x3505e2){const _0x1d6332=a158_0x3378,_0x42fd1c=_0xddd1a7();while(!![]){try{const _0x822b9e=-parseInt(_0x1d6332(0xf4))/0x1+-parseInt(_0x1d6332(0x100))/0x2+-parseInt(_0x1d6332(0xff))/0x3+parseInt(_0x1d6332(0xfc))/0x4+-parseInt(_0x1d6332(0x107))/0x5*(-parseInt(_0x1d6332(0x105))/0x6)+parseInt(_0x1d6332(0x102))/0x7*(parseInt(_0x1d6332(0x108))/0x8)+parseInt(_0x1d6332(0x101))/0x9;if(_0x822b9e===_0x3505e2)break;else _0x42fd1c['push'](_0x42fd1c['shift']());}catch(_0x30498e){_0x42fd1c['push'](_0x42fd1c['shift']());}}}(a158_0x1970,0x5ac1d));import{existsSync,readFileSync}from'fs';import a158_0x43cbd0 from'path';const TDX_CONFIG_FILE=a158_0x46aa0d(0x104),SEGMENTS_DIR=a158_0x46aa0d(0xf5);function a158_0x1970(){const _0x5a13b6=['1509411BuPWrk','1245796EnUXjB','7552053fyCHfo','7WoWJqm','utf-8','tdx.json','6gXaYEQ','engage_workspace','81935rAODdx','2140744IHoGMI','No\x20tdx.json\x20found.\x20Please\x20run\x20\x27tdx\x20sg\x20pull\x20<parent_segment>\x27\x20first\x20to\x20create\x20the\x20folder\x20structure.','parent_segment','parse','startsWith','Invalid\x20tdx.json:\x20expected\x20object','249773vNotjz','segments','resolve','string','stringify','dirname','Invalid\x20JSON\x20in\x20','relative','2497808jaFbzy','cwd','join'];a158_0x1970=function(){return _0x5a13b6;};return a158_0x1970();}export function findTdxConfigPath(_0x17bf2d=process[a158_0x46aa0d(0xfd)]()){const _0x1e9098=a158_0x46aa0d;let _0x550e73=a158_0x43cbd0[_0x1e9098(0xf6)](_0x17bf2d);const _0x2d817c=a158_0x43cbd0[_0x1e9098(0x10b)](_0x550e73)['root'];while(_0x550e73!==_0x2d817c){const _0x2c3ec0=a158_0x43cbd0[_0x1e9098(0xfe)](_0x550e73,TDX_CONFIG_FILE);if(existsSync(_0x2c3ec0))return _0x2c3ec0;_0x550e73=a158_0x43cbd0['dirname'](_0x550e73);}return null;}function a158_0x3378(_0x52c117,_0x3eff67){_0x52c117=_0x52c117-0xf3;const _0x197079=a158_0x1970();let _0x3378bd=_0x197079[_0x52c117];return _0x3378bd;}export function loadTdxConfig(_0x115770){const _0x5d4216=a158_0x46aa0d,_0xb4e360=readFileSync(_0x115770,_0x5d4216(0x103));let _0x33589a;try{_0x33589a=JSON[_0x5d4216(0x10b)](_0xb4e360);}catch{throw new Error(_0x5d4216(0xfa)+_0x115770);}if(!_0x33589a||typeof _0x33589a!=='object')throw new Error(_0x5d4216(0xf3));const _0x200a94=_0x33589a,_0x335553=_0x200a94[_0x5d4216(0x10a)]&&typeof _0x200a94[_0x5d4216(0x10a)]===_0x5d4216(0xf7),_0x106461=_0x200a94['engage_workspace']&&typeof _0x200a94['engage_workspace']===_0x5d4216(0xf7);if(!_0x335553&&!_0x106461)throw new Error('Invalid\x20tdx.json:\x20must\x20contain\x20\x27parent_segment\x27\x20or\x20\x27engage_workspace\x27\x20field');const _0x4ed81a={};return _0x335553&&(_0x4ed81a[_0x5d4216(0x10a)]=_0x200a94['parent_segment']),_0x106461&&(_0x4ed81a[_0x5d4216(0x106)]=_0x200a94[_0x5d4216(0x106)]),_0x4ed81a;}export function findTdxConfig(_0x4bd8c3=process[a158_0x46aa0d(0xfd)]()){const _0x224655=a158_0x46aa0d,_0x4b4de0=findTdxConfigPath(_0x4bd8c3);if(!_0x4b4de0)throw new Error(_0x224655(0x109));const _0x3cb4f1=loadTdxConfig(_0x4b4de0),_0x3d8300=a158_0x43cbd0[_0x224655(0xf9)](_0x4b4de0);return{'config':_0x3cb4f1,'configPath':_0x4b4de0,'configDir':_0x3d8300};}export function tryFindTdxConfig(_0x31613e){try{return findTdxConfig(_0x31613e);}catch{return null;}}export function getSegmentRootDir(_0x305cc6,_0x565662=process[a158_0x46aa0d(0xfd)]()){const _0x1e85ed=a158_0x46aa0d;return a158_0x43cbd0[_0x1e85ed(0xfe)](_0x565662,SEGMENTS_DIR,_0x305cc6);}export function getTdxConfigPath(_0x28bf37,_0x1bd499=process[a158_0x46aa0d(0xfd)]()){const _0x529c47=a158_0x46aa0d;return a158_0x43cbd0[_0x529c47(0xfe)](getSegmentRootDir(_0x28bf37,_0x1bd499),TDX_CONFIG_FILE);}export function getRelativePathFromConfig(_0x387afb,_0x59a903){const _0x5e5877=a158_0x46aa0d,_0xd4dbd3=a158_0x43cbd0[_0x5e5877(0xf6)](_0x387afb),_0x383005=a158_0x43cbd0[_0x5e5877(0xfb)](_0x59a903,_0xd4dbd3);if(_0x383005[_0x5e5877(0x10c)]('..'))return'';return _0x383005;}export function localPathToTdFolderPath(_0x35cfc1){const _0x3634b7=a158_0x46aa0d,_0x900638=a158_0x43cbd0[_0x3634b7(0xf9)](_0x35cfc1);if(_0x900638==='.'||_0x900638==='')return'';return _0x900638['replace'](/\\/g,'/');}export function tdFolderPathToLocalPath(_0x290f00,_0x5a2832){const _0x3a182e=a158_0x46aa0d;if(!_0x290f00)return _0x5a2832;return a158_0x43cbd0[_0x3a182e(0xfe)](_0x5a2832,_0x290f00);}export function createTdxConfigContent(_0xa7d8bc){const _0x474c29=a158_0x46aa0d,_0x4da61a={'parent_segment':_0xa7d8bc};return JSON[_0x474c29(0xf8)](_0x4da61a,null,0x2)+'\x0a';}export function createEngageTdxConfigContent(_0x58992f){const _0x2a8646=a158_0x46aa0d,_0x57ca99={'engage_workspace':_0x58992f};return JSON[_0x2a8646(0xf8)](_0x57ca99,null,0x2)+'\x0a';}
1
+ const a158_0xdf8fa=a158_0x568a;(function(_0x5983b0,_0x54eed4){const _0x3821d7=a158_0x568a,_0x2aed46=_0x5983b0();while(!![]){try{const _0x3e4449=parseInt(_0x3821d7(0xa7))/0x1*(-parseInt(_0x3821d7(0xa8))/0x2)+-parseInt(_0x3821d7(0xad))/0x3*(-parseInt(_0x3821d7(0xb5))/0x4)+-parseInt(_0x3821d7(0xa4))/0x5*(-parseInt(_0x3821d7(0xaf))/0x6)+-parseInt(_0x3821d7(0xb0))/0x7+-parseInt(_0x3821d7(0xac))/0x8*(-parseInt(_0x3821d7(0xb1))/0x9)+-parseInt(_0x3821d7(0xb4))/0xa*(-parseInt(_0x3821d7(0xb9))/0xb)+-parseInt(_0x3821d7(0xbc))/0xc;if(_0x3e4449===_0x54eed4)break;else _0x2aed46['push'](_0x2aed46['shift']());}catch(_0x22cd5e){_0x2aed46['push'](_0x2aed46['shift']());}}}(a158_0x82ab,0xc3986));import{existsSync,readFileSync}from'fs';import a158_0x190b12 from'path';const TDX_CONFIG_FILE=a158_0xdf8fa(0xba),SEGMENTS_DIR='segments';export function findTdxConfigPath(_0x15257b=process[a158_0xdf8fa(0xc0)]()){const _0x19045c=a158_0xdf8fa;let _0xf414d6=a158_0x190b12[_0x19045c(0xa9)](_0x15257b);const _0x412311=a158_0x190b12['parse'](_0xf414d6)[_0x19045c(0xa5)];while(_0xf414d6!==_0x412311){const _0x4ffe1f=a158_0x190b12[_0x19045c(0xbe)](_0xf414d6,TDX_CONFIG_FILE);if(existsSync(_0x4ffe1f))return _0x4ffe1f;_0xf414d6=a158_0x190b12[_0x19045c(0xbd)](_0xf414d6);}return null;}export function loadTdxConfig(_0x264582){const _0x422626=a158_0xdf8fa,_0x3a5c20=readFileSync(_0x264582,_0x422626(0xaa));let _0x4ed470;try{_0x4ed470=JSON[_0x422626(0xab)](_0x3a5c20);}catch{throw new Error(_0x422626(0xa6)+_0x264582);}if(!_0x4ed470||typeof _0x4ed470!==_0x422626(0xb3))throw new Error('Invalid\x20tdx.json:\x20expected\x20object');const _0x33095e=_0x4ed470,_0x4551df=_0x33095e[_0x422626(0xb7)]&&typeof _0x33095e[_0x422626(0xb7)]==='string',_0x292e92=_0x33095e[_0x422626(0xb6)]&&typeof _0x33095e[_0x422626(0xb6)]==='string';if(!_0x4551df&&!_0x292e92)throw new Error(_0x422626(0xbf));const _0x1b1341={};return _0x4551df&&(_0x1b1341[_0x422626(0xb7)]=_0x33095e[_0x422626(0xb7)]),_0x292e92&&(_0x1b1341[_0x422626(0xb6)]=_0x33095e['engage_workspace']),_0x1b1341;}export function findTdxConfig(_0x1461ff=process[a158_0xdf8fa(0xc0)]()){const _0x2fa7bb=a158_0xdf8fa,_0x16cdfa=findTdxConfigPath(_0x1461ff);if(!_0x16cdfa)throw new Error('No\x20tdx.json\x20found.\x20Please\x20run\x20\x27tdx\x20sg\x20pull\x20<parent_segment>\x27\x20first\x20to\x20create\x20the\x20folder\x20structure.');const _0x5f059f=loadTdxConfig(_0x16cdfa),_0x204269=a158_0x190b12[_0x2fa7bb(0xbd)](_0x16cdfa);return{'config':_0x5f059f,'configPath':_0x16cdfa,'configDir':_0x204269};}function a158_0x568a(_0x326ccd,_0x484e37){_0x326ccd=_0x326ccd-0xa4;const _0x82abcf=a158_0x82ab();let _0x568a84=_0x82abcf[_0x326ccd];return _0x568a84;}export function tryFindTdxConfig(_0x510752){try{return findTdxConfig(_0x510752);}catch{return null;}}export function getSegmentRootDir(_0x2fa4e8,_0x4bbf38=process['cwd']()){const _0x20f509=a158_0xdf8fa;return a158_0x190b12[_0x20f509(0xbe)](_0x4bbf38,SEGMENTS_DIR,_0x2fa4e8);}export function getTdxConfigPath(_0x293c11,_0x53d7e0=process['cwd']()){const _0x4e0993=a158_0xdf8fa;return a158_0x190b12[_0x4e0993(0xbe)](getSegmentRootDir(_0x293c11,_0x53d7e0),TDX_CONFIG_FILE);}export function getRelativePathFromConfig(_0x523987,_0x37b9a2){const _0x180aae=a158_0xdf8fa,_0x142f11=a158_0x190b12[_0x180aae(0xa9)](_0x523987),_0x17dbc1=a158_0x190b12[_0x180aae(0xbb)](_0x37b9a2,_0x142f11);if(_0x17dbc1[_0x180aae(0xb2)]('..'))return'';return _0x17dbc1;}export function localPathToTdFolderPath(_0x28b1cd){const _0x29a628=a158_0xdf8fa,_0x4f9724=a158_0x190b12[_0x29a628(0xbd)](_0x28b1cd);if(_0x4f9724==='.'||_0x4f9724==='')return'';return _0x4f9724[_0x29a628(0xae)](/\\/g,'/');}export function tdFolderPathToLocalPath(_0x5bb62d,_0x4f32d2){const _0x58c484=a158_0xdf8fa;if(!_0x5bb62d)return _0x4f32d2;return a158_0x190b12[_0x58c484(0xbe)](_0x4f32d2,_0x5bb62d);}export function createTdxConfigContent(_0x52be65){const _0x50ffce=a158_0xdf8fa,_0x11b0d8={'parent_segment':_0x52be65};return JSON[_0x50ffce(0xb8)](_0x11b0d8,null,0x2)+'\x0a';}function a158_0x82ab(){const _0xed5470=['parse','6387048bcwknv','3OEmJBo','replace','3189090njdtNW','3584084MnWwrm','9ylUXlu','startsWith','object','247150biLroM','4845836QVSABW','engage_workspace','parent_segment','stringify','176iZMSgy','tdx.json','relative','17755032cJGTXo','dirname','join','Invalid\x20tdx.json:\x20must\x20contain\x20\x27parent_segment\x27\x20or\x20\x27engage_workspace\x27\x20field','cwd','10lfQEQt','root','Invalid\x20JSON\x20in\x20','675554jSXTlB','2QFxxjc','resolve','utf-8'];a158_0x82ab=function(){return _0xed5470;};return a158_0x82ab();}export function createEngageTdxConfigContent(_0x1685e3){const _0x569b06=a158_0xdf8fa,_0xcbba5a={'engage_workspace':_0x1685e3};return JSON[_0x569b06(0xb8)](_0xcbba5a,null,0x2)+'\x0a';}
@@ -1 +1 @@
1
- const a159_0x199fd4=a159_0x2882;(function(_0x556b88,_0x487885){const _0x2ee9f7=a159_0x2882,_0xf05db8=_0x556b88();while(!![]){try{const _0x144a33=-parseInt(_0x2ee9f7(0x7d))/0x1+-parseInt(_0x2ee9f7(0x85))/0x2+-parseInt(_0x2ee9f7(0x9d))/0x3*(-parseInt(_0x2ee9f7(0x79))/0x4)+-parseInt(_0x2ee9f7(0x86))/0x5*(parseInt(_0x2ee9f7(0x8f))/0x6)+parseInt(_0x2ee9f7(0x90))/0x7+parseInt(_0x2ee9f7(0x7e))/0x8*(parseInt(_0x2ee9f7(0x88))/0x9)+parseInt(_0x2ee9f7(0xa1))/0xa*(parseInt(_0x2ee9f7(0x99))/0xb);if(_0x144a33===_0x487885)break;else _0xf05db8['push'](_0xf05db8['shift']());}catch(_0x1f2f83){_0xf05db8['push'](_0xf05db8['shift']());}}}(a159_0x35f8,0x9e5b6));import{z}from'zod';export const ScheduleTypeSchema=z[a159_0x199fd4(0x9a)]([a159_0x199fd4(0x8e),a159_0x199fd4(0x9c),'daily',a159_0x199fd4(0x87),a159_0x199fd4(0x91),'cron',a159_0x199fd4(0x92)]);function a159_0x35f8(){const _0xe48c70=['weekly','9wAlYMO','day','min','Activation\x20name\x20is\x20required','masked','string','none','2903412DjQcSB','6536551lMlskE','monthly','minutes_interval','record','rows','week','cols','All','number','13158079kogfjS','enum','minute','hourly','14850kGaNHu','optional','asc','once','10romjTC','208ScCBjn','boolean','Last','onSuccess','1173533sAgbtJ','5677664fvkvnI','object','union','desc','nullable','onFailure','array','614246IBwaua','10rRaEdW'];a159_0x35f8=function(){return _0xe48c70;};return a159_0x35f8();}export const RepeatUnitSchema=z[a159_0x199fd4(0x9a)]([a159_0x199fd4(0x9b),'hour',a159_0x199fd4(0x89),a159_0x199fd4(0x95),'month',a159_0x199fd4(0xa0),a159_0x199fd4(0x8e)]);export const ScheduleDefSchema=z[a159_0x199fd4(0x7f)]({'type':ScheduleTypeSchema[a159_0x199fd4(0x9e)](),'repeat_unit':RepeatUnitSchema[a159_0x199fd4(0x9e)](),'repeat_frequency':z[a159_0x199fd4(0x98)]()[a159_0x199fd4(0x9e)](),'repeat_sub_frequency':z['array'](z['number']())[a159_0x199fd4(0x9e)](),'start_at':z[a159_0x199fd4(0x8d)]()[a159_0x199fd4(0x82)]()[a159_0x199fd4(0x9e)](),'end_on':z[a159_0x199fd4(0x8d)]()[a159_0x199fd4(0x82)]()['optional'](),'timezone':z[a159_0x199fd4(0x8d)]()[a159_0x199fd4(0x9e)]()});function a159_0x2882(_0x33f185,_0x58a60f){_0x33f185=_0x33f185-0x79;const _0x35f843=a159_0x35f8();let _0x28821c=_0x35f843[_0x33f185];return _0x28821c;}export const NotificationDefSchema=z['object']({'notify_on':z[a159_0x199fd4(0x84)](z['enum']([a159_0x199fd4(0x7c),a159_0x199fd4(0x83)]))[a159_0x199fd4(0x9e)](),'email_recipients':z[a159_0x199fd4(0x84)](z[a159_0x199fd4(0x8d)]())[a159_0x199fd4(0x9e)]()});export const ActivationColumnDefSchema=z[a159_0x199fd4(0x80)]([z[a159_0x199fd4(0x8d)](),z['object']({'name':z[a159_0x199fd4(0x8d)](),'type':z[a159_0x199fd4(0x8d)]()['optional'](),'visibility':z['enum'](['clear',a159_0x199fd4(0x8c)])[a159_0x199fd4(0x9e)]()})]);export const ActivationBehaviorDefSchema=z['object']({'columns':z['array'](z[a159_0x199fd4(0x7f)]({'name':z['string'](),'type':z['string']()[a159_0x199fd4(0x9e)](),'visibility':z[a159_0x199fd4(0x9a)](['clear',a159_0x199fd4(0x8c)])[a159_0x199fd4(0x9e)]()}))[a159_0x199fd4(0x9e)](),'behavior_table':z[a159_0x199fd4(0x8d)]()[a159_0x199fd4(0x9e)](),'join_row':z[a159_0x199fd4(0x98)]()[a159_0x199fd4(0x82)]()['optional'](),'join_strategy':z[a159_0x199fd4(0x9a)]([a159_0x199fd4(0x97),'First',a159_0x199fd4(0x7b),'Top-N'])['optional'](),'formatting':z[a159_0x199fd4(0x9a)]([a159_0x199fd4(0x94),a159_0x199fd4(0x96)])[a159_0x199fd4(0x9e)](),'order_by':z[a159_0x199fd4(0x84)](z[a159_0x199fd4(0x7f)]({'key':z[a159_0x199fd4(0x8d)](),'order':z['enum']([a159_0x199fd4(0x9f),a159_0x199fd4(0x81)])}))[a159_0x199fd4(0x9e)]()});export const ActivationDefSchema=z[a159_0x199fd4(0x7f)]({'name':z[a159_0x199fd4(0x8d)]()[a159_0x199fd4(0x8a)](0x1,a159_0x199fd4(0x8b)),'description':z['string']()[a159_0x199fd4(0x9e)](),'connection':z[a159_0x199fd4(0x8d)]()[a159_0x199fd4(0x8a)](0x1,'Connection\x20name\x20is\x20required'),'all_columns':z[a159_0x199fd4(0x7a)]()[a159_0x199fd4(0x9e)](),'columns':z['array'](ActivationColumnDefSchema)[a159_0x199fd4(0x9e)](),'schedule':ScheduleDefSchema[a159_0x199fd4(0x9e)](),'notification':NotificationDefSchema[a159_0x199fd4(0x9e)](),'connector_config':z[a159_0x199fd4(0x93)](z[a159_0x199fd4(0x8d)](),z['unknown']())[a159_0x199fd4(0x9e)](),'activation_template_id':z[a159_0x199fd4(0x8d)]()[a159_0x199fd4(0x82)]()['optional'](),'behavior':ActivationBehaviorDefSchema[a159_0x199fd4(0x82)]()['optional'](),'run_after_journey_refresh':z[a159_0x199fd4(0x7a)]()[a159_0x199fd4(0x9e)]()});
1
+ const a159_0x1b98eb=a159_0x2acb;(function(_0x34afee,_0x2f7fbd){const _0x8d78e7=a159_0x2acb,_0x400448=_0x34afee();while(!![]){try{const _0x38a668=-parseInt(_0x8d78e7(0xec))/0x1*(-parseInt(_0x8d78e7(0xfd))/0x2)+-parseInt(_0x8d78e7(0x110))/0x3+parseInt(_0x8d78e7(0xf0))/0x4*(-parseInt(_0x8d78e7(0x113))/0x5)+-parseInt(_0x8d78e7(0xfe))/0x6+parseInt(_0x8d78e7(0x106))/0x7+-parseInt(_0x8d78e7(0xfb))/0x8+parseInt(_0x8d78e7(0x103))/0x9;if(_0x38a668===_0x2f7fbd)break;else _0x400448['push'](_0x400448['shift']());}catch(_0xdf9f5c){_0x400448['push'](_0x400448['shift']());}}}(a159_0x2b6e,0x6c326));import{z}from'zod';export const ScheduleTypeSchema=z['enum']([a159_0x1b98eb(0x10a),'hourly','daily',a159_0x1b98eb(0x115),a159_0x1b98eb(0x100),a159_0x1b98eb(0x107),'minutes_interval']);function a159_0x2acb(_0x5bff69,_0x413cb2){_0x5bff69=_0x5bff69-0xec;const _0x2b6ea6=a159_0x2b6e();let _0x2acbd3=_0x2b6ea6[_0x5bff69];return _0x2acbd3;}export const RepeatUnitSchema=z[a159_0x1b98eb(0xee)](['minute',a159_0x1b98eb(0x10c),a159_0x1b98eb(0xed),a159_0x1b98eb(0x10f),a159_0x1b98eb(0xf1),a159_0x1b98eb(0xef),a159_0x1b98eb(0x10a)]);export const ScheduleDefSchema=z[a159_0x1b98eb(0x10e)]({'type':ScheduleTypeSchema[a159_0x1b98eb(0xfa)](),'repeat_unit':RepeatUnitSchema[a159_0x1b98eb(0xfa)](),'repeat_frequency':z[a159_0x1b98eb(0xf4)]()['optional'](),'repeat_sub_frequency':z['array'](z[a159_0x1b98eb(0xf4)]())[a159_0x1b98eb(0xfa)](),'start_at':z[a159_0x1b98eb(0x10b)]()[a159_0x1b98eb(0x111)]()[a159_0x1b98eb(0xfa)](),'end_on':z[a159_0x1b98eb(0x10b)]()[a159_0x1b98eb(0x111)]()[a159_0x1b98eb(0xfa)](),'timezone':z[a159_0x1b98eb(0x10b)]()['optional']()});export const NotificationDefSchema=z[a159_0x1b98eb(0x10e)]({'notify_on':z['array'](z['enum'](['onSuccess','onFailure']))[a159_0x1b98eb(0xfa)](),'email_recipients':z[a159_0x1b98eb(0xf6)](z[a159_0x1b98eb(0x10b)]())[a159_0x1b98eb(0xfa)]()});function a159_0x2b6e(){const _0x200700=['14075658mlksKN','record','First','5219235oduStb','cron','masked','desc','none','string','hour','clear','object','week','2361309mBzrOk','nullable','Activation\x20name\x20is\x20required','2385gCXrLu','All','weekly','498609STzqOR','day','enum','once','6804OvfaWq','month','Connection\x20name\x20is\x20required','Last','number','asc','array','union','rows','Top-N','optional','5560320odZMru','cols','2gUsTIn','428892YUcYvc','min','monthly','boolean','unknown'];a159_0x2b6e=function(){return _0x200700;};return a159_0x2b6e();}export const ActivationColumnDefSchema=z[a159_0x1b98eb(0xf7)]([z[a159_0x1b98eb(0x10b)](),z['object']({'name':z[a159_0x1b98eb(0x10b)](),'type':z['string']()['optional'](),'visibility':z[a159_0x1b98eb(0xee)]([a159_0x1b98eb(0x10d),a159_0x1b98eb(0x108)])[a159_0x1b98eb(0xfa)]()})]);export const ActivationBehaviorDefSchema=z[a159_0x1b98eb(0x10e)]({'columns':z[a159_0x1b98eb(0xf6)](z['object']({'name':z[a159_0x1b98eb(0x10b)](),'type':z[a159_0x1b98eb(0x10b)]()[a159_0x1b98eb(0xfa)](),'visibility':z[a159_0x1b98eb(0xee)]([a159_0x1b98eb(0x10d),a159_0x1b98eb(0x108)])['optional']()}))['optional'](),'behavior_table':z[a159_0x1b98eb(0x10b)]()[a159_0x1b98eb(0xfa)](),'join_row':z[a159_0x1b98eb(0xf4)]()[a159_0x1b98eb(0x111)]()['optional'](),'join_strategy':z[a159_0x1b98eb(0xee)]([a159_0x1b98eb(0x114),a159_0x1b98eb(0x105),a159_0x1b98eb(0xf3),a159_0x1b98eb(0xf9)])[a159_0x1b98eb(0xfa)](),'formatting':z[a159_0x1b98eb(0xee)]([a159_0x1b98eb(0xf8),a159_0x1b98eb(0xfc)])[a159_0x1b98eb(0xfa)](),'order_by':z[a159_0x1b98eb(0xf6)](z[a159_0x1b98eb(0x10e)]({'key':z[a159_0x1b98eb(0x10b)](),'order':z[a159_0x1b98eb(0xee)]([a159_0x1b98eb(0xf5),a159_0x1b98eb(0x109)])}))[a159_0x1b98eb(0xfa)]()});export const ActivationDefSchema=z['object']({'name':z['string']()[a159_0x1b98eb(0xff)](0x1,a159_0x1b98eb(0x112)),'description':z['string']()['optional'](),'connection':z[a159_0x1b98eb(0x10b)]()['min'](0x1,a159_0x1b98eb(0xf2)),'all_columns':z[a159_0x1b98eb(0x101)]()[a159_0x1b98eb(0xfa)](),'columns':z[a159_0x1b98eb(0xf6)](ActivationColumnDefSchema)['optional'](),'schedule':ScheduleDefSchema[a159_0x1b98eb(0xfa)](),'notification':NotificationDefSchema['optional'](),'connector_config':z[a159_0x1b98eb(0x104)](z['string'](),z[a159_0x1b98eb(0x102)]())['optional'](),'activation_template_id':z[a159_0x1b98eb(0x10b)]()[a159_0x1b98eb(0x111)]()[a159_0x1b98eb(0xfa)](),'behavior':ActivationBehaviorDefSchema[a159_0x1b98eb(0x111)]()['optional'](),'run_after_journey_refresh':z[a159_0x1b98eb(0x101)]()['optional']()});
@@ -1 +1 @@
1
- function a160_0x23ac(_0x509eca,_0x56d808){_0x509eca=_0x509eca-0xe2;var _0x5cc40c=a160_0x5cc4();var _0x23ace0=_0x5cc40c[_0x509eca];return _0x23ace0;}(function(_0x3a6ff2,_0x2da5ad){var _0x3290a7=a160_0x23ac,_0x3697fb=_0x3a6ff2();while(!![]){try{var _0x447029=-parseInt(_0x3290a7(0xe9))/0x1+-parseInt(_0x3290a7(0xe8))/0x2+-parseInt(_0x3290a7(0xe2))/0x3+-parseInt(_0x3290a7(0xe7))/0x4+parseInt(_0x3290a7(0xe6))/0x5+-parseInt(_0x3290a7(0xe4))/0x6+-parseInt(_0x3290a7(0xe5))/0x7*(-parseInt(_0x3290a7(0xe3))/0x8);if(_0x447029===_0x2da5ad)break;else _0x3697fb['push'](_0x3697fb['shift']());}catch(_0x509c59){_0x3697fb['push'](_0x3697fb['shift']());}}}(a160_0x5cc4,0xd1453));function a160_0x5cc4(){var _0x5e8b13=['25304MGEeXg','4915602lUufeD','11123aGFlxN','5142365FqQKcl','6756044ODFDwJ','858840xjgtKz','1288037bSxbJF','2914722ZmQfWv'];a160_0x5cc4=function(){return _0x5e8b13;};return a160_0x5cc4();}export{JourneyStateTypeSchema,ReentryModeTypeSchema,WaitUnitTypeSchema,StepTypeValueSchema,EmbeddedSegmentDefSchema,CriteriaDefSchema,StepDefSchema,StageDefSchema,JourneyEntryDefSchema,JourneyDefSchema}from'./journey-schema.js';
1
+ (function(_0x2c0ef0,_0x4821d5){var _0x278e7f=a160_0x39a4,_0x1ab63a=_0x2c0ef0();while(!![]){try{var _0x4edbf8=parseInt(_0x278e7f(0x116))/0x1+-parseInt(_0x278e7f(0x114))/0x2+-parseInt(_0x278e7f(0x112))/0x3*(parseInt(_0x278e7f(0x119))/0x4)+-parseInt(_0x278e7f(0x111))/0x5*(-parseInt(_0x278e7f(0x115))/0x6)+parseInt(_0x278e7f(0x118))/0x7+-parseInt(_0x278e7f(0x113))/0x8+parseInt(_0x278e7f(0x117))/0x9;if(_0x4edbf8===_0x4821d5)break;else _0x1ab63a['push'](_0x1ab63a['shift']());}catch(_0x4e16e5){_0x1ab63a['push'](_0x1ab63a['shift']());}}}(a160_0x55b1,0x5599f));export{JourneyStateTypeSchema,ReentryModeTypeSchema,WaitUnitTypeSchema,StepTypeValueSchema,EmbeddedSegmentDefSchema,CriteriaDefSchema,StepDefSchema,StageDefSchema,JourneyEntryDefSchema,JourneyDefSchema}from'./journey-schema.js';function a160_0x39a4(_0x4fe504,_0x4ac57e){_0x4fe504=_0x4fe504-0x111;var _0x55b140=a160_0x55b1();var _0x39a441=_0x55b140[_0x4fe504];return _0x39a441;}function a160_0x55b1(){var _0x108541=['1970cMgZTZ','15InRvPP','2694776rxLLJb','1293140rKEbVH','3258ednUYH','262284xHjvgZ','3854304enthet','3320191xrWELJ','35804mOZsXT'];a160_0x55b1=function(){return _0x108541;};return a160_0x55b1();}
@@ -1 +1 @@
1
- const a161_0x443ff3=a161_0x18d6;(function(_0x295aa6,_0x550fc8){const _0x4143b9=a161_0x18d6,_0x58c0f8=_0x295aa6();while(!![]){try{const _0x45715d=parseInt(_0x4143b9(0xee))/0x1*(-parseInt(_0x4143b9(0xeb))/0x2)+parseInt(_0x4143b9(0xfa))/0x3+-parseInt(_0x4143b9(0xd7))/0x4*(-parseInt(_0x4143b9(0xe5))/0x5)+parseInt(_0x4143b9(0xf4))/0x6+-parseInt(_0x4143b9(0xef))/0x7*(-parseInt(_0x4143b9(0xe0))/0x8)+-parseInt(_0x4143b9(0xf3))/0x9*(parseInt(_0x4143b9(0xe4))/0xa)+parseInt(_0x4143b9(0xf1))/0xb*(-parseInt(_0x4143b9(0xd6))/0xc);if(_0x45715d===_0x550fc8)break;else _0x58c0f8['push'](_0x58c0f8['shift']());}catch(_0x4556e4){_0x58c0f8['push'](_0x58c0f8['shift']());}}}(a161_0xed09,0x75f53));import{z}from'zod';import{RuleDefSchema}from'./segment-schema.js';import{ActivationDefSchema}from'./activation-schema.js';export const JourneyStateTypeSchema=z[a161_0x443ff3(0xf5)]([a161_0x443ff3(0xd9),a161_0x443ff3(0xde),a161_0x443ff3(0xea)]);function a161_0xed09(){const _0x509627=['object','2110gyTQQE','1345645filoIO','decision_point','ab_test','reentry_always','Journey\x20must\x20have\x20exactly\x20one\x20of:\x20journeys,\x20stages,\x20or\x20versions','launched','727828fBjGxS','journeys','jump','1XTVjpe','2230291rTfjGB','string','11NeNPve','end','21339lAJfMR','5166354JSLdZL','enum','min','stages','Journey\x20name\x20is\x20required','optional','505443wGSvFU','length','activation','versions','type','week','boolean','literal','refine','number','array','6468732jeYazP','8mnFhJm','wait','draft','record','merge','lazy','no_reentry','simulation','passthrough','8EkNeLB','reentry_unless_goal_achieved','journey'];a161_0xed09=function(){return _0x509627;};return a161_0xed09();}export const ReentryModeTypeSchema=z[a161_0x443ff3(0xf5)]([a161_0x443ff3(0xdd),a161_0x443ff3(0xe1),a161_0x443ff3(0xe8)]);export const WaitUnitTypeSchema=z[a161_0x443ff3(0xf5)](['day',a161_0x443ff3(0xd0)]);export const StepTypeValueSchema=z[a161_0x443ff3(0xf5)]([a161_0x443ff3(0xd8),a161_0x443ff3(0xfc),'decision_point',a161_0x443ff3(0xe7),a161_0x443ff3(0xdb),a161_0x443ff3(0xed),a161_0x443ff3(0xf2)]);export const EmbeddedSegmentDefSchema=z['object']({'description':z[a161_0x443ff3(0xf0)]()[a161_0x443ff3(0xf9)](),'rule':RuleDefSchema});const JumpTargetDefSchema=z[a161_0x443ff3(0xe3)]({'journey':z['string'](),'stage':z[a161_0x443ff3(0xf0)](),'bundle_id':z['string']()[a161_0x443ff3(0xf9)]()});export const CriteriaDefSchema=z[a161_0x443ff3(0xe3)]({'name':z['string'](),'description':z[a161_0x443ff3(0xf0)]()[a161_0x443ff3(0xf9)](),'segment':z[a161_0x443ff3(0xf0)](),'target':JumpTargetDefSchema[a161_0x443ff3(0xf9)]()});const WaitConditionTimeoutDefSchema=z[a161_0x443ff3(0xe3)]({'duration':z[a161_0x443ff3(0xd4)](),'unit':WaitUnitTypeSchema,'next':z[a161_0x443ff3(0xf0)]()[a161_0x443ff3(0xf9)]()}),WaitConditionDefSchema=z[a161_0x443ff3(0xe3)]({'segment':z[a161_0x443ff3(0xf0)](),'next':z[a161_0x443ff3(0xf0)]()['optional'](),'timeout':WaitConditionTimeoutDefSchema[a161_0x443ff3(0xf9)]()}),WaitStepParamsDefSchema=z[a161_0x443ff3(0xe3)]({'duration':z[a161_0x443ff3(0xd4)]()[a161_0x443ff3(0xf9)](),'unit':WaitUnitTypeSchema['optional'](),'wait_until':z[a161_0x443ff3(0xf0)]()[a161_0x443ff3(0xf9)](),'condition':WaitConditionDefSchema['optional'](),'days_of_week':z[a161_0x443ff3(0xd5)](z[a161_0x443ff3(0xf0)]())['optional']()}),StepBaseFields={'name':z[a161_0x443ff3(0xf0)](),'uuid':z['string']()[a161_0x443ff3(0xf9)](),'next':z[a161_0x443ff3(0xf0)]()['optional']()},WaitStepDefSchema=z['object']({...StepBaseFields,'type':z['literal']('wait'),'with':WaitStepParamsDefSchema}),ActivationStepParamsDefSchema=z[a161_0x443ff3(0xe3)]({'activation':z[a161_0x443ff3(0xf0)]()}),ActivationStepDefSchema=z[a161_0x443ff3(0xe3)]({...StepBaseFields,'type':z[a161_0x443ff3(0xd2)](a161_0x443ff3(0xfc)),'with':ActivationStepParamsDefSchema}),DecisionBranchDefSchema=z[a161_0x443ff3(0xe3)]({'name':z['string'](),'segment':z['string']()[a161_0x443ff3(0xf9)](),'segment_id':z[a161_0x443ff3(0xf0)]()['optional'](),'excluded':z[a161_0x443ff3(0xd1)]()[a161_0x443ff3(0xf9)](),'next':z[a161_0x443ff3(0xf0)]()[a161_0x443ff3(0xf9)]()}),DecisionPointStepParamsDefSchema=z[a161_0x443ff3(0xe3)]({'branches':z[a161_0x443ff3(0xd5)](DecisionBranchDefSchema)}),DecisionPointStepDefSchema=z['object']({...StepBaseFields,'type':z['literal'](a161_0x443ff3(0xe6)),'with':DecisionPointStepParamsDefSchema}),AbTestVariantDefSchema=z[a161_0x443ff3(0xe3)]({'id':z[a161_0x443ff3(0xf0)]()[a161_0x443ff3(0xf9)](),'name':z['string'](),'percentage':z[a161_0x443ff3(0xd4)](),'next':z[a161_0x443ff3(0xf0)]()['optional']()}),AbTestStepParamsDefSchema=z[a161_0x443ff3(0xe3)]({'variants':z[a161_0x443ff3(0xd5)](AbTestVariantDefSchema),'unique_id':z[a161_0x443ff3(0xf0)]()[a161_0x443ff3(0xf9)](),'customized_split':z[a161_0x443ff3(0xd1)]()[a161_0x443ff3(0xf9)]()}),AbTestStepDefSchema=z[a161_0x443ff3(0xe3)]({...StepBaseFields,'type':z[a161_0x443ff3(0xd2)](a161_0x443ff3(0xe7)),'with':AbTestStepParamsDefSchema}),MergeStepDefSchema=z[a161_0x443ff3(0xe3)]({...StepBaseFields,'type':z[a161_0x443ff3(0xd2)](a161_0x443ff3(0xdb))}),JumpStepParamsDefSchema=z['object']({'target':JumpTargetDefSchema}),JumpStepDefSchema=z[a161_0x443ff3(0xe3)]({...StepBaseFields,'type':z['literal'](a161_0x443ff3(0xed)),'with':JumpStepParamsDefSchema}),EndStepDefSchema=z[a161_0x443ff3(0xe3)]({...StepBaseFields,'type':z[a161_0x443ff3(0xd2)]('end')})[a161_0x443ff3(0xdf)]();function a161_0x18d6(_0x43f76f,_0x23ad9c){_0x43f76f=_0x43f76f-0xd0;const _0xed09a6=a161_0xed09();let _0x18d663=_0xed09a6[_0x43f76f];return _0x18d663;}export const StepDefSchema=z['discriminatedUnion'](a161_0x443ff3(0xfe),[WaitStepDefSchema,ActivationStepDefSchema,DecisionPointStepDefSchema,AbTestStepDefSchema,MergeStepDefSchema,JumpStepDefSchema,EndStepDefSchema]);export const StageDefSchema=z[a161_0x443ff3(0xe3)]({'name':z[a161_0x443ff3(0xf0)](),'description':z['string']()[a161_0x443ff3(0xf9)](),'id':z[a161_0x443ff3(0xf0)]()['optional'](),'entry_criteria':CriteriaDefSchema['optional'](),'exit_criteria':z[a161_0x443ff3(0xd5)](CriteriaDefSchema)['optional'](),'milestone':CriteriaDefSchema['optional'](),'root_step':z[a161_0x443ff3(0xf0)]()['optional'](),'steps':z['array'](StepDefSchema)[a161_0x443ff3(0xf9)]()});export const JourneyEntryDefSchema=z[a161_0x443ff3(0xe3)]({'name':z[a161_0x443ff3(0xf0)]()[a161_0x443ff3(0xf9)](),'version':z[a161_0x443ff3(0xf0)]()[a161_0x443ff3(0xf9)](),'state':JourneyStateTypeSchema[a161_0x443ff3(0xf9)](),'latest':z[a161_0x443ff3(0xd1)]()['optional'](),'stages':z[a161_0x443ff3(0xd5)](StageDefSchema),'id':z['string']()[a161_0x443ff3(0xf9)](),'version_number':z['number']()[a161_0x443ff3(0xf9)](),'goal':CriteriaDefSchema[a161_0x443ff3(0xf9)](),'reentry':ReentryModeTypeSchema[a161_0x443ff3(0xf9)]()});export const JourneyDefSchema=z[a161_0x443ff3(0xdc)](()=>z[a161_0x443ff3(0xe3)]({'type':z['literal'](a161_0x443ff3(0xe2)),'name':z[a161_0x443ff3(0xf0)]()[a161_0x443ff3(0xf6)](0x1,a161_0x443ff3(0xf8)),'description':z[a161_0x443ff3(0xf0)]()[a161_0x443ff3(0xf9)](),'bundle_id':z[a161_0x443ff3(0xf0)]()[a161_0x443ff3(0xf9)](),'bundle_name':z[a161_0x443ff3(0xf0)]()[a161_0x443ff3(0xf9)](),'folder_id':z['string']()[a161_0x443ff3(0xf9)](),'reentry':ReentryModeTypeSchema['optional'](),'allow_reentry':z[a161_0x443ff3(0xd1)]()['optional'](),'goal':CriteriaDefSchema[a161_0x443ff3(0xf9)](),'id':z[a161_0x443ff3(0xf0)]()['optional'](),'version':z[a161_0x443ff3(0xf0)]()[a161_0x443ff3(0xf9)](),'version_number':z[a161_0x443ff3(0xd4)]()[a161_0x443ff3(0xf9)](),'stages':z[a161_0x443ff3(0xd5)](StageDefSchema)[a161_0x443ff3(0xf9)](),'versions':z[a161_0x443ff3(0xd5)](JourneyEntryDefSchema)[a161_0x443ff3(0xf9)](),'journeys':z[a161_0x443ff3(0xd5)](JourneyEntryDefSchema)[a161_0x443ff3(0xf9)](),'segments':z[a161_0x443ff3(0xda)](z[a161_0x443ff3(0xf0)](),EmbeddedSegmentDefSchema)[a161_0x443ff3(0xf9)](),'activations':z[a161_0x443ff3(0xda)](z[a161_0x443ff3(0xf0)](),ActivationDefSchema)[a161_0x443ff3(0xf9)]()})[a161_0x443ff3(0xd3)](_0x162a43=>{const _0x4848a6=a161_0x443ff3,_0x24345a=[_0x162a43[_0x4848a6(0xec)],_0x162a43[_0x4848a6(0xf7)],_0x162a43[_0x4848a6(0xfd)]]['filter'](_0x142535=>Array['isArray'](_0x142535)&&_0x142535[_0x4848a6(0xfb)]>0x0)[_0x4848a6(0xfb)];return _0x24345a===0x1;},{'message':a161_0x443ff3(0xe9)}));const _syncCheck1=!![],_syncCheck2=!![];void _syncCheck1,void _syncCheck2;
1
+ const a161_0x486589=a161_0x5881;(function(_0x1a1fa6,_0x4bf50c){const _0x3dd3bc=a161_0x5881,_0xa568a5=_0x1a1fa6();while(!![]){try{const _0x2ca977=parseInt(_0x3dd3bc(0x110))/0x1+parseInt(_0x3dd3bc(0xfc))/0x2*(parseInt(_0x3dd3bc(0x11d))/0x3)+-parseInt(_0x3dd3bc(0x10e))/0x4*(-parseInt(_0x3dd3bc(0x102))/0x5)+parseInt(_0x3dd3bc(0x111))/0x6*(parseInt(_0x3dd3bc(0x10c))/0x7)+parseInt(_0x3dd3bc(0x11e))/0x8*(-parseInt(_0x3dd3bc(0x11f))/0x9)+parseInt(_0x3dd3bc(0x10a))/0xa+-parseInt(_0x3dd3bc(0x114))/0xb;if(_0x2ca977===_0x4bf50c)break;else _0xa568a5['push'](_0xa568a5['shift']());}catch(_0x4b74b8){_0xa568a5['push'](_0xa568a5['shift']());}}}(a161_0x28d2,0xca001));import{z}from'zod';import{RuleDefSchema}from'./segment-schema.js';function a161_0x28d2(){const _0x5a7318=['min','draft','decision_point','7968985Qrsbuo','launched','boolean','journey','stages','passthrough','enum','literal','7473430oXAIpy','reentry_unless_goal_achieved','14eDPrkD','lazy','4PlJeFY','number','177067pbVqfj','2851746gACwIM','versions','journeys','26699409okrJax','Journey\x20name\x20is\x20required','object','wait','string','reentry_always','Journey\x20must\x20have\x20exactly\x20one\x20of:\x20journeys,\x20stages,\x20or\x20versions','length','no_reentry','39gGQTYa','2044136oOesvs','9MAZMBx','day','jump','end','record','week','optional','array','6360xniOJc','ab_test','discriminatedUnion'];a161_0x28d2=function(){return _0x5a7318;};return a161_0x28d2();}import{ActivationDefSchema}from'./activation-schema.js';export const JourneyStateTypeSchema=z[a161_0x486589(0x108)]([a161_0x486589(0x100),'simulation',a161_0x486589(0x103)]);export const ReentryModeTypeSchema=z[a161_0x486589(0x108)]([a161_0x486589(0x11c),a161_0x486589(0x10b),a161_0x486589(0x119)]);export const WaitUnitTypeSchema=z[a161_0x486589(0x108)]([a161_0x486589(0x120),a161_0x486589(0x124)]);export const StepTypeValueSchema=z[a161_0x486589(0x108)]([a161_0x486589(0x117),'activation',a161_0x486589(0x101),'ab_test','merge',a161_0x486589(0x121),a161_0x486589(0x122)]);export const EmbeddedSegmentDefSchema=z[a161_0x486589(0x116)]({'description':z[a161_0x486589(0x118)]()['optional'](),'rule':RuleDefSchema});const JumpTargetDefSchema=z['object']({'journey':z[a161_0x486589(0x118)](),'stage':z[a161_0x486589(0x118)](),'bundle_id':z[a161_0x486589(0x118)]()[a161_0x486589(0xfa)]()});export const CriteriaDefSchema=z[a161_0x486589(0x116)]({'name':z[a161_0x486589(0x118)](),'description':z[a161_0x486589(0x118)]()[a161_0x486589(0xfa)](),'segment':z[a161_0x486589(0x118)](),'target':JumpTargetDefSchema[a161_0x486589(0xfa)]()});function a161_0x5881(_0x262118,_0xf079f8){_0x262118=_0x262118-0xfa;const _0x28d24f=a161_0x28d2();let _0x5881ee=_0x28d24f[_0x262118];return _0x5881ee;}const WaitConditionTimeoutDefSchema=z[a161_0x486589(0x116)]({'duration':z['number'](),'unit':WaitUnitTypeSchema,'next':z[a161_0x486589(0x118)]()[a161_0x486589(0xfa)]()}),WaitConditionDefSchema=z[a161_0x486589(0x116)]({'segment':z[a161_0x486589(0x118)](),'next':z[a161_0x486589(0x118)]()[a161_0x486589(0xfa)](),'timeout':WaitConditionTimeoutDefSchema['optional']()}),WaitStepParamsDefSchema=z['object']({'duration':z[a161_0x486589(0x10f)]()[a161_0x486589(0xfa)](),'unit':WaitUnitTypeSchema[a161_0x486589(0xfa)](),'wait_until':z[a161_0x486589(0x118)]()['optional'](),'condition':WaitConditionDefSchema['optional'](),'days_of_week':z['array'](z['string']())[a161_0x486589(0xfa)]()}),StepBaseFields={'name':z['string'](),'uuid':z[a161_0x486589(0x118)]()[a161_0x486589(0xfa)](),'next':z['string']()[a161_0x486589(0xfa)]()},WaitStepDefSchema=z[a161_0x486589(0x116)]({...StepBaseFields,'type':z[a161_0x486589(0x109)]('wait'),'with':WaitStepParamsDefSchema}),ActivationStepParamsDefSchema=z[a161_0x486589(0x116)]({'activation':z['string']()}),ActivationStepDefSchema=z['object']({...StepBaseFields,'type':z[a161_0x486589(0x109)]('activation'),'with':ActivationStepParamsDefSchema}),DecisionBranchDefSchema=z['object']({'name':z[a161_0x486589(0x118)](),'segment':z[a161_0x486589(0x118)]()[a161_0x486589(0xfa)](),'segment_id':z[a161_0x486589(0x118)]()[a161_0x486589(0xfa)](),'excluded':z[a161_0x486589(0x104)]()['optional'](),'next':z[a161_0x486589(0x118)]()[a161_0x486589(0xfa)]()}),DecisionPointStepParamsDefSchema=z[a161_0x486589(0x116)]({'branches':z[a161_0x486589(0xfb)](DecisionBranchDefSchema)}),DecisionPointStepDefSchema=z['object']({...StepBaseFields,'type':z[a161_0x486589(0x109)](a161_0x486589(0x101)),'with':DecisionPointStepParamsDefSchema}),AbTestVariantDefSchema=z[a161_0x486589(0x116)]({'id':z[a161_0x486589(0x118)]()[a161_0x486589(0xfa)](),'name':z[a161_0x486589(0x118)](),'percentage':z[a161_0x486589(0x10f)](),'next':z['string']()['optional']()}),AbTestStepParamsDefSchema=z[a161_0x486589(0x116)]({'variants':z[a161_0x486589(0xfb)](AbTestVariantDefSchema),'unique_id':z['string']()[a161_0x486589(0xfa)](),'customized_split':z[a161_0x486589(0x104)]()[a161_0x486589(0xfa)]()}),AbTestStepDefSchema=z['object']({...StepBaseFields,'type':z[a161_0x486589(0x109)](a161_0x486589(0xfd)),'with':AbTestStepParamsDefSchema}),MergeStepDefSchema=z[a161_0x486589(0x116)]({...StepBaseFields,'type':z[a161_0x486589(0x109)]('merge')}),JumpStepParamsDefSchema=z[a161_0x486589(0x116)]({'target':JumpTargetDefSchema}),JumpStepDefSchema=z[a161_0x486589(0x116)]({...StepBaseFields,'type':z[a161_0x486589(0x109)](a161_0x486589(0x121)),'with':JumpStepParamsDefSchema}),EndStepDefSchema=z['object']({...StepBaseFields,'type':z[a161_0x486589(0x109)]('end')})[a161_0x486589(0x107)]();export const StepDefSchema=z[a161_0x486589(0xfe)]('type',[WaitStepDefSchema,ActivationStepDefSchema,DecisionPointStepDefSchema,AbTestStepDefSchema,MergeStepDefSchema,JumpStepDefSchema,EndStepDefSchema]);export const StageDefSchema=z[a161_0x486589(0x116)]({'name':z['string'](),'description':z[a161_0x486589(0x118)]()[a161_0x486589(0xfa)](),'id':z[a161_0x486589(0x118)]()[a161_0x486589(0xfa)](),'entry_criteria':CriteriaDefSchema['optional'](),'exit_criteria':z[a161_0x486589(0xfb)](CriteriaDefSchema)[a161_0x486589(0xfa)](),'milestone':CriteriaDefSchema[a161_0x486589(0xfa)](),'root_step':z['string']()[a161_0x486589(0xfa)](),'steps':z[a161_0x486589(0xfb)](StepDefSchema)[a161_0x486589(0xfa)]()});export const JourneyEntryDefSchema=z[a161_0x486589(0x116)]({'name':z[a161_0x486589(0x118)]()[a161_0x486589(0xfa)](),'version':z['string']()['optional'](),'state':JourneyStateTypeSchema[a161_0x486589(0xfa)](),'latest':z['boolean']()[a161_0x486589(0xfa)](),'stages':z[a161_0x486589(0xfb)](StageDefSchema),'id':z[a161_0x486589(0x118)]()[a161_0x486589(0xfa)](),'version_number':z[a161_0x486589(0x10f)]()[a161_0x486589(0xfa)](),'goal':CriteriaDefSchema[a161_0x486589(0xfa)](),'reentry':ReentryModeTypeSchema[a161_0x486589(0xfa)]()});export const JourneyDefSchema=z[a161_0x486589(0x10d)](()=>z['object']({'type':z[a161_0x486589(0x109)](a161_0x486589(0x105)),'name':z[a161_0x486589(0x118)]()[a161_0x486589(0xff)](0x1,a161_0x486589(0x115)),'description':z[a161_0x486589(0x118)]()[a161_0x486589(0xfa)](),'bundle_id':z[a161_0x486589(0x118)]()[a161_0x486589(0xfa)](),'bundle_name':z[a161_0x486589(0x118)]()[a161_0x486589(0xfa)](),'folder_id':z['string']()[a161_0x486589(0xfa)](),'reentry':ReentryModeTypeSchema[a161_0x486589(0xfa)](),'allow_reentry':z[a161_0x486589(0x104)]()[a161_0x486589(0xfa)](),'goal':CriteriaDefSchema[a161_0x486589(0xfa)](),'id':z['string']()[a161_0x486589(0xfa)](),'version':z[a161_0x486589(0x118)]()[a161_0x486589(0xfa)](),'version_number':z[a161_0x486589(0x10f)]()['optional'](),'stages':z[a161_0x486589(0xfb)](StageDefSchema)[a161_0x486589(0xfa)](),'versions':z[a161_0x486589(0xfb)](JourneyEntryDefSchema)[a161_0x486589(0xfa)](),'journeys':z[a161_0x486589(0xfb)](JourneyEntryDefSchema)[a161_0x486589(0xfa)](),'segments':z[a161_0x486589(0x123)](z[a161_0x486589(0x118)](),EmbeddedSegmentDefSchema)['optional'](),'activations':z[a161_0x486589(0x123)](z[a161_0x486589(0x118)](),ActivationDefSchema)['optional']()})['refine'](_0x5af98c=>{const _0xbc52e=a161_0x486589,_0x3d5075=[_0x5af98c[_0xbc52e(0x113)],_0x5af98c[_0xbc52e(0x106)],_0x5af98c[_0xbc52e(0x112)]]['filter'](_0x3efbde=>Array['isArray'](_0x3efbde)&&_0x3efbde[_0xbc52e(0x11b)]>0x0)[_0xbc52e(0x11b)];return _0x3d5075===0x1;},{'message':a161_0x486589(0x11a)}));const _syncCheck1=!![],_syncCheck2=!![];void _syncCheck1,void _syncCheck2;
@@ -1 +1 @@
1
- function a163_0x5826(){var _0x5ef89a=['4104198oHFbiQ','36435HXrxsV','1208ectJzO','144057UPoXSj','6nAfOBg','3207280rvbFhq','2279100VkFyDw','728NxtGRT','9754190yiGaQj','12186kqTwoo'];a163_0x5826=function(){return _0x5ef89a;};return a163_0x5826();}(function(_0x397ad7,_0x5e8591){var _0xd7f746=a163_0x24e6,_0x1fc3d1=_0x397ad7();while(!![]){try{var _0x2caa47=parseInt(_0xd7f746(0xb7))/0x1*(parseInt(_0xd7f746(0xb8))/0x2)+-parseInt(_0xd7f746(0xbd))/0x3*(-parseInt(_0xd7f746(0xb6))/0x4)+parseInt(_0xd7f746(0xb9))/0x5+parseInt(_0xd7f746(0xba))/0x6+parseInt(_0xd7f746(0xbf))/0x7*(-parseInt(_0xd7f746(0xbb))/0x8)+-parseInt(_0xd7f746(0xbe))/0x9+-parseInt(_0xd7f746(0xbc))/0xa;if(_0x2caa47===_0x5e8591)break;else _0x1fc3d1['push'](_0x1fc3d1['shift']());}catch(_0x3961f9){_0x1fc3d1['push'](_0x1fc3d1['shift']());}}}(a163_0x5826,0xbd3c1));function a163_0x24e6(_0x4ddfc5,_0x4be9c2){_0x4ddfc5=_0x4ddfc5-0xb6;var _0x582651=a163_0x5826();var _0x24e698=_0x582651[_0x4ddfc5];return _0x24e698;}export{OperatorTypeSchema,TimeUnitSchema,AggregationTypeSchema,ArrayMatchingSchema,OperatorDefSchema,AggregationDefSchema,TimeWindowDefSchema,FilterColumnConditionDefSchema,FilterRuleDefSchema,ValueConditionDefSchema,BehaviorConditionDefSchema,ColumnConditionDefSchema,CompositeConditionDefSchema,SegmentRefConditionDefSchema,ConditionDefSchema,RuleDefSchema,SegmentDefSchema}from'./segment-schema.js';export{ScheduleTypeSchema,RepeatUnitSchema,ScheduleDefSchema,NotificationDefSchema,ActivationColumnDefSchema,ActivationBehaviorDefSchema,ActivationDefSchema}from'./activation-schema.js';
1
+ (function(_0x297377,_0x533e9e){var _0x44c9b0=a163_0x232e,_0x4c8761=_0x297377();while(!![]){try{var _0x5a0cf9=parseInt(_0x44c9b0(0x10a))/0x1+parseInt(_0x44c9b0(0x112))/0x2*(parseInt(_0x44c9b0(0x109))/0x3)+-parseInt(_0x44c9b0(0x10c))/0x4*(-parseInt(_0x44c9b0(0x110))/0x5)+parseInt(_0x44c9b0(0x10f))/0x6+-parseInt(_0x44c9b0(0x10b))/0x7+-parseInt(_0x44c9b0(0x111))/0x8*(-parseInt(_0x44c9b0(0x108))/0x9)+parseInt(_0x44c9b0(0x10e))/0xa*(-parseInt(_0x44c9b0(0x10d))/0xb);if(_0x5a0cf9===_0x533e9e)break;else _0x4c8761['push'](_0x4c8761['shift']());}catch(_0x45f127){_0x4c8761['push'](_0x4c8761['shift']());}}}(a163_0x45e7,0xcbd29));function a163_0x232e(_0x3ca752,_0x15d002){_0x3ca752=_0x3ca752-0x108;var _0x45e763=a163_0x45e7();var _0x232ec2=_0x45e763[_0x3ca752];return _0x232ec2;}export{OperatorTypeSchema,TimeUnitSchema,AggregationTypeSchema,ArrayMatchingSchema,OperatorDefSchema,AggregationDefSchema,TimeWindowDefSchema,FilterColumnConditionDefSchema,FilterRuleDefSchema,ValueConditionDefSchema,BehaviorConditionDefSchema,ColumnConditionDefSchema,CompositeConditionDefSchema,SegmentRefConditionDefSchema,ConditionDefSchema,RuleDefSchema,SegmentDefSchema}from'./segment-schema.js';export{ScheduleTypeSchema,RepeatUnitSchema,ScheduleDefSchema,NotificationDefSchema,ActivationColumnDefSchema,ActivationBehaviorDefSchema,ActivationDefSchema}from'./activation-schema.js';function a163_0x45e7(){var _0x5edd85=['37485XWuTvO','278163KdJMKT','974327aVWMsN','10522974TcJcKV','470908uedUdG','11zTnfGx','21057620twJZCn','9697278tPObSb','10UqpqkS','80vndWaB','34FYpeCB'];a163_0x45e7=function(){return _0x5edd85;};return a163_0x45e7();}
@@ -1 +1 @@
1
- const a164_0x373ae2=a164_0x3add;function a164_0x3647(){const _0x2428ff=['TimeRange\x20operator\x20requires\x20\x27duration\x27','6652WaHySv','Regexp','from','minute','Max','Segment\x20name\x20is\x20required','include','MISSING_BETWEEN_BOUNDS','operator','has','LessEqual','value','Min','EndWith','number','duration','lazy','Timestamp\x20column\x20only\x20supports\x20TimeWithinPast,\x20TimeWithinNext,\x20or\x20TimeRange\x20operators\x20(got\x20\x27','Last','TimeRange','addIssue','realtime','Column','TimeWithinPast','second','CountDistinct','Count','union','2991816KcAEIQ','record','250NGvUbU','literal','StartWith','unit','2611oMhtiM','max','TimeWithinNext','batch','string','min','1828719XcvuUN','5694500ZXbhzQ','object','Greater','enum','GreaterEqual','hour','superRefine','Between\x20operator\x20requires\x20\x27min\x27\x20and/or\x20\x27max\x27\x20values','Behavior','First','column','Less','4AtYKwZ','optional','week','And','Between','Equal','313401nUUNqt','all','7385180JFIoVo','Contain','exclude','timestamp','\x27\x20requires\x20a\x20value','boolean','7206KaSDlT','TimeRange\x20operator\x20requires\x20\x27from\x27','9rLzPHc','Average','Operator\x20\x27','Sum','custom','type','array','discriminatedUnion','Value','funnel_stage'];a164_0x3647=function(){return _0x2428ff;};return a164_0x3647();}(function(_0x46c50e,_0x2c6645){const _0x973909=a164_0x3add,_0x3deb4d=_0x46c50e();while(!![]){try{const _0x1907b0=parseInt(_0x973909(0xdb))/0x1*(parseInt(_0x973909(0xd5))/0x2)+-parseInt(_0x973909(0xc8))/0x3+parseInt(_0x973909(0xf0))/0x4*(-parseInt(_0x973909(0x10e))/0x5)+-parseInt(_0x973909(0xe3))/0x6*(parseInt(_0x973909(0x112))/0x7)+-parseInt(_0x973909(0x10c))/0x8*(parseInt(_0x973909(0xe5))/0x9)+parseInt(_0x973909(0xc9))/0xa+parseInt(_0x973909(0xdd))/0xb;if(_0x1907b0===_0x2c6645)break;else _0x3deb4d['push'](_0x3deb4d['shift']());}catch(_0x383416){_0x3deb4d['push'](_0x3deb4d['shift']());}}}(a164_0x3647,0x562bf));import{z}from'zod';export const OperatorTypeSchema=z[a164_0x373ae2(0xcc)](['Equal',a164_0x373ae2(0xcb),'Less',a164_0x373ae2(0xcd),a164_0x373ae2(0xfa),'In',a164_0x373ae2(0xd9),a164_0x373ae2(0xf1),'IsNull',a164_0x373ae2(0x107),'TimeWithinNext',a164_0x373ae2(0xde),a164_0x373ae2(0x110),a164_0x373ae2(0xfd),a164_0x373ae2(0x103)]);export const TimeUnitSchema=z[a164_0x373ae2(0xcc)]([a164_0x373ae2(0x108),a164_0x373ae2(0xf3),a164_0x373ae2(0xce),'day',a164_0x373ae2(0xd7),'month','year']);export const AggregationTypeSchema=z[a164_0x373ae2(0xcc)]([a164_0x373ae2(0x10a),'Sum',a164_0x373ae2(0xe6),a164_0x373ae2(0xfc),a164_0x373ae2(0xf4),a164_0x373ae2(0x109),a164_0x373ae2(0xd2),'Last']);const TemporalValueSchema=z[a164_0x373ae2(0x10b)]([z[a164_0x373ae2(0xca)]({'timestamp':z['string']()}),z[a164_0x373ae2(0xca)]({'last':z[a164_0x373ae2(0x10b)]([z[a164_0x373ae2(0xfe)](),z[a164_0x373ae2(0x10d)](z['string'](),z[a164_0x373ae2(0xfe)]())]),'unit':z['string']()})]),OperatorValueSchema=z[a164_0x373ae2(0x10b)]([z[a164_0x373ae2(0x116)](),z[a164_0x373ae2(0xfe)](),z[a164_0x373ae2(0xe2)](),TemporalValueSchema,z[a164_0x373ae2(0xeb)](z['union']([z[a164_0x373ae2(0x116)](),z[a164_0x373ae2(0xfe)](),z['boolean']()]))]),OPERATORS_REQUIRING_VALUE=new Set([a164_0x373ae2(0xda),'Greater',a164_0x373ae2(0xcd),a164_0x373ae2(0xd4),'LessEqual','In',a164_0x373ae2(0xde),a164_0x373ae2(0x110),'EndWith',a164_0x373ae2(0xf1),a164_0x373ae2(0x107),a164_0x373ae2(0x114)]),OPERATORS_REQUIRING_UNIT=new Set(['TimeWithinPast','TimeWithinNext']);export const OperatorDefSchema=z['object']({'type':OperatorTypeSchema,'not':z['boolean']()[a164_0x373ae2(0xd6)](),'value':OperatorValueSchema[a164_0x373ae2(0xd6)](),'min':z[a164_0x373ae2(0x10b)]([z[a164_0x373ae2(0xfe)](),z['string'](),TemporalValueSchema])[a164_0x373ae2(0xd6)](),'max':z[a164_0x373ae2(0x10b)]([z[a164_0x373ae2(0xfe)](),z['string'](),TemporalValueSchema])[a164_0x373ae2(0xd6)](),'unit':TimeUnitSchema[a164_0x373ae2(0xd6)](),'duration':z['object']({'day':z[a164_0x373ae2(0xfe)]()['optional'](),'week':z['number']()['optional'](),'month':z['number']()[a164_0x373ae2(0xd6)](),'year':z['number']()[a164_0x373ae2(0xd6)](),'hour':z[a164_0x373ae2(0xfe)]()[a164_0x373ae2(0xd6)](),'minute':z['number']()['optional'](),'second':z[a164_0x373ae2(0xfe)]()[a164_0x373ae2(0xd6)]()})['optional'](),'from':z[a164_0x373ae2(0xca)]({'last':z[a164_0x373ae2(0x10b)]([z[a164_0x373ae2(0xfe)](),z[a164_0x373ae2(0x116)]()]),'unit':TimeUnitSchema})[a164_0x373ae2(0xd6)](),'reverse':z['boolean']()[a164_0x373ae2(0xd6)]()})[a164_0x373ae2(0xcf)]((_0x18e5b5,_0xb16dbe)=>{const _0x1ae304=a164_0x373ae2;OPERATORS_REQUIRING_VALUE[_0x1ae304(0xf9)](_0x18e5b5['type'])&&(_0x18e5b5[_0x1ae304(0xfb)]===undefined||_0x18e5b5['value']===null)&&_0xb16dbe[_0x1ae304(0x104)]({'code':'custom','message':'Operator\x20\x27'+_0x18e5b5[_0x1ae304(0xea)]+_0x1ae304(0xe1),'path':['value']}),_0x18e5b5['type']===_0x1ae304(0xd9)&&_0x18e5b5[_0x1ae304(0xc7)]===undefined&&_0x18e5b5[_0x1ae304(0x113)]===undefined&&_0xb16dbe['addIssue']({'code':_0x1ae304(0xe9),'message':_0x1ae304(0xd0),'params':{'validationCode':_0x1ae304(0xf7)}}),OPERATORS_REQUIRING_UNIT['has'](_0x18e5b5[_0x1ae304(0xea)])&&_0x18e5b5[_0x1ae304(0xfb)]!==undefined&&!_0x18e5b5[_0x1ae304(0x111)]&&_0xb16dbe[_0x1ae304(0x104)]({'code':_0x1ae304(0xe9),'message':'Operator\x20\x27'+_0x18e5b5[_0x1ae304(0xea)]+'\x27\x20requires\x20a\x20time\x20unit','path':[_0x1ae304(0x111)],'params':{'validationCode':'MISSING_TIME_UNIT'}}),_0x18e5b5[_0x1ae304(0xea)]===_0x1ae304(0x103)&&(!_0x18e5b5['duration']&&_0xb16dbe['addIssue']({'code':_0x1ae304(0xe9),'message':_0x1ae304(0xef),'path':[_0x1ae304(0xff)]}),!_0x18e5b5[_0x1ae304(0xf2)]&&_0xb16dbe[_0x1ae304(0x104)]({'code':_0x1ae304(0xe9),'message':_0x1ae304(0xe4),'path':[_0x1ae304(0xf2)]}));});export const ArrayMatchingSchema=z[a164_0x373ae2(0x10b)]([z['literal']('any'),z[a164_0x373ae2(0x10f)](a164_0x373ae2(0xdc)),z[a164_0x373ae2(0xca)]({'atLeast':z['number']()}),z[a164_0x373ae2(0xca)]({'atMost':z['number']()}),z[a164_0x373ae2(0xca)]({'exactly':z[a164_0x373ae2(0xfe)]()})]);export const AggregationDefSchema=z[a164_0x373ae2(0xec)]('type',[z[a164_0x373ae2(0xca)]({'type':z[a164_0x373ae2(0xcc)]([a164_0x373ae2(0xe8),'Min',a164_0x373ae2(0xf4),a164_0x373ae2(0xe6)]),'column':z['string'](),'groupingColumns':z[a164_0x373ae2(0xeb)](z[a164_0x373ae2(0x116)]())[a164_0x373ae2(0xd6)]()}),z[a164_0x373ae2(0xca)]({'type':z[a164_0x373ae2(0x10f)]('Count'),'groupingColumns':z[a164_0x373ae2(0xeb)](z[a164_0x373ae2(0x116)]())[a164_0x373ae2(0xd6)]()}),z['object']({'type':z[a164_0x373ae2(0x10f)](a164_0x373ae2(0x109)),'columns':z['array'](z[a164_0x373ae2(0x116)]())}),z[a164_0x373ae2(0xca)]({'type':z[a164_0x373ae2(0xcc)]([a164_0x373ae2(0xd2),a164_0x373ae2(0x102)]),'column':z[a164_0x373ae2(0x116)](),'orderColumn':z[a164_0x373ae2(0x116)](),'groupingColumns':z['array'](z[a164_0x373ae2(0x116)]())[a164_0x373ae2(0xd6)]()})]);export const TimeWindowDefSchema=z[a164_0x373ae2(0xca)]({'duration':z['number'](),'unit':TimeUnitSchema});const TIMESTAMP_OPERATORS=new Set(['TimeWithinPast',a164_0x373ae2(0x114),a164_0x373ae2(0x103)]);export const FilterColumnConditionDefSchema=z['object']({'type':z[a164_0x373ae2(0x10f)](a164_0x373ae2(0x106)),'column':z[a164_0x373ae2(0x116)](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema[a164_0x373ae2(0xd6)]()})['superRefine']((_0x606967,_0xb96e35)=>{const _0x2bbc90=a164_0x373ae2,_0x48f0f0=_0x606967['operator'][_0x2bbc90(0xea)];_0x606967[_0x2bbc90(0xd3)]===_0x2bbc90(0xe0)?!TIMESTAMP_OPERATORS[_0x2bbc90(0xf9)](_0x48f0f0)&&_0xb96e35[_0x2bbc90(0x104)]({'code':_0x2bbc90(0xe9),'message':_0x2bbc90(0x101)+_0x48f0f0+'\x27)','path':[_0x2bbc90(0xf8),'type']}):TIMESTAMP_OPERATORS[_0x2bbc90(0xf9)](_0x48f0f0)&&_0xb96e35[_0x2bbc90(0x104)]({'code':_0x2bbc90(0xe9),'message':_0x2bbc90(0xe7)+_0x48f0f0+'\x27\x20is\x20only\x20valid\x20for\x20the\x20\x27timestamp\x27\x20column','path':[_0x2bbc90(0xf8),_0x2bbc90(0xea)]});});export const FilterRuleDefSchema=z['object']({'type':z[a164_0x373ae2(0x10f)]('And'),'conditions':z['array'](FilterColumnConditionDefSchema)});export const ValueConditionDefSchema=z[a164_0x373ae2(0x100)](()=>z[a164_0x373ae2(0xca)]({'type':z[a164_0x373ae2(0x10f)](a164_0x373ae2(0xed)),'attribute':z[a164_0x373ae2(0x116)](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema[a164_0x373ae2(0xd6)](),'exclude':z['boolean']()['optional'](),'aggregation':AggregationDefSchema[a164_0x373ae2(0xd6)](),'source':z['string']()[a164_0x373ae2(0xd6)](),'filter':FilterRuleDefSchema[a164_0x373ae2(0xd6)](),'limit':z[a164_0x373ae2(0xfe)]()[a164_0x373ae2(0xd6)]()}));export const BehaviorConditionDefSchema=z[a164_0x373ae2(0x100)](()=>z[a164_0x373ae2(0xca)]({'type':z[a164_0x373ae2(0x10f)](a164_0x373ae2(0xd1)),'attribute':z[a164_0x373ae2(0x116)](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema[a164_0x373ae2(0xd6)](),'exclude':z['boolean']()['optional'](),'aggregation':AggregationDefSchema[a164_0x373ae2(0xd6)](),'source':z[a164_0x373ae2(0x116)]()[a164_0x373ae2(0xd6)](),'filter':FilterRuleDefSchema[a164_0x373ae2(0xd6)](),'timeWindow':TimeWindowDefSchema['optional'](),'limit':z[a164_0x373ae2(0xfe)]()[a164_0x373ae2(0xd6)]()}));export const ColumnConditionDefSchema=z['object']({'type':z[a164_0x373ae2(0x10f)]('Column'),'column':z[a164_0x373ae2(0x116)](),'operator':OperatorDefSchema});export const CompositeConditionDefSchema=z[a164_0x373ae2(0x100)](()=>z[a164_0x373ae2(0xca)]({'type':z['enum']([a164_0x373ae2(0xd8),'Or']),'conditions':z[a164_0x373ae2(0xeb)](ConditionDefSchema),'description':z[a164_0x373ae2(0x116)]()[a164_0x373ae2(0xd6)]()}));function a164_0x3add(_0x46cf7b,_0x15b43b){_0x46cf7b=_0x46cf7b-0xc7;const _0x364734=a164_0x3647();let _0x3add3b=_0x364734[_0x46cf7b];return _0x3add3b;}export const SegmentRefConditionDefSchema=z[a164_0x373ae2(0xca)]({'type':z[a164_0x373ae2(0xcc)]([a164_0x373ae2(0xf6),a164_0x373ae2(0xdf)]),'segment':z[a164_0x373ae2(0x116)]()['min'](0x1,'Segment\x20reference\x20must\x20not\x20be\x20empty')});export const ConditionDefSchema=z[a164_0x373ae2(0x100)](()=>z[a164_0x373ae2(0x10b)]([ValueConditionDefSchema,BehaviorConditionDefSchema,ColumnConditionDefSchema,CompositeConditionDefSchema,SegmentRefConditionDefSchema]));export const RuleDefSchema=z[a164_0x373ae2(0x100)](()=>z[a164_0x373ae2(0xca)]({'type':z[a164_0x373ae2(0xcc)](['And','Or']),'conditions':z[a164_0x373ae2(0xeb)](ConditionDefSchema),'description':z['string']()['optional']()}));export const SegmentDefSchema=z[a164_0x373ae2(0xca)]({'type':z['literal']('segment')['optional'](),'name':z['string']()['min'](0x1,a164_0x373ae2(0xf5)),'description':z[a164_0x373ae2(0x116)]()[a164_0x373ae2(0xd6)](),'folder':z[a164_0x373ae2(0x116)]()[a164_0x373ae2(0xd6)](),'rule':RuleDefSchema[a164_0x373ae2(0xd6)](),'kind':z[a164_0x373ae2(0xcc)]([a164_0x373ae2(0x115),a164_0x373ae2(0x105),a164_0x373ae2(0xee)])[a164_0x373ae2(0xd6)](),'visible':z[a164_0x373ae2(0xe2)]()['optional'](),'activations':z['array'](z['any']())['optional']()});const _syncCheck1=!![],_syncCheck2=!![];void _syncCheck1,void _syncCheck2;
1
+ const a164_0x32a8b7=a164_0x4403;(function(_0x2b3d27,_0x34b791){const _0x5d8a5d=a164_0x4403,_0x2c17f7=_0x2b3d27();while(!![]){try{const _0x3883c3=-parseInt(_0x5d8a5d(0xc0))/0x1+-parseInt(_0x5d8a5d(0x9f))/0x2+-parseInt(_0x5d8a5d(0xbf))/0x3+parseInt(_0x5d8a5d(0xa3))/0x4*(parseInt(_0x5d8a5d(0xd7))/0x5)+parseInt(_0x5d8a5d(0xd2))/0x6+-parseInt(_0x5d8a5d(0xa6))/0x7*(-parseInt(_0x5d8a5d(0xca))/0x8)+parseInt(_0x5d8a5d(0x9b))/0x9*(-parseInt(_0x5d8a5d(0x97))/0xa);if(_0x3883c3===_0x34b791)break;else _0x2c17f7['push'](_0x2c17f7['shift']());}catch(_0x50e5a7){_0x2c17f7['push'](_0x2c17f7['shift']());}}}(a164_0x4a14,0xba4d3));import{z}from'zod';export const OperatorTypeSchema=z[a164_0x32a8b7(0xdd)]([a164_0x32a8b7(0xc3),a164_0x32a8b7(0xdc),a164_0x32a8b7(0xa0),a164_0x32a8b7(0xa9),a164_0x32a8b7(0xd8),'In','Between',a164_0x32a8b7(0xba),a164_0x32a8b7(0x92),a164_0x32a8b7(0xbc),a164_0x32a8b7(0xb6),a164_0x32a8b7(0xb7),a164_0x32a8b7(0x93),a164_0x32a8b7(0xb3),a164_0x32a8b7(0xce)]);export const TimeUnitSchema=z[a164_0x32a8b7(0xdd)](['second',a164_0x32a8b7(0xb9),a164_0x32a8b7(0xda),'day','week',a164_0x32a8b7(0x96),a164_0x32a8b7(0xa8)]);export const AggregationTypeSchema=z[a164_0x32a8b7(0xdd)]([a164_0x32a8b7(0xab),'Sum','Average',a164_0x32a8b7(0xae),'Max','CountDistinct',a164_0x32a8b7(0x98),a164_0x32a8b7(0xd3)]);function a164_0x4403(_0x460c57,_0x55588c){_0x460c57=_0x460c57-0x8f;const _0x4a145b=a164_0x4a14();let _0x440325=_0x4a145b[_0x460c57];return _0x440325;}const TemporalValueSchema=z[a164_0x32a8b7(0xa2)]([z[a164_0x32a8b7(0xcd)]({'timestamp':z[a164_0x32a8b7(0x95)]()}),z[a164_0x32a8b7(0xcd)]({'last':z['union']([z[a164_0x32a8b7(0xc2)](),z[a164_0x32a8b7(0xb4)](z[a164_0x32a8b7(0x95)](),z[a164_0x32a8b7(0xc2)]())]),'unit':z[a164_0x32a8b7(0x95)]()})]),OperatorValueSchema=z[a164_0x32a8b7(0xa2)]([z[a164_0x32a8b7(0x95)](),z['number'](),z[a164_0x32a8b7(0xd6)](),TemporalValueSchema,z[a164_0x32a8b7(0x99)](z[a164_0x32a8b7(0xa2)]([z[a164_0x32a8b7(0x95)](),z[a164_0x32a8b7(0xc2)](),z['boolean']()]))]),OPERATORS_REQUIRING_VALUE=new Set([a164_0x32a8b7(0xc3),'Greater',a164_0x32a8b7(0xa9),'Less',a164_0x32a8b7(0xd8),'In',a164_0x32a8b7(0xb7),a164_0x32a8b7(0x93),'EndWith',a164_0x32a8b7(0xba),'TimeWithinPast',a164_0x32a8b7(0xb6)]),OPERATORS_REQUIRING_UNIT=new Set([a164_0x32a8b7(0xbc),a164_0x32a8b7(0xb6)]);export const OperatorDefSchema=z[a164_0x32a8b7(0xcd)]({'type':OperatorTypeSchema,'not':z[a164_0x32a8b7(0xd6)]()['optional'](),'value':OperatorValueSchema[a164_0x32a8b7(0xbb)](),'min':z[a164_0x32a8b7(0xa2)]([z[a164_0x32a8b7(0xc2)](),z[a164_0x32a8b7(0x95)](),TemporalValueSchema])[a164_0x32a8b7(0xbb)](),'max':z[a164_0x32a8b7(0xa2)]([z[a164_0x32a8b7(0xc2)](),z[a164_0x32a8b7(0x95)](),TemporalValueSchema])[a164_0x32a8b7(0xbb)](),'unit':TimeUnitSchema[a164_0x32a8b7(0xbb)](),'duration':z['object']({'day':z['number']()[a164_0x32a8b7(0xbb)](),'week':z['number']()['optional'](),'month':z['number']()['optional'](),'year':z[a164_0x32a8b7(0xc2)]()[a164_0x32a8b7(0xbb)](),'hour':z['number']()[a164_0x32a8b7(0xbb)](),'minute':z[a164_0x32a8b7(0xc2)]()[a164_0x32a8b7(0xbb)](),'second':z[a164_0x32a8b7(0xc2)]()['optional']()})[a164_0x32a8b7(0xbb)](),'from':z[a164_0x32a8b7(0xcd)]({'last':z[a164_0x32a8b7(0xa2)]([z[a164_0x32a8b7(0xc2)](),z['string']()]),'unit':TimeUnitSchema})[a164_0x32a8b7(0xbb)](),'reverse':z[a164_0x32a8b7(0xd6)]()['optional']()})[a164_0x32a8b7(0xcc)]((_0x4b2452,_0x59bb08)=>{const _0xd052df=a164_0x32a8b7;OPERATORS_REQUIRING_VALUE['has'](_0x4b2452[_0xd052df(0xa4)])&&(_0x4b2452['value']===undefined||_0x4b2452[_0xd052df(0xc5)]===null)&&_0x59bb08['addIssue']({'code':_0xd052df(0xc6),'message':_0xd052df(0xd9)+_0x4b2452[_0xd052df(0xa4)]+_0xd052df(0xbe),'path':[_0xd052df(0xc5)]}),_0x4b2452[_0xd052df(0xa4)]===_0xd052df(0xac)&&_0x4b2452[_0xd052df(0xd4)]===undefined&&_0x4b2452[_0xd052df(0xc1)]===undefined&&_0x59bb08[_0xd052df(0x91)]({'code':'custom','message':'Between\x20operator\x20requires\x20\x27min\x27\x20and/or\x20\x27max\x27\x20values','params':{'validationCode':_0xd052df(0xc4)}}),OPERATORS_REQUIRING_UNIT[_0xd052df(0xb2)](_0x4b2452[_0xd052df(0xa4)])&&_0x4b2452[_0xd052df(0xc5)]!==undefined&&!_0x4b2452[_0xd052df(0xa1)]&&_0x59bb08[_0xd052df(0x91)]({'code':_0xd052df(0xc6),'message':'Operator\x20\x27'+_0x4b2452[_0xd052df(0xa4)]+_0xd052df(0xb0),'path':['unit'],'params':{'validationCode':_0xd052df(0x8f)}}),_0x4b2452[_0xd052df(0xa4)]===_0xd052df(0xce)&&(!_0x4b2452[_0xd052df(0xb1)]&&_0x59bb08[_0xd052df(0x91)]({'code':_0xd052df(0xc6),'message':'TimeRange\x20operator\x20requires\x20\x27duration\x27','path':[_0xd052df(0xb1)]}),!_0x4b2452[_0xd052df(0xaf)]&&_0x59bb08[_0xd052df(0x91)]({'code':'custom','message':'TimeRange\x20operator\x20requires\x20\x27from\x27','path':['from']}));});export const ArrayMatchingSchema=z[a164_0x32a8b7(0xa2)]([z[a164_0x32a8b7(0xb5)](a164_0x32a8b7(0xdb)),z['literal']('all'),z['object']({'atLeast':z[a164_0x32a8b7(0xc2)]()}),z[a164_0x32a8b7(0xcd)]({'atMost':z[a164_0x32a8b7(0xc2)]()}),z[a164_0x32a8b7(0xcd)]({'exactly':z[a164_0x32a8b7(0xc2)]()})]);export const AggregationDefSchema=z[a164_0x32a8b7(0x9e)](a164_0x32a8b7(0xa4),[z['object']({'type':z[a164_0x32a8b7(0xdd)](['Sum',a164_0x32a8b7(0xae),a164_0x32a8b7(0x9c),a164_0x32a8b7(0x94)]),'column':z[a164_0x32a8b7(0x95)](),'groupingColumns':z['array'](z['string']())[a164_0x32a8b7(0xbb)]()}),z['object']({'type':z[a164_0x32a8b7(0xb5)](a164_0x32a8b7(0xab)),'groupingColumns':z[a164_0x32a8b7(0x99)](z[a164_0x32a8b7(0x95)]())[a164_0x32a8b7(0xbb)]()}),z[a164_0x32a8b7(0xcd)]({'type':z[a164_0x32a8b7(0xb5)](a164_0x32a8b7(0xc9)),'columns':z['array'](z[a164_0x32a8b7(0x95)]())}),z[a164_0x32a8b7(0xcd)]({'type':z[a164_0x32a8b7(0xdd)](['First',a164_0x32a8b7(0xd3)]),'column':z['string'](),'orderColumn':z[a164_0x32a8b7(0x95)](),'groupingColumns':z[a164_0x32a8b7(0x99)](z[a164_0x32a8b7(0x95)]())[a164_0x32a8b7(0xbb)]()})]);export const TimeWindowDefSchema=z['object']({'duration':z[a164_0x32a8b7(0xc2)](),'unit':TimeUnitSchema});const TIMESTAMP_OPERATORS=new Set([a164_0x32a8b7(0xbc),a164_0x32a8b7(0xb6),'TimeRange']);export const FilterColumnConditionDefSchema=z['object']({'type':z['literal'](a164_0x32a8b7(0x9a)),'column':z[a164_0x32a8b7(0x95)](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema[a164_0x32a8b7(0xbb)]()})[a164_0x32a8b7(0xcc)]((_0x1e109c,_0x1c41b2)=>{const _0x4c8a4a=a164_0x32a8b7,_0x46e1aa=_0x1e109c[_0x4c8a4a(0x90)][_0x4c8a4a(0xa4)];_0x1e109c[_0x4c8a4a(0xa7)]===_0x4c8a4a(0xc8)?!TIMESTAMP_OPERATORS['has'](_0x46e1aa)&&_0x1c41b2['addIssue']({'code':'custom','message':_0x4c8a4a(0xd1)+_0x46e1aa+'\x27)','path':[_0x4c8a4a(0x90),_0x4c8a4a(0xa4)]}):TIMESTAMP_OPERATORS[_0x4c8a4a(0xb2)](_0x46e1aa)&&_0x1c41b2['addIssue']({'code':'custom','message':_0x4c8a4a(0xd9)+_0x46e1aa+_0x4c8a4a(0xa5),'path':[_0x4c8a4a(0x90),_0x4c8a4a(0xa4)]});});export const FilterRuleDefSchema=z[a164_0x32a8b7(0xcd)]({'type':z['literal'](a164_0x32a8b7(0xd0)),'conditions':z[a164_0x32a8b7(0x99)](FilterColumnConditionDefSchema)});export const ValueConditionDefSchema=z[a164_0x32a8b7(0x9d)](()=>z[a164_0x32a8b7(0xcd)]({'type':z[a164_0x32a8b7(0xb5)](a164_0x32a8b7(0xb8)),'attribute':z[a164_0x32a8b7(0x95)](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema[a164_0x32a8b7(0xbb)](),'exclude':z[a164_0x32a8b7(0xd6)]()[a164_0x32a8b7(0xbb)](),'aggregation':AggregationDefSchema[a164_0x32a8b7(0xbb)](),'source':z[a164_0x32a8b7(0x95)]()['optional'](),'filter':FilterRuleDefSchema['optional'](),'limit':z[a164_0x32a8b7(0xc2)]()['optional']()}));export const BehaviorConditionDefSchema=z[a164_0x32a8b7(0x9d)](()=>z[a164_0x32a8b7(0xcd)]({'type':z[a164_0x32a8b7(0xb5)](a164_0x32a8b7(0xde)),'attribute':z['string'](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema['optional'](),'exclude':z[a164_0x32a8b7(0xd6)]()[a164_0x32a8b7(0xbb)](),'aggregation':AggregationDefSchema[a164_0x32a8b7(0xbb)](),'source':z[a164_0x32a8b7(0x95)]()[a164_0x32a8b7(0xbb)](),'filter':FilterRuleDefSchema[a164_0x32a8b7(0xbb)](),'timeWindow':TimeWindowDefSchema['optional'](),'limit':z[a164_0x32a8b7(0xc2)]()[a164_0x32a8b7(0xbb)]()}));export const ColumnConditionDefSchema=z[a164_0x32a8b7(0xcd)]({'type':z[a164_0x32a8b7(0xb5)](a164_0x32a8b7(0x9a)),'column':z[a164_0x32a8b7(0x95)](),'operator':OperatorDefSchema});export const CompositeConditionDefSchema=z[a164_0x32a8b7(0x9d)](()=>z['object']({'type':z[a164_0x32a8b7(0xdd)](['And','Or']),'conditions':z['array'](ConditionDefSchema),'description':z[a164_0x32a8b7(0x95)]()[a164_0x32a8b7(0xbb)]()}));export const SegmentRefConditionDefSchema=z[a164_0x32a8b7(0xcd)]({'type':z[a164_0x32a8b7(0xdd)]([a164_0x32a8b7(0xbd),a164_0x32a8b7(0xc7)]),'segment':z[a164_0x32a8b7(0x95)]()['min'](0x1,a164_0x32a8b7(0xaa))});export const ConditionDefSchema=z['lazy'](()=>z[a164_0x32a8b7(0xa2)]([ValueConditionDefSchema,BehaviorConditionDefSchema,ColumnConditionDefSchema,CompositeConditionDefSchema,SegmentRefConditionDefSchema]));export const RuleDefSchema=z[a164_0x32a8b7(0x9d)](()=>z[a164_0x32a8b7(0xcd)]({'type':z[a164_0x32a8b7(0xdd)]([a164_0x32a8b7(0xd0),'Or']),'conditions':z[a164_0x32a8b7(0x99)](ConditionDefSchema),'description':z[a164_0x32a8b7(0x95)]()[a164_0x32a8b7(0xbb)]()}));export const SegmentDefSchema=z['object']({'type':z[a164_0x32a8b7(0xb5)](a164_0x32a8b7(0xcf))[a164_0x32a8b7(0xbb)](),'name':z[a164_0x32a8b7(0x95)]()[a164_0x32a8b7(0xd4)](0x1,'Segment\x20name\x20is\x20required'),'description':z[a164_0x32a8b7(0x95)]()[a164_0x32a8b7(0xbb)](),'folder':z[a164_0x32a8b7(0x95)]()[a164_0x32a8b7(0xbb)](),'rule':RuleDefSchema[a164_0x32a8b7(0xbb)](),'kind':z[a164_0x32a8b7(0xdd)]([a164_0x32a8b7(0xad),a164_0x32a8b7(0xd5),a164_0x32a8b7(0xcb)])['optional'](),'visible':z[a164_0x32a8b7(0xd6)]()['optional'](),'activations':z[a164_0x32a8b7(0x99)](z['any']())['optional']()});const _syncCheck1=!![],_syncCheck2=!![];void _syncCheck1,void _syncCheck2;function a164_0x4a14(){const _0x5d4b81=['LessEqual','Operator\x20\x27','hour','any','Greater','enum','Behavior','MISSING_TIME_UNIT','operator','addIssue','IsNull','StartWith','Average','string','month','60HqSjRZ','First','array','Column','516177SoQSRl','Max','lazy','discriminatedUnion','937368ByFQlY','Less','unit','union','39548msVpik','type','\x27\x20is\x20only\x20valid\x20for\x20the\x20\x27timestamp\x27\x20column','24829NIzXjj','column','year','GreaterEqual','Segment\x20reference\x20must\x20not\x20be\x20empty','Count','Between','batch','Min','from','\x27\x20requires\x20a\x20time\x20unit','duration','has','EndWith','record','literal','TimeWithinNext','Contain','Value','minute','Regexp','optional','TimeWithinPast','include','\x27\x20requires\x20a\x20value','1451472YKgzMK','310914phzFXb','max','number','Equal','MISSING_BETWEEN_BOUNDS','value','custom','exclude','timestamp','CountDistinct','1400pnGfUC','funnel_stage','superRefine','object','TimeRange','segment','And','Timestamp\x20column\x20only\x20supports\x20TimeWithinPast,\x20TimeWithinNext,\x20or\x20TimeRange\x20operators\x20(got\x20\x27','7355370UrrkxM','Last','min','realtime','boolean','265JBcOgW'];a164_0x4a14=function(){return _0x5d4b81;};return a164_0x4a14();}
@@ -1 +1 @@
1
- const a165_0x25f2eb=a165_0x5e66;(function(_0x43789f,_0x5550f6){const _0x227d04=a165_0x5e66,_0x3caa70=_0x43789f();while(!![]){try{const _0x480c6c=-parseInt(_0x227d04(0x1bf))/0x1*(-parseInt(_0x227d04(0x1cf))/0x2)+parseInt(_0x227d04(0x1cd))/0x3+-parseInt(_0x227d04(0x1c3))/0x4*(parseInt(_0x227d04(0x1c0))/0x5)+-parseInt(_0x227d04(0x1d2))/0x6+-parseInt(_0x227d04(0x1c8))/0x7+parseInt(_0x227d04(0x1ca))/0x8*(parseInt(_0x227d04(0x1c5))/0x9)+parseInt(_0x227d04(0x1cb))/0xa;if(_0x480c6c===_0x5550f6)break;else _0x3caa70['push'](_0x3caa70['shift']());}catch(_0x3575da){_0x3caa70['push'](_0x3caa70['shift']());}}}(a165_0x57b2,0x41506));import{readFileSync}from'fs';import*as a165_0x16db5a from'path';function a165_0x5e66(_0x3c6191,_0x229cdb){_0x3c6191=_0x3c6191-0x1b8;const _0x57b20a=a165_0x57b2();let _0x5e6601=_0x57b20a[_0x3c6191];return _0x5e6601;}import*as a165_0x542335 from'yaml';import{validateSegmentDef}from'./yaml-validator.js';import{validateJourneyDef}from'./journey-validator.js';import{validateCampaignDef}from'../engage/campaign-validator.js';import{validateTemplateDef}from'../engage/template-validator.js';const VALID_CAMPAIGN_TYPES=new Set(['email',a165_0x25f2eb(0x1bc)]);export function isJourneyDef(_0x1e3958){const _0xc55fdc=a165_0x25f2eb;return typeof _0x1e3958===_0xc55fdc(0x1b8)&&_0x1e3958!==null&&_0xc55fdc(0x1c1)in _0x1e3958&&_0x1e3958[_0xc55fdc(0x1c1)]===_0xc55fdc(0x1cc);}export function isCampaignDef(_0x1b5a71){const _0x3e7c05=a165_0x25f2eb;if(typeof _0x1b5a71!=='object'||_0x1b5a71===null)return![];const _0x58937f=_0x1b5a71,_0x590aa7=VALID_CAMPAIGN_TYPES['has'](_0x58937f[_0x3e7c05(0x1be)]);if(_0x58937f['type']===_0x3e7c05(0x1d1)&&_0x590aa7)return!![];if(_0x590aa7&&!_0x58937f[_0x3e7c05(0x1c1)])return!![];return![];}export function isTemplateDef(_0x317fc1){const _0x3295bc=a165_0x25f2eb;return typeof _0x317fc1==='object'&&_0x317fc1!==null&&'type'in _0x317fc1&&_0x317fc1[_0x3295bc(0x1c1)]==='template';}export function isValidationResult(_0x52c87e){const _0xe7bc09=a165_0x25f2eb;return!(_0xe7bc09(0x1c2)in _0x52c87e);}export function createParseErrorResult(_0x3f8670,_0x1ae370,_0x53dc45,_0x4e83b5,_0x519b9d=a165_0x25f2eb(0x1bd)){const _0x9b0d1a=a165_0x25f2eb;return{'filePath':_0x3f8670,'relativePath':_0x1ae370,'source':_0x53dc45,'result':{'valid':![],'errors':[{'level':_0x9b0d1a(0x1c9),'path':'','code':_0x9b0d1a(0x1c4),'message':_0x4e83b5}],'warnings':[]},'fileType':_0x519b9d};}export function validateYamlFile(_0x2ba55d,_0x2bf7e1,_0x517f76={}){const _0x46dc72=a165_0x25f2eb,_0x624bc4=a165_0x16db5a[_0x46dc72(0x1d0)](_0x2bf7e1,_0x2ba55d)||a165_0x16db5a[_0x46dc72(0x1d7)](_0x2ba55d);try{const _0x17de06=readFileSync(_0x2ba55d,_0x46dc72(0x1d4)),_0x42bbe8=a165_0x542335[_0x46dc72(0x1d6)](_0x17de06),_0x12f34d=_0x42bbe8[_0x46dc72(0x1c7)]();if(!_0x12f34d)return createParseErrorResult(_0x2ba55d,_0x624bc4,_0x17de06,_0x46dc72(0x1c6));let _0x23786c;if(isJourneyDef(_0x12f34d))_0x23786c=_0x46dc72(0x1cc);else{if(isCampaignDef(_0x12f34d))_0x23786c=_0x46dc72(0x1d1);else isTemplateDef(_0x12f34d)?_0x23786c=_0x46dc72(0x1d5):_0x23786c=_0x46dc72(0x1bd);}if(_0x517f76['filterType']&&_0x23786c!==_0x517f76[_0x46dc72(0x1ba)])return{'filePath':_0x2ba55d,'relativePath':_0x624bc4,'skipped':!![],'reason':'not\x20a\x20'+_0x517f76['filterType']};const _0x115ce8={'source':_0x17de06,'document':_0x42bbe8};let _0x3336f0;if(_0x23786c===_0x46dc72(0x1cc))_0x3336f0=validateJourneyDef(_0x12f34d,_0x115ce8);else{if(_0x23786c===_0x46dc72(0x1d1))_0x3336f0=validateCampaignDef(_0x12f34d,_0x115ce8);else _0x23786c===_0x46dc72(0x1d5)?_0x3336f0=validateTemplateDef(_0x12f34d,_0x115ce8):_0x3336f0=validateSegmentDef(_0x12f34d,_0x115ce8);}return{'filePath':_0x2ba55d,'relativePath':_0x624bc4,'source':_0x17de06,'result':_0x3336f0,'fileType':_0x23786c};}catch(_0x5fe46){const _0x1a19c1=_0x5fe46 instanceof Error?_0x5fe46['message']:String(_0x5fe46);return createParseErrorResult(_0x2ba55d,_0x624bc4,'',_0x46dc72(0x1ce)+_0x1a19c1);}}export function validateYamlFiles(_0x46566f,_0x1e52f3,_0x4207b4={}){return _0x46566f['map'](_0x44ba76=>validateYamlFile(_0x44ba76,_0x1e52f3,_0x4207b4));}export function calculateSummary(_0x112670){const _0x56ac16=a165_0x25f2eb;let _0x592d27=0x0,_0xbd1b91=0x0,_0x417eb0=0x0,_0x262e24=0x0;for(const _0x495111 of _0x112670){if(!isValidationResult(_0x495111)){_0x262e24++;continue;}_0x495111[_0x56ac16(0x1d3)][_0x56ac16(0x1bb)]?_0x592d27++:_0xbd1b91++,_0x417eb0+=_0x495111[_0x56ac16(0x1d3)][_0x56ac16(0x1d8)][_0x56ac16(0x1b9)];}return{'validCount':_0x592d27,'invalidCount':_0xbd1b91,'warningCount':_0x417eb0,'skippedCount':_0x262e24,'hasErrors':_0xbd1b91>0x0};}function a165_0x57b2(){const _0x7ddb19=['1137087sTixlU','Failed\x20to\x20parse\x20YAML\x20file\x20(empty\x20or\x20invalid)','toJSON','958643kqdzVY','error','8gLxrVc','7197650aEfapY','journey','334950DtiLPU','YAML\x20parse\x20error:\x20','994UgDICt','relative','campaign','1791690VfJUae','result','utf-8','template','parseDocument','basename','warnings','object','length','filterType','valid','push','segment','campaign_type','266rCGbux','17585vGvFPz','type','skipped','440vyptgP','YAML_PARSE_ERROR'];a165_0x57b2=function(){return _0x7ddb19;};return a165_0x57b2();}
1
+ const a165_0x3342f4=a165_0x30ef;(function(_0x1dd854,_0x25f303){const _0x4b3375=a165_0x30ef,_0x19d548=_0x1dd854();while(!![]){try{const _0x1e7c20=parseInt(_0x4b3375(0x88))/0x1*(-parseInt(_0x4b3375(0x7e))/0x2)+parseInt(_0x4b3375(0x78))/0x3*(parseInt(_0x4b3375(0x80))/0x4)+-parseInt(_0x4b3375(0x6e))/0x5+-parseInt(_0x4b3375(0x70))/0x6+parseInt(_0x4b3375(0x73))/0x7+parseInt(_0x4b3375(0x84))/0x8+-parseInt(_0x4b3375(0x7d))/0x9*(parseInt(_0x4b3375(0x71))/0xa);if(_0x1e7c20===_0x25f303)break;else _0x19d548['push'](_0x19d548['shift']());}catch(_0x4cd2c0){_0x19d548['push'](_0x19d548['shift']());}}}(a165_0x3b79,0x4b4d5));function a165_0x30ef(_0x317a9d,_0x4778c3){_0x317a9d=_0x317a9d-0x6a;const _0x3b7958=a165_0x3b79();let _0x30effe=_0x3b7958[_0x317a9d];return _0x30effe;}import{readFileSync}from'fs';import*as a165_0x3f7aca from'path';import*as a165_0x2b4338 from'yaml';import{validateSegmentDef}from'./yaml-validator.js';function a165_0x3b79(){const _0x20a916=['message','filterType','1902933aBIMFH','452skyumr','map','308356ACiAYX','result','segment','not\x20a\x20','4881840VydOVJ','campaign_type','YAML_PARSE_ERROR','toJSON','13wXfPHy','campaign','warnings','length','has','object','1373880aSIRUB','type','1287402ZYWXNI','10xjFwTd','skipped','654983DMoPOz','parseDocument','journey','YAML\x20parse\x20error:\x20','valid','12BDxFAV','email','template'];a165_0x3b79=function(){return _0x20a916;};return a165_0x3b79();}import{validateJourneyDef}from'./journey-validator.js';import{validateCampaignDef}from'../engage/campaign-validator.js';import{validateTemplateDef}from'../engage/template-validator.js';const VALID_CAMPAIGN_TYPES=new Set([a165_0x3342f4(0x79),'push']);export function isJourneyDef(_0x241722){const _0x3fe947=a165_0x3342f4;return typeof _0x241722===_0x3fe947(0x6d)&&_0x241722!==null&&_0x3fe947(0x6f)in _0x241722&&_0x241722[_0x3fe947(0x6f)]==='journey';}export function isCampaignDef(_0x4749f2){const _0x1f8664=a165_0x3342f4;if(typeof _0x4749f2!==_0x1f8664(0x6d)||_0x4749f2===null)return![];const _0x364694=_0x4749f2,_0x4722a8=VALID_CAMPAIGN_TYPES[_0x1f8664(0x6c)](_0x364694[_0x1f8664(0x85)]);if(_0x364694[_0x1f8664(0x6f)]===_0x1f8664(0x89)&&_0x4722a8)return!![];if(_0x4722a8&&!_0x364694['type'])return!![];return![];}export function isTemplateDef(_0x4e5835){const _0x59336b=a165_0x3342f4;return typeof _0x4e5835===_0x59336b(0x6d)&&_0x4e5835!==null&&'type'in _0x4e5835&&_0x4e5835[_0x59336b(0x6f)]===_0x59336b(0x7a);}export function isValidationResult(_0x2c8e1b){const _0x51c8e4=a165_0x3342f4;return!(_0x51c8e4(0x72)in _0x2c8e1b);}export function createParseErrorResult(_0x226f64,_0x32e0d2,_0xe51c3b,_0x2954ad,_0x3dbde2='segment'){const _0x4726da=a165_0x3342f4;return{'filePath':_0x226f64,'relativePath':_0x32e0d2,'source':_0xe51c3b,'result':{'valid':![],'errors':[{'level':'error','path':'','code':_0x4726da(0x86),'message':_0x2954ad}],'warnings':[]},'fileType':_0x3dbde2};}export function validateYamlFile(_0x136a88,_0xd74e61,_0x4e9dd3={}){const _0x15258c=a165_0x3342f4,_0x1ded05=a165_0x3f7aca['relative'](_0xd74e61,_0x136a88)||a165_0x3f7aca['basename'](_0x136a88);try{const _0x58e8f0=readFileSync(_0x136a88,'utf-8'),_0x18073d=a165_0x2b4338[_0x15258c(0x74)](_0x58e8f0),_0x133002=_0x18073d[_0x15258c(0x87)]();if(!_0x133002)return createParseErrorResult(_0x136a88,_0x1ded05,_0x58e8f0,'Failed\x20to\x20parse\x20YAML\x20file\x20(empty\x20or\x20invalid)');let _0x18046f;if(isJourneyDef(_0x133002))_0x18046f=_0x15258c(0x75);else{if(isCampaignDef(_0x133002))_0x18046f=_0x15258c(0x89);else isTemplateDef(_0x133002)?_0x18046f=_0x15258c(0x7a):_0x18046f=_0x15258c(0x82);}if(_0x4e9dd3[_0x15258c(0x7c)]&&_0x18046f!==_0x4e9dd3[_0x15258c(0x7c)])return{'filePath':_0x136a88,'relativePath':_0x1ded05,'skipped':!![],'reason':_0x15258c(0x83)+_0x4e9dd3[_0x15258c(0x7c)]};const _0xe6420b={'source':_0x58e8f0,'document':_0x18073d};let _0x4ee940;if(_0x18046f===_0x15258c(0x75))_0x4ee940=validateJourneyDef(_0x133002,_0xe6420b);else{if(_0x18046f===_0x15258c(0x89))_0x4ee940=validateCampaignDef(_0x133002,_0xe6420b);else _0x18046f===_0x15258c(0x7a)?_0x4ee940=validateTemplateDef(_0x133002,_0xe6420b):_0x4ee940=validateSegmentDef(_0x133002,_0xe6420b);}return{'filePath':_0x136a88,'relativePath':_0x1ded05,'source':_0x58e8f0,'result':_0x4ee940,'fileType':_0x18046f};}catch(_0x19e93b){const _0x49982d=_0x19e93b instanceof Error?_0x19e93b[_0x15258c(0x7b)]:String(_0x19e93b);return createParseErrorResult(_0x136a88,_0x1ded05,'',_0x15258c(0x76)+_0x49982d);}}export function validateYamlFiles(_0xbba8f,_0x17c66d,_0xb52ba3={}){const _0x213149=a165_0x3342f4;return _0xbba8f[_0x213149(0x7f)](_0xf7a01=>validateYamlFile(_0xf7a01,_0x17c66d,_0xb52ba3));}export function calculateSummary(_0x58533b){const _0x4fd945=a165_0x3342f4;let _0x230ccd=0x0,_0x50c046=0x0,_0x5d610d=0x0,_0x3a111f=0x0;for(const _0x4a5efd of _0x58533b){if(!isValidationResult(_0x4a5efd)){_0x3a111f++;continue;}_0x4a5efd[_0x4fd945(0x81)][_0x4fd945(0x77)]?_0x230ccd++:_0x50c046++,_0x5d610d+=_0x4a5efd[_0x4fd945(0x81)][_0x4fd945(0x6a)][_0x4fd945(0x6b)];}return{'validCount':_0x230ccd,'invalidCount':_0x50c046,'warningCount':_0x5d610d,'skippedCount':_0x3a111f,'hasErrors':_0x50c046>0x0};}
@@ -1 +1 @@
1
- (function(_0x487ed6,_0x567e01){const _0x507a1f=a166_0x3afe,_0x4627c2=_0x487ed6();while(!![]){try{const _0x1e4281=parseInt(_0x507a1f(0x183))/0x1*(-parseInt(_0x507a1f(0x17a))/0x2)+parseInt(_0x507a1f(0x16e))/0x3*(parseInt(_0x507a1f(0x17b))/0x4)+parseInt(_0x507a1f(0x15f))/0x5*(parseInt(_0x507a1f(0x164))/0x6)+parseInt(_0x507a1f(0x165))/0x7+-parseInt(_0x507a1f(0x185))/0x8*(-parseInt(_0x507a1f(0x189))/0x9)+parseInt(_0x507a1f(0x167))/0xa+-parseInt(_0x507a1f(0x172))/0xb;if(_0x1e4281===_0x567e01)break;else _0x4627c2['push'](_0x4627c2['shift']());}catch(_0x48401b){_0x4627c2['push'](_0x4627c2['shift']());}}}(a166_0x3281,0xd7aaa));import*as a166_0x2c1a7a from'yaml';import a166_0x221e2e from'chalk';export{validateSegmentDef,validateRuleDef}from'./segment-validator.js';export function getLocationFromPath(_0x117f6e,_0x4caf6b,_0x47e8ba){const _0x39eab4=a166_0x3afe;if(!_0x117f6e||!_0x4caf6b)return undefined;try{let _0x5d6f5d=_0x117f6e[_0x39eab4(0x168)](_0x47e8ba,!![]),_0x4ff550=[..._0x47e8ba];while((!_0x5d6f5d||typeof _0x5d6f5d!=='object'||!(_0x39eab4(0x186)in _0x5d6f5d)||!_0x5d6f5d[_0x39eab4(0x186)])&&_0x4ff550[_0x39eab4(0x16a)]>0x0){_0x4ff550['pop'](),_0x5d6f5d=_0x4ff550[_0x39eab4(0x16a)]>0x0?_0x117f6e[_0x39eab4(0x168)](_0x4ff550,!![]):_0x117f6e[_0x39eab4(0x187)];}if(!_0x5d6f5d||typeof _0x5d6f5d!=='object'||!(_0x39eab4(0x186)in _0x5d6f5d)||!_0x5d6f5d[_0x39eab4(0x186)])return undefined;const [_0x483197]=_0x5d6f5d['range'];return offsetToLocation(_0x4caf6b,_0x483197);}catch{return undefined;}}export function offsetToLocation(_0xfbb3c8,_0x2a819d){let _0x5dd117=0x1,_0x503e4e=0x1;for(let _0x42b7de=0x0;_0x42b7de<_0x2a819d&&_0x42b7de<_0xfbb3c8['length'];_0x42b7de++){_0xfbb3c8[_0x42b7de]==='\x0a'?(_0x5dd117++,_0x503e4e=0x1):_0x503e4e++;}return{'line':_0x5dd117,'column':_0x503e4e,'offset':_0x2a819d};}export function pathToArray(_0x5951f7){const _0x15d9bf=a166_0x3afe;if(!_0x5951f7)return[];return _0x5951f7['split']('.')[_0x15d9bf(0x176)](_0x1a6a77=>{const _0x2d6d29=_0x1a6a77['match'](/^(\w+)\[(\d+)\]$/);if(_0x2d6d29)return[_0x2d6d29[0x1],parseInt(_0x2d6d29[0x2],0xa)];return[_0x1a6a77];});}export function formatZodPath(_0x553d75){const _0x4a1d5d=a166_0x3afe;let _0x46e651='';for(const _0x390a50 of _0x553d75){if(typeof _0x390a50===_0x4a1d5d(0x17c))_0x46e651+='['+_0x390a50+']';else{const _0x29f89c=String(_0x390a50);_0x46e651+=_0x46e651?'.'+_0x29f89c:_0x29f89c;}}return _0x46e651;}export function flattenZodIssues(_0x457d73){const _0xdbbe6f=a166_0x3afe,_0x457bd7=[];for(const _0x4b9290 of _0x457d73){if(_0x4b9290[_0xdbbe6f(0x171)]==='invalid_union'&&_0xdbbe6f(0x170)in _0x4b9290){const _0x2e5919=_0x4b9290[_0xdbbe6f(0x170)];let _0x149a7a=_0x2e5919[0x0]||[];for(const _0x3056e0 of _0x2e5919){_0x3056e0[_0xdbbe6f(0x16a)]<_0x149a7a[_0xdbbe6f(0x16a)]&&(_0x149a7a=_0x3056e0);}const _0x3a0a7f=_0x149a7a[_0xdbbe6f(0x15d)](_0x5eff35=>({..._0x5eff35,'path':[..._0x4b9290[_0xdbbe6f(0x16f)],..._0x5eff35[_0xdbbe6f(0x16f)]]}));_0x457bd7[_0xdbbe6f(0x180)](...flattenZodIssues(_0x3a0a7f));}else _0x457bd7[_0xdbbe6f(0x180)](_0x4b9290);}return _0x457bd7;}export function safeParseYaml(_0xcb6f5,_0x53e6fe){const _0x1546be=a166_0x3afe,_0x1e315f=a166_0x2c1a7a[_0x1546be(0x169)](_0xcb6f5);if(!_0x1e315f||typeof _0x1e315f!==_0x1546be(0x179))throw new Error(_0x1546be(0x175));const _0x6042e1=_0x53e6fe['safeParse'](_0x1e315f);if(!_0x6042e1[_0x1546be(0x161)]){const _0x5c6aca=_0x6042e1[_0x1546be(0x16c)][_0x1546be(0x16b)][0x0],_0x48595b=formatZodPath(_0x5c6aca[_0x1546be(0x16f)]);throw new Error(_0x48595b?_0x1546be(0x174)+_0x48595b+_0x1546be(0x173)+_0x5c6aca[_0x1546be(0x182)]:'YAML\x20validation\x20error:\x20'+_0x5c6aca[_0x1546be(0x182)]);}return _0x6042e1[_0x1546be(0x160)];}export function formatIssueWithContext(_0x56fae0,_0x2fb327,_0x9710c5){const _0x3bffec=a166_0x3afe,_0x4ee797=[],_0x5b7533=_0x56fae0[_0x3bffec(0x16d)]===_0x3bffec(0x16c),_0x3ac503=_0x5b7533?a166_0x221e2e['red']:a166_0x221e2e['yellow'],_0x2ba81a=_0x5b7533?a166_0x221e2e[_0x3bffec(0x17d)]:a166_0x221e2e[_0x3bffec(0x15c)],_0x28f8dd=_0x9710c5?a166_0x221e2e['cyan'](_0x9710c5+':'):'';if(_0x56fae0['location']){const _0x19240d=a166_0x221e2e[_0x3bffec(0x163)](_0x56fae0['location']['line']+':'+_0x56fae0[_0x3bffec(0x15e)][_0x3bffec(0x178)]);_0x4ee797[_0x3bffec(0x180)](''+_0x28f8dd+_0x19240d+':\x20'+_0x3ac503(_0x56fae0[_0x3bffec(0x16d)])+'\x20'+_0x2ba81a('['+_0x56fae0[_0x3bffec(0x171)]+']'));}else _0x4ee797[_0x3bffec(0x180)](''+_0x28f8dd+a166_0x221e2e[_0x3bffec(0x17e)](_0x56fae0[_0x3bffec(0x16f)])+':\x20'+_0x3ac503(_0x56fae0['level'])+'\x20'+_0x2ba81a('['+_0x56fae0['code']+']'));_0x4ee797[_0x3bffec(0x180)](_0x56fae0[_0x3bffec(0x182)]);if(_0x56fae0[_0x3bffec(0x15e)]&&_0x2fb327){const _0x387171=_0x2fb327[_0x3bffec(0x181)]('\x0a'),{line:_0xafd412,column:_0x16284d}=_0x56fae0[_0x3bffec(0x15e)],_0x3cf109=Math['max'](0x1,_0xafd412-0x1),_0xf10894=Math[_0x3bffec(0x166)](_0x387171['length'],_0xafd412+0x1);_0x4ee797[_0x3bffec(0x180)]('');for(let _0x57b57c=_0x3cf109;_0x57b57c<=_0xf10894;_0x57b57c++){const _0x5a9e70=_0x387171[_0x57b57c-0x1]||'',_0x4da60b=a166_0x221e2e[_0x3bffec(0x17e)](_0x57b57c[_0x3bffec(0x17f)]()[_0x3bffec(0x184)](0x4)),_0x1fa347=a166_0x221e2e['dim'](_0x3bffec(0x177));if(_0x57b57c===_0xafd412){_0x4ee797['push']('\x20\x20'+_0x4da60b+_0x1fa347+_0x3ac503(_0x5a9e70));const _0x4d0953='\x20'['repeat'](0x4+0x3+_0x16284d-0x1);_0x4ee797['push']('\x20\x20'+_0x4d0953+_0x3ac503('^'));}else _0x4ee797[_0x3bffec(0x180)]('\x20\x20'+_0x4da60b+_0x1fa347+a166_0x221e2e[_0x3bffec(0x17e)](_0x5a9e70));}}return _0x4ee797[_0x3bffec(0x162)]('\x0a');}function a166_0x3281(){const _0x414aeb=['errors','code','29757662qwWzDZ','\x27:\x20','YAML\x20validation\x20error\x20at\x20\x27','Invalid\x20YAML:\x20expected\x20an\x20object','flatMap','\x20|\x20','column','object','526iKDSOo','40ckaReu','number','red','dim','toString','push','split','message','3147PibJLu','padStart','16pGKMIy','range','contents','warnings','3294585BJZYme','yellow','map','location','18845gnqkSw','data','success','join','cyan','438oYfNDE','2712640jULyEo','min','14450260Yajsds','getIn','parse','length','issues','error','level','472938MyIKgW','path'];a166_0x3281=function(){return _0x414aeb;};return a166_0x3281();}function a166_0x3afe(_0x37c32c,_0x383095){_0x37c32c=_0x37c32c-0x15c;const _0x3281db=a166_0x3281();let _0x3afe1d=_0x3281db[_0x37c32c];return _0x3afe1d;}export function formatValidationResult(_0x54ee8e,_0x62f03a,_0x2f6cfe){const _0x3b3c32=a166_0x3afe,_0x2e1e13=[];for(const _0x565881 of _0x54ee8e[_0x3b3c32(0x170)]){_0x2e1e13['push'](formatIssueWithContext(_0x565881,_0x62f03a,_0x2f6cfe)),_0x2e1e13[_0x3b3c32(0x180)]('');}for(const _0x498bff of _0x54ee8e[_0x3b3c32(0x188)]){_0x2e1e13[_0x3b3c32(0x180)](formatIssueWithContext(_0x498bff,_0x62f03a,_0x2f6cfe)),_0x2e1e13[_0x3b3c32(0x180)]('');}return _0x2e1e13['join']('\x0a');}
1
+ (function(_0x2c2fc7,_0xfb236c){const _0x4a242f=a166_0x31df,_0x276119=_0x2c2fc7();while(!![]){try{const _0x1a068c=parseInt(_0x4a242f(0x1cf))/0x1*(parseInt(_0x4a242f(0x1c7))/0x2)+-parseInt(_0x4a242f(0x1b8))/0x3*(-parseInt(_0x4a242f(0x1b1))/0x4)+-parseInt(_0x4a242f(0x1b7))/0x5*(parseInt(_0x4a242f(0x1c2))/0x6)+-parseInt(_0x4a242f(0x1ce))/0x7*(parseInt(_0x4a242f(0x1b9))/0x8)+-parseInt(_0x4a242f(0x1ca))/0x9*(parseInt(_0x4a242f(0x1c0))/0xa)+-parseInt(_0x4a242f(0x1c3))/0xb*(-parseInt(_0x4a242f(0x1b2))/0xc)+parseInt(_0x4a242f(0x1bd))/0xd*(parseInt(_0x4a242f(0x1c8))/0xe);if(_0x1a068c===_0xfb236c)break;else _0x276119['push'](_0x276119['shift']());}catch(_0x2fc331){_0x276119['push'](_0x276119['shift']());}}}(a166_0x5730,0x6597f));function a166_0x5730(){const _0xcc0347=['red','dim','issues','cyan','\x20|\x20','YAML\x20validation\x20error\x20at\x20\x27','pop','getIn','yellow','length','warnings','Invalid\x20YAML:\x20expected\x20an\x20object','object','safeParse','min','success','code','level','location','4548WIrKsS','204IufcWc','join','errors','number','path','18065QtuTCu','978uOvIIv','4632VTfupg','push','range','max','13KkAGfu','contents','split','43670cVlgld','YAML\x20validation\x20error:\x20','372DOBmoP','16643bnEHpS','toString','message','repeat','1830pfluSL','98126GOUmmi','column','423AztsAm','line','error','flatMap','2765FfhMTg','733rwQtKG','invalid_union'];a166_0x5730=function(){return _0xcc0347;};return a166_0x5730();}import*as a166_0x41cc4f from'yaml';import a166_0x49d8bc from'chalk';export{validateSegmentDef,validateRuleDef}from'./segment-validator.js';export function getLocationFromPath(_0x1aa157,_0xa53222,_0x1f172c){const _0x47d0d2=a166_0x31df;if(!_0x1aa157||!_0xa53222)return undefined;try{let _0x2c6e15=_0x1aa157[_0x47d0d2(0x1d8)](_0x1f172c,!![]),_0x39940e=[..._0x1f172c];while((!_0x2c6e15||typeof _0x2c6e15!==_0x47d0d2(0x1aa)||!('range'in _0x2c6e15)||!_0x2c6e15[_0x47d0d2(0x1bb)])&&_0x39940e[_0x47d0d2(0x1a7)]>0x0){_0x39940e[_0x47d0d2(0x1d7)](),_0x2c6e15=_0x39940e[_0x47d0d2(0x1a7)]>0x0?_0x1aa157[_0x47d0d2(0x1d8)](_0x39940e,!![]):_0x1aa157[_0x47d0d2(0x1be)];}if(!_0x2c6e15||typeof _0x2c6e15!==_0x47d0d2(0x1aa)||!('range'in _0x2c6e15)||!_0x2c6e15[_0x47d0d2(0x1bb)])return undefined;const [_0x2d1cd6]=_0x2c6e15['range'];return offsetToLocation(_0xa53222,_0x2d1cd6);}catch{return undefined;}}export function offsetToLocation(_0xebd040,_0x15e4ef){let _0x46f688=0x1,_0x51cb13=0x1;for(let _0x4be68c=0x0;_0x4be68c<_0x15e4ef&&_0x4be68c<_0xebd040['length'];_0x4be68c++){_0xebd040[_0x4be68c]==='\x0a'?(_0x46f688++,_0x51cb13=0x1):_0x51cb13++;}return{'line':_0x46f688,'column':_0x51cb13,'offset':_0x15e4ef};}export function pathToArray(_0x21d7cd){const _0x4dc080=a166_0x31df;if(!_0x21d7cd)return[];return _0x21d7cd['split']('.')[_0x4dc080(0x1cd)](_0x1e7472=>{const _0x3b7f32=_0x1e7472['match'](/^(\w+)\[(\d+)\]$/);if(_0x3b7f32)return[_0x3b7f32[0x1],parseInt(_0x3b7f32[0x2],0xa)];return[_0x1e7472];});}export function formatZodPath(_0x14d491){const _0x135969=a166_0x31df;let _0x2c8ca1='';for(const _0x12e977 of _0x14d491){if(typeof _0x12e977===_0x135969(0x1b5))_0x2c8ca1+='['+_0x12e977+']';else{const _0x2c12e7=String(_0x12e977);_0x2c8ca1+=_0x2c8ca1?'.'+_0x2c12e7:_0x2c12e7;}}return _0x2c8ca1;}function a166_0x31df(_0xe99fef,_0x551780){_0xe99fef=_0xe99fef-0x1a7;const _0x573091=a166_0x5730();let _0x31df76=_0x573091[_0xe99fef];return _0x31df76;}export function flattenZodIssues(_0x20687f){const _0x50bdaf=a166_0x31df,_0x5d5871=[];for(const _0x54a683 of _0x20687f){if(_0x54a683[_0x50bdaf(0x1ae)]===_0x50bdaf(0x1d0)&&_0x50bdaf(0x1b4)in _0x54a683){const _0x3ac2b9=_0x54a683[_0x50bdaf(0x1b4)];let _0x142cfe=_0x3ac2b9[0x0]||[];for(const _0x3e11cf of _0x3ac2b9){_0x3e11cf[_0x50bdaf(0x1a7)]<_0x142cfe[_0x50bdaf(0x1a7)]&&(_0x142cfe=_0x3e11cf);}const _0xc46afa=_0x142cfe['map'](_0x5967fb=>({..._0x5967fb,'path':[..._0x54a683[_0x50bdaf(0x1b6)],..._0x5967fb[_0x50bdaf(0x1b6)]]}));_0x5d5871[_0x50bdaf(0x1ba)](...flattenZodIssues(_0xc46afa));}else _0x5d5871[_0x50bdaf(0x1ba)](_0x54a683);}return _0x5d5871;}export function safeParseYaml(_0xf460fd,_0xbdd78f){const _0x5f1f9b=a166_0x31df,_0x5a83bc=a166_0x41cc4f['parse'](_0xf460fd);if(!_0x5a83bc||typeof _0x5a83bc!==_0x5f1f9b(0x1aa))throw new Error(_0x5f1f9b(0x1a9));const _0x3eb6b6=_0xbdd78f[_0x5f1f9b(0x1ab)](_0x5a83bc);if(!_0x3eb6b6[_0x5f1f9b(0x1ad)]){const _0x3d44ad=_0x3eb6b6['error'][_0x5f1f9b(0x1d3)][0x0],_0x413769=formatZodPath(_0x3d44ad['path']);throw new Error(_0x413769?_0x5f1f9b(0x1d6)+_0x413769+'\x27:\x20'+_0x3d44ad['message']:_0x5f1f9b(0x1c1)+_0x3d44ad[_0x5f1f9b(0x1c5)]);}return _0x3eb6b6['data'];}export function formatIssueWithContext(_0x282991,_0x4bb0e6,_0x2cc98f){const _0x476d3b=a166_0x31df,_0x3e41d7=[],_0x510bd9=_0x282991[_0x476d3b(0x1af)]===_0x476d3b(0x1cc),_0x24bd16=_0x510bd9?a166_0x49d8bc[_0x476d3b(0x1d1)]:a166_0x49d8bc[_0x476d3b(0x1d9)],_0x4e1d21=_0x510bd9?a166_0x49d8bc[_0x476d3b(0x1d1)]:a166_0x49d8bc[_0x476d3b(0x1d9)],_0x2e4478=_0x2cc98f?a166_0x49d8bc[_0x476d3b(0x1d4)](_0x2cc98f+':'):'';if(_0x282991[_0x476d3b(0x1b0)]){const _0x24e572=a166_0x49d8bc['cyan'](_0x282991[_0x476d3b(0x1b0)][_0x476d3b(0x1cb)]+':'+_0x282991[_0x476d3b(0x1b0)][_0x476d3b(0x1c9)]);_0x3e41d7['push'](''+_0x2e4478+_0x24e572+':\x20'+_0x24bd16(_0x282991[_0x476d3b(0x1af)])+'\x20'+_0x4e1d21('['+_0x282991[_0x476d3b(0x1ae)]+']'));}else _0x3e41d7[_0x476d3b(0x1ba)](''+_0x2e4478+a166_0x49d8bc['dim'](_0x282991[_0x476d3b(0x1b6)])+':\x20'+_0x24bd16(_0x282991[_0x476d3b(0x1af)])+'\x20'+_0x4e1d21('['+_0x282991[_0x476d3b(0x1ae)]+']'));_0x3e41d7[_0x476d3b(0x1ba)](_0x282991[_0x476d3b(0x1c5)]);if(_0x282991[_0x476d3b(0x1b0)]&&_0x4bb0e6){const _0x3cf383=_0x4bb0e6[_0x476d3b(0x1bf)]('\x0a'),{line:_0x5a54d4,column:_0x14e5d4}=_0x282991['location'],_0x3c370a=Math[_0x476d3b(0x1bc)](0x1,_0x5a54d4-0x1),_0x5a9e=Math[_0x476d3b(0x1ac)](_0x3cf383['length'],_0x5a54d4+0x1);_0x3e41d7['push']('');for(let _0x3666e3=_0x3c370a;_0x3666e3<=_0x5a9e;_0x3666e3++){const _0x1b37f9=_0x3cf383[_0x3666e3-0x1]||'',_0x909a9f=a166_0x49d8bc['dim'](_0x3666e3[_0x476d3b(0x1c4)]()['padStart'](0x4)),_0x341299=a166_0x49d8bc[_0x476d3b(0x1d2)](_0x476d3b(0x1d5));if(_0x3666e3===_0x5a54d4){_0x3e41d7['push']('\x20\x20'+_0x909a9f+_0x341299+_0x24bd16(_0x1b37f9));const _0x481dd1='\x20'[_0x476d3b(0x1c6)](0x4+0x3+_0x14e5d4-0x1);_0x3e41d7[_0x476d3b(0x1ba)]('\x20\x20'+_0x481dd1+_0x24bd16('^'));}else _0x3e41d7[_0x476d3b(0x1ba)]('\x20\x20'+_0x909a9f+_0x341299+a166_0x49d8bc[_0x476d3b(0x1d2)](_0x1b37f9));}}return _0x3e41d7[_0x476d3b(0x1b3)]('\x0a');}export function formatValidationResult(_0xfd3c9f,_0x20ee84,_0x4b6dc9){const _0xaeb1ca=a166_0x31df,_0x27d0bf=[];for(const _0x1dc81e of _0xfd3c9f[_0xaeb1ca(0x1b4)]){_0x27d0bf[_0xaeb1ca(0x1ba)](formatIssueWithContext(_0x1dc81e,_0x20ee84,_0x4b6dc9)),_0x27d0bf[_0xaeb1ca(0x1ba)]('');}for(const _0x181db1 of _0xfd3c9f[_0xaeb1ca(0x1a8)]){_0x27d0bf['push'](formatIssueWithContext(_0x181db1,_0x20ee84,_0x4b6dc9)),_0x27d0bf[_0xaeb1ca(0x1ba)]('');}return _0x27d0bf[_0xaeb1ca(0x1b3)]('\x0a');}