@searchability/admin-client 0.0.18 → 0.0.19

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.
@@ -0,0 +1,15 @@
1
+ undefined&&undefined['__awaiter']||function(_0x5752fa,_0x11668b,_0x5d6697,_0x4716de){function _0x26f552(_0x51e87e){return _0x51e87e instanceof _0x5d6697?_0x51e87e:new _0x5d6697(function(_0x40c70e){_0x40c70e(_0x51e87e);});}return new(_0x5d6697||(_0x5d6697=Promise))(function(_0x4d24a8,_0x197e2d){function _0x24355f(_0x524591){try{_0x296b5b(_0x4716de['next'](_0x524591));}catch(_0x3c6680){_0x197e2d(_0x3c6680);}}function _0x1d5d38(_0x53b635){try{_0x296b5b(_0x4716de['throw'](_0x53b635));}catch(_0x550e80){_0x197e2d(_0x550e80);}}function _0x296b5b(_0xb960b9){_0xb960b9['done']?_0x4d24a8(_0xb960b9['value']):_0x26f552(_0xb960b9['value'])['then'](_0x24355f,_0x1d5d38);}_0x296b5b((_0x4716de=_0x4716de['apply'](_0x5752fa,_0x11668b||[]))['next']());});};
2
+
3
+ class Response{constructor(_0x4cd842){this['isSuccess']=_0x4cd842;}}class SuccessfulAccountResponse extends Response{constructor(_0x3c979a){super(!![]),this['account']=_0x3c979a;}['toSuccess'](){return this['account'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAccountResponse extends Response{constructor(_0x2542b4){super(![]),this['problem']=_0x2542b4;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulAuthResponse extends Response{constructor(_0x214b3f){super(!![]),this['tokens']=_0x214b3f;}['toSuccess'](){return this['tokens'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAuthResponse extends Response{constructor(_0x40acd9){super(![]),this['problem']=_0x40acd9;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulApiKeyResponse extends Response{constructor(_0x414f35){super(!![]),this['apiKeys']=_0x414f35;}['toSuccess'](){return this['apiKeys'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedApiKeyResponse extends Response{constructor(_0x5f8d5d){super(![]),this['problem']=_0x5f8d5d;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}
4
+
5
+ var __awaiter$4=undefined&&undefined['__awaiter']||function(_0x10c32f,_0x5a703f,_0x5ac711,_0x3721c9){function _0x547941(_0x36a478){return _0x36a478 instanceof _0x5ac711?_0x36a478:new _0x5ac711(function(_0x534d13){_0x534d13(_0x36a478);});}return new(_0x5ac711||(_0x5ac711=Promise))(function(_0x47072d,_0x2c96bd){function _0x4d00d7(_0x2432d3){try{_0xc02bf6(_0x3721c9['next'](_0x2432d3));}catch(_0x268f9f){_0x2c96bd(_0x268f9f);}}function _0x322f09(_0x774371){try{_0xc02bf6(_0x3721c9['throw'](_0x774371));}catch(_0x411e2c){_0x2c96bd(_0x411e2c);}}function _0xc02bf6(_0x4cab66){_0x4cab66['done']?_0x47072d(_0x4cab66['value']):_0x547941(_0x4cab66['value'])['then'](_0x4d00d7,_0x322f09);}_0xc02bf6((_0x3721c9=_0x3721c9['apply'](_0x10c32f,_0x5a703f||[]))['next']());});};class AccountService{constructor(_0x4dadc6){this['fetch']=_0x4dadc6;}['get'](_0x45686c,_0x31ceb7){return __awaiter$4(this,void 0,void 0,function*(){const _0x438504='Account/'+_0x45686c+'/',_0x4af386=yield this['fetch']['get'](_0x438504,_0x31ceb7);try{if(_0x4af386['status']>0xc7&&_0x4af386['status']<0x12c){const _0x329ff2=yield _0x4af386['json']();return new SuccessfulAccountResponse(_0x329ff2);}const _0x1ea9f9=yield _0x4af386['json']();return new FailedAccountResponse(_0x1ea9f9);}catch(_0x5e66ef){if(_0x5e66ef instanceof Error)return new FailedAccountResponse({'detail':_0x5e66ef['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x5e66ef;}});}}
6
+
7
+ var __awaiter$3=undefined&&undefined['__awaiter']||function(_0x493fbf,_0x2b3a8e,_0x532e4d,_0x3ab447){function _0x5e40ee(_0x56d398){return _0x56d398 instanceof _0x532e4d?_0x56d398:new _0x532e4d(function(_0x579e0e){_0x579e0e(_0x56d398);});}return new(_0x532e4d||(_0x532e4d=Promise))(function(_0x228706,_0x477131){function _0x250412(_0x3ac6bf){try{_0x2bbc83(_0x3ab447['next'](_0x3ac6bf));}catch(_0x240cea){_0x477131(_0x240cea);}}function _0x47ddc2(_0x2134f1){try{_0x2bbc83(_0x3ab447['throw'](_0x2134f1));}catch(_0xec1b59){_0x477131(_0xec1b59);}}function _0x2bbc83(_0x10ce95){_0x10ce95['done']?_0x228706(_0x10ce95['value']):_0x5e40ee(_0x10ce95['value'])['then'](_0x250412,_0x47ddc2);}_0x2bbc83((_0x3ab447=_0x3ab447['apply'](_0x493fbf,_0x2b3a8e||[]))['next']());});};class ApiKeyService{constructor(_0x43e298){this['fetch']=_0x43e298;}['create'](_0x3102ed,_0x2a82e5,_0xa0a72b){return __awaiter$3(this,void 0,void 0,function*(){const _0x800e6f='ApiKey/Create',_0x47359f={'account_name':_0x3102ed,'name':_0x2a82e5};try{const _0x4a4d13=yield this['fetch']['post'](_0x800e6f,_0xa0a72b,_0x47359f);if(_0x4a4d13['status']>0xc7&&_0x4a4d13['status']<0x12c){const _0x1880f5=yield _0x4a4d13['json']();return new SuccessfulApiKeyResponse(_0x1880f5);}const _0x593db8=yield _0x4a4d13['json']();return new FailedApiKeyResponse(_0x593db8);}catch(_0x40832a){if(_0x40832a instanceof Error)return new FailedApiKeyResponse({'detail':_0x40832a['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x40832a;}});}}
8
+
9
+ var __awaiter$2=undefined&&undefined['__awaiter']||function(_0x4d6946,_0x158da6,_0x23b090,_0x5321ef){function _0x255d11(_0x1daf43){return _0x1daf43 instanceof _0x23b090?_0x1daf43:new _0x23b090(function(_0x20df5f){_0x20df5f(_0x1daf43);});}return new(_0x23b090||(_0x23b090=Promise))(function(_0x345980,_0x130395){function _0xd8a402(_0x4bfe5d){try{_0x131506(_0x5321ef['next'](_0x4bfe5d));}catch(_0x16666a){_0x130395(_0x16666a);}}function _0x28ab9a(_0x268837){try{_0x131506(_0x5321ef['throw'](_0x268837));}catch(_0x4d7c7b){_0x130395(_0x4d7c7b);}}function _0x131506(_0x1a5e80){_0x1a5e80['done']?_0x345980(_0x1a5e80['value']):_0x255d11(_0x1a5e80['value'])['then'](_0xd8a402,_0x28ab9a);}_0x131506((_0x5321ef=_0x5321ef['apply'](_0x4d6946,_0x158da6||[]))['next']());});};class ListService{constructor(_0x1b4447){this['fetch']=_0x1b4447;}['add'](_0x2bb44d,_0x546294,_0x461737){return __awaiter$2(this,void 0,void 0,function*(){const _0xa5b684='List',_0x299626={'account_name':_0x2bb44d,'list_name':_0x546294};try{const _0xa074ae=yield this['fetch']['post'](_0xa5b684,_0x461737,_0x299626);if(_0xa074ae['status']>0xc7&&_0xa074ae['status']<0x12c){const _0xd32ffe=yield _0xa074ae['json']();return new SuccessfulAccountResponse(_0xd32ffe);}const _0x2ea622=yield _0xa074ae['json']();return new FailedAccountResponse(_0x2ea622);}catch(_0x584934){if(_0x584934 instanceof Error)return new FailedAccountResponse({'detail':_0x584934['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x584934;}});}['remove'](_0x244654,_0xf7bbc1,_0x5bcb72){return __awaiter$2(this,void 0,void 0,function*(){const _0x4aa5f7='List/'+_0x244654+'/'+_0xf7bbc1,_0x5bcc7b=yield this['fetch']['delete'](_0x4aa5f7,_0x5bcb72);try{if(_0x5bcc7b['status']>0xc7&&_0x5bcc7b['status']<0x12c){const _0x355b61=yield _0x5bcc7b['json']();return new SuccessfulAccountResponse(_0x355b61);}const _0x30eb7f=yield _0x5bcc7b['json']();return new FailedAccountResponse(_0x30eb7f);}catch(_0x1f7a31){if(_0x1f7a31 instanceof Error)return new FailedAccountResponse({'detail':_0x1f7a31['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x1f7a31;}});}}
10
+
11
+ var __awaiter$1=undefined&&undefined['__awaiter']||function(_0x5cce3a,_0x471e96,_0x51ab35,_0x488726){function _0x349cdb(_0x512f76){return _0x512f76 instanceof _0x51ab35?_0x512f76:new _0x51ab35(function(_0x4752ec){_0x4752ec(_0x512f76);});}return new(_0x51ab35||(_0x51ab35=Promise))(function(_0x46623c,_0x3845ca){function _0x379db1(_0x4c5992){try{_0x46f509(_0x488726['next'](_0x4c5992));}catch(_0x1e8aae){_0x3845ca(_0x1e8aae);}}function _0x3c157d(_0x153929){try{_0x46f509(_0x488726['throw'](_0x153929));}catch(_0x159cd1){_0x3845ca(_0x159cd1);}}function _0x46f509(_0x25017c){_0x25017c['done']?_0x46623c(_0x25017c['value']):_0x349cdb(_0x25017c['value'])['then'](_0x379db1,_0x3c157d);}_0x46f509((_0x488726=_0x488726['apply'](_0x5cce3a,_0x471e96||[]))['next']());});};class Fetch{constructor(_0x48cf35){this['baseUri']=_0x48cf35,this['getUrl']=_0x2e27f9=>{return _0x2e27f9['startsWith']('/')&&(_0x2e27f9=_0x2e27f9['replace']('/','')),''+this['baseUri']+_0x2e27f9;},!_0x48cf35['endsWith']('/')&&(_0x48cf35=_0x48cf35+'/');}['get'](_0x5e3020,_0x1ccf8f){return __awaiter$1(this,void 0,void 0,function*(){const _0x2ce524=this['getUrl'](_0x5e3020);return yield fetch(_0x2ce524,{'method':'GET','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x1ccf8f}});});}['post'](_0x129067,_0x50dd0c,_0x1ce492){return __awaiter$1(this,void 0,void 0,function*(){const _0x3efc81=this['getUrl'](_0x129067);return yield fetch(_0x3efc81,{'method':'POST','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x50dd0c},'body':_0x1ce492?JSON['stringify'](_0x1ce492):null});});}['put'](_0x1d21fb,_0x37d94e,_0x4d7e0f){return __awaiter$1(this,void 0,void 0,function*(){const _0x29e41d=this['getUrl'](_0x1d21fb);return yield fetch(_0x29e41d,{'method':'PUT','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x37d94e},'body':_0x4d7e0f?JSON['stringify'](_0x4d7e0f):null});});}['delete'](_0x35b1c5,_0x73c78e){return __awaiter$1(this,void 0,void 0,function*(){const _0x486371=this['getUrl'](_0x35b1c5);return yield fetch(_0x486371,{'method':'DELETE','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x73c78e}});});}}
12
+
13
+ var __awaiter=undefined&&undefined['__awaiter']||function(_0x1087ac,_0x592444,_0x869b98,_0x1c708b){function _0x164bed(_0x2c812e){return _0x2c812e instanceof _0x869b98?_0x2c812e:new _0x869b98(function(_0x3976c4){_0x3976c4(_0x2c812e);});}return new(_0x869b98||(_0x869b98=Promise))(function(_0x49d719,_0x332193){function _0x500ea4(_0x3675e0){try{_0x2b3a9c(_0x1c708b['next'](_0x3675e0));}catch(_0x4962f8){_0x332193(_0x4962f8);}}function _0x177d88(_0x1fd817){try{_0x2b3a9c(_0x1c708b['throw'](_0x1fd817));}catch(_0x2f2cfd){_0x332193(_0x2f2cfd);}}function _0x2b3a9c(_0x2b207b){_0x2b207b['done']?_0x49d719(_0x2b207b['value']):_0x164bed(_0x2b207b['value'])['then'](_0x500ea4,_0x177d88);}_0x2b3a9c((_0x1c708b=_0x1c708b['apply'](_0x1087ac,_0x592444||[]))['next']());});};class AdminClient{constructor(_0x671dc9='https://admin.searchability.dev/'){var _0x3d4602=new Fetch(_0x671dc9);this['Accounts']=new AccountService(_0x3d4602),this['Lists']=new ListService(_0x3d4602),this['ApiKeys']=new ApiKeyService(_0x3d4602);}}class AuthClient{constructor(_0x4e121a='https://auth.searchability.dev/'){this['fetch']=new Fetch(_0x4e121a);}['login'](_0x49d261){return __awaiter(this,void 0,void 0,function*(){var _0x4aca23='login/'+_0x49d261;try{const _0x435990=yield yield fetch(_0x4aca23);if(_0x435990['status']>0xc7&&_0x435990['status']<0x12c){const _0x2ee1c2=yield _0x435990['json']();return new SuccessfulAuthResponse(_0x2ee1c2);}const _0x3a4c1f=yield _0x435990['json']();return new FailedAuthResponse(_0x3a4c1f);}catch(_0xdfac83){if(_0xdfac83 instanceof Error)return new FailedAuthResponse({'detail':_0xdfac83['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0xdfac83;}});}['refresh'](_0xabba94){return __awaiter(this,void 0,void 0,function*(){var _0x5adb0f='refresh';try{const _0x12e09b=yield this['fetch']['post'](_0x5adb0f,_0xabba94,null);if(_0x12e09b['status']>0xc7&&_0x12e09b['status']<0x12c){const _0x5b9eee=yield _0x12e09b['json']();return new SuccessfulAuthResponse(_0x5b9eee);}const _0x218a4e=yield _0x12e09b['json']();return new FailedAuthResponse(_0x218a4e);}catch(_0x2ead5f){if(_0x2ead5f instanceof Error)return new FailedAuthResponse({'detail':_0x2ead5f['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x2ead5f;}});}}
14
+
15
+ export { AdminClient, AuthClient };
@@ -1,16 +1,18 @@
1
1
  'use strict';
2
2
 
3
- class Response{constructor(_0x10b4fb){this['isSuccess']=_0x10b4fb;}}class SuccessfulAccountResponse extends Response{constructor(_0x2f9118){super(!![]),this['account']=_0x2f9118;}['toSuccess'](){return this['account'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAccountResponse extends Response{constructor(_0x216fde){super(![]),this['problem']=_0x216fde;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulAuthResponse extends Response{constructor(_0x4ad05f){super(!![]),this['tokens']=_0x4ad05f;}['toSuccess'](){return this['tokens'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAuthResponse extends Response{constructor(_0x396e8c){super(![]),this['problem']=_0x396e8c;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulApiKeyResponse extends Response{constructor(_0x392c90){super(!![]),this['apiKeys']=_0x392c90;}['toSuccess'](){return this['apiKeys'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedApiKeyResponse extends Response{constructor(_0xf29cbe){super(![]),this['problem']=_0xf29cbe;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}
3
+ undefined&&undefined['__awaiter']||function(_0x5a3a39,_0x4b2db0,_0x124244,_0x1bf66b){function _0x4f5cb4(_0x2ad17){return _0x2ad17 instanceof _0x124244?_0x2ad17:new _0x124244(function(_0x5804e8){_0x5804e8(_0x2ad17);});}return new(_0x124244||(_0x124244=Promise))(function(_0x48d0e7,_0x2bfe18){function _0x8fe6e2(_0x416f54){try{_0x2c9684(_0x1bf66b['next'](_0x416f54));}catch(_0x22a44b){_0x2bfe18(_0x22a44b);}}function _0x19c1bb(_0x321a05){try{_0x2c9684(_0x1bf66b['throw'](_0x321a05));}catch(_0x4f2b53){_0x2bfe18(_0x4f2b53);}}function _0x2c9684(_0x2e8b8a){_0x2e8b8a['done']?_0x48d0e7(_0x2e8b8a['value']):_0x4f5cb4(_0x2e8b8a['value'])['then'](_0x8fe6e2,_0x19c1bb);}_0x2c9684((_0x1bf66b=_0x1bf66b['apply'](_0x5a3a39,_0x4b2db0||[]))['next']());});};
4
4
 
5
- var __awaiter$4=undefined&&undefined['__awaiter']||function(_0x6955be,_0x46dc77,_0xbaabe6,_0x3c593b){function _0x1fc67d(_0x266876){return _0x266876 instanceof _0xbaabe6?_0x266876:new _0xbaabe6(function(_0x5860a6){_0x5860a6(_0x266876);});}return new(_0xbaabe6||(_0xbaabe6=Promise))(function(_0x5c616e,_0x172eb8){function _0x5c90c5(_0x222a53){try{_0x367dd5(_0x3c593b['next'](_0x222a53));}catch(_0x2d1ce6){_0x172eb8(_0x2d1ce6);}}function _0x1be55b(_0xad9759){try{_0x367dd5(_0x3c593b['throw'](_0xad9759));}catch(_0x2f0ebe){_0x172eb8(_0x2f0ebe);}}function _0x367dd5(_0x59ca8d){_0x59ca8d['done']?_0x5c616e(_0x59ca8d['value']):_0x1fc67d(_0x59ca8d['value'])['then'](_0x5c90c5,_0x1be55b);}_0x367dd5((_0x3c593b=_0x3c593b['apply'](_0x6955be,_0x46dc77||[]))['next']());});};class AccountService{constructor(_0x41578f){this['fetch']=_0x41578f;}['get'](_0x4899d2,_0x5c11b4){return __awaiter$4(this,void 0,void 0,function*(){const _0x19ce1c='Account/'+_0x4899d2+'/',_0x4ac89c=yield this['fetch']['get'](_0x19ce1c,_0x5c11b4);try{if(_0x4ac89c['status']>0xc7&&_0x4ac89c['status']<0x12c){const _0xf3d307=yield _0x4ac89c['json']();return new SuccessfulAccountResponse(_0xf3d307);}const _0x1e4cf0=yield _0x4ac89c['json']();return new FailedAccountResponse(_0x1e4cf0);}catch(_0x3da305){if(_0x3da305 instanceof Error)return new FailedAccountResponse({'detail':_0x3da305['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x3da305;}});}}
5
+ class Response{constructor(_0x6261e8){this['isSuccess']=_0x6261e8;}}class SuccessfulAccountResponse extends Response{constructor(_0x39d384){super(!![]),this['account']=_0x39d384;}['toSuccess'](){return this['account'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAccountResponse extends Response{constructor(_0x1b3eaa){super(![]),this['problem']=_0x1b3eaa;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulAuthResponse extends Response{constructor(_0x2810a1){super(!![]),this['tokens']=_0x2810a1;}['toSuccess'](){return this['tokens'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAuthResponse extends Response{constructor(_0x4cafbb){super(![]),this['problem']=_0x4cafbb;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulApiKeyResponse extends Response{constructor(_0x34d443){super(!![]),this['apiKeys']=_0x34d443;}['toSuccess'](){return this['apiKeys'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedApiKeyResponse extends Response{constructor(_0x4c81f7){super(![]),this['problem']=_0x4c81f7;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}
6
6
 
7
- var __awaiter$3=undefined&&undefined['__awaiter']||function(_0x278523,_0x1cc72d,_0x5889ea,_0x23f8ca){function _0x3e5dc9(_0xb7db32){return _0xb7db32 instanceof _0x5889ea?_0xb7db32:new _0x5889ea(function(_0x575c15){_0x575c15(_0xb7db32);});}return new(_0x5889ea||(_0x5889ea=Promise))(function(_0x528f65,_0x2098d0){function _0x5118c7(_0x3715be){try{_0x8685a2(_0x23f8ca['next'](_0x3715be));}catch(_0x115221){_0x2098d0(_0x115221);}}function _0x14c396(_0x57b73a){try{_0x8685a2(_0x23f8ca['throw'](_0x57b73a));}catch(_0x5715de){_0x2098d0(_0x5715de);}}function _0x8685a2(_0x1ccd95){_0x1ccd95['done']?_0x528f65(_0x1ccd95['value']):_0x3e5dc9(_0x1ccd95['value'])['then'](_0x5118c7,_0x14c396);}_0x8685a2((_0x23f8ca=_0x23f8ca['apply'](_0x278523,_0x1cc72d||[]))['next']());});};class ApiKeyService{constructor(_0x28a205){this['fetch']=_0x28a205;}['create'](_0x55e587,_0x4e19f4,_0x283c91){return __awaiter$3(this,void 0,void 0,function*(){const _0x10a547='ApiKey/Create',_0x2c7f44={'account_name':_0x55e587,'name':_0x4e19f4};try{const _0x327485=yield this['fetch']['post'](_0x10a547,_0x283c91,_0x2c7f44);if(_0x327485['status']>0xc7&&_0x327485['status']<0x12c){const _0x12a077=yield _0x327485['json']();return new SuccessfulApiKeyResponse(_0x12a077);}const _0x573444=yield _0x327485['json']();return new FailedApiKeyResponse(_0x573444);}catch(_0x55e8da){if(_0x55e8da instanceof Error)return new FailedApiKeyResponse({'detail':_0x55e8da['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x55e8da;}});}}
7
+ var __awaiter$4=undefined&&undefined['__awaiter']||function(_0x638aa9,_0x5bee76,_0x49b5ca,_0x24c39b){function _0x1fe46f(_0x24a58c){return _0x24a58c instanceof _0x49b5ca?_0x24a58c:new _0x49b5ca(function(_0x164e7b){_0x164e7b(_0x24a58c);});}return new(_0x49b5ca||(_0x49b5ca=Promise))(function(_0x6f5cf5,_0x4f2398){function _0x46519b(_0xd12512){try{_0x3ce84e(_0x24c39b['next'](_0xd12512));}catch(_0x1cdfec){_0x4f2398(_0x1cdfec);}}function _0x69bde(_0x9f315){try{_0x3ce84e(_0x24c39b['throw'](_0x9f315));}catch(_0x1a2ef4){_0x4f2398(_0x1a2ef4);}}function _0x3ce84e(_0x5a407e){_0x5a407e['done']?_0x6f5cf5(_0x5a407e['value']):_0x1fe46f(_0x5a407e['value'])['then'](_0x46519b,_0x69bde);}_0x3ce84e((_0x24c39b=_0x24c39b['apply'](_0x638aa9,_0x5bee76||[]))['next']());});};class AccountService{constructor(_0x1477d2){this['fetch']=_0x1477d2;}['get'](_0x452bfa,_0x43a4e0){return __awaiter$4(this,void 0,void 0,function*(){const _0x459b6b='Account/'+_0x452bfa+'/',_0x123515=yield this['fetch']['get'](_0x459b6b,_0x43a4e0);try{if(_0x123515['status']>0xc7&&_0x123515['status']<0x12c){const _0x2ada05=yield _0x123515['json']();return new SuccessfulAccountResponse(_0x2ada05);}const _0x26eac9=yield _0x123515['json']();return new FailedAccountResponse(_0x26eac9);}catch(_0x5c9b1d){if(_0x5c9b1d instanceof Error)return new FailedAccountResponse({'detail':_0x5c9b1d['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x5c9b1d;}});}}
8
8
 
9
- var __awaiter$2=undefined&&undefined['__awaiter']||function(_0x395def,_0x322f12,_0xa7b00c,_0x155404){function _0x570eab(_0x559e38){return _0x559e38 instanceof _0xa7b00c?_0x559e38:new _0xa7b00c(function(_0x385707){_0x385707(_0x559e38);});}return new(_0xa7b00c||(_0xa7b00c=Promise))(function(_0x20577e,_0x45fbc9){function _0x2be27f(_0x1f2fa3){try{_0x8e85c6(_0x155404['next'](_0x1f2fa3));}catch(_0x2d218d){_0x45fbc9(_0x2d218d);}}function _0x722837(_0x5b5879){try{_0x8e85c6(_0x155404['throw'](_0x5b5879));}catch(_0x499184){_0x45fbc9(_0x499184);}}function _0x8e85c6(_0x47b4a7){_0x47b4a7['done']?_0x20577e(_0x47b4a7['value']):_0x570eab(_0x47b4a7['value'])['then'](_0x2be27f,_0x722837);}_0x8e85c6((_0x155404=_0x155404['apply'](_0x395def,_0x322f12||[]))['next']());});};class ListService{constructor(_0x28493f){this['fetch']=_0x28493f;}['add'](_0x1cebec,_0x417cdc,_0x432bcd){return __awaiter$2(this,void 0,void 0,function*(){const _0x22588c='List',_0x57ec71={'account_name':_0x1cebec,'list_name':_0x417cdc};try{const _0x42a97d=yield this['fetch']['post'](_0x22588c,_0x432bcd,_0x57ec71);if(_0x42a97d['status']>0xc7&&_0x42a97d['status']<0x12c){const _0x32baae=yield _0x42a97d['json']();return new SuccessfulAccountResponse(_0x32baae);}const _0x335941=yield _0x42a97d['json']();return new FailedAccountResponse(_0x335941);}catch(_0x1f9570){if(_0x1f9570 instanceof Error)return new FailedAccountResponse({'detail':_0x1f9570['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x1f9570;}});}['remove'](_0x21a727,_0x5caaae,_0x2c90c7){return __awaiter$2(this,void 0,void 0,function*(){const _0x129ec8='List/'+_0x21a727+'/'+_0x5caaae,_0x5cffb=yield this['fetch']['delete'](_0x129ec8,_0x2c90c7);try{if(_0x5cffb['status']>0xc7&&_0x5cffb['status']<0x12c){const _0x48f39b=yield _0x5cffb['json']();return new SuccessfulAccountResponse(_0x48f39b);}const _0x3db956=yield _0x5cffb['json']();return new FailedAccountResponse(_0x3db956);}catch(_0x3ba858){if(_0x3ba858 instanceof Error)return new FailedAccountResponse({'detail':_0x3ba858['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x3ba858;}});}}
9
+ var __awaiter$3=undefined&&undefined['__awaiter']||function(_0x297eab,_0x1ea1bc,_0x114ff4,_0x4ad39d){function _0x59d6e4(_0x86e2aa){return _0x86e2aa instanceof _0x114ff4?_0x86e2aa:new _0x114ff4(function(_0x1a6119){_0x1a6119(_0x86e2aa);});}return new(_0x114ff4||(_0x114ff4=Promise))(function(_0x5124e0,_0x39ab71){function _0x22e634(_0x598f7f){try{_0x26a4c3(_0x4ad39d['next'](_0x598f7f));}catch(_0x417eb0){_0x39ab71(_0x417eb0);}}function _0x32f4ef(_0x59222d){try{_0x26a4c3(_0x4ad39d['throw'](_0x59222d));}catch(_0x2af4c){_0x39ab71(_0x2af4c);}}function _0x26a4c3(_0x563776){_0x563776['done']?_0x5124e0(_0x563776['value']):_0x59d6e4(_0x563776['value'])['then'](_0x22e634,_0x32f4ef);}_0x26a4c3((_0x4ad39d=_0x4ad39d['apply'](_0x297eab,_0x1ea1bc||[]))['next']());});};class ApiKeyService{constructor(_0x6115e0){this['fetch']=_0x6115e0;}['create'](_0x3350ad,_0x48682a,_0x2ef38b){return __awaiter$3(this,void 0,void 0,function*(){const _0x52cbf4='ApiKey/Create',_0x562165={'account_name':_0x3350ad,'name':_0x48682a};try{const _0x29de61=yield this['fetch']['post'](_0x52cbf4,_0x2ef38b,_0x562165);if(_0x29de61['status']>0xc7&&_0x29de61['status']<0x12c){const _0x2fd35f=yield _0x29de61['json']();return new SuccessfulApiKeyResponse(_0x2fd35f);}const _0x321782=yield _0x29de61['json']();return new FailedApiKeyResponse(_0x321782);}catch(_0x5c263a){if(_0x5c263a instanceof Error)return new FailedApiKeyResponse({'detail':_0x5c263a['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x5c263a;}});}}
10
10
 
11
- var __awaiter$1=undefined&&undefined['__awaiter']||function(_0x30aa4a,_0x5d4c4d,_0x3000a3,_0x203364){function _0x53107f(_0x47fab1){return _0x47fab1 instanceof _0x3000a3?_0x47fab1:new _0x3000a3(function(_0x4c7d39){_0x4c7d39(_0x47fab1);});}return new(_0x3000a3||(_0x3000a3=Promise))(function(_0x3522f1,_0x4d5152){function _0x78f48e(_0x129b11){try{_0x2e78c7(_0x203364['next'](_0x129b11));}catch(_0x473ffd){_0x4d5152(_0x473ffd);}}function _0x23eef4(_0x27777c){try{_0x2e78c7(_0x203364['throw'](_0x27777c));}catch(_0xb8cba7){_0x4d5152(_0xb8cba7);}}function _0x2e78c7(_0x44d60b){_0x44d60b['done']?_0x3522f1(_0x44d60b['value']):_0x53107f(_0x44d60b['value'])['then'](_0x78f48e,_0x23eef4);}_0x2e78c7((_0x203364=_0x203364['apply'](_0x30aa4a,_0x5d4c4d||[]))['next']());});};class Fetch{constructor(_0x2bd28b){this['baseUri']=_0x2bd28b,this['getUrl']=_0x211916=>{return _0x211916['startsWith']('/')&&(_0x211916=_0x211916['replace']('/','')),''+this['baseUri']+_0x211916;},!_0x2bd28b['endsWith']('/')&&(_0x2bd28b=_0x2bd28b+'/');}['get'](_0x1fb400,_0x47936c){return __awaiter$1(this,void 0,void 0,function*(){const _0x2ead71=this['getUrl'](_0x1fb400);return yield fetch(_0x2ead71,{'method':'GET','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x47936c}});});}['post'](_0x3e94e7,_0x90dda6,_0x14b934){return __awaiter$1(this,void 0,void 0,function*(){const _0x5472bc=this['getUrl'](_0x3e94e7);return yield fetch(_0x5472bc,{'method':'POST','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x90dda6},'body':_0x14b934?JSON['stringify'](_0x14b934):null});});}['put'](_0x4d4e42,_0x2f8679,_0x571f38){return __awaiter$1(this,void 0,void 0,function*(){const _0x44de33=this['getUrl'](_0x4d4e42);return yield fetch(_0x44de33,{'method':'PUT','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x2f8679},'body':_0x571f38?JSON['stringify'](_0x571f38):null});});}['delete'](_0x19b830,_0x1ca631){return __awaiter$1(this,void 0,void 0,function*(){const _0x29cccd=this['getUrl'](_0x19b830);return yield fetch(_0x29cccd,{'method':'DELETE','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x1ca631}});});}}
11
+ var __awaiter$2=undefined&&undefined['__awaiter']||function(_0x3d9183,_0x3c1184,_0x108637,_0x2ffffe){function _0x4e2d48(_0xe7ac56){return _0xe7ac56 instanceof _0x108637?_0xe7ac56:new _0x108637(function(_0xd6db18){_0xd6db18(_0xe7ac56);});}return new(_0x108637||(_0x108637=Promise))(function(_0x17a555,_0x1c7ba7){function _0xcbfde6(_0x3eb90c){try{_0x1bcb35(_0x2ffffe['next'](_0x3eb90c));}catch(_0x1ad236){_0x1c7ba7(_0x1ad236);}}function _0x5ee071(_0x47284a){try{_0x1bcb35(_0x2ffffe['throw'](_0x47284a));}catch(_0x253d38){_0x1c7ba7(_0x253d38);}}function _0x1bcb35(_0x137445){_0x137445['done']?_0x17a555(_0x137445['value']):_0x4e2d48(_0x137445['value'])['then'](_0xcbfde6,_0x5ee071);}_0x1bcb35((_0x2ffffe=_0x2ffffe['apply'](_0x3d9183,_0x3c1184||[]))['next']());});};class ListService{constructor(_0x405058){this['fetch']=_0x405058;}['add'](_0xd35366,_0x13f56b,_0x2991bf){return __awaiter$2(this,void 0,void 0,function*(){const _0x370fbb='List',_0x40ea26={'account_name':_0xd35366,'list_name':_0x13f56b};try{const _0x576b49=yield this['fetch']['post'](_0x370fbb,_0x2991bf,_0x40ea26);if(_0x576b49['status']>0xc7&&_0x576b49['status']<0x12c){const _0x50f4c3=yield _0x576b49['json']();return new SuccessfulAccountResponse(_0x50f4c3);}const _0x5e27b1=yield _0x576b49['json']();return new FailedAccountResponse(_0x5e27b1);}catch(_0x4890e2){if(_0x4890e2 instanceof Error)return new FailedAccountResponse({'detail':_0x4890e2['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x4890e2;}});}['remove'](_0x5159b2,_0x1284ca,_0x1fa661){return __awaiter$2(this,void 0,void 0,function*(){const _0x1fbb63='List/'+_0x5159b2+'/'+_0x1284ca,_0x544dc4=yield this['fetch']['delete'](_0x1fbb63,_0x1fa661);try{if(_0x544dc4['status']>0xc7&&_0x544dc4['status']<0x12c){const _0x27310a=yield _0x544dc4['json']();return new SuccessfulAccountResponse(_0x27310a);}const _0x347eff=yield _0x544dc4['json']();return new FailedAccountResponse(_0x347eff);}catch(_0x54849a){if(_0x54849a instanceof Error)return new FailedAccountResponse({'detail':_0x54849a['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x54849a;}});}}
12
12
 
13
- var __awaiter=undefined&&undefined['__awaiter']||function(_0x1250c0,_0xef2dec,_0x2d42a6,_0x3b8607){function _0x429f4e(_0x45d6cf){return _0x45d6cf instanceof _0x2d42a6?_0x45d6cf:new _0x2d42a6(function(_0x190797){_0x190797(_0x45d6cf);});}return new(_0x2d42a6||(_0x2d42a6=Promise))(function(_0x6ccac3,_0x227987){function _0x2cf405(_0x259053){try{_0x1df859(_0x3b8607['next'](_0x259053));}catch(_0x2bb31c){_0x227987(_0x2bb31c);}}function _0x1114de(_0x3373ac){try{_0x1df859(_0x3b8607['throw'](_0x3373ac));}catch(_0x1dff6c){_0x227987(_0x1dff6c);}}function _0x1df859(_0x3dd516){_0x3dd516['done']?_0x6ccac3(_0x3dd516['value']):_0x429f4e(_0x3dd516['value'])['then'](_0x2cf405,_0x1114de);}_0x1df859((_0x3b8607=_0x3b8607['apply'](_0x1250c0,_0xef2dec||[]))['next']());});};class AdminClient{constructor(_0xbaa485='https://admin.searchability.dev/'){var _0x3a5d20=new Fetch(_0xbaa485);this['Accounts']=new AccountService(_0x3a5d20),this['Lists']=new ListService(_0x3a5d20),this['ApiKeys']=new ApiKeyService(_0x3a5d20);}}class AuthClient{constructor(_0x3aa3b9='https://auth.searchability.dev/'){this['fetch']=new Fetch(_0x3aa3b9);}['login'](_0x3abcb1){return __awaiter(this,void 0,void 0,function*(){var _0x564a0c='login/'+_0x3abcb1;try{const _0x39a80=yield yield fetch(_0x564a0c);if(_0x39a80['status']>0xc7&&_0x39a80['status']<0x12c){const _0x5dd986=yield _0x39a80['json']();return new SuccessfulAuthResponse(_0x5dd986);}const _0x5e664c=yield _0x39a80['json']();return new FailedAuthResponse(_0x5e664c);}catch(_0x4394f5){if(_0x4394f5 instanceof Error)return new FailedAuthResponse({'detail':_0x4394f5['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x4394f5;}});}['refresh'](_0x497a61){return __awaiter(this,void 0,void 0,function*(){var _0x2e57d7='refresh';try{const _0x1bdbf5=yield this['fetch']['post'](_0x2e57d7,_0x497a61,null);if(_0x1bdbf5['status']>0xc7&&_0x1bdbf5['status']<0x12c){const _0x4787f0=yield _0x1bdbf5['json']();return new SuccessfulAuthResponse(_0x4787f0);}const _0x94621c=yield _0x1bdbf5['json']();return new FailedAuthResponse(_0x94621c);}catch(_0x3db8e0){if(_0x3db8e0 instanceof Error)return new FailedAuthResponse({'detail':_0x3db8e0['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x3db8e0;}});}}
13
+ var __awaiter$1=undefined&&undefined['__awaiter']||function(_0x38d705,_0x28c9db,_0x45b149,_0x415d26){function _0x3595b3(_0x345d0d){return _0x345d0d instanceof _0x45b149?_0x345d0d:new _0x45b149(function(_0x5731c4){_0x5731c4(_0x345d0d);});}return new(_0x45b149||(_0x45b149=Promise))(function(_0x4df549,_0x2fb9eb){function _0x1cb0b4(_0x4eda17){try{_0x409df3(_0x415d26['next'](_0x4eda17));}catch(_0x2a98fb){_0x2fb9eb(_0x2a98fb);}}function _0x517736(_0x79f4c6){try{_0x409df3(_0x415d26['throw'](_0x79f4c6));}catch(_0x42561a){_0x2fb9eb(_0x42561a);}}function _0x409df3(_0x352f01){_0x352f01['done']?_0x4df549(_0x352f01['value']):_0x3595b3(_0x352f01['value'])['then'](_0x1cb0b4,_0x517736);}_0x409df3((_0x415d26=_0x415d26['apply'](_0x38d705,_0x28c9db||[]))['next']());});};class Fetch{constructor(_0x334189){this['baseUri']=_0x334189,this['getUrl']=_0x3607ed=>{return _0x3607ed['startsWith']('/')&&(_0x3607ed=_0x3607ed['replace']('/','')),''+this['baseUri']+_0x3607ed;},!_0x334189['endsWith']('/')&&(_0x334189=_0x334189+'/');}['get'](_0x445f7d,_0x333780){return __awaiter$1(this,void 0,void 0,function*(){const _0x54967c=this['getUrl'](_0x445f7d);return yield fetch(_0x54967c,{'method':'GET','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x333780}});});}['post'](_0x4bc071,_0xe27281,_0x1ae075){return __awaiter$1(this,void 0,void 0,function*(){const _0x57075a=this['getUrl'](_0x4bc071);return yield fetch(_0x57075a,{'method':'POST','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0xe27281},'body':_0x1ae075?JSON['stringify'](_0x1ae075):null});});}['put'](_0x4cde64,_0x17dbe0,_0x11ca4a){return __awaiter$1(this,void 0,void 0,function*(){const _0x14e033=this['getUrl'](_0x4cde64);return yield fetch(_0x14e033,{'method':'PUT','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x17dbe0},'body':_0x11ca4a?JSON['stringify'](_0x11ca4a):null});});}['delete'](_0x47b0ca,_0x57e746){return __awaiter$1(this,void 0,void 0,function*(){const _0x18ad7e=this['getUrl'](_0x47b0ca);return yield fetch(_0x18ad7e,{'method':'DELETE','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x57e746}});});}}
14
+
15
+ var __awaiter=undefined&&undefined['__awaiter']||function(_0x5ae4e8,_0x48869d,_0x517c83,_0x366159){function _0x261e4b(_0x3556e1){return _0x3556e1 instanceof _0x517c83?_0x3556e1:new _0x517c83(function(_0x38ef69){_0x38ef69(_0x3556e1);});}return new(_0x517c83||(_0x517c83=Promise))(function(_0x3411ca,_0xa25297){function _0xa8f513(_0x5c8a0b){try{_0x27bc60(_0x366159['next'](_0x5c8a0b));}catch(_0x2fa74a){_0xa25297(_0x2fa74a);}}function _0x5ac595(_0x2cc04f){try{_0x27bc60(_0x366159['throw'](_0x2cc04f));}catch(_0x2c9130){_0xa25297(_0x2c9130);}}function _0x27bc60(_0x33625d){_0x33625d['done']?_0x3411ca(_0x33625d['value']):_0x261e4b(_0x33625d['value'])['then'](_0xa8f513,_0x5ac595);}_0x27bc60((_0x366159=_0x366159['apply'](_0x5ae4e8,_0x48869d||[]))['next']());});};class AdminClient{constructor(_0x58c4eb='https://admin.searchability.dev/'){var _0x3d5929=new Fetch(_0x58c4eb);this['Accounts']=new AccountService(_0x3d5929),this['Lists']=new ListService(_0x3d5929),this['ApiKeys']=new ApiKeyService(_0x3d5929);}}class AuthClient{constructor(_0x58438c='https://auth.searchability.dev/'){this['fetch']=new Fetch(_0x58438c);}['login'](_0x39164a){return __awaiter(this,void 0,void 0,function*(){var _0x4728a3='login/'+_0x39164a;try{const _0x13f038=yield yield fetch(_0x4728a3);if(_0x13f038['status']>0xc7&&_0x13f038['status']<0x12c){const _0x303c46=yield _0x13f038['json']();return new SuccessfulAuthResponse(_0x303c46);}const _0x51d2b7=yield _0x13f038['json']();return new FailedAuthResponse(_0x51d2b7);}catch(_0x3e1c41){if(_0x3e1c41 instanceof Error)return new FailedAuthResponse({'detail':_0x3e1c41['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x3e1c41;}});}['refresh'](_0x121fa5){return __awaiter(this,void 0,void 0,function*(){var _0x1d99a2='refresh';try{const _0x529646=yield this['fetch']['post'](_0x1d99a2,_0x121fa5,null);if(_0x529646['status']>0xc7&&_0x529646['status']<0x12c){const _0xaae093=yield _0x529646['json']();return new SuccessfulAuthResponse(_0xaae093);}const _0x4e55c1=yield _0x529646['json']();return new FailedAuthResponse(_0x4e55c1);}catch(_0x167d20){if(_0x167d20 instanceof Error)return new FailedAuthResponse({'detail':_0x167d20['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x167d20;}});}}
14
16
 
15
17
  exports.AdminClient = AdminClient;
16
18
  exports.AuthClient = AuthClient;
@@ -1,13 +1,15 @@
1
- class Response{constructor(_0x2bb31a){this['isSuccess']=_0x2bb31a;}}class SuccessfulAccountResponse extends Response{constructor(_0x3c1cad){super(!![]),this['account']=_0x3c1cad;}['toSuccess'](){return this['account'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAccountResponse extends Response{constructor(_0x338b7b){super(![]),this['problem']=_0x338b7b;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulAuthResponse extends Response{constructor(_0x55735f){super(!![]),this['tokens']=_0x55735f;}['toSuccess'](){return this['tokens'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAuthResponse extends Response{constructor(_0x4fc299){super(![]),this['problem']=_0x4fc299;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulApiKeyResponse extends Response{constructor(_0x1196a2){super(!![]),this['apiKeys']=_0x1196a2;}['toSuccess'](){return this['apiKeys'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedApiKeyResponse extends Response{constructor(_0x51a2ed){super(![]),this['problem']=_0x51a2ed;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}
1
+ undefined&&undefined['__awaiter']||function(_0x25163a,_0x2cd093,_0x56c610,_0x437d07){function _0x35ad0f(_0x252ce7){return _0x252ce7 instanceof _0x56c610?_0x252ce7:new _0x56c610(function(_0xed7672){_0xed7672(_0x252ce7);});}return new(_0x56c610||(_0x56c610=Promise))(function(_0x3b3252,_0x42694f){function _0x245882(_0x1d71bd){try{_0x595711(_0x437d07['next'](_0x1d71bd));}catch(_0x406e25){_0x42694f(_0x406e25);}}function _0x329afd(_0x5e2dff){try{_0x595711(_0x437d07['throw'](_0x5e2dff));}catch(_0xb3dc33){_0x42694f(_0xb3dc33);}}function _0x595711(_0x596ffe){_0x596ffe['done']?_0x3b3252(_0x596ffe['value']):_0x35ad0f(_0x596ffe['value'])['then'](_0x245882,_0x329afd);}_0x595711((_0x437d07=_0x437d07['apply'](_0x25163a,_0x2cd093||[]))['next']());});};
2
2
 
3
- var __awaiter$4=undefined&&undefined['__awaiter']||function(_0x1efe11,_0x588157,_0x164773,_0x228247){function _0x45e598(_0x14ee82){return _0x14ee82 instanceof _0x164773?_0x14ee82:new _0x164773(function(_0x1b9fa3){_0x1b9fa3(_0x14ee82);});}return new(_0x164773||(_0x164773=Promise))(function(_0x397d1c,_0x56f20e){function _0x8c8a03(_0x46baf7){try{_0xc0d1cd(_0x228247['next'](_0x46baf7));}catch(_0x463047){_0x56f20e(_0x463047);}}function _0x78e5fa(_0x29b5a4){try{_0xc0d1cd(_0x228247['throw'](_0x29b5a4));}catch(_0x59d377){_0x56f20e(_0x59d377);}}function _0xc0d1cd(_0x52a47d){_0x52a47d['done']?_0x397d1c(_0x52a47d['value']):_0x45e598(_0x52a47d['value'])['then'](_0x8c8a03,_0x78e5fa);}_0xc0d1cd((_0x228247=_0x228247['apply'](_0x1efe11,_0x588157||[]))['next']());});};class AccountService{constructor(_0x3b47f6){this['fetch']=_0x3b47f6;}['get'](_0x2247d8,_0x37df25){return __awaiter$4(this,void 0,void 0,function*(){const _0x3eb7ff='Account/'+_0x2247d8+'/',_0x4d66be=yield this['fetch']['get'](_0x3eb7ff,_0x37df25);try{if(_0x4d66be['status']>0xc7&&_0x4d66be['status']<0x12c){const _0x5ea5e4=yield _0x4d66be['json']();return new SuccessfulAccountResponse(_0x5ea5e4);}const _0x8c8854=yield _0x4d66be['json']();return new FailedAccountResponse(_0x8c8854);}catch(_0x3448d6){if(_0x3448d6 instanceof Error)return new FailedAccountResponse({'detail':_0x3448d6['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x3448d6;}});}}
3
+ class Response{constructor(_0x3acc20){this['isSuccess']=_0x3acc20;}}class SuccessfulAccountResponse extends Response{constructor(_0x3a013b){super(!![]),this['account']=_0x3a013b;}['toSuccess'](){return this['account'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAccountResponse extends Response{constructor(_0x1a7c0a){super(![]),this['problem']=_0x1a7c0a;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulAuthResponse extends Response{constructor(_0x1fddfe){super(!![]),this['tokens']=_0x1fddfe;}['toSuccess'](){return this['tokens'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAuthResponse extends Response{constructor(_0x45075a){super(![]),this['problem']=_0x45075a;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulApiKeyResponse extends Response{constructor(_0x43d601){super(!![]),this['apiKeys']=_0x43d601;}['toSuccess'](){return this['apiKeys'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedApiKeyResponse extends Response{constructor(_0x2adf23){super(![]),this['problem']=_0x2adf23;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}
4
4
 
5
- var __awaiter$3=undefined&&undefined['__awaiter']||function(_0x16e741,_0x3fe147,_0x48dcb5,_0x51b576){function _0x4b1f03(_0x6293be){return _0x6293be instanceof _0x48dcb5?_0x6293be:new _0x48dcb5(function(_0xe7a046){_0xe7a046(_0x6293be);});}return new(_0x48dcb5||(_0x48dcb5=Promise))(function(_0x2f0dcc,_0x24d9ee){function _0x59ba50(_0x59f3e7){try{_0x458de7(_0x51b576['next'](_0x59f3e7));}catch(_0x1a2b18){_0x24d9ee(_0x1a2b18);}}function _0x3ecdd8(_0x2e4744){try{_0x458de7(_0x51b576['throw'](_0x2e4744));}catch(_0xaf1de0){_0x24d9ee(_0xaf1de0);}}function _0x458de7(_0x3f434f){_0x3f434f['done']?_0x2f0dcc(_0x3f434f['value']):_0x4b1f03(_0x3f434f['value'])['then'](_0x59ba50,_0x3ecdd8);}_0x458de7((_0x51b576=_0x51b576['apply'](_0x16e741,_0x3fe147||[]))['next']());});};class ApiKeyService{constructor(_0x1d9f4d){this['fetch']=_0x1d9f4d;}['create'](_0x563e88,_0xb5568d,_0x516045){return __awaiter$3(this,void 0,void 0,function*(){const _0x393c51='ApiKey/Create',_0x5a19ee={'account_name':_0x563e88,'name':_0xb5568d};try{const _0x4acf59=yield this['fetch']['post'](_0x393c51,_0x516045,_0x5a19ee);if(_0x4acf59['status']>0xc7&&_0x4acf59['status']<0x12c){const _0x48b3cc=yield _0x4acf59['json']();return new SuccessfulApiKeyResponse(_0x48b3cc);}const _0xaef4b1=yield _0x4acf59['json']();return new FailedApiKeyResponse(_0xaef4b1);}catch(_0x420382){if(_0x420382 instanceof Error)return new FailedApiKeyResponse({'detail':_0x420382['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x420382;}});}}
5
+ var __awaiter$4=undefined&&undefined['__awaiter']||function(_0x3c4753,_0x52680e,_0x19bd1f,_0x2dc09d){function _0x29af53(_0x4b0c76){return _0x4b0c76 instanceof _0x19bd1f?_0x4b0c76:new _0x19bd1f(function(_0xab98d2){_0xab98d2(_0x4b0c76);});}return new(_0x19bd1f||(_0x19bd1f=Promise))(function(_0x43ef76,_0x42a227){function _0x5380f3(_0x51427c){try{_0x5b3ee9(_0x2dc09d['next'](_0x51427c));}catch(_0x1d2f1c){_0x42a227(_0x1d2f1c);}}function _0x5875d7(_0x28a689){try{_0x5b3ee9(_0x2dc09d['throw'](_0x28a689));}catch(_0x33c07f){_0x42a227(_0x33c07f);}}function _0x5b3ee9(_0x27dc68){_0x27dc68['done']?_0x43ef76(_0x27dc68['value']):_0x29af53(_0x27dc68['value'])['then'](_0x5380f3,_0x5875d7);}_0x5b3ee9((_0x2dc09d=_0x2dc09d['apply'](_0x3c4753,_0x52680e||[]))['next']());});};class AccountService{constructor(_0x5736f2){this['fetch']=_0x5736f2;}['get'](_0x1e7994,_0x1523fe){return __awaiter$4(this,void 0,void 0,function*(){const _0x422eea='Account/'+_0x1e7994+'/',_0x19fb5d=yield this['fetch']['get'](_0x422eea,_0x1523fe);try{if(_0x19fb5d['status']>0xc7&&_0x19fb5d['status']<0x12c){const _0x358154=yield _0x19fb5d['json']();return new SuccessfulAccountResponse(_0x358154);}const _0x39556e=yield _0x19fb5d['json']();return new FailedAccountResponse(_0x39556e);}catch(_0x32c4c8){if(_0x32c4c8 instanceof Error)return new FailedAccountResponse({'detail':_0x32c4c8['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x32c4c8;}});}}
6
6
 
7
- var __awaiter$2=undefined&&undefined['__awaiter']||function(_0x2dedbc,_0x504b37,_0x20ffc4,_0x2255eb){function _0x594241(_0x342b6a){return _0x342b6a instanceof _0x20ffc4?_0x342b6a:new _0x20ffc4(function(_0x5a2bd4){_0x5a2bd4(_0x342b6a);});}return new(_0x20ffc4||(_0x20ffc4=Promise))(function(_0x12fd4b,_0xc3a875){function _0x1e8823(_0x2edb84){try{_0x1b8802(_0x2255eb['next'](_0x2edb84));}catch(_0xd7c45){_0xc3a875(_0xd7c45);}}function _0x3a129c(_0x115bf9){try{_0x1b8802(_0x2255eb['throw'](_0x115bf9));}catch(_0x27efa0){_0xc3a875(_0x27efa0);}}function _0x1b8802(_0x18ff2a){_0x18ff2a['done']?_0x12fd4b(_0x18ff2a['value']):_0x594241(_0x18ff2a['value'])['then'](_0x1e8823,_0x3a129c);}_0x1b8802((_0x2255eb=_0x2255eb['apply'](_0x2dedbc,_0x504b37||[]))['next']());});};class ListService{constructor(_0x1b9a74){this['fetch']=_0x1b9a74;}['add'](_0x1c9886,_0x2a61f4,_0x1d45be){return __awaiter$2(this,void 0,void 0,function*(){const _0x29f144='List',_0x1b4e7b={'account_name':_0x1c9886,'list_name':_0x2a61f4};try{const _0x53f488=yield this['fetch']['post'](_0x29f144,_0x1d45be,_0x1b4e7b);if(_0x53f488['status']>0xc7&&_0x53f488['status']<0x12c){const _0x57d44c=yield _0x53f488['json']();return new SuccessfulAccountResponse(_0x57d44c);}const _0x4bd56e=yield _0x53f488['json']();return new FailedAccountResponse(_0x4bd56e);}catch(_0xd67045){if(_0xd67045 instanceof Error)return new FailedAccountResponse({'detail':_0xd67045['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0xd67045;}});}['remove'](_0x3c37d0,_0xb1a3c1,_0x340d84){return __awaiter$2(this,void 0,void 0,function*(){const _0x3cd15a='List/'+_0x3c37d0+'/'+_0xb1a3c1,_0x4e072d=yield this['fetch']['delete'](_0x3cd15a,_0x340d84);try{if(_0x4e072d['status']>0xc7&&_0x4e072d['status']<0x12c){const _0x35ccdf=yield _0x4e072d['json']();return new SuccessfulAccountResponse(_0x35ccdf);}const _0x2de857=yield _0x4e072d['json']();return new FailedAccountResponse(_0x2de857);}catch(_0xab8c0d){if(_0xab8c0d instanceof Error)return new FailedAccountResponse({'detail':_0xab8c0d['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0xab8c0d;}});}}
7
+ var __awaiter$3=undefined&&undefined['__awaiter']||function(_0x52a64c,_0x58641b,_0x47c2ca,_0x8c76f0){function _0xcccad0(_0x2f3c7f){return _0x2f3c7f instanceof _0x47c2ca?_0x2f3c7f:new _0x47c2ca(function(_0x4aeb94){_0x4aeb94(_0x2f3c7f);});}return new(_0x47c2ca||(_0x47c2ca=Promise))(function(_0x5c9d78,_0x57a643){function _0x127f4e(_0x12a15e){try{_0x1ba5a6(_0x8c76f0['next'](_0x12a15e));}catch(_0x3eb407){_0x57a643(_0x3eb407);}}function _0x30bdb0(_0x16ecca){try{_0x1ba5a6(_0x8c76f0['throw'](_0x16ecca));}catch(_0x2ed893){_0x57a643(_0x2ed893);}}function _0x1ba5a6(_0xd15cc7){_0xd15cc7['done']?_0x5c9d78(_0xd15cc7['value']):_0xcccad0(_0xd15cc7['value'])['then'](_0x127f4e,_0x30bdb0);}_0x1ba5a6((_0x8c76f0=_0x8c76f0['apply'](_0x52a64c,_0x58641b||[]))['next']());});};class ApiKeyService{constructor(_0x5884a5){this['fetch']=_0x5884a5;}['create'](_0x36c24c,_0x3d05a6,_0x3e4b30){return __awaiter$3(this,void 0,void 0,function*(){const _0x2e30e6='ApiKey/Create',_0x7f8a7a={'account_name':_0x36c24c,'name':_0x3d05a6};try{const _0x29fedf=yield this['fetch']['post'](_0x2e30e6,_0x3e4b30,_0x7f8a7a);if(_0x29fedf['status']>0xc7&&_0x29fedf['status']<0x12c){const _0x4cbf04=yield _0x29fedf['json']();return new SuccessfulApiKeyResponse(_0x4cbf04);}const _0x323403=yield _0x29fedf['json']();return new FailedApiKeyResponse(_0x323403);}catch(_0x4b67d3){if(_0x4b67d3 instanceof Error)return new FailedApiKeyResponse({'detail':_0x4b67d3['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x4b67d3;}});}}
8
8
 
9
- var __awaiter$1=undefined&&undefined['__awaiter']||function(_0x5eead4,_0x1d186f,_0x4420f2,_0x5d598b){function _0x3a3f77(_0x440f8e){return _0x440f8e instanceof _0x4420f2?_0x440f8e:new _0x4420f2(function(_0x30ab7b){_0x30ab7b(_0x440f8e);});}return new(_0x4420f2||(_0x4420f2=Promise))(function(_0x1cd630,_0x294d71){function _0x461f31(_0x2d78b4){try{_0x2ec52e(_0x5d598b['next'](_0x2d78b4));}catch(_0x1db181){_0x294d71(_0x1db181);}}function _0x491e56(_0x2687d5){try{_0x2ec52e(_0x5d598b['throw'](_0x2687d5));}catch(_0x5969db){_0x294d71(_0x5969db);}}function _0x2ec52e(_0x4248a3){_0x4248a3['done']?_0x1cd630(_0x4248a3['value']):_0x3a3f77(_0x4248a3['value'])['then'](_0x461f31,_0x491e56);}_0x2ec52e((_0x5d598b=_0x5d598b['apply'](_0x5eead4,_0x1d186f||[]))['next']());});};class Fetch{constructor(_0x3980c7){this['baseUri']=_0x3980c7,this['getUrl']=_0x4a7cd0=>{return _0x4a7cd0['startsWith']('/')&&(_0x4a7cd0=_0x4a7cd0['replace']('/','')),''+this['baseUri']+_0x4a7cd0;},!_0x3980c7['endsWith']('/')&&(_0x3980c7=_0x3980c7+'/');}['get'](_0x22a324,_0x3430ba){return __awaiter$1(this,void 0,void 0,function*(){const _0x2ed50f=this['getUrl'](_0x22a324);return yield fetch(_0x2ed50f,{'method':'GET','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x3430ba}});});}['post'](_0x4b4355,_0x5e39ef,_0x488233){return __awaiter$1(this,void 0,void 0,function*(){const _0x176d98=this['getUrl'](_0x4b4355);return yield fetch(_0x176d98,{'method':'POST','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x5e39ef},'body':_0x488233?JSON['stringify'](_0x488233):null});});}['put'](_0x51d577,_0x3d81af,_0x201bd4){return __awaiter$1(this,void 0,void 0,function*(){const _0x12d97f=this['getUrl'](_0x51d577);return yield fetch(_0x12d97f,{'method':'PUT','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x3d81af},'body':_0x201bd4?JSON['stringify'](_0x201bd4):null});});}['delete'](_0x5b9de6,_0x14e815){return __awaiter$1(this,void 0,void 0,function*(){const _0x58c29f=this['getUrl'](_0x5b9de6);return yield fetch(_0x58c29f,{'method':'DELETE','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x14e815}});});}}
9
+ var __awaiter$2=undefined&&undefined['__awaiter']||function(_0x4fd7bf,_0x3e7276,_0x3e5528,_0x130860){function _0x3f822e(_0x1b2048){return _0x1b2048 instanceof _0x3e5528?_0x1b2048:new _0x3e5528(function(_0x721e1e){_0x721e1e(_0x1b2048);});}return new(_0x3e5528||(_0x3e5528=Promise))(function(_0x483e6f,_0x193fc3){function _0x36624a(_0x5f0140){try{_0x5fb01b(_0x130860['next'](_0x5f0140));}catch(_0x29f2b0){_0x193fc3(_0x29f2b0);}}function _0x299e2b(_0x5a870b){try{_0x5fb01b(_0x130860['throw'](_0x5a870b));}catch(_0x145e0e){_0x193fc3(_0x145e0e);}}function _0x5fb01b(_0x47354a){_0x47354a['done']?_0x483e6f(_0x47354a['value']):_0x3f822e(_0x47354a['value'])['then'](_0x36624a,_0x299e2b);}_0x5fb01b((_0x130860=_0x130860['apply'](_0x4fd7bf,_0x3e7276||[]))['next']());});};class ListService{constructor(_0x2e4d46){this['fetch']=_0x2e4d46;}['add'](_0x4bcf41,_0x37ae8d,_0x30bb8c){return __awaiter$2(this,void 0,void 0,function*(){const _0x1181b5='List',_0x5ef467={'account_name':_0x4bcf41,'list_name':_0x37ae8d};try{const _0x53858e=yield this['fetch']['post'](_0x1181b5,_0x30bb8c,_0x5ef467);if(_0x53858e['status']>0xc7&&_0x53858e['status']<0x12c){const _0x36f3cb=yield _0x53858e['json']();return new SuccessfulAccountResponse(_0x36f3cb);}const _0x10dee1=yield _0x53858e['json']();return new FailedAccountResponse(_0x10dee1);}catch(_0x5319db){if(_0x5319db instanceof Error)return new FailedAccountResponse({'detail':_0x5319db['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x5319db;}});}['remove'](_0x447e2e,_0x27b8fe,_0x44a3f7){return __awaiter$2(this,void 0,void 0,function*(){const _0x2f3420='List/'+_0x447e2e+'/'+_0x27b8fe,_0x48baa7=yield this['fetch']['delete'](_0x2f3420,_0x44a3f7);try{if(_0x48baa7['status']>0xc7&&_0x48baa7['status']<0x12c){const _0x17b2ec=yield _0x48baa7['json']();return new SuccessfulAccountResponse(_0x17b2ec);}const _0x371b60=yield _0x48baa7['json']();return new FailedAccountResponse(_0x371b60);}catch(_0x526098){if(_0x526098 instanceof Error)return new FailedAccountResponse({'detail':_0x526098['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x526098;}});}}
10
10
 
11
- var __awaiter=undefined&&undefined['__awaiter']||function(_0x38139e,_0x23047d,_0x509e62,_0x19ce10){function _0x5b4376(_0x2a5ddc){return _0x2a5ddc instanceof _0x509e62?_0x2a5ddc:new _0x509e62(function(_0x492c16){_0x492c16(_0x2a5ddc);});}return new(_0x509e62||(_0x509e62=Promise))(function(_0x21796c,_0x469b59){function _0x249213(_0x4fc37d){try{_0x564413(_0x19ce10['next'](_0x4fc37d));}catch(_0x52742c){_0x469b59(_0x52742c);}}function _0x552052(_0x3b2f5e){try{_0x564413(_0x19ce10['throw'](_0x3b2f5e));}catch(_0x599c0e){_0x469b59(_0x599c0e);}}function _0x564413(_0x11a724){_0x11a724['done']?_0x21796c(_0x11a724['value']):_0x5b4376(_0x11a724['value'])['then'](_0x249213,_0x552052);}_0x564413((_0x19ce10=_0x19ce10['apply'](_0x38139e,_0x23047d||[]))['next']());});};class AdminClient{constructor(_0x458e03='https://admin.searchability.dev/'){var _0x2c941b=new Fetch(_0x458e03);this['Accounts']=new AccountService(_0x2c941b),this['Lists']=new ListService(_0x2c941b),this['ApiKeys']=new ApiKeyService(_0x2c941b);}}class AuthClient{constructor(_0x28e12e='https://auth.searchability.dev/'){this['fetch']=new Fetch(_0x28e12e);}['login'](_0x339cc6){return __awaiter(this,void 0,void 0,function*(){var _0x399e60='login/'+_0x339cc6;try{const _0x472016=yield yield fetch(_0x399e60);if(_0x472016['status']>0xc7&&_0x472016['status']<0x12c){const _0x242641=yield _0x472016['json']();return new SuccessfulAuthResponse(_0x242641);}const _0x470c1a=yield _0x472016['json']();return new FailedAuthResponse(_0x470c1a);}catch(_0x25f84c){if(_0x25f84c instanceof Error)return new FailedAuthResponse({'detail':_0x25f84c['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x25f84c;}});}['refresh'](_0x3b10ec){return __awaiter(this,void 0,void 0,function*(){var _0x591186='refresh';try{const _0x2c3815=yield this['fetch']['post'](_0x591186,_0x3b10ec,null);if(_0x2c3815['status']>0xc7&&_0x2c3815['status']<0x12c){const _0x5aee4e=yield _0x2c3815['json']();return new SuccessfulAuthResponse(_0x5aee4e);}const _0x2634f1=yield _0x2c3815['json']();return new FailedAuthResponse(_0x2634f1);}catch(_0x2fd994){if(_0x2fd994 instanceof Error)return new FailedAuthResponse({'detail':_0x2fd994['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x2fd994;}});}}
11
+ var __awaiter$1=undefined&&undefined['__awaiter']||function(_0x500f64,_0x374050,_0x63ef5b,_0x121883){function _0x27ae9a(_0x703431){return _0x703431 instanceof _0x63ef5b?_0x703431:new _0x63ef5b(function(_0x57094c){_0x57094c(_0x703431);});}return new(_0x63ef5b||(_0x63ef5b=Promise))(function(_0x344238,_0x2d47be){function _0x3bebdf(_0x4b744e){try{_0x5ce552(_0x121883['next'](_0x4b744e));}catch(_0x271f45){_0x2d47be(_0x271f45);}}function _0x5eb669(_0x1a8dea){try{_0x5ce552(_0x121883['throw'](_0x1a8dea));}catch(_0x389204){_0x2d47be(_0x389204);}}function _0x5ce552(_0x58c370){_0x58c370['done']?_0x344238(_0x58c370['value']):_0x27ae9a(_0x58c370['value'])['then'](_0x3bebdf,_0x5eb669);}_0x5ce552((_0x121883=_0x121883['apply'](_0x500f64,_0x374050||[]))['next']());});};class Fetch{constructor(_0xe293af){this['baseUri']=_0xe293af,this['getUrl']=_0x429412=>{return _0x429412['startsWith']('/')&&(_0x429412=_0x429412['replace']('/','')),''+this['baseUri']+_0x429412;},!_0xe293af['endsWith']('/')&&(_0xe293af=_0xe293af+'/');}['get'](_0x212db6,_0x5f53ba){return __awaiter$1(this,void 0,void 0,function*(){const _0xf36fa2=this['getUrl'](_0x212db6);return yield fetch(_0xf36fa2,{'method':'GET','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x5f53ba}});});}['post'](_0x3ea1b5,_0x3b9489,_0x1bef5e){return __awaiter$1(this,void 0,void 0,function*(){const _0x15e6aa=this['getUrl'](_0x3ea1b5);return yield fetch(_0x15e6aa,{'method':'POST','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x3b9489},'body':_0x1bef5e?JSON['stringify'](_0x1bef5e):null});});}['put'](_0x167d92,_0x56e7e5,_0x130abd){return __awaiter$1(this,void 0,void 0,function*(){const _0xb49915=this['getUrl'](_0x167d92);return yield fetch(_0xb49915,{'method':'PUT','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x56e7e5},'body':_0x130abd?JSON['stringify'](_0x130abd):null});});}['delete'](_0x38a2de,_0x5e7052){return __awaiter$1(this,void 0,void 0,function*(){const _0x1b5ef9=this['getUrl'](_0x38a2de);return yield fetch(_0x1b5ef9,{'method':'DELETE','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x5e7052}});});}}
12
+
13
+ var __awaiter=undefined&&undefined['__awaiter']||function(_0x30ec2d,_0x495c9e,_0x5808c2,_0x4d1590){function _0x365bfd(_0x1dda4b){return _0x1dda4b instanceof _0x5808c2?_0x1dda4b:new _0x5808c2(function(_0x5f12ea){_0x5f12ea(_0x1dda4b);});}return new(_0x5808c2||(_0x5808c2=Promise))(function(_0x29bc69,_0x57e19e){function _0x3fd2ec(_0x1fe67){try{_0x1efa58(_0x4d1590['next'](_0x1fe67));}catch(_0x16d5ed){_0x57e19e(_0x16d5ed);}}function _0x4807d2(_0x2718b5){try{_0x1efa58(_0x4d1590['throw'](_0x2718b5));}catch(_0x5817d8){_0x57e19e(_0x5817d8);}}function _0x1efa58(_0xbaac0e){_0xbaac0e['done']?_0x29bc69(_0xbaac0e['value']):_0x365bfd(_0xbaac0e['value'])['then'](_0x3fd2ec,_0x4807d2);}_0x1efa58((_0x4d1590=_0x4d1590['apply'](_0x30ec2d,_0x495c9e||[]))['next']());});};class AdminClient{constructor(_0x11d52d='https://admin.searchability.dev/'){var _0x464c78=new Fetch(_0x11d52d);this['Accounts']=new AccountService(_0x464c78),this['Lists']=new ListService(_0x464c78),this['ApiKeys']=new ApiKeyService(_0x464c78);}}class AuthClient{constructor(_0x5a69b3='https://auth.searchability.dev/'){this['fetch']=new Fetch(_0x5a69b3);}['login'](_0x7083b7){return __awaiter(this,void 0,void 0,function*(){var _0x147d33='login/'+_0x7083b7;try{const _0xab2a0f=yield yield fetch(_0x147d33);if(_0xab2a0f['status']>0xc7&&_0xab2a0f['status']<0x12c){const _0x558548=yield _0xab2a0f['json']();return new SuccessfulAuthResponse(_0x558548);}const _0x1df465=yield _0xab2a0f['json']();return new FailedAuthResponse(_0x1df465);}catch(_0x172fd6){if(_0x172fd6 instanceof Error)return new FailedAuthResponse({'detail':_0x172fd6['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x172fd6;}});}['refresh'](_0x2b28cb){return __awaiter(this,void 0,void 0,function*(){var _0x74e973='refresh';try{const _0xad4a3d=yield this['fetch']['post'](_0x74e973,_0x2b28cb,null);if(_0xad4a3d['status']>0xc7&&_0xad4a3d['status']<0x12c){const _0xd8ac17=yield _0xad4a3d['json']();return new SuccessfulAuthResponse(_0xd8ac17);}const _0x244082=yield _0xad4a3d['json']();return new FailedAuthResponse(_0x244082);}catch(_0x3e05af){if(_0x3e05af instanceof Error)return new FailedAuthResponse({'detail':_0x3e05af['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x3e05af;}});}}
12
14
 
13
15
  export { AdminClient, AuthClient };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@searchability/admin-client",
3
- "version": "0.0.18",
3
+ "version": "0.0.19",
4
4
  "description": "Searchability admin client.",
5
5
  "type": "module",
6
6
  "types": "./dist/types.d.ts",
@@ -1,13 +0,0 @@
1
- class Response{constructor(_0x326403){this['isSuccess']=_0x326403;}}class SuccessfulAccountResponse extends Response{constructor(_0x277157){super(!![]),this['account']=_0x277157;}['toSuccess'](){return this['account'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAccountResponse extends Response{constructor(_0x1e98c1){super(![]),this['problem']=_0x1e98c1;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulAuthResponse extends Response{constructor(_0x3078dc){super(!![]),this['tokens']=_0x3078dc;}['toSuccess'](){return this['tokens'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAuthResponse extends Response{constructor(_0x60e52e){super(![]),this['problem']=_0x60e52e;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulApiKeyResponse extends Response{constructor(_0x804eb8){super(!![]),this['apiKeys']=_0x804eb8;}['toSuccess'](){return this['apiKeys'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedApiKeyResponse extends Response{constructor(_0xf940eb){super(![]),this['problem']=_0xf940eb;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}
2
-
3
- var __awaiter$4=undefined&&undefined['__awaiter']||function(_0x5c789b,_0x521441,_0x2c2fd7,_0x2d358c){function _0x593ce5(_0x37f7a3){return _0x37f7a3 instanceof _0x2c2fd7?_0x37f7a3:new _0x2c2fd7(function(_0x1b12a7){_0x1b12a7(_0x37f7a3);});}return new(_0x2c2fd7||(_0x2c2fd7=Promise))(function(_0x974d2c,_0x20d7d9){function _0x5ea89c(_0x811416){try{_0x3782a0(_0x2d358c['next'](_0x811416));}catch(_0x20030a){_0x20d7d9(_0x20030a);}}function _0x5055e0(_0x1ab45c){try{_0x3782a0(_0x2d358c['throw'](_0x1ab45c));}catch(_0x32d0a8){_0x20d7d9(_0x32d0a8);}}function _0x3782a0(_0x1d5bc6){_0x1d5bc6['done']?_0x974d2c(_0x1d5bc6['value']):_0x593ce5(_0x1d5bc6['value'])['then'](_0x5ea89c,_0x5055e0);}_0x3782a0((_0x2d358c=_0x2d358c['apply'](_0x5c789b,_0x521441||[]))['next']());});};class AccountService{constructor(_0x4a48fb){this['fetch']=_0x4a48fb;}['get'](_0xa49391,_0x5abead){return __awaiter$4(this,void 0,void 0,function*(){const _0xe272c='Account/'+_0xa49391+'/',_0xd612f2=yield this['fetch']['get'](_0xe272c,_0x5abead);try{if(_0xd612f2['status']>0xc7&&_0xd612f2['status']<0x12c){const _0x4539f3=yield _0xd612f2['json']();return new SuccessfulAccountResponse(_0x4539f3);}const _0x5e22a4=yield _0xd612f2['json']();return new FailedAccountResponse(_0x5e22a4);}catch(_0x2c56f7){if(_0x2c56f7 instanceof Error)return new FailedAccountResponse({'detail':_0x2c56f7['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x2c56f7;}});}}
4
-
5
- var __awaiter$3=undefined&&undefined['__awaiter']||function(_0x794f6f,_0x522478,_0x19540d,_0xfaeb7d){function _0x36fad5(_0xe63321){return _0xe63321 instanceof _0x19540d?_0xe63321:new _0x19540d(function(_0x4a35ac){_0x4a35ac(_0xe63321);});}return new(_0x19540d||(_0x19540d=Promise))(function(_0x143013,_0x4f8423){function _0x148a36(_0x3222a5){try{_0x43d53e(_0xfaeb7d['next'](_0x3222a5));}catch(_0x14ad51){_0x4f8423(_0x14ad51);}}function _0x585314(_0x1fc029){try{_0x43d53e(_0xfaeb7d['throw'](_0x1fc029));}catch(_0x3b1e23){_0x4f8423(_0x3b1e23);}}function _0x43d53e(_0x353e28){_0x353e28['done']?_0x143013(_0x353e28['value']):_0x36fad5(_0x353e28['value'])['then'](_0x148a36,_0x585314);}_0x43d53e((_0xfaeb7d=_0xfaeb7d['apply'](_0x794f6f,_0x522478||[]))['next']());});};class ApiKeyService{constructor(_0xd24cf8){this['fetch']=_0xd24cf8;}['create'](_0x3f3ff6,_0x2df8f4,_0x5c1b49){return __awaiter$3(this,void 0,void 0,function*(){const _0x4953b2='ApiKey/Create',_0xc8a302={'account_name':_0x3f3ff6,'name':_0x2df8f4};try{const _0x31a6d9=yield this['fetch']['post'](_0x4953b2,_0x5c1b49,_0xc8a302);if(_0x31a6d9['status']>0xc7&&_0x31a6d9['status']<0x12c){const _0x14396d=yield _0x31a6d9['json']();return new SuccessfulApiKeyResponse(_0x14396d);}const _0x10348a=yield _0x31a6d9['json']();return new FailedApiKeyResponse(_0x10348a);}catch(_0x30a314){if(_0x30a314 instanceof Error)return new FailedApiKeyResponse({'detail':_0x30a314['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x30a314;}});}}
6
-
7
- var __awaiter$2=undefined&&undefined['__awaiter']||function(_0x58186c,_0x397b42,_0x53b5cf,_0x5c448b){function _0xa932e4(_0x477a6a){return _0x477a6a instanceof _0x53b5cf?_0x477a6a:new _0x53b5cf(function(_0x2a667b){_0x2a667b(_0x477a6a);});}return new(_0x53b5cf||(_0x53b5cf=Promise))(function(_0x4e1813,_0x53ffde){function _0x2907fe(_0x40888f){try{_0x165a82(_0x5c448b['next'](_0x40888f));}catch(_0x33e8ad){_0x53ffde(_0x33e8ad);}}function _0x1a4d3b(_0x27ed3f){try{_0x165a82(_0x5c448b['throw'](_0x27ed3f));}catch(_0x125013){_0x53ffde(_0x125013);}}function _0x165a82(_0x488824){_0x488824['done']?_0x4e1813(_0x488824['value']):_0xa932e4(_0x488824['value'])['then'](_0x2907fe,_0x1a4d3b);}_0x165a82((_0x5c448b=_0x5c448b['apply'](_0x58186c,_0x397b42||[]))['next']());});};class ListService{constructor(_0x1f0474){this['fetch']=_0x1f0474;}['add'](_0x23daab,_0x294f43,_0x57c16b){return __awaiter$2(this,void 0,void 0,function*(){const _0x25a8df='List',_0x28b411={'account_name':_0x23daab,'list_name':_0x294f43};try{const _0x51cef7=yield this['fetch']['post'](_0x25a8df,_0x57c16b,_0x28b411);if(_0x51cef7['status']>0xc7&&_0x51cef7['status']<0x12c){const _0x34bf9c=yield _0x51cef7['json']();return new SuccessfulAccountResponse(_0x34bf9c);}const _0x5a653b=yield _0x51cef7['json']();return new FailedAccountResponse(_0x5a653b);}catch(_0x544d59){if(_0x544d59 instanceof Error)return new FailedAccountResponse({'detail':_0x544d59['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x544d59;}});}['remove'](_0x558357,_0x2ecbf3,_0x449f0){return __awaiter$2(this,void 0,void 0,function*(){const _0x19d49d='List/'+_0x558357+'/'+_0x2ecbf3,_0x2efdb6=yield this['fetch']['delete'](_0x19d49d,_0x449f0);try{if(_0x2efdb6['status']>0xc7&&_0x2efdb6['status']<0x12c){const _0x218688=yield _0x2efdb6['json']();return new SuccessfulAccountResponse(_0x218688);}const _0x3282c4=yield _0x2efdb6['json']();return new FailedAccountResponse(_0x3282c4);}catch(_0xa6d9c9){if(_0xa6d9c9 instanceof Error)return new FailedAccountResponse({'detail':_0xa6d9c9['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0xa6d9c9;}});}}
8
-
9
- var __awaiter$1=undefined&&undefined['__awaiter']||function(_0x12911d,_0x5a3f41,_0x2e70e1,_0x3dcf51){function _0x4d6563(_0x3a92f8){return _0x3a92f8 instanceof _0x2e70e1?_0x3a92f8:new _0x2e70e1(function(_0xce7692){_0xce7692(_0x3a92f8);});}return new(_0x2e70e1||(_0x2e70e1=Promise))(function(_0x209e1e,_0x3da527){function _0x168d23(_0x30f111){try{_0x23f8b4(_0x3dcf51['next'](_0x30f111));}catch(_0x4dfb12){_0x3da527(_0x4dfb12);}}function _0x393e7d(_0x163de4){try{_0x23f8b4(_0x3dcf51['throw'](_0x163de4));}catch(_0x188ff0){_0x3da527(_0x188ff0);}}function _0x23f8b4(_0x1da686){_0x1da686['done']?_0x209e1e(_0x1da686['value']):_0x4d6563(_0x1da686['value'])['then'](_0x168d23,_0x393e7d);}_0x23f8b4((_0x3dcf51=_0x3dcf51['apply'](_0x12911d,_0x5a3f41||[]))['next']());});};class Fetch{constructor(_0x46cb0a){this['baseUri']=_0x46cb0a,this['getUrl']=_0x4642d5=>{return _0x4642d5['startsWith']('/')&&(_0x4642d5=_0x4642d5['replace']('/','')),''+this['baseUri']+_0x4642d5;},!_0x46cb0a['endsWith']('/')&&(_0x46cb0a=_0x46cb0a+'/');}['get'](_0x5541a0,_0x9f20b2){return __awaiter$1(this,void 0,void 0,function*(){const _0x3b390d=this['getUrl'](_0x5541a0);return yield fetch(_0x3b390d,{'method':'GET','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x9f20b2}});});}['post'](_0x32f9f1,_0x52a28f,_0x2587ad){return __awaiter$1(this,void 0,void 0,function*(){const _0x30de5f=this['getUrl'](_0x32f9f1);return yield fetch(_0x30de5f,{'method':'POST','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x52a28f},'body':_0x2587ad?JSON['stringify'](_0x2587ad):null});});}['put'](_0x36a4af,_0x3ebb56,_0x89369d){return __awaiter$1(this,void 0,void 0,function*(){const _0x5d4ca8=this['getUrl'](_0x36a4af);return yield fetch(_0x5d4ca8,{'method':'PUT','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x3ebb56},'body':_0x89369d?JSON['stringify'](_0x89369d):null});});}['delete'](_0x2edb54,_0x3e7ba8){return __awaiter$1(this,void 0,void 0,function*(){const _0x267e6d=this['getUrl'](_0x2edb54);return yield fetch(_0x267e6d,{'method':'DELETE','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x3e7ba8}});});}}
10
-
11
- var __awaiter=undefined&&undefined['__awaiter']||function(_0x196219,_0x57bab7,_0x15ed3a,_0x405096){function _0x1f26d1(_0xd0d1c9){return _0xd0d1c9 instanceof _0x15ed3a?_0xd0d1c9:new _0x15ed3a(function(_0x3bcb9c){_0x3bcb9c(_0xd0d1c9);});}return new(_0x15ed3a||(_0x15ed3a=Promise))(function(_0x257057,_0x3fc8e9){function _0x258053(_0xa52e7a){try{_0x44cd66(_0x405096['next'](_0xa52e7a));}catch(_0x25cd18){_0x3fc8e9(_0x25cd18);}}function _0x3eb7ab(_0x5e704b){try{_0x44cd66(_0x405096['throw'](_0x5e704b));}catch(_0x791059){_0x3fc8e9(_0x791059);}}function _0x44cd66(_0xae8198){_0xae8198['done']?_0x257057(_0xae8198['value']):_0x1f26d1(_0xae8198['value'])['then'](_0x258053,_0x3eb7ab);}_0x44cd66((_0x405096=_0x405096['apply'](_0x196219,_0x57bab7||[]))['next']());});};class AdminClient{constructor(_0xd22cb3='https://admin.searchability.dev/'){var _0x45fa2e=new Fetch(_0xd22cb3);this['Accounts']=new AccountService(_0x45fa2e),this['Lists']=new ListService(_0x45fa2e),this['ApiKeys']=new ApiKeyService(_0x45fa2e);}}class AuthClient{constructor(_0x55285b='https://auth.searchability.dev/'){this['fetch']=new Fetch(_0x55285b);}['login'](_0x38c508){return __awaiter(this,void 0,void 0,function*(){var _0x4e46ca='login/'+_0x38c508;try{const _0x57033c=yield yield fetch(_0x4e46ca);if(_0x57033c['status']>0xc7&&_0x57033c['status']<0x12c){const _0x307970=yield _0x57033c['json']();return new SuccessfulAuthResponse(_0x307970);}const _0xb16326=yield _0x57033c['json']();return new FailedAuthResponse(_0xb16326);}catch(_0x59e2f4){if(_0x59e2f4 instanceof Error)return new FailedAuthResponse({'detail':_0x59e2f4['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x59e2f4;}});}['refresh'](_0x37bbf7){return __awaiter(this,void 0,void 0,function*(){var _0x2c9db0='refresh';try{const _0x5308f3=yield this['fetch']['post'](_0x2c9db0,_0x37bbf7,null);if(_0x5308f3['status']>0xc7&&_0x5308f3['status']<0x12c){const _0x300a36=yield _0x5308f3['json']();return new SuccessfulAuthResponse(_0x300a36);}const _0x3003ef=yield _0x5308f3['json']();return new FailedAuthResponse(_0x3003ef);}catch(_0x446c2f){if(_0x446c2f instanceof Error)return new FailedAuthResponse({'detail':_0x446c2f['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x446c2f;}});}}
12
-
13
- export { AdminClient, AuthClient };