@searchability/admin-client 0.0.50 → 0.0.51

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
+ var TokenStatus;(function(_0x3a3c61){_0x3a3c61[_0x3a3c61['Ok']=0x0]='Ok',_0x3a3c61[_0x3a3c61['Refresh']=0x1]='Refresh',_0x3a3c61[_0x3a3c61['Expired']=0x2]='Expired';}(TokenStatus||(TokenStatus={})));class Tokens{constructor(){this['access_token']='',this['access_expires']=0x0,this['refresh_token']='',this['refresh_expires']=0x0;}}class Response{constructor(_0x4cb7cc){this['isSuccess']=_0x4cb7cc;}}class SuccessfulAccountResponse extends Response{constructor(_0x15df36){super(!![]),this['account']=_0x15df36;}['toSuccess'](){return this['account'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class SuccessfulListIdentityResponse extends Response{constructor(_0x168c68){super(!![]),this['list']=_0x168c68;}['toSuccess'](){return this['list'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAccountResponse extends Response{constructor(_0x372633){super(![]),this['problem']=_0x372633;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class FailedListIdentityResponse extends Response{constructor(_0x52e1b8){super(![]),this['problem']=_0x52e1b8;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulAuthResponse extends Response{constructor(_0x24dc79){super(!![]),this['tokens']=_0x24dc79;}['toSuccess'](){return this['tokens'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAuthResponse extends Response{constructor(_0x33eaf5){super(![]),this['problem']=_0x33eaf5;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulApiKeyResponse extends Response{constructor(_0x318ac0){super(!![]),this['apiKey']=_0x318ac0;}['toSuccess'](){return this['apiKey'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedApiKeyResponse extends Response{constructor(_0x28ccd7){super(![]),this['problem']=_0x28ccd7;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulSearchServiceResponse extends Response{constructor(_0x9b657d){super(!![]),this['searchService']=_0x9b657d;}['toSuccess'](){return this['searchService'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedSearchServiceResponse extends Response{constructor(_0x3c9326){super(![]),this['problem']=_0x3c9326;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulViewSearchServiceResponse extends Response{constructor(_0x1f59b2){super(!![]),this['searchService']=_0x1f59b2;}['toSuccess'](){return this['searchService'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class SuccessfulListSearchServiceResponse extends Response{constructor(_0x136616){super(!![]),this['searchServices']=_0x136616;}['toSuccess'](){return this['searchServices'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedViewSearchServicesResponse extends Response{constructor(_0x4431bd){super(![]),this['problem']=_0x4431bd;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class FailedViewSearchServiceResponse extends Response{constructor(_0x1d5ba3){super(![]),this['problem']=_0x1d5ba3;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulApiKeyValueResponse extends Response{constructor(_0x22d012){super(!![]),this['apiKeyValue']=_0x22d012;}['toSuccess'](){return this['apiKeyValue'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class SuccessfulResponse extends Response{constructor(_0x29fe10){super(!![]),this['obj']=_0x29fe10;}['toSuccess'](){return this['obj'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedResponse extends Response{constructor(_0x123454){super(![]),this['problem']=_0x123454;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class FailedApiKeyValueResponse extends Response{constructor(_0x18a617){super(![]),this['problem']=_0x18a617;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}
2
+
3
+ var __awaiter$5=undefined&&undefined['__awaiter']||function(_0x41dc50,_0x1e6d53,_0x118ca2,_0x8091ff){function _0x12c9c8(_0x59a04){return _0x59a04 instanceof _0x118ca2?_0x59a04:new _0x118ca2(function(_0x539b90){_0x539b90(_0x59a04);});}return new(_0x118ca2||(_0x118ca2=Promise))(function(_0x5b1046,_0x3ccf53){function _0x477aae(_0x50ae3b){try{_0x45cf35(_0x8091ff['next'](_0x50ae3b));}catch(_0x2db49d){_0x3ccf53(_0x2db49d);}}function _0x2f98a9(_0x33420c){try{_0x45cf35(_0x8091ff['throw'](_0x33420c));}catch(_0x27423f){_0x3ccf53(_0x27423f);}}function _0x45cf35(_0x3f43a3){_0x3f43a3['done']?_0x5b1046(_0x3f43a3['value']):_0x12c9c8(_0x3f43a3['value'])['then'](_0x477aae,_0x2f98a9);}_0x45cf35((_0x8091ff=_0x8091ff['apply'](_0x41dc50,_0x1e6d53||[]))['next']());});};class AccountService{constructor(_0x490fff){this['fetch']=_0x490fff;}['get'](_0x33d833,_0xa1708c){return __awaiter$5(this,void 0,void 0,function*(){const _0x5b7ed8='Account/'+_0x33d833+'/',_0x179676=yield this['fetch']['get'](_0x5b7ed8,_0xa1708c);try{if(_0x179676['status']>0xc7&&_0x179676['status']<0x12c){const _0x52b299=yield _0x179676['json']();return new SuccessfulAccountResponse(_0x52b299);}const _0x1cbd50=yield _0x179676['json']();return new FailedAccountResponse(_0x1cbd50);}catch(_0x1bfd2b){if(_0x1bfd2b instanceof Error)return new FailedAccountResponse({'detail':_0x1bfd2b['message'],'title':_0x1bfd2b['name'],'status':0x1f4,'instance':'','type':''});throw _0x1bfd2b;}});}}
4
+
5
+ var __awaiter$4=undefined&&undefined['__awaiter']||function(_0x4240c9,_0x4e13e1,_0xde722a,_0x4ba40c){function _0x11e859(_0x47b648){return _0x47b648 instanceof _0xde722a?_0x47b648:new _0xde722a(function(_0x2fb42a){_0x2fb42a(_0x47b648);});}return new(_0xde722a||(_0xde722a=Promise))(function(_0x6d089a,_0x59fac0){function _0x16c82f(_0x4d2581){try{_0xcf71f(_0x4ba40c['next'](_0x4d2581));}catch(_0x8490ac){_0x59fac0(_0x8490ac);}}function _0x4fb2cb(_0x4a8eed){try{_0xcf71f(_0x4ba40c['throw'](_0x4a8eed));}catch(_0x72fa0d){_0x59fac0(_0x72fa0d);}}function _0xcf71f(_0x3fcc58){_0x3fcc58['done']?_0x6d089a(_0x3fcc58['value']):_0x11e859(_0x3fcc58['value'])['then'](_0x16c82f,_0x4fb2cb);}_0xcf71f((_0x4ba40c=_0x4ba40c['apply'](_0x4240c9,_0x4e13e1||[]))['next']());});};class ApiKeyService{constructor(_0x15857f){this['fetch']=_0x15857f,this['path']='api-key';}['create'](_0x43d1f7,_0x371d1d,_0x2a10c8){return __awaiter$4(this,void 0,void 0,function*(){const _0xa045da={'account_name':_0x43d1f7,'api_key_name':_0x371d1d};try{const _0x25b02a=yield this['fetch']['post'](this['path'],_0x2a10c8,_0xa045da);if(_0x25b02a['status']>0xc7&&_0x25b02a['status']<0x12c){const _0x519910=yield _0x25b02a['json']();return new SuccessfulApiKeyResponse(_0x519910);}const _0x52eaa3=yield _0x25b02a['json']();return new FailedApiKeyResponse(_0x52eaa3);}catch(_0x551823){if(_0x551823 instanceof Error)return new FailedApiKeyResponse({'detail':_0x551823['message'],'title':_0x551823['name'],'status':0x1f4,'instance':'','type':''});throw _0x551823;}});}['view'](_0x1bfecd,_0x3fbc98,_0x1ef69b){return __awaiter$4(this,void 0,void 0,function*(){const _0x29c5cc=this['path']+'/'+_0x1bfecd+'/'+_0x3fbc98;try{const _0xb24d1b=yield this['fetch']['get'](_0x29c5cc,_0x1ef69b);if(_0xb24d1b['status']>0xc7&&_0xb24d1b['status']<0x12c){const _0x1bd15a=yield _0xb24d1b['json']();return new SuccessfulApiKeyValueResponse(_0x1bd15a);}const _0x599031=yield _0xb24d1b['json']();return new FailedApiKeyValueResponse(_0x599031);}catch(_0x1e9aa0){if(_0x1e9aa0 instanceof Error)return new FailedApiKeyValueResponse({'detail':_0x1e9aa0['message'],'title':_0x1e9aa0['name'],'status':0x1f4,'instance':'','type':''});throw _0x1e9aa0;}});}['delete'](_0x39dac5,_0x5aa382,_0x53aae2){return __awaiter$4(this,void 0,void 0,function*(){const _0x211648=this['path']+'/'+_0x39dac5+'/'+_0x5aa382;try{const _0x1fbf1c=yield this['fetch']['delete'](_0x211648,_0x53aae2);if(_0x1fbf1c['status']>0xc7&&_0x1fbf1c['status']<0x12c)return new SuccessfulResponse({});const _0x10e2be=yield _0x1fbf1c['json']();return new FailedResponse(_0x10e2be);}catch(_0x3de8b8){if(_0x3de8b8 instanceof Error)return new FailedResponse({'detail':_0x3de8b8['message'],'title':_0x3de8b8['name'],'status':0x1f4,'instance':'','type':''});throw _0x3de8b8;}});}}
6
+
7
+ var __awaiter$3=undefined&&undefined['__awaiter']||function(_0x43a57b,_0x520d4e,_0x83fa6,_0xfd87ff){function _0x19ab47(_0x381508){return _0x381508 instanceof _0x83fa6?_0x381508:new _0x83fa6(function(_0x480a05){_0x480a05(_0x381508);});}return new(_0x83fa6||(_0x83fa6=Promise))(function(_0x196e9f,_0x558811){function _0x1d8e2d(_0x2bbac3){try{_0x786d43(_0xfd87ff['next'](_0x2bbac3));}catch(_0x4d2bd4){_0x558811(_0x4d2bd4);}}function _0x12c2a9(_0x2cf742){try{_0x786d43(_0xfd87ff['throw'](_0x2cf742));}catch(_0x14080d){_0x558811(_0x14080d);}}function _0x786d43(_0x4c5a75){_0x4c5a75['done']?_0x196e9f(_0x4c5a75['value']):_0x19ab47(_0x4c5a75['value'])['then'](_0x1d8e2d,_0x12c2a9);}_0x786d43((_0xfd87ff=_0xfd87ff['apply'](_0x43a57b,_0x520d4e||[]))['next']());});};class ListService{constructor(_0x96eac8){this['fetch']=_0x96eac8;}['add'](_0x519675,_0x2fc79a,_0x47fb4a,_0x2b49ae){return __awaiter$3(this,void 0,void 0,function*(){const _0x16299f='List',_0x134376={'account_name':_0x519675,'list_name':_0x2fc79a,'search_service_name':_0x47fb4a};try{const _0x445d59=yield this['fetch']['post'](_0x16299f,_0x2b49ae,_0x134376);if(_0x445d59['status']>0xc7&&_0x445d59['status']<0x12c){const _0x40a7c1=yield _0x445d59['json']();return new SuccessfulListIdentityResponse(_0x40a7c1);}const _0x5a7b90=yield _0x445d59['json']();return new FailedListIdentityResponse(_0x5a7b90);}catch(_0x18f069){if(_0x18f069 instanceof Error)return new FailedListIdentityResponse({'detail':_0x18f069['message'],'title':_0x18f069['name'],'status':0x1f4,'instance':'','type':''});throw _0x18f069;}});}['delete'](_0x474951,_0x5ac25f,_0x5053a7){return __awaiter$3(this,void 0,void 0,function*(){const _0x30a91b='List/'+_0x474951+'/'+_0x5ac25f,_0x4b84ff=yield this['fetch']['delete'](_0x30a91b,_0x5053a7);try{if(_0x4b84ff['status']>0xc7&&_0x4b84ff['status']<0x12c)return new SuccessfulResponse({});const _0x125a5f=yield _0x4b84ff['json']();return new FailedResponse(_0x125a5f);}catch(_0x278716){if(_0x278716 instanceof Error)return new FailedResponse({'detail':_0x278716['message'],'title':_0x278716['name'],'status':0x1f4,'instance':'','type':''});throw _0x278716;}});}}
8
+
9
+ var __awaiter$2=undefined&&undefined['__awaiter']||function(_0x5c14c5,_0x56b357,_0x4ba30,_0x34c639){function _0x432e2f(_0x189097){return _0x189097 instanceof _0x4ba30?_0x189097:new _0x4ba30(function(_0x3837e7){_0x3837e7(_0x189097);});}return new(_0x4ba30||(_0x4ba30=Promise))(function(_0x25f663,_0x6e28ac){function _0x2358b2(_0x523571){try{_0x9ec049(_0x34c639['next'](_0x523571));}catch(_0x2ec678){_0x6e28ac(_0x2ec678);}}function _0x59e990(_0x5ae4f7){try{_0x9ec049(_0x34c639['throw'](_0x5ae4f7));}catch(_0x2f7d73){_0x6e28ac(_0x2f7d73);}}function _0x9ec049(_0x3353a7){_0x3353a7['done']?_0x25f663(_0x3353a7['value']):_0x432e2f(_0x3353a7['value'])['then'](_0x2358b2,_0x59e990);}_0x9ec049((_0x34c639=_0x34c639['apply'](_0x5c14c5,_0x56b357||[]))['next']());});};class Fetch{constructor(_0x37ea83){this['baseUri']=_0x37ea83,this['getUrl']=_0x44b482=>{return _0x44b482['startsWith']('/')&&(_0x44b482=_0x44b482['replace']('/','')),''+this['baseUri']+_0x44b482;},!_0x37ea83['endsWith']('/')&&(_0x37ea83=_0x37ea83+'/');}['get'](_0x2eeb26,_0x1d76f7){return __awaiter$2(this,void 0,void 0,function*(){const _0x7bfd15=this['getUrl'](_0x2eeb26);return yield fetch(_0x7bfd15,{'method':'GET','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x1d76f7}});});}['post'](_0xbe425a,_0x133004,_0xe1540b){return __awaiter$2(this,void 0,void 0,function*(){const _0x251414=this['getUrl'](_0xbe425a);return yield fetch(_0x251414,{'method':'POST','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x133004},'body':_0xe1540b?JSON['stringify'](_0xe1540b):null});});}['PostNoAuth'](_0x4491be,_0x40d9d9){return __awaiter$2(this,void 0,void 0,function*(){const _0xfe7b61=this['getUrl'](_0x4491be);return yield fetch(_0xfe7b61,{'method':'POST','headers':{'Content-Type':'application/json'},'body':_0x40d9d9?JSON['stringify'](_0x40d9d9):null});});}['put'](_0x49b431,_0x53a195,_0x4dccfd){return __awaiter$2(this,void 0,void 0,function*(){const _0x192d05=this['getUrl'](_0x49b431);return yield fetch(_0x192d05,{'method':'PUT','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x53a195},'body':_0x4dccfd?JSON['stringify'](_0x4dccfd):null});});}['delete'](_0x4b1810,_0xe124c7){return __awaiter$2(this,void 0,void 0,function*(){const _0x2537c1=this['getUrl'](_0x4b1810);return yield fetch(_0x2537c1,{'method':'DELETE','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0xe124c7}});});}}
10
+
11
+ var __awaiter$1=undefined&&undefined['__awaiter']||function(_0x514e0c,_0x40fc3b,_0x207a93,_0x4b418f){function _0x4d6d76(_0x5b3e50){return _0x5b3e50 instanceof _0x207a93?_0x5b3e50:new _0x207a93(function(_0x296dd){_0x296dd(_0x5b3e50);});}return new(_0x207a93||(_0x207a93=Promise))(function(_0x1f817e,_0x314765){function _0x275fd3(_0x5b9cd7){try{_0x5c30a9(_0x4b418f['next'](_0x5b9cd7));}catch(_0x4a28e1){_0x314765(_0x4a28e1);}}function _0x444d6d(_0x5a3a3c){try{_0x5c30a9(_0x4b418f['throw'](_0x5a3a3c));}catch(_0x366eb5){_0x314765(_0x366eb5);}}function _0x5c30a9(_0x3f2a68){_0x3f2a68['done']?_0x1f817e(_0x3f2a68['value']):_0x4d6d76(_0x3f2a68['value'])['then'](_0x275fd3,_0x444d6d);}_0x5c30a9((_0x4b418f=_0x4b418f['apply'](_0x514e0c,_0x40fc3b||[]))['next']());});};class SearchServersService{constructor(_0x4a1d53){this['fetch']=_0x4a1d53,this['path']='search-services';}['create'](_0x4f15d3,_0x35f9e1,_0x1de1b7,_0x3acc75,_0x434b32,_0x527565,_0x1d899f,_0x53fc04){return __awaiter$1(this,void 0,void 0,function*(){const _0x405272={'account_name':_0x4f15d3,'search_service_name':_0x35f9e1,'endpoint':_0x1de1b7,'key':_0x3acc75,'country':_0x434b32,'provider':_0x527565,'index_name':_0x1d899f};try{const _0x15fe8d=yield this['fetch']['post'](this['path'],_0x53fc04,_0x405272);if(_0x15fe8d['status']>0xc7&&_0x15fe8d['status']<0x12c){const _0x3bea15=yield _0x15fe8d['json']();return new SuccessfulSearchServiceResponse(_0x3bea15);}const _0x2171b4=yield _0x15fe8d['json']();return new FailedSearchServiceResponse(_0x2171b4);}catch(_0x566ab9){if(_0x566ab9 instanceof Error)return new FailedSearchServiceResponse({'detail':_0x566ab9['message'],'title':_0x566ab9['name'],'status':0x1f4,'instance':'','type':''});throw _0x566ab9;}});}['delete'](_0x3ebcf9,_0x5eb38d,_0x474b7d){return __awaiter$1(this,void 0,void 0,function*(){const _0x472cac=this['path']+'/'+_0x3ebcf9+'/'+_0x5eb38d;try{const _0xfd3f60=yield this['fetch']['delete'](_0x472cac,_0x474b7d);if(_0xfd3f60['status']>0xc7&&_0xfd3f60['status']<0x12c)return new SuccessfulResponse({});const _0x4fe1f7=yield _0xfd3f60['json']();return new FailedResponse(_0x4fe1f7);}catch(_0x39ce74){if(_0x39ce74 instanceof Error)return new FailedResponse({'detail':_0x39ce74['message'],'title':_0x39ce74['name'],'status':0x1f4,'instance':'','type':''});throw _0x39ce74;}});}['view'](_0x114635,_0x8983c7,_0x4c181f){return __awaiter$1(this,void 0,void 0,function*(){const _0x51e215=this['path']+'/'+_0x114635+'/'+_0x8983c7;try{const _0x4fc798=yield this['fetch']['get'](_0x51e215,_0x4c181f);if(_0x4fc798['status']>0xc7&&_0x4fc798['status']<0x12c){const _0x192f89=yield _0x4fc798['json']();return new SuccessfulViewSearchServiceResponse(_0x192f89);}const _0x32170c=yield _0x4fc798['json']();return new FailedViewSearchServiceResponse(_0x32170c);}catch(_0x45a2a1){if(_0x45a2a1 instanceof Error)return new FailedViewSearchServiceResponse({'detail':_0x45a2a1['message'],'title':_0x45a2a1['name'],'status':0x1f4,'instance':'','type':''});throw _0x45a2a1;}});}['edit'](_0x3da1ed,_0x18d41c,_0xfd5b99,_0xa26064,_0x3ddbc3,_0x51e7c7){return __awaiter$1(this,void 0,void 0,function*(){const _0x43648e={'account_name':_0x3da1ed,'search_service_name':_0x18d41c,'new_search_service_name':_0xfd5b99,'key':_0xa26064,'country':_0x3ddbc3};try{const _0x31db25=yield this['fetch']['put'](this['path'],_0x51e7c7,_0x43648e);if(_0x31db25['status']>0xc7&&_0x31db25['status']<0x12c){const _0x3c3361=yield _0x31db25['json']();return new SuccessfulSearchServiceResponse(_0x3c3361);}const _0x50f005=yield _0x31db25['json']();return new FailedSearchServiceResponse(_0x50f005);}catch(_0x2a73d8){if(_0x2a73d8 instanceof Error)return new FailedSearchServiceResponse({'detail':_0x2a73d8['message'],'title':_0x2a73d8['name'],'status':0x1f4,'instance':'','type':''});throw _0x2a73d8;}});}['list'](_0x3bfbc6,_0x2486d8){return __awaiter$1(this,void 0,void 0,function*(){const _0x349c65=this['path']+'/'+_0x3bfbc6;try{const _0x16a15a=yield this['fetch']['get'](_0x349c65,_0x2486d8);if(_0x16a15a['status']>0xc7&&_0x16a15a['status']<0x12c){const _0x107996=yield _0x16a15a['json']();return new SuccessfulListSearchServiceResponse(_0x107996);}const _0x316ec8=yield _0x16a15a['json']();return new FailedViewSearchServicesResponse(_0x316ec8);}catch(_0x373e9a){if(_0x373e9a instanceof Error)return new FailedViewSearchServicesResponse({'detail':_0x373e9a['message'],'title':_0x373e9a['name'],'status':0x1f4,'instance':'','type':''});throw _0x373e9a;}});}}
12
+
13
+ var __awaiter=undefined&&undefined['__awaiter']||function(_0x36bb2c,_0x5ed8f2,_0x112abe,_0x3a9465){function _0x5c1100(_0x196e79){return _0x196e79 instanceof _0x112abe?_0x196e79:new _0x112abe(function(_0x4e1494){_0x4e1494(_0x196e79);});}return new(_0x112abe||(_0x112abe=Promise))(function(_0x356577,_0x39303e){function _0x59a786(_0x3e4460){try{_0x294a86(_0x3a9465['next'](_0x3e4460));}catch(_0x5b80b3){_0x39303e(_0x5b80b3);}}function _0x1fea99(_0x276827){try{_0x294a86(_0x3a9465['throw'](_0x276827));}catch(_0x43bc0c){_0x39303e(_0x43bc0c);}}function _0x294a86(_0xed0f4f){_0xed0f4f['done']?_0x356577(_0xed0f4f['value']):_0x5c1100(_0xed0f4f['value'])['then'](_0x59a786,_0x1fea99);}_0x294a86((_0x3a9465=_0x3a9465['apply'](_0x36bb2c,_0x5ed8f2||[]))['next']());});};class AdminClient{constructor(_0x204981='https://admin.searchability.dev/'){var _0x7b9b5a=new Fetch(_0x204981);this['Accounts']=new AccountService(_0x7b9b5a),this['Lists']=new ListService(_0x7b9b5a),this['ApiKeys']=new ApiKeyService(_0x7b9b5a),this['SearchServices']=new SearchServersService(_0x7b9b5a);}}class AuthClient{constructor(_0x80cec1='https://auth.searchability.dev/'){this['fetch']=new Fetch(_0x80cec1);}['login'](_0x5d9742){return __awaiter(this,void 0,void 0,function*(){const _0x2d37b3='login/'+_0x5d9742;try{const _0x563d31=yield yield fetch(_0x2d37b3);if(_0x563d31['status']>0xc7&&_0x563d31['status']<0x12c){const _0x16eb94=yield _0x563d31['json']();return new SuccessfulAuthResponse(_0x16eb94);}const _0x1eb7e4=yield _0x563d31['json']();return new FailedAuthResponse(_0x1eb7e4);}catch(_0x462de1){if(_0x462de1 instanceof Error)return new FailedAuthResponse({'detail':_0x462de1['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x462de1;}});}['refresh'](_0xb2d835){return __awaiter(this,void 0,void 0,function*(){const _0x116a02='refresh',_0x3dcd62={'refresh_token':_0xb2d835};try{const _0x47f712=yield this['fetch']['PostNoAuth'](_0x116a02,_0x3dcd62);if(_0x47f712['status']>0xc7&&_0x47f712['status']<0x12c){const _0x5b1025=yield _0x47f712['json']();return new SuccessfulAuthResponse(_0x5b1025);}const _0x142419=yield _0x47f712['json']();return new FailedAuthResponse(_0x142419);}catch(_0x3f095e){if(_0x3f095e instanceof Error)return new FailedAuthResponse({'detail':_0x3f095e['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x3f095e;}});}['getTokenStatus'](_0xa17523){if(Date['now']()<_0xa17523['access_expires'])return TokenStatus['Ok'];if(Date['now']()<_0xa17523['refresh_expires'])return TokenStatus['Refresh'];return TokenStatus['Expired'];}}
14
+
15
+ export { AdminClient, AuthClient, TokenStatus, Tokens };
@@ -1,18 +1,18 @@
1
1
  'use strict';
2
2
 
3
- exports.TokenStatus = void 0;(function(_0x42351a){_0x42351a[_0x42351a['Ok']=0x0]='Ok',_0x42351a[_0x42351a['Refresh']=0x1]='Refresh',_0x42351a[_0x42351a['Expired']=0x2]='Expired';}(exports.TokenStatus||(exports.TokenStatus={})));class Tokens{constructor(){this['access_token']='',this['access_expires']=0x0,this['refresh_token']='',this['refresh_expires']=0x0;}}class Response{constructor(_0x5299c7){this['isSuccess']=_0x5299c7;}}class SuccessfulAccountResponse extends Response{constructor(_0x374324){super(!![]),this['account']=_0x374324;}['toSuccess'](){return this['account'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class SuccessfulListIdentityResponse extends Response{constructor(_0x406481){super(!![]),this['list']=_0x406481;}['toSuccess'](){return this['list'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAccountResponse extends Response{constructor(_0x2333fd){super(![]),this['problem']=_0x2333fd;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class FailedListIdentityResponse extends Response{constructor(_0x2996e8){super(![]),this['problem']=_0x2996e8;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulAuthResponse extends Response{constructor(_0x2a4e3f){super(!![]),this['tokens']=_0x2a4e3f;}['toSuccess'](){return this['tokens'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAuthResponse extends Response{constructor(_0x2d678e){super(![]),this['problem']=_0x2d678e;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulApiKeyResponse extends Response{constructor(_0x571fde){super(!![]),this['apiKey']=_0x571fde;}['toSuccess'](){return this['apiKey'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedApiKeyResponse extends Response{constructor(_0x4b42aa){super(![]),this['problem']=_0x4b42aa;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulSearchServiceResponse extends Response{constructor(_0x235f22){super(!![]),this['searchService']=_0x235f22;}['toSuccess'](){return this['searchService'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedSearchServiceResponse extends Response{constructor(_0x39b1b4){super(![]),this['problem']=_0x39b1b4;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulViewSearchServiceResponse extends Response{constructor(_0x2480e5){super(!![]),this['searchService']=_0x2480e5;}['toSuccess'](){return this['searchService'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class SuccessfulListSearchServiceResponse extends Response{constructor(_0x50a1f8){super(!![]),this['searchServices']=_0x50a1f8;}['toSuccess'](){return this['searchServices'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedViewSearchServicesResponse extends Response{constructor(_0x13ec3d){super(![]),this['problem']=_0x13ec3d;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class FailedViewSearchServiceResponse extends Response{constructor(_0x426f14){super(![]),this['problem']=_0x426f14;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulApiKeyValueResponse extends Response{constructor(_0x3f3069){super(!![]),this['apiKeyValue']=_0x3f3069;}['toSuccess'](){return this['apiKeyValue'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class SuccessfulResponse extends Response{constructor(_0x53c17c){super(!![]),this['obj']=_0x53c17c;}['toSuccess'](){return this['obj'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedResponse extends Response{constructor(_0x200ae4){super(![]),this['problem']=_0x200ae4;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class FailedApiKeyValueResponse extends Response{constructor(_0x466669){super(![]),this['problem']=_0x466669;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}
3
+ exports.TokenStatus = void 0;(function(_0x29dac7){_0x29dac7[_0x29dac7['Ok']=0x0]='Ok',_0x29dac7[_0x29dac7['Refresh']=0x1]='Refresh',_0x29dac7[_0x29dac7['Expired']=0x2]='Expired';}(exports.TokenStatus||(exports.TokenStatus={})));class Tokens{constructor(){this['access_token']='',this['access_expires']=0x0,this['refresh_token']='',this['refresh_expires']=0x0;}}class Response{constructor(_0x26480f){this['isSuccess']=_0x26480f;}}class SuccessfulAccountResponse extends Response{constructor(_0x2c3121){super(!![]),this['account']=_0x2c3121;}['toSuccess'](){return this['account'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class SuccessfulListIdentityResponse extends Response{constructor(_0x6a1761){super(!![]),this['list']=_0x6a1761;}['toSuccess'](){return this['list'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAccountResponse extends Response{constructor(_0x4c6aa6){super(![]),this['problem']=_0x4c6aa6;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class FailedListIdentityResponse extends Response{constructor(_0x565eb1){super(![]),this['problem']=_0x565eb1;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulAuthResponse extends Response{constructor(_0x51c230){super(!![]),this['tokens']=_0x51c230;}['toSuccess'](){return this['tokens'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAuthResponse extends Response{constructor(_0xbaf373){super(![]),this['problem']=_0xbaf373;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulApiKeyResponse extends Response{constructor(_0x572fe0){super(!![]),this['apiKey']=_0x572fe0;}['toSuccess'](){return this['apiKey'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedApiKeyResponse extends Response{constructor(_0x4abdbb){super(![]),this['problem']=_0x4abdbb;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulSearchServiceResponse extends Response{constructor(_0x1c52e9){super(!![]),this['searchService']=_0x1c52e9;}['toSuccess'](){return this['searchService'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedSearchServiceResponse extends Response{constructor(_0x65975b){super(![]),this['problem']=_0x65975b;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulViewSearchServiceResponse extends Response{constructor(_0x168c94){super(!![]),this['searchService']=_0x168c94;}['toSuccess'](){return this['searchService'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class SuccessfulListSearchServiceResponse extends Response{constructor(_0x46b5d2){super(!![]),this['searchServices']=_0x46b5d2;}['toSuccess'](){return this['searchServices'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedViewSearchServicesResponse extends Response{constructor(_0x1619ee){super(![]),this['problem']=_0x1619ee;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class FailedViewSearchServiceResponse extends Response{constructor(_0x28677b){super(![]),this['problem']=_0x28677b;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulApiKeyValueResponse extends Response{constructor(_0x53d9c7){super(!![]),this['apiKeyValue']=_0x53d9c7;}['toSuccess'](){return this['apiKeyValue'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class SuccessfulResponse extends Response{constructor(_0x113bec){super(!![]),this['obj']=_0x113bec;}['toSuccess'](){return this['obj'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedResponse extends Response{constructor(_0x33afc4){super(![]),this['problem']=_0x33afc4;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class FailedApiKeyValueResponse extends Response{constructor(_0x2e563d){super(![]),this['problem']=_0x2e563d;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}
4
4
 
5
- var __awaiter$5=undefined&&undefined['__awaiter']||function(_0x1eab9a,_0x4f8518,_0x1c1d71,_0x3d86dc){function _0x5c7738(_0x12b189){return _0x12b189 instanceof _0x1c1d71?_0x12b189:new _0x1c1d71(function(_0x4b8d98){_0x4b8d98(_0x12b189);});}return new(_0x1c1d71||(_0x1c1d71=Promise))(function(_0x17a630,_0x4ed6ac){function _0x1e020d(_0x272d3a){try{_0x3334f2(_0x3d86dc['next'](_0x272d3a));}catch(_0x3f4516){_0x4ed6ac(_0x3f4516);}}function _0x2958f9(_0x4bc183){try{_0x3334f2(_0x3d86dc['throw'](_0x4bc183));}catch(_0x5cea19){_0x4ed6ac(_0x5cea19);}}function _0x3334f2(_0x398718){_0x398718['done']?_0x17a630(_0x398718['value']):_0x5c7738(_0x398718['value'])['then'](_0x1e020d,_0x2958f9);}_0x3334f2((_0x3d86dc=_0x3d86dc['apply'](_0x1eab9a,_0x4f8518||[]))['next']());});};class AccountService{constructor(_0x36e39d){this['fetch']=_0x36e39d;}['get'](_0x71ff90,_0x3ac812){return __awaiter$5(this,void 0,void 0,function*(){const _0x2a9785='Account/'+_0x71ff90+'/',_0x4cd903=yield this['fetch']['get'](_0x2a9785,_0x3ac812);try{if(_0x4cd903['status']>0xc7&&_0x4cd903['status']<0x12c){const _0x21fc63=yield _0x4cd903['json']();return new SuccessfulAccountResponse(_0x21fc63);}const _0x2c7891=yield _0x4cd903['json']();return new FailedAccountResponse(_0x2c7891);}catch(_0x464f8d){if(_0x464f8d instanceof Error)return new FailedAccountResponse({'detail':_0x464f8d['message'],'title':_0x464f8d['name'],'status':0x1f4,'instance':'','type':''});throw _0x464f8d;}});}}
5
+ var __awaiter$5=undefined&&undefined['__awaiter']||function(_0x2871e5,_0x347d4b,_0x12beb3,_0x26ff61){function _0x24fdea(_0x47be3d){return _0x47be3d instanceof _0x12beb3?_0x47be3d:new _0x12beb3(function(_0xa07927){_0xa07927(_0x47be3d);});}return new(_0x12beb3||(_0x12beb3=Promise))(function(_0x1b96b7,_0xda8b81){function _0x5ec1f9(_0x5dfb79){try{_0x4d2cc9(_0x26ff61['next'](_0x5dfb79));}catch(_0x26214f){_0xda8b81(_0x26214f);}}function _0x17dbac(_0x5139fb){try{_0x4d2cc9(_0x26ff61['throw'](_0x5139fb));}catch(_0x1af6c0){_0xda8b81(_0x1af6c0);}}function _0x4d2cc9(_0x523371){_0x523371['done']?_0x1b96b7(_0x523371['value']):_0x24fdea(_0x523371['value'])['then'](_0x5ec1f9,_0x17dbac);}_0x4d2cc9((_0x26ff61=_0x26ff61['apply'](_0x2871e5,_0x347d4b||[]))['next']());});};class AccountService{constructor(_0x214c49){this['fetch']=_0x214c49;}['get'](_0x52ed50,_0x2c7c13){return __awaiter$5(this,void 0,void 0,function*(){const _0x2cac59='Account/'+_0x52ed50+'/',_0x214202=yield this['fetch']['get'](_0x2cac59,_0x2c7c13);try{if(_0x214202['status']>0xc7&&_0x214202['status']<0x12c){const _0xfc0d9a=yield _0x214202['json']();return new SuccessfulAccountResponse(_0xfc0d9a);}const _0x457619=yield _0x214202['json']();return new FailedAccountResponse(_0x457619);}catch(_0x2adadf){if(_0x2adadf instanceof Error)return new FailedAccountResponse({'detail':_0x2adadf['message'],'title':_0x2adadf['name'],'status':0x1f4,'instance':'','type':''});throw _0x2adadf;}});}}
6
6
 
7
- var __awaiter$4=undefined&&undefined['__awaiter']||function(_0x220c99,_0xc50d51,_0x51a21e,_0x48b1bf){function _0xf83330(_0x556724){return _0x556724 instanceof _0x51a21e?_0x556724:new _0x51a21e(function(_0x22a056){_0x22a056(_0x556724);});}return new(_0x51a21e||(_0x51a21e=Promise))(function(_0x38193a,_0x2fdf2e){function _0x1e7dc7(_0xfb953d){try{_0x5596de(_0x48b1bf['next'](_0xfb953d));}catch(_0x2f33a5){_0x2fdf2e(_0x2f33a5);}}function _0x1cd5a6(_0x5854d9){try{_0x5596de(_0x48b1bf['throw'](_0x5854d9));}catch(_0x495af7){_0x2fdf2e(_0x495af7);}}function _0x5596de(_0x306b5c){_0x306b5c['done']?_0x38193a(_0x306b5c['value']):_0xf83330(_0x306b5c['value'])['then'](_0x1e7dc7,_0x1cd5a6);}_0x5596de((_0x48b1bf=_0x48b1bf['apply'](_0x220c99,_0xc50d51||[]))['next']());});};class ApiKeyService{constructor(_0x281150){this['fetch']=_0x281150,this['path']='api-key';}['create'](_0x32bd2b,_0x45bde7,_0x209fee){return __awaiter$4(this,void 0,void 0,function*(){const _0x5df6ec={'account_name':_0x32bd2b,'api_key_name':_0x45bde7};try{const _0x53095a=yield this['fetch']['post'](this['path'],_0x209fee,_0x5df6ec);if(_0x53095a['status']>0xc7&&_0x53095a['status']<0x12c){const _0x2c3fad=yield _0x53095a['json']();return new SuccessfulApiKeyResponse(_0x2c3fad);}const _0x444d27=yield _0x53095a['json']();return new FailedApiKeyResponse(_0x444d27);}catch(_0x3ec24b){if(_0x3ec24b instanceof Error)return new FailedApiKeyResponse({'detail':_0x3ec24b['message'],'title':_0x3ec24b['name'],'status':0x1f4,'instance':'','type':''});throw _0x3ec24b;}});}['view'](_0x566cfd,_0x41cf6d,_0x3a56ab){return __awaiter$4(this,void 0,void 0,function*(){const _0x34083c=this['path']+'/'+_0x566cfd+'/'+_0x41cf6d;try{const _0xe6432e=yield this['fetch']['get'](_0x34083c,_0x3a56ab);if(_0xe6432e['status']>0xc7&&_0xe6432e['status']<0x12c){const _0x3a3132=yield _0xe6432e['json']();return new SuccessfulApiKeyValueResponse(_0x3a3132);}const _0x4bfdb3=yield _0xe6432e['json']();return new FailedApiKeyValueResponse(_0x4bfdb3);}catch(_0x335021){if(_0x335021 instanceof Error)return new FailedApiKeyValueResponse({'detail':_0x335021['message'],'title':_0x335021['name'],'status':0x1f4,'instance':'','type':''});throw _0x335021;}});}['delete'](_0x4f8e06,_0x3a297b,_0x2cb9a0){return __awaiter$4(this,void 0,void 0,function*(){const _0x5c27a7=this['path']+'/'+_0x4f8e06+'/'+_0x3a297b;try{const _0xa1ccc3=yield this['fetch']['delete'](_0x5c27a7,_0x2cb9a0);if(_0xa1ccc3['status']>0xc7&&_0xa1ccc3['status']<0x12c)return new SuccessfulResponse({});const _0xb4bfa3=yield _0xa1ccc3['json']();return new FailedResponse(_0xb4bfa3);}catch(_0x5ebc2a){if(_0x5ebc2a instanceof Error)return new FailedResponse({'detail':_0x5ebc2a['message'],'title':_0x5ebc2a['name'],'status':0x1f4,'instance':'','type':''});throw _0x5ebc2a;}});}}
7
+ var __awaiter$4=undefined&&undefined['__awaiter']||function(_0x407abe,_0x300d5d,_0x35f5a1,_0x29db79){function _0x568901(_0x197e2a){return _0x197e2a instanceof _0x35f5a1?_0x197e2a:new _0x35f5a1(function(_0x529207){_0x529207(_0x197e2a);});}return new(_0x35f5a1||(_0x35f5a1=Promise))(function(_0x1e852d,_0x1d6b07){function _0x7f05c2(_0x1b79e5){try{_0x40bf66(_0x29db79['next'](_0x1b79e5));}catch(_0x3af2f5){_0x1d6b07(_0x3af2f5);}}function _0x9a2a28(_0x582e48){try{_0x40bf66(_0x29db79['throw'](_0x582e48));}catch(_0x7f1695){_0x1d6b07(_0x7f1695);}}function _0x40bf66(_0x4c4c32){_0x4c4c32['done']?_0x1e852d(_0x4c4c32['value']):_0x568901(_0x4c4c32['value'])['then'](_0x7f05c2,_0x9a2a28);}_0x40bf66((_0x29db79=_0x29db79['apply'](_0x407abe,_0x300d5d||[]))['next']());});};class ApiKeyService{constructor(_0x1b42fb){this['fetch']=_0x1b42fb,this['path']='api-key';}['create'](_0x4082fc,_0x16f34f,_0x4fc36e){return __awaiter$4(this,void 0,void 0,function*(){const _0x148e89={'account_name':_0x4082fc,'api_key_name':_0x16f34f};try{const _0x1a7ae7=yield this['fetch']['post'](this['path'],_0x4fc36e,_0x148e89);if(_0x1a7ae7['status']>0xc7&&_0x1a7ae7['status']<0x12c){const _0x41cd08=yield _0x1a7ae7['json']();return new SuccessfulApiKeyResponse(_0x41cd08);}const _0x15bbe0=yield _0x1a7ae7['json']();return new FailedApiKeyResponse(_0x15bbe0);}catch(_0x2d0d18){if(_0x2d0d18 instanceof Error)return new FailedApiKeyResponse({'detail':_0x2d0d18['message'],'title':_0x2d0d18['name'],'status':0x1f4,'instance':'','type':''});throw _0x2d0d18;}});}['view'](_0x4d783d,_0x247613,_0x21991){return __awaiter$4(this,void 0,void 0,function*(){const _0x4b7280=this['path']+'/'+_0x4d783d+'/'+_0x247613;try{const _0x4f8d5e=yield this['fetch']['get'](_0x4b7280,_0x21991);if(_0x4f8d5e['status']>0xc7&&_0x4f8d5e['status']<0x12c){const _0x306ab1=yield _0x4f8d5e['json']();return new SuccessfulApiKeyValueResponse(_0x306ab1);}const _0x3ddd8d=yield _0x4f8d5e['json']();return new FailedApiKeyValueResponse(_0x3ddd8d);}catch(_0x35bd5c){if(_0x35bd5c instanceof Error)return new FailedApiKeyValueResponse({'detail':_0x35bd5c['message'],'title':_0x35bd5c['name'],'status':0x1f4,'instance':'','type':''});throw _0x35bd5c;}});}['delete'](_0x9579cc,_0x215b2d,_0x4febf8){return __awaiter$4(this,void 0,void 0,function*(){const _0x5f001e=this['path']+'/'+_0x9579cc+'/'+_0x215b2d;try{const _0x1d030f=yield this['fetch']['delete'](_0x5f001e,_0x4febf8);if(_0x1d030f['status']>0xc7&&_0x1d030f['status']<0x12c)return new SuccessfulResponse({});const _0x2bc008=yield _0x1d030f['json']();return new FailedResponse(_0x2bc008);}catch(_0xd7bfda){if(_0xd7bfda instanceof Error)return new FailedResponse({'detail':_0xd7bfda['message'],'title':_0xd7bfda['name'],'status':0x1f4,'instance':'','type':''});throw _0xd7bfda;}});}}
8
8
 
9
- var __awaiter$3=undefined&&undefined['__awaiter']||function(_0x545c39,_0x3a3bc1,_0x382677,_0x1017a4){function _0x27a1e0(_0x3b50ca){return _0x3b50ca instanceof _0x382677?_0x3b50ca:new _0x382677(function(_0x56df69){_0x56df69(_0x3b50ca);});}return new(_0x382677||(_0x382677=Promise))(function(_0x3b2a6b,_0x3d8b5c){function _0x48d3cc(_0x43d4aa){try{_0x1ee421(_0x1017a4['next'](_0x43d4aa));}catch(_0x3181e3){_0x3d8b5c(_0x3181e3);}}function _0x45baba(_0x3f38e4){try{_0x1ee421(_0x1017a4['throw'](_0x3f38e4));}catch(_0x554d02){_0x3d8b5c(_0x554d02);}}function _0x1ee421(_0x2d994e){_0x2d994e['done']?_0x3b2a6b(_0x2d994e['value']):_0x27a1e0(_0x2d994e['value'])['then'](_0x48d3cc,_0x45baba);}_0x1ee421((_0x1017a4=_0x1017a4['apply'](_0x545c39,_0x3a3bc1||[]))['next']());});};class ListService{constructor(_0x1b1e0b){this['fetch']=_0x1b1e0b;}['add'](_0xc4458f,_0x32adcf,_0x1540fe,_0x313177){return __awaiter$3(this,void 0,void 0,function*(){const _0x1a1efa='List',_0x49a952={'account_name':_0xc4458f,'list_name':_0x32adcf,'search_service_name':_0x1540fe};try{const _0x326518=yield this['fetch']['post'](_0x1a1efa,_0x313177,_0x49a952);if(_0x326518['status']>0xc7&&_0x326518['status']<0x12c){const _0x81fdaf=yield _0x326518['json']();return new SuccessfulListIdentityResponse(_0x81fdaf);}const _0x25c15f=yield _0x326518['json']();return new FailedListIdentityResponse(_0x25c15f);}catch(_0x4e91f5){if(_0x4e91f5 instanceof Error)return new FailedListIdentityResponse({'detail':_0x4e91f5['message'],'title':_0x4e91f5['name'],'status':0x1f4,'instance':'','type':''});throw _0x4e91f5;}});}['delete'](_0x5a63bd,_0x1c2bc9,_0x55d26a){return __awaiter$3(this,void 0,void 0,function*(){const _0x168df8='List/'+_0x5a63bd+'/'+_0x1c2bc9,_0xea2bbd=yield this['fetch']['delete'](_0x168df8,_0x55d26a);try{if(_0xea2bbd['status']>0xc7&&_0xea2bbd['status']<0x12c)return new SuccessfulResponse({});const _0x43eb44=yield _0xea2bbd['json']();return new FailedResponse(_0x43eb44);}catch(_0x4816d8){if(_0x4816d8 instanceof Error)return new FailedResponse({'detail':_0x4816d8['message'],'title':_0x4816d8['name'],'status':0x1f4,'instance':'','type':''});throw _0x4816d8;}});}}
9
+ var __awaiter$3=undefined&&undefined['__awaiter']||function(_0x3899c3,_0x2e1f4f,_0x58066b,_0x17aab0){function _0x26d387(_0x4a8626){return _0x4a8626 instanceof _0x58066b?_0x4a8626:new _0x58066b(function(_0x9024bb){_0x9024bb(_0x4a8626);});}return new(_0x58066b||(_0x58066b=Promise))(function(_0x4e428b,_0x9118e2){function _0x5b110c(_0x28842b){try{_0x46b60d(_0x17aab0['next'](_0x28842b));}catch(_0x689ef5){_0x9118e2(_0x689ef5);}}function _0x37a3fb(_0x313af1){try{_0x46b60d(_0x17aab0['throw'](_0x313af1));}catch(_0xe438){_0x9118e2(_0xe438);}}function _0x46b60d(_0x49a961){_0x49a961['done']?_0x4e428b(_0x49a961['value']):_0x26d387(_0x49a961['value'])['then'](_0x5b110c,_0x37a3fb);}_0x46b60d((_0x17aab0=_0x17aab0['apply'](_0x3899c3,_0x2e1f4f||[]))['next']());});};class ListService{constructor(_0x384638){this['fetch']=_0x384638;}['add'](_0x4ed590,_0x1a6dcd,_0x1641d2,_0x524014){return __awaiter$3(this,void 0,void 0,function*(){const _0x49f529='List',_0x3c95e2={'account_name':_0x4ed590,'list_name':_0x1a6dcd,'search_service_name':_0x1641d2};try{const _0x398804=yield this['fetch']['post'](_0x49f529,_0x524014,_0x3c95e2);if(_0x398804['status']>0xc7&&_0x398804['status']<0x12c){const _0x2737c6=yield _0x398804['json']();return new SuccessfulListIdentityResponse(_0x2737c6);}const _0x2fa79c=yield _0x398804['json']();return new FailedListIdentityResponse(_0x2fa79c);}catch(_0x54628f){if(_0x54628f instanceof Error)return new FailedListIdentityResponse({'detail':_0x54628f['message'],'title':_0x54628f['name'],'status':0x1f4,'instance':'','type':''});throw _0x54628f;}});}['delete'](_0x2d030f,_0x3c3533,_0x12bbcb){return __awaiter$3(this,void 0,void 0,function*(){const _0x459da4='List/'+_0x2d030f+'/'+_0x3c3533,_0x144d5f=yield this['fetch']['delete'](_0x459da4,_0x12bbcb);try{if(_0x144d5f['status']>0xc7&&_0x144d5f['status']<0x12c)return new SuccessfulResponse({});const _0x1e3ff6=yield _0x144d5f['json']();return new FailedResponse(_0x1e3ff6);}catch(_0x459eeb){if(_0x459eeb instanceof Error)return new FailedResponse({'detail':_0x459eeb['message'],'title':_0x459eeb['name'],'status':0x1f4,'instance':'','type':''});throw _0x459eeb;}});}}
10
10
 
11
- var __awaiter$2=undefined&&undefined['__awaiter']||function(_0x952f47,_0x41240e,_0x49508c,_0x33d5ef){function _0x175c65(_0x1481a9){return _0x1481a9 instanceof _0x49508c?_0x1481a9:new _0x49508c(function(_0x921366){_0x921366(_0x1481a9);});}return new(_0x49508c||(_0x49508c=Promise))(function(_0x3c0a03,_0x54ce64){function _0x1953f4(_0x4a8441){try{_0x5ab7f0(_0x33d5ef['next'](_0x4a8441));}catch(_0x58cba5){_0x54ce64(_0x58cba5);}}function _0x9ed3aa(_0x3cb1dd){try{_0x5ab7f0(_0x33d5ef['throw'](_0x3cb1dd));}catch(_0x2ecbcc){_0x54ce64(_0x2ecbcc);}}function _0x5ab7f0(_0xbfa907){_0xbfa907['done']?_0x3c0a03(_0xbfa907['value']):_0x175c65(_0xbfa907['value'])['then'](_0x1953f4,_0x9ed3aa);}_0x5ab7f0((_0x33d5ef=_0x33d5ef['apply'](_0x952f47,_0x41240e||[]))['next']());});};class Fetch{constructor(_0x1e2130){this['baseUri']=_0x1e2130,this['getUrl']=_0x2bf6fe=>{return _0x2bf6fe['startsWith']('/')&&(_0x2bf6fe=_0x2bf6fe['replace']('/','')),''+this['baseUri']+_0x2bf6fe;},!_0x1e2130['endsWith']('/')&&(_0x1e2130=_0x1e2130+'/');}['get'](_0x327c10,_0xa089bc){return __awaiter$2(this,void 0,void 0,function*(){const _0x58a76d=this['getUrl'](_0x327c10);return yield fetch(_0x58a76d,{'method':'GET','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0xa089bc}});});}['post'](_0x330852,_0x2ab831,_0x14b652){return __awaiter$2(this,void 0,void 0,function*(){const _0x3d1462=this['getUrl'](_0x330852);return yield fetch(_0x3d1462,{'method':'POST','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x2ab831},'body':_0x14b652?JSON['stringify'](_0x14b652):null});});}['PostNoAuth'](_0x1c9d3a,_0x3bb23b){return __awaiter$2(this,void 0,void 0,function*(){const _0xc4df0b=this['getUrl'](_0x1c9d3a);return yield fetch(_0xc4df0b,{'method':'POST','headers':{'Content-Type':'application/json'},'body':_0x3bb23b?JSON['stringify'](_0x3bb23b):null});});}['put'](_0x5091bd,_0x3de2e0,_0x59163d){return __awaiter$2(this,void 0,void 0,function*(){const _0x5d8f5e=this['getUrl'](_0x5091bd);return yield fetch(_0x5d8f5e,{'method':'PUT','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x3de2e0},'body':_0x59163d?JSON['stringify'](_0x59163d):null});});}['delete'](_0x109fec,_0x149c51){return __awaiter$2(this,void 0,void 0,function*(){const _0x29e64e=this['getUrl'](_0x109fec);return yield fetch(_0x29e64e,{'method':'DELETE','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x149c51}});});}}
11
+ var __awaiter$2=undefined&&undefined['__awaiter']||function(_0x5a1f14,_0x29599b,_0x3b7b65,_0x2e1d62){function _0x4fae3d(_0x2376e6){return _0x2376e6 instanceof _0x3b7b65?_0x2376e6:new _0x3b7b65(function(_0xd22dd6){_0xd22dd6(_0x2376e6);});}return new(_0x3b7b65||(_0x3b7b65=Promise))(function(_0x1a7743,_0x4fd681){function _0x408cf2(_0xbb6357){try{_0x20b3e8(_0x2e1d62['next'](_0xbb6357));}catch(_0x14b0dc){_0x4fd681(_0x14b0dc);}}function _0x3cf698(_0x4f0228){try{_0x20b3e8(_0x2e1d62['throw'](_0x4f0228));}catch(_0x1f82ec){_0x4fd681(_0x1f82ec);}}function _0x20b3e8(_0x30987d){_0x30987d['done']?_0x1a7743(_0x30987d['value']):_0x4fae3d(_0x30987d['value'])['then'](_0x408cf2,_0x3cf698);}_0x20b3e8((_0x2e1d62=_0x2e1d62['apply'](_0x5a1f14,_0x29599b||[]))['next']());});};class Fetch{constructor(_0x5804a4){this['baseUri']=_0x5804a4,this['getUrl']=_0x289a72=>{return _0x289a72['startsWith']('/')&&(_0x289a72=_0x289a72['replace']('/','')),''+this['baseUri']+_0x289a72;},!_0x5804a4['endsWith']('/')&&(_0x5804a4=_0x5804a4+'/');}['get'](_0x30f839,_0x13eaf3){return __awaiter$2(this,void 0,void 0,function*(){const _0x16ce89=this['getUrl'](_0x30f839);return yield fetch(_0x16ce89,{'method':'GET','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x13eaf3}});});}['post'](_0x36ac3e,_0xf1c163,_0x2a9f31){return __awaiter$2(this,void 0,void 0,function*(){const _0x561c33=this['getUrl'](_0x36ac3e);return yield fetch(_0x561c33,{'method':'POST','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0xf1c163},'body':_0x2a9f31?JSON['stringify'](_0x2a9f31):null});});}['PostNoAuth'](_0x3028a2,_0x437213){return __awaiter$2(this,void 0,void 0,function*(){const _0x4fbcb7=this['getUrl'](_0x3028a2);return yield fetch(_0x4fbcb7,{'method':'POST','headers':{'Content-Type':'application/json'},'body':_0x437213?JSON['stringify'](_0x437213):null});});}['put'](_0x5944bc,_0x4e7632,_0x4ea562){return __awaiter$2(this,void 0,void 0,function*(){const _0x36a742=this['getUrl'](_0x5944bc);return yield fetch(_0x36a742,{'method':'PUT','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x4e7632},'body':_0x4ea562?JSON['stringify'](_0x4ea562):null});});}['delete'](_0x3655f5,_0x2bd898){return __awaiter$2(this,void 0,void 0,function*(){const _0x319eb2=this['getUrl'](_0x3655f5);return yield fetch(_0x319eb2,{'method':'DELETE','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x2bd898}});});}}
12
12
 
13
- var __awaiter$1=undefined&&undefined['__awaiter']||function(_0x3b1c05,_0x5ea840,_0x5629a4,_0xf61ba3){function _0x502838(_0x2c979d){return _0x2c979d instanceof _0x5629a4?_0x2c979d:new _0x5629a4(function(_0x5544ae){_0x5544ae(_0x2c979d);});}return new(_0x5629a4||(_0x5629a4=Promise))(function(_0x6ab3a9,_0x2a14f2){function _0x3ba0e2(_0x2b4194){try{_0x19250a(_0xf61ba3['next'](_0x2b4194));}catch(_0x419237){_0x2a14f2(_0x419237);}}function _0x446d76(_0x2a8221){try{_0x19250a(_0xf61ba3['throw'](_0x2a8221));}catch(_0x5e0f69){_0x2a14f2(_0x5e0f69);}}function _0x19250a(_0x360d17){_0x360d17['done']?_0x6ab3a9(_0x360d17['value']):_0x502838(_0x360d17['value'])['then'](_0x3ba0e2,_0x446d76);}_0x19250a((_0xf61ba3=_0xf61ba3['apply'](_0x3b1c05,_0x5ea840||[]))['next']());});};class SearchServersService{constructor(_0x66c33f){this['fetch']=_0x66c33f,this['path']='search-services';}['create'](_0x31b480,_0x1c380b,_0x147ab7,_0x2e2967,_0x3cf953,_0x55652c,_0x30664a,_0x69c1e){return __awaiter$1(this,void 0,void 0,function*(){const _0x53b9b1={'account_name':_0x31b480,'search_service_name':_0x1c380b,'endpoint':_0x147ab7,'key':_0x2e2967,'country':_0x3cf953,'provider':_0x55652c,'index_name':_0x30664a};try{const _0x4f4295=yield this['fetch']['post'](this['path'],_0x69c1e,_0x53b9b1);if(_0x4f4295['status']>0xc7&&_0x4f4295['status']<0x12c){const _0x27702a=yield _0x4f4295['json']();return new SuccessfulSearchServiceResponse(_0x27702a);}const _0xe1c117=yield _0x4f4295['json']();return new FailedSearchServiceResponse(_0xe1c117);}catch(_0x31f14d){if(_0x31f14d instanceof Error)return new FailedSearchServiceResponse({'detail':_0x31f14d['message'],'title':_0x31f14d['name'],'status':0x1f4,'instance':'','type':''});throw _0x31f14d;}});}['delete'](_0x2ea6de,_0x34acd0,_0x5cb2cc){return __awaiter$1(this,void 0,void 0,function*(){const _0x3d635c=this['path']+'/'+_0x2ea6de+'/'+_0x34acd0;try{const _0x3a27a5=yield this['fetch']['delete'](_0x3d635c,_0x5cb2cc);if(_0x3a27a5['status']>0xc7&&_0x3a27a5['status']<0x12c)return new SuccessfulResponse({});const _0x4b8ea7=yield _0x3a27a5['json']();return new FailedResponse(_0x4b8ea7);}catch(_0x59891e){if(_0x59891e instanceof Error)return new FailedResponse({'detail':_0x59891e['message'],'title':_0x59891e['name'],'status':0x1f4,'instance':'','type':''});throw _0x59891e;}});}['view'](_0x17ad27,_0x172f3a,_0x36dc42){return __awaiter$1(this,void 0,void 0,function*(){const _0x29fa9d=this['path']+'/'+_0x17ad27+'/'+_0x172f3a;try{const _0x267ed8=yield this['fetch']['get'](_0x29fa9d,_0x36dc42);if(_0x267ed8['status']>0xc7&&_0x267ed8['status']<0x12c){const _0x4b9aba=yield _0x267ed8['json']();return new SuccessfulViewSearchServiceResponse(_0x4b9aba);}const _0x4a9deb=yield _0x267ed8['json']();return new FailedViewSearchServiceResponse(_0x4a9deb);}catch(_0x48d6a5){if(_0x48d6a5 instanceof Error)return new FailedViewSearchServiceResponse({'detail':_0x48d6a5['message'],'title':_0x48d6a5['name'],'status':0x1f4,'instance':'','type':''});throw _0x48d6a5;}});}['edit'](_0x93d12c,_0x15b527,_0x3c0425,_0x37b638,_0x5d677f,_0x3d815e){return __awaiter$1(this,void 0,void 0,function*(){const _0x4c7a90={'account_name':_0x93d12c,'search_service_name':_0x15b527,'new_search_service_name':_0x3c0425,'key':_0x37b638,'country':_0x5d677f};try{const _0x189181=yield this['fetch']['put'](this['path'],_0x3d815e,_0x4c7a90);if(_0x189181['status']>0xc7&&_0x189181['status']<0x12c){const _0x1736eb=yield _0x189181['json']();return new SuccessfulSearchServiceResponse(_0x1736eb);}const _0x174e15=yield _0x189181['json']();return new FailedSearchServiceResponse(_0x174e15);}catch(_0x49ba28){if(_0x49ba28 instanceof Error)return new FailedSearchServiceResponse({'detail':_0x49ba28['message'],'title':_0x49ba28['name'],'status':0x1f4,'instance':'','type':''});throw _0x49ba28;}});}['list'](_0x3da9bf,_0x59546f){return __awaiter$1(this,void 0,void 0,function*(){const _0x2277d4=this['path']+'/'+_0x3da9bf;try{const _0x1fbdfe=yield this['fetch']['get'](_0x2277d4,_0x59546f);if(_0x1fbdfe['status']>0xc7&&_0x1fbdfe['status']<0x12c){const _0x4e76e5=yield _0x1fbdfe['json']();return new SuccessfulListSearchServiceResponse(_0x4e76e5);}const _0x23f82e=yield _0x1fbdfe['json']();return new FailedViewSearchServicesResponse(_0x23f82e);}catch(_0xb58f51){if(_0xb58f51 instanceof Error)return new FailedViewSearchServicesResponse({'detail':_0xb58f51['message'],'title':_0xb58f51['name'],'status':0x1f4,'instance':'','type':''});throw _0xb58f51;}});}}
13
+ var __awaiter$1=undefined&&undefined['__awaiter']||function(_0x856241,_0x1d6191,_0x593b3e,_0x201c67){function _0x1c49f4(_0x158e71){return _0x158e71 instanceof _0x593b3e?_0x158e71:new _0x593b3e(function(_0x2fb1ea){_0x2fb1ea(_0x158e71);});}return new(_0x593b3e||(_0x593b3e=Promise))(function(_0x225284,_0x14d7de){function _0x155d76(_0x16d257){try{_0x324a77(_0x201c67['next'](_0x16d257));}catch(_0x590ddd){_0x14d7de(_0x590ddd);}}function _0x4dfda9(_0x3d0648){try{_0x324a77(_0x201c67['throw'](_0x3d0648));}catch(_0x30d7d6){_0x14d7de(_0x30d7d6);}}function _0x324a77(_0x30ea4a){_0x30ea4a['done']?_0x225284(_0x30ea4a['value']):_0x1c49f4(_0x30ea4a['value'])['then'](_0x155d76,_0x4dfda9);}_0x324a77((_0x201c67=_0x201c67['apply'](_0x856241,_0x1d6191||[]))['next']());});};class SearchServersService{constructor(_0x26d5da){this['fetch']=_0x26d5da,this['path']='search-services';}['create'](_0x2655ef,_0x19dcc5,_0x18789d,_0x2d254b,_0x57168b,_0x5792c7,_0x3950b9,_0xfc1161){return __awaiter$1(this,void 0,void 0,function*(){const _0x295985={'account_name':_0x2655ef,'search_service_name':_0x19dcc5,'endpoint':_0x18789d,'key':_0x2d254b,'country':_0x57168b,'provider':_0x5792c7,'index_name':_0x3950b9};try{const _0x5d21d6=yield this['fetch']['post'](this['path'],_0xfc1161,_0x295985);if(_0x5d21d6['status']>0xc7&&_0x5d21d6['status']<0x12c){const _0x26eb43=yield _0x5d21d6['json']();return new SuccessfulSearchServiceResponse(_0x26eb43);}const _0x47aa8f=yield _0x5d21d6['json']();return new FailedSearchServiceResponse(_0x47aa8f);}catch(_0x5dd800){if(_0x5dd800 instanceof Error)return new FailedSearchServiceResponse({'detail':_0x5dd800['message'],'title':_0x5dd800['name'],'status':0x1f4,'instance':'','type':''});throw _0x5dd800;}});}['delete'](_0x257fb9,_0x19f011,_0x52ca94){return __awaiter$1(this,void 0,void 0,function*(){const _0x12ca21=this['path']+'/'+_0x257fb9+'/'+_0x19f011;try{const _0x2a0242=yield this['fetch']['delete'](_0x12ca21,_0x52ca94);if(_0x2a0242['status']>0xc7&&_0x2a0242['status']<0x12c)return new SuccessfulResponse({});const _0x1e40d4=yield _0x2a0242['json']();return new FailedResponse(_0x1e40d4);}catch(_0x191b13){if(_0x191b13 instanceof Error)return new FailedResponse({'detail':_0x191b13['message'],'title':_0x191b13['name'],'status':0x1f4,'instance':'','type':''});throw _0x191b13;}});}['view'](_0x17bd15,_0x514a27,_0x41fbda){return __awaiter$1(this,void 0,void 0,function*(){const _0x58bde0=this['path']+'/'+_0x17bd15+'/'+_0x514a27;try{const _0x4eb539=yield this['fetch']['get'](_0x58bde0,_0x41fbda);if(_0x4eb539['status']>0xc7&&_0x4eb539['status']<0x12c){const _0x144269=yield _0x4eb539['json']();return new SuccessfulViewSearchServiceResponse(_0x144269);}const _0x4598aa=yield _0x4eb539['json']();return new FailedViewSearchServiceResponse(_0x4598aa);}catch(_0x4f553b){if(_0x4f553b instanceof Error)return new FailedViewSearchServiceResponse({'detail':_0x4f553b['message'],'title':_0x4f553b['name'],'status':0x1f4,'instance':'','type':''});throw _0x4f553b;}});}['edit'](_0x22fe52,_0x50de67,_0x38a65a,_0x23686b,_0x3213b0,_0x267910){return __awaiter$1(this,void 0,void 0,function*(){const _0x511ad6={'account_name':_0x22fe52,'search_service_name':_0x50de67,'new_search_service_name':_0x38a65a,'key':_0x23686b,'country':_0x3213b0};try{const _0x175009=yield this['fetch']['put'](this['path'],_0x267910,_0x511ad6);if(_0x175009['status']>0xc7&&_0x175009['status']<0x12c){const _0x59ba3e=yield _0x175009['json']();return new SuccessfulSearchServiceResponse(_0x59ba3e);}const _0x1a01c6=yield _0x175009['json']();return new FailedSearchServiceResponse(_0x1a01c6);}catch(_0x28e5bc){if(_0x28e5bc instanceof Error)return new FailedSearchServiceResponse({'detail':_0x28e5bc['message'],'title':_0x28e5bc['name'],'status':0x1f4,'instance':'','type':''});throw _0x28e5bc;}});}['list'](_0x5ee896,_0x6f8fb8){return __awaiter$1(this,void 0,void 0,function*(){const _0xb0c93d=this['path']+'/'+_0x5ee896;try{const _0x50b0b8=yield this['fetch']['get'](_0xb0c93d,_0x6f8fb8);if(_0x50b0b8['status']>0xc7&&_0x50b0b8['status']<0x12c){const _0x41eeb9=yield _0x50b0b8['json']();return new SuccessfulListSearchServiceResponse(_0x41eeb9);}const _0x3cb226=yield _0x50b0b8['json']();return new FailedViewSearchServicesResponse(_0x3cb226);}catch(_0x22d980){if(_0x22d980 instanceof Error)return new FailedViewSearchServicesResponse({'detail':_0x22d980['message'],'title':_0x22d980['name'],'status':0x1f4,'instance':'','type':''});throw _0x22d980;}});}}
14
14
 
15
- var __awaiter=undefined&&undefined['__awaiter']||function(_0x1f292d,_0x507403,_0x596783,_0x252803){function _0x3420ba(_0x54daca){return _0x54daca instanceof _0x596783?_0x54daca:new _0x596783(function(_0x6b74f3){_0x6b74f3(_0x54daca);});}return new(_0x596783||(_0x596783=Promise))(function(_0x4b343b,_0x27c19f){function _0x5a8ff3(_0x453cb7){try{_0xbcc52f(_0x252803['next'](_0x453cb7));}catch(_0x5f2730){_0x27c19f(_0x5f2730);}}function _0x348f42(_0x1b4a30){try{_0xbcc52f(_0x252803['throw'](_0x1b4a30));}catch(_0x48d2c0){_0x27c19f(_0x48d2c0);}}function _0xbcc52f(_0x3f389a){_0x3f389a['done']?_0x4b343b(_0x3f389a['value']):_0x3420ba(_0x3f389a['value'])['then'](_0x5a8ff3,_0x348f42);}_0xbcc52f((_0x252803=_0x252803['apply'](_0x1f292d,_0x507403||[]))['next']());});};class AdminClient{constructor(_0x4f4dbc='https://admin.searchability.dev/'){var _0x29460c=new Fetch(_0x4f4dbc);this['Accounts']=new AccountService(_0x29460c),this['Lists']=new ListService(_0x29460c),this['ApiKeys']=new ApiKeyService(_0x29460c),this['SearchServices']=new SearchServersService(_0x29460c);}}class AuthClient{constructor(_0x1e7586='https://auth.searchability.dev/'){this['fetch']=new Fetch(_0x1e7586);}['login'](_0x171a05){return __awaiter(this,void 0,void 0,function*(){const _0x2211b7='login/'+_0x171a05;try{const _0x4edb2b=yield yield fetch(_0x2211b7);if(_0x4edb2b['status']>0xc7&&_0x4edb2b['status']<0x12c){const _0x4370b6=yield _0x4edb2b['json']();return new SuccessfulAuthResponse(_0x4370b6);}const _0x3051a3=yield _0x4edb2b['json']();return new FailedAuthResponse(_0x3051a3);}catch(_0x2fc8a1){if(_0x2fc8a1 instanceof Error)return new FailedAuthResponse({'detail':_0x2fc8a1['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x2fc8a1;}});}['refresh'](_0x433cbc){return __awaiter(this,void 0,void 0,function*(){const _0x1846f9='refresh',_0x44e338={'refresh_token':_0x433cbc};try{const _0x5edddd=yield this['fetch']['PostNoAuth'](_0x1846f9,_0x44e338);if(_0x5edddd['status']>0xc7&&_0x5edddd['status']<0x12c){const _0x562d54=yield _0x5edddd['json']();return new SuccessfulAuthResponse(_0x562d54);}const _0x2252a8=yield _0x5edddd['json']();return new FailedAuthResponse(_0x2252a8);}catch(_0x2b0404){if(_0x2b0404 instanceof Error)return new FailedAuthResponse({'detail':_0x2b0404['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x2b0404;}});}['getTokenStatus'](_0x3a9cec){if(Date['now']()<_0x3a9cec['access_expires'])return exports.TokenStatus['Ok'];if(Date['now']()<_0x3a9cec['refresh_expires'])return exports.TokenStatus['Refresh'];return exports.TokenStatus['Expired'];}}
15
+ var __awaiter=undefined&&undefined['__awaiter']||function(_0x3b447d,_0x4a07c9,_0x2fada3,_0x263ef1){function _0x3bca5f(_0x28889a){return _0x28889a instanceof _0x2fada3?_0x28889a:new _0x2fada3(function(_0x41d457){_0x41d457(_0x28889a);});}return new(_0x2fada3||(_0x2fada3=Promise))(function(_0x22c01c,_0x1844f1){function _0x5e6bdf(_0x4bc9f2){try{_0x4fae2a(_0x263ef1['next'](_0x4bc9f2));}catch(_0x5dbee8){_0x1844f1(_0x5dbee8);}}function _0x2a9685(_0x2e9e10){try{_0x4fae2a(_0x263ef1['throw'](_0x2e9e10));}catch(_0x5a75a4){_0x1844f1(_0x5a75a4);}}function _0x4fae2a(_0x3f1279){_0x3f1279['done']?_0x22c01c(_0x3f1279['value']):_0x3bca5f(_0x3f1279['value'])['then'](_0x5e6bdf,_0x2a9685);}_0x4fae2a((_0x263ef1=_0x263ef1['apply'](_0x3b447d,_0x4a07c9||[]))['next']());});};class AdminClient{constructor(_0x40364d='https://admin.searchability.dev/'){var _0x40e2d2=new Fetch(_0x40364d);this['Accounts']=new AccountService(_0x40e2d2),this['Lists']=new ListService(_0x40e2d2),this['ApiKeys']=new ApiKeyService(_0x40e2d2),this['SearchServices']=new SearchServersService(_0x40e2d2);}}class AuthClient{constructor(_0x36f390='https://auth.searchability.dev/'){this['fetch']=new Fetch(_0x36f390);}['login'](_0x501f8a){return __awaiter(this,void 0,void 0,function*(){const _0x49eb1e='login/'+_0x501f8a;try{const _0x575fd4=yield yield fetch(_0x49eb1e);if(_0x575fd4['status']>0xc7&&_0x575fd4['status']<0x12c){const _0x38848c=yield _0x575fd4['json']();return new SuccessfulAuthResponse(_0x38848c);}const _0x547b7a=yield _0x575fd4['json']();return new FailedAuthResponse(_0x547b7a);}catch(_0x5ed2d6){if(_0x5ed2d6 instanceof Error)return new FailedAuthResponse({'detail':_0x5ed2d6['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x5ed2d6;}});}['refresh'](_0x37d6e0){return __awaiter(this,void 0,void 0,function*(){const _0x5d5e1a='refresh',_0x1fb9c9={'refresh_token':_0x37d6e0};try{const _0x2d6824=yield this['fetch']['PostNoAuth'](_0x5d5e1a,_0x1fb9c9);if(_0x2d6824['status']>0xc7&&_0x2d6824['status']<0x12c){const _0x3ca147=yield _0x2d6824['json']();return new SuccessfulAuthResponse(_0x3ca147);}const _0x1a059b=yield _0x2d6824['json']();return new FailedAuthResponse(_0x1a059b);}catch(_0x2c6c3e){if(_0x2c6c3e instanceof Error)return new FailedAuthResponse({'detail':_0x2c6c3e['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x2c6c3e;}});}['getTokenStatus'](_0x13f11b){if(Date['now']()<_0x13f11b['access_expires'])return exports.TokenStatus['Ok'];if(Date['now']()<_0x13f11b['refresh_expires'])return exports.TokenStatus['Refresh'];return exports.TokenStatus['Expired'];}}
16
16
 
17
17
  exports.AdminClient = AdminClient;
18
18
  exports.AuthClient = AuthClient;
@@ -1,15 +1,15 @@
1
- var TokenStatus;(function(_0x555e90){_0x555e90[_0x555e90['Ok']=0x0]='Ok',_0x555e90[_0x555e90['Refresh']=0x1]='Refresh',_0x555e90[_0x555e90['Expired']=0x2]='Expired';}(TokenStatus||(TokenStatus={})));class Tokens{constructor(){this['access_token']='',this['access_expires']=0x0,this['refresh_token']='',this['refresh_expires']=0x0;}}class Response{constructor(_0x589bb8){this['isSuccess']=_0x589bb8;}}class SuccessfulAccountResponse extends Response{constructor(_0x12cf26){super(!![]),this['account']=_0x12cf26;}['toSuccess'](){return this['account'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class SuccessfulListIdentityResponse extends Response{constructor(_0x337f7f){super(!![]),this['list']=_0x337f7f;}['toSuccess'](){return this['list'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAccountResponse extends Response{constructor(_0x54739e){super(![]),this['problem']=_0x54739e;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class FailedListIdentityResponse extends Response{constructor(_0xfce474){super(![]),this['problem']=_0xfce474;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulAuthResponse extends Response{constructor(_0x6820f3){super(!![]),this['tokens']=_0x6820f3;}['toSuccess'](){return this['tokens'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAuthResponse extends Response{constructor(_0xfea91){super(![]),this['problem']=_0xfea91;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulApiKeyResponse extends Response{constructor(_0x526533){super(!![]),this['apiKey']=_0x526533;}['toSuccess'](){return this['apiKey'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedApiKeyResponse extends Response{constructor(_0x498a19){super(![]),this['problem']=_0x498a19;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulSearchServiceResponse extends Response{constructor(_0x4661af){super(!![]),this['searchService']=_0x4661af;}['toSuccess'](){return this['searchService'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedSearchServiceResponse extends Response{constructor(_0x28a996){super(![]),this['problem']=_0x28a996;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulViewSearchServiceResponse extends Response{constructor(_0x1b39c1){super(!![]),this['searchService']=_0x1b39c1;}['toSuccess'](){return this['searchService'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class SuccessfulListSearchServiceResponse extends Response{constructor(_0x48333e){super(!![]),this['searchServices']=_0x48333e;}['toSuccess'](){return this['searchServices'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedViewSearchServicesResponse extends Response{constructor(_0x3d20ef){super(![]),this['problem']=_0x3d20ef;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class FailedViewSearchServiceResponse extends Response{constructor(_0x352169){super(![]),this['problem']=_0x352169;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulApiKeyValueResponse extends Response{constructor(_0x19c35c){super(!![]),this['apiKeyValue']=_0x19c35c;}['toSuccess'](){return this['apiKeyValue'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class SuccessfulResponse extends Response{constructor(_0x547d84){super(!![]),this['obj']=_0x547d84;}['toSuccess'](){return this['obj'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedResponse extends Response{constructor(_0x4ee5ef){super(![]),this['problem']=_0x4ee5ef;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class FailedApiKeyValueResponse extends Response{constructor(_0x43eace){super(![]),this['problem']=_0x43eace;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}
1
+ var TokenStatus;(function(_0x2c44d6){_0x2c44d6[_0x2c44d6['Ok']=0x0]='Ok',_0x2c44d6[_0x2c44d6['Refresh']=0x1]='Refresh',_0x2c44d6[_0x2c44d6['Expired']=0x2]='Expired';}(TokenStatus||(TokenStatus={})));class Tokens{constructor(){this['access_token']='',this['access_expires']=0x0,this['refresh_token']='',this['refresh_expires']=0x0;}}class Response{constructor(_0x174783){this['isSuccess']=_0x174783;}}class SuccessfulAccountResponse extends Response{constructor(_0x491436){super(!![]),this['account']=_0x491436;}['toSuccess'](){return this['account'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class SuccessfulListIdentityResponse extends Response{constructor(_0x1c3031){super(!![]),this['list']=_0x1c3031;}['toSuccess'](){return this['list'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAccountResponse extends Response{constructor(_0x41aed2){super(![]),this['problem']=_0x41aed2;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class FailedListIdentityResponse extends Response{constructor(_0x5a660b){super(![]),this['problem']=_0x5a660b;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulAuthResponse extends Response{constructor(_0x28c1aa){super(!![]),this['tokens']=_0x28c1aa;}['toSuccess'](){return this['tokens'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAuthResponse extends Response{constructor(_0x2b62e4){super(![]),this['problem']=_0x2b62e4;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulApiKeyResponse extends Response{constructor(_0x11b977){super(!![]),this['apiKey']=_0x11b977;}['toSuccess'](){return this['apiKey'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedApiKeyResponse extends Response{constructor(_0x225fa8){super(![]),this['problem']=_0x225fa8;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulSearchServiceResponse extends Response{constructor(_0x37167a){super(!![]),this['searchService']=_0x37167a;}['toSuccess'](){return this['searchService'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedSearchServiceResponse extends Response{constructor(_0x100b23){super(![]),this['problem']=_0x100b23;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulViewSearchServiceResponse extends Response{constructor(_0xb014d4){super(!![]),this['searchService']=_0xb014d4;}['toSuccess'](){return this['searchService'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class SuccessfulListSearchServiceResponse extends Response{constructor(_0x49c26d){super(!![]),this['searchServices']=_0x49c26d;}['toSuccess'](){return this['searchServices'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedViewSearchServicesResponse extends Response{constructor(_0x25be0d){super(![]),this['problem']=_0x25be0d;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class FailedViewSearchServiceResponse extends Response{constructor(_0x367514){super(![]),this['problem']=_0x367514;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulApiKeyValueResponse extends Response{constructor(_0x202d49){super(!![]),this['apiKeyValue']=_0x202d49;}['toSuccess'](){return this['apiKeyValue'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class SuccessfulResponse extends Response{constructor(_0x17eb4d){super(!![]),this['obj']=_0x17eb4d;}['toSuccess'](){return this['obj'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedResponse extends Response{constructor(_0xafb6d3){super(![]),this['problem']=_0xafb6d3;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class FailedApiKeyValueResponse extends Response{constructor(_0x19a53e){super(![]),this['problem']=_0x19a53e;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}
2
2
 
3
- var __awaiter$5=undefined&&undefined['__awaiter']||function(_0x2a05b1,_0x4c762f,_0xf95329,_0x32edbd){function _0x17f574(_0x219640){return _0x219640 instanceof _0xf95329?_0x219640:new _0xf95329(function(_0x2629b3){_0x2629b3(_0x219640);});}return new(_0xf95329||(_0xf95329=Promise))(function(_0x1d1067,_0x504440){function _0x3b8b49(_0x3dc1c3){try{_0x473375(_0x32edbd['next'](_0x3dc1c3));}catch(_0x590f84){_0x504440(_0x590f84);}}function _0x368a9b(_0x5a0520){try{_0x473375(_0x32edbd['throw'](_0x5a0520));}catch(_0x467aed){_0x504440(_0x467aed);}}function _0x473375(_0x146cc1){_0x146cc1['done']?_0x1d1067(_0x146cc1['value']):_0x17f574(_0x146cc1['value'])['then'](_0x3b8b49,_0x368a9b);}_0x473375((_0x32edbd=_0x32edbd['apply'](_0x2a05b1,_0x4c762f||[]))['next']());});};class AccountService{constructor(_0x752749){this['fetch']=_0x752749;}['get'](_0x4f9a59,_0x1ef069){return __awaiter$5(this,void 0,void 0,function*(){const _0x4a249e='Account/'+_0x4f9a59+'/',_0x2d409a=yield this['fetch']['get'](_0x4a249e,_0x1ef069);try{if(_0x2d409a['status']>0xc7&&_0x2d409a['status']<0x12c){const _0x1dac3e=yield _0x2d409a['json']();return new SuccessfulAccountResponse(_0x1dac3e);}const _0x974e81=yield _0x2d409a['json']();return new FailedAccountResponse(_0x974e81);}catch(_0x2cf5fe){if(_0x2cf5fe instanceof Error)return new FailedAccountResponse({'detail':_0x2cf5fe['message'],'title':_0x2cf5fe['name'],'status':0x1f4,'instance':'','type':''});throw _0x2cf5fe;}});}}
3
+ var __awaiter$5=undefined&&undefined['__awaiter']||function(_0x35f880,_0x2b7ac6,_0x412686,_0x399f62){function _0x398bf7(_0x803bf5){return _0x803bf5 instanceof _0x412686?_0x803bf5:new _0x412686(function(_0x16bd5f){_0x16bd5f(_0x803bf5);});}return new(_0x412686||(_0x412686=Promise))(function(_0x291275,_0x3f0298){function _0x56e2bb(_0x1bf412){try{_0x14e948(_0x399f62['next'](_0x1bf412));}catch(_0x25dc13){_0x3f0298(_0x25dc13);}}function _0x2d402e(_0x3a06e9){try{_0x14e948(_0x399f62['throw'](_0x3a06e9));}catch(_0x121bcb){_0x3f0298(_0x121bcb);}}function _0x14e948(_0x459440){_0x459440['done']?_0x291275(_0x459440['value']):_0x398bf7(_0x459440['value'])['then'](_0x56e2bb,_0x2d402e);}_0x14e948((_0x399f62=_0x399f62['apply'](_0x35f880,_0x2b7ac6||[]))['next']());});};class AccountService{constructor(_0x295a65){this['fetch']=_0x295a65;}['get'](_0x1ee0fb,_0x368afb){return __awaiter$5(this,void 0,void 0,function*(){const _0x4a1dd='Account/'+_0x1ee0fb+'/',_0x5eea39=yield this['fetch']['get'](_0x4a1dd,_0x368afb);try{if(_0x5eea39['status']>0xc7&&_0x5eea39['status']<0x12c){const _0x486839=yield _0x5eea39['json']();return new SuccessfulAccountResponse(_0x486839);}const _0x1923fd=yield _0x5eea39['json']();return new FailedAccountResponse(_0x1923fd);}catch(_0x151bd7){if(_0x151bd7 instanceof Error)return new FailedAccountResponse({'detail':_0x151bd7['message'],'title':_0x151bd7['name'],'status':0x1f4,'instance':'','type':''});throw _0x151bd7;}});}}
4
4
 
5
- var __awaiter$4=undefined&&undefined['__awaiter']||function(_0xfeb29d,_0x48be09,_0x5b8aa2,_0x384ee0){function _0x222072(_0x2b7af4){return _0x2b7af4 instanceof _0x5b8aa2?_0x2b7af4:new _0x5b8aa2(function(_0x215376){_0x215376(_0x2b7af4);});}return new(_0x5b8aa2||(_0x5b8aa2=Promise))(function(_0xc454b0,_0x1c83d0){function _0x5ddc97(_0x2509b1){try{_0x36aabd(_0x384ee0['next'](_0x2509b1));}catch(_0x529ed4){_0x1c83d0(_0x529ed4);}}function _0xda9521(_0x5875bd){try{_0x36aabd(_0x384ee0['throw'](_0x5875bd));}catch(_0x428e4c){_0x1c83d0(_0x428e4c);}}function _0x36aabd(_0x4ba395){_0x4ba395['done']?_0xc454b0(_0x4ba395['value']):_0x222072(_0x4ba395['value'])['then'](_0x5ddc97,_0xda9521);}_0x36aabd((_0x384ee0=_0x384ee0['apply'](_0xfeb29d,_0x48be09||[]))['next']());});};class ApiKeyService{constructor(_0x5473f7){this['fetch']=_0x5473f7,this['path']='api-key';}['create'](_0xafa8b3,_0x5878e7,_0x44cbb0){return __awaiter$4(this,void 0,void 0,function*(){const _0x4a9f5c={'account_name':_0xafa8b3,'api_key_name':_0x5878e7};try{const _0x5567c8=yield this['fetch']['post'](this['path'],_0x44cbb0,_0x4a9f5c);if(_0x5567c8['status']>0xc7&&_0x5567c8['status']<0x12c){const _0x12a62a=yield _0x5567c8['json']();return new SuccessfulApiKeyResponse(_0x12a62a);}const _0x43a490=yield _0x5567c8['json']();return new FailedApiKeyResponse(_0x43a490);}catch(_0x17dfaf){if(_0x17dfaf instanceof Error)return new FailedApiKeyResponse({'detail':_0x17dfaf['message'],'title':_0x17dfaf['name'],'status':0x1f4,'instance':'','type':''});throw _0x17dfaf;}});}['view'](_0x4a530c,_0x195abb,_0x9240e){return __awaiter$4(this,void 0,void 0,function*(){const _0x31c519=this['path']+'/'+_0x4a530c+'/'+_0x195abb;try{const _0x183824=yield this['fetch']['get'](_0x31c519,_0x9240e);if(_0x183824['status']>0xc7&&_0x183824['status']<0x12c){const _0x4d5209=yield _0x183824['json']();return new SuccessfulApiKeyValueResponse(_0x4d5209);}const _0x500e88=yield _0x183824['json']();return new FailedApiKeyValueResponse(_0x500e88);}catch(_0x4392ee){if(_0x4392ee instanceof Error)return new FailedApiKeyValueResponse({'detail':_0x4392ee['message'],'title':_0x4392ee['name'],'status':0x1f4,'instance':'','type':''});throw _0x4392ee;}});}['delete'](_0xb52d88,_0x442b90,_0x4c2aa5){return __awaiter$4(this,void 0,void 0,function*(){const _0x79baf4=this['path']+'/'+_0xb52d88+'/'+_0x442b90;try{const _0x2e74d3=yield this['fetch']['delete'](_0x79baf4,_0x4c2aa5);if(_0x2e74d3['status']>0xc7&&_0x2e74d3['status']<0x12c)return new SuccessfulResponse({});const _0x22a5b4=yield _0x2e74d3['json']();return new FailedResponse(_0x22a5b4);}catch(_0x3c9fc2){if(_0x3c9fc2 instanceof Error)return new FailedResponse({'detail':_0x3c9fc2['message'],'title':_0x3c9fc2['name'],'status':0x1f4,'instance':'','type':''});throw _0x3c9fc2;}});}}
5
+ var __awaiter$4=undefined&&undefined['__awaiter']||function(_0x2625c0,_0x33df41,_0x5f4063,_0x9ce0d5){function _0x121248(_0x114615){return _0x114615 instanceof _0x5f4063?_0x114615:new _0x5f4063(function(_0x418b01){_0x418b01(_0x114615);});}return new(_0x5f4063||(_0x5f4063=Promise))(function(_0x1f5c82,_0x4ea4e5){function _0x5e1d25(_0x233fe0){try{_0x30811d(_0x9ce0d5['next'](_0x233fe0));}catch(_0x80d200){_0x4ea4e5(_0x80d200);}}function _0x4f59c5(_0xd27cb7){try{_0x30811d(_0x9ce0d5['throw'](_0xd27cb7));}catch(_0x2d7e05){_0x4ea4e5(_0x2d7e05);}}function _0x30811d(_0x29cab9){_0x29cab9['done']?_0x1f5c82(_0x29cab9['value']):_0x121248(_0x29cab9['value'])['then'](_0x5e1d25,_0x4f59c5);}_0x30811d((_0x9ce0d5=_0x9ce0d5['apply'](_0x2625c0,_0x33df41||[]))['next']());});};class ApiKeyService{constructor(_0x47f520){this['fetch']=_0x47f520,this['path']='api-key';}['create'](_0x35f0dd,_0xb5a53d,_0xd0c71){return __awaiter$4(this,void 0,void 0,function*(){const _0x5f1083={'account_name':_0x35f0dd,'api_key_name':_0xb5a53d};try{const _0xcc3749=yield this['fetch']['post'](this['path'],_0xd0c71,_0x5f1083);if(_0xcc3749['status']>0xc7&&_0xcc3749['status']<0x12c){const _0x4c4c0e=yield _0xcc3749['json']();return new SuccessfulApiKeyResponse(_0x4c4c0e);}const _0x2aa5de=yield _0xcc3749['json']();return new FailedApiKeyResponse(_0x2aa5de);}catch(_0x88e05a){if(_0x88e05a instanceof Error)return new FailedApiKeyResponse({'detail':_0x88e05a['message'],'title':_0x88e05a['name'],'status':0x1f4,'instance':'','type':''});throw _0x88e05a;}});}['view'](_0x28f632,_0x27ff8a,_0x472399){return __awaiter$4(this,void 0,void 0,function*(){const _0x1c2826=this['path']+'/'+_0x28f632+'/'+_0x27ff8a;try{const _0x4936a5=yield this['fetch']['get'](_0x1c2826,_0x472399);if(_0x4936a5['status']>0xc7&&_0x4936a5['status']<0x12c){const _0x540b8b=yield _0x4936a5['json']();return new SuccessfulApiKeyValueResponse(_0x540b8b);}const _0x21c9c3=yield _0x4936a5['json']();return new FailedApiKeyValueResponse(_0x21c9c3);}catch(_0x40fe91){if(_0x40fe91 instanceof Error)return new FailedApiKeyValueResponse({'detail':_0x40fe91['message'],'title':_0x40fe91['name'],'status':0x1f4,'instance':'','type':''});throw _0x40fe91;}});}['delete'](_0x1d3dcd,_0x34157a,_0x314338){return __awaiter$4(this,void 0,void 0,function*(){const _0x50b3e3=this['path']+'/'+_0x1d3dcd+'/'+_0x34157a;try{const _0x3f195e=yield this['fetch']['delete'](_0x50b3e3,_0x314338);if(_0x3f195e['status']>0xc7&&_0x3f195e['status']<0x12c)return new SuccessfulResponse({});const _0x27d726=yield _0x3f195e['json']();return new FailedResponse(_0x27d726);}catch(_0x378450){if(_0x378450 instanceof Error)return new FailedResponse({'detail':_0x378450['message'],'title':_0x378450['name'],'status':0x1f4,'instance':'','type':''});throw _0x378450;}});}}
6
6
 
7
- var __awaiter$3=undefined&&undefined['__awaiter']||function(_0x1838f1,_0x5819d6,_0x43e904,_0x3ddecc){function _0x4513bd(_0xf82162){return _0xf82162 instanceof _0x43e904?_0xf82162:new _0x43e904(function(_0x5a626a){_0x5a626a(_0xf82162);});}return new(_0x43e904||(_0x43e904=Promise))(function(_0x501575,_0x4b5d8b){function _0x376516(_0x51fd74){try{_0x18c221(_0x3ddecc['next'](_0x51fd74));}catch(_0x493c5a){_0x4b5d8b(_0x493c5a);}}function _0x47c6fb(_0x41a135){try{_0x18c221(_0x3ddecc['throw'](_0x41a135));}catch(_0x5bc499){_0x4b5d8b(_0x5bc499);}}function _0x18c221(_0x5e1853){_0x5e1853['done']?_0x501575(_0x5e1853['value']):_0x4513bd(_0x5e1853['value'])['then'](_0x376516,_0x47c6fb);}_0x18c221((_0x3ddecc=_0x3ddecc['apply'](_0x1838f1,_0x5819d6||[]))['next']());});};class ListService{constructor(_0x238516){this['fetch']=_0x238516;}['add'](_0xd6a7de,_0x25c151,_0x302e6b,_0xb8cf9){return __awaiter$3(this,void 0,void 0,function*(){const _0x53613b='List',_0x45f41f={'account_name':_0xd6a7de,'list_name':_0x25c151,'search_service_name':_0x302e6b};try{const _0x1d2766=yield this['fetch']['post'](_0x53613b,_0xb8cf9,_0x45f41f);if(_0x1d2766['status']>0xc7&&_0x1d2766['status']<0x12c){const _0x1e4936=yield _0x1d2766['json']();return new SuccessfulListIdentityResponse(_0x1e4936);}const _0x39ed28=yield _0x1d2766['json']();return new FailedListIdentityResponse(_0x39ed28);}catch(_0x3cc0f1){if(_0x3cc0f1 instanceof Error)return new FailedListIdentityResponse({'detail':_0x3cc0f1['message'],'title':_0x3cc0f1['name'],'status':0x1f4,'instance':'','type':''});throw _0x3cc0f1;}});}['delete'](_0x2bd52a,_0x3dd9b4,_0x5e9538){return __awaiter$3(this,void 0,void 0,function*(){const _0x540ca='List/'+_0x2bd52a+'/'+_0x3dd9b4,_0x187558=yield this['fetch']['delete'](_0x540ca,_0x5e9538);try{if(_0x187558['status']>0xc7&&_0x187558['status']<0x12c)return new SuccessfulResponse({});const _0x5a864a=yield _0x187558['json']();return new FailedResponse(_0x5a864a);}catch(_0x2408c6){if(_0x2408c6 instanceof Error)return new FailedResponse({'detail':_0x2408c6['message'],'title':_0x2408c6['name'],'status':0x1f4,'instance':'','type':''});throw _0x2408c6;}});}}
7
+ var __awaiter$3=undefined&&undefined['__awaiter']||function(_0x469d92,_0x561302,_0x45e6d5,_0x430be2){function _0x4d2542(_0x2ccb91){return _0x2ccb91 instanceof _0x45e6d5?_0x2ccb91:new _0x45e6d5(function(_0x52e186){_0x52e186(_0x2ccb91);});}return new(_0x45e6d5||(_0x45e6d5=Promise))(function(_0x5590a4,_0x5207dc){function _0x1955b7(_0x3e3881){try{_0x3bf085(_0x430be2['next'](_0x3e3881));}catch(_0x308edc){_0x5207dc(_0x308edc);}}function _0x37d2aa(_0x3ef31f){try{_0x3bf085(_0x430be2['throw'](_0x3ef31f));}catch(_0x1af0e9){_0x5207dc(_0x1af0e9);}}function _0x3bf085(_0x1ba551){_0x1ba551['done']?_0x5590a4(_0x1ba551['value']):_0x4d2542(_0x1ba551['value'])['then'](_0x1955b7,_0x37d2aa);}_0x3bf085((_0x430be2=_0x430be2['apply'](_0x469d92,_0x561302||[]))['next']());});};class ListService{constructor(_0x351e6a){this['fetch']=_0x351e6a;}['add'](_0x4d0298,_0x53e870,_0x436730,_0x558937){return __awaiter$3(this,void 0,void 0,function*(){const _0x51860e='List',_0x3fb27f={'account_name':_0x4d0298,'list_name':_0x53e870,'search_service_name':_0x436730};try{const _0x49325c=yield this['fetch']['post'](_0x51860e,_0x558937,_0x3fb27f);if(_0x49325c['status']>0xc7&&_0x49325c['status']<0x12c){const _0x427174=yield _0x49325c['json']();return new SuccessfulListIdentityResponse(_0x427174);}const _0x4dff3f=yield _0x49325c['json']();return new FailedListIdentityResponse(_0x4dff3f);}catch(_0x2db80e){if(_0x2db80e instanceof Error)return new FailedListIdentityResponse({'detail':_0x2db80e['message'],'title':_0x2db80e['name'],'status':0x1f4,'instance':'','type':''});throw _0x2db80e;}});}['delete'](_0x1a96d2,_0x3e100e,_0x1e00e3){return __awaiter$3(this,void 0,void 0,function*(){const _0x1169da='List/'+_0x1a96d2+'/'+_0x3e100e,_0x469bc6=yield this['fetch']['delete'](_0x1169da,_0x1e00e3);try{if(_0x469bc6['status']>0xc7&&_0x469bc6['status']<0x12c)return new SuccessfulResponse({});const _0x1057ca=yield _0x469bc6['json']();return new FailedResponse(_0x1057ca);}catch(_0x5b21ed){if(_0x5b21ed instanceof Error)return new FailedResponse({'detail':_0x5b21ed['message'],'title':_0x5b21ed['name'],'status':0x1f4,'instance':'','type':''});throw _0x5b21ed;}});}}
8
8
 
9
- var __awaiter$2=undefined&&undefined['__awaiter']||function(_0xbe4d84,_0x4bcce8,_0x505326,_0x225f15){function _0x1c95ce(_0x542a7d){return _0x542a7d instanceof _0x505326?_0x542a7d:new _0x505326(function(_0x41f423){_0x41f423(_0x542a7d);});}return new(_0x505326||(_0x505326=Promise))(function(_0x439ab9,_0x8f84a3){function _0x1a7f3e(_0x54df4d){try{_0x266286(_0x225f15['next'](_0x54df4d));}catch(_0x39b84d){_0x8f84a3(_0x39b84d);}}function _0x4445e2(_0x435c6d){try{_0x266286(_0x225f15['throw'](_0x435c6d));}catch(_0x3bddc1){_0x8f84a3(_0x3bddc1);}}function _0x266286(_0x1bb28a){_0x1bb28a['done']?_0x439ab9(_0x1bb28a['value']):_0x1c95ce(_0x1bb28a['value'])['then'](_0x1a7f3e,_0x4445e2);}_0x266286((_0x225f15=_0x225f15['apply'](_0xbe4d84,_0x4bcce8||[]))['next']());});};class Fetch{constructor(_0x323f65){this['baseUri']=_0x323f65,this['getUrl']=_0x3879fe=>{return _0x3879fe['startsWith']('/')&&(_0x3879fe=_0x3879fe['replace']('/','')),''+this['baseUri']+_0x3879fe;},!_0x323f65['endsWith']('/')&&(_0x323f65=_0x323f65+'/');}['get'](_0x39a1f2,_0x454431){return __awaiter$2(this,void 0,void 0,function*(){const _0x19f3d3=this['getUrl'](_0x39a1f2);return yield fetch(_0x19f3d3,{'method':'GET','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x454431}});});}['post'](_0x2b904a,_0x5833dd,_0x368f05){return __awaiter$2(this,void 0,void 0,function*(){const _0x2679c0=this['getUrl'](_0x2b904a);return yield fetch(_0x2679c0,{'method':'POST','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x5833dd},'body':_0x368f05?JSON['stringify'](_0x368f05):null});});}['PostNoAuth'](_0x1f862f,_0x337d1b){return __awaiter$2(this,void 0,void 0,function*(){const _0x521e34=this['getUrl'](_0x1f862f);return yield fetch(_0x521e34,{'method':'POST','headers':{'Content-Type':'application/json'},'body':_0x337d1b?JSON['stringify'](_0x337d1b):null});});}['put'](_0x11e230,_0xacdd83,_0x1aa708){return __awaiter$2(this,void 0,void 0,function*(){const _0x10fb51=this['getUrl'](_0x11e230);return yield fetch(_0x10fb51,{'method':'PUT','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0xacdd83},'body':_0x1aa708?JSON['stringify'](_0x1aa708):null});});}['delete'](_0x4ddd4f,_0x9be57e){return __awaiter$2(this,void 0,void 0,function*(){const _0x287a33=this['getUrl'](_0x4ddd4f);return yield fetch(_0x287a33,{'method':'DELETE','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x9be57e}});});}}
9
+ var __awaiter$2=undefined&&undefined['__awaiter']||function(_0x43c404,_0xafe0c5,_0x396b8e,_0x1fbb30){function _0x41e9c8(_0x4a96fa){return _0x4a96fa instanceof _0x396b8e?_0x4a96fa:new _0x396b8e(function(_0x358d6e){_0x358d6e(_0x4a96fa);});}return new(_0x396b8e||(_0x396b8e=Promise))(function(_0x5e9ab8,_0xa4d331){function _0x257f64(_0x36b45a){try{_0x3360b9(_0x1fbb30['next'](_0x36b45a));}catch(_0x2cdf66){_0xa4d331(_0x2cdf66);}}function _0x54a3a1(_0x2e0366){try{_0x3360b9(_0x1fbb30['throw'](_0x2e0366));}catch(_0x1f9923){_0xa4d331(_0x1f9923);}}function _0x3360b9(_0x185576){_0x185576['done']?_0x5e9ab8(_0x185576['value']):_0x41e9c8(_0x185576['value'])['then'](_0x257f64,_0x54a3a1);}_0x3360b9((_0x1fbb30=_0x1fbb30['apply'](_0x43c404,_0xafe0c5||[]))['next']());});};class Fetch{constructor(_0x4b360d){this['baseUri']=_0x4b360d,this['getUrl']=_0x32e19b=>{return _0x32e19b['startsWith']('/')&&(_0x32e19b=_0x32e19b['replace']('/','')),''+this['baseUri']+_0x32e19b;},!_0x4b360d['endsWith']('/')&&(_0x4b360d=_0x4b360d+'/');}['get'](_0x197d40,_0x40a79d){return __awaiter$2(this,void 0,void 0,function*(){const _0x9305ad=this['getUrl'](_0x197d40);return yield fetch(_0x9305ad,{'method':'GET','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x40a79d}});});}['post'](_0x3d082f,_0x557e3f,_0x10594d){return __awaiter$2(this,void 0,void 0,function*(){const _0x141c97=this['getUrl'](_0x3d082f);return yield fetch(_0x141c97,{'method':'POST','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x557e3f},'body':_0x10594d?JSON['stringify'](_0x10594d):null});});}['PostNoAuth'](_0x495b2c,_0x2c4dfe){return __awaiter$2(this,void 0,void 0,function*(){const _0x5ad615=this['getUrl'](_0x495b2c);return yield fetch(_0x5ad615,{'method':'POST','headers':{'Content-Type':'application/json'},'body':_0x2c4dfe?JSON['stringify'](_0x2c4dfe):null});});}['put'](_0x5a205d,_0x4dc9f9,_0x505043){return __awaiter$2(this,void 0,void 0,function*(){const _0x37112c=this['getUrl'](_0x5a205d);return yield fetch(_0x37112c,{'method':'PUT','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x4dc9f9},'body':_0x505043?JSON['stringify'](_0x505043):null});});}['delete'](_0x328120,_0x2ce678){return __awaiter$2(this,void 0,void 0,function*(){const _0x4634e5=this['getUrl'](_0x328120);return yield fetch(_0x4634e5,{'method':'DELETE','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x2ce678}});});}}
10
10
 
11
- var __awaiter$1=undefined&&undefined['__awaiter']||function(_0xd28365,_0x46d8af,_0x16d274,_0x1cf27b){function _0x1d1c9d(_0x2eb5f8){return _0x2eb5f8 instanceof _0x16d274?_0x2eb5f8:new _0x16d274(function(_0x24ca8c){_0x24ca8c(_0x2eb5f8);});}return new(_0x16d274||(_0x16d274=Promise))(function(_0x1e3507,_0x3b35df){function _0x3d56b6(_0x57986b){try{_0x4dff30(_0x1cf27b['next'](_0x57986b));}catch(_0x445967){_0x3b35df(_0x445967);}}function _0x4e1eb1(_0x371fda){try{_0x4dff30(_0x1cf27b['throw'](_0x371fda));}catch(_0x4acfcc){_0x3b35df(_0x4acfcc);}}function _0x4dff30(_0x3e736e){_0x3e736e['done']?_0x1e3507(_0x3e736e['value']):_0x1d1c9d(_0x3e736e['value'])['then'](_0x3d56b6,_0x4e1eb1);}_0x4dff30((_0x1cf27b=_0x1cf27b['apply'](_0xd28365,_0x46d8af||[]))['next']());});};class SearchServersService{constructor(_0xfb75fc){this['fetch']=_0xfb75fc,this['path']='search-services';}['create'](_0x415143,_0x3fc3c8,_0x2de9b0,_0x33779b,_0x31e24f,_0x19e818,_0x37a32f,_0x1b8a55){return __awaiter$1(this,void 0,void 0,function*(){const _0x2f1455={'account_name':_0x415143,'search_service_name':_0x3fc3c8,'endpoint':_0x2de9b0,'key':_0x33779b,'country':_0x31e24f,'provider':_0x19e818,'index_name':_0x37a32f};try{const _0x5a0a98=yield this['fetch']['post'](this['path'],_0x1b8a55,_0x2f1455);if(_0x5a0a98['status']>0xc7&&_0x5a0a98['status']<0x12c){const _0x3d12b3=yield _0x5a0a98['json']();return new SuccessfulSearchServiceResponse(_0x3d12b3);}const _0x1638f0=yield _0x5a0a98['json']();return new FailedSearchServiceResponse(_0x1638f0);}catch(_0x2057b6){if(_0x2057b6 instanceof Error)return new FailedSearchServiceResponse({'detail':_0x2057b6['message'],'title':_0x2057b6['name'],'status':0x1f4,'instance':'','type':''});throw _0x2057b6;}});}['delete'](_0x5549af,_0x35079b,_0x1ced64){return __awaiter$1(this,void 0,void 0,function*(){const _0x6a5f6e=this['path']+'/'+_0x5549af+'/'+_0x35079b;try{const _0x2caf61=yield this['fetch']['delete'](_0x6a5f6e,_0x1ced64);if(_0x2caf61['status']>0xc7&&_0x2caf61['status']<0x12c)return new SuccessfulResponse({});const _0x469eaa=yield _0x2caf61['json']();return new FailedResponse(_0x469eaa);}catch(_0x14c895){if(_0x14c895 instanceof Error)return new FailedResponse({'detail':_0x14c895['message'],'title':_0x14c895['name'],'status':0x1f4,'instance':'','type':''});throw _0x14c895;}});}['view'](_0x4a4ee8,_0x9c3ab5,_0x421cc9){return __awaiter$1(this,void 0,void 0,function*(){const _0x352364=this['path']+'/'+_0x4a4ee8+'/'+_0x9c3ab5;try{const _0x557e39=yield this['fetch']['get'](_0x352364,_0x421cc9);if(_0x557e39['status']>0xc7&&_0x557e39['status']<0x12c){const _0x409f45=yield _0x557e39['json']();return new SuccessfulViewSearchServiceResponse(_0x409f45);}const _0x14a27a=yield _0x557e39['json']();return new FailedViewSearchServiceResponse(_0x14a27a);}catch(_0x13a041){if(_0x13a041 instanceof Error)return new FailedViewSearchServiceResponse({'detail':_0x13a041['message'],'title':_0x13a041['name'],'status':0x1f4,'instance':'','type':''});throw _0x13a041;}});}['edit'](_0x1aa7bd,_0x4496d0,_0x482c9f,_0x3ded2f,_0x4a06e6,_0x332f83){return __awaiter$1(this,void 0,void 0,function*(){const _0x23e650={'account_name':_0x1aa7bd,'search_service_name':_0x4496d0,'new_search_service_name':_0x482c9f,'key':_0x3ded2f,'country':_0x4a06e6};try{const _0x26d9d3=yield this['fetch']['put'](this['path'],_0x332f83,_0x23e650);if(_0x26d9d3['status']>0xc7&&_0x26d9d3['status']<0x12c){const _0xf5cecc=yield _0x26d9d3['json']();return new SuccessfulSearchServiceResponse(_0xf5cecc);}const _0x33e20c=yield _0x26d9d3['json']();return new FailedSearchServiceResponse(_0x33e20c);}catch(_0x2d148f){if(_0x2d148f instanceof Error)return new FailedSearchServiceResponse({'detail':_0x2d148f['message'],'title':_0x2d148f['name'],'status':0x1f4,'instance':'','type':''});throw _0x2d148f;}});}['list'](_0x29f883,_0x5f2567){return __awaiter$1(this,void 0,void 0,function*(){const _0x27de72=this['path']+'/'+_0x29f883;try{const _0x309531=yield this['fetch']['get'](_0x27de72,_0x5f2567);if(_0x309531['status']>0xc7&&_0x309531['status']<0x12c){const _0x3ed655=yield _0x309531['json']();return new SuccessfulListSearchServiceResponse(_0x3ed655);}const _0x3096f4=yield _0x309531['json']();return new FailedViewSearchServicesResponse(_0x3096f4);}catch(_0x486c3d){if(_0x486c3d instanceof Error)return new FailedViewSearchServicesResponse({'detail':_0x486c3d['message'],'title':_0x486c3d['name'],'status':0x1f4,'instance':'','type':''});throw _0x486c3d;}});}}
11
+ var __awaiter$1=undefined&&undefined['__awaiter']||function(_0x4de4ed,_0x573e21,_0x1e4644,_0x2e9b01){function _0x290617(_0x41f341){return _0x41f341 instanceof _0x1e4644?_0x41f341:new _0x1e4644(function(_0x3fea12){_0x3fea12(_0x41f341);});}return new(_0x1e4644||(_0x1e4644=Promise))(function(_0x14d606,_0x3976e3){function _0x532c15(_0x1d37da){try{_0x4e0373(_0x2e9b01['next'](_0x1d37da));}catch(_0x1bb841){_0x3976e3(_0x1bb841);}}function _0x41f962(_0x53aa56){try{_0x4e0373(_0x2e9b01['throw'](_0x53aa56));}catch(_0x8be13c){_0x3976e3(_0x8be13c);}}function _0x4e0373(_0xe78425){_0xe78425['done']?_0x14d606(_0xe78425['value']):_0x290617(_0xe78425['value'])['then'](_0x532c15,_0x41f962);}_0x4e0373((_0x2e9b01=_0x2e9b01['apply'](_0x4de4ed,_0x573e21||[]))['next']());});};class SearchServersService{constructor(_0x2d1f8f){this['fetch']=_0x2d1f8f,this['path']='search-services';}['create'](_0x44e24b,_0x5589a6,_0x4707a9,_0x50feef,_0x4679f5,_0x4fae29,_0x2b5d00,_0x3f4b11){return __awaiter$1(this,void 0,void 0,function*(){const _0x21f824={'account_name':_0x44e24b,'search_service_name':_0x5589a6,'endpoint':_0x4707a9,'key':_0x50feef,'country':_0x4679f5,'provider':_0x4fae29,'index_name':_0x2b5d00};try{const _0xc99383=yield this['fetch']['post'](this['path'],_0x3f4b11,_0x21f824);if(_0xc99383['status']>0xc7&&_0xc99383['status']<0x12c){const _0x2774a5=yield _0xc99383['json']();return new SuccessfulSearchServiceResponse(_0x2774a5);}const _0x841743=yield _0xc99383['json']();return new FailedSearchServiceResponse(_0x841743);}catch(_0x514534){if(_0x514534 instanceof Error)return new FailedSearchServiceResponse({'detail':_0x514534['message'],'title':_0x514534['name'],'status':0x1f4,'instance':'','type':''});throw _0x514534;}});}['delete'](_0x15e30b,_0x37a306,_0x338246){return __awaiter$1(this,void 0,void 0,function*(){const _0x1904e1=this['path']+'/'+_0x15e30b+'/'+_0x37a306;try{const _0x1652c0=yield this['fetch']['delete'](_0x1904e1,_0x338246);if(_0x1652c0['status']>0xc7&&_0x1652c0['status']<0x12c)return new SuccessfulResponse({});const _0x5abc33=yield _0x1652c0['json']();return new FailedResponse(_0x5abc33);}catch(_0x68d40c){if(_0x68d40c instanceof Error)return new FailedResponse({'detail':_0x68d40c['message'],'title':_0x68d40c['name'],'status':0x1f4,'instance':'','type':''});throw _0x68d40c;}});}['view'](_0x3b05ae,_0xa03f7f,_0xcb4c07){return __awaiter$1(this,void 0,void 0,function*(){const _0x36e87e=this['path']+'/'+_0x3b05ae+'/'+_0xa03f7f;try{const _0x280cf6=yield this['fetch']['get'](_0x36e87e,_0xcb4c07);if(_0x280cf6['status']>0xc7&&_0x280cf6['status']<0x12c){const _0x57ae57=yield _0x280cf6['json']();return new SuccessfulViewSearchServiceResponse(_0x57ae57);}const _0x49180c=yield _0x280cf6['json']();return new FailedViewSearchServiceResponse(_0x49180c);}catch(_0x505066){if(_0x505066 instanceof Error)return new FailedViewSearchServiceResponse({'detail':_0x505066['message'],'title':_0x505066['name'],'status':0x1f4,'instance':'','type':''});throw _0x505066;}});}['edit'](_0x2ff7af,_0x303208,_0x46aaeb,_0x3d1967,_0x276990,_0x5e8a9){return __awaiter$1(this,void 0,void 0,function*(){const _0x2ff036={'account_name':_0x2ff7af,'search_service_name':_0x303208,'new_search_service_name':_0x46aaeb,'key':_0x3d1967,'country':_0x276990};try{const _0x4feb12=yield this['fetch']['put'](this['path'],_0x5e8a9,_0x2ff036);if(_0x4feb12['status']>0xc7&&_0x4feb12['status']<0x12c){const _0x32016e=yield _0x4feb12['json']();return new SuccessfulSearchServiceResponse(_0x32016e);}const _0x274485=yield _0x4feb12['json']();return new FailedSearchServiceResponse(_0x274485);}catch(_0x1545fe){if(_0x1545fe instanceof Error)return new FailedSearchServiceResponse({'detail':_0x1545fe['message'],'title':_0x1545fe['name'],'status':0x1f4,'instance':'','type':''});throw _0x1545fe;}});}['list'](_0x1c152b,_0x100164){return __awaiter$1(this,void 0,void 0,function*(){const _0x5ced86=this['path']+'/'+_0x1c152b;try{const _0x497ec8=yield this['fetch']['get'](_0x5ced86,_0x100164);if(_0x497ec8['status']>0xc7&&_0x497ec8['status']<0x12c){const _0x1091e6=yield _0x497ec8['json']();return new SuccessfulListSearchServiceResponse(_0x1091e6);}const _0x148ec1=yield _0x497ec8['json']();return new FailedViewSearchServicesResponse(_0x148ec1);}catch(_0x3e8de3){if(_0x3e8de3 instanceof Error)return new FailedViewSearchServicesResponse({'detail':_0x3e8de3['message'],'title':_0x3e8de3['name'],'status':0x1f4,'instance':'','type':''});throw _0x3e8de3;}});}}
12
12
 
13
- var __awaiter=undefined&&undefined['__awaiter']||function(_0x33f109,_0x320004,_0x1de34a,_0x5af53b){function _0x4058aa(_0x4fc652){return _0x4fc652 instanceof _0x1de34a?_0x4fc652:new _0x1de34a(function(_0x25e3bb){_0x25e3bb(_0x4fc652);});}return new(_0x1de34a||(_0x1de34a=Promise))(function(_0xb45fde,_0x21b07b){function _0x15dd82(_0x313c41){try{_0x52c8c9(_0x5af53b['next'](_0x313c41));}catch(_0x52e114){_0x21b07b(_0x52e114);}}function _0x212e9d(_0x46d4ce){try{_0x52c8c9(_0x5af53b['throw'](_0x46d4ce));}catch(_0x4d4dad){_0x21b07b(_0x4d4dad);}}function _0x52c8c9(_0x51810c){_0x51810c['done']?_0xb45fde(_0x51810c['value']):_0x4058aa(_0x51810c['value'])['then'](_0x15dd82,_0x212e9d);}_0x52c8c9((_0x5af53b=_0x5af53b['apply'](_0x33f109,_0x320004||[]))['next']());});};class AdminClient{constructor(_0x2092dc='https://admin.searchability.dev/'){var _0x436d55=new Fetch(_0x2092dc);this['Accounts']=new AccountService(_0x436d55),this['Lists']=new ListService(_0x436d55),this['ApiKeys']=new ApiKeyService(_0x436d55),this['SearchServices']=new SearchServersService(_0x436d55);}}class AuthClient{constructor(_0x57fc74='https://auth.searchability.dev/'){this['fetch']=new Fetch(_0x57fc74);}['login'](_0x3f0da6){return __awaiter(this,void 0,void 0,function*(){const _0x33b375='login/'+_0x3f0da6;try{const _0x455a9d=yield yield fetch(_0x33b375);if(_0x455a9d['status']>0xc7&&_0x455a9d['status']<0x12c){const _0x3d69b6=yield _0x455a9d['json']();return new SuccessfulAuthResponse(_0x3d69b6);}const _0x89b6f8=yield _0x455a9d['json']();return new FailedAuthResponse(_0x89b6f8);}catch(_0x3d7efe){if(_0x3d7efe instanceof Error)return new FailedAuthResponse({'detail':_0x3d7efe['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x3d7efe;}});}['refresh'](_0x5882b6){return __awaiter(this,void 0,void 0,function*(){const _0x4b3c1d='refresh',_0x4367f0={'refresh_token':_0x5882b6};try{const _0x343902=yield this['fetch']['PostNoAuth'](_0x4b3c1d,_0x4367f0);if(_0x343902['status']>0xc7&&_0x343902['status']<0x12c){const _0x2438fd=yield _0x343902['json']();return new SuccessfulAuthResponse(_0x2438fd);}const _0xf5cc44=yield _0x343902['json']();return new FailedAuthResponse(_0xf5cc44);}catch(_0x288d21){if(_0x288d21 instanceof Error)return new FailedAuthResponse({'detail':_0x288d21['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x288d21;}});}['getTokenStatus'](_0x474292){if(Date['now']()<_0x474292['access_expires'])return TokenStatus['Ok'];if(Date['now']()<_0x474292['refresh_expires'])return TokenStatus['Refresh'];return TokenStatus['Expired'];}}
13
+ var __awaiter=undefined&&undefined['__awaiter']||function(_0x41d7dd,_0x1147b6,_0x3868db,_0x1fdf01){function _0x2632bd(_0x3036a6){return _0x3036a6 instanceof _0x3868db?_0x3036a6:new _0x3868db(function(_0x2b87fc){_0x2b87fc(_0x3036a6);});}return new(_0x3868db||(_0x3868db=Promise))(function(_0x407546,_0x373209){function _0x28200d(_0x5f63c3){try{_0x1d0d19(_0x1fdf01['next'](_0x5f63c3));}catch(_0x3cee2c){_0x373209(_0x3cee2c);}}function _0x3c2bf2(_0x298dd4){try{_0x1d0d19(_0x1fdf01['throw'](_0x298dd4));}catch(_0x4d3f45){_0x373209(_0x4d3f45);}}function _0x1d0d19(_0x174229){_0x174229['done']?_0x407546(_0x174229['value']):_0x2632bd(_0x174229['value'])['then'](_0x28200d,_0x3c2bf2);}_0x1d0d19((_0x1fdf01=_0x1fdf01['apply'](_0x41d7dd,_0x1147b6||[]))['next']());});};class AdminClient{constructor(_0x4816d9='https://admin.searchability.dev/'){var _0x441149=new Fetch(_0x4816d9);this['Accounts']=new AccountService(_0x441149),this['Lists']=new ListService(_0x441149),this['ApiKeys']=new ApiKeyService(_0x441149),this['SearchServices']=new SearchServersService(_0x441149);}}class AuthClient{constructor(_0x23f554='https://auth.searchability.dev/'){this['fetch']=new Fetch(_0x23f554);}['login'](_0x40ebb8){return __awaiter(this,void 0,void 0,function*(){const _0x871af7='login/'+_0x40ebb8;try{const _0x160d7e=yield yield fetch(_0x871af7);if(_0x160d7e['status']>0xc7&&_0x160d7e['status']<0x12c){const _0x57b933=yield _0x160d7e['json']();return new SuccessfulAuthResponse(_0x57b933);}const _0x10736a=yield _0x160d7e['json']();return new FailedAuthResponse(_0x10736a);}catch(_0x4963f7){if(_0x4963f7 instanceof Error)return new FailedAuthResponse({'detail':_0x4963f7['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x4963f7;}});}['refresh'](_0x5ae000){return __awaiter(this,void 0,void 0,function*(){const _0x3ce96b='refresh',_0x506f04={'refresh_token':_0x5ae000};try{const _0x2a9712=yield this['fetch']['PostNoAuth'](_0x3ce96b,_0x506f04);if(_0x2a9712['status']>0xc7&&_0x2a9712['status']<0x12c){const _0x5e4a3b=yield _0x2a9712['json']();return new SuccessfulAuthResponse(_0x5e4a3b);}const _0x4cbd60=yield _0x2a9712['json']();return new FailedAuthResponse(_0x4cbd60);}catch(_0x317dd1){if(_0x317dd1 instanceof Error)return new FailedAuthResponse({'detail':_0x317dd1['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x317dd1;}});}['getTokenStatus'](_0x5a39bb){if(Date['now']()<_0x5a39bb['access_expires'])return TokenStatus['Ok'];if(Date['now']()<_0x5a39bb['refresh_expires'])return TokenStatus['Refresh'];return TokenStatus['Expired'];}}
14
14
 
15
15
  export { AdminClient, AuthClient, TokenStatus, Tokens };
package/dist/types.d.ts CHANGED
@@ -87,6 +87,7 @@ type ListIdentity = {
87
87
  created: number;
88
88
  account_name: string;
89
89
  is_shared: boolean;
90
+ version: number;
90
91
  };
91
92
  type ApiKey = {
92
93
  name: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@searchability/admin-client",
3
- "version": "0.0.50",
3
+ "version": "0.0.51",
4
4
  "description": "Searchability admin client.",
5
5
  "type": "module",
6
6
  "types": "./dist/types.d.ts",
@@ -1,15 +0,0 @@
1
- var TokenStatus;(function(_0x2572fc){_0x2572fc[_0x2572fc['Ok']=0x0]='Ok',_0x2572fc[_0x2572fc['Refresh']=0x1]='Refresh',_0x2572fc[_0x2572fc['Expired']=0x2]='Expired';}(TokenStatus||(TokenStatus={})));class Tokens{constructor(){this['access_token']='',this['access_expires']=0x0,this['refresh_token']='',this['refresh_expires']=0x0;}}class Response{constructor(_0x2d696d){this['isSuccess']=_0x2d696d;}}class SuccessfulAccountResponse extends Response{constructor(_0x5303c2){super(!![]),this['account']=_0x5303c2;}['toSuccess'](){return this['account'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class SuccessfulListIdentityResponse extends Response{constructor(_0x3b352a){super(!![]),this['list']=_0x3b352a;}['toSuccess'](){return this['list'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAccountResponse extends Response{constructor(_0x26d555){super(![]),this['problem']=_0x26d555;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class FailedListIdentityResponse extends Response{constructor(_0x3e32af){super(![]),this['problem']=_0x3e32af;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulAuthResponse extends Response{constructor(_0x29489e){super(!![]),this['tokens']=_0x29489e;}['toSuccess'](){return this['tokens'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedAuthResponse extends Response{constructor(_0x588eb4){super(![]),this['problem']=_0x588eb4;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulApiKeyResponse extends Response{constructor(_0x104009){super(!![]),this['apiKey']=_0x104009;}['toSuccess'](){return this['apiKey'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedApiKeyResponse extends Response{constructor(_0x1f8431){super(![]),this['problem']=_0x1f8431;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulSearchServiceResponse extends Response{constructor(_0x247dfc){super(!![]),this['searchService']=_0x247dfc;}['toSuccess'](){return this['searchService'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedSearchServiceResponse extends Response{constructor(_0x45565a){super(![]),this['problem']=_0x45565a;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulViewSearchServiceResponse extends Response{constructor(_0x114b12){super(!![]),this['searchService']=_0x114b12;}['toSuccess'](){return this['searchService'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class SuccessfulListSearchServiceResponse extends Response{constructor(_0x2a7f20){super(!![]),this['searchServices']=_0x2a7f20;}['toSuccess'](){return this['searchServices'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedViewSearchServicesResponse extends Response{constructor(_0x5f4189){super(![]),this['problem']=_0x5f4189;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class FailedViewSearchServiceResponse extends Response{constructor(_0x1f1ae1){super(![]),this['problem']=_0x1f1ae1;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class SuccessfulApiKeyValueResponse extends Response{constructor(_0x515941){super(!![]),this['apiKeyValue']=_0x515941;}['toSuccess'](){return this['apiKeyValue'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class SuccessfulResponse extends Response{constructor(_0x99ddb1){super(!![]),this['obj']=_0x99ddb1;}['toSuccess'](){return this['obj'];}['toProblem'](){throw new Error('Did\x20not\x20fail');}}class FailedResponse extends Response{constructor(_0x9d3a7f){super(![]),this['problem']=_0x9d3a7f;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}class FailedApiKeyValueResponse extends Response{constructor(_0x864247){super(![]),this['problem']=_0x864247;}['toSuccess'](){throw new Error('Not\x20a\x20success');}['toProblem'](){return this['problem'];}}
2
-
3
- var __awaiter$5=undefined&&undefined['__awaiter']||function(_0x5dc25c,_0x558621,_0x14fea1,_0x34672e){function _0x5a4fd6(_0x36d198){return _0x36d198 instanceof _0x14fea1?_0x36d198:new _0x14fea1(function(_0x9a99c7){_0x9a99c7(_0x36d198);});}return new(_0x14fea1||(_0x14fea1=Promise))(function(_0xe32fe4,_0x319541){function _0x47799a(_0x1be21c){try{_0x27e0b9(_0x34672e['next'](_0x1be21c));}catch(_0xac2ef8){_0x319541(_0xac2ef8);}}function _0x320ae2(_0x4d0f81){try{_0x27e0b9(_0x34672e['throw'](_0x4d0f81));}catch(_0x397ff6){_0x319541(_0x397ff6);}}function _0x27e0b9(_0x332518){_0x332518['done']?_0xe32fe4(_0x332518['value']):_0x5a4fd6(_0x332518['value'])['then'](_0x47799a,_0x320ae2);}_0x27e0b9((_0x34672e=_0x34672e['apply'](_0x5dc25c,_0x558621||[]))['next']());});};class AccountService{constructor(_0x2e60cf){this['fetch']=_0x2e60cf;}['get'](_0x2262ef,_0x1607ac){return __awaiter$5(this,void 0,void 0,function*(){const _0xb39ba4='Account/'+_0x2262ef+'/',_0x438b6f=yield this['fetch']['get'](_0xb39ba4,_0x1607ac);try{if(_0x438b6f['status']>0xc7&&_0x438b6f['status']<0x12c){const _0x4aa140=yield _0x438b6f['json']();return new SuccessfulAccountResponse(_0x4aa140);}const _0x2d0de7=yield _0x438b6f['json']();return new FailedAccountResponse(_0x2d0de7);}catch(_0x2be3b){if(_0x2be3b instanceof Error)return new FailedAccountResponse({'detail':_0x2be3b['message'],'title':_0x2be3b['name'],'status':0x1f4,'instance':'','type':''});throw _0x2be3b;}});}}
4
-
5
- var __awaiter$4=undefined&&undefined['__awaiter']||function(_0x1072db,_0x180026,_0xb1736c,_0x24f697){function _0x18c5d7(_0x33e196){return _0x33e196 instanceof _0xb1736c?_0x33e196:new _0xb1736c(function(_0x28c474){_0x28c474(_0x33e196);});}return new(_0xb1736c||(_0xb1736c=Promise))(function(_0x4d4c,_0x15a194){function _0x37855b(_0x121eba){try{_0x1b12b7(_0x24f697['next'](_0x121eba));}catch(_0x4b6282){_0x15a194(_0x4b6282);}}function _0x340e58(_0x5cd7a3){try{_0x1b12b7(_0x24f697['throw'](_0x5cd7a3));}catch(_0x3d403a){_0x15a194(_0x3d403a);}}function _0x1b12b7(_0x2125f0){_0x2125f0['done']?_0x4d4c(_0x2125f0['value']):_0x18c5d7(_0x2125f0['value'])['then'](_0x37855b,_0x340e58);}_0x1b12b7((_0x24f697=_0x24f697['apply'](_0x1072db,_0x180026||[]))['next']());});};class ApiKeyService{constructor(_0x8d7856){this['fetch']=_0x8d7856,this['path']='api-key';}['create'](_0x191e7e,_0xb974ab,_0x32bf2f){return __awaiter$4(this,void 0,void 0,function*(){const _0x37a143={'account_name':_0x191e7e,'api_key_name':_0xb974ab};try{const _0x7b252a=yield this['fetch']['post'](this['path'],_0x32bf2f,_0x37a143);if(_0x7b252a['status']>0xc7&&_0x7b252a['status']<0x12c){const _0x323e63=yield _0x7b252a['json']();return new SuccessfulApiKeyResponse(_0x323e63);}const _0x29f759=yield _0x7b252a['json']();return new FailedApiKeyResponse(_0x29f759);}catch(_0x3004b7){if(_0x3004b7 instanceof Error)return new FailedApiKeyResponse({'detail':_0x3004b7['message'],'title':_0x3004b7['name'],'status':0x1f4,'instance':'','type':''});throw _0x3004b7;}});}['view'](_0x444317,_0x772a5d,_0x4d6d95){return __awaiter$4(this,void 0,void 0,function*(){const _0x494904=this['path']+'/'+_0x444317+'/'+_0x772a5d;try{const _0x388115=yield this['fetch']['get'](_0x494904,_0x4d6d95);if(_0x388115['status']>0xc7&&_0x388115['status']<0x12c){const _0x5ee9b2=yield _0x388115['json']();return new SuccessfulApiKeyValueResponse(_0x5ee9b2);}const _0x21026a=yield _0x388115['json']();return new FailedApiKeyValueResponse(_0x21026a);}catch(_0x410d8c){if(_0x410d8c instanceof Error)return new FailedApiKeyValueResponse({'detail':_0x410d8c['message'],'title':_0x410d8c['name'],'status':0x1f4,'instance':'','type':''});throw _0x410d8c;}});}['delete'](_0x36ab2b,_0x4b03d2,_0x945383){return __awaiter$4(this,void 0,void 0,function*(){const _0x1b98e8=this['path']+'/'+_0x36ab2b+'/'+_0x4b03d2;try{const _0x2d12b1=yield this['fetch']['delete'](_0x1b98e8,_0x945383);if(_0x2d12b1['status']>0xc7&&_0x2d12b1['status']<0x12c)return new SuccessfulResponse({});const _0x29881c=yield _0x2d12b1['json']();return new FailedResponse(_0x29881c);}catch(_0x28f4c4){if(_0x28f4c4 instanceof Error)return new FailedResponse({'detail':_0x28f4c4['message'],'title':_0x28f4c4['name'],'status':0x1f4,'instance':'','type':''});throw _0x28f4c4;}});}}
6
-
7
- var __awaiter$3=undefined&&undefined['__awaiter']||function(_0x11a703,_0xd918b5,_0xe0ec9c,_0x15c1b8){function _0x1f864c(_0x5bc137){return _0x5bc137 instanceof _0xe0ec9c?_0x5bc137:new _0xe0ec9c(function(_0x168bca){_0x168bca(_0x5bc137);});}return new(_0xe0ec9c||(_0xe0ec9c=Promise))(function(_0x5941c8,_0x5044a6){function _0x334458(_0x39c946){try{_0x519df3(_0x15c1b8['next'](_0x39c946));}catch(_0x5bd0b5){_0x5044a6(_0x5bd0b5);}}function _0x3c4f28(_0x41d9be){try{_0x519df3(_0x15c1b8['throw'](_0x41d9be));}catch(_0x1efe8f){_0x5044a6(_0x1efe8f);}}function _0x519df3(_0x372d3f){_0x372d3f['done']?_0x5941c8(_0x372d3f['value']):_0x1f864c(_0x372d3f['value'])['then'](_0x334458,_0x3c4f28);}_0x519df3((_0x15c1b8=_0x15c1b8['apply'](_0x11a703,_0xd918b5||[]))['next']());});};class ListService{constructor(_0xecc096){this['fetch']=_0xecc096;}['add'](_0x2db3be,_0x59e227,_0x5a17e0,_0x34ead9){return __awaiter$3(this,void 0,void 0,function*(){const _0x2a777c='List',_0x2889a6={'account_name':_0x2db3be,'list_name':_0x59e227,'search_service_name':_0x5a17e0};try{const _0xded512=yield this['fetch']['post'](_0x2a777c,_0x34ead9,_0x2889a6);if(_0xded512['status']>0xc7&&_0xded512['status']<0x12c){const _0xfcf411=yield _0xded512['json']();return new SuccessfulListIdentityResponse(_0xfcf411);}const _0x327136=yield _0xded512['json']();return new FailedListIdentityResponse(_0x327136);}catch(_0x5ee5ea){if(_0x5ee5ea instanceof Error)return new FailedListIdentityResponse({'detail':_0x5ee5ea['message'],'title':_0x5ee5ea['name'],'status':0x1f4,'instance':'','type':''});throw _0x5ee5ea;}});}['delete'](_0x514cbb,_0xf84ee8,_0x268ec6){return __awaiter$3(this,void 0,void 0,function*(){const _0x135602='List/'+_0x514cbb+'/'+_0xf84ee8,_0x52e9cf=yield this['fetch']['delete'](_0x135602,_0x268ec6);try{if(_0x52e9cf['status']>0xc7&&_0x52e9cf['status']<0x12c)return new SuccessfulResponse({});const _0xa4a88d=yield _0x52e9cf['json']();return new FailedResponse(_0xa4a88d);}catch(_0x25a462){if(_0x25a462 instanceof Error)return new FailedResponse({'detail':_0x25a462['message'],'title':_0x25a462['name'],'status':0x1f4,'instance':'','type':''});throw _0x25a462;}});}}
8
-
9
- var __awaiter$2=undefined&&undefined['__awaiter']||function(_0x1950d4,_0x115c3e,_0x1bd874,_0x595906){function _0x33f831(_0x5db6b5){return _0x5db6b5 instanceof _0x1bd874?_0x5db6b5:new _0x1bd874(function(_0xdcb173){_0xdcb173(_0x5db6b5);});}return new(_0x1bd874||(_0x1bd874=Promise))(function(_0x11d972,_0x181f2e){function _0x323656(_0x3a7eca){try{_0x15f75d(_0x595906['next'](_0x3a7eca));}catch(_0x10bcca){_0x181f2e(_0x10bcca);}}function _0x225d2e(_0x599696){try{_0x15f75d(_0x595906['throw'](_0x599696));}catch(_0x46ca07){_0x181f2e(_0x46ca07);}}function _0x15f75d(_0x17903a){_0x17903a['done']?_0x11d972(_0x17903a['value']):_0x33f831(_0x17903a['value'])['then'](_0x323656,_0x225d2e);}_0x15f75d((_0x595906=_0x595906['apply'](_0x1950d4,_0x115c3e||[]))['next']());});};class Fetch{constructor(_0x4ecfb8){this['baseUri']=_0x4ecfb8,this['getUrl']=_0x437bd9=>{return _0x437bd9['startsWith']('/')&&(_0x437bd9=_0x437bd9['replace']('/','')),''+this['baseUri']+_0x437bd9;},!_0x4ecfb8['endsWith']('/')&&(_0x4ecfb8=_0x4ecfb8+'/');}['get'](_0xddc773,_0x27a809){return __awaiter$2(this,void 0,void 0,function*(){const _0xc071c6=this['getUrl'](_0xddc773);return yield fetch(_0xc071c6,{'method':'GET','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x27a809}});});}['post'](_0xbbc82f,_0x5b085c,_0x2d45de){return __awaiter$2(this,void 0,void 0,function*(){const _0x4fddfe=this['getUrl'](_0xbbc82f);return yield fetch(_0x4fddfe,{'method':'POST','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x5b085c},'body':_0x2d45de?JSON['stringify'](_0x2d45de):null});});}['PostNoAuth'](_0x2d3528,_0x2c01e1){return __awaiter$2(this,void 0,void 0,function*(){const _0x1e7910=this['getUrl'](_0x2d3528);return yield fetch(_0x1e7910,{'method':'POST','headers':{'Content-Type':'application/json'},'body':_0x2c01e1?JSON['stringify'](_0x2c01e1):null});});}['put'](_0x25cd07,_0x18cb5d,_0x28b70d){return __awaiter$2(this,void 0,void 0,function*(){const _0x9aacde=this['getUrl'](_0x25cd07);return yield fetch(_0x9aacde,{'method':'PUT','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x18cb5d},'body':_0x28b70d?JSON['stringify'](_0x28b70d):null});});}['delete'](_0x5e6515,_0x57f1d8){return __awaiter$2(this,void 0,void 0,function*(){const _0x2114cc=this['getUrl'](_0x5e6515);return yield fetch(_0x2114cc,{'method':'DELETE','headers':{'Content-Type':'application/json','Authorization':'Bearer\x20'+_0x57f1d8}});});}}
10
-
11
- var __awaiter$1=undefined&&undefined['__awaiter']||function(_0x2616cb,_0x512df2,_0xf679c1,_0x930653){function _0x469b71(_0x378b85){return _0x378b85 instanceof _0xf679c1?_0x378b85:new _0xf679c1(function(_0xc73ec3){_0xc73ec3(_0x378b85);});}return new(_0xf679c1||(_0xf679c1=Promise))(function(_0x42a295,_0x4e2df4){function _0x462c8e(_0x53c834){try{_0x5b11b2(_0x930653['next'](_0x53c834));}catch(_0x4dac94){_0x4e2df4(_0x4dac94);}}function _0x2c28aa(_0x113741){try{_0x5b11b2(_0x930653['throw'](_0x113741));}catch(_0x29258d){_0x4e2df4(_0x29258d);}}function _0x5b11b2(_0x355d59){_0x355d59['done']?_0x42a295(_0x355d59['value']):_0x469b71(_0x355d59['value'])['then'](_0x462c8e,_0x2c28aa);}_0x5b11b2((_0x930653=_0x930653['apply'](_0x2616cb,_0x512df2||[]))['next']());});};class SearchServersService{constructor(_0x31a2aa){this['fetch']=_0x31a2aa,this['path']='search-services';}['create'](_0x38d142,_0x24e2b1,_0x159b49,_0x2a3b8e,_0xf5f9b5,_0x2d841a,_0x2f294a,_0x59e7be){return __awaiter$1(this,void 0,void 0,function*(){const _0x30e25c={'account_name':_0x38d142,'search_service_name':_0x24e2b1,'endpoint':_0x159b49,'key':_0x2a3b8e,'country':_0xf5f9b5,'provider':_0x2d841a,'index_name':_0x2f294a};try{const _0x5b659d=yield this['fetch']['post'](this['path'],_0x59e7be,_0x30e25c);if(_0x5b659d['status']>0xc7&&_0x5b659d['status']<0x12c){const _0x39540d=yield _0x5b659d['json']();return new SuccessfulSearchServiceResponse(_0x39540d);}const _0x43efc5=yield _0x5b659d['json']();return new FailedSearchServiceResponse(_0x43efc5);}catch(_0x44646a){if(_0x44646a instanceof Error)return new FailedSearchServiceResponse({'detail':_0x44646a['message'],'title':_0x44646a['name'],'status':0x1f4,'instance':'','type':''});throw _0x44646a;}});}['delete'](_0x8d44e3,_0xf0b5cd,_0x291e64){return __awaiter$1(this,void 0,void 0,function*(){const _0x3c7b47=this['path']+'/'+_0x8d44e3+'/'+_0xf0b5cd;try{const _0x36f641=yield this['fetch']['delete'](_0x3c7b47,_0x291e64);if(_0x36f641['status']>0xc7&&_0x36f641['status']<0x12c)return new SuccessfulResponse({});const _0x4587c4=yield _0x36f641['json']();return new FailedResponse(_0x4587c4);}catch(_0x1f70e7){if(_0x1f70e7 instanceof Error)return new FailedResponse({'detail':_0x1f70e7['message'],'title':_0x1f70e7['name'],'status':0x1f4,'instance':'','type':''});throw _0x1f70e7;}});}['view'](_0x5479a6,_0x28caa1,_0x45c618){return __awaiter$1(this,void 0,void 0,function*(){const _0x58fc63=this['path']+'/'+_0x5479a6+'/'+_0x28caa1;try{const _0x460a4a=yield this['fetch']['get'](_0x58fc63,_0x45c618);if(_0x460a4a['status']>0xc7&&_0x460a4a['status']<0x12c){const _0x380a35=yield _0x460a4a['json']();return new SuccessfulViewSearchServiceResponse(_0x380a35);}const _0x21a29b=yield _0x460a4a['json']();return new FailedViewSearchServiceResponse(_0x21a29b);}catch(_0x5e9ac4){if(_0x5e9ac4 instanceof Error)return new FailedViewSearchServiceResponse({'detail':_0x5e9ac4['message'],'title':_0x5e9ac4['name'],'status':0x1f4,'instance':'','type':''});throw _0x5e9ac4;}});}['edit'](_0x48e433,_0x5b2a7f,_0x278a27,_0x56361d,_0x362c42,_0x3093f0){return __awaiter$1(this,void 0,void 0,function*(){const _0x3062a0={'account_name':_0x48e433,'search_service_name':_0x5b2a7f,'new_search_service_name':_0x278a27,'key':_0x56361d,'country':_0x362c42};try{const _0x21e322=yield this['fetch']['put'](this['path'],_0x3093f0,_0x3062a0);if(_0x21e322['status']>0xc7&&_0x21e322['status']<0x12c){const _0x50a417=yield _0x21e322['json']();return new SuccessfulSearchServiceResponse(_0x50a417);}const _0x2bf822=yield _0x21e322['json']();return new FailedSearchServiceResponse(_0x2bf822);}catch(_0x9ed6ff){if(_0x9ed6ff instanceof Error)return new FailedSearchServiceResponse({'detail':_0x9ed6ff['message'],'title':_0x9ed6ff['name'],'status':0x1f4,'instance':'','type':''});throw _0x9ed6ff;}});}['list'](_0x337d40,_0x1081da){return __awaiter$1(this,void 0,void 0,function*(){const _0x110b19=this['path']+'/'+_0x337d40;try{const _0x37dbf9=yield this['fetch']['get'](_0x110b19,_0x1081da);if(_0x37dbf9['status']>0xc7&&_0x37dbf9['status']<0x12c){const _0x12ff4a=yield _0x37dbf9['json']();return new SuccessfulListSearchServiceResponse(_0x12ff4a);}const _0x1c500c=yield _0x37dbf9['json']();return new FailedViewSearchServicesResponse(_0x1c500c);}catch(_0x2438d6){if(_0x2438d6 instanceof Error)return new FailedViewSearchServicesResponse({'detail':_0x2438d6['message'],'title':_0x2438d6['name'],'status':0x1f4,'instance':'','type':''});throw _0x2438d6;}});}}
12
-
13
- var __awaiter=undefined&&undefined['__awaiter']||function(_0xf3f2b7,_0x1b26f7,_0x188a9a,_0x41d92a){function _0x44c6b0(_0x3cfd64){return _0x3cfd64 instanceof _0x188a9a?_0x3cfd64:new _0x188a9a(function(_0x187d7c){_0x187d7c(_0x3cfd64);});}return new(_0x188a9a||(_0x188a9a=Promise))(function(_0x354f39,_0x596c5f){function _0x296a48(_0x5bb362){try{_0x532961(_0x41d92a['next'](_0x5bb362));}catch(_0x21fe18){_0x596c5f(_0x21fe18);}}function _0x3b6b9e(_0x8552ab){try{_0x532961(_0x41d92a['throw'](_0x8552ab));}catch(_0x4ae7e9){_0x596c5f(_0x4ae7e9);}}function _0x532961(_0x2b4a75){_0x2b4a75['done']?_0x354f39(_0x2b4a75['value']):_0x44c6b0(_0x2b4a75['value'])['then'](_0x296a48,_0x3b6b9e);}_0x532961((_0x41d92a=_0x41d92a['apply'](_0xf3f2b7,_0x1b26f7||[]))['next']());});};class AdminClient{constructor(_0x1c5bda='https://admin.searchability.dev/'){var _0x31a9c6=new Fetch(_0x1c5bda);this['Accounts']=new AccountService(_0x31a9c6),this['Lists']=new ListService(_0x31a9c6),this['ApiKeys']=new ApiKeyService(_0x31a9c6),this['SearchServices']=new SearchServersService(_0x31a9c6);}}class AuthClient{constructor(_0x490d4e='https://auth.searchability.dev/'){this['fetch']=new Fetch(_0x490d4e);}['login'](_0x389127){return __awaiter(this,void 0,void 0,function*(){const _0x5d0cea='login/'+_0x389127;try{const _0x37d9fd=yield yield fetch(_0x5d0cea);if(_0x37d9fd['status']>0xc7&&_0x37d9fd['status']<0x12c){const _0x4a4548=yield _0x37d9fd['json']();return new SuccessfulAuthResponse(_0x4a4548);}const _0x431465=yield _0x37d9fd['json']();return new FailedAuthResponse(_0x431465);}catch(_0x3377a7){if(_0x3377a7 instanceof Error)return new FailedAuthResponse({'detail':_0x3377a7['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x3377a7;}});}['refresh'](_0xc4f97d){return __awaiter(this,void 0,void 0,function*(){const _0x45ef5f='refresh',_0x55c4e6={'refresh_token':_0xc4f97d};try{const _0x564290=yield this['fetch']['PostNoAuth'](_0x45ef5f,_0x55c4e6);if(_0x564290['status']>0xc7&&_0x564290['status']<0x12c){const _0x37df4a=yield _0x564290['json']();return new SuccessfulAuthResponse(_0x37df4a);}const _0x58fe51=yield _0x564290['json']();return new FailedAuthResponse(_0x58fe51);}catch(_0x32685d){if(_0x32685d instanceof Error)return new FailedAuthResponse({'detail':_0x32685d['message'],'title':'','status':0x1f4,'instance':'','type':''});throw _0x32685d;}});}['getTokenStatus'](_0x2cbe6e){if(Date['now']()<_0x2cbe6e['access_expires'])return TokenStatus['Ok'];if(Date['now']()<_0x2cbe6e['refresh_expires'])return TokenStatus['Refresh'];return TokenStatus['Expired'];}}
14
-
15
- export { AdminClient, AuthClient, TokenStatus, Tokens };