@treasuredata/tdx 2026.4.4 → 2026.4.5

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 (231) 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.d.ts +2 -0
  168. package/dist/sdk/types/workspace.d.ts.map +1 -1
  169. package/dist/sdk/types/workspace.js +1 -1
  170. package/dist/sdk/user.js +1 -1
  171. package/dist/sdk/util/format-detector.js +1 -1
  172. package/dist/sdk/util/formatters.js +1 -1
  173. package/dist/sdk/util/index.js +1 -1
  174. package/dist/sdk/util/paginate.js +1 -1
  175. package/dist/sdk/util/tree-formatter.js +1 -1
  176. package/dist/sdk/workflow/archive-validation.js +1 -1
  177. package/dist/sdk/workflow/clone-workflow.js +1 -1
  178. package/dist/sdk/workflow/index.js +1 -1
  179. package/dist/sdk/workflow/pull-workflow.js +1 -1
  180. package/dist/sdk/workflow/push-workflow.js +1 -1
  181. package/dist/sdk/workflow/tdx-config.js +1 -1
  182. package/dist/sdk/workflow/workflow-utils.js +1 -1
  183. package/dist/sdk/workspace/access-tracker.d.ts +5 -0
  184. package/dist/sdk/workspace/access-tracker.d.ts.map +1 -0
  185. package/dist/sdk/workspace/access-tracker.js +1 -0
  186. package/dist/sdk/workspace/access-tracker.js.map +1 -0
  187. package/dist/sdk/workspace/frontmatter.js +1 -1
  188. package/dist/sdk/workspace/git.d.ts +1 -1
  189. package/dist/sdk/workspace/git.d.ts.map +1 -1
  190. package/dist/sdk/workspace/git.js +1 -1
  191. package/dist/sdk/workspace/git.js.map +1 -1
  192. package/dist/sdk/workspace/index.d.ts +8 -0
  193. package/dist/sdk/workspace/index.d.ts.map +1 -1
  194. package/dist/sdk/workspace/index.js +1 -1
  195. package/dist/sdk/workspace/index.js.map +1 -1
  196. package/dist/sdk/workspace/templates.js +1 -1
  197. package/dist/sdk/workspace/weekly.js +1 -1
  198. package/dist/sdk/workspace/wikilinks.js +1 -1
  199. package/dist/test-utils/command-runner.js +1 -1
  200. package/dist/test-utils/factories.js +1 -1
  201. package/dist/test-utils/fixtures.js +1 -1
  202. package/dist/test-utils/http-mock.js +1 -1
  203. package/dist/test-utils/index.js +1 -1
  204. package/dist/utils/async.js +1 -1
  205. package/dist/utils/colors.js +1 -1
  206. package/dist/utils/diff.js +1 -1
  207. package/dist/utils/file-permissions.js +1 -1
  208. package/dist/utils/file-reader.js +1 -1
  209. package/dist/utils/github-releases.js +1 -1
  210. package/dist/utils/global-cache.js +1 -1
  211. package/dist/utils/json-loader.js +1 -1
  212. package/dist/utils/local-cache.js +1 -1
  213. package/dist/utils/logger/formatters/default-formatter.js +1 -1
  214. package/dist/utils/logger/formatters/index.js +1 -1
  215. package/dist/utils/logger/handlers/console-handler.js +1 -1
  216. package/dist/utils/logger/handlers/file-handler.js +1 -1
  217. package/dist/utils/logger/handlers/index.js +1 -1
  218. package/dist/utils/logger/handlers/null-handler.js +1 -1
  219. package/dist/utils/logger/index.js +1 -1
  220. package/dist/utils/logger/logger.js +1 -1
  221. package/dist/utils/logger/types.js +1 -1
  222. package/dist/utils/option-validation.js +1 -1
  223. package/dist/utils/process.js +1 -1
  224. package/dist/utils/prompt.js +1 -1
  225. package/dist/utils/spinner.js +1 -1
  226. package/dist/utils/sse-parser.js +1 -1
  227. package/dist/utils/string-utils.js +1 -1
  228. package/dist/utils/table-ref-parser.js +1 -1
  229. package/dist/utils/tdx-logger.js +1 -1
  230. package/dist/utils/version-check.js +1 -1
  231. package/package.json +1 -1
@@ -1 +1 @@
1
- (function(_0x3d61c2,_0x552631){const _0x3b70c6=a157_0x30dc,_0x51b74c=_0x3d61c2();while(!![]){try{const _0x489398=parseInt(_0x3b70c6(0xba))/0x1+-parseInt(_0x3b70c6(0xbd))/0x2*(-parseInt(_0x3b70c6(0xaa))/0x3)+parseInt(_0x3b70c6(0xa0))/0x4*(-parseInt(_0x3b70c6(0xa6))/0x5)+parseInt(_0x3b70c6(0xb1))/0x6+-parseInt(_0x3b70c6(0xa1))/0x7+parseInt(_0x3b70c6(0x9e))/0x8*(parseInt(_0x3b70c6(0xc5))/0x9)+parseInt(_0x3b70c6(0xc2))/0xa*(-parseInt(_0x3b70c6(0x9f))/0xb);if(_0x489398===_0x552631)break;else _0x51b74c['push'](_0x51b74c['shift']());}catch(_0x450ca6){_0x51b74c['push'](_0x51b74c['shift']());}}}(a157_0x596d,0xa8a55));import a157_0x46d1c9 from'path';import{sanitizeFileName}from'../../utils/string-utils.js';import{nodeFileSystem}from'../io/node-filesystem.js';import{isYamlFilePath,resolveYamlFilePath}from'./segment-path-parser.js';import{getSegmentRootDir}from'./tdx-config.js';export function isSuccessfulResolution(_0x2096b4){const _0x68a435=a157_0x30dc;return _0x2096b4['type']!==_0x68a435(0x9d);}export function isScopedResolution(_0x5022a7){const _0x127517=a157_0x30dc;return _0x5022a7[_0x127517(0xca)]===_0x127517(0xcc)||_0x5022a7[_0x127517(0xca)]===_0x127517(0xc6)||_0x5022a7[_0x127517(0xca)]===_0x127517(0xcd);}export function getScopedDetails(_0x126da2){const _0x4e89ed=a157_0x30dc;if(isScopedResolution(_0x126da2))return{'isScoped':_0x126da2[_0x4e89ed(0xc1)],'scopedFolderPath':_0x126da2['scopedFolderPath']};return undefined;}function a157_0x596d(){const _0x3aa412=['error','1416OWmlTf','649SyGQfN','16aNsZTH','2569623kJjuky','extname','File\x20not\x20found:\x20','message','includes','1264865DthxAN','readFile','file_not_found','isDirectory','12VNhcoG','tdx.json','No\x20tdx.json\x20found\x20in\x20or\x20above:\x20','startsWith','exists','basename','parentSegment','2819394IuTqnZ','File\x20not\x20found','No\x20tdx.json\x20found','relative','invalid_yaml','no_parent','isFile','Segment\x20and\x20journey\x20files\x20must\x20have\x20.yml\x20or\x20.yaml\x20extension','scopedFolderPath','88681FEpeCD','root','segmentName','373562hAmSHK','configDir','trim','parent_segment','isScoped','29590zQQhNi','journey','resourceType','47727oHhnMa','file','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_config','cwd','type','match','directory','context','join','parse','dirname','No\x20tdx.json\x20found\x20for\x20file:\x20','resolve','folderPath','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','Parent\x20segment\x20not\x20specified','string'];a157_0x596d=function(){return _0x3aa412;};return a157_0x596d();}async function findTdxConfigAsync(_0x586ad5,_0x236cab){const _0x4d9e79=a157_0x30dc;let _0x55ea3c=a157_0x46d1c9[_0x4d9e79(0x98)](_0x586ad5);const _0x23f80c=a157_0x46d1c9[_0x4d9e79(0xcf)](_0x55ea3c)[_0x4d9e79(0xbb)];while(_0x55ea3c!==_0x23f80c){const _0x62ca35=a157_0x46d1c9[_0x4d9e79(0xce)](_0x55ea3c,_0x4d9e79(0xab));if(await _0x236cab[_0x4d9e79(0xae)](_0x62ca35))try{const _0x1fd6af=await _0x236cab[_0x4d9e79(0xa7)](_0x62ca35),_0x3e2872=JSON['parse'](_0x1fd6af);if(_0x3e2872[_0x4d9e79(0xc0)]&&typeof _0x3e2872['parent_segment']===_0x4d9e79(0x9c))return{'configPath':_0x62ca35,'configDir':_0x55ea3c,'parentSegment':_0x3e2872['parent_segment']};}catch{}_0x55ea3c=a157_0x46d1c9[_0x4d9e79(0xd0)](_0x55ea3c);}return null;}function a157_0x30dc(_0x4a9d5f,_0x1ba3e9){_0x4a9d5f=_0x4a9d5f-0x97;const _0x596d41=a157_0x596d();let _0x30dc70=_0x596d41[_0x4a9d5f];return _0x30dc70;}function calculateScopedPath(_0x2164b0,_0x1cf4ad){const _0x1c090a=a157_0x30dc,_0x1284e3=a157_0x46d1c9[_0x1c090a(0xb4)](_0x1cf4ad,_0x2164b0),_0x4d8925=_0x1284e3!==''&&_0x1284e3!=='.'&&!_0x1284e3[_0x1c090a(0xad)]('..');return{'isScoped':_0x4d8925,'scopedFolderPath':_0x4d8925?_0x1284e3['replace'](/\\/g,'/'):''};}export async function resolveTarget(_0x169226){const _0x1590fa=a157_0x30dc,{arg:_0x51356d,contextParent:_0x567193,cwd:cwd=process[_0x1590fa(0xc9)](),fs:fs=nodeFileSystem}=_0x169226;if(_0x51356d&&isYamlFilePath(_0x51356d))try{const _0x2045c9=await resolveYamlFilePath(_0x51356d,fs),_0x298faa=a157_0x46d1c9[_0x1590fa(0x98)](_0x51356d),_0x1ad688=a157_0x46d1c9[_0x1590fa(0xd0)](_0x298faa),_0xafba25=await findTdxConfigAsync(_0x1ad688,fs);if(!_0xafba25){if(_0x567193){const _0x585cfc=a157_0x46d1c9[_0x1590fa(0xd0)](_0x298faa);return{'type':_0x1590fa(0xc6),'parentName':_0x567193,'targetDir':_0x585cfc,'configRoot':_0x585cfc,'filePath':_0x298faa,'resourceName':_0x2045c9['segmentName'],'folderPath':_0x2045c9[_0x1590fa(0x99)],'resourceType':_0x2045c9[_0x1590fa(0xc4)],'isScoped':![],'scopedFolderPath':''};}return{'type':_0x1590fa(0x9d),'errorCode':'no_config','message':_0x1590fa(0x97)+_0x51356d,'arg':_0x51356d,'helpText':_0x1590fa(0xc7)};}const _0x329107=calculateScopedPath(_0x1ad688,_0xafba25['configDir']);return{'type':_0x1590fa(0xc6),'parentName':_0xafba25[_0x1590fa(0xb0)],'targetDir':_0xafba25[_0x1590fa(0xbe)],'configRoot':_0xafba25['configDir'],'filePath':_0x298faa,'resourceName':_0x2045c9[_0x1590fa(0xbc)],'folderPath':_0x2045c9['folderPath'],'resourceType':_0x2045c9[_0x1590fa(0xc4)],'isScoped':_0x329107['isScoped'],'scopedFolderPath':_0x329107[_0x1590fa(0xb9)]};}catch(_0x5cb8b6){const _0x37f55a=_0x5cb8b6 instanceof Error?_0x5cb8b6[_0x1590fa(0xa4)]:String(_0x5cb8b6);if(_0x37f55a['includes'](_0x1590fa(0xb2)))return{'type':'error','errorCode':_0x1590fa(0xa8),'message':_0x1590fa(0xa3)+_0x51356d,'arg':_0x51356d};if(_0x37f55a[_0x1590fa(0xa5)](_0x1590fa(0xb3))){if(_0x567193){const _0x34d775=a157_0x46d1c9[_0x1590fa(0x98)](_0x51356d);if(await fs[_0x1590fa(0xae)](_0x34d775)){const _0x80c0c1=a157_0x46d1c9[_0x1590fa(0xd0)](_0x34d775),_0x72bf95=await fs['readFile'](_0x34d775),_0x400399=_0x72bf95[_0x1590fa(0xcb)](/^name:\s*["']?([^"'\n]+)["']?/m),_0xdd2810=_0x72bf95[_0x1590fa(0xcb)](/^type:\s*["']?([^"'\n]+)["']?/m),_0x65b1b0=_0x400399?_0x400399[0x1][_0x1590fa(0xbf)]():a157_0x46d1c9[_0x1590fa(0xaf)](_0x51356d,a157_0x46d1c9[_0x1590fa(0xa2)](_0x51356d)),_0x13e0c6=_0xdd2810&&_0xdd2810[0x1][_0x1590fa(0xbf)]()===_0x1590fa(0xc3)?_0x1590fa(0xc3):'segment';return{'type':'file','parentName':_0x567193,'targetDir':_0x80c0c1,'configRoot':_0x80c0c1,'filePath':_0x34d775,'resourceName':_0x65b1b0,'folderPath':'','resourceType':_0x13e0c6,'isScoped':![],'scopedFolderPath':''};}}return{'type':_0x1590fa(0x9d),'errorCode':_0x1590fa(0xc8),'message':_0x1590fa(0x97)+_0x51356d,'arg':_0x51356d,'helpText':_0x1590fa(0xc7)};}return{'type':_0x1590fa(0x9d),'errorCode':_0x1590fa(0xb5),'message':_0x37f55a,'arg':_0x51356d};}if(_0x51356d){const _0x212b92=a157_0x46d1c9[_0x1590fa(0x98)](cwd,_0x51356d);let _0x24928f=null;try{_0x24928f=await fs['stat'](_0x212b92);}catch{}if(_0x24928f?.[_0x1590fa(0xa9)]()){const _0x5d09ac=await findTdxConfigAsync(_0x212b92,fs);if(_0x5d09ac){const _0x7168c8=calculateScopedPath(_0x212b92,_0x5d09ac['configDir']);return{'type':_0x1590fa(0xcc),'parentName':_0x5d09ac[_0x1590fa(0xb0)],'targetDir':_0x212b92,'configRoot':_0x5d09ac[_0x1590fa(0xbe)],'isScoped':_0x7168c8[_0x1590fa(0xc1)],'scopedFolderPath':_0x7168c8[_0x1590fa(0xb9)]};}if(_0x567193)return{'type':_0x1590fa(0xcc),'parentName':_0x567193,'targetDir':_0x212b92,'configRoot':_0x212b92,'isScoped':![],'scopedFolderPath':''};return{'type':_0x1590fa(0x9d),'errorCode':'no_config','message':_0x1590fa(0xac)+_0x51356d,'arg':_0x51356d,'helpText':_0x1590fa(0xc7)};}if(_0x24928f?.[_0x1590fa(0xb7)]())return{'type':_0x1590fa(0x9d),'errorCode':'invalid_yaml','message':'Not\x20a\x20YAML\x20file:\x20'+_0x51356d,'arg':_0x51356d,'helpText':_0x1590fa(0xb8)};const _0x45efa6=sanitizeFileName(_0x51356d),_0x1854f7=getSegmentRootDir(_0x45efa6,cwd);return{'type':'parent_name','parentName':_0x51356d,'targetDir':_0x1854f7,'configRoot':_0x1854f7};}const _0x1fe326=await findTdxConfigAsync(cwd,fs);if(_0x1fe326){const _0x192a59=calculateScopedPath(cwd,_0x1fe326[_0x1590fa(0xbe)]);return{'type':'context','parentName':_0x1fe326[_0x1590fa(0xb0)],'targetDir':cwd,'configRoot':_0x1fe326[_0x1590fa(0xbe)],'isScoped':_0x192a59['isScoped'],'scopedFolderPath':_0x192a59[_0x1590fa(0xb9)]};}if(_0x567193){const _0x3868c4=sanitizeFileName(_0x567193),_0x58e70b=getSegmentRootDir(_0x3868c4,cwd);return{'type':_0x1590fa(0xcd),'parentName':_0x567193,'targetDir':_0x58e70b,'configRoot':_0x58e70b,'isScoped':![],'scopedFolderPath':''};}return{'type':'error','errorCode':_0x1590fa(0xb6),'message':_0x1590fa(0x9b),'helpText':_0x1590fa(0x9a)};}
1
+ function a157_0x2193(_0x4aa00b,_0x21d789){_0x4aa00b=_0x4aa00b-0x196;const _0x295a46=a157_0x295a();let _0x219366=_0x295a46[_0x4aa00b];return _0x219366;}(function(_0x29005f,_0x315252){const _0x2e43d2=a157_0x2193,_0x524123=_0x29005f();while(!![]){try{const _0x3f9f3b=-parseInt(_0x2e43d2(0x1c5))/0x1+parseInt(_0x2e43d2(0x1a6))/0x2+-parseInt(_0x2e43d2(0x1c0))/0x3*(-parseInt(_0x2e43d2(0x19f))/0x4)+-parseInt(_0x2e43d2(0x1c2))/0x5*(-parseInt(_0x2e43d2(0x1b9))/0x6)+parseInt(_0x2e43d2(0x1a8))/0x7*(-parseInt(_0x2e43d2(0x1bc))/0x8)+parseInt(_0x2e43d2(0x1a5))/0x9*(-parseInt(_0x2e43d2(0x1a2))/0xa)+parseInt(_0x2e43d2(0x1a1))/0xb;if(_0x3f9f3b===_0x315252)break;else _0x524123['push'](_0x524123['shift']());}catch(_0x2e7251){_0x524123['push'](_0x524123['shift']());}}}(a157_0x295a,0xeca17));function a157_0x295a(){const _0x350342=['isFile','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','File\x20not\x20found','error','No\x20tdx.json\x20found\x20in\x20or\x20above:\x20','scopedFolderPath','startsWith','dirname','join','parentSegment','isDirectory','includes','18616txrsqN','resourceType','11793771jqUZdH','69430RVaJJc','basename','File\x20not\x20found:\x20','2097orhMaS','3318630xorEpR','journey','163086laFAvo','No\x20tdx.json\x20found\x20for\x20file:\x20','exists','resolve','Segment\x20and\x20journey\x20files\x20must\x20have\x20.yml\x20or\x20.yaml\x20extension','context','no_config','configDir','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','isScoped','parent_name','folderPath','readFile','segmentName','parent_segment','type','no_parent','24ZlpTBi','file','match','472vZUCjZ','relative','root','directory','591GoZlDm','trim','1391065ToEoEN','Parent\x20segment\x20not\x20specified','invalid_yaml','799626aJyBuj'];a157_0x295a=function(){return _0x350342;};return a157_0x295a();}import a157_0x2a9fbe from'path';import{sanitizeFileName}from'../../utils/string-utils.js';import{nodeFileSystem}from'../io/node-filesystem.js';import{isYamlFilePath,resolveYamlFilePath}from'./segment-path-parser.js';import{getSegmentRootDir}from'./tdx-config.js';export function isSuccessfulResolution(_0x4b981f){const _0x5d7575=a157_0x2193;return _0x4b981f['type']!==_0x5d7575(0x196);}export function isScopedResolution(_0x513bc3){const _0x332be6=a157_0x2193;return _0x513bc3[_0x332be6(0x1b7)]==='directory'||_0x513bc3[_0x332be6(0x1b7)]===_0x332be6(0x1ba)||_0x513bc3[_0x332be6(0x1b7)]===_0x332be6(0x1ad);}export function getScopedDetails(_0x5705e6){const _0x1703ab=a157_0x2193;if(isScopedResolution(_0x5705e6))return{'isScoped':_0x5705e6[_0x1703ab(0x1b1)],'scopedFolderPath':_0x5705e6['scopedFolderPath']};return undefined;}async function findTdxConfigAsync(_0x34822b,_0x4afc13){const _0x5ceb3b=a157_0x2193;let _0x1c1bda=a157_0x2a9fbe[_0x5ceb3b(0x1ab)](_0x34822b);const _0x567b44=a157_0x2a9fbe['parse'](_0x1c1bda)[_0x5ceb3b(0x1be)];while(_0x1c1bda!==_0x567b44){const _0x5a5d61=a157_0x2a9fbe[_0x5ceb3b(0x19b)](_0x1c1bda,'tdx.json');if(await _0x4afc13[_0x5ceb3b(0x1aa)](_0x5a5d61))try{const _0x1acb50=await _0x4afc13[_0x5ceb3b(0x1b4)](_0x5a5d61),_0x5ea709=JSON['parse'](_0x1acb50);if(_0x5ea709[_0x5ceb3b(0x1b6)]&&typeof _0x5ea709[_0x5ceb3b(0x1b6)]==='string')return{'configPath':_0x5a5d61,'configDir':_0x1c1bda,'parentSegment':_0x5ea709['parent_segment']};}catch{}_0x1c1bda=a157_0x2a9fbe[_0x5ceb3b(0x19a)](_0x1c1bda);}return null;}function calculateScopedPath(_0x18f040,_0x24ad3a){const _0x56fa2d=a157_0x2193,_0x80b810=a157_0x2a9fbe[_0x56fa2d(0x1bd)](_0x24ad3a,_0x18f040),_0x408796=_0x80b810!==''&&_0x80b810!=='.'&&!_0x80b810[_0x56fa2d(0x199)]('..');return{'isScoped':_0x408796,'scopedFolderPath':_0x408796?_0x80b810['replace'](/\\/g,'/'):''};}export async function resolveTarget(_0x3208a8){const _0x47ac2a=a157_0x2193,{arg:_0x534b51,contextParent:_0x2b3072,cwd:cwd=process['cwd'](),fs:fs=nodeFileSystem}=_0x3208a8;if(_0x534b51&&isYamlFilePath(_0x534b51))try{const _0x10aaec=await resolveYamlFilePath(_0x534b51,fs),_0x11e84d=a157_0x2a9fbe[_0x47ac2a(0x1ab)](_0x534b51),_0x52d073=a157_0x2a9fbe['dirname'](_0x11e84d),_0x252c0b=await findTdxConfigAsync(_0x52d073,fs);if(!_0x252c0b){if(_0x2b3072){const _0x20c53a=a157_0x2a9fbe[_0x47ac2a(0x19a)](_0x11e84d);return{'type':_0x47ac2a(0x1ba),'parentName':_0x2b3072,'targetDir':_0x20c53a,'configRoot':_0x20c53a,'filePath':_0x11e84d,'resourceName':_0x10aaec[_0x47ac2a(0x1b5)],'folderPath':_0x10aaec[_0x47ac2a(0x1b3)],'resourceType':_0x10aaec[_0x47ac2a(0x1a0)],'isScoped':![],'scopedFolderPath':''};}return{'type':_0x47ac2a(0x196),'errorCode':'no_config','message':_0x47ac2a(0x1a9)+_0x534b51,'arg':_0x534b51,'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 _0xaa3bf0=calculateScopedPath(_0x52d073,_0x252c0b['configDir']);return{'type':_0x47ac2a(0x1ba),'parentName':_0x252c0b[_0x47ac2a(0x19c)],'targetDir':_0x252c0b[_0x47ac2a(0x1af)],'configRoot':_0x252c0b[_0x47ac2a(0x1af)],'filePath':_0x11e84d,'resourceName':_0x10aaec[_0x47ac2a(0x1b5)],'folderPath':_0x10aaec[_0x47ac2a(0x1b3)],'resourceType':_0x10aaec[_0x47ac2a(0x1a0)],'isScoped':_0xaa3bf0[_0x47ac2a(0x1b1)],'scopedFolderPath':_0xaa3bf0[_0x47ac2a(0x198)]};}catch(_0x116795){const _0x1b7de0=_0x116795 instanceof Error?_0x116795['message']:String(_0x116795);if(_0x1b7de0[_0x47ac2a(0x19e)](_0x47ac2a(0x1c8)))return{'type':_0x47ac2a(0x196),'errorCode':'file_not_found','message':_0x47ac2a(0x1a4)+_0x534b51,'arg':_0x534b51};if(_0x1b7de0['includes']('No\x20tdx.json\x20found')){if(_0x2b3072){const _0x4ef227=a157_0x2a9fbe[_0x47ac2a(0x1ab)](_0x534b51);if(await fs[_0x47ac2a(0x1aa)](_0x4ef227)){const _0x47e01f=a157_0x2a9fbe[_0x47ac2a(0x19a)](_0x4ef227),_0x125c6c=await fs[_0x47ac2a(0x1b4)](_0x4ef227),_0x110b81=_0x125c6c[_0x47ac2a(0x1bb)](/^name:\s*["']?([^"'\n]+)["']?/m),_0x417fe9=_0x125c6c[_0x47ac2a(0x1bb)](/^type:\s*["']?([^"'\n]+)["']?/m),_0x41a10c=_0x110b81?_0x110b81[0x1]['trim']():a157_0x2a9fbe[_0x47ac2a(0x1a3)](_0x534b51,a157_0x2a9fbe['extname'](_0x534b51)),_0x5a626e=_0x417fe9&&_0x417fe9[0x1][_0x47ac2a(0x1c1)]()===_0x47ac2a(0x1a7)?_0x47ac2a(0x1a7):'segment';return{'type':'file','parentName':_0x2b3072,'targetDir':_0x47e01f,'configRoot':_0x47e01f,'filePath':_0x4ef227,'resourceName':_0x41a10c,'folderPath':'','resourceType':_0x5a626e,'isScoped':![],'scopedFolderPath':''};}}return{'type':_0x47ac2a(0x196),'errorCode':'no_config','message':'No\x20tdx.json\x20found\x20for\x20file:\x20'+_0x534b51,'arg':_0x534b51,'helpText':_0x47ac2a(0x1c7)};}return{'type':_0x47ac2a(0x196),'errorCode':_0x47ac2a(0x1c4),'message':_0x1b7de0,'arg':_0x534b51};}if(_0x534b51){const _0x1801ed=a157_0x2a9fbe[_0x47ac2a(0x1ab)](cwd,_0x534b51);let _0x331e42=null;try{_0x331e42=await fs['stat'](_0x1801ed);}catch{}if(_0x331e42?.[_0x47ac2a(0x19d)]()){const _0x2642d4=await findTdxConfigAsync(_0x1801ed,fs);if(_0x2642d4){const _0x462ac=calculateScopedPath(_0x1801ed,_0x2642d4[_0x47ac2a(0x1af)]);return{'type':_0x47ac2a(0x1bf),'parentName':_0x2642d4[_0x47ac2a(0x19c)],'targetDir':_0x1801ed,'configRoot':_0x2642d4['configDir'],'isScoped':_0x462ac[_0x47ac2a(0x1b1)],'scopedFolderPath':_0x462ac[_0x47ac2a(0x198)]};}if(_0x2b3072)return{'type':'directory','parentName':_0x2b3072,'targetDir':_0x1801ed,'configRoot':_0x1801ed,'isScoped':![],'scopedFolderPath':''};return{'type':_0x47ac2a(0x196),'errorCode':_0x47ac2a(0x1ae),'message':_0x47ac2a(0x197)+_0x534b51,'arg':_0x534b51,'helpText':_0x47ac2a(0x1c7)};}if(_0x331e42?.[_0x47ac2a(0x1c6)]())return{'type':_0x47ac2a(0x196),'errorCode':_0x47ac2a(0x1c4),'message':'Not\x20a\x20YAML\x20file:\x20'+_0x534b51,'arg':_0x534b51,'helpText':_0x47ac2a(0x1ac)};const _0xeaf7ed=sanitizeFileName(_0x534b51),_0x401951=getSegmentRootDir(_0xeaf7ed,cwd);return{'type':_0x47ac2a(0x1b2),'parentName':_0x534b51,'targetDir':_0x401951,'configRoot':_0x401951};}const _0x32e65d=await findTdxConfigAsync(cwd,fs);if(_0x32e65d){const _0x4557db=calculateScopedPath(cwd,_0x32e65d[_0x47ac2a(0x1af)]);return{'type':'context','parentName':_0x32e65d['parentSegment'],'targetDir':cwd,'configRoot':_0x32e65d[_0x47ac2a(0x1af)],'isScoped':_0x4557db[_0x47ac2a(0x1b1)],'scopedFolderPath':_0x4557db[_0x47ac2a(0x198)]};}if(_0x2b3072){const _0x5d68f8=sanitizeFileName(_0x2b3072),_0xe51d15=getSegmentRootDir(_0x5d68f8,cwd);return{'type':_0x47ac2a(0x1ad),'parentName':_0x2b3072,'targetDir':_0xe51d15,'configRoot':_0xe51d15,'isScoped':![],'scopedFolderPath':''};}return{'type':_0x47ac2a(0x196),'errorCode':_0x47ac2a(0x1b8),'message':_0x47ac2a(0x1c3),'helpText':_0x47ac2a(0x1b0)};}
@@ -1 +1 @@
1
- const a158_0xe467c7=a158_0x2049;function a158_0x2049(_0x58eee5,_0x275b17){_0x58eee5=_0x58eee5-0x1d8;const _0x2731ee=a158_0x2731();let _0x2049db=_0x2731ee[_0x58eee5];return _0x2049db;}(function(_0x2e8bd0,_0x27ec53){const _0x3d228a=a158_0x2049,_0x1f3497=_0x2e8bd0();while(!![]){try{const _0x1b6d38=parseInt(_0x3d228a(0x1e9))/0x1*(-parseInt(_0x3d228a(0x1ea))/0x2)+parseInt(_0x3d228a(0x1f2))/0x3*(parseInt(_0x3d228a(0x1e1))/0x4)+parseInt(_0x3d228a(0x1dd))/0x5+-parseInt(_0x3d228a(0x1dc))/0x6*(parseInt(_0x3d228a(0x1e3))/0x7)+parseInt(_0x3d228a(0x1df))/0x8*(parseInt(_0x3d228a(0x1f4))/0x9)+-parseInt(_0x3d228a(0x1da))/0xa+-parseInt(_0x3d228a(0x1d9))/0xb;if(_0x1b6d38===_0x27ec53)break;else _0x1f3497['push'](_0x1f3497['shift']());}catch(_0x126816){_0x1f3497['push'](_0x1f3497['shift']());}}}(a158_0x2731,0xe1d3f));import{existsSync,readFileSync}from'fs';import a158_0x5cb0fc from'path';const TDX_CONFIG_FILE=a158_0xe467c7(0x1e2),SEGMENTS_DIR=a158_0xe467c7(0x1e8);export function findTdxConfigPath(_0x54bb02=process[a158_0xe467c7(0x1ec)]()){const _0x2ebcaa=a158_0xe467c7;let _0x162e6e=a158_0x5cb0fc[_0x2ebcaa(0x1de)](_0x54bb02);const _0x496014=a158_0x5cb0fc[_0x2ebcaa(0x1f3)](_0x162e6e)['root'];while(_0x162e6e!==_0x496014){const _0xf81187=a158_0x5cb0fc[_0x2ebcaa(0x1ed)](_0x162e6e,TDX_CONFIG_FILE);if(existsSync(_0xf81187))return _0xf81187;_0x162e6e=a158_0x5cb0fc[_0x2ebcaa(0x1d8)](_0x162e6e);}return null;}export function loadTdxConfig(_0x1b23ea){const _0xda04f7=a158_0xe467c7,_0x18984d=readFileSync(_0x1b23ea,'utf-8');let _0x38d5ea;try{_0x38d5ea=JSON[_0xda04f7(0x1f3)](_0x18984d);}catch{throw new Error(_0xda04f7(0x1e7)+_0x1b23ea);}if(!_0x38d5ea||typeof _0x38d5ea!==_0xda04f7(0x1e5))throw new Error(_0xda04f7(0x1e6));const _0x415648=_0x38d5ea,_0x5d2b81=_0x415648[_0xda04f7(0x1f0)]&&typeof _0x415648[_0xda04f7(0x1f0)]===_0xda04f7(0x1e4),_0x2d98c1=_0x415648['engage_workspace']&&typeof _0x415648[_0xda04f7(0x1eb)]===_0xda04f7(0x1e4);if(!_0x5d2b81&&!_0x2d98c1)throw new Error(_0xda04f7(0x1e0));const _0x548732={};return _0x5d2b81&&(_0x548732[_0xda04f7(0x1f0)]=_0x415648[_0xda04f7(0x1f0)]),_0x2d98c1&&(_0x548732['engage_workspace']=_0x415648['engage_workspace']),_0x548732;}export function findTdxConfig(_0x2322d7=process[a158_0xe467c7(0x1ec)]()){const _0x4a3a9d=a158_0xe467c7,_0x20cfc1=findTdxConfigPath(_0x2322d7);if(!_0x20cfc1)throw new Error(_0x4a3a9d(0x1db));const _0x19a0ea=loadTdxConfig(_0x20cfc1),_0x38d634=a158_0x5cb0fc[_0x4a3a9d(0x1d8)](_0x20cfc1);return{'config':_0x19a0ea,'configPath':_0x20cfc1,'configDir':_0x38d634};}export function tryFindTdxConfig(_0x2024cf){try{return findTdxConfig(_0x2024cf);}catch{return null;}}export function getSegmentRootDir(_0x49714c,_0x355e4b=process[a158_0xe467c7(0x1ec)]()){const _0x2038cb=a158_0xe467c7;return a158_0x5cb0fc[_0x2038cb(0x1ed)](_0x355e4b,SEGMENTS_DIR,_0x49714c);}export function getTdxConfigPath(_0x1c8b97,_0x468cef=process[a158_0xe467c7(0x1ec)]()){const _0xefe25a=a158_0xe467c7;return a158_0x5cb0fc[_0xefe25a(0x1ed)](getSegmentRootDir(_0x1c8b97,_0x468cef),TDX_CONFIG_FILE);}function a158_0x2731(){const _0x30ea31=['parse','108flscYN','dirname','10277971fqFFbs','3850380ovnMXw','No\x20tdx.json\x20found.\x20Please\x20run\x20\x27tdx\x20sg\x20pull\x20<parent_segment>\x27\x20first\x20to\x20create\x20the\x20folder\x20structure.','6pEzxUo','8536800FtDHYb','resolve','826104dIUeGs','Invalid\x20tdx.json:\x20must\x20contain\x20\x27parent_segment\x27\x20or\x20\x27engage_workspace\x27\x20field','314564MoCHgh','tdx.json','4416790kHgtbP','string','object','Invalid\x20tdx.json:\x20expected\x20object','Invalid\x20JSON\x20in\x20','segments','163IfXOgf','1838VRLktE','engage_workspace','cwd','join','startsWith','relative','parent_segment','stringify','3HslUEI'];a158_0x2731=function(){return _0x30ea31;};return a158_0x2731();}export function getRelativePathFromConfig(_0x1db4b8,_0x16ecda){const _0x298803=a158_0xe467c7,_0x1daa63=a158_0x5cb0fc[_0x298803(0x1de)](_0x1db4b8),_0x5a6195=a158_0x5cb0fc[_0x298803(0x1ef)](_0x16ecda,_0x1daa63);if(_0x5a6195[_0x298803(0x1ee)]('..'))return'';return _0x5a6195;}export function localPathToTdFolderPath(_0x5f3437){const _0x859e3c=a158_0xe467c7,_0x1b840b=a158_0x5cb0fc[_0x859e3c(0x1d8)](_0x5f3437);if(_0x1b840b==='.'||_0x1b840b==='')return'';return _0x1b840b['replace'](/\\/g,'/');}export function tdFolderPathToLocalPath(_0x315a00,_0x23e70c){if(!_0x315a00)return _0x23e70c;return a158_0x5cb0fc['join'](_0x23e70c,_0x315a00);}export function createTdxConfigContent(_0x249609){const _0x408b87={'parent_segment':_0x249609};return JSON['stringify'](_0x408b87,null,0x2)+'\x0a';}export function createEngageTdxConfigContent(_0x103931){const _0xf0c4dd=a158_0xe467c7,_0x4f1c1f={'engage_workspace':_0x103931};return JSON[_0xf0c4dd(0x1f1)](_0x4f1c1f,null,0x2)+'\x0a';}
1
+ const a158_0x575893=a158_0x247e;(function(_0x27b99b,_0x4f0d20){const _0x2af6d7=a158_0x247e,_0x4e1577=_0x27b99b();while(!![]){try{const _0x3dee23=parseInt(_0x2af6d7(0x11b))/0x1*(parseInt(_0x2af6d7(0x112))/0x2)+-parseInt(_0x2af6d7(0x10f))/0x3*(-parseInt(_0x2af6d7(0x11c))/0x4)+-parseInt(_0x2af6d7(0x11a))/0x5*(parseInt(_0x2af6d7(0x118))/0x6)+-parseInt(_0x2af6d7(0x121))/0x7*(parseInt(_0x2af6d7(0x11d))/0x8)+-parseInt(_0x2af6d7(0x110))/0x9*(-parseInt(_0x2af6d7(0x109))/0xa)+parseInt(_0x2af6d7(0x120))/0xb*(parseInt(_0x2af6d7(0x125))/0xc)+-parseInt(_0x2af6d7(0x10e))/0xd*(parseInt(_0x2af6d7(0x11e))/0xe);if(_0x3dee23===_0x4f0d20)break;else _0x4e1577['push'](_0x4e1577['shift']());}catch(_0x2cdb8a){_0x4e1577['push'](_0x4e1577['shift']());}}}(a158_0x19d5,0x74950));import{existsSync,readFileSync}from'fs';import a158_0x31cfd8 from'path';const TDX_CONFIG_FILE='tdx.json',SEGMENTS_DIR=a158_0x575893(0x126);function a158_0x247e(_0x4d7e8c,_0x2521ad){_0x4d7e8c=_0x4d7e8c-0x109;const _0x19d51d=a158_0x19d5();let _0x247e61=_0x19d51d[_0x4d7e8c];return _0x247e61;}export function findTdxConfigPath(_0x28c05a=process[a158_0x575893(0x113)]()){const _0x23af32=a158_0x575893;let _0x5b67dd=a158_0x31cfd8[_0x23af32(0x111)](_0x28c05a);const _0x453ee1=a158_0x31cfd8['parse'](_0x5b67dd)['root'];while(_0x5b67dd!==_0x453ee1){const _0x294e23=a158_0x31cfd8[_0x23af32(0x119)](_0x5b67dd,TDX_CONFIG_FILE);if(existsSync(_0x294e23))return _0x294e23;_0x5b67dd=a158_0x31cfd8[_0x23af32(0x122)](_0x5b67dd);}return null;}export function loadTdxConfig(_0x4e9c1b){const _0x4b732a=a158_0x575893,_0x8fa6e=readFileSync(_0x4e9c1b,_0x4b732a(0x114));let _0x2ce44b;try{_0x2ce44b=JSON['parse'](_0x8fa6e);}catch{throw new Error('Invalid\x20JSON\x20in\x20'+_0x4e9c1b);}if(!_0x2ce44b||typeof _0x2ce44b!==_0x4b732a(0x11f))throw new Error(_0x4b732a(0x123));const _0x50fb56=_0x2ce44b,_0x3dd477=_0x50fb56[_0x4b732a(0x117)]&&typeof _0x50fb56['parent_segment']===_0x4b732a(0x115),_0x19c1c=_0x50fb56[_0x4b732a(0x10a)]&&typeof _0x50fb56['engage_workspace']==='string';if(!_0x3dd477&&!_0x19c1c)throw new Error(_0x4b732a(0x10d));const _0x48bfa2={};return _0x3dd477&&(_0x48bfa2['parent_segment']=_0x50fb56[_0x4b732a(0x117)]),_0x19c1c&&(_0x48bfa2[_0x4b732a(0x10a)]=_0x50fb56['engage_workspace']),_0x48bfa2;}export function findTdxConfig(_0x35bf5a=process[a158_0x575893(0x113)]()){const _0x1929bc=a158_0x575893,_0x29723b=findTdxConfigPath(_0x35bf5a);if(!_0x29723b)throw new Error(_0x1929bc(0x116));const _0x2391f5=loadTdxConfig(_0x29723b),_0x8db98b=a158_0x31cfd8[_0x1929bc(0x122)](_0x29723b);return{'config':_0x2391f5,'configPath':_0x29723b,'configDir':_0x8db98b};}export function tryFindTdxConfig(_0x1d5831){try{return findTdxConfig(_0x1d5831);}catch{return null;}}export function getSegmentRootDir(_0x22e313,_0x35e9af=process[a158_0x575893(0x113)]()){const _0x2acedd=a158_0x575893;return a158_0x31cfd8[_0x2acedd(0x119)](_0x35e9af,SEGMENTS_DIR,_0x22e313);}export function getTdxConfigPath(_0x312d17,_0x51b011=process['cwd']()){return a158_0x31cfd8['join'](getSegmentRootDir(_0x312d17,_0x51b011),TDX_CONFIG_FILE);}export function getRelativePathFromConfig(_0xa3fbc5,_0x1f539b){const _0x49217d=a158_0x575893,_0x1599d2=a158_0x31cfd8[_0x49217d(0x111)](_0xa3fbc5),_0x37909e=a158_0x31cfd8['relative'](_0x1f539b,_0x1599d2);if(_0x37909e[_0x49217d(0x124)]('..'))return'';return _0x37909e;}function a158_0x19d5(){const _0x413d33=['No\x20tdx.json\x20found.\x20Please\x20run\x20\x27tdx\x20sg\x20pull\x20<parent_segment>\x27\x20first\x20to\x20create\x20the\x20folder\x20structure.','parent_segment','246DHpkQW','join','3390EQGYiB','21LBAWgw','3668TFSpQa','14600eaGQKw','56myNKcG','object','4367kUePbh','1883jVBRSI','dirname','Invalid\x20tdx.json:\x20expected\x20object','startsWith','15324qwoNZo','segments','20cVrSQM','engage_workspace','stringify','replace','Invalid\x20tdx.json:\x20must\x20contain\x20\x27parent_segment\x27\x20or\x20\x27engage_workspace\x27\x20field','4598074mtWyxB','2913KOUenS','1972638GqbidM','resolve','54790gyvVWc','cwd','utf-8','string'];a158_0x19d5=function(){return _0x413d33;};return a158_0x19d5();}export function localPathToTdFolderPath(_0xcb372){const _0x36d0ae=a158_0x575893,_0xaa9a2f=a158_0x31cfd8['dirname'](_0xcb372);if(_0xaa9a2f==='.'||_0xaa9a2f==='')return'';return _0xaa9a2f[_0x36d0ae(0x10c)](/\\/g,'/');}export function tdFolderPathToLocalPath(_0x958211,_0x5d67b3){const _0x436c20=a158_0x575893;if(!_0x958211)return _0x5d67b3;return a158_0x31cfd8[_0x436c20(0x119)](_0x5d67b3,_0x958211);}export function createTdxConfigContent(_0x10b3ee){const _0x2f2e5f=a158_0x575893,_0x1c3d4a={'parent_segment':_0x10b3ee};return JSON[_0x2f2e5f(0x10b)](_0x1c3d4a,null,0x2)+'\x0a';}export function createEngageTdxConfigContent(_0x5c453b){const _0x4ffd96=a158_0x575893,_0x123208={'engage_workspace':_0x5c453b};return JSON[_0x4ffd96(0x10b)](_0x123208,null,0x2)+'\x0a';}
@@ -1 +1 @@
1
- const a159_0x2bf2e1=a159_0x5029;(function(_0x42da5a,_0xb3094a){const _0x47c771=a159_0x5029,_0x38719d=_0x42da5a();while(!![]){try{const _0x56e5c4=parseInt(_0x47c771(0x1be))/0x1+parseInt(_0x47c771(0x1a7))/0x2+-parseInt(_0x47c771(0x1c5))/0x3*(parseInt(_0x47c771(0x1b3))/0x4)+-parseInt(_0x47c771(0x1ce))/0x5+parseInt(_0x47c771(0x1aa))/0x6*(-parseInt(_0x47c771(0x1cb))/0x7)+-parseInt(_0x47c771(0x1c1))/0x8*(-parseInt(_0x47c771(0x1bf))/0x9)+parseInt(_0x47c771(0x1b6))/0xa;if(_0x56e5c4===_0xb3094a)break;else _0x38719d['push'](_0x38719d['shift']());}catch(_0x1ae41e){_0x38719d['push'](_0x38719d['shift']());}}}(a159_0x459d,0xd0176));import{z}from'zod';function a159_0x459d(){const _0x3d76ea=['First','boolean','3862820cekDuv','1190292NUpVVA','Top-N','nullable','915486uIKVCF','rows','object','Activation\x20name\x20is\x20required','none','min','clear','cron','record','25212AmnzNm','asc','week','13043880bwFXRn','enum','masked','desc','month','string','optional','onSuccess','1228860LWijfY','18594TqlsZF','minutes_interval','2936BvtfZx','Last','once','daily','786LDimop','onFailure','monthly','array','union','number','28iWjFCV'];a159_0x459d=function(){return _0x3d76ea;};return a159_0x459d();}export const ScheduleTypeSchema=z['enum']([a159_0x2bf2e1(0x1ae),'hourly',a159_0x2bf2e1(0x1c4),'weekly',a159_0x2bf2e1(0x1c7),a159_0x2bf2e1(0x1b1),a159_0x2bf2e1(0x1c0)]);export const RepeatUnitSchema=z['enum'](['minute','hour','day',a159_0x2bf2e1(0x1b5),a159_0x2bf2e1(0x1ba),a159_0x2bf2e1(0x1c3),a159_0x2bf2e1(0x1ae)]);export const ScheduleDefSchema=z[a159_0x2bf2e1(0x1ac)]({'type':ScheduleTypeSchema['optional'](),'repeat_unit':RepeatUnitSchema[a159_0x2bf2e1(0x1bc)](),'repeat_frequency':z[a159_0x2bf2e1(0x1ca)]()[a159_0x2bf2e1(0x1bc)](),'repeat_sub_frequency':z[a159_0x2bf2e1(0x1c8)](z['number']())[a159_0x2bf2e1(0x1bc)](),'start_at':z[a159_0x2bf2e1(0x1bb)]()[a159_0x2bf2e1(0x1a9)]()['optional'](),'end_on':z[a159_0x2bf2e1(0x1bb)]()[a159_0x2bf2e1(0x1a9)]()[a159_0x2bf2e1(0x1bc)](),'timezone':z[a159_0x2bf2e1(0x1bb)]()['optional']()});function a159_0x5029(_0x1c402f,_0x4011e9){_0x1c402f=_0x1c402f-0x1a7;const _0x459d7c=a159_0x459d();let _0x50292e=_0x459d7c[_0x1c402f];return _0x50292e;}export const NotificationDefSchema=z[a159_0x2bf2e1(0x1ac)]({'notify_on':z[a159_0x2bf2e1(0x1c8)](z[a159_0x2bf2e1(0x1b7)]([a159_0x2bf2e1(0x1bd),a159_0x2bf2e1(0x1c6)]))[a159_0x2bf2e1(0x1bc)](),'email_recipients':z['array'](z[a159_0x2bf2e1(0x1bb)]())['optional']()});export const ActivationColumnDefSchema=z[a159_0x2bf2e1(0x1c9)]([z[a159_0x2bf2e1(0x1bb)](),z[a159_0x2bf2e1(0x1ac)]({'name':z[a159_0x2bf2e1(0x1bb)](),'type':z[a159_0x2bf2e1(0x1bb)]()[a159_0x2bf2e1(0x1bc)](),'visibility':z['enum']([a159_0x2bf2e1(0x1b0),a159_0x2bf2e1(0x1b8)])[a159_0x2bf2e1(0x1bc)]()})]);export const ActivationBehaviorDefSchema=z[a159_0x2bf2e1(0x1ac)]({'columns':z[a159_0x2bf2e1(0x1c8)](z[a159_0x2bf2e1(0x1ac)]({'name':z[a159_0x2bf2e1(0x1bb)](),'type':z[a159_0x2bf2e1(0x1bb)]()[a159_0x2bf2e1(0x1bc)](),'visibility':z[a159_0x2bf2e1(0x1b7)]([a159_0x2bf2e1(0x1b0),a159_0x2bf2e1(0x1b8)])[a159_0x2bf2e1(0x1bc)]()}))[a159_0x2bf2e1(0x1bc)](),'behavior_table':z[a159_0x2bf2e1(0x1bb)]()[a159_0x2bf2e1(0x1bc)](),'join_row':z[a159_0x2bf2e1(0x1ca)]()['nullable']()[a159_0x2bf2e1(0x1bc)](),'join_strategy':z[a159_0x2bf2e1(0x1b7)](['All',a159_0x2bf2e1(0x1cc),a159_0x2bf2e1(0x1c2),a159_0x2bf2e1(0x1a8)])[a159_0x2bf2e1(0x1bc)](),'formatting':z[a159_0x2bf2e1(0x1b7)]([a159_0x2bf2e1(0x1ab),'cols'])[a159_0x2bf2e1(0x1bc)](),'order_by':z['array'](z[a159_0x2bf2e1(0x1ac)]({'key':z[a159_0x2bf2e1(0x1bb)](),'order':z['enum']([a159_0x2bf2e1(0x1b4),a159_0x2bf2e1(0x1b9)])}))['optional']()});export const ActivationDefSchema=z[a159_0x2bf2e1(0x1ac)]({'name':z[a159_0x2bf2e1(0x1bb)]()[a159_0x2bf2e1(0x1af)](0x1,a159_0x2bf2e1(0x1ad)),'description':z[a159_0x2bf2e1(0x1bb)]()[a159_0x2bf2e1(0x1bc)](),'connection':z[a159_0x2bf2e1(0x1bb)]()[a159_0x2bf2e1(0x1af)](0x1,'Connection\x20name\x20is\x20required'),'all_columns':z[a159_0x2bf2e1(0x1cd)]()[a159_0x2bf2e1(0x1bc)](),'columns':z[a159_0x2bf2e1(0x1c8)](ActivationColumnDefSchema)[a159_0x2bf2e1(0x1bc)](),'schedule':ScheduleDefSchema[a159_0x2bf2e1(0x1bc)](),'notification':NotificationDefSchema['optional'](),'connector_config':z[a159_0x2bf2e1(0x1b2)](z['string'](),z['unknown']())['optional'](),'activation_template_id':z[a159_0x2bf2e1(0x1bb)]()[a159_0x2bf2e1(0x1a9)]()['optional'](),'behavior':ActivationBehaviorDefSchema['nullable']()['optional'](),'run_after_journey_refresh':z['boolean']()[a159_0x2bf2e1(0x1bc)](),'nested_workflow_project_name':z[a159_0x2bf2e1(0x1bb)]()[a159_0x2bf2e1(0x1bc)](),'nested_workflow_name':z['string']()['optional'](),'lock_enabled':z['boolean']()['optional']()});
1
+ const a159_0x344182=a159_0x4a34;(function(_0x28692e,_0x2b7fec){const _0x4c851c=a159_0x4a34,_0x126225=_0x28692e();while(!![]){try{const _0x2fa64c=-parseInt(_0x4c851c(0xc7))/0x1+parseInt(_0x4c851c(0xc3))/0x2+-parseInt(_0x4c851c(0xb7))/0x3*(parseInt(_0x4c851c(0xc6))/0x4)+-parseInt(_0x4c851c(0xc0))/0x5*(parseInt(_0x4c851c(0xbc))/0x6)+-parseInt(_0x4c851c(0x9d))/0x7+-parseInt(_0x4c851c(0xb8))/0x8*(-parseInt(_0x4c851c(0xbb))/0x9)+-parseInt(_0x4c851c(0xb4))/0xa*(-parseInt(_0x4c851c(0xb2))/0xb);if(_0x2fa64c===_0x2b7fec)break;else _0x126225['push'](_0x126225['shift']());}catch(_0x4abf42){_0x126225['push'](_0x126225['shift']());}}}(a159_0x3b44,0xbe73f));import{z}from'zod';export const ScheduleTypeSchema=z['enum']([a159_0x344182(0xa0),a159_0x344182(0xa8),a159_0x344182(0xb6),a159_0x344182(0xa9),'monthly',a159_0x344182(0xc2),'minutes_interval']);export const RepeatUnitSchema=z['enum']([a159_0x344182(0xad),a159_0x344182(0xbe),a159_0x344182(0xa4),a159_0x344182(0xbf),a159_0x344182(0xbd),a159_0x344182(0xc5),a159_0x344182(0xa0)]);export const ScheduleDefSchema=z[a159_0x344182(0xae)]({'type':ScheduleTypeSchema[a159_0x344182(0xb3)](),'repeat_unit':RepeatUnitSchema[a159_0x344182(0xb3)](),'repeat_frequency':z[a159_0x344182(0xac)]()[a159_0x344182(0xb3)](),'repeat_sub_frequency':z['array'](z['number']())[a159_0x344182(0xb3)](),'start_at':z[a159_0x344182(0xaf)]()['nullable']()[a159_0x344182(0xb3)](),'end_on':z['string']()[a159_0x344182(0xa3)]()[a159_0x344182(0xb3)](),'timezone':z[a159_0x344182(0xaf)]()[a159_0x344182(0xb3)]()});function a159_0x4a34(_0x185748,_0x2ded01){_0x185748=_0x185748-0x9d;const _0x3b44e8=a159_0x3b44();let _0x4a34d9=_0x3b44e8[_0x185748];return _0x4a34d9;}function a159_0x3b44(){const _0x288d04=['asc','array','number','minute','object','string','masked','union','1135222SOzQWq','optional','190WGrqIO','Activation\x20name\x20is\x20required','daily','508503IOaFPV','3909416KHYJhg','enum','rows','9uhvwGX','84EHJgwi','month','hour','week','890YlPlIy','Last','cron','108594wVGSTp','onSuccess','once','20qajoMe','93292ZDACNG','5462996DYOPTp','desc','First','none','record','Connection\x20name\x20is\x20required','nullable','day','onFailure','clear','unknown','hourly','weekly'];a159_0x3b44=function(){return _0x288d04;};return a159_0x3b44();}export const NotificationDefSchema=z[a159_0x344182(0xae)]({'notify_on':z['array'](z['enum']([a159_0x344182(0xc4),a159_0x344182(0xa5)]))[a159_0x344182(0xb3)](),'email_recipients':z['array'](z[a159_0x344182(0xaf)]())[a159_0x344182(0xb3)]()});export const ActivationColumnDefSchema=z[a159_0x344182(0xb1)]([z[a159_0x344182(0xaf)](),z[a159_0x344182(0xae)]({'name':z[a159_0x344182(0xaf)](),'type':z[a159_0x344182(0xaf)]()[a159_0x344182(0xb3)](),'visibility':z[a159_0x344182(0xb9)]([a159_0x344182(0xa6),a159_0x344182(0xb0)])[a159_0x344182(0xb3)]()})]);export const ActivationBehaviorDefSchema=z[a159_0x344182(0xae)]({'columns':z[a159_0x344182(0xab)](z[a159_0x344182(0xae)]({'name':z[a159_0x344182(0xaf)](),'type':z[a159_0x344182(0xaf)]()[a159_0x344182(0xb3)](),'visibility':z['enum']([a159_0x344182(0xa6),a159_0x344182(0xb0)])['optional']()}))[a159_0x344182(0xb3)](),'behavior_table':z[a159_0x344182(0xaf)]()[a159_0x344182(0xb3)](),'join_row':z[a159_0x344182(0xac)]()[a159_0x344182(0xa3)]()[a159_0x344182(0xb3)](),'join_strategy':z[a159_0x344182(0xb9)](['All',a159_0x344182(0x9f),a159_0x344182(0xc1),'Top-N'])[a159_0x344182(0xb3)](),'formatting':z[a159_0x344182(0xb9)]([a159_0x344182(0xba),'cols'])[a159_0x344182(0xb3)](),'order_by':z[a159_0x344182(0xab)](z[a159_0x344182(0xae)]({'key':z[a159_0x344182(0xaf)](),'order':z[a159_0x344182(0xb9)]([a159_0x344182(0xaa),a159_0x344182(0x9e)])}))[a159_0x344182(0xb3)]()});export const ActivationDefSchema=z[a159_0x344182(0xae)]({'name':z[a159_0x344182(0xaf)]()['min'](0x1,a159_0x344182(0xb5)),'description':z['string']()[a159_0x344182(0xb3)](),'connection':z[a159_0x344182(0xaf)]()['min'](0x1,a159_0x344182(0xa2)),'all_columns':z['boolean']()[a159_0x344182(0xb3)](),'columns':z[a159_0x344182(0xab)](ActivationColumnDefSchema)['optional'](),'schedule':ScheduleDefSchema[a159_0x344182(0xb3)](),'notification':NotificationDefSchema[a159_0x344182(0xb3)](),'connector_config':z[a159_0x344182(0xa1)](z[a159_0x344182(0xaf)](),z[a159_0x344182(0xa7)]())['optional'](),'activation_template_id':z[a159_0x344182(0xaf)]()[a159_0x344182(0xa3)]()[a159_0x344182(0xb3)](),'behavior':ActivationBehaviorDefSchema[a159_0x344182(0xa3)]()[a159_0x344182(0xb3)](),'run_after_journey_refresh':z['boolean']()['optional'](),'nested_workflow_project_name':z['string']()['optional'](),'nested_workflow_name':z[a159_0x344182(0xaf)]()[a159_0x344182(0xb3)](),'lock_enabled':z['boolean']()[a159_0x344182(0xb3)]()});
@@ -1 +1 @@
1
- (function(_0x115d63,_0x41c554){var _0x1e5dec=a160_0x2898,_0x307c16=_0x115d63();while(!![]){try{var _0x59b325=parseInt(_0x1e5dec(0x192))/0x1*(-parseInt(_0x1e5dec(0x195))/0x2)+parseInt(_0x1e5dec(0x191))/0x3*(-parseInt(_0x1e5dec(0x196))/0x4)+parseInt(_0x1e5dec(0x194))/0x5*(-parseInt(_0x1e5dec(0x19a))/0x6)+-parseInt(_0x1e5dec(0x18f))/0x7+parseInt(_0x1e5dec(0x199))/0x8*(parseInt(_0x1e5dec(0x190))/0x9)+-parseInt(_0x1e5dec(0x197))/0xa+-parseInt(_0x1e5dec(0x198))/0xb*(-parseInt(_0x1e5dec(0x193))/0xc);if(_0x59b325===_0x41c554)break;else _0x307c16['push'](_0x307c16['shift']());}catch(_0x45c34c){_0x307c16['push'](_0x307c16['shift']());}}}(a160_0x164b,0x3009b));export{JourneyStateTypeSchema,ReentryModeTypeSchema,WaitUnitTypeSchema,StepTypeValueSchema,EmbeddedSegmentDefSchema,CriteriaDefSchema,StepDefSchema,StageDefSchema,JourneyEntryDefSchema,JourneyDefSchema}from'./journey-schema.js';function a160_0x2898(_0x3f8e07,_0x38686e){_0x3f8e07=_0x3f8e07-0x18f;var _0x164b24=a160_0x164b();var _0x2898c2=_0x164b24[_0x3f8e07];return _0x2898c2;}function a160_0x164b(){var _0x18a10e=['2211860aRQAIt','25371fovjlL','18HKFTWn','25763xAzqQP','9096mmdJjX','5705vXlCld','18dODqlx','89596vqytce','3019770WyBbeM','19283cUMhRg','8FwzxCd','792RAqQNW'];a160_0x164b=function(){return _0x18a10e;};return a160_0x164b();}
1
+ (function(_0x22718e,_0x17a661){var _0x774a78=a160_0x536b,_0x1cde2e=_0x22718e();while(!![]){try{var _0x36c1b2=-parseInt(_0x774a78(0x1ce))/0x1+-parseInt(_0x774a78(0x1cf))/0x2+parseInt(_0x774a78(0x1cd))/0x3+parseInt(_0x774a78(0x1d1))/0x4+-parseInt(_0x774a78(0x1d0))/0x5+-parseInt(_0x774a78(0x1d2))/0x6*(-parseInt(_0x774a78(0x1d3))/0x7)+-parseInt(_0x774a78(0x1d4))/0x8;if(_0x36c1b2===_0x17a661)break;else _0x1cde2e['push'](_0x1cde2e['shift']());}catch(_0x2540bf){_0x1cde2e['push'](_0x1cde2e['shift']());}}}(a160_0x30ac,0x8ffdf));function a160_0x30ac(){var _0x15d6ff=['22358qMDFig','360378zYolQg','3116985pYWhLN','957652nBBPXT','18ouGAnh','357007Cxqnfc','1209328BrufuI','3523455rLjKag'];a160_0x30ac=function(){return _0x15d6ff;};return a160_0x30ac();}function a160_0x536b(_0x584914,_0x49e37a){_0x584914=_0x584914-0x1cd;var _0x30acf8=a160_0x30ac();var _0x536b3d=_0x30acf8[_0x584914];return _0x536b3d;}export{JourneyStateTypeSchema,ReentryModeTypeSchema,WaitUnitTypeSchema,StepTypeValueSchema,EmbeddedSegmentDefSchema,CriteriaDefSchema,StepDefSchema,StageDefSchema,JourneyEntryDefSchema,JourneyDefSchema}from'./journey-schema.js';
@@ -1 +1 @@
1
- const a161_0x243905=a161_0x5ce9;(function(_0x538b96,_0x769131){const _0xe0a56c=a161_0x5ce9,_0x2efd38=_0x538b96();while(!![]){try{const _0x52caad=-parseInt(_0xe0a56c(0x1de))/0x1*(-parseInt(_0xe0a56c(0x1ce))/0x2)+parseInt(_0xe0a56c(0x1e6))/0x3+-parseInt(_0xe0a56c(0x1d7))/0x4*(parseInt(_0xe0a56c(0x1d2))/0x5)+parseInt(_0xe0a56c(0x1e8))/0x6*(parseInt(_0xe0a56c(0x1e7))/0x7)+parseInt(_0xe0a56c(0x1d4))/0x8*(-parseInt(_0xe0a56c(0x1d0))/0x9)+parseInt(_0xe0a56c(0x1e5))/0xa*(parseInt(_0xe0a56c(0x1ec))/0xb)+parseInt(_0xe0a56c(0x1dd))/0xc;if(_0x52caad===_0x769131)break;else _0x2efd38['push'](_0x2efd38['shift']());}catch(_0x19d7dc){_0x2efd38['push'](_0x2efd38['shift']());}}}(a161_0x10b2,0xbc411));import{z}from'zod';import{RuleDefSchema}from'./segment-schema.js';import{ActivationDefSchema}from'./activation-schema.js';function a161_0x5ce9(_0x2ed747,_0x2261fd){_0x2ed747=_0x2ed747-0x1ce;const _0x10b2b3=a161_0x10b2();let _0x5ce98b=_0x10b2b3[_0x2ed747];return _0x5ce98b;}export const JourneyStateTypeSchema=z['enum']([a161_0x243905(0x1f1),a161_0x243905(0x1dc),'launched']);export const ReentryModeTypeSchema=z[a161_0x243905(0x1e4)](['no_reentry',a161_0x243905(0x1ee),a161_0x243905(0x1d3)]);function a161_0x10b2(){const _0x32988c=['2QYvKDL','object','5777829YInQOa','string','11735pReVyD','reentry_always','8VitGKu','day','activation','1736MzfTkf','optional','end','wait','array','simulation','4716444MvzEmk','37809WIvEUi','discriminatedUnion','number','boolean','merge','min','enum','188980wGxPVc','1087491kEwBPS','1679111xvdoKs','6GNWJji','decision_point','record','length','814SxrZHr','journey','reentry_unless_goal_achieved','refine','lazy','draft','literal','Journey\x20name\x20is\x20required','jump','journeys'];a161_0x10b2=function(){return _0x32988c;};return a161_0x10b2();}export const WaitUnitTypeSchema=z[a161_0x243905(0x1e4)]([a161_0x243905(0x1d5),'week']);export const StepTypeValueSchema=z[a161_0x243905(0x1e4)](['wait',a161_0x243905(0x1d6),'decision_point','ab_test',a161_0x243905(0x1e2),a161_0x243905(0x1f4),a161_0x243905(0x1d9)]);export const EmbeddedSegmentDefSchema=z['object']({'description':z[a161_0x243905(0x1d1)]()[a161_0x243905(0x1d8)](),'rule':RuleDefSchema});const JumpTargetDefSchema=z[a161_0x243905(0x1cf)]({'journey':z[a161_0x243905(0x1d1)](),'stage':z[a161_0x243905(0x1d1)](),'bundle_id':z[a161_0x243905(0x1d1)]()[a161_0x243905(0x1d8)]()});export const CriteriaDefSchema=z[a161_0x243905(0x1cf)]({'name':z[a161_0x243905(0x1d1)](),'description':z[a161_0x243905(0x1d1)]()['optional'](),'segment':z['string'](),'target':JumpTargetDefSchema[a161_0x243905(0x1d8)]()});const WaitConditionTimeoutDefSchema=z[a161_0x243905(0x1cf)]({'duration':z[a161_0x243905(0x1e0)](),'unit':WaitUnitTypeSchema,'next':z['string']()['optional']()}),WaitConditionDefSchema=z['object']({'segment':z['string'](),'next':z['string']()['optional'](),'timeout':WaitConditionTimeoutDefSchema[a161_0x243905(0x1d8)]()}),WaitStepParamsDefSchema=z[a161_0x243905(0x1cf)]({'duration':z[a161_0x243905(0x1e0)]()['optional'](),'unit':WaitUnitTypeSchema['optional'](),'wait_until':z['string']()[a161_0x243905(0x1d8)](),'condition':WaitConditionDefSchema[a161_0x243905(0x1d8)](),'days_of_week':z[a161_0x243905(0x1db)](z[a161_0x243905(0x1d1)]())[a161_0x243905(0x1d8)]()}),StepBaseFields={'name':z[a161_0x243905(0x1d1)](),'uuid':z[a161_0x243905(0x1d1)]()[a161_0x243905(0x1d8)](),'next':z[a161_0x243905(0x1d1)]()[a161_0x243905(0x1d8)]()},WaitStepDefSchema=z[a161_0x243905(0x1cf)]({...StepBaseFields,'type':z[a161_0x243905(0x1f2)](a161_0x243905(0x1da)),'with':WaitStepParamsDefSchema}),ActivationStepParamsDefSchema=z[a161_0x243905(0x1cf)]({'activation':z[a161_0x243905(0x1d1)]()}),ActivationStepDefSchema=z[a161_0x243905(0x1cf)]({...StepBaseFields,'type':z[a161_0x243905(0x1f2)](a161_0x243905(0x1d6)),'with':ActivationStepParamsDefSchema}),DecisionBranchDefSchema=z[a161_0x243905(0x1cf)]({'name':z[a161_0x243905(0x1d1)](),'segment':z['string']()['optional'](),'segment_id':z[a161_0x243905(0x1d1)]()[a161_0x243905(0x1d8)](),'excluded':z[a161_0x243905(0x1e1)]()[a161_0x243905(0x1d8)](),'next':z['string']()['optional']()}),DecisionPointStepParamsDefSchema=z[a161_0x243905(0x1cf)]({'branches':z[a161_0x243905(0x1db)](DecisionBranchDefSchema)}),DecisionPointStepDefSchema=z['object']({...StepBaseFields,'type':z[a161_0x243905(0x1f2)](a161_0x243905(0x1e9)),'with':DecisionPointStepParamsDefSchema}),AbTestVariantDefSchema=z['object']({'id':z['string']()[a161_0x243905(0x1d8)](),'name':z['string'](),'percentage':z['number'](),'next':z[a161_0x243905(0x1d1)]()[a161_0x243905(0x1d8)]()}),AbTestStepParamsDefSchema=z[a161_0x243905(0x1cf)]({'variants':z[a161_0x243905(0x1db)](AbTestVariantDefSchema),'unique_id':z[a161_0x243905(0x1d1)]()[a161_0x243905(0x1d8)](),'customized_split':z[a161_0x243905(0x1e1)]()[a161_0x243905(0x1d8)]()}),AbTestStepDefSchema=z[a161_0x243905(0x1cf)]({...StepBaseFields,'type':z[a161_0x243905(0x1f2)]('ab_test'),'with':AbTestStepParamsDefSchema}),MergeStepDefSchema=z[a161_0x243905(0x1cf)]({...StepBaseFields,'type':z[a161_0x243905(0x1f2)](a161_0x243905(0x1e2))}),JumpStepParamsDefSchema=z[a161_0x243905(0x1cf)]({'target':JumpTargetDefSchema}),JumpStepDefSchema=z[a161_0x243905(0x1cf)]({...StepBaseFields,'type':z[a161_0x243905(0x1f2)](a161_0x243905(0x1f4)),'with':JumpStepParamsDefSchema}),EndStepDefSchema=z[a161_0x243905(0x1cf)]({...StepBaseFields,'type':z[a161_0x243905(0x1f2)](a161_0x243905(0x1d9))})['passthrough']();export const StepDefSchema=z[a161_0x243905(0x1df)]('type',[WaitStepDefSchema,ActivationStepDefSchema,DecisionPointStepDefSchema,AbTestStepDefSchema,MergeStepDefSchema,JumpStepDefSchema,EndStepDefSchema]);export const StageDefSchema=z[a161_0x243905(0x1cf)]({'name':z[a161_0x243905(0x1d1)](),'description':z[a161_0x243905(0x1d1)]()[a161_0x243905(0x1d8)](),'id':z[a161_0x243905(0x1d1)]()[a161_0x243905(0x1d8)](),'entry_criteria':CriteriaDefSchema[a161_0x243905(0x1d8)](),'exit_criteria':z[a161_0x243905(0x1db)](CriteriaDefSchema)[a161_0x243905(0x1d8)](),'milestone':CriteriaDefSchema['optional'](),'root_step':z['string']()[a161_0x243905(0x1d8)](),'steps':z['array'](StepDefSchema)['optional']()});export const JourneyEntryDefSchema=z['object']({'name':z['string']()[a161_0x243905(0x1d8)](),'version':z[a161_0x243905(0x1d1)]()[a161_0x243905(0x1d8)](),'state':JourneyStateTypeSchema[a161_0x243905(0x1d8)](),'latest':z[a161_0x243905(0x1e1)]()[a161_0x243905(0x1d8)](),'stages':z[a161_0x243905(0x1db)](StageDefSchema),'id':z['string']()[a161_0x243905(0x1d8)](),'version_number':z[a161_0x243905(0x1e0)]()['optional'](),'goal':CriteriaDefSchema['optional'](),'reentry':ReentryModeTypeSchema[a161_0x243905(0x1d8)]()});export const JourneyDefSchema=z[a161_0x243905(0x1f0)](()=>z[a161_0x243905(0x1cf)]({'type':z['literal'](a161_0x243905(0x1ed)),'name':z['string']()[a161_0x243905(0x1e3)](0x1,a161_0x243905(0x1f3)),'description':z[a161_0x243905(0x1d1)]()[a161_0x243905(0x1d8)](),'bundle_id':z['string']()[a161_0x243905(0x1d8)](),'bundle_name':z[a161_0x243905(0x1d1)]()['optional'](),'folder_id':z['string']()[a161_0x243905(0x1d8)](),'reentry':ReentryModeTypeSchema[a161_0x243905(0x1d8)](),'allow_reentry':z[a161_0x243905(0x1e1)]()[a161_0x243905(0x1d8)](),'goal':CriteriaDefSchema[a161_0x243905(0x1d8)](),'id':z[a161_0x243905(0x1d1)]()[a161_0x243905(0x1d8)](),'version':z[a161_0x243905(0x1d1)]()[a161_0x243905(0x1d8)](),'version_number':z[a161_0x243905(0x1e0)]()[a161_0x243905(0x1d8)](),'stages':z['array'](StageDefSchema)['optional'](),'versions':z['array'](JourneyEntryDefSchema)[a161_0x243905(0x1d8)](),'journeys':z[a161_0x243905(0x1db)](JourneyEntryDefSchema)[a161_0x243905(0x1d8)](),'segments':z['record'](z[a161_0x243905(0x1d1)](),EmbeddedSegmentDefSchema)[a161_0x243905(0x1d8)](),'activations':z[a161_0x243905(0x1ea)](z[a161_0x243905(0x1d1)](),ActivationDefSchema)['optional']()})[a161_0x243905(0x1ef)](_0x4c8eb3=>{const _0x1d71ed=a161_0x243905,_0xdf3390=[_0x4c8eb3[_0x1d71ed(0x1f5)],_0x4c8eb3['stages'],_0x4c8eb3['versions']]['filter'](_0x4a962a=>Array['isArray'](_0x4a962a)&&_0x4a962a[_0x1d71ed(0x1eb)]>0x0)[_0x1d71ed(0x1eb)];return _0xdf3390===0x1;},{'message':'Journey\x20must\x20have\x20exactly\x20one\x20of:\x20journeys,\x20stages,\x20or\x20versions'}));const _syncCheck1=!![],_syncCheck2=!![];void _syncCheck1,void _syncCheck2;
1
+ const a161_0x2b267c=a161_0x675c;(function(_0x22cf2a,_0x341357){const _0x1c417c=a161_0x675c,_0x2fbf67=_0x22cf2a();while(!![]){try{const _0x484fb4=parseInt(_0x1c417c(0x13c))/0x1*(-parseInt(_0x1c417c(0x12f))/0x2)+-parseInt(_0x1c417c(0x148))/0x3*(parseInt(_0x1c417c(0x146))/0x4)+-parseInt(_0x1c417c(0x130))/0x5*(-parseInt(_0x1c417c(0x14d))/0x6)+-parseInt(_0x1c417c(0x131))/0x7+-parseInt(_0x1c417c(0x13b))/0x8+parseInt(_0x1c417c(0x143))/0x9+parseInt(_0x1c417c(0x13e))/0xa;if(_0x484fb4===_0x341357)break;else _0x2fbf67['push'](_0x2fbf67['shift']());}catch(_0x4800a1){_0x2fbf67['push'](_0x2fbf67['shift']());}}}(a161_0x2aee,0xaa3fd));import{z}from'zod';import{RuleDefSchema}from'./segment-schema.js';import{ActivationDefSchema}from'./activation-schema.js';export const JourneyStateTypeSchema=z[a161_0x2b267c(0x152)]([a161_0x2b267c(0x137),a161_0x2b267c(0x139),'launched']);export const ReentryModeTypeSchema=z['enum'](['no_reentry',a161_0x2b267c(0x149),a161_0x2b267c(0x132)]);export const WaitUnitTypeSchema=z[a161_0x2b267c(0x152)](['day',a161_0x2b267c(0x136)]);export const StepTypeValueSchema=z[a161_0x2b267c(0x152)]([a161_0x2b267c(0x150),'activation',a161_0x2b267c(0x142),a161_0x2b267c(0x14b),'merge',a161_0x2b267c(0x12e),'end']);export const EmbeddedSegmentDefSchema=z[a161_0x2b267c(0x144)]({'description':z[a161_0x2b267c(0x13a)]()[a161_0x2b267c(0x14a)](),'rule':RuleDefSchema});const JumpTargetDefSchema=z['object']({'journey':z[a161_0x2b267c(0x13a)](),'stage':z[a161_0x2b267c(0x13a)](),'bundle_id':z[a161_0x2b267c(0x13a)]()[a161_0x2b267c(0x14a)]()});function a161_0x675c(_0x14fee4,_0x5cfeb1){_0x14fee4=_0x14fee4-0x12b;const _0x2aee08=a161_0x2aee();let _0x675c09=_0x2aee08[_0x14fee4];return _0x675c09;}export const CriteriaDefSchema=z[a161_0x2b267c(0x144)]({'name':z[a161_0x2b267c(0x13a)](),'description':z[a161_0x2b267c(0x13a)]()['optional'](),'segment':z[a161_0x2b267c(0x13a)](),'target':JumpTargetDefSchema[a161_0x2b267c(0x14a)]()});const WaitConditionTimeoutDefSchema=z[a161_0x2b267c(0x144)]({'duration':z[a161_0x2b267c(0x140)](),'unit':WaitUnitTypeSchema,'next':z[a161_0x2b267c(0x13a)]()[a161_0x2b267c(0x14a)]()}),WaitConditionDefSchema=z[a161_0x2b267c(0x144)]({'segment':z[a161_0x2b267c(0x13a)](),'next':z['string']()['optional'](),'timeout':WaitConditionTimeoutDefSchema[a161_0x2b267c(0x14a)]()}),WaitStepParamsDefSchema=z[a161_0x2b267c(0x144)]({'duration':z[a161_0x2b267c(0x140)]()[a161_0x2b267c(0x14a)](),'unit':WaitUnitTypeSchema[a161_0x2b267c(0x14a)](),'wait_until':z[a161_0x2b267c(0x13a)]()[a161_0x2b267c(0x14a)](),'condition':WaitConditionDefSchema[a161_0x2b267c(0x14a)](),'days_of_week':z['array'](z[a161_0x2b267c(0x13a)]())[a161_0x2b267c(0x14a)]()}),StepBaseFields={'name':z['string'](),'uuid':z[a161_0x2b267c(0x13a)]()[a161_0x2b267c(0x14a)](),'next':z[a161_0x2b267c(0x13a)]()[a161_0x2b267c(0x14a)]()},WaitStepDefSchema=z[a161_0x2b267c(0x144)]({...StepBaseFields,'type':z[a161_0x2b267c(0x141)](a161_0x2b267c(0x150)),'with':WaitStepParamsDefSchema}),ActivationStepParamsDefSchema=z['object']({'activation':z[a161_0x2b267c(0x13a)]()}),ActivationStepDefSchema=z[a161_0x2b267c(0x144)]({...StepBaseFields,'type':z[a161_0x2b267c(0x141)](a161_0x2b267c(0x13d)),'with':ActivationStepParamsDefSchema}),DecisionBranchDefSchema=z[a161_0x2b267c(0x144)]({'name':z['string'](),'segment':z[a161_0x2b267c(0x13a)]()['optional'](),'segment_id':z[a161_0x2b267c(0x13a)]()[a161_0x2b267c(0x14a)](),'excluded':z[a161_0x2b267c(0x14f)]()[a161_0x2b267c(0x14a)](),'next':z[a161_0x2b267c(0x13a)]()[a161_0x2b267c(0x14a)]()}),DecisionPointStepParamsDefSchema=z[a161_0x2b267c(0x144)]({'branches':z[a161_0x2b267c(0x14e)](DecisionBranchDefSchema)}),DecisionPointStepDefSchema=z[a161_0x2b267c(0x144)]({...StepBaseFields,'type':z[a161_0x2b267c(0x141)](a161_0x2b267c(0x142)),'with':DecisionPointStepParamsDefSchema}),AbTestVariantDefSchema=z[a161_0x2b267c(0x144)]({'id':z['string']()['optional'](),'name':z[a161_0x2b267c(0x13a)](),'percentage':z[a161_0x2b267c(0x140)](),'next':z[a161_0x2b267c(0x13a)]()[a161_0x2b267c(0x14a)]()}),AbTestStepParamsDefSchema=z['object']({'variants':z[a161_0x2b267c(0x14e)](AbTestVariantDefSchema),'unique_id':z[a161_0x2b267c(0x13a)]()['optional'](),'customized_split':z[a161_0x2b267c(0x14f)]()['optional']()}),AbTestStepDefSchema=z['object']({...StepBaseFields,'type':z[a161_0x2b267c(0x141)](a161_0x2b267c(0x14b)),'with':AbTestStepParamsDefSchema}),MergeStepDefSchema=z[a161_0x2b267c(0x144)]({...StepBaseFields,'type':z[a161_0x2b267c(0x141)](a161_0x2b267c(0x153))}),JumpStepParamsDefSchema=z[a161_0x2b267c(0x144)]({'target':JumpTargetDefSchema}),JumpStepDefSchema=z['object']({...StepBaseFields,'type':z[a161_0x2b267c(0x141)](a161_0x2b267c(0x12e)),'with':JumpStepParamsDefSchema}),EndStepDefSchema=z['object']({...StepBaseFields,'type':z[a161_0x2b267c(0x141)]('end')})['passthrough']();function a161_0x2aee(){const _0x3fc50f=['214514EyqFJA','95VmFGFz','4031482SgXzeV','reentry_always','isArray','record','Journey\x20must\x20have\x20exactly\x20one\x20of:\x20journeys,\x20stages,\x20or\x20versions','week','draft','type','simulation','string','9108536fwoWVO','2miwkMh','activation','15649830rMjkaC','journeys','number','literal','decision_point','12138210lCxBnV','object','lazy','780860vfStNE','Journey\x20name\x20is\x20required','15DfmkBX','reentry_unless_goal_achieved','optional','ab_test','discriminatedUnion','217500IBCthX','array','boolean','wait','filter','enum','merge','length','min','journey','jump'];a161_0x2aee=function(){return _0x3fc50f;};return a161_0x2aee();}export const StepDefSchema=z[a161_0x2b267c(0x14c)](a161_0x2b267c(0x138),[WaitStepDefSchema,ActivationStepDefSchema,DecisionPointStepDefSchema,AbTestStepDefSchema,MergeStepDefSchema,JumpStepDefSchema,EndStepDefSchema]);export const StageDefSchema=z[a161_0x2b267c(0x144)]({'name':z[a161_0x2b267c(0x13a)](),'description':z[a161_0x2b267c(0x13a)]()[a161_0x2b267c(0x14a)](),'id':z[a161_0x2b267c(0x13a)]()[a161_0x2b267c(0x14a)](),'entry_criteria':CriteriaDefSchema[a161_0x2b267c(0x14a)](),'exit_criteria':z[a161_0x2b267c(0x14e)](CriteriaDefSchema)[a161_0x2b267c(0x14a)](),'milestone':CriteriaDefSchema['optional'](),'root_step':z[a161_0x2b267c(0x13a)]()[a161_0x2b267c(0x14a)](),'steps':z[a161_0x2b267c(0x14e)](StepDefSchema)[a161_0x2b267c(0x14a)]()});export const JourneyEntryDefSchema=z[a161_0x2b267c(0x144)]({'name':z[a161_0x2b267c(0x13a)]()[a161_0x2b267c(0x14a)](),'version':z[a161_0x2b267c(0x13a)]()['optional'](),'state':JourneyStateTypeSchema['optional'](),'latest':z[a161_0x2b267c(0x14f)]()[a161_0x2b267c(0x14a)](),'stages':z[a161_0x2b267c(0x14e)](StageDefSchema),'id':z['string']()[a161_0x2b267c(0x14a)](),'version_number':z[a161_0x2b267c(0x140)]()[a161_0x2b267c(0x14a)](),'goal':CriteriaDefSchema[a161_0x2b267c(0x14a)](),'reentry':ReentryModeTypeSchema[a161_0x2b267c(0x14a)]()});export const JourneyDefSchema=z[a161_0x2b267c(0x145)](()=>z[a161_0x2b267c(0x144)]({'type':z['literal'](a161_0x2b267c(0x12d)),'name':z[a161_0x2b267c(0x13a)]()[a161_0x2b267c(0x12c)](0x1,a161_0x2b267c(0x147)),'description':z['string']()[a161_0x2b267c(0x14a)](),'bundle_id':z[a161_0x2b267c(0x13a)]()[a161_0x2b267c(0x14a)](),'bundle_name':z[a161_0x2b267c(0x13a)]()[a161_0x2b267c(0x14a)](),'folder_id':z['string']()[a161_0x2b267c(0x14a)](),'reentry':ReentryModeTypeSchema[a161_0x2b267c(0x14a)](),'allow_reentry':z['boolean']()[a161_0x2b267c(0x14a)](),'goal':CriteriaDefSchema['optional'](),'id':z[a161_0x2b267c(0x13a)]()[a161_0x2b267c(0x14a)](),'version':z[a161_0x2b267c(0x13a)]()[a161_0x2b267c(0x14a)](),'version_number':z[a161_0x2b267c(0x140)]()[a161_0x2b267c(0x14a)](),'stages':z['array'](StageDefSchema)[a161_0x2b267c(0x14a)](),'versions':z[a161_0x2b267c(0x14e)](JourneyEntryDefSchema)['optional'](),'journeys':z[a161_0x2b267c(0x14e)](JourneyEntryDefSchema)[a161_0x2b267c(0x14a)](),'segments':z['record'](z[a161_0x2b267c(0x13a)](),EmbeddedSegmentDefSchema)[a161_0x2b267c(0x14a)](),'activations':z[a161_0x2b267c(0x134)](z[a161_0x2b267c(0x13a)](),ActivationDefSchema)[a161_0x2b267c(0x14a)]()})['refine'](_0x445c25=>{const _0x237551=a161_0x2b267c,_0x744bae=[_0x445c25[_0x237551(0x13f)],_0x445c25['stages'],_0x445c25['versions']][_0x237551(0x151)](_0x5262e0=>Array[_0x237551(0x133)](_0x5262e0)&&_0x5262e0[_0x237551(0x12b)]>0x0)[_0x237551(0x12b)];return _0x744bae===0x1;},{'message':a161_0x2b267c(0x135)}));const _syncCheck1=!![],_syncCheck2=!![];void _syncCheck1,void _syncCheck2;
@@ -1 +1 @@
1
- (function(_0x475a5b,_0x2ad0a3){var _0x486500=a163_0x2b28,_0x509664=_0x475a5b();while(!![]){try{var _0x245d8a=-parseInt(_0x486500(0x15d))/0x1+-parseInt(_0x486500(0x15c))/0x2*(parseInt(_0x486500(0x158))/0x3)+-parseInt(_0x486500(0x15a))/0x4*(parseInt(_0x486500(0x15b))/0x5)+parseInt(_0x486500(0x15e))/0x6+-parseInt(_0x486500(0x159))/0x7+parseInt(_0x486500(0x15f))/0x8+parseInt(_0x486500(0x160))/0x9;if(_0x245d8a===_0x2ad0a3)break;else _0x509664['push'](_0x509664['shift']());}catch(_0xaba9b){_0x509664['push'](_0x509664['shift']());}}}(a163_0x2d5c,0xcb0ff));function a163_0x2b28(_0x21ffdf,_0x5a8d4b){_0x21ffdf=_0x21ffdf-0x158;var _0x2d5c7c=a163_0x2d5c();var _0x2b2827=_0x2d5c7c[_0x21ffdf];return _0x2b2827;}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_0x2d5c(){var _0x324c99=['6712251DfRADj','4azhcZO','3839830tLyeZc','1647664YFOZiL','66796QbqjDs','8688438wPmUiN','11915248RpyGRp','4605759CIcQNw','3ziXiLD'];a163_0x2d5c=function(){return _0x324c99;};return a163_0x2d5c();}
1
+ function a163_0x2729(){var _0x1187bb=['74720wjLtfr','2515443yNYadC','721PRNdhW','6372735LMiafs','1478608SjeScH','4563548TmxFDx','1600878XmcHqQ','6636402OoTCSI'];a163_0x2729=function(){return _0x1187bb;};return a163_0x2729();}(function(_0x27340a,_0x54e27c){var _0x3c8370=a163_0x3d08,_0xf43c53=_0x27340a();while(!![]){try{var _0x13aacc=-parseInt(_0x3c8370(0x180))/0x1+parseInt(_0x3c8370(0x182))/0x2+-parseInt(_0x3c8370(0x17d))/0x3+parseInt(_0x3c8370(0x181))/0x4+parseInt(_0x3c8370(0x17f))/0x5+-parseInt(_0x3c8370(0x17b))/0x6+parseInt(_0x3c8370(0x17e))/0x7*(parseInt(_0x3c8370(0x17c))/0x8);if(_0x13aacc===_0x54e27c)break;else _0xf43c53['push'](_0xf43c53['shift']());}catch(_0x2c60db){_0xf43c53['push'](_0xf43c53['shift']());}}}(a163_0x2729,0xb8431));function a163_0x3d08(_0x368b76,_0x546c9c){_0x368b76=_0x368b76-0x17b;var _0x272952=a163_0x2729();var _0x3d083e=_0x272952[_0x368b76];return _0x3d083e;}export{OperatorTypeSchema,TimeUnitSchema,AggregationTypeSchema,ArrayMatchingSchema,OperatorDefSchema,AggregationDefSchema,TimeWindowDefSchema,FilterColumnConditionDefSchema,FilterRuleDefSchema,ValueConditionDefSchema,BehaviorConditionDefSchema,ColumnConditionDefSchema,CompositeConditionDefSchema,SegmentRefConditionDefSchema,ConditionDefSchema,RuleDefSchema,SegmentDefSchema}from'./segment-schema.js';export{ScheduleTypeSchema,RepeatUnitSchema,ScheduleDefSchema,NotificationDefSchema,ActivationColumnDefSchema,ActivationBehaviorDefSchema,ActivationDefSchema}from'./activation-schema.js';
@@ -1 +1 @@
1
- const a164_0x4e2c8b=a164_0x1755;(function(_0x4b07da,_0x3d1189){const _0x11b087=a164_0x1755,_0x196a99=_0x4b07da();while(!![]){try{const _0x1ec92f=parseInt(_0x11b087(0x20c))/0x1*(-parseInt(_0x11b087(0x208))/0x2)+-parseInt(_0x11b087(0x201))/0x3*(parseInt(_0x11b087(0x236))/0x4)+-parseInt(_0x11b087(0x203))/0x5+-parseInt(_0x11b087(0x213))/0x6*(-parseInt(_0x11b087(0x1fe))/0x7)+parseInt(_0x11b087(0x20f))/0x8*(-parseInt(_0x11b087(0x219))/0x9)+-parseInt(_0x11b087(0x22c))/0xa*(-parseInt(_0x11b087(0x200))/0xb)+parseInt(_0x11b087(0x216))/0xc;if(_0x1ec92f===_0x3d1189)break;else _0x196a99['push'](_0x196a99['shift']());}catch(_0x500a89){_0x196a99['push'](_0x196a99['shift']());}}}(a164_0x4436,0x7abe9));import{z}from'zod';export const OperatorTypeSchema=z['enum']([a164_0x4e2c8b(0x239),a164_0x4e2c8b(0x214),a164_0x4e2c8b(0x22a),a164_0x4e2c8b(0x1f8),'LessEqual','In',a164_0x4e2c8b(0x217),'Regexp',a164_0x4e2c8b(0x22e),a164_0x4e2c8b(0x230),a164_0x4e2c8b(0x228),a164_0x4e2c8b(0x241),a164_0x4e2c8b(0x1f0),a164_0x4e2c8b(0x202),a164_0x4e2c8b(0x23c)]);export const TimeUnitSchema=z[a164_0x4e2c8b(0x20a)](['second',a164_0x4e2c8b(0x1f7),a164_0x4e2c8b(0x225),a164_0x4e2c8b(0x20d),a164_0x4e2c8b(0x232),'month','year']);export const AggregationTypeSchema=z[a164_0x4e2c8b(0x20a)]([a164_0x4e2c8b(0x233),a164_0x4e2c8b(0x235),a164_0x4e2c8b(0x23e),a164_0x4e2c8b(0x23d),a164_0x4e2c8b(0x220),a164_0x4e2c8b(0x222),a164_0x4e2c8b(0x238),a164_0x4e2c8b(0x1fa)]);const TemporalValueSchema=z[a164_0x4e2c8b(0x231)]([z[a164_0x4e2c8b(0x22d)]({'timestamp':z[a164_0x4e2c8b(0x1f2)]()}),z['object']({'last':z[a164_0x4e2c8b(0x231)]([z[a164_0x4e2c8b(0x23f)](),z[a164_0x4e2c8b(0x1ff)](z[a164_0x4e2c8b(0x1f2)](),z['number']())]),'unit':z[a164_0x4e2c8b(0x1f2)]()})]),OperatorValueSchema=z[a164_0x4e2c8b(0x231)]([z[a164_0x4e2c8b(0x1f2)](),z['number'](),z[a164_0x4e2c8b(0x218)](),TemporalValueSchema,z['array'](z[a164_0x4e2c8b(0x231)]([z[a164_0x4e2c8b(0x1f2)](),z[a164_0x4e2c8b(0x23f)](),z[a164_0x4e2c8b(0x218)]()]))]),OPERATORS_REQUIRING_VALUE=new Set([a164_0x4e2c8b(0x239),'Greater',a164_0x4e2c8b(0x1f8),'Less',a164_0x4e2c8b(0x1ef),'In',a164_0x4e2c8b(0x241),a164_0x4e2c8b(0x1f0),a164_0x4e2c8b(0x202),a164_0x4e2c8b(0x22b),'TimeWithinPast',a164_0x4e2c8b(0x228)]),OPERATORS_REQUIRING_UNIT=new Set([a164_0x4e2c8b(0x230),a164_0x4e2c8b(0x228)]);export const OperatorDefSchema=z[a164_0x4e2c8b(0x22d)]({'type':OperatorTypeSchema,'not':z['boolean']()[a164_0x4e2c8b(0x1f4)](),'value':OperatorValueSchema[a164_0x4e2c8b(0x1f4)](),'min':z[a164_0x4e2c8b(0x231)]([z[a164_0x4e2c8b(0x23f)](),z[a164_0x4e2c8b(0x1f2)](),TemporalValueSchema])['optional'](),'max':z['union']([z[a164_0x4e2c8b(0x23f)](),z[a164_0x4e2c8b(0x1f2)](),TemporalValueSchema])[a164_0x4e2c8b(0x1f4)](),'unit':TimeUnitSchema[a164_0x4e2c8b(0x1f4)](),'duration':z[a164_0x4e2c8b(0x22d)]({'day':z[a164_0x4e2c8b(0x23f)]()['optional'](),'week':z['number']()[a164_0x4e2c8b(0x1f4)](),'month':z[a164_0x4e2c8b(0x23f)]()[a164_0x4e2c8b(0x1f4)](),'year':z['number']()[a164_0x4e2c8b(0x1f4)](),'hour':z[a164_0x4e2c8b(0x23f)]()[a164_0x4e2c8b(0x1f4)](),'minute':z[a164_0x4e2c8b(0x23f)]()['optional'](),'second':z[a164_0x4e2c8b(0x23f)]()['optional']()})[a164_0x4e2c8b(0x1f4)](),'from':z[a164_0x4e2c8b(0x22d)]({'last':z[a164_0x4e2c8b(0x231)]([z[a164_0x4e2c8b(0x23f)](),z[a164_0x4e2c8b(0x1f2)]()]),'unit':TimeUnitSchema})[a164_0x4e2c8b(0x1f4)](),'reverse':z[a164_0x4e2c8b(0x218)]()[a164_0x4e2c8b(0x1f4)]()})['superRefine']((_0x41811b,_0x4652aa)=>{const _0x56c4e2=a164_0x4e2c8b;OPERATORS_REQUIRING_VALUE[_0x56c4e2(0x21a)](_0x41811b[_0x56c4e2(0x227)])&&(_0x41811b['value']===undefined||_0x41811b[_0x56c4e2(0x23b)]===null)&&_0x4652aa['addIssue']({'code':_0x56c4e2(0x237),'message':_0x56c4e2(0x1f5)+_0x41811b[_0x56c4e2(0x227)]+_0x56c4e2(0x21f),'path':[_0x56c4e2(0x23b)]}),_0x41811b[_0x56c4e2(0x227)]===_0x56c4e2(0x217)&&_0x41811b[_0x56c4e2(0x210)]===undefined&&_0x41811b[_0x56c4e2(0x21b)]===undefined&&_0x4652aa[_0x56c4e2(0x205)]({'code':'custom','message':_0x56c4e2(0x242),'params':{'validationCode':_0x56c4e2(0x224)}}),OPERATORS_REQUIRING_UNIT['has'](_0x41811b['type'])&&_0x41811b[_0x56c4e2(0x23b)]!==undefined&&!_0x41811b['unit']&&_0x4652aa[_0x56c4e2(0x205)]({'code':_0x56c4e2(0x237),'message':_0x56c4e2(0x1f5)+_0x41811b[_0x56c4e2(0x227)]+_0x56c4e2(0x1f1),'path':[_0x56c4e2(0x209)],'params':{'validationCode':_0x56c4e2(0x20e)}}),_0x41811b['type']===_0x56c4e2(0x23c)&&(!_0x41811b[_0x56c4e2(0x212)]&&_0x4652aa['addIssue']({'code':_0x56c4e2(0x237),'message':_0x56c4e2(0x207),'path':[_0x56c4e2(0x212)]}),!_0x41811b[_0x56c4e2(0x23a)]&&_0x4652aa['addIssue']({'code':_0x56c4e2(0x237),'message':_0x56c4e2(0x1f3),'path':[_0x56c4e2(0x23a)]}));});export const ArrayMatchingSchema=z[a164_0x4e2c8b(0x231)]([z[a164_0x4e2c8b(0x229)](a164_0x4e2c8b(0x1fb)),z['literal']('all'),z[a164_0x4e2c8b(0x22d)]({'atLeast':z[a164_0x4e2c8b(0x23f)]()}),z[a164_0x4e2c8b(0x22d)]({'atMost':z[a164_0x4e2c8b(0x23f)]()}),z['object']({'exactly':z[a164_0x4e2c8b(0x23f)]()})]);function a164_0x4436(){const _0x52582f=['Column','TimeWithinPast','union','week','Count','exclude','Sum','4OLYwGn','custom','First','Equal','from','value','TimeRange','Min','Average','number','array','Contain','Between\x20operator\x20requires\x20\x27min\x27\x20and/or\x20\x27max\x27\x20values','segment','include','LessEqual','StartWith','\x27\x20requires\x20a\x20time\x20unit','string','TimeRange\x20operator\x20requires\x20\x27from\x27','optional','Operator\x20\x27','superRefine','minute','GreaterEqual','operator','Last','any','And','realtime','2009ndhSmU','record','2959GIihJY','1880262CWNRIk','EndWith','4331370YyEtXD','Timestamp\x20column\x20only\x20supports\x20TimeWithinPast,\x20TimeWithinNext,\x20or\x20TimeRange\x20operators\x20(got\x20\x27','addIssue','Behavior','TimeRange\x20operator\x20requires\x20\x27duration\x27','295166QDkVxF','unit','enum','discriminatedUnion','1ApHERp','day','MISSING_TIME_UNIT','153848PAXwhT','min','batch','duration','9738mwLcMa','Greater','timestamp','15664704BdOjqJ','Between','boolean','63EtMKxE','has','max','column','lazy','Segment\x20name\x20is\x20required','\x27\x20requires\x20a\x20value','Max','funnel_stage','CountDistinct','Value','MISSING_BETWEEN_BOUNDS','hour','\x27\x20is\x20only\x20valid\x20for\x20the\x20\x27timestamp\x27\x20column','type','TimeWithinNext','literal','Less','Regexp','18840WFHBrF','object','IsNull'];a164_0x4436=function(){return _0x52582f;};return a164_0x4436();}export const AggregationDefSchema=z[a164_0x4e2c8b(0x20b)](a164_0x4e2c8b(0x227),[z[a164_0x4e2c8b(0x22d)]({'type':z[a164_0x4e2c8b(0x20a)](['Sum',a164_0x4e2c8b(0x23d),a164_0x4e2c8b(0x220),'Average']),'column':z[a164_0x4e2c8b(0x1f2)](),'groupingColumns':z[a164_0x4e2c8b(0x240)](z[a164_0x4e2c8b(0x1f2)]())['optional']()}),z[a164_0x4e2c8b(0x22d)]({'type':z[a164_0x4e2c8b(0x229)](a164_0x4e2c8b(0x233)),'groupingColumns':z['array'](z[a164_0x4e2c8b(0x1f2)]())[a164_0x4e2c8b(0x1f4)]()}),z[a164_0x4e2c8b(0x22d)]({'type':z[a164_0x4e2c8b(0x229)](a164_0x4e2c8b(0x222)),'columns':z[a164_0x4e2c8b(0x240)](z[a164_0x4e2c8b(0x1f2)]())}),z[a164_0x4e2c8b(0x22d)]({'type':z[a164_0x4e2c8b(0x20a)]([a164_0x4e2c8b(0x238),'Last']),'column':z[a164_0x4e2c8b(0x1f2)](),'orderColumn':z['string'](),'groupingColumns':z[a164_0x4e2c8b(0x240)](z[a164_0x4e2c8b(0x1f2)]())['optional']()})]);export const TimeWindowDefSchema=z['object']({'duration':z[a164_0x4e2c8b(0x23f)](),'unit':TimeUnitSchema});const TIMESTAMP_OPERATORS=new Set(['TimeWithinPast',a164_0x4e2c8b(0x228),'TimeRange']);function a164_0x1755(_0x4b7434,_0x4bc291){_0x4b7434=_0x4b7434-0x1ee;const _0x443614=a164_0x4436();let _0x1755cb=_0x443614[_0x4b7434];return _0x1755cb;}export const FilterColumnConditionDefSchema=z[a164_0x4e2c8b(0x22d)]({'type':z[a164_0x4e2c8b(0x229)](a164_0x4e2c8b(0x22f)),'column':z['string'](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema[a164_0x4e2c8b(0x1f4)]()})[a164_0x4e2c8b(0x1f6)]((_0x226daa,_0x465315)=>{const _0xa9104e=a164_0x4e2c8b,_0x1069b5=_0x226daa[_0xa9104e(0x1f9)]['type'];_0x226daa[_0xa9104e(0x21c)]===_0xa9104e(0x215)?!TIMESTAMP_OPERATORS[_0xa9104e(0x21a)](_0x1069b5)&&_0x465315[_0xa9104e(0x205)]({'code':_0xa9104e(0x237),'message':_0xa9104e(0x204)+_0x1069b5+'\x27)','path':['operator',_0xa9104e(0x227)]}):TIMESTAMP_OPERATORS[_0xa9104e(0x21a)](_0x1069b5)&&_0x465315[_0xa9104e(0x205)]({'code':_0xa9104e(0x237),'message':'Operator\x20\x27'+_0x1069b5+_0xa9104e(0x226),'path':[_0xa9104e(0x1f9),'type']});});export const FilterRuleDefSchema=z['object']({'type':z[a164_0x4e2c8b(0x229)](a164_0x4e2c8b(0x1fc)),'conditions':z[a164_0x4e2c8b(0x240)](FilterColumnConditionDefSchema)});export const ValueConditionDefSchema=z[a164_0x4e2c8b(0x21d)](()=>z['object']({'type':z['literal'](a164_0x4e2c8b(0x223)),'attribute':z['string'](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema['optional'](),'exclude':z[a164_0x4e2c8b(0x218)]()[a164_0x4e2c8b(0x1f4)](),'aggregation':AggregationDefSchema[a164_0x4e2c8b(0x1f4)](),'source':z[a164_0x4e2c8b(0x1f2)]()[a164_0x4e2c8b(0x1f4)](),'filter':FilterRuleDefSchema[a164_0x4e2c8b(0x1f4)](),'limit':z[a164_0x4e2c8b(0x23f)]()[a164_0x4e2c8b(0x1f4)]()}));export const BehaviorConditionDefSchema=z[a164_0x4e2c8b(0x21d)](()=>z['object']({'type':z[a164_0x4e2c8b(0x229)](a164_0x4e2c8b(0x206)),'attribute':z[a164_0x4e2c8b(0x1f2)](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema[a164_0x4e2c8b(0x1f4)](),'exclude':z[a164_0x4e2c8b(0x218)]()['optional'](),'aggregation':AggregationDefSchema['optional'](),'source':z[a164_0x4e2c8b(0x1f2)]()[a164_0x4e2c8b(0x1f4)](),'filter':FilterRuleDefSchema['optional'](),'timeWindow':TimeWindowDefSchema[a164_0x4e2c8b(0x1f4)](),'limit':z[a164_0x4e2c8b(0x23f)]()['optional']()}));export const ColumnConditionDefSchema=z[a164_0x4e2c8b(0x22d)]({'type':z[a164_0x4e2c8b(0x229)](a164_0x4e2c8b(0x22f)),'column':z[a164_0x4e2c8b(0x1f2)](),'operator':OperatorDefSchema});export const CompositeConditionDefSchema=z[a164_0x4e2c8b(0x21d)](()=>z[a164_0x4e2c8b(0x22d)]({'type':z[a164_0x4e2c8b(0x20a)]([a164_0x4e2c8b(0x1fc),'Or']),'conditions':z[a164_0x4e2c8b(0x240)](ConditionDefSchema),'description':z[a164_0x4e2c8b(0x1f2)]()[a164_0x4e2c8b(0x1f4)]()}));export const SegmentRefConditionDefSchema=z[a164_0x4e2c8b(0x22d)]({'type':z[a164_0x4e2c8b(0x20a)]([a164_0x4e2c8b(0x1ee),a164_0x4e2c8b(0x234)]),'segment':z[a164_0x4e2c8b(0x1f2)]()[a164_0x4e2c8b(0x210)](0x1,'Segment\x20reference\x20must\x20not\x20be\x20empty')});export const ConditionDefSchema=z['lazy'](()=>z[a164_0x4e2c8b(0x231)]([ValueConditionDefSchema,BehaviorConditionDefSchema,ColumnConditionDefSchema,CompositeConditionDefSchema,SegmentRefConditionDefSchema]));export const RuleDefSchema=z[a164_0x4e2c8b(0x21d)](()=>z[a164_0x4e2c8b(0x22d)]({'type':z[a164_0x4e2c8b(0x20a)](['And','Or']),'conditions':z[a164_0x4e2c8b(0x240)](ConditionDefSchema),'description':z['string']()[a164_0x4e2c8b(0x1f4)]()}));export const SegmentDefSchema=z[a164_0x4e2c8b(0x22d)]({'type':z[a164_0x4e2c8b(0x229)](a164_0x4e2c8b(0x243))[a164_0x4e2c8b(0x1f4)](),'name':z[a164_0x4e2c8b(0x1f2)]()['min'](0x1,a164_0x4e2c8b(0x21e)),'description':z[a164_0x4e2c8b(0x1f2)]()[a164_0x4e2c8b(0x1f4)](),'folder':z['string']()[a164_0x4e2c8b(0x1f4)](),'rule':RuleDefSchema[a164_0x4e2c8b(0x1f4)](),'kind':z[a164_0x4e2c8b(0x20a)]([a164_0x4e2c8b(0x211),a164_0x4e2c8b(0x1fd),a164_0x4e2c8b(0x221)])[a164_0x4e2c8b(0x1f4)](),'visible':z[a164_0x4e2c8b(0x218)]()['optional'](),'activations':z[a164_0x4e2c8b(0x240)](z[a164_0x4e2c8b(0x1fb)]())[a164_0x4e2c8b(0x1f4)]()});const _syncCheck1=!![],_syncCheck2=!![];void _syncCheck1,void _syncCheck2;
1
+ const a164_0x432b63=a164_0x3d34;(function(_0x46f57f,_0x2bfdcb){const _0x268564=a164_0x3d34,_0x25c2db=_0x46f57f();while(!![]){try{const _0x18c4d2=-parseInt(_0x268564(0xa4))/0x1+parseInt(_0x268564(0xa9))/0x2*(-parseInt(_0x268564(0x77))/0x3)+-parseInt(_0x268564(0xb3))/0x4+parseInt(_0x268564(0x9b))/0x5+-parseInt(_0x268564(0xad))/0x6*(parseInt(_0x268564(0x94))/0x7)+parseInt(_0x268564(0xaf))/0x8*(parseInt(_0x268564(0x6d))/0x9)+-parseInt(_0x268564(0xa5))/0xa*(-parseInt(_0x268564(0x81))/0xb);if(_0x18c4d2===_0x2bfdcb)break;else _0x25c2db['push'](_0x25c2db['shift']());}catch(_0x1052ce){_0x25c2db['push'](_0x25c2db['shift']());}}}(a164_0x4a7b,0xa7cd8));function a164_0x4a7b(){const _0x33ea78=['First','string','TimeWithinPast','1134714xUfCTR','Operator\x20\x27','643728sOkasb','boolean','LessEqual','Segment\x20reference\x20must\x20not\x20be\x20empty','1110836prnoLO','addIssue','EndWith','TimeRange\x20operator\x20requires\x20\x27from\x27','IsNull','Last','StartWith','literal','discriminatedUnion','has','Count','array','63osPWLR','TimeRange','\x27\x20requires\x20a\x20value','funnel_stage','lazy','Min','CountDistinct','optional','Value','month','12PqTNbu','Max','\x27\x20is\x20only\x20valid\x20for\x20the\x20\x27timestamp\x27\x20column','Less','type','GreaterEqual','MISSING_TIME_UNIT','max','Contain','object','2083741AwFHpj','superRefine','Greater','union','And','unit','custom','batch','any','Equal','operator','min','include','column','Segment\x20name\x20is\x20required','MISSING_BETWEEN_BOUNDS','realtime','all','record','28uCeTHg','enum','day','Between\x20operator\x20requires\x20\x27min\x27\x20and/or\x20\x27max\x27\x20values','Sum','number','duration','6582315FGxjim','TimeWithinNext','Column','Average','second','segment','\x27\x20requires\x20a\x20time\x20unit','timestamp','value','245295shwohk','10TbmZTV','from','year','Between','51178OHvJSv'];a164_0x4a7b=function(){return _0x33ea78;};return a164_0x4a7b();}import{z}from'zod';export const OperatorTypeSchema=z['enum']([a164_0x432b63(0x8a),a164_0x432b63(0x83),'Less',a164_0x432b63(0x7c),a164_0x432b63(0xb1),'In',a164_0x432b63(0xa8),'Regexp',a164_0x432b63(0xb7),a164_0x432b63(0xac),'TimeWithinNext',a164_0x432b63(0x7f),a164_0x432b63(0x67),'EndWith','TimeRange']);export const TimeUnitSchema=z[a164_0x432b63(0x95)]([a164_0x432b63(0x9f),'minute','hour',a164_0x432b63(0x96),'week',a164_0x432b63(0x76),a164_0x432b63(0xa7)]);export const AggregationTypeSchema=z['enum']([a164_0x432b63(0x6b),a164_0x432b63(0x98),a164_0x432b63(0x9e),a164_0x432b63(0x72),a164_0x432b63(0x78),a164_0x432b63(0x73),a164_0x432b63(0xaa),a164_0x432b63(0x66)]);const TemporalValueSchema=z[a164_0x432b63(0x84)]([z['object']({'timestamp':z[a164_0x432b63(0xab)]()}),z['object']({'last':z['union']([z[a164_0x432b63(0x99)](),z[a164_0x432b63(0x93)](z[a164_0x432b63(0xab)](),z[a164_0x432b63(0x99)]())]),'unit':z[a164_0x432b63(0xab)]()})]),OperatorValueSchema=z[a164_0x432b63(0x84)]([z[a164_0x432b63(0xab)](),z['number'](),z[a164_0x432b63(0xb0)](),TemporalValueSchema,z[a164_0x432b63(0x6c)](z['union']([z[a164_0x432b63(0xab)](),z[a164_0x432b63(0x99)](),z[a164_0x432b63(0xb0)]()]))]),OPERATORS_REQUIRING_VALUE=new Set(['Equal',a164_0x432b63(0x83),'GreaterEqual',a164_0x432b63(0x7a),a164_0x432b63(0xb1),'In',a164_0x432b63(0x7f),a164_0x432b63(0x67),a164_0x432b63(0xb5),'Regexp',a164_0x432b63(0xac),a164_0x432b63(0x9c)]),OPERATORS_REQUIRING_UNIT=new Set([a164_0x432b63(0xac),a164_0x432b63(0x9c)]);export const OperatorDefSchema=z[a164_0x432b63(0x80)]({'type':OperatorTypeSchema,'not':z[a164_0x432b63(0xb0)]()[a164_0x432b63(0x74)](),'value':OperatorValueSchema[a164_0x432b63(0x74)](),'min':z['union']([z[a164_0x432b63(0x99)](),z['string'](),TemporalValueSchema])['optional'](),'max':z['union']([z['number'](),z[a164_0x432b63(0xab)](),TemporalValueSchema])['optional'](),'unit':TimeUnitSchema[a164_0x432b63(0x74)](),'duration':z[a164_0x432b63(0x80)]({'day':z[a164_0x432b63(0x99)]()[a164_0x432b63(0x74)](),'week':z[a164_0x432b63(0x99)]()[a164_0x432b63(0x74)](),'month':z['number']()[a164_0x432b63(0x74)](),'year':z[a164_0x432b63(0x99)]()[a164_0x432b63(0x74)](),'hour':z['number']()[a164_0x432b63(0x74)](),'minute':z[a164_0x432b63(0x99)]()[a164_0x432b63(0x74)](),'second':z[a164_0x432b63(0x99)]()[a164_0x432b63(0x74)]()})[a164_0x432b63(0x74)](),'from':z['object']({'last':z[a164_0x432b63(0x84)]([z[a164_0x432b63(0x99)](),z[a164_0x432b63(0xab)]()]),'unit':TimeUnitSchema})[a164_0x432b63(0x74)](),'reverse':z['boolean']()[a164_0x432b63(0x74)]()})[a164_0x432b63(0x82)]((_0x2b27e0,_0x39b5f9)=>{const _0x2573aa=a164_0x432b63;OPERATORS_REQUIRING_VALUE[_0x2573aa(0x6a)](_0x2b27e0[_0x2573aa(0x7b)])&&(_0x2b27e0[_0x2573aa(0xa3)]===undefined||_0x2b27e0['value']===null)&&_0x39b5f9['addIssue']({'code':_0x2573aa(0x87),'message':_0x2573aa(0xae)+_0x2b27e0[_0x2573aa(0x7b)]+_0x2573aa(0x6f),'path':[_0x2573aa(0xa3)]}),_0x2b27e0[_0x2573aa(0x7b)]===_0x2573aa(0xa8)&&_0x2b27e0['min']===undefined&&_0x2b27e0[_0x2573aa(0x7e)]===undefined&&_0x39b5f9[_0x2573aa(0xb4)]({'code':_0x2573aa(0x87),'message':_0x2573aa(0x97),'params':{'validationCode':_0x2573aa(0x90)}}),OPERATORS_REQUIRING_UNIT[_0x2573aa(0x6a)](_0x2b27e0['type'])&&_0x2b27e0[_0x2573aa(0xa3)]!==undefined&&!_0x2b27e0[_0x2573aa(0x86)]&&_0x39b5f9[_0x2573aa(0xb4)]({'code':_0x2573aa(0x87),'message':_0x2573aa(0xae)+_0x2b27e0[_0x2573aa(0x7b)]+_0x2573aa(0xa1),'path':[_0x2573aa(0x86)],'params':{'validationCode':_0x2573aa(0x7d)}}),_0x2b27e0['type']===_0x2573aa(0x6e)&&(!_0x2b27e0[_0x2573aa(0x9a)]&&_0x39b5f9[_0x2573aa(0xb4)]({'code':'custom','message':'TimeRange\x20operator\x20requires\x20\x27duration\x27','path':[_0x2573aa(0x9a)]}),!_0x2b27e0[_0x2573aa(0xa6)]&&_0x39b5f9[_0x2573aa(0xb4)]({'code':_0x2573aa(0x87),'message':_0x2573aa(0xb6),'path':[_0x2573aa(0xa6)]}));});export const ArrayMatchingSchema=z[a164_0x432b63(0x84)]([z[a164_0x432b63(0x68)](a164_0x432b63(0x89)),z[a164_0x432b63(0x68)](a164_0x432b63(0x92)),z['object']({'atLeast':z[a164_0x432b63(0x99)]()}),z['object']({'atMost':z[a164_0x432b63(0x99)]()}),z[a164_0x432b63(0x80)]({'exactly':z['number']()})]);export const AggregationDefSchema=z[a164_0x432b63(0x69)](a164_0x432b63(0x7b),[z[a164_0x432b63(0x80)]({'type':z[a164_0x432b63(0x95)]([a164_0x432b63(0x98),a164_0x432b63(0x72),'Max',a164_0x432b63(0x9e)]),'column':z[a164_0x432b63(0xab)](),'groupingColumns':z[a164_0x432b63(0x6c)](z[a164_0x432b63(0xab)]())[a164_0x432b63(0x74)]()}),z['object']({'type':z['literal']('Count'),'groupingColumns':z[a164_0x432b63(0x6c)](z['string']())[a164_0x432b63(0x74)]()}),z[a164_0x432b63(0x80)]({'type':z[a164_0x432b63(0x68)](a164_0x432b63(0x73)),'columns':z[a164_0x432b63(0x6c)](z[a164_0x432b63(0xab)]())}),z[a164_0x432b63(0x80)]({'type':z['enum']([a164_0x432b63(0xaa),'Last']),'column':z[a164_0x432b63(0xab)](),'orderColumn':z['string'](),'groupingColumns':z[a164_0x432b63(0x6c)](z[a164_0x432b63(0xab)]())[a164_0x432b63(0x74)]()})]);export const TimeWindowDefSchema=z[a164_0x432b63(0x80)]({'duration':z[a164_0x432b63(0x99)](),'unit':TimeUnitSchema});const TIMESTAMP_OPERATORS=new Set([a164_0x432b63(0xac),a164_0x432b63(0x9c),a164_0x432b63(0x6e)]);export const FilterColumnConditionDefSchema=z[a164_0x432b63(0x80)]({'type':z[a164_0x432b63(0x68)](a164_0x432b63(0x9d)),'column':z[a164_0x432b63(0xab)](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema[a164_0x432b63(0x74)]()})['superRefine']((_0x255ce2,_0x713c95)=>{const _0x2783e7=a164_0x432b63,_0x45551b=_0x255ce2[_0x2783e7(0x8b)]['type'];_0x255ce2[_0x2783e7(0x8e)]===_0x2783e7(0xa2)?!TIMESTAMP_OPERATORS[_0x2783e7(0x6a)](_0x45551b)&&_0x713c95[_0x2783e7(0xb4)]({'code':_0x2783e7(0x87),'message':'Timestamp\x20column\x20only\x20supports\x20TimeWithinPast,\x20TimeWithinNext,\x20or\x20TimeRange\x20operators\x20(got\x20\x27'+_0x45551b+'\x27)','path':['operator',_0x2783e7(0x7b)]}):TIMESTAMP_OPERATORS[_0x2783e7(0x6a)](_0x45551b)&&_0x713c95[_0x2783e7(0xb4)]({'code':_0x2783e7(0x87),'message':_0x2783e7(0xae)+_0x45551b+_0x2783e7(0x79),'path':[_0x2783e7(0x8b),_0x2783e7(0x7b)]});});export const FilterRuleDefSchema=z['object']({'type':z[a164_0x432b63(0x68)](a164_0x432b63(0x85)),'conditions':z[a164_0x432b63(0x6c)](FilterColumnConditionDefSchema)});export const ValueConditionDefSchema=z['lazy'](()=>z[a164_0x432b63(0x80)]({'type':z[a164_0x432b63(0x68)](a164_0x432b63(0x75)),'attribute':z['string'](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema[a164_0x432b63(0x74)](),'exclude':z['boolean']()[a164_0x432b63(0x74)](),'aggregation':AggregationDefSchema[a164_0x432b63(0x74)](),'source':z[a164_0x432b63(0xab)]()[a164_0x432b63(0x74)](),'filter':FilterRuleDefSchema[a164_0x432b63(0x74)](),'limit':z[a164_0x432b63(0x99)]()['optional']()}));export const BehaviorConditionDefSchema=z[a164_0x432b63(0x71)](()=>z[a164_0x432b63(0x80)]({'type':z[a164_0x432b63(0x68)]('Behavior'),'attribute':z['string'](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema[a164_0x432b63(0x74)](),'exclude':z[a164_0x432b63(0xb0)]()[a164_0x432b63(0x74)](),'aggregation':AggregationDefSchema[a164_0x432b63(0x74)](),'source':z[a164_0x432b63(0xab)]()[a164_0x432b63(0x74)](),'filter':FilterRuleDefSchema[a164_0x432b63(0x74)](),'timeWindow':TimeWindowDefSchema[a164_0x432b63(0x74)](),'limit':z[a164_0x432b63(0x99)]()['optional']()}));function a164_0x3d34(_0xc205e5,_0x267c88){_0xc205e5=_0xc205e5-0x66;const _0x4a7bb8=a164_0x4a7b();let _0x3d345a=_0x4a7bb8[_0xc205e5];return _0x3d345a;}export const ColumnConditionDefSchema=z[a164_0x432b63(0x80)]({'type':z[a164_0x432b63(0x68)](a164_0x432b63(0x9d)),'column':z[a164_0x432b63(0xab)](),'operator':OperatorDefSchema});export const CompositeConditionDefSchema=z[a164_0x432b63(0x71)](()=>z[a164_0x432b63(0x80)]({'type':z[a164_0x432b63(0x95)](['And','Or']),'conditions':z[a164_0x432b63(0x6c)](ConditionDefSchema),'description':z['string']()['optional']()}));export const SegmentRefConditionDefSchema=z[a164_0x432b63(0x80)]({'type':z[a164_0x432b63(0x95)]([a164_0x432b63(0x8d),'exclude']),'segment':z[a164_0x432b63(0xab)]()[a164_0x432b63(0x8c)](0x1,a164_0x432b63(0xb2))});export const ConditionDefSchema=z[a164_0x432b63(0x71)](()=>z[a164_0x432b63(0x84)]([ValueConditionDefSchema,BehaviorConditionDefSchema,ColumnConditionDefSchema,CompositeConditionDefSchema,SegmentRefConditionDefSchema]));export const RuleDefSchema=z[a164_0x432b63(0x71)](()=>z[a164_0x432b63(0x80)]({'type':z[a164_0x432b63(0x95)](['And','Or']),'conditions':z[a164_0x432b63(0x6c)](ConditionDefSchema),'description':z[a164_0x432b63(0xab)]()[a164_0x432b63(0x74)]()}));export const SegmentDefSchema=z['object']({'type':z[a164_0x432b63(0x68)](a164_0x432b63(0xa0))['optional'](),'name':z[a164_0x432b63(0xab)]()[a164_0x432b63(0x8c)](0x1,a164_0x432b63(0x8f)),'description':z[a164_0x432b63(0xab)]()['optional'](),'folder':z['string']()[a164_0x432b63(0x74)](),'rule':RuleDefSchema[a164_0x432b63(0x74)](),'kind':z['enum']([a164_0x432b63(0x88),a164_0x432b63(0x91),a164_0x432b63(0x70)])[a164_0x432b63(0x74)](),'visible':z[a164_0x432b63(0xb0)]()['optional'](),'activations':z[a164_0x432b63(0x6c)](z[a164_0x432b63(0x89)]())[a164_0x432b63(0x74)]()});const _syncCheck1=!![],_syncCheck2=!![];void _syncCheck1,void _syncCheck2;
@@ -1 +1 @@
1
- const a165_0x2d0a1c=a165_0x5970;(function(_0x67c88e,_0x5261a1){const _0x70e8f7=a165_0x5970,_0x15d972=_0x67c88e();while(!![]){try{const _0x4d1fc5=parseInt(_0x70e8f7(0x89))/0x1+-parseInt(_0x70e8f7(0x79))/0x2+-parseInt(_0x70e8f7(0x8d))/0x3+parseInt(_0x70e8f7(0x7c))/0x4+parseInt(_0x70e8f7(0x76))/0x5*(parseInt(_0x70e8f7(0x8c))/0x6)+parseInt(_0x70e8f7(0x7d))/0x7*(-parseInt(_0x70e8f7(0x8b))/0x8)+parseInt(_0x70e8f7(0x7b))/0x9;if(_0x4d1fc5===_0x5261a1)break;else _0x15d972['push'](_0x15d972['shift']());}catch(_0x5c1afd){_0x15d972['push'](_0x15d972['shift']());}}}(a165_0x5443,0x2864d));function a165_0x5443(){const _0x3ce82f=['728895oQtxqM','skipped','type','576020HkqucZ','filterType','1994976KtxwIy','1278696WBSYaa','21RIcEJy','not\x20a\x20','toJSON','template','object','YAML\x20parse\x20error:\x20','relative','warnings','valid','email','campaign_type','message','3397jIFiKU','parseDocument','268232pEKxGn','12sWuvjd','846729iwdPKj','YAML_PARSE_ERROR','Failed\x20to\x20parse\x20YAML\x20file\x20(empty\x20or\x20invalid)','campaign','journey','push','segment','result'];a165_0x5443=function(){return _0x3ce82f;};return a165_0x5443();}import{readFileSync}from'fs';import*as a165_0x53559c from'path';import*as a165_0x4e1eff 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_0x2d0a1c(0x86),a165_0x2d0a1c(0x73)]);export function isJourneyDef(_0xd0fceb){const _0x1e8178=a165_0x2d0a1c;return typeof _0xd0fceb===_0x1e8178(0x81)&&_0xd0fceb!==null&&_0x1e8178(0x78)in _0xd0fceb&&_0xd0fceb[_0x1e8178(0x78)]===_0x1e8178(0x72);}function a165_0x5970(_0x4b0c9a,_0x136f2a){_0x4b0c9a=_0x4b0c9a-0x71;const _0x544362=a165_0x5443();let _0x59708c=_0x544362[_0x4b0c9a];return _0x59708c;}export function isCampaignDef(_0x12ecd1){const _0x421f64=a165_0x2d0a1c;if(typeof _0x12ecd1!==_0x421f64(0x81)||_0x12ecd1===null)return![];const _0x2cf9ca=_0x12ecd1,_0x28a9e3=VALID_CAMPAIGN_TYPES['has'](_0x2cf9ca[_0x421f64(0x87)]);if(_0x2cf9ca['type']===_0x421f64(0x71)&&_0x28a9e3)return!![];if(_0x28a9e3&&!_0x2cf9ca[_0x421f64(0x78)])return!![];return![];}export function isTemplateDef(_0x7d5ba3){const _0x2a68d5=a165_0x2d0a1c;return typeof _0x7d5ba3===_0x2a68d5(0x81)&&_0x7d5ba3!==null&&'type'in _0x7d5ba3&&_0x7d5ba3[_0x2a68d5(0x78)]==='template';}export function isValidationResult(_0x129aa7){const _0x110070=a165_0x2d0a1c;return!(_0x110070(0x77)in _0x129aa7);}export function createParseErrorResult(_0x399094,_0x3f52e6,_0x5e594c,_0x352cb3,_0x31b2a6=a165_0x2d0a1c(0x74)){const _0x157632=a165_0x2d0a1c;return{'filePath':_0x399094,'relativePath':_0x3f52e6,'source':_0x5e594c,'result':{'valid':![],'errors':[{'level':'error','path':'','code':_0x157632(0x8e),'message':_0x352cb3}],'warnings':[]},'fileType':_0x31b2a6};}export function validateYamlFile(_0x5e773d,_0x4e3298,_0x51c3ab={}){const _0x596ef3=a165_0x2d0a1c,_0x4f97b7=a165_0x53559c[_0x596ef3(0x83)](_0x4e3298,_0x5e773d)||a165_0x53559c['basename'](_0x5e773d);try{const _0x11809e=readFileSync(_0x5e773d,'utf-8'),_0x1857f3=a165_0x4e1eff[_0x596ef3(0x8a)](_0x11809e),_0x4d182a=_0x1857f3[_0x596ef3(0x7f)]();if(!_0x4d182a)return createParseErrorResult(_0x5e773d,_0x4f97b7,_0x11809e,_0x596ef3(0x8f));let _0x33602d;if(isJourneyDef(_0x4d182a))_0x33602d=_0x596ef3(0x72);else{if(isCampaignDef(_0x4d182a))_0x33602d=_0x596ef3(0x71);else isTemplateDef(_0x4d182a)?_0x33602d=_0x596ef3(0x80):_0x33602d=_0x596ef3(0x74);}if(_0x51c3ab[_0x596ef3(0x7a)]&&_0x33602d!==_0x51c3ab['filterType'])return{'filePath':_0x5e773d,'relativePath':_0x4f97b7,'skipped':!![],'reason':_0x596ef3(0x7e)+_0x51c3ab[_0x596ef3(0x7a)]};const _0x3d1089={'source':_0x11809e,'document':_0x1857f3};let _0x41bae9;if(_0x33602d===_0x596ef3(0x72))_0x41bae9=validateJourneyDef(_0x4d182a,_0x3d1089);else{if(_0x33602d==='campaign')_0x41bae9=validateCampaignDef(_0x4d182a,_0x3d1089);else _0x33602d==='template'?_0x41bae9=validateTemplateDef(_0x4d182a,_0x3d1089):_0x41bae9=validateSegmentDef(_0x4d182a,_0x3d1089);}return{'filePath':_0x5e773d,'relativePath':_0x4f97b7,'source':_0x11809e,'result':_0x41bae9,'fileType':_0x33602d};}catch(_0x2a6543){const _0xbf687b=_0x2a6543 instanceof Error?_0x2a6543[_0x596ef3(0x88)]:String(_0x2a6543);return createParseErrorResult(_0x5e773d,_0x4f97b7,'',_0x596ef3(0x82)+_0xbf687b);}}export function validateYamlFiles(_0x227703,_0x2068a2,_0x534111={}){return _0x227703['map'](_0x40018a=>validateYamlFile(_0x40018a,_0x2068a2,_0x534111));}export function calculateSummary(_0x310187){const _0x37961c=a165_0x2d0a1c;let _0x13ccda=0x0,_0x654756=0x0,_0x262147=0x0,_0x3c6deb=0x0;for(const _0x5befcb of _0x310187){if(!isValidationResult(_0x5befcb)){_0x3c6deb++;continue;}_0x5befcb[_0x37961c(0x75)][_0x37961c(0x85)]?_0x13ccda++:_0x654756++,_0x262147+=_0x5befcb['result'][_0x37961c(0x84)]['length'];}return{'validCount':_0x13ccda,'invalidCount':_0x654756,'warningCount':_0x262147,'skippedCount':_0x3c6deb,'hasErrors':_0x654756>0x0};}
1
+ const a165_0x160561=a165_0x5566;(function(_0x4c8768,_0x248e20){const _0x4a52f1=a165_0x5566,_0x1e1371=_0x4c8768();while(!![]){try{const _0x1d99ba=-parseInt(_0x4a52f1(0x170))/0x1+-parseInt(_0x4a52f1(0x17e))/0x2*(parseInt(_0x4a52f1(0x173))/0x3)+-parseInt(_0x4a52f1(0x16d))/0x4+parseInt(_0x4a52f1(0x17c))/0x5*(parseInt(_0x4a52f1(0x161))/0x6)+parseInt(_0x4a52f1(0x16f))/0x7*(-parseInt(_0x4a52f1(0x169))/0x8)+parseInt(_0x4a52f1(0x164))/0x9*(-parseInt(_0x4a52f1(0x175))/0xa)+parseInt(_0x4a52f1(0x165))/0xb*(parseInt(_0x4a52f1(0x17f))/0xc);if(_0x1d99ba===_0x248e20)break;else _0x1e1371['push'](_0x1e1371['shift']());}catch(_0x11912f){_0x1e1371['push'](_0x1e1371['shift']());}}}(a165_0x5d72,0xd45d2));import{readFileSync}from'fs';function a165_0x5566(_0x2ebc7e,_0x2e305e){_0x2ebc7e=_0x2ebc7e-0x160;const _0x5d7225=a165_0x5d72();let _0x55667c=_0x5d7225[_0x2ebc7e];return _0x55667c;}import*as a165_0x528430 from'path';import*as a165_0x3d015e 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_0x160561(0x177),a165_0x160561(0x178)]);export function isJourneyDef(_0x476622){const _0x3d1366=a165_0x160561;return typeof _0x476622==='object'&&_0x476622!==null&&_0x3d1366(0x16b)in _0x476622&&_0x476622['type']==='journey';}export function isCampaignDef(_0x100186){const _0xe6e408=a165_0x160561;if(typeof _0x100186!==_0xe6e408(0x171)||_0x100186===null)return![];const _0x56d2db=_0x100186,_0xa51c19=VALID_CAMPAIGN_TYPES[_0xe6e408(0x181)](_0x56d2db['campaign_type']);if(_0x56d2db[_0xe6e408(0x16b)]===_0xe6e408(0x163)&&_0xa51c19)return!![];if(_0xa51c19&&!_0x56d2db[_0xe6e408(0x16b)])return!![];return![];}export function isTemplateDef(_0x559dda){const _0x15a429=a165_0x160561;return typeof _0x559dda==='object'&&_0x559dda!==null&&'type'in _0x559dda&&_0x559dda[_0x15a429(0x16b)]==='template';}function a165_0x5d72(){const _0x1c7186=['not\x20a\x20','has','basename','6hEObIR','toJSON','campaign','65061kxbAkr','26009687cWZAeR','template','segment','relative','85672bosZyv','YAML\x20parse\x20error:\x20','type','YAML_PARSE_ERROR','5736772fbCaiJ','Failed\x20to\x20parse\x20YAML\x20file\x20(empty\x20or\x20invalid)','1113kMSauA','1137249ZzrOUe','object','valid','796431hXdtnm','length','1450ISwRPA','utf-8','email','push','skipped','parseDocument','filterType','8643315KWlnBQ','warnings','2cwJKIM','24QhxNAk'];a165_0x5d72=function(){return _0x1c7186;};return a165_0x5d72();}export function isValidationResult(_0x5f57b7){const _0x2b2fdc=a165_0x160561;return!(_0x2b2fdc(0x179)in _0x5f57b7);}export function createParseErrorResult(_0x4cd5de,_0x543a46,_0x564f41,_0x2b100f,_0x1994bc='segment'){const _0x332004=a165_0x160561;return{'filePath':_0x4cd5de,'relativePath':_0x543a46,'source':_0x564f41,'result':{'valid':![],'errors':[{'level':'error','path':'','code':_0x332004(0x16c),'message':_0x2b100f}],'warnings':[]},'fileType':_0x1994bc};}export function validateYamlFile(_0x4c19d2,_0x1c1235,_0x279950={}){const _0x3792a0=a165_0x160561,_0x26a1e0=a165_0x528430[_0x3792a0(0x168)](_0x1c1235,_0x4c19d2)||a165_0x528430[_0x3792a0(0x160)](_0x4c19d2);try{const _0x459ece=readFileSync(_0x4c19d2,_0x3792a0(0x176)),_0x4aa0b5=a165_0x3d015e[_0x3792a0(0x17a)](_0x459ece),_0x548a03=_0x4aa0b5[_0x3792a0(0x162)]();if(!_0x548a03)return createParseErrorResult(_0x4c19d2,_0x26a1e0,_0x459ece,_0x3792a0(0x16e));let _0x272154;if(isJourneyDef(_0x548a03))_0x272154='journey';else{if(isCampaignDef(_0x548a03))_0x272154=_0x3792a0(0x163);else isTemplateDef(_0x548a03)?_0x272154='template':_0x272154=_0x3792a0(0x167);}if(_0x279950[_0x3792a0(0x17b)]&&_0x272154!==_0x279950['filterType'])return{'filePath':_0x4c19d2,'relativePath':_0x26a1e0,'skipped':!![],'reason':_0x3792a0(0x180)+_0x279950['filterType']};const _0x33180a={'source':_0x459ece,'document':_0x4aa0b5};let _0x1db4c0;if(_0x272154==='journey')_0x1db4c0=validateJourneyDef(_0x548a03,_0x33180a);else{if(_0x272154===_0x3792a0(0x163))_0x1db4c0=validateCampaignDef(_0x548a03,_0x33180a);else _0x272154===_0x3792a0(0x166)?_0x1db4c0=validateTemplateDef(_0x548a03,_0x33180a):_0x1db4c0=validateSegmentDef(_0x548a03,_0x33180a);}return{'filePath':_0x4c19d2,'relativePath':_0x26a1e0,'source':_0x459ece,'result':_0x1db4c0,'fileType':_0x272154};}catch(_0x169766){const _0x427162=_0x169766 instanceof Error?_0x169766['message']:String(_0x169766);return createParseErrorResult(_0x4c19d2,_0x26a1e0,'',_0x3792a0(0x16a)+_0x427162);}}export function validateYamlFiles(_0x1b21b5,_0x557d5e,_0x2c0268={}){return _0x1b21b5['map'](_0x254832=>validateYamlFile(_0x254832,_0x557d5e,_0x2c0268));}export function calculateSummary(_0x3114df){const _0x89dcc9=a165_0x160561;let _0x2590d3=0x0,_0x318504=0x0,_0x14330d=0x0,_0x6fed7=0x0;for(const _0x3597bb of _0x3114df){if(!isValidationResult(_0x3597bb)){_0x6fed7++;continue;}_0x3597bb['result'][_0x89dcc9(0x172)]?_0x2590d3++:_0x318504++,_0x14330d+=_0x3597bb['result'][_0x89dcc9(0x17d)][_0x89dcc9(0x174)];}return{'validCount':_0x2590d3,'invalidCount':_0x318504,'warningCount':_0x14330d,'skippedCount':_0x6fed7,'hasErrors':_0x318504>0x0};}
@@ -1 +1 @@
1
- (function(_0x35e63a,_0xd54042){const _0x128646=a166_0x2ade,_0x30f3c6=_0x35e63a();while(!![]){try{const _0x1bb689=parseInt(_0x128646(0xa6))/0x1+-parseInt(_0x128646(0xa2))/0x2*(-parseInt(_0x128646(0x98))/0x3)+-parseInt(_0x128646(0x96))/0x4*(-parseInt(_0x128646(0xb7))/0x5)+parseInt(_0x128646(0xa7))/0x6*(-parseInt(_0x128646(0xbe))/0x7)+parseInt(_0x128646(0xb9))/0x8+parseInt(_0x128646(0x9f))/0x9+-parseInt(_0x128646(0xb4))/0xa;if(_0x1bb689===_0xd54042)break;else _0x30f3c6['push'](_0x30f3c6['shift']());}catch(_0x414029){_0x30f3c6['push'](_0x30f3c6['shift']());}}}(a166_0xc62d,0x885ab));function a166_0xc62d(){const _0x102449=['match','line','invalid_union','map','49CBvMFq','yellow','range','warnings','YAML\x20validation\x20error\x20at\x20\x27','parse','path','YAML\x20validation\x20error:\x20','length','3528676PVNDQH','padStart','427611PaTNcg','Invalid\x20YAML:\x20expected\x20an\x20object','join','max','object','success','\x27:\x20','4994541gpyazq','level','data','12plawrZ','safeParse','getIn','min','323256ZGCNAF','226902Pypyao','dim','column','cyan','split','code','repeat','number','location','push','errors','error','red','23418080qJbSgZ','toString','message','5Emxapz','\x20|\x20','4395504XoLjrk'];a166_0xc62d=function(){return _0x102449;};return a166_0xc62d();}import*as a166_0xa79b29 from'yaml';import a166_0x35e43e from'chalk';export{validateSegmentDef,validateRuleDef}from'./segment-validator.js';export function getLocationFromPath(_0x4903b3,_0x592ac5,_0x244d45){const _0x126237=a166_0x2ade;if(!_0x4903b3||!_0x592ac5)return undefined;try{let _0x28dd60=_0x4903b3[_0x126237(0xa4)](_0x244d45,!![]),_0x44f040=[..._0x244d45];while((!_0x28dd60||typeof _0x28dd60!==_0x126237(0x9c)||!(_0x126237(0xc0)in _0x28dd60)||!_0x28dd60[_0x126237(0xc0)])&&_0x44f040[_0x126237(0x95)]>0x0){_0x44f040['pop'](),_0x28dd60=_0x44f040['length']>0x0?_0x4903b3['getIn'](_0x44f040,!![]):_0x4903b3['contents'];}if(!_0x28dd60||typeof _0x28dd60!==_0x126237(0x9c)||!(_0x126237(0xc0)in _0x28dd60)||!_0x28dd60['range'])return undefined;const [_0x5d0130]=_0x28dd60['range'];return offsetToLocation(_0x592ac5,_0x5d0130);}catch{return undefined;}}function a166_0x2ade(_0x121b36,_0x99ae31){_0x121b36=_0x121b36-0x90;const _0xc62d86=a166_0xc62d();let _0x2ade98=_0xc62d86[_0x121b36];return _0x2ade98;}export function offsetToLocation(_0xb6cc31,_0x2965ae){let _0x288fb1=0x1,_0x48ac8a=0x1;for(let _0x1d78d8=0x0;_0x1d78d8<_0x2965ae&&_0x1d78d8<_0xb6cc31['length'];_0x1d78d8++){_0xb6cc31[_0x1d78d8]==='\x0a'?(_0x288fb1++,_0x48ac8a=0x1):_0x48ac8a++;}return{'line':_0x288fb1,'column':_0x48ac8a,'offset':_0x2965ae};}export function pathToArray(_0xca6f4e){const _0x2e678f=a166_0x2ade;if(!_0xca6f4e)return[];return _0xca6f4e[_0x2e678f(0xab)]('.')['flatMap'](_0x589e9b=>{const _0x48b7e4=_0x2e678f,_0x514984=_0x589e9b[_0x48b7e4(0xba)](/^(\w+)\[(\d+)\]$/);if(_0x514984)return[_0x514984[0x1],parseInt(_0x514984[0x2],0xa)];return[_0x589e9b];});}export function formatZodPath(_0x24099f){const _0x34a982=a166_0x2ade;let _0x34160e='';for(const _0x1f3e62 of _0x24099f){if(typeof _0x1f3e62===_0x34a982(0xae))_0x34160e+='['+_0x1f3e62+']';else{const _0x469129=String(_0x1f3e62);_0x34160e+=_0x34160e?'.'+_0x469129:_0x469129;}}return _0x34160e;}export function flattenZodIssues(_0x3b3a98){const _0x2eb575=a166_0x2ade,_0x209e0e=[];for(const _0x161b9c of _0x3b3a98){if(_0x161b9c[_0x2eb575(0xac)]===_0x2eb575(0xbc)&&_0x2eb575(0xb1)in _0x161b9c){const _0x355e75=_0x161b9c[_0x2eb575(0xb1)];let _0x3d852a=_0x355e75[0x0]||[];for(const _0x3c9fbf of _0x355e75){_0x3c9fbf['length']<_0x3d852a[_0x2eb575(0x95)]&&(_0x3d852a=_0x3c9fbf);}const _0x430d2d=_0x3d852a[_0x2eb575(0xbd)](_0x1814e2=>({..._0x1814e2,'path':[..._0x161b9c[_0x2eb575(0x93)],..._0x1814e2[_0x2eb575(0x93)]]}));_0x209e0e[_0x2eb575(0xb0)](...flattenZodIssues(_0x430d2d));}else _0x209e0e[_0x2eb575(0xb0)](_0x161b9c);}return _0x209e0e;}export function safeParseYaml(_0x88c1db,_0x215c64){const _0x97e9e8=a166_0x2ade,_0x22bcb5=a166_0xa79b29[_0x97e9e8(0x92)](_0x88c1db);if(!_0x22bcb5||typeof _0x22bcb5!==_0x97e9e8(0x9c))throw new Error(_0x97e9e8(0x99));const _0x4bb27b=_0x215c64[_0x97e9e8(0xa3)](_0x22bcb5);if(!_0x4bb27b[_0x97e9e8(0x9d)]){const _0x447c6e=_0x4bb27b[_0x97e9e8(0xb2)]['issues'][0x0],_0x4b6590=formatZodPath(_0x447c6e[_0x97e9e8(0x93)]);throw new Error(_0x4b6590?_0x97e9e8(0x91)+_0x4b6590+_0x97e9e8(0x9e)+_0x447c6e[_0x97e9e8(0xb6)]:_0x97e9e8(0x94)+_0x447c6e[_0x97e9e8(0xb6)]);}return _0x4bb27b[_0x97e9e8(0xa1)];}export function formatIssueWithContext(_0x599564,_0x48e5af,_0x4429c6){const _0x41711e=a166_0x2ade,_0x4de168=[],_0x11565d=_0x599564[_0x41711e(0xa0)]==='error',_0x411509=_0x11565d?a166_0x35e43e[_0x41711e(0xb3)]:a166_0x35e43e[_0x41711e(0xbf)],_0x37d90c=_0x11565d?a166_0x35e43e[_0x41711e(0xb3)]:a166_0x35e43e['yellow'],_0x38f65c=_0x4429c6?a166_0x35e43e[_0x41711e(0xaa)](_0x4429c6+':'):'';if(_0x599564[_0x41711e(0xaf)]){const _0x3aed8f=a166_0x35e43e[_0x41711e(0xaa)](_0x599564['location'][_0x41711e(0xbb)]+':'+_0x599564[_0x41711e(0xaf)][_0x41711e(0xa9)]);_0x4de168[_0x41711e(0xb0)](''+_0x38f65c+_0x3aed8f+':\x20'+_0x411509(_0x599564[_0x41711e(0xa0)])+'\x20'+_0x37d90c('['+_0x599564[_0x41711e(0xac)]+']'));}else _0x4de168[_0x41711e(0xb0)](''+_0x38f65c+a166_0x35e43e[_0x41711e(0xa8)](_0x599564[_0x41711e(0x93)])+':\x20'+_0x411509(_0x599564['level'])+'\x20'+_0x37d90c('['+_0x599564[_0x41711e(0xac)]+']'));_0x4de168[_0x41711e(0xb0)](_0x599564[_0x41711e(0xb6)]);if(_0x599564[_0x41711e(0xaf)]&&_0x48e5af){const _0x3aaba1=_0x48e5af[_0x41711e(0xab)]('\x0a'),{line:_0x30695d,column:_0x59f094}=_0x599564[_0x41711e(0xaf)],_0x316ed9=Math[_0x41711e(0x9b)](0x1,_0x30695d-0x1),_0xffac40=Math[_0x41711e(0xa5)](_0x3aaba1['length'],_0x30695d+0x1);_0x4de168[_0x41711e(0xb0)]('');for(let _0x4a190b=_0x316ed9;_0x4a190b<=_0xffac40;_0x4a190b++){const _0x5d85e1=_0x3aaba1[_0x4a190b-0x1]||'',_0xbcbcfd=a166_0x35e43e[_0x41711e(0xa8)](_0x4a190b[_0x41711e(0xb5)]()[_0x41711e(0x97)](0x4)),_0x1fbc16=a166_0x35e43e[_0x41711e(0xa8)](_0x41711e(0xb8));if(_0x4a190b===_0x30695d){_0x4de168[_0x41711e(0xb0)]('\x20\x20'+_0xbcbcfd+_0x1fbc16+_0x411509(_0x5d85e1));const _0x235e0a='\x20'[_0x41711e(0xad)](0x4+0x3+_0x59f094-0x1);_0x4de168['push']('\x20\x20'+_0x235e0a+_0x411509('^'));}else _0x4de168[_0x41711e(0xb0)]('\x20\x20'+_0xbcbcfd+_0x1fbc16+a166_0x35e43e['dim'](_0x5d85e1));}}return _0x4de168[_0x41711e(0x9a)]('\x0a');}export function formatValidationResult(_0x55a9e3,_0x5968d9,_0x30d4bb){const _0x4fedb1=a166_0x2ade,_0x5d6f88=[];for(const _0x4f53eb of _0x55a9e3[_0x4fedb1(0xb1)]){_0x5d6f88[_0x4fedb1(0xb0)](formatIssueWithContext(_0x4f53eb,_0x5968d9,_0x30d4bb)),_0x5d6f88['push']('');}for(const _0x49f8e6 of _0x55a9e3[_0x4fedb1(0x90)]){_0x5d6f88[_0x4fedb1(0xb0)](formatIssueWithContext(_0x49f8e6,_0x5968d9,_0x30d4bb)),_0x5d6f88[_0x4fedb1(0xb0)]('');}return _0x5d6f88['join']('\x0a');}
1
+ function a166_0x5a46(_0x55b7a1,_0x429fba){_0x55b7a1=_0x55b7a1-0x1a0;const _0x19ce37=a166_0x19ce();let _0x5a46c4=_0x19ce37[_0x55b7a1];return _0x5a46c4;}(function(_0x317975,_0x5745a0){const _0x384b5d=a166_0x5a46,_0x2ac29a=_0x317975();while(!![]){try{const _0x4a6d=-parseInt(_0x384b5d(0x1c7))/0x1*(-parseInt(_0x384b5d(0x1be))/0x2)+-parseInt(_0x384b5d(0x1b4))/0x3+parseInt(_0x384b5d(0x1bf))/0x4*(-parseInt(_0x384b5d(0x1ae))/0x5)+-parseInt(_0x384b5d(0x1a9))/0x6*(parseInt(_0x384b5d(0x1ca))/0x7)+-parseInt(_0x384b5d(0x1af))/0x8*(parseInt(_0x384b5d(0x1c2))/0x9)+-parseInt(_0x384b5d(0x1c1))/0xa+parseInt(_0x384b5d(0x1ba))/0xb;if(_0x4a6d===_0x5745a0)break;else _0x2ac29a['push'](_0x2ac29a['shift']());}catch(_0x5aeaa1){_0x2ac29a['push'](_0x2ac29a['shift']());}}}(a166_0x19ce,0xec2ac));import*as a166_0x298114 from'yaml';import a166_0x451975 from'chalk';export{validateSegmentDef,validateRuleDef}from'./segment-validator.js';export function getLocationFromPath(_0x5617a0,_0x574044,_0x155695){const _0xa0bf5f=a166_0x5a46;if(!_0x5617a0||!_0x574044)return undefined;try{let _0xacd0d=_0x5617a0[_0xa0bf5f(0x1a4)](_0x155695,!![]),_0x17545c=[..._0x155695];while((!_0xacd0d||typeof _0xacd0d!==_0xa0bf5f(0x1b7)||!('range'in _0xacd0d)||!_0xacd0d[_0xa0bf5f(0x1b2)])&&_0x17545c[_0xa0bf5f(0x1a8)]>0x0){_0x17545c[_0xa0bf5f(0x1ac)](),_0xacd0d=_0x17545c[_0xa0bf5f(0x1a8)]>0x0?_0x5617a0['getIn'](_0x17545c,!![]):_0x5617a0['contents'];}if(!_0xacd0d||typeof _0xacd0d!==_0xa0bf5f(0x1b7)||!(_0xa0bf5f(0x1b2)in _0xacd0d)||!_0xacd0d['range'])return undefined;const [_0x12b707]=_0xacd0d[_0xa0bf5f(0x1b2)];return offsetToLocation(_0x574044,_0x12b707);}catch{return undefined;}}export function offsetToLocation(_0x3fe1cc,_0x21b2d9){const _0x3de078=a166_0x5a46;let _0x2e1f82=0x1,_0x5d7a81=0x1;for(let _0x3126c9=0x0;_0x3126c9<_0x21b2d9&&_0x3126c9<_0x3fe1cc[_0x3de078(0x1a8)];_0x3126c9++){_0x3fe1cc[_0x3126c9]==='\x0a'?(_0x2e1f82++,_0x5d7a81=0x1):_0x5d7a81++;}return{'line':_0x2e1f82,'column':_0x5d7a81,'offset':_0x21b2d9};}export function pathToArray(_0x213d21){const _0x181880=a166_0x5a46;if(!_0x213d21)return[];return _0x213d21[_0x181880(0x1b1)]('.')[_0x181880(0x1b0)](_0x22b7c6=>{const _0x1c82ea=_0x181880,_0x545e75=_0x22b7c6[_0x1c82ea(0x1ad)](/^(\w+)\[(\d+)\]$/);if(_0x545e75)return[_0x545e75[0x1],parseInt(_0x545e75[0x2],0xa)];return[_0x22b7c6];});}export function formatZodPath(_0xa5f341){const _0x1f90b3=a166_0x5a46;let _0x274f77='';for(const _0x3631c6 of _0xa5f341){if(typeof _0x3631c6===_0x1f90b3(0x1a1))_0x274f77+='['+_0x3631c6+']';else{const _0x5066cc=String(_0x3631c6);_0x274f77+=_0x274f77?'.'+_0x5066cc:_0x5066cc;}}return _0x274f77;}export function flattenZodIssues(_0x2566dc){const _0x29353e=a166_0x5a46,_0x39cc7b=[];for(const _0x35d7fa of _0x2566dc){if(_0x35d7fa[_0x29353e(0x1aa)]===_0x29353e(0x1bc)&&'errors'in _0x35d7fa){const _0x291c04=_0x35d7fa[_0x29353e(0x1c4)];let _0x595303=_0x291c04[0x0]||[];for(const _0x389e20 of _0x291c04){_0x389e20['length']<_0x595303['length']&&(_0x595303=_0x389e20);}const _0x357c13=_0x595303[_0x29353e(0x1b8)](_0x5782d7=>({..._0x5782d7,'path':[..._0x35d7fa[_0x29353e(0x1c9)],..._0x5782d7[_0x29353e(0x1c9)]]}));_0x39cc7b[_0x29353e(0x1ce)](...flattenZodIssues(_0x357c13));}else _0x39cc7b['push'](_0x35d7fa);}return _0x39cc7b;}export function safeParseYaml(_0x5bad80,_0x82f3fc){const _0x173309=a166_0x5a46,_0x453e49=a166_0x298114[_0x173309(0x1cb)](_0x5bad80);if(!_0x453e49||typeof _0x453e49!==_0x173309(0x1b7))throw new Error('Invalid\x20YAML:\x20expected\x20an\x20object');const _0x3e786b=_0x82f3fc[_0x173309(0x1c3)](_0x453e49);if(!_0x3e786b['success']){const _0x766405=_0x3e786b['error'][_0x173309(0x1c5)][0x0],_0x351b5e=formatZodPath(_0x766405[_0x173309(0x1c9)]);throw new Error(_0x351b5e?_0x173309(0x1ab)+_0x351b5e+_0x173309(0x1a5)+_0x766405[_0x173309(0x1b5)]:_0x173309(0x1b6)+_0x766405[_0x173309(0x1b5)]);}return _0x3e786b[_0x173309(0x1a7)];}function a166_0x19ce(){const _0x37ab7b=['padStart','14208ZQxwoi','5647376qILtwi','yellow','10749280KFDfnO','5309262ztyveh','safeParse','errors','issues','max','203AlGHoN','location','path','119tILZlr','parse','red','level','push','warnings','number','\x20|\x20','cyan','getIn','\x27:\x20','join','data','length','544098QtCKVc','code','YAML\x20validation\x20error\x20at\x20\x27','pop','match','5OZdGNM','16KfyGrG','flatMap','split','range','dim','1842354ABleUN','message','YAML\x20validation\x20error:\x20','object','map','error','58823215AVZSnT','line','invalid_union'];a166_0x19ce=function(){return _0x37ab7b;};return a166_0x19ce();}export function formatIssueWithContext(_0x2c12e9,_0x19d9ee,_0x23f2b5){const _0xa30771=a166_0x5a46,_0x36dbfc=[],_0x4d7704=_0x2c12e9['level']===_0xa30771(0x1b9),_0x5a2826=_0x4d7704?a166_0x451975[_0xa30771(0x1cc)]:a166_0x451975[_0xa30771(0x1c0)],_0x3302ec=_0x4d7704?a166_0x451975[_0xa30771(0x1cc)]:a166_0x451975[_0xa30771(0x1c0)],_0x1e1735=_0x23f2b5?a166_0x451975[_0xa30771(0x1a3)](_0x23f2b5+':'):'';if(_0x2c12e9[_0xa30771(0x1c8)]){const _0x5941d7=a166_0x451975['cyan'](_0x2c12e9[_0xa30771(0x1c8)][_0xa30771(0x1bb)]+':'+_0x2c12e9['location']['column']);_0x36dbfc[_0xa30771(0x1ce)](''+_0x1e1735+_0x5941d7+':\x20'+_0x5a2826(_0x2c12e9['level'])+'\x20'+_0x3302ec('['+_0x2c12e9[_0xa30771(0x1aa)]+']'));}else _0x36dbfc[_0xa30771(0x1ce)](''+_0x1e1735+a166_0x451975[_0xa30771(0x1b3)](_0x2c12e9['path'])+':\x20'+_0x5a2826(_0x2c12e9[_0xa30771(0x1cd)])+'\x20'+_0x3302ec('['+_0x2c12e9['code']+']'));_0x36dbfc[_0xa30771(0x1ce)](_0x2c12e9[_0xa30771(0x1b5)]);if(_0x2c12e9[_0xa30771(0x1c8)]&&_0x19d9ee){const _0x2925b1=_0x19d9ee[_0xa30771(0x1b1)]('\x0a'),{line:_0x2ef23b,column:_0x50190b}=_0x2c12e9['location'],_0x2fcd96=Math[_0xa30771(0x1c6)](0x1,_0x2ef23b-0x1),_0x49e8dc=Math['min'](_0x2925b1[_0xa30771(0x1a8)],_0x2ef23b+0x1);_0x36dbfc[_0xa30771(0x1ce)]('');for(let _0x5c933d=_0x2fcd96;_0x5c933d<=_0x49e8dc;_0x5c933d++){const _0x301de0=_0x2925b1[_0x5c933d-0x1]||'',_0x4f4c77=a166_0x451975[_0xa30771(0x1b3)](_0x5c933d['toString']()[_0xa30771(0x1bd)](0x4)),_0x20e7b1=a166_0x451975[_0xa30771(0x1b3)](_0xa30771(0x1a2));if(_0x5c933d===_0x2ef23b){_0x36dbfc[_0xa30771(0x1ce)]('\x20\x20'+_0x4f4c77+_0x20e7b1+_0x5a2826(_0x301de0));const _0x3befcc='\x20'['repeat'](0x4+0x3+_0x50190b-0x1);_0x36dbfc['push']('\x20\x20'+_0x3befcc+_0x5a2826('^'));}else _0x36dbfc[_0xa30771(0x1ce)]('\x20\x20'+_0x4f4c77+_0x20e7b1+a166_0x451975['dim'](_0x301de0));}}return _0x36dbfc['join']('\x0a');}export function formatValidationResult(_0x594483,_0x5c6c56,_0x14ea7b){const _0x4e51c5=a166_0x5a46,_0x1e0ff5=[];for(const _0x5af73a of _0x594483[_0x4e51c5(0x1c4)]){_0x1e0ff5[_0x4e51c5(0x1ce)](formatIssueWithContext(_0x5af73a,_0x5c6c56,_0x14ea7b)),_0x1e0ff5[_0x4e51c5(0x1ce)]('');}for(const _0x46fdff of _0x594483[_0x4e51c5(0x1a0)]){_0x1e0ff5[_0x4e51c5(0x1ce)](formatIssueWithContext(_0x46fdff,_0x5c6c56,_0x14ea7b)),_0x1e0ff5[_0x4e51c5(0x1ce)]('');}return _0x1e0ff5[_0x4e51c5(0x1a6)]('\x0a');}