@lovrabet/rabetbase-cli 2.5.8-beta.2 → 2.5.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/api/api-doc.js +1 -1
- package/lib/api/api-group.js +1 -1
- package/lib/api/fetch-model-list.js +1 -1
- package/lib/api/generate-api-file.js +1 -1
- package/lib/api/generate-sdk-config-file.js +1 -1
- package/lib/api/legacy-api-file.js +1 -1
- package/lib/api/model-registry-file.js +1 -1
- package/lib/api/model-registry-scaffold.js +1 -1
- package/lib/api/model-source.js +1 -1
- package/lib/auth/auth-server-ui.js +1 -1
- package/lib/auth/auth-server.js +1 -1
- package/lib/auth/constant.js +1 -1
- package/lib/auth/get-cookie.js +1 -1
- package/lib/auth/get-session-user.js +1 -1
- package/lib/auth/is-session-valid.js +1 -1
- package/lib/auth/login-success-html.js +1 -1
- package/lib/auth/logout.js +1 -1
- package/lib/cli-flags.js +1 -1
- package/lib/cli.js +1 -1
- package/lib/commands/api/generate.js +1 -1
- package/lib/commands/api/index.js +1 -1
- package/lib/commands/api/list.js +1 -1
- package/lib/commands/api/pull.js +1 -1
- package/lib/commands/api/shared.js +1 -1
- package/lib/commands/app/detail.js +1 -1
- package/lib/commands/app/index.js +1 -1
- package/lib/commands/app/list.js +1 -1
- package/lib/commands/app/members-list.js +1 -1
- package/lib/commands/app/remote-directory.js +1 -1
- package/lib/commands/app/shared.js +1 -1
- package/lib/commands/app-config/delete.js +1 -1
- package/lib/commands/app-config/get.js +1 -1
- package/lib/commands/app-config/index.js +1 -1
- package/lib/commands/app-config/list.js +1 -1
- package/lib/commands/app-config/set.js +1 -1
- package/lib/commands/app-config/shared.js +1 -1
- package/lib/commands/auth/index.js +1 -1
- package/lib/commands/bff/create.js +1 -1
- package/lib/commands/bff/delete.js +1 -1
- package/lib/commands/bff/detail.js +1 -1
- package/lib/commands/bff/index.js +1 -1
- package/lib/commands/bff/list.js +1 -1
- package/lib/commands/bff/logs.js +1 -1
- package/lib/commands/bff/pull.js +1 -1
- package/lib/commands/bff/push.js +1 -1
- package/lib/commands/bff/status.js +1 -1
- package/lib/commands/cli-skill/index.js +1 -1
- package/lib/commands/cli-update.js +1 -1
- package/lib/commands/codegen/index.js +1 -1
- package/lib/commands/codegen/sdk.js +1 -1
- package/lib/commands/codegen/sql.js +1 -1
- package/lib/commands/common/app-registry.js +1 -1
- package/lib/commands/common/app-selector.js +1 -1
- package/lib/commands/common/async-task.js +1 -1
- package/lib/commands/common/dry-run.js +1 -1
- package/lib/commands/common/flags.js +1 -1
- package/lib/commands/common/local-file.js +1 -1
- package/lib/commands/common/validate.js +1 -1
- package/lib/commands/config/delete.js +1 -1
- package/lib/commands/config/get.js +1 -1
- package/lib/commands/config/index.js +1 -1
- package/lib/commands/config/init.js +1 -1
- package/lib/commands/config/list.js +1 -1
- package/lib/commands/config/set.js +1 -1
- package/lib/commands/config/shared.js +1 -1
- package/lib/commands/dataset/batch-design.js +1 -1
- package/lib/commands/dataset/business-group-update.js +1 -1
- package/lib/commands/dataset/business-groups.js +1 -1
- package/lib/commands/dataset/capability.js +1 -1
- package/lib/commands/dataset/cross-relation-create.js +1 -1
- package/lib/commands/dataset/cross-relation-delete.js +1 -1
- package/lib/commands/dataset/cross-relation-list.js +1 -1
- package/lib/commands/dataset/cross-relation-shared.js +1 -1
- package/lib/commands/dataset/cross-relation-update.js +1 -1
- package/lib/commands/dataset/delete.js +1 -1
- package/lib/commands/dataset/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 +1 -1
- package/skills/rabetbase/SKILL.md +1 -1
- package/skills/rabetbase-dataset-generation/SKILL.md +1 -1
- package/skills/rabetbase-page-generation/SKILL.md +1 -1
- package/skills/rabetbase.manifest.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
const a197_0x5c5ecd=a197_0x4de5;(function(_0x40450a,_0x187042){const _0x4cdcfe=a197_0x4de5,_0x323192=_0x40450a();while(!![]){try{const _0x25bf57=parseInt(_0x4cdcfe(0x1d7))/0x1*(-parseInt(_0x4cdcfe(0x19f))/0x2)+-parseInt(_0x4cdcfe(0x1ce))/0x3*(parseInt(_0x4cdcfe(0x173))/0x4)+-parseInt(_0x4cdcfe(0x1b7))/0x5+-parseInt(_0x4cdcfe(0x175))/0x6+parseInt(_0x4cdcfe(0x188))/0x7*(-parseInt(_0x4cdcfe(0x1ca))/0x8)+-parseInt(_0x4cdcfe(0x1d6))/0x9*(-parseInt(_0x4cdcfe(0x1a1))/0xa)+parseInt(_0x4cdcfe(0x189))/0xb*(parseInt(_0x4cdcfe(0x1ee))/0xc);if(_0x25bf57===_0x187042)break;else _0x323192['push'](_0x323192['shift']());}catch(_0xd7cdf9){_0x323192['push'](_0x323192['shift']());}}}(a197_0x5085,0x7ddad));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_0x5c5ecd(0x19a),a197_0x5c5ecd(0x1b9),a197_0x5c5ecd(0x1e1),a197_0x5c5ecd(0x18e),a197_0x5c5ecd(0x187)];function a197_0x4de5(_0x73b85b,_0x15fc3b){_0x73b85b=_0x73b85b-0x172;const _0x50857f=a197_0x5085();let _0x4de525=_0x50857f[_0x73b85b];return _0x4de525;}export const DEFAULT_NOTIFICATION_CONNECT_TIMEOUT=0x1388;export const DEFAULT_NOTIFICATION_READ_TIMEOUT=0x2710;const ALLOWED_INPUT_FIELDS=new Set([a197_0x5c5ecd(0x1e0),a197_0x5c5ecd(0x1cb),'endpointUrl',a197_0x5c5ecd(0x1ec),'description','connectTimeout',a197_0x5c5ecd(0x1c9)]),FORBIDDEN_IDENTITY_FIELDS=new Set(['id',a197_0x5c5ecd(0x178),'configCode','channelCode']),EMAIL_RECIPIENT_FIELDS=new Set([a197_0x5c5ecd(0x1af),a197_0x5c5ecd(0x191),'ccList',a197_0x5c5ecd(0x1bc),a197_0x5c5ecd(0x1e7),'subjectPrefix',a197_0x5c5ecd(0x1a4),'to','cc']);export const NOTIFICATION_INPUT_FLAGS=[{'name':'file','type':'string','required':![],'description':'Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20UTF-8\x20file'},{'name':'stdin','type':a197_0x5c5ecd(0x1de),'required':![],'default':![],'description':a197_0x5c5ecd(0x1c0)},{'name':'from-env','type':a197_0x5c5ecd(0x1e8),'required':![],'description':a197_0x5c5ecd(0x180)}];export const NOTIFICATION_ID_FLAG={'name':'id','type':a197_0x5c5ecd(0x1ad),'required':!![],'description':a197_0x5c5ecd(0x19e)};export const NOTIFICATION_APP_FLAG=APPCODE_FLAG_OPTIONAL;export function notificationError(_0x4a5234,_0x12ff38,_0xb57196){return new CliError(_0x4a5234,0x1,_0x12ff38,_0xb57196);}export function readNotificationId(_0x26ec38){const _0x324d5c=a197_0x5c5ecd,_0x2d8b07=_0x26ec38[_0x324d5c(0x1ac)]('id');if(!Number[_0x324d5c(0x17b)](_0x2d8b07)||_0x2d8b07<=0x0)throw notificationError(_0x324d5c(0x186),_0x324d5c(0x183));return _0x2d8b07;}export function requireNotificationExplicitYes(_0x4f6bd5){const _0x5b516d=a197_0x5c5ecd;if(_0x4f6bd5['bool'](_0x5b516d(0x1a7))||_0x4f6bd5[_0x5b516d(0x1ae)](_0x5b516d(0x1cd)))return;throw notificationError(_0x5b516d(0x1cc),_0x5b516d(0x1bf),_0x5b516d(0x17f));}export function readNotificationChannelType(_0x5009f6,_0x451838=a197_0x5c5ecd(0x1cf),_0x549a4c=a197_0x5c5ecd(0x19a)){const _0x16affd=a197_0x5c5ecd,_0x2cac1b=_0x5009f6[_0x16affd(0x1e6)](_0x451838)[_0x16affd(0x184)]()||_0x549a4c;if(!NOTIFICATION_CHANNEL_TYPES[_0x16affd(0x1b1)](_0x2cac1b))throw CliErrors[_0x16affd(0x1b5)]('Invalid\x20--'+_0x451838+':\x20'+_0x2cac1b,_0x16affd(0x199)+NOTIFICATION_CHANNEL_TYPES[_0x16affd(0x1f3)](',\x20')+'.');return _0x2cac1b;}export function assertSingleNotificationSource(_0x383a2e){const _0x3da54e=a197_0x5c5ecd,_0x15d4b6=[],_0x56470a=_0x383a2e[_0x3da54e(0x1e6)](_0x3da54e(0x1b6))[_0x3da54e(0x184)]();if(_0x56470a)_0x15d4b6['push']({'kind':'file','path':_0x56470a});if(_0x383a2e[_0x3da54e(0x1ae)]('stdin'))_0x15d4b6[_0x3da54e(0x1e4)]({'kind':_0x3da54e(0x195)});const _0x3d0801=_0x383a2e[_0x3da54e(0x1e6)](_0x3da54e(0x1ef))[_0x3da54e(0x184)]();if(_0x3d0801)_0x15d4b6[_0x3da54e(0x1e4)]({'kind':_0x3da54e(0x1db),'name':_0x3d0801});if(_0x15d4b6[_0x3da54e(0x1d8)]===0x0)throw CliErrors[_0x3da54e(0x1b5)](_0x3da54e(0x172),_0x3da54e(0x1aa));if(_0x15d4b6['length']>0x1)throw CliErrors[_0x3da54e(0x1b5)]('Notification\x20JSON\x20source\x20is\x20ambiguous.',_0x3da54e(0x1aa));return _0x15d4b6[0x0];}export async function readNotificationDocument(_0x283b0a,_0x46f0bb){const _0x259561=a197_0x5c5ecd,_0x5956d0=assertSingleNotificationSource(_0x283b0a),_0xf7ff7c=_0x5956d0['kind']===_0x259561(0x1b6)?'file\x20'+_0x5956d0[_0x259561(0x1f2)]:_0x5956d0[_0x259561(0x1e2)]==='env'?'environment\x20variable\x20'+_0x5956d0[_0x259561(0x1d1)]:_0x259561(0x195);let _0x258025;try{if(_0x5956d0[_0x259561(0x1e2)]===_0x259561(0x1b6))_0x258025=await readFile(_0x5956d0[_0x259561(0x1f2)],_0x259561(0x1d3));else{if(_0x5956d0[_0x259561(0x1e2)]===_0x259561(0x1db)){if(!(_0x5956d0[_0x259561(0x1d1)]in process.env))throw notificationError(_0x259561(0x1df),_0x259561(0x1a9)+_0x5956d0[_0x259561(0x1d1)]);_0x258025=process.env[_0x5956d0.name]??'';}else _0x258025=await readStdin();}}catch(_0x935159){if(_0x935159 instanceof CliError)throw _0x935159;throw notificationError(_0x259561(0x1df),'Unable\x20to\x20read\x20notification\x20JSON\x20from\x20'+_0xf7ff7c+'.');}let _0x2d7881;try{_0x2d7881=JSON[_0x259561(0x1a2)](_0x258025);}catch{throw notificationError(_0x259561(0x17a),_0x259561(0x17c)+_0xf7ff7c+_0x259561(0x1c8),_0x259561(0x19c));}if(!isJsonObject(_0x2d7881))throw notificationError(_0x259561(0x17a),_0x259561(0x17c)+_0xf7ff7c+_0x259561(0x1f0));return validateNotificationDocument(_0x2d7881,_0x46f0bb);}export function projectNotificationListConfig(_0x327e73,_0x3e3d54){const _0x12ae11=a197_0x5c5ecd;return{'id':typeof _0x327e73['id']===_0x12ae11(0x1ad)?_0x327e73['id']:null,'configCode':requireResponseString(_0x327e73['configCode'],_0x12ae11(0x1e9),_0x3e3d54),'configName':requireResponseString(_0x327e73[_0x12ae11(0x1e0)],_0x12ae11(0x1e0),_0x3e3d54),'channelType':requireResponseString(_0x327e73[_0x12ae11(0x1cb)],'channelType',_0x3e3d54),'description':normalizeNullableString(_0x327e73[_0x12ae11(0x19b)]),'createTime':normalizeNullableString(_0x327e73[_0x12ae11(0x1f1)]),'updateTime':normalizeNullableString(_0x327e73[_0x12ae11(0x1c7)])};}export function normalizeExactNotificationConfig(_0x69c711,_0x44f0e6,_0x543f5c){const _0x408d23=a197_0x5c5ecd;if(!Number[_0x408d23(0x17b)](_0x69c711['id'])||_0x69c711['id']!==_0x44f0e6)throw notificationError(_0x408d23(0x1dc),_0x408d23(0x193)+_0x44f0e6+'.');if(_0x69c711[_0x408d23(0x178)]!==_0x543f5c)throw notificationError(_0x408d23(0x1dc),_0x408d23(0x179)+_0x44f0e6+_0x408d23(0x174));const _0x415ea0=requireExactString(_0x69c711[_0x408d23(0x1e0)],_0x408d23(0x1e0),_0x44f0e6),_0x5de2e9=requireExactString(_0x69c711[_0x408d23(0x1e9)],_0x408d23(0x1e9),_0x44f0e6),_0x277f0a=requireExactString(_0x69c711['channelType'],_0x408d23(0x1cb),_0x44f0e6);if(!NOTIFICATION_CHANNEL_TYPES['includes'](_0x277f0a))throw notificationError(_0x408d23(0x1dc),'Notification\x20config\x20'+_0x44f0e6+'\x20has\x20an\x20unsupported\x20channelType.');const _0x37fa84=responseNullableString(_0x69c711[_0x408d23(0x18c)],_0x408d23(0x18c),_0x44f0e6),_0x5d9485=responseNullableString(_0x69c711[_0x408d23(0x1ec)],'channelConfig',_0x44f0e6),_0x3f0a65=responseNullableString(_0x69c711[_0x408d23(0x19b)],_0x408d23(0x19b),_0x44f0e6),_0x556031=responseNullableTimeout(_0x69c711[_0x408d23(0x1d9)],'connectTimeout',_0x44f0e6),_0x2959c8=responseNullableTimeout(_0x69c711[_0x408d23(0x1c9)],_0x408d23(0x1c9),_0x44f0e6);return{'id':_0x44f0e6,'appCode':_0x543f5c,'configCode':_0x5de2e9,'configName':_0x415ea0,'channelType':_0x277f0a,'endpointUrl':redactSensitive(_0x37fa84),'channelConfig':redactSensitive(_0x5d9485),'description':_0x3f0a65,'connectTimeout':_0x556031,'readTimeout':_0x2959c8,'endpointUrlRaw':_0x37fa84,'channelConfigRaw':_0x5d9485};}export async function requireExactNotificationConfig(_0x5353d5,_0x2438ec,_0x371261){const _0x50c247=a197_0x5c5ecd;let _0x3d4e52;try{_0x3d4e52=await getNotificationChannelConfig(_0x2438ec,_0x5353d5);}catch{throw safeApiFailure(_0x371261,_0x50c247(0x1bd),_0x50c247(0x1c2)+_0x5353d5+_0x50c247(0x190));}return normalizeExactNotificationConfig(_0x3d4e52,_0x2438ec,_0x5353d5);}export function projectNotificationConfig(_0x3d8ea4){const _0x174c4e=a197_0x5c5ecd;return{'id':_0x3d8ea4['id']??null,'appCode':_0x3d8ea4[_0x174c4e(0x178)],'configCode':_0x3d8ea4[_0x174c4e(0x1e9)]??null,'configName':_0x3d8ea4['configName'],'channelType':_0x3d8ea4[_0x174c4e(0x1cb)],'endpointUrl':redactSensitive(_0x3d8ea4[_0x174c4e(0x18c)]),'channelConfig':redactSensitive(_0x3d8ea4[_0x174c4e(0x1ec)]),'description':_0x3d8ea4[_0x174c4e(0x19b)]??null,'connectTimeout':_0x3d8ea4[_0x174c4e(0x1d9)]??null,'readTimeout':_0x3d8ea4[_0x174c4e(0x1c9)]??null};}export function notificationSelector(_0x383071){const _0x34639d=a197_0x5c5ecd;return{'appCode':_0x383071[_0x34639d(0x178)],'id':_0x383071['id'],'configCode':_0x383071[_0x34639d(0x1e9)],'configName':_0x383071[_0x34639d(0x1e0)],'channelType':_0x383071[_0x34639d(0x1cb)]};}export function createMutationInput(_0x1ad7cd,_0x4b71fb){const _0x448e3a=a197_0x5c5ecd;return{'appCode':_0x1ad7cd,'configName':_0x4b71fb['configName'],'channelType':_0x4b71fb[_0x448e3a(0x1cb)],...hasOwn(_0x4b71fb,_0x448e3a(0x18c))?{'endpointUrl':_0x4b71fb['endpointUrl']}:{},...hasOwn(_0x4b71fb,'channelConfig')?{'channelConfig':serializeChannelConfig(_0x4b71fb[_0x448e3a(0x1ec)])}:{},...hasOwn(_0x4b71fb,'description')?{'description':_0x4b71fb[_0x448e3a(0x19b)]}:{},...hasOwn(_0x4b71fb,_0x448e3a(0x1d9))?{'connectTimeout':_0x4b71fb['connectTimeout']}:{},...hasOwn(_0x4b71fb,_0x448e3a(0x1c9))?{'readTimeout':_0x4b71fb[_0x448e3a(0x1c9)]}:{}};}export function mergeUpdateInput(_0x17555b,_0x29915b){const _0x56d2eb=a197_0x5c5ecd;return{'id':_0x17555b['id'],'appCode':_0x17555b[_0x56d2eb(0x178)],'configName':_0x29915b[_0x56d2eb(0x1e0)]??_0x17555b[_0x56d2eb(0x1e0)],'channelType':_0x29915b['channelType']??_0x17555b[_0x56d2eb(0x1cb)],'endpointUrl':hasOwn(_0x29915b,_0x56d2eb(0x18c))?_0x29915b[_0x56d2eb(0x18c)]:_0x17555b[_0x56d2eb(0x1ea)],'channelConfig':hasOwn(_0x29915b,_0x56d2eb(0x1ec))?serializeChannelConfig(_0x29915b[_0x56d2eb(0x1ec)]):_0x17555b[_0x56d2eb(0x1e3)],'description':hasOwn(_0x29915b,_0x56d2eb(0x19b))?_0x29915b[_0x56d2eb(0x19b)]:_0x17555b[_0x56d2eb(0x19b)],'connectTimeout':hasOwn(_0x29915b,_0x56d2eb(0x1d9))?_0x29915b[_0x56d2eb(0x1d9)]:_0x17555b[_0x56d2eb(0x1d9)],'readTimeout':hasOwn(_0x29915b,'readTimeout')?_0x29915b[_0x56d2eb(0x1c9)]:_0x17555b[_0x56d2eb(0x1c9)]};}export function plannedUpdateProjection(_0x48202d,_0x187ce5){const _0x30cc4a=a197_0x5c5ecd;return projectNotificationConfig({'id':_0x48202d['id'],'appCode':_0x48202d['appCode'],'configCode':_0x48202d[_0x30cc4a(0x1e9)],'configName':_0x187ce5[_0x30cc4a(0x1e0)]??_0x48202d['configName'],'channelType':_0x187ce5[_0x30cc4a(0x1cb)]??_0x48202d[_0x30cc4a(0x1cb)],'endpointUrl':hasOwn(_0x187ce5,_0x30cc4a(0x18c))?_0x187ce5['endpointUrl']:_0x48202d[_0x30cc4a(0x1ea)],'channelConfig':hasOwn(_0x187ce5,_0x30cc4a(0x1ec))?_0x187ce5[_0x30cc4a(0x1ec)]:_0x48202d['channelConfigRaw'],'description':hasOwn(_0x187ce5,_0x30cc4a(0x19b))?_0x187ce5['description']:_0x48202d[_0x30cc4a(0x19b)],'connectTimeout':hasOwn(_0x187ce5,_0x30cc4a(0x1d9))?_0x187ce5[_0x30cc4a(0x1d9)]??DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:_0x48202d['connectTimeout'],'readTimeout':hasOwn(_0x187ce5,_0x30cc4a(0x1c9))?_0x187ce5[_0x30cc4a(0x1c9)]??DEFAULT_NOTIFICATION_READ_TIMEOUT:_0x48202d[_0x30cc4a(0x1c9)]});}export function requestedSafeFieldsMatch(_0x2f0fd3,_0x3515df,_0x113ddd){const _0x4333a5=a197_0x5c5ecd,_0x5bc8d9=[],_0x3b59e0=[],_0x15ad2a=[];for(const _0x15d4b9 of[_0x4333a5(0x1e0),_0x4333a5(0x1cb),_0x4333a5(0x19b)]){if(!hasOwn(_0x113ddd,_0x15d4b9))continue;_0x15ad2a[_0x4333a5(0x1e4)](_0x15d4b9),_0x5bc8d9[_0x4333a5(0x1e4)](_0x3515df[_0x15d4b9]===_0x113ddd[_0x15d4b9]),_0x3b59e0[_0x4333a5(0x1e4)](_0x2f0fd3[_0x15d4b9]!==_0x113ddd[_0x15d4b9]&&_0x3515df[_0x15d4b9]===_0x113ddd[_0x15d4b9]);}for(const _0x1f2a51 of[_0x4333a5(0x1d9),_0x4333a5(0x1c9)]){if(!hasOwn(_0x113ddd,_0x1f2a51))continue;const _0x19e8ff=_0x113ddd[_0x1f2a51]??(_0x1f2a51===_0x4333a5(0x1d9)?DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:DEFAULT_NOTIFICATION_READ_TIMEOUT);_0x15ad2a[_0x4333a5(0x1e4)](_0x1f2a51),_0x5bc8d9[_0x4333a5(0x1e4)](_0x3515df[_0x1f2a51]===_0x19e8ff),_0x3b59e0[_0x4333a5(0x1e4)](_0x2f0fd3[_0x1f2a51]!==_0x19e8ff&&_0x3515df[_0x1f2a51]===_0x19e8ff);}return hasOwn(_0x113ddd,_0x4333a5(0x18c))&&_0x113ddd[_0x4333a5(0x18c)]===null&&(_0x15ad2a['push']('endpointUrl:null'),_0x5bc8d9[_0x4333a5(0x1e4)](_0x3515df['endpointUrlRaw']===null||_0x3515df['endpointUrlRaw']===''),_0x3b59e0[_0x4333a5(0x1e4)](_0x2f0fd3[_0x4333a5(0x1ea)]!==null&&_0x2f0fd3[_0x4333a5(0x1ea)]!==''&&(_0x3515df[_0x4333a5(0x1ea)]===null||_0x3515df[_0x4333a5(0x1ea)]===''))),{'allMatch':_0x5bc8d9['every'](Boolean),'provesChange':_0x3b59e0['some'](Boolean),'verifiedFields':_0x15ad2a};}export function validateNotificationDeleteReadback(_0x1e34dc,_0x67a086,_0x2a15da){const _0x3e07d3=a197_0x5c5ecd;for(const [_0x907bcb,_0x5b748c]of _0x1e34dc['entries']()){if(!Number[_0x3e07d3(0x17b)](_0x5b748c['id'])||_0x5b748c['id']<=0x0)throw notificationError(_0x3e07d3(0x1dc),'Notification\x20config\x20list\x20item\x20'+(_0x907bcb+0x1)+_0x3e07d3(0x196));if(_0x5b748c[_0x3e07d3(0x178)]!==_0x67a086)throw notificationError(_0x3e07d3(0x1dc),_0x3e07d3(0x1d5)+(_0x907bcb+0x1)+_0x3e07d3(0x1b4));if(_0x5b748c[_0x3e07d3(0x1cb)]!==_0x2a15da)throw notificationError('notification_config_response_invalid',_0x3e07d3(0x1d5)+(_0x907bcb+0x1)+_0x3e07d3(0x1c6));}}export function safeApiFailure(_0x5a76e3,_0x1618bd,_0x2d2947){const _0x35e100=a197_0x5c5ecd;return notificationError(_0x35e100(0x1ba)+_0x5a76e3+'_'+(_0x1618bd===_0x35e100(0x18d)?_0x35e100(0x1a6):_0x1618bd+'_unavailable'),_0x35e100(0x179)+_0x5a76e3+'\x20'+_0x1618bd+_0x35e100(0x197),_0x2d2947);}export function notificationLookupCommand(_0x1a4331,_0x3b1c2e){const _0x10e18c=a197_0x5c5ecd;return _0x10e18c(0x1eb)+_0x1a4331+_0x10e18c(0x1b8)+_0x3b1c2e+_0x10e18c(0x17e);}function validateNotificationDocument(_0x28dfb7,_0x4aa3c2){const _0x59d85f=a197_0x5c5ecd;for(const _0x4db1f2 of Object[_0x59d85f(0x1c1)](_0x28dfb7)){if(FORBIDDEN_IDENTITY_FIELDS[_0x59d85f(0x1be)](_0x4db1f2))throw notificationError('notification_config_field_forbidden',_0x59d85f(0x1d2)+_0x4db1f2+'\x22\x20is\x20controlled\x20by\x20the\x20CLI\x20or\x20server\x20and\x20is\x20forbidden.');if(!ALLOWED_INPUT_FIELDS[_0x59d85f(0x1be)](_0x4db1f2))throw notificationError(_0x59d85f(0x192),'Unknown\x20notification\x20JSON\x20field\x20\x22'+_0x4db1f2+'\x22.');}if(_0x4aa3c2===_0x59d85f(0x185)&&Object[_0x59d85f(0x1c1)](_0x28dfb7)[_0x59d85f(0x1d8)]===0x0)throw notificationError('notification_config_update_empty',_0x59d85f(0x1d4));const _0x552736={};if(hasOwn(_0x28dfb7,_0x59d85f(0x1e0)))_0x552736[_0x59d85f(0x1e0)]=validateRequiredString(_0x28dfb7[_0x59d85f(0x1e0)],_0x59d85f(0x1e0),0x80);else{if(_0x4aa3c2===_0x59d85f(0x1da))throw notificationError('notification_config_field_required',_0x59d85f(0x18a)+'\x22configName\x22.');}if(hasOwn(_0x28dfb7,'channelType')){if(typeof _0x28dfb7[_0x59d85f(0x1cb)]!==_0x59d85f(0x1e8))throw invalidFieldType(_0x59d85f(0x1cb),_0x59d85f(0x194));const _0x202ad4=_0x28dfb7[_0x59d85f(0x1cb)][_0x59d85f(0x184)]();if(!NOTIFICATION_CHANNEL_TYPES[_0x59d85f(0x1b1)](_0x202ad4))throw notificationError(_0x59d85f(0x1bb),_0x59d85f(0x1c3),_0x59d85f(0x199)+NOTIFICATION_CHANNEL_TYPES[_0x59d85f(0x1f3)](',\x20')+'.');_0x552736[_0x59d85f(0x1cb)]=_0x202ad4;}else{if(_0x4aa3c2===_0x59d85f(0x1da))throw notificationError(_0x59d85f(0x198),_0x59d85f(0x18a)+_0x59d85f(0x1b3));}for(const [_0x424740,_0xf1bc20]of[[_0x59d85f(0x18c),0x200],['description',0x100]]){if(!hasOwn(_0x28dfb7,_0x424740))continue;const _0x1567e4=_0x28dfb7[_0x424740];if(_0x1567e4!==null&&typeof _0x1567e4!==_0x59d85f(0x1e8))throw invalidFieldType(_0x424740,_0x59d85f(0x1b0));if(typeof _0x1567e4===_0x59d85f(0x1e8)&&_0x1567e4[_0x59d85f(0x1d8)]>_0xf1bc20)throw notificationError(_0x59d85f(0x1bb),'Notification\x20JSON\x20field\x20\x22'+_0x424740+'\x22\x20cannot\x20exceed\x20'+_0xf1bc20+'\x20characters.');_0x552736[_0x424740]=_0x1567e4;}if(hasOwn(_0x28dfb7,_0x59d85f(0x1ec))){const _0x546ea6=_0x28dfb7[_0x59d85f(0x1ec)];if(_0x546ea6===null&&_0x4aa3c2===_0x59d85f(0x1da))throw invalidFieldType(_0x59d85f(0x1ec),'a\x20JSON\x20object');if(_0x546ea6!==null&&!isJsonObject(_0x546ea6))throw invalidFieldType(_0x59d85f(0x1ec),_0x4aa3c2===_0x59d85f(0x185)?_0x59d85f(0x1d0):_0x59d85f(0x182));_0x546ea6!==null&&validateChannelConfigFields(_0x552736['channelType'],_0x546ea6),_0x552736[_0x59d85f(0x1ec)]=_0x546ea6;}for(const _0x5cea1a of[_0x59d85f(0x1d9),_0x59d85f(0x1c9)]){if(!hasOwn(_0x28dfb7,_0x5cea1a))continue;const _0x1930a0=_0x28dfb7[_0x5cea1a];if(_0x1930a0!==null&&(!Number[_0x59d85f(0x17b)](_0x1930a0)||_0x1930a0<0x0))throw notificationError(_0x59d85f(0x1bb),_0x59d85f(0x1d2)+_0x5cea1a+_0x59d85f(0x1b2));_0x552736[_0x5cea1a]=_0x1930a0;}return _0x552736;}function validateRequiredString(_0x54b6ab,_0x2933e1,_0x28053a){const _0x3e3a66=a197_0x5c5ecd;if(typeof _0x54b6ab!==_0x3e3a66(0x1e8))throw invalidFieldType(_0x2933e1,_0x3e3a66(0x1ab));const _0x142721=_0x54b6ab[_0x3e3a66(0x184)]();if(!_0x142721)throw notificationError(_0x3e3a66(0x1bb),'Notification\x20JSON\x20field\x20\x22'+_0x2933e1+_0x3e3a66(0x18f));if(_0x142721['length']>_0x28053a)throw notificationError('notification_config_field_invalid',_0x3e3a66(0x1d2)+_0x2933e1+_0x3e3a66(0x1a8)+_0x28053a+_0x3e3a66(0x181));return _0x142721;}function validateChannelConfigFields(_0x4298b0,_0x4e24af){const _0xa898a1=a197_0x5c5ecd;if(hasOwn(_0x4e24af,'messageTemplate'))throw forbiddenChannelConfigField('messageTemplate');if(_0x4298b0===_0xa898a1(0x19a))for(const _0x4606f1 of EMAIL_RECIPIENT_FIELDS){if(hasOwn(_0x4e24af,_0x4606f1))throw forbiddenChannelConfigField(_0x4606f1);}}function forbiddenChannelConfigField(_0x192aa5){const _0x166328=a197_0x5c5ecd;return notificationError(_0x166328(0x1a0),_0x166328(0x1c4)+_0x192aa5+_0x166328(0x1ed));}function invalidFieldType(_0x1cadec,_0x515433){const _0xb5acdf=a197_0x5c5ecd;return notificationError(_0xb5acdf(0x1bb),_0xb5acdf(0x1d2)+_0x1cadec+_0xb5acdf(0x19d)+_0x515433+'.');}function serializeChannelConfig(_0x35c828){const _0x5ce927=a197_0x5c5ecd;return _0x35c828===null||_0x35c828===undefined?null:JSON[_0x5ce927(0x1c5)](_0x35c828);}function redactSensitive(_0x372684){return _0x372684===null||_0x372684===undefined||_0x372684===''?null:'<redacted>';}function requireResponseString(_0x110dc2,_0x337c81,_0x194349){const _0x46c1bb=a197_0x5c5ecd;if(typeof _0x110dc2!==_0x46c1bb(0x1e8)||_0x110dc2[_0x46c1bb(0x184)]()==='')throw CliErrors[_0x46c1bb(0x1a5)]('Invalid\x20notification\x20config\x20response.',_0x46c1bb(0x18b)+(_0x194349+0x1)+_0x46c1bb(0x176)+_0x337c81+'\x22.');return _0x110dc2[_0x46c1bb(0x184)]();}function a197_0x5085(){const _0x181673=['call','str','replyTo','string','configCode','endpointUrlRaw','rabetbase\x20notification\x20config-list\x20--appcode\x20','channelConfig','\x22\x20is\x20forbidden.','5160Fmqunv','from-env','\x20must\x20be\x20an\x20object.','createTime','path','join','Missing\x20notification\x20JSON\x20source.','1206404QRKtTF','\x20does\x20not\x20belong\x20to\x20the\x20resolved\x20app.','4655436FtiJmM','\x20is\x20missing\x20required\x20field\x20\x22','hasOwnProperty','appCode','Notification\x20config\x20','notification_config_json_invalid','isSafeInteger','Notification\x20JSON\x20from\x20','\x20has\x20invalid\x20field\x20\x22','\x20--format\x20compress','Run\x20the\x20command\x20with\x20--dry-run\x20first,\x20then\x20add\x20--yes\x20after\x20reviewing\x20the\x20plan.','Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20named\x20environment\x20variable','\x20characters.','a\x20JSON\x20object','--id\x20must\x20be\x20a\x20positive\x20safe\x20integer.','trim','update','notification_config_id_invalid','WEBHOOK','5952450cBjfgO','53449niQqDG','Create\x20JSON\x20requires\x20field\x20','Item\x20','endpointUrl','mutation','WECOM','\x22\x20must\x20be\x20a\x20non-empty\x20string.','\x20--type\x20<CHANNEL_TYPE>\x20--format\x20compress;\x20no\x20mutation\x20was\x20submitted.','recipients','notification_config_field_unknown','Notification\x20config\x20detail\x20did\x20not\x20contain\x20the\x20requested\x20ID\x20','a\x20supported\x20string','stdin','\x20has\x20an\x20invalid\x20id.','\x20failed.','notification_config_field_required','Allowed\x20values:\x20','EMAIL','description','Provide\x20one\x20valid\x20JSON\x20object;\x20source\x20contents\x20are\x20not\x20included\x20in\x20errors.','\x22\x20must\x20be\x20','Application-level\x20notification\x20config\x20ID','74PMFwPp','notification_config_channel_field_forbidden','190BPfXce','parse','isArray','fromName','apiError','failed','dry-run','\x22\x20cannot\x20exceed\x20','Notification\x20JSON\x20environment\x20variable\x20is\x20not\x20set:\x20','Use\x20exactly\x20one\x20of\x20--file\x20<path>,\x20--stdin,\x20or\x20--from-env\x20<NAME>.','a\x20non-empty\x20string','num','number','bool','emailTargets','a\x20string\x20or\x20null','includes','\x22\x20must\x20be\x20a\x20non-negative\x20safe\x20integer\x20or\x20null.','\x22channelType\x22.','\x20has\x20an\x20invalid\x20appCode.','validation','file','642585OWDMbH','\x20--type\x20','FEISHU','notification_config_','notification_config_field_invalid','bccList','preflight','has','This\x20notification\x20config\x20mutation\x20requires\x20explicit\x20--yes.','Read\x20the\x20notification\x20JSON\x20document\x20from\x20stdin','keys','Inspect\x20with\x20rabetbase\x20notification\x20config-list\x20--appcode\x20','Notification\x20JSON\x20field\x20\x22channelType\x22\x20is\x20unsupported.','Notification\x20JSON\x20channelConfig\x20field\x20\x22','stringify','\x20has\x20an\x20invalid\x20channelType.','updateTime','\x20is\x20invalid.','readTimeout','8PEhOUB','channelType','notification_config_confirmation_required','yes','3CCIjev','type','a\x20JSON\x20object\x20or\x20null','name','Notification\x20JSON\x20field\x20\x22','utf8','Update\x20JSON\x20must\x20contain\x20at\x20least\x20one\x20allowed\x20field.','Notification\x20config\x20list\x20item\x20','337446aZXhGg','6213bcshAS','length','connectTimeout','create','env','notification_config_response_invalid','prototype','boolean','notification_config_source_unavailable','configName','DINGTALK','kind','channelConfigRaw','push'];a197_0x5085=function(){return _0x181673;};return a197_0x5085();}function requireExactString(_0x2a828c,_0x301f3b,_0x38e3de){const _0x42d8f9=a197_0x5c5ecd;if(typeof _0x2a828c!==_0x42d8f9(0x1e8)||_0x2a828c[_0x42d8f9(0x184)]()==='')throw notificationError(_0x42d8f9(0x1dc),_0x42d8f9(0x179)+_0x38e3de+_0x42d8f9(0x176)+_0x301f3b+'\x22.');return _0x2a828c[_0x42d8f9(0x184)]();}function responseNullableString(_0xf168f1,_0x54b214,_0x427866){const _0x5f01ba=a197_0x5c5ecd;if(_0xf168f1===undefined||_0xf168f1===null)return null;if(typeof _0xf168f1!=='string')throw notificationError(_0x5f01ba(0x1dc),'Notification\x20config\x20'+_0x427866+_0x5f01ba(0x17d)+_0x54b214+'\x22.');return _0xf168f1;}function responseNullableTimeout(_0x4e931e,_0x1fca54,_0x4275c3){const _0x3a08a6=a197_0x5c5ecd;if(_0x4e931e===undefined||_0x4e931e===null)return null;if(!Number[_0x3a08a6(0x17b)](_0x4e931e)||_0x4e931e<0x0)throw notificationError(_0x3a08a6(0x1dc),_0x3a08a6(0x179)+_0x4275c3+'\x20has\x20invalid\x20field\x20\x22'+_0x1fca54+'\x22.');return _0x4e931e;}function normalizeNullableString(_0x219ad2){const _0x28c347=a197_0x5c5ecd;return typeof _0x219ad2===_0x28c347(0x1e8)?_0x219ad2:null;}function isJsonObject(_0x1dca3f){const _0x5a0ac8=a197_0x5c5ecd;return _0x1dca3f!==null&&typeof _0x1dca3f==='object'&&!Array[_0x5a0ac8(0x1a3)](_0x1dca3f);}function hasOwn(_0x30903d,_0x312f33){const _0x2fc359=a197_0x5c5ecd;return Object[_0x2fc359(0x1dd)][_0x2fc359(0x177)][_0x2fc359(0x1e5)](_0x30903d,_0x312f33);}async function readStdin(){const _0x5644e9=a197_0x5c5ecd;let _0x57b482='';process[_0x5644e9(0x195)]['setEncoding'](_0x5644e9(0x1d3));for await(const _0x578341 of process[_0x5644e9(0x195)])_0x57b482+=_0x578341;return _0x57b482;}
|
|
1
|
+
const a197_0x486777=a197_0x2b62;(function(_0x121134,_0xbbeef3){const _0x16bad9=a197_0x2b62,_0x29a295=_0x121134();while(!![]){try{const _0xbbcd63=-parseInt(_0x16bad9(0x1d3))/0x1+parseInt(_0x16bad9(0x1d5))/0x2*(-parseInt(_0x16bad9(0x1be))/0x3)+parseInt(_0x16bad9(0x1b1))/0x4+-parseInt(_0x16bad9(0x1de))/0x5+parseInt(_0x16bad9(0x1b4))/0x6+-parseInt(_0x16bad9(0x203))/0x7+-parseInt(_0x16bad9(0x216))/0x8*(-parseInt(_0x16bad9(0x1b8))/0x9);if(_0xbbcd63===_0xbbeef3)break;else _0x29a295['push'](_0x29a295['shift']());}catch(_0x1b4ade){_0x29a295['push'](_0x29a295['shift']());}}}(a197_0x1bd4,0x70849));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=['EMAIL','FEISHU',a197_0x486777(0x1f6),'WECOM',a197_0x486777(0x1e3)];export const DEFAULT_NOTIFICATION_CONNECT_TIMEOUT=0x1388;export const DEFAULT_NOTIFICATION_READ_TIMEOUT=0x2710;const ALLOWED_INPUT_FIELDS=new Set(['configName',a197_0x486777(0x217),'endpointUrl',a197_0x486777(0x1ca),a197_0x486777(0x201),a197_0x486777(0x20e),a197_0x486777(0x1bb)]),FORBIDDEN_IDENTITY_FIELDS=new Set(['id',a197_0x486777(0x1af),'configCode','channelCode']),EMAIL_RECIPIENT_FIELDS=new Set([a197_0x486777(0x1f9),a197_0x486777(0x1a7),a197_0x486777(0x1ee),a197_0x486777(0x1ba),'replyTo','subjectPrefix',a197_0x486777(0x21a),'to','cc']);export const NOTIFICATION_INPUT_FLAGS=[{'name':a197_0x486777(0x1c8),'type':a197_0x486777(0x1d9),'required':![],'description':a197_0x486777(0x1b2)},{'name':a197_0x486777(0x219),'type':a197_0x486777(0x1f2),'required':![],'default':![],'description':a197_0x486777(0x1fd)},{'name':a197_0x486777(0x1a4),'type':a197_0x486777(0x1d9),'required':![],'description':a197_0x486777(0x1ab)}];export const NOTIFICATION_ID_FLAG={'name':'id','type':'number','required':!![],'description':'Application-level\x20notification\x20config\x20ID'};export const NOTIFICATION_APP_FLAG=APPCODE_FLAG_OPTIONAL;export function notificationError(_0x3f3527,_0x409fb9,_0xe550b5){return new CliError(_0x3f3527,0x1,_0x409fb9,_0xe550b5);}export function readNotificationId(_0x3f8a77){const _0x2134b0=a197_0x486777,_0x1df013=_0x3f8a77[_0x2134b0(0x213)]('id');if(!Number[_0x2134b0(0x1db)](_0x1df013)||_0x1df013<=0x0)throw notificationError(_0x2134b0(0x209),'--id\x20must\x20be\x20a\x20positive\x20safe\x20integer.');return _0x1df013;}export function requireNotificationExplicitYes(_0xe09f0c){const _0x35569f=a197_0x486777;if(_0xe09f0c[_0x35569f(0x211)](_0x35569f(0x21b))||_0xe09f0c[_0x35569f(0x211)](_0x35569f(0x1c5)))return;throw notificationError('notification_config_confirmation_required','This\x20notification\x20config\x20mutation\x20requires\x20explicit\x20--yes.',_0x35569f(0x1d1));}export function readNotificationChannelType(_0x17c151,_0x179c31=a197_0x486777(0x1c7),_0x2d7887=a197_0x486777(0x1a9)){const _0x1a1074=a197_0x486777,_0x21aaf1=_0x17c151[_0x1a1074(0x1f3)](_0x179c31)['trim']()||_0x2d7887;if(!NOTIFICATION_CHANNEL_TYPES[_0x1a1074(0x1f4)](_0x21aaf1))throw CliErrors[_0x1a1074(0x208)](_0x1a1074(0x1d7)+_0x179c31+':\x20'+_0x21aaf1,_0x1a1074(0x1a0)+NOTIFICATION_CHANNEL_TYPES[_0x1a1074(0x1e5)](',\x20')+'.');return _0x21aaf1;}export function assertSingleNotificationSource(_0x589bed){const _0x457a53=a197_0x486777,_0x950b56=[],_0xedfb28=_0x589bed[_0x457a53(0x1f3)]('file')[_0x457a53(0x218)]();if(_0xedfb28)_0x950b56[_0x457a53(0x21e)]({'kind':'file','path':_0xedfb28});if(_0x589bed[_0x457a53(0x211)](_0x457a53(0x219)))_0x950b56[_0x457a53(0x21e)]({'kind':'stdin'});const _0x40e459=_0x589bed[_0x457a53(0x1f3)](_0x457a53(0x1a4))['trim']();if(_0x40e459)_0x950b56[_0x457a53(0x21e)]({'kind':_0x457a53(0x1b7),'name':_0x40e459});if(_0x950b56[_0x457a53(0x1bd)]===0x0)throw CliErrors[_0x457a53(0x208)](_0x457a53(0x1b5),_0x457a53(0x1fe));if(_0x950b56['length']>0x1)throw CliErrors['validation']('Notification\x20JSON\x20source\x20is\x20ambiguous.',_0x457a53(0x1fe));return _0x950b56[0x0];}function a197_0x2b62(_0x555876,_0x120faa){_0x555876=_0x555876-0x1a0;const _0x1bd49e=a197_0x1bd4();let _0x2b6229=_0x1bd49e[_0x555876];return _0x2b6229;}export async function readNotificationDocument(_0xcf5f5c,_0x2b7b95){const _0x4d7838=a197_0x486777,_0x563799=assertSingleNotificationSource(_0xcf5f5c),_0x5cd193=_0x563799[_0x4d7838(0x1bf)]==='file'?_0x4d7838(0x1a8)+_0x563799[_0x4d7838(0x1ce)]:_0x563799[_0x4d7838(0x1bf)]==='env'?_0x4d7838(0x202)+_0x563799[_0x4d7838(0x215)]:_0x4d7838(0x219);let _0x214195;try{if(_0x563799['kind']===_0x4d7838(0x1c8))_0x214195=await readFile(_0x563799[_0x4d7838(0x1ce)],_0x4d7838(0x1e4));else{if(_0x563799[_0x4d7838(0x1bf)]===_0x4d7838(0x1b7)){if(!(_0x563799[_0x4d7838(0x215)]in process.env))throw notificationError(_0x4d7838(0x1fc),_0x4d7838(0x1b0)+_0x563799[_0x4d7838(0x215)]);_0x214195=process.env[_0x563799.name]??'';}else _0x214195=await readStdin();}}catch(_0xd5e3d4){if(_0xd5e3d4 instanceof CliError)throw _0xd5e3d4;throw notificationError('notification_config_source_unavailable','Unable\x20to\x20read\x20notification\x20JSON\x20from\x20'+_0x5cd193+'.');}let _0x7b5253;try{_0x7b5253=JSON['parse'](_0x214195);}catch{throw notificationError(_0x4d7838(0x1c4),'Notification\x20JSON\x20from\x20'+_0x5cd193+_0x4d7838(0x1e0),_0x4d7838(0x1e6));}if(!isJsonObject(_0x7b5253))throw notificationError(_0x4d7838(0x1c4),'Notification\x20JSON\x20from\x20'+_0x5cd193+_0x4d7838(0x1f1));return validateNotificationDocument(_0x7b5253,_0x2b7b95);}export function projectNotificationListConfig(_0x23f115,_0x11a0d1){const _0x278fa9=a197_0x486777;return{'id':typeof _0x23f115['id']===_0x278fa9(0x204)?_0x23f115['id']:null,'configCode':requireResponseString(_0x23f115['configCode'],_0x278fa9(0x1ad),_0x11a0d1),'configName':requireResponseString(_0x23f115['configName'],_0x278fa9(0x1d2),_0x11a0d1),'channelType':requireResponseString(_0x23f115[_0x278fa9(0x217)],_0x278fa9(0x217),_0x11a0d1),'description':normalizeNullableString(_0x23f115[_0x278fa9(0x201)]),'createTime':normalizeNullableString(_0x23f115[_0x278fa9(0x1f8)]),'updateTime':normalizeNullableString(_0x23f115[_0x278fa9(0x1d4)])};}export function normalizeExactNotificationConfig(_0x5c0bb9,_0x46f40a,_0x575346){const _0x32c2f2=a197_0x486777;if(!Number[_0x32c2f2(0x1db)](_0x5c0bb9['id'])||_0x5c0bb9['id']!==_0x46f40a)throw notificationError(_0x32c2f2(0x1c3),_0x32c2f2(0x1e7)+_0x46f40a+'.');if(_0x5c0bb9[_0x32c2f2(0x1af)]!==_0x575346)throw notificationError(_0x32c2f2(0x1c3),'Notification\x20config\x20'+_0x46f40a+_0x32c2f2(0x1ea));const _0x2df053=requireExactString(_0x5c0bb9[_0x32c2f2(0x1d2)],'configName',_0x46f40a),_0x5a2622=requireExactString(_0x5c0bb9[_0x32c2f2(0x1ad)],_0x32c2f2(0x1ad),_0x46f40a),_0x2e949b=requireExactString(_0x5c0bb9[_0x32c2f2(0x217)],_0x32c2f2(0x217),_0x46f40a);if(!NOTIFICATION_CHANNEL_TYPES['includes'](_0x2e949b))throw notificationError('notification_config_response_invalid','Notification\x20config\x20'+_0x46f40a+_0x32c2f2(0x21f));const _0x3e98b6=responseNullableString(_0x5c0bb9[_0x32c2f2(0x200)],_0x32c2f2(0x200),_0x46f40a),_0x5b6653=responseNullableString(_0x5c0bb9[_0x32c2f2(0x1ca)],'channelConfig',_0x46f40a),_0xb12ef1=responseNullableString(_0x5c0bb9[_0x32c2f2(0x201)],_0x32c2f2(0x201),_0x46f40a),_0x3ca85f=responseNullableTimeout(_0x5c0bb9[_0x32c2f2(0x20e)],_0x32c2f2(0x20e),_0x46f40a),_0x1e961d=responseNullableTimeout(_0x5c0bb9[_0x32c2f2(0x1bb)],_0x32c2f2(0x1bb),_0x46f40a);return{'id':_0x46f40a,'appCode':_0x575346,'configCode':_0x5a2622,'configName':_0x2df053,'channelType':_0x2e949b,'endpointUrl':redactSensitive(_0x3e98b6),'channelConfig':redactSensitive(_0x5b6653),'description':_0xb12ef1,'connectTimeout':_0x3ca85f,'readTimeout':_0x1e961d,'endpointUrlRaw':_0x3e98b6,'channelConfigRaw':_0x5b6653};}export async function requireExactNotificationConfig(_0x5889bb,_0x4d9229,_0x1acc1a){const _0x5b69b5=a197_0x486777;let _0xdbcbe5;try{_0xdbcbe5=await getNotificationChannelConfig(_0x4d9229,_0x5889bb);}catch{throw safeApiFailure(_0x1acc1a,'preflight',_0x5b69b5(0x1dd)+_0x5889bb+_0x5b69b5(0x1c0));}return normalizeExactNotificationConfig(_0xdbcbe5,_0x4d9229,_0x5889bb);}export function projectNotificationConfig(_0x238667){const _0x33bd72=a197_0x486777;return{'id':_0x238667['id']??null,'appCode':_0x238667[_0x33bd72(0x1af)],'configCode':_0x238667[_0x33bd72(0x1ad)]??null,'configName':_0x238667['configName'],'channelType':_0x238667[_0x33bd72(0x217)],'endpointUrl':redactSensitive(_0x238667[_0x33bd72(0x200)]),'channelConfig':redactSensitive(_0x238667[_0x33bd72(0x1ca)]),'description':_0x238667['description']??null,'connectTimeout':_0x238667[_0x33bd72(0x20e)]??null,'readTimeout':_0x238667[_0x33bd72(0x1bb)]??null};}export function notificationSelector(_0x69bd57){const _0x517815=a197_0x486777;return{'appCode':_0x69bd57[_0x517815(0x1af)],'id':_0x69bd57['id'],'configCode':_0x69bd57[_0x517815(0x1ad)],'configName':_0x69bd57[_0x517815(0x1d2)],'channelType':_0x69bd57['channelType']};}export function createMutationInput(_0x2cb5cb,_0x35b003){const _0x47c012=a197_0x486777;return{'appCode':_0x2cb5cb,'configName':_0x35b003[_0x47c012(0x1d2)],'channelType':_0x35b003[_0x47c012(0x217)],...hasOwn(_0x35b003,_0x47c012(0x200))?{'endpointUrl':_0x35b003['endpointUrl']}:{},...hasOwn(_0x35b003,_0x47c012(0x1ca))?{'channelConfig':serializeChannelConfig(_0x35b003[_0x47c012(0x1ca)])}:{},...hasOwn(_0x35b003,'description')?{'description':_0x35b003[_0x47c012(0x201)]}:{},...hasOwn(_0x35b003,_0x47c012(0x20e))?{'connectTimeout':_0x35b003['connectTimeout']}:{},...hasOwn(_0x35b003,'readTimeout')?{'readTimeout':_0x35b003[_0x47c012(0x1bb)]}:{}};}export function mergeUpdateInput(_0x2419b8,_0x170dff){const _0x529a28=a197_0x486777;return{'id':_0x2419b8['id'],'appCode':_0x2419b8['appCode'],'configName':_0x170dff[_0x529a28(0x1d2)]??_0x2419b8['configName'],'channelType':_0x170dff[_0x529a28(0x217)]??_0x2419b8[_0x529a28(0x217)],'endpointUrl':hasOwn(_0x170dff,_0x529a28(0x200))?_0x170dff[_0x529a28(0x200)]:_0x2419b8[_0x529a28(0x1d0)],'channelConfig':hasOwn(_0x170dff,_0x529a28(0x1ca))?serializeChannelConfig(_0x170dff[_0x529a28(0x1ca)]):_0x2419b8[_0x529a28(0x1da)],'description':hasOwn(_0x170dff,_0x529a28(0x201))?_0x170dff[_0x529a28(0x201)]:_0x2419b8[_0x529a28(0x201)],'connectTimeout':hasOwn(_0x170dff,'connectTimeout')?_0x170dff[_0x529a28(0x20e)]:_0x2419b8[_0x529a28(0x20e)],'readTimeout':hasOwn(_0x170dff,_0x529a28(0x1bb))?_0x170dff['readTimeout']:_0x2419b8['readTimeout']};}export function plannedUpdateProjection(_0x4fdf46,_0x45747a){const _0x3a63d7=a197_0x486777;return projectNotificationConfig({'id':_0x4fdf46['id'],'appCode':_0x4fdf46['appCode'],'configCode':_0x4fdf46['configCode'],'configName':_0x45747a['configName']??_0x4fdf46[_0x3a63d7(0x1d2)],'channelType':_0x45747a[_0x3a63d7(0x217)]??_0x4fdf46[_0x3a63d7(0x217)],'endpointUrl':hasOwn(_0x45747a,_0x3a63d7(0x200))?_0x45747a['endpointUrl']:_0x4fdf46[_0x3a63d7(0x1d0)],'channelConfig':hasOwn(_0x45747a,_0x3a63d7(0x1ca))?_0x45747a['channelConfig']:_0x4fdf46[_0x3a63d7(0x1da)],'description':hasOwn(_0x45747a,_0x3a63d7(0x201))?_0x45747a[_0x3a63d7(0x201)]:_0x4fdf46[_0x3a63d7(0x201)],'connectTimeout':hasOwn(_0x45747a,_0x3a63d7(0x20e))?_0x45747a[_0x3a63d7(0x20e)]??DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:_0x4fdf46[_0x3a63d7(0x20e)],'readTimeout':hasOwn(_0x45747a,_0x3a63d7(0x1bb))?_0x45747a[_0x3a63d7(0x1bb)]??DEFAULT_NOTIFICATION_READ_TIMEOUT:_0x4fdf46[_0x3a63d7(0x1bb)]});}export function requestedSafeFieldsMatch(_0x4764c3,_0x3370a5,_0xda619d){const _0x4205cc=a197_0x486777,_0x5820c2=[],_0x4a9d2c=[],_0x125cf8=[];for(const _0x315b72 of[_0x4205cc(0x1d2),_0x4205cc(0x217),_0x4205cc(0x201)]){if(!hasOwn(_0xda619d,_0x315b72))continue;_0x125cf8['push'](_0x315b72),_0x5820c2[_0x4205cc(0x21e)](_0x3370a5[_0x315b72]===_0xda619d[_0x315b72]),_0x4a9d2c[_0x4205cc(0x21e)](_0x4764c3[_0x315b72]!==_0xda619d[_0x315b72]&&_0x3370a5[_0x315b72]===_0xda619d[_0x315b72]);}for(const _0x191f46 of[_0x4205cc(0x20e),_0x4205cc(0x1bb)]){if(!hasOwn(_0xda619d,_0x191f46))continue;const _0x107f62=_0xda619d[_0x191f46]??(_0x191f46===_0x4205cc(0x20e)?DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:DEFAULT_NOTIFICATION_READ_TIMEOUT);_0x125cf8[_0x4205cc(0x21e)](_0x191f46),_0x5820c2['push'](_0x3370a5[_0x191f46]===_0x107f62),_0x4a9d2c[_0x4205cc(0x21e)](_0x4764c3[_0x191f46]!==_0x107f62&&_0x3370a5[_0x191f46]===_0x107f62);}return hasOwn(_0xda619d,_0x4205cc(0x200))&&_0xda619d[_0x4205cc(0x200)]===null&&(_0x125cf8['push'](_0x4205cc(0x1ed)),_0x5820c2[_0x4205cc(0x21e)](_0x3370a5[_0x4205cc(0x1d0)]===null||_0x3370a5[_0x4205cc(0x1d0)]===''),_0x4a9d2c[_0x4205cc(0x21e)](_0x4764c3[_0x4205cc(0x1d0)]!==null&&_0x4764c3[_0x4205cc(0x1d0)]!==''&&(_0x3370a5[_0x4205cc(0x1d0)]===null||_0x3370a5[_0x4205cc(0x1d0)]===''))),{'allMatch':_0x5820c2[_0x4205cc(0x1a3)](Boolean),'provesChange':_0x4a9d2c['some'](Boolean),'verifiedFields':_0x125cf8};}export function validateNotificationDeleteReadback(_0x199e6b,_0x270414,_0x281979){const _0x2f05da=a197_0x486777;for(const [_0x49a439,_0x82824e]of _0x199e6b['entries']()){if(!Number[_0x2f05da(0x1db)](_0x82824e['id'])||_0x82824e['id']<=0x0)throw notificationError(_0x2f05da(0x1c3),_0x2f05da(0x1dc)+(_0x49a439+0x1)+_0x2f05da(0x1fa));if(_0x82824e[_0x2f05da(0x1af)]!==_0x270414)throw notificationError('notification_config_response_invalid',_0x2f05da(0x1dc)+(_0x49a439+0x1)+_0x2f05da(0x222));if(_0x82824e[_0x2f05da(0x217)]!==_0x281979)throw notificationError(_0x2f05da(0x1c3),'Notification\x20config\x20list\x20item\x20'+(_0x49a439+0x1)+_0x2f05da(0x210));}}function a197_0x1bd4(){const _0x2c02e5=['\x22\x20is\x20controlled\x20by\x20the\x20CLI\x20or\x20server\x20and\x20is\x20forbidden.','recipients','file\x20','EMAIL','Notification\x20JSON\x20field\x20\x22','Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20named\x20environment\x20variable','Notification\x20JSON\x20field\x20\x22channelType\x22\x20is\x20unsupported.','configCode','apiError','appCode','Notification\x20JSON\x20environment\x20variable\x20is\x20not\x20set:\x20','3045204yafAlj','Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20UTF-8\x20file','object','2155008eeoUbF','Missing\x20notification\x20JSON\x20source.','stringify','env','153pxRkVA','setEncoding','bccList','readTimeout','<redacted>','length','3IzBuNg','kind','\x20--type\x20<CHANNEL_TYPE>\x20--format\x20compress;\x20no\x20mutation\x20was\x20submitted.','a\x20supported\x20string','Notification\x20config\x20','notification_config_response_invalid','notification_config_json_invalid','yes','notification_config_','type','file','_unavailable','channelConfig','\x22\x20must\x20be\x20','Create\x20JSON\x20requires\x20field\x20','a\x20string\x20or\x20null','path','messageTemplate','endpointUrlRaw','Run\x20the\x20command\x20with\x20--dry-run\x20first,\x20then\x20add\x20--yes\x20after\x20reviewing\x20the\x20plan.','configName','47178NEUVZz','updateTime','1680054qhMTwT','create','Invalid\x20--','call','string','channelConfigRaw','isSafeInteger','Notification\x20config\x20list\x20item\x20','Inspect\x20with\x20rabetbase\x20notification\x20config-list\x20--appcode\x20','3806310vtbwJw','a\x20non-empty\x20string','\x20is\x20invalid.','\x22channelType\x22.','\x20--format\x20compress','WEBHOOK','utf8','join','Provide\x20one\x20valid\x20JSON\x20object;\x20source\x20contents\x20are\x20not\x20included\x20in\x20errors.','Notification\x20config\x20detail\x20did\x20not\x20contain\x20the\x20requested\x20ID\x20','has','\x22\x20is\x20forbidden.','\x20does\x20not\x20belong\x20to\x20the\x20resolved\x20app.','update','\x20characters.','endpointUrl:null','ccList','keys','\x20is\x20missing\x20required\x20field\x20\x22','\x20must\x20be\x20an\x20object.','boolean','str','includes','mutation','DINGTALK','prototype','createTime','emailTargets','\x20has\x20an\x20invalid\x20id.','Unknown\x20notification\x20JSON\x20field\x20\x22','notification_config_source_unavailable','Read\x20the\x20notification\x20JSON\x20document\x20from\x20stdin','Use\x20exactly\x20one\x20of\x20--file\x20<path>,\x20--stdin,\x20or\x20--from-env\x20<NAME>.','\x22\x20must\x20be\x20a\x20non-negative\x20safe\x20integer\x20or\x20null.','endpointUrl','description','environment\x20variable\x20','1531068VxrYlW','number','notification_config_field_invalid','notification_config_field_forbidden','hasOwnProperty','validation','notification_config_id_invalid','\x22\x20cannot\x20exceed\x20','notification_config_channel_field_forbidden','\x20--type\x20','\x22configName\x22.','connectTimeout','\x20failed.','\x20has\x20an\x20invalid\x20channelType.','bool','Notification\x20JSON\x20channelConfig\x20field\x20\x22','num','isArray','name','568280nLBaVi','channelType','trim','stdin','fromName','dry-run','Update\x20JSON\x20must\x20contain\x20at\x20least\x20one\x20allowed\x20field.','notification_config_field_required','push','\x20has\x20an\x20unsupported\x20channelType.','notification_config_update_empty','\x20has\x20invalid\x20field\x20\x22','\x20has\x20an\x20invalid\x20appCode.','Allowed\x20values:\x20','a\x20JSON\x20object','notification_config_field_unknown','every','from-env','\x22\x20must\x20be\x20a\x20non-empty\x20string.'];a197_0x1bd4=function(){return _0x2c02e5;};return a197_0x1bd4();}export function safeApiFailure(_0x50255c,_0x45b446,_0x29ffa0){const _0x1aaf09=a197_0x486777;return notificationError(_0x1aaf09(0x1c6)+_0x50255c+'_'+(_0x45b446===_0x1aaf09(0x1f5)?'failed':_0x45b446+_0x1aaf09(0x1c9)),_0x1aaf09(0x1c2)+_0x50255c+'\x20'+_0x45b446+_0x1aaf09(0x20f),_0x29ffa0);}export function notificationLookupCommand(_0x5cfa01,_0x46b474){const _0x38267e=a197_0x486777;return'rabetbase\x20notification\x20config-list\x20--appcode\x20'+_0x5cfa01+_0x38267e(0x20c)+_0x46b474+_0x38267e(0x1e2);}function validateNotificationDocument(_0x5013f4,_0x4089f1){const _0x28a3a8=a197_0x486777;for(const _0x48e4d6 of Object[_0x28a3a8(0x1ef)](_0x5013f4)){if(FORBIDDEN_IDENTITY_FIELDS[_0x28a3a8(0x1e8)](_0x48e4d6))throw notificationError(_0x28a3a8(0x206),_0x28a3a8(0x1aa)+_0x48e4d6+_0x28a3a8(0x1a6));if(!ALLOWED_INPUT_FIELDS[_0x28a3a8(0x1e8)](_0x48e4d6))throw notificationError(_0x28a3a8(0x1a2),_0x28a3a8(0x1fb)+_0x48e4d6+'\x22.');}if(_0x4089f1===_0x28a3a8(0x1eb)&&Object['keys'](_0x5013f4)[_0x28a3a8(0x1bd)]===0x0)throw notificationError(_0x28a3a8(0x220),_0x28a3a8(0x21c));const _0x1d1a47={};if(hasOwn(_0x5013f4,'configName'))_0x1d1a47[_0x28a3a8(0x1d2)]=validateRequiredString(_0x5013f4[_0x28a3a8(0x1d2)],_0x28a3a8(0x1d2),0x80);else{if(_0x4089f1===_0x28a3a8(0x1d6))throw notificationError(_0x28a3a8(0x21d),_0x28a3a8(0x1cc)+_0x28a3a8(0x20d));}if(hasOwn(_0x5013f4,_0x28a3a8(0x217))){if(typeof _0x5013f4['channelType']!==_0x28a3a8(0x1d9))throw invalidFieldType(_0x28a3a8(0x217),_0x28a3a8(0x1c1));const _0x47fb3e=_0x5013f4[_0x28a3a8(0x217)]['trim']();if(!NOTIFICATION_CHANNEL_TYPES[_0x28a3a8(0x1f4)](_0x47fb3e))throw notificationError(_0x28a3a8(0x205),_0x28a3a8(0x1ac),_0x28a3a8(0x1a0)+NOTIFICATION_CHANNEL_TYPES['join'](',\x20')+'.');_0x1d1a47[_0x28a3a8(0x217)]=_0x47fb3e;}else{if(_0x4089f1===_0x28a3a8(0x1d6))throw notificationError(_0x28a3a8(0x21d),'Create\x20JSON\x20requires\x20field\x20'+_0x28a3a8(0x1e1));}for(const [_0x1d7578,_0x3297b7]of[[_0x28a3a8(0x200),0x200],[_0x28a3a8(0x201),0x100]]){if(!hasOwn(_0x5013f4,_0x1d7578))continue;const _0xa53e8f=_0x5013f4[_0x1d7578];if(_0xa53e8f!==null&&typeof _0xa53e8f!==_0x28a3a8(0x1d9))throw invalidFieldType(_0x1d7578,_0x28a3a8(0x1cd));if(typeof _0xa53e8f===_0x28a3a8(0x1d9)&&_0xa53e8f[_0x28a3a8(0x1bd)]>_0x3297b7)throw notificationError(_0x28a3a8(0x205),_0x28a3a8(0x1aa)+_0x1d7578+_0x28a3a8(0x20a)+_0x3297b7+_0x28a3a8(0x1ec));_0x1d1a47[_0x1d7578]=_0xa53e8f;}if(hasOwn(_0x5013f4,_0x28a3a8(0x1ca))){const _0x3641c3=_0x5013f4[_0x28a3a8(0x1ca)];if(_0x3641c3===null&&_0x4089f1===_0x28a3a8(0x1d6))throw invalidFieldType(_0x28a3a8(0x1ca),_0x28a3a8(0x1a1));if(_0x3641c3!==null&&!isJsonObject(_0x3641c3))throw invalidFieldType(_0x28a3a8(0x1ca),_0x4089f1===_0x28a3a8(0x1eb)?'a\x20JSON\x20object\x20or\x20null':'a\x20JSON\x20object');_0x3641c3!==null&&validateChannelConfigFields(_0x1d1a47[_0x28a3a8(0x217)],_0x3641c3),_0x1d1a47[_0x28a3a8(0x1ca)]=_0x3641c3;}for(const _0x474852 of[_0x28a3a8(0x20e),_0x28a3a8(0x1bb)]){if(!hasOwn(_0x5013f4,_0x474852))continue;const _0x91de13=_0x5013f4[_0x474852];if(_0x91de13!==null&&(!Number['isSafeInteger'](_0x91de13)||_0x91de13<0x0))throw notificationError(_0x28a3a8(0x205),_0x28a3a8(0x1aa)+_0x474852+_0x28a3a8(0x1ff));_0x1d1a47[_0x474852]=_0x91de13;}return _0x1d1a47;}function validateRequiredString(_0x184984,_0x16b038,_0xb6c6c5){const _0x90c380=a197_0x486777;if(typeof _0x184984!==_0x90c380(0x1d9))throw invalidFieldType(_0x16b038,_0x90c380(0x1df));const _0x509703=_0x184984[_0x90c380(0x218)]();if(!_0x509703)throw notificationError(_0x90c380(0x205),_0x90c380(0x1aa)+_0x16b038+_0x90c380(0x1a5));if(_0x509703['length']>_0xb6c6c5)throw notificationError('notification_config_field_invalid',_0x90c380(0x1aa)+_0x16b038+'\x22\x20cannot\x20exceed\x20'+_0xb6c6c5+_0x90c380(0x1ec));return _0x509703;}function validateChannelConfigFields(_0x3b4fc0,_0x519b89){const _0x24d5a9=a197_0x486777;if(hasOwn(_0x519b89,_0x24d5a9(0x1cf)))throw forbiddenChannelConfigField('messageTemplate');if(_0x3b4fc0==='EMAIL')for(const _0xd5bdfd of EMAIL_RECIPIENT_FIELDS){if(hasOwn(_0x519b89,_0xd5bdfd))throw forbiddenChannelConfigField(_0xd5bdfd);}}function forbiddenChannelConfigField(_0x31bd83){const _0x27188f=a197_0x486777;return notificationError(_0x27188f(0x20b),_0x27188f(0x212)+_0x31bd83+_0x27188f(0x1e9));}function invalidFieldType(_0x5a5d1a,_0x10bcdd){const _0x59b024=a197_0x486777;return notificationError(_0x59b024(0x205),_0x59b024(0x1aa)+_0x5a5d1a+_0x59b024(0x1cb)+_0x10bcdd+'.');}function serializeChannelConfig(_0x1718de){const _0xb908b9=a197_0x486777;return _0x1718de===null||_0x1718de===undefined?null:JSON[_0xb908b9(0x1b6)](_0x1718de);}function redactSensitive(_0x296579){const _0x424b03=a197_0x486777;return _0x296579===null||_0x296579===undefined||_0x296579===''?null:_0x424b03(0x1bc);}function requireResponseString(_0x3a7a0b,_0x472dbf,_0x3ea233){const _0x38b4ef=a197_0x486777;if(typeof _0x3a7a0b!==_0x38b4ef(0x1d9)||_0x3a7a0b[_0x38b4ef(0x218)]()==='')throw CliErrors[_0x38b4ef(0x1ae)]('Invalid\x20notification\x20config\x20response.','Item\x20'+(_0x3ea233+0x1)+_0x38b4ef(0x1f0)+_0x472dbf+'\x22.');return _0x3a7a0b['trim']();}function requireExactString(_0x4e6b28,_0xddd6ce,_0x12343f){const _0x598d01=a197_0x486777;if(typeof _0x4e6b28!==_0x598d01(0x1d9)||_0x4e6b28['trim']()==='')throw notificationError(_0x598d01(0x1c3),'Notification\x20config\x20'+_0x12343f+_0x598d01(0x1f0)+_0xddd6ce+'\x22.');return _0x4e6b28[_0x598d01(0x218)]();}function responseNullableString(_0x590bf7,_0x143a31,_0x3ad1ce){const _0x30d7c3=a197_0x486777;if(_0x590bf7===undefined||_0x590bf7===null)return null;if(typeof _0x590bf7!==_0x30d7c3(0x1d9))throw notificationError(_0x30d7c3(0x1c3),_0x30d7c3(0x1c2)+_0x3ad1ce+_0x30d7c3(0x221)+_0x143a31+'\x22.');return _0x590bf7;}function responseNullableTimeout(_0x25ad7,_0x27f0c4,_0x1d57ba){const _0x33bbdc=a197_0x486777;if(_0x25ad7===undefined||_0x25ad7===null)return null;if(!Number[_0x33bbdc(0x1db)](_0x25ad7)||_0x25ad7<0x0)throw notificationError(_0x33bbdc(0x1c3),_0x33bbdc(0x1c2)+_0x1d57ba+_0x33bbdc(0x221)+_0x27f0c4+'\x22.');return _0x25ad7;}function normalizeNullableString(_0x5c5162){return typeof _0x5c5162==='string'?_0x5c5162:null;}function isJsonObject(_0x30628c){const _0x32284d=a197_0x486777;return _0x30628c!==null&&typeof _0x30628c===_0x32284d(0x1b3)&&!Array[_0x32284d(0x214)](_0x30628c);}function hasOwn(_0x33cf09,_0x181b3a){const _0x4633e0=a197_0x486777;return Object[_0x4633e0(0x1f7)][_0x4633e0(0x207)][_0x4633e0(0x1d8)](_0x33cf09,_0x181b3a);}async function readStdin(){const _0x1310b9=a197_0x486777;let _0x1ecc3b='';process[_0x1310b9(0x219)][_0x1310b9(0x1b9)](_0x1310b9(0x1e4));for await(const _0x4fb393 of process[_0x1310b9(0x219)])_0x1ecc3b+=_0x4fb393;return _0x1ecc3b;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a198_0x1ed9f7=a198_0x3db1;(function(_0x3f0a0e,_0x2a3cab){const _0x353912=a198_0x3db1,_0x15f199=_0x3f0a0e();while(!![]){try{const _0x289740=parseInt(_0x353912(0x7a))/0x1+parseInt(_0x353912(0x8b))/0x2+-parseInt(_0x353912(0x8d))/0x3+parseInt(_0x353912(0x90))/0x4*(-parseInt(_0x353912(0xa2))/0x5)+-parseInt(_0x353912(0xa6))/0x6+-parseInt(_0x353912(0x9e))/0x7*(parseInt(_0x353912(0xa9))/0x8)+-parseInt(_0x353912(0x84))/0x9*(-parseInt(_0x353912(0x92))/0xa);if(_0x289740===_0x2a3cab)break;else _0x15f199['push'](_0x15f199['shift']());}catch(_0x5c9914){_0x15f199['push'](_0x15f199['shift']());}}}(a198_0x2b85,0x20f55));import{requireDevelopmentUploadFile}from'../../commands/common/local-file.js';import{queryDevelopmentFileUrl,recognizeDevelopmentOcr,uploadDevelopmentFile}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';const SUPPORTED_SCENES=[a198_0x1ed9f7(0xa8),a198_0x1ed9f7(0xa7),a198_0x1ed9f7(0xa4),'idCard'],SCENE_TO_LEGACY_TYPE={'invoice':a198_0x1ed9f7(0x82),'general':a198_0x1ed9f7(0x96),'form':a198_0x1ed9f7(0x93),'idCard':a198_0x1ed9f7(0x98)},SCENE_FLAG={'name':'scene','type':'string','required':!![],'enum':[...SUPPORTED_SCENES],'description':a198_0x1ed9f7(0x7c)},IMAGE_FILE_FLAG={'name':a198_0x1ed9f7(0x78),'type':a198_0x1ed9f7(0x85),'description':'Local\x20image\x20or\x20PDF\x20file;\x20uses\x20upload\x20->\x20query-url\x20->\x20OCR'},IMAGE_URL_FLAG={'name':a198_0x1ed9f7(0x9b),'type':a198_0x1ed9f7(0x85),'description':'Publicly\x20accessible\x20image\x20or\x20file\x20URL'};function normalizeScene(_0xe3c85c){const _0x18e600=a198_0x1ed9f7,_0x4426e4=_0xe3c85c[_0x18e600(0x9a)]()[_0x18e600(0x97)]();if(_0x4426e4===_0x18e600(0x95))return _0x18e600(0xa1);if(_0x4426e4===_0x18e600(0xa8)||_0x4426e4===_0x18e600(0xa7)||_0x4426e4===_0x18e600(0xa4))return _0x4426e4;throw CliErrors[_0x18e600(0x83)](_0x18e600(0xa3)+_0xe3c85c+_0x18e600(0x89)+SUPPORTED_SCENES[_0x18e600(0x9d)](',\x20'));}function a198_0x2b85(){const _0x4e4cbb=['Table','POST','idcard','General','toLowerCase','IdCard','Preview:\x20recognize\x20','trim','image-url','read','join','7bAZinL','/smartapi/ocr/recognize-text?','scene','idCard','710520biZuzd','Unsupported\x20OCR\x20scene:\x20','form','filePath','1544436DsSRqV','general','invoice','1712768LFNXOj','File\x20upload\x20response\x20missing\x20filePath.','filter','str','\x20OCR','/smartapi/common/uploadFile','image-file','appCode','240450KWjlmL','GET','OCR\x20scene:\x20invoice,\x20general,\x20form,\x20or\x20idCard','\x20OCR\x20from\x20URL','imageFile','fileUrl','Preview:\x20upload\x20local\x20file,\x20query\x20temporary\x20URL,\x20then\x20recognize\x20','<fileUrl\x20returned\x20by\x20/smartapi/common/queryFileUrl>','Invoice','validation','117BOiDMo','string','imageUrl','ocr','apiError','.\x20Supported\x20scenes:\x20','/smartapi/ocr/recognize-text','313886fdxAon','toString','654960oYSrYg','/smartapi/common/queryFileUrl','<filePath\x20returned\x20by\x20/smartapi/common/uploadFile>','4bOTSDC','fileName','438100Xolyaq'];a198_0x2b85=function(){return _0x4e4cbb;};return a198_0x2b85();}function selectedInputs(_0x22cd9a){const _0x42cdcf=a198_0x1ed9f7,_0x218547=_0x22cd9a[_0x42cdcf(0xac)]('image-file')['trim'](),_0x46c216=_0x22cd9a[_0x42cdcf(0xac)](_0x42cdcf(0x9b))[_0x42cdcf(0x9a)]();return{'imageFile':_0x218547,'imageUrl':_0x46c216,'count':[_0x218547,_0x46c216][_0x42cdcf(0xab)](Boolean)['length']};}function validateInputSelection(_0x29a354){const _0x18fa2b=a198_0x1ed9f7,_0x12cf38=selectedInputs(_0x29a354);if(_0x12cf38['count']!==0x1)throw CliErrors[_0x18fa2b(0x83)]('Choose\x20exactly\x20one\x20OCR\x20input:\x20--image-file\x20or\x20--image-url.');return _0x12cf38;}function withScene(_0x348557,_0x1566ab,_0x472e5d){const _0x2daec3=a198_0x1ed9f7;return{..._0x348557,'scene':_0x1566ab,..._0x472e5d?{'sourceFile':{'fileName':_0x472e5d[_0x2daec3(0x91)],'filePath':_0x472e5d[_0x2daec3(0xa5)]}}:{}};}const ocrRecognize={'service':a198_0x1ed9f7(0x87),'command':'recognize','description':'Extract\x20text\x20and\x20structured\x20fields\x20from\x20voucher-style\x20business\x20documents;\x20not\x20for\x20general\x20image\x20understanding','risk':a198_0x1ed9f7(0x9c),'flags':[SCENE_FLAG,IMAGE_FILE_FLAG,IMAGE_URL_FLAG],async 'dryRun'(_0x5a9038){const _0x9d2c2b=a198_0x1ed9f7,_0x461103=normalizeScene(_0x5a9038['str'](_0x9d2c2b(0xa0))),_0x162a81=SCENE_TO_LEGACY_TYPE[_0x461103],_0x283d15=validateInputSelection(_0x5a9038);if(_0x283d15[_0x9d2c2b(0x86)]){const _0x560448=new URLSearchParams({'url':_0x283d15[_0x9d2c2b(0x86)],'type':_0x162a81,'appCode':_0x5a9038['appCode']});return{'method':_0x9d2c2b(0x7b),'url':_0x9d2c2b(0x9f)+_0x560448[_0x9d2c2b(0x8c)](),'description':_0x9d2c2b(0x99)+_0x461103+_0x9d2c2b(0x7d)};}const _0x32aa14=requireDevelopmentUploadFile(_0x283d15[_0x9d2c2b(0x7e)],_0x9d2c2b(0x78));return{'method':_0x9d2c2b(0x94),'url':_0x9d2c2b(0x77),'body':{'steps':[{'method':'POST','url':_0x9d2c2b(0x77),'body':{'appCode':_0x5a9038[_0x9d2c2b(0x79)],'multipart':{'file':_0x32aa14}}},{'method':_0x9d2c2b(0x94),'url':_0x9d2c2b(0x8e),'body':{'filePath':_0x9d2c2b(0x8f),'downloadFlag':![]}},{'method':_0x9d2c2b(0x7b),'url':_0x9d2c2b(0x8a),'query':{'appCode':_0x5a9038['appCode'],'url':_0x9d2c2b(0x81),'type':_0x162a81}}]},'description':_0x9d2c2b(0x80)+_0x461103+_0x9d2c2b(0x76)};},async 'execute'(_0x3b53dc){const _0x5c979d=a198_0x1ed9f7,_0x422d59=normalizeScene(_0x3b53dc[_0x5c979d(0xac)]('scene')),_0x5a17b0=SCENE_TO_LEGACY_TYPE[_0x422d59],_0x275f1f=validateInputSelection(_0x3b53dc);if(_0x275f1f['imageUrl']){const _0x49bc5f=await recognizeDevelopmentOcr(_0x3b53dc[_0x5c979d(0x79)],{'url':_0x275f1f[_0x5c979d(0x86)],'type':_0x5a17b0});return{'ok':!![],'data':withScene(_0x49bc5f,_0x422d59)};}const _0x3101d2=requireDevelopmentUploadFile(_0x275f1f[_0x5c979d(0x7e)],_0x5c979d(0x78)),_0x470b0b=await uploadDevelopmentFile(_0x3b53dc['appCode'],_0x3101d2['path']);if(!_0x470b0b[_0x5c979d(0xa5)])throw CliErrors['apiError'](_0x5c979d(0xaa));const _0x44813f=await queryDevelopmentFileUrl(_0x470b0b['filePath'],{'download':![]});if(!_0x44813f[_0x5c979d(0x7f)])throw CliErrors[_0x5c979d(0x88)]('File\x20URL\x20response\x20missing\x20fileUrl.');const _0x55f6c6=await recognizeDevelopmentOcr(_0x3b53dc[_0x5c979d(0x79)],{'url':_0x44813f[_0x5c979d(0x7f)],'type':_0x5a17b0});return{'ok':!![],'data':withScene(_0x55f6c6,_0x422d59,_0x470b0b)};}};function a198_0x3db1(_0x28a8c9,_0x422f21){_0x28a8c9=_0x28a8c9-0x76;const _0x2b852c=a198_0x2b85();let _0x3db1b0=_0x2b852c[_0x28a8c9];return _0x3db1b0;}export const ocrDefinitions=[ocrRecognize];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a199_0x1056(_0x47c283,_0x243ba0){_0x47c283=_0x47c283-0x145;const _0x3e6a2e=a199_0x3e6a();let _0x105661=_0x3e6a2e[_0x47c283];return _0x105661;}const a199_0x4f4fdf=a199_0x1056;(function(_0x2324d5,_0x153f4f){const _0x519815=a199_0x1056,_0x18a6c6=_0x2324d5();while(!![]){try{const _0x218d7e=parseInt(_0x519815(0x16a))/0x1+-parseInt(_0x519815(0x17a))/0x2+-parseInt(_0x519815(0x15a))/0x3+-parseInt(_0x519815(0x16d))/0x4+parseInt(_0x519815(0x17f))/0x5+parseInt(_0x519815(0x177))/0x6+parseInt(_0x519815(0x159))/0x7;if(_0x218d7e===_0x153f4f)break;else _0x18a6c6['push'](_0x18a6c6['shift']());}catch(_0x46cfb2){_0x18a6c6['push'](_0x18a6c6['shift']());}}}(a199_0x3e6a,0x5357f));import{readFile}from'node:fs/promises';function a199_0x3e6a(){const _0x2e8a5c=['Would\x20create\x20Custom\x20Page\x20','page.create','Invalid\x20Custom\x20Page\x20pattern:\x20','keys','--page-pattern\x20must\x20be\x20BLANK,\x20ONEPAGE,\x20or\x20DASHBOARD.','stringify','version','--page-pattern\x20and\x20--page-dir\x20cannot\x20be\x20used\x20together.','compress','utf8','Built-in\x20Custom\x20Page\x20pattern\x20(cannot\x20be\x20used\x20with\x20--page-dir)','some','Create\x20a\x20JSX\x20Custom\x20Page\x20from\x20a\x20released\x20pattern\x20or\x20local\x20directory','string','page-type','POST','4957708aRleOa','278517Plnhci','Custom\x20Page\x20was\x20created,\x20but\x20a\x20link\x20to\x20its\x20latest\x20saved\x20content\x20could\x20not\x20be\x20generated.','ONEPAGE','menuId','str','Custom_page_','Write\x20the\x20complete\x20page\x20files\x20to\x20a\x20local\x20directory\x20and\x20use\x20--page-dir\x20<dir>.','create','page\x20create\x20does\x20not\x20accept\x20--page-type.','isNaN','Custom\x20Page\x20creation\x20did\x20not\x20return\x20a\x20valid\x20pageId.','values','BLANK','write','files','page-dir','141319nJxTXk','parent-menu-id','toLowerCase','2717092ajshJm','pageName','page-content','trim','page-pattern','page\x20create\x20no\x20longer\x20accepts\x20--page-content.','validation','Created\x20Custom\x20Page\x20','number','name','1290600isUVXj','Optional\x20parent\x20menu\x20id\x20when\x20creating\x20a\x20menu\x20entry','parentMenuId','711192eaOlGU','now','Directory\x20containing\x20all\x20page\x20files\x20(cannot\x20be\x20used\x20with\x20--page-pattern)','isInteger','--page-dir\x20must\x20contain\x20at\x20least\x20one\x20page\x20file.','2022100mxzoKA','appCode','num','pageId','.json','Custom\x20Page\x20pattern\x20not\x20found:\x20','apiError','../../../templates/custom-pages','menuPath','Provide\x20--page-pattern\x20BLANK,\x20ONEPAGE,\x20DASHBOARD,\x20or\x20--page-dir\x20<dir>.'];a199_0x3e6a=function(){return _0x2e8a5c;};return a199_0x3e6a();}import{dirname,join,resolve}from'node:path';import{fileURLToPath}from'node:url';import{APPCODE_FLAG}from'../../commands/common/flags.js';import{readCustomPageDirectory}from'../../core/page/file-system.js';import{createCustomPage}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{buildCustomPageDevelopmentUrl,buildCustomPageEditUrl,validateCustomPageContent}from'./custom/shared.js';const CUSTOM_PAGE_PATTERNS=[a199_0x4f4fdf(0x166),a199_0x4f4fdf(0x15c),'DASHBOARD'],CUSTOM_PAGE_TEMPLATE_DIR=resolve(dirname(fileURLToPath(import.meta.url)),a199_0x4f4fdf(0x146));export const pageCreate={'service':'page','command':a199_0x4f4fdf(0x161),'description':a199_0x4f4fdf(0x155),'risk':a199_0x4f4fdf(0x167),'defaultOutputFormat':a199_0x4f4fdf(0x151),'structuredErrors':!![],'rejectedFlags':[{'name':a199_0x4f4fdf(0x157),'message':a199_0x4f4fdf(0x162),'hint':'This\x20command\x20always\x20creates\x20a\x20CUSTOM\x20JSX\x20page;\x20use\x20--page-pattern\x20BLANK,\x20ONEPAGE,\x20DASHBOARD,\x20or\x20--page-dir.'},{'name':a199_0x4f4fdf(0x16f),'message':a199_0x4f4fdf(0x172),'hint':a199_0x4f4fdf(0x160)}],'flags':[{'name':a199_0x4f4fdf(0x176),'type':'string','description':'Optional\x20Custom\x20Page\x20name\x20(1-100\x20characters)'},{'name':a199_0x4f4fdf(0x16b),'type':a199_0x4f4fdf(0x175),'description':a199_0x4f4fdf(0x178)},{'name':a199_0x4f4fdf(0x171),'type':a199_0x4f4fdf(0x156),'description':a199_0x4f4fdf(0x153),'enum':CUSTOM_PAGE_PATTERNS},{'name':a199_0x4f4fdf(0x169),'type':a199_0x4f4fdf(0x156),'description':a199_0x4f4fdf(0x17c)},APPCODE_FLAG],async 'validate'(_0x1513c7){await readValidatedPageSource(_0x1513c7);},async 'dryRun'(_0x578ce1){const _0x385c83=a199_0x4f4fdf,_0x322f7b=readInput(_0x578ce1,await readValidatedPageSource(_0x578ce1));return{'method':_0x385c83(0x158),'url':'/smartapi/webcode/page/create','body':{'appCode':_0x322f7b[_0x385c83(0x180)],'pageName':_0x322f7b[_0x385c83(0x16e)],..._0x322f7b[_0x385c83(0x179)]!=null?{'parentMenuId':_0x322f7b[_0x385c83(0x179)]}:{},'createMenu':_0x322f7b['createMenu'],'codeContent':_0x322f7b[_0x385c83(0x168)]},'description':_0x385c83(0x149)+JSON[_0x385c83(0x14e)](_0x322f7b['pageName'])+'\x20and\x20its\x20menu\x20entry.'};},async 'execute'(_0x5da06c){const _0x5305d0=a199_0x4f4fdf,_0x115037=readInput(_0x5da06c,await readValidatedPageSource(_0x5da06c)),_0x5eeb45=await createCustomPage(_0x115037);if(!Number[_0x5305d0(0x17d)](_0x5eeb45[_0x5305d0(0x182)])||_0x5eeb45[_0x5305d0(0x182)]<=0x0)throw CliErrors[_0x5305d0(0x145)](_0x5305d0(0x164));const _0x386185=buildCustomPageDevelopmentUrl(_0x115037[_0x5305d0(0x180)],_0x5eeb45[_0x5305d0(0x147)]),_0x436148=buildCustomPageEditUrl(_0x115037[_0x5305d0(0x180)],_0x5eeb45['pageId']);return{'ok':!![],'data':{'operation':_0x5305d0(0x14a),'pageType':'CUSTOM','pagePattern':readPagePattern(_0x5da06c),'selector':{'appCode':_0x115037[_0x5305d0(0x180)],'pageName':_0x115037[_0x5305d0(0x16e)]},'before':null,'after':{'pageId':_0x5eeb45[_0x5305d0(0x182)],'pageName':_0x5eeb45['pageName'],'appCode':_0x5eeb45[_0x5305d0(0x180)],'version':_0x5eeb45[_0x5305d0(0x14f)],'menuId':_0x5eeb45[_0x5305d0(0x15d)],'menuPath':_0x5eeb45[_0x5305d0(0x147)],'files':_0x5eeb45[_0x5305d0(0x168)]??Object['keys'](_0x115037[_0x5305d0(0x168)])},'dryRun':![],'request':_0x115037,..._0x386185?{'pageUrl':_0x386185}:{},..._0x436148?{'editPageUrl':_0x436148}:{},'warnings':_0x386185?[]:[_0x5305d0(0x15b)]},'message':_0x5305d0(0x174)+_0x5eeb45[_0x5305d0(0x182)]+'.'};}};function readPagePattern(_0x1dcaa6){const _0x5b6ed5=a199_0x4f4fdf,_0x2ff868=_0x1dcaa6[_0x5b6ed5(0x15e)](_0x5b6ed5(0x171))[_0x5b6ed5(0x170)](),_0x155def=_0x1dcaa6['str'](_0x5b6ed5(0x169))['trim']();if(_0x2ff868&&_0x155def)throw CliErrors[_0x5b6ed5(0x173)](_0x5b6ed5(0x150));if(_0x155def)return null;if(!_0x2ff868)throw CliErrors[_0x5b6ed5(0x173)](_0x5b6ed5(0x148));if(!CUSTOM_PAGE_PATTERNS['includes'](_0x2ff868))throw CliErrors[_0x5b6ed5(0x173)](_0x5b6ed5(0x14d));return _0x2ff868;}async function readPageSource(_0x9c9c76){const _0x21b41d=a199_0x4f4fdf,_0x92bd78=_0x9c9c76[_0x21b41d(0x15e)](_0x21b41d(0x169))['trim'](),_0x1ddc1b=readPagePattern(_0x9c9c76);if(_0x1ddc1b===null){const _0x475e6f=await readCustomPageDirectory(_0x92bd78);if(Object[_0x21b41d(0x14c)](_0x475e6f)['length']===0x0)throw CliErrors[_0x21b41d(0x173)](_0x21b41d(0x17e));return _0x475e6f;}let _0x4e8483;try{_0x4e8483=await readFile(join(CUSTOM_PAGE_TEMPLATE_DIR,_0x1ddc1b[_0x21b41d(0x16c)]()+_0x21b41d(0x183)),_0x21b41d(0x152));}catch{throw CliErrors[_0x21b41d(0x173)](_0x21b41d(0x184)+_0x1ddc1b+'.');}let _0x258ff5;try{_0x258ff5=JSON['parse'](_0x4e8483);}catch{throw CliErrors[_0x21b41d(0x173)](_0x21b41d(0x14b)+_0x1ddc1b+'.');}if(!_0x258ff5||typeof _0x258ff5!=='object'||Array['isArray'](_0x258ff5)||Object[_0x21b41d(0x165)](_0x258ff5)[_0x21b41d(0x154)](_0x59541c=>typeof _0x59541c!==_0x21b41d(0x156)))throw CliErrors['validation'](_0x21b41d(0x14b)+_0x1ddc1b+'.');return _0x258ff5;}async function readValidatedPageSource(_0x4eff57){const _0x59889d=await readPageSource(_0x4eff57);return await validateCustomPageContent(_0x59889d),_0x59889d;}function readInput(_0x230e3f,_0x1f8a18){const _0x1d6805=a199_0x4f4fdf,_0x299da9=_0x230e3f['str'](_0x1d6805(0x176))['trim']()||_0x1d6805(0x15f)+Date[_0x1d6805(0x17b)]();if(_0x299da9['length']>0x64)throw CliErrors[_0x1d6805(0x173)]('pageName\x20cannot\x20exceed\x20100\x20characters.');const _0x30a3fb=_0x230e3f[_0x1d6805(0x181)]('parent-menu-id',NaN),_0x4bae66=!Number[_0x1d6805(0x163)](_0x30a3fb);if(_0x4bae66&&(!Number[_0x1d6805(0x17d)](_0x30a3fb)||_0x30a3fb<=0x0))throw CliErrors['validation']('--parent-menu-id\x20must\x20be\x20a\x20positive\x20integer.');return{'appCode':_0x230e3f[_0x1d6805(0x180)],'pageName':_0x299da9,..._0x4bae66?{'parentMenuId':_0x30a3fb}:{},'createMenu':!![],'files':_0x1f8a18};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a200_0x35128d=a200_0xa163;(function(_0x4b11f5,_0x30b4a3){const _0x4607fe=a200_0xa163,_0xde007=_0x4b11f5();while(!![]){try{const _0x3efc48=parseInt(_0x4607fe(0xec))/0x1+parseInt(_0x4607fe(0xee))/0x2+-parseInt(_0x4607fe(0xed))/0x3*(parseInt(_0x4607fe(0xf6))/0x4)+-parseInt(_0x4607fe(0xea))/0x5*(parseInt(_0x4607fe(0xe4))/0x6)+-parseInt(_0x4607fe(0xe1))/0x7+parseInt(_0x4607fe(0xe9))/0x8+parseInt(_0x4607fe(0xf3))/0x9;if(_0x3efc48===_0x30b4a3)break;else _0xde007['push'](_0xde007['shift']());}catch(_0x4bfbce){_0xde007['push'](_0xde007['shift']());}}}(a200_0x1650,0xbd7a3));function a200_0xa163(_0x9b2ef4,_0xde62da){_0x9b2ef4=_0x9b2ef4-0xde;const _0x16503f=a200_0x1650();let _0xa16312=_0x16503f[_0x9b2ef4];return _0xa16312;}function a200_0x1650(){const _0x4ea58e=['3rMxiWZ','1527098UHAxOR','custom-detail','padStart','getMinutes','getTime','12642930cuwcgX','getHours','trim','5341896tqQqGZ','appCode','appcode','Retrieved\x20Custom\x20Page\x20','join','isNaN','str','pageCode','10676526AphNza','getFullYear','getMonth','4080KRDFUx','cookie','number','read','compress','8165392WKFEct','4970xFdRXV','page','1123718NERXEL'];a200_0x1650=function(){return _0x4ea58e;};return a200_0x1650();}import{getCustomPageSource}from'../../../core/api-client.js';import{buildCustomPageEditUrl,buildCustomPageRuntimeUrl,readCustomPageId,CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL,resolveCustomPageDevelopmentUrl}from'./shared.js';export const pageCustomDetail={'service':a200_0x35128d(0xeb),'command':a200_0x35128d(0xef),'description':'Show\x20a\x20Custom\x20Page\x20and\x20all\x20of\x20its\x20files','risk':a200_0x35128d(0xe7),'defaultOutputFormat':a200_0x35128d(0xe8),'structuredErrors':!![],'requiresAppCode':![],'flags':[{'name':'id','type':a200_0x35128d(0xe6),'required':!![],'description':'Custom\x20Page\x20ID'},CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL],async 'validate'(_0x2d1a1b){readCustomPageId(_0x2d1a1b);},async 'execute'(_0x38aa55){const _0x1772af=a200_0x35128d,_0x1e4afa=readCustomPageId(_0x38aa55),_0x29bb66=await getCustomPageSource(_0x1e4afa),{bundle:_0x4ebd62,createTime:_0x172714,updateTime:_0x4b2337,..._0x8698a}=_0x29bb66,_0x3885c4=_0x29bb66['id']??_0x1e4afa,_0x57f3b5=_0x29bb66[_0x1772af(0xf7)]?.['trim']()||_0x38aa55[_0x1772af(0xdf)](_0x1772af(0xf8))[_0x1772af(0xf5)](),_0x55d3e1=buildCustomPageRuntimeUrl(_0x57f3b5,_0x29bb66[_0x1772af(0xe0)]),_0x20f17d=buildCustomPageEditUrl(_0x57f3b5,_0x3885c4),_0x28824c=await resolveCustomPageDevelopmentUrl(_0x57f3b5,_0x3885c4,_0x38aa55[_0x1772af(0xe5)]);return{'ok':!![],'data':{..._0x8698a,..._0x55d3e1?{'runtimePageUrl':_0x55d3e1}:{},..._0x28824c?{'pageUrl':_0x28824c}:{},..._0x20f17d?{'editPageUrl':_0x20f17d}:{},..._0x172714==null?{}:{'createTime':formatTime(_0x172714)},..._0x4b2337==null?{}:{'updateTime':formatTime(_0x4b2337)}},'message':_0x1772af(0xf9)+_0x1e4afa+'.'};}};function formatTime(_0x32845c){const _0x3742e4=a200_0x35128d,_0x286777=new Date(_0x32845c);if(Number[_0x3742e4(0xde)](_0x286777[_0x3742e4(0xf2)]()))return String(_0x32845c);const _0x33e042=[_0x286777[_0x3742e4(0xe2)](),String(_0x286777[_0x3742e4(0xe3)]()+0x1)[_0x3742e4(0xf0)](0x2,'0'),String(_0x286777['getDate']())[_0x3742e4(0xf0)](0x2,'0')]['join']('-'),_0x1e7e61=[String(_0x286777[_0x3742e4(0xf4)]())[_0x3742e4(0xf0)](0x2,'0'),String(_0x286777[_0x3742e4(0xf1)]())['padStart'](0x2,'0'),String(_0x286777['getSeconds']())[_0x3742e4(0xf0)](0x2,'0')][_0x3742e4(0xfa)](':');return _0x33e042+'\x20'+_0x1e7e61;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a201_0x50be9f=a201_0x3ff6;function a201_0x3ff6(_0x523c81,_0x5d9c37){_0x523c81=_0x523c81-0x65;const _0x5edb00=a201_0x5edb();let _0x3ff6a5=_0x5edb00[_0x523c81];return _0x3ff6a5;}(function(_0x430e82,_0x6c7da1){const _0x204a41=a201_0x3ff6,_0x396a4d=_0x430e82();while(!![]){try{const _0xd4e123=parseInt(_0x204a41(0x6b))/0x1+parseInt(_0x204a41(0x75))/0x2*(parseInt(_0x204a41(0x65))/0x3)+-parseInt(_0x204a41(0x7a))/0x4*(parseInt(_0x204a41(0x76))/0x5)+-parseInt(_0x204a41(0x7c))/0x6+parseInt(_0x204a41(0x71))/0x7+-parseInt(_0x204a41(0x69))/0x8*(-parseInt(_0x204a41(0x68))/0x9)+-parseInt(_0x204a41(0x6e))/0xa*(parseInt(_0x204a41(0x77))/0xb);if(_0xd4e123===_0x6c7da1)break;else _0x396a4d['push'](_0x396a4d['shift']());}catch(_0x242bc9){_0x396a4d['push'](_0x396a4d['shift']());}}}(a201_0x5edb,0x57add));import{APPCODE_FLAG_OPTIONAL}from'../../../commands/common/flags.js';import{fetchMenuSnapshot}from'../../../commands/menu/shared/facts.js';import{buildCustomPageDevelopmentUrl,buildCustomPageEditUrl,buildCustomPageRuntimeUrl}from'./shared.js';function a201_0x5edb(){const _0x40b4f7=['715wsNuOy','1157288GHRySM','List\x20Custom\x20Pages\x20in\x20the\x20current\x20app','cookie','10548NjMqbl','custom-list','1291008NrWkDc','page','39dIJQfN','No\x20Custom\x20Pages\x20found.','Found\x20','549QsMbip','9416UUDhFs','\x20Custom\x20Page(s).','612274MSwIHa','compress','flatMap','40AVmPOY','path','appCode','685944lYPbpC','label','length','pageId','90794ziSvIw'];a201_0x5edb=function(){return _0x40b4f7;};return a201_0x5edb();}export const pageCustomList={'service':a201_0x50be9f(0x7d),'command':a201_0x50be9f(0x7b),'description':a201_0x50be9f(0x78),'risk':'read','defaultOutputFormat':a201_0x50be9f(0x6c),'structuredErrors':!![],'flags':[APPCODE_FLAG_OPTIONAL],async 'execute'(_0x401a14){const _0x3886fd=a201_0x50be9f,_0x109ae8=(await fetchMenuSnapshot(_0x401a14[_0x3886fd(0x70)],_0x401a14[_0x3886fd(0x79)]))['menus'][_0x3886fd(0x6d)](_0x1bdfb4=>{const _0x38f1ca=_0x3886fd;if(_0x1bdfb4['type']!=='react'||_0x1bdfb4['pageId']==null)return[];const _0x36d13f=buildCustomPageDevelopmentUrl(_0x401a14[_0x38f1ca(0x70)],_0x1bdfb4[_0x38f1ca(0x6f)]),_0x5cb8fd=buildCustomPageRuntimeUrl(_0x401a14['appCode'],_0x1bdfb4[_0x38f1ca(0x6f)]),_0x365e9b=buildCustomPageEditUrl(_0x401a14['appCode'],_0x1bdfb4['pageId']);return[{'pageId':_0x1bdfb4[_0x38f1ca(0x74)],'label':_0x1bdfb4[_0x38f1ca(0x72)],'path':_0x1bdfb4['path'],..._0x36d13f?{'pageUrl':_0x36d13f}:{},..._0x5cb8fd?{'runtimePageUrl':_0x5cb8fd}:{},..._0x365e9b?{'editPageUrl':_0x365e9b}:{}}];});return{'ok':!![],'data':{'pages':_0x109ae8},'message':_0x109ae8[_0x3886fd(0x73)]===0x0?_0x3886fd(0x66):_0x3886fd(0x67)+_0x109ae8['length']+_0x3886fd(0x6a)};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a202_0x50f0(){const _0x58e0eb=['Published\x20successfully,\x20but\x20a\x20link\x20to\x20the\x20published\x20page\x20could\x20not\x20be\x20generated.','300760Iwyxnb','push','cookie','Published\x20Custom\x20Page\x20','appCode','Publish\x20the\x20latest\x20saved\x20content\x20of\x20a\x20Custom\x20Page','unknown','4128840hoqOfw','write','isInteger','5096970XkEnaS','str','821170DqoIXF','210186ZThqVr','pageId','status','page.custom-publish','runtimePageUrl','27vbJcYi','40NoVMaX','warnings','trim','POST','string','Would\x20publish\x20Custom\x20Page\x20','FORMAL','Custom\x20Page\x20publish\x20did\x20not\x20return\x20the\x20expected\x20page\x20ID.','24ogAjTH','apiError','Custom\x20Page\x20publish\x20did\x20not\x20reach\x20published\x20status:\x20','522564BWOJWr','386735MoJmfq','remark'];a202_0x50f0=function(){return _0x58e0eb;};return a202_0x50f0();}function a202_0x3737(_0x4afa9a,_0x3cd088){_0x4afa9a=_0x4afa9a-0x1d9;const _0x50f001=a202_0x50f0();let _0x3737b6=_0x50f001[_0x4afa9a];return _0x3737b6;}const a202_0x1f8d43=a202_0x3737;(function(_0x2823fd,_0x3f2b5e){const _0x403bdb=a202_0x3737,_0x171dc3=_0x2823fd();while(!![]){try{const _0x49d0f8=parseInt(_0x403bdb(0x1e9))/0x1+-parseInt(_0x403bdb(0x1e8))/0x2+-parseInt(_0x403bdb(0x1ee))/0x3*(parseInt(_0x403bdb(0x1dc))/0x4)+parseInt(_0x403bdb(0x1d9))/0x5*(-parseInt(_0x403bdb(0x1f7))/0x6)+-parseInt(_0x403bdb(0x1fa))/0x7+-parseInt(_0x403bdb(0x1e3))/0x8+-parseInt(_0x403bdb(0x1e6))/0x9*(-parseInt(_0x403bdb(0x1ef))/0xa);if(_0x49d0f8===_0x3f2b5e)break;else _0x171dc3['push'](_0x171dc3['shift']());}catch(_0x358e2f){_0x171dc3['push'](_0x171dc3['shift']());}}}(a202_0x50f0,0x77282));import{getCustomPageSource,publishCustomPage}from'../../../core/api-client.js';import{CliErrors}from'../../../errors.js';import{buildCustomPageEditUrl,buildCustomPageRuntimeUrl,readCustomPageId,resolveCustomPageDevelopmentUrl}from'./shared.js';export const pageCustomPublish={'service':'page','command':'custom-publish','description':a202_0x1f8d43(0x1e1),'risk':a202_0x1f8d43(0x1e4),'defaultOutputFormat':'compress','structuredErrors':!![],'requiresAppCode':![],'flags':[{'name':'id','type':'number','required':!![],'description':'Custom\x20Page\x20ID'},{'name':a202_0x1f8d43(0x1da),'type':a202_0x1f8d43(0x1f3),'description':'Optional\x20publish\x20remark'}],async 'validate'(_0x57fe16){readCustomPageId(_0x57fe16);},async 'dryRun'(_0x38525f){const _0x35b45a=a202_0x1f8d43,_0x4add17=readInput(_0x38525f);return{'method':_0x35b45a(0x1f2),'url':'/smartapi/webcode/file/publish','body':{'id':_0x4add17[_0x35b45a(0x1ea)],..._0x4add17[_0x35b45a(0x1da)]?{'remark':_0x4add17[_0x35b45a(0x1da)]}:{}},'description':_0x35b45a(0x1f4)+_0x4add17[_0x35b45a(0x1ea)]+'.'};},async 'execute'(_0x283999){const _0x3c36a7=a202_0x1f8d43,_0x54bfc9=readInput(_0x283999);await getCustomPageSource(_0x54bfc9[_0x3c36a7(0x1ea)]);const _0x49390f=await publishCustomPage(_0x54bfc9);if(!Number[_0x3c36a7(0x1e5)](_0x49390f)||_0x49390f!==_0x54bfc9['pageId'])throw CliErrors[_0x3c36a7(0x1f8)](_0x3c36a7(0x1f6));const _0x420bb9=await getCustomPageSource(_0x54bfc9[_0x3c36a7(0x1ea)]);if(_0x420bb9['status']!==_0x3c36a7(0x1f5))throw CliErrors[_0x3c36a7(0x1f8)](_0x3c36a7(0x1f9)+(_0x420bb9[_0x3c36a7(0x1eb)]??_0x3c36a7(0x1e2))+'.');const _0x12f276=_0x420bb9[_0x3c36a7(0x1e0)]?.[_0x3c36a7(0x1f1)](),_0x4d1065=buildCustomPageEditUrl(_0x12f276,_0x54bfc9[_0x3c36a7(0x1ea)]),_0x110cfb=await resolveCustomPageDevelopmentUrl(_0x12f276,_0x54bfc9[_0x3c36a7(0x1ea)],_0x283999[_0x3c36a7(0x1de)]),_0xcda7a4=buildMutationData(_0x54bfc9,!![],_0x110cfb,_0x4d1065);_0x12f276&&!_0x110cfb&&_0xcda7a4[_0x3c36a7(0x1f0)][_0x3c36a7(0x1dd)]('Published\x20successfully,\x20but\x20a\x20link\x20to\x20the\x20latest\x20saved\x20content\x20could\x20not\x20be\x20generated.');const _0x38b398=buildCustomPageRuntimeUrl(_0x420bb9[_0x3c36a7(0x1e0)],_0x420bb9['pageCode']);return _0x38b398?_0xcda7a4[_0x3c36a7(0x1ed)]=_0x38b398:_0xcda7a4[_0x3c36a7(0x1f0)][_0x3c36a7(0x1dd)](_0x3c36a7(0x1db)),{'ok':!![],'data':_0xcda7a4,'message':_0x3c36a7(0x1df)+_0x54bfc9['pageId']+'.'};}};function readInput(_0x4a9b7d){const _0xd177b9=a202_0x1f8d43,_0x557f36=readCustomPageId(_0x4a9b7d),_0x1f0eb8=_0x4a9b7d[_0xd177b9(0x1e7)](_0xd177b9(0x1da))[_0xd177b9(0x1f1)]();return{'pageId':_0x557f36,..._0x1f0eb8?{'remark':_0x1f0eb8}:{}};}function buildMutationData(_0x431753,_0x40b837=![],_0x568cae,_0x2c9f1b){const _0xae7502=a202_0x1f8d43;return{'operation':_0xae7502(0x1ec),'selector':{'pageId':_0x431753[_0xae7502(0x1ea)]},'before':null,'after':{'pageId':_0x431753['pageId'],'status':_0xae7502(0x1f5)},'dryRun':!_0x40b837,'request':_0x431753,..._0x568cae?{'pageUrl':_0x568cae}:{},..._0x2c9f1b?{'editPageUrl':_0x2c9f1b}:{},'warnings':[]};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
const a203_0x25ce54=a203_0xeaa7;(function(_0x5d5a03,_0x21b481){const _0x504d12=a203_0xeaa7,_0x52255e=_0x5d5a03();while(!![]){try{const _0x3edb36=parseInt(_0x504d12(0x9e))/0x1+parseInt(_0x504d12(0xa1))/0x2+parseInt(_0x504d12(0xa6))/0x3*(-parseInt(_0x504d12(0x9d))/0x4)+parseInt(_0x504d12(0x9c))/0x5+-parseInt(_0x504d12(0x9b))/0x6+-parseInt(_0x504d12(0xa3))/0x7*(-parseInt(_0x504d12(0xa5))/0x8)+-parseInt(_0x504d12(0xad))/0x9;if(_0x3edb36===_0x21b481)break;else _0x52255e['push'](_0x52255e['shift']());}catch(_0x10b0b3){_0x52255e['push'](_0x52255e['shift']());}}}(a203_0x465e,0x55aa8));import{APPCODE_FLAG_OPTIONAL}from'../../../commands/common/flags.js';import{fetchMenuSnapshot}from'../../../commands/menu/shared/facts.js';import{getAppBaseUrl,getPublishedAppDomain}from'../../../constant/domain.js';import{CliErrors}from'../../../errors.js';import{validateCustomPageSourceFiles}from'./syntax.js';export const CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL={...APPCODE_FLAG_OPTIONAL,'description':a203_0x25ce54(0x97)};function trimOptional(_0xa70595){const _0x10f7c2=a203_0x25ce54;return _0xa70595?.[_0x10f7c2(0x95)]()||undefined;}export function buildCustomPageRuntimeUrl(_0x4ecf2c,_0x3a69f4){const _0x555f7f=trimOptional(_0x4ecf2c),_0x4975fa=trimOptional(_0x3a69f4);if(!_0x555f7f||!_0x4975fa)return undefined;return getPublishedAppDomain(_0x555f7f)+'/'+encodeURIComponent(_0x4975fa);}export function buildCustomPageDevelopmentUrl(_0x39ebde,_0x677216){const _0x235ae3=a203_0x25ce54,_0x4ed056=trimOptional(_0x39ebde),_0x450ab7=trimOptional(_0x677216);if(!_0x4ed056||!_0x450ab7)return undefined;return getAppBaseUrl(_0x4ed056)+_0x235ae3(0xa7)+encodeURIComponent(_0x450ab7);}export async function resolveCustomPageDevelopmentUrl(_0x33b0bf,_0x5f5c82,_0x446a6a){const _0x575527=a203_0x25ce54,_0x20e5bf=trimOptional(_0x33b0bf);if(!_0x20e5bf)return undefined;try{const _0x81a4c=(await fetchMenuSnapshot(_0x20e5bf,_0x446a6a))['menus'][_0x575527(0x9a)](_0x5c346c=>_0x5c346c['type']==='react'&&_0x5c346c['pageId']===_0x5f5c82);return buildCustomPageDevelopmentUrl(_0x20e5bf,_0x81a4c?.[_0x575527(0xab)]);}catch{return undefined;}}export function buildCustomPageEditUrl(_0x48d1a0,_0x413bfb){const _0x19dfd8=a203_0x25ce54,_0x447c0b=trimOptional(_0x48d1a0);if(!_0x447c0b)return;const _0x1184c1=trimOptional(String(_0x413bfb??''));if(!_0x1184c1)return;return getAppBaseUrl(_0x447c0b)+_0x19dfd8(0x99)+encodeURIComponent(_0x1184c1);}export async function validateCustomPageContent(_0x5c704f){const _0x46a164=a203_0x25ce54,_0x200da9=await validateCustomPageSourceFiles(_0x5c704f);if(_0x200da9[_0x46a164(0xa9)]>0x0)throw CliErrors[_0x46a164(0xa0)](_0x46a164(0x9f)+_0x200da9[_0x46a164(0xa2)](_0x1ead50=>_0x1ead50[_0x46a164(0xa8)]+':\x20'+_0x1ead50[_0x46a164(0xac)])[_0x46a164(0x96)](';\x20'));}export function readCustomPageId(_0x5d476b){const _0x3b1d29=a203_0x25ce54,_0x2ef4ca=_0x5d476b[_0x3b1d29(0xaa)]('id');if(!Number[_0x3b1d29(0xa4)](_0x2ef4ca)||_0x2ef4ca<=0x0)throw CliErrors[_0x3b1d29(0xa0)](_0x3b1d29(0x98));return _0x2ef4ca;}function a203_0xeaa7(_0x3fafd9,_0x260f29){_0x3fafd9=_0x3fafd9-0x95;const _0x465eca=a203_0x465e();let _0xeaa73=_0x465eca[_0x3fafd9];return _0xeaa73;}function a203_0x465e(){const _0x1c646d=['validation','1321038xGFleK','map','7KnjUSN','isInteger','616024TXCIrC','6Bqnmnr','/pages/','file','length','num','path','message','6796998vQkiAM','trim','join','Optional\x20app\x20code\x20resolved\x20from\x20page\x20ID\x20when\x20omitted','--id\x20must\x20be\x20a\x20positive\x20integer.','/ide/','find','242568OjFXkJ','1151255pyaSkc','867448lrATgI','612489nJdoHT','Invalid\x20Custom\x20Page\x20content:\x20'];a203_0x465e=function(){return _0x1c646d;};return a203_0x465e();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a204_0x37952d=a204_0x3b16;(function(_0x385af3,_0x2c91db){const _0x500eba=a204_0x3b16,_0x550c27=_0x385af3();while(!![]){try{const _0x53a656=-parseInt(_0x500eba(0xb3))/0x1*(parseInt(_0x500eba(0xc9))/0x2)+parseInt(_0x500eba(0xc7))/0x3*(-parseInt(_0x500eba(0xc0))/0x4)+-parseInt(_0x500eba(0xc5))/0x5*(-parseInt(_0x500eba(0xba))/0x6)+-parseInt(_0x500eba(0xbc))/0x7+-parseInt(_0x500eba(0xb2))/0x8*(parseInt(_0x500eba(0xc6))/0x9)+-parseInt(_0x500eba(0xc8))/0xa+parseInt(_0x500eba(0xc3))/0xb*(parseInt(_0x500eba(0xb6))/0xc);if(_0x53a656===_0x2c91db)break;else _0x550c27['push'](_0x550c27['shift']());}catch(_0x4c1286){_0x550c27['push'](_0x550c27['shift']());}}}(a204_0x4374,0x756a2));import{format}from'prettier';function a204_0x4374(){const _0x4caa08=['find','entries','1039884Cpwgth','trim','message','filter','6bkJKsC','babel','4138666lpbfZM','typescript','endsWith','.tsx','4UnYoWy','toLowerCase','Missing\x20React\x20source\x20file\x20with\x20extension\x20.jsx\x20or\x20.tsx','429VZkJfv','some','983835BqgAMr','18HsTZnt','1142709CfRtjE','4268910aHXNOk','11996iWOnTl','3018968itjoKc','157HmPEUR'];a204_0x4374=function(){return _0x4caa08;};return a204_0x4374();}function a204_0x3b16(_0x536597,_0x1327e5){_0x536597=_0x536597-0xb2;const _0x437447=a204_0x4374();let _0x3b165e=_0x437447[_0x536597];return _0x3b165e;}const SOURCE_PARSERS={'.js':'babel','.jsx':a204_0x37952d(0xbb),'.ts':'typescript','.tsx':a204_0x37952d(0xbd)},CUSTOM_PAGE_EXTENSIONS=['.jsx',a204_0x37952d(0xbf)];export async function validateCustomPageSourceFiles(_0x462d56){const _0x34da1e=a204_0x37952d,_0x188f50=Object[_0x34da1e(0xb5)](_0x462d56)[_0x34da1e(0xb9)](([_0x5c6bb7])=>getParser(_0x5c6bb7));if(!_0x188f50[_0x34da1e(0xc4)](([_0x30e1c9])=>isReactSourceFile(_0x30e1c9)))return[{'file':'page\x20files','message':_0x34da1e(0xc2)}];const _0xc08163=await Promise['all'](_0x188f50['map'](async([_0x3448af,_0xd3bd41])=>{const _0x251399=_0x34da1e;try{return await format(_0xd3bd41,{'parser':getParser(_0x3448af)}),undefined;}catch(_0x5e4162){return{'file':_0x3448af,'message':_0x5e4162 instanceof Error?_0x5e4162[_0x251399(0xb8)]:String(_0x5e4162)};}}));return _0xc08163[_0x34da1e(0xb9)](_0x372de9=>_0x372de9!==undefined);}function getParser(_0x3d8235){const _0x117093=a204_0x37952d,_0x553454=_0x3d8235[_0x117093(0xb7)]()[_0x117093(0xc1)]();return Object[_0x117093(0xb5)](SOURCE_PARSERS)[_0x117093(0xb4)](([_0x1ec901])=>_0x553454['endsWith'](_0x1ec901))?.[0x1];}function isReactSourceFile(_0x5607cf){const _0xc53873=a204_0x37952d,_0x21792c=_0x5607cf[_0xc53873(0xb7)]()['toLowerCase']();return CUSTOM_PAGE_EXTENSIONS[_0xc53873(0xc4)](_0x2f909b=>_0x21792c[_0xc53873(0xbe)](_0x2f909b));}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a205_0x23e7d9=a205_0x347c;(function(_0x1fab8d,_0x306d03){const _0x2270dd=a205_0x347c,_0x3a13e1=_0x1fab8d();while(!![]){try{const _0x1ae9d6=parseInt(_0x2270dd(0x143))/0x1*(parseInt(_0x2270dd(0x12d))/0x2)+parseInt(_0x2270dd(0x136))/0x3+-parseInt(_0x2270dd(0x125))/0x4*(parseInt(_0x2270dd(0x123))/0x5)+parseInt(_0x2270dd(0x121))/0x6+parseInt(_0x2270dd(0x142))/0x7*(-parseInt(_0x2270dd(0x12b))/0x8)+-parseInt(_0x2270dd(0x139))/0x9+parseInt(_0x2270dd(0x122))/0xa;if(_0x1ae9d6===_0x306d03)break;else _0x3a13e1['push'](_0x3a13e1['shift']());}catch(_0xf799ae){_0x3a13e1['push'](_0x3a13e1['shift']());}}}(a205_0x438a,0x8a50b));import{getCustomPageSource,updateCustomPageContent}from'../../../core/api-client.js';function a205_0x347c(_0x7a65a5,_0x5725d8){_0x7a65a5=_0x7a65a5-0x11f;const _0x438a71=a205_0x438a();let _0x347c34=_0x438a71[_0x7a65a5];return _0x347c34;}import{readCustomPageDirectory}from'../../../core/page/file-system.js';import{CliErrors}from'../../../errors.js';import{buildCustomPageEditUrl,resolveCustomPageDevelopmentUrl,readCustomPageId,CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL,validateCustomPageContent}from'./shared.js';export const pageCustomUpdate={'service':a205_0x23e7d9(0x128),'command':a205_0x23e7d9(0x13a),'description':'Save\x20all\x20files\x20of\x20a\x20Custom\x20Page','risk':a205_0x23e7d9(0x120),'defaultOutputFormat':a205_0x23e7d9(0x133),'structuredErrors':!![],'requiresAppCode':![],'rejectedFlags':[{'name':a205_0x23e7d9(0x12a),'message':a205_0x23e7d9(0x135),'hint':a205_0x23e7d9(0x130)}],'flags':[{'name':'id','type':a205_0x23e7d9(0x131),'required':!![],'description':'Custom\x20Page\x20ID'},{'name':'page-dir','type':'string','required':!![],'description':'Directory\x20containing\x20all\x20complete\x20page\x20files'},CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL],async 'validate'(_0x5ad729){readCustomPageId(_0x5ad729),await readValidatedPageContent(_0x5ad729);},async 'dryRun'(_0x1f0a3c){const _0x18decf=a205_0x23e7d9,_0x4208f2=await readInput(_0x1f0a3c);return{'method':_0x18decf(0x138),'url':_0x18decf(0x13d),'body':{'id':_0x4208f2['pageId'],'codeContent':_0x4208f2[_0x18decf(0x12f)]},'description':_0x18decf(0x13e)+_0x4208f2[_0x18decf(0x12c)]+'.'};},async 'execute'(_0x5710d5){const _0x1f147a=a205_0x23e7d9,_0x527540=await readInput(_0x5710d5),_0x1e9106=await updateCustomPageContent({'pageId':_0x527540[_0x1f147a(0x12c)],'pageContent':_0x527540[_0x1f147a(0x12f)]});if(!Number[_0x1f147a(0x13b)](_0x1e9106[_0x1f147a(0x11f)])||_0x1e9106[_0x1f147a(0x11f)]<=0x0)throw CliErrors[_0x1f147a(0x141)](_0x1f147a(0x126));const _0x306114=buildCustomPageEditUrl(_0x527540[_0x1f147a(0x144)],_0x527540[_0x1f147a(0x12c)]),_0xe10807=await resolveCustomPageDevelopmentUrl(_0x527540[_0x1f147a(0x144)],_0x527540['pageId'],_0x5710d5[_0x1f147a(0x124)]);return{'ok':!![],'data':{'operation':_0x1f147a(0x140),'selector':{'appCode':_0x527540[_0x1f147a(0x144)],'pageId':_0x527540[_0x1f147a(0x12c)]},'before':null,'after':{'pageId':_0x1e9106['pageId'],'version':_0x1e9106[_0x1f147a(0x11f)],'pageContent':_0x527540[_0x1f147a(0x12f)]},'dryRun':![],'request':_0x527540,..._0xe10807?{'pageUrl':_0xe10807}:{},..._0x306114?{'editPageUrl':_0x306114}:{},'warnings':_0xe10807?[]:[_0x1f147a(0x137)]},'message':_0x1f147a(0x13f)+_0x527540[_0x1f147a(0x12c)]+'.'};}};function a205_0x438a(){const _0x24c65e=['29141vuKSzV','appCode','newVersion','write','6338196bEOfrW','1338060gECUpZ','5SVhXWe','cookie','2360508rUrIvD','Custom\x20Page\x20update\x20did\x20not\x20create\x20a\x20new\x20version.','trim','page','validation','page-content','8065128ZBeqYa','pageId','30ceyAWb','Cannot\x20determine\x20the\x20appCode\x20for\x20Custom\x20Page\x20','pageContent','Write\x20the\x20complete\x20page\x20files\x20to\x20a\x20local\x20directory\x20and\x20use\x20--page-dir\x20<dir>.','number','appcode','compress','str','page\x20custom-update\x20no\x20longer\x20accepts\x20--page-content.','3361551ZoILUQ','Custom\x20Page\x20was\x20updated,\x20but\x20a\x20link\x20to\x20its\x20latest\x20saved\x20content\x20could\x20not\x20be\x20generated.','POST','5246973XuIsrJ','custom-update','isInteger','page-dir','/smartapi/webcode/page/update/content','Would\x20save\x20all\x20files\x20of\x20Custom\x20Page\x20','Updated\x20Custom\x20Page\x20','page.custom-update','apiError','7OTDEuG'];a205_0x438a=function(){return _0x24c65e;};return a205_0x438a();}async function readInput(_0x14b7f9){const _0x311da0=a205_0x23e7d9,_0x5a509c=readCustomPageId(_0x14b7f9),_0x4779ee=_0x14b7f9[_0x311da0(0x134)](_0x311da0(0x132))[_0x311da0(0x127)]()||(await getCustomPageSource(_0x5a509c))[_0x311da0(0x144)]?.[_0x311da0(0x127)]();if(!_0x4779ee)throw CliErrors[_0x311da0(0x129)](_0x311da0(0x12e)+_0x5a509c+'.');return{'appCode':_0x4779ee,'pageId':_0x5a509c,'pageContent':await readValidatedPageContent(_0x14b7f9)};}async function readValidatedPageContent(_0xa1a7ed){const _0x255ba1=a205_0x23e7d9,_0x591f2f=await readCustomPageDirectory(_0xa1a7ed[_0x255ba1(0x134)](_0x255ba1(0x13c)));return await validateCustomPageContent(_0x591f2f),_0x591f2f;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a206_0x8367(_0x489a3a,_0x2b1f49){_0x489a3a=_0x489a3a-0x192;const _0x369621=a206_0x3696();let _0x8367a1=_0x369621[_0x489a3a];return _0x8367a1;}const a206_0x4eb17d=a206_0x8367;(function(_0x4e29e1,_0x2b1c47){const _0x3d1c49=a206_0x8367,_0x27401e=_0x4e29e1();while(!![]){try{const _0x50da10=parseInt(_0x3d1c49(0x1ab))/0x1+-parseInt(_0x3d1c49(0x197))/0x2+parseInt(_0x3d1c49(0x19c))/0x3*(-parseInt(_0x3d1c49(0x1a7))/0x4)+-parseInt(_0x3d1c49(0x1a9))/0x5*(-parseInt(_0x3d1c49(0x1aa))/0x6)+-parseInt(_0x3d1c49(0x1a8))/0x7*(-parseInt(_0x3d1c49(0x1a6))/0x8)+parseInt(_0x3d1c49(0x19d))/0x9*(-parseInt(_0x3d1c49(0x193))/0xa)+parseInt(_0x3d1c49(0x198))/0xb;if(_0x50da10===_0x2b1c47)break;else _0x27401e['push'](_0x27401e['shift']());}catch(_0x11bebf){_0x27401e['push'](_0x27401e['shift']());}}}(a206_0x3696,0x2688a));import{APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{assessDataListPageState,getUndeletedRelatedPages,loadDatasetDetailForPage,loadDataListPageStatusForGenerate,serializeDryRunDescription,validateDatasetSelector}from'../../commands/page/shared.js';export const pageDataListStatus={'service':a206_0x4eb17d(0x1a1),'command':'data-list-status','description':a206_0x4eb17d(0x1a2),'risk':a206_0x4eb17d(0x19b),'defaultOutputFormat':'compress','flags':[APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL,{'name':a206_0x4eb17d(0x19f),'type':a206_0x4eb17d(0x199),'description':a206_0x4eb17d(0x1a5)}],async 'validate'(_0x4fd382){validateDatasetSelector(_0x4fd382);},async 'dryRun'(_0x1cbc38){const _0x50e440=a206_0x4eb17d,_0x218f23=await loadDatasetDetailForPage(_0x1cbc38);return{'method':'GET','url':_0x50e440(0x1a3)+_0x218f23['code']+'/standard-page-status?appCode='+encodeURIComponent(_0x1cbc38[_0x50e440(0x1ac)]),'description':serializeDryRunDescription({'dataset':{'id':_0x218f23['id'],'code':_0x218f23['code'],'name':_0x218f23['name']},'action':_0x50e440(0x1a4)})};},async 'execute'(_0x43d178){const _0xbecd44=a206_0x4eb17d,_0x486f06=await loadDatasetDetailForPage(_0x43d178),_0x2ec14d=await loadDataListPageStatusForGenerate(_0x43d178,_0x486f06[_0xbecd44(0x19e)]),_0x5329b4=getUndeletedRelatedPages(_0x486f06),_0x414b4f=assessDataListPageState(_0x486f06['code'],_0x2ec14d,{'fallbackUndeletedPages':_0x5329b4});return{'ok':!![],'data':{'datasetCode':_0x486f06[_0xbecd44(0x19e)],'precheckSource':_0x2ec14d?.[_0xbecd44(0x192)]??_0xbecd44(0x1a0),'status':_0x414b4f[_0xbecd44(0x194)],'manualResolutionRequired':_0x414b4f[_0xbecd44(0x196)],'nextAction':_0x414b4f[_0xbecd44(0x195)],'dataListPageStatus':_0x2ec14d,'relatedPages':{'total':_0x486f06['relatedPages'][_0xbecd44(0x19a)],'undeletedCount':_0x5329b4[_0xbecd44(0x19a)]}}};}};function a206_0x3696(){const _0x502ac1=['403572qtkNOp','4365141AXfrVy','string','length','read','445017GSmlnD','754497AieBUN','code','alias','related-pages-fallback','page','Query\x20Data\x20List\x20Page\x20facts\x20for\x20a\x20dataset','/smartapi/lovrabet/dataset/','query-data-list-status','Dataset\x20alias\x20from\x20api.ts\x20(resolves\x20to\x20dataset\x20code\x20automatically)','547704hxbsTm','8QcQZpu','7yUkbwP','1041305VTaWzk','6abQJub','66576tWKScc','appCode','source','10eHKAlx','status','nextAction','manualResolutionRequired'];a206_0x3696=function(){return _0x502ac1;};return a206_0x3696();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
function a207_0x4578(){const _0x3c0654=['/generate-standard-pages/start','141690aruiWk','344nCsxBX','DATA_LIST\x20currently\x20has\x20one\x20fixed\x20pattern:\x20CRUD_PAGE_SET.','This\x20command\x20always\x20generates\x20a\x20DATA_LIST\x20page\x20from\x20a\x20dataset.','211841oVUTzd','dryRun','bool','nextAction','name','page\x20generate-start\x20does\x20not\x20accept\x20--page-pattern.','progressRate','string','dataset','related-pages-fallback','/smartapi/lovrabet/dataset/','2097tsrXYC','code','Actually\x20execute\x20the\x20generation.\x20Without\x20this\x20flag,\x20only\x20a\x20dry-run\x20preview\x20is\x20shown.','reused','3100638oIKNnu','apply','Dataset\x20alias\x20from\x20api.ts\x20(resolves\x20to\x20dataset\x20code\x20automatically)','manualResolutionRequired','3477980aworkW','page\x20generate-start\x20does\x20not\x20accept\x20--page-type.','DATA_LIST','precheck','alias','Dry-run\x20preview\x20(pass\x20--apply\x20to\x20execute\x20the\x20generation)','341194jToFto','write','operationId','number','page-pattern','boolean','clientOperationId','message','7731750MRaDjm','POST','taskId','196gxgrvz','appCode','generate-start','12732rnqOXk','CRUD_PAGE_SET','Reusing\x20an\x20existing\x20generate\x20task','PARTIAL_SUCCESS','Submitted\x20a\x20generate\x20task','page-type','status','dataListPageStatus'];a207_0x4578=function(){return _0x3c0654;};return a207_0x4578();}const a207_0x849b48=a207_0x25a6;function a207_0x25a6(_0x309262,_0x504ac3){_0x309262=_0x309262-0x1c0;const _0x457867=a207_0x4578();let _0x25a66b=_0x457867[_0x309262];return _0x25a66b;}(function(_0x2f041f,_0x4bedf1){const _0x5d29b1=a207_0x25a6,_0x31c885=_0x2f041f();while(!![]){try{const _0x3a6635=-parseInt(_0x5d29b1(0x1c0))/0x1+parseInt(_0x5d29b1(0x1ea))/0x2+parseInt(_0x5d29b1(0x1ce))/0x3*(-parseInt(_0x5d29b1(0x1cb))/0x4)+parseInt(_0x5d29b1(0x1ee))/0x5+parseInt(_0x5d29b1(0x1c8))/0x6+-parseInt(_0x5d29b1(0x1db))/0x7*(-parseInt(_0x5d29b1(0x1d8))/0x8)+-parseInt(_0x5d29b1(0x1e6))/0x9*(parseInt(_0x5d29b1(0x1d7))/0xa);if(_0x3a6635===_0x4bedf1)break;else _0x31c885['push'](_0x31c885['shift']());}catch(_0xf41a96){_0x31c885['push'](_0x31c885['shift']());}}}(a207_0x4578,0xf08ea));import{APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{assessGenerateOperationState,assessDataListPageState,buildPageGenerateOperationStatusQueryCommand,buildDataListPageStatusQueryCommand,createPageGenerateClientOperationId,getUndeletedRelatedPages,loadDatasetDetailForPage,loadDataListPageStatusForGenerate,serializeDryRunDescription,validateDatasetSelector}from'../../commands/page/shared.js';import{startGenerateDataListPages}from'../../core/api-client.js';export const pageGenerateStart={'service':'page','command':a207_0x849b48(0x1cd),'description':'Start\x20async\x20Data\x20List\x20Page\x20generation\x20from\x20a\x20dataset','risk':a207_0x849b48(0x1c1),'defaultOutputFormat':'compress','rejectedFlags':[{'name':a207_0x849b48(0x1d3),'message':a207_0x849b48(0x1ef),'hint':a207_0x849b48(0x1da)},{'name':a207_0x849b48(0x1c4),'message':a207_0x849b48(0x1e0),'hint':a207_0x849b48(0x1d9)}],'flags':[APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL,{'name':a207_0x849b48(0x1f2),'type':a207_0x849b48(0x1e2),'description':a207_0x849b48(0x1ec)},{'name':a207_0x849b48(0x1eb),'type':a207_0x849b48(0x1c5),'description':a207_0x849b48(0x1e8)}],async 'validate'(_0x16e9af){validateDatasetSelector(_0x16e9af);},async 'dryRun'(_0x2b069c){const _0x322460=a207_0x849b48,_0x1e8f09=await prepare(_0x2b069c);return{'method':_0x322460(0x1c9),'url':_0x322460(0x1e5)+_0x1e8f09[_0x322460(0x1e3)][_0x322460(0x1e7)]+_0x322460(0x1d6),'body':{'appCode':_0x2b069c[_0x322460(0x1cc)],'clientOperationId':_0x1e8f09[_0x322460(0x1c6)]},'description':serializeDryRunDescription({'dataset':{'id':_0x1e8f09[_0x322460(0x1e3)]['id'],'code':_0x1e8f09[_0x322460(0x1e3)][_0x322460(0x1e7)],'name':_0x1e8f09[_0x322460(0x1e3)][_0x322460(0x1df)],'fieldCount':_0x1e8f09[_0x322460(0x1e3)]['fieldCount']},'precheckSource':_0x1e8f09[_0x322460(0x1d5)]?.['source']??_0x322460(0x1e4),'action':_0x322460(0x1cd),'clientOperationId':_0x1e8f09['clientOperationId'],'plannedStatus':_0x1e8f09[_0x322460(0x1f1)][_0x322460(0x1d4)],'reason':_0x1e8f09[_0x322460(0x1f1)]['message']})};},async 'execute'(_0x528d97){const _0x40dff1=a207_0x849b48;if(!_0x528d97[_0x40dff1(0x1dd)]('apply')){const _0x224047=await pageGenerateStart[_0x40dff1(0x1dc)](_0x528d97);return{'ok':!![],'message':_0x40dff1(0x1f3),'data':_0x224047};}const _0xfef536=await prepare(_0x528d97);if(!_0xfef536[_0x40dff1(0x1f1)]['allowGenerate'])return{'ok':![],'message':_0xfef536[_0x40dff1(0x1f1)][_0x40dff1(0x1c7)],'data':{'datasetCode':_0xfef536[_0x40dff1(0x1e3)][_0x40dff1(0x1e7)],'pageType':_0x40dff1(0x1f0),'pagePattern':_0x40dff1(0x1cf),'clientOperationId':_0xfef536['clientOperationId'],'precheckSource':_0xfef536['dataListPageStatus']?.['source']??_0x40dff1(0x1e4),'status':_0xfef536[_0x40dff1(0x1f1)][_0x40dff1(0x1d4)],'manualResolutionRequired':_0xfef536['precheck'][_0x40dff1(0x1ed)],'nextAction':_0xfef536[_0x40dff1(0x1f1)][_0x40dff1(0x1de)],'query':{'command':buildDataListPageStatusQueryCommand(_0xfef536['dataset']['code'],_0x528d97[_0x40dff1(0x1cc)])},'dataListPageStatus':_0xfef536[_0x40dff1(0x1d5)]}};const _0x2cb3a8=await startGenerateDataListPages(_0x528d97[_0x40dff1(0x1cc)],_0xfef536[_0x40dff1(0x1e3)][_0x40dff1(0x1e7)],{'clientOperationId':_0xfef536[_0x40dff1(0x1c6)]}),_0x53ac27=_0x2cb3a8[_0x40dff1(0x1d4)]==='SUCCESS'||_0x2cb3a8['status']===_0x40dff1(0x1d1)?await loadDataListPageStatusForGenerate(_0x528d97,_0xfef536[_0x40dff1(0x1e3)][_0x40dff1(0x1e7)]):null,_0x47d8a7=assessGenerateOperationState(_0xfef536['dataset']['code'],_0x2cb3a8[_0x40dff1(0x1d4)],_0x53ac27);return{'ok':!![],'message':_0x2cb3a8[_0x40dff1(0x1e9)]?_0x40dff1(0x1d0):_0x40dff1(0x1d2),'data':{'datasetCode':_0xfef536[_0x40dff1(0x1e3)][_0x40dff1(0x1e7)],'appCode':_0x528d97['appCode'],'pageType':_0x40dff1(0x1f0),'pagePattern':_0x40dff1(0x1cf),'taskId':_0x2cb3a8[_0x40dff1(0x1ca)]??null,'operationId':_0x2cb3a8[_0x40dff1(0x1c2)]??null,'clientOperationId':_0xfef536[_0x40dff1(0x1c6)],'jobStatus':_0x2cb3a8[_0x40dff1(0x1d4)]??null,'progressRate':typeof _0x2cb3a8['progressRate']===_0x40dff1(0x1c3)?_0x2cb3a8[_0x40dff1(0x1e1)]:null,'currentStep':_0x2cb3a8['currentStep']??null,'reused':_0x2cb3a8[_0x40dff1(0x1e9)]===!![],'status':_0x47d8a7[_0x40dff1(0x1d4)],'manualResolutionRequired':_0x47d8a7['manualResolutionRequired'],'nextAction':_0x47d8a7[_0x40dff1(0x1de)],'query':{'command':buildPageGenerateOperationStatusQueryCommand(_0xfef536[_0x40dff1(0x1e3)][_0x40dff1(0x1e7)],{'appCode':_0x528d97[_0x40dff1(0x1cc)],'taskId':_0x2cb3a8[_0x40dff1(0x1ca)],'operationId':_0x2cb3a8[_0x40dff1(0x1c2)],'clientOperationId':_0xfef536[_0x40dff1(0x1c6)]})},'dataListPageStatus':_0x53ac27}};}};async function prepare(_0x2c0912){const _0x26f8d3=a207_0x849b48,_0x45d757=await loadDatasetDetailForPage(_0x2c0912),_0x166a9c=await loadDataListPageStatusForGenerate(_0x2c0912,_0x45d757[_0x26f8d3(0x1e7)]),_0x36f7e4=getUndeletedRelatedPages(_0x45d757);return{'dataset':_0x45d757,'dataListPageStatus':_0x166a9c,'clientOperationId':createPageGenerateClientOperationId(),'precheck':assessDataListPageState(_0x45d757['code'],_0x166a9c,{'fallbackUndeletedPages':_0x36f7e4})};}
|