@treasuredata/tdx 2026.3.14 → 2026.3.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bin.js +1 -1
- package/dist/build-info.json +3 -3
- package/dist/cli-categories.js +1 -1
- package/dist/cli.js +1 -1
- package/dist/commands/activations.js +1 -1
- package/dist/commands/agent-command.js +1 -1
- package/dist/commands/agent-test-command.js +1 -1
- package/dist/commands/api-command.js +1 -1
- package/dist/commands/auth-command.js +1 -1
- package/dist/commands/auth-login-command.js +1 -1
- package/dist/commands/chat-command.js +1 -1
- package/dist/commands/claude-command.js +1 -1
- package/dist/commands/claude-statusline-command.js +1 -1
- package/dist/commands/claude-usage-command.js +1 -1
- package/dist/commands/command.js +1 -1
- package/dist/commands/connection-command.js +1 -1
- package/dist/commands/databases.js +1 -1
- package/dist/commands/delivery-command.js +1 -1
- package/dist/commands/describe.js +1 -1
- package/dist/commands/engage-campaign-pull-command.js +1 -1
- package/dist/commands/engage-campaign-push-command.js +1 -1
- package/dist/commands/engage-campaign-validate-command.js +1 -1
- package/dist/commands/engage-command.js +1 -1
- package/dist/commands/engage-template-pull-command.js +1 -1
- package/dist/commands/engage-template-push-command.js +1 -1
- package/dist/commands/engage-template-validate-command.js +1 -1
- package/dist/commands/job-command.js +1 -1
- package/dist/commands/journey-command.js +1 -1
- package/dist/commands/journey-validate-command.js +1 -1
- package/dist/commands/llm-command.js +1 -1
- package/dist/commands/mcp-command.js +1 -1
- package/dist/commands/parent-segment-command.js +1 -1
- package/dist/commands/profile-command.js +1 -1
- package/dist/commands/profiles-command.js +1 -1
- package/dist/commands/query-command.js +1 -1
- package/dist/commands/schedule-command.js +1 -1
- package/dist/commands/segment-command.js +1 -1
- package/dist/commands/segment-create-command.js +1 -1
- package/dist/commands/segment-fields-command.js +1 -1
- package/dist/commands/segment-pull-command.js +1 -1
- package/dist/commands/segment-push-command.js +1 -1
- package/dist/commands/segment-update-command.js +1 -1
- package/dist/commands/segment-use-command.js +1 -1
- package/dist/commands/segment-validate-command.js +1 -1
- package/dist/commands/segments.js +1 -1
- package/dist/commands/show.js +1 -1
- package/dist/commands/status-command.js +1 -1
- package/dist/commands/tables.js +1 -1
- package/dist/commands/unset-command.js +1 -1
- package/dist/commands/upgrade-command.js +1 -1
- package/dist/commands/use-command.js +1 -1
- package/dist/commands/user-command.js +1 -1
- package/dist/commands/workflow-command.js +1 -1
- package/dist/core/auth.js +1 -1
- package/dist/core/command-output.js +1 -1
- package/dist/core/config.js +1 -1
- package/dist/core/connection-cache.js +1 -1
- package/dist/core/constants.js +1 -1
- package/dist/core/credential-cache.js +1 -1
- package/dist/core/global-context.js +1 -1
- package/dist/core/keychain.js +1 -1
- package/dist/core/oauth-keychain.js +1 -1
- package/dist/core/oauth.js +1 -1
- package/dist/core/profile.js +1 -1
- package/dist/core/project-config.js +1 -1
- package/dist/core/session.js +1 -1
- package/dist/core/user-cache.js +1 -1
- package/dist/core/version.js +1 -1
- package/dist/index.js +1 -1
- package/dist/mcp/server.js +1 -1
- package/dist/mcp/tools/index.js +1 -1
- package/dist/mcp/tools/tdx-run.js +1 -1
- package/dist/mcp/tools/tdx-search.js +1 -1
- package/dist/mcp/utils.js +1 -1
- package/dist/proxy/claude-usage-tracker.js +1 -1
- package/dist/proxy/passthrough-server.js +1 -1
- package/dist/proxy/sse-usage-parser.js +1 -1
- package/dist/sdk/agent/agent-config.js +1 -1
- package/dist/sdk/agent/agent-ref-parser.js +1 -1
- package/dist/sdk/agent/agent-yaml.js +1 -1
- package/dist/sdk/agent/test/evaluator.js +1 -1
- package/dist/sdk/agent/test/executor.js +1 -1
- package/dist/sdk/agent/test/index.js +1 -1
- package/dist/sdk/agent/test/output.js +1 -1
- package/dist/sdk/agent/test/parser.js +1 -1
- package/dist/sdk/agent/tool-target-registry.js +1 -1
- package/dist/sdk/api.js +1 -1
- package/dist/sdk/client/cdp-api-client.js +1 -1
- package/dist/sdk/client/delivery-api-client.js +1 -1
- package/dist/sdk/client/endpoints.js +1 -1
- package/dist/sdk/client/engage-api-client.js +1 -1
- package/dist/sdk/client/http-client.js +1 -1
- package/dist/sdk/client/llm-api-client.js +1 -1
- package/dist/sdk/client/oauth-refresh.js +1 -1
- package/dist/sdk/client/rate-limiter.js +1 -1
- package/dist/sdk/client/td-api-client.js +1 -1
- package/dist/sdk/client/trino-api-client.js +1 -1
- package/dist/sdk/client/workflow-client.js +1 -1
- package/dist/sdk/connection-validator.js +1 -1
- package/dist/sdk/connection.js +1 -1
- package/dist/sdk/delivery.js +1 -1
- package/dist/sdk/engage/campaign-pull.js +1 -1
- package/dist/sdk/engage/campaign-push.js +1 -1
- package/dist/sdk/engage/campaign-validator.js +1 -1
- package/dist/sdk/engage/campaign-yaml.js +1 -1
- package/dist/sdk/engage/template-pull.js +1 -1
- package/dist/sdk/engage/template-push.js +1 -1
- package/dist/sdk/engage/template-validator.js +1 -1
- package/dist/sdk/engage/template-yaml.js +1 -1
- package/dist/sdk/engage/types/campaign-def.js +1 -1
- package/dist/sdk/engage/types/campaign-schema.js +1 -1
- package/dist/sdk/engage/types/template-schema.js +1 -1
- package/dist/sdk/engage.js +1 -1
- package/dist/sdk/errors.js +1 -1
- package/dist/sdk/index.js +1 -1
- package/dist/sdk/io/index.js +1 -1
- package/dist/sdk/io/node-filesystem.js +1 -1
- package/dist/sdk/job.js +1 -1
- package/dist/sdk/journey.js +1 -1
- package/dist/sdk/llm/chat-cache.js +1 -1
- package/dist/sdk/llm/index.js +1 -1
- package/dist/sdk/llm/llm-backup-utils.js +1 -1
- package/dist/sdk/llm/model-factors.js +1 -1
- package/dist/sdk/personalization.js +1 -1
- package/dist/sdk/query/index.js +1 -1
- package/dist/sdk/query/sql-parser.js +1 -1
- package/dist/sdk/realtime.js +1 -1
- package/dist/sdk/schedule.js +1 -1
- package/dist/sdk/segment/child-segment-yaml.js +1 -1
- package/dist/sdk/segment/fields-display.js +1 -1
- package/dist/sdk/segment/file-discovery.js +1 -1
- package/dist/sdk/segment/journey-utils.js +1 -1
- package/dist/sdk/segment/journey-validator.js +1 -1
- package/dist/sdk/segment/journey-yaml.js +1 -1
- package/dist/sdk/segment/parent-segment-preview.js +1 -1
- package/dist/sdk/segment/parent-segment-yaml.js +1 -1
- package/dist/sdk/segment/pull-workflow.js +1 -1
- package/dist/sdk/segment/push-recovery.js +1 -1
- package/dist/sdk/segment/push-workflow.js +1 -1
- package/dist/sdk/segment/resolution-context.js +1 -1
- package/dist/sdk/segment/segment-path-parser.js +1 -1
- package/dist/sdk/segment/segment-ref-parser.js +1 -1
- package/dist/sdk/segment/segment-validator.js +1 -1
- package/dist/sdk/segment/target-resolution.js +1 -1
- package/dist/sdk/segment/tdx-config.js +1 -1
- package/dist/sdk/segment/types/activation-schema.js +1 -1
- package/dist/sdk/segment/types/journey-def.js +1 -1
- package/dist/sdk/segment/types/journey-schema.js +1 -1
- package/dist/sdk/segment/types/segment-def.js +1 -1
- package/dist/sdk/segment/types/segment-schema.js +1 -1
- package/dist/sdk/segment/validate-files.js +1 -1
- package/dist/sdk/segment/yaml-validator.js +1 -1
- package/dist/sdk/segment.js +1 -1
- package/dist/sdk/types/index.js +1 -1
- package/dist/sdk/types/progress.js +1 -1
- package/dist/sdk/user.js +1 -1
- package/dist/sdk/util/format-detector.js +1 -1
- package/dist/sdk/util/formatters.js +1 -1
- package/dist/sdk/util/index.js +1 -1
- package/dist/sdk/util/paginate.js +1 -1
- package/dist/sdk/util/tree-formatter.js +1 -1
- package/dist/sdk/workflow/archive-validation.js +1 -1
- package/dist/sdk/workflow/clone-workflow.js +1 -1
- package/dist/sdk/workflow/index.js +1 -1
- package/dist/sdk/workflow/pull-workflow.js +1 -1
- package/dist/sdk/workflow/push-workflow.js +1 -1
- package/dist/sdk/workflow/tdx-config.js +1 -1
- package/dist/sdk/workflow/workflow-utils.js +1 -1
- package/dist/test-utils/command-runner.js +1 -1
- package/dist/test-utils/factories.js +1 -1
- package/dist/test-utils/fixtures.js +1 -1
- package/dist/test-utils/http-mock.js +1 -1
- package/dist/test-utils/index.js +1 -1
- package/dist/utils/async.js +1 -1
- package/dist/utils/colors.js +1 -1
- package/dist/utils/diff.js +1 -1
- package/dist/utils/file-permissions.js +1 -1
- package/dist/utils/file-reader.js +1 -1
- package/dist/utils/github-releases.js +1 -1
- package/dist/utils/global-cache.js +1 -1
- package/dist/utils/json-loader.js +1 -1
- package/dist/utils/local-cache.js +1 -1
- package/dist/utils/logger/formatters/default-formatter.js +1 -1
- package/dist/utils/logger/formatters/index.js +1 -1
- package/dist/utils/logger/handlers/console-handler.js +1 -1
- package/dist/utils/logger/handlers/file-handler.js +1 -1
- package/dist/utils/logger/handlers/index.js +1 -1
- package/dist/utils/logger/handlers/null-handler.js +1 -1
- package/dist/utils/logger/index.js +1 -1
- package/dist/utils/logger/logger.js +1 -1
- package/dist/utils/logger/types.js +1 -1
- package/dist/utils/option-validation.js +1 -1
- package/dist/utils/process.js +1 -1
- package/dist/utils/prompt.js +1 -1
- package/dist/utils/spinner.js +1 -1
- package/dist/utils/sse-parser.js +1 -1
- package/dist/utils/string-utils.js +1 -1
- package/dist/utils/table-ref-parser.js +1 -1
- package/dist/utils/tdx-logger.js +1 -1
- package/dist/utils/version-check.js +1 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x224936,_0x463071){const _0x307796=a144_0x1dec,_0x226d92=_0x224936();while(!![]){try{const _0x155d79=-parseInt(_0x307796(0x1b9))/0x1*(-parseInt(_0x307796(0x188))/0x2)+-parseInt(_0x307796(0x1bd))/0x3*(parseInt(_0x307796(0x1a8))/0x4)+parseInt(_0x307796(0x187))/0x5+parseInt(_0x307796(0x1a5))/0x6+parseInt(_0x307796(0x1a9))/0x7+parseInt(_0x307796(0x197))/0x8+-parseInt(_0x307796(0x19f))/0x9;if(_0x155d79===_0x463071)break;else _0x226d92['push'](_0x226d92['shift']());}catch(_0x1ee2bc){_0x226d92['push'](_0x226d92['shift']());}}}(a144_0x3111,0xbd21c));import{SegmentDefSchema,RuleDefSchema}from'./types/segment-schema.js';import{formatZodPath,flattenZodIssues,getLocationFromPath,pathToArray}from'./yaml-validator.js';export function validateSegmentDef(_0x5ec286,_0x27188a={},_0x9fe75d={}){const _0x25e6ab=a144_0x1dec;if(_0x9fe75d[_0x25e6ab(0x199)])return runSemanticChecks(_0x5ec286,_0x27188a);const _0x31ac47=SegmentDefSchema[_0x25e6ab(0x18b)](_0x5ec286);if(_0x31ac47['success'])return runSemanticChecks(_0x31ac47[_0x25e6ab(0x19e)],_0x27188a);return zodErrorsToValidationResult(_0x31ac47['error'],_0x27188a);}export function validateRuleDef(_0x558f0a,_0x3a97cf,_0xe63a08){const _0xabcad8=a144_0x1dec;if(!_0x558f0a)return[];const _0x51ef57=RuleDefSchema[_0xabcad8(0x18b)](_0x558f0a);if(_0x51ef57['success'])return checkRule(_0x51ef57[_0xabcad8(0x19e)],_0x3a97cf,_0xe63a08);const _0x445c37=flattenZodIssues(_0x51ef57[_0xabcad8(0x1a1)][_0xabcad8(0x184)]);return _0x445c37[_0xabcad8(0x18a)](_0x41ed3d=>{const _0x5af81a=_0xabcad8,_0x146570=formatZodPath(_0x41ed3d[_0x5af81a(0x1b8)]),_0x229b41=_0x146570?_0x3a97cf+'.'+_0x146570:_0x3a97cf,_0x1b3285=mapZodIssueToCode(_0x41ed3d,_0x146570),_0x22c07d=getLocationFromPath(_0xe63a08['document'],_0xe63a08[_0x5af81a(0x1af)],pathToArray(_0x229b41));return{'level':'error','path':_0x229b41,'code':_0x1b3285,'message':_0x41ed3d[_0x5af81a(0x1b7)],..._0x22c07d&&{'location':_0x22c07d}};});}function zodErrorsToValidationResult(_0x341a8a,_0x106c32){const _0x9b19e=a144_0x1dec,_0x439dd8=flattenZodIssues(_0x341a8a['issues']),_0x398168=_0x439dd8[_0x9b19e(0x18a)](_0x13208d=>{const _0x3cf385=_0x9b19e,_0x66641e=formatZodPath(_0x13208d[_0x3cf385(0x1b8)]),_0x4e04bd=mapZodIssueToCode(_0x13208d,_0x66641e),_0x28d212=getLocationFromPath(_0x106c32[_0x3cf385(0x1c1)],_0x106c32['source'],_0x13208d[_0x3cf385(0x1b8)][_0x3cf385(0x18a)](_0x4f289f=>typeof _0x4f289f===_0x3cf385(0x189)?String(_0x4f289f):_0x4f289f));return{'level':_0x3cf385(0x1a1),'path':_0x66641e,'code':_0x4e04bd,'message':_0x13208d[_0x3cf385(0x1b7)],..._0x28d212&&{'location':_0x28d212}};});return{'valid':![],'errors':_0x398168,'warnings':[]};}function mapZodIssueToCode(_0x2589f5,_0x9a19d5){const _0x1dac43=a144_0x1dec,_0x28e3c3=_0x2589f5['code']===_0x1dac43(0x194)?_0x2589f5['params']:undefined;if(_0x9a19d5===_0x1dac43(0x1b2))return _0x1dac43(0x1a4);if(_0x9a19d5===_0x1dac43(0x1a0)||_0x9a19d5[_0x1dac43(0x1c3)]('.type')){if(_0x2589f5[_0x1dac43(0x1a6)]===_0x1dac43(0x1b1)){if(_0x9a19d5===_0x1dac43(0x1a0)||_0x9a19d5['match'](/\.conditions\[\d+\]\.type$/))return _0x1dac43(0x183);}}if(_0x9a19d5[_0x1dac43(0x1c3)](_0x1dac43(0x1b3)))return _0x1dac43(0x1a7);if(_0x9a19d5[_0x1dac43(0x1c3)](_0x1dac43(0x1ae)))return _0x1dac43(0x1bf);if(_0x28e3c3?.[_0x1dac43(0x198)]===_0x1dac43(0x18d))return _0x1dac43(0x18d);if(_0x28e3c3?.[_0x1dac43(0x198)]===_0x1dac43(0x17e))return _0x1dac43(0x17e);if(_0x9a19d5[_0x1dac43(0x1c3)](_0x1dac43(0x1c0))||_0x9a19d5==='conditions')return _0x1dac43(0x1b4);if(_0x9a19d5['includes'](_0x1dac43(0x1ad)))return _0x1dac43(0x185);if(_0x9a19d5[_0x1dac43(0x1c3)](_0x1dac43(0x18e)))return'MISSING_SEGMENT_REFERENCE';return _0x1dac43(0x1b6);}function runSemanticChecks(_0x1ef0a5,_0xb5c93e){const _0x6708ec=a144_0x1dec,_0x19b3cd=[];_0x1ef0a5[_0x6708ec(0x180)]&&_0x19b3cd[_0x6708ec(0x18c)](...checkRule(_0x1ef0a5[_0x6708ec(0x180)],_0x6708ec(0x180),_0xb5c93e));const _0x4e85f6=_0x19b3cd[_0x6708ec(0x1aa)](_0x1dcec1=>_0x1dcec1[_0x6708ec(0x1ba)]===_0x6708ec(0x1a1)),_0xe0ef=_0x19b3cd['filter'](_0x339564=>_0x339564['level']===_0x6708ec(0x1bc));return{'valid':_0x4e85f6[_0x6708ec(0x1be)]===0x0,'errors':_0x4e85f6,'warnings':_0xe0ef};}function checkRule(_0x138050,_0x117147,_0x10d5f2){const _0x6961d9=a144_0x1dec,_0x389a28=[];if(_0x138050[_0x6961d9(0x1b0)][_0x6961d9(0x1be)]===0x0)return _0x389a28['push']({'level':_0x6961d9(0x1a1),'path':_0x117147+'.conditions','code':_0x6961d9(0x186),'message':_0x6961d9(0x191),'location':getLocationFromPath(_0x10d5f2['document'],_0x10d5f2['source'],pathToArray(_0x117147+'.conditions'))}),_0x389a28;return _0x389a28[_0x6961d9(0x18c)](...checkConditions(_0x138050['conditions'],_0x117147,_0x10d5f2)),_0x389a28;}function checkConditions(_0x2e47f2,_0x105bbc,_0x226db8){const _0x3bc076=a144_0x1dec,_0xa68243=[];for(let _0x411bd4=0x0;_0x411bd4<_0x2e47f2[_0x3bc076(0x1be)];_0x411bd4++){const _0x1abd91=_0x2e47f2[_0x411bd4],_0x5992e2=_0x105bbc+_0x3bc076(0x1ac)+_0x411bd4+']';_0xa68243[_0x3bc076(0x18c)](...checkCondition(_0x1abd91,_0x5992e2,_0x226db8));}return _0xa68243;}function a144_0x3111(){const _0x40a9fb=['rule.type','error','attribute','BEHAVIOR_SOURCE_MISSING_FILTER','MISSING_NAME','7701360NSTaMb','code','INVALID_OPERATOR_TYPE','972724hQhDUe','8580600jEcfkd','filter','requires\x20a\x20nested\x20\x27filter\x27.\x20Without\x20filter,\x20the\x20source\x20is\x20silently\x20ignored\x20and\x20','.conditions[','arrayMatching','.operator.value','source','conditions','invalid_value','name','.operator.type','MISSING_CONDITIONS','BEHAVIOR_SOURCE_WITH_ATTRIBUTE','SEGMENT_SCHEMA_ERROR','message','path','103LlyuzH','level','Attribute\x20\x27','warning','3HZfUYy','length','MISSING_OPERATOR_VALUE','.conditions','document','groups,\x20causing\x20local/server\x20discrepancy.\x20For\x20same-attribute\x20Or\x20conditions,\x20','endsWith','aggregation','MISSING_TIME_UNIT','.filter','rule','\x20condition\x20cannot\x20have\x20an\x20empty\x20conditions\x20array','Value','INVALID_RULE_TYPE','issues','INVALID_ARRAY_MATCHING','EMPTY_CONDITIONS','361665VvWJjs','15882nbqqLy','symbol','map','safeParse','push','MISSING_BETWEEN_BOUNDS','.segment','\x27\x20with\x20attribute\x20\x27','\x20condition\x20group\x20not\x20supported.\x20Console\x20UI\x20ignores\x20nested\x20condition\x20','Rule\x20conditions\x20array\x20cannot\x20be\x20empty.\x20Add\x20at\x20least\x20one\x20condition.','\x27\x20with\x20behavior\x20source\x20may\x20cause\x20unexpected\x20behavior.\x20','the\x20condition\x20queries\x20the\x20master\x20table\x20instead.\x20','custom','type','NESTED_CONDITION_GROUP','12367672UMuywB','validationCode','skipSchema','And','.attribute','.source','Attribute\x20name\x20cannot\x20be\x20empty','data','35349390gnOvXg'];a144_0x3111=function(){return _0x40a9fb;};return a144_0x3111();}function a144_0x1dec(_0x3bc30b,_0x108f92){_0x3bc30b=_0x3bc30b-0x17e;const _0x3111b3=a144_0x3111();let _0x1decb2=_0x3111b3[_0x3bc30b];return _0x1decb2;}function checkCondition(_0x5366c1,_0x68c850,_0x226844){const _0x56ddc0=a144_0x1dec,_0x2c59c3=[];if(_0x5366c1[_0x56ddc0(0x195)]===_0x56ddc0(0x19a)||_0x5366c1[_0x56ddc0(0x195)]==='Or')return _0x5366c1[_0x56ddc0(0x1b0)][_0x56ddc0(0x1be)]===0x0?_0x2c59c3[_0x56ddc0(0x18c)]({'level':_0x56ddc0(0x1a1),'path':_0x68c850+_0x56ddc0(0x1c0),'code':_0x56ddc0(0x186),'message':_0x5366c1[_0x56ddc0(0x195)]+_0x56ddc0(0x181),'location':getLocationFromPath(_0x226844[_0x56ddc0(0x1c1)],_0x226844[_0x56ddc0(0x1af)],pathToArray(_0x68c850+_0x56ddc0(0x1c0)))}):_0x2c59c3['push']({'level':_0x56ddc0(0x1a1),'path':_0x68c850,'code':_0x56ddc0(0x196),'message':_0x5366c1[_0x56ddc0(0x195)]+_0x56ddc0(0x190)+_0x56ddc0(0x1c2)+'use\x20\x27In\x27\x20operator\x20instead:\x20operator:\x20{\x20type:\x20In,\x20value:\x20[\x22val1\x22,\x20\x22val2\x22]\x20}','location':getLocationFromPath(_0x226844[_0x56ddc0(0x1c1)],_0x226844[_0x56ddc0(0x1af)],pathToArray(_0x68c850))}),_0x2c59c3;if(_0x5366c1[_0x56ddc0(0x195)]===_0x56ddc0(0x182)||_0x5366c1['type']==='Behavior'){const _0x5b03a7=_0x5366c1,_0x44ee5a=_0x5b03a7['source'],_0x5cd1f6=_0x5b03a7[_0x56ddc0(0x1c4)],_0x5a2ed1=_0x44ee5a||_0x5cd1f6;(!_0x5b03a7[_0x56ddc0(0x1a2)]||_0x5b03a7[_0x56ddc0(0x1a2)]==='')&&(!_0x5a2ed1&&_0x2c59c3[_0x56ddc0(0x18c)]({'level':_0x56ddc0(0x1a1),'path':_0x68c850+_0x56ddc0(0x19b),'code':'EMPTY_ATTRIBUTE','message':_0x56ddc0(0x19d),'location':getLocationFromPath(_0x226844[_0x56ddc0(0x1c1)],_0x226844[_0x56ddc0(0x1af)],pathToArray(_0x68c850+_0x56ddc0(0x19b)))}));_0x5b03a7[_0x56ddc0(0x1aa)]&&_0x2c59c3['push'](...checkRule(_0x5b03a7[_0x56ddc0(0x1aa)],_0x68c850+_0x56ddc0(0x17f),_0x226844));if(_0x5b03a7['source']){const _0x35748a=_0x5b03a7[_0x56ddc0(0x1a2)]&&_0x5b03a7[_0x56ddc0(0x1a2)]!=='';_0x35748a&&!_0x5b03a7['filter']&&_0x2c59c3[_0x56ddc0(0x18c)]({'level':'error','path':_0x68c850+_0x56ddc0(0x19c),'code':_0x56ddc0(0x1a3),'message':'Behavior\x20source\x20\x27'+_0x5b03a7[_0x56ddc0(0x1af)]+_0x56ddc0(0x18f)+_0x5b03a7['attribute']+'\x27\x20'+_0x56ddc0(0x1ab)+_0x56ddc0(0x193)+'Use\x20\x27attribute:\x20\x22\x22\x27\x20with\x20\x27filter.type:\x20And\x27\x20containing\x20\x27type:\x20Column\x27\x20conditions.','location':getLocationFromPath(_0x226844['document'],_0x226844[_0x56ddc0(0x1af)],pathToArray(_0x68c850+'.source'))}),_0x35748a&&_0x5b03a7[_0x56ddc0(0x1aa)]&&_0x2c59c3[_0x56ddc0(0x18c)]({'level':_0x56ddc0(0x1bc),'path':_0x68c850+_0x56ddc0(0x19b),'code':_0x56ddc0(0x1b5),'message':_0x56ddc0(0x1bb)+_0x5b03a7[_0x56ddc0(0x1a2)]+_0x56ddc0(0x192)+'For\x20behavior\x20aggregations,\x20use\x20\x27attribute:\x20\x22\x22\x27\x20with\x20Column\x20conditions\x20in\x20filter.','location':getLocationFromPath(_0x226844['document'],_0x226844['source'],pathToArray(_0x68c850+'.attribute'))});}}return _0x2c59c3;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
function a145_0x442d(){const _0x44de67=['stat','parent_segment','join','parse','File\x20not\x20found','scopedFolderPath','includes','trim','20nnKNGe','file','configDir','9819kjARPW','root','startsWith','No\x20tdx.json\x20found\x20for\x20file:\x20','845670GiPxGF','20ngKKye','tdx.json','folderPath','resolve','exists','type','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','parentSegment','resourceType','replace','2954237GGlKig','46745SlgKSZ','707200tahyCH','Segment\x20and\x20journey\x20files\x20must\x20have\x20.yml\x20or\x20.yaml\x20extension','parent_name','dirname','isScoped','No\x20tdx.json\x20found','match','error','message','relative','segment','771939bubMUo','journey','no_config','directory','context','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','string','28LUeCeT','156092mtwkQX','readFile','invalid_yaml','No\x20tdx.json\x20found\x20in\x20or\x20above:\x20','File\x20not\x20found:\x20','extname','segmentName','isFile','Parent\x20segment\x20not\x20specified','basename','file_not_found','7OWMmMC'];a145_0x442d=function(){return _0x44de67;};return a145_0x442d();}(function(_0x54842d,_0xc0eebb){const _0x2b637a=a145_0x1216,_0x2b7a88=_0x54842d();while(!![]){try{const _0x398ac5=parseInt(_0x2b637a(0x189))/0x1+-parseInt(_0x2b637a(0x161))/0x2*(-parseInt(_0x2b637a(0x179))/0x3)+-parseInt(_0x2b637a(0x162))/0x4*(-parseInt(_0x2b637a(0x176))/0x5)+-parseInt(_0x2b637a(0x17d))/0x6*(parseInt(_0x2b637a(0x16d))/0x7)+-parseInt(_0x2b637a(0x18a))/0x8+-parseInt(_0x2b637a(0x195))/0x9*(parseInt(_0x2b637a(0x17e))/0xa)+parseInt(_0x2b637a(0x188))/0xb;if(_0x398ac5===_0xc0eebb)break;else _0x2b7a88['push'](_0x2b7a88['shift']());}catch(_0x4867b3){_0x2b7a88['push'](_0x2b7a88['shift']());}}}(a145_0x442d,0x1c673));import a145_0x4e7455 from'path';import{sanitizeFileName}from'../../utils/string-utils.js';import{nodeFileSystem}from'../io/node-filesystem.js';function a145_0x1216(_0x401365,_0x33935b){_0x401365=_0x401365-0x161;const _0x442d36=a145_0x442d();let _0x1216be=_0x442d36[_0x401365];return _0x1216be;}import{isYamlFilePath,resolveYamlFilePath}from'./segment-path-parser.js';import{getSegmentRootDir}from'./tdx-config.js';export function isSuccessfulResolution(_0x8a0f90){const _0x3ed09b=a145_0x1216;return _0x8a0f90['type']!==_0x3ed09b(0x191);}export function isScopedResolution(_0xd8e40f){const _0x266d61=a145_0x1216;return _0xd8e40f[_0x266d61(0x183)]===_0x266d61(0x198)||_0xd8e40f[_0x266d61(0x183)]===_0x266d61(0x177)||_0xd8e40f[_0x266d61(0x183)]===_0x266d61(0x199);}export function getScopedDetails(_0x41b6d0){const _0x56b14d=a145_0x1216;if(isScopedResolution(_0x41b6d0))return{'isScoped':_0x41b6d0[_0x56b14d(0x18e)],'scopedFolderPath':_0x41b6d0[_0x56b14d(0x173)]};return undefined;}async function findTdxConfigAsync(_0x17897f,_0x363431){const _0x1427f8=a145_0x1216;let _0x394194=a145_0x4e7455[_0x1427f8(0x181)](_0x17897f);const _0x32d781=a145_0x4e7455[_0x1427f8(0x171)](_0x394194)[_0x1427f8(0x17a)];while(_0x394194!==_0x32d781){const _0x1efa77=a145_0x4e7455[_0x1427f8(0x170)](_0x394194,_0x1427f8(0x17f));if(await _0x363431[_0x1427f8(0x182)](_0x1efa77))try{const _0x2a9089=await _0x363431[_0x1427f8(0x163)](_0x1efa77),_0x5c6ac2=JSON[_0x1427f8(0x171)](_0x2a9089);if(_0x5c6ac2['parent_segment']&&typeof _0x5c6ac2['parent_segment']===_0x1427f8(0x19b))return{'configPath':_0x1efa77,'configDir':_0x394194,'parentSegment':_0x5c6ac2[_0x1427f8(0x16f)]};}catch{}_0x394194=a145_0x4e7455[_0x1427f8(0x18d)](_0x394194);}return null;}function calculateScopedPath(_0x570b68,_0x2bc677){const _0x15bebf=a145_0x1216,_0x4f7880=a145_0x4e7455[_0x15bebf(0x193)](_0x2bc677,_0x570b68),_0x1ad6e7=_0x4f7880!==''&&_0x4f7880!=='.'&&!_0x4f7880[_0x15bebf(0x17b)]('..');return{'isScoped':_0x1ad6e7,'scopedFolderPath':_0x1ad6e7?_0x4f7880[_0x15bebf(0x187)](/\\/g,'/'):''};}export async function resolveTarget(_0x5d81c0){const _0x531367=a145_0x1216,{arg:_0x5683b9,contextParent:_0x2ef3c5,cwd:cwd=process['cwd'](),fs:fs=nodeFileSystem}=_0x5d81c0;if(_0x5683b9&&isYamlFilePath(_0x5683b9))try{const _0x3af143=await resolveYamlFilePath(_0x5683b9,fs),_0x44d6c4=a145_0x4e7455[_0x531367(0x181)](_0x5683b9),_0x2f6ce7=a145_0x4e7455[_0x531367(0x18d)](_0x44d6c4),_0x2e04ee=await findTdxConfigAsync(_0x2f6ce7,fs);if(!_0x2e04ee){if(_0x2ef3c5){const _0x3b871d=a145_0x4e7455[_0x531367(0x18d)](_0x44d6c4);return{'type':'file','parentName':_0x2ef3c5,'targetDir':_0x3b871d,'configRoot':_0x3b871d,'filePath':_0x44d6c4,'resourceName':_0x3af143[_0x531367(0x168)],'folderPath':_0x3af143[_0x531367(0x180)],'resourceType':_0x3af143[_0x531367(0x186)],'isScoped':![],'scopedFolderPath':''};}return{'type':_0x531367(0x191),'errorCode':'no_config','message':_0x531367(0x17c)+_0x5683b9,'arg':_0x5683b9,'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 _0x50ce58=calculateScopedPath(_0x2f6ce7,_0x2e04ee[_0x531367(0x178)]);return{'type':_0x531367(0x177),'parentName':_0x2e04ee[_0x531367(0x185)],'targetDir':_0x2e04ee[_0x531367(0x178)],'configRoot':_0x2e04ee['configDir'],'filePath':_0x44d6c4,'resourceName':_0x3af143[_0x531367(0x168)],'folderPath':_0x3af143[_0x531367(0x180)],'resourceType':_0x3af143[_0x531367(0x186)],'isScoped':_0x50ce58[_0x531367(0x18e)],'scopedFolderPath':_0x50ce58[_0x531367(0x173)]};}catch(_0x5f024f){const _0x529e0e=_0x5f024f instanceof Error?_0x5f024f[_0x531367(0x192)]:String(_0x5f024f);if(_0x529e0e[_0x531367(0x174)](_0x531367(0x172)))return{'type':_0x531367(0x191),'errorCode':_0x531367(0x16c),'message':_0x531367(0x166)+_0x5683b9,'arg':_0x5683b9};if(_0x529e0e[_0x531367(0x174)](_0x531367(0x18f))){if(_0x2ef3c5){const _0x305937=a145_0x4e7455['resolve'](_0x5683b9);if(await fs[_0x531367(0x182)](_0x305937)){const _0x1f8aae=a145_0x4e7455[_0x531367(0x18d)](_0x305937),_0x5d2d3b=await fs[_0x531367(0x163)](_0x305937),_0x1fe892=_0x5d2d3b[_0x531367(0x190)](/^name:\s*["']?([^"'\n]+)["']?/m),_0x404d69=_0x5d2d3b['match'](/^type:\s*["']?([^"'\n]+)["']?/m),_0x49fd6a=_0x1fe892?_0x1fe892[0x1]['trim']():a145_0x4e7455[_0x531367(0x16b)](_0x5683b9,a145_0x4e7455[_0x531367(0x167)](_0x5683b9)),_0x11c701=_0x404d69&&_0x404d69[0x1][_0x531367(0x175)]()===_0x531367(0x196)?'journey':_0x531367(0x194);return{'type':_0x531367(0x177),'parentName':_0x2ef3c5,'targetDir':_0x1f8aae,'configRoot':_0x1f8aae,'filePath':_0x305937,'resourceName':_0x49fd6a,'folderPath':'','resourceType':_0x11c701,'isScoped':![],'scopedFolderPath':''};}}return{'type':_0x531367(0x191),'errorCode':_0x531367(0x197),'message':_0x531367(0x17c)+_0x5683b9,'arg':_0x5683b9,'helpText':_0x531367(0x184)};}return{'type':_0x531367(0x191),'errorCode':'invalid_yaml','message':_0x529e0e,'arg':_0x5683b9};}if(_0x5683b9){const _0xd7f531=a145_0x4e7455[_0x531367(0x181)](cwd,_0x5683b9);let _0xa1bae5=null;try{_0xa1bae5=await fs[_0x531367(0x16e)](_0xd7f531);}catch{}if(_0xa1bae5?.['isDirectory']()){const _0x390736=await findTdxConfigAsync(_0xd7f531,fs);if(_0x390736){const _0x27c342=calculateScopedPath(_0xd7f531,_0x390736['configDir']);return{'type':_0x531367(0x198),'parentName':_0x390736[_0x531367(0x185)],'targetDir':_0xd7f531,'configRoot':_0x390736[_0x531367(0x178)],'isScoped':_0x27c342[_0x531367(0x18e)],'scopedFolderPath':_0x27c342[_0x531367(0x173)]};}if(_0x2ef3c5)return{'type':_0x531367(0x198),'parentName':_0x2ef3c5,'targetDir':_0xd7f531,'configRoot':_0xd7f531,'isScoped':![],'scopedFolderPath':''};return{'type':'error','errorCode':'no_config','message':_0x531367(0x165)+_0x5683b9,'arg':_0x5683b9,'helpText':_0x531367(0x184)};}if(_0xa1bae5?.[_0x531367(0x169)]())return{'type':_0x531367(0x191),'errorCode':_0x531367(0x164),'message':'Not\x20a\x20YAML\x20file:\x20'+_0x5683b9,'arg':_0x5683b9,'helpText':_0x531367(0x18b)};const _0x56c4a3=sanitizeFileName(_0x5683b9),_0x12937c=getSegmentRootDir(_0x56c4a3,cwd);return{'type':_0x531367(0x18c),'parentName':_0x5683b9,'targetDir':_0x12937c,'configRoot':_0x12937c};}const _0x3eeba7=await findTdxConfigAsync(cwd,fs);if(_0x3eeba7){const _0x2ad416=calculateScopedPath(cwd,_0x3eeba7['configDir']);return{'type':_0x531367(0x199),'parentName':_0x3eeba7['parentSegment'],'targetDir':cwd,'configRoot':_0x3eeba7[_0x531367(0x178)],'isScoped':_0x2ad416[_0x531367(0x18e)],'scopedFolderPath':_0x2ad416[_0x531367(0x173)]};}if(_0x2ef3c5){const _0x21c26d=sanitizeFileName(_0x2ef3c5),_0xed4d02=getSegmentRootDir(_0x21c26d,cwd);return{'type':'context','parentName':_0x2ef3c5,'targetDir':_0xed4d02,'configRoot':_0xed4d02,'isScoped':![],'scopedFolderPath':''};}return{'type':_0x531367(0x191),'errorCode':'no_parent','message':_0x531367(0x16a),'helpText':_0x531367(0x19a)};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a146_0x215885=a146_0x1867;(function(_0x3ae5f0,_0x2e33a8){const _0x1cb6be=a146_0x1867,_0x21cd9c=_0x3ae5f0();while(!![]){try{const _0x1fa5c3=parseInt(_0x1cb6be(0x11f))/0x1*(parseInt(_0x1cb6be(0x11d))/0x2)+-parseInt(_0x1cb6be(0x12d))/0x3*(parseInt(_0x1cb6be(0x128))/0x4)+-parseInt(_0x1cb6be(0x120))/0x5+parseInt(_0x1cb6be(0x127))/0x6*(-parseInt(_0x1cb6be(0x11b))/0x7)+parseInt(_0x1cb6be(0x125))/0x8+parseInt(_0x1cb6be(0x121))/0x9*(parseInt(_0x1cb6be(0x11e))/0xa)+parseInt(_0x1cb6be(0x114))/0xb*(parseInt(_0x1cb6be(0x115))/0xc);if(_0x1fa5c3===_0x2e33a8)break;else _0x21cd9c['push'](_0x21cd9c['shift']());}catch(_0x610528){_0x21cd9c['push'](_0x21cd9c['shift']());}}}(a146_0x51b9,0x5345f));import{existsSync,readFileSync}from'fs';import a146_0x39b15c from'path';function a146_0x1867(_0x246690,_0x3717ab){_0x246690=_0x246690-0x112;const _0x51b964=a146_0x51b9();let _0x18677a=_0x51b964[_0x246690];return _0x18677a;}const TDX_CONFIG_FILE=a146_0x215885(0x117),SEGMENTS_DIR='segments';export function findTdxConfigPath(_0x6c4c22=process['cwd']()){const _0x5928ab=a146_0x215885;let _0x3df64e=a146_0x39b15c[_0x5928ab(0x129)](_0x6c4c22);const _0x161f53=a146_0x39b15c['parse'](_0x3df64e)['root'];while(_0x3df64e!==_0x161f53){const _0x4f3a8f=a146_0x39b15c[_0x5928ab(0x122)](_0x3df64e,TDX_CONFIG_FILE);if(existsSync(_0x4f3a8f))return _0x4f3a8f;_0x3df64e=a146_0x39b15c[_0x5928ab(0x118)](_0x3df64e);}return null;}export function loadTdxConfig(_0x5bad61){const _0x185798=a146_0x215885,_0x3ed342=readFileSync(_0x5bad61,_0x185798(0x12c));let _0x627158;try{_0x627158=JSON[_0x185798(0x11c)](_0x3ed342);}catch{throw new Error(_0x185798(0x116)+_0x5bad61);}if(!_0x627158||typeof _0x627158!==_0x185798(0x119))throw new Error(_0x185798(0x113));const _0x9b26e9=_0x627158,_0x5c13b9=_0x9b26e9['parent_segment']&&typeof _0x9b26e9['parent_segment']===_0x185798(0x126),_0x1f71b=_0x9b26e9['engage_workspace']&&typeof _0x9b26e9['engage_workspace']===_0x185798(0x126);if(!_0x5c13b9&&!_0x1f71b)throw new Error('Invalid\x20tdx.json:\x20must\x20contain\x20\x27parent_segment\x27\x20or\x20\x27engage_workspace\x27\x20field');const _0x53e811={};return _0x5c13b9&&(_0x53e811[_0x185798(0x11a)]=_0x9b26e9['parent_segment']),_0x1f71b&&(_0x53e811['engage_workspace']=_0x9b26e9[_0x185798(0x112)]),_0x53e811;}export function findTdxConfig(_0x52bf3e=process[a146_0x215885(0x124)]()){const _0x1ddbe4=a146_0x215885,_0x4d93e4=findTdxConfigPath(_0x52bf3e);if(!_0x4d93e4)throw new Error(_0x1ddbe4(0x123));const _0x1b3a8b=loadTdxConfig(_0x4d93e4),_0x36a00c=a146_0x39b15c[_0x1ddbe4(0x118)](_0x4d93e4);return{'config':_0x1b3a8b,'configPath':_0x4d93e4,'configDir':_0x36a00c};}export function tryFindTdxConfig(_0x310bb9){try{return findTdxConfig(_0x310bb9);}catch{return null;}}export function getSegmentRootDir(_0x2a445c,_0x1b3b23=process[a146_0x215885(0x124)]()){return a146_0x39b15c['join'](_0x1b3b23,SEGMENTS_DIR,_0x2a445c);}export function getTdxConfigPath(_0x37b557,_0x571f0f=process[a146_0x215885(0x124)]()){const _0x1dfe94=a146_0x215885;return a146_0x39b15c[_0x1dfe94(0x122)](getSegmentRootDir(_0x37b557,_0x571f0f),TDX_CONFIG_FILE);}export function getRelativePathFromConfig(_0x1aa80f,_0x1ce990){const _0x574eec=a146_0x215885,_0x3b902b=a146_0x39b15c[_0x574eec(0x129)](_0x1aa80f),_0x270e22=a146_0x39b15c[_0x574eec(0x12a)](_0x1ce990,_0x3b902b);if(_0x270e22['startsWith']('..'))return'';return _0x270e22;}export function localPathToTdFolderPath(_0x44dd5d){const _0x4d9bfb=a146_0x215885,_0x261e4e=a146_0x39b15c[_0x4d9bfb(0x118)](_0x44dd5d);if(_0x261e4e==='.'||_0x261e4e==='')return'';return _0x261e4e[_0x4d9bfb(0x12b)](/\\/g,'/');}export function tdFolderPathToLocalPath(_0x3c40fb,_0x9daaa8){const _0x150dfb=a146_0x215885;if(!_0x3c40fb)return _0x9daaa8;return a146_0x39b15c[_0x150dfb(0x122)](_0x9daaa8,_0x3c40fb);}export function createTdxConfigContent(_0x23f6e6){const _0x103f0a={'parent_segment':_0x23f6e6};return JSON['stringify'](_0x103f0a,null,0x2)+'\x0a';}function a146_0x51b9(){const _0x3fcaca=['relative','replace','utf-8','1224BBZbET','engage_workspace','Invalid\x20tdx.json:\x20expected\x20object','22MtdGZd','4370736wePBRc','Invalid\x20JSON\x20in\x20','tdx.json','dirname','object','parent_segment','1751029kUpHLc','parse','1328aAzIiw','10NzoiZr','472GgGeMl','3013125Xhzpov','4513527ZAuHlX','join','No\x20tdx.json\x20found.\x20Please\x20run\x20\x27tdx\x20sg\x20pull\x20<parent_segment>\x27\x20first\x20to\x20create\x20the\x20folder\x20structure.','cwd','1989304dhYWvc','string','12tSTBjx','3412EhwkfI','resolve'];a146_0x51b9=function(){return _0x3fcaca;};return a146_0x51b9();}export function createEngageTdxConfigContent(_0x4db965){const _0x2ec219={'engage_workspace':_0x4db965};return JSON['stringify'](_0x2ec219,null,0x2)+'\x0a';}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a147_0x3e21d6=a147_0x254d;(function(_0x5e05a4,_0x4ce958){const _0x26e7c0=a147_0x254d,_0x101898=_0x5e05a4();while(!![]){try{const _0x425491=parseInt(_0x26e7c0(0x195))/0x1+parseInt(_0x26e7c0(0x1ab))/0x2+-parseInt(_0x26e7c0(0x1a0))/0x3+parseInt(_0x26e7c0(0x1b1))/0x4+parseInt(_0x26e7c0(0x1b3))/0x5*(parseInt(_0x26e7c0(0x196))/0x6)+parseInt(_0x26e7c0(0x1a9))/0x7*(-parseInt(_0x26e7c0(0x1a2))/0x8)+-parseInt(_0x26e7c0(0x1a6))/0x9*(parseInt(_0x26e7c0(0x19c))/0xa);if(_0x425491===_0x4ce958)break;else _0x101898['push'](_0x101898['shift']());}catch(_0x1f6f22){_0x101898['push'](_0x101898['shift']());}}}(a147_0x36ae,0xcc0da));import{z}from'zod';export const ScheduleTypeSchema=z[a147_0x3e21d6(0x1bd)]([a147_0x3e21d6(0x1b4),a147_0x3e21d6(0x1ad),'daily',a147_0x3e21d6(0x19f),a147_0x3e21d6(0x197),a147_0x3e21d6(0x1bc),'minutes_interval']);export const RepeatUnitSchema=z['enum']([a147_0x3e21d6(0x1a3),'hour',a147_0x3e21d6(0x1a7),a147_0x3e21d6(0x1b2),a147_0x3e21d6(0x19d),a147_0x3e21d6(0x198),'none']);export const ScheduleDefSchema=z['object']({'type':ScheduleTypeSchema['optional'](),'repeat_unit':RepeatUnitSchema[a147_0x3e21d6(0x1b7)](),'repeat_frequency':z[a147_0x3e21d6(0x1b9)]()[a147_0x3e21d6(0x1b7)](),'repeat_sub_frequency':z['array'](z[a147_0x3e21d6(0x1b9)]())[a147_0x3e21d6(0x1b7)](),'start_at':z[a147_0x3e21d6(0x1ae)]()[a147_0x3e21d6(0x1aa)]()[a147_0x3e21d6(0x1b7)](),'end_on':z[a147_0x3e21d6(0x1ae)]()[a147_0x3e21d6(0x1aa)]()[a147_0x3e21d6(0x1b7)](),'timezone':z[a147_0x3e21d6(0x1ae)]()[a147_0x3e21d6(0x1b7)]()});export const NotificationDefSchema=z[a147_0x3e21d6(0x1a5)]({'notify_on':z['array'](z['enum']([a147_0x3e21d6(0x19b),a147_0x3e21d6(0x1ac)]))[a147_0x3e21d6(0x1b7)](),'email_recipients':z[a147_0x3e21d6(0x1b5)](z[a147_0x3e21d6(0x1ae)]())['optional']()});export const ActivationColumnDefSchema=z['union']([z[a147_0x3e21d6(0x1ae)](),z[a147_0x3e21d6(0x1a5)]({'name':z[a147_0x3e21d6(0x1ae)](),'type':z['string']()[a147_0x3e21d6(0x1b7)](),'visibility':z['enum']([a147_0x3e21d6(0x1af),a147_0x3e21d6(0x1a8)])[a147_0x3e21d6(0x1b7)]()})]);export const ActivationBehaviorDefSchema=z[a147_0x3e21d6(0x1a5)]({'columns':z[a147_0x3e21d6(0x1b5)](z[a147_0x3e21d6(0x1a5)]({'name':z[a147_0x3e21d6(0x1ae)](),'type':z[a147_0x3e21d6(0x1ae)]()['optional'](),'visibility':z[a147_0x3e21d6(0x1bd)](['clear',a147_0x3e21d6(0x1a8)])[a147_0x3e21d6(0x1b7)]()}))[a147_0x3e21d6(0x1b7)](),'behavior_table':z[a147_0x3e21d6(0x1ae)]()[a147_0x3e21d6(0x1b7)](),'join_row':z[a147_0x3e21d6(0x1b9)]()[a147_0x3e21d6(0x1aa)]()[a147_0x3e21d6(0x1b7)](),'join_strategy':z['enum']([a147_0x3e21d6(0x1ba),'First','Last',a147_0x3e21d6(0x199)])[a147_0x3e21d6(0x1b7)](),'formatting':z[a147_0x3e21d6(0x1bd)](['rows',a147_0x3e21d6(0x1be)])[a147_0x3e21d6(0x1b7)](),'order_by':z[a147_0x3e21d6(0x1b5)](z['object']({'key':z['string'](),'order':z[a147_0x3e21d6(0x1bd)]([a147_0x3e21d6(0x1bb),a147_0x3e21d6(0x1b0)])}))[a147_0x3e21d6(0x1b7)]()});export const ActivationDefSchema=z[a147_0x3e21d6(0x1a5)]({'name':z[a147_0x3e21d6(0x1ae)]()[a147_0x3e21d6(0x1a4)](0x1,a147_0x3e21d6(0x1b8)),'description':z[a147_0x3e21d6(0x1ae)]()[a147_0x3e21d6(0x1b7)](),'connection':z[a147_0x3e21d6(0x1ae)]()[a147_0x3e21d6(0x1a4)](0x1,a147_0x3e21d6(0x19e)),'all_columns':z['boolean']()[a147_0x3e21d6(0x1b7)](),'columns':z[a147_0x3e21d6(0x1b5)](ActivationColumnDefSchema)[a147_0x3e21d6(0x1b7)](),'schedule':ScheduleDefSchema[a147_0x3e21d6(0x1b7)](),'notification':NotificationDefSchema[a147_0x3e21d6(0x1b7)](),'connector_config':z[a147_0x3e21d6(0x1a1)](z[a147_0x3e21d6(0x1ae)](),z[a147_0x3e21d6(0x1b6)]())[a147_0x3e21d6(0x1b7)](),'activation_template_id':z[a147_0x3e21d6(0x1ae)]()['nullable']()[a147_0x3e21d6(0x1b7)](),'behavior':ActivationBehaviorDefSchema[a147_0x3e21d6(0x1aa)]()[a147_0x3e21d6(0x1b7)](),'run_after_journey_refresh':z[a147_0x3e21d6(0x19a)]()[a147_0x3e21d6(0x1b7)]()});function a147_0x254d(_0x383a3e,_0x24390c){_0x383a3e=_0x383a3e-0x195;const _0x36ae0f=a147_0x36ae();let _0x254d57=_0x36ae0f[_0x383a3e];return _0x254d57;}function a147_0x36ae(){const _0x161e7e=['day','masked','10317727CEgVLR','nullable','3262496GcLFaj','onFailure','hourly','string','clear','desc','5019108upuXQt','week','1255GhkqUS','none','array','unknown','optional','Activation\x20name\x20is\x20required','number','All','asc','cron','enum','cols','25604OiAUoT','25446dZolWL','monthly','once','Top-N','boolean','onSuccess','7795630SUmIfG','month','Connection\x20name\x20is\x20required','weekly','321693RwQnXX','record','8MsCoAI','minute','min','object','18GQlSEn'];a147_0x36ae=function(){return _0x161e7e;};return a147_0x36ae();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x36507a,_0x187d3e){var _0xc62d64=a148_0x2f76,_0x1104b2=_0x36507a();while(!![]){try{var _0x2759d4=parseInt(_0xc62d64(0x17f))/0x1+parseInt(_0xc62d64(0x183))/0x2*(-parseInt(_0xc62d64(0x180))/0x3)+-parseInt(_0xc62d64(0x17e))/0x4+-parseInt(_0xc62d64(0x17d))/0x5+parseInt(_0xc62d64(0x182))/0x6+-parseInt(_0xc62d64(0x17c))/0x7+parseInt(_0xc62d64(0x181))/0x8*(parseInt(_0xc62d64(0x184))/0x9);if(_0x2759d4===_0x187d3e)break;else _0x1104b2['push'](_0x1104b2['shift']());}catch(_0x2930b7){_0x1104b2['push'](_0x1104b2['shift']());}}}(a148_0xc368,0x68fcc));function a148_0x2f76(_0x48ace2,_0x150662){_0x48ace2=_0x48ace2-0x17c;var _0xc36839=a148_0xc368();var _0x2f7626=_0xc36839[_0x48ace2];return _0x2f7626;}export{JourneyStateTypeSchema,ReentryModeTypeSchema,WaitUnitTypeSchema,StepTypeValueSchema,EmbeddedSegmentDefSchema,CriteriaDefSchema,StepDefSchema,StageDefSchema,JourneyEntryDefSchema,JourneyDefSchema}from'./journey-schema.js';function a148_0xc368(){var _0x9e3767=['301875FeAsQt','1139344SdHfJi','556040dJvWYQ','1191399aTnnSg','416SfTVJG','945756ysufkh','2uDojoA','208917XytRrg','5238590JvmXTs'];a148_0xc368=function(){return _0x9e3767;};return a148_0xc368();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a149_0x402d9d=a149_0xd04d;(function(_0x46be3f,_0x475edc){const _0x4aa252=a149_0xd04d,_0x25f493=_0x46be3f();while(!![]){try{const _0x3bf931=-parseInt(_0x4aa252(0x1f1))/0x1+parseInt(_0x4aa252(0x1fe))/0x2+-parseInt(_0x4aa252(0x1ef))/0x3*(parseInt(_0x4aa252(0x1fa))/0x4)+parseInt(_0x4aa252(0x1fd))/0x5*(-parseInt(_0x4aa252(0x1e3))/0x6)+parseInt(_0x4aa252(0x1fc))/0x7+parseInt(_0x4aa252(0x1ff))/0x8*(parseInt(_0x4aa252(0x1e2))/0x9)+-parseInt(_0x4aa252(0x1f5))/0xa;if(_0x3bf931===_0x475edc)break;else _0x25f493['push'](_0x25f493['shift']());}catch(_0x5e993b){_0x25f493['push'](_0x25f493['shift']());}}}(a149_0x1550,0xc81ce));import{z}from'zod';import{RuleDefSchema}from'./segment-schema.js';import{ActivationDefSchema}from'./activation-schema.js';function a149_0x1550(){const _0x10a4a0=['enum','76000ASggEq','stages','week','Journey\x20name\x20is\x20required','8372170mcRkiY','journeys','Journey\x20must\x20have\x20exactly\x20one\x20of:\x20journeys,\x20stages,\x20or\x20versions','jump','merge','55972sAuAmH','lazy','2215255eZzrRx','15mrzTME','1956998VORkLw','9381992kFdCSc','string','number','ab_test','object','length','type','day','draft','activation','9dYoZFF','1161822hkZoFe','decision_point','record','isArray','array','end','reentry_always','boolean','literal','discriminatedUnion','optional','min','33IUAkAI'];a149_0x1550=function(){return _0x10a4a0;};return a149_0x1550();}export const JourneyStateTypeSchema=z[a149_0x402d9d(0x1f0)]([a149_0x402d9d(0x1e0),'simulation','launched']);export const ReentryModeTypeSchema=z[a149_0x402d9d(0x1f0)](['no_reentry','reentry_unless_goal_achieved',a149_0x402d9d(0x1e9)]);export const WaitUnitTypeSchema=z[a149_0x402d9d(0x1f0)]([a149_0x402d9d(0x206),a149_0x402d9d(0x1f3)]);export const StepTypeValueSchema=z[a149_0x402d9d(0x1f0)](['wait',a149_0x402d9d(0x1e1),a149_0x402d9d(0x1e4),a149_0x402d9d(0x202),a149_0x402d9d(0x1f9),a149_0x402d9d(0x1f8),'end']);export const EmbeddedSegmentDefSchema=z[a149_0x402d9d(0x203)]({'description':z[a149_0x402d9d(0x200)]()['optional'](),'rule':RuleDefSchema});const JumpTargetDefSchema=z[a149_0x402d9d(0x203)]({'journey':z[a149_0x402d9d(0x200)](),'stage':z[a149_0x402d9d(0x200)](),'bundle_id':z[a149_0x402d9d(0x200)]()[a149_0x402d9d(0x1ed)]()});export const CriteriaDefSchema=z[a149_0x402d9d(0x203)]({'name':z['string'](),'description':z[a149_0x402d9d(0x200)]()[a149_0x402d9d(0x1ed)](),'segment':z[a149_0x402d9d(0x200)](),'target':JumpTargetDefSchema[a149_0x402d9d(0x1ed)]()});const WaitConditionTimeoutDefSchema=z[a149_0x402d9d(0x203)]({'duration':z[a149_0x402d9d(0x201)](),'unit':WaitUnitTypeSchema,'next':z[a149_0x402d9d(0x200)]()[a149_0x402d9d(0x1ed)]()}),WaitConditionDefSchema=z['object']({'segment':z[a149_0x402d9d(0x200)](),'next':z[a149_0x402d9d(0x200)]()['optional'](),'timeout':WaitConditionTimeoutDefSchema[a149_0x402d9d(0x1ed)]()}),WaitStepParamsDefSchema=z['object']({'duration':z[a149_0x402d9d(0x201)]()[a149_0x402d9d(0x1ed)](),'unit':WaitUnitTypeSchema[a149_0x402d9d(0x1ed)](),'wait_until':z[a149_0x402d9d(0x200)]()[a149_0x402d9d(0x1ed)](),'condition':WaitConditionDefSchema[a149_0x402d9d(0x1ed)](),'days_of_week':z['array'](z[a149_0x402d9d(0x200)]())[a149_0x402d9d(0x1ed)]()}),StepBaseFields={'name':z[a149_0x402d9d(0x200)](),'uuid':z[a149_0x402d9d(0x200)]()[a149_0x402d9d(0x1ed)](),'next':z[a149_0x402d9d(0x200)]()[a149_0x402d9d(0x1ed)]()},WaitStepDefSchema=z['object']({...StepBaseFields,'type':z[a149_0x402d9d(0x1eb)]('wait'),'with':WaitStepParamsDefSchema}),ActivationStepParamsDefSchema=z[a149_0x402d9d(0x203)]({'activation':z[a149_0x402d9d(0x200)]()}),ActivationStepDefSchema=z[a149_0x402d9d(0x203)]({...StepBaseFields,'type':z['literal'](a149_0x402d9d(0x1e1)),'with':ActivationStepParamsDefSchema}),DecisionBranchDefSchema=z['object']({'name':z[a149_0x402d9d(0x200)](),'segment':z[a149_0x402d9d(0x200)]()[a149_0x402d9d(0x1ed)](),'segment_id':z[a149_0x402d9d(0x200)]()[a149_0x402d9d(0x1ed)](),'excluded':z[a149_0x402d9d(0x1ea)]()['optional'](),'next':z[a149_0x402d9d(0x200)]()[a149_0x402d9d(0x1ed)]()}),DecisionPointStepParamsDefSchema=z[a149_0x402d9d(0x203)]({'branches':z[a149_0x402d9d(0x1e7)](DecisionBranchDefSchema)}),DecisionPointStepDefSchema=z[a149_0x402d9d(0x203)]({...StepBaseFields,'type':z['literal'](a149_0x402d9d(0x1e4)),'with':DecisionPointStepParamsDefSchema}),AbTestVariantDefSchema=z[a149_0x402d9d(0x203)]({'id':z[a149_0x402d9d(0x200)]()['optional'](),'name':z[a149_0x402d9d(0x200)](),'percentage':z[a149_0x402d9d(0x201)](),'next':z[a149_0x402d9d(0x200)]()[a149_0x402d9d(0x1ed)]()}),AbTestStepParamsDefSchema=z[a149_0x402d9d(0x203)]({'variants':z[a149_0x402d9d(0x1e7)](AbTestVariantDefSchema),'unique_id':z[a149_0x402d9d(0x200)]()['optional'](),'customized_split':z[a149_0x402d9d(0x1ea)]()[a149_0x402d9d(0x1ed)]()}),AbTestStepDefSchema=z['object']({...StepBaseFields,'type':z['literal']('ab_test'),'with':AbTestStepParamsDefSchema}),MergeStepDefSchema=z[a149_0x402d9d(0x203)]({...StepBaseFields,'type':z[a149_0x402d9d(0x1eb)](a149_0x402d9d(0x1f9))}),JumpStepParamsDefSchema=z[a149_0x402d9d(0x203)]({'target':JumpTargetDefSchema}),JumpStepDefSchema=z['object']({...StepBaseFields,'type':z['literal'](a149_0x402d9d(0x1f8)),'with':JumpStepParamsDefSchema}),EndStepDefSchema=z['object']({...StepBaseFields,'type':z[a149_0x402d9d(0x1eb)](a149_0x402d9d(0x1e8))})['passthrough']();export const StepDefSchema=z[a149_0x402d9d(0x1ec)](a149_0x402d9d(0x205),[WaitStepDefSchema,ActivationStepDefSchema,DecisionPointStepDefSchema,AbTestStepDefSchema,MergeStepDefSchema,JumpStepDefSchema,EndStepDefSchema]);export const StageDefSchema=z[a149_0x402d9d(0x203)]({'name':z['string'](),'description':z[a149_0x402d9d(0x200)]()['optional'](),'id':z['string']()['optional'](),'entry_criteria':CriteriaDefSchema[a149_0x402d9d(0x1ed)](),'exit_criteria':z[a149_0x402d9d(0x1e7)](CriteriaDefSchema)[a149_0x402d9d(0x1ed)](),'milestone':CriteriaDefSchema['optional'](),'root_step':z['string']()['optional'](),'steps':z['array'](StepDefSchema)['optional']()});export const JourneyEntryDefSchema=z[a149_0x402d9d(0x203)]({'name':z[a149_0x402d9d(0x200)]()[a149_0x402d9d(0x1ed)](),'version':z['string']()[a149_0x402d9d(0x1ed)](),'state':JourneyStateTypeSchema[a149_0x402d9d(0x1ed)](),'latest':z[a149_0x402d9d(0x1ea)]()[a149_0x402d9d(0x1ed)](),'stages':z['array'](StageDefSchema),'id':z['string']()[a149_0x402d9d(0x1ed)](),'version_number':z[a149_0x402d9d(0x201)]()['optional'](),'goal':CriteriaDefSchema[a149_0x402d9d(0x1ed)](),'reentry':ReentryModeTypeSchema[a149_0x402d9d(0x1ed)]()});function a149_0xd04d(_0x5ab481,_0x56c1fe){_0x5ab481=_0x5ab481-0x1e0;const _0x155092=a149_0x1550();let _0xd04d1=_0x155092[_0x5ab481];return _0xd04d1;}export const JourneyDefSchema=z[a149_0x402d9d(0x1fb)](()=>z[a149_0x402d9d(0x203)]({'type':z[a149_0x402d9d(0x1eb)]('journey'),'name':z[a149_0x402d9d(0x200)]()[a149_0x402d9d(0x1ee)](0x1,a149_0x402d9d(0x1f4)),'description':z[a149_0x402d9d(0x200)]()[a149_0x402d9d(0x1ed)](),'bundle_id':z['string']()['optional'](),'bundle_name':z[a149_0x402d9d(0x200)]()['optional'](),'folder_id':z['string']()[a149_0x402d9d(0x1ed)](),'reentry':ReentryModeTypeSchema[a149_0x402d9d(0x1ed)](),'allow_reentry':z[a149_0x402d9d(0x1ea)]()[a149_0x402d9d(0x1ed)](),'goal':CriteriaDefSchema[a149_0x402d9d(0x1ed)](),'id':z[a149_0x402d9d(0x200)]()[a149_0x402d9d(0x1ed)](),'version':z[a149_0x402d9d(0x200)]()[a149_0x402d9d(0x1ed)](),'version_number':z[a149_0x402d9d(0x201)]()['optional'](),'stages':z[a149_0x402d9d(0x1e7)](StageDefSchema)[a149_0x402d9d(0x1ed)](),'versions':z[a149_0x402d9d(0x1e7)](JourneyEntryDefSchema)[a149_0x402d9d(0x1ed)](),'journeys':z[a149_0x402d9d(0x1e7)](JourneyEntryDefSchema)['optional'](),'segments':z[a149_0x402d9d(0x1e5)](z[a149_0x402d9d(0x200)](),EmbeddedSegmentDefSchema)['optional'](),'activations':z[a149_0x402d9d(0x1e5)](z[a149_0x402d9d(0x200)](),ActivationDefSchema)['optional']()})['refine'](_0x264803=>{const _0x503999=a149_0x402d9d,_0x4c21d1=[_0x264803[_0x503999(0x1f6)],_0x264803[_0x503999(0x1f2)],_0x264803['versions']]['filter'](_0x2acc80=>Array[_0x503999(0x1e6)](_0x2acc80)&&_0x2acc80[_0x503999(0x204)]>0x0)['length'];return _0x4c21d1===0x1;},{'message':a149_0x402d9d(0x1f7)}));const _syncCheck1=!![],_syncCheck2=!![];void _syncCheck1,void _syncCheck2;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x169479,_0xa68251){var _0x2e637a=a151_0x4262,_0x2d7098=_0x169479();while(!![]){try{var _0x446666=-parseInt(_0x2e637a(0x1cc))/0x1*(-parseInt(_0x2e637a(0x1d2))/0x2)+-parseInt(_0x2e637a(0x1d4))/0x3*(parseInt(_0x2e637a(0x1d0))/0x4)+-parseInt(_0x2e637a(0x1ce))/0x5+-parseInt(_0x2e637a(0x1d3))/0x6*(-parseInt(_0x2e637a(0x1d6))/0x7)+parseInt(_0x2e637a(0x1d1))/0x8+-parseInt(_0x2e637a(0x1d5))/0x9+-parseInt(_0x2e637a(0x1cd))/0xa*(parseInt(_0x2e637a(0x1cf))/0xb);if(_0x446666===_0xa68251)break;else _0x2d7098['push'](_0x2d7098['shift']());}catch(_0x567178){_0x2d7098['push'](_0x2d7098['shift']());}}}(a151_0x8398,0xf2dff));function a151_0x4262(_0x5e02e3,_0x5660bb){_0x5e02e3=_0x5e02e3-0x1cc;var _0x83981b=a151_0x8398();var _0x426211=_0x83981b[_0x5e02e3];return _0x426211;}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 a151_0x8398(){var _0x1fbb97=['2696036AYprvC','2wQOcbG','2410eEtEES','7069810iKGqoD','23705dDZLrw','1231612QZaIhY','11985392adZUUK','1624762AGkttV','6zlQwHE','3MWIxaW','2448441kuJUpH'];a151_0x8398=function(){return _0x1fbb97;};return a151_0x8398();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const a152_0x3280dc=a152_0x3b40;(function(_0x22a32a,_0x4b8b89){const _0x2a3f9b=a152_0x3b40,_0x39ad29=_0x22a32a();while(!![]){try{const _0x424e46=-parseInt(_0x2a3f9b(0x1c9))/0x1*(parseInt(_0x2a3f9b(0x1d5))/0x2)+-parseInt(_0x2a3f9b(0x1c7))/0x3+-parseInt(_0x2a3f9b(0x1f6))/0x4+-parseInt(_0x2a3f9b(0x1ef))/0x5*(-parseInt(_0x2a3f9b(0x1d1))/0x6)+-parseInt(_0x2a3f9b(0x1db))/0x7*(-parseInt(_0x2a3f9b(0x1c2))/0x8)+parseInt(_0x2a3f9b(0x207))/0x9+-parseInt(_0x2a3f9b(0x202))/0xa;if(_0x424e46===_0x4b8b89)break;else _0x39ad29['push'](_0x39ad29['shift']());}catch(_0x587096){_0x39ad29['push'](_0x39ad29['shift']());}}}(a152_0x588e,0xa7cf3));import{z}from'zod';export const OperatorTypeSchema=z[a152_0x3280dc(0x1ce)]([a152_0x3280dc(0x1e0),a152_0x3280dc(0x1b8),a152_0x3280dc(0x1c6),a152_0x3280dc(0x1b9),a152_0x3280dc(0x1e1),'In',a152_0x3280dc(0x200),a152_0x3280dc(0x1fb),'IsNull',a152_0x3280dc(0x1cd),a152_0x3280dc(0x1be),a152_0x3280dc(0x1de),a152_0x3280dc(0x1fc),a152_0x3280dc(0x203),a152_0x3280dc(0x1cb)]);export const TimeUnitSchema=z[a152_0x3280dc(0x1ce)]([a152_0x3280dc(0x1fa),a152_0x3280dc(0x1e5),a152_0x3280dc(0x1e9),'day','week',a152_0x3280dc(0x1ff),'year']);export const AggregationTypeSchema=z[a152_0x3280dc(0x1ce)]([a152_0x3280dc(0x1bb),a152_0x3280dc(0x1d9),a152_0x3280dc(0x201),a152_0x3280dc(0x1ba),a152_0x3280dc(0x1f2),a152_0x3280dc(0x1fd),'First','Last']);const TemporalValueSchema=z[a152_0x3280dc(0x1da)]([z[a152_0x3280dc(0x1f9)]({'timestamp':z[a152_0x3280dc(0x1ec)]()}),z['object']({'last':z[a152_0x3280dc(0x1da)]([z[a152_0x3280dc(0x1f7)](),z[a152_0x3280dc(0x1c4)](z[a152_0x3280dc(0x1ec)](),z['number']())]),'unit':z['string']()})]),OperatorValueSchema=z[a152_0x3280dc(0x1da)]([z[a152_0x3280dc(0x1ec)](),z['number'](),z[a152_0x3280dc(0x1bf)](),TemporalValueSchema,z['array'](z[a152_0x3280dc(0x1da)]([z[a152_0x3280dc(0x1ec)](),z[a152_0x3280dc(0x1f7)](),z[a152_0x3280dc(0x1bf)]()]))]),OPERATORS_REQUIRING_VALUE=new Set([a152_0x3280dc(0x1e0),a152_0x3280dc(0x1b8),a152_0x3280dc(0x1b9),a152_0x3280dc(0x1c6),a152_0x3280dc(0x1e1),'In',a152_0x3280dc(0x1de),a152_0x3280dc(0x1fc),a152_0x3280dc(0x203),a152_0x3280dc(0x1fb),a152_0x3280dc(0x1cd),'TimeWithinNext']),OPERATORS_REQUIRING_UNIT=new Set([a152_0x3280dc(0x1cd),a152_0x3280dc(0x1be)]);function a152_0x588e(){const _0x8f0d98=['Last','2HaTQwu','include','has','superRefine','Sum','union','1981sBZmOk','Timestamp\x20column\x20only\x20supports\x20TimeWithinPast,\x20TimeWithinNext,\x20or\x20TimeRange\x20operators\x20(got\x20\x27','Column','Contain','TimeRange\x20operator\x20requires\x20\x27from\x27','Equal','LessEqual','Behavior','all','value','minute','min','\x27\x20requires\x20a\x20value','column','hour','MISSING_BETWEEN_BOUNDS','TimeRange\x20operator\x20requires\x20\x27duration\x27','string','operator','from','65dsANJi','duration','lazy','Max','First','array','max','3642528sFXKSd','number','funnel_stage','object','second','Regexp','StartWith','CountDistinct','Between\x20operator\x20requires\x20\x27min\x27\x20and/or\x20\x27max\x27\x20values','month','Between','Average','5273800mrmRgq','EndWith','\x27\x20requires\x20a\x20time\x20unit','optional','Operator\x20\x27','4136760xUGSac','Greater','GreaterEqual','Min','Count','Segment\x20name\x20is\x20required','type','TimeWithinNext','boolean','literal','custom','37216bPTvaR','any','record','MISSING_TIME_UNIT','Less','1268361ORODkq','realtime','537812GQhzdX','\x27\x20is\x20only\x20valid\x20for\x20the\x20\x27timestamp\x27\x20column','TimeRange','addIssue','TimeWithinPast','enum','batch','timestamp','604524wKIOos','And','exclude'];a152_0x588e=function(){return _0x8f0d98;};return a152_0x588e();}function a152_0x3b40(_0x1d43db,_0x1b4317){_0x1d43db=_0x1d43db-0x1b8;const _0x588ee1=a152_0x588e();let _0x3b404b=_0x588ee1[_0x1d43db];return _0x3b404b;}export const OperatorDefSchema=z[a152_0x3280dc(0x1f9)]({'type':OperatorTypeSchema,'not':z['boolean']()[a152_0x3280dc(0x205)](),'value':OperatorValueSchema['optional'](),'min':z['union']([z['number'](),z[a152_0x3280dc(0x1ec)](),TemporalValueSchema])[a152_0x3280dc(0x205)](),'max':z[a152_0x3280dc(0x1da)]([z['number'](),z[a152_0x3280dc(0x1ec)](),TemporalValueSchema])[a152_0x3280dc(0x205)](),'unit':TimeUnitSchema[a152_0x3280dc(0x205)](),'duration':z[a152_0x3280dc(0x1f9)]({'day':z[a152_0x3280dc(0x1f7)]()[a152_0x3280dc(0x205)](),'week':z[a152_0x3280dc(0x1f7)]()[a152_0x3280dc(0x205)](),'month':z[a152_0x3280dc(0x1f7)]()['optional'](),'year':z[a152_0x3280dc(0x1f7)]()[a152_0x3280dc(0x205)](),'hour':z[a152_0x3280dc(0x1f7)]()[a152_0x3280dc(0x205)](),'minute':z['number']()[a152_0x3280dc(0x205)](),'second':z[a152_0x3280dc(0x1f7)]()[a152_0x3280dc(0x205)]()})['optional'](),'from':z['object']({'last':z[a152_0x3280dc(0x1da)]([z[a152_0x3280dc(0x1f7)](),z[a152_0x3280dc(0x1ec)]()]),'unit':TimeUnitSchema})[a152_0x3280dc(0x205)](),'reverse':z[a152_0x3280dc(0x1bf)]()[a152_0x3280dc(0x205)]()})[a152_0x3280dc(0x1d8)]((_0x44ff04,_0x1f6f32)=>{const _0x1a9d31=a152_0x3280dc;OPERATORS_REQUIRING_VALUE['has'](_0x44ff04[_0x1a9d31(0x1bd)])&&(_0x44ff04[_0x1a9d31(0x1e4)]===undefined||_0x44ff04[_0x1a9d31(0x1e4)]===null)&&_0x1f6f32[_0x1a9d31(0x1cc)]({'code':_0x1a9d31(0x1c1),'message':_0x1a9d31(0x206)+_0x44ff04[_0x1a9d31(0x1bd)]+_0x1a9d31(0x1e7),'path':[_0x1a9d31(0x1e4)]}),_0x44ff04[_0x1a9d31(0x1bd)]==='Between'&&_0x44ff04[_0x1a9d31(0x1e6)]===undefined&&_0x44ff04[_0x1a9d31(0x1f5)]===undefined&&_0x1f6f32[_0x1a9d31(0x1cc)]({'code':_0x1a9d31(0x1c1),'message':_0x1a9d31(0x1fe),'params':{'validationCode':_0x1a9d31(0x1ea)}}),OPERATORS_REQUIRING_UNIT[_0x1a9d31(0x1d7)](_0x44ff04[_0x1a9d31(0x1bd)])&&_0x44ff04[_0x1a9d31(0x1e4)]!==undefined&&!_0x44ff04['unit']&&_0x1f6f32[_0x1a9d31(0x1cc)]({'code':'custom','message':_0x1a9d31(0x206)+_0x44ff04[_0x1a9d31(0x1bd)]+_0x1a9d31(0x204),'path':['unit'],'params':{'validationCode':_0x1a9d31(0x1c5)}}),_0x44ff04[_0x1a9d31(0x1bd)]==='TimeRange'&&(!_0x44ff04[_0x1a9d31(0x1f0)]&&_0x1f6f32[_0x1a9d31(0x1cc)]({'code':_0x1a9d31(0x1c1),'message':_0x1a9d31(0x1eb),'path':[_0x1a9d31(0x1f0)]}),!_0x44ff04['from']&&_0x1f6f32[_0x1a9d31(0x1cc)]({'code':_0x1a9d31(0x1c1),'message':_0x1a9d31(0x1df),'path':[_0x1a9d31(0x1ee)]}));});export const ArrayMatchingSchema=z[a152_0x3280dc(0x1da)]([z[a152_0x3280dc(0x1c0)]('any'),z[a152_0x3280dc(0x1c0)](a152_0x3280dc(0x1e3)),z[a152_0x3280dc(0x1f9)]({'atLeast':z[a152_0x3280dc(0x1f7)]()}),z[a152_0x3280dc(0x1f9)]({'atMost':z[a152_0x3280dc(0x1f7)]()}),z[a152_0x3280dc(0x1f9)]({'exactly':z[a152_0x3280dc(0x1f7)]()})]);export const AggregationDefSchema=z['discriminatedUnion']('type',[z[a152_0x3280dc(0x1f9)]({'type':z[a152_0x3280dc(0x1ce)]([a152_0x3280dc(0x1d9),a152_0x3280dc(0x1ba),a152_0x3280dc(0x1f2),'Average']),'column':z[a152_0x3280dc(0x1ec)](),'groupingColumns':z['array'](z[a152_0x3280dc(0x1ec)]())[a152_0x3280dc(0x205)]()}),z[a152_0x3280dc(0x1f9)]({'type':z['literal']('Count'),'groupingColumns':z['array'](z['string']())[a152_0x3280dc(0x205)]()}),z[a152_0x3280dc(0x1f9)]({'type':z[a152_0x3280dc(0x1c0)](a152_0x3280dc(0x1fd)),'columns':z[a152_0x3280dc(0x1f4)](z[a152_0x3280dc(0x1ec)]())}),z['object']({'type':z[a152_0x3280dc(0x1ce)]([a152_0x3280dc(0x1f3),a152_0x3280dc(0x1d4)]),'column':z[a152_0x3280dc(0x1ec)](),'orderColumn':z[a152_0x3280dc(0x1ec)](),'groupingColumns':z[a152_0x3280dc(0x1f4)](z[a152_0x3280dc(0x1ec)]())[a152_0x3280dc(0x205)]()})]);export const TimeWindowDefSchema=z['object']({'duration':z['number'](),'unit':TimeUnitSchema});const TIMESTAMP_OPERATORS=new Set([a152_0x3280dc(0x1cd),a152_0x3280dc(0x1be),'TimeRange']);export const FilterColumnConditionDefSchema=z[a152_0x3280dc(0x1f9)]({'type':z['literal'](a152_0x3280dc(0x1dd)),'column':z[a152_0x3280dc(0x1ec)](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema[a152_0x3280dc(0x205)]()})[a152_0x3280dc(0x1d8)]((_0x4e8816,_0x14cf16)=>{const _0x3b9624=a152_0x3280dc,_0xc9326a=_0x4e8816[_0x3b9624(0x1ed)]['type'];_0x4e8816[_0x3b9624(0x1e8)]===_0x3b9624(0x1d0)?!TIMESTAMP_OPERATORS[_0x3b9624(0x1d7)](_0xc9326a)&&_0x14cf16[_0x3b9624(0x1cc)]({'code':_0x3b9624(0x1c1),'message':_0x3b9624(0x1dc)+_0xc9326a+'\x27)','path':[_0x3b9624(0x1ed),_0x3b9624(0x1bd)]}):TIMESTAMP_OPERATORS[_0x3b9624(0x1d7)](_0xc9326a)&&_0x14cf16[_0x3b9624(0x1cc)]({'code':_0x3b9624(0x1c1),'message':_0x3b9624(0x206)+_0xc9326a+_0x3b9624(0x1ca),'path':[_0x3b9624(0x1ed),'type']});});export const FilterRuleDefSchema=z[a152_0x3280dc(0x1f9)]({'type':z['literal'](a152_0x3280dc(0x1d2)),'conditions':z['array'](FilterColumnConditionDefSchema)});export const ValueConditionDefSchema=z[a152_0x3280dc(0x1f1)](()=>z[a152_0x3280dc(0x1f9)]({'type':z[a152_0x3280dc(0x1c0)]('Value'),'attribute':z['string'](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema['optional'](),'exclude':z['boolean']()[a152_0x3280dc(0x205)](),'aggregation':AggregationDefSchema[a152_0x3280dc(0x205)](),'source':z[a152_0x3280dc(0x1ec)]()[a152_0x3280dc(0x205)](),'filter':FilterRuleDefSchema[a152_0x3280dc(0x205)](),'limit':z['number']()[a152_0x3280dc(0x205)]()}));export const BehaviorConditionDefSchema=z[a152_0x3280dc(0x1f1)](()=>z[a152_0x3280dc(0x1f9)]({'type':z[a152_0x3280dc(0x1c0)](a152_0x3280dc(0x1e2)),'attribute':z[a152_0x3280dc(0x1ec)](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema[a152_0x3280dc(0x205)](),'exclude':z[a152_0x3280dc(0x1bf)]()[a152_0x3280dc(0x205)](),'aggregation':AggregationDefSchema[a152_0x3280dc(0x205)](),'source':z['string']()['optional'](),'filter':FilterRuleDefSchema['optional'](),'timeWindow':TimeWindowDefSchema['optional'](),'limit':z['number']()[a152_0x3280dc(0x205)]()}));export const ColumnConditionDefSchema=z[a152_0x3280dc(0x1f9)]({'type':z[a152_0x3280dc(0x1c0)](a152_0x3280dc(0x1dd)),'column':z[a152_0x3280dc(0x1ec)](),'operator':OperatorDefSchema});export const CompositeConditionDefSchema=z[a152_0x3280dc(0x1f1)](()=>z[a152_0x3280dc(0x1f9)]({'type':z[a152_0x3280dc(0x1ce)]([a152_0x3280dc(0x1d2),'Or']),'conditions':z[a152_0x3280dc(0x1f4)](ConditionDefSchema),'description':z[a152_0x3280dc(0x1ec)]()[a152_0x3280dc(0x205)]()}));export const SegmentRefConditionDefSchema=z[a152_0x3280dc(0x1f9)]({'type':z[a152_0x3280dc(0x1ce)]([a152_0x3280dc(0x1d6),a152_0x3280dc(0x1d3)]),'segment':z[a152_0x3280dc(0x1ec)]()[a152_0x3280dc(0x1e6)](0x1,'Segment\x20reference\x20must\x20not\x20be\x20empty')});export const ConditionDefSchema=z[a152_0x3280dc(0x1f1)](()=>z[a152_0x3280dc(0x1da)]([ValueConditionDefSchema,BehaviorConditionDefSchema,ColumnConditionDefSchema,CompositeConditionDefSchema,SegmentRefConditionDefSchema]));export const RuleDefSchema=z[a152_0x3280dc(0x1f1)](()=>z['object']({'type':z[a152_0x3280dc(0x1ce)]([a152_0x3280dc(0x1d2),'Or']),'conditions':z[a152_0x3280dc(0x1f4)](ConditionDefSchema),'description':z['string']()[a152_0x3280dc(0x205)]()}));export const SegmentDefSchema=z[a152_0x3280dc(0x1f9)]({'type':z[a152_0x3280dc(0x1c0)]('segment')[a152_0x3280dc(0x205)](),'name':z[a152_0x3280dc(0x1ec)]()[a152_0x3280dc(0x1e6)](0x1,a152_0x3280dc(0x1bc)),'description':z[a152_0x3280dc(0x1ec)]()[a152_0x3280dc(0x205)](),'folder':z[a152_0x3280dc(0x1ec)]()[a152_0x3280dc(0x205)](),'rule':RuleDefSchema[a152_0x3280dc(0x205)](),'kind':z[a152_0x3280dc(0x1ce)]([a152_0x3280dc(0x1cf),a152_0x3280dc(0x1c8),a152_0x3280dc(0x1f8)])[a152_0x3280dc(0x205)](),'visible':z[a152_0x3280dc(0x1bf)]()[a152_0x3280dc(0x205)](),'activations':z[a152_0x3280dc(0x1f4)](z[a152_0x3280dc(0x1c3)]())[a152_0x3280dc(0x205)]()});const _syncCheck1=!![],_syncCheck2=!![];void _syncCheck1,void _syncCheck2;
|
|
1
|
+
const a152_0x44dc78=a152_0x1803;(function(_0x4a9a3f,_0x810976){const _0x16c604=a152_0x1803,_0x145a1a=_0x4a9a3f();while(!![]){try{const _0x4effd6=parseInt(_0x16c604(0xa5))/0x1*(-parseInt(_0x16c604(0xe4))/0x2)+-parseInt(_0x16c604(0xd6))/0x3*(-parseInt(_0x16c604(0xc1))/0x4)+-parseInt(_0x16c604(0x9e))/0x5*(-parseInt(_0x16c604(0xc6))/0x6)+parseInt(_0x16c604(0xab))/0x7+parseInt(_0x16c604(0xcd))/0x8*(parseInt(_0x16c604(0xa8))/0x9)+-parseInt(_0x16c604(0xd7))/0xa*(-parseInt(_0x16c604(0xaf))/0xb)+parseInt(_0x16c604(0xb6))/0xc*(-parseInt(_0x16c604(0xa9))/0xd);if(_0x4effd6===_0x810976)break;else _0x145a1a['push'](_0x145a1a['shift']());}catch(_0x554ff0){_0x145a1a['push'](_0x145a1a['shift']());}}}(a152_0x1070,0x6ec8b));function a152_0x1070(){const _0xf42b76=['Max','Regexp','day','discriminatedUnion','number','1tngQfV','Operator\x20\x27','column','124659qPDIiP','39aSEPqb','type','932162gRGLvV','boolean','TimeWithinNext','operator','73513rhoNbc','second','addIssue','GreaterEqual','Last','And','MISSING_BETWEEN_BOUNDS','8054052MTnQBY','enum','Segment\x20name\x20is\x20required','LessEqual','\x27\x20is\x20only\x20valid\x20for\x20the\x20\x27timestamp\x27\x20column','custom','literal','object','Value','duration','Min','54052TJzdMI','StartWith','CountDistinct','has','TimeRange\x20operator\x20requires\x20\x27from\x27','143118kGtqHY','Contain','Less','batch','Average','Behavior','Column','352yAnjrx','unit','Greater','Segment\x20reference\x20must\x20not\x20be\x20empty','IsNull','superRefine','union','lazy','EndWith','198NHRFiU','880DjiDhH','array','funnel_stage','TimeWithinPast','record','any','optional','Between','string','all','Equal','hour','TimeRange','1227992zCVibk','TimeRange\x20operator\x20requires\x20\x27duration\x27','value','\x27\x20requires\x20a\x20time\x20unit','Count','min','realtime','Sum','180HYpDCO','from'];a152_0x1070=function(){return _0xf42b76;};return a152_0x1070();}import{z}from'zod';export const OperatorTypeSchema=z[a152_0x44dc78(0xb7)]([a152_0x44dc78(0xe1),a152_0x44dc78(0xcf),a152_0x44dc78(0xc8),a152_0x44dc78(0xb2),a152_0x44dc78(0xb9),'In',a152_0x44dc78(0xde),a152_0x44dc78(0xa1),a152_0x44dc78(0xd1),a152_0x44dc78(0xda),a152_0x44dc78(0xad),a152_0x44dc78(0xc7),a152_0x44dc78(0xc2),a152_0x44dc78(0xd5),a152_0x44dc78(0xe3)]);export const TimeUnitSchema=z[a152_0x44dc78(0xb7)]([a152_0x44dc78(0xb0),'minute',a152_0x44dc78(0xe2),a152_0x44dc78(0xa2),'week','month','year']);export const AggregationTypeSchema=z[a152_0x44dc78(0xb7)]([a152_0x44dc78(0x9a),'Sum',a152_0x44dc78(0xca),a152_0x44dc78(0xc0),'Max',a152_0x44dc78(0xc3),'First',a152_0x44dc78(0xb3)]);const TemporalValueSchema=z['union']([z[a152_0x44dc78(0xbd)]({'timestamp':z[a152_0x44dc78(0xdf)]()}),z[a152_0x44dc78(0xbd)]({'last':z['union']([z['number'](),z[a152_0x44dc78(0xdb)](z['string'](),z['number']())]),'unit':z[a152_0x44dc78(0xdf)]()})]),OperatorValueSchema=z[a152_0x44dc78(0xd3)]([z[a152_0x44dc78(0xdf)](),z[a152_0x44dc78(0xa4)](),z['boolean'](),TemporalValueSchema,z['array'](z[a152_0x44dc78(0xd3)]([z[a152_0x44dc78(0xdf)](),z[a152_0x44dc78(0xa4)](),z[a152_0x44dc78(0xac)]()]))]),OPERATORS_REQUIRING_VALUE=new Set([a152_0x44dc78(0xe1),a152_0x44dc78(0xcf),'GreaterEqual',a152_0x44dc78(0xc8),a152_0x44dc78(0xb9),'In','Contain',a152_0x44dc78(0xc2),a152_0x44dc78(0xd5),a152_0x44dc78(0xa1),a152_0x44dc78(0xda),a152_0x44dc78(0xad)]),OPERATORS_REQUIRING_UNIT=new Set(['TimeWithinPast',a152_0x44dc78(0xad)]);export const OperatorDefSchema=z[a152_0x44dc78(0xbd)]({'type':OperatorTypeSchema,'not':z[a152_0x44dc78(0xac)]()[a152_0x44dc78(0xdd)](),'value':OperatorValueSchema['optional'](),'min':z[a152_0x44dc78(0xd3)]([z[a152_0x44dc78(0xa4)](),z['string'](),TemporalValueSchema])[a152_0x44dc78(0xdd)](),'max':z['union']([z[a152_0x44dc78(0xa4)](),z['string'](),TemporalValueSchema])['optional'](),'unit':TimeUnitSchema['optional'](),'duration':z['object']({'day':z['number']()[a152_0x44dc78(0xdd)](),'week':z[a152_0x44dc78(0xa4)]()[a152_0x44dc78(0xdd)](),'month':z['number']()[a152_0x44dc78(0xdd)](),'year':z[a152_0x44dc78(0xa4)]()[a152_0x44dc78(0xdd)](),'hour':z[a152_0x44dc78(0xa4)]()[a152_0x44dc78(0xdd)](),'minute':z['number']()[a152_0x44dc78(0xdd)](),'second':z[a152_0x44dc78(0xa4)]()[a152_0x44dc78(0xdd)]()})[a152_0x44dc78(0xdd)](),'from':z[a152_0x44dc78(0xbd)]({'last':z[a152_0x44dc78(0xd3)]([z[a152_0x44dc78(0xa4)](),z[a152_0x44dc78(0xdf)]()]),'unit':TimeUnitSchema})[a152_0x44dc78(0xdd)](),'reverse':z[a152_0x44dc78(0xac)]()['optional']()})[a152_0x44dc78(0xd2)]((_0x1df6b0,_0x3fdc78)=>{const _0x1350d9=a152_0x44dc78;OPERATORS_REQUIRING_VALUE[_0x1350d9(0xc4)](_0x1df6b0[_0x1350d9(0xaa)])&&(_0x1df6b0['value']===undefined||_0x1df6b0[_0x1350d9(0x98)]===null)&&_0x3fdc78[_0x1350d9(0xb1)]({'code':'custom','message':_0x1350d9(0xa6)+_0x1df6b0['type']+'\x27\x20requires\x20a\x20value','path':[_0x1350d9(0x98)]}),_0x1df6b0[_0x1350d9(0xaa)]==='Between'&&_0x1df6b0['min']===undefined&&_0x1df6b0['max']===undefined&&_0x3fdc78[_0x1350d9(0xb1)]({'code':_0x1350d9(0xbb),'message':'Between\x20operator\x20requires\x20\x27min\x27\x20and/or\x20\x27max\x27\x20values','params':{'validationCode':_0x1350d9(0xb5)}}),OPERATORS_REQUIRING_UNIT[_0x1350d9(0xc4)](_0x1df6b0[_0x1350d9(0xaa)])&&_0x1df6b0[_0x1350d9(0x98)]!==undefined&&!_0x1df6b0[_0x1350d9(0xce)]&&_0x3fdc78[_0x1350d9(0xb1)]({'code':'custom','message':'Operator\x20\x27'+_0x1df6b0['type']+_0x1350d9(0x99),'path':['unit'],'params':{'validationCode':'MISSING_TIME_UNIT'}}),_0x1df6b0[_0x1350d9(0xaa)]===_0x1350d9(0xe3)&&(!_0x1df6b0[_0x1350d9(0xbf)]&&_0x3fdc78[_0x1350d9(0xb1)]({'code':_0x1350d9(0xbb),'message':_0x1350d9(0x97),'path':['duration']}),!_0x1df6b0[_0x1350d9(0x9f)]&&_0x3fdc78[_0x1350d9(0xb1)]({'code':_0x1350d9(0xbb),'message':_0x1350d9(0xc5),'path':[_0x1350d9(0x9f)]}));});function a152_0x1803(_0x4766d1,_0xeed43f){_0x4766d1=_0x4766d1-0x97;const _0x107017=a152_0x1070();let _0x180384=_0x107017[_0x4766d1];return _0x180384;}export const ArrayMatchingSchema=z[a152_0x44dc78(0xd3)]([z[a152_0x44dc78(0xbc)](a152_0x44dc78(0xdc)),z[a152_0x44dc78(0xbc)](a152_0x44dc78(0xe0)),z[a152_0x44dc78(0xbd)]({'atLeast':z[a152_0x44dc78(0xa4)]()}),z[a152_0x44dc78(0xbd)]({'atMost':z[a152_0x44dc78(0xa4)]()}),z[a152_0x44dc78(0xbd)]({'exactly':z[a152_0x44dc78(0xa4)]()})]);export const AggregationDefSchema=z[a152_0x44dc78(0xa3)](a152_0x44dc78(0xaa),[z[a152_0x44dc78(0xbd)]({'type':z[a152_0x44dc78(0xb7)]([a152_0x44dc78(0x9d),a152_0x44dc78(0xc0),a152_0x44dc78(0xa0),a152_0x44dc78(0xca)]),'column':z[a152_0x44dc78(0xdf)](),'groupingColumns':z[a152_0x44dc78(0xd8)](z[a152_0x44dc78(0xdf)]())[a152_0x44dc78(0xdd)]()}),z[a152_0x44dc78(0xbd)]({'type':z[a152_0x44dc78(0xbc)](a152_0x44dc78(0x9a)),'groupingColumns':z[a152_0x44dc78(0xd8)](z[a152_0x44dc78(0xdf)]())[a152_0x44dc78(0xdd)]()}),z[a152_0x44dc78(0xbd)]({'type':z[a152_0x44dc78(0xbc)](a152_0x44dc78(0xc3)),'columns':z[a152_0x44dc78(0xd8)](z[a152_0x44dc78(0xdf)]())}),z['object']({'type':z['enum'](['First',a152_0x44dc78(0xb3)]),'column':z[a152_0x44dc78(0xdf)](),'orderColumn':z[a152_0x44dc78(0xdf)](),'groupingColumns':z[a152_0x44dc78(0xd8)](z[a152_0x44dc78(0xdf)]())['optional']()})]);export const TimeWindowDefSchema=z[a152_0x44dc78(0xbd)]({'duration':z[a152_0x44dc78(0xa4)](),'unit':TimeUnitSchema});const TIMESTAMP_OPERATORS=new Set([a152_0x44dc78(0xda),'TimeWithinNext','TimeRange']);export const FilterColumnConditionDefSchema=z['object']({'type':z[a152_0x44dc78(0xbc)](a152_0x44dc78(0xcc)),'column':z[a152_0x44dc78(0xdf)](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema[a152_0x44dc78(0xdd)]()})[a152_0x44dc78(0xd2)]((_0x36a5b1,_0x4b6eab)=>{const _0x5bef5f=a152_0x44dc78,_0x1922e7=_0x36a5b1['operator'][_0x5bef5f(0xaa)];_0x36a5b1[_0x5bef5f(0xa7)]==='timestamp'?!TIMESTAMP_OPERATORS[_0x5bef5f(0xc4)](_0x1922e7)&&_0x4b6eab[_0x5bef5f(0xb1)]({'code':_0x5bef5f(0xbb),'message':'Timestamp\x20column\x20only\x20supports\x20TimeWithinPast,\x20TimeWithinNext,\x20or\x20TimeRange\x20operators\x20(got\x20\x27'+_0x1922e7+'\x27)','path':[_0x5bef5f(0xae),_0x5bef5f(0xaa)]}):TIMESTAMP_OPERATORS[_0x5bef5f(0xc4)](_0x1922e7)&&_0x4b6eab[_0x5bef5f(0xb1)]({'code':_0x5bef5f(0xbb),'message':_0x5bef5f(0xa6)+_0x1922e7+_0x5bef5f(0xba),'path':[_0x5bef5f(0xae),_0x5bef5f(0xaa)]});});export const FilterRuleDefSchema=z[a152_0x44dc78(0xbd)]({'type':z['literal'](a152_0x44dc78(0xb4)),'conditions':z['array'](FilterColumnConditionDefSchema)});export const ValueConditionDefSchema=z['lazy'](()=>z[a152_0x44dc78(0xbd)]({'type':z[a152_0x44dc78(0xbc)](a152_0x44dc78(0xbe)),'attribute':z['string'](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema[a152_0x44dc78(0xdd)](),'exclude':z['boolean']()[a152_0x44dc78(0xdd)](),'aggregation':AggregationDefSchema[a152_0x44dc78(0xdd)](),'source':z[a152_0x44dc78(0xdf)]()[a152_0x44dc78(0xdd)](),'filter':FilterRuleDefSchema[a152_0x44dc78(0xdd)](),'limit':z['number']()[a152_0x44dc78(0xdd)]()}));export const BehaviorConditionDefSchema=z[a152_0x44dc78(0xd4)](()=>z[a152_0x44dc78(0xbd)]({'type':z[a152_0x44dc78(0xbc)](a152_0x44dc78(0xcb)),'attribute':z['string'](),'operator':OperatorDefSchema,'arrayMatching':ArrayMatchingSchema[a152_0x44dc78(0xdd)](),'exclude':z[a152_0x44dc78(0xac)]()[a152_0x44dc78(0xdd)](),'aggregation':AggregationDefSchema[a152_0x44dc78(0xdd)](),'source':z[a152_0x44dc78(0xdf)]()['optional'](),'filter':FilterRuleDefSchema[a152_0x44dc78(0xdd)](),'timeWindow':TimeWindowDefSchema[a152_0x44dc78(0xdd)](),'limit':z[a152_0x44dc78(0xa4)]()['optional']()}));export const ColumnConditionDefSchema=z[a152_0x44dc78(0xbd)]({'type':z[a152_0x44dc78(0xbc)](a152_0x44dc78(0xcc)),'column':z[a152_0x44dc78(0xdf)](),'operator':OperatorDefSchema});export const CompositeConditionDefSchema=z['lazy'](()=>z[a152_0x44dc78(0xbd)]({'type':z[a152_0x44dc78(0xb7)]([a152_0x44dc78(0xb4),'Or']),'conditions':z[a152_0x44dc78(0xd8)](ConditionDefSchema),'description':z[a152_0x44dc78(0xdf)]()[a152_0x44dc78(0xdd)]()}));export const SegmentRefConditionDefSchema=z[a152_0x44dc78(0xbd)]({'type':z[a152_0x44dc78(0xb7)](['include','exclude']),'segment':z[a152_0x44dc78(0xdf)]()[a152_0x44dc78(0x9b)](0x1,a152_0x44dc78(0xd0))});export const ConditionDefSchema=z[a152_0x44dc78(0xd4)](()=>z[a152_0x44dc78(0xd3)]([ValueConditionDefSchema,BehaviorConditionDefSchema,ColumnConditionDefSchema,CompositeConditionDefSchema,SegmentRefConditionDefSchema]));export const RuleDefSchema=z[a152_0x44dc78(0xd4)](()=>z[a152_0x44dc78(0xbd)]({'type':z[a152_0x44dc78(0xb7)]([a152_0x44dc78(0xb4),'Or']),'conditions':z['array'](ConditionDefSchema),'description':z[a152_0x44dc78(0xdf)]()[a152_0x44dc78(0xdd)]()}));export const SegmentDefSchema=z[a152_0x44dc78(0xbd)]({'type':z[a152_0x44dc78(0xbc)]('segment')[a152_0x44dc78(0xdd)](),'name':z[a152_0x44dc78(0xdf)]()['min'](0x1,a152_0x44dc78(0xb8)),'description':z['string']()[a152_0x44dc78(0xdd)](),'folder':z[a152_0x44dc78(0xdf)]()[a152_0x44dc78(0xdd)](),'rule':RuleDefSchema[a152_0x44dc78(0xdd)](),'kind':z[a152_0x44dc78(0xb7)]([a152_0x44dc78(0xc9),a152_0x44dc78(0x9c),a152_0x44dc78(0xd9)])[a152_0x44dc78(0xdd)](),'visible':z[a152_0x44dc78(0xac)]()[a152_0x44dc78(0xdd)](),'activations':z[a152_0x44dc78(0xd8)](z[a152_0x44dc78(0xdc)]())[a152_0x44dc78(0xdd)]()});const _syncCheck1=!![],_syncCheck2=!![];void _syncCheck1,void _syncCheck2;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a153_0x3f04b2=a153_0x4a15;(function(_0xb1eef8,_0x121094){const _0x368240=a153_0x4a15,_0x4a67c6=_0xb1eef8();while(!![]){try{const _0x328579=-parseInt(_0x368240(0x1cf))/0x1*(-parseInt(_0x368240(0x1db))/0x2)+-parseInt(_0x368240(0x1d1))/0x3+parseInt(_0x368240(0x1d3))/0x4*(parseInt(_0x368240(0x1c4))/0x5)+parseInt(_0x368240(0x1d9))/0x6*(parseInt(_0x368240(0x1cd))/0x7)+-parseInt(_0x368240(0x1e0))/0x8*(parseInt(_0x368240(0x1c3))/0x9)+parseInt(_0x368240(0x1c7))/0xa+-parseInt(_0x368240(0x1d5))/0xb;if(_0x328579===_0x121094)break;else _0x4a67c6['push'](_0x4a67c6['shift']());}catch(_0x3d670a){_0x4a67c6['push'](_0x4a67c6['shift']());}}}(a153_0x1ed0,0xb68b5));function a153_0x4a15(_0x337a50,_0x110df6){_0x337a50=_0x337a50-0x1c2;const _0x1ed076=a153_0x1ed0();let _0x4a1517=_0x1ed076[_0x337a50];return _0x4a1517;}import{readFileSync}from'fs';import*as a153_0x5e65ce from'path';import*as a153_0x195645 from'yaml';function a153_0x1ed0(){const _0x184092=['filterType','email','utf-8','500160KUOZbU','basename','type','parseDocument','180dINGQX','135GduFUm','push','message','5399710khzONr','object','warnings','campaign_type','campaign','result','49lzCgnL','journey','14oEEobH','relative','2846181UtNJRe','map','106416iVKLCA','valid','3326070SAeACC','YAML\x20parse\x20error:\x20','template','toJSON','1113126kwlUkq','skipped','98896KdBQRd','YAML_PARSE_ERROR'];a153_0x1ed0=function(){return _0x184092;};return a153_0x1ed0();}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([a153_0x3f04b2(0x1de),a153_0x3f04b2(0x1c5)]);export function isJourneyDef(_0x13eae7){const _0x3fa0bc=a153_0x3f04b2;return typeof _0x13eae7===_0x3fa0bc(0x1c8)&&_0x13eae7!==null&&_0x3fa0bc(0x1e2)in _0x13eae7&&_0x13eae7['type']===_0x3fa0bc(0x1ce);}export function isCampaignDef(_0x342a34){const _0x5c8b87=a153_0x3f04b2;if(typeof _0x342a34!==_0x5c8b87(0x1c8)||_0x342a34===null)return![];const _0x159fde=_0x342a34,_0x5059ae=VALID_CAMPAIGN_TYPES['has'](_0x159fde[_0x5c8b87(0x1ca)]);if(_0x159fde[_0x5c8b87(0x1e2)]===_0x5c8b87(0x1cb)&&_0x5059ae)return!![];if(_0x5059ae&&!_0x159fde['type'])return!![];return![];}export function isTemplateDef(_0x34503a){const _0x494751=a153_0x3f04b2;return typeof _0x34503a===_0x494751(0x1c8)&&_0x34503a!==null&&_0x494751(0x1e2)in _0x34503a&&_0x34503a[_0x494751(0x1e2)]===_0x494751(0x1d7);}export function isValidationResult(_0x227258){const _0x128997=a153_0x3f04b2;return!(_0x128997(0x1da)in _0x227258);}export function createParseErrorResult(_0x49bed5,_0x9cb78f,_0x2ee889,_0x2103c1,_0x502ba1='segment'){const _0x1d00ef=a153_0x3f04b2;return{'filePath':_0x49bed5,'relativePath':_0x9cb78f,'source':_0x2ee889,'result':{'valid':![],'errors':[{'level':'error','path':'','code':_0x1d00ef(0x1dc),'message':_0x2103c1}],'warnings':[]},'fileType':_0x502ba1};}export function validateYamlFile(_0x500a6f,_0xcbe5e9,_0x322cbf={}){const _0xd4d629=a153_0x3f04b2,_0x13e838=a153_0x5e65ce[_0xd4d629(0x1d0)](_0xcbe5e9,_0x500a6f)||a153_0x5e65ce[_0xd4d629(0x1e1)](_0x500a6f);try{const _0x1ca0c2=readFileSync(_0x500a6f,_0xd4d629(0x1df)),_0x51e264=a153_0x195645[_0xd4d629(0x1c2)](_0x1ca0c2),_0xe6de20=_0x51e264[_0xd4d629(0x1d8)]();if(!_0xe6de20)return createParseErrorResult(_0x500a6f,_0x13e838,_0x1ca0c2,'Failed\x20to\x20parse\x20YAML\x20file\x20(empty\x20or\x20invalid)');let _0x43c5f3;if(isJourneyDef(_0xe6de20))_0x43c5f3='journey';else{if(isCampaignDef(_0xe6de20))_0x43c5f3=_0xd4d629(0x1cb);else isTemplateDef(_0xe6de20)?_0x43c5f3=_0xd4d629(0x1d7):_0x43c5f3='segment';}if(_0x322cbf['filterType']&&_0x43c5f3!==_0x322cbf[_0xd4d629(0x1dd)])return{'filePath':_0x500a6f,'relativePath':_0x13e838,'skipped':!![],'reason':'not\x20a\x20'+_0x322cbf[_0xd4d629(0x1dd)]};const _0x1aff30={'source':_0x1ca0c2,'document':_0x51e264};let _0x262741;if(_0x43c5f3===_0xd4d629(0x1ce))_0x262741=validateJourneyDef(_0xe6de20,_0x1aff30);else{if(_0x43c5f3===_0xd4d629(0x1cb))_0x262741=validateCampaignDef(_0xe6de20,_0x1aff30);else _0x43c5f3===_0xd4d629(0x1d7)?_0x262741=validateTemplateDef(_0xe6de20,_0x1aff30):_0x262741=validateSegmentDef(_0xe6de20,_0x1aff30);}return{'filePath':_0x500a6f,'relativePath':_0x13e838,'source':_0x1ca0c2,'result':_0x262741,'fileType':_0x43c5f3};}catch(_0x4f46c6){const _0x62e392=_0x4f46c6 instanceof Error?_0x4f46c6[_0xd4d629(0x1c6)]:String(_0x4f46c6);return createParseErrorResult(_0x500a6f,_0x13e838,'',_0xd4d629(0x1d6)+_0x62e392);}}export function validateYamlFiles(_0x2b90f5,_0x28c2f4,_0x7881c7={}){const _0x55ae98=a153_0x3f04b2;return _0x2b90f5[_0x55ae98(0x1d2)](_0x1a9691=>validateYamlFile(_0x1a9691,_0x28c2f4,_0x7881c7));}export function calculateSummary(_0x1748e3){const _0x533704=a153_0x3f04b2;let _0x462871=0x0,_0x3ce35d=0x0,_0x131d2b=0x0,_0x5d0cda=0x0;for(const _0x1521d9 of _0x1748e3){if(!isValidationResult(_0x1521d9)){_0x5d0cda++;continue;}_0x1521d9[_0x533704(0x1cc)][_0x533704(0x1d4)]?_0x462871++:_0x3ce35d++,_0x131d2b+=_0x1521d9['result'][_0x533704(0x1c9)]['length'];}return{'validCount':_0x462871,'invalidCount':_0x3ce35d,'warningCount':_0x131d2b,'skippedCount':_0x5d0cda,'hasErrors':_0x3ce35d>0x0};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x447a8e,_0x1e7bb1){const _0x11f51e=a154_0x1c89,_0x539126=_0x447a8e();while(!![]){try{const _0x2ae8cd=parseInt(_0x11f51e(0x1ff))/0x1+-parseInt(_0x11f51e(0x1ee))/0x2+parseInt(_0x11f51e(0x212))/0x3*(parseInt(_0x11f51e(0x207))/0x4)+parseInt(_0x11f51e(0x1eb))/0x5*(parseInt(_0x11f51e(0x1f6))/0x6)+parseInt(_0x11f51e(0x219))/0x7*(parseInt(_0x11f51e(0x210))/0x8)+-parseInt(_0x11f51e(0x215))/0x9*(-parseInt(_0x11f51e(0x202))/0xa)+-parseInt(_0x11f51e(0x1fe))/0xb;if(_0x2ae8cd===_0x1e7bb1)break;else _0x539126['push'](_0x539126['shift']());}catch(_0x31cc7a){_0x539126['push'](_0x539126['shift']());}}}(a154_0x5c65,0x868fc));import*as a154_0x2f5af1 from'yaml';import a154_0x4076b8 from'chalk';export{validateSegmentDef,validateRuleDef}from'./segment-validator.js';export function getLocationFromPath(_0x248d16,_0x145f92,_0xcc0795){const _0x259154=a154_0x1c89;if(!_0x248d16||!_0x145f92)return undefined;try{let _0x453af8=_0x248d16[_0x259154(0x1ef)](_0xcc0795,!![]),_0x5856f5=[..._0xcc0795];while((!_0x453af8||typeof _0x453af8!==_0x259154(0x1ea)||!(_0x259154(0x205)in _0x453af8)||!_0x453af8[_0x259154(0x205)])&&_0x5856f5[_0x259154(0x1fb)]>0x0){_0x5856f5[_0x259154(0x1f0)](),_0x453af8=_0x5856f5[_0x259154(0x1fb)]>0x0?_0x248d16[_0x259154(0x1ef)](_0x5856f5,!![]):_0x248d16[_0x259154(0x1f4)];}if(!_0x453af8||typeof _0x453af8!==_0x259154(0x1ea)||!(_0x259154(0x205)in _0x453af8)||!_0x453af8['range'])return undefined;const [_0x1eb0ed]=_0x453af8[_0x259154(0x205)];return offsetToLocation(_0x145f92,_0x1eb0ed);}catch{return undefined;}}export function offsetToLocation(_0x41d0b7,_0x3258d4){let _0x200e82=0x1,_0x86ee35=0x1;for(let _0x4ed029=0x0;_0x4ed029<_0x3258d4&&_0x4ed029<_0x41d0b7['length'];_0x4ed029++){_0x41d0b7[_0x4ed029]==='\x0a'?(_0x200e82++,_0x86ee35=0x1):_0x86ee35++;}return{'line':_0x200e82,'column':_0x86ee35,'offset':_0x3258d4};}export function pathToArray(_0xcb613a){const _0x3b2a21=a154_0x1c89;if(!_0xcb613a)return[];return _0xcb613a[_0x3b2a21(0x21a)]('.')[_0x3b2a21(0x21b)](_0x36cb8e=>{const _0x450a13=_0x3b2a21,_0x22fd45=_0x36cb8e[_0x450a13(0x20d)](/^(\w+)\[(\d+)\]$/);if(_0x22fd45)return[_0x22fd45[0x1],parseInt(_0x22fd45[0x2],0xa)];return[_0x36cb8e];});}export function formatZodPath(_0xe5141f){let _0x4661e6='';for(const _0x55dd74 of _0xe5141f){if(typeof _0x55dd74==='number')_0x4661e6+='['+_0x55dd74+']';else{const _0x5bba51=String(_0x55dd74);_0x4661e6+=_0x4661e6?'.'+_0x5bba51:_0x5bba51;}}return _0x4661e6;}function a154_0x1c89(_0x4d1269,_0x59430a){_0x4d1269=_0x4d1269-0x1ea;const _0x5c655e=a154_0x5c65();let _0x1c8993=_0x5c655e[_0x4d1269];return _0x1c8993;}export function flattenZodIssues(_0xe65342){const _0x1877c8=a154_0x1c89,_0x53f2b2=[];for(const _0x39006a of _0xe65342){if(_0x39006a[_0x1877c8(0x206)]===_0x1877c8(0x218)&&_0x1877c8(0x203)in _0x39006a){const _0x2cc096=_0x39006a['errors'];let _0x157dc9=_0x2cc096[0x0]||[];for(const _0x320adc of _0x2cc096){_0x320adc[_0x1877c8(0x1fb)]<_0x157dc9[_0x1877c8(0x1fb)]&&(_0x157dc9=_0x320adc);}const _0x2ab711=_0x157dc9[_0x1877c8(0x1fd)](_0x2f1f4e=>({..._0x2f1f4e,'path':[..._0x39006a[_0x1877c8(0x1ed)],..._0x2f1f4e[_0x1877c8(0x1ed)]]}));_0x53f2b2[_0x1877c8(0x208)](...flattenZodIssues(_0x2ab711));}else _0x53f2b2[_0x1877c8(0x208)](_0x39006a);}return _0x53f2b2;}export function safeParseYaml(_0x1fe8b7,_0x4a110f){const _0x26a3e1=a154_0x1c89,_0x9793d5=a154_0x2f5af1[_0x26a3e1(0x217)](_0x1fe8b7);if(!_0x9793d5||typeof _0x9793d5!==_0x26a3e1(0x1ea))throw new Error(_0x26a3e1(0x20e));const _0xca510c=_0x4a110f[_0x26a3e1(0x1ec)](_0x9793d5);if(!_0xca510c[_0x26a3e1(0x211)]){const _0xa12776=_0xca510c['error'][_0x26a3e1(0x213)][0x0],_0x4448f1=formatZodPath(_0xa12776['path']);throw new Error(_0x4448f1?'YAML\x20validation\x20error\x20at\x20\x27'+_0x4448f1+_0x26a3e1(0x216)+_0xa12776[_0x26a3e1(0x204)]:_0x26a3e1(0x209)+_0xa12776[_0x26a3e1(0x204)]);}return _0xca510c[_0x26a3e1(0x20f)];}export function formatIssueWithContext(_0x1fd77f,_0x2a341e,_0x416eae){const _0x2587c5=a154_0x1c89,_0x6b6aec=[],_0x2f613f=_0x1fd77f[_0x2587c5(0x20c)]===_0x2587c5(0x1f5),_0x449060=_0x2f613f?a154_0x4076b8[_0x2587c5(0x214)]:a154_0x4076b8[_0x2587c5(0x1fc)],_0x58b8c6=_0x2f613f?a154_0x4076b8[_0x2587c5(0x214)]:a154_0x4076b8[_0x2587c5(0x1fc)],_0x25a264=_0x416eae?a154_0x4076b8[_0x2587c5(0x200)](_0x416eae+':'):'';if(_0x1fd77f[_0x2587c5(0x1f8)]){const _0x3d4d06=a154_0x4076b8[_0x2587c5(0x200)](_0x1fd77f[_0x2587c5(0x1f8)][_0x2587c5(0x20b)]+':'+_0x1fd77f['location'][_0x2587c5(0x1fa)]);_0x6b6aec['push'](''+_0x25a264+_0x3d4d06+':\x20'+_0x449060(_0x1fd77f[_0x2587c5(0x20c)])+'\x20'+_0x58b8c6('['+_0x1fd77f['code']+']'));}else _0x6b6aec[_0x2587c5(0x208)](''+_0x25a264+a154_0x4076b8[_0x2587c5(0x1f1)](_0x1fd77f[_0x2587c5(0x1ed)])+':\x20'+_0x449060(_0x1fd77f[_0x2587c5(0x20c)])+'\x20'+_0x58b8c6('['+_0x1fd77f[_0x2587c5(0x206)]+']'));_0x6b6aec[_0x2587c5(0x208)](_0x1fd77f[_0x2587c5(0x204)]);if(_0x1fd77f[_0x2587c5(0x1f8)]&&_0x2a341e){const _0x34748b=_0x2a341e[_0x2587c5(0x21a)]('\x0a'),{line:_0x2b1486,column:_0x337a32}=_0x1fd77f[_0x2587c5(0x1f8)],_0x34fcfb=Math[_0x2587c5(0x20a)](0x1,_0x2b1486-0x1),_0x2c1450=Math['min'](_0x34748b[_0x2587c5(0x1fb)],_0x2b1486+0x1);_0x6b6aec[_0x2587c5(0x208)]('');for(let _0x26b562=_0x34fcfb;_0x26b562<=_0x2c1450;_0x26b562++){const _0x4e4350=_0x34748b[_0x26b562-0x1]||'',_0x24d094=a154_0x4076b8['dim'](_0x26b562[_0x2587c5(0x1f7)]()[_0x2587c5(0x1f3)](0x4)),_0x3f58f5=a154_0x4076b8['dim'](_0x2587c5(0x201));if(_0x26b562===_0x2b1486){_0x6b6aec[_0x2587c5(0x208)]('\x20\x20'+_0x24d094+_0x3f58f5+_0x449060(_0x4e4350));const _0x2a0094='\x20'['repeat'](0x4+0x3+_0x337a32-0x1);_0x6b6aec[_0x2587c5(0x208)]('\x20\x20'+_0x2a0094+_0x449060('^'));}else _0x6b6aec[_0x2587c5(0x208)]('\x20\x20'+_0x24d094+_0x3f58f5+a154_0x4076b8[_0x2587c5(0x1f1)](_0x4e4350));}}return _0x6b6aec[_0x2587c5(0x1f9)]('\x0a');}function a154_0x5c65(){const _0x477424=['\x27:\x20','parse','invalid_union','6038935IoZNWt','split','flatMap','object','231970UkOdIq','safeParse','path','2047422GSNDcz','getIn','pop','dim','warnings','padStart','contents','error','138ZjEMPo','toString','location','join','column','length','yellow','map','27750778CViGhX','819676tQUabR','cyan','\x20|\x20','323310mbDxOK','errors','message','range','code','68UNTIVB','push','YAML\x20validation\x20error:\x20','max','line','level','match','Invalid\x20YAML:\x20expected\x20an\x20object','data','8OMQNoV','success','129519DVZmcj','issues','red','171QsfYni'];a154_0x5c65=function(){return _0x477424;};return a154_0x5c65();}export function formatValidationResult(_0x385887,_0x42c18d,_0x47b633){const _0x36b991=a154_0x1c89,_0x779941=[];for(const _0x3e94ce of _0x385887[_0x36b991(0x203)]){_0x779941[_0x36b991(0x208)](formatIssueWithContext(_0x3e94ce,_0x42c18d,_0x47b633)),_0x779941['push']('');}for(const _0x1edfc8 of _0x385887[_0x36b991(0x1f2)]){_0x779941[_0x36b991(0x208)](formatIssueWithContext(_0x1edfc8,_0x42c18d,_0x47b633)),_0x779941[_0x36b991(0x208)]('');}return _0x779941[_0x36b991(0x1f9)]('\x0a');}
|