@treasuredata/tdx 2026.4.1 → 2026.4.2

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/cas-command.js +1 -1
  11. package/dist/commands/cas-segment-command.js +1 -1
  12. package/dist/commands/chat-command.js +1 -1
  13. package/dist/commands/claude-command.js +1 -1
  14. package/dist/commands/claude-statusline-command.js +1 -1
  15. package/dist/commands/claude-usage-command.js +1 -1
  16. package/dist/commands/command.js +1 -1
  17. package/dist/commands/connection-command.js +1 -1
  18. package/dist/commands/databases.js +1 -1
  19. package/dist/commands/delivery-command.js +1 -1
  20. package/dist/commands/describe.js +1 -1
  21. package/dist/commands/engage-campaign-pull-command.js +1 -1
  22. package/dist/commands/engage-campaign-push-command.js +1 -1
  23. package/dist/commands/engage-campaign-validate-command.js +1 -1
  24. package/dist/commands/engage-command.js +1 -1
  25. package/dist/commands/engage-template-pull-command.js +1 -1
  26. package/dist/commands/engage-template-push-command.js +1 -1
  27. package/dist/commands/engage-template-validate-command.js +1 -1
  28. package/dist/commands/job-command.js +1 -1
  29. package/dist/commands/journey-command.js +1 -1
  30. package/dist/commands/journey-validate-command.js +1 -1
  31. package/dist/commands/llm-command.js +1 -1
  32. package/dist/commands/mcp-command.js +1 -1
  33. package/dist/commands/parent-segment-command.js +1 -1
  34. package/dist/commands/policy-command.js +1 -1
  35. package/dist/commands/profile-command.js +1 -1
  36. package/dist/commands/profiles-command.js +1 -1
  37. package/dist/commands/query-command.js +1 -1
  38. package/dist/commands/schedule-command.js +1 -1
  39. package/dist/commands/segment-command.js +1 -1
  40. package/dist/commands/segment-create-command.js +1 -1
  41. package/dist/commands/segment-fields-command.js +1 -1
  42. package/dist/commands/segment-pull-command.js +1 -1
  43. package/dist/commands/segment-push-command.js +1 -1
  44. package/dist/commands/segment-update-command.js +1 -1
  45. package/dist/commands/segment-use-command.js +1 -1
  46. package/dist/commands/segment-validate-command.js +1 -1
  47. package/dist/commands/segments.js +1 -1
  48. package/dist/commands/show.js +1 -1
  49. package/dist/commands/status-command.js +1 -1
  50. package/dist/commands/tables.js +1 -1
  51. package/dist/commands/unset-command.js +1 -1
  52. package/dist/commands/upgrade-command.js +1 -1
  53. package/dist/commands/use-command.js +1 -1
  54. package/dist/commands/user-command.js +1 -1
  55. package/dist/commands/work-command.js +1 -1
  56. package/dist/commands/workflow-command.js +1 -1
  57. package/dist/core/auth.js +1 -1
  58. package/dist/core/command-output.js +1 -1
  59. package/dist/core/config.js +1 -1
  60. package/dist/core/connection-cache.js +1 -1
  61. package/dist/core/constants.js +1 -1
  62. package/dist/core/credential-cache.js +1 -1
  63. package/dist/core/global-context.js +1 -1
  64. package/dist/core/keychain.js +1 -1
  65. package/dist/core/oauth-keychain.js +1 -1
  66. package/dist/core/oauth.js +1 -1
  67. package/dist/core/profile.js +1 -1
  68. package/dist/core/project-config.js +1 -1
  69. package/dist/core/session.js +1 -1
  70. package/dist/core/user-cache.js +1 -1
  71. package/dist/core/version.js +1 -1
  72. package/dist/index.js +1 -1
  73. package/dist/mcp/server.js +1 -1
  74. package/dist/mcp/tools/index.js +1 -1
  75. package/dist/mcp/tools/tdx-run.js +1 -1
  76. package/dist/mcp/tools/tdx-search.js +1 -1
  77. package/dist/mcp/tools/work-create-item.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(_0x3b978,_0x2b5d1e){const _0x21fce8=a157_0x54f3,_0x2e4aaa=_0x3b978();while(!![]){try{const _0x21e8b4=parseInt(_0x21fce8(0x106))/0x1*(-parseInt(_0x21fce8(0xdd))/0x2)+parseInt(_0x21fce8(0x109))/0x3*(parseInt(_0x21fce8(0xde))/0x4)+-parseInt(_0x21fce8(0xfa))/0x5+parseInt(_0x21fce8(0xe8))/0x6*(parseInt(_0x21fce8(0xf3))/0x7)+parseInt(_0x21fce8(0xee))/0x8+parseInt(_0x21fce8(0x105))/0x9+-parseInt(_0x21fce8(0x104))/0xa;if(_0x21e8b4===_0x2b5d1e)break;else _0x2e4aaa['push'](_0x2e4aaa['shift']());}catch(_0x58933b){_0x2e4aaa['push'](_0x2e4aaa['shift']());}}}(a157_0xbaa5,0x647e1));import a157_0x21c6c0 from'path';import{sanitizeFileName}from'../../utils/string-utils.js';import{nodeFileSystem}from'../io/node-filesystem.js';function a157_0xbaa5(){const _0x358523=['cwd','866reIfqn','236OWHoeS','startsWith','join','tdx.json','trim','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','No\x20tdx.json\x20found\x20in\x20or\x20above:\x20','no_parent','error','segment','227418fcpjma','file_not_found','type','No\x20tdx.json\x20found\x20for\x20file:\x20','isScoped','string','2539104VSCpJA','match','exists','context','directory','119iSLLJw','basename','dirname','file','parent_segment','journey','Not\x20a\x20YAML\x20file:\x20','2315355CVQuvU','replace','stat','root','resourceType','relative','parentSegment','isDirectory','segmentName','Parent\x20segment\x20not\x20specified','14331440pCeadS','7245567gYrxsC','118epJfwR','no_config','configDir','30108Garzjt','message','invalid_yaml','parse','extname','parent_name','folderPath','resolve','includes','scopedFolderPath'];a157_0xbaa5=function(){return _0x358523;};return a157_0xbaa5();}import{isYamlFilePath,resolveYamlFilePath}from'./segment-path-parser.js';import{getSegmentRootDir}from'./tdx-config.js';export function isSuccessfulResolution(_0x4aa194){const _0x37c47d=a157_0x54f3;return _0x4aa194['type']!==_0x37c47d(0xe6);}export function isScopedResolution(_0x1b4a70){const _0x3240f4=a157_0x54f3;return _0x1b4a70[_0x3240f4(0xea)]===_0x3240f4(0xf2)||_0x1b4a70['type']===_0x3240f4(0xf6)||_0x1b4a70[_0x3240f4(0xea)]===_0x3240f4(0xf1);}function a157_0x54f3(_0x43d5d9,_0x44e23d){_0x43d5d9=_0x43d5d9-0xd9;const _0xbaa599=a157_0xbaa5();let _0x54f329=_0xbaa599[_0x43d5d9];return _0x54f329;}export function getScopedDetails(_0x4d31c1){const _0x123b40=a157_0x54f3;if(isScopedResolution(_0x4d31c1))return{'isScoped':_0x4d31c1[_0x123b40(0xec)],'scopedFolderPath':_0x4d31c1[_0x123b40(0xdb)]};return undefined;}async function findTdxConfigAsync(_0x3a2a9d,_0x345d5){const _0x21a76f=a157_0x54f3;let _0xcc2e1e=a157_0x21c6c0['resolve'](_0x3a2a9d);const _0x29f491=a157_0x21c6c0[_0x21a76f(0x10c)](_0xcc2e1e)[_0x21a76f(0xfd)];while(_0xcc2e1e!==_0x29f491){const _0x48e58f=a157_0x21c6c0[_0x21a76f(0xe0)](_0xcc2e1e,_0x21a76f(0xe1));if(await _0x345d5[_0x21a76f(0xf0)](_0x48e58f))try{const _0xf285b3=await _0x345d5['readFile'](_0x48e58f),_0x41e8ae=JSON[_0x21a76f(0x10c)](_0xf285b3);if(_0x41e8ae[_0x21a76f(0xf7)]&&typeof _0x41e8ae[_0x21a76f(0xf7)]===_0x21a76f(0xed))return{'configPath':_0x48e58f,'configDir':_0xcc2e1e,'parentSegment':_0x41e8ae[_0x21a76f(0xf7)]};}catch{}_0xcc2e1e=a157_0x21c6c0[_0x21a76f(0xf5)](_0xcc2e1e);}return null;}function calculateScopedPath(_0x3e0071,_0x3f6f10){const _0x4056b4=a157_0x54f3,_0x3a0030=a157_0x21c6c0[_0x4056b4(0xff)](_0x3f6f10,_0x3e0071),_0x123b52=_0x3a0030!==''&&_0x3a0030!=='.'&&!_0x3a0030[_0x4056b4(0xdf)]('..');return{'isScoped':_0x123b52,'scopedFolderPath':_0x123b52?_0x3a0030[_0x4056b4(0xfb)](/\\/g,'/'):''};}export async function resolveTarget(_0x2d4825){const _0x2d14c7=a157_0x54f3,{arg:_0x596446,contextParent:_0x5c42c9,cwd:cwd=process[_0x2d14c7(0xdc)](),fs:fs=nodeFileSystem}=_0x2d4825;if(_0x596446&&isYamlFilePath(_0x596446))try{const _0x1f72e6=await resolveYamlFilePath(_0x596446,fs),_0x70a198=a157_0x21c6c0[_0x2d14c7(0xd9)](_0x596446),_0x810531=a157_0x21c6c0[_0x2d14c7(0xf5)](_0x70a198),_0x428bd5=await findTdxConfigAsync(_0x810531,fs);if(!_0x428bd5){if(_0x5c42c9){const _0x29b69b=a157_0x21c6c0[_0x2d14c7(0xf5)](_0x70a198);return{'type':'file','parentName':_0x5c42c9,'targetDir':_0x29b69b,'configRoot':_0x29b69b,'filePath':_0x70a198,'resourceName':_0x1f72e6['segmentName'],'folderPath':_0x1f72e6[_0x2d14c7(0x10f)],'resourceType':_0x1f72e6[_0x2d14c7(0xfe)],'isScoped':![],'scopedFolderPath':''};}return{'type':'error','errorCode':'no_config','message':_0x2d14c7(0xeb)+_0x596446,'arg':_0x596446,'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 _0x19de30=calculateScopedPath(_0x810531,_0x428bd5[_0x2d14c7(0x108)]);return{'type':_0x2d14c7(0xf6),'parentName':_0x428bd5[_0x2d14c7(0x100)],'targetDir':_0x428bd5[_0x2d14c7(0x108)],'configRoot':_0x428bd5[_0x2d14c7(0x108)],'filePath':_0x70a198,'resourceName':_0x1f72e6[_0x2d14c7(0x102)],'folderPath':_0x1f72e6[_0x2d14c7(0x10f)],'resourceType':_0x1f72e6[_0x2d14c7(0xfe)],'isScoped':_0x19de30[_0x2d14c7(0xec)],'scopedFolderPath':_0x19de30['scopedFolderPath']};}catch(_0x2dfaa9){const _0x43cdf0=_0x2dfaa9 instanceof Error?_0x2dfaa9[_0x2d14c7(0x10a)]:String(_0x2dfaa9);if(_0x43cdf0[_0x2d14c7(0xda)]('File\x20not\x20found'))return{'type':'error','errorCode':_0x2d14c7(0xe9),'message':'File\x20not\x20found:\x20'+_0x596446,'arg':_0x596446};if(_0x43cdf0['includes']('No\x20tdx.json\x20found')){if(_0x5c42c9){const _0x1cdd16=a157_0x21c6c0[_0x2d14c7(0xd9)](_0x596446);if(await fs['exists'](_0x1cdd16)){const _0x43aea7=a157_0x21c6c0[_0x2d14c7(0xf5)](_0x1cdd16),_0x449d71=await fs['readFile'](_0x1cdd16),_0x5accfd=_0x449d71[_0x2d14c7(0xef)](/^name:\s*["']?([^"'\n]+)["']?/m),_0x144f08=_0x449d71[_0x2d14c7(0xef)](/^type:\s*["']?([^"'\n]+)["']?/m),_0x4c288f=_0x5accfd?_0x5accfd[0x1]['trim']():a157_0x21c6c0[_0x2d14c7(0xf4)](_0x596446,a157_0x21c6c0[_0x2d14c7(0x10d)](_0x596446)),_0x33c3bd=_0x144f08&&_0x144f08[0x1][_0x2d14c7(0xe2)]()===_0x2d14c7(0xf8)?_0x2d14c7(0xf8):_0x2d14c7(0xe7);return{'type':_0x2d14c7(0xf6),'parentName':_0x5c42c9,'targetDir':_0x43aea7,'configRoot':_0x43aea7,'filePath':_0x1cdd16,'resourceName':_0x4c288f,'folderPath':'','resourceType':_0x33c3bd,'isScoped':![],'scopedFolderPath':''};}}return{'type':_0x2d14c7(0xe6),'errorCode':'no_config','message':_0x2d14c7(0xeb)+_0x596446,'arg':_0x596446,'helpText':_0x2d14c7(0xe3)};}return{'type':_0x2d14c7(0xe6),'errorCode':_0x2d14c7(0x10b),'message':_0x43cdf0,'arg':_0x596446};}if(_0x596446){const _0x11697c=a157_0x21c6c0[_0x2d14c7(0xd9)](cwd,_0x596446);let _0x168ce5=null;try{_0x168ce5=await fs[_0x2d14c7(0xfc)](_0x11697c);}catch{}if(_0x168ce5?.[_0x2d14c7(0x101)]()){const _0x37ddee=await findTdxConfigAsync(_0x11697c,fs);if(_0x37ddee){const _0x50f502=calculateScopedPath(_0x11697c,_0x37ddee[_0x2d14c7(0x108)]);return{'type':_0x2d14c7(0xf2),'parentName':_0x37ddee[_0x2d14c7(0x100)],'targetDir':_0x11697c,'configRoot':_0x37ddee[_0x2d14c7(0x108)],'isScoped':_0x50f502['isScoped'],'scopedFolderPath':_0x50f502[_0x2d14c7(0xdb)]};}if(_0x5c42c9)return{'type':_0x2d14c7(0xf2),'parentName':_0x5c42c9,'targetDir':_0x11697c,'configRoot':_0x11697c,'isScoped':![],'scopedFolderPath':''};return{'type':_0x2d14c7(0xe6),'errorCode':_0x2d14c7(0x107),'message':_0x2d14c7(0xe4)+_0x596446,'arg':_0x596446,'helpText':_0x2d14c7(0xe3)};}if(_0x168ce5?.['isFile']())return{'type':'error','errorCode':_0x2d14c7(0x10b),'message':_0x2d14c7(0xf9)+_0x596446,'arg':_0x596446,'helpText':'Segment\x20and\x20journey\x20files\x20must\x20have\x20.yml\x20or\x20.yaml\x20extension'};const _0x10a4c1=sanitizeFileName(_0x596446),_0x5d1c3d=getSegmentRootDir(_0x10a4c1,cwd);return{'type':_0x2d14c7(0x10e),'parentName':_0x596446,'targetDir':_0x5d1c3d,'configRoot':_0x5d1c3d};}const _0x4aea64=await findTdxConfigAsync(cwd,fs);if(_0x4aea64){const _0x33739d=calculateScopedPath(cwd,_0x4aea64['configDir']);return{'type':_0x2d14c7(0xf1),'parentName':_0x4aea64[_0x2d14c7(0x100)],'targetDir':cwd,'configRoot':_0x4aea64[_0x2d14c7(0x108)],'isScoped':_0x33739d[_0x2d14c7(0xec)],'scopedFolderPath':_0x33739d['scopedFolderPath']};}if(_0x5c42c9){const _0x1aeb7a=sanitizeFileName(_0x5c42c9),_0x192879=getSegmentRootDir(_0x1aeb7a,cwd);return{'type':_0x2d14c7(0xf1),'parentName':_0x5c42c9,'targetDir':_0x192879,'configRoot':_0x192879,'isScoped':![],'scopedFolderPath':''};}return{'type':_0x2d14c7(0xe6),'errorCode':_0x2d14c7(0xe5),'message':_0x2d14c7(0x103),'helpText':'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'};}
1
+ (function(_0x100fe3,_0x76ed94){const _0xa86d1e=a157_0x40ac,_0x297aab=_0x100fe3();while(!![]){try{const _0x57af59=-parseInt(_0xa86d1e(0x208))/0x1+parseInt(_0xa86d1e(0x1f0))/0x2*(parseInt(_0xa86d1e(0x213))/0x3)+-parseInt(_0xa86d1e(0x1ff))/0x4*(parseInt(_0xa86d1e(0x214))/0x5)+-parseInt(_0xa86d1e(0x20c))/0x6+parseInt(_0xa86d1e(0x1eb))/0x7+-parseInt(_0xa86d1e(0x20a))/0x8*(parseInt(_0xa86d1e(0x1f1))/0x9)+parseInt(_0xa86d1e(0x218))/0xa;if(_0x57af59===_0x76ed94)break;else _0x297aab['push'](_0x297aab['shift']());}catch(_0x37b18b){_0x297aab['push'](_0x297aab['shift']());}}}(a157_0x275c,0xd4635));import a157_0x3f2589 from'path';import{sanitizeFileName}from'../../utils/string-utils.js';import{nodeFileSystem}from'../io/node-filesystem.js';function a157_0x40ac(_0x45cf25,_0x46bb26){_0x45cf25=_0x45cf25-0x1e4;const _0x275ced=a157_0x275c();let _0x40ac92=_0x275ced[_0x45cf25];return _0x40ac92;}function a157_0x275c(){const _0x578bc8=['Not\x20a\x20YAML\x20file:\x20','473484wADuEu','folderPath','parse','isFile','invalid_yaml','directory','basename','tdx.json','journey','831949pvSPWQ','isScoped','9688688MKxkFv','readFile','6989814WErtVF','parent_name','resolve','exists','No\x20tdx.json\x20found\x20for\x20file:\x20','dirname','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','3960564XaZCjD','10IWoDto','parent_segment','file_not_found','stat','18229980woxifb','replace','segmentName','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','includes','root','scopedFolderPath','no_config','8200507fMhJfR','context','cwd','File\x20not\x20found','No\x20tdx.json\x20found\x20in\x20or\x20above:\x20','2BtFPCx','9gGKFXd','error','match','file','type','extname','File\x20not\x20found:\x20','resourceType','Segment\x20and\x20journey\x20files\x20must\x20have\x20.yml\x20or\x20.yaml\x20extension','configDir','startsWith','trim','parentSegment'];a157_0x275c=function(){return _0x578bc8;};return a157_0x275c();}import{isYamlFilePath,resolveYamlFilePath}from'./segment-path-parser.js';import{getSegmentRootDir}from'./tdx-config.js';export function isSuccessfulResolution(_0x6f88d1){const _0x12d1a8=a157_0x40ac;return _0x6f88d1[_0x12d1a8(0x1f5)]!==_0x12d1a8(0x1f2);}export function isScopedResolution(_0x399eb7){const _0x3038f6=a157_0x40ac;return _0x399eb7[_0x3038f6(0x1f5)]===_0x3038f6(0x204)||_0x399eb7['type']==='file'||_0x399eb7['type']===_0x3038f6(0x1ec);}export function getScopedDetails(_0x469da2){const _0x43099e=a157_0x40ac;if(isScopedResolution(_0x469da2))return{'isScoped':_0x469da2[_0x43099e(0x209)],'scopedFolderPath':_0x469da2[_0x43099e(0x1e9)]};return undefined;}async function findTdxConfigAsync(_0x3467e8,_0x1c5c9a){const _0x2e846e=a157_0x40ac;let _0x5dea3a=a157_0x3f2589['resolve'](_0x3467e8);const _0x1b011c=a157_0x3f2589[_0x2e846e(0x201)](_0x5dea3a)[_0x2e846e(0x1e8)];while(_0x5dea3a!==_0x1b011c){const _0x537c12=a157_0x3f2589['join'](_0x5dea3a,_0x2e846e(0x206));if(await _0x1c5c9a[_0x2e846e(0x20f)](_0x537c12))try{const _0xae9d76=await _0x1c5c9a[_0x2e846e(0x20b)](_0x537c12),_0x2ef0b1=JSON['parse'](_0xae9d76);if(_0x2ef0b1[_0x2e846e(0x215)]&&typeof _0x2ef0b1[_0x2e846e(0x215)]==='string')return{'configPath':_0x537c12,'configDir':_0x5dea3a,'parentSegment':_0x2ef0b1[_0x2e846e(0x215)]};}catch{}_0x5dea3a=a157_0x3f2589[_0x2e846e(0x211)](_0x5dea3a);}return null;}function calculateScopedPath(_0x41ddc9,_0x5deeb3){const _0x44645e=a157_0x40ac,_0x3b92a4=a157_0x3f2589['relative'](_0x5deeb3,_0x41ddc9),_0x1ab9b7=_0x3b92a4!==''&&_0x3b92a4!=='.'&&!_0x3b92a4[_0x44645e(0x1fb)]('..');return{'isScoped':_0x1ab9b7,'scopedFolderPath':_0x1ab9b7?_0x3b92a4[_0x44645e(0x1e4)](/\\/g,'/'):''};}export async function resolveTarget(_0x41b732){const _0x3ffd3e=a157_0x40ac,{arg:_0x40afe0,contextParent:_0x19000d,cwd:cwd=process[_0x3ffd3e(0x1ed)](),fs:fs=nodeFileSystem}=_0x41b732;if(_0x40afe0&&isYamlFilePath(_0x40afe0))try{const _0x573e87=await resolveYamlFilePath(_0x40afe0,fs),_0x231a1b=a157_0x3f2589[_0x3ffd3e(0x20e)](_0x40afe0),_0x38382d=a157_0x3f2589[_0x3ffd3e(0x211)](_0x231a1b),_0x2fea41=await findTdxConfigAsync(_0x38382d,fs);if(!_0x2fea41){if(_0x19000d){const _0x52c61a=a157_0x3f2589[_0x3ffd3e(0x211)](_0x231a1b);return{'type':_0x3ffd3e(0x1f4),'parentName':_0x19000d,'targetDir':_0x52c61a,'configRoot':_0x52c61a,'filePath':_0x231a1b,'resourceName':_0x573e87[_0x3ffd3e(0x1e5)],'folderPath':_0x573e87['folderPath'],'resourceType':_0x573e87[_0x3ffd3e(0x1f8)],'isScoped':![],'scopedFolderPath':''};}return{'type':'error','errorCode':_0x3ffd3e(0x1ea),'message':_0x3ffd3e(0x210)+_0x40afe0,'arg':_0x40afe0,'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 _0x848e95=calculateScopedPath(_0x38382d,_0x2fea41['configDir']);return{'type':_0x3ffd3e(0x1f4),'parentName':_0x2fea41[_0x3ffd3e(0x1fd)],'targetDir':_0x2fea41[_0x3ffd3e(0x1fa)],'configRoot':_0x2fea41['configDir'],'filePath':_0x231a1b,'resourceName':_0x573e87[_0x3ffd3e(0x1e5)],'folderPath':_0x573e87[_0x3ffd3e(0x200)],'resourceType':_0x573e87['resourceType'],'isScoped':_0x848e95['isScoped'],'scopedFolderPath':_0x848e95[_0x3ffd3e(0x1e9)]};}catch(_0x51b847){const _0x50de75=_0x51b847 instanceof Error?_0x51b847['message']:String(_0x51b847);if(_0x50de75['includes'](_0x3ffd3e(0x1ee)))return{'type':_0x3ffd3e(0x1f2),'errorCode':_0x3ffd3e(0x216),'message':_0x3ffd3e(0x1f7)+_0x40afe0,'arg':_0x40afe0};if(_0x50de75[_0x3ffd3e(0x1e7)]('No\x20tdx.json\x20found')){if(_0x19000d){const _0x2b838b=a157_0x3f2589[_0x3ffd3e(0x20e)](_0x40afe0);if(await fs[_0x3ffd3e(0x20f)](_0x2b838b)){const _0x21a636=a157_0x3f2589[_0x3ffd3e(0x211)](_0x2b838b),_0x1a013f=await fs[_0x3ffd3e(0x20b)](_0x2b838b),_0x5513eb=_0x1a013f['match'](/^name:\s*["']?([^"'\n]+)["']?/m),_0x33284f=_0x1a013f[_0x3ffd3e(0x1f3)](/^type:\s*["']?([^"'\n]+)["']?/m),_0x3318a3=_0x5513eb?_0x5513eb[0x1]['trim']():a157_0x3f2589[_0x3ffd3e(0x205)](_0x40afe0,a157_0x3f2589[_0x3ffd3e(0x1f6)](_0x40afe0)),_0x38b8c7=_0x33284f&&_0x33284f[0x1][_0x3ffd3e(0x1fc)]()===_0x3ffd3e(0x207)?'journey':'segment';return{'type':_0x3ffd3e(0x1f4),'parentName':_0x19000d,'targetDir':_0x21a636,'configRoot':_0x21a636,'filePath':_0x2b838b,'resourceName':_0x3318a3,'folderPath':'','resourceType':_0x38b8c7,'isScoped':![],'scopedFolderPath':''};}}return{'type':'error','errorCode':_0x3ffd3e(0x1ea),'message':_0x3ffd3e(0x210)+_0x40afe0,'arg':_0x40afe0,'helpText':_0x3ffd3e(0x1e6)};}return{'type':_0x3ffd3e(0x1f2),'errorCode':'invalid_yaml','message':_0x50de75,'arg':_0x40afe0};}if(_0x40afe0){const _0x14f06a=a157_0x3f2589[_0x3ffd3e(0x20e)](cwd,_0x40afe0);let _0x42a152=null;try{_0x42a152=await fs[_0x3ffd3e(0x217)](_0x14f06a);}catch{}if(_0x42a152?.['isDirectory']()){const _0x5a6533=await findTdxConfigAsync(_0x14f06a,fs);if(_0x5a6533){const _0x2b13c8=calculateScopedPath(_0x14f06a,_0x5a6533[_0x3ffd3e(0x1fa)]);return{'type':_0x3ffd3e(0x204),'parentName':_0x5a6533[_0x3ffd3e(0x1fd)],'targetDir':_0x14f06a,'configRoot':_0x5a6533['configDir'],'isScoped':_0x2b13c8[_0x3ffd3e(0x209)],'scopedFolderPath':_0x2b13c8[_0x3ffd3e(0x1e9)]};}if(_0x19000d)return{'type':_0x3ffd3e(0x204),'parentName':_0x19000d,'targetDir':_0x14f06a,'configRoot':_0x14f06a,'isScoped':![],'scopedFolderPath':''};return{'type':_0x3ffd3e(0x1f2),'errorCode':_0x3ffd3e(0x1ea),'message':_0x3ffd3e(0x1ef)+_0x40afe0,'arg':_0x40afe0,'helpText':_0x3ffd3e(0x1e6)};}if(_0x42a152?.[_0x3ffd3e(0x202)]())return{'type':_0x3ffd3e(0x1f2),'errorCode':_0x3ffd3e(0x203),'message':_0x3ffd3e(0x1fe)+_0x40afe0,'arg':_0x40afe0,'helpText':_0x3ffd3e(0x1f9)};const _0x532199=sanitizeFileName(_0x40afe0),_0x20d6aa=getSegmentRootDir(_0x532199,cwd);return{'type':_0x3ffd3e(0x20d),'parentName':_0x40afe0,'targetDir':_0x20d6aa,'configRoot':_0x20d6aa};}const _0xa4b7f7=await findTdxConfigAsync(cwd,fs);if(_0xa4b7f7){const _0x571c71=calculateScopedPath(cwd,_0xa4b7f7['configDir']);return{'type':_0x3ffd3e(0x1ec),'parentName':_0xa4b7f7['parentSegment'],'targetDir':cwd,'configRoot':_0xa4b7f7[_0x3ffd3e(0x1fa)],'isScoped':_0x571c71[_0x3ffd3e(0x209)],'scopedFolderPath':_0x571c71[_0x3ffd3e(0x1e9)]};}if(_0x19000d){const _0x248a4d=sanitizeFileName(_0x19000d),_0x239213=getSegmentRootDir(_0x248a4d,cwd);return{'type':_0x3ffd3e(0x1ec),'parentName':_0x19000d,'targetDir':_0x239213,'configRoot':_0x239213,'isScoped':![],'scopedFolderPath':''};}return{'type':'error','errorCode':'no_parent','message':'Parent\x20segment\x20not\x20specified','helpText':_0x3ffd3e(0x212)};}
@@ -1 +1 @@
1
- const a158_0x5e1fb0=a158_0x31c3;(function(_0x380da3,_0x4e1474){const _0x7fceb6=a158_0x31c3,_0x27eef3=_0x380da3();while(!![]){try{const _0x56d115=-parseInt(_0x7fceb6(0x10a))/0x1*(-parseInt(_0x7fceb6(0x116))/0x2)+-parseInt(_0x7fceb6(0x112))/0x3*(parseInt(_0x7fceb6(0x119))/0x4)+parseInt(_0x7fceb6(0x10c))/0x5+parseInt(_0x7fceb6(0x109))/0x6*(-parseInt(_0x7fceb6(0x110))/0x7)+parseInt(_0x7fceb6(0x104))/0x8+parseInt(_0x7fceb6(0x11b))/0x9+-parseInt(_0x7fceb6(0x111))/0xa*(-parseInt(_0x7fceb6(0x115))/0xb);if(_0x56d115===_0x4e1474)break;else _0x27eef3['push'](_0x27eef3['shift']());}catch(_0x4659ff){_0x27eef3['push'](_0x27eef3['shift']());}}}(a158_0x45e7,0x54d11));import{existsSync,readFileSync}from'fs';import a158_0x4fd49b from'path';const TDX_CONFIG_FILE=a158_0x5e1fb0(0x10d),SEGMENTS_DIR='segments';export function findTdxConfigPath(_0x3e4587=process[a158_0x5e1fb0(0x113)]()){const _0x373e90=a158_0x5e1fb0;let _0x118535=a158_0x4fd49b[_0x373e90(0x10f)](_0x3e4587);const _0x5edcb6=a158_0x4fd49b[_0x373e90(0x103)](_0x118535)[_0x373e90(0x106)];while(_0x118535!==_0x5edcb6){const _0x4a3fb3=a158_0x4fd49b[_0x373e90(0x108)](_0x118535,TDX_CONFIG_FILE);if(existsSync(_0x4a3fb3))return _0x4a3fb3;_0x118535=a158_0x4fd49b[_0x373e90(0x11e)](_0x118535);}return null;}export function loadTdxConfig(_0x440f2c){const _0x4b0a1b=a158_0x5e1fb0,_0x36734e=readFileSync(_0x440f2c,_0x4b0a1b(0x105));let _0x66895e;try{_0x66895e=JSON[_0x4b0a1b(0x103)](_0x36734e);}catch{throw new Error(_0x4b0a1b(0x11a)+_0x440f2c);}if(!_0x66895e||typeof _0x66895e!=='object')throw new Error(_0x4b0a1b(0x10b));const _0x5921da=_0x66895e,_0x18d678=_0x5921da[_0x4b0a1b(0x11f)]&&typeof _0x5921da[_0x4b0a1b(0x11f)]==='string',_0x17d52d=_0x5921da[_0x4b0a1b(0x11c)]&&typeof _0x5921da[_0x4b0a1b(0x11c)]===_0x4b0a1b(0x11d);if(!_0x18d678&&!_0x17d52d)throw new Error(_0x4b0a1b(0x117));const _0x540cf0={};return _0x18d678&&(_0x540cf0['parent_segment']=_0x5921da['parent_segment']),_0x17d52d&&(_0x540cf0['engage_workspace']=_0x5921da[_0x4b0a1b(0x11c)]),_0x540cf0;}function a158_0x45e7(){const _0x4a2cc7=['utf-8','root','No\x20tdx.json\x20found.\x20Please\x20run\x20\x27tdx\x20sg\x20pull\x20<parent_segment>\x27\x20first\x20to\x20create\x20the\x20folder\x20structure.','join','1218XOSxvN','306JIfDXz','Invalid\x20tdx.json:\x20expected\x20object','440775RfIHGf','tdx.json','replace','resolve','16086afTnIq','130ElpuhN','18bdZJUo','cwd','startsWith','130229JlTBRL','784RUzFLm','Invalid\x20tdx.json:\x20must\x20contain\x20\x27parent_segment\x27\x20or\x20\x27engage_workspace\x27\x20field','stringify','391604NRkSwV','Invalid\x20JSON\x20in\x20','5368752gRdCFc','engage_workspace','string','dirname','parent_segment','parse','3542136QmlBqR'];a158_0x45e7=function(){return _0x4a2cc7;};return a158_0x45e7();}export function findTdxConfig(_0x35ec62=process[a158_0x5e1fb0(0x113)]()){const _0x636f68=a158_0x5e1fb0,_0xd8496=findTdxConfigPath(_0x35ec62);if(!_0xd8496)throw new Error(_0x636f68(0x107));const _0x47f1cb=loadTdxConfig(_0xd8496),_0x2b74a8=a158_0x4fd49b['dirname'](_0xd8496);return{'config':_0x47f1cb,'configPath':_0xd8496,'configDir':_0x2b74a8};}export function tryFindTdxConfig(_0x2e2068){try{return findTdxConfig(_0x2e2068);}catch{return null;}}export function getSegmentRootDir(_0x300944,_0x3a19e=process[a158_0x5e1fb0(0x113)]()){return a158_0x4fd49b['join'](_0x3a19e,SEGMENTS_DIR,_0x300944);}export function getTdxConfigPath(_0x480f40,_0x2592c3=process[a158_0x5e1fb0(0x113)]()){const _0x166eee=a158_0x5e1fb0;return a158_0x4fd49b[_0x166eee(0x108)](getSegmentRootDir(_0x480f40,_0x2592c3),TDX_CONFIG_FILE);}export function getRelativePathFromConfig(_0x2c7df1,_0x4c72e4){const _0x5a669c=a158_0x5e1fb0,_0x191c38=a158_0x4fd49b[_0x5a669c(0x10f)](_0x2c7df1),_0x4e87c6=a158_0x4fd49b['relative'](_0x4c72e4,_0x191c38);if(_0x4e87c6[_0x5a669c(0x114)]('..'))return'';return _0x4e87c6;}export function localPathToTdFolderPath(_0x1d8105){const _0x27152f=a158_0x5e1fb0,_0xf57c17=a158_0x4fd49b['dirname'](_0x1d8105);if(_0xf57c17==='.'||_0xf57c17==='')return'';return _0xf57c17[_0x27152f(0x10e)](/\\/g,'/');}function a158_0x31c3(_0x55e878,_0x1ab161){_0x55e878=_0x55e878-0x103;const _0x45e74c=a158_0x45e7();let _0x31c341=_0x45e74c[_0x55e878];return _0x31c341;}export function tdFolderPathToLocalPath(_0x406ae4,_0x1e7c45){const _0x4b8e2d=a158_0x5e1fb0;if(!_0x406ae4)return _0x1e7c45;return a158_0x4fd49b[_0x4b8e2d(0x108)](_0x1e7c45,_0x406ae4);}export function createTdxConfigContent(_0x37b3ea){const _0x4ea139=a158_0x5e1fb0,_0x2fa553={'parent_segment':_0x37b3ea};return JSON[_0x4ea139(0x118)](_0x2fa553,null,0x2)+'\x0a';}export function createEngageTdxConfigContent(_0x2d3888){const _0x1b8e9a=a158_0x5e1fb0,_0x497cec={'engage_workspace':_0x2d3888};return JSON[_0x1b8e9a(0x118)](_0x497cec,null,0x2)+'\x0a';}
1
+ function a158_0x549e(){const _0x26d003=['resolve','stringify','replace','join','tdx.json','cwd','parent_segment','object','utf-8','engage_workspace','18HqqHMd','36RCwGEn','Invalid\x20tdx.json:\x20must\x20contain\x20\x27parent_segment\x27\x20or\x20\x27engage_workspace\x27\x20field','1zqjQHr','469976bhIQzk','776854nNEIde','1989490ioTNAQ','dirname','40681692hDBQwz','parse','3jtsmPD','root','133zXBCaV','relative','Invalid\x20tdx.json:\x20expected\x20object','string','895892UGZhdn','8191733QBgFhW','2694605kpbLPZ'];a158_0x549e=function(){return _0x26d003;};return a158_0x549e();}const a158_0x3674a0=a158_0x218f;(function(_0x347d7c,_0x32a788){const _0x327cf7=a158_0x218f,_0x3376dd=_0x347d7c();while(!![]){try{const _0x102cc1=-parseInt(_0x327cf7(0xf4))/0x1*(-parseInt(_0x327cf7(0xf6))/0x2)+parseInt(_0x327cf7(0xfb))/0x3*(-parseInt(_0x327cf7(0x101))/0x4)+-parseInt(_0x327cf7(0xe6))/0x5*(parseInt(_0x327cf7(0xf1))/0x6)+-parseInt(_0x327cf7(0xfd))/0x7*(parseInt(_0x327cf7(0xf5))/0x8)+-parseInt(_0x327cf7(0xf2))/0x9*(-parseInt(_0x327cf7(0xf7))/0xa)+-parseInt(_0x327cf7(0x102))/0xb+parseInt(_0x327cf7(0xf9))/0xc;if(_0x102cc1===_0x32a788)break;else _0x3376dd['push'](_0x3376dd['shift']());}catch(_0xfb0b75){_0x3376dd['push'](_0x3376dd['shift']());}}}(a158_0x549e,0xd511c));import{existsSync,readFileSync}from'fs';import a158_0x5d567e from'path';const TDX_CONFIG_FILE=a158_0x3674a0(0xeb),SEGMENTS_DIR='segments';export function findTdxConfigPath(_0x570f4a=process[a158_0x3674a0(0xec)]()){const _0x2f934a=a158_0x3674a0;let _0x5a7f08=a158_0x5d567e[_0x2f934a(0xe7)](_0x570f4a);const _0x2b2b60=a158_0x5d567e[_0x2f934a(0xfa)](_0x5a7f08)[_0x2f934a(0xfc)];while(_0x5a7f08!==_0x2b2b60){const _0xddfc4f=a158_0x5d567e[_0x2f934a(0xea)](_0x5a7f08,TDX_CONFIG_FILE);if(existsSync(_0xddfc4f))return _0xddfc4f;_0x5a7f08=a158_0x5d567e[_0x2f934a(0xf8)](_0x5a7f08);}return null;}export function loadTdxConfig(_0x3704c2){const _0x113a76=a158_0x3674a0,_0x1dbd48=readFileSync(_0x3704c2,_0x113a76(0xef));let _0x3d32ad;try{_0x3d32ad=JSON[_0x113a76(0xfa)](_0x1dbd48);}catch{throw new Error('Invalid\x20JSON\x20in\x20'+_0x3704c2);}if(!_0x3d32ad||typeof _0x3d32ad!==_0x113a76(0xee))throw new Error(_0x113a76(0xff));const _0x32914f=_0x3d32ad,_0x3a074b=_0x32914f['parent_segment']&&typeof _0x32914f[_0x113a76(0xed)]==='string',_0x1cce14=_0x32914f[_0x113a76(0xf0)]&&typeof _0x32914f[_0x113a76(0xf0)]===_0x113a76(0x100);if(!_0x3a074b&&!_0x1cce14)throw new Error(_0x113a76(0xf3));const _0x38780a={};return _0x3a074b&&(_0x38780a[_0x113a76(0xed)]=_0x32914f[_0x113a76(0xed)]),_0x1cce14&&(_0x38780a[_0x113a76(0xf0)]=_0x32914f['engage_workspace']),_0x38780a;}export function findTdxConfig(_0xe023e6=process['cwd']()){const _0x2c83f7=findTdxConfigPath(_0xe023e6);if(!_0x2c83f7)throw new Error('No\x20tdx.json\x20found.\x20Please\x20run\x20\x27tdx\x20sg\x20pull\x20<parent_segment>\x27\x20first\x20to\x20create\x20the\x20folder\x20structure.');const _0x28b6f5=loadTdxConfig(_0x2c83f7),_0x48e5e6=a158_0x5d567e['dirname'](_0x2c83f7);return{'config':_0x28b6f5,'configPath':_0x2c83f7,'configDir':_0x48e5e6};}function a158_0x218f(_0x4ae05a,_0x9b1889){_0x4ae05a=_0x4ae05a-0xe6;const _0x549ee1=a158_0x549e();let _0x218ff2=_0x549ee1[_0x4ae05a];return _0x218ff2;}export function tryFindTdxConfig(_0x5f1328){try{return findTdxConfig(_0x5f1328);}catch{return null;}}export function getSegmentRootDir(_0x7f172a,_0x38fd44=process[a158_0x3674a0(0xec)]()){const _0xcc10a6=a158_0x3674a0;return a158_0x5d567e[_0xcc10a6(0xea)](_0x38fd44,SEGMENTS_DIR,_0x7f172a);}export function getTdxConfigPath(_0x17ad7c,_0x1afde5=process[a158_0x3674a0(0xec)]()){return a158_0x5d567e['join'](getSegmentRootDir(_0x17ad7c,_0x1afde5),TDX_CONFIG_FILE);}export function getRelativePathFromConfig(_0x37d4af,_0x18ef04){const _0xcfee15=a158_0x3674a0,_0x324f65=a158_0x5d567e[_0xcfee15(0xe7)](_0x37d4af),_0x3541eb=a158_0x5d567e[_0xcfee15(0xfe)](_0x18ef04,_0x324f65);if(_0x3541eb['startsWith']('..'))return'';return _0x3541eb;}export function localPathToTdFolderPath(_0x16a35d){const _0x23dbd8=a158_0x3674a0,_0xbc8be0=a158_0x5d567e[_0x23dbd8(0xf8)](_0x16a35d);if(_0xbc8be0==='.'||_0xbc8be0==='')return'';return _0xbc8be0[_0x23dbd8(0xe9)](/\\/g,'/');}export function tdFolderPathToLocalPath(_0x258a28,_0x4578de){if(!_0x258a28)return _0x4578de;return a158_0x5d567e['join'](_0x4578de,_0x258a28);}export function createTdxConfigContent(_0x5dab05){const _0x426f59={'parent_segment':_0x5dab05};return JSON['stringify'](_0x426f59,null,0x2)+'\x0a';}export function createEngageTdxConfigContent(_0x32b927){const _0x28a2e6=a158_0x3674a0,_0x54f62c={'engage_workspace':_0x32b927};return JSON[_0x28a2e6(0xe8)](_0x54f62c,null,0x2)+'\x0a';}
@@ -1 +1 @@
1
- const a159_0x1bb815=a159_0x4d0f;function a159_0x1203(){const _0x41483d=['none','optional','11eWAaGk','69656kJFSjS','16209MhNnyX','record','asc','nullable','weekly','min','7hogSsJ','object','array','daily','All','enum','Last','monthly','75749DRfczy','boolean','clear','string','masked','minutes_interval','desc','3954102zejHJs','once','Top-N','rows','number','2664bnBPov','48561QrvYhj','minute','day','12124730CcJImG','onFailure','cron','First','cols','onSuccess','6LLoWfX','hourly','Connection\x20name\x20is\x20required','11579976JfmNCn','150YkjCWq'];a159_0x1203=function(){return _0x41483d;};return a159_0x1203();}(function(_0x5c311b,_0x20cb63){const _0x17a8b7=a159_0x4d0f,_0x27d404=_0x5c311b();while(!![]){try{const _0x319359=-parseInt(_0x17a8b7(0x112))/0x1+parseInt(_0x17a8b7(0xfb))/0x2*(-parseInt(_0x17a8b7(0x11f))/0x3)+-parseInt(_0x17a8b7(0x103))/0x4*(parseInt(_0x17a8b7(0xff))/0x5)+parseInt(_0x17a8b7(0x119))/0x6*(parseInt(_0x17a8b7(0x10a))/0x7)+-parseInt(_0x17a8b7(0x11e))/0x8*(-parseInt(_0x17a8b7(0x104))/0x9)+parseInt(_0x17a8b7(0x122))/0xa*(parseInt(_0x17a8b7(0x102))/0xb)+-parseInt(_0x17a8b7(0xfe))/0xc;if(_0x319359===_0x20cb63)break;else _0x27d404['push'](_0x27d404['shift']());}catch(_0x4b74ee){_0x27d404['push'](_0x27d404['shift']());}}}(a159_0x1203,0xd1d67));import{z}from'zod';export const ScheduleTypeSchema=z['enum']([a159_0x1bb815(0x100),a159_0x1bb815(0xfc),a159_0x1bb815(0x10d),a159_0x1bb815(0x108),a159_0x1bb815(0x111),a159_0x1bb815(0x124),a159_0x1bb815(0x117)]);export const RepeatUnitSchema=z['enum']([a159_0x1bb815(0x120),'hour',a159_0x1bb815(0x121),'week','month',a159_0x1bb815(0x11a),'none']);export const ScheduleDefSchema=z['object']({'type':ScheduleTypeSchema['optional'](),'repeat_unit':RepeatUnitSchema[a159_0x1bb815(0x101)](),'repeat_frequency':z[a159_0x1bb815(0x11d)]()['optional'](),'repeat_sub_frequency':z[a159_0x1bb815(0x10c)](z[a159_0x1bb815(0x11d)]())[a159_0x1bb815(0x101)](),'start_at':z[a159_0x1bb815(0x115)]()[a159_0x1bb815(0x107)]()[a159_0x1bb815(0x101)](),'end_on':z[a159_0x1bb815(0x115)]()['nullable']()[a159_0x1bb815(0x101)](),'timezone':z[a159_0x1bb815(0x115)]()['optional']()});function a159_0x4d0f(_0x191778,_0x4ef0ac){_0x191778=_0x191778-0xfa;const _0x1203c6=a159_0x1203();let _0x4d0fbf=_0x1203c6[_0x191778];return _0x4d0fbf;}export const NotificationDefSchema=z[a159_0x1bb815(0x10b)]({'notify_on':z[a159_0x1bb815(0x10c)](z[a159_0x1bb815(0x10f)]([a159_0x1bb815(0xfa),a159_0x1bb815(0x123)]))['optional'](),'email_recipients':z[a159_0x1bb815(0x10c)](z[a159_0x1bb815(0x115)]())[a159_0x1bb815(0x101)]()});export const ActivationColumnDefSchema=z['union']([z[a159_0x1bb815(0x115)](),z['object']({'name':z[a159_0x1bb815(0x115)](),'type':z[a159_0x1bb815(0x115)]()[a159_0x1bb815(0x101)](),'visibility':z[a159_0x1bb815(0x10f)](['clear',a159_0x1bb815(0x116)])[a159_0x1bb815(0x101)]()})]);export const ActivationBehaviorDefSchema=z['object']({'columns':z[a159_0x1bb815(0x10c)](z['object']({'name':z[a159_0x1bb815(0x115)](),'type':z[a159_0x1bb815(0x115)]()[a159_0x1bb815(0x101)](),'visibility':z[a159_0x1bb815(0x10f)]([a159_0x1bb815(0x114),a159_0x1bb815(0x116)])[a159_0x1bb815(0x101)]()}))[a159_0x1bb815(0x101)](),'behavior_table':z[a159_0x1bb815(0x115)]()[a159_0x1bb815(0x101)](),'join_row':z[a159_0x1bb815(0x11d)]()[a159_0x1bb815(0x107)]()[a159_0x1bb815(0x101)](),'join_strategy':z[a159_0x1bb815(0x10f)]([a159_0x1bb815(0x10e),a159_0x1bb815(0x125),a159_0x1bb815(0x110),a159_0x1bb815(0x11b)])[a159_0x1bb815(0x101)](),'formatting':z[a159_0x1bb815(0x10f)]([a159_0x1bb815(0x11c),a159_0x1bb815(0x126)])[a159_0x1bb815(0x101)](),'order_by':z[a159_0x1bb815(0x10c)](z['object']({'key':z[a159_0x1bb815(0x115)](),'order':z[a159_0x1bb815(0x10f)]([a159_0x1bb815(0x106),a159_0x1bb815(0x118)])}))[a159_0x1bb815(0x101)]()});export const ActivationDefSchema=z[a159_0x1bb815(0x10b)]({'name':z['string']()[a159_0x1bb815(0x109)](0x1,'Activation\x20name\x20is\x20required'),'description':z[a159_0x1bb815(0x115)]()[a159_0x1bb815(0x101)](),'connection':z[a159_0x1bb815(0x115)]()[a159_0x1bb815(0x109)](0x1,a159_0x1bb815(0xfd)),'all_columns':z[a159_0x1bb815(0x113)]()[a159_0x1bb815(0x101)](),'columns':z[a159_0x1bb815(0x10c)](ActivationColumnDefSchema)['optional'](),'schedule':ScheduleDefSchema[a159_0x1bb815(0x101)](),'notification':NotificationDefSchema['optional'](),'connector_config':z[a159_0x1bb815(0x105)](z[a159_0x1bb815(0x115)](),z['unknown']())[a159_0x1bb815(0x101)](),'activation_template_id':z['string']()['nullable']()['optional'](),'behavior':ActivationBehaviorDefSchema[a159_0x1bb815(0x107)]()['optional'](),'run_after_journey_refresh':z[a159_0x1bb815(0x113)]()[a159_0x1bb815(0x101)](),'nested_workflow_project_name':z[a159_0x1bb815(0x115)]()[a159_0x1bb815(0x101)](),'nested_workflow_name':z[a159_0x1bb815(0x115)]()['optional'](),'lock_enabled':z[a159_0x1bb815(0x113)]()[a159_0x1bb815(0x101)]()});
1
+ const a159_0x461558=a159_0x3da3;(function(_0x5e48f2,_0x2dec11){const _0x478228=a159_0x3da3,_0x11e893=_0x5e48f2();while(!![]){try{const _0x5293c8=-parseInt(_0x478228(0x114))/0x1*(-parseInt(_0x478228(0x113))/0x2)+parseInt(_0x478228(0x11c))/0x3*(parseInt(_0x478228(0x12b))/0x4)+parseInt(_0x478228(0x130))/0x5+-parseInt(_0x478228(0x10f))/0x6*(parseInt(_0x478228(0x125))/0x7)+parseInt(_0x478228(0x11b))/0x8+parseInt(_0x478228(0x134))/0x9+-parseInt(_0x478228(0x12f))/0xa*(parseInt(_0x478228(0x11d))/0xb);if(_0x5293c8===_0x2dec11)break;else _0x11e893['push'](_0x11e893['shift']());}catch(_0x870fda){_0x11e893['push'](_0x11e893['shift']());}}}(a159_0x246d,0x42af7));function a159_0x246d(){const _0x1b33df=['12664Tfvqjw','union','optional','min','3160ZcysXH','2546535rYXSBj','day','object','First','1165275aRPjSl','All','record','monthly','array','number','string','78dWHXcO','unknown','Activation\x20name\x20is\x20required','masked','143510aZoddC','1MIrqKC','Connection\x20name\x20is\x20required','weekly','Top-N','rows','clear','enum','907288ZNbuIe','423DyZmAA','21219gRwLQO','daily','onFailure','Last','minute','cron','minutes_interval','hour','208733omAzQX','hourly','asc','nullable','desc','boolean'];a159_0x246d=function(){return _0x1b33df;};return a159_0x246d();}import{z}from'zod';export const ScheduleTypeSchema=z['enum'](['none',a159_0x461558(0x126),a159_0x461558(0x11e),a159_0x461558(0x116),a159_0x461558(0x137),a159_0x461558(0x122),a159_0x461558(0x123)]);export const RepeatUnitSchema=z[a159_0x461558(0x11a)]([a159_0x461558(0x121),a159_0x461558(0x124),a159_0x461558(0x131),'week','month','once','none']);export const ScheduleDefSchema=z[a159_0x461558(0x132)]({'type':ScheduleTypeSchema[a159_0x461558(0x12d)](),'repeat_unit':RepeatUnitSchema[a159_0x461558(0x12d)](),'repeat_frequency':z['number']()[a159_0x461558(0x12d)](),'repeat_sub_frequency':z[a159_0x461558(0x10c)](z['number']())['optional'](),'start_at':z[a159_0x461558(0x10e)]()[a159_0x461558(0x128)]()[a159_0x461558(0x12d)](),'end_on':z[a159_0x461558(0x10e)]()[a159_0x461558(0x128)]()['optional'](),'timezone':z['string']()['optional']()});function a159_0x3da3(_0x41ae94,_0x11b295){_0x41ae94=_0x41ae94-0x10c;const _0x246dde=a159_0x246d();let _0x3da3a7=_0x246dde[_0x41ae94];return _0x3da3a7;}export const NotificationDefSchema=z[a159_0x461558(0x132)]({'notify_on':z['array'](z[a159_0x461558(0x11a)](['onSuccess',a159_0x461558(0x11f)]))[a159_0x461558(0x12d)](),'email_recipients':z[a159_0x461558(0x10c)](z[a159_0x461558(0x10e)]())['optional']()});export const ActivationColumnDefSchema=z[a159_0x461558(0x12c)]([z[a159_0x461558(0x10e)](),z[a159_0x461558(0x132)]({'name':z[a159_0x461558(0x10e)](),'type':z[a159_0x461558(0x10e)]()['optional'](),'visibility':z['enum']([a159_0x461558(0x119),'masked'])[a159_0x461558(0x12d)]()})]);export const ActivationBehaviorDefSchema=z[a159_0x461558(0x132)]({'columns':z[a159_0x461558(0x10c)](z[a159_0x461558(0x132)]({'name':z[a159_0x461558(0x10e)](),'type':z['string']()[a159_0x461558(0x12d)](),'visibility':z[a159_0x461558(0x11a)]([a159_0x461558(0x119),a159_0x461558(0x112)])[a159_0x461558(0x12d)]()}))[a159_0x461558(0x12d)](),'behavior_table':z[a159_0x461558(0x10e)]()[a159_0x461558(0x12d)](),'join_row':z[a159_0x461558(0x10d)]()[a159_0x461558(0x128)]()[a159_0x461558(0x12d)](),'join_strategy':z[a159_0x461558(0x11a)]([a159_0x461558(0x135),a159_0x461558(0x133),a159_0x461558(0x120),a159_0x461558(0x117)])[a159_0x461558(0x12d)](),'formatting':z[a159_0x461558(0x11a)]([a159_0x461558(0x118),'cols'])['optional'](),'order_by':z[a159_0x461558(0x10c)](z[a159_0x461558(0x132)]({'key':z[a159_0x461558(0x10e)](),'order':z['enum']([a159_0x461558(0x127),a159_0x461558(0x129)])}))[a159_0x461558(0x12d)]()});export const ActivationDefSchema=z[a159_0x461558(0x132)]({'name':z[a159_0x461558(0x10e)]()[a159_0x461558(0x12e)](0x1,a159_0x461558(0x111)),'description':z[a159_0x461558(0x10e)]()['optional'](),'connection':z[a159_0x461558(0x10e)]()[a159_0x461558(0x12e)](0x1,a159_0x461558(0x115)),'all_columns':z[a159_0x461558(0x12a)]()['optional'](),'columns':z[a159_0x461558(0x10c)](ActivationColumnDefSchema)[a159_0x461558(0x12d)](),'schedule':ScheduleDefSchema[a159_0x461558(0x12d)](),'notification':NotificationDefSchema[a159_0x461558(0x12d)](),'connector_config':z[a159_0x461558(0x136)](z[a159_0x461558(0x10e)](),z[a159_0x461558(0x110)]())['optional'](),'activation_template_id':z[a159_0x461558(0x10e)]()[a159_0x461558(0x128)]()[a159_0x461558(0x12d)](),'behavior':ActivationBehaviorDefSchema['nullable']()[a159_0x461558(0x12d)](),'run_after_journey_refresh':z[a159_0x461558(0x12a)]()[a159_0x461558(0x12d)](),'nested_workflow_project_name':z[a159_0x461558(0x10e)]()[a159_0x461558(0x12d)](),'nested_workflow_name':z[a159_0x461558(0x10e)]()[a159_0x461558(0x12d)](),'lock_enabled':z[a159_0x461558(0x12a)]()[a159_0x461558(0x12d)]()});
@@ -1 +1 @@
1
- (function(_0xa49fc5,_0xa17145){var _0x29fd86=a160_0x31f5,_0x56c3d7=_0xa49fc5();while(!![]){try{var _0x442d65=parseInt(_0x29fd86(0x138))/0x1+parseInt(_0x29fd86(0x132))/0x2*(-parseInt(_0x29fd86(0x130))/0x3)+-parseInt(_0x29fd86(0x133))/0x4+parseInt(_0x29fd86(0x139))/0x5+-parseInt(_0x29fd86(0x137))/0x6*(parseInt(_0x29fd86(0x134))/0x7)+parseInt(_0x29fd86(0x135))/0x8+parseInt(_0x29fd86(0x136))/0x9*(parseInt(_0x29fd86(0x131))/0xa);if(_0x442d65===_0xa17145)break;else _0x56c3d7['push'](_0x56c3d7['shift']());}catch(_0x123e16){_0x56c3d7['push'](_0x56c3d7['shift']());}}}(a160_0x61aa,0xbe6cd));function a160_0x31f5(_0x1c55c2,_0x1f8858){_0x1c55c2=_0x1c55c2-0x130;var _0x61aae0=a160_0x61aa();var _0x31f511=_0x61aae0[_0x1c55c2];return _0x31f511;}function a160_0x61aa(){var _0x351c7e=['2405520kTAKrD','11980620pZGPpm','714hiWSxI','313925EhSjCF','6612355ieStgJ','199497dFyZNX','10LgBZho','26mHdPjE','2492508HzZpNr','58863LdYFon'];a160_0x61aa=function(){return _0x351c7e;};return a160_0x61aa();}export{JourneyStateTypeSchema,ReentryModeTypeSchema,WaitUnitTypeSchema,StepTypeValueSchema,EmbeddedSegmentDefSchema,CriteriaDefSchema,StepDefSchema,StageDefSchema,JourneyEntryDefSchema,JourneyDefSchema}from'./journey-schema.js';
1
+ (function(_0x56d8e5,_0xcbd336){var _0x2aff4d=a160_0x1b83,_0x283285=_0x56d8e5();while(!![]){try{var _0x363cfc=-parseInt(_0x2aff4d(0x1a4))/0x1+-parseInt(_0x2aff4d(0x1a0))/0x2+parseInt(_0x2aff4d(0x1a9))/0x3*(parseInt(_0x2aff4d(0x1a3))/0x4)+parseInt(_0x2aff4d(0x1a5))/0x5*(-parseInt(_0x2aff4d(0x1a2))/0x6)+parseInt(_0x2aff4d(0x1a8))/0x7+parseInt(_0x2aff4d(0x1a1))/0x8*(parseInt(_0x2aff4d(0x19f))/0x9)+-parseInt(_0x2aff4d(0x1a7))/0xa*(-parseInt(_0x2aff4d(0x1a6))/0xb);if(_0x363cfc===_0xcbd336)break;else _0x283285['push'](_0x283285['shift']());}catch(_0x2e3e04){_0x283285['push'](_0x283285['shift']());}}}(a160_0x2b28,0xad3c8));function a160_0x1b83(_0x522db0,_0x2f21c4){_0x522db0=_0x522db0-0x19f;var _0x2b281b=a160_0x2b28();var _0x1b8395=_0x2b281b[_0x522db0];return _0x1b8395;}export{JourneyStateTypeSchema,ReentryModeTypeSchema,WaitUnitTypeSchema,StepTypeValueSchema,EmbeddedSegmentDefSchema,CriteriaDefSchema,StepDefSchema,StageDefSchema,JourneyEntryDefSchema,JourneyDefSchema}from'./journey-schema.js';function a160_0x2b28(){var _0x657a48=['278965BVgABL','1859edlBzi','31720vgSeUR','4506117vnHyzc','1023RngegI','1099611ISiaDO','420730BfsHUm','24Ybqhyc','54XyCNZO','11812ZdTCZq','1131231iAWNfn'];a160_0x2b28=function(){return _0x657a48;};return a160_0x2b28();}
@@ -1 +1 @@
1
- const a161_0x3be2e1=a161_0x5e81;(function(_0x36d51f,_0x17fef2){const _0x1080ad=a161_0x5e81,_0xd7fcb=_0x36d51f();while(!![]){try{const _0x44b0c7=parseInt(_0x1080ad(0x9d))/0x1*(-parseInt(_0x1080ad(0x94))/0x2)+-parseInt(_0x1080ad(0xaf))/0x3*(parseInt(_0x1080ad(0x99))/0x4)+-parseInt(_0x1080ad(0x90))/0x5+-parseInt(_0x1080ad(0x9a))/0x6+parseInt(_0x1080ad(0x9b))/0x7*(-parseInt(_0x1080ad(0xb2))/0x8)+parseInt(_0x1080ad(0xb6))/0x9*(-parseInt(_0x1080ad(0xaa))/0xa)+parseInt(_0x1080ad(0xb3))/0xb;if(_0x44b0c7===_0x17fef2)break;else _0xd7fcb['push'](_0xd7fcb['shift']());}catch(_0x5431d4){_0xd7fcb['push'](_0xd7fcb['shift']());}}}(a161_0x4cc8,0x619e1));import{z}from'zod';import{RuleDefSchema}from'./segment-schema.js';import{ActivationDefSchema}from'./activation-schema.js';export const JourneyStateTypeSchema=z[a161_0x3be2e1(0x9c)]([a161_0x3be2e1(0xb9),a161_0x3be2e1(0xa0),a161_0x3be2e1(0x98)]);export const ReentryModeTypeSchema=z['enum'](['no_reentry','reentry_unless_goal_achieved',a161_0x3be2e1(0x9e)]);function a161_0x4cc8(){const _0x232831=['54yCUQtc','isArray','type','draft','decision_point','ab_test','541720wMnKrF','journey','object','lazy','14gaAUts','jump','merge','string','launched','24cyMoTQ','3507762ACrxgL','1631EOITfo','enum','97915mOPJiG','reentry_always','end','simulation','journeys','wait','Journey\x20name\x20is\x20required','versions','week','refine','stages','boolean','filter','1134130YAufIE','optional','array','activation','literal','112452tcbPHW','record','passthrough','7472NImpdj','31913431vtJbZp','number','length'];a161_0x4cc8=function(){return _0x232831;};return a161_0x4cc8();}export const WaitUnitTypeSchema=z['enum'](['day',a161_0x3be2e1(0xa5)]);export const StepTypeValueSchema=z['enum']([a161_0x3be2e1(0xa2),a161_0x3be2e1(0xad),a161_0x3be2e1(0xba),'ab_test',a161_0x3be2e1(0x96),a161_0x3be2e1(0x95),a161_0x3be2e1(0x9f)]);function a161_0x5e81(_0x5e522a,_0x227bc9){_0x5e522a=_0x5e522a-0x90;const _0x4cc869=a161_0x4cc8();let _0x5e810b=_0x4cc869[_0x5e522a];return _0x5e810b;}export const EmbeddedSegmentDefSchema=z[a161_0x3be2e1(0x92)]({'description':z[a161_0x3be2e1(0x97)]()[a161_0x3be2e1(0xab)](),'rule':RuleDefSchema});const JumpTargetDefSchema=z[a161_0x3be2e1(0x92)]({'journey':z[a161_0x3be2e1(0x97)](),'stage':z['string'](),'bundle_id':z['string']()[a161_0x3be2e1(0xab)]()});export const CriteriaDefSchema=z['object']({'name':z['string'](),'description':z[a161_0x3be2e1(0x97)]()['optional'](),'segment':z['string'](),'target':JumpTargetDefSchema['optional']()});const WaitConditionTimeoutDefSchema=z['object']({'duration':z[a161_0x3be2e1(0xb4)](),'unit':WaitUnitTypeSchema,'next':z[a161_0x3be2e1(0x97)]()[a161_0x3be2e1(0xab)]()}),WaitConditionDefSchema=z[a161_0x3be2e1(0x92)]({'segment':z[a161_0x3be2e1(0x97)](),'next':z['string']()['optional'](),'timeout':WaitConditionTimeoutDefSchema['optional']()}),WaitStepParamsDefSchema=z[a161_0x3be2e1(0x92)]({'duration':z[a161_0x3be2e1(0xb4)]()['optional'](),'unit':WaitUnitTypeSchema[a161_0x3be2e1(0xab)](),'wait_until':z[a161_0x3be2e1(0x97)]()[a161_0x3be2e1(0xab)](),'condition':WaitConditionDefSchema['optional'](),'days_of_week':z['array'](z['string']())[a161_0x3be2e1(0xab)]()}),StepBaseFields={'name':z['string'](),'uuid':z[a161_0x3be2e1(0x97)]()[a161_0x3be2e1(0xab)](),'next':z[a161_0x3be2e1(0x97)]()[a161_0x3be2e1(0xab)]()},WaitStepDefSchema=z[a161_0x3be2e1(0x92)]({...StepBaseFields,'type':z['literal']('wait'),'with':WaitStepParamsDefSchema}),ActivationStepParamsDefSchema=z['object']({'activation':z[a161_0x3be2e1(0x97)]()}),ActivationStepDefSchema=z[a161_0x3be2e1(0x92)]({...StepBaseFields,'type':z[a161_0x3be2e1(0xae)](a161_0x3be2e1(0xad)),'with':ActivationStepParamsDefSchema}),DecisionBranchDefSchema=z[a161_0x3be2e1(0x92)]({'name':z[a161_0x3be2e1(0x97)](),'segment':z[a161_0x3be2e1(0x97)]()['optional'](),'segment_id':z[a161_0x3be2e1(0x97)]()['optional'](),'excluded':z[a161_0x3be2e1(0xa8)]()[a161_0x3be2e1(0xab)](),'next':z['string']()['optional']()}),DecisionPointStepParamsDefSchema=z[a161_0x3be2e1(0x92)]({'branches':z[a161_0x3be2e1(0xac)](DecisionBranchDefSchema)}),DecisionPointStepDefSchema=z[a161_0x3be2e1(0x92)]({...StepBaseFields,'type':z[a161_0x3be2e1(0xae)](a161_0x3be2e1(0xba)),'with':DecisionPointStepParamsDefSchema}),AbTestVariantDefSchema=z['object']({'id':z['string']()[a161_0x3be2e1(0xab)](),'name':z[a161_0x3be2e1(0x97)](),'percentage':z[a161_0x3be2e1(0xb4)](),'next':z[a161_0x3be2e1(0x97)]()['optional']()}),AbTestStepParamsDefSchema=z[a161_0x3be2e1(0x92)]({'variants':z[a161_0x3be2e1(0xac)](AbTestVariantDefSchema),'unique_id':z[a161_0x3be2e1(0x97)]()[a161_0x3be2e1(0xab)](),'customized_split':z[a161_0x3be2e1(0xa8)]()[a161_0x3be2e1(0xab)]()}),AbTestStepDefSchema=z[a161_0x3be2e1(0x92)]({...StepBaseFields,'type':z[a161_0x3be2e1(0xae)](a161_0x3be2e1(0xbb)),'with':AbTestStepParamsDefSchema}),MergeStepDefSchema=z[a161_0x3be2e1(0x92)]({...StepBaseFields,'type':z['literal']('merge')}),JumpStepParamsDefSchema=z[a161_0x3be2e1(0x92)]({'target':JumpTargetDefSchema}),JumpStepDefSchema=z['object']({...StepBaseFields,'type':z[a161_0x3be2e1(0xae)]('jump'),'with':JumpStepParamsDefSchema}),EndStepDefSchema=z['object']({...StepBaseFields,'type':z[a161_0x3be2e1(0xae)](a161_0x3be2e1(0x9f))})[a161_0x3be2e1(0xb1)]();export const StepDefSchema=z['discriminatedUnion'](a161_0x3be2e1(0xb8),[WaitStepDefSchema,ActivationStepDefSchema,DecisionPointStepDefSchema,AbTestStepDefSchema,MergeStepDefSchema,JumpStepDefSchema,EndStepDefSchema]);export const StageDefSchema=z[a161_0x3be2e1(0x92)]({'name':z[a161_0x3be2e1(0x97)](),'description':z[a161_0x3be2e1(0x97)]()['optional'](),'id':z[a161_0x3be2e1(0x97)]()['optional'](),'entry_criteria':CriteriaDefSchema[a161_0x3be2e1(0xab)](),'exit_criteria':z['array'](CriteriaDefSchema)[a161_0x3be2e1(0xab)](),'milestone':CriteriaDefSchema[a161_0x3be2e1(0xab)](),'root_step':z[a161_0x3be2e1(0x97)]()[a161_0x3be2e1(0xab)](),'steps':z[a161_0x3be2e1(0xac)](StepDefSchema)[a161_0x3be2e1(0xab)]()});export const JourneyEntryDefSchema=z[a161_0x3be2e1(0x92)]({'name':z['string']()[a161_0x3be2e1(0xab)](),'version':z[a161_0x3be2e1(0x97)]()[a161_0x3be2e1(0xab)](),'state':JourneyStateTypeSchema[a161_0x3be2e1(0xab)](),'latest':z['boolean']()[a161_0x3be2e1(0xab)](),'stages':z[a161_0x3be2e1(0xac)](StageDefSchema),'id':z[a161_0x3be2e1(0x97)]()[a161_0x3be2e1(0xab)](),'version_number':z['number']()['optional'](),'goal':CriteriaDefSchema[a161_0x3be2e1(0xab)](),'reentry':ReentryModeTypeSchema[a161_0x3be2e1(0xab)]()});export const JourneyDefSchema=z[a161_0x3be2e1(0x93)](()=>z[a161_0x3be2e1(0x92)]({'type':z[a161_0x3be2e1(0xae)](a161_0x3be2e1(0x91)),'name':z['string']()['min'](0x1,a161_0x3be2e1(0xa3)),'description':z['string']()['optional'](),'bundle_id':z[a161_0x3be2e1(0x97)]()[a161_0x3be2e1(0xab)](),'bundle_name':z[a161_0x3be2e1(0x97)]()[a161_0x3be2e1(0xab)](),'folder_id':z[a161_0x3be2e1(0x97)]()['optional'](),'reentry':ReentryModeTypeSchema[a161_0x3be2e1(0xab)](),'allow_reentry':z[a161_0x3be2e1(0xa8)]()[a161_0x3be2e1(0xab)](),'goal':CriteriaDefSchema['optional'](),'id':z['string']()[a161_0x3be2e1(0xab)](),'version':z[a161_0x3be2e1(0x97)]()['optional'](),'version_number':z[a161_0x3be2e1(0xb4)]()[a161_0x3be2e1(0xab)](),'stages':z['array'](StageDefSchema)[a161_0x3be2e1(0xab)](),'versions':z[a161_0x3be2e1(0xac)](JourneyEntryDefSchema)[a161_0x3be2e1(0xab)](),'journeys':z['array'](JourneyEntryDefSchema)[a161_0x3be2e1(0xab)](),'segments':z[a161_0x3be2e1(0xb0)](z['string'](),EmbeddedSegmentDefSchema)['optional'](),'activations':z['record'](z[a161_0x3be2e1(0x97)](),ActivationDefSchema)[a161_0x3be2e1(0xab)]()})[a161_0x3be2e1(0xa6)](_0x5b439d=>{const _0x5bceee=a161_0x3be2e1,_0x55292=[_0x5b439d[_0x5bceee(0xa1)],_0x5b439d[_0x5bceee(0xa7)],_0x5b439d[_0x5bceee(0xa4)]][_0x5bceee(0xa9)](_0x4d9230=>Array[_0x5bceee(0xb7)](_0x4d9230)&&_0x4d9230[_0x5bceee(0xb5)]>0x0)[_0x5bceee(0xb5)];return _0x55292===0x1;},{'message':'Journey\x20must\x20have\x20exactly\x20one\x20of:\x20journeys,\x20stages,\x20or\x20versions'}));const _syncCheck1=!![],_syncCheck2=!![];void _syncCheck1,void _syncCheck2;
1
+ const a161_0x4d50c3=a161_0x25d4;(function(_0x59511a,_0x3f30bb){const _0x4ddeae=a161_0x25d4,_0x47f4fd=_0x59511a();while(!![]){try{const _0x45d943=parseInt(_0x4ddeae(0xcf))/0x1*(-parseInt(_0x4ddeae(0xd3))/0x2)+-parseInt(_0x4ddeae(0xd6))/0x3+-parseInt(_0x4ddeae(0xc8))/0x4+-parseInt(_0x4ddeae(0xbd))/0x5+-parseInt(_0x4ddeae(0xb7))/0x6*(-parseInt(_0x4ddeae(0xcc))/0x7)+-parseInt(_0x4ddeae(0xb6))/0x8*(parseInt(_0x4ddeae(0xdc))/0x9)+parseInt(_0x4ddeae(0xba))/0xa*(parseInt(_0x4ddeae(0xe0))/0xb);if(_0x45d943===_0x3f30bb)break;else _0x47f4fd['push'](_0x47f4fd['shift']());}catch(_0x36372d){_0x47f4fd['push'](_0x47f4fd['shift']());}}}(a161_0x2043,0xddaa8));import{z}from'zod';import{RuleDefSchema}from'./segment-schema.js';function a161_0x25d4(_0x478737,_0x415684){_0x478737=_0x478737-0xb4;const _0x2043da=a161_0x2043();let _0x25d445=_0x2043da[_0x478737];return _0x25d445;}import{ActivationDefSchema}from'./activation-schema.js';export const JourneyStateTypeSchema=z[a161_0x4d50c3(0xd7)]([a161_0x4d50c3(0xd9),'simulation','launched']);export const ReentryModeTypeSchema=z[a161_0x4d50c3(0xd7)]([a161_0x4d50c3(0xcb),a161_0x4d50c3(0xdd),a161_0x4d50c3(0xde)]);export const WaitUnitTypeSchema=z[a161_0x4d50c3(0xd7)](['day',a161_0x4d50c3(0xd2)]);export const StepTypeValueSchema=z[a161_0x4d50c3(0xd7)]([a161_0x4d50c3(0xbe),a161_0x4d50c3(0xc6),a161_0x4d50c3(0xda),a161_0x4d50c3(0xbf),a161_0x4d50c3(0xc3),a161_0x4d50c3(0xc7),a161_0x4d50c3(0xb4)]);function a161_0x2043(){const _0x1ef1f0=['lazy','16803MLuwRN','reentry_unless_goal_achieved','reentry_always','journeys','33IGnLoo','end','boolean','5000SwQtAS','136542yzsYWy','refine','string','17462860ZqiumP','optional','discriminatedUnion','8302595jedMWe','wait','ab_test','array','filter','isArray','merge','Journey\x20must\x20have\x20exactly\x20one\x20of:\x20journeys,\x20stages,\x20or\x20versions','passthrough','activation','jump','4591244VlTdPs','number','Journey\x20name\x20is\x20required','no_reentry','203vfCUxw','length','record','1IbjBnM','versions','min','week','680474iFTmKR','object','journey','2026275KqVuiX','enum','literal','draft','decision_point'];a161_0x2043=function(){return _0x1ef1f0;};return a161_0x2043();}export const EmbeddedSegmentDefSchema=z[a161_0x4d50c3(0xd4)]({'description':z[a161_0x4d50c3(0xb9)]()[a161_0x4d50c3(0xbb)](),'rule':RuleDefSchema});const JumpTargetDefSchema=z[a161_0x4d50c3(0xd4)]({'journey':z[a161_0x4d50c3(0xb9)](),'stage':z[a161_0x4d50c3(0xb9)](),'bundle_id':z['string']()[a161_0x4d50c3(0xbb)]()});export const CriteriaDefSchema=z[a161_0x4d50c3(0xd4)]({'name':z[a161_0x4d50c3(0xb9)](),'description':z[a161_0x4d50c3(0xb9)]()['optional'](),'segment':z['string'](),'target':JumpTargetDefSchema[a161_0x4d50c3(0xbb)]()});const WaitConditionTimeoutDefSchema=z['object']({'duration':z['number'](),'unit':WaitUnitTypeSchema,'next':z['string']()['optional']()}),WaitConditionDefSchema=z[a161_0x4d50c3(0xd4)]({'segment':z['string'](),'next':z['string']()[a161_0x4d50c3(0xbb)](),'timeout':WaitConditionTimeoutDefSchema[a161_0x4d50c3(0xbb)]()}),WaitStepParamsDefSchema=z[a161_0x4d50c3(0xd4)]({'duration':z[a161_0x4d50c3(0xc9)]()[a161_0x4d50c3(0xbb)](),'unit':WaitUnitTypeSchema[a161_0x4d50c3(0xbb)](),'wait_until':z[a161_0x4d50c3(0xb9)]()[a161_0x4d50c3(0xbb)](),'condition':WaitConditionDefSchema['optional'](),'days_of_week':z[a161_0x4d50c3(0xc0)](z[a161_0x4d50c3(0xb9)]())['optional']()}),StepBaseFields={'name':z[a161_0x4d50c3(0xb9)](),'uuid':z['string']()[a161_0x4d50c3(0xbb)](),'next':z['string']()[a161_0x4d50c3(0xbb)]()},WaitStepDefSchema=z[a161_0x4d50c3(0xd4)]({...StepBaseFields,'type':z[a161_0x4d50c3(0xd8)]('wait'),'with':WaitStepParamsDefSchema}),ActivationStepParamsDefSchema=z['object']({'activation':z[a161_0x4d50c3(0xb9)]()}),ActivationStepDefSchema=z[a161_0x4d50c3(0xd4)]({...StepBaseFields,'type':z['literal'](a161_0x4d50c3(0xc6)),'with':ActivationStepParamsDefSchema}),DecisionBranchDefSchema=z['object']({'name':z[a161_0x4d50c3(0xb9)](),'segment':z['string']()[a161_0x4d50c3(0xbb)](),'segment_id':z[a161_0x4d50c3(0xb9)]()[a161_0x4d50c3(0xbb)](),'excluded':z[a161_0x4d50c3(0xb5)]()['optional'](),'next':z[a161_0x4d50c3(0xb9)]()[a161_0x4d50c3(0xbb)]()}),DecisionPointStepParamsDefSchema=z[a161_0x4d50c3(0xd4)]({'branches':z['array'](DecisionBranchDefSchema)}),DecisionPointStepDefSchema=z[a161_0x4d50c3(0xd4)]({...StepBaseFields,'type':z[a161_0x4d50c3(0xd8)](a161_0x4d50c3(0xda)),'with':DecisionPointStepParamsDefSchema}),AbTestVariantDefSchema=z[a161_0x4d50c3(0xd4)]({'id':z[a161_0x4d50c3(0xb9)]()['optional'](),'name':z[a161_0x4d50c3(0xb9)](),'percentage':z[a161_0x4d50c3(0xc9)](),'next':z[a161_0x4d50c3(0xb9)]()[a161_0x4d50c3(0xbb)]()}),AbTestStepParamsDefSchema=z['object']({'variants':z[a161_0x4d50c3(0xc0)](AbTestVariantDefSchema),'unique_id':z['string']()[a161_0x4d50c3(0xbb)](),'customized_split':z[a161_0x4d50c3(0xb5)]()[a161_0x4d50c3(0xbb)]()}),AbTestStepDefSchema=z[a161_0x4d50c3(0xd4)]({...StepBaseFields,'type':z[a161_0x4d50c3(0xd8)]('ab_test'),'with':AbTestStepParamsDefSchema}),MergeStepDefSchema=z[a161_0x4d50c3(0xd4)]({...StepBaseFields,'type':z[a161_0x4d50c3(0xd8)](a161_0x4d50c3(0xc3))}),JumpStepParamsDefSchema=z['object']({'target':JumpTargetDefSchema}),JumpStepDefSchema=z[a161_0x4d50c3(0xd4)]({...StepBaseFields,'type':z['literal']('jump'),'with':JumpStepParamsDefSchema}),EndStepDefSchema=z[a161_0x4d50c3(0xd4)]({...StepBaseFields,'type':z[a161_0x4d50c3(0xd8)](a161_0x4d50c3(0xb4))})[a161_0x4d50c3(0xc5)]();export const StepDefSchema=z[a161_0x4d50c3(0xbc)]('type',[WaitStepDefSchema,ActivationStepDefSchema,DecisionPointStepDefSchema,AbTestStepDefSchema,MergeStepDefSchema,JumpStepDefSchema,EndStepDefSchema]);export const StageDefSchema=z[a161_0x4d50c3(0xd4)]({'name':z[a161_0x4d50c3(0xb9)](),'description':z[a161_0x4d50c3(0xb9)]()[a161_0x4d50c3(0xbb)](),'id':z[a161_0x4d50c3(0xb9)]()[a161_0x4d50c3(0xbb)](),'entry_criteria':CriteriaDefSchema['optional'](),'exit_criteria':z[a161_0x4d50c3(0xc0)](CriteriaDefSchema)[a161_0x4d50c3(0xbb)](),'milestone':CriteriaDefSchema[a161_0x4d50c3(0xbb)](),'root_step':z['string']()[a161_0x4d50c3(0xbb)](),'steps':z[a161_0x4d50c3(0xc0)](StepDefSchema)[a161_0x4d50c3(0xbb)]()});export const JourneyEntryDefSchema=z['object']({'name':z[a161_0x4d50c3(0xb9)]()['optional'](),'version':z[a161_0x4d50c3(0xb9)]()[a161_0x4d50c3(0xbb)](),'state':JourneyStateTypeSchema[a161_0x4d50c3(0xbb)](),'latest':z['boolean']()[a161_0x4d50c3(0xbb)](),'stages':z[a161_0x4d50c3(0xc0)](StageDefSchema),'id':z[a161_0x4d50c3(0xb9)]()[a161_0x4d50c3(0xbb)](),'version_number':z[a161_0x4d50c3(0xc9)]()['optional'](),'goal':CriteriaDefSchema[a161_0x4d50c3(0xbb)](),'reentry':ReentryModeTypeSchema[a161_0x4d50c3(0xbb)]()});export const JourneyDefSchema=z[a161_0x4d50c3(0xdb)](()=>z[a161_0x4d50c3(0xd4)]({'type':z['literal'](a161_0x4d50c3(0xd5)),'name':z[a161_0x4d50c3(0xb9)]()[a161_0x4d50c3(0xd1)](0x1,a161_0x4d50c3(0xca)),'description':z[a161_0x4d50c3(0xb9)]()[a161_0x4d50c3(0xbb)](),'bundle_id':z[a161_0x4d50c3(0xb9)]()[a161_0x4d50c3(0xbb)](),'bundle_name':z[a161_0x4d50c3(0xb9)]()[a161_0x4d50c3(0xbb)](),'folder_id':z['string']()[a161_0x4d50c3(0xbb)](),'reentry':ReentryModeTypeSchema[a161_0x4d50c3(0xbb)](),'allow_reentry':z['boolean']()['optional'](),'goal':CriteriaDefSchema[a161_0x4d50c3(0xbb)](),'id':z['string']()[a161_0x4d50c3(0xbb)](),'version':z[a161_0x4d50c3(0xb9)]()[a161_0x4d50c3(0xbb)](),'version_number':z[a161_0x4d50c3(0xc9)]()[a161_0x4d50c3(0xbb)](),'stages':z['array'](StageDefSchema)[a161_0x4d50c3(0xbb)](),'versions':z[a161_0x4d50c3(0xc0)](JourneyEntryDefSchema)[a161_0x4d50c3(0xbb)](),'journeys':z['array'](JourneyEntryDefSchema)['optional'](),'segments':z[a161_0x4d50c3(0xce)](z[a161_0x4d50c3(0xb9)](),EmbeddedSegmentDefSchema)[a161_0x4d50c3(0xbb)](),'activations':z[a161_0x4d50c3(0xce)](z[a161_0x4d50c3(0xb9)](),ActivationDefSchema)['optional']()})[a161_0x4d50c3(0xb8)](_0x2ba788=>{const _0x58d47e=a161_0x4d50c3,_0x9b77d9=[_0x2ba788[_0x58d47e(0xdf)],_0x2ba788['stages'],_0x2ba788[_0x58d47e(0xd0)]][_0x58d47e(0xc1)](_0x4611ad=>Array[_0x58d47e(0xc2)](_0x4611ad)&&_0x4611ad[_0x58d47e(0xcd)]>0x0)[_0x58d47e(0xcd)];return _0x9b77d9===0x1;},{'message':a161_0x4d50c3(0xc4)}));const _syncCheck1=!![],_syncCheck2=!![];void _syncCheck1,void _syncCheck2;
@@ -1 +1 @@
1
- function a163_0x2b8b(_0x3e52d3,_0x38a1ce){_0x3e52d3=_0x3e52d3-0xad;var _0x5c2220=a163_0x5c22();var _0x2b8bf4=_0x5c2220[_0x3e52d3];return _0x2b8bf4;}(function(_0x37f883,_0x3a0680){var _0x9a831a=a163_0x2b8b,_0x11dd76=_0x37f883();while(!![]){try{var _0x4c7c55=parseInt(_0x9a831a(0xae))/0x1*(parseInt(_0x9a831a(0xb1))/0x2)+-parseInt(_0x9a831a(0xb5))/0x3*(-parseInt(_0x9a831a(0xaf))/0x4)+parseInt(_0x9a831a(0xb3))/0x5+parseInt(_0x9a831a(0xb2))/0x6+parseInt(_0x9a831a(0xb7))/0x7+-parseInt(_0x9a831a(0xad))/0x8*(parseInt(_0x9a831a(0xb0))/0x9)+-parseInt(_0x9a831a(0xb4))/0xa*(parseInt(_0x9a831a(0xb6))/0xb);if(_0x4c7c55===_0x3a0680)break;else _0x11dd76['push'](_0x11dd76['shift']());}catch(_0x128bed){_0x11dd76['push'](_0x11dd76['shift']());}}}(a163_0x5c22,0x3135e));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_0x5c22(){var _0x4dc0fc=['2tPmjQq','1724mJIsQX','9UnOZGa','105686JAQSdE','1286694ZVAfrf','637535wRxxwy','325790kzafIY','1494OIMoTg','187LigIZp','2273642CxLoRZ','1853416BlLNUA'];a163_0x5c22=function(){return _0x4dc0fc;};return a163_0x5c22();}
1
+ (function(_0x4c344f,_0x12c006){var _0x1a2421=a163_0x5bdb,_0x43ca9b=_0x4c344f();while(!![]){try{var _0x10a7b8=parseInt(_0x1a2421(0x6e))/0x1*(parseInt(_0x1a2421(0x73))/0x2)+-parseInt(_0x1a2421(0x6d))/0x3+-parseInt(_0x1a2421(0x72))/0x4*(-parseInt(_0x1a2421(0x70))/0x5)+parseInt(_0x1a2421(0x77))/0x6*(parseInt(_0x1a2421(0x6c))/0x7)+-parseInt(_0x1a2421(0x74))/0x8*(parseInt(_0x1a2421(0x71))/0x9)+-parseInt(_0x1a2421(0x75))/0xa*(parseInt(_0x1a2421(0x6f))/0xb)+parseInt(_0x1a2421(0x76))/0xc*(parseInt(_0x1a2421(0x6b))/0xd);if(_0x10a7b8===_0x12c006)break;else _0x43ca9b['push'](_0x43ca9b['shift']());}catch(_0x28911a){_0x43ca9b['push'](_0x43ca9b['shift']());}}}(a163_0x49d9,0x538f8));function a163_0x5bdb(_0x495c50,_0xe7e8cf){_0x495c50=_0x495c50-0x6b;var _0x49d9c7=a163_0x49d9();var _0x5bdb4d=_0x49d9c7[_0x495c50];return _0x5bdb4d;}export{OperatorTypeSchema,TimeUnitSchema,AggregationTypeSchema,ArrayMatchingSchema,OperatorDefSchema,AggregationDefSchema,TimeWindowDefSchema,FilterColumnConditionDefSchema,FilterRuleDefSchema,ValueConditionDefSchema,BehaviorConditionDefSchema,ColumnConditionDefSchema,CompositeConditionDefSchema,SegmentRefConditionDefSchema,ConditionDefSchema,RuleDefSchema,SegmentDefSchema}from'./segment-schema.js';function a163_0x49d9(){var _0x16c823=['62709LVlWiH','7FwhoVB','22VLTCaG','380645aJgxHL','105003ScOvqc','4sDmMXr','153454ItSimH','72meuaDF','2370360spYlNl','74892hQAfSd','119076QaqehN','520qNmqjT','28vHPCNi'];a163_0x49d9=function(){return _0x16c823;};return a163_0x49d9();}export{ScheduleTypeSchema,RepeatUnitSchema,ScheduleDefSchema,NotificationDefSchema,ActivationColumnDefSchema,ActivationBehaviorDefSchema,ActivationDefSchema}from'./activation-schema.js';
@@ -1 +1 @@
1
- const a164_0x1630dc=a164_0x51fb;(function(_0x333d2b,_0x59d3db){const _0x2a09ea=a164_0x51fb,_0x3fad6b=_0x333d2b();while(!![]){try{const _0x3e3544=parseInt(_0x2a09ea(0x20c))/0x1*(parseInt(_0x2a09ea(0x228))/0x2)+-parseInt(_0x2a09ea(0x233))/0x3+-parseInt(_0x2a09ea(0x225))/0x4+parseInt(_0x2a09ea(0x22a))/0x5+parseInt(_0x2a09ea(0x211))/0x6*(parseInt(_0x2a09ea(0x1fa))/0x7)+parseInt(_0x2a09ea(0x234))/0x8+-parseInt(_0x2a09ea(0x201))/0x9*(parseInt(_0x2a09ea(0x210))/0xa);if(_0x3e3544===_0x59d3db)break;else _0x3fad6b['push'](_0x3fad6b['shift']());}catch(_0x1f83bd){_0x3fad6b['push'](_0x3fad6b['shift']());}}}(a164_0x193a,0xd82a7));import{z}from'zod';export const OperatorTypeSchema=z['enum']([a164_0x1630dc(0x1f0),'Greater','Less',a164_0x1630dc(0x203),a164_0x1630dc(0x205),'In',a164_0x1630dc(0x20b),a164_0x1630dc(0x22f),a164_0x1630dc(0x20e),a164_0x1630dc(0x217),a164_0x1630dc(0x230),'Contain',a164_0x1630dc(0x202),a164_0x1630dc(0x1ef),'TimeRange']);export const TimeUnitSchema=z[a164_0x1630dc(0x22c)]([a164_0x1630dc(0x222),'minute',a164_0x1630dc(0x204),a164_0x1630dc(0x206),'week',a164_0x1630dc(0x21f),'year']);export const AggregationTypeSchema=z[a164_0x1630dc(0x22c)]([a164_0x1630dc(0x200),a164_0x1630dc(0x213),a164_0x1630dc(0x223),'Min','Max',a164_0x1630dc(0x214),a164_0x1630dc(0x207),'Last']);function a164_0x193a(){const _0x238094=['day','First','Contain','discriminatedUnion','Behavior','Between','14549XQkRXl','Value','IsNull','array','30xmnMxX','6SWuKMA','realtime','Sum','CountDistinct','TimeRange\x20operator\x20requires\x20\x27duration\x27','addIssue','TimeWithinPast','include','Column','type','column','from','Segment\x20name\x20is\x20required','Timestamp\x20column\x20only\x20supports\x20TimeWithinPast,\x20TimeWithinNext,\x20or\x20TimeRange\x20operators\x20(got\x20\x27','month','And','boolean','second','Average','lazy','539768EFFeQH','Operator\x20\x27','Between\x20operator\x20requires\x20\x27min\x27\x20and/or\x20\x27max\x27\x20values','42pQBeOd','string','361405uNnllX','Last','enum','union','custom','Regexp','TimeWithinNext','object','\x27\x20is\x20only\x20valid\x20for\x20the\x20\x27timestamp\x27\x20column','1974675sVSoTi','9053616hnKyhL','TimeRange','operator','any','EndWith','Equal','min','duration','number','record','segment','literal','max','value','superRefine','6816467xVGabA','unit','MISSING_TIME_UNIT','has','Greater','optional','Count','2414133nLXpnb','StartWith','GreaterEqual','hour','LessEqual'];a164_0x193a=function(){return _0x238094;};return a164_0x193a();}const TemporalValueSchema=z[a164_0x1630dc(0x22d)]([z['object']({'timestamp':z[a164_0x1630dc(0x229)]()}),z[a164_0x1630dc(0x231)]({'last':z[a164_0x1630dc(0x22d)]([z[a164_0x1630dc(0x1f3)](),z[a164_0x1630dc(0x1f4)](z[a164_0x1630dc(0x229)](),z[a164_0x1630dc(0x1f3)]())]),'unit':z['string']()})]),OperatorValueSchema=z[a164_0x1630dc(0x22d)]([z[a164_0x1630dc(0x229)](),z[a164_0x1630dc(0x1f3)](),z[a164_0x1630dc(0x221)](),TemporalValueSchema,z['array'](z[a164_0x1630dc(0x22d)]([z[a164_0x1630dc(0x229)](),z[a164_0x1630dc(0x1f3)](),z[a164_0x1630dc(0x221)]()]))]),OPERATORS_REQUIRING_VALUE=new Set(['Equal',a164_0x1630dc(0x1fe),a164_0x1630dc(0x203),'Less','LessEqual','In',a164_0x1630dc(0x208),a164_0x1630dc(0x202),'EndWith',a164_0x1630dc(0x22f),a164_0x1630dc(0x217),'TimeWithinNext']),OPERATORS_REQUIRING_UNIT=new Set(['TimeWithinPast','TimeWithinNext']);export const OperatorDefSchema=z[a164_0x1630dc(0x231)]({'type':OperatorTypeSchema,'not':z['boolean']()[a164_0x1630dc(0x1ff)](),'value':OperatorValueSchema[a164_0x1630dc(0x1ff)](),'min':z[a164_0x1630dc(0x22d)]([z[a164_0x1630dc(0x1f3)](),z[a164_0x1630dc(0x229)](),TemporalValueSchema])['optional'](),'max':z[a164_0x1630dc(0x22d)]([z[a164_0x1630dc(0x1f3)](),z['string'](),TemporalValueSchema])[a164_0x1630dc(0x1ff)](),'unit':TimeUnitSchema[a164_0x1630dc(0x1ff)](),'duration':z[a164_0x1630dc(0x231)]({'day':z[a164_0x1630dc(0x1f3)]()[a164_0x1630dc(0x1ff)](),'week':z[a164_0x1630dc(0x1f3)]()[a164_0x1630dc(0x1ff)](),'month':z[a164_0x1630dc(0x1f3)]()[a164_0x1630dc(0x1ff)](),'year':z[a164_0x1630dc(0x1f3)]()[a164_0x1630dc(0x1ff)](),'hour':z[a164_0x1630dc(0x1f3)]()[a164_0x1630dc(0x1ff)](),'minute':z[a164_0x1630dc(0x1f3)]()[a164_0x1630dc(0x1ff)](),'second':z[a164_0x1630dc(0x1f3)]()[a164_0x1630dc(0x1ff)]()})[a164_0x1630dc(0x1ff)](),'from':z['object']({'last':z[a164_0x1630dc(0x22d)]([z[a164_0x1630dc(0x1f3)](),z[a164_0x1630dc(0x229)]()]),'unit':TimeUnitSchema})[a164_0x1630dc(0x1ff)](),'reverse':z['boolean']()[a164_0x1630dc(0x1ff)]()})['superRefine']((_0x43a1ce,_0x20083f)=>{const _0x4b47fe=a164_0x1630dc;OPERATORS_REQUIRING_VALUE[_0x4b47fe(0x1fd)](_0x43a1ce[_0x4b47fe(0x21a)])&&(_0x43a1ce[_0x4b47fe(0x1f8)]===undefined||_0x43a1ce['value']===null)&&_0x20083f[_0x4b47fe(0x216)]({'code':'custom','message':'Operator\x20\x27'+_0x43a1ce[_0x4b47fe(0x21a)]+'\x27\x20requires\x20a\x20value','path':[_0x4b47fe(0x1f8)]}),_0x43a1ce['type']===_0x4b47fe(0x20b)&&_0x43a1ce[_0x4b47fe(0x1f1)]===undefined&&_0x43a1ce[_0x4b47fe(0x1f7)]===undefined&&_0x20083f[_0x4b47fe(0x216)]({'code':_0x4b47fe(0x22e),'message':_0x4b47fe(0x227),'params':{'validationCode':'MISSING_BETWEEN_BOUNDS'}}),OPERATORS_REQUIRING_UNIT[_0x4b47fe(0x1fd)](_0x43a1ce['type'])&&_0x43a1ce[_0x4b47fe(0x1f8)]!==undefined&&!_0x43a1ce['unit']&&_0x20083f['addIssue']({'code':_0x4b47fe(0x22e),'message':_0x4b47fe(0x226)+_0x43a1ce['type']+'\x27\x20requires\x20a\x20time\x20unit','path':[_0x4b47fe(0x1fb)],'params':{'validationCode':_0x4b47fe(0x1fc)}}),_0x43a1ce[_0x4b47fe(0x21a)]===_0x4b47fe(0x235)&&(!_0x43a1ce[_0x4b47fe(0x1f2)]&&_0x20083f['addIssue']({'code':'custom','message':_0x4b47fe(0x215),'path':['duration']}),!_0x43a1ce['from']&&_0x20083f['addIssue']({'code':_0x4b47fe(0x22e),'message':'TimeRange\x20operator\x20requires\x20\x27from\x27','path':[_0x4b47fe(0x21c)]}));});export const ArrayMatchingSchema=z[a164_0x1630dc(0x22d)]([z[a164_0x1630dc(0x1f6)]('any'),z[a164_0x1630dc(0x1f6)]('all'),z[a164_0x1630dc(0x231)]({'atLeast':z[a164_0x1630dc(0x1f3)]()}),z[a164_0x1630dc(0x231)]({'atMost':z['number']()}),z['object']({'exactly':z['number']()})]);export const AggregationDefSchema=z[a164_0x1630dc(0x209)](a164_0x1630dc(0x21a),[z['object']({'type':z[a164_0x1630dc(0x22c)]([a164_0x1630dc(0x213),'Min','Max',a164_0x1630dc(0x223)]),'column':z[a164_0x1630dc(0x229)](),'groupingColumns':z[a164_0x1630dc(0x20f)](z[a164_0x1630dc(0x229)]())[a164_0x1630dc(0x1ff)]()}),z['object']({'type':z[a164_0x1630dc(0x1f6)](a164_0x1630dc(0x200)),'groupingColumns':z[a164_0x1630dc(0x20f)](z[a164_0x1630dc(0x229)]())['optional']()}),z[a164_0x1630dc(0x231)]({'type':z[a164_0x1630dc(0x1f6)](a164_0x1630dc(0x214)),'columns':z[a164_0x1630dc(0x20f)](z[a164_0x1630dc(0x229)]())}),z[a164_0x1630dc(0x231)]({'type':z[a164_0x1630dc(0x22c)]([a164_0x1630dc(0x207),a164_0x1630dc(0x22b)]),'column':z[a164_0x1630dc(0x229)](),'orderColumn':z[a164_0x1630dc(0x229)](),'groupingColumns':z['array'](z[a164_0x1630dc(0x229)]())['optional']()})]);export const TimeWindowDefSchema=z[a164_0x1630dc(0x231)]({'duration':z[a164_0x1630dc(0x1f3)](),'unit':TimeUnitSchema});const TIMESTAMP_OPERATORS=new Set([a164_0x1630dc(0x217),'TimeWithinNext',a164_0x1630dc(0x235)]);export const FilterColumnConditionDefSchema=z[a164_0x1630dc(0x231)]({'type':z[a164_0x1630dc(0x1f6)](a164_0x1630dc(0x219)),'column':z[a164_0x1630dc(0x229)](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema[a164_0x1630dc(0x1ff)]()})[a164_0x1630dc(0x1f9)]((_0x224f27,_0x79af8d)=>{const _0x140579=a164_0x1630dc,_0x25ac3e=_0x224f27[_0x140579(0x236)]['type'];_0x224f27[_0x140579(0x21b)]==='timestamp'?!TIMESTAMP_OPERATORS[_0x140579(0x1fd)](_0x25ac3e)&&_0x79af8d[_0x140579(0x216)]({'code':'custom','message':_0x140579(0x21e)+_0x25ac3e+'\x27)','path':[_0x140579(0x236),'type']}):TIMESTAMP_OPERATORS['has'](_0x25ac3e)&&_0x79af8d[_0x140579(0x216)]({'code':_0x140579(0x22e),'message':'Operator\x20\x27'+_0x25ac3e+_0x140579(0x232),'path':['operator','type']});});function a164_0x51fb(_0x4ce1a5,_0x46a742){_0x4ce1a5=_0x4ce1a5-0x1ee;const _0x193add=a164_0x193a();let _0x51fb50=_0x193add[_0x4ce1a5];return _0x51fb50;}export const FilterRuleDefSchema=z['object']({'type':z[a164_0x1630dc(0x1f6)](a164_0x1630dc(0x220)),'conditions':z[a164_0x1630dc(0x20f)](FilterColumnConditionDefSchema)});export const ValueConditionDefSchema=z['lazy'](()=>z[a164_0x1630dc(0x231)]({'type':z[a164_0x1630dc(0x1f6)](a164_0x1630dc(0x20d)),'attribute':z[a164_0x1630dc(0x229)](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema[a164_0x1630dc(0x1ff)](),'exclude':z['boolean']()[a164_0x1630dc(0x1ff)](),'aggregation':AggregationDefSchema[a164_0x1630dc(0x1ff)](),'source':z['string']()['optional'](),'filter':FilterRuleDefSchema[a164_0x1630dc(0x1ff)](),'limit':z[a164_0x1630dc(0x1f3)]()[a164_0x1630dc(0x1ff)]()}));export const BehaviorConditionDefSchema=z['lazy'](()=>z['object']({'type':z['literal'](a164_0x1630dc(0x20a)),'attribute':z[a164_0x1630dc(0x229)](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema['optional'](),'exclude':z[a164_0x1630dc(0x221)]()[a164_0x1630dc(0x1ff)](),'aggregation':AggregationDefSchema[a164_0x1630dc(0x1ff)](),'source':z[a164_0x1630dc(0x229)]()[a164_0x1630dc(0x1ff)](),'filter':FilterRuleDefSchema['optional'](),'timeWindow':TimeWindowDefSchema[a164_0x1630dc(0x1ff)](),'limit':z[a164_0x1630dc(0x1f3)]()[a164_0x1630dc(0x1ff)]()}));export const ColumnConditionDefSchema=z[a164_0x1630dc(0x231)]({'type':z['literal']('Column'),'column':z[a164_0x1630dc(0x229)](),'operator':OperatorDefSchema});export const CompositeConditionDefSchema=z[a164_0x1630dc(0x224)](()=>z['object']({'type':z[a164_0x1630dc(0x22c)]([a164_0x1630dc(0x220),'Or']),'conditions':z[a164_0x1630dc(0x20f)](ConditionDefSchema),'description':z['string']()['optional']()}));export const SegmentRefConditionDefSchema=z[a164_0x1630dc(0x231)]({'type':z[a164_0x1630dc(0x22c)]([a164_0x1630dc(0x218),'exclude']),'segment':z['string']()[a164_0x1630dc(0x1f1)](0x1,'Segment\x20reference\x20must\x20not\x20be\x20empty')});export const ConditionDefSchema=z['lazy'](()=>z[a164_0x1630dc(0x22d)]([ValueConditionDefSchema,BehaviorConditionDefSchema,ColumnConditionDefSchema,CompositeConditionDefSchema,SegmentRefConditionDefSchema]));export const RuleDefSchema=z[a164_0x1630dc(0x224)](()=>z[a164_0x1630dc(0x231)]({'type':z['enum']([a164_0x1630dc(0x220),'Or']),'conditions':z[a164_0x1630dc(0x20f)](ConditionDefSchema),'description':z[a164_0x1630dc(0x229)]()[a164_0x1630dc(0x1ff)]()}));export const SegmentDefSchema=z[a164_0x1630dc(0x231)]({'type':z['literal'](a164_0x1630dc(0x1f5))[a164_0x1630dc(0x1ff)](),'name':z[a164_0x1630dc(0x229)]()[a164_0x1630dc(0x1f1)](0x1,a164_0x1630dc(0x21d)),'description':z[a164_0x1630dc(0x229)]()[a164_0x1630dc(0x1ff)](),'folder':z[a164_0x1630dc(0x229)]()[a164_0x1630dc(0x1ff)](),'rule':RuleDefSchema['optional'](),'kind':z['enum'](['batch',a164_0x1630dc(0x212),'funnel_stage'])[a164_0x1630dc(0x1ff)](),'visible':z[a164_0x1630dc(0x221)]()[a164_0x1630dc(0x1ff)](),'activations':z['array'](z[a164_0x1630dc(0x1ee)]())[a164_0x1630dc(0x1ff)]()});const _syncCheck1=!![],_syncCheck2=!![];void _syncCheck1,void _syncCheck2;
1
+ const a164_0x5ada79=a164_0x3f6c;(function(_0x49eb6,_0x4b847c){const _0x3593e0=a164_0x3f6c,_0x3dfe55=_0x49eb6();while(!![]){try{const _0x45342e=parseInt(_0x3593e0(0xbf))/0x1+parseInt(_0x3593e0(0xd6))/0x2+parseInt(_0x3593e0(0xb1))/0x3+-parseInt(_0x3593e0(0xa1))/0x4+-parseInt(_0x3593e0(0xbb))/0x5*(-parseInt(_0x3593e0(0xcc))/0x6)+parseInt(_0x3593e0(0xdf))/0x7+parseInt(_0x3593e0(0xca))/0x8;if(_0x45342e===_0x4b847c)break;else _0x3dfe55['push'](_0x3dfe55['shift']());}catch(_0x487699){_0x3dfe55['push'](_0x3dfe55['shift']());}}}(a164_0x2943,0x9470f));function a164_0x2943(){const _0x2ab6e8=['value','year','min','\x27\x20is\x20only\x20valid\x20for\x20the\x20\x27timestamp\x27\x20column','Timestamp\x20column\x20only\x20supports\x20TimeWithinPast,\x20TimeWithinNext,\x20or\x20TimeRange\x20operators\x20(got\x20\x27','array','35iLQtxL','minute','hour','Max','238516TXEPQK','Last','\x27\x20requires\x20a\x20time\x20unit','exclude','from','CountDistinct','Contain','lazy','Count','custom','Equal','4403176PjvVNq','Segment\x20reference\x20must\x20not\x20be\x20empty','39024OBDCia','type','superRefine','week','number','Segment\x20name\x20is\x20required','segment','Value','has','First','39800lvRqwC','Greater','Regexp','MISSING_TIME_UNIT','Between','LessEqual','operator','Average','TimeRange\x20operator\x20requires\x20\x27from\x27','5198557gaOUwa','TimeRange','batch','literal','addIssue','Min','day','TimeWithinPast','optional','Column','4344648rUFoJd','Behavior','EndWith','union','TimeWithinNext','And','Sum','realtime','StartWith','duration','Operator\x20\x27','any','enum','boolean','MISSING_BETWEEN_BOUNDS','max','291555dMQqfI','Less','string','object'];a164_0x2943=function(){return _0x2ab6e8;};return a164_0x2943();}import{z}from'zod';export const OperatorTypeSchema=z[a164_0x5ada79(0xad)](['Equal','Greater',a164_0x5ada79(0xb2),'GreaterEqual',a164_0x5ada79(0xdb),'In',a164_0x5ada79(0xda),a164_0x5ada79(0xd8),'IsNull',a164_0x5ada79(0x9e),a164_0x5ada79(0xa5),a164_0x5ada79(0xc5),'StartWith',a164_0x5ada79(0xa3),'TimeRange']);export const TimeUnitSchema=z[a164_0x5ada79(0xad)](['second',a164_0x5ada79(0xbc),a164_0x5ada79(0xbd),a164_0x5ada79(0x9d),a164_0x5ada79(0xcf),'month',a164_0x5ada79(0xb6)]);export const AggregationTypeSchema=z[a164_0x5ada79(0xad)]([a164_0x5ada79(0xc7),'Sum',a164_0x5ada79(0xdd),a164_0x5ada79(0x9c),a164_0x5ada79(0xbe),a164_0x5ada79(0xc4),a164_0x5ada79(0xd5),a164_0x5ada79(0xc0)]);const TemporalValueSchema=z[a164_0x5ada79(0xa4)]([z[a164_0x5ada79(0xb4)]({'timestamp':z['string']()}),z[a164_0x5ada79(0xb4)]({'last':z['union']([z[a164_0x5ada79(0xd0)](),z['record'](z[a164_0x5ada79(0xb3)](),z[a164_0x5ada79(0xd0)]())]),'unit':z[a164_0x5ada79(0xb3)]()})]),OperatorValueSchema=z[a164_0x5ada79(0xa4)]([z[a164_0x5ada79(0xb3)](),z[a164_0x5ada79(0xd0)](),z['boolean'](),TemporalValueSchema,z[a164_0x5ada79(0xba)](z[a164_0x5ada79(0xa4)]([z[a164_0x5ada79(0xb3)](),z[a164_0x5ada79(0xd0)](),z[a164_0x5ada79(0xae)]()]))]),OPERATORS_REQUIRING_VALUE=new Set([a164_0x5ada79(0xc9),a164_0x5ada79(0xd7),'GreaterEqual',a164_0x5ada79(0xb2),a164_0x5ada79(0xdb),'In',a164_0x5ada79(0xc5),a164_0x5ada79(0xa9),'EndWith',a164_0x5ada79(0xd8),a164_0x5ada79(0x9e),a164_0x5ada79(0xa5)]),OPERATORS_REQUIRING_UNIT=new Set([a164_0x5ada79(0x9e),'TimeWithinNext']);export const OperatorDefSchema=z[a164_0x5ada79(0xb4)]({'type':OperatorTypeSchema,'not':z[a164_0x5ada79(0xae)]()[a164_0x5ada79(0x9f)](),'value':OperatorValueSchema[a164_0x5ada79(0x9f)](),'min':z['union']([z[a164_0x5ada79(0xd0)](),z[a164_0x5ada79(0xb3)](),TemporalValueSchema])[a164_0x5ada79(0x9f)](),'max':z[a164_0x5ada79(0xa4)]([z[a164_0x5ada79(0xd0)](),z[a164_0x5ada79(0xb3)](),TemporalValueSchema])['optional'](),'unit':TimeUnitSchema[a164_0x5ada79(0x9f)](),'duration':z[a164_0x5ada79(0xb4)]({'day':z[a164_0x5ada79(0xd0)]()[a164_0x5ada79(0x9f)](),'week':z['number']()[a164_0x5ada79(0x9f)](),'month':z[a164_0x5ada79(0xd0)]()['optional'](),'year':z[a164_0x5ada79(0xd0)]()[a164_0x5ada79(0x9f)](),'hour':z['number']()['optional'](),'minute':z[a164_0x5ada79(0xd0)]()[a164_0x5ada79(0x9f)](),'second':z['number']()[a164_0x5ada79(0x9f)]()})[a164_0x5ada79(0x9f)](),'from':z[a164_0x5ada79(0xb4)]({'last':z[a164_0x5ada79(0xa4)]([z['number'](),z['string']()]),'unit':TimeUnitSchema})['optional'](),'reverse':z[a164_0x5ada79(0xae)]()[a164_0x5ada79(0x9f)]()})[a164_0x5ada79(0xce)]((_0x312ba0,_0x2fc95d)=>{const _0x5ec32e=a164_0x5ada79;OPERATORS_REQUIRING_VALUE[_0x5ec32e(0xd4)](_0x312ba0['type'])&&(_0x312ba0[_0x5ec32e(0xb5)]===undefined||_0x312ba0[_0x5ec32e(0xb5)]===null)&&_0x2fc95d[_0x5ec32e(0xe3)]({'code':_0x5ec32e(0xc8),'message':'Operator\x20\x27'+_0x312ba0[_0x5ec32e(0xcd)]+'\x27\x20requires\x20a\x20value','path':[_0x5ec32e(0xb5)]}),_0x312ba0[_0x5ec32e(0xcd)]===_0x5ec32e(0xda)&&_0x312ba0[_0x5ec32e(0xb7)]===undefined&&_0x312ba0[_0x5ec32e(0xb0)]===undefined&&_0x2fc95d['addIssue']({'code':_0x5ec32e(0xc8),'message':'Between\x20operator\x20requires\x20\x27min\x27\x20and/or\x20\x27max\x27\x20values','params':{'validationCode':_0x5ec32e(0xaf)}}),OPERATORS_REQUIRING_UNIT[_0x5ec32e(0xd4)](_0x312ba0[_0x5ec32e(0xcd)])&&_0x312ba0[_0x5ec32e(0xb5)]!==undefined&&!_0x312ba0['unit']&&_0x2fc95d['addIssue']({'code':_0x5ec32e(0xc8),'message':_0x5ec32e(0xab)+_0x312ba0[_0x5ec32e(0xcd)]+_0x5ec32e(0xc1),'path':['unit'],'params':{'validationCode':_0x5ec32e(0xd9)}}),_0x312ba0[_0x5ec32e(0xcd)]===_0x5ec32e(0xe0)&&(!_0x312ba0[_0x5ec32e(0xaa)]&&_0x2fc95d[_0x5ec32e(0xe3)]({'code':_0x5ec32e(0xc8),'message':'TimeRange\x20operator\x20requires\x20\x27duration\x27','path':[_0x5ec32e(0xaa)]}),!_0x312ba0[_0x5ec32e(0xc3)]&&_0x2fc95d[_0x5ec32e(0xe3)]({'code':_0x5ec32e(0xc8),'message':_0x5ec32e(0xde),'path':['from']}));});export const ArrayMatchingSchema=z[a164_0x5ada79(0xa4)]([z['literal'](a164_0x5ada79(0xac)),z[a164_0x5ada79(0xe2)]('all'),z[a164_0x5ada79(0xb4)]({'atLeast':z[a164_0x5ada79(0xd0)]()}),z[a164_0x5ada79(0xb4)]({'atMost':z['number']()}),z['object']({'exactly':z[a164_0x5ada79(0xd0)]()})]);function a164_0x3f6c(_0x4296a1,_0x270a91){_0x4296a1=_0x4296a1-0x9c;const _0x294311=a164_0x2943();let _0x3f6c51=_0x294311[_0x4296a1];return _0x3f6c51;}export const AggregationDefSchema=z['discriminatedUnion'](a164_0x5ada79(0xcd),[z[a164_0x5ada79(0xb4)]({'type':z[a164_0x5ada79(0xad)]([a164_0x5ada79(0xa7),a164_0x5ada79(0x9c),a164_0x5ada79(0xbe),a164_0x5ada79(0xdd)]),'column':z[a164_0x5ada79(0xb3)](),'groupingColumns':z[a164_0x5ada79(0xba)](z[a164_0x5ada79(0xb3)]())[a164_0x5ada79(0x9f)]()}),z[a164_0x5ada79(0xb4)]({'type':z['literal'](a164_0x5ada79(0xc7)),'groupingColumns':z[a164_0x5ada79(0xba)](z[a164_0x5ada79(0xb3)]())[a164_0x5ada79(0x9f)]()}),z['object']({'type':z['literal'](a164_0x5ada79(0xc4)),'columns':z[a164_0x5ada79(0xba)](z[a164_0x5ada79(0xb3)]())}),z[a164_0x5ada79(0xb4)]({'type':z['enum']([a164_0x5ada79(0xd5),a164_0x5ada79(0xc0)]),'column':z['string'](),'orderColumn':z[a164_0x5ada79(0xb3)](),'groupingColumns':z[a164_0x5ada79(0xba)](z[a164_0x5ada79(0xb3)]())[a164_0x5ada79(0x9f)]()})]);export const TimeWindowDefSchema=z[a164_0x5ada79(0xb4)]({'duration':z[a164_0x5ada79(0xd0)](),'unit':TimeUnitSchema});const TIMESTAMP_OPERATORS=new Set([a164_0x5ada79(0x9e),a164_0x5ada79(0xa5),'TimeRange']);export const FilterColumnConditionDefSchema=z[a164_0x5ada79(0xb4)]({'type':z[a164_0x5ada79(0xe2)](a164_0x5ada79(0xa0)),'column':z['string'](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema[a164_0x5ada79(0x9f)]()})[a164_0x5ada79(0xce)]((_0x22ea28,_0xcc4422)=>{const _0x547c04=a164_0x5ada79,_0x2c3049=_0x22ea28[_0x547c04(0xdc)][_0x547c04(0xcd)];_0x22ea28['column']==='timestamp'?!TIMESTAMP_OPERATORS[_0x547c04(0xd4)](_0x2c3049)&&_0xcc4422[_0x547c04(0xe3)]({'code':_0x547c04(0xc8),'message':_0x547c04(0xb9)+_0x2c3049+'\x27)','path':[_0x547c04(0xdc),_0x547c04(0xcd)]}):TIMESTAMP_OPERATORS[_0x547c04(0xd4)](_0x2c3049)&&_0xcc4422[_0x547c04(0xe3)]({'code':'custom','message':_0x547c04(0xab)+_0x2c3049+_0x547c04(0xb8),'path':[_0x547c04(0xdc),_0x547c04(0xcd)]});});export const FilterRuleDefSchema=z[a164_0x5ada79(0xb4)]({'type':z[a164_0x5ada79(0xe2)](a164_0x5ada79(0xa6)),'conditions':z['array'](FilterColumnConditionDefSchema)});export const ValueConditionDefSchema=z[a164_0x5ada79(0xc6)](()=>z[a164_0x5ada79(0xb4)]({'type':z[a164_0x5ada79(0xe2)](a164_0x5ada79(0xd3)),'attribute':z[a164_0x5ada79(0xb3)](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema[a164_0x5ada79(0x9f)](),'exclude':z[a164_0x5ada79(0xae)]()[a164_0x5ada79(0x9f)](),'aggregation':AggregationDefSchema[a164_0x5ada79(0x9f)](),'source':z[a164_0x5ada79(0xb3)]()[a164_0x5ada79(0x9f)](),'filter':FilterRuleDefSchema[a164_0x5ada79(0x9f)](),'limit':z[a164_0x5ada79(0xd0)]()['optional']()}));export const BehaviorConditionDefSchema=z[a164_0x5ada79(0xc6)](()=>z[a164_0x5ada79(0xb4)]({'type':z[a164_0x5ada79(0xe2)](a164_0x5ada79(0xa2)),'attribute':z[a164_0x5ada79(0xb3)](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema[a164_0x5ada79(0x9f)](),'exclude':z[a164_0x5ada79(0xae)]()['optional'](),'aggregation':AggregationDefSchema[a164_0x5ada79(0x9f)](),'source':z[a164_0x5ada79(0xb3)]()[a164_0x5ada79(0x9f)](),'filter':FilterRuleDefSchema[a164_0x5ada79(0x9f)](),'timeWindow':TimeWindowDefSchema[a164_0x5ada79(0x9f)](),'limit':z[a164_0x5ada79(0xd0)]()[a164_0x5ada79(0x9f)]()}));export const ColumnConditionDefSchema=z['object']({'type':z[a164_0x5ada79(0xe2)](a164_0x5ada79(0xa0)),'column':z['string'](),'operator':OperatorDefSchema});export const CompositeConditionDefSchema=z[a164_0x5ada79(0xc6)](()=>z[a164_0x5ada79(0xb4)]({'type':z[a164_0x5ada79(0xad)]([a164_0x5ada79(0xa6),'Or']),'conditions':z['array'](ConditionDefSchema),'description':z[a164_0x5ada79(0xb3)]()[a164_0x5ada79(0x9f)]()}));export const SegmentRefConditionDefSchema=z[a164_0x5ada79(0xb4)]({'type':z[a164_0x5ada79(0xad)](['include',a164_0x5ada79(0xc2)]),'segment':z[a164_0x5ada79(0xb3)]()[a164_0x5ada79(0xb7)](0x1,a164_0x5ada79(0xcb))});export const ConditionDefSchema=z['lazy'](()=>z[a164_0x5ada79(0xa4)]([ValueConditionDefSchema,BehaviorConditionDefSchema,ColumnConditionDefSchema,CompositeConditionDefSchema,SegmentRefConditionDefSchema]));export const RuleDefSchema=z[a164_0x5ada79(0xc6)](()=>z[a164_0x5ada79(0xb4)]({'type':z[a164_0x5ada79(0xad)]([a164_0x5ada79(0xa6),'Or']),'conditions':z[a164_0x5ada79(0xba)](ConditionDefSchema),'description':z[a164_0x5ada79(0xb3)]()[a164_0x5ada79(0x9f)]()}));export const SegmentDefSchema=z[a164_0x5ada79(0xb4)]({'type':z[a164_0x5ada79(0xe2)](a164_0x5ada79(0xd2))[a164_0x5ada79(0x9f)](),'name':z[a164_0x5ada79(0xb3)]()[a164_0x5ada79(0xb7)](0x1,a164_0x5ada79(0xd1)),'description':z[a164_0x5ada79(0xb3)]()['optional'](),'folder':z[a164_0x5ada79(0xb3)]()['optional'](),'rule':RuleDefSchema[a164_0x5ada79(0x9f)](),'kind':z['enum']([a164_0x5ada79(0xe1),a164_0x5ada79(0xa8),'funnel_stage'])[a164_0x5ada79(0x9f)](),'visible':z[a164_0x5ada79(0xae)]()[a164_0x5ada79(0x9f)](),'activations':z[a164_0x5ada79(0xba)](z['any']())[a164_0x5ada79(0x9f)]()});const _syncCheck1=!![],_syncCheck2=!![];void _syncCheck1,void _syncCheck2;
@@ -1 +1 @@
1
- const a165_0x4e4d4c=a165_0x4ecf;(function(_0x5d5163,_0x40cda6){const _0x440f5e=a165_0x4ecf,_0x395275=_0x5d5163();while(!![]){try{const _0x3c5db9=parseInt(_0x440f5e(0x150))/0x1*(-parseInt(_0x440f5e(0x15a))/0x2)+parseInt(_0x440f5e(0x14f))/0x3+-parseInt(_0x440f5e(0x14d))/0x4*(-parseInt(_0x440f5e(0x151))/0x5)+parseInt(_0x440f5e(0x154))/0x6+-parseInt(_0x440f5e(0x14a))/0x7*(-parseInt(_0x440f5e(0x149))/0x8)+-parseInt(_0x440f5e(0x160))/0x9*(parseInt(_0x440f5e(0x161))/0xa)+-parseInt(_0x440f5e(0x144))/0xb;if(_0x3c5db9===_0x40cda6)break;else _0x395275['push'](_0x395275['shift']());}catch(_0x1998ce){_0x395275['push'](_0x395275['shift']());}}}(a165_0x2ecb,0xa10be));import{readFileSync}from'fs';import*as a165_0x2e1af3 from'path';import*as a165_0x2db897 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([a165_0x4e4d4c(0x157),'push']);function a165_0x2ecb(){const _0x757307=['8NCzBqo','7350903CPuHlG','template','campaign_type','71112SWZtHD','toJSON','392910vqKemo','2eQXuIv','310BXtbVR','object','journey','1682010MrrNJy','length','message','email','segment','type','254596HoABcG','error','result','not\x20a\x20','parseDocument','relative','45vTEJDH','1336540amdzOq','YAML\x20parse\x20error:\x20','YAML_PARSE_ERROR','has','valid','basename','10792738vSUVDr','map','utf-8','campaign','filterType'];a165_0x2ecb=function(){return _0x757307;};return a165_0x2ecb();}export function isJourneyDef(_0x4b7731){const _0x30deb2=a165_0x4e4d4c;return typeof _0x4b7731==='object'&&_0x4b7731!==null&&_0x30deb2(0x159)in _0x4b7731&&_0x4b7731['type']==='journey';}export function isCampaignDef(_0x3628cc){const _0x45ff25=a165_0x4e4d4c;if(typeof _0x3628cc!=='object'||_0x3628cc===null)return![];const _0x2060b5=_0x3628cc,_0x5923b7=VALID_CAMPAIGN_TYPES[_0x45ff25(0x141)](_0x2060b5[_0x45ff25(0x14c)]);if(_0x2060b5[_0x45ff25(0x159)]==='campaign'&&_0x5923b7)return!![];if(_0x5923b7&&!_0x2060b5['type'])return!![];return![];}export function isTemplateDef(_0x5740ac){const _0x528988=a165_0x4e4d4c;return typeof _0x5740ac===_0x528988(0x152)&&_0x5740ac!==null&&_0x528988(0x159)in _0x5740ac&&_0x5740ac[_0x528988(0x159)]==='template';}export function isValidationResult(_0x27960f){return!('skipped'in _0x27960f);}export function createParseErrorResult(_0x1edd2c,_0x250245,_0x4a8965,_0xfef0c8,_0x59c572='segment'){const _0x3d7006=a165_0x4e4d4c;return{'filePath':_0x1edd2c,'relativePath':_0x250245,'source':_0x4a8965,'result':{'valid':![],'errors':[{'level':_0x3d7006(0x15b),'path':'','code':_0x3d7006(0x163),'message':_0xfef0c8}],'warnings':[]},'fileType':_0x59c572};}function a165_0x4ecf(_0xbe4328,_0x15e508){_0xbe4328=_0xbe4328-0x141;const _0x2ecb69=a165_0x2ecb();let _0x4ecfd1=_0x2ecb69[_0xbe4328];return _0x4ecfd1;}export function validateYamlFile(_0x266a44,_0x7d3715,_0x56d250={}){const _0x5cdafe=a165_0x4e4d4c,_0x9ae6ed=a165_0x2e1af3[_0x5cdafe(0x15f)](_0x7d3715,_0x266a44)||a165_0x2e1af3[_0x5cdafe(0x143)](_0x266a44);try{const _0x216fe1=readFileSync(_0x266a44,_0x5cdafe(0x146)),_0x4a783c=a165_0x2db897[_0x5cdafe(0x15e)](_0x216fe1),_0x5f4d60=_0x4a783c[_0x5cdafe(0x14e)]();if(!_0x5f4d60)return createParseErrorResult(_0x266a44,_0x9ae6ed,_0x216fe1,'Failed\x20to\x20parse\x20YAML\x20file\x20(empty\x20or\x20invalid)');let _0xeae697;if(isJourneyDef(_0x5f4d60))_0xeae697=_0x5cdafe(0x153);else{if(isCampaignDef(_0x5f4d60))_0xeae697='campaign';else isTemplateDef(_0x5f4d60)?_0xeae697=_0x5cdafe(0x14b):_0xeae697=_0x5cdafe(0x158);}if(_0x56d250['filterType']&&_0xeae697!==_0x56d250[_0x5cdafe(0x148)])return{'filePath':_0x266a44,'relativePath':_0x9ae6ed,'skipped':!![],'reason':_0x5cdafe(0x15d)+_0x56d250[_0x5cdafe(0x148)]};const _0x104489={'source':_0x216fe1,'document':_0x4a783c};let _0x38029f;if(_0xeae697===_0x5cdafe(0x153))_0x38029f=validateJourneyDef(_0x5f4d60,_0x104489);else{if(_0xeae697===_0x5cdafe(0x147))_0x38029f=validateCampaignDef(_0x5f4d60,_0x104489);else _0xeae697===_0x5cdafe(0x14b)?_0x38029f=validateTemplateDef(_0x5f4d60,_0x104489):_0x38029f=validateSegmentDef(_0x5f4d60,_0x104489);}return{'filePath':_0x266a44,'relativePath':_0x9ae6ed,'source':_0x216fe1,'result':_0x38029f,'fileType':_0xeae697};}catch(_0x3ca9b7){const _0x1638f6=_0x3ca9b7 instanceof Error?_0x3ca9b7[_0x5cdafe(0x156)]:String(_0x3ca9b7);return createParseErrorResult(_0x266a44,_0x9ae6ed,'',_0x5cdafe(0x162)+_0x1638f6);}}export function validateYamlFiles(_0x5eb827,_0x2b116f,_0x142df0={}){const _0x3987af=a165_0x4e4d4c;return _0x5eb827[_0x3987af(0x145)](_0xeaf8c1=>validateYamlFile(_0xeaf8c1,_0x2b116f,_0x142df0));}export function calculateSummary(_0x1b8620){const _0x456c81=a165_0x4e4d4c;let _0x937f21=0x0,_0x3f1788=0x0,_0xe88a7e=0x0,_0x6f5db4=0x0;for(const _0x633ef of _0x1b8620){if(!isValidationResult(_0x633ef)){_0x6f5db4++;continue;}_0x633ef[_0x456c81(0x15c)][_0x456c81(0x142)]?_0x937f21++:_0x3f1788++,_0xe88a7e+=_0x633ef[_0x456c81(0x15c)]['warnings'][_0x456c81(0x155)];}return{'validCount':_0x937f21,'invalidCount':_0x3f1788,'warningCount':_0xe88a7e,'skippedCount':_0x6f5db4,'hasErrors':_0x3f1788>0x0};}
1
+ (function(_0x45f9f5,_0x4b68e5){const _0x205a23=a165_0x4ef1,_0x34368f=_0x45f9f5();while(!![]){try{const _0x17aa93=-parseInt(_0x205a23(0x1d4))/0x1+-parseInt(_0x205a23(0x1c6))/0x2+-parseInt(_0x205a23(0x1c4))/0x3+-parseInt(_0x205a23(0x1c8))/0x4+parseInt(_0x205a23(0x1cc))/0x5+parseInt(_0x205a23(0x1bd))/0x6+parseInt(_0x205a23(0x1bb))/0x7*(parseInt(_0x205a23(0x1d5))/0x8);if(_0x17aa93===_0x4b68e5)break;else _0x34368f['push'](_0x34368f['shift']());}catch(_0x3e2ca6){_0x34368f['push'](_0x34368f['shift']());}}}(a165_0x2ef7,0x76eb3));function a165_0x4ef1(_0x4b4a06,_0x33e715){_0x4b4a06=_0x4b4a06-0x1bb;const _0x2ef7cc=a165_0x2ef7();let _0x4ef11e=_0x2ef7cc[_0x4b4a06];return _0x4ef11e;}import{readFileSync}from'fs';function a165_0x2ef7(){const _0x28523c=['1320416fGlhfQ','object','template','result','612730XLaKPm','Failed\x20to\x20parse\x20YAML\x20file\x20(empty\x20or\x20invalid)','type','campaign','YAML_PARSE_ERROR','YAML\x20parse\x20error:\x20','journey','message','374758OeKOFc','15618568ACyPop','error','7jycUbd','utf-8','1398762BlDLFw','length','valid','basename','map','toJSON','parseDocument','2146020rCvxlR','segment','801402qvDDvh','campaign_type'];a165_0x2ef7=function(){return _0x28523c;};return a165_0x2ef7();}import*as a165_0x2cecef from'path';import*as a165_0x324cf8 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','push']);export function isJourneyDef(_0x1fd9d0){const _0x16918a=a165_0x4ef1;return typeof _0x1fd9d0==='object'&&_0x1fd9d0!==null&&_0x16918a(0x1ce)in _0x1fd9d0&&_0x1fd9d0[_0x16918a(0x1ce)]===_0x16918a(0x1d2);}export function isCampaignDef(_0x4f44a1){const _0x2f2f44=a165_0x4ef1;if(typeof _0x4f44a1!==_0x2f2f44(0x1c9)||_0x4f44a1===null)return![];const _0xfef012=_0x4f44a1,_0x32ef3c=VALID_CAMPAIGN_TYPES['has'](_0xfef012[_0x2f2f44(0x1c7)]);if(_0xfef012[_0x2f2f44(0x1ce)]===_0x2f2f44(0x1cf)&&_0x32ef3c)return!![];if(_0x32ef3c&&!_0xfef012[_0x2f2f44(0x1ce)])return!![];return![];}export function isTemplateDef(_0x2c7f2c){const _0x1738dd=a165_0x4ef1;return typeof _0x2c7f2c==='object'&&_0x2c7f2c!==null&&_0x1738dd(0x1ce)in _0x2c7f2c&&_0x2c7f2c[_0x1738dd(0x1ce)]===_0x1738dd(0x1ca);}export function isValidationResult(_0x5ddc8c){return!('skipped'in _0x5ddc8c);}export function createParseErrorResult(_0x41d15c,_0x2bd869,_0x5ca893,_0x5bf44e,_0x57d370='segment'){const _0x502b50=a165_0x4ef1;return{'filePath':_0x41d15c,'relativePath':_0x2bd869,'source':_0x5ca893,'result':{'valid':![],'errors':[{'level':_0x502b50(0x1d6),'path':'','code':_0x502b50(0x1d0),'message':_0x5bf44e}],'warnings':[]},'fileType':_0x57d370};}export function validateYamlFile(_0x3886ef,_0x53e6fd,_0x2a209e={}){const _0x5e011c=a165_0x4ef1,_0x48a74a=a165_0x2cecef['relative'](_0x53e6fd,_0x3886ef)||a165_0x2cecef[_0x5e011c(0x1c0)](_0x3886ef);try{const _0x455ddd=readFileSync(_0x3886ef,_0x5e011c(0x1bc)),_0x1b5702=a165_0x324cf8[_0x5e011c(0x1c3)](_0x455ddd),_0x407828=_0x1b5702[_0x5e011c(0x1c2)]();if(!_0x407828)return createParseErrorResult(_0x3886ef,_0x48a74a,_0x455ddd,_0x5e011c(0x1cd));let _0xa3be00;if(isJourneyDef(_0x407828))_0xa3be00='journey';else{if(isCampaignDef(_0x407828))_0xa3be00=_0x5e011c(0x1cf);else isTemplateDef(_0x407828)?_0xa3be00=_0x5e011c(0x1ca):_0xa3be00=_0x5e011c(0x1c5);}if(_0x2a209e['filterType']&&_0xa3be00!==_0x2a209e['filterType'])return{'filePath':_0x3886ef,'relativePath':_0x48a74a,'skipped':!![],'reason':'not\x20a\x20'+_0x2a209e['filterType']};const _0x31ef61={'source':_0x455ddd,'document':_0x1b5702};let _0x356d41;if(_0xa3be00===_0x5e011c(0x1d2))_0x356d41=validateJourneyDef(_0x407828,_0x31ef61);else{if(_0xa3be00===_0x5e011c(0x1cf))_0x356d41=validateCampaignDef(_0x407828,_0x31ef61);else _0xa3be00===_0x5e011c(0x1ca)?_0x356d41=validateTemplateDef(_0x407828,_0x31ef61):_0x356d41=validateSegmentDef(_0x407828,_0x31ef61);}return{'filePath':_0x3886ef,'relativePath':_0x48a74a,'source':_0x455ddd,'result':_0x356d41,'fileType':_0xa3be00};}catch(_0x31fd22){const _0x1b6328=_0x31fd22 instanceof Error?_0x31fd22[_0x5e011c(0x1d3)]:String(_0x31fd22);return createParseErrorResult(_0x3886ef,_0x48a74a,'',_0x5e011c(0x1d1)+_0x1b6328);}}export function validateYamlFiles(_0x2818f0,_0x3dd9d0,_0x4c1d6b={}){const _0x2b21dc=a165_0x4ef1;return _0x2818f0[_0x2b21dc(0x1c1)](_0x82a9be=>validateYamlFile(_0x82a9be,_0x3dd9d0,_0x4c1d6b));}export function calculateSummary(_0x2e71e2){const _0x7a31e=a165_0x4ef1;let _0x1f49f1=0x0,_0x7e991f=0x0,_0x5bc9de=0x0,_0x5a3822=0x0;for(const _0x2726de of _0x2e71e2){if(!isValidationResult(_0x2726de)){_0x5a3822++;continue;}_0x2726de[_0x7a31e(0x1cb)][_0x7a31e(0x1bf)]?_0x1f49f1++:_0x7e991f++,_0x5bc9de+=_0x2726de[_0x7a31e(0x1cb)]['warnings'][_0x7a31e(0x1be)];}return{'validCount':_0x1f49f1,'invalidCount':_0x7e991f,'warningCount':_0x5bc9de,'skippedCount':_0x5a3822,'hasErrors':_0x7e991f>0x0};}
@@ -1 +1 @@
1
- (function(_0x3c1f3d,_0x38f2db){const _0xc07a22=a166_0x47c1,_0x255cab=_0x3c1f3d();while(!![]){try{const _0x20f779=parseInt(_0xc07a22(0xc7))/0x1+parseInt(_0xc07a22(0xe6))/0x2*(parseInt(_0xc07a22(0xd1))/0x3)+-parseInt(_0xc07a22(0xc9))/0x4*(-parseInt(_0xc07a22(0xcb))/0x5)+parseInt(_0xc07a22(0xcd))/0x6+-parseInt(_0xc07a22(0xf0))/0x7*(parseInt(_0xc07a22(0xdf))/0x8)+parseInt(_0xc07a22(0xd0))/0x9*(parseInt(_0xc07a22(0xd3))/0xa)+-parseInt(_0xc07a22(0xe8))/0xb;if(_0x20f779===_0x38f2db)break;else _0x255cab['push'](_0x255cab['shift']());}catch(_0x45d1c4){_0x255cab['push'](_0x255cab['shift']());}}}(a166_0x2133,0x5a442));import*as a166_0x2dce5f from'yaml';import a166_0x136c87 from'chalk';export{validateSegmentDef,validateRuleDef}from'./segment-validator.js';function a166_0x2133(){const _0x20073a=['message','issues','code','length','4006415YvBkEV','min','red','number','error','match','34279dgbiHJ','safeParse','92LQAanj','Invalid\x20YAML:\x20expected\x20an\x20object','40105cHMVZf','path','3751794IqpxJd','errors','pop','55197nWDYSA','14478XDLmtR','toString','500HdUMJK','dim','YAML\x20validation\x20error:\x20','map','data','success','cyan','repeat','getIn','max','column','range','8BrMIPk','object','level','flatMap','contents','join','push','160mNfUyl','invalid_union','6541876vOtVaM','split','location','\x20|\x20'];a166_0x2133=function(){return _0x20073a;};return a166_0x2133();}export function getLocationFromPath(_0x546a13,_0x4b97ce,_0x481cf9){const _0x280296=a166_0x47c1;if(!_0x546a13||!_0x4b97ce)return undefined;try{let _0x34199c=_0x546a13[_0x280296(0xdb)](_0x481cf9,!![]),_0x48cb81=[..._0x481cf9];while((!_0x34199c||typeof _0x34199c!==_0x280296(0xe0)||!(_0x280296(0xde)in _0x34199c)||!_0x34199c[_0x280296(0xde)])&&_0x48cb81[_0x280296(0xef)]>0x0){_0x48cb81[_0x280296(0xcf)](),_0x34199c=_0x48cb81[_0x280296(0xef)]>0x0?_0x546a13['getIn'](_0x48cb81,!![]):_0x546a13[_0x280296(0xe3)];}if(!_0x34199c||typeof _0x34199c!==_0x280296(0xe0)||!('range'in _0x34199c)||!_0x34199c[_0x280296(0xde)])return undefined;const [_0x12a391]=_0x34199c[_0x280296(0xde)];return offsetToLocation(_0x4b97ce,_0x12a391);}catch{return undefined;}}function a166_0x47c1(_0x441cc,_0x1571d5){_0x441cc=_0x441cc-0xc6;const _0x21337b=a166_0x2133();let _0x47c106=_0x21337b[_0x441cc];return _0x47c106;}export function offsetToLocation(_0x2d810c,_0x56a56a){const _0x4a08da=a166_0x47c1;let _0x5f3c47=0x1,_0x5dade7=0x1;for(let _0x4864c2=0x0;_0x4864c2<_0x56a56a&&_0x4864c2<_0x2d810c[_0x4a08da(0xef)];_0x4864c2++){_0x2d810c[_0x4864c2]==='\x0a'?(_0x5f3c47++,_0x5dade7=0x1):_0x5dade7++;}return{'line':_0x5f3c47,'column':_0x5dade7,'offset':_0x56a56a};}export function pathToArray(_0x670a5c){const _0x26cf7d=a166_0x47c1;if(!_0x670a5c)return[];return _0x670a5c[_0x26cf7d(0xe9)]('.')[_0x26cf7d(0xe2)](_0x534a66=>{const _0x127a77=_0x26cf7d,_0x48e8f1=_0x534a66[_0x127a77(0xc6)](/^(\w+)\[(\d+)\]$/);if(_0x48e8f1)return[_0x48e8f1[0x1],parseInt(_0x48e8f1[0x2],0xa)];return[_0x534a66];});}export function formatZodPath(_0x4b7add){const _0x34e3cc=a166_0x47c1;let _0x5c6d12='';for(const _0x208094 of _0x4b7add){if(typeof _0x208094===_0x34e3cc(0xf3))_0x5c6d12+='['+_0x208094+']';else{const _0xd33311=String(_0x208094);_0x5c6d12+=_0x5c6d12?'.'+_0xd33311:_0xd33311;}}return _0x5c6d12;}export function flattenZodIssues(_0x108d7b){const _0xc3fdf4=a166_0x47c1,_0x59bb7b=[];for(const _0x1e7f14 of _0x108d7b){if(_0x1e7f14['code']===_0xc3fdf4(0xe7)&&'errors'in _0x1e7f14){const _0x523f8d=_0x1e7f14['errors'];let _0x3a2760=_0x523f8d[0x0]||[];for(const _0x52b8a2 of _0x523f8d){_0x52b8a2[_0xc3fdf4(0xef)]<_0x3a2760['length']&&(_0x3a2760=_0x52b8a2);}const _0x4e16f3=_0x3a2760[_0xc3fdf4(0xd6)](_0x2bcaee=>({..._0x2bcaee,'path':[..._0x1e7f14[_0xc3fdf4(0xcc)],..._0x2bcaee['path']]}));_0x59bb7b[_0xc3fdf4(0xe5)](...flattenZodIssues(_0x4e16f3));}else _0x59bb7b[_0xc3fdf4(0xe5)](_0x1e7f14);}return _0x59bb7b;}export function safeParseYaml(_0x3a48fc,_0x2ec66d){const _0x1a5027=a166_0x47c1,_0x1caaa7=a166_0x2dce5f['parse'](_0x3a48fc);if(!_0x1caaa7||typeof _0x1caaa7!==_0x1a5027(0xe0))throw new Error(_0x1a5027(0xca));const _0x3225be=_0x2ec66d[_0x1a5027(0xc8)](_0x1caaa7);if(!_0x3225be[_0x1a5027(0xd8)]){const _0x2d1f97=_0x3225be[_0x1a5027(0xf4)][_0x1a5027(0xed)][0x0],_0x2bc6f5=formatZodPath(_0x2d1f97[_0x1a5027(0xcc)]);throw new Error(_0x2bc6f5?'YAML\x20validation\x20error\x20at\x20\x27'+_0x2bc6f5+'\x27:\x20'+_0x2d1f97[_0x1a5027(0xec)]:_0x1a5027(0xd5)+_0x2d1f97[_0x1a5027(0xec)]);}return _0x3225be[_0x1a5027(0xd7)];}export function formatIssueWithContext(_0x2c8915,_0x5cb7d3,_0x177303){const _0x2c1fa0=a166_0x47c1,_0x38a94c=[],_0x487433=_0x2c8915[_0x2c1fa0(0xe1)]===_0x2c1fa0(0xf4),_0x4fb76a=_0x487433?a166_0x136c87[_0x2c1fa0(0xf2)]:a166_0x136c87['yellow'],_0x12dbbc=_0x487433?a166_0x136c87[_0x2c1fa0(0xf2)]:a166_0x136c87['yellow'],_0x2e1213=_0x177303?a166_0x136c87[_0x2c1fa0(0xd9)](_0x177303+':'):'';if(_0x2c8915[_0x2c1fa0(0xea)]){const _0x4d7a30=a166_0x136c87[_0x2c1fa0(0xd9)](_0x2c8915[_0x2c1fa0(0xea)]['line']+':'+_0x2c8915[_0x2c1fa0(0xea)][_0x2c1fa0(0xdd)]);_0x38a94c[_0x2c1fa0(0xe5)](''+_0x2e1213+_0x4d7a30+':\x20'+_0x4fb76a(_0x2c8915[_0x2c1fa0(0xe1)])+'\x20'+_0x12dbbc('['+_0x2c8915['code']+']'));}else _0x38a94c[_0x2c1fa0(0xe5)](''+_0x2e1213+a166_0x136c87[_0x2c1fa0(0xd4)](_0x2c8915[_0x2c1fa0(0xcc)])+':\x20'+_0x4fb76a(_0x2c8915[_0x2c1fa0(0xe1)])+'\x20'+_0x12dbbc('['+_0x2c8915[_0x2c1fa0(0xee)]+']'));_0x38a94c[_0x2c1fa0(0xe5)](_0x2c8915[_0x2c1fa0(0xec)]);if(_0x2c8915[_0x2c1fa0(0xea)]&&_0x5cb7d3){const _0x3d2920=_0x5cb7d3['split']('\x0a'),{line:_0x22ce0c,column:_0x57d2a1}=_0x2c8915[_0x2c1fa0(0xea)],_0xea5663=Math[_0x2c1fa0(0xdc)](0x1,_0x22ce0c-0x1),_0x169114=Math[_0x2c1fa0(0xf1)](_0x3d2920[_0x2c1fa0(0xef)],_0x22ce0c+0x1);_0x38a94c[_0x2c1fa0(0xe5)]('');for(let _0x53e3b5=_0xea5663;_0x53e3b5<=_0x169114;_0x53e3b5++){const _0x318579=_0x3d2920[_0x53e3b5-0x1]||'',_0x39dfa7=a166_0x136c87[_0x2c1fa0(0xd4)](_0x53e3b5[_0x2c1fa0(0xd2)]()['padStart'](0x4)),_0x202920=a166_0x136c87[_0x2c1fa0(0xd4)](_0x2c1fa0(0xeb));if(_0x53e3b5===_0x22ce0c){_0x38a94c[_0x2c1fa0(0xe5)]('\x20\x20'+_0x39dfa7+_0x202920+_0x4fb76a(_0x318579));const _0x2aa194='\x20'[_0x2c1fa0(0xda)](0x4+0x3+_0x57d2a1-0x1);_0x38a94c['push']('\x20\x20'+_0x2aa194+_0x4fb76a('^'));}else _0x38a94c[_0x2c1fa0(0xe5)]('\x20\x20'+_0x39dfa7+_0x202920+a166_0x136c87[_0x2c1fa0(0xd4)](_0x318579));}}return _0x38a94c[_0x2c1fa0(0xe4)]('\x0a');}export function formatValidationResult(_0x3873a2,_0x1ba4a2,_0x2d7c80){const _0x4e0410=a166_0x47c1,_0x895f8c=[];for(const _0x516835 of _0x3873a2[_0x4e0410(0xce)]){_0x895f8c[_0x4e0410(0xe5)](formatIssueWithContext(_0x516835,_0x1ba4a2,_0x2d7c80)),_0x895f8c[_0x4e0410(0xe5)]('');}for(const _0x286665 of _0x3873a2['warnings']){_0x895f8c[_0x4e0410(0xe5)](formatIssueWithContext(_0x286665,_0x1ba4a2,_0x2d7c80)),_0x895f8c[_0x4e0410(0xe5)]('');}return _0x895f8c[_0x4e0410(0xe4)]('\x0a');}
1
+ (function(_0x8a5b6c,_0x453190){const _0x101012=a166_0x181e,_0xa7df04=_0x8a5b6c();while(!![]){try{const _0x21013e=parseInt(_0x101012(0x121))/0x1+-parseInt(_0x101012(0x13a))/0x2+parseInt(_0x101012(0x13e))/0x3*(parseInt(_0x101012(0x118))/0x4)+-parseInt(_0x101012(0x11d))/0x5+-parseInt(_0x101012(0x136))/0x6+-parseInt(_0x101012(0x13c))/0x7*(-parseInt(_0x101012(0x116))/0x8)+parseInt(_0x101012(0x11f))/0x9;if(_0x21013e===_0x453190)break;else _0xa7df04['push'](_0xa7df04['shift']());}catch(_0x19a82c){_0xa7df04['push'](_0xa7df04['shift']());}}}(a166_0x30f4,0x72c0f));function a166_0x30f4(){const _0x441059=['errors','max','issues','split','invalid_union','YAML\x20validation\x20error\x20at\x20\x27','\x20|\x20','repeat','location','4335744GvxlSj','red','number','safeParse','234600JPgsjk','getIn','701505zrzvYi','Invalid\x20YAML:\x20expected\x20an\x20object','288pTZugr','pop','range','48jGSeuj','length','16448ZnBgPI','min','push','success','cyan','2979890VcOace','level','2471067kOrSlg','dim','635328kegHTj','path','message','data','flatMap','column','\x27:\x20','error','code','object','join','yellow'];a166_0x30f4=function(){return _0x441059;};return a166_0x30f4();}import*as a166_0x5bd8f5 from'yaml';function a166_0x181e(_0x4d3f63,_0x579b8d){_0x4d3f63=_0x4d3f63-0x114;const _0x30f473=a166_0x30f4();let _0x181e36=_0x30f473[_0x4d3f63];return _0x181e36;}import a166_0x4b51cd from'chalk';export{validateSegmentDef,validateRuleDef}from'./segment-validator.js';export function getLocationFromPath(_0x3de3c4,_0x14c03d,_0x3b4880){const _0x5f29c0=a166_0x181e;if(!_0x3de3c4||!_0x14c03d)return undefined;try{let _0x12feba=_0x3de3c4[_0x5f29c0(0x13b)](_0x3b4880,!![]),_0x2d2485=[..._0x3b4880];while((!_0x12feba||typeof _0x12feba!==_0x5f29c0(0x12a)||!(_0x5f29c0(0x115)in _0x12feba)||!_0x12feba['range'])&&_0x2d2485[_0x5f29c0(0x117)]>0x0){_0x2d2485[_0x5f29c0(0x114)](),_0x12feba=_0x2d2485['length']>0x0?_0x3de3c4['getIn'](_0x2d2485,!![]):_0x3de3c4['contents'];}if(!_0x12feba||typeof _0x12feba!==_0x5f29c0(0x12a)||!(_0x5f29c0(0x115)in _0x12feba)||!_0x12feba[_0x5f29c0(0x115)])return undefined;const [_0x52e2e6]=_0x12feba[_0x5f29c0(0x115)];return offsetToLocation(_0x14c03d,_0x52e2e6);}catch{return undefined;}}export function offsetToLocation(_0x3d695d,_0x91a65c){const _0x6aec07=a166_0x181e;let _0x47621a=0x1,_0x373044=0x1;for(let _0x3ac15e=0x0;_0x3ac15e<_0x91a65c&&_0x3ac15e<_0x3d695d[_0x6aec07(0x117)];_0x3ac15e++){_0x3d695d[_0x3ac15e]==='\x0a'?(_0x47621a++,_0x373044=0x1):_0x373044++;}return{'line':_0x47621a,'column':_0x373044,'offset':_0x91a65c};}export function pathToArray(_0x3252ad){const _0x2a13fa=a166_0x181e;if(!_0x3252ad)return[];return _0x3252ad[_0x2a13fa(0x130)]('.')[_0x2a13fa(0x125)](_0xda9e5f=>{const _0x18592c=_0xda9e5f['match'](/^(\w+)\[(\d+)\]$/);if(_0x18592c)return[_0x18592c[0x1],parseInt(_0x18592c[0x2],0xa)];return[_0xda9e5f];});}export function formatZodPath(_0xa2e516){const _0x9417c5=a166_0x181e;let _0x58c65b='';for(const _0x4af46f of _0xa2e516){if(typeof _0x4af46f===_0x9417c5(0x138))_0x58c65b+='['+_0x4af46f+']';else{const _0x562c32=String(_0x4af46f);_0x58c65b+=_0x58c65b?'.'+_0x562c32:_0x562c32;}}return _0x58c65b;}export function flattenZodIssues(_0x3e9938){const _0x3c9d9f=a166_0x181e,_0x22907d=[];for(const _0x123e2c of _0x3e9938){if(_0x123e2c[_0x3c9d9f(0x129)]===_0x3c9d9f(0x131)&&_0x3c9d9f(0x12d)in _0x123e2c){const _0x18b7ad=_0x123e2c[_0x3c9d9f(0x12d)];let _0x2b5236=_0x18b7ad[0x0]||[];for(const _0x39ad6c of _0x18b7ad){_0x39ad6c[_0x3c9d9f(0x117)]<_0x2b5236[_0x3c9d9f(0x117)]&&(_0x2b5236=_0x39ad6c);}const _0x1b125b=_0x2b5236['map'](_0x4bf436=>({..._0x4bf436,'path':[..._0x123e2c[_0x3c9d9f(0x122)],..._0x4bf436[_0x3c9d9f(0x122)]]}));_0x22907d[_0x3c9d9f(0x11a)](...flattenZodIssues(_0x1b125b));}else _0x22907d[_0x3c9d9f(0x11a)](_0x123e2c);}return _0x22907d;}export function safeParseYaml(_0x1f0a83,_0x3572a7){const _0x461123=a166_0x181e,_0x2dfa5e=a166_0x5bd8f5['parse'](_0x1f0a83);if(!_0x2dfa5e||typeof _0x2dfa5e!==_0x461123(0x12a))throw new Error(_0x461123(0x13d));const _0x1bb825=_0x3572a7[_0x461123(0x139)](_0x2dfa5e);if(!_0x1bb825[_0x461123(0x11b)]){const _0x4ab801=_0x1bb825[_0x461123(0x128)][_0x461123(0x12f)][0x0],_0x588abd=formatZodPath(_0x4ab801['path']);throw new Error(_0x588abd?_0x461123(0x132)+_0x588abd+_0x461123(0x127)+_0x4ab801[_0x461123(0x123)]:'YAML\x20validation\x20error:\x20'+_0x4ab801[_0x461123(0x123)]);}return _0x1bb825[_0x461123(0x124)];}export function formatIssueWithContext(_0x1f2925,_0x45fadc,_0x25715b){const _0x5e247d=a166_0x181e,_0x33037c=[],_0xcbf102=_0x1f2925[_0x5e247d(0x11e)]===_0x5e247d(0x128),_0x492eb8=_0xcbf102?a166_0x4b51cd[_0x5e247d(0x137)]:a166_0x4b51cd[_0x5e247d(0x12c)],_0x21c080=_0xcbf102?a166_0x4b51cd['red']:a166_0x4b51cd[_0x5e247d(0x12c)],_0x54196c=_0x25715b?a166_0x4b51cd[_0x5e247d(0x11c)](_0x25715b+':'):'';if(_0x1f2925[_0x5e247d(0x135)]){const _0x170c29=a166_0x4b51cd[_0x5e247d(0x11c)](_0x1f2925[_0x5e247d(0x135)]['line']+':'+_0x1f2925['location'][_0x5e247d(0x126)]);_0x33037c[_0x5e247d(0x11a)](''+_0x54196c+_0x170c29+':\x20'+_0x492eb8(_0x1f2925[_0x5e247d(0x11e)])+'\x20'+_0x21c080('['+_0x1f2925[_0x5e247d(0x129)]+']'));}else _0x33037c[_0x5e247d(0x11a)](''+_0x54196c+a166_0x4b51cd['dim'](_0x1f2925[_0x5e247d(0x122)])+':\x20'+_0x492eb8(_0x1f2925[_0x5e247d(0x11e)])+'\x20'+_0x21c080('['+_0x1f2925[_0x5e247d(0x129)]+']'));_0x33037c[_0x5e247d(0x11a)](_0x1f2925[_0x5e247d(0x123)]);if(_0x1f2925[_0x5e247d(0x135)]&&_0x45fadc){const _0x2b4ef1=_0x45fadc[_0x5e247d(0x130)]('\x0a'),{line:_0x575676,column:_0x45b801}=_0x1f2925[_0x5e247d(0x135)],_0x3e5f14=Math[_0x5e247d(0x12e)](0x1,_0x575676-0x1),_0x5eea4a=Math[_0x5e247d(0x119)](_0x2b4ef1[_0x5e247d(0x117)],_0x575676+0x1);_0x33037c['push']('');for(let _0xdc3984=_0x3e5f14;_0xdc3984<=_0x5eea4a;_0xdc3984++){const _0x15dc1a=_0x2b4ef1[_0xdc3984-0x1]||'',_0x1e43ca=a166_0x4b51cd[_0x5e247d(0x120)](_0xdc3984['toString']()['padStart'](0x4)),_0x27e0ae=a166_0x4b51cd['dim'](_0x5e247d(0x133));if(_0xdc3984===_0x575676){_0x33037c['push']('\x20\x20'+_0x1e43ca+_0x27e0ae+_0x492eb8(_0x15dc1a));const _0x188607='\x20'[_0x5e247d(0x134)](0x4+0x3+_0x45b801-0x1);_0x33037c['push']('\x20\x20'+_0x188607+_0x492eb8('^'));}else _0x33037c[_0x5e247d(0x11a)]('\x20\x20'+_0x1e43ca+_0x27e0ae+a166_0x4b51cd[_0x5e247d(0x120)](_0x15dc1a));}}return _0x33037c[_0x5e247d(0x12b)]('\x0a');}export function formatValidationResult(_0x2fd03c,_0x576599,_0x2a7b7f){const _0x5d6a39=a166_0x181e,_0x32370f=[];for(const _0x2ba099 of _0x2fd03c['errors']){_0x32370f['push'](formatIssueWithContext(_0x2ba099,_0x576599,_0x2a7b7f)),_0x32370f['push']('');}for(const _0x582be7 of _0x2fd03c['warnings']){_0x32370f[_0x5d6a39(0x11a)](formatIssueWithContext(_0x582be7,_0x576599,_0x2a7b7f)),_0x32370f[_0x5d6a39(0x11a)]('');}return _0x32370f[_0x5d6a39(0x12b)]('\x0a');}