@lovrabet/rabetbase-cli 2.5.9-beta.1 → 2.5.10-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- 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/design-context.js +1 -1
- package/lib/commands/dataset/design-start.js +1 -1
- package/lib/commands/dataset/design-status.js +1 -1
- package/lib/commands/dataset/design-sync-retry.js +1 -1
- package/lib/commands/dataset/design-sync-status.js +1 -1
- package/lib/commands/dataset/design-validate.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/cross-db-analysis-shared.js +1 -1
- package/lib/commands/db/cross-db-analyze-latest.js +1 -1
- package/lib/commands/db/cross-db-analyze-start.js +1 -1
- package/lib/commands/db/cross-db-analyze-status.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/page-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-analysis.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-management-client.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/services/dataset-design/checkpoint.js +1 -1
- package/lib/services/dataset-design/commands.js +1 -1
- package/lib/services/dataset-design/contract.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 +2 -2
- package/skills/rabetbase/SKILL.md +2 -2
- package/skills/rabetbase-dataset-generation/SKILL.md +2 -2
- package/skills/rabetbase-page-generation/SKILL.md +2 -2
- package/skills/rabetbase.manifest.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a190_0x5bd46a=a190_0xf5b3;function a190_0x5b67(){const _0x1c47f8=['\x20failed.','yes','\x20local\x20microfrontend\x20menu(s).','\x20created.','params','Exact\x20comma-separated\x20local\x20page\x20paths\x20to\x20sync','Failed\x20to\x20fetch\x20online\x20menu\x20list','17626444haKjuo','Non-interactive\x20menu\x20sync\x20requires\x20--yes.','targetPages','9042hadpxm','selectedAppName','✓\x20All\x20local\x20pages\x20are\x20already\x20on\x20platform','\x20\x20Continue\x20with\x20creation?','cookie','trim','sync','flag','appCode','POST','\x20menu(s)','filter','12257EkVXNK','appcode','1086aEbpDP','\x20\x20Cancelled.','skipped','Creating\x20','cssUrl','localPages','Confirm\x20non-interactive\x20sync;\x20without\x20--paths,\x20create\x20all\x20missing\x20local\x20pages','Menu\x20sync\x20skipped','length','appName','Prefer\x20appName\x20for\x20shared\x20subapp\x20resources\x20and\x20parentId\x20for\x20planned\x20groups.\x20','message','1283214waSwMa','map','paths','JSON:\x20{\x22appName\x22:\x22store-app\x22,\x22parentId\x22:42,\x22visible\x22:false};\x20jsUrl\x20and\x20cssUrl\x20remain\x20available\x20for\x20individual\x20menu\x20resources.','Preview\x20with\x20--dry-run,\x20then\x20reuse\x20the\x20same\x20--paths\x20and\x20--params\x20with\x20--yes.','failed','\x20created,\x20','/smartapi/menu/create','Register\x20local\x20pages\x20as\x20platform\x20menus','created','Tip:\x20For\x20frontend\x20subapps,\x20prefer\x20Agent-planned\x20menu\x20groups\x20and\x20shared\x20resources.\x20This\x20manual\x20sync\x20workflow\x20remains\x20available\x20as\x20a\x20fallback.','split','898812KeWaWA','boolean','10rzZTwd','Menu\x20sync\x20completed:\x20','validation','str','17607393bDiGyM','Would\x20create\x20','\x20\x20!\x20No\x20local\x20pages\x20found,\x20please\x20create\x20pages\x20first','gray','Menu\x20creation\x20failed','onlinePaths','\x20page(s)','\x20\x20✓\x20Selected:\x20','yellow','3850065SZuPHm','Created\x20','string','cyan','6PJJXHA','✓\x20Menu\x20sync\x20completed:\x20','\x20\x20Create\x20','rawFlags','onlineMenuList','4904OAKkru','No\x20local\x20microfrontend\x20menus\x20would\x20be\x20created.','!\x20No\x20local\x20pages\x20found\x20in\x20src/pages','menu\x20sync\x20--paths\x20requires\x20--yes\x20for\x20execution.','size','jsUrl'];a190_0x5b67=function(){return _0x1c47f8;};return a190_0x5b67();}(function(_0xc6a439,_0x3459d3){const _0x465ad3=a190_0xf5b3,_0x14061b=_0xc6a439();while(!![]){try{const _0xe0657a=parseInt(_0x465ad3(0x1a3))/0x1+parseInt(_0x465ad3(0x189))/0x2*(parseInt(_0x465ad3(0x197))/0x3)+-parseInt(_0x465ad3(0x161))/0x4+-parseInt(_0x465ad3(0x170))/0x5*(-parseInt(_0x465ad3(0x174))/0x6)+parseInt(_0x465ad3(0x195))/0x7*(parseInt(_0x465ad3(0x179))/0x8)+parseInt(_0x465ad3(0x167))/0x9*(-parseInt(_0x465ad3(0x163))/0xa)+-parseInt(_0x465ad3(0x186))/0xb;if(_0xe0657a===_0x3459d3)break;else _0x14061b['push'](_0x14061b['shift']());}catch(_0x45ca5e){_0x14061b['push'](_0x14061b['shift']());}}}(a190_0x5b67,0xef2fc));function a190_0xf5b3(_0x4543cf,_0x30ca8e){_0x4543cf=_0x4543cf-0x15c;const _0x5b67ca=a190_0x5b67();let _0xf5b347=_0x5b67ca[_0x4543cf];return _0xf5b347;}import a190_0xf1f731 from'chalk';import{buildCompareRows,doCreateMenus,fetchMenuData}from'../../commands/menu/shared/logic.js';import{renderCompareTable,renderSyncSummary}from'../../commands/menu/shared/compare-table.js';import{selectPages,askJsUrl,askCssUrl,askConfirm,startSpinner,stopSpinner,isInteractive,requireInteractive}from'../../commands/menu/shared/inquirer.js';import{CliErrors}from'../../errors.js';import{writeCliSideChannelLine}from'../../utils/write-cli-side-channel.js';import{parseMenuSyncParams,resolvePage,runMenuSyncCore}from'../../commands/menu/shared/sync-core.js';import{getLocalPages}from'../../commands/menu/shared/local-pages.js';import{isInProject}from'../../context.js';import{assertSharedResourcesConfigured}from'../../commands/menu/shared/subapp-assets.js';export const menuSync={'service':'menu','command':a190_0x5bd46a(0x18f),'description':a190_0x5bd46a(0x15d),'risk':'write','flags':[{'name':a190_0x5bd46a(0x183),'type':a190_0x5bd46a(0x172),'description':a190_0x5bd46a(0x1a1)+a190_0x5bd46a(0x1a6)},{'name':'paths','type':a190_0x5bd46a(0x172),'description':a190_0x5bd46a(0x184)},{'name':a190_0x5bd46a(0x180),'type':a190_0x5bd46a(0x162),'description':a190_0x5bd46a(0x19d)}],async 'dryRun'(_0x6251ce){const _0x2a1585=a190_0x5bd46a;ensureRunnableContext(_0x6251ce[_0x2a1585(0x177)],_0x6251ce['selectedAppName']);const _0x38c6b4=await runMenuSyncCore(_0x6251ce[_0x2a1585(0x191)],_0x6251ce[_0x2a1585(0x18d)],parsePaths(_0x6251ce[_0x2a1585(0x166)](_0x2a1585(0x1a5))),_0x6251ce[_0x2a1585(0x166)](_0x2a1585(0x183)),{'dryRun':!![]});return{'method':_0x2a1585(0x192),'url':_0x2a1585(0x15c),'body':_0x38c6b4,'description':_0x38c6b4[_0x2a1585(0x199)]?_0x2a1585(0x17a):_0x2a1585(0x168)+_0x38c6b4[_0x2a1585(0x188)][_0x2a1585(0x19f)]+_0x2a1585(0x181)};},async 'execute'(_0x40fbe7){const _0x2f96b1=a190_0x5bd46a;ensureRunnableContext(_0x40fbe7['rawFlags'],_0x40fbe7[_0x2f96b1(0x18a)]);const _0x1dd919=_0x40fbe7[_0x2f96b1(0x190)](_0x2f96b1(0x180)),_0x52f061=_0x40fbe7[_0x2f96b1(0x166)](_0x2f96b1(0x183)),_0x330932=parsePaths(_0x40fbe7[_0x2f96b1(0x166)](_0x2f96b1(0x1a5))),_0x3f4493=parseMenuSyncParams(_0x52f061);if(_0x1dd919){const _0x306752=await runMenuSyncCore(_0x40fbe7['appCode'],_0x40fbe7['cookie'],_0x330932,_0x52f061);if(_0x306752[_0x2f96b1(0x199)]){const _0x4bedd6=getLocalPages();_0x4bedd6[_0x2f96b1(0x19f)]===0x0?writeCliSideChannelLine(_0x2f96b1(0x17b)):writeCliSideChannelLine(_0x2f96b1(0x18b));}else writeCliSideChannelLine(_0x2f96b1(0x175)+_0x306752['created']+'\x20menu(s)\x20created');return{'ok':!![],'data':_0x306752,'message':_0x306752[_0x2f96b1(0x199)]?_0x2f96b1(0x19e):_0x2f96b1(0x164)+_0x306752[_0x2f96b1(0x15e)]+_0x2f96b1(0x182)};}if(_0x330932[_0x2f96b1(0x19f)]>0x0)throw CliErrors[_0x2f96b1(0x165)](_0x2f96b1(0x17c),_0x2f96b1(0x1a7));if(!isInteractive()&&_0x52f061)throw CliErrors['validation'](_0x2f96b1(0x187),_0x2f96b1(0x1a7));requireInteractive(),writeCliSideChannelLine(_0x2f96b1(0x15f));const _0x2910e4=startSpinner('Fetching\x20online\x20menu\x20list...');let _0xef4241,_0x3739a7,_0x259e52;try{const _0x5292ed=await fetchMenuData(_0x40fbe7['appCode'],_0x40fbe7[_0x2f96b1(0x18d)]);_0xef4241=_0x5292ed[_0x2f96b1(0x19c)],_0x3739a7=_0x5292ed[_0x2f96b1(0x16c)],_0x259e52=_0x5292ed[_0x2f96b1(0x178)],stopSpinner(_0x2910e4,'Online\x20menu\x20list\x20fetched',!![]);}catch(_0x4e485f){stopSpinner(_0x2910e4,_0x2f96b1(0x185),![]);throw CliErrors[_0x2f96b1(0x165)](_0x4e485f instanceof Error?_0x4e485f[_0x2f96b1(0x1a2)]:_0x2f96b1(0x185));}if(_0xef4241[_0x2f96b1(0x19f)]===0x0)return writeCliSideChannelLine(a190_0xf1f731[_0x2f96b1(0x16f)](_0x2f96b1(0x169))),{'ok':!![]};const _0xa935da=buildCompareRows(_0xef4241,_0x3739a7);writeCliSideChannelLine(renderCompareTable(_0xa935da)),writeCliSideChannelLine('');const _0x2ffd97=await selectPages(_0xef4241,_0x3739a7);writeCliSideChannelLine(''),writeCliSideChannelLine(a190_0xf1f731[_0x2f96b1(0x173)](_0x2f96b1(0x16e)+_0x2ffd97[_0x2f96b1(0x19f)]+_0x2f96b1(0x16d)));const _0x3db617=_0x3f4493[_0x2f96b1(0x17e)]&&_0x3f4493['cssUrl'];if(!_0x3db617){writeCliSideChannelLine(renderSyncSummary(_0x2ffd97,_0x3739a7[_0x2f96b1(0x17d)]>0x0));const _0x3e8151=await askConfirm(_0x2f96b1(0x18c));if(!_0x3e8151)return writeCliSideChannelLine(a190_0xf1f731[_0x2f96b1(0x16a)]('\x20\x20Cancelled.')),{'ok':!![]};}let _0x3eefed=_0x3f4493[_0x2f96b1(0x17e)],_0x1e61d4=_0x3f4493[_0x2f96b1(0x19b)];!_0x3eefed&&!_0x3f4493[_0x2f96b1(0x1a0)]&&(_0x3eefed=await askJsUrl());!_0x1e61d4&&!_0x3f4493['appName']&&(_0x1e61d4=await askCssUrl());const _0x358acd=await askConfirm(_0x3f4493[_0x2f96b1(0x1a0)]?'\x20\x20Create\x20'+_0x2ffd97[_0x2f96b1(0x19f)]+'\x20menu(s)\x20bound\x20to\x20'+_0x3f4493['appName']+'?':_0x2f96b1(0x176)+_0x2ffd97[_0x2f96b1(0x19f)]+'\x20menu(s)\x20with\x20JS:\x20'+_0x3eefed+'\x20and\x20CSS:\x20'+_0x1e61d4+'?');if(!_0x358acd)return writeCliSideChannelLine(a190_0xf1f731[_0x2f96b1(0x16a)](_0x2f96b1(0x198))),{'ok':!![]};const _0x577fdc=[_0x3eefed,_0x1e61d4][_0x2f96b1(0x194)](_0xb185c4=>Boolean(_0xb185c4));_0x3f4493[_0x2f96b1(0x1a0)]&&_0x577fdc['length']===0x0&&await assertSharedResourcesConfigured(_0x40fbe7['appCode'],_0x40fbe7[_0x2f96b1(0x18d)],_0x3f4493['appName']);const _0x3c8f86=startSpinner(_0x2f96b1(0x19a)+_0x2ffd97[_0x2f96b1(0x19f)]+'\x20menu(s)...');try{const _0x566ba9=_0x2ffd97[_0x2f96b1(0x1a4)](_0x33f508=>resolvePage(_0x33f508,_0x3f4493,_0x259e52)),_0x20b217=await doCreateMenus(_0x40fbe7['appCode'],_0x40fbe7[_0x2f96b1(0x18d)],_0x566ba9,_0x577fdc,_0x3f4493[_0x2f96b1(0x1a0)]?{'appName':_0x3f4493[_0x2f96b1(0x1a0)]}:undefined);return stopSpinner(_0x3c8f86,_0x2f96b1(0x171)+_0x20b217[_0x2f96b1(0x15e)]+_0x2f96b1(0x193),!![]),{'ok':!![],'data':_0x20b217,'message':_0x2f96b1(0x164)+_0x20b217['created']+_0x2f96b1(0x1a9)+_0x20b217[_0x2f96b1(0x1a8)]+_0x2f96b1(0x17f)};}catch(_0x1a5c10){stopSpinner(_0x3c8f86,_0x2f96b1(0x16b),![]);throw CliErrors['validation'](_0x1a5c10 instanceof Error?_0x1a5c10[_0x2f96b1(0x1a2)]:_0x2f96b1(0x16b));}}};function ensureRunnableContext(_0x2a9084,_0x55c91b){const _0x110188=a190_0x5bd46a,_0x1bb055=_0x2a9084[_0x110188(0x196)]?String(_0x2a9084['appcode'])[_0x110188(0x18e)]():'';if(!isInProject()&&!_0x55c91b&&!_0x1bb055)throw CliErrors[_0x110188(0x165)]('menu\x20sync\x20requires\x20a\x20project\x20context\x20or\x20explicit\x20--appcode.\x20'+'Run\x20inside\x20a\x20directory\x20with\x20.rabetbase.json,\x20or\x20pass\x20--appcode\x20<code>.');}function parsePaths(_0x46d50d){const _0x5cdc11=a190_0x5bd46a;return[...new Set(_0x46d50d[_0x5cdc11(0x160)](',')[_0x5cdc11(0x1a4)](_0x161f30=>_0x161f30[_0x5cdc11(0x18e)]())['filter'](Boolean))];}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const a191_0x190d35=a191_0x161a;(function(_0x531383,_0x33df41){const _0x238f17=a191_0x161a,_0x3bbd67=_0x531383();while(!![]){try{const _0x471982=parseInt(_0x238f17(0x129))/0x1+parseInt(_0x238f17(0x17b))/0x2*(-parseInt(_0x238f17(0x14d))/0x3)+-parseInt(_0x238f17(0x13f))/0x4*(-parseInt(_0x238f17(0x16a))/0x5)+parseInt(_0x238f17(0x128))/0x6*(parseInt(_0x238f17(0x14b))/0x7)+parseInt(_0x238f17(0x178))/0x8+parseInt(_0x238f17(0x143))/0x9*(-parseInt(_0x238f17(0x182))/0xa)+-parseInt(_0x238f17(0x16d))/0xb;if(_0x471982===_0x33df41)break;else _0x3bbd67['push'](_0x3bbd67['shift']());}catch(_0x58bd15){_0x3bbd67['push'](_0x3bbd67['shift']());}}}(a191_0x4114,0x3acca));import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{fetchMenuSnapshot}from'../../commands/menu/shared/facts.js';import{asVerificationError,assertVerified,describeMenuErrorCause,fetchMutationSnapshot,hasFlag,isMenuResponseLoss,mapMenuApiError,menuDryRunResult,menuError,menuFailure,mutationResult,recheckMutationSnapshot}from'../../commands/menu/shared/mutations.js';function a191_0x4114(){const _0x5e0997=['childrenCount','label','length','expectedCount','menu_state_drift','\x20must\x20be\x20true\x20or\x20false.','rabetbase\x20menu\x20list\x20--format\x20compress','The\x20update\x20may\x20have\x20taken\x20effect;\x20inspect\x20the\x20latest\x20menu\x20facts\x20before\x20retrying.','menu-ids','validation','type','update-recovery','paths','Menu\x20path\x20selector\x20matched\x20multiple\x20menus:\x20','menu_expected_count_mismatch','Would\x20update\x20visibility\x20for\x20','push','expected-count','some','/smartapi/menu/update','updated','Every\x20selected\x20menu\x20already\x20has\x20the\x20requested\x20visibility;\x20no\x20write\x20is\x20needed.','url','\x20skipped,\x20','rawFlags','\x20visible\x20did\x20not\x20match\x20the\x20requested\x20state.','menu_selector_not_found','565140CgzLaZ','262185NgtYyQ','pageType','warnings','cookie','Menu\x20visibility\x20update\x20completed:\x20','byId','Menu\x20id\x20selector(s)\x20not\x20found:\x20','\x20visibility\x20could\x20not\x20be\x20verified\x20safely','Menu\x20path\x20selector\x20not\x20found:\x20','\x20unchanged\x20menu(s).','update\x20menu\x20visibility','depth','verify\x20menu\x20visibility\x20update','path','update-menu-visibility','Final\x20menu\x20visibility\x20readback\x20failed.','Response\x20was\x20lost\x20and\x20menu\x20','write','code','visible','update\x20visibility\x20for','\x20failed.','12voNrxm','stringify','before','expectVisible','1249137mrtdVu','verification','filter','targets','Selected\x20menu\x20visibility\x20changed\x20for\x20id(s):\x20','\x20changed\x20unexpectedly.','Run\x20the\x20command\x20with\x20--dry-run\x20again\x20and\x20update\x20--expected-count.','join','21McVeCi','Abort\x20unless\x20the\x20exact\x20number\x20of\x20selected\x20menus\x20matches','8097FJrUoE','Selected\x20','Run\x20`rabetbase\x20menu\x20list\x20--format\x20compress`\x20and\x20use\x20exact\x20current\x20ids.','\x20menu(s);\x20skipped\x20','isArray','parentId','menu_verification_failed','map','Set\x20exact\x20menus\x20visible\x20or\x20hidden\x20without\x20changing\x20their\x20routes\x20or\x20resources','has','Exact\x20comma-separated\x20menu\x20paths\x20to\x20update','sort','Run\x20`rabetbase\x20menu\x20list\x20--format\x20compress`\x20and\x20use\x20an\x20exact\x20current\x20path.','datasetCode','number','appCode','visibility-update','--menu-ids\x20must\x20contain\x20positive\x20safe\x20integers.','plannedActions','message','menuIds','datasetId','One\x20or\x20more\x20updates\x20may\x20have\x20changed\x20fields\x20outside\x20visibility;\x20inspect\x20current\x20menu\x20facts\x20before\x20retrying.','plan','Updated\x20visibility\x20for\x20','set','trim','menu','POST','335165iFeheo','Menu\x20','menu\x20list','4590872QNwtHH','boolean','failed','flagMissing','modelType','hash','Exact\x20comma-separated\x20menu\x20IDs\x20to\x20update','childrenIds','\x20was\x20not\x20found\x20during\x20visibility\x20verification.','get','str','3095624enaYVG','num','resources','146gFDgiL','\x20menu(s),\x20expected\x20','expect-visible','menus','Failed\x20update\x20requests\x20were\x20not\x20retried;\x20inspect\x20current\x20menu\x20facts\x20before\x20retrying.','Visibility\x20update\x20requests\x20completed\x20but\x20readback\x20could\x20not\x20confirm\x20the\x20requested\x20state','requestedVisible','20ZkpvSG','pageId','beforeById','resourcesValid'];a191_0x4114=function(){return _0x5e0997;};return a191_0x4114();}import{updateMenuEntity}from'../../commands/menu/shared/service.js';import{CliErrors}from'../../errors.js';const BACKEND=[{'method':a191_0x190d35(0x169),'path':'/smartapi/menu/update'}];export const menuVisibilityUpdate={'service':a191_0x190d35(0x168),'command':a191_0x190d35(0x15d),'description':a191_0x190d35(0x155),'risk':a191_0x190d35(0x13a),'structuredErrors':!![],'flags':[{'name':'menu-ids','type':'string','description':a191_0x190d35(0x173)},{'name':'paths','type':'string','description':a191_0x190d35(0x157)},{'name':a191_0x190d35(0x13c),'type':a191_0x190d35(0x16e),'required':!![],'description':'Requested\x20menu\x20visibility'},{'name':a191_0x190d35(0x17d),'type':a191_0x190d35(0x16e),'description':'Abort\x20unless\x20every\x20selected\x20menu\x20has\x20this\x20visibility'},{'name':'expected-count','type':a191_0x190d35(0x15b),'description':a191_0x190d35(0x14c)},APPCODE_FLAG_OPTIONAL],async 'validate'(_0x50071d){parseInput(_0x50071d);},async 'dryRun'(_0x2929cb){const _0x31a1f0=a191_0x190d35,_0x4c753b=await buildPlan(_0x2929cb,!![]),_0x473dc0=_0x4c753b[_0x31a1f0(0x164)][_0x31a1f0(0x15f)]?.[_0x31a1f0(0x188)]??0x0,_0x2d8566=_0x4c753b[_0x31a1f0(0x164)]['targets'][_0x31a1f0(0x188)]-_0x473dc0;return menuDryRunResult(_0x4c753b[_0x31a1f0(0x164)],{'method':_0x31a1f0(0x169),'url':_0x31a1f0(0x199),'body':{'updates':_0x4c753b['plan'][_0x31a1f0(0x15f)]?.['map'](_0x486f01=>_0x486f01['body'])??[]},'description':_0x31a1f0(0x195)+_0x473dc0+'\x20menu(s);\x20skip\x20'+_0x2d8566+_0x31a1f0(0x132)});},async 'execute'(_0x5a8c66){const _0x58a6dd=a191_0x190d35,_0x1fb75b=await buildPlan(_0x5a8c66,![]);await recheckMutationSnapshot(_0x5a8c66,_0x1fb75b['plan'],_0x58a6dd(0x133));const _0x4d748f=[],_0x1936e3=[],_0x5ad471=[];for(const _0x2e6f20 of _0x1fb75b[_0x58a6dd(0x164)][_0x58a6dd(0x146)]){if(_0x2e6f20[_0x58a6dd(0x141)][_0x58a6dd(0x13c)]===_0x1fb75b[_0x58a6dd(0x164)][_0x58a6dd(0x181)]){_0x4d748f[_0x58a6dd(0x196)]({'id':_0x2e6f20['id'],'updated':![],'skipped':!![]});continue;}try{await updateMenuEntity(_0x5a8c66[_0x58a6dd(0x15c)],_0x5a8c66['cookie'],{'id':_0x2e6f20['id'],'visible':_0x1fb75b[_0x58a6dd(0x164)]['requestedVisible']}),_0x4d748f['push']({'id':_0x2e6f20['id'],'updated':!![],'skipped':![]});}catch(_0x5991c0){const _0x5bf9cb=mapMenuApiError(_0x5991c0,_0x58a6dd(0x13d),_0x2e6f20['id']);if(isMenuResponseLoss(_0x5991c0)&&_0x5bf9cb[_0x58a6dd(0x13b)]!=='menu_permission_denied'){_0x5ad471[_0x58a6dd(0x196)](_0x2e6f20['id']);continue;}_0x1936e3[_0x58a6dd(0x196)]({'id':_0x2e6f20['id'],'stage':'update','code':_0x5bf9cb[_0x58a6dd(0x13b)],'message':_0x5bf9cb[_0x58a6dd(0x160)]});}}let _0x34a565;try{_0x34a565=await fetchMenuSnapshot(_0x5a8c66['appCode'],_0x5a8c66[_0x58a6dd(0x12c)]);}catch(_0x1d86ba){const _0x3bc879=describeMenuErrorCause(_0x1d86ba,_0x58a6dd(0x135)),_0x5cdd48=_0x5ad471[_0x58a6dd(0x154)](_0x4e6507=>({'id':_0x4e6507,'stage':'update-recovery','code':_0x58a6dd(0x153),'message':'Response\x20was\x20lost\x20for\x20menu\x20'+_0x4e6507+'\x20and\x20final\x20state\x20could\x20not\x20be\x20read.','requestedStateConfirmed':![],'recovered':![]})),_0x2b507c={'stage':_0x58a6dd(0x144),'code':_0x58a6dd(0x153),'message':_0x58a6dd(0x138),'targetIds':_0x1fb75b[_0x58a6dd(0x164)]['targets'][_0x58a6dd(0x154)](_0x4e5044=>_0x4e5044['id']),'requestedStateConfirmed':![],..._0x3bc879};throw menuFailure(asVerificationError(_0x1d86ba,_0x58a6dd(0x180)),_0x1fb75b[_0x58a6dd(0x164)],{'stage':_0x58a6dd(0x144),'succeeded':_0x4d748f,'failedRecords':[..._0x1936e3,..._0x5cdd48,_0x2b507c],'warnings':[_0x58a6dd(0x18d)],'verification':{'status':_0x58a6dd(0x16f),'recoveredCount':0x0,'lookupCommand':_0x58a6dd(0x18c)}});}const _0x31c1ba=[];for(const _0x39377b of _0x4d748f){const _0xba2a93=Number(_0x39377b['id']),_0x46a8f2=_0x1fb75b[_0x58a6dd(0x184)][_0x58a6dd(0x176)](_0xba2a93),_0x2e841b=_0x34a565[_0x58a6dd(0x12e)]['get'](_0xba2a93);try{verifyVisibilityUpdate(_0x46a8f2,_0x2e841b,_0x1fb75b[_0x58a6dd(0x164)][_0x58a6dd(0x181)]);}catch(_0x3e1308){const _0x4183d3=asVerificationError(_0x3e1308,_0x58a6dd(0x16b)+_0xba2a93+'\x20visibility\x20update\x20could\x20not\x20be\x20verified');_0x31c1ba[_0x58a6dd(0x196)]({'id':_0xba2a93,'stage':_0x58a6dd(0x144),'code':_0x4183d3['code'],'message':_0x4183d3[_0x58a6dd(0x160)],'requestedStateConfirmed':![]});}}for(const _0x1cd2a9 of _0x5ad471){const _0x335fb0=_0x1fb75b[_0x58a6dd(0x184)][_0x58a6dd(0x176)](_0x1cd2a9),_0x274bbf=_0x34a565[_0x58a6dd(0x12e)]['get'](_0x1cd2a9);try{verifyVisibilityUpdate(_0x335fb0,_0x274bbf,_0x1fb75b[_0x58a6dd(0x164)][_0x58a6dd(0x181)]),_0x4d748f[_0x58a6dd(0x196)]({'id':_0x1cd2a9,'updated':!![],'skipped':![],'recovered':!![]});}catch(_0x55442e){const _0x458426=asVerificationError(_0x55442e,_0x58a6dd(0x139)+_0x1cd2a9+_0x58a6dd(0x130));_0x31c1ba['push']({'id':_0x1cd2a9,'stage':_0x58a6dd(0x191),'code':_0x458426[_0x58a6dd(0x13b)],'message':_0x458426['message'],'requestedStateConfirmed':![],'recovered':![]});}}if(_0x31c1ba['length']>0x0){const _0x52ed1c=_0x31c1ba[_0x58a6dd(0x154)](_0x251f12=>Number(_0x251f12['id'])),_0x233c7e=_0x4d748f[_0x58a6dd(0x145)](_0x48f6b0=>_0x48f6b0['recovered']===!![])[_0x58a6dd(0x188)],_0x62f001=menuError(_0x58a6dd(0x153),'Menu\x20visibility\x20update\x20could\x20not\x20be\x20verified\x20for\x20id(s):\x20'+_0x52ed1c['join'](',\x20')+'.','Inspect\x20current\x20menu\x20facts\x20before\x20retrying\x20any\x20target.');throw menuFailure(_0x62f001,_0x1fb75b['plan'],{'stage':_0x58a6dd(0x144),'succeeded':_0x4d748f,'failedRecords':[..._0x1936e3,..._0x31c1ba],'warnings':[_0x58a6dd(0x163)],'verification':{'status':'failed',..._0x52ed1c[_0x58a6dd(0x188)]===0x1?{'targetId':_0x52ed1c[0x0]}:{'targetIds':_0x52ed1c},'recoveredCount':_0x233c7e,'lookupCommand':_0x58a6dd(0x18c)}});}const _0x76af33=_0x4d748f[_0x58a6dd(0x145)](_0x1fad1a=>_0x1fad1a[_0x58a6dd(0x121)]===!![])[_0x58a6dd(0x188)],_0x2c6700=_0x4d748f[_0x58a6dd(0x188)]-_0x76af33,_0x564f22={..._0x1fb75b['plan'],'succeeded':_0x4d748f,'failed':_0x1936e3,'warnings':_0x1936e3[_0x58a6dd(0x188)]>0x0?[..._0x1fb75b[_0x58a6dd(0x164)][_0x58a6dd(0x12b)],_0x58a6dd(0x17f)]:_0x1fb75b[_0x58a6dd(0x164)]['warnings'],'verification':{'checkedBy':_0x58a6dd(0x16c),'snapshotHash':_0x34a565[_0x58a6dd(0x172)],'matchesRequestedState':_0x1936e3[_0x58a6dd(0x188)]===0x0,'recoveredCount':_0x5ad471[_0x58a6dd(0x188)]}};return{'ok':_0x1936e3[_0x58a6dd(0x188)]===0x0,'data':_0x564f22,'message':_0x1936e3['length']===0x0?_0x58a6dd(0x165)+_0x76af33+_0x58a6dd(0x150)+_0x2c6700+'\x20unchanged\x20menu(s).':_0x58a6dd(0x12d)+_0x76af33+'\x20updated,\x20'+_0x2c6700+_0x58a6dd(0x124)+_0x1936e3[_0x58a6dd(0x188)]+_0x58a6dd(0x13e)};}};function a191_0x161a(_0x1986f0,_0x14c4c4){_0x1986f0=_0x1986f0-0x121;const _0x4114a0=a191_0x4114();let _0x161ac9=_0x4114a0[_0x1986f0];return _0x161ac9;}function parseInput(_0x36627b){const _0x89ae6d=a191_0x190d35,_0x4ce574=parseMenuIds(_0x36627b[_0x89ae6d(0x177)](_0x89ae6d(0x18e))),_0x4a1afb=parseCsv(_0x36627b['str'](_0x89ae6d(0x192)));if(_0x4ce574[_0x89ae6d(0x188)]===0x0&&_0x4a1afb[_0x89ae6d(0x188)]===0x0)throw CliErrors['validation']('menu\x20visibility-update\x20requires\x20--menu-ids\x20or\x20--paths.');const _0x53e4b3=parseBooleanFlag(_0x36627b,_0x89ae6d(0x13c),!![]),_0x5925ef=parseBooleanFlag(_0x36627b,'expect-visible',![]);let _0x4d49dd;if(hasFlag(_0x36627b,_0x89ae6d(0x197))){_0x4d49dd=_0x36627b[_0x89ae6d(0x179)](_0x89ae6d(0x197));if(!Number['isSafeInteger'](_0x4d49dd)||_0x4d49dd<0x0)throw CliErrors[_0x89ae6d(0x18f)]('--expected-count\x20must\x20be\x20a\x20non-negative\x20integer.');}return{'menuIds':_0x4ce574,'paths':_0x4a1afb,'visible':_0x53e4b3,'expectVisible':_0x5925ef,'expectedCount':_0x4d49dd};}async function buildPlan(_0x25cc81,_0xe635d){const _0xc77fae=a191_0x190d35,_0x443b46=parseInput(_0x25cc81),_0x4b9c14=await fetchMutationSnapshot(_0x25cc81,_0xc77fae(0x133)),_0x29a617=selectTargets(_0x4b9c14[_0xc77fae(0x17e)],_0x443b46['menuIds'],_0x443b46[_0xc77fae(0x192)]);if(_0x443b46['expectedCount']!==undefined&&_0x29a617[_0xc77fae(0x188)]!==_0x443b46['expectedCount'])throw menuError(_0xc77fae(0x194),_0xc77fae(0x14e)+_0x29a617[_0xc77fae(0x188)]+_0xc77fae(0x17c)+_0x443b46[_0xc77fae(0x189)]+'.',_0xc77fae(0x149));if(_0x443b46[_0xc77fae(0x142)]!==undefined){const _0x54a526=_0x29a617[_0xc77fae(0x145)](_0x2d2d87=>_0x2d2d87[_0xc77fae(0x13c)]!==_0x443b46[_0xc77fae(0x142)]);if(_0x54a526['length']>0x0)throw menuError(_0xc77fae(0x18a),_0xc77fae(0x147)+_0x54a526[_0xc77fae(0x154)](_0x338308=>_0x338308['id'])[_0xc77fae(0x14a)](',\x20')+'.','Run\x20the\x20command\x20with\x20--dry-run\x20again\x20and\x20update\x20--expect-visible.');}const _0xce7a95=_0x29a617[_0xc77fae(0x154)](_0x4153db=>({'id':_0x4153db['id'],'label':_0x4153db['label'],'path':_0x4153db['path'],'before':{'visible':_0x4153db['visible']},'after':{'visible':_0x443b46['visible']}})),_0x2f0473=_0xce7a95['filter'](_0x22be0a=>_0x22be0a[_0xc77fae(0x141)][_0xc77fae(0x13c)]!==_0x443b46[_0xc77fae(0x13c)])['map'](_0xc42811=>({'stage':_0xc77fae(0x137),'method':_0xc77fae(0x169),'path':_0xc77fae(0x199),'body':{'appCode':_0x25cc81[_0xc77fae(0x15c)],'id':_0xc42811['id'],'visible':_0x443b46[_0xc77fae(0x13c)]}})),_0x4d7ae0=mutationResult({'operation':_0xc77fae(0x15d),'selector':{'menuIds':_0x443b46[_0xc77fae(0x161)],'paths':_0x443b46['paths']},'before':{'menus':_0x29a617[_0xc77fae(0x154)](_0x1bb013=>({'id':_0x1bb013['id'],'path':_0x1bb013[_0xc77fae(0x136)],'visible':_0x1bb013[_0xc77fae(0x13c)]}))},'after':{'menus':_0x29a617[_0xc77fae(0x154)](_0x1dda09=>({'id':_0x1dda09['id'],'path':_0x1dda09[_0xc77fae(0x136)],'visible':_0x443b46['visible']}))},'dryRun':_0xe635d,'backend':[...BACKEND],'plannedActions':_0x2f0473,'snapshotHash':_0x4b9c14['hash'],'warnings':_0x2f0473[_0xc77fae(0x188)]===0x0?[_0xc77fae(0x122)]:[]});return{'plan':{..._0x4d7ae0,'requestedVisible':_0x443b46[_0xc77fae(0x13c)],'targets':_0xce7a95},'beforeById':new Map(_0x29a617[_0xc77fae(0x154)](_0x257f38=>[_0x257f38['id'],_0x257f38]))};}function selectTargets(_0x5f4d56,_0x232076,_0x3a0e9a){const _0x152171=a191_0x190d35,_0x55f2bb=new Map(_0x5f4d56[_0x152171(0x154)](_0x51bbc6=>[_0x51bbc6['id'],_0x51bbc6])),_0x25278b=new Map(),_0x113245=_0x232076[_0x152171(0x145)](_0x10eb90=>!_0x55f2bb[_0x152171(0x156)](_0x10eb90));if(_0x113245[_0x152171(0x188)]>0x0)throw menuError(_0x152171(0x127),_0x152171(0x12f)+_0x113245[_0x152171(0x14a)](',\x20')+'.',_0x152171(0x14f));for(const _0x5eee9e of _0x232076){_0x25278b[_0x152171(0x166)](_0x5eee9e,_0x55f2bb[_0x152171(0x176)](_0x5eee9e));}for(const _0x1bc9f0 of _0x3a0e9a){const _0x26c20b=_0x5f4d56[_0x152171(0x145)](_0x3bfb21=>_0x3bfb21[_0x152171(0x136)]===_0x1bc9f0);if(_0x26c20b['length']===0x0)throw menuError('menu_selector_not_found',_0x152171(0x131)+JSON['stringify'](_0x1bc9f0)+'.',_0x152171(0x159));if(_0x26c20b[_0x152171(0x188)]>0x1)throw menuError('menu_selector_ambiguous',_0x152171(0x193)+JSON['stringify'](_0x1bc9f0)+'.','Use\x20--menu-ids\x20with\x20one\x20or\x20more\x20of:\x20'+_0x26c20b[_0x152171(0x154)](_0x2d2f62=>_0x2d2f62['id'])[_0x152171(0x14a)](',\x20')+'.');const _0x659928=_0x26c20b[0x0];_0x25278b[_0x152171(0x166)](_0x659928['id'],_0x659928);}return[..._0x25278b['values']()];}function parseMenuIds(_0xfd8b61){const _0x4ade22=a191_0x190d35,_0x252560=parseCsv(_0xfd8b61),_0x38654b=_0x252560[_0x4ade22(0x154)](Number);if(_0x38654b[_0x4ade22(0x198)](_0x156020=>!Number['isSafeInteger'](_0x156020)||_0x156020<=0x0))throw CliErrors[_0x4ade22(0x18f)](_0x4ade22(0x15e));return[...new Set(_0x38654b)];}function parseCsv(_0x1acc58){const _0x36d646=a191_0x190d35;return[...new Set(_0x1acc58['split'](',')['map'](_0xcbd1db=>_0xcbd1db[_0x36d646(0x167)]())['filter'](Boolean))];}function parseBooleanFlag(_0x2f0d83,_0x3c83ac,_0x35291f){const _0x5609cd=a191_0x190d35;if(!hasFlag(_0x2f0d83,_0x3c83ac)){if(_0x35291f)throw CliErrors[_0x5609cd(0x170)](_0x3c83ac);return undefined;}const _0x16c84b=_0x2f0d83[_0x5609cd(0x125)][_0x3c83ac];if(_0x16c84b===!![]||_0x16c84b===![])return _0x16c84b;if(_0x16c84b==='true')return!![];if(_0x16c84b==='false')return![];throw CliErrors[_0x5609cd(0x18f)]('--'+_0x3c83ac+_0x5609cd(0x18b));}function verifyVisibilityUpdate(_0x5a7097,_0x3c8536,_0x5186a2){const _0x2b325e=a191_0x190d35;assertVerified(!!_0x3c8536,_0x2b325e(0x16b)+_0x5a7097['id']+_0x2b325e(0x175)),assertVerified(_0x3c8536[_0x2b325e(0x13c)]===_0x5186a2,_0x2b325e(0x16b)+_0x5a7097['id']+_0x2b325e(0x126));const _0x10b9d3=[['id',_0x3c8536['id'],_0x5a7097['id']],[_0x2b325e(0x152),_0x3c8536[_0x2b325e(0x152)],_0x5a7097[_0x2b325e(0x152)]],[_0x2b325e(0x134),_0x3c8536[_0x2b325e(0x134)],_0x5a7097[_0x2b325e(0x134)]],['label',_0x3c8536[_0x2b325e(0x187)],_0x5a7097[_0x2b325e(0x187)]],[_0x2b325e(0x136),_0x3c8536['path'],_0x5a7097['path']],['url',_0x3c8536[_0x2b325e(0x123)],_0x5a7097['url']],[_0x2b325e(0x190),_0x3c8536[_0x2b325e(0x190)],_0x5a7097[_0x2b325e(0x190)]],[_0x2b325e(0x158),_0x3c8536[_0x2b325e(0x158)],_0x5a7097[_0x2b325e(0x158)]],[_0x2b325e(0x17a),_0x3c8536[_0x2b325e(0x17a)],_0x5a7097[_0x2b325e(0x17a)]],[_0x2b325e(0x185),_0x3c8536[_0x2b325e(0x185)],_0x5a7097[_0x2b325e(0x185)]],[_0x2b325e(0x174),_0x3c8536[_0x2b325e(0x174)],_0x5a7097[_0x2b325e(0x174)]],[_0x2b325e(0x186),_0x3c8536['childrenCount'],_0x5a7097[_0x2b325e(0x186)]],[_0x2b325e(0x183),_0x3c8536[_0x2b325e(0x183)],_0x5a7097[_0x2b325e(0x183)]],[_0x2b325e(0x12a),_0x3c8536['pageType'],_0x5a7097[_0x2b325e(0x12a)]],[_0x2b325e(0x171),_0x3c8536[_0x2b325e(0x171)],_0x5a7097[_0x2b325e(0x171)]],[_0x2b325e(0x162),_0x3c8536['datasetId'],_0x5a7097[_0x2b325e(0x162)]],[_0x2b325e(0x15a),_0x3c8536[_0x2b325e(0x15a)],_0x5a7097[_0x2b325e(0x15a)]]];for(const [_0x13c2f2,_0x2f4a38,_0x272b71]of _0x10b9d3){assertVerified(sameValue(_0x2f4a38,_0x272b71),_0x2b325e(0x16b)+_0x5a7097['id']+'\x20'+_0x13c2f2+_0x2b325e(0x148));}}function sameValue(_0x56c330,_0x2d56cc){const _0x375e70=a191_0x190d35;if(Array[_0x375e70(0x151)](_0x56c330)||Array['isArray'](_0x2d56cc))return JSON[_0x375e70(0x140)](_0x56c330)===JSON[_0x375e70(0x140)](_0x2d56cc);return _0x56c330===_0x2d56cc;}
|
|
1
|
+
function a191_0x288a(){const _0x457847=['1047000AnWitr','parentId','Run\x20the\x20command\x20with\x20--dry-run\x20again\x20and\x20update\x20--expected-count.','\x20was\x20not\x20found\x20during\x20visibility\x20verification.','some','length','Every\x20selected\x20menu\x20already\x20has\x20the\x20requested\x20visibility;\x20no\x20write\x20is\x20needed.','Run\x20`rabetbase\x20menu\x20list\x20--format\x20compress`\x20and\x20use\x20exact\x20current\x20ids.','datasetCode','Inspect\x20current\x20menu\x20facts\x20before\x20retrying\x20any\x20target.','Menu\x20path\x20selector\x20matched\x20multiple\x20menus:\x20','paths','pageType','str','modelType','expected-count','\x20menu(s);\x20skipped\x20','verification','label','\x20updated,\x20','failed','beforeById','POST','update-recovery','Selected\x20','push','num','18PPsTIr','warnings','isArray','childrenCount','depth','Response\x20was\x20lost\x20and\x20menu\x20','number','get','filter','body','\x20menu(s),\x20expected\x20','cookie','\x20must\x20be\x20true\x20or\x20false.','\x20visibility\x20could\x20not\x20be\x20verified\x20safely','resources','Menu\x20','targets','true','\x20menu(s);\x20skip\x20','plan','menu\x20list','join','trim','url','set','expect-visible','menu_selector_not_found','menu_verification_failed','The\x20update\x20may\x20have\x20taken\x20effect;\x20inspect\x20the\x20latest\x20menu\x20facts\x20before\x20retrying.','boolean','Menu\x20path\x20selector\x20not\x20found:\x20','Selected\x20menu\x20visibility\x20changed\x20for\x20id(s):\x20','map','15850EWFgGU','visibility-update','48ERJFYK','validation','\x20failed.','visible','expectedCount','1012070oOOouz','childrenIds','appCode','Run\x20the\x20command\x20with\x20--dry-run\x20again\x20and\x20update\x20--expect-visible.','code','menu\x20visibility-update\x20requires\x20--menu-ids\x20or\x20--paths.','\x20visible\x20did\x20not\x20match\x20the\x20requested\x20state.','resourcesValid','updated','645532mqimCF','string','update\x20visibility\x20for','\x20changed\x20unexpectedly.','hash','587484sTIlYJ','type','path','--expected-count\x20must\x20be\x20a\x20non-negative\x20integer.','rawFlags','sort','false','requestedVisible','menu_permission_denied','datasetId','Failed\x20update\x20requests\x20were\x20not\x20retried;\x20inspect\x20current\x20menu\x20facts\x20before\x20retrying.','Run\x20`rabetbase\x20menu\x20list\x20--format\x20compress`\x20and\x20use\x20an\x20exact\x20current\x20path.','\x20visibility\x20update\x20could\x20not\x20be\x20verified','--menu-ids\x20must\x20contain\x20positive\x20safe\x20integers.','Menu\x20visibility\x20update\x20could\x20not\x20be\x20verified\x20for\x20id(s):\x20','59311iGjBmO','message','stringify','update-menu-visibility','Menu\x20id\x20selector(s)\x20not\x20found:\x20','update\x20menu\x20visibility','Response\x20was\x20lost\x20for\x20menu\x20','verify\x20menu\x20visibility\x20update','menu_selector_ambiguous','pageId','menuIds','byId','Menu\x20visibility\x20update\x20completed:\x20','before','Use\x20--menu-ids\x20with\x20one\x20or\x20more\x20of:\x20','158270TPZYzc','\x20skipped,\x20','\x20unchanged\x20menu(s).','isSafeInteger','Exact\x20comma-separated\x20menu\x20IDs\x20to\x20update','Abort\x20unless\x20the\x20exact\x20number\x20of\x20selected\x20menus\x20matches','expectVisible','rabetbase\x20menu\x20list\x20--format\x20compress','menu-ids','plannedActions'];a191_0x288a=function(){return _0x457847;};return a191_0x288a();}const a191_0x14ee11=a191_0x2fff;(function(_0x4062e5,_0x26db31){const _0x272498=a191_0x2fff,_0x292f7f=_0x4062e5();while(!![]){try{const _0x226b09=parseInt(_0x272498(0x190))/0x1+parseInt(_0x272498(0x15d))/0x2*(-parseInt(_0x272498(0x15f))/0x3)+parseInt(_0x272498(0x16d))/0x4+-parseInt(_0x272498(0x164))/0x5+parseInt(_0x272498(0x13c))/0x6*(-parseInt(_0x272498(0x181))/0x7)+parseInt(_0x272498(0x19a))/0x8+parseInt(_0x272498(0x172))/0x9;if(_0x226b09===_0x26db31)break;else _0x292f7f['push'](_0x292f7f['shift']());}catch(_0x45d3d5){_0x292f7f['push'](_0x292f7f['shift']());}}}(a191_0x288a,0x27593));import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{fetchMenuSnapshot}from'../../commands/menu/shared/facts.js';import{asVerificationError,assertVerified,describeMenuErrorCause,fetchMutationSnapshot,hasFlag,isMenuResponseLoss,mapMenuApiError,menuDryRunResult,menuError,menuFailure,mutationResult,recheckMutationSnapshot}from'../../commands/menu/shared/mutations.js';import{updateMenuEntity}from'../../commands/menu/shared/service.js';function a191_0x2fff(_0x44ee25,_0x3c48c8){_0x44ee25=_0x44ee25-0x12e;const _0x288a45=a191_0x288a();let _0x2ffff0=_0x288a45[_0x44ee25];return _0x2ffff0;}import{CliErrors}from'../../errors.js';const BACKEND=[{'method':a191_0x14ee11(0x137),'path':'/smartapi/menu/update'}];export const menuVisibilityUpdate={'service':'menu','command':a191_0x14ee11(0x15e),'description':'Set\x20exact\x20menus\x20visible\x20or\x20hidden\x20without\x20changing\x20their\x20routes\x20or\x20resources','risk':'write','structuredErrors':!![],'flags':[{'name':'menu-ids','type':a191_0x14ee11(0x16e),'description':a191_0x14ee11(0x194)},{'name':a191_0x14ee11(0x1a5),'type':a191_0x14ee11(0x16e),'description':'Exact\x20comma-separated\x20menu\x20paths\x20to\x20update'},{'name':a191_0x14ee11(0x162),'type':a191_0x14ee11(0x159),'required':!![],'description':'Requested\x20menu\x20visibility'},{'name':'expect-visible','type':a191_0x14ee11(0x159),'description':'Abort\x20unless\x20every\x20selected\x20menu\x20has\x20this\x20visibility'},{'name':a191_0x14ee11(0x130),'type':a191_0x14ee11(0x142),'description':a191_0x14ee11(0x195)},APPCODE_FLAG_OPTIONAL],async 'validate'(_0x17cbb3){parseInput(_0x17cbb3);},async 'dryRun'(_0x4b42b7){const _0x5e14e6=a191_0x14ee11,_0x5743b9=await buildPlan(_0x4b42b7,!![]),_0xc6e693=_0x5743b9[_0x5e14e6(0x14f)][_0x5e14e6(0x199)]?.[_0x5e14e6(0x19f)]??0x0,_0x132ae4=_0x5743b9['plan'][_0x5e14e6(0x14c)][_0x5e14e6(0x19f)]-_0xc6e693;return menuDryRunResult(_0x5743b9[_0x5e14e6(0x14f)],{'method':_0x5e14e6(0x137),'url':'/smartapi/menu/update','body':{'updates':_0x5743b9[_0x5e14e6(0x14f)][_0x5e14e6(0x199)]?.[_0x5e14e6(0x15c)](_0xecfd57=>_0xecfd57[_0x5e14e6(0x145)])??[]},'description':'Would\x20update\x20visibility\x20for\x20'+_0xc6e693+_0x5e14e6(0x14e)+_0x132ae4+'\x20unchanged\x20menu(s).'});},async 'execute'(_0x2535e9){const _0x12080c=a191_0x14ee11,_0x29adc5=await buildPlan(_0x2535e9,![]);await recheckMutationSnapshot(_0x2535e9,_0x29adc5[_0x12080c(0x14f)],_0x12080c(0x186));const _0x16415c=[],_0x20e279=[],_0x49a0d8=[];for(const _0x4c1d03 of _0x29adc5[_0x12080c(0x14f)][_0x12080c(0x14c)]){if(_0x4c1d03[_0x12080c(0x18e)][_0x12080c(0x162)]===_0x29adc5[_0x12080c(0x14f)][_0x12080c(0x179)]){_0x16415c[_0x12080c(0x13a)]({'id':_0x4c1d03['id'],'updated':![],'skipped':!![]});continue;}try{await updateMenuEntity(_0x2535e9[_0x12080c(0x166)],_0x2535e9['cookie'],{'id':_0x4c1d03['id'],'visible':_0x29adc5[_0x12080c(0x14f)][_0x12080c(0x179)]}),_0x16415c[_0x12080c(0x13a)]({'id':_0x4c1d03['id'],'updated':!![],'skipped':![]});}catch(_0xeefda1){const _0x4758d2=mapMenuApiError(_0xeefda1,_0x12080c(0x16f),_0x4c1d03['id']);if(isMenuResponseLoss(_0xeefda1)&&_0x4758d2[_0x12080c(0x168)]!==_0x12080c(0x17a)){_0x49a0d8[_0x12080c(0x13a)](_0x4c1d03['id']);continue;}_0x20e279[_0x12080c(0x13a)]({'id':_0x4c1d03['id'],'stage':'update','code':_0x4758d2[_0x12080c(0x168)],'message':_0x4758d2['message']});}}let _0x3c8d12;try{_0x3c8d12=await fetchMenuSnapshot(_0x2535e9[_0x12080c(0x166)],_0x2535e9[_0x12080c(0x147)]);}catch(_0xf9c251){const _0x389001=describeMenuErrorCause(_0xf9c251,_0x12080c(0x188)),_0x2ccb02=_0x49a0d8['map'](_0x512dc4=>({'id':_0x512dc4,'stage':_0x12080c(0x138),'code':_0x12080c(0x157),'message':_0x12080c(0x187)+_0x512dc4+'\x20and\x20final\x20state\x20could\x20not\x20be\x20read.','requestedStateConfirmed':![],'recovered':![]})),_0x1fc8df={'stage':_0x12080c(0x132),'code':_0x12080c(0x157),'message':'Final\x20menu\x20visibility\x20readback\x20failed.','targetIds':_0x29adc5[_0x12080c(0x14f)][_0x12080c(0x14c)]['map'](_0x398680=>_0x398680['id']),'requestedStateConfirmed':![],..._0x389001};throw menuFailure(asVerificationError(_0xf9c251,'Visibility\x20update\x20requests\x20completed\x20but\x20readback\x20could\x20not\x20confirm\x20the\x20requested\x20state'),_0x29adc5[_0x12080c(0x14f)],{'stage':_0x12080c(0x132),'succeeded':_0x16415c,'failedRecords':[..._0x20e279,..._0x2ccb02,_0x1fc8df],'warnings':[_0x12080c(0x158)],'verification':{'status':_0x12080c(0x135),'recoveredCount':0x0,'lookupCommand':_0x12080c(0x197)}});}const _0x46609c=[];for(const _0x5daef3 of _0x16415c){const _0x43a7b6=Number(_0x5daef3['id']),_0x536906=_0x29adc5['beforeById'][_0x12080c(0x143)](_0x43a7b6),_0x435024=_0x3c8d12[_0x12080c(0x18c)][_0x12080c(0x143)](_0x43a7b6);try{verifyVisibilityUpdate(_0x536906,_0x435024,_0x29adc5[_0x12080c(0x14f)][_0x12080c(0x179)]);}catch(_0x1919c0){const _0x4d771a=asVerificationError(_0x1919c0,_0x12080c(0x14b)+_0x43a7b6+_0x12080c(0x17e));_0x46609c['push']({'id':_0x43a7b6,'stage':_0x12080c(0x132),'code':_0x4d771a[_0x12080c(0x168)],'message':_0x4d771a[_0x12080c(0x182)],'requestedStateConfirmed':![]});}}for(const _0x3481b6 of _0x49a0d8){const _0x48e9da=_0x29adc5[_0x12080c(0x136)][_0x12080c(0x143)](_0x3481b6),_0x56271d=_0x3c8d12['byId']['get'](_0x3481b6);try{verifyVisibilityUpdate(_0x48e9da,_0x56271d,_0x29adc5[_0x12080c(0x14f)][_0x12080c(0x179)]),_0x16415c[_0x12080c(0x13a)]({'id':_0x3481b6,'updated':!![],'skipped':![],'recovered':!![]});}catch(_0x15d4cd){const _0x3ff25c=asVerificationError(_0x15d4cd,_0x12080c(0x141)+_0x3481b6+_0x12080c(0x149));_0x46609c[_0x12080c(0x13a)]({'id':_0x3481b6,'stage':_0x12080c(0x138),'code':_0x3ff25c[_0x12080c(0x168)],'message':_0x3ff25c[_0x12080c(0x182)],'requestedStateConfirmed':![],'recovered':![]});}}if(_0x46609c[_0x12080c(0x19f)]>0x0){const _0x231140=_0x46609c[_0x12080c(0x15c)](_0x3d844c=>Number(_0x3d844c['id'])),_0x5f3a76=_0x16415c[_0x12080c(0x144)](_0x20472c=>_0x20472c['recovered']===!![])['length'],_0x1348a2=menuError(_0x12080c(0x157),_0x12080c(0x180)+_0x231140[_0x12080c(0x151)](',\x20')+'.',_0x12080c(0x1a3));throw menuFailure(_0x1348a2,_0x29adc5['plan'],{'stage':'verification','succeeded':_0x16415c,'failedRecords':[..._0x20e279,..._0x46609c],'warnings':['One\x20or\x20more\x20updates\x20may\x20have\x20changed\x20fields\x20outside\x20visibility;\x20inspect\x20current\x20menu\x20facts\x20before\x20retrying.'],'verification':{'status':'failed',..._0x231140['length']===0x1?{'targetId':_0x231140[0x0]}:{'targetIds':_0x231140},'recoveredCount':_0x5f3a76,'lookupCommand':_0x12080c(0x197)}});}const _0x3c8ecb=_0x16415c[_0x12080c(0x144)](_0x39f8f7=>_0x39f8f7[_0x12080c(0x16c)]===!![])['length'],_0x138c84=_0x16415c[_0x12080c(0x19f)]-_0x3c8ecb,_0x4a1d0b={..._0x29adc5['plan'],'succeeded':_0x16415c,'failed':_0x20e279,'warnings':_0x20e279[_0x12080c(0x19f)]>0x0?[..._0x29adc5['plan'][_0x12080c(0x13d)],_0x12080c(0x17c)]:_0x29adc5[_0x12080c(0x14f)][_0x12080c(0x13d)],'verification':{'checkedBy':_0x12080c(0x150),'snapshotHash':_0x3c8d12[_0x12080c(0x171)],'matchesRequestedState':_0x20e279['length']===0x0,'recoveredCount':_0x49a0d8['length']}};return{'ok':_0x20e279['length']===0x0,'data':_0x4a1d0b,'message':_0x20e279[_0x12080c(0x19f)]===0x0?'Updated\x20visibility\x20for\x20'+_0x3c8ecb+_0x12080c(0x131)+_0x138c84+_0x12080c(0x192):_0x12080c(0x18d)+_0x3c8ecb+_0x12080c(0x134)+_0x138c84+_0x12080c(0x191)+_0x20e279['length']+_0x12080c(0x161)};}};function parseInput(_0x146878){const _0x2af24d=a191_0x14ee11,_0x10c7d8=parseMenuIds(_0x146878[_0x2af24d(0x12e)](_0x2af24d(0x198))),_0x569d3b=parseCsv(_0x146878[_0x2af24d(0x12e)]('paths'));if(_0x10c7d8[_0x2af24d(0x19f)]===0x0&&_0x569d3b[_0x2af24d(0x19f)]===0x0)throw CliErrors[_0x2af24d(0x160)](_0x2af24d(0x169));const _0x5f4720=parseBooleanFlag(_0x146878,_0x2af24d(0x162),!![]),_0x5b25f8=parseBooleanFlag(_0x146878,_0x2af24d(0x155),![]);let _0x10cb46;if(hasFlag(_0x146878,_0x2af24d(0x130))){_0x10cb46=_0x146878[_0x2af24d(0x13b)](_0x2af24d(0x130));if(!Number[_0x2af24d(0x193)](_0x10cb46)||_0x10cb46<0x0)throw CliErrors[_0x2af24d(0x160)](_0x2af24d(0x175));}return{'menuIds':_0x10c7d8,'paths':_0x569d3b,'visible':_0x5f4720,'expectVisible':_0x5b25f8,'expectedCount':_0x10cb46};}async function buildPlan(_0x4a2f2d,_0x453861){const _0x5ab096=a191_0x14ee11,_0x376379=parseInput(_0x4a2f2d),_0x32f88f=await fetchMutationSnapshot(_0x4a2f2d,'update\x20menu\x20visibility'),_0x1a7708=selectTargets(_0x32f88f['menus'],_0x376379[_0x5ab096(0x18b)],_0x376379[_0x5ab096(0x1a5)]);if(_0x376379[_0x5ab096(0x163)]!==undefined&&_0x1a7708[_0x5ab096(0x19f)]!==_0x376379[_0x5ab096(0x163)])throw menuError('menu_expected_count_mismatch',_0x5ab096(0x139)+_0x1a7708[_0x5ab096(0x19f)]+_0x5ab096(0x146)+_0x376379[_0x5ab096(0x163)]+'.',_0x5ab096(0x19c));if(_0x376379[_0x5ab096(0x196)]!==undefined){const _0x58e9c0=_0x1a7708[_0x5ab096(0x144)](_0x558aee=>_0x558aee[_0x5ab096(0x162)]!==_0x376379[_0x5ab096(0x196)]);if(_0x58e9c0[_0x5ab096(0x19f)]>0x0)throw menuError('menu_state_drift',_0x5ab096(0x15b)+_0x58e9c0[_0x5ab096(0x15c)](_0x8c8ab6=>_0x8c8ab6['id'])[_0x5ab096(0x151)](',\x20')+'.',_0x5ab096(0x167));}const _0x1784ca=_0x1a7708['map'](_0x2da43d=>({'id':_0x2da43d['id'],'label':_0x2da43d[_0x5ab096(0x133)],'path':_0x2da43d[_0x5ab096(0x174)],'before':{'visible':_0x2da43d[_0x5ab096(0x162)]},'after':{'visible':_0x376379[_0x5ab096(0x162)]}})),_0x12f5e6=_0x1784ca['filter'](_0x4de86a=>_0x4de86a[_0x5ab096(0x18e)][_0x5ab096(0x162)]!==_0x376379['visible'])[_0x5ab096(0x15c)](_0xb0f42f=>({'stage':_0x5ab096(0x184),'method':'POST','path':'/smartapi/menu/update','body':{'appCode':_0x4a2f2d[_0x5ab096(0x166)],'id':_0xb0f42f['id'],'visible':_0x376379[_0x5ab096(0x162)]}})),_0x5b6a93=mutationResult({'operation':'visibility-update','selector':{'menuIds':_0x376379[_0x5ab096(0x18b)],'paths':_0x376379[_0x5ab096(0x1a5)]},'before':{'menus':_0x1a7708[_0x5ab096(0x15c)](_0x3e3f6a=>({'id':_0x3e3f6a['id'],'path':_0x3e3f6a['path'],'visible':_0x3e3f6a['visible']}))},'after':{'menus':_0x1a7708[_0x5ab096(0x15c)](_0x5eb5df=>({'id':_0x5eb5df['id'],'path':_0x5eb5df[_0x5ab096(0x174)],'visible':_0x376379[_0x5ab096(0x162)]}))},'dryRun':_0x453861,'backend':[...BACKEND],'plannedActions':_0x12f5e6,'snapshotHash':_0x32f88f[_0x5ab096(0x171)],'warnings':_0x12f5e6[_0x5ab096(0x19f)]===0x0?[_0x5ab096(0x1a0)]:[]});return{'plan':{..._0x5b6a93,'requestedVisible':_0x376379['visible'],'targets':_0x1784ca},'beforeById':new Map(_0x1a7708[_0x5ab096(0x15c)](_0x2a14b8=>[_0x2a14b8['id'],_0x2a14b8]))};}function selectTargets(_0x3f33fa,_0x16c507,_0x401629){const _0x254fe8=a191_0x14ee11,_0x2a3ad6=new Map(_0x3f33fa[_0x254fe8(0x15c)](_0x43a3d0=>[_0x43a3d0['id'],_0x43a3d0])),_0x114a79=new Map(),_0x2ce1bb=_0x16c507[_0x254fe8(0x144)](_0x355e23=>!_0x2a3ad6['has'](_0x355e23));if(_0x2ce1bb[_0x254fe8(0x19f)]>0x0)throw menuError(_0x254fe8(0x156),_0x254fe8(0x185)+_0x2ce1bb[_0x254fe8(0x151)](',\x20')+'.',_0x254fe8(0x1a1));for(const _0x100852 of _0x16c507){_0x114a79[_0x254fe8(0x154)](_0x100852,_0x2a3ad6[_0x254fe8(0x143)](_0x100852));}for(const _0x53c52e of _0x401629){const _0x10b1bb=_0x3f33fa[_0x254fe8(0x144)](_0x17c157=>_0x17c157[_0x254fe8(0x174)]===_0x53c52e);if(_0x10b1bb[_0x254fe8(0x19f)]===0x0)throw menuError(_0x254fe8(0x156),_0x254fe8(0x15a)+JSON[_0x254fe8(0x183)](_0x53c52e)+'.',_0x254fe8(0x17d));if(_0x10b1bb['length']>0x1)throw menuError(_0x254fe8(0x189),_0x254fe8(0x1a4)+JSON[_0x254fe8(0x183)](_0x53c52e)+'.',_0x254fe8(0x18f)+_0x10b1bb[_0x254fe8(0x15c)](_0x31dde7=>_0x31dde7['id'])[_0x254fe8(0x151)](',\x20')+'.');const _0x189f5d=_0x10b1bb[0x0];_0x114a79[_0x254fe8(0x154)](_0x189f5d['id'],_0x189f5d);}return[..._0x114a79['values']()];}function parseMenuIds(_0x2cbdb7){const _0x2c90ec=a191_0x14ee11,_0x10bba9=parseCsv(_0x2cbdb7),_0x36d783=_0x10bba9['map'](Number);if(_0x36d783[_0x2c90ec(0x19e)](_0x2e6356=>!Number[_0x2c90ec(0x193)](_0x2e6356)||_0x2e6356<=0x0))throw CliErrors[_0x2c90ec(0x160)](_0x2c90ec(0x17f));return[...new Set(_0x36d783)];}function parseCsv(_0x2b20f7){const _0x14d05c=a191_0x14ee11;return[...new Set(_0x2b20f7['split'](',')[_0x14d05c(0x15c)](_0x560918=>_0x560918[_0x14d05c(0x152)]())['filter'](Boolean))];}function parseBooleanFlag(_0xe5f15b,_0xfe5ba,_0x3eeb84){const _0x25e32e=a191_0x14ee11;if(!hasFlag(_0xe5f15b,_0xfe5ba)){if(_0x3eeb84)throw CliErrors['flagMissing'](_0xfe5ba);return undefined;}const _0x4acabd=_0xe5f15b[_0x25e32e(0x176)][_0xfe5ba];if(_0x4acabd===!![]||_0x4acabd===![])return _0x4acabd;if(_0x4acabd===_0x25e32e(0x14d))return!![];if(_0x4acabd===_0x25e32e(0x178))return![];throw CliErrors[_0x25e32e(0x160)]('--'+_0xfe5ba+_0x25e32e(0x148));}function verifyVisibilityUpdate(_0x1dd8f5,_0x186cda,_0x4870c2){const _0x16cead=a191_0x14ee11;assertVerified(!!_0x186cda,'Menu\x20'+_0x1dd8f5['id']+_0x16cead(0x19d)),assertVerified(_0x186cda[_0x16cead(0x162)]===_0x4870c2,_0x16cead(0x14b)+_0x1dd8f5['id']+_0x16cead(0x16a));const _0x50fee0=[['id',_0x186cda['id'],_0x1dd8f5['id']],[_0x16cead(0x19b),_0x186cda[_0x16cead(0x19b)],_0x1dd8f5[_0x16cead(0x19b)]],['depth',_0x186cda[_0x16cead(0x140)],_0x1dd8f5[_0x16cead(0x140)]],['label',_0x186cda[_0x16cead(0x133)],_0x1dd8f5[_0x16cead(0x133)]],['path',_0x186cda[_0x16cead(0x174)],_0x1dd8f5[_0x16cead(0x174)]],[_0x16cead(0x153),_0x186cda[_0x16cead(0x153)],_0x1dd8f5[_0x16cead(0x153)]],[_0x16cead(0x173),_0x186cda[_0x16cead(0x173)],_0x1dd8f5['type']],[_0x16cead(0x177),_0x186cda[_0x16cead(0x177)],_0x1dd8f5[_0x16cead(0x177)]],[_0x16cead(0x14a),_0x186cda[_0x16cead(0x14a)],_0x1dd8f5[_0x16cead(0x14a)]],[_0x16cead(0x16b),_0x186cda[_0x16cead(0x16b)],_0x1dd8f5[_0x16cead(0x16b)]],[_0x16cead(0x165),_0x186cda[_0x16cead(0x165)],_0x1dd8f5[_0x16cead(0x165)]],['childrenCount',_0x186cda[_0x16cead(0x13f)],_0x1dd8f5[_0x16cead(0x13f)]],[_0x16cead(0x18a),_0x186cda[_0x16cead(0x18a)],_0x1dd8f5['pageId']],[_0x16cead(0x1a6),_0x186cda[_0x16cead(0x1a6)],_0x1dd8f5[_0x16cead(0x1a6)]],[_0x16cead(0x12f),_0x186cda[_0x16cead(0x12f)],_0x1dd8f5['modelType']],[_0x16cead(0x17b),_0x186cda['datasetId'],_0x1dd8f5[_0x16cead(0x17b)]],['datasetCode',_0x186cda[_0x16cead(0x1a2)],_0x1dd8f5[_0x16cead(0x1a2)]]];for(const [_0x181ef1,_0x266e51,_0x1d32e5]of _0x50fee0){assertVerified(sameValue(_0x266e51,_0x1d32e5),_0x16cead(0x14b)+_0x1dd8f5['id']+'\x20'+_0x181ef1+_0x16cead(0x170));}}function sameValue(_0x4a525c,_0x5f110f){const _0x472fde=a191_0x14ee11;if(Array[_0x472fde(0x13e)](_0x4a525c)||Array[_0x472fde(0x13e)](_0x5f110f))return JSON[_0x472fde(0x183)](_0x4a525c)===JSON[_0x472fde(0x183)](_0x5f110f);return _0x4a525c===_0x5f110f;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a192_0x338b(_0x53e200,_0x51ed1a){_0x53e200=_0x53e200-0x1df;const _0x51dbeb=a192_0x51db();let _0x338b44=_0x51dbeb[_0x53e200];return _0x338b44;}function a192_0x51db(){const _0xd9af82=['Created\x20notification\x20config\x20','configName','isSafeInteger','config-create','document','146264FXHTkQ','readTimeout','82838JtxAco',';\x20no\x20automatic\x20retry\x20was\x20attempted.','14696970fngVvg','62uhDKWB','6aTXYsv','notification','Inspect\x20with\x20','configCode','7088725Txorci','mutation','write','POST','channelType','connectTimeout','Create\x20an\x20app-level\x20notification\x20config\x20from\x20a\x20secure\x20JSON\x20source','notification_config_create_outcome_unknown',';\x20do\x20not\x20resubmit.','endpointUrl','create','15413qyPPsL','32hSmswz','channelConfig','verification','appCode','verified','/notification/channel-config/create','Notification\x20config\x20create\x20outcome\x20is\x20unknown\x20because\x20no\x20server\x20ID\x20was\x20received.','1108572rpxBwB','108IODZFv','Notification\x20config\x20create\x20returned\x20no\x20usable\x20server\x20ID.','planned','3668427mQqrbx','605cACwxs'];a192_0x51db=function(){return _0xd9af82;};return a192_0x51db();}const a192_0x44c356=a192_0x338b;(function(_0x578ea6,_0x215a14){const _0x19b945=a192_0x338b,_0xc6ec1d=_0x578ea6();while(!![]){try{const _0x5f09ca=-parseInt(_0x19b945(0x1f7))/0x1*(parseInt(_0x19b945(0x1e7))/0x2)+parseInt(_0x19b945(0x200))/0x3*(-parseInt(_0x19b945(0x1e2))/0x4)+-parseInt(_0x19b945(0x1ec))/0x5*(parseInt(_0x19b945(0x1e8))/0x6)+parseInt(_0x19b945(0x1e4))/0x7*(parseInt(_0x19b945(0x1f8))/0x8)+parseInt(_0x19b945(0x203))/0x9+-parseInt(_0x19b945(0x1e6))/0xa+parseInt(_0x19b945(0x204))/0xb*(parseInt(_0x19b945(0x1ff))/0xc);if(_0x5f09ca===_0x215a14)break;else _0xc6ec1d['push'](_0xc6ec1d['shift']());}catch(_0x5b6eac){_0xc6ec1d['push'](_0xc6ec1d['shift']());}}}(a192_0x51db,0xd0901));import{asDryRunResult}from'../../commands/common/dry-run.js';import{createNotificationChannelConfig,getNotificationChannelConfig,isPlatformTransportFailure}from'../../core/api-client.js';import{assertSingleNotificationSource,createMutationInput,DEFAULT_NOTIFICATION_CONNECT_TIMEOUT,DEFAULT_NOTIFICATION_READ_TIMEOUT,normalizeExactNotificationConfig,notificationError,notificationLookupCommand,NOTIFICATION_APP_FLAG,NOTIFICATION_INPUT_FLAGS,projectNotificationConfig,readNotificationDocument,safeApiFailure}from'../../commands/notification/shared.js';const CREATE_PATH=a192_0x44c356(0x1fd);async function prepareCreate(_0x4d2850){const _0x5d6fdf=a192_0x44c356,_0x44928d=await readNotificationDocument(_0x4d2850,'create'),_0x15df90=createMutationInput(_0x4d2850['appCode'],_0x44928d);return{'document':_0x44928d,'input':_0x15df90,'planned':projectNotificationConfig({'appCode':_0x4d2850[_0x5d6fdf(0x1fb)],'configName':_0x44928d['configName'],'channelType':_0x44928d[_0x5d6fdf(0x1f0)],'endpointUrl':_0x44928d[_0x5d6fdf(0x1f5)],'channelConfig':_0x44928d[_0x5d6fdf(0x1f9)],'description':_0x44928d['description'],'connectTimeout':_0x44928d[_0x5d6fdf(0x1f1)]??DEFAULT_NOTIFICATION_CONNECT_TIMEOUT,'readTimeout':_0x44928d[_0x5d6fdf(0x1e3)]??DEFAULT_NOTIFICATION_READ_TIMEOUT})};}export const notificationConfigCreate={'service':a192_0x44c356(0x1e9),'command':a192_0x44c356(0x1e0),'description':a192_0x44c356(0x1f2),'risk':a192_0x44c356(0x1ee),'requiresAppCode':!![],'structuredErrors':!![],'flags':[...NOTIFICATION_INPUT_FLAGS,NOTIFICATION_APP_FLAG],async 'validate'(_0xee86e9){assertSingleNotificationSource(_0xee86e9);},async 'dryRun'(_0x41d8c9){const _0x2981ba=a192_0x44c356,_0x22b7d6=await prepareCreate(_0x41d8c9),_0x8fbcb=notificationLookupCommand(_0x41d8c9[_0x2981ba(0x1fb)],_0x22b7d6[_0x2981ba(0x1e1)][_0x2981ba(0x1f0)]);return asDryRunResult({'operation':'create','selector':{'appCode':_0x41d8c9[_0x2981ba(0x1fb)],'configName':_0x22b7d6[_0x2981ba(0x1e1)]['configName'],'channelType':_0x22b7d6['document']['channelType']},'before':null,'after':_0x22b7d6[_0x2981ba(0x202)],'dryRun':!![],'backend':{'method':_0x2981ba(0x1ef),'path':CREATE_PATH},'warnings':[],'verification':{'status':_0x2981ba(0x202),'lookupCommand':_0x8fbcb}},{'method':_0x2981ba(0x1ef),'url':CREATE_PATH});},async 'execute'(_0x4147a4){const _0x4ca101=a192_0x44c356,_0x500720=await prepareCreate(_0x4147a4),_0x50467d=notificationLookupCommand(_0x4147a4['appCode'],_0x500720[_0x4ca101(0x1e1)][_0x4ca101(0x1f0)]);let _0x56697a;try{_0x56697a=await createNotificationChannelConfig(_0x500720['input']);}catch(_0x1caa36){if(isPlatformTransportFailure(_0x1caa36))throw notificationError(_0x4ca101(0x1f3),_0x4ca101(0x1fe),_0x4ca101(0x1ea)+_0x50467d+';\x20do\x20not\x20resubmit.');throw safeApiFailure(_0x4ca101(0x1f6),_0x4ca101(0x1ed),_0x4ca101(0x1ea)+_0x50467d+_0x4ca101(0x1e5));}if(!Number[_0x4ca101(0x1df)](_0x56697a)||_0x56697a<=0x0)throw notificationError('notification_config_create_outcome_unknown',_0x4ca101(0x201),'Inspect\x20with\x20'+_0x50467d+_0x4ca101(0x1f4));let _0x3f8fee;try{const _0x943ca4=await getNotificationChannelConfig(_0x56697a,_0x4147a4['appCode']);_0x3f8fee=normalizeExactNotificationConfig(_0x943ca4,_0x56697a,_0x4147a4['appCode']);}catch{throw safeApiFailure(_0x4ca101(0x1f6),_0x4ca101(0x1fa),_0x4ca101(0x1ea)+_0x50467d+';\x20do\x20not\x20resubmit\x20automatically.');}return{'ok':!![],'data':{'operation':'create','selector':{'appCode':_0x3f8fee['appCode'],'id':_0x3f8fee['id'],'configCode':_0x3f8fee[_0x4ca101(0x1eb)],'configName':_0x3f8fee[_0x4ca101(0x206)],'channelType':_0x3f8fee[_0x4ca101(0x1f0)]},'before':null,'after':projectNotificationConfig(_0x3f8fee),'dryRun':![],'backend':{'method':_0x4ca101(0x1ef),'path':CREATE_PATH},'warnings':[],'verification':{'status':_0x4ca101(0x1fc),'lookupCommand':_0x50467d}},'message':_0x4ca101(0x205)+_0x3f8fee['id']};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
function a193_0x3727(){const _0x1cf134=[';\x20no\x20automatic\x20retry\x20was\x20attempted.',';\x20do\x20not\x20resubmit\x20automatically.','10lFetgT','\x20delete\x20could\x20not\x20be\x20verified.','Deleting\x20this\x20app-level\x20config\x20may\x20make\x20dataset-level\x20channels\x20that\x20reference\x20it\x20unavailable;\x20dataset\x20references\x20were\x20not\x20verified\x20by\x20the\x20CLI.','notification_config_delete_verification_unavailable','2335710HpdKld','Notification\x20config\x20','1712721CKUisI','high-risk-write','appCode','some','/notification/channel-config/delete','Inspect\x20with\x20','69592ZUGZWT','notification_config_delete_verification_failed','notification','8SAtssD','5962ZrBKJo','4929743OWJdBi','planned','Delete\x20response\x20was\x20unavailable;\x20list\x20readback\x20proved\x20ID\x20absence\x20without\x20resubmitting.','2EDEoXh','Deleted\x20notification\x20config\x20','notification_config_delete_outcome_unknown','delete','1641096oqWIVo','verified','mutation','25460gfKJWt','1176244yuUkbg','before','POST','unshift','channelType'];a193_0x3727=function(){return _0x1cf134;};return a193_0x3727();}const a193_0x28efd3=a193_0x4287;(function(_0x57ec71,_0x5a9edd){const _0x1b8fed=a193_0x4287,_0x3e8225=_0x57ec71();while(!![]){try{const _0x4bb71a=parseInt(_0x1b8fed(0xa3))/0x1*(-parseInt(_0x1b8fed(0x9b))/0x2)+-parseInt(_0x1b8fed(0xb8))/0x3+parseInt(_0x1b8fed(0xab))/0x4*(parseInt(_0x1b8fed(0xb2))/0x5)+parseInt(_0x1b8fed(0xb6))/0x6+-parseInt(_0x1b8fed(0xa0))/0x7+parseInt(_0x1b8fed(0x9e))/0x8*(-parseInt(_0x1b8fed(0xa7))/0x9)+-parseInt(_0x1b8fed(0xaa))/0xa*(-parseInt(_0x1b8fed(0x9f))/0xb);if(_0x4bb71a===_0x5a9edd)break;else _0x3e8225['push'](_0x3e8225['shift']());}catch(_0x3e76d2){_0x3e8225['push'](_0x3e8225['shift']());}}}(a193_0x3727,0xcab27));import{asDryRunResult}from'../../commands/common/dry-run.js';import{deleteNotificationChannelConfig,isPlatformTransportFailure,listNotificationChannelConfigs}from'../../core/api-client.js';import{notificationError,notificationLookupCommand,notificationSelector,NOTIFICATION_APP_FLAG,NOTIFICATION_ID_FLAG,projectNotificationConfig,readNotificationId,requireNotificationExplicitYes,requireExactNotificationConfig,safeApiFailure,validateNotificationDeleteReadback}from'../../commands/notification/shared.js';function a193_0x4287(_0x5f0063,_0x150a4f){_0x5f0063=_0x5f0063-0x9b;const _0x372757=a193_0x3727();let _0x428705=_0x372757[_0x5f0063];return _0x428705;}const DELETE_PATH=a193_0x28efd3(0xbc),REFERENCE_WARNING=a193_0x28efd3(0xb4);async function prepareDelete(_0x4e4e9f){const _0x2bba33=a193_0x28efd3,_0x2c6502=readNotificationId(_0x4e4e9f),_0x53dfac=await requireExactNotificationConfig(_0x4e4e9f['appCode'],_0x2c6502,_0x2bba33(0xa6));return{'id':_0x2c6502,'before':_0x53dfac};}export const notificationConfigDelete={'service':a193_0x28efd3(0x9d),'command':'config-delete','description':'Delete\x20an\x20app-level\x20notification\x20config\x20after\x20exact\x20preflight','risk':a193_0x28efd3(0xb9),'requiresAppCode':!![],'structuredErrors':!![],'flags':[NOTIFICATION_ID_FLAG,NOTIFICATION_APP_FLAG],async 'validate'(_0x1d6393){readNotificationId(_0x1d6393),requireNotificationExplicitYes(_0x1d6393);},async 'dryRun'(_0xd88259){const _0x3b3370=a193_0x28efd3,_0x13d61f=await prepareDelete(_0xd88259),_0x4d67f1=notificationLookupCommand(_0xd88259['appCode'],_0x13d61f[_0x3b3370(0xac)]['channelType']);return asDryRunResult({'operation':_0x3b3370(0xa6),'selector':notificationSelector(_0x13d61f[_0x3b3370(0xac)]),'before':projectNotificationConfig(_0x13d61f[_0x3b3370(0xac)]),'after':null,'dryRun':!![],'backend':{'method':'POST','path':DELETE_PATH},'warnings':[REFERENCE_WARNING],'verification':{'status':_0x3b3370(0xa1),'lookupCommand':_0x4d67f1}},{'method':_0x3b3370(0xad),'url':DELETE_PATH});},async 'execute'(_0x107b2b){const _0x420405=a193_0x28efd3;requireNotificationExplicitYes(_0x107b2b);const _0x27c6eb=await prepareDelete(_0x107b2b),_0x19824a=notificationLookupCommand(_0x107b2b[_0x420405(0xba)],_0x27c6eb[_0x420405(0xac)]['channelType']);let _0x1a484b=![];try{await deleteNotificationChannelConfig(_0x27c6eb['id'],_0x107b2b[_0x420405(0xba)]);}catch(_0xd6a6cc){if(!isPlatformTransportFailure(_0xd6a6cc))throw safeApiFailure('delete',_0x420405(0xa9),_0x420405(0xbd)+_0x19824a+_0x420405(0xb0));_0x1a484b=!![];}let _0x514d3b;try{_0x514d3b=await listNotificationChannelConfigs(_0x107b2b[_0x420405(0xba)],_0x27c6eb[_0x420405(0xac)]['channelType']),validateNotificationDeleteReadback(_0x514d3b,_0x107b2b[_0x420405(0xba)],_0x27c6eb[_0x420405(0xac)][_0x420405(0xaf)]);}catch{throw notificationError(_0x1a484b?_0x420405(0xa5):_0x420405(0xb5),_0x420405(0xb7)+_0x27c6eb['id']+_0x420405(0xb3),_0x420405(0xbd)+_0x19824a+_0x420405(0xb1));}if(_0x514d3b[_0x420405(0xbb)](_0x38ecac=>_0x38ecac['id']===_0x27c6eb['id']))throw notificationError(_0x1a484b?_0x420405(0xa5):_0x420405(0x9c),_0x420405(0xb7)+_0x27c6eb['id']+'\x20remains\x20present\x20after\x20delete.','Inspect\x20with\x20'+_0x19824a+';\x20do\x20not\x20resubmit\x20automatically.');const _0x1925a7=[REFERENCE_WARNING];return _0x1a484b&&_0x1925a7[_0x420405(0xae)](_0x420405(0xa2)),{'ok':!![],'data':{'operation':_0x420405(0xa6),'selector':notificationSelector(_0x27c6eb[_0x420405(0xac)]),'before':projectNotificationConfig(_0x27c6eb[_0x420405(0xac)]),'after':null,'dryRun':![],'backend':{'method':_0x420405(0xad),'path':DELETE_PATH},'warnings':_0x1925a7,'verification':{'status':_0x420405(0xa8),'absenceConfirmed':!![],'recoveredAfterUnknownResponse':_0x1a484b,'lookupCommand':_0x19824a}},'message':_0x420405(0xa4)+_0x27c6eb['id']};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a194_0x2eb69e=a194_0x561e;(function(_0x4c57d3,_0x4bb30f){const _0xe821f3=a194_0x561e,_0x5c793a=_0x4c57d3();while(!![]){try{const _0x4c9fa7=-parseInt(_0xe821f3(0x128))/0x1+-parseInt(_0xe821f3(0x123))/0x2*(-parseInt(_0xe821f3(0x12d))/0x3)+-parseInt(_0xe821f3(0x131))/0x4*(-parseInt(_0xe821f3(0x137))/0x5)+-parseInt(_0xe821f3(0x130))/0x6+parseInt(_0xe821f3(0x120))/0x7+-parseInt(_0xe821f3(0x121))/0x8+parseInt(_0xe821f3(0x11c))/0x9;if(_0x4c9fa7===_0x4bb30f)break;else _0x5c793a['push'](_0x5c793a['shift']());}catch(_0x8e90f0){_0x5c793a['push'](_0x5c793a['shift']());}}}(a194_0x379d,0x8dd6b));import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{listNotificationChannelConfigs}from'../../core/api-client.js';function a194_0x561e(_0x289a91,_0x539482){_0x289a91=_0x289a91-0x11b;const _0x379d23=a194_0x379d();let _0x561e19=_0x379d23[_0x289a91];return _0x561e19;}function a194_0x379d(){const _0x186bca=['notification','type','5204612sAPaOp','5819800koqaEE','validation','2WWKuVf','appCode','read','length','map','321329nubuNz','Notification\x20channel\x20type','flat','str','Found\x20','749289MqooEq','\x20notification\x20config(s)','Use\x20--all,\x20or\x20query\x20one\x20explicit\x20--type.','174642LmUuCX','4oxzoYh','bool','List\x20configs\x20for\x20every\x20supported\x20notification\x20channel\x20type','trim','config-list','\x20notification\x20config(s)\x20across\x20all\x20channel\x20types','731405QXCoVa','--all\x20and\x20--type\x20are\x20mutually\x20exclusive.','all','4673898YZJOxJ','string'];a194_0x379d=function(){return _0x186bca;};return a194_0x379d();}import{CliErrors}from'../../errors.js';import{NOTIFICATION_CHANNEL_TYPES,projectNotificationListConfig,readNotificationChannelType}from'../../commands/notification/shared.js';export const notificationConfigList={'service':a194_0x2eb69e(0x11e),'command':a194_0x2eb69e(0x135),'description':'List\x20app-level\x20notification\x20configs\x20and\x20their\x20configCode\x20values','risk':a194_0x2eb69e(0x125),'flags':[APPCODE_FLAG_OPTIONAL,{'name':a194_0x2eb69e(0x11f),'type':a194_0x2eb69e(0x11d),'description':a194_0x2eb69e(0x129),'enum':NOTIFICATION_CHANNEL_TYPES},{'name':a194_0x2eb69e(0x11b),'type':'boolean','default':![],'description':a194_0x2eb69e(0x133)}],async 'validate'(_0x3359ae){const _0x3f2018=a194_0x2eb69e;if(_0x3359ae[_0x3f2018(0x132)](_0x3f2018(0x11b))&&_0x3359ae[_0x3f2018(0x12b)](_0x3f2018(0x11f))[_0x3f2018(0x134)]())throw CliErrors[_0x3f2018(0x122)](_0x3f2018(0x138),_0x3f2018(0x12f));if(_0x3359ae[_0x3f2018(0x132)](_0x3f2018(0x11b)))return;readNotificationChannelType(_0x3359ae);},async 'execute'(_0x2478d6){const _0x5d1906=a194_0x2eb69e;if(_0x2478d6[_0x5d1906(0x132)](_0x5d1906(0x11b))){const _0x2f5a78=await Promise[_0x5d1906(0x11b)](NOTIFICATION_CHANNEL_TYPES['map'](_0x5bba73=>listNotificationChannelConfigs(_0x2478d6[_0x5d1906(0x124)],_0x5bba73))),_0x4b3b45=_0x2f5a78[_0x5d1906(0x12a)]()[_0x5d1906(0x127)](projectNotificationListConfig);return{'ok':!![],'data':{'appCode':_0x2478d6[_0x5d1906(0x124)],'channelTypes':NOTIFICATION_CHANNEL_TYPES,'count':_0x4b3b45[_0x5d1906(0x126)],'configs':_0x4b3b45},'message':'Found\x20'+_0x4b3b45['length']+_0x5d1906(0x136)};}const _0x698e19=readNotificationChannelType(_0x2478d6),_0x4dce4d=await listNotificationChannelConfigs(_0x2478d6[_0x5d1906(0x124)],_0x698e19),_0xb5254a=_0x4dce4d[_0x5d1906(0x127)](projectNotificationListConfig);return{'ok':!![],'data':{'appCode':_0x2478d6['appCode'],'channelType':_0x698e19,'count':_0xb5254a['length'],'configs':_0xb5254a},'message':_0x5d1906(0x12c)+_0xb5254a['length']+'\x20'+_0x698e19+_0x5d1906(0x12e)};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
const a195_0x3aa6ef=a195_0x5321;function a195_0x5321(_0x4a37d9,_0x280908){_0x4a37d9=_0x4a37d9-0x18a;const _0x5c66dc=a195_0x5c66();let _0x53214a=_0x5c66dc[_0x4a37d9];return _0x53214a;}(function(_0x4ffc5b,_0x171ff5){const _0x4ea66f=a195_0x5321,_0x384e20=_0x4ffc5b();while(!![]){try{const _0x94b5e0=parseInt(_0x4ea66f(0x195))/0x1*(-parseInt(_0x4ea66f(0x1a7))/0x2)+-parseInt(_0x4ea66f(0x196))/0x3+parseInt(_0x4ea66f(0x190))/0x4+-parseInt(_0x4ea66f(0x199))/0x5*(-parseInt(_0x4ea66f(0x197))/0x6)+-parseInt(_0x4ea66f(0x1a5))/0x7+-parseInt(_0x4ea66f(0x1a6))/0x8+-parseInt(_0x4ea66f(0x18c))/0x9*(-parseInt(_0x4ea66f(0x19e))/0xa);if(_0x94b5e0===_0x171ff5)break;else _0x384e20['push'](_0x384e20['shift']());}catch(_0x468cc0){_0x384e20['push'](_0x384e20['shift']());}}}(a195_0x5c66,0xb5784));import{asDryRunResult}from'../../commands/common/dry-run.js';import{getNotificationChannelConfig,isPlatformTransportFailure,updateNotificationChannelConfig}from'../../core/api-client.js';function a195_0x5c66(){const _0xebe298=['Update\x20an\x20app-level\x20notification\x20config\x20from\x20a\x20secure\x20JSON\x20patch','1868SNWZkS','2703888aCKbCc','4316532fvEZfW','mutation','10WRQruR','\x20via\x20','payload','\x20with\x20','notification_config_update_verification_unavailable','44190ywKhMl','appCode','high-risk-write','before','Updated\x20notification\x20config\x20','allMatch',';\x20no\x20automatic\x20retry\x20was\x20attempted.','1012914rYUfEl','3153568jksDUQ','938lLDDfn','provesChange','patch',';\x20do\x20not\x20resubmit\x20automatically.','Inspect\x20with\x20--id\x20','update','2763RcWQBQ','POST','notification_config_update_outcome_unknown','Notification\x20config\x20','1056436UhkcCT','verifiedFields','channelType','Inspect\x20ID\x20'];a195_0x5c66=function(){return _0xebe298;};return a195_0x5c66();}import{assertSingleNotificationSource,mergeUpdateInput,normalizeExactNotificationConfig,notificationError,notificationLookupCommand,notificationSelector,NOTIFICATION_APP_FLAG,NOTIFICATION_ID_FLAG,NOTIFICATION_INPUT_FLAGS,plannedUpdateProjection,projectNotificationConfig,readNotificationDocument,readNotificationId,requestedSafeFieldsMatch,requireNotificationExplicitYes,requireExactNotificationConfig,safeApiFailure}from'../../commands/notification/shared.js';const UPDATE_PATH='/notification/channel-config/update';async function prepareUpdate(_0x49cc25){const _0x5a8888=a195_0x5321,_0x29cc09=readNotificationId(_0x49cc25),_0x588458=await readNotificationDocument(_0x49cc25,_0x5a8888(0x18b)),_0x56c6c6=await requireExactNotificationConfig(_0x49cc25[_0x5a8888(0x19f)],_0x29cc09,_0x5a8888(0x18b));return{'id':_0x29cc09,'patch':_0x588458,'before':_0x56c6c6,'payload':mergeUpdateInput(_0x56c6c6,_0x588458),'planned':plannedUpdateProjection(_0x56c6c6,_0x588458)};}export const notificationConfigUpdate={'service':'notification','command':'config-update','description':a195_0x3aa6ef(0x194),'risk':a195_0x3aa6ef(0x1a0),'requiresAppCode':!![],'structuredErrors':!![],'flags':[NOTIFICATION_ID_FLAG,...NOTIFICATION_INPUT_FLAGS,NOTIFICATION_APP_FLAG],async 'validate'(_0x15842c){readNotificationId(_0x15842c),assertSingleNotificationSource(_0x15842c),requireNotificationExplicitYes(_0x15842c);},async 'dryRun'(_0x5e3793){const _0x1fe224=a195_0x3aa6ef,_0x157331=await prepareUpdate(_0x5e3793),_0x33a993=notificationLookupCommand(_0x5e3793[_0x1fe224(0x19f)],_0x157331[_0x1fe224(0x1a1)][_0x1fe224(0x192)]);return asDryRunResult({'operation':_0x1fe224(0x18b),'selector':notificationSelector(_0x157331['before']),'before':projectNotificationConfig(_0x157331[_0x1fe224(0x1a1)]),'after':_0x157331['planned'],'dryRun':!![],'backend':{'method':_0x1fe224(0x18d),'path':UPDATE_PATH},'warnings':[],'verification':{'status':'planned','lookupCommand':_0x33a993}},{'method':_0x1fe224(0x18d),'url':UPDATE_PATH});},async 'execute'(_0x5579a0){const _0x489888=a195_0x3aa6ef;requireNotificationExplicitYes(_0x5579a0);const _0x17e3e1=await prepareUpdate(_0x5579a0),_0x3f4223=notificationLookupCommand(_0x5579a0[_0x489888(0x19f)],_0x17e3e1[_0x489888(0x1a1)][_0x489888(0x192)]);let _0x5075d0=![];try{await updateNotificationChannelConfig(_0x17e3e1[_0x489888(0x19b)]);}catch(_0x4beed0){if(!isPlatformTransportFailure(_0x4beed0))throw safeApiFailure(_0x489888(0x18b),_0x489888(0x198),_0x489888(0x193)+_0x17e3e1['id']+_0x489888(0x19c)+_0x3f4223+_0x489888(0x1a4));_0x5075d0=!![];}let _0x1ae0d4;try{const _0x2d6763=await getNotificationChannelConfig(_0x17e3e1['id'],_0x5579a0[_0x489888(0x19f)]);_0x1ae0d4=normalizeExactNotificationConfig(_0x2d6763,_0x17e3e1['id'],_0x5579a0[_0x489888(0x19f)]);}catch{throw notificationError(_0x5075d0?_0x489888(0x18e):_0x489888(0x19d),_0x489888(0x18f)+_0x17e3e1['id']+'\x20update\x20could\x20not\x20be\x20verified\x20by\x20exact\x20ID.',_0x489888(0x18a)+_0x17e3e1['id']+_0x489888(0x19a)+_0x3f4223+_0x489888(0x1aa));}const _0x5bd989=requestedSafeFieldsMatch(_0x17e3e1['before'],_0x1ae0d4,_0x17e3e1[_0x489888(0x1a9)]);if(!_0x5bd989[_0x489888(0x1a3)]||_0x5075d0&&!_0x5bd989[_0x489888(0x1a8)])throw notificationError(_0x5075d0?_0x489888(0x18e):'notification_config_update_verification_failed',_0x489888(0x18f)+_0x17e3e1['id']+'\x20readback\x20does\x20not\x20prove\x20the\x20requested\x20update.',_0x489888(0x18a)+_0x17e3e1['id']+_0x489888(0x19a)+_0x3f4223+';\x20do\x20not\x20resubmit\x20automatically.');const _0x2c2356=_0x5075d0?['Update\x20response\x20was\x20unavailable;\x20exact-ID\x20readback\x20proved\x20changed\x20safe\x20fields\x20without\x20resubmitting.']:[];return{'ok':!![],'data':{'operation':_0x489888(0x18b),'selector':notificationSelector(_0x1ae0d4),'before':projectNotificationConfig(_0x17e3e1[_0x489888(0x1a1)]),'after':projectNotificationConfig(_0x1ae0d4),'dryRun':![],'backend':{'method':'POST','path':UPDATE_PATH},'warnings':_0x2c2356,'verification':{'status':'verified','recoveredAfterUnknownResponse':_0x5075d0,'verifiedFields':_0x5bd989[_0x489888(0x191)],'lookupCommand':_0x3f4223}},'message':_0x489888(0x1a2)+_0x1ae0d4['id']};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a196_0x53fd(_0x5e35e7,_0x132a80){_0x5e35e7=_0x5e35e7-0x6c;const _0x520e84=a196_0x520e();let _0x53fd09=_0x520e84[_0x5e35e7];return _0x53fd09;}(function(_0x525549,_0x5c5242){const _0x28c285=a196_0x53fd,_0x5bb787=_0x525549();while(!![]){try{const _0x5cb5f9=parseInt(_0x28c285(0x71))/0x1*(parseInt(_0x28c285(0x70))/0x2)+-parseInt(_0x28c285(0x72))/0x3*(-parseInt(_0x28c285(0x6e))/0x4)+parseInt(_0x28c285(0x6f))/0x5*(parseInt(_0x28c285(0x77))/0x6)+parseInt(_0x28c285(0x6d))/0x7+parseInt(_0x28c285(0x6c))/0x8*(parseInt(_0x28c285(0x76))/0x9)+parseInt(_0x28c285(0x74))/0xa+-parseInt(_0x28c285(0x75))/0xb*(parseInt(_0x28c285(0x73))/0xc);if(_0x5cb5f9===_0x5c5242)break;else _0x5bb787['push'](_0x5bb787['shift']());}catch(_0x3fd16a){_0x5bb787['push'](_0x5bb787['shift']());}}}(a196_0x520e,0xd957d));function a196_0x520e(){const _0x2cffd6=['138579HkiTYZ','36785580iVcNhd','9683320iWqoyM','11LnmNiv','999ujTBxw','12ixWzoR','1808zCflKI','5878803fGpGbK','40MPjlLQ','2246890aMcYhA','28746MYrZrv','53YCaLLG'];a196_0x520e=function(){return _0x2cffd6;};return a196_0x520e();}import{notificationConfigList}from'../../commands/notification/config-list.js';import{notificationConfigCreate}from'../../commands/notification/config-create.js';import{notificationConfigUpdate}from'../../commands/notification/config-update.js';import{notificationConfigDelete}from'../../commands/notification/config-delete.js';export const notificationDefinitions=[notificationConfigList,notificationConfigCreate,notificationConfigUpdate,notificationConfigDelete];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const a197_0xe04579=a197_0x4104;(function(_0x4d212b,_0x39d1c8){const _0x4cae5e=a197_0x4104,_0x1efeee=_0x4d212b();while(!![]){try{const _0x331403=parseInt(_0x4cae5e(0x233))/0x1*(-parseInt(_0x4cae5e(0x238))/0x2)+-parseInt(_0x4cae5e(0x221))/0x3*(-parseInt(_0x4cae5e(0x265))/0x4)+parseInt(_0x4cae5e(0x23d))/0x5*(parseInt(_0x4cae5e(0x22e))/0x6)+-parseInt(_0x4cae5e(0x253))/0x7*(parseInt(_0x4cae5e(0x224))/0x8)+-parseInt(_0x4cae5e(0x1fb))/0x9*(-parseInt(_0x4cae5e(0x25d))/0xa)+-parseInt(_0x4cae5e(0x1f7))/0xb+parseInt(_0x4cae5e(0x250))/0xc;if(_0x331403===_0x39d1c8)break;else _0x1efeee['push'](_0x1efeee['shift']());}catch(_0x2d3f52){_0x1efeee['push'](_0x1efeee['shift']());}}}(a197_0x32f1,0xe8f11));import{readFile}from'node:fs/promises';import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';function a197_0x4104(_0xffadff,_0x13c274){_0xffadff=_0xffadff-0x1ef;const _0x32f1eb=a197_0x32f1();let _0x410490=_0x32f1eb[_0xffadff];return _0x410490;}import{getNotificationChannelConfig}from'../../core/api-client.js';import{CliError,CliErrors}from'../../errors.js';export const NOTIFICATION_CHANNEL_TYPES=['EMAIL',a197_0xe04579(0x216),a197_0xe04579(0x272),'WECOM','WEBHOOK'];export const DEFAULT_NOTIFICATION_CONNECT_TIMEOUT=0x1388;export const DEFAULT_NOTIFICATION_READ_TIMEOUT=0x2710;const ALLOWED_INPUT_FIELDS=new Set(['configName',a197_0xe04579(0x217),a197_0xe04579(0x21a),a197_0xe04579(0x22f),'description',a197_0xe04579(0x247),a197_0xe04579(0x219)]),FORBIDDEN_IDENTITY_FIELDS=new Set(['id',a197_0xe04579(0x257),a197_0xe04579(0x266),'channelCode']),EMAIL_RECIPIENT_FIELDS=new Set([a197_0xe04579(0x245),'recipients',a197_0xe04579(0x1fe),'bccList','replyTo',a197_0xe04579(0x26b),a197_0xe04579(0x20b),'to','cc']);export const NOTIFICATION_INPUT_FLAGS=[{'name':a197_0xe04579(0x20e),'type':a197_0xe04579(0x213),'required':![],'description':'Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20UTF-8\x20file'},{'name':a197_0xe04579(0x1f2),'type':'boolean','required':![],'default':![],'description':a197_0xe04579(0x25c)},{'name':a197_0xe04579(0x21d),'type':a197_0xe04579(0x213),'required':![],'description':a197_0xe04579(0x1ef)}];export const NOTIFICATION_ID_FLAG={'name':'id','type':a197_0xe04579(0x21b),'required':!![],'description':a197_0xe04579(0x26c)};export const NOTIFICATION_APP_FLAG=APPCODE_FLAG_OPTIONAL;export function notificationError(_0x326e4d,_0x1346dc,_0x4c39a4){return new CliError(_0x326e4d,0x1,_0x1346dc,_0x4c39a4);}export function readNotificationId(_0x1b646d){const _0x23df7f=a197_0xe04579,_0x165943=_0x1b646d[_0x23df7f(0x22b)]('id');if(!Number[_0x23df7f(0x271)](_0x165943)||_0x165943<=0x0)throw notificationError(_0x23df7f(0x20a),'--id\x20must\x20be\x20a\x20positive\x20safe\x20integer.');return _0x165943;}export function requireNotificationExplicitYes(_0x3cfd89){const _0x2664a6=a197_0xe04579;if(_0x3cfd89[_0x2664a6(0x241)](_0x2664a6(0x223))||_0x3cfd89[_0x2664a6(0x241)](_0x2664a6(0x244)))return;throw notificationError(_0x2664a6(0x22d),_0x2664a6(0x23f),_0x2664a6(0x25e));}export function readNotificationChannelType(_0x17d9aa,_0x546bd0=a197_0xe04579(0x1f6),_0xd37c3f=a197_0xe04579(0x24e)){const _0x34a5ae=a197_0xe04579,_0xa7ee46=_0x17d9aa['str'](_0x546bd0)[_0x34a5ae(0x208)]()||_0xd37c3f;if(!NOTIFICATION_CHANNEL_TYPES[_0x34a5ae(0x255)](_0xa7ee46))throw CliErrors[_0x34a5ae(0x22c)](_0x34a5ae(0x269)+_0x546bd0+':\x20'+_0xa7ee46,_0x34a5ae(0x242)+NOTIFICATION_CHANNEL_TYPES[_0x34a5ae(0x23a)](',\x20')+'.');return _0xa7ee46;}export function assertSingleNotificationSource(_0x4120dc){const _0x11b7fb=a197_0xe04579,_0x4db16a=[],_0x389150=_0x4120dc[_0x11b7fb(0x252)](_0x11b7fb(0x20e))['trim']();if(_0x389150)_0x4db16a[_0x11b7fb(0x270)]({'kind':_0x11b7fb(0x20e),'path':_0x389150});if(_0x4120dc['bool']('stdin'))_0x4db16a[_0x11b7fb(0x270)]({'kind':'stdin'});const _0x33656f=_0x4120dc['str'](_0x11b7fb(0x21d))['trim']();if(_0x33656f)_0x4db16a[_0x11b7fb(0x270)]({'kind':_0x11b7fb(0x26a),'name':_0x33656f});if(_0x4db16a[_0x11b7fb(0x226)]===0x0)throw CliErrors[_0x11b7fb(0x22c)](_0x11b7fb(0x25a),_0x11b7fb(0x273));if(_0x4db16a['length']>0x1)throw CliErrors['validation']('Notification\x20JSON\x20source\x20is\x20ambiguous.','Use\x20exactly\x20one\x20of\x20--file\x20<path>,\x20--stdin,\x20or\x20--from-env\x20<NAME>.');return _0x4db16a[0x0];}export async function readNotificationDocument(_0x3f8a06,_0xa2cfeb){const _0x432a23=a197_0xe04579,_0x1266f4=assertSingleNotificationSource(_0x3f8a06),_0x1bff7f=_0x1266f4[_0x432a23(0x259)]===_0x432a23(0x20e)?_0x432a23(0x227)+_0x1266f4[_0x432a23(0x23e)]:_0x1266f4[_0x432a23(0x259)]==='env'?'environment\x20variable\x20'+_0x1266f4[_0x432a23(0x205)]:_0x432a23(0x1f2);let _0x464939;try{if(_0x1266f4[_0x432a23(0x259)]===_0x432a23(0x20e))_0x464939=await readFile(_0x1266f4[_0x432a23(0x23e)],_0x432a23(0x206));else{if(_0x1266f4[_0x432a23(0x259)]==='env'){if(!(_0x1266f4[_0x432a23(0x205)]in process.env))throw notificationError('notification_config_source_unavailable',_0x432a23(0x211)+_0x1266f4[_0x432a23(0x205)]);_0x464939=process.env[_0x1266f4.name]??'';}else _0x464939=await readStdin();}}catch(_0xe2dcc2){if(_0xe2dcc2 instanceof CliError)throw _0xe2dcc2;throw notificationError(_0x432a23(0x236),_0x432a23(0x1fd)+_0x1bff7f+'.');}let _0x10d8fc;try{_0x10d8fc=JSON['parse'](_0x464939);}catch{throw notificationError(_0x432a23(0x209),_0x432a23(0x24b)+_0x1bff7f+_0x432a23(0x26f),_0x432a23(0x258));}if(!isJsonObject(_0x10d8fc))throw notificationError('notification_config_json_invalid','Notification\x20JSON\x20from\x20'+_0x1bff7f+_0x432a23(0x23c));return validateNotificationDocument(_0x10d8fc,_0xa2cfeb);}export function projectNotificationListConfig(_0xfed73a,_0x701d11){const _0x272441=a197_0xe04579;return{'id':typeof _0xfed73a['id']===_0x272441(0x21b)?_0xfed73a['id']:null,'configCode':requireResponseString(_0xfed73a[_0x272441(0x266)],_0x272441(0x266),_0x701d11),'configName':requireResponseString(_0xfed73a[_0x272441(0x222)],_0x272441(0x222),_0x701d11),'channelType':requireResponseString(_0xfed73a[_0x272441(0x217)],_0x272441(0x217),_0x701d11),'description':normalizeNullableString(_0xfed73a[_0x272441(0x24d)]),'createTime':normalizeNullableString(_0xfed73a[_0x272441(0x1f4)]),'updateTime':normalizeNullableString(_0xfed73a[_0x272441(0x1f3)])};}export function normalizeExactNotificationConfig(_0x4ba2d9,_0x1ac7f1,_0x5a3a16){const _0x37eea8=a197_0xe04579;if(!Number[_0x37eea8(0x271)](_0x4ba2d9['id'])||_0x4ba2d9['id']!==_0x1ac7f1)throw notificationError(_0x37eea8(0x202),_0x37eea8(0x262)+_0x1ac7f1+'.');if(_0x4ba2d9[_0x37eea8(0x257)]!==_0x5a3a16)throw notificationError(_0x37eea8(0x202),'Notification\x20config\x20'+_0x1ac7f1+_0x37eea8(0x201));const _0x101b29=requireExactString(_0x4ba2d9[_0x37eea8(0x222)],'configName',_0x1ac7f1),_0x54f376=requireExactString(_0x4ba2d9[_0x37eea8(0x266)],'configCode',_0x1ac7f1),_0x39181b=requireExactString(_0x4ba2d9['channelType'],_0x37eea8(0x217),_0x1ac7f1);if(!NOTIFICATION_CHANNEL_TYPES[_0x37eea8(0x255)](_0x39181b))throw notificationError('notification_config_response_invalid',_0x37eea8(0x21e)+_0x1ac7f1+_0x37eea8(0x246));const _0x5a512e=responseNullableString(_0x4ba2d9[_0x37eea8(0x21a)],_0x37eea8(0x21a),_0x1ac7f1),_0x548de2=responseNullableString(_0x4ba2d9[_0x37eea8(0x22f)],_0x37eea8(0x22f),_0x1ac7f1),_0x356151=responseNullableString(_0x4ba2d9['description'],_0x37eea8(0x24d),_0x1ac7f1),_0x471efd=responseNullableTimeout(_0x4ba2d9['connectTimeout'],_0x37eea8(0x247),_0x1ac7f1),_0x266cb3=responseNullableTimeout(_0x4ba2d9[_0x37eea8(0x219)],_0x37eea8(0x219),_0x1ac7f1);return{'id':_0x1ac7f1,'appCode':_0x5a3a16,'configCode':_0x54f376,'configName':_0x101b29,'channelType':_0x39181b,'endpointUrl':redactSensitive(_0x5a512e),'channelConfig':redactSensitive(_0x548de2),'description':_0x356151,'connectTimeout':_0x471efd,'readTimeout':_0x266cb3,'endpointUrlRaw':_0x5a512e,'channelConfigRaw':_0x548de2};}export async function requireExactNotificationConfig(_0x43dd76,_0x1bdff0,_0x49bcbc){const _0x5c1daf=a197_0xe04579;let _0x500016;try{_0x500016=await getNotificationChannelConfig(_0x1bdff0,_0x43dd76);}catch{throw safeApiFailure(_0x49bcbc,_0x5c1daf(0x1f5),_0x5c1daf(0x1f9)+_0x43dd76+_0x5c1daf(0x1fa));}return normalizeExactNotificationConfig(_0x500016,_0x1bdff0,_0x43dd76);}export function projectNotificationConfig(_0x355de0){const _0x4af799=a197_0xe04579;return{'id':_0x355de0['id']??null,'appCode':_0x355de0[_0x4af799(0x257)],'configCode':_0x355de0['configCode']??null,'configName':_0x355de0['configName'],'channelType':_0x355de0[_0x4af799(0x217)],'endpointUrl':redactSensitive(_0x355de0[_0x4af799(0x21a)]),'channelConfig':redactSensitive(_0x355de0['channelConfig']),'description':_0x355de0[_0x4af799(0x24d)]??null,'connectTimeout':_0x355de0['connectTimeout']??null,'readTimeout':_0x355de0[_0x4af799(0x219)]??null};}export function notificationSelector(_0xe4a0f0){const _0x2c90c3=a197_0xe04579;return{'appCode':_0xe4a0f0[_0x2c90c3(0x257)],'id':_0xe4a0f0['id'],'configCode':_0xe4a0f0[_0x2c90c3(0x266)],'configName':_0xe4a0f0['configName'],'channelType':_0xe4a0f0['channelType']};}export function createMutationInput(_0x16dec8,_0x47361f){const _0x3e0a9a=a197_0xe04579;return{'appCode':_0x16dec8,'configName':_0x47361f[_0x3e0a9a(0x222)],'channelType':_0x47361f['channelType'],...hasOwn(_0x47361f,_0x3e0a9a(0x21a))?{'endpointUrl':_0x47361f[_0x3e0a9a(0x21a)]}:{},...hasOwn(_0x47361f,_0x3e0a9a(0x22f))?{'channelConfig':serializeChannelConfig(_0x47361f[_0x3e0a9a(0x22f)])}:{},...hasOwn(_0x47361f,'description')?{'description':_0x47361f[_0x3e0a9a(0x24d)]}:{},...hasOwn(_0x47361f,_0x3e0a9a(0x247))?{'connectTimeout':_0x47361f['connectTimeout']}:{},...hasOwn(_0x47361f,_0x3e0a9a(0x219))?{'readTimeout':_0x47361f[_0x3e0a9a(0x219)]}:{}};}export function mergeUpdateInput(_0x2bcb26,_0x2eade7){const _0x142b21=a197_0xe04579;return{'id':_0x2bcb26['id'],'appCode':_0x2bcb26[_0x142b21(0x257)],'configName':_0x2eade7[_0x142b21(0x222)]??_0x2bcb26['configName'],'channelType':_0x2eade7[_0x142b21(0x217)]??_0x2bcb26[_0x142b21(0x217)],'endpointUrl':hasOwn(_0x2eade7,_0x142b21(0x21a))?_0x2eade7['endpointUrl']:_0x2bcb26[_0x142b21(0x232)],'channelConfig':hasOwn(_0x2eade7,_0x142b21(0x22f))?serializeChannelConfig(_0x2eade7[_0x142b21(0x22f)]):_0x2bcb26[_0x142b21(0x1f1)],'description':hasOwn(_0x2eade7,_0x142b21(0x24d))?_0x2eade7[_0x142b21(0x24d)]:_0x2bcb26[_0x142b21(0x24d)],'connectTimeout':hasOwn(_0x2eade7,_0x142b21(0x247))?_0x2eade7[_0x142b21(0x247)]:_0x2bcb26[_0x142b21(0x247)],'readTimeout':hasOwn(_0x2eade7,_0x142b21(0x219))?_0x2eade7[_0x142b21(0x219)]:_0x2bcb26[_0x142b21(0x219)]};}export function plannedUpdateProjection(_0x4a40ec,_0x4efaef){const _0x26fdc0=a197_0xe04579;return projectNotificationConfig({'id':_0x4a40ec['id'],'appCode':_0x4a40ec[_0x26fdc0(0x257)],'configCode':_0x4a40ec[_0x26fdc0(0x266)],'configName':_0x4efaef[_0x26fdc0(0x222)]??_0x4a40ec[_0x26fdc0(0x222)],'channelType':_0x4efaef[_0x26fdc0(0x217)]??_0x4a40ec[_0x26fdc0(0x217)],'endpointUrl':hasOwn(_0x4efaef,_0x26fdc0(0x21a))?_0x4efaef[_0x26fdc0(0x21a)]:_0x4a40ec[_0x26fdc0(0x232)],'channelConfig':hasOwn(_0x4efaef,_0x26fdc0(0x22f))?_0x4efaef['channelConfig']:_0x4a40ec[_0x26fdc0(0x1f1)],'description':hasOwn(_0x4efaef,_0x26fdc0(0x24d))?_0x4efaef[_0x26fdc0(0x24d)]:_0x4a40ec[_0x26fdc0(0x24d)],'connectTimeout':hasOwn(_0x4efaef,'connectTimeout')?_0x4efaef['connectTimeout']??DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:_0x4a40ec[_0x26fdc0(0x247)],'readTimeout':hasOwn(_0x4efaef,_0x26fdc0(0x219))?_0x4efaef[_0x26fdc0(0x219)]??DEFAULT_NOTIFICATION_READ_TIMEOUT:_0x4a40ec['readTimeout']});}export function requestedSafeFieldsMatch(_0x21ca29,_0x508c12,_0x42e211){const _0x20791f=a197_0xe04579,_0x5ae3e5=[],_0x2c44c5=[],_0x4687bb=[];for(const _0x4eea5c of[_0x20791f(0x222),'channelType','description']){if(!hasOwn(_0x42e211,_0x4eea5c))continue;_0x4687bb[_0x20791f(0x270)](_0x4eea5c),_0x5ae3e5['push'](_0x508c12[_0x4eea5c]===_0x42e211[_0x4eea5c]),_0x2c44c5['push'](_0x21ca29[_0x4eea5c]!==_0x42e211[_0x4eea5c]&&_0x508c12[_0x4eea5c]===_0x42e211[_0x4eea5c]);}for(const _0x43c8d2 of[_0x20791f(0x247),'readTimeout']){if(!hasOwn(_0x42e211,_0x43c8d2))continue;const _0x1f7f1d=_0x42e211[_0x43c8d2]??(_0x43c8d2===_0x20791f(0x247)?DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:DEFAULT_NOTIFICATION_READ_TIMEOUT);_0x4687bb[_0x20791f(0x270)](_0x43c8d2),_0x5ae3e5[_0x20791f(0x270)](_0x508c12[_0x43c8d2]===_0x1f7f1d),_0x2c44c5[_0x20791f(0x270)](_0x21ca29[_0x43c8d2]!==_0x1f7f1d&&_0x508c12[_0x43c8d2]===_0x1f7f1d);}return hasOwn(_0x42e211,_0x20791f(0x21a))&&_0x42e211['endpointUrl']===null&&(_0x4687bb[_0x20791f(0x270)](_0x20791f(0x20c)),_0x5ae3e5[_0x20791f(0x270)](_0x508c12[_0x20791f(0x232)]===null||_0x508c12[_0x20791f(0x232)]===''),_0x2c44c5[_0x20791f(0x270)](_0x21ca29[_0x20791f(0x232)]!==null&&_0x21ca29[_0x20791f(0x232)]!==''&&(_0x508c12['endpointUrlRaw']===null||_0x508c12[_0x20791f(0x232)]===''))),{'allMatch':_0x5ae3e5[_0x20791f(0x200)](Boolean),'provesChange':_0x2c44c5[_0x20791f(0x22a)](Boolean),'verifiedFields':_0x4687bb};}function a197_0x32f1(){const _0xd668f6=['from-env','Notification\x20config\x20','Notification\x20JSON\x20field\x20\x22','\x20has\x20invalid\x20field\x20\x22','128064gbxnsL','configName','dry-run','24uYFSfP','Notification\x20config\x20list\x20item\x20','length','file\x20','notification_config_field_required','update','some','num','validation','notification_config_confirmation_required','6BLHypa','channelConfig','\x22\x20must\x20be\x20a\x20non-empty\x20string.','\x20characters.','endpointUrlRaw','339019rtLXFk','\x22\x20must\x20be\x20a\x20non-negative\x20safe\x20integer\x20or\x20null.','notification_config_channel_field_forbidden','notification_config_source_unavailable','prototype','2DDBWnQ','\x20is\x20missing\x20required\x20field\x20\x22','join','call','\x20must\x20be\x20an\x20object.','4140235iWqBDe','path','This\x20notification\x20config\x20mutation\x20requires\x20explicit\x20--yes.','keys','bool','Allowed\x20values:\x20','Update\x20JSON\x20must\x20contain\x20at\x20least\x20one\x20allowed\x20field.','yes','emailTargets','\x20has\x20an\x20unsupported\x20channelType.','connectTimeout','Item\x20','\x22\x20cannot\x20exceed\x20','object','Notification\x20JSON\x20from\x20','\x22\x20must\x20be\x20','description','EMAIL','_unavailable','10614588sXJfCx','Invalid\x20notification\x20config\x20response.','str','2265557WreLVL','failed','includes','notification_config_update_empty','appCode','Provide\x20one\x20valid\x20JSON\x20object;\x20source\x20contents\x20are\x20not\x20included\x20in\x20errors.','kind','Missing\x20notification\x20JSON\x20source.','notification_config_field_forbidden','Read\x20the\x20notification\x20JSON\x20document\x20from\x20stdin','1285970vHRWXb','Run\x20the\x20command\x20with\x20--dry-run\x20first,\x20then\x20add\x20--yes\x20after\x20reviewing\x20the\x20plan.','\x20--format\x20compress','\x22\x20is\x20forbidden.','notification_config_','Notification\x20config\x20detail\x20did\x20not\x20contain\x20the\x20requested\x20ID\x20','a\x20string\x20or\x20null','\x20has\x20an\x20invalid\x20id.','24qYGuZZ','configCode','Notification\x20JSON\x20channelConfig\x20field\x20\x22','a\x20non-empty\x20string','Invalid\x20--','env','subjectPrefix','Application-level\x20notification\x20config\x20ID','Create\x20JSON\x20requires\x20field\x20','\x20--type\x20','\x20is\x20invalid.','push','isSafeInteger','DINGTALK','Use\x20exactly\x20one\x20of\x20--file\x20<path>,\x20--stdin,\x20or\x20--from-env\x20<NAME>.','Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20named\x20environment\x20variable','\x20has\x20an\x20invalid\x20appCode.','channelConfigRaw','stdin','updateTime','createTime','preflight','type','8067389EcusQo','a\x20supported\x20string','Inspect\x20with\x20rabetbase\x20notification\x20config-list\x20--appcode\x20','\x20--type\x20<CHANNEL_TYPE>\x20--format\x20compress;\x20no\x20mutation\x20was\x20submitted.','72JAuDDj','notification_config_field_invalid','Unable\x20to\x20read\x20notification\x20JSON\x20from\x20','ccList','\x22\x20is\x20controlled\x20by\x20the\x20CLI\x20or\x20server\x20and\x20is\x20forbidden.','every','\x20does\x20not\x20belong\x20to\x20the\x20resolved\x20app.','notification_config_response_invalid','has','\x20has\x20an\x20invalid\x20channelType.','name','utf8','rabetbase\x20notification\x20config-list\x20--appcode\x20','trim','notification_config_json_invalid','notification_config_id_invalid','fromName','endpointUrl:null','create','file','<redacted>','Notification\x20JSON\x20field\x20\x22channelType\x22\x20is\x20unsupported.','Notification\x20JSON\x20environment\x20variable\x20is\x20not\x20set:\x20','hasOwnProperty','string','a\x20JSON\x20object','setEncoding','FEISHU','channelType','\x20failed.','readTimeout','endpointUrl','number','messageTemplate'];a197_0x32f1=function(){return _0xd668f6;};return a197_0x32f1();}export function validateNotificationDeleteReadback(_0x49fca4,_0x5afb89,_0x29c767){const _0x329c6f=a197_0xe04579;for(const [_0x3627da,_0x286c51]of _0x49fca4['entries']()){if(!Number['isSafeInteger'](_0x286c51['id'])||_0x286c51['id']<=0x0)throw notificationError('notification_config_response_invalid',_0x329c6f(0x225)+(_0x3627da+0x1)+_0x329c6f(0x264));if(_0x286c51[_0x329c6f(0x257)]!==_0x5afb89)throw notificationError('notification_config_response_invalid',_0x329c6f(0x225)+(_0x3627da+0x1)+_0x329c6f(0x1f0));if(_0x286c51[_0x329c6f(0x217)]!==_0x29c767)throw notificationError(_0x329c6f(0x202),_0x329c6f(0x225)+(_0x3627da+0x1)+_0x329c6f(0x204));}}export function safeApiFailure(_0xc56284,_0x118cce,_0x484ce2){const _0x49d0df=a197_0xe04579;return notificationError(_0x49d0df(0x261)+_0xc56284+'_'+(_0x118cce==='mutation'?_0x49d0df(0x254):_0x118cce+_0x49d0df(0x24f)),_0x49d0df(0x21e)+_0xc56284+'\x20'+_0x118cce+_0x49d0df(0x218),_0x484ce2);}export function notificationLookupCommand(_0x3ba31f,_0x547359){const _0x2eef10=a197_0xe04579;return _0x2eef10(0x207)+_0x3ba31f+_0x2eef10(0x26e)+_0x547359+_0x2eef10(0x25f);}function validateNotificationDocument(_0x3a88d2,_0x7e4905){const _0x54f771=a197_0xe04579;for(const _0x54e328 of Object[_0x54f771(0x240)](_0x3a88d2)){if(FORBIDDEN_IDENTITY_FIELDS[_0x54f771(0x203)](_0x54e328))throw notificationError(_0x54f771(0x25b),'Notification\x20JSON\x20field\x20\x22'+_0x54e328+_0x54f771(0x1ff));if(!ALLOWED_INPUT_FIELDS[_0x54f771(0x203)](_0x54e328))throw notificationError('notification_config_field_unknown','Unknown\x20notification\x20JSON\x20field\x20\x22'+_0x54e328+'\x22.');}if(_0x7e4905===_0x54f771(0x229)&&Object[_0x54f771(0x240)](_0x3a88d2)[_0x54f771(0x226)]===0x0)throw notificationError(_0x54f771(0x256),_0x54f771(0x243));const _0x707e09={};if(hasOwn(_0x3a88d2,_0x54f771(0x222)))_0x707e09['configName']=validateRequiredString(_0x3a88d2[_0x54f771(0x222)],_0x54f771(0x222),0x80);else{if(_0x7e4905===_0x54f771(0x20d))throw notificationError(_0x54f771(0x228),_0x54f771(0x26d)+'\x22configName\x22.');}if(hasOwn(_0x3a88d2,_0x54f771(0x217))){if(typeof _0x3a88d2[_0x54f771(0x217)]!==_0x54f771(0x213))throw invalidFieldType('channelType',_0x54f771(0x1f8));const _0x5f37a4=_0x3a88d2['channelType']['trim']();if(!NOTIFICATION_CHANNEL_TYPES[_0x54f771(0x255)](_0x5f37a4))throw notificationError(_0x54f771(0x1fc),_0x54f771(0x210),_0x54f771(0x242)+NOTIFICATION_CHANNEL_TYPES[_0x54f771(0x23a)](',\x20')+'.');_0x707e09[_0x54f771(0x217)]=_0x5f37a4;}else{if(_0x7e4905==='create')throw notificationError('notification_config_field_required',_0x54f771(0x26d)+'\x22channelType\x22.');}for(const [_0x113f14,_0x3fc771]of[[_0x54f771(0x21a),0x200],['description',0x100]]){if(!hasOwn(_0x3a88d2,_0x113f14))continue;const _0x6692b6=_0x3a88d2[_0x113f14];if(_0x6692b6!==null&&typeof _0x6692b6!==_0x54f771(0x213))throw invalidFieldType(_0x113f14,_0x54f771(0x263));if(typeof _0x6692b6===_0x54f771(0x213)&&_0x6692b6['length']>_0x3fc771)throw notificationError(_0x54f771(0x1fc),_0x54f771(0x21f)+_0x113f14+'\x22\x20cannot\x20exceed\x20'+_0x3fc771+_0x54f771(0x231));_0x707e09[_0x113f14]=_0x6692b6;}if(hasOwn(_0x3a88d2,_0x54f771(0x22f))){const _0x3357f5=_0x3a88d2['channelConfig'];if(_0x3357f5===null&&_0x7e4905===_0x54f771(0x20d))throw invalidFieldType(_0x54f771(0x22f),_0x54f771(0x214));if(_0x3357f5!==null&&!isJsonObject(_0x3357f5))throw invalidFieldType('channelConfig',_0x7e4905==='update'?'a\x20JSON\x20object\x20or\x20null':_0x54f771(0x214));_0x3357f5!==null&&validateChannelConfigFields(_0x707e09[_0x54f771(0x217)],_0x3357f5),_0x707e09[_0x54f771(0x22f)]=_0x3357f5;}for(const _0x3d650b of[_0x54f771(0x247),_0x54f771(0x219)]){if(!hasOwn(_0x3a88d2,_0x3d650b))continue;const _0x26e996=_0x3a88d2[_0x3d650b];if(_0x26e996!==null&&(!Number[_0x54f771(0x271)](_0x26e996)||_0x26e996<0x0))throw notificationError(_0x54f771(0x1fc),_0x54f771(0x21f)+_0x3d650b+_0x54f771(0x234));_0x707e09[_0x3d650b]=_0x26e996;}return _0x707e09;}function validateRequiredString(_0xf27d7e,_0x44e358,_0x31f6fa){const _0x241cb3=a197_0xe04579;if(typeof _0xf27d7e!==_0x241cb3(0x213))throw invalidFieldType(_0x44e358,_0x241cb3(0x268));const _0x148222=_0xf27d7e[_0x241cb3(0x208)]();if(!_0x148222)throw notificationError(_0x241cb3(0x1fc),'Notification\x20JSON\x20field\x20\x22'+_0x44e358+_0x241cb3(0x230));if(_0x148222[_0x241cb3(0x226)]>_0x31f6fa)throw notificationError(_0x241cb3(0x1fc),'Notification\x20JSON\x20field\x20\x22'+_0x44e358+_0x241cb3(0x249)+_0x31f6fa+_0x241cb3(0x231));return _0x148222;}function validateChannelConfigFields(_0x69ab98,_0x117257){const _0x20ffe2=a197_0xe04579;if(hasOwn(_0x117257,_0x20ffe2(0x21c)))throw forbiddenChannelConfigField(_0x20ffe2(0x21c));if(_0x69ab98===_0x20ffe2(0x24e))for(const _0x47ede9 of EMAIL_RECIPIENT_FIELDS){if(hasOwn(_0x117257,_0x47ede9))throw forbiddenChannelConfigField(_0x47ede9);}}function forbiddenChannelConfigField(_0x26c456){const _0x3dc606=a197_0xe04579;return notificationError(_0x3dc606(0x235),_0x3dc606(0x267)+_0x26c456+_0x3dc606(0x260));}function invalidFieldType(_0x53dcff,_0x49cd52){const _0x550366=a197_0xe04579;return notificationError('notification_config_field_invalid',_0x550366(0x21f)+_0x53dcff+_0x550366(0x24c)+_0x49cd52+'.');}function serializeChannelConfig(_0x206757){return _0x206757===null||_0x206757===undefined?null:JSON['stringify'](_0x206757);}function redactSensitive(_0x2c7a0e){const _0x3f1b70=a197_0xe04579;return _0x2c7a0e===null||_0x2c7a0e===undefined||_0x2c7a0e===''?null:_0x3f1b70(0x20f);}function requireResponseString(_0x1d0b75,_0xa73a2b,_0x2342c2){const _0x338ed1=a197_0xe04579;if(typeof _0x1d0b75!==_0x338ed1(0x213)||_0x1d0b75[_0x338ed1(0x208)]()==='')throw CliErrors['apiError'](_0x338ed1(0x251),_0x338ed1(0x248)+(_0x2342c2+0x1)+_0x338ed1(0x239)+_0xa73a2b+'\x22.');return _0x1d0b75[_0x338ed1(0x208)]();}function requireExactString(_0x56ba8d,_0x55ce66,_0x182e8c){const _0x291891=a197_0xe04579;if(typeof _0x56ba8d!==_0x291891(0x213)||_0x56ba8d[_0x291891(0x208)]()==='')throw notificationError(_0x291891(0x202),'Notification\x20config\x20'+_0x182e8c+_0x291891(0x239)+_0x55ce66+'\x22.');return _0x56ba8d[_0x291891(0x208)]();}function responseNullableString(_0x113d5f,_0x1e6cc5,_0x419eaf){const _0x54eb4f=a197_0xe04579;if(_0x113d5f===undefined||_0x113d5f===null)return null;if(typeof _0x113d5f!==_0x54eb4f(0x213))throw notificationError('notification_config_response_invalid',_0x54eb4f(0x21e)+_0x419eaf+_0x54eb4f(0x220)+_0x1e6cc5+'\x22.');return _0x113d5f;}function responseNullableTimeout(_0x4b73a3,_0xe9c88,_0x53dc63){const _0x583e90=a197_0xe04579;if(_0x4b73a3===undefined||_0x4b73a3===null)return null;if(!Number[_0x583e90(0x271)](_0x4b73a3)||_0x4b73a3<0x0)throw notificationError(_0x583e90(0x202),_0x583e90(0x21e)+_0x53dc63+'\x20has\x20invalid\x20field\x20\x22'+_0xe9c88+'\x22.');return _0x4b73a3;}function normalizeNullableString(_0x5af2ce){const _0x73d084=a197_0xe04579;return typeof _0x5af2ce===_0x73d084(0x213)?_0x5af2ce:null;}function isJsonObject(_0xa293f6){const _0x41e396=a197_0xe04579;return _0xa293f6!==null&&typeof _0xa293f6===_0x41e396(0x24a)&&!Array['isArray'](_0xa293f6);}function hasOwn(_0x576434,_0x365ecd){const _0x112161=a197_0xe04579;return Object[_0x112161(0x237)][_0x112161(0x212)][_0x112161(0x23b)](_0x576434,_0x365ecd);}async function readStdin(){const _0xb411bb=a197_0xe04579;let _0x208535='';process['stdin'][_0xb411bb(0x215)](_0xb411bb(0x206));for await(const _0x1d3ad7 of process[_0xb411bb(0x1f2)])_0x208535+=_0x1d3ad7;return _0x208535;}
|
|
1
|
+
const a197_0x51c5e6=a197_0x1529;function a197_0x1529(_0x4e21fd,_0x58287b){_0x4e21fd=_0x4e21fd-0x13a;const _0x3f4868=a197_0x3f48();let _0x152908=_0x3f4868[_0x4e21fd];return _0x152908;}(function(_0x332541,_0x12073e){const _0x1c55bc=a197_0x1529,_0x1da24a=_0x332541();while(!![]){try{const _0x5e2968=-parseInt(_0x1c55bc(0x172))/0x1*(parseInt(_0x1c55bc(0x15c))/0x2)+-parseInt(_0x1c55bc(0x16c))/0x3+-parseInt(_0x1c55bc(0x1a9))/0x4*(parseInt(_0x1c55bc(0x13b))/0x5)+parseInt(_0x1c55bc(0x140))/0x6+parseInt(_0x1c55bc(0x173))/0x7+-parseInt(_0x1c55bc(0x16b))/0x8*(-parseInt(_0x1c55bc(0x17d))/0x9)+-parseInt(_0x1c55bc(0x163))/0xa*(-parseInt(_0x1c55bc(0x148))/0xb);if(_0x5e2968===_0x12073e)break;else _0x1da24a['push'](_0x1da24a['shift']());}catch(_0x274719){_0x1da24a['push'](_0x1da24a['shift']());}}}(a197_0x3f48,0x9d1e4));import{readFile}from'node:fs/promises';import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{getNotificationChannelConfig}from'../../core/api-client.js';import{CliError,CliErrors}from'../../errors.js';export const NOTIFICATION_CHANNEL_TYPES=[a197_0x51c5e6(0x193),a197_0x51c5e6(0x164),a197_0x51c5e6(0x174),'WECOM',a197_0x51c5e6(0x185)];export const DEFAULT_NOTIFICATION_CONNECT_TIMEOUT=0x1388;export const DEFAULT_NOTIFICATION_READ_TIMEOUT=0x2710;const ALLOWED_INPUT_FIELDS=new Set([a197_0x51c5e6(0x1ac),a197_0x51c5e6(0x17f),a197_0x51c5e6(0x16a),a197_0x51c5e6(0x13d),'description',a197_0x51c5e6(0x189),a197_0x51c5e6(0x162)]),FORBIDDEN_IDENTITY_FIELDS=new Set(['id','appCode',a197_0x51c5e6(0x180),a197_0x51c5e6(0x18d)]),EMAIL_RECIPIENT_FIELDS=new Set([a197_0x51c5e6(0x199),'recipients',a197_0x51c5e6(0x144),a197_0x51c5e6(0x14f),a197_0x51c5e6(0x170),a197_0x51c5e6(0x15f),a197_0x51c5e6(0x1b2),'to','cc']);export const NOTIFICATION_INPUT_FLAGS=[{'name':'file','type':a197_0x51c5e6(0x1b0),'required':![],'description':a197_0x51c5e6(0x165)},{'name':a197_0x51c5e6(0x169),'type':'boolean','required':![],'default':![],'description':a197_0x51c5e6(0x188)},{'name':a197_0x51c5e6(0x150),'type':a197_0x51c5e6(0x1b0),'required':![],'description':a197_0x51c5e6(0x1b5)}];export const NOTIFICATION_ID_FLAG={'name':'id','type':a197_0x51c5e6(0x146),'required':!![],'description':'Application-level\x20notification\x20config\x20ID'};export const NOTIFICATION_APP_FLAG=APPCODE_FLAG_OPTIONAL;export function notificationError(_0x58c5c7,_0x76af1e,_0x90d2c2){return new CliError(_0x58c5c7,0x1,_0x76af1e,_0x90d2c2);}export function readNotificationId(_0x8fe525){const _0xcdbe92=a197_0x51c5e6,_0x47e231=_0x8fe525['num']('id');if(!Number[_0xcdbe92(0x192)](_0x47e231)||_0x47e231<=0x0)throw notificationError(_0xcdbe92(0x1af),_0xcdbe92(0x161));return _0x47e231;}export function requireNotificationExplicitYes(_0xf52d77){const _0xfb038=a197_0x51c5e6;if(_0xf52d77[_0xfb038(0x175)](_0xfb038(0x141))||_0xf52d77['bool']('yes'))return;throw notificationError(_0xfb038(0x160),_0xfb038(0x1b1),'Run\x20the\x20command\x20with\x20--dry-run\x20first,\x20then\x20add\x20--yes\x20after\x20reviewing\x20the\x20plan.');}export function readNotificationChannelType(_0x62e34f,_0x44819c=a197_0x51c5e6(0x18c),_0x27fdd0='EMAIL'){const _0x436a30=a197_0x51c5e6,_0x30fd27=_0x62e34f[_0x436a30(0x13f)](_0x44819c)[_0x436a30(0x16d)]()||_0x27fdd0;if(!NOTIFICATION_CHANNEL_TYPES[_0x436a30(0x159)](_0x30fd27))throw CliErrors['validation']('Invalid\x20--'+_0x44819c+':\x20'+_0x30fd27,_0x436a30(0x179)+NOTIFICATION_CHANNEL_TYPES['join'](',\x20')+'.');return _0x30fd27;}export function assertSingleNotificationSource(_0x1c235b){const _0x61d596=a197_0x51c5e6,_0x2f889f=[],_0x2f3d92=_0x1c235b['str']('file')['trim']();if(_0x2f3d92)_0x2f889f[_0x61d596(0x149)]({'kind':_0x61d596(0x18f),'path':_0x2f3d92});if(_0x1c235b[_0x61d596(0x175)](_0x61d596(0x169)))_0x2f889f[_0x61d596(0x149)]({'kind':_0x61d596(0x169)});const _0x2239d4=_0x1c235b[_0x61d596(0x13f)](_0x61d596(0x150))[_0x61d596(0x16d)]();if(_0x2239d4)_0x2f889f[_0x61d596(0x149)]({'kind':_0x61d596(0x198),'name':_0x2239d4});if(_0x2f889f[_0x61d596(0x157)]===0x0)throw CliErrors['validation']('Missing\x20notification\x20JSON\x20source.',_0x61d596(0x1a7));if(_0x2f889f[_0x61d596(0x157)]>0x1)throw CliErrors['validation'](_0x61d596(0x166),_0x61d596(0x1a7));return _0x2f889f[0x0];}export async function readNotificationDocument(_0x10ad61,_0x247707){const _0x484687=a197_0x51c5e6,_0x2f22ed=assertSingleNotificationSource(_0x10ad61),_0x256d4c=_0x2f22ed[_0x484687(0x186)]==='file'?_0x484687(0x171)+_0x2f22ed[_0x484687(0x147)]:_0x2f22ed['kind']===_0x484687(0x198)?_0x484687(0x17c)+_0x2f22ed[_0x484687(0x152)]:_0x484687(0x169);let _0x315757;try{if(_0x2f22ed['kind']==='file')_0x315757=await readFile(_0x2f22ed[_0x484687(0x147)],_0x484687(0x1a1));else{if(_0x2f22ed[_0x484687(0x186)]===_0x484687(0x198)){if(!(_0x2f22ed[_0x484687(0x152)]in process.env))throw notificationError(_0x484687(0x187),_0x484687(0x1a2)+_0x2f22ed['name']);_0x315757=process.env[_0x2f22ed.name]??'';}else _0x315757=await readStdin();}}catch(_0x733bd){if(_0x733bd instanceof CliError)throw _0x733bd;throw notificationError('notification_config_source_unavailable',_0x484687(0x167)+_0x256d4c+'.');}let _0x52de9f;try{_0x52de9f=JSON[_0x484687(0x176)](_0x315757);}catch{throw notificationError('notification_config_json_invalid',_0x484687(0x15a)+_0x256d4c+_0x484687(0x19b),_0x484687(0x17e));}if(!isJsonObject(_0x52de9f))throw notificationError(_0x484687(0x1a3),'Notification\x20JSON\x20from\x20'+_0x256d4c+'\x20must\x20be\x20an\x20object.');return validateNotificationDocument(_0x52de9f,_0x247707);}export function projectNotificationListConfig(_0x221df8,_0x5e578b){const _0xd2948=a197_0x51c5e6;return{'id':typeof _0x221df8['id']===_0xd2948(0x146)?_0x221df8['id']:null,'configCode':requireResponseString(_0x221df8[_0xd2948(0x180)],_0xd2948(0x180),_0x5e578b),'configName':requireResponseString(_0x221df8[_0xd2948(0x1ac)],_0xd2948(0x1ac),_0x5e578b),'channelType':requireResponseString(_0x221df8[_0xd2948(0x17f)],_0xd2948(0x17f),_0x5e578b),'description':normalizeNullableString(_0x221df8[_0xd2948(0x19a)]),'createTime':normalizeNullableString(_0x221df8[_0xd2948(0x177)]),'updateTime':normalizeNullableString(_0x221df8[_0xd2948(0x142)])};}export function normalizeExactNotificationConfig(_0x26fee3,_0x597c15,_0x251c04){const _0x59c617=a197_0x51c5e6;if(!Number[_0x59c617(0x192)](_0x26fee3['id'])||_0x26fee3['id']!==_0x597c15)throw notificationError('notification_config_response_invalid',_0x59c617(0x13e)+_0x597c15+'.');if(_0x26fee3['appCode']!==_0x251c04)throw notificationError(_0x59c617(0x16f),_0x59c617(0x1ab)+_0x597c15+_0x59c617(0x1ad));const _0x1c8a3b=requireExactString(_0x26fee3[_0x59c617(0x1ac)],_0x59c617(0x1ac),_0x597c15),_0x4a6484=requireExactString(_0x26fee3[_0x59c617(0x180)],_0x59c617(0x180),_0x597c15),_0x14e422=requireExactString(_0x26fee3[_0x59c617(0x17f)],'channelType',_0x597c15);if(!NOTIFICATION_CHANNEL_TYPES[_0x59c617(0x159)](_0x14e422))throw notificationError(_0x59c617(0x16f),_0x59c617(0x1ab)+_0x597c15+'\x20has\x20an\x20unsupported\x20channelType.');const _0x56d655=responseNullableString(_0x26fee3[_0x59c617(0x16a)],_0x59c617(0x16a),_0x597c15),_0x59774e=responseNullableString(_0x26fee3[_0x59c617(0x13d)],'channelConfig',_0x597c15),_0x206c28=responseNullableString(_0x26fee3[_0x59c617(0x19a)],_0x59c617(0x19a),_0x597c15),_0x3c3296=responseNullableTimeout(_0x26fee3[_0x59c617(0x189)],_0x59c617(0x189),_0x597c15),_0x4c24d9=responseNullableTimeout(_0x26fee3[_0x59c617(0x162)],_0x59c617(0x162),_0x597c15);return{'id':_0x597c15,'appCode':_0x251c04,'configCode':_0x4a6484,'configName':_0x1c8a3b,'channelType':_0x14e422,'endpointUrl':redactSensitive(_0x56d655),'channelConfig':redactSensitive(_0x59774e),'description':_0x206c28,'connectTimeout':_0x3c3296,'readTimeout':_0x4c24d9,'endpointUrlRaw':_0x56d655,'channelConfigRaw':_0x59774e};}export async function requireExactNotificationConfig(_0x1f9206,_0x4478c4,_0x28caa2){const _0x3f6161=a197_0x51c5e6;let _0x540574;try{_0x540574=await getNotificationChannelConfig(_0x4478c4,_0x1f9206);}catch{throw safeApiFailure(_0x28caa2,_0x3f6161(0x183),_0x3f6161(0x191)+_0x1f9206+_0x3f6161(0x14e));}return normalizeExactNotificationConfig(_0x540574,_0x4478c4,_0x1f9206);}export function projectNotificationConfig(_0x54b332){const _0x2fbada=a197_0x51c5e6;return{'id':_0x54b332['id']??null,'appCode':_0x54b332[_0x2fbada(0x184)],'configCode':_0x54b332['configCode']??null,'configName':_0x54b332[_0x2fbada(0x1ac)],'channelType':_0x54b332[_0x2fbada(0x17f)],'endpointUrl':redactSensitive(_0x54b332['endpointUrl']),'channelConfig':redactSensitive(_0x54b332[_0x2fbada(0x13d)]),'description':_0x54b332[_0x2fbada(0x19a)]??null,'connectTimeout':_0x54b332['connectTimeout']??null,'readTimeout':_0x54b332['readTimeout']??null};}export function notificationSelector(_0x4b689a){const _0x126a9e=a197_0x51c5e6;return{'appCode':_0x4b689a[_0x126a9e(0x184)],'id':_0x4b689a['id'],'configCode':_0x4b689a[_0x126a9e(0x180)],'configName':_0x4b689a[_0x126a9e(0x1ac)],'channelType':_0x4b689a[_0x126a9e(0x17f)]};}export function createMutationInput(_0xe59177,_0x1be2d1){const _0x3eaf02=a197_0x51c5e6;return{'appCode':_0xe59177,'configName':_0x1be2d1[_0x3eaf02(0x1ac)],'channelType':_0x1be2d1['channelType'],...hasOwn(_0x1be2d1,_0x3eaf02(0x16a))?{'endpointUrl':_0x1be2d1[_0x3eaf02(0x16a)]}:{},...hasOwn(_0x1be2d1,_0x3eaf02(0x13d))?{'channelConfig':serializeChannelConfig(_0x1be2d1['channelConfig'])}:{},...hasOwn(_0x1be2d1,_0x3eaf02(0x19a))?{'description':_0x1be2d1[_0x3eaf02(0x19a)]}:{},...hasOwn(_0x1be2d1,_0x3eaf02(0x189))?{'connectTimeout':_0x1be2d1[_0x3eaf02(0x189)]}:{},...hasOwn(_0x1be2d1,_0x3eaf02(0x162))?{'readTimeout':_0x1be2d1[_0x3eaf02(0x162)]}:{}};}export function mergeUpdateInput(_0x385d00,_0x51deec){const _0x26595e=a197_0x51c5e6;return{'id':_0x385d00['id'],'appCode':_0x385d00['appCode'],'configName':_0x51deec[_0x26595e(0x1ac)]??_0x385d00[_0x26595e(0x1ac)],'channelType':_0x51deec[_0x26595e(0x17f)]??_0x385d00[_0x26595e(0x17f)],'endpointUrl':hasOwn(_0x51deec,_0x26595e(0x16a))?_0x51deec[_0x26595e(0x16a)]:_0x385d00[_0x26595e(0x13a)],'channelConfig':hasOwn(_0x51deec,_0x26595e(0x13d))?serializeChannelConfig(_0x51deec[_0x26595e(0x13d)]):_0x385d00['channelConfigRaw'],'description':hasOwn(_0x51deec,'description')?_0x51deec[_0x26595e(0x19a)]:_0x385d00[_0x26595e(0x19a)],'connectTimeout':hasOwn(_0x51deec,_0x26595e(0x189))?_0x51deec['connectTimeout']:_0x385d00[_0x26595e(0x189)],'readTimeout':hasOwn(_0x51deec,'readTimeout')?_0x51deec[_0x26595e(0x162)]:_0x385d00[_0x26595e(0x162)]};}export function plannedUpdateProjection(_0x249f5a,_0x297f56){const _0x4ae95b=a197_0x51c5e6;return projectNotificationConfig({'id':_0x249f5a['id'],'appCode':_0x249f5a[_0x4ae95b(0x184)],'configCode':_0x249f5a[_0x4ae95b(0x180)],'configName':_0x297f56['configName']??_0x249f5a[_0x4ae95b(0x1ac)],'channelType':_0x297f56[_0x4ae95b(0x17f)]??_0x249f5a[_0x4ae95b(0x17f)],'endpointUrl':hasOwn(_0x297f56,_0x4ae95b(0x16a))?_0x297f56[_0x4ae95b(0x16a)]:_0x249f5a[_0x4ae95b(0x13a)],'channelConfig':hasOwn(_0x297f56,_0x4ae95b(0x13d))?_0x297f56[_0x4ae95b(0x13d)]:_0x249f5a[_0x4ae95b(0x16e)],'description':hasOwn(_0x297f56,_0x4ae95b(0x19a))?_0x297f56['description']:_0x249f5a[_0x4ae95b(0x19a)],'connectTimeout':hasOwn(_0x297f56,_0x4ae95b(0x189))?_0x297f56[_0x4ae95b(0x189)]??DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:_0x249f5a[_0x4ae95b(0x189)],'readTimeout':hasOwn(_0x297f56,_0x4ae95b(0x162))?_0x297f56[_0x4ae95b(0x162)]??DEFAULT_NOTIFICATION_READ_TIMEOUT:_0x249f5a[_0x4ae95b(0x162)]});}export function requestedSafeFieldsMatch(_0x5de184,_0x4bb812,_0x41c5c0){const _0x51bcaf=a197_0x51c5e6,_0x5d9c9f=[],_0x3a4aaa=[],_0x1c0d45=[];for(const _0x1f573b of[_0x51bcaf(0x1ac),'channelType',_0x51bcaf(0x19a)]){if(!hasOwn(_0x41c5c0,_0x1f573b))continue;_0x1c0d45['push'](_0x1f573b),_0x5d9c9f[_0x51bcaf(0x149)](_0x4bb812[_0x1f573b]===_0x41c5c0[_0x1f573b]),_0x3a4aaa['push'](_0x5de184[_0x1f573b]!==_0x41c5c0[_0x1f573b]&&_0x4bb812[_0x1f573b]===_0x41c5c0[_0x1f573b]);}for(const _0x52dd23 of[_0x51bcaf(0x189),_0x51bcaf(0x162)]){if(!hasOwn(_0x41c5c0,_0x52dd23))continue;const _0x5d5df7=_0x41c5c0[_0x52dd23]??(_0x52dd23===_0x51bcaf(0x189)?DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:DEFAULT_NOTIFICATION_READ_TIMEOUT);_0x1c0d45[_0x51bcaf(0x149)](_0x52dd23),_0x5d9c9f['push'](_0x4bb812[_0x52dd23]===_0x5d5df7),_0x3a4aaa[_0x51bcaf(0x149)](_0x5de184[_0x52dd23]!==_0x5d5df7&&_0x4bb812[_0x52dd23]===_0x5d5df7);}return hasOwn(_0x41c5c0,_0x51bcaf(0x16a))&&_0x41c5c0[_0x51bcaf(0x16a)]===null&&(_0x1c0d45['push'](_0x51bcaf(0x190)),_0x5d9c9f['push'](_0x4bb812[_0x51bcaf(0x13a)]===null||_0x4bb812['endpointUrlRaw']===''),_0x3a4aaa[_0x51bcaf(0x149)](_0x5de184[_0x51bcaf(0x13a)]!==null&&_0x5de184['endpointUrlRaw']!==''&&(_0x4bb812['endpointUrlRaw']===null||_0x4bb812[_0x51bcaf(0x13a)]===''))),{'allMatch':_0x5d9c9f[_0x51bcaf(0x14a)](Boolean),'provesChange':_0x3a4aaa['some'](Boolean),'verifiedFields':_0x1c0d45};}export function validateNotificationDeleteReadback(_0x3ce576,_0x5945e9,_0x5275bf){const _0xef321d=a197_0x51c5e6;for(const [_0x444cae,_0x17ae58]of _0x3ce576[_0xef321d(0x19d)]()){if(!Number[_0xef321d(0x192)](_0x17ae58['id'])||_0x17ae58['id']<=0x0)throw notificationError(_0xef321d(0x16f),_0xef321d(0x15b)+(_0x444cae+0x1)+'\x20has\x20an\x20invalid\x20id.');if(_0x17ae58['appCode']!==_0x5945e9)throw notificationError(_0xef321d(0x16f),_0xef321d(0x15b)+(_0x444cae+0x1)+'\x20has\x20an\x20invalid\x20appCode.');if(_0x17ae58['channelType']!==_0x5275bf)throw notificationError(_0xef321d(0x16f),_0xef321d(0x15b)+(_0x444cae+0x1)+'\x20has\x20an\x20invalid\x20channelType.');}}export function safeApiFailure(_0x57dc4a,_0x5855ca,_0xf5dc64){const _0x207cc5=a197_0x51c5e6;return notificationError(_0x207cc5(0x178)+_0x57dc4a+'_'+(_0x5855ca==='mutation'?_0x207cc5(0x1aa):_0x5855ca+_0x207cc5(0x19e)),_0x207cc5(0x1ab)+_0x57dc4a+'\x20'+_0x5855ca+'\x20failed.',_0xf5dc64);}export function notificationLookupCommand(_0x28dd42,_0x2858e9){const _0x160e3a=a197_0x51c5e6;return'rabetbase\x20notification\x20config-list\x20--appcode\x20'+_0x28dd42+_0x160e3a(0x15e)+_0x2858e9+'\x20--format\x20compress';}function validateNotificationDocument(_0x3e73cb,_0x5e28a8){const _0x59b470=a197_0x51c5e6;for(const _0x587759 of Object[_0x59b470(0x18b)](_0x3e73cb)){if(FORBIDDEN_IDENTITY_FIELDS['has'](_0x587759))throw notificationError(_0x59b470(0x14b),_0x59b470(0x14c)+_0x587759+'\x22\x20is\x20controlled\x20by\x20the\x20CLI\x20or\x20server\x20and\x20is\x20forbidden.');if(!ALLOWED_INPUT_FIELDS[_0x59b470(0x155)](_0x587759))throw notificationError('notification_config_field_unknown',_0x59b470(0x13c)+_0x587759+'\x22.');}if(_0x5e28a8===_0x59b470(0x156)&&Object[_0x59b470(0x18b)](_0x3e73cb)[_0x59b470(0x157)]===0x0)throw notificationError(_0x59b470(0x1a5),_0x59b470(0x153));const _0x3e72c9={};if(hasOwn(_0x3e73cb,_0x59b470(0x1ac)))_0x3e72c9[_0x59b470(0x1ac)]=validateRequiredString(_0x3e73cb['configName'],_0x59b470(0x1ac),0x80);else{if(_0x5e28a8===_0x59b470(0x1b4))throw notificationError(_0x59b470(0x1a6),_0x59b470(0x197)+'\x22configName\x22.');}if(hasOwn(_0x3e73cb,_0x59b470(0x17f))){if(typeof _0x3e73cb['channelType']!=='string')throw invalidFieldType(_0x59b470(0x17f),_0x59b470(0x196));const _0x6358bf=_0x3e73cb[_0x59b470(0x17f)][_0x59b470(0x16d)]();if(!NOTIFICATION_CHANNEL_TYPES[_0x59b470(0x159)](_0x6358bf))throw notificationError('notification_config_field_invalid',_0x59b470(0x181),_0x59b470(0x179)+NOTIFICATION_CHANNEL_TYPES[_0x59b470(0x195)](',\x20')+'.');_0x3e72c9[_0x59b470(0x17f)]=_0x6358bf;}else{if(_0x5e28a8===_0x59b470(0x1b4))throw notificationError('notification_config_field_required',_0x59b470(0x197)+_0x59b470(0x182));}for(const [_0x35a93e,_0x2f7386]of[['endpointUrl',0x200],[_0x59b470(0x19a),0x100]]){if(!hasOwn(_0x3e73cb,_0x35a93e))continue;const _0x22cba7=_0x3e73cb[_0x35a93e];if(_0x22cba7!==null&&typeof _0x22cba7!==_0x59b470(0x1b0))throw invalidFieldType(_0x35a93e,'a\x20string\x20or\x20null');if(typeof _0x22cba7===_0x59b470(0x1b0)&&_0x22cba7['length']>_0x2f7386)throw notificationError('notification_config_field_invalid','Notification\x20JSON\x20field\x20\x22'+_0x35a93e+_0x59b470(0x19f)+_0x2f7386+'\x20characters.');_0x3e72c9[_0x35a93e]=_0x22cba7;}if(hasOwn(_0x3e73cb,'channelConfig')){const _0x53a4b6=_0x3e73cb['channelConfig'];if(_0x53a4b6===null&&_0x5e28a8===_0x59b470(0x1b4))throw invalidFieldType(_0x59b470(0x13d),_0x59b470(0x17b));if(_0x53a4b6!==null&&!isJsonObject(_0x53a4b6))throw invalidFieldType(_0x59b470(0x13d),_0x5e28a8===_0x59b470(0x156)?_0x59b470(0x18e):_0x59b470(0x17b));_0x53a4b6!==null&&validateChannelConfigFields(_0x3e72c9[_0x59b470(0x17f)],_0x53a4b6),_0x3e72c9[_0x59b470(0x13d)]=_0x53a4b6;}for(const _0x3c8df4 of['connectTimeout',_0x59b470(0x162)]){if(!hasOwn(_0x3e73cb,_0x3c8df4))continue;const _0x575995=_0x3e73cb[_0x3c8df4];if(_0x575995!==null&&(!Number[_0x59b470(0x192)](_0x575995)||_0x575995<0x0))throw notificationError('notification_config_field_invalid',_0x59b470(0x14c)+_0x3c8df4+_0x59b470(0x194));_0x3e72c9[_0x3c8df4]=_0x575995;}return _0x3e72c9;}function validateRequiredString(_0x344ddf,_0xfe505d,_0x1c8bc2){const _0x516a78=a197_0x51c5e6;if(typeof _0x344ddf!==_0x516a78(0x1b0))throw invalidFieldType(_0xfe505d,'a\x20non-empty\x20string');const _0x35200b=_0x344ddf[_0x516a78(0x16d)]();if(!_0x35200b)throw notificationError(_0x516a78(0x145),_0x516a78(0x14c)+_0xfe505d+_0x516a78(0x17a));if(_0x35200b[_0x516a78(0x157)]>_0x1c8bc2)throw notificationError(_0x516a78(0x145),_0x516a78(0x14c)+_0xfe505d+_0x516a78(0x19f)+_0x1c8bc2+_0x516a78(0x19c));return _0x35200b;}function a197_0x3f48(){const _0x5bfa04=['utf8','Notification\x20JSON\x20environment\x20variable\x20is\x20not\x20set:\x20','notification_config_json_invalid','stringify','notification_config_update_empty','notification_config_field_required','Use\x20exactly\x20one\x20of\x20--file\x20<path>,\x20--stdin,\x20or\x20--from-env\x20<NAME>.','messageTemplate','296yhcvUk','failed','Notification\x20config\x20','configName','\x20does\x20not\x20belong\x20to\x20the\x20resolved\x20app.','apiError','notification_config_id_invalid','string','This\x20notification\x20config\x20mutation\x20requires\x20explicit\x20--yes.','fromName','\x22\x20must\x20be\x20','create','Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20named\x20environment\x20variable','endpointUrlRaw','24425CkSnJW','Unknown\x20notification\x20JSON\x20field\x20\x22','channelConfig','Notification\x20config\x20detail\x20did\x20not\x20contain\x20the\x20requested\x20ID\x20','str','5219562MqOGAu','dry-run','updateTime','\x20has\x20invalid\x20field\x20\x22','ccList','notification_config_field_invalid','number','path','11ssVwHs','push','every','notification_config_field_forbidden','Notification\x20JSON\x20field\x20\x22','setEncoding','\x20--type\x20<CHANNEL_TYPE>\x20--format\x20compress;\x20no\x20mutation\x20was\x20submitted.','bccList','from-env','call','name','Update\x20JSON\x20must\x20contain\x20at\x20least\x20one\x20allowed\x20field.','<redacted>','has','update','length','prototype','includes','Notification\x20JSON\x20from\x20','Notification\x20config\x20list\x20item\x20','3878PvcTZo','object','\x20--type\x20','subjectPrefix','notification_config_confirmation_required','--id\x20must\x20be\x20a\x20positive\x20safe\x20integer.','readTimeout','8230780wCGQul','FEISHU','Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20UTF-8\x20file','Notification\x20JSON\x20source\x20is\x20ambiguous.','Unable\x20to\x20read\x20notification\x20JSON\x20from\x20','\x20is\x20missing\x20required\x20field\x20\x22','stdin','endpointUrl','17104FYAsBh','2584497vEEhoX','trim','channelConfigRaw','notification_config_response_invalid','replyTo','file\x20','1IvtfYO','375291ymCfoy','DINGTALK','bool','parse','createTime','notification_config_','Allowed\x20values:\x20','\x22\x20must\x20be\x20a\x20non-empty\x20string.','a\x20JSON\x20object','environment\x20variable\x20','513vpgLeh','Provide\x20one\x20valid\x20JSON\x20object;\x20source\x20contents\x20are\x20not\x20included\x20in\x20errors.','channelType','configCode','Notification\x20JSON\x20field\x20\x22channelType\x22\x20is\x20unsupported.','\x22channelType\x22.','preflight','appCode','WEBHOOK','kind','notification_config_source_unavailable','Read\x20the\x20notification\x20JSON\x20document\x20from\x20stdin','connectTimeout','\x22\x20is\x20forbidden.','keys','type','channelCode','a\x20JSON\x20object\x20or\x20null','file','endpointUrl:null','Inspect\x20with\x20rabetbase\x20notification\x20config-list\x20--appcode\x20','isSafeInteger','EMAIL','\x22\x20must\x20be\x20a\x20non-negative\x20safe\x20integer\x20or\x20null.','join','a\x20supported\x20string','Create\x20JSON\x20requires\x20field\x20','env','emailTargets','description','\x20is\x20invalid.','\x20characters.','entries','_unavailable','\x22\x20cannot\x20exceed\x20','notification_config_channel_field_forbidden'];a197_0x3f48=function(){return _0x5bfa04;};return a197_0x3f48();}function validateChannelConfigFields(_0x1c1bcf,_0x492a7c){const _0x236da0=a197_0x51c5e6;if(hasOwn(_0x492a7c,_0x236da0(0x1a8)))throw forbiddenChannelConfigField('messageTemplate');if(_0x1c1bcf===_0x236da0(0x193))for(const _0x3f155d of EMAIL_RECIPIENT_FIELDS){if(hasOwn(_0x492a7c,_0x3f155d))throw forbiddenChannelConfigField(_0x3f155d);}}function forbiddenChannelConfigField(_0x510932){const _0x48aede=a197_0x51c5e6;return notificationError(_0x48aede(0x1a0),'Notification\x20JSON\x20channelConfig\x20field\x20\x22'+_0x510932+_0x48aede(0x18a));}function invalidFieldType(_0x58cc3d,_0x53d824){const _0x217029=a197_0x51c5e6;return notificationError('notification_config_field_invalid',_0x217029(0x14c)+_0x58cc3d+_0x217029(0x1b3)+_0x53d824+'.');}function serializeChannelConfig(_0x160061){const _0x3410de=a197_0x51c5e6;return _0x160061===null||_0x160061===undefined?null:JSON[_0x3410de(0x1a4)](_0x160061);}function redactSensitive(_0x112a9a){const _0x4d7d34=a197_0x51c5e6;return _0x112a9a===null||_0x112a9a===undefined||_0x112a9a===''?null:_0x4d7d34(0x154);}function requireResponseString(_0x2d3692,_0x72604d,_0x5809ee){const _0x44f2fb=a197_0x51c5e6;if(typeof _0x2d3692!==_0x44f2fb(0x1b0)||_0x2d3692[_0x44f2fb(0x16d)]()==='')throw CliErrors[_0x44f2fb(0x1ae)]('Invalid\x20notification\x20config\x20response.','Item\x20'+(_0x5809ee+0x1)+_0x44f2fb(0x168)+_0x72604d+'\x22.');return _0x2d3692[_0x44f2fb(0x16d)]();}function requireExactString(_0x37c336,_0x43c090,_0x3d21e3){const _0x31924c=a197_0x51c5e6;if(typeof _0x37c336!==_0x31924c(0x1b0)||_0x37c336[_0x31924c(0x16d)]()==='')throw notificationError(_0x31924c(0x16f),_0x31924c(0x1ab)+_0x3d21e3+_0x31924c(0x168)+_0x43c090+'\x22.');return _0x37c336['trim']();}function responseNullableString(_0x2f7ac1,_0x191b43,_0x587885){const _0x1255a5=a197_0x51c5e6;if(_0x2f7ac1===undefined||_0x2f7ac1===null)return null;if(typeof _0x2f7ac1!==_0x1255a5(0x1b0))throw notificationError('notification_config_response_invalid',_0x1255a5(0x1ab)+_0x587885+'\x20has\x20invalid\x20field\x20\x22'+_0x191b43+'\x22.');return _0x2f7ac1;}function responseNullableTimeout(_0xc820d1,_0x1a7c21,_0x586c72){const _0x179522=a197_0x51c5e6;if(_0xc820d1===undefined||_0xc820d1===null)return null;if(!Number[_0x179522(0x192)](_0xc820d1)||_0xc820d1<0x0)throw notificationError(_0x179522(0x16f),_0x179522(0x1ab)+_0x586c72+_0x179522(0x143)+_0x1a7c21+'\x22.');return _0xc820d1;}function normalizeNullableString(_0x5c3807){return typeof _0x5c3807==='string'?_0x5c3807:null;}function isJsonObject(_0xad4bc5){const _0x596d60=a197_0x51c5e6;return _0xad4bc5!==null&&typeof _0xad4bc5===_0x596d60(0x15d)&&!Array['isArray'](_0xad4bc5);}function hasOwn(_0x26518e,_0x3afee5){const _0x28e76e=a197_0x51c5e6;return Object[_0x28e76e(0x158)]['hasOwnProperty'][_0x28e76e(0x151)](_0x26518e,_0x3afee5);}async function readStdin(){const _0x2f0dd1=a197_0x51c5e6;let _0x3b7afb='';process['stdin'][_0x2f0dd1(0x14d)](_0x2f0dd1(0x1a1));for await(const _0x12875f of process[_0x2f0dd1(0x169)])_0x3b7afb+=_0x12875f;return _0x3b7afb;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a198_0x354c86=a198_0x4c56;(function(_0x5e76d4,_0x5e77e7){const _0xa6506f=a198_0x4c56,_0x61195f=_0x5e76d4();while(!![]){try{const _0x50221f=parseInt(_0xa6506f(0x10b))/0x1+parseInt(_0xa6506f(0x112))/0x2+parseInt(_0xa6506f(0x108))/0x3*(-parseInt(_0xa6506f(0xec))/0x4)+-parseInt(_0xa6506f(0x11a))/0x5+parseInt(_0xa6506f(0xfa))/0x6+-parseInt(_0xa6506f(0xf4))/0x7*(-parseInt(_0xa6506f(0xee))/0x8)+parseInt(_0xa6506f(0x102))/0x9*(parseInt(_0xa6506f(0x11c))/0xa);if(_0x50221f===_0x5e77e7)break;else _0x61195f['push'](_0x61195f['shift']());}catch(_0x3a938c){_0x61195f['push'](_0x61195f['shift']());}}}(a198_0x39e0,0xc965c));import{requireDevelopmentUploadFile}from'../../commands/common/local-file.js';import{queryDevelopmentFileUrl,recognizeDevelopmentOcr,uploadDevelopmentFile}from'../../core/api-client.js';function a198_0x39e0(){const _0x27b68c=['Invoice','image-url','filter','Publicly\x20accessible\x20image\x20or\x20file\x20URL','824682VRWuIy','Unsupported\x20OCR\x20scene:\x20','scene','appCode','Local\x20image\x20or\x20PDF\x20file;\x20uses\x20upload\x20->\x20query-url\x20->\x20OCR','File\x20upload\x20response\x20missing\x20filePath.','fileUrl','image-file','7982400ZcmXkx','filePath','999730MHGfjD','recognize','/smartapi/ocr/recognize-text','<fileUrl\x20returned\x20by\x20/smartapi/common/queryFileUrl>','toLowerCase','1864glLKDf','<filePath\x20returned\x20by\x20/smartapi/common/uploadFile>','24ZLgbTS','General','Table','IdCard','idcard','/smartapi/common/queryFileUrl','885717JOrBKP','OCR\x20scene:\x20invoice,\x20general,\x20form,\x20or\x20idCard','str','apiError','ocr','File\x20URL\x20response\x20missing\x20fileUrl.','3622896CtAJez','/smartapi/ocr/recognize-text?','GET','general','string','join','imageUrl','toString','45eKgytr','form','Extract\x20text\x20and\x20structured\x20fields\x20from\x20voucher-style\x20business\x20documents;\x20not\x20for\x20general\x20image\x20understanding','read','trim','invoice','2559VJzLQR','POST','fileName','923287SEDYbE','validation','Preview:\x20recognize\x20'];a198_0x39e0=function(){return _0x27b68c;};return a198_0x39e0();}import{CliErrors}from'../../errors.js';function a198_0x4c56(_0x443cd1,_0x2eb73c){_0x443cd1=_0x443cd1-0xe9;const _0x39e05f=a198_0x39e0();let _0x4c567c=_0x39e05f[_0x443cd1];return _0x4c567c;}const SUPPORTED_SCENES=['invoice',a198_0x354c86(0xfd),'form','idCard'],SCENE_TO_LEGACY_TYPE={'invoice':a198_0x354c86(0x10e),'general':a198_0x354c86(0xef),'form':a198_0x354c86(0xf0),'idCard':a198_0x354c86(0xf1)},SCENE_FLAG={'name':a198_0x354c86(0x114),'type':a198_0x354c86(0xfe),'required':!![],'enum':[...SUPPORTED_SCENES],'description':a198_0x354c86(0xf5)},IMAGE_FILE_FLAG={'name':a198_0x354c86(0x119),'type':a198_0x354c86(0xfe),'description':a198_0x354c86(0x116)},IMAGE_URL_FLAG={'name':a198_0x354c86(0x10f),'type':a198_0x354c86(0xfe),'description':a198_0x354c86(0x111)};function normalizeScene(_0x450e3f){const _0x4f5c58=a198_0x354c86,_0x375d70=_0x450e3f['trim']()[_0x4f5c58(0xeb)]();if(_0x375d70===_0x4f5c58(0xf2))return'idCard';if(_0x375d70===_0x4f5c58(0x107)||_0x375d70===_0x4f5c58(0xfd)||_0x375d70===_0x4f5c58(0x103))return _0x375d70;throw CliErrors[_0x4f5c58(0x10c)](_0x4f5c58(0x113)+_0x450e3f+'.\x20Supported\x20scenes:\x20'+SUPPORTED_SCENES[_0x4f5c58(0xff)](',\x20'));}function selectedInputs(_0x35591b){const _0x823614=a198_0x354c86,_0x150fec=_0x35591b[_0x823614(0xf6)](_0x823614(0x119))[_0x823614(0x106)](),_0xdfaf9=_0x35591b[_0x823614(0xf6)](_0x823614(0x10f))['trim']();return{'imageFile':_0x150fec,'imageUrl':_0xdfaf9,'count':[_0x150fec,_0xdfaf9][_0x823614(0x110)](Boolean)['length']};}function validateInputSelection(_0x3a26a3){const _0x31dfa3=a198_0x354c86,_0x3f48f3=selectedInputs(_0x3a26a3);if(_0x3f48f3['count']!==0x1)throw CliErrors[_0x31dfa3(0x10c)]('Choose\x20exactly\x20one\x20OCR\x20input:\x20--image-file\x20or\x20--image-url.');return _0x3f48f3;}function withScene(_0xc672d2,_0x2e2ba0,_0xed6bda){const _0xdc1b99=a198_0x354c86;return{..._0xc672d2,'scene':_0x2e2ba0,..._0xed6bda?{'sourceFile':{'fileName':_0xed6bda[_0xdc1b99(0x10a)],'filePath':_0xed6bda[_0xdc1b99(0x11b)]}}:{}};}const ocrRecognize={'service':a198_0x354c86(0xf8),'command':a198_0x354c86(0x11d),'description':a198_0x354c86(0x104),'risk':a198_0x354c86(0x105),'flags':[SCENE_FLAG,IMAGE_FILE_FLAG,IMAGE_URL_FLAG],async 'dryRun'(_0x216a89){const _0x35e410=a198_0x354c86,_0x959b37=normalizeScene(_0x216a89[_0x35e410(0xf6)](_0x35e410(0x114))),_0x2df831=SCENE_TO_LEGACY_TYPE[_0x959b37],_0x864804=validateInputSelection(_0x216a89);if(_0x864804[_0x35e410(0x100)]){const _0xbe9e93=new URLSearchParams({'url':_0x864804[_0x35e410(0x100)],'type':_0x2df831,'appCode':_0x216a89[_0x35e410(0x115)]});return{'method':_0x35e410(0xfc),'url':_0x35e410(0xfb)+_0xbe9e93[_0x35e410(0x101)](),'description':_0x35e410(0x10d)+_0x959b37+'\x20OCR\x20from\x20URL'};}const _0x485584=requireDevelopmentUploadFile(_0x864804['imageFile'],'image-file');return{'method':_0x35e410(0x109),'url':'/smartapi/common/uploadFile','body':{'steps':[{'method':_0x35e410(0x109),'url':'/smartapi/common/uploadFile','body':{'appCode':_0x216a89[_0x35e410(0x115)],'multipart':{'file':_0x485584}}},{'method':_0x35e410(0x109),'url':_0x35e410(0xf3),'body':{'filePath':_0x35e410(0xed),'downloadFlag':![]}},{'method':_0x35e410(0xfc),'url':_0x35e410(0xe9),'query':{'appCode':_0x216a89[_0x35e410(0x115)],'url':_0x35e410(0xea),'type':_0x2df831}}]},'description':'Preview:\x20upload\x20local\x20file,\x20query\x20temporary\x20URL,\x20then\x20recognize\x20'+_0x959b37+'\x20OCR'};},async 'execute'(_0x87eb7b){const _0x129135=a198_0x354c86,_0x59a63c=normalizeScene(_0x87eb7b['str']('scene')),_0x49ccc2=SCENE_TO_LEGACY_TYPE[_0x59a63c],_0x5a915c=validateInputSelection(_0x87eb7b);if(_0x5a915c[_0x129135(0x100)]){const _0x2a0af=await recognizeDevelopmentOcr(_0x87eb7b[_0x129135(0x115)],{'url':_0x5a915c['imageUrl'],'type':_0x49ccc2});return{'ok':!![],'data':withScene(_0x2a0af,_0x59a63c)};}const _0x6b6afe=requireDevelopmentUploadFile(_0x5a915c['imageFile'],_0x129135(0x119)),_0x23efbe=await uploadDevelopmentFile(_0x87eb7b[_0x129135(0x115)],_0x6b6afe['path']);if(!_0x23efbe[_0x129135(0x11b)])throw CliErrors['apiError'](_0x129135(0x117));const _0x4742b4=await queryDevelopmentFileUrl(_0x23efbe[_0x129135(0x11b)],{'download':![]});if(!_0x4742b4[_0x129135(0x118)])throw CliErrors[_0x129135(0xf7)](_0x129135(0xf9));const _0x4927eb=await recognizeDevelopmentOcr(_0x87eb7b[_0x129135(0x115)],{'url':_0x4742b4['fileUrl'],'type':_0x49ccc2});return{'ok':!![],'data':withScene(_0x4927eb,_0x59a63c,_0x23efbe)};}};export const ocrDefinitions=[ocrRecognize];
|