@lovrabet/lovrabet-cli 2.3.2-beta.3 → 2.3.3-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/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/approval/index.d.ts +15 -0
- package/lib/commands/approval/index.js +1 -0
- 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.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.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.js +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.js +1 -1
- package/lib/constant/env.js +1 -1
- package/lib/constant/output.js +1 -1
- package/lib/constant/product.js +1 -1
- 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 +83 -0
- package/lib/core/api-client.js +1 -1
- package/lib/core/db-resolver.js +1 -1
- package/lib/core/kb-search-client.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.js +1 -1
- package/lib/generated/build-info.d.ts +4 -4
- package/lib/generated/build-info.js +1 -1
- package/lib/generated/official-routing.js +1 -1
- package/lib/generated/routing-contract.js +1 -1
- package/lib/help.js +1 -1
- package/lib/postinstall.js +1 -1
- package/lib/runtime/confirmation.js +1 -1
- package/lib/runtime/event.js +1 -1
- package/lib/runtime/index.js +1 -1
- package/lib/runtime/queue.js +1 -1
- package/lib/runtime/resolve.js +1 -1
- package/lib/skills/builtin-skill.js +1 -1
- package/lib/skills/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/positive-safe-integer.d.ts +5 -0
- package/lib/utils/positive-safe-integer.js +1 -0
- package/lib/utils/redaction.d.ts +17 -0
- package/lib/utils/redaction.js +1 -0
- 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 +1 -1
- package/skills/lovrabet/SKILL.md +3 -2
- package/skills/lovrabet/references/lovrabet-approval-workflow.md +73 -0
- package/skills/lovrabet.manifest.json +4 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a160_0xf5fddd=a160_0x4dfc;(function(_0x1dcaf0,_0x6b5fc7){const _0xf485a5=a160_0x4dfc,_0x3c5358=_0x1dcaf0();while(!![]){try{const _0x3e9571=-parseInt(_0xf485a5(0x12d))/0x1*(parseInt(_0xf485a5(0x12b))/0x2)+-parseInt(_0xf485a5(0x11a))/0x3+parseInt(_0xf485a5(0x12a))/0x4+parseInt(_0xf485a5(0x11c))/0x5*(parseInt(_0xf485a5(0x123))/0x6)+parseInt(_0xf485a5(0x126))/0x7*(-parseInt(_0xf485a5(0x11b))/0x8)+-parseInt(_0xf485a5(0x121))/0x9+parseInt(_0xf485a5(0x11f))/0xa;if(_0x3e9571===_0x6b5fc7)break;else _0x3c5358['push'](_0x3c5358['shift']());}catch(_0x4a120c){_0x3c5358['push'](_0x3c5358['shift']());}}}(a160_0x405f,0xa1007));function a160_0x405f(){const _0x317352=['MIN_SAFE_INTEGER','parse','36621200NOyykU','length','6041304MBiPXZ','includes','11574QsiEBW','json','text','11634gXDOgD','defineProperty','undefined','exec','2957060vQVCik','58192CnJGgO','slice','43kahQXU','getOwnPropertyDescriptor','2878395hPdSKY','5672ImYSqy','825YgWgfP'];a160_0x405f=function(){return _0x317352;};return a160_0x405f();}const JSON_NUMBER_PATTERN=/^-?(?:0|[1-9]\d*)(?:\.\d+)?(?:[eE][+-]?\d+)?/,MAX_SAFE_INTEGER=BigInt(Number['MAX_SAFE_INTEGER']),MIN_SAFE_INTEGER=BigInt(Number[a160_0xf5fddd(0x11d)]);function a160_0x4dfc(_0x118aed,_0x595e01){_0x118aed=_0x118aed-0x119;const _0x405ffd=a160_0x405f();let _0x4dfc7d=_0x405ffd[_0x118aed];return _0x4dfc7d;}let restoreResponseJsonParser,responseJsonPrototype,originalResponseJsonDescriptor;function isUnsafeIntegerLiteral(_0x366b11){const _0x189657=a160_0xf5fddd;if(_0x366b11['includes']('.')||_0x366b11[_0x189657(0x122)]('e')||_0x366b11[_0x189657(0x122)]('E'))return![];const _0x474872=BigInt(_0x366b11);return _0x474872>MAX_SAFE_INTEGER||_0x474872<MIN_SAFE_INTEGER;}function quoteUnsafeIntegerLiterals(_0x34d127){const _0x38123e=a160_0xf5fddd;let _0x3c656a='',_0x5e67a2=![],_0x82e67b=![];for(let _0x1903d9=0x0;_0x1903d9<_0x34d127['length'];){const _0x14dc5c=_0x34d127[_0x1903d9];if(_0x5e67a2){_0x3c656a+=_0x14dc5c,_0x1903d9+=0x1;if(_0x82e67b)_0x82e67b=![];else{if(_0x14dc5c==='\x5c')_0x82e67b=!![];else _0x14dc5c==='\x22'&&(_0x5e67a2=![]);}continue;}if(_0x14dc5c==='\x22'){_0x5e67a2=!![],_0x3c656a+=_0x14dc5c,_0x1903d9+=0x1;continue;}if(_0x14dc5c==='-'||_0x14dc5c>='0'&&_0x14dc5c<='9'){const _0x4f8777=JSON_NUMBER_PATTERN[_0x38123e(0x129)](_0x34d127[_0x38123e(0x12c)](_0x1903d9))?.[0x0];if(_0x4f8777){_0x3c656a+=isUnsafeIntegerLiteral(_0x4f8777)?'\x22'+_0x4f8777+'\x22':_0x4f8777,_0x1903d9+=_0x4f8777[_0x38123e(0x120)];continue;}}_0x3c656a+=_0x14dc5c,_0x1903d9+=0x1;}return _0x3c656a;}export function parseLosslessJson(_0x7b39ef){const _0x3ccf8e=a160_0xf5fddd;return JSON[_0x3ccf8e(0x11e)](quoteUnsafeIntegerLiterals(_0x7b39ef));}export function installLosslessJsonResponseParser(){const _0x5edcb8=a160_0xf5fddd;if(typeof Response===_0x5edcb8(0x128))return()=>{};if(restoreResponseJsonParser)return restoreResponseJsonParser;return responseJsonPrototype=Response['prototype'],originalResponseJsonDescriptor=Object[_0x5edcb8(0x119)](responseJsonPrototype,_0x5edcb8(0x124)),Object[_0x5edcb8(0x127)](responseJsonPrototype,_0x5edcb8(0x124),{...originalResponseJsonDescriptor??{'configurable':!![],'enumerable':![],'writable':!![]},'value':async function _0xc76c74(){const _0x1eb703=_0x5edcb8;return parseLosslessJson(await this[_0x1eb703(0x125)]());}}),restoreResponseJsonParser=()=>{const _0x516a68=_0x5edcb8;if(!responseJsonPrototype)return;originalResponseJsonDescriptor?Object[_0x516a68(0x127)](responseJsonPrototype,_0x516a68(0x124),originalResponseJsonDescriptor):delete responseJsonPrototype[_0x516a68(0x124)],responseJsonPrototype=undefined,originalResponseJsonDescriptor=undefined,restoreResponseJsonParser=undefined;},restoreResponseJsonParser;}export function restoreLosslessJsonResponseParser(){restoreResponseJsonParser?.();}
|
package/lib/utils/params.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x4bc91b,_0x5cd670){const _0x1e0297=a161_0x2fb2,_0x17e671=_0x4bc91b();while(!![]){try{const _0x1fef85=-parseInt(_0x1e0297(0x1ec))/0x1+-parseInt(_0x1e0297(0x1dc))/0x2*(parseInt(_0x1e0297(0x1e9))/0x3)+-parseInt(_0x1e0297(0x1ed))/0x4+-parseInt(_0x1e0297(0x1de))/0x5*(-parseInt(_0x1e0297(0x1df))/0x6)+parseInt(_0x1e0297(0x1f3))/0x7+parseInt(_0x1e0297(0x1e6))/0x8+parseInt(_0x1e0297(0x1e7))/0x9*(parseInt(_0x1e0297(0x1e4))/0xa);if(_0x1fef85===_0x5cd670)break;else _0x17e671['push'](_0x17e671['shift']());}catch(_0x2032e8){_0x17e671['push'](_0x17e671['shift']());}}}(a161_0x413f,0x68802));import{CliErrors}from'../errors.js';import{parseLosslessJson}from'../utils/lossless-json.js';function a161_0x2fb2(_0x5aa298,_0x53d468){_0x5aa298=_0x5aa298-0x1db;const _0x413f66=a161_0x413f();let _0x2fb228=_0x413f66[_0x5aa298];return _0x2fb228;}function a161_0x413f(){const _0xecd296=['1122568dQyxny','isArray','test','validation','object','Invalid\x20JSON\x20for\x20--params:\x20','2942156BFSbiz','\x20records\x20per\x20call;\x20received\x20','items','2OvOirG','length','1275WjKROX','3054yJmwsa','data\x20update\x20--params.','data\x20update\x20id\x20array\x20cannot\x20be\x20empty.','number','batchCreate\x20--params\x20must\x20be\x20a\x20JSON\x20array\x20or\x20{\x22items\x22:[...]}','332250rGOEPu','string','3497688NesvUZ','162GPlapK','Example:\x20--params\x20\x27[{\x22name\x22:\x22a\x22},{\x22name\x22:\x22b\x22}]\x27','777867YMHYBR','id[','Example:\x20--params\x20\x27{\x22id\x22:[1,2,3],\x22status\x22:\x22done\x22}\x27','617399UbjFUa'];a161_0x413f=function(){return _0xecd296;};return a161_0x413f();}export const MAX_DATA_UPDATE_IDS=0x3e8;export function parseJsonParams(_0x53f6b4){const _0x36b993=a161_0x2fb2;if(!_0x53f6b4)return undefined;try{return parseLosslessJson(_0x53f6b4);}catch{throw CliErrors[_0x36b993(0x1f0)](_0x36b993(0x1f2)+_0x53f6b4);}}export function parseJsonParamsValue(_0x5ed284){const _0x476b02=a161_0x2fb2;if(!_0x5ed284)return undefined;try{return parseLosslessJson(_0x5ed284);}catch{throw CliErrors[_0x476b02(0x1f0)](_0x476b02(0x1f2)+_0x5ed284);}}export function parseBatchCreateItemsFromParams(_0x16f12f){const _0x2f5927=a161_0x2fb2;if(Array[_0x2f5927(0x1ee)](_0x16f12f))return _0x16f12f;if(_0x16f12f!==null&&_0x16f12f!==undefined&&typeof _0x16f12f===_0x2f5927(0x1f1)&&Array[_0x2f5927(0x1ee)](_0x16f12f['items']))return _0x16f12f[_0x2f5927(0x1db)];throw CliErrors[_0x2f5927(0x1f0)](_0x2f5927(0x1e3),_0x2f5927(0x1e8));}function parseDataUpdateId(_0x127789,_0x63a5c0){const _0x811268=a161_0x2fb2;if(typeof _0x127789===_0x811268(0x1e2)&&Number['isSafeInteger'](_0x127789)&&_0x127789>0x0)return _0x127789;if(typeof _0x127789===_0x811268(0x1e5)){if(/^[1-9]\d*$/[_0x811268(0x1ef)](_0x127789))return _0x127789;}throw CliErrors[_0x811268(0x1f0)](_0x811268(0x1e0)+_0x63a5c0+'\x20must\x20be\x20a\x20positive\x20integer\x20or\x20numeric\x20string.');}export function parseUpdateIdsFromParams(_0x2c3041){const _0x5dcc5e=a161_0x2fb2;if(_0x2c3041===null||_0x2c3041===undefined||typeof _0x2c3041!==_0x5dcc5e(0x1f1)||Array['isArray'](_0x2c3041))throw CliErrors[_0x5dcc5e(0x1f0)]('data\x20update\x20--params\x20must\x20be\x20a\x20JSON\x20object\x20with\x20id.','Example:\x20--params\x20\x27{\x22id\x22:[1,2,3],\x22status\x22:\x22done\x22}\x27');const _0x5191a1=_0x2c3041['id'];if(_0x5191a1===undefined||_0x5191a1===null)throw CliErrors[_0x5dcc5e(0x1f0)]('data\x20update\x20requires\x20\x22id\x22\x20in\x20--params.',_0x5dcc5e(0x1eb));const _0x5f182e=Array['isArray'](_0x5191a1)?_0x5191a1:[_0x5191a1];if(_0x5f182e['length']===0x0)throw CliErrors[_0x5dcc5e(0x1f0)](_0x5dcc5e(0x1e1));if(_0x5f182e['length']>MAX_DATA_UPDATE_IDS)throw CliErrors[_0x5dcc5e(0x1f0)]('data\x20update\x20can\x20update\x20at\x20most\x20'+MAX_DATA_UPDATE_IDS+_0x5dcc5e(0x1f4)+_0x5f182e[_0x5dcc5e(0x1dd)]+'.');return _0x5f182e['map']((_0x449394,_0x523941)=>parseDataUpdateId(_0x449394,Array[_0x5dcc5e(0x1ee)](_0x5191a1)?_0x5dcc5e(0x1ea)+_0x523941+']':'id'));}export function normalizeUpdateParamsForRuntime(_0x494181,_0x35739b){const _0x556c6d=a161_0x2fb2;if(Array['isArray'](_0x494181['id'])&&_0x35739b[_0x556c6d(0x1dd)]>0x1)return{..._0x494181,'id':_0x35739b['join'](',')};return _0x494181;}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(function(_0x29e6f4,_0x56dbab){const _0x30356b=a162_0x20ef,_0x151605=_0x29e6f4();while(!![]){try{const _0x11cbf3=-parseInt(_0x30356b(0x1b0))/0x1*(parseInt(_0x30356b(0x1b8))/0x2)+parseInt(_0x30356b(0x1b4))/0x3*(parseInt(_0x30356b(0x1b5))/0x4)+-parseInt(_0x30356b(0x1b6))/0x5+parseInt(_0x30356b(0x1ae))/0x6+parseInt(_0x30356b(0x1ad))/0x7+parseInt(_0x30356b(0x1b9))/0x8+parseInt(_0x30356b(0x1b3))/0x9*(-parseInt(_0x30356b(0x1b7))/0xa);if(_0x11cbf3===_0x56dbab)break;else _0x151605['push'](_0x151605['shift']());}catch(_0x18b01f){_0x151605['push'](_0x151605['shift']());}}}(a162_0x23d1,0xb2dde));function a162_0x20ef(_0x55b117,_0x42299e){_0x55b117=_0x55b117-0x1ad;const _0x23d1dd=a162_0x23d1();let _0x20ef1a=_0x23d1dd[_0x55b117];return _0x20ef1a;}export function normalizePositiveSafeInteger(_0xbadf61){const _0x3fb27c=a162_0x20ef;if(typeof _0xbadf61===_0x3fb27c(0x1b1))return Number['isSafeInteger'](_0xbadf61)&&_0xbadf61>0x0?_0xbadf61:undefined;if(typeof _0xbadf61!==_0x3fb27c(0x1af)||!/^\d+$/[_0x3fb27c(0x1b2)](_0xbadf61))return undefined;const _0xfd91cf=Number(_0xbadf61);return Number['isSafeInteger'](_0xfd91cf)&&_0xfd91cf>0x0?_0xfd91cf:undefined;}function a162_0x23d1(){const _0x102aa8=['4389172oHuOCj','4804270utFRzI','10sBzfoR','14002uilcbf','6509376xrNtNB','3614429xISbVo','7731642dGkKEQ','string','10owRbQf','number','test','17571753GFnaKW','3ZinjwW'];a162_0x23d1=function(){return _0x102aa8;};return a162_0x23d1();}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @fileoverview Redaction helpers for command arguments and API-shaped values.
|
|
3
|
+
*
|
|
4
|
+
* Approval payloads can contain user-provided form data. These helpers keep
|
|
5
|
+
* credentials and similarly sensitive values out of previews, logs, and output
|
|
6
|
+
* while preserving ordinary business fields for inspection.
|
|
7
|
+
*/
|
|
8
|
+
declare const REDACTED_VALUE = "[REDACTED]";
|
|
9
|
+
/** Returns whether an object key contains a credential or secret value. */
|
|
10
|
+
export declare function isSensitiveKey(key: string): boolean;
|
|
11
|
+
/** Returns whether a command flag should be hidden in command text. */
|
|
12
|
+
export declare function isSensitiveFlagName(key: string): boolean;
|
|
13
|
+
/** Recursively redacts sensitive object properties without mutating the input. */
|
|
14
|
+
export declare function redactSensitiveValue(value: unknown): unknown;
|
|
15
|
+
/** Redacts values of sensitive flags in a reconstructed command invocation. */
|
|
16
|
+
export declare function redactCommandArgv(argv: readonly string[]): string[];
|
|
17
|
+
export { REDACTED_VALUE };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const a163_0x1e5796=a163_0x4ad6;function a163_0x4ad6(_0xd5fdf8,_0x3a3221){_0xd5fdf8=_0xd5fdf8-0x1de;const _0x261fad=a163_0x261f();let _0x4ad6ae=_0x261fad[_0xd5fdf8];return _0x4ad6ae;}(function(_0x1f887b,_0xbca354){const _0x557037=a163_0x4ad6,_0x1c11e2=_0x1f887b();while(!![]){try{const _0x4b38cd=parseInt(_0x557037(0x1e6))/0x1+parseInt(_0x557037(0x1e5))/0x2+parseInt(_0x557037(0x1df))/0x3*(parseInt(_0x557037(0x1e2))/0x4)+parseInt(_0x557037(0x1e8))/0x5+parseInt(_0x557037(0x1e4))/0x6+parseInt(_0x557037(0x1ee))/0x7*(parseInt(_0x557037(0x1ef))/0x8)+parseInt(_0x557037(0x1eb))/0x9*(-parseInt(_0x557037(0x1de))/0xa);if(_0x4b38cd===_0xbca354)break;else _0x1c11e2['push'](_0x1c11e2['shift']());}catch(_0x4f08f9){_0x1c11e2['push'](_0x1c11e2['shift']());}}}(a163_0x261f,0x93ee0));const REDACTED_VALUE=a163_0x1e5796(0x1e9),SENSITIVE_KEY_PATTERN=/(?:access.?key|api.?key|authorization|cookie|credential|password|passwd|private.?key|secret|token|webhook)/i,SENSITIVE_FLAG_NAMES=new Set([a163_0x1e5796(0x1e1),a163_0x1e5796(0x1f0)]),SENSITIVE_VALUE_KEYS=new Set([a163_0x1e5796(0x1e1)]);export function isSensitiveKey(_0x1342ca){const _0x4311fc=a163_0x1e5796,_0x368399=_0x1342ca['replace'](/_/g,'-')[_0x4311fc(0x1e0)]();return SENSITIVE_KEY_PATTERN['test'](_0x368399);}export function isSensitiveFlagName(_0x48d750){const _0x274186=_0x48d750['replace'](/_/g,'-')['toLowerCase']();return isSensitiveKey(_0x274186)||SENSITIVE_FLAG_NAMES['has'](_0x274186);}function redactVariableValues(_0x2581ae){const _0x3b91cb=a163_0x1e5796;if(Array[_0x3b91cb(0x1f2)](_0x2581ae))return _0x2581ae['map'](_0x1ebead=>redactVariableValues(_0x1ebead));if(_0x2581ae&&typeof _0x2581ae===_0x3b91cb(0x1e3))return Object[_0x3b91cb(0x1ea)](Object[_0x3b91cb(0x1e7)](_0x2581ae)['map'](([_0x46d648,_0x412279])=>[_0x46d648,redactVariableValues(_0x412279)]));return REDACTED_VALUE;}export function redactSensitiveValue(_0x4caeac){const _0x300e0a=a163_0x1e5796;if(Array[_0x300e0a(0x1f2)](_0x4caeac))return _0x4caeac[_0x300e0a(0x1ec)](_0x4cadfb=>redactSensitiveValue(_0x4cadfb));if(!_0x4caeac||typeof _0x4caeac!==_0x300e0a(0x1e3))return _0x4caeac;const _0xf8c18a={};for(const [_0x2a1a61,_0x2e606f]of Object['entries'](_0x4caeac)){const _0x283eda=_0x2a1a61['replace'](/_/g,'-')[_0x300e0a(0x1e0)]();_0xf8c18a[_0x2a1a61]=_0x283eda===_0x300e0a(0x1f0)?redactVariableValues(_0x2e606f):SENSITIVE_VALUE_KEYS[_0x300e0a(0x1f3)](_0x283eda)||isSensitiveKey(_0x2a1a61)?REDACTED_VALUE:redactSensitiveValue(_0x2e606f);}return _0xf8c18a;}export function redactCommandArgv(_0x12ef58){const _0x2dc807=a163_0x1e5796,_0xa8037e=[];let _0x5472ae=![];for(const _0x123dad of _0x12ef58){if(_0x5472ae){_0xa8037e[_0x2dc807(0x1f1)](REDACTED_VALUE),_0x5472ae=![];continue;}const _0x2ad341=_0x123dad[_0x2dc807(0x1ed)](/^--([^=]+)(?:=(.*))?$/);if(!_0x2ad341||!isSensitiveFlagName(_0x2ad341[0x1]??'')){_0xa8037e[_0x2dc807(0x1f1)](_0x123dad);continue;}_0xa8037e[_0x2dc807(0x1f1)]('--'+_0x2ad341[0x1]+(_0x2ad341[0x2]===undefined?'':'='+REDACTED_VALUE)),_0x2ad341[0x2]===undefined&&(_0x5472ae=!![]);}return _0xa8037e;}function a163_0x261f(){const _0x335e75=['44180170QXaZtT','3kpYxfX','toLowerCase','comment','3639508EIYEQF','object','6405492bMOdtx','1180454yHwigw','994908yeSYsJ','entries','3417770pZyufz','[REDACTED]','fromEntries','9zlthKE','map','match','201649gpLMvu','216jkiafo','variables','push','isArray','has'];a163_0x261f=function(){return _0x335e75;};return a163_0x261f();}export{REDACTED_VALUE};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x126205,_0x502c20){const _0x1719c8=a164_0xa67d,_0x37ce7a=_0x126205();while(!![]){try{const _0xcee456=parseInt(_0x1719c8(0x183))/0x1+parseInt(_0x1719c8(0x198))/0x2+-parseInt(_0x1719c8(0x18c))/0x3*(parseInt(_0x1719c8(0x188))/0x4)+-parseInt(_0x1719c8(0x197))/0x5+-parseInt(_0x1719c8(0x189))/0x6*(-parseInt(_0x1719c8(0x192))/0x7)+parseInt(_0x1719c8(0x190))/0x8+parseInt(_0x1719c8(0x184))/0x9;if(_0xcee456===_0x502c20)break;else _0x37ce7a['push'](_0x37ce7a['shift']());}catch(_0xe9952e){_0x37ce7a['push'](_0x37ce7a['shift']());}}}(a164_0x473e,0x65798));import{mkdir,readFile,writeFile}from'node:fs/promises';import{homedir}from'node:os';function a164_0xa67d(_0x182605,_0x3f8308){_0x182605=_0x182605-0x182;const _0x473edb=a164_0x473e();let _0xa67d59=_0x473edb[_0x182605];return _0xa67d59;}import{dirname,join}from'node:path';import{LOVRABET_NPM_PACKAGE_NAME}from'../constant/distribution.js';import{CLI_BIN_NAME}from'../constant/cli.js';import{checkCliVersion,getCliUpgradeCommand}from'../utils/cli-version-check.js';const UPDATE_NOTICE_TTL_MS=0x18*0x3c*0x3c*0x3e8;function a164_0x473e(){const _0x3d09c9=['/v/','stableVersion','update-check.json','1822590sLBVzT','556002Wlrtls','trim','number','https://www.npmjs.com/package/','object','lovrabet-cli','\x20is\x20recommended,\x20current\x20','join','96223KsYCuT','1694727EUiVGj','belowMinimum','.cache','true','16gwNATS','1854AjcbJu','yes','toLowerCase','409974gxXBaM','utf8','lastNotifiedAt','stringify','5693864suLoHt','lastNotifiedVersion','1190QSvcjX','filter'];a164_0x473e=function(){return _0x3d09c9;};return a164_0x473e();}function isUpdateNoticeDisabled(){const _0x2bde8a=a164_0xa67d,_0x9f3278=process.env.LOVRABET_NO_UPDATE_NOTICE?.[_0x2bde8a(0x199)]()[_0x2bde8a(0x18b)]();return _0x9f3278==='1'||_0x9f3278===_0x2bde8a(0x187)||_0x9f3278===_0x2bde8a(0x18a);}function cacheRoot(){const _0x3869b5=a164_0xa67d;return process.env.XDG_CACHE_HOME||process.env.LOCALAPPDATA||join(homedir(),_0x3869b5(0x186));}export function getUpdateNoticeCachePath(){const _0x1445d0=a164_0xa67d;return join(cacheRoot(),_0x1445d0(0x19d),_0x1445d0(0x196));}async function readUpdateNoticeCache(){const _0x532778=a164_0xa67d;try{const _0xdb1680=await readFile(getUpdateNoticeCachePath(),_0x532778(0x18d)),_0x2cc382=JSON['parse'](_0xdb1680);if(!_0x2cc382||typeof _0x2cc382!==_0x532778(0x19c))return{};return _0x2cc382;}catch{return{};}}async function writeUpdateNoticeCache(_0x30ceca){const _0x4ea60b=a164_0xa67d;try{const _0x4f8bb7=getUpdateNoticeCachePath();await mkdir(dirname(_0x4f8bb7),{'recursive':!![]}),await writeFile(_0x4f8bb7,JSON[_0x4ea60b(0x18f)](_0x30ceca,null,0x2)+'\x0a',_0x4ea60b(0x18d));}catch{}}function isRecentlyNotified(_0x2b6752,_0x1ce70e,_0x19ec17){const _0x744b93=a164_0xa67d;return _0x2b6752[_0x744b93(0x191)]===_0x1ce70e&&typeof _0x2b6752[_0x744b93(0x18e)]===_0x744b93(0x19a)&&_0x19ec17-_0x2b6752[_0x744b93(0x18e)]<UPDATE_NOTICE_TTL_MS;}export function buildNpmVersionUrl(_0x14886e){const _0x1d4b86=a164_0xa67d;return _0x1d4b86(0x19b)+LOVRABET_NPM_PACKAGE_NAME+_0x1d4b86(0x194)+_0x14886e;}export async function resolveLatestUpdateNotice(_0xae214){const _0x2b6878=a164_0xa67d;if(isUpdateNoticeDisabled())return null;try{const _0x52447f=Date['now'](),_0x1e9ef0=_0xae214??await checkCliVersion(),_0x2be941=_0x1e9ef0['currentVersion'],_0x74f9b0=_0x1e9ef0[_0x2b6878(0x195)],_0x4d1478=await readUpdateNoticeCache();if(!_0x74f9b0||!_0x1e9ef0['needsUpgrade']||_0x1e9ef0[_0x2b6878(0x185)])return null;if(isRecentlyNotified(_0x4d1478,_0x74f9b0,_0x52447f))return null;const _0x1e36c4=getCliUpgradeCommand(_0x1e9ef0);return await writeUpdateNoticeCache({..._0x4d1478,'checkedAt':_0x52447f,'latest':_0x74f9b0,'failed':![],'lastNotifiedVersion':_0x74f9b0,'lastNotifiedAt':_0x52447f}),{'command':_0x1e36c4,'current':_0x2be941,'latest':_0x74f9b0,'url':buildNpmVersionUrl(_0x74f9b0),'message':[_0x1e9ef0['upgradeMessage'],CLI_BIN_NAME+'\x20'+_0x74f9b0+_0x2b6878(0x19e)+_0x2be941+',\x20run:\x20'+_0x1e36c4][_0x2b6878(0x193)](Boolean)[_0x2b6878(0x182)]('\x20')};}catch{return null;}}
|
package/lib/utils/version.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x4309ab,_0x2edd22){const _0x5c5afe=a165_0x108e,_0xdc193f=_0x4309ab();while(!![]){try{const _0x55e787=parseInt(_0x5c5afe(0xa0))/0x1+-parseInt(_0x5c5afe(0xa8))/0x2+parseInt(_0x5c5afe(0xa9))/0x3*(-parseInt(_0x5c5afe(0xa6))/0x4)+parseInt(_0x5c5afe(0xa5))/0x5+-parseInt(_0x5c5afe(0xa7))/0x6*(parseInt(_0x5c5afe(0x9f))/0x7)+-parseInt(_0x5c5afe(0xa2))/0x8*(-parseInt(_0x5c5afe(0xa3))/0x9)+parseInt(_0x5c5afe(0xa4))/0xa;if(_0x55e787===_0x2edd22)break;else _0xdc193f['push'](_0xdc193f['shift']());}catch(_0x184447){_0xdc193f['push'](_0xdc193f['shift']());}}}(a165_0x5776,0xe6a99));function a165_0x108e(_0x1ca882,_0x38c9c9){_0x1ca882=_0x1ca882-0x9f;const _0x5776e9=a165_0x5776();let _0x108e87=_0x5776e9[_0x1ca882];return _0x108e87;}import{BUILD_TIME,GIT_COMMIT,VERSION}from'../generated/build-info.js';export function getCliVersion(){return VERSION;}export function getCliGitCommit(){const _0x5532cb=a165_0x108e,_0x5c0da7=String(GIT_COMMIT);return _0x5c0da7&&_0x5c0da7!==_0x5532cb(0xa1)?_0x5c0da7:'';}function a165_0x5776(){const _0x31c430=['9194610gOTPmc','20mHDChn','3030XqPsTi','797698RZeZgu','1076523fEnTAN','3619EbpnAY','1024682UMjgIw','unknown','8288uaNCMG','2223CyaQPD','2794360zFWzzh'];a165_0x5776=function(){return _0x31c430;};return a165_0x5776();}export function getCliVersionDisplay(){const _0x103781=getCliGitCommit(),_0x248118=BUILD_TIME['slice'](0x0,0xa);if(!_0x103781||!_0x248118)return VERSION;return VERSION+'\x20('+_0x103781+',\x20'+_0x248118+')';}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x3dc531,_0xec2eb8){var _0x31008d=a166_0x470b,_0xee3cf0=_0x3dc531();while(!![]){try{var _0x2c55e6=parseInt(_0x31008d(0xb9))/0x1*(-parseInt(_0x31008d(0xb7))/0x2)+-parseInt(_0x31008d(0xb4))/0x3*(-parseInt(_0x31008d(0xb0))/0x4)+-parseInt(_0x31008d(0xb5))/0x5*(-parseInt(_0x31008d(0xb6))/0x6)+parseInt(_0x31008d(0xb2))/0x7+-parseInt(_0x31008d(0xb1))/0x8*(parseInt(_0x31008d(0xb3))/0x9)+parseInt(_0x31008d(0xb8))/0xa*(parseInt(_0x31008d(0xae))/0xb)+parseInt(_0x31008d(0xba))/0xc;if(_0x2c55e6===_0xec2eb8)break;else _0xee3cf0['push'](_0xee3cf0['shift']());}catch(_0x3d8c39){_0xee3cf0['push'](_0xee3cf0['shift']());}}}(a166_0x15ca,0x2c021));export function writeCliSideChannelLine(_0x50d49c){var _0x5aa783=a166_0x470b;process[_0x5aa783(0xaf)]['write'](_0x50d49c+'\x0a');}function a166_0x470b(_0x6340cd,_0x172022){_0x6340cd=_0x6340cd-0xae;var _0x15cad=a166_0x15ca();var _0x470b28=_0x15cad[_0x6340cd];return _0x470b28;}function a166_0x15ca(){var _0xd13688=['583788DoVeew','2TniMtJ','30VvBiJX','273938SFsrRT','2984724NhpkAh','602173OPHdpr','stderr','24idyXJE','960CSOhTn','18389LIuBYn','11871ZzCTJN','49797fvHSTn','5ITMywX'];a166_0x15ca=function(){return _0xd13688;};return a166_0x15ca();}
|
package/package.json
CHANGED
package/skills/lovrabet/SKILL.md
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: lovrabet
|
|
3
3
|
displayName: Lovrabet 运行态 CLI
|
|
4
|
-
version: 2.3.
|
|
5
|
-
description: "Lovrabet 运行态 CLI — 面向业务场景的 AI 操作套件,通过 lovrabet 命令管理应用目录、业务角色与权限、用户级外部账号、Service Tree 业务命令、API 文档发现、数据集查询、Instant API 数据操作、Custom SQL/Backend Function、Personal Backend Function、文件上传、面向票证类业务材料文字与结构化字段提取的 OCR
|
|
4
|
+
version: 2.3.3-beta.1
|
|
5
|
+
description: "Lovrabet 运行态 CLI — 面向业务场景的 AI 操作套件,通过 lovrabet 命令管理应用目录、业务角色与权限、用户级外部账号、Service Tree 业务命令、API 文档发现、数据集查询、Instant API 数据操作、Custom SQL/Backend Function、Personal Backend Function、文件上传、面向票证类业务材料文字与结构化字段提取的 OCR、审批待办与任务办理、定时任务、Skill、知识库与运行态 app-config key 状态检查。触发词:云图、lovrabet、lovrabet-cli、业务角色、角色成员、页面权限、菜单权限、数据集权限、user-account bind、provider 外部账号绑定、钉钉 userId 绑定、service tree、业务服务树、api-doc、dataset、data filter、file upload、file query-url、ocr recognize、OCR 识别、票证文字提取、票证字段提取、发票识别、票据识别、证照识别、附件上传、personal-bff、approval、审批、待办、approve、reject、transfer、schedule、定时任务、cron、kb、skill、sql exec、bff exec、app-config、accessKey、compress、jq。"
|
|
6
6
|
metadata:
|
|
7
7
|
requires:
|
|
8
8
|
bins: ["lovrabet"]
|
|
@@ -28,6 +28,7 @@ metadata:
|
|
|
28
28
|
- [数据集与数据流程](guides/dataset-and-data-workflow.md)
|
|
29
29
|
- [Custom SQL 与 Backend Function 流程](guides/sql-and-bff-workflow.md)
|
|
30
30
|
- [排障](guides/troubleshooting.md)
|
|
31
|
+
- [审批流运行态办理](references/lovrabet-approval-workflow.md)
|
|
31
32
|
- 命令细节 / 参数参考:
|
|
32
33
|
- `references/*.md`
|
|
33
34
|
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
# 审批流运行态办理
|
|
2
|
+
|
|
3
|
+
Runtime CLI 只负责当前 AccessKey 用户的运行态任务查询和办理,不管理流程定义。当前用户由 `X-User-AK` 对应的服务端认证上下文确定,命令不接受 `--user-id`。
|
|
4
|
+
|
|
5
|
+
## 查询待办
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
lovrabet approval todo --app-code <APP_CODE>
|
|
9
|
+
lovrabet approval todo --app-code <APP_CODE> --page 2 --page-size 20 --format compress
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
未传 `--app-code` 时,命令使用当前工作区解析出的应用;服务端请求参数是 `appCode`、`currentPage` 和 `pageSize`。
|
|
13
|
+
|
|
14
|
+
## 查看任务
|
|
15
|
+
|
|
16
|
+
```bash
|
|
17
|
+
lovrabet approval task-detail --task-id <TASK_ID> --format json
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
详情中的 `canHandle`、`canCancel`、`transferCandidates`、`formData` 和流程上下文以 Runtime 返回为准。输出会遮罩敏感键;如响应包含 `variables`,其中的值只显示脱敏占位符。
|
|
21
|
+
|
|
22
|
+
## 审批和拒绝
|
|
23
|
+
|
|
24
|
+
先预览请求:
|
|
25
|
+
|
|
26
|
+
```bash
|
|
27
|
+
lovrabet approval approve --task-id <TASK_ID> --comment '同意' --dry-run
|
|
28
|
+
lovrabet approval reject --task-id <TASK_ID> --comment '需要补充材料' --dry-run
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
确认后执行:
|
|
32
|
+
|
|
33
|
+
```bash
|
|
34
|
+
lovrabet approval approve --task-id <TASK_ID> --comment '同意' --yes
|
|
35
|
+
lovrabet approval reject --task-id <TASK_ID> --comment '需要补充材料' --yes
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
`approve` 和 `reject` 都调用 Runtime 的 `/api/flow/approve`,区别只在请求体的 `approved` 值。流程后续路径由已发布流程定义决定,CLI 不自行解释。
|
|
39
|
+
|
|
40
|
+
## 转交
|
|
41
|
+
|
|
42
|
+
目标用户应来自任务详情的 `transferCandidates` 或其他已确认的 Runtime 资源:
|
|
43
|
+
|
|
44
|
+
```bash
|
|
45
|
+
lovrabet approval transfer \
|
|
46
|
+
--task-id <TASK_ID> \
|
|
47
|
+
--target-user-id <USER_ID> \
|
|
48
|
+
--comment '请协助处理' \
|
|
49
|
+
--dry-run
|
|
50
|
+
|
|
51
|
+
lovrabet approval transfer \
|
|
52
|
+
--task-id <TASK_ID> \
|
|
53
|
+
--target-user-id <USER_ID> \
|
|
54
|
+
--comment '请协助处理' \
|
|
55
|
+
--yes
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
最终授权和候选人合法性由 Runtime 校验。
|
|
59
|
+
|
|
60
|
+
## Variables 与安全
|
|
61
|
+
|
|
62
|
+
审批变量支持内联 JSON 或文件:
|
|
63
|
+
|
|
64
|
+
```bash
|
|
65
|
+
lovrabet approval approve --task-id <TASK_ID> \
|
|
66
|
+
--variables '{"amount":100}' --yes
|
|
67
|
+
lovrabet approval approve --task-id <TASK_ID> \
|
|
68
|
+
--variables @variables.json --yes
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
变量解析失败时不会发送请求。dry-run、错误重试命令和本地命令日志不会回显变量值、AccessKey、token 或 secret。
|
|
72
|
+
|
|
73
|
+
高风险命令在非交互模式必须传 `--yes`;`--dry-run` 只生成脱敏预览,不执行写请求。
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
"schemaVersion": 1,
|
|
3
3
|
"name": "lovrabet",
|
|
4
4
|
"packageName": "@lovrabet/lovrabet-cli",
|
|
5
|
-
"packageVersion": "2.3.
|
|
6
|
-
"skillVersion": "2.3.
|
|
5
|
+
"packageVersion": "2.3.3-beta.1",
|
|
6
|
+
"skillVersion": "2.3.3-beta.1",
|
|
7
7
|
"files": [
|
|
8
8
|
"SKILL.md",
|
|
9
9
|
"guides/app-resolution.md",
|
|
@@ -15,6 +15,7 @@
|
|
|
15
15
|
"references/instant-api-workflow.md",
|
|
16
16
|
"references/lovrabet-app-config.md",
|
|
17
17
|
"references/lovrabet-app.md",
|
|
18
|
+
"references/lovrabet-approval-workflow.md",
|
|
18
19
|
"references/lovrabet-auth.md",
|
|
19
20
|
"references/lovrabet-bff-workflow.md",
|
|
20
21
|
"references/lovrabet-config-commands.md",
|
|
@@ -37,5 +38,5 @@
|
|
|
37
38
|
"references/lovrabet-user-account.md",
|
|
38
39
|
"references/lovrabet-workspace.md"
|
|
39
40
|
],
|
|
40
|
-
"digest": "
|
|
41
|
+
"digest": "30b618d9419b739ae2d10d6df111e7a542e0186fa6a31ecb3bbc55ef01dbba07"
|
|
41
42
|
}
|