@treasuredata/tdx 2026.3.46 → 2026.3.48
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bin.js +1 -1
- package/dist/build-info.json +3 -3
- package/dist/cli-categories.js +1 -1
- package/dist/cli.js +1 -1
- package/dist/commands/activations.js +1 -1
- package/dist/commands/agent-command.js +1 -1
- package/dist/commands/agent-test-command.js +1 -1
- package/dist/commands/api-command.js +1 -1
- package/dist/commands/auth-command.js +1 -1
- package/dist/commands/auth-login-command.js +1 -1
- package/dist/commands/cas-command.js +1 -1
- package/dist/commands/cas-segment-command.js +1 -1
- package/dist/commands/chat-command.js +1 -1
- package/dist/commands/claude-command.js +1 -1
- package/dist/commands/claude-statusline-command.js +1 -1
- package/dist/commands/claude-usage-command.js +1 -1
- package/dist/commands/command.js +1 -1
- package/dist/commands/connection-command.js +1 -1
- package/dist/commands/databases.js +1 -1
- package/dist/commands/delivery-command.js +1 -1
- package/dist/commands/describe.js +1 -1
- package/dist/commands/engage-campaign-pull-command.js +1 -1
- package/dist/commands/engage-campaign-push-command.js +1 -1
- package/dist/commands/engage-campaign-validate-command.js +1 -1
- package/dist/commands/engage-command.js +1 -1
- package/dist/commands/engage-template-pull-command.js +1 -1
- package/dist/commands/engage-template-push-command.js +1 -1
- package/dist/commands/engage-template-validate-command.js +1 -1
- package/dist/commands/job-command.js +1 -1
- package/dist/commands/journey-command.js +1 -1
- package/dist/commands/journey-validate-command.js +1 -1
- package/dist/commands/llm-command.js +1 -1
- package/dist/commands/mcp-command.js +1 -1
- package/dist/commands/parent-segment-command.js +1 -1
- package/dist/commands/policy-command.js +1 -1
- package/dist/commands/profile-command.js +1 -1
- package/dist/commands/profiles-command.js +1 -1
- package/dist/commands/query-command.js +1 -1
- package/dist/commands/schedule-command.js +1 -1
- package/dist/commands/segment-command.js +1 -1
- package/dist/commands/segment-create-command.js +1 -1
- package/dist/commands/segment-fields-command.js +1 -1
- package/dist/commands/segment-pull-command.js +1 -1
- package/dist/commands/segment-push-command.js +1 -1
- package/dist/commands/segment-update-command.js +1 -1
- package/dist/commands/segment-use-command.js +1 -1
- package/dist/commands/segment-validate-command.js +1 -1
- package/dist/commands/segments.js +1 -1
- package/dist/commands/show.js +1 -1
- package/dist/commands/status-command.js +1 -1
- package/dist/commands/tables.js +1 -1
- package/dist/commands/unset-command.js +1 -1
- package/dist/commands/upgrade-command.js +1 -1
- package/dist/commands/use-command.js +1 -1
- package/dist/commands/user-command.js +1 -1
- package/dist/commands/work-command.js +1 -1
- package/dist/commands/workflow-command.js +1 -1
- package/dist/core/auth.js +1 -1
- package/dist/core/command-output.js +1 -1
- package/dist/core/config.js +1 -1
- package/dist/core/connection-cache.js +1 -1
- package/dist/core/constants.js +1 -1
- package/dist/core/credential-cache.js +1 -1
- package/dist/core/global-context.js +1 -1
- package/dist/core/keychain.js +1 -1
- package/dist/core/oauth-keychain.js +1 -1
- package/dist/core/oauth.js +1 -1
- package/dist/core/profile.js +1 -1
- package/dist/core/project-config.js +1 -1
- package/dist/core/session.js +1 -1
- package/dist/core/user-cache.js +1 -1
- package/dist/core/version.js +1 -1
- package/dist/index.js +1 -1
- package/dist/mcp/server.js +1 -1
- package/dist/mcp/tools/index.js +1 -1
- package/dist/mcp/tools/tdx-run.js +1 -1
- package/dist/mcp/tools/tdx-search.js +1 -1
- package/dist/mcp/utils.js +1 -1
- package/dist/proxy/claude-usage-tracker.js +1 -1
- package/dist/proxy/passthrough-server.js +1 -1
- package/dist/proxy/sse-usage-parser.js +1 -1
- package/dist/sdk/agent/agent-config.js +1 -1
- package/dist/sdk/agent/agent-ref-parser.js +1 -1
- package/dist/sdk/agent/agent-yaml.js +1 -1
- package/dist/sdk/agent/test/evaluator.js +1 -1
- package/dist/sdk/agent/test/executor.js +1 -1
- package/dist/sdk/agent/test/index.js +1 -1
- package/dist/sdk/agent/test/output.js +1 -1
- package/dist/sdk/agent/test/parser.js +1 -1
- package/dist/sdk/agent/tool-target-registry.js +1 -1
- package/dist/sdk/api.js +1 -1
- package/dist/sdk/cas/cas-api-client.js +1 -1
- package/dist/sdk/cas/cas-audience-yaml.js +1 -1
- package/dist/sdk/cas/cas-segment-yaml.js +1 -1
- package/dist/sdk/cas/index.js +1 -1
- package/dist/sdk/cas/pull-workflow.js +1 -1
- package/dist/sdk/cas/push-workflow.js +1 -1
- package/dist/sdk/client/cdp-api-client.js +1 -1
- package/dist/sdk/client/delivery-api-client.js +1 -1
- package/dist/sdk/client/endpoints.js +1 -1
- package/dist/sdk/client/engage-api-client.js +1 -1
- package/dist/sdk/client/http-client.js +1 -1
- package/dist/sdk/client/llm-api-client.js +1 -1
- package/dist/sdk/client/oauth-refresh.js +1 -1
- package/dist/sdk/client/rate-limiter.js +1 -1
- package/dist/sdk/client/td-api-client.js +1 -1
- package/dist/sdk/client/trino-api-client.js +1 -1
- package/dist/sdk/client/workflow-client.js +1 -1
- package/dist/sdk/connection-validator.js +1 -1
- package/dist/sdk/connection.js +1 -1
- package/dist/sdk/delivery.js +1 -1
- package/dist/sdk/engage/campaign-pull.js +1 -1
- package/dist/sdk/engage/campaign-push.js +1 -1
- package/dist/sdk/engage/campaign-validator.js +1 -1
- package/dist/sdk/engage/campaign-yaml.js +1 -1
- package/dist/sdk/engage/template-pull.js +1 -1
- package/dist/sdk/engage/template-push.js +1 -1
- package/dist/sdk/engage/template-validator.js +1 -1
- package/dist/sdk/engage/template-yaml.js +1 -1
- package/dist/sdk/engage/types/campaign-def.js +1 -1
- package/dist/sdk/engage/types/campaign-schema.js +1 -1
- package/dist/sdk/engage/types/template-schema.js +1 -1
- package/dist/sdk/engage.js +1 -1
- package/dist/sdk/errors.js +1 -1
- package/dist/sdk/index.js +1 -1
- package/dist/sdk/io/index.js +1 -1
- package/dist/sdk/io/node-filesystem.js +1 -1
- package/dist/sdk/job.js +1 -1
- package/dist/sdk/journey.js +1 -1
- package/dist/sdk/llm/chat-cache.js +1 -1
- package/dist/sdk/llm/index.js +1 -1
- package/dist/sdk/llm/llm-backup-utils.js +1 -1
- package/dist/sdk/llm/model-factors.js +1 -1
- package/dist/sdk/personalization.js +1 -1
- package/dist/sdk/policy.js +1 -1
- package/dist/sdk/query/index.js +1 -1
- package/dist/sdk/query/sql-parser.js +1 -1
- package/dist/sdk/realtime.js +1 -1
- package/dist/sdk/schedule.js +1 -1
- package/dist/sdk/segment/child-segment-yaml.js +1 -1
- package/dist/sdk/segment/fields-display.js +1 -1
- package/dist/sdk/segment/file-discovery.js +1 -1
- package/dist/sdk/segment/journey-utils.js +1 -1
- package/dist/sdk/segment/journey-validator.js +1 -1
- package/dist/sdk/segment/journey-yaml.js +1 -1
- package/dist/sdk/segment/parent-segment-preview.js +1 -1
- package/dist/sdk/segment/parent-segment-yaml.js +1 -1
- package/dist/sdk/segment/pull-workflow.js +1 -1
- package/dist/sdk/segment/push-recovery.js +1 -1
- package/dist/sdk/segment/push-workflow.js +1 -1
- package/dist/sdk/segment/resolution-context.js +1 -1
- package/dist/sdk/segment/segment-path-parser.js +1 -1
- package/dist/sdk/segment/segment-ref-parser.js +1 -1
- package/dist/sdk/segment/segment-validator.js +1 -1
- package/dist/sdk/segment/target-resolution.js +1 -1
- package/dist/sdk/segment/tdx-config.js +1 -1
- package/dist/sdk/segment/types/activation-schema.js +1 -1
- package/dist/sdk/segment/types/journey-def.js +1 -1
- package/dist/sdk/segment/types/journey-schema.js +1 -1
- package/dist/sdk/segment/types/segment-def.js +1 -1
- package/dist/sdk/segment/types/segment-schema.js +1 -1
- package/dist/sdk/segment/validate-files.js +1 -1
- package/dist/sdk/segment/yaml-validator.js +1 -1
- package/dist/sdk/segment.js +1 -1
- package/dist/sdk/types/index.js +1 -1
- package/dist/sdk/types/progress.js +1 -1
- package/dist/sdk/types/workspace.js +1 -1
- package/dist/sdk/user.js +1 -1
- package/dist/sdk/util/format-detector.js +1 -1
- package/dist/sdk/util/formatters.js +1 -1
- package/dist/sdk/util/index.js +1 -1
- package/dist/sdk/util/paginate.js +1 -1
- package/dist/sdk/util/tree-formatter.js +1 -1
- package/dist/sdk/workflow/archive-validation.js +1 -1
- package/dist/sdk/workflow/clone-workflow.js +1 -1
- package/dist/sdk/workflow/index.js +1 -1
- package/dist/sdk/workflow/pull-workflow.js +1 -1
- package/dist/sdk/workflow/push-workflow.js +1 -1
- package/dist/sdk/workflow/tdx-config.js +1 -1
- package/dist/sdk/workflow/workflow-utils.js +1 -1
- package/dist/sdk/workspace/builtin-schedules/builtin-schedules/execute-items/TASK.md +62 -0
- package/dist/sdk/workspace/builtin-schedules/builtin-schedules/execute-items/schedule.yaml +20 -0
- package/dist/sdk/workspace/builtin-schedules/builtin-schedules/item-triage/TASK.md +106 -0
- package/dist/sdk/workspace/builtin-schedules/builtin-schedules/item-triage/schedule.yaml +18 -0
- package/dist/sdk/workspace/builtin-schedules/builtin-schedules/stale-item-cleanup/TASK.md +26 -0
- package/dist/sdk/workspace/builtin-schedules/builtin-schedules/stale-item-cleanup/schedule.yaml +15 -0
- package/dist/sdk/workspace/builtin-schedules/builtin-schedules/synthesize-knowledge/TASK.md +26 -0
- package/dist/sdk/workspace/builtin-schedules/builtin-schedules/synthesize-knowledge/schedule.yaml +16 -0
- package/dist/sdk/workspace/builtin-schedules/builtin-schedules/weekly-review/TASK.md +21 -0
- package/dist/sdk/workspace/builtin-schedules/builtin-schedules/weekly-review/schedule.yaml +14 -0
- package/dist/sdk/workspace/builtin-schedules/execute-items/TASK.md +62 -0
- package/dist/sdk/workspace/builtin-schedules/execute-items/schedule.yaml +20 -0
- package/dist/sdk/workspace/builtin-schedules/item-triage/TASK.md +106 -0
- package/dist/sdk/workspace/builtin-schedules/item-triage/schedule.yaml +18 -0
- package/dist/sdk/workspace/builtin-schedules/stale-item-cleanup/TASK.md +26 -0
- package/dist/sdk/workspace/builtin-schedules/stale-item-cleanup/schedule.yaml +15 -0
- package/dist/sdk/workspace/builtin-schedules/synthesize-knowledge/TASK.md +26 -0
- package/dist/sdk/workspace/builtin-schedules/synthesize-knowledge/schedule.yaml +16 -0
- package/dist/sdk/workspace/builtin-schedules/weekly-review/TASK.md +21 -0
- package/dist/sdk/workspace/builtin-schedules/weekly-review/schedule.yaml +14 -0
- package/dist/sdk/workspace/frontmatter.js +1 -1
- package/dist/sdk/workspace/git.js +1 -1
- package/dist/sdk/workspace/index.d.ts +5 -1
- package/dist/sdk/workspace/index.d.ts.map +1 -1
- package/dist/sdk/workspace/index.js +1 -1
- package/dist/sdk/workspace/index.js.map +1 -1
- package/dist/sdk/workspace/templates.js +1 -1
- package/dist/sdk/workspace/weekly.js +1 -1
- package/dist/sdk/workspace/wikilinks.js +1 -1
- package/dist/test-utils/command-runner.js +1 -1
- package/dist/test-utils/factories.js +1 -1
- package/dist/test-utils/fixtures.js +1 -1
- package/dist/test-utils/http-mock.js +1 -1
- package/dist/test-utils/index.js +1 -1
- package/dist/utils/async.js +1 -1
- package/dist/utils/colors.js +1 -1
- package/dist/utils/diff.js +1 -1
- package/dist/utils/file-permissions.js +1 -1
- package/dist/utils/file-reader.js +1 -1
- package/dist/utils/github-releases.js +1 -1
- package/dist/utils/global-cache.js +1 -1
- package/dist/utils/json-loader.js +1 -1
- package/dist/utils/local-cache.js +1 -1
- package/dist/utils/logger/formatters/default-formatter.js +1 -1
- package/dist/utils/logger/formatters/index.js +1 -1
- package/dist/utils/logger/handlers/console-handler.js +1 -1
- package/dist/utils/logger/handlers/file-handler.js +1 -1
- package/dist/utils/logger/handlers/index.js +1 -1
- package/dist/utils/logger/handlers/null-handler.js +1 -1
- package/dist/utils/logger/index.js +1 -1
- package/dist/utils/logger/logger.js +1 -1
- package/dist/utils/logger/types.js +1 -1
- package/dist/utils/option-validation.js +1 -1
- package/dist/utils/process.js +1 -1
- package/dist/utils/prompt.js +1 -1
- package/dist/utils/spinner.js +1 -1
- package/dist/utils/sse-parser.js +1 -1
- package/dist/utils/string-utils.js +1 -1
- package/dist/utils/table-ref-parser.js +1 -1
- package/dist/utils/tdx-logger.js +1 -1
- package/dist/utils/version-check.js +1 -1
- package/package.json +2 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
const a32_0x3c5e89=a32_0x375c;(function(_0x1c4495,_0x48ef97){const _0x469c25=a32_0x375c,_0x48e98b=_0x1c4495();while(!![]){try{const _0x3e6dee=parseInt(_0x469c25(0x2d5))/0x1*(-parseInt(_0x469c25(0x2af))/0x2)+parseInt(_0x469c25(0x348))/0x3+-parseInt(_0x469c25(0x1ec))/0x4*(parseInt(_0x469c25(0x30e))/0x5)+-parseInt(_0x469c25(0x2fa))/0x6*(parseInt(_0x469c25(0x1db))/0x7)+parseInt(_0x469c25(0x29f))/0x8+parseInt(_0x469c25(0x226))/0x9+parseInt(_0x469c25(0x244))/0xa;if(_0x3e6dee===_0x48ef97)break;else _0x48e98b['push'](_0x48e98b['shift']());}catch(_0x4c7b42){_0x48e98b['push'](_0x48e98b['shift']());}}}(a32_0x3f58,0x72e66));import{writeFileSync,readFileSync,existsSync,mkdirSync,renameSync,statSync}from'fs';import{spawn}from'child_process';import a32_0x40546c from'path';import{BaseCommand}from'./command.js';import{handleSDKOutput,handleQueryOutput,handleSingleObjectOutput,writeOutput}from'../core/command-output.js';import{withSpinner,withProgressSpinner,createCommandSpinner,formatElapsed}from'../utils/spinner.js';import{loadJSONFromOptions,loadJSON}from'../utils/json-loader.js';import{generateDiff,formatDiffWithColors,hasChanges}from'../utils/diff.js';import{getConsoleUrl,getConsoleNextUrl}from'../sdk/client/endpoints.js';import{formatRows,formatAsTable,hyperlink}from'../sdk/util/formatters.js';import{parseDef,serializeDef}from'../sdk/segment/parent-segment-yaml.js';import{confirmKey,isInteractive}from'../utils/prompt.js';import{DEFAULT_DISPLAY_LIMIT,resolveLimit}from'../core/constants.js';import a32_0x54ffbd from'chalk';import{displayFieldsHumanReadable,executeSchemaQuery}from'../sdk/segment/fields-display.js';import{saveSessionContext}from'../core/session.js';import{sanitizeFileName}from'../utils/string-utils.js';const PARENT_SEGMENT_DIR='parent_segments',LEGACY_PARENT_SEGMENT_DIR='parent_segment';function openBrowser(_0xe51b24){const _0x4259e7=a32_0x375c,_0x514744=process[_0x4259e7(0x1bd)],_0x59ae1a=_0x514744==='darwin'?_0x4259e7(0x2ea):_0x514744===_0x4259e7(0x3aa)?_0x4259e7(0x357):_0x4259e7(0x354);spawn(_0x59ae1a,[_0xe51b24],{'detached':!![],'stdio':_0x4259e7(0x219)})[_0x4259e7(0x2bf)]();}function migrateLegacyDirectory(){const _0x3dd9e8=a32_0x375c;if(!existsSync(LEGACY_PARENT_SEGMENT_DIR))return![];const _0x5cc545=statSync(LEGACY_PARENT_SEGMENT_DIR);if(!_0x5cc545[_0x3dd9e8(0x306)]())return![];if(existsSync(PARENT_SEGMENT_DIR))return console[_0x3dd9e8(0x3bd)](a32_0x54ffbd['yellow'](_0x3dd9e8(0x2bb)+LEGACY_PARENT_SEGMENT_DIR+_0x3dd9e8(0x2f5)+PARENT_SEGMENT_DIR+'/\x20directories\x20exist.')),console[_0x3dd9e8(0x3bd)](a32_0x54ffbd[_0x3dd9e8(0x2f6)](_0x3dd9e8(0x1b3)+LEGACY_PARENT_SEGMENT_DIR+'/\x20directory.\x0a')),![];console[_0x3dd9e8(0x3bd)](a32_0x54ffbd[_0x3dd9e8(0x24d)](_0x3dd9e8(0x23e)+LEGACY_PARENT_SEGMENT_DIR+_0x3dd9e8(0x379)+PARENT_SEGMENT_DIR+'/\x0a'));try{return renameSync(LEGACY_PARENT_SEGMENT_DIR,PARENT_SEGMENT_DIR),console['error'](a32_0x54ffbd[_0x3dd9e8(0x1d8)](_0x3dd9e8(0x338)+PARENT_SEGMENT_DIR+'/\x0a')),!![];}catch(_0x2e093e){const _0x2eda69=_0x2e093e instanceof Error?_0x2e093e['message']:String(_0x2e093e);return console[_0x3dd9e8(0x3bd)](a32_0x54ffbd[_0x3dd9e8(0x2cb)](_0x3dd9e8(0x249)+_0x2eda69+'\x0a')),![];}}class BaseParentSegmentCommand extends BaseCommand{async[a32_0x3c5e89(0x3b1)](_0x1d0867){const _0x1e2348=a32_0x3c5e89;return migrateLegacyDirectory(),super[_0x1e2348(0x3b1)](_0x1d0867);}}function resolveYamlFile(_0x3a5ffa){const _0x2bdaff=a32_0x3c5e89;if(_0x3a5ffa[_0x2bdaff(0x3b2)](_0x2bdaff(0x352))||_0x3a5ffa[_0x2bdaff(0x3b2)](_0x2bdaff(0x2d8)))return _0x3a5ffa;return a32_0x40546c[_0x2bdaff(0x296)](PARENT_SEGMENT_DIR,sanitizeFileName(_0x3a5ffa)+_0x2bdaff(0x352));}function formatProgressMessage(_0x799410){const _0x3f192b=a32_0x3c5e89,_0x194be9=_0x799410['match'](/^(.+?):\s*(.+?)(\s*\(.+\))?$/);if(_0x194be9){const [,_0xb718e1,_0x262c11,_0xd3ac2f='']=_0x194be9;return a32_0x54ffbd[_0x3f192b(0x2f6)](_0xb718e1+':')+'\x20'+_0x262c11+a32_0x54ffbd['dim'](_0xd3ac2f);}return a32_0x54ffbd[_0x3f192b(0x2f6)](_0x799410);}function showFileNotFoundError(_0x1f9476,_0x1cb354){const _0x42e107=a32_0x3c5e89;console[_0x42e107(0x3bd)](a32_0x54ffbd[_0x42e107(0x2cb)](_0x42e107(0x286)+_0x1f9476+'\x0a')),console[_0x42e107(0x3bd)](a32_0x54ffbd[_0x42e107(0x30f)](_0x42e107(0x398)+_0x1cb354+'`\x20to\x20download\x20the\x20configuration\x20first'));}function displayRealtimeValidation(_0x4c588e){const _0x4a1ab3=a32_0x3c5e89;if(!_0x4c588e[_0x4a1ab3(0x1f1)])return;const _0x35dbd6=_0x4c588e[_0x4a1ab3(0x1f1)],_0x14514c=_0x35dbd6[_0x4a1ab3(0x1c8)]?a32_0x54ffbd[_0x4a1ab3(0x1d8)]('⚡\x20Enabled'):a32_0x54ffbd[_0x4a1ab3(0x24d)](_0x4a1ab3(0x1dc));console[_0x4a1ab3(0x3bd)]('\x0a'+a32_0x54ffbd[_0x4a1ab3(0x2f6)](_0x4a1ab3(0x27a))+'\x20'+_0x14514c);if(_0x35dbd6['events']&&_0x35dbd6[_0x4a1ab3(0x218)][_0x4a1ab3(0x30a)]>0x0){console[_0x4a1ab3(0x3bd)]('\x20\x20'+a32_0x54ffbd[_0x4a1ab3(0x2f6)](_0x4a1ab3(0x1e9))+'\x20'+_0x35dbd6['events'][_0x4a1ab3(0x30a)]+_0x4a1ab3(0x290));for(const _0x50c62f of _0x35dbd6[_0x4a1ab3(0x218)]){const _0x48b535=_0x50c62f[_0x4a1ab3(0x201)]===![]?a32_0x54ffbd[_0x4a1ab3(0x2cb)]('✘'):a32_0x54ffbd[_0x4a1ab3(0x1d8)]('✔');console[_0x4a1ab3(0x3bd)](_0x4a1ab3(0x308)+_0x48b535+'\x20'+_0x50c62f[_0x4a1ab3(0x37d)]),_0x50c62f[_0x4a1ab3(0x35e)]&&console['error'](_0x4a1ab3(0x1de)+a32_0x54ffbd[_0x4a1ab3(0x2cb)](_0x50c62f[_0x4a1ab3(0x35e)]));}}if(_0x35dbd6[_0x4a1ab3(0x370)]&&_0x35dbd6[_0x4a1ab3(0x370)]['length']>0x0){console['error']('\x20\x20'+a32_0x54ffbd[_0x4a1ab3(0x2f6)](_0x4a1ab3(0x2ec))+'\x20'+_0x35dbd6['attributes'][_0x4a1ab3(0x30a)]+'\x20configured');for(const _0x3e1bc1 of _0x35dbd6[_0x4a1ab3(0x370)]){const _0x2369e5=_0x3e1bc1[_0x4a1ab3(0x323)]?a32_0x54ffbd[_0x4a1ab3(0x1d8)]('✔'):a32_0x54ffbd['red']('✘');console[_0x4a1ab3(0x3bd)]('\x20\x20\x20\x20'+_0x2369e5+'\x20'+_0x3e1bc1[_0x4a1ab3(0x37d)]+'\x20'+a32_0x54ffbd['dim']('('+_0x3e1bc1[_0x4a1ab3(0x1b4)]+')'));}}if(_0x35dbd6[_0x4a1ab3(0x3a4)]){const _0x16c5ee=_0x35dbd6['idStitching'][_0x4a1ab3(0x37b)]?.[_0x4a1ab3(0x30a)]?_0x4a1ab3(0x1e3)+_0x35dbd6[_0x4a1ab3(0x3a4)][_0x4a1ab3(0x37b)][_0x4a1ab3(0x296)](',\x20')+']':'';console[_0x4a1ab3(0x3bd)]('\x20\x20'+a32_0x54ffbd[_0x4a1ab3(0x2f6)]('ID\x20Stitching:')+'\x20'+_0x35dbd6['idStitching'][_0x4a1ab3(0x39b)]+_0x16c5ee);}if(_0x35dbd6['personalizationServices']&&_0x35dbd6[_0x4a1ab3(0x23d)][_0x4a1ab3(0x30a)]>0x0){console[_0x4a1ab3(0x3bd)]('\x20\x20'+a32_0x54ffbd[_0x4a1ab3(0x2f6)](_0x4a1ab3(0x2b1))+'\x20'+_0x35dbd6[_0x4a1ab3(0x23d)]['length']+_0x4a1ab3(0x2b8)+(_0x35dbd6[_0x4a1ab3(0x23d)][_0x4a1ab3(0x30a)]!==0x1?'s':''));for(const _0x19a399 of _0x35dbd6[_0x4a1ab3(0x23d)]){console['error'](_0x4a1ab3(0x2f0)+_0x19a399[_0x4a1ab3(0x37d)]);}}}function showParentSegmentNotSetError(_0x2e96d2){const _0x5dae1b=a32_0x3c5e89;console[_0x5dae1b(0x3bd)](a32_0x54ffbd[_0x5dae1b(0x24d)]('parent_segment\x20is\x20not\x20set.\x20Use\x20`tdx\x20ps\x20use\x20<name>`\x20to\x20set\x20it.\x0a')),console[_0x5dae1b(0x3bd)](_0x2e96d2);}export class ParentSegmentListCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]=a32_0x3c5e89(0x261);['description']=a32_0x3c5e89(0x222);async['execute'](_0x7b08b0){const _0x3d093e=a32_0x3c5e89,{options:_0x114dd4,args:_0x43d808,tdx:_0x5e472}=_0x7b08b0,_0x30e870=_0x43d808[0x0];_0x114dd4['verbose']&&(console[_0x3d093e(0x3bd)](_0x3d093e(0x39e)+_0x114dd4[_0x3d093e(0x1d1)]),_0x30e870&&console[_0x3d093e(0x3bd)](_0x3d093e(0x35f)+_0x30e870));const _0x5f5dda=await withSpinner(_0x30e870?_0x3d093e(0x24c)+_0x30e870+_0x3d093e(0x288):'Listing\x20parent\x20segments...',()=>_0x5e472[_0x3d093e(0x1f3)][_0x3d093e(0x298)](),{'verbose':_0x114dd4['verbose']});let _0x222dba=_0x5f5dda[_0x3d093e(0x1ad)];if(_0x30e870){const _0x4eb04d=_0x30e870[_0x3d093e(0x3bf)](/[.+^${}()|[\]\\]/g,_0x3d093e(0x391))[_0x3d093e(0x3bf)](/\*/g,'.*')[_0x3d093e(0x3bf)](/\?/g,'.'),_0x45a5b6=new RegExp('^'+_0x4eb04d+'$','i');_0x222dba=_0x222dba[_0x3d093e(0x2d1)](_0x5e98aa=>_0x45a5b6[_0x3d093e(0x2fd)](_0x5e98aa[_0x3d093e(0x370)]['name']));}_0x222dba[_0x3d093e(0x385)]((_0xcda5a9,_0x5b985a)=>_0xcda5a9['attributes'][_0x3d093e(0x37d)][_0x3d093e(0x20d)](_0x5b985a[_0x3d093e(0x370)][_0x3d093e(0x37d)])),console[_0x3d093e(0x3bd)]('✔\x20Found\x20'+_0x222dba[_0x3d093e(0x30a)]+_0x3d093e(0x39a)+(_0x222dba[_0x3d093e(0x30a)]!==0x1?'s':''));const _0x7ddb9c=_0x41c1b5=>{const _0x3d4976=_0x3d093e;return getConsoleNextUrl(_0x114dd4[_0x3d4976(0x1d1)],_0x3d4976(0x24f)+_0x41c1b5);};if(_0x114dd4['format']===_0x3d093e(0x2e5)||_0x114dd4[_0x3d093e(0x3b3)]===_0x3d093e(0x1ae)){const _0x4b7ca5=_0x222dba[_0x3d093e(0x383)](_0x168064=>({..._0x168064,'url':_0x7ddb9c(_0x168064['id'])}));await handleSDKOutput(_0x4b7ca5,_0x114dd4);}else{if(_0x222dba[_0x3d093e(0x30a)]===0x0)_0x30e870?console[_0x3d093e(0x2c0)](_0x3d093e(0x2ac)+_0x30e870):console[_0x3d093e(0x2c0)](_0x3d093e(0x37e));else for(const _0x31bc10 of _0x222dba){const _0x5de175=_0x31bc10['attributes'][_0x3d093e(0x38c)]?a32_0x54ffbd[_0x3d093e(0x2f6)]('\x20('+formatRows(_0x31bc10[_0x3d093e(0x370)][_0x3d093e(0x38c)])+')'):'',_0xd084df=hyperlink(_0x31bc10[_0x3d093e(0x370)]['name'],_0x7ddb9c(_0x31bc10['id']));console[_0x3d093e(0x2c0)](_0x3d093e(0x34f)+_0xd084df+_0x5de175);}}return 0x0;}}export class ParentSegmentCreateCommand extends BaseCommand{['name']=a32_0x3c5e89(0x267);[a32_0x3c5e89(0x297)]='Create\x20new\x20parent\x20segment\x20(audience)\x20[DEPRECATED]';async['execute'](_0x288ac5){const _0x319bbc=a32_0x3c5e89,{options:_0x57726e,args:_0xce66be,tdx:_0x3a3cc3}=_0x288ac5;console['error'](_0x319bbc(0x2c2)+_0x319bbc(0x3b0)+_0x319bbc(0x22d));const _0x1d61d4=_0x57726e;if(_0xce66be[_0x319bbc(0x30a)]===0x0)return console[_0x319bbc(0x3bd)](a32_0x54ffbd[_0x319bbc(0x2cb)](_0x319bbc(0x2e1))),console[_0x319bbc(0x3bd)](_0x319bbc(0x2c7)),0x1;const _0x28e070=_0xce66be[0x0];if(!_0x1d61d4[_0x319bbc(0x279)]||!_0x1d61d4[_0x319bbc(0x20a)])return console[_0x319bbc(0x3bd)]('Error:\x20--database\x20and\x20--table\x20are\x20required'),console[_0x319bbc(0x3bd)]('Usage:\x20tdx\x20segment\x20parent\x20create\x20<name>\x20--database\x20<db>\x20--table\x20<table>'),0x1;_0x1d61d4[_0x319bbc(0x387)]&&(console[_0x319bbc(0x3bd)](_0x319bbc(0x39e)+_0x1d61d4[_0x319bbc(0x1d1)]),console['error'](_0x319bbc(0x202)+_0x28e070),console[_0x319bbc(0x3bd)](_0x319bbc(0x2d9)+_0x1d61d4[_0x319bbc(0x279)]),console[_0x319bbc(0x3bd)](_0x319bbc(0x2b5)+_0x1d61d4[_0x319bbc(0x20a)]));const _0x1bc6c1=await loadJSONFromOptions(_0x1d61d4[_0x319bbc(0x370)],_0x1d61d4[_0x319bbc(0x1e4)]),_0x2f4f40=await loadJSONFromOptions(_0x1d61d4['behaviors'],_0x1d61d4[_0x319bbc(0x275)]),_0x29e902=await loadJSONFromOptions(_0x1d61d4['customerGroup'],_0x1d61d4[_0x319bbc(0x1c2)]),_0x2c6e31={'name':_0x28e070,'description':_0x1d61d4['description'],'scheduleType':_0x1d61d4[_0x319bbc(0x299)],'scheduleOption':_0x1d61d4[_0x319bbc(0x349)],'timezone':_0x1d61d4['timezone'],'master':{'parentDatabaseName':_0x1d61d4[_0x319bbc(0x279)],'parentTableName':_0x1d61d4['table']},'attributes':_0x1bc6c1,'behaviors':_0x2f4f40,'customerGroup':_0x29e902},_0x5e6538=await withSpinner('Creating\x20parent\x20segment\x20\x27'+_0x28e070+_0x319bbc(0x288),()=>_0x3a3cc3['segment'][_0x319bbc(0x272)](_0x2c6e31),{'verbose':_0x57726e[_0x319bbc(0x387)]}),_0x1bcc31=_0x5e6538[_0x319bbc(0x1ad)];return console[_0x319bbc(0x3bd)](_0x319bbc(0x2b2)+_0x1bcc31[_0x319bbc(0x37d)]+_0x319bbc(0x1c6)+_0x1bcc31['id']),await handleSDKOutput([_0x1bcc31],_0x57726e),0x0;}}function a32_0x375c(_0x319ef4,_0x3a718a){_0x319ef4=_0x319ef4-0x199;const _0x3f581f=a32_0x3f58();let _0x375c4b=_0x3f581f[_0x319ef4];return _0x375c4b;}export class ParentSegmentUpdateCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]=a32_0x3c5e89(0x2a7);[a32_0x3c5e89(0x297)]=a32_0x3c5e89(0x382);async[a32_0x3c5e89(0x2ce)](_0x2fc34a){const _0x504f5a=a32_0x3c5e89,{options:_0x17b669,args:_0x194323,tdx:_0x59b50a}=_0x2fc34a;console['error']('\x0a⚠️\x20\x20DEPRECATED:\x20`tdx\x20segment\x20parent\x20update`\x20is\x20deprecated.\x0a'+_0x504f5a(0x3b0)+_0x504f5a(0x22d));const _0x64c126=_0x17b669;if(_0x194323['length']===0x0)return console[_0x504f5a(0x3bd)](a32_0x54ffbd[_0x504f5a(0x2cb)](_0x504f5a(0x2e1))),console[_0x504f5a(0x3bd)]('Usage:\x20tdx\x20segment\x20parent\x20update\x20<name>\x20[options]'),0x1;const _0x97184a=_0x194323[0x0];_0x64c126[_0x504f5a(0x387)]&&(console['error'](_0x504f5a(0x39e)+_0x64c126[_0x504f5a(0x1d1)]),console[_0x504f5a(0x3bd)](_0x504f5a(0x2c9)+_0x97184a));const _0x4f0ba2=await withSpinner(_0x504f5a(0x34d)+_0x97184a+_0x504f5a(0x288),()=>_0x59b50a[_0x504f5a(0x1f3)][_0x504f5a(0x24a)](_0x97184a),{'verbose':_0x64c126[_0x504f5a(0x387)]}),_0x56524a=_0x4f0ba2[_0x504f5a(0x1ad)],_0x297be4=await loadJSONFromOptions(_0x64c126[_0x504f5a(0x314)],_0x64c126[_0x504f5a(0x231)]),_0x10e3bd=await loadJSONFromOptions(_0x64c126['addBehaviors'],_0x64c126[_0x504f5a(0x2e0)]),_0x1b42fc={'name':_0x56524a[_0x504f5a(0x37d)],'description':_0x64c126[_0x504f5a(0x297)]!==undefined?_0x64c126[_0x504f5a(0x297)]:_0x56524a[_0x504f5a(0x297)],'scheduleType':_0x64c126[_0x504f5a(0x299)]!==undefined?_0x64c126['scheduleType']:_0x56524a[_0x504f5a(0x299)],'scheduleOption':_0x64c126[_0x504f5a(0x349)]!==undefined?_0x64c126[_0x504f5a(0x349)]:_0x56524a[_0x504f5a(0x349)],'timezone':_0x64c126[_0x504f5a(0x247)]!==undefined?_0x64c126['timezone']:_0x56524a[_0x504f5a(0x247)],'master':_0x56524a[_0x504f5a(0x1d3)],'attributes':_0x297be4?[..._0x56524a['attributes']||[],..._0x297be4]:_0x56524a[_0x504f5a(0x370)],'behaviors':_0x10e3bd?[..._0x56524a[_0x504f5a(0x27f)]||[],..._0x10e3bd]:_0x56524a[_0x504f5a(0x27f)],'customerGroup':_0x56524a[_0x504f5a(0x36e)]},_0x230d4b=await withSpinner('Updating\x20parent\x20segment\x20\x27'+_0x97184a+_0x504f5a(0x288),()=>_0x59b50a['segment'][_0x504f5a(0x3a0)](_0x97184a,_0x1b42fc),{'verbose':_0x64c126[_0x504f5a(0x387)]}),_0x463d6d=_0x230d4b[_0x504f5a(0x1ad)];return console['error']('✔\x20Updated\x20parent\x20segment\x20\x27'+_0x463d6d['name']+'\x27'),await handleSDKOutput([_0x463d6d],_0x64c126),0x0;}}export class ParentSegmentPullCommand extends BaseParentSegmentCommand{['name']='segment:parent:pull';[a32_0x3c5e89(0x297)]='Pull\x20parent\x20segment\x20configuration\x20to\x20YAML\x20file';async['execute'](_0x144593){const _0x4777c8=a32_0x3c5e89,{options:_0x181626,args:_0x142d18,tdx:_0x50ed2b}=_0x144593,_0x5b9cf3=_0x181626,_0x419def=_0x142d18[0x0]||_0x181626[_0x4777c8(0x1bc)];if(!_0x419def)return showParentSegmentNotSetError(_0x4777c8(0x255)+_0x4777c8(0x20e)),0x1;if(_0x5b9cf3[_0x4777c8(0x363)]&&_0x5b9cf3[_0x4777c8(0x22e)])return console[_0x4777c8(0x3bd)](a32_0x54ffbd['red']('Error:\x20-u\x20(--use)\x20and\x20-o\x20(--output)\x20cannot\x20be\x20used\x20together\x0a')),console[_0x4777c8(0x3bd)](a32_0x54ffbd['dim']('The\x20-u\x20flag\x20sets\x20the\x20context\x20to\x20the\x20pulled\x20segment,\x20which\x20requires')),console['error'](a32_0x54ffbd[_0x4777c8(0x2f6)](_0x4777c8(0x1d6)+PARENT_SEGMENT_DIR+_0x4777c8(0x34b))),console['error'](a32_0x54ffbd[_0x4777c8(0x30f)](_0x4777c8(0x200))),0x1;const _0x56e192=_0x5b9cf3[_0x4777c8(0x22e)]||a32_0x40546c['join'](PARENT_SEGMENT_DIR,sanitizeFileName(_0x419def)+_0x4777c8(0x352));_0x5b9cf3[_0x4777c8(0x387)]&&(console[_0x4777c8(0x3bd)](_0x4777c8(0x39e)+_0x5b9cf3[_0x4777c8(0x1d1)]),console[_0x4777c8(0x3bd)](_0x4777c8(0x2c9)+_0x419def),console[_0x4777c8(0x3bd)](_0x4777c8(0x2e7)+_0x56e192));const _0x477305=await withSpinner('Fetching\x20parent\x20segment\x20\x27'+_0x419def+_0x4777c8(0x288),()=>_0x50ed2b[_0x4777c8(0x1f3)][_0x4777c8(0x1b6)](_0x419def),{'verbose':_0x5b9cf3[_0x4777c8(0x387)]}),_0x51411f=_0x477305[_0x4777c8(0x1ad)];if(existsSync(_0x56e192)){const _0x1004ca=readFileSync(_0x56e192,_0x4777c8(0x36a)),_0x1d2807=generateDiff(_0x1004ca,_0x51411f);if(!hasChanges(_0x1d2807))console[_0x4777c8(0x3bd)](a32_0x54ffbd[_0x4777c8(0x1d8)]('✔')+_0x4777c8(0x1fd)+a32_0x54ffbd[_0x4777c8(0x30f)](_0x56e192)+_0x4777c8(0x3a3));else{console[_0x4777c8(0x3bd)](_0x4777c8(0x3a8)+_0x56e192+'\x27:'),console['error']('─'['repeat'](0x3c)),console['error'](formatDiffWithColors(_0x1d2807)),console['error']('─'[_0x4777c8(0x346)](0x3c));if(!_0x5b9cf3[_0x4777c8(0x3ab)]){if(!isInteractive())return console[_0x4777c8(0x3bd)](a32_0x54ffbd[_0x4777c8(0x2cb)](_0x4777c8(0x2ee)),'Confirmation\x20required\x20but\x20running\x20in\x20non-interactive\x20mode'),console[_0x4777c8(0x3bd)](a32_0x54ffbd['dim'](_0x4777c8(0x28d))),0x1;const _0x3d76da=await confirmKey(_0x4777c8(0x2b7)+_0x56e192+'\x27?');if(!_0x3d76da)return console[_0x4777c8(0x3bd)](a32_0x54ffbd['yellow'](_0x4777c8(0x264))),0x1;}writeFileSync(_0x56e192,_0x51411f,_0x4777c8(0x36a)),console[_0x4777c8(0x3bd)](a32_0x54ffbd['green']('✔')+_0x4777c8(0x1fc)+a32_0x54ffbd[_0x4777c8(0x30f)](_0x56e192));}}else{const _0x45aaf4=a32_0x40546c[_0x4777c8(0x212)](_0x56e192);!existsSync(_0x45aaf4)&&mkdirSync(_0x45aaf4,{'recursive':!![]}),writeFileSync(_0x56e192,_0x51411f,_0x4777c8(0x36a)),console[_0x4777c8(0x3bd)](a32_0x54ffbd['green']('✔')+_0x4777c8(0x1fc)+a32_0x54ffbd[_0x4777c8(0x30f)](_0x56e192));}return saveSessionContext({'parent_segment':_0x419def},_0x5b9cf3[_0x4777c8(0x367)]),console[_0x4777c8(0x3bd)](a32_0x54ffbd[_0x4777c8(0x1d8)]('✔')+_0x4777c8(0x38e)+a32_0x54ffbd[_0x4777c8(0x2f6)](_0x4777c8(0x2c5))+_0x4777c8(0x343)+a32_0x54ffbd[_0x4777c8(0x30f)](_0x419def)),0x0;}}export class ParentSegmentPushCommand extends BaseParentSegmentCommand{[a32_0x3c5e89(0x37d)]=a32_0x3c5e89(0x380);[a32_0x3c5e89(0x297)]=a32_0x3c5e89(0x1ff);async['execute'](_0x373e38){const _0x20fd63=a32_0x3c5e89,{options:_0x497f2c,args:_0x3d7f8d,tdx:_0x31d87e}=_0x373e38,_0x301139=_0x497f2c,_0x3e5280=_0x3d7f8d[0x0]||_0x497f2c[_0x20fd63(0x1bc)];if(!_0x3e5280)return showParentSegmentNotSetError(_0x20fd63(0x2f4)+_0x20fd63(0x1e8)),0x1;const _0x4682c2=resolveYamlFile(_0x3e5280);if(!existsSync(_0x4682c2))return showFileNotFoundError(_0x4682c2,_0x3e5280),0x1;_0x301139['verbose']&&(console[_0x20fd63(0x3bd)]('Site:\x20'+_0x301139[_0x20fd63(0x1d1)]),console['error']('YAML\x20file:\x20'+_0x4682c2));let _0x9499e6;try{_0x9499e6=readFileSync(_0x4682c2,_0x20fd63(0x36a));}catch(_0x172d89){const _0x409743=_0x172d89 instanceof Error?_0x172d89[_0x20fd63(0x2fe)]:String(_0x172d89);return console[_0x20fd63(0x3bd)]('Error\x20reading\x20file:\x20'+_0x409743),0x1;}const _0x374c87=await withSpinner('Analyzing\x20changes...',()=>_0x31d87e[_0x20fd63(0x1f3)][_0x20fd63(0x2b4)](_0x9499e6),{'verbose':_0x301139[_0x20fd63(0x387)]}),_0x14af30=_0x374c87[_0x20fd63(0x1ad)],{isNew:_0x47d9a3,name:_0x21d253,hasChanges:_0x2932ea,diffFormatted:_0x3375b6}=_0x14af30;if(!_0x2932ea)return console['error']('✔\x20No\x20changes\x20-\x20\x27'+_0x21d253+_0x20fd63(0x1d7)),0x0;_0x47d9a3?console[_0x20fd63(0x3bd)]('\x0aNew\x20parent\x20segment\x20\x27'+_0x21d253+'\x27:'):console[_0x20fd63(0x3bd)](_0x20fd63(0x350)+_0x21d253+'\x27:');console[_0x20fd63(0x3bd)]('─'['repeat'](0x3c)),console['error'](_0x3375b6),console['error']('─'[_0x20fd63(0x346)](0x3c));const _0x391502=_0x47d9a3?_0x20fd63(0x239)+_0x21d253+'\x27?':_0x20fd63(0x1df)+_0x21d253+'\x27?';if(!_0x301139['yes']){if(!isInteractive())return console['error'](a32_0x54ffbd['red']('\x0aError:'),_0x20fd63(0x248)),console[_0x20fd63(0x3bd)](a32_0x54ffbd[_0x20fd63(0x2f6)](_0x20fd63(0x28d))),0x1;const _0x29de44=await confirmKey(_0x391502);if(!_0x29de44)return console[_0x20fd63(0x3bd)](a32_0x54ffbd[_0x20fd63(0x24d)](_0x20fd63(0x264))),0x1;}const _0x5ec933=_0x47d9a3?_0x20fd63(0x22f):_0x20fd63(0x28b),_0x3abdbe=await withSpinner(_0x5ec933+_0x20fd63(0x25b)+_0x21d253+_0x20fd63(0x288),()=>_0x14af30[_0x20fd63(0x2c3)](),{'verbose':_0x301139[_0x20fd63(0x387)]}),_0x24df4a=_0x3abdbe[_0x20fd63(0x1ad)],_0x113670=getConsoleNextUrl(_0x301139[_0x20fd63(0x1d1)],_0x20fd63(0x24f)+_0x24df4a['id']),_0x591f07=_0x47d9a3?_0x20fd63(0x1f7):_0x20fd63(0x3a9);return console['error']('✔\x20'+_0x591f07+_0x20fd63(0x25b)+_0x24df4a[_0x20fd63(0x37d)]+'\x27'),console[_0x20fd63(0x3bd)]('\x20\x20'+_0x113670),0x0;}}export class ParentSegmentValidateCommand extends BaseParentSegmentCommand{[a32_0x3c5e89(0x37d)]=a32_0x3c5e89(0x2b9);[a32_0x3c5e89(0x297)]='Validate\x20parent\x20segment\x20YAML\x20configuration\x20and\x20show\x20statistics';async[a32_0x3c5e89(0x2ce)](_0x35af0a){const _0x419c36=a32_0x3c5e89,{options:_0x173ab9,args:_0x3c803c,tdx:_0x36815f}=_0x35af0a,_0x54c122=_0x173ab9,_0x5b8909=_0x3c803c[0x0]||_0x173ab9['parentSegment'];if(!_0x5b8909)return showParentSegmentNotSetError(_0x419c36(0x1c1)+_0x419c36(0x1a3)+_0x419c36(0x1b2)+'\x20\x20--attribute\x20[name]\x20\x20\x20Show\x20only\x20attributes\x20(or\x20specific\x20one)\x0a'+_0x419c36(0x28f)+_0x419c36(0x1b7)),0x1;const _0x3f1ea2=resolveYamlFile(_0x5b8909);if(!existsSync(_0x3f1ea2))return showFileNotFoundError(_0x3f1ea2,_0x5b8909),0x1;_0x54c122[_0x419c36(0x387)]&&(console['error'](_0x419c36(0x39e)+_0x54c122[_0x419c36(0x1d1)]),console[_0x419c36(0x3bd)](_0x419c36(0x389)+_0x3f1ea2));let _0x5573e1;try{_0x5573e1=readFileSync(_0x3f1ea2,_0x419c36(0x36a));}catch(_0x1d7f06){const _0x129932=_0x1d7f06 instanceof Error?_0x1d7f06[_0x419c36(0x2fe)]:String(_0x1d7f06);return console[_0x419c36(0x3bd)](_0x419c36(0x37a)+_0x129932),0x1;}const _0x4fd48a=createCommandSpinner(a32_0x54ffbd[_0x419c36(0x2f6)](_0x419c36(0x1e1)),{'verbose':_0x54c122['verbose']});_0x4fd48a['start']();const _0x3ceb05={'onProgress':_0x443e09=>{const _0x4a9e61=_0x419c36;_0x4fd48a[_0x4a9e61(0x26e)]=formatProgressMessage(_0x443e09);}};if(_0x54c122['master'])_0x3ceb05[_0x419c36(0x1d3)]=!![];if(_0x54c122['enriched'])_0x3ceb05[_0x419c36(0x34c)]=!![];_0x54c122['attribute']&&(_0x3ceb05[_0x419c36(0x2a0)]=_0x54c122[_0x419c36(0x2a0)]);_0x54c122[_0x419c36(0x312)]&&(_0x3ceb05['behavior']=_0x54c122['behavior']);if(_0x54c122['interval'])_0x3ceb05[_0x419c36(0x3b7)]=_0x54c122[_0x419c36(0x3b7)];let _0x184aba;try{_0x184aba=await _0x36815f[_0x419c36(0x1f3)][_0x419c36(0x1c7)](_0x5573e1,_0x3ceb05),_0x4fd48a[_0x419c36(0x3ba)]();}catch(_0x591e4a){_0x4fd48a[_0x419c36(0x3ba)]();throw _0x591e4a;}const _0x2ebe03=_0x54c122['interval']||'-1d';return this[_0x419c36(0x2ff)](_0x184aba,_0x3ceb05,_0x3f1ea2,_0x2ebe03),_0x184aba['allValid']?0x0:0x1;}[a32_0x3c5e89(0x2ff)](_0x3b1d7d,_0x1e2dab,_0x20df4d,_0x40f3ba){const _0x1826c7=a32_0x3c5e89;console['error']('\x0a'+a32_0x54ffbd[_0x1826c7(0x1be)]('Validate:')+'\x20'+_0x3b1d7d[_0x1826c7(0x37d)]),console['error']('═'['repeat'](0x3c)),this[_0x1826c7(0x294)](_0x3b1d7d);if(typeof _0x1e2dab[_0x1826c7(0x2a0)]===_0x1826c7(0x26b)){this[_0x1826c7(0x378)](_0x3b1d7d),this[_0x1826c7(0x1ce)](_0x3b1d7d),this['displayPreviewHints'](_0x20df4d,_0x40f3ba,_0x1826c7(0x2a0),_0x1e2dab[_0x1826c7(0x2a0)]);return;}if(_0x1e2dab[_0x1826c7(0x2a0)]===!![]){this[_0x1826c7(0x378)](_0x3b1d7d),this['displaySummary'](_0x3b1d7d),this['displayPreviewHints'](_0x20df4d,_0x40f3ba,_0x1826c7(0x370));return;}if(typeof _0x1e2dab[_0x1826c7(0x312)]===_0x1826c7(0x26b)){this[_0x1826c7(0x29b)](_0x3b1d7d,_0x40f3ba),this[_0x1826c7(0x1ce)](_0x3b1d7d),this[_0x1826c7(0x2a1)](_0x20df4d,_0x40f3ba,_0x1826c7(0x312),_0x1e2dab['behavior']);return;}if(_0x1e2dab[_0x1826c7(0x312)]===!![]){this['displayBehaviorsStats'](_0x3b1d7d,_0x40f3ba),this['displaySummary'](_0x3b1d7d),this[_0x1826c7(0x2a1)](_0x20df4d,_0x40f3ba,_0x1826c7(0x27f));return;}this[_0x1826c7(0x378)](_0x3b1d7d),this[_0x1826c7(0x29b)](_0x3b1d7d,_0x40f3ba),this[_0x1826c7(0x2cc)](_0x3b1d7d),this['displaySummary'](_0x3b1d7d),this['displayPreviewHints'](_0x20df4d,_0x40f3ba,_0x1826c7(0x307));}[a32_0x3c5e89(0x2cc)](_0x433c6a){displayRealtimeValidation(_0x433c6a);}[a32_0x3c5e89(0x2a1)](_0x505eb3,_0x2aa122,_0x590177,_0x23ed63){const _0x520b53=a32_0x3c5e89;console[_0x520b53(0x3bd)]('\x0a'+a32_0x54ffbd[_0x520b53(0x2f6)](_0x520b53(0x1bf)));const _0x3c88a7=_0x2aa122!==_0x520b53(0x394)?_0x520b53(0x2fb)+_0x2aa122:'';if(_0x590177==='attribute'&&_0x23ed63)console['error']('\x20\x20'+a32_0x54ffbd['dim'](_0x520b53(0x295)+_0x505eb3+_0x520b53(0x213)+_0x23ed63+'\x22'+_0x3c88a7));else{if(_0x590177==='behavior'&&_0x23ed63)console['error']('\x20\x20'+a32_0x54ffbd[_0x520b53(0x2f6)](_0x520b53(0x295)+_0x505eb3+'\x20--behavior\x20\x22'+_0x23ed63+'\x22'+_0x3c88a7));else(_0x590177===_0x520b53(0x370)||_0x590177===_0x520b53(0x307))&&console[_0x520b53(0x3bd)]('\x20\x20'+a32_0x54ffbd[_0x520b53(0x2f6)](_0x520b53(0x295)+_0x505eb3+_0x520b53(0x1ca)+_0x3c88a7));}(_0x590177==='behaviors'||_0x590177===_0x520b53(0x307))&&console[_0x520b53(0x3bd)]('\x20\x20'+a32_0x54ffbd['dim'](_0x520b53(0x295)+_0x505eb3+_0x520b53(0x3b5)+_0x3c88a7)),_0x590177===_0x520b53(0x307)&&console[_0x520b53(0x3bd)]('\x20\x20'+a32_0x54ffbd[_0x520b53(0x2f6)](_0x520b53(0x295)+_0x505eb3+_0x520b53(0x280)+_0x3c88a7));}[a32_0x3c5e89(0x294)](_0x3f5b67){const _0x312a6a=a32_0x3c5e89,{master:_0x2a0ed5}=_0x3f5b67,_0x3aeea0=_0x2a0ed5[_0x312a6a(0x396)]?a32_0x54ffbd[_0x312a6a(0x1d8)]('✔'):a32_0x54ffbd[_0x312a6a(0x2cb)]('✘');console['error']('\x0a'+a32_0x54ffbd[_0x312a6a(0x2f6)]('Master\x20Table')),console[_0x312a6a(0x3bd)](_0x3aeea0+'\x20'+a32_0x54ffbd[_0x312a6a(0x1be)](_0x2a0ed5[_0x312a6a(0x279)]+'.'+_0x2a0ed5[_0x312a6a(0x20a)])),_0x2a0ed5['schemaValid']?_0x2a0ed5[_0x312a6a(0x2fc)]!==undefined&&console[_0x312a6a(0x3bd)]('\x20\x20'+a32_0x54ffbd[_0x312a6a(0x2f6)](_0x312a6a(0x2a5))+'\x20'+a32_0x54ffbd[_0x312a6a(0x30f)](formatRows(_0x2a0ed5[_0x312a6a(0x2fc)]))):console[_0x312a6a(0x3bd)]('\x20\x20'+a32_0x54ffbd[_0x312a6a(0x2cb)]('Error:')+'\x20'+_0x2a0ed5[_0x312a6a(0x1e2)]);}[a32_0x3c5e89(0x378)](_0x4a3bac){const _0x31cdae=a32_0x3c5e89;if(_0x4a3bac[_0x31cdae(0x370)][_0x31cdae(0x30a)]===0x0)return;console['error']('\x0a'+a32_0x54ffbd['dim'](_0x31cdae(0x28a)));for(const _0x34b31f of _0x4a3bac[_0x31cdae(0x370)]){const _0x9b32bc=_0x34b31f[_0x31cdae(0x396)]?a32_0x54ffbd[_0x31cdae(0x1d8)]('✔'):a32_0x54ffbd[_0x31cdae(0x2cb)]('✘');let _0x46026a='';if(_0x34b31f[_0x31cdae(0x396)]&&_0x34b31f[_0x31cdae(0x336)]!==undefined&&_0x34b31f[_0x31cdae(0x3b4)]!==undefined){const _0x6c6f93=_0x34b31f['coveragePercent']['toFixed'](0x1),_0x24ef7f=_0x34b31f[_0x31cdae(0x3b4)]>=0x50?a32_0x54ffbd[_0x31cdae(0x1d8)]:_0x34b31f[_0x31cdae(0x3b4)]>=0x32?a32_0x54ffbd[_0x31cdae(0x24d)]:a32_0x54ffbd[_0x31cdae(0x2cb)];_0x46026a='\x20'+a32_0x54ffbd[_0x31cdae(0x2f6)](_0x31cdae(0x39c))+'\x20'+_0x24ef7f(_0x6c6f93+'%')+'\x20('+formatRows(_0x34b31f[_0x31cdae(0x336)])+_0x31cdae(0x31a);}console[_0x31cdae(0x3bd)](_0x9b32bc+'\x20'+a32_0x54ffbd['bold'](_0x34b31f[_0x31cdae(0x37d)])+_0x46026a),console[_0x31cdae(0x3bd)]('\x20\x20'+a32_0x54ffbd[_0x31cdae(0x2f6)](_0x31cdae(0x1af))+'\x20'+a32_0x54ffbd['bold'](_0x34b31f[_0x31cdae(0x279)]+'.'+_0x34b31f[_0x31cdae(0x20a)]));const _0x1d9e9d=_0x34b31f[_0x31cdae(0x1e6)]===_0x34b31f['foreignKey']?a32_0x54ffbd[_0x31cdae(0x2f6)](_0x31cdae(0x366))+'\x20'+_0x34b31f[_0x31cdae(0x1e6)]:a32_0x54ffbd[_0x31cdae(0x2f6)](_0x31cdae(0x34e))+'\x20'+_0x34b31f[_0x31cdae(0x1e6)]+'\x20=\x20'+_0x34b31f[_0x31cdae(0x2f3)];console['error']('\x20\x20'+_0x1d9e9d),console[_0x31cdae(0x3bd)]('\x20\x20'+a32_0x54ffbd[_0x31cdae(0x2f6)]('Columns:')),this[_0x31cdae(0x1d2)](_0x34b31f[_0x31cdae(0x22a)]),!_0x34b31f[_0x31cdae(0x396)]&&console[_0x31cdae(0x3bd)]('\x20\x20'+a32_0x54ffbd[_0x31cdae(0x2cb)](_0x31cdae(0x2c1))+'\x20'+_0x34b31f[_0x31cdae(0x1e2)]);}}[a32_0x3c5e89(0x29b)](_0xd04912,_0x211f0d){const _0x3329c3=a32_0x3c5e89;if(_0xd04912['behaviors'][_0x3329c3(0x30a)]===0x0)return;console[_0x3329c3(0x3bd)]('\x0a'+a32_0x54ffbd[_0x3329c3(0x2f6)](_0x3329c3(0x257))+'\x20'+a32_0x54ffbd['dim']('('+_0x211f0d+')'));for(const _0x25b153 of _0xd04912[_0x3329c3(0x27f)]){const _0x28b5fb=_0x25b153[_0x3329c3(0x396)]?a32_0x54ffbd[_0x3329c3(0x1d8)]('✔'):a32_0x54ffbd[_0x3329c3(0x2cb)]('✘');let _0x319feb='';if(_0x25b153['schemaValid']&&_0x25b153['customersWithEvents']!==undefined&&_0x25b153['totalEvents']!==undefined){const _0x4a5100=_0x25b153['customerPercent']?.[_0x3329c3(0x33a)](0x1)||'?',_0x8f55e2=(_0x25b153[_0x3329c3(0x1c4)]??0x0)>=0x32?a32_0x54ffbd['green']:(_0x25b153[_0x3329c3(0x1c4)]??0x0)>=0x14?a32_0x54ffbd[_0x3329c3(0x24d)]:a32_0x54ffbd[_0x3329c3(0x2cb)];_0x319feb='\x20'+a32_0x54ffbd[_0x3329c3(0x2f6)]('Customers:')+'\x20'+_0x8f55e2(formatRows(_0x25b153['customersWithEvents']))+'\x20('+_0x4a5100+_0x3329c3(0x265)+a32_0x54ffbd['dim']('Events:')+'\x20'+a32_0x54ffbd['cyan'](formatRows(_0x25b153['totalEvents']));}console[_0x3329c3(0x3bd)](_0x28b5fb+'\x20'+a32_0x54ffbd[_0x3329c3(0x1be)](_0x25b153[_0x3329c3(0x37d)])+_0x319feb),console[_0x3329c3(0x3bd)]('\x20\x20'+a32_0x54ffbd[_0x3329c3(0x2f6)](_0x3329c3(0x1af))+'\x20'+a32_0x54ffbd[_0x3329c3(0x1be)](_0x25b153[_0x3329c3(0x279)]+'.'+_0x25b153[_0x3329c3(0x20a)]));const _0x44610b=_0x25b153[_0x3329c3(0x1e6)]===_0x25b153[_0x3329c3(0x2f3)]?a32_0x54ffbd[_0x3329c3(0x2f6)](_0x3329c3(0x366))+'\x20'+_0x25b153[_0x3329c3(0x1e6)]:a32_0x54ffbd['dim'](_0x3329c3(0x34e))+'\x20'+_0x25b153[_0x3329c3(0x1e6)]+_0x3329c3(0x343)+_0x25b153[_0x3329c3(0x2f3)];console[_0x3329c3(0x3bd)]('\x20\x20'+_0x44610b),console[_0x3329c3(0x3bd)]('\x20\x20'+a32_0x54ffbd[_0x3329c3(0x2f6)](_0x3329c3(0x2ae))),this[_0x3329c3(0x1d2)](_0x25b153['columns']),!_0x25b153[_0x3329c3(0x396)]&&console[_0x3329c3(0x3bd)]('\x20\x20'+a32_0x54ffbd['red'](_0x3329c3(0x2c1))+'\x20'+_0x25b153[_0x3329c3(0x1e2)]);}}[a32_0x3c5e89(0x1d2)](_0x5c118e){const _0x14793d=a32_0x3c5e89;for(const _0x343647 of _0x5c118e){_0x343647[_0x14793d(0x31e)]===_0x343647[_0x14793d(0x25e)]||_0x343647[_0x14793d(0x25e)]==='*'?console[_0x14793d(0x3bd)](_0x14793d(0x2f0)+_0x343647[_0x14793d(0x31e)]):console['error'](_0x14793d(0x2f0)+_0x343647['label']+'\x20'+a32_0x54ffbd[_0x14793d(0x2f6)]('('+_0x343647[_0x14793d(0x25e)]+')'));}}[a32_0x3c5e89(0x1ce)](_0x593e58){const _0x443614=a32_0x3c5e89;console[_0x443614(0x3bd)]('─'[_0x443614(0x346)](0x3c));if(_0x593e58[_0x443614(0x1b5)][_0x443614(0x30a)]>0x0){console[_0x443614(0x3bd)]('\x0a'+a32_0x54ffbd[_0x443614(0x2cb)](_0x443614(0x236)));for(const _0xa6ffdc of _0x593e58[_0x443614(0x1b5)]){console[_0x443614(0x3bd)]('\x20\x20'+a32_0x54ffbd[_0x443614(0x2cb)]('•')+'\x20'+_0xa6ffdc);}}_0x593e58[_0x443614(0x224)]&&console[_0x443614(0x3bd)]('\x0a'+a32_0x54ffbd[_0x443614(0x1d8)]('✔')+_0x443614(0x25f));}}export class ParentSegmentPreviewCommand extends BaseParentSegmentCommand{['name']=a32_0x3c5e89(0x2b3);[a32_0x3c5e89(0x297)]=a32_0x3c5e89(0x2e8);async[a32_0x3c5e89(0x2ce)](_0x28f6a8){const _0x2d49f0=a32_0x3c5e89,{options:_0x486962,args:_0x364641,tdx:_0x462bd4}=_0x28f6a8,_0x490a5d=_0x486962,_0x5421ec=_0x364641[0x0]||_0x486962[_0x2d49f0(0x1bc)];if(!_0x5421ec)return showParentSegmentNotSetError(_0x2d49f0(0x328)+_0x2d49f0(0x29c)+'Options\x20(one\x20required):\x0a'+_0x2d49f0(0x369)+'\x20\x20--attribute\x20<name>\x20\x20\x20Show\x20sample\x20data\x20for\x20specific\x20attribute\x0a'+_0x2d49f0(0x1a9)+_0x2d49f0(0x31f)+'\x20\x20--interval\x20<range>\x20\x20\x20TD_INTERVAL\x20time\x20range\x20for\x20behaviors\x20(default:\x20-1d)'),0x1;if(!_0x490a5d[_0x2d49f0(0x1d3)]&&!_0x490a5d[_0x2d49f0(0x2a0)]&&!_0x490a5d[_0x2d49f0(0x312)]&&!_0x490a5d[_0x2d49f0(0x34c)])return console[_0x2d49f0(0x3bd)](a32_0x54ffbd[_0x2d49f0(0x2cb)](_0x2d49f0(0x1ba))),console[_0x2d49f0(0x3bd)](_0x2d49f0(0x27d)),console[_0x2d49f0(0x3bd)](_0x2d49f0(0x259)),console[_0x2d49f0(0x3bd)](_0x2d49f0(0x371)),console['error']('\x20\x20--attribute\x20<name>\x20\x20\x20Show\x20sample\x20data\x20for\x20specific\x20attribute'),console[_0x2d49f0(0x3bd)](_0x2d49f0(0x375)),console[_0x2d49f0(0x3bd)]('\x20\x20--enriched\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Show\x20sample\x20enriched\x20master\x20data'),0x1;const _0x57106b=resolveYamlFile(_0x5421ec);if(!existsSync(_0x57106b))return showFileNotFoundError(_0x57106b,_0x5421ec),0x1;_0x490a5d['verbose']&&(console['error'](_0x2d49f0(0x39e)+_0x490a5d[_0x2d49f0(0x1d1)]),console[_0x2d49f0(0x3bd)](_0x2d49f0(0x389)+_0x57106b));let _0x3fdd04;try{_0x3fdd04=readFileSync(_0x57106b,_0x2d49f0(0x36a));}catch(_0x39018b){const _0x570ccd=_0x39018b instanceof Error?_0x39018b[_0x2d49f0(0x2fe)]:String(_0x39018b);return console[_0x2d49f0(0x3bd)]('Error\x20reading\x20file:\x20'+_0x570ccd),0x1;}let _0x337bd3;try{_0x337bd3=parseDef(_0x3fdd04);}catch(_0x1c3f75){const _0x16136d=_0x1c3f75 instanceof Error?_0x1c3f75[_0x2d49f0(0x2fe)]:String(_0x1c3f75);return console['error'](a32_0x54ffbd['red']('Error\x20parsing\x20YAML:\x20'+_0x16136d)),0x1;}if(_0x490a5d[_0x2d49f0(0x2a0)]===!![]||_0x490a5d['attribute']===''){const _0x2f2bce=_0x337bd3['attributes']?.[_0x2d49f0(0x383)](_0x13af7b=>_0x13af7b[_0x2d49f0(0x37d)])||[];if(_0x2f2bce[_0x2d49f0(0x30a)]===0x0)console[_0x2d49f0(0x3bd)](a32_0x54ffbd[_0x2d49f0(0x2cb)]('Error:\x20No\x20attributes\x20defined\x20in\x20configuration'));else{console['error'](a32_0x54ffbd[_0x2d49f0(0x2cb)](_0x2d49f0(0x1ac))),console[_0x2d49f0(0x3bd)](_0x2d49f0(0x390));for(const _0xb56d6e of _0x2f2bce){console[_0x2d49f0(0x3bd)]('\x20\x20'+a32_0x54ffbd['cyan'](_0xb56d6e));}console[_0x2d49f0(0x3bd)](_0x2d49f0(0x26a)+_0x5421ec+_0x2d49f0(0x213)+_0x2f2bce[0x0]+'\x22');}return 0x1;}if(_0x490a5d[_0x2d49f0(0x312)]===!![]||_0x490a5d[_0x2d49f0(0x312)]===''){const _0x216521=_0x337bd3[_0x2d49f0(0x27f)]?.[_0x2d49f0(0x383)](_0x4f3066=>_0x4f3066['name'])||[];if(_0x216521[_0x2d49f0(0x30a)]===0x0)console[_0x2d49f0(0x3bd)](a32_0x54ffbd['red'](_0x2d49f0(0x38f)));else{console[_0x2d49f0(0x3bd)](a32_0x54ffbd[_0x2d49f0(0x2cb)](_0x2d49f0(0x237))),console[_0x2d49f0(0x3bd)](_0x2d49f0(0x344));for(const _0x343259 of _0x216521){console[_0x2d49f0(0x3bd)]('\x20\x20'+a32_0x54ffbd[_0x2d49f0(0x30f)](_0x343259));}console[_0x2d49f0(0x3bd)](_0x2d49f0(0x26a)+_0x5421ec+'\x20--behavior\x20\x22'+_0x216521[0x0]+'\x22');}return 0x1;}const _0x3ab379=createCommandSpinner(a32_0x54ffbd[_0x2d49f0(0x2f6)](_0x2d49f0(0x30b)),{'verbose':_0x490a5d[_0x2d49f0(0x387)]});_0x3ab379[_0x2d49f0(0x357)]();const _0x6c8a49={'onProgress':_0x424f73=>{_0x3ab379['text']=formatProgressMessage(_0x424f73);}};if(_0x490a5d['master'])_0x6c8a49[_0x2d49f0(0x1d3)]=!![];if(_0x490a5d[_0x2d49f0(0x2a0)]&&typeof _0x490a5d['attribute']===_0x2d49f0(0x26b))_0x6c8a49[_0x2d49f0(0x2a0)]=_0x490a5d[_0x2d49f0(0x2a0)];if(_0x490a5d[_0x2d49f0(0x312)]&&typeof _0x490a5d[_0x2d49f0(0x312)]==='string')_0x6c8a49[_0x2d49f0(0x312)]=_0x490a5d[_0x2d49f0(0x312)];if(_0x490a5d['enriched'])_0x6c8a49['enriched']=!![];if(_0x490a5d[_0x2d49f0(0x3b7)])_0x6c8a49['interval']=_0x490a5d['interval'];let _0x3c4dab;try{_0x3c4dab=await _0x462bd4[_0x2d49f0(0x1f3)][_0x2d49f0(0x364)](_0x3fdd04,_0x6c8a49),_0x3ab379[_0x2d49f0(0x3ba)]();}catch(_0x54ace7){_0x3ab379[_0x2d49f0(0x3ba)]();throw _0x54ace7;}return await this[_0x2d49f0(0x355)](_0x3c4dab,{'master':_0x490a5d[_0x2d49f0(0x1d3)],'attribute':typeof _0x490a5d[_0x2d49f0(0x2a0)]===_0x2d49f0(0x26b)?_0x490a5d['attribute']:undefined,'behavior':typeof _0x490a5d['behavior']===_0x2d49f0(0x26b)?_0x490a5d[_0x2d49f0(0x312)]:undefined,'enriched':_0x490a5d['enriched']}),_0x3c4dab[_0x2d49f0(0x224)]?0x0:0x1;}async[a32_0x3c5e89(0x355)](_0x323817,_0x560b32){const _0xc08153=a32_0x3c5e89;console[_0xc08153(0x3bd)]('\x0a'+a32_0x54ffbd[_0xc08153(0x1be)](_0xc08153(0x220))+'\x20'+_0x323817[_0xc08153(0x37d)]),console[_0xc08153(0x3bd)]('═'[_0xc08153(0x346)](0x3c));if(_0x560b32['master']&&_0x323817['sampleData']){const _0x17e718=a32_0x54ffbd[_0xc08153(0x2f6)](_0xc08153(0x207))+'\x20'+a32_0x54ffbd[_0xc08153(0x1be)](_0x323817[_0xc08153(0x1d3)][_0xc08153(0x279)]+'.'+_0x323817[_0xc08153(0x1d3)][_0xc08153(0x20a)]);await this[_0xc08153(0x2eb)](_0x17e718,_0x323817[_0xc08153(0x333)]);}else{if(_0x560b32[_0xc08153(0x2a0)]&&_0x323817[_0xc08153(0x333)]){const _0x211140=a32_0x54ffbd['dim'](_0xc08153(0x335))+'\x20'+a32_0x54ffbd[_0xc08153(0x1be)](_0x560b32[_0xc08153(0x2a0)]);await this['displaySampleData'](_0x211140,_0x323817[_0xc08153(0x333)]);}else{if(_0x560b32[_0xc08153(0x312)]&&_0x323817[_0xc08153(0x333)]){const _0x1280d6=a32_0x54ffbd['dim']('Behavior:')+'\x20'+a32_0x54ffbd[_0xc08153(0x1be)](_0x560b32[_0xc08153(0x312)]);await this['displaySampleData'](_0x1280d6,_0x323817['sampleData']);}else{if(_0x560b32[_0xc08153(0x34c)]&&_0x323817[_0xc08153(0x333)]){const _0x2b05bb=a32_0x54ffbd['dim']('Enriched:')+'\x20'+a32_0x54ffbd[_0xc08153(0x1be)](_0xc08153(0x37f));await this['displaySampleData'](_0x2b05bb,_0x323817[_0xc08153(0x333)]);}else!_0x323817[_0xc08153(0x333)]&&console[_0xc08153(0x3bd)](_0xc08153(0x278));}}}if(_0x323817[_0xc08153(0x1b5)][_0xc08153(0x30a)]>0x0){console[_0xc08153(0x3bd)]('─'[_0xc08153(0x346)](0x3c)),console[_0xc08153(0x3bd)]('\x0a'+a32_0x54ffbd[_0xc08153(0x2cb)]('Errors:'));for(const _0x335be1 of _0x323817[_0xc08153(0x1b5)]){console['error']('\x20\x20'+a32_0x54ffbd[_0xc08153(0x2cb)]('•')+'\x20'+_0x335be1);}}}async[a32_0x3c5e89(0x2eb)](_0x3245b9,_0x190dfb){const _0x4f3a07=a32_0x3c5e89;if(_0x190dfb[_0x4f3a07(0x30a)]===0x0){console['error']('\x0a'+_0x3245b9),console[_0x4f3a07(0x3bd)](_0x4f3a07(0x332));return;}console[_0x4f3a07(0x3bd)]('\x0a'+_0x3245b9);const _0x11cef0=Object[_0x4f3a07(0x33f)](_0x190dfb[0x0])[_0x4f3a07(0x383)](_0x4d25b8=>({'name':_0x4d25b8,'type':typeof _0x190dfb[0x0][_0x4d25b8]===_0x4f3a07(0x34a)?_0x4f3a07(0x2e6):'varchar'})),_0x32a8d6={'queryId':_0x4f3a07(0x19a),'columns':_0x11cef0,'data':_0x190dfb,'stats':{'state':_0x4f3a07(0x282),'queued':![],'scheduled':![],'nodes':0x0,'totalSplits':0x0,'queuedSplits':0x0,'runningSplits':0x0,'completedSplits':0x0,'cpuTimeMillis':0x0,'wallTimeMillis':0x0,'queuedTimeMillis':0x0,'elapsedTimeMillis':0x0,'processedRows':_0x190dfb['length'],'processedBytes':0x0,'physicalInputBytes':0x0,'peakMemoryBytes':0x0,'spilledBytes':0x0}},_0x171e17=formatAsTable(_0x32a8d6,_0x190dfb[_0x4f3a07(0x30a)],!![]);await writeOutput(_0x171e17,undefined,_0x4f3a07(0x20a));}}export class ParentSegmentRunCommand extends BaseParentSegmentCommand{[a32_0x3c5e89(0x37d)]=a32_0x3c5e89(0x254);[a32_0x3c5e89(0x297)]='Run\x20parent\x20segment\x20workflow\x20(pushes\x20YAML\x20if\x20exists)';async['execute'](_0x38f340){const _0x5e899d=a32_0x3c5e89,{options:_0x2d079d,args:_0x384bbf,tdx:_0x1aec68}=_0x38f340,_0x2c34d4=_0x2d079d,_0x3c9f0e=_0x384bbf[0x0]||_0x2d079d[_0x5e899d(0x1bc)];if(!_0x3c9f0e)return showParentSegmentNotSetError(_0x5e899d(0x1d4)+_0x5e899d(0x1cd)),0x1;const _0x22b00c=resolveYamlFile(_0x3c9f0e);if(existsSync(_0x22b00c)){_0x2c34d4[_0x5e899d(0x387)]&&console['error']('Found\x20YAML\x20file:\x20'+_0x22b00c);let _0x1b0454;try{_0x1b0454=readFileSync(_0x22b00c,_0x5e899d(0x36a));}catch(_0x2338c3){const _0x1f710e=_0x2338c3 instanceof Error?_0x2338c3[_0x5e899d(0x2fe)]:String(_0x2338c3);return console[_0x5e899d(0x3bd)](_0x5e899d(0x37a)+_0x1f710e),0x1;}const _0x5ce4d0=await withSpinner('Analyzing\x20changes...',()=>_0x1aec68['segment'][_0x5e899d(0x2b4)](_0x1b0454),{'verbose':_0x2c34d4['verbose']}),_0xe00236=_0x5ce4d0[_0x5e899d(0x1ad)],{isNew:_0x3e020a,name:_0x3a632f,hasChanges:_0x5b9e23,diffFormatted:_0x42f012}=_0xe00236;if(_0x5b9e23){_0x3e020a?console['error'](_0x5e899d(0x19d)+_0x3a632f+'\x27:'):console[_0x5e899d(0x3bd)](_0x5e899d(0x350)+_0x3a632f+'\x27:');console['error']('─'[_0x5e899d(0x346)](0x3c)),console[_0x5e899d(0x3bd)](_0x42f012),console[_0x5e899d(0x3bd)]('─'['repeat'](0x3c));const _0x3e61d2=_0x3e020a?_0x5e899d(0x239)+_0x3a632f+'\x27\x20and\x20run\x20workflow?':_0x5e899d(0x1df)+_0x3a632f+_0x5e899d(0x2cf);if(!_0x2c34d4[_0x5e899d(0x3ab)]){if(!isInteractive())return console[_0x5e899d(0x3bd)](a32_0x54ffbd[_0x5e899d(0x2cb)](_0x5e899d(0x2ee)),_0x5e899d(0x248)),console[_0x5e899d(0x3bd)](a32_0x54ffbd[_0x5e899d(0x2f6)](_0x5e899d(0x28d))),0x1;const _0x30c458=await confirmKey(_0x3e61d2);if(!_0x30c458)return console[_0x5e899d(0x3bd)](a32_0x54ffbd[_0x5e899d(0x24d)](_0x5e899d(0x264))),0x1;}const _0x4a24a3=_0x3e020a?'Creating':_0x5e899d(0x28b);await withSpinner(_0x4a24a3+_0x5e899d(0x25b)+_0x3a632f+_0x5e899d(0x288),()=>_0xe00236[_0x5e899d(0x2c3)](),{'verbose':_0x2c34d4[_0x5e899d(0x387)]});const _0x3d255f=_0x3e020a?_0x5e899d(0x1f7):'Updated';console[_0x5e899d(0x3bd)]('✔\x20'+_0x3d255f+_0x5e899d(0x25b)+_0x3a632f+'\x27');}else console[_0x5e899d(0x3bd)](_0x5e899d(0x199)+_0x3a632f+'\x27\x20is\x20up\x20to\x20date');}const _0x407b0a=await withSpinner('Running\x20parent\x20segment\x20workflow\x20for\x20\x27'+_0x3c9f0e+'\x27...',()=>_0x1aec68[_0x5e899d(0x1f3)]['runParent'](_0x3c9f0e),{'verbose':_0x2c34d4[_0x5e899d(0x387)]}),_0x2d3a54=_0x407b0a[_0x5e899d(0x1ad)],_0x1a52a2=getConsoleUrl(_0x2c34d4['site'],_0x5e899d(0x1ed)+_0x2d3a54[_0x5e899d(0x2ca)]+_0x5e899d(0x3b6)+_0x2d3a54['workflowSessionId']+'/attempt/'+_0x2d3a54[_0x5e899d(0x20b)]);return console[_0x5e899d(0x3bd)](_0x5e899d(0x377)),console['error']('\x20\x20'+a32_0x54ffbd[_0x5e899d(0x2f6)](_0x5e899d(0x271))+'\x20'+_0x2d3a54[_0x5e899d(0x319)]),console['error']('\x20\x20'+a32_0x54ffbd[_0x5e899d(0x2f6)](_0x5e899d(0x301))+'\x20'+_0x2d3a54[_0x5e899d(0x3b9)]),console[_0x5e899d(0x3bd)]('\x20\x20'+a32_0x54ffbd['dim'](_0x5e899d(0x250))+'\x20'+_0x2d3a54[_0x5e899d(0x31c)]),console[_0x5e899d(0x3bd)]('\x20\x20'+a32_0x54ffbd['dim'](_0x5e899d(0x284))+'\x20'+_0x2d3a54[_0x5e899d(0x20b)]),console[_0x5e899d(0x3bd)]('\x20\x20'+_0x1a52a2),console['error']('\x0a'+a32_0x54ffbd['dim'](_0x5e899d(0x334))+_0x5e899d(0x2d7)+_0x2d3a54[_0x5e899d(0x20b)]+_0x5e899d(0x277)),0x0;}}export class ParentSegmentFieldsCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]=a32_0x3c5e89(0x36f);[a32_0x3c5e89(0x297)]='List\x20available\x20fields\x20for\x20segmentation';async[a32_0x3c5e89(0x2ce)](_0x2a5c95){const _0xf555b9=a32_0x3c5e89,{options:_0x2eb817,args:_0x21ca6f,tdx:_0x249302}=_0x2a5c95,_0x4f443b=_0x21ca6f[0x0]||_0x2eb817[_0xf555b9(0x1bc)];if(!_0x4f443b)return showParentSegmentNotSetError(_0xf555b9(0x23b)+_0xf555b9(0x2f2)),0x1;_0x2eb817[_0xf555b9(0x387)]&&(console[_0xf555b9(0x3bd)]('Site:\x20'+_0x2eb817['site']),console['error'](_0xf555b9(0x2c9)+_0x4f443b));const _0x5f2b3f=await withSpinner(_0xf555b9(0x35a)+_0x4f443b+_0xf555b9(0x288),()=>_0x249302['segment'][_0xf555b9(0x1c5)](_0x4f443b),{'verbose':_0x2eb817[_0xf555b9(0x387)]}),_0x9477c7=_0x5f2b3f[_0xf555b9(0x1ad)];console[_0xf555b9(0x3bd)]('✔\x20Found\x20'+_0x9477c7[_0xf555b9(0x30a)]+_0xf555b9(0x2a6)+(_0x9477c7[_0xf555b9(0x30a)]!==0x1?'s':''));if(_0x2eb817[_0xf555b9(0x2e5)]||_0x2eb817[_0xf555b9(0x1ae)])return await handleSDKOutput(_0x9477c7,_0x2eb817),0x0;return displayFieldsHumanReadable(_0x9477c7,_0x4f443b),0x0;}}export class ParentSegmentViewCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]='segment:parent:view';[a32_0x3c5e89(0x297)]=a32_0x3c5e89(0x32e);async[a32_0x3c5e89(0x2ce)](_0x3ab583){const _0x52e58f=a32_0x3c5e89,{options:_0x3d1110,args:_0x35a909,tdx:_0x434bbf}=_0x3ab583,_0x2a9bbe=_0x3d1110,_0x20ae69=_0x35a909[0x0]||_0x3d1110[_0x52e58f(0x1bc)];if(!_0x20ae69)return showParentSegmentNotSetError(_0x52e58f(0x3a6)+_0x52e58f(0x397)+_0x52e58f(0x1b2)+_0x52e58f(0x3b8)),0x1;_0x3d1110['verbose']&&(console['error'](_0x52e58f(0x39e)+_0x3d1110['site']),console['error'](_0x52e58f(0x2c9)+_0x20ae69));const _0x31d6bb=await withSpinner(_0x52e58f(0x1f9)+_0x20ae69+_0x52e58f(0x288),()=>_0x434bbf['segment']['getParentFull'](_0x20ae69),{'verbose':_0x3d1110[_0x52e58f(0x387)]}),_0x15be89=_0x31d6bb[_0x52e58f(0x1ad)];if(_0x2a9bbe[_0x52e58f(0x1a7)]){const _0xae7081=getConsoleNextUrl(_0x2a9bbe[_0x52e58f(0x1d1)],'/app/dw/parentSegments/'+_0x15be89['id']);return console[_0x52e58f(0x3bd)](a32_0x54ffbd[_0x52e58f(0x1d8)]('✔')+'\x20Opening\x20'+a32_0x54ffbd['cyan'](_0xae7081)),openBrowser(_0xae7081),0x0;}return await handleSingleObjectOutput(_0x15be89,_0x3d1110),0x0;}}export class ParentSegmentDescCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]=a32_0x3c5e89(0x1f2);['description']=a32_0x3c5e89(0x3a7);async['execute'](_0x1aa246){const _0x4bed3a=a32_0x3c5e89,{options:_0x40d512,args:_0x184201,tdx:_0x4049ce}=_0x1aa246,_0x5715f8=_0x40d512,_0x2dcfc3=_0x184201[0x0]||_0x40d512[_0x4bed3a(0x1bc)];if(!_0x2dcfc3)return showParentSegmentNotSetError(_0x4bed3a(0x30d)+_0x4bed3a(0x221)+_0x4bed3a(0x1b2)+'\x20\x20-o,\x20--output\x20<file>\x20\x20Output\x20file\x20path'),0x1;_0x40d512[_0x4bed3a(0x387)]&&(console['error']('Site:\x20'+_0x40d512[_0x4bed3a(0x1d1)]),console['error']('Parent\x20segment:\x20'+_0x2dcfc3));const _0x366893=await withSpinner(_0x4bed3a(0x245)+_0x2dcfc3+_0x4bed3a(0x288),()=>_0x4049ce[_0x4bed3a(0x1f3)][_0x4bed3a(0x251)](_0x2dcfc3),{'verbose':_0x40d512[_0x4bed3a(0x387)]}),_0x5b55b3=_0x366893[_0x4bed3a(0x1ad)],_0x4d0093=_0x4049ce[_0x4bed3a(0x1f3)][_0x4bed3a(0x2b6)](_0x5b55b3);if(_0x5715f8[_0x4bed3a(0x22e)]){const _0x1bd924=await this['collectSchema'](_0x1aa246,_0x2dcfc3,_0x5b55b3,_0x4d0093),_0xdf5345=this['formatSchemaJson'](_0x1bd924);writeFileSync(_0x5715f8['output'],_0xdf5345);const _0x4bd977=_0x1bd924[_0x4bed3a(0x1c0)][_0x4bed3a(0x22a)][_0x4bed3a(0x30a)]+_0x1bd924[_0x4bed3a(0x27f)][_0x4bed3a(0x1c9)]((_0x266168,_0x229ee4)=>_0x266168+_0x229ee4[_0x4bed3a(0x22a)][_0x4bed3a(0x30a)],0x0),_0x1608de=_0x1bd924[_0x4bed3a(0x27f)]['filter'](_0x4070b9=>_0x4070b9[_0x4bed3a(0x22a)][_0x4bed3a(0x30a)]===0x0)[_0x4bed3a(0x30a)];return console['log'](_0x4bed3a(0x32b)+_0x5715f8[_0x4bed3a(0x22e)]),console[_0x4bed3a(0x2c0)](_0x4bed3a(0x395)+_0x4d0093),console['log'](_0x4bed3a(0x26d)+_0x1bd924[_0x4bed3a(0x27f)][_0x4bed3a(0x30a)]+_0x4bed3a(0x208)),console[_0x4bed3a(0x2c0)](_0x4bed3a(0x3bc)+_0x4bd977+'\x20total'),_0x1608de>0x0&&console[_0x4bed3a(0x2c0)](_0x4bed3a(0x19c)+_0x1608de+_0x4bed3a(0x256)),0x0;}console[_0x4bed3a(0x3bd)]('\x0a'+a32_0x54ffbd[_0x4bed3a(0x1be)]('Output\x20Database:')+'\x20'+a32_0x54ffbd['cyan'](_0x4d0093));const _0x6ab84e=await withSpinner('Fetching\x20customers\x20schema...',()=>_0x4049ce[_0x4bed3a(0x1f3)]['getParentSQL'](_0x5b55b3),{'verbose':_0x40d512[_0x4bed3a(0x387)]});console['error']('\x0a'+a32_0x54ffbd[_0x4bed3a(0x1be)](_0x4bed3a(0x1c0))+'\x20'+a32_0x54ffbd[_0x4bed3a(0x2f6)]('('+_0x4d0093+'.customers)'));const _0x3fab46=await executeSchemaQuery(_0x6ab84e[_0x4bed3a(0x1ad)],_0x4049ce,_0x40d512);await handleQueryOutput(_0x3fab46,_0x40d512);const _0x232050=await withSpinner('Fetching\x20behavior\x20list...',()=>_0x4049ce['segment']['getBehaviorNames'](_0x5b55b3),{'verbose':_0x40d512[_0x4bed3a(0x387)]});for(const _0x2c3745 of _0x232050[_0x4bed3a(0x1ad)]){const _0xaf7f2e='behavior_'+_0x2c3745[_0x4bed3a(0x210)]()[_0x4bed3a(0x3bf)](/\s+/g,'_'),_0x44023d='SELECT\x20*\x20FROM\x20'+_0x4d0093+'.'+_0xaf7f2e;console['error']('\x0a'+a32_0x54ffbd[_0x4bed3a(0x1be)](_0x2c3745)+'\x20'+a32_0x54ffbd[_0x4bed3a(0x2f6)]('('+_0x4d0093+'.'+_0xaf7f2e+')'));try{const _0x3d6b14=await executeSchemaQuery(_0x44023d,_0x4049ce,_0x40d512);await handleQueryOutput(_0x3d6b14,_0x40d512);}catch{console[_0x4bed3a(0x3bd)](a32_0x54ffbd[_0x4bed3a(0x24d)](_0x4bed3a(0x2dd)));}}return 0x0;}async[a32_0x3c5e89(0x3a2)](_0xd4f9a7,_0x5572da,_0x1cd7c1,_0x45efc5){const _0x579e2f=a32_0x3c5e89,{options:_0x2669e5,tdx:_0x1dce0c}=_0xd4f9a7,_0x4c6bd8=await withSpinner(_0x579e2f(0x258),()=>_0x1dce0c['segment']['getParentSQL'](_0x1cd7c1),{'verbose':_0x2669e5[_0x579e2f(0x387)]}),_0x582f26=await executeSchemaQuery(_0x4c6bd8['data'],_0x1dce0c,_0x2669e5),_0x110cbe=_0x582f26[_0x579e2f(0x1ad)][_0x579e2f(0x383)](_0x5837bd=>({'name':_0x5837bd['column_name'],'type':_0x5837bd[_0x579e2f(0x26c)]})),_0xebcbc3=await withSpinner(_0x579e2f(0x317),()=>_0x1dce0c['segment'][_0x579e2f(0x230)](_0x1cd7c1),{'verbose':_0x2669e5[_0x579e2f(0x387)]}),_0x466db6=[];for(const _0x403f47 of _0xebcbc3[_0x579e2f(0x1ad)]){const _0x26fa87=_0x579e2f(0x205)+_0x403f47['toLowerCase']()[_0x579e2f(0x3bf)](/\s+/g,'_'),_0x57aa9c=_0x579e2f(0x3a1)+_0x45efc5+'.'+_0x26fa87;let _0xf50309=[];try{const _0x2afadd=await executeSchemaQuery(_0x57aa9c,_0x1dce0c,_0x2669e5);_0xf50309=_0x2afadd[_0x579e2f(0x1ad)][_0x579e2f(0x383)](_0x525d61=>({'name':_0x525d61[_0x579e2f(0x2f8)],'type':_0x525d61[_0x579e2f(0x26c)]}));}catch{}_0x466db6[_0x579e2f(0x19b)]({'table':_0x26fa87,'columns':_0xf50309});}return{'database':_0x45efc5,'parent_segment':_0x5572da,'parent_id':_0x1cd7c1,'customers':{'table':'customers','columns':_0x110cbe},'behaviors':_0x466db6};}['formatSchemaJson'](_0x5f55fa){const _0x59a3b3=a32_0x3c5e89,_0x5836ff=_0x57e23a=>{const _0x448c75=a32_0x375c;if(_0x57e23a['length']===0x0)return'[]';const _0x2dca8f=_0x57e23a[_0x448c75(0x383)](_0x2e9f80=>'\x20\x20\x20\x20\x20\x20{\x20\x22name\x22:\x20\x22'+_0x2e9f80['name']+_0x448c75(0x25a)+_0x2e9f80[_0x448c75(0x1b4)]+_0x448c75(0x241));return'[\x0a'+_0x2dca8f[_0x448c75(0x296)](',\x0a')+_0x448c75(0x1cc);},_0x13e2fa=_0x5f55fa[_0x59a3b3(0x27f)][_0x59a3b3(0x383)](_0x5f4c68=>{const _0x403f94=_0x59a3b3;return _0x403f94(0x360)+_0x5f4c68[_0x403f94(0x20a)]+'\x22,\x0a\x20\x20\x20\x20\x20\x20\x22columns\x22:\x20'+_0x5836ff(_0x5f4c68[_0x403f94(0x22a)])[_0x403f94(0x3bf)](/^/gm,'\x20\x20')[_0x403f94(0x232)]()+_0x403f94(0x388);})['join'](',\x0a');return'{\x0a\x20\x20\x22database\x22:\x20\x22'+_0x5f55fa[_0x59a3b3(0x279)]+'\x22,\x0a\x20\x20\x22parent_segment\x22:\x20\x22'+_0x5f55fa[_0x59a3b3(0x2c5)]+_0x59a3b3(0x2f9)+_0x5f55fa[_0x59a3b3(0x32d)]+_0x59a3b3(0x2a4)+_0x5f55fa[_0x59a3b3(0x1c0)][_0x59a3b3(0x20a)]+_0x59a3b3(0x1d0)+_0x5836ff(_0x5f55fa[_0x59a3b3(0x1c0)][_0x59a3b3(0x22a)])[_0x59a3b3(0x3bf)](/^/gm,'\x20\x20')['trim']()+'\x0a\x20\x20},\x0a\x20\x20\x22behaviors\x22:\x20[\x0a'+_0x13e2fa+_0x59a3b3(0x327);}}function a32_0x3f58(){const _0x4f32b0=['Usage:\x20tdx\x20ps\x20rt\x20jn\x20resume_activations\x20<journeyId>\x0a','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20service\x20show\x20<service_id>\x20\x20#\x20Uses\x20context','Usage:\x20tdx\x20parent-segment\x20preview\x20<name>\x20<option>\x0a','information_schema','behaviors','\x20--enriched','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20rt\x20validate\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Validate\x20RT\x20config\x20for\x20specific\x20parent\x20segment','FINISHED','Listing\x20personalization\x20services\x20for\x20\x27','Attempt:','\x0aTip:\x20Run\x20`tdx\x20ps\x20pz\x20service\x20init`\x20to\x20add\x20a\x20template\x20personalization\x20section\x20to\x20your\x20YAML','Error:\x20File\x20not\x20found:\x20','ps:rt:list','\x27...','createToken','Attributes','Updating','Error:\x20--description\x20is\x20required\x20(or\x20use\x20--file\x20for\x20a\x20full\x20request\x20body)','Use\x20-y\x20or\x20--yes\x20flag\x20to\x20apply\x20changes\x20without\x20confirmation','Usage:\x20tdx\x20ps\x20show\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Show\x20config\x20(requires\x20context)\x0a','\x20\x20--behavior\x20[name]\x20\x20\x20\x20Show\x20only\x20behaviors\x20(or\x20specific\x20one)\x0a','\x20configured','Patching\x20personalization\x20\x27','\x20stage','Usage:\x20tdx\x20ps\x20pz\x20service\x20token\x20create\x20<name>\x20<service_id>\x20[parent_segment]','displayMasterInfo','tdx\x20ps\x20preview\x20','join','description','listParents','scheduleType','Usage:\x20tdx\x20ps\x20pz\x20patch\x20<id>\x20--name\x20<name>\x20--description\x20<desc>\x20[--sections\x20<json>]','displayBehaviorsStats','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20preview\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Preview\x20specific\x20parent\x20segment\x0a\x0a','\x20\x20\x20\x20\x20\x20\x20Pass\x20null\x20to\x20place\x20in\x20the\x20root\x20folder.','✔\x20Retrieved\x20RT\x20configuration\x20version','2803072uwvoXs','attribute','displayPreviewHints','✔\x20Created\x20token\x20\x27','Listing\x20personalizations\x20for\x20\x27','\x22,\x0a\x20\x20\x22customers\x22:\x20{\x0a\x20\x20\x20\x20\x22table\x22:\x20\x22','Rows:','\x20field','segment:parent:update','Pausing\x20activations\x20for\x20RT\x20journey\x20\x27','createPersonalization','deletePersonalization','Error\x20parsing\x20YAML:\x20','No\x20parent\x20segments\x20match\x20pattern:\x20','\x27\x20for\x20service\x20\x27','Columns:','2CDBQbW','My\x20Service','Personalization:','✔\x20Created\x20parent\x20segment\x20\x27','segment:parent:preview','pushParentYaml','Table:\x20','getOutputDatabaseName','Overwrite\x20\x27','\x20service','segment:parent:validate','payload:','\x0a⚠️\x20\x20Both\x20','Usage:\x20tdx\x20ps\x20pz\x20service\x20list\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20List\x20PZ\x20services\x20(requires\x20context)\x0a','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20show\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Show\x20config\x20for\x20specific\x20parent\x20segment','Error:\x20Token\x20name\x20is\x20required','unref','log','Error:','\x0a⚠️\x20\x20DEPRECATED:\x20`tdx\x20segment\x20parent\x20create`\x20is\x20deprecated.\x0a','apply','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20create\x20--file\x20<path>','parent_segment','Usage:\x20tdx\x20ps\x20pz\x20service\x20show\x20<service_id>\x20[parent_segment]\x0a','Usage:\x20tdx\x20segment\x20parent\x20create\x20<name>\x20--database\x20<db>\x20--table\x20<table>','Usage:\x20tdx\x20ps\x20pz\x20service\x20token\x20create\x20<name>\x20<service_id>\x20[parent_segment]\x0a','Parent\x20segment:\x20','workflowId','red','displayRealtimeInfo','RT\x202.0\x20Validate:','execute','\x27\x20and\x20run\x20workflow?','SELECT\x20*\x20FROM\x20(\x0a','filter','getParentSQL','Tip:\x20Use\x20`tdx\x20ps\x20rt\x20jn\x20list\x20<parent_segment>`\x20to\x20find\x20journey\x20IDs','true','849358NKACbm','file','\x20tdx\x20wf\x20attempt\x20','.yaml','Database:\x20','Updating\x20personalization\x20service\x20\x27','⚠️\x20\x20personalization_services\x20section\x20already\x20exists\x20in\x20','Resume\x20activations\x20in\x20an\x20RT\x20journey','\x20\x20Schema\x20not\x20available\x20(workflow\x20may\x20not\x20have\x20run\x20yet)','updated:','Usage:\x20tdx\x20ps\x20rt\x20validate\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Validate\x20RT\x20config\x20(requires\x20context)\x0a','addBehaviorsFile','Error:\x20Parent\x20segment\x20name\x20is\x20required','Error:\x20Token\x20\x27','\x20service(s)\x20configured','keyEventCriteria','json','double','Output\x20file:\x20','Preview\x20sample\x20data\x20from\x20parent\x20segment\x20YAML\x20configuration','payload','open','displaySampleData','Attributes:','last_page_viewed','\x0aError:','Usage:\x20tdx\x20ps\x20pz\x20create\x20--name\x20<name>\x20--description\x20<desc>\x20--folder-id\x20<id>\x20[options]','\x20\x20\x20\x20-\x20','allowedIps','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20fields\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Show\x20fields\x20for\x20specific\x20parent\x20segment','foreignKey','Usage:\x20tdx\x20ps\x20push\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Push\x20(requires\x20context)\x0a','/\x20and\x20','dim','setJobId','column_name','\x22,\x0a\x20\x20\x22parent_id\x22:\x20\x22','2322918ApRTdb','\x20--interval\x20','rowCount','test','message','displayValidateResults','\x20personalization','Status:','Creating\x20personalization\x20service\x20\x27','Deleting\x20token\x20\x27','✔\x20Updated\x20personalization\x20\x27','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20sql\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Show\x20SQL\x20for\x20specific\x20parent\x20segment','isDirectory','all','\x20\x20\x20\x20','✔\x20Deleted\x20personalization\x20\x27','length','Fetching\x20sample\x20data...','token:','Usage:\x20tdx\x20ps\x20desc\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Describe\x20all\x20tables\x20(requires\x20context)\x0a','475ZETtow','cyan','single','updatedAt','behavior','Validate\x20RT\x202.0\x20configuration\x20from\x20parent\x20segment\x20YAML','addAttributes','\x20to\x20configure\x20your\x20personalization\x20service','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20patch\x20<id>\x20--file\x20<path>','Fetching\x20behavior\x20list...','keyEventId','audienceId','\x20rows)','\x20(paused)','workflowSessionId','Usage:\x20tdx\x20ps\x20rt\x20configuration_versions\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Get\x20RT\x20config\x20version\x20(requires\x20context)\x0a','label','\x20\x20--enriched\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Show\x20sample\x20enriched\x20master\x20data\x0a','getPersonalization','Update\x20a\x20personalization\x20service\x20name\x20and/or\x20description','created:','valid','personalization','td_client_id','public','\x0a\x20\x20]\x0a}\x0a','Usage:\x20tdx\x20ps\x20preview\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Preview\x20(requires\x20context)\x0a','ps:rt:validate','tokens','Schema\x20saved\x20to\x20','id:\x20','parent_id','Show\x20parent\x20segment\x20details','parentFolder','Finding\x20service\x20for\x20token...','Usage:\x20tdx\x20ps\x20pz\x20show\x20<personalization_id>','\x20\x20No\x20sample\x20data\x20available','sampleData','To\x20cancel:','Attribute:','matchedCount','ps:pz:service:token:create','✔\x20Renamed\x20directory\x20to\x20','Listing\x20RT-enabled\x20parent\x20segments...','toFixed','Error:\x20Token\x20ID\x20is\x20required','✔\x20Resumed\x20activations\x20for\x20RT\x20journey\x20\x27','patch','realtime:','keys','Error:\x20\x22relationships.parentFolder\x22\x20is\x20required\x20in\x20the\x20JSON\x20file.','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20service\x20token\x20delete\x20<token_id>\x20\x20#\x20Uses\x20context','page_view','\x20=\x20','Available\x20behaviors:','keyEventId:','repeat','Next\x20steps:','815937TpivVA','scheduleOption','number','/{name}.yml\x0a','enriched','Fetching\x20current\x20configuration\x20for\x20\x27','Join:','👥\x20','\x0aChanges\x20to\x20apply\x20to\x20\x27','ps:pz:service:create','.yml','allowed\x20IPs:','xdg-open','displayPreviewResults','ps:pz:patch','start','getCurrentConfigVersion','identifier','Listing\x20fields\x20for\x20\x27','RT\x20Journey\x20ID:\x20','No\x20RT-enabled\x20parent\x20segments\x20found','ps:pz:delete','sourceTableError','Pattern:\x20','\x20\x20\x20\x20{\x0a\x20\x20\x20\x20\x20\x20\x22table\x22:\x20\x22','\x27\x20(id:\x20','Usage:\x20tdx\x20ps\x20pz\x20service\x20show\x20<service_id>\x20[parent_segment]','use','previewParentYaml','Execute\x20parent\x20segment\x20SQL\x20query\x20and\x20show\x20results','Join\x20on:','session','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20service\x20delete\x20<service_id>\x20\x20#\x20Uses\x20context','\x20\x20--master\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Show\x20sample\x20master\x20table\x20data\x0a','utf-8','Error:\x20Service\x20name\x20is\x20required','Error:\x20--name\x20is\x20required','listJourneys','customerGroup','segment:parent:fields','attributes','\x20\x20--master\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Show\x20sample\x20master\x20table\x20data','Usage:\x20tdx\x20ps\x20pz\x20service\x20update\x20<service_id>\x20[parent_segment]\x20--name\x20<name>\x20[--description\x20<text>]','\x20\x202.\x20Run\x20','list','\x20\x20--behavior\x20<name>\x20\x20\x20\x20Show\x20sample\x20data\x20for\x20specific\x20behavior','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20service\x20token\x20create\x20<name>\x20<service_id>\x20\x20#\x20Uses\x20context','\x0a✔\x20Workflow\x20started','displayAttributesStats','/\x20→\x20','Error\x20reading\x20file:\x20','stitchingKeys','ps:pz:service:token:delete','name','No\x20parent\x20segments\x20found','Master\x20+\x20Attributes','segment:parent:push','launched','Update\x20existing\x20parent\x20segment\x20(audience)\x20[DEPRECATED]','map','Usage:\x20tdx\x20ps\x20pz\x20list\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20List\x20personalizations\x20(requires\x20context)\x0a','sort','Usage:\x20tdx\x20ps\x20rt\x20jn\x20list\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20List\x20RT\x20journeys\x20(requires\x20context)\x0a','verbose','\x0a\x20\x20\x20\x20}','YAML\x20file:\x20','patchPersonalization','stageCount','population','✔\x20Found\x20','\x20Context\x20set:\x20','Error:\x20No\x20behaviors\x20defined\x20in\x20configuration','Available\x20attributes:','\x5c$&','paused','\x20\x20\x20\x20\x20\x20\x20\x20','-1d','\x20\x20Database:\x20','schemaValid','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20view\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20View\x20specific\x20parent\x20segment\x0a\x0a','Tip:\x20Run\x20`tdx\x20ps\x20pull\x20-u\x20','✔\x20Paused\x20activations\x20for\x20RT\x20journey\x20\x27','\x20parent\x20segment','primaryKey','Coverage:','\x27\x20not\x20found\x20in\x20any\x20personalization\x20service','Site:\x20','identifier:\x20','updateParent','SELECT\x20*\x20FROM\x20','collectSchema','\x20is\x20already\x20up\x20to\x20date','idStitching','eventKind:\x20','Usage:\x20tdx\x20ps\x20view\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20View\x20(requires\x20context)\x0a','Show\x20parent\x20segment\x20schema\x20(column\x20types)','\x0aChanges\x20to\x20\x27','Updated','win32','yes','Validating\x20RT\x20configuration...','split','\x20true','List\x20realtime\x20personalizations\x20for\x20a\x20parent\x20segment','\x20\x20\x20Use\x20`tdx\x20segment\x20parent\x20push\x20<file.yml>`\x20instead\x20for\x20better\x20configuration\x20management.\x0a','run','endsWith','format','coveragePercent','\x20--behavior\x20\x22<name>\x22','/sessions/','interval','\x20\x20-w,\x20--web\x20\x20Open\x20parent\x20segment\x20in\x20web\x20browser','status','stop','toLocaleString','\x20\x20Columns:\x20','error','Getting\x20RT\x20configuration\x20version\x20for\x20\x27','replace','✔\x20No\x20changes\x20-\x20\x27','preview','push','\x20\x20Note:\x20','\x0aNew\x20parent\x20segment\x20\x27','\x20Added\x20RT\x202.0\x20template\x20section','List\x20parent\x20segments\x20with\x20RT\x202.0\x20status','tdx\x20ps\x20push\x20','Listing\x20RT\x20journeys\x20for\x20\x27','Error:\x20Service\x20ID\x20is\x20required','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20validate\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Validate\x20specific\x20parent\x20segment\x0a\x0a','✔\x20Query\x20completed:\x20Processed\x20','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20service\x20list\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20List\x20PZ\x20services\x20for\x20specific\x20parent\x20segment','Delete\x20a\x20realtime\x20personalization','web','\x20RT\x20configuration\x20is\x20valid','\x20\x20--behavior\x20<name>\x20\x20\x20\x20Show\x20sample\x20data\x20for\x20specific\x20behavior\x0a','Get\x20SQL\x20query\x20for\x20parent\x20segment','deleteToken','Error:\x20--attribute\x20requires\x20a\x20name\x0a','data','jsonl','Source:','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20init\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Add\x20PZ\x20template\x20for\x20specific\x20parent\x20segment','jobId','Options:\x0a','\x20\x20\x20Please\x20manually\x20merge\x20or\x20remove\x20','type','errors','pullParentYaml','\x20\x20--interval\x20<range>\x20\x20\x20TD_INTERVAL\x20time\x20range\x20for\x20behaviors\x20(default:\x20-1d)','Usage:\x20tdx\x20ps\x20pz\x20service\x20create\x20<name>\x20[parent_segment]','folderId','Error:\x20At\x20least\x20one\x20preview\x20option\x20required\x0a','\x20[Job\x20ID:\x20','parentSegment','platform','bold','To\x20view\x20sample\x20data:','customers','Usage:\x20tdx\x20ps\x20validate\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Validate\x20(requires\x20context)\x0a','customerGroupFile','audienceId:','customerPercent','listFields','\x27\x20with\x20ID:\x20','validateParentYaml','enabled','reduce','\x20--attribute\x20\x22<name>\x22','Creating\x20personalization\x20\x27','\x0a\x20\x20\x20\x20]','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20run\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Run\x20specific\x20parent\x20segment','displaySummary','elapsedTimeMillis','\x22,\x0a\x20\x20\x20\x20\x22columns\x22:\x20','site','displayColumns','master','Usage:\x20tdx\x20ps\x20run\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Run\x20(requires\x20context)\x0a','eventKind','using\x20the\x20default\x20path:\x20','\x27\x20is\x20already\x20up\x20to\x20date','green','\x20\x20\x20','Listing\x20RT-enabled\x20parent\x20segments\x20matching\x20\x27','7dAhizh','⚡\x20Not\x20enabled','Create\x20a\x20personalization\x20service\x20for\x20a\x20parent\x20segment','\x20\x20\x20\x20\x20\x20','Apply\x20changes\x20to\x20\x27','(id:\x20','Validating\x20configuration...','schemaError','\x20+\x20[','attributesFile','✔\x20Updated\x20personalization\x20service\x20\x27','joinKey','Add\x20template\x20personalization\x20section\x20to\x20parent\x20segment\x20YAML','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20push\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Push\x20specific\x20parent\x20segment','Events:','Deleting\x20personalization\x20\x27','SQL\x20query:\x0a','18652KstYSE','/app/workflows/','delete','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20service\x20update\x20<service_id>\x20--name\x20<name>\x20\x20#\x20Uses\x20context','\x20rows\x20','realtime','segment:parent:desc','segment','No\x20personalizations\x20configured','\x20\x201.\x20Edit\x20','ps:rt:jn:pause','Created','segment:parent:sql','Fetching\x20parent\x20segment\x20\x27','Show\x20personalization\x20service\x20details','<database>.<table>','\x20Saved\x20parent\x20segment\x20configuration\x20to\x20','\x20No\x20changes\x20-\x20','Executing\x20parent\x20segment\x20query...','Push\x20parent\x20segment\x20configuration\x20from\x20YAML\x20file','Tip:\x20Use\x20-u\x20without\x20-o,\x20or\x20-o\x20without\x20-u','sourceTableValid','Name:\x20','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20service\x20create\x20<name>\x20\x20#\x20Uses\x20context','Fetching\x20personalization\x20service\x20\x27','behavior_','Error:\x20RT\x20journey\x20ID\x20is\x20required\x0a','Master:','\x20behaviors','entryCriteria','table','workflowAttemptId','✔\x20Created\x20personalization\x20\x27','localeCompare','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pull\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Pull\x20specific\x20parent\x20segment','query','toLowerCase','status:\x20','dirname','\x20--attribute\x20\x22','Fetching\x20SQL\x20for\x20\x27','✔\x20Deleted\x20personalization\x20service\x20\x27','processedRows','get','events','ignore','\x20to\x20push\x20the\x20configuration','resumeJourney','no\x20tokens\x20configured','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20rt\x20configuration_versions\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Get\x20RT\x20config\x20version\x20for\x20specific\x20parent\x20segment','Usage:\x20tdx\x20ps\x20pz\x20service\x20update\x20<service_id>\x20[parent_segment]\x20--name\x20<name>\x20[--description\x20<text>]\x0a','state','Preview:','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20desc\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Describe\x20all\x20tables\x20for\x20parent\x20segment\x0a\x0a','List\x20parent\x20segments','audienceId:\x20','allValid','Error:\x20--name\x20is\x20required\x20(or\x20use\x20--file\x20for\x20a\x20full\x20request\x20body)','7486443ggQypZ','create','ps:rt:jn:list','\x0a⚠\x20Save\x20this\x20token\x20value\x20-\x20it\x20will\x20not\x20be\x20shown\x20again:','columns','ps:rt:configuration_versions','pauseJourney','\x20\x20\x20See:\x20tdx\x20segment\x20parent\x20pull\x20--help\x0a','output','Creating','getBehaviorNames','addAttributesFile','trim','personalization_services','ps:pz:show','includeSensitive:','Errors:','Error:\x20--behavior\x20requires\x20a\x20name\x0a','value','Create\x20parent\x20segment\x20\x27','Creating\x20token\x20\x27','Usage:\x20tdx\x20ps\x20fields\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Show\x20fields\x20(requires\x20context)\x0a','\x20RT\x20journey','personalizationServices','\x0a⚠️\x20\x20Migrating:\x20','Usage:\x20tdx\x20ps\x20pz\x20service\x20token\x20delete\x20<token_id>\x20[parent_segment]\x0a','Personalization\x20service\x20description','\x22\x20}','Error:\x20Personalization\x20ID\x20is\x20required','indexOf','6959360UfGnPq','Resolving\x20parent\x20segment\x20\x27','✔\x20Found\x20personalization\x20\x27','timezone','Confirmation\x20required\x20but\x20running\x20in\x20non-interactive\x20mode','✘\x20Failed\x20to\x20rename\x20directory:\x20','getParentFull','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20list\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20List\x20personalizations\x20for\x20specific\x20parent\x20segment','Listing\x20parent\x20segments\x20matching\x20\x27','yellow','Usage:\x20tdx\x20ps\x20pz\x20init\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Add\x20PZ\x20template\x20(requires\x20context)\x0a','/app/dw/parentSegments/','Session:','resolveParentId','Getting\x20personalization\x20\x27','includeSensitive','segment:parent:run','Usage:\x20tdx\x20ps\x20pull\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Pull\x20(requires\x20context)\x0a','\x20behavior\x20tables\x20not\x20yet\x20generated\x20(workflow\x20may\x20not\x20have\x20run)','Behaviors','Fetching\x20customers\x20schema...','Options:','\x22,\x20\x22type\x22:\x20\x22','\x20parent\x20segment\x20\x27','sections','Get\x20current\x20RT\x20configuration\x20version\x20status','column','\x20Configuration\x20is\x20valid','some','segment:parent:list','segment:parent:show','ps:pz:list','Aborted.','%)\x20','sections:','segment:parent:create','✔\x20Deleted\x20token\x20\x27','any','\x0aUsage:\x20tdx\x20ps\x20preview\x20','string','column_type','\x20\x20Tables:\x201\x20customers\x20+\x20','text','\x20\x20\x22relationships\x22:\x20{\x20\x22parentFolder\x22:\x20{\x20\x22data\x22:\x20{\x20\x22id\x22:\x20\x22<id>\x22,\x20\x22type\x22:\x20\x22folder-segment\x22\x20}\x20}\x20}','stringify','Audience\x20ID:','createParent','limit','ps:rt:jn:resume','behaviorsFile','ps:pz:service:list','\x20kill','\x0aNo\x20sample\x20data\x20available','database','RT\x202.0:'];a32_0x3f58=function(){return _0x4f32b0;};return a32_0x3f58();}export class ParentSegmentSQLCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]=a32_0x3c5e89(0x1f8);['description']=a32_0x3c5e89(0x1aa);async['execute'](_0x52d461){const _0x554cb9=a32_0x3c5e89,{options:_0x3b360f,args:_0x22c900,tdx:_0x58eb0d}=_0x52d461,_0x13733a=_0x22c900[0x0]||_0x3b360f[_0x554cb9(0x1bc)];if(!_0x13733a)return showParentSegmentNotSetError('Usage:\x20tdx\x20ps\x20sql\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Show\x20SQL\x20(requires\x20context)\x0a'+_0x554cb9(0x305)),0x1;_0x3b360f[_0x554cb9(0x387)]&&(console[_0x554cb9(0x3bd)](_0x554cb9(0x39e)+_0x3b360f[_0x554cb9(0x1d1)]),console[_0x554cb9(0x3bd)](_0x554cb9(0x2c9)+_0x13733a));const _0x29c2d9=await withSpinner('Resolving\x20parent\x20segment\x20\x27'+_0x13733a+_0x554cb9(0x288),()=>_0x58eb0d['segment'][_0x554cb9(0x251)](_0x13733a),{'verbose':_0x3b360f[_0x554cb9(0x387)]}),_0x2e6bf6=_0x29c2d9[_0x554cb9(0x1ad)],_0x132768=await withSpinner(_0x554cb9(0x214)+_0x13733a+_0x554cb9(0x288),()=>_0x58eb0d[_0x554cb9(0x1f3)]['getParentSQL'](_0x2e6bf6),{'verbose':_0x3b360f[_0x554cb9(0x387)]}),_0x5f313f=_0x132768[_0x554cb9(0x1ad)];return _0x3b360f['format']===_0x554cb9(0x2e5)||_0x3b360f[_0x554cb9(0x3b3)]===_0x554cb9(0x1ae)?await handleSDKOutput([{'sql':_0x5f313f}],_0x3b360f):console[_0x554cb9(0x2c0)](_0x5f313f),0x0;}}export class ParentSegmentShowCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]=a32_0x3c5e89(0x262);[a32_0x3c5e89(0x297)]=a32_0x3c5e89(0x365);async['execute'](_0x207dc3){const _0x3f4e74=a32_0x3c5e89,{options:_0xe35f0,args:_0x2af5cf,tdx:_0x3e0323}=_0x207dc3,_0xf0fe23=_0x2af5cf[0x0]||_0xe35f0[_0x3f4e74(0x1bc)];if(!_0xf0fe23)return showParentSegmentNotSetError(_0x3f4e74(0x28e)+_0x3f4e74(0x2bd)),0x1;_0xe35f0[_0x3f4e74(0x387)]&&(console[_0x3f4e74(0x3bd)](_0x3f4e74(0x39e)+_0xe35f0['site']),console[_0x3f4e74(0x3bd)](_0x3f4e74(0x2c9)+_0xf0fe23));const _0x3fb2c7=await withSpinner(_0x3f4e74(0x245)+_0xf0fe23+'\x27...',()=>_0x3e0323['segment']['resolveParentId'](_0xf0fe23),{'verbose':_0xe35f0[_0x3f4e74(0x387)]}),_0xf2088a=_0x3fb2c7['data'],_0x1e35b7=await withSpinner(_0x3f4e74(0x214)+_0xf0fe23+'\x27...',()=>_0x3e0323[_0x3f4e74(0x1f3)][_0x3f4e74(0x2d2)](_0xf2088a),{'verbose':_0xe35f0[_0x3f4e74(0x387)]});let _0x2ca9ee=_0x1e35b7[_0x3f4e74(0x1ad)];const _0x2f90fa=resolveLimit(_0xe35f0[_0x3f4e74(0x273)],DEFAULT_DISPLAY_LIMIT),_0x776490=/\bLIMIT\s+\d+/i[_0x3f4e74(0x2fd)](_0x2ca9ee);!_0x776490&&(_0x2ca9ee=_0x2ca9ee['trim']()[_0x3f4e74(0x3bf)](/;+$/,''),_0x2ca9ee=_0x3f4e74(0x2d0)+_0x2ca9ee+'\x0a)\x20AS\x20segment_query\x0aLIMIT\x20'+_0x2f90fa);_0xe35f0[_0x3f4e74(0x387)]&&console[_0x3f4e74(0x3bd)](_0x3f4e74(0x1eb)+_0x2ca9ee);const _0x2da8b5=await withProgressSpinner(_0x3f4e74(0x1fe),async _0x2f635a=>{const _0x2087f1=_0x3f4e74,_0x46257e=await _0x3e0323[_0x2087f1(0x20f)][_0x2087f1(0x2ce)](_0x2ca9ee,{'catalog':'td','schema':_0x2087f1(0x27e),'onJobId':_0x5e86bd=>{const _0xf70821=_0x2087f1;_0x2f635a[_0xf70821(0x2f7)](_0x5e86bd);}});return _0x46257e;},{'verbose':_0xe35f0[_0x3f4e74(0x387)]}),_0x53802e=_0x2da8b5['data'],_0x31c68c=_0x53802e[_0x3f4e74(0x1b1)]?_0x3f4e74(0x1bb)+_0x53802e[_0x3f4e74(0x1b1)]+']':'';return console['error'](_0x3f4e74(0x1a4)+_0x53802e['stats'][_0x3f4e74(0x216)][_0x3f4e74(0x3bb)]()+_0x3f4e74(0x1f0)+('in\x20'+formatElapsed(_0x53802e['stats'][_0x3f4e74(0x1cf)])+_0x31c68c)),await handleQueryOutput(_0x53802e,_0xe35f0),0x0;}}export class PSRtListCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]=a32_0x3c5e89(0x287);[a32_0x3c5e89(0x297)]=a32_0x3c5e89(0x19f);async[a32_0x3c5e89(0x2ce)](_0x4b17c5){const _0x425f36=a32_0x3c5e89,{options:_0xf2e8a6,args:_0x2eb87d,tdx:_0x4dec56}=_0x4b17c5,_0x22b89c=_0x2eb87d[0x0],_0x36f18f=await withSpinner(_0x22b89c?_0x425f36(0x1da)+_0x22b89c+_0x425f36(0x288):_0x425f36(0x339),()=>_0x4dec56[_0x425f36(0x1f1)]['list'](),{'verbose':_0xf2e8a6[_0x425f36(0x387)]});let _0x17786e=_0x36f18f[_0x425f36(0x1ad)][_0x425f36(0x2d1)](_0x12bf48=>_0x12bf48['realtime_enabled']);if(_0x22b89c){const _0x2d1a78=_0x22b89c['replace'](/[.+^${}()|[\]\\]/g,_0x425f36(0x391))['replace'](/\*/g,'.*')['replace'](/\?/g,'.'),_0x479657=new RegExp('^'+_0x2d1a78+'$','i');_0x17786e=_0x17786e['filter'](_0xec32df=>_0x479657[_0x425f36(0x2fd)](_0xec32df[_0x425f36(0x37d)]));}_0x17786e[_0x425f36(0x385)]((_0x4c9290,_0xd1242c)=>_0x4c9290[_0x425f36(0x37d)]['localeCompare'](_0xd1242c['name'])),console[_0x425f36(0x3bd)](_0x425f36(0x38d)+_0x17786e[_0x425f36(0x30a)]+'\x20RT-enabled\x20parent\x20segment'+(_0x17786e[_0x425f36(0x30a)]!==0x1?'s':''));const _0x23c4c5=_0x37f073=>{const _0x248f27=_0x425f36;return getConsoleNextUrl(_0xf2e8a6[_0x248f27(0x1d1)],_0x248f27(0x24f)+_0x37f073);};if(_0xf2e8a6[_0x425f36(0x3b3)]==='json'||_0xf2e8a6['format']===_0x425f36(0x1ae)){const _0x57562a=_0x17786e['map'](_0x516749=>({..._0x516749,'url':_0x23c4c5(_0x516749['id'])}));await handleSDKOutput(_0x57562a,_0xf2e8a6);}else{if(_0x17786e[_0x425f36(0x30a)]===0x0)console['log'](_0x425f36(0x35c));else for(const _0x24243d of _0x17786e){const _0x5551c8=_0x24243d[_0x425f36(0x38c)]?a32_0x54ffbd['dim']('\x20('+formatRows(_0x24243d[_0x425f36(0x38c)])+')'):'',_0x3881a0=hyperlink(_0x24243d[_0x425f36(0x37d)],_0x23c4c5(_0x24243d['id']));console[_0x425f36(0x2c0)]('⚡\x20'+_0x3881a0+_0x5551c8);}}return 0x0;}}export class PSRtValidateCommand extends BaseParentSegmentCommand{['name']=a32_0x3c5e89(0x329);['description']=a32_0x3c5e89(0x313);async[a32_0x3c5e89(0x2ce)](_0x558e77){const _0x488f21=a32_0x3c5e89,{options:_0x40b265,args:_0x281961,tdx:_0x9d9732}=_0x558e77,_0x21c4b7=_0x281961[0x0]||_0x40b265[_0x488f21(0x1bc)];if(!_0x21c4b7)return showParentSegmentNotSetError(_0x488f21(0x2df)+_0x488f21(0x281)),0x1;const _0x1c6e5a=resolveYamlFile(_0x21c4b7);if(!existsSync(_0x1c6e5a))return showFileNotFoundError(_0x1c6e5a,_0x21c4b7),0x1;let _0x3dd2ce;try{_0x3dd2ce=readFileSync(_0x1c6e5a,_0x488f21(0x36a));}catch(_0xeaf84a){const _0x4f3bd4=_0xeaf84a instanceof Error?_0xeaf84a[_0x488f21(0x2fe)]:String(_0xeaf84a);return console['error'](_0x488f21(0x37a)+_0x4f3bd4),0x1;}const _0x3a6f2c=createCommandSpinner(a32_0x54ffbd['dim'](_0x488f21(0x3ac)),{'verbose':_0x40b265[_0x488f21(0x387)]});_0x3a6f2c['start']();const _0x13acf7={'realtime':!![],'onProgress':_0x17bf31=>{const _0x3a745e=_0x488f21;_0x3a6f2c[_0x3a745e(0x26e)]=formatProgressMessage(_0x17bf31);}};let _0x44c457;try{_0x44c457=await _0x9d9732[_0x488f21(0x1f3)][_0x488f21(0x1c7)](_0x3dd2ce,_0x13acf7),_0x3a6f2c['stop']();}catch(_0x1cc47c){_0x3a6f2c['stop']();throw _0x1cc47c;}console[_0x488f21(0x3bd)]('\x0a'+a32_0x54ffbd[_0x488f21(0x1be)](_0x488f21(0x2cd))+'\x20'+_0x44c457['name']),console[_0x488f21(0x3bd)]('═'[_0x488f21(0x346)](0x3c)),displayRealtimeValidation(_0x44c457),console[_0x488f21(0x3bd)]('─'[_0x488f21(0x346)](0x3c));if(_0x44c457[_0x488f21(0x1b5)][_0x488f21(0x30a)]>0x0){console[_0x488f21(0x3bd)]('\x0a'+a32_0x54ffbd['red'](_0x488f21(0x236)));for(const _0x4ace47 of _0x44c457['errors']){console[_0x488f21(0x3bd)]('\x20\x20'+a32_0x54ffbd[_0x488f21(0x2cb)]('•')+'\x20'+_0x4ace47);}}return _0x44c457['allValid']&&console['error']('\x0a'+a32_0x54ffbd[_0x488f21(0x1d8)]('✔')+_0x488f21(0x1a8)),_0x44c457[_0x488f21(0x224)]?0x0:0x1;}}export class PSRtJnListCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]=a32_0x3c5e89(0x228);[a32_0x3c5e89(0x297)]='List\x20RT\x20journeys';async['execute'](_0x4c4141){const _0x26db70=a32_0x3c5e89,{options:_0x48f657,args:_0x44eb5f,tdx:_0x43189d}=_0x4c4141,_0x57ea28=_0x44eb5f[0x0]||_0x48f657[_0x26db70(0x1bc)];if(!_0x57ea28)return showParentSegmentNotSetError(_0x26db70(0x386)+'\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20rt\x20jn\x20list\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20List\x20RT\x20journeys\x20for\x20specific\x20parent\x20segment'),0x1;_0x48f657[_0x26db70(0x387)]&&(console[_0x26db70(0x3bd)](_0x26db70(0x39e)+_0x48f657[_0x26db70(0x1d1)]),console[_0x26db70(0x3bd)](_0x26db70(0x2c9)+_0x57ea28));const _0x2a54b3=await withSpinner(_0x26db70(0x245)+_0x57ea28+_0x26db70(0x288),()=>_0x43189d[_0x26db70(0x1f3)]['resolveParentId'](_0x57ea28),{'verbose':_0x48f657[_0x26db70(0x387)]}),_0x5aea90=_0x2a54b3['data'],_0x204a73=await withSpinner(_0x26db70(0x1a1)+_0x57ea28+_0x26db70(0x288),()=>_0x43189d[_0x26db70(0x1f1)][_0x26db70(0x36d)](_0x5aea90),{'verbose':_0x48f657[_0x26db70(0x387)]}),_0x4aad12=_0x204a73['data'];console[_0x26db70(0x3bd)]('✔\x20Found\x20'+_0x4aad12['length']+_0x26db70(0x23c)+(_0x4aad12['length']!==0x1?'s':''));if(_0x48f657[_0x26db70(0x3b3)]===_0x26db70(0x2e5)||_0x48f657[_0x26db70(0x3b3)]===_0x26db70(0x1ae))await handleSDKOutput(_0x4aad12,_0x48f657);else{if(_0x4aad12[_0x26db70(0x30a)]===0x0)console['log']('No\x20RT\x20journeys\x20found');else for(const _0x24d564 of _0x4aad12){const _0x676a2f=_0x24d564[_0x26db70(0x21f)]==='launched'?'🚀':'📝',_0x59baf8=_0x24d564[_0x26db70(0x392)]?a32_0x54ffbd['yellow']('\x20(paused)'):'',_0xde6839=a32_0x54ffbd[_0x26db70(0x2f6)]('\x20('+_0x24d564['stageCount']+_0x26db70(0x292)+(_0x24d564[_0x26db70(0x38b)]!==0x1?'s':'')+')');console[_0x26db70(0x2c0)](_0x676a2f+'\x20'+_0x24d564[_0x26db70(0x37d)]+_0x59baf8+_0xde6839);}}return 0x0;}}export class PSRtJnPauseCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]=a32_0x3c5e89(0x1f6);[a32_0x3c5e89(0x297)]='Pause\x20activations\x20in\x20an\x20RT\x20journey';async[a32_0x3c5e89(0x2ce)](_0x16c65e){const _0x553aee=a32_0x3c5e89,{options:_0x48da5f,args:_0x544de0,tdx:_0x3000bf}=_0x16c65e,_0xa20d5c=_0x544de0[0x0];if(!_0xa20d5c)return console[_0x553aee(0x3bd)](a32_0x54ffbd[_0x553aee(0x2cb)](_0x553aee(0x206))),console[_0x553aee(0x3bd)]('Usage:\x20tdx\x20ps\x20rt\x20jn\x20pause_activations\x20<journeyId>\x0a'),console[_0x553aee(0x3bd)](a32_0x54ffbd[_0x553aee(0x2f6)](_0x553aee(0x2d3))),0x1;_0x48da5f[_0x553aee(0x387)]&&(console[_0x553aee(0x3bd)](_0x553aee(0x39e)+_0x48da5f[_0x553aee(0x1d1)]),console['error'](_0x553aee(0x35b)+_0xa20d5c));const _0x2f4e76=await withSpinner(_0x553aee(0x2a8)+_0xa20d5c+_0x553aee(0x288),()=>_0x3000bf[_0x553aee(0x1f1)][_0x553aee(0x22c)](_0xa20d5c),{'verbose':_0x48da5f[_0x553aee(0x387)]}),_0x33f80f=_0x2f4e76['data'];console[_0x553aee(0x3bd)](_0x553aee(0x399)+_0x33f80f[_0x553aee(0x37d)]+'\x27');if(_0x48da5f[_0x553aee(0x3b3)]==='json'||_0x48da5f['format']===_0x553aee(0x1ae))await handleSDKOutput([_0x33f80f],_0x48da5f);else{const _0x45becb=_0x33f80f[_0x553aee(0x21f)]===_0x553aee(0x381)?'🚀':'📝',_0x3ee7c0=_0x33f80f[_0x553aee(0x392)]?a32_0x54ffbd[_0x553aee(0x24d)](_0x553aee(0x31b)):'';console['log'](_0x45becb+'\x20'+_0x33f80f[_0x553aee(0x37d)]+_0x3ee7c0);}return 0x0;}}export class PSRtJnResumeCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]=a32_0x3c5e89(0x274);[a32_0x3c5e89(0x297)]=a32_0x3c5e89(0x2dc);async[a32_0x3c5e89(0x2ce)](_0x9d9302){const _0x549519=a32_0x3c5e89,{options:_0x267e10,args:_0x24700e,tdx:_0x1bdf26}=_0x9d9302,_0x2136cc=_0x24700e[0x0];if(!_0x2136cc)return console[_0x549519(0x3bd)](a32_0x54ffbd[_0x549519(0x2cb)](_0x549519(0x206))),console[_0x549519(0x3bd)](_0x549519(0x27b)),console[_0x549519(0x3bd)](a32_0x54ffbd[_0x549519(0x2f6)](_0x549519(0x2d3))),0x1;_0x267e10[_0x549519(0x387)]&&(console[_0x549519(0x3bd)]('Site:\x20'+_0x267e10[_0x549519(0x1d1)]),console[_0x549519(0x3bd)]('RT\x20Journey\x20ID:\x20'+_0x2136cc));const _0x5bfcf0=await withSpinner('Resuming\x20activations\x20for\x20RT\x20journey\x20\x27'+_0x2136cc+'\x27...',()=>_0x1bdf26[_0x549519(0x1f1)][_0x549519(0x21b)](_0x2136cc),{'verbose':_0x267e10[_0x549519(0x387)]}),_0x37b541=_0x5bfcf0[_0x549519(0x1ad)];console[_0x549519(0x3bd)](_0x549519(0x33c)+_0x37b541[_0x549519(0x37d)]+'\x27');if(_0x267e10['format']===_0x549519(0x2e5)||_0x267e10[_0x549519(0x3b3)]===_0x549519(0x1ae))await handleSDKOutput([_0x37b541],_0x267e10);else{const _0x9526a5=_0x37b541['state']===_0x549519(0x381)?'🚀':'📝',_0x5df43a=_0x37b541[_0x549519(0x392)]?a32_0x54ffbd[_0x549519(0x24d)](_0x549519(0x31b)):'';console[_0x549519(0x2c0)](_0x9526a5+'\x20'+_0x37b541[_0x549519(0x37d)]+_0x5df43a);}return 0x0;}}export class PSRtConfigVersionCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]=a32_0x3c5e89(0x22b);[a32_0x3c5e89(0x297)]=a32_0x3c5e89(0x25d);async[a32_0x3c5e89(0x2ce)](_0x1ecd96){const _0x410e06=a32_0x3c5e89,{options:_0xeabf,args:_0x25bd45,tdx:_0x5741da}=_0x1ecd96,_0x6bed6f=_0x25bd45[0x0]||_0xeabf[_0x410e06(0x1bc)];if(!_0x6bed6f)return showParentSegmentNotSetError(_0x410e06(0x31d)+_0x410e06(0x21d)),0x1;_0xeabf[_0x410e06(0x387)]&&(console[_0x410e06(0x3bd)](_0x410e06(0x39e)+_0xeabf[_0x410e06(0x1d1)]),console[_0x410e06(0x3bd)](_0x410e06(0x2c9)+_0x6bed6f));const _0x22b15f=await withSpinner('Resolving\x20parent\x20segment\x20\x27'+_0x6bed6f+_0x410e06(0x288),()=>_0x5741da[_0x410e06(0x1f3)]['resolveParentId'](_0x6bed6f),{'verbose':_0xeabf[_0x410e06(0x387)]}),_0x434109=_0x22b15f[_0x410e06(0x1ad)],_0x171d12=await withSpinner(_0x410e06(0x3be)+_0x6bed6f+_0x410e06(0x288),()=>_0x5741da[_0x410e06(0x1f1)][_0x410e06(0x358)](_0x434109),{'verbose':_0xeabf[_0x410e06(0x387)]}),_0x32be3d=_0x171d12[_0x410e06(0x1ad)];return console[_0x410e06(0x3bd)](_0x410e06(0x29e)),_0xeabf[_0x410e06(0x3b3)]===_0x410e06(0x2e5)||_0xeabf[_0x410e06(0x3b3)]===_0x410e06(0x1ae)?await handleSDKOutput([_0x32be3d],_0xeabf):(console[_0x410e06(0x2c0)](_0x410e06(0x32c)+_0x32be3d['id']),console[_0x410e06(0x2c0)](_0x410e06(0x223)+_0x32be3d[_0x410e06(0x319)]),console[_0x410e06(0x2c0)](_0x410e06(0x39f)+_0x32be3d[_0x410e06(0x359)]),console['log'](_0x410e06(0x3a5)+_0x32be3d[_0x410e06(0x1d5)]),console[_0x410e06(0x2c0)](_0x410e06(0x211)+_0x32be3d['status'])),0x0;}}export class PSPzServiceListCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]=a32_0x3c5e89(0x276);[a32_0x3c5e89(0x297)]='List\x20personalization\x20services\x20for\x20a\x20parent\x20segment';async[a32_0x3c5e89(0x2ce)](_0x5db950){const _0x3218c7=a32_0x3c5e89,{options:_0x3ceda7,args:_0x587aa1,tdx:_0x56b232}=_0x5db950,_0x2c5c27=_0x587aa1[0x0]||_0x3ceda7[_0x3218c7(0x1bc)];if(!_0x2c5c27)return showParentSegmentNotSetError(_0x3218c7(0x2bc)+_0x3218c7(0x1a5)),0x1;const _0x182f83=await withSpinner(_0x3218c7(0x245)+_0x2c5c27+_0x3218c7(0x288),()=>_0x56b232[_0x3218c7(0x1f3)][_0x3218c7(0x251)](_0x2c5c27),{'verbose':_0x3ceda7[_0x3218c7(0x387)]}),_0x50bf94=_0x182f83[_0x3218c7(0x1ad)],_0x5e655c=await withSpinner(_0x3218c7(0x283)+_0x2c5c27+_0x3218c7(0x288),()=>_0x56b232['personalization']['list'](_0x50bf94),{'verbose':_0x3ceda7[_0x3218c7(0x387)]}),_0xbae874=_0x5e655c[_0x3218c7(0x1ad)];console[_0x3218c7(0x3bd)](_0x3218c7(0x38d)+_0xbae874[_0x3218c7(0x30a)]+'\x20personalization\x20service'+(_0xbae874[_0x3218c7(0x30a)]!==0x1?'s':''));if(_0x3ceda7[_0x3218c7(0x3b3)]===_0x3218c7(0x2e5)||_0x3ceda7[_0x3218c7(0x3b3)]===_0x3218c7(0x1ae))await handleSDKOutput(_0xbae874,_0x3ceda7);else{if(_0xbae874[_0x3218c7(0x30a)]===0x0)console[_0x3218c7(0x2c0)]('No\x20personalization\x20services\x20configured'),console[_0x3218c7(0x3bd)](a32_0x54ffbd[_0x3218c7(0x30f)](_0x3218c7(0x285)));else for(const _0x2c0b18 of _0xbae874){console[_0x3218c7(0x2c0)](a32_0x54ffbd['bold'](_0x2c0b18[_0x3218c7(0x37d)])+'\x20'+a32_0x54ffbd['dim'](_0x3218c7(0x1e0)+_0x2c0b18['id']+')'));_0x2c0b18[_0x3218c7(0x297)]&&console[_0x3218c7(0x2c0)]('\x20\x20'+a32_0x54ffbd[_0x3218c7(0x2f6)](_0x2c0b18['description']));if(_0x2c0b18[_0x3218c7(0x32a)]&&_0x2c0b18[_0x3218c7(0x32a)][_0x3218c7(0x30a)]>0x0)for(const _0x5960d7 of _0x2c0b18[_0x3218c7(0x32a)]){const _0x4cb5ee=_0x5960d7[_0x3218c7(0x2f1)]?.[_0x3218c7(0x30a)]?_0x5960d7[_0x3218c7(0x2f1)][_0x3218c7(0x296)](',\x20'):_0x3218c7(0x269);console[_0x3218c7(0x2c0)]('\x20\x20'+a32_0x54ffbd[_0x3218c7(0x30f)](_0x3218c7(0x30c))+'\x20'+_0x5960d7[_0x3218c7(0x37d)]+'\x20'+a32_0x54ffbd[_0x3218c7(0x2f6)](_0x3218c7(0x1e0)+_0x5960d7['id']+')')),console[_0x3218c7(0x2c0)](_0x3218c7(0x308)+a32_0x54ffbd[_0x3218c7(0x2f6)](_0x3218c7(0x353))+'\x20'+_0x4cb5ee);}else console[_0x3218c7(0x2c0)]('\x20\x20'+a32_0x54ffbd[_0x3218c7(0x2f6)](_0x3218c7(0x21c)));}}return 0x0;}}export class PSPzServiceCreateCommand extends BaseCommand{['name']=a32_0x3c5e89(0x351);[a32_0x3c5e89(0x297)]=a32_0x3c5e89(0x1dd);async[a32_0x3c5e89(0x2ce)](_0x5db688){const _0x45389b=a32_0x3c5e89,{options:_0x45cd34,args:_0x1fcaa9,tdx:_0x184e47}=_0x5db688,_0x44aa8f=_0x45cd34,_0x4b01ca=_0x1fcaa9[0x0],_0x436f10=_0x1fcaa9[0x1]||_0x45cd34[_0x45389b(0x1bc)];if(!_0x4b01ca)return console[_0x45389b(0x3bd)](_0x45389b(0x36b)),console[_0x45389b(0x3bd)](_0x45389b(0x1b8)),console[_0x45389b(0x3bd)](_0x45389b(0x203)),0x1;if(!_0x436f10)return showParentSegmentNotSetError('Usage:\x20tdx\x20ps\x20pz\x20service\x20create\x20<name>\x20[parent_segment]\x0a'+'\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20service\x20create\x20<name>\x20\x20#\x20Uses\x20context'),0x1;const _0x4686c2=await withSpinner(_0x45389b(0x245)+_0x436f10+_0x45389b(0x288),()=>_0x184e47['segment'][_0x45389b(0x251)](_0x436f10),{'verbose':_0x45cd34[_0x45389b(0x387)]}),_0x7989e0=_0x4686c2[_0x45389b(0x1ad)],_0x92f1b6={'name':_0x4b01ca,'description':_0x44aa8f[_0x45389b(0x297)],'public':_0x44aa8f['public']},_0x46c262=await withSpinner(_0x45389b(0x302)+_0x4b01ca+_0x45389b(0x288),()=>_0x184e47[_0x45389b(0x324)][_0x45389b(0x227)](_0x7989e0,_0x92f1b6),{'verbose':_0x45cd34[_0x45389b(0x387)]}),_0x3d34dd=_0x46c262[_0x45389b(0x1ad)];return console[_0x45389b(0x3bd)]('✔\x20Created\x20personalization\x20service\x20\x27'+_0x3d34dd[_0x45389b(0x37d)]+_0x45389b(0x1c6)+_0x3d34dd['id']),await handleSDKOutput([_0x3d34dd],_0x45cd34),0x0;}}export class PSPzServiceShowCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]='ps:pz:service:show';[a32_0x3c5e89(0x297)]=a32_0x3c5e89(0x1fa);async['execute'](_0x3710ca){const _0x5d137c=a32_0x3c5e89,{options:_0x1f780e,args:_0x492bc7,tdx:_0x537ab3}=_0x3710ca,_0x2d132c=_0x492bc7[0x0],_0x24ad06=_0x492bc7[0x1]||_0x1f780e[_0x5d137c(0x1bc)];if(!_0x2d132c)return console['error'](_0x5d137c(0x1a2)),console['error'](_0x5d137c(0x362)),console[_0x5d137c(0x3bd)](_0x5d137c(0x27c)),0x1;if(!_0x24ad06)return showParentSegmentNotSetError(_0x5d137c(0x2c6)+_0x5d137c(0x27c)),0x1;const _0xd049a4=await withSpinner(_0x5d137c(0x245)+_0x24ad06+'\x27...',()=>_0x537ab3[_0x5d137c(0x1f3)][_0x5d137c(0x251)](_0x24ad06),{'verbose':_0x1f780e[_0x5d137c(0x387)]}),_0x209346=_0xd049a4[_0x5d137c(0x1ad)],_0x42e205=await withSpinner(_0x5d137c(0x204)+_0x2d132c+_0x5d137c(0x288),()=>_0x537ab3[_0x5d137c(0x324)][_0x5d137c(0x217)](_0x209346,_0x2d132c),{'verbose':_0x1f780e[_0x5d137c(0x387)]}),_0x4cb5e8=_0x42e205[_0x5d137c(0x1ad)];if(_0x1f780e[_0x5d137c(0x2e5)]||_0x1f780e[_0x5d137c(0x1ae)])await handleSDKOutput([_0x4cb5e8],_0x1f780e);else{console[_0x5d137c(0x2c0)](a32_0x54ffbd[_0x5d137c(0x1be)](_0x4cb5e8[_0x5d137c(0x37d)])+'\x20'+a32_0x54ffbd[_0x5d137c(0x2f6)](_0x5d137c(0x1e0)+_0x4cb5e8['id']+')'));_0x4cb5e8['description']&&console[_0x5d137c(0x2c0)]('\x20\x20'+a32_0x54ffbd[_0x5d137c(0x2f6)](_0x4cb5e8[_0x5d137c(0x297)]));console['log']('\x20\x20'+a32_0x54ffbd[_0x5d137c(0x30f)]('public:')+'\x20'+(_0x4cb5e8[_0x5d137c(0x326)]?_0x5d137c(0x3ab):'no'));if(_0x4cb5e8[_0x5d137c(0x32a)]&&_0x4cb5e8['tokens'][_0x5d137c(0x30a)]>0x0)for(const _0x2ff116 of _0x4cb5e8[_0x5d137c(0x32a)]){const _0x46024a=_0x2ff116[_0x5d137c(0x2f1)]?.['length']?_0x2ff116[_0x5d137c(0x2f1)][_0x5d137c(0x296)](',\x20'):'any';console['log']('\x20\x20'+a32_0x54ffbd[_0x5d137c(0x30f)](_0x5d137c(0x30c))+'\x20'+_0x2ff116[_0x5d137c(0x37d)]+'\x20'+a32_0x54ffbd['dim'](_0x5d137c(0x1e0)+_0x2ff116['id']+')')),console[_0x5d137c(0x2c0)]('\x20\x20\x20\x20'+a32_0x54ffbd[_0x5d137c(0x2f6)](_0x5d137c(0x353))+'\x20'+_0x46024a);}else console[_0x5d137c(0x2c0)]('\x20\x20'+a32_0x54ffbd[_0x5d137c(0x2f6)](_0x5d137c(0x21c)));}return 0x0;}}export class PSPzServiceDeleteCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]='ps:pz:service:delete';[a32_0x3c5e89(0x297)]='Delete\x20a\x20personalization\x20service';async['execute'](_0x5a54c3){const _0x2cca09=a32_0x3c5e89,{options:_0x372741,args:_0x42ae54,tdx:_0x28747a}=_0x5a54c3,_0x4c18b8=_0x42ae54[0x0],_0xd532ec=_0x42ae54[0x1]||_0x372741[_0x2cca09(0x1bc)];if(!_0x4c18b8)return console[_0x2cca09(0x3bd)]('Error:\x20Service\x20ID\x20is\x20required'),console['error']('Usage:\x20tdx\x20ps\x20pz\x20service\x20delete\x20<service_id>\x20[parent_segment]'),console['error'](_0x2cca09(0x368)),0x1;if(!_0xd532ec)return showParentSegmentNotSetError('Usage:\x20tdx\x20ps\x20pz\x20service\x20delete\x20<service_id>\x20[parent_segment]\x0a'+_0x2cca09(0x368)),0x1;const _0x364669=await withSpinner(_0x2cca09(0x245)+_0xd532ec+_0x2cca09(0x288),()=>_0x28747a[_0x2cca09(0x1f3)][_0x2cca09(0x251)](_0xd532ec),{'verbose':_0x372741[_0x2cca09(0x387)]}),_0x2cb6ee=_0x364669[_0x2cca09(0x1ad)];return await withSpinner('Deleting\x20personalization\x20service\x20\x27'+_0x4c18b8+'\x27...',()=>_0x28747a[_0x2cca09(0x324)][_0x2cca09(0x1ee)](_0x2cb6ee,_0x4c18b8),{'verbose':_0x372741[_0x2cca09(0x387)]}),console['error'](_0x2cca09(0x215)+_0x4c18b8+'\x27'),0x0;}}export class PSPzServiceUpdateCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]='ps:pz:service:update';[a32_0x3c5e89(0x297)]=a32_0x3c5e89(0x321);async[a32_0x3c5e89(0x2ce)](_0x7173d4){const _0x252872=a32_0x3c5e89,{options:_0x1c54e1,args:_0x131922,tdx:_0x5e6b86}=_0x7173d4,_0x572993=_0x1c54e1,_0xdc19a3=_0x131922[0x0],_0x1e2572=_0x131922[0x1]||_0x1c54e1['parentSegment'];if(!_0xdc19a3)return console[_0x252872(0x3bd)](_0x252872(0x1a2)),console[_0x252872(0x3bd)](_0x252872(0x372)),console[_0x252872(0x3bd)](_0x252872(0x1ef)),0x1;if(!_0x572993[_0x252872(0x37d)])return console['error'](_0x252872(0x36c)),console['error']('Usage:\x20tdx\x20ps\x20pz\x20service\x20update\x20<service_id>\x20[parent_segment]\x20--name\x20<name>\x20[--description\x20<text>]'),0x1;if(!_0x1e2572)return showParentSegmentNotSetError(_0x252872(0x21e)+_0x252872(0x1ef)),0x1;const _0x27b455=await withSpinner(_0x252872(0x245)+_0x1e2572+'\x27...',()=>_0x5e6b86[_0x252872(0x1f3)]['resolveParentId'](_0x1e2572),{'verbose':_0x1c54e1[_0x252872(0x387)]}),_0x1e00ef=_0x27b455[_0x252872(0x1ad)],_0x3c0667={'name':_0x572993['name']};_0x572993[_0x252872(0x297)]!==undefined&&(_0x3c0667[_0x252872(0x297)]=_0x572993['description']);const _0x197876=await withSpinner(_0x252872(0x2da)+_0xdc19a3+_0x252872(0x288),()=>_0x5e6b86['personalization'][_0x252872(0x33d)](_0x1e00ef,_0xdc19a3,_0x3c0667),{'verbose':_0x1c54e1[_0x252872(0x387)]}),_0x573dfe=_0x197876[_0x252872(0x1ad)];return console[_0x252872(0x3bd)](_0x252872(0x1e5)+_0x573dfe[_0x252872(0x37d)]+'\x27'),await handleSDKOutput([_0x573dfe],_0x1c54e1),0x0;}}export class PSPzServiceTokenCreateCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]=a32_0x3c5e89(0x337);[a32_0x3c5e89(0x297)]='Create\x20a\x20token\x20for\x20a\x20personalization\x20service';async[a32_0x3c5e89(0x2ce)](_0x26f5af){const _0x48cf7d=a32_0x3c5e89,{options:_0x246cd7,args:_0x28eb0e,tdx:_0x41c3d9}=_0x26f5af,_0x1f177c=_0x246cd7,_0x527fc0=_0x28eb0e[0x0],_0x4f9f7e=_0x28eb0e[0x1],_0x5a92d8=_0x28eb0e[0x2]||_0x246cd7[_0x48cf7d(0x1bc)];if(!_0x527fc0)return console['error'](_0x48cf7d(0x2be)),console['error']('Usage:\x20tdx\x20ps\x20pz\x20service\x20token\x20create\x20<name>\x20<service_id>\x20[parent_segment]'),console[_0x48cf7d(0x3bd)]('\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20service\x20token\x20create\x20<name>\x20<service_id>\x20\x20#\x20Uses\x20context'),0x1;if(!_0x4f9f7e)return console['error'](_0x48cf7d(0x1a2)),console[_0x48cf7d(0x3bd)](_0x48cf7d(0x293)),console[_0x48cf7d(0x3bd)](_0x48cf7d(0x376)),0x1;if(!_0x5a92d8)return showParentSegmentNotSetError(_0x48cf7d(0x2c8)+_0x48cf7d(0x376)),0x1;const _0x2e8d2a=await withSpinner(_0x48cf7d(0x245)+_0x5a92d8+_0x48cf7d(0x288),()=>_0x41c3d9[_0x48cf7d(0x1f3)][_0x48cf7d(0x251)](_0x5a92d8),{'verbose':_0x246cd7['verbose']}),_0x53a975=_0x2e8d2a['data'],_0xc150cb={'name':_0x527fc0};_0x1f177c[_0x48cf7d(0x2f1)]&&(_0xc150cb['allowedIps']=_0x1f177c[_0x48cf7d(0x2f1)][_0x48cf7d(0x3ad)](',')['map'](_0x2c9c81=>_0x2c9c81[_0x48cf7d(0x232)]()));_0x1f177c[_0x48cf7d(0x297)]&&(_0xc150cb[_0x48cf7d(0x297)]=_0x1f177c[_0x48cf7d(0x297)]);const _0x3080e0=await withSpinner(_0x48cf7d(0x23a)+_0x527fc0+_0x48cf7d(0x2ad)+_0x4f9f7e+_0x48cf7d(0x288),()=>_0x41c3d9[_0x48cf7d(0x324)][_0x48cf7d(0x289)](_0x53a975,_0x4f9f7e,_0xc150cb),{'verbose':_0x246cd7[_0x48cf7d(0x387)]}),_0x2c35a5=_0x3080e0[_0x48cf7d(0x1ad)];return console[_0x48cf7d(0x3bd)](_0x48cf7d(0x2a2)+_0x2c35a5[_0x48cf7d(0x37d)]+_0x48cf7d(0x1c6)+_0x2c35a5['id']),_0x2c35a5[_0x48cf7d(0x238)]&&(console['error'](a32_0x54ffbd[_0x48cf7d(0x24d)](_0x48cf7d(0x229))),console['error'](a32_0x54ffbd[_0x48cf7d(0x30f)](_0x2c35a5['value'])),console[_0x48cf7d(0x3bd)]('')),await handleSDKOutput([_0x2c35a5],_0x246cd7),0x0;}}export class PSPzServiceTokenDeleteCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]=a32_0x3c5e89(0x37c);[a32_0x3c5e89(0x297)]='Delete\x20a\x20token\x20from\x20a\x20personalization\x20service';async[a32_0x3c5e89(0x2ce)](_0x5e7dcf){const _0x584538=a32_0x3c5e89,{options:_0xb04776,args:_0x326fd8,tdx:_0x54de37}=_0x5e7dcf,_0x1c6b33=_0x326fd8[0x0],_0x309f47=_0x326fd8[0x1]||_0xb04776[_0x584538(0x1bc)];if(!_0x1c6b33)return console[_0x584538(0x3bd)](_0x584538(0x33b)),console[_0x584538(0x3bd)]('Usage:\x20tdx\x20ps\x20pz\x20service\x20token\x20delete\x20<token_id>\x20[parent_segment]'),console['error'](_0x584538(0x341)),0x1;if(!_0x309f47)return showParentSegmentNotSetError(_0x584538(0x23f)+_0x584538(0x341)),0x1;const _0x3611be=await withSpinner(_0x584538(0x245)+_0x309f47+_0x584538(0x288),()=>_0x54de37[_0x584538(0x1f3)][_0x584538(0x251)](_0x309f47),{'verbose':_0xb04776[_0x584538(0x387)]}),_0x184756=_0x3611be[_0x584538(0x1ad)],_0x3b3e10=await withSpinner(_0x584538(0x330),()=>_0x54de37[_0x584538(0x324)][_0x584538(0x374)](_0x184756),{'verbose':_0xb04776['verbose']}),_0x4b712b=_0x3b3e10['data'];let _0x3ff25b;for(const _0x4fe206 of _0x4b712b){if(_0x4fe206[_0x584538(0x32a)]?.[_0x584538(0x260)](_0x40f16d=>_0x40f16d['id']===_0x1c6b33)){_0x3ff25b=_0x4fe206['id'];break;}}if(!_0x3ff25b)return console['error'](_0x584538(0x2e2)+_0x1c6b33+_0x584538(0x39d)),0x1;const _0x44585e=await withSpinner(_0x584538(0x303)+_0x1c6b33+_0x584538(0x288),()=>_0x54de37['personalization'][_0x584538(0x1ab)](_0x184756,_0x3ff25b,_0x1c6b33),{'verbose':_0xb04776[_0x584538(0x387)]}),_0x383d8b=_0x44585e['data'];return console['error'](_0x584538(0x268)+(_0x383d8b['name']||_0x1c6b33)+'\x27'),await handleSDKOutput([_0x383d8b],_0xb04776),0x0;}}export class PSPzListCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]=a32_0x3c5e89(0x263);[a32_0x3c5e89(0x297)]=a32_0x3c5e89(0x3af);async['execute'](_0x351559){const _0x5dca88=a32_0x3c5e89,{options:_0x3f2a85,args:_0x54749b,tdx:_0xe3ed53}=_0x351559,_0x331914=_0x54749b[0x0]||_0x3f2a85[_0x5dca88(0x1bc)];if(!_0x331914)return showParentSegmentNotSetError(_0x5dca88(0x384)+_0x5dca88(0x24b)),0x1;const _0x12592d=await withSpinner(_0x5dca88(0x245)+_0x331914+_0x5dca88(0x288),()=>_0xe3ed53['segment'][_0x5dca88(0x251)](_0x331914),{'verbose':_0x3f2a85[_0x5dca88(0x387)]}),_0xd2f1d=_0x12592d[_0x5dca88(0x1ad)],_0x296909=await withSpinner(_0x5dca88(0x2a3)+_0x331914+_0x5dca88(0x288),()=>_0xe3ed53['personalization']['listPersonalizations'](_0xd2f1d),{'verbose':_0x3f2a85['verbose']}),_0x5631ed=_0x296909[_0x5dca88(0x1ad)];console[_0x5dca88(0x3bd)](_0x5dca88(0x38d)+_0x5631ed[_0x5dca88(0x30a)]+_0x5dca88(0x300)+(_0x5631ed[_0x5dca88(0x30a)]!==0x1?'s':''));if(_0x3f2a85[_0x5dca88(0x3b3)]===_0x5dca88(0x2e5)||_0x3f2a85[_0x5dca88(0x3b3)]===_0x5dca88(0x1ae))await handleSDKOutput(_0x5631ed,_0x3f2a85);else{if(_0x5631ed[_0x5dca88(0x30a)]===0x0)console[_0x5dca88(0x2c0)](_0x5dca88(0x1f4));else for(const _0xbfbf4e of _0x5631ed){console[_0x5dca88(0x2c0)](a32_0x54ffbd[_0x5dca88(0x1be)](_0xbfbf4e[_0x5dca88(0x37d)])+'\x20'+a32_0x54ffbd[_0x5dca88(0x2f6)](_0x5dca88(0x1e0)+_0xbfbf4e['id']+')'));_0xbfbf4e['description']&&console[_0x5dca88(0x2c0)]('\x20\x20'+a32_0x54ffbd['dim'](_0xbfbf4e[_0x5dca88(0x297)]));const _0x1336cb=_0xbfbf4e['sections']?.['length']||0x0;console['log']('\x20\x20'+a32_0x54ffbd[_0x5dca88(0x30f)](_0x5dca88(0x266))+'\x20'+_0x1336cb);if(_0xbfbf4e[_0x5dca88(0x25c)]&&_0xbfbf4e[_0x5dca88(0x25c)][_0x5dca88(0x30a)]>0x0)for(const _0xfd7045 of _0xbfbf4e[_0x5dca88(0x25c)]){console[_0x5dca88(0x2c0)]('\x20\x20\x20\x20-\x20'+_0xfd7045[_0x5dca88(0x37d)]);}}}return 0x0;}}export class PSPzShowCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]=a32_0x3c5e89(0x234);[a32_0x3c5e89(0x297)]='Show\x20a\x20specific\x20realtime\x20personalization';async[a32_0x3c5e89(0x2ce)](_0x204b25){const _0x1ef2c3=a32_0x3c5e89,{options:_0x3adc34,args:_0x4fd611,tdx:_0x46ea32}=_0x204b25,_0x1aadee=_0x4fd611[0x0];if(!_0x1aadee)return console['error'](_0x1ef2c3(0x242)),console[_0x1ef2c3(0x3bd)](_0x1ef2c3(0x331)),0x1;const _0x4d2792=await withSpinner(_0x1ef2c3(0x252)+_0x1aadee+'\x27...',()=>_0x46ea32[_0x1ef2c3(0x324)][_0x1ef2c3(0x320)](_0x1aadee),{'verbose':_0x3adc34['verbose']}),_0x3fbf32=_0x4d2792[_0x1ef2c3(0x1ad)];console['error'](_0x1ef2c3(0x246)+_0x3fbf32[_0x1ef2c3(0x37d)]+'\x27');if(_0x3adc34[_0x1ef2c3(0x3b3)]===_0x1ef2c3(0x2e5)||_0x3adc34[_0x1ef2c3(0x3b3)]==='jsonl')await handleSDKOutput([_0x3fbf32],_0x3adc34);else{console[_0x1ef2c3(0x2c0)](a32_0x54ffbd[_0x1ef2c3(0x1be)](_0x3fbf32['name'])+'\x20'+a32_0x54ffbd[_0x1ef2c3(0x2f6)]('(id:\x20'+_0x3fbf32['id']+')'));_0x3fbf32[_0x1ef2c3(0x297)]&&console['log']('\x20\x20'+a32_0x54ffbd[_0x1ef2c3(0x2f6)](_0x3fbf32['description']));_0x3fbf32[_0x1ef2c3(0x319)]&&console[_0x1ef2c3(0x2c0)]('\x20\x20'+a32_0x54ffbd['cyan'](_0x1ef2c3(0x1c3))+'\x20'+_0x3fbf32[_0x1ef2c3(0x319)]);console['log']('\x20\x20'+a32_0x54ffbd['cyan'](_0x1ef2c3(0x322))+'\x20'+_0x3fbf32['createdAt']),console[_0x1ef2c3(0x2c0)]('\x20\x20'+a32_0x54ffbd['cyan'](_0x1ef2c3(0x2de))+'\x20'+_0x3fbf32[_0x1ef2c3(0x311)]);const _0x526d03=_0x3fbf32[_0x1ef2c3(0x25c)]?.['length']||0x0;console[_0x1ef2c3(0x2c0)]('\x20\x20'+a32_0x54ffbd[_0x1ef2c3(0x30f)](_0x1ef2c3(0x266))+'\x20'+_0x526d03);if(_0x3fbf32['sections']&&_0x3fbf32[_0x1ef2c3(0x25c)][_0x1ef2c3(0x30a)]>0x0)for(const _0x104dc7 of _0x3fbf32[_0x1ef2c3(0x25c)]){console['log']('\x20\x20\x20\x20'+a32_0x54ffbd['bold'](_0x104dc7[_0x1ef2c3(0x37d)])+'\x20'+a32_0x54ffbd[_0x1ef2c3(0x2f6)](_0x1ef2c3(0x1e0)+_0x104dc7['id']+')')),_0x104dc7[_0x1ef2c3(0x209)]&&(console['log']('\x20\x20\x20\x20\x20\x20'+a32_0x54ffbd[_0x1ef2c3(0x30f)]('entryCriteria:')+'\x20'+_0x104dc7['entryCriteria'][_0x1ef2c3(0x37d)]),_0x104dc7[_0x1ef2c3(0x209)]['keyEventCriteria']?.[_0x1ef2c3(0x318)]&&console[_0x1ef2c3(0x2c0)](_0x1ef2c3(0x393)+a32_0x54ffbd[_0x1ef2c3(0x30f)](_0x1ef2c3(0x345))+'\x20'+_0x104dc7[_0x1ef2c3(0x209)][_0x1ef2c3(0x2e4)][_0x1ef2c3(0x318)])),_0x104dc7['payload']&&console['log'](_0x1ef2c3(0x1de)+a32_0x54ffbd['cyan'](_0x1ef2c3(0x2ba))+'\x20'+JSON[_0x1ef2c3(0x270)](_0x104dc7[_0x1ef2c3(0x2e9)])),_0x104dc7[_0x1ef2c3(0x253)]&&console[_0x1ef2c3(0x2c0)](_0x1ef2c3(0x1de)+a32_0x54ffbd[_0x1ef2c3(0x30f)](_0x1ef2c3(0x235))+_0x1ef2c3(0x3ae));}}return 0x0;}}export class PSPzDeleteCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]=a32_0x3c5e89(0x35d);['description']=a32_0x3c5e89(0x1a6);async[a32_0x3c5e89(0x2ce)](_0x507f79){const _0xdce1b3=a32_0x3c5e89,{options:_0x21df58,args:_0x33390f,tdx:_0x4d545f}=_0x507f79,_0x34a8d7=_0x33390f[0x0];if(!_0x34a8d7)return console[_0xdce1b3(0x3bd)](_0xdce1b3(0x242)),console[_0xdce1b3(0x3bd)]('Usage:\x20tdx\x20ps\x20pz\x20delete\x20<personalization_id>'),0x1;return await withSpinner(_0xdce1b3(0x1ea)+_0x34a8d7+'\x27...',()=>_0x4d545f[_0xdce1b3(0x324)][_0xdce1b3(0x2aa)](_0x34a8d7),{'verbose':_0x21df58[_0xdce1b3(0x387)]}),console['error'](_0xdce1b3(0x309)+_0x34a8d7+'\x27'),0x0;}}export class PSPzCreateCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]='ps:pz:create';[a32_0x3c5e89(0x297)]='Create\x20a\x20realtime\x20personalization\x20entity';async[a32_0x3c5e89(0x2ce)](_0x193e97){const _0x4a1f76=a32_0x3c5e89,{options:_0x5cdf8d,tdx:_0x4978f8}=_0x193e97,_0x61c01b=_0x5cdf8d;let _0x4a537d;if(_0x61c01b[_0x4a1f76(0x2d6)]){_0x4a537d=await loadJSON(_0x61c01b[_0x4a1f76(0x2d6)],!![]);if(!_0x4a537d['relationships']?.[_0x4a1f76(0x32f)])return console[_0x4a1f76(0x3bd)](_0x4a1f76(0x340)),console['error']('Use\x20`tdx\x20ps\x20folder\x20list\x20<name>`\x20to\x20find\x20the\x20folder\x20ID,\x20then\x20add:'),console[_0x4a1f76(0x3bd)](_0x4a1f76(0x26f)),0x1;}else{if(!_0x61c01b[_0x4a1f76(0x37d)])return console[_0x4a1f76(0x3bd)](_0x4a1f76(0x225)),console[_0x4a1f76(0x3bd)](_0x4a1f76(0x2ef)),console[_0x4a1f76(0x3bd)]('\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20create\x20--file\x20<path>'),0x1;if(_0x61c01b['description']===undefined)return console[_0x4a1f76(0x3bd)](_0x4a1f76(0x28c)),console[_0x4a1f76(0x3bd)](_0x4a1f76(0x2ef)),console[_0x4a1f76(0x3bd)](_0x4a1f76(0x2c4)),0x1;if(_0x61c01b[_0x4a1f76(0x1b9)]===undefined)return console[_0x4a1f76(0x3bd)]('Error:\x20--folder-id\x20is\x20required.\x20Use\x20`tdx\x20ps\x20folder\x20list\x20<name>`\x20to\x20find\x20the\x20folder\x20ID.'),console[_0x4a1f76(0x3bd)](_0x4a1f76(0x29d)),0x1;let _0x1a0eb0=_0x61c01b['audienceId'];if(!_0x1a0eb0&&_0x5cdf8d[_0x4a1f76(0x1bc)]){const _0xae8075=await withSpinner(_0x4a1f76(0x245)+_0x5cdf8d[_0x4a1f76(0x1bc)]+_0x4a1f76(0x288),()=>_0x4978f8[_0x4a1f76(0x1f3)][_0x4a1f76(0x251)](_0x5cdf8d[_0x4a1f76(0x1bc)]),{'verbose':_0x5cdf8d[_0x4a1f76(0x387)]});_0x1a0eb0=_0xae8075[_0x4a1f76(0x1ad)];}let _0x555e90;_0x61c01b[_0x4a1f76(0x25c)]&&(_0x555e90=await loadJSON(_0x61c01b[_0x4a1f76(0x25c)],![]));const _0x16967e=_0x61c01b[_0x4a1f76(0x1b9)]==='null'?null:{'id':_0x61c01b['folderId'],'type':'folder-segment'};_0x4a537d={'attributes':{'name':_0x61c01b[_0x4a1f76(0x37d)],'description':_0x61c01b['description']||null,..._0x1a0eb0!==undefined&&{'audienceId':_0x1a0eb0},..._0x555e90!==undefined&&{'sections':_0x555e90}},'relationships':{'parentFolder':{'data':_0x16967e}}};}const _0x1168a7=await withSpinner(_0x4a1f76(0x1cb)+(_0x4a537d[_0x4a1f76(0x370)]?.[_0x4a1f76(0x37d)]??'')+'\x27...',()=>_0x4978f8['personalization'][_0x4a1f76(0x2a9)](_0x4a537d),{'verbose':_0x5cdf8d[_0x4a1f76(0x387)]}),_0x294ab4=_0x1168a7['data'];return console['error'](_0x4a1f76(0x20c)+_0x294ab4[_0x4a1f76(0x37d)]+_0x4a1f76(0x1c6)+_0x294ab4['id']),await handleSDKOutput([_0x294ab4],_0x5cdf8d),0x0;}}export class PSPzPatchCommand extends BaseCommand{[a32_0x3c5e89(0x37d)]=a32_0x3c5e89(0x356);['description']='Update\x20a\x20realtime\x20personalization\x20entity';async[a32_0x3c5e89(0x2ce)](_0x4d5794){const _0x8440ea=a32_0x3c5e89,{options:_0x1963c0,args:_0x4b96cd}=_0x4d5794,_0x29b48e=_0x1963c0,_0x1a149f=_0x4b96cd[0x0];if(!_0x1a149f)return console[_0x8440ea(0x3bd)](_0x8440ea(0x242)),console['error'](_0x8440ea(0x29a)),console['error'](_0x8440ea(0x316)),0x1;let _0x275d5b;if(_0x29b48e[_0x8440ea(0x2d6)])_0x275d5b=await loadJSON(_0x29b48e[_0x8440ea(0x2d6)],!![]);else{if(!_0x29b48e[_0x8440ea(0x37d)])return console['error'](_0x8440ea(0x225)),console['error']('Usage:\x20tdx\x20ps\x20pz\x20patch\x20<id>\x20--name\x20<name>\x20--description\x20<desc>\x20[--sections\x20<json>]'),0x1;if(_0x29b48e[_0x8440ea(0x297)]===undefined)return console['error']('Error:\x20--description\x20is\x20required\x20(or\x20use\x20--file\x20for\x20a\x20full\x20request\x20body)'),console['error'](_0x8440ea(0x29a)),0x1;let _0x3db548;_0x29b48e[_0x8440ea(0x25c)]&&(_0x3db548=await loadJSON(_0x29b48e['sections'],![])),_0x275d5b={'attributes':{'name':_0x29b48e[_0x8440ea(0x37d)],'description':_0x29b48e[_0x8440ea(0x297)]||null,..._0x3db548!==undefined&&{'sections':_0x3db548}}};}const {tdx:_0x1b15b2}=_0x4d5794,_0x10a3ed=await withSpinner(_0x8440ea(0x291)+_0x1a149f+_0x8440ea(0x288),()=>_0x1b15b2[_0x8440ea(0x324)][_0x8440ea(0x38a)](_0x1a149f,_0x275d5b),{'verbose':_0x1963c0[_0x8440ea(0x387)]}),_0x36d3ff=_0x10a3ed[_0x8440ea(0x1ad)];return console[_0x8440ea(0x3bd)](_0x8440ea(0x304)+_0x36d3ff[_0x8440ea(0x37d)]+_0x8440ea(0x361)+_0x36d3ff['id']+')'),await handleSDKOutput([_0x36d3ff],_0x1963c0),0x0;}}export class PSPzInitCommand extends BaseParentSegmentCommand{['name']='ps:pz:init';[a32_0x3c5e89(0x297)]=a32_0x3c5e89(0x1e7);async[a32_0x3c5e89(0x2ce)](_0x58f6fb){const _0x2146aa=a32_0x3c5e89,{options:_0x2d9f72,args:_0x317240}=_0x58f6fb,_0xc630cd=_0x317240[0x0]||_0x2d9f72[_0x2146aa(0x1bc)];if(!_0xc630cd)return showParentSegmentNotSetError(_0x2146aa(0x24e)+_0x2146aa(0x1b0)),0x1;const _0x5ac602=resolveYamlFile(_0xc630cd);if(!existsSync(_0x5ac602))return showFileNotFoundError(_0x5ac602,_0xc630cd),0x1;let _0x2b708a;try{_0x2b708a=readFileSync(_0x5ac602,_0x2146aa(0x36a));}catch(_0x1f52af){const _0x246f25=_0x1f52af instanceof Error?_0x1f52af[_0x2146aa(0x2fe)]:String(_0x1f52af);return console[_0x2146aa(0x3bd)](_0x2146aa(0x37a)+_0x246f25),0x1;}let _0x3cdce4;try{_0x3cdce4=parseDef(_0x2b708a);}catch(_0x413aa0){const _0x1b0e5b=_0x413aa0 instanceof Error?_0x413aa0[_0x2146aa(0x2fe)]:String(_0x413aa0);return console[_0x2146aa(0x3bd)](a32_0x54ffbd[_0x2146aa(0x2cb)](_0x2146aa(0x2ab)+_0x1b0e5b)),0x1;}if(_0x3cdce4['personalization_services']&&_0x3cdce4[_0x2146aa(0x233)][_0x2146aa(0x30a)]>0x0)return console[_0x2146aa(0x3bd)](a32_0x54ffbd[_0x2146aa(0x24d)](_0x2146aa(0x2db)+_0x5ac602)),console[_0x2146aa(0x3bd)](a32_0x54ffbd['dim'](_0x2146aa(0x1d9)+_0x3cdce4['personalization_services'][_0x2146aa(0x30a)]+_0x2146aa(0x2e3))),0x1;!_0x3cdce4[_0x2146aa(0x1f1)]&&(_0x3cdce4[_0x2146aa(0x1f1)]={'events':[{'name':'page_view','source_table':_0x2146aa(0x1fb)}],'attributes':[{'name':_0x2146aa(0x2ed),'type':_0x2146aa(0x310)}],'id_stitching':{'primary_key':_0x3cdce4[_0x2146aa(0x1d3)][_0x2146aa(0x20a)]===_0x2146aa(0x1c0)?_0x2146aa(0x325):'user_id'}});_0x3cdce4[_0x2146aa(0x233)]=[{'name':_0x2146aa(0x2b0),'description':_0x2146aa(0x240),'trigger_event':_0x2146aa(0x342),'sections':[{'name':'Default','criteria':_0x2146aa(0x2d4),'attributes':[_0x2146aa(0x2ed)]}]}];const _0x33c751=serializeDef(_0x3cdce4);return writeFileSync(_0x5ac602,_0x33c751,_0x2146aa(0x36a)),console['error'](a32_0x54ffbd['green']('✔')+'\x20Added\x20personalization\x20template\x20to\x20'+a32_0x54ffbd[_0x2146aa(0x30f)](_0x5ac602)),(!_0x3cdce4[_0x2146aa(0x1f1)]||_0x2b708a[_0x2146aa(0x243)](_0x2146aa(0x33e))===-0x1)&&console[_0x2146aa(0x3bd)](a32_0x54ffbd[_0x2146aa(0x1d8)]('✔')+_0x2146aa(0x19e)),console[_0x2146aa(0x3bd)]('\x0a'+a32_0x54ffbd[_0x2146aa(0x2f6)](_0x2146aa(0x347))),console['error'](_0x2146aa(0x1f5)+_0x5ac602+_0x2146aa(0x315)),console['error'](_0x2146aa(0x373)+a32_0x54ffbd[_0x2146aa(0x2f6)](_0x2146aa(0x1a0)+_0xc630cd)+_0x2146aa(0x21a)),0x0;}}
|
|
1
|
+
const a32_0x462d84=a32_0x266e;(function(_0x49d475,_0x5f3aa1){const _0x2b1697=a32_0x266e,_0x587321=_0x49d475();while(!![]){try{const _0x458608=parseInt(_0x2b1697(0xc8))/0x1*(parseInt(_0x2b1697(0xcd))/0x2)+parseInt(_0x2b1697(0x1a2))/0x3*(-parseInt(_0x2b1697(0x266))/0x4)+parseInt(_0x2b1697(0x1e3))/0x5+parseInt(_0x2b1697(0x10e))/0x6*(parseInt(_0x2b1697(0x138))/0x7)+-parseInt(_0x2b1697(0x179))/0x8*(parseInt(_0x2b1697(0x1b7))/0x9)+parseInt(_0x2b1697(0x83))/0xa+-parseInt(_0x2b1697(0x208))/0xb;if(_0x458608===_0x5f3aa1)break;else _0x587321['push'](_0x587321['shift']());}catch(_0x32e323){_0x587321['push'](_0x587321['shift']());}}}(a32_0x43b6,0x3c13e));import{writeFileSync,readFileSync,existsSync,mkdirSync,renameSync,statSync}from'fs';import{spawn}from'child_process';import a32_0x5922c1 from'path';import{BaseCommand}from'./command.js';import{handleSDKOutput,handleQueryOutput,handleSingleObjectOutput,writeOutput}from'../core/command-output.js';import{withSpinner,withProgressSpinner,createCommandSpinner,formatElapsed}from'../utils/spinner.js';import{loadJSONFromOptions,loadJSON}from'../utils/json-loader.js';import{generateDiff,formatDiffWithColors,hasChanges}from'../utils/diff.js';import{getConsoleUrl,getConsoleNextUrl}from'../sdk/client/endpoints.js';import{formatRows,formatAsTable,hyperlink}from'../sdk/util/formatters.js';import{parseDef,serializeDef}from'../sdk/segment/parent-segment-yaml.js';import{confirmKey,isInteractive}from'../utils/prompt.js';import{DEFAULT_DISPLAY_LIMIT,resolveLimit}from'../core/constants.js';import a32_0x10437a from'chalk';import{displayFieldsHumanReadable,executeSchemaQuery}from'../sdk/segment/fields-display.js';import{saveSessionContext}from'../core/session.js';import{sanitizeFileName}from'../utils/string-utils.js';const PARENT_SEGMENT_DIR=a32_0x462d84(0x258),LEGACY_PARENT_SEGMENT_DIR=a32_0x462d84(0x160);function openBrowser(_0x5805ff){const _0x3eb6ef=a32_0x462d84,_0x38430d=process[_0x3eb6ef(0xa3)],_0x36c690=_0x38430d===_0x3eb6ef(0x8a)?_0x3eb6ef(0x14e):_0x38430d===_0x3eb6ef(0x21c)?_0x3eb6ef(0x1c9):_0x3eb6ef(0xd2);spawn(_0x36c690,[_0x5805ff],{'detached':!![],'stdio':_0x3eb6ef(0x1c5)})[_0x3eb6ef(0x243)]();}function migrateLegacyDirectory(){const _0x3475fd=a32_0x462d84;if(!existsSync(LEGACY_PARENT_SEGMENT_DIR))return![];const _0x2558f7=statSync(LEGACY_PARENT_SEGMENT_DIR);if(!_0x2558f7[_0x3475fd(0xa7)]())return![];if(existsSync(PARENT_SEGMENT_DIR))return console['error'](a32_0x10437a[_0x3475fd(0x94)](_0x3475fd(0x110)+LEGACY_PARENT_SEGMENT_DIR+_0x3475fd(0x13c)+PARENT_SEGMENT_DIR+_0x3475fd(0x23f))),console[_0x3475fd(0x17d)](a32_0x10437a[_0x3475fd(0x247)]('\x20\x20\x20Please\x20manually\x20merge\x20or\x20remove\x20'+LEGACY_PARENT_SEGMENT_DIR+_0x3475fd(0x11a))),![];console[_0x3475fd(0x17d)](a32_0x10437a[_0x3475fd(0x94)](_0x3475fd(0x1d0)+LEGACY_PARENT_SEGMENT_DIR+_0x3475fd(0x1eb)+PARENT_SEGMENT_DIR+'/\x0a'));try{return renameSync(LEGACY_PARENT_SEGMENT_DIR,PARENT_SEGMENT_DIR),console[_0x3475fd(0x17d)](a32_0x10437a[_0x3475fd(0x96)](_0x3475fd(0x147)+PARENT_SEGMENT_DIR+'/\x0a')),!![];}catch(_0x30ad56){const _0x19d466=_0x30ad56 instanceof Error?_0x30ad56[_0x3475fd(0x184)]:String(_0x30ad56);return console[_0x3475fd(0x17d)](a32_0x10437a['red'](_0x3475fd(0x1c2)+_0x19d466+'\x0a')),![];}}function a32_0x266e(_0x2a6e7a,_0x1cbe5d){_0x2a6e7a=_0x2a6e7a-0x6f;const _0x43b6fb=a32_0x43b6();let _0x266e4c=_0x43b6fb[_0x2a6e7a];return _0x266e4c;}class BaseParentSegmentCommand extends BaseCommand{async[a32_0x462d84(0x167)](_0x4ded45){const _0x43be2f=a32_0x462d84;return migrateLegacyDirectory(),super[_0x43be2f(0x167)](_0x4ded45);}}function resolveYamlFile(_0x2ded10){const _0x1a52b9=a32_0x462d84;if(_0x2ded10['endsWith'](_0x1a52b9(0x275))||_0x2ded10[_0x1a52b9(0x212)](_0x1a52b9(0x18d)))return _0x2ded10;return a32_0x5922c1[_0x1a52b9(0x1bb)](PARENT_SEGMENT_DIR,sanitizeFileName(_0x2ded10)+'.yml');}function formatProgressMessage(_0x87a024){const _0x21d0a5=a32_0x462d84,_0x2b35f8=_0x87a024[_0x21d0a5(0x178)](/^(.+?):\s*(.+?)(\s*\(.+\))?$/);if(_0x2b35f8){const [,_0x545ce4,_0x43de92,_0x154f25='']=_0x2b35f8;return a32_0x10437a[_0x21d0a5(0x247)](_0x545ce4+':')+'\x20'+_0x43de92+a32_0x10437a[_0x21d0a5(0x247)](_0x154f25);}return a32_0x10437a['dim'](_0x87a024);}function showFileNotFoundError(_0x28e740,_0xd44777){const _0xaabb65=a32_0x462d84;console[_0xaabb65(0x17d)](a32_0x10437a[_0xaabb65(0xbd)](_0xaabb65(0x274)+_0x28e740+'\x0a')),console[_0xaabb65(0x17d)](a32_0x10437a[_0xaabb65(0x276)]('Tip:\x20Run\x20`tdx\x20ps\x20pull\x20-u\x20'+_0xd44777+_0xaabb65(0x95)));}function displayRealtimeValidation(_0x2d2f57){const _0x2e7aef=a32_0x462d84;if(!_0x2d2f57[_0x2e7aef(0x231)])return;const _0x5be11d=_0x2d2f57[_0x2e7aef(0x231)],_0x454ea6=_0x5be11d['enabled']?a32_0x10437a['green'](_0x2e7aef(0x251)):a32_0x10437a['yellow'](_0x2e7aef(0x23d));console[_0x2e7aef(0x17d)]('\x0a'+a32_0x10437a[_0x2e7aef(0x247)]('RT\x202.0:')+'\x20'+_0x454ea6);if(_0x5be11d[_0x2e7aef(0xb1)]&&_0x5be11d['events'][_0x2e7aef(0x7b)]>0x0){console['error']('\x20\x20'+a32_0x10437a['dim']('Events:')+'\x20'+_0x5be11d[_0x2e7aef(0xb1)][_0x2e7aef(0x7b)]+'\x20configured');for(const _0x13d7db of _0x5be11d[_0x2e7aef(0xb1)]){const _0x5bed46=_0x13d7db['sourceTableValid']===![]?a32_0x10437a[_0x2e7aef(0xbd)]('✘'):a32_0x10437a['green']('✔');console[_0x2e7aef(0x17d)](_0x2e7aef(0x12b)+_0x5bed46+'\x20'+_0x13d7db['name']),_0x13d7db[_0x2e7aef(0xf0)]&&console['error']('\x20\x20\x20\x20\x20\x20'+a32_0x10437a[_0x2e7aef(0xbd)](_0x13d7db['sourceTableError']));}}if(_0x5be11d[_0x2e7aef(0x150)]&&_0x5be11d[_0x2e7aef(0x150)][_0x2e7aef(0x7b)]>0x0){console[_0x2e7aef(0x17d)]('\x20\x20'+a32_0x10437a['dim'](_0x2e7aef(0x1be))+'\x20'+_0x5be11d[_0x2e7aef(0x150)][_0x2e7aef(0x7b)]+_0x2e7aef(0x16b));for(const _0x23f5ec of _0x5be11d['attributes']){const _0x24f76c=_0x23f5ec[_0x2e7aef(0x10d)]?a32_0x10437a[_0x2e7aef(0x96)]('✔'):a32_0x10437a['red']('✘');console[_0x2e7aef(0x17d)]('\x20\x20\x20\x20'+_0x24f76c+'\x20'+_0x23f5ec['name']+'\x20'+a32_0x10437a['dim']('('+_0x23f5ec[_0x2e7aef(0x25d)]+')'));}}if(_0x5be11d[_0x2e7aef(0xff)]){const _0x2378ed=_0x5be11d[_0x2e7aef(0xff)][_0x2e7aef(0xd9)]?.['length']?_0x2e7aef(0xda)+_0x5be11d[_0x2e7aef(0xff)][_0x2e7aef(0xd9)][_0x2e7aef(0x1bb)](',\x20')+']':'';console[_0x2e7aef(0x17d)]('\x20\x20'+a32_0x10437a[_0x2e7aef(0x247)]('ID\x20Stitching:')+'\x20'+_0x5be11d[_0x2e7aef(0xff)][_0x2e7aef(0x18e)]+_0x2378ed);}if(_0x5be11d['personalizationServices']&&_0x5be11d[_0x2e7aef(0x246)][_0x2e7aef(0x7b)]>0x0){console['error']('\x20\x20'+a32_0x10437a[_0x2e7aef(0x247)](_0x2e7aef(0xe8))+'\x20'+_0x5be11d['personalizationServices'][_0x2e7aef(0x7b)]+_0x2e7aef(0x280)+(_0x5be11d['personalizationServices'][_0x2e7aef(0x7b)]!==0x1?'s':''));for(const _0x4abc33 of _0x5be11d['personalizationServices']){console['error'](_0x2e7aef(0xe4)+_0x4abc33[_0x2e7aef(0xf9)]);}}}function showParentSegmentNotSetError(_0x134159){const _0x717b10=a32_0x462d84;console['error'](a32_0x10437a[_0x717b10(0x94)](_0x717b10(0x1dd))),console[_0x717b10(0x17d)](_0x134159);}export class ParentSegmentListCommand extends BaseCommand{['name']=a32_0x462d84(0x1f9);[a32_0x462d84(0x19c)]=a32_0x462d84(0x102);async[a32_0x462d84(0x17f)](_0x23ec34){const _0x2db975=a32_0x462d84,{options:_0x5a7501,args:_0x14c99c,tdx:_0x5916b4}=_0x23ec34,_0x58f6da=_0x14c99c[0x0];_0x5a7501[_0x2db975(0x19e)]&&(console[_0x2db975(0x17d)]('Site:\x20'+_0x5a7501[_0x2db975(0xe6)]),_0x58f6da&&console[_0x2db975(0x17d)](_0x2db975(0x170)+_0x58f6da));const _0x165f86=await withSpinner(_0x58f6da?'Listing\x20parent\x20segments\x20matching\x20\x27'+_0x58f6da+_0x2db975(0x183):_0x2db975(0x1fc),()=>_0x5916b4[_0x2db975(0x139)][_0x2db975(0x18a)](),{'verbose':_0x5a7501[_0x2db975(0x19e)]});let _0x241192=_0x165f86[_0x2db975(0x12d)];if(_0x58f6da){const _0x3c8675=_0x58f6da['replace'](/[.+^${}()|[\]\\]/g,'\x5c$&')['replace'](/\*/g,'.*')[_0x2db975(0x228)](/\?/g,'.'),_0x203ed8=new RegExp('^'+_0x3c8675+'$','i');_0x241192=_0x241192['filter'](_0x177e98=>_0x203ed8[_0x2db975(0x198)](_0x177e98[_0x2db975(0x150)][_0x2db975(0xf9)]));}_0x241192[_0x2db975(0x19d)]((_0x3c4221,_0x2dbfd6)=>_0x3c4221[_0x2db975(0x150)][_0x2db975(0xf9)][_0x2db975(0x124)](_0x2dbfd6[_0x2db975(0x150)][_0x2db975(0xf9)])),console[_0x2db975(0x17d)](_0x2db975(0x105)+_0x241192[_0x2db975(0x7b)]+_0x2db975(0x227)+(_0x241192['length']!==0x1?'s':''));const _0x4b512f=_0x5dba9a=>{const _0x5cbbfb=_0x2db975;return getConsoleNextUrl(_0x5a7501['site'],_0x5cbbfb(0x1d1)+_0x5dba9a);};if(_0x5a7501['format']===_0x2db975(0x1ea)||_0x5a7501[_0x2db975(0x128)]===_0x2db975(0x262)){const _0x572200=_0x241192[_0x2db975(0xa5)](_0x50440d=>({..._0x50440d,'url':_0x4b512f(_0x50440d['id'])}));await handleSDKOutput(_0x572200,_0x5a7501);}else{if(_0x241192[_0x2db975(0x7b)]===0x0)_0x58f6da?console['log'](_0x2db975(0x173)+_0x58f6da):console[_0x2db975(0x195)](_0x2db975(0x1ed));else for(const _0x330b9e of _0x241192){const _0x555193=_0x330b9e[_0x2db975(0x150)][_0x2db975(0x1d7)]?a32_0x10437a[_0x2db975(0x247)]('\x20('+formatRows(_0x330b9e['attributes'][_0x2db975(0x1d7)])+')'):'',_0x458b7a=hyperlink(_0x330b9e[_0x2db975(0x150)][_0x2db975(0xf9)],_0x4b512f(_0x330b9e['id']));console[_0x2db975(0x195)]('👥\x20'+_0x458b7a+_0x555193);}}return 0x0;}}export class ParentSegmentCreateCommand extends BaseCommand{['name']='segment:parent:create';[a32_0x462d84(0x19c)]=a32_0x462d84(0x16a);async[a32_0x462d84(0x17f)](_0x41b8f3){const _0x4fd69f=a32_0x462d84,{options:_0x4c9e88,args:_0x583dc6,tdx:_0x29cc04}=_0x41b8f3;console[_0x4fd69f(0x17d)](_0x4fd69f(0x177)+_0x4fd69f(0x260)+_0x4fd69f(0x131));const _0x2b85ad=_0x4c9e88;if(_0x583dc6[_0x4fd69f(0x7b)]===0x0)return console[_0x4fd69f(0x17d)](a32_0x10437a[_0x4fd69f(0xbd)](_0x4fd69f(0x16e))),console[_0x4fd69f(0x17d)](_0x4fd69f(0x127)),0x1;const _0x2f3dc0=_0x583dc6[0x0];if(!_0x2b85ad[_0x4fd69f(0x162)]||!_0x2b85ad['table'])return console[_0x4fd69f(0x17d)](_0x4fd69f(0xdc)),console['error'](_0x4fd69f(0x127)),0x1;_0x2b85ad[_0x4fd69f(0x19e)]&&(console['error']('Site:\x20'+_0x2b85ad['site']),console[_0x4fd69f(0x17d)](_0x4fd69f(0x1f6)+_0x2f3dc0),console[_0x4fd69f(0x17d)](_0x4fd69f(0x214)+_0x2b85ad[_0x4fd69f(0x162)]),console[_0x4fd69f(0x17d)]('Table:\x20'+_0x2b85ad[_0x4fd69f(0x217)]));const _0x5d4bdc=await loadJSONFromOptions(_0x2b85ad[_0x4fd69f(0x150)],_0x2b85ad[_0x4fd69f(0x180)]),_0x5dc118=await loadJSONFromOptions(_0x2b85ad[_0x4fd69f(0xde)],_0x2b85ad['behaviorsFile']),_0x3a093d=await loadJSONFromOptions(_0x2b85ad[_0x4fd69f(0x20b)],_0x2b85ad['customerGroupFile']),_0x3147bd={'name':_0x2f3dc0,'description':_0x2b85ad[_0x4fd69f(0x19c)],'scheduleType':_0x2b85ad[_0x4fd69f(0x76)],'scheduleOption':_0x2b85ad[_0x4fd69f(0x237)],'timezone':_0x2b85ad[_0x4fd69f(0x13f)],'master':{'parentDatabaseName':_0x2b85ad[_0x4fd69f(0x162)],'parentTableName':_0x2b85ad['table']},'attributes':_0x5d4bdc,'behaviors':_0x5dc118,'customerGroup':_0x3a093d},_0xf22134=await withSpinner(_0x4fd69f(0x172)+_0x2f3dc0+_0x4fd69f(0x183),()=>_0x29cc04[_0x4fd69f(0x139)][_0x4fd69f(0x1b5)](_0x3147bd),{'verbose':_0x4c9e88['verbose']}),_0x37e9de=_0xf22134[_0x4fd69f(0x12d)];return console[_0x4fd69f(0x17d)](_0x4fd69f(0x141)+_0x37e9de[_0x4fd69f(0xf9)]+_0x4fd69f(0x71)+_0x37e9de['id']),await handleSDKOutput([_0x37e9de],_0x4c9e88),0x0;}}export class ParentSegmentUpdateCommand extends BaseCommand{[a32_0x462d84(0xf9)]=a32_0x462d84(0x1ba);[a32_0x462d84(0x19c)]=a32_0x462d84(0xfd);async[a32_0x462d84(0x17f)](_0x131cd5){const _0x2a9c8c=a32_0x462d84,{options:_0x5465a9,args:_0x432d32,tdx:_0x1d3697}=_0x131cd5;console[_0x2a9c8c(0x17d)](_0x2a9c8c(0x1f3)+_0x2a9c8c(0x260)+'\x20\x20\x20See:\x20tdx\x20segment\x20parent\x20pull\x20--help\x0a');const _0x25e66f=_0x5465a9;if(_0x432d32['length']===0x0)return console[_0x2a9c8c(0x17d)](a32_0x10437a[_0x2a9c8c(0xbd)](_0x2a9c8c(0x16e))),console[_0x2a9c8c(0x17d)](_0x2a9c8c(0x1b6)),0x1;const _0x4f18b7=_0x432d32[0x0];_0x25e66f['verbose']&&(console[_0x2a9c8c(0x17d)](_0x2a9c8c(0x112)+_0x25e66f[_0x2a9c8c(0xe6)]),console[_0x2a9c8c(0x17d)](_0x2a9c8c(0x261)+_0x4f18b7));const _0x34af2c=await withSpinner('Fetching\x20current\x20configuration\x20for\x20\x27'+_0x4f18b7+_0x2a9c8c(0x183),()=>_0x1d3697['segment'][_0x2a9c8c(0x123)](_0x4f18b7),{'verbose':_0x25e66f[_0x2a9c8c(0x19e)]}),_0x504632=_0x34af2c[_0x2a9c8c(0x12d)],_0x8eccc9=await loadJSONFromOptions(_0x25e66f[_0x2a9c8c(0x26b)],_0x25e66f[_0x2a9c8c(0x24f)]),_0x3e6fce=await loadJSONFromOptions(_0x25e66f['addBehaviors'],_0x25e66f[_0x2a9c8c(0xa4)]),_0x4cbcae={'name':_0x504632['name'],'description':_0x25e66f[_0x2a9c8c(0x19c)]!==undefined?_0x25e66f[_0x2a9c8c(0x19c)]:_0x504632[_0x2a9c8c(0x19c)],'scheduleType':_0x25e66f[_0x2a9c8c(0x76)]!==undefined?_0x25e66f[_0x2a9c8c(0x76)]:_0x504632[_0x2a9c8c(0x76)],'scheduleOption':_0x25e66f[_0x2a9c8c(0x237)]!==undefined?_0x25e66f[_0x2a9c8c(0x237)]:_0x504632[_0x2a9c8c(0x237)],'timezone':_0x25e66f['timezone']!==undefined?_0x25e66f[_0x2a9c8c(0x13f)]:_0x504632[_0x2a9c8c(0x13f)],'master':_0x504632[_0x2a9c8c(0x109)],'attributes':_0x8eccc9?[..._0x504632['attributes']||[],..._0x8eccc9]:_0x504632[_0x2a9c8c(0x150)],'behaviors':_0x3e6fce?[..._0x504632[_0x2a9c8c(0xde)]||[],..._0x3e6fce]:_0x504632[_0x2a9c8c(0xde)],'customerGroup':_0x504632['customerGroup']},_0x1c4ce0=await withSpinner('Updating\x20parent\x20segment\x20\x27'+_0x4f18b7+'\x27...',()=>_0x1d3697[_0x2a9c8c(0x139)][_0x2a9c8c(0x26a)](_0x4f18b7,_0x4cbcae),{'verbose':_0x25e66f[_0x2a9c8c(0x19e)]}),_0x591553=_0x1c4ce0[_0x2a9c8c(0x12d)];return console['error'](_0x2a9c8c(0x7e)+_0x591553['name']+'\x27'),await handleSDKOutput([_0x591553],_0x25e66f),0x0;}}export class ParentSegmentPullCommand extends BaseParentSegmentCommand{[a32_0x462d84(0xf9)]=a32_0x462d84(0x24d);[a32_0x462d84(0x19c)]=a32_0x462d84(0x1ef);async[a32_0x462d84(0x17f)](_0x5e7fa0){const _0x57b1fb=a32_0x462d84,{options:_0x48b855,args:_0x93149e,tdx:_0x46f79d}=_0x5e7fa0,_0x38c414=_0x48b855,_0x35f32c=_0x93149e[0x0]||_0x48b855[_0x57b1fb(0xa2)];if(!_0x35f32c)return showParentSegmentNotSetError(_0x57b1fb(0xcf)+_0x57b1fb(0x103)),0x1;if(_0x38c414[_0x57b1fb(0x196)]&&_0x38c414['output'])return console[_0x57b1fb(0x17d)](a32_0x10437a[_0x57b1fb(0xbd)](_0x57b1fb(0x18c))),console[_0x57b1fb(0x17d)](a32_0x10437a['dim'](_0x57b1fb(0x27a))),console['error'](a32_0x10437a[_0x57b1fb(0x247)](_0x57b1fb(0x26d)+PARENT_SEGMENT_DIR+_0x57b1fb(0xfc))),console['error'](a32_0x10437a[_0x57b1fb(0x276)](_0x57b1fb(0xd3))),0x1;const _0x15e7a7=_0x38c414['output']||a32_0x5922c1[_0x57b1fb(0x1bb)](PARENT_SEGMENT_DIR,sanitizeFileName(_0x35f32c)+'.yml');_0x38c414[_0x57b1fb(0x19e)]&&(console[_0x57b1fb(0x17d)](_0x57b1fb(0x112)+_0x38c414[_0x57b1fb(0xe6)]),console['error'](_0x57b1fb(0x261)+_0x35f32c),console[_0x57b1fb(0x17d)](_0x57b1fb(0x104)+_0x15e7a7));const _0x5c9870=await withSpinner(_0x57b1fb(0x125)+_0x35f32c+_0x57b1fb(0x183),()=>_0x46f79d['segment'][_0x57b1fb(0x24e)](_0x35f32c),{'verbose':_0x38c414[_0x57b1fb(0x19e)]}),_0x3ac227=_0x5c9870['data'];if(existsSync(_0x15e7a7)){const _0x169a46=readFileSync(_0x15e7a7,_0x57b1fb(0x15f)),_0x1ab659=generateDiff(_0x169a46,_0x3ac227);if(!hasChanges(_0x1ab659))console[_0x57b1fb(0x17d)](a32_0x10437a['green']('✔')+'\x20No\x20changes\x20-\x20'+a32_0x10437a[_0x57b1fb(0x276)](_0x15e7a7)+_0x57b1fb(0xcb));else{console[_0x57b1fb(0x17d)](_0x57b1fb(0x152)+_0x15e7a7+'\x27:'),console['error']('─'[_0x57b1fb(0x148)](0x3c)),console['error'](formatDiffWithColors(_0x1ab659)),console[_0x57b1fb(0x17d)]('─'[_0x57b1fb(0x148)](0x3c));if(!_0x38c414[_0x57b1fb(0x19f)]){if(!isInteractive())return console[_0x57b1fb(0x17d)](a32_0x10437a[_0x57b1fb(0xbd)](_0x57b1fb(0x1dc)),'Confirmation\x20required\x20but\x20running\x20in\x20non-interactive\x20mode'),console[_0x57b1fb(0x17d)](a32_0x10437a[_0x57b1fb(0x247)](_0x57b1fb(0x14f))),0x1;const _0x396bf6=await confirmKey(_0x57b1fb(0x13d)+_0x15e7a7+'\x27?');if(!_0x396bf6)return console[_0x57b1fb(0x17d)](a32_0x10437a[_0x57b1fb(0x94)](_0x57b1fb(0x1ce))),0x1;}writeFileSync(_0x15e7a7,_0x3ac227,_0x57b1fb(0x15f)),console[_0x57b1fb(0x17d)](a32_0x10437a[_0x57b1fb(0x96)]('✔')+_0x57b1fb(0x8f)+a32_0x10437a[_0x57b1fb(0x276)](_0x15e7a7));}}else{const _0x542fc9=a32_0x5922c1[_0x57b1fb(0xc3)](_0x15e7a7);!existsSync(_0x542fc9)&&mkdirSync(_0x542fc9,{'recursive':!![]}),writeFileSync(_0x15e7a7,_0x3ac227,_0x57b1fb(0x15f)),console[_0x57b1fb(0x17d)](a32_0x10437a[_0x57b1fb(0x96)]('✔')+_0x57b1fb(0x8f)+a32_0x10437a[_0x57b1fb(0x276)](_0x15e7a7));}return saveSessionContext({'parent_segment':_0x35f32c},_0x38c414[_0x57b1fb(0x1bd)]),console[_0x57b1fb(0x17d)](a32_0x10437a[_0x57b1fb(0x96)]('✔')+_0x57b1fb(0x13e)+a32_0x10437a[_0x57b1fb(0x247)](_0x57b1fb(0x160))+'\x20=\x20'+a32_0x10437a['cyan'](_0x35f32c)),0x0;}}export class ParentSegmentPushCommand extends BaseParentSegmentCommand{[a32_0x462d84(0xf9)]='segment:parent:push';[a32_0x462d84(0x19c)]=a32_0x462d84(0x1fd);async[a32_0x462d84(0x17f)](_0xb8165d){const _0x1cb010=a32_0x462d84,{options:_0x5d0e11,args:_0x510af6,tdx:_0x275c5d}=_0xb8165d,_0x3052c5=_0x5d0e11,_0x509241=_0x510af6[0x0]||_0x5d0e11[_0x1cb010(0xa2)];if(!_0x509241)return showParentSegmentNotSetError(_0x1cb010(0x225)+_0x1cb010(0xf4)),0x1;const _0x4f6221=resolveYamlFile(_0x509241);if(!existsSync(_0x4f6221))return showFileNotFoundError(_0x4f6221,_0x509241),0x1;_0x3052c5[_0x1cb010(0x19e)]&&(console['error'](_0x1cb010(0x112)+_0x3052c5[_0x1cb010(0xe6)]),console['error'](_0x1cb010(0x245)+_0x4f6221));let _0x104cb1;try{_0x104cb1=readFileSync(_0x4f6221,_0x1cb010(0x15f));}catch(_0x32bdc1){const _0x434be7=_0x32bdc1 instanceof Error?_0x32bdc1['message']:String(_0x32bdc1);return console['error'](_0x1cb010(0x88)+_0x434be7),0x1;}const _0x3ff349=await withSpinner(_0x1cb010(0x1bc),()=>_0x275c5d[_0x1cb010(0x139)][_0x1cb010(0x25a)](_0x104cb1),{'verbose':_0x3052c5[_0x1cb010(0x19e)]}),_0x22d914=_0x3ff349['data'],{isNew:_0x159a13,name:_0x1f5545,hasChanges:_0x3a3de7,diffFormatted:_0x197587}=_0x22d914;if(!_0x3a3de7)return console['error'](_0x1cb010(0x19b)+_0x1f5545+'\x27\x20is\x20already\x20up\x20to\x20date'),0x0;_0x159a13?console[_0x1cb010(0x17d)]('\x0aNew\x20parent\x20segment\x20\x27'+_0x1f5545+'\x27:'):console[_0x1cb010(0x17d)]('\x0aChanges\x20to\x20apply\x20to\x20\x27'+_0x1f5545+'\x27:');console[_0x1cb010(0x17d)]('─'[_0x1cb010(0x148)](0x3c)),console[_0x1cb010(0x17d)](_0x197587),console[_0x1cb010(0x17d)]('─'['repeat'](0x3c));const _0x510ae6=_0x159a13?_0x1cb010(0xd6)+_0x1f5545+'\x27?':'Apply\x20changes\x20to\x20\x27'+_0x1f5545+'\x27?';if(!_0x3052c5[_0x1cb010(0x19f)]){if(!isInteractive())return console['error'](a32_0x10437a[_0x1cb010(0xbd)](_0x1cb010(0x1dc)),'Confirmation\x20required\x20but\x20running\x20in\x20non-interactive\x20mode'),console[_0x1cb010(0x17d)](a32_0x10437a[_0x1cb010(0x247)](_0x1cb010(0x14f))),0x1;const _0x5edbc7=await confirmKey(_0x510ae6);if(!_0x5edbc7)return console[_0x1cb010(0x17d)](a32_0x10437a[_0x1cb010(0x94)](_0x1cb010(0x1ce))),0x1;}const _0x486dfa=_0x159a13?_0x1cb010(0x1e5):_0x1cb010(0x27f),_0x3cd93a=await withSpinner(_0x486dfa+_0x1cb010(0xbc)+_0x1f5545+_0x1cb010(0x183),()=>_0x22d914[_0x1cb010(0x159)](),{'verbose':_0x3052c5[_0x1cb010(0x19e)]}),_0x520562=_0x3cd93a[_0x1cb010(0x12d)],_0x4027cc=getConsoleNextUrl(_0x3052c5[_0x1cb010(0xe6)],_0x1cb010(0x1d1)+_0x520562['id']),_0x176086=_0x159a13?'Created':_0x1cb010(0x169);return console['error']('✔\x20'+_0x176086+_0x1cb010(0xbc)+_0x520562['name']+'\x27'),console[_0x1cb010(0x17d)]('\x20\x20'+_0x4027cc),0x0;}}export class ParentSegmentValidateCommand extends BaseParentSegmentCommand{[a32_0x462d84(0xf9)]='segment:parent:validate';[a32_0x462d84(0x19c)]='Validate\x20parent\x20segment\x20YAML\x20configuration\x20and\x20show\x20statistics';async[a32_0x462d84(0x17f)](_0x2b4d2c){const _0x50a894=a32_0x462d84,{options:_0x4b495e,args:_0xda2200,tdx:_0x943d5}=_0x2b4d2c,_0x39c1fb=_0x4b495e,_0x5d2aae=_0xda2200[0x0]||_0x4b495e[_0x50a894(0xa2)];if(!_0x5d2aae)return showParentSegmentNotSetError(_0x50a894(0x226)+_0x50a894(0x239)+_0x50a894(0x89)+_0x50a894(0xe3)+_0x50a894(0x13a)+_0x50a894(0x9d)),0x1;const _0x19f698=resolveYamlFile(_0x5d2aae);if(!existsSync(_0x19f698))return showFileNotFoundError(_0x19f698,_0x5d2aae),0x1;_0x39c1fb[_0x50a894(0x19e)]&&(console[_0x50a894(0x17d)](_0x50a894(0x112)+_0x39c1fb[_0x50a894(0xe6)]),console['error'](_0x50a894(0x245)+_0x19f698));let _0x5f3d9d;try{_0x5f3d9d=readFileSync(_0x19f698,_0x50a894(0x15f));}catch(_0x44fa82){const _0x586ed6=_0x44fa82 instanceof Error?_0x44fa82[_0x50a894(0x184)]:String(_0x44fa82);return console['error']('Error\x20reading\x20file:\x20'+_0x586ed6),0x1;}const _0x4d4aa1=createCommandSpinner(a32_0x10437a[_0x50a894(0x247)]('Validating\x20configuration...'),{'verbose':_0x39c1fb['verbose']});_0x4d4aa1['start']();const _0x44ef66={'onProgress':_0x31d04e=>{const _0x59a0a7=_0x50a894;_0x4d4aa1[_0x59a0a7(0xe7)]=formatProgressMessage(_0x31d04e);}};if(_0x39c1fb[_0x50a894(0x109)])_0x44ef66[_0x50a894(0x109)]=!![];if(_0x39c1fb[_0x50a894(0x7c)])_0x44ef66[_0x50a894(0x7c)]=!![];_0x39c1fb[_0x50a894(0xa0)]&&(_0x44ef66[_0x50a894(0xa0)]=_0x39c1fb[_0x50a894(0xa0)]);_0x39c1fb['behavior']&&(_0x44ef66[_0x50a894(0x129)]=_0x39c1fb['behavior']);if(_0x39c1fb[_0x50a894(0x9f)])_0x44ef66['interval']=_0x39c1fb[_0x50a894(0x9f)];let _0x552ee9;try{_0x552ee9=await _0x943d5['segment'][_0x50a894(0x10c)](_0x5f3d9d,_0x44ef66),_0x4d4aa1[_0x50a894(0x26c)]();}catch(_0x2684b9){_0x4d4aa1[_0x50a894(0x26c)]();throw _0x2684b9;}const _0x13a4ed=_0x39c1fb['interval']||_0x50a894(0x201);return this['displayValidateResults'](_0x552ee9,_0x44ef66,_0x19f698,_0x13a4ed),_0x552ee9['allValid']?0x0:0x1;}[a32_0x462d84(0x10f)](_0x3c867b,_0x5b345b,_0x3acb3c,_0x102f21){const _0x2335c1=a32_0x462d84;console['error']('\x0a'+a32_0x10437a[_0x2335c1(0xb5)](_0x2335c1(0x22e))+'\x20'+_0x3c867b['name']),console[_0x2335c1(0x17d)]('═'[_0x2335c1(0x148)](0x3c)),this[_0x2335c1(0xa9)](_0x3c867b);if(typeof _0x5b345b['attribute']===_0x2335c1(0x27d)){this[_0x2335c1(0x191)](_0x3c867b),this['displaySummary'](_0x3c867b),this[_0x2335c1(0xb8)](_0x3acb3c,_0x102f21,_0x2335c1(0xa0),_0x5b345b[_0x2335c1(0xa0)]);return;}if(_0x5b345b[_0x2335c1(0xa0)]===!![]){this['displayAttributesStats'](_0x3c867b),this['displaySummary'](_0x3c867b),this[_0x2335c1(0xb8)](_0x3acb3c,_0x102f21,'attributes');return;}if(typeof _0x5b345b[_0x2335c1(0x129)]==='string'){this[_0x2335c1(0x156)](_0x3c867b,_0x102f21),this['displaySummary'](_0x3c867b),this[_0x2335c1(0xb8)](_0x3acb3c,_0x102f21,_0x2335c1(0x129),_0x5b345b[_0x2335c1(0x129)]);return;}if(_0x5b345b[_0x2335c1(0x129)]===!![]){this[_0x2335c1(0x156)](_0x3c867b,_0x102f21),this[_0x2335c1(0x186)](_0x3c867b),this[_0x2335c1(0xb8)](_0x3acb3c,_0x102f21,_0x2335c1(0xde));return;}this[_0x2335c1(0x191)](_0x3c867b),this['displayBehaviorsStats'](_0x3c867b,_0x102f21),this['displayRealtimeInfo'](_0x3c867b),this['displaySummary'](_0x3c867b),this[_0x2335c1(0xb8)](_0x3acb3c,_0x102f21,_0x2335c1(0x114));}[a32_0x462d84(0x135)](_0x30e2cd){displayRealtimeValidation(_0x30e2cd);}[a32_0x462d84(0xb8)](_0x5d93a4,_0x58c69a,_0x2ba7a4,_0x43b825){const _0x296277=a32_0x462d84;console[_0x296277(0x17d)]('\x0a'+a32_0x10437a['dim'](_0x296277(0x250)));const _0x4c8901=_0x58c69a!==_0x296277(0x201)?_0x296277(0x185)+_0x58c69a:'';if(_0x2ba7a4==='attribute'&&_0x43b825)console[_0x296277(0x17d)]('\x20\x20'+a32_0x10437a['dim'](_0x296277(0x1e7)+_0x5d93a4+'\x20--attribute\x20\x22'+_0x43b825+'\x22'+_0x4c8901));else{if(_0x2ba7a4===_0x296277(0x129)&&_0x43b825)console[_0x296277(0x17d)]('\x20\x20'+a32_0x10437a[_0x296277(0x247)](_0x296277(0x1e7)+_0x5d93a4+_0x296277(0x1b8)+_0x43b825+'\x22'+_0x4c8901));else(_0x2ba7a4==='attributes'||_0x2ba7a4==='all')&&console['error']('\x20\x20'+a32_0x10437a['dim'](_0x296277(0x1e7)+_0x5d93a4+_0x296277(0x155)+_0x4c8901));}(_0x2ba7a4===_0x296277(0xde)||_0x2ba7a4===_0x296277(0x114))&&console[_0x296277(0x17d)]('\x20\x20'+a32_0x10437a[_0x296277(0x247)]('tdx\x20ps\x20preview\x20'+_0x5d93a4+_0x296277(0x1aa)+_0x4c8901)),_0x2ba7a4===_0x296277(0x114)&&console['error']('\x20\x20'+a32_0x10437a[_0x296277(0x247)](_0x296277(0x1e7)+_0x5d93a4+_0x296277(0x10b)+_0x4c8901));}[a32_0x462d84(0xa9)](_0x4d559d){const _0xfbf17e=a32_0x462d84,{master:_0x2f918c}=_0x4d559d,_0x2675c8=_0x2f918c[_0xfbf17e(0x1cf)]?a32_0x10437a[_0xfbf17e(0x96)]('✔'):a32_0x10437a[_0xfbf17e(0xbd)]('✘');console[_0xfbf17e(0x17d)]('\x0a'+a32_0x10437a[_0xfbf17e(0x247)](_0xfbf17e(0x1db))),console['error'](_0x2675c8+'\x20'+a32_0x10437a[_0xfbf17e(0xb5)](_0x2f918c[_0xfbf17e(0x162)]+'.'+_0x2f918c[_0xfbf17e(0x217)])),_0x2f918c[_0xfbf17e(0x1cf)]?_0x2f918c[_0xfbf17e(0x122)]!==undefined&&console[_0xfbf17e(0x17d)]('\x20\x20'+a32_0x10437a['dim']('Rows:')+'\x20'+a32_0x10437a[_0xfbf17e(0x276)](formatRows(_0x2f918c[_0xfbf17e(0x122)]))):console[_0xfbf17e(0x17d)]('\x20\x20'+a32_0x10437a[_0xfbf17e(0xbd)](_0xfbf17e(0x192))+'\x20'+_0x2f918c['schemaError']);}[a32_0x462d84(0x191)](_0x54ab47){const _0xcf16ba=a32_0x462d84;if(_0x54ab47[_0xcf16ba(0x150)][_0xcf16ba(0x7b)]===0x0)return;console['error']('\x0a'+a32_0x10437a[_0xcf16ba(0x247)](_0xcf16ba(0x1ee)));for(const _0x1acbbb of _0x54ab47[_0xcf16ba(0x150)]){const _0x3b0765=_0x1acbbb['schemaValid']?a32_0x10437a[_0xcf16ba(0x96)]('✔'):a32_0x10437a['red']('✘');let _0x4e7ba0='';if(_0x1acbbb[_0xcf16ba(0x1cf)]&&_0x1acbbb[_0xcf16ba(0xf1)]!==undefined&&_0x1acbbb['coveragePercent']!==undefined){const _0x113f53=_0x1acbbb['coveragePercent'][_0xcf16ba(0xa8)](0x1),_0x549f44=_0x1acbbb[_0xcf16ba(0x11e)]>=0x50?a32_0x10437a[_0xcf16ba(0x96)]:_0x1acbbb['coveragePercent']>=0x32?a32_0x10437a[_0xcf16ba(0x94)]:a32_0x10437a[_0xcf16ba(0xbd)];_0x4e7ba0='\x20'+a32_0x10437a[_0xcf16ba(0x247)](_0xcf16ba(0x190))+'\x20'+_0x549f44(_0x113f53+'%')+'\x20('+formatRows(_0x1acbbb[_0xcf16ba(0xf1)])+'\x20rows)';}console[_0xcf16ba(0x17d)](_0x3b0765+'\x20'+a32_0x10437a[_0xcf16ba(0xb5)](_0x1acbbb[_0xcf16ba(0xf9)])+_0x4e7ba0),console['error']('\x20\x20'+a32_0x10437a[_0xcf16ba(0x247)](_0xcf16ba(0x1d6))+'\x20'+a32_0x10437a[_0xcf16ba(0xb5)](_0x1acbbb[_0xcf16ba(0x162)]+'.'+_0x1acbbb['table']));const _0x366854=_0x1acbbb['joinKey']===_0x1acbbb[_0xcf16ba(0x210)]?a32_0x10437a['dim'](_0xcf16ba(0x1bf))+'\x20'+_0x1acbbb[_0xcf16ba(0x107)]:a32_0x10437a[_0xcf16ba(0x247)](_0xcf16ba(0x118))+'\x20'+_0x1acbbb[_0xcf16ba(0x107)]+_0xcf16ba(0x230)+_0x1acbbb['foreignKey'];console[_0xcf16ba(0x17d)]('\x20\x20'+_0x366854),console[_0xcf16ba(0x17d)]('\x20\x20'+a32_0x10437a[_0xcf16ba(0x247)](_0xcf16ba(0x25f))),this['displayColumns'](_0x1acbbb[_0xcf16ba(0x254)]),!_0x1acbbb[_0xcf16ba(0x1cf)]&&console[_0xcf16ba(0x17d)]('\x20\x20'+a32_0x10437a[_0xcf16ba(0xbd)]('Error:')+'\x20'+_0x1acbbb[_0xcf16ba(0xbf)]);}}[a32_0x462d84(0x156)](_0x598127,_0xd5cd7e){const _0x5110bb=a32_0x462d84;if(_0x598127[_0x5110bb(0xde)][_0x5110bb(0x7b)]===0x0)return;console[_0x5110bb(0x17d)]('\x0a'+a32_0x10437a['dim'](_0x5110bb(0xcc))+'\x20'+a32_0x10437a[_0x5110bb(0x247)]('('+_0xd5cd7e+')'));for(const _0x341e29 of _0x598127[_0x5110bb(0xde)]){const _0x2bb613=_0x341e29[_0x5110bb(0x1cf)]?a32_0x10437a[_0x5110bb(0x96)]('✔'):a32_0x10437a[_0x5110bb(0xbd)]('✘');let _0x459a78='';if(_0x341e29['schemaValid']&&_0x341e29['customersWithEvents']!==undefined&&_0x341e29[_0x5110bb(0x24b)]!==undefined){const _0x3819be=_0x341e29[_0x5110bb(0x1c7)]?.['toFixed'](0x1)||'?',_0x12cd48=(_0x341e29['customerPercent']??0x0)>=0x32?a32_0x10437a[_0x5110bb(0x96)]:(_0x341e29[_0x5110bb(0x1c7)]??0x0)>=0x14?a32_0x10437a[_0x5110bb(0x94)]:a32_0x10437a[_0x5110bb(0xbd)];_0x459a78='\x20'+a32_0x10437a['dim'](_0x5110bb(0x268))+'\x20'+_0x12cd48(formatRows(_0x341e29['customersWithEvents']))+'\x20('+_0x3819be+_0x5110bb(0x84)+a32_0x10437a[_0x5110bb(0x247)](_0x5110bb(0x81))+'\x20'+a32_0x10437a[_0x5110bb(0x276)](formatRows(_0x341e29[_0x5110bb(0x24b)]));}console[_0x5110bb(0x17d)](_0x2bb613+'\x20'+a32_0x10437a[_0x5110bb(0xb5)](_0x341e29['name'])+_0x459a78),console[_0x5110bb(0x17d)]('\x20\x20'+a32_0x10437a[_0x5110bb(0x247)](_0x5110bb(0x1d6))+'\x20'+a32_0x10437a[_0x5110bb(0xb5)](_0x341e29[_0x5110bb(0x162)]+'.'+_0x341e29['table']));const _0x226ca8=_0x341e29['joinKey']===_0x341e29['foreignKey']?a32_0x10437a['dim'](_0x5110bb(0x1bf))+'\x20'+_0x341e29[_0x5110bb(0x107)]:a32_0x10437a['dim'](_0x5110bb(0x118))+'\x20'+_0x341e29[_0x5110bb(0x107)]+_0x5110bb(0x230)+_0x341e29[_0x5110bb(0x210)];console[_0x5110bb(0x17d)]('\x20\x20'+_0x226ca8),console['error']('\x20\x20'+a32_0x10437a['dim'](_0x5110bb(0x25f))),this[_0x5110bb(0x175)](_0x341e29[_0x5110bb(0x254)]),!_0x341e29[_0x5110bb(0x1cf)]&&console[_0x5110bb(0x17d)]('\x20\x20'+a32_0x10437a['red'](_0x5110bb(0x192))+'\x20'+_0x341e29[_0x5110bb(0xbf)]);}}['displayColumns'](_0x270f1e){const _0x4a0938=a32_0x462d84;for(const _0x17b771 of _0x270f1e){_0x17b771[_0x4a0938(0x9b)]===_0x17b771[_0x4a0938(0x181)]||_0x17b771[_0x4a0938(0x181)]==='*'?console[_0x4a0938(0x17d)](_0x4a0938(0xe4)+_0x17b771['label']):console[_0x4a0938(0x17d)]('\x20\x20\x20\x20-\x20'+_0x17b771[_0x4a0938(0x9b)]+'\x20'+a32_0x10437a[_0x4a0938(0x247)]('('+_0x17b771[_0x4a0938(0x181)]+')'));}}[a32_0x462d84(0x186)](_0x506d9c){const _0x353ab2=a32_0x462d84;console['error']('─'['repeat'](0x3c));if(_0x506d9c[_0x353ab2(0x25e)][_0x353ab2(0x7b)]>0x0){console[_0x353ab2(0x17d)]('\x0a'+a32_0x10437a[_0x353ab2(0xbd)](_0x353ab2(0xba)));for(const _0x52f1ec of _0x506d9c['errors']){console[_0x353ab2(0x17d)]('\x20\x20'+a32_0x10437a[_0x353ab2(0xbd)]('•')+'\x20'+_0x52f1ec);}}_0x506d9c['allValid']&&console[_0x353ab2(0x17d)]('\x0a'+a32_0x10437a[_0x353ab2(0x96)]('✔')+_0x353ab2(0x20d));}}export class ParentSegmentPreviewCommand extends BaseParentSegmentCommand{[a32_0x462d84(0xf9)]='segment:parent:preview';['description']=a32_0x462d84(0x252);async['execute'](_0x573e4b){const _0x43a9f9=a32_0x462d84,{options:_0x2e1031,args:_0x45e093,tdx:_0x34931c}=_0x573e4b,_0x59e2d1=_0x2e1031,_0x1c54c2=_0x45e093[0x0]||_0x2e1031[_0x43a9f9(0xa2)];if(!_0x1c54c2)return showParentSegmentNotSetError(_0x43a9f9(0x1f5)+_0x43a9f9(0x168)+'Options\x20(one\x20required):\x0a'+_0x43a9f9(0x1e8)+'\x20\x20--attribute\x20<name>\x20\x20\x20Show\x20sample\x20data\x20for\x20specific\x20attribute\x0a'+'\x20\x20--behavior\x20<name>\x20\x20\x20\x20Show\x20sample\x20data\x20for\x20specific\x20behavior\x0a'+_0x43a9f9(0x219)+_0x43a9f9(0x9d)),0x1;if(!_0x59e2d1[_0x43a9f9(0x109)]&&!_0x59e2d1[_0x43a9f9(0xa0)]&&!_0x59e2d1[_0x43a9f9(0x129)]&&!_0x59e2d1[_0x43a9f9(0x7c)])return console['error'](a32_0x10437a['red'](_0x43a9f9(0x151))),console[_0x43a9f9(0x17d)](_0x43a9f9(0x203)),console[_0x43a9f9(0x17d)]('Options:'),console[_0x43a9f9(0x17d)](_0x43a9f9(0x182)),console[_0x43a9f9(0x17d)]('\x20\x20--attribute\x20<name>\x20\x20\x20Show\x20sample\x20data\x20for\x20specific\x20attribute'),console['error'](_0x43a9f9(0x16c)),console[_0x43a9f9(0x17d)](_0x43a9f9(0x1a7)),0x1;const _0x17d01a=resolveYamlFile(_0x1c54c2);if(!existsSync(_0x17d01a))return showFileNotFoundError(_0x17d01a,_0x1c54c2),0x1;_0x59e2d1[_0x43a9f9(0x19e)]&&(console[_0x43a9f9(0x17d)]('Site:\x20'+_0x59e2d1[_0x43a9f9(0xe6)]),console[_0x43a9f9(0x17d)](_0x43a9f9(0x245)+_0x17d01a));let _0x13f38f;try{_0x13f38f=readFileSync(_0x17d01a,_0x43a9f9(0x15f));}catch(_0x3f8bb1){const _0xeb3c8f=_0x3f8bb1 instanceof Error?_0x3f8bb1[_0x43a9f9(0x184)]:String(_0x3f8bb1);return console['error']('Error\x20reading\x20file:\x20'+_0xeb3c8f),0x1;}let _0x3a7ac7;try{_0x3a7ac7=parseDef(_0x13f38f);}catch(_0x60261c){const _0xf11923=_0x60261c instanceof Error?_0x60261c[_0x43a9f9(0x184)]:String(_0x60261c);return console[_0x43a9f9(0x17d)](a32_0x10437a['red'](_0x43a9f9(0xb0)+_0xf11923)),0x1;}if(_0x59e2d1['attribute']===!![]||_0x59e2d1[_0x43a9f9(0xa0)]===''){const _0x5d9b57=_0x3a7ac7[_0x43a9f9(0x150)]?.['map'](_0x5b1903=>_0x5b1903[_0x43a9f9(0xf9)])||[];if(_0x5d9b57[_0x43a9f9(0x7b)]===0x0)console[_0x43a9f9(0x17d)](a32_0x10437a[_0x43a9f9(0xbd)](_0x43a9f9(0x224)));else{console[_0x43a9f9(0x17d)](a32_0x10437a[_0x43a9f9(0xbd)]('Error:\x20--attribute\x20requires\x20a\x20name\x0a')),console[_0x43a9f9(0x17d)]('Available\x20attributes:');for(const _0x41db51 of _0x5d9b57){console[_0x43a9f9(0x17d)]('\x20\x20'+a32_0x10437a[_0x43a9f9(0x276)](_0x41db51));}console[_0x43a9f9(0x17d)](_0x43a9f9(0x193)+_0x1c54c2+'\x20--attribute\x20\x22'+_0x5d9b57[0x0]+'\x22');}return 0x1;}if(_0x59e2d1[_0x43a9f9(0x129)]===!![]||_0x59e2d1[_0x43a9f9(0x129)]===''){const _0x73d40=_0x3a7ac7[_0x43a9f9(0xde)]?.[_0x43a9f9(0xa5)](_0x1b67d8=>_0x1b67d8[_0x43a9f9(0xf9)])||[];if(_0x73d40[_0x43a9f9(0x7b)]===0x0)console['error'](a32_0x10437a['red'](_0x43a9f9(0x145)));else{console[_0x43a9f9(0x17d)](a32_0x10437a['red']('Error:\x20--behavior\x20requires\x20a\x20name\x0a')),console[_0x43a9f9(0x17d)](_0x43a9f9(0xdb));for(const _0x323eca of _0x73d40){console[_0x43a9f9(0x17d)]('\x20\x20'+a32_0x10437a[_0x43a9f9(0x276)](_0x323eca));}console[_0x43a9f9(0x17d)](_0x43a9f9(0x193)+_0x1c54c2+_0x43a9f9(0x1b8)+_0x73d40[0x0]+'\x22');}return 0x1;}const _0x209d09=createCommandSpinner(a32_0x10437a[_0x43a9f9(0x247)](_0x43a9f9(0x256)),{'verbose':_0x59e2d1[_0x43a9f9(0x19e)]});_0x209d09[_0x43a9f9(0x1c9)]();const _0x56f334={'onProgress':_0x6210bb=>{_0x209d09['text']=formatProgressMessage(_0x6210bb);}};if(_0x59e2d1[_0x43a9f9(0x109)])_0x56f334['master']=!![];if(_0x59e2d1[_0x43a9f9(0xa0)]&&typeof _0x59e2d1[_0x43a9f9(0xa0)]===_0x43a9f9(0x27d))_0x56f334['attribute']=_0x59e2d1[_0x43a9f9(0xa0)];if(_0x59e2d1[_0x43a9f9(0x129)]&&typeof _0x59e2d1[_0x43a9f9(0x129)]===_0x43a9f9(0x27d))_0x56f334[_0x43a9f9(0x129)]=_0x59e2d1[_0x43a9f9(0x129)];if(_0x59e2d1[_0x43a9f9(0x7c)])_0x56f334[_0x43a9f9(0x7c)]=!![];if(_0x59e2d1[_0x43a9f9(0x9f)])_0x56f334[_0x43a9f9(0x9f)]=_0x59e2d1['interval'];let _0x200724;try{_0x200724=await _0x34931c[_0x43a9f9(0x139)][_0x43a9f9(0x9a)](_0x13f38f,_0x56f334),_0x209d09[_0x43a9f9(0x26c)]();}catch(_0x4aaf87){_0x209d09[_0x43a9f9(0x26c)]();throw _0x4aaf87;}return await this['displayPreviewResults'](_0x200724,{'master':_0x59e2d1[_0x43a9f9(0x109)],'attribute':typeof _0x59e2d1[_0x43a9f9(0xa0)]==='string'?_0x59e2d1[_0x43a9f9(0xa0)]:undefined,'behavior':typeof _0x59e2d1['behavior']===_0x43a9f9(0x27d)?_0x59e2d1[_0x43a9f9(0x129)]:undefined,'enriched':_0x59e2d1[_0x43a9f9(0x7c)]}),_0x200724[_0x43a9f9(0x241)]?0x0:0x1;}async['displayPreviewResults'](_0x496d56,_0x109fc0){const _0x13ee92=a32_0x462d84;console[_0x13ee92(0x17d)]('\x0a'+a32_0x10437a['bold'](_0x13ee92(0x279))+'\x20'+_0x496d56['name']),console[_0x13ee92(0x17d)]('═'[_0x13ee92(0x148)](0x3c));if(_0x109fc0[_0x13ee92(0x109)]&&_0x496d56[_0x13ee92(0x106)]){const _0x2ad5d1=a32_0x10437a[_0x13ee92(0x247)](_0x13ee92(0x1e4))+'\x20'+a32_0x10437a['bold'](_0x496d56[_0x13ee92(0x109)][_0x13ee92(0x162)]+'.'+_0x496d56[_0x13ee92(0x109)][_0x13ee92(0x217)]);await this[_0x13ee92(0x1ad)](_0x2ad5d1,_0x496d56[_0x13ee92(0x106)]);}else{if(_0x109fc0['attribute']&&_0x496d56[_0x13ee92(0x106)]){const _0x5f4669=a32_0x10437a[_0x13ee92(0x247)](_0x13ee92(0x187))+'\x20'+a32_0x10437a['bold'](_0x109fc0[_0x13ee92(0xa0)]);await this[_0x13ee92(0x1ad)](_0x5f4669,_0x496d56[_0x13ee92(0x106)]);}else{if(_0x109fc0['behavior']&&_0x496d56['sampleData']){const _0x3b897e=a32_0x10437a[_0x13ee92(0x247)](_0x13ee92(0x233))+'\x20'+a32_0x10437a['bold'](_0x109fc0['behavior']);await this[_0x13ee92(0x1ad)](_0x3b897e,_0x496d56[_0x13ee92(0x106)]);}else{if(_0x109fc0[_0x13ee92(0x7c)]&&_0x496d56[_0x13ee92(0x106)]){const _0x47764e=a32_0x10437a[_0x13ee92(0x247)](_0x13ee92(0x111))+'\x20'+a32_0x10437a['bold']('Master\x20+\x20Attributes');await this[_0x13ee92(0x1ad)](_0x47764e,_0x496d56[_0x13ee92(0x106)]);}else!_0x496d56[_0x13ee92(0x106)]&&console[_0x13ee92(0x17d)](_0x13ee92(0x278));}}}if(_0x496d56[_0x13ee92(0x25e)]['length']>0x0){console[_0x13ee92(0x17d)]('─'[_0x13ee92(0x148)](0x3c)),console[_0x13ee92(0x17d)]('\x0a'+a32_0x10437a[_0x13ee92(0xbd)](_0x13ee92(0xba)));for(const _0x3a120b of _0x496d56[_0x13ee92(0x25e)]){console[_0x13ee92(0x17d)]('\x20\x20'+a32_0x10437a['red']('•')+'\x20'+_0x3a120b);}}}async[a32_0x462d84(0x1ad)](_0x1da286,_0x114978){const _0x37ebd5=a32_0x462d84;if(_0x114978[_0x37ebd5(0x7b)]===0x0){console[_0x37ebd5(0x17d)]('\x0a'+_0x1da286),console[_0x37ebd5(0x17d)](_0x37ebd5(0x164));return;}console[_0x37ebd5(0x17d)]('\x0a'+_0x1da286);const _0x10af58=Object['keys'](_0x114978[0x0])[_0x37ebd5(0xa5)](_0xbdccd6=>({'name':_0xbdccd6,'type':typeof _0x114978[0x0][_0xbdccd6]===_0x37ebd5(0x21f)?_0x37ebd5(0x22d):_0x37ebd5(0x115)})),_0x481fc4={'queryId':'preview','columns':_0x10af58,'data':_0x114978,'stats':{'state':_0x37ebd5(0x23e),'queued':![],'scheduled':![],'nodes':0x0,'totalSplits':0x0,'queuedSplits':0x0,'runningSplits':0x0,'completedSplits':0x0,'cpuTimeMillis':0x0,'wallTimeMillis':0x0,'queuedTimeMillis':0x0,'elapsedTimeMillis':0x0,'processedRows':_0x114978[_0x37ebd5(0x7b)],'processedBytes':0x0,'physicalInputBytes':0x0,'peakMemoryBytes':0x0,'spilledBytes':0x0}},_0x7bc03e=formatAsTable(_0x481fc4,_0x114978[_0x37ebd5(0x7b)],!![]);await writeOutput(_0x7bc03e,undefined,_0x37ebd5(0x217));}}export class ParentSegmentRunCommand extends BaseParentSegmentCommand{['name']=a32_0x462d84(0x133);[a32_0x462d84(0x19c)]=a32_0x462d84(0x277);async[a32_0x462d84(0x17f)](_0x546f31){const _0x5cd1cf=a32_0x462d84,{options:_0x50b70a,args:_0x3b3d65,tdx:_0x38f517}=_0x546f31,_0x181978=_0x50b70a,_0x3b26e1=_0x3b3d65[0x0]||_0x50b70a['parentSegment'];if(!_0x3b26e1)return showParentSegmentNotSetError(_0x5cd1cf(0xc4)+_0x5cd1cf(0x1b9)),0x1;const _0x529f4a=resolveYamlFile(_0x3b26e1);if(existsSync(_0x529f4a)){_0x181978['verbose']&&console[_0x5cd1cf(0x17d)](_0x5cd1cf(0x6f)+_0x529f4a);let _0x445da8;try{_0x445da8=readFileSync(_0x529f4a,_0x5cd1cf(0x15f));}catch(_0x1cc8a4){const _0x3d1598=_0x1cc8a4 instanceof Error?_0x1cc8a4['message']:String(_0x1cc8a4);return console[_0x5cd1cf(0x17d)]('Error\x20reading\x20file:\x20'+_0x3d1598),0x1;}const _0x146369=await withSpinner(_0x5cd1cf(0x1bc),()=>_0x38f517['segment'][_0x5cd1cf(0x25a)](_0x445da8),{'verbose':_0x181978['verbose']}),_0x4d7561=_0x146369[_0x5cd1cf(0x12d)],{isNew:_0xef5381,name:_0x4246fd,hasChanges:_0x2b6b10,diffFormatted:_0x53a394}=_0x4d7561;if(_0x2b6b10){_0xef5381?console[_0x5cd1cf(0x17d)](_0x5cd1cf(0x1ec)+_0x4246fd+'\x27:'):console[_0x5cd1cf(0x17d)]('\x0aChanges\x20to\x20apply\x20to\x20\x27'+_0x4246fd+'\x27:');console['error']('─'['repeat'](0x3c)),console[_0x5cd1cf(0x17d)](_0x53a394),console[_0x5cd1cf(0x17d)]('─'[_0x5cd1cf(0x148)](0x3c));const _0x3d3d45=_0xef5381?_0x5cd1cf(0xd6)+_0x4246fd+_0x5cd1cf(0x73):_0x5cd1cf(0x220)+_0x4246fd+_0x5cd1cf(0x73);if(!_0x181978['yes']){if(!isInteractive())return console['error'](a32_0x10437a[_0x5cd1cf(0xbd)](_0x5cd1cf(0x1dc)),_0x5cd1cf(0x1c6)),console[_0x5cd1cf(0x17d)](a32_0x10437a[_0x5cd1cf(0x247)](_0x5cd1cf(0x14f))),0x1;const _0x3eae80=await confirmKey(_0x3d3d45);if(!_0x3eae80)return console[_0x5cd1cf(0x17d)](a32_0x10437a['yellow'](_0x5cd1cf(0x1ce))),0x1;}const _0x4a3e61=_0xef5381?_0x5cd1cf(0x1e5):_0x5cd1cf(0x27f);await withSpinner(_0x4a3e61+_0x5cd1cf(0xbc)+_0x4246fd+_0x5cd1cf(0x183),()=>_0x4d7561['apply'](),{'verbose':_0x181978[_0x5cd1cf(0x19e)]});const _0x384173=_0xef5381?_0x5cd1cf(0xbb):_0x5cd1cf(0x169);console[_0x5cd1cf(0x17d)]('✔\x20'+_0x384173+'\x20parent\x20segment\x20\x27'+_0x4246fd+'\x27');}else console['error']('✔\x20No\x20changes\x20-\x20\x27'+_0x4246fd+_0x5cd1cf(0xd5));}const _0x42ebe2=await withSpinner('Running\x20parent\x20segment\x20workflow\x20for\x20\x27'+_0x3b26e1+'\x27...',()=>_0x38f517[_0x5cd1cf(0x139)][_0x5cd1cf(0xc1)](_0x3b26e1),{'verbose':_0x181978[_0x5cd1cf(0x19e)]}),_0x38bb5b=_0x42ebe2['data'],_0x242325=getConsoleUrl(_0x181978[_0x5cd1cf(0xe6)],_0x5cd1cf(0x272)+_0x38bb5b[_0x5cd1cf(0x78)]+'/sessions/'+_0x38bb5b[_0x5cd1cf(0xc2)]+_0x5cd1cf(0x1f8)+_0x38bb5b[_0x5cd1cf(0x1e1)]);return console[_0x5cd1cf(0x17d)](_0x5cd1cf(0x17e)),console['error']('\x20\x20'+a32_0x10437a[_0x5cd1cf(0x247)](_0x5cd1cf(0x27e))+'\x20'+_0x38bb5b['audienceId']),console['error']('\x20\x20'+a32_0x10437a[_0x5cd1cf(0x247)]('Status:')+'\x20'+_0x38bb5b['status']),console[_0x5cd1cf(0x17d)]('\x20\x20'+a32_0x10437a[_0x5cd1cf(0x247)](_0x5cd1cf(0x11c))+'\x20'+_0x38bb5b[_0x5cd1cf(0xc2)]),console[_0x5cd1cf(0x17d)]('\x20\x20'+a32_0x10437a['dim'](_0x5cd1cf(0xe0))+'\x20'+_0x38bb5b['workflowAttemptId']),console[_0x5cd1cf(0x17d)]('\x20\x20'+_0x242325),console[_0x5cd1cf(0x17d)]('\x0a'+a32_0x10437a[_0x5cd1cf(0x247)](_0x5cd1cf(0x90))+_0x5cd1cf(0xf3)+_0x38bb5b[_0x5cd1cf(0x1e1)]+_0x5cd1cf(0xd7)),0x0;}}export class ParentSegmentFieldsCommand extends BaseCommand{[a32_0x462d84(0xf9)]=a32_0x462d84(0xe9);['description']='List\x20available\x20fields\x20for\x20segmentation';async[a32_0x462d84(0x17f)](_0x422882){const _0x3aae53=a32_0x462d84,{options:_0x202426,args:_0x1b6c52,tdx:_0x4c9012}=_0x422882,_0x1ba0b0=_0x1b6c52[0x0]||_0x202426[_0x3aae53(0xa2)];if(!_0x1ba0b0)return showParentSegmentNotSetError(_0x3aae53(0x158)+'\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20fields\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Show\x20fields\x20for\x20specific\x20parent\x20segment'),0x1;_0x202426[_0x3aae53(0x19e)]&&(console[_0x3aae53(0x17d)](_0x3aae53(0x112)+_0x202426[_0x3aae53(0xe6)]),console['error'](_0x3aae53(0x261)+_0x1ba0b0));const _0x234aca=await withSpinner('Listing\x20fields\x20for\x20\x27'+_0x1ba0b0+_0x3aae53(0x183),()=>_0x4c9012[_0x3aae53(0x139)][_0x3aae53(0x1cc)](_0x1ba0b0),{'verbose':_0x202426[_0x3aae53(0x19e)]}),_0x3b14a1=_0x234aca['data'];console[_0x3aae53(0x17d)](_0x3aae53(0x105)+_0x3b14a1[_0x3aae53(0x7b)]+_0x3aae53(0xdd)+(_0x3b14a1[_0x3aae53(0x7b)]!==0x1?'s':''));if(_0x202426['json']||_0x202426[_0x3aae53(0x262)])return await handleSDKOutput(_0x3b14a1,_0x202426),0x0;return displayFieldsHumanReadable(_0x3b14a1,_0x1ba0b0),0x0;}}export class ParentSegmentViewCommand extends BaseCommand{[a32_0x462d84(0xf9)]=a32_0x462d84(0x1a3);['description']=a32_0x462d84(0xb4);async['execute'](_0x1ea0af){const _0xe186d8=a32_0x462d84,{options:_0x219232,args:_0x143c8c,tdx:_0x4bc193}=_0x1ea0af,_0x219d91=_0x219232,_0x5a4b02=_0x143c8c[0x0]||_0x219232['parentSegment'];if(!_0x5a4b02)return showParentSegmentNotSetError(_0xe186d8(0x171)+_0xe186d8(0x1b1)+_0xe186d8(0x89)+_0xe186d8(0x7f)),0x1;_0x219232[_0xe186d8(0x19e)]&&(console[_0xe186d8(0x17d)]('Site:\x20'+_0x219232[_0xe186d8(0xe6)]),console[_0xe186d8(0x17d)](_0xe186d8(0x261)+_0x5a4b02));const _0x2d6415=await withSpinner(_0xe186d8(0x125)+_0x5a4b02+_0xe186d8(0x183),()=>_0x4bc193[_0xe186d8(0x139)][_0xe186d8(0x123)](_0x5a4b02),{'verbose':_0x219232[_0xe186d8(0x19e)]}),_0x18b5fa=_0x2d6415[_0xe186d8(0x12d)];if(_0x219d91[_0xe186d8(0x197)]){const _0x2c262c=getConsoleNextUrl(_0x219d91['site'],_0xe186d8(0x1d1)+_0x18b5fa['id']);return console[_0xe186d8(0x17d)](a32_0x10437a['green']('✔')+_0xe186d8(0x1e9)+a32_0x10437a[_0xe186d8(0x276)](_0x2c262c)),openBrowser(_0x2c262c),0x0;}return await handleSingleObjectOutput(_0x18b5fa,_0x219232),0x0;}}export class ParentSegmentDescCommand extends BaseCommand{[a32_0x462d84(0xf9)]=a32_0x462d84(0xdf);[a32_0x462d84(0x19c)]=a32_0x462d84(0x11d);async['execute'](_0x3f4e71){const _0x477863=a32_0x462d84,{options:_0x4917d0,args:_0x15e5c0,tdx:_0x1a663e}=_0x3f4e71,_0x236254=_0x4917d0,_0x4a4fd2=_0x15e5c0[0x0]||_0x4917d0[_0x477863(0xa2)];if(!_0x4a4fd2)return showParentSegmentNotSetError('Usage:\x20tdx\x20ps\x20desc\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Describe\x20all\x20tables\x20(requires\x20context)\x0a'+'\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20desc\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Describe\x20all\x20tables\x20for\x20parent\x20segment\x0a\x0a'+_0x477863(0x89)+_0x477863(0x79)),0x1;_0x4917d0['verbose']&&(console[_0x477863(0x17d)](_0x477863(0x112)+_0x4917d0['site']),console[_0x477863(0x17d)](_0x477863(0x261)+_0x4a4fd2));const _0x7ad158=await withSpinner(_0x477863(0x255)+_0x4a4fd2+_0x477863(0x183),()=>_0x1a663e['segment'][_0x477863(0xe2)](_0x4a4fd2),{'verbose':_0x4917d0[_0x477863(0x19e)]}),_0x4018e2=_0x7ad158[_0x477863(0x12d)],_0x536ffe=_0x1a663e[_0x477863(0x139)][_0x477863(0x21a)](_0x4018e2);if(_0x236254['output']){const _0x45a07f=await this['collectSchema'](_0x3f4e71,_0x4a4fd2,_0x4018e2,_0x536ffe),_0x252cb0=this[_0x477863(0x85)](_0x45a07f);writeFileSync(_0x236254[_0x477863(0x234)],_0x252cb0);const _0xf2aa8=_0x45a07f[_0x477863(0x1c4)][_0x477863(0x254)][_0x477863(0x7b)]+_0x45a07f[_0x477863(0xde)][_0x477863(0x134)]((_0x9734d9,_0x50b639)=>_0x9734d9+_0x50b639['columns'][_0x477863(0x7b)],0x0),_0x293f0b=_0x45a07f[_0x477863(0xde)]['filter'](_0x4ce3f2=>_0x4ce3f2[_0x477863(0x254)][_0x477863(0x7b)]===0x0)['length'];return console['log'](_0x477863(0x21d)+_0x236254[_0x477863(0x234)]),console[_0x477863(0x195)](_0x477863(0x97)+_0x536ffe),console[_0x477863(0x195)]('\x20\x20Tables:\x201\x20customers\x20+\x20'+_0x45a07f['behaviors'][_0x477863(0x7b)]+_0x477863(0x18f)),console[_0x477863(0x195)](_0x477863(0x1d4)+_0xf2aa8+_0x477863(0x1e6)),_0x293f0b>0x0&&console['log']('\x20\x20Note:\x20'+_0x293f0b+_0x477863(0xf6)),0x0;}console[_0x477863(0x17d)]('\x0a'+a32_0x10437a['bold']('Output\x20Database:')+'\x20'+a32_0x10437a[_0x477863(0x276)](_0x536ffe));const _0x38796e=await withSpinner(_0x477863(0xfe),()=>_0x1a663e[_0x477863(0x139)]['getParentSQL'](_0x4018e2),{'verbose':_0x4917d0[_0x477863(0x19e)]});console[_0x477863(0x17d)]('\x0a'+a32_0x10437a[_0x477863(0xb5)]('customers')+'\x20'+a32_0x10437a[_0x477863(0x247)]('('+_0x536ffe+_0x477863(0x1cb)));const _0x347156=await executeSchemaQuery(_0x38796e[_0x477863(0x12d)],_0x1a663e,_0x4917d0);await handleQueryOutput(_0x347156,_0x4917d0);const _0x5ae67b=await withSpinner(_0x477863(0x257),()=>_0x1a663e['segment'][_0x477863(0x236)](_0x4018e2),{'verbose':_0x4917d0[_0x477863(0x19e)]});for(const _0x4818db of _0x5ae67b['data']){const _0x59557c=_0x477863(0x70)+_0x4818db['toLowerCase']()[_0x477863(0x228)](/\s+/g,'_'),_0x18382a=_0x477863(0x77)+_0x536ffe+'.'+_0x59557c;console['error']('\x0a'+a32_0x10437a[_0x477863(0xb5)](_0x4818db)+'\x20'+a32_0x10437a[_0x477863(0x247)]('('+_0x536ffe+'.'+_0x59557c+')'));try{const _0x7f1160=await executeSchemaQuery(_0x18382a,_0x1a663e,_0x4917d0);await handleQueryOutput(_0x7f1160,_0x4917d0);}catch{console[_0x477863(0x17d)](a32_0x10437a[_0x477863(0x94)](_0x477863(0x99)));}}return 0x0;}async['collectSchema'](_0x5a9c12,_0x1b6270,_0x447faa,_0x342f76){const _0x1a6ce7=a32_0x462d84,{options:_0x280b2b,tdx:_0x406c3f}=_0x5a9c12,_0x223412=await withSpinner(_0x1a6ce7(0xfe),()=>_0x406c3f[_0x1a6ce7(0x139)][_0x1a6ce7(0x11b)](_0x447faa),{'verbose':_0x280b2b['verbose']}),_0x12ac84=await executeSchemaQuery(_0x223412[_0x1a6ce7(0x12d)],_0x406c3f,_0x280b2b),_0x22a90e=_0x12ac84[_0x1a6ce7(0x12d)][_0x1a6ce7(0xa5)](_0x2d5f7b=>({'name':_0x2d5f7b['column_name'],'type':_0x2d5f7b[_0x1a6ce7(0x23c)]})),_0x32a961=await withSpinner(_0x1a6ce7(0x257),()=>_0x406c3f[_0x1a6ce7(0x139)][_0x1a6ce7(0x236)](_0x447faa),{'verbose':_0x280b2b[_0x1a6ce7(0x19e)]}),_0x32e84e=[];for(const _0x26021a of _0x32a961[_0x1a6ce7(0x12d)]){const _0x519eb5=_0x1a6ce7(0x70)+_0x26021a[_0x1a6ce7(0x263)]()['replace'](/\s+/g,'_'),_0x27dc95=_0x1a6ce7(0x77)+_0x342f76+'.'+_0x519eb5;let _0x2c8ffe=[];try{const _0x2712fe=await executeSchemaQuery(_0x27dc95,_0x406c3f,_0x280b2b);_0x2c8ffe=_0x2712fe['data'][_0x1a6ce7(0xa5)](_0x3970b8=>({'name':_0x3970b8['column_name'],'type':_0x3970b8[_0x1a6ce7(0x23c)]}));}catch{}_0x32e84e['push']({'table':_0x519eb5,'columns':_0x2c8ffe});}return{'database':_0x342f76,'parent_segment':_0x1b6270,'parent_id':_0x447faa,'customers':{'table':_0x1a6ce7(0x1c4),'columns':_0x22a90e},'behaviors':_0x32e84e};}['formatSchemaJson'](_0x10ab0e){const _0x33d83d=a32_0x462d84,_0x3476a3=_0x973eaf=>{const _0xae3cb7=a32_0x266e;if(_0x973eaf['length']===0x0)return'[]';const _0x802a90=_0x973eaf[_0xae3cb7(0xa5)](_0x5bf094=>'\x20\x20\x20\x20\x20\x20{\x20\x22name\x22:\x20\x22'+_0x5bf094['name']+_0xae3cb7(0x15c)+_0x5bf094['type']+_0xae3cb7(0x1af));return'[\x0a'+_0x802a90['join'](',\x0a')+'\x0a\x20\x20\x20\x20]';},_0x7cb210=_0x10ab0e[_0x33d83d(0xde)]['map'](_0x4a28af=>{const _0x285540=_0x33d83d;return _0x285540(0xb9)+_0x4a28af[_0x285540(0x217)]+_0x285540(0x1fb)+_0x3476a3(_0x4a28af[_0x285540(0x254)])[_0x285540(0x228)](/^/gm,'\x20\x20')[_0x285540(0xd1)]()+'\x0a\x20\x20\x20\x20}';})[_0x33d83d(0x1bb)](',\x0a');return _0x33d83d(0x7a)+_0x10ab0e[_0x33d83d(0x162)]+'\x22,\x0a\x20\x20\x22parent_segment\x22:\x20\x22'+_0x10ab0e[_0x33d83d(0x160)]+_0x33d83d(0xd0)+_0x10ab0e[_0x33d83d(0x1c1)]+'\x22,\x0a\x20\x20\x22customers\x22:\x20{\x0a\x20\x20\x20\x20\x22table\x22:\x20\x22'+_0x10ab0e[_0x33d83d(0x1c4)][_0x33d83d(0x217)]+'\x22,\x0a\x20\x20\x20\x20\x22columns\x22:\x20'+_0x3476a3(_0x10ab0e[_0x33d83d(0x1c4)][_0x33d83d(0x254)])[_0x33d83d(0x228)](/^/gm,'\x20\x20')[_0x33d83d(0xd1)]()+_0x33d83d(0x80)+_0x7cb210+_0x33d83d(0x1f2);}}export class ParentSegmentSQLCommand extends BaseCommand{[a32_0x462d84(0xf9)]=a32_0x462d84(0x26e);[a32_0x462d84(0x19c)]=a32_0x462d84(0x265);async[a32_0x462d84(0x17f)](_0x575414){const _0xadf2b9=a32_0x462d84,{options:_0x4aa086,args:_0x153e8c,tdx:_0x178ea0}=_0x575414,_0xe50ed1=_0x153e8c[0x0]||_0x4aa086[_0xadf2b9(0xa2)];if(!_0xe50ed1)return showParentSegmentNotSetError(_0xadf2b9(0x16d)+_0xadf2b9(0x1df)),0x1;_0x4aa086['verbose']&&(console['error']('Site:\x20'+_0x4aa086[_0xadf2b9(0xe6)]),console[_0xadf2b9(0x17d)](_0xadf2b9(0x261)+_0xe50ed1));const _0xc46e0c=await withSpinner(_0xadf2b9(0x255)+_0xe50ed1+_0xadf2b9(0x183),()=>_0x178ea0[_0xadf2b9(0x139)][_0xadf2b9(0xe2)](_0xe50ed1),{'verbose':_0x4aa086[_0xadf2b9(0x19e)]}),_0x45098a=_0xc46e0c[_0xadf2b9(0x12d)],_0xa05a71=await withSpinner(_0xadf2b9(0x1f1)+_0xe50ed1+'\x27...',()=>_0x178ea0[_0xadf2b9(0x139)][_0xadf2b9(0x11b)](_0x45098a),{'verbose':_0x4aa086[_0xadf2b9(0x19e)]}),_0x3ca842=_0xa05a71[_0xadf2b9(0x12d)];return _0x4aa086[_0xadf2b9(0x128)]==='json'||_0x4aa086['format']==='jsonl'?await handleSDKOutput([{'sql':_0x3ca842}],_0x4aa086):console[_0xadf2b9(0x195)](_0x3ca842),0x0;}}export class ParentSegmentShowCommand extends BaseCommand{['name']=a32_0x462d84(0x108);[a32_0x462d84(0x19c)]='Execute\x20parent\x20segment\x20SQL\x20query\x20and\x20show\x20results';async[a32_0x462d84(0x17f)](_0x441a56){const _0x25334a=a32_0x462d84,{options:_0x157023,args:_0x402baf,tdx:_0x289cca}=_0x441a56,_0x3efb9f=_0x402baf[0x0]||_0x157023[_0x25334a(0xa2)];if(!_0x3efb9f)return showParentSegmentNotSetError(_0x25334a(0x161)+_0x25334a(0x82)),0x1;_0x157023['verbose']&&(console[_0x25334a(0x17d)](_0x25334a(0x112)+_0x157023[_0x25334a(0xe6)]),console[_0x25334a(0x17d)](_0x25334a(0x261)+_0x3efb9f));const _0xfb5dc2=await withSpinner('Resolving\x20parent\x20segment\x20\x27'+_0x3efb9f+_0x25334a(0x183),()=>_0x289cca[_0x25334a(0x139)][_0x25334a(0xe2)](_0x3efb9f),{'verbose':_0x157023[_0x25334a(0x19e)]}),_0x377ab2=_0xfb5dc2['data'],_0x52c366=await withSpinner(_0x25334a(0x1f1)+_0x3efb9f+'\x27...',()=>_0x289cca[_0x25334a(0x139)]['getParentSQL'](_0x377ab2),{'verbose':_0x157023[_0x25334a(0x19e)]});let _0x32bb60=_0x52c366[_0x25334a(0x12d)];const _0x18e95e=resolveLimit(_0x157023['limit'],DEFAULT_DISPLAY_LIMIT),_0x4bd00c=/\bLIMIT\s+\d+/i['test'](_0x32bb60);!_0x4bd00c&&(_0x32bb60=_0x32bb60['trim']()['replace'](/;+$/,''),_0x32bb60='SELECT\x20*\x20FROM\x20(\x0a'+_0x32bb60+_0x25334a(0x267)+_0x18e95e);_0x157023[_0x25334a(0x19e)]&&console[_0x25334a(0x17d)]('SQL\x20query:\x0a'+_0x32bb60);const _0x550a6e=await withProgressSpinner(_0x25334a(0x157),async _0x450c94=>{const _0x459992=await _0x289cca['query']['execute'](_0x32bb60,{'catalog':'td','schema':'information_schema','onJobId':_0x194e27=>{const _0x3a99ce=a32_0x266e;_0x450c94[_0x3a99ce(0xae)](_0x194e27);}});return _0x459992;},{'verbose':_0x157023[_0x25334a(0x19e)]}),_0x3fc3f1=_0x550a6e[_0x25334a(0x12d)],_0x553c4f=_0x3fc3f1[_0x25334a(0xe1)]?_0x25334a(0xaa)+_0x3fc3f1['jobId']+']':'';return console[_0x25334a(0x17d)](_0x25334a(0x271)+_0x3fc3f1['stats']['processedRows'][_0x25334a(0x223)]()+'\x20rows\x20'+('in\x20'+formatElapsed(_0x3fc3f1[_0x25334a(0x142)][_0x25334a(0xaf)])+_0x553c4f)),await handleQueryOutput(_0x3fc3f1,_0x157023),0x0;}}export class PSRtListCommand extends BaseCommand{['name']=a32_0x462d84(0x1b2);[a32_0x462d84(0x19c)]='List\x20parent\x20segments\x20with\x20RT\x202.0\x20status';async[a32_0x462d84(0x17f)](_0x47d5f3){const _0x443c12=a32_0x462d84,{options:_0x24762a,args:_0x5190f2,tdx:_0x13f5cd}=_0x47d5f3,_0x24bccf=_0x5190f2[0x0],_0x28230e=await withSpinner(_0x24bccf?_0x443c12(0x154)+_0x24bccf+_0x443c12(0x183):_0x443c12(0x218),()=>_0x13f5cd[_0x443c12(0x231)]['list'](),{'verbose':_0x24762a[_0x443c12(0x19e)]});let _0x431e80=_0x28230e[_0x443c12(0x12d)]['filter'](_0x1b5994=>_0x1b5994[_0x443c12(0x206)]);if(_0x24bccf){const _0x59cc36=_0x24bccf[_0x443c12(0x228)](/[.+^${}()|[\]\\]/g,_0x443c12(0x229))['replace'](/\*/g,'.*')[_0x443c12(0x228)](/\?/g,'.'),_0x121877=new RegExp('^'+_0x59cc36+'$','i');_0x431e80=_0x431e80['filter'](_0x321bda=>_0x121877[_0x443c12(0x198)](_0x321bda[_0x443c12(0xf9)]));}_0x431e80['sort']((_0x2b4abc,_0x900bd5)=>_0x2b4abc[_0x443c12(0xf9)][_0x443c12(0x124)](_0x900bd5['name'])),console[_0x443c12(0x17d)]('✔\x20Found\x20'+_0x431e80[_0x443c12(0x7b)]+_0x443c12(0x143)+(_0x431e80['length']!==0x1?'s':''));const _0x592642=_0x38c9cc=>{const _0x194758=_0x443c12;return getConsoleNextUrl(_0x24762a[_0x194758(0xe6)],_0x194758(0x1d1)+_0x38c9cc);};if(_0x24762a[_0x443c12(0x128)]===_0x443c12(0x1ea)||_0x24762a[_0x443c12(0x128)]===_0x443c12(0x262)){const _0x2f1c4f=_0x431e80[_0x443c12(0xa5)](_0x10626a=>({..._0x10626a,'url':_0x592642(_0x10626a['id'])}));await handleSDKOutput(_0x2f1c4f,_0x24762a);}else{if(_0x431e80['length']===0x0)console[_0x443c12(0x195)]('No\x20RT-enabled\x20parent\x20segments\x20found');else for(const _0x525faa of _0x431e80){const _0x27e2db=_0x525faa['population']?a32_0x10437a[_0x443c12(0x247)]('\x20('+formatRows(_0x525faa['population'])+')'):'',_0x4087fc=hyperlink(_0x525faa['name'],_0x592642(_0x525faa['id']));console[_0x443c12(0x195)]('⚡\x20'+_0x4087fc+_0x27e2db);}}return 0x0;}}export class PSRtValidateCommand extends BaseParentSegmentCommand{['name']=a32_0x462d84(0x21b);[a32_0x462d84(0x19c)]=a32_0x462d84(0x1f7);async[a32_0x462d84(0x17f)](_0x2dccd5){const _0x84a5bd=a32_0x462d84,{options:_0x4647ab,args:_0x5778f8,tdx:_0x2e497e}=_0x2dccd5,_0x45fe6f=_0x5778f8[0x0]||_0x4647ab[_0x84a5bd(0xa2)];if(!_0x45fe6f)return showParentSegmentNotSetError(_0x84a5bd(0x18b)+_0x84a5bd(0x23a)),0x1;const _0x441c8c=resolveYamlFile(_0x45fe6f);if(!existsSync(_0x441c8c))return showFileNotFoundError(_0x441c8c,_0x45fe6f),0x1;let _0x18e16c;try{_0x18e16c=readFileSync(_0x441c8c,_0x84a5bd(0x15f));}catch(_0x5d40c2){const _0x40033c=_0x5d40c2 instanceof Error?_0x5d40c2[_0x84a5bd(0x184)]:String(_0x5d40c2);return console[_0x84a5bd(0x17d)]('Error\x20reading\x20file:\x20'+_0x40033c),0x1;}const _0x426203=createCommandSpinner(a32_0x10437a[_0x84a5bd(0x247)](_0x84a5bd(0x1a6)),{'verbose':_0x4647ab[_0x84a5bd(0x19e)]});_0x426203['start']();const _0x9df13b={'realtime':!![],'onProgress':_0x25a4e3=>{const _0x301c61=_0x84a5bd;_0x426203[_0x301c61(0xe7)]=formatProgressMessage(_0x25a4e3);}};let _0x12c384;try{_0x12c384=await _0x2e497e['segment']['validateParentYaml'](_0x18e16c,_0x9df13b),_0x426203[_0x84a5bd(0x26c)]();}catch(_0x4773a6){_0x426203[_0x84a5bd(0x26c)]();throw _0x4773a6;}console['error']('\x0a'+a32_0x10437a[_0x84a5bd(0xb5)](_0x84a5bd(0x98))+'\x20'+_0x12c384['name']),console[_0x84a5bd(0x17d)]('═'[_0x84a5bd(0x148)](0x3c)),displayRealtimeValidation(_0x12c384),console['error']('─'['repeat'](0x3c));if(_0x12c384[_0x84a5bd(0x25e)]['length']>0x0){console[_0x84a5bd(0x17d)]('\x0a'+a32_0x10437a[_0x84a5bd(0xbd)](_0x84a5bd(0xba)));for(const _0xa69a6 of _0x12c384[_0x84a5bd(0x25e)]){console[_0x84a5bd(0x17d)]('\x20\x20'+a32_0x10437a[_0x84a5bd(0xbd)]('•')+'\x20'+_0xa69a6);}}return _0x12c384['allValid']&&console['error']('\x0a'+a32_0x10437a[_0x84a5bd(0x96)]('✔')+_0x84a5bd(0x1b0)),_0x12c384[_0x84a5bd(0x241)]?0x0:0x1;}}export class PSRtJnListCommand extends BaseCommand{[a32_0x462d84(0xf9)]=a32_0x462d84(0x216);[a32_0x462d84(0x19c)]=a32_0x462d84(0x14a);async[a32_0x462d84(0x17f)](_0x46363c){const _0x2358e3=a32_0x462d84,{options:_0x15f239,args:_0x406297,tdx:_0x3c693c}=_0x46363c,_0x53f012=_0x406297[0x0]||_0x15f239[_0x2358e3(0xa2)];if(!_0x53f012)return showParentSegmentNotSetError(_0x2358e3(0x121)+_0x2358e3(0x1d3)),0x1;_0x15f239[_0x2358e3(0x19e)]&&(console[_0x2358e3(0x17d)](_0x2358e3(0x112)+_0x15f239[_0x2358e3(0xe6)]),console[_0x2358e3(0x17d)](_0x2358e3(0x261)+_0x53f012));const _0xeb12a9=await withSpinner(_0x2358e3(0x255)+_0x53f012+_0x2358e3(0x183),()=>_0x3c693c[_0x2358e3(0x139)]['resolveParentId'](_0x53f012),{'verbose':_0x15f239[_0x2358e3(0x19e)]}),_0x2bba74=_0xeb12a9[_0x2358e3(0x12d)],_0x4e3d55=await withSpinner(_0x2358e3(0x16f)+_0x53f012+_0x2358e3(0x183),()=>_0x3c693c[_0x2358e3(0x231)][_0x2358e3(0x1d5)](_0x2bba74),{'verbose':_0x15f239['verbose']}),_0x36e2aa=_0x4e3d55['data'];console[_0x2358e3(0x17d)](_0x2358e3(0x105)+_0x36e2aa['length']+'\x20RT\x20journey'+(_0x36e2aa[_0x2358e3(0x7b)]!==0x1?'s':''));if(_0x15f239[_0x2358e3(0x128)]===_0x2358e3(0x1ea)||_0x15f239[_0x2358e3(0x128)]===_0x2358e3(0x262))await handleSDKOutput(_0x36e2aa,_0x15f239);else{if(_0x36e2aa[_0x2358e3(0x7b)]===0x0)console[_0x2358e3(0x195)](_0x2358e3(0x25b));else for(const _0x5cddbf of _0x36e2aa){const _0x172a74=_0x5cddbf[_0x2358e3(0x249)]===_0x2358e3(0x93)?'🚀':'📝',_0x56cff8=_0x5cddbf[_0x2358e3(0x14c)]?a32_0x10437a[_0x2358e3(0x94)]('\x20(paused)'):'',_0x150574=a32_0x10437a[_0x2358e3(0x247)]('\x20('+_0x5cddbf['stageCount']+'\x20stage'+(_0x5cddbf[_0x2358e3(0xa6)]!==0x1?'s':'')+')');console['log'](_0x172a74+'\x20'+_0x5cddbf['name']+_0x56cff8+_0x150574);}}return 0x0;}}export class PSRtJnPauseCommand extends BaseCommand{[a32_0x462d84(0xf9)]=a32_0x462d84(0x202);[a32_0x462d84(0x19c)]='Pause\x20activations\x20in\x20an\x20RT\x20journey';async['execute'](_0x1066c3){const _0xc1cc0=a32_0x462d84,{options:_0x4f55e3,args:_0x4a4adb,tdx:_0x3352c0}=_0x1066c3,_0x476c89=_0x4a4adb[0x0];if(!_0x476c89)return console[_0xc1cc0(0x17d)](a32_0x10437a[_0xc1cc0(0xbd)](_0xc1cc0(0x188))),console['error'](_0xc1cc0(0x8b)),console['error'](a32_0x10437a[_0xc1cc0(0x247)](_0xc1cc0(0x92))),0x1;_0x4f55e3[_0xc1cc0(0x19e)]&&(console['error'](_0xc1cc0(0x112)+_0x4f55e3[_0xc1cc0(0xe6)]),console[_0xc1cc0(0x17d)]('RT\x20Journey\x20ID:\x20'+_0x476c89));const _0x44667f=await withSpinner(_0xc1cc0(0xbe)+_0x476c89+'\x27...',()=>_0x3352c0[_0xc1cc0(0x231)][_0xc1cc0(0x8e)](_0x476c89),{'verbose':_0x4f55e3[_0xc1cc0(0x19e)]}),_0x3291aa=_0x44667f['data'];console['error']('✔\x20Paused\x20activations\x20for\x20RT\x20journey\x20\x27'+_0x3291aa[_0xc1cc0(0xf9)]+'\x27');if(_0x4f55e3[_0xc1cc0(0x128)]===_0xc1cc0(0x1ea)||_0x4f55e3['format']===_0xc1cc0(0x262))await handleSDKOutput([_0x3291aa],_0x4f55e3);else{const _0x26ce1f=_0x3291aa['state']===_0xc1cc0(0x93)?'🚀':'📝',_0x39263b=_0x3291aa[_0xc1cc0(0x14c)]?a32_0x10437a[_0xc1cc0(0x94)](_0xc1cc0(0x17c)):'';console[_0xc1cc0(0x195)](_0x26ce1f+'\x20'+_0x3291aa['name']+_0x39263b);}return 0x0;}}export class PSRtJnResumeCommand extends BaseCommand{['name']=a32_0x462d84(0xed);[a32_0x462d84(0x19c)]='Resume\x20activations\x20in\x20an\x20RT\x20journey';async[a32_0x462d84(0x17f)](_0x53f36e){const _0x1fee7f=a32_0x462d84,{options:_0x54c355,args:_0x4fcd52,tdx:_0x31aa4b}=_0x53f36e,_0x5e057e=_0x4fcd52[0x0];if(!_0x5e057e)return console[_0x1fee7f(0x17d)](a32_0x10437a[_0x1fee7f(0xbd)](_0x1fee7f(0x188))),console[_0x1fee7f(0x17d)](_0x1fee7f(0x149)),console['error'](a32_0x10437a[_0x1fee7f(0x247)](_0x1fee7f(0x92))),0x1;_0x54c355[_0x1fee7f(0x19e)]&&(console['error'](_0x1fee7f(0x112)+_0x54c355[_0x1fee7f(0xe6)]),console[_0x1fee7f(0x17d)](_0x1fee7f(0x7d)+_0x5e057e));const _0x244ae9=await withSpinner('Resuming\x20activations\x20for\x20RT\x20journey\x20\x27'+_0x5e057e+_0x1fee7f(0x183),()=>_0x31aa4b[_0x1fee7f(0x231)][_0x1fee7f(0x10a)](_0x5e057e),{'verbose':_0x54c355[_0x1fee7f(0x19e)]}),_0x3eeeba=_0x244ae9[_0x1fee7f(0x12d)];console['error']('✔\x20Resumed\x20activations\x20for\x20RT\x20journey\x20\x27'+_0x3eeeba[_0x1fee7f(0xf9)]+'\x27');if(_0x54c355[_0x1fee7f(0x128)]==='json'||_0x54c355[_0x1fee7f(0x128)]==='jsonl')await handleSDKOutput([_0x3eeeba],_0x54c355);else{const _0x4bf9fd=_0x3eeeba[_0x1fee7f(0x249)]===_0x1fee7f(0x93)?'🚀':'📝',_0x42745b=_0x3eeeba[_0x1fee7f(0x14c)]?a32_0x10437a[_0x1fee7f(0x94)]('\x20(paused)'):'';console['log'](_0x4bf9fd+'\x20'+_0x3eeeba['name']+_0x42745b);}return 0x0;}}export class PSRtConfigVersionCommand extends BaseCommand{[a32_0x462d84(0xf9)]='ps:rt:configuration_versions';[a32_0x462d84(0x19c)]=a32_0x462d84(0x119);async[a32_0x462d84(0x17f)](_0x212e3c){const _0x5b9f04=a32_0x462d84,{options:_0x2a6131,args:_0x494f25,tdx:_0x221c81}=_0x212e3c,_0x14c6ef=_0x494f25[0x0]||_0x2a6131[_0x5b9f04(0xa2)];if(!_0x14c6ef)return showParentSegmentNotSetError('Usage:\x20tdx\x20ps\x20rt\x20configuration_versions\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Get\x20RT\x20config\x20version\x20(requires\x20context)\x0a'+_0x5b9f04(0x126)),0x1;_0x2a6131[_0x5b9f04(0x19e)]&&(console[_0x5b9f04(0x17d)]('Site:\x20'+_0x2a6131[_0x5b9f04(0xe6)]),console[_0x5b9f04(0x17d)](_0x5b9f04(0x261)+_0x14c6ef));const _0xa5946a=await withSpinner(_0x5b9f04(0x255)+_0x14c6ef+_0x5b9f04(0x183),()=>_0x221c81['segment'][_0x5b9f04(0xe2)](_0x14c6ef),{'verbose':_0x2a6131[_0x5b9f04(0x19e)]}),_0x379852=_0xa5946a[_0x5b9f04(0x12d)],_0x460e35=await withSpinner('Getting\x20RT\x20configuration\x20version\x20for\x20\x27'+_0x14c6ef+_0x5b9f04(0x183),()=>_0x221c81[_0x5b9f04(0x231)][_0x5b9f04(0xec)](_0x379852),{'verbose':_0x2a6131[_0x5b9f04(0x19e)]}),_0x3ce96b=_0x460e35[_0x5b9f04(0x12d)];return console['error'](_0x5b9f04(0x209)),_0x2a6131[_0x5b9f04(0x128)]===_0x5b9f04(0x1ea)||_0x2a6131[_0x5b9f04(0x128)]===_0x5b9f04(0x262)?await handleSDKOutput([_0x3ce96b],_0x2a6131):(console[_0x5b9f04(0x195)](_0x5b9f04(0x240)+_0x3ce96b['id']),console[_0x5b9f04(0x195)](_0x5b9f04(0x17b)+_0x3ce96b['audienceId']),console[_0x5b9f04(0x195)]('identifier:\x20'+_0x3ce96b[_0x5b9f04(0x22f)]),console['log'](_0x5b9f04(0x253)+_0x3ce96b[_0x5b9f04(0xea)]),console[_0x5b9f04(0x195)](_0x5b9f04(0xa1)+_0x3ce96b[_0x5b9f04(0x1f4)])),0x0;}}export class PSPzServiceListCommand extends BaseCommand{['name']=a32_0x462d84(0xfb);[a32_0x462d84(0x19c)]=a32_0x462d84(0x19a);async[a32_0x462d84(0x17f)](_0x188c96){const _0x2c0418=a32_0x462d84,{options:_0x25b89a,args:_0x191b97,tdx:_0x3de81b}=_0x188c96,_0x3e3a1f=_0x191b97[0x0]||_0x25b89a[_0x2c0418(0xa2)];if(!_0x3e3a1f)return showParentSegmentNotSetError(_0x2c0418(0x204)+'\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20service\x20list\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20List\x20PZ\x20services\x20for\x20specific\x20parent\x20segment'),0x1;const _0x265993=await withSpinner('Resolving\x20parent\x20segment\x20\x27'+_0x3e3a1f+_0x2c0418(0x183),()=>_0x3de81b[_0x2c0418(0x139)][_0x2c0418(0xe2)](_0x3e3a1f),{'verbose':_0x25b89a[_0x2c0418(0x19e)]}),_0x53c9fb=_0x265993[_0x2c0418(0x12d)],_0x1fbe31=await withSpinner('Listing\x20personalization\x20services\x20for\x20\x27'+_0x3e3a1f+'\x27...',()=>_0x3de81b[_0x2c0418(0x1e0)][_0x2c0418(0xd4)](_0x53c9fb),{'verbose':_0x25b89a[_0x2c0418(0x19e)]}),_0x21d024=_0x1fbe31[_0x2c0418(0x12d)];console[_0x2c0418(0x17d)](_0x2c0418(0x105)+_0x21d024[_0x2c0418(0x7b)]+'\x20personalization\x20service'+(_0x21d024[_0x2c0418(0x7b)]!==0x1?'s':''));if(_0x25b89a[_0x2c0418(0x128)]===_0x2c0418(0x1ea)||_0x25b89a['format']===_0x2c0418(0x262))await handleSDKOutput(_0x21d024,_0x25b89a);else{if(_0x21d024[_0x2c0418(0x7b)]===0x0)console['log'](_0x2c0418(0x20c)),console[_0x2c0418(0x17d)](a32_0x10437a[_0x2c0418(0x276)](_0x2c0418(0xe5)));else for(const _0x26ade0 of _0x21d024){console['log'](a32_0x10437a[_0x2c0418(0xb5)](_0x26ade0[_0x2c0418(0xf9)])+'\x20'+a32_0x10437a[_0x2c0418(0x247)](_0x2c0418(0x213)+_0x26ade0['id']+')'));_0x26ade0[_0x2c0418(0x19c)]&&console[_0x2c0418(0x195)]('\x20\x20'+a32_0x10437a[_0x2c0418(0x247)](_0x26ade0['description']));if(_0x26ade0[_0x2c0418(0x13b)]&&_0x26ade0[_0x2c0418(0x13b)][_0x2c0418(0x7b)]>0x0)for(const _0x1d6659 of _0x26ade0['tokens']){const _0x35e378=_0x1d6659[_0x2c0418(0x74)]?.[_0x2c0418(0x7b)]?_0x1d6659['allowedIps'][_0x2c0418(0x1bb)](',\x20'):_0x2c0418(0x12c);console['log']('\x20\x20'+a32_0x10437a[_0x2c0418(0x276)](_0x2c0418(0x11f))+'\x20'+_0x1d6659[_0x2c0418(0xf9)]+'\x20'+a32_0x10437a[_0x2c0418(0x247)](_0x2c0418(0x213)+_0x1d6659['id']+')')),console[_0x2c0418(0x195)](_0x2c0418(0x12b)+a32_0x10437a[_0x2c0418(0x247)](_0x2c0418(0x20e))+'\x20'+_0x35e378);}else console['log']('\x20\x20'+a32_0x10437a[_0x2c0418(0x247)]('no\x20tokens\x20configured'));}}return 0x0;}}export class PSPzServiceCreateCommand extends BaseCommand{[a32_0x462d84(0xf9)]=a32_0x462d84(0x86);[a32_0x462d84(0x19c)]=a32_0x462d84(0x9c);async[a32_0x462d84(0x17f)](_0x1db373){const _0x52da1f=a32_0x462d84,{options:_0x5b8a61,args:_0x4c0823,tdx:_0x1fef3c}=_0x1db373,_0x15665e=_0x5b8a61,_0x3702dc=_0x4c0823[0x0],_0xcb4b59=_0x4c0823[0x1]||_0x5b8a61['parentSegment'];if(!_0x3702dc)return console['error'](_0x52da1f(0x1b3)),console['error'](_0x52da1f(0x1ac)),console[_0x52da1f(0x17d)](_0x52da1f(0x1de)),0x1;if(!_0xcb4b59)return showParentSegmentNotSetError('Usage:\x20tdx\x20ps\x20pz\x20service\x20create\x20<name>\x20[parent_segment]\x0a'+_0x52da1f(0x1de)),0x1;const _0x35bf10=await withSpinner(_0x52da1f(0x255)+_0xcb4b59+'\x27...',()=>_0x1fef3c[_0x52da1f(0x139)]['resolveParentId'](_0xcb4b59),{'verbose':_0x5b8a61[_0x52da1f(0x19e)]}),_0x23ad8e=_0x35bf10['data'],_0x2f4b3e={'name':_0x3702dc,'description':_0x15665e['description'],'public':_0x15665e['public']},_0x4bf9a9=await withSpinner('Creating\x20personalization\x20service\x20\x27'+_0x3702dc+'\x27...',()=>_0x1fef3c[_0x52da1f(0x1e0)][_0x52da1f(0x1ab)](_0x23ad8e,_0x2f4b3e),{'verbose':_0x5b8a61[_0x52da1f(0x19e)]}),_0xe1441a=_0x4bf9a9[_0x52da1f(0x12d)];return console['error'](_0x52da1f(0x1a1)+_0xe1441a[_0x52da1f(0xf9)]+_0x52da1f(0x71)+_0xe1441a['id']),await handleSDKOutput([_0xe1441a],_0x5b8a61),0x0;}}export class PSPzServiceShowCommand extends BaseCommand{[a32_0x462d84(0xf9)]=a32_0x462d84(0x12a);[a32_0x462d84(0x19c)]=a32_0x462d84(0x15b);async[a32_0x462d84(0x17f)](_0x2b56c6){const _0x2ce5e7=a32_0x462d84,{options:_0x3ecd4c,args:_0x465397,tdx:_0x3f65fa}=_0x2b56c6,_0xf7230e=_0x465397[0x0],_0x340a60=_0x465397[0x1]||_0x3ecd4c['parentSegment'];if(!_0xf7230e)return console[_0x2ce5e7(0x17d)](_0x2ce5e7(0x91)),console[_0x2ce5e7(0x17d)](_0x2ce5e7(0x137)),console[_0x2ce5e7(0x17d)](_0x2ce5e7(0x136)),0x1;if(!_0x340a60)return showParentSegmentNotSetError('Usage:\x20tdx\x20ps\x20pz\x20service\x20show\x20<service_id>\x20[parent_segment]\x0a'+'\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20service\x20show\x20<service_id>\x20\x20#\x20Uses\x20context'),0x1;const _0x5c7dbe=await withSpinner(_0x2ce5e7(0x255)+_0x340a60+_0x2ce5e7(0x183),()=>_0x3f65fa[_0x2ce5e7(0x139)][_0x2ce5e7(0xe2)](_0x340a60),{'verbose':_0x3ecd4c[_0x2ce5e7(0x19e)]}),_0x30e31f=_0x5c7dbe[_0x2ce5e7(0x12d)],_0xb10a9f=await withSpinner(_0x2ce5e7(0x14b)+_0xf7230e+_0x2ce5e7(0x183),()=>_0x3f65fa[_0x2ce5e7(0x1e0)][_0x2ce5e7(0x24a)](_0x30e31f,_0xf7230e),{'verbose':_0x3ecd4c[_0x2ce5e7(0x19e)]}),_0x1c1db5=_0xb10a9f['data'];if(_0x3ecd4c['json']||_0x3ecd4c[_0x2ce5e7(0x262)])await handleSDKOutput([_0x1c1db5],_0x3ecd4c);else{console[_0x2ce5e7(0x195)](a32_0x10437a[_0x2ce5e7(0xb5)](_0x1c1db5[_0x2ce5e7(0xf9)])+'\x20'+a32_0x10437a[_0x2ce5e7(0x247)](_0x2ce5e7(0x213)+_0x1c1db5['id']+')'));_0x1c1db5[_0x2ce5e7(0x19c)]&&console[_0x2ce5e7(0x195)]('\x20\x20'+a32_0x10437a[_0x2ce5e7(0x247)](_0x1c1db5['description']));console[_0x2ce5e7(0x195)]('\x20\x20'+a32_0x10437a[_0x2ce5e7(0x276)](_0x2ce5e7(0x153))+'\x20'+(_0x1c1db5['public']?_0x2ce5e7(0x19f):'no'));if(_0x1c1db5['tokens']&&_0x1c1db5[_0x2ce5e7(0x13b)][_0x2ce5e7(0x7b)]>0x0)for(const _0x2f8de3 of _0x1c1db5[_0x2ce5e7(0x13b)]){const _0x273967=_0x2f8de3[_0x2ce5e7(0x74)]?.[_0x2ce5e7(0x7b)]?_0x2f8de3['allowedIps']['join'](',\x20'):_0x2ce5e7(0x12c);console[_0x2ce5e7(0x195)]('\x20\x20'+a32_0x10437a['cyan'](_0x2ce5e7(0x11f))+'\x20'+_0x2f8de3['name']+'\x20'+a32_0x10437a['dim'](_0x2ce5e7(0x213)+_0x2f8de3['id']+')')),console[_0x2ce5e7(0x195)](_0x2ce5e7(0x12b)+a32_0x10437a['dim'](_0x2ce5e7(0x20e))+'\x20'+_0x273967);}else console['log']('\x20\x20'+a32_0x10437a[_0x2ce5e7(0x247)]('no\x20tokens\x20configured'));}return 0x0;}}export class PSPzServiceDeleteCommand extends BaseCommand{[a32_0x462d84(0xf9)]=a32_0x462d84(0x72);[a32_0x462d84(0x19c)]=a32_0x462d84(0x20f);async['execute'](_0x35a29f){const _0x55d375=a32_0x462d84,{options:_0x46f00e,args:_0x4ab4ae,tdx:_0x38cfdf}=_0x35a29f,_0x2af5df=_0x4ab4ae[0x0],_0x5eafdf=_0x4ab4ae[0x1]||_0x46f00e[_0x55d375(0xa2)];if(!_0x2af5df)return console[_0x55d375(0x17d)](_0x55d375(0x91)),console[_0x55d375(0x17d)](_0x55d375(0x25c)),console['error'](_0x55d375(0x163)),0x1;if(!_0x5eafdf)return showParentSegmentNotSetError(_0x55d375(0x1cd)+_0x55d375(0x163)),0x1;const _0x19809c=await withSpinner(_0x55d375(0x255)+_0x5eafdf+_0x55d375(0x183),()=>_0x38cfdf[_0x55d375(0x139)][_0x55d375(0xe2)](_0x5eafdf),{'verbose':_0x46f00e[_0x55d375(0x19e)]}),_0x2d07a3=_0x19809c[_0x55d375(0x12d)];return await withSpinner(_0x55d375(0x238)+_0x2af5df+_0x55d375(0x183),()=>_0x38cfdf[_0x55d375(0x1e0)]['delete'](_0x2d07a3,_0x2af5df),{'verbose':_0x46f00e['verbose']}),console['error']('✔\x20Deleted\x20personalization\x20service\x20\x27'+_0x2af5df+'\x27'),0x0;}}export class PSPzServiceUpdateCommand extends BaseCommand{[a32_0x462d84(0xf9)]='ps:pz:service:update';[a32_0x462d84(0x19c)]=a32_0x462d84(0x140);async[a32_0x462d84(0x17f)](_0x43a4f7){const _0x4004b8=a32_0x462d84,{options:_0x1b4663,args:_0x3b1840,tdx:_0x388e95}=_0x43a4f7,_0x28a9e5=_0x1b4663,_0x35f0ce=_0x3b1840[0x0],_0x7b226f=_0x3b1840[0x1]||_0x1b4663[_0x4004b8(0xa2)];if(!_0x35f0ce)return console['error'](_0x4004b8(0x91)),console[_0x4004b8(0x17d)](_0x4004b8(0x75)),console[_0x4004b8(0x17d)](_0x4004b8(0x24c)),0x1;if(!_0x28a9e5[_0x4004b8(0xf9)])return console[_0x4004b8(0x17d)](_0x4004b8(0xf2)),console['error'](_0x4004b8(0x75)),0x1;if(!_0x7b226f)return showParentSegmentNotSetError(_0x4004b8(0x1d2)+_0x4004b8(0x24c)),0x1;const _0xf73689=await withSpinner(_0x4004b8(0x255)+_0x7b226f+_0x4004b8(0x183),()=>_0x388e95['segment']['resolveParentId'](_0x7b226f),{'verbose':_0x1b4663[_0x4004b8(0x19e)]}),_0x534257=_0xf73689['data'],_0x1ebd09={'name':_0x28a9e5['name']};_0x28a9e5[_0x4004b8(0x19c)]!==undefined&&(_0x1ebd09[_0x4004b8(0x19c)]=_0x28a9e5['description']);const _0x4bd021=await withSpinner('Updating\x20personalization\x20service\x20\x27'+_0x35f0ce+_0x4004b8(0x183),()=>_0x388e95[_0x4004b8(0x1e0)][_0x4004b8(0x1a4)](_0x534257,_0x35f0ce,_0x1ebd09),{'verbose':_0x1b4663[_0x4004b8(0x19e)]}),_0x5cd820=_0x4bd021['data'];return console['error'](_0x4004b8(0xb2)+_0x5cd820[_0x4004b8(0xf9)]+'\x27'),await handleSDKOutput([_0x5cd820],_0x1b4663),0x0;}}export class PSPzServiceTokenCreateCommand extends BaseCommand{[a32_0x462d84(0xf9)]='ps:pz:service:token:create';['description']=a32_0x462d84(0xd8);async['execute'](_0x1fbae9){const _0x54b23b=a32_0x462d84,{options:_0x4c30db,args:_0x2bbc51,tdx:_0x587c3b}=_0x1fbae9,_0x24176f=_0x4c30db,_0x584fa1=_0x2bbc51[0x0],_0x5494b5=_0x2bbc51[0x1],_0x4d0013=_0x2bbc51[0x2]||_0x4c30db['parentSegment'];if(!_0x584fa1)return console[_0x54b23b(0x17d)](_0x54b23b(0xad)),console[_0x54b23b(0x17d)](_0x54b23b(0xac)),console['error']('\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20service\x20token\x20create\x20<name>\x20<service_id>\x20\x20#\x20Uses\x20context'),0x1;if(!_0x5494b5)return console[_0x54b23b(0x17d)](_0x54b23b(0x91)),console[_0x54b23b(0x17d)]('Usage:\x20tdx\x20ps\x20pz\x20service\x20token\x20create\x20<name>\x20<service_id>\x20[parent_segment]'),console[_0x54b23b(0x17d)](_0x54b23b(0x215)),0x1;if(!_0x4d0013)return showParentSegmentNotSetError(_0x54b23b(0x1d8)+_0x54b23b(0x215)),0x1;const _0x521e08=await withSpinner(_0x54b23b(0x255)+_0x4d0013+_0x54b23b(0x183),()=>_0x587c3b[_0x54b23b(0x139)][_0x54b23b(0xe2)](_0x4d0013),{'verbose':_0x4c30db[_0x54b23b(0x19e)]}),_0x299b49=_0x521e08[_0x54b23b(0x12d)],_0x168614={'name':_0x584fa1};_0x24176f[_0x54b23b(0x74)]&&(_0x168614[_0x54b23b(0x74)]=_0x24176f[_0x54b23b(0x74)][_0x54b23b(0x1c3)](',')[_0x54b23b(0xa5)](_0x12538b=>_0x12538b['trim']()));_0x24176f[_0x54b23b(0x19c)]&&(_0x168614[_0x54b23b(0x19c)]=_0x24176f[_0x54b23b(0x19c)]);const _0x154a2a=await withSpinner('Creating\x20token\x20\x27'+_0x584fa1+_0x54b23b(0x248)+_0x5494b5+_0x54b23b(0x183),()=>_0x587c3b[_0x54b23b(0x1e0)][_0x54b23b(0xc5)](_0x299b49,_0x5494b5,_0x168614),{'verbose':_0x4c30db['verbose']}),_0x1c6720=_0x154a2a[_0x54b23b(0x12d)];return console['error'](_0x54b23b(0x235)+_0x1c6720[_0x54b23b(0xf9)]+'\x27\x20with\x20ID:\x20'+_0x1c6720['id']),_0x1c6720[_0x54b23b(0x1a8)]&&(console[_0x54b23b(0x17d)](a32_0x10437a[_0x54b23b(0x94)]('\x0a⚠\x20Save\x20this\x20token\x20value\x20-\x20it\x20will\x20not\x20be\x20shown\x20again:')),console['error'](a32_0x10437a[_0x54b23b(0x276)](_0x1c6720[_0x54b23b(0x1a8)])),console[_0x54b23b(0x17d)]('')),await handleSDKOutput([_0x1c6720],_0x4c30db),0x0;}}export class PSPzServiceTokenDeleteCommand extends BaseCommand{[a32_0x462d84(0xf9)]='ps:pz:service:token:delete';[a32_0x462d84(0x19c)]=a32_0x462d84(0x270);async[a32_0x462d84(0x17f)](_0x10d6c0){const _0x4167b2=a32_0x462d84,{options:_0x249421,args:_0x288176,tdx:_0x5744d7}=_0x10d6c0,_0x2beb80=_0x288176[0x0],_0x10a8d5=_0x288176[0x1]||_0x249421[_0x4167b2(0xa2)];if(!_0x2beb80)return console[_0x4167b2(0x17d)](_0x4167b2(0x12e)),console[_0x4167b2(0x17d)](_0x4167b2(0x232)),console['error'](_0x4167b2(0x1fe)),0x1;if(!_0x10a8d5)return showParentSegmentNotSetError('Usage:\x20tdx\x20ps\x20pz\x20service\x20token\x20delete\x20<token_id>\x20[parent_segment]\x0a'+_0x4167b2(0x1fe)),0x1;const _0x52a9a4=await withSpinner(_0x4167b2(0x255)+_0x10a8d5+_0x4167b2(0x183),()=>_0x5744d7['segment']['resolveParentId'](_0x10a8d5),{'verbose':_0x249421['verbose']}),_0x52b158=_0x52a9a4[_0x4167b2(0x12d)],_0x287df6=await withSpinner(_0x4167b2(0x1ff),()=>_0x5744d7[_0x4167b2(0x1e0)][_0x4167b2(0xd4)](_0x52b158),{'verbose':_0x249421[_0x4167b2(0x19e)]}),_0x14e7b3=_0x287df6['data'];let _0x3c8bcf;for(const _0x46923e of _0x14e7b3){if(_0x46923e[_0x4167b2(0x13b)]?.[_0x4167b2(0xc6)](_0x385ee2=>_0x385ee2['id']===_0x2beb80)){_0x3c8bcf=_0x46923e['id'];break;}}if(!_0x3c8bcf)return console['error']('Error:\x20Token\x20\x27'+_0x2beb80+_0x4167b2(0x8d)),0x1;const _0x34462f=await withSpinner(_0x4167b2(0xeb)+_0x2beb80+_0x4167b2(0x183),()=>_0x5744d7['personalization'][_0x4167b2(0x116)](_0x52b158,_0x3c8bcf,_0x2beb80),{'verbose':_0x249421[_0x4167b2(0x19e)]}),_0x4e1ab2=_0x34462f[_0x4167b2(0x12d)];return console[_0x4167b2(0x17d)](_0x4167b2(0x144)+(_0x4e1ab2[_0x4167b2(0xf9)]||_0x2beb80)+'\x27'),await handleSDKOutput([_0x4e1ab2],_0x249421),0x0;}}export class PSPzListCommand extends BaseCommand{['name']=a32_0x462d84(0x222);[a32_0x462d84(0x19c)]=a32_0x462d84(0x146);async[a32_0x462d84(0x17f)](_0x108cd3){const _0x1c4c43=a32_0x462d84,{options:_0x12cc76,args:_0x5550b2,tdx:_0x3405a9}=_0x108cd3,_0x3a1935=_0x5550b2[0x0]||_0x12cc76[_0x1c4c43(0xa2)];if(!_0x3a1935)return showParentSegmentNotSetError('Usage:\x20tdx\x20ps\x20pz\x20list\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20List\x20personalizations\x20(requires\x20context)\x0a'+'\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20list\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20List\x20personalizations\x20for\x20specific\x20parent\x20segment'),0x1;const _0x2c94bc=await withSpinner('Resolving\x20parent\x20segment\x20\x27'+_0x3a1935+'\x27...',()=>_0x3405a9[_0x1c4c43(0x139)][_0x1c4c43(0xe2)](_0x3a1935),{'verbose':_0x12cc76[_0x1c4c43(0x19e)]}),_0x1688ec=_0x2c94bc[_0x1c4c43(0x12d)],_0x38f526=await withSpinner('Listing\x20personalizations\x20for\x20\x27'+_0x3a1935+_0x1c4c43(0x183),()=>_0x3405a9[_0x1c4c43(0x1e0)][_0x1c4c43(0x100)](_0x1688ec),{'verbose':_0x12cc76[_0x1c4c43(0x19e)]}),_0x483a3e=_0x38f526[_0x1c4c43(0x12d)];console['error'](_0x1c4c43(0x105)+_0x483a3e[_0x1c4c43(0x7b)]+'\x20personalization'+(_0x483a3e['length']!==0x1?'s':''));if(_0x12cc76['format']===_0x1c4c43(0x1ea)||_0x12cc76['format']==='jsonl')await handleSDKOutput(_0x483a3e,_0x12cc76);else{if(_0x483a3e[_0x1c4c43(0x7b)]===0x0)console[_0x1c4c43(0x195)](_0x1c4c43(0xca));else for(const _0x466a7a of _0x483a3e){console[_0x1c4c43(0x195)](a32_0x10437a[_0x1c4c43(0xb5)](_0x466a7a['name'])+'\x20'+a32_0x10437a['dim']('(id:\x20'+_0x466a7a['id']+')'));_0x466a7a[_0x1c4c43(0x19c)]&&console['log']('\x20\x20'+a32_0x10437a['dim'](_0x466a7a[_0x1c4c43(0x19c)]));const _0x3f366b=_0x466a7a[_0x1c4c43(0x22a)]?.[_0x1c4c43(0x7b)]||0x0;console[_0x1c4c43(0x195)]('\x20\x20'+a32_0x10437a['cyan'](_0x1c4c43(0x1c0))+'\x20'+_0x3f366b);if(_0x466a7a[_0x1c4c43(0x22a)]&&_0x466a7a[_0x1c4c43(0x22a)][_0x1c4c43(0x7b)]>0x0)for(const _0x5a9f6b of _0x466a7a['sections']){console[_0x1c4c43(0x195)]('\x20\x20\x20\x20-\x20'+_0x5a9f6b[_0x1c4c43(0xf9)]);}}}return 0x0;}}function a32_0x43b6(){const _0x4bce2d=['status','Usage:\x20tdx\x20ps\x20preview\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Preview\x20(requires\x20context)\x0a','Name:\x20','Validate\x20RT\x202.0\x20configuration\x20from\x20parent\x20segment\x20YAML','/attempt/','segment:parent:list','Error:\x20Personalization\x20ID\x20is\x20required','\x22,\x0a\x20\x20\x20\x20\x20\x20\x22columns\x22:\x20','Listing\x20parent\x20segments...','Push\x20parent\x20segment\x20configuration\x20from\x20YAML\x20file','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20service\x20token\x20delete\x20<token_id>\x20\x20#\x20Uses\x20context','Finding\x20service\x20for\x20token...','✔\x20Created\x20personalization\x20\x27','-1d','ps:rt:jn:pause','Usage:\x20tdx\x20parent-segment\x20preview\x20<name>\x20<option>\x0a','Usage:\x20tdx\x20ps\x20pz\x20service\x20list\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20List\x20PZ\x20services\x20(requires\x20context)\x0a','indexOf','realtime_enabled','Deleting\x20personalization\x20\x27','1691294SrTGzz','✔\x20Retrieved\x20RT\x20configuration\x20version','entryCriteria:','customerGroup','No\x20personalization\x20services\x20configured','\x20Configuration\x20is\x20valid','allowed\x20IPs:','Delete\x20a\x20personalization\x20service','foreignKey','Show\x20a\x20specific\x20realtime\x20personalization','endsWith','(id:\x20','Database:\x20','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20service\x20token\x20create\x20<name>\x20<service_id>\x20\x20#\x20Uses\x20context','ps:rt:jn:list','table','Listing\x20RT-enabled\x20parent\x20segments...','\x20\x20--enriched\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Show\x20sample\x20enriched\x20master\x20data\x0a','getOutputDatabaseName','ps:rt:validate','win32','Schema\x20saved\x20to\x20','createPersonalization','number','Apply\x20changes\x20to\x20\x27','tdx\x20ps\x20push\x20','ps:pz:list','toLocaleString','Error:\x20No\x20attributes\x20defined\x20in\x20configuration','Usage:\x20tdx\x20ps\x20push\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Push\x20(requires\x20context)\x0a','Usage:\x20tdx\x20ps\x20validate\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Validate\x20(requires\x20context)\x0a','\x20parent\x20segment','replace','\x5c$&','sections','Create\x20a\x20realtime\x20personalization\x20entity','page_view','double','Validate:','identifier','\x20=\x20','realtime','Usage:\x20tdx\x20ps\x20pz\x20service\x20token\x20delete\x20<token_id>\x20[parent_segment]','Behavior:','output','✔\x20Created\x20token\x20\x27','getBehaviorNames','scheduleOption','Deleting\x20personalization\x20service\x20\x27','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20validate\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Validate\x20specific\x20parent\x20segment\x0a\x0a','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20rt\x20validate\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Validate\x20RT\x20config\x20for\x20specific\x20parent\x20segment','patchPersonalization','column_type','⚡\x20Not\x20enabled','FINISHED','/\x20directories\x20exist.','id:\x20','allValid','My\x20Service','unref','deletePersonalization','YAML\x20file:\x20','personalizationServices','dim','\x27\x20for\x20service\x20\x27','state','get','totalEvents','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20service\x20update\x20<service_id>\x20--name\x20<name>\x20\x20#\x20Uses\x20context','segment:parent:pull','pullParentYaml','addAttributesFile','To\x20view\x20sample\x20data:','⚡\x20Enabled','Preview\x20sample\x20data\x20from\x20parent\x20segment\x20YAML\x20configuration','eventKind:\x20','columns','Resolving\x20parent\x20segment\x20\x27','Fetching\x20sample\x20data...','Fetching\x20behavior\x20list...','parent_segments','includeSensitive','pushParentYaml','No\x20RT\x20journeys\x20found','Usage:\x20tdx\x20ps\x20pz\x20service\x20delete\x20<service_id>\x20[parent_segment]','type','errors','Columns:','\x20\x20\x20Use\x20`tdx\x20segment\x20parent\x20push\x20<file.yml>`\x20instead\x20for\x20better\x20configuration\x20management.\x0a','Parent\x20segment:\x20','jsonl','toLowerCase','\x20\x20\x20\x20\x20\x20\x20Pass\x20null\x20to\x20place\x20in\x20the\x20root\x20folder.','Get\x20SQL\x20query\x20for\x20parent\x20segment','4sHjMaZ','\x0a)\x20AS\x20segment_query\x0aLIMIT\x20','Customers:','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20init\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Add\x20PZ\x20template\x20for\x20specific\x20parent\x20segment','updateParent','addAttributes','stop','using\x20the\x20default\x20path:\x20','segment:parent:sql','Usage:\x20tdx\x20ps\x20pz\x20create\x20--name\x20<name>\x20--description\x20<desc>\x20--folder-id\x20<id>\x20[options]','Delete\x20a\x20token\x20from\x20a\x20personalization\x20service','✔\x20Query\x20completed:\x20Processed\x20','/app/workflows/','\x20true','Error:\x20File\x20not\x20found:\x20','.yml','cyan','Run\x20parent\x20segment\x20workflow\x20(pushes\x20YAML\x20if\x20exists)','\x0aNo\x20sample\x20data\x20available','Preview:','The\x20-u\x20flag\x20sets\x20the\x20context\x20to\x20the\x20pulled\x20segment,\x20which\x20requires','⚠️\x20\x20personalization_services\x20section\x20already\x20exists\x20in\x20','last_page_viewed','string','Audience\x20ID:','Updating','\x20service','Found\x20YAML\x20file:\x20','behavior_','\x27\x20with\x20ID:\x20','ps:pz:service:delete','\x27\x20and\x20run\x20workflow?','allowedIps','Usage:\x20tdx\x20ps\x20pz\x20service\x20update\x20<service_id>\x20[parent_segment]\x20--name\x20<name>\x20[--description\x20<text>]','scheduleType','SELECT\x20*\x20FROM\x20','workflowId','\x20\x20-o,\x20--output\x20<file>\x20\x20Output\x20file\x20path','{\x0a\x20\x20\x22database\x22:\x20\x22','length','enriched','RT\x20Journey\x20ID:\x20','✔\x20Updated\x20parent\x20segment\x20\x27','\x20\x20-w,\x20--web\x20\x20Open\x20parent\x20segment\x20in\x20web\x20browser','\x0a\x20\x20},\x0a\x20\x20\x22behaviors\x22:\x20[\x0a','Events:','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20show\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Show\x20config\x20for\x20specific\x20parent\x20segment','327460DCmQKe','%)\x20','formatSchemaJson','ps:pz:service:create','keyEventId','Error\x20reading\x20file:\x20','Options:\x0a','darwin','Usage:\x20tdx\x20ps\x20rt\x20jn\x20pause_activations\x20<journeyId>\x0a','audienceId:','\x27\x20not\x20found\x20in\x20any\x20personalization\x20service','pauseJourney','\x20Saved\x20parent\x20segment\x20configuration\x20to\x20','To\x20cancel:','Error:\x20Service\x20ID\x20is\x20required','Tip:\x20Use\x20`tdx\x20ps\x20rt\x20jn\x20list\x20<parent_segment>`\x20to\x20find\x20journey\x20IDs','launched','yellow','`\x20to\x20download\x20the\x20configuration\x20first','green','\x20\x20Database:\x20','RT\x202.0\x20Validate:','\x20\x20Schema\x20not\x20available\x20(workflow\x20may\x20not\x20have\x20run\x20yet)','previewParentYaml','label','Create\x20a\x20personalization\x20service\x20for\x20a\x20parent\x20segment','\x20\x20--interval\x20<range>\x20\x20\x20TD_INTERVAL\x20time\x20range\x20for\x20behaviors\x20(default:\x20-1d)','\x20\x201.\x20Edit\x20','interval','attribute','status:\x20','parentSegment','platform','addBehaviorsFile','map','stageCount','isDirectory','toFixed','displayMasterInfo','\x20[Job\x20ID:\x20','Error:\x20--name\x20is\x20required\x20(or\x20use\x20--file\x20for\x20a\x20full\x20request\x20body)','Usage:\x20tdx\x20ps\x20pz\x20service\x20token\x20create\x20<name>\x20<service_id>\x20[parent_segment]','Error:\x20Token\x20name\x20is\x20required','setJobId','elapsedTimeMillis','Error\x20parsing\x20YAML:\x20','events','✔\x20Updated\x20personalization\x20service\x20\x27','✔\x20Updated\x20personalization\x20\x27','Show\x20parent\x20segment\x20details','bold','Usage:\x20tdx\x20ps\x20pz\x20show\x20<personalization_id>','ps:pz:delete','displayPreviewHints','\x20\x20\x20\x20{\x0a\x20\x20\x20\x20\x20\x20\x22table\x22:\x20\x22','Errors:','Created','\x20parent\x20segment\x20\x27','red','Pausing\x20activations\x20for\x20RT\x20journey\x20\x27','schemaError','Use\x20`tdx\x20ps\x20folder\x20list\x20<name>`\x20to\x20find\x20the\x20folder\x20ID,\x20then\x20add:','runParent','workflowSessionId','dirname','Usage:\x20tdx\x20ps\x20run\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Run\x20(requires\x20context)\x0a','createToken','some','payload:','3185YAHATo','\x27\x20(id:\x20','No\x20personalizations\x20configured','\x20is\x20already\x20up\x20to\x20date','Behaviors','98elzzLH','createdAt','Usage:\x20tdx\x20ps\x20pull\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Pull\x20(requires\x20context)\x0a','\x22,\x0a\x20\x20\x22parent_id\x22:\x20\x22','trim','xdg-open','Tip:\x20Use\x20-u\x20without\x20-o,\x20or\x20-o\x20without\x20-u','list','\x27\x20is\x20up\x20to\x20date','Create\x20parent\x20segment\x20\x27','\x20kill','Create\x20a\x20token\x20for\x20a\x20personalization\x20service','stitchingKeys','\x20+\x20[','Available\x20behaviors:','Error:\x20--database\x20and\x20--table\x20are\x20required','\x20field','behaviors','segment:parent:desc','Attempt:','jobId','resolveParentId','\x20\x20--attribute\x20[name]\x20\x20\x20Show\x20only\x20attributes\x20(or\x20specific\x20one)\x0a','\x20\x20\x20\x20-\x20','\x0aTip:\x20Run\x20`tdx\x20ps\x20pz\x20service\x20init`\x20to\x20add\x20a\x20template\x20personalization\x20section\x20to\x20your\x20YAML','site','text','Personalization:','segment:parent:fields','eventKind','Deleting\x20token\x20\x27','getCurrentConfigVersion','ps:rt:jn:resume','created:','audienceId','sourceTableError','matchedCount','Error:\x20--name\x20is\x20required','\x20tdx\x20wf\x20attempt\x20','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20push\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Push\x20specific\x20parent\x20segment','\x20service(s)\x20configured','\x20behavior\x20tables\x20not\x20yet\x20generated\x20(workflow\x20may\x20not\x20have\x20run)','null','file','name','\x20\x20\x20\x20\x20\x20','ps:pz:service:list','/{name}.yml\x0a','Update\x20existing\x20parent\x20segment\x20(audience)\x20[DEPRECATED]','Fetching\x20customers\x20schema...','idStitching','listPersonalizations','folder-segment','List\x20parent\x20segments','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pull\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Pull\x20specific\x20parent\x20segment','Output\x20file:\x20','✔\x20Found\x20','sampleData','joinKey','segment:parent:show','master','resumeJourney','\x20--enriched','validateParentYaml','valid','78daQGYx','displayValidateResults','\x0a⚠️\x20\x20Both\x20','Enriched:','Site:\x20','\x20to\x20push\x20the\x20configuration','all','varchar','deleteToken','entryCriteria','Join:','Get\x20current\x20RT\x20configuration\x20version\x20status','/\x20directory.\x0a','getParentSQL','Session:','Show\x20parent\x20segment\x20schema\x20(column\x20types)','coveragePercent','token:','realtime:','Usage:\x20tdx\x20ps\x20rt\x20jn\x20list\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20List\x20RT\x20journeys\x20(requires\x20context)\x0a','rowCount','getParentFull','localeCompare','Fetching\x20parent\x20segment\x20\x27','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20rt\x20configuration_versions\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Get\x20RT\x20config\x20version\x20for\x20specific\x20parent\x20segment','Usage:\x20tdx\x20segment\x20parent\x20create\x20<name>\x20--database\x20<db>\x20--table\x20<table>','format','behavior','ps:pz:service:show','\x20\x20\x20\x20','any','data','Error:\x20Token\x20ID\x20is\x20required','getPersonalization','Default','\x20\x20\x20See:\x20tdx\x20segment\x20parent\x20pull\x20--help\x0a','\x20Added\x20RT\x202.0\x20template\x20section','segment:parent:run','reduce','displayRealtimeInfo','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20service\x20show\x20<service_id>\x20\x20#\x20Uses\x20context','Usage:\x20tdx\x20ps\x20pz\x20service\x20show\x20<service_id>\x20[parent_segment]','56119hhXmbb','segment','\x20\x20--behavior\x20[name]\x20\x20\x20\x20Show\x20only\x20behaviors\x20(or\x20specific\x20one)\x0a','tokens','/\x20and\x20','Overwrite\x20\x27','\x20Context\x20set:\x20','timezone','Update\x20a\x20personalization\x20service\x20name\x20and/or\x20description','✔\x20Created\x20parent\x20segment\x20\x27','stats','\x20RT-enabled\x20parent\x20segment','✔\x20Deleted\x20token\x20\x27','Error:\x20No\x20behaviors\x20defined\x20in\x20configuration','List\x20realtime\x20personalizations\x20for\x20a\x20parent\x20segment','✔\x20Renamed\x20directory\x20to\x20','repeat','Usage:\x20tdx\x20ps\x20rt\x20jn\x20resume_activations\x20<journeyId>\x0a','List\x20RT\x20journeys','Fetching\x20personalization\x20service\x20\x27','paused','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20create\x20--file\x20<path>','open','Use\x20-y\x20or\x20--yes\x20flag\x20to\x20apply\x20changes\x20without\x20confirmation','attributes','Error:\x20At\x20least\x20one\x20preview\x20option\x20required\x0a','\x0aChanges\x20to\x20\x27','public:','Listing\x20RT-enabled\x20parent\x20segments\x20matching\x20\x27','\x20--attribute\x20\x22<name>\x22','displayBehaviorsStats','Executing\x20parent\x20segment\x20query...','Usage:\x20tdx\x20ps\x20fields\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Show\x20fields\x20(requires\x20context)\x0a','apply','Update\x20a\x20realtime\x20personalization\x20entity','Show\x20personalization\x20service\x20details','\x22,\x20\x22type\x22:\x20\x22','parentFolder','Error:\x20--description\x20is\x20required\x20(or\x20use\x20--file\x20for\x20a\x20full\x20request\x20body)','utf-8','parent_segment','Usage:\x20tdx\x20ps\x20show\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Show\x20config\x20(requires\x20context)\x0a','database','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20service\x20delete\x20<service_id>\x20\x20#\x20Uses\x20context','\x20\x20No\x20sample\x20data\x20available','\x20\x202.\x20Run\x20','personalization_services','run','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20preview\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Preview\x20specific\x20parent\x20segment\x0a\x0a','Updated','Create\x20new\x20parent\x20segment\x20(audience)\x20[DEPRECATED]','\x20configured','\x20\x20--behavior\x20<name>\x20\x20\x20\x20Show\x20sample\x20data\x20for\x20specific\x20behavior','Usage:\x20tdx\x20ps\x20sql\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Show\x20SQL\x20(requires\x20context)\x0a','Error:\x20Parent\x20segment\x20name\x20is\x20required','Listing\x20RT\x20journeys\x20for\x20\x27','Pattern:\x20','Usage:\x20tdx\x20ps\x20view\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20View\x20(requires\x20context)\x0a','Creating\x20parent\x20segment\x20\x27','No\x20parent\x20segments\x20match\x20pattern:\x20','stringify','displayColumns','Add\x20template\x20personalization\x20section\x20to\x20parent\x20segment\x20YAML','\x0a⚠️\x20\x20DEPRECATED:\x20`tdx\x20segment\x20parent\x20create`\x20is\x20deprecated.\x0a','match','8MYHrNB','ps:pz:create','audienceId:\x20','\x20(paused)','error','\x0a✔\x20Workflow\x20started','execute','attributesFile','column','\x20\x20--master\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Show\x20sample\x20master\x20table\x20data','\x27...','message','\x20--interval\x20','displaySummary','Attribute:','Error:\x20RT\x20journey\x20ID\x20is\x20required\x0a','Usage:\x20tdx\x20ps\x20pz\x20patch\x20<id>\x20--name\x20<name>\x20--description\x20<desc>\x20[--sections\x20<json>]','listParents','Usage:\x20tdx\x20ps\x20rt\x20validate\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Validate\x20RT\x20config\x20(requires\x20context)\x0a','Error:\x20-u\x20(--use)\x20and\x20-o\x20(--output)\x20cannot\x20be\x20used\x20together\x0a','.yaml','primaryKey','\x20behaviors','Coverage:','displayAttributesStats','Error:','\x0aUsage:\x20tdx\x20ps\x20preview\x20','relationships','log','use','web','test','Getting\x20personalization\x20\x27','List\x20personalization\x20services\x20for\x20a\x20parent\x20segment','✔\x20No\x20changes\x20-\x20\x27','description','sort','verbose','yes','includeSensitive:','✔\x20Created\x20personalization\x20service\x20\x27','305997HFHgbv','segment:parent:view','patch','ps:pz:show','Validating\x20RT\x20configuration...','\x20\x20--enriched\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Show\x20sample\x20enriched\x20master\x20data','value','updated:','\x20--behavior\x20\x22<name>\x22','create','Usage:\x20tdx\x20ps\x20pz\x20service\x20create\x20<name>\x20[parent_segment]','displaySampleData','Usage:\x20tdx\x20ps\x20pz\x20delete\x20<personalization_id>','\x22\x20}','\x20RT\x20configuration\x20is\x20valid','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20view\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20View\x20specific\x20parent\x20segment\x0a\x0a','ps:rt:list','Error:\x20Service\x20name\x20is\x20required','✔\x20Deleted\x20personalization\x20\x27','createParent','Usage:\x20tdx\x20segment\x20parent\x20update\x20<name>\x20[options]','2437209edPGDY','\x20--behavior\x20\x22','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20run\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Run\x20specific\x20parent\x20segment','segment:parent:update','join','Analyzing\x20changes...','session','Attributes:','Join\x20on:','sections:','parent_id','✘\x20Failed\x20to\x20rename\x20directory:\x20','split','customers','ignore','Confirmation\x20required\x20but\x20running\x20in\x20non-interactive\x20mode','customerPercent','Personalization\x20service\x20description','start','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20patch\x20<id>\x20--file\x20<path>','.customers)','listFields','Usage:\x20tdx\x20ps\x20pz\x20service\x20delete\x20<service_id>\x20[parent_segment]\x0a','Aborted.','schemaValid','\x0a⚠️\x20\x20Migrating:\x20','/app/dw/parentSegments/','Usage:\x20tdx\x20ps\x20pz\x20service\x20update\x20<service_id>\x20[parent_segment]\x20--name\x20<name>\x20[--description\x20<text>]\x0a','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20rt\x20jn\x20list\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20List\x20RT\x20journeys\x20for\x20specific\x20parent\x20segment','\x20\x20Columns:\x20','listJourneys','Source:','population','Usage:\x20tdx\x20ps\x20pz\x20service\x20token\x20create\x20<name>\x20<service_id>\x20[parent_segment]\x0a','Next\x20steps:','keyEventId:','Master\x20Table','\x0aError:','parent_segment\x20is\x20not\x20set.\x20Use\x20`tdx\x20ps\x20use\x20<name>`\x20to\x20set\x20it.\x0a','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20pz\x20service\x20create\x20<name>\x20\x20#\x20Uses\x20context','\x20\x20\x20\x20\x20\x20\x20tdx\x20ps\x20sql\x20<name>\x20\x20\x20\x20\x20\x20\x20#\x20Show\x20SQL\x20for\x20specific\x20parent\x20segment','personalization','workflowAttemptId','Usage:\x20tdx\x20ps\x20pz\x20init\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20#\x20Add\x20PZ\x20template\x20(requires\x20context)\x0a','2398000FhaNDD','Master:','Creating','\x20total','tdx\x20ps\x20preview\x20','\x20\x20--master\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Show\x20sample\x20master\x20table\x20data\x0a','\x20Opening\x20','json','/\x20→\x20','\x0aNew\x20parent\x20segment\x20\x27','No\x20parent\x20segments\x20found','Attributes','Pull\x20parent\x20segment\x20configuration\x20to\x20YAML\x20file','folderId','Fetching\x20SQL\x20for\x20\x27','\x0a\x20\x20]\x0a}\x0a','\x0a⚠️\x20\x20DEPRECATED:\x20`tdx\x20segment\x20parent\x20update`\x20is\x20deprecated.\x0a'];a32_0x43b6=function(){return _0x4bce2d;};return a32_0x43b6();}export class PSPzShowCommand extends BaseCommand{[a32_0x462d84(0xf9)]=a32_0x462d84(0x1a5);[a32_0x462d84(0x19c)]=a32_0x462d84(0x211);async['execute'](_0x3f10fa){const _0x591891=a32_0x462d84,{options:_0x198af3,args:_0x3d0296,tdx:_0x498e55}=_0x3f10fa,_0x4bd218=_0x3d0296[0x0];if(!_0x4bd218)return console[_0x591891(0x17d)]('Error:\x20Personalization\x20ID\x20is\x20required'),console[_0x591891(0x17d)](_0x591891(0xb6)),0x1;const _0xa66f8f=await withSpinner(_0x591891(0x199)+_0x4bd218+_0x591891(0x183),()=>_0x498e55['personalization'][_0x591891(0x12f)](_0x4bd218),{'verbose':_0x198af3[_0x591891(0x19e)]}),_0xda2bcf=_0xa66f8f[_0x591891(0x12d)];console[_0x591891(0x17d)]('✔\x20Found\x20personalization\x20\x27'+_0xda2bcf['name']+'\x27');if(_0x198af3[_0x591891(0x128)]===_0x591891(0x1ea)||_0x198af3[_0x591891(0x128)]===_0x591891(0x262))await handleSDKOutput([_0xda2bcf],_0x198af3);else{console[_0x591891(0x195)](a32_0x10437a[_0x591891(0xb5)](_0xda2bcf['name'])+'\x20'+a32_0x10437a['dim'](_0x591891(0x213)+_0xda2bcf['id']+')'));_0xda2bcf['description']&&console['log']('\x20\x20'+a32_0x10437a[_0x591891(0x247)](_0xda2bcf[_0x591891(0x19c)]));_0xda2bcf[_0x591891(0xef)]&&console[_0x591891(0x195)]('\x20\x20'+a32_0x10437a[_0x591891(0x276)](_0x591891(0x8c))+'\x20'+_0xda2bcf[_0x591891(0xef)]);console[_0x591891(0x195)]('\x20\x20'+a32_0x10437a['cyan'](_0x591891(0xee))+'\x20'+_0xda2bcf[_0x591891(0xce)]),console['log']('\x20\x20'+a32_0x10437a[_0x591891(0x276)](_0x591891(0x1a9))+'\x20'+_0xda2bcf['updatedAt']);const _0x1db8ac=_0xda2bcf[_0x591891(0x22a)]?.[_0x591891(0x7b)]||0x0;console[_0x591891(0x195)]('\x20\x20'+a32_0x10437a['cyan']('sections:')+'\x20'+_0x1db8ac);if(_0xda2bcf[_0x591891(0x22a)]&&_0xda2bcf[_0x591891(0x22a)][_0x591891(0x7b)]>0x0)for(const _0xa11e47 of _0xda2bcf[_0x591891(0x22a)]){console[_0x591891(0x195)](_0x591891(0x12b)+a32_0x10437a[_0x591891(0xb5)](_0xa11e47[_0x591891(0xf9)])+'\x20'+a32_0x10437a[_0x591891(0x247)](_0x591891(0x213)+_0xa11e47['id']+')')),_0xa11e47['entryCriteria']&&(console[_0x591891(0x195)](_0x591891(0xfa)+a32_0x10437a[_0x591891(0x276)](_0x591891(0x20a))+'\x20'+_0xa11e47[_0x591891(0x117)][_0x591891(0xf9)]),_0xa11e47['entryCriteria']['keyEventCriteria']?.[_0x591891(0x87)]&&console[_0x591891(0x195)]('\x20\x20\x20\x20\x20\x20\x20\x20'+a32_0x10437a[_0x591891(0x276)](_0x591891(0x1da))+'\x20'+_0xa11e47['entryCriteria']['keyEventCriteria']['keyEventId'])),_0xa11e47['payload']&&console[_0x591891(0x195)]('\x20\x20\x20\x20\x20\x20'+a32_0x10437a['cyan'](_0x591891(0xc7))+'\x20'+JSON[_0x591891(0x174)](_0xa11e47['payload'])),_0xa11e47[_0x591891(0x259)]&&console[_0x591891(0x195)](_0x591891(0xfa)+a32_0x10437a['cyan'](_0x591891(0x1a0))+_0x591891(0x273));}}return 0x0;}}export class PSPzDeleteCommand extends BaseCommand{[a32_0x462d84(0xf9)]=a32_0x462d84(0xb7);[a32_0x462d84(0x19c)]='Delete\x20a\x20realtime\x20personalization';async[a32_0x462d84(0x17f)](_0xdece91){const _0x2091d8=a32_0x462d84,{options:_0x544bf5,args:_0xab8179,tdx:_0x1711e5}=_0xdece91,_0x15fe62=_0xab8179[0x0];if(!_0x15fe62)return console[_0x2091d8(0x17d)](_0x2091d8(0x1fa)),console[_0x2091d8(0x17d)](_0x2091d8(0x1ae)),0x1;return await withSpinner(_0x2091d8(0x207)+_0x15fe62+_0x2091d8(0x183),()=>_0x1711e5[_0x2091d8(0x1e0)][_0x2091d8(0x244)](_0x15fe62),{'verbose':_0x544bf5['verbose']}),console[_0x2091d8(0x17d)](_0x2091d8(0x1b4)+_0x15fe62+'\x27'),0x0;}}export class PSPzCreateCommand extends BaseCommand{[a32_0x462d84(0xf9)]=a32_0x462d84(0x17a);[a32_0x462d84(0x19c)]=a32_0x462d84(0x22b);async['execute'](_0x55b456){const _0xbaf900=a32_0x462d84,{options:_0x3712e7,tdx:_0x38c808}=_0x55b456,_0x258bd7=_0x3712e7;let _0xd5d741;if(_0x258bd7['file']){_0xd5d741=await loadJSON(_0x258bd7['file'],!![]);if(!_0xd5d741[_0xbaf900(0x194)]?.[_0xbaf900(0x15d)])return console[_0xbaf900(0x17d)]('Error:\x20\x22relationships.parentFolder\x22\x20is\x20required\x20in\x20the\x20JSON\x20file.'),console[_0xbaf900(0x17d)](_0xbaf900(0xc0)),console[_0xbaf900(0x17d)]('\x20\x20\x22relationships\x22:\x20{\x20\x22parentFolder\x22:\x20{\x20\x22data\x22:\x20{\x20\x22id\x22:\x20\x22<id>\x22,\x20\x22type\x22:\x20\x22folder-segment\x22\x20}\x20}\x20}'),0x1;}else{if(!_0x258bd7[_0xbaf900(0xf9)])return console[_0xbaf900(0x17d)](_0xbaf900(0xab)),console[_0xbaf900(0x17d)](_0xbaf900(0x26f)),console[_0xbaf900(0x17d)](_0xbaf900(0x14d)),0x1;if(_0x258bd7[_0xbaf900(0x19c)]===undefined)return console['error'](_0xbaf900(0x15e)),console['error'](_0xbaf900(0x26f)),console['error'](_0xbaf900(0x14d)),0x1;if(_0x258bd7[_0xbaf900(0x1f0)]===undefined)return console[_0xbaf900(0x17d)]('Error:\x20--folder-id\x20is\x20required.\x20Use\x20`tdx\x20ps\x20folder\x20list\x20<name>`\x20to\x20find\x20the\x20folder\x20ID.'),console[_0xbaf900(0x17d)](_0xbaf900(0x264)),0x1;let _0x731df6=_0x258bd7[_0xbaf900(0xef)];if(!_0x731df6&&_0x3712e7['parentSegment']){const _0x48c443=await withSpinner(_0xbaf900(0x255)+_0x3712e7[_0xbaf900(0xa2)]+_0xbaf900(0x183),()=>_0x38c808[_0xbaf900(0x139)]['resolveParentId'](_0x3712e7[_0xbaf900(0xa2)]),{'verbose':_0x3712e7[_0xbaf900(0x19e)]});_0x731df6=_0x48c443[_0xbaf900(0x12d)];}let _0x21caf6;_0x258bd7[_0xbaf900(0x22a)]&&(_0x21caf6=await loadJSON(_0x258bd7[_0xbaf900(0x22a)],![]));const _0x40161f=_0x258bd7[_0xbaf900(0x1f0)]===_0xbaf900(0xf7)?null:{'id':_0x258bd7[_0xbaf900(0x1f0)],'type':_0xbaf900(0x101)};_0xd5d741={'attributes':{'name':_0x258bd7[_0xbaf900(0xf9)],'description':_0x258bd7['description']||null,..._0x731df6!==undefined&&{'audienceId':_0x731df6},..._0x21caf6!==undefined&&{'sections':_0x21caf6}},'relationships':{'parentFolder':{'data':_0x40161f}}};}const _0x5b0eef=await withSpinner('Creating\x20personalization\x20\x27'+(_0xd5d741[_0xbaf900(0x150)]?.[_0xbaf900(0xf9)]??'')+_0xbaf900(0x183),()=>_0x38c808[_0xbaf900(0x1e0)][_0xbaf900(0x21e)](_0xd5d741),{'verbose':_0x3712e7['verbose']}),_0x17645f=_0x5b0eef[_0xbaf900(0x12d)];return console['error'](_0xbaf900(0x200)+_0x17645f[_0xbaf900(0xf9)]+_0xbaf900(0x71)+_0x17645f['id']),await handleSDKOutput([_0x17645f],_0x3712e7),0x0;}}export class PSPzPatchCommand extends BaseCommand{['name']='ps:pz:patch';[a32_0x462d84(0x19c)]=a32_0x462d84(0x15a);async[a32_0x462d84(0x17f)](_0x3d72ba){const _0x328b23=a32_0x462d84,{options:_0xef1105,args:_0x12a0da}=_0x3d72ba,_0x2cc53c=_0xef1105,_0x369daf=_0x12a0da[0x0];if(!_0x369daf)return console[_0x328b23(0x17d)]('Error:\x20Personalization\x20ID\x20is\x20required'),console[_0x328b23(0x17d)](_0x328b23(0x189)),console[_0x328b23(0x17d)](_0x328b23(0x1ca)),0x1;let _0x34223b;if(_0x2cc53c[_0x328b23(0xf8)])_0x34223b=await loadJSON(_0x2cc53c['file'],!![]);else{if(!_0x2cc53c[_0x328b23(0xf9)])return console[_0x328b23(0x17d)](_0x328b23(0xab)),console[_0x328b23(0x17d)](_0x328b23(0x189)),0x1;if(_0x2cc53c['description']===undefined)return console['error'](_0x328b23(0x15e)),console['error'](_0x328b23(0x189)),0x1;let _0x905579;_0x2cc53c['sections']&&(_0x905579=await loadJSON(_0x2cc53c['sections'],![])),_0x34223b={'attributes':{'name':_0x2cc53c[_0x328b23(0xf9)],'description':_0x2cc53c['description']||null,..._0x905579!==undefined&&{'sections':_0x905579}}};}const {tdx:_0x407209}=_0x3d72ba,_0x7e46a2=await withSpinner('Patching\x20personalization\x20\x27'+_0x369daf+_0x328b23(0x183),()=>_0x407209[_0x328b23(0x1e0)][_0x328b23(0x23b)](_0x369daf,_0x34223b),{'verbose':_0xef1105['verbose']}),_0x3df778=_0x7e46a2[_0x328b23(0x12d)];return console['error'](_0x328b23(0xb3)+_0x3df778[_0x328b23(0xf9)]+_0x328b23(0xc9)+_0x3df778['id']+')'),await handleSDKOutput([_0x3df778],_0xef1105),0x0;}}export class PSPzInitCommand extends BaseParentSegmentCommand{[a32_0x462d84(0xf9)]='ps:pz:init';[a32_0x462d84(0x19c)]=a32_0x462d84(0x176);async[a32_0x462d84(0x17f)](_0x4c0d93){const _0x10a4cb=a32_0x462d84,{options:_0x228818,args:_0x244265}=_0x4c0d93,_0x223e29=_0x244265[0x0]||_0x228818[_0x10a4cb(0xa2)];if(!_0x223e29)return showParentSegmentNotSetError(_0x10a4cb(0x1e2)+_0x10a4cb(0x269)),0x1;const _0x11d932=resolveYamlFile(_0x223e29);if(!existsSync(_0x11d932))return showFileNotFoundError(_0x11d932,_0x223e29),0x1;let _0x378783;try{_0x378783=readFileSync(_0x11d932,_0x10a4cb(0x15f));}catch(_0x960190){const _0xaa8be9=_0x960190 instanceof Error?_0x960190[_0x10a4cb(0x184)]:String(_0x960190);return console['error'](_0x10a4cb(0x88)+_0xaa8be9),0x1;}let _0x44074e;try{_0x44074e=parseDef(_0x378783);}catch(_0x10f446){const _0x1b5554=_0x10f446 instanceof Error?_0x10f446['message']:String(_0x10f446);return console['error'](a32_0x10437a[_0x10a4cb(0xbd)](_0x10a4cb(0xb0)+_0x1b5554)),0x1;}if(_0x44074e[_0x10a4cb(0x166)]&&_0x44074e[_0x10a4cb(0x166)][_0x10a4cb(0x7b)]>0x0)return console['error'](a32_0x10437a[_0x10a4cb(0x94)](_0x10a4cb(0x27b)+_0x11d932)),console[_0x10a4cb(0x17d)](a32_0x10437a[_0x10a4cb(0x247)]('\x20\x20\x20'+_0x44074e[_0x10a4cb(0x166)]['length']+_0x10a4cb(0xf5))),0x1;!_0x44074e[_0x10a4cb(0x231)]&&(_0x44074e[_0x10a4cb(0x231)]={'events':[{'name':_0x10a4cb(0x22c),'source_table':'<database>.<table>'}],'attributes':[{'name':_0x10a4cb(0x27c),'type':'single'}],'id_stitching':{'primary_key':_0x44074e[_0x10a4cb(0x109)][_0x10a4cb(0x217)]==='customers'?'td_client_id':'user_id'}});_0x44074e[_0x10a4cb(0x166)]=[{'name':_0x10a4cb(0x242),'description':_0x10a4cb(0x1c8),'trigger_event':_0x10a4cb(0x22c),'sections':[{'name':_0x10a4cb(0x130),'criteria':'true','attributes':[_0x10a4cb(0x27c)]}]}];const _0x1184a2=serializeDef(_0x44074e);return writeFileSync(_0x11d932,_0x1184a2,_0x10a4cb(0x15f)),console[_0x10a4cb(0x17d)](a32_0x10437a[_0x10a4cb(0x96)]('✔')+'\x20Added\x20personalization\x20template\x20to\x20'+a32_0x10437a[_0x10a4cb(0x276)](_0x11d932)),(!_0x44074e['realtime']||_0x378783[_0x10a4cb(0x205)](_0x10a4cb(0x120))===-0x1)&&console['error'](a32_0x10437a[_0x10a4cb(0x96)]('✔')+_0x10a4cb(0x132)),console[_0x10a4cb(0x17d)]('\x0a'+a32_0x10437a['dim'](_0x10a4cb(0x1d9))),console[_0x10a4cb(0x17d)](_0x10a4cb(0x9e)+_0x11d932+'\x20to\x20configure\x20your\x20personalization\x20service'),console[_0x10a4cb(0x17d)](_0x10a4cb(0x165)+a32_0x10437a[_0x10a4cb(0x247)](_0x10a4cb(0x221)+_0x223e29)+_0x10a4cb(0x113)),0x0;}}
|