@lovrabet/rabetbase-cli 2.5.5-beta.1 → 2.5.5-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/api/api-doc.js +1 -1
- package/lib/api/api-group.js +1 -1
- package/lib/api/fetch-model-list.js +1 -1
- package/lib/api/generate-api-file.js +1 -1
- package/lib/api/generate-sdk-config-file.js +1 -1
- package/lib/api/legacy-api-file.js +1 -1
- package/lib/api/model-registry-file.js +1 -1
- package/lib/api/model-registry-scaffold.js +1 -1
- package/lib/api/model-source.js +1 -1
- package/lib/auth/auth-server-ui.js +1 -1
- package/lib/auth/auth-server.js +1 -1
- package/lib/auth/constant.js +1 -1
- package/lib/auth/get-cookie.js +1 -1
- package/lib/auth/get-session-user.js +1 -1
- package/lib/auth/is-session-valid.js +1 -1
- package/lib/auth/login-success-html.js +1 -1
- package/lib/auth/logout.js +1 -1
- package/lib/cli-flags.js +1 -1
- package/lib/cli.js +1 -1
- package/lib/commands/api/generate.js +1 -1
- package/lib/commands/api/index.js +1 -1
- package/lib/commands/api/list.js +1 -1
- package/lib/commands/api/pull.js +1 -1
- package/lib/commands/api/shared.js +1 -1
- package/lib/commands/app/detail.js +1 -1
- package/lib/commands/app/index.js +1 -1
- package/lib/commands/app/list.js +1 -1
- package/lib/commands/app/members-list.js +1 -1
- package/lib/commands/app/remote-directory.js +1 -1
- package/lib/commands/app/shared.js +1 -1
- package/lib/commands/app-config/delete.js +1 -1
- package/lib/commands/app-config/get.js +1 -1
- package/lib/commands/app-config/index.js +1 -1
- package/lib/commands/app-config/list.js +1 -1
- package/lib/commands/app-config/set.js +1 -1
- package/lib/commands/app-config/shared.js +1 -1
- package/lib/commands/auth/index.js +1 -1
- package/lib/commands/bff/create.js +1 -1
- package/lib/commands/bff/delete.js +1 -1
- package/lib/commands/bff/detail.js +1 -1
- package/lib/commands/bff/index.js +1 -1
- package/lib/commands/bff/list.js +1 -1
- package/lib/commands/bff/logs.js +1 -1
- package/lib/commands/bff/pull.js +1 -1
- package/lib/commands/bff/push.js +1 -1
- package/lib/commands/bff/status.js +1 -1
- package/lib/commands/cli-skill/index.js +1 -1
- package/lib/commands/cli-update.js +1 -1
- package/lib/commands/codegen/index.js +1 -1
- package/lib/commands/codegen/sdk.js +1 -1
- package/lib/commands/codegen/sql.js +1 -1
- package/lib/commands/common/app-registry.js +1 -1
- package/lib/commands/common/app-selector.js +1 -1
- package/lib/commands/common/async-task.js +1 -1
- package/lib/commands/common/dry-run.js +1 -1
- package/lib/commands/common/flags.js +1 -1
- package/lib/commands/common/local-file.js +1 -1
- package/lib/commands/common/validate.js +1 -1
- package/lib/commands/config/delete.js +1 -1
- package/lib/commands/config/get.js +1 -1
- package/lib/commands/config/index.js +1 -1
- package/lib/commands/config/init.js +1 -1
- package/lib/commands/config/list.js +1 -1
- package/lib/commands/config/set.js +1 -1
- package/lib/commands/config/shared.js +1 -1
- package/lib/commands/dataset/batch-design.js +1 -1
- package/lib/commands/dataset/business-group-update.js +1 -1
- package/lib/commands/dataset/business-groups.js +1 -1
- package/lib/commands/dataset/capability.js +1 -1
- package/lib/commands/dataset/cross-relation-create.js +1 -1
- package/lib/commands/dataset/cross-relation-delete.js +1 -1
- package/lib/commands/dataset/cross-relation-list.js +1 -1
- package/lib/commands/dataset/cross-relation-shared.js +1 -1
- package/lib/commands/dataset/cross-relation-update.js +1 -1
- package/lib/commands/dataset/delete.js +1 -1
- package/lib/commands/dataset/detail.js +1 -1
- package/lib/commands/dataset/extend-update.js +1 -1
- package/lib/commands/dataset/field-restore.js +1 -1
- package/lib/commands/dataset/field-update.js +1 -1
- package/lib/commands/dataset/generate.js +1 -1
- package/lib/commands/dataset/index.js +1 -1
- package/lib/commands/dataset/list.js +1 -1
- package/lib/commands/dataset/operations.js +1 -1
- package/lib/commands/dataset/relation-audit.js +1 -1
- package/lib/commands/dataset/relation-create.js +1 -1
- package/lib/commands/dataset/relation-delete.js +1 -1
- package/lib/commands/dataset/relation-shared.js +1 -1
- package/lib/commands/dataset/relation-update.js +1 -1
- package/lib/commands/dataset/relations.js +1 -1
- package/lib/commands/dataset/rename.js +1 -1
- package/lib/commands/dataset/restore.js +1 -1
- package/lib/commands/dataset/user-deleted-field-list.js +1 -1
- package/lib/commands/db/analysis-batching.js +1 -1
- package/lib/commands/db/analyze-batch-plan.js +1 -1
- package/lib/commands/db/analyze-cancel.js +1 -1
- package/lib/commands/db/analyze-start.js +1 -1
- package/lib/commands/db/analyze-status.js +1 -1
- package/lib/commands/db/create.js +1 -1
- package/lib/commands/db/delete.js +1 -1
- package/lib/commands/db/detail.js +1 -1
- package/lib/commands/db/diff-refresh-start.js +1 -1
- package/lib/commands/db/diff-refresh-status.js +1 -1
- package/lib/commands/db/diff.js +1 -1
- package/lib/commands/db/index.js +1 -1
- package/lib/commands/db/list.js +1 -1
- package/lib/commands/db/shared.js +1 -1
- package/lib/commands/db/table-diff-shared.js +1 -1
- package/lib/commands/db/tables.js +1 -1
- package/lib/commands/db/test.js +1 -1
- package/lib/commands/db/update.js +1 -1
- package/lib/commands/deployment/index.js +1 -1
- package/lib/commands/deployment/sync-all.js +1 -1
- package/lib/commands/deployment/sync-jobs.js +1 -1
- package/lib/commands/deployment/sync-status.js +1 -1
- package/lib/commands/doctor.js +1 -1
- package/lib/commands/file/index.js +1 -1
- package/lib/commands/flow/create.js +1 -1
- package/lib/commands/flow/detail.js +1 -1
- package/lib/commands/flow/index.js +1 -1
- package/lib/commands/flow/list.js +1 -1
- package/lib/commands/flow/publish.js +1 -1
- package/lib/commands/flow/runtime-resources-shared.js +1 -1
- package/lib/commands/flow/runtime-role-list.js +1 -1
- package/lib/commands/flow/runtime-role-user-list.js +1 -1
- package/lib/commands/flow/runtime-user-search.js +1 -1
- package/lib/commands/flow/shared.js +1 -1
- package/lib/commands/flow/update.js +1 -1
- package/lib/commands/flow/validate.js +1 -1
- package/lib/commands/instant-api-policy/current.js +1 -1
- package/lib/commands/instant-api-policy/index.js +1 -1
- package/lib/commands/instant-api-policy/init.js +1 -1
- package/lib/commands/instant-api-policy/publish.js +1 -1
- package/lib/commands/instant-api-policy/pull.js +1 -1
- package/lib/commands/instant-api-policy/revision.js +1 -1
- package/lib/commands/instant-api-policy/revisions.js +1 -1
- package/lib/commands/instant-api-policy/rollback.js +1 -1
- package/lib/commands/instant-api-policy/shared.js +1 -1
- package/lib/commands/instant-api-policy/validate.js +1 -1
- package/lib/commands/issue/index.js +1 -1
- package/lib/commands/issue/nudge.js +1 -1
- package/lib/commands/issue/report.js +1 -1
- package/lib/commands/issue/shared.js +1 -1
- package/lib/commands/kb/create.js +1 -1
- package/lib/commands/kb/delete.js +1 -1
- package/lib/commands/kb/detail.js +1 -1
- package/lib/commands/kb/index.js +1 -1
- package/lib/commands/kb/list.js +1 -1
- package/lib/commands/kb/search.js +1 -1
- package/lib/commands/kb/shared.js +1 -1
- package/lib/commands/kb/update.js +1 -1
- package/lib/commands/logs/index.js +1 -1
- package/lib/commands/menu/asset-update.js +1 -1
- package/lib/commands/menu/delete.js +1 -1
- package/lib/commands/menu/external-link-create.js +1 -1
- package/lib/commands/menu/external-link-update.js +1 -1
- package/lib/commands/menu/group-create.js +1 -1
- package/lib/commands/menu/group-update.js +1 -1
- package/lib/commands/menu/index.js +1 -1
- package/lib/commands/menu/list.js +1 -1
- package/lib/commands/menu/move.js +1 -1
- package/lib/commands/menu/regroup-start.js +1 -1
- package/lib/commands/menu/rename.js +1 -1
- package/lib/commands/menu/shared/compare-table.js +1 -1
- package/lib/commands/menu/shared/delete-plan.js +1 -1
- package/lib/commands/menu/shared/facts.js +1 -1
- package/lib/commands/menu/shared/index.js +1 -1
- package/lib/commands/menu/shared/inquirer.js +1 -1
- package/lib/commands/menu/shared/local-pages.js +1 -1
- package/lib/commands/menu/shared/logic.js +1 -1
- package/lib/commands/menu/shared/mutations.js +1 -1
- package/lib/commands/menu/shared/path.js +1 -1
- package/lib/commands/menu/shared/service.js +1 -1
- package/lib/commands/menu/shared/subapp-assets.js +1 -1
- package/lib/commands/menu/shared/sync-core.js +1 -1
- package/lib/commands/menu/shared/update-core.js +1 -1
- package/lib/commands/menu/shared/valid-url.js +1 -1
- package/lib/commands/menu/subapp-assets-status.js +1 -1
- package/lib/commands/menu/subapp-assets-update.js +1 -1
- package/lib/commands/menu/sync.js +1 -1
- package/lib/commands/menu/visibility-update.js +1 -1
- package/lib/commands/notification/config-create.js +1 -1
- package/lib/commands/notification/config-delete.js +1 -1
- package/lib/commands/notification/config-list.js +1 -1
- package/lib/commands/notification/config-update.js +1 -1
- package/lib/commands/notification/index.js +1 -1
- package/lib/commands/notification/shared.js +1 -1
- package/lib/commands/ocr/index.js +1 -1
- package/lib/commands/page/create.js +1 -1
- package/lib/commands/page/custom/detail.js +1 -1
- package/lib/commands/page/custom/list.js +1 -1
- package/lib/commands/page/custom/publish.js +1 -1
- package/lib/commands/page/custom/shared.js +1 -1
- package/lib/commands/page/custom/syntax.js +1 -1
- package/lib/commands/page/custom/update.js +1 -1
- package/lib/commands/page/data-list-status.js +1 -1
- package/lib/commands/page/generate-start.js +1 -1
- package/lib/commands/page/generate-status.js +1 -1
- package/lib/commands/page/index.js +1 -1
- package/lib/commands/page/pull.js +1 -1
- package/lib/commands/page/push.js +1 -1
- package/lib/commands/page/relation-audit.js +1 -1
- package/lib/commands/page/restore.js +1 -1
- package/lib/commands/page/shared.js +1 -1
- package/lib/commands/page/sync.js +1 -1
- package/lib/commands/project/api-architecture-upgrade.js +1 -1
- package/lib/commands/project/create/enhanced-guided-create.js +1 -1
- package/lib/commands/project/create/format-elapsed.js +1 -1
- package/lib/commands/project/create/main.js +1 -1
- package/lib/commands/project/create/materialize-project-template.js +1 -1
- package/lib/commands/project/create/project-name.js +1 -1
- package/lib/commands/project/create/project-template-archive.js +1 -1
- package/lib/commands/project/create/project-template-path.js +1 -1
- package/lib/commands/project/create/use-copy-project-template.js +1 -1
- package/lib/commands/project/create/use-format-code.js +1 -1
- package/lib/commands/project/create/use-install-dependencies.js +1 -1
- package/lib/commands/project/domain-routing-sync.js +1 -1
- package/lib/commands/project/index.js +1 -1
- package/lib/commands/project/upgrade.js +1 -1
- package/lib/commands/registry.js +1 -1
- package/lib/commands/role/delete.js +1 -1
- package/lib/commands/role/detail.js +1 -1
- package/lib/commands/role/index.js +1 -1
- package/lib/commands/role/list.js +1 -1
- package/lib/commands/role/shared.js +1 -1
- package/lib/commands/role/update.js +1 -1
- package/lib/commands/role/user-add.js +1 -1
- package/lib/commands/role/user-remove.js +1 -1
- package/lib/commands/role/user-resolve.js +1 -1
- package/lib/commands/rule/get.js +1 -1
- package/lib/commands/rule/index.js +1 -1
- package/lib/commands/rule/list.js +1 -1
- package/lib/commands/rule/set.js +1 -1
- package/lib/commands/rule/shared.js +1 -1
- package/lib/commands/run/index.js +1 -1
- package/lib/commands/schema.js +1 -1
- package/lib/commands/sql/create.js +1 -1
- package/lib/commands/sql/delete.js +1 -1
- package/lib/commands/sql/detail.js +1 -1
- package/lib/commands/sql/exec.js +1 -1
- package/lib/commands/sql/index.js +1 -1
- package/lib/commands/sql/list.js +1 -1
- package/lib/commands/sql/pull.js +1 -1
- package/lib/commands/sql/push.js +1 -1
- package/lib/commands/sql/shared.js +1 -1
- package/lib/commands/sql/status.js +1 -1
- package/lib/commands/sql/validate.js +1 -1
- package/lib/commands/task/index.js +1 -1
- package/lib/commands/task/status.js +1 -1
- package/lib/commands/tenant/index.js +1 -1
- package/lib/commands/tenant/members-list.js +1 -1
- package/lib/commands/tenant/shared.js +1 -1
- package/lib/commands/user-account/dingding-sandbox-bind.js +1 -1
- package/lib/commands/user-account/feishu-bind.js +1 -1
- package/lib/commands/user-account/index.js +1 -1
- package/lib/commands/workspace/add.js +1 -1
- package/lib/commands/workspace/index.js +1 -1
- package/lib/commands/workspace/remove.js +1 -1
- package/lib/config/domain-config.js +1 -1
- package/lib/config/project-domain-routing.js +1 -1
- package/lib/config/region-config.js +1 -1
- package/lib/config/schema.js +1 -1
- package/lib/constant/cdn.js +1 -1
- package/lib/constant/cli.js +1 -1
- package/lib/constant/defaults.js +1 -1
- package/lib/constant/domain.js +1 -1
- package/lib/constant/env.js +1 -1
- package/lib/constant/output.js +1 -1
- package/lib/constant/paths.js +1 -1
- package/lib/constant/region.js +1 -1
- package/lib/constant/risk.js +1 -1
- package/lib/constant/routing-profile.js +1 -1
- package/lib/context/app-resolver.js +1 -1
- package/lib/context/auth-resolver.js +1 -1
- package/lib/context/config-loader.js +1 -1
- package/lib/context.js +1 -1
- package/lib/core/alias-resolver.js +1 -1
- package/lib/core/api-client.js +1 -1
- package/lib/core/bff/config.js +1 -1
- package/lib/core/bff/file-system.js +1 -1
- package/lib/core/bff/hash.js +1 -1
- package/lib/core/bff/hook-directory.js +1 -1
- package/lib/core/bff/lock.js +1 -1
- package/lib/core/bff/utils.js +1 -1
- package/lib/core/cross-db-relation.js +1 -1
- package/lib/core/db-resolver.js +1 -1
- package/lib/core/flow-config.js +1 -1
- package/lib/core/instant-api-policy/config.js +1 -1
- package/lib/core/kb-search-client.js +1 -1
- package/lib/core/page/file-system.js +1 -1
- package/lib/core/page/hash.js +1 -1
- package/lib/core/page/lock.js +1 -1
- package/lib/core/page/lr-smart-jsx.js +1 -1
- package/lib/core/sql-index-auditor.js +1 -1
- package/lib/core/sql-sync/config.js +1 -1
- package/lib/core/sql-sync/file-system.js +1 -1
- package/lib/core/sql-sync/hash.js +1 -1
- package/lib/core/sql-sync/lock.js +1 -1
- package/lib/core/sql-sync/utils.js +1 -1
- package/lib/core/sql-validator.js +1 -1
- package/lib/errors.js +1 -1
- package/lib/framework/build-all-flags.js +1 -1
- package/lib/framework/error-output.js +1 -1
- package/lib/framework/explicit-yes.js +1 -1
- package/lib/framework/flags.js +1 -1
- package/lib/framework/help.js +1 -1
- package/lib/framework/index.js +1 -1
- package/lib/framework/output.js +1 -1
- package/lib/framework/response.js +1 -1
- package/lib/framework/runner-alias.js +1 -1
- package/lib/framework/runner.js +1 -1
- package/lib/framework/schema-export.js +1 -1
- package/lib/framework/supported-flags.js +1 -1
- package/lib/framework/types.js +1 -1
- package/lib/generated/build-info.d.ts +4 -4
- package/lib/generated/build-info.js +1 -1
- package/lib/generated/official-routing.js +1 -1
- package/lib/generated/routing-contract.js +1 -1
- package/lib/help.js +1 -1
- package/lib/postinstall.js +1 -1
- package/lib/runtime/confirmation.js +1 -1
- package/lib/runtime/event.js +1 -1
- package/lib/runtime/index.js +1 -1
- package/lib/runtime/queue.js +1 -1
- package/lib/runtime/resolve.js +1 -1
- package/lib/skills/builtin-skill.js +1 -1
- package/lib/skills/main.js +1 -1
- package/lib/skills/npx-skills-add.js +1 -1
- package/lib/skills/skill-presence.js +1 -1
- package/lib/telemetry/cli-command-trace.js +1 -1
- package/lib/telemetry/cli-help-trace.js +1 -1
- package/lib/telemetry/ensure-cli-otel-config.js +1 -1
- package/lib/telemetry/register-otel-exit-shutdown.js +1 -1
- package/lib/telemetry/send-cli-trace-log.js +1 -1
- package/lib/telemetry/send-platform-issue-collect-log.js +1 -1
- package/lib/utils/ai_config.js +1 -1
- package/lib/utils/apply-jq-filter.js +1 -1
- package/lib/utils/cdn-config.js +1 -1
- package/lib/utils/check-sdk-version.js +1 -1
- package/lib/utils/cli-version-check.js +1 -1
- package/lib/utils/cli-version-policy.js +1 -1
- package/lib/utils/config.js +1 -1
- package/lib/utils/entity-with-id.js +1 -1
- package/lib/utils/file-utils.js +1 -1
- package/lib/utils/guides-cdn.js +1 -1
- package/lib/utils/http-client.js +1 -1
- package/lib/utils/is-non-interactive.js +1 -1
- package/lib/utils/logger.js +1 -1
- package/lib/utils/params.js +1 -1
- package/lib/utils/platform.js +1 -1
- package/lib/utils/sleep.js +1 -1
- package/lib/utils/template-replacer.js +1 -1
- package/lib/utils/update-notice.js +1 -1
- package/lib/utils/version.js +1 -1
- package/lib/utils/with-active-cookie.js +1 -1
- package/lib/utils/write-cli-side-channel.js +1 -1
- package/package.json +1 -1
- package/skills/rabetbase/SKILL.md +1 -1
- package/skills/rabetbase-page-generation/SKILL.md +13 -9
- package/skills/rabetbase-page-generation/references/component-baseline.md +2 -2
- package/skills/rabetbase-page-generation/references/generation.md +64 -15
- package/skills/rabetbase-page-generation/templates/onepage/build.mjs +39 -54
- package/skills/rabetbase-page-generation/templates/onepage/list/index.jsx +6 -2
- package/skills/rabetbase.manifest.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0xccf93e,_0x27d041){const _0x2301ed=a272_0x2a99,_0x22bd32=_0xccf93e();while(!![]){try{const _0x4dffcc=parseInt(_0x2301ed(0x174))/0x1+-parseInt(_0x2301ed(0x178))/0x2*(-parseInt(_0x2301ed(0x170))/0x3)+-parseInt(_0x2301ed(0x173))/0x4+parseInt(_0x2301ed(0x166))/0x5+parseInt(_0x2301ed(0x16c))/0x6+parseInt(_0x2301ed(0x164))/0x7+-parseInt(_0x2301ed(0x17c))/0x8;if(_0x4dffcc===_0x27d041)break;else _0x22bd32['push'](_0x22bd32['shift']());}catch(_0x3b9829){_0x22bd32['push'](_0x22bd32['shift']());}}}(a272_0xf4df,0xdbc2a));import{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';function a272_0x2a99(_0x2a42a8,_0x2304c1){_0x2a42a8=_0x2a42a8-0x157;const _0xf4dffd=a272_0xf4df();let _0x2a9954=_0xf4dffd[_0x2a42a8];return _0x2a9954;}import{isDaily,normalizeEnv}from'../constant/env.js';import{normalizeLegacyOutputFormat,riskLevelOrder}from'../framework/types.js';import{DEFAULT_LOVRABET_REGION,normalizeLovrabetRegion}from'../constant/region.js';function a272_0xf4df(){const _0x13c3df=['24777GeKdbP','RISK_LEVEL','cookie','6827956RkyRix','1220399gMnlWy','app','value','projectPath','394VFURXr','apps','COOKIE','env','12346592mldmyK','length','write','APP','pageSize','defaultApp','globalConfig','riskLevel','locale','apiDir','ENV','read','production','keys','trim','region','daily','appcode','ACCESS_KEY','3296202JuyTTe','accessKey','2082145AVGxyC','projectConfig','FORMAT','source','object','entries','2494284qMeyMw','format','filter','PAGE_SIZE'];a272_0xf4df=function(){return _0x13c3df;};return a272_0xf4df();}import{selectConfiguredRegion}from'../config/region-config.js';function stringConfigValue(_0x2616b8){const _0x46a892=a272_0x2a99;return typeof _0x2616b8==='string'&&_0x2616b8[_0x46a892(0x15f)]()?_0x2616b8[_0x46a892(0x15f)]():undefined;}function appProfiles(_0x1b7140){const _0x30c653=a272_0x2a99;return _0x1b7140['apps']&&typeof _0x1b7140['apps']===_0x30c653(0x16a)?_0x1b7140[_0x30c653(0x179)]:{};}function resolveDefaultAppName(_0x2fa8bc){const _0x470ee5=a272_0x2a99,_0x373a79=stringConfigValue(_0x2fa8bc[_0x470ee5(0x181)]);if(_0x373a79)return _0x373a79;const _0x4411dc=Object[_0x470ee5(0x15e)](appProfiles(_0x2fa8bc));return _0x4411dc[_0x470ee5(0x17d)]===0x1?_0x4411dc[0x0]:undefined;}function resolveTopLevelAppCode(_0x43d185){return stringConfigValue(_0x43d185['appcode'])||stringConfigValue(_0x43d185['app']);}function normalizeRiskCeiling(_0x24f458){const _0x1fc264=a272_0x2a99;if(_0x24f458===undefined||_0x24f458===null)return undefined;if(_0x24f458===_0x1fc264(0x15c)||_0x24f458===_0x1fc264(0x17e)||_0x24f458==='high-risk-write')return _0x24f458;return _0x1fc264(0x15c);}function resolveRiskCeiling(..._0x10a174){const _0x2665d3=a272_0x2a99;let _0x4f2933;for(const _0x137634 of _0x10a174){const _0x28b1e1=normalizeRiskCeiling(_0x137634);_0x28b1e1&&(!_0x4f2933||riskLevelOrder(_0x28b1e1)<riskLevelOrder(_0x4f2933))&&(_0x4f2933=_0x28b1e1);}return _0x4f2933??DEFAULT_CONFIG_VALUES[_0x2665d3(0x158)];}export function resolveAppConfig({raw:_0x22fc90,flags:_0x1048f5,layers:_0x70866c,readEnv:_0x2070c0}){const _0x455096=a272_0x2a99,_0x571856=_0x70866c?.[_0x455096(0x167)]??{},_0x107355=_0x70866c?.[_0x455096(0x157)]??{},_0x31a293=!!_0x70866c?.[_0x455096(0x177)]||Object[_0x455096(0x15e)](_0x571856)[_0x455096(0x17d)]>0x0,_0x1945da=!_0x31a293,_0x27e666=_0x31a293?resolveDefaultAppName(_0x571856):undefined,_0xea198a=_0x1945da?resolveDefaultAppName(_0x107355):undefined,_0x4b36b4=stringConfigValue(_0x1048f5[_0x455096(0x175)]),_0x1a7464=_0x2070c0(_0x455096(0x17f)),_0x2cec94={};if(_0x22fc90[_0x455096(0x179)]&&typeof _0x22fc90[_0x455096(0x179)]===_0x455096(0x16a))for(const [_0x4d2412,_0x4d5bd6]of Object[_0x455096(0x16b)](_0x22fc90[_0x455096(0x179)])){_0x4d5bd6&&typeof _0x4d5bd6===_0x455096(0x16a)&&_0x4d5bd6[_0x455096(0x162)]&&(_0x2cec94[_0x4d2412]=_0x4d5bd6);}const _0x4a3bfe=_0x27e666||_0xea198a||resolveDefaultAppName(_0x22fc90),_0xe633c2=Object[_0x455096(0x15e)](_0x2cec94)['length']>0x0,_0x546972=_0x4b36b4||_0x27e666||_0x1a7464||_0xea198a||_0x4a3bfe||undefined,_0x269921=stringConfigValue(_0x1048f5[_0x455096(0x162)]),_0x17d957=_0x269921?Object[_0x455096(0x16b)](_0x2cec94)[_0x455096(0x16e)](([,_0x2bb085])=>_0x2bb085?.['appcode']===_0x269921):[],_0xede63c=_0x4b36b4&&_0x2cec94[_0x4b36b4]?.['appcode']===_0x269921?[_0x4b36b4,_0x2cec94[_0x4b36b4]]:undefined,_0x415a15=_0xede63c??(_0x17d957['length']===0x1?_0x17d957[0x0]:undefined),_0x4b38e7=_0x415a15?.[0x0],_0x4f49f1=_0x415a15?.[0x1],_0x252ab9=_0x269921?_0x4b38e7:_0x546972;let _0x4f1c17=_0x252ab9&&_0x2cec94[_0x252ab9]?_0x2cec94[_0x252ab9]:undefined;_0x269921&&_0x4f49f1&&(_0x4f1c17=_0x4f49f1);const _0x272bf0=_0x269921?_0x4f49f1??_0x4f1c17:_0x4f1c17,_0x5f3a1d=!_0x4b36b4&&!_0x27e666&&_0x1a7464&&_0x252ab9===_0x1a7464,_0x184bf2=_0x4b36b4||(_0x5f3a1d?_0x1a7464:undefined)||(_0x269921?_0x4b38e7:undefined),_0x591c08=_0x272bf0?.[_0x455096(0x162)],_0x3f1a7f=_0x31a293?resolveTopLevelAppCode(_0x571856):undefined,_0x580208=_0x1945da?resolveTopLevelAppCode(_0x107355):undefined,_0x5f42cb=_0x4b36b4||_0x27e666?_0x591c08:undefined,_0x203633=!_0x4b36b4&&!_0x27e666?_0x591c08:undefined,_0x39cb11=_0x269921||_0x5f42cb||_0x3f1a7f||_0x203633||_0x580208||undefined,_0x2db6d8=_0x31a293?stringConfigValue(_0x571856[_0x455096(0x17b)]):undefined,_0x293f84=_0x1945da?stringConfigValue(_0x107355[_0x455096(0x17b)]):undefined,_0x4cc32d=_0x1048f5[_0x455096(0x17b)]||_0x272bf0?.[_0x455096(0x17b)]||_0x2db6d8||_0x2070c0(_0x455096(0x15b))||_0x293f84||_0x22fc90[_0x455096(0x17b)]||DEFAULT_CONFIG_VALUES[_0x455096(0x17b)],_0x1d8220=_0x272bf0?.[_0x455096(0x159)]||_0x22fc90['locale']||DEFAULT_CONFIG_VALUES[_0x455096(0x159)],_0x3dad69=_0x2070c0(_0x455096(0x17a))||_0x272bf0?.[_0x455096(0x172)]||_0x22fc90[_0x455096(0x172)]||undefined,_0x4be1f4=_0x2070c0(_0x455096(0x163))||_0x272bf0?.[_0x455096(0x165)]||_0x22fc90[_0x455096(0x165)]||undefined,_0x13bb0d=_0x1048f5[_0x455096(0x16d)]||_0x2070c0(_0x455096(0x168))||_0x272bf0?.['format']||_0x22fc90[_0x455096(0x16d)],_0x330bad=normalizeLegacyOutputFormat(_0x13bb0d),_0xdefc49=_0x2070c0(_0x455096(0x16f))||_0x272bf0?.['pageSize']||_0x22fc90[_0x455096(0x180)],_0x39d590=_0xdefc49?Number(_0xdefc49)||undefined:undefined,_0x526895=_0x70866c?[_0x70866c[_0x455096(0x157)][_0x455096(0x158)],_0x70866c[_0x455096(0x167)][_0x455096(0x158)]]:[_0x22fc90[_0x455096(0x158)]],_0x576c2e=resolveRiskCeiling(..._0x526895,_0x272bf0?.[_0x455096(0x158)]),_0x51d33a=resolveRiskCeiling(_0x576c2e,_0x2070c0(_0x455096(0x171))),_0x3bd8a2=_0x2070c0('VERBOSE'),_0xd6cf28=_0x3bd8a2==='1'||_0x3bd8a2==='true',_0x4bbbae=_0x272bf0?.['apiDir']||_0x22fc90[_0x455096(0x15a)]||DEFAULT_CONFIG_VALUES[_0x455096(0x15a)],_0x15e752=selectConfiguredRegion({'appRegion':_0x272bf0?.['region'],'projectRegion':_0x31a293?_0x571856[_0x455096(0x160)]:undefined,'globalRegion':_0x31a293||_0x1945da?_0x107355[_0x455096(0x160)]:undefined,'mergedRegion':_0x22fc90[_0x455096(0x160)]}),_0x534ee1=normalizeLovrabetRegion(_0x15e752[_0x455096(0x176)])??DEFAULT_LOVRABET_REGION,_0x4aac93=isDaily(normalizeEnv(String(_0x4cc32d)))?_0x455096(0x161):_0x455096(0x15d);return{'appCode':typeof _0x39cb11==='string'&&_0x39cb11[_0x455096(0x15f)]()?_0x39cb11[_0x455096(0x15f)]():undefined,'region':_0x534ee1,'regionConfiguredValue':_0x15e752['value'],'regionSource':_0x15e752[_0x455096(0x169)],'env':_0x4aac93,'locale':_0x1d8220,'cookie':_0x3dad69,'accessKey':_0x4be1f4,'format':_0x330bad,'pageSize':_0x39d590,'riskLevel':_0x51d33a,'verbose':_0xd6cf28,'apiDir':_0x4bbbae,'apps':_0x2cec94,'defaultApp':_0x4a3bfe,'currentApp':_0xe633c2?_0x252ab9:undefined,'explicitAppName':_0x184bf2};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x538435,_0x90bcdb){const _0x46335d=a273_0x57d2,_0x158431=_0x538435();while(!![]){try{const _0x24cd2b=parseInt(_0x46335d(0x170))/0x1*(-parseInt(_0x46335d(0x17a))/0x2)+parseInt(_0x46335d(0x16f))/0x3+-parseInt(_0x46335d(0x174))/0x4+parseInt(_0x46335d(0x179))/0x5*(parseInt(_0x46335d(0x177))/0x6)+-parseInt(_0x46335d(0x178))/0x7+-parseInt(_0x46335d(0x175))/0x8+-parseInt(_0x46335d(0x171))/0x9*(-parseInt(_0x46335d(0x173))/0xa);if(_0x24cd2b===_0x90bcdb)break;else _0x158431['push'](_0x158431['shift']());}catch(_0x131917){_0x158431['push'](_0x158431['shift']());}}}(a273_0x4879,0x266ca));function a273_0x57d2(_0x596279,_0x5c5ddd){_0x596279=_0x596279-0x16f;const _0x48792f=a273_0x4879();let _0x57d21e=_0x48792f[_0x596279];return _0x57d21e;}import{getIsSessionValid}from'../auth/is-session-valid.js';import{CliErrors}from'../errors.js';function a273_0x4879(){const _0x2cd0db=['2794437CfrJUn','authRequired','20PkCxMy','541540GBrBcq','2341896bCmtJK','../auth/get-cookie.js','6wRdhOb','1040165IWAwyo','34955sqTUaG','6zXLkQB','586821VVJcau','29827ygYQgB'];a273_0x4879=function(){return _0x2cd0db;};return a273_0x4879();}export async function buildAuth(_0x1a8657){const _0x214ae0=a273_0x57d2,{getCookie:_0x1cfb20}=await import(_0x214ae0(0x176)),_0x2b52e4=_0x1a8657['cookie']||_0x1cfb20(),_0x2104f8=_0x2b52e4?await getIsSessionValid():![];return{'cookie':_0x2b52e4,'isLoggedIn':_0x2104f8,async 'getOrLogin'(){const _0x29d747=_0x214ae0;if(_0x2b52e4&&_0x2104f8)return _0x2b52e4;throw CliErrors[_0x29d747(0x172)]();}};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a274_0x4590e5=a274_0x59f1;(function(_0x10f069,_0x126536){const _0x4da49d=a274_0x59f1,_0x1a174d=_0x10f069();while(!![]){try{const _0x4b69cc=-parseInt(_0x4da49d(0x199))/0x1+-parseInt(_0x4da49d(0x18a))/0x2*(-parseInt(_0x4da49d(0x1a0))/0x3)+parseInt(_0x4da49d(0x18f))/0x4*(-parseInt(_0x4da49d(0x176))/0x5)+parseInt(_0x4da49d(0x19d))/0x6*(-parseInt(_0x4da49d(0x18b))/0x7)+parseInt(_0x4da49d(0x19c))/0x8*(parseInt(_0x4da49d(0x17e))/0x9)+-parseInt(_0x4da49d(0x17a))/0xa*(parseInt(_0x4da49d(0x1a6))/0xb)+parseInt(_0x4da49d(0x177))/0xc;if(_0x4b69cc===_0x126536)break;else _0x1a174d['push'](_0x1a174d['shift']());}catch(_0x54b0a6){_0x1a174d['push'](_0x1a174d['shift']());}}}(a274_0x3691,0x95fac));import{existsSync,mkdirSync,readFileSync,renameSync,unlinkSync,writeFileSync}from'node:fs';import{dirname,parse,resolve}from'node:path';import{homedir}from'node:os';import{CLI_BIN_NAME}from'../constant/cli.js';import{normalizeConfigForWrite}from'../config/schema.js';export const NEW_CONFIG_NAME=a274_0x4590e5(0x197);export const CONFIG_NAMES=[NEW_CONFIG_NAME];const normalizedWriteCache=new Map();export function resolveConfigPath(_0x574939){for(const _0x707f02 of CONFIG_NAMES){const _0x425923=resolve(_0x574939,_0x707f02);if(existsSync(_0x425923))return _0x425923;}return undefined;}export function findProjectRootDirectory(_0x58de93=process[a274_0x4590e5(0x182)]()){let _0x722f00=resolve(_0x58de93);const {root:_0x546ca1}=parse(_0x722f00),_0x1a0a69=homedir();while(!![]){if(resolveConfigPath(_0x722f00)){if(_0x722f00===_0x1a0a69)break;return _0x722f00;}if(_0x722f00===_0x546ca1||_0x722f00===_0x1a0a69)break;const _0x38ab75=dirname(_0x722f00);if(_0x38ab75===_0x722f00)break;_0x722f00=_0x38ab75;}return resolve(_0x58de93);}export function getProjectConfigPath(){return resolveConfigPath(process['cwd']());}export function getGlobalConfigPath(){return resolveConfigPath(homedir());}export function isInProject(){return!!getProjectConfigPath();}export function inspectCliConfigJsonFile(_0x5e92e3){const _0x390505=a274_0x4590e5;if(!existsSync(_0x5e92e3))return{'status':_0x390505(0x180)};try{const _0x524f56=readFileSync(_0x5e92e3,{'encoding':'utf8'});if(!_0x524f56?.[_0x390505(0x183)]())return{'status':_0x390505(0x19f)};const _0x1ae65e=JSON[_0x390505(0x19a)](_0x524f56);return{'status':'ok','data':_0x1ae65e};}catch(_0x20da9b){return{'status':'error','message':_0x20da9b instanceof Error?_0x20da9b[_0x390505(0x19e)]:String(_0x20da9b)};}}function parseCliConfigJsonFile(_0x3a6d7f,_0x119db2,_0x1e641c){const _0x34bb8f=a274_0x4590e5,_0x4e0082=inspectCliConfigJsonFile(_0x3a6d7f);if(_0x4e0082[_0x34bb8f(0x186)]===_0x34bb8f(0x180)||_0x4e0082['status']===_0x34bb8f(0x19f))return{};if(_0x4e0082['status']==='ok')return _0x4e0082[_0x34bb8f(0x188)];return _0x119db2==='warn'&&_0x1e641c&&console[_0x34bb8f(0x1a2)](CLI_BIN_NAME+':\x20'+_0x1e641c+_0x34bb8f(0x17c)+_0x3a6d7f+_0x34bb8f(0x190)+_0x4e0082[_0x34bb8f(0x19e)]),{};}function normalizeLegacyConfigShape(_0x5873ee){const _0x3847af=a274_0x4590e5;if(!_0x5873ee||typeof _0x5873ee!==_0x3847af(0x184))return{'config':{},'migrated':![]};const _0x301317={..._0x5873ee},_0xb62d4a=_0x301317[_0x3847af(0x1a5)]&&typeof _0x301317[_0x3847af(0x1a5)]===_0x3847af(0x184)?{..._0x301317['apps']}:{},_0x36465f=Object[_0x3847af(0x185)](_0xb62d4a)[_0x3847af(0x1a3)],_0x56ee64=_0x301317[_0x3847af(0x196)]||_0x301317['app'];let _0x1bac7d=![];if(_0x56ee64&&_0x36465f===0x0){const _0x4905bc=typeof _0x301317[_0x3847af(0x171)]===_0x3847af(0x1a4)&&_0x301317['defaultApp'][_0x3847af(0x183)]()?_0x301317[_0x3847af(0x171)]:String(_0x56ee64)[_0x3847af(0x183)]();_0xb62d4a[_0x4905bc]={'appcode':String(_0x56ee64)[_0x3847af(0x183)](),..._0x301317[_0x3847af(0x181)]!=null?{'env':_0x301317['env']}:{},..._0x301317[_0x3847af(0x174)]!=null?{'apiDir':_0x301317[_0x3847af(0x174)]}:{},..._0x301317[_0x3847af(0x17b)]!=null?{'cookie':_0x301317[_0x3847af(0x17b)]}:{},..._0x301317[_0x3847af(0x170)]!=null?{'accessKey':_0x301317['accessKey']}:{},..._0x301317[_0x3847af(0x198)]!=null?{'format':_0x301317['format']}:{},..._0x301317[_0x3847af(0x18c)]!=null?{'pageSize':_0x301317[_0x3847af(0x18c)]}:{},..._0x301317[_0x3847af(0x178)]!=null?{'riskLevel':_0x301317['riskLevel']}:{},..._0x301317[_0x3847af(0x189)]!=null?{'locale':_0x301317[_0x3847af(0x189)]}:{}},_0x301317[_0x3847af(0x1a5)]=_0xb62d4a,delete _0x301317[_0x3847af(0x171)],_0x1bac7d=!![];}return(_0x3847af(0x196)in _0x301317||_0x3847af(0x18d)in _0x301317)&&(delete _0x301317[_0x3847af(0x196)],delete _0x301317[_0x3847af(0x18d)],_0x1bac7d=!![]),{'config':_0x301317,'migrated':_0x1bac7d};}function writeNormalizedConfigIfNeeded(_0x112193,_0x205a23){const _0x1268f1=JSON['stringify'](normalizeConfigForWrite(_0x205a23),null,0x2)+'\x0a';if(normalizedWriteCache['get'](_0x112193)===_0x1268f1)return;writeConfigFile(_0x112193,_0x205a23),normalizedWriteCache['set'](_0x112193,_0x1268f1);}function parseAndNormalizeConfig(_0x2cb738,_0x4b3d78,_0x22c002){const _0x196aab=a274_0x4590e5,_0x191c59=parseCliConfigJsonFile(_0x2cb738,_0x4b3d78,_0x22c002),_0x3bfbbf=normalizeLegacyConfigShape(_0x191c59);if(_0x3bfbbf['migrated'])try{writeNormalizedConfigIfNeeded(_0x2cb738,_0x3bfbbf['config']);}catch{}return _0x3bfbbf[_0x196aab(0x193)];}export function loadRawConfigLayers(_0x49f355){const _0x3c2ba0=a274_0x4590e5;let _0x5044ba={},_0x3fc76c={};const _0x2e39de=resolveConfigPath(homedir());_0x2e39de&&(_0x5044ba=parseAndNormalizeConfig(_0x2e39de,_0x3c2ba0(0x195),_0x3c2ba0(0x179)));const _0x462af3=_0x49f355??findProjectRootDirectory(),_0x213cae=resolveConfigPath(_0x462af3);return _0x213cae&&(_0x3fc76c=parseAndNormalizeConfig(_0x213cae,_0x3c2ba0(0x195),_0x3c2ba0(0x17f))),{'globalPath':_0x2e39de,'projectPath':_0x213cae,'globalConfig':_0x5044ba,'projectConfig':_0x3fc76c};}function a274_0x3691(){const _0x414798=['\x20config\x20file\x20ignored\x20(invalid\x20JSON\x20or\x20unreadable):\x20','project','1635489JffKXJ','Project','missing','env','cwd','trim','object','keys','status','region','data','locale','2GFSGFF','203zijpjP','pageSize','app','localDomain','4HlrhVa','\x0a\x20\x20','skillDomain','silent','config','appDomain','warn','appcode','.rabetbase.json','format','314745VBrTKL','parse','certificateDomain','48VLQveS','62214sbTIPz','message','empty','1062681JRAdRH','runtimeDomain','error','length','string','apps','132891lzTBlC','routing','stringify','accessKey','defaultApp','.tmp','kbServiceDomain','apiDir','apiDomain','1097700VsUxdm','10639944Vjmpuo','riskLevel','Global','730EQNDad','cookie'];a274_0x3691=function(){return _0x414798;};return a274_0x3691();}const INHERIT_WHITELIST=['cookie',a274_0x4590e5(0x170),'locale',a274_0x4590e5(0x198),'riskLevel','pageSize',a274_0x4590e5(0x187),a274_0x4590e5(0x16e),'userDomain',a274_0x4590e5(0x175),a274_0x4590e5(0x1a1),a274_0x4590e5(0x191),'kbDomain',a274_0x4590e5(0x173),a274_0x4590e5(0x194),a274_0x4590e5(0x18e),a274_0x4590e5(0x19b)];export function mergeRawConfigLayers(_0x1a2fa3){const _0x4939b7=a274_0x4590e5,{globalConfig:_0x2c3272,projectConfig:_0x2139f2}=_0x1a2fa3,_0x17f604=!!_0x1a2fa3['projectPath']||Object[_0x4939b7(0x185)](_0x2139f2)[_0x4939b7(0x1a3)]>0x0;if(!_0x17f604)return mergeGlobalOnly(_0x2c3272);return mergeProjectFirst(_0x2c3272,_0x2139f2);}function a274_0x59f1(_0x22668f,_0x455be8){_0x22668f=_0x22668f-0x16e;const _0x369178=a274_0x3691();let _0x59f1a4=_0x369178[_0x22668f];return _0x59f1a4;}function mergeGlobalOnly(_0x3091c1){const _0x119c31=a274_0x4590e5,_0x26d9d8={..._0x3091c1};delete _0x26d9d8['inherit'];const _0x2cfdb1=_0x3091c1[_0x119c31(0x1a5)]&&typeof _0x3091c1['apps']===_0x119c31(0x184)?_0x3091c1[_0x119c31(0x1a5)]:{};if(Object[_0x119c31(0x185)](_0x2cfdb1)[_0x119c31(0x1a3)]>0x0)_0x26d9d8[_0x119c31(0x1a5)]=_0x2cfdb1;if(_0x3091c1[_0x119c31(0x171)])_0x26d9d8[_0x119c31(0x171)]=_0x3091c1[_0x119c31(0x171)];return _0x26d9d8;}function mergeProjectFirst(_0x363048,_0x365d3f){const _0x36ec0f=a274_0x4590e5,_0x21a6cc={..._0x365d3f};delete _0x21a6cc['inherit'];for(const _0x3b5b93 of INHERIT_WHITELIST){!(_0x3b5b93 in _0x21a6cc)&&_0x3b5b93 in _0x363048&&(_0x21a6cc[_0x3b5b93]=_0x363048[_0x3b5b93]);}const _0x252ecd=_0x365d3f[_0x36ec0f(0x1a5)]&&typeof _0x365d3f['apps']===_0x36ec0f(0x184)?_0x365d3f[_0x36ec0f(0x1a5)]:{};return Object['keys'](_0x252ecd)[_0x36ec0f(0x1a3)]>0x0?_0x21a6cc[_0x36ec0f(0x1a5)]=_0x252ecd:delete _0x21a6cc[_0x36ec0f(0x1a5)],_0x36ec0f(0x171)in _0x365d3f?_0x21a6cc[_0x36ec0f(0x171)]=_0x365d3f['defaultApp']:delete _0x21a6cc[_0x36ec0f(0x171)],_0x21a6cc;}export function readRawConfigWithLayers(_0x1041b6){const _0x278250=loadRawConfigLayers(_0x1041b6);return{'config':mergeRawConfigLayers(_0x278250),'layers':_0x278250};}export function readRawConfig(_0x188349){return mergeRawConfigLayers(loadRawConfigLayers(_0x188349));}export function readConfigFile(_0x2c4f24){const _0x31f4da=a274_0x4590e5;return parseAndNormalizeConfig(_0x2c4f24,_0x31f4da(0x192));}export function writeConfigFile(_0x34971a,_0x131c7e){const _0x59db4b=a274_0x4590e5,_0x388325=dirname(_0x34971a);!existsSync(_0x388325)&&mkdirSync(_0x388325,{'recursive':!![]});const _0x161b1d=_0x34971a+_0x59db4b(0x172);try{const _0x5aff65=normalizeConfigForWrite(_0x131c7e);writeFileSync(_0x161b1d,JSON[_0x59db4b(0x16f)](_0x5aff65,null,0x2)+'\x0a',{'encoding':'utf8','mode':0x180}),renameSync(_0x161b1d,_0x34971a);}catch(_0x3bda3b){try{unlinkSync(_0x161b1d);}catch{}throw _0x3bda3b;}}export function resolveWriteConfigPath(_0x573292){const _0x39939d=a274_0x4590e5,_0x489c7d=_0x573292===_0x39939d(0x17d)?process[_0x39939d(0x182)]():homedir(),_0x2878f5=resolveConfigPath(_0x489c7d);return _0x2878f5??resolve(_0x489c7d,NEW_CONFIG_NAME);}
|
package/lib/context.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const a275_0x476c0c=a275_0x59c9;(function(_0x54857c,_0x7823f){const _0x1cc260=a275_0x59c9,_0x34e58d=_0x54857c();while(!![]){try{const _0x182f7e=parseInt(_0x1cc260(0x195))/0x1*(-parseInt(_0x1cc260(0x161))/0x2)+-parseInt(_0x1cc260(0x179))/0x3*(parseInt(_0x1cc260(0x199))/0x4)+-parseInt(_0x1cc260(0x15e))/0x5+-parseInt(_0x1cc260(0x184))/0x6+-parseInt(_0x1cc260(0x15b))/0x7+-parseInt(_0x1cc260(0x187))/0x8*(parseInt(_0x1cc260(0x176))/0x9)+parseInt(_0x1cc260(0x188))/0xa;if(_0x182f7e===_0x7823f)break;else _0x34e58d['push'](_0x34e58d['shift']());}catch(_0x351313){_0x34e58d['push'](_0x34e58d['shift']());}}}(a275_0xa6e4,0x79b61));import{CLI_BIN_NAME}from'./constant/cli.js';import{buildAuth}from'./context/auth-resolver.js';import{resolveAppConfig}from'./context/app-resolver.js';import{CONFIG_NAMES,NEW_CONFIG_NAME,findProjectRootDirectory,getGlobalConfigPath,getProjectConfigPath,inspectCliConfigJsonFile,isInProject,loadRawConfigLayers,mergeRawConfigLayers,readConfigFile,readRawConfig,readRawConfigWithLayers,resolveConfigPath,resolveWriteConfigPath,writeConfigFile}from'./context/config-loader.js';import{resolveConfiguredRegion,resolveEffectiveRegion}from'./config/region-config.js';import{resolveEnterpriseRoutingManifest}from'./config/domain-config.js';import{logger}from'./utils/logger.js';import{resolveApiModelSource}from'./api/model-source.js';export{CONFIG_NAMES,NEW_CONFIG_NAME,findProjectRootDirectory,getGlobalConfigPath,getProjectConfigPath,inspectCliConfigJsonFile,isInProject,loadRawConfigLayers,mergeRawConfigLayers,readConfigFile,readRawConfig,readRawConfigWithLayers,resolveConfigPath,resolveWriteConfigPath,writeConfigFile};function a275_0x59c9(_0x6c4400,_0x9895fb){_0x6c4400=_0x6c4400-0x154;const _0xa6e478=a275_0xa6e4();let _0x59c910=_0xa6e478[_0x6c4400];return _0x59c910;}function env(_0x5849bb){return process.env[`RABETBASE_${_0x5849bb}`]||process.env[`LOVRABET_${_0x5849bb}`]||undefined;}function optionalString(_0x490c24){const _0x486cd3=a275_0x59c9;return typeof _0x490c24==='string'&&_0x490c24[_0x486cd3(0x19e)]()?_0x490c24[_0x486cd3(0x19e)]():undefined;}export function isRoutingRecoveryService(_0x5a9976){const _0x448139=a275_0x59c9;return _0x5a9976===_0x448139(0x158)||_0x5a9976===_0x448139(0x15c);}export async function createContext(_0x2dc8ed){const _0x4487b2=a275_0x59c9,{config:_0x5459a9,layers:_0x37d066}=readRawConfigWithLayers(),_0x288aea=buildConfig(_0x5459a9,_0x2dc8ed,_0x37d066);await initGlobalEnvironment(_0x288aea);const {getUserDomain:_0x39b3ec,getApiDomain:_0x44d0d7}=await import(_0x4487b2(0x17c)),_0x436dee={'apiDomain':_0x44d0d7(),'userDomain':_0x39b3ec()},_0x30566d=await buildAuth(_0x288aea);logger[_0x4487b2(0x167)](process[_0x4487b2(0x16e)]());const _0x7baabe=(CLI_BIN_NAME+'\x20'+process[_0x4487b2(0x190)][_0x4487b2(0x194)](0x2)[_0x4487b2(0x198)]('\x20'))[_0x4487b2(0x19e)]();logger[_0x4487b2(0x162)](_0x7baabe);const {isNonInteractive:_0xb1b48c}=await import(_0x4487b2(0x15d)),_0x33c532=_0xb1b48c(_0x2dc8ed);return{'config':_0x288aea,'auth':_0x30566d,'logger':logger,'env':_0x436dee,'nonInteractive':_0x33c532};}export function buildConfigFromFlags(_0x33aa50){const {config:_0x2236d6,layers:_0x503beb}=readRawConfigWithLayers();return buildConfig(_0x2236d6,_0x33aa50,_0x503beb);}export async function initGlobalEnvironment(_0x5bc389){const _0x10ad80=a275_0x59c9,_0x412130=_0x5bc389[_0x10ad80(0x165)]===_0x10ad80(0x182)&&_0x5bc389[_0x10ad80(0x160)]?'app\x20profile\x20\x22'+_0x5bc389['currentApp']+'\x22':_0x5bc389[_0x10ad80(0x165)]==='project'?_0x10ad80(0x169):_0x5bc389['regionSource']===_0x10ad80(0x18e)?_0x10ad80(0x166):_0x10ad80(0x16d);await initConfiguredEnvironment({'raw':_0x5bc389[_0x10ad80(0x17a)],'configuredRegion':_0x5bc389[_0x10ad80(0x185)]??_0x5bc389[_0x10ad80(0x17a)]?.[_0x10ad80(0x19a)]??_0x5bc389[_0x10ad80(0x19a)],'regionLocation':_0x412130,'targetEnv':_0x5bc389[_0x10ad80(0x16b)]});}function a275_0xa6e4(){const _0x163847=['routing','352373ZgqjsZ','doctor','./utils/is-non-interactive.js','2402575PTdvNX','cookie','currentApp','1183970AnUumu','setRawCommand','apps','entries','regionSource','global\x20Rabetbase\x20configuration','setLogPath','name','project\x20Rabetbase\x20configuration','object','env','apiGroup','Rabetbase\x20configuration','cwd','platformDomain','skillHubDomain','kbDomain','prototype','production','userDomain','projectConfig','279RiJFuX','some','https://g.lovrabet.com/dist/lovrabet-skill','303141fASzMZ','raw','runtimeDomain','./constant/domain.js','regionLocation','filter','template_base_url','call','replace','app','skillDomain','5687868UOEfZA','regionConfiguredValue','appcode','42904SYSyjV','29376930SMxUCM','string','defaultApp','source','length','hasOwnProperty','global','keys','argv','filePath','targetEnv','kbServiceDomain','slice','1pOhXxA','apiDomain','certificateDomain','join','8PVqCYe','region','domains','map','localDomain','trim','cdn','agentDomain','daily','appDomain','apiDir','routingConfig','config','configuredRegion'];a275_0xa6e4=function(){return _0x163847;};return a275_0xa6e4();}async function initConfiguredEnvironment(_0x4bea5f){const _0x533ff3=a275_0x59c9,_0x19fc99=resolveConfiguredRegion(_0x4bea5f[_0x533ff3(0x159)],_0x4bea5f[_0x533ff3(0x17d)]),_0x17921a=resolveEnterpriseRoutingManifest(_0x4bea5f[_0x533ff3(0x17a)]?.['routing']),_0x40b81a={'region':_0x19fc99,'apiDomain':_0x17921a?_0x17921a['domains'][_0x533ff3(0x196)]:optionalString(_0x4bea5f[_0x533ff3(0x17a)]?.['apiDomain']),'userDomain':_0x17921a?_0x17921a['domains'][_0x533ff3(0x174)]:optionalString(_0x4bea5f['raw']?.[_0x533ff3(0x174)]),'runtimeDomain':_0x17921a?_0x17921a['domains'][_0x533ff3(0x17b)]:optionalString(_0x4bea5f[_0x533ff3(0x17a)]?.[_0x533ff3(0x17b)]),'skillDomain':_0x17921a?_0x17921a[_0x533ff3(0x19b)]['skillDomain']:optionalString(_0x4bea5f[_0x533ff3(0x17a)]?.[_0x533ff3(0x183)])||optionalString(_0x4bea5f[_0x533ff3(0x17a)]?.[_0x533ff3(0x170)])||optionalString(_0x4bea5f[_0x533ff3(0x17a)]?.[_0x533ff3(0x1a0)])||optionalString(_0x4bea5f[_0x533ff3(0x17a)]?.[_0x533ff3(0x16f)]),'kbDomain':_0x17921a?_0x17921a[_0x533ff3(0x19b)][_0x533ff3(0x171)]:optionalString(_0x4bea5f[_0x533ff3(0x17a)]?.['kbDomain'])||optionalString(_0x4bea5f['raw']?.[_0x533ff3(0x1a0)])||optionalString(_0x4bea5f[_0x533ff3(0x17a)]?.['platformDomain']),'kbServiceDomain':_0x17921a?_0x17921a['domains'][_0x533ff3(0x193)]:optionalString(_0x4bea5f[_0x533ff3(0x17a)]?.[_0x533ff3(0x193)]),'appDomain':_0x17921a?_0x17921a[_0x533ff3(0x19b)][_0x533ff3(0x155)]:optionalString(_0x4bea5f[_0x533ff3(0x17a)]?.[_0x533ff3(0x155)]),'localDomain':_0x17921a?_0x17921a[_0x533ff3(0x19b)][_0x533ff3(0x19d)]:optionalString(_0x4bea5f[_0x533ff3(0x17a)]?.[_0x533ff3(0x19d)]),'certificateDomain':_0x17921a?_0x17921a[_0x533ff3(0x19b)][_0x533ff3(0x197)]:optionalString(_0x4bea5f[_0x533ff3(0x17a)]?.[_0x533ff3(0x197)]),'cdn':_0x17921a?.[_0x533ff3(0x19f)],'allowOfficialKbServiceDefault':!(_0x17921a!==undefined||[_0x533ff3(0x196),_0x533ff3(0x174),_0x533ff3(0x17b),_0x533ff3(0x183),_0x533ff3(0x170),_0x533ff3(0x171),_0x533ff3(0x193),_0x533ff3(0x1a0),_0x533ff3(0x16f),_0x533ff3(0x155),_0x533ff3(0x19d),_0x533ff3(0x197)][_0x533ff3(0x177)](_0x2025bf=>Object['prototype'][_0x533ff3(0x18d)][_0x533ff3(0x180)](_0x4bea5f[_0x533ff3(0x17a)]??{},_0x2025bf)))},{initEnv:_0x23a861}=await import('./constant/env.js'),{initDomains:_0x21751c}=await import(_0x533ff3(0x17c));_0x23a861(_0x4bea5f[_0x533ff3(0x192)]),_0x21751c(_0x40b81a);}export async function initMultiAppEnvironment(_0x143415){const _0x166db9=a275_0x59c9;await initConfiguredEnvironment({'raw':_0x143415[_0x166db9(0x157)],'configuredRegion':_0x143415['region'],'regionLocation':'app\x20profile\x20\x22'+_0x143415[_0x166db9(0x168)]+'\x22','targetEnv':_0x143415[_0x166db9(0x16b)]==='daily'?_0x166db9(0x154):_0x166db9(0x173)});}export function getConfigAppCode(_0x4520ae){const _0x427669=a275_0x59c9,_0x40ae92=readRawConfig(_0x4520ae);if(_0x40ae92[_0x427669(0x163)]&&typeof _0x40ae92['apps']===_0x427669(0x16a)){const _0x27a9f8=_0x40ae92[_0x427669(0x18a)];if(_0x27a9f8)return _0x40ae92[_0x427669(0x163)][_0x27a9f8]?.[_0x427669(0x186)]?String(_0x40ae92[_0x427669(0x163)][_0x27a9f8]['appcode'])[_0x427669(0x19e)]():undefined;const _0x4d607a=Object['values'](_0x40ae92[_0x427669(0x163)]);if(_0x4d607a['length']===0x1&&_0x4d607a[0x0]?.[_0x427669(0x186)])return String(_0x4d607a[0x0][_0x427669(0x186)])['trim']();}const _0x2a027a=_0x40ae92[_0x427669(0x186)]||_0x40ae92[_0x427669(0x182)];if(typeof _0x2a027a!==_0x427669(0x189)||_0x2a027a[_0x427669(0x19e)]()==='')return undefined;return _0x2a027a[_0x427669(0x19e)]();}const CONNECTION_ROUTING_KEYS=[a275_0x476c0c(0x15a),a275_0x476c0c(0x196),'userDomain',a275_0x476c0c(0x17b),a275_0x476c0c(0x183),a275_0x476c0c(0x170),'kbDomain','kbServiceDomain',a275_0x476c0c(0x1a0),a275_0x476c0c(0x16f),a275_0x476c0c(0x155),a275_0x476c0c(0x19d),a275_0x476c0c(0x197)];function withAppProfileRouting(_0x5a00b1,_0x23d680){const _0x1c288d=a275_0x476c0c;if(!_0x23d680||_0x23d680['kbServiceDomain']===undefined)return _0x5a00b1;return{..._0x5a00b1,'kbServiceDomain':_0x23d680[_0x1c288d(0x193)]};}function pickConnectionRoutingConfig(_0x3cbb46,_0xc611f){const _0x1487a4={'region':_0xc611f};for(const _0x146e95 of CONNECTION_ROUTING_KEYS){if(_0x3cbb46[_0x146e95]!==undefined)_0x1487a4[_0x146e95]=_0x3cbb46[_0x146e95];}return _0x1487a4;}export function getMultiAppConfigs(_0x1a4a01='project',_0x2ec24e){const _0x51ced4=a275_0x476c0c,_0x546a82=loadRawConfigLayers(_0x2ec24e);let _0x590a00,_0x293ca0;const _0x1384b8=mergeRawConfigLayers(_0x546a82),_0x35bb35=_0x546a82['globalConfig'][_0x51ced4(0x163)]&&typeof _0x546a82['globalConfig'][_0x51ced4(0x163)]==='object'?_0x546a82['globalConfig'][_0x51ced4(0x163)]:{},_0x11c06c=_0x546a82[_0x51ced4(0x175)][_0x51ced4(0x163)]&&typeof _0x546a82[_0x51ced4(0x175)][_0x51ced4(0x163)]===_0x51ced4(0x16a)?_0x546a82[_0x51ced4(0x175)][_0x51ced4(0x163)]:{};_0x1a4a01==='merged'?(_0x590a00={..._0x35bb35,..._0x11c06c},_0x293ca0=_0x1384b8[_0x51ced4(0x18a)]):(_0x590a00=_0x546a82[_0x51ced4(0x175)][_0x51ced4(0x163)],_0x293ca0=_0x546a82[_0x51ced4(0x175)]['defaultApp']);!_0x293ca0&&_0x590a00&&typeof _0x590a00===_0x51ced4(0x16a)&&Object[_0x51ced4(0x18f)](_0x590a00)[_0x51ced4(0x18c)]===0x1&&(_0x293ca0=Object[_0x51ced4(0x18f)](_0x590a00)[0x0]);if(!_0x590a00||typeof _0x590a00!==_0x51ced4(0x16a)||Object[_0x51ced4(0x18f)](_0x590a00)['length']===0x0)return null;return Object[_0x51ced4(0x164)](_0x590a00)[_0x51ced4(0x19c)](([_0x30540a,_0x4c0894])=>{const _0x5efd68=_0x51ced4,_0x5abf84=_0x1a4a01==='project'||Object[_0x5efd68(0x172)][_0x5efd68(0x18d)][_0x5efd68(0x180)](_0x11c06c,_0x30540a),_0x50e028=withAppProfileRouting(_0x5abf84?_0x1384b8:_0x546a82['globalConfig'],_0x4c0894),_0x3eda7b=resolveEffectiveRegion({'appRegion':_0x4c0894?.['region'],'projectRegion':_0x5abf84?_0x546a82[_0x5efd68(0x175)][_0x5efd68(0x19a)]:undefined,'globalRegion':_0x546a82['globalConfig']['region'],'mergedRegion':_0x50e028[_0x5efd68(0x19a)],'appName':_0x30540a});return{'name':_0x30540a,'appcode':_0x4c0894?.[_0x5efd68(0x186)]||'','apiGroup':optionalString(_0x4c0894?.[_0x5efd68(0x16c)]),'isDefault':_0x30540a===_0x293ca0,'region':_0x3eda7b['region'],'regionSource':_0x3eda7b[_0x5efd68(0x18b)],'env':_0x4c0894?.[_0x5efd68(0x16b)],'apiDir':optionalString(_0x4c0894?.[_0x5efd68(0x156)])||optionalString(_0x50e028[_0x5efd68(0x156)]),'cookie':_0x4c0894?.[_0x5efd68(0x15f)]||undefined,'routingConfig':pickConnectionRoutingConfig(_0x50e028,_0x3eda7b[_0x5efd68(0x19a)])};})[_0x51ced4(0x17e)](_0x159c23=>_0x159c23[_0x51ced4(0x186)]);}export function getTemplateBaseUrl(_0xe5c077){const _0x3b89a2=a275_0x476c0c,_0x5a1b16=readRawConfig(_0xe5c077);if(_0x5a1b16[_0x3b89a2(0x17f)]&&typeof _0x5a1b16['template_base_url']==='string')return _0x5a1b16['template_base_url'][_0x3b89a2(0x181)](/\/$/,'');return _0x3b89a2(0x178);}function buildConfig(_0x5c7b2a,_0x1cf1e5,_0x584f60){const _0x2e7de5=a275_0x476c0c,_0xd559da=resolveAppConfig({'raw':_0x5c7b2a,'flags':_0x1cf1e5,'layers':_0x584f60,'readEnv':env}),_0x301e84=_0xd559da[_0x2e7de5(0x160)]?_0xd559da['apps'][_0xd559da[_0x2e7de5(0x160)]]:undefined;return{..._0xd559da,'raw':withAppProfileRouting(_0x5c7b2a,_0x301e84)};}export function resolveApiFilePath(_0x4ecc58,_0x261782,_0x2bc985){const _0x737b04=a275_0x476c0c;return resolveApiModelSource(_0x4ecc58,_0x261782,_0x2bc985)[_0x737b04(0x191)];}
|
|
1
|
+
const a275_0xa44581=a275_0x2adb;(function(_0x20ce6d,_0x23f24f){const _0x43865f=a275_0x2adb,_0x32697c=_0x20ce6d();while(!![]){try{const _0x56efeb=parseInt(_0x43865f(0xa9))/0x1*(parseInt(_0x43865f(0xbd))/0x2)+-parseInt(_0x43865f(0xba))/0x3*(-parseInt(_0x43865f(0x9e))/0x4)+parseInt(_0x43865f(0x9f))/0x5*(parseInt(_0x43865f(0xab))/0x6)+-parseInt(_0x43865f(0xca))/0x7+-parseInt(_0x43865f(0x92))/0x8+-parseInt(_0x43865f(0x90))/0x9+parseInt(_0x43865f(0x9c))/0xa;if(_0x56efeb===_0x23f24f)break;else _0x32697c['push'](_0x32697c['shift']());}catch(_0x1b7cda){_0x32697c['push'](_0x32697c['shift']());}}}(a275_0x17d5,0xe4726));import{CLI_BIN_NAME}from'./constant/cli.js';import{buildAuth}from'./context/auth-resolver.js';import{resolveAppConfig}from'./context/app-resolver.js';import{CONFIG_NAMES,NEW_CONFIG_NAME,findProjectRootDirectory,getGlobalConfigPath,getProjectConfigPath,inspectCliConfigJsonFile,isInProject,loadRawConfigLayers,mergeRawConfigLayers,readConfigFile,readRawConfig,readRawConfigWithLayers,resolveConfigPath,resolveWriteConfigPath,writeConfigFile}from'./context/config-loader.js';import{resolveConfiguredRegion,resolveEffectiveRegion}from'./config/region-config.js';import{resolveEnterpriseRoutingManifest}from'./config/domain-config.js';function a275_0x2adb(_0x385f5d,_0x516c34){_0x385f5d=_0x385f5d-0x8c;const _0x17d57f=a275_0x17d5();let _0x2adb88=_0x17d57f[_0x385f5d];return _0x2adb88;}function a275_0x17d5(){const _0x3e1558=['targetEnv','slice','regionConfiguredValue','doctor','production','length','config','daily','template_base_url','globalConfig','localDomain','2312964bzjdTh','skillDomain','global\x20Rabetbase\x20configuration','18914lRtmXP','cdn','hasOwnProperty','map','agentDomain','kbServiceDomain','projectConfig','argv','trim','env','routing','app\x20profile\x20\x22','project','12820640uJwsiu','string','region','./utils/is-non-interactive.js','prototype','global','merged','source','raw','project\x20Rabetbase\x20configuration','currentApp','platformDomain','https://g.lovrabet.com/dist/lovrabet-skill','keys','object','14812038lbrobS','certificateDomain','888544HQaErx','configuredRegion','kbDomain','setLogPath','routingConfig','appDomain','domains','apps','join','Rabetbase\x20configuration','13768820FpHHLY','skillHubDomain','8zRHZOA','17950UTwHlt','./constant/env.js','regionSource','apiDomain','defaultApp','apiDir','apiGroup','runtimeDomain','./constant/domain.js','regionLocation','150FjbDMb','app','312fjfXGv','userDomain','appcode','filter'];a275_0x17d5=function(){return _0x3e1558;};return a275_0x17d5();}import{logger}from'./utils/logger.js';import{resolveApiModelSource}from'./api/model-source.js';export{CONFIG_NAMES,NEW_CONFIG_NAME,findProjectRootDirectory,getGlobalConfigPath,getProjectConfigPath,inspectCliConfigJsonFile,isInProject,loadRawConfigLayers,mergeRawConfigLayers,readConfigFile,readRawConfig,readRawConfigWithLayers,resolveConfigPath,resolveWriteConfigPath,writeConfigFile};function env(_0x3cb0c5){return process.env[`RABETBASE_${_0x3cb0c5}`]||process.env[`LOVRABET_${_0x3cb0c5}`]||undefined;}function optionalString(_0x22e221){const _0x4747b4=a275_0x2adb;return typeof _0x22e221===_0x4747b4(0xcb)&&_0x22e221[_0x4747b4(0xc5)]()?_0x22e221['trim']():undefined;}export function isRoutingRecoveryService(_0x9da876){const _0x1785a8=a275_0x2adb;return _0x9da876===_0x1785a8(0xb5)||_0x9da876===_0x1785a8(0xb2);}export async function createContext(_0x41e042){const _0x2f0b61=a275_0x2adb,{config:_0x4507a8,layers:_0x492f84}=readRawConfigWithLayers(),_0x13382c=buildConfig(_0x4507a8,_0x41e042,_0x492f84);await initGlobalEnvironment(_0x13382c);const {getUserDomain:_0xf66eee,getApiDomain:_0xf1f749}=await import(_0x2f0b61(0xa7)),_0x1ff2b1={'apiDomain':_0xf1f749(),'userDomain':_0xf66eee()},_0x592c3a=await buildAuth(_0x13382c);logger[_0x2f0b61(0x95)](process['cwd']());const _0x47f651=(CLI_BIN_NAME+'\x20'+process[_0x2f0b61(0xc4)][_0x2f0b61(0xb0)](0x2)[_0x2f0b61(0x9a)]('\x20'))[_0x2f0b61(0xc5)]();logger['setRawCommand'](_0x47f651);const {isNonInteractive:_0x3a9808}=await import(_0x2f0b61(0xcd)),_0x380c50=_0x3a9808(_0x41e042);return{'config':_0x13382c,'auth':_0x592c3a,'logger':logger,'env':_0x1ff2b1,'nonInteractive':_0x380c50};}export function buildConfigFromFlags(_0x87d1bd){const {config:_0x4d900c,layers:_0x43c006}=readRawConfigWithLayers();return buildConfig(_0x4d900c,_0x87d1bd,_0x43c006);}export async function initGlobalEnvironment(_0x28ca34){const _0x5d7327=a275_0x2adb,_0x43bc7a=_0x28ca34['regionSource']===_0x5d7327(0xaa)&&_0x28ca34[_0x5d7327(0xd4)]?_0x5d7327(0xc8)+_0x28ca34[_0x5d7327(0xd4)]+'\x22':_0x28ca34[_0x5d7327(0xa1)]===_0x5d7327(0xc9)?_0x5d7327(0xd3):_0x28ca34[_0x5d7327(0xa1)]===_0x5d7327(0xcf)?_0x5d7327(0xbc):_0x5d7327(0x9b);await initConfiguredEnvironment({'raw':_0x28ca34[_0x5d7327(0xd2)],'configuredRegion':_0x28ca34[_0x5d7327(0xb1)]??_0x28ca34[_0x5d7327(0xd2)]?.[_0x5d7327(0xcc)]??_0x28ca34['region'],'regionLocation':_0x43bc7a,'targetEnv':_0x28ca34[_0x5d7327(0xc6)]});}async function initConfiguredEnvironment(_0x44c5f3){const _0x29e5b6=a275_0x2adb,_0x74114b=resolveConfiguredRegion(_0x44c5f3[_0x29e5b6(0x93)],_0x44c5f3[_0x29e5b6(0xa8)]),_0x2a9068=resolveEnterpriseRoutingManifest(_0x44c5f3[_0x29e5b6(0xd2)]?.[_0x29e5b6(0xc7)]),_0x3897dd={'region':_0x74114b,'apiDomain':_0x2a9068?_0x2a9068[_0x29e5b6(0x98)][_0x29e5b6(0xa2)]:optionalString(_0x44c5f3[_0x29e5b6(0xd2)]?.['apiDomain']),'userDomain':_0x2a9068?_0x2a9068[_0x29e5b6(0x98)][_0x29e5b6(0xac)]:optionalString(_0x44c5f3[_0x29e5b6(0xd2)]?.[_0x29e5b6(0xac)]),'runtimeDomain':_0x2a9068?_0x2a9068[_0x29e5b6(0x98)]['runtimeDomain']:optionalString(_0x44c5f3[_0x29e5b6(0xd2)]?.[_0x29e5b6(0xa6)]),'skillDomain':_0x2a9068?_0x2a9068[_0x29e5b6(0x98)]['skillDomain']:optionalString(_0x44c5f3['raw']?.[_0x29e5b6(0xbb)])||optionalString(_0x44c5f3[_0x29e5b6(0xd2)]?.[_0x29e5b6(0x9d)])||optionalString(_0x44c5f3[_0x29e5b6(0xd2)]?.[_0x29e5b6(0xc1)])||optionalString(_0x44c5f3[_0x29e5b6(0xd2)]?.[_0x29e5b6(0x8c)]),'kbDomain':_0x2a9068?_0x2a9068[_0x29e5b6(0x98)][_0x29e5b6(0x94)]:optionalString(_0x44c5f3[_0x29e5b6(0xd2)]?.['kbDomain'])||optionalString(_0x44c5f3['raw']?.['agentDomain'])||optionalString(_0x44c5f3[_0x29e5b6(0xd2)]?.[_0x29e5b6(0x8c)]),'kbServiceDomain':_0x2a9068?_0x2a9068[_0x29e5b6(0x98)]['kbServiceDomain']:optionalString(_0x44c5f3[_0x29e5b6(0xd2)]?.[_0x29e5b6(0xc2)]),'appDomain':_0x2a9068?_0x2a9068['domains'][_0x29e5b6(0x97)]:optionalString(_0x44c5f3[_0x29e5b6(0xd2)]?.['appDomain']),'localDomain':_0x2a9068?_0x2a9068['domains'][_0x29e5b6(0xb9)]:optionalString(_0x44c5f3[_0x29e5b6(0xd2)]?.['localDomain']),'certificateDomain':_0x2a9068?_0x2a9068[_0x29e5b6(0x98)][_0x29e5b6(0x91)]:optionalString(_0x44c5f3['raw']?.[_0x29e5b6(0x91)]),'cdn':_0x2a9068?.[_0x29e5b6(0xbe)],'allowOfficialKbServiceDefault':!(_0x2a9068!==undefined||[_0x29e5b6(0xa2),_0x29e5b6(0xac),'runtimeDomain','skillDomain',_0x29e5b6(0x9d),_0x29e5b6(0x94),_0x29e5b6(0xc2),_0x29e5b6(0xc1),_0x29e5b6(0x8c),_0x29e5b6(0x97),_0x29e5b6(0xb9),_0x29e5b6(0x91)]['some'](_0xe012c9=>Object[_0x29e5b6(0xce)][_0x29e5b6(0xbf)]['call'](_0x44c5f3[_0x29e5b6(0xd2)]??{},_0xe012c9)))},{initEnv:_0x77100b}=await import(_0x29e5b6(0xa0)),{initDomains:_0xf839be}=await import('./constant/domain.js');_0x77100b(_0x44c5f3[_0x29e5b6(0xaf)]),_0xf839be(_0x3897dd);}export async function initMultiAppEnvironment(_0x483612){const _0x4d94bb=a275_0x2adb;await initConfiguredEnvironment({'raw':_0x483612[_0x4d94bb(0x96)],'configuredRegion':_0x483612['region'],'regionLocation':_0x4d94bb(0xc8)+_0x483612['name']+'\x22','targetEnv':_0x483612[_0x4d94bb(0xc6)]==='daily'?_0x4d94bb(0xb6):_0x4d94bb(0xb3)});}export function getConfigAppCode(_0x249154){const _0x36ce25=a275_0x2adb,_0x50066d=readRawConfig(_0x249154);if(_0x50066d['apps']&&typeof _0x50066d['apps']===_0x36ce25(0x8f)){const _0x3ddb7e=_0x50066d[_0x36ce25(0xa3)];if(_0x3ddb7e)return _0x50066d[_0x36ce25(0x99)][_0x3ddb7e]?.[_0x36ce25(0xad)]?String(_0x50066d[_0x36ce25(0x99)][_0x3ddb7e]['appcode'])[_0x36ce25(0xc5)]():undefined;const _0x1ae08e=Object['values'](_0x50066d[_0x36ce25(0x99)]);if(_0x1ae08e[_0x36ce25(0xb4)]===0x1&&_0x1ae08e[0x0]?.[_0x36ce25(0xad)])return String(_0x1ae08e[0x0][_0x36ce25(0xad)])[_0x36ce25(0xc5)]();}const _0x4d59a7=_0x50066d['appcode']||_0x50066d[_0x36ce25(0xaa)];if(typeof _0x4d59a7!=='string'||_0x4d59a7[_0x36ce25(0xc5)]()==='')return undefined;return _0x4d59a7[_0x36ce25(0xc5)]();}const CONNECTION_ROUTING_KEYS=[a275_0xa44581(0xc7),'apiDomain','userDomain',a275_0xa44581(0xa6),'skillDomain','skillHubDomain',a275_0xa44581(0x94),a275_0xa44581(0xc2),a275_0xa44581(0xc1),a275_0xa44581(0x8c),a275_0xa44581(0x97),'localDomain','certificateDomain'];function withAppProfileRouting(_0x6bf7e,_0x149d91){const _0x32a29b=a275_0xa44581;if(!_0x149d91||_0x149d91[_0x32a29b(0xc2)]===undefined)return _0x6bf7e;return{..._0x6bf7e,'kbServiceDomain':_0x149d91[_0x32a29b(0xc2)]};}function pickConnectionRoutingConfig(_0x300214,_0xd31550){const _0x21dd18={'region':_0xd31550};for(const _0x1a1c5b of CONNECTION_ROUTING_KEYS){if(_0x300214[_0x1a1c5b]!==undefined)_0x21dd18[_0x1a1c5b]=_0x300214[_0x1a1c5b];}return _0x21dd18;}export function getMultiAppConfigs(_0xe10f63=a275_0xa44581(0xc9),_0x35d42c){const _0x2b8713=a275_0xa44581,_0x4020ac=loadRawConfigLayers(_0x35d42c);let _0x3af9a9,_0x267899;const _0x24a82f=mergeRawConfigLayers(_0x4020ac),_0x1f49a1=_0x4020ac[_0x2b8713(0xb8)][_0x2b8713(0x99)]&&typeof _0x4020ac[_0x2b8713(0xb8)][_0x2b8713(0x99)]===_0x2b8713(0x8f)?_0x4020ac[_0x2b8713(0xb8)][_0x2b8713(0x99)]:{},_0x5cfebf=_0x4020ac[_0x2b8713(0xc3)]['apps']&&typeof _0x4020ac['projectConfig']['apps']==='object'?_0x4020ac[_0x2b8713(0xc3)][_0x2b8713(0x99)]:{};_0xe10f63===_0x2b8713(0xd0)?(_0x3af9a9={..._0x1f49a1,..._0x5cfebf},_0x267899=_0x24a82f[_0x2b8713(0xa3)]):(_0x3af9a9=_0x4020ac[_0x2b8713(0xc3)][_0x2b8713(0x99)],_0x267899=_0x4020ac['projectConfig'][_0x2b8713(0xa3)]);!_0x267899&&_0x3af9a9&&typeof _0x3af9a9===_0x2b8713(0x8f)&&Object[_0x2b8713(0x8e)](_0x3af9a9)['length']===0x1&&(_0x267899=Object['keys'](_0x3af9a9)[0x0]);if(!_0x3af9a9||typeof _0x3af9a9!=='object'||Object[_0x2b8713(0x8e)](_0x3af9a9)[_0x2b8713(0xb4)]===0x0)return null;return Object['entries'](_0x3af9a9)[_0x2b8713(0xc0)](([_0x5352e1,_0x2adaea])=>{const _0x4737ac=_0x2b8713,_0xf8405=_0xe10f63===_0x4737ac(0xc9)||Object[_0x4737ac(0xce)][_0x4737ac(0xbf)]['call'](_0x5cfebf,_0x5352e1),_0x48f7d3=withAppProfileRouting(_0xf8405?_0x24a82f:_0x4020ac[_0x4737ac(0xb8)],_0x2adaea),_0x1a1952=resolveEffectiveRegion({'appRegion':_0x2adaea?.['region'],'projectRegion':_0xf8405?_0x4020ac['projectConfig'][_0x4737ac(0xcc)]:undefined,'globalRegion':_0x4020ac['globalConfig'][_0x4737ac(0xcc)],'mergedRegion':_0x48f7d3['region'],'appName':_0x5352e1});return{'name':_0x5352e1,'appcode':_0x2adaea?.['appcode']||'','apiGroup':optionalString(_0x2adaea?.[_0x4737ac(0xa5)]),'isDefault':_0x5352e1===_0x267899,'region':_0x1a1952[_0x4737ac(0xcc)],'regionSource':_0x1a1952[_0x4737ac(0xd1)],'env':_0x2adaea?.[_0x4737ac(0xc6)],'apiDir':optionalString(_0x2adaea?.[_0x4737ac(0xa4)])||optionalString(_0x48f7d3[_0x4737ac(0xa4)]),'cookie':_0x2adaea?.['cookie']||undefined,'routingConfig':pickConnectionRoutingConfig(_0x48f7d3,_0x1a1952[_0x4737ac(0xcc)])};})[_0x2b8713(0xae)](_0x31c70b=>_0x31c70b['appcode']);}export function getTemplateBaseUrl(_0x587ee2){const _0x5c39d1=a275_0xa44581,_0x377d56=readRawConfig(_0x587ee2);if(_0x377d56[_0x5c39d1(0xb7)]&&typeof _0x377d56[_0x5c39d1(0xb7)]===_0x5c39d1(0xcb))return _0x377d56[_0x5c39d1(0xb7)]['replace'](/\/$/,'');return _0x5c39d1(0x8d);}function buildConfig(_0x14b13c,_0x2183ec,_0x5e781c){const _0x414933=a275_0xa44581,_0x1117aa=resolveAppConfig({'raw':_0x14b13c,'flags':_0x2183ec,'layers':_0x5e781c,'readEnv':env}),_0x25dce8=_0x1117aa[_0x414933(0xd4)]?_0x1117aa['apps'][_0x1117aa[_0x414933(0xd4)]]:undefined;return{..._0x1117aa,'raw':withAppProfileRouting(_0x14b13c,_0x25dce8)};}export function resolveApiFilePath(_0x32b97a,_0x45b716,_0x9547e6){return resolveApiModelSource(_0x32b97a,_0x45b716,_0x9547e6)['filePath'];}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a276_0x53a4b9=a276_0x5b33;function a276_0x474b(){const _0x1bede9=['2781995kVdrPa','.cjs','.ts','.tsx','12TElxms','get','api.ts','.mjs','520TLcmUs','datasetCode','96138JUEAvB','slice','push','flags','isFile','add','map','.mts','432870aqwSww','2831290wUJxIF','alias','.js','1425724szkkep','6489156PTaFzf','.jsx','startsWith','name','size','.cts','has','664rACdkm','endsWith','tableName','exec','14388nfepvO','flatMap','stringify','set','filter','cwd'];a276_0x474b=function(){return _0x1bede9;};return a276_0x474b();}(function(_0x408823,_0x4bfe18){const _0x43c187=a276_0x5b33,_0xfa2055=_0x408823();while(!![]){try{const _0x4152dc=parseInt(_0x43c187(0x16d))/0x1+-parseInt(_0x43c187(0x15f))/0x2*(-parseInt(_0x43c187(0x151))/0x3)+-parseInt(_0x43c187(0x16e))/0x4+-parseInt(_0x43c187(0x157))/0x5*(-parseInt(_0x43c187(0x15b))/0x6)+-parseInt(_0x43c187(0x16a))/0x7+parseInt(_0x43c187(0x14d))/0x8*(-parseInt(_0x43c187(0x161))/0x9)+-parseInt(_0x43c187(0x169))/0xa;if(_0x4152dc===_0x4bfe18)break;else _0xfa2055['push'](_0xfa2055['shift']());}catch(_0x2451f7){_0xfa2055['push'](_0xfa2055['shift']());}}}(a276_0x474b,0xca59e));import{existsSync,readFileSync,realpathSync,statSync}from'node:fs';import{dirname,extname,isAbsolute,relative,resolve}from'node:path';import{MODEL_REGISTRY_FILE_NAME,getProfileModels,readModelRegistry}from'../api/model-registry-file.js';import{parseLegacyApiModels}from'../api/legacy-api-file.js';function a276_0x5b33(_0x10aee7,_0x360e0e){_0x10aee7=_0x10aee7-0x147;const _0x474b0b=a276_0x474b();let _0x5b336c=_0x474b0b[_0x10aee7];return _0x5b336c;}import{findProjectRootDirectory}from'../context/config-loader.js';const cache=new Map(),MAX_LOCAL_REEXPORT_DEPTH=0x8,SOURCE_FILE_EXTENSIONS=[a276_0x53a4b9(0x159),a276_0x53a4b9(0x15a),a276_0x53a4b9(0x168),'.cts',a276_0x53a4b9(0x16c),a276_0x53a4b9(0x147),a276_0x53a4b9(0x15e),a276_0x53a4b9(0x158)],LOCAL_REEXPORT_RE=/\bexport\s+(?:type\s+)?(?:\{[\s\S]*?\}|\*)\s+from\s*["']([^"']+)["']/g,SOURCE_EXTENSIONS_BY_RUNTIME_EXTENSION={'.js':[a276_0x53a4b9(0x159),a276_0x53a4b9(0x15a)],'.jsx':[a276_0x53a4b9(0x15a)],'.mjs':[a276_0x53a4b9(0x168)],'.cjs':[a276_0x53a4b9(0x14b)]};function parseApiFile(_0x181ffc){const _0x937ffa=a276_0x53a4b9;return parseLegacyApiModels(_0x181ffc)['flatMap'](_0x195ef7=>_0x195ef7[_0x937ffa(0x16b)]?[{'alias':_0x195ef7[_0x937ffa(0x16b)],'datasetCode':_0x195ef7[_0x937ffa(0x160)],'tableName':_0x195ef7[_0x937ffa(0x14f)],'name':_0x195ef7['name']}]:[]);}function isWithinRoot(_0x5a6ac4,_0x4db3a4){const _0x4cbf6d=a276_0x53a4b9,_0x43c864=relative(_0x5a6ac4,_0x4db3a4);return _0x43c864===''||!_0x43c864[_0x4cbf6d(0x148)]('..')&&!isAbsolute(_0x43c864);}function resolveExistingFile(_0x4cf263){const _0x4a615a=a276_0x53a4b9;if(!existsSync(_0x4cf263))return undefined;try{return statSync(_0x4cf263)[_0x4a615a(0x165)]()?realpathSync(_0x4cf263):undefined;}catch{return undefined;}}function reexportCandidatePaths(_0x5d2f43){const _0x489bcc=a276_0x53a4b9,_0x3d9edb=extname(_0x5d2f43);if(!_0x3d9edb)return[...SOURCE_FILE_EXTENSIONS[_0x489bcc(0x167)](_0x545afc=>''+_0x5d2f43+_0x545afc),...SOURCE_FILE_EXTENSIONS['map'](_0x2433b6=>resolve(_0x5d2f43,'index'+_0x2433b6))];const _0x1081f8=SOURCE_EXTENSIONS_BY_RUNTIME_EXTENSION[_0x3d9edb];if(!_0x1081f8)return[_0x5d2f43];const _0x5f0524=_0x5d2f43[_0x489bcc(0x162)](0x0,-_0x3d9edb['length']);return[..._0x1081f8[_0x489bcc(0x167)](_0xc15e15=>''+_0x5f0524+_0xc15e15),_0x5d2f43];}function resolveLocalReexport(_0x348c0e,_0x235b31,_0x57ad5f){const _0x124f46=a276_0x53a4b9;if(!_0x235b31[_0x124f46(0x148)]('./')&&!_0x235b31[_0x124f46(0x148)]('../'))return undefined;const _0x2699ff=resolve(dirname(_0x348c0e),_0x235b31);if(!isWithinRoot(_0x57ad5f,_0x2699ff))return undefined;for(const _0x43901f of reexportCandidatePaths(_0x2699ff)){const _0x22a2ac=resolveExistingFile(_0x43901f);if(_0x22a2ac&&isWithinRoot(_0x57ad5f,_0x22a2ac))return _0x22a2ac;}return undefined;}function parseApiFileTree(_0x3c8de6,_0x47ee4a,_0x4abdfe,_0x244b3c){const _0x24fc84=a276_0x53a4b9,_0x269a87=resolveExistingFile(_0x3c8de6);if(!_0x269a87)return[];const _0x56a914=_0x4abdfe[_0x24fc84(0x15c)](_0x269a87);if(_0x56a914!==undefined&&_0x56a914<=_0x244b3c)return[];_0x4abdfe[_0x24fc84(0x154)](_0x269a87,_0x244b3c);const _0x489046=readFileSync(_0x269a87,'utf-8'),_0x1228e6=parseApiFile(_0x489046);if(_0x244b3c>=MAX_LOCAL_REEXPORT_DEPTH)return _0x1228e6;const _0x3330bf=new RegExp(LOCAL_REEXPORT_RE['source'],LOCAL_REEXPORT_RE[_0x24fc84(0x164)]);let _0x382b69;while((_0x382b69=_0x3330bf[_0x24fc84(0x150)](_0x489046))!==null){const _0x2b7b77=resolveLocalReexport(_0x269a87,_0x382b69[0x1],_0x47ee4a);_0x2b7b77&&_0x1228e6[_0x24fc84(0x163)](...parseApiFileTree(_0x2b7b77,_0x47ee4a,_0x4abdfe,_0x244b3c+0x1));}return _0x1228e6;}function aliasProjectRoot(_0x378b17){const _0xd57124=findProjectRootDirectory(dirname(_0x378b17));try{return realpathSync(_0xd57124);}catch{return _0xd57124;}}function uniqueAliasEntries(_0x1b14bd){const _0x42e789=a276_0x53a4b9,_0x3bf6cd=new Set();return _0x1b14bd[_0x42e789(0x155)](_0x219268=>{const _0x134945=_0x42e789,_0x568b4d=JSON[_0x134945(0x153)](_0x219268);if(_0x3bf6cd['has'](_0x568b4d))return![];return _0x3bf6cd[_0x134945(0x166)](_0x568b4d),!![];});}export function loadAliasMap(_0x40a102,_0x1349b6,_0x2b86aa,_0x15d67f){const _0x5aea44=a276_0x53a4b9,_0x739f13=resolve(_0x2b86aa??resolve(process[_0x5aea44(0x156)](),_0x40a102,_0x5aea44(0x15d))),_0x344354=_0x15d67f?_0x739f13+'#'+_0x15d67f:_0x739f13;if(cache[_0x5aea44(0x14c)](_0x344354))return cache['get'](_0x344354);if(!existsSync(_0x739f13))return cache['set'](_0x344354,[]),[];try{if(_0x739f13[_0x5aea44(0x14e)](MODEL_REGISTRY_FILE_NAME)){const _0x18f323=readModelRegistry(_0x739f13),_0x2a8b02=_0x15d67f??_0x18f323?.['defaultProfile'],_0x482328=_0x2a8b02&&_0x18f323?getProfileModels(_0x18f323,_0x2a8b02):[],_0x1a4e6e=uniqueAliasEntries(_0x482328[_0x5aea44(0x152)](_0x1fcd0c=>_0x1fcd0c[_0x5aea44(0x16b)]?[{'alias':_0x1fcd0c['alias'],'datasetCode':_0x1fcd0c[_0x5aea44(0x160)],'tableName':_0x1fcd0c['tableName'],'name':_0x1fcd0c[_0x5aea44(0x149)]}]:[]));return cache[_0x5aea44(0x154)](_0x344354,_0x1a4e6e),_0x1a4e6e;}const _0x4c8e95=uniqueAliasEntries(parseApiFileTree(_0x739f13,aliasProjectRoot(_0x739f13),new Map(),0x0));return cache[_0x5aea44(0x154)](_0x344354,_0x4c8e95),_0x4c8e95;}catch{return cache[_0x5aea44(0x154)](_0x344354,[]),[];}}export function resolveAlias(_0x137b62,_0x2f18a4,_0x94c91d,_0x321811,_0x4db877){const _0x1c80cd=a276_0x53a4b9;if(!_0x2f18a4)return undefined;const _0x4b5b45=loadAliasMap(_0x137b62,_0x94c91d,_0x321811,_0x4db877),_0x20468b=new Set(_0x4b5b45[_0x1c80cd(0x155)](_0x1a05d1=>_0x1a05d1[_0x1c80cd(0x16b)]===_0x2f18a4)[_0x1c80cd(0x167)](_0x314c3c=>_0x314c3c[_0x1c80cd(0x160)]));return _0x20468b[_0x1c80cd(0x14a)]===0x1?[..._0x20468b][0x0]:undefined;}export function listAliases(_0x36c92f,_0x5b0448,_0x53f6f2,_0x271111){return loadAliasMap(_0x36c92f,_0x5b0448,_0x53f6f2,_0x271111);}
|