@lovrabet/lovrabet-cli 2.3.1-beta.2 → 2.3.1-beta.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +53 -1
- package/lib/cli.js +1 -1
- package/lib/commands/api-doc/index.js +1 -1
- package/lib/commands/app/cache.js +1 -1
- package/lib/commands/app/definitions.js +1 -1
- package/lib/commands/app/eligibility.js +1 -1
- package/lib/commands/app/mock-loader.js +1 -1
- package/lib/commands/app/remote-source.js +1 -1
- package/lib/commands/app/shared.js +1 -1
- package/lib/commands/app-config/get.js +1 -1
- package/lib/commands/app-config/index.js +1 -1
- package/lib/commands/artifact/index.js +1 -1
- package/lib/commands/auth/device.js +1 -1
- package/lib/commands/auth/index.js +1 -1
- package/lib/commands/auth/prompt.js +1 -1
- package/lib/commands/bff/detail.js +1 -1
- package/lib/commands/bff/exec.js +1 -1
- package/lib/commands/bff/index.js +1 -1
- package/lib/commands/cli-skill/index.js +1 -1
- package/lib/commands/common/config-policy.js +1 -1
- package/lib/commands/common/constraints.js +1 -1
- package/lib/commands/common/flags.d.ts +2 -0
- package/lib/commands/common/flags.js +1 -1
- package/lib/commands/common/local-file.js +1 -1
- package/lib/commands/config/definitions.js +1 -1
- package/lib/commands/config/init.d.ts +2 -0
- package/lib/commands/config/init.js +1 -1
- package/lib/commands/config/shared.js +1 -1
- package/lib/commands/data/index.js +1 -1
- package/lib/commands/dataset/detail.js +1 -1
- package/lib/commands/dataset/index.js +1 -1
- package/lib/commands/dataset/list.js +1 -1
- package/lib/commands/dataset/sdk-doc.js +1 -1
- package/lib/commands/doctor.js +1 -1
- package/lib/commands/file/index.js +1 -1
- package/lib/commands/init.js +1 -1
- package/lib/commands/kb/index.js +1 -1
- package/lib/commands/logs/index.js +1 -1
- package/lib/commands/notification/config-list.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/permit/dataset-get.js +1 -1
- package/lib/commands/permit/dataset-set.js +1 -1
- package/lib/commands/permit/index.js +1 -1
- package/lib/commands/permit/page-get.js +1 -1
- package/lib/commands/permit/page-set.js +1 -1
- package/lib/commands/permit/role-menus-set.js +1 -1
- package/lib/commands/permit/role-menus.js +1 -1
- package/lib/commands/permit/shared.js +1 -1
- package/lib/commands/personal-bff/index.js +1 -1
- package/lib/commands/registry.js +1 -1
- package/lib/commands/role/create.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/schedule/index.js +1 -1
- package/lib/commands/schema.js +1 -1
- package/lib/commands/service/dynamic.js +1 -1
- package/lib/commands/service/function-name-adapter.js +1 -1
- package/lib/commands/service/index.js +1 -1
- package/lib/commands/service/registry.js +1 -1
- package/lib/commands/skill/commands/create.js +1 -1
- package/lib/commands/skill/commands/diagram.js +1 -1
- package/lib/commands/skill/commands/install.js +1 -1
- package/lib/commands/skill/commands/list.js +1 -1
- package/lib/commands/skill/commands/push.js +1 -1
- package/lib/commands/skill/commands/validate.js +1 -1
- package/lib/commands/skill/diagram.js +1 -1
- package/lib/commands/skill/flags.js +1 -1
- package/lib/commands/skill/index.js +1 -1
- package/lib/commands/skill/manifest-helpers.js +1 -1
- package/lib/commands/skill/push-execute.js +1 -1
- package/lib/commands/skill/push-flow-helpers.js +1 -1
- package/lib/commands/skill/push-retarget.js +1 -1
- package/lib/commands/skill/scopes.js +1 -1
- package/lib/commands/skill/summary.js +1 -1
- package/lib/commands/skill/templates.js +1 -1
- package/lib/commands/skill/validate.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/update.js +1 -1
- package/lib/commands/user-account/bind.js +1 -1
- package/lib/commands/user-account/index.js +1 -1
- package/lib/commands/workspace/index.js +1 -1
- package/lib/config/domain-config.d.ts +33 -1
- package/lib/config/domain-config.js +1 -1
- package/lib/config/schema.d.ts +1 -1
- package/lib/config/schema.js +1 -1
- package/lib/constant/app.js +1 -1
- package/lib/constant/auth-mode.js +1 -1
- package/lib/constant/cli.js +1 -1
- package/lib/constant/defaults.js +1 -1
- package/lib/constant/distribution.js +1 -1
- package/lib/constant/domain.d.ts +3 -3
- package/lib/constant/domain.js +1 -1
- package/lib/constant/env.js +1 -1
- package/lib/constant/output.js +1 -1
- package/lib/constant/product.d.ts +0 -51
- package/lib/constant/product.js +1 -1
- package/lib/constant/region.d.ts +3 -5
- package/lib/constant/region.js +1 -1
- package/lib/constant/risk.js +1 -1
- package/lib/constant/url.js +1 -1
- package/lib/context.js +1 -1
- package/lib/core/api-client.d.ts +16 -0
- package/lib/core/api-client.js +1 -1
- package/lib/core/db-resolver.js +1 -1
- package/lib/core/sdk-client.js +1 -1
- package/lib/errors.js +1 -1
- package/lib/framework/build-all-flags.js +1 -1
- package/lib/framework/dryrun.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/preparse.js +1 -1
- package/lib/framework/rate-limit.js +1 -1
- package/lib/framework/raw-flags.js +1 -1
- package/lib/framework/response.js +1 -1
- package/lib/framework/runner-confirmation.js +1 -1
- package/lib/framework/runner-error.js +1 -1
- package/lib/framework/runner.js +1 -1
- package/lib/framework/schema-export.js +1 -1
- package/lib/framework/service-order.js +1 -1
- package/lib/framework/types.d.ts +0 -2
- 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.d.ts +59 -0
- package/lib/generated/official-routing.js +1 -0
- package/lib/generated/routing-contract.d.ts +9 -0
- package/lib/generated/routing-contract.js +1 -0
- package/lib/help.js +1 -1
- package/lib/postinstall.js +1 -1
- package/lib/runtime/confirmation.js +1 -1
- package/lib/runtime/event.js +1 -1
- package/lib/runtime/index.js +1 -1
- package/lib/runtime/queue.js +1 -1
- package/lib/runtime/resolve.js +1 -1
- package/lib/skills/builtin-skill.js +1 -1
- package/lib/skills/npx-skills-add.js +1 -1
- package/lib/skills/runtime-skill-sync/constants.js +1 -1
- package/lib/skills/runtime-skill-sync/fs-utils.js +1 -1
- package/lib/skills/runtime-skill-sync/hashing.js +1 -1
- package/lib/skills/runtime-skill-sync/install-target.js +1 -1
- package/lib/skills/runtime-skill-sync/links.js +1 -1
- package/lib/skills/runtime-skill-sync/list-local.js +1 -1
- package/lib/skills/runtime-skill-sync/local-files.js +1 -1
- package/lib/skills/runtime-skill-sync/materialize.js +1 -1
- package/lib/skills/runtime-skill-sync/metadata.js +1 -1
- package/lib/skills/runtime-skill-sync/paths.js +1 -1
- package/lib/skills/runtime-skill-sync/push.js +1 -1
- package/lib/skills/runtime-skill-sync/scopes.js +1 -1
- package/lib/skills/runtime-skill-sync/zip-codec.js +1 -1
- package/lib/skills/runtime-skill-sync/zip-package.js +1 -1
- package/lib/skills/runtime-skill-sync.js +1 -1
- package/lib/skills/skill-presence.js +1 -1
- package/lib/utils/access-key-redaction.js +1 -1
- package/lib/utils/apply-jq-filter.js +1 -1
- package/lib/utils/cli-version-check.js +1 -1
- package/lib/utils/cli-version-policy.js +1 -1
- package/lib/utils/logger.js +1 -1
- package/lib/utils/lossless-json.js +1 -1
- package/lib/utils/params.js +1 -1
- package/lib/utils/platform.js +1 -1
- package/lib/utils/update-notice.js +1 -1
- package/lib/utils/version.js +1 -1
- package/lib/utils/write-cli-side-channel.js +1 -1
- package/package.json +2 -1
- package/skills/lovrabet/SKILL.md +4 -4
- package/skills/lovrabet/guides/troubleshooting.md +3 -5
- package/skills/lovrabet/references/lovrabet-config-commands.md +33 -10
- package/skills/lovrabet/references/lovrabet-config.md +8 -20
- package/skills/lovrabet/references/lovrabet-doctor.md +0 -2
- package/skills/lovrabet/references/lovrabet-kb-workflow.md +1 -3
- package/skills/lovrabet.manifest.json +3 -3
- package/lib/core/kb-search-client.d.ts +0 -30
- package/lib/core/kb-search-client.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
const a25_0x4a6051=a25_0x4150;function a25_0x4150(_0x2fae53,_0x17d8a5){_0x2fae53=_0x2fae53-0x1ca;const _0xc2d662=a25_0xc2d6();let _0x4150cd=_0xc2d662[_0x2fae53];return _0x4150cd;}(function(_0xc83be1,_0x2e2806){const _0x422f38=a25_0x4150,_0x91c95a=_0xc83be1();while(!![]){try{const _0x2bbdad=parseInt(_0x422f38(0x1fa))/0x1*(-parseInt(_0x422f38(0x1ed))/0x2)+-parseInt(_0x422f38(0x222))/0x3*(parseInt(_0x422f38(0x20c))/0x4)+-parseInt(_0x422f38(0x1ce))/0x5+-parseInt(_0x422f38(0x1e1))/0x6+-parseInt(_0x422f38(0x228))/0x7+parseInt(_0x422f38(0x1d4))/0x8*(-parseInt(_0x422f38(0x1f0))/0x9)+parseInt(_0x422f38(0x1de))/0xa*(parseInt(_0x422f38(0x204))/0xb);if(_0x2bbdad===_0x2e2806)break;else _0x91c95a['push'](_0x91c95a['shift']());}catch(_0x349584){_0x91c95a['push'](_0x91c95a['shift']());}}}(a25_0xc2d6,0x7499a));import{executeData}from'../../core/sdk-client.js';import{CODE_FLAG,PARAMS_FLAG}from'../../commands/common/flags.js';import{requireAnyOf}from'../../commands/common/constraints.js';import{parseJsonParams,parseJsonParamsValue,parseBatchCreateItemsFromParams,parseUpdateIdsFromParams,normalizeUpdateParamsForRuntime}from'../../utils/params.js';import{dryRun}from'../../framework/dryrun.js';const specs=[{'command':'filter','operation':'filter','risk':a25_0x4a6051(0x20e),'paramsRequired':![],'description':'Filter\x20dataset\x20records\x20with\x20query\x20conditions','paramsHint':a25_0x4a6051(0x20a)+a25_0x4a6051(0x1f5),'helpExtra':[a25_0x4a6051(0x1cf),a25_0x4a6051(0x21f),'\x20\x20\x20\x20$ne\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Not\x20equals\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22status\x22:{\x22$ne\x22:\x22deleted\x22}}',a25_0x4a6051(0x1d9),a25_0x4a6051(0x219),a25_0x4a6051(0x210),a25_0x4a6051(0x211),a25_0x4a6051(0x212),a25_0x4a6051(0x1f2),a25_0x4a6051(0x206),a25_0x4a6051(0x21d),'',a25_0x4a6051(0x224),a25_0x4a6051(0x1fd),'\x20\x20\x20\x20$or\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Any\x20condition\x20matches\x20\x20{\x22$or\x22:[{\x22status\x22:{\x22$eq\x22:\x22active\x22}},{\x22status\x22:{\x22$eq\x22:\x22pending\x22}}]}','','\x20\x20JSON\x20BODY\x20FIELDS\x20(pass\x20inside\x20--params)','\x20\x20\x20\x20where\x20\x20\x20\x20\x20\x20\x20\x20\x20Object\x20\x20\x20Query\x20conditions\x20(see\x20operators\x20above)',a25_0x4a6051(0x1d3),'\x20\x20\x20\x20orderBy\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Sort\x20order,\x20e.g.\x20[{\x22id\x22:\x22desc\x22},{\x22name\x22:\x22asc\x22}]',a25_0x4a6051(0x1cd),'\x20\x20\x20\x20pageSize\x20\x20\x20\x20\x20\x20Number\x20\x20\x20Records\x20per\x20page\x20(default:\x2020)','',a25_0x4a6051(0x1e3),'\x20\x20\x20\x20Filtering\x20and\x20pagination\x20are\x20controlled\x20only\x20via\x20one\x20JSON\x20object\x20in\x20--params.',a25_0x4a6051(0x1d6),a25_0x4a6051(0x1ff),a25_0x4a6051(0x1e6),a25_0x4a6051(0x1ee),a25_0x4a6051(0x21b),a25_0x4a6051(0x1e8)][a25_0x4a6051(0x1fc)]('\x0a')},{'command':a25_0x4a6051(0x207),'operation':'getOne','risk':a25_0x4a6051(0x20e),'paramsRequired':!![],'description':a25_0x4a6051(0x220),'paramsHint':a25_0x4a6051(0x21a)},{'command':'create','operation':a25_0x4a6051(0x1f1),'risk':a25_0x4a6051(0x1ca),'paramsRequired':!![],'description':a25_0x4a6051(0x1db),'confirmationDescription':'Writes\x20one\x20new\x20business\x20record\x20to\x20the\x20current\x20app\x20dataset.\x20It\x20is\x20saved\x20immediately\x20after\x20confirmation.','paramsHint':a25_0x4a6051(0x1d7)},{'command':a25_0x4a6051(0x216),'operation':a25_0x4a6051(0x216),'risk':a25_0x4a6051(0x1ca),'paramsRequired':!![],'description':a25_0x4a6051(0x225),'confirmationDescription':a25_0x4a6051(0x1e0),'paramsHint':a25_0x4a6051(0x1cc)},{'command':'update','operation':a25_0x4a6051(0x1df),'risk':a25_0x4a6051(0x1ca),'paramsRequired':!![],'description':a25_0x4a6051(0x20f),'confirmationDescription':a25_0x4a6051(0x1ea),'paramsHint':a25_0x4a6051(0x1e5)+a25_0x4a6051(0x221)},{'command':a25_0x4a6051(0x1dc),'operation':a25_0x4a6051(0x1dc),'risk':a25_0x4a6051(0x1d2),'paramsRequired':!![],'description':a25_0x4a6051(0x1d5),'confirmationDescription':a25_0x4a6051(0x1e4),'paramsHint':a25_0x4a6051(0x21a)},{'command':a25_0x4a6051(0x226),'operation':a25_0x4a6051(0x226),'risk':a25_0x4a6051(0x20e),'paramsRequired':![],'description':a25_0x4a6051(0x21e),'paramsHint':a25_0x4a6051(0x20b)+a25_0x4a6051(0x208),'helpExtra':['\x20\x20AGGREGATE\x20TYPES','\x20\x20\x20\x20SUM\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Sum\x20of\x20column\x20values\x20\x20\x20\x20\x20{\x22column\x22:\x22amount\x22,\x22type\x22:\x22SUM\x22,\x22alias\x22:\x22total\x22}','\x20\x20\x20\x20COUNT\x20\x20\x20\x20\x20\x20\x20\x20Count\x20of\x20records\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22column\x22:\x22id\x22,\x22type\x22:\x22COUNT\x22,\x22alias\x22:\x22cnt\x22}',a25_0x4a6051(0x214),a25_0x4a6051(0x1f3),'\x20\x20\x20\x20AVG\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Rounded\x20average\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22column\x22:\x22score\x22,\x22type\x22:\x22AVG\x22,\x22alias\x22:\x22avg\x22,\x22round\x22:true,\x22precision\x22:2}',a25_0x4a6051(0x202),a25_0x4a6051(0x1d0),'',a25_0x4a6051(0x203),'\x20\x20\x20\x20select\x20\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Fields\x20to\x20return\x20alongside\x20aggregates,\x20e.g.\x20[\x22status\x22,\x22region\x22]',a25_0x4a6051(0x1f8),'\x20\x20\x20\x20where\x20\x20\x20\x20\x20\x20\x20\x20\x20Object\x20\x20\x20Pre-aggregation\x20filter\x20(same\x20operators\x20as\x20data\x20filter)','\x20\x20\x20\x20groupBy\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Grouping\x20fields,\x20e.g.\x20[\x22status\x22,\x22region\x22]',a25_0x4a6051(0x1cb),a25_0x4a6051(0x1eb),'','\x20\x20AGGREGATE\x20ALIAS\x20BOUNDARY',a25_0x4a6051(0x1dd),'\x20\x20\x20\x20select/where/having/groupBy\x20must\x20use\x20real\x20dataset\x20fields',a25_0x4a6051(0x218),'','\x20\x20DATASET\x20BOUNDARY',a25_0x4a6051(0x1e7),a25_0x4a6051(0x1fe),'\x20\x20\x20\x20JOIN\x20and\x20cross-table\x20aggregation\x20require\x20an\x20existing\x20trusted\x20Custom\x20SQL',a25_0x4a6051(0x1ef),'','\x20\x20EXAMPLES','\x20\x20\x20\x20#\x20Sum\x20amount\x20grouped\x20by\x20status',a25_0x4a6051(0x1f4),'',a25_0x4a6051(0x21c),'\x20\x20\x20\x20--params\x20\x27{\x22aggregate\x22:[{\x22column\x22:\x22id\x22,\x22type\x22:\x22COUNT\x22,\x22alias\x22:\x22cnt\x22}],\x22groupBy\x22:[\x22region\x22],\x22where\x22:{\x22status\x22:{\x22$eq\x22:\x22active\x22}}}\x27','',a25_0x4a6051(0x1f7)][a25_0x4a6051(0x1fc)]('\x0a')}];function a25_0xc2d6(){const _0x4c9007=['str','1400014VJFdft','write','\x20\x20\x20\x20having\x20\x20\x20\x20\x20\x20\x20\x20Object\x20\x20\x20Post-aggregation\x20filters\x20using\x20real\x20dataset\x20fields,\x20e.g.\x20{\x22category_id\x22:{\x22$notNull\x22:true}}','JSON\x20array\x20of\x20record\x20objects,\x20or\x20{\x22items\x22:[...]}.\x20Example:\x20\x27[{\x22name\x22:\x22a\x22},{\x22name\x22:\x22b\x22}]\x27','\x20\x20\x20\x20currentPage\x20\x20\x20Number\x20\x20\x20Page\x20number\x20(starts\x20from\x201)','3407470yeqQIG','\x20\x20WHERE\x20OPERATORS','\x20\x20\x20\x20MIN\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Minimum\x20value\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22column\x22:\x22price\x22,\x22type\x22:\x22MIN\x22,\x22alias\x22:\x22min_price\x22}','description','high-risk-write','\x20\x20\x20\x20select\x20\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Fields\x20to\x20return,\x20e.g.\x20[\x22id\x22,\x22name\x22,\x22status\x22]','224FoMxoT','Delete\x20data\x20records\x20(non-interactive\x20mode\x20requires\x20--yes)','\x20\x20\x20\x20Do\x20NOT\x20use\x20--where,\x20--select,\x20--order-by,\x20--current-page,\x20--page,\x20or\x20--page-size\x20as\x20CLI\x20flags.','JSON\x20with\x20field\x20values.\x20Example:\x20\x27{\x22name\x22:\x22test\x22,\x22amount\x22:100}\x27','length','\x20\x20\x20\x20$gt\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Greater\x20than\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22amount\x22:{\x22$gt\x22:100}}','body','Create\x20one\x20record\x20in\x20the\x20dataset','delete','\x20\x20\x20\x20aggregate[].alias\x20defines\x20the\x20output\x20field\x20name\x20only','20hYiblL','update','Writes\x20multiple\x20new\x20business\x20records\x20to\x20the\x20current\x20app\x20dataset.\x20They\x20are\x20saved\x20immediately\x20after\x20confirmation.','4496328SAvlbw','operation','\x20\x20PAGINATION','Deletes\x20business\x20records\x20from\x20the\x20current\x20app\x20dataset.\x20This\x20may\x20not\x20be\x20recoverable.','JSON\x20with\x20id\x20+\x20fields\x20to\x20update.\x20id\x20may\x20be\x20a\x20single\x20value\x20or\x20array.\x20','\x20\x20\x20\x20and\x20increment\x20only\x20currentPage.\x20Use\x20a\x20stable\x20unique\x20orderBy\x20field\x20to\x20avoid\x20duplicates\x20or\x20gaps.','\x20\x20\x20\x20aggregate\x20supports\x20a\x20single\x20DB_TABLE\x20dataset\x20only','\x20\x20\x20\x20Verify\x20the\x20response\x20paging.currentPage/pageSize\x20and\x20that\x20tableData\x20satisfies\x20where\x20before\x20drawing\x20conclusions.','code','Changes\x20an\x20existing\x20business\x20record\x20in\x20the\x20current\x20app\x20dataset.\x20The\x20new\x20values\x20are\x20saved\x20immediately\x20after\x20confirmation.','\x20\x20\x20\x20orderBy\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Sort\x20order;\x20may\x20reference\x20aggregate\x20output\x20aliases,\x20e.g.\x20[{\x22total\x22:\x22desc\x22}]','data','2rjFhaF','\x20\x20\x20\x20Page\x201:\x20--params\x20\x27{\x22where\x22:{\x22status\x22:{\x22$eq\x22:\x22active\x22}},\x22orderBy\x22:[{\x22id\x22:\x22asc\x22}],\x22currentPage\x22:1,\x22pageSize\x22:20}\x27','\x20\x20\x20\x20choose\x20the\x20capability\x20before\x20execution;\x20never\x20fall\x20back\x20at\x20runtime','59229rtmDhY','create','\x20\x20\x20\x20$contain\x20\x20\x20\x20\x20Substring\x20match\x20\x20\x20\x20\x20\x20\x20\x20{\x22name\x22:{\x22$contain\x22:\x22test\x22}}','\x20\x20\x20\x20AVG\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Average\x20value\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22column\x22:\x22score\x22,\x22type\x22:\x22AVG\x22,\x22alias\x22:\x22avg_score\x22}','\x20\x20\x20\x20--params\x20\x27{\x22aggregate\x22:[{\x22column\x22:\x22amount\x22,\x22type\x22:\x22SUM\x22,\x22alias\x22:\x22total\x22}],\x22groupBy\x22:[\x22status\x22]}\x27','Example:\x20\x27{\x22where\x22:{\x22status\x22:{\x22$eq\x22:\x22active\x22}},\x22currentPage\x22:1,\x22pageSize\x22:20}\x27','Preview:\x20data\x20','\x20\x20\x20\x20#\x20`field`\x20is\x20accepted\x20as\x20a\x20deprecated\x20alias\x20for\x20`column`;\x20new\x20calls\x20should\x20use\x20`column`.','\x20\x20\x20\x20aggregate\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Aggregation\x20definitions\x20(see\x20AGGREGATE\x20TYPES\x20above)','batch','829018hXrMKx','command','join','\x20\x20\x20\x20$and\x20\x20\x20\x20\x20\x20\x20\x20\x20All\x20conditions\x20match\x20\x20\x20{\x22$and\x22:[{\x22age\x22:{\x22$gte\x22:18}},{\x22status\x22:{\x22$eq\x22:\x22active\x22}}]}','\x20\x20\x20\x20METADATA\x20datasets\x20do\x20not\x20support\x20aggregate\x20or\x20Custom\x20SQL','\x20\x20\x20\x20Page\x20numbers\x20start\x20at\x201.\x20To\x20fetch\x20the\x20next\x20page,\x20keep\x20where/select/orderBy/pageSize\x20unchanged','now','/api/{appCode}/','\x20\x20\x20\x20MAX\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Maximum\x20value\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22column\x22:\x22price\x22,\x22type\x22:\x22MAX\x22,\x22alias\x22:\x22max_price\x22}','\x20\x20PARAMS\x20STRUCTURE','17667089WWUeqH','data\x20','\x20\x20\x20\x20$startWith\x20\x20\x20Starts\x20with\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22name\x22:{\x22$startWith\x22:\x22Mr.\x22}}','getOne','Example:\x20\x27{\x22aggregate\x22:[{\x22column\x22:\x20\x22amount\x22,\x22type\x22:\x22SUM\x22,\x22alias\x22:\x22total\x22}],\x22groupBy\x22:[\x22status\x22]}\x27','POST','JSON\x20body\x20for\x20filter\x20API.\x20Fields:\x20where,\x20select,\x20orderBy,\x20currentPage,\x20pageSize.\x20','JSON\x20body\x20for\x20aggregate\x20API.\x20Fields:\x20select,\x20aggregate,\x20where,\x20groupBy,\x20having,\x20orderBy.\x20','4dngKvu','build','read','Update\x20an\x20existing\x20data\x20record','\x20\x20\x20\x20$lt\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Less\x20than\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22amount\x22:{\x22$lt\x22:1000}}','\x20\x20\x20\x20$lte\x20\x20\x20\x20\x20\x20\x20\x20\x20Less\x20than\x20or\x20equal\x20\x20\x20\x20\x20{\x22amount\x22:{\x22$lte\x22:1000}}','\x20\x20\x20\x20$in\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Value\x20in\x20set\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22country\x22:{\x22$in\x22:[\x22CN\x22,\x22US\x22]}}','params','\x20\x20\x20\x20COUNT\x20\x20\x20\x20\x20\x20\x20\x20Count\x20distinct\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22column\x22:\x22id\x22,\x22type\x22:\x22COUNT\x22,\x22alias\x22:\x22cnt\x22,\x22distinct\x22:true}','risk','batchCreate','dryRun','\x20\x20\x20\x20orderBy\x20may\x20reference\x20aggregate\x20output\x20aliases','\x20\x20\x20\x20$gte\x20\x20\x20\x20\x20\x20\x20\x20\x20Greater\x20than\x20or\x20equal\x20\x20{\x22amount\x22:{\x22$gte\x22:100}}','JSON\x20with\x20record\x20id.\x20Example:\x20\x27{\x22id\x22:123}\x27','\x20\x20\x20\x20Page\x202:\x20--params\x20\x27{\x22where\x22:{\x22status\x22:{\x22$eq\x22:\x22active\x22}},\x22orderBy\x22:[{\x22id\x22:\x22asc\x22}],\x22currentPage\x22:2,\x22pageSize\x22:20}\x27','\x20\x20\x20\x20#\x20Count\x20orders\x20per\x20region\x20with\x20filter','\x20\x20\x20\x20$endWith\x20\x20\x20\x20\x20Ends\x20with\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22email\x22:{\x22$endWith\x22:\x22@example.com\x22}}','Aggregate\x20dataset\x20records\x20(group\x20by,\x20sum,\x20count,\x20avg,\x20etc.)','\x20\x20\x20\x20$eq\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Equals\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22age\x22:{\x22$eq\x22:18}}','Get\x20a\x20single\x20record\x20by\x20ID','Examples:\x20\x27{\x22id\x22:123,\x22status\x22:\x22completed\x22}\x27,\x20\x27{\x22id\x22:[1,2,3],\x22status\x22:\x22completed\x22}\x27','271302UMDMqc','\x20on\x20dataset\x20','\x20\x20LOGICAL\x20COMBINATORS','Create\x20multiple\x20records\x20in\x20the\x20dataset\x20in\x20one\x20request','aggregate'];a25_0xc2d6=function(){return _0x4c9007;};return a25_0xc2d6();}function makeDataCommand(_0x26eb67){const _0x32faab=a25_0x4a6051,_0xc9b3be=_0x32faab(0x205)+_0x26eb67[_0x32faab(0x1fb)],_0x40114f={'service':_0x32faab(0x1ec),'command':_0x26eb67[_0x32faab(0x1fb)],'description':_0x26eb67['description'],'risk':_0x26eb67[_0x32faab(0x215)],..._0x26eb67['confirmationDescription']?{'confirmationDescription':_0x26eb67['confirmationDescription']}:{},'helpExtra':_0x26eb67['helpExtra'],'flags':[CODE_FLAG,{...PARAMS_FLAG,'description':_0x26eb67['paramsHint']}],'validate':async _0x41ae52=>{const _0x15a96b=_0x32faab;_0x26eb67['paramsRequired']&&requireAnyOf(_0x41ae52,[_0x15a96b(0x213)],_0xc9b3be),_0x26eb67[_0x15a96b(0x1e2)]===_0x15a96b(0x216)&&parseBatchCreateItemsFromParams(parseJsonParamsValue(_0x41ae52[_0x15a96b(0x227)](_0x15a96b(0x213)))),_0x26eb67[_0x15a96b(0x1e2)]===_0x15a96b(0x1df)&&parseUpdateIdsFromParams(parseJsonParams(_0x41ae52[_0x15a96b(0x227)]('params'))??{});},async 'execute'(_0x57b75f){const _0x3723ab=_0x32faab,_0x4cda92=_0x57b75f[_0x3723ab(0x227)](_0x3723ab(0x1e9)),_0x5548e1=_0x26eb67[_0x3723ab(0x1e2)]===_0x3723ab(0x216)?parseBatchCreateItemsFromParams(parseJsonParamsValue(_0x57b75f[_0x3723ab(0x227)](_0x3723ab(0x213)))):parseJsonParams(_0x57b75f[_0x3723ab(0x227)]('params'))??{},_0x19eff9=_0x26eb67[_0x3723ab(0x1e2)]===_0x3723ab(0x1df)?parseUpdateIdsFromParams(_0x5548e1):undefined,_0x5ba9f9=_0x19eff9?normalizeUpdateParamsForRuntime(_0x5548e1,_0x19eff9):_0x5548e1,_0x3d38dc=Date[_0x3723ab(0x200)](),_0x4643b7=await executeData(_0x4cda92,_0x26eb67[_0x3723ab(0x1e2)],_0x5ba9f9),_0x559d45=Date[_0x3723ab(0x200)]()-_0x3d38dc,_0x1d271f=_0x19eff9&&_0x19eff9[_0x3723ab(0x1d8)]>0x1?buildBatchUpdateResult(_0x19eff9,_0x4643b7):_0x4643b7;return{'ok':!![],'data':{'result':_0x1d271f,'elapsed':_0x559d45},'message':_0x3723ab(0x205)+_0x26eb67['command']+'\x20completed\x20in\x20'+_0x559d45+'ms'};}};return _0x26eb67[_0x32faab(0x215)]!=='read'&&(_0x40114f[_0x32faab(0x217)]=async _0x3c4f87=>{const _0x54fa05=_0x32faab,_0x1666f4=_0x3c4f87[_0x54fa05(0x227)]('code'),_0x3eee77=_0x26eb67['operation']==='batchCreate'?parseBatchCreateItemsFromParams(parseJsonParamsValue(_0x3c4f87['str'](_0x54fa05(0x213)))):parseJsonParams(_0x3c4f87['str'](_0x54fa05(0x213)))??{};let _0x4078be=_0x3eee77;if(_0x26eb67[_0x54fa05(0x1e2)]===_0x54fa05(0x1df)){const _0x3e4f86=parseUpdateIdsFromParams(_0x3eee77);_0x4078be=normalizeUpdateParamsForRuntime(_0x3eee77,_0x3e4f86);}return dryRun(_0x54fa05(0x209),_0x54fa05(0x201)+_0x1666f4+'/'+_0x26eb67[_0x54fa05(0x1e2)])[_0x54fa05(0x1da)](_0x4078be)[_0x54fa05(0x1d1)](_0x54fa05(0x1f6)+_0x26eb67['command']+_0x54fa05(0x223)+_0x1666f4)[_0x54fa05(0x20d)]();}),_0x40114f;}export const dataDefinitions=specs['map'](makeDataCommand);function buildBatchUpdateResult(_0x5f59f6,_0x21aea9){const _0x14595b=a25_0x4a6051;return{'operation':'update','mode':_0x14595b(0x1f9),'ids':_0x5f59f6,'total':_0x5f59f6[_0x14595b(0x1d8)],'result':_0x21aea9};}
|
|
1
|
+
function a25_0x53c6(_0xd52995,_0x572b98){_0xd52995=_0xd52995-0x14a;const _0x362b97=a25_0x362b();let _0x53c672=_0x362b97[_0xd52995];return _0x53c672;}const a25_0x239022=a25_0x53c6;(function(_0x53a0c9,_0x53d51c){const _0x255f5d=a25_0x53c6,_0x26b270=_0x53a0c9();while(!![]){try{const _0x1b8944=parseInt(_0x255f5d(0x17e))/0x1*(parseInt(_0x255f5d(0x193))/0x2)+parseInt(_0x255f5d(0x1ad))/0x3+-parseInt(_0x255f5d(0x1a6))/0x4*(-parseInt(_0x255f5d(0x1a2))/0x5)+-parseInt(_0x255f5d(0x19a))/0x6*(parseInt(_0x255f5d(0x153))/0x7)+-parseInt(_0x255f5d(0x1a4))/0x8*(-parseInt(_0x255f5d(0x15c))/0x9)+parseInt(_0x255f5d(0x1a9))/0xa+-parseInt(_0x255f5d(0x150))/0xb*(parseInt(_0x255f5d(0x172))/0xc);if(_0x1b8944===_0x53d51c)break;else _0x26b270['push'](_0x26b270['shift']());}catch(_0x13902b){_0x26b270['push'](_0x26b270['shift']());}}}(a25_0x362b,0x4f426));import{executeData}from'../../core/sdk-client.js';function a25_0x362b(){const _0x4e5f14=['\x20\x20\x20\x20SUM\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Sum\x20of\x20column\x20values\x20\x20\x20\x20\x20{\x22column\x22:\x22amount\x22,\x22type\x22:\x22SUM\x22,\x22alias\x22:\x22total\x22}','\x20\x20DATASET\x20BOUNDARY','str','\x20\x20JSON\x20BODY\x20FIELDS\x20(pass\x20inside\x20--params)','\x20\x20\x20\x20$in\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Value\x20in\x20set\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22country\x22:{\x22$in\x22:[\x22CN\x22,\x22US\x22]}}','28655HzPifb','delete','confirmationDescription','938427uwTpaY','Changes\x20an\x20existing\x20business\x20record\x20in\x20the\x20current\x20app\x20dataset.\x20The\x20new\x20values\x20are\x20saved\x20immediately\x20after\x20confirmation.','data\x20','\x20\x20\x20\x20Filtering\x20and\x20pagination\x20are\x20controlled\x20only\x20via\x20one\x20JSON\x20object\x20in\x20--params.','Get\x20a\x20single\x20record\x20by\x20ID','\x20\x20EXAMPLES','Example:\x20\x27{\x22aggregate\x22:[{\x22column\x22:\x20\x22amount\x22,\x22type\x22:\x22SUM\x22,\x22alias\x22:\x22total\x22}],\x22groupBy\x22:[\x22status\x22]}\x27','\x20\x20\x20\x20$gte\x20\x20\x20\x20\x20\x20\x20\x20\x20Greater\x20than\x20or\x20equal\x20\x20{\x22amount\x22:{\x22$gte\x22:100}}','JSON\x20body\x20for\x20filter\x20API.\x20Fields:\x20where,\x20select,\x20orderBy,\x20currentPage,\x20pageSize.\x20','378693bMOlFA','params','Writes\x20one\x20new\x20business\x20record\x20to\x20the\x20current\x20app\x20dataset.\x20It\x20is\x20saved\x20immediately\x20after\x20confirmation.','Example:\x20\x27{\x22where\x22:{\x22status\x22:{\x22$eq\x22:\x22active\x22}},\x22currentPage\x22:1,\x22pageSize\x22:20}\x27','join','aggregate','Update\x20an\x20existing\x20data\x20record','\x20\x20AGGREGATE\x20TYPES','\x20\x20\x20\x20select\x20\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Fields\x20to\x20return,\x20e.g.\x20[\x22id\x22,\x22name\x22,\x22status\x22]','\x20\x20\x20\x20$or\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Any\x20condition\x20matches\x20\x20{\x22$or\x22:[{\x22status\x22:{\x22$eq\x22:\x22active\x22}},{\x22status\x22:{\x22$eq\x22:\x22pending\x22}}]}','\x20\x20\x20\x20groupBy\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Grouping\x20fields,\x20e.g.\x20[\x22status\x22,\x22region\x22]','\x20\x20\x20\x20MAX\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Maximum\x20value\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22column\x22:\x22price\x22,\x22type\x22:\x22MAX\x22,\x22alias\x22:\x22max_price\x22}','helpExtra','Writes\x20multiple\x20new\x20business\x20records\x20to\x20the\x20current\x20app\x20dataset.\x20They\x20are\x20saved\x20immediately\x20after\x20confirmation.','paramsHint','JSON\x20with\x20field\x20values.\x20Example:\x20\x27{\x22name\x22:\x22test\x22,\x22amount\x22:100}\x27','\x20\x20\x20\x20Page\x20numbers\x20start\x20at\x201.\x20To\x20fetch\x20the\x20next\x20page,\x20keep\x20where/select/orderBy/pageSize\x20unchanged','risk','\x20\x20\x20\x20currentPage\x20\x20\x20Number\x20\x20\x20Page\x20number\x20(starts\x20from\x201)','length','\x20\x20\x20\x20METADATA\x20datasets\x20do\x20not\x20support\x20aggregate\x20or\x20Custom\x20SQL','\x20\x20\x20\x20#\x20`field`\x20is\x20accepted\x20as\x20a\x20deprecated\x20alias\x20for\x20`column`;\x20new\x20calls\x20should\x20use\x20`column`.','8400OcBVyZ','\x20\x20AGGREGATE\x20ALIAS\x20BOUNDARY','Preview:\x20data\x20','create','Create\x20one\x20record\x20in\x20the\x20dataset','batch','\x20\x20\x20\x20--params\x20\x27{\x22aggregate\x22:[{\x22column\x22:\x22id\x22,\x22type\x22:\x22COUNT\x22,\x22alias\x22:\x22cnt\x22}],\x22groupBy\x22:[\x22region\x22],\x22where\x22:{\x22status\x22:{\x22$eq\x22:\x22active\x22}}}\x27','\x20\x20WHERE\x20OPERATORS','\x20\x20\x20\x20JOIN\x20and\x20cross-table\x20aggregation\x20require\x20an\x20existing\x20trusted\x20Custom\x20SQL','\x20\x20\x20\x20select/where/having/groupBy\x20must\x20use\x20real\x20dataset\x20fields','\x20\x20\x20\x20AVG\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Average\x20value\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22column\x22:\x22score\x22,\x22type\x22:\x22AVG\x22,\x22alias\x22:\x22avg_score\x22}','batchCreate','34028Gfyppr','/api/{appCode}/','read','\x20\x20\x20\x20$lt\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Less\x20than\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22amount\x22:{\x22$lt\x22:1000}}','\x20\x20\x20\x20Verify\x20the\x20response\x20paging.currentPage/pageSize\x20and\x20that\x20tableData\x20satisfies\x20where\x20before\x20drawing\x20conclusions.','\x20\x20\x20\x20where\x20\x20\x20\x20\x20\x20\x20\x20\x20Object\x20\x20\x20Query\x20conditions\x20(see\x20operators\x20above)','\x20\x20PARAMS\x20STRUCTURE','body','update','\x20\x20\x20\x20orderBy\x20may\x20reference\x20aggregate\x20output\x20aliases','\x20\x20\x20\x20$gt\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Greater\x20than\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22amount\x22:{\x22$gt\x22:100}}','Deletes\x20business\x20records\x20from\x20the\x20current\x20app\x20dataset.\x20This\x20may\x20not\x20be\x20recoverable.','getOne','now','\x20\x20\x20\x20Do\x20NOT\x20use\x20--where,\x20--select,\x20--order-by,\x20--current-page,\x20--page,\x20or\x20--page-size\x20as\x20CLI\x20flags.','\x20\x20\x20\x20aggregate\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Aggregation\x20definitions\x20(see\x20AGGREGATE\x20TYPES\x20above)','write','\x20\x20\x20\x20Page\x202:\x20--params\x20\x27{\x22where\x22:{\x22status\x22:{\x22$eq\x22:\x22active\x22}},\x22orderBy\x22:[{\x22id\x22:\x22asc\x22}],\x22currentPage\x22:2,\x22pageSize\x22:20}\x27','operation','\x20\x20\x20\x20Page\x201:\x20--params\x20\x27{\x22where\x22:{\x22status\x22:{\x22$eq\x22:\x22active\x22}},\x22orderBy\x22:[{\x22id\x22:\x22asc\x22}],\x22currentPage\x22:1,\x22pageSize\x22:20}\x27','filter','34daaTnG','\x20\x20\x20\x20$endWith\x20\x20\x20\x20\x20Ends\x20with\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22email\x22:{\x22$endWith\x22:\x22@example.com\x22}}','\x20\x20\x20\x20orderBy\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Sort\x20order,\x20e.g.\x20[{\x22id\x22:\x22desc\x22},{\x22name\x22:\x22asc\x22}]','build','\x20\x20\x20\x20COUNT\x20\x20\x20\x20\x20\x20\x20\x20Count\x20distinct\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22column\x22:\x22id\x22,\x22type\x22:\x22COUNT\x22,\x22alias\x22:\x22cnt\x22,\x22distinct\x22:true}','command','\x20\x20\x20\x20pageSize\x20\x20\x20\x20\x20\x20Number\x20\x20\x20Records\x20per\x20page\x20(default:\x2020)','6cLmkry','\x20\x20\x20\x20--params\x20\x27{\x22aggregate\x22:[{\x22column\x22:\x22amount\x22,\x22type\x22:\x22SUM\x22,\x22alias\x22:\x22total\x22}],\x22groupBy\x22:[\x22status\x22]}\x27','\x20\x20\x20\x20COUNT\x20\x20\x20\x20\x20\x20\x20\x20Count\x20of\x20records\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22column\x22:\x22id\x22,\x22type\x22:\x22COUNT\x22,\x22alias\x22:\x22cnt\x22}','Delete\x20data\x20records\x20(non-interactive\x20mode\x20requires\x20--yes)','JSON\x20array\x20of\x20record\x20objects,\x20or\x20{\x22items\x22:[...]}.\x20Example:\x20\x27[{\x22name\x22:\x22a\x22},{\x22name\x22:\x22b\x22}]\x27','map','JSON\x20body\x20for\x20aggregate\x20API.\x20Fields:\x20select,\x20aggregate,\x20where,\x20groupBy,\x20having,\x20orderBy.\x20','\x20\x20\x20\x20where\x20\x20\x20\x20\x20\x20\x20\x20\x20Object\x20\x20\x20Pre-aggregation\x20filter\x20(same\x20operators\x20as\x20data\x20filter)','3635Wkyqes','\x20\x20\x20\x20#\x20Count\x20orders\x20per\x20region\x20with\x20filter','120AndMnJ','high-risk-write','2612nBmUpl','code','description','868540kzNDyG','\x20\x20\x20\x20and\x20increment\x20only\x20currentPage.\x20Use\x20a\x20stable\x20unique\x20orderBy\x20field\x20to\x20avoid\x20duplicates\x20or\x20gaps.','\x20\x20\x20\x20$ne\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Not\x20equals\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22status\x22:{\x22$ne\x22:\x22deleted\x22}}','\x20on\x20dataset\x20','1532973sXjyoh','paramsRequired','JSON\x20with\x20id\x20+\x20fields\x20to\x20update.\x20id\x20may\x20be\x20a\x20single\x20value\x20or\x20array.\x20','\x20\x20\x20\x20having\x20\x20\x20\x20\x20\x20\x20\x20Object\x20\x20\x20Post-aggregation\x20filters\x20using\x20real\x20dataset\x20fields,\x20e.g.\x20{\x22category_id\x22:{\x22$notNull\x22:true}}','Examples:\x20\x27{\x22id\x22:123,\x22status\x22:\x22completed\x22}\x27,\x20\x27{\x22id\x22:[1,2,3],\x22status\x22:\x22completed\x22}\x27','\x20\x20\x20\x20AVG\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Rounded\x20average\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22column\x22:\x22score\x22,\x22type\x22:\x22AVG\x22,\x22alias\x22:\x22avg\x22,\x22round\x22:true,\x22precision\x22:2}'];a25_0x362b=function(){return _0x4e5f14;};return a25_0x362b();}import{CODE_FLAG,PARAMS_FLAG}from'../../commands/common/flags.js';import{requireAnyOf}from'../../commands/common/constraints.js';import{parseJsonParams,parseJsonParamsValue,parseBatchCreateItemsFromParams,parseUpdateIdsFromParams,normalizeUpdateParamsForRuntime}from'../../utils/params.js';import{dryRun}from'../../framework/dryrun.js';const specs=[{'command':'filter','operation':a25_0x239022(0x192),'risk':'read','paramsRequired':![],'description':'Filter\x20dataset\x20records\x20with\x20query\x20conditions','paramsHint':a25_0x239022(0x15b)+a25_0x239022(0x15f),'helpExtra':[a25_0x239022(0x179),'\x20\x20\x20\x20$eq\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Equals\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22age\x22:{\x22$eq\x22:18}}',a25_0x239022(0x1ab),a25_0x239022(0x188),a25_0x239022(0x15a),a25_0x239022(0x181),'\x20\x20\x20\x20$lte\x20\x20\x20\x20\x20\x20\x20\x20\x20Less\x20than\x20or\x20equal\x20\x20\x20\x20\x20{\x22amount\x22:{\x22$lte\x22:1000}}',a25_0x239022(0x14f),'\x20\x20\x20\x20$contain\x20\x20\x20\x20\x20Substring\x20match\x20\x20\x20\x20\x20\x20\x20\x20{\x22name\x22:{\x22$contain\x22:\x22test\x22}}','\x20\x20\x20\x20$startWith\x20\x20\x20Starts\x20with\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22name\x22:{\x22$startWith\x22:\x22Mr.\x22}}',a25_0x239022(0x194),'','\x20\x20LOGICAL\x20COMBINATORS','\x20\x20\x20\x20$and\x20\x20\x20\x20\x20\x20\x20\x20\x20All\x20conditions\x20match\x20\x20\x20{\x22$and\x22:[{\x22age\x22:{\x22$gte\x22:18}},{\x22status\x22:{\x22$eq\x22:\x22active\x22}}]}',a25_0x239022(0x165),'',a25_0x239022(0x14e),a25_0x239022(0x183),a25_0x239022(0x164),a25_0x239022(0x195),a25_0x239022(0x16e),a25_0x239022(0x199),'','\x20\x20PAGINATION',a25_0x239022(0x156),a25_0x239022(0x18c),a25_0x239022(0x16c),a25_0x239022(0x1aa),a25_0x239022(0x191),a25_0x239022(0x18f),a25_0x239022(0x182)][a25_0x239022(0x160)]('\x0a')},{'command':a25_0x239022(0x18a),'operation':a25_0x239022(0x18a),'risk':a25_0x239022(0x180),'paramsRequired':!![],'description':a25_0x239022(0x157),'paramsHint':'JSON\x20with\x20record\x20id.\x20Example:\x20\x27{\x22id\x22:123}\x27'},{'command':'create','operation':a25_0x239022(0x175),'risk':a25_0x239022(0x18e),'paramsRequired':!![],'description':a25_0x239022(0x176),'confirmationDescription':a25_0x239022(0x15e),'paramsHint':a25_0x239022(0x16b)},{'command':a25_0x239022(0x17d),'operation':a25_0x239022(0x17d),'risk':a25_0x239022(0x18e),'paramsRequired':!![],'description':'Create\x20multiple\x20records\x20in\x20the\x20dataset\x20in\x20one\x20request','confirmationDescription':a25_0x239022(0x169),'paramsHint':a25_0x239022(0x19e)},{'command':'update','operation':a25_0x239022(0x186),'risk':a25_0x239022(0x18e),'paramsRequired':!![],'description':a25_0x239022(0x162),'confirmationDescription':a25_0x239022(0x154),'paramsHint':a25_0x239022(0x1af)+a25_0x239022(0x1b1)},{'command':'delete','operation':a25_0x239022(0x151),'risk':a25_0x239022(0x1a5),'paramsRequired':!![],'description':a25_0x239022(0x19d),'confirmationDescription':a25_0x239022(0x189),'paramsHint':'JSON\x20with\x20record\x20id.\x20Example:\x20\x27{\x22id\x22:123}\x27'},{'command':'aggregate','operation':a25_0x239022(0x161),'risk':a25_0x239022(0x180),'paramsRequired':![],'description':'Aggregate\x20dataset\x20records\x20(group\x20by,\x20sum,\x20count,\x20avg,\x20etc.)','paramsHint':a25_0x239022(0x1a0)+a25_0x239022(0x159),'helpExtra':[a25_0x239022(0x163),a25_0x239022(0x14b),a25_0x239022(0x19c),a25_0x239022(0x197),a25_0x239022(0x17c),a25_0x239022(0x14a),a25_0x239022(0x167),'\x20\x20\x20\x20MIN\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Minimum\x20value\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22column\x22:\x22price\x22,\x22type\x22:\x22MIN\x22,\x22alias\x22:\x22min_price\x22}','',a25_0x239022(0x184),'\x20\x20\x20\x20select\x20\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Fields\x20to\x20return\x20alongside\x20aggregates,\x20e.g.\x20[\x22status\x22,\x22region\x22]',a25_0x239022(0x18d),a25_0x239022(0x1a1),a25_0x239022(0x166),a25_0x239022(0x1b0),'\x20\x20\x20\x20orderBy\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Sort\x20order;\x20may\x20reference\x20aggregate\x20output\x20aliases,\x20e.g.\x20[{\x22total\x22:\x22desc\x22}]','',a25_0x239022(0x173),'\x20\x20\x20\x20aggregate[].alias\x20defines\x20the\x20output\x20field\x20name\x20only',a25_0x239022(0x17b),a25_0x239022(0x187),'',a25_0x239022(0x14c),'\x20\x20\x20\x20aggregate\x20supports\x20a\x20single\x20DB_TABLE\x20dataset\x20only',a25_0x239022(0x170),a25_0x239022(0x17a),'\x20\x20\x20\x20choose\x20the\x20capability\x20before\x20execution;\x20never\x20fall\x20back\x20at\x20runtime','',a25_0x239022(0x158),'\x20\x20\x20\x20#\x20Sum\x20amount\x20grouped\x20by\x20status',a25_0x239022(0x19b),'',a25_0x239022(0x1a3),a25_0x239022(0x178),'',a25_0x239022(0x171)]['join']('\x0a')}];function makeDataCommand(_0x4e5549){const _0x50786d=a25_0x239022,_0x4be3fd=_0x50786d(0x155)+_0x4e5549[_0x50786d(0x198)],_0x5a5642={'service':'data','command':_0x4e5549[_0x50786d(0x198)],'description':_0x4e5549[_0x50786d(0x1a8)],'risk':_0x4e5549[_0x50786d(0x16d)],..._0x4e5549[_0x50786d(0x152)]?{'confirmationDescription':_0x4e5549[_0x50786d(0x152)]}:{},'helpExtra':_0x4e5549[_0x50786d(0x168)],'flags':[CODE_FLAG,{...PARAMS_FLAG,'description':_0x4e5549[_0x50786d(0x16a)]}],'validate':async _0x159c92=>{const _0xc188f7=_0x50786d;_0x4e5549[_0xc188f7(0x1ae)]&&requireAnyOf(_0x159c92,['params'],_0x4be3fd),_0x4e5549[_0xc188f7(0x190)]===_0xc188f7(0x17d)&&parseBatchCreateItemsFromParams(parseJsonParamsValue(_0x159c92[_0xc188f7(0x14d)](_0xc188f7(0x15d)))),_0x4e5549[_0xc188f7(0x190)]===_0xc188f7(0x186)&&parseUpdateIdsFromParams(parseJsonParams(_0x159c92[_0xc188f7(0x14d)](_0xc188f7(0x15d)))??{});},async 'execute'(_0x3087d9){const _0x29b13b=_0x50786d,_0x456736=_0x3087d9[_0x29b13b(0x14d)](_0x29b13b(0x1a7)),_0x41d20d=_0x4e5549[_0x29b13b(0x190)]===_0x29b13b(0x17d)?parseBatchCreateItemsFromParams(parseJsonParamsValue(_0x3087d9[_0x29b13b(0x14d)](_0x29b13b(0x15d)))):parseJsonParams(_0x3087d9[_0x29b13b(0x14d)](_0x29b13b(0x15d)))??{},_0x3ea5ec=_0x4e5549[_0x29b13b(0x190)]===_0x29b13b(0x186)?parseUpdateIdsFromParams(_0x41d20d):undefined,_0x54c088=_0x3ea5ec?normalizeUpdateParamsForRuntime(_0x41d20d,_0x3ea5ec):_0x41d20d,_0x5c5a77=Date[_0x29b13b(0x18b)](),_0x2fb8e9=await executeData(_0x456736,_0x4e5549[_0x29b13b(0x190)],_0x54c088),_0x1af381=Date['now']()-_0x5c5a77,_0x30f02b=_0x3ea5ec&&_0x3ea5ec[_0x29b13b(0x16f)]>0x1?buildBatchUpdateResult(_0x3ea5ec,_0x2fb8e9):_0x2fb8e9;return{'ok':!![],'data':{'result':_0x30f02b,'elapsed':_0x1af381},'message':'data\x20'+_0x4e5549[_0x29b13b(0x198)]+'\x20completed\x20in\x20'+_0x1af381+'ms'};}};return _0x4e5549['risk']!==_0x50786d(0x180)&&(_0x5a5642['dryRun']=async _0x1d077e=>{const _0x34a162=_0x50786d,_0x33652f=_0x1d077e[_0x34a162(0x14d)](_0x34a162(0x1a7)),_0x1ae985=_0x4e5549['operation']==='batchCreate'?parseBatchCreateItemsFromParams(parseJsonParamsValue(_0x1d077e[_0x34a162(0x14d)](_0x34a162(0x15d)))):parseJsonParams(_0x1d077e[_0x34a162(0x14d)](_0x34a162(0x15d)))??{};let _0x424ef3=_0x1ae985;if(_0x4e5549[_0x34a162(0x190)]===_0x34a162(0x186)){const _0x2b01a5=parseUpdateIdsFromParams(_0x1ae985);_0x424ef3=normalizeUpdateParamsForRuntime(_0x1ae985,_0x2b01a5);}return dryRun('POST',_0x34a162(0x17f)+_0x33652f+'/'+_0x4e5549[_0x34a162(0x190)])[_0x34a162(0x185)](_0x424ef3)[_0x34a162(0x1a8)](_0x34a162(0x174)+_0x4e5549[_0x34a162(0x198)]+_0x34a162(0x1ac)+_0x33652f)[_0x34a162(0x196)]();}),_0x5a5642;}export const dataDefinitions=specs[a25_0x239022(0x19f)](makeDataCommand);function buildBatchUpdateResult(_0x20c0d9,_0x1229eb){const _0xb8656=a25_0x239022;return{'operation':_0xb8656(0x186),'mode':_0xb8656(0x177),'ids':_0x20c0d9,'total':_0x20c0d9[_0xb8656(0x16f)],'result':_0x1229eb};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a26_0x5c783d=a26_0x48f9;function a26_0x48f9(_0x131978,_0x172449){_0x131978=_0x131978-0x178;const _0x10a6ce=a26_0x10a6();let _0x48f9e8=_0x10a6ce[_0x131978];return _0x48f9e8;}(function(_0x17de89,_0x4d62aa){const _0x15c29c=a26_0x48f9,_0x3b1a27=_0x17de89();while(!![]){try{const _0x279ac6=-parseInt(_0x15c29c(0x1b3))/0x1*(-parseInt(_0x15c29c(0x18e))/0x2)+-parseInt(_0x15c29c(0x178))/0x3+parseInt(_0x15c29c(0x17e))/0x4+parseInt(_0x15c29c(0x1b6))/0x5*(-parseInt(_0x15c29c(0x1b5))/0x6)+-parseInt(_0x15c29c(0x192))/0x7+-parseInt(_0x15c29c(0x1ba))/0x8+-parseInt(_0x15c29c(0x182))/0x9*(-parseInt(_0x15c29c(0x18d))/0xa);if(_0x279ac6===_0x4d62aa)break;else _0x3b1a27['push'](_0x3b1a27['shift']());}catch(_0x23ea9e){_0x3b1a27['push'](_0x3b1a27['shift']());}}}(a26_0x10a6,0x57eae));import{getDatasetDetail,listDatasets}from'../../core/api-client.js';import{CODE_FLAG}from'../../commands/common/flags.js';function normalizeField(_0xac8a8){const _0x3316be=a26_0x48f9;if(_0xac8a8['deleted'])return null;const _0xc15efd=Boolean(_0xac8a8[_0x3316be(0x1a9)]!==undefined||_0xac8a8[_0x3316be(0x17b)]!==undefined);let _0x581636={};if(!_0xc15efd&&typeof _0xac8a8[_0x3316be(0x1b1)]==='string')try{_0x581636=JSON[_0x3316be(0x1bb)](_0xac8a8[_0x3316be(0x1b1)]);}catch{}const _0x4577fa=_0xc15efd?_0xac8a8[_0x3316be(0x1b2)]:_0xac8a8[_0x3316be(0x196)],_0x4b8a5b=_0xc15efd?_0xac8a8['displayName']:_0xac8a8['name'],_0x3834f9=_0xc15efd?_0xac8a8[_0x3316be(0x17b)]:_0xac8a8[_0x3316be(0x1a8)]||_0xac8a8[_0x3316be(0x180)],_0x4d5bbc=_0xc15efd?_0xac8a8[_0x3316be(0x194)]===!![]:_0x581636[_0x3316be(0x194)]===!![],_0x37a87c=_0xc15efd?_0xac8a8['required']===!![]:_0x581636['required']===!![],_0x69712=_0xc15efd?_0xac8a8['options']??null:_0x581636[_0x3316be(0x17f)]??null,_0x168654={'name':_0x4577fa,'displayName':_0x4b8a5b||_0x4577fa,'type':_0x3834f9,'dbType':_0xac8a8[_0x3316be(0x1b4)],'pk':_0x4d5bbc,'required':_0x37a87c,'description':_0xac8a8[_0x3316be(0x198)]||undefined};return Array[_0x3316be(0x18c)](_0x69712)&&_0x69712[_0x3316be(0x199)]>0x0&&(_0x168654[_0x3316be(0x17f)]=_0x69712),_0x168654;}function parseJsonMaybe(_0x210a55){const _0x2253f3=a26_0x48f9;if(typeof _0x210a55!==_0x2253f3(0x1bd))return _0x210a55;try{return JSON[_0x2253f3(0x1bb)](_0x210a55);}catch{return _0x210a55;}}function normalizeOperationEntry(_0x1a8329,_0x3b227c){const _0x8d3639=a26_0x48f9;if(!_0x3b227c||typeof _0x3b227c!==_0x8d3639(0x1a3))return null;if(!_0x3b227c[_0x8d3639(0x1a2)]||!_0x3b227c[_0x8d3639(0x19b)])return null;const _0x2c9053={'name':_0x1a8329,'method':_0x3b227c[_0x8d3639(0x1a2)],'path':_0x3b227c[_0x8d3639(0x19b)]};if(_0x3b227c[_0x8d3639(0x1b0)])_0x2c9053['host']=_0x3b227c[_0x8d3639(0x1b0)];if(_0x3b227c[_0x8d3639(0x185)]!=null)_0x2c9053[_0x8d3639(0x185)]=parseJsonMaybe(_0x3b227c['requestBody']);if(_0x3b227c[_0x8d3639(0x1b8)]!=null)_0x2c9053[_0x8d3639(0x1b8)]=parseJsonMaybe(_0x3b227c['responseBody']);if(_0x3b227c[_0x8d3639(0x1a7)]!=null)_0x2c9053['beforeScriptId']=_0x3b227c[_0x8d3639(0x1a7)];if(_0x3b227c['afterScriptId']!=null)_0x2c9053['afterScriptId']=_0x3b227c[_0x8d3639(0x193)];if(Array['isArray'](_0x3b227c[_0x8d3639(0x186)]))_0x2c9053[_0x8d3639(0x186)]=_0x3b227c[_0x8d3639(0x186)];if(Array[_0x8d3639(0x18c)](_0x3b227c[_0x8d3639(0x195)]))_0x2c9053[_0x8d3639(0x195)]=_0x3b227c['responseFields'];return _0x2c9053;}function summarizeDbtable(_0xf0136e){const _0x1046f4=a26_0x48f9,_0x5661d8={},_0x58b794=[_0x1046f4(0x1be),'dbName','tableName','datasetKey','pkField',_0x1046f4(0x1ae),'logicField',_0x1046f4(0x1a6),_0x1046f4(0x1ab),'creatorIdField',_0x1046f4(0x1b7),_0x1046f4(0x1bc),_0x1046f4(0x1a0),'labelField','dblinkInfoDTO'];for(const _0x5a4199 of _0x58b794){if(_0xf0136e[_0x5a4199]!==undefined)_0x5661d8[_0x5a4199]=_0xf0136e[_0x5a4199];}return typeof _0x5661d8['allFields']===_0x1046f4(0x1bd)&&_0x5661d8[_0x1046f4(0x1ae)][_0x1046f4(0x199)]>0x0&&(_0x5661d8[_0x1046f4(0x18b)]=_0x5661d8[_0x1046f4(0x1ae)][_0x1046f4(0x1af)](',')[_0x1046f4(0x1b9)](_0xf8c277=>_0xf8c277[_0x1046f4(0x17c)]())[_0x1046f4(0x19c)](Boolean)),_0x5661d8;}function normalizeRelatedPages(_0xa977d1){const _0xd055c=a26_0x48f9;if(!Array[_0xd055c(0x18c)](_0xa977d1))return[];return _0xa977d1[_0xd055c(0x19c)](_0x4fa3ec=>_0x4fa3ec&&typeof _0x4fa3ec===_0xd055c(0x1a3))[_0xd055c(0x1b9)](_0x59d197=>({'id':_0x59d197['id'],'type':_0x59d197[_0xd055c(0x1a8)],'code':_0x59d197[_0xd055c(0x196)],'title':_0x59d197['title'],'deleted':_0x59d197[_0xd055c(0x184)]===!![]}));}function normalizeFallbackFieldName(_0x4512bd,_0x5e1108){const _0x27656=a26_0x48f9,_0x2966e0=_0x4512bd[_0x27656(0x17c)]();if(!_0x2966e0)return null;return{'name':_0x2966e0,'displayName':_0x2966e0,'type':undefined,'dbType':undefined,'pk':_0x2966e0===_0x5e1108,'required':![],'description':undefined};}async function loadListFieldFallback(_0x5260cc,_0x5a2608){const _0x1755cf=a26_0x48f9;if(!_0x5260cc||!_0x5a2608)return[];try{const _0x504eee=await listDatasets(_0x5260cc,{'code':_0x5a2608}),_0x14956e=_0x504eee[_0x1755cf(0x19f)](_0x24d699=>_0x24d699['code']===_0x5a2608)??_0x504eee[0x0],_0x4da509=_0x14956e?.['dbtableConfig']??{},_0xad0e5e=typeof _0x4da509[_0x1755cf(0x1ae)]===_0x1755cf(0x1bd)?_0x4da509[_0x1755cf(0x1ae)]['split'](','):[];return _0xad0e5e['map'](_0x2b4e2d=>normalizeFallbackFieldName(_0x2b4e2d,_0x4da509[_0x1755cf(0x194)]))['filter'](_0x51706e=>_0x51706e!==null);}catch{return[];}}export const datasetDetail={'service':a26_0x5c783d(0x18a),'command':a26_0x5c783d(0x19a),'description':a26_0x5c783d(0x1a4),'risk':'read','flags':[CODE_FLAG],async 'execute'(_0x2470d7){const _0x50e07d=a26_0x5c783d,_0xc8edd1=await getDatasetDetail(_0x2470d7[_0x50e07d(0x189)](_0x50e07d(0x196))),_0x36942c=Array[_0x50e07d(0x18c)](_0xc8edd1[_0x50e07d(0x190)])?_0xc8edd1[_0x50e07d(0x190)]:Array['isArray'](_0xc8edd1[_0x50e07d(0x1ac)])?_0xc8edd1[_0x50e07d(0x1ac)]:[];let _0x35e7e8=_0x36942c[_0x50e07d(0x1b9)](_0xa3cccd=>normalizeField(_0xa3cccd))[_0x50e07d(0x19c)](_0x9339f6=>_0x9339f6!==null);_0x35e7e8[_0x50e07d(0x199)]===0x0&&(_0x35e7e8=await loadListFieldFallback(_0x2470d7[_0x50e07d(0x19e)],_0x2470d7[_0x50e07d(0x189)](_0x50e07d(0x196))));const _0x1637fd=_0xc8edd1[_0x50e07d(0x17d)]??{},_0x1691b1=[];for(const [_0x51bac9,_0x317d9f]of Object[_0x50e07d(0x191)](_0x1637fd)){const _0x57b236=normalizeOperationEntry(_0x51bac9,_0x317d9f);if(_0x57b236)_0x1691b1[_0x50e07d(0x19d)](_0x57b236);}const _0xc8c045=_0xc8edd1[_0x50e07d(0x188)]??{},_0x5eea16=_0xc8edd1['dataset']??{},_0x5a7659=_0xc8c045['dbId']!=null?{'id':_0xc8c045[_0x50e07d(0x1be)],'name':_0xc8c045['dbName']??null}:undefined;let _0x412057;return typeof _0xc8edd1[_0x50e07d(0x1b1)]===_0x50e07d(0x1bd)&&(_0x412057=parseJsonMaybe(_0xc8edd1[_0x50e07d(0x1b1)])),{'ok':!![],'data':{'id':_0xc8edd1[_0x50e07d(0x187)]??_0xc8edd1['id'],'name':_0xc8edd1['name'],'code':_0xc8edd1[_0x50e07d(0x179)]||_0xc8edd1[_0x50e07d(0x196)],'doVersion':_0xc8edd1[_0x50e07d(0x183)],'description':_0xc8edd1[_0x50e07d(0x198)]||_0x5eea16[_0x50e07d(0x17a)]||undefined,'source':_0xc8edd1['source']||_0x5eea16['sourceType'],'table':_0xc8c045[_0x50e07d(0x197)]||_0x5eea16[_0x50e07d(0x197)],'datasetKey':_0xc8c045[_0x50e07d(0x1a1)],'pk':_0xc8c045['pkField'],'db':_0x5a7659,'dbtable':summarizeDbtable(_0xc8c045),'fields':_0x35e7e8,'operations':_0x1691b1,'indexes':Array['isArray'](_0x5eea16['indexes'])?_0x5eea16[_0x50e07d(0x1a5)]:[],'relations':_0xc8edd1[_0x50e07d(0x1ad)]??null,'relatedPages':normalizeRelatedPages(_0xc8edd1['relatedPageInfoList']),...Array[_0x50e07d(0x18c)](_0xc8edd1[_0x50e07d(0x1aa)])?{'columnCodeListWithDeleted':_0xc8edd1[_0x50e07d(0x1aa)]}:{},'formatRules':Array['isArray'](_0xc8edd1['formatRules'])?_0xc8edd1[_0x50e07d(0x181)]:[],'validateRules':Array[_0x50e07d(0x18c)](_0xc8edd1['validateRules'])?_0xc8edd1[_0x50e07d(0x18f)]:[],..._0x412057!==undefined?{'extend':_0x412057}:{},'stats':{'fieldCount':_0x35e7e8['length'],'operationCount':_0x1691b1[_0x50e07d(0x199)]}}};}};function a26_0x10a6(){const _0x31bb28=['operations','558692zvkqxJ','options','dataType','formatRules','18YrpgdA','doVersion','deleted','requestBody','requestFields','modelId','dbtableConfig','str','dataset','allFieldNames','isArray','7475080RKdtMy','2RoUytj','validateRules','fields','entries','3541125XMsYUy','afterScriptId','pkField','responseFields','code','tableName','description','length','detail','path','filter','push','appCode','find','modifierNameField','datasetKey','method','object','Get\x20dataset\x20detail\x20including\x20fields,\x20relations,\x20and\x20operations','indexes','createTimeField','beforeScriptId','type','displayName','columnCodeListWithDeleted','updateTimeField','properties','relations','allFields','split','host','extend','name','557611fckHxZ','dbType','1959042hihWeu','10XimfWH','creatorNameField','responseBody','map','3521456CnmEGn','parse','modifierIdField','string','dbId','699357rNwxas','modelCode','tableComment','doType','trim'];a26_0x10a6=function(){return _0x31bb28;};return a26_0x10a6();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0xc956cf,_0x4b7f6a){const _0x57490d=a27_0x5a30,_0x471e75=_0xc956cf();while(!![]){try{const _0xe2ff09=parseInt(_0x57490d(0x1f8))/0x1*(parseInt(_0x57490d(0x1fe))/0x2)+-parseInt(_0x57490d(0x1fd))/0x3*(parseInt(_0x57490d(0x1fc))/0x4)+-parseInt(_0x57490d(0x1f4))/0x5*(parseInt(_0x57490d(0x1f9))/0x6)+parseInt(_0x57490d(0x1f5))/0x7+parseInt(_0x57490d(0x1fa))/0x8*(parseInt(_0x57490d(0x1f7))/0x9)+-parseInt(_0x57490d(0x1ff))/0xa*(parseInt(_0x57490d(0x1fb))/0xb)+parseInt(_0x57490d(0x1f6))/0xc;if(_0xe2ff09===_0x4b7f6a)break;else _0x471e75['push'](_0x471e75['shift']());}catch(_0x445346){_0x471e75['push'](_0x471e75['shift']());}}}(a27_0x1310,0x909a1));import{datasetList}from'../../commands/dataset/list.js';import{datasetDetail}from'../../commands/dataset/detail.js';import{datasetSdkDoc}from'../../commands/dataset/sdk-doc.js';function a27_0x1310(){const _0x4e4206=['881150MgAuRx','15FoJchy','2874620qVGrMg','2219472YsrMUt','16893NhKTEH','1NxWaKg','535410pOJfOI','2080vzCPOo','33nalJbf','8uZfprr','1646751YtEFQd','2277074hLSBDn'];a27_0x1310=function(){return _0x4e4206;};return a27_0x1310();}function a27_0x5a30(_0x1e0f51,_0x227f80){_0x1e0f51=_0x1e0f51-0x1f4;const _0x1310b8=a27_0x1310();let _0x5a306b=_0x1310b8[_0x1e0f51];return _0x5a306b;}export const datasetDefinitions=[datasetList,datasetDetail,datasetSdkDoc];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a28_0x56dd(){const _0x1c9d4c=['description','source','List\x20datasets\x20in\x20the\x20app\x20(supports\x20server-side\x20name/code\x20filtering)','232205qlXwsv','datasetKey','allFields','code','76ceKgud','string','1655298TwlzLI','9198010JWLyXR','8GdatFT','28702956aajZAk','map','list','read','Filter\x20by\x20dataset\x20code\x20(server-side\x20exact\x20match)','name','1062181ivBmGc','3393502cpJJJU','str','dbtableConfig','1687JLdEUV','tableName','pkField','trim','22KqGoZD','3QZhMRy','21522WCLaOP','appCode'];a28_0x56dd=function(){return _0x1c9d4c;};return a28_0x56dd();}const a28_0x5ae78e=a28_0x46b6;(function(_0x3d0ec8,_0x4c5864){const _0x531ccb=a28_0x46b6,_0x1142c3=_0x3d0ec8();while(!![]){try{const _0x195e72=-parseInt(_0x531ccb(0x194))/0x1+-parseInt(_0x531ccb(0x195))/0x2*(-parseInt(_0x531ccb(0x17f))/0x3)+-parseInt(_0x531ccb(0x189))/0x4*(parseInt(_0x531ccb(0x185))/0x5)+-parseInt(_0x531ccb(0x180))/0x6*(-parseInt(_0x531ccb(0x198))/0x7)+parseInt(_0x531ccb(0x18d))/0x8*(-parseInt(_0x531ccb(0x18b))/0x9)+-parseInt(_0x531ccb(0x18c))/0xa*(parseInt(_0x531ccb(0x17e))/0xb)+parseInt(_0x531ccb(0x18e))/0xc;if(_0x195e72===_0x4c5864)break;else _0x1142c3['push'](_0x1142c3['shift']());}catch(_0x5108ae){_0x1142c3['push'](_0x1142c3['shift']());}}}(a28_0x56dd,0xf07d7));import{listDatasets}from'../../core/api-client.js';import{CODE_FLAG}from'../../commands/common/flags.js';function a28_0x46b6(_0x403696,_0x58b93e){_0x403696=_0x403696-0x17d;const _0x56dd1d=a28_0x56dd();let _0x46b6d9=_0x56dd1d[_0x403696];return _0x46b6d9;}export const datasetList={'service':'dataset','command':a28_0x5ae78e(0x190),'description':a28_0x5ae78e(0x184),'risk':a28_0x5ae78e(0x191),'flags':[{'name':a28_0x5ae78e(0x193),'type':a28_0x5ae78e(0x18a),'description':'Filter\x20by\x20dataset\x20name\x20(server-side\x20fuzzy\x20match)'},{...CODE_FLAG,'required':![],'description':a28_0x5ae78e(0x192)}],async 'execute'(_0xd646d4){const _0x1e540f=a28_0x5ae78e,_0x1ab5b0=_0xd646d4[_0x1e540f(0x196)](_0x1e540f(0x193)),_0x29b31b=_0xd646d4[_0x1e540f(0x196)](_0x1e540f(0x188)),_0x2999a6=await listDatasets(_0xd646d4[_0x1e540f(0x181)],{..._0x1ab5b0&&{'name':_0x1ab5b0},..._0x29b31b&&{'code':_0x29b31b}});return{'ok':!![],'data':{'total':_0x2999a6['length'],'datasets':_0x2999a6[_0x1e540f(0x18f)](_0x49a468=>{const _0x27ad67=_0x1e540f,_0x3084a2=_0x49a468[_0x27ad67(0x197)]??{};return{'id':_0x49a468['id'],'code':_0x49a468[_0x27ad67(0x188)],'name':_0x49a468[_0x27ad67(0x193)],'source':_0x49a468[_0x27ad67(0x183)],'description':_0x49a468[_0x27ad67(0x182)],'table':_0x3084a2[_0x27ad67(0x199)],'datasetKey':_0x3084a2[_0x27ad67(0x186)],'pk':_0x3084a2[_0x27ad67(0x19a)],'fields':_0x3084a2[_0x27ad67(0x187)]?_0x3084a2['allFields']['split'](',')[_0x27ad67(0x18f)](_0x4a0090=>_0x4a0090[_0x27ad67(0x17d)]()):[]};})}};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a29_0x449908=a29_0x25d1;(function(_0x2d3076,_0x5ac5de){const _0x3e4fd8=a29_0x25d1,_0x14554b=_0x2d3076();while(!![]){try{const _0x4e43c1=parseInt(_0x3e4fd8(0xd8))/0x1+-parseInt(_0x3e4fd8(0xd7))/0x2*(-parseInt(_0x3e4fd8(0xd5))/0x3)+parseInt(_0x3e4fd8(0xd6))/0x4+-parseInt(_0x3e4fd8(0xd1))/0x5+-parseInt(_0x3e4fd8(0xda))/0x6+-parseInt(_0x3e4fd8(0xd3))/0x7+parseInt(_0x3e4fd8(0xd2))/0x8;if(_0x4e43c1===_0x5ac5de)break;else _0x14554b['push'](_0x14554b['shift']());}catch(_0x298877){_0x14554b['push'](_0x14554b['shift']());}}}(a29_0x589e,0x99ee7));function a29_0x25d1(_0x3539e8,_0x4ea174){_0x3539e8=_0x3539e8-0xcd;const _0x589e87=a29_0x589e();let _0x25d11c=_0x589e87[_0x3539e8];return _0x25d11c;}import{getDatasetSdkUsageDoc}from'../../core/api-client.js';import{CODE_FLAG}from'../../commands/common/flags.js';const DEFAULT_MARKDOWN=a29_0x449908(0xd0);export function formatDatasetSdkMarkdown(_0x18bde9){const _0xe8fc3e=a29_0x449908,_0x167f81=typeof _0x18bde9==='string'?_0x18bde9[_0xe8fc3e(0xdb)]():'';return _0x167f81||DEFAULT_MARKDOWN;}function a29_0x589e(){const _0x28d3b3=['str','dataset','read','Dataset\x20code\x20(32\x20characters).\x20Numeric\x20dataset\x20IDs\x20are\x20not\x20accepted.','#\x20Dataset\x20SDK\x20Usage\x20Documentation\x0a\x0aNo\x20SDK\x20usage\x20documentation\x20is\x20available.','332105qfQhUh','8311512EtQhQn','7376642xJRSsH','Get\x20SDK\x20usage\x20markdown\x20for\x20a\x20dataset\x20code','3VNXGWa','2216328ODaTbE','888970pqPPrG','374856QAPjqm','appCode','3969792eGCGUz','trim'];a29_0x589e=function(){return _0x28d3b3;};return a29_0x589e();}export const datasetSdkDoc={'service':a29_0x449908(0xcd),'command':'sdk-doc','description':a29_0x449908(0xd4),'risk':a29_0x449908(0xce),'flags':[{...CODE_FLAG,'description':a29_0x449908(0xcf)}],async 'execute'(_0x2c09b8){const _0x87a1e6=a29_0x449908,_0x129738=_0x2c09b8[_0x87a1e6(0xdc)]('code'),_0x117f77=await getDatasetSdkUsageDoc(_0x129738,_0x2c09b8[_0x87a1e6(0xd9)]);return{'ok':!![],'data':{'code':_0x129738,'appCode':_0x2c09b8[_0x87a1e6(0xd9)],'markdown':formatDatasetSdkMarkdown(_0x117f77)}};}};
|
package/lib/commands/doctor.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function a30_0x2add(_0x5f54b1,_0x57ad66){_0x5f54b1=_0x5f54b1-0xd7;const _0x455670=a30_0x4556();let _0x2addc8=_0x455670[_0x5f54b1];return _0x2addc8;}const a30_0xe33880=a30_0x2add;(function(_0x4e0cd4,_0x232c83){const _0x574bd0=a30_0x2add,_0x5f5575=_0x4e0cd4();while(!![]){try{const _0x147292=parseInt(_0x574bd0(0xda))/0x1+parseInt(_0x574bd0(0x135))/0x2*(parseInt(_0x574bd0(0x12b))/0x3)+-parseInt(_0x574bd0(0x122))/0x4+-parseInt(_0x574bd0(0x117))/0x5*(parseInt(_0x574bd0(0xfa))/0x6)+-parseInt(_0x574bd0(0x113))/0x7+parseInt(_0x574bd0(0x141))/0x8*(parseInt(_0x574bd0(0xf6))/0x9)+parseInt(_0x574bd0(0x110))/0xa*(parseInt(_0x574bd0(0xe0))/0xb);if(_0x147292===_0x232c83)break;else _0x5f5575['push'](_0x5f5575['shift']());}catch(_0x217638){_0x5f5575['push'](_0x5f5575['shift']());}}}(a30_0x4556,0x9c367));import a30_0x22eb2f from'chalk';import{CLI_BIN_NAME}from'../constant/cli.js';import{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';import{getCliVersion}from'../utils/version.js';import{getApiDomain,getKbDomain,getRuntimeDomain,getSkillDomain,getUserDomain}from'../constant/domain.js';function a30_0x4556(){const _0x245cd3=['\x20\x20Reason:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','4707072IPNvVd','\x20\x20verbose:\x20\x20\x20\x20\x20\x20\x20\x20\x20','accessKey','\x20\x20Auth','ClientAk','(missing)','✓\x20current','\x20\x20region:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20config','471VgogHx','includes','read','(not\x20found)','global','repeat','\x20\x20Service\x20Tree','\x20\x20Config\x20JSON','\x20\x20State:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','reason','14660Pgzcts','join','✗\x20Invalid','(no\x20file)','length','\x20\x20appCode:\x20\x20\x20\x20\x20\x20\x20\x20\x20','call','projectConfig','defaultApp','prototype','\x20\x20Mode:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20─','459296UVVoKT','platform','\x20\x20CLI\x20Version:\x20\x20\x20\x20\x20','(unnamed)','format','621273iMghvJ','padEnd','\x20\x20Global:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','repairCommand','\x20\x20accessKey:\x20\x20\x20\x20\x20\x20\x20','✓\x20Loaded','7634DcCzMp','\x20\x20currentApp:\x20\x20\x20\x20\x20\x20','serviceCount','inherit','hasOwnProperty','message','Project','currentApp','env','✓\x20Valid\x20JSON','\x20+\x20','globalConfig','empty','\x20\x20Config\x20Files','\x20(accessKey)','packageVersion','\x20\x20pageSize:\x20\x20\x20\x20\x20\x20\x20\x20','check','✗\x20Invalid\x20JSON','version','arch','registryPath','27pKpcYj','log','verbose','doctor','6AkAYuh','\x20config\x20delete\x20inherit\x20--global','bold','\x20\x20skillDomain:\x20\x20\x20\x20\x20','current','\x20\x20apiDomain:\x20\x20\x20\x20\x20\x20\x20','(not\x20set)','raw','⚠\x20Empty','\x20\x20app\x20locale:\x20\x20\x20\x20\x20\x20','services','appCode','project','Diagnose\x20CLI\x20configuration\x20and\x20environment','(default)','commandCount','\x20\x20Commands:\x20\x20\x20\x20\x20\x20\x20\x20','gray','\x20\x20format:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','skillVersion','riskLevel','\x20\x20Project:\x20\x20\x20\x20\x20\x20\x20\x20\x20','5480qiUQEf','\x20\x20defaultApp:\x20\x20\x20\x20\x20\x20','\x20\x20Status:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','1447649IEccrH','\x20\x20Installed\x20Path:\x20\x20','\x20\x20Merged\x20Config','yellow','1506045DVibbo','\x20commands)','\x20\x20Built-in\x20Skill','(none)','green','status','state','ignored\x20in\x20','\x20Imported\x20from:\x20','red'];a30_0x4556=function(){return _0x245cd3;};return a30_0x4556();}import{normalizeLovrabetRegion}from'../constant/region.js';import{buildConfigFromFlags,initGlobalEnvironment,getProjectConfigPath,getGlobalConfigPath,inspectCliConfigJsonFile,loadRawConfigLayers}from'../context.js';import{AUTH_MODE}from'../constant/auth-mode.js';import{inspectServiceRegistry}from'../commands/service/registry.js';import{inspectBuiltinSkill}from'../skills/builtin-skill.js';async function execute(_0x366f94){const _0x452362=a30_0x2add,_0x1fa624=getCliVersion(),_0x5b323a=buildConfigFromFlags({});await initGlobalEnvironment(_0x5b323a),console['log'](),console['log'](a30_0x22eb2f['bold'](CLI_BIN_NAME+'\x20doctor')),console[_0x452362(0xf7)](a30_0x22eb2f[_0x452362(0x10b)]('─'[_0x452362(0x130)](0x32))),console['log'](_0x452362(0xd7)+_0x1fa624),console['log']('\x20\x20Node:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+process[_0x452362(0xf3)]),console['log']('\x20\x20Platform:\x20\x20\x20\x20\x20\x20\x20\x20'+process[_0x452362(0x142)]+'\x20'+process[_0x452362(0xf4)]);const _0x4cf8f0=inspectBuiltinSkill();console[_0x452362(0xf7)](),console['log'](a30_0x22eb2f['bold'](_0x452362(0x119))),console[_0x452362(0xf7)](a30_0x22eb2f[_0x452362(0x10b)](_0x452362(0x140)[_0x452362(0x130)](0x1e))),console[_0x452362(0xf7)](_0x452362(0x133)+(_0x4cf8f0['state']===_0x452362(0xfe)?a30_0x22eb2f[_0x452362(0x11b)](_0x452362(0x128)):a30_0x22eb2f[_0x452362(0x120)]('✗\x20'+_0x4cf8f0['state']))),console[_0x452362(0xf7)]('\x20\x20Package\x20Version:\x20'+_0x4cf8f0[_0x452362(0xef)]),console['log']('\x20\x20Skill\x20Version:\x20\x20\x20'+(_0x4cf8f0[_0x452362(0x10d)]||a30_0x22eb2f[_0x452362(0x10b)](_0x452362(0x127)))),console[_0x452362(0xf7)](_0x452362(0x114)+(_0x4cf8f0['installedPath']||a30_0x22eb2f[_0x452362(0x10b)]('(not\x20found)')));_0x4cf8f0[_0x452362(0x11d)]!==_0x452362(0xfe)&&console[_0x452362(0xf7)]('\x20\x20Repair:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+_0x4cf8f0[_0x452362(0xdd)]);_0x4cf8f0[_0x452362(0x134)]&&console[_0x452362(0xf7)](_0x452362(0x121)+_0x4cf8f0['reason']);console[_0x452362(0xf7)](),console[_0x452362(0xf7)](a30_0x22eb2f['bold'](_0x452362(0xed))),console[_0x452362(0xf7)](a30_0x22eb2f['gray'](_0x452362(0x140)[_0x452362(0x130)](0x1e)));const _0x18337f=getGlobalConfigPath(),_0x1ff8c4=getProjectConfigPath();console[_0x452362(0xf7)](_0x452362(0xdc)+(_0x18337f||a30_0x22eb2f[_0x452362(0x10b)]('(not\x20found)'))),console[_0x452362(0xf7)](_0x452362(0x10f)+(_0x1ff8c4||a30_0x22eb2f[_0x452362(0x10b)](_0x452362(0x12e)))),console['log'](),console[_0x452362(0xf7)](a30_0x22eb2f[_0x452362(0xfc)](_0x452362(0x132))),console['log'](a30_0x22eb2f['gray'](_0x452362(0x140)['repeat'](0x1e)));const _0x3581b3=(_0x2b91f2,_0x2b5dc2)=>{const _0xfd72f=_0x452362;if(!_0x2b5dc2){console[_0xfd72f(0xf7)]('\x20\x20'+_0x2b91f2[_0xfd72f(0xdb)](0x11)+'\x20'+a30_0x22eb2f['gray'](_0xfd72f(0x138)));return;}const _0x13ddfd=inspectCliConfigJsonFile(_0x2b5dc2);if(_0x13ddfd[_0xfd72f(0x11c)]==='ok')console[_0xfd72f(0xf7)]('\x20\x20'+_0x2b91f2['padEnd'](0x11)+'\x20'+a30_0x22eb2f[_0xfd72f(0x11b)](_0xfd72f(0xe9)));else{if(_0x13ddfd[_0xfd72f(0x11c)]==='empty')console['log']('\x20\x20'+_0x2b91f2['padEnd'](0x11)+'\x20'+a30_0x22eb2f['yellow']('⚠\x20Empty\x20(treated\x20as\x20{})'));else _0x13ddfd[_0xfd72f(0x11c)]==='missing'?console[_0xfd72f(0xf7)]('\x20\x20'+_0x2b91f2['padEnd'](0x11)+'\x20'+a30_0x22eb2f[_0xfd72f(0x10b)](_0xfd72f(0x127))):(console['log']('\x20\x20'+_0x2b91f2['padEnd'](0x11)+'\x20'+a30_0x22eb2f[_0xfd72f(0x120)](_0xfd72f(0xf2))),console['log']('\x20\x20'+''[_0xfd72f(0xdb)](0x11)+'\x20'+a30_0x22eb2f[_0xfd72f(0x120)](_0x13ddfd[_0xfd72f(0xe5)])));}};_0x3581b3('Global',_0x18337f),_0x3581b3(_0x452362(0xe6),_0x1ff8c4);const _0xe50d91=loadRawConfigLayers(),_0x14881e=[Object[_0x452362(0x13e)][_0x452362(0xe4)][_0x452362(0x13b)](_0xe50d91[_0x452362(0xeb)],_0x452362(0xe3))?_0x452362(0x12f):null,Object['prototype'][_0x452362(0xe4)][_0x452362(0x13b)](_0xe50d91[_0x452362(0x13c)],_0x452362(0xe3))?_0x452362(0x106):null]['filter'](Boolean);_0x14881e[_0x452362(0x139)]>0x0&&(console[_0x452362(0xf7)]('\x20\x20Legacy\x20inherit:\x20\x20\x20'+a30_0x22eb2f[_0x452362(0x116)](_0x452362(0x11e)+_0x14881e[_0x452362(0x136)](_0x452362(0xea))+_0x452362(0x12a))),_0x14881e[_0x452362(0x12c)](_0x452362(0x106))&&console['log']('\x20\x20Repair\x20project:\x20\x20\x20'+CLI_BIN_NAME+'\x20config\x20delete\x20inherit'),_0x14881e[_0x452362(0x12c)]('global')&&console[_0x452362(0xf7)]('\x20\x20Repair\x20global:\x20\x20\x20\x20'+CLI_BIN_NAME+_0x452362(0xfb)));console[_0x452362(0xf7)](),console[_0x452362(0xf7)](a30_0x22eb2f['bold'](_0x452362(0x115))),console[_0x452362(0xf7)](a30_0x22eb2f[_0x452362(0x10b)](_0x452362(0x140)[_0x452362(0x130)](0x1e))),console[_0x452362(0xf7)](_0x452362(0x13a)+(_0x5b323a[_0x452362(0x105)]||a30_0x22eb2f[_0x452362(0x120)](_0x452362(0x100)))),console[_0x452362(0xf7)]('\x20\x20env:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+_0x5b323a[_0x452362(0xe8)]),console['log'](_0x452362(0x129)+normalizeLovrabetRegion(_0x5b323a[_0x452362(0x101)]['region'])),console['log'](_0x452362(0x103)+_0x5b323a['locale']),console['log'](_0x452362(0x111)+(_0x5b323a[_0x452362(0x13d)]||a30_0x22eb2f[_0x452362(0x10b)](_0x452362(0x11a)))),console['log'](_0x452362(0xe1)+(_0x5b323a[_0x452362(0xe7)]||a30_0x22eb2f['gray']('(none)'))),console[_0x452362(0xf7)](_0x452362(0x10c)+(_0x5b323a[_0x452362(0xd9)]||a30_0x22eb2f[_0x452362(0x10b)]('(default:\x20'+DEFAULT_CONFIG_VALUES[_0x452362(0xd9)]+')'))),console[_0x452362(0xf7)](_0x452362(0xf0)+(_0x5b323a['pageSize']??a30_0x22eb2f[_0x452362(0x10b)](_0x452362(0x108)))),console[_0x452362(0xf7)]('\x20\x20riskLevel:\x20\x20\x20\x20\x20\x20\x20'+_0x5b323a[_0x452362(0x10e)]),console[_0x452362(0xf7)](_0x452362(0x123)+_0x5b323a[_0x452362(0xf8)]),console[_0x452362(0xf7)]('\x20\x20auth\x20(effective):\x20'+AUTH_MODE[_0x452362(0x126)]),console[_0x452362(0xf7)](_0x452362(0xde)+(_0x5b323a[_0x452362(0x124)]?a30_0x22eb2f[_0x452362(0x11b)]('(set,\x20length='+_0x5b323a[_0x452362(0x124)]['length']+')'):a30_0x22eb2f['gray'](_0x452362(0x11a)))),console[_0x452362(0xf7)](),console[_0x452362(0xf7)](a30_0x22eb2f['bold']('\x20\x20API\x20Endpoints')),console[_0x452362(0xf7)](a30_0x22eb2f[_0x452362(0x10b)](_0x452362(0x140)[_0x452362(0x130)](0x1e))),console[_0x452362(0xf7)](_0x452362(0xff)+getApiDomain()),console[_0x452362(0xf7)]('\x20\x20userDomain:\x20\x20\x20\x20\x20\x20'+getUserDomain()),console['log']('\x20\x20runtimeDomain:\x20\x20\x20'+getRuntimeDomain()),console[_0x452362(0xf7)](_0x452362(0xfd)+getSkillDomain()),console[_0x452362(0xf7)]('\x20\x20kbDomain:\x20\x20\x20\x20\x20\x20\x20\x20'+getKbDomain()),console[_0x452362(0xf7)](),console[_0x452362(0xf7)](a30_0x22eb2f['bold'](_0x452362(0x131))),console[_0x452362(0xf7)](a30_0x22eb2f[_0x452362(0x10b)]('\x20\x20─'[_0x452362(0x130)](0x1e)));const _0x128bab=inspectServiceRegistry();console['log']('\x20\x20Registry:\x20\x20\x20\x20\x20\x20\x20\x20'+_0x128bab[_0x452362(0xf5)]),console[_0x452362(0xf7)](_0x452362(0x112)+formatServiceRegistryStatus(_0x128bab)),console[_0x452362(0xf7)]('\x20\x20Services:\x20\x20\x20\x20\x20\x20\x20\x20'+_0x128bab[_0x452362(0xe2)]),console[_0x452362(0xf7)](_0x452362(0x10a)+_0x128bab['commandCount']);for(const _0x2587a2 of _0x128bab[_0x452362(0x104)]){console[_0x452362(0xf7)]('\x20\x20'+(_0x2587a2['serviceCode']+':')[_0x452362(0xdb)](0x11)+'\x20'+(_0x2587a2['name']||a30_0x22eb2f['gray'](_0x452362(0xd8)))+'\x20('+_0x2587a2[_0x452362(0x109)]+_0x452362(0x118)),console[_0x452362(0xf7)]('\x20\x20'+''['padEnd'](0x11)+_0x452362(0x11f)+_0x2587a2['source']['path']);}return console[_0x452362(0xf7)](),console[_0x452362(0xf7)](a30_0x22eb2f[_0x452362(0xfc)](_0x452362(0x125))),console[_0x452362(0xf7)](a30_0x22eb2f[_0x452362(0x10b)](_0x452362(0x140)[_0x452362(0x130)](0x1e))),console[_0x452362(0xf7)](_0x452362(0x13f)+a30_0x22eb2f['green'](AUTH_MODE['ClientAk']+_0x452362(0xee))),console['log']('\x20\x20Session\x20check:\x20\x20\x20'+a30_0x22eb2f[_0x452362(0x10b)]('(removed\x20—\x20cookie\x20auth\x20disabled)')),console['log'](),{'ok':!![]};}function formatServiceRegistryStatus(_0xacdcca){const _0x36b14d=a30_0x2add;if(_0xacdcca[_0x36b14d(0x11c)]==='ok')return a30_0x22eb2f[_0x36b14d(0x11b)](_0x36b14d(0xdf));if(_0xacdcca[_0x36b14d(0x11c)]==='missing')return a30_0x22eb2f[_0x36b14d(0x10b)]('(not\x20found)');if(_0xacdcca['status']===_0x36b14d(0xec))return a30_0x22eb2f[_0x36b14d(0x116)](_0x36b14d(0x102));return a30_0x22eb2f['red'](_0x36b14d(0x137)+(_0xacdcca[_0x36b14d(0xe5)]?':\x20'+_0xacdcca[_0x36b14d(0xe5)]:''));}export const doctorDefinition={'service':a30_0xe33880(0xf9),'command':a30_0xe33880(0xf1),'description':a30_0xe33880(0x107),'risk':a30_0xe33880(0x12d),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],'execute':execute};
|
|
1
|
+
const a30_0x19d718=a30_0x2e24;(function(_0x487fa3,_0x245fab){const _0x443d97=a30_0x2e24,_0x41a866=_0x487fa3();while(!![]){try{const _0x5e897e=-parseInt(_0x443d97(0x222))/0x1*(parseInt(_0x443d97(0x1d5))/0x2)+-parseInt(_0x443d97(0x1e0))/0x3+parseInt(_0x443d97(0x20b))/0x4*(parseInt(_0x443d97(0x216))/0x5)+parseInt(_0x443d97(0x1f6))/0x6+-parseInt(_0x443d97(0x1bf))/0x7*(parseInt(_0x443d97(0x1b5))/0x8)+-parseInt(_0x443d97(0x228))/0x9*(-parseInt(_0x443d97(0x22d))/0xa)+parseInt(_0x443d97(0x1da))/0xb*(-parseInt(_0x443d97(0x1c6))/0xc);if(_0x5e897e===_0x245fab)break;else _0x41a866['push'](_0x41a866['shift']());}catch(_0x31b0d3){_0x41a866['push'](_0x41a866['shift']());}}}(a30_0xeee4,0x645a6));import a30_0x3e8ff0 from'chalk';import{CLI_BIN_NAME}from'../constant/cli.js';import{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';import{getCliVersion}from'../utils/version.js';import{getApiDomain,getKbDomain,getRuntimeDomain,getSkillDomain,getUserDomain}from'../constant/domain.js';import{normalizeLovrabetRegion}from'../constant/region.js';import{buildConfigFromFlags,initGlobalEnvironment,getProjectConfigPath,getGlobalConfigPath,inspectCliConfigJsonFile,loadRawConfigLayers}from'../context.js';import{AUTH_MODE}from'../constant/auth-mode.js';function a30_0x2e24(_0x2eba20,_0x3c2241){_0x2eba20=_0x2eba20-0x1b0;const _0xeee40e=a30_0xeee4();let _0x2e2495=_0xeee40e[_0x2eba20];return _0x2e2495;}function a30_0xeee4(){const _0x1022ac=['\x20\x20Config\x20Files','globalConfig','registryPath','accessKey','8113970pGyDdd','\x20\x20Repair:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20userDomain:\x20\x20\x20\x20\x20\x20','skillVersion','current','\x20\x20Installed\x20Path:\x20\x20','\x20\x20Built-in\x20Skill','8oKahxU','\x20config\x20delete\x20inherit\x20--global','\x20\x20Platform:\x20\x20\x20\x20\x20\x20\x20\x20','\x20doctor','\x20config','empty','\x20(accessKey)','call','ClientAk','\x20\x20State:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','1277143eXOMkj','\x20\x20Country/Region\x20Configuration','hasOwnProperty','\x20\x20apiDomain:\x20\x20\x20\x20\x20\x20\x20','\x20\x20riskLevel:\x20\x20\x20\x20\x20\x20\x20','\x20\x20app\x20locale:\x20\x20\x20\x20\x20\x20','\x20\x20Package\x20Version:\x20','404844nSkmIr','platform','\x20\x20Routing\x20Configuration','\x20commands)','\x20\x20Services:\x20\x20\x20\x20\x20\x20\x20\x20','source','\x20\x20appCode:\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20format:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20Status:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','filter','log','\x20\x20CLI\x20Version:\x20\x20\x20\x20\x20','state','bold','repairCommand','2sAWRcg','green','(missing)','prototype','\x20\x20Legacy\x20inherit:\x20\x20\x20','11VYTEOf','locale','\x20+\x20','\x20\x20─','\x20\x20currentApp:\x20\x20\x20\x20\x20\x20','\x20Imported\x20from:\x20','1822788RsSZFl','\x20\x20Repair\x20global:\x20\x20\x20','⚠\x20Empty\x20(treated\x20as\x20{})','\x20\x20defaultApp:\x20\x20\x20\x20\x20\x20','\x20\x20Reason:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20kbDomain:\x20\x20\x20\x20\x20\x20\x20\x20','region','serviceCode','includes','format','(not\x20set)','\x20\x20runtimeDomain:\x20\x20\x20','red','project','✓\x20Loaded','message','arch','\x20\x20Node:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','services','\x20\x20Repair\x20project:\x20\x20\x20','(not\x20found)','global','621198YPWRBW','\x20config\x20delete\x20inherit','\x20\x20pageSize:\x20\x20\x20\x20\x20\x20\x20\x20','currentApp','verbose','\x20config\x20delete\x20routing\x20--global','\x20\x20Commands:\x20\x20\x20\x20\x20\x20\x20\x20','(removed\x20—\x20cookie\x20auth\x20disabled)','gray','repeat','length','\x20\x20auth\x20(effective):\x20','status','read','\x20\x20Service\x20Tree','✗\x20Invalid\x20JSON','\x20\x20Mode:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20config\x20delete\x20routing','pageSize','(default:\x20','yellow','4wAYRWt','(none)','raw','version','\x20\x20skillDomain:\x20\x20\x20\x20\x20','doctor','Global','packageVersion','padEnd','defaultApp','\x20\x20Project:\x20\x20\x20\x20\x20\x20\x20\x20\x20','2175620IMSrTG','\x20\x20verbose:\x20\x20\x20\x20\x20\x20\x20\x20\x20','(default)','commandCount','Unavailable\x20until\x20routing\x20configuration\x20is\x20repaired','⚠\x20Empty','\x20\x20Config\x20JSON','\x20\x20region:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','projectConfig','✗\x20Invalid','join','missing','115226ZHVULK','\x20\x20Repair\x20project:\x20\x20','inherit','\x20\x20Repair\x20global:\x20\x20\x20\x20','routing','\x20\x20Session\x20check:\x20\x20\x20','9HSJuXG'];a30_0xeee4=function(){return _0x1022ac;};return a30_0xeee4();}import{inspectServiceRegistry}from'../commands/service/registry.js';import{inspectBuiltinSkill}from'../skills/builtin-skill.js';async function execute(_0x528f43){const _0x1090d3=a30_0x2e24,_0x382403=getCliVersion(),_0x38987e=buildConfigFromFlags({});let _0x452130,_0x24da99;try{_0x452130=normalizeLovrabetRegion(_0x38987e[_0x1090d3(0x20d)][_0x1090d3(0x1e6)]);}catch(_0x53198d){_0x24da99=_0x53198d instanceof Error?_0x53198d:new Error(String(_0x53198d));}let _0x2443be;if(!_0x24da99)try{await initGlobalEnvironment(_0x38987e);}catch(_0x380900){_0x2443be=_0x380900 instanceof Error?_0x380900:new Error(String(_0x380900));}console['log'](),console[_0x1090d3(0x1d0)](a30_0x3e8ff0[_0x1090d3(0x1d3)](CLI_BIN_NAME+_0x1090d3(0x1b8))),console['log'](a30_0x3e8ff0[_0x1090d3(0x1fe)]('─'[_0x1090d3(0x1ff)](0x32))),console[_0x1090d3(0x1d0)](_0x1090d3(0x1d1)+_0x382403),console['log'](_0x1090d3(0x1f1)+process[_0x1090d3(0x20e)]),console[_0x1090d3(0x1d0)](_0x1090d3(0x1b7)+process[_0x1090d3(0x1c7)]+'\x20'+process[_0x1090d3(0x1f0)]);const _0x75117f=inspectBuiltinSkill();console[_0x1090d3(0x1d0)](),console[_0x1090d3(0x1d0)](a30_0x3e8ff0['bold'](_0x1090d3(0x1b4))),console['log'](a30_0x3e8ff0['gray'](_0x1090d3(0x1dd)[_0x1090d3(0x1ff)](0x1e))),console[_0x1090d3(0x1d0)](_0x1090d3(0x1be)+(_0x75117f[_0x1090d3(0x1d2)]==='current'?a30_0x3e8ff0[_0x1090d3(0x1d6)]('✓\x20current'):a30_0x3e8ff0[_0x1090d3(0x1ec)]('✗\x20'+_0x75117f[_0x1090d3(0x1d2)]))),console[_0x1090d3(0x1d0)](_0x1090d3(0x1c5)+_0x75117f[_0x1090d3(0x212)]),console[_0x1090d3(0x1d0)]('\x20\x20Skill\x20Version:\x20\x20\x20'+(_0x75117f[_0x1090d3(0x1b1)]||a30_0x3e8ff0[_0x1090d3(0x1fe)]('(missing)'))),console[_0x1090d3(0x1d0)](_0x1090d3(0x1b3)+(_0x75117f['installedPath']||a30_0x3e8ff0[_0x1090d3(0x1fe)](_0x1090d3(0x1f4))));_0x75117f[_0x1090d3(0x1d2)]!==_0x1090d3(0x1b2)&&console[_0x1090d3(0x1d0)](_0x1090d3(0x22e)+_0x75117f[_0x1090d3(0x1d4)]);_0x75117f['reason']&&console[_0x1090d3(0x1d0)](_0x1090d3(0x1e4)+_0x75117f['reason']);console[_0x1090d3(0x1d0)](),console['log'](a30_0x3e8ff0[_0x1090d3(0x1d3)](_0x1090d3(0x229))),console[_0x1090d3(0x1d0)](a30_0x3e8ff0[_0x1090d3(0x1fe)](_0x1090d3(0x1dd)[_0x1090d3(0x1ff)](0x1e)));const _0x585146=getGlobalConfigPath(),_0x22feae=getProjectConfigPath();console[_0x1090d3(0x1d0)]('\x20\x20Global:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+(_0x585146||a30_0x3e8ff0[_0x1090d3(0x1fe)](_0x1090d3(0x1f4)))),console[_0x1090d3(0x1d0)](_0x1090d3(0x215)+(_0x22feae||a30_0x3e8ff0['gray'](_0x1090d3(0x1f4)))),console[_0x1090d3(0x1d0)](),console[_0x1090d3(0x1d0)](a30_0x3e8ff0['bold'](_0x1090d3(0x21c))),console[_0x1090d3(0x1d0)](a30_0x3e8ff0[_0x1090d3(0x1fe)]('\x20\x20─'[_0x1090d3(0x1ff)](0x1e)));const _0xf92e4c=(_0x2f2998,_0x620fc3)=>{const _0x190255=_0x1090d3;if(!_0x620fc3){console[_0x190255(0x1d0)]('\x20\x20'+_0x2f2998[_0x190255(0x213)](0x11)+'\x20'+a30_0x3e8ff0['gray']('(no\x20file)'));return;}const _0x161c86=inspectCliConfigJsonFile(_0x620fc3);if(_0x161c86['status']==='ok')console[_0x190255(0x1d0)]('\x20\x20'+_0x2f2998[_0x190255(0x213)](0x11)+'\x20'+a30_0x3e8ff0[_0x190255(0x1d6)]('✓\x20Valid\x20JSON'));else{if(_0x161c86['status']==='empty')console[_0x190255(0x1d0)]('\x20\x20'+_0x2f2998[_0x190255(0x213)](0x11)+'\x20'+a30_0x3e8ff0[_0x190255(0x20a)](_0x190255(0x1e2)));else _0x161c86['status']===_0x190255(0x221)?console[_0x190255(0x1d0)]('\x20\x20'+_0x2f2998[_0x190255(0x213)](0x11)+'\x20'+a30_0x3e8ff0[_0x190255(0x1fe)](_0x190255(0x1d7))):(console[_0x190255(0x1d0)]('\x20\x20'+_0x2f2998[_0x190255(0x213)](0x11)+'\x20'+a30_0x3e8ff0[_0x190255(0x1ec)](_0x190255(0x205))),console[_0x190255(0x1d0)]('\x20\x20'+''[_0x190255(0x213)](0x11)+'\x20'+a30_0x3e8ff0['red'](_0x161c86[_0x190255(0x1ef)])));}};_0xf92e4c(_0x1090d3(0x211),_0x585146),_0xf92e4c('Project',_0x22feae);const _0x4db638=loadRawConfigLayers(),_0x16a368=[Object[_0x1090d3(0x1d8)][_0x1090d3(0x1c1)][_0x1090d3(0x1bc)](_0x4db638[_0x1090d3(0x22a)],_0x1090d3(0x224))?'global':null,Object[_0x1090d3(0x1d8)]['hasOwnProperty'][_0x1090d3(0x1bc)](_0x4db638[_0x1090d3(0x21e)],'inherit')?_0x1090d3(0x1ed):null][_0x1090d3(0x1cf)](Boolean);_0x16a368[_0x1090d3(0x200)]>0x0&&(console[_0x1090d3(0x1d0)](_0x1090d3(0x1d9)+a30_0x3e8ff0[_0x1090d3(0x20a)]('ignored\x20in\x20'+_0x16a368[_0x1090d3(0x220)](_0x1090d3(0x1dc))+_0x1090d3(0x1b9))),_0x16a368[_0x1090d3(0x1e8)](_0x1090d3(0x1ed))&&console[_0x1090d3(0x1d0)](_0x1090d3(0x1f3)+CLI_BIN_NAME+_0x1090d3(0x1f7)),_0x16a368[_0x1090d3(0x1e8)](_0x1090d3(0x1f5))&&console[_0x1090d3(0x1d0)](_0x1090d3(0x225)+CLI_BIN_NAME+_0x1090d3(0x1b6)));_0x2443be&&(console['log'](),console[_0x1090d3(0x1d0)](a30_0x3e8ff0[_0x1090d3(0x1d3)](_0x1090d3(0x1c8))),console[_0x1090d3(0x1d0)](a30_0x3e8ff0[_0x1090d3(0x1fe)]('\x20\x20─'['repeat'](0x1e))),console[_0x1090d3(0x1d0)](_0x1090d3(0x1ce)+a30_0x3e8ff0[_0x1090d3(0x1ec)](_0x1090d3(0x21f))),console['log']('\x20\x20Reason:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+_0x2443be[_0x1090d3(0x1ef)]),Object[_0x1090d3(0x1d8)][_0x1090d3(0x1c1)][_0x1090d3(0x1bc)](_0x4db638[_0x1090d3(0x21e)],_0x1090d3(0x226))&&console['log'](_0x1090d3(0x223)+CLI_BIN_NAME+_0x1090d3(0x207)),Object[_0x1090d3(0x1d8)][_0x1090d3(0x1c1)]['call'](_0x4db638['globalConfig'],'routing')&&console[_0x1090d3(0x1d0)](_0x1090d3(0x1e1)+CLI_BIN_NAME+_0x1090d3(0x1fb)));_0x24da99&&(console['log'](),console[_0x1090d3(0x1d0)](a30_0x3e8ff0['bold'](_0x1090d3(0x1c0))),console[_0x1090d3(0x1d0)](a30_0x3e8ff0[_0x1090d3(0x1fe)](_0x1090d3(0x1dd)[_0x1090d3(0x1ff)](0x1e))),console[_0x1090d3(0x1d0)](_0x1090d3(0x1ce)+a30_0x3e8ff0['red']('✗\x20Invalid')),console[_0x1090d3(0x1d0)](_0x1090d3(0x1e4)+_0x24da99['message']),Object['prototype'][_0x1090d3(0x1c1)][_0x1090d3(0x1bc)](_0x4db638[_0x1090d3(0x21e)],_0x1090d3(0x1e6))&&console[_0x1090d3(0x1d0)](_0x1090d3(0x223)+CLI_BIN_NAME+'\x20config\x20delete\x20region'),Object[_0x1090d3(0x1d8)][_0x1090d3(0x1c1)][_0x1090d3(0x1bc)](_0x4db638[_0x1090d3(0x22a)],_0x1090d3(0x1e6))&&console['log'](_0x1090d3(0x1e1)+CLI_BIN_NAME+'\x20config\x20init'));console[_0x1090d3(0x1d0)](),console[_0x1090d3(0x1d0)](a30_0x3e8ff0['bold']('\x20\x20Merged\x20Config')),console[_0x1090d3(0x1d0)](a30_0x3e8ff0[_0x1090d3(0x1fe)](_0x1090d3(0x1dd)[_0x1090d3(0x1ff)](0x1e))),console[_0x1090d3(0x1d0)](_0x1090d3(0x1cc)+(_0x38987e['appCode']||a30_0x3e8ff0[_0x1090d3(0x1ec)](_0x1090d3(0x1ea)))),console[_0x1090d3(0x1d0)](_0x1090d3(0x21d)+(_0x452130??a30_0x3e8ff0[_0x1090d3(0x1ec)]('(invalid)'))),console[_0x1090d3(0x1d0)](_0x1090d3(0x1c4)+_0x38987e[_0x1090d3(0x1db)]),console[_0x1090d3(0x1d0)](_0x1090d3(0x1e3)+(_0x38987e[_0x1090d3(0x214)]||a30_0x3e8ff0[_0x1090d3(0x1fe)]('(none)'))),console[_0x1090d3(0x1d0)](_0x1090d3(0x1de)+(_0x38987e[_0x1090d3(0x1f9)]||a30_0x3e8ff0['gray']('(none)'))),console['log'](_0x1090d3(0x1cd)+(_0x38987e[_0x1090d3(0x1e9)]||a30_0x3e8ff0[_0x1090d3(0x1fe)](_0x1090d3(0x209)+DEFAULT_CONFIG_VALUES[_0x1090d3(0x1e9)]+')'))),console[_0x1090d3(0x1d0)](_0x1090d3(0x1f8)+(_0x38987e[_0x1090d3(0x208)]??a30_0x3e8ff0[_0x1090d3(0x1fe)](_0x1090d3(0x218)))),console[_0x1090d3(0x1d0)](_0x1090d3(0x1c3)+_0x38987e['riskLevel']),console[_0x1090d3(0x1d0)](_0x1090d3(0x217)+_0x38987e[_0x1090d3(0x1fa)]),console[_0x1090d3(0x1d0)](_0x1090d3(0x201)+AUTH_MODE[_0x1090d3(0x1bd)]),console[_0x1090d3(0x1d0)]('\x20\x20accessKey:\x20\x20\x20\x20\x20\x20\x20'+(_0x38987e[_0x1090d3(0x22c)]?a30_0x3e8ff0[_0x1090d3(0x1d6)]('(set,\x20length='+_0x38987e[_0x1090d3(0x22c)]['length']+')'):a30_0x3e8ff0[_0x1090d3(0x1fe)](_0x1090d3(0x20c)))),console[_0x1090d3(0x1d0)](),console[_0x1090d3(0x1d0)](a30_0x3e8ff0[_0x1090d3(0x1d3)]('\x20\x20API\x20Endpoints')),console[_0x1090d3(0x1d0)](a30_0x3e8ff0[_0x1090d3(0x1fe)](_0x1090d3(0x1dd)[_0x1090d3(0x1ff)](0x1e)));_0x2443be||_0x24da99?console[_0x1090d3(0x1d0)](_0x1090d3(0x1ce)+a30_0x3e8ff0['red'](_0x1090d3(0x21a))):(console[_0x1090d3(0x1d0)](_0x1090d3(0x1c2)+getApiDomain()),console[_0x1090d3(0x1d0)](_0x1090d3(0x1b0)+getUserDomain()),console[_0x1090d3(0x1d0)](_0x1090d3(0x1eb)+getRuntimeDomain()),console[_0x1090d3(0x1d0)](_0x1090d3(0x20f)+getSkillDomain()),console['log'](_0x1090d3(0x1e5)+getKbDomain()));console[_0x1090d3(0x1d0)](),console['log'](a30_0x3e8ff0[_0x1090d3(0x1d3)](_0x1090d3(0x204))),console['log'](a30_0x3e8ff0[_0x1090d3(0x1fe)]('\x20\x20─'[_0x1090d3(0x1ff)](0x1e)));const _0x73a7da=inspectServiceRegistry();console[_0x1090d3(0x1d0)]('\x20\x20Registry:\x20\x20\x20\x20\x20\x20\x20\x20'+_0x73a7da[_0x1090d3(0x22b)]),console[_0x1090d3(0x1d0)]('\x20\x20Status:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+formatServiceRegistryStatus(_0x73a7da)),console[_0x1090d3(0x1d0)](_0x1090d3(0x1ca)+_0x73a7da['serviceCount']),console[_0x1090d3(0x1d0)](_0x1090d3(0x1fc)+_0x73a7da[_0x1090d3(0x219)]);for(const _0x1cbc7e of _0x73a7da[_0x1090d3(0x1f2)]){console['log']('\x20\x20'+(_0x1cbc7e[_0x1090d3(0x1e7)]+':')[_0x1090d3(0x213)](0x11)+'\x20'+(_0x1cbc7e['name']||a30_0x3e8ff0['gray']('(unnamed)'))+'\x20('+_0x1cbc7e[_0x1090d3(0x219)]+_0x1090d3(0x1c9)),console[_0x1090d3(0x1d0)]('\x20\x20'+''[_0x1090d3(0x213)](0x11)+_0x1090d3(0x1df)+_0x1cbc7e[_0x1090d3(0x1cb)]['path']);}return console[_0x1090d3(0x1d0)](),console[_0x1090d3(0x1d0)](a30_0x3e8ff0['bold']('\x20\x20Auth')),console[_0x1090d3(0x1d0)](a30_0x3e8ff0[_0x1090d3(0x1fe)](_0x1090d3(0x1dd)[_0x1090d3(0x1ff)](0x1e))),console[_0x1090d3(0x1d0)](_0x1090d3(0x206)+a30_0x3e8ff0[_0x1090d3(0x1d6)](AUTH_MODE[_0x1090d3(0x1bd)]+_0x1090d3(0x1bb))),console[_0x1090d3(0x1d0)](_0x1090d3(0x227)+a30_0x3e8ff0[_0x1090d3(0x1fe)](_0x1090d3(0x1fd))),console[_0x1090d3(0x1d0)](),{'ok':!![]};}function formatServiceRegistryStatus(_0x49be28){const _0x29b37c=a30_0x2e24;if(_0x49be28[_0x29b37c(0x202)]==='ok')return a30_0x3e8ff0[_0x29b37c(0x1d6)](_0x29b37c(0x1ee));if(_0x49be28['status']===_0x29b37c(0x221))return a30_0x3e8ff0[_0x29b37c(0x1fe)](_0x29b37c(0x1f4));if(_0x49be28[_0x29b37c(0x202)]===_0x29b37c(0x1ba))return a30_0x3e8ff0[_0x29b37c(0x20a)](_0x29b37c(0x21b));return a30_0x3e8ff0[_0x29b37c(0x1ec)]('✗\x20Invalid'+(_0x49be28['message']?':\x20'+_0x49be28[_0x29b37c(0x1ef)]:''));}export const doctorDefinition={'service':a30_0x19d718(0x210),'command':'check','description':'Diagnose\x20CLI\x20configuration\x20and\x20environment','risk':a30_0x19d718(0x203),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],'execute':execute};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a31_0x5419f2=a31_0x7e95;(function(_0x5bdeea,_0x5b08f2){const _0x47bbbd=a31_0x7e95,_0x51a858=_0x5bdeea();while(!![]){try{const _0xe84a49=parseInt(_0x47bbbd(0x8c))/0x1*(parseInt(_0x47bbbd(0x83))/0x2)+-parseInt(_0x47bbbd(0x9f))/0x3*(parseInt(_0x47bbbd(0x86))/0x4)+-parseInt(_0x47bbbd(0x93))/0x5+-parseInt(_0x47bbbd(0x8e))/0x6+parseInt(_0x47bbbd(0x92))/0x7+-parseInt(_0x47bbbd(0x9e))/0x8+parseInt(_0x47bbbd(0x7f))/0x9;if(_0xe84a49===_0x5b08f2)break;else _0x51a858['push'](_0x51a858['shift']());}catch(_0x6cae3a){_0x51a858['push'](_0x51a858['shift']());}}}(a31_0x23dd,0x3b4bb));import{requireRuntimeUploadFile}from'../../commands/common/local-file.js';import{queryRuntimeFileUrl,uploadRuntimeFile}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';function a31_0x23dd(){const _0x21fbd8=['long-term','Return\x20a\x203-year\x20URL\x20for\x20URL-only\x20content\x20embedding\x20such\x20as\x20rich\x20text,\x20Markdown,\x20or\x20HTML','2oULedP','str','trim','16gnwbGg','read','Uploaded\x20file.\x20Store\x20filePath\x20for\x20durable\x20references;\x20use\x20file\x20query-url\x20for\x20short-lived\x20access.','validation','query-url','bool','455539UrnIXJ','File','430098QFwnWQ','file','appCode','boolean','465010WhRnBv','415925TnKHLJ','Return\x20a\x20short-lived\x20download\x20URL\x20instead\x20of\x20a\x20short-lived\x20preview\x20URL','body','/client/uploadFile','path','Preview:\x20upload\x20','string','Query\x20a\x20short-lived\x20URL\x20for\x20preview,\x20download,\x20OCR,\x20or\x20immediate\x20access','upload','download','Upload\x20a\x20local\x20file\x20and\x20return\x20filePath\x20for\x20durable\x20references','2405576ZaBlVa','287943LyVtof','filePath\x20is\x20required.','filePath','.\x20Store\x20filePath\x20for\x20durable\x20references;\x20use\x20file\x20query-url\x20for\x20short-lived\x20access.','5043555owbEnr','filepath'];a31_0x23dd=function(){return _0x21fbd8;};return a31_0x23dd();}import{dryRun}from'../../framework/dryrun.js';const FILE_FLAG={'name':a31_0x5419f2(0x8f),'type':a31_0x5419f2(0x99),'required':!![],'description':'Path\x20to\x20the\x20local\x20file\x20to\x20upload'},FILEPATH_FLAG={'name':a31_0x5419f2(0x80),'type':a31_0x5419f2(0x99),'required':!![],'description':'Runtime\x20filePath\x20returned\x20by\x20file\x20upload;\x20store\x20it\x20in\x20file\x20fields\x20and\x20durable\x20data'},DOWNLOAD_FLAG={'name':a31_0x5419f2(0x9c),'type':a31_0x5419f2(0x91),'description':a31_0x5419f2(0x94)},LONG_TERM_FLAG={'name':'long-term','type':a31_0x5419f2(0x91),'description':a31_0x5419f2(0x82)};function requireFilePath(_0x8afe9e){const _0x3bcf33=a31_0x5419f2,_0x53d34a=_0x8afe9e[_0x3bcf33(0x85)]();if(!_0x53d34a)throw CliErrors[_0x3bcf33(0x89)](_0x3bcf33(0xa0));return _0x53d34a;}const fileUpload={'service':a31_0x5419f2(0x8f),'command':a31_0x5419f2(0x9b),'description':a31_0x5419f2(0x9d),'risk':a31_0x5419f2(0x87),'flags':[FILE_FLAG],async 'dryRun'(_0x1fcf51){const _0x2545ad=a31_0x5419f2,_0x1d2089=requireRuntimeUploadFile(_0x1fcf51[_0x2545ad(0x84)](_0x2545ad(0x8f)),_0x2545ad(0x8d));return dryRun('POST',_0x2545ad(0x96))[_0x2545ad(0x95)]({'appCode':_0x1fcf51['appCode'],'multipart':{'file':_0x1d2089}})['description'](_0x2545ad(0x98)+_0x1d2089[_0x2545ad(0x97)]+'\x20to\x20runtime\x20app\x20'+_0x1fcf51[_0x2545ad(0x90)])['build']();},async 'execute'(_0x3db1cd){const _0x22b38a=a31_0x5419f2,_0x305f7e=requireRuntimeUploadFile(_0x3db1cd[_0x22b38a(0x84)](_0x22b38a(0x8f)),'File'),_0x5d6824=await uploadRuntimeFile(_0x3db1cd[_0x22b38a(0x90)],_0x305f7e[_0x22b38a(0x97)]);return{'ok':!![],'data':_0x5d6824,'message':_0x5d6824[_0x22b38a(0x7d)]?'Uploaded\x20file:\x20'+_0x5d6824['filePath']+_0x22b38a(0x7e):_0x22b38a(0x88)};}},fileQueryUrl={'service':a31_0x5419f2(0x8f),'command':a31_0x5419f2(0x8a),'description':a31_0x5419f2(0x9a),'risk':a31_0x5419f2(0x87),'flags':[FILEPATH_FLAG,DOWNLOAD_FLAG,LONG_TERM_FLAG],async 'execute'(_0x1a36fc){const _0x3e590c=a31_0x5419f2,_0x521896=requireFilePath(_0x1a36fc[_0x3e590c(0x84)](_0x3e590c(0x80))),_0x7628b=await queryRuntimeFileUrl(_0x521896,{'download':_0x1a36fc[_0x3e590c(0x8b)](_0x3e590c(0x9c)),'longTerm':_0x1a36fc['bool'](_0x3e590c(0x81))});return{'ok':!![],'data':_0x7628b};}};function a31_0x7e95(_0x4a2628,_0x1e3d99){_0x4a2628=_0x4a2628-0x7d;const _0x23dde9=a31_0x23dd();let _0x7e95d=_0x23dde9[_0x4a2628];return _0x7e95d;}export const fileDefinitions=[fileUpload,fileQueryUrl];
|
package/lib/commands/init.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a32_0x478a5e=a32_0x4dcf;(function(_0x6cf646,_0x11c3b3){const _0x587ca8=a32_0x4dcf,_0x4a6e81=_0x6cf646();while(!![]){try{const _0x1f0975=parseInt(_0x587ca8(0x204))/0x1*(-parseInt(_0x587ca8(0x1f4))/0x2)+-parseInt(_0x587ca8(0x1e9))/0x3+parseInt(_0x587ca8(0x210))/0x4*(-parseInt(_0x587ca8(0x209))/0x5)+-parseInt(_0x587ca8(0x1fa))/0x6+parseInt(_0x587ca8(0x202))/0x7*(-parseInt(_0x587ca8(0x203))/0x8)+parseInt(_0x587ca8(0x1e6))/0x9+parseInt(_0x587ca8(0x1f3))/0xa;if(_0x1f0975===_0x11c3b3)break;else _0x4a6e81['push'](_0x4a6e81['shift']());}catch(_0x10165e){_0x4a6e81['push'](_0x4a6e81['shift']());}}}(a32_0x12af,0x4d188));import{existsSync,readFileSync}from'node:fs';import{resolve,isAbsolute}from'node:path';import{CliErrors}from'../errors.js';import{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';import{RUNTIME_ENV_VALUES}from'../constant/env.js';import{IMPORTABLE_RUNTIME_CONFIG_KEYS}from'../config/schema.js';import{resolveWriteConfigPath,readConfigFile,writeConfigFile}from'../context.js';import{PRODUCT_CONFIG}from'../constant/product.js';export const appImportFlagDefs=[{'name':a32_0x478a5e(0x1ea),'type':a32_0x478a5e(0x1ee),'description':a32_0x478a5e(0x1f5),'required':!![]},{'name':a32_0x478a5e(0x1e8),'type':'string','description':a32_0x478a5e(0x1f0)},{'name':a32_0x478a5e(0x1ef),'type':'string','description':a32_0x478a5e(0x1e7),'enum':[...RUNTIME_ENV_VALUES]},{'name':'global','type':a32_0x478a5e(0x1fc),'description':a32_0x478a5e(0x1ec)+PRODUCT_CONFIG['newConfigFileName']+')\x20instead\x20of\x20project','default':![]},{'name':a32_0x478a5e(0x1eb),'type':a32_0x478a5e(0x1fc),'description':a32_0x478a5e(0x1fb),'default':![]}];export async function runAppImport(_0xe75652){const _0x1d5ac8=a32_0x478a5e,_0x4cc1b4=_0xe75652[_0x1d5ac8(0x200)]?_0x1d5ac8(0x200):_0x1d5ac8(0x205),_0x11c9df=resolveWriteConfigPath(_0x4cc1b4);await runFromImport(_0xe75652,_0x11c9df);}async function runFromImport(_0x3ba122,_0x150322){const _0x2af817=a32_0x478a5e,_0x5c8c28=resolveFilePath(_0x3ba122['file']);if(!existsSync(_0x5c8c28))throw CliErrors[_0x2af817(0x20c)](_0x2af817(0x1f6)+_0x5c8c28);const _0x54b975=readSourceFile(_0x5c8c28),_0x39745e=convertToRuntimeConfig(_0x54b975);_0x3ba122['appcode']&&(_0x39745e[_0x2af817(0x1e8)]=String(_0x3ba122['appcode']));_0x3ba122['env']&&(_0x39745e[_0x2af817(0x1ef)]=resolveImportEnv(_0x3ba122));if(!_0x39745e[_0x2af817(0x1e8)])throw CliErrors[_0x2af817(0x20c)](_0x2af817(0x20d),'Provide\x20--appcode\x20<code>\x20or\x20use\x20an\x20upgraded\x20.rabetbase.json\x20with\x20top-level\x20appcode.\x20Legacy\x20files\x20must\x20be\x20upgraded\x20first\x20with\x20`rabetbase\x20project\x20upgrade`.');await writeImportConfig(_0x150322,_0x39745e,_0x3ba122),console[_0x2af817(0x1f7)](_0x2af817(0x1f2)+_0x5c8c28),console[_0x2af817(0x1f7)]('\x20\x20config:\x20\x20'+_0x150322),console[_0x2af817(0x1f7)](_0x2af817(0x20e)+_0x39745e[_0x2af817(0x1e8)]);if(_0x39745e['defaultApp'])console[_0x2af817(0x1f7)]('\x20\x20default:\x20'+_0x39745e[_0x2af817(0x20a)]);}function a32_0x12af(){const _0x321cf3=['32858DfgjtC','152RlCVTW','3bOivqr','project','message','riskLevel','object','1195965ialAIU','defaultApp','join','validation','Source\x20file\x20does\x20not\x20contain\x20an\x20importable\x20appcode.','\x20\x20appcode:\x20','Invalid\x20env\x20\x22','4KbXhCi','Run\x20`rabetbase\x20project\x20upgrade`\x20first,\x20then\x20retry\x20`lovrabet\x20app\x20import`.','4736331BKTQdU','Override\x20imported\x20default\x20env','appcode','1138578mgvTaY','file','yes','Write\x20to\x20global\x20(~/','entries','string','env','Override\x20imported\x20default\x20appcode','parse','Imported\x20from\x20','8954440RAXNyL','157660XDldmX','Import\x20from\x20a\x20.rabetbase.json\x20file\x20path','Source\x20file\x20not\x20found:\x20','log','utf8','app','969144inJrfa','Skip\x20confirmation\x20when\x20overwriting','boolean','cwd','\x22.\x20Allowed:\x20','apps','global','includes'];a32_0x12af=function(){return _0x321cf3;};return a32_0x12af();}function convertToRuntimeConfig(_0x3c359d){const _0x34380b=a32_0x478a5e;if(_0x3c359d[_0x34380b(0x1ff)]&&typeof _0x3c359d[_0x34380b(0x1ff)]===_0x34380b(0x208))throw CliErrors[_0x34380b(0x20c)]('Legacy\x20/\x20multi-app\x20.rabetbase.json\x20is\x20no\x20longer\x20supported\x20for\x20import.',_0x34380b(0x1e5));const _0x19a721={};for(const _0x1ac3b3 of IMPORTABLE_RUNTIME_CONFIG_KEYS){_0x3c359d[_0x1ac3b3]!==undefined&&(_0x19a721[_0x1ac3b3]=_0x3c359d[_0x1ac3b3]);}return!_0x19a721['riskLevel']&&(_0x19a721['riskLevel']=DEFAULT_CONFIG_VALUES[_0x34380b(0x207)]),_0x19a721;}async function writeImportConfig(_0x74e7c0,_0x143c63,_0x52e4a7){const _0x537196=a32_0x478a5e;let _0x857b6f={};existsSync(_0x74e7c0)&&!_0x52e4a7[_0x537196(0x1eb)]&&(_0x857b6f=readConfigFile(_0x74e7c0));for(const [_0xcab8e8,_0xd026d5]of Object[_0x537196(0x1ed)](_0x143c63)){_0xd026d5!==undefined&&(_0x857b6f[_0xcab8e8]=_0xd026d5);}if(_0x857b6f[_0x537196(0x1f9)])delete _0x857b6f['app'];writeConfigFile(_0x74e7c0,_0x857b6f);}function a32_0x4dcf(_0x3cb633,_0x250266){_0x3cb633=_0x3cb633-0x1e5;const _0x12afa9=a32_0x12af();let _0x4dcf9f=_0x12afa9[_0x3cb633];return _0x4dcf9f;}function resolveFilePath(_0x1435b5){const _0x14955b=a32_0x478a5e;return isAbsolute(_0x1435b5)?_0x1435b5:resolve(process[_0x14955b(0x1fd)](),_0x1435b5);}function readSourceFile(_0x1e6680){const _0x50c0c0=a32_0x478a5e;try{const _0x4d67ec=readFileSync(_0x1e6680,{'encoding':_0x50c0c0(0x1f8)});return JSON[_0x50c0c0(0x1f1)](_0x4d67ec);}catch(_0x110ddd){throw CliErrors[_0x50c0c0(0x20c)]('Failed\x20to\x20parse\x20source\x20file:\x20'+_0x110ddd[_0x50c0c0(0x206)]);}}function resolveImportEnv(_0x3436ad){const _0x194cf6=a32_0x478a5e,_0x1c5ce5=_0x3436ad[_0x194cf6(0x1ef)];if(_0x1c5ce5===undefined||_0x1c5ce5==='')return DEFAULT_CONFIG_VALUES[_0x194cf6(0x1ef)];if(!RUNTIME_ENV_VALUES[_0x194cf6(0x201)](_0x1c5ce5))throw CliErrors[_0x194cf6(0x20c)](_0x194cf6(0x20f)+_0x1c5ce5+_0x194cf6(0x1fe)+RUNTIME_ENV_VALUES[_0x194cf6(0x20b)](',\x20'));return _0x1c5ce5;}
|
package/lib/commands/kb/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a33_0x58d0(_0x37287d,_0x14418a){_0x37287d=_0x37287d-0x13e;const _0x375cbc=a33_0x375c();let _0x58d0ca=_0x375cbc[_0x37287d];return _0x58d0ca;}const a33_0x156ba4=a33_0x58d0;(function(_0x47d848,_0x3109ac){const _0x416bcc=a33_0x58d0,_0x1a6feb=_0x47d848();while(!![]){try{const _0x5278fe=parseInt(_0x416bcc(0x168))/0x1*(parseInt(_0x416bcc(0x143))/0x2)+-parseInt(_0x416bcc(0x15f))/0x3*(-parseInt(_0x416bcc(0x15a))/0x4)+-parseInt(_0x416bcc(0x142))/0x5*(parseInt(_0x416bcc(0x140))/0x6)+parseInt(_0x416bcc(0x162))/0x7+-parseInt(_0x416bcc(0x177))/0x8+-parseInt(_0x416bcc(0x150))/0x9+parseInt(_0x416bcc(0x17e))/0xa*(-parseInt(_0x416bcc(0x159))/0xb);if(_0x5278fe===_0x3109ac)break;else _0x1a6feb['push'](_0x1a6feb['shift']());}catch(_0x186b56){_0x1a6feb['push'](_0x1a6feb['shift']());}}}(a33_0x375c,0xdd8d9));import{existsSync,readFileSync,statSync}from'node:fs';import{createPersonalKnowledgeBaseItem,getPersonalKnowledgeBaseItem,listPersonalKnowledgeBaseItems,searchKnowledgeBase,updatePersonalKnowledgeBaseItem}from'../../core/api-client.js';import{ID_FLAG,VERBOSE_FLAG}from'../../commands/common/flags.js';import{CliErrors}from'../../errors.js';import{dryRun}from'../../framework/dryrun.js';const TITLE_FLAG={'name':a33_0x156ba4(0x171),'type':a33_0x156ba4(0x164),'required':!![],'description':a33_0x156ba4(0x17f)},FILE_FLAG={'name':a33_0x156ba4(0x174),'type':'string','required':!![],'description':a33_0x156ba4(0x15b)},QUERY_FLAG={'name':a33_0x156ba4(0x144),'type':a33_0x156ba4(0x164),'required':!![],'description':a33_0x156ba4(0x169)},TOPK_FLAG={'name':a33_0x156ba4(0x154),'type':'number','description':a33_0x156ba4(0x166)};function readKnowledgeFile(_0x5461df){const _0x5cde12=a33_0x156ba4;if(!_0x5461df)throw CliErrors[_0x5cde12(0x16c)]('File\x20path\x20is\x20required.');if(!existsSync(_0x5461df))throw CliErrors[_0x5cde12(0x16c)](_0x5cde12(0x178)+_0x5461df);if(!statSync(_0x5461df)[_0x5cde12(0x152)]())throw CliErrors[_0x5cde12(0x16c)]('File\x20is\x20not\x20a\x20regular\x20file:\x20'+_0x5461df);return readFileSync(_0x5461df,_0x5cde12(0x16e));}function summarizePersonalItem(_0x52d1e6){const _0x580b97=a33_0x156ba4;return{'id':_0x52d1e6['id'],'title':_0x52d1e6[_0x580b97(0x171)],'version':_0x52d1e6[_0x580b97(0x17b)],'ragStatus':_0x52d1e6[_0x580b97(0x14e)],'ragErrorMessage':_0x52d1e6[_0x580b97(0x156)],'updateTime':_0x52d1e6[_0x580b97(0x13f)]};}function detailPersonalItem(_0x7d9c6e){const _0x26aa51=a33_0x156ba4;return{'id':_0x7d9c6e['id'],'appCode':_0x7d9c6e[_0x26aa51(0x17d)],'scope':_0x7d9c6e['scope'],'userId':_0x7d9c6e[_0x26aa51(0x16b)],'title':_0x7d9c6e[_0x26aa51(0x171)],'content':_0x7d9c6e['content']??'','version':_0x7d9c6e['version'],'ragStatus':_0x7d9c6e['ragStatus'],'ragErrorMessage':_0x7d9c6e['ragErrorMessage'],'createTime':_0x7d9c6e[_0x26aa51(0x147)],'updateTime':_0x7d9c6e[_0x26aa51(0x13f)]};}function summarizeSearchHit(_0x4a768c){const _0x183551=a33_0x156ba4;return{'scope':_0x4a768c[_0x183551(0x15c)],'title':_0x4a768c[_0x183551(0x171)],'docId':_0x4a768c[_0x183551(0x14f)],'score':_0x4a768c[_0x183551(0x175)],'weightedScore':_0x4a768c[_0x183551(0x13e)],'content':_0x4a768c[_0x183551(0x14d)],'metadata':_0x4a768c[_0x183551(0x16f)]};}function readTopK(_0x28107c){const _0x1c733b=a33_0x156ba4,_0x2c106e=_0x28107c[_0x1c733b(0x14a)](_0x1c733b(0x154));if(_0x2c106e===undefined||_0x2c106e===null||_0x2c106e==='')return undefined;const _0x231561=_0x28107c[_0x1c733b(0x170)](_0x1c733b(0x154));if(!Number[_0x1c733b(0x141)](_0x231561)||_0x231561<0x1)throw CliErrors[_0x1c733b(0x16c)](_0x1c733b(0x163));return _0x231561;}function a33_0x375c(){const _0x10a39e=['ragErrorMessage','length','POST','11CGCHgK','4qsUDwj','Path\x20to\x20a\x20local\x20UTF-8\x20text\x20or\x20Markdown\x20file','scope','detail','bool','4232271uVoOqz','/client/knowledge-base/personal/','Search\x20query\x20is\x20required.','12202071BrrQGh','--topk\x20must\x20be\x20a\x20positive\x20number.','string','read','Maximum\x20number\x20of\x20search\x20hits\x20to\x20return','Updated\x20KB\x20entry\x20','261VyhmWC','Search\x20query\x20for\x20visible\x20company\x20and\x20personal\x20knowledge','write','userId','validation','Replaces\x20the\x20personal\x20knowledge-base\x20entry\x20body\x20with\x20local\x20file\x20content\x20and\x20triggers\x20retrieval\x20sync.','utf8','metadata','num','title','Preview:\x20create\x20personal\x20knowledge-base\x20entry\x20\x22','Update\x20a\x20personal\x20knowledge-base\x20entry\x20from\x20a\x20local\x20file','file','score','list','3302832xuPbhw','File\x20not\x20found:\x20','map','trim','version','build','appCode','19413670hbwnWr','Personal\x20knowledge-base\x20entry\x20title','body','List\x20personal\x20knowledge-base\x20entries\x20for\x20the\x20current\x20app','verbose','weightedScore','updateTime','239676nCyhwN','isFinite','25mzYtwj','8314fKCBbz','query','description','Saves\x20local\x20file\x20content\x20as\x20a\x20personal\x20knowledge-base\x20entry\x20and\x20starts\x20retrieval\x20sync.','createTime','search','str','flag','create','Show\x20one\x20personal\x20knowledge-base\x20entry\x20by\x20id','content','ragStatus','docId','6997095rsWvfF','Override\x20the\x20existing\x20entry\x20title','isFile','/client/knowledge-base/personal/create','topk','Personal\x20knowledge-base\x20entry\x20ID'];a33_0x375c=function(){return _0x10a39e;};return a33_0x375c();}const kbList={'service':'kb','command':a33_0x156ba4(0x176),'description':a33_0x156ba4(0x181),'risk':a33_0x156ba4(0x165),'flags':[VERBOSE_FLAG],async 'execute'(_0x1bb378){const _0x2e6ac3=a33_0x156ba4,_0x53b163=await listPersonalKnowledgeBaseItems(_0x1bb378[_0x2e6ac3(0x17d)]);if(_0x1bb378[_0x2e6ac3(0x15e)](_0x2e6ac3(0x182)))return{'ok':!![],'data':{'total':_0x53b163[_0x2e6ac3(0x157)],'items':_0x53b163}};return{'ok':!![],'data':{'total':_0x53b163[_0x2e6ac3(0x157)],'items':_0x53b163[_0x2e6ac3(0x179)](summarizePersonalItem)}};}},kbDetail={'service':'kb','command':a33_0x156ba4(0x15d),'description':a33_0x156ba4(0x14c),'risk':'read','flags':[{...ID_FLAG,'description':a33_0x156ba4(0x155)}],async 'execute'(_0x37ab06){const _0x374643=a33_0x156ba4,_0x46bfcd=await getPersonalKnowledgeBaseItem(_0x37ab06[_0x374643(0x170)]('id'),_0x37ab06['appCode']);return{'ok':!![],'data':detailPersonalItem(_0x46bfcd)};}},kbCreate={'service':'kb','command':a33_0x156ba4(0x14b),'description':'Create\x20a\x20personal\x20knowledge-base\x20entry\x20from\x20a\x20local\x20file','risk':a33_0x156ba4(0x16a),'confirmationDescription':a33_0x156ba4(0x146),'flags':[TITLE_FLAG,FILE_FLAG],async 'execute'(_0x22e652){const _0x334735=a33_0x156ba4,_0x4774e3=_0x22e652[_0x334735(0x149)](_0x334735(0x171)),_0x212684=readKnowledgeFile(_0x22e652['str'](_0x334735(0x174))),_0x57684f=await createPersonalKnowledgeBaseItem(_0x22e652['appCode'],{'title':_0x4774e3,'content':_0x212684});return{'ok':!![],'data':summarizePersonalItem(_0x57684f),'message':'Created\x20KB\x20entry\x20'+_0x57684f['id']+'\x20('+_0x57684f[_0x334735(0x171)]+')'};},async 'dryRun'(_0x565aa5){const _0x5062da=a33_0x156ba4,_0xfafc4a=_0x565aa5[_0x5062da(0x149)](_0x5062da(0x171)),_0x25f8e9=readKnowledgeFile(_0x565aa5[_0x5062da(0x149)](_0x5062da(0x174)));return dryRun(_0x5062da(0x158),_0x5062da(0x153))[_0x5062da(0x180)]({'appCode':_0x565aa5['appCode'],'title':_0xfafc4a,'content':_0x25f8e9})[_0x5062da(0x145)](_0x5062da(0x172)+_0xfafc4a+'\x22')['build']();}},kbUpdate={'service':'kb','command':'update','description':a33_0x156ba4(0x173),'risk':a33_0x156ba4(0x16a),'confirmationDescription':a33_0x156ba4(0x16d),'flags':[{...ID_FLAG,'description':a33_0x156ba4(0x155)},{...TITLE_FLAG,'required':![],'description':a33_0x156ba4(0x151)},FILE_FLAG],async 'execute'(_0x344242){const _0x29552c=a33_0x156ba4,_0x1561ca=_0x344242[_0x29552c(0x170)]('id'),_0xb77893=readKnowledgeFile(_0x344242[_0x29552c(0x149)](_0x29552c(0x174))),_0x571a61=_0x344242[_0x29552c(0x149)](_0x29552c(0x171))||(await getPersonalKnowledgeBaseItem(_0x1561ca,_0x344242['appCode']))[_0x29552c(0x171)],_0x16773d=await updatePersonalKnowledgeBaseItem(_0x1561ca,_0x344242[_0x29552c(0x17d)],{'title':_0x571a61,'content':_0xb77893});return{'ok':!![],'data':summarizePersonalItem(_0x16773d),'message':_0x29552c(0x167)+_0x16773d['id']+'\x20('+_0x16773d[_0x29552c(0x171)]+')'};},async 'dryRun'(_0xf50a32){const _0x453575=a33_0x156ba4,_0x519f14=_0xf50a32[_0x453575(0x170)]('id'),_0x58681f=readKnowledgeFile(_0xf50a32[_0x453575(0x149)](_0x453575(0x174))),_0x471521=_0xf50a32[_0x453575(0x149)](_0x453575(0x171))||(await getPersonalKnowledgeBaseItem(_0x519f14,_0xf50a32[_0x453575(0x17d)]))['title'];return dryRun('POST',_0x453575(0x160)+_0x519f14+'/update')[_0x453575(0x180)]({'appCode':_0xf50a32[_0x453575(0x17d)],'title':_0x471521,'content':_0x58681f})[_0x453575(0x145)]('Preview:\x20update\x20personal\x20knowledge-base\x20entry\x20'+_0x519f14)[_0x453575(0x17c)]();}},kbSearch={'service':'kb','command':a33_0x156ba4(0x148),'description':'Search\x20visible\x20company\x20and\x20personal\x20knowledge\x20base\x20content','risk':a33_0x156ba4(0x165),'flags':[QUERY_FLAG,TOPK_FLAG],async 'validate'(_0x37e31a){const _0x878ee9=a33_0x156ba4;if(!_0x37e31a['str']('query')[_0x878ee9(0x17a)]())throw CliErrors[_0x878ee9(0x16c)](_0x878ee9(0x161));readTopK(_0x37e31a);},async 'execute'(_0x3995d2){const _0x428224=a33_0x156ba4,_0x1a8218=_0x3995d2[_0x428224(0x149)](_0x428224(0x144))[_0x428224(0x17a)](),_0x4516e3=readTopK(_0x3995d2),_0x5dc71b=await searchKnowledgeBase(_0x3995d2['appCode'],{'query':_0x1a8218,'topK':_0x4516e3});return{'ok':!![],'data':{'total':_0x5dc71b[_0x428224(0x157)],'hits':_0x5dc71b[_0x428224(0x179)](summarizeSearchHit)}};}};export const kbDefinitions=[kbList,kbDetail,kbCreate,kbUpdate,kbSearch];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a34_0x44154e=a34_0x352d;(function(_0x320fa6,_0x39ae6e){const _0x5a1d14=a34_0x352d,_0x39d82e=_0x320fa6();while(!![]){try{const _0x372bcd=-parseInt(_0x5a1d14(0x112))/0x1*(-parseInt(_0x5a1d14(0x115))/0x2)+parseInt(_0x5a1d14(0xfc))/0x3*(-parseInt(_0x5a1d14(0x106))/0x4)+parseInt(_0x5a1d14(0x114))/0x5+parseInt(_0x5a1d14(0x101))/0x6+-parseInt(_0x5a1d14(0xfa))/0x7+parseInt(_0x5a1d14(0x10a))/0x8+parseInt(_0x5a1d14(0x10c))/0x9*(-parseInt(_0x5a1d14(0x110))/0xa);if(_0x372bcd===_0x39ae6e)break;else _0x39d82e['push'](_0x39d82e['shift']());}catch(_0x1e5485){_0x39d82e['push'](_0x39d82e['shift']());}}}(a34_0x236c,0x8cf7b));import{logger}from'../../utils/logger.js';import{CLI_DISPLAY_NAME}from'../../constant/cli.js';function a34_0x352d(_0x3d0dd7,_0x5ac855){_0x3d0dd7=_0x3d0dd7-0xfa;const _0x236c84=a34_0x236c();let _0x352d40=_0x236c84[_0x3d0dd7];return _0x352d40;}function a34_0x236c(){const _0x4925e0=['command','5167512ReqQoo','View\x20command\x20history\x20logs','3fNfBeX','length','*\x20No\x20logs\x20found','timestamp','read','5371584FWOIwM','message','readLogs','warn','toLocaleString','290384QoTSLC','\x20\x20\x20Details:\x20','\x20\x20\x20Duration:\x20','log','2146760IRWRiX','level','189351uDEMYe','\x20\x20\x20Time:\x20','error','show','830IzUqnh','details','59wfZuaA','duration','5265195ciJfLG','31112sddzgi','\x20logs:\x0a'];a34_0x236c=function(){return _0x4925e0;};return a34_0x236c();}function printLogs(_0x2ec5c5){const _0x11efeb=a34_0x352d;if(_0x2ec5c5[_0x11efeb(0xfd)]===0x0){console['log'](_0x11efeb(0xfe));return;}console[_0x11efeb(0x109)]('*\x20'+CLI_DISPLAY_NAME+_0x11efeb(0x116)),_0x2ec5c5['forEach']((_0x638299,_0x411d07)=>{const _0x2f9f77=_0x11efeb,_0x385b54=new Date(_0x638299[_0x2f9f77(0xff)])[_0x2f9f77(0x105)]('en-US'),_0x32f981=_0x638299[_0x2f9f77(0x10b)]==='success'?'√':_0x638299[_0x2f9f77(0x10b)]===_0x2f9f77(0x10e)?'×':_0x638299[_0x2f9f77(0x10b)]===_0x2f9f77(0x104)?'!':'i';console[_0x2f9f77(0x109)](_0x411d07+0x1+'.\x20'+_0x32f981+'\x20['+_0x638299[_0x2f9f77(0x117)]+']\x20'+_0x638299[_0x2f9f77(0x102)]),console[_0x2f9f77(0x109)](_0x2f9f77(0x10d)+_0x385b54),_0x638299['duration']&&console['log'](_0x2f9f77(0x108)+_0x638299[_0x2f9f77(0x113)]+'ms'),_0x638299[_0x2f9f77(0x111)]&&Object['keys'](_0x638299['details'])['length']>0x0&&console[_0x2f9f77(0x109)](_0x2f9f77(0x107)+JSON['stringify'](_0x638299['details'],null,0x2)),console['log']('');});}export const logsDefinitions=[{'service':'logs','command':a34_0x44154e(0x10f),'description':a34_0x44154e(0xfb),'risk':a34_0x44154e(0x100),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x33fd8d){const _0x183bbd=a34_0x44154e;return printLogs(logger[_0x183bbd(0x103)]()),{'ok':!![]};}}];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a35_0x5d39f3=a35_0x3d02;(function(_0xea62fa,_0x2351f2){const _0x19709b=a35_0x3d02,_0x312ca4=_0xea62fa();while(!![]){try{const _0x31f016=parseInt(_0x19709b(0x200))/0x1+parseInt(_0x19709b(0x1f2))/0x2*(parseInt(_0x19709b(0x1ff))/0x3)+parseInt(_0x19709b(0x1f3))/0x4+-parseInt(_0x19709b(0x1f7))/0x5+-parseInt(_0x19709b(0x1fa))/0x6*(parseInt(_0x19709b(0x1f9))/0x7)+-parseInt(_0x19709b(0x1f5))/0x8+parseInt(_0x19709b(0x1fd))/0x9;if(_0x31f016===_0x2351f2)break;else _0x312ca4['push'](_0x312ca4['shift']());}catch(_0x205f0a){_0x312ca4['push'](_0x312ca4['shift']());}}}(a35_0x1d2e,0x5dfdc));function a35_0x1d2e(){const _0x37ee1e=['Found\x20','length','973406dvPePF','1801032RcizLb','\x20notification\x20config(s)','4187712ydnVhG','appCode','2609745orEHtx','type','1141Tfefhu','11886JpUZbI','read','string','420066nXIiWp','map','3lWiXon','769669qdViqT','List\x20app-level\x20notification\x20configs\x20and\x20their\x20configCode\x20values'];a35_0x1d2e=function(){return _0x37ee1e;};return a35_0x1d2e();}function a35_0x3d02(_0xa63d4,_0x5bf148){_0xa63d4=_0xa63d4-0x1f1;const _0x1d2eb8=a35_0x1d2e();let _0x3d0285=_0x1d2eb8[_0xa63d4];return _0x3d0285;}import{listNotificationChannelConfigs}from'../../core/api-client.js';import{NOTIFICATION_CHANNEL_TYPES,projectNotificationListConfig,readNotificationChannelType}from'../../commands/notification/shared.js';export const notificationConfigList={'service':'notification','command':'config-list','description':a35_0x5d39f3(0x201),'risk':a35_0x5d39f3(0x1fb),'flags':[{'name':a35_0x5d39f3(0x1f8),'type':a35_0x5d39f3(0x1fc),'description':'Notification\x20channel\x20type','enum':NOTIFICATION_CHANNEL_TYPES,'default':'EMAIL'}],async 'validate'(_0x2e2f5c){readNotificationChannelType(_0x2e2f5c);},async 'execute'(_0x21b42f){const _0x345a1c=a35_0x5d39f3,_0x14efed=readNotificationChannelType(_0x21b42f),_0x448696=await listNotificationChannelConfigs(_0x21b42f['appCode'],_0x14efed),_0x2c9c68=_0x448696[_0x345a1c(0x1fe)](projectNotificationListConfig);return{'ok':!![],'data':{'appCode':_0x21b42f[_0x345a1c(0x1f6)],'channelType':_0x14efed,'count':_0x2c9c68['length'],'configs':_0x2c9c68},'message':_0x345a1c(0x202)+_0x2c9c68[_0x345a1c(0x1f1)]+'\x20'+_0x14efed+_0x345a1c(0x1f4)};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function a36_0x5aa1(_0x167922,_0x46d134){_0x167922=_0x167922-0x1ba;const _0x578358=a36_0x5783();let _0x5aa1f1=_0x578358[_0x167922];return _0x5aa1f1;}function a36_0x5783(){const _0x521510=['340443gKDzdW','225532MJnhVN','3696875RyzlQN','3RlAqDs','6uCDmkq','6471474qZjEMg','6886580zbYiHH','925173uJzswT','32HgqdeA','2284779gruZrw'];a36_0x5783=function(){return _0x521510;};return a36_0x5783();}(function(_0x3ad2d4,_0x4092ec){const _0xa412df=a36_0x5aa1,_0x17d45e=_0x3ad2d4();while(!![]){try{const _0x31d6e8=parseInt(_0xa412df(0x1c1))/0x1*(-parseInt(_0xa412df(0x1bb))/0x2)+parseInt(_0xa412df(0x1ba))/0x3*(-parseInt(_0xa412df(0x1c2))/0x4)+parseInt(_0xa412df(0x1c3))/0x5+parseInt(_0xa412df(0x1bc))/0x6+-parseInt(_0xa412df(0x1c0))/0x7+parseInt(_0xa412df(0x1bf))/0x8*(-parseInt(_0xa412df(0x1be))/0x9)+parseInt(_0xa412df(0x1bd))/0xa;if(_0x31d6e8===_0x4092ec)break;else _0x17d45e['push'](_0x17d45e['shift']());}catch(_0x7eecf2){_0x17d45e['push'](_0x17d45e['shift']());}}}(a36_0x5783,0xa8c73));import{notificationConfigList}from'../../commands/notification/config-list.js';export const notificationDefinitions=[notificationConfigList];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a37_0x1154f5=a37_0x5e8f;(function(_0x4fff52,_0x2e8677){const _0x234038=a37_0x5e8f,_0x492abe=_0x4fff52();while(!![]){try{const _0x26e971=parseInt(_0x234038(0x211))/0x1+-parseInt(_0x234038(0x204))/0x2+-parseInt(_0x234038(0x206))/0x3*(parseInt(_0x234038(0x1fb))/0x4)+-parseInt(_0x234038(0x200))/0x5+-parseInt(_0x234038(0x1fe))/0x6*(parseInt(_0x234038(0x1fc))/0x7)+parseInt(_0x234038(0x20f))/0x8+-parseInt(_0x234038(0x1f4))/0x9*(-parseInt(_0x234038(0x201))/0xa);if(_0x26e971===_0x2e8677)break;else _0x492abe['push'](_0x492abe['shift']());}catch(_0x17def5){_0x492abe['push'](_0x492abe['shift']());}}}(a37_0xebad,0x9ae9d));import{CliErrors}from'../../errors.js';export const NOTIFICATION_CHANNEL_TYPES=['EMAIL',a37_0x1154f5(0x208),a37_0x1154f5(0x20b),a37_0x1154f5(0x203),a37_0x1154f5(0x1f3)];export function readNotificationChannelType(_0x2c00e7){const _0xbe9184=a37_0x1154f5,_0x75cddd=_0x2c00e7[_0xbe9184(0x20c)](_0xbe9184(0x1f5))[_0xbe9184(0x1fd)]()||_0xbe9184(0x20d);if(!NOTIFICATION_CHANNEL_TYPES[_0xbe9184(0x1f8)](_0x75cddd))throw CliErrors['validation'](_0xbe9184(0x210)+_0x75cddd,_0xbe9184(0x1f7)+NOTIFICATION_CHANNEL_TYPES[_0xbe9184(0x202)](',\x20')+'.');return _0x75cddd;}function a37_0xebad(){const _0x44c8c9=['WECOM','166162dDXxbk','configName','6FcimvH','channelType','FEISHU','updateTime','createTime','DINGTALK','str','EMAIL','apiError','4074992DTqptU','Invalid\x20--type:\x20','889470FsyAFB','isSafeInteger','Invalid\x20notification\x20config\x20response.','isArray','object','configCode','WEBHOOK','644787MSNgRJ','type','\x20must\x20be\x20an\x20object.','Allowed\x20values:\x20','includes','test','Item\x20','71320LKwzYr','49VRjhOO','trim','886638GAukTw','string','4503705KSkWfs','180YPXHDc','join'];a37_0xebad=function(){return _0x44c8c9;};return a37_0xebad();}export function projectNotificationListConfig(_0xf3099d,_0xde92f3){const _0x2c0035=a37_0x1154f5,_0x314ccc=requireResponseObject(_0xf3099d,_0xde92f3);return{'id':normalizeNullableId(_0x314ccc['id'],_0xde92f3),'configCode':requireResponseString(_0x314ccc[_0x2c0035(0x216)],_0x2c0035(0x216),_0xde92f3),'configName':requireResponseString(_0x314ccc['configName'],_0x2c0035(0x205),_0xde92f3),'channelType':requireResponseString(_0x314ccc[_0x2c0035(0x207)],'channelType',_0xde92f3),'description':normalizeNullableString(_0x314ccc['description']),'createTime':normalizeNullableString(_0x314ccc[_0x2c0035(0x20a)]),'updateTime':normalizeNullableString(_0x314ccc[_0x2c0035(0x209)])};}function requireResponseObject(_0x364550,_0xfb7f05){const _0x22d7fc=a37_0x1154f5;if(typeof _0x364550!==_0x22d7fc(0x215)||_0x364550===null||Array[_0x22d7fc(0x214)](_0x364550))throw CliErrors[_0x22d7fc(0x20e)](_0x22d7fc(0x213),_0x22d7fc(0x1fa)+(_0xfb7f05+0x1)+_0x22d7fc(0x1f6));return _0x364550;}function a37_0x5e8f(_0x2939a1,_0x3a7492){_0x2939a1=_0x2939a1-0x1f3;const _0xebad95=a37_0xebad();let _0x5e8fdf=_0xebad95[_0x2939a1];return _0x5e8fdf;}function requireResponseString(_0x2b311f,_0x5acf47,_0x4380a6){const _0x52469c=a37_0x1154f5;if(typeof _0x2b311f!==_0x52469c(0x1ff)||!_0x2b311f['trim']())throw CliErrors[_0x52469c(0x20e)](_0x52469c(0x213),_0x52469c(0x1fa)+(_0x4380a6+0x1)+'\x20is\x20missing\x20required\x20field\x20\x22'+_0x5acf47+'\x22.');return _0x2b311f['trim']();}function normalizeNullableString(_0x5da082){return typeof _0x5da082==='string'&&_0x5da082['trim']()?_0x5da082['trim']():null;}function normalizeNullableId(_0x28f07e,_0x3210cc){const _0x386515=a37_0x1154f5;if(_0x28f07e===undefined||_0x28f07e===null)return null;if(typeof _0x28f07e==='number'&&Number[_0x386515(0x212)](_0x28f07e))return _0x28f07e;if(typeof _0x28f07e===_0x386515(0x1ff)&&/^-?\d+$/[_0x386515(0x1f9)](_0x28f07e[_0x386515(0x1fd)]()))return _0x28f07e[_0x386515(0x1fd)]();throw CliErrors[_0x386515(0x20e)](_0x386515(0x213),_0x386515(0x1fa)+(_0x3210cc+0x1)+'\x20has\x20invalid\x20field\x20\x22id\x22.');}
|