@kedem/okdb 1.6.0 → 1.6.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/bin/okdb.js CHANGED
@@ -1,2 +1,2 @@
1
1
  #!/usr/bin/env node
2
- 'use strict';const _0x152c38=_0x1dd2;(function(_0x5bc889,_0x18bc78){const _0x560efe=_0x1dd2,_0x1d52ed=_0x5bc889();while(!![]){try{const _0xb2dfff=-parseInt(_0x560efe(0x11e))/0x1*(parseInt(_0x560efe(0x2ac))/0x2)+parseInt(_0x560efe(0x313))/0x3+parseInt(_0x560efe(0x2d1))/0x4*(-parseInt(_0x560efe(0x176))/0x5)+parseInt(_0x560efe(0x2a7))/0x6+-parseInt(_0x560efe(0x273))/0x7+parseInt(_0x560efe(0x144))/0x8+-parseInt(_0x560efe(0x33a))/0x9;if(_0xb2dfff===_0x18bc78)break;else _0x1d52ed['push'](_0x1d52ed['shift']());}catch(_0x4b8284){_0x1d52ed['push'](_0x1d52ed['shift']());}}}(_0x18ba,0xe597d));var require$$1$1=require('path'),require$$1=require('fs'),require$$3=require('net'),require$$0$2=require(_0x152c38(0x1fd)),require$$5=require(_0x152c38(0x382)),require$$0=require(_0x152c38(0xc5)),require$$0$1=require(_0x152c38(0xa9)),require$$2$1=require('os'),require$$4=require(_0x152c38(0x308));function getDefaultExportFromCjs(_0x4fc338){const _0x10a0ec=_0x152c38;return _0x4fc338&&_0x4fc338[_0x10a0ec(0x26d)]&&Object[_0x10a0ec(0x285)][_0x10a0ec(0x336)][_0x10a0ec(0xb4)](_0x4fc338,'default')?_0x4fc338['default']:_0x4fc338;}var okdb$1={},version=_0x152c38(0x1d9),require$$2={'version':version},okdbAuthTokens,hasRequiredOkdbAuthTokens;function requireOkdbAuthTokens(){if(hasRequiredOkdbAuthTokens)return okdbAuthTokens;hasRequiredOkdbAuthTokens=0x1;const _0x54125b=require$$0;function _0x387f5a(_0x2c5359,_0x47f70d){const _0x3defb1=_0x1dd2;return _0x54125b[_0x3defb1(0x2f2)](_0x3defb1(0xa0),_0x47f70d)[_0x3defb1(0x2a3)](_0x2c5359)[_0x3defb1(0x20f)](_0x3defb1(0x1a1));}function _0xfdc848(_0x227835,_0x1ba3c6){const _0x1e0186=_0x1dd2;if(typeof _0x227835!=='string'||typeof _0x1ba3c6!==_0x1e0186(0x2f3))return![];if(Buffer[_0x1e0186(0x24c)](_0x227835)!==Buffer[_0x1e0186(0x24c)](_0x1ba3c6))return![];return _0x54125b[_0x1e0186(0x263)](Buffer[_0x1e0186(0xb5)](_0x227835),Buffer[_0x1e0186(0xb5)](_0x1ba3c6));}function _0x140b61(_0x43528a){const _0x465d39=_0x1dd2;if(!_0x43528a?.[_0x465d39(0x1ef)](_0x465d39(0x180)))return null;return _0x43528a[_0x465d39(0x341)](0x7);}function _0xe089ba(_0x538693=0x20){const _0x2a4388=_0x1dd2;return _0x54125b[_0x2a4388(0x2aa)](_0x538693)[_0x2a4388(0x350)](_0x2a4388(0x1a1));}function _0x565686(_0x78c538){const _0x13c1ae=_0x1dd2;return _0x54125b[_0x13c1ae(0x160)](_0x13c1ae(0xa0))['update'](_0x78c538)[_0x13c1ae(0x20f)](_0x13c1ae(0x360));}function _0x11b2fb(_0x351bca,_0x24bc6b,_0x3c6787=0x36ee80){const _0x4923b7=_0x1dd2;if(!_0x24bc6b)throw new Error(_0x4923b7(0x345));const _0x4fa4fe=Date['now'](),_0x67b49b=Buffer[_0x4923b7(0xb5)](JSON[_0x4923b7(0xf3)]({'iat':_0x4fa4fe,'exp':_0x4fa4fe+_0x3c6787,'sub':_0x351bca?.['id']??_0x351bca?.[_0x4923b7(0x2b0)]??null,'username':_0x351bca?.[_0x4923b7(0x1c2)]??_0x351bca?.[_0x4923b7(0x167)]??null,'roles':Array[_0x4923b7(0x140)](_0x351bca?.[_0x4923b7(0xde)])?_0x351bca[_0x4923b7(0xde)]:[]}))[_0x4923b7(0x350)]('base64url'),_0x52c559=_0x387f5a(_0x67b49b,_0x24bc6b);return _0x67b49b+'.'+_0x52c559;}function _0x4afbfd(_0x47fd80,_0x4a4167){const _0x13e225=_0x1dd2;if(!_0x4a4167||typeof _0x47fd80!==_0x13e225(0x2f3))return null;const [_0x367be0,_0x233491]=_0x47fd80['split']('.');if(!_0x367be0||!_0x233491)return null;const _0x348daa=_0x387f5a(_0x367be0,_0x4a4167);if(!_0xfdc848(_0x233491,_0x348daa))return null;try{const _0x526026=JSON[_0x13e225(0x179)](Buffer[_0x13e225(0xb5)](_0x367be0,'base64url')[_0x13e225(0x350)]()),_0x469b60=0x7530;if(Date[_0x13e225(0x149)]()>Number(_0x526026?.[_0x13e225(0xcc)]??0x0)+_0x469b60)return null;return _0x526026;}catch{return null;}}async function _0x18bbec(_0x5eac46){return new Promise((_0x4d51d5,_0x836dc2)=>{const _0x4d49ce=_0x1dd2,_0x32ec3e=_0x54125b[_0x4d49ce(0x2aa)](0x10);_0x54125b[_0x4d49ce(0x102)](_0x5eac46,_0x32ec3e,0x40,(_0x3be54b,_0x24cf1a)=>{const _0xf21291=_0x4d49ce;if(_0x3be54b)_0x836dc2(_0x3be54b);_0x4d51d5(_0x32ec3e['toString'](_0xf21291(0x360))+':'+_0x24cf1a['toString']('hex'));});});}async function _0x2deeda(_0x3994e1,_0x204953){const _0x17f556=_0x1dd2,[_0x2b1799,_0x507d8a]=_0x204953[_0x17f556(0xb7)](':');if(!_0x2b1799||!_0x507d8a)return![];const _0x3bf251=Buffer[_0x17f556(0xb5)](_0x2b1799,'hex');return new Promise((_0x573160,_0x596acb)=>{_0x54125b['scrypt'](_0x3994e1,_0x3bf251,0x40,(_0x22c9da,_0xce6de3)=>{const _0x404546=_0x1dd2;if(_0x22c9da)_0x596acb(_0x22c9da);_0x573160(_0x54125b[_0x404546(0x263)](_0xce6de3,Buffer[_0x404546(0xb5)](_0x507d8a,'hex')));});});}return okdbAuthTokens={'hmac':_0x387f5a,'timingSafeEqual':_0xfdc848,'parseBearer':_0x140b61,'randomToken':_0xe089ba,'hashToken':_0x565686,'issueToken':_0x11b2fb,'authenticateToken':_0x4afbfd,'hashPassword':_0x18bbec,'verifyPassword':_0x2deeda},okdbAuthTokens;}var okdbLicenseCodec,hasRequiredOkdbLicenseCodec;function requireOkdbLicenseCodec(){const _0x3dba17=_0x152c38;if(hasRequiredOkdbLicenseCodec)return okdbLicenseCodec;hasRequiredOkdbLicenseCodec=0x1;const _0xe83bd1=require$$0$1,_0x10f581=_0x3dba17(0x166),_0x1781be=new Uint8Array(0x100)['fill'](0xff);for(let _0xe87dae=0x0;_0xe87dae<_0x10f581[_0x3dba17(0x1b0)];_0xe87dae++){_0x1781be[_0x10f581[_0x3dba17(0x306)](_0xe87dae)]=_0xe87dae,_0x1781be[_0x10f581[_0x3dba17(0x306)](_0xe87dae)+0x20]=_0xe87dae;}_0x1781be['O'['charCodeAt'](0x0)]=0x0,_0x1781be['o'[_0x3dba17(0x306)](0x0)]=0x0,_0x1781be['I'['charCodeAt'](0x0)]=0x1,_0x1781be['i'[_0x3dba17(0x306)](0x0)]=0x1,_0x1781be['L'[_0x3dba17(0x306)](0x0)]=0x1,_0x1781be['l'[_0x3dba17(0x306)](0x0)]=0x1;function _0x1bcfe5(_0x31ed49){const _0x1fd2df=_0x3dba17;let _0x55cd38=0x0,_0x2d42cc=0x0,_0x5ebf5b='';for(let _0x2b56d5=0x0;_0x2b56d5<_0x31ed49[_0x1fd2df(0x1b0)];_0x2b56d5++){_0x2d42cc=_0x2d42cc<<0x8|_0x31ed49[_0x2b56d5],_0x55cd38+=0x8;while(_0x55cd38>=0x5){_0x55cd38-=0x5,_0x5ebf5b+=_0x10f581[_0x2d42cc>>>_0x55cd38&0x1f];}}return _0x55cd38>0x0&&(_0x5ebf5b+=_0x10f581[_0x2d42cc<<0x5-_0x55cd38&0x1f]),_0x5ebf5b;}function _0x4146a7(_0x10e341){const _0x53184f=_0x3dba17;_0x10e341=_0x10e341[_0x53184f(0x156)](/-/g,'')[_0x53184f(0x361)]();let _0x44bbbd=0x0,_0x5207fb=0x0;const _0x539ac3=[];for(let _0x11ec0f=0x0;_0x11ec0f<_0x10e341['length'];_0x11ec0f++){const _0x298658=_0x1781be[_0x10e341['charCodeAt'](_0x11ec0f)];if(_0x298658===0xff)continue;_0x5207fb=_0x5207fb<<0x5|_0x298658,_0x44bbbd+=0x5,_0x44bbbd>=0x8&&(_0x44bbbd-=0x8,_0x539ac3[_0x53184f(0x231)](_0x5207fb>>>_0x44bbbd&0xff));}return Buffer[_0x53184f(0xb5)](_0x539ac3);}const _0x498869=[_0x3dba17(0x36a),_0x3dba17(0x25c),_0x3dba17(0x34a),_0x3dba17(0x1b6),_0x3dba17(0x32e),_0x3dba17(0x9a),'mcp',_0x3dba17(0x174)],_0x2a7c45=0x0,_0x4d82a1=0x1,_0x2b2c59=0x2,_0xcf6134=0x6*0x1e*0x18*0x3c*0x3c*0x3e8;function _0x843f65({issuedAt:_0x4cc665,expiresAt:_0x47039e,licensee:licensee='',features:features={},limits:limits={},licenseType:licenseType=_0x2a7c45}){const _0x16f57c=_0x3dba17,_0x4bdd44=Buffer['from'](licensee,_0x16f57c(0x30f))['slice'](0x0,0x40),_0xbf4cb=0x1+0x1+0x4+0x4+0x1+_0x4bdd44[_0x16f57c(0x1b0)]+0x2+0x10,_0x2e5fff=Buffer[_0x16f57c(0x1bf)](_0xbf4cb);let _0x5a0964=0x0;_0x2e5fff[_0x16f57c(0x311)](0x1,_0x5a0964++),_0x2e5fff[_0x16f57c(0x311)](licenseType,_0x5a0964++),_0x2e5fff[_0x16f57c(0xfa)](Math[_0x16f57c(0x380)](_0x4cc665/0x3e8),_0x5a0964),_0x5a0964+=0x4,_0x2e5fff['writeUInt32BE'](Math[_0x16f57c(0x380)](_0x47039e/0x3e8),_0x5a0964),_0x5a0964+=0x4,_0x2e5fff[_0x16f57c(0x311)](_0x4bdd44['length'],_0x5a0964++),_0x4bdd44[_0x16f57c(0x17f)](_0x2e5fff,_0x5a0964),_0x5a0964+=_0x4bdd44[_0x16f57c(0x1b0)];let _0xcaeae0=0x0;for(let _0x118282=0x0;_0x118282<_0x498869[_0x16f57c(0x1b0)];_0x118282++){if(features[_0x498869[_0x118282]])_0xcaeae0|=0x1<<_0x118282;}_0x2e5fff[_0x16f57c(0x233)](_0xcaeae0,_0x5a0964),_0x5a0964+=0x2;const _0x1a85e3=[_0x16f57c(0x355),_0x16f57c(0x2af),_0x16f57c(0x2e2),'maxWrites'];for(const _0x5aed68 of _0x1a85e3){_0x2e5fff['writeUInt32BE'](limits[_0x5aed68]||0x0,_0x5a0964),_0x5a0964+=0x4;}return _0x2e5fff;}function _0x304598(_0x4441b4){const _0x521df4=_0x3dba17;let _0x433345=0x0;const _0x2c9141=_0x4441b4[_0x521df4(0x35b)](_0x433345++),_0x3492cd=_0x4441b4[_0x521df4(0x35b)](_0x433345++),_0x43a858=_0x4441b4[_0x521df4(0xd0)](_0x433345);_0x433345+=0x4;const _0x4b47a8=_0x4441b4['readUInt32BE'](_0x433345);_0x433345+=0x4;const _0x587998=_0x4441b4[_0x521df4(0x35b)](_0x433345++),_0x5b510b=_0x4441b4[_0x521df4(0x341)](_0x433345,_0x433345+_0x587998)[_0x521df4(0x350)](_0x521df4(0x30f));_0x433345+=_0x587998;const _0x59f5ae=_0x4441b4[_0x521df4(0x28b)](_0x433345);_0x433345+=0x2;const _0x25d558={};for(let _0x35e617=0x0;_0x35e617<_0x498869[_0x521df4(0x1b0)];_0x35e617++){_0x25d558[_0x498869[_0x35e617]]=Boolean(_0x59f5ae&0x1<<_0x35e617);}const _0xa04f81=[_0x521df4(0x355),_0x521df4(0x2af),_0x521df4(0x2e2),_0x521df4(0x322)],_0x218517={};for(const _0x4e621c of _0xa04f81){const _0x56ea20=_0x4441b4[_0x521df4(0xd0)](_0x433345);_0x433345+=0x4,_0x218517[_0x4e621c]=_0x56ea20===0x0?null:_0x56ea20;}return{'v':_0x2c9141,'licenseType':_0x3492cd,'issuedAt':_0x43a858*0x3e8,'expiresAt':_0x4b47a8*0x3e8,'licensee':_0x5b510b,'features':_0x25d558,'limits':_0x218517};}function _0x328d27(_0x578c42,_0x4139d1){const _0x344725=_0x3dba17,_0x1388a4=Buffer[_0x344725(0x139)]([_0x578c42,_0x4139d1]),_0x119e2f=_0x1bcfe5(_0x1388a4),_0x864db0=[];for(let _0x3a4a89=0x0;_0x3a4a89<_0x119e2f['length'];_0x3a4a89+=0x8){_0x864db0['push'](_0x119e2f[_0x344725(0x341)](_0x3a4a89,_0x3a4a89+0x8));}return _0x864db0['join']('-');}function _0x51084c(_0x33126d){const _0x172c0e=_0x3dba17;if(typeof _0x33126d!==_0x172c0e(0x2f3))throw new Error(_0x172c0e(0x11b));const _0x19de28=_0x4146a7(_0x33126d[_0x172c0e(0x156)](/-/g,''));if(_0x19de28[_0x172c0e(0x1b0)]<0x41)throw new Error('decodeLicenseBlob:\x20blob\x20too\x20short\x20('+_0x19de28['length']+_0x172c0e(0x27d));const _0x3049c1=_0x19de28[_0x172c0e(0x341)](0x0,_0x19de28[_0x172c0e(0x1b0)]-0x40),_0x155545=_0x19de28[_0x172c0e(0x341)](_0x19de28[_0x172c0e(0x1b0)]-0x40);let _0x46ba63;try{_0x46ba63=_0x304598(_0x3049c1);}catch(_0x46d080){throw new Error('decodeLicenseBlob:\x20failed\x20to\x20decode\x20payload:\x20'+_0x46d080[_0x172c0e(0x307)]);}return{'rawBuf':_0x19de28,'payload':_0x3049c1,'sig':_0x155545,'decoded':_0x46ba63};}function _0x2958c1(_0x24e917){const _0x595154=_0x3dba17;return _0xe83bd1[_0x595154(0x160)](_0x595154(0xa0))[_0x595154(0x2a3)](_0x24e917)[_0x595154(0x20f)]()[_0x595154(0x341)](0x0,0x8);}function _0x11dcb1(_0x79d97d,_0x528010,_0x39d8b4){const _0x40b779=_0x3dba17,_0x2b7d02=_0x40b779(0x314)+_0x39d8b4,_0x438112=Buffer[_0x40b779(0x139)]([Buffer[_0x40b779(0xb5)](_0x79d97d,_0x40b779(0x30f)),_0x528010]),_0x402605=_0xe83bd1['createHmac']('sha256',_0x2b7d02)['update'](_0x438112)[_0x40b779(0x20f)](),_0x535d8f=_0x1bcfe5(_0x402605[_0x40b779(0x341)](0x0,0x5));return{'pin':_0x535d8f,'pinHmac':_0x402605};}function _0x4650e7(_0x186b55,_0x5dc75e,_0x476934){const _0x20621d=_0x3dba17,_0x1e116a=Buffer[_0x20621d(0x1bf)](0x4d);let _0x5ae934=0x0;_0x1e116a[_0x20621d(0x311)](0x1,_0x5ae934++),_0x186b55[_0x20621d(0x17f)](_0x1e116a,_0x5ae934),_0x5ae934+=0x8,_0x1e116a[_0x20621d(0xfa)](_0x5dc75e,_0x5ae934),_0x5ae934+=0x4,_0x476934[_0x20621d(0x17f)](_0x1e116a,_0x5ae934);const _0x4dae58=_0x1bcfe5(_0x1e116a),_0x3d19d5=[];for(let _0x2d9c76=0x0;_0x2d9c76<_0x4dae58['length'];_0x2d9c76+=0x6){_0x3d19d5[_0x20621d(0x231)](_0x4dae58[_0x20621d(0x341)](_0x2d9c76,_0x2d9c76+0x6));}return _0x3d19d5[_0x20621d(0x161)]('-');}function _0x35960c(_0x31a11a){const _0x4e9d51=_0x3dba17;if(typeof _0x31a11a!==_0x4e9d51(0x2f3))throw new Error('decodeActivationToken:\x20input\x20must\x20be\x20a\x20string');const _0x3b2f00=_0x4146a7(_0x31a11a[_0x4e9d51(0x156)](/-/g,''));if(_0x3b2f00[_0x4e9d51(0x1b0)]!==0x4d)throw new Error(_0x4e9d51(0x369)+_0x3b2f00[_0x4e9d51(0x1b0)]);let _0x434760=0x0;const _0x4153c7=_0x3b2f00['readUInt8'](_0x434760++),_0x2a18fa=_0x3b2f00[_0x4e9d51(0x341)](_0x434760,_0x434760+0x8);_0x434760+=0x8;const _0xe1b91f=_0x3b2f00['readUInt32BE'](_0x434760);_0x434760+=0x4;const _0x549fc7=_0x3b2f00[_0x4e9d51(0x341)](_0x434760);return{'v':_0x4153c7,'licenseHash':_0x2a18fa,'expiry':_0xe1b91f,'sig':_0x549fc7};}function _0x75ae52({tokenString:_0x19d612,nodeId:_0x20d591,rawBlobBuf:_0x5c9e8b,pubKeyPem:_0x370027,pubFingerprint:_0x3b2dc6}){const _0x21ba79=_0x3dba17;let _0xcf5f2c;try{_0xcf5f2c=_0x35960c(_0x19d612);}catch(_0x5aede3){return{'valid':![],'reason':_0x21ba79(0x1f4)};}const _0xdc9d97=_0x2958c1(_0x5c9e8b);if(!_0xdc9d97[_0x21ba79(0x1f7)](_0xcf5f2c[_0x21ba79(0x9c)]))return{'valid':![],'reason':_0x21ba79(0xfc)};const {pinHmac:_0x409f2d}=_0x11dcb1(_0x20d591,_0xdc9d97,_0x3b2dc6),_0xec8847=Buffer['allocUnsafe'](0x4);_0xec8847[_0x21ba79(0xfa)](_0xcf5f2c[_0x21ba79(0x143)],0x0);const _0x562ad2=Buffer[_0x21ba79(0x139)]([Buffer['from']([_0xcf5f2c['v']]),_0x409f2d[_0x21ba79(0x341)](0x0,0x5),_0xcf5f2c[_0x21ba79(0x9c)],_0xec8847]);try{const _0x3324a4=_0xe83bd1[_0x21ba79(0x34c)](null,_0x562ad2,_0x370027,_0xcf5f2c[_0x21ba79(0x1ea)]);if(!_0x3324a4)return{'valid':![],'reason':'SIG_INVALID'};}catch(_0x2b9403){return{'valid':![],'reason':_0x21ba79(0x18a)};}if(_0xcf5f2c[_0x21ba79(0x143)]<Date[_0x21ba79(0x149)]()/0x3e8)return{'valid':![],'reason':'ACTIVATION_EXPIRED'};return{'valid':!![],'reason':'ok'};}function _0x284602(_0x5203ed){const _0x270189=_0x3dba17;if(typeof _0x5203ed!==_0x270189(0x2f3))return _0x270189(0x32b);const _0x390681=_0x5203ed[_0x270189(0x15e)]();if(_0x390681[_0x270189(0x1ef)]('/')||_0x390681[_0x270189(0x1ef)]('./')||_0x390681['startsWith'](_0x270189(0x23c))||/^[A-Za-z]:[\\/]/[_0x270189(0x2f5)](_0x390681))return _0x270189(0x348);if(/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i['test'](_0x390681))return _0x270189(0x297);const _0x462376=_0x390681[_0x270189(0x156)](/[\s-]+/g,'')[_0x270189(0x1b0)];if(_0x462376===0x7c)return _0x270189(0x2e0);if(_0x462376>=0x95&&_0x462376<=0xfc)return'blob';return _0x270189(0x32b);}return okdbLicenseCodec={'toBase32':_0x1bcfe5,'fromBase32':_0x4146a7,'encodeLicensePayload':_0x843f65,'decodeLicensePayload':_0x304598,'encodeLicenseBlob':_0x328d27,'decodeLicenseBlob':_0x51084c,'licenseHash':_0x2958c1,'derivePin':_0x11dcb1,'encodeActivationToken':_0x4650e7,'decodeActivationToken':_0x35960c,'verifyActivation':_0x75ae52,'detectInputType':_0x284602,'FEATURE_NAMES':_0x498869,'LICENSE_TYPE_STANDARD':_0x2a7c45,'LICENSE_TYPE_OPEN':_0x4d82a1,'LICENSE_TYPE_INTERNAL':_0x2b2c59,'OPEN_LICENSE_MAX_DURATION_MS':_0xcf6134},okdbLicenseCodec;}var okdbError,hasRequiredOkdbError;function requireOkdbError(){if(hasRequiredOkdbError)return okdbError;hasRequiredOkdbError=0x1;class _0x3f1ae9 extends Error{constructor(_0x473cd7,_0x553426,_0x431cd3={}){const _0x3d2451=_0x1dd2;super(_0x473cd7),this['name']=_0x3d2451(0x208),this['code']=_0x553426,this[_0x3d2451(0x1b1)]=_0x431cd3,_0x431cd3[_0x3d2451(0x346)]&&(this[_0x3d2451(0x346)]=_0x431cd3['cause']),Error[_0x3d2451(0x228)](this,this['constructor']);}}class _0x612b54 extends _0x3f1ae9{constructor(_0x1c0058,_0x4c622a,_0x13e0bf,_0x39ad11){const _0x1dc37a=_0x1dd2;super(_0x1dc37a(0x24a)+_0x1c0058+'@'+_0x4c622a+_0x1dc37a(0x19b)+_0x13e0bf+_0x1dc37a(0x145)+_0x39ad11,_0x1dc37a(0x1cc),{'type':_0x1c0058,'key':_0x4c622a,'expectedVersion':_0x13e0bf,'actualVersion':_0x39ad11}),this[_0x1dc37a(0x167)]='OKDBVersionMismatchError';}}class _0x27218b extends _0x3f1ae9{constructor(_0x1b7489,_0x399a7d){const _0x5ca603=_0x1dd2;super(_0x1b7489+'@'+_0x399a7d+_0x5ca603(0xe2),_0x5ca603(0x119),{'type':_0x1b7489,'key':_0x399a7d}),this[_0x5ca603(0x167)]=_0x5ca603(0x190);}}class _0x195e38 extends _0x3f1ae9{constructor(_0xdbb398,_0x4a03f3){const _0x14cb4b=_0x1dd2;super(_0xdbb398+'@'+_0x4a03f3+'\x20already\x20exists',_0x14cb4b(0x302),{'type':_0xdbb398,'key':_0x4a03f3}),this[_0x14cb4b(0x167)]=_0x14cb4b(0x12a);}}class _0x15f468 extends _0x3f1ae9{constructor(_0xacb85c,_0x1eefc3){const _0x205d3e=_0x1dd2,_0x3a559c=typeof _0x1eefc3;super(_0x205d3e(0x296)+_0xacb85c+'\x27:\x20'+_0x3a559c+_0x205d3e(0x1eb)+_0x1eefc3,_0x205d3e(0x2c9),{'index':_0xacb85c,'key':_0x1eefc3,'keyType':_0x3a559c}),this[_0x205d3e(0x167)]=_0x205d3e(0x2e7);}}class _0x5562f7 extends _0x3f1ae9{constructor(_0x8fbac9){const _0x6fe259=_0x1dd2,_0x2b9dc8=typeof _0x8fbac9;super(_0x6fe259(0x2f0)+_0x2b9dc8+_0x6fe259(0xad)+_0x8fbac9,'INVALID_PRIMARY_KEY',{'key':_0x8fbac9,'keyType':_0x2b9dc8}),this[_0x6fe259(0x167)]=_0x6fe259(0x11c);}}class _0x44bd34 extends _0x3f1ae9{constructor(_0x43659a){const _0xdf92ae=_0x1dd2;super(_0xdf92ae(0x29c)+_0x43659a+_0xdf92ae(0x2bd),_0xdf92ae(0x289),{'type':_0x43659a}),this[_0xdf92ae(0x167)]=_0xdf92ae(0x13e);}}class _0x4fae61 extends _0x3f1ae9{constructor(_0x3d2709){const _0x32e5ce=_0x1dd2;super('Type\x20\x27'+_0x3d2709+'\x27\x20already\x20registered',_0x32e5ce(0xa8),{'type':_0x3d2709}),this[_0x32e5ce(0x167)]='OKDBTypeAlreadyRegisteredError';}}class _0x6f9262 extends _0x3f1ae9{constructor(_0x85c538,_0x4f954a){const _0x5a28f5=_0x1dd2;super(_0x5a28f5(0x173)+_0x4f954a+_0x5a28f5(0x31e)+_0x85c538+'\x27\x20doesn\x27t\x20exist',_0x5a28f5(0x25d),{'type':_0x85c538,'index':_0x4f954a}),this['name']='OKDBIndexNotRegisteredError';}}class _0x1004a3 extends _0x3f1ae9{constructor(_0x318090,_0x3ebc3a){const _0x489be0=_0x1dd2;super(_0x489be0(0x173)+_0x3ebc3a+'\x27\x20on\x20type\x20\x27'+_0x318090+_0x489be0(0x19f),_0x489be0(0x244),{'type':_0x318090,'index':_0x3ebc3a}),this[_0x489be0(0x167)]='OKDBIndexAlreadyRegisteredError';}}class _0xa8e908 extends _0x3f1ae9{constructor(_0x2c456b,_0x36cbeb={}){const _0x2473f5=_0x1dd2;super(_0x2c456b,_0x2473f5(0x276),_0x36cbeb),this[_0x2473f5(0x167)]=_0x2473f5(0x115);}}class _0x4e6409 extends _0x3f1ae9{constructor(_0x1df64a,_0x278ef2,_0x234a7b,_0x587a50,_0x50a164){const _0x164441=_0x1dd2;super('Unique\x20constraint\x20violated\x20on\x20'+_0x1df64a+'@'+_0x278ef2+':\x20key\x20['+_0x234a7b+_0x164441(0x211)+_0x587a50+_0x164441(0x1dc)+_0x50a164+'\x27',_0x164441(0x1c6),{'type':_0x1df64a,'index':_0x278ef2,'indexKey':_0x234a7b,'existingKey':_0x587a50,'conflictingKey':_0x50a164}),this[_0x164441(0x167)]=_0x164441(0x24e);}}class _0x825b16 extends _0x3f1ae9{constructor(_0x35e027,_0x36359e,_0x45783b){const _0x1ab0aa=_0x1dd2;super('Schema\x20validation\x20failed\x20for\x20'+_0x35e027+'@'+_0x36359e,_0x1ab0aa(0x15a),{'type':_0x35e027,'key':_0x36359e,'errors':_0x45783b}),this[_0x1ab0aa(0x167)]=_0x1ab0aa(0x2a2),this[_0x1ab0aa(0x358)]=_0x35e027,this[_0x1ab0aa(0x15b)]=_0x36359e,this[_0x1ab0aa(0x120)]=_0x45783b;}}class _0x4fe7f5 extends _0x3f1ae9{constructor(_0x46c11b,_0x158818){const _0x586a7b=_0x1dd2;super(_0x586a7b(0x373)+_0x46c11b+':\x20'+_0x158818[_0x586a7b(0x1b0)]+'\x20documents\x20fail\x20validation',_0x586a7b(0x2b2),{'type':_0x46c11b,'failures':_0x158818}),this['name']=_0x586a7b(0x193),this['type']=_0x46c11b,this[_0x586a7b(0x381)]=_0x158818;}}class _0x3cc4cc extends _0x3f1ae9{constructor(_0x5549e1,_0x13072a,_0x3cfafb,_0x3e9e99,_0x218bfb){const _0x492c93=_0x1dd2;super(_0x492c93(0x2c1)+_0x5549e1+'@'+_0x13072a+'.'+_0x3cfafb+'\x20references\x20'+_0x3e9e99+'@'+_0x218bfb+_0x492c93(0x14d),_0x492c93(0x38e),{'sourceType':_0x5549e1,'sourceKey':_0x13072a,'fieldPath':_0x3cfafb,'targetType':_0x3e9e99,'targetKey':_0x218bfb}),this['name']=_0x492c93(0xf1),this['sourceType']=_0x5549e1,this[_0x492c93(0x2a4)]=_0x13072a,this[_0x492c93(0x24b)]=_0x3cfafb,this[_0x492c93(0x287)]=_0x3e9e99,this[_0x492c93(0xc8)]=_0x218bfb;}}class _0x19c3ca extends _0x3f1ae9{constructor(_0x1808b4,_0x4e594a,_0x575d6b){const _0x30e50e=_0x1dd2;super(_0x30e50e(0xf4)+_0x1808b4+'@'+_0x4e594a+':\x20'+_0x575d6b[_0x30e50e(0x1b0)]+_0x30e50e(0x169),_0x30e50e(0x32f),{'targetType':_0x1808b4,'targetKey':_0x4e594a,'references':_0x575d6b}),this[_0x30e50e(0x167)]=_0x30e50e(0x94),this[_0x30e50e(0x287)]=_0x1808b4,this[_0x30e50e(0xc8)]=_0x4e594a,this['references']=_0x575d6b;}}class _0x271850 extends _0x3f1ae9{constructor(_0x1cb2b3,_0x482c37,_0x4f3c86){const _0x37e9eb=_0x1dd2;super(_0x37e9eb(0x2da)+_0x482c37+_0x37e9eb(0x28d)+_0x1cb2b3+'\x22\x20is\x20used\x20by:\x20'+_0x4f3c86[_0x37e9eb(0x282)](_0x1edaaf=>_0x1edaaf[_0x37e9eb(0x18b)]+':'+_0x1edaaf[_0x37e9eb(0x167)])[_0x37e9eb(0x161)](',\x20'),_0x37e9eb(0x2a9),{'type':_0x1cb2b3,'index':_0x482c37,'usedBy':_0x4f3c86}),this[_0x37e9eb(0x167)]=_0x37e9eb(0x1ba);}}return okdbError={'OKDBError':_0x3f1ae9,'OKDBVersionMismatchError':_0x612b54,'OKDBNotFoundError':_0x27218b,'OKDBAlreadyExistsError':_0x195e38,'OKDBInvalidIndexKeyError':_0x15f468,'OKDBInvalidPrimaryKeyError':_0x5562f7,'OKDBTypeNotRegisteredError':_0x44bd34,'OKDBTypeAlreadyRegisteredError':_0x4fae61,'OKDBIndexNotRegisteredError':_0x6f9262,'OKDBIndexAlreadyRegisteredError':_0x1004a3,'OKDBInvalidValueError':_0xa8e908,'OKDBUniqueConstraintError':_0x4e6409,'OKDBSchemaValidationError':_0x825b16,'OKDBSchemaCollectionError':_0x4fe7f5,'OKDBForeignKeyError':_0x3cc4cc,'OKDBForeignKeyDeleteError':_0x19c3ca,'OKDBIndexHasConsumersError':_0x271850},okdbError;}var okdbEnums,hasRequiredOkdbEnums;function requireOkdbEnums(){const _0x3a3d73=_0x152c38;if(hasRequiredOkdbEnums)return okdbEnums;hasRequiredOkdbEnums=0x1;const _0x28c2a6={'PUT':'put','REMOVE':'remove','INDEX_DROP':_0x3a3d73(0x328),'INDEX_REGISTER':_0x3a3d73(0x2d5),'INDEX_RESET':_0x3a3d73(0x101),'TYPE_REGISTER':_0x3a3d73(0x30d),'TYPE_DROP':_0x3a3d73(0x159),'FTS_REGISTER':_0x3a3d73(0x1e2),'FTS_DROP':_0x3a3d73(0x2c5),'FTS_RESET':_0x3a3d73(0x1e3),'SCHEMA_SET':'setSchema','SCHEMA_DROP':_0x3a3d73(0x35c),'TTL_SET':'setTtl','TTL_CLEAR':_0x3a3d73(0xe9)},_0x2bed8b={'SYSTEM_READY':_0x3a3d73(0x1c3),'SYSTEM_STOPPED':'system:stopped','SYSTEM_CLOCK_CHANGE':_0x3a3d73(0xd3),'SYSTEM_POKE':_0x3a3d73(0x26c),'SYSTEM_DRAIN':_0x3a3d73(0x221),'SYSTEM_BUS_STATE_CHANGE':'system:bus_state_change','ITEM_CREATE':'item:create','ITEM_UPDATE':'item:update','ITEM_REMOVE':_0x3a3d73(0x2df),'INDEX_RESET':'index:reset','INDEX_READY':_0x3a3d73(0x92),'INDEX_PROGRESS':_0x3a3d73(0x136),'INDEX_DROP':_0x3a3d73(0x2bc),'INDEX_REGISTERED':'index:registered','FTS_REGISTERED':_0x3a3d73(0x243),'FTS_DROP':_0x3a3d73(0x225),'FTS_RESET':_0x3a3d73(0x222),'SCHEMA_SET':_0x3a3d73(0x191),'SCHEMA_DROP':'schema:drop','UNIQUE_VIOLATION':_0x3a3d73(0x1aa),'UNIQUE_VIOLATION_RESOLVED':_0x3a3d73(0x30a),'REF_VIOLATION':_0x3a3d73(0x34d),'REF_VIOLATION_RESOLVED':'ref:violation_resolved','SYNC_APPLY':_0x3a3d73(0x383),'TXN_START':_0x3a3d73(0x1c4),'TXN_END':_0x3a3d73(0x1ed),'TXN_ROLLBACK':_0x3a3d73(0xae),'TYPE_REGISTERED':_0x3a3d73(0x34e),'TYPE_DROP':_0x3a3d73(0xaa),'ENV_OPENED':_0x3a3d73(0xf5),'ENV_REMOVED':'env:removed','TTL_EXPIRED':_0x3a3d73(0x199),'TTL_SET':'ttl:set','TTL_CLEAR':'ttl:clear','LICENSE_INVALID':_0x3a3d73(0x374),'LICENSE_ADDED':_0x3a3d73(0x246),'LICENSE_ACTIVATED':_0x3a3d73(0x17d),'LICENSE_REMOVED':_0x3a3d73(0x37a)},_0x4bfc36={'CREATING':_0x3a3d73(0x220),'RESETTING':_0x3a3d73(0x111),'READY':_0x3a3d73(0x2be),'DROPPING':_0x3a3d73(0x207),'WAITING':_0x3a3d73(0x324)},_0x5b4f52={'CREATED':_0x3a3d73(0x18d),'STARTING':_0x3a3d73(0x265),'STARTED':_0x3a3d73(0xed),'STOPPING':_0x3a3d73(0x1e7),'STOPPED':'stopped'},_0x2138a3={'CREATING':_0x3a3d73(0x220),'READY':_0x3a3d73(0x2be),'HALTED':_0x3a3d73(0xb8),'STOPPED':_0x3a3d73(0x286),'RESETTING':_0x3a3d73(0x111)},_0x394949=Object[_0x3a3d73(0x186)]({'POKE':'bus:poke','DRAIN':_0x3a3d73(0x13c)});return okdbEnums={'BUS_EVENTS':_0x394949,'CHANGE_ACTIONS':_0x28c2a6,'EVENTS':_0x2bed8b,'INDEX_STATE':_0x4bfc36,'OKDB_STATE':_0x5b4f52,'VIEW_STATE':_0x2138a3},okdbEnums;}function _0x1dd2(_0x47bab3,_0x24ec8b){_0x47bab3=_0x47bab3-0x84;const _0x18ba0e=_0x18ba();let _0x1dd2e2=_0x18ba0e[_0x47bab3];return _0x1dd2e2;}var okdbPubkey,hasRequiredOkdbPubkey;function requireOkdbPubkey(){const _0x814c66=_0x152c38;if(hasRequiredOkdbPubkey)return okdbPubkey;hasRequiredOkdbPubkey=0x1;const _0x45297b=require$$1,_0x1e1c7c=require$$1$1,_0x367e4a=require$$0,_0x4f3f33=_0x45297b['readFileSync'](_0x1e1c7c['join'](__dirname,'keys/public.pem'),_0x814c66(0x30f))[_0x814c66(0x15e)](),_0x267456=_0x367e4a[_0x814c66(0x1e4)](_0x4f3f33)[_0x814c66(0xc7)]({'type':'spki','format':_0x814c66(0x93)}),_0x6db8a3=_0x367e4a[_0x814c66(0x160)](_0x814c66(0xa0))[_0x814c66(0x2a3)](_0x267456)[_0x814c66(0x20f)](_0x814c66(0x360))['slice'](0x0,0x10);return okdbPubkey={'PUBLIC_KEY_PEM':_0x4f3f33,'PUB_FINGERPRINT':_0x6db8a3},okdbPubkey;}function _0x18ba(){const _0x42afa0=['createHmac','string','License\x20limit\x20exceeded:\x20','test','⚠\x20OPEN\x20LICENSE\x20ACTIVE\x20—\x20this\x20license\x20is\x20not\x20node-bound\x20and\x20is\x20intended\x20for\x20POC/demo\x20use\x20only.\x20Expires\x20in\x20','[okdb]\x20reset:\x20','\x20\x20\x20\x20pin:\x20\x20\x20\x20\x20\x20\x20','open','derivePin','migrate','/admin/index.html','env','[okdb]\x20opening\x20','No\x20tokens.','\x0a\x20\x20✓\x20License\x20added','\x20\x20Or\x20set\x20sync.address\x20in\x20.kdbconfig','ALREADY_EXISTS','help','\x20\x20\x20\x20status:\x20\x20\x20\x20active','--log-level','charCodeAt','message','child_process','code','unique:violation_resolved','types','statSync','registerType','(null)','utf8','processors/','writeUInt8','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20override\x20active\x20environment\x20for\x20this\x20call\x0a\x20\x20','4694961KOGFdu','OKDB-PIN-V1:','[okdb]\x20error:\x20token\x20with\x20name\x20\x22','line','status','\x20→\x20POST\x20/api/env/','recheck','--key','\x20\x20after\x20sync.\x20Duplicate\x20names\x20will\x20surface\x20as\x20ambiguous\x20logins\x20to\x20clean\x20up.','Activation\x20invalid:\x20','\x0d[okdb]\x20blobs:\x20','\x27\x20on\x20type\x20\x27','toLocaleString','\x0a\x20\x20\x20\x20','\x20\x20\x20\x20port:\x20\x20','maxWrites','wrong_node','waiting','\x20\x20║','body','\x20\x20\x20\x20api:\x20\x20\x20http://localhost:','dropIndex','type/','\x20\x20⚠','unknown','/api','application/json','timeMachine','FOREIGN_KEY_DELETE_RESTRICTED','/type/users\x0a\x20\x20\x20\x20','warn','open\x20','type/users','\x20\x20\x20\x20admin:\x20http://localhost:','\x20\x20changes=','hasOwnProperty','Embeddings','result','Processors','206730ZoxxZi','every','CREATED','\x20\x20\x20http://localhost:','blob','Full-text\x20search','\x20\x20Usage:\x20','slice','SIGINT','./okdb-export.ndjson','\x20\x20✓\x20joined\x20and\x20reconciliation\x20initiated','Token\x20secret\x20not\x20configured','cause','object','path','summary','engines','\x20envs','verify','ref:violation','type:registered','\x20\x20Writes:\x20\x20','toString','logRequests','pause','time','hidden','envs','[okdb]\x20error:\x20join\x20requires\x20credentials.\x20Provide\x20--token\x20<t>\x20or\x20--username\x20<u>\x20--password\x20<p>','[okdb]\x20nothing\x20to\x20reset\x20—\x20','type','writeFileSync','toFixed','readUInt8','dropSchema','import','ttl','changes','hex','toUpperCase','\x20\x20Usage:\x20okdb\x20license\x20[<blob|path|uuid|activation-token>]','detachConsole','setPrompt','[okdb]\x20error:\x20remove\x20requires\x20an\x20id\x20argument','includes','⚠\x20INTERNAL\x20LICENSE\x20ACTIVE\x20—\x20all\x20features\x20and\x20limits\x20are\x20unlocked.\x20For\x20vendor/internal\x20use\x20only.','peers=','decodeActivationToken:\x20expected\x2077\x20bytes,\x20got\x20','sync','\x20\x20\x20\x20\x20control\x20log\x20verbosity\x0a\x20\x20','\x20\x20records=','dbPath','ceil','existsSync','--ttl','fts:','[body]','Cannot\x20set\x20enforce\x20schema\x20on\x20','license:invalid','Records','\x0a\x20\x20Raw\x20token\x20(shown\x20once,\x20save\x20it\x20now):\x0a','\x0a\x20\x20✓\x20Token\x20created','./okdb-backup','--blobs','license:removed','\x0a\x20\x20Usage:\x20use\x20<env-name>\x0a','.\x20Add\x20a\x20license\x20that\x20includes\x20\x22','features','\x20deleted','history','floor','failures','../okdb','sync:apply','win32','padStart','.kdb_history','assertLimit','\x20\x20Common\x20causes:','types\x20--env\x20staging','\x0a[okdb]\x20fatal\x20error:','--help','\x20\x20╚═══════════════════════════╝','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20show\x20active\x20environment\x20+\x20list\x20all\x20envs\x0a\x20\x20','FOREIGN_KEY_VIOLATION','\x20\x20\x20\x20\x20\x20','--path','Environments','\x20days\x20—\x20POC/demo\x20only,\x20not\x20node-bound)','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20open\x20admin\x20UI\x20in\x20browser\x0a\x20\x20','listLicenses','[okdb]\x20error:\x20license\x20management\x20is\x20only\x20available\x20in\x20licensed\x20builds\x20(npm\x20run\x20build:prod).','\x20env','--no-repl','\x20\x20\x20\x20limits:\x20\x20\x20\x20','level','\x20environment\x20','_computeStatus','--permissions','data','\x20\x20(licenses\x20must\x20be\x20signed\x20by\x20the\x20matching\x20private\x20key)','\x0a\x20\x20Invalid\x20JSON:\x20','logs','index:ready','der','OKDBForeignKeyDeleteError','backup','\x20\x20\x20\x20license:\x20⚠\x20OPEN\x20—\x20','\x20\x20Example:\x20okdb\x20join\x20https://node-a.example.com\x20--token\x20<t>\x20--address\x20http://myhost:8484\x0a','type/users/item/alice','repeat','views','isFile','licenseHash','LICENSE_FEATURE_DISABLED','ROUTES','PUBLIC_KEY_PEM','sha256','\x20\x20\x20\x20writes:\x20\x20\x20\x20','hasType','input:\x20','\x20\x20Expected\x20one\x20of:','\x20\x20\x20\x20\x20\x20\x20POST\x20(body\x20implies\x20POST)\x0a\x20\x20','--username','node\x20','TYPE_ALREADY_REGISTERED','node:crypto','type:drop','QUIT','\x20\x20\x20\x201.\x20Send\x20the\x20PIN\x20above\x20(','.\x20Primary\x20keys\x20must\x20be\x20string\x20or\x20number.\x20Got:\x20','txn:rollback','\x1b[32m','[okdb]\x20export\x20complete','dirname','--port','licenseId','call','from','\x20file','split','halted','okdb.pid','\x20\x20\x20\x20expires:\x20\x20\x20','[okdb]\x20exported\x20\x20types=','\x20\x20Next\x20step\x20—\x20activate\x20the\x20license:','body:\x20','min','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/env/staging/info\x0a\x0a','toISOString','Invalid\x20license\x20blob:\x20','listening','stack','drop','crypto','green','export','targetKey','\x20\x20\x20\x20usage:\x20\x20\x20','\x20\x20✓\x20http\x20listening\x20on\x20:','rmSync','exp','\x20\x20No\x20licenses\x20stored.\x20Use\x20`okdb\x20license\x20<blob>`\x20to\x20add\x20one.','[okdb]\x20error:\x20--grants\x20must\x20be\x20valid\x20JSON\x20object','\x0a\x20\x20Delete\x20ALL\x20data\x20in\x20','readUInt32BE','\x20\x20✓\x20database\x20opened\x0a','addedAt','system:clock_change','then','free\x20tier','\x20\x20→\x20\x20','server','\x20\x20\x20\x20label:\x20\x20\x20\x20\x20\x20\x20','title','No\x20license\x20found\x20matching\x20this\x20activation\x20token','STATUS','api','log','roles','ENVS','<path>','/api/','\x20does\x20not\x20exist','white','\x20\x20✓\x20Revoked\x20token\x20','loadEnvFile','\x20\x20\x20\x20addedAt:\x20\x20\x20','LICENSE_ACTIVATION_INVALID','[okdb]\x20error:\x20--address\x20is\x20required\x20for\x20join\x20(this\x20node\x27s\x20reachable\x20sync\x20address).\x0a','clearTtl','indexOf','--types','Sync','started','/types\x0a\x20\x20\x20\x20','write','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/env/','OKDBForeignKeyError','indexToDb','stringify','Cannot\x20delete\x20','env:opened','\x20\x20\x20\x20•\x20a\x20license\x20blob\x20\x20\x20(Crockford\x20base32,\x20~150–250\x20chars)','[okdb]\x20error:\x20ambiguous\x20prefix\x20\x22','\x22.\x20Use:\x20create,\x20list,\x20revoke','_envs','writeUInt32BE','LICENSE_LIMIT_EXCEEDED','LICENSE_HASH_MISMATCH','~tokens','\x20\x20Path\x20access','invalid','logLevel','resetIndex','scrypt','database\x20path\x20writable:\x20','\x20\x20\x20\x20features:\x20\x20','--config','--password','{}[]:,\x27\x22','toLowerCase','version','\x20months\x20from\x20issuance)','\x0a\x20\x20Joining\x20cluster\x20at\x20','mkdirSync','type/users/item/alice\x20--env\x20staging','payload','[okdb]\x20error:\x20failed\x20to\x20read\x20','[okdb]\x20started\x20in\x20','resetting','_lookupByName','\x20records…','config\x20file\x20invalid:\x20','OKDBInvalidValueError','keys','[okdb]\x20exporting\x20env\x20\x22','transaction','NOT_FOUND','expiresAt','decodeLicenseBlob:\x20input\x20must\x20be\x20a\x20string','OKDBInvalidPrimaryKeyError','\x20(must\x20be\x201–65535)','10qJwlzN','\x0a\x0a\x20\x20','errors','--changes','_systemEnv','\x20\x20\x20\x20\x20explicit\x20method\x0a\x0a\x20\x20','exec','\x20\x20\x20\x20','\x0a\x20\x20No\x20documentation\x20found\x20for:\x20','\x20\x20\x20\x20name:\x20\x20\x20\x20\x20\x20\x20\x20','catch','typeSubDbs','OKDBAlreadyExistsError','\x20to\x20quit.','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20GET\x20(implicit)\x0a\x20\x20','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','getSecurityNotices','\x20\x20Usage:\x20logs\x20[on|off|debug|info|warn|error]','PUB_FINGERPRINT','\x20SECURITY\x20NOTICE','emit','EXPIRES','\x20\x20+','set','index:progress','val','events','concat','{}[]:,\x0a\x0d\x09\x20','exports','bus:drain','License\x20already\x20stored','OKDBTypeNotRegisteredError','(none)','isArray','reload','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/env/','expiry','11403016rFieuD',',\x20got\x20','readFileSync','node','xdg-open\x20','now','columns','sizeBefore','\x20logs\x20on\x20\x20','\x20which\x20does\x20not\x20exist','_ensureTokensType','licensed','\x20\x20Envs:\x20\x20\x20\x20','createdAt','\x0d[okdb]\x20','remove','licenseType','valid','replace','already\x20in\x20use','has','dropType','SCHEMA_VALIDATION_FAILED','key','[okdb]\x20invalid\x20port:\x20','exit','trim','transport:\x20','createHash','join','\x1b[34m','\x20\x20(','[okdb]\x20error:\x20no\x20token\x20with\x20id\x20\x22','exportBlobs','0123456789ABCDEFGHJKMNPQRSTVWXYZ','name','start\x20','\x20document(s)\x20reference\x20it\x20with\x20onDelete:restrict','platform','License\x20expired\x20or\x20invalidated','types/env=','some','\x20\x20·\x20','Examples','rawBuf','--grants','--env','Index\x20\x27','files','types:','7060OaDCdr','yellow','--drop','parse','find','config\x20file\x20valid:\x20','DELETE\x20type/users/item/x','license:activated','removeLicense','copy','Bearer\x20','Feature\x20not\x20available\x20on\x20free\x20tier:\x20','\x20to\x20browse\x20the\x20API,\x20','TYPES','\x0a\x20\x20✓\x20License\x20activated','--address','freeze','get','\x20\x20╔═══════════════════════════╗','Build\x20expects\x20public\x20key\x20fingerprint\x20','SIG_INVALID','kind','createInterface','created','decodeActivationToken','importBlobs','OKDBNotFoundError','schema:set','\x1b[0m','OKDBSchemaCollectionError','verifyActivation','\x20licenses','\x0a[okdb]\x20shutting\x20down…\x0a','DELETE','database\x20path\x20not\x20writable:\x20','ttl:expired','reset',':\x20expected\x20','__writeCounter','\x20\x20\x20\x20status:\x20\x20\x20\x20','available','\x27\x20is\x20already\x20registered','.kdbconfig','base64url','bold','\x22\x20(must\x20be\x20debug|info|warn|error)','put','create','queue/','%),\x20','_licenseHash','[okdb]\x20unknown\x20token\x20action:\x20\x22','unique:violation','OPEN','noAdmin','?\x0a\x20\x20Type\x20\x22yes\x22\x20to\x20confirm:\x20','[filter]','reason','length','details','LICENSED_BUILD','/type/users/query\x0a\x20\x20\x20\x20','detectInputType','grants','fts','[okdb]\x20.kdbconfig\x20already\x20exists\x20—\x20skipping','enabled','\x0a\x20\x20','OKDBIndexHasConsumersError','LABEL','SIGTERM','inputSchema','\x22\x20matches\x20','allocUnsafe','finally','\x20already\x20in\x20use','username','system:ready','txn:start','\x20\x20✓\x20','UNIQUE_CONSTRAINT','--name','search','list','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20set\x20active\x20environment\x20(persists\x20in\x20session)\x0a\x20\x20','\x20\x20\x20\x20id:\x20\x20\x20\x20\x20\x20\x20\x20','VERSION_MISMATCH','address','active','\x20\x20\x20\x20\x20\x20\x20\x20\x20OKDB\x20SHELL\x20\x20\x20\x20\x20\x20\x20\x20\x20','--token','dest','value','exportToFile','[okdb]\x20error:\x20unrecognized\x20input:\x20\x22','\x20(expires\x20in\x20','listen','\x20\x20\x20\x20id:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20type','1.6.0','.\x20The\x20active\x20license\x20does\x20not\x20enable\x20\x22','\x20\x20\x20\x20•\x20an\x20activation\x20token\x20\x20(124\x20chars)','\x27,\x20cannot\x20map\x20to\x20\x27','Open\x20licenses\x20cannot\x20exceed\x206\x20months\x20duration\x20(this\x20license\x20expires\x20','once','[okdb]\x20port\x20','terminal','shutdown','registerFts','resetFts','createPublicKey','effective','[okdb]\x20./okdb-data\x20already\x20exists\x20—\x20skipping','stopping','\x20\x20\x20\x20path:\x20\x20','port','sig','.\x20Only\x20primitives,\x20null,\x20Buffers,\x20and\x20arrays\x20are\x20allowed.\x20Got:\x20','pending','txn:end','[okdb]\x20error:\x20show\x20requires\x20an\x20id\x20argument','startsWith','[okdb]\x20error:\x20','getCount','admin','default','MALFORMED_TOKEN','operation','\x1b[2m','equals','info','[env]','\x20\x20\x20\x20envs:\x20\x20\x20\x20\x20\x20','Files','\x20\x20✗','readline','(add\x20a\x20license\x20first)','issuedAt','\x20\x20\x20\x20\x20\x20\x20','false','~licenses','\x20for\x20commands,\x20','\x20writes\x20(','unlinkSync','\x1b[31m','dropping','OKDBError','[okdb]\x20importing\x20','type/users\x20--help','padEnd','records','bind','[okdb]\x20created\x20./okdb-data','digest','homedir',']\x20already\x20maps\x20to\x20\x27','\x20MB\x20→\x20','_active','limits','[okdb]\x20error:\x20--password\x20requires\x20--name','[okdb]\x20import\x20complete','description','listRoutes','--log-requests','ENV','\x20—\x20type\x20env\x20to\x20list\x20available\x0a','activateLicense','routes','importFromFile','[okdb]\x20backup\x20complete','creating','system:drain','fts:reset','PERMISSIONS','\x20records','fts:drop','true','\x22\x20already\x20exists','captureStackTrace','null','license','stderr','active:','sort','\x20more','\x20\x20(licensee:\x20','reverse','push','http','writeUInt16BE','filter','resolve','/\x20quit\x20/\x20Ctrl+C','token','doctor','dim','VERB','tags','../','handle','\x20/\x20','GET','[okdb]\x20error:\x20no\x20license\x20with\x20id\x20\x22','\x20\x20\x20\x20pin:\x20\x20\x20\x20\x20','\x20\x20[','fts:registered','INDEX_ALREADY_REGISTERED','\x20\x20Build:\x20\x20\x20key\x20fingerprint\x20','license:added','\x20\x20⚠\x20\x20','pin','\x1b[90m','Version\x20mismatch\x20for\x20','fieldPath','byteLength','\x20\x20Tier:\x20\x20\x20\x20','OKDBUniqueConstraintError','\x20\x20skipped=','\x20\x20✓\x20Removed\x20license\x20','prompt','\x20\x20All\x20checks\x20passed.\x0a','permissions','boolean','\x20\x20\x20\x20•\x20a\x20path\x20to\x20a\x20.license\x20file','\x20\x20\x20\x20\x20\x20\x20\x20\x20browse\x20API\x20routes,\x20grouped\x20by\x20area\x0a\x20\x20','magenta','param','meta','getPins','\x20\x20@','embeddings','INDEX_NOT_REGISTERED','[on|off|level]','isInteger','PUT\x20type/users/item/x\x20{\x22n\x22:1}','max','forEach','timingSafeEqual','idx:','starting','error','./okdb-data','_license','onLicenseExpired','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20show\x20API\x20docs\x20for\x20a\x20path\x0a\x0a\x20\x20','\x20not\x20found','system:poke','__esModule','password','label','off','config','.okdb-write-test','5794635DGzRxe','stdin','keys:','INVALID_VALUE','sizeAfter','(no\x20types)','isFeatureEnabled','noRepl','red','entries','\x20bytes,\x20need\x20>=\x2065)','\x22\x20→\x20','—\x20/api/\x20is\x20auto-prefixed,\x20env\x20is\x20auto-injected','Shutting\x20down\x20due\x20to\x20license\x20expiry','License\x20signature\x20invalid:\x20','map','[okdb]\x20error:\x20revoke\x20requires\x20an\x20id\x20argument','(unset)','prototype','stopped','targetType','licensee','TYPE_NOT_REGISTERED','okdb','readUInt16BE','\x1b[37m','\x22\x20on\x20\x22','round','dynamic','\x1b[35m','\x20\x20Some\x20checks\x20failed.\x0a','expired','decodeLicenseBlob','stdout','debug','Invalid\x20index\x20key\x20type\x20for\x20\x27','uuid','envs=','addLicense','EXIT','\x20active\x20env:\x20','Type\x20\x27','count','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20show\x20this\x20help\x0a\x20\x20','\x20\x20Note:\x20this\x20node\x20has\x20existing\x20tokens.\x20They\x20will\x20coexist\x20with\x20cluster\x20tokens\x0a','\x0a\x20\x20Joined.\x20Remote\x20tokens\x20replicated.\x20You\x20can\x20now\x20log\x20in\x20with\x20cluster\x20credentials.\x0a','auth','OKDBSchemaValidationError','update','sourceKey','close','yes','1938936rjaMga','cyan','INDEX_HAS_CONSUMERS','randomBytes','\x22\x20to\x20enable\x20it.','9076Buqfzh','--env\x20<name>',',\x20label:\x20','typesPerEnv','sub','selfAddress','SCHEMA_COLLECTION_INVALID','_isFree','blobs','\x20\x20✓\x20OKDB\x20server\x20running','USE','[okdb]\x20exporting\x20blobs…','LICENSE_TYPE_OPEN','\x20\x20\x20\x20licensee:\x20\x20','children','\x0a\x20\x20License\x20details:','index:drop','\x27\x20doesn\x27t\x20exist','ready','trimStart','\x20\x20\x20\x20license:\x20','Foreign\x20key\x20violation:\x20','ACTIVATION_EXPIRED','current','\x20\x20\x20\x20-\x20The\x20activation\x20token\x20has\x20expired\x20—\x20request\x20a\x20fresh\x20one.','dropFts','getRange','safety','hint','INVALID_INDEX_KEY','method','\x20MB)','\x20\x20[okdb]\x20shutting\x20down…','\x20\x20\x20\x20graceful\x20shutdown\x0a','darwin','\x0a[okdb]\x20error:\x20','attach','4184CBXkeK','gray','\x20\x20(unlimited)','LICENSE_INVALID','registerIndex','--version','POST','type/users/query\x20{\x22active\x22:true}','assertFeature','Index\x20\x22','env/:env','randomUUID','transport','[okdb]\x20invalid\x20log\x20level:\x20\x22','item:remove','activation','/api/env/','syncPeers','number','argv','\x20\x20Usage:','use\x20<env>','OKDBInvalidIndexKeyError','mcp','\x20\x20\x20\x20permissions:\x20','\x20\x20(name:\x20','options','--label','index','decoded','Types','Invalid\x20primary\x20key\x20type:\x20','/type/users/item/alice\x0a\x20\x20\x20\x20'];_0x18ba=function(){return _0x42afa0;};return _0x18ba();}var okdbLicense,hasRequiredOkdbLicense;function requireOkdbLicense(){const _0x4d9960=_0x152c38;if(hasRequiredOkdbLicense)return okdbLicense;hasRequiredOkdbLicense=0x1;const _0x1a5e85=require$$0,{OKDBError:_0x2a30d1}=requireOkdbError(),{EVENTS:_0x5a6d0a}=requireOkdbEnums(),_0x79d811=requireOkdbLicenseCodec(),{LICENSE_TYPE_OPEN:_0x5b9ae9,LICENSE_TYPE_INTERNAL:_0x175933,OPEN_LICENSE_MAX_DURATION_MS:_0x1a2c08}=_0x79d811,_0x2e3db8=requireOkdbPubkey(),_0x1b916b={'LICENSED_BUILD':_0x4d9960(0x226),'PUBLIC_KEY_PEM':_0x2e3db8[_0x4d9960(0x9f)],'PUB_FINGERPRINT':_0x2e3db8[_0x4d9960(0x130)],'LICENSE_EXPIRED_ACTION':'log'},_0xac745f=_0x4d9960(0x202),_0x2a2a73={'features':{'sync':![],'embeddings':![],'engines':![],'fts':!![],'timeMachine':![],'views':!![],'mcp':!![],'files':!![]},'limits':{'envs':0x2,'typesPerEnv':0xa,'syncPeers':0x0,'maxWrites':0xf4240},'_isFree':!![]};async function _0xd99774(_0x53550b){const _0xc18d4e=_0x4d9960;!_0x53550b[_0xc18d4e(0xa2)](_0xac745f)&&await _0x53550b[_0xc18d4e(0x30d)](_0xac745f);}class _0x4e059a{constructor(_0x1842d6){const _0x45d4e4=_0x4d9960;this[_0x45d4e4(0x28a)]=_0x1842d6,this[_0x45d4e4(0x213)]=null;}async[_0x4d9960(0x141)](){const _0x52a31d=_0x4d9960,_0x3e22ec=this[_0x52a31d(0x28a)]['_systemEnv'];if(!_0x3e22ec||!_0x3e22ec[_0x52a31d(0xa2)](_0xac745f)){this[_0x52a31d(0x213)]=null;return;}const _0x27b5df=this[_0x52a31d(0x28a)]['id'];let _0x164991=null;for(const {key:_0x3bcdcd,value:_0x50ca87}of _0x3e22ec['getRange'](_0xac745f)){const _0x29c565=this[_0x52a31d(0x8c)](_0x50ca87,_0x27b5df);_0x29c565===_0x52a31d(0x1ce)&&!_0x164991&&(_0x164991={..._0x50ca87,'id':_0x3bcdcd,'status':_0x29c565});}this['_active']=_0x164991;if(this[_0x52a31d(0x213)]&&this[_0x52a31d(0x213)][_0x52a31d(0x154)]===_0x5b9ae9){const _0xcbeb5d=Math[_0x52a31d(0x36e)]((this[_0x52a31d(0x213)][_0x52a31d(0x11a)]-Date['now']())/0x5265c00);this['okdb']['log']?.['warn'](_0x52a31d(0x2f6)+_0xcbeb5d+'\x20day(s).',{'feature':'license','licensee':this[_0x52a31d(0x213)][_0x52a31d(0x288)],'expiresAt':new Date(this[_0x52a31d(0x213)][_0x52a31d(0x11a)])['toISOString']()});}this['_active']&&this[_0x52a31d(0x213)][_0x52a31d(0x154)]===_0x175933&&this[_0x52a31d(0x28a)][_0x52a31d(0xdd)]?.[_0x52a31d(0x331)](_0x52a31d(0x367),{'feature':_0x52a31d(0x22a),'licensee':this['_active'][_0x52a31d(0x288)]});}[_0x4d9960(0x8c)](_0x5c5b8f,_0x4a427c){const _0x5ec12e=_0x4d9960;if(!_0x5c5b8f[_0x5ec12e(0x33e)])return'invalid';let _0x22d32d;try{_0x22d32d=_0x79d811['decodeLicenseBlob'](_0x5c5b8f[_0x5ec12e(0x33e)]);}catch(_0x3ae9f6){return'invalid';}try{const _0x1d2922=_0x1a5e85['verify'](null,_0x22d32d[_0x5ec12e(0x10e)],_0x1b916b[_0x5ec12e(0x9f)],_0x22d32d[_0x5ec12e(0x1ea)]);if(!_0x1d2922)return'invalid';}catch(_0x1d6b4a){return _0x5ec12e(0xff);}if(_0x22d32d[_0x5ec12e(0x2ee)]['licenseType']===_0x175933)return'active';if(_0x22d32d[_0x5ec12e(0x2ee)][_0x5ec12e(0x11a)]<=Date[_0x5ec12e(0x149)]())return _0x5ec12e(0x292);if(_0x22d32d['decoded'][_0x5ec12e(0x154)]===_0x5b9ae9)return _0x5ec12e(0x1ce);if(!_0x5c5b8f[_0x5ec12e(0x2e0)])return _0x5ec12e(0x1ec);const _0x8e10ce=_0x79d811[_0x5ec12e(0x194)]({'tokenString':_0x5c5b8f[_0x5ec12e(0x2e0)],'nodeId':_0x4a427c,'rawBlobBuf':_0x22d32d[_0x5ec12e(0x170)],'pubKeyPem':_0x1b916b[_0x5ec12e(0x9f)],'pubFingerprint':_0x1b916b[_0x5ec12e(0x130)]});if(_0x8e10ce[_0x5ec12e(0x1af)]===_0x5ec12e(0xfc)||_0x8e10ce[_0x5ec12e(0x1af)]===_0x5ec12e(0x18a))return _0x5ec12e(0x323);if(_0x8e10ce[_0x5ec12e(0x1af)]===_0x5ec12e(0x2c2))return _0x5ec12e(0x292);if(!_0x8e10ce[_0x5ec12e(0x155)])return'wrong_node';return'active';}get[_0x4d9960(0x1ce)](){const _0x370a86=_0x4d9960;return this[_0x370a86(0x213)];}get[_0x4d9960(0x1e5)](){const _0x44cc97=_0x4d9960;return this[_0x44cc97(0x213)]??_0x2a2a73;}[_0x4d9960(0x2d9)](_0x739bf7){const _0x1c6d96=_0x4d9960;if(_0x1b916b[_0x1c6d96(0x1b2)]!==_0x1c6d96(0x226))return;const _0x2ed7be=this[_0x1c6d96(0x1e5)];if(!_0x2ed7be[_0x1c6d96(0x37d)]?.[_0x739bf7]){const _0x5f2cab=_0x2ed7be[_0x1c6d96(0x2b3)]?_0x1c6d96(0x181)+_0x739bf7+_0x1c6d96(0x37c)+_0x739bf7+_0x1c6d96(0x2ab):'Feature\x20not\x20licensed:\x20'+_0x739bf7+_0x1c6d96(0x1da)+_0x739bf7+'\x22.';throw new _0x2a30d1(_0x5f2cab,_0x1c6d96(0x9d),{'feature':_0x739bf7});}}[_0x4d9960(0x279)](_0x2ac7d5){const _0x52209a=_0x4d9960;if(_0x1b916b[_0x52209a(0x1b2)]!==_0x52209a(0x226))return!![];return!!this['effective'][_0x52209a(0x37d)]?.[_0x2ac7d5];}[_0x4d9960(0x387)](_0x1c016b,_0x43621b){const _0x4dae16=_0x4d9960;if(_0x1b916b[_0x4dae16(0x1b2)]!==_0x4dae16(0x226))return;const _0x13a641=this['effective'],_0x3b7f7f=_0x13a641[_0x4dae16(0x214)]?.[_0x1c016b];if(_0x3b7f7f===null||_0x3b7f7f===undefined||_0x3b7f7f===0x0)return;if(_0x43621b>=_0x3b7f7f)throw new _0x2a30d1(_0x4dae16(0x2f4)+_0x1c016b+'\x20('+_0x43621b+'/'+_0x3b7f7f+')',_0x4dae16(0xfb),{'limit':_0x1c016b,'current':_0x43621b,'max':_0x3b7f7f});}async[_0x4d9960(0x299)](_0x2484da){const _0x30641e=_0x4d9960;let _0x25fc73;try{_0x25fc73=_0x79d811[_0x30641e(0x293)](_0x2484da);}catch(_0x5281a8){throw new _0x2a30d1(_0x30641e(0xc1)+_0x5281a8[_0x30641e(0x307)],_0x30641e(0x2d4));}let _0x44523a;try{_0x44523a=_0x1a5e85[_0x30641e(0x34c)](null,_0x25fc73[_0x30641e(0x10e)],_0x1b916b[_0x30641e(0x9f)],_0x25fc73[_0x30641e(0x1ea)]);}catch(_0x327824){throw new _0x2a30d1(_0x30641e(0x281)+_0x327824['message'],_0x30641e(0x2d4));}if(!_0x44523a)throw new _0x2a30d1('License\x20signature\x20invalid\x20—\x20this\x20license\x20was\x20not\x20signed\x20by\x20the\x20key\x20paired\x20with\x20this\x20build.\x20'+(_0x30641e(0x189)+_0x1b916b[_0x30641e(0x130)]+'.\x20')+'Either\x20the\x20build\x20was\x20made\x20with\x20a\x20different\x20keypair,\x20or\x20the\x20license\x20was\x20issued\x20with\x20a\x20different\x20private\x20key.',_0x30641e(0x2d4),{'expectedFingerprint':_0x1b916b[_0x30641e(0x130)]});if(_0x25fc73[_0x30641e(0x2ee)][_0x30641e(0x154)]===_0x5b9ae9){const _0x35a6a1=_0x25fc73[_0x30641e(0x2ee)][_0x30641e(0x11a)]-_0x25fc73['decoded'][_0x30641e(0x1ff)];if(_0x35a6a1>_0x1a2c08)throw new _0x2a30d1(_0x30641e(0x1dd)+Math[_0x30641e(0x36e)](_0x35a6a1/(0x1e*0x5265c00))+_0x30641e(0x10a),_0x30641e(0x2d4));}const _0xc82acc=this[_0x30641e(0x28a)][_0x30641e(0x122)];await _0xd99774(_0xc82acc);const _0x276420=_0x79d811[_0x30641e(0x9c)](_0x25fc73[_0x30641e(0x170)])[_0x30641e(0x350)](_0x30641e(0x360));for(const {value:_0xa6d545}of _0xc82acc['getRange'](_0xac745f)){if(_0xa6d545[_0x30641e(0x1a8)]===_0x276420)throw new _0x2a30d1(_0x30641e(0x13d),_0x30641e(0x2d4));}const _0x3ba0c5=_0x1a5e85[_0x30641e(0x2dc)](),_0x39f3a3={'blob':_0x2484da,'activation':null,'addedAt':Date[_0x30641e(0x149)](),'_licenseHash':_0x276420,'licensee':_0x25fc73[_0x30641e(0x2ee)][_0x30641e(0x288)],'expiresAt':_0x25fc73['decoded'][_0x30641e(0x11a)],'features':_0x25fc73['decoded'][_0x30641e(0x37d)],'limits':_0x25fc73[_0x30641e(0x2ee)][_0x30641e(0x214)],'licenseType':_0x25fc73[_0x30641e(0x2ee)][_0x30641e(0x154)]};return await _0xc82acc[_0x30641e(0x1a4)](_0xac745f,_0x3ba0c5,_0x39f3a3),{'id':_0x3ba0c5,..._0x39f3a3};}async[_0x4d9960(0x21c)](_0x51fb10){const _0x33cf5f=_0x4d9960;let _0x20e907;try{_0x20e907=_0x79d811[_0x33cf5f(0x18e)](_0x51fb10);}catch(_0x4fd7f0){throw new _0x2a30d1('Invalid\x20activation\x20token:\x20'+_0x4fd7f0[_0x33cf5f(0x307)],'LICENSE_ACTIVATION_INVALID');}const _0x50317a=_0x20e907[_0x33cf5f(0x9c)][_0x33cf5f(0x350)]('hex'),_0x40d5b5=this[_0x33cf5f(0x28a)][_0x33cf5f(0x122)];if(!_0x40d5b5||!_0x40d5b5[_0x33cf5f(0xa2)](_0xac745f))throw new _0x2a30d1('No\x20license\x20found\x20matching\x20this\x20activation\x20token','LICENSE_ACTIVATION_INVALID');let _0x26d489=null,_0x34c0d=null;for(const {key:_0x15a12a,value:_0x5620f2}of _0x40d5b5[_0x33cf5f(0x2c6)](_0xac745f)){if(_0x5620f2['_licenseHash']===_0x50317a){_0x26d489=_0x15a12a,_0x34c0d=_0x5620f2;break;}}if(!_0x26d489)throw new _0x2a30d1(_0x33cf5f(0xda),'LICENSE_ACTIVATION_INVALID');const {rawBuf:_0x45747b}=_0x79d811[_0x33cf5f(0x293)](_0x34c0d[_0x33cf5f(0x33e)]),_0x52d10d=_0x79d811[_0x33cf5f(0x194)]({'tokenString':_0x51fb10,'nodeId':this[_0x33cf5f(0x28a)]['id'],'rawBlobBuf':_0x45747b,'pubKeyPem':_0x1b916b[_0x33cf5f(0x9f)],'pubFingerprint':_0x1b916b[_0x33cf5f(0x130)]});if(!_0x52d10d['valid'])throw new _0x2a30d1(_0x33cf5f(0x31c)+_0x52d10d['reason'],_0x33cf5f(0xe7),{'reason':_0x52d10d['reason']});const _0x34d235={..._0x34c0d,'activation':_0x51fb10};return await _0x40d5b5[_0x33cf5f(0x2a3)](_0xac745f,_0x26d489,_0x34d235),{'id':_0x26d489,..._0x34d235};}async[_0x4d9960(0x17e)](_0x731882){const _0x21d8fc=_0x4d9960,_0x479d24=this[_0x21d8fc(0x28a)][_0x21d8fc(0x122)];if(!_0x479d24||!_0x479d24[_0x21d8fc(0xa2)](_0xac745f))return;await _0x479d24[_0x21d8fc(0x153)](_0xac745f,_0x731882);}async[_0x4d9960(0x85)](){const _0x384633=_0x4d9960,_0x4cad11=this[_0x384633(0x28a)][_0x384633(0x122)];if(!_0x4cad11||!_0x4cad11['hasType'](_0xac745f))return[];const _0x448537=this[_0x384633(0x28a)]['id'],_0x388d38=[];for(const {key:_0x5380cf,value:_0x2d1771}of _0x4cad11[_0x384633(0x2c6)](_0xac745f)){const _0x4a08ef=this[_0x384633(0x8c)](_0x2d1771,_0x448537);_0x388d38['push']({..._0x2d1771,'id':_0x5380cf,'status':_0x4a08ef});}return _0x388d38;}[_0x4d9960(0x25a)](){const _0x1da484=_0x4d9960,_0x3ee6e5=this[_0x1da484(0x28a)][_0x1da484(0x122)];if(!_0x3ee6e5||!_0x3ee6e5[_0x1da484(0xa2)](_0xac745f))return[];const _0x5992ce=this[_0x1da484(0x28a)]['id'],_0x4f844f=[];for(const {key:_0xf7af5e,value:_0x12494f}of _0x3ee6e5[_0x1da484(0x2c6)](_0xac745f)){if(_0x12494f[_0x1da484(0x1a8)]){if(_0x12494f[_0x1da484(0x154)]===_0x5b9ae9)_0x4f844f[_0x1da484(0x231)]({'licenseId':_0xf7af5e,'pin':null});else{const _0x3d82e3=Buffer[_0x1da484(0xb5)](_0x12494f['_licenseHash'],_0x1da484(0x360)),{pin:_0x44db42}=_0x79d811[_0x1da484(0x2fa)](_0x5992ce,_0x3d82e3,_0x1b916b['PUB_FINGERPRINT']);_0x4f844f[_0x1da484(0x231)]({'licenseId':_0xf7af5e,'pin':_0x44db42});}}}return _0x4f844f;}async[_0x4d9960(0x319)](){const _0x2471e5=_0x4d9960,_0x33bd69=this['_active'];await this[_0x2471e5(0x141)]();if(this[_0x2471e5(0x213)]&&this['_active'][_0x2471e5(0x154)]===_0x5b9ae9){const _0x502a79=Math['ceil']((this['_active'][_0x2471e5(0x11a)]-Date[_0x2471e5(0x149)]())/0x5265c00);this['okdb']['log']?.['warn'](_0x2471e5(0x2f6)+_0x502a79+'\x20day(s).',{'feature':_0x2471e5(0x22a),'licensee':this[_0x2471e5(0x213)]['licensee'],'expiresAt':new Date(this[_0x2471e5(0x213)][_0x2471e5(0x11a)])[_0x2471e5(0xc0)]()});}this[_0x2471e5(0x213)]&&this[_0x2471e5(0x213)][_0x2471e5(0x154)]===_0x175933&&this[_0x2471e5(0x28a)]['log']?.[_0x2471e5(0x331)](_0x2471e5(0x367),{'feature':_0x2471e5(0x22a),'licensee':this[_0x2471e5(0x213)][_0x2471e5(0x288)]});if(_0x33bd69&&!this[_0x2471e5(0x213)]){this[_0x2471e5(0x28a)][_0x2471e5(0xdd)]?.[_0x2471e5(0x331)](_0x2471e5(0x16b),{'feature':_0x2471e5(0x22a)}),this['okdb'][_0x2471e5(0x138)]?.[_0x2471e5(0x132)](_0x5a6d0a[_0x2471e5(0x2d4)],{'previous':_0x33bd69});const _0x3693eb=this['okdb'][_0x2471e5(0x2eb)]?.[_0x2471e5(0x269)]??_0x1b916b['LICENSE_EXPIRED_ACTION'];_0x3693eb===_0x2471e5(0x1e1)&&(this[_0x2471e5(0x28a)][_0x2471e5(0xdd)]?.['error'](_0x2471e5(0x280),{'feature':_0x2471e5(0x22a)}),this[_0x2471e5(0x28a)]['close']()['catch'](()=>{})[_0x2471e5(0x1c0)](()=>process[_0x2471e5(0x15d)](0x1)));}}}return okdbLicense={'LicenseChecker':_0x4e059a,'_C':_0x1b916b},okdbLicense;}var okdbShell,hasRequiredOkdbShell;function requireOkdbShell(){const _0x42fa8f=_0x152c38;if(hasRequiredOkdbShell)return okdbShell;hasRequiredOkdbShell=0x1;const _0x4caf77=require$$0$2,_0xe972e0=require$$1,_0x338959=require$$2$1,_0x38b637=require$$1$1,_0x26105a=_0x38b637['join'](_0x338959[_0x42fa8f(0x210)](),_0x42fa8f(0x386)),_0x2504a4=0x3e8,_0x11b2f7={'reset':_0x42fa8f(0x192),'bold':'\x1b[1m','dim':_0x42fa8f(0x1f6),'red':_0x42fa8f(0x206),'green':_0x42fa8f(0xaf),'yellow':'\x1b[33m','blue':_0x42fa8f(0x162),'magenta':_0x42fa8f(0x290),'cyan':'\x1b[36m','white':_0x42fa8f(0x28c),'gray':_0x42fa8f(0x249)},_0xd217bf=!process['stdout']['isTTY']||!!process.env.NO_COLOR,_0x89fdf=(_0x4d60fb,_0x36c91b)=>_0xd217bf?_0x36c91b:''+_0x4d60fb+_0x36c91b+_0x11b2f7[_0x42fa8f(0x19a)],_0x18aa8e={'error':_0x11b2f7[_0x42fa8f(0x27b)],'warn':_0x11b2f7[_0x42fa8f(0x177)],'info':_0x11b2f7['cyan'],'debug':_0x11b2f7[_0x42fa8f(0x2d2)]},_0x1b2c94={'debug':0x0,'info':0x1,'warn':0x2,'error':0x3};function _0x263a36(_0x3f4aff,_0x22e605='info'){const _0x1da9a4=_0x42fa8f,{level:_0x5aee4a,msg:_0x298c09,meta:_0x40a45f,context:_0x43a821,ts:_0x15201f}=_0x3f4aff;if((_0x1b2c94[_0x5aee4a]??0x1)<(_0x1b2c94[_0x22e605]??0x1))return;const _0x168949=_0x89fdf(_0x11b2f7['gray'],new Date(_0x15201f)[_0x1da9a4(0xc0)]()),_0x57f5d0=_0x89fdf(_0x18aa8e[_0x5aee4a]??_0x11b2f7[_0x1da9a4(0xe3)],_0x5aee4a[_0x1da9a4(0x20b)](0x5));let _0x28593a='\x20\x20'+_0x168949+'\x20'+_0x89fdf(_0x11b2f7[_0x1da9a4(0x1a2)],_0x57f5d0)+'\x20'+_0x298c09;if(_0x40a45f&&Object[_0x1da9a4(0x116)](_0x40a45f)[_0x1da9a4(0x1b0)]>0x0){const _0x4243fc=Object['entries'](_0x40a45f)[_0x1da9a4(0x282)](([_0x3d139b,_0x2e1f8e])=>_0x3d139b+'='+_0x2e1f8e)[_0x1da9a4(0x161)]('\x20');_0x28593a+=_0x89fdf(_0x11b2f7['dim'],_0x1da9a4(0x242)+_0x4243fc+']');}if(_0x43a821!==undefined){const _0x1d689=typeof _0x43a821===_0x1da9a4(0x347)?JSON[_0x1da9a4(0xf3)](_0x43a821):String(_0x43a821);_0x28593a+=_0x89fdf(_0x11b2f7[_0x1da9a4(0x239)],'\x20\x20'+_0x1d689);}const _0x340d9a=_0x5aee4a===_0x1da9a4(0x266)||_0x5aee4a===_0x1da9a4(0x331)?process[_0x1da9a4(0x22b)][_0x1da9a4(0xef)][_0x1da9a4(0x20d)](process[_0x1da9a4(0x22b)]):process[_0x1da9a4(0x294)][_0x1da9a4(0xef)][_0x1da9a4(0x20d)](process[_0x1da9a4(0x294)]);_0x340d9a(_0x28593a+'\x0a');}function _0x5a56a0(_0xff9650,_0x139e6a){const _0x1abba1=_0x42fa8f;if(_0xff9650===0xcc||_0xff9650>=0xc8&&_0xff9650<0x12c&&!_0x139e6a){console[_0x1abba1(0xdd)](_0x1abba1(0x1b9)+_0x89fdf(_0x11b2f7[_0x1abba1(0xc6)],'✓')+'\x0a');return;}if(_0xff9650>=0x190||_0x139e6a?.['error']){const _0x370403=_0x139e6a?.[_0x1abba1(0x266)]??_0x139e6a?.[_0x1abba1(0x307)]??'HTTP\x20'+_0xff9650;console[_0x1abba1(0xdd)]('\x0a\x20\x20'+_0x89fdf(_0x11b2f7[_0x1abba1(0x27b)],'✗')+'\x20'+_0x89fdf(_0x11b2f7['bold']+_0x11b2f7[_0x1abba1(0x27b)],String(_0xff9650))+'\x20\x20'+_0x370403+'\x0a');return;}const _0x66be2b=Object[_0x1abba1(0x285)][_0x1abba1(0x336)][_0x1abba1(0xb4)](_0x139e6a??{},_0x1abba1(0x338))?_0x139e6a[_0x1abba1(0x338)]:_0x139e6a,_0x12d460=_0x139e6a?.['meta'];console['log'](''),_0x1f2b9e(_0x66be2b,'\x20\x20');if(_0x12d460?.[_0x1abba1(0x29d)]!=null||_0x12d460?.[_0x1abba1(0x353)]!=null){const _0x337bf4=[];if(_0x12d460['count']!=null)_0x337bf4['push'](_0x12d460[_0x1abba1(0x29d)]+'\x20result'+(_0x12d460[_0x1abba1(0x29d)]!==0x1?'s':''));if(_0x12d460[_0x1abba1(0x353)]!=null)_0x337bf4['push'](_0x12d460[_0x1abba1(0x353)]+'ms');console['log'](_0x1abba1(0x1b9)+_0x89fdf(_0x11b2f7[_0x1abba1(0x239)],_0x337bf4[_0x1abba1(0x161)]('\x20\x20·\x20\x20')));}console[_0x1abba1(0xdd)]('');}function _0x1f2b9e(_0x2bd5b8,_0x10ee2e=''){const _0x2d3f58=_0x42fa8f;if(_0x2bd5b8===null||_0x2bd5b8===undefined){console['log'](_0x10ee2e+_0x89fdf(_0x11b2f7['dim'],_0x2d3f58(0x30e)));return;}if(Array['isArray'](_0x2bd5b8)){if(_0x2bd5b8[_0x2d3f58(0x1b0)]===0x0){console[_0x2d3f58(0xdd)](_0x10ee2e+_0x89fdf(_0x11b2f7[_0x2d3f58(0x239)],'(empty)'));return;}if(_0x2bd5b8['every'](_0x3919f2=>_0x3919f2&&typeof _0x3919f2===_0x2d3f58(0x347)&&_0x2d3f58(0x15b)in _0x3919f2&&_0x2d3f58(0x1d2)in _0x3919f2)){_0x19fc3a(_0x2bd5b8,_0x10ee2e);return;}if(_0x2bd5b8[_0x2d3f58(0x33b)](_0x464259=>_0x464259&&typeof _0x464259==='object'&&_0x2d3f58(0x358)in _0x464259&&_0x2d3f58(0x29d)in _0x464259)){_0x562255(_0x2bd5b8,_0x10ee2e);return;}if(_0x2bd5b8[_0x2d3f58(0x33b)](_0x2a3292=>typeof _0x2a3292!=='object'||_0x2a3292===null)){_0x2bd5b8[_0x2d3f58(0x262)]((_0x661939,_0x5ae58c)=>console['log'](_0x10ee2e+_0x89fdf(_0x11b2f7[_0x2d3f58(0x2d2)],_0x5ae58c+0x1+'.')+'\x20'+_0x89fdf(_0x11b2f7[_0x2d3f58(0xe3)],String(_0x661939))));return;}_0x2bd5b8[_0x2d3f58(0x262)]((_0x5b0a76,_0xf3db8d)=>{const _0x273399=_0x2d3f58;console[_0x273399(0xdd)](_0x10ee2e+_0x89fdf(_0x11b2f7[_0x273399(0x239)],'['+_0xf3db8d+']'));if(typeof _0x5b0a76===_0x273399(0x347)&&_0x5b0a76!==null)_0x20d724(_0x5b0a76,_0x10ee2e+'\x20\x20');else console[_0x273399(0xdd)](_0x10ee2e+'\x20\x20'+String(_0x5b0a76));});return;}if(typeof _0x2bd5b8==='object'){if(_0x2d3f58(0x15b)in _0x2bd5b8&&_0x2d3f58(0x1d2)in _0x2bd5b8&&Object[_0x2d3f58(0x116)](_0x2bd5b8)[_0x2d3f58(0x1b0)]<=0x3){console['log'](_0x10ee2e+_0x89fdf(_0x11b2f7[_0x2d3f58(0x1a2)]+_0x11b2f7[_0x2d3f58(0x2a8)],String(_0x2bd5b8['key'])));const _0x7798a3=_0x2bd5b8[_0x2d3f58(0x1d2)];if(_0x7798a3&&typeof _0x7798a3==='object')_0x20d724(_0x7798a3,_0x10ee2e);else console[_0x2d3f58(0xdd)](_0x10ee2e+_0x89fdf(_0x11b2f7[_0x2d3f58(0xe3)],String(_0x7798a3)));return;}_0x20d724(_0x2bd5b8,_0x10ee2e);return;}console['log'](_0x10ee2e+_0x89fdf(_0x11b2f7[_0x2d3f58(0xe3)],String(_0x2bd5b8)));}function _0x20d724(_0xeddde0,_0x19f0e9=''){const _0x30153d=_0x42fa8f,_0x3d6b5f=Object[_0x30153d(0x27c)](_0xeddde0);if(_0x3d6b5f[_0x30153d(0x1b0)]===0x0){console[_0x30153d(0xdd)](_0x19f0e9+_0x89fdf(_0x11b2f7[_0x30153d(0x239)],'{}'));return;}const _0x3f1407=Math[_0x30153d(0xbe)](0x1c,Math[_0x30153d(0x261)](..._0x3d6b5f[_0x30153d(0x282)](([_0x2b0642])=>_0x2b0642[_0x30153d(0x1b0)])));for(const [_0x28014b,_0x17a310]of _0x3d6b5f){const _0x440f20=_0x89fdf(_0x11b2f7[_0x30153d(0x2a8)],_0x28014b[_0x30153d(0x20b)](_0x3f1407));if(_0x17a310===null||_0x17a310===undefined)console[_0x30153d(0xdd)](_0x19f0e9+_0x440f20+'\x20\x20'+_0x89fdf(_0x11b2f7[_0x30153d(0x239)],_0x30153d(0x229)));else{if(typeof _0x17a310===_0x30153d(0x347)){const _0x523634=JSON[_0x30153d(0xf3)](_0x17a310);_0x523634[_0x30153d(0x1b0)]<=0x50?console[_0x30153d(0xdd)](_0x19f0e9+_0x440f20+'\x20\x20'+_0x89fdf(_0x11b2f7[_0x30153d(0x239)],_0x523634)):(console['log'](_0x19f0e9+_0x440f20),_0x1f2b9e(_0x17a310,_0x19f0e9+'\x20\x20'));}else{const _0x19d57c=typeof _0x17a310===_0x30153d(0x254)?_0x89fdf(_0x17a310?_0x11b2f7[_0x30153d(0xc6)]:_0x11b2f7['yellow'],String(_0x17a310)):typeof _0x17a310===_0x30153d(0x2e3)?_0x89fdf(_0x11b2f7['magenta'],String(_0x17a310)):_0x89fdf(_0x11b2f7['white'],String(_0x17a310));console[_0x30153d(0xdd)](_0x19f0e9+_0x440f20+'\x20\x20'+_0x19d57c);}}}}function _0x19fc3a(_0x1f37d6,_0x4f9098=''){const _0x49d882=_0x42fa8f,_0x395ea2=Math[_0x49d882(0xbe)](0x20,Math[_0x49d882(0x261)](..._0x1f37d6['map'](_0x431e6e=>String(_0x431e6e[_0x49d882(0x15b)])[_0x49d882(0x1b0)])));for(const {key:_0xbb3203,value:_0x37ec04,score:_0x1eade7,clock:_0x2c7dbf}of _0x1f37d6){const _0x161566=_0x89fdf(_0x11b2f7['bold']+_0x11b2f7[_0x49d882(0x2a8)],String(_0xbb3203)[_0x49d882(0x20b)](_0x395ea2)),_0x2ccf93=_0x37ec04==null?_0x89fdf(_0x11b2f7[_0x49d882(0x239)],_0x49d882(0x229)):typeof _0x37ec04==='object'?_0x89fdf(_0x11b2f7['dim'],JSON[_0x49d882(0xf3)](_0x37ec04)):_0x89fdf(_0x11b2f7[_0x49d882(0xe3)],String(_0x37ec04)),_0x3ce274=_0x1eade7!=null?_0x89fdf(_0x11b2f7[_0x49d882(0x2d2)],'\x20\x20score:'+_0x1eade7[_0x49d882(0x35a)](0x4)):'',_0x5a5db0=_0x2c7dbf!=null?_0x89fdf(_0x11b2f7['gray'],_0x49d882(0x25b)+_0x2c7dbf):'';console[_0x49d882(0xdd)](_0x4f9098+_0x161566+'\x20\x20'+_0x2ccf93+_0x3ce274+_0x5a5db0);}}function _0x562255(_0x47f340,_0x2f4df6=''){const _0x3a05f8=_0x42fa8f,_0x22f38c=Math[_0x3a05f8(0xbe)](0x20,Math[_0x3a05f8(0x261)](..._0x47f340['map'](_0x19c897=>_0x19c897['type']['length'])));for(const {type:_0x321d7e,count:_0x4751d0,fields:_0x62fb4c}of _0x47f340){if(_0x321d7e[_0x3a05f8(0x1ef)]('~'))continue;const _0x4688c2=_0x89fdf(_0x11b2f7[_0x3a05f8(0x1a2)]+_0x11b2f7[_0x3a05f8(0x2a8)],_0x321d7e[_0x3a05f8(0x20b)](_0x22f38c)),_0x274eef=_0x89fdf(_0x11b2f7[_0x3a05f8(0x257)],String(_0x4751d0)[_0x3a05f8(0x385)](0x6))+_0x89fdf(_0x11b2f7['dim'],_0x3a05f8(0x224)),_0x4bad99=_0x62fb4c&&Object[_0x3a05f8(0x116)](_0x62fb4c)[_0x3a05f8(0x1b0)]?_0x89fdf(_0x11b2f7['dim'],_0x3a05f8(0x16e)+Object[_0x3a05f8(0x116)](_0x62fb4c)['slice'](0x0,0x6)[_0x3a05f8(0x161)](',\x20')+(Object[_0x3a05f8(0x116)](_0x62fb4c)[_0x3a05f8(0x1b0)]>0x6?'…':'')):'';console[_0x3a05f8(0xdd)](_0x2f4df6+_0x4688c2+'\x20\x20'+_0x274eef+_0x4bad99);}}const _0x3c2de4=['types',_0x42fa8f(0x329),_0x42fa8f(0x1a6),'files/',_0x42fa8f(0x118),_0x42fa8f(0x310)];function _0x16edf5(_0x504656,_0x4ac1fb){const _0x259df2=_0x42fa8f;if(_0x504656['startsWith'](_0x259df2(0xe1)))return _0x504656;if(_0x504656[_0x259df2(0x1ef)]('/'))return _0x259df2(0x32c)+_0x504656;if(_0x504656[_0x259df2(0x1ef)]('env/'))return _0x259df2(0xe1)+_0x504656;const _0x18eb5e=_0x3c2de4[_0x259df2(0x16d)](_0x14b44e=>_0x504656===_0x14b44e[_0x259df2(0x156)](/\/$/,'')||_0x504656[_0x259df2(0x1ef)](_0x14b44e));return _0x18eb5e?_0x259df2(0x2e1)+_0x4ac1fb+'/'+_0x504656:_0x259df2(0xe1)+_0x504656;}function _0x1b4e59(_0x37a67b){const _0x28fd01=_0x42fa8f,_0x1fdae3={},_0x2533bf=[];let _0x37d070=0x0;while(_0x37d070<_0x37a67b[_0x28fd01(0x1b0)]){if((_0x37a67b[_0x37d070]===_0x28fd01(0x172)||_0x37a67b[_0x37d070]==='-e')&&_0x37a67b[_0x37d070+0x1]&&!_0x37a67b[_0x37d070+0x1][_0x28fd01(0x1ef)]('-'))_0x1fdae3['env']=_0x37a67b[++_0x37d070];else _0x37a67b[_0x37d070]==='--help'||_0x37a67b[_0x37d070]==='-h'?_0x1fdae3[_0x28fd01(0x303)]=!![]:_0x2533bf[_0x28fd01(0x231)](_0x37a67b[_0x37d070]);_0x37d070++;}return{'flags':_0x1fdae3,'rest':_0x2533bf};}const _0x2abba6={'system':'System','envs':_0x42fa8f(0x391),'types':_0x42fa8f(0x2ef),'data':_0x42fa8f(0x375),'indexes':'Indexes','fts':_0x42fa8f(0x33f),'sync':_0x42fa8f(0xec),'queue':'Queue','files':_0x42fa8f(0x1fb),'embeddings':_0x42fa8f(0x337),'engines':'Engines','admin':'Admin','event':'Events','processor':_0x42fa8f(0x339)},_0x407553=['system',_0x42fa8f(0x355),_0x42fa8f(0x30b),'data','indexes',_0x42fa8f(0x1b6),_0x42fa8f(0x36a),'queue',_0x42fa8f(0x174),'embeddings',_0x42fa8f(0x34a),_0x42fa8f(0x1f2)];function _0x199895(_0x861990){const _0x576933=_0x42fa8f;return _0x861990['replace'](/^\/api/,'')[_0x576933(0x156)](/^\[\/env\/:env=[^\]]*\]/,_0x576933(0x1f9))[_0x576933(0x156)](/^\/env\/:env/,_0x576933(0x2db))[_0x576933(0x156)](/^\//,'');}function _0x5226e8(_0x5cb07d,_0x3145da=''){const _0x5ac13d=_0x42fa8f,_0x1becee=_0x5cb07d['http']['listRoutes']()[_0x5ac13d(0x234)](_0x1b6342=>!_0x1b6342['meta']?.['hidden']),_0x50bf5b=_0x3145da?_0x1becee['filter'](_0x3a6326=>_0x3a6326[_0x5ac13d(0x348)][_0x5ac13d(0x108)]()[_0x5ac13d(0x366)](_0x3145da[_0x5ac13d(0x108)]())||(_0x4caf95(_0x3a6326)??'')[_0x5ac13d(0x108)]()[_0x5ac13d(0x366)](_0x3145da[_0x5ac13d(0x108)]())||_0x1d4312(_0x3a6326)[_0x5ac13d(0x16d)](_0x39e136=>_0x39e136['toLowerCase']()[_0x5ac13d(0x366)](_0x3145da['toLowerCase']()))):_0x1becee;if(!_0x50bf5b[_0x5ac13d(0x1b0)]){console['log'](_0x89fdf(_0x11b2f7['yellow'],'\x0a\x20\x20No\x20routes\x20matching\x20\x22'+_0x3145da+'\x22\x0a'));return;}const _0x4a9628=new Map();for(const _0x48bc89 of _0x50bf5b){const _0x225d57=_0x1d4312(_0x48bc89)[0x0]??'other';if(!_0x4a9628[_0x5ac13d(0x158)](_0x225d57))_0x4a9628['set'](_0x225d57,[]);_0x4a9628[_0x5ac13d(0x187)](_0x225d57)['push'](_0x48bc89);}const _0x57cb2b=[..._0x407553[_0x5ac13d(0x234)](_0x1c8d43=>_0x4a9628[_0x5ac13d(0x158)](_0x1c8d43)),...[..._0x4a9628[_0x5ac13d(0x116)]()][_0x5ac13d(0x234)](_0x372af5=>!_0x407553[_0x5ac13d(0x366)](_0x372af5))];console[_0x5ac13d(0xdd)]('');for(const _0x1eaf06 of _0x57cb2b){const _0x22397f=_0x4a9628[_0x5ac13d(0x187)](_0x1eaf06);if(!_0x22397f?.[_0x5ac13d(0x1b0)])continue;console[_0x5ac13d(0xdd)](_0x89fdf(_0x11b2f7['bold'],'\x20\x20'+(_0x2abba6[_0x1eaf06]??_0x1eaf06)));for(const _0xa8df98 of _0x22397f){const _0x500bf5=_0x89fdf(_0x11b2f7[_0x5ac13d(0x257)],_0xa8df98[_0x5ac13d(0x2ca)][_0x5ac13d(0x20b)](0x7)),_0x157d55=_0x89fdf(_0x11b2f7['cyan'],_0x199895(_0xa8df98[_0x5ac13d(0x348)])),_0x332a8f=_0x4caf95(_0xa8df98)?_0x89fdf(_0x11b2f7[_0x5ac13d(0x239)],'\x20\x20'+_0x4caf95(_0xa8df98)):'',_0x3bf0fa=_0xa8df98[_0x5ac13d(0x1f5)]?.['id']?_0x89fdf(_0x11b2f7[_0x5ac13d(0x2d2)],_0x5ac13d(0x242)+_0xa8df98[_0x5ac13d(0x1f5)]['id']+']'):'';console[_0x5ac13d(0xdd)]('\x20\x20\x20\x20'+_0x500bf5+'\x20'+_0x157d55+_0x332a8f+_0x3bf0fa);}console[_0x5ac13d(0xdd)]('');}}function _0x4ef7a5(_0x615dad,_0x52c776){const _0x5b2862=_0x42fa8f,_0x5f1b07=_0x52c776[_0x5b2862(0x156)](/^\/api(\/env\/[^/]+)?\//,'')[_0x5b2862(0xb7)]('/')[0x0],_0x54a4ed=_0x615dad[_0x5b2862(0x232)]['listRoutes']()[_0x5b2862(0x234)](_0x4ce8b9=>_0x4ce8b9[_0x5b2862(0x348)][_0x5b2862(0x108)]()[_0x5b2862(0x366)](_0x5f1b07['toLowerCase']()));if(!_0x54a4ed[_0x5b2862(0x1b0)]){console[_0x5b2862(0xdd)](_0x89fdf(_0x11b2f7[_0x5b2862(0x177)],_0x5b2862(0x126)+_0x52c776+'\x0a'));return;}console[_0x5b2862(0xdd)]('');for(const _0x58737d of _0x54a4ed[_0x5b2862(0x341)](0x0,0xc)){for(const _0x4cd0e5 of _0x3d612c(_0x58737d)){console[_0x5b2862(0xdd)](_0x4cd0e5);}console['log']('');}}function _0x4caf95(_0x3920fd){const _0x27facf=_0x42fa8f;return _0x3920fd[_0x27facf(0x1f5)]?.['summary']??_0x3920fd['meta']?.[_0x27facf(0x349)]??'';}function _0x5b4d99(_0x6d2279){const _0x200532=_0x42fa8f;return _0x6d2279[_0x200532(0x1f5)]?.['description']??_0x6d2279['meta']?.[_0x200532(0x217)]??'';}function _0x1d4312(_0x39e3ba){const _0x59c5ec=_0x42fa8f;return _0x39e3ba[_0x59c5ec(0x1f5)]?.[_0x59c5ec(0x23b)]?.[_0x59c5ec(0x1b0)]?_0x39e3ba[_0x59c5ec(0x1f5)][_0x59c5ec(0x23b)]:_0x39e3ba[_0x59c5ec(0x259)]?.['tags']??[];}function _0x3d612c(_0x1e9073){const _0x75356a=_0x42fa8f,_0x438931=[];_0x438931[_0x75356a(0x231)]('\x20\x20'+_0x89fdf(_0x11b2f7[_0x75356a(0x1a2)]+_0x11b2f7[_0x75356a(0x257)],_0x1e9073[_0x75356a(0x2ca)]['padEnd'](0x7))+'\x20'+_0x89fdf(_0x11b2f7['bold']+_0x11b2f7[_0x75356a(0x2a8)],_0x1e9073[_0x75356a(0x348)]));_0x1e9073[_0x75356a(0x1f5)]?.['id']&&_0x438931[_0x75356a(0x231)]('\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+_0x89fdf(_0x11b2f7[_0x75356a(0x2d2)],'id:\x20'+_0x1e9073['operation']['id']));_0x4caf95(_0x1e9073)&&_0x438931[_0x75356a(0x231)](_0x75356a(0x12d)+_0x89fdf(_0x11b2f7['white'],_0x4caf95(_0x1e9073)));_0x5b4d99(_0x1e9073)&&_0x438931[_0x75356a(0x231)](_0x75356a(0x12d)+_0x89fdf(_0x11b2f7[_0x75356a(0x239)],_0x5b4d99(_0x1e9073)));_0x1d4312(_0x1e9073)[_0x75356a(0x1b0)]&&_0x438931['push'](_0x75356a(0x12d)+_0x89fdf(_0x11b2f7['gray'],'tags:\x20'+_0x1d4312(_0x1e9073)[_0x75356a(0x161)](',\x20')));_0x1e9073['operation']?.['safety']?.['access']&&_0x438931[_0x75356a(0x231)](_0x75356a(0x12d)+_0x89fdf(_0x11b2f7[_0x75356a(0x2d2)],'access:\x20'+_0x1e9073[_0x75356a(0x1f5)][_0x75356a(0x2c7)]['access']));_0x1e9073[_0x75356a(0x1f5)]?.[_0x75356a(0x232)]?.[_0x75356a(0x2dd)]&&_0x1e9073[_0x75356a(0x1f5)][_0x75356a(0x232)][_0x75356a(0x2dd)]!=='standard'&&_0x438931[_0x75356a(0x231)](_0x75356a(0x12d)+_0x89fdf(_0x11b2f7[_0x75356a(0x2d2)],_0x75356a(0x15f)+_0x1e9073[_0x75356a(0x1f5)][_0x75356a(0x232)][_0x75356a(0x2dd)]));if(_0x1e9073[_0x75356a(0x1f5)]?.['inputSchema']){const _0x393c58=Object[_0x75356a(0x116)](_0x1e9073[_0x75356a(0x1f5)][_0x75356a(0x1bd)]['properties']||{});if(_0x393c58['length'])_0x438931[_0x75356a(0x231)](_0x75356a(0x12d)+_0x89fdf(_0x11b2f7[_0x75356a(0x2d2)],_0x75356a(0xa3)+_0x393c58['join'](',\x20')));}return _0x1e9073[_0x75356a(0x259)]?.['body']&&_0x438931[_0x75356a(0x231)](_0x75356a(0x12d)+_0x89fdf(_0x11b2f7['gray'],_0x75356a(0xbd)+JSON['stringify'](_0x1e9073[_0x75356a(0x259)][_0x75356a(0x326)]))),_0x438931;}async function _0x383b4c(_0x56ba09,_0x11b283,_0x54784a,_0x2e3a2c=null){const _0x58d010=_0x42fa8f,_0x3a4ed1=_0x54784a[_0x58d010(0xea)]('?'),_0x2fde4a=_0x3a4ed1>=0x0?_0x54784a[_0x58d010(0x341)](0x0,_0x3a4ed1):_0x54784a,_0x2d40ff=_0x3a4ed1>=0x0?_0x54784a['slice'](_0x3a4ed1+0x1):'',_0x5e4a3d=Object['fromEntries'](new URLSearchParams(_0x2d40ff)[_0x58d010(0x27c)]());return _0x56ba09[_0x58d010(0x232)][_0x58d010(0x23d)](_0x11b283,_0x2fde4a,{'body':_0x2e3a2c,'query':_0x5e4a3d,'headers':{'content-type':_0x58d010(0x32d)}},{'internal':!![]});}function _0x2ca322(_0x3fc29b){const _0x795468=_0x42fa8f;if(!_0x3fc29b)return null;const _0x34d15f=_0x3fc29b[_0x795468(0x15e)]();if(!_0x34d15f)return null;try{return JSON[_0x795468(0x179)](_0x34d15f);}catch{}try{return JSON[_0x795468(0x179)](_0x460b19(_0x34d15f));}catch(_0x232d69){throw new SyntaxError(_0x232d69['message'],{'cause':_0x232d69});}}function _0x460b19(_0x3e5681){const _0x41f141=_0x42fa8f;let _0x292d49='',_0xfde5bf=0x0;while(_0xfde5bf<_0x3e5681['length']){const _0xee358a=_0x3e5681[_0xfde5bf];if(_0xee358a==='\x22'){_0x292d49+='\x22',_0xfde5bf++;while(_0xfde5bf<_0x3e5681[_0x41f141(0x1b0)]&&_0x3e5681[_0xfde5bf]!=='\x22'){if(_0x3e5681[_0xfde5bf]==='\x5c'){_0x292d49+=_0x3e5681[_0xfde5bf++];if(_0xfde5bf<_0x3e5681['length'])_0x292d49+=_0x3e5681[_0xfde5bf++];}else _0x292d49+=_0x3e5681[_0xfde5bf++];}_0x292d49+='\x22';if(_0xfde5bf<_0x3e5681[_0x41f141(0x1b0)])_0xfde5bf++;continue;}if(_0xee358a==='\x27'){_0x292d49+='\x22',_0xfde5bf++;while(_0xfde5bf<_0x3e5681[_0x41f141(0x1b0)]&&_0x3e5681[_0xfde5bf]!=='\x27'){if(_0x3e5681[_0xfde5bf]==='\x5c'&&_0x3e5681[_0xfde5bf+0x1]==='\x27')_0x292d49+='\x27',_0xfde5bf+=0x2;else _0x3e5681[_0xfde5bf]==='\x22'?(_0x292d49+='\x5c\x22',_0xfde5bf++):_0x292d49+=_0x3e5681[_0xfde5bf++];}_0x292d49+='\x22';if(_0xfde5bf<_0x3e5681['length'])_0xfde5bf++;continue;}if(_0x41f141(0x13a)[_0x41f141(0x366)](_0xee358a)){_0x292d49+=_0xee358a,_0xfde5bf++;continue;}let _0x1aeebb='';while(_0xfde5bf<_0x3e5681[_0x41f141(0x1b0)]&&!_0x41f141(0x107)['includes'](_0x3e5681[_0xfde5bf])&&_0x3e5681[_0xfde5bf]!=='\x20'&&_0x3e5681[_0xfde5bf]!=='\x09'&&_0x3e5681[_0xfde5bf]!=='\x0a'&&_0x3e5681[_0xfde5bf]!=='\x0d'){_0x1aeebb+=_0x3e5681[_0xfde5bf++];}let _0x3adea4=_0xfde5bf;while(_0x3adea4<_0x3e5681[_0x41f141(0x1b0)]&&(_0x3e5681[_0x3adea4]==='\x20'||_0x3e5681[_0x3adea4]==='\x09'))_0x3adea4++;if(_0x3e5681[_0x3adea4]===':')_0x292d49+='\x22'+_0x1aeebb+'\x22';else _0x1aeebb===_0x41f141(0x226)||_0x1aeebb===_0x41f141(0x201)||_0x1aeebb===_0x41f141(0x229)||/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/[_0x41f141(0x2f5)](_0x1aeebb)?_0x292d49+=_0x1aeebb:_0x292d49+='\x22'+_0x1aeebb+'\x22';}return _0x292d49[_0x41f141(0x156)](/,(\s*[}\]])/g,'$1');}function _0x3c020f(_0x1a516c){const _0x3fd64a=_0x42fa8f,_0x593b3f=[];let _0xfcd69d=0x0;while(_0xfcd69d<_0x1a516c[_0x3fd64a(0x1b0)]){while(_0xfcd69d<_0x1a516c[_0x3fd64a(0x1b0)]&&(_0x1a516c[_0xfcd69d]==='\x20'||_0x1a516c[_0xfcd69d]==='\x09'))_0xfcd69d++;if(_0xfcd69d>=_0x1a516c[_0x3fd64a(0x1b0)])break;const _0x5162df=_0x1a516c[_0xfcd69d];if(_0x5162df==='{'||_0x5162df==='['){const _0x23fc26=_0x5162df==='{'?'}':']',_0x396a81=_0xfcd69d++;let _0x3af341=0x1,_0x454852=![],_0x1f779d='';while(_0xfcd69d<_0x1a516c[_0x3fd64a(0x1b0)]&&_0x3af341>0x0){const _0x51036d=_0x1a516c[_0xfcd69d];if(_0x454852){if(_0x51036d==='\x5c')_0xfcd69d++;else{if(_0x51036d===_0x1f779d)_0x454852=![];}}else{if(_0x51036d==='\x22'||_0x51036d==='\x27')_0x454852=!![],_0x1f779d=_0x51036d;else{if(_0x51036d===_0x5162df)_0x3af341++;else{if(_0x51036d===_0x23fc26)_0x3af341--;}}}_0xfcd69d++;}_0x593b3f[_0x3fd64a(0x231)](_0x1a516c[_0x3fd64a(0x341)](_0x396a81,_0xfcd69d));continue;}if(_0x5162df==='\x22'||_0x5162df==='\x27'){const _0xd85401=_0x5162df;_0xfcd69d++;let _0x82d7e1='';while(_0xfcd69d<_0x1a516c[_0x3fd64a(0x1b0)]&&_0x1a516c[_0xfcd69d]!==_0xd85401){if(_0x1a516c[_0xfcd69d]==='\x5c'&&_0xfcd69d+0x1<_0x1a516c['length'])_0xfcd69d++,_0x82d7e1+=_0x1a516c[_0xfcd69d++];else _0x82d7e1+=_0x1a516c[_0xfcd69d++];}if(_0xfcd69d<_0x1a516c[_0x3fd64a(0x1b0)])_0xfcd69d++;_0x593b3f['push'](_0x82d7e1);continue;}let _0x1c257d='';while(_0xfcd69d<_0x1a516c['length']&&_0x1a516c[_0xfcd69d]!=='\x20'&&_0x1a516c[_0xfcd69d]!=='\x09'&&_0x1a516c[_0xfcd69d]!=='{'&&_0x1a516c[_0xfcd69d]!=='['){_0x1c257d+=_0x1a516c[_0xfcd69d++];}if(_0x1c257d)_0x593b3f['push'](_0x1c257d);}return _0x593b3f;}function _0x575b07(_0x1d1216,_0x294101){const _0xdadd60=_0x42fa8f,_0x432477=[..._0x1d1216[_0xdadd60(0xf9)][_0xdadd60(0x116)]()][_0xdadd60(0x234)](_0xc13a11=>!_0xc13a11[_0xdadd60(0x1ef)]('~'));console['log'](['',_0x89fdf(_0x11b2f7[_0xdadd60(0x1a2)]+_0x11b2f7[_0xdadd60(0x2a8)],_0xdadd60(0x188)),_0x89fdf(_0x11b2f7[_0xdadd60(0x1a2)]+_0x11b2f7[_0xdadd60(0x2a8)],_0xdadd60(0x325))+_0x89fdf(_0x11b2f7[_0xdadd60(0x1a2)],_0xdadd60(0x1cf))+_0x89fdf(_0x11b2f7[_0xdadd60(0x1a2)]+_0x11b2f7[_0xdadd60(0x2a8)],'║'),_0x89fdf(_0x11b2f7[_0xdadd60(0x1a2)]+_0x11b2f7[_0xdadd60(0x2a8)],_0xdadd60(0x38c)),'','\x20\x20'+_0x89fdf(_0x11b2f7[_0xdadd60(0xc6)],'✓')+'\x20'+_0x89fdf(_0x11b2f7[_0xdadd60(0x1a2)],_0xdadd60(0xd7))+'\x20\x20http://localhost:'+_0x294101[_0xdadd60(0x1e9)],'\x20\x20'+_0x89fdf(_0x11b2f7[_0xdadd60(0xc6)],'✓')+'\x20'+_0x89fdf(_0x11b2f7['bold'],_0xdadd60(0xdc))+'\x20\x20\x20\x20\x20http://localhost:'+_0x294101[_0xdadd60(0x1e9)]+'/api','\x20\x20'+_0x89fdf(_0x11b2f7[_0xdadd60(0xc6)],'✓')+'\x20'+_0x89fdf(_0x11b2f7[_0xdadd60(0x1a2)],_0xdadd60(0x348))+_0xdadd60(0x125)+_0x294101[_0xdadd60(0x36d)],'\x20\x20'+_0x89fdf(_0x11b2f7[_0xdadd60(0xc6)],'✓')+'\x20'+_0x89fdf(_0x11b2f7['bold'],'id')+_0xdadd60(0x38f)+_0x89fdf(_0x11b2f7[_0xdadd60(0x2d2)],_0x1d1216['id']),'\x20\x20'+_0x89fdf(_0x11b2f7[_0xdadd60(0xc6)],'✓')+'\x20'+_0x89fdf(_0x11b2f7[_0xdadd60(0x1a2)],_0xdadd60(0x355))+_0xdadd60(0x125)+_0x432477[_0xdadd60(0x282)](_0x29ab05=>_0x89fdf(_0x11b2f7[_0xdadd60(0x2a8)],_0x29ab05))['join']('\x20\x20'),..._0x294101['noAdmin']?[]:['\x20\x20'+_0x89fdf(_0x11b2f7[_0xdadd60(0xc6)],'✓')+'\x20'+_0x89fdf(_0x11b2f7[_0xdadd60(0x1a2)],'admin')+_0xdadd60(0x33d)+_0x294101['port']+_0xdadd60(0x2fc)],'',_0x89fdf(_0x11b2f7['dim'],'\x20\x20Type\x20'+_0x89fdf(_0x11b2f7[_0xdadd60(0x1a2)],_0xdadd60(0x303))+_0xdadd60(0x203)+_0x89fdf(_0x11b2f7[_0xdadd60(0x1a2)],_0xdadd60(0x21d))+_0xdadd60(0x182)+_0x89fdf(_0x11b2f7[_0xdadd60(0x1a2)],'exit')+_0xdadd60(0x12b)),'']['join']('\x0a'));}function _0x28cfb6(_0x34330c){const _0xe0ff00=_0x42fa8f;console[_0xe0ff00(0xdd)]('\x0a'+_0x89fdf(_0x11b2f7[_0xe0ff00(0x1a2)],_0xe0ff00(0xfe))+'\x20\x20'+_0x89fdf(_0x11b2f7[_0xe0ff00(0x239)],_0xe0ff00(0x27f))+_0xe0ff00(0x11f)+_0x89fdf(_0x11b2f7[_0xe0ff00(0x2a8)],_0xe0ff00(0xe0))+_0xe0ff00(0x12c)+_0x89fdf(_0x11b2f7['cyan'],_0xe0ff00(0xe0))+'\x20'+_0x89fdf(_0x11b2f7[_0xe0ff00(0x177)],'<json-body>')+_0xe0ff00(0xa5)+_0x89fdf(_0x11b2f7[_0xe0ff00(0x2a8)],_0xe0ff00(0x23a))+'\x20'+_0x89fdf(_0x11b2f7[_0xe0ff00(0x2a8)],_0xe0ff00(0xe0))+'\x20'+_0x89fdf(_0x11b2f7[_0xe0ff00(0x177)],_0xe0ff00(0x372))+_0xe0ff00(0x123)+_0x89fdf(_0x11b2f7['dim'],_0xe0ff00(0x16f))+_0xe0ff00(0x320)+_0x89fdf(_0x11b2f7['gray'],_0xe0ff00(0x1f8))+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/info\x0a\x20\x20\x20\x20'+_0x89fdf(_0x11b2f7['gray'],_0xe0ff00(0x355))+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/envs\x0a\x20\x20\x20\x20'+_0x89fdf(_0x11b2f7['gray'],'types')+'\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/env/'+_0x34330c['env']+_0xe0ff00(0xee)+_0x89fdf(_0x11b2f7['gray'],_0xe0ff00(0x333))+_0xe0ff00(0xf0)+_0x34330c[_0xe0ff00(0x2fd)]+_0xe0ff00(0x330)+_0x89fdf(_0x11b2f7[_0xe0ff00(0x2d2)],_0xe0ff00(0x98))+_0xe0ff00(0x142)+_0x34330c[_0xe0ff00(0x2fd)]+_0xe0ff00(0x2f1)+_0x89fdf(_0x11b2f7[_0xe0ff00(0x2d2)],_0xe0ff00(0x2d8))+_0xe0ff00(0x318)+_0x34330c[_0xe0ff00(0x2fd)]+_0xe0ff00(0x1b3)+_0x89fdf(_0x11b2f7[_0xe0ff00(0x2d2)],_0xe0ff00(0x260))+_0xe0ff00(0x320)+_0x89fdf(_0x11b2f7[_0xe0ff00(0x2d2)],_0xe0ff00(0x17c))+_0xe0ff00(0x320)+_0x89fdf(_0x11b2f7['gray'],'env/staging/info')+_0xe0ff00(0xbf)+_0x89fdf(_0x11b2f7[_0xe0ff00(0x1a2)],'\x20\x20Flags')+'\x20\x20'+_0x89fdf(_0x11b2f7['dim'],'(on\x20any\x20path\x20command)')+_0xe0ff00(0x11f)+_0x89fdf(_0x11b2f7[_0xe0ff00(0x2a8)],_0xe0ff00(0x2ad))+_0xe0ff00(0x312)+_0x89fdf(_0x11b2f7[_0xe0ff00(0x2a8)],_0xe0ff00(0x38b))+_0xe0ff00(0x26a)+_0x89fdf(_0x11b2f7[_0xe0ff00(0x239)],_0xe0ff00(0x16f))+_0xe0ff00(0x320)+_0x89fdf(_0x11b2f7['gray'],_0xe0ff00(0x389))+_0xe0ff00(0x320)+_0x89fdf(_0x11b2f7[_0xe0ff00(0x2d2)],_0xe0ff00(0x10d))+_0xe0ff00(0x320)+_0x89fdf(_0x11b2f7[_0xe0ff00(0x2d2)],_0xe0ff00(0x20a))+'\x0a\x0a'+_0x89fdf(_0x11b2f7['bold'],'\x20\x20Shell\x20commands')+'\x0a\x0a\x20\x20'+_0x89fdf(_0x11b2f7[_0xe0ff00(0x2a8)],_0xe0ff00(0x2e6))+_0xe0ff00(0x1ca)+_0x89fdf(_0x11b2f7[_0xe0ff00(0x2a8)],_0xe0ff00(0x2fd))+_0xe0ff00(0x38d)+_0x89fdf(_0x11b2f7[_0xe0ff00(0x2a8)],'routes')+'\x20'+_0x89fdf(_0x11b2f7[_0xe0ff00(0x239)],_0xe0ff00(0x1ae))+_0xe0ff00(0x256)+_0x89fdf(_0x11b2f7['cyan'],_0xe0ff00(0x91))+'\x20'+_0x89fdf(_0x11b2f7['dim'],_0xe0ff00(0x25e))+_0xe0ff00(0x36b)+_0x89fdf(_0x11b2f7[_0xe0ff00(0x2a8)],_0xe0ff00(0x2f9))+_0xe0ff00(0x84)+_0x89fdf(_0x11b2f7[_0xe0ff00(0x2a8)],_0xe0ff00(0x303))+_0xe0ff00(0x29e)+_0x89fdf(_0x11b2f7[_0xe0ff00(0x2a8)],_0xe0ff00(0x15d))+'\x20'+_0x89fdf(_0x11b2f7[_0xe0ff00(0x239)],_0xe0ff00(0x236))+_0xe0ff00(0x2cd));}async function _0x2ce730(_0x4630d4,_0x5be2b4=0x0){const _0x5b6c52=_0x42fa8f;process['stdout']['write']('\x0a'),console[_0x5b6c52(0xdd)](_0x89fdf(_0x11b2f7[_0x5b6c52(0x177)],_0x5b6c52(0x2cc)));try{await _0x4630d4[_0x5b6c52(0x2a5)]();}catch(_0x3d2309){console[_0x5b6c52(0x266)](_0x89fdf(_0x11b2f7['red'],'\x20\x20'+_0x3d2309[_0x5b6c52(0x307)]));}process[_0x5b6c52(0x15d)](_0x5be2b4);}function _0x55df33(_0x14fa3f){const _0x1b97a5=_0x42fa8f,_0x2fac78=_0x14fa3f[_0x1b97a5(0x2fd)]!=='default'?_0x89fdf(_0x11b2f7['yellow'],'['+_0x14fa3f['env']+']'):'';return _0x89fdf(_0x11b2f7['bold']+_0x11b2f7['cyan'],_0x1b97a5(0x28a))+_0x2fac78+_0x89fdf(_0x11b2f7[_0x1b97a5(0x2d2)],'>\x20');}const _0x20373a=new Set([_0x42fa8f(0x23f),_0x42fa8f(0x2d7),'PUT','PATCH',_0x42fa8f(0x197)]);async function _0x561de8(_0x44976a,_0x356b54,_0x86a75a,_0x34622f,_0x31a5d6,_0x21b0cf){const _0x53e7b0=_0x42fa8f;_0x44976a=_0x44976a[_0x53e7b0(0x15e)]();if(!_0x44976a||_0x44976a[_0x53e7b0(0x1ef)]('#'))return;const _0x1fb9f4=_0x3c020f(_0x44976a),{flags:_0x20c8b5,rest:_0x447605}=_0x1b4e59(_0x1fb9f4);if(!_0x447605[_0x53e7b0(0x1b0)])return;const _0xb8dec1=_0x447605[0x0],_0x5971fd=_0xb8dec1['toUpperCase']();if(_0x5971fd==='HELP'){if(_0x447605[0x1])_0x4ef7a5(_0x356b54,_0x16edf5(_0x447605[0x1],_0x20c8b5[_0x53e7b0(0x2fd)]??_0x31a5d6[_0x53e7b0(0x2fd)]));else _0x28cfb6(_0x31a5d6);return;}if(_0x5971fd===_0x53e7b0(0x2b6)){const _0x224301=_0x447605[0x1];if(!_0x224301){console['log'](_0x89fdf(_0x11b2f7[_0x53e7b0(0x27b)],_0x53e7b0(0x37b)));return;}try{_0x356b54[_0x53e7b0(0x2fd)](_0x224301),_0x31a5d6[_0x53e7b0(0x2fd)]=_0x224301,_0x21b0cf?.[_0x53e7b0(0x364)](_0x55df33(_0x31a5d6)),console[_0x53e7b0(0xdd)](_0x53e7b0(0x1b9)+_0x89fdf(_0x11b2f7['green'],'✓')+_0x53e7b0(0x29b)+_0x89fdf(_0x11b2f7['bold']+_0x11b2f7[_0x53e7b0(0x2a8)],_0x224301)+'\x0a');}catch{console[_0x53e7b0(0xdd)]('\x0a\x20\x20'+_0x89fdf(_0x11b2f7[_0x53e7b0(0x27b)],'✗')+_0x53e7b0(0x8b)+_0x89fdf(_0x11b2f7[_0x53e7b0(0x1a2)],_0x224301)+_0x53e7b0(0x26b)+_0x89fdf(_0x11b2f7[_0x53e7b0(0x239)],_0x53e7b0(0x21b)));}return;}if(_0x5971fd===_0x53e7b0(0x21a)){const _0x1fd495=[..._0x356b54[_0x53e7b0(0xf9)]['keys']()][_0x53e7b0(0x234)](_0x305329=>!_0x305329[_0x53e7b0(0x1ef)]('~'));console[_0x53e7b0(0xdd)]('');for(const _0x25111e of _0x1fd495){const _0x4d59d4=_0x25111e===_0x31a5d6[_0x53e7b0(0x2fd)];console['log']('\x20\x20'+(_0x4d59d4?_0x89fdf(_0x11b2f7['green'],'●'):_0x89fdf(_0x11b2f7[_0x53e7b0(0x239)],'○'))+'\x20\x20'+(_0x4d59d4?_0x89fdf(_0x11b2f7['bold']+_0x11b2f7[_0x53e7b0(0x2a8)],_0x25111e):_0x89fdf(_0x11b2f7[_0x53e7b0(0x239)],_0x25111e)));}console[_0x53e7b0(0xdd)]('\x0a\x20\x20'+_0x89fdf(_0x11b2f7['dim'],_0x53e7b0(0x22c))+'\x20'+_0x89fdf(_0x11b2f7[_0x53e7b0(0x2a8)],_0x31a5d6[_0x53e7b0(0x2fd)])),console[_0x53e7b0(0xdd)]('');return;}if(_0x5971fd===_0x53e7b0(0xdf)){const _0x10692d=[..._0x356b54['_envs']['values']()][_0x53e7b0(0x234)](_0x1fef31=>!_0x1fef31[_0x53e7b0(0x167)]['startsWith']('~'));console[_0x53e7b0(0xdd)]('');const _0x56924d=Math[_0x53e7b0(0x261)](..._0x10692d[_0x53e7b0(0x282)](_0x384a24=>_0x384a24[_0x53e7b0(0x167)]['length']));for(const _0x3fb735 of _0x10692d){const _0x280905=_0x3fb735[_0x53e7b0(0x167)]===_0x31a5d6[_0x53e7b0(0x2fd)],_0x2d4dc3=_0x280905?_0x89fdf(_0x11b2f7[_0x53e7b0(0xc6)],'●'):_0x89fdf(_0x11b2f7[_0x53e7b0(0x239)],'○'),_0x100d95=_0x280905?_0x89fdf(_0x11b2f7[_0x53e7b0(0x1a2)]+_0x11b2f7[_0x53e7b0(0x2a8)],_0x3fb735[_0x53e7b0(0x167)][_0x53e7b0(0x20b)](_0x56924d)):_0x89fdf(_0x11b2f7[_0x53e7b0(0x239)],_0x3fb735[_0x53e7b0(0x167)][_0x53e7b0(0x20b)](_0x56924d)),_0x5338a3=[..._0x3fb735[_0x53e7b0(0x129)][_0x53e7b0(0x116)]()][_0x53e7b0(0x234)](_0x2c3919=>!_0x2c3919['startsWith']('~')),_0x98369f=_0x5338a3['length']?_0x89fdf(_0x11b2f7['dim'],_0x5338a3[_0x53e7b0(0x341)](0x0,0x5)['join'](',\x20')+(_0x5338a3[_0x53e7b0(0x1b0)]>0x5?_0x53e7b0(0x134)+(_0x5338a3[_0x53e7b0(0x1b0)]-0x5)+_0x53e7b0(0x22e):'')):_0x89fdf(_0x11b2f7['dim'],_0x53e7b0(0x278));console[_0x53e7b0(0xdd)]('\x20\x20'+_0x2d4dc3+'\x20\x20'+_0x100d95+'\x20\x20'+_0x98369f);}console[_0x53e7b0(0xdd)]('');return;}if(_0x5971fd===_0x53e7b0(0x183)){const _0x4761ab=_0x20c8b5[_0x53e7b0(0x2fd)]??_0x447605[0x1]??_0x31a5d6[_0x53e7b0(0x2fd)];try{const _0x3818e8=_0x356b54['env'](_0x4761ab),_0x169190=[..._0x3818e8['typeSubDbs'][_0x53e7b0(0x116)]()][_0x53e7b0(0x234)](_0x45903b=>!_0x45903b[_0x53e7b0(0x1ef)]('~'))[_0x53e7b0(0x22d)]();console['log'](_0x53e7b0(0x1b9)+_0x89fdf(_0x11b2f7[_0x53e7b0(0x239)],_0x169190[_0x53e7b0(0x1b0)]+_0x53e7b0(0x1d8)+(_0x169190[_0x53e7b0(0x1b0)]!==0x1?'s':'')+'\x20in\x20'+_0x4761ab));for(const _0x312929 of _0x169190){const _0x17af54=_0x3818e8['typeSubDbs'][_0x53e7b0(0x187)](_0x312929),_0x5033b8=_0x17af54?.[_0x53e7b0(0x8e)]?.[_0x53e7b0(0x1f1)]?.()??0x0,_0x23ca8e=_0x89fdf(_0x11b2f7['bold']+_0x11b2f7[_0x53e7b0(0x2a8)],_0x312929[_0x53e7b0(0x20b)](0x1c));console[_0x53e7b0(0xdd)](_0x53e7b0(0x125)+_0x23ca8e+'\x20\x20'+_0x89fdf(_0x11b2f7[_0x53e7b0(0x257)],String(_0x5033b8)[_0x53e7b0(0x385)](0x6))+'\x20'+_0x89fdf(_0x11b2f7['dim'],'records'));}console[_0x53e7b0(0xdd)]('');}catch(_0x4d52b4){console[_0x53e7b0(0x266)](_0x89fdf(_0x11b2f7[_0x53e7b0(0x27b)],'\x0a\x20\x20'+_0x4d52b4['message']+'\x0a'));}return;}if(_0x5971fd===_0x53e7b0(0x9e)){_0x5226e8(_0x356b54,_0x447605['slice'](0x1)[_0x53e7b0(0x161)]('\x20'));return;}if(_0x5971fd==='LOGS'){const _0x129540=(_0x447605[0x1]??'')[_0x53e7b0(0x108)]();if(!_0x129540||_0x129540==='on')_0x34622f[_0x53e7b0(0x1b8)]=!![],_0x34622f[_0x53e7b0(0x8a)]='info',console[_0x53e7b0(0xdd)](_0x53e7b0(0x1b9)+_0x89fdf(_0x11b2f7[_0x53e7b0(0xc6)],'✓')+_0x53e7b0(0x14c)+_0x89fdf(_0x11b2f7[_0x53e7b0(0x239)],'level:\x20info')+'\x0a');else{if(_0x129540===_0x53e7b0(0x270))_0x34622f[_0x53e7b0(0x1b8)]=![],console['log'](_0x53e7b0(0x1b9)+_0x89fdf(_0x11b2f7['yellow'],'○')+'\x20logs\x20off\x0a');else _0x1b2c94[_0x129540]!==undefined?(_0x34622f[_0x53e7b0(0x1b8)]=!![],_0x34622f[_0x53e7b0(0x8a)]=_0x129540,console['log']('\x0a\x20\x20'+_0x89fdf(_0x11b2f7[_0x53e7b0(0xc6)],'✓')+'\x20log\x20level:\x20'+_0x89fdf(_0x11b2f7[_0x53e7b0(0x1a2)],_0x129540)+'\x0a')):console[_0x53e7b0(0x266)](_0x89fdf(_0x11b2f7[_0x53e7b0(0x27b)],_0x53e7b0(0x12f)));}return;}if(_0x5971fd===_0x53e7b0(0x29a)||_0x5971fd===_0x53e7b0(0xab)){await _0x2ce730(_0x356b54,0x0);return;}if(_0x5971fd===_0x53e7b0(0x1ab)){const _0xaa705e='http://localhost:'+_0x86a75a[_0x53e7b0(0x1e9)]+'/admin/index.html',_0x312814=process[_0x53e7b0(0x16a)]===_0x53e7b0(0x384)?_0x53e7b0(0x168)+_0xaa705e:process[_0x53e7b0(0x16a)]===_0x53e7b0(0x2ce)?_0x53e7b0(0x332)+_0xaa705e:_0x53e7b0(0x148)+_0xaa705e;require$$4[_0x53e7b0(0x124)](_0x312814),console['log']('\x0a\x20\x20'+_0x89fdf(_0x11b2f7['green'],'✓')+'\x20opening\x20'+_0x89fdf(_0x11b2f7[_0x53e7b0(0x2a8)],_0xaa705e)+'\x0a');return;}let _0x5e196c,_0x25b808,_0x79977c;if(_0x20373a[_0x53e7b0(0x158)](_0x5971fd)){_0x5e196c=_0x5971fd,_0x25b808=_0x447605[0x1],_0x79977c=_0x447605['slice'](0x2);if(!_0x25b808){console[_0x53e7b0(0x266)](_0x89fdf(_0x11b2f7['red'],_0x53e7b0(0x340)+_0xb8dec1+'\x20<path>\x20[json-body]'));return;}}else _0x5e196c=null,_0x25b808=_0x447605[0x0],_0x79977c=_0x447605[_0x53e7b0(0x341)](0x1);const _0x2b9a21=_0x20c8b5[_0x53e7b0(0x2fd)]??_0x31a5d6[_0x53e7b0(0x2fd)],_0xff506c=_0x16edf5(_0x25b808,_0x2b9a21);if(_0x20c8b5[_0x53e7b0(0x303)]){_0x4ef7a5(_0x356b54,_0xff506c);return;}let _0x248055=null;if(_0x79977c[_0x53e7b0(0x1b0)]){const _0x4373ef=_0x79977c[_0x53e7b0(0x161)]('\x20');try{_0x248055=_0x2ca322(_0x4373ef);}catch(_0x3da39d){console[_0x53e7b0(0x266)](_0x89fdf(_0x11b2f7[_0x53e7b0(0x27b)],_0x53e7b0(0x90)+_0x4373ef+_0x53e7b0(0x1b9)+_0x89fdf(_0x11b2f7['dim'],_0x3da39d['message'])+'\x0a'));return;}}if(!_0x5e196c)_0x5e196c=_0x248055!==null?_0x53e7b0(0x2d7):_0x53e7b0(0x23f);try{const _0x32043a=await _0x383b4c(_0x356b54,_0x5e196c,_0xff506c,_0x248055);_0x5a56a0(_0x32043a['status'],_0x32043a[_0x53e7b0(0x326)]);}catch(_0x2124ed){console[_0x53e7b0(0x266)](_0x53e7b0(0x1b9)+_0x89fdf(_0x11b2f7['red'],'✗')+'\x20'+_0x2124ed[_0x53e7b0(0x307)]+'\x0a');}}class _0x146d3c{constructor(){const _0x253082=_0x42fa8f;this[_0x253082(0x2ba)]=new Map(),this[_0x253082(0x28f)]=null,this[_0x253082(0x1e0)]=![];}}function _0x5523ad(_0x405782){const _0x4b12e8=_0x42fa8f,_0x32d21b=new _0x146d3c();for(const _0x14c1e4 of _0x405782){if(_0x14c1e4[_0x4b12e8(0x259)]?.[_0x4b12e8(0x354)])continue;const _0xa6ede3=_0x14c1e4[_0x4b12e8(0x348)][_0x4b12e8(0x156)](/^\/api/,'')['replace'](/^\[\/env\/:env=[^\]]*\]/,'')['replace'](/^\//,'');if(!_0xa6ede3)continue;let _0x3db3a4=_0x32d21b;for(const _0x151590 of _0xa6ede3[_0x4b12e8(0xb7)]('/')['filter'](Boolean)){if(_0x151590[_0x4b12e8(0x1ef)](':')){const _0x3f0b6f=_0x151590[_0x4b12e8(0x341)](0x1);if(!_0x3db3a4[_0x4b12e8(0x28f)])_0x3db3a4[_0x4b12e8(0x28f)]={'param':_0x3f0b6f,'node':new _0x146d3c()};_0x3db3a4=_0x3db3a4[_0x4b12e8(0x28f)][_0x4b12e8(0x147)];}else{if(!_0x3db3a4[_0x4b12e8(0x2ba)][_0x4b12e8(0x158)](_0x151590))_0x3db3a4[_0x4b12e8(0x2ba)][_0x4b12e8(0x135)](_0x151590,new _0x146d3c());_0x3db3a4=_0x3db3a4[_0x4b12e8(0x2ba)][_0x4b12e8(0x187)](_0x151590);}}_0x3db3a4[_0x4b12e8(0x1e0)]=!![];}return _0x32d21b;}const _0x1beb63=new Map();function _0x5b7cb1(_0x173255,_0x2dc120,_0xffbbf2){const _0x11e714=_0x42fa8f,_0x435ed6=_0x1beb63[_0x11e714(0x187)](_0x173255);if(_0x435ed6&&_0x435ed6[_0x11e714(0xcc)]>Date[_0x11e714(0x149)]())return _0x435ed6[_0x11e714(0x137)];const _0x1af8ba=_0xffbbf2();return _0x1beb63[_0x11e714(0x135)](_0x173255,{'val':_0x1af8ba,'exp':Date[_0x11e714(0x149)]()+_0x2dc120}),_0x1af8ba;}function _0x2dc97f(_0x55b04d,_0x31c46d,_0x34254a,_0x21ec1a){const _0x1bd4cd=_0x42fa8f,_0x27c8b0=_0x31c46d[_0x1bd4cd(0x2fd)]??_0x21ec1a['env'];switch(_0x55b04d){case _0x1bd4cd(0x2fd):return[..._0x34254a[_0x1bd4cd(0xf9)][_0x1bd4cd(0x116)]()][_0x1bd4cd(0x234)](_0x14c731=>!_0x14c731[_0x1bd4cd(0x1ef)]('~'));case _0x1bd4cd(0x358):return _0x5b7cb1(_0x1bd4cd(0x175)+_0x27c8b0,0x7d0,()=>{const _0x4d7b94=_0x1bd4cd;try{return[..._0x34254a[_0x4d7b94(0x2fd)](_0x27c8b0)[_0x4d7b94(0x129)][_0x4d7b94(0x116)]()][_0x4d7b94(0x234)](_0x129552=>!_0x129552[_0x4d7b94(0x1ef)]('~'));}catch{return[];}});case'key':if(!_0x31c46d[_0x1bd4cd(0x358)])return[];return _0x5b7cb1(_0x1bd4cd(0x275)+_0x27c8b0+':'+_0x31c46d[_0x1bd4cd(0x358)],0x5dc,()=>{const _0x586e3d=_0x1bd4cd;try{const _0x2d621d=_0x34254a['env'](_0x27c8b0)['typeSubDbs']['get'](_0x31c46d[_0x586e3d(0x358)]);if(!_0x2d621d?.[_0x586e3d(0x8e)])return[];const _0x45dd2c=[];for(const {key:_0x5d28e7}of _0x2d621d[_0x586e3d(0x8e)]['getRange']({'limit':0x32})){_0x45dd2c[_0x586e3d(0x231)](String(_0x5d28e7));if(_0x45dd2c[_0x586e3d(0x1b0)]>=0x32)break;}return _0x45dd2c;}catch{return[];}});case _0x1bd4cd(0x2ed):if(!_0x31c46d[_0x1bd4cd(0x358)])return[];return _0x5b7cb1(_0x1bd4cd(0x264)+_0x27c8b0+':'+_0x31c46d[_0x1bd4cd(0x358)],0x7d0,()=>{const _0x21f853=_0x1bd4cd;try{const _0xf40fc3=_0x34254a[_0x21f853(0x2fd)](_0x27c8b0)[_0x21f853(0x129)]['get'](_0x31c46d[_0x21f853(0x358)]);return _0xf40fc3?[..._0xf40fc3[_0x21f853(0xf2)]?.[_0x21f853(0x116)]()??[]]:[];}catch{return[];}});case'ftsName':if(!_0x31c46d['type'])return[];return _0x5b7cb1(_0x1bd4cd(0x371)+_0x27c8b0+':'+_0x31c46d[_0x1bd4cd(0x358)],0x7d0,()=>{const _0x469d11=_0x1bd4cd;try{return _0x34254a[_0x469d11(0x1b6)]?.[_0x469d11(0x1c9)]?.(_0x31c46d[_0x469d11(0x358)],_0x34254a[_0x469d11(0x2fd)](_0x27c8b0))?.[_0x469d11(0x282)](_0x59e0f1=>_0x59e0f1[_0x469d11(0x167)])??[];}catch{return[];}});default:return[];}}function _0x538abe(_0x17521f,_0x1ad3fb,_0x4255be,_0x5a0822){const _0x5503b2=_0x42fa8f,_0x16dba7=_0x17521f['endsWith']('/'),_0x1eda04=_0x17521f[_0x5503b2(0xb7)]('/'),_0x19e3b2=_0x16dba7?_0x1eda04['slice'](0x0,-0x1):_0x1eda04[_0x5503b2(0x341)](0x0,-0x1),_0x4120b3=_0x16dba7?'':_0x1eda04[_0x1eda04['length']-0x1];let _0x1e7c93=_0x1ad3fb;const _0x1f0f90={};for(const _0x4c683b of _0x19e3b2){if(!_0x4c683b)continue;if(_0x1e7c93['children'][_0x5503b2(0x158)](_0x4c683b))_0x1e7c93=_0x1e7c93[_0x5503b2(0x2ba)][_0x5503b2(0x187)](_0x4c683b);else{if(_0x1e7c93['dynamic'])_0x1f0f90[_0x1e7c93[_0x5503b2(0x28f)][_0x5503b2(0x258)]]=_0x4c683b,_0x1e7c93=_0x1e7c93[_0x5503b2(0x28f)]['node'];else return[];}}const _0x6f5c4a=_0x19e3b2[_0x5503b2(0x234)](Boolean),_0x465384=_0x6f5c4a[_0x5503b2(0x1b0)]?_0x6f5c4a[_0x5503b2(0x161)]('/')+'/':'',_0x4cfeb0=[];for(const [_0x4c6e3b]of _0x1e7c93[_0x5503b2(0x2ba)]){if(_0x4c6e3b['startsWith'](_0x4120b3))_0x4cfeb0[_0x5503b2(0x231)](_0x465384+_0x4c6e3b);}if(_0x1e7c93[_0x5503b2(0x28f)])for(const _0x731dd7 of _0x2dc97f(_0x1e7c93[_0x5503b2(0x28f)][_0x5503b2(0x258)],_0x1f0f90,_0x4255be,_0x5a0822)){if(String(_0x731dd7)[_0x5503b2(0x1ef)](_0x4120b3))_0x4cfeb0[_0x5503b2(0x231)](_0x465384+_0x731dd7);}return _0x4cfeb0[_0x5503b2(0x341)](0x0,0x64);}const _0x25b77b=[_0x42fa8f(0x303),'use',_0x42fa8f(0x2fd),_0x42fa8f(0x355),_0x42fa8f(0x30b),_0x42fa8f(0x21d),_0x42fa8f(0x91),_0x42fa8f(0x2f9),_0x42fa8f(0x15d),'quit'];function _0x2d53ed(_0x43468a,_0x4bb1eb,_0x5a24ad){return function _0x17decc(_0x3b20ef){const _0x55f5da=_0x1dd2;try{const _0x5dc740=_0x3b20ef[_0x55f5da(0x1c8)](/\s[{[]/),_0x1adb68=_0x5dc740>=0x0?_0x3b20ef[_0x55f5da(0x341)](0x0,_0x5dc740):_0x3b20ef,_0x52f951=_0x1adb68[_0x55f5da(0x2bf)]();if(!_0x52f951){const _0x560a98=[..._0x25b77b,...[..._0x43468a[_0x55f5da(0x2ba)][_0x55f5da(0x116)]()]][_0x55f5da(0x341)](0x0,0x64);return[_0x560a98,''];}const _0x4a243e=_0x52f951[_0x55f5da(0xb7)](/\s+/),_0x59f359=_0x4a243e[0x0],_0x120b88=_0x59f359[_0x55f5da(0x361)]();if(_0x4a243e[_0x55f5da(0x1b0)]===0x1){const _0x51a42b=_0x59f359[_0x55f5da(0x108)](),_0x2b35e7=_0x25b77b[_0x55f5da(0x234)](_0x3b56e8=>_0x3b56e8['startsWith'](_0x51a42b)),_0x129422=_0x538abe(_0x59f359,_0x43468a,_0x4bb1eb,_0x5a24ad),_0x194582=[...new Set([..._0x2b35e7,..._0x129422])]['slice'](0x0,0x64);return[_0x194582,_0x59f359];}if(_0x20373a[_0x55f5da(0x158)](_0x120b88)&&_0x4a243e[_0x55f5da(0x1b0)]===0x2){const _0x12ecdb=_0x4a243e[0x1],_0x485547=_0x538abe(_0x12ecdb,_0x43468a,_0x4bb1eb,_0x5a24ad);return[_0x485547[_0x55f5da(0x282)](_0x31725e=>_0x59f359+'\x20'+_0x31725e),_0x59f359+'\x20'+_0x12ecdb];}if(!_0x20373a[_0x55f5da(0x158)](_0x120b88)&&_0x4a243e[_0x55f5da(0x1b0)]>0x1){const _0xf4219c=_0x538abe(_0x59f359,_0x43468a,_0x4bb1eb,_0x5a24ad),_0x433a8d='\x20'+_0x4a243e[_0x55f5da(0x341)](0x1)[_0x55f5da(0x161)]('\x20');return[_0xf4219c[_0x55f5da(0x282)](_0x148335=>_0x148335+_0x433a8d),_0x59f359+_0x433a8d];}return[[],_0x3b20ef];}catch{return[[],_0x3b20ef];}};}async function _0x24ee55(_0x5cd3be,_0x527c95){const _0x38fa2a=_0x42fa8f,_0x5df37e={'enabled':!![],'level':_0x527c95[_0x38fa2a(0x100)]??_0x38fa2a(0x1f8)},_0x49b028={'env':_0x38fa2a(0x1f3)},_0x563188={'current':null},_0x4e185c=_0x5523ad(_0x5cd3be[_0x38fa2a(0x232)][_0x38fa2a(0x218)]()),_0x27459c=_0x2d53ed(_0x4e185c,_0x5cd3be,_0x49b028);_0x5cd3be[_0x38fa2a(0xdd)][_0x38fa2a(0x2d0)](_0x21e9a4=>{const _0x49e574=_0x38fa2a;if(!_0x5df37e[_0x49e574(0x1b8)])return;_0x263a36(_0x21e9a4,_0x5df37e['level']),_0x563188['current']?.[_0x49e574(0x251)](!![]);}),_0x575b07(_0x5cd3be,_0x527c95);const _0x6fd59e=_0x4caf77['createInterface']({'input':process[_0x38fa2a(0x274)],'output':process['stdout'],'terminal':!![],'completer':_0x27459c,'prompt':_0x55df33(_0x49b028),'historySize':_0x2504a4});try{const _0x1b7768=_0xe972e0[_0x38fa2a(0x146)](_0x26105a,'utf8')[_0x38fa2a(0xb7)]('\x0a')[_0x38fa2a(0x234)](Boolean);_0x6fd59e['history']=_0x1b7768[_0x38fa2a(0x230)]()[_0x38fa2a(0x341)](0x0,_0x2504a4);}catch{}return _0x563188[_0x38fa2a(0x2c3)]=_0x6fd59e,_0x6fd59e['on'](_0x38fa2a(0x316),async _0xfe36cd=>{const _0x217e43=_0x38fa2a;_0x6fd59e[_0x217e43(0x352)]();try{await _0x561de8(_0xfe36cd,_0x5cd3be,_0x527c95,_0x5df37e,_0x49b028,_0x6fd59e);}catch(_0x1a0577){console[_0x217e43(0x266)](_0x89fdf(_0x11b2f7[_0x217e43(0x27b)],'\x20\x20Error:\x20'+_0x1a0577['message']));}finally{_0x6fd59e['resume'](),_0x6fd59e[_0x217e43(0x251)]();}}),_0x6fd59e['on']('close',()=>{const _0xba68da=_0x38fa2a;try{const _0x1a2f98=[..._0x6fd59e[_0xba68da(0x37f)]][_0xba68da(0x230)]()[_0xba68da(0x234)](Boolean)[_0xba68da(0x341)](0x0,_0x2504a4);_0xe972e0[_0xba68da(0x359)](_0x26105a,_0x1a2f98[_0xba68da(0x161)]('\x0a')+'\x0a');}catch{}_0x2ce730(_0x5cd3be,0x0);}),process['on']('SIGINT',()=>{const _0x36aacc=_0x38fa2a;if(_0x6fd59e[_0x36aacc(0x316)]==='')_0x2ce730(_0x5cd3be,0x0);else process['stdout'][_0x36aacc(0xef)]('\x0a'),_0x6fd59e['clearLine'](0x0),_0x6fd59e['prompt']();}),process['on'](_0x38fa2a(0x1bc),()=>_0x2ce730(_0x5cd3be,0x0)),_0x6fd59e[_0x38fa2a(0x251)](),_0x6fd59e;}return okdbShell={'start':_0x24ee55,'colorLog':_0x263a36,'lenientParse':_0x2ca322,'_splitLine':_0x3c020f,'_formatRouteHelpLines':_0x3d612c,'_routeSummary':_0x4caf95,'_routeTags':_0x1d4312},okdbShell;}var hasRequiredOkdb;function requireOkdb(){const _0x178958=_0x152c38;if(hasRequiredOkdb)return okdb$1;hasRequiredOkdb=0x1;try{process[_0x178958(0xe5)]();}catch{}const _0x4e5a5b=require$$1$1,_0x31ec50=require$$1;function _0x15c3e1(_0x1938da){const _0x3d2b66=_0x178958,_0x4f8ac6=_0x1938da[_0x3d2b66(0x341)](0x2),_0x489dca={};let _0x36ded0=0x0;while(_0x36ded0<_0x4f8ac6[_0x3d2b66(0x1b0)]){const _0x1ee5a1=_0x4f8ac6[_0x36ded0];if(_0x1ee5a1===_0x3d2b66(0xb2)||_0x1ee5a1==='-p')_0x489dca['port']=Number(_0x4f8ac6[++_0x36ded0]);else{if(_0x1ee5a1===_0x3d2b66(0x390)||_0x1ee5a1==='-d')_0x489dca[_0x3d2b66(0x348)]=_0x4f8ac6[++_0x36ded0];else{if(_0x1ee5a1===_0x3d2b66(0x31a)||_0x1ee5a1==='-k')_0x489dca[_0x3d2b66(0x15b)]=_0x4f8ac6[++_0x36ded0];else{if(_0x1ee5a1==='--config'||_0x1ee5a1==='-c')_0x489dca[_0x3d2b66(0x271)]=_0x4f8ac6[++_0x36ded0];else{if(_0x1ee5a1==='--log-level')_0x489dca['logLevel']=_0x4f8ac6[++_0x36ded0];else{if(_0x1ee5a1===_0x3d2b66(0x88))_0x489dca[_0x3d2b66(0x27a)]=!![];else{if(_0x1ee5a1==='--no-admin')_0x489dca[_0x3d2b66(0x1ac)]=!![];else{if(_0x1ee5a1===_0x3d2b66(0x172)||_0x1ee5a1==='-e')_0x489dca[_0x3d2b66(0x2fd)]=_0x4f8ac6[++_0x36ded0];else{if(_0x1ee5a1===_0x3d2b66(0xeb))_0x489dca[_0x3d2b66(0x30b)]=_0x4f8ac6[++_0x36ded0];else{if(_0x1ee5a1===_0x3d2b66(0x121))_0x489dca['changes']=!![];else{if(_0x1ee5a1===_0x3d2b66(0x379))_0x489dca['blobs']=!![];else{if(_0x1ee5a1===_0x3d2b66(0x178))_0x489dca[_0x3d2b66(0xc4)]=!![];else{if(_0x1ee5a1==='--open'){const _0x3c6a70=[];while(_0x36ded0+0x1<_0x4f8ac6[_0x3d2b66(0x1b0)]&&!_0x4f8ac6[_0x36ded0+0x1][_0x3d2b66(0x1ef)]('--')){_0x3c6a70[_0x3d2b66(0x231)](_0x4f8ac6[++_0x36ded0]);}_0x489dca[_0x3d2b66(0x2f9)]=_0x3c6a70[_0x3d2b66(0x1b0)]>0x0?_0x3c6a70:!![];}else{if(_0x1ee5a1===_0x3d2b66(0x219))_0x489dca['logRequests']=!![];else{if(_0x1ee5a1===_0x3d2b66(0x1c7))_0x489dca[_0x3d2b66(0x167)]=_0x4f8ac6[++_0x36ded0];else{if(_0x1ee5a1===_0x3d2b66(0x106))_0x489dca[_0x3d2b66(0x26e)]=_0x4f8ac6[++_0x36ded0];else{if(_0x1ee5a1==='--label')_0x489dca['label']=_0x4f8ac6[++_0x36ded0];else{if(_0x1ee5a1==='--permissions')_0x489dca[_0x3d2b66(0x253)]=_0x4f8ac6[++_0x36ded0];else{if(_0x1ee5a1===_0x3d2b66(0x171))_0x489dca[_0x3d2b66(0x1b5)]=_0x4f8ac6[++_0x36ded0];else{if(_0x1ee5a1===_0x3d2b66(0x370))_0x489dca['ttl']=_0x4f8ac6[++_0x36ded0];else{if(_0x1ee5a1===_0x3d2b66(0x1d0))_0x489dca['token']=_0x4f8ac6[++_0x36ded0];else{if(_0x1ee5a1==='--username'||_0x1ee5a1==='-u')_0x489dca[_0x3d2b66(0x1c2)]=_0x4f8ac6[++_0x36ded0];else{if(_0x1ee5a1===_0x3d2b66(0x185))_0x489dca[_0x3d2b66(0x2b1)]=_0x4f8ac6[++_0x36ded0];else{if(_0x1ee5a1===_0x3d2b66(0x2d6)||_0x1ee5a1==='-v'){const _0x22b306=require$$2;console['log'](_0x22b306[_0x3d2b66(0x109)]),process[_0x3d2b66(0x15d)](0x0);}else(_0x1ee5a1===_0x3d2b66(0x38b)||_0x1ee5a1==='-h')&&(_0x57be3d(),process[_0x3d2b66(0x15d)](0x0));}}}}}}}}}}}}}}}}}}}}}}}_0x36ded0++;}return _0x489dca;}function _0x57be3d(){const _0x1223f8=_0x178958;console[_0x1223f8(0xdd)]('\x0a\x20\x20okdb\x20—\x20standalone\x20OKDB\x20server\x0a\x0a\x20\x20Usage:\x0a\x20\x20\x20\x20okdb\x20[options]\x0a\x20\x20\x20\x20okdb\x20<command>\x0a\x0a\x20\x20Options:\x0a\x20\x20\x20\x20-p,\x20--port\x20<port>\x20\x20\x20\x20\x20\x20\x20\x20HTTP\x20port\x20(default:\x208484)\x0a\x20\x20\x20\x20-d,\x20--path\x20<dir>\x20\x20\x20\x20\x20\x20\x20\x20\x20Database\x20directory\x20(default:\x20./okdb-data)\x0a\x20\x20\x20\x20-k,\x20--key\x20\x20<secret>\x20\x20\x20\x20\x20\x20Encryption\x20key\x20for\x20data\x20at\x20rest\x0a\x20\x20\x20\x20-c,\x20--config\x20<file>\x20\x20\x20\x20\x20\x20Config\x20file\x20path\x20(default:\x20.kdbconfig)\x0a\x20\x20\x20\x20\x20\x20\x20\x20--log-level\x20<level>\x20\x20Log\x20level:\x20debug\x20|\x20info\x20|\x20warn\x20|\x20error\x20(default:\x20info)\x0a\x20\x20\x20\x20\x20\x20\x20\x20--no-repl\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Start\x20server\x20without\x20interactive\x20shell\x0a\x20\x20\x20\x20\x20\x20\x20\x20--no-admin\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Disable\x20admin\x20UI\x0a\x20\x20\x20\x20\x20\x20\x20\x20--open\x20[ip\x20...]\x20\x20\x20\x20\x20\x20Open\x20mode:\x20bypass\x20auth\x20for\x20listed\x20IPs\x20(default:\x20localhost).\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Examples:\x20--open\x20\x20--open\x20192.168.1.0/24\x20\x20--open\x20*\x0a\x20\x20\x20\x20\x20\x20\x20\x20--log-requests\x20\x20\x20\x20\x20\x20\x20Print\x20every\x20HTTP\x20request\x20to\x20stdout\x20(for\x20debugging)\x0a\x20\x20\x20\x20-v,\x20--version\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Print\x20version\x20and\x20exit\x0a\x20\x20\x20\x20-h,\x20--help\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Show\x20this\x20help\x0a\x0a\x20\x20Commands:\x0a\x20\x20\x20\x20version\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Print\x20version\x20and\x20exit\x0a\x20\x20\x20\x20doctor\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Run\x20health\x20checks\x0a\x20\x20\x20\x20init\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Create\x20.kdbconfig\x20and\x20okdb-data/\x0a\x20\x20\x20\x20token\x20create\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Create\x20a\x20token\x20in\x20the\x20local\x20DB\x20(direct\x20access,\x20no\x20HTTP)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--name\x20<name>\x20\x20\x20\x20\x20\x20For\x20password\x20login\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--password\x20<pass>\x20\x20Password\x20(requires\x20--name)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--label\x20<text>\x20\x20\x20\x20\x20Human\x20description\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--permissions\x20<l>\x20\x20Comma-separated\x20baseline\x20permissions\x20(e.g.\x20\x22*\x22\x20or\x20\x22data:read\x22)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--grants\x20<json>\x20\x20\x20\x20Per-env\x20grants\x20as\x20JSON\x20(e.g.\x20\x27{\x22orders\x22:[\x22data:*\x22]}\x27)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--ttl\x20<ms>\x20\x20\x20\x20\x20\x20\x20\x20\x20Optional\x20TTL\x20in\x20milliseconds\x0a\x20\x20\x20\x20token\x20list\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20List\x20all\x20tokens\x20in\x20the\x20local\x20DB\x0a\x20\x20\x20\x20token\x20revoke\x20<id>\x20\x20\x20\x20\x20\x20\x20\x20Revoke\x20(delete)\x20a\x20token\x20by\x20id\x20(full\x20uuid\x20or\x20unique\x20prefix)\x0a\x20\x20\x20\x20join\x20<address>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Join\x20an\x20existing\x20cluster\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--token\x20<t>\x20\x20\x20\x20\x20\x20\x20\x20Bearer\x20token\x20from\x20the\x20cluster\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--username\x20<u>\x20\x20\x20\x20\x20Or,\x20username\x20for\x20login\x20exchange\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--password\x20<p>\x20\x20\x20\x20\x20Password\x20for\x20login\x20exchange\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--address\x20<addr>\x20\x20\x20This\x20node\x27s\x20reachable\x20sync\x20address\x20(required)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--path\x20<dir>\x20\x20\x20\x20\x20\x20\x20Local\x20DB\x20path\x0a\x20\x20\x20\x20backup\x20[dir]\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Hot\x20filesystem\x20backup\x20via\x20LMDB\x20native\x20copy\x20(default:\x20./okdb-backup)\x0a\x20\x20\x20\x20export\x20<file>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Streaming\x20NDJSON\x20logical\x20export\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--env\x20<name>\x20\x20\x20\x20\x20\x20env\x20to\x20export\x20(default:\x20default)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--types\x20<a,b,...>\x20comma-separated\x20type\x20filter\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--changes\x20\x20\x20\x20\x20\x20\x20\x20\x20include\x20changelog\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--blobs\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20also\x20export\x20blob\x20files\x20alongside\x0a\x20\x20\x20\x20import\x20<file>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Streaming\x20NDJSON\x20logical\x20import\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--env\x20<name>\x20\x20\x20\x20\x20\x20target\x20env\x20override\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--types\x20<a,b,...>\x20import\x20only\x20these\x20types\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--drop\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20drop\x20&\x20recreate\x20existing\x20types\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--changes\x20\x20\x20\x20\x20\x20\x20\x20\x20restore\x20changelog\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--blobs\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20also\x20import\x20blob\x20files\x20alongside\x0a\x20\x20\x20\x20reset\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Delete\x20and\x20recreate\x20database\x20(with\x20confirmation)\x0a\x20\x20\x20\x20license\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20List\x20stored\x20licenses,\x20current\x20tier,\x20and\x20usage\x0a\x20\x20\x20\x20license\x20<blob|path>\x20\x20\x20\x20\x20\x20Add\x20a\x20license\x20blob\x20(or\x20read\x20from\x20a\x20.license\x20file)\x0a\x20\x20\x20\x20license\x20<activation>\x20\x20\x20\x20\x20Activate\x20a\x20previously-added\x20license\x20with\x20the\x20vendor\x27s\x20token\x0a\x20\x20\x20\x20license\x20<id>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Show\x20details\x20for\x20one\x20stored\x20license\x20(by\x20uuid\x20or\x20prefix)\x0a\x20\x20\x20\x20license\x20remove\x20<id>\x20\x20\x20\x20\x20\x20Remove\x20a\x20stored\x20license\x0a\x0a\x20\x20Environment\x20variables:\x0a\x20\x20\x20\x20OKDB_PORT\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20HTTP\x20port\x0a\x20\x20\x20\x20OKDB_PATH\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Database\x20directory\x0a\x20\x20\x20\x20OKDB_LOG_LEVEL\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Log\x20level\x20(debug|info|warn|error)\x0a\x20\x20\x20\x20OKDB_KEY\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Encryption\x20key\x0a\x20\x20\x20\x20OKDB_NO_REPL=1\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Disable\x20REPL\x0a\x20\x20\x20\x20OKDB_NO_ADMIN=1\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Disable\x20admin\x20UI\x0a\x0a\x20\x20Config\x20file\x20(.kdbconfig)\x20—\x20JSON,\x20all\x20keys\x20optional:\x0a\x20\x20\x20\x20{\x0a\x20\x20\x20\x20\x20\x20\x22port\x22:\x20\x20\x20\x20\x208484,\x0a\x20\x20\x20\x20\x20\x20\x22path\x22:\x20\x20\x20\x20\x20\x22./okdb-data\x22,\x0a\x20\x20\x20\x20\x20\x20\x22key\x22:\x20\x20\x20\x20\x20\x20\x22...\x22,\x0a\x20\x20\x20\x20\x20\x20\x22logLevel\x22:\x20\x22info\x22,\x0a\x20\x20\x20\x20\x20\x20\x22noAdmin\x22:\x20\x20false,\x0a\x20\x20\x20\x20\x20\x20\x22noRepl\x22:\x20\x20\x20false,\x0a\x20\x20\x20\x20\x20\x20\x22auth\x22:\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x22open\x22:\x20false\x0a\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20}\x0a\x0a\x20\x20Examples:\x0a\x20\x20\x20\x20okdb\x0a\x20\x20\x20\x20okdb\x20--port\x209000\x20--path\x20./mydb\x0a\x20\x20\x20\x20okdb\x20--no-repl\x20--port\x208080\x0a\x20\x20\x20\x20okdb\x20--open\x0a\x20\x20\x20\x20okdb\x20--open\x20192.168.1.0/24\x0a\x20\x20\x20\x20okdb\x20doctor\x0a\x20\x20\x20\x20okdb\x20backup\x20./my-backup\x0a');}const _0x3fc97c=new Set([_0x178958(0x295),_0x178958(0x1f8),_0x178958(0x331),_0x178958(0x266)]);function _0x4d61dd(_0x53a9f7){const _0x42715f=_0x178958,_0x35764b=_0x53a9f7[_0x42715f(0x271)]?_0x4e5a5b['resolve'](_0x53a9f7[_0x42715f(0x271)]):_0x4e5a5b[_0x42715f(0x235)](_0x42715f(0x1a0));let _0x2830fd={};if(_0x31ec50['existsSync'](_0x35764b))try{const _0x143834=_0x31ec50[_0x42715f(0x146)](_0x35764b,'utf8')[_0x42715f(0x156)](/^\uFEFF/,'');_0x2830fd=JSON[_0x42715f(0x179)](_0x143834),console[_0x42715f(0xdd)]('[okdb]\x20loaded\x20config:\x20'+_0x35764b);}catch(_0x2e49b7){console['error']('[okdb]\x20failed\x20to\x20parse\x20config\x20file\x20'+_0x35764b+':\x20'+_0x2e49b7['message']),process[_0x42715f(0x15d)](0x1);}const _0x243963={'port':process.env.OKDB_PORT?Number(process.env.OKDB_PORT):undefined,'path':process.env.OKDB_PATH??undefined,'key':process.env.OKDB_KEY??undefined,'logLevel':process.env.OKDB_LOG_LEVEL??undefined,'noRepl':process.env.OKDB_NO_REPL==='1'?!![]:undefined,'noAdmin':process.env.OKDB_NO_ADMIN==='1'?!![]:undefined},_0x3bf65e={'port':_0x53a9f7[_0x42715f(0x1e9)]??_0x2830fd[_0x42715f(0x1e9)]??_0x243963[_0x42715f(0x1e9)]??0x2124,'dbPath':_0x53a9f7[_0x42715f(0x348)]??_0x2830fd[_0x42715f(0x348)]??_0x243963[_0x42715f(0x348)]??_0x42715f(0x267),'key':_0x53a9f7[_0x42715f(0x15b)]??_0x2830fd[_0x42715f(0x15b)]??_0x243963[_0x42715f(0x15b)]??undefined,'logLevel':_0x53a9f7[_0x42715f(0x100)]??_0x2830fd['logLevel']??_0x243963['logLevel']??'info','noRepl':_0x53a9f7['noRepl']??_0x2830fd[_0x42715f(0x27a)]??_0x243963[_0x42715f(0x27a)]??![],'noAdmin':_0x53a9f7[_0x42715f(0x1ac)]??_0x2830fd[_0x42715f(0x1ac)]??_0x243963[_0x42715f(0x1ac)]??![],'admin':_0x2830fd[_0x42715f(0x1f2)]??{},'api':_0x2830fd[_0x42715f(0xdc)]??undefined,'auth':_0x2830fd[_0x42715f(0x2a1)]??undefined,'mcp':_0x2830fd['mcp']??undefined,'timeMachine':_0x2830fd[_0x42715f(0x32e)]!==![]?_0x2830fd['timeMachine']??{}:![]};return _0x53a9f7[_0x42715f(0x2f9)]!==undefined&&(_0x3bf65e['auth']=_0x3bf65e[_0x42715f(0x2a1)]||{},_0x3bf65e[_0x42715f(0x2a1)][_0x42715f(0x2f9)]=_0x53a9f7[_0x42715f(0x2f9)]),_0x53a9f7[_0x42715f(0x351)]&&(_0x3bf65e['debug']=_0x3bf65e[_0x42715f(0x295)]||{},_0x3bf65e[_0x42715f(0x295)][_0x42715f(0x351)]=!![]),(!Number[_0x42715f(0x25f)](_0x3bf65e[_0x42715f(0x1e9)])||_0x3bf65e['port']<0x1||_0x3bf65e[_0x42715f(0x1e9)]>0xffff)&&(console[_0x42715f(0x266)](_0x42715f(0x15c)+_0x3bf65e[_0x42715f(0x1e9)]+_0x42715f(0x11d)),process['exit'](0x1)),!_0x3fc97c[_0x42715f(0x158)](_0x3bf65e[_0x42715f(0x100)])&&(console['error'](_0x42715f(0x2de)+_0x3bf65e[_0x42715f(0x100)]+_0x42715f(0x1a3)),process[_0x42715f(0x15d)](0x1)),_0x3bf65e;}function _0x4297a1(_0x33f478){const _0x4551ad=_0x178958;return!!(_0x33f478&&typeof _0x33f478===_0x4551ad(0x347)&&!Array['isArray'](_0x33f478)&&Object['keys'](_0x33f478)[_0x4551ad(0x1b0)]>0x0);}const _0x3e7f9a=!process[_0x178958(0x294)]['isTTY']||!!process.env.NO_COLOR;function _0x211b7d(_0x3a818a,_0x5eab68){const _0x494da0=_0x178958;return _0x3e7f9a?_0x5eab68:'\x1b['+_0x3a818a+'m'+_0x5eab68+_0x494da0(0x192);}function _0x1297e8(_0x33f047){const _0x2b7b19=_0x178958;if(!_0x33f047||_0x33f047[_0x2b7b19(0x1b0)]===0x0)return;const _0xb4593f='─'['repeat'](0x38);process[_0x2b7b19(0x22b)][_0x2b7b19(0xef)]('\x0a'),process['stderr'][_0x2b7b19(0xef)](_0x211b7d('33',_0x2b7b19(0x247)+_0x33f047[_0x2b7b19(0x1b0)]+_0x2b7b19(0x131)+(_0x33f047[_0x2b7b19(0x1b0)]>0x1?'S':'')+'\x0a')),process[_0x2b7b19(0x22b)][_0x2b7b19(0xef)]('\x20\x20'+_0xb4593f+'\x0a');for(const _0xb1d77b of _0x33f047){const _0x3ff58e=_0xb1d77b[_0x2b7b19(0x8a)]===_0x2b7b19(0x266)?_0x211b7d('31',_0x2b7b19(0x1fc)):_0x211b7d('33',_0x2b7b19(0x32a));process['stderr']['write'](_0x3ff58e+'\x20\x20'+_0x211b7d('1',_0xb1d77b[_0x2b7b19(0xd9)])+'\x0a'),process['stderr'][_0x2b7b19(0xef)](_0x2b7b19(0x200)+_0xb1d77b['message']+'\x0a');if(_0xb1d77b[_0x2b7b19(0x2c8)])process['stderr']['write'](_0x2b7b19(0x200)+_0x211b7d('2','Hint:\x20'+_0xb1d77b[_0x2b7b19(0x2c8)])+'\x0a');process[_0x2b7b19(0x22b)]['write']('\x0a');}process[_0x2b7b19(0x22b)][_0x2b7b19(0xef)]('\x20\x20'+_0xb4593f+'\x0a\x0a');}function _0x38fa7e(_0x1423ba,_0x24e27d){const _0x169023=_0x178958,_0x555b4a=_0x1423ba[_0x169023(0x232)][_0x169023(0x1d6)](_0x24e27d);return new Promise((_0x364bb3,_0x138917)=>{const _0x37938f=_0x169023;_0x555b4a[_0x37938f(0x1de)]('listening',_0x364bb3),_0x555b4a['once'](_0x37938f(0x266),_0x138917);});}async function _0x2aee4d(_0x10a467){const _0x2c7309=_0x178958,_0x4dca2d=require$$3;console['log']('\x0a\x20\x20okdb\x20doctor\x0a');let _0x228e2f=!![];const _0x1a89a5=(_0x137f4d,_0x31fd8a)=>{console['log']('\x20\x20'+(_0x137f4d?'✓':'✗')+'\x20'+_0x31fd8a);if(!_0x137f4d)_0x228e2f=![];},_0xf7f30f=Number(process[_0x2c7309(0x109)][_0x2c7309(0x156)]('v','')[_0x2c7309(0xb7)]('.')[0x0]);_0x1a89a5(_0xf7f30f>=0x12,_0x2c7309(0xa7)+process[_0x2c7309(0x109)]+(_0xf7f30f<0x12?'\x20\x20(need\x20≥\x2018)':''));const _0x3cc5f7=_0x4e5a5b[_0x2c7309(0x235)](_0x10a467[_0x2c7309(0x36d)]);try{_0x31ec50[_0x2c7309(0x10c)](_0x3cc5f7,{'recursive':!![]});const _0x1e3252=_0x4e5a5b[_0x2c7309(0x161)](_0x3cc5f7,_0x2c7309(0x272));_0x31ec50[_0x2c7309(0x359)](_0x1e3252,''),_0x31ec50[_0x2c7309(0x205)](_0x1e3252),_0x1a89a5(!![],_0x2c7309(0x103)+_0x3cc5f7);}catch(_0x18fe14){_0x1a89a5(![],_0x2c7309(0x198)+_0x3cc5f7+_0x2c7309(0x163)+_0x18fe14[_0x2c7309(0x307)]+')');}const _0x3f63a5=await new Promise(_0x214c4b=>{const _0x4cf0ca=_0x2c7309,_0xed9452=_0x4dca2d['createServer']();_0xed9452[_0x4cf0ca(0x1de)](_0x4cf0ca(0x266),()=>_0x214c4b(![])),_0xed9452[_0x4cf0ca(0x1de)](_0x4cf0ca(0xc2),()=>{const _0x4fb2e5=_0x4cf0ca;_0xed9452[_0x4fb2e5(0x2a5)](),_0x214c4b(!![]);}),_0xed9452[_0x4cf0ca(0x1d6)](_0x10a467['port'],'127.0.0.1');});_0x1a89a5(_0x3f63a5,'port\x20'+_0x10a467[_0x2c7309(0x1e9)]+'\x20'+(_0x3f63a5?_0x2c7309(0x19e):_0x2c7309(0x157)));const _0x5dbfb9=_0x4e5a5b[_0x2c7309(0x235)](_0x2c7309(0x1a0));if(_0x31ec50[_0x2c7309(0x36f)](_0x5dbfb9))try{JSON[_0x2c7309(0x179)](_0x31ec50['readFileSync'](_0x5dbfb9,_0x2c7309(0x30f))['replace'](/^\uFEFF/,'')),_0x1a89a5(!![],_0x2c7309(0x17b)+_0x5dbfb9);}catch(_0x424be2){_0x1a89a5(![],_0x2c7309(0x114)+_0x424be2[_0x2c7309(0x307)]);}else _0x1a89a5(!![],'no\x20.kdbconfig\x20(using\x20defaults)');console[_0x2c7309(0xdd)](''),_0x228e2f?console[_0x2c7309(0xdd)](_0x2c7309(0x252)):(console[_0x2c7309(0xdd)](_0x2c7309(0x291)),process['exit'](0x1));}async function _0x5dbf09(){const _0x3375c2=_0x178958,_0x33bdd3=_0x4e5a5b['resolve']('.kdbconfig');!_0x31ec50[_0x3375c2(0x36f)](_0x33bdd3)?(_0x31ec50['writeFileSync'](_0x33bdd3,JSON[_0x3375c2(0xf3)]({'port':0x2124,'path':_0x3375c2(0x267),'logLevel':_0x3375c2(0x1f8),'noRepl':![],'noAdmin':![]},null,0x2)+'\x0a'),console['log']('[okdb]\x20created\x20.kdbconfig')):console[_0x3375c2(0xdd)](_0x3375c2(0x1b7));const _0xa7d683=_0x4e5a5b[_0x3375c2(0x235)](_0x3375c2(0x267));!_0x31ec50[_0x3375c2(0x36f)](_0xa7d683)?(_0x31ec50[_0x3375c2(0x10c)](_0xa7d683,{'recursive':!![]}),console[_0x3375c2(0xdd)](_0x3375c2(0x20e))):console['log'](_0x3375c2(0x1e6)),console['log']('\x0a\x20\x20Run\x20okdb\x20to\x20start\x20the\x20server.\x0a');}async function _0x265e3a(_0x58ba6b){const _0x36187=_0x178958,_0x4fb5f6=_0x4e5a5b[_0x36187(0x235)](_0x58ba6b[_0x36187(0x36d)]);if(!_0x31ec50[_0x36187(0x36f)](_0x4fb5f6)){console[_0x36187(0xdd)](_0x36187(0x357)+_0x4fb5f6+_0x36187(0xe2));return;}const _0x173fcc=require$$0$2,_0x4ad09e=_0x173fcc[_0x36187(0x18c)]({'input':process[_0x36187(0x274)],'output':process[_0x36187(0x294)]}),_0xfba6e=await new Promise(_0x44c972=>_0x4ad09e['question'](_0x36187(0xcf)+_0x4fb5f6+_0x36187(0x1ad),_0x44c972));_0x4ad09e['close'](),console[_0x36187(0xdd)]('');if(_0xfba6e[_0x36187(0x15e)]()[_0x36187(0x108)]()!==_0x36187(0x2a6)){console[_0x36187(0xdd)]('[okdb]\x20reset\x20aborted');return;}_0x31ec50[_0x36187(0xcb)](_0x4fb5f6,{'recursive':!![],'force':!![]}),console[_0x36187(0xdd)](_0x36187(0x2f7)+_0x4fb5f6+_0x36187(0x37e));}async function _0x494019(_0x1e6ef3,_0x996b57){const _0x4f08df=_0x178958,_0x3d50b2=require$$5,_0x1cc9d7=_0x4e5a5b[_0x4f08df(0x235)](_0x996b57[_0x4f08df(0x36d)]);console[_0x4f08df(0xdd)](_0x4f08df(0x2fe)+_0x1cc9d7+'…');const _0x9f5952=new _0x3d50b2(_0x1cc9d7,_0x996b57[_0x4f08df(0x15b)]?{'encryptionKey':_0x996b57['key']}:{});await _0x9f5952['open'](),console['log']('[okdb]\x20backing\x20up\x20to\x20'+_0x1e6ef3+'…');const {envs:_0x1a5ce4}=await _0x9f5952[_0x4f08df(0x2fb)][_0x4f08df(0x95)](_0x1e6ef3);for(const _0x4ae039 of _0x1a5ce4){const _0x49dc5c=_0x4ae039['sizeBefore']>0x0?'\x20\x20('+(_0x4ae039[_0x4f08df(0x14b)]/0x400/0x400)[_0x4f08df(0x35a)](0x2)+_0x4f08df(0x212)+(_0x4ae039[_0x4f08df(0x277)]/0x400/0x400)[_0x4f08df(0x35a)](0x2)+'\x20MB)':'';console[_0x4f08df(0xdd)](_0x4f08df(0x1c5)+_0x4ae039[_0x4f08df(0x167)]+_0x4f08df(0xd6)+_0x4ae039[_0x4f08df(0x1d1)]+_0x49dc5c);}await _0x9f5952['close'](),console[_0x4f08df(0xdd)](_0x4f08df(0x21f));}async function _0x194b4b(_0x4119bc,_0x128780,_0x2ac7f3){const _0x4f3f77=_0x178958,_0x1e77c8=require$$5,_0xb12b7c=_0x4e5a5b[_0x4f3f77(0x235)](_0x128780['dbPath']),_0x9f95b0=_0x2ac7f3['env']??_0x4f3f77(0x1f3),_0x553228=_0x2ac7f3[_0x4f3f77(0x30b)]?_0x2ac7f3[_0x4f3f77(0x30b)][_0x4f3f77(0xb7)](',')['map'](_0x1b8ac8=>_0x1b8ac8[_0x4f3f77(0x15e)]()):null;console[_0x4f3f77(0xdd)](_0x4f3f77(0x2fe)+_0xb12b7c+'…');const _0x5d3a91=new _0x1e77c8(_0xb12b7c,_0x128780[_0x4f3f77(0x15b)]?{'encryptionKey':_0x128780[_0x4f3f77(0x15b)]}:{});await _0x5d3a91[_0x4f3f77(0x2f9)](),console['log'](_0x4f3f77(0x117)+_0x9f95b0+_0x4f3f77(0x27e)+_0x4119bc+'…');const _0x383415=await _0x5d3a91[_0x4f3f77(0x2fb)][_0x4f3f77(0x1d3)](_0x4119bc,{'envName':_0x9f95b0,'types':_0x553228,'includeChanges':!!_0x2ac7f3[_0x4f3f77(0x35f)]});console[_0x4f3f77(0xdd)](_0x4f3f77(0xbb)+_0x383415['types']+_0x4f3f77(0x36c)+_0x383415['records']+_0x4f3f77(0x335)+_0x383415[_0x4f3f77(0x35f)]);if(_0x2ac7f3[_0x4f3f77(0x2b4)]){const _0x5b2a54=_0x4e5a5b[_0x4f3f77(0x161)](_0x4e5a5b[_0x4f3f77(0xb1)](_0x4119bc),_0x4f3f77(0x2b4));process['stdout'][_0x4f3f77(0xef)](_0x4f3f77(0x2b7));const {count:_0x3606f1,bytes:_0x4574c6}=await _0x5d3a91[_0x4f3f77(0x2fb)][_0x4f3f77(0x165)](_0x5b2a54);console[_0x4f3f77(0xdd)](_0x4f3f77(0x31d)+_0x5b2a54+_0x4f3f77(0x163)+_0x3606f1+_0x4f3f77(0xb6)+(_0x3606f1!==0x1?'s':'')+',\x20'+(_0x4574c6/0x400/0x400)['toFixed'](0x2)+_0x4f3f77(0x2cb));}await _0x5d3a91[_0x4f3f77(0x2a5)](),console[_0x4f3f77(0xdd)](_0x4f3f77(0xb0));}async function _0x40f9ff(_0x293a9c,_0x206351,_0x379887){const _0x4fd2ab=_0x178958,_0x2ea7a3=require$$5,_0x3f36d0=_0x4e5a5b[_0x4fd2ab(0x235)](_0x206351[_0x4fd2ab(0x36d)]),_0x5de6ba=_0x379887[_0x4fd2ab(0x2fd)]??null,_0xf9a960=_0x379887['types']?_0x379887[_0x4fd2ab(0x30b)][_0x4fd2ab(0xb7)](',')['map'](_0x34c34b=>_0x34c34b['trim']()):null,_0x40a015=!!_0x379887[_0x4fd2ab(0xc4)];console[_0x4fd2ab(0xdd)](_0x4fd2ab(0x2fe)+_0x3f36d0+'…');const _0x22ff20=new _0x2ea7a3(_0x3f36d0,_0x206351[_0x4fd2ab(0x15b)]?{'encryptionKey':_0x206351[_0x4fd2ab(0x15b)]}:{});await _0x22ff20['open'](),console[_0x4fd2ab(0xdd)](_0x4fd2ab(0x209)+_0x293a9c+'…');const _0xfead9=await _0x22ff20['migrate'][_0x4fd2ab(0x21e)](_0x293a9c,{'envName':_0x5de6ba,'types':_0xf9a960,'dropExisting':_0x40a015,'includeChanges':!!_0x379887[_0x4fd2ab(0x35f)],'onProgress':({type:_0x21032e,count:_0x57c6de})=>{const _0x532205=_0x4fd2ab;process[_0x532205(0x294)][_0x532205(0xef)](_0x532205(0x152)+_0x21032e+':\x20'+_0x57c6de+_0x532205(0x113));}});process[_0x4fd2ab(0x294)][_0x4fd2ab(0xef)]('\x0a'),console[_0x4fd2ab(0xdd)]('[okdb]\x20imported\x20\x20types='+_0xfead9[_0x4fd2ab(0x30b)]+_0x4fd2ab(0x36c)+_0xfead9[_0x4fd2ab(0x20c)]+_0x4fd2ab(0x335)+_0xfead9[_0x4fd2ab(0x35f)]);if(_0x379887[_0x4fd2ab(0x2b4)]){const _0x367d9b=_0x4e5a5b['join'](_0x4e5a5b[_0x4fd2ab(0xb1)](_0x293a9c),_0x4fd2ab(0x2b4));if(_0x31ec50[_0x4fd2ab(0x36f)](_0x367d9b)){const {imported:_0x175157,skipped:_0x4c50c5}=await _0x22ff20['migrate'][_0x4fd2ab(0x18f)](_0x367d9b);console['log']('[okdb]\x20blobs:\x20imported='+_0x175157+_0x4fd2ab(0x24f)+_0x4c50c5);}}await _0x22ff20[_0x4fd2ab(0x2a5)](),console[_0x4fd2ab(0xdd)](_0x4fd2ab(0x216));}async function _0x19981c(_0x4127f9,_0x2b8b01){const _0x2d1613=_0x178958;_0x2b8b01[_0x2d1613(0x26e)]&&!_0x2b8b01[_0x2d1613(0x167)]&&(console[_0x2d1613(0x266)](_0x2d1613(0x215)),process[_0x2d1613(0x15d)](0x1));const _0x462274=_0x2b8b01[_0x2d1613(0x253)]?_0x2b8b01[_0x2d1613(0x253)][_0x2d1613(0xb7)](',')[_0x2d1613(0x282)](_0x2d1a32=>_0x2d1a32['trim']())['filter'](Boolean):[];let _0x19ee6a={};if(_0x2b8b01['grants'])try{_0x19ee6a=JSON['parse'](_0x2b8b01[_0x2d1613(0x1b5)]);if(typeof _0x19ee6a!=='object'||Array[_0x2d1613(0x140)](_0x19ee6a)||_0x19ee6a===null)throw new Error();}catch{console[_0x2d1613(0x266)](_0x2d1613(0xce)),process[_0x2d1613(0x15d)](0x1);}const _0x384841=require$$5,{randomToken:_0x452531,hashToken:_0x2deb58,hashPassword:_0x2a1526}=requireOkdbAuthTokens(),_0x192fca=require$$0,_0x48befb=_0x4e5a5b[_0x2d1613(0x235)](_0x4127f9[_0x2d1613(0x36d)]),_0x4b57cb=new _0x384841(_0x48befb,_0x4127f9[_0x2d1613(0x15b)]?{'encryptionKey':_0x4127f9[_0x2d1613(0x15b)]}:{});await _0x4b57cb['open']();try{await _0x4b57cb[_0x2d1613(0x2a1)][_0x2d1613(0x14e)]();if(_0x2b8b01[_0x2d1613(0x167)]){const _0x579009=await _0x4b57cb['auth'][_0x2d1613(0x112)](_0x2b8b01[_0x2d1613(0x167)]);_0x579009&&(console[_0x2d1613(0x266)](_0x2d1613(0x315)+_0x2b8b01[_0x2d1613(0x167)]+_0x2d1613(0x227)),process[_0x2d1613(0x15d)](0x1));}const _0x161dc1=_0x452531(0x20),_0x4218a5=_0x2deb58(_0x161dc1),_0x1553d4=_0x2b8b01['password']?await _0x2a1526(_0x2b8b01[_0x2d1613(0x26e)]):null,_0x2a94ad=_0x192fca[_0x2d1613(0x2dc)](),_0x16dfe9={'tokenHash':_0x4218a5,'name':_0x2b8b01[_0x2d1613(0x167)]||null,'passwordHash':_0x1553d4,'label':_0x2b8b01[_0x2d1613(0x26f)]||null,'permissions':_0x462274,'grants':_0x19ee6a,'createdAt':Date[_0x2d1613(0x149)](),'lastUsedAt':null},_0x2603ce=_0x2b8b01[_0x2d1613(0x35e)]?{'ttl':Number(_0x2b8b01['ttl'])}:undefined;await _0x4b57cb[_0x2d1613(0x122)][_0x2d1613(0x1a4)](_0x2d1613(0xfd),_0x2a94ad,_0x16dfe9,_0x2603ce),console[_0x2d1613(0xdd)](_0x2d1613(0x377)),console[_0x2d1613(0xdd)](_0x2d1613(0x1d7)+_0x2a94ad),console[_0x2d1613(0xdd)](_0x2d1613(0x127)+(_0x2b8b01[_0x2d1613(0x167)]||_0x2d1613(0x284))),console[_0x2d1613(0xdd)](_0x2d1613(0xd8)+(_0x2b8b01[_0x2d1613(0x26f)]||'(unset)')),console[_0x2d1613(0xdd)](_0x2d1613(0x2e9)+(_0x462274[_0x2d1613(0x161)](',\x20')||_0x2d1613(0x13f))),console[_0x2d1613(0xdd)](_0x2d1613(0x376)),console[_0x2d1613(0xdd)](_0x2d1613(0x125)+_0x161dc1+'\x0a');}finally{await _0x4b57cb[_0x2d1613(0x2a5)]();}}async function _0x54d243(_0x13e77b){const _0x485926=_0x178958,_0x1ede47=require$$5,_0x3e6257=_0x4e5a5b[_0x485926(0x235)](_0x13e77b[_0x485926(0x36d)]),_0x67a0f3=new _0x1ede47(_0x3e6257,_0x13e77b[_0x485926(0x15b)]?{'encryptionKey':_0x13e77b[_0x485926(0x15b)]}:{});await _0x67a0f3[_0x485926(0x2f9)]();try{const _0x4f60f7=_0x67a0f3[_0x485926(0x122)];if(!_0x4f60f7||!_0x4f60f7[_0x485926(0xa2)](_0x485926(0xfd))){console[_0x485926(0xdd)](_0x485926(0x2ff));return;}const _0x17cd43=[];for(const {key:_0x537521,value:_0x6f2050}of _0x4f60f7['getRange'](_0x485926(0xfd))){_0x17cd43[_0x485926(0x231)]({'id':_0x537521,'name':_0x6f2050['name']||_0x485926(0x284),'label':_0x6f2050['label']||_0x485926(0x284),'permissions':Array[_0x485926(0x140)](_0x6f2050[_0x485926(0x253)])?_0x6f2050[_0x485926(0x253)][_0x485926(0x161)](','):'','created':_0x6f2050[_0x485926(0x151)]?new Date(_0x6f2050[_0x485926(0x151)])['toISOString']()[_0x485926(0x341)](0x0,0xa):''});}if(_0x17cd43[_0x485926(0x1b0)]===0x0){console[_0x485926(0xdd)](_0x485926(0x2ff));return;}const _0x492b58=!process[_0x485926(0x294)]['columns']||process[_0x485926(0x294)][_0x485926(0x14a)]>=0x64,_0x4c442a=_0x492b58?0x24:0xa,_0x5459d5=['ID'[_0x485926(0x20b)](_0x4c442a),'NAME'[_0x485926(0x20b)](0x10),_0x485926(0x1bb)['padEnd'](0x14),_0x485926(0x223)[_0x485926(0x20b)](0x14),_0x485926(0x33c)]['join']('\x20\x20');console['log']('\x0a'+_0x5459d5),console[_0x485926(0xdd)]('-'[_0x485926(0x99)](_0x5459d5[_0x485926(0x1b0)]));for(const _0x5eb119 of _0x17cd43){const _0x2ce68b=_0x492b58?_0x5eb119['id']:_0x5eb119['id'][_0x485926(0x341)](0x0,0x8)+'…';console[_0x485926(0xdd)]([_0x2ce68b[_0x485926(0x20b)](_0x4c442a),_0x5eb119[_0x485926(0x167)][_0x485926(0x341)](0x0,0x10)['padEnd'](0x10),_0x5eb119['label'][_0x485926(0x341)](0x0,0x14)[_0x485926(0x20b)](0x14),_0x5eb119[_0x485926(0x253)][_0x485926(0x341)](0x0,0x14)[_0x485926(0x20b)](0x14),_0x5eb119[_0x485926(0x18d)]][_0x485926(0x161)]('\x20\x20'));}console['log']('');}finally{await _0x67a0f3[_0x485926(0x2a5)]();}}async function _0x58a0e2(_0x1a3a79,_0x9d0f1a){const _0x13c15=_0x178958;!_0x1a3a79&&(console['error'](_0x13c15(0x283)),process[_0x13c15(0x15d)](0x1));const _0xde296c=require$$5,_0x3670d8=_0x4e5a5b[_0x13c15(0x235)](_0x9d0f1a[_0x13c15(0x36d)]),_0x46ab39=new _0xde296c(_0x3670d8,_0x9d0f1a[_0x13c15(0x15b)]?{'encryptionKey':_0x9d0f1a['key']}:{});await _0x46ab39['open']();try{const _0x11f16d=_0x46ab39[_0x13c15(0x122)];(!_0x11f16d||!_0x11f16d['hasType'](_0x13c15(0xfd)))&&(console[_0x13c15(0x266)](_0x13c15(0x164)+_0x1a3a79+'\x22'),process[_0x13c15(0x15d)](0x1));let _0x4959b5=null,_0x464d2a=null;const _0x5765e9=_0x11f16d[_0x13c15(0x187)](_0x13c15(0xfd),_0x1a3a79);if(_0x5765e9)_0x4959b5=_0x1a3a79,_0x464d2a=_0x5765e9;else{const _0x38caaa=[];for(const {key:_0x590d7c,value:_0x32dfc8}of _0x11f16d['getRange'](_0x13c15(0xfd))){if(_0x590d7c[_0x13c15(0x1ef)](_0x1a3a79))_0x38caaa[_0x13c15(0x231)]({'key':_0x590d7c,'value':_0x32dfc8});}_0x38caaa['length']===0x0&&(console[_0x13c15(0x266)](_0x13c15(0x164)+_0x1a3a79+'\x22'),process[_0x13c15(0x15d)](0x1));if(_0x38caaa['length']>0x1){console[_0x13c15(0x266)](_0x13c15(0xf7)+_0x1a3a79+_0x13c15(0x1be)+_0x38caaa[_0x13c15(0x1b0)]+'\x20tokens:');for(const _0x28f71e of _0x38caaa){console[_0x13c15(0x266)]('\x20\x20'+_0x28f71e[_0x13c15(0x15b)]+'\x20\x20(name:\x20'+(_0x28f71e['value'][_0x13c15(0x167)]||_0x13c15(0x284))+')');}process[_0x13c15(0x15d)](0x1);}_0x4959b5=_0x38caaa[0x0][_0x13c15(0x15b)],_0x464d2a=_0x38caaa[0x0][_0x13c15(0x1d2)];}await _0x11f16d['remove'](_0x13c15(0xfd),_0x4959b5),console[_0x13c15(0xdd)](_0x13c15(0xe4)+_0x4959b5+_0x13c15(0x2ea)+(_0x464d2a[_0x13c15(0x167)]||_0x13c15(0x284))+_0x13c15(0x2ae)+(_0x464d2a[_0x13c15(0x26f)]||_0x13c15(0x284))+')');}finally{await _0x46ab39['close']();}}function _0x30fb7a(_0x192b94,_0x17d41b){const _0xc42afb=_0x178958;if(!_0x192b94[_0xc42afb(0x2e0)])return _0xc42afb(0x1ec);const _0x5e53ac=_0x192b94[_0xc42afb(0x11a)];if(!_0x5e53ac)return _0xc42afb(0x1ce);if(_0x17d41b>_0x5e53ac)return'expired';return _0xc42afb(0x1ce);}function _0x3af915(_0x544287){const _0x178311=_0x178958;if(!_0x544287||typeof _0x544287!==_0x178311(0x347))return'';const _0x28fdb9=Object[_0x178311(0x27c)](_0x544287)[_0x178311(0x234)](([,_0x2ab8f7])=>_0x2ab8f7)[_0x178311(0x282)](([_0x1604e5])=>_0x1604e5);if(_0x28fdb9[_0x178311(0x1b0)]===0x0)return _0x178311(0x13f);if(_0x28fdb9['length']<=0x3)return _0x28fdb9['join']('\x20');return _0x28fdb9[_0x178311(0x341)](0x0,0x3)[_0x178311(0x161)]('\x20')+('\x20+'+(_0x28fdb9[_0x178311(0x1b0)]-0x3));}async function _0x340528(_0x88f514){const _0x3251fa=_0x178958,_0x1d39ca=require$$5,_0x389cdc=requireOkdbLicenseCodec(),{_C:_0x422ce4}=requireOkdbLicense(),_0x4fccf1=_0x4e5a5b['resolve'](_0x88f514[_0x3251fa(0x36d)]),_0x4514cb=new _0x1d39ca(_0x4fccf1,_0x88f514[_0x3251fa(0x15b)]?{'encryptionKey':_0x88f514[_0x3251fa(0x15b)]}:{});await _0x4514cb[_0x3251fa(0x2f9)]();try{const _0x187337=_0x4514cb[_0x3251fa(0x122)],_0x351590=_0x187337?.['db']?.['get']?.(_0x3251fa(0x19c))??0x0,_0x58a50d=[..._0x4514cb[_0x3251fa(0xf9)][_0x3251fa(0x116)]()][_0x3251fa(0x234)](_0x1476ae=>!_0x1476ae[_0x3251fa(0x1ef)]('~'))[_0x3251fa(0x1b0)],_0x20c263=_0x4514cb['_license']?.[_0x3251fa(0x1e5)];if(_0x20c263){const _0x139592=_0x20c263['_isFree']===!![],_0x3a9412=_0x139592?_0x3251fa(0xd5):_0x4514cb[_0x3251fa(0x268)][_0x3251fa(0x1ce)]?.[_0x3251fa(0x288)]||_0x3251fa(0x14f);console[_0x3251fa(0xdd)](''),console[_0x3251fa(0xdd)](_0x3251fa(0x24d)+_0x3a9412);const _0x17370c=_0x20c263[_0x3251fa(0x214)]||{};if(_0x17370c['maxWrites']){const _0x4914fd=Math[_0x3251fa(0x28e)](_0x351590/_0x17370c[_0x3251fa(0x322)]*0x64);console[_0x3251fa(0xdd)](_0x3251fa(0x34f)+_0x351590[_0x3251fa(0x31f)]()+_0x3251fa(0x23e)+_0x17370c[_0x3251fa(0x322)]['toLocaleString']()+_0x3251fa(0x163)+_0x4914fd+'%)');}else console[_0x3251fa(0xdd)](_0x3251fa(0x34f)+_0x351590[_0x3251fa(0x31f)]());_0x17370c['envs']?console[_0x3251fa(0xdd)](_0x3251fa(0x150)+_0x58a50d+_0x3251fa(0x23e)+_0x17370c[_0x3251fa(0x355)]):console[_0x3251fa(0xdd)]('\x20\x20Envs:\x20\x20\x20\x20'+_0x58a50d),_0x422ce4?.['PUB_FINGERPRINT']&&console[_0x3251fa(0xdd)](_0x3251fa(0x245)+_0x422ce4[_0x3251fa(0x130)]+_0x3251fa(0x8f));}if(!_0x187337||!_0x187337[_0x3251fa(0xa2)]('~licenses')){console['log'](''),console[_0x3251fa(0xdd)](_0x3251fa(0xcd)),console[_0x3251fa(0xdd)]('');return;}const _0x29c76b=[],_0x200d87=Date['now'](),_0x248816=_0x4514cb['id'],_0x3fd0cf='__OKDB_PUB_FINGERPRINT__';for(const {key:_0x1696a1,value:_0x4d0eee}of _0x187337['getRange']('~licenses')){const _0x2cec37=_0x4d0eee[_0x3251fa(0x1a8)]?Buffer[_0x3251fa(0xb5)](_0x4d0eee[_0x3251fa(0x1a8)],_0x3251fa(0x360)):Buffer['alloc'](0x8);let _0x2970f7='';try{_0x2970f7=_0x389cdc[_0x3251fa(0x2fa)](_0x248816,_0x2cec37,_0x3fd0cf)[_0x3251fa(0x248)];}catch{}_0x29c76b[_0x3251fa(0x231)]({'id':_0x1696a1,'licensee':_0x4d0eee['licensee']||'','expires':_0x4d0eee[_0x3251fa(0x11a)]?new Date(_0x4d0eee[_0x3251fa(0x11a)])[_0x3251fa(0xc0)]()['slice'](0x0,0xa):'','features':_0x3af915(_0x4d0eee[_0x3251fa(0x37d)]),'pin':_0x2970f7,'status':_0x30fb7a(_0x4d0eee,_0x200d87)});}if(_0x29c76b['length']===0x0){console['log'](''),console['log']('\x20\x20No\x20licenses\x20stored.\x20Use\x20`okdb\x20license\x20<blob>`\x20to\x20add\x20one.'),console[_0x3251fa(0xdd)]('');return;}const _0x41fd04=['\x20\x20'+'ID'[_0x3251fa(0x20b)](0xe),'LICENSEE'[_0x3251fa(0x20b)](0xe),_0x3251fa(0x133)['padEnd'](0xc),'FEATURES'[_0x3251fa(0x20b)](0x1e),'PIN'[_0x3251fa(0x20b)](0xa),_0x3251fa(0xdb)][_0x3251fa(0x161)]('\x20');console[_0x3251fa(0xdd)]('\x0a'+_0x41fd04);for(const _0x11b6b5 of _0x29c76b){const _0x2b746b=_0x11b6b5['id'][_0x3251fa(0x341)](0x0,0x8)+'…';console[_0x3251fa(0xdd)](['\x20\x20'+_0x2b746b[_0x3251fa(0x20b)](0xe),_0x11b6b5[_0x3251fa(0x288)][_0x3251fa(0x341)](0x0,0xe)[_0x3251fa(0x20b)](0xe),_0x11b6b5['expires'][_0x3251fa(0x20b)](0xc),_0x11b6b5[_0x3251fa(0x37d)]['slice'](0x0,0x1e)[_0x3251fa(0x20b)](0x1e),_0x11b6b5[_0x3251fa(0x248)][_0x3251fa(0x20b)](0xa),_0x11b6b5[_0x3251fa(0x317)]]['join']('\x20'));}console[_0x3251fa(0xdd)]('');}finally{await _0x4514cb[_0x3251fa(0x2a5)]();}}async function _0x3a4f0c(_0x1d45c8,_0xfdca06){const _0x200497=_0x178958,_0x4207b2=require$$5,_0x377dc0=requireOkdbLicenseCodec();let _0x2537f2=_0x1d45c8;(_0x377dc0['detectInputType'](_0x1d45c8)===_0x200497(0x348)||_0x31ec50['existsSync'](_0x1d45c8)&&_0x31ec50[_0x200497(0x30c)](_0x1d45c8)[_0x200497(0x9b)]())&&(_0x2537f2=_0x31ec50[_0x200497(0x146)](_0x1d45c8,_0x200497(0x30f))[_0x200497(0x15e)]());const _0x49f362=_0x4e5a5b[_0x200497(0x235)](_0xfdca06[_0x200497(0x36d)]),_0x328d86=new _0x4207b2(_0x49f362,_0xfdca06[_0x200497(0x15b)]?{'encryptionKey':_0xfdca06[_0x200497(0x15b)]}:{});await _0x328d86[_0x200497(0x2f9)]();try{!_0x328d86['_license']&&(console[_0x200497(0x266)](_0x200497(0x86)),process['exit'](0x1));let _0x54db30;try{_0x54db30=await _0x328d86[_0x200497(0x268)][_0x200497(0x299)](_0x2537f2);}catch(_0xab2cc6){console[_0x200497(0x266)](_0x200497(0x1f0)+_0xab2cc6[_0x200497(0x307)]),process[_0x200497(0x15d)](0x1);}const _0x5d57a5=_0x328d86[_0x200497(0x268)][_0x200497(0x25a)](),_0x405c93=_0x5d57a5[_0x200497(0x17a)](_0x2766f8=>_0x2766f8[_0x200497(0xb3)]===_0x54db30['id'])?.['pin']||'',_0x35761c=Object['entries'](_0x54db30['features']||{})['filter'](([,_0x4bde10])=>_0x4bde10)[_0x200497(0x282)](([_0x9078ef])=>_0x9078ef),_0x34d300=_0x54db30['limits']||{},_0x588876=[_0x34d300[_0x200497(0x355)]?_0x200497(0x298)+_0x34d300['envs']:null,_0x34d300[_0x200497(0x2af)]?_0x200497(0x16c)+_0x34d300['typesPerEnv']:null,_0x34d300['syncPeers']?_0x200497(0x368)+_0x34d300[_0x200497(0x2e2)]:null,_0x34d300[_0x200497(0x322)]?'writes='+_0x34d300[_0x200497(0x322)][_0x200497(0x31f)]():null]['filter'](Boolean)[_0x200497(0x161)]('\x20\x20'),_0x65036d=_0x54db30['licenseType']===_0x377dc0[_0x200497(0x2b8)];console[_0x200497(0xdd)](_0x200497(0x300)),console[_0x200497(0xdd)](_0x200497(0x1cb)+_0x54db30['id']),console[_0x200497(0xdd)](_0x200497(0x2b9)+_0x54db30[_0x200497(0x288)]),console[_0x200497(0xdd)]('\x20\x20\x20\x20expires:\x20\x20\x20'+new Date(_0x54db30[_0x200497(0x11a)])[_0x200497(0xc0)]()[_0x200497(0x341)](0x0,0xa)),console['log'](_0x200497(0x104)+(_0x35761c[_0x200497(0x161)](',\x20')||'(none)'));if(_0x588876)console[_0x200497(0xdd)](_0x200497(0x89)+_0x588876);_0x65036d?(console[_0x200497(0xdd)]('\x20\x20\x20\x20status:\x20\x20\x20\x20active\x20\x20(open\x20license\x20—\x20no\x20activation\x20needed)'),console[_0x200497(0xdd)]('')):(console['log'](_0x200497(0x2f8)+_0x405c93),console[_0x200497(0xdd)]('\x20\x20\x20\x20status:\x20\x20\x20\x20pending\x20activation'),console[_0x200497(0xdd)](''),console[_0x200497(0xdd)](_0x200497(0xbc)),console[_0x200497(0xdd)](_0x200497(0xac)+_0x405c93+')\x20to\x20your\x20license\x20vendor.'),console[_0x200497(0xdd)]('\x20\x20\x20\x202.\x20The\x20vendor\x20returns\x20an\x20activation\x20token.'),console['log']('\x20\x20\x20\x203.\x20Run:\x20\x20okdb\x20license\x20<activation-token>'),console[_0x200497(0xdd)](''));}finally{await _0x328d86['close']();}}async function _0x310d55(_0x1f6ef1,_0x11cf41){const _0x1819a3=_0x178958,_0x459501=require$$5,_0x19e693=_0x4e5a5b[_0x1819a3(0x235)](_0x11cf41['dbPath']),_0xf78192=new _0x459501(_0x19e693,_0x11cf41[_0x1819a3(0x15b)]?{'encryptionKey':_0x11cf41[_0x1819a3(0x15b)]}:{});await _0xf78192[_0x1819a3(0x2f9)]();try{!_0xf78192[_0x1819a3(0x268)]&&(console[_0x1819a3(0x266)]('[okdb]\x20error:\x20license\x20management\x20is\x20only\x20available\x20in\x20licensed\x20builds\x20(npm\x20run\x20build:prod).'),process[_0x1819a3(0x15d)](0x1));let _0x37830f;try{_0x37830f=await _0xf78192[_0x1819a3(0x268)][_0x1819a3(0x21c)](_0x1f6ef1[_0x1819a3(0x15e)]());}catch(_0x1ccd39){console['error'](_0x1819a3(0x1f0)+_0x1ccd39[_0x1819a3(0x307)]),console[_0x1819a3(0x266)](''),console[_0x1819a3(0x266)](_0x1819a3(0x388)),console[_0x1819a3(0x266)]('\x20\x20\x20\x20-\x20The\x20license\x20blob\x20has\x20not\x20been\x20added\x20yet\x20—\x20run\x20`okdb\x20license\x20<blob>`\x20first.'),console[_0x1819a3(0x266)]('\x20\x20\x20\x20-\x20The\x20activation\x20token\x20was\x20issued\x20for\x20a\x20different\x20node\x20—\x20share\x20this\x20node\x27s\x20PIN\x20with\x20the\x20vendor.'),console[_0x1819a3(0x266)](_0x1819a3(0x2c4)),console['error'](''),process[_0x1819a3(0x15d)](0x1);}console['log'](_0x1819a3(0x184)),console['log'](_0x1819a3(0x1cb)+_0x37830f['id']),console[_0x1819a3(0xdd)](_0x1819a3(0x2b9)+_0x37830f[_0x1819a3(0x288)]),console[_0x1819a3(0xdd)](_0x1819a3(0xba)+new Date(_0x37830f['expiresAt'])[_0x1819a3(0xc0)]()[_0x1819a3(0x341)](0x0,0xa)),console[_0x1819a3(0xdd)](_0x1819a3(0x304)),console[_0x1819a3(0xdd)]('');}finally{await _0xf78192[_0x1819a3(0x2a5)]();}}async function _0x334955(_0x10a89d,_0x371b40){const _0x4f3a4f=_0x178958;!_0x10a89d&&(console[_0x4f3a4f(0x266)](_0x4f3a4f(0x1ee)),process[_0x4f3a4f(0x15d)](0x1));const _0xa1325a=require$$5,_0x4aa033=requireOkdbLicenseCodec(),_0x31a923=_0x4e5a5b['resolve'](_0x371b40[_0x4f3a4f(0x36d)]),_0x5cb61c=new _0xa1325a(_0x31a923,_0x371b40['key']?{'encryptionKey':_0x371b40[_0x4f3a4f(0x15b)]}:{});await _0x5cb61c['open']();try{const _0x1c5bc6=_0x5cb61c['_systemEnv'];(!_0x1c5bc6||!_0x1c5bc6[_0x4f3a4f(0xa2)](_0x4f3a4f(0x202)))&&(console[_0x4f3a4f(0x266)](_0x4f3a4f(0x240)+_0x10a89d+'\x22'),process[_0x4f3a4f(0x15d)](0x1));let _0x5a52ed=null,_0x1dab95=null;const _0xceba3f=_0x1c5bc6[_0x4f3a4f(0x187)](_0x4f3a4f(0x202),_0x10a89d);if(_0xceba3f)_0x5a52ed=_0x10a89d,_0x1dab95=_0xceba3f;else{const _0x56bb00=[];for(const {key:_0x4f8fc5,value:_0x33b495}of _0x1c5bc6[_0x4f3a4f(0x2c6)]('~licenses')){if(_0x4f8fc5['startsWith'](_0x10a89d))_0x56bb00[_0x4f3a4f(0x231)]({'key':_0x4f8fc5,'value':_0x33b495});}_0x56bb00[_0x4f3a4f(0x1b0)]===0x0&&(console['error'](_0x4f3a4f(0x240)+_0x10a89d+'\x22'),process['exit'](0x1)),_0x56bb00[_0x4f3a4f(0x1b0)]>0x1&&(console[_0x4f3a4f(0x266)](_0x4f3a4f(0xf7)+_0x10a89d+_0x4f3a4f(0x1be)+_0x56bb00[_0x4f3a4f(0x1b0)]+_0x4f3a4f(0x195)),process[_0x4f3a4f(0x15d)](0x1)),_0x5a52ed=_0x56bb00[0x0][_0x4f3a4f(0x15b)],_0x1dab95=_0x56bb00[0x0][_0x4f3a4f(0x1d2)];}const _0x3865da=Date[_0x4f3a4f(0x149)](),_0x29aac8=_0x30fb7a(_0x1dab95,_0x3865da),_0x584f21=_0x5cb61c['id'],_0x428c4c='__OKDB_PUB_FINGERPRINT__';let _0x22f24f='';try{const _0xecd900=Buffer[_0x4f3a4f(0xb5)](_0x1dab95[_0x4f3a4f(0x1a8)],_0x4f3a4f(0x360));_0x22f24f=_0x4aa033['derivePin'](_0x584f21,_0xecd900,_0x428c4c)[_0x4f3a4f(0x248)];}catch{}const _0x557ecb=_0x1dab95[_0x4f3a4f(0x37d)]?Object[_0x4f3a4f(0x27c)](_0x1dab95[_0x4f3a4f(0x37d)])[_0x4f3a4f(0x234)](([,_0x3b875e])=>_0x3b875e)[_0x4f3a4f(0x282)](([_0x10c0cf])=>_0x10c0cf):[],_0x3623e9=_0x1dab95[_0x4f3a4f(0x214)]||{},_0x25c786=_0x1c5bc6?.['db']?.[_0x4f3a4f(0x187)]?.(_0x4f3a4f(0x19c))??0x0,_0x57e4f8=[..._0x5cb61c[_0x4f3a4f(0xf9)][_0x4f3a4f(0x116)]()][_0x4f3a4f(0x234)](_0x3dfa6f=>!_0x3dfa6f[_0x4f3a4f(0x1ef)]('~'))[_0x4f3a4f(0x1b0)];console[_0x4f3a4f(0xdd)](_0x4f3a4f(0x2bb)),console[_0x4f3a4f(0xdd)](_0x4f3a4f(0x1cb)+_0x5a52ed),console[_0x4f3a4f(0xdd)](_0x4f3a4f(0x2b9)+(_0x1dab95[_0x4f3a4f(0x288)]||'')),console[_0x4f3a4f(0xdd)](_0x4f3a4f(0xba)+(_0x1dab95[_0x4f3a4f(0x11a)]?new Date(_0x1dab95['expiresAt'])[_0x4f3a4f(0xc0)]()[_0x4f3a4f(0x341)](0x0,0xa):'')),console[_0x4f3a4f(0xdd)](_0x4f3a4f(0x104)+(_0x557ecb['join'](',\x20')||_0x4f3a4f(0x13f))),console['log']('\x20\x20\x20\x20pin:\x20\x20\x20\x20\x20\x20\x20'+_0x22f24f),console[_0x4f3a4f(0xdd)](_0x4f3a4f(0x19d)+_0x29aac8),console[_0x4f3a4f(0xdd)](_0x4f3a4f(0xe6)+new Date(_0x1dab95[_0x4f3a4f(0xd2)])[_0x4f3a4f(0xc0)]());if(_0x29aac8==='active'){console[_0x4f3a4f(0xdd)](''),console[_0x4f3a4f(0xdd)](_0x4f3a4f(0x2e5));if(_0x3623e9[_0x4f3a4f(0x322)]){const _0x68ebb9=Math['round'](_0x25c786/_0x3623e9['maxWrites']*0x64);console[_0x4f3a4f(0xdd)](_0x4f3a4f(0xa1)+_0x25c786[_0x4f3a4f(0x31f)]()+_0x4f3a4f(0x23e)+_0x3623e9[_0x4f3a4f(0x322)][_0x4f3a4f(0x31f)]()+'\x20\x20('+_0x68ebb9+'%)');}else console[_0x4f3a4f(0xdd)](_0x4f3a4f(0xa1)+_0x25c786[_0x4f3a4f(0x31f)]()+'\x20\x20(unlimited)');_0x3623e9['envs']?console[_0x4f3a4f(0xdd)](_0x4f3a4f(0x1fa)+_0x57e4f8+_0x4f3a4f(0x23e)+_0x3623e9[_0x4f3a4f(0x355)]):console[_0x4f3a4f(0xdd)](_0x4f3a4f(0x1fa)+_0x57e4f8+_0x4f3a4f(0x2d3));}console[_0x4f3a4f(0xdd)]('');}finally{await _0x5cb61c[_0x4f3a4f(0x2a5)]();}}async function _0x3bae57(_0x365c70,_0x32916a){const _0x38fe92=_0x178958;!_0x365c70&&(console['error'](_0x38fe92(0x365)),process[_0x38fe92(0x15d)](0x1));const _0x1b43dc=require$$5,_0x2686a1=_0x4e5a5b[_0x38fe92(0x235)](_0x32916a[_0x38fe92(0x36d)]),_0x53aa78=new _0x1b43dc(_0x2686a1,_0x32916a[_0x38fe92(0x15b)]?{'encryptionKey':_0x32916a['key']}:{});await _0x53aa78[_0x38fe92(0x2f9)]();try{const _0x692452=_0x53aa78[_0x38fe92(0x122)];(!_0x692452||!_0x692452[_0x38fe92(0xa2)](_0x38fe92(0x202)))&&(console['error']('[okdb]\x20error:\x20no\x20license\x20with\x20id\x20\x22'+_0x365c70+'\x22'),process[_0x38fe92(0x15d)](0x1));let _0x19b5df=null,_0x1b9efe=null;const _0x443460=_0x692452['get'](_0x38fe92(0x202),_0x365c70);if(_0x443460)_0x19b5df=_0x365c70,_0x1b9efe=_0x443460;else{const _0x1b2403=[];for(const {key:_0x824a24,value:_0x18252d}of _0x692452[_0x38fe92(0x2c6)](_0x38fe92(0x202))){if(_0x824a24['startsWith'](_0x365c70))_0x1b2403['push']({'key':_0x824a24,'value':_0x18252d});}_0x1b2403[_0x38fe92(0x1b0)]===0x0&&(console[_0x38fe92(0x266)](_0x38fe92(0x240)+_0x365c70+'\x22'),process['exit'](0x1)),_0x1b2403[_0x38fe92(0x1b0)]>0x1&&(console[_0x38fe92(0x266)](_0x38fe92(0xf7)+_0x365c70+_0x38fe92(0x1be)+_0x1b2403[_0x38fe92(0x1b0)]+_0x38fe92(0x195)),process['exit'](0x1)),_0x19b5df=_0x1b2403[0x0][_0x38fe92(0x15b)],_0x1b9efe=_0x1b2403[0x0][_0x38fe92(0x1d2)];}await _0x692452[_0x38fe92(0x153)]('~licenses',_0x19b5df),console[_0x38fe92(0xdd)](_0x38fe92(0x250)+_0x19b5df+_0x38fe92(0x22f)+(_0x1b9efe[_0x38fe92(0x288)]||_0x38fe92(0x284))+')');}finally{await _0x53aa78['close']();}}async function _0x2e83df(_0x21cc33,_0x57454c,_0x1e9ed7){const _0x30d96f=_0x178958;!_0x21cc33&&(console[_0x30d96f(0x266)]('[okdb]\x20error:\x20join\x20requires\x20a\x20remote\x20address.\x20Usage:\x20okdb\x20join\x20<address>\x20--token\x20<t>'),process[_0x30d96f(0x15d)](0x1));!_0x1e9ed7[_0x30d96f(0x237)]&&!(_0x1e9ed7[_0x30d96f(0x1c2)]&&_0x1e9ed7[_0x30d96f(0x26e)])&&(console[_0x30d96f(0x266)](_0x30d96f(0x356)),process[_0x30d96f(0x15d)](0x1));const _0x3b2bc3=_0x1e9ed7['selfAddress']||_0x57454c[_0x30d96f(0x36a)]?.[_0x30d96f(0x1cd)];!_0x3b2bc3&&(console['error'](_0x30d96f(0xe8)+_0x30d96f(0x97)+_0x30d96f(0x301)),process['exit'](0x1));const _0x5b216c=require$$5,_0x8e3065=new _0x5b216c(_0x57454c[_0x30d96f(0x36d)],{'sync':{'address':_0x3b2bc3,'auto_reconcile':![]}});await _0x8e3065[_0x30d96f(0x2f9)]();try{const _0x52ebaf=_0x8e3065[_0x30d96f(0x122)];if(_0x52ebaf&&_0x52ebaf[_0x30d96f(0xa2)]('~tokens')){let _0x41afbf=![];for(const _0x1237bb of _0x52ebaf['getRange']('~tokens')){_0x41afbf=!![];break;}_0x41afbf&&console[_0x30d96f(0xdd)](_0x30d96f(0x29f)+_0x30d96f(0x31b));}console[_0x30d96f(0xdd)](_0x30d96f(0x10b)+_0x21cc33+'…'),await _0x8e3065[_0x30d96f(0x36a)][_0x30d96f(0x161)](_0x21cc33[_0x30d96f(0x156)](/\/+$/,''),{'token':_0x1e9ed7[_0x30d96f(0x237)],'username':_0x1e9ed7['username'],'password':_0x1e9ed7[_0x30d96f(0x26e)]}),console[_0x30d96f(0xdd)](_0x30d96f(0x344)),console[_0x30d96f(0xdd)](_0x30d96f(0x2a0));}finally{await _0x8e3065[_0x30d96f(0x2a5)]();}}async function _0x2b37cf(){const _0x11ad31=_0x178958,_0x4c8833=Date[_0x11ad31(0x149)](),_0x58301e=_0x15c3e1(process[_0x11ad31(0x2e4)]),_0x50e1fa=_0x4d61dd(_0x58301e),_0xb16085=_0x4e5a5b[_0x11ad31(0x235)](_0x50e1fa[_0x11ad31(0x36d)]);!_0x50e1fa['noRepl']&&!process[_0x11ad31(0x274)]['isTTY']&&(_0x50e1fa[_0x11ad31(0x27a)]=!![]);const _0xbbaed9=require$$5,{start:_0x25d893,colorLog:_0x40ebfb}=requireOkdbShell(),_0xf4b52c={..._0x50e1fa[_0x11ad31(0x15b)]?{'encryptionKey':_0x50e1fa['key']}:{},..._0x50e1fa['noAdmin']?{'admin':![]}:_0x4297a1(_0x50e1fa[_0x11ad31(0x1f2)])?{'admin':_0x50e1fa[_0x11ad31(0x1f2)]}:{},..._0x4297a1(_0x50e1fa[_0x11ad31(0xdc)])?{'api':_0x50e1fa[_0x11ad31(0xdc)]}:{},..._0x4297a1(_0x50e1fa[_0x11ad31(0x2a1)])?{'auth':_0x50e1fa['auth']}:{},..._0x4297a1(_0x50e1fa[_0x11ad31(0x2e8)])?{'mcp':_0x50e1fa['mcp']}:{},..._0x50e1fa[_0x11ad31(0x32e)]!==![]?{'timeMachine':_0x50e1fa['timeMachine']}:{}},_0x24002f=new _0xbbaed9(_0xb16085,_0xf4b52c);_0x24002f[_0x11ad31(0xdd)][_0x11ad31(0x363)]?.();const _0x57a03d=_0x24002f[_0x11ad31(0xdd)][_0x11ad31(0x2d0)](_0x2a7bc8=>_0x40ebfb(_0x2a7bc8,_0x50e1fa['logLevel']));if(_0x50e1fa['noRepl'])process['stdout'][_0x11ad31(0xef)]('[okdb]\x20starting…\x0a');await _0x24002f[_0x11ad31(0x2f9)]();if(_0x50e1fa[_0x11ad31(0x27a)])process['stdout'][_0x11ad31(0xef)](_0x11ad31(0xd1));try{await _0x38fa7e(_0x24002f,_0x50e1fa['port']);}catch(_0x376f55){_0x376f55[_0x11ad31(0x309)]==='EADDRINUSE'&&(console['error'](_0x11ad31(0x1df)+_0x50e1fa[_0x11ad31(0x1e9)]+_0x11ad31(0x1c1)),process['exit'](0x1));throw _0x376f55;}if(_0x50e1fa[_0x11ad31(0x27a)])process['stdout'][_0x11ad31(0xef)](_0x11ad31(0xca)+_0x50e1fa[_0x11ad31(0x1e9)]+'\x0a');if(!_0x50e1fa[_0x11ad31(0x27a)])_0x24002f[_0x11ad31(0xdd)][_0x11ad31(0x363)]?.(),_0x57a03d?.(),_0x1297e8(_0x24002f[_0x11ad31(0x2a1)]?.[_0x11ad31(0x12e)]?.()??[]),await _0x25d893(_0x24002f,_0x50e1fa);else{const _0x4f506e=_0x4e5a5b['join'](_0xb16085,_0x11ad31(0xb9));try{_0x31ec50[_0x11ad31(0x359)](_0x4f506e,String(process['pid']));}catch{}const _0x523158=Date['now']()-_0x4c8833;console['log'](''),console[_0x11ad31(0xdd)](_0x11ad31(0x2b5)),console[_0x11ad31(0xdd)](_0x11ad31(0x321)+_0x50e1fa[_0x11ad31(0x1e9)]),console[_0x11ad31(0xdd)](_0x11ad31(0x1e8)+_0xb16085),console[_0x11ad31(0xdd)]('\x20\x20\x20\x20id:\x20\x20\x20\x20'+_0x24002f['id']);{const _0x2a0ba5=_0x24002f['_systemEnv']?.['db']?.['get']?.(_0x11ad31(0x19c))??0x0,_0x1c6ddd=[..._0x24002f[_0x11ad31(0xf9)]['keys']()][_0x11ad31(0x234)](_0xf8f92=>!_0xf8f92[_0x11ad31(0x1ef)]('~'))[_0x11ad31(0x1b0)];if(_0x24002f['_license']?.[_0x11ad31(0x1ce)]?.[_0x11ad31(0x154)]===0x1){const _0x2e1043=Math[_0x11ad31(0x36e)]((_0x24002f[_0x11ad31(0x268)]['active'][_0x11ad31(0x11a)]-Date[_0x11ad31(0x149)]())/0x5265c00);console[_0x11ad31(0xdd)](_0x11ad31(0x96)+_0x24002f[_0x11ad31(0x268)]['active'][_0x11ad31(0x288)]+_0x11ad31(0x1d5)+_0x2e1043+_0x11ad31(0x392));}else{if(_0x24002f[_0x11ad31(0x268)]?.[_0x11ad31(0x1ce)]){const _0x492c76=_0x24002f[_0x11ad31(0x268)]['active'];console['log'](_0x11ad31(0x2c0)+_0x492c76[_0x11ad31(0x288)]+'\x20(expires\x20'+new Date(_0x492c76[_0x11ad31(0x11a)])[_0x11ad31(0xc0)]()['slice'](0x0,0xa)+')');const _0x11436b=_0x492c76[_0x11ad31(0x214)]||{};if(_0x11436b[_0x11ad31(0x322)]){const _0x26f3bf=Math['round'](_0x2a0ba5/_0x11436b[_0x11ad31(0x322)]*0x64);console['log'](_0x11ad31(0xc9)+_0x2a0ba5[_0x11ad31(0x31f)]()+'\x20/\x20'+_0x11436b['maxWrites']['toLocaleString']()+_0x11ad31(0x204)+_0x26f3bf+'%),\x20'+_0x1c6ddd+(_0x11436b[_0x11ad31(0x355)]?'/'+_0x11436b[_0x11ad31(0x355)]:'')+_0x11ad31(0x87)+(_0x1c6ddd===0x1?'':'s'));}}else{if(_0x24002f['_license']){const _0x5a6fac=_0x24002f[_0x11ad31(0x268)][_0x11ad31(0x25a)](),_0x1d316b=_0x5a6fac[_0x11ad31(0x1b0)]?_0x5a6fac[_0x11ad31(0x282)](_0x582910=>_0x582910[_0x11ad31(0x248)])[_0x11ad31(0x161)](',\x20'):_0x11ad31(0x1fe),_0x247f62=_0x24002f[_0x11ad31(0x268)][_0x11ad31(0x1e5)],_0xaf2013=_0x247f62['limits'][_0x11ad31(0x322)]?Math['round'](_0x2a0ba5/_0x247f62['limits'][_0x11ad31(0x322)]*0x64):0x0;console['log']('\x20\x20\x20\x20license:\x20free\x20tier\x20—\x20add\x20a\x20license\x20to\x20unlock\x20sync,\x20embeddings,\x20engines,\x20time-machine'),console['log'](_0x11ad31(0xc9)+_0x2a0ba5[_0x11ad31(0x31f)]()+_0x11ad31(0x23e)+_0x247f62[_0x11ad31(0x214)]['maxWrites'][_0x11ad31(0x31f)]()+_0x11ad31(0x204)+_0xaf2013+_0x11ad31(0x1a7)+_0x1c6ddd+_0x11ad31(0x23e)+_0x247f62[_0x11ad31(0x214)][_0x11ad31(0x355)]+_0x11ad31(0x34b)),console[_0x11ad31(0xdd)](_0x11ad31(0x241)+_0x1d316b);}}}}console[_0x11ad31(0xdd)](_0x11ad31(0x327)+_0x50e1fa[_0x11ad31(0x1e9)]+_0x11ad31(0x32c));!_0x50e1fa[_0x11ad31(0x1ac)]&&console[_0x11ad31(0xdd)](_0x11ad31(0x334)+_0x50e1fa[_0x11ad31(0x1e9)]+_0x11ad31(0x2fc));console[_0x11ad31(0xdd)](''),console[_0x11ad31(0xdd)](_0x11ad31(0x110)+_0x523158+'ms'),_0x1297e8(_0x24002f[_0x11ad31(0x2a1)]?.[_0x11ad31(0x12e)]?.()??[]);async function _0x5dc956(){const _0x437e33=_0x11ad31;process['stdout'][_0x437e33(0xef)](_0x437e33(0x196));try{_0x31ec50[_0x437e33(0x205)](_0x4f506e);}catch{}await _0x24002f[_0x437e33(0x2a5)](),process[_0x437e33(0x15d)](0x0);}process['on'](_0x11ad31(0x342),_0x5dc956),process['on'](_0x11ad31(0x1bc),_0x5dc956);}}const _0x3398cb=new Set([_0x178958(0x109),_0x178958(0x238),'init',_0x178958(0x95),'export',_0x178958(0x35d),_0x178958(0x19a),_0x178958(0x237),_0x178958(0x161),_0x178958(0x22a)]),_0x78651f=process[_0x178958(0x2e4)][0x2];if(_0x78651f==='version')console[_0x178958(0xdd)](require$$2[_0x178958(0x109)]),process[_0x178958(0x15d)](0x0);else{if(_0x78651f&&_0x3398cb['has'](_0x78651f)){const _0x23d2bd=process['argv'][_0x178958(0x341)](0x3),_0x2eeead=_0x15c3e1([_0x178958(0x147),_0x178958(0x28a),..._0x23d2bd]),_0x50abdd=_0x4d61dd(_0x2eeead),_0x4b1b28=new Set([_0x178958(0x390),'-d',_0x178958(0x31a),'-k',_0x178958(0x105),'-c',_0x178958(0xb2),'-p',_0x178958(0x305),_0x178958(0x172),'-e',_0x178958(0xeb),_0x178958(0x1c7),'--password',_0x178958(0x2ec),_0x178958(0x8d),_0x178958(0x171),_0x178958(0x370),_0x178958(0x1d0),_0x178958(0xa6),'-u',_0x178958(0x185)]);let _0x4d57c6=null;for(let _0x1395d2=0x0;_0x1395d2<_0x23d2bd[_0x178958(0x1b0)];_0x1395d2++){if(_0x4b1b28[_0x178958(0x158)](_0x23d2bd[_0x1395d2])){_0x1395d2++;continue;}if(!_0x23d2bd[_0x1395d2][_0x178958(0x1ef)]('-')){_0x4d57c6=_0x23d2bd[_0x1395d2];break;}}(async()=>{const _0x377ea8=_0x178958;if(_0x78651f===_0x377ea8(0x237)){const _0x40ca55=process[_0x377ea8(0x2e4)][0x3],_0x3ed08e=process[_0x377ea8(0x2e4)][_0x377ea8(0x341)](0x4),_0x37ca97=_0x15c3e1(['node','okdb',..._0x3ed08e]),_0xbe166b=_0x4d61dd(_0x37ca97),_0x350ab6=new Set([_0x377ea8(0x390),'-d',_0x377ea8(0x31a),'-k',_0x377ea8(0x105),'-c',_0x377ea8(0xb2),'-p','--name',_0x377ea8(0x106),_0x377ea8(0x2ec),_0x377ea8(0x8d),'--grants','--ttl','--log-level',_0x377ea8(0x172),'-e',_0x377ea8(0xeb)]),_0x4ccde6=[];for(let _0x1f8dc4=0x0;_0x1f8dc4<_0x3ed08e['length'];_0x1f8dc4++){if(_0x350ab6['has'](_0x3ed08e[_0x1f8dc4])){_0x1f8dc4++;continue;}if(_0x3ed08e[_0x1f8dc4][_0x377ea8(0x1ef)]('-'))continue;_0x4ccde6[_0x377ea8(0x231)](_0x3ed08e[_0x1f8dc4]);}switch(_0x40ca55){case _0x377ea8(0x1a5):await _0x19981c(_0xbe166b,_0x37ca97);break;case'list':await _0x54d243(_0xbe166b);break;case'revoke':await _0x58a0e2(_0x4ccde6[0x0],_0xbe166b);break;default:console['error'](_0x377ea8(0x1a9)+_0x40ca55+_0x377ea8(0xf8)),process['exit'](0x1);}return;}if(_0x78651f==='license'){const _0x17b963=requireOkdbLicenseCodec(),_0x4c8805=process[_0x377ea8(0x2e4)][_0x377ea8(0x341)](0x3),_0x3737a9=_0x15c3e1([_0x377ea8(0x147),_0x377ea8(0x28a),..._0x4c8805]),_0x4beab3=_0x4d61dd(_0x3737a9),_0x5322e2=new Set([_0x377ea8(0x390),'-d',_0x377ea8(0x31a),'-k','--config','-c','--port','-p',_0x377ea8(0x305)]),_0x13b980=[];for(let _0x14df7f=0x0;_0x14df7f<_0x4c8805[_0x377ea8(0x1b0)];_0x14df7f++){if(_0x5322e2[_0x377ea8(0x158)](_0x4c8805[_0x14df7f])){_0x14df7f++;continue;}if(_0x4c8805[_0x14df7f][_0x377ea8(0x1ef)]('-'))continue;_0x13b980[_0x377ea8(0x231)](_0x4c8805[_0x14df7f]);}const _0xf9a6a1=_0x13b980[0x0]??null;if(_0xf9a6a1===_0x377ea8(0x153))await _0x3bae57(_0x13b980[0x1],_0x4beab3);else{if(!_0xf9a6a1)await _0x340528(_0x4beab3);else{let _0x47268a=_0x17b963[_0x377ea8(0x1b4)](_0xf9a6a1);if(_0x47268a===_0x377ea8(0x32b)&&_0x31ec50[_0x377ea8(0x36f)](_0xf9a6a1))_0x47268a=_0x377ea8(0x348);if(_0x47268a==='path')try{const _0xe1bbd5=_0x31ec50[_0x377ea8(0x146)](_0xf9a6a1,'utf8')['trim'](),_0x363904=_0x17b963['detectInputType'](_0xe1bbd5);if(_0x363904==='activation'){await _0x310d55(_0xe1bbd5,_0x4beab3);return;}await _0x3a4f0c(_0xf9a6a1,_0x4beab3);return;}catch(_0x5a018c){console[_0x377ea8(0x266)](_0x377ea8(0x10f)+_0xf9a6a1+':\x20'+_0x5a018c[_0x377ea8(0x307)]),process['exit'](0x1);}switch(_0x47268a){case'blob':await _0x3a4f0c(_0xf9a6a1,_0x4beab3);break;case _0x377ea8(0x2e0):await _0x310d55(_0xf9a6a1,_0x4beab3);break;case _0x377ea8(0x297):await _0x334955(_0xf9a6a1,_0x4beab3);break;default:console[_0x377ea8(0x266)](_0x377ea8(0x1d4)+_0xf9a6a1+'\x22'),console[_0x377ea8(0x266)](''),console[_0x377ea8(0x266)](_0x377ea8(0xa4)),console[_0x377ea8(0x266)](_0x377ea8(0xf6)),console[_0x377ea8(0x266)](_0x377ea8(0x1db)),console[_0x377ea8(0x266)]('\x20\x20\x20\x20•\x20a\x20license\x20id\x20\x20\x20\x20\x20(uuid)'),console[_0x377ea8(0x266)](_0x377ea8(0x255)),console[_0x377ea8(0x266)](''),console['error'](_0x377ea8(0x362)),process[_0x377ea8(0x15d)](0x1);}}}return;}switch(_0x78651f){case _0x377ea8(0x238):await _0x2aee4d(_0x50abdd);break;case'init':await _0x5dbf09();break;case _0x377ea8(0x19a):await _0x265e3a(_0x50abdd);break;case _0x377ea8(0x95):await _0x494019(_0x4d57c6??_0x4e5a5b[_0x377ea8(0x235)](_0x377ea8(0x378)),_0x50abdd);break;case'export':await _0x194b4b(_0x4d57c6??_0x4e5a5b[_0x377ea8(0x235)](_0x377ea8(0x343)),_0x50abdd,_0x2eeead);break;case _0x377ea8(0x35d):await _0x40f9ff(_0x4d57c6??_0x4e5a5b[_0x377ea8(0x235)](_0x377ea8(0x343)),_0x50abdd,_0x2eeead);break;case _0x377ea8(0x161):await _0x2e83df(_0x4d57c6,_0x50abdd,_0x2eeead);break;}})()[_0x178958(0xd4)](()=>process[_0x178958(0x15d)](0x0))[_0x178958(0x128)](_0x29077b=>{const _0x46a7d3=_0x178958;console[_0x46a7d3(0x266)](_0x46a7d3(0x2cf)+(_0x29077b['message']||_0x29077b)+'\x0a'),process[_0x46a7d3(0x15d)](0x1);});}else _0x2b37cf()[_0x178958(0x128)](_0x3f383b=>{const _0x1525fd=_0x178958;console[_0x1525fd(0x266)](_0x1525fd(0x38a)),console[_0x1525fd(0x266)](_0x3f383b[_0x1525fd(0xc3)]||_0x3f383b),process['exit'](0x1);});}return okdb$1;}var okdbExports=requireOkdb(),okdb=getDefaultExportFromCjs(okdbExports);module[_0x152c38(0x13b)]=okdb;
2
+ 'use strict';const _0x538f61=_0x44a0;(function(_0x31dffb,_0x1e1a7d){const _0x2942a4=_0x44a0,_0x5de995=_0x31dffb();while(!![]){try{const _0x2c488b=parseInt(_0x2942a4(0x405))/0x1+-parseInt(_0x2942a4(0x1f7))/0x2*(-parseInt(_0x2942a4(0x2d2))/0x3)+parseInt(_0x2942a4(0x35d))/0x4*(parseInt(_0x2942a4(0x20f))/0x5)+-parseInt(_0x2942a4(0x38d))/0x6+-parseInt(_0x2942a4(0x40b))/0x7+parseInt(_0x2942a4(0x2bd))/0x8*(-parseInt(_0x2942a4(0x299))/0x9)+parseInt(_0x2942a4(0x386))/0xa*(-parseInt(_0x2942a4(0x1b5))/0xb);if(_0x2c488b===_0x1e1a7d)break;else _0x5de995['push'](_0x5de995['shift']());}catch(_0x7c6956){_0x5de995['push'](_0x5de995['shift']());}}}(_0x52d5,0x90b46));var require$$1$1=require(_0x538f61(0x3c3)),require$$1=require('fs'),require$$3=require(_0x538f61(0x25f)),require$$0$2=require(_0x538f61(0x45e)),require$$5=require(_0x538f61(0x246)),require$$0=require(_0x538f61(0x451)),require$$0$1=require(_0x538f61(0x341)),require$$2$1=require('os'),require$$4=require(_0x538f61(0x349));function getDefaultExportFromCjs(_0x1abbcd){const _0x406f4f=_0x538f61;return _0x1abbcd&&_0x1abbcd[_0x406f4f(0x35c)]&&Object[_0x406f4f(0x376)]['hasOwnProperty'][_0x406f4f(0x248)](_0x1abbcd,_0x406f4f(0x200))?_0x1abbcd[_0x406f4f(0x200)]:_0x1abbcd;}var okdb$1={},version='1.6.2',require$$2={'version':version},okdbAuthTokens,hasRequiredOkdbAuthTokens;function requireOkdbAuthTokens(){if(hasRequiredOkdbAuthTokens)return okdbAuthTokens;hasRequiredOkdbAuthTokens=0x1;const _0x1373c9=require$$0;function _0x3d8842(_0x16e0ff,_0x37b8ad){const _0x27f552=_0x44a0;return _0x1373c9[_0x27f552(0x474)]('sha256',_0x37b8ad)[_0x27f552(0x2c5)](_0x16e0ff)[_0x27f552(0x1dc)]('base64url');}function _0x3edbf1(_0x54514a,_0x104c27){const _0x1ea4d4=_0x44a0;if(typeof _0x54514a!==_0x1ea4d4(0x373)||typeof _0x104c27!==_0x1ea4d4(0x373))return![];if(Buffer[_0x1ea4d4(0x466)](_0x54514a)!==Buffer[_0x1ea4d4(0x466)](_0x104c27))return![];return _0x1373c9[_0x1ea4d4(0x33d)](Buffer[_0x1ea4d4(0x252)](_0x54514a),Buffer['from'](_0x104c27));}function _0x183f2d(_0x372790){const _0x5045a2=_0x44a0;if(!_0x372790?.['startsWith'](_0x5045a2(0x3ef)))return null;return _0x372790[_0x5045a2(0x1c2)](0x7);}function _0x550ad0(_0x19ed25=0x20){const _0x3d8646=_0x44a0;return _0x1373c9[_0x3d8646(0x394)](_0x19ed25)[_0x3d8646(0x449)](_0x3d8646(0x1f8));}function _0x250ab9(_0x2abb93){const _0x2eb6b6=_0x44a0;return _0x1373c9['createHash'](_0x2eb6b6(0x2a3))['update'](_0x2abb93)[_0x2eb6b6(0x1dc)](_0x2eb6b6(0x269));}function _0x1c8624(_0x3a7a58,_0xd1118f,_0x4bceb4=0x36ee80){const _0x4e24e=_0x44a0;if(!_0xd1118f)throw new Error('Token\x20secret\x20not\x20configured');const _0x4b90af=Date['now'](),_0x4962af=Buffer[_0x4e24e(0x252)](JSON['stringify']({'iat':_0x4b90af,'exp':_0x4b90af+_0x4bceb4,'sub':_0x3a7a58?.['id']??_0x3a7a58?.[_0x4e24e(0x3f2)]??null,'username':_0x3a7a58?.[_0x4e24e(0x1e5)]??_0x3a7a58?.[_0x4e24e(0x2b5)]??null,'roles':Array[_0x4e24e(0x27d)](_0x3a7a58?.[_0x4e24e(0x369)])?_0x3a7a58[_0x4e24e(0x369)]:[]}))[_0x4e24e(0x449)](_0x4e24e(0x1f8)),_0x5ea42a=_0x3d8842(_0x4962af,_0xd1118f);return _0x4962af+'.'+_0x5ea42a;}function _0x4c14e9(_0x5900a8,_0x558954){const _0x3af6ae=_0x44a0;if(!_0x558954||typeof _0x5900a8!==_0x3af6ae(0x373))return null;const [_0x151054,_0x58eb15]=_0x5900a8['split']('.');if(!_0x151054||!_0x58eb15)return null;const _0x522abc=_0x3d8842(_0x151054,_0x558954);if(!_0x3edbf1(_0x58eb15,_0x522abc))return null;try{const _0x264bd4=JSON['parse'](Buffer[_0x3af6ae(0x252)](_0x151054,_0x3af6ae(0x1f8))['toString']()),_0x28198c=0x7530;if(Date[_0x3af6ae(0x311)]()>Number(_0x264bd4?.[_0x3af6ae(0x239)]??0x0)+_0x28198c)return null;return _0x264bd4;}catch{return null;}}async function _0x422777(_0x20fd5b){return new Promise((_0x1657c8,_0x59a646)=>{const _0x4a1383=_0x44a0,_0x5564a8=_0x1373c9[_0x4a1383(0x394)](0x10);_0x1373c9[_0x4a1383(0x20b)](_0x20fd5b,_0x5564a8,0x40,(_0x4fcba3,_0x185054)=>{const _0xfe82d0=_0x4a1383;if(_0x4fcba3)_0x59a646(_0x4fcba3);_0x1657c8(_0x5564a8[_0xfe82d0(0x449)](_0xfe82d0(0x269))+':'+_0x185054[_0xfe82d0(0x449)](_0xfe82d0(0x269)));});});}async function _0x5f026e(_0x9427f1,_0x55d431){const _0x22ceb6=_0x44a0,[_0x1b5f08,_0x4c2f32]=_0x55d431['split'](':');if(!_0x1b5f08||!_0x4c2f32)return![];const _0x52bec5=Buffer[_0x22ceb6(0x252)](_0x1b5f08,_0x22ceb6(0x269));return new Promise((_0x12698a,_0x138002)=>{const _0x1282c2=_0x22ceb6;_0x1373c9[_0x1282c2(0x20b)](_0x9427f1,_0x52bec5,0x40,(_0x1ab860,_0x117940)=>{const _0x26945b=_0x1282c2;if(_0x1ab860)_0x138002(_0x1ab860);_0x12698a(_0x1373c9['timingSafeEqual'](_0x117940,Buffer[_0x26945b(0x252)](_0x4c2f32,_0x26945b(0x269))));});});}return okdbAuthTokens={'hmac':_0x3d8842,'timingSafeEqual':_0x3edbf1,'parseBearer':_0x183f2d,'randomToken':_0x550ad0,'hashToken':_0x250ab9,'issueToken':_0x1c8624,'authenticateToken':_0x4c14e9,'hashPassword':_0x422777,'verifyPassword':_0x5f026e},okdbAuthTokens;}function _0x44a0(_0x2ca66d,_0x555599){_0x2ca66d=_0x2ca66d-0x1b1;const _0x52d55b=_0x52d5();let _0x44a0f7=_0x52d55b[_0x2ca66d];return _0x44a0f7;}var okdbLicenseCodec,hasRequiredOkdbLicenseCodec;function requireOkdbLicenseCodec(){const _0x3fc48d=_0x538f61;if(hasRequiredOkdbLicenseCodec)return okdbLicenseCodec;hasRequiredOkdbLicenseCodec=0x1;const _0x5bd276=require$$0$1,_0x13dae6=_0x3fc48d(0x201),_0x39e999=new Uint8Array(0x100)[_0x3fc48d(0x486)](0xff);for(let _0x301461=0x0;_0x301461<_0x13dae6['length'];_0x301461++){_0x39e999[_0x13dae6[_0x3fc48d(0x22e)](_0x301461)]=_0x301461,_0x39e999[_0x13dae6[_0x3fc48d(0x22e)](_0x301461)+0x20]=_0x301461;}_0x39e999['O'[_0x3fc48d(0x22e)](0x0)]=0x0,_0x39e999['o'[_0x3fc48d(0x22e)](0x0)]=0x0,_0x39e999['I'['charCodeAt'](0x0)]=0x1,_0x39e999['i'['charCodeAt'](0x0)]=0x1,_0x39e999['L'[_0x3fc48d(0x22e)](0x0)]=0x1,_0x39e999['l'[_0x3fc48d(0x22e)](0x0)]=0x1;function _0x17aa5d(_0x5c170b){let _0x3bdbbd=0x0,_0x39b4b4=0x0,_0x37862b='';for(let _0x31c79e=0x0;_0x31c79e<_0x5c170b['length'];_0x31c79e++){_0x39b4b4=_0x39b4b4<<0x8|_0x5c170b[_0x31c79e],_0x3bdbbd+=0x8;while(_0x3bdbbd>=0x5){_0x3bdbbd-=0x5,_0x37862b+=_0x13dae6[_0x39b4b4>>>_0x3bdbbd&0x1f];}}return _0x3bdbbd>0x0&&(_0x37862b+=_0x13dae6[_0x39b4b4<<0x5-_0x3bdbbd&0x1f]),_0x37862b;}function _0x529e94(_0xf52574){const _0x163dd6=_0x3fc48d;_0xf52574=_0xf52574[_0x163dd6(0x279)](/-/g,'')['toUpperCase']();let _0x4ec64a=0x0,_0x11cc1f=0x0;const _0x319082=[];for(let _0x9d9355=0x0;_0x9d9355<_0xf52574[_0x163dd6(0x48c)];_0x9d9355++){const _0x371019=_0x39e999[_0xf52574[_0x163dd6(0x22e)](_0x9d9355)];if(_0x371019===0xff)continue;_0x11cc1f=_0x11cc1f<<0x5|_0x371019,_0x4ec64a+=0x5,_0x4ec64a>=0x8&&(_0x4ec64a-=0x8,_0x319082[_0x163dd6(0x488)](_0x11cc1f>>>_0x4ec64a&0xff));}return Buffer[_0x163dd6(0x252)](_0x319082);}const _0x33a4fb=[_0x3fc48d(0x346),_0x3fc48d(0x3db),'engines',_0x3fc48d(0x243),_0x3fc48d(0x2a6),_0x3fc48d(0x1c4),_0x3fc48d(0x44b),_0x3fc48d(0x47a)],_0x181c54=0x0,_0x346139=0x1,_0x42001a=0x2,_0x4edd1c=0x6*0x1e*0x18*0x3c*0x3c*0x3e8;function _0x34fda2({issuedAt:_0x323e44,expiresAt:_0x56c7bd,licensee:licensee='',features:features={},limits:limits={},licenseType:licenseType=_0x181c54}){const _0x118585=_0x3fc48d,_0x3344d1=Buffer[_0x118585(0x252)](licensee,_0x118585(0x484))[_0x118585(0x1c2)](0x0,0x40),_0x2c2242=0x1+0x1+0x4+0x4+0x1+_0x3344d1[_0x118585(0x48c)]+0x2+0x10,_0x2f651c=Buffer['allocUnsafe'](_0x2c2242);let _0xd23f5f=0x0;_0x2f651c[_0x118585(0x41f)](0x1,_0xd23f5f++),_0x2f651c[_0x118585(0x41f)](licenseType,_0xd23f5f++),_0x2f651c[_0x118585(0x41c)](Math[_0x118585(0x222)](_0x323e44/0x3e8),_0xd23f5f),_0xd23f5f+=0x4,_0x2f651c['writeUInt32BE'](Math[_0x118585(0x222)](_0x56c7bd/0x3e8),_0xd23f5f),_0xd23f5f+=0x4,_0x2f651c[_0x118585(0x41f)](_0x3344d1[_0x118585(0x48c)],_0xd23f5f++),_0x3344d1[_0x118585(0x284)](_0x2f651c,_0xd23f5f),_0xd23f5f+=_0x3344d1['length'];let _0x1a7ecc=0x0;for(let _0x134204=0x0;_0x134204<_0x33a4fb['length'];_0x134204++){if(features[_0x33a4fb[_0x134204]])_0x1a7ecc|=0x1<<_0x134204;}_0x2f651c['writeUInt16BE'](_0x1a7ecc,_0xd23f5f),_0xd23f5f+=0x2;const _0x1c2e80=[_0x118585(0x431),_0x118585(0x388),_0x118585(0x215),_0x118585(0x1b3)];for(const _0x1686fe of _0x1c2e80){_0x2f651c['writeUInt32BE'](limits[_0x1686fe]||0x0,_0xd23f5f),_0xd23f5f+=0x4;}return _0x2f651c;}function _0x228933(_0x48259b){const _0x47d5c8=_0x3fc48d;let _0x2a45d5=0x0;const _0x4ba34d=_0x48259b[_0x47d5c8(0x3c8)](_0x2a45d5++),_0x47f8c6=_0x48259b[_0x47d5c8(0x3c8)](_0x2a45d5++),_0x5e1cc1=_0x48259b['readUInt32BE'](_0x2a45d5);_0x2a45d5+=0x4;const _0x3a1151=_0x48259b[_0x47d5c8(0x1cc)](_0x2a45d5);_0x2a45d5+=0x4;const _0x57bd19=_0x48259b['readUInt8'](_0x2a45d5++),_0x13782a=_0x48259b[_0x47d5c8(0x1c2)](_0x2a45d5,_0x2a45d5+_0x57bd19)[_0x47d5c8(0x449)](_0x47d5c8(0x484));_0x2a45d5+=_0x57bd19;const _0x2318bd=_0x48259b[_0x47d5c8(0x2ec)](_0x2a45d5);_0x2a45d5+=0x2;const _0x448004={};for(let _0x1eb864=0x0;_0x1eb864<_0x33a4fb[_0x47d5c8(0x48c)];_0x1eb864++){_0x448004[_0x33a4fb[_0x1eb864]]=Boolean(_0x2318bd&0x1<<_0x1eb864);}const _0x1a2ca8=[_0x47d5c8(0x431),_0x47d5c8(0x388),'syncPeers','maxWrites'],_0x393ce1={};for(const _0x3a937c of _0x1a2ca8){const _0x4ee044=_0x48259b[_0x47d5c8(0x1cc)](_0x2a45d5);_0x2a45d5+=0x4,_0x393ce1[_0x3a937c]=_0x4ee044===0x0?null:_0x4ee044;}return{'v':_0x4ba34d,'licenseType':_0x47f8c6,'issuedAt':_0x5e1cc1*0x3e8,'expiresAt':_0x3a1151*0x3e8,'licensee':_0x13782a,'features':_0x448004,'limits':_0x393ce1};}function _0x5f36a9(_0x5d85b4,_0x4e2beb){const _0x7acce4=_0x3fc48d,_0x4b3fab=Buffer[_0x7acce4(0x42f)]([_0x5d85b4,_0x4e2beb]),_0x530c39=_0x17aa5d(_0x4b3fab),_0x5af057=[];for(let _0x18c376=0x0;_0x18c376<_0x530c39[_0x7acce4(0x48c)];_0x18c376+=0x8){_0x5af057[_0x7acce4(0x488)](_0x530c39['slice'](_0x18c376,_0x18c376+0x8));}return _0x5af057[_0x7acce4(0x2d8)]('-');}function _0x224ce0(_0x199eab){const _0x38862a=_0x3fc48d;if(typeof _0x199eab!==_0x38862a(0x373))throw new Error(_0x38862a(0x1dd));const _0x578034=_0x529e94(_0x199eab[_0x38862a(0x279)](/-/g,''));if(_0x578034[_0x38862a(0x48c)]<0x41)throw new Error(_0x38862a(0x1d1)+_0x578034[_0x38862a(0x48c)]+'\x20bytes,\x20need\x20>=\x2065)');const _0x39dc0a=_0x578034[_0x38862a(0x1c2)](0x0,_0x578034[_0x38862a(0x48c)]-0x40),_0x44d7ab=_0x578034['slice'](_0x578034[_0x38862a(0x48c)]-0x40);let _0x25d0d8;try{_0x25d0d8=_0x228933(_0x39dc0a);}catch(_0x43f593){throw new Error('decodeLicenseBlob:\x20failed\x20to\x20decode\x20payload:\x20'+_0x43f593[_0x38862a(0x2a5)]);}return{'rawBuf':_0x578034,'payload':_0x39dc0a,'sig':_0x44d7ab,'decoded':_0x25d0d8};}function _0x2f2d00(_0x22b44d){const _0x45dd34=_0x3fc48d;return _0x5bd276[_0x45dd34(0x318)](_0x45dd34(0x2a3))[_0x45dd34(0x2c5)](_0x22b44d)[_0x45dd34(0x1dc)]()[_0x45dd34(0x1c2)](0x0,0x8);}function _0x3a90fc(_0x1e89b3,_0x6ab5c4,_0x418031){const _0x14a5e4=_0x3fc48d,_0x5997a6=_0x14a5e4(0x242)+_0x418031,_0x2adb0a=Buffer[_0x14a5e4(0x42f)]([Buffer[_0x14a5e4(0x252)](_0x1e89b3,_0x14a5e4(0x484)),_0x6ab5c4]),_0x382fab=_0x5bd276[_0x14a5e4(0x474)](_0x14a5e4(0x2a3),_0x5997a6)['update'](_0x2adb0a)[_0x14a5e4(0x1dc)](),_0xfa64d3=_0x17aa5d(_0x382fab[_0x14a5e4(0x1c2)](0x0,0x5));return{'pin':_0xfa64d3,'pinHmac':_0x382fab};}function _0x222db6(_0x296389,_0x7631a6,_0x5151a7){const _0x547b18=_0x3fc48d,_0x47d806=Buffer[_0x547b18(0x355)](0x4d);let _0x1413ae=0x0;_0x47d806[_0x547b18(0x41f)](0x1,_0x1413ae++),_0x296389[_0x547b18(0x284)](_0x47d806,_0x1413ae),_0x1413ae+=0x8,_0x47d806[_0x547b18(0x41c)](_0x7631a6,_0x1413ae),_0x1413ae+=0x4,_0x5151a7[_0x547b18(0x284)](_0x47d806,_0x1413ae);const _0x1fa201=_0x17aa5d(_0x47d806),_0x13184d=[];for(let _0x6ea1a2=0x0;_0x6ea1a2<_0x1fa201[_0x547b18(0x48c)];_0x6ea1a2+=0x6){_0x13184d[_0x547b18(0x488)](_0x1fa201[_0x547b18(0x1c2)](_0x6ea1a2,_0x6ea1a2+0x6));}return _0x13184d[_0x547b18(0x2d8)]('-');}function _0x3843da(_0x303763){const _0x2c5db8=_0x3fc48d;if(typeof _0x303763!=='string')throw new Error(_0x2c5db8(0x3f9));const _0x4ddc16=_0x529e94(_0x303763['replace'](/-/g,''));if(_0x4ddc16[_0x2c5db8(0x48c)]!==0x4d)throw new Error('decodeActivationToken:\x20expected\x2077\x20bytes,\x20got\x20'+_0x4ddc16[_0x2c5db8(0x48c)]);let _0x47378c=0x0;const _0x592c82=_0x4ddc16[_0x2c5db8(0x3c8)](_0x47378c++),_0x467e64=_0x4ddc16[_0x2c5db8(0x1c2)](_0x47378c,_0x47378c+0x8);_0x47378c+=0x8;const _0x24b086=_0x4ddc16[_0x2c5db8(0x1cc)](_0x47378c);_0x47378c+=0x4;const _0x214fd8=_0x4ddc16[_0x2c5db8(0x1c2)](_0x47378c);return{'v':_0x592c82,'licenseHash':_0x467e64,'expiry':_0x24b086,'sig':_0x214fd8};}function _0x4df930({tokenString:_0x22d01e,nodeId:_0x529dd7,rawBlobBuf:_0x4deac2,pubKeyPem:_0x3646c3,pubFingerprint:_0x43b9b7}){const _0x563f80=_0x3fc48d;let _0x31ccc1;try{_0x31ccc1=_0x3843da(_0x22d01e);}catch(_0x2cbb9d){return{'valid':![],'reason':'MALFORMED_TOKEN'};}const _0x1ee466=_0x2f2d00(_0x4deac2);if(!_0x1ee466['equals'](_0x31ccc1[_0x563f80(0x22b)]))return{'valid':![],'reason':_0x563f80(0x27b)};const {pinHmac:_0x53c645}=_0x3a90fc(_0x529dd7,_0x1ee466,_0x43b9b7),_0x554e18=Buffer[_0x563f80(0x355)](0x4);_0x554e18[_0x563f80(0x41c)](_0x31ccc1[_0x563f80(0x39a)],0x0);const _0x55df06=Buffer[_0x563f80(0x42f)]([Buffer['from']([_0x31ccc1['v']]),_0x53c645[_0x563f80(0x1c2)](0x0,0x5),_0x31ccc1[_0x563f80(0x22b)],_0x554e18]);try{const _0x4a7cfe=_0x5bd276['verify'](null,_0x55df06,_0x3646c3,_0x31ccc1['sig']);if(!_0x4a7cfe)return{'valid':![],'reason':_0x563f80(0x2a7)};}catch(_0x2a3350){return{'valid':![],'reason':'SIG_INVALID'};}if(_0x31ccc1[_0x563f80(0x39a)]<Date[_0x563f80(0x311)]()/0x3e8)return{'valid':![],'reason':_0x563f80(0x34a)};return{'valid':!![],'reason':'ok'};}function _0x520397(_0x27b13f){const _0xb720ae=_0x3fc48d;if(typeof _0x27b13f!=='string')return _0xb720ae(0x273);const _0x3a52d7=_0x27b13f[_0xb720ae(0x34d)]();if(_0x3a52d7[_0xb720ae(0x424)]('/')||_0x3a52d7[_0xb720ae(0x424)]('./')||_0x3a52d7[_0xb720ae(0x424)](_0xb720ae(0x26c))||/^[A-Za-z]:[\\/]/[_0xb720ae(0x320)](_0x3a52d7))return _0xb720ae(0x3c3);if(/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i[_0xb720ae(0x320)](_0x3a52d7))return _0xb720ae(0x3cd);const _0xdf5035=_0x3a52d7[_0xb720ae(0x279)](/[\s-]+/g,'')[_0xb720ae(0x48c)];if(_0xdf5035===0x7c)return _0xb720ae(0x3a9);if(_0xdf5035>=0x95&&_0xdf5035<=0xfc)return _0xb720ae(0x283);return _0xb720ae(0x273);}return okdbLicenseCodec={'toBase32':_0x17aa5d,'fromBase32':_0x529e94,'encodeLicensePayload':_0x34fda2,'decodeLicensePayload':_0x228933,'encodeLicenseBlob':_0x5f36a9,'decodeLicenseBlob':_0x224ce0,'licenseHash':_0x2f2d00,'derivePin':_0x3a90fc,'encodeActivationToken':_0x222db6,'decodeActivationToken':_0x3843da,'verifyActivation':_0x4df930,'detectInputType':_0x520397,'FEATURE_NAMES':_0x33a4fb,'LICENSE_TYPE_STANDARD':_0x181c54,'LICENSE_TYPE_OPEN':_0x346139,'LICENSE_TYPE_INTERNAL':_0x42001a,'OPEN_LICENSE_MAX_DURATION_MS':_0x4edd1c},okdbLicenseCodec;}var okdbError,hasRequiredOkdbError;function requireOkdbError(){if(hasRequiredOkdbError)return okdbError;hasRequiredOkdbError=0x1;class _0x519e23 extends Error{constructor(_0x5cc48c,_0x267260,_0x16c9a5={}){const _0x3923e0=_0x44a0;super(_0x5cc48c),this['name']=_0x3923e0(0x258),this[_0x3923e0(0x2d7)]=_0x267260,this[_0x3923e0(0x367)]=_0x16c9a5,_0x16c9a5[_0x3923e0(0x3d5)]&&(this[_0x3923e0(0x3d5)]=_0x16c9a5[_0x3923e0(0x3d5)]),Error[_0x3923e0(0x478)](this,this[_0x3923e0(0x457)]);}}class _0x139364 extends _0x519e23{constructor(_0x44fcac,_0x44c5e2,_0x444d19,_0xfff964){const _0x2d26a1=_0x44a0;super('Version\x20mismatch\x20for\x20'+_0x44fcac+'@'+_0x44c5e2+_0x2d26a1(0x4ae)+_0x444d19+_0x2d26a1(0x3c9)+_0xfff964,'VERSION_MISMATCH',{'type':_0x44fcac,'key':_0x44c5e2,'expectedVersion':_0x444d19,'actualVersion':_0xfff964}),this['name']='OKDBVersionMismatchError';}}class _0x4eea25 extends _0x519e23{constructor(_0x1ccca0,_0x1fe5e0){const _0x4177b7=_0x44a0;super(_0x1ccca0+'@'+_0x1fe5e0+_0x4177b7(0x2c3),'NOT_FOUND',{'type':_0x1ccca0,'key':_0x1fe5e0}),this[_0x4177b7(0x2b5)]=_0x4177b7(0x1ec);}}class _0x129a9a extends _0x519e23{constructor(_0x214c5e,_0x2feb53){const _0x1a8b5a=_0x44a0;super(_0x214c5e+'@'+_0x2feb53+_0x1a8b5a(0x45a),'ALREADY_EXISTS',{'type':_0x214c5e,'key':_0x2feb53}),this['name']=_0x1a8b5a(0x228);}}class _0x21b174 extends _0x519e23{constructor(_0x18ffe3,_0x4615a5){const _0x42fa94=_0x44a0,_0x1d075e=typeof _0x4615a5;super(_0x42fa94(0x251)+_0x18ffe3+_0x42fa94(0x459)+_0x1d075e+'.\x20Only\x20primitives,\x20null,\x20Buffers,\x20and\x20arrays\x20are\x20allowed.\x20Got:\x20'+_0x4615a5,'INVALID_INDEX_KEY',{'index':_0x18ffe3,'key':_0x4615a5,'keyType':_0x1d075e}),this[_0x42fa94(0x2b5)]=_0x42fa94(0x44f);}}class _0x13df89 extends _0x519e23{constructor(_0x2db62c){const _0x32c479=_0x44a0,_0x44bd45=typeof _0x2db62c;super(_0x32c479(0x212)+_0x44bd45+'.\x20Primary\x20keys\x20must\x20be\x20string\x20or\x20number.\x20Got:\x20'+_0x2db62c,_0x32c479(0x1c1),{'key':_0x2db62c,'keyType':_0x44bd45}),this['name']=_0x32c479(0x3d3);}}class _0x2b79a0 extends _0x519e23{constructor(_0x5856da){const _0x3e5ad2=_0x44a0;super(_0x3e5ad2(0x3d1)+_0x5856da+'\x27\x20doesn\x27t\x20exist',_0x3e5ad2(0x446),{'type':_0x5856da}),this[_0x3e5ad2(0x2b5)]=_0x3e5ad2(0x220);}}class _0x17cdd2 extends _0x519e23{constructor(_0x3de509){const _0x48536c=_0x44a0;super(_0x48536c(0x3d1)+_0x3de509+'\x27\x20already\x20registered',_0x48536c(0x372),{'type':_0x3de509}),this[_0x48536c(0x2b5)]=_0x48536c(0x27c);}}class _0x239d8e extends _0x519e23{constructor(_0x470622,_0x32f30e){const _0x3c0218=_0x44a0;super(_0x3c0218(0x436)+_0x32f30e+_0x3c0218(0x2f8)+_0x470622+'\x27\x20doesn\x27t\x20exist','INDEX_NOT_REGISTERED',{'type':_0x470622,'index':_0x32f30e}),this[_0x3c0218(0x2b5)]=_0x3c0218(0x470);}}class _0x56bade extends _0x519e23{constructor(_0x4b66e2,_0x4f9f0e){const _0x352498=_0x44a0;super(_0x352498(0x436)+_0x4f9f0e+_0x352498(0x2f8)+_0x4b66e2+_0x352498(0x24c),_0x352498(0x483),{'type':_0x4b66e2,'index':_0x4f9f0e}),this[_0x352498(0x2b5)]=_0x352498(0x335);}}class _0x93e817 extends _0x519e23{constructor(_0xbbeb6d,_0x3ad4a5={}){const _0x5cc5ba=_0x44a0;super(_0xbbeb6d,_0x5cc5ba(0x2b9),_0x3ad4a5),this[_0x5cc5ba(0x2b5)]=_0x5cc5ba(0x402);}}class _0x3287b1 extends _0x519e23{constructor(_0x2b88f7,_0x4e6cc3,_0x171665,_0x304781,_0x800c06){const _0x3671a3=_0x44a0;super(_0x3671a3(0x36e)+_0x2b88f7+'@'+_0x4e6cc3+':\x20key\x20['+_0x171665+']\x20already\x20maps\x20to\x20\x27'+_0x304781+_0x3671a3(0x468)+_0x800c06+'\x27',_0x3671a3(0x390),{'type':_0x2b88f7,'index':_0x4e6cc3,'indexKey':_0x171665,'existingKey':_0x304781,'conflictingKey':_0x800c06}),this[_0x3671a3(0x2b5)]=_0x3671a3(0x1d0);}}class _0x5d9ada extends _0x519e23{constructor(_0x7bd7e5,_0x3fb7aa,_0x52ac34){const _0x44cbe6=_0x44a0;super(_0x44cbe6(0x2b0)+_0x7bd7e5+'@'+_0x3fb7aa,_0x44cbe6(0x1fd),{'type':_0x7bd7e5,'key':_0x3fb7aa,'errors':_0x52ac34}),this[_0x44cbe6(0x2b5)]=_0x44cbe6(0x270),this['type']=_0x7bd7e5,this[_0x44cbe6(0x22c)]=_0x3fb7aa,this['errors']=_0x52ac34;}}class _0x3239e9 extends _0x519e23{constructor(_0x564ad6,_0x3cae2e){const _0x3919a2=_0x44a0;super(_0x3919a2(0x475)+_0x564ad6+':\x20'+_0x3cae2e['length']+_0x3919a2(0x1b9),'SCHEMA_COLLECTION_INVALID',{'type':_0x564ad6,'failures':_0x3cae2e}),this[_0x3919a2(0x2b5)]='OKDBSchemaCollectionError',this[_0x3919a2(0x398)]=_0x564ad6,this[_0x3919a2(0x37b)]=_0x3cae2e;}}class _0x3fb43f extends _0x519e23{constructor(_0x1945f6,_0x2b30d0,_0x1fa56b,_0x50761c,_0x4e92e6){const _0x54e697=_0x44a0;super('Foreign\x20key\x20violation:\x20'+_0x1945f6+'@'+_0x2b30d0+'.'+_0x1fa56b+_0x54e697(0x26f)+_0x50761c+'@'+_0x4e92e6+_0x54e697(0x29d),'FOREIGN_KEY_VIOLATION',{'sourceType':_0x1945f6,'sourceKey':_0x2b30d0,'fieldPath':_0x1fa56b,'targetType':_0x50761c,'targetKey':_0x4e92e6}),this[_0x54e697(0x2b5)]='OKDBForeignKeyError',this[_0x54e697(0x1f2)]=_0x1945f6,this[_0x54e697(0x25a)]=_0x2b30d0,this[_0x54e697(0x25c)]=_0x1fa56b,this['targetType']=_0x50761c,this[_0x54e697(0x1d5)]=_0x4e92e6;}}class _0x463e7c extends _0x519e23{constructor(_0x24cd30,_0x33f22f,_0x545dfd){const _0x584b23=_0x44a0;super('Cannot\x20delete\x20'+_0x24cd30+'@'+_0x33f22f+':\x20'+_0x545dfd['length']+_0x584b23(0x216),'FOREIGN_KEY_DELETE_RESTRICTED',{'targetType':_0x24cd30,'targetKey':_0x33f22f,'references':_0x545dfd}),this[_0x584b23(0x2b5)]=_0x584b23(0x24f),this[_0x584b23(0x331)]=_0x24cd30,this[_0x584b23(0x1d5)]=_0x33f22f,this[_0x584b23(0x421)]=_0x545dfd;}}class _0x4be49b extends _0x519e23{constructor(_0xc636a8,_0x444a3e,_0x1c3955){const _0x243d21=_0x44a0;super('Index\x20\x22'+_0x444a3e+_0x243d21(0x33f)+_0xc636a8+'\x22\x20is\x20used\x20by:\x20'+_0x1c3955[_0x243d21(0x308)](_0x4eaff5=>_0x4eaff5[_0x243d21(0x217)]+':'+_0x4eaff5[_0x243d21(0x2b5)])[_0x243d21(0x2d8)](',\x20'),_0x243d21(0x2a4),{'type':_0xc636a8,'index':_0x444a3e,'usedBy':_0x1c3955}),this[_0x243d21(0x2b5)]=_0x243d21(0x400);}}return okdbError={'OKDBError':_0x519e23,'OKDBVersionMismatchError':_0x139364,'OKDBNotFoundError':_0x4eea25,'OKDBAlreadyExistsError':_0x129a9a,'OKDBInvalidIndexKeyError':_0x21b174,'OKDBInvalidPrimaryKeyError':_0x13df89,'OKDBTypeNotRegisteredError':_0x2b79a0,'OKDBTypeAlreadyRegisteredError':_0x17cdd2,'OKDBIndexNotRegisteredError':_0x239d8e,'OKDBIndexAlreadyRegisteredError':_0x56bade,'OKDBInvalidValueError':_0x93e817,'OKDBUniqueConstraintError':_0x3287b1,'OKDBSchemaValidationError':_0x5d9ada,'OKDBSchemaCollectionError':_0x3239e9,'OKDBForeignKeyError':_0x3fb43f,'OKDBForeignKeyDeleteError':_0x463e7c,'OKDBIndexHasConsumersError':_0x4be49b},okdbError;}function _0x52d5(){const _0x14c759=['count','\x20\x20Path\x20access','decoded','Open\x20licenses\x20cannot\x20exceed\x206\x20months\x20duration\x20(this\x20license\x20expires\x20','licenseId','[okdb]\x20error:\x20no\x20token\x20with\x20id\x20\x22','every','\x20\x20\x20\x20label:\x20\x20\x20\x20\x20\x20\x20','⚠\x20OPEN\x20LICENSE\x20ACTIVE\x20—\x20this\x20license\x20is\x20not\x20node-bound\x20and\x20is\x20intended\x20for\x20POC/demo\x20use\x20only.\x20Expires\x20in\x20','readUInt16BE','Sync','getRange','--key','\x20\x20\x20\x202.\x20The\x20vendor\x20returns\x20an\x20activation\x20token.','wrong_node','darwin','\x20\x20(licenses\x20must\x20be\x20signed\x20by\x20the\x20matching\x20private\x20key)','doctor','ceil','CREATED','yellow','\x27\x20on\x20type\x20\x27','--config','\x20\x20(unlimited)','selfAddress','[body]','index:progress','_active','Types','PATCH','access','\x20/\x20','\x20more','verifyActivation','val','EXIT','—\x20/api/\x20is\x20auto-prefixed,\x20env\x20is\x20auto-injected','map','summary','{}[]:,\x0a\x0d\x09\x20','[okdb]\x20.kdbconfig\x20already\x20exists\x20—\x20skipping','\x0a\x20\x20\x20\x20','stderr','_isFree','_systemEnv','type/users/item/alice','now','info','stdout','filter','queue','--log-level','\x1b[34m','createHash','noRepl','--path','addedAt','processors/','typeSubDbs','rmSync','other','test','children','(none)','enabled','SIGTERM','drop','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/env/','param','Processors','once','\x20MB)','(on\x20any\x20path\x20command)','\x20\x20\x20\x20\x20\x20\x20\x20\x20browse\x20API\x20routes,\x20grouped\x20by\x20area\x0a\x20\x20','getPins','\x20\x20\x20\x20\x20explicit\x20method\x0a\x0a\x20\x20','stopping','~tokens','targetType','\x20(must\x20be\x201–65535)','halted','addLicense','OKDBIndexAlreadyRegisteredError','\x20records…','operation',',\x20label:\x20','Full-text\x20search','USE','title','inputSchema','timingSafeEqual','derivePin','\x22\x20on\x20\x22','keys/public.pem','node:crypto','Activation\x20invalid:\x20','create','\x20\x20✓\x20database\x20opened\x0a','unique:violation','sync','type/users/item/alice\x20--env\x20staging','\x0a\x20\x20Invalid\x20JSON:\x20','child_process','ACTIVATION_EXPIRED','set','history','trim','xdg-open\x20','License\x20expired\x20or\x20invalidated','registerType','--name','finally','listen','\x20day(s).','allocUnsafe','(no\x20types)','--types','_envs','\x20result','.okdb-write-test','logRequests','__esModule','1492qvgUip','\x20\x20\x20\x20licensee:\x20\x20','VERB','valid','\x0a[okdb]\x20error:\x20','\x22\x20→\x20','pending','\x20\x20\x20\x20','schema:set','\x20\x20·\x20','details','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20set\x20active\x20environment\x20(persists\x20in\x20session)\x0a\x20\x20','roles','starting','types:','\x20(expires\x20','free\x20tier','Unique\x20constraint\x20violated\x20on\x20','admin','\x0a[okdb]\x20shutting\x20down…\x0a','isFile','TYPE_ALREADY_REGISTERED','string','created','--permissions','prototype','\x1b[31m','[okdb]\x20error:\x20no\x20license\x20with\x20id\x20\x22','stringify','\x20\x20\x20\x20pin:\x20\x20\x20\x20\x20\x20\x20','failures','env:removed','engines','[okdb]\x20error:\x20remove\x20requires\x20an\x20id\x20argument','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20show\x20this\x20help\x0a\x20\x20','expires','.kdb_history','resetIndex','tags','values','__OKDB_PUB_FINGERPRINT__','10180BKdyVw','\x20\x20\x20\x20graceful\x20shutdown\x0a','typesPerEnv','readFileSync','\x20\x20\x20\x20\x20\x20','rawBuf','\x20logs\x20on\x20\x20','5032602pSClRy','indexToDb','invalid','UNIQUE_CONSTRAINT','\x20\x20\x20\x20name:\x20\x20\x20\x20\x20\x20\x20\x20','dropSchema','item:update','randomBytes','auth','licenseType','terminal','type','http://localhost:','expiry','[okdb]\x20error:\x20unrecognized\x20input:\x20\x22','http','__writeCounter','[okdb]\x20error:\x20license\x20management\x20is\x20only\x20available\x20in\x20licensed\x20builds\x20(npm\x20run\x20build:prod).','\x22\x20already\x20exists','[okdb]\x20opening\x20','\x1b[33m','level','Indexes','\x20\x20\x20\x20•\x20a\x20path\x20to\x20a\x20.license\x20file','\x20\x20⚠','\x20\x20\x20\x20•\x20an\x20activation\x20token\x20\x20(124\x20chars)','\x20environment\x20','\x20\x20\x20\x20status:\x20\x20\x20\x20active\x20\x20(open\x20license\x20—\x20no\x20activation\x20needed)','activation','./okdb-export.ndjson','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/env/staging/info\x0a\x0a','setPrompt','hint','[okdb]\x20exporting\x20env\x20\x22','\x20\x20@','Environments','loadEnvFile','indexes','envs=','ready','port\x20','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20GET\x20(implicit)\x0a\x20\x20','\x20days\x20—\x20POC/demo\x20only,\x20not\x20node-bound)','unlinkSync','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20show\x20active\x20environment\x20+\x20list\x20all\x20envs\x0a\x20\x20','.\x20The\x20active\x20license\x20does\x20not\x20enable\x20\x22','\x1b[2m','\x0a\x20\x20Joining\x20cluster\x20at\x20','./okdb-backup','/type/users/query\x0a\x20\x20\x20\x20','records','/type/users/item/alice\x0a\x20\x20\x20\x20','[okdb]\x20error:\x20ambiguous\x20prefix\x20\x22','types/env=','path','onLicenseExpired','statSync','dim','catch','readUInt8',',\x20got\x20','env','\x20\x20Example:\x20okdb\x20join\x20https://node-a.example.com\x20--token\x20<t>\x20--address\x20http://myhost:8484\x0a','permissions','uuid','system:drain','repeat','data','Type\x20\x27','license:activated','OKDBInvalidPrimaryKeyError','env:opened','cause','homedir','hasType','toLocaleString','init','--port','embeddings','dirname','schema:drop','Queue','label','value','clearTtl','exportToFile','[okdb]\x20import\x20complete','LICENSED_BUILD','⚠\x20INTERNAL\x20LICENSE\x20ACTIVE\x20—\x20all\x20features\x20and\x20limits\x20are\x20unlocked.\x20For\x20vendor/internal\x20use\x20only.','resolve','list','No\x20tokens.','LABEL','\x20\x20(need\x20≥\x2018)','safety','database\x20path\x20not\x20writable:\x20','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20open\x20admin\x20UI\x20in\x20browser\x0a\x20\x20','--token','Bearer\x20','[okdb]\x20failed\x20to\x20parse\x20config\x20file\x20','\x20\x20Common\x20causes:','sub','--password','\x20SECURITY\x20NOTICE','\x20env','\x20\x20No\x20licenses\x20stored.\x20Use\x20`okdb\x20license\x20<blob>`\x20to\x20add\x20one.','--blobs','entries','decodeActivationToken:\x20input\x20must\x20be\x20a\x20string','\x20\x20\x20\x20-\x20The\x20activation\x20token\x20has\x20expired\x20—\x20request\x20a\x20fresh\x20one.','setSchema','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/env/','keys','has','detectInputType','OKDBIndexHasConsumersError','false','OKDBInvalidValueError','LICENSE_INVALID','--ttl','1071663VxsvCX','Files','transport','\x20\x20\x20\x20\x20http://localhost:','env/:env','ttl','337127GTfsni','reason','\x20\x20\x20\x20writes:\x20\x20\x20\x20','type/users\x20--help','includes','\x20\x20\x20\x20status:\x20\x20\x20\x20pending\x20activation','listening','input:\x20','yes','--address','\x20(expires\x20in\x20','bold','available','\x20\x20╚═══════════════════════════╝','Feature\x20not\x20available\x20on\x20free\x20tier:\x20','stack','idx:','writeUInt32BE','der','\x1b[0m','writeUInt8','padStart','references','true','\x20\x20All\x20checks\x20passed.\x0a','startsWith','\x22.\x20Use:\x20create,\x20list,\x20revoke','\x20—\x20type\x20env\x20to\x20list\x20available\x0a','migrate','\x20\x20Shell\x20commands','stdin','importFromFile','\x20logs\x20off\x0a','\x1b[35m','shutdown','config','concat','(add\x20a\x20license\x20first)','envs','\x20\x20╔═══════════════════════════╗','[okdb]\x20port\x20','LICENSE_TYPE_OPEN','\x22\x20matches\x20','Index\x20\x27','\x20\x20✓\x20Revoked\x20token\x20','token','mkdirSync','ref:violation','password','then','\x20\x20\x20\x20limits:\x20\x20\x20\x20','logLevel','type/users','active:','\x0d[okdb]\x20','License\x20signature\x20invalid\x20—\x20this\x20license\x20was\x20not\x20signed\x20by\x20the\x20key\x20paired\x20with\x20this\x20build.\x20','pause','id:\x20','\x20\x20\x20\x20-\x20The\x20activation\x20token\x20was\x20issued\x20for\x20a\x20different\x20node\x20—\x20share\x20this\x20node\x27s\x20PIN\x20with\x20the\x20vendor.','TYPE_NOT_REGISTERED','type/','[okdb]\x20nothing\x20to\x20reset\x20—\x20','toString','--env','mcp','trimStart','\x20MB\x20→\x20','sizeBefore','OKDBInvalidIndexKeyError','[okdb]\x20loaded\x20config:\x20','crypto','./okdb-data','item:remove','\x20\x20Note:\x20this\x20node\x20has\x20existing\x20tokens.\x20They\x20will\x20coexist\x20with\x20cluster\x20tokens\x0a','item:create','[okdb]\x20error:\x20','constructor','\x0a\x0a\x20\x20','\x27:\x20','\x20already\x20exists','started','\x0a\x20\x20Delete\x20ALL\x20data\x20in\x20','meta','readline','getCount','open','resetting','indexOf','exit','LOGS','txn:end','byteLength','[okdb]\x20error:\x20failed\x20to\x20read\x20','\x27,\x20cannot\x20map\x20to\x20\x27','randomUUID','/api/env/','\x20\x20Usage:\x20','api','fts:drop','env/staging/info','green','OKDBIndexNotRegisteredError','Either\x20the\x20build\x20was\x20made\x20with\x20a\x20different\x20keypair,\x20or\x20the\x20license\x20was\x20issued\x20with\x20a\x20different\x20private\x20key.','_license','round','createHmac','Cannot\x20set\x20enforce\x20schema\x20on\x20','licensed','pin','captureStackTrace','endsWith','files','\x1b[32m','\x20\x20\x20\x20\x20\x20\x20POST\x20(body\x20implies\x20POST)\x0a\x20\x20','DELETE','options','[okdb]\x20invalid\x20port:\x20','search','fromEntries','\x20\x20\x20\x20status:\x20\x20\x20\x20','INDEX_ALREADY_REGISTERED','utf8','find','fill','sig','push','prompt','already\x20in\x20use','type/users/query\x20{\x22active\x22:true}','length','hasOwnProperty','[filter]','use\x20<env>','cyan','POST','debug','some','--open','padEnd','[okdb]\x20started\x20in\x20','import','\x20\x20\x20\x20expires:\x20\x20\x20','log','isTTY','--no-admin','txn:rollback','--help','registerIndex','\x20\x20\x20\x20license:\x20free\x20tier\x20—\x20add\x20a\x20license\x20to\x20unlock\x20sync,\x20embeddings,\x20engines,\x20time-machine','red','null','split','routes','[okdb]\x20error:\x20--password\x20requires\x20--name','Invalid\x20license\x20blob:\x20','createInterface','\x0d[okdb]\x20blobs:\x20','standard','ttl:clear','expired','database\x20path\x20writable:\x20','\x20\x20\x20\x20path:\x20\x20','TYPES',':\x20expected\x20','License\x20signature\x20invalid:\x20','transaction','activateLicense','maxWrites','argv','5654dRNISH','Hint:\x20','[okdb]\x20error:\x20show\x20requires\x20an\x20id\x20argument','result','\x20documents\x20fail\x20validation','dbPath','detachConsole','server','/api/','PUBLIC_KEY_PEM','question','noAdmin','INVALID_PRIMARY_KEY','slice','put','views','sync:apply','no\x20.kdbconfig\x20(using\x20defaults)','license','\x20\x20(','createdAt','licensee','[okdb]\x20created\x20.kdbconfig','readUInt32BE','description','.kdbconfig','time','OKDBUniqueConstraintError','decodeLicenseBlob:\x20blob\x20too\x20short\x20(','LICENSE_ACTIVATION_INVALID','\x20\x20Envs:\x20\x20\x20\x20','reverse','targetKey','(empty)','[okdb]\x20blobs:\x20imported=','\x20\x20·\x20\x20','properties','\x20envs','\x20\x20→\x20\x20','digest','decodeLicenseBlob:\x20input\x20must\x20be\x20a\x20string','type:drop','\x20\x20\x20\x20features:\x20\x20','[okdb]\x20importing\x20','[okdb]\x20unknown\x20token\x20action:\x20\x22','/type/users\x0a\x20\x20\x20\x20','/\x20quit\x20/\x20Ctrl+C','--username','username','\x20\x20after\x20sync.\x20Duplicate\x20names\x20will\x20surface\x20as\x20ambiguous\x20logins\x20to\x20clean\x20up.','dynamic','\x0a\x20\x20okdb\x20—\x20standalone\x20OKDB\x20server\x0a\x0a\x20\x20Usage:\x0a\x20\x20\x20\x20okdb\x20[options]\x0a\x20\x20\x20\x20okdb\x20<command>\x0a\x0a\x20\x20Options:\x0a\x20\x20\x20\x20-p,\x20--port\x20<port>\x20\x20\x20\x20\x20\x20\x20\x20HTTP\x20port\x20(default:\x208484)\x0a\x20\x20\x20\x20-d,\x20--path\x20<dir>\x20\x20\x20\x20\x20\x20\x20\x20\x20Database\x20directory\x20(default:\x20./okdb-data)\x0a\x20\x20\x20\x20-k,\x20--key\x20\x20<secret>\x20\x20\x20\x20\x20\x20Encryption\x20key\x20for\x20data\x20at\x20rest\x0a\x20\x20\x20\x20-c,\x20--config\x20<file>\x20\x20\x20\x20\x20\x20Config\x20file\x20path\x20(default:\x20.kdbconfig)\x0a\x20\x20\x20\x20\x20\x20\x20\x20--log-level\x20<level>\x20\x20Log\x20level:\x20debug\x20|\x20info\x20|\x20warn\x20|\x20error\x20(default:\x20info)\x0a\x20\x20\x20\x20\x20\x20\x20\x20--no-repl\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Start\x20server\x20without\x20interactive\x20shell\x0a\x20\x20\x20\x20\x20\x20\x20\x20--no-admin\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Disable\x20admin\x20UI\x0a\x20\x20\x20\x20\x20\x20\x20\x20--open\x20[ip\x20...]\x20\x20\x20\x20\x20\x20Open\x20mode:\x20bypass\x20auth\x20for\x20listed\x20IPs\x20(default:\x20localhost).\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Examples:\x20--open\x20\x20--open\x20192.168.1.0/24\x20\x20--open\x20*\x0a\x20\x20\x20\x20\x20\x20\x20\x20--log-requests\x20\x20\x20\x20\x20\x20\x20Print\x20every\x20HTTP\x20request\x20to\x20stdout\x20(for\x20debugging)\x0a\x20\x20\x20\x20-v,\x20--version\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Print\x20version\x20and\x20exit\x0a\x20\x20\x20\x20-h,\x20--help\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Show\x20this\x20help\x0a\x0a\x20\x20Commands:\x0a\x20\x20\x20\x20version\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Print\x20version\x20and\x20exit\x0a\x20\x20\x20\x20doctor\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Run\x20health\x20checks\x0a\x20\x20\x20\x20init\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Create\x20.kdbconfig\x20and\x20okdb-data/\x0a\x20\x20\x20\x20token\x20create\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Create\x20a\x20token\x20in\x20the\x20local\x20DB\x20(direct\x20access,\x20no\x20HTTP)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--name\x20<name>\x20\x20\x20\x20\x20\x20For\x20password\x20login\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--password\x20<pass>\x20\x20Password\x20(requires\x20--name)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--label\x20<text>\x20\x20\x20\x20\x20Human\x20description\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--permissions\x20<l>\x20\x20Comma-separated\x20baseline\x20permissions\x20(e.g.\x20\x22*\x22\x20or\x20\x22data:read\x22)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--grants\x20<json>\x20\x20\x20\x20Per-env\x20grants\x20as\x20JSON\x20(e.g.\x20\x27{\x22orders\x22:[\x22data:*\x22]}\x27)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--ttl\x20<ms>\x20\x20\x20\x20\x20\x20\x20\x20\x20Optional\x20TTL\x20in\x20milliseconds\x0a\x20\x20\x20\x20token\x20list\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20List\x20all\x20tokens\x20in\x20the\x20local\x20DB\x0a\x20\x20\x20\x20token\x20revoke\x20<id>\x20\x20\x20\x20\x20\x20\x20\x20Revoke\x20(delete)\x20a\x20token\x20by\x20id\x20(full\x20uuid\x20or\x20unique\x20prefix)\x0a\x20\x20\x20\x20join\x20<address>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Join\x20an\x20existing\x20cluster\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--token\x20<t>\x20\x20\x20\x20\x20\x20\x20\x20Bearer\x20token\x20from\x20the\x20cluster\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--username\x20<u>\x20\x20\x20\x20\x20Or,\x20username\x20for\x20login\x20exchange\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--password\x20<p>\x20\x20\x20\x20\x20Password\x20for\x20login\x20exchange\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--address\x20<addr>\x20\x20\x20This\x20node\x27s\x20reachable\x20sync\x20address\x20(required)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--path\x20<dir>\x20\x20\x20\x20\x20\x20\x20Local\x20DB\x20path\x0a\x20\x20\x20\x20backup\x20[dir]\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Hot\x20filesystem\x20backup\x20via\x20LMDB\x20native\x20copy\x20(default:\x20./okdb-backup)\x0a\x20\x20\x20\x20export\x20<file>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Streaming\x20NDJSON\x20logical\x20export\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--env\x20<name>\x20\x20\x20\x20\x20\x20env\x20to\x20export\x20(default:\x20default)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--types\x20<a,b,...>\x20comma-separated\x20type\x20filter\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--changes\x20\x20\x20\x20\x20\x20\x20\x20\x20include\x20changelog\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--blobs\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20also\x20export\x20blob\x20files\x20alongside\x0a\x20\x20\x20\x20import\x20<file>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Streaming\x20NDJSON\x20logical\x20import\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--env\x20<name>\x20\x20\x20\x20\x20\x20target\x20env\x20override\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--types\x20<a,b,...>\x20import\x20only\x20these\x20types\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--drop\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20drop\x20&\x20recreate\x20existing\x20types\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--changes\x20\x20\x20\x20\x20\x20\x20\x20\x20restore\x20changelog\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20--blobs\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20also\x20import\x20blob\x20files\x20alongside\x0a\x20\x20\x20\x20reset\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Delete\x20and\x20recreate\x20database\x20(with\x20confirmation)\x0a\x20\x20\x20\x20license\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20List\x20stored\x20licenses,\x20current\x20tier,\x20and\x20usage\x0a\x20\x20\x20\x20license\x20<blob|path>\x20\x20\x20\x20\x20\x20Add\x20a\x20license\x20blob\x20(or\x20read\x20from\x20a\x20.license\x20file)\x0a\x20\x20\x20\x20license\x20<activation>\x20\x20\x20\x20\x20Activate\x20a\x20previously-added\x20license\x20with\x20the\x20vendor\x27s\x20token\x0a\x20\x20\x20\x20license\x20<id>\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Show\x20details\x20for\x20one\x20stored\x20license\x20(by\x20uuid\x20or\x20prefix)\x0a\x20\x20\x20\x20license\x20remove\x20<id>\x20\x20\x20\x20\x20\x20Remove\x20a\x20stored\x20license\x0a\x0a\x20\x20Environment\x20variables:\x0a\x20\x20\x20\x20OKDB_PORT\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20HTTP\x20port\x0a\x20\x20\x20\x20OKDB_PATH\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Database\x20directory\x0a\x20\x20\x20\x20OKDB_LOG_LEVEL\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Log\x20level\x20(debug|info|warn|error)\x0a\x20\x20\x20\x20OKDB_KEY\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Encryption\x20key\x0a\x20\x20\x20\x20OKDB_NO_REPL=1\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Disable\x20REPL\x0a\x20\x20\x20\x20OKDB_NO_ADMIN=1\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Disable\x20admin\x20UI\x0a\x0a\x20\x20Config\x20file\x20(.kdbconfig)\x20—\x20JSON,\x20all\x20keys\x20optional:\x0a\x20\x20\x20\x20{\x0a\x20\x20\x20\x20\x20\x20\x22port\x22:\x20\x20\x20\x20\x208484,\x0a\x20\x20\x20\x20\x20\x20\x22path\x22:\x20\x20\x20\x20\x20\x22./okdb-data\x22,\x0a\x20\x20\x20\x20\x20\x20\x22key\x22:\x20\x20\x20\x20\x20\x20\x22...\x22,\x0a\x20\x20\x20\x20\x20\x20\x22logLevel\x22:\x20\x22info\x22,\x0a\x20\x20\x20\x20\x20\x20\x22noAdmin\x22:\x20\x20false,\x0a\x20\x20\x20\x20\x20\x20\x22noRepl\x22:\x20\x20\x20false,\x0a\x20\x20\x20\x20\x20\x20\x22auth\x22:\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x22open\x22:\x20false\x0a\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20}\x0a\x0a\x20\x20Examples:\x0a\x20\x20\x20\x20okdb\x0a\x20\x20\x20\x20okdb\x20--port\x209000\x20--path\x20./mydb\x0a\x20\x20\x20\x20okdb\x20--no-repl\x20--port\x208080\x0a\x20\x20\x20\x20okdb\x20--open\x0a\x20\x20\x20\x20okdb\x20--open\x20192.168.1.0/24\x0a\x20\x20\x20\x20okdb\x20doctor\x0a\x20\x20\x20\x20okdb\x20backup\x20./my-backup\x0a','\x0a\x20\x20','createServer','\x20\x20\x20\x20port:\x20\x20','OKDBNotFoundError','decodeLicenseBlob','object','_ensureTokensType','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','address','sourceType','ENV','Shutting\x20down\x20due\x20to\x20license\x20expiry','[env]','HELP','9762rToPJB','base64url','Embeddings','min','ROUTES','--drop','SCHEMA_VALIDATION_FAILED','okdb.pid','toFixed','default','0123456789ABCDEFGHJKMNPQRSTVWXYZ','error','node\x20','write','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/envs\x0a\x20\x20\x20\x20','node','\x20\x20(licensee:\x20','warn','version','PUB_FINGERPRINT','scrypt','forEach','_licenseHash','\x0a\x20\x20Run\x20okdb\x20to\x20start\x20the\x20server.\x0a','7145gVvIDd','\x20\x20\x20\x20status:\x20\x20\x20\x20active','\x20\x20[','Invalid\x20primary\x20key\x20type:\x20','_computeStatus','expiresAt','syncPeers','\x20document(s)\x20reference\x20it\x20with\x20onDelete:restrict','kind','fts:registered','status','index:registered','port','peers=','/types\x0a\x20\x20\x20\x20','decodeActivationToken','\x20\x20\x20\x20envs:\x20\x20\x20\x20\x20\x20','OKDBTypeNotRegisteredError','features','floor','Invalid\x20activation\x20token:\x20','recheck','payload','removeLicense','ftsName','OKDBAlreadyExistsError','License\x20limit\x20exceeded:\x20','%),\x20','licenseHash','key','writeFileSync','charCodeAt','current','body:\x20','waiting','/api','\x20\x20✓\x20','\x20\x20✓\x20OKDB\x20server\x20running','blobs','ttl:set','\x20licenses','listRoutes','exp','.\x20Add\x20a\x20license\x20that\x20includes\x20\x22','\x20\x20✓\x20http\x20listening\x20on\x20:','\x20deleted','--log-requests','white','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/env/','grants','verify','OKDB-PIN-V1:','fts','\x20\x20Error:\x20','\x20\x20Usage:','../okdb','\x20\x20http://localhost:','call','LICENSE_EXPIRED_ACTION','Admin','parse','\x27\x20is\x20already\x20registered','remove','\x20\x20changes=','OKDBForeignKeyDeleteError','okdb','Invalid\x20index\x20key\x20type\x20for\x20\x27','from','STATUS','--env\x20<name>','magenta','exec','line','OKDBError','reload','sourceKey','\x20\x20\x20\x20•\x20a\x20license\x20id\x20\x20\x20\x20\x20(uuid)','fieldPath','types','platform','net','\x20\x20(name:\x20','Examples','system:bus_state_change','\x20\x20\x20\x20admin:\x20http://localhost:','help','\x20\x20\x20\x20addedAt:\x20\x20\x20','index:ready','[okdb]\x20error:\x20join\x20requires\x20credentials.\x20Provide\x20--token\x20<t>\x20or\x20--username\x20<u>\x20--password\x20<p>','\x0a\x20\x20No\x20routes\x20matching\x20\x22','hex','revoke','get','../','--version','\x0a\x20\x20okdb\x20doctor\x0a','\x20references\x20','OKDBSchemaValidationError','bind','[okdb]\x20error:\x20revoke\x20requires\x20an\x20id\x20argument','unknown','\x20\x20records=','\x20\x20Usage:\x20logs\x20[on|off|debug|info|warn|error]','\x20\x20Usage:\x20okdb\x20license\x20[<blob|path|uuid|activation-token>]','[okdb]\x20error:\x20join\x20requires\x20a\x20remote\x20address.\x20Usage:\x20okdb\x20join\x20<address>\x20--token\x20<t>','issuedAt','replace','[on|off|level]','LICENSE_HASH_MISMATCH','OKDBTypeAlreadyRegisteredError','isArray','license:invalid','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20→\x20GET\x20/api/info\x0a\x20\x20\x20\x20','PIN','\x22\x20to\x20enable\x20it.','\x20\x20Expected\x20one\x20of:','blob','copy','toUpperCase','OPEN','attach','[okdb]\x20export\x20complete','--grants','txn:start','effective','<path>','\x20\x20skipped=','\x20\x20Next\x20step\x20—\x20activate\x20the\x20license:','dropping','writes=','toLowerCase','\x20\x20\x20\x20\x20\x20\x20\x20\x20OKDB\x20SHELL\x20\x20\x20\x20\x20\x20\x20\x20\x20','existsSync','method','index:reset','\x0a\x20\x20✓\x20License\x20added','{}[]:,\x27\x22','off','108657BrNJYo','\x20\x20⚠\x20\x20','(unset)','assertLimit','\x20which\x20does\x20not\x20exist','\x20\x20score:','Build\x20expects\x20public\x20key\x20fingerprint\x20','limits','clearLine','[okdb]\x20exporting\x20blobs…','sha256','INDEX_HAS_CONSUMERS','message','timeMachine','SIG_INVALID','dropIndex','\x20\x20\x20\x20id:\x20\x20\x20\x20\x20\x20\x20\x20','backup','No\x20license\x20found\x20matching\x20this\x20activation\x20token','\x0a[okdb]\x20fatal\x20error:','system:poke','--label','sizeAfter','Schema\x20validation\x20failed\x20for\x20','gray','[okdb]\x20error:\x20--address\x20is\x20required\x20for\x20join\x20(this\x20node\x27s\x20reachable\x20sync\x20address).\x0a','toISOString','getSecurityNotices','name','logs','env/','start\x20','INVALID_VALUE','dropFts','[okdb]\x20reset:\x20','\x20\x20\x20\x20id:\x20\x20\x20\x20','176uhfPTu','max','\x20\x20\x20\x20usage:\x20\x20\x20','changes','resume','Events','\x20does\x20not\x20exist','PERMISSIONS','update','\x20\x20\x20\x20id:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','~licenses',')\x20to\x20your\x20license\x20vendor.','\x20to\x20quit.','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20show\x20API\x20docs\x20for\x20a\x20path\x0a\x0a\x20\x20','stopped','\x20\x20\x20\x203.\x20Run:\x20\x20okdb\x20license\x20<activation-token>','columns','\x20<path>\x20[json-body]','hidden','\x20writes\x20(','exports','408ffFfjL','active','\x0a\x20\x20✓\x20License\x20activated','export','_lookupByName','code','join','close','pid','\x20records','creating','resetFts','[okdb]\x20reset\x20aborted','\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20override\x20active\x20environment\x20for\x20this\x20call\x0a\x20\x20','config\x20file\x20valid:\x20','body','/admin/index.html'];_0x52d5=function(){return _0x14c759;};return _0x52d5();}var okdbEnums,hasRequiredOkdbEnums;function requireOkdbEnums(){const _0x35ca51=_0x538f61;if(hasRequiredOkdbEnums)return okdbEnums;hasRequiredOkdbEnums=0x1;const _0x56cd79={'PUT':'put','REMOVE':_0x35ca51(0x24d),'INDEX_DROP':_0x35ca51(0x2a8),'INDEX_REGISTER':_0x35ca51(0x49e),'INDEX_RESET':_0x35ca51(0x382),'TYPE_REGISTER':_0x35ca51(0x350),'TYPE_DROP':'dropType','FTS_REGISTER':'registerFts','FTS_DROP':_0x35ca51(0x2ba),'FTS_RESET':_0x35ca51(0x2dd),'SCHEMA_SET':_0x35ca51(0x3fb),'SCHEMA_DROP':_0x35ca51(0x392),'TTL_SET':'setTtl','TTL_CLEAR':_0x35ca51(0x3e1)},_0x54eeee={'SYSTEM_READY':'system:ready','SYSTEM_STOPPED':'system:stopped','SYSTEM_CLOCK_CHANGE':'system:clock_change','SYSTEM_POKE':_0x35ca51(0x2ad),'SYSTEM_DRAIN':_0x35ca51(0x3ce),'SYSTEM_BUS_STATE_CHANGE':_0x35ca51(0x262),'ITEM_CREATE':_0x35ca51(0x455),'ITEM_UPDATE':_0x35ca51(0x393),'ITEM_REMOVE':_0x35ca51(0x453),'INDEX_RESET':_0x35ca51(0x295),'INDEX_READY':_0x35ca51(0x266),'INDEX_PROGRESS':_0x35ca51(0x2fd),'INDEX_DROP':'index:drop','INDEX_REGISTERED':_0x35ca51(0x21a),'FTS_REGISTERED':_0x35ca51(0x218),'FTS_DROP':_0x35ca51(0x46d),'FTS_RESET':'fts:reset','SCHEMA_SET':_0x35ca51(0x365),'SCHEMA_DROP':_0x35ca51(0x3dd),'UNIQUE_VIOLATION':_0x35ca51(0x345),'UNIQUE_VIOLATION_RESOLVED':'unique:violation_resolved','REF_VIOLATION':_0x35ca51(0x43a),'REF_VIOLATION_RESOLVED':'ref:violation_resolved','SYNC_APPLY':_0x35ca51(0x1c5),'TXN_START':_0x35ca51(0x28a),'TXN_END':_0x35ca51(0x465),'TXN_ROLLBACK':_0x35ca51(0x49c),'TYPE_REGISTERED':'type:registered','TYPE_DROP':_0x35ca51(0x1de),'ENV_OPENED':_0x35ca51(0x3d4),'ENV_REMOVED':_0x35ca51(0x37c),'TTL_EXPIRED':'ttl:expired','TTL_SET':_0x35ca51(0x236),'TTL_CLEAR':_0x35ca51(0x4a9),'LICENSE_INVALID':_0x35ca51(0x27e),'LICENSE_ADDED':'license:added','LICENSE_ACTIVATED':_0x35ca51(0x3d2),'LICENSE_REMOVED':'license:removed'},_0x3ae819={'CREATING':_0x35ca51(0x2dc),'RESETTING':'resetting','READY':'ready','DROPPING':_0x35ca51(0x28f),'WAITING':_0x35ca51(0x231)},_0x317076={'CREATED':_0x35ca51(0x374),'STARTING':_0x35ca51(0x36a),'STARTED':_0x35ca51(0x45b),'STOPPING':_0x35ca51(0x32f),'STOPPED':_0x35ca51(0x2cb)},_0x174cbb={'CREATING':'creating','READY':_0x35ca51(0x3b4),'HALTED':_0x35ca51(0x333),'STOPPED':_0x35ca51(0x2cb),'RESETTING':_0x35ca51(0x461)},_0x3efcde=Object['freeze']({'POKE':'bus:poke','DRAIN':'bus:drain'});return okdbEnums={'BUS_EVENTS':_0x3efcde,'CHANGE_ACTIONS':_0x56cd79,'EVENTS':_0x54eeee,'INDEX_STATE':_0x3ae819,'OKDB_STATE':_0x317076,'VIEW_STATE':_0x174cbb},okdbEnums;}var okdbPubkey,hasRequiredOkdbPubkey;function requireOkdbPubkey(){const _0x3840e5=_0x538f61;if(hasRequiredOkdbPubkey)return okdbPubkey;hasRequiredOkdbPubkey=0x1;const _0x2f8173=require$$1,_0x387840=require$$1$1,_0x507ae9=require$$0,_0x2ebb80=_0x2f8173[_0x3840e5(0x389)](_0x387840[_0x3840e5(0x2d8)](__dirname,_0x3840e5(0x340)),'utf8')[_0x3840e5(0x34d)](),_0x2e44c6=_0x507ae9['createPublicKey'](_0x2ebb80)[_0x3840e5(0x2d5)]({'type':'spki','format':_0x3840e5(0x41d)}),_0x9447b8=_0x507ae9['createHash']('sha256')[_0x3840e5(0x2c5)](_0x2e44c6)[_0x3840e5(0x1dc)]('hex')['slice'](0x0,0x10);return okdbPubkey={'PUBLIC_KEY_PEM':_0x2ebb80,'PUB_FINGERPRINT':_0x9447b8},okdbPubkey;}var okdbLicense,hasRequiredOkdbLicense;function requireOkdbLicense(){const _0x37793d=_0x538f61;if(hasRequiredOkdbLicense)return okdbLicense;hasRequiredOkdbLicense=0x1;const _0x5cb370=require$$0,{OKDBError:_0x38e550}=requireOkdbError(),{EVENTS:_0x4a8f0a}=requireOkdbEnums(),_0x1fceda=requireOkdbLicenseCodec(),{LICENSE_TYPE_OPEN:_0x77d9f7,LICENSE_TYPE_INTERNAL:_0x3fbe5e,OPEN_LICENSE_MAX_DURATION_MS:_0x3f50e8}=_0x1fceda,_0x3efc81=requireOkdbPubkey(),_0x3c83ec={'LICENSED_BUILD':_0x37793d(0x422),'PUBLIC_KEY_PEM':_0x3efc81[_0x37793d(0x1be)],'PUB_FINGERPRINT':_0x3efc81[_0x37793d(0x20a)],'LICENSE_EXPIRED_ACTION':_0x37793d(0x499)},_0xec6d73=_0x37793d(0x2c7),_0x363ba3={'features':{'sync':![],'embeddings':![],'engines':![],'fts':!![],'timeMachine':![],'views':!![],'mcp':!![],'files':!![]},'limits':{'envs':0x2,'typesPerEnv':0xa,'syncPeers':0x0,'maxWrites':0xf4240},'_isFree':!![]};async function _0x289463(_0x384b85){const _0x931f5c=_0x37793d;!_0x384b85[_0x931f5c(0x3d7)](_0xec6d73)&&await _0x384b85[_0x931f5c(0x350)](_0xec6d73);}class _0x32dc0f{constructor(_0x2f2cdd){const _0x229282=_0x37793d;this[_0x229282(0x250)]=_0x2f2cdd,this[_0x229282(0x2fe)]=null;}async[_0x37793d(0x259)](){const _0xcdde66=_0x37793d,_0x46504c=this[_0xcdde66(0x250)][_0xcdde66(0x30f)];if(!_0x46504c||!_0x46504c[_0xcdde66(0x3d7)](_0xec6d73)){this[_0xcdde66(0x2fe)]=null;return;}const _0x22e7af=this[_0xcdde66(0x250)]['id'];let _0x633167=null;for(const {key:_0x224398,value:_0xf9f5c2}of _0x46504c['getRange'](_0xec6d73)){const _0x404579=this[_0xcdde66(0x213)](_0xf9f5c2,_0x22e7af);_0x404579===_0xcdde66(0x2d3)&&!_0x633167&&(_0x633167={..._0xf9f5c2,'id':_0x224398,'status':_0x404579});}this[_0xcdde66(0x2fe)]=_0x633167;if(this[_0xcdde66(0x2fe)]&&this['_active'][_0xcdde66(0x396)]===_0x77d9f7){const _0x4c28e4=Math['ceil']((this[_0xcdde66(0x2fe)][_0xcdde66(0x214)]-Date[_0xcdde66(0x311)]())/0x5265c00);this[_0xcdde66(0x250)][_0xcdde66(0x499)]?.[_0xcdde66(0x208)](_0xcdde66(0x2eb)+_0x4c28e4+'\x20day(s).',{'feature':_0xcdde66(0x1c7),'licensee':this['_active'][_0xcdde66(0x1ca)],'expiresAt':new Date(this[_0xcdde66(0x2fe)][_0xcdde66(0x214)])['toISOString']()});}this['_active']&&this[_0xcdde66(0x2fe)][_0xcdde66(0x396)]===_0x3fbe5e&&this[_0xcdde66(0x250)][_0xcdde66(0x499)]?.['warn'](_0xcdde66(0x3e5),{'feature':_0xcdde66(0x1c7),'licensee':this[_0xcdde66(0x2fe)][_0xcdde66(0x1ca)]});}[_0x37793d(0x213)](_0x495dc2,_0x5a89d6){const _0x836b9a=_0x37793d;if(!_0x495dc2[_0x836b9a(0x283)])return _0x836b9a(0x38f);let _0x4f922a;try{_0x4f922a=_0x1fceda[_0x836b9a(0x1ed)](_0x495dc2[_0x836b9a(0x283)]);}catch(_0x9dec2c){return _0x836b9a(0x38f);}try{const _0x4dd68b=_0x5cb370[_0x836b9a(0x241)](null,_0x4f922a[_0x836b9a(0x225)],_0x3c83ec[_0x836b9a(0x1be)],_0x4f922a['sig']);if(!_0x4dd68b)return _0x836b9a(0x38f);}catch(_0x1ff1c9){return _0x836b9a(0x38f);}if(_0x4f922a['decoded']['licenseType']===_0x3fbe5e)return _0x836b9a(0x2d3);if(_0x4f922a[_0x836b9a(0x2e5)][_0x836b9a(0x214)]<=Date[_0x836b9a(0x311)]())return _0x836b9a(0x4aa);if(_0x4f922a[_0x836b9a(0x2e5)][_0x836b9a(0x396)]===_0x77d9f7)return'active';if(!_0x495dc2[_0x836b9a(0x3a9)])return _0x836b9a(0x363);const _0x5f49c=_0x1fceda[_0x836b9a(0x304)]({'tokenString':_0x495dc2[_0x836b9a(0x3a9)],'nodeId':_0x5a89d6,'rawBlobBuf':_0x4f922a['rawBuf'],'pubKeyPem':_0x3c83ec['PUBLIC_KEY_PEM'],'pubFingerprint':_0x3c83ec[_0x836b9a(0x20a)]});if(_0x5f49c['reason']===_0x836b9a(0x27b)||_0x5f49c['reason']==='SIG_INVALID')return _0x836b9a(0x2f1);if(_0x5f49c[_0x836b9a(0x40c)]===_0x836b9a(0x34a))return'expired';if(!_0x5f49c[_0x836b9a(0x360)])return _0x836b9a(0x2f1);return'active';}get[_0x37793d(0x2d3)](){const _0x4ce159=_0x37793d;return this[_0x4ce159(0x2fe)];}get[_0x37793d(0x28b)](){const _0x4b64a1=_0x37793d;return this[_0x4b64a1(0x2fe)]??_0x363ba3;}['assertFeature'](_0x1ccbcb){const _0x4e6d7b=_0x37793d;if(_0x3c83ec[_0x4e6d7b(0x3e4)]!==_0x4e6d7b(0x422))return;const _0x1b515e=this[_0x4e6d7b(0x28b)];if(!_0x1b515e[_0x4e6d7b(0x221)]?.[_0x1ccbcb]){const _0xe682a=_0x1b515e[_0x4e6d7b(0x30e)]?_0x4e6d7b(0x419)+_0x1ccbcb+_0x4e6d7b(0x23a)+_0x1ccbcb+_0x4e6d7b(0x281):'Feature\x20not\x20licensed:\x20'+_0x1ccbcb+_0x4e6d7b(0x3ba)+_0x1ccbcb+'\x22.';throw new _0x38e550(_0xe682a,'LICENSE_FEATURE_DISABLED',{'feature':_0x1ccbcb});}}['isFeatureEnabled'](_0x54d732){const _0xe0e8d=_0x37793d;if(_0x3c83ec[_0xe0e8d(0x3e4)]!==_0xe0e8d(0x422))return!![];return!!this[_0xe0e8d(0x28b)][_0xe0e8d(0x221)]?.[_0x54d732];}[_0x37793d(0x29c)](_0x293239,_0x1dda75){const _0x80fb9c=_0x37793d;if(_0x3c83ec[_0x80fb9c(0x3e4)]!=='true')return;const _0x506120=this['effective'],_0x1cf8d1=_0x506120['limits']?.[_0x293239];if(_0x1cf8d1===null||_0x1cf8d1===undefined||_0x1cf8d1===0x0)return;if(_0x1dda75>=_0x1cf8d1)throw new _0x38e550(_0x80fb9c(0x229)+_0x293239+'\x20('+_0x1dda75+'/'+_0x1cf8d1+')','LICENSE_LIMIT_EXCEEDED',{'limit':_0x293239,'current':_0x1dda75,'max':_0x1cf8d1});}async[_0x37793d(0x334)](_0x4ac15c){const _0x401dcb=_0x37793d;let _0x1cd274;try{_0x1cd274=_0x1fceda['decodeLicenseBlob'](_0x4ac15c);}catch(_0x5080c7){throw new _0x38e550(_0x401dcb(0x4a5)+_0x5080c7[_0x401dcb(0x2a5)],_0x401dcb(0x403));}let _0x35d1dc;try{_0x35d1dc=_0x5cb370[_0x401dcb(0x241)](null,_0x1cd274[_0x401dcb(0x225)],_0x3c83ec[_0x401dcb(0x1be)],_0x1cd274[_0x401dcb(0x487)]);}catch(_0x729099){throw new _0x38e550(_0x401dcb(0x4af)+_0x729099[_0x401dcb(0x2a5)],_0x401dcb(0x403));}if(!_0x35d1dc)throw new _0x38e550(_0x401dcb(0x442)+(_0x401dcb(0x29f)+_0x3c83ec[_0x401dcb(0x20a)]+'.\x20')+_0x401dcb(0x471),_0x401dcb(0x403),{'expectedFingerprint':_0x3c83ec[_0x401dcb(0x20a)]});if(_0x1cd274['decoded'][_0x401dcb(0x396)]===_0x77d9f7){const _0x263269=_0x1cd274[_0x401dcb(0x2e5)][_0x401dcb(0x214)]-_0x1cd274[_0x401dcb(0x2e5)][_0x401dcb(0x278)];if(_0x263269>_0x3f50e8)throw new _0x38e550(_0x401dcb(0x2e6)+Math[_0x401dcb(0x2f5)](_0x263269/(0x1e*0x5265c00))+'\x20months\x20from\x20issuance)',_0x401dcb(0x403));}const _0x3d3951=this[_0x401dcb(0x250)][_0x401dcb(0x30f)];await _0x289463(_0x3d3951);const _0x4d198f=_0x1fceda['licenseHash'](_0x1cd274[_0x401dcb(0x38b)])[_0x401dcb(0x449)]('hex');for(const {value:_0xb330c9}of _0x3d3951[_0x401dcb(0x2ee)](_0xec6d73)){if(_0xb330c9['_licenseHash']===_0x4d198f)throw new _0x38e550('License\x20already\x20stored',_0x401dcb(0x403));}const _0x361483=_0x5cb370[_0x401dcb(0x469)](),_0x701a5b={'blob':_0x4ac15c,'activation':null,'addedAt':Date['now'](),'_licenseHash':_0x4d198f,'licensee':_0x1cd274[_0x401dcb(0x2e5)][_0x401dcb(0x1ca)],'expiresAt':_0x1cd274[_0x401dcb(0x2e5)]['expiresAt'],'features':_0x1cd274[_0x401dcb(0x2e5)][_0x401dcb(0x221)],'limits':_0x1cd274[_0x401dcb(0x2e5)][_0x401dcb(0x2a0)],'licenseType':_0x1cd274[_0x401dcb(0x2e5)][_0x401dcb(0x396)]};return await _0x3d3951[_0x401dcb(0x1c3)](_0xec6d73,_0x361483,_0x701a5b),{'id':_0x361483,..._0x701a5b};}async[_0x37793d(0x1b2)](_0xd78c94){const _0x2e3b2f=_0x37793d;let _0x1f3521;try{_0x1f3521=_0x1fceda[_0x2e3b2f(0x21e)](_0xd78c94);}catch(_0x4968e8){throw new _0x38e550(_0x2e3b2f(0x223)+_0x4968e8[_0x2e3b2f(0x2a5)],_0x2e3b2f(0x1d2));}const _0x537ff7=_0x1f3521['licenseHash']['toString'](_0x2e3b2f(0x269)),_0x4aebcc=this['okdb']['_systemEnv'];if(!_0x4aebcc||!_0x4aebcc[_0x2e3b2f(0x3d7)](_0xec6d73))throw new _0x38e550('No\x20license\x20found\x20matching\x20this\x20activation\x20token',_0x2e3b2f(0x1d2));let _0x38a680=null,_0x1ed161=null;for(const {key:_0x40cd67,value:_0x59d47d}of _0x4aebcc[_0x2e3b2f(0x2ee)](_0xec6d73)){if(_0x59d47d[_0x2e3b2f(0x20d)]===_0x537ff7){_0x38a680=_0x40cd67,_0x1ed161=_0x59d47d;break;}}if(!_0x38a680)throw new _0x38e550(_0x2e3b2f(0x2ab),_0x2e3b2f(0x1d2));const {rawBuf:_0x15505c}=_0x1fceda[_0x2e3b2f(0x1ed)](_0x1ed161[_0x2e3b2f(0x283)]),_0x21f0da=_0x1fceda[_0x2e3b2f(0x304)]({'tokenString':_0xd78c94,'nodeId':this[_0x2e3b2f(0x250)]['id'],'rawBlobBuf':_0x15505c,'pubKeyPem':_0x3c83ec[_0x2e3b2f(0x1be)],'pubFingerprint':_0x3c83ec[_0x2e3b2f(0x20a)]});if(!_0x21f0da[_0x2e3b2f(0x360)])throw new _0x38e550(_0x2e3b2f(0x342)+_0x21f0da[_0x2e3b2f(0x40c)],'LICENSE_ACTIVATION_INVALID',{'reason':_0x21f0da['reason']});const _0x4e2ed8={..._0x1ed161,'activation':_0xd78c94};return await _0x4aebcc[_0x2e3b2f(0x2c5)](_0xec6d73,_0x38a680,_0x4e2ed8),{'id':_0x38a680,..._0x4e2ed8};}async[_0x37793d(0x226)](_0x45db79){const _0x178bcc=_0x37793d,_0x4260fe=this[_0x178bcc(0x250)][_0x178bcc(0x30f)];if(!_0x4260fe||!_0x4260fe[_0x178bcc(0x3d7)](_0xec6d73))return;await _0x4260fe[_0x178bcc(0x24d)](_0xec6d73,_0x45db79);}async['listLicenses'](){const _0x3734fe=_0x37793d,_0x2bff29=this[_0x3734fe(0x250)][_0x3734fe(0x30f)];if(!_0x2bff29||!_0x2bff29[_0x3734fe(0x3d7)](_0xec6d73))return[];const _0x16272f=this[_0x3734fe(0x250)]['id'],_0x582af1=[];for(const {key:_0x178eba,value:_0x3552df}of _0x2bff29[_0x3734fe(0x2ee)](_0xec6d73)){const _0x3406c3=this[_0x3734fe(0x213)](_0x3552df,_0x16272f);_0x582af1[_0x3734fe(0x488)]({..._0x3552df,'id':_0x178eba,'status':_0x3406c3});}return _0x582af1;}[_0x37793d(0x32d)](){const _0x268837=_0x37793d,_0x1df827=this[_0x268837(0x250)][_0x268837(0x30f)];if(!_0x1df827||!_0x1df827[_0x268837(0x3d7)](_0xec6d73))return[];const _0x1d18e4=this['okdb']['id'],_0x1f7c33=[];for(const {key:_0x1d882a,value:_0x370d00}of _0x1df827['getRange'](_0xec6d73)){if(_0x370d00[_0x268837(0x20d)]){if(_0x370d00[_0x268837(0x396)]===_0x77d9f7)_0x1f7c33[_0x268837(0x488)]({'licenseId':_0x1d882a,'pin':null});else{const _0xe041f7=Buffer[_0x268837(0x252)](_0x370d00['_licenseHash'],_0x268837(0x269)),{pin:_0x4afc09}=_0x1fceda[_0x268837(0x33e)](_0x1d18e4,_0xe041f7,_0x3c83ec[_0x268837(0x20a)]);_0x1f7c33['push']({'licenseId':_0x1d882a,'pin':_0x4afc09});}}}return _0x1f7c33;}async[_0x37793d(0x224)](){const _0x5548ac=_0x37793d,_0x4bb2de=this[_0x5548ac(0x2fe)];await this[_0x5548ac(0x259)]();if(this[_0x5548ac(0x2fe)]&&this[_0x5548ac(0x2fe)][_0x5548ac(0x396)]===_0x77d9f7){const _0xede30e=Math['ceil']((this[_0x5548ac(0x2fe)][_0x5548ac(0x214)]-Date['now']())/0x5265c00);this[_0x5548ac(0x250)][_0x5548ac(0x499)]?.[_0x5548ac(0x208)]('⚠\x20OPEN\x20LICENSE\x20ACTIVE\x20—\x20this\x20license\x20is\x20not\x20node-bound\x20and\x20is\x20intended\x20for\x20POC/demo\x20use\x20only.\x20Expires\x20in\x20'+_0xede30e+_0x5548ac(0x354),{'feature':_0x5548ac(0x1c7),'licensee':this['_active'][_0x5548ac(0x1ca)],'expiresAt':new Date(this[_0x5548ac(0x2fe)]['expiresAt'])[_0x5548ac(0x2b3)]()});}this['_active']&&this['_active']['licenseType']===_0x3fbe5e&&this[_0x5548ac(0x250)]['log']?.[_0x5548ac(0x208)](_0x5548ac(0x3e5),{'feature':'license','licensee':this[_0x5548ac(0x2fe)][_0x5548ac(0x1ca)]});if(_0x4bb2de&&!this[_0x5548ac(0x2fe)]){this[_0x5548ac(0x250)][_0x5548ac(0x499)]?.[_0x5548ac(0x208)](_0x5548ac(0x34f),{'feature':_0x5548ac(0x1c7)}),this[_0x5548ac(0x250)]['events']?.['emit'](_0x4a8f0a[_0x5548ac(0x403)],{'previous':_0x4bb2de});const _0x5e471d=this['okdb'][_0x5548ac(0x47e)]?.[_0x5548ac(0x3c4)]??_0x3c83ec[_0x5548ac(0x249)];_0x5e471d===_0x5548ac(0x42d)&&(this[_0x5548ac(0x250)][_0x5548ac(0x499)]?.[_0x5548ac(0x202)](_0x5548ac(0x1f4),{'feature':_0x5548ac(0x1c7)}),this[_0x5548ac(0x250)][_0x5548ac(0x2d9)]()[_0x5548ac(0x3c7)](()=>{})[_0x5548ac(0x352)](()=>process[_0x5548ac(0x463)](0x1)));}}}return okdbLicense={'LicenseChecker':_0x32dc0f,'_C':_0x3c83ec},okdbLicense;}var okdbShell,hasRequiredOkdbShell;function requireOkdbShell(){const _0x3136f7=_0x538f61;if(hasRequiredOkdbShell)return okdbShell;hasRequiredOkdbShell=0x1;const _0x51b846=require$$0$2,_0x562786=require$$1,_0x5cfad5=require$$2$1,_0x4e8bf9=require$$1$1,_0x2aa2c7=_0x4e8bf9[_0x3136f7(0x2d8)](_0x5cfad5[_0x3136f7(0x3d6)](),_0x3136f7(0x381)),_0x22d439=0x3e8,_0x1d9d03={'reset':_0x3136f7(0x41e),'bold':'\x1b[1m','dim':_0x3136f7(0x3bb),'red':_0x3136f7(0x377),'green':_0x3136f7(0x47b),'yellow':_0x3136f7(0x3a1),'blue':_0x3136f7(0x317),'magenta':_0x3136f7(0x42c),'cyan':'\x1b[36m','white':'\x1b[37m','gray':'\x1b[90m'},_0x24264e=!process[_0x3136f7(0x313)][_0x3136f7(0x49a)]||!!process.env.NO_COLOR,_0x402df7=(_0x5b0a68,_0x19cdd3)=>_0x24264e?_0x19cdd3:''+_0x5b0a68+_0x19cdd3+_0x1d9d03['reset'],_0x4ab8de={'error':_0x1d9d03[_0x3136f7(0x4a0)],'warn':_0x1d9d03[_0x3136f7(0x2f7)],'info':_0x1d9d03[_0x3136f7(0x490)],'debug':_0x1d9d03['gray']},_0x124412={'debug':0x0,'info':0x1,'warn':0x2,'error':0x3};function _0x182a9b(_0x119075,_0x1bf44d=_0x3136f7(0x312)){const _0x2329c1=_0x3136f7,{level:_0x3cde2c,msg:_0x21b1c7,meta:_0x195755,context:_0x2365ed,ts:_0x1fecb1}=_0x119075;if((_0x124412[_0x3cde2c]??0x1)<(_0x124412[_0x1bf44d]??0x1))return;const _0x4a7e59=_0x402df7(_0x1d9d03[_0x2329c1(0x2b1)],new Date(_0x1fecb1)[_0x2329c1(0x2b3)]()),_0x15cd66=_0x402df7(_0x4ab8de[_0x3cde2c]??_0x1d9d03[_0x2329c1(0x23e)],_0x3cde2c[_0x2329c1(0x495)](0x5));let _0x28afb8='\x20\x20'+_0x4a7e59+'\x20'+_0x402df7(_0x1d9d03[_0x2329c1(0x416)],_0x15cd66)+'\x20'+_0x21b1c7;if(_0x195755&&Object[_0x2329c1(0x3fd)](_0x195755)['length']>0x0){const _0x24e0ed=Object[_0x2329c1(0x3f8)](_0x195755)[_0x2329c1(0x308)](([_0x372324,_0x6a6297])=>_0x372324+'='+_0x6a6297)[_0x2329c1(0x2d8)]('\x20');_0x28afb8+=_0x402df7(_0x1d9d03['dim'],_0x2329c1(0x211)+_0x24e0ed+']');}if(_0x2365ed!==undefined){const _0x2b002d=typeof _0x2365ed===_0x2329c1(0x1ee)?JSON['stringify'](_0x2365ed):String(_0x2365ed);_0x28afb8+=_0x402df7(_0x1d9d03[_0x2329c1(0x3c6)],'\x20\x20'+_0x2b002d);}const _0xcc038d=_0x3cde2c===_0x2329c1(0x202)||_0x3cde2c===_0x2329c1(0x208)?process['stderr'][_0x2329c1(0x204)][_0x2329c1(0x271)](process['stderr']):process[_0x2329c1(0x313)][_0x2329c1(0x204)]['bind'](process[_0x2329c1(0x313)]);_0xcc038d(_0x28afb8+'\x0a');}function _0x4f316f(_0x4fcb90,_0x50e5d3){const _0x31d47b=_0x3136f7;if(_0x4fcb90===0xcc||_0x4fcb90>=0xc8&&_0x4fcb90<0x12c&&!_0x50e5d3){console[_0x31d47b(0x499)](_0x31d47b(0x1e9)+_0x402df7(_0x1d9d03[_0x31d47b(0x46f)],'✓')+'\x0a');return;}if(_0x4fcb90>=0x190||_0x50e5d3?.[_0x31d47b(0x202)]){const _0xae59dd=_0x50e5d3?.[_0x31d47b(0x202)]??_0x50e5d3?.[_0x31d47b(0x2a5)]??'HTTP\x20'+_0x4fcb90;console[_0x31d47b(0x499)]('\x0a\x20\x20'+_0x402df7(_0x1d9d03[_0x31d47b(0x4a0)],'✗')+'\x20'+_0x402df7(_0x1d9d03[_0x31d47b(0x416)]+_0x1d9d03[_0x31d47b(0x4a0)],String(_0x4fcb90))+'\x20\x20'+_0xae59dd+'\x0a');return;}const _0x5063ed=Object[_0x31d47b(0x376)][_0x31d47b(0x48d)][_0x31d47b(0x248)](_0x50e5d3??{},_0x31d47b(0x1b8))?_0x50e5d3[_0x31d47b(0x1b8)]:_0x50e5d3,_0x1bbfd1=_0x50e5d3?.['meta'];console[_0x31d47b(0x499)](''),_0x38340b(_0x5063ed,'\x20\x20');if(_0x1bbfd1?.[_0x31d47b(0x2e3)]!=null||_0x1bbfd1?.[_0x31d47b(0x1cf)]!=null){const _0x172abb=[];if(_0x1bbfd1[_0x31d47b(0x2e3)]!=null)_0x172abb[_0x31d47b(0x488)](_0x1bbfd1[_0x31d47b(0x2e3)]+_0x31d47b(0x359)+(_0x1bbfd1[_0x31d47b(0x2e3)]!==0x1?'s':''));if(_0x1bbfd1[_0x31d47b(0x1cf)]!=null)_0x172abb['push'](_0x1bbfd1[_0x31d47b(0x1cf)]+'ms');console[_0x31d47b(0x499)](_0x31d47b(0x1e9)+_0x402df7(_0x1d9d03[_0x31d47b(0x3c6)],_0x172abb[_0x31d47b(0x2d8)](_0x31d47b(0x1d8))));}console['log']('');}function _0x38340b(_0x5a2bde,_0x504e68=''){const _0x58ebd4=_0x3136f7;if(_0x5a2bde===null||_0x5a2bde===undefined){console['log'](_0x504e68+_0x402df7(_0x1d9d03[_0x58ebd4(0x3c6)],'(null)'));return;}if(Array['isArray'](_0x5a2bde)){if(_0x5a2bde['length']===0x0){console[_0x58ebd4(0x499)](_0x504e68+_0x402df7(_0x1d9d03[_0x58ebd4(0x3c6)],_0x58ebd4(0x1d6)));return;}if(_0x5a2bde['every'](_0x1d1799=>_0x1d1799&&typeof _0x1d1799==='object'&&_0x58ebd4(0x22c)in _0x1d1799&&_0x58ebd4(0x3e0)in _0x1d1799)){_0x25f847(_0x5a2bde,_0x504e68);return;}if(_0x5a2bde[_0x58ebd4(0x2e9)](_0x1313a5=>_0x1313a5&&typeof _0x1313a5==='object'&&_0x58ebd4(0x398)in _0x1313a5&&'count'in _0x1313a5)){_0x256f01(_0x5a2bde,_0x504e68);return;}if(_0x5a2bde[_0x58ebd4(0x2e9)](_0x1b3134=>typeof _0x1b3134!==_0x58ebd4(0x1ee)||_0x1b3134===null)){_0x5a2bde[_0x58ebd4(0x20c)]((_0x183f92,_0x88d049)=>console[_0x58ebd4(0x499)](_0x504e68+_0x402df7(_0x1d9d03[_0x58ebd4(0x2b1)],_0x88d049+0x1+'.')+'\x20'+_0x402df7(_0x1d9d03[_0x58ebd4(0x23e)],String(_0x183f92))));return;}_0x5a2bde[_0x58ebd4(0x20c)]((_0x55ceea,_0x2aec26)=>{const _0xf966ef=_0x58ebd4;console['log'](_0x504e68+_0x402df7(_0x1d9d03[_0xf966ef(0x3c6)],'['+_0x2aec26+']'));if(typeof _0x55ceea===_0xf966ef(0x1ee)&&_0x55ceea!==null)_0x48c68c(_0x55ceea,_0x504e68+'\x20\x20');else console[_0xf966ef(0x499)](_0x504e68+'\x20\x20'+String(_0x55ceea));});return;}if(typeof _0x5a2bde===_0x58ebd4(0x1ee)){if('key'in _0x5a2bde&&'value'in _0x5a2bde&&Object[_0x58ebd4(0x3fd)](_0x5a2bde)[_0x58ebd4(0x48c)]<=0x3){console[_0x58ebd4(0x499)](_0x504e68+_0x402df7(_0x1d9d03['bold']+_0x1d9d03[_0x58ebd4(0x490)],String(_0x5a2bde['key'])));const _0x2e94bf=_0x5a2bde[_0x58ebd4(0x3e0)];if(_0x2e94bf&&typeof _0x2e94bf===_0x58ebd4(0x1ee))_0x48c68c(_0x2e94bf,_0x504e68);else console[_0x58ebd4(0x499)](_0x504e68+_0x402df7(_0x1d9d03[_0x58ebd4(0x23e)],String(_0x2e94bf)));return;}_0x48c68c(_0x5a2bde,_0x504e68);return;}console[_0x58ebd4(0x499)](_0x504e68+_0x402df7(_0x1d9d03[_0x58ebd4(0x23e)],String(_0x5a2bde)));}function _0x48c68c(_0x478af7,_0x528059=''){const _0x4f069=_0x3136f7,_0x15192d=Object['entries'](_0x478af7);if(_0x15192d[_0x4f069(0x48c)]===0x0){console[_0x4f069(0x499)](_0x528059+_0x402df7(_0x1d9d03[_0x4f069(0x3c6)],'{}'));return;}const _0x58bfd0=Math['min'](0x1c,Math['max'](..._0x15192d[_0x4f069(0x308)](([_0x2830ef])=>_0x2830ef['length'])));for(const [_0x3abf48,_0x771624]of _0x15192d){const _0x14bc64=_0x402df7(_0x1d9d03[_0x4f069(0x490)],_0x3abf48[_0x4f069(0x495)](_0x58bfd0));if(_0x771624===null||_0x771624===undefined)console[_0x4f069(0x499)](_0x528059+_0x14bc64+'\x20\x20'+_0x402df7(_0x1d9d03[_0x4f069(0x3c6)],'null'));else{if(typeof _0x771624==='object'){const _0x5eae48=JSON[_0x4f069(0x379)](_0x771624);_0x5eae48['length']<=0x50?console['log'](_0x528059+_0x14bc64+'\x20\x20'+_0x402df7(_0x1d9d03[_0x4f069(0x3c6)],_0x5eae48)):(console[_0x4f069(0x499)](_0x528059+_0x14bc64),_0x38340b(_0x771624,_0x528059+'\x20\x20'));}else{const _0x352d5a=typeof _0x771624==='boolean'?_0x402df7(_0x771624?_0x1d9d03['green']:_0x1d9d03[_0x4f069(0x2f7)],String(_0x771624)):typeof _0x771624==='number'?_0x402df7(_0x1d9d03[_0x4f069(0x255)],String(_0x771624)):_0x402df7(_0x1d9d03[_0x4f069(0x23e)],String(_0x771624));console[_0x4f069(0x499)](_0x528059+_0x14bc64+'\x20\x20'+_0x352d5a);}}}}function _0x25f847(_0x3be329,_0x34d84e=''){const _0x55f368=_0x3136f7,_0xbb0274=Math['min'](0x20,Math[_0x55f368(0x2be)](..._0x3be329[_0x55f368(0x308)](_0x18b500=>String(_0x18b500[_0x55f368(0x22c)])[_0x55f368(0x48c)])));for(const {key:_0x3fe56a,value:_0x5c9003,score:_0xcdb2f0,clock:_0x3fd664}of _0x3be329){const _0xdf9ee3=_0x402df7(_0x1d9d03[_0x55f368(0x416)]+_0x1d9d03[_0x55f368(0x490)],String(_0x3fe56a)['padEnd'](_0xbb0274)),_0x6cfa4b=_0x5c9003==null?_0x402df7(_0x1d9d03[_0x55f368(0x3c6)],'null'):typeof _0x5c9003===_0x55f368(0x1ee)?_0x402df7(_0x1d9d03[_0x55f368(0x3c6)],JSON[_0x55f368(0x379)](_0x5c9003)):_0x402df7(_0x1d9d03[_0x55f368(0x23e)],String(_0x5c9003)),_0x21f57d=_0xcdb2f0!=null?_0x402df7(_0x1d9d03['gray'],_0x55f368(0x29e)+_0xcdb2f0[_0x55f368(0x1ff)](0x4)):'',_0x11349f=_0x3fd664!=null?_0x402df7(_0x1d9d03[_0x55f368(0x2b1)],_0x55f368(0x3af)+_0x3fd664):'';console[_0x55f368(0x499)](_0x34d84e+_0xdf9ee3+'\x20\x20'+_0x6cfa4b+_0x21f57d+_0x11349f);}}function _0x256f01(_0x1bf94a,_0x190a32=''){const _0x18e872=_0x3136f7,_0x194485=Math[_0x18e872(0x1fa)](0x20,Math[_0x18e872(0x2be)](..._0x1bf94a['map'](_0x4ec2d8=>_0x4ec2d8['type'][_0x18e872(0x48c)])));for(const {type:_0x19a870,count:_0x3f1071,fields:_0x27e01f}of _0x1bf94a){if(_0x19a870[_0x18e872(0x424)]('~'))continue;const _0x5ab706=_0x402df7(_0x1d9d03[_0x18e872(0x416)]+_0x1d9d03[_0x18e872(0x490)],_0x19a870[_0x18e872(0x495)](_0x194485)),_0x589253=_0x402df7(_0x1d9d03[_0x18e872(0x255)],String(_0x3f1071)[_0x18e872(0x420)](0x6))+_0x402df7(_0x1d9d03['dim'],_0x18e872(0x2db)),_0x23e9f4=_0x27e01f&&Object[_0x18e872(0x3fd)](_0x27e01f)['length']?_0x402df7(_0x1d9d03['dim'],_0x18e872(0x366)+Object[_0x18e872(0x3fd)](_0x27e01f)['slice'](0x0,0x6)[_0x18e872(0x2d8)](',\x20')+(Object['keys'](_0x27e01f)[_0x18e872(0x48c)]>0x6?'…':'')):'';console['log'](_0x190a32+_0x5ab706+'\x20\x20'+_0x589253+_0x23e9f4);}}const _0x54f19b=[_0x3136f7(0x25d),_0x3136f7(0x447),'queue/','files/',_0x3136f7(0x1b1),_0x3136f7(0x31c)];function _0x252226(_0x5b2eb4,_0x362c9e){const _0x4f017e=_0x3136f7;if(_0x5b2eb4['startsWith']('/api/'))return _0x5b2eb4;if(_0x5b2eb4[_0x4f017e(0x424)]('/'))return'/api'+_0x5b2eb4;if(_0x5b2eb4[_0x4f017e(0x424)](_0x4f017e(0x2b7)))return _0x4f017e(0x1bd)+_0x5b2eb4;const _0x3e4419=_0x54f19b[_0x4f017e(0x493)](_0x57fdfb=>_0x5b2eb4===_0x57fdfb[_0x4f017e(0x279)](/\/$/,'')||_0x5b2eb4[_0x4f017e(0x424)](_0x57fdfb));return _0x3e4419?_0x4f017e(0x46a)+_0x362c9e+'/'+_0x5b2eb4:_0x4f017e(0x1bd)+_0x5b2eb4;}function _0x70bb86(_0x450165){const _0x5f41c9=_0x3136f7,_0x5c8f2a={},_0x91d8ce=[];let _0xcc4b8e=0x0;while(_0xcc4b8e<_0x450165['length']){if((_0x450165[_0xcc4b8e]==='--env'||_0x450165[_0xcc4b8e]==='-e')&&_0x450165[_0xcc4b8e+0x1]&&!_0x450165[_0xcc4b8e+0x1][_0x5f41c9(0x424)]('-'))_0x5c8f2a[_0x5f41c9(0x3ca)]=_0x450165[++_0xcc4b8e];else _0x450165[_0xcc4b8e]==='--help'||_0x450165[_0xcc4b8e]==='-h'?_0x5c8f2a[_0x5f41c9(0x264)]=!![]:_0x91d8ce[_0x5f41c9(0x488)](_0x450165[_0xcc4b8e]);_0xcc4b8e++;}return{'flags':_0x5c8f2a,'rest':_0x91d8ce};}const _0x57f5b7={'system':'System','envs':_0x3136f7(0x3b0),'types':_0x3136f7(0x2ff),'data':'Records','indexes':_0x3136f7(0x3a3),'fts':_0x3136f7(0x339),'sync':_0x3136f7(0x2ed),'queue':_0x3136f7(0x3de),'files':_0x3136f7(0x406),'embeddings':_0x3136f7(0x1f9),'engines':'Engines','admin':_0x3136f7(0x24a),'event':_0x3136f7(0x2c2),'processor':_0x3136f7(0x328)},_0x58b20f=['system',_0x3136f7(0x431),'types',_0x3136f7(0x3d0),_0x3136f7(0x3b2),_0x3136f7(0x243),'sync',_0x3136f7(0x315),_0x3136f7(0x47a),_0x3136f7(0x3db),_0x3136f7(0x37d),_0x3136f7(0x36f)];function _0x19aa12(_0x4ec516){const _0x4d9468=_0x3136f7;return _0x4ec516[_0x4d9468(0x279)](/^\/api/,'')[_0x4d9468(0x279)](/^\[\/env\/:env=[^\]]*\]/,_0x4d9468(0x1f5))['replace'](/^\/env\/:env/,_0x4d9468(0x409))[_0x4d9468(0x279)](/^\//,'');}function _0xa3a137(_0xc90bd5,_0x509d4d=''){const _0x2ebc2b=_0x3136f7,_0x4043f2=_0xc90bd5['http'][_0x2ebc2b(0x238)]()['filter'](_0x22c559=>!_0x22c559['meta']?.[_0x2ebc2b(0x2cf)]),_0x2d08c0=_0x509d4d?_0x4043f2[_0x2ebc2b(0x314)](_0xf8f0f4=>_0xf8f0f4[_0x2ebc2b(0x3c3)][_0x2ebc2b(0x291)]()['includes'](_0x509d4d[_0x2ebc2b(0x291)]())||(_0x94fddb(_0xf8f0f4)??'')[_0x2ebc2b(0x291)]()[_0x2ebc2b(0x40f)](_0x509d4d[_0x2ebc2b(0x291)]())||_0x54fb96(_0xf8f0f4)['some'](_0x2e3b81=>_0x2e3b81[_0x2ebc2b(0x291)]()[_0x2ebc2b(0x40f)](_0x509d4d[_0x2ebc2b(0x291)]()))):_0x4043f2;if(!_0x2d08c0[_0x2ebc2b(0x48c)]){console[_0x2ebc2b(0x499)](_0x402df7(_0x1d9d03[_0x2ebc2b(0x2f7)],_0x2ebc2b(0x268)+_0x509d4d+'\x22\x0a'));return;}const _0x9583f4=new Map();for(const _0x2c7338 of _0x2d08c0){const _0x30f72e=_0x54fb96(_0x2c7338)[0x0]??_0x2ebc2b(0x31f);if(!_0x9583f4[_0x2ebc2b(0x3fe)](_0x30f72e))_0x9583f4[_0x2ebc2b(0x34b)](_0x30f72e,[]);_0x9583f4['get'](_0x30f72e)['push'](_0x2c7338);}const _0x2fb8af=[..._0x58b20f[_0x2ebc2b(0x314)](_0x257d03=>_0x9583f4[_0x2ebc2b(0x3fe)](_0x257d03)),...[..._0x9583f4[_0x2ebc2b(0x3fd)]()][_0x2ebc2b(0x314)](_0x18901a=>!_0x58b20f[_0x2ebc2b(0x40f)](_0x18901a))];console[_0x2ebc2b(0x499)]('');for(const _0x34b7e8 of _0x2fb8af){const _0x3ab1a6=_0x9583f4[_0x2ebc2b(0x26b)](_0x34b7e8);if(!_0x3ab1a6?.[_0x2ebc2b(0x48c)])continue;console[_0x2ebc2b(0x499)](_0x402df7(_0x1d9d03[_0x2ebc2b(0x416)],'\x20\x20'+(_0x57f5b7[_0x34b7e8]??_0x34b7e8)));for(const _0x41f57c of _0x3ab1a6){const _0x3348c8=_0x402df7(_0x1d9d03[_0x2ebc2b(0x255)],_0x41f57c[_0x2ebc2b(0x294)][_0x2ebc2b(0x495)](0x7)),_0x578340=_0x402df7(_0x1d9d03[_0x2ebc2b(0x490)],_0x19aa12(_0x41f57c[_0x2ebc2b(0x3c3)])),_0x3b3f97=_0x94fddb(_0x41f57c)?_0x402df7(_0x1d9d03[_0x2ebc2b(0x3c6)],'\x20\x20'+_0x94fddb(_0x41f57c)):'',_0xfeb3bb=_0x41f57c['operation']?.['id']?_0x402df7(_0x1d9d03['gray'],_0x2ebc2b(0x211)+_0x41f57c['operation']['id']+']'):'';console[_0x2ebc2b(0x499)]('\x20\x20\x20\x20'+_0x3348c8+'\x20'+_0x578340+_0x3b3f97+_0xfeb3bb);}console['log']('');}}function _0x3fe033(_0x5a473c,_0x40bee6){const _0x3a8e12=_0x3136f7,_0x170b85=_0x40bee6[_0x3a8e12(0x279)](/^\/api(\/env\/[^/]+)?\//,'')[_0x3a8e12(0x4a2)]('/')[0x0],_0x4398b3=_0x5a473c[_0x3a8e12(0x39c)][_0x3a8e12(0x238)]()[_0x3a8e12(0x314)](_0x4111aa=>_0x4111aa[_0x3a8e12(0x3c3)]['toLowerCase']()['includes'](_0x170b85['toLowerCase']()));if(!_0x4398b3['length']){console[_0x3a8e12(0x499)](_0x402df7(_0x1d9d03[_0x3a8e12(0x2f7)],'\x0a\x20\x20No\x20documentation\x20found\x20for:\x20'+_0x40bee6+'\x0a'));return;}console['log']('');for(const _0x16fc94 of _0x4398b3[_0x3a8e12(0x1c2)](0x0,0xc)){for(const _0x2fd2ec of _0x17a7aa(_0x16fc94)){console[_0x3a8e12(0x499)](_0x2fd2ec);}console[_0x3a8e12(0x499)]('');}}function _0x94fddb(_0x47278c){const _0x2ce782=_0x3136f7;return _0x47278c[_0x2ce782(0x337)]?.[_0x2ce782(0x309)]??_0x47278c[_0x2ce782(0x45d)]?.[_0x2ce782(0x309)]??'';}function _0x3daa3d(_0x249530){const _0x3d1c11=_0x3136f7;return _0x249530[_0x3d1c11(0x337)]?.[_0x3d1c11(0x1cd)]??_0x249530[_0x3d1c11(0x45d)]?.[_0x3d1c11(0x1cd)]??'';}function _0x54fb96(_0x5c9bf7){const _0x2ddcac=_0x3136f7;return _0x5c9bf7['operation']?.[_0x2ddcac(0x383)]?.[_0x2ddcac(0x48c)]?_0x5c9bf7[_0x2ddcac(0x337)][_0x2ddcac(0x383)]:_0x5c9bf7[_0x2ddcac(0x45d)]?.[_0x2ddcac(0x383)]??[];}function _0x17a7aa(_0x541770){const _0x51441e=_0x3136f7,_0x2c6f16=[];_0x2c6f16[_0x51441e(0x488)]('\x20\x20'+_0x402df7(_0x1d9d03[_0x51441e(0x416)]+_0x1d9d03[_0x51441e(0x255)],_0x541770['method'][_0x51441e(0x495)](0x7))+'\x20'+_0x402df7(_0x1d9d03[_0x51441e(0x416)]+_0x1d9d03[_0x51441e(0x490)],_0x541770[_0x51441e(0x3c3)]));_0x541770[_0x51441e(0x337)]?.['id']&&_0x2c6f16[_0x51441e(0x488)](_0x51441e(0x1f0)+_0x402df7(_0x1d9d03[_0x51441e(0x2b1)],_0x51441e(0x444)+_0x541770[_0x51441e(0x337)]['id']));_0x94fddb(_0x541770)&&_0x2c6f16[_0x51441e(0x488)](_0x51441e(0x1f0)+_0x402df7(_0x1d9d03[_0x51441e(0x23e)],_0x94fddb(_0x541770)));_0x3daa3d(_0x541770)&&_0x2c6f16[_0x51441e(0x488)](_0x51441e(0x1f0)+_0x402df7(_0x1d9d03[_0x51441e(0x3c6)],_0x3daa3d(_0x541770)));_0x54fb96(_0x541770)[_0x51441e(0x48c)]&&_0x2c6f16[_0x51441e(0x488)](_0x51441e(0x1f0)+_0x402df7(_0x1d9d03['gray'],'tags:\x20'+_0x54fb96(_0x541770)['join'](',\x20')));_0x541770[_0x51441e(0x337)]?.['safety']?.['access']&&_0x2c6f16['push']('\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+_0x402df7(_0x1d9d03[_0x51441e(0x2b1)],'access:\x20'+_0x541770[_0x51441e(0x337)][_0x51441e(0x3eb)][_0x51441e(0x301)]));_0x541770[_0x51441e(0x337)]?.['http']?.[_0x51441e(0x407)]&&_0x541770[_0x51441e(0x337)]['http'][_0x51441e(0x407)]!==_0x51441e(0x4a8)&&_0x2c6f16[_0x51441e(0x488)](_0x51441e(0x1f0)+_0x402df7(_0x1d9d03['gray'],'transport:\x20'+_0x541770[_0x51441e(0x337)][_0x51441e(0x39c)]['transport']));if(_0x541770['operation']?.['inputSchema']){const _0x3d4a44=Object['keys'](_0x541770[_0x51441e(0x337)][_0x51441e(0x33c)][_0x51441e(0x1d9)]||{});if(_0x3d4a44[_0x51441e(0x48c)])_0x2c6f16[_0x51441e(0x488)]('\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+_0x402df7(_0x1d9d03[_0x51441e(0x2b1)],_0x51441e(0x412)+_0x3d4a44[_0x51441e(0x2d8)](',\x20')));}return _0x541770['meta']?.[_0x51441e(0x2e1)]&&_0x2c6f16[_0x51441e(0x488)]('\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+_0x402df7(_0x1d9d03[_0x51441e(0x2b1)],_0x51441e(0x230)+JSON[_0x51441e(0x379)](_0x541770[_0x51441e(0x45d)][_0x51441e(0x2e1)]))),_0x2c6f16;}async function _0xe42de1(_0x3a0823,_0x446b01,_0x1f06c7,_0x47e1dc=null){const _0x2abe6f=_0x3136f7,_0x502b6c=_0x1f06c7[_0x2abe6f(0x462)]('?'),_0x2f0efd=_0x502b6c>=0x0?_0x1f06c7[_0x2abe6f(0x1c2)](0x0,_0x502b6c):_0x1f06c7,_0x537d08=_0x502b6c>=0x0?_0x1f06c7['slice'](_0x502b6c+0x1):'',_0x4e9ab5=Object[_0x2abe6f(0x481)](new URLSearchParams(_0x537d08)[_0x2abe6f(0x3f8)]());return _0x3a0823[_0x2abe6f(0x39c)]['handle'](_0x446b01,_0x2f0efd,{'body':_0x47e1dc,'query':_0x4e9ab5,'headers':{'content-type':'application/json'}},{'internal':!![]});}function _0x5d2be3(_0x41576d){const _0x4fcaad=_0x3136f7;if(!_0x41576d)return null;const _0x5a5e24=_0x41576d[_0x4fcaad(0x34d)]();if(!_0x5a5e24)return null;try{return JSON[_0x4fcaad(0x24b)](_0x5a5e24);}catch{}try{return JSON[_0x4fcaad(0x24b)](_0x13d248(_0x5a5e24));}catch(_0x11bc71){throw new SyntaxError(_0x11bc71[_0x4fcaad(0x2a5)],{'cause':_0x11bc71});}}function _0x13d248(_0x5f36fb){const _0xfa2fc6=_0x3136f7;let _0x364a5d='',_0x596a8a=0x0;while(_0x596a8a<_0x5f36fb[_0xfa2fc6(0x48c)]){const _0x3ced47=_0x5f36fb[_0x596a8a];if(_0x3ced47==='\x22'){_0x364a5d+='\x22',_0x596a8a++;while(_0x596a8a<_0x5f36fb[_0xfa2fc6(0x48c)]&&_0x5f36fb[_0x596a8a]!=='\x22'){if(_0x5f36fb[_0x596a8a]==='\x5c'){_0x364a5d+=_0x5f36fb[_0x596a8a++];if(_0x596a8a<_0x5f36fb['length'])_0x364a5d+=_0x5f36fb[_0x596a8a++];}else _0x364a5d+=_0x5f36fb[_0x596a8a++];}_0x364a5d+='\x22';if(_0x596a8a<_0x5f36fb[_0xfa2fc6(0x48c)])_0x596a8a++;continue;}if(_0x3ced47==='\x27'){_0x364a5d+='\x22',_0x596a8a++;while(_0x596a8a<_0x5f36fb['length']&&_0x5f36fb[_0x596a8a]!=='\x27'){if(_0x5f36fb[_0x596a8a]==='\x5c'&&_0x5f36fb[_0x596a8a+0x1]==='\x27')_0x364a5d+='\x27',_0x596a8a+=0x2;else _0x5f36fb[_0x596a8a]==='\x22'?(_0x364a5d+='\x5c\x22',_0x596a8a++):_0x364a5d+=_0x5f36fb[_0x596a8a++];}_0x364a5d+='\x22';if(_0x596a8a<_0x5f36fb[_0xfa2fc6(0x48c)])_0x596a8a++;continue;}if(_0xfa2fc6(0x30a)[_0xfa2fc6(0x40f)](_0x3ced47)){_0x364a5d+=_0x3ced47,_0x596a8a++;continue;}let _0x33105e='';while(_0x596a8a<_0x5f36fb[_0xfa2fc6(0x48c)]&&!_0xfa2fc6(0x297)[_0xfa2fc6(0x40f)](_0x5f36fb[_0x596a8a])&&_0x5f36fb[_0x596a8a]!=='\x20'&&_0x5f36fb[_0x596a8a]!=='\x09'&&_0x5f36fb[_0x596a8a]!=='\x0a'&&_0x5f36fb[_0x596a8a]!=='\x0d'){_0x33105e+=_0x5f36fb[_0x596a8a++];}let _0x5a3a17=_0x596a8a;while(_0x5a3a17<_0x5f36fb[_0xfa2fc6(0x48c)]&&(_0x5f36fb[_0x5a3a17]==='\x20'||_0x5f36fb[_0x5a3a17]==='\x09'))_0x5a3a17++;if(_0x5f36fb[_0x5a3a17]===':')_0x364a5d+='\x22'+_0x33105e+'\x22';else _0x33105e===_0xfa2fc6(0x422)||_0x33105e===_0xfa2fc6(0x401)||_0x33105e===_0xfa2fc6(0x4a1)||/^-?\d+(\.\d+)?([eE][+-]?\d+)?$/[_0xfa2fc6(0x320)](_0x33105e)?_0x364a5d+=_0x33105e:_0x364a5d+='\x22'+_0x33105e+'\x22';}return _0x364a5d[_0xfa2fc6(0x279)](/,(\s*[}\]])/g,'$1');}function _0x563f11(_0x3f12ab){const _0xfc55eb=_0x3136f7,_0x500791=[];let _0x417a63=0x0;while(_0x417a63<_0x3f12ab[_0xfc55eb(0x48c)]){while(_0x417a63<_0x3f12ab['length']&&(_0x3f12ab[_0x417a63]==='\x20'||_0x3f12ab[_0x417a63]==='\x09'))_0x417a63++;if(_0x417a63>=_0x3f12ab[_0xfc55eb(0x48c)])break;const _0x100d1f=_0x3f12ab[_0x417a63];if(_0x100d1f==='{'||_0x100d1f==='['){const _0x40bd62=_0x100d1f==='{'?'}':']',_0x174c8f=_0x417a63++;let _0x581c26=0x1,_0x307bd5=![],_0x189e2f='';while(_0x417a63<_0x3f12ab[_0xfc55eb(0x48c)]&&_0x581c26>0x0){const _0x1f9498=_0x3f12ab[_0x417a63];if(_0x307bd5){if(_0x1f9498==='\x5c')_0x417a63++;else{if(_0x1f9498===_0x189e2f)_0x307bd5=![];}}else{if(_0x1f9498==='\x22'||_0x1f9498==='\x27')_0x307bd5=!![],_0x189e2f=_0x1f9498;else{if(_0x1f9498===_0x100d1f)_0x581c26++;else{if(_0x1f9498===_0x40bd62)_0x581c26--;}}}_0x417a63++;}_0x500791[_0xfc55eb(0x488)](_0x3f12ab[_0xfc55eb(0x1c2)](_0x174c8f,_0x417a63));continue;}if(_0x100d1f==='\x22'||_0x100d1f==='\x27'){const _0x486455=_0x100d1f;_0x417a63++;let _0x17b2cd='';while(_0x417a63<_0x3f12ab['length']&&_0x3f12ab[_0x417a63]!==_0x486455){if(_0x3f12ab[_0x417a63]==='\x5c'&&_0x417a63+0x1<_0x3f12ab[_0xfc55eb(0x48c)])_0x417a63++,_0x17b2cd+=_0x3f12ab[_0x417a63++];else _0x17b2cd+=_0x3f12ab[_0x417a63++];}if(_0x417a63<_0x3f12ab['length'])_0x417a63++;_0x500791[_0xfc55eb(0x488)](_0x17b2cd);continue;}let _0x467e42='';while(_0x417a63<_0x3f12ab['length']&&_0x3f12ab[_0x417a63]!=='\x20'&&_0x3f12ab[_0x417a63]!=='\x09'&&_0x3f12ab[_0x417a63]!=='{'&&_0x3f12ab[_0x417a63]!=='['){_0x467e42+=_0x3f12ab[_0x417a63++];}if(_0x467e42)_0x500791[_0xfc55eb(0x488)](_0x467e42);}return _0x500791;}function _0x26917e(_0x497b2f,_0x16413a){const _0x2f47bd=_0x3136f7,_0xe617b8=[..._0x497b2f['_envs'][_0x2f47bd(0x3fd)]()][_0x2f47bd(0x314)](_0x4c00ba=>!_0x4c00ba['startsWith']('~'));console[_0x2f47bd(0x499)](['',_0x402df7(_0x1d9d03[_0x2f47bd(0x416)]+_0x1d9d03[_0x2f47bd(0x490)],_0x2f47bd(0x432)),_0x402df7(_0x1d9d03[_0x2f47bd(0x416)]+_0x1d9d03[_0x2f47bd(0x490)],'\x20\x20║')+_0x402df7(_0x1d9d03[_0x2f47bd(0x416)],_0x2f47bd(0x292))+_0x402df7(_0x1d9d03['bold']+_0x1d9d03['cyan'],'║'),_0x402df7(_0x1d9d03[_0x2f47bd(0x416)]+_0x1d9d03['cyan'],_0x2f47bd(0x418)),'','\x20\x20'+_0x402df7(_0x1d9d03[_0x2f47bd(0x46f)],'✓')+'\x20'+_0x402df7(_0x1d9d03[_0x2f47bd(0x416)],_0x2f47bd(0x1bc))+_0x2f47bd(0x247)+_0x16413a[_0x2f47bd(0x21b)],'\x20\x20'+_0x402df7(_0x1d9d03['green'],'✓')+'\x20'+_0x402df7(_0x1d9d03[_0x2f47bd(0x416)],'api')+_0x2f47bd(0x408)+_0x16413a['port']+_0x2f47bd(0x232),'\x20\x20'+_0x402df7(_0x1d9d03[_0x2f47bd(0x46f)],'✓')+'\x20'+_0x402df7(_0x1d9d03[_0x2f47bd(0x416)],_0x2f47bd(0x3c3))+_0x2f47bd(0x364)+_0x16413a[_0x2f47bd(0x1ba)],'\x20\x20'+_0x402df7(_0x1d9d03[_0x2f47bd(0x46f)],'✓')+'\x20'+_0x402df7(_0x1d9d03[_0x2f47bd(0x416)],'id')+_0x2f47bd(0x38a)+_0x402df7(_0x1d9d03[_0x2f47bd(0x2b1)],_0x497b2f['id']),'\x20\x20'+_0x402df7(_0x1d9d03['green'],'✓')+'\x20'+_0x402df7(_0x1d9d03[_0x2f47bd(0x416)],'envs')+'\x20\x20\x20\x20'+_0xe617b8[_0x2f47bd(0x308)](_0x35cb9b=>_0x402df7(_0x1d9d03['cyan'],_0x35cb9b))[_0x2f47bd(0x2d8)]('\x20\x20'),..._0x16413a['noAdmin']?[]:['\x20\x20'+_0x402df7(_0x1d9d03[_0x2f47bd(0x46f)],'✓')+'\x20'+_0x402df7(_0x1d9d03[_0x2f47bd(0x416)],_0x2f47bd(0x36f))+'\x20\x20\x20http://localhost:'+_0x16413a[_0x2f47bd(0x21b)]+'/admin/index.html'],'',_0x402df7(_0x1d9d03[_0x2f47bd(0x3c6)],'\x20\x20Type\x20'+_0x402df7(_0x1d9d03['bold'],_0x2f47bd(0x264))+'\x20for\x20commands,\x20'+_0x402df7(_0x1d9d03['bold'],_0x2f47bd(0x4a3))+'\x20to\x20browse\x20the\x20API,\x20'+_0x402df7(_0x1d9d03[_0x2f47bd(0x416)],_0x2f47bd(0x463))+_0x2f47bd(0x2c9)),''][_0x2f47bd(0x2d8)]('\x0a'));}function _0x4df7b0(_0x30028d){const _0x453209=_0x3136f7;console['log']('\x0a'+_0x402df7(_0x1d9d03['bold'],_0x453209(0x2e4))+'\x20\x20'+_0x402df7(_0x1d9d03[_0x453209(0x3c6)],_0x453209(0x307))+_0x453209(0x458)+_0x402df7(_0x1d9d03['cyan'],_0x453209(0x28c))+_0x453209(0x3b6)+_0x402df7(_0x1d9d03[_0x453209(0x490)],_0x453209(0x28c))+'\x20'+_0x402df7(_0x1d9d03[_0x453209(0x2f7)],'<json-body>')+_0x453209(0x47c)+_0x402df7(_0x1d9d03[_0x453209(0x490)],_0x453209(0x35f))+'\x20'+_0x402df7(_0x1d9d03[_0x453209(0x490)],_0x453209(0x28c))+'\x20'+_0x402df7(_0x1d9d03[_0x453209(0x2f7)],_0x453209(0x2fc))+_0x453209(0x32e)+_0x402df7(_0x1d9d03[_0x453209(0x3c6)],_0x453209(0x261))+_0x453209(0x30c)+_0x402df7(_0x1d9d03['gray'],_0x453209(0x312))+_0x453209(0x27f)+_0x402df7(_0x1d9d03[_0x453209(0x2b1)],_0x453209(0x431))+_0x453209(0x205)+_0x402df7(_0x1d9d03[_0x453209(0x2b1)],_0x453209(0x25d))+_0x453209(0x23f)+_0x30028d[_0x453209(0x3ca)]+_0x453209(0x21d)+_0x402df7(_0x1d9d03[_0x453209(0x2b1)],_0x453209(0x43f))+_0x453209(0x3fc)+_0x30028d[_0x453209(0x3ca)]+_0x453209(0x1e2)+_0x402df7(_0x1d9d03['gray'],_0x453209(0x310))+_0x453209(0x326)+_0x30028d[_0x453209(0x3ca)]+_0x453209(0x3c0)+_0x402df7(_0x1d9d03[_0x453209(0x2b1)],_0x453209(0x48b))+'\x20→\x20POST\x20/api/env/'+_0x30028d['env']+_0x453209(0x3be)+_0x402df7(_0x1d9d03[_0x453209(0x2b1)],'PUT\x20type/users/item/x\x20{\x22n\x22:1}')+_0x453209(0x30c)+_0x402df7(_0x1d9d03[_0x453209(0x2b1)],'DELETE\x20type/users/item/x')+_0x453209(0x30c)+_0x402df7(_0x1d9d03[_0x453209(0x2b1)],_0x453209(0x46e))+_0x453209(0x3ab)+_0x402df7(_0x1d9d03[_0x453209(0x416)],'\x20\x20Flags')+'\x20\x20'+_0x402df7(_0x1d9d03['dim'],_0x453209(0x32b))+_0x453209(0x458)+_0x402df7(_0x1d9d03[_0x453209(0x490)],_0x453209(0x254))+_0x453209(0x2df)+_0x402df7(_0x1d9d03['cyan'],_0x453209(0x49d))+_0x453209(0x2ca)+_0x402df7(_0x1d9d03['dim'],_0x453209(0x261))+_0x453209(0x30c)+_0x402df7(_0x1d9d03[_0x453209(0x2b1)],'types\x20--env\x20staging')+_0x453209(0x30c)+_0x402df7(_0x1d9d03['gray'],_0x453209(0x347))+_0x453209(0x30c)+_0x402df7(_0x1d9d03[_0x453209(0x2b1)],_0x453209(0x40e))+'\x0a\x0a'+_0x402df7(_0x1d9d03['bold'],_0x453209(0x428))+_0x453209(0x458)+_0x402df7(_0x1d9d03[_0x453209(0x490)],_0x453209(0x48f))+_0x453209(0x368)+_0x402df7(_0x1d9d03[_0x453209(0x490)],_0x453209(0x3ca))+_0x453209(0x3b9)+_0x402df7(_0x1d9d03[_0x453209(0x490)],_0x453209(0x4a3))+'\x20'+_0x402df7(_0x1d9d03[_0x453209(0x3c6)],_0x453209(0x48e))+_0x453209(0x32c)+_0x402df7(_0x1d9d03[_0x453209(0x490)],_0x453209(0x2b6))+'\x20'+_0x402df7(_0x1d9d03['dim'],_0x453209(0x27a))+'\x20\x20\x20\x20\x20control\x20log\x20verbosity\x0a\x20\x20'+_0x402df7(_0x1d9d03[_0x453209(0x490)],_0x453209(0x460))+_0x453209(0x3ed)+_0x402df7(_0x1d9d03['cyan'],'help')+_0x453209(0x37f)+_0x402df7(_0x1d9d03['cyan'],_0x453209(0x463))+'\x20'+_0x402df7(_0x1d9d03[_0x453209(0x3c6)],_0x453209(0x1e3))+_0x453209(0x387));}async function _0x2b06d1(_0x545221,_0x2c07ef=0x0){const _0x19f849=_0x3136f7;process[_0x19f849(0x313)][_0x19f849(0x204)]('\x0a'),console[_0x19f849(0x499)](_0x402df7(_0x1d9d03[_0x19f849(0x2f7)],'\x20\x20[okdb]\x20shutting\x20down…'));try{await _0x545221['close']();}catch(_0x15b191){console[_0x19f849(0x202)](_0x402df7(_0x1d9d03[_0x19f849(0x4a0)],'\x20\x20'+_0x15b191[_0x19f849(0x2a5)]));}process[_0x19f849(0x463)](_0x2c07ef);}function _0x191811(_0x5ce0b1){const _0x36442f=_0x3136f7,_0x95c227=_0x5ce0b1[_0x36442f(0x3ca)]!=='default'?_0x402df7(_0x1d9d03[_0x36442f(0x2f7)],'['+_0x5ce0b1[_0x36442f(0x3ca)]+']'):'';return _0x402df7(_0x1d9d03[_0x36442f(0x416)]+_0x1d9d03['cyan'],_0x36442f(0x250))+_0x95c227+_0x402df7(_0x1d9d03[_0x36442f(0x2b1)],'>\x20');}const _0xb953be=new Set(['GET',_0x3136f7(0x491),'PUT',_0x3136f7(0x300),_0x3136f7(0x47d)]);async function _0x37c092(_0x184712,_0xf1fe57,_0x28db62,_0x44ad02,_0x4276e4,_0x8e01d4){const _0x9215f3=_0x3136f7;_0x184712=_0x184712[_0x9215f3(0x34d)]();if(!_0x184712||_0x184712[_0x9215f3(0x424)]('#'))return;const _0x5f0902=_0x563f11(_0x184712),{flags:_0x1c8183,rest:_0x3f9f65}=_0x70bb86(_0x5f0902);if(!_0x3f9f65[_0x9215f3(0x48c)])return;const _0x50bbb7=_0x3f9f65[0x0],_0x48dbb6=_0x50bbb7[_0x9215f3(0x285)]();if(_0x48dbb6===_0x9215f3(0x1f6)){if(_0x3f9f65[0x1])_0x3fe033(_0xf1fe57,_0x252226(_0x3f9f65[0x1],_0x1c8183['env']??_0x4276e4[_0x9215f3(0x3ca)]));else _0x4df7b0(_0x4276e4);return;}if(_0x48dbb6===_0x9215f3(0x33a)){const _0x52054d=_0x3f9f65[0x1];if(!_0x52054d){console[_0x9215f3(0x499)](_0x402df7(_0x1d9d03[_0x9215f3(0x4a0)],'\x0a\x20\x20Usage:\x20use\x20<env-name>\x0a'));return;}try{_0xf1fe57[_0x9215f3(0x3ca)](_0x52054d),_0x4276e4[_0x9215f3(0x3ca)]=_0x52054d,_0x8e01d4?.[_0x9215f3(0x3ac)](_0x191811(_0x4276e4)),console[_0x9215f3(0x499)](_0x9215f3(0x1e9)+_0x402df7(_0x1d9d03['green'],'✓')+'\x20active\x20env:\x20'+_0x402df7(_0x1d9d03[_0x9215f3(0x416)]+_0x1d9d03[_0x9215f3(0x490)],_0x52054d)+'\x0a');}catch{console['log']('\x0a\x20\x20'+_0x402df7(_0x1d9d03[_0x9215f3(0x4a0)],'✗')+_0x9215f3(0x3a7)+_0x402df7(_0x1d9d03[_0x9215f3(0x416)],_0x52054d)+'\x20not\x20found'+_0x402df7(_0x1d9d03['dim'],_0x9215f3(0x426)));}return;}if(_0x48dbb6===_0x9215f3(0x1f3)){const _0x4b7de4=[..._0xf1fe57[_0x9215f3(0x358)][_0x9215f3(0x3fd)]()][_0x9215f3(0x314)](_0x57d738=>!_0x57d738[_0x9215f3(0x424)]('~'));console[_0x9215f3(0x499)]('');for(const _0x43acb9 of _0x4b7de4){const _0x4fdc77=_0x43acb9===_0x4276e4[_0x9215f3(0x3ca)];console['log']('\x20\x20'+(_0x4fdc77?_0x402df7(_0x1d9d03[_0x9215f3(0x46f)],'●'):_0x402df7(_0x1d9d03[_0x9215f3(0x3c6)],'○'))+'\x20\x20'+(_0x4fdc77?_0x402df7(_0x1d9d03[_0x9215f3(0x416)]+_0x1d9d03['cyan'],_0x43acb9):_0x402df7(_0x1d9d03[_0x9215f3(0x3c6)],_0x43acb9)));}console['log'](_0x9215f3(0x1e9)+_0x402df7(_0x1d9d03['dim'],_0x9215f3(0x440))+'\x20'+_0x402df7(_0x1d9d03[_0x9215f3(0x490)],_0x4276e4[_0x9215f3(0x3ca)])),console[_0x9215f3(0x499)]('');return;}if(_0x48dbb6==='ENVS'){const _0x212b86=[..._0xf1fe57[_0x9215f3(0x358)][_0x9215f3(0x384)]()][_0x9215f3(0x314)](_0x4e4a50=>!_0x4e4a50[_0x9215f3(0x2b5)]['startsWith']('~'));console['log']('');const _0x21823a=Math[_0x9215f3(0x2be)](..._0x212b86[_0x9215f3(0x308)](_0x252266=>_0x252266[_0x9215f3(0x2b5)][_0x9215f3(0x48c)]));for(const _0x18178a of _0x212b86){const _0x4ed905=_0x18178a[_0x9215f3(0x2b5)]===_0x4276e4[_0x9215f3(0x3ca)],_0x220647=_0x4ed905?_0x402df7(_0x1d9d03['green'],'●'):_0x402df7(_0x1d9d03[_0x9215f3(0x3c6)],'○'),_0x1e8d85=_0x4ed905?_0x402df7(_0x1d9d03[_0x9215f3(0x416)]+_0x1d9d03[_0x9215f3(0x490)],_0x18178a[_0x9215f3(0x2b5)]['padEnd'](_0x21823a)):_0x402df7(_0x1d9d03[_0x9215f3(0x3c6)],_0x18178a[_0x9215f3(0x2b5)][_0x9215f3(0x495)](_0x21823a)),_0x5819b5=[..._0x18178a[_0x9215f3(0x31d)][_0x9215f3(0x3fd)]()][_0x9215f3(0x314)](_0x5352ab=>!_0x5352ab[_0x9215f3(0x424)]('~')),_0x3abae8=_0x5819b5[_0x9215f3(0x48c)]?_0x402df7(_0x1d9d03[_0x9215f3(0x3c6)],_0x5819b5[_0x9215f3(0x1c2)](0x0,0x5)[_0x9215f3(0x2d8)](',\x20')+(_0x5819b5[_0x9215f3(0x48c)]>0x5?'\x20\x20+'+(_0x5819b5[_0x9215f3(0x48c)]-0x5)+_0x9215f3(0x303):'')):_0x402df7(_0x1d9d03[_0x9215f3(0x3c6)],_0x9215f3(0x356));console[_0x9215f3(0x499)]('\x20\x20'+_0x220647+'\x20\x20'+_0x1e8d85+'\x20\x20'+_0x3abae8);}console[_0x9215f3(0x499)]('');return;}if(_0x48dbb6===_0x9215f3(0x4ad)){const _0x58636b=_0x1c8183[_0x9215f3(0x3ca)]??_0x3f9f65[0x1]??_0x4276e4[_0x9215f3(0x3ca)];try{const _0xf75fc5=_0xf1fe57[_0x9215f3(0x3ca)](_0x58636b),_0x388515=[..._0xf75fc5[_0x9215f3(0x31d)][_0x9215f3(0x3fd)]()][_0x9215f3(0x314)](_0x4262dd=>!_0x4262dd[_0x9215f3(0x424)]('~'))['sort']();console[_0x9215f3(0x499)](_0x9215f3(0x1e9)+_0x402df7(_0x1d9d03[_0x9215f3(0x3c6)],_0x388515[_0x9215f3(0x48c)]+'\x20type'+(_0x388515[_0x9215f3(0x48c)]!==0x1?'s':'')+'\x20in\x20'+_0x58636b));for(const _0x139a9a of _0x388515){const _0x533c81=_0xf75fc5[_0x9215f3(0x31d)]['get'](_0x139a9a),_0x2f419d=_0x533c81?.['data']?.[_0x9215f3(0x45f)]?.()??0x0,_0x23a24e=_0x402df7(_0x1d9d03[_0x9215f3(0x416)]+_0x1d9d03[_0x9215f3(0x490)],_0x139a9a[_0x9215f3(0x495)](0x1c));console['log'](_0x9215f3(0x364)+_0x23a24e+'\x20\x20'+_0x402df7(_0x1d9d03[_0x9215f3(0x255)],String(_0x2f419d)['padStart'](0x6))+'\x20'+_0x402df7(_0x1d9d03[_0x9215f3(0x3c6)],'records'));}console[_0x9215f3(0x499)]('');}catch(_0x4fbf17){console['error'](_0x402df7(_0x1d9d03[_0x9215f3(0x4a0)],_0x9215f3(0x1e9)+_0x4fbf17[_0x9215f3(0x2a5)]+'\x0a'));}return;}if(_0x48dbb6===_0x9215f3(0x1fb)){_0xa3a137(_0xf1fe57,_0x3f9f65[_0x9215f3(0x1c2)](0x1)[_0x9215f3(0x2d8)]('\x20'));return;}if(_0x48dbb6===_0x9215f3(0x464)){const _0x385e8c=(_0x3f9f65[0x1]??'')[_0x9215f3(0x291)]();if(!_0x385e8c||_0x385e8c==='on')_0x44ad02[_0x9215f3(0x323)]=!![],_0x44ad02[_0x9215f3(0x3a2)]=_0x9215f3(0x312),console[_0x9215f3(0x499)](_0x9215f3(0x1e9)+_0x402df7(_0x1d9d03[_0x9215f3(0x46f)],'✓')+_0x9215f3(0x38c)+_0x402df7(_0x1d9d03[_0x9215f3(0x3c6)],'level:\x20info')+'\x0a');else{if(_0x385e8c===_0x9215f3(0x298))_0x44ad02[_0x9215f3(0x323)]=![],console[_0x9215f3(0x499)](_0x9215f3(0x1e9)+_0x402df7(_0x1d9d03['yellow'],'○')+_0x9215f3(0x42b));else _0x124412[_0x385e8c]!==undefined?(_0x44ad02[_0x9215f3(0x323)]=!![],_0x44ad02[_0x9215f3(0x3a2)]=_0x385e8c,console[_0x9215f3(0x499)](_0x9215f3(0x1e9)+_0x402df7(_0x1d9d03['green'],'✓')+'\x20log\x20level:\x20'+_0x402df7(_0x1d9d03['bold'],_0x385e8c)+'\x0a')):console[_0x9215f3(0x202)](_0x402df7(_0x1d9d03[_0x9215f3(0x4a0)],_0x9215f3(0x275)));}return;}if(_0x48dbb6===_0x9215f3(0x306)||_0x48dbb6==='QUIT'){await _0x2b06d1(_0xf1fe57,0x0);return;}if(_0x48dbb6===_0x9215f3(0x286)){const _0xdc5b5=_0x9215f3(0x399)+_0x28db62[_0x9215f3(0x21b)]+'/admin/index.html',_0x222e9e=process[_0x9215f3(0x25e)]==='win32'?_0x9215f3(0x2b8)+_0xdc5b5:process[_0x9215f3(0x25e)]===_0x9215f3(0x2f2)?'open\x20'+_0xdc5b5:_0x9215f3(0x34e)+_0xdc5b5;require$$4[_0x9215f3(0x256)](_0x222e9e),console[_0x9215f3(0x499)]('\x0a\x20\x20'+_0x402df7(_0x1d9d03['green'],'✓')+'\x20opening\x20'+_0x402df7(_0x1d9d03[_0x9215f3(0x490)],_0xdc5b5)+'\x0a');return;}let _0x450922,_0x1a91e7,_0x1720e3;if(_0xb953be[_0x9215f3(0x3fe)](_0x48dbb6)){_0x450922=_0x48dbb6,_0x1a91e7=_0x3f9f65[0x1],_0x1720e3=_0x3f9f65[_0x9215f3(0x1c2)](0x2);if(!_0x1a91e7){console[_0x9215f3(0x202)](_0x402df7(_0x1d9d03[_0x9215f3(0x4a0)],_0x9215f3(0x46b)+_0x50bbb7+_0x9215f3(0x2ce)));return;}}else _0x450922=null,_0x1a91e7=_0x3f9f65[0x0],_0x1720e3=_0x3f9f65[_0x9215f3(0x1c2)](0x1);const _0x300510=_0x1c8183[_0x9215f3(0x3ca)]??_0x4276e4[_0x9215f3(0x3ca)],_0x541375=_0x252226(_0x1a91e7,_0x300510);if(_0x1c8183[_0x9215f3(0x264)]){_0x3fe033(_0xf1fe57,_0x541375);return;}let _0xef058d=null;if(_0x1720e3['length']){const _0x597063=_0x1720e3[_0x9215f3(0x2d8)]('\x20');try{_0xef058d=_0x5d2be3(_0x597063);}catch(_0x5e58f8){console[_0x9215f3(0x202)](_0x402df7(_0x1d9d03['red'],_0x9215f3(0x348)+_0x597063+_0x9215f3(0x1e9)+_0x402df7(_0x1d9d03[_0x9215f3(0x3c6)],_0x5e58f8[_0x9215f3(0x2a5)])+'\x0a'));return;}}if(!_0x450922)_0x450922=_0xef058d!==null?_0x9215f3(0x491):'GET';try{const _0x578a10=await _0xe42de1(_0xf1fe57,_0x450922,_0x541375,_0xef058d);_0x4f316f(_0x578a10[_0x9215f3(0x219)],_0x578a10[_0x9215f3(0x2e1)]);}catch(_0x10e09d){console[_0x9215f3(0x202)]('\x0a\x20\x20'+_0x402df7(_0x1d9d03[_0x9215f3(0x4a0)],'✗')+'\x20'+_0x10e09d[_0x9215f3(0x2a5)]+'\x0a');}}class _0x1a2e4e{constructor(){const _0x15fb40=_0x3136f7;this[_0x15fb40(0x321)]=new Map(),this[_0x15fb40(0x1e7)]=null,this[_0x15fb40(0x397)]=![];}}function _0x28949d(_0x1fe5c8){const _0x1ad684=_0x3136f7,_0xa97ee9=new _0x1a2e4e();for(const _0x30c1cd of _0x1fe5c8){if(_0x30c1cd[_0x1ad684(0x45d)]?.[_0x1ad684(0x2cf)])continue;const _0x31a239=_0x30c1cd[_0x1ad684(0x3c3)]['replace'](/^\/api/,'')['replace'](/^\[\/env\/:env=[^\]]*\]/,'')['replace'](/^\//,'');if(!_0x31a239)continue;let _0x3ffbd3=_0xa97ee9;for(const _0x5b0f37 of _0x31a239[_0x1ad684(0x4a2)]('/')[_0x1ad684(0x314)](Boolean)){if(_0x5b0f37[_0x1ad684(0x424)](':')){const _0x32f816=_0x5b0f37[_0x1ad684(0x1c2)](0x1);if(!_0x3ffbd3['dynamic'])_0x3ffbd3[_0x1ad684(0x1e7)]={'param':_0x32f816,'node':new _0x1a2e4e()};_0x3ffbd3=_0x3ffbd3['dynamic']['node'];}else{if(!_0x3ffbd3[_0x1ad684(0x321)][_0x1ad684(0x3fe)](_0x5b0f37))_0x3ffbd3[_0x1ad684(0x321)]['set'](_0x5b0f37,new _0x1a2e4e());_0x3ffbd3=_0x3ffbd3[_0x1ad684(0x321)][_0x1ad684(0x26b)](_0x5b0f37);}}_0x3ffbd3[_0x1ad684(0x397)]=!![];}return _0xa97ee9;}const _0x5a33fb=new Map();function _0x5096d2(_0x318b71,_0x105af0,_0x49ce2f){const _0x405f08=_0x3136f7,_0x32e2d8=_0x5a33fb[_0x405f08(0x26b)](_0x318b71);if(_0x32e2d8&&_0x32e2d8[_0x405f08(0x239)]>Date[_0x405f08(0x311)]())return _0x32e2d8[_0x405f08(0x305)];const _0x5a613a=_0x49ce2f();return _0x5a33fb[_0x405f08(0x34b)](_0x318b71,{'val':_0x5a613a,'exp':Date[_0x405f08(0x311)]()+_0x105af0}),_0x5a613a;}function _0xafdf65(_0xf8b5b4,_0xdc8c,_0x58ade1,_0x25f30f){const _0x4b4f86=_0x3136f7,_0x5be8b4=_0xdc8c[_0x4b4f86(0x3ca)]??_0x25f30f[_0x4b4f86(0x3ca)];switch(_0xf8b5b4){case'env':return[..._0x58ade1[_0x4b4f86(0x358)][_0x4b4f86(0x3fd)]()][_0x4b4f86(0x314)](_0xa2bcc=>!_0xa2bcc[_0x4b4f86(0x424)]('~'));case _0x4b4f86(0x398):return _0x5096d2(_0x4b4f86(0x36b)+_0x5be8b4,0x7d0,()=>{const _0x417a2d=_0x4b4f86;try{return[..._0x58ade1[_0x417a2d(0x3ca)](_0x5be8b4)[_0x417a2d(0x31d)][_0x417a2d(0x3fd)]()]['filter'](_0x4f099c=>!_0x4f099c[_0x417a2d(0x424)]('~'));}catch{return[];}});case _0x4b4f86(0x22c):if(!_0xdc8c[_0x4b4f86(0x398)])return[];return _0x5096d2('keys:'+_0x5be8b4+':'+_0xdc8c[_0x4b4f86(0x398)],0x5dc,()=>{const _0x5cef41=_0x4b4f86;try{const _0x531c53=_0x58ade1[_0x5cef41(0x3ca)](_0x5be8b4)[_0x5cef41(0x31d)][_0x5cef41(0x26b)](_0xdc8c[_0x5cef41(0x398)]);if(!_0x531c53?.[_0x5cef41(0x3d0)])return[];const _0x5dc81e=[];for(const {key:_0x34cd74}of _0x531c53[_0x5cef41(0x3d0)][_0x5cef41(0x2ee)]({'limit':0x32})){_0x5dc81e['push'](String(_0x34cd74));if(_0x5dc81e[_0x5cef41(0x48c)]>=0x32)break;}return _0x5dc81e;}catch{return[];}});case'index':if(!_0xdc8c[_0x4b4f86(0x398)])return[];return _0x5096d2(_0x4b4f86(0x41b)+_0x5be8b4+':'+_0xdc8c[_0x4b4f86(0x398)],0x7d0,()=>{const _0x54eee3=_0x4b4f86;try{const _0x4eb387=_0x58ade1[_0x54eee3(0x3ca)](_0x5be8b4)[_0x54eee3(0x31d)][_0x54eee3(0x26b)](_0xdc8c[_0x54eee3(0x398)]);return _0x4eb387?[..._0x4eb387[_0x54eee3(0x38e)]?.['keys']()??[]]:[];}catch{return[];}});case _0x4b4f86(0x227):if(!_0xdc8c[_0x4b4f86(0x398)])return[];return _0x5096d2('fts:'+_0x5be8b4+':'+_0xdc8c[_0x4b4f86(0x398)],0x7d0,()=>{const _0x39f022=_0x4b4f86;try{return _0x58ade1['fts']?.[_0x39f022(0x3e7)]?.(_0xdc8c['type'],_0x58ade1['env'](_0x5be8b4))?.[_0x39f022(0x308)](_0x76b935=>_0x76b935[_0x39f022(0x2b5)])??[];}catch{return[];}});default:return[];}}function _0x2b6d7e(_0x5217af,_0x5b5d3a,_0x9bd6dd,_0xe82008){const _0x2ae1bd=_0x3136f7,_0x4b333f=_0x5217af[_0x2ae1bd(0x479)]('/'),_0x2a4711=_0x5217af['split']('/'),_0x29ee4a=_0x4b333f?_0x2a4711[_0x2ae1bd(0x1c2)](0x0,-0x1):_0x2a4711[_0x2ae1bd(0x1c2)](0x0,-0x1),_0x15a3ec=_0x4b333f?'':_0x2a4711[_0x2a4711[_0x2ae1bd(0x48c)]-0x1];let _0x1a8960=_0x5b5d3a;const _0x172e47={};for(const _0x7f0e72 of _0x29ee4a){if(!_0x7f0e72)continue;if(_0x1a8960[_0x2ae1bd(0x321)]['has'](_0x7f0e72))_0x1a8960=_0x1a8960['children'][_0x2ae1bd(0x26b)](_0x7f0e72);else{if(_0x1a8960[_0x2ae1bd(0x1e7)])_0x172e47[_0x1a8960[_0x2ae1bd(0x1e7)][_0x2ae1bd(0x327)]]=_0x7f0e72,_0x1a8960=_0x1a8960[_0x2ae1bd(0x1e7)]['node'];else return[];}}const _0x5401c8=_0x29ee4a[_0x2ae1bd(0x314)](Boolean),_0xb9dd62=_0x5401c8['length']?_0x5401c8[_0x2ae1bd(0x2d8)]('/')+'/':'',_0xe2ad80=[];for(const [_0x11d9c0]of _0x1a8960['children']){if(_0x11d9c0[_0x2ae1bd(0x424)](_0x15a3ec))_0xe2ad80['push'](_0xb9dd62+_0x11d9c0);}if(_0x1a8960[_0x2ae1bd(0x1e7)])for(const _0x33ae23 of _0xafdf65(_0x1a8960[_0x2ae1bd(0x1e7)][_0x2ae1bd(0x327)],_0x172e47,_0x9bd6dd,_0xe82008)){if(String(_0x33ae23)[_0x2ae1bd(0x424)](_0x15a3ec))_0xe2ad80[_0x2ae1bd(0x488)](_0xb9dd62+_0x33ae23);}return _0xe2ad80[_0x2ae1bd(0x1c2)](0x0,0x64);}const _0x19486f=[_0x3136f7(0x264),'use',_0x3136f7(0x3ca),_0x3136f7(0x431),'types',_0x3136f7(0x4a3),_0x3136f7(0x2b6),_0x3136f7(0x460),'exit','quit'];function _0x5dc5d7(_0x5bb043,_0x129c29,_0x3c87c4){return function _0x499613(_0x261743){const _0x44b230=_0x44a0;try{const _0x256039=_0x261743[_0x44b230(0x480)](/\s[{[]/),_0x577561=_0x256039>=0x0?_0x261743[_0x44b230(0x1c2)](0x0,_0x256039):_0x261743,_0x5ce39c=_0x577561[_0x44b230(0x44c)]();if(!_0x5ce39c){const _0x5468da=[..._0x19486f,...[..._0x5bb043[_0x44b230(0x321)]['keys']()]][_0x44b230(0x1c2)](0x0,0x64);return[_0x5468da,''];}const _0x5d7672=_0x5ce39c[_0x44b230(0x4a2)](/\s+/),_0x3991f9=_0x5d7672[0x0],_0x5daaa9=_0x3991f9[_0x44b230(0x285)]();if(_0x5d7672[_0x44b230(0x48c)]===0x1){const _0x5ebf0c=_0x3991f9['toLowerCase'](),_0x2bc088=_0x19486f[_0x44b230(0x314)](_0x209741=>_0x209741[_0x44b230(0x424)](_0x5ebf0c)),_0x4c444f=_0x2b6d7e(_0x3991f9,_0x5bb043,_0x129c29,_0x3c87c4),_0x4a3c10=[...new Set([..._0x2bc088,..._0x4c444f])]['slice'](0x0,0x64);return[_0x4a3c10,_0x3991f9];}if(_0xb953be['has'](_0x5daaa9)&&_0x5d7672[_0x44b230(0x48c)]===0x2){const _0x4beda5=_0x5d7672[0x1],_0xce4c4d=_0x2b6d7e(_0x4beda5,_0x5bb043,_0x129c29,_0x3c87c4);return[_0xce4c4d[_0x44b230(0x308)](_0x57ae76=>_0x3991f9+'\x20'+_0x57ae76),_0x3991f9+'\x20'+_0x4beda5];}if(!_0xb953be[_0x44b230(0x3fe)](_0x5daaa9)&&_0x5d7672['length']>0x1){const _0x1aef16=_0x2b6d7e(_0x3991f9,_0x5bb043,_0x129c29,_0x3c87c4),_0x454a65='\x20'+_0x5d7672[_0x44b230(0x1c2)](0x1)[_0x44b230(0x2d8)]('\x20');return[_0x1aef16[_0x44b230(0x308)](_0x1c143a=>_0x1c143a+_0x454a65),_0x3991f9+_0x454a65];}return[[],_0x261743];}catch{return[[],_0x261743];}};}async function _0x547b76(_0x11c47c,_0x4c4e1b){const _0x47abc9=_0x3136f7,_0x4189d2={'enabled':!![],'level':_0x4c4e1b['logLevel']??_0x47abc9(0x312)},_0x2ae445={'env':_0x47abc9(0x200)},_0x5cf3e2={'current':null},_0x367af7=_0x28949d(_0x11c47c[_0x47abc9(0x39c)][_0x47abc9(0x238)]()),_0xd51850=_0x5dc5d7(_0x367af7,_0x11c47c,_0x2ae445);_0x11c47c[_0x47abc9(0x499)][_0x47abc9(0x287)](_0x461324=>{const _0x4ace3a=_0x47abc9;if(!_0x4189d2['enabled'])return;_0x182a9b(_0x461324,_0x4189d2[_0x4ace3a(0x3a2)]),_0x5cf3e2[_0x4ace3a(0x22f)]?.[_0x4ace3a(0x489)](!![]);}),_0x26917e(_0x11c47c,_0x4c4e1b);const _0x132fa3=_0x51b846[_0x47abc9(0x4a6)]({'input':process[_0x47abc9(0x429)],'output':process[_0x47abc9(0x313)],'terminal':!![],'completer':_0xd51850,'prompt':_0x191811(_0x2ae445),'historySize':_0x22d439});try{const _0x5b6667=_0x562786[_0x47abc9(0x389)](_0x2aa2c7,_0x47abc9(0x484))['split']('\x0a')[_0x47abc9(0x314)](Boolean);_0x132fa3[_0x47abc9(0x34c)]=_0x5b6667[_0x47abc9(0x1d4)]()[_0x47abc9(0x1c2)](0x0,_0x22d439);}catch{}return _0x5cf3e2[_0x47abc9(0x22f)]=_0x132fa3,_0x132fa3['on'](_0x47abc9(0x257),async _0x497ff2=>{const _0x4305b1=_0x47abc9;_0x132fa3[_0x4305b1(0x443)]();try{await _0x37c092(_0x497ff2,_0x11c47c,_0x4c4e1b,_0x4189d2,_0x2ae445,_0x132fa3);}catch(_0x1b5bc1){console['error'](_0x402df7(_0x1d9d03[_0x4305b1(0x4a0)],_0x4305b1(0x244)+_0x1b5bc1[_0x4305b1(0x2a5)]));}finally{_0x132fa3[_0x4305b1(0x2c1)](),_0x132fa3[_0x4305b1(0x489)]();}}),_0x132fa3['on'](_0x47abc9(0x2d9),()=>{const _0x3e6f70=_0x47abc9;try{const _0x208594=[..._0x132fa3['history']][_0x3e6f70(0x1d4)]()[_0x3e6f70(0x314)](Boolean)['slice'](0x0,_0x22d439);_0x562786[_0x3e6f70(0x22d)](_0x2aa2c7,_0x208594[_0x3e6f70(0x2d8)]('\x0a')+'\x0a');}catch{}_0x2b06d1(_0x11c47c,0x0);}),process['on']('SIGINT',()=>{const _0x2ed5f0=_0x47abc9;if(_0x132fa3[_0x2ed5f0(0x257)]==='')_0x2b06d1(_0x11c47c,0x0);else process[_0x2ed5f0(0x313)][_0x2ed5f0(0x204)]('\x0a'),_0x132fa3[_0x2ed5f0(0x2a1)](0x0),_0x132fa3[_0x2ed5f0(0x489)]();}),process['on'](_0x47abc9(0x324),()=>_0x2b06d1(_0x11c47c,0x0)),_0x132fa3['prompt'](),_0x132fa3;}return okdbShell={'start':_0x547b76,'colorLog':_0x182a9b,'lenientParse':_0x5d2be3,'_splitLine':_0x563f11,'_formatRouteHelpLines':_0x17a7aa,'_routeSummary':_0x94fddb,'_routeTags':_0x54fb96},okdbShell;}var hasRequiredOkdb;function requireOkdb(){const _0x3a4bd7=_0x538f61;if(hasRequiredOkdb)return okdb$1;hasRequiredOkdb=0x1;try{process[_0x3a4bd7(0x3b1)]();}catch{}const _0x4f4c56=require$$1$1,_0x10d084=require$$1;function _0x131052(_0x14debe){const _0x4de07f=_0x3a4bd7,_0xb1ba1d=_0x14debe[_0x4de07f(0x1c2)](0x2),_0x6413d7={};let _0x4c93bc=0x0;while(_0x4c93bc<_0xb1ba1d[_0x4de07f(0x48c)]){const _0x3b0649=_0xb1ba1d[_0x4c93bc];if(_0x3b0649==='--port'||_0x3b0649==='-p')_0x6413d7[_0x4de07f(0x21b)]=Number(_0xb1ba1d[++_0x4c93bc]);else{if(_0x3b0649==='--path'||_0x3b0649==='-d')_0x6413d7[_0x4de07f(0x3c3)]=_0xb1ba1d[++_0x4c93bc];else{if(_0x3b0649===_0x4de07f(0x2ef)||_0x3b0649==='-k')_0x6413d7[_0x4de07f(0x22c)]=_0xb1ba1d[++_0x4c93bc];else{if(_0x3b0649===_0x4de07f(0x2f9)||_0x3b0649==='-c')_0x6413d7[_0x4de07f(0x42e)]=_0xb1ba1d[++_0x4c93bc];else{if(_0x3b0649===_0x4de07f(0x316))_0x6413d7[_0x4de07f(0x43e)]=_0xb1ba1d[++_0x4c93bc];else{if(_0x3b0649==='--no-repl')_0x6413d7['noRepl']=!![];else{if(_0x3b0649===_0x4de07f(0x49b))_0x6413d7[_0x4de07f(0x1c0)]=!![];else{if(_0x3b0649===_0x4de07f(0x44a)||_0x3b0649==='-e')_0x6413d7[_0x4de07f(0x3ca)]=_0xb1ba1d[++_0x4c93bc];else{if(_0x3b0649==='--types')_0x6413d7[_0x4de07f(0x25d)]=_0xb1ba1d[++_0x4c93bc];else{if(_0x3b0649==='--changes')_0x6413d7['changes']=!![];else{if(_0x3b0649===_0x4de07f(0x3f7))_0x6413d7['blobs']=!![];else{if(_0x3b0649===_0x4de07f(0x1fc))_0x6413d7['drop']=!![];else{if(_0x3b0649===_0x4de07f(0x494)){const _0x2bb554=[];while(_0x4c93bc+0x1<_0xb1ba1d[_0x4de07f(0x48c)]&&!_0xb1ba1d[_0x4c93bc+0x1][_0x4de07f(0x424)]('--')){_0x2bb554[_0x4de07f(0x488)](_0xb1ba1d[++_0x4c93bc]);}_0x6413d7[_0x4de07f(0x460)]=_0x2bb554['length']>0x0?_0x2bb554:!![];}else{if(_0x3b0649===_0x4de07f(0x23d))_0x6413d7['logRequests']=!![];else{if(_0x3b0649===_0x4de07f(0x351))_0x6413d7['name']=_0xb1ba1d[++_0x4c93bc];else{if(_0x3b0649===_0x4de07f(0x3f3))_0x6413d7[_0x4de07f(0x43b)]=_0xb1ba1d[++_0x4c93bc];else{if(_0x3b0649===_0x4de07f(0x2ae))_0x6413d7['label']=_0xb1ba1d[++_0x4c93bc];else{if(_0x3b0649===_0x4de07f(0x375))_0x6413d7[_0x4de07f(0x3cc)]=_0xb1ba1d[++_0x4c93bc];else{if(_0x3b0649===_0x4de07f(0x289))_0x6413d7[_0x4de07f(0x240)]=_0xb1ba1d[++_0x4c93bc];else{if(_0x3b0649===_0x4de07f(0x404))_0x6413d7['ttl']=_0xb1ba1d[++_0x4c93bc];else{if(_0x3b0649===_0x4de07f(0x3ee))_0x6413d7[_0x4de07f(0x438)]=_0xb1ba1d[++_0x4c93bc];else{if(_0x3b0649===_0x4de07f(0x1e4)||_0x3b0649==='-u')_0x6413d7['username']=_0xb1ba1d[++_0x4c93bc];else{if(_0x3b0649==='--address')_0x6413d7[_0x4de07f(0x2fb)]=_0xb1ba1d[++_0x4c93bc];else{if(_0x3b0649===_0x4de07f(0x26d)||_0x3b0649==='-v'){const _0x42146f=require$$2;console[_0x4de07f(0x499)](_0x42146f['version']),process[_0x4de07f(0x463)](0x0);}else(_0x3b0649===_0x4de07f(0x49d)||_0x3b0649==='-h')&&(_0x49a788(),process[_0x4de07f(0x463)](0x0));}}}}}}}}}}}}}}}}}}}}}}}_0x4c93bc++;}return _0x6413d7;}function _0x49a788(){const _0x1c510d=_0x3a4bd7;console[_0x1c510d(0x499)](_0x1c510d(0x1e8));}const _0x16bdcc=new Set(['debug',_0x3a4bd7(0x312),_0x3a4bd7(0x208),_0x3a4bd7(0x202)]);function _0x48c23c(_0x47937c){const _0x398fbf=_0x3a4bd7,_0x493a26=_0x47937c['config']?_0x4f4c56[_0x398fbf(0x3e6)](_0x47937c[_0x398fbf(0x42e)]):_0x4f4c56[_0x398fbf(0x3e6)](_0x398fbf(0x1ce));let _0xc5cd52={};if(_0x10d084['existsSync'](_0x493a26))try{const _0x594147=_0x10d084[_0x398fbf(0x389)](_0x493a26,_0x398fbf(0x484))[_0x398fbf(0x279)](/^\uFEFF/,'');_0xc5cd52=JSON['parse'](_0x594147),console[_0x398fbf(0x499)](_0x398fbf(0x450)+_0x493a26);}catch(_0x43e08b){console['error'](_0x398fbf(0x3f0)+_0x493a26+':\x20'+_0x43e08b[_0x398fbf(0x2a5)]),process[_0x398fbf(0x463)](0x1);}const _0x4281a3={'port':process.env.OKDB_PORT?Number(process.env.OKDB_PORT):undefined,'path':process.env.OKDB_PATH??undefined,'key':process.env.OKDB_KEY??undefined,'logLevel':process.env.OKDB_LOG_LEVEL??undefined,'noRepl':process.env.OKDB_NO_REPL==='1'?!![]:undefined,'noAdmin':process.env.OKDB_NO_ADMIN==='1'?!![]:undefined},_0x4d85b5={'port':_0x47937c['port']??_0xc5cd52['port']??_0x4281a3[_0x398fbf(0x21b)]??0x2124,'dbPath':_0x47937c[_0x398fbf(0x3c3)]??_0xc5cd52['path']??_0x4281a3['path']??_0x398fbf(0x452),'key':_0x47937c[_0x398fbf(0x22c)]??_0xc5cd52[_0x398fbf(0x22c)]??_0x4281a3[_0x398fbf(0x22c)]??undefined,'logLevel':_0x47937c[_0x398fbf(0x43e)]??_0xc5cd52['logLevel']??_0x4281a3[_0x398fbf(0x43e)]??'info','noRepl':_0x47937c[_0x398fbf(0x319)]??_0xc5cd52[_0x398fbf(0x319)]??_0x4281a3[_0x398fbf(0x319)]??![],'noAdmin':_0x47937c[_0x398fbf(0x1c0)]??_0xc5cd52[_0x398fbf(0x1c0)]??_0x4281a3['noAdmin']??![],'admin':_0xc5cd52[_0x398fbf(0x36f)]??{},'api':_0xc5cd52[_0x398fbf(0x46c)]??undefined,'auth':_0xc5cd52[_0x398fbf(0x395)]??undefined,'mcp':_0xc5cd52['mcp']??undefined,'timeMachine':_0xc5cd52[_0x398fbf(0x2a6)]!==![]?_0xc5cd52[_0x398fbf(0x2a6)]??{}:![]};return _0x47937c[_0x398fbf(0x460)]!==undefined&&(_0x4d85b5['auth']=_0x4d85b5[_0x398fbf(0x395)]||{},_0x4d85b5[_0x398fbf(0x395)][_0x398fbf(0x460)]=_0x47937c[_0x398fbf(0x460)]),_0x47937c[_0x398fbf(0x35b)]&&(_0x4d85b5[_0x398fbf(0x492)]=_0x4d85b5[_0x398fbf(0x492)]||{},_0x4d85b5[_0x398fbf(0x492)][_0x398fbf(0x35b)]=!![]),(!Number['isInteger'](_0x4d85b5['port'])||_0x4d85b5[_0x398fbf(0x21b)]<0x1||_0x4d85b5[_0x398fbf(0x21b)]>0xffff)&&(console['error'](_0x398fbf(0x47f)+_0x4d85b5[_0x398fbf(0x21b)]+_0x398fbf(0x332)),process[_0x398fbf(0x463)](0x1)),!_0x16bdcc[_0x398fbf(0x3fe)](_0x4d85b5[_0x398fbf(0x43e)])&&(console[_0x398fbf(0x202)]('[okdb]\x20invalid\x20log\x20level:\x20\x22'+_0x4d85b5[_0x398fbf(0x43e)]+'\x22\x20(must\x20be\x20debug|info|warn|error)'),process[_0x398fbf(0x463)](0x1)),_0x4d85b5;}function _0x55364b(_0x23c7de){const _0x1dcbd7=_0x3a4bd7;return!!(_0x23c7de&&typeof _0x23c7de===_0x1dcbd7(0x1ee)&&!Array[_0x1dcbd7(0x27d)](_0x23c7de)&&Object[_0x1dcbd7(0x3fd)](_0x23c7de)[_0x1dcbd7(0x48c)]>0x0);}const _0x526838=!process['stdout']['isTTY']||!!process.env.NO_COLOR;function _0x6dff8c(_0x2c6623,_0x47f9f2){return _0x526838?_0x47f9f2:'\x1b['+_0x2c6623+'m'+_0x47f9f2+'\x1b[0m';}function _0x2f6e85(_0x34f4ac){const _0x4ffb71=_0x3a4bd7;if(!_0x34f4ac||_0x34f4ac[_0x4ffb71(0x48c)]===0x0)return;const _0x503b6d='─'[_0x4ffb71(0x3cf)](0x38);process[_0x4ffb71(0x30d)]['write']('\x0a'),process[_0x4ffb71(0x30d)]['write'](_0x6dff8c('33',_0x4ffb71(0x29a)+_0x34f4ac[_0x4ffb71(0x48c)]+_0x4ffb71(0x3f4)+(_0x34f4ac[_0x4ffb71(0x48c)]>0x1?'S':'')+'\x0a')),process[_0x4ffb71(0x30d)]['write']('\x20\x20'+_0x503b6d+'\x0a');for(const _0x58ed83 of _0x34f4ac){const _0xe9fe7e=_0x58ed83['level']===_0x4ffb71(0x202)?_0x6dff8c('31','\x20\x20✗'):_0x6dff8c('33',_0x4ffb71(0x3a5));process[_0x4ffb71(0x30d)]['write'](_0xe9fe7e+'\x20\x20'+_0x6dff8c('1',_0x58ed83[_0x4ffb71(0x33b)])+'\x0a'),process[_0x4ffb71(0x30d)][_0x4ffb71(0x204)]('\x20\x20\x20\x20\x20\x20\x20'+_0x58ed83[_0x4ffb71(0x2a5)]+'\x0a');if(_0x58ed83[_0x4ffb71(0x3ad)])process[_0x4ffb71(0x30d)][_0x4ffb71(0x204)]('\x20\x20\x20\x20\x20\x20\x20'+_0x6dff8c('2',_0x4ffb71(0x1b6)+_0x58ed83[_0x4ffb71(0x3ad)])+'\x0a');process['stderr'][_0x4ffb71(0x204)]('\x0a');}process[_0x4ffb71(0x30d)][_0x4ffb71(0x204)]('\x20\x20'+_0x503b6d+'\x0a\x0a');}function _0x3936c6(_0x3c1f63,_0x43b750){const _0x58159c=_0x3a4bd7,_0x470d1a=_0x3c1f63[_0x58159c(0x39c)][_0x58159c(0x353)](_0x43b750);return new Promise((_0x4ba17d,_0x1d20b2)=>{const _0x504627=_0x58159c;_0x470d1a[_0x504627(0x329)](_0x504627(0x411),_0x4ba17d),_0x470d1a['once'](_0x504627(0x202),_0x1d20b2);});}async function _0x3f5db3(_0x3d0d7e){const _0x2089d4=_0x3a4bd7,_0x1d3baa=require$$3;console[_0x2089d4(0x499)](_0x2089d4(0x26e));let _0x20a124=!![];const _0x335d2e=(_0xab3640,_0x45913f)=>{const _0x44df15=_0x2089d4;console[_0x44df15(0x499)]('\x20\x20'+(_0xab3640?'✓':'✗')+'\x20'+_0x45913f);if(!_0xab3640)_0x20a124=![];},_0x3b4005=Number(process[_0x2089d4(0x209)]['replace']('v','')['split']('.')[0x0]);_0x335d2e(_0x3b4005>=0x12,_0x2089d4(0x203)+process[_0x2089d4(0x209)]+(_0x3b4005<0x12?_0x2089d4(0x3ea):''));const _0x2699ac=_0x4f4c56[_0x2089d4(0x3e6)](_0x3d0d7e[_0x2089d4(0x1ba)]);try{_0x10d084[_0x2089d4(0x439)](_0x2699ac,{'recursive':!![]});const _0xa3addc=_0x4f4c56[_0x2089d4(0x2d8)](_0x2699ac,_0x2089d4(0x35a));_0x10d084['writeFileSync'](_0xa3addc,''),_0x10d084[_0x2089d4(0x3b8)](_0xa3addc),_0x335d2e(!![],_0x2089d4(0x4ab)+_0x2699ac);}catch(_0xa118a7){_0x335d2e(![],_0x2089d4(0x3ec)+_0x2699ac+_0x2089d4(0x1c8)+_0xa118a7[_0x2089d4(0x2a5)]+')');}const _0x46e4bb=await new Promise(_0x4a7f8=>{const _0x32e058=_0x2089d4,_0x3cf61e=_0x1d3baa[_0x32e058(0x1ea)]();_0x3cf61e[_0x32e058(0x329)]('error',()=>_0x4a7f8(![])),_0x3cf61e[_0x32e058(0x329)](_0x32e058(0x411),()=>{const _0x18ff9f=_0x32e058;_0x3cf61e[_0x18ff9f(0x2d9)](),_0x4a7f8(!![]);}),_0x3cf61e[_0x32e058(0x353)](_0x3d0d7e[_0x32e058(0x21b)],'127.0.0.1');});_0x335d2e(_0x46e4bb,_0x2089d4(0x3b5)+_0x3d0d7e[_0x2089d4(0x21b)]+'\x20'+(_0x46e4bb?_0x2089d4(0x417):_0x2089d4(0x48a)));const _0x499e6c=_0x4f4c56[_0x2089d4(0x3e6)](_0x2089d4(0x1ce));if(_0x10d084['existsSync'](_0x499e6c))try{JSON[_0x2089d4(0x24b)](_0x10d084[_0x2089d4(0x389)](_0x499e6c,_0x2089d4(0x484))[_0x2089d4(0x279)](/^\uFEFF/,'')),_0x335d2e(!![],_0x2089d4(0x2e0)+_0x499e6c);}catch(_0x7169a2){_0x335d2e(![],'config\x20file\x20invalid:\x20'+_0x7169a2[_0x2089d4(0x2a5)]);}else _0x335d2e(!![],_0x2089d4(0x1c6));console[_0x2089d4(0x499)](''),_0x20a124?console[_0x2089d4(0x499)](_0x2089d4(0x423)):(console['log']('\x20\x20Some\x20checks\x20failed.\x0a'),process[_0x2089d4(0x463)](0x1));}async function _0x275e00(){const _0x52e2f1=_0x3a4bd7,_0x3bc988=_0x4f4c56['resolve'](_0x52e2f1(0x1ce));!_0x10d084['existsSync'](_0x3bc988)?(_0x10d084[_0x52e2f1(0x22d)](_0x3bc988,JSON[_0x52e2f1(0x379)]({'port':0x2124,'path':_0x52e2f1(0x452),'logLevel':_0x52e2f1(0x312),'noRepl':![],'noAdmin':![]},null,0x2)+'\x0a'),console['log'](_0x52e2f1(0x1cb))):console[_0x52e2f1(0x499)](_0x52e2f1(0x30b));const _0x40d280=_0x4f4c56[_0x52e2f1(0x3e6)]('./okdb-data');!_0x10d084[_0x52e2f1(0x293)](_0x40d280)?(_0x10d084[_0x52e2f1(0x439)](_0x40d280,{'recursive':!![]}),console[_0x52e2f1(0x499)]('[okdb]\x20created\x20./okdb-data')):console[_0x52e2f1(0x499)]('[okdb]\x20./okdb-data\x20already\x20exists\x20—\x20skipping'),console[_0x52e2f1(0x499)](_0x52e2f1(0x20e));}async function _0x201b7c(_0x1f1fc7){const _0x5ad22e=_0x3a4bd7,_0x5f54a0=_0x4f4c56[_0x5ad22e(0x3e6)](_0x1f1fc7['dbPath']);if(!_0x10d084[_0x5ad22e(0x293)](_0x5f54a0)){console[_0x5ad22e(0x499)](_0x5ad22e(0x448)+_0x5f54a0+_0x5ad22e(0x2c3));return;}const _0x3a636b=require$$0$2,_0x5720a3=_0x3a636b['createInterface']({'input':process[_0x5ad22e(0x429)],'output':process['stdout']}),_0x24aa1d=await new Promise(_0x22a236=>_0x5720a3[_0x5ad22e(0x1bf)](_0x5ad22e(0x45c)+_0x5f54a0+'?\x0a\x20\x20Type\x20\x22yes\x22\x20to\x20confirm:\x20',_0x22a236));_0x5720a3[_0x5ad22e(0x2d9)](),console['log']('');if(_0x24aa1d[_0x5ad22e(0x34d)]()['toLowerCase']()!==_0x5ad22e(0x413)){console[_0x5ad22e(0x499)](_0x5ad22e(0x2de));return;}_0x10d084[_0x5ad22e(0x31e)](_0x5f54a0,{'recursive':!![],'force':!![]}),console[_0x5ad22e(0x499)](_0x5ad22e(0x2bb)+_0x5f54a0+_0x5ad22e(0x23c));}async function _0xa4e409(_0x45e8a2,_0x1a021b){const _0x1e4588=_0x3a4bd7,_0x25b28f=require$$5,_0x489543=_0x4f4c56[_0x1e4588(0x3e6)](_0x1a021b[_0x1e4588(0x1ba)]);console[_0x1e4588(0x499)]('[okdb]\x20opening\x20'+_0x489543+'…');const _0x4f8326=new _0x25b28f(_0x489543,_0x1a021b[_0x1e4588(0x22c)]?{'encryptionKey':_0x1a021b[_0x1e4588(0x22c)]}:{});await _0x4f8326['open'](),console['log']('[okdb]\x20backing\x20up\x20to\x20'+_0x45e8a2+'…');const {envs:_0x2c8f56}=await _0x4f8326[_0x1e4588(0x427)][_0x1e4588(0x2aa)](_0x45e8a2);for(const _0x2a0d49 of _0x2c8f56){const _0x170e7a=_0x2a0d49['sizeBefore']>0x0?'\x20\x20('+(_0x2a0d49[_0x1e4588(0x44e)]/0x400/0x400)[_0x1e4588(0x1ff)](0x2)+_0x1e4588(0x44d)+(_0x2a0d49[_0x1e4588(0x2af)]/0x400/0x400)[_0x1e4588(0x1ff)](0x2)+_0x1e4588(0x32a):'';console['log'](_0x1e4588(0x233)+_0x2a0d49[_0x1e4588(0x2b5)]+_0x1e4588(0x1db)+_0x2a0d49['dest']+_0x170e7a);}await _0x4f8326[_0x1e4588(0x2d9)](),console[_0x1e4588(0x499)]('[okdb]\x20backup\x20complete');}async function _0x512c5f(_0x4dba18,_0x302f28,_0x308842){const _0x5ef43e=_0x3a4bd7,_0x1e5ee2=require$$5,_0x102045=_0x4f4c56['resolve'](_0x302f28[_0x5ef43e(0x1ba)]),_0xd691d9=_0x308842[_0x5ef43e(0x3ca)]??_0x5ef43e(0x200),_0x346f83=_0x308842[_0x5ef43e(0x25d)]?_0x308842[_0x5ef43e(0x25d)][_0x5ef43e(0x4a2)](',')['map'](_0xbda5ae=>_0xbda5ae[_0x5ef43e(0x34d)]()):null;console[_0x5ef43e(0x499)](_0x5ef43e(0x3a0)+_0x102045+'…');const _0x5534f5=new _0x1e5ee2(_0x102045,_0x302f28[_0x5ef43e(0x22c)]?{'encryptionKey':_0x302f28[_0x5ef43e(0x22c)]}:{});await _0x5534f5['open'](),console[_0x5ef43e(0x499)](_0x5ef43e(0x3ae)+_0xd691d9+_0x5ef43e(0x362)+_0x4dba18+'…');const _0x4aff3c=await _0x5534f5[_0x5ef43e(0x427)][_0x5ef43e(0x3e2)](_0x4dba18,{'envName':_0xd691d9,'types':_0x346f83,'includeChanges':!!_0x308842[_0x5ef43e(0x2c0)]});console[_0x5ef43e(0x499)]('[okdb]\x20exported\x20\x20types='+_0x4aff3c[_0x5ef43e(0x25d)]+_0x5ef43e(0x274)+_0x4aff3c['records']+_0x5ef43e(0x24e)+_0x4aff3c['changes']);if(_0x308842[_0x5ef43e(0x235)]){const _0x55184f=_0x4f4c56[_0x5ef43e(0x2d8)](_0x4f4c56[_0x5ef43e(0x3dc)](_0x4dba18),_0x5ef43e(0x235));process[_0x5ef43e(0x313)][_0x5ef43e(0x204)](_0x5ef43e(0x2a2));const {count:_0x343942,bytes:_0x52ca97}=await _0x5534f5[_0x5ef43e(0x427)]['exportBlobs'](_0x55184f);console[_0x5ef43e(0x499)](_0x5ef43e(0x4a7)+_0x55184f+'\x20\x20('+_0x343942+'\x20file'+(_0x343942!==0x1?'s':'')+',\x20'+(_0x52ca97/0x400/0x400)[_0x5ef43e(0x1ff)](0x2)+_0x5ef43e(0x32a));}await _0x5534f5[_0x5ef43e(0x2d9)](),console[_0x5ef43e(0x499)](_0x5ef43e(0x288));}async function _0x233b56(_0x2a98c0,_0x35a712,_0x3b2d2b){const _0x4527f6=_0x3a4bd7,_0x13eb26=require$$5,_0x501f8e=_0x4f4c56['resolve'](_0x35a712['dbPath']),_0x164f20=_0x3b2d2b['env']??null,_0x2f6a60=_0x3b2d2b[_0x4527f6(0x25d)]?_0x3b2d2b[_0x4527f6(0x25d)][_0x4527f6(0x4a2)](',')['map'](_0x14f415=>_0x14f415[_0x4527f6(0x34d)]()):null,_0x5a5901=!!_0x3b2d2b[_0x4527f6(0x325)];console[_0x4527f6(0x499)](_0x4527f6(0x3a0)+_0x501f8e+'…');const _0x293bf5=new _0x13eb26(_0x501f8e,_0x35a712[_0x4527f6(0x22c)]?{'encryptionKey':_0x35a712['key']}:{});await _0x293bf5[_0x4527f6(0x460)](),console['log'](_0x4527f6(0x1e0)+_0x2a98c0+'…');const _0x43c457=await _0x293bf5[_0x4527f6(0x427)][_0x4527f6(0x42a)](_0x2a98c0,{'envName':_0x164f20,'types':_0x2f6a60,'dropExisting':_0x5a5901,'includeChanges':!!_0x3b2d2b['changes'],'onProgress':({type:_0x245931,count:_0x44ff2e})=>{const _0x5ea5be=_0x4527f6;process['stdout'][_0x5ea5be(0x204)](_0x5ea5be(0x441)+_0x245931+':\x20'+_0x44ff2e+_0x5ea5be(0x336));}});process['stdout'][_0x4527f6(0x204)]('\x0a'),console[_0x4527f6(0x499)]('[okdb]\x20imported\x20\x20types='+_0x43c457[_0x4527f6(0x25d)]+'\x20\x20records='+_0x43c457[_0x4527f6(0x3bf)]+_0x4527f6(0x24e)+_0x43c457['changes']);if(_0x3b2d2b[_0x4527f6(0x235)]){const _0x32a6b0=_0x4f4c56[_0x4527f6(0x2d8)](_0x4f4c56[_0x4527f6(0x3dc)](_0x2a98c0),_0x4527f6(0x235));if(_0x10d084[_0x4527f6(0x293)](_0x32a6b0)){const {imported:_0x3a1b52,skipped:_0x3cafac}=await _0x293bf5[_0x4527f6(0x427)]['importBlobs'](_0x32a6b0);console[_0x4527f6(0x499)](_0x4527f6(0x1d7)+_0x3a1b52+_0x4527f6(0x28d)+_0x3cafac);}}await _0x293bf5['close'](),console['log'](_0x4527f6(0x3e3));}async function _0x59dc77(_0xc566fa,_0x534ed7){const _0x1c5517=_0x3a4bd7;_0x534ed7[_0x1c5517(0x43b)]&&!_0x534ed7[_0x1c5517(0x2b5)]&&(console[_0x1c5517(0x202)](_0x1c5517(0x4a4)),process[_0x1c5517(0x463)](0x1));const _0x2faf07=_0x534ed7[_0x1c5517(0x3cc)]?_0x534ed7[_0x1c5517(0x3cc)][_0x1c5517(0x4a2)](',')['map'](_0x38d6c6=>_0x38d6c6[_0x1c5517(0x34d)]())['filter'](Boolean):[];let _0x3ab8dc={};if(_0x534ed7[_0x1c5517(0x240)])try{_0x3ab8dc=JSON[_0x1c5517(0x24b)](_0x534ed7['grants']);if(typeof _0x3ab8dc!=='object'||Array['isArray'](_0x3ab8dc)||_0x3ab8dc===null)throw new Error();}catch{console[_0x1c5517(0x202)]('[okdb]\x20error:\x20--grants\x20must\x20be\x20valid\x20JSON\x20object'),process['exit'](0x1);}const _0x3ecb71=require$$5,{randomToken:_0x5a6c04,hashToken:_0x57e38d,hashPassword:_0x4d1650}=requireOkdbAuthTokens(),_0x3304ef=require$$0,_0x35eebc=_0x4f4c56[_0x1c5517(0x3e6)](_0xc566fa[_0x1c5517(0x1ba)]),_0x2f6156=new _0x3ecb71(_0x35eebc,_0xc566fa[_0x1c5517(0x22c)]?{'encryptionKey':_0xc566fa[_0x1c5517(0x22c)]}:{});await _0x2f6156['open']();try{await _0x2f6156[_0x1c5517(0x395)][_0x1c5517(0x1ef)]();if(_0x534ed7['name']){const _0x1bee4e=await _0x2f6156[_0x1c5517(0x395)][_0x1c5517(0x2d6)](_0x534ed7[_0x1c5517(0x2b5)]);_0x1bee4e&&(console[_0x1c5517(0x202)]('[okdb]\x20error:\x20token\x20with\x20name\x20\x22'+_0x534ed7['name']+_0x1c5517(0x39f)),process[_0x1c5517(0x463)](0x1));}const _0x39bcdb=_0x5a6c04(0x20),_0x510512=_0x57e38d(_0x39bcdb),_0x59b315=_0x534ed7[_0x1c5517(0x43b)]?await _0x4d1650(_0x534ed7[_0x1c5517(0x43b)]):null,_0x4fe61d=_0x3304ef[_0x1c5517(0x469)](),_0x3bc183={'tokenHash':_0x510512,'name':_0x534ed7[_0x1c5517(0x2b5)]||null,'passwordHash':_0x59b315,'label':_0x534ed7[_0x1c5517(0x3df)]||null,'permissions':_0x2faf07,'grants':_0x3ab8dc,'createdAt':Date[_0x1c5517(0x311)](),'lastUsedAt':null},_0x1c956d=_0x534ed7[_0x1c5517(0x40a)]?{'ttl':Number(_0x534ed7[_0x1c5517(0x40a)])}:undefined;await _0x2f6156[_0x1c5517(0x30f)][_0x1c5517(0x1c3)]('~tokens',_0x4fe61d,_0x3bc183,_0x1c956d),console['log']('\x0a\x20\x20✓\x20Token\x20created'),console[_0x1c5517(0x499)](_0x1c5517(0x2c6)+_0x4fe61d),console[_0x1c5517(0x499)](_0x1c5517(0x391)+(_0x534ed7['name']||_0x1c5517(0x29b))),console[_0x1c5517(0x499)](_0x1c5517(0x2ea)+(_0x534ed7[_0x1c5517(0x3df)]||'(unset)')),console[_0x1c5517(0x499)]('\x20\x20\x20\x20permissions:\x20'+(_0x2faf07['join'](',\x20')||_0x1c5517(0x322))),console[_0x1c5517(0x499)]('\x0a\x20\x20Raw\x20token\x20(shown\x20once,\x20save\x20it\x20now):\x0a'),console[_0x1c5517(0x499)]('\x20\x20\x20\x20'+_0x39bcdb+'\x0a');}finally{await _0x2f6156['close']();}}async function _0x401697(_0x5a70f8){const _0x5baeaa=_0x3a4bd7,_0x151a42=require$$5,_0x2d8646=_0x4f4c56[_0x5baeaa(0x3e6)](_0x5a70f8[_0x5baeaa(0x1ba)]),_0x25952e=new _0x151a42(_0x2d8646,_0x5a70f8[_0x5baeaa(0x22c)]?{'encryptionKey':_0x5a70f8[_0x5baeaa(0x22c)]}:{});await _0x25952e[_0x5baeaa(0x460)]();try{const _0x52874b=_0x25952e[_0x5baeaa(0x30f)];if(!_0x52874b||!_0x52874b[_0x5baeaa(0x3d7)](_0x5baeaa(0x330))){console[_0x5baeaa(0x499)](_0x5baeaa(0x3e8));return;}const _0x239759=[];for(const {key:_0x276fed,value:_0x5cc495}of _0x52874b[_0x5baeaa(0x2ee)](_0x5baeaa(0x330))){_0x239759['push']({'id':_0x276fed,'name':_0x5cc495[_0x5baeaa(0x2b5)]||_0x5baeaa(0x29b),'label':_0x5cc495[_0x5baeaa(0x3df)]||'(unset)','permissions':Array[_0x5baeaa(0x27d)](_0x5cc495[_0x5baeaa(0x3cc)])?_0x5cc495['permissions'][_0x5baeaa(0x2d8)](','):'','created':_0x5cc495[_0x5baeaa(0x1c9)]?new Date(_0x5cc495['createdAt'])[_0x5baeaa(0x2b3)]()[_0x5baeaa(0x1c2)](0x0,0xa):''});}if(_0x239759[_0x5baeaa(0x48c)]===0x0){console['log'](_0x5baeaa(0x3e8));return;}const _0x46d0ad=!process['stdout'][_0x5baeaa(0x2cd)]||process[_0x5baeaa(0x313)][_0x5baeaa(0x2cd)]>=0x64,_0x2d79b3=_0x46d0ad?0x24:0xa,_0x4cdba6=['ID'[_0x5baeaa(0x495)](_0x2d79b3),'NAME'[_0x5baeaa(0x495)](0x10),_0x5baeaa(0x3e9)[_0x5baeaa(0x495)](0x14),_0x5baeaa(0x2c4)[_0x5baeaa(0x495)](0x14),_0x5baeaa(0x2f6)][_0x5baeaa(0x2d8)]('\x20\x20');console['log']('\x0a'+_0x4cdba6),console['log']('-'[_0x5baeaa(0x3cf)](_0x4cdba6[_0x5baeaa(0x48c)]));for(const _0x5b89ea of _0x239759){const _0x588dfe=_0x46d0ad?_0x5b89ea['id']:_0x5b89ea['id']['slice'](0x0,0x8)+'…';console[_0x5baeaa(0x499)]([_0x588dfe[_0x5baeaa(0x495)](_0x2d79b3),_0x5b89ea[_0x5baeaa(0x2b5)][_0x5baeaa(0x1c2)](0x0,0x10)['padEnd'](0x10),_0x5b89ea[_0x5baeaa(0x3df)][_0x5baeaa(0x1c2)](0x0,0x14)[_0x5baeaa(0x495)](0x14),_0x5b89ea[_0x5baeaa(0x3cc)][_0x5baeaa(0x1c2)](0x0,0x14)['padEnd'](0x14),_0x5b89ea[_0x5baeaa(0x374)]][_0x5baeaa(0x2d8)]('\x20\x20'));}console['log']('');}finally{await _0x25952e[_0x5baeaa(0x2d9)]();}}async function _0x15f7af(_0x452884,_0x4f337b){const _0x5b0c06=_0x3a4bd7;!_0x452884&&(console[_0x5b0c06(0x202)](_0x5b0c06(0x272)),process[_0x5b0c06(0x463)](0x1));const _0x10e603=require$$5,_0x1c6109=_0x4f4c56[_0x5b0c06(0x3e6)](_0x4f337b[_0x5b0c06(0x1ba)]),_0x2545a7=new _0x10e603(_0x1c6109,_0x4f337b[_0x5b0c06(0x22c)]?{'encryptionKey':_0x4f337b[_0x5b0c06(0x22c)]}:{});await _0x2545a7['open']();try{const _0x4fb6b0=_0x2545a7[_0x5b0c06(0x30f)];(!_0x4fb6b0||!_0x4fb6b0[_0x5b0c06(0x3d7)](_0x5b0c06(0x330)))&&(console['error'](_0x5b0c06(0x2e8)+_0x452884+'\x22'),process[_0x5b0c06(0x463)](0x1));let _0x3e328d=null,_0x53dc31=null;const _0xf27a67=_0x4fb6b0[_0x5b0c06(0x26b)]('~tokens',_0x452884);if(_0xf27a67)_0x3e328d=_0x452884,_0x53dc31=_0xf27a67;else{const _0x24e423=[];for(const {key:_0x606fbb,value:_0x53bc72}of _0x4fb6b0['getRange'](_0x5b0c06(0x330))){if(_0x606fbb['startsWith'](_0x452884))_0x24e423[_0x5b0c06(0x488)]({'key':_0x606fbb,'value':_0x53bc72});}_0x24e423[_0x5b0c06(0x48c)]===0x0&&(console['error'](_0x5b0c06(0x2e8)+_0x452884+'\x22'),process[_0x5b0c06(0x463)](0x1));if(_0x24e423[_0x5b0c06(0x48c)]>0x1){console[_0x5b0c06(0x202)](_0x5b0c06(0x3c1)+_0x452884+_0x5b0c06(0x435)+_0x24e423[_0x5b0c06(0x48c)]+'\x20tokens:');for(const _0xf88b50 of _0x24e423){console[_0x5b0c06(0x202)]('\x20\x20'+_0xf88b50[_0x5b0c06(0x22c)]+_0x5b0c06(0x260)+(_0xf88b50[_0x5b0c06(0x3e0)][_0x5b0c06(0x2b5)]||'(unset)')+')');}process[_0x5b0c06(0x463)](0x1);}_0x3e328d=_0x24e423[0x0]['key'],_0x53dc31=_0x24e423[0x0][_0x5b0c06(0x3e0)];}await _0x4fb6b0[_0x5b0c06(0x24d)](_0x5b0c06(0x330),_0x3e328d),console[_0x5b0c06(0x499)](_0x5b0c06(0x437)+_0x3e328d+_0x5b0c06(0x260)+(_0x53dc31[_0x5b0c06(0x2b5)]||_0x5b0c06(0x29b))+_0x5b0c06(0x338)+(_0x53dc31[_0x5b0c06(0x3df)]||_0x5b0c06(0x29b))+')');}finally{await _0x2545a7[_0x5b0c06(0x2d9)]();}}function _0x405895(_0x1664da,_0x1951f3){const _0x1fe425=_0x3a4bd7;if(!_0x1664da[_0x1fe425(0x3a9)])return _0x1fe425(0x363);const _0x27d256=_0x1664da[_0x1fe425(0x214)];if(!_0x27d256)return _0x1fe425(0x2d3);if(_0x1951f3>_0x27d256)return _0x1fe425(0x4aa);return'active';}function _0x232e00(_0x31c120){const _0x261320=_0x3a4bd7;if(!_0x31c120||typeof _0x31c120!==_0x261320(0x1ee))return'';const _0x590116=Object['entries'](_0x31c120)['filter'](([,_0x392ede])=>_0x392ede)[_0x261320(0x308)](([_0x2398e8])=>_0x2398e8);if(_0x590116[_0x261320(0x48c)]===0x0)return _0x261320(0x322);if(_0x590116[_0x261320(0x48c)]<=0x3)return _0x590116[_0x261320(0x2d8)]('\x20');return _0x590116[_0x261320(0x1c2)](0x0,0x3)['join']('\x20')+('\x20+'+(_0x590116['length']-0x3));}async function _0x473950(_0x304dee){const _0x311870=_0x3a4bd7,_0x4e69af=require$$5,_0x4f0450=requireOkdbLicenseCodec(),{_C:_0x3737ad}=requireOkdbLicense(),_0x1dd362=_0x4f4c56[_0x311870(0x3e6)](_0x304dee['dbPath']),_0x4d0229=new _0x4e69af(_0x1dd362,_0x304dee[_0x311870(0x22c)]?{'encryptionKey':_0x304dee['key']}:{});await _0x4d0229['open']();try{const _0x15892a=_0x4d0229[_0x311870(0x30f)],_0x395506=_0x15892a?.['db']?.[_0x311870(0x26b)]?.(_0x311870(0x39d))??0x0,_0x4d203e=[..._0x4d0229['_envs'][_0x311870(0x3fd)]()][_0x311870(0x314)](_0x5f1729=>!_0x5f1729[_0x311870(0x424)]('~'))['length'],_0x497322=_0x4d0229[_0x311870(0x472)]?.[_0x311870(0x28b)];if(_0x497322){const _0x544592=_0x497322[_0x311870(0x30e)]===!![],_0x5ec47a=_0x544592?_0x311870(0x36d):_0x4d0229[_0x311870(0x472)][_0x311870(0x2d3)]?.[_0x311870(0x1ca)]||_0x311870(0x476);console[_0x311870(0x499)](''),console[_0x311870(0x499)]('\x20\x20Tier:\x20\x20\x20\x20'+_0x5ec47a);const _0x38f7d6=_0x497322[_0x311870(0x2a0)]||{};if(_0x38f7d6['maxWrites']){const _0x1ee82c=Math['round'](_0x395506/_0x38f7d6[_0x311870(0x1b3)]*0x64);console[_0x311870(0x499)]('\x20\x20Writes:\x20\x20'+_0x395506['toLocaleString']()+_0x311870(0x302)+_0x38f7d6[_0x311870(0x1b3)][_0x311870(0x3d8)]()+_0x311870(0x1c8)+_0x1ee82c+'%)');}else console[_0x311870(0x499)]('\x20\x20Writes:\x20\x20'+_0x395506[_0x311870(0x3d8)]());_0x38f7d6[_0x311870(0x431)]?console[_0x311870(0x499)]('\x20\x20Envs:\x20\x20\x20\x20'+_0x4d203e+'\x20/\x20'+_0x38f7d6[_0x311870(0x431)]):console[_0x311870(0x499)](_0x311870(0x1d3)+_0x4d203e),_0x3737ad?.['PUB_FINGERPRINT']&&console[_0x311870(0x499)]('\x20\x20Build:\x20\x20\x20key\x20fingerprint\x20'+_0x3737ad[_0x311870(0x20a)]+_0x311870(0x2f3));}if(!_0x15892a||!_0x15892a[_0x311870(0x3d7)](_0x311870(0x2c7))){console[_0x311870(0x499)](''),console[_0x311870(0x499)](_0x311870(0x3f6)),console[_0x311870(0x499)]('');return;}const _0x1d2c13=[],_0x413b99=Date[_0x311870(0x311)](),_0x5bc47c=_0x4d0229['id'],_0xc87421=_0x311870(0x385);for(const {key:_0x47c94f,value:_0x60ef0f}of _0x15892a[_0x311870(0x2ee)](_0x311870(0x2c7))){const _0x5c9d55=_0x60ef0f[_0x311870(0x20d)]?Buffer[_0x311870(0x252)](_0x60ef0f[_0x311870(0x20d)],_0x311870(0x269)):Buffer['alloc'](0x8);let _0x373945='';try{_0x373945=_0x4f0450[_0x311870(0x33e)](_0x5bc47c,_0x5c9d55,_0xc87421)[_0x311870(0x477)];}catch{}_0x1d2c13['push']({'id':_0x47c94f,'licensee':_0x60ef0f['licensee']||'','expires':_0x60ef0f[_0x311870(0x214)]?new Date(_0x60ef0f[_0x311870(0x214)])[_0x311870(0x2b3)]()[_0x311870(0x1c2)](0x0,0xa):'','features':_0x232e00(_0x60ef0f['features']),'pin':_0x373945,'status':_0x405895(_0x60ef0f,_0x413b99)});}if(_0x1d2c13[_0x311870(0x48c)]===0x0){console[_0x311870(0x499)](''),console[_0x311870(0x499)](_0x311870(0x3f6)),console[_0x311870(0x499)]('');return;}const _0x1dfad4=['\x20\x20'+'ID'['padEnd'](0xe),'LICENSEE'[_0x311870(0x495)](0xe),'EXPIRES'[_0x311870(0x495)](0xc),'FEATURES'['padEnd'](0x1e),_0x311870(0x280)[_0x311870(0x495)](0xa),_0x311870(0x253)][_0x311870(0x2d8)]('\x20');console[_0x311870(0x499)]('\x0a'+_0x1dfad4);for(const _0x341614 of _0x1d2c13){const _0x34bbf8=_0x341614['id'][_0x311870(0x1c2)](0x0,0x8)+'…';console[_0x311870(0x499)](['\x20\x20'+_0x34bbf8[_0x311870(0x495)](0xe),_0x341614['licensee'][_0x311870(0x1c2)](0x0,0xe)['padEnd'](0xe),_0x341614[_0x311870(0x380)][_0x311870(0x495)](0xc),_0x341614[_0x311870(0x221)]['slice'](0x0,0x1e)[_0x311870(0x495)](0x1e),_0x341614['pin'][_0x311870(0x495)](0xa),_0x341614[_0x311870(0x219)]]['join']('\x20'));}console[_0x311870(0x499)]('');}finally{await _0x4d0229[_0x311870(0x2d9)]();}}async function _0xec1910(_0xf79a3d,_0x3ea0a0){const _0x3287e0=_0x3a4bd7,_0x195a42=require$$5,_0x16d6d3=requireOkdbLicenseCodec();let _0x27e476=_0xf79a3d;(_0x16d6d3['detectInputType'](_0xf79a3d)===_0x3287e0(0x3c3)||_0x10d084[_0x3287e0(0x293)](_0xf79a3d)&&_0x10d084[_0x3287e0(0x3c5)](_0xf79a3d)[_0x3287e0(0x371)]())&&(_0x27e476=_0x10d084[_0x3287e0(0x389)](_0xf79a3d,_0x3287e0(0x484))['trim']());const _0x334daf=_0x4f4c56[_0x3287e0(0x3e6)](_0x3ea0a0[_0x3287e0(0x1ba)]),_0x41304a=new _0x195a42(_0x334daf,_0x3ea0a0[_0x3287e0(0x22c)]?{'encryptionKey':_0x3ea0a0[_0x3287e0(0x22c)]}:{});await _0x41304a['open']();try{!_0x41304a[_0x3287e0(0x472)]&&(console[_0x3287e0(0x202)](_0x3287e0(0x39e)),process[_0x3287e0(0x463)](0x1));let _0x4663b3;try{_0x4663b3=await _0x41304a[_0x3287e0(0x472)][_0x3287e0(0x334)](_0x27e476);}catch(_0x411bec){console[_0x3287e0(0x202)](_0x3287e0(0x456)+_0x411bec[_0x3287e0(0x2a5)]),process[_0x3287e0(0x463)](0x1);}const _0x5146c3=_0x41304a[_0x3287e0(0x472)]['getPins'](),_0x45bba2=_0x5146c3[_0x3287e0(0x485)](_0x9f3251=>_0x9f3251[_0x3287e0(0x2e7)]===_0x4663b3['id'])?.[_0x3287e0(0x477)]||'',_0x349bfb=Object[_0x3287e0(0x3f8)](_0x4663b3[_0x3287e0(0x221)]||{})[_0x3287e0(0x314)](([,_0x566376])=>_0x566376)[_0x3287e0(0x308)](([_0x2baaab])=>_0x2baaab),_0xf3f7e3=_0x4663b3[_0x3287e0(0x2a0)]||{},_0xbde93=[_0xf3f7e3['envs']?_0x3287e0(0x3b3)+_0xf3f7e3[_0x3287e0(0x431)]:null,_0xf3f7e3[_0x3287e0(0x388)]?_0x3287e0(0x3c2)+_0xf3f7e3[_0x3287e0(0x388)]:null,_0xf3f7e3[_0x3287e0(0x215)]?_0x3287e0(0x21c)+_0xf3f7e3[_0x3287e0(0x215)]:null,_0xf3f7e3[_0x3287e0(0x1b3)]?_0x3287e0(0x290)+_0xf3f7e3['maxWrites'][_0x3287e0(0x3d8)]():null][_0x3287e0(0x314)](Boolean)[_0x3287e0(0x2d8)]('\x20\x20'),_0x48dd67=_0x4663b3[_0x3287e0(0x396)]===_0x16d6d3[_0x3287e0(0x434)];console[_0x3287e0(0x499)](_0x3287e0(0x296)),console[_0x3287e0(0x499)]('\x20\x20\x20\x20id:\x20\x20\x20\x20\x20\x20\x20\x20'+_0x4663b3['id']),console[_0x3287e0(0x499)](_0x3287e0(0x35e)+_0x4663b3[_0x3287e0(0x1ca)]),console['log'](_0x3287e0(0x498)+new Date(_0x4663b3[_0x3287e0(0x214)])[_0x3287e0(0x2b3)]()[_0x3287e0(0x1c2)](0x0,0xa)),console[_0x3287e0(0x499)]('\x20\x20\x20\x20features:\x20\x20'+(_0x349bfb['join'](',\x20')||_0x3287e0(0x322)));if(_0xbde93)console[_0x3287e0(0x499)](_0x3287e0(0x43d)+_0xbde93);_0x48dd67?(console['log'](_0x3287e0(0x3a8)),console['log']('')):(console[_0x3287e0(0x499)](_0x3287e0(0x37a)+_0x45bba2),console['log'](_0x3287e0(0x410)),console[_0x3287e0(0x499)](''),console[_0x3287e0(0x499)](_0x3287e0(0x28e)),console[_0x3287e0(0x499)]('\x20\x20\x20\x201.\x20Send\x20the\x20PIN\x20above\x20('+_0x45bba2+_0x3287e0(0x2c8)),console[_0x3287e0(0x499)](_0x3287e0(0x2f0)),console[_0x3287e0(0x499)](_0x3287e0(0x2cc)),console['log'](''));}finally{await _0x41304a[_0x3287e0(0x2d9)]();}}async function _0x45889a(_0x112550,_0x2103f8){const _0x369b2b=_0x3a4bd7,_0x1da73a=require$$5,_0x124cf8=_0x4f4c56['resolve'](_0x2103f8[_0x369b2b(0x1ba)]),_0x88d429=new _0x1da73a(_0x124cf8,_0x2103f8['key']?{'encryptionKey':_0x2103f8[_0x369b2b(0x22c)]}:{});await _0x88d429[_0x369b2b(0x460)]();try{!_0x88d429['_license']&&(console[_0x369b2b(0x202)](_0x369b2b(0x39e)),process[_0x369b2b(0x463)](0x1));let _0xd52739;try{_0xd52739=await _0x88d429[_0x369b2b(0x472)]['activateLicense'](_0x112550[_0x369b2b(0x34d)]());}catch(_0x2b6033){console[_0x369b2b(0x202)](_0x369b2b(0x456)+_0x2b6033['message']),console['error'](''),console[_0x369b2b(0x202)](_0x369b2b(0x3f1)),console[_0x369b2b(0x202)]('\x20\x20\x20\x20-\x20The\x20license\x20blob\x20has\x20not\x20been\x20added\x20yet\x20—\x20run\x20`okdb\x20license\x20<blob>`\x20first.'),console[_0x369b2b(0x202)](_0x369b2b(0x445)),console[_0x369b2b(0x202)](_0x369b2b(0x3fa)),console[_0x369b2b(0x202)](''),process[_0x369b2b(0x463)](0x1);}console[_0x369b2b(0x499)](_0x369b2b(0x2d4)),console[_0x369b2b(0x499)](_0x369b2b(0x2a9)+_0xd52739['id']),console['log']('\x20\x20\x20\x20licensee:\x20\x20'+_0xd52739['licensee']),console['log']('\x20\x20\x20\x20expires:\x20\x20\x20'+new Date(_0xd52739[_0x369b2b(0x214)])[_0x369b2b(0x2b3)]()['slice'](0x0,0xa)),console['log'](_0x369b2b(0x210)),console[_0x369b2b(0x499)]('');}finally{await _0x88d429[_0x369b2b(0x2d9)]();}}async function _0x436e1e(_0x2afa42,_0x1488f8){const _0x479ad3=_0x3a4bd7;!_0x2afa42&&(console[_0x479ad3(0x202)](_0x479ad3(0x1b7)),process[_0x479ad3(0x463)](0x1));const _0x55ba62=require$$5,_0x4296f7=requireOkdbLicenseCodec(),_0x1195d9=_0x4f4c56[_0x479ad3(0x3e6)](_0x1488f8[_0x479ad3(0x1ba)]),_0x641376=new _0x55ba62(_0x1195d9,_0x1488f8[_0x479ad3(0x22c)]?{'encryptionKey':_0x1488f8[_0x479ad3(0x22c)]}:{});await _0x641376[_0x479ad3(0x460)]();try{const _0x11dc95=_0x641376['_systemEnv'];(!_0x11dc95||!_0x11dc95['hasType'](_0x479ad3(0x2c7)))&&(console[_0x479ad3(0x202)](_0x479ad3(0x378)+_0x2afa42+'\x22'),process['exit'](0x1));let _0x1e962d=null,_0x1b42c8=null;const _0x141908=_0x11dc95['get'](_0x479ad3(0x2c7),_0x2afa42);if(_0x141908)_0x1e962d=_0x2afa42,_0x1b42c8=_0x141908;else{const _0x54ea58=[];for(const {key:_0x22e512,value:_0x285df7}of _0x11dc95[_0x479ad3(0x2ee)](_0x479ad3(0x2c7))){if(_0x22e512[_0x479ad3(0x424)](_0x2afa42))_0x54ea58[_0x479ad3(0x488)]({'key':_0x22e512,'value':_0x285df7});}_0x54ea58[_0x479ad3(0x48c)]===0x0&&(console[_0x479ad3(0x202)](_0x479ad3(0x378)+_0x2afa42+'\x22'),process[_0x479ad3(0x463)](0x1)),_0x54ea58[_0x479ad3(0x48c)]>0x1&&(console[_0x479ad3(0x202)]('[okdb]\x20error:\x20ambiguous\x20prefix\x20\x22'+_0x2afa42+_0x479ad3(0x435)+_0x54ea58['length']+_0x479ad3(0x237)),process[_0x479ad3(0x463)](0x1)),_0x1e962d=_0x54ea58[0x0]['key'],_0x1b42c8=_0x54ea58[0x0][_0x479ad3(0x3e0)];}const _0x493347=Date[_0x479ad3(0x311)](),_0x4909b8=_0x405895(_0x1b42c8,_0x493347),_0x1e14e8=_0x641376['id'],_0x903b04=_0x479ad3(0x385);let _0x5039ce='';try{const _0x3bbd4f=Buffer[_0x479ad3(0x252)](_0x1b42c8[_0x479ad3(0x20d)],_0x479ad3(0x269));_0x5039ce=_0x4296f7['derivePin'](_0x1e14e8,_0x3bbd4f,_0x903b04)['pin'];}catch{}const _0x5423b8=_0x1b42c8[_0x479ad3(0x221)]?Object['entries'](_0x1b42c8['features'])['filter'](([,_0x585990])=>_0x585990)[_0x479ad3(0x308)](([_0x317eb0])=>_0x317eb0):[],_0x19f12c=_0x1b42c8[_0x479ad3(0x2a0)]||{},_0x504c24=_0x11dc95?.['db']?.[_0x479ad3(0x26b)]?.(_0x479ad3(0x39d))??0x0,_0x218afb=[..._0x641376[_0x479ad3(0x358)][_0x479ad3(0x3fd)]()][_0x479ad3(0x314)](_0x588d5f=>!_0x588d5f['startsWith']('~'))[_0x479ad3(0x48c)];console[_0x479ad3(0x499)]('\x0a\x20\x20License\x20details:'),console[_0x479ad3(0x499)](_0x479ad3(0x2a9)+_0x1e962d),console[_0x479ad3(0x499)](_0x479ad3(0x35e)+(_0x1b42c8[_0x479ad3(0x1ca)]||'')),console[_0x479ad3(0x499)](_0x479ad3(0x498)+(_0x1b42c8[_0x479ad3(0x214)]?new Date(_0x1b42c8[_0x479ad3(0x214)])[_0x479ad3(0x2b3)]()['slice'](0x0,0xa):'')),console[_0x479ad3(0x499)](_0x479ad3(0x1df)+(_0x5423b8[_0x479ad3(0x2d8)](',\x20')||_0x479ad3(0x322))),console[_0x479ad3(0x499)](_0x479ad3(0x37a)+_0x5039ce),console[_0x479ad3(0x499)](_0x479ad3(0x482)+_0x4909b8),console['log'](_0x479ad3(0x265)+new Date(_0x1b42c8[_0x479ad3(0x31b)])[_0x479ad3(0x2b3)]());if(_0x4909b8===_0x479ad3(0x2d3)){console[_0x479ad3(0x499)](''),console['log'](_0x479ad3(0x245));if(_0x19f12c[_0x479ad3(0x1b3)]){const _0x2c9893=Math[_0x479ad3(0x473)](_0x504c24/_0x19f12c[_0x479ad3(0x1b3)]*0x64);console[_0x479ad3(0x499)](_0x479ad3(0x40d)+_0x504c24[_0x479ad3(0x3d8)]()+_0x479ad3(0x302)+_0x19f12c[_0x479ad3(0x1b3)][_0x479ad3(0x3d8)]()+_0x479ad3(0x1c8)+_0x2c9893+'%)');}else console['log'](_0x479ad3(0x40d)+_0x504c24[_0x479ad3(0x3d8)]()+_0x479ad3(0x2fa));_0x19f12c['envs']?console[_0x479ad3(0x499)](_0x479ad3(0x21f)+_0x218afb+_0x479ad3(0x302)+_0x19f12c[_0x479ad3(0x431)]):console[_0x479ad3(0x499)]('\x20\x20\x20\x20envs:\x20\x20\x20\x20\x20\x20'+_0x218afb+_0x479ad3(0x2fa));}console[_0x479ad3(0x499)]('');}finally{await _0x641376[_0x479ad3(0x2d9)]();}}async function _0x938eb3(_0x431212,_0x3746b1){const _0x4c5772=_0x3a4bd7;!_0x431212&&(console[_0x4c5772(0x202)](_0x4c5772(0x37e)),process[_0x4c5772(0x463)](0x1));const _0x1b09fb=require$$5,_0x1f57cb=_0x4f4c56[_0x4c5772(0x3e6)](_0x3746b1[_0x4c5772(0x1ba)]),_0x2cc26a=new _0x1b09fb(_0x1f57cb,_0x3746b1[_0x4c5772(0x22c)]?{'encryptionKey':_0x3746b1['key']}:{});await _0x2cc26a[_0x4c5772(0x460)]();try{const _0x1cd4af=_0x2cc26a['_systemEnv'];(!_0x1cd4af||!_0x1cd4af['hasType'](_0x4c5772(0x2c7)))&&(console[_0x4c5772(0x202)]('[okdb]\x20error:\x20no\x20license\x20with\x20id\x20\x22'+_0x431212+'\x22'),process[_0x4c5772(0x463)](0x1));let _0x1c193a=null,_0x315899=null;const _0x316a4d=_0x1cd4af[_0x4c5772(0x26b)](_0x4c5772(0x2c7),_0x431212);if(_0x316a4d)_0x1c193a=_0x431212,_0x315899=_0x316a4d;else{const _0x12102=[];for(const {key:_0x3fa36c,value:_0xd90fe4}of _0x1cd4af[_0x4c5772(0x2ee)](_0x4c5772(0x2c7))){if(_0x3fa36c['startsWith'](_0x431212))_0x12102['push']({'key':_0x3fa36c,'value':_0xd90fe4});}_0x12102[_0x4c5772(0x48c)]===0x0&&(console[_0x4c5772(0x202)](_0x4c5772(0x378)+_0x431212+'\x22'),process['exit'](0x1)),_0x12102['length']>0x1&&(console[_0x4c5772(0x202)](_0x4c5772(0x3c1)+_0x431212+_0x4c5772(0x435)+_0x12102['length']+'\x20licenses'),process[_0x4c5772(0x463)](0x1)),_0x1c193a=_0x12102[0x0][_0x4c5772(0x22c)],_0x315899=_0x12102[0x0][_0x4c5772(0x3e0)];}await _0x1cd4af['remove'](_0x4c5772(0x2c7),_0x1c193a),console[_0x4c5772(0x499)]('\x20\x20✓\x20Removed\x20license\x20'+_0x1c193a+_0x4c5772(0x207)+(_0x315899[_0x4c5772(0x1ca)]||_0x4c5772(0x29b))+')');}finally{await _0x2cc26a[_0x4c5772(0x2d9)]();}}async function _0x273a12(_0x34286b,_0x4de309,_0x26573b){const _0x3cf085=_0x3a4bd7;!_0x34286b&&(console[_0x3cf085(0x202)](_0x3cf085(0x277)),process['exit'](0x1));!_0x26573b['token']&&!(_0x26573b[_0x3cf085(0x1e5)]&&_0x26573b[_0x3cf085(0x43b)])&&(console[_0x3cf085(0x202)](_0x3cf085(0x267)),process[_0x3cf085(0x463)](0x1));const _0x1d9424=_0x26573b[_0x3cf085(0x2fb)]||_0x4de309[_0x3cf085(0x346)]?.[_0x3cf085(0x1f1)];!_0x1d9424&&(console['error'](_0x3cf085(0x2b2)+_0x3cf085(0x3cb)+'\x20\x20Or\x20set\x20sync.address\x20in\x20.kdbconfig'),process[_0x3cf085(0x463)](0x1));const _0x42f588=require$$5,_0x5251ad=new _0x42f588(_0x4de309[_0x3cf085(0x1ba)],{'sync':{'address':_0x1d9424,'auto_reconcile':![]}});await _0x5251ad[_0x3cf085(0x460)]();try{const _0x56e960=_0x5251ad[_0x3cf085(0x30f)];if(_0x56e960&&_0x56e960[_0x3cf085(0x3d7)](_0x3cf085(0x330))){let _0x25694b=![];for(const _0x401f08 of _0x56e960[_0x3cf085(0x2ee)](_0x3cf085(0x330))){_0x25694b=!![];break;}_0x25694b&&console['log'](_0x3cf085(0x454)+_0x3cf085(0x1e6));}console[_0x3cf085(0x499)](_0x3cf085(0x3bc)+_0x34286b+'…'),await _0x5251ad[_0x3cf085(0x346)][_0x3cf085(0x2d8)](_0x34286b[_0x3cf085(0x279)](/\/+$/,''),{'token':_0x26573b['token'],'username':_0x26573b[_0x3cf085(0x1e5)],'password':_0x26573b['password']}),console[_0x3cf085(0x499)]('\x20\x20✓\x20joined\x20and\x20reconciliation\x20initiated'),console[_0x3cf085(0x499)]('\x0a\x20\x20Joined.\x20Remote\x20tokens\x20replicated.\x20You\x20can\x20now\x20log\x20in\x20with\x20cluster\x20credentials.\x0a');}finally{await _0x5251ad[_0x3cf085(0x2d9)]();}}async function _0x1c29b0(){const _0x132eae=_0x3a4bd7,_0x1bcbd7=Date[_0x132eae(0x311)](),_0x3b7506=_0x131052(process[_0x132eae(0x1b4)]),_0x3c9a82=_0x48c23c(_0x3b7506),_0xab8f72=_0x4f4c56[_0x132eae(0x3e6)](_0x3c9a82[_0x132eae(0x1ba)]);!_0x3c9a82[_0x132eae(0x319)]&&!process[_0x132eae(0x429)][_0x132eae(0x49a)]&&(_0x3c9a82['noRepl']=!![]);const _0x4a6b9b=require$$5,{start:_0x221a91,colorLog:_0x230e4f}=requireOkdbShell(),_0x3271f7={..._0x3c9a82[_0x132eae(0x22c)]?{'encryptionKey':_0x3c9a82['key']}:{},..._0x3c9a82['noAdmin']?{'admin':![]}:_0x55364b(_0x3c9a82[_0x132eae(0x36f)])?{'admin':_0x3c9a82[_0x132eae(0x36f)]}:{},..._0x55364b(_0x3c9a82['api'])?{'api':_0x3c9a82['api']}:{},..._0x55364b(_0x3c9a82['auth'])?{'auth':_0x3c9a82[_0x132eae(0x395)]}:{},..._0x55364b(_0x3c9a82[_0x132eae(0x44b)])?{'mcp':_0x3c9a82['mcp']}:{},..._0x3c9a82[_0x132eae(0x2a6)]!==![]?{'timeMachine':_0x3c9a82[_0x132eae(0x2a6)]}:{}},_0xed95e4=new _0x4a6b9b(_0xab8f72,_0x3271f7);_0xed95e4[_0x132eae(0x499)][_0x132eae(0x1bb)]?.();const _0x177736=_0xed95e4[_0x132eae(0x499)][_0x132eae(0x287)](_0x9fb748=>_0x230e4f(_0x9fb748,_0x3c9a82['logLevel']));if(_0x3c9a82[_0x132eae(0x319)])process['stdout'][_0x132eae(0x204)]('[okdb]\x20starting…\x0a');await _0xed95e4[_0x132eae(0x460)]();if(_0x3c9a82[_0x132eae(0x319)])process[_0x132eae(0x313)][_0x132eae(0x204)](_0x132eae(0x344));try{await _0x3936c6(_0xed95e4,_0x3c9a82[_0x132eae(0x21b)]);}catch(_0x17cd49){_0x17cd49[_0x132eae(0x2d7)]==='EADDRINUSE'&&(console[_0x132eae(0x202)](_0x132eae(0x433)+_0x3c9a82[_0x132eae(0x21b)]+'\x20already\x20in\x20use'),process[_0x132eae(0x463)](0x1));throw _0x17cd49;}if(_0x3c9a82[_0x132eae(0x319)])process[_0x132eae(0x313)][_0x132eae(0x204)](_0x132eae(0x23b)+_0x3c9a82[_0x132eae(0x21b)]+'\x0a');if(!_0x3c9a82[_0x132eae(0x319)])_0xed95e4[_0x132eae(0x499)][_0x132eae(0x1bb)]?.(),_0x177736?.(),_0x2f6e85(_0xed95e4['auth']?.[_0x132eae(0x2b4)]?.()??[]),await _0x221a91(_0xed95e4,_0x3c9a82);else{const _0x3de69d=_0x4f4c56['join'](_0xab8f72,_0x132eae(0x1fe));try{_0x10d084[_0x132eae(0x22d)](_0x3de69d,String(process[_0x132eae(0x2da)]));}catch{}const _0x449046=Date['now']()-_0x1bcbd7;console[_0x132eae(0x499)](''),console[_0x132eae(0x499)](_0x132eae(0x234)),console[_0x132eae(0x499)](_0x132eae(0x1eb)+_0x3c9a82[_0x132eae(0x21b)]),console[_0x132eae(0x499)](_0x132eae(0x4ac)+_0xab8f72),console['log'](_0x132eae(0x2bc)+_0xed95e4['id']);{const _0x415742=_0xed95e4[_0x132eae(0x30f)]?.['db']?.['get']?.(_0x132eae(0x39d))??0x0,_0x153744=[..._0xed95e4[_0x132eae(0x358)]['keys']()][_0x132eae(0x314)](_0xb041ee=>!_0xb041ee[_0x132eae(0x424)]('~'))[_0x132eae(0x48c)];if(_0xed95e4['_license']?.[_0x132eae(0x2d3)]?.[_0x132eae(0x396)]===0x1){const _0x47f667=Math[_0x132eae(0x2f5)]((_0xed95e4[_0x132eae(0x472)][_0x132eae(0x2d3)]['expiresAt']-Date['now']())/0x5265c00);console[_0x132eae(0x499)]('\x20\x20\x20\x20license:\x20⚠\x20OPEN\x20—\x20'+_0xed95e4['_license'][_0x132eae(0x2d3)]['licensee']+_0x132eae(0x415)+_0x47f667+_0x132eae(0x3b7));}else{if(_0xed95e4[_0x132eae(0x472)]?.[_0x132eae(0x2d3)]){const _0x238796=_0xed95e4[_0x132eae(0x472)]['active'];console[_0x132eae(0x499)]('\x20\x20\x20\x20license:\x20'+_0x238796[_0x132eae(0x1ca)]+_0x132eae(0x36c)+new Date(_0x238796[_0x132eae(0x214)])[_0x132eae(0x2b3)]()[_0x132eae(0x1c2)](0x0,0xa)+')');const _0x5070db=_0x238796[_0x132eae(0x2a0)]||{};if(_0x5070db['maxWrites']){const _0x5bbd34=Math[_0x132eae(0x473)](_0x415742/_0x5070db[_0x132eae(0x1b3)]*0x64);console[_0x132eae(0x499)](_0x132eae(0x2bf)+_0x415742['toLocaleString']()+_0x132eae(0x302)+_0x5070db[_0x132eae(0x1b3)]['toLocaleString']()+_0x132eae(0x2d0)+_0x5bbd34+'%),\x20'+_0x153744+(_0x5070db[_0x132eae(0x431)]?'/'+_0x5070db[_0x132eae(0x431)]:'')+_0x132eae(0x3f5)+(_0x153744===0x1?'':'s'));}}else{if(_0xed95e4[_0x132eae(0x472)]){const _0x1c8e54=_0xed95e4['_license']['getPins'](),_0x1c3cbd=_0x1c8e54[_0x132eae(0x48c)]?_0x1c8e54[_0x132eae(0x308)](_0x2c65bc=>_0x2c65bc[_0x132eae(0x477)])['join'](',\x20'):_0x132eae(0x430),_0x3f2582=_0xed95e4['_license']['effective'],_0xb807c2=_0x3f2582[_0x132eae(0x2a0)][_0x132eae(0x1b3)]?Math[_0x132eae(0x473)](_0x415742/_0x3f2582[_0x132eae(0x2a0)][_0x132eae(0x1b3)]*0x64):0x0;console[_0x132eae(0x499)](_0x132eae(0x49f)),console[_0x132eae(0x499)](_0x132eae(0x2bf)+_0x415742[_0x132eae(0x3d8)]()+'\x20/\x20'+_0x3f2582['limits'][_0x132eae(0x1b3)][_0x132eae(0x3d8)]()+'\x20writes\x20('+_0xb807c2+_0x132eae(0x22a)+_0x153744+_0x132eae(0x302)+_0x3f2582[_0x132eae(0x2a0)]['envs']+_0x132eae(0x1da)),console[_0x132eae(0x499)]('\x20\x20\x20\x20pin:\x20\x20\x20\x20\x20'+_0x1c3cbd);}}}}console['log']('\x20\x20\x20\x20api:\x20\x20\x20http://localhost:'+_0x3c9a82[_0x132eae(0x21b)]+'/api');!_0x3c9a82[_0x132eae(0x1c0)]&&console['log'](_0x132eae(0x263)+_0x3c9a82[_0x132eae(0x21b)]+_0x132eae(0x2e2));console['log'](''),console[_0x132eae(0x499)](_0x132eae(0x496)+_0x449046+'ms'),_0x2f6e85(_0xed95e4[_0x132eae(0x395)]?.[_0x132eae(0x2b4)]?.()??[]);async function _0x29d2ed(){const _0x4dab7=_0x132eae;process[_0x4dab7(0x313)][_0x4dab7(0x204)](_0x4dab7(0x370));try{_0x10d084['unlinkSync'](_0x3de69d);}catch{}await _0xed95e4[_0x4dab7(0x2d9)](),process['exit'](0x0);}process['on']('SIGINT',_0x29d2ed),process['on'](_0x132eae(0x324),_0x29d2ed);}}const _0x414bb1=new Set(['version',_0x3a4bd7(0x2f4),'init',_0x3a4bd7(0x2aa),_0x3a4bd7(0x2d5),_0x3a4bd7(0x497),'reset','token',_0x3a4bd7(0x2d8),_0x3a4bd7(0x1c7)]),_0x3b33e1=process[_0x3a4bd7(0x1b4)][0x2];if(_0x3b33e1===_0x3a4bd7(0x209))console['log'](require$$2[_0x3a4bd7(0x209)]),process['exit'](0x0);else{if(_0x3b33e1&&_0x414bb1[_0x3a4bd7(0x3fe)](_0x3b33e1)){const _0x11b3b6=process[_0x3a4bd7(0x1b4)][_0x3a4bd7(0x1c2)](0x3),_0x30cf9a=_0x131052(['node','okdb',..._0x11b3b6]),_0x4ebc2b=_0x48c23c(_0x30cf9a),_0x118c76=new Set(['--path','-d',_0x3a4bd7(0x2ef),'-k','--config','-c','--port','-p',_0x3a4bd7(0x316),_0x3a4bd7(0x44a),'-e',_0x3a4bd7(0x357),_0x3a4bd7(0x351),_0x3a4bd7(0x3f3),_0x3a4bd7(0x2ae),'--permissions',_0x3a4bd7(0x289),_0x3a4bd7(0x404),_0x3a4bd7(0x3ee),_0x3a4bd7(0x1e4),'-u',_0x3a4bd7(0x414)]);let _0x5bbdca=null;for(let _0x255e3c=0x0;_0x255e3c<_0x11b3b6[_0x3a4bd7(0x48c)];_0x255e3c++){if(_0x118c76[_0x3a4bd7(0x3fe)](_0x11b3b6[_0x255e3c])){_0x255e3c++;continue;}if(!_0x11b3b6[_0x255e3c][_0x3a4bd7(0x424)]('-')){_0x5bbdca=_0x11b3b6[_0x255e3c];break;}}(async()=>{const _0x54df21=_0x3a4bd7;if(_0x3b33e1===_0x54df21(0x438)){const _0x3b7e5d=process[_0x54df21(0x1b4)][0x3],_0x8fb7a8=process[_0x54df21(0x1b4)][_0x54df21(0x1c2)](0x4),_0x2b7bcf=_0x131052([_0x54df21(0x206),_0x54df21(0x250),..._0x8fb7a8]),_0x4a5b69=_0x48c23c(_0x2b7bcf),_0xb6dea=new Set([_0x54df21(0x31a),'-d',_0x54df21(0x2ef),'-k','--config','-c',_0x54df21(0x3da),'-p',_0x54df21(0x351),_0x54df21(0x3f3),_0x54df21(0x2ae),_0x54df21(0x375),_0x54df21(0x289),'--ttl',_0x54df21(0x316),_0x54df21(0x44a),'-e',_0x54df21(0x357)]),_0x4137ac=[];for(let _0x530b6d=0x0;_0x530b6d<_0x8fb7a8['length'];_0x530b6d++){if(_0xb6dea[_0x54df21(0x3fe)](_0x8fb7a8[_0x530b6d])){_0x530b6d++;continue;}if(_0x8fb7a8[_0x530b6d][_0x54df21(0x424)]('-'))continue;_0x4137ac[_0x54df21(0x488)](_0x8fb7a8[_0x530b6d]);}switch(_0x3b7e5d){case _0x54df21(0x343):await _0x59dc77(_0x4a5b69,_0x2b7bcf);break;case _0x54df21(0x3e7):await _0x401697(_0x4a5b69);break;case _0x54df21(0x26a):await _0x15f7af(_0x4137ac[0x0],_0x4a5b69);break;default:console[_0x54df21(0x202)](_0x54df21(0x1e1)+_0x3b7e5d+_0x54df21(0x425)),process[_0x54df21(0x463)](0x1);}return;}if(_0x3b33e1===_0x54df21(0x1c7)){const _0x294a9c=requireOkdbLicenseCodec(),_0x3c8d8a=process['argv']['slice'](0x3),_0x2eb426=_0x131052([_0x54df21(0x206),_0x54df21(0x250),..._0x3c8d8a]),_0x46b58f=_0x48c23c(_0x2eb426),_0x5dbcd7=new Set([_0x54df21(0x31a),'-d',_0x54df21(0x2ef),'-k','--config','-c',_0x54df21(0x3da),'-p',_0x54df21(0x316)]),_0x42adf9=[];for(let _0x3c5499=0x0;_0x3c5499<_0x3c8d8a[_0x54df21(0x48c)];_0x3c5499++){if(_0x5dbcd7[_0x54df21(0x3fe)](_0x3c8d8a[_0x3c5499])){_0x3c5499++;continue;}if(_0x3c8d8a[_0x3c5499][_0x54df21(0x424)]('-'))continue;_0x42adf9['push'](_0x3c8d8a[_0x3c5499]);}const _0x3227af=_0x42adf9[0x0]??null;if(_0x3227af===_0x54df21(0x24d))await _0x938eb3(_0x42adf9[0x1],_0x46b58f);else{if(!_0x3227af)await _0x473950(_0x46b58f);else{let _0x1ffc6f=_0x294a9c[_0x54df21(0x3ff)](_0x3227af);if(_0x1ffc6f===_0x54df21(0x273)&&_0x10d084[_0x54df21(0x293)](_0x3227af))_0x1ffc6f=_0x54df21(0x3c3);if(_0x1ffc6f===_0x54df21(0x3c3))try{const _0x557518=_0x10d084[_0x54df21(0x389)](_0x3227af,_0x54df21(0x484))[_0x54df21(0x34d)](),_0x5215de=_0x294a9c[_0x54df21(0x3ff)](_0x557518);if(_0x5215de==='activation'){await _0x45889a(_0x557518,_0x46b58f);return;}await _0xec1910(_0x3227af,_0x46b58f);return;}catch(_0x317f41){console['error'](_0x54df21(0x467)+_0x3227af+':\x20'+_0x317f41['message']),process[_0x54df21(0x463)](0x1);}switch(_0x1ffc6f){case _0x54df21(0x283):await _0xec1910(_0x3227af,_0x46b58f);break;case _0x54df21(0x3a9):await _0x45889a(_0x3227af,_0x46b58f);break;case _0x54df21(0x3cd):await _0x436e1e(_0x3227af,_0x46b58f);break;default:console[_0x54df21(0x202)](_0x54df21(0x39b)+_0x3227af+'\x22'),console['error'](''),console[_0x54df21(0x202)](_0x54df21(0x282)),console[_0x54df21(0x202)]('\x20\x20\x20\x20•\x20a\x20license\x20blob\x20\x20\x20(Crockford\x20base32,\x20~150–250\x20chars)'),console[_0x54df21(0x202)](_0x54df21(0x3a6)),console[_0x54df21(0x202)](_0x54df21(0x25b)),console[_0x54df21(0x202)](_0x54df21(0x3a4)),console[_0x54df21(0x202)](''),console[_0x54df21(0x202)](_0x54df21(0x276)),process[_0x54df21(0x463)](0x1);}}}return;}switch(_0x3b33e1){case _0x54df21(0x2f4):await _0x3f5db3(_0x4ebc2b);break;case _0x54df21(0x3d9):await _0x275e00();break;case'reset':await _0x201b7c(_0x4ebc2b);break;case _0x54df21(0x2aa):await _0xa4e409(_0x5bbdca??_0x4f4c56[_0x54df21(0x3e6)](_0x54df21(0x3bd)),_0x4ebc2b);break;case _0x54df21(0x2d5):await _0x512c5f(_0x5bbdca??_0x4f4c56[_0x54df21(0x3e6)](_0x54df21(0x3aa)),_0x4ebc2b,_0x30cf9a);break;case _0x54df21(0x497):await _0x233b56(_0x5bbdca??_0x4f4c56[_0x54df21(0x3e6)](_0x54df21(0x3aa)),_0x4ebc2b,_0x30cf9a);break;case _0x54df21(0x2d8):await _0x273a12(_0x5bbdca,_0x4ebc2b,_0x30cf9a);break;}})()[_0x3a4bd7(0x43c)](()=>process[_0x3a4bd7(0x463)](0x0))[_0x3a4bd7(0x3c7)](_0x3e8e65=>{const _0x57ef56=_0x3a4bd7;console[_0x57ef56(0x202)](_0x57ef56(0x361)+(_0x3e8e65[_0x57ef56(0x2a5)]||_0x3e8e65)+'\x0a'),process['exit'](0x1);});}else _0x1c29b0()['catch'](_0x432bef=>{const _0x44ee3c=_0x3a4bd7;console[_0x44ee3c(0x202)](_0x44ee3c(0x2ac)),console[_0x44ee3c(0x202)](_0x432bef[_0x44ee3c(0x41a)]||_0x432bef),process[_0x44ee3c(0x463)](0x1);});}return okdb$1;}var okdbExports=requireOkdb(),okdb=getDefaultExportFromCjs(okdbExports);module[_0x538f61(0x2d1)]=okdb;