@treasuredata/tdx 0.16.0 → 0.16.1
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/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/describe.js +1 -1
- package/dist/commands/engage-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/llm-proxy.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/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/tables.js +1 -1
- package/dist/commands/unset-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/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/anthropic-adapter.js +1 -1
- package/dist/proxy/claude-usage-tracker.js +1 -1
- package/dist/proxy/context-signature.js +1 -1
- package/dist/proxy/conversation-utils.js +1 -1
- package/dist/proxy/passthrough-server.js +1 -1
- package/dist/proxy/server.js +1 -1
- package/dist/proxy/session-cache.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/api.js +1 -1
- package/dist/sdk/claude-agent/claude-agent-client.js +1 -1
- package/dist/sdk/claude-agent/environment.js +1 -1
- package/dist/sdk/claude-agent/index.js +1 -1
- package/dist/sdk/claude-agent/system-prompts.js +1 -1
- package/dist/sdk/client/cdp-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/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/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-aliases.js +1 -1
- package/dist/sdk/llm/model-factors.js +1 -1
- package/dist/sdk/query/index.js +1 -1
- package/dist/sdk/query/sql-parser.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-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-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/target-resolution.js +1 -1
- package/dist/sdk/segment/tdx-config.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/tree-formatter.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/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/json-loader.js +1 -1
- package/dist/utils/option-validation.js +1 -1
- package/dist/utils/port.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
|
-
const a111_0x28abc7=a111_0x146b;(function(_0xf8d7ef,_0x3d2c5f){const _0x101cf9=a111_0x146b,_0x18f994=_0xf8d7ef();while(!![]){try{const _0x425fbd=parseInt(_0x101cf9(0x9e))/0x1*(parseInt(_0x101cf9(0x108))/0x2)+-parseInt(_0x101cf9(0x105))/0x3*(-parseInt(_0x101cf9(0xd8))/0x4)+parseInt(_0x101cf9(0xa3))/0x5+parseInt(_0x101cf9(0xb9))/0x6+parseInt(_0x101cf9(0xc2))/0x7*(parseInt(_0x101cf9(0x9d))/0x8)+parseInt(_0x101cf9(0xd9))/0x9+parseInt(_0x101cf9(0xc6))/0xa*(-parseInt(_0x101cf9(0xd5))/0xb);if(_0x425fbd===_0x3d2c5f)break;else _0x18f994['push'](_0x18f994['shift']());}catch(_0xb3ad37){_0x18f994['push'](_0x18f994['shift']());}}}(a111_0x5646,0xaccaf));import*as a111_0xe7d623 from'yaml';import{SDKError,ErrorCode}from'../errors.js';import{validateConnectorConfig,transformConfigToLegacy,normalizeConnectorConfigForYaml,formatValidationErrors,formatValidationWarnings,formatSchemaAsHelp}from'../connection-validator.js';export function segmentResponseToDefSync(_0x330f15,_0x24c0b7){const _0x2729dd=a111_0x146b,_0x95cee8=_0x330f15[_0x2729dd(0xad)]&&'type'in _0x330f15['rule']&&_0x330f15['rule'][_0x2729dd(0xfe)];return{'type':_0x2729dd(0xfc),'name':_0x330f15['name'],..._0x330f15[_0x2729dd(0x98)]&&{'description':_0x330f15[_0x2729dd(0x98)]},..._0x24c0b7&&{'folder':_0x24c0b7},..._0x95cee8&&{'rule':apiRuleToYaml(_0x330f15[_0x2729dd(0xad)])},..._0x330f15[_0x2729dd(0xdd)]!==undefined&&{'kind':_0x330f15[_0x2729dd(0xdd)]===0x0?_0x2729dd(0xe1):_0x330f15['kind']===0x1?_0x2729dd(0xc5):_0x2729dd(0xec)},..._0x330f15[_0x2729dd(0xcd)]!==undefined&&{'visible':_0x330f15['isVisible']}};}export async function segmentResponseToDef(_0x4c7d38,_0x19521d,_0x1928cb){const _0x31a56e=a111_0x146b,_0x2db2ca=segmentResponseToDefSync(_0x4c7d38,_0x1928cb);if(!_0x19521d||!_0x19521d[_0x31a56e(0xff)])return _0x2db2ca;return _0x2db2ca[_0x31a56e(0xad)]&&(_0x2db2ca[_0x31a56e(0xad)]=await resolveRuleSegmentRefs(_0x2db2ca[_0x31a56e(0xad)],_0x19521d[_0x31a56e(0xff)])),_0x2db2ca;}export function apiRuleToYaml(_0x4a75fd){const _0x4cddb6=a111_0x146b,_0x4e35e9=(_0x4a75fd[_0x4cddb6(0xd6)]||[])[_0x4cddb6(0x119)](apiConditionToYaml);if(_0x4e35e9[_0x4cddb6(0x97)]===0x1&&!_0x4a75fd[_0x4cddb6(0x98)]&&'type'in _0x4e35e9[0x0]&&(_0x4e35e9[0x0]['type']===_0x4cddb6(0xa4)||_0x4e35e9[0x0][_0x4cddb6(0xfe)]==='Or')){const _0x16e52d=_0x4e35e9[0x0];if(_0x16e52d[_0x4cddb6(0xfe)]===_0x4a75fd[_0x4cddb6(0xfe)]&&_0x16e52d[_0x4cddb6(0xd6)])return{'type':_0x4a75fd['type'],'conditions':_0x16e52d[_0x4cddb6(0xd6)],..._0x16e52d[_0x4cddb6(0x98)]&&{'description':_0x16e52d[_0x4cddb6(0x98)]}};}return{'type':_0x4a75fd[_0x4cddb6(0xfe)],'conditions':_0x4e35e9,..._0x4a75fd['description']&&{'description':_0x4a75fd[_0x4cddb6(0x98)]}};}export async function resolveRuleSegmentRefs(_0x5846ee,_0x4f2905){const _0x500fee=a111_0x146b,_0x12646d=await Promise[_0x500fee(0xfd)](_0x5846ee[_0x500fee(0xd6)]['map'](_0x22798a=>resolveConditionSegmentRefs(_0x22798a,_0x4f2905)));return{..._0x5846ee,'conditions':_0x12646d};}async function resolveConditionSegmentRefs(_0x35f06,_0x58842b){const _0x2f775d=a111_0x146b;if(_0x2f775d(0xfc)in _0x35f06&&(_0x35f06[_0x2f775d(0xfe)]===_0x2f775d(0x10a)||_0x35f06['type']===_0x2f775d(0x91))){const _0x4e173c=_0x35f06;if(/^\d+$/[_0x2f775d(0x99)](_0x4e173c[_0x2f775d(0xfc)])){const _0x2ce14f=await _0x58842b(_0x4e173c[_0x2f775d(0xfc)]);return{..._0x4e173c,'segment':_0x2ce14f};}return _0x35f06;}if(_0x2f775d(0xd6)in _0x35f06&&_0x35f06[_0x2f775d(0xd6)]){const _0x106eeb=_0x35f06,_0x28cc16=await Promise[_0x2f775d(0xfd)](_0x106eeb[_0x2f775d(0xd6)][_0x2f775d(0x119)](_0x35e314=>resolveConditionSegmentRefs(_0x35e314,_0x58842b)));return{..._0x106eeb,'conditions':_0x28cc16};}if(_0x2f775d(0x90)in _0x35f06&&_0x35f06['filter']){const _0x268bab=_0x35f06,_0xa0d847=await resolveRuleSegmentRefs(_0x268bab['filter'],_0x58842b);return{..._0x268bab,'filter':_0xa0d847};}return _0x35f06;}export async function resolveRuleSegmentIds(_0x385bb0,_0x180441){const _0x153cce=a111_0x146b,_0x475a99=await Promise[_0x153cce(0xfd)](_0x385bb0[_0x153cce(0xd6)][_0x153cce(0x119)](_0x5a811a=>resolveConditionSegmentIds(_0x5a811a,_0x180441)));return{..._0x385bb0,'conditions':_0x475a99};}async function resolveConditionSegmentIds(_0x4b02c0,_0xcd75f7){const _0x2b0768=a111_0x146b;if(_0x2b0768(0xfc)in _0x4b02c0&&(_0x4b02c0['type']===_0x2b0768(0x10a)||_0x4b02c0[_0x2b0768(0xfe)]===_0x2b0768(0x91))){const _0x4a54f2=_0x4b02c0;if(!/^\d+$/[_0x2b0768(0x99)](_0x4a54f2[_0x2b0768(0xfc)])){const _0x5734f0=await _0xcd75f7(_0x4a54f2[_0x2b0768(0xfc)]);return{..._0x4a54f2,'segment':_0x5734f0};}return _0x4b02c0;}if(_0x2b0768(0xd6)in _0x4b02c0&&_0x4b02c0[_0x2b0768(0xd6)]){const _0xe2c6b4=_0x4b02c0,_0xca0829=await Promise['all'](_0xe2c6b4[_0x2b0768(0xd6)][_0x2b0768(0x119)](_0x13da2d=>resolveConditionSegmentIds(_0x13da2d,_0xcd75f7)));return{..._0xe2c6b4,'conditions':_0xca0829};}if(_0x2b0768(0x90)in _0x4b02c0&&_0x4b02c0['filter']){const _0x54ff7d=_0x4b02c0,_0x2dd1f9=await resolveRuleSegmentIds(_0x54ff7d['filter'],_0xcd75f7);return{..._0x54ff7d,'filter':_0x2dd1f9};}return _0x4b02c0;}function apiConditionToYaml(_0x22f0d1){const _0xe39f6f=a111_0x146b;if(_0x22f0d1[_0xe39f6f(0xfe)]===_0xe39f6f(0xa4)||_0x22f0d1['type']==='Or'){if(_0x22f0d1[_0xe39f6f(0xd6)]){const _0x5163ef=_0x22f0d1[_0xe39f6f(0xd6)]['map'](apiConditionToYaml);if(_0x5163ef[_0xe39f6f(0x97)]===0x1&&!_0x22f0d1[_0xe39f6f(0x98)])return _0x5163ef[0x0];return{'type':_0x22f0d1[_0xe39f6f(0xfe)],'conditions':_0x5163ef,..._0x22f0d1['description']&&{'description':_0x22f0d1[_0xe39f6f(0x98)]}};}}if(_0x22f0d1['type']===_0xe39f6f(0x8e)&&_0x22f0d1['leftValue']&&_0x22f0d1[_0xe39f6f(0xb3)]){const _0x500e0c=_0x22f0d1[_0xe39f6f(0x106)]['aggregation']?{'type':_0x22f0d1[_0xe39f6f(0x106)]['aggregation']['type'],..._0x22f0d1[_0xe39f6f(0x106)][_0xe39f6f(0xbf)][_0xe39f6f(0xc4)]&&{'groupingColumns':_0x22f0d1['leftValue']['aggregation'][_0xe39f6f(0xc4)]}}:undefined;return{'type':_0xe39f6f(0x8e),'attribute':_0x22f0d1[_0xe39f6f(0x106)][_0xe39f6f(0xdc)]||'','operator':apiOperatorToYaml(_0x22f0d1[_0xe39f6f(0xb3)]),..._0x22f0d1[_0xe39f6f(0xfa)]&&_0x22f0d1[_0xe39f6f(0xfa)]!==_0xe39f6f(0xaf)?{'arrayMatching':_0x22f0d1['arrayMatching']}:{},..._0x22f0d1[_0xe39f6f(0x91)]?{'exclude':_0x22f0d1[_0xe39f6f(0x91)]}:{},..._0x500e0c?{'aggregation':_0x500e0c}:{},..._0x22f0d1[_0xe39f6f(0x106)]['source']?{'source':_0x22f0d1['leftValue'][_0xe39f6f(0xe6)][_0xe39f6f(0xdc)]}:{},..._0x22f0d1[_0xe39f6f(0x106)][_0xe39f6f(0x90)]?{'filter':apiRuleToYaml(_0x22f0d1[_0xe39f6f(0x106)][_0xe39f6f(0x90)])}:{},..._0x22f0d1['limit']!==undefined&&_0x22f0d1[_0xe39f6f(0xe9)]!==null?{'limit':_0x22f0d1[_0xe39f6f(0xe9)]}:{}};}if(_0x22f0d1[_0xe39f6f(0xfe)]===_0xe39f6f(0xb1)&&_0x22f0d1['id'])return{'type':_0x22f0d1[_0xe39f6f(0x91)]?_0xe39f6f(0x91):_0xe39f6f(0x10a),'segment':_0x22f0d1['id']};return{'type':'And','conditions':[]};}function a111_0x5646(){const _0x1694f4=['has','operator','Segment\x20description','from','keys','unit','__UNRESOLVED__','2996298TFGXQS','valid','warn','string','connector_config','behavior_table','aggregation','values','Equal','5559225NWYraE','push','groupingColumns','realtime','186970JqYixP','Invalid\x20condition\x20in\x20embedded\x20segment\x20\x27','repeatUnit','repeatSubFrequency','columns','emailRecipients','order_by','isVisible','activations','visible','repeat_sub_frequency','connection','behavior','\x22:\x0a','forEach','1507WCFBWH','conditions','parse','1212020WrviTi','340272FsPiSZ','\x0a\x0aAvailable\x20fields:\x0a','toLowerCase','name','kind','end_on','add','rightValue','batch','activation_template_id','joinRow','stringify','object','source','isArray','rule:','limit','connectionNameToTypeMap','activationTemplateId','funnel_stage','endOn','duration','get','emailToIdMap','every','connectionNameToIdMap','folder','repeat_unit','syndicationBehavior','notify_on','connectionId','start_at','errors','arrayMatching','].attribute\x20cannot\x20be\x20empty.\x0a','segment','all','type','resolveSegmentName','min','Connector:\x20','visibility','value','ruleHashToName','3ShWCGu','leftValue','Unknown\x20connection:\x20','1381454mKxaLu','set','include','notifyOn','schedule','Invalid\x20connector_config\x20for\x20activation\x20\x22','usedNames','null','CONNECTOR_INVALID_CONFIG','orderBy','formatting','startAt','\x27:\x20','connectorConfig','JOURNEY_SYNTAX_ERROR','behaviorTableName','CONNECTOR_SCHEMA_NOT_FOUND','map','timezone','rightValues','__SEGMENT_REF__','Use\x20\x27tdx\x20connections\x27\x20to\x20list\x20available\x20connections','Value','warnings','filter','exclude','not','Please\x20specify\x20a\x20valid\x20attribute\x20name.','getSchema','allColumns','localRuleToName','length','description','test','all_columns','join_row','scheduleType','8KhOpua','2ycFKbt','notification','repeatFrequency','activations:','Unknown\x20email\x20recipient:\x20','1267115waWacs','And','join_strategy','max','replace','New\x20Segment','.\x20Use\x20\x27tdx\x20user\x20list\x27\x20to\x20see\x20valid\x20emails.','sort','email_recipients','activationParams','rule','joinStrategy','any','repeat_frequency','Reference'];a111_0x5646=function(){return _0x1694f4;};return a111_0x5646();}function isTemporalOperator(_0x21d3af){return _0x21d3af==='TimeWithinPast'||_0x21d3af==='TimeWithinNext';}function getEffectiveValue(_0x34ccff){const _0x221d08=a111_0x146b,_0x4a895b=_0x34ccff[_0x221d08(0xc0)];return _0x34ccff['value']??_0x4a895b;}function apiOperatorToYaml(_0x4955b9){const _0x177353=a111_0x146b;let _0x373c61;if(_0x4955b9[_0x177353(0x11b)]&&_0x4955b9[_0x177353(0x11b)][_0x177353(0x97)]>0x0)_0x373c61=_0x4955b9[_0x177353(0x11b)];else{if(_0x4955b9[_0x177353(0xe0)]!==undefined)_0x373c61=_0x4955b9[_0x177353(0xe0)];else isTemporalOperator(_0x4955b9[_0x177353(0xfe)])&&_0x4955b9[_0x177353(0x103)]!==undefined&&(_0x373c61=_0x4955b9[_0x177353(0x103)]);}return{'type':mapApiOperatorType(_0x4955b9[_0x177353(0xfe)]),..._0x4955b9[_0x177353(0x92)]&&{'not':_0x4955b9[_0x177353(0x92)]},..._0x373c61!==undefined&&{'value':_0x373c61},..._0x4955b9[_0x177353(0xb7)]&&{'unit':_0x4955b9[_0x177353(0xb7)]}};}function mapApiOperatorType(_0x30c64e){return _0x30c64e;}function a111_0x146b(_0x5ac96f,_0x37bcdb){_0x5ac96f=_0x5ac96f-0x8d;const _0x564606=a111_0x5646();let _0x146b23=_0x564606[_0x5ac96f];return _0x146b23;}export function segmentDefToCreateRequest(_0x83a4d9,_0x31dc7e){const _0x126a7e=a111_0x146b,_0x5dbbe5={'name':_0x83a4d9[_0x126a7e(0xdc)]};return _0x83a4d9[_0x126a7e(0x98)]&&(_0x5dbbe5['description']=_0x83a4d9[_0x126a7e(0x98)]),_0x83a4d9['rule']&&(_0x5dbbe5[_0x126a7e(0xad)]=yamlRuleToApi(_0x83a4d9[_0x126a7e(0xad)])),_0x83a4d9['kind']&&(_0x5dbbe5[_0x126a7e(0xdd)]=_0x83a4d9[_0x126a7e(0xdd)]==='batch'?0x0:_0x83a4d9[_0x126a7e(0xdd)]==='realtime'?0x1:0x2),_0x83a4d9[_0x126a7e(0xcf)]!==undefined&&(_0x5dbbe5[_0x126a7e(0xcd)]=_0x83a4d9[_0x126a7e(0xcf)]),_0x31dc7e&&(_0x5dbbe5['segmentFolderId']=_0x31dc7e),_0x5dbbe5;}export function segmentDefToUpdateRequest(_0x17c0e1){const _0x39a4bc=a111_0x146b,_0x318168={'name':_0x17c0e1[_0x39a4bc(0xdc)]};return _0x17c0e1[_0x39a4bc(0x98)]!==undefined&&(_0x318168['description']=_0x17c0e1[_0x39a4bc(0x98)]),_0x17c0e1[_0x39a4bc(0xad)]&&(_0x318168[_0x39a4bc(0xad)]=yamlRuleToApi(_0x17c0e1['rule'])),_0x17c0e1[_0x39a4bc(0xdd)]&&(_0x318168[_0x39a4bc(0xdd)]=_0x17c0e1[_0x39a4bc(0xdd)]===_0x39a4bc(0xe1)?0x0:_0x17c0e1[_0x39a4bc(0xdd)]===_0x39a4bc(0xc5)?0x1:0x2),_0x318168;}export function yamlRuleToApi(_0x3dfcd3,_0x8de8da=![]){const _0x17153a=a111_0x146b,_0x16644d=_0x3dfcd3[_0x17153a(0xd6)][_0x17153a(0x119)](yamlConditionToApi);if(_0x8de8da){const _0x15c96d=_0x16644d[_0x17153a(0xf1)](_0x1865fe=>_0x1865fe[_0x17153a(0xfe)]==='And'||_0x1865fe[_0x17153a(0xfe)]==='Or');if(!_0x15c96d&&_0x16644d['length']>0x0)return{'type':_0x3dfcd3[_0x17153a(0xfe)],'conditions':[{'type':_0x17153a(0xa4),'description':_0x3dfcd3[_0x17153a(0x98)]||'','conditions':_0x16644d}]};}return{'type':_0x3dfcd3[_0x17153a(0xfe)],'conditions':_0x16644d,..._0x3dfcd3[_0x17153a(0x98)]&&{'description':_0x3dfcd3['description']}};}function yamlConditionToApi(_0x1c9d2c){const _0x112511=a111_0x146b;if('segment'in _0x1c9d2c&&(_0x1c9d2c[_0x112511(0xfe)]===_0x112511(0x10a)||_0x1c9d2c[_0x112511(0xfe)]==='exclude')){const _0x24f860=_0x1c9d2c;return{'type':_0x112511(0xb1),'id':_0x24f860[_0x112511(0xfc)],'exclude':_0x24f860['type']===_0x112511(0x91)};}if(_0x112511(0xfe)in _0x1c9d2c&&(_0x1c9d2c[_0x112511(0xfe)]===_0x112511(0xa4)||_0x1c9d2c[_0x112511(0xfe)]==='Or')){const _0x16cc06=_0x1c9d2c;return{'type':_0x16cc06[_0x112511(0xfe)],'conditions':_0x16cc06[_0x112511(0xd6)]['map'](yamlConditionToApi),..._0x16cc06[_0x112511(0x98)]&&{'description':_0x16cc06[_0x112511(0x98)]}};}const _0x528e0e=_0x1c9d2c,_0x2f4736={'type':_0x112511(0x8e),'leftValue':buildLeftValue(_0x528e0e),'operator':yamlOperatorToApi(_0x528e0e[_0x112511(0xb3)]),'exclude':_0x528e0e[_0x112511(0x91)]??![],'arrayMatching':_0x528e0e[_0x112511(0xfa)]??_0x112511(0xaf)};return _0x528e0e[_0x112511(0xe9)]!==undefined&&(_0x2f4736[_0x112511(0xe9)]=_0x528e0e['limit']),_0x2f4736;}function buildLeftValue(_0x2805b1){const _0x3e602a=a111_0x146b,_0x293113={'name':_0x2805b1['attribute']};return _0x2805b1[_0x3e602a(0xbf)]&&(_0x293113['aggregation']={'type':_0x2805b1[_0x3e602a(0xbf)][_0x3e602a(0xfe)],..._0x2805b1[_0x3e602a(0xbf)][_0x3e602a(0xc4)]&&{'groupingColumns':_0x2805b1[_0x3e602a(0xbf)][_0x3e602a(0xc4)]}}),_0x2805b1[_0x3e602a(0xe6)]&&(_0x293113[_0x3e602a(0xe6)]={'name':_0x2805b1[_0x3e602a(0xe6)]}),_0x2805b1[_0x3e602a(0x90)]&&(_0x293113['filter']=yamlRuleToApi(_0x2805b1[_0x3e602a(0x90)])),_0x293113;}function yamlOperatorToApi(_0xe42d1d){const _0x5d0f9c=a111_0x146b,_0x3e0ba5={'type':mapYamlOperatorType(_0xe42d1d[_0x5d0f9c(0xfe)]),'not':_0xe42d1d[_0x5d0f9c(0x92)]??![]},_0x2b804f=getEffectiveValue(_0xe42d1d);if(_0x2b804f!==undefined){if(Array[_0x5d0f9c(0xe7)](_0x2b804f))_0x3e0ba5['rightValues']=_0x2b804f;else isTemporalOperator(_0xe42d1d[_0x5d0f9c(0xfe)])?_0x3e0ba5[_0x5d0f9c(0x103)]=_0x2b804f:_0x3e0ba5[_0x5d0f9c(0xe0)]=_0x2b804f;}return _0xe42d1d['unit']&&(_0x3e0ba5[_0x5d0f9c(0xb7)]=_0xe42d1d[_0x5d0f9c(0xb7)]),_0x3e0ba5;}function mapYamlOperatorType(_0x4f1370){return _0x4f1370;}export function toYamlString(_0x119c48){const _0x22613f=a111_0x146b,_0x44475d=JSON[_0x22613f(0xd7)](JSON['stringify'](_0x119c48)),_0x58c5b2=a111_0xe7d623[_0x22613f(0xe4)](_0x44475d,{'indent':0x2,'lineWidth':0x0,'nullStr':'null'}),_0x45f97f=[_0x22613f(0xe8)];let _0x2f765d=_0x58c5b2;for(const _0x973e46 of _0x45f97f){_0x2f765d=_0x2f765d[_0x22613f(0xa7)](new RegExp('^('+_0x973e46+')','m'),(_0x1f37e0,_0x264848,_0x3da6ec)=>{if(_0x3da6ec===0x0||_0x2f765d[_0x3da6ec-0x1]==='\x0a'&&_0x2f765d[_0x3da6ec-0x2]==='\x0a')return _0x264848;return'\x0a'+_0x264848;});}return _0x2f765d;}export function parseYamlString(_0x30a00d){const _0x4f4c51=a111_0x146b,_0x510ba7=a111_0xe7d623['parse'](_0x30a00d);if(!_0x510ba7[_0x4f4c51(0xdc)])throw new Error('YAML\x20config\x20missing\x20required\x20field:\x20name');if(_0x510ba7[_0x4f4c51(0xfe)]&&_0x510ba7[_0x4f4c51(0xfe)]!==_0x4f4c51(0xfc))throw new Error('YAML\x20type\x20must\x20be\x20\x27segment\x27\x20or\x20omitted,\x20got:\x20'+_0x510ba7['type']);return _0x510ba7;}export function isSegmentYaml(_0x226000){const _0x4a4cc0=a111_0x146b;if(typeof _0x226000!==_0x4a4cc0(0xe5)||_0x226000===null)return![];const _0x275c57=_0x226000;return _0x275c57[_0x4a4cc0(0xfe)]==='segment'||_0x275c57[_0x4a4cc0(0xfe)]===undefined;}export function generateTemplate(_0x12c9f5=a111_0x28abc7(0xa8)){const _0x5a1894=a111_0x28abc7,_0x357882={'type':_0x5a1894(0xfc),'name':_0x12c9f5,'description':_0x5a1894(0xb4),'rule':{'type':'And','conditions':[{'type':_0x5a1894(0x8e),'attribute':'attribute_name','operator':{'type':_0x5a1894(0xc1),'value':_0x5a1894(0x103)}}]}};return toYamlString(_0x357882);}export function segmentToYamlString(_0x4cb1aa){const _0x3747b5=a111_0x28abc7,_0x53462a=JSON[_0x3747b5(0xd7)](JSON[_0x3747b5(0xe4)](_0x4cb1aa)),_0x1a5b78=a111_0xe7d623[_0x3747b5(0xe4)](_0x53462a,{'indent':0x2,'lineWidth':0x0,'nullStr':_0x3747b5(0x10f)}),_0x16d549=[_0x3747b5(0xe8),_0x3747b5(0xa1)];let _0x3e8246=_0x1a5b78;for(const _0x1136ca of _0x16d549){_0x3e8246=_0x3e8246[_0x3747b5(0xa7)](new RegExp('^('+_0x1136ca+')','m'),(_0x17e947,_0x33acb0,_0x302bfc)=>{if(_0x302bfc===0x0||_0x3e8246[_0x302bfc-0x1]==='\x0a'&&_0x3e8246[_0x302bfc-0x2]==='\x0a')return _0x33acb0;return'\x0a'+_0x33acb0;});}return _0x3e8246;}export function parseSegmentYamlFile(_0x17bd60){const _0x43e97f=a111_0x28abc7,_0x16a006=a111_0xe7d623[_0x43e97f(0xd7)](_0x17bd60);if(!_0x16a006[_0x43e97f(0xdc)])throw new Error('YAML\x20config\x20missing\x20required\x20field:\x20name');return _0x16a006;}export function normalizeChildSegmentYaml(_0x54f74c){const _0x3a03ca=a111_0x28abc7;return{'type':_0x3a03ca(0xfc),'name':_0x54f74c[_0x3a03ca(0xdc)],..._0x54f74c[_0x3a03ca(0x98)]!==undefined&&{'description':_0x54f74c['description']},..._0x54f74c[_0x3a03ca(0xf3)]!==undefined&&{'folder':_0x54f74c[_0x3a03ca(0xf3)]},..._0x54f74c[_0x3a03ca(0xad)]&&{'rule':normalizeRule(_0x54f74c[_0x3a03ca(0xad)])},..._0x54f74c[_0x3a03ca(0xdd)]!==undefined&&{'kind':_0x54f74c[_0x3a03ca(0xdd)]},..._0x54f74c[_0x3a03ca(0xcf)]!==undefined&&{'visible':_0x54f74c[_0x3a03ca(0xcf)]},..._0x54f74c['activations']&&{'activations':_0x54f74c[_0x3a03ca(0xce)][_0x3a03ca(0x119)](normalizeActivation)}};}export function normalizeRule(_0x3d93a7){const _0x4ea351=a111_0x28abc7;return{'type':_0x3d93a7['type'],'conditions':_0x3d93a7['conditions'][_0x4ea351(0x119)](normalizeCondition),..._0x3d93a7[_0x4ea351(0x98)]!==undefined&&{'description':_0x3d93a7[_0x4ea351(0x98)]}};}function normalizeCondition(_0x53ccfe){const _0x2c22fc=a111_0x28abc7;if('segment'in _0x53ccfe&&(_0x53ccfe[_0x2c22fc(0xfe)]==='include'||_0x53ccfe[_0x2c22fc(0xfe)]===_0x2c22fc(0x91))){const _0x44eed1=_0x53ccfe;return{'type':_0x44eed1[_0x2c22fc(0xfe)],'segment':_0x44eed1['segment']};}if(_0x2c22fc(0xfe)in _0x53ccfe&&(_0x53ccfe[_0x2c22fc(0xfe)]===_0x2c22fc(0xa4)||_0x53ccfe['type']==='Or')){const _0x53d46b=_0x53ccfe;return{'type':_0x53d46b[_0x2c22fc(0xfe)],'conditions':_0x53d46b['conditions'][_0x2c22fc(0x119)](normalizeCondition),..._0x53d46b[_0x2c22fc(0x98)]!==undefined&&{'description':_0x53d46b['description']}};}const _0x4158f2=_0x53ccfe;return{'type':_0x2c22fc(0x8e),'attribute':_0x4158f2['attribute'],'operator':normalizeOperator(_0x4158f2[_0x2c22fc(0xb3)]),..._0x4158f2['arrayMatching']!==undefined&&{'arrayMatching':_0x4158f2[_0x2c22fc(0xfa)]},..._0x4158f2[_0x2c22fc(0x91)]!==undefined&&{'exclude':_0x4158f2[_0x2c22fc(0x91)]},..._0x4158f2[_0x2c22fc(0xbf)]!==undefined&&{'aggregation':_0x4158f2[_0x2c22fc(0xbf)]},..._0x4158f2[_0x2c22fc(0xe6)]!==undefined&&{'source':_0x4158f2[_0x2c22fc(0xe6)]},..._0x4158f2[_0x2c22fc(0x90)]!==undefined&&{'filter':normalizeRule(_0x4158f2['filter'])},..._0x4158f2[_0x2c22fc(0xe9)]!==undefined&&{'limit':_0x4158f2[_0x2c22fc(0xe9)]}};}function normalizeOperator(_0x5c99d9){const _0x2136a5=a111_0x28abc7,_0x5d046a=getEffectiveValue(_0x5c99d9);return{'type':_0x5c99d9[_0x2136a5(0xfe)],..._0x5c99d9[_0x2136a5(0x92)]!==undefined&&{'not':_0x5c99d9[_0x2136a5(0x92)]},..._0x5d046a!==undefined&&{'value':_0x5d046a},..._0x5c99d9['min']!==undefined&&{'min':_0x5c99d9[_0x2136a5(0x100)]},..._0x5c99d9[_0x2136a5(0xa6)]!==undefined&&{'max':_0x5c99d9['max']},..._0x5c99d9['unit']!==undefined&&{'unit':_0x5c99d9[_0x2136a5(0xb7)]},..._0x5c99d9[_0x2136a5(0xee)]!==undefined&&{'duration':_0x5c99d9[_0x2136a5(0xee)]},..._0x5c99d9['from']!==undefined&&{'from':_0x5c99d9[_0x2136a5(0xb5)]}};}function normalizeActivation(_0x3460b4){const _0x686de2=a111_0x28abc7;return{'name':_0x3460b4['name'],'connection':_0x3460b4[_0x686de2(0xd1)],..._0x3460b4[_0x686de2(0x98)]!==undefined&&{'description':_0x3460b4[_0x686de2(0x98)]},..._0x3460b4[_0x686de2(0x9a)]!==undefined&&{'all_columns':_0x3460b4[_0x686de2(0x9a)]},..._0x3460b4[_0x686de2(0xca)]!==undefined&&{'columns':_0x3460b4['columns']},..._0x3460b4[_0x686de2(0xd2)]!==undefined&&{'behavior':_0x3460b4[_0x686de2(0xd2)]},..._0x3460b4[_0x686de2(0x10c)]!==undefined&&{'schedule':_0x3460b4[_0x686de2(0x10c)]},..._0x3460b4['notification']!==undefined&&{'notification':_0x3460b4['notification']},..._0x3460b4[_0x686de2(0xbd)]!==undefined&&{'connector_config':_0x3460b4[_0x686de2(0xbd)]},..._0x3460b4[_0x686de2(0xe2)]!==undefined&&{'activation_template_id':_0x3460b4['activation_template_id']}};}export function activationResponseToDef(_0x3b404b,_0x2563fa,_0x47155a){const _0x22616b=a111_0x28abc7,_0x22fe25=_0x3b404b[_0x22616b(0xf7)]||'',_0x4b5774=_0x47155a?.[_0x22616b(0xef)](_0x22fe25)??_0x22fe25,_0x350269={'name':_0x3b404b[_0x22616b(0xdc)],'connection':_0x4b5774};_0x3b404b[_0x22616b(0x98)]&&(_0x350269[_0x22616b(0x98)]=_0x3b404b['description']);let _0x320a7f=[];_0x3b404b[_0x22616b(0xca)]&&_0x3b404b['columns'][_0x22616b(0x97)]>0x0&&(_0x320a7f=_0x3b404b[_0x22616b(0xca)][_0x22616b(0x90)](_0x29b920=>_0x29b920&&_0x29b920['name'])[_0x22616b(0x119)](_0x294b3d=>{const _0x1196b4=_0x22616b;if(_0x294b3d[_0x1196b4(0xfe)]||_0x294b3d[_0x1196b4(0x102)])return{'name':_0x294b3d[_0x1196b4(0xdc)],..._0x294b3d['type']&&{'type':_0x294b3d[_0x1196b4(0xfe)]},..._0x294b3d[_0x1196b4(0x102)]&&{'visibility':_0x294b3d[_0x1196b4(0x102)]}};return _0x294b3d[_0x1196b4(0xdc)];}));_0x320a7f[_0x22616b(0x97)]>0x0&&(_0x350269[_0x22616b(0xca)]=_0x320a7f);_0x3b404b[_0x22616b(0x95)]!==undefined&&(_0x3b404b[_0x22616b(0x95)]===![]&&_0x320a7f['length']===0x0?_0x350269[_0x22616b(0x9a)]=!![]:_0x350269['all_columns']=_0x3b404b[_0x22616b(0x95)]);const _0x2b6679={};let _0x28d04f=![];_0x3b404b[_0x22616b(0x9c)]&&(_0x2b6679[_0x22616b(0xfe)]=_0x3b404b['scheduleType'],_0x28d04f=!![]);_0x3b404b[_0x22616b(0xc8)]&&(_0x2b6679['repeat_unit']=_0x3b404b['repeatUnit'],_0x28d04f=!![]);_0x3b404b['repeatFrequency']!==undefined&&_0x3b404b[_0x22616b(0xa0)]!==null&&(_0x2b6679['repeat_frequency']=_0x3b404b[_0x22616b(0xa0)],_0x28d04f=!![]);_0x3b404b[_0x22616b(0xc9)]&&_0x3b404b['repeatSubFrequency'][_0x22616b(0x97)]>0x0&&(_0x2b6679[_0x22616b(0xd0)]=_0x3b404b['repeatSubFrequency'],_0x28d04f=!![]);_0x3b404b[_0x22616b(0x113)]!==undefined&&(_0x2b6679[_0x22616b(0xf8)]=_0x3b404b[_0x22616b(0x113)],_0x28d04f=!![]);_0x3b404b[_0x22616b(0xed)]!==undefined&&(_0x2b6679[_0x22616b(0xde)]=_0x3b404b[_0x22616b(0xed)],_0x28d04f=!![]);_0x3b404b['timezone']&&(_0x2b6679[_0x22616b(0x11a)]=_0x3b404b[_0x22616b(0x11a)],_0x28d04f=!![]);_0x28d04f&&(_0x350269[_0x22616b(0x10c)]=_0x2b6679);(_0x3b404b[_0x22616b(0x10b)]&&_0x3b404b[_0x22616b(0x10b)][_0x22616b(0x97)]>0x0||_0x3b404b[_0x22616b(0xcb)]&&_0x3b404b[_0x22616b(0xcb)][_0x22616b(0x97)]>0x0)&&(_0x350269['notification']={},_0x3b404b[_0x22616b(0x10b)]&&_0x3b404b[_0x22616b(0x10b)]['length']>0x0&&(_0x350269[_0x22616b(0x9f)][_0x22616b(0xf6)]=_0x3b404b['notifyOn']),_0x3b404b[_0x22616b(0xcb)]&&_0x3b404b[_0x22616b(0xcb)][_0x22616b(0x97)]>0x0&&(_0x350269[_0x22616b(0x9f)]['email_recipients']=_0x3b404b[_0x22616b(0xcb)][_0x22616b(0x119)](_0x264bdd=>{const _0x2a8bdb=_0x22616b,_0x5efb62=_0x2563fa?.[_0x2a8bdb(0xef)](_0x264bdd);return _0x5efb62??String(_0x264bdd);})));_0x3b404b[_0x22616b(0x115)]&&Object[_0x22616b(0xb6)](_0x3b404b[_0x22616b(0x115)])[_0x22616b(0x97)]>0x0&&(_0x350269[_0x22616b(0xbd)]=normalizeConnectorConfigForYaml(_0x3b404b[_0x22616b(0x115)]));_0x3b404b['activationTemplateId']&&(_0x350269['activation_template_id']=_0x3b404b['activationTemplateId']);if(_0x3b404b['syndicationBehavior']){const _0x46995e={},_0x4afc66=_0x3b404b['syndicationBehavior'];_0x4afc66['columns']&&_0x4afc66[_0x22616b(0xca)][_0x22616b(0x97)]>0x0&&(_0x46995e[_0x22616b(0xca)]=_0x4afc66[_0x22616b(0xca)][_0x22616b(0x90)](_0x44daba=>_0x44daba&&_0x44daba[_0x22616b(0xdc)])[_0x22616b(0x119)](_0x3c2fd2=>({'name':_0x3c2fd2[_0x22616b(0xdc)],..._0x3c2fd2[_0x22616b(0xfe)]&&{'type':_0x3c2fd2['type']},..._0x3c2fd2[_0x22616b(0x102)]&&{'visibility':_0x3c2fd2[_0x22616b(0x102)]}}))),_0x4afc66[_0x22616b(0x117)]&&(_0x46995e[_0x22616b(0xbe)]=_0x4afc66[_0x22616b(0x117)]),_0x4afc66[_0x22616b(0xe3)]!==undefined&&(_0x46995e[_0x22616b(0x9b)]=_0x4afc66[_0x22616b(0xe3)]),_0x4afc66['joinStrategy']&&(_0x46995e['join_strategy']=_0x4afc66[_0x22616b(0xae)]),_0x4afc66['formatting']&&(_0x46995e[_0x22616b(0x112)]=_0x4afc66[_0x22616b(0x112)]),_0x4afc66[_0x22616b(0x111)]&&_0x4afc66[_0x22616b(0x111)][_0x22616b(0x97)]>0x0&&(_0x46995e[_0x22616b(0xcc)]=_0x4afc66[_0x22616b(0x111)]),Object[_0x22616b(0xb6)](_0x46995e)[_0x22616b(0x97)]>0x0&&(_0x350269[_0x22616b(0xd2)]=_0x46995e);}return _0x350269;}export function journeyActivationStepToYaml(_0x56310c,_0x114a6a,_0x3eeea4){const _0x459e29=a111_0x28abc7,_0x2869eb=_0x56310c['attributes'][_0x459e29(0xac)],_0x57d0e5=_0x2869eb[_0x459e29(0xf7)]||'',_0x51a988=_0x3eeea4?.['get'](_0x57d0e5)??_0x57d0e5,_0xfff672={'name':_0x2869eb['name']||'','connection':_0x51a988};_0x2869eb[_0x459e29(0x98)]&&(_0xfff672[_0x459e29(0x98)]=_0x2869eb[_0x459e29(0x98)]);let _0x34b01b=[];_0x2869eb[_0x459e29(0xca)]&&_0x2869eb[_0x459e29(0xca)][_0x459e29(0x97)]>0x0&&(_0x34b01b=_0x2869eb[_0x459e29(0xca)]['filter'](_0x256680=>_0x256680&&_0x256680[_0x459e29(0xdc)])[_0x459e29(0x119)](_0x4db404=>{const _0x49699e=_0x459e29;if(_0x4db404[_0x49699e(0xfe)]||_0x4db404[_0x49699e(0x102)])return{'name':_0x4db404[_0x49699e(0xdc)],..._0x4db404['type']&&{'type':_0x4db404[_0x49699e(0xfe)]},..._0x4db404[_0x49699e(0x102)]&&{'visibility':_0x4db404[_0x49699e(0x102)]}};return _0x4db404['name'];}));_0x34b01b[_0x459e29(0x97)]>0x0&&(_0xfff672[_0x459e29(0xca)]=_0x34b01b);_0x2869eb[_0x459e29(0x95)]!==undefined&&(_0x2869eb[_0x459e29(0x95)]===![]&&_0x34b01b['length']===0x0?_0xfff672[_0x459e29(0x9a)]=!![]:_0xfff672[_0x459e29(0x9a)]=_0x2869eb[_0x459e29(0x95)]);const _0x648aec={};let _0x3e3d40=![];_0x2869eb[_0x459e29(0x9c)]&&(_0x648aec['type']=_0x2869eb[_0x459e29(0x9c)],_0x3e3d40=!![]);_0x2869eb['repeatUnit']&&(_0x648aec[_0x459e29(0xf4)]=_0x2869eb[_0x459e29(0xc8)],_0x3e3d40=!![]);_0x2869eb[_0x459e29(0xa0)]!==undefined&&_0x2869eb[_0x459e29(0xa0)]!==null&&(_0x648aec[_0x459e29(0xb0)]=_0x2869eb[_0x459e29(0xa0)],_0x3e3d40=!![]);_0x2869eb[_0x459e29(0x113)]!==undefined&&(_0x648aec['start_at']=_0x2869eb[_0x459e29(0x113)],_0x3e3d40=!![]);_0x2869eb[_0x459e29(0xed)]!==undefined&&(_0x648aec[_0x459e29(0xde)]=_0x2869eb['endOn'],_0x3e3d40=!![]);_0x2869eb[_0x459e29(0x11a)]&&(_0x648aec[_0x459e29(0x11a)]=_0x2869eb[_0x459e29(0x11a)],_0x3e3d40=!![]);_0x3e3d40&&(_0xfff672['schedule']=_0x648aec);(_0x2869eb['notifyOn']&&_0x2869eb[_0x459e29(0x10b)][_0x459e29(0x97)]>0x0||_0x2869eb[_0x459e29(0xcb)]&&_0x2869eb[_0x459e29(0xcb)][_0x459e29(0x97)]>0x0)&&(_0xfff672[_0x459e29(0x9f)]={},_0x2869eb[_0x459e29(0x10b)]&&_0x2869eb[_0x459e29(0x10b)][_0x459e29(0x97)]>0x0&&(_0xfff672[_0x459e29(0x9f)][_0x459e29(0xf6)]=_0x2869eb[_0x459e29(0x10b)]),_0x2869eb[_0x459e29(0xcb)]&&_0x2869eb[_0x459e29(0xcb)][_0x459e29(0x97)]>0x0&&(_0xfff672[_0x459e29(0x9f)][_0x459e29(0xab)]=_0x2869eb[_0x459e29(0xcb)][_0x459e29(0x119)](_0x4fa276=>{const _0x249087=_0x459e29,_0x1ed295=_0x114a6a?.[_0x249087(0xef)](_0x4fa276);return _0x1ed295??String(_0x4fa276);})));_0x2869eb[_0x459e29(0x115)]&&Object['keys'](_0x2869eb[_0x459e29(0x115)])[_0x459e29(0x97)]>0x0&&(_0xfff672['connector_config']=normalizeConnectorConfigForYaml(_0x2869eb['connectorConfig']));_0x2869eb[_0x459e29(0xeb)]&&(_0xfff672[_0x459e29(0xe2)]=_0x2869eb[_0x459e29(0xeb)]);if(_0x2869eb[_0x459e29(0xf5)]){const _0x17d482={},_0x516d5d=_0x2869eb[_0x459e29(0xf5)];_0x516d5d[_0x459e29(0xca)]&&_0x516d5d[_0x459e29(0xca)]['length']>0x0&&(_0x17d482[_0x459e29(0xca)]=_0x516d5d[_0x459e29(0xca)][_0x459e29(0x90)](_0x151b53=>_0x151b53&&_0x151b53[_0x459e29(0xdc)])[_0x459e29(0x119)](_0x2096df=>({'name':_0x2096df[_0x459e29(0xdc)],..._0x2096df[_0x459e29(0xfe)]&&{'type':_0x2096df['type']},..._0x2096df[_0x459e29(0x102)]&&{'visibility':_0x2096df[_0x459e29(0x102)]}}))),_0x516d5d['behaviorTableName']&&(_0x17d482[_0x459e29(0xbe)]=_0x516d5d[_0x459e29(0x117)]),_0x516d5d[_0x459e29(0xe3)]!==undefined&&(_0x17d482['join_row']=_0x516d5d[_0x459e29(0xe3)]),_0x516d5d['joinStrategy']&&(_0x17d482[_0x459e29(0xa5)]=_0x516d5d[_0x459e29(0xae)]),_0x516d5d['formatting']&&(_0x17d482[_0x459e29(0x112)]=_0x516d5d[_0x459e29(0x112)]),_0x516d5d[_0x459e29(0x111)]&&_0x516d5d['orderBy']['length']>0x0&&(_0x17d482[_0x459e29(0xcc)]=_0x516d5d[_0x459e29(0x111)]),Object['keys'](_0x17d482)[_0x459e29(0x97)]>0x0&&(_0xfff672['behavior']=_0x17d482);}return _0xfff672;}export function segmentWithActivationsToYaml(_0x4ac764,_0x390ff9,_0x4521c2,_0x33838b,_0x274d05){const _0x264c81=a111_0x28abc7,_0x4fd11b=segmentResponseToDefSync(_0x4ac764,_0x4521c2);return _0x390ff9[_0x264c81(0x97)]>0x0&&(_0x4fd11b[_0x264c81(0xce)]=_0x390ff9[_0x264c81(0x119)](_0x3c03f5=>activationResponseToDef(_0x3c03f5,_0x33838b,_0x274d05))),_0x4fd11b;}function normalizeColumn(_0x321482){const _0x1a3c7d=a111_0x28abc7;if(typeof _0x321482==='string')return{'name':_0x321482};return{'name':_0x321482[_0x1a3c7d(0xdc)],..._0x321482[_0x1a3c7d(0xfe)]&&{'type':_0x321482[_0x1a3c7d(0xfe)]},..._0x321482[_0x1a3c7d(0x102)]&&{'visibility':_0x321482[_0x1a3c7d(0x102)]}};}export async function activationDefToCreateRequest(_0x2fcdd5,_0xd32aa){const _0x9c2c30=a111_0x28abc7,_0x47b9c1=_0xd32aa?.[_0x9c2c30(0xf0)],_0x4fad8f=_0xd32aa?.[_0x9c2c30(0xf2)],_0x11c58d=_0x2fcdd5[_0x9c2c30(0xd1)];let _0x11a2e5;const _0x2075f0=parseInt(_0x11c58d,0xa);if(!isNaN(_0x2075f0)&&String(_0x2075f0)===_0x11c58d)_0x11a2e5=_0x2075f0;else{const _0x4cf919=_0x4fad8f?.[_0x9c2c30(0xef)](_0x11c58d);if(_0x4cf919===undefined)throw new SDKError(ErrorCode['CONNECTION_NOT_FOUND'],_0x9c2c30(0x107)+_0x11c58d,undefined,{'helpText':_0x9c2c30(0x8d)});_0x11a2e5=_0x4cf919;}const _0x2b2714={'name':_0x2fcdd5[_0x9c2c30(0xdc)],'connectionId':_0x11a2e5};_0x2fcdd5['description']&&(_0x2b2714[_0x9c2c30(0x98)]=_0x2fcdd5[_0x9c2c30(0x98)]);let _0x356828=[];_0x2fcdd5[_0x9c2c30(0xca)]&&_0x2fcdd5[_0x9c2c30(0xca)]['length']>0x0&&(_0x356828=_0x2fcdd5[_0x9c2c30(0xca)][_0x9c2c30(0x90)](_0x38943d=>_0x38943d!=null)[_0x9c2c30(0x119)](normalizeColumn));_0x356828[_0x9c2c30(0x97)]>0x0&&(_0x2b2714[_0x9c2c30(0xca)]=_0x356828);_0x2fcdd5[_0x9c2c30(0x9a)]!==undefined&&(_0x2fcdd5['all_columns']===![]&&_0x356828[_0x9c2c30(0x97)]===0x0?_0x2b2714['allColumns']=!![]:_0x2b2714[_0x9c2c30(0x95)]=_0x2fcdd5[_0x9c2c30(0x9a)]);if(_0x2fcdd5[_0x9c2c30(0x10c)]){const _0x3d3414=_0x2fcdd5[_0x9c2c30(0x10c)];_0x3d3414[_0x9c2c30(0xfe)]&&(_0x2b2714[_0x9c2c30(0x9c)]=_0x3d3414[_0x9c2c30(0xfe)]),_0x3d3414[_0x9c2c30(0xf4)]&&(_0x2b2714[_0x9c2c30(0xc8)]=_0x3d3414[_0x9c2c30(0xf4)]),_0x3d3414[_0x9c2c30(0xb0)]!==undefined&&(_0x2b2714[_0x9c2c30(0xa0)]=_0x3d3414[_0x9c2c30(0xb0)]),_0x3d3414[_0x9c2c30(0xd0)]&&(_0x2b2714[_0x9c2c30(0xc9)]=_0x3d3414[_0x9c2c30(0xd0)]),_0x3d3414[_0x9c2c30(0xf8)]!==undefined&&(_0x2b2714[_0x9c2c30(0x113)]=_0x3d3414[_0x9c2c30(0xf8)]),_0x3d3414[_0x9c2c30(0xde)]!==undefined&&(_0x2b2714['endOn']=_0x3d3414[_0x9c2c30(0xde)]),_0x3d3414[_0x9c2c30(0x11a)]&&(_0x2b2714['timezone']=_0x3d3414[_0x9c2c30(0x11a)]);}_0x2fcdd5[_0x9c2c30(0x9f)]&&(_0x2fcdd5[_0x9c2c30(0x9f)][_0x9c2c30(0xf6)]&&(_0x2b2714[_0x9c2c30(0x10b)]=_0x2fcdd5['notification'][_0x9c2c30(0xf6)]),_0x2fcdd5[_0x9c2c30(0x9f)]['email_recipients']&&(_0x2b2714[_0x9c2c30(0xcb)]=_0x2fcdd5['notification'][_0x9c2c30(0xab)][_0x9c2c30(0x119)](_0x2879df=>{const _0x3faf35=_0x9c2c30,_0x589bd5=Number(_0x2879df);if(!isNaN(_0x589bd5)&&String(_0x589bd5)===_0x2879df)return _0x589bd5;const _0x179f3d=_0x47b9c1?.[_0x3faf35(0xef)](_0x2879df[_0x3faf35(0xdb)]());if(_0x179f3d===undefined)throw new SDKError(ErrorCode['INVALID_ARGUMENT'],_0x3faf35(0xa2)+_0x2879df+_0x3faf35(0xa9));return _0x179f3d;})));if(_0x2fcdd5[_0x9c2c30(0xbd)]){const _0x92d8c2=_0xd32aa?.[_0x9c2c30(0xea)]?.[_0x9c2c30(0xef)](_0x11c58d);if(_0x92d8c2&&_0xd32aa?.[_0x9c2c30(0x94)])try{const _0x124043=await _0xd32aa[_0x9c2c30(0x94)](_0x92d8c2),_0x348c3c=validateConnectorConfig(_0x2fcdd5['connector_config'],_0x124043);if(!_0x348c3c[_0x9c2c30(0xba)])throw new SDKError(ErrorCode[_0x9c2c30(0x110)],_0x9c2c30(0x10d)+_0x2fcdd5[_0x9c2c30(0xdc)]+_0x9c2c30(0xd3)+formatValidationErrors(_0x348c3c[_0x9c2c30(0xf9)]),undefined,{'helpText':_0x9c2c30(0x101)+_0x92d8c2+_0x9c2c30(0xda)+formatSchemaAsHelp(_0x124043)});if(_0x348c3c[_0x9c2c30(0x8f)][_0x9c2c30(0x97)]>0x0){const _0x334394=formatValidationWarnings(_0x348c3c[_0x9c2c30(0x8f)]);console[_0x9c2c30(0xbb)]('connector_config\x20for\x20activation\x20\x22'+_0x2fcdd5[_0x9c2c30(0xdc)]+_0x9c2c30(0xd3)+_0x334394);}_0x2b2714[_0x9c2c30(0x115)]=transformConfigToLegacy(_0x2fcdd5[_0x9c2c30(0xbd)],_0x124043);}catch(_0x169272){if(_0x169272 instanceof SDKError&&_0x169272['code']===ErrorCode[_0x9c2c30(0x118)])_0x2b2714[_0x9c2c30(0x115)]=_0x2fcdd5[_0x9c2c30(0xbd)];else throw _0x169272;}else _0x2b2714['connectorConfig']=_0x2fcdd5[_0x9c2c30(0xbd)];}_0x2fcdd5[_0x9c2c30(0xe2)]!==undefined&&(_0x2b2714['activationTemplateId']=_0x2fcdd5[_0x9c2c30(0xe2)]);if(_0x2fcdd5[_0x9c2c30(0xd2)]){const _0x26ef2d=_0x2fcdd5[_0x9c2c30(0xd2)],_0x3d1ace={};if(_0x26ef2d[_0x9c2c30(0xca)]&&_0x26ef2d[_0x9c2c30(0xca)]['length']>0x0){const _0x2cbd98=_0x26ef2d[_0x9c2c30(0xca)][_0x9c2c30(0x90)](_0x492a31=>_0x492a31&&_0x492a31[_0x9c2c30(0xdc)]);_0x2cbd98[_0x9c2c30(0x97)]>0x0&&(_0x3d1ace['columns']=_0x2cbd98);}_0x26ef2d[_0x9c2c30(0xbe)]&&(_0x3d1ace[_0x9c2c30(0x117)]=_0x26ef2d[_0x9c2c30(0xbe)]),_0x26ef2d[_0x9c2c30(0x9b)]!==undefined&&(_0x3d1ace[_0x9c2c30(0xe3)]=_0x26ef2d[_0x9c2c30(0x9b)]),_0x26ef2d[_0x9c2c30(0xa5)]&&(_0x3d1ace[_0x9c2c30(0xae)]=_0x26ef2d[_0x9c2c30(0xa5)]),_0x26ef2d[_0x9c2c30(0x112)]&&(_0x3d1ace[_0x9c2c30(0x112)]=_0x26ef2d[_0x9c2c30(0x112)]),_0x26ef2d[_0x9c2c30(0xcc)]&&(_0x3d1ace[_0x9c2c30(0x111)]=_0x26ef2d[_0x9c2c30(0xcc)]),_0x2b2714[_0x9c2c30(0xf5)]=_0x3d1ace;}return _0x2b2714;}export async function activationDefToUpdateRequest(_0x401359,_0x2cfb5a){return activationDefToCreateRequest(_0x401359,_0x2cfb5a);}export function deepSortObject(_0x58a44f){const _0x4ee133=a111_0x28abc7;if(_0x58a44f===null||typeof _0x58a44f!==_0x4ee133(0xe5))return _0x58a44f;if(Array['isArray'](_0x58a44f))return _0x58a44f[_0x4ee133(0x119)](deepSortObject)[_0x4ee133(0xaa)]((_0x2c3b41,_0x1eae3c)=>JSON[_0x4ee133(0xe4)](_0x2c3b41)['localeCompare'](JSON['stringify'](_0x1eae3c)));const _0x67bb1b={};for(const _0x412485 of Object['keys'](_0x58a44f)['sort']()){_0x67bb1b[_0x412485]=deepSortObject(_0x58a44f[_0x412485]);}return _0x67bb1b;}export function serializeRule(_0x21e124){return JSON['stringify'](deepSortObject(_0x21e124));}export function normalizeRuleForMatching(_0xc29997){return normalizeConditionsForMatching(_0xc29997);}function normalizeConditionsForMatching(_0x5df966){const _0x56f5ae=a111_0x28abc7;if(_0x5df966===null||typeof _0x5df966!=='object')return _0x5df966;if(Array[_0x56f5ae(0xe7)](_0x5df966))return _0x5df966[_0x56f5ae(0x119)](normalizeConditionsForMatching);const _0x10c536=_0x5df966;if((_0x10c536[_0x56f5ae(0xfe)]===_0x56f5ae(0x10a)||_0x10c536[_0x56f5ae(0xfe)]===_0x56f5ae(0x91))&&typeof _0x10c536['segment']===_0x56f5ae(0xbc))return{..._0x10c536,'segment':_0x56f5ae(0x11c)};const _0x272e76={};for(const _0x3dedcc of Object[_0x56f5ae(0xb6)](_0x10c536)){_0x272e76[_0x3dedcc]=normalizeConditionsForMatching(_0x10c536[_0x3dedcc]);}return _0x272e76;}export function serializeRuleForMatching(_0x46f648){const _0x4e8708=a111_0x28abc7;return JSON[_0x4e8708(0xe4)](deepSortObject(normalizeRuleForMatching(_0x46f648)));}export function expandSegmentReferences(_0x2d9934,_0x5f3bfa,_0x6b8cf9=new Set()){return expandConditions(_0x2d9934,_0x5f3bfa,_0x6b8cf9);}function expandConditions(_0x5f164d,_0x50b3ed,_0x19a3ed){const _0x47ff97=a111_0x28abc7;if(_0x5f164d===null||typeof _0x5f164d!==_0x47ff97(0xe5))return _0x5f164d;if(Array[_0x47ff97(0xe7)](_0x5f164d))return _0x5f164d[_0x47ff97(0x119)](_0x52bacb=>expandConditions(_0x52bacb,_0x50b3ed,_0x19a3ed));const _0x1fada2=_0x5f164d;if((_0x1fada2[_0x47ff97(0xfe)]==='include'||_0x1fada2[_0x47ff97(0xfe)]===_0x47ff97(0x91))&&typeof _0x1fada2[_0x47ff97(0xfc)]===_0x47ff97(0xbc)){const _0x4dbc53=_0x1fada2[_0x47ff97(0xfc)],_0xb7dde8=_0x50b3ed[_0x47ff97(0xef)](_0x4dbc53);if(_0xb7dde8&&!_0x19a3ed[_0x47ff97(0xb2)](_0x4dbc53)){const _0xb04a4c=new Set(_0x19a3ed);_0xb04a4c['add'](_0x4dbc53);const _0x30f511=expandConditions(_0xb7dde8,_0x50b3ed,_0xb04a4c);return{'type':_0x1fada2[_0x47ff97(0xfe)],'expanded_rule':_0x30f511};}return{'type':_0x1fada2['type'],'expanded_rule':_0x47ff97(0xb8)};}const _0xf1655={};for(const _0xff1d0c of Object[_0x47ff97(0xb6)](_0x1fada2)){_0xf1655[_0xff1d0c]=expandConditions(_0x1fada2[_0xff1d0c],_0x50b3ed,_0x19a3ed);}return _0xf1655;}export function serializeExpandedRule(_0x1a9d20,_0x5ca4e2){const _0x18ebdf=expandSegmentReferences(_0x1a9d20,_0x5ca4e2);return JSON['stringify'](deepSortObject(_0x18ebdf));}export function createSegmentNameContext(_0x1c675f){const _0x46cb31=a111_0x28abc7,_0x2d4487=new Set(),_0x5e4e32=new Map(),_0x302a7b=new Map();if(_0x1c675f)for(const [_0x3aece6,_0x3c0231]of Object['entries'](_0x1c675f)){if(_0x3c0231['rule']){const _0x4ba5b5=serializeRule(_0x3c0231[_0x46cb31(0xad)]);_0x302a7b[_0x46cb31(0x109)](_0x4ba5b5,_0x3aece6),_0x2d4487[_0x46cb31(0xdf)](_0x3aece6);}}return{'usedNames':_0x2d4487,'ruleHashToName':_0x5e4e32,'localRuleToName':_0x1c675f?_0x302a7b:undefined};}export function resolveSegmentName(_0x4d7afc,_0x20c624,_0x50bd92,_0x3a303c){const _0x59b42f=a111_0x28abc7,_0x5a6387=serializeRule(_0x20c624);if(_0x50bd92[_0x59b42f(0x96)]){const _0x3c4642=_0x50bd92[_0x59b42f(0x96)]['get'](_0x5a6387);if(_0x3c4642)return{'name':_0x3c4642,'isDuplicate':![],'isLocalMatch':!![]};}const _0x9fabb3=_0x50bd92[_0x59b42f(0x104)][_0x59b42f(0xef)](_0x5a6387);if(_0x9fabb3)return{'name':_0x9fabb3,'isDuplicate':!![],'isLocalMatch':![]};const _0x1ec4e5=_0x3a303c(_0x4d7afc);let _0x217fa4=_0x1ec4e5||_0x4d7afc,_0x58367c=_0x217fa4,_0x429d38=0x2;while(_0x50bd92[_0x59b42f(0x10e)][_0x59b42f(0xb2)](_0x58367c)){_0x58367c=_0x217fa4+'_'+_0x429d38,_0x429d38++;}return _0x50bd92[_0x59b42f(0x10e)][_0x59b42f(0xdf)](_0x58367c),_0x50bd92[_0x59b42f(0x104)][_0x59b42f(0x109)](_0x5a6387,_0x58367c),{'name':_0x58367c,'isDuplicate':![],'isLocalMatch':![]};}export function collectSegmentRefsFromRule(_0x4ce60a){const _0x327a6d=[],_0x5856a6=_0x53735b=>{const _0x4c865b=a111_0x146b;if(!_0x53735b||typeof _0x53735b!==_0x4c865b(0xe5))return;if(Array[_0x4c865b(0xe7)](_0x53735b)){_0x53735b[_0x4c865b(0xd4)](_0x5856a6);return;}const _0x37d955=_0x53735b;(_0x37d955['type']===_0x4c865b(0x10a)||_0x37d955[_0x4c865b(0xfe)]==='exclude')&&typeof _0x37d955[_0x4c865b(0xfc)]===_0x4c865b(0xbc)&&_0x327a6d[_0x4c865b(0xc3)](_0x37d955[_0x4c865b(0xfc)]);for(const _0x7790b of Object[_0x4c865b(0xc0)](_0x37d955)){_0x5856a6(_0x7790b);}};return _0x5856a6(_0x4ce60a),_0x327a6d;}export function validateSegmentRule(_0x3afe7e,_0x3011c8){const _0xb3625f=a111_0x28abc7;if(!_0x3011c8||!_0x3011c8[_0xb3625f(0xd6)])return;for(let _0x36fbd6=0x0;_0x36fbd6<_0x3011c8['conditions'][_0xb3625f(0x97)];_0x36fbd6++){const _0x311ae9=_0x3011c8['conditions'][_0x36fbd6];if(_0xb3625f(0xfe)in _0x311ae9&&_0x311ae9[_0xb3625f(0xfe)]===_0xb3625f(0x8e)){const _0x35a631=_0x311ae9;if(!_0x35a631['attribute']||_0x35a631['attribute']==='')throw new SDKError(ErrorCode[_0xb3625f(0x116)],_0xb3625f(0xc7)+_0x3afe7e+_0xb3625f(0x114)+('conditions['+_0x36fbd6+_0xb3625f(0xfb))+_0xb3625f(0x93));}}}
|
|
1
|
+
(function(_0x4c5b6f,_0x28bd02){const _0x5b45a5=a111_0x5430,_0x3e4318=_0x4c5b6f();while(!![]){try{const _0x38c1e0=-parseInt(_0x5b45a5(0x179))/0x1*(-parseInt(_0x5b45a5(0x18b))/0x2)+parseInt(_0x5b45a5(0x171))/0x3+parseInt(_0x5b45a5(0x1d1))/0x4*(parseInt(_0x5b45a5(0x1d8))/0x5)+-parseInt(_0x5b45a5(0x170))/0x6+-parseInt(_0x5b45a5(0x1d5))/0x7*(-parseInt(_0x5b45a5(0x1c0))/0x8)+-parseInt(_0x5b45a5(0x162))/0x9+-parseInt(_0x5b45a5(0x1e3))/0xa*(parseInt(_0x5b45a5(0x1c4))/0xb);if(_0x38c1e0===_0x28bd02)break;else _0x3e4318['push'](_0x3e4318['shift']());}catch(_0x2b6f9c){_0x3e4318['push'](_0x3e4318['shift']());}}}(a111_0x1792,0xc472f));import*as a111_0x40a4dd from'yaml';import{SDKError,ErrorCode}from'../errors.js';import{validateConnectorConfig,transformConfigToLegacy,normalizeConnectorConfigForYaml,formatValidationErrors,formatValidationWarnings,formatSchemaAsHelp}from'../connection-validator.js';export function segmentResponseToDefSync(_0x370f57,_0x4e24fb){const _0x299aa9=a111_0x5430,_0x4e9389=_0x370f57[_0x299aa9(0x17e)]&&'type'in _0x370f57[_0x299aa9(0x17e)]&&_0x370f57[_0x299aa9(0x17e)][_0x299aa9(0x1a0)];return{'type':_0x299aa9(0x1ac),'name':_0x370f57['name'],..._0x370f57[_0x299aa9(0x167)]&&{'description':_0x370f57[_0x299aa9(0x167)]},..._0x4e24fb&&{'folder':_0x4e24fb},..._0x4e9389&&{'rule':apiRuleToYaml(_0x370f57[_0x299aa9(0x17e)])},..._0x370f57[_0x299aa9(0x176)]!==undefined&&{'kind':_0x370f57['kind']===0x0?_0x299aa9(0x182):_0x370f57['kind']===0x1?_0x299aa9(0x1b2):_0x299aa9(0x17b)},..._0x370f57['isVisible']!==undefined&&{'visible':_0x370f57['isVisible']}};}export async function segmentResponseToDef(_0x4b95fc,_0x1147c5,_0x1e84ff){const _0x37ee2c=a111_0x5430,_0x4b6249=segmentResponseToDefSync(_0x4b95fc,_0x1e84ff);if(!_0x1147c5||!_0x1147c5[_0x37ee2c(0x18e)])return _0x4b6249;return _0x4b6249[_0x37ee2c(0x17e)]&&(_0x4b6249[_0x37ee2c(0x17e)]=await resolveRuleSegmentRefs(_0x4b6249[_0x37ee2c(0x17e)],_0x1147c5[_0x37ee2c(0x18e)])),_0x4b6249;}export function apiRuleToYaml(_0x5c2ab5){const _0xe5d2d1=a111_0x5430,_0x3af203=(_0x5c2ab5[_0xe5d2d1(0x17c)]||[])[_0xe5d2d1(0x1d4)](apiConditionToYaml);if(_0x3af203['length']===0x1&&!_0x5c2ab5['description']&&'type'in _0x3af203[0x0]&&(_0x3af203[0x0][_0xe5d2d1(0x1a0)]===_0xe5d2d1(0x19a)||_0x3af203[0x0]['type']==='Or')){const _0x4a676b=_0x3af203[0x0];if(_0x4a676b['type']===_0x5c2ab5[_0xe5d2d1(0x1a0)]&&_0x4a676b[_0xe5d2d1(0x17c)])return{'type':_0x5c2ab5[_0xe5d2d1(0x1a0)],'conditions':_0x4a676b[_0xe5d2d1(0x17c)],..._0x4a676b[_0xe5d2d1(0x167)]&&{'description':_0x4a676b['description']}};}return{'type':_0x5c2ab5['type'],'conditions':_0x3af203,..._0x5c2ab5[_0xe5d2d1(0x167)]&&{'description':_0x5c2ab5['description']}};}export async function resolveRuleSegmentRefs(_0x2ce2c7,_0x2371da){const _0x5ac795=a111_0x5430,_0x11c5a3=await Promise[_0x5ac795(0x16b)](_0x2ce2c7[_0x5ac795(0x17c)][_0x5ac795(0x1d4)](_0x4d3564=>resolveConditionSegmentRefs(_0x4d3564,_0x2371da)));return{..._0x2ce2c7,'conditions':_0x11c5a3};}async function resolveConditionSegmentRefs(_0x23de38,_0xb3702d){const _0x390e3a=a111_0x5430;if(_0x390e3a(0x1ac)in _0x23de38&&(_0x23de38[_0x390e3a(0x1a0)]==='include'||_0x23de38['type']==='exclude')){const _0x5b0830=_0x23de38;if(/^\d+$/[_0x390e3a(0x1b1)](_0x5b0830[_0x390e3a(0x1ac)])){const _0x14c833=await _0xb3702d(_0x5b0830[_0x390e3a(0x1ac)]);return{..._0x5b0830,'segment':_0x14c833};}return _0x23de38;}if(_0x390e3a(0x17c)in _0x23de38&&_0x23de38[_0x390e3a(0x17c)]){const _0x4cfcda=_0x23de38,_0x362ee0=await Promise['all'](_0x4cfcda['conditions'][_0x390e3a(0x1d4)](_0x54bfa8=>resolveConditionSegmentRefs(_0x54bfa8,_0xb3702d)));return{..._0x4cfcda,'conditions':_0x362ee0};}if('filter'in _0x23de38&&_0x23de38[_0x390e3a(0x165)]){const _0x3714cd=_0x23de38,_0x278241=await resolveRuleSegmentRefs(_0x3714cd[_0x390e3a(0x165)],_0xb3702d);return{..._0x3714cd,'filter':_0x278241};}return _0x23de38;}export async function resolveRuleSegmentIds(_0x1bb231,_0x559ba1){const _0x2eb928=await Promise['all'](_0x1bb231['conditions']['map'](_0x4f70bd=>resolveConditionSegmentIds(_0x4f70bd,_0x559ba1)));return{..._0x1bb231,'conditions':_0x2eb928};}async function resolveConditionSegmentIds(_0x3700ba,_0x3d2bb7){const _0x6b4966=a111_0x5430;if(_0x6b4966(0x1ac)in _0x3700ba&&(_0x3700ba[_0x6b4966(0x1a0)]===_0x6b4966(0x1d0)||_0x3700ba[_0x6b4966(0x1a0)]==='exclude')){const _0xbe5608=_0x3700ba;if(!/^\d+$/[_0x6b4966(0x1b1)](_0xbe5608[_0x6b4966(0x1ac)])){const _0x53c7b4=await _0x3d2bb7(_0xbe5608[_0x6b4966(0x1ac)]);return{..._0xbe5608,'segment':_0x53c7b4};}return _0x3700ba;}if(_0x6b4966(0x17c)in _0x3700ba&&_0x3700ba[_0x6b4966(0x17c)]){const _0x2ea38a=_0x3700ba,_0x5ece9a=await Promise['all'](_0x2ea38a['conditions'][_0x6b4966(0x1d4)](_0x43aa9b=>resolveConditionSegmentIds(_0x43aa9b,_0x3d2bb7)));return{..._0x2ea38a,'conditions':_0x5ece9a};}if(_0x6b4966(0x165)in _0x3700ba&&_0x3700ba[_0x6b4966(0x165)]){const _0x47048d=_0x3700ba,_0x3a3dfd=await resolveRuleSegmentIds(_0x47048d[_0x6b4966(0x165)],_0x3d2bb7);return{..._0x47048d,'filter':_0x3a3dfd};}return _0x3700ba;}function apiConditionToYaml(_0x375f1d){const _0x58f7ed=a111_0x5430;if(_0x375f1d[_0x58f7ed(0x1a0)]===_0x58f7ed(0x19a)||_0x375f1d['type']==='Or'){if(_0x375f1d[_0x58f7ed(0x17c)]){const _0x2c1bdf=_0x375f1d[_0x58f7ed(0x17c)]['map'](apiConditionToYaml);if(_0x2c1bdf['length']===0x1&&!_0x375f1d[_0x58f7ed(0x167)])return _0x2c1bdf[0x0];return{'type':_0x375f1d[_0x58f7ed(0x1a0)],'conditions':_0x2c1bdf,..._0x375f1d[_0x58f7ed(0x167)]&&{'description':_0x375f1d[_0x58f7ed(0x167)]}};}}if(_0x375f1d[_0x58f7ed(0x1a0)]===_0x58f7ed(0x1dd)&&_0x375f1d[_0x58f7ed(0x1b5)]&&_0x375f1d[_0x58f7ed(0x1b4)]){const _0x32c0f4=_0x375f1d[_0x58f7ed(0x1b5)]['aggregation']?{'type':_0x375f1d[_0x58f7ed(0x1b5)]['aggregation'][_0x58f7ed(0x1a0)],..._0x375f1d[_0x58f7ed(0x1b5)][_0x58f7ed(0x174)][_0x58f7ed(0x1ed)]&&{'groupingColumns':_0x375f1d['leftValue']['aggregation']['groupingColumns']}}:undefined;return{'type':_0x58f7ed(0x1dd),'attribute':_0x375f1d[_0x58f7ed(0x1b5)]['name']||'','operator':apiOperatorToYaml(_0x375f1d['operator']),..._0x375f1d['arrayMatching']&&_0x375f1d['arrayMatching']!==_0x58f7ed(0x1cf)?{'arrayMatching':_0x375f1d[_0x58f7ed(0x169)]}:{},..._0x375f1d[_0x58f7ed(0x1be)]?{'exclude':_0x375f1d[_0x58f7ed(0x1be)]}:{},..._0x32c0f4?{'aggregation':_0x32c0f4}:{},..._0x375f1d[_0x58f7ed(0x1b5)][_0x58f7ed(0x1db)]?{'source':_0x375f1d[_0x58f7ed(0x1b5)][_0x58f7ed(0x1db)][_0x58f7ed(0x1c7)]}:{},..._0x375f1d[_0x58f7ed(0x1b5)][_0x58f7ed(0x165)]?{'filter':apiRuleToYaml(_0x375f1d['leftValue'][_0x58f7ed(0x165)])}:{},..._0x375f1d['limit']!==undefined&&_0x375f1d[_0x58f7ed(0x1b8)]!==null?{'limit':_0x375f1d[_0x58f7ed(0x1b8)]}:{}};}if(_0x375f1d[_0x58f7ed(0x1a0)]==='Reference'&&_0x375f1d['id'])return{'type':_0x375f1d[_0x58f7ed(0x1be)]?_0x58f7ed(0x1be):_0x58f7ed(0x1d0),'segment':_0x375f1d['id']};return{'type':_0x58f7ed(0x19a),'conditions':[]};}function isTemporalOperator(_0x27cf0a){const _0x370c66=a111_0x5430;return _0x27cf0a==='TimeWithinPast'||_0x27cf0a===_0x370c66(0x1a4);}function getEffectiveValue(_0x253594){const _0x1d1766=a111_0x5430,_0x1e5e74=_0x253594[_0x1d1766(0x1d7)];return _0x253594['value']??_0x1e5e74;}function apiOperatorToYaml(_0x7c42c4){const _0x1c1909=a111_0x5430;let _0x18ccd1;if(_0x7c42c4['rightValues']&&_0x7c42c4[_0x1c1909(0x197)][_0x1c1909(0x1e0)]>0x0)_0x18ccd1=_0x7c42c4['rightValues'];else{if(_0x7c42c4[_0x1c1909(0x187)]!==undefined)_0x18ccd1=_0x7c42c4[_0x1c1909(0x187)];else isTemporalOperator(_0x7c42c4[_0x1c1909(0x1a0)])&&_0x7c42c4[_0x1c1909(0x1ab)]!==undefined&&(_0x18ccd1=_0x7c42c4[_0x1c1909(0x1ab)]);}return{'type':mapApiOperatorType(_0x7c42c4[_0x1c1909(0x1a0)]),..._0x7c42c4[_0x1c1909(0x1eb)]&&{'not':_0x7c42c4['not']},..._0x18ccd1!==undefined&&{'value':_0x18ccd1},..._0x7c42c4[_0x1c1909(0x1d3)]&&{'unit':_0x7c42c4[_0x1c1909(0x1d3)]}};}function mapApiOperatorType(_0xde13bf){return _0xde13bf;}export function segmentDefToCreateRequest(_0x707fed,_0x4c553b){const _0x159312=a111_0x5430,_0x1ffc60={'name':_0x707fed[_0x159312(0x1c7)]};return _0x707fed[_0x159312(0x167)]&&(_0x1ffc60['description']=_0x707fed[_0x159312(0x167)]),_0x707fed[_0x159312(0x17e)]&&(_0x1ffc60[_0x159312(0x17e)]=yamlRuleToApi(_0x707fed[_0x159312(0x17e)])),_0x707fed['kind']&&(_0x1ffc60[_0x159312(0x176)]=_0x707fed[_0x159312(0x176)]==='batch'?0x0:_0x707fed[_0x159312(0x176)]===_0x159312(0x1b2)?0x1:0x2),_0x707fed['visible']!==undefined&&(_0x1ffc60[_0x159312(0x1b3)]=_0x707fed['visible']),_0x4c553b&&(_0x1ffc60['segmentFolderId']=_0x4c553b),_0x1ffc60;}export function segmentDefToUpdateRequest(_0x3380b9){const _0x2466a3=a111_0x5430,_0x557573={'name':_0x3380b9[_0x2466a3(0x1c7)]};return _0x3380b9[_0x2466a3(0x167)]!==undefined&&(_0x557573[_0x2466a3(0x167)]=_0x3380b9[_0x2466a3(0x167)]),_0x3380b9[_0x2466a3(0x17e)]&&(_0x557573[_0x2466a3(0x17e)]=yamlRuleToApi(_0x3380b9[_0x2466a3(0x17e)])),_0x3380b9[_0x2466a3(0x176)]&&(_0x557573[_0x2466a3(0x176)]=_0x3380b9[_0x2466a3(0x176)]==='batch'?0x0:_0x3380b9[_0x2466a3(0x176)]===_0x2466a3(0x1b2)?0x1:0x2),_0x557573;}export function yamlRuleToApi(_0x3ea9b4,_0x5a3db1=![]){const _0x365ea1=a111_0x5430,_0xb1735d=_0x3ea9b4[_0x365ea1(0x17c)][_0x365ea1(0x1d4)](yamlConditionToApi);if(_0x5a3db1){const _0x53bf9b=_0xb1735d[_0x365ea1(0x163)](_0x186dc2=>_0x186dc2[_0x365ea1(0x1a0)]==='And'||_0x186dc2[_0x365ea1(0x1a0)]==='Or');if(!_0x53bf9b&&_0xb1735d[_0x365ea1(0x1e0)]>0x0)return{'type':_0x3ea9b4[_0x365ea1(0x1a0)],'conditions':[{'type':'And','description':_0x3ea9b4[_0x365ea1(0x167)]||'','conditions':_0xb1735d}]};}return{'type':_0x3ea9b4[_0x365ea1(0x1a0)],'conditions':_0xb1735d,..._0x3ea9b4[_0x365ea1(0x167)]&&{'description':_0x3ea9b4[_0x365ea1(0x167)]}};}function yamlConditionToApi(_0x3cd8b5){const _0x5dc037=a111_0x5430;if(_0x5dc037(0x1ac)in _0x3cd8b5&&(_0x3cd8b5[_0x5dc037(0x1a0)]===_0x5dc037(0x1d0)||_0x3cd8b5['type']===_0x5dc037(0x1be))){const _0x4399f7=_0x3cd8b5;return{'type':'Reference','id':_0x4399f7[_0x5dc037(0x1ac)],'exclude':_0x4399f7['type']===_0x5dc037(0x1be)};}if(_0x5dc037(0x1a0)in _0x3cd8b5&&(_0x3cd8b5[_0x5dc037(0x1a0)]===_0x5dc037(0x19a)||_0x3cd8b5['type']==='Or')){const _0x48f293=_0x3cd8b5;return{'type':_0x48f293[_0x5dc037(0x1a0)],'conditions':_0x48f293[_0x5dc037(0x17c)][_0x5dc037(0x1d4)](yamlConditionToApi),..._0x48f293[_0x5dc037(0x167)]&&{'description':_0x48f293['description']}};}const _0x243f8b=_0x3cd8b5,_0x4e5037={'type':_0x5dc037(0x1dd),'leftValue':buildLeftValue(_0x243f8b),'operator':yamlOperatorToApi(_0x243f8b[_0x5dc037(0x1b4)]),'exclude':_0x243f8b[_0x5dc037(0x1be)]??![],'arrayMatching':_0x243f8b[_0x5dc037(0x169)]??'any'};return _0x243f8b[_0x5dc037(0x1b8)]!==undefined&&(_0x4e5037[_0x5dc037(0x1b8)]=_0x243f8b[_0x5dc037(0x1b8)]),_0x4e5037;}function buildLeftValue(_0x12aae2){const _0x5f347f=a111_0x5430,_0x4ba9dd={'name':_0x12aae2[_0x5f347f(0x1b0)]};return _0x12aae2['aggregation']&&(_0x4ba9dd[_0x5f347f(0x174)]={'type':_0x12aae2[_0x5f347f(0x174)][_0x5f347f(0x1a0)],..._0x12aae2[_0x5f347f(0x174)][_0x5f347f(0x1ed)]&&{'groupingColumns':_0x12aae2[_0x5f347f(0x174)][_0x5f347f(0x1ed)]}}),_0x12aae2[_0x5f347f(0x1db)]&&(_0x4ba9dd[_0x5f347f(0x1db)]={'name':_0x12aae2[_0x5f347f(0x1db)]}),_0x12aae2[_0x5f347f(0x165)]&&(_0x4ba9dd[_0x5f347f(0x165)]=yamlRuleToApi(_0x12aae2[_0x5f347f(0x165)])),_0x4ba9dd;}function yamlOperatorToApi(_0x2307fc){const _0x53e03a=a111_0x5430,_0x4a21da={'type':mapYamlOperatorType(_0x2307fc[_0x53e03a(0x1a0)]),'not':_0x2307fc['not']??![]},_0x3593e0=getEffectiveValue(_0x2307fc);if(_0x3593e0!==undefined){if(Array[_0x53e03a(0x1c2)](_0x3593e0))_0x4a21da['rightValues']=_0x3593e0;else isTemporalOperator(_0x2307fc[_0x53e03a(0x1a0)])?_0x4a21da[_0x53e03a(0x1ab)]=_0x3593e0:_0x4a21da[_0x53e03a(0x187)]=_0x3593e0;}return _0x2307fc[_0x53e03a(0x1d3)]&&(_0x4a21da['unit']=_0x2307fc[_0x53e03a(0x1d3)]),_0x4a21da;}function mapYamlOperatorType(_0x5e2205){return _0x5e2205;}function a111_0x5430(_0x284984,_0x9f8de8){_0x284984=_0x284984-0x162;const _0x17921f=a111_0x1792();let _0x5430f5=_0x17921f[_0x284984];return _0x5430f5;}export function toYamlString(_0x11b735){const _0x4bc0f6=a111_0x5430,_0x14f2c8=JSON[_0x4bc0f6(0x1b7)](JSON[_0x4bc0f6(0x1bf)](_0x11b735)),_0x5b0fab=a111_0x40a4dd[_0x4bc0f6(0x1bf)](_0x14f2c8,{'indent':0x2,'lineWidth':0x0,'nullStr':_0x4bc0f6(0x178)}),_0x25fb05=[_0x4bc0f6(0x17d)];let _0x5a6a3b=_0x5b0fab;for(const _0x18f671 of _0x25fb05){_0x5a6a3b=_0x5a6a3b[_0x4bc0f6(0x1ae)](new RegExp('^('+_0x18f671+')','m'),(_0x5192c4,_0x3a6cd4,_0x699061)=>{if(_0x699061===0x0||_0x5a6a3b[_0x699061-0x1]==='\x0a'&&_0x5a6a3b[_0x699061-0x2]==='\x0a')return _0x3a6cd4;return'\x0a'+_0x3a6cd4;});}return _0x5a6a3b;}export function parseYamlString(_0x1d38eb){const _0x3b94a8=a111_0x5430,_0xaaec35=a111_0x40a4dd[_0x3b94a8(0x1b7)](_0x1d38eb);if(!_0xaaec35['name'])throw new Error('YAML\x20config\x20missing\x20required\x20field:\x20name');if(_0xaaec35['type']&&_0xaaec35['type']!==_0x3b94a8(0x1ac))throw new Error(_0x3b94a8(0x1e4)+_0xaaec35[_0x3b94a8(0x1a0)]);return _0xaaec35;}export function isSegmentYaml(_0x13db3c){const _0x41718d=a111_0x5430;if(typeof _0x13db3c!=='object'||_0x13db3c===null)return![];const _0x40a0b2=_0x13db3c;return _0x40a0b2[_0x41718d(0x1a0)]===_0x41718d(0x1ac)||_0x40a0b2[_0x41718d(0x1a0)]===undefined;}export function generateTemplate(_0x258311='New\x20Segment'){const _0x236cf8=a111_0x5430,_0x42c7a3={'type':_0x236cf8(0x1ac),'name':_0x258311,'description':_0x236cf8(0x180),'rule':{'type':'And','conditions':[{'type':'Value','attribute':_0x236cf8(0x1e8),'operator':{'type':_0x236cf8(0x172),'value':_0x236cf8(0x1ab)}}]}};return toYamlString(_0x42c7a3);}export function segmentToYamlString(_0x3ef93e){const _0x334ec1=a111_0x5430,_0x702bc=JSON['parse'](JSON[_0x334ec1(0x1bf)](_0x3ef93e)),_0xde1cb8=a111_0x40a4dd['stringify'](_0x702bc,{'indent':0x2,'lineWidth':0x0,'nullStr':_0x334ec1(0x178)}),_0x42457c=[_0x334ec1(0x17d),_0x334ec1(0x1e1)];let _0x185e6d=_0xde1cb8;for(const _0x2797dd of _0x42457c){_0x185e6d=_0x185e6d[_0x334ec1(0x1ae)](new RegExp('^('+_0x2797dd+')','m'),(_0x395437,_0x1ed646,_0x360bcc)=>{if(_0x360bcc===0x0||_0x185e6d[_0x360bcc-0x1]==='\x0a'&&_0x185e6d[_0x360bcc-0x2]==='\x0a')return _0x1ed646;return'\x0a'+_0x1ed646;});}return _0x185e6d;}export function parseSegmentYamlFile(_0x47fc77){const _0x29bfba=a111_0x5430,_0x1023c4=a111_0x40a4dd[_0x29bfba(0x1b7)](_0x47fc77);if(!_0x1023c4['name'])throw new Error(_0x29bfba(0x1b9));return _0x1023c4;}export function normalizeChildSegmentYaml(_0x3bd947){const _0x30907f=a111_0x5430;return{'type':_0x30907f(0x1ac),'name':_0x3bd947[_0x30907f(0x1c7)],..._0x3bd947['description']!==undefined&&{'description':_0x3bd947[_0x30907f(0x167)]},..._0x3bd947[_0x30907f(0x19e)]!==undefined&&{'folder':_0x3bd947['folder']},..._0x3bd947[_0x30907f(0x17e)]&&{'rule':normalizeRule(_0x3bd947['rule'])},..._0x3bd947[_0x30907f(0x176)]!==undefined&&{'kind':_0x3bd947['kind']},..._0x3bd947['visible']!==undefined&&{'visible':_0x3bd947[_0x30907f(0x1c5)]},..._0x3bd947[_0x30907f(0x19f)]&&{'activations':_0x3bd947[_0x30907f(0x19f)][_0x30907f(0x1d4)](normalizeActivation)}};}export function normalizeRule(_0x11b2c6){const _0x460017=a111_0x5430;return{'type':_0x11b2c6['type'],'conditions':_0x11b2c6['conditions'][_0x460017(0x1d4)](normalizeCondition),..._0x11b2c6[_0x460017(0x167)]!==undefined&&{'description':_0x11b2c6[_0x460017(0x167)]}};}function normalizeCondition(_0x714333){const _0x4a3715=a111_0x5430;if(_0x4a3715(0x1ac)in _0x714333&&(_0x714333[_0x4a3715(0x1a0)]===_0x4a3715(0x1d0)||_0x714333[_0x4a3715(0x1a0)]===_0x4a3715(0x1be))){const _0x7410db=_0x714333;return{'type':_0x7410db[_0x4a3715(0x1a0)],'segment':_0x7410db['segment']};}if('type'in _0x714333&&(_0x714333['type']===_0x4a3715(0x19a)||_0x714333['type']==='Or')){const _0x20de79=_0x714333;return{'type':_0x20de79[_0x4a3715(0x1a0)],'conditions':_0x20de79[_0x4a3715(0x17c)][_0x4a3715(0x1d4)](normalizeCondition),..._0x20de79[_0x4a3715(0x167)]!==undefined&&{'description':_0x20de79[_0x4a3715(0x167)]}};}const _0x45d56f=_0x714333;return{'type':_0x4a3715(0x1dd),'attribute':_0x45d56f['attribute'],'operator':normalizeOperator(_0x45d56f[_0x4a3715(0x1b4)]),..._0x45d56f[_0x4a3715(0x169)]!==undefined&&{'arrayMatching':_0x45d56f[_0x4a3715(0x169)]},..._0x45d56f['exclude']!==undefined&&{'exclude':_0x45d56f[_0x4a3715(0x1be)]},..._0x45d56f[_0x4a3715(0x174)]!==undefined&&{'aggregation':_0x45d56f['aggregation']},..._0x45d56f['source']!==undefined&&{'source':_0x45d56f[_0x4a3715(0x1db)]},..._0x45d56f[_0x4a3715(0x165)]!==undefined&&{'filter':normalizeRule(_0x45d56f[_0x4a3715(0x165)])},..._0x45d56f[_0x4a3715(0x1b8)]!==undefined&&{'limit':_0x45d56f[_0x4a3715(0x1b8)]}};}function normalizeOperator(_0x4698d8){const _0x33d54b=a111_0x5430,_0x41a9f8=getEffectiveValue(_0x4698d8);return{'type':_0x4698d8[_0x33d54b(0x1a0)],..._0x4698d8[_0x33d54b(0x1eb)]!==undefined&&{'not':_0x4698d8[_0x33d54b(0x1eb)]},..._0x41a9f8!==undefined&&{'value':_0x41a9f8},..._0x4698d8['min']!==undefined&&{'min':_0x4698d8['min']},..._0x4698d8['max']!==undefined&&{'max':_0x4698d8['max']},..._0x4698d8[_0x33d54b(0x1d3)]!==undefined&&{'unit':_0x4698d8[_0x33d54b(0x1d3)]},..._0x4698d8[_0x33d54b(0x1ad)]!==undefined&&{'duration':_0x4698d8['duration']},..._0x4698d8[_0x33d54b(0x194)]!==undefined&&{'from':_0x4698d8['from']}};}function normalizeActivation(_0x14e91f){const _0x7e298b=a111_0x5430;return{'name':_0x14e91f[_0x7e298b(0x1c7)],'connection':_0x14e91f[_0x7e298b(0x186)],..._0x14e91f[_0x7e298b(0x167)]!==undefined&&{'description':_0x14e91f[_0x7e298b(0x167)]},..._0x14e91f[_0x7e298b(0x168)]!==undefined&&{'all_columns':_0x14e91f[_0x7e298b(0x168)]},..._0x14e91f['columns']!==undefined&&{'columns':_0x14e91f[_0x7e298b(0x1e5)]},..._0x14e91f[_0x7e298b(0x1da)]!==undefined&&{'behavior':_0x14e91f['behavior']},..._0x14e91f['schedule']!==undefined&&{'schedule':_0x14e91f[_0x7e298b(0x1df)]},..._0x14e91f[_0x7e298b(0x16f)]!==undefined&&{'notification':_0x14e91f['notification']},..._0x14e91f[_0x7e298b(0x1d9)]!==undefined&&{'connector_config':_0x14e91f[_0x7e298b(0x1d9)]},..._0x14e91f['activation_template_id']!==undefined&&{'activation_template_id':_0x14e91f[_0x7e298b(0x192)]}};}export function activationResponseToDef(_0x299dc4,_0x373ce6,_0x5625f4){const _0x4d1d68=a111_0x5430,_0x41a561=_0x299dc4[_0x4d1d68(0x1a5)]||'',_0x56dcbc=_0x5625f4?.[_0x4d1d68(0x17a)](_0x41a561)??_0x41a561,_0x514bca={'name':_0x299dc4[_0x4d1d68(0x1c7)],'connection':_0x56dcbc};_0x299dc4[_0x4d1d68(0x167)]&&(_0x514bca[_0x4d1d68(0x167)]=_0x299dc4[_0x4d1d68(0x167)]);let _0x53bb72=[];_0x299dc4[_0x4d1d68(0x1e5)]&&_0x299dc4[_0x4d1d68(0x1e5)][_0x4d1d68(0x1e0)]>0x0&&(_0x53bb72=_0x299dc4[_0x4d1d68(0x1e5)][_0x4d1d68(0x165)](_0x46aab0=>_0x46aab0&&_0x46aab0[_0x4d1d68(0x1c7)])[_0x4d1d68(0x1d4)](_0x2df4f0=>{const _0xcb2a80=_0x4d1d68;if(_0x2df4f0[_0xcb2a80(0x1a0)]||_0x2df4f0[_0xcb2a80(0x1c9)])return{'name':_0x2df4f0[_0xcb2a80(0x1c7)],..._0x2df4f0[_0xcb2a80(0x1a0)]&&{'type':_0x2df4f0[_0xcb2a80(0x1a0)]},..._0x2df4f0[_0xcb2a80(0x1c9)]&&{'visibility':_0x2df4f0['visibility']}};return _0x2df4f0['name'];}));_0x53bb72[_0x4d1d68(0x1e0)]>0x0&&(_0x514bca[_0x4d1d68(0x1e5)]=_0x53bb72);_0x299dc4[_0x4d1d68(0x177)]!==undefined&&(_0x299dc4[_0x4d1d68(0x177)]===![]&&_0x53bb72[_0x4d1d68(0x1e0)]===0x0?_0x514bca['all_columns']=!![]:_0x514bca[_0x4d1d68(0x168)]=_0x299dc4[_0x4d1d68(0x177)]);const _0x130fd6={};let _0x541fff=![];_0x299dc4['scheduleType']&&(_0x130fd6[_0x4d1d68(0x1a0)]=_0x299dc4[_0x4d1d68(0x185)],_0x541fff=!![]);_0x299dc4[_0x4d1d68(0x18d)]&&(_0x130fd6[_0x4d1d68(0x1b6)]=_0x299dc4['repeatUnit'],_0x541fff=!![]);_0x299dc4[_0x4d1d68(0x184)]!==undefined&&_0x299dc4[_0x4d1d68(0x184)]!==null&&(_0x130fd6[_0x4d1d68(0x1e7)]=_0x299dc4['repeatFrequency'],_0x541fff=!![]);_0x299dc4[_0x4d1d68(0x16d)]&&_0x299dc4[_0x4d1d68(0x16d)][_0x4d1d68(0x1e0)]>0x0&&(_0x130fd6['repeat_sub_frequency']=_0x299dc4[_0x4d1d68(0x16d)],_0x541fff=!![]);_0x299dc4['startAt']!==undefined&&(_0x130fd6[_0x4d1d68(0x1a2)]=_0x299dc4[_0x4d1d68(0x1f0)],_0x541fff=!![]);_0x299dc4[_0x4d1d68(0x1c6)]!==undefined&&(_0x130fd6[_0x4d1d68(0x16e)]=_0x299dc4[_0x4d1d68(0x1c6)],_0x541fff=!![]);_0x299dc4['timezone']&&(_0x130fd6[_0x4d1d68(0x1a7)]=_0x299dc4[_0x4d1d68(0x1a7)],_0x541fff=!![]);_0x541fff&&(_0x514bca[_0x4d1d68(0x1df)]=_0x130fd6);(_0x299dc4[_0x4d1d68(0x19c)]&&_0x299dc4[_0x4d1d68(0x19c)][_0x4d1d68(0x1e0)]>0x0||_0x299dc4['emailRecipients']&&_0x299dc4[_0x4d1d68(0x181)][_0x4d1d68(0x1e0)]>0x0)&&(_0x514bca[_0x4d1d68(0x16f)]={},_0x299dc4[_0x4d1d68(0x19c)]&&_0x299dc4[_0x4d1d68(0x19c)]['length']>0x0&&(_0x514bca[_0x4d1d68(0x16f)][_0x4d1d68(0x1bd)]=_0x299dc4[_0x4d1d68(0x19c)]),_0x299dc4[_0x4d1d68(0x181)]&&_0x299dc4[_0x4d1d68(0x181)]['length']>0x0&&(_0x514bca[_0x4d1d68(0x16f)][_0x4d1d68(0x1a6)]=_0x299dc4[_0x4d1d68(0x181)][_0x4d1d68(0x1d4)](_0x239cf6=>{const _0x44f8fc=_0x4d1d68,_0x40ff14=_0x373ce6?.[_0x44f8fc(0x17a)](_0x239cf6);return _0x40ff14??String(_0x239cf6);})));_0x299dc4[_0x4d1d68(0x1ec)]&&Object[_0x4d1d68(0x193)](_0x299dc4[_0x4d1d68(0x1ec)])[_0x4d1d68(0x1e0)]>0x0&&(_0x514bca[_0x4d1d68(0x1d9)]=normalizeConnectorConfigForYaml(_0x299dc4[_0x4d1d68(0x1ec)]));_0x299dc4[_0x4d1d68(0x1c1)]&&(_0x514bca[_0x4d1d68(0x192)]=_0x299dc4[_0x4d1d68(0x1c1)]);if(_0x299dc4[_0x4d1d68(0x166)]){const _0x30773f={},_0x5b9d4c=_0x299dc4[_0x4d1d68(0x166)];_0x5b9d4c[_0x4d1d68(0x1e5)]&&_0x5b9d4c['columns'][_0x4d1d68(0x1e0)]>0x0&&(_0x30773f[_0x4d1d68(0x1e5)]=_0x5b9d4c['columns'][_0x4d1d68(0x165)](_0x53dd69=>_0x53dd69&&_0x53dd69['name'])[_0x4d1d68(0x1d4)](_0x3455d5=>({'name':_0x3455d5[_0x4d1d68(0x1c7)],..._0x3455d5[_0x4d1d68(0x1a0)]&&{'type':_0x3455d5[_0x4d1d68(0x1a0)]},..._0x3455d5[_0x4d1d68(0x1c9)]&&{'visibility':_0x3455d5[_0x4d1d68(0x1c9)]}}))),_0x5b9d4c[_0x4d1d68(0x16a)]&&(_0x30773f[_0x4d1d68(0x1de)]=_0x5b9d4c[_0x4d1d68(0x16a)]),_0x5b9d4c['joinRow']!==undefined&&(_0x30773f[_0x4d1d68(0x1ba)]=_0x5b9d4c[_0x4d1d68(0x1ea)]),_0x5b9d4c['joinStrategy']&&(_0x30773f[_0x4d1d68(0x1d6)]=_0x5b9d4c['joinStrategy']),_0x5b9d4c[_0x4d1d68(0x19d)]&&(_0x30773f[_0x4d1d68(0x19d)]=_0x5b9d4c[_0x4d1d68(0x19d)]),_0x5b9d4c[_0x4d1d68(0x1a8)]&&_0x5b9d4c[_0x4d1d68(0x1a8)]['length']>0x0&&(_0x30773f[_0x4d1d68(0x1e2)]=_0x5b9d4c[_0x4d1d68(0x1a8)]),Object[_0x4d1d68(0x193)](_0x30773f)['length']>0x0&&(_0x514bca[_0x4d1d68(0x1da)]=_0x30773f);}return _0x514bca;}export function journeyActivationStepToYaml(_0x25884e,_0x404471,_0x3f5b6e){const _0x1f30ad=a111_0x5430,_0x2e0640=_0x25884e['attributes']['activationParams'],_0x1171c3=_0x2e0640[_0x1f30ad(0x1a5)]||'',_0xd782e=_0x3f5b6e?.['get'](_0x1171c3)??_0x1171c3,_0x4ab030={'name':_0x2e0640[_0x1f30ad(0x1c7)]||'','connection':_0xd782e};_0x2e0640['description']&&(_0x4ab030[_0x1f30ad(0x167)]=_0x2e0640[_0x1f30ad(0x167)]);let _0x65ead2=[];_0x2e0640['columns']&&_0x2e0640[_0x1f30ad(0x1e5)][_0x1f30ad(0x1e0)]>0x0&&(_0x65ead2=_0x2e0640['columns']['filter'](_0x1cbf03=>_0x1cbf03&&_0x1cbf03[_0x1f30ad(0x1c7)])[_0x1f30ad(0x1d4)](_0x2f208f=>{const _0x45f591=_0x1f30ad;if(_0x2f208f[_0x45f591(0x1a0)]||_0x2f208f[_0x45f591(0x1c9)])return{'name':_0x2f208f[_0x45f591(0x1c7)],..._0x2f208f['type']&&{'type':_0x2f208f[_0x45f591(0x1a0)]},..._0x2f208f[_0x45f591(0x1c9)]&&{'visibility':_0x2f208f[_0x45f591(0x1c9)]}};return _0x2f208f[_0x45f591(0x1c7)];}));_0x65ead2[_0x1f30ad(0x1e0)]>0x0&&(_0x4ab030['columns']=_0x65ead2);_0x2e0640['allColumns']!==undefined&&(_0x2e0640['allColumns']===![]&&_0x65ead2[_0x1f30ad(0x1e0)]===0x0?_0x4ab030['all_columns']=!![]:_0x4ab030[_0x1f30ad(0x168)]=_0x2e0640[_0x1f30ad(0x177)]);const _0x52a754={};let _0x26e9b9=![];_0x2e0640[_0x1f30ad(0x185)]&&(_0x52a754[_0x1f30ad(0x1a0)]=_0x2e0640[_0x1f30ad(0x185)],_0x26e9b9=!![]);_0x2e0640[_0x1f30ad(0x18d)]&&(_0x52a754[_0x1f30ad(0x1b6)]=_0x2e0640[_0x1f30ad(0x18d)],_0x26e9b9=!![]);_0x2e0640[_0x1f30ad(0x184)]!==undefined&&_0x2e0640[_0x1f30ad(0x184)]!==null&&(_0x52a754[_0x1f30ad(0x1e7)]=_0x2e0640[_0x1f30ad(0x184)],_0x26e9b9=!![]);_0x2e0640[_0x1f30ad(0x1f0)]!==undefined&&(_0x52a754['start_at']=_0x2e0640[_0x1f30ad(0x1f0)],_0x26e9b9=!![]);_0x2e0640[_0x1f30ad(0x1c6)]!==undefined&&(_0x52a754['end_on']=_0x2e0640['endOn'],_0x26e9b9=!![]);_0x2e0640[_0x1f30ad(0x1a7)]&&(_0x52a754[_0x1f30ad(0x1a7)]=_0x2e0640[_0x1f30ad(0x1a7)],_0x26e9b9=!![]);_0x26e9b9&&(_0x4ab030[_0x1f30ad(0x1df)]=_0x52a754);(_0x2e0640['notifyOn']&&_0x2e0640[_0x1f30ad(0x19c)][_0x1f30ad(0x1e0)]>0x0||_0x2e0640[_0x1f30ad(0x181)]&&_0x2e0640[_0x1f30ad(0x181)][_0x1f30ad(0x1e0)]>0x0)&&(_0x4ab030[_0x1f30ad(0x16f)]={},_0x2e0640[_0x1f30ad(0x19c)]&&_0x2e0640['notifyOn'][_0x1f30ad(0x1e0)]>0x0&&(_0x4ab030[_0x1f30ad(0x16f)][_0x1f30ad(0x1bd)]=_0x2e0640['notifyOn']),_0x2e0640[_0x1f30ad(0x181)]&&_0x2e0640[_0x1f30ad(0x181)][_0x1f30ad(0x1e0)]>0x0&&(_0x4ab030[_0x1f30ad(0x16f)]['email_recipients']=_0x2e0640[_0x1f30ad(0x181)]['map'](_0x58777e=>{const _0x49506b=_0x1f30ad,_0x474d89=_0x404471?.[_0x49506b(0x17a)](_0x58777e);return _0x474d89??String(_0x58777e);})));_0x2e0640['connectorConfig']&&Object[_0x1f30ad(0x193)](_0x2e0640[_0x1f30ad(0x1ec)])[_0x1f30ad(0x1e0)]>0x0&&(_0x4ab030[_0x1f30ad(0x1d9)]=normalizeConnectorConfigForYaml(_0x2e0640[_0x1f30ad(0x1ec)]));_0x2e0640[_0x1f30ad(0x1c1)]&&(_0x4ab030[_0x1f30ad(0x192)]=_0x2e0640[_0x1f30ad(0x1c1)]);if(_0x2e0640[_0x1f30ad(0x166)]){const _0x8eee03={},_0x406b2b=_0x2e0640[_0x1f30ad(0x166)];_0x406b2b[_0x1f30ad(0x1e5)]&&_0x406b2b['columns'][_0x1f30ad(0x1e0)]>0x0&&(_0x8eee03[_0x1f30ad(0x1e5)]=_0x406b2b[_0x1f30ad(0x1e5)][_0x1f30ad(0x165)](_0xd97a19=>_0xd97a19&&_0xd97a19[_0x1f30ad(0x1c7)])[_0x1f30ad(0x1d4)](_0x4c3966=>({'name':_0x4c3966[_0x1f30ad(0x1c7)],..._0x4c3966[_0x1f30ad(0x1a0)]&&{'type':_0x4c3966['type']},..._0x4c3966[_0x1f30ad(0x1c9)]&&{'visibility':_0x4c3966['visibility']}}))),_0x406b2b[_0x1f30ad(0x16a)]&&(_0x8eee03[_0x1f30ad(0x1de)]=_0x406b2b[_0x1f30ad(0x16a)]),_0x406b2b['joinRow']!==undefined&&(_0x8eee03['join_row']=_0x406b2b['joinRow']),_0x406b2b[_0x1f30ad(0x175)]&&(_0x8eee03[_0x1f30ad(0x1d6)]=_0x406b2b[_0x1f30ad(0x175)]),_0x406b2b[_0x1f30ad(0x19d)]&&(_0x8eee03['formatting']=_0x406b2b[_0x1f30ad(0x19d)]),_0x406b2b[_0x1f30ad(0x1a8)]&&_0x406b2b[_0x1f30ad(0x1a8)][_0x1f30ad(0x1e0)]>0x0&&(_0x8eee03[_0x1f30ad(0x1e2)]=_0x406b2b[_0x1f30ad(0x1a8)]),Object[_0x1f30ad(0x193)](_0x8eee03)[_0x1f30ad(0x1e0)]>0x0&&(_0x4ab030[_0x1f30ad(0x1da)]=_0x8eee03);}return _0x4ab030;}export function segmentWithActivationsToYaml(_0x4d65b0,_0x232dbf,_0x51d560,_0x176ef5,_0x31b4b0){const _0x500a3c=a111_0x5430,_0x444a01=segmentResponseToDefSync(_0x4d65b0,_0x51d560);return _0x232dbf['length']>0x0&&(_0x444a01[_0x500a3c(0x19f)]=_0x232dbf['map'](_0x22d59a=>activationResponseToDef(_0x22d59a,_0x176ef5,_0x31b4b0))),_0x444a01;}function normalizeColumn(_0x14e49b){const _0xf96598=a111_0x5430;if(typeof _0x14e49b===_0xf96598(0x1ce))return{'name':_0x14e49b};return{'name':_0x14e49b[_0xf96598(0x1c7)],..._0x14e49b['type']&&{'type':_0x14e49b[_0xf96598(0x1a0)]},..._0x14e49b[_0xf96598(0x1c9)]&&{'visibility':_0x14e49b[_0xf96598(0x1c9)]}};}function a111_0x1792(){const _0x582231=['arrayMatching','behaviorTableName','all','CONNECTOR_INVALID_CONFIG','repeatSubFrequency','end_on','notification','82032vsQtrT','4685817fjPxSp','Equal','add','aggregation','joinStrategy','kind','allColumns','null','403621XWJCao','get','funnel_stage','conditions','rule:','rule','errors','Segment\x20description','emailRecipients','batch','has','repeatFrequency','scheduleType','connection','rightValue','Invalid\x20connector_config\x20for\x20activation\x20\x22','usedNames','emailToIdMap','4rJANYN','repeat_sub_frequency','repeatUnit','resolveSegmentName','\x27:\x20','Please\x20specify\x20a\x20valid\x20attribute\x20name.','__SEGMENT_REF__','activation_template_id','keys','from','JOURNEY_SYNTAX_ERROR','].attribute\x20cannot\x20be\x20empty.\x0a','rightValues','__UNRESOLVED__','Unknown\x20email\x20recipient:\x20','And','CONNECTION_NOT_FOUND','notifyOn','formatting','folder','activations','type','warnings','start_at','code','TimeWithinNext','connectionId','email_recipients','timezone','orderBy','Connector:\x20','push','value','segment','duration','replace','connectionNameToTypeMap','attribute','test','realtime','isVisible','operator','leftValue','repeat_unit','parse','limit','YAML\x20config\x20missing\x20required\x20field:\x20name','join_row','Use\x20\x27tdx\x20connections\x27\x20to\x20list\x20available\x20connections','sort','notify_on','exclude','stringify','16sjgBMP','activationTemplateId','isArray','connectionNameToIdMap','11gBYFyO','visible','endOn','name','set','visibility','valid','localRuleToName','toLowerCase','ruleHashToName','string','any','include','484QRJulJ','object','unit','map','3870517XBvqas','join_strategy','values','7755wOzVfQ','connector_config','behavior','source','connector_config\x20for\x20activation\x20\x22','Value','behavior_table','schedule','length','activations:','order_by','13297610Nrhvtn','YAML\x20type\x20must\x20be\x20\x27segment\x27\x20or\x20omitted,\x20got:\x20','columns','localeCompare','repeat_frequency','attribute_name','\x0a\x0aAvailable\x20fields:\x0a','joinRow','not','connectorConfig','groupingColumns','\x22:\x0a','getSchema','startAt','13631634lPizgq','every','.\x20Use\x20\x27tdx\x20user\x20list\x27\x20to\x20see\x20valid\x20emails.','filter','syndicationBehavior','description','all_columns'];a111_0x1792=function(){return _0x582231;};return a111_0x1792();}export async function activationDefToCreateRequest(_0x576e8c,_0x404019){const _0x2529ec=a111_0x5430,_0x53736c=_0x404019?.[_0x2529ec(0x18a)],_0x5674f1=_0x404019?.[_0x2529ec(0x1c3)],_0x43afa2=_0x576e8c[_0x2529ec(0x186)];let _0x5cd20d;const _0x3690d3=parseInt(_0x43afa2,0xa);if(!isNaN(_0x3690d3)&&String(_0x3690d3)===_0x43afa2)_0x5cd20d=_0x3690d3;else{const _0x1aae12=_0x5674f1?.[_0x2529ec(0x17a)](_0x43afa2);if(_0x1aae12===undefined)throw new SDKError(ErrorCode[_0x2529ec(0x19b)],'Unknown\x20connection:\x20'+_0x43afa2,undefined,{'helpText':_0x2529ec(0x1bb)});_0x5cd20d=_0x1aae12;}const _0x31e999={'name':_0x576e8c['name'],'connectionId':_0x5cd20d};_0x576e8c[_0x2529ec(0x167)]&&(_0x31e999[_0x2529ec(0x167)]=_0x576e8c[_0x2529ec(0x167)]);let _0x402dc4=[];_0x576e8c[_0x2529ec(0x1e5)]&&_0x576e8c[_0x2529ec(0x1e5)][_0x2529ec(0x1e0)]>0x0&&(_0x402dc4=_0x576e8c[_0x2529ec(0x1e5)]['filter'](_0x3e327f=>_0x3e327f!=null)[_0x2529ec(0x1d4)](normalizeColumn));_0x402dc4[_0x2529ec(0x1e0)]>0x0&&(_0x31e999['columns']=_0x402dc4);_0x576e8c['all_columns']!==undefined&&(_0x576e8c[_0x2529ec(0x168)]===![]&&_0x402dc4['length']===0x0?_0x31e999[_0x2529ec(0x177)]=!![]:_0x31e999['allColumns']=_0x576e8c['all_columns']);if(_0x576e8c[_0x2529ec(0x1df)]){const _0x4fbeba=_0x576e8c[_0x2529ec(0x1df)];_0x4fbeba[_0x2529ec(0x1a0)]&&(_0x31e999[_0x2529ec(0x185)]=_0x4fbeba['type']),_0x4fbeba[_0x2529ec(0x1b6)]&&(_0x31e999['repeatUnit']=_0x4fbeba[_0x2529ec(0x1b6)]),_0x4fbeba[_0x2529ec(0x1e7)]!==undefined&&(_0x31e999['repeatFrequency']=_0x4fbeba['repeat_frequency']),_0x4fbeba[_0x2529ec(0x18c)]&&(_0x31e999['repeatSubFrequency']=_0x4fbeba[_0x2529ec(0x18c)]),_0x4fbeba[_0x2529ec(0x1a2)]!==undefined&&(_0x31e999[_0x2529ec(0x1f0)]=_0x4fbeba['start_at']),_0x4fbeba['end_on']!==undefined&&(_0x31e999[_0x2529ec(0x1c6)]=_0x4fbeba[_0x2529ec(0x16e)]),_0x4fbeba['timezone']&&(_0x31e999[_0x2529ec(0x1a7)]=_0x4fbeba['timezone']);}_0x576e8c[_0x2529ec(0x16f)]&&(_0x576e8c[_0x2529ec(0x16f)]['notify_on']&&(_0x31e999['notifyOn']=_0x576e8c[_0x2529ec(0x16f)][_0x2529ec(0x1bd)]),_0x576e8c[_0x2529ec(0x16f)][_0x2529ec(0x1a6)]&&(_0x31e999[_0x2529ec(0x181)]=_0x576e8c[_0x2529ec(0x16f)][_0x2529ec(0x1a6)][_0x2529ec(0x1d4)](_0x168218=>{const _0x350375=_0x2529ec,_0x760df1=Number(_0x168218);if(!isNaN(_0x760df1)&&String(_0x760df1)===_0x168218)return _0x760df1;const _0x36fd21=_0x53736c?.['get'](_0x168218[_0x350375(0x1cc)]());if(_0x36fd21===undefined)throw new SDKError(ErrorCode['INVALID_ARGUMENT'],_0x350375(0x199)+_0x168218+_0x350375(0x164));return _0x36fd21;})));if(_0x576e8c['connector_config']){const _0x25de59=_0x404019?.[_0x2529ec(0x1af)]?.['get'](_0x43afa2);if(_0x25de59&&_0x404019?.[_0x2529ec(0x1ef)])try{const _0x5fd9af=await _0x404019[_0x2529ec(0x1ef)](_0x25de59),_0x378b3b=validateConnectorConfig(_0x576e8c['connector_config'],_0x5fd9af);if(!_0x378b3b[_0x2529ec(0x1ca)])throw new SDKError(ErrorCode[_0x2529ec(0x16c)],_0x2529ec(0x188)+_0x576e8c[_0x2529ec(0x1c7)]+_0x2529ec(0x1ee)+formatValidationErrors(_0x378b3b[_0x2529ec(0x17f)]),undefined,{'helpText':_0x2529ec(0x1a9)+_0x25de59+_0x2529ec(0x1e9)+formatSchemaAsHelp(_0x5fd9af)});if(_0x378b3b[_0x2529ec(0x1a1)][_0x2529ec(0x1e0)]>0x0){const _0x53744d=formatValidationWarnings(_0x378b3b[_0x2529ec(0x1a1)]);console['warn'](_0x2529ec(0x1dc)+_0x576e8c[_0x2529ec(0x1c7)]+_0x2529ec(0x1ee)+_0x53744d);}_0x31e999[_0x2529ec(0x1ec)]=transformConfigToLegacy(_0x576e8c[_0x2529ec(0x1d9)],_0x5fd9af);}catch(_0x5c2a00){if(_0x5c2a00 instanceof SDKError&&_0x5c2a00[_0x2529ec(0x1a3)]===ErrorCode['CONNECTOR_SCHEMA_NOT_FOUND'])_0x31e999[_0x2529ec(0x1ec)]=_0x576e8c[_0x2529ec(0x1d9)];else throw _0x5c2a00;}else _0x31e999[_0x2529ec(0x1ec)]=_0x576e8c['connector_config'];}_0x576e8c['activation_template_id']!==undefined&&(_0x31e999[_0x2529ec(0x1c1)]=_0x576e8c[_0x2529ec(0x192)]);if(_0x576e8c['behavior']){const _0x4bd555=_0x576e8c['behavior'],_0x46e423={};if(_0x4bd555[_0x2529ec(0x1e5)]&&_0x4bd555['columns'][_0x2529ec(0x1e0)]>0x0){const _0x4acaf2=_0x4bd555[_0x2529ec(0x1e5)]['filter'](_0xf91f8c=>_0xf91f8c&&_0xf91f8c['name']);_0x4acaf2[_0x2529ec(0x1e0)]>0x0&&(_0x46e423[_0x2529ec(0x1e5)]=_0x4acaf2);}_0x4bd555[_0x2529ec(0x1de)]&&(_0x46e423[_0x2529ec(0x16a)]=_0x4bd555[_0x2529ec(0x1de)]),_0x4bd555[_0x2529ec(0x1ba)]!==undefined&&(_0x46e423[_0x2529ec(0x1ea)]=_0x4bd555[_0x2529ec(0x1ba)]),_0x4bd555[_0x2529ec(0x1d6)]&&(_0x46e423['joinStrategy']=_0x4bd555[_0x2529ec(0x1d6)]),_0x4bd555[_0x2529ec(0x19d)]&&(_0x46e423[_0x2529ec(0x19d)]=_0x4bd555[_0x2529ec(0x19d)]),_0x4bd555[_0x2529ec(0x1e2)]&&(_0x46e423[_0x2529ec(0x1a8)]=_0x4bd555[_0x2529ec(0x1e2)]),_0x31e999['syndicationBehavior']=_0x46e423;}return _0x31e999;}export async function activationDefToUpdateRequest(_0x40d34e,_0x44c4bf){return activationDefToCreateRequest(_0x40d34e,_0x44c4bf);}export function deepSortObject(_0x15c3fa){const _0x2ef002=a111_0x5430;if(_0x15c3fa===null||typeof _0x15c3fa!==_0x2ef002(0x1d2))return _0x15c3fa;if(Array[_0x2ef002(0x1c2)](_0x15c3fa))return _0x15c3fa[_0x2ef002(0x1d4)](deepSortObject)[_0x2ef002(0x1bc)]((_0x1041fc,_0x67577b)=>JSON[_0x2ef002(0x1bf)](_0x1041fc)[_0x2ef002(0x1e6)](JSON['stringify'](_0x67577b)));const _0x1044af={};for(const _0x57134c of Object['keys'](_0x15c3fa)[_0x2ef002(0x1bc)]()){_0x1044af[_0x57134c]=deepSortObject(_0x15c3fa[_0x57134c]);}return _0x1044af;}export function serializeRule(_0x36be46){const _0x140959=a111_0x5430;return JSON[_0x140959(0x1bf)](deepSortObject(_0x36be46));}export function normalizeRuleForMatching(_0x348efc){return normalizeConditionsForMatching(_0x348efc);}function normalizeConditionsForMatching(_0x4c7faf){const _0xe304c5=a111_0x5430;if(_0x4c7faf===null||typeof _0x4c7faf!==_0xe304c5(0x1d2))return _0x4c7faf;if(Array[_0xe304c5(0x1c2)](_0x4c7faf))return _0x4c7faf[_0xe304c5(0x1d4)](normalizeConditionsForMatching);const _0x659d37=_0x4c7faf;if((_0x659d37[_0xe304c5(0x1a0)]===_0xe304c5(0x1d0)||_0x659d37[_0xe304c5(0x1a0)]===_0xe304c5(0x1be))&&typeof _0x659d37[_0xe304c5(0x1ac)]===_0xe304c5(0x1ce))return{..._0x659d37,'segment':_0xe304c5(0x191)};const _0xe252cd={};for(const _0x3cc81b of Object[_0xe304c5(0x193)](_0x659d37)){_0xe252cd[_0x3cc81b]=normalizeConditionsForMatching(_0x659d37[_0x3cc81b]);}return _0xe252cd;}export function serializeRuleForMatching(_0x303120){const _0x1fee7f=a111_0x5430;return JSON[_0x1fee7f(0x1bf)](deepSortObject(normalizeRuleForMatching(_0x303120)));}export function expandSegmentReferences(_0x3591a6,_0x1676cc,_0x195c7d=new Set()){return expandConditions(_0x3591a6,_0x1676cc,_0x195c7d);}function expandConditions(_0x4a7e0a,_0x2ac767,_0xa8076b){const _0x2147be=a111_0x5430;if(_0x4a7e0a===null||typeof _0x4a7e0a!=='object')return _0x4a7e0a;if(Array[_0x2147be(0x1c2)](_0x4a7e0a))return _0x4a7e0a[_0x2147be(0x1d4)](_0x13be6b=>expandConditions(_0x13be6b,_0x2ac767,_0xa8076b));const _0x333d8=_0x4a7e0a;if((_0x333d8[_0x2147be(0x1a0)]===_0x2147be(0x1d0)||_0x333d8[_0x2147be(0x1a0)]==='exclude')&&typeof _0x333d8[_0x2147be(0x1ac)]==='string'){const _0x156bea=_0x333d8[_0x2147be(0x1ac)],_0x59b46a=_0x2ac767[_0x2147be(0x17a)](_0x156bea);if(_0x59b46a&&!_0xa8076b[_0x2147be(0x183)](_0x156bea)){const _0xfeb609=new Set(_0xa8076b);_0xfeb609['add'](_0x156bea);const _0x277ab2=expandConditions(_0x59b46a,_0x2ac767,_0xfeb609);return{'type':_0x333d8[_0x2147be(0x1a0)],'expanded_rule':_0x277ab2};}return{'type':_0x333d8[_0x2147be(0x1a0)],'expanded_rule':_0x2147be(0x198)};}const _0x579a8d={};for(const _0x44a27d of Object[_0x2147be(0x193)](_0x333d8)){_0x579a8d[_0x44a27d]=expandConditions(_0x333d8[_0x44a27d],_0x2ac767,_0xa8076b);}return _0x579a8d;}export function serializeExpandedRule(_0x526497,_0x1e289c){const _0x4ced4f=a111_0x5430,_0x516f83=expandSegmentReferences(_0x526497,_0x1e289c);return JSON[_0x4ced4f(0x1bf)](deepSortObject(_0x516f83));}export function createSegmentNameContext(_0x31c6a7){const _0x4e9fed=a111_0x5430,_0x493705=new Set(),_0x40145c=new Map(),_0x30d871=new Map();if(_0x31c6a7)for(const [_0x3dcd75,_0xf0e3e]of Object['entries'](_0x31c6a7)){if(_0xf0e3e['rule']){const _0x1f409a=serializeRule(_0xf0e3e[_0x4e9fed(0x17e)]);_0x30d871[_0x4e9fed(0x1c8)](_0x1f409a,_0x3dcd75),_0x493705[_0x4e9fed(0x173)](_0x3dcd75);}}return{'usedNames':_0x493705,'ruleHashToName':_0x40145c,'localRuleToName':_0x31c6a7?_0x30d871:undefined};}export function resolveSegmentName(_0x4978d1,_0x3874e6,_0x2a0b62,_0x186d5d){const _0xa2fe50=a111_0x5430,_0x7f8aed=serializeRule(_0x3874e6);if(_0x2a0b62[_0xa2fe50(0x1cb)]){const _0x2e4108=_0x2a0b62[_0xa2fe50(0x1cb)]['get'](_0x7f8aed);if(_0x2e4108)return{'name':_0x2e4108,'isDuplicate':![],'isLocalMatch':!![]};}const _0x5d56dd=_0x2a0b62['ruleHashToName']['get'](_0x7f8aed);if(_0x5d56dd)return{'name':_0x5d56dd,'isDuplicate':!![],'isLocalMatch':![]};const _0x4b7a7d=_0x186d5d(_0x4978d1);let _0x413e68=_0x4b7a7d||_0x4978d1,_0x2756f7=_0x413e68,_0x5d7295=0x2;while(_0x2a0b62[_0xa2fe50(0x189)][_0xa2fe50(0x183)](_0x2756f7)){_0x2756f7=_0x413e68+'_'+_0x5d7295,_0x5d7295++;}return _0x2a0b62[_0xa2fe50(0x189)][_0xa2fe50(0x173)](_0x2756f7),_0x2a0b62[_0xa2fe50(0x1cd)]['set'](_0x7f8aed,_0x2756f7),{'name':_0x2756f7,'isDuplicate':![],'isLocalMatch':![]};}export function collectSegmentRefsFromRule(_0x20f0a6){const _0x43877b=[],_0x361e5e=_0x35fed0=>{const _0x112471=a111_0x5430;if(!_0x35fed0||typeof _0x35fed0!==_0x112471(0x1d2))return;if(Array[_0x112471(0x1c2)](_0x35fed0)){_0x35fed0['forEach'](_0x361e5e);return;}const _0x55a519=_0x35fed0;(_0x55a519['type']===_0x112471(0x1d0)||_0x55a519['type']===_0x112471(0x1be))&&typeof _0x55a519[_0x112471(0x1ac)]===_0x112471(0x1ce)&&_0x43877b[_0x112471(0x1aa)](_0x55a519[_0x112471(0x1ac)]);for(const _0xc50e88 of Object[_0x112471(0x1d7)](_0x55a519)){_0x361e5e(_0xc50e88);}};return _0x361e5e(_0x20f0a6),_0x43877b;}export function validateSegmentRule(_0x25d538,_0x5e484d){const _0x2ef800=a111_0x5430;if(!_0x5e484d||!_0x5e484d[_0x2ef800(0x17c)])return;for(let _0x13f7db=0x0;_0x13f7db<_0x5e484d[_0x2ef800(0x17c)][_0x2ef800(0x1e0)];_0x13f7db++){const _0x4aa719=_0x5e484d[_0x2ef800(0x17c)][_0x13f7db];if(_0x2ef800(0x1a0)in _0x4aa719&&_0x4aa719[_0x2ef800(0x1a0)]===_0x2ef800(0x1dd)){const _0x412dba=_0x4aa719;if(!_0x412dba[_0x2ef800(0x1b0)]||_0x412dba[_0x2ef800(0x1b0)]==='')throw new SDKError(ErrorCode[_0x2ef800(0x195)],'Invalid\x20condition\x20in\x20embedded\x20segment\x20\x27'+_0x25d538+_0x2ef800(0x18f)+('conditions['+_0x13f7db+_0x2ef800(0x196))+_0x2ef800(0x190));}}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a112_0x15d3(_0x20e4cd,_0x2247a8){_0x20e4cd=_0x20e4cd-0xa3;const _0x31ae2e=a112_0x31ae();let _0x15d3bb=_0x31ae2e[_0x20e4cd];return _0x15d3bb;}(function(_0xd8a2e4,_0x181b5d){const _0x4c3578=a112_0x15d3,_0x21becc=_0xd8a2e4();while(!![]){try{const _0x9982dd=-parseInt(_0x4c3578(0xd6))/0x1*(parseInt(_0x4c3578(0xc1))/0x2)+parseInt(_0x4c3578(0xc7))/0x3+-parseInt(_0x4c3578(0xc9))/0x4*(-parseInt(_0x4c3578(0xbb))/0x5)+parseInt(_0x4c3578(0xb7))/0x6*(parseInt(_0x4c3578(0xc4))/0x7)+-parseInt(_0x4c3578(0xba))/0x8*(-parseInt(_0x4c3578(0xa5))/0x9)+parseInt(_0x4c3578(0xa6))/0xa*(parseInt(_0x4c3578(0xb4))/0xb)+-parseInt(_0x4c3578(0xb5))/0xc;if(_0x9982dd===_0x181b5d)break;else _0x21becc['push'](_0x21becc['shift']());}catch(_0x3f928d){_0x21becc['push'](_0x21becc['shift']());}}}(a112_0x31ae,0xf1977));import a112_0x139c46 from'chalk';import{withProgressSpinner}from'../../utils/spinner.js';function a112_0x31ae(){const _0x58b6c3=['fields','trim','YES','dim','extra','data','11aKyFWF','14104656lByWIW','localeCompare','6FFLctj','entries','Behaviors','1497272seGMZD','280990LCmzKE','startsWith','setJobId','filter','bold','push','1664216Qbmmjo','behavior','\x20\x20\x20\x20','7017423tmaXKV','Unknown','map','3115320QTTHgS','cyan','80pThtRV','name','source','parentColumn','verbose','Attributes','error','Fetching\x20schema...','default','\x0a)\x20AS\x20segment_query\x20LIMIT\x200','slice','parentTableName','information_schema','2DtOXZg','displayName','replace','size','behaviorName','get','tableName','sort','varchar','attribute','27jVOwSI','1027970ZLAuwN','columns','type','length','column_type','groupingName','key','set'];a112_0x31ae=function(){return _0x58b6c3;};return a112_0x31ae();}export function buildSchemaResult(_0x34a773){const _0x1c6133=a112_0x15d3,_0x1c1511=_0x34a773[_0x1c6133(0xa7)][_0x1c6133(0xc6)](_0x333760=>({'column_name':_0x333760[_0x1c6133(0xca)],'column_type':_0x333760[_0x1c6133(0xa8)],'null':_0x1c6133(0xb0),'key':null,'default':null,'extra':null}));return{..._0x34a773,'columns':[{'name':'column_name','type':_0x1c6133(0xa3)},{'name':_0x1c6133(0xaa),'type':_0x1c6133(0xa3)},{'name':'null','type':_0x1c6133(0xa3)},{'name':_0x1c6133(0xac),'type':_0x1c6133(0xa3)},{'name':_0x1c6133(0xd1),'type':'varchar'},{'name':_0x1c6133(0xb2),'type':_0x1c6133(0xa3)}],'data':_0x1c1511};}export async function executeSchemaQuery(_0x37b871,_0x407e22,_0x3d1275){const _0x59c657=a112_0x15d3,_0x49025e=_0x37b871[_0x59c657(0xaf)]()[_0x59c657(0xd8)](/;+$/,''),_0x45d34e='SELECT\x20*\x20FROM\x20(\x0a'+_0x49025e+_0x59c657(0xd2);_0x3d1275[_0x59c657(0xcd)]&&console[_0x59c657(0xcf)]('Schema\x20query:\x0a'+_0x45d34e);const _0x3bbd60=await withProgressSpinner(_0x59c657(0xd0),async _0x2b4484=>{const _0x28546d=_0x59c657,_0x1c4011=await _0x407e22['query']['execute'](_0x45d34e,{'catalog':'td','schema':_0x28546d(0xd5),'onJobId':_0x3696cb=>{const _0x51ff59=_0x28546d;_0x2b4484[_0x51ff59(0xbd)](_0x3696cb);}});return _0x1c4011;},{'verbose':_0x3d1275['verbose']});return buildSchemaResult(_0x3bbd60[_0x59c657(0xb3)]);}export function displayFieldsHumanReadable(_0x16d87f,_0x20e7d2){const _0x3788d1=a112_0x15d3,_0x1dbf6a=_0x16d87f[_0x3788d1(0xbe)](_0x48b1c5=>_0x48b1c5[_0x3788d1(0xcb)]===_0x3788d1(0xa4)),_0x14d0b4=_0x16d87f[_0x3788d1(0xbe)](_0x1c5821=>_0x1c5821[_0x3788d1(0xcb)]===_0x3788d1(0xc2)),_0x38324b=new Map();for(const _0x4d90bb of _0x1dbf6a){const _0x1506e3=_0x4d90bb[_0x3788d1(0xab)]||_0x4d90bb['parentTableName']||_0x3788d1(0xc5),_0x5486c0=_0x38324b['get'](_0x1506e3);_0x5486c0?_0x5486c0[_0x3788d1(0xae)]['push'](_0x4d90bb):_0x38324b[_0x3788d1(0xad)](_0x1506e3,{'displayName':_0x1506e3,'tableName':_0x4d90bb[_0x3788d1(0xd4)],'fields':[_0x4d90bb]});}const _0x2fde8c=new Map();for(const _0x36ba6e of _0x14d0b4){const _0x194be5=_0x36ba6e[_0x3788d1(0xda)]||'Unknown',_0x1380b5=_0x2fde8c[_0x3788d1(0xdb)](_0x194be5)||[];_0x1380b5[_0x3788d1(0xc0)](_0x36ba6e),_0x2fde8c[_0x3788d1(0xad)](_0x194be5,_0x1380b5);}console[_0x3788d1(0xcf)]('\x0a'+a112_0x139c46[_0x3788d1(0xbf)](_0x20e7d2));if(_0x38324b[_0x3788d1(0xd9)]>0x0){console[_0x3788d1(0xcf)]('\x0a'+a112_0x139c46[_0x3788d1(0xb1)](_0x3788d1(0xce)));const _0x388960=[..._0x38324b[_0x3788d1(0xb8)]()][_0x3788d1(0xdd)]((_0x153c66,_0x3c508c)=>_0x153c66[0x0][_0x3788d1(0xb6)](_0x3c508c[0x0]));for(const [,_0x364354]of _0x388960){const _0x2126c1=_0x364354['tableName']&&_0x364354['tableName']!==_0x364354['displayName']?'\x20'+a112_0x139c46[_0x3788d1(0xb1)]('('+_0x364354[_0x3788d1(0xdc)]+')'):'';console[_0x3788d1(0xcf)]('\x20\x20'+a112_0x139c46[_0x3788d1(0xbf)](_0x364354[_0x3788d1(0xd7)])+_0x2126c1);const _0x2fe575=[..._0x364354[_0x3788d1(0xae)]][_0x3788d1(0xdd)]((_0x55c384,_0xa5ec12)=>_0x55c384['name'][_0x3788d1(0xb6)](_0xa5ec12[_0x3788d1(0xca)]));for(const _0x53607a of _0x2fe575){const _0x3e2751=_0x53607a[_0x3788d1(0xcc)]&&_0x53607a[_0x3788d1(0xcc)]!==_0x53607a[_0x3788d1(0xca)]?'\x20'+a112_0x139c46[_0x3788d1(0xb1)]('('+_0x53607a['parentColumn']+')'):'';console[_0x3788d1(0xcf)](_0x3788d1(0xc3)+_0x53607a[_0x3788d1(0xca)]+_0x3e2751+':\x20'+a112_0x139c46[_0x3788d1(0xc8)](_0x53607a['type']));}}}if(_0x2fde8c['size']>0x0){console[_0x3788d1(0xcf)]('\x0a'+a112_0x139c46[_0x3788d1(0xb1)](_0x3788d1(0xb9)));const _0x32a5d9=[..._0x2fde8c[_0x3788d1(0xb8)]()][_0x3788d1(0xdd)]((_0x444512,_0x3fdb12)=>_0x444512[0x0][_0x3788d1(0xb6)](_0x3fdb12[0x0]));for(const [_0x5e4b01,_0x4313e4]of _0x32a5d9){const _0x67d395=_0x4313e4[0x0],_0x1ff040=_0x67d395?.[_0x3788d1(0xd4)]||'';console[_0x3788d1(0xcf)]('\x20\x20'+a112_0x139c46[_0x3788d1(0xbf)](_0x5e4b01)+(_0x1ff040?'\x20'+a112_0x139c46['dim']('('+_0x1ff040+')'):''));const _0x45d9bb=[..._0x4313e4][_0x3788d1(0xdd)]((_0x34dd11,_0x1b113f)=>_0x34dd11['name'][_0x3788d1(0xb6)](_0x1b113f['name']));for(const _0x59b577 of _0x45d9bb){const _0x4b147d=_0x59b577['name'][_0x3788d1(0xbc)](_0x5e4b01+'.')?_0x59b577[_0x3788d1(0xca)][_0x3788d1(0xd3)](_0x5e4b01[_0x3788d1(0xa9)]+0x1):_0x59b577[_0x3788d1(0xca)],_0x3c7efc=_0x59b577[_0x3788d1(0xcc)]&&_0x59b577[_0x3788d1(0xcc)]!==_0x4b147d?'\x20'+a112_0x139c46[_0x3788d1(0xb1)]('('+_0x59b577['parentColumn']+')'):'';console[_0x3788d1(0xcf)](_0x3788d1(0xc3)+_0x4b147d+_0x3c7efc+':\x20'+a112_0x139c46[_0x3788d1(0xc8)](_0x59b577[_0x3788d1(0xa8)]));}}}console[_0x3788d1(0xcf)]('');}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a113_0x2683(){const _0x3ed0d8=['20941778FlvlWD','140758RjZjrB','endsWith','name','.yaml','328LECmmD','isFile','map','isDirectory','relative','6945815TzYqTM','3793612WPFygv','.yml','323091cKDgBX','6qdlmtQ','15660730sxoEIh','16PEODHZ','extname','dirname','10169173HQXnij','toLowerCase','3sVyYmU'];a113_0x2683=function(){return _0x3ed0d8;};return a113_0x2683();}(function(_0xae2096,_0x472af4){const _0x44a0a7=a113_0x57bc,_0x2ce137=_0xae2096();while(!![]){try{const _0x1fe455=-parseInt(_0x44a0a7(0x68))/0x1*(parseInt(_0x44a0a7(0x77))/0x2)+parseInt(_0x44a0a7(0x66))/0x3*(parseInt(_0x44a0a7(0x72))/0x4)+parseInt(_0x44a0a7(0x71))/0x5*(parseInt(_0x44a0a7(0x75))/0x6)+parseInt(_0x44a0a7(0x7a))/0x7+parseInt(_0x44a0a7(0x6c))/0x8*(-parseInt(_0x44a0a7(0x74))/0x9)+parseInt(_0x44a0a7(0x76))/0xa+-parseInt(_0x44a0a7(0x67))/0xb;if(_0x1fe455===_0x472af4)break;else _0x2ce137['push'](_0x2ce137['shift']());}catch(_0xe2501e){_0x2ce137['push'](_0x2ce137['shift']());}}}(a113_0x2683,0xd0a81));import{readdirSync,statSync}from'fs';function a113_0x57bc(_0x25083c,_0x126542){_0x25083c=_0x25083c-0x66;const _0x268394=a113_0x2683();let _0x57bc87=_0x268394[_0x25083c];return _0x57bc87;}import a113_0x105d9d from'path';export function findYamlFiles(_0x15384b){const _0x5c8847=[];function _0x45fc82(_0x51762e){const _0x1e7a0b=a113_0x57bc,_0x5ee6ef=readdirSync(_0x51762e,{'withFileTypes':!![]});for(const _0x351118 of _0x5ee6ef){const _0x5234da=a113_0x105d9d['join'](_0x51762e,_0x351118[_0x1e7a0b(0x6a)]);if(_0x351118[_0x1e7a0b(0x6f)]())_0x45fc82(_0x5234da);else(_0x351118['name'][_0x1e7a0b(0x69)](_0x1e7a0b(0x73))||_0x351118['name'][_0x1e7a0b(0x69)]('.yaml'))&&_0x5c8847['push'](_0x5234da);}}return _0x45fc82(_0x15384b),_0x5c8847;}export function discoverYamlFiles(_0x3e3e6d){const _0x44c8be=a113_0x57bc,_0x468243=findYamlFiles(_0x3e3e6d);return _0x468243[_0x44c8be(0x6e)](_0x3f12fe=>{const _0x31a798=_0x44c8be,_0x1b864f=a113_0x105d9d[_0x31a798(0x70)](_0x3e3e6d,_0x3f12fe),_0x16a3cd=a113_0x105d9d[_0x31a798(0x79)](_0x1b864f);return{'absolutePath':_0x3f12fe,'relativePath':_0x1b864f,'folderPath':_0x16a3cd==='.'?'':_0x16a3cd};});}export function isYamlFile(_0x458b02){const _0x40b0a3=a113_0x57bc;try{const _0x5973f8=statSync(_0x458b02);if(!_0x5973f8[_0x40b0a3(0x6d)]())return![];const _0x76c58e=a113_0x105d9d[_0x40b0a3(0x78)](_0x458b02)[_0x40b0a3(0x7b)]();return _0x76c58e===_0x40b0a3(0x73)||_0x76c58e===_0x40b0a3(0x6b);}catch{return![];}}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(_0x378d49,_0x401e86){const _0x4ca252=a114_0x1b7e,_0x26798d=_0x378d49();while(!![]){try{const _0x4e0e2b=-parseInt(_0x4ca252(0x11e))/0x1+-parseInt(_0x4ca252(0x102))/0x2*(-parseInt(_0x4ca252(0x10e))/0x3)+parseInt(_0x4ca252(0xda))/0x4*(-parseInt(_0x4ca252(0xe6))/0x5)+-parseInt(_0x4ca252(0xdf))/0x6*(-parseInt(_0x4ca252(0x101))/0x7)+-parseInt(_0x4ca252(0xf9))/0x8+parseInt(_0x4ca252(0xec))/0x9+parseInt(_0x4ca252(0x11c))/0xa;if(_0x4e0e2b===_0x401e86)break;else _0x26798d['push'](_0x26798d['shift']());}catch(_0x495f88){_0x26798d['push'](_0x26798d['shift']());}}}(a114_0x5102,0x5fd0c));function a114_0x1b7e(_0x3a8f83,_0x3d7be2){_0x3a8f83=_0x3a8f83-0xda;const _0x51027f=a114_0x5102();let _0x1b7ea3=_0x51027f[_0x3a8f83];return _0x1b7ea3;}import{serializeRule,deepSortObject}from'./child-segment-yaml.js';export const SEGMENT_KIND_JOURNEY=0x3;function a114_0x5102(){const _0x373f21=['match','bundle_name','keys','endsWith','isArray','steps','latest','trim','with','stages','44WMecWI','values','schedule','null','connection','1037094fwMUOw','max','sort','stringify','columns','attributes','rule','2165NYakem','name','activation','yaml','segment','decision_point','2051370VzzmyJ','toLowerCase','goal','entry_criteria','all_columns','length','versionNumber','replace','push','startsWith','object','state','activation_template_id','1337416RORFcp','activations','map','include','type','journeyBundleName','has','slice','7bnvIWq','2CNyADG','entries','bundle_id','set','string','launched','conditions','journeys','description','journeyStages','milestone','connector_config','1529958xUzqAs','version_number','item','get','wait','branches','from','join','versions','draft','nameMapping','behavior','exit_criteria','version','4083260GthvGm','segments','754691RLrSvr','notification'];a114_0x5102=function(){return _0x373f21;};return a114_0x5102();}const MAX_MAPPING_CHAIN_DEPTH=0xa;export function sanitizeYamlKey(_0x3c5b93){const _0x5a6657=a114_0x1b7e;return _0x3c5b93[_0x5a6657(0xed)]()[_0x5a6657(0xf3)](/\s+/g,'_')[_0x5a6657(0xf3)](/[^a-z0-9_]/g,'')[_0x5a6657(0xf3)](/_+/g,'_')[_0x5a6657(0xf3)](/^_|_$/g,'');}export function generateJourneyLocalName(_0x58fa37){const _0x53b781=a114_0x1b7e,_0x42e78a=_0x58fa37['match'](/^journey_([a-z_]+)_([0-9a-f-]+)$/i);if(_0x42e78a){const _0x2d91c2=_0x42e78a[0x1][_0x53b781(0xed)](),_0x3e175c=_0x42e78a[0x2],_0x126f3e=_0x3e175c[_0x53b781(0xf3)](/-/g,'')[_0x53b781(0x100)](0x0,0x4)['toLowerCase']();return _0x2d91c2+'_'+_0x126f3e;}const _0x35fded=_0x58fa37[_0x53b781(0x120)](/^journey_\d+_stage_\d+_step_([0-9a-f-]+)_([a-z_]+)$/i);if(_0x35fded){const _0x1a02c7=_0x35fded[0x1],_0x129595=_0x35fded[0x2][_0x53b781(0xed)](),_0x3e2563=_0x1a02c7['replace'](/-/g,'')[_0x53b781(0x100)](0x0,0x4)['toLowerCase']();return _0x129595+'_'+_0x3e2563;}return undefined;}function stableStringify(_0x1676a3){const _0x2f0a97=a114_0x1b7e;if(Array[_0x2f0a97(0x124)](_0x1676a3))return'['+_0x1676a3[_0x2f0a97(0xfb)](_0x2d6c1a=>stableStringify(_0x2d6c1a))[_0x2f0a97(0x115)](',')+']';if(_0x1676a3&&typeof _0x1676a3==='object'){const _0x4fa33a=_0x1676a3,_0x25e7dd=Object[_0x2f0a97(0x122)](_0x4fa33a)[_0x2f0a97(0xe1)](),_0x19a29b=_0x25e7dd[_0x2f0a97(0xfb)](_0x5c7e61=>'\x22'+_0x5c7e61+'\x22:'+stableStringify(_0x4fa33a[_0x5c7e61]));return'{'+_0x19a29b['join'](',')+'}';}const _0x363998=JSON[_0x2f0a97(0xe2)](_0x1676a3);return _0x363998===undefined?_0x2f0a97(0xdd):_0x363998;}export function consolidateActivationsByContent(_0x56a585){const _0x1ad2fd=a114_0x1b7e,_0x36ca62={},_0x4240c8=new Map(),_0x53e6f7=new Map();for(const _0x3057fe of _0x56a585){if(!_0x3057fe)continue;for(const [_0x112b98,_0x362068]of Object['entries'](_0x3057fe)){const _0x57f9da={'connection':_0x362068[_0x1ad2fd(0xde)],..._0x362068[_0x1ad2fd(0xf0)]!==undefined&&{'all_columns':_0x362068['all_columns']},..._0x362068['columns']!==undefined&&{'columns':_0x362068[_0x1ad2fd(0xe3)]},..._0x362068[_0x1ad2fd(0x119)]!==undefined&&{'behavior':_0x362068['behavior']},..._0x362068[_0x1ad2fd(0xdc)]!==undefined&&{'schedule':_0x362068['schedule']},..._0x362068[_0x1ad2fd(0x11f)]!==undefined&&{'notification':_0x362068[_0x1ad2fd(0x11f)]},..._0x362068[_0x1ad2fd(0x10d)]!==undefined&&{'connector_config':_0x362068[_0x1ad2fd(0x10d)]},..._0x362068[_0x1ad2fd(0xf8)]!==undefined&&{'activation_template_id':_0x362068[_0x1ad2fd(0xf8)]}},_0x52638b=stableStringify(_0x57f9da),_0x309ba4=_0x53e6f7['get'](_0x52638b);_0x309ba4?_0x4240c8[_0x1ad2fd(0x105)](_0x112b98,_0x309ba4):(_0x36ca62[_0x112b98]=_0x362068,_0x4240c8[_0x1ad2fd(0x105)](_0x112b98,_0x112b98),_0x53e6f7['set'](_0x52638b,_0x112b98));}}return{'merged':_0x36ca62,'nameMapping':_0x4240c8};}export function updateActivationReferences(_0x632ce5,_0x179d93){const _0x1315b8=a114_0x1b7e;if(!_0x632ce5)return;for(const _0x5ea052 of _0x632ce5){if(!_0x5ea052['steps'])continue;for(const _0x521737 of _0x5ea052[_0x1315b8(0x125)]){if(_0x521737[_0x1315b8(0xfd)]==='activation'&&_0x521737['with']?.['activation']){const _0x4f7dd7=_0x179d93['get'](_0x521737[_0x1315b8(0x128)]['activation']);_0x4f7dd7&&_0x4f7dd7!==_0x521737[_0x1315b8(0x128)][_0x1315b8(0xe8)]&&(_0x521737[_0x1315b8(0x128)][_0x1315b8(0xe8)]=_0x4f7dd7);}}}}export function consolidateSegmentsByContent(_0x5c2daa,_0x2648f0){const _0x4f8608=a114_0x1b7e,_0x31445b={},_0x293949=new Map(),_0x3ba64f=new Map();for(const _0x57221a of _0x5c2daa){if(!_0x57221a)continue;for(const [_0x31c478,_0x328b22]of Object[_0x4f8608(0x103)](_0x57221a)){if(!_0x328b22['rule']){_0x31445b[_0x31c478]=_0x328b22,_0x293949[_0x4f8608(0x105)](_0x31c478,_0x31c478);continue;}const _0x1eadfb=_0x328b22[_0x4f8608(0x10a)]&&_0x328b22[_0x4f8608(0x10a)][_0x4f8608(0x127)]()?_0x328b22[_0x4f8608(0x10a)]:undefined,_0x1ab0aa=JSON[_0x4f8608(0xe2)]({'description':_0x1eadfb,'rule':deepSortObject(_0x328b22[_0x4f8608(0xe5)])}),_0x2ec751=_0x3ba64f[_0x4f8608(0x111)](_0x1ab0aa);if(_0x2ec751){const _0x45ffb5={..._0x328b22[_0x4f8608(0x10a)]!==undefined&&{'description':_0x328b22['description']},'rule':_0x328b22['rule']?deepSortObject(_0x328b22[_0x4f8608(0xe5)]):_0x328b22['rule']};if(_0x31c478<_0x2ec751){_0x31445b[_0x31c478]=_0x45ffb5,delete _0x31445b[_0x2ec751];for(const [_0x210f06,_0x3964d4]of _0x293949[_0x4f8608(0x103)]()){_0x3964d4===_0x2ec751&&_0x293949[_0x4f8608(0x105)](_0x210f06,_0x31c478);}_0x293949[_0x4f8608(0x105)](_0x31c478,_0x31c478),_0x3ba64f['set'](_0x1ab0aa,_0x31c478);}else _0x31445b[_0x2ec751]=_0x45ffb5,_0x293949[_0x4f8608(0x105)](_0x31c478,_0x2ec751);}else{let _0x5159f4=_0x31c478;if(_0x2648f0){const _0x286a34=_0x2648f0['get'](_0x1ab0aa);_0x286a34&&_0x286a34['length']>0x0&&(_0x5159f4=_0x286a34[_0x4f8608(0x100)]()[_0x4f8608(0xe1)]()[0x0]);}const _0x20946a={..._0x328b22[_0x4f8608(0x10a)]!==undefined&&{'description':_0x328b22[_0x4f8608(0x10a)]},'rule':_0x328b22['rule']?deepSortObject(_0x328b22[_0x4f8608(0xe5)]):_0x328b22[_0x4f8608(0xe5)]};_0x31445b[_0x5159f4]=_0x20946a,_0x293949[_0x4f8608(0x105)](_0x31c478,_0x5159f4),_0x3ba64f[_0x4f8608(0x105)](_0x1ab0aa,_0x5159f4);}}}return{'merged':_0x31445b,'nameMapping':_0x293949};}export function updateSegmentReferences(_0x1ad748,_0x491409){const _0x35ef9c=a114_0x1b7e;if(!_0x1ad748)return;for(const _0x4478c3 of _0x1ad748){if(_0x4478c3[_0x35ef9c(0xef)]?.[_0x35ef9c(0xea)]){const _0x4f4e04=_0x491409['get'](_0x4478c3['entry_criteria']['segment']);_0x4f4e04&&(_0x4478c3[_0x35ef9c(0xef)][_0x35ef9c(0xea)]=_0x4f4e04);}if(_0x4478c3[_0x35ef9c(0x125)])for(const _0x1cdcb6 of _0x4478c3[_0x35ef9c(0x125)]){if(_0x1cdcb6[_0x35ef9c(0xfd)]===_0x35ef9c(0xeb)&&_0x1cdcb6[_0x35ef9c(0x128)]?.[_0x35ef9c(0x113)])for(const _0x6872c7 of _0x1cdcb6['with'][_0x35ef9c(0x113)]){if(_0x6872c7['segment']){const _0xc671f7=_0x491409[_0x35ef9c(0x111)](_0x6872c7[_0x35ef9c(0xea)]);_0xc671f7&&(_0x6872c7['segment']=_0xc671f7);}}}}}export function updateSegmentRefsInSegments(_0x2837f8,_0x4ddbe8){const _0x3903b4=a114_0x1b7e;for(const _0x1fd381 of Object[_0x3903b4(0xdb)](_0x2837f8)){_0x1fd381[_0x3903b4(0xe5)]&&updateSegmentRefsInRule(_0x1fd381[_0x3903b4(0xe5)],_0x4ddbe8);}}function updateSegmentRefsInRule(_0x474165,_0x3eb71d){const _0x321cd7=a114_0x1b7e;if(_0x474165===null||typeof _0x474165!==_0x321cd7(0xf6))return;if(Array[_0x321cd7(0x124)](_0x474165)){for(const _0x45cfd7 of _0x474165){updateSegmentRefsInRule(_0x45cfd7,_0x3eb71d);}return;}const _0x132e09=_0x474165;if((_0x132e09['type']===_0x321cd7(0xfc)||_0x132e09['type']==='exclude')&&typeof _0x132e09[_0x321cd7(0xea)]===_0x321cd7(0x106)){const _0x3ef0a5=_0x3eb71d[_0x321cd7(0x111)](_0x132e09[_0x321cd7(0xea)]);_0x3ef0a5&&(_0x132e09['segment']=_0x3ef0a5);}if(_0x132e09[_0x321cd7(0x108)]&&Array['isArray'](_0x132e09[_0x321cd7(0x108)]))for(const _0x2a7c66 of _0x132e09[_0x321cd7(0x108)]){updateSegmentRefsInRule(_0x2a7c66,_0x3eb71d);}}export function buildJourneysArray(_0x3b24af){const _0x50b761=a114_0x1b7e,_0x5b9cbb=Math[_0x50b761(0xe0)](..._0x3b24af[_0x50b761(0xfb)](_0x228de9=>_0x228de9[_0x50b761(0x110)][_0x50b761(0xf2)]||0x0));return _0x3b24af[_0x50b761(0xfb)](_0x4e8570=>{const _0x48d7a4=_0x50b761,_0x517e32=(_0x4e8570['item'][_0x48d7a4(0xf2)]||0x0)===_0x5b9cbb,_0x3b7ea6=_0x4e8570[_0x48d7a4(0xe9)]['journeys']?.[0x0],_0x278e48={'version':_0x3b7ea6?.['version']||_0x4e8570[_0x48d7a4(0xe9)][_0x48d7a4(0x11b)]||_0x4e8570[_0x48d7a4(0x110)][_0x48d7a4(0xe7)],'state':_0x4e8570[_0x48d7a4(0x110)][_0x48d7a4(0xf7)]===_0x48d7a4(0x107)?'launched':_0x48d7a4(0x117),'stages':_0x3b7ea6?.['stages']||_0x4e8570[_0x48d7a4(0xe9)][_0x48d7a4(0x129)]||[],'id':_0x3b7ea6?.['id']||_0x4e8570[_0x48d7a4(0xe9)]['id'],'version_number':_0x3b7ea6?.['version_number']||_0x4e8570[_0x48d7a4(0xe9)][_0x48d7a4(0x10f)]};return _0x517e32&&(_0x278e48[_0x48d7a4(0x126)]=!![]),_0x278e48;});}export function buildMergedJourneyDef(_0x3158c9,_0x1c3294){const _0x70ee40=a114_0x1b7e,_0x346677=_0x3158c9[0x0]['yaml'],_0x4b70ea=buildJourneysArray(_0x3158c9),{merged:_0x14fd53,nameMapping:_0x1dd05e}=consolidateSegmentsByContent(_0x3158c9['map'](_0x1f6727=>_0x1f6727['yaml'][_0x70ee40(0x11d)]),_0x1c3294);updateSegmentRefsInSegments(_0x14fd53,_0x1dd05e);const _0x388670=Array[_0x70ee40(0x114)](_0x1dd05e[_0x70ee40(0x103)]())['some'](([_0x3d80f0,_0x2eb973])=>_0x3d80f0!==_0x2eb973&&_0x3d80f0[_0x70ee40(0xf5)](_0x70ee40(0xef)));let _0x25f6bb=_0x14fd53,_0x5e8ff3=new Map();if(_0x388670){const _0x280957=consolidateSegmentsByContent([_0x14fd53],_0x1c3294);_0x25f6bb=_0x280957['merged'],_0x5e8ff3=_0x280957[_0x70ee40(0x118)];}const _0x476b02=new Map(_0x1dd05e);for(const [_0x3ceadb,_0x3b5a5a]of _0x5e8ff3[_0x70ee40(0x103)]()){_0x476b02[_0x70ee40(0x105)](_0x3ceadb,_0x3b5a5a);}for(const [_0x5c8015,_0x2c20d4]of _0x476b02['entries']()){let _0x5e646b=_0x2c20d4,_0x2282df=0x0;while(_0x476b02[_0x70ee40(0xff)](_0x5e646b)&&_0x476b02['get'](_0x5e646b)!==_0x5e646b&&_0x2282df<MAX_MAPPING_CHAIN_DEPTH){_0x5e646b=_0x476b02[_0x70ee40(0x111)](_0x5e646b),_0x2282df++;}_0x5e646b!==_0x2c20d4&&_0x476b02[_0x70ee40(0x105)](_0x5c8015,_0x5e646b);}for(const _0x3eee74 of _0x4b70ea){updateSegmentReferences(_0x3eee74[_0x70ee40(0x129)],_0x476b02);}const {merged:_0x42f198,nameMapping:_0x3bcdd7}=consolidateActivationsByContent(_0x3158c9[_0x70ee40(0xfb)](_0x453a3d=>_0x453a3d[_0x70ee40(0xe9)][_0x70ee40(0xfa)]));for(const _0x34d20e of _0x4b70ea){updateActivationReferences(_0x34d20e['stages'],_0x3bcdd7);}let _0x214465=_0x346677['goal'];if(_0x214465?.['segment']){const _0x3fc3ee=_0x476b02[_0x70ee40(0x111)](_0x214465[_0x70ee40(0xea)]);_0x3fc3ee&&(_0x214465={..._0x214465,'segment':_0x3fc3ee});}for(const _0x5206e0 of _0x4b70ea){if(_0x5206e0[_0x70ee40(0xee)]?.[_0x70ee40(0xea)]){const _0xd6ece9=_0x476b02['get'](_0x5206e0[_0x70ee40(0xee)][_0x70ee40(0xea)]);_0xd6ece9&&(_0x5206e0[_0x70ee40(0xee)]={..._0x5206e0[_0x70ee40(0xee)],'segment':_0xd6ece9});}}return{'type':'journey','name':_0x346677[_0x70ee40(0xe7)],'description':_0x346677[_0x70ee40(0x10a)],'goal':_0x214465,'reentry':_0x346677['reentry'],'segments':Object[_0x70ee40(0x122)](_0x25f6bb)[_0x70ee40(0xf1)]>0x0?_0x25f6bb:undefined,'activations':Object[_0x70ee40(0x122)](_0x42f198)[_0x70ee40(0xf1)]>0x0?_0x42f198:undefined,'journeys':_0x4b70ea,'bundle_id':_0x346677[_0x70ee40(0x104)],'bundle_name':_0x346677[_0x70ee40(0x121)]};}export function createJumpTargetCache(){return new Map();}export async function resolveJumpTarget(_0x1f68e4,_0x4b1012,_0x10b4d3,_0x42d4ae){const _0x5ac686=a114_0x1b7e,_0x5ebead=_0x1f68e4+':'+_0x4b1012,_0x4b1214=_0x10b4d3[_0x5ac686(0x111)](_0x5ebead);if(_0x4b1214)return _0x4b1214;const _0x585703=await _0x42d4ae(_0x1f68e4),_0x38c872=_0x585703[_0x5ac686(0xe4)][_0x5ac686(0xfe)]||_0x585703[_0x5ac686(0xe4)][_0x5ac686(0xe7)],_0x55fc52=_0x585703['attributes'][_0x5ac686(0x10b)]['find'](_0xc5dd3a=>String(_0xc5dd3a['id'])===String(_0x4b1012)),_0x155ac4=_0x55fc52?.['name']||_0x4b1012,_0x50b77d={'journeyName':_0x38c872,'stageName':_0x155ac4};return _0x10b4d3[_0x5ac686(0x105)](_0x5ebead,_0x50b77d),_0x50b77d;}export function formatApiJourneyName(_0x54c7b3,_0x4f31b5){return _0x4f31b5+'\x20('+_0x54c7b3+')';}export function isLocalJourneyRef(_0x486a3d){const _0x4542ae=a114_0x1b7e;return _0x486a3d[_0x4542ae(0x123)]('.yml')||_0x486a3d[_0x4542ae(0x123)]('.yaml');}export function buildLocalRuleToNameMapping(_0x20bd37){const _0x273003=a114_0x1b7e,_0x9e33e=new Map();if(!_0x20bd37)return _0x9e33e;for(const [_0x2e33d5,_0x6092c8]of Object['entries'](_0x20bd37)){if(_0x6092c8[_0x273003(0xe5)]){const _0x16ea02=serializeRule(_0x6092c8[_0x273003(0xe5)]),_0x15738e=_0x9e33e[_0x273003(0x111)](_0x16ea02)||[];_0x15738e['push'](_0x2e33d5),_0x9e33e[_0x273003(0x105)](_0x16ea02,_0x15738e);}}return _0x9e33e;}export function buildLocalRuleToNameMappingFromJourney(_0x1aaea3){const _0x11f8ec=a114_0x1b7e,_0x387916=_0x1aaea3[_0x11f8ec(0x11d)];if(!_0x387916)return new Map();const _0x173994=collectSegmentUsageCounts(_0x1aaea3),_0x3251df=new Map();let _0x2eed06=0x0;for(const [_0x2b934f,_0x5cb7ad]of Object['entries'](_0x387916)){if(!_0x5cb7ad[_0x11f8ec(0xe5)]){_0x2eed06++;continue;}const _0x14612d=serializeRule(_0x5cb7ad[_0x11f8ec(0xe5)]),_0x4fe1d5=_0x3251df[_0x11f8ec(0x111)](_0x14612d)||[];_0x4fe1d5[_0x11f8ec(0xf4)]({'name':_0x2b934f,'index':_0x2eed06}),_0x3251df[_0x11f8ec(0x105)](_0x14612d,_0x4fe1d5),_0x2eed06++;}const _0x14944a=new Map();for(const [_0x5d6324,_0x15d5bf]of _0x3251df){const _0x1a9f61=_0x15d5bf[_0x11f8ec(0x100)]()[_0x11f8ec(0xe1)]((_0xa05baa,_0x5eb238)=>{const _0x41b1bb=_0x11f8ec,_0x2293b4=_0x173994[_0x41b1bb(0x111)](_0xa05baa['name'])||0x0,_0x274fdb=_0x173994['get'](_0x5eb238[_0x41b1bb(0xe7)])||0x0;if(_0x2293b4!==_0x274fdb)return _0x274fdb-_0x2293b4;return _0xa05baa['index']-_0x5eb238['index'];})[_0x11f8ec(0xfb)](_0x4c6d60=>_0x4c6d60['name']);_0x14944a[_0x11f8ec(0x105)](_0x5d6324,_0x1a9f61);}return _0x14944a;}export function collectSegmentUsageCounts(_0x55043){const _0x5ed113=a114_0x1b7e,_0x18d82b=new Map(),_0x528d3d=_0x1a1856=>{const _0x2aa215=a114_0x1b7e;if(!_0x1a1856)return;_0x18d82b[_0x2aa215(0x105)](_0x1a1856,(_0x18d82b[_0x2aa215(0x111)](_0x1a1856)||0x0)+0x1);},_0x5d0a7a=_0x3228cf=>{const _0xe5a069=a114_0x1b7e;for(const _0x69fc26 of _0x3228cf){_0x528d3d(_0x69fc26[_0xe5a069(0xef)]?.['segment']);if(_0x69fc26[_0xe5a069(0x11a)])for(const _0x1a2c17 of _0x69fc26[_0xe5a069(0x11a)]){_0x528d3d(_0x1a2c17['segment']);}_0x528d3d(_0x69fc26[_0xe5a069(0x10c)]?.[_0xe5a069(0xea)]);if(_0x69fc26['steps'])for(const _0x2fa23b of _0x69fc26[_0xe5a069(0x125)]){if(_0x2fa23b[_0xe5a069(0xfd)]===_0xe5a069(0xeb))for(const _0x52968f of _0x2fa23b['with']['branches']){_0x528d3d(_0x52968f[_0xe5a069(0xea)]);}else _0x2fa23b[_0xe5a069(0xfd)]===_0xe5a069(0x112)&&_0x528d3d(_0x2fa23b[_0xe5a069(0x128)]['condition']?.[_0xe5a069(0xea)]);}}};_0x528d3d(_0x55043[_0x5ed113(0xee)]?.[_0x5ed113(0xea)]);if(_0x55043[_0x5ed113(0x109)])for(const _0x202112 of _0x55043[_0x5ed113(0x109)]){_0x528d3d(_0x202112['goal']?.[_0x5ed113(0xea)]),_0x5d0a7a(_0x202112['stages']);}_0x55043['stages']&&_0x5d0a7a(_0x55043[_0x5ed113(0x129)]);if(_0x55043[_0x5ed113(0x116)])for(const _0xe183e of _0x55043[_0x5ed113(0x116)]){_0x5d0a7a(_0xe183e[_0x5ed113(0x129)]);}return _0x18d82b;}
|
|
1
|
+
(function(_0x2cdfae,_0x36b397){const _0x590677=a114_0x2ea3,_0x2109e6=_0x2cdfae();while(!![]){try{const _0x48359e=parseInt(_0x590677(0xd0))/0x1+-parseInt(_0x590677(0x9c))/0x2+-parseInt(_0x590677(0xd9))/0x3+-parseInt(_0x590677(0xb6))/0x4*(parseInt(_0x590677(0xa2))/0x5)+parseInt(_0x590677(0xa7))/0x6*(-parseInt(_0x590677(0xbb))/0x7)+parseInt(_0x590677(0xea))/0x8+-parseInt(_0x590677(0xcb))/0x9*(-parseInt(_0x590677(0xd1))/0xa);if(_0x48359e===_0x36b397)break;else _0x2109e6['push'](_0x2109e6['shift']());}catch(_0x3e6427){_0x2109e6['push'](_0x2109e6['shift']());}}}(a114_0x269b,0xc6ced));import{serializeRule,deepSortObject}from'./child-segment-yaml.js';export const SEGMENT_KIND_JOURNEY=0x3;const MAX_MAPPING_CHAIN_DEPTH=0xa;export function sanitizeYamlKey(_0x44cf25){const _0x5f496c=a114_0x2ea3;return _0x44cf25[_0x5f496c(0xc2)]()['replace'](/\s+/g,'_')[_0x5f496c(0xab)](/[^a-z0-9_]/g,'')[_0x5f496c(0xab)](/_+/g,'_')[_0x5f496c(0xab)](/^_|_$/g,'');}export function generateJourneyLocalName(_0x529912){const _0x1345b5=a114_0x2ea3,_0x81bad2=_0x529912[_0x1345b5(0xc8)](/^journey_([a-z_]+)_([0-9a-f-]+)$/i);if(_0x81bad2){const _0x272bfe=_0x81bad2[0x1][_0x1345b5(0xc2)](),_0x231cbe=_0x81bad2[0x2],_0x2d74bb=_0x231cbe[_0x1345b5(0xab)](/-/g,'')['slice'](0x0,0x4)[_0x1345b5(0xc2)]();return _0x272bfe+'_'+_0x2d74bb;}const _0x171203=_0x529912[_0x1345b5(0xc8)](/^journey_\d+_stage_\d+_step_([0-9a-f-]+)_([a-z_]+)$/i);if(_0x171203){const _0x2da67a=_0x171203[0x1],_0x36d295=_0x171203[0x2][_0x1345b5(0xc2)](),_0x5b00f5=_0x2da67a['replace'](/-/g,'')[_0x1345b5(0xe4)](0x0,0x4)['toLowerCase']();return _0x36d295+'_'+_0x5b00f5;}return undefined;}function stableStringify(_0x32e354){const _0x30e195=a114_0x2ea3;if(Array[_0x30e195(0xa3)](_0x32e354))return'['+_0x32e354[_0x30e195(0xe2)](_0x47af7b=>stableStringify(_0x47af7b))[_0x30e195(0xb7)](',')+']';if(_0x32e354&&typeof _0x32e354===_0x30e195(0xc1)){const _0x2959aa=_0x32e354,_0x5137c8=Object[_0x30e195(0xa5)](_0x2959aa)['sort'](),_0x1d4f5e=_0x5137c8[_0x30e195(0xe2)](_0x183c22=>'\x22'+_0x183c22+'\x22:'+stableStringify(_0x2959aa[_0x183c22]));return'{'+_0x1d4f5e[_0x30e195(0xb7)](',')+'}';}const _0x2033f3=JSON[_0x30e195(0xc4)](_0x32e354);return _0x2033f3===undefined?_0x30e195(0xc0):_0x2033f3;}export function consolidateActivationsByContent(_0xc657c5){const _0x3c82bf=a114_0x2ea3,_0x570392={},_0x5727ee=new Map(),_0x20f590=new Map();for(const _0x594a52 of _0xc657c5){if(!_0x594a52)continue;for(const [_0x40d2f1,_0x53c480]of Object[_0x3c82bf(0xa9)](_0x594a52)){const _0x24098b={'connection':_0x53c480[_0x3c82bf(0xdc)],..._0x53c480[_0x3c82bf(0xaa)]!==undefined&&{'all_columns':_0x53c480['all_columns']},..._0x53c480[_0x3c82bf(0xa0)]!==undefined&&{'columns':_0x53c480['columns']},..._0x53c480[_0x3c82bf(0xc6)]!==undefined&&{'behavior':_0x53c480[_0x3c82bf(0xc6)]},..._0x53c480[_0x3c82bf(0xd8)]!==undefined&&{'schedule':_0x53c480[_0x3c82bf(0xd8)]},..._0x53c480[_0x3c82bf(0x9f)]!==undefined&&{'notification':_0x53c480['notification']},..._0x53c480[_0x3c82bf(0xd4)]!==undefined&&{'connector_config':_0x53c480[_0x3c82bf(0xd4)]},..._0x53c480[_0x3c82bf(0xb2)]!==undefined&&{'activation_template_id':_0x53c480[_0x3c82bf(0xb2)]}},_0x585b8e=stableStringify(_0x24098b),_0x2f6076=_0x20f590['get'](_0x585b8e);_0x2f6076?_0x5727ee[_0x3c82bf(0xcf)](_0x40d2f1,_0x2f6076):(_0x570392[_0x40d2f1]=_0x53c480,_0x5727ee[_0x3c82bf(0xcf)](_0x40d2f1,_0x40d2f1),_0x20f590[_0x3c82bf(0xcf)](_0x585b8e,_0x40d2f1));}}return{'merged':_0x570392,'nameMapping':_0x5727ee};}export function updateActivationReferences(_0x5e0918,_0x5c823d){const _0x566799=a114_0x2ea3;if(!_0x5e0918)return;for(const _0x215a2a of _0x5e0918){if(!_0x215a2a[_0x566799(0xd7)])continue;for(const _0x70a4da of _0x215a2a['steps']){if(_0x70a4da[_0x566799(0xda)]===_0x566799(0xc7)&&_0x70a4da['with']?.[_0x566799(0xc7)]){const _0x744346=_0x5c823d[_0x566799(0xc9)](_0x70a4da[_0x566799(0xd6)][_0x566799(0xc7)]);_0x744346&&_0x744346!==_0x70a4da[_0x566799(0xd6)][_0x566799(0xc7)]&&(_0x70a4da['with'][_0x566799(0xc7)]=_0x744346);}}}}export function consolidateSegmentsByContent(_0x9e8543,_0x38e3dd){const _0x19741c=a114_0x2ea3,_0xe6bc6e={},_0x4ca1f8=new Map(),_0x1ecc9d=new Map();for(const _0x37b4a6 of _0x9e8543){if(!_0x37b4a6)continue;for(const [_0x541bf6,_0x14098d]of Object[_0x19741c(0xa9)](_0x37b4a6)){if(!_0x14098d['rule']){_0xe6bc6e[_0x541bf6]=_0x14098d,_0x4ca1f8[_0x19741c(0xcf)](_0x541bf6,_0x541bf6);continue;}const _0x1a0fdd=_0x14098d[_0x19741c(0xce)]&&_0x14098d[_0x19741c(0xce)][_0x19741c(0xe6)]()?_0x14098d[_0x19741c(0xce)]:undefined,_0x3bd379=JSON['stringify']({'description':_0x1a0fdd,'rule':deepSortObject(_0x14098d[_0x19741c(0xb8)])}),_0x26c01d=_0x1ecc9d[_0x19741c(0xc9)](_0x3bd379);if(_0x26c01d){const _0x47bca4={..._0x14098d[_0x19741c(0xce)]!==undefined&&{'description':_0x14098d['description']},'rule':_0x14098d[_0x19741c(0xb8)]?deepSortObject(_0x14098d['rule']):_0x14098d['rule']};if(_0x541bf6<_0x26c01d){_0xe6bc6e[_0x541bf6]=_0x47bca4,delete _0xe6bc6e[_0x26c01d];for(const [_0x5f2685,_0x22b929]of _0x4ca1f8[_0x19741c(0xa9)]()){_0x22b929===_0x26c01d&&_0x4ca1f8['set'](_0x5f2685,_0x541bf6);}_0x4ca1f8[_0x19741c(0xcf)](_0x541bf6,_0x541bf6),_0x1ecc9d['set'](_0x3bd379,_0x541bf6);}else _0xe6bc6e[_0x26c01d]=_0x47bca4,_0x4ca1f8[_0x19741c(0xcf)](_0x541bf6,_0x26c01d);}else{let _0x3dbb29=_0x541bf6;if(_0x38e3dd){const _0xbc0a61=_0x38e3dd['get'](_0x3bd379);_0xbc0a61&&_0xbc0a61[_0x19741c(0xde)]>0x0&&(_0x3dbb29=_0xbc0a61['slice']()[_0x19741c(0xe9)]()[0x0]);}const _0x35c886={..._0x14098d[_0x19741c(0xce)]!==undefined&&{'description':_0x14098d['description']},'rule':_0x14098d['rule']?deepSortObject(_0x14098d[_0x19741c(0xb8)]):_0x14098d[_0x19741c(0xb8)]};_0xe6bc6e[_0x3dbb29]=_0x35c886,_0x4ca1f8[_0x19741c(0xcf)](_0x541bf6,_0x3dbb29),_0x1ecc9d[_0x19741c(0xcf)](_0x3bd379,_0x3dbb29);}}}return{'merged':_0xe6bc6e,'nameMapping':_0x4ca1f8};}export function updateSegmentReferences(_0xee563f,_0x2adc19){const _0x192a80=a114_0x2ea3;if(!_0xee563f)return;for(const _0x1138a4 of _0xee563f){if(_0x1138a4[_0x192a80(0xe5)]?.[_0x192a80(0xdb)]){const _0x217975=_0x2adc19[_0x192a80(0xc9)](_0x1138a4[_0x192a80(0xe5)]['segment']);_0x217975&&(_0x1138a4[_0x192a80(0xe5)][_0x192a80(0xdb)]=_0x217975);}if(_0x1138a4[_0x192a80(0xd7)])for(const _0x3a2d77 of _0x1138a4[_0x192a80(0xd7)]){if(_0x3a2d77[_0x192a80(0xda)]===_0x192a80(0xb5)&&_0x3a2d77['with']?.['branches'])for(const _0x279216 of _0x3a2d77['with']['branches']){if(_0x279216[_0x192a80(0xdb)]){const _0x5b697e=_0x2adc19[_0x192a80(0xc9)](_0x279216[_0x192a80(0xdb)]);_0x5b697e&&(_0x279216['segment']=_0x5b697e);}}}}}export function updateSegmentRefsInSegments(_0x173f8a,_0x29c90f){const _0x42ce00=a114_0x2ea3;for(const _0x1d387c of Object['values'](_0x173f8a)){_0x1d387c[_0x42ce00(0xb8)]&&updateSegmentRefsInRule(_0x1d387c[_0x42ce00(0xb8)],_0x29c90f);}}function updateSegmentRefsInRule(_0x2a9966,_0x1471ce){const _0x575673=a114_0x2ea3;if(_0x2a9966===null||typeof _0x2a9966!==_0x575673(0xc1))return;if(Array[_0x575673(0xa3)](_0x2a9966)){for(const _0xed17b of _0x2a9966){updateSegmentRefsInRule(_0xed17b,_0x1471ce);}return;}const _0x5071bf=_0x2a9966;if((_0x5071bf[_0x575673(0xda)]===_0x575673(0xc3)||_0x5071bf[_0x575673(0xda)]===_0x575673(0xba))&&typeof _0x5071bf[_0x575673(0xdb)]===_0x575673(0xcc)){const _0x14fa01=_0x1471ce[_0x575673(0xc9)](_0x5071bf[_0x575673(0xdb)]);_0x14fa01&&(_0x5071bf[_0x575673(0xdb)]=_0x14fa01);}if(_0x5071bf[_0x575673(0xae)]&&Array['isArray'](_0x5071bf['conditions']))for(const _0x2c531c of _0x5071bf[_0x575673(0xae)]){updateSegmentRefsInRule(_0x2c531c,_0x1471ce);}}export function buildJourneysArray(_0xcc1e4a){const _0x337a5b=a114_0x2ea3,_0x18aad9=Math[_0x337a5b(0xd5)](..._0xcc1e4a[_0x337a5b(0xe2)](_0x27c760=>_0x27c760[_0x337a5b(0xcd)]['versionNumber']||0x0));return _0xcc1e4a[_0x337a5b(0xe2)](_0x23c7b2=>{const _0xb893d6=_0x337a5b,_0x401ca8=(_0x23c7b2[_0xb893d6(0xcd)]['versionNumber']||0x0)===_0x18aad9,_0x559d58=_0x23c7b2[_0xb893d6(0xad)][_0xb893d6(0xdf)]?.[0x0],_0x5b826b={'version':_0x559d58?.['version']||_0x23c7b2['yaml'][_0xb893d6(0xe7)]||_0x23c7b2['item'][_0xb893d6(0x9e)],'state':_0x23c7b2[_0xb893d6(0xcd)][_0xb893d6(0xa6)]===_0xb893d6(0xa4)?_0xb893d6(0xa4):_0xb893d6(0xca),'stages':_0x559d58?.[_0xb893d6(0xaf)]||_0x23c7b2[_0xb893d6(0xad)]['stages']||[],'id':_0x559d58?.['id']||_0x23c7b2['yaml']['id'],'version_number':_0x559d58?.[_0xb893d6(0xd3)]||_0x23c7b2[_0xb893d6(0xad)][_0xb893d6(0xd3)]};return _0x401ca8&&(_0x5b826b[_0xb893d6(0xd2)]=!![]),_0x5b826b;});}export function buildMergedJourneyDef(_0x3b966b,_0x449857){const _0x11fca3=a114_0x2ea3,_0x4fa1f8=_0x3b966b[0x0]['yaml'],_0x29038f=buildJourneysArray(_0x3b966b),{merged:_0x531352,nameMapping:_0x5330fd}=consolidateSegmentsByContent(_0x3b966b[_0x11fca3(0xe2)](_0x1f375b=>_0x1f375b[_0x11fca3(0xad)][_0x11fca3(0xbd)]),_0x449857);updateSegmentRefsInSegments(_0x531352,_0x5330fd);const _0x1db402=Array['from'](_0x5330fd['entries']())[_0x11fca3(0xb4)](([_0xfd42c2,_0x1f10cc])=>_0xfd42c2!==_0x1f10cc&&_0xfd42c2['startsWith'](_0x11fca3(0xe5)));let _0x162d41=_0x531352,_0x1f6832=new Map();if(_0x1db402){const _0x15ff89=consolidateSegmentsByContent([_0x531352],_0x449857);_0x162d41=_0x15ff89['merged'],_0x1f6832=_0x15ff89['nameMapping'];}const _0x22e748=new Map(_0x5330fd);for(const [_0x176b7c,_0x597c54]of _0x1f6832[_0x11fca3(0xa9)]()){_0x22e748[_0x11fca3(0xcf)](_0x176b7c,_0x597c54);}for(const [_0x5953f0,_0x504ae4]of _0x22e748[_0x11fca3(0xa9)]()){let _0x38afb7=_0x504ae4,_0x133ab5=0x0;while(_0x22e748[_0x11fca3(0xbc)](_0x38afb7)&&_0x22e748[_0x11fca3(0xc9)](_0x38afb7)!==_0x38afb7&&_0x133ab5<MAX_MAPPING_CHAIN_DEPTH){_0x38afb7=_0x22e748[_0x11fca3(0xc9)](_0x38afb7),_0x133ab5++;}_0x38afb7!==_0x504ae4&&_0x22e748[_0x11fca3(0xcf)](_0x5953f0,_0x38afb7);}for(const _0x579311 of _0x29038f){updateSegmentReferences(_0x579311[_0x11fca3(0xaf)],_0x22e748);}const {merged:_0x26cedf,nameMapping:_0x2dfe65}=consolidateActivationsByContent(_0x3b966b[_0x11fca3(0xe2)](_0xe52bc0=>_0xe52bc0['yaml'][_0x11fca3(0xe3)]));for(const _0x49f395 of _0x29038f){updateActivationReferences(_0x49f395[_0x11fca3(0xaf)],_0x2dfe65);}let _0x3289ea=_0x4fa1f8[_0x11fca3(0xeb)];if(_0x3289ea?.[_0x11fca3(0xdb)]){const _0x5abc5d=_0x22e748['get'](_0x3289ea['segment']);_0x5abc5d&&(_0x3289ea={..._0x3289ea,'segment':_0x5abc5d});}for(const _0x1350ef of _0x29038f){if(_0x1350ef[_0x11fca3(0xeb)]?.['segment']){const _0x8b0238=_0x22e748[_0x11fca3(0xc9)](_0x1350ef['goal'][_0x11fca3(0xdb)]);_0x8b0238&&(_0x1350ef[_0x11fca3(0xeb)]={..._0x1350ef[_0x11fca3(0xeb)],'segment':_0x8b0238});}}return{'type':_0x11fca3(0xdd),'name':_0x4fa1f8[_0x11fca3(0x9e)],'description':_0x4fa1f8['description'],'goal':_0x3289ea,'reentry':_0x4fa1f8[_0x11fca3(0xb9)],'segments':Object[_0x11fca3(0xa5)](_0x162d41)[_0x11fca3(0xde)]>0x0?_0x162d41:undefined,'activations':Object['keys'](_0x26cedf)[_0x11fca3(0xde)]>0x0?_0x26cedf:undefined,'journeys':_0x29038f,'bundle_id':_0x4fa1f8['bundle_id'],'bundle_name':_0x4fa1f8['bundle_name']};}export function createJumpTargetCache(){return new Map();}export async function resolveJumpTarget(_0x498ffa,_0x126323,_0x468110,_0x2085ca){const _0x26eb33=a114_0x2ea3,_0x94f1cc=_0x498ffa+':'+_0x126323,_0xf7f83c=_0x468110[_0x26eb33(0xc9)](_0x94f1cc);if(_0xf7f83c)return _0xf7f83c;const _0x401085=await _0x2085ca(_0x498ffa),_0x596714=_0x401085[_0x26eb33(0xc5)]['journeyBundleName']||_0x401085[_0x26eb33(0xc5)][_0x26eb33(0x9e)],_0x23cfd0=_0x401085[_0x26eb33(0xc5)][_0x26eb33(0xe8)]['find'](_0x25f641=>String(_0x25f641['id'])===String(_0x126323)),_0x4817b2=_0x23cfd0?.['name']||_0x126323,_0x41a5ca={'journeyName':_0x596714,'stageName':_0x4817b2};return _0x468110[_0x26eb33(0xcf)](_0x94f1cc,_0x41a5ca),_0x41a5ca;}export function formatApiJourneyName(_0x2fa49f,_0x2bcf52){return _0x2bcf52+'\x20('+_0x2fa49f+')';}function a114_0x269b(){const _0x16f943=['schedule','3237702vOToEl','type','segment','connection','journey','length','journeys','.yml','.yaml','map','activations','slice','entry_criteria','trim','version','journeyStages','sort','6779984DXApGo','goal','430734dunZCi','index','name','notification','columns','endsWith','495vrGfPT','isArray','launched','keys','state','19674cYtOwx','exit_criteria','entries','all_columns','replace','milestone','yaml','conditions','stages','condition','push','activation_template_id','versions','some','decision_point','62932ZAkwhm','join','rule','reentry','exclude','2555toCOtL','has','segments','wait','branches','null','object','toLowerCase','include','stringify','attributes','behavior','activation','match','get','draft','3969OPvvOe','string','item','description','set','1247665WxZnsQ','62770EeUSsl','latest','version_number','connector_config','max','with','steps'];a114_0x269b=function(){return _0x16f943;};return a114_0x269b();}export function isLocalJourneyRef(_0x396502){const _0x2fa9a6=a114_0x2ea3;return _0x396502[_0x2fa9a6(0xa1)](_0x2fa9a6(0xe0))||_0x396502[_0x2fa9a6(0xa1)](_0x2fa9a6(0xe1));}export function buildLocalRuleToNameMapping(_0x58bd4e){const _0x282bde=a114_0x2ea3,_0x5e67d0=new Map();if(!_0x58bd4e)return _0x5e67d0;for(const [_0x2af038,_0x18294e]of Object[_0x282bde(0xa9)](_0x58bd4e)){if(_0x18294e[_0x282bde(0xb8)]){const _0x35a4cf=serializeRule(_0x18294e[_0x282bde(0xb8)]),_0x498a94=_0x5e67d0[_0x282bde(0xc9)](_0x35a4cf)||[];_0x498a94[_0x282bde(0xb1)](_0x2af038),_0x5e67d0[_0x282bde(0xcf)](_0x35a4cf,_0x498a94);}}return _0x5e67d0;}function a114_0x2ea3(_0x4b22ef,_0x32a8a1){_0x4b22ef=_0x4b22ef-0x9c;const _0x269bc8=a114_0x269b();let _0x2ea356=_0x269bc8[_0x4b22ef];return _0x2ea356;}export function buildLocalRuleToNameMappingFromJourney(_0x4970db){const _0x409e73=a114_0x2ea3,_0x59ca4c=_0x4970db['segments'];if(!_0x59ca4c)return new Map();const _0x4192cd=collectSegmentUsageCounts(_0x4970db),_0x272bf5=new Map();let _0x496629=0x0;for(const [_0x302b4,_0x1a3902]of Object[_0x409e73(0xa9)](_0x59ca4c)){if(!_0x1a3902['rule']){_0x496629++;continue;}const _0x4aedee=serializeRule(_0x1a3902[_0x409e73(0xb8)]),_0xafdd5d=_0x272bf5[_0x409e73(0xc9)](_0x4aedee)||[];_0xafdd5d[_0x409e73(0xb1)]({'name':_0x302b4,'index':_0x496629}),_0x272bf5[_0x409e73(0xcf)](_0x4aedee,_0xafdd5d),_0x496629++;}const _0x15b31f=new Map();for(const [_0x182b48,_0x20376c]of _0x272bf5){const _0x2fe346=_0x20376c[_0x409e73(0xe4)]()[_0x409e73(0xe9)]((_0x3c56a5,_0x577ce9)=>{const _0x500a97=_0x409e73,_0x2b4b85=_0x4192cd[_0x500a97(0xc9)](_0x3c56a5[_0x500a97(0x9e)])||0x0,_0x6dd3c2=_0x4192cd[_0x500a97(0xc9)](_0x577ce9['name'])||0x0;if(_0x2b4b85!==_0x6dd3c2)return _0x6dd3c2-_0x2b4b85;return _0x3c56a5['index']-_0x577ce9[_0x500a97(0x9d)];})[_0x409e73(0xe2)](_0x555de9=>_0x555de9[_0x409e73(0x9e)]);_0x15b31f[_0x409e73(0xcf)](_0x182b48,_0x2fe346);}return _0x15b31f;}export function collectSegmentUsageCounts(_0x2fbb59){const _0x2e01f8=a114_0x2ea3,_0x1f68e2=new Map(),_0x567038=_0xa4edd5=>{const _0x3e93c8=a114_0x2ea3;if(!_0xa4edd5)return;_0x1f68e2[_0x3e93c8(0xcf)](_0xa4edd5,(_0x1f68e2[_0x3e93c8(0xc9)](_0xa4edd5)||0x0)+0x1);},_0x65d843=_0x994cf9=>{const _0x50ef28=a114_0x2ea3;for(const _0x314b75 of _0x994cf9){_0x567038(_0x314b75[_0x50ef28(0xe5)]?.[_0x50ef28(0xdb)]);if(_0x314b75[_0x50ef28(0xa8)])for(const _0x4c8517 of _0x314b75[_0x50ef28(0xa8)]){_0x567038(_0x4c8517[_0x50ef28(0xdb)]);}_0x567038(_0x314b75[_0x50ef28(0xac)]?.[_0x50ef28(0xdb)]);if(_0x314b75[_0x50ef28(0xd7)])for(const _0x2e769f of _0x314b75[_0x50ef28(0xd7)]){if(_0x2e769f['type']==='decision_point')for(const _0x5f5cc5 of _0x2e769f[_0x50ef28(0xd6)][_0x50ef28(0xbf)]){_0x567038(_0x5f5cc5[_0x50ef28(0xdb)]);}else _0x2e769f[_0x50ef28(0xda)]===_0x50ef28(0xbe)&&_0x567038(_0x2e769f[_0x50ef28(0xd6)][_0x50ef28(0xb0)]?.[_0x50ef28(0xdb)]);}}};_0x567038(_0x2fbb59[_0x2e01f8(0xeb)]?.[_0x2e01f8(0xdb)]);if(_0x2fbb59[_0x2e01f8(0xdf)])for(const _0x3593dc of _0x2fbb59['journeys']){_0x567038(_0x3593dc[_0x2e01f8(0xeb)]?.['segment']),_0x65d843(_0x3593dc['stages']);}_0x2fbb59[_0x2e01f8(0xaf)]&&_0x65d843(_0x2fbb59[_0x2e01f8(0xaf)]);if(_0x2fbb59[_0x2e01f8(0xb3)])for(const _0x977ff9 of _0x2fbb59[_0x2e01f8(0xb3)]){_0x65d843(_0x977ff9[_0x2e01f8(0xaf)]);}return _0x1f68e2;}
|