@regulaforensics/facesdk-webclient 8.3.652-rc → 8.3.656-nightly
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +8 -8
- package/dist/index.js +1619 -1425
- package/package.json +2 -2
package/dist/index.cjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});function ut(e,t){return function(){return e.apply(t,arguments)}}const{toString:Zt}=Object.prototype,{getPrototypeOf:xe}=Object,{iterator:Oe,toStringTag:pt}=Symbol,_e=(e=>t=>{const r=Zt.call(t);return e[r]||(e[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),G=e=>(e=e.toLowerCase(),t=>_e(t)===e),me=e=>t=>typeof t===e,{isArray:K}=Array,Z=me("undefined");function re(e){return e!==null&&!Z(e)&&e.constructor!==null&&!Z(e.constructor)&&N(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const ht=G("ArrayBuffer");function Kt(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&ht(e.buffer),t}const Qt=me("string"),N=me("function"),ft=me("number"),se=e=>e!==null&&typeof e=="object",er=e=>e===!0||e===!1,pe=e=>{if(_e(e)!=="object")return!1;const t=xe(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(pt in e)&&!(Oe in e)},tr=e=>{if(!se(e)||re(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch{return!1}},rr=G("Date"),sr=G("File"),nr=e=>!!(e&&typeof e.uri<"u"),or=e=>e&&typeof e.getParts<"u",ar=G("Blob"),ir=G("FileList"),lr=e=>se(e)&&N(e.pipe);function cr(){return typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{}}const ze=cr(),We=typeof ze.FormData<"u"?ze.FormData:void 0,dr=e=>{let t;return e&&(We&&e instanceof We||N(e.append)&&((t=_e(e))==="formdata"||t==="object"&&N(e.toString)&&e.toString()==="[object FormData]"))},ur=G("URLSearchParams"),[pr,hr,fr,Er]=["ReadableStream","Request","Response","Headers"].map(G),Ar=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function ne(e,t,{allOwnKeys:r=!1}={}){if(e===null||typeof e>"u")return;let s,n;if(typeof e!="object"&&(e=[e]),K(e))for(s=0,n=e.length;s<n;s++)t.call(null,e[s],s,e);else{if(re(e))return;const o=r?Object.getOwnPropertyNames(e):Object.keys(e),a=o.length;let i;for(s=0;s<a;s++)i=o[s],t.call(null,e[i],i,e)}}function Et(e,t){if(re(e))return null;t=t.toLowerCase();const r=Object.keys(e);let s=r.length,n;for(;s-- >0;)if(n=r[s],t===n.toLowerCase())return n;return null}const z=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,At=e=>!Z(e)&&e!==z;function Le(){const{caseless:e,skipUndefined:t}=At(this)&&this||{},r={},s=(n,o)=>{if(o==="__proto__"||o==="constructor"||o==="prototype")return;const a=e&&Et(r,o)||o;pe(r[a])&&pe(n)?r[a]=Le(r[a],n):pe(n)?r[a]=Le({},n):K(n)?r[a]=n.slice():(!t||!Z(n))&&(r[a]=n)};for(let n=0,o=arguments.length;n<o;n++)arguments[n]&&ne(arguments[n],s);return r}const Or=(e,t,r,{allOwnKeys:s}={})=>(ne(t,(n,o)=>{r&&N(n)?Object.defineProperty(e,o,{value:ut(n,r),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(e,o,{value:n,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:s}),e),_r=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),mr=(e,t,r,s)=>{e.prototype=Object.create(t.prototype,s),Object.defineProperty(e.prototype,"constructor",{value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,"super",{value:t.prototype}),r&&Object.assign(e.prototype,r)},Rr=(e,t,r,s)=>{let n,o,a;const i={};if(t=t||{},e==null)return t;do{for(n=Object.getOwnPropertyNames(e),o=n.length;o-- >0;)a=n[o],(!s||s(a,e,t))&&!i[a]&&(t[a]=e[a],i[a]=!0);e=r!==!1&&xe(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t},Tr=(e,t,r)=>{e=String(e),(r===void 0||r>e.length)&&(r=e.length),r-=t.length;const s=e.indexOf(t,r);return s!==-1&&s===r},Pr=e=>{if(!e)return null;if(K(e))return e;let t=e.length;if(!ft(t))return null;const r=new Array(t);for(;t-- >0;)r[t]=e[t];return r},Ir=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&xe(Uint8Array)),Sr=(e,t)=>{const s=(e&&e[Oe]).call(e);let n;for(;(n=s.next())&&!n.done;){const o=n.value;t.call(e,o[0],o[1])}},br=(e,t)=>{let r;const s=[];for(;(r=e.exec(t))!==null;)s.push(r);return s},wr=G("HTMLFormElement"),yr=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(r,s,n){return s.toUpperCase()+n}),Ye=(({hasOwnProperty:e})=>(t,r)=>e.call(t,r))(Object.prototype),Cr=G("RegExp"),Ot=(e,t)=>{const r=Object.getOwnPropertyDescriptors(e),s={};ne(r,(n,o)=>{let a;(a=t(n,o,e))!==!1&&(s[o]=a||n)}),Object.defineProperties(e,s)},Lr=e=>{Ot(e,(t,r)=>{if(N(e)&&["arguments","caller","callee"].indexOf(r)!==-1)return!1;const s=e[r];if(N(s)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")})}})},gr=(e,t)=>{const r={},s=n=>{n.forEach(o=>{r[o]=!0})};return K(e)?s(e):s(String(e).split(t)),r},Vr=()=>{},Nr=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function Ur(e){return!!(e&&N(e.append)&&e[pt]==="FormData"&&e[Oe])}const xr=e=>{const t=new Array(10),r=(s,n)=>{if(se(s)){if(t.indexOf(s)>=0)return;if(re(s))return s;if(!("toJSON"in s)){t[n]=s;const o=K(s)?[]:{};return ne(s,(a,i)=>{const l=r(a,n+1);!Z(l)&&(o[i]=l)}),t[n]=void 0,o}}return s};return r(e,0)},Dr=G("AsyncFunction"),Br=e=>e&&(se(e)||N(e))&&N(e.then)&&N(e.catch),_t=((e,t)=>e?setImmediate:t?((r,s)=>(z.addEventListener("message",({source:n,data:o})=>{n===z&&o===r&&s.length&&s.shift()()},!1),n=>{s.push(n),z.postMessage(r,"*")}))(`axios@${Math.random()}`,[]):r=>setTimeout(r))(typeof setImmediate=="function",N(z.postMessage)),Hr=typeof queueMicrotask<"u"?queueMicrotask.bind(z):typeof process<"u"&&process.nextTick||_t,Gr=e=>e!=null&&N(e[Oe]),u={isArray:K,isArrayBuffer:ht,isBuffer:re,isFormData:dr,isArrayBufferView:Kt,isString:Qt,isNumber:ft,isBoolean:er,isObject:se,isPlainObject:pe,isEmptyObject:tr,isReadableStream:pr,isRequest:hr,isResponse:fr,isHeaders:Er,isUndefined:Z,isDate:rr,isFile:sr,isReactNativeBlob:nr,isReactNative:or,isBlob:ar,isRegExp:Cr,isFunction:N,isStream:lr,isURLSearchParams:ur,isTypedArray:Ir,isFileList:ir,forEach:ne,merge:Le,extend:Or,trim:Ar,stripBOM:_r,inherits:mr,toFlatObject:Rr,kindOf:_e,kindOfTest:G,endsWith:Tr,toArray:Pr,forEachEntry:Sr,matchAll:br,isHTMLForm:wr,hasOwnProperty:Ye,hasOwnProp:Ye,reduceDescriptors:Ot,freezeMethods:Lr,toObjectSet:gr,toCamelCase:yr,noop:Vr,toFiniteNumber:Nr,findKey:Et,global:z,isContextDefined:At,isSpecCompliantForm:Ur,toJSONObject:xr,isAsyncFn:Dr,isThenable:Br,setImmediate:_t,asap:Hr,isIterable:Gr};let A=class mt extends Error{static from(t,r,s,n,o,a){const i=new mt(t.message,r||t.code,s,n,o);return i.cause=t,i.name=t.name,t.status!=null&&i.status==null&&(i.status=t.status),a&&Object.assign(i,a),i}constructor(t,r,s,n,o){super(t),Object.defineProperty(this,"message",{value:t,enumerable:!0,writable:!0,configurable:!0}),this.name="AxiosError",this.isAxiosError=!0,r&&(this.code=r),s&&(this.config=s),n&&(this.request=n),o&&(this.response=o,this.status=o.status)}toJSON(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:u.toJSONObject(this.config),code:this.code,status:this.status}}};A.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE";A.ERR_BAD_OPTION="ERR_BAD_OPTION";A.ECONNABORTED="ECONNABORTED";A.ETIMEDOUT="ETIMEDOUT";A.ERR_NETWORK="ERR_NETWORK";A.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS";A.ERR_DEPRECATED="ERR_DEPRECATED";A.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE";A.ERR_BAD_REQUEST="ERR_BAD_REQUEST";A.ERR_CANCELED="ERR_CANCELED";A.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT";A.ERR_INVALID_URL="ERR_INVALID_URL";const Mr=null;function ge(e){return u.isPlainObject(e)||u.isArray(e)}function Rt(e){return u.endsWith(e,"[]")?e.slice(0,-2):e}function Se(e,t,r){return e?e.concat(t).map(function(n,o){return n=Rt(n),!r&&o?"["+n+"]":n}).join(r?".":""):t}function vr(e){return u.isArray(e)&&!e.some(ge)}const jr=u.toFlatObject(u,{},null,function(t){return/^is[A-Z]/.test(t)});function Re(e,t,r){if(!u.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,r=u.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(E,f){return!u.isUndefined(f[E])});const s=r.metaTokens,n=r.visitor||d,o=r.dots,a=r.indexes,l=(r.Blob||typeof Blob<"u"&&Blob)&&u.isSpecCompliantForm(t);if(!u.isFunction(n))throw new TypeError("visitor must be a function");function c(h){if(h===null)return"";if(u.isDate(h))return h.toISOString();if(u.isBoolean(h))return h.toString();if(!l&&u.isBlob(h))throw new A("Blob is not supported. Use a Buffer instead.");return u.isArrayBuffer(h)||u.isTypedArray(h)?l&&typeof Blob=="function"?new Blob([h]):Buffer.from(h):h}function d(h,E,f){let w=h;if(u.isReactNative(t)&&u.isReactNativeBlob(h))return t.append(Se(f,E,o),c(h)),!1;if(h&&!f&&typeof h=="object"){if(u.endsWith(E,"{}"))E=s?E:E.slice(0,-2),h=JSON.stringify(h);else if(u.isArray(h)&&vr(h)||(u.isFileList(h)||u.endsWith(E,"[]"))&&(w=u.toArray(h)))return E=Rt(E),w.forEach(function(y,g){!(u.isUndefined(y)||y===null)&&t.append(a===!0?Se([E],g,o):a===null?E:E+"[]",c(y))}),!1}return ge(h)?!0:(t.append(Se(f,E,o),c(h)),!1)}const p=[],_=Object.assign(jr,{defaultVisitor:d,convertValue:c,isVisitable:ge});function C(h,E){if(!u.isUndefined(h)){if(p.indexOf(h)!==-1)throw Error("Circular reference detected in "+E.join("."));p.push(h),u.forEach(h,function(w,x){(!(u.isUndefined(w)||w===null)&&n.call(t,w,u.isString(x)?x.trim():x,E,_))===!0&&C(w,E?E.concat(x):[x])}),p.pop()}}if(!u.isObject(e))throw new TypeError("data must be an object");return C(e),t}function Xe(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(s){return t[s]})}function De(e,t){this._pairs=[],e&&Re(e,this,t)}const Tt=De.prototype;Tt.append=function(t,r){this._pairs.push([t,r])};Tt.toString=function(t){const r=t?function(s){return t.call(this,s,Xe)}:Xe;return this._pairs.map(function(n){return r(n[0])+"="+r(n[1])},"").join("&")};function Fr(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function Pt(e,t,r){if(!t)return e;const s=r&&r.encode||Fr,n=u.isFunction(r)?{serialize:r}:r,o=n&&n.serialize;let a;if(o?a=o(t,n):a=u.isURLSearchParams(t)?t.toString():new De(t,n).toString(s),a){const i=e.indexOf("#");i!==-1&&(e=e.slice(0,i)),e+=(e.indexOf("?")===-1?"?":"&")+a}return e}class Je{constructor(){this.handlers=[]}use(t,r,s){return this.handlers.push({fulfilled:t,rejected:r,synchronous:s?s.synchronous:!1,runWhen:s?s.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){u.forEach(this.handlers,function(s){s!==null&&t(s)})}}const Be={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},kr=typeof URLSearchParams<"u"?URLSearchParams:De,qr=typeof FormData<"u"?FormData:null,$r=typeof Blob<"u"?Blob:null,zr={isBrowser:!0,classes:{URLSearchParams:kr,FormData:qr,Blob:$r},protocols:["http","https","file","blob","url","data"]},He=typeof window<"u"&&typeof document<"u",Ve=typeof navigator=="object"&&navigator||void 0,Wr=He&&(!Ve||["ReactNative","NativeScript","NS"].indexOf(Ve.product)<0),Yr=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",Xr=He&&window.location.href||"http://localhost",Jr=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:He,hasStandardBrowserEnv:Wr,hasStandardBrowserWebWorkerEnv:Yr,navigator:Ve,origin:Xr},Symbol.toStringTag,{value:"Module"})),L={...Jr,...zr};function Zr(e,t){return Re(e,new L.classes.URLSearchParams,{visitor:function(r,s,n,o){return L.isNode&&u.isBuffer(r)?(this.append(s,r.toString("base64")),!1):o.defaultVisitor.apply(this,arguments)},...t})}function Kr(e){return u.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function Qr(e){const t={},r=Object.keys(e);let s;const n=r.length;let o;for(s=0;s<n;s++)o=r[s],t[o]=e[o];return t}function It(e){function t(r,s,n,o){let a=r[o++];if(a==="__proto__")return!0;const i=Number.isFinite(+a),l=o>=r.length;return a=!a&&u.isArray(n)?n.length:a,l?(u.hasOwnProp(n,a)?n[a]=[n[a],s]:n[a]=s,!i):((!n[a]||!u.isObject(n[a]))&&(n[a]=[]),t(r,s,n[a],o)&&u.isArray(n[a])&&(n[a]=Qr(n[a])),!i)}if(u.isFormData(e)&&u.isFunction(e.entries)){const r={};return u.forEachEntry(e,(s,n)=>{t(Kr(s),n,r,0)}),r}return null}function es(e,t,r){if(u.isString(e))try{return(t||JSON.parse)(e),u.trim(e)}catch(s){if(s.name!=="SyntaxError")throw s}return(r||JSON.stringify)(e)}const oe={transitional:Be,adapter:["xhr","http","fetch"],transformRequest:[function(t,r){const s=r.getContentType()||"",n=s.indexOf("application/json")>-1,o=u.isObject(t);if(o&&u.isHTMLForm(t)&&(t=new FormData(t)),u.isFormData(t))return n?JSON.stringify(It(t)):t;if(u.isArrayBuffer(t)||u.isBuffer(t)||u.isStream(t)||u.isFile(t)||u.isBlob(t)||u.isReadableStream(t))return t;if(u.isArrayBufferView(t))return t.buffer;if(u.isURLSearchParams(t))return r.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let i;if(o){if(s.indexOf("application/x-www-form-urlencoded")>-1)return Zr(t,this.formSerializer).toString();if((i=u.isFileList(t))||s.indexOf("multipart/form-data")>-1){const l=this.env&&this.env.FormData;return Re(i?{"files[]":t}:t,l&&new l,this.formSerializer)}}return o||n?(r.setContentType("application/json",!1),es(t)):t}],transformResponse:[function(t){const r=this.transitional||oe.transitional,s=r&&r.forcedJSONParsing,n=this.responseType==="json";if(u.isResponse(t)||u.isReadableStream(t))return t;if(t&&u.isString(t)&&(s&&!this.responseType||n)){const a=!(r&&r.silentJSONParsing)&&n;try{return JSON.parse(t,this.parseReviver)}catch(i){if(a)throw i.name==="SyntaxError"?A.from(i,A.ERR_BAD_RESPONSE,this,null,this.response):i}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:L.classes.FormData,Blob:L.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};u.forEach(["delete","get","head","post","put","patch"],e=>{oe.headers[e]={}});const ts=u.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),rs=e=>{const t={};let r,s,n;return e&&e.split(`
|
|
2
|
-
`).forEach(function(a){
|
|
3
|
-
`)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...r){const s=new this(t);return r.forEach(n=>s.set(n)),s}static accessor(t){const s=(this[Ze]=this[Ze]={accessors:{}}).accessors,n=this.prototype;function o(a){const i=te(a);s[i]||(ls(n,a),s[i]=!0)}return u.isArray(t)?t.forEach(o):o(t),this}};U.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);u.reduceDescriptors(U.prototype,({value:e},t)=>{let r=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(s){this[r]=s}}});u.freezeMethods(U);function we(e,t){const r=this||oe,s=t||r,n=U.from(s.headers);let o=s.data;return u.forEach(e,function(i){o=i.call(r,o,n.normalize(),t?t.status:void 0)}),n.normalize(),o}function bt(e){return!!(e&&e.__CANCEL__)}let ae=class extends A{constructor(t,r,s){super(t??"canceled",A.ERR_CANCELED,r,s),this.name="CanceledError",this.__CANCEL__=!0}};function wt(e,t,r){const s=r.config.validateStatus;!r.status||!s||s(r.status)?e(r):t(new A("Request failed with status code "+r.status,[A.ERR_BAD_REQUEST,A.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r))}function cs(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function ds(e,t){e=e||10;const r=new Array(e),s=new Array(e);let n=0,o=0,a;return t=t!==void 0?t:1e3,function(l){const c=Date.now(),d=s[o];a||(a=c),r[n]=l,s[n]=c;let p=o,_=0;for(;p!==n;)_+=r[p++],p=p%e;if(n=(n+1)%e,n===o&&(o=(o+1)%e),c-a<t)return;const C=d&&c-d;return C?Math.round(_*1e3/C):void 0}}function us(e,t){let r=0,s=1e3/t,n,o;const a=(c,d=Date.now())=>{r=d,n=null,o&&(clearTimeout(o),o=null),e(...c)};return[(...c)=>{const d=Date.now(),p=d-r;p>=s?a(c,d):(n=c,o||(o=setTimeout(()=>{o=null,a(n)},s-p)))},()=>n&&a(n)]}const Ee=(e,t,r=3)=>{let s=0;const n=ds(50,250);return us(o=>{const a=o.loaded,i=o.lengthComputable?o.total:void 0,l=a-s,c=n(l),d=a<=i;s=a;const p={loaded:a,total:i,progress:i?a/i:void 0,bytes:l,rate:c||void 0,estimated:c&&i&&d?(i-a)/c:void 0,event:o,lengthComputable:i!=null,[t?"download":"upload"]:!0};e(p)},r)},Ke=(e,t)=>{const r=e!=null;return[s=>t[0]({lengthComputable:r,total:e,loaded:s}),t[1]]},Qe=e=>(...t)=>u.asap(()=>e(...t)),ps=L.hasStandardBrowserEnv?((e,t)=>r=>(r=new URL(r,L.origin),e.protocol===r.protocol&&e.host===r.host&&(t||e.port===r.port)))(new URL(L.origin),L.navigator&&/(msie|trident)/i.test(L.navigator.userAgent)):()=>!0,hs=L.hasStandardBrowserEnv?{write(e,t,r,s,n,o,a){if(typeof document>"u")return;const i=[`${e}=${encodeURIComponent(t)}`];u.isNumber(r)&&i.push(`expires=${new Date(r).toUTCString()}`),u.isString(s)&&i.push(`path=${s}`),u.isString(n)&&i.push(`domain=${n}`),o===!0&&i.push("secure"),u.isString(a)&&i.push(`SameSite=${a}`),document.cookie=i.join("; ")},read(e){if(typeof document>"u")return null;const t=document.cookie.match(new RegExp("(?:^|; )"+e+"=([^;]*)"));return t?decodeURIComponent(t[1]):null},remove(e){this.write(e,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function fs(e){return typeof e!="string"?!1:/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function Es(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function yt(e,t,r){let s=!fs(t);return e&&(s||r==!1)?Es(e,t):t}const et=e=>e instanceof U?{...e}:e;function Y(e,t){t=t||{};const r={};function s(c,d,p,_){return u.isPlainObject(c)&&u.isPlainObject(d)?u.merge.call({caseless:_},c,d):u.isPlainObject(d)?u.merge({},d):u.isArray(d)?d.slice():d}function n(c,d,p,_){if(u.isUndefined(d)){if(!u.isUndefined(c))return s(void 0,c,p,_)}else return s(c,d,p,_)}function o(c,d){if(!u.isUndefined(d))return s(void 0,d)}function a(c,d){if(u.isUndefined(d)){if(!u.isUndefined(c))return s(void 0,c)}else return s(void 0,d)}function i(c,d,p){if(p in t)return s(c,d);if(p in e)return s(void 0,c)}const l={url:o,method:o,data:o,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,withXSRFToken:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,responseEncoding:a,validateStatus:i,headers:(c,d,p)=>n(et(c),et(d),p,!0)};return u.forEach(Object.keys({...e,...t}),function(d){if(d==="__proto__"||d==="constructor"||d==="prototype")return;const p=u.hasOwnProp(l,d)?l[d]:n,_=p(e[d],t[d],d);u.isUndefined(_)&&p!==i||(r[d]=_)}),r}const Ct=e=>{const t=Y({},e);let{data:r,withXSRFToken:s,xsrfHeaderName:n,xsrfCookieName:o,headers:a,auth:i}=t;if(t.headers=a=U.from(a),t.url=Pt(yt(t.baseURL,t.url,t.allowAbsoluteUrls),e.params,e.paramsSerializer),i&&a.set("Authorization","Basic "+btoa((i.username||"")+":"+(i.password?unescape(encodeURIComponent(i.password)):""))),u.isFormData(r)){if(L.hasStandardBrowserEnv||L.hasStandardBrowserWebWorkerEnv)a.setContentType(void 0);else if(u.isFunction(r.getHeaders)){const l=r.getHeaders(),c=["content-type","content-length"];Object.entries(l).forEach(([d,p])=>{c.includes(d.toLowerCase())&&a.set(d,p)})}}if(L.hasStandardBrowserEnv&&(s&&u.isFunction(s)&&(s=s(t)),s||s!==!1&&ps(t.url))){const l=n&&o&&hs.read(o);l&&a.set(n,l)}return t},As=typeof XMLHttpRequest<"u",Os=As&&function(e){return new Promise(function(r,s){const n=Ct(e);let o=n.data;const a=U.from(n.headers).normalize();let{responseType:i,onUploadProgress:l,onDownloadProgress:c}=n,d,p,_,C,h;function E(){C&&C(),h&&h(),n.cancelToken&&n.cancelToken.unsubscribe(d),n.signal&&n.signal.removeEventListener("abort",d)}let f=new XMLHttpRequest;f.open(n.method.toUpperCase(),n.url,!0),f.timeout=n.timeout;function w(){if(!f)return;const y=U.from("getAllResponseHeaders"in f&&f.getAllResponseHeaders()),H={data:!i||i==="text"||i==="json"?f.responseText:f.response,status:f.status,statusText:f.statusText,headers:y,config:e,request:f};wt(function(D){r(D),E()},function(D){s(D),E()},H),f=null}"onloadend"in f?f.onloadend=w:f.onreadystatechange=function(){!f||f.readyState!==4||f.status===0&&!(f.responseURL&&f.responseURL.indexOf("file:")===0)||setTimeout(w)},f.onabort=function(){f&&(s(new A("Request aborted",A.ECONNABORTED,e,f)),f=null)},f.onerror=function(g){const H=g&&g.message?g.message:"Network Error",k=new A(H,A.ERR_NETWORK,e,f);k.event=g||null,s(k),f=null},f.ontimeout=function(){let g=n.timeout?"timeout of "+n.timeout+"ms exceeded":"timeout exceeded";const H=n.transitional||Be;n.timeoutErrorMessage&&(g=n.timeoutErrorMessage),s(new A(g,H.clarifyTimeoutError?A.ETIMEDOUT:A.ECONNABORTED,e,f)),f=null},o===void 0&&a.setContentType(null),"setRequestHeader"in f&&u.forEach(a.toJSON(),function(g,H){f.setRequestHeader(H,g)}),u.isUndefined(n.withCredentials)||(f.withCredentials=!!n.withCredentials),i&&i!=="json"&&(f.responseType=n.responseType),c&&([_,h]=Ee(c,!0),f.addEventListener("progress",_)),l&&f.upload&&([p,C]=Ee(l),f.upload.addEventListener("progress",p),f.upload.addEventListener("loadend",C)),(n.cancelToken||n.signal)&&(d=y=>{f&&(s(!y||y.type?new ae(null,e,f):y),f.abort(),f=null)},n.cancelToken&&n.cancelToken.subscribe(d),n.signal&&(n.signal.aborted?d():n.signal.addEventListener("abort",d)));const x=cs(n.url);if(x&&L.protocols.indexOf(x)===-1){s(new A("Unsupported protocol "+x+":",A.ERR_BAD_REQUEST,e));return}f.send(o||null)})},_s=(e,t)=>{const{length:r}=e=e?e.filter(Boolean):[];if(t||r){let s=new AbortController,n;const o=function(c){if(!n){n=!0,i();const d=c instanceof Error?c:this.reason;s.abort(d instanceof A?d:new ae(d instanceof Error?d.message:d))}};let a=t&&setTimeout(()=>{a=null,o(new A(`timeout of ${t}ms exceeded`,A.ETIMEDOUT))},t);const i=()=>{e&&(a&&clearTimeout(a),a=null,e.forEach(c=>{c.unsubscribe?c.unsubscribe(o):c.removeEventListener("abort",o)}),e=null)};e.forEach(c=>c.addEventListener("abort",o));const{signal:l}=s;return l.unsubscribe=()=>u.asap(i),l}},ms=function*(e,t){let r=e.byteLength;if(r<t){yield e;return}let s=0,n;for(;s<r;)n=s+t,yield e.slice(s,n),s=n},Rs=async function*(e,t){for await(const r of Ts(e))yield*ms(r,t)},Ts=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}const t=e.getReader();try{for(;;){const{done:r,value:s}=await t.read();if(r)break;yield s}}finally{await t.cancel()}},tt=(e,t,r,s)=>{const n=Rs(e,t);let o=0,a,i=l=>{a||(a=!0,s&&s(l))};return new ReadableStream({async pull(l){try{const{done:c,value:d}=await n.next();if(c){i(),l.close();return}let p=d.byteLength;if(r){let _=o+=p;r(_)}l.enqueue(new Uint8Array(d))}catch(c){throw i(c),c}},cancel(l){return i(l),n.return()}},{highWaterMark:2})},rt=64*1024,{isFunction:de}=u,Ps=(({Request:e,Response:t})=>({Request:e,Response:t}))(u.global),{ReadableStream:st,TextEncoder:nt}=u.global,ot=(e,...t)=>{try{return!!e(...t)}catch{return!1}},Is=e=>{e=u.merge.call({skipUndefined:!0},Ps,e);const{fetch:t,Request:r,Response:s}=e,n=t?de(t):typeof fetch=="function",o=de(r),a=de(s);if(!n)return!1;const i=n&&de(st),l=n&&(typeof nt=="function"?(h=>E=>h.encode(E))(new nt):async h=>new Uint8Array(await new r(h).arrayBuffer())),c=o&&i&&ot(()=>{let h=!1;const E=new st,f=new r(L.origin,{body:E,method:"POST",get duplex(){return h=!0,"half"}}).headers.has("Content-Type");return E.cancel(),h&&!f}),d=a&&i&&ot(()=>u.isReadableStream(new s("").body)),p={stream:d&&(h=>h.body)};n&&["text","arrayBuffer","blob","formData","stream"].forEach(h=>{!p[h]&&(p[h]=(E,f)=>{let w=E&&E[h];if(w)return w.call(E);throw new A(`Response type '${h}' is not supported`,A.ERR_NOT_SUPPORT,f)})});const _=async h=>{if(h==null)return 0;if(u.isBlob(h))return h.size;if(u.isSpecCompliantForm(h))return(await new r(L.origin,{method:"POST",body:h}).arrayBuffer()).byteLength;if(u.isArrayBufferView(h)||u.isArrayBuffer(h))return h.byteLength;if(u.isURLSearchParams(h)&&(h=h+""),u.isString(h))return(await l(h)).byteLength},C=async(h,E)=>{const f=u.toFiniteNumber(h.getContentLength());return f??_(E)};return async h=>{let{url:E,method:f,data:w,signal:x,cancelToken:y,timeout:g,onDownloadProgress:H,onUploadProgress:k,responseType:D,headers:Pe,withCredentials:ie="same-origin",fetchOptions:ve}=Ct(h),je=t||fetch;D=D?(D+"").toLowerCase():"text";let le=_s([x,y&&y.toAbortSignal()],g),ee=null;const q=le&&le.unsubscribe&&(()=>{le.unsubscribe()});let Fe;try{if(k&&c&&f!=="get"&&f!=="head"&&(Fe=await C(Pe,w))!==0){let F=new r(E,{method:"POST",body:w,duplex:"half"}),X;if(u.isFormData(w)&&(X=F.headers.get("content-type"))&&Pe.setContentType(X),F.body){const[Ie,ce]=Ke(Fe,Ee(Qe(k)));w=tt(F.body,rt,Ie,ce)}}u.isString(ie)||(ie=ie?"include":"omit");const V=o&&"credentials"in r.prototype,ke={...ve,signal:le,method:f.toUpperCase(),headers:Pe.normalize().toJSON(),body:w,duplex:"half",credentials:V?ie:void 0};ee=o&&new r(E,ke);let j=await(o?je(ee,ve):je(E,ke));const qe=d&&(D==="stream"||D==="response");if(d&&(H||qe&&q)){const F={};["status","statusText","headers"].forEach($e=>{F[$e]=j[$e]});const X=u.toFiniteNumber(j.headers.get("content-length")),[Ie,ce]=H&&Ke(X,Ee(Qe(H),!0))||[];j=new s(tt(j.body,rt,Ie,()=>{ce&&ce(),q&&q()}),F)}D=D||"text";let Jt=await p[u.findKey(p,D)||"text"](j,h);return!qe&&q&&q(),await new Promise((F,X)=>{wt(F,X,{data:Jt,headers:U.from(j.headers),status:j.status,statusText:j.statusText,config:h,request:ee})})}catch(V){throw q&&q(),V&&V.name==="TypeError"&&/Load failed|fetch/i.test(V.message)?Object.assign(new A("Network Error",A.ERR_NETWORK,h,ee,V&&V.response),{cause:V.cause||V}):A.from(V,V&&V.code,h,ee,V&&V.response)}}},Ss=new Map,Lt=e=>{let t=e&&e.env||{};const{fetch:r,Request:s,Response:n}=t,o=[s,n,r];let a=o.length,i=a,l,c,d=Ss;for(;i--;)l=o[i],c=d.get(l),c===void 0&&d.set(l,c=i?new Map:Is(t)),d=c;return c};Lt();const Ge={http:Mr,xhr:Os,fetch:{get:Lt}};u.forEach(Ge,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const at=e=>`- ${e}`,bs=e=>u.isFunction(e)||e===null||e===!1;function ws(e,t){e=u.isArray(e)?e:[e];const{length:r}=e;let s,n;const o={};for(let a=0;a<r;a++){s=e[a];let i;if(n=s,!bs(s)&&(n=Ge[(i=String(s)).toLowerCase()],n===void 0))throw new A(`Unknown adapter '${i}'`);if(n&&(u.isFunction(n)||(n=n.get(t))))break;o[i||"#"+a]=n}if(!n){const a=Object.entries(o).map(([l,c])=>`adapter ${l} `+(c===!1?"is not supported by the environment":"is not available in the build"));let i=r?a.length>1?`since :
|
|
4
|
-
`+a.map(
|
|
5
|
-
`):" "+
|
|
6
|
-
`);return a===-1?"":
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});function Rt(e,t){return function(){return e.apply(t,arguments)}}const{toString:sr}=Object.prototype,{getPrototypeOf:be}=Object,{iterator:we,toStringTag:mt}=Symbol,Ce=(e=>t=>{const r=sr.call(t);return e[r]||(e[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),M=e=>(e=e.toLowerCase(),t=>Ce(t)===e),Le=e=>t=>typeof t===e,{isArray:oe}=Array,se=Le("undefined");function ue(e){return e!==null&&!se(e)&&e.constructor!==null&&!se(e.constructor)&&D(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Tt=M("ArrayBuffer");function or(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&Tt(e.buffer),t}const ar=Le("string"),D=Le("function"),Pt=Le("number"),pe=e=>e!==null&&typeof e=="object",ir=e=>e===!0||e===!1,Te=e=>{if(Ce(e)!=="object")return!1;const t=be(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(mt in e)&&!(we in e)},lr=e=>{if(!pe(e)||ue(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch{return!1}},cr=M("Date"),dr=M("File"),ur=e=>!!(e&&typeof e.uri<"u"),pr=e=>e&&typeof e.getParts<"u",hr=M("Blob"),fr=M("FileList"),Er=e=>pe(e)&&D(e.pipe);function Ar(){return typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{}}const nt=Ar(),st=typeof nt.FormData<"u"?nt.FormData:void 0,Or=e=>{if(!e)return!1;if(st&&e instanceof st)return!0;const t=be(e);if(!t||t===Object.prototype||!D(e.append))return!1;const r=Ce(e);return r==="formdata"||r==="object"&&D(e.toString)&&e.toString()==="[object FormData]"},_r=M("URLSearchParams"),[Rr,mr,Tr,Pr]=["ReadableStream","Request","Response","Headers"].map(M),Sr=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function he(e,t,{allOwnKeys:r=!1}={}){if(e===null||typeof e>"u")return;let n,s;if(typeof e!="object"&&(e=[e]),oe(e))for(n=0,s=e.length;n<s;n++)t.call(null,e[n],n,e);else{if(ue(e))return;const o=r?Object.getOwnPropertyNames(e):Object.keys(e),a=o.length;let i;for(n=0;n<a;n++)i=o[n],t.call(null,e[i],i,e)}}function St(e,t){if(ue(e))return null;t=t.toLowerCase();const r=Object.keys(e);let n=r.length,s;for(;n-- >0;)if(s=r[n],t===s.toLowerCase())return s;return null}const K=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,It=e=>!se(e)&&e!==K;function ve(...e){const{caseless:t,skipUndefined:r}=It(this)&&this||{},n={},s=(o,a)=>{if(a==="__proto__"||a==="constructor"||a==="prototype")return;const i=t&&St(n,a)||a,l=Fe(n,i)?n[i]:void 0;Te(l)&&Te(o)?n[i]=ve(l,o):Te(o)?n[i]=ve({},o):oe(o)?n[i]=o.slice():(!r||!se(o))&&(n[i]=o)};for(let o=0,a=e.length;o<a;o++)e[o]&&he(e[o],s);return n}const Ir=(e,t,r,{allOwnKeys:n}={})=>(he(t,(s,o)=>{r&&D(s)?Object.defineProperty(e,o,{__proto__:null,value:Rt(s,r),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(e,o,{__proto__:null,value:s,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:n}),e),yr=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),br=(e,t,r,n)=>{e.prototype=Object.create(t.prototype,n),Object.defineProperty(e.prototype,"constructor",{__proto__:null,value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,"super",{__proto__:null,value:t.prototype}),r&&Object.assign(e.prototype,r)},wr=(e,t,r,n)=>{let s,o,a;const i={};if(t=t||{},e==null)return t;do{for(s=Object.getOwnPropertyNames(e),o=s.length;o-- >0;)a=s[o],(!n||n(a,e,t))&&!i[a]&&(t[a]=e[a],i[a]=!0);e=r!==!1&&be(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t},Cr=(e,t,r)=>{e=String(e),(r===void 0||r>e.length)&&(r=e.length),r-=t.length;const n=e.indexOf(t,r);return n!==-1&&n===r},Lr=e=>{if(!e)return null;if(oe(e))return e;let t=e.length;if(!Pt(t))return null;const r=new Array(t);for(;t-- >0;)r[t]=e[t];return r},gr=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&be(Uint8Array)),Nr=(e,t)=>{const n=(e&&e[we]).call(e);let s;for(;(s=n.next())&&!s.done;){const o=s.value;t.call(e,o[0],o[1])}},xr=(e,t)=>{let r;const n=[];for(;(r=e.exec(t))!==null;)n.push(r);return n},Vr=M("HTMLFormElement"),Ur=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(r,n,s){return n.toUpperCase()+s}),Fe=(({hasOwnProperty:e})=>(t,r)=>e.call(t,r))(Object.prototype),Dr=M("RegExp"),yt=(e,t)=>{const r=Object.getOwnPropertyDescriptors(e),n={};he(r,(s,o)=>{let a;(a=t(s,o,e))!==!1&&(n[o]=a||s)}),Object.defineProperties(e,n)},Br=e=>{yt(e,(t,r)=>{if(D(e)&&["arguments","caller","callee"].includes(r))return!1;const n=e[r];if(D(n)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")})}})},Hr=(e,t)=>{const r={},n=s=>{s.forEach(o=>{r[o]=!0})};return oe(e)?n(e):n(String(e).split(t)),r},Gr=()=>{},Mr=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function vr(e){return!!(e&&D(e.append)&&e[mt]==="FormData"&&e[we])}const Fr=e=>{const t=new Array(10),r=(n,s)=>{if(pe(n)){if(t.indexOf(n)>=0)return;if(ue(n))return n;if(!("toJSON"in n)){t[s]=n;const o=oe(n)?[]:{};return he(n,(a,i)=>{const l=r(a,s+1);!se(l)&&(o[i]=l)}),t[s]=void 0,o}}return n};return r(e,0)},jr=M("AsyncFunction"),kr=e=>e&&(pe(e)||D(e))&&D(e.then)&&D(e.catch),bt=((e,t)=>e?setImmediate:t?((r,n)=>(K.addEventListener("message",({source:s,data:o})=>{s===K&&o===r&&n.length&&n.shift()()},!1),s=>{n.push(s),K.postMessage(r,"*")}))(`axios@${Math.random()}`,[]):r=>setTimeout(r))(typeof setImmediate=="function",D(K.postMessage)),qr=typeof queueMicrotask<"u"?queueMicrotask.bind(K):typeof process<"u"&&process.nextTick||bt,zr=e=>e!=null&&D(e[we]),u={isArray:oe,isArrayBuffer:Tt,isBuffer:ue,isFormData:Or,isArrayBufferView:or,isString:ar,isNumber:Pt,isBoolean:ir,isObject:pe,isPlainObject:Te,isEmptyObject:lr,isReadableStream:Rr,isRequest:mr,isResponse:Tr,isHeaders:Pr,isUndefined:se,isDate:cr,isFile:dr,isReactNativeBlob:ur,isReactNative:pr,isBlob:hr,isRegExp:Dr,isFunction:D,isStream:Er,isURLSearchParams:_r,isTypedArray:gr,isFileList:fr,forEach:he,merge:ve,extend:Ir,trim:Sr,stripBOM:yr,inherits:br,toFlatObject:wr,kindOf:Ce,kindOfTest:M,endsWith:Cr,toArray:Lr,forEachEntry:Nr,matchAll:xr,isHTMLForm:Vr,hasOwnProperty:Fe,hasOwnProp:Fe,reduceDescriptors:yt,freezeMethods:Br,toObjectSet:Hr,toCamelCase:Ur,noop:Gr,toFiniteNumber:Mr,findKey:St,global:K,isContextDefined:It,isSpecCompliantForm:vr,toJSONObject:Fr,isAsyncFn:jr,isThenable:kr,setImmediate:bt,asap:qr,isIterable:zr},$r=u.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),Wr=e=>{const t={};let r,n,s;return e&&e.split(`
|
|
2
|
+
`).forEach(function(a){s=a.indexOf(":"),r=a.substring(0,s).trim().toLowerCase(),n=a.substring(s+1).trim(),!(!r||t[r]&&$r[r])&&(r==="set-cookie"?t[r]?t[r].push(n):t[r]=[n]:t[r]=t[r]?t[r]+", "+n:n)}),t},ot=Symbol("internals"),Xr=/[^\x09\x20-\x7E\x80-\xFF]/g;function Yr(e){let t=0,r=e.length;for(;t<r;){const n=e.charCodeAt(t);if(n!==9&&n!==32)break;t+=1}for(;r>t;){const n=e.charCodeAt(r-1);if(n!==9&&n!==32)break;r-=1}return t===0&&r===e.length?e:e.slice(t,r)}function de(e){return e&&String(e).trim().toLowerCase()}function Jr(e){return Yr(e.replace(Xr,""))}function Pe(e){return e===!1||e==null?e:u.isArray(e)?e.map(Pe):Jr(String(e))}function Zr(e){const t=Object.create(null),r=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let n;for(;n=r.exec(e);)t[n[1]]=n[2];return t}const Kr=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function De(e,t,r,n,s){if(u.isFunction(n))return n.call(this,t,r);if(s&&(t=r),!!u.isString(t)){if(u.isString(n))return t.indexOf(n)!==-1;if(u.isRegExp(n))return n.test(t)}}function Qr(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,r,n)=>r.toUpperCase()+n)}function en(e,t){const r=u.toCamelCase(" "+t);["get","set","has"].forEach(n=>{Object.defineProperty(e,n+r,{__proto__:null,value:function(s,o,a){return this[n].call(this,t,s,o,a)},configurable:!0})})}let U=class{constructor(t){t&&this.set(t)}set(t,r,n){const s=this;function o(i,l,c){const d=de(l);if(!d)throw new Error("header name must be a non-empty string");const p=u.findKey(s,d);(!p||s[p]===void 0||c===!0||c===void 0&&s[p]!==!1)&&(s[p||l]=Pe(i))}const a=(i,l)=>u.forEach(i,(c,d)=>o(c,d,l));if(u.isPlainObject(t)||t instanceof this.constructor)a(t,r);else if(u.isString(t)&&(t=t.trim())&&!Kr(t))a(Wr(t),r);else if(u.isObject(t)&&u.isIterable(t)){let i={},l,c;for(const d of t){if(!u.isArray(d))throw TypeError("Object iterator must return a key-value pair");i[c=d[0]]=(l=i[c])?u.isArray(l)?[...l,d[1]]:[l,d[1]]:d[1]}a(i,r)}else t!=null&&o(r,t,n);return this}get(t,r){if(t=de(t),t){const n=u.findKey(this,t);if(n){const s=this[n];if(!r)return s;if(r===!0)return Zr(s);if(u.isFunction(r))return r.call(this,s,n);if(u.isRegExp(r))return r.exec(s);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,r){if(t=de(t),t){const n=u.findKey(this,t);return!!(n&&this[n]!==void 0&&(!r||De(this,this[n],n,r)))}return!1}delete(t,r){const n=this;let s=!1;function o(a){if(a=de(a),a){const i=u.findKey(n,a);i&&(!r||De(n,n[i],i,r))&&(delete n[i],s=!0)}}return u.isArray(t)?t.forEach(o):o(t),s}clear(t){const r=Object.keys(this);let n=r.length,s=!1;for(;n--;){const o=r[n];(!t||De(this,this[o],o,t,!0))&&(delete this[o],s=!0)}return s}normalize(t){const r=this,n={};return u.forEach(this,(s,o)=>{const a=u.findKey(n,o);if(a){r[a]=Pe(s),delete r[o];return}const i=t?Qr(o):String(o).trim();i!==o&&delete r[o],r[i]=Pe(s),n[i]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const r=Object.create(null);return u.forEach(this,(n,s)=>{n!=null&&n!==!1&&(r[s]=t&&u.isArray(n)?n.join(", "):n)}),r}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,r])=>t+": "+r).join(`
|
|
3
|
+
`)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...r){const n=new this(t);return r.forEach(s=>n.set(s)),n}static accessor(t){const n=(this[ot]=this[ot]={accessors:{}}).accessors,s=this.prototype;function o(a){const i=de(a);n[i]||(en(s,a),n[i]=!0)}return u.isArray(t)?t.forEach(o):o(t),this}};U.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);u.reduceDescriptors(U.prototype,({value:e},t)=>{let r=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(n){this[r]=n}}});u.freezeMethods(U);const tn="[REDACTED ****]";function rn(e){if(u.hasOwnProp(e,"toJSON"))return!0;let t=Object.getPrototypeOf(e);for(;t&&t!==Object.prototype;){if(u.hasOwnProp(t,"toJSON"))return!0;t=Object.getPrototypeOf(t)}return!1}function nn(e,t){const r=new Set(t.map(o=>String(o).toLowerCase())),n=[],s=o=>{if(o===null||typeof o!="object"||u.isBuffer(o))return o;if(n.indexOf(o)!==-1)return;o instanceof U&&(o=o.toJSON()),n.push(o);let a;if(u.isArray(o))a=[],o.forEach((i,l)=>{const c=s(i);u.isUndefined(c)||(a[l]=c)});else{if(!u.isPlainObject(o)&&rn(o))return n.pop(),o;a=Object.create(null);for(const[i,l]of Object.entries(o)){const c=r.has(i.toLowerCase())?tn:s(l);u.isUndefined(c)||(a[i]=c)}}return n.pop(),a};return s(e)}let f=class wt extends Error{static from(t,r,n,s,o,a){const i=new wt(t.message,r||t.code,n,s,o);return i.cause=t,i.name=t.name,t.status!=null&&i.status==null&&(i.status=t.status),a&&Object.assign(i,a),i}constructor(t,r,n,s,o){super(t),Object.defineProperty(this,"message",{__proto__:null,value:t,enumerable:!0,writable:!0,configurable:!0}),this.name="AxiosError",this.isAxiosError=!0,r&&(this.code=r),n&&(this.config=n),s&&(this.request=s),o&&(this.response=o,this.status=o.status)}toJSON(){const t=this.config,r=t&&u.hasOwnProp(t,"redact")?t.redact:void 0,n=u.isArray(r)&&r.length>0?nn(t,r):u.toJSONObject(t);return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:n,code:this.code,status:this.status}}};f.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE";f.ERR_BAD_OPTION="ERR_BAD_OPTION";f.ECONNABORTED="ECONNABORTED";f.ETIMEDOUT="ETIMEDOUT";f.ECONNREFUSED="ECONNREFUSED";f.ERR_NETWORK="ERR_NETWORK";f.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS";f.ERR_DEPRECATED="ERR_DEPRECATED";f.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE";f.ERR_BAD_REQUEST="ERR_BAD_REQUEST";f.ERR_CANCELED="ERR_CANCELED";f.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT";f.ERR_INVALID_URL="ERR_INVALID_URL";f.ERR_FORM_DATA_DEPTH_EXCEEDED="ERR_FORM_DATA_DEPTH_EXCEEDED";const sn=null;function je(e){return u.isPlainObject(e)||u.isArray(e)}function Ct(e){return u.endsWith(e,"[]")?e.slice(0,-2):e}function Be(e,t,r){return e?e.concat(t).map(function(s,o){return s=Ct(s),!r&&o?"["+s+"]":s}).join(r?".":""):t}function on(e){return u.isArray(e)&&!e.some(je)}const an=u.toFlatObject(u,{},null,function(t){return/^is[A-Z]/.test(t)});function ge(e,t,r){if(!u.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,r=u.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(h,A){return!u.isUndefined(A[h])});const n=r.metaTokens,s=r.visitor||p,o=r.dots,a=r.indexes,i=r.Blob||typeof Blob<"u"&&Blob,l=r.maxDepth===void 0?100:r.maxDepth,c=i&&u.isSpecCompliantForm(t);if(!u.isFunction(s))throw new TypeError("visitor must be a function");function d(E){if(E===null)return"";if(u.isDate(E))return E.toISOString();if(u.isBoolean(E))return E.toString();if(!c&&u.isBlob(E))throw new f("Blob is not supported. Use a Buffer instead.");return u.isArrayBuffer(E)||u.isTypedArray(E)?c&&typeof Blob=="function"?new Blob([E]):Buffer.from(E):E}function p(E,h,A){let I=E;if(u.isReactNative(t)&&u.isReactNativeBlob(E))return t.append(Be(A,h,o),d(E)),!1;if(E&&!A&&typeof E=="object"){if(u.endsWith(h,"{}"))h=n?h:h.slice(0,-2),E=JSON.stringify(E);else if(u.isArray(E)&&on(E)||(u.isFileList(E)||u.endsWith(h,"[]"))&&(I=u.toArray(E)))return h=Ct(h),I.forEach(function(T,B){!(u.isUndefined(T)||T===null)&&t.append(a===!0?Be([h],B,o):a===null?h:h+"[]",d(T))}),!1}return je(E)?!0:(t.append(Be(A,h,o),d(E)),!1)}const _=[],R=Object.assign(an,{defaultVisitor:p,convertValue:d,isVisitable:je});function m(E,h,A=0){if(!u.isUndefined(E)){if(A>l)throw new f("Object is too deeply nested ("+A+" levels). Max depth: "+l,f.ERR_FORM_DATA_DEPTH_EXCEEDED);if(_.indexOf(E)!==-1)throw Error("Circular reference detected in "+h.join("."));_.push(E),u.forEach(E,function(P,T){(!(u.isUndefined(P)||P===null)&&s.call(t,P,u.isString(T)?T.trim():T,h,R))===!0&&m(P,h?h.concat(T):[T],A+1)}),_.pop()}}if(!u.isObject(e))throw new TypeError("data must be an object");return m(e),t}function at(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"};return encodeURIComponent(e).replace(/[!'()~]|%20/g,function(n){return t[n]})}function $e(e,t){this._pairs=[],e&&ge(e,this,t)}const Lt=$e.prototype;Lt.append=function(t,r){this._pairs.push([t,r])};Lt.toString=function(t){const r=t?function(n){return t.call(this,n,at)}:at;return this._pairs.map(function(s){return r(s[0])+"="+r(s[1])},"").join("&")};function ln(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function gt(e,t,r){if(!t)return e;const n=r&&r.encode||ln,s=u.isFunction(r)?{serialize:r}:r,o=s&&s.serialize;let a;if(o?a=o(t,s):a=u.isURLSearchParams(t)?t.toString():new $e(t,s).toString(n),a){const i=e.indexOf("#");i!==-1&&(e=e.slice(0,i)),e+=(e.indexOf("?")===-1?"?":"&")+a}return e}class it{constructor(){this.handlers=[]}use(t,r,n){return this.handlers.push({fulfilled:t,rejected:r,synchronous:n?n.synchronous:!1,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){u.forEach(this.handlers,function(n){n!==null&&t(n)})}}const We={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},cn=typeof URLSearchParams<"u"?URLSearchParams:$e,dn=typeof FormData<"u"?FormData:null,un=typeof Blob<"u"?Blob:null,pn={isBrowser:!0,classes:{URLSearchParams:cn,FormData:dn,Blob:un},protocols:["http","https","file","blob","url","data"]},Xe=typeof window<"u"&&typeof document<"u",ke=typeof navigator=="object"&&navigator||void 0,hn=Xe&&(!ke||["ReactNative","NativeScript","NS"].indexOf(ke.product)<0),fn=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",En=Xe&&window.location.href||"http://localhost",An=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:Xe,hasStandardBrowserEnv:hn,hasStandardBrowserWebWorkerEnv:fn,navigator:ke,origin:En},Symbol.toStringTag,{value:"Module"})),V={...An,...pn};function On(e,t){return ge(e,new V.classes.URLSearchParams,{visitor:function(r,n,s,o){return V.isNode&&u.isBuffer(r)?(this.append(n,r.toString("base64")),!1):o.defaultVisitor.apply(this,arguments)},...t})}function _n(e){return u.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function Rn(e){const t={},r=Object.keys(e);let n;const s=r.length;let o;for(n=0;n<s;n++)o=r[n],t[o]=e[o];return t}function Nt(e){function t(r,n,s,o){let a=r[o++];if(a==="__proto__")return!0;const i=Number.isFinite(+a),l=o>=r.length;return a=!a&&u.isArray(s)?s.length:a,l?(u.hasOwnProp(s,a)?s[a]=u.isArray(s[a])?s[a].concat(n):[s[a],n]:s[a]=n,!i):((!s[a]||!u.isObject(s[a]))&&(s[a]=[]),t(r,n,s[a],o)&&u.isArray(s[a])&&(s[a]=Rn(s[a])),!i)}if(u.isFormData(e)&&u.isFunction(e.entries)){const r={};return u.forEachEntry(e,(n,s)=>{t(_n(n),s,r,0)}),r}return null}const re=(e,t)=>e!=null&&u.hasOwnProp(e,t)?e[t]:void 0;function mn(e,t,r){if(u.isString(e))try{return(t||JSON.parse)(e),u.trim(e)}catch(n){if(n.name!=="SyntaxError")throw n}return(r||JSON.stringify)(e)}const fe={transitional:We,adapter:["xhr","http","fetch"],transformRequest:[function(t,r){const n=r.getContentType()||"",s=n.indexOf("application/json")>-1,o=u.isObject(t);if(o&&u.isHTMLForm(t)&&(t=new FormData(t)),u.isFormData(t))return s?JSON.stringify(Nt(t)):t;if(u.isArrayBuffer(t)||u.isBuffer(t)||u.isStream(t)||u.isFile(t)||u.isBlob(t)||u.isReadableStream(t))return t;if(u.isArrayBufferView(t))return t.buffer;if(u.isURLSearchParams(t))return r.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let i;if(o){const l=re(this,"formSerializer");if(n.indexOf("application/x-www-form-urlencoded")>-1)return On(t,l).toString();if((i=u.isFileList(t))||n.indexOf("multipart/form-data")>-1){const c=re(this,"env"),d=c&&c.FormData;return ge(i?{"files[]":t}:t,d&&new d,l)}}return o||s?(r.setContentType("application/json",!1),mn(t)):t}],transformResponse:[function(t){const r=re(this,"transitional")||fe.transitional,n=r&&r.forcedJSONParsing,s=re(this,"responseType"),o=s==="json";if(u.isResponse(t)||u.isReadableStream(t))return t;if(t&&u.isString(t)&&(n&&!s||o)){const i=!(r&&r.silentJSONParsing)&&o;try{return JSON.parse(t,re(this,"parseReviver"))}catch(l){if(i)throw l.name==="SyntaxError"?f.from(l,f.ERR_BAD_RESPONSE,this,null,re(this,"response")):l}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:V.classes.FormData,Blob:V.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};u.forEach(["delete","get","head","post","put","patch","query"],e=>{fe.headers[e]={}});function He(e,t){const r=this||fe,n=t||r,s=U.from(n.headers);let o=n.data;return u.forEach(e,function(i){o=i.call(r,o,s.normalize(),t?t.status:void 0)}),s.normalize(),o}function xt(e){return!!(e&&e.__CANCEL__)}let Ee=class extends f{constructor(t,r,n){super(t??"canceled",f.ERR_CANCELED,r,n),this.name="CanceledError",this.__CANCEL__=!0}};function Vt(e,t,r){const n=r.config.validateStatus;!r.status||!n||n(r.status)?e(r):t(new f("Request failed with status code "+r.status,r.status>=400&&r.status<500?f.ERR_BAD_REQUEST:f.ERR_BAD_RESPONSE,r.config,r.request,r))}function Tn(e){const t=/^([-+\w]{1,25}):(?:\/\/)?/.exec(e);return t&&t[1]||""}function Pn(e,t){e=e||10;const r=new Array(e),n=new Array(e);let s=0,o=0,a;return t=t!==void 0?t:1e3,function(l){const c=Date.now(),d=n[o];a||(a=c),r[s]=l,n[s]=c;let p=o,_=0;for(;p!==s;)_+=r[p++],p=p%e;if(s=(s+1)%e,s===o&&(o=(o+1)%e),c-a<t)return;const R=d&&c-d;return R?Math.round(_*1e3/R):void 0}}function Sn(e,t){let r=0,n=1e3/t,s,o;const a=(c,d=Date.now())=>{r=d,s=null,o&&(clearTimeout(o),o=null),e(...c)};return[(...c)=>{const d=Date.now(),p=d-r;p>=n?a(c,d):(s=c,o||(o=setTimeout(()=>{o=null,a(s)},n-p)))},()=>s&&a(s)]}const Ie=(e,t,r=3)=>{let n=0;const s=Pn(50,250);return Sn(o=>{const a=o.loaded,i=o.lengthComputable?o.total:void 0,l=i!=null?Math.min(a,i):a,c=Math.max(0,l-n),d=s(c);n=Math.max(n,l);const p={loaded:l,total:i,progress:i?l/i:void 0,bytes:c,rate:d||void 0,estimated:d&&i?(i-l)/d:void 0,event:o,lengthComputable:i!=null,[t?"download":"upload"]:!0};e(p)},r)},lt=(e,t)=>{const r=e!=null;return[n=>t[0]({lengthComputable:r,total:e,loaded:n}),t[1]]},ct=e=>(...t)=>u.asap(()=>e(...t)),In=V.hasStandardBrowserEnv?((e,t)=>r=>(r=new URL(r,V.origin),e.protocol===r.protocol&&e.host===r.host&&(t||e.port===r.port)))(new URL(V.origin),V.navigator&&/(msie|trident)/i.test(V.navigator.userAgent)):()=>!0,yn=V.hasStandardBrowserEnv?{write(e,t,r,n,s,o,a){if(typeof document>"u")return;const i=[`${e}=${encodeURIComponent(t)}`];u.isNumber(r)&&i.push(`expires=${new Date(r).toUTCString()}`),u.isString(n)&&i.push(`path=${n}`),u.isString(s)&&i.push(`domain=${s}`),o===!0&&i.push("secure"),u.isString(a)&&i.push(`SameSite=${a}`),document.cookie=i.join("; ")},read(e){if(typeof document>"u")return null;const t=document.cookie.split(";");for(let r=0;r<t.length;r++){const n=t[r].replace(/^\s+/,""),s=n.indexOf("=");if(s!==-1&&n.slice(0,s)===e)return decodeURIComponent(n.slice(s+1))}return null},remove(e){this.write(e,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function bn(e){return typeof e!="string"?!1:/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function wn(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function Ut(e,t,r){let n=!bn(t);return e&&(n||r===!1)?wn(e,t):t}const dt=e=>e instanceof U?{...e}:e;function ee(e,t){t=t||{};const r=Object.create(null);Object.defineProperty(r,"hasOwnProperty",{__proto__:null,value:Object.prototype.hasOwnProperty,enumerable:!1,writable:!0,configurable:!0});function n(c,d,p,_){return u.isPlainObject(c)&&u.isPlainObject(d)?u.merge.call({caseless:_},c,d):u.isPlainObject(d)?u.merge({},d):u.isArray(d)?d.slice():d}function s(c,d,p,_){if(u.isUndefined(d)){if(!u.isUndefined(c))return n(void 0,c,p,_)}else return n(c,d,p,_)}function o(c,d){if(!u.isUndefined(d))return n(void 0,d)}function a(c,d){if(u.isUndefined(d)){if(!u.isUndefined(c))return n(void 0,c)}else return n(void 0,d)}function i(c,d,p){if(u.hasOwnProp(t,p))return n(c,d);if(u.hasOwnProp(e,p))return n(void 0,c)}const l={url:o,method:o,data:o,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,withXSRFToken:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,allowedSocketPaths:a,responseEncoding:a,validateStatus:i,headers:(c,d,p)=>s(dt(c),dt(d),p,!0)};return u.forEach(Object.keys({...e,...t}),function(d){if(d==="__proto__"||d==="constructor"||d==="prototype")return;const p=u.hasOwnProp(l,d)?l[d]:s,_=u.hasOwnProp(e,d)?e[d]:void 0,R=u.hasOwnProp(t,d)?t[d]:void 0,m=p(_,R,d);u.isUndefined(m)&&p!==i||(r[d]=m)}),r}const Cn=["content-type","content-length"];function Ln(e,t,r){if(r!=="content-only"){e.set(t);return}Object.entries(t).forEach(([n,s])=>{Cn.includes(n.toLowerCase())&&e.set(n,s)})}const gn=e=>encodeURIComponent(e).replace(/%([0-9A-F]{2})/gi,(t,r)=>String.fromCharCode(parseInt(r,16))),Dt=e=>{const t=ee({},e),r=_=>u.hasOwnProp(t,_)?t[_]:void 0,n=r("data");let s=r("withXSRFToken");const o=r("xsrfHeaderName"),a=r("xsrfCookieName");let i=r("headers");const l=r("auth"),c=r("baseURL"),d=r("allowAbsoluteUrls"),p=r("url");if(t.headers=i=U.from(i),t.url=gt(Ut(c,p,d),e.params,e.paramsSerializer),l&&i.set("Authorization","Basic "+btoa((l.username||"")+":"+(l.password?gn(l.password):""))),u.isFormData(n)&&(V.hasStandardBrowserEnv||V.hasStandardBrowserWebWorkerEnv?i.setContentType(void 0):u.isFunction(n.getHeaders)&&Ln(i,n.getHeaders(),r("formDataHeaderPolicy"))),V.hasStandardBrowserEnv&&(u.isFunction(s)&&(s=s(t)),s===!0||s==null&&In(t.url))){const R=o&&a&&yn.read(a);R&&i.set(o,R)}return t},Nn=typeof XMLHttpRequest<"u",xn=Nn&&function(e){return new Promise(function(r,n){const s=Dt(e);let o=s.data;const a=U.from(s.headers).normalize();let{responseType:i,onUploadProgress:l,onDownloadProgress:c}=s,d,p,_,R,m;function E(){R&&R(),m&&m(),s.cancelToken&&s.cancelToken.unsubscribe(d),s.signal&&s.signal.removeEventListener("abort",d)}let h=new XMLHttpRequest;h.open(s.method.toUpperCase(),s.url,!0),h.timeout=s.timeout;function A(){if(!h)return;const P=U.from("getAllResponseHeaders"in h&&h.getAllResponseHeaders()),B={data:!i||i==="text"||i==="json"?h.responseText:h.response,status:h.status,statusText:h.statusText,headers:P,config:e,request:h};Vt(function(ie){r(ie),E()},function(ie){n(ie),E()},B),h=null}"onloadend"in h?h.onloadend=A:h.onreadystatechange=function(){!h||h.readyState!==4||h.status===0&&!(h.responseURL&&h.responseURL.startsWith("file:"))||setTimeout(A)},h.onabort=function(){h&&(n(new f("Request aborted",f.ECONNABORTED,e,h)),E(),h=null)},h.onerror=function(T){const B=T&&T.message?T.message:"Network Error",X=new f(B,f.ERR_NETWORK,e,h);X.event=T||null,n(X),E(),h=null},h.ontimeout=function(){let T=s.timeout?"timeout of "+s.timeout+"ms exceeded":"timeout exceeded";const B=s.transitional||We;s.timeoutErrorMessage&&(T=s.timeoutErrorMessage),n(new f(T,B.clarifyTimeoutError?f.ETIMEDOUT:f.ECONNABORTED,e,h)),E(),h=null},o===void 0&&a.setContentType(null),"setRequestHeader"in h&&u.forEach(a.toJSON(),function(T,B){h.setRequestHeader(B,T)}),u.isUndefined(s.withCredentials)||(h.withCredentials=!!s.withCredentials),i&&i!=="json"&&(h.responseType=s.responseType),c&&([_,m]=Ie(c,!0),h.addEventListener("progress",_)),l&&h.upload&&([p,R]=Ie(l),h.upload.addEventListener("progress",p),h.upload.addEventListener("loadend",R)),(s.cancelToken||s.signal)&&(d=P=>{h&&(n(!P||P.type?new Ee(null,e,h):P),h.abort(),E(),h=null)},s.cancelToken&&s.cancelToken.subscribe(d),s.signal&&(s.signal.aborted?d():s.signal.addEventListener("abort",d)));const I=Tn(s.url);if(I&&!V.protocols.includes(I)){n(new f("Unsupported protocol "+I+":",f.ERR_BAD_REQUEST,e));return}h.send(o||null)})},Vn=(e,t)=>{const{length:r}=e=e?e.filter(Boolean):[];if(t||r){let n=new AbortController,s;const o=function(c){if(!s){s=!0,i();const d=c instanceof Error?c:this.reason;n.abort(d instanceof f?d:new Ee(d instanceof Error?d.message:d))}};let a=t&&setTimeout(()=>{a=null,o(new f(`timeout of ${t}ms exceeded`,f.ETIMEDOUT))},t);const i=()=>{e&&(a&&clearTimeout(a),a=null,e.forEach(c=>{c.unsubscribe?c.unsubscribe(o):c.removeEventListener("abort",o)}),e=null)};e.forEach(c=>c.addEventListener("abort",o));const{signal:l}=n;return l.unsubscribe=()=>u.asap(i),l}},Un=function*(e,t){let r=e.byteLength;if(r<t){yield e;return}let n=0,s;for(;n<r;)s=n+t,yield e.slice(n,s),n=s},Dn=async function*(e,t){for await(const r of Bn(e))yield*Un(r,t)},Bn=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}const t=e.getReader();try{for(;;){const{done:r,value:n}=await t.read();if(r)break;yield n}}finally{await t.cancel()}},ut=(e,t,r,n)=>{const s=Dn(e,t);let o=0,a,i=l=>{a||(a=!0,n&&n(l))};return new ReadableStream({async pull(l){try{const{done:c,value:d}=await s.next();if(c){i(),l.close();return}let p=d.byteLength;if(r){let _=o+=p;r(_)}l.enqueue(new Uint8Array(d))}catch(c){throw i(c),c}},cancel(l){return i(l),s.return()}},{highWaterMark:2})};function Hn(e){if(!e||typeof e!="string"||!e.startsWith("data:"))return 0;const t=e.indexOf(",");if(t<0)return 0;const r=e.slice(5,t),n=e.slice(t+1);if(/;base64/i.test(r)){let a=n.length;const i=n.length;for(let R=0;R<i;R++)if(n.charCodeAt(R)===37&&R+2<i){const m=n.charCodeAt(R+1),E=n.charCodeAt(R+2);(m>=48&&m<=57||m>=65&&m<=70||m>=97&&m<=102)&&(E>=48&&E<=57||E>=65&&E<=70||E>=97&&E<=102)&&(a-=2,R+=2)}let l=0,c=i-1;const d=R=>R>=2&&n.charCodeAt(R-2)===37&&n.charCodeAt(R-1)===51&&(n.charCodeAt(R)===68||n.charCodeAt(R)===100);c>=0&&(n.charCodeAt(c)===61?(l++,c--):d(c)&&(l++,c-=3)),l===1&&c>=0&&(n.charCodeAt(c)===61||d(c))&&l++;const _=Math.floor(a/4)*3-(l||0);return _>0?_:0}if(typeof Buffer<"u"&&typeof Buffer.byteLength=="function")return Buffer.byteLength(n,"utf8");let o=0;for(let a=0,i=n.length;a<i;a++){const l=n.charCodeAt(a);if(l<128)o+=1;else if(l<2048)o+=2;else if(l>=55296&&l<=56319&&a+1<i){const c=n.charCodeAt(a+1);c>=56320&&c<=57343?(o+=4,a++):o+=3}else o+=3}return o}const Ye="1.16.0",pt=64*1024,{isFunction:Re}=u,ht=(e,...t)=>{try{return!!e(...t)}catch{return!1}},Gn=e=>{const t=u.global??globalThis,{ReadableStream:r,TextEncoder:n}=t;e=u.merge.call({skipUndefined:!0},{Request:t.Request,Response:t.Response},e);const{fetch:s,Request:o,Response:a}=e,i=s?Re(s):typeof fetch=="function",l=Re(o),c=Re(a);if(!i)return!1;const d=i&&Re(r),p=i&&(typeof n=="function"?(A=>I=>A.encode(I))(new n):async A=>new Uint8Array(await new o(A).arrayBuffer())),_=l&&d&&ht(()=>{let A=!1;const I=new o(V.origin,{body:new r,method:"POST",get duplex(){return A=!0,"half"}}),P=I.headers.has("Content-Type");return I.body!=null&&I.body.cancel(),A&&!P}),R=c&&d&&ht(()=>u.isReadableStream(new a("").body)),m={stream:R&&(A=>A.body)};i&&["text","arrayBuffer","blob","formData","stream"].forEach(A=>{!m[A]&&(m[A]=(I,P)=>{let T=I&&I[A];if(T)return T.call(I);throw new f(`Response type '${A}' is not supported`,f.ERR_NOT_SUPPORT,P)})});const E=async A=>{if(A==null)return 0;if(u.isBlob(A))return A.size;if(u.isSpecCompliantForm(A))return(await new o(V.origin,{method:"POST",body:A}).arrayBuffer()).byteLength;if(u.isArrayBufferView(A)||u.isArrayBuffer(A))return A.byteLength;if(u.isURLSearchParams(A)&&(A=A+""),u.isString(A))return(await p(A)).byteLength},h=async(A,I)=>{const P=u.toFiniteNumber(A.getContentLength());return P??E(I)};return async A=>{let{url:I,method:P,data:T,signal:B,cancelToken:X,timeout:ie,onDownloadProgress:xe,onUploadProgress:Ke,responseType:z,headers:Y,withCredentials:Ae="same-origin",fetchOptions:Qe,maxContentLength:v,maxBodyLength:Ve}=Dt(A);const le=u.isNumber(v)&&v>-1,rr=u.isNumber(Ve)&&Ve>-1;let et=s||fetch;z=z?(z+"").toLowerCase():"text";let $=Vn([B,X&&X.toAbortSignal()],ie),H=null;const J=$&&$.unsubscribe&&(()=>{$.unsubscribe()});let tt;try{if(le&&typeof I=="string"&&I.startsWith("data:")&&Hn(I)>v)throw new f("maxContentLength size of "+v+" exceeded",f.ERR_BAD_RESPONSE,A,H);if(rr&&P!=="get"&&P!=="head"){const y=await h(Y,T);if(typeof y=="number"&&isFinite(y)&&y>Ve)throw new f("Request body larger than maxBodyLength limit",f.ERR_BAD_REQUEST,A,H)}if(Ke&&_&&P!=="get"&&P!=="head"&&(tt=await h(Y,T))!==0){let y=new o(I,{method:"POST",body:T,duplex:"half"}),te;if(u.isFormData(T)&&(te=y.headers.get("content-type"))&&Y.setContentType(te),y.body){const[Oe,_e]=lt(tt,Ie(ct(Ke)));T=ut(y.body,pt,Oe,_e)}}u.isString(Ae)||(Ae=Ae?"include":"omit");const x=l&&"credentials"in o.prototype;if(u.isFormData(T)){const y=Y.getContentType();y&&/^multipart\/form-data/i.test(y)&&!/boundary=/i.test(y)&&Y.delete("content-type")}Y.set("User-Agent","axios/"+Ye,!1);const W={...Qe,signal:$,method:P.toUpperCase(),headers:Y.normalize().toJSON(),body:T,duplex:"half",credentials:x?Ae:void 0};H=l&&new o(I,W);let F=await(l?et(H,Qe):et(I,W));if(le){const y=u.toFiniteNumber(F.headers.get("content-length"));if(y!=null&&y>v)throw new f("maxContentLength size of "+v+" exceeded",f.ERR_BAD_RESPONSE,A,H)}const Ue=R&&(z==="stream"||z==="response");if(R&&F.body&&(xe||le||Ue&&J)){const y={};["status","statusText","headers"].forEach(ce=>{y[ce]=F[ce]});const te=u.toFiniteNumber(F.headers.get("content-length")),[Oe,_e]=xe&<(te,Ie(ct(xe),!0))||[];let rt=0;const nr=ce=>{if(le&&(rt=ce,rt>v))throw new f("maxContentLength size of "+v+" exceeded",f.ERR_BAD_RESPONSE,A,H);Oe&&Oe(ce)};F=new a(ut(F.body,pt,nr,()=>{_e&&_e(),J&&J()}),y)}z=z||"text";let k=await m[u.findKey(m,z)||"text"](F,A);if(le&&!R&&!Ue){let y;if(k!=null&&(typeof k.byteLength=="number"?y=k.byteLength:typeof k.size=="number"?y=k.size:typeof k=="string"&&(y=typeof n=="function"?new n().encode(k).byteLength:k.length)),typeof y=="number"&&y>v)throw new f("maxContentLength size of "+v+" exceeded",f.ERR_BAD_RESPONSE,A,H)}return!Ue&&J&&J(),await new Promise((y,te)=>{Vt(y,te,{data:k,headers:U.from(F.headers),status:F.status,statusText:F.statusText,config:A,request:H})})}catch(x){if(J&&J(),$&&$.aborted&&$.reason instanceof f){const W=$.reason;throw W.config=A,H&&(W.request=H),x!==W&&(W.cause=x),W}throw x&&x.name==="TypeError"&&/Load failed|fetch/i.test(x.message)?Object.assign(new f("Network Error",f.ERR_NETWORK,A,H,x&&x.response),{cause:x.cause||x}):f.from(x,x&&x.code,A,H,x&&x.response)}}},Mn=new Map,Bt=e=>{let t=e&&e.env||{};const{fetch:r,Request:n,Response:s}=t,o=[n,s,r];let a=o.length,i=a,l,c,d=Mn;for(;i--;)l=o[i],c=d.get(l),c===void 0&&d.set(l,c=i?new Map:Gn(t)),d=c;return c};Bt();const Je={http:sn,xhr:xn,fetch:{get:Bt}};u.forEach(Je,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{__proto__:null,value:t})}catch{}Object.defineProperty(e,"adapterName",{__proto__:null,value:t})}});const ft=e=>`- ${e}`,vn=e=>u.isFunction(e)||e===null||e===!1;function Fn(e,t){e=u.isArray(e)?e:[e];const{length:r}=e;let n,s;const o={};for(let a=0;a<r;a++){n=e[a];let i;if(s=n,!vn(n)&&(s=Je[(i=String(n)).toLowerCase()],s===void 0))throw new f(`Unknown adapter '${i}'`);if(s&&(u.isFunction(s)||(s=s.get(t))))break;o[i||"#"+a]=s}if(!s){const a=Object.entries(o).map(([l,c])=>`adapter ${l} `+(c===!1?"is not supported by the environment":"is not available in the build"));let i=r?a.length>1?`since :
|
|
4
|
+
`+a.map(ft).join(`
|
|
5
|
+
`):" "+ft(a[0]):"as no adapter specified";throw new f("There is no suitable adapter to dispatch the request "+i,"ERR_NOT_SUPPORT")}return s}const Ht={getAdapter:Fn,adapters:Je};function Ge(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Ee(null,e)}function Et(e){return Ge(e),e.headers=U.from(e.headers),e.data=He.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),Ht.getAdapter(e.adapter||fe.adapter,e)(e).then(function(n){Ge(e),e.response=n;try{n.data=He.call(e,e.transformResponse,n)}finally{delete e.response}return n.headers=U.from(n.headers),n},function(n){if(!xt(n)&&(Ge(e),n&&n.response)){e.response=n.response;try{n.response.data=He.call(e,e.transformResponse,n.response)}finally{delete e.response}n.response.headers=U.from(n.response.headers)}return Promise.reject(n)})}const Ne={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{Ne[e]=function(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}});const At={};Ne.transitional=function(t,r,n){function s(o,a){return"[Axios v"+Ye+"] Transitional option '"+o+"'"+a+(n?". "+n:"")}return(o,a,i)=>{if(t===!1)throw new f(s(a," has been removed"+(r?" in "+r:"")),f.ERR_DEPRECATED);return r&&!At[a]&&(At[a]=!0,console.warn(s(a," has been deprecated since v"+r+" and will be removed in the near future"))),t?t(o,a,i):!0}};Ne.spelling=function(t){return(r,n)=>(console.warn(`${n} is likely a misspelling of ${t}`),!0)};function jn(e,t,r){if(typeof e!="object")throw new f("options must be an object",f.ERR_BAD_OPTION_VALUE);const n=Object.keys(e);let s=n.length;for(;s-- >0;){const o=n[s],a=Object.prototype.hasOwnProperty.call(t,o)?t[o]:void 0;if(a){const i=e[o],l=i===void 0||a(i,o,e);if(l!==!0)throw new f("option "+o+" must be "+l,f.ERR_BAD_OPTION_VALUE);continue}if(r!==!0)throw new f("Unknown option "+o,f.ERR_BAD_OPTION)}}const Se={assertOptions:jn,validators:Ne},G=Se.validators;let Q=class{constructor(t){this.defaults=t||{},this.interceptors={request:new it,response:new it}}async request(t,r){try{return await this._request(t,r)}catch(n){if(n instanceof Error){let s={};Error.captureStackTrace?Error.captureStackTrace(s):s=new Error;const o=(()=>{if(!s.stack)return"";const a=s.stack.indexOf(`
|
|
6
|
+
`);return a===-1?"":s.stack.slice(a+1)})();try{if(!n.stack)n.stack=o;else if(o){const a=o.indexOf(`
|
|
7
7
|
`),i=a===-1?-1:o.indexOf(`
|
|
8
|
-
`,a+1),l=i===-1?"":o.slice(i+1);String(
|
|
9
|
-
`+o)}}catch{}}throw s}}_request(t,r){typeof t=="string"?(r=r||{},r.url=t):r=t||{},r=Y(this.defaults,r);const{transitional:s,paramsSerializer:n,headers:o}=r;s!==void 0&&fe.assertOptions(s,{silentJSONParsing:B.transitional(B.boolean),forcedJSONParsing:B.transitional(B.boolean),clarifyTimeoutError:B.transitional(B.boolean),legacyInterceptorReqResOrdering:B.transitional(B.boolean)},!1),n!=null&&(u.isFunction(n)?r.paramsSerializer={serialize:n}:fe.assertOptions(n,{encode:B.function,serialize:B.function},!0)),r.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?r.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:r.allowAbsoluteUrls=!0),fe.assertOptions(r,{baseUrl:B.spelling("baseURL"),withXsrfToken:B.spelling("withXSRFToken")},!0),r.method=(r.method||this.defaults.method||"get").toLowerCase();let a=o&&u.merge(o.common,o[r.method]);o&&u.forEach(["delete","get","head","post","put","patch","common"],h=>{delete o[h]}),r.headers=U.concat(a,o);const i=[];let l=!0;this.interceptors.request.forEach(function(E){if(typeof E.runWhen=="function"&&E.runWhen(r)===!1)return;l=l&&E.synchronous;const f=r.transitional||Be;f&&f.legacyInterceptorReqResOrdering?i.unshift(E.fulfilled,E.rejected):i.push(E.fulfilled,E.rejected)});const c=[];this.interceptors.response.forEach(function(E){c.push(E.fulfilled,E.rejected)});let d,p=0,_;if(!l){const h=[it.bind(this),void 0];for(h.unshift(...i),h.push(...c),_=h.length,d=Promise.resolve(r);p<_;)d=d.then(h[p++],h[p++]);return d}_=i.length;let C=r;for(;p<_;){const h=i[p++],E=i[p++];try{C=h(C)}catch(f){E.call(this,f);break}}try{d=it.call(this,C)}catch(h){return Promise.reject(h)}for(p=0,_=c.length;p<_;)d=d.then(c[p++],c[p++]);return d}getUri(t){t=Y(this.defaults,t);const r=yt(t.baseURL,t.url,t.allowAbsoluteUrls);return Pt(r,t.params,t.paramsSerializer)}};u.forEach(["delete","get","head","options"],function(t){W.prototype[t]=function(r,s){return this.request(Y(s||{},{method:t,url:r,data:(s||{}).data}))}});u.forEach(["post","put","patch"],function(t){function r(s){return function(o,a,i){return this.request(Y(i||{},{method:t,headers:s?{"Content-Type":"multipart/form-data"}:{},url:o,data:a}))}}W.prototype[t]=r(),W.prototype[t+"Form"]=r(!0)});let Cs=class Nt{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let r;this.promise=new Promise(function(o){r=o});const s=this;this.promise.then(n=>{if(!s._listeners)return;let o=s._listeners.length;for(;o-- >0;)s._listeners[o](n);s._listeners=null}),this.promise.then=n=>{let o;const a=new Promise(i=>{s.subscribe(i),o=i}).then(n);return a.cancel=function(){s.unsubscribe(o)},a},t(function(o,a,i){s.reason||(s.reason=new ae(o,a,i),r(s.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const r=this._listeners.indexOf(t);r!==-1&&this._listeners.splice(r,1)}toAbortSignal(){const t=new AbortController,r=s=>{t.abort(s)};return this.subscribe(r),t.signal.unsubscribe=()=>this.unsubscribe(r),t.signal}static source(){let t;return{token:new Nt(function(n){t=n}),cancel:t}}};function Ls(e){return function(r){return e.apply(null,r)}}function gs(e){return u.isObject(e)&&e.isAxiosError===!0}const Ne={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(Ne).forEach(([e,t])=>{Ne[t]=e});function Ut(e){const t=new W(e),r=ut(W.prototype.request,t);return u.extend(r,W.prototype,t,{allOwnKeys:!0}),u.extend(r,t,null,{allOwnKeys:!0}),r.create=function(n){return Ut(Y(e,n))},r}const O=Ut(oe);O.Axios=W;O.CanceledError=ae;O.CancelToken=Cs;O.isCancel=bt;O.VERSION=Vt;O.toFormData=Re;O.AxiosError=A;O.Cancel=O.CanceledError;O.all=function(t){return Promise.all(t)};O.spread=Ls;O.isAxiosError=gs;O.mergeConfig=Y;O.AxiosHeaders=U;O.formToJSON=e=>It(u.isHTMLForm(e)?new FormData(e):e);O.getAdapter=gt.getAdapter;O.HttpStatusCode=Ne;O.default=O;const{Axios:Zs,AxiosError:Ks,CanceledError:Qs,isCancel:en,CancelToken:tn,VERSION:rn,all:sn,Cancel:nn,isAxiosError:on,spread:an,toFormData:ln,AxiosHeaders:cn,HttpStatusCode:dn,formToJSON:un,getAdapter:pn,mergeConfig:hn}=O,R="https://faceapi.regulaforensics.com".replace(/\/+$/,"");class Q{constructor(t,r=R,s=O){this.basePath=r,this.axios=s,t&&(this.configuration=t,this.basePath=t.basePath??r)}}class Vs extends Error{constructor(t,r){super(r),this.field=t,this.name="RequiredError"}}const T={},P="https://example.com",m=function(e,t,r){if(r==null)throw new Vs(t,`Required parameter ${t} was null or undefined when calling ${e}.`)};function Ue(e,t,r=""){t!=null&&(typeof t=="object"?Array.isArray(t)?t.forEach(s=>Ue(e,s,r)):Object.keys(t).forEach(s=>Ue(e,t[s],`${r}${r!==""?".":""}${s}`)):e.has(r)?e.append(r,t):e.set(r,t))}const I=function(e,...t){const r=new URLSearchParams(e.search);Ue(r,t),e.search=r.toString()},M=function(e,t,r){const s=typeof e!="string";return(s&&r&&r.isJsonMime?r.isJsonMime(t.headers["Content-Type"]):s)?JSON.stringify(e!==void 0?e:{}):e||""},S=function(e){return e.pathname+e.search+e.hash},b=function(e,t,r,s){return(n=t,o=r)=>{const a={...e.options,url:(n.defaults.baseURL?"":s?.basePath??o)+e.url};return n.request(a)}},Ns=function(e){return{detect:async(t,r,s={})=>{m("detect","detectRequest",t);const n="/api/detect",o=new URL(n,P);let a;e&&(a=e.baseOptions);const i={method:"POST",...a,...s},l={},c={};l["Content-Type"]="application/json",r!=null&&(l["X-RequestID"]=String(r)),I(o,c);let d=a&&a.headers?a.headers:{};return i.headers={...l,...d,...s.headers},i.data=M(t,i,e),{url:S(o),options:i}},match:async(t,r,s={})=>{m("match","matchRequest",t);const n="/api/match",o=new URL(n,P);let a;e&&(a=e.baseOptions);const i={method:"POST",...a,...s},l={},c={};l["Content-Type"]="application/json",r!=null&&(l["X-RequestID"]=String(r)),I(o,c);let d=a&&a.headers?a.headers:{};return i.headers={...l,...d,...s.headers},i.data=M(t,i,e),{url:S(o),options:i}},matchAndSearch:async(t,r,s={})=>{m("matchAndSearch","matchAndSearchRequest",t);const n="/api/match_and_search",o=new URL(n,P);let a;e&&(a=e.baseOptions);const i={method:"POST",...a,...s},l={},c={};l["Content-Type"]="application/json",r!=null&&(l["X-RequestID"]=String(r)),I(o,c);let d=a&&a.headers?a.headers:{};return i.headers={...l,...d,...s.headers},i.data=M(t,i,e),{url:S(o),options:i}}}},Ce=function(e){const t=Ns(e);return{async detect(r,s,n){const o=await t.detect(r,s,n),a=e?.serverIndex??0,i=T["MatchApi.detect"]?.[a]?.url;return(l,c)=>b(o,O,R,e)(l,i||c)},async match(r,s,n){const o=await t.match(r,s,n),a=e?.serverIndex??0,i=T["MatchApi.match"]?.[a]?.url;return(l,c)=>b(o,O,R,e)(l,i||c)},async matchAndSearch(r,s,n){const o=await t.matchAndSearch(r,s,n),a=e?.serverIndex??0,i=T["MatchApi.matchAndSearch"]?.[a]?.url;return(l,c)=>b(o,O,R,e)(l,i||c)}}};let Us=class extends Q{detect(t,r,s){return Ce(this.configuration).detect(t,r,s).then(n=>n(this.axios,this.basePath))}match(t,r,s){return Ce(this.configuration).match(t,r,s).then(n=>n(this.axios,this.basePath))}matchAndSearch(t,r,s){return Ce(this.configuration).matchAndSearch(t,r,s).then(n=>n(this.axios,this.basePath))}};var xt=(e=>(e.AGE="Age",e.EMOTION="Emotion",e.EYE_LEFT="EyeLeft",e.EYE_RIGHT="EyeRight",e.SMILE="Smile",e.GLASSES="Glasses",e.HEAD_COVERING="HeadCovering",e.FOREHEAD_COVERING="ForeheadCovering",e.MOUTH="Mouth",e.MEDICAL_MASK="MedicalMask",e.OCCLUSION="Occlusion",e.STRONG_MAKEUP="StrongMakeup",e.HEADPHONES="Headphones",e))(xt||{}),Dt=(e=>(e[e.ALIGN_3x4=0]="ALIGN_3x4",e[e.ALIGN_4x5=1]="ALIGN_4x5",e[e.ALIGN_2x3=2]="ALIGN_2x3",e[e.ALIGN_1x1=3]="ALIGN_1x1",e[e.ALIGN_7x9=4]="ALIGN_7x9",e))(Dt||{}),Bt=(e=>(e[e.IMAGE_CHARACTERISTICS=1]="IMAGE_CHARACTERISTICS",e[e.HEAD_SIZE_AND_POSITIONS=2]="HEAD_SIZE_AND_POSITIONS",e[e.FACE_QUALITY=3]="FACE_QUALITY",e[e.EYES_CHARACTERISTICS=4]="EYES_CHARACTERISTICS",e[e.SHADOWS_AND_LIGHTNING=5]="SHADOWS_AND_LIGHTNING",e[e.POSE_AND_EXPRESSION=6]="POSE_AND_EXPRESSION",e[e.HEAD_OCCLUSION=7]="HEAD_OCCLUSION",e[e.BACKGROUND=8]="BACKGROUND",e))(Bt||{}),Ht=(e=>(e.IMAGE_CHARACTERISTICS="ImageCharacteristics",e.HEAD_SIZE_AND_POSITIONS="HeadSizeAndPosition",e.FACE_QUALITY="FaceQuality",e.EYES_CHARACTERISTICS="EyesCharacteristics",e.SHADOWS_AND_LIGHTNING="ShadowsAndLightning",e.POSE_AND_EXPRESSION="PoseAndExpression",e.HEAD_OCCLUSION="HeadOcclusion",e.BACKGROUND="Background",e))(Ht||{}),Gt=(e=>(e[e.QUALITY_STATUS_FALSE=0]="QUALITY_STATUS_FALSE",e[e.QUALITY_STATUS_TRUE=1]="QUALITY_STATUS_TRUE",e[e.QUALITY_STATUS_UNDETERMINED=2]="QUALITY_STATUS_UNDETERMINED",e))(Gt||{}),Mt=(e=>(e.IMAGE_WIDTH="ImageWidth",e.IMAGE_HEIGHT="ImageHeight",e.IMAGE_WIDTH_TO_HEIGHT="ImageWidthToHeight",e.IMAGE_CHANNELS_NUMBER="ImageChannelsNumber",e.PADDING_RATIO="PaddingRatio",e.FACE_MID_POINT_HORIZONTAL_POSITION="FaceMidPointHorizontalPosition",e.FACE_MID_POINT_VERTICAL_POSITION="FaceMidPointVerticalPosition",e.HEAD_WIDTH_RATIO="HeadWidthRatio",e.HEAD_HEIGHT_RATIO="HeadHeightRatio",e.EYES_DISTANCE="EyesDistance",e.YAW="Yaw",e.PITCH="Pitch",e.ROLL="Roll",e.BLUR_LEVEL="BlurLevel",e.NOISE_LEVEL="NoiseLevel",e.EYE_RIGHT_CLOSED="EyeRightClosed",e.EYE_LEFT_CLOSED="EyeLeftClosed",e.EYE_RIGHT_OCCLUDED="EyeRightOccluded",e.EYE_LEFT_OCCLUDED="EyeLeftOccluded",e.EYES_RED="EyesRed",e.EYE_RIGHT_COVERED_WITH_HAIR="EyeRightCoveredWithHair",e.EYE_LEFT_COVERED_WITH_HAIR="EyeLeftCoveredWithHair",e.OFF_GAZE="OffGaze",e.FACE_DYNAMIC_RANGE="FaceDynamicRange",e.UNNATURAL_SKIN_TONE="UnnaturalSkinTone",e.TOO_DARK="TooDark",e.TOO_LIGHT="TooLight",e.FACE_GLARE="FaceGlare",e.SHADOWS_ON_FACE="ShadowsOnFace",e.DARK_GLASSES="DarkGlasses",e.REFLECTION_ON_GLASSES="ReflectionOnGlasses",e.FRAMES_TOO_HEAVY="FramesTooHeavy",e.FACE_OCCLUDED="FaceOccluded",e.HEAD_COVERING="HeadCovering",e.BACKGROUND_UNIFORMITY="BackgroundUniformity",e.SHADOWS_ON_BACKGROUND="ShadowsOnBackground",e.OTHER_FACES="OtherFaces",e.SHOULDERS_POSE="ShouldersPose",e.EXPRESSION_LEVEL="ExpressionLevel",e.MOUTH_OPEN="MouthOpen",e.FOREHEAD_COVERING="ForeheadCovering",e.SMILE="Smile",e.STRONG_MAKEUP="StrongMakeup",e.HEADPHONES="Headphones",e.MEDICAL_MASK="MedicalMask",e.BACKGROUND_COLOR_MATCH="BackgroundColorMatch",e.ART_FACE="ArtFace",e.CONTACT_LENSES="ContactLenses",e))(Mt||{}),vt=(e=>(e.OLD_MODE="OldMode",e.QUALITY_FULL="QualityFull",e.QUALITY_ICAO="QualityICAO",e.QUALITY_VISA_SCHENGEN="QualityVisaSchengen",e.QUALITY_VISA_USA="QualityVisaUSA",e.CROP_CENTRAL_FACE="CropCentralFace",e.CROP_ALL_FACES="CropAllFaces",e.THUMBNAIL="Thumbnail",e.ATTRIBUTES_ALL="AttributesAll",e.EMPTY="",e))(vt||{}),jt=(e=>(e[e.FACER_OK=0]="FACER_OK",e[e.FR_IMAGE_EMPTY=1]="FR_IMAGE_EMPTY",e[e.FR_FACE_NOT_DETECTED=2]="FR_FACE_NOT_DETECTED",e[e.FR_LANDMARKS_NOT_DETECTED=3]="FR_LANDMARKS_NOT_DETECTED",e[e.FR_FACE_ALIGHNER_FAILED=4]="FR_FACE_ALIGHNER_FAILED",e[e.FR_DESCRIPTOR_EXTRACTOR_ERROR=5]="FR_DESCRIPTOR_EXTRACTOR_ERROR",e[e.FR_IMAGE_DECODE_ERROR=6]="FR_IMAGE_DECODE_ERROR",e[e.FR_INTERNAL_ERROR=7]="FR_INTERNAL_ERROR",e[e.FACER_CONFIG_ERROR=199]="FACER_CONFIG_ERROR",e[e.FACER_NO_LICENSE=200]="FACER_NO_LICENSE",e[e.FACER_IS_NOT_INITIALIZED=201]="FACER_IS_NOT_INITIALIZED",e[e.FACER_COMMAND_IS_NOT_SUPPORTED=202]="FACER_COMMAND_IS_NOT_SUPPORTED",e[e.FACER_COMMAND_PARAMS_READ_ERROR=203]="FACER_COMMAND_PARAMS_READ_ERROR",e[e.FACER_LESS_THAN_TWO_IMAGES_IN_REQUEST=224]="FACER_LESS_THAN_TWO_IMAGES_IN_REQUEST",e[e.FACER_VIDEO_DECODE_ERROR=227]="FACER_VIDEO_DECODE_ERROR",e[e.FACER_NOT_ENOUGH_FRAMES=228]="FACER_NOT_ENOUGH_FRAMES",e[e.FACER_OUTPUT_IS_NOT_DEFINED=229]="FACER_OUTPUT_IS_NOT_DEFINED",e[e.FACER_CLOSED_EYES_DETECTED=230]="FACER_CLOSED_EYES_DETECTED",e[e.FACER_LOW_QUALITY=231]="FACER_LOW_QUALITY",e[e.FACER_HIGH_ASYMMETRY=232]="FACER_HIGH_ASYMMETRY",e[e.FACER_FACE_OVER_EMOTIONAL=233]="FACER_FACE_OVER_EMOTIONAL",e[e.FACER_SUNGLASSES_DETECTED=234]="FACER_SUNGLASSES_DETECTED",e[e.FACER_SMALL_AGE=235]="FACER_SMALL_AGE",e[e.FACER_HEADDRESS_DETECTED=236]="FACER_HEADDRESS_DETECTED",e[e.FACER_FACES_NOT_MATCHED=237]="FACER_FACES_NOT_MATCHED",e[e.FACER_IMAGES_COUNT_LIMIT_EXCEEDED=238]="FACER_IMAGES_COUNT_LIMIT_EXCEEDED",e[e.FACER_MEDICINE_MASK_DETECTED=239]="FACER_MEDICINE_MASK_DETECTED",e[e.FACER_OCCLUSION_DETECTED=240]="FACER_OCCLUSION_DETECTED",e[e.FACER_FOREHEAD_GLASSES_DETECTED=242]="FACER_FOREHEAD_GLASSES_DETECTED",e[e.FACER_MOUTH_OPENED=243]="FACER_MOUTH_OPENED",e[e.FACER_ART_MASK_DETECTED=244]="FACER_ART_MASK_DETECTED",e[e.FACER_ELECTRONIC_DEVICE_DETECTED=245]="FACER_ELECTRONIC_DEVICE_DETECTED",e[e.FACER_TRACK_BREAK=246]="FACER_TRACK_BREAK",e[e.FACER_WRONG_GEO=247]="FACER_WRONG_GEO",e[e.FACER_WRONG_OF=248]="FACER_WRONG_OF",e[e.FACER_WRONG_VIEW=249]="FACER_WRONG_VIEW",e[e.FACER_TIMEOUT_LIVENESS_TRANSACTION=250]="FACER_TIMEOUT_LIVENESS_TRANSACTION",e[e.FACER_FAILED_LIVENESS_TRANSACTION=251]="FACER_FAILED_LIVENESS_TRANSACTION",e[e.FACER_ABORTED_LIVENESS_TRANSACTION=252]="FACER_ABORTED_LIVENESS_TRANSACTION",e[e.FACER_GENERAL_ERROR=253]="FACER_GENERAL_ERROR",e[e.FACER_PASSIVE_LIVENESS_FAIL=254]="FACER_PASSIVE_LIVENESS_FAIL",e))(jt||{}),Ft=(e=>(e.IN="in",e.NOT_IN="nin",e))(Ft||{}),Me=(e=>(e[e.DOCUMENT_PRINTED=1]="DOCUMENT_PRINTED",e[e.DOCUMENT_RFID=2]="DOCUMENT_RFID",e[e.LIVE=3]="LIVE",e[e.DOCUMENT_WITH_LIVE=4]="DOCUMENT_WITH_LIVE",e[e.EXTERNAL=5]="EXTERNAL",e[e.GHOST=6]="GHOST",e[e.BARCODE=7]="BARCODE",e))(Me||{}),kt=(e=>(e[e.ACTIVE=0]="ACTIVE",e[e.PASSIVE=1]="PASSIVE",e))(kt||{}),J="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",xs=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(var ue=0;ue<J.length;ue++)xs[J.charCodeAt(ue)]=ue;var Ae=function(e){var t=new Uint8Array(e),r,s=t.length,n="";for(r=0;r<s;r+=3)n+=J[t[r]>>2],n+=J[(t[r]&3)<<4|t[r+1]>>4],n+=J[(t[r+1]&15)<<2|t[r+2]>>6],n+=J[t[r+2]&63];return s%3===2?n=n.substring(0,n.length-1)+"=":s%3===1&&(n=n.substring(0,n.length-2)+"=="),n};class qt{constructor(t,r,s){this.superClass=new Us(t,r,s)}async match(t,r,s){for(const o of t.images)o.type||(o.type=Me.LIVE),typeof o.data!="string"&&(o.data=Ae(o.data));return(await this.superClass.match(t,r,s)).data}async detect(t,r,s){return t.image&&typeof t.image!="string"&&(t.image=Ae(t.image)),(await this.superClass.detect(t,r,s)).data}}const Ds=function(e){return{createGroup:async(t,r,s={})=>{m("createGroup","groupToCreate",t);const n="/api/groups",o=new URL(n,P);let a;e&&(a=e.baseOptions);const i={method:"POST",...a,...s},l={},c={};l["Content-Type"]="application/json",r!=null&&(l["X-RequestID"]=String(r)),I(o,c);let d=a&&a.headers?a.headers:{};return i.headers={...l,...d,...s.headers},i.data=M(t,i,e),{url:S(o),options:i}},deleteGroup:async(t,r,s={})=>{m("deleteGroup","groupId",t);const n="/api/groups/{groupId}".replace("{groupId}",encodeURIComponent(String(t))),o=new URL(n,P);let a;e&&(a=e.baseOptions);const i={method:"DELETE",...a,...s},l={},c={};r!=null&&(l["X-RequestID"]=String(r)),I(o,c);let d=a&&a.headers?a.headers:{};return i.headers={...l,...d,...s.headers},{url:S(o),options:i}},getAllGroups:async(t,r,s,n={})=>{const o="/api/groups",a=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...n},c={},d={};r!==void 0&&(d.page=r),s!==void 0&&(d.size=s),t!=null&&(c["X-RequestID"]=String(t)),I(a,d);let p=i&&i.headers?i.headers:{};return l.headers={...c,...p,...n.headers},{url:S(a),options:l}},getAllPersonsByGroupId:async(t,r,s,n,o={})=>{m("getAllPersonsByGroupId","groupId",t);const a="/api/groups/{groupId}/persons".replace("{groupId}",encodeURIComponent(String(t))),i=new URL(a,P);let l;e&&(l=e.baseOptions);const c={method:"GET",...l,...o},d={},p={};s!==void 0&&(p.page=s),n!==void 0&&(p.size=n),r!=null&&(d["X-RequestID"]=String(r)),I(i,p);let _=l&&l.headers?l.headers:{};return c.headers={...d,..._,...o.headers},{url:S(i),options:c}},getGroup:async(t,r,s={})=>{m("getGroup","groupId",t);const n="/api/groups/{groupId}".replace("{groupId}",encodeURIComponent(String(t))),o=new URL(n,P);let a;e&&(a=e.baseOptions);const i={method:"GET",...a,...s},l={},c={};r!=null&&(l["X-RequestID"]=String(r)),I(o,c);let d=a&&a.headers?a.headers:{};return i.headers={...l,...d,...s.headers},{url:S(o),options:i}},updateGroup:async(t,r,s,n={})=>{m("updateGroup","groupId",t),m("updateGroup","groupToCreate",r);const o="/api/groups/{groupId}".replace("{groupId}",encodeURIComponent(String(t))),a=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...n},c={},d={};c["Content-Type"]="application/json",s!=null&&(c["X-RequestID"]=String(s)),I(a,d);let p=i&&i.headers?i.headers:{};return l.headers={...c,...p,...n.headers},l.data=M(r,l,e),{url:S(a),options:l}},updatePersonsInGroup:async(t,r,s,n={})=>{m("updatePersonsInGroup","groupId",t),m("updatePersonsInGroup","updateGroup",r);const o="/api/groups/{groupId}/persons".replace("{groupId}",encodeURIComponent(String(t))),a=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...n},c={},d={};c["Content-Type"]="application/json",s!=null&&(c["X-RequestID"]=String(s)),I(a,d);let p=i&&i.headers?i.headers:{};return l.headers={...c,...p,...n.headers},l.data=M(r,l,e),{url:S(a),options:l}}}},$=function(e){const t=Ds(e);return{async createGroup(r,s,n){const o=await t.createGroup(r,s,n),a=e?.serverIndex??0,i=T["GroupApi.createGroup"]?.[a]?.url;return(l,c)=>b(o,O,R,e)(l,i||c)},async deleteGroup(r,s,n){const o=await t.deleteGroup(r,s,n),a=e?.serverIndex??0,i=T["GroupApi.deleteGroup"]?.[a]?.url;return(l,c)=>b(o,O,R,e)(l,i||c)},async getAllGroups(r,s,n,o){const a=await t.getAllGroups(r,s,n,o),i=e?.serverIndex??0,l=T["GroupApi.getAllGroups"]?.[i]?.url;return(c,d)=>b(a,O,R,e)(c,l||d)},async getAllPersonsByGroupId(r,s,n,o,a){const i=await t.getAllPersonsByGroupId(r,s,n,o,a),l=e?.serverIndex??0,c=T["GroupApi.getAllPersonsByGroupId"]?.[l]?.url;return(d,p)=>b(i,O,R,e)(d,c||p)},async getGroup(r,s,n){const o=await t.getGroup(r,s,n),a=e?.serverIndex??0,i=T["GroupApi.getGroup"]?.[a]?.url;return(l,c)=>b(o,O,R,e)(l,i||c)},async updateGroup(r,s,n,o){const a=await t.updateGroup(r,s,n,o),i=e?.serverIndex??0,l=T["GroupApi.updateGroup"]?.[i]?.url;return(c,d)=>b(a,O,R,e)(c,l||d)},async updatePersonsInGroup(r,s,n,o){const a=await t.updatePersonsInGroup(r,s,n,o),i=e?.serverIndex??0,l=T["GroupApi.updatePersonsInGroup"]?.[i]?.url;return(c,d)=>b(a,O,R,e)(c,l||d)}}};let Bs=class extends Q{createGroup(t,r,s){return $(this.configuration).createGroup(t,r,s).then(n=>n(this.axios,this.basePath))}deleteGroup(t,r,s){return $(this.configuration).deleteGroup(t,r,s).then(n=>n(this.axios,this.basePath))}getAllGroups(t,r,s,n){return $(this.configuration).getAllGroups(t,r,s,n).then(o=>o(this.axios,this.basePath))}getAllPersonsByGroupId(t,r,s,n,o){return $(this.configuration).getAllPersonsByGroupId(t,r,s,n,o).then(a=>a(this.axios,this.basePath))}getGroup(t,r,s){return $(this.configuration).getGroup(t,r,s).then(n=>n(this.axios,this.basePath))}updateGroup(t,r,s,n){return $(this.configuration).updateGroup(t,r,s,n).then(o=>o(this.axios,this.basePath))}updatePersonsInGroup(t,r,s,n){return $(this.configuration).updatePersonsInGroup(t,r,s,n).then(o=>o(this.axios,this.basePath))}};class $t{constructor(t,r,s){this.superClass=new Bs(t,r,s)}async createGroup(t,r,s){const n={...t,metadata:t?.metadata?t.metadata:{}};return(await this.superClass.createGroup(n,r,s)).data}async deleteGroup(t,r,s){await this.superClass.deleteGroup(t,r,s)}async getAllGroups(t,r,s,n){return(await this.superClass.getAllGroups(s,t,r,n)).data}async getAllPersonsByGroupId(t,r,s,n,o){return(await this.superClass.getAllPersonsByGroupId(s,n,t,r,o)).data}async getGroup(t,r,s){return(await this.superClass.getGroup(t,r,s)).data}async updateGroup(t,r,s,n){await this.superClass.updateGroup(t,r,s,n)}async updatePersonsInGroup(t,r,s,n){await this.superClass.updatePersonsInGroup(t,r,s,n)}}const Hs=function(e){return{addImageToPerson:async(t,r,s,n={})=>{m("addImageToPerson","personId",t),m("addImageToPerson","addImageToPersonRequest",r);const o="/api/persons/{personId}/images".replace("{personId}",encodeURIComponent(String(t))),a=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...n},c={},d={};c["Content-Type"]="application/json",s!=null&&(c["X-RequestID"]=String(s)),I(a,d);let p=i&&i.headers?i.headers:{};return l.headers={...c,...p,...n.headers},l.data=M(r,l,e),{url:S(a),options:l}},createPerson:async(t,r,s={})=>{m("createPerson","personFields",t);const n="/api/persons",o=new URL(n,P);let a;e&&(a=e.baseOptions);const i={method:"POST",...a,...s},l={},c={};l["Content-Type"]="application/json",r!=null&&(l["X-RequestID"]=String(r)),I(o,c);let d=a&&a.headers?a.headers:{};return i.headers={...l,...d,...s.headers},i.data=M(t,i,e),{url:S(o),options:i}},deleteImageOfPerson:async(t,r,s,n={})=>{m("deleteImageOfPerson","personId",t),m("deleteImageOfPerson","imageId",r);const o="/api/persons/{personId}/images/{imageId}".replace("{personId}",encodeURIComponent(String(t))).replace("{imageId}",encodeURIComponent(String(r))),a=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"DELETE",...i,...n},c={},d={};s!=null&&(c["X-RequestID"]=String(s)),I(a,d);let p=i&&i.headers?i.headers:{};return l.headers={...c,...p,...n.headers},{url:S(a),options:l}},deletePerson:async(t,r,s={})=>{m("deletePerson","personId",t);const n="/api/persons/{personId}".replace("{personId}",encodeURIComponent(String(t))),o=new URL(n,P);let a;e&&(a=e.baseOptions);const i={method:"DELETE",...a,...s},l={},c={};r!=null&&(l["X-RequestID"]=String(r)),I(o,c);let d=a&&a.headers?a.headers:{};return i.headers={...l,...d,...s.headers},{url:S(o),options:i}},getAllGroupsByPersonId:async(t,r,s,n,o={})=>{m("getAllGroupsByPersonId","personId",t);const a="/api/persons/{personId}/groups".replace("{personId}",encodeURIComponent(String(t))),i=new URL(a,P);let l;e&&(l=e.baseOptions);const c={method:"GET",...l,...o},d={},p={};s!==void 0&&(p.page=s),n!==void 0&&(p.size=n),r!=null&&(d["X-RequestID"]=String(r)),I(i,p);let _=l&&l.headers?l.headers:{};return c.headers={...d,..._,...o.headers},{url:S(i),options:c}},getAllImagesByPersonId:async(t,r,s,n,o={})=>{m("getAllImagesByPersonId","personId",t);const a="/api/persons/{personId}/images".replace("{personId}",encodeURIComponent(String(t))),i=new URL(a,P);let l;e&&(l=e.baseOptions);const c={method:"GET",...l,...o},d={},p={};s!==void 0&&(p.page=s),n!==void 0&&(p.size=n),r!=null&&(d["X-RequestID"]=String(r)),I(i,p);let _=l&&l.headers?l.headers:{};return c.headers={...d,..._,...o.headers},{url:S(i),options:c}},getImageOfPerson:async(t,r,s,n={})=>{m("getImageOfPerson","personId",t),m("getImageOfPerson","imageId",r);const o="/api/persons/{personId}/images/{imageId}".replace("{personId}",encodeURIComponent(String(t))).replace("{imageId}",encodeURIComponent(String(r))),a=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...n},c={},d={};s!=null&&(c["X-RequestID"]=String(s)),I(a,d);let p=i&&i.headers?i.headers:{};return l.headers={...c,...p,...n.headers},{url:S(a),options:l}},getPerson:async(t,r,s={})=>{m("getPerson","personId",t);const n="/api/persons/{personId}".replace("{personId}",encodeURIComponent(String(t))),o=new URL(n,P);let a;e&&(a=e.baseOptions);const i={method:"GET",...a,...s},l={},c={};r!=null&&(l["X-RequestID"]=String(r)),I(o,c);let d=a&&a.headers?a.headers:{};return i.headers={...l,...d,...s.headers},{url:S(o),options:i}},updatePerson:async(t,r,s,n={})=>{m("updatePerson","personId",t),m("updatePerson","personToUpdateFields",r);const o="/api/persons/{personId}".replace("{personId}",encodeURIComponent(String(t))),a=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...n},c={},d={};c["Content-Type"]="application/json",s!=null&&(c["X-RequestID"]=String(s)),I(a,d);let p=i&&i.headers?i.headers:{};return l.headers={...c,...p,...n.headers},l.data=M(r,l,e),{url:S(a),options:l}}}},v=function(e){const t=Hs(e);return{async addImageToPerson(r,s,n,o){const a=await t.addImageToPerson(r,s,n,o),i=e?.serverIndex??0,l=T["PersonApi.addImageToPerson"]?.[i]?.url;return(c,d)=>b(a,O,R,e)(c,l||d)},async createPerson(r,s,n){const o=await t.createPerson(r,s,n),a=e?.serverIndex??0,i=T["PersonApi.createPerson"]?.[a]?.url;return(l,c)=>b(o,O,R,e)(l,i||c)},async deleteImageOfPerson(r,s,n,o){const a=await t.deleteImageOfPerson(r,s,n,o),i=e?.serverIndex??0,l=T["PersonApi.deleteImageOfPerson"]?.[i]?.url;return(c,d)=>b(a,O,R,e)(c,l||d)},async deletePerson(r,s,n){const o=await t.deletePerson(r,s,n),a=e?.serverIndex??0,i=T["PersonApi.deletePerson"]?.[a]?.url;return(l,c)=>b(o,O,R,e)(l,i||c)},async getAllGroupsByPersonId(r,s,n,o,a){const i=await t.getAllGroupsByPersonId(r,s,n,o,a),l=e?.serverIndex??0,c=T["PersonApi.getAllGroupsByPersonId"]?.[l]?.url;return(d,p)=>b(i,O,R,e)(d,c||p)},async getAllImagesByPersonId(r,s,n,o,a){const i=await t.getAllImagesByPersonId(r,s,n,o,a),l=e?.serverIndex??0,c=T["PersonApi.getAllImagesByPersonId"]?.[l]?.url;return(d,p)=>b(i,O,R,e)(d,c||p)},async getImageOfPerson(r,s,n,o){const a=await t.getImageOfPerson(r,s,n,o),i=e?.serverIndex??0,l=T["PersonApi.getImageOfPerson"]?.[i]?.url;return(c,d)=>b(a,O,R,e)(c,l||d)},async getPerson(r,s,n){const o=await t.getPerson(r,s,n),a=e?.serverIndex??0,i=T["PersonApi.getPerson"]?.[a]?.url;return(l,c)=>b(o,O,R,e)(l,i||c)},async updatePerson(r,s,n,o){const a=await t.updatePerson(r,s,n,o),i=e?.serverIndex??0,l=T["PersonApi.updatePerson"]?.[i]?.url;return(c,d)=>b(a,O,R,e)(c,l||d)}}};let Gs=class extends Q{addImageToPerson(t,r,s,n){return v(this.configuration).addImageToPerson(t,r,s,n).then(o=>o(this.axios,this.basePath))}createPerson(t,r,s){return v(this.configuration).createPerson(t,r,s).then(n=>n(this.axios,this.basePath))}deleteImageOfPerson(t,r,s,n){return v(this.configuration).deleteImageOfPerson(t,r,s,n).then(o=>o(this.axios,this.basePath))}deletePerson(t,r,s){return v(this.configuration).deletePerson(t,r,s).then(n=>n(this.axios,this.basePath))}getAllGroupsByPersonId(t,r,s,n,o){return v(this.configuration).getAllGroupsByPersonId(t,r,s,n,o).then(a=>a(this.axios,this.basePath))}getAllImagesByPersonId(t,r,s,n,o){return v(this.configuration).getAllImagesByPersonId(t,r,s,n,o).then(a=>a(this.axios,this.basePath))}getImageOfPerson(t,r,s,n){return v(this.configuration).getImageOfPerson(t,r,s,n).then(o=>o(this.axios,this.basePath))}getPerson(t,r,s){return v(this.configuration).getPerson(t,r,s).then(n=>n(this.axios,this.basePath))}updatePerson(t,r,s,n){return v(this.configuration).updatePerson(t,r,s,n).then(o=>o(this.axios,this.basePath))}};class zt{constructor(t,r,s){this.superClass=new Gs(t,r,s)}async createPerson(t,r,s){const n={...t,metadata:t?.metadata?t.metadata:{}};return(await this.superClass.createPerson(n,r,s)).data}async addImageToPerson(t,r,s,n){return r?.image?.content&&typeof r.image.content!="string"&&(r.image.content=Ae(r.image.content)),(await this.superClass.addImageToPerson(t,r,s,n)).data}async deleteImageOfPerson(t,r,s,n){await this.superClass.deleteImageOfPerson(r,t,s,n)}async deletePerson(t,r,s){await this.superClass.deletePerson(t,r,s)}async getAllGroupsByPersonId(t,r,s,n,o){return(await this.superClass.getAllGroupsByPersonId(s,n,t,r,o)).data}async getAllImagesByPersonId(t,r,s,n,o){return(await this.superClass.getAllImagesByPersonId(s,n,t,r,o)).data}async getImageOfPerson(t,r,s,n){return(await this.superClass.getImageOfPerson(r,t,s,n)).data}async getPerson(t,r,s){return(await this.superClass.getPerson(t,r,s)).data}async updatePerson(t,r,s,n){await this.superClass.updatePerson(t,r,s,n)}}const Ms=function(e){return{search:async(t,r,s,n={})=>{m("search","searchRequest",t);const o="/api/search",a=new URL(o,P);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...n},c={},d={};s!==void 0&&(d.withImages=s),c["Content-Type"]="application/json",r!=null&&(c["X-RequestID"]=String(r)),I(a,d);let p=i&&i.headers?i.headers:{};return l.headers={...c,...p,...n.headers},l.data=M(t,l,e),{url:S(a),options:l}}}},vs=function(e){const t=Ms(e);return{async search(r,s,n,o){const a=await t.search(r,s,n,o),i=e?.serverIndex??0,l=T["SearchApi.search"]?.[i]?.url;return(c,d)=>b(a,O,R,e)(c,l||d)}}};let js=class extends Q{search(t,r,s,n){return vs(this.configuration).search(t,r,s,n).then(o=>o(this.axios,this.basePath))}};class Wt{constructor(t,r,s){this.superClass=new js(t,r,s)}async search(t,r,s,n){return t?.image?.content&&typeof t.image.content!="string"&&(t.image.content=Ae(t.image.content)),(await this.superClass.search(t,r,s,n)).data}}const Fs=function(e){return{deleteLivenessTransaction:async(t,r,s={})=>{m("deleteLivenessTransaction","transactionId",t),m("deleteLivenessTransaction","tag",r);const n="/api/v2/liveness",o=new URL(n,P);let a;e&&(a=e.baseOptions);const i={method:"DELETE",...a,...s},l={},c={};t!==void 0&&(c.transactionId=t),r!==void 0&&(c.tag=r),I(o,c);let d=a&&a.headers?a.headers:{};return i.headers={...l,...d,...s.headers},{url:S(o),options:i}},getLivenessTransactionInfo:async(t,r={})=>{m("getLivenessTransactionInfo","transactionId",t);const s="/api/v2/liveness",n=new URL(s,P);let o;e&&(o=e.baseOptions);const a={method:"GET",...o,...r},i={},l={};t!==void 0&&(l.transactionId=t),I(n,l);let c=o&&o.headers?o.headers:{};return a.headers={...i,...c,...r.headers},{url:S(n),options:a}}}},ct=function(e){const t=Fs(e);return{async deleteLivenessTransaction(r,s,n){const o=await t.deleteLivenessTransaction(r,s,n),a=e?.serverIndex??0,i=T["Liveness20Api.deleteLivenessTransaction"]?.[a]?.url;return(l,c)=>b(o,O,R,e)(l,i||c)},async getLivenessTransactionInfo(r,s){const n=await t.getLivenessTransactionInfo(r,s),o=e?.serverIndex??0,a=T["Liveness20Api.getLivenessTransactionInfo"]?.[o]?.url;return(i,l)=>b(n,O,R,e)(i,a||l)}}};let ks=class extends Q{deleteLivenessTransaction(t,r,s){return ct(this.configuration).deleteLivenessTransaction(t,r,s).then(n=>n(this.axios,this.basePath))}getLivenessTransactionInfo(t,r){return ct(this.configuration).getLivenessTransactionInfo(t,r).then(s=>s(this.axios,this.basePath))}};class Yt{constructor(t,r,s){this.superClass=new ks(t,r,s)}async getLivenessTransactionInfo(t,r){return(await this.superClass.getLivenessTransactionInfo(t,r)).data}}const qs=function(e){return{healthz:async(t,r={})=>{const s="/api/healthz",n=new URL(s,P);let o;e&&(o=e.baseOptions);const a={method:"GET",...o,...r},i={},l={};t!=null&&(i["X-RequestID"]=String(t)),I(n,l);let c=o&&o.headers?o.headers:{};return a.headers={...i,...c,...r.headers},{url:S(n),options:a}},readyz:async(t,r={})=>{const s="/api/readyz",n=new URL(s,P);let o;e&&(o=e.baseOptions);const a={method:"GET",...o,...r},i={},l={};t!=null&&(i["X-RequestID"]=String(t)),I(n,l);let c=o&&o.headers?o.headers:{};return a.headers={...i,...c,...r.headers},{url:S(n),options:a}}}},dt=function(e){const t=qs(e);return{async healthz(r,s){const n=await t.healthz(r,s),o=e?.serverIndex??0,a=T["HealthcheckApi.healthz"]?.[o]?.url;return(i,l)=>b(n,O,R,e)(i,a||l)},async readyz(r,s){const n=await t.readyz(r,s),o=e?.serverIndex??0,a=T["HealthcheckApi.readyz"]?.[o]?.url;return(i,l)=>b(n,O,R,e)(i,a||l)}}};let $s=class extends Q{healthz(t,r){return dt(this.configuration).healthz(t,r).then(s=>s(this.axios,this.basePath))}readyz(t,r){return dt(this.configuration).readyz(t,r).then(s=>s(this.axios,this.basePath))}};class Xt{constructor(t,r,s){this.superClass=new $s(t,r,s)}async healthz(t,r){return(await this.superClass.healthz(t,r)).data}async readyz(t,r){return(await this.superClass.readyz(t,r)).data}}class zs{constructor(t,r=R,s=O){this.basePath=r,this.axios=s,this.matchApi=new qt(t,r,s),this.groupApi=new $t(t,r,s),this.personApi=new zt(t,r,s),this.searchApi=new Wt(t,r,s),this.livenessApi=new Yt(t,r,s),this.healthcheckApi=new Xt(t,r,s)}}class Ws{constructor(t={}){this.apiKey=t.apiKey,this.username=t.username,this.password=t.password,this.accessToken=t.accessToken,this.basePath=t.basePath,this.serverIndex=t.serverIndex,this.baseOptions={...t.baseOptions,headers:{...t.baseOptions?.headers}},this.formDataCtor=t.formDataCtor}isJsonMime(t){const r=new RegExp("^(application/json|[^;/ ]+/[^;/ ]+[+]json)[ ]*(;.*)?$","i");return t!==null&&(r.test(t)||t.toLowerCase()==="application/json-patch+json")}}exports.Configuration=Ws;exports.FaceAttribute=xt;exports.FaceImageQualityAlignType=Dt;exports.FaceImageQualityGroups=Bt;exports.FaceImageQualityGroupsStrings=Ht;exports.FaceImageQualityStatus=Gt;exports.FaceQualityConfigName=Mt;exports.FaceQualityScenarios=vt;exports.FaceSDKResultCode=jt;exports.FaceSdk=zs;exports.FilterOp=Ft;exports.GroupApi=$t;exports.HealthcheckApi=Xt;exports.ImageSource=Me;exports.Liveness20Api=Yt;exports.LivenessType=kt;exports.MatchApi=qt;exports.PersonApi=zt;exports.SearchApi=Wt;
|
|
8
|
+
`,a+1),l=i===-1?"":o.slice(i+1);String(n.stack).endsWith(l)||(n.stack+=`
|
|
9
|
+
`+o)}}catch{}}throw n}}_request(t,r){typeof t=="string"?(r=r||{},r.url=t):r=t||{},r=ee(this.defaults,r);const{transitional:n,paramsSerializer:s,headers:o}=r;n!==void 0&&Se.assertOptions(n,{silentJSONParsing:G.transitional(G.boolean),forcedJSONParsing:G.transitional(G.boolean),clarifyTimeoutError:G.transitional(G.boolean),legacyInterceptorReqResOrdering:G.transitional(G.boolean)},!1),s!=null&&(u.isFunction(s)?r.paramsSerializer={serialize:s}:Se.assertOptions(s,{encode:G.function,serialize:G.function},!0)),r.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?r.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:r.allowAbsoluteUrls=!0),Se.assertOptions(r,{baseUrl:G.spelling("baseURL"),withXsrfToken:G.spelling("withXSRFToken")},!0),r.method=(r.method||this.defaults.method||"get").toLowerCase();let a=o&&u.merge(o.common,o[r.method]);o&&u.forEach(["delete","get","head","post","put","patch","query","common"],m=>{delete o[m]}),r.headers=U.concat(a,o);const i=[];let l=!0;this.interceptors.request.forEach(function(E){if(typeof E.runWhen=="function"&&E.runWhen(r)===!1)return;l=l&&E.synchronous;const h=r.transitional||We;h&&h.legacyInterceptorReqResOrdering?i.unshift(E.fulfilled,E.rejected):i.push(E.fulfilled,E.rejected)});const c=[];this.interceptors.response.forEach(function(E){c.push(E.fulfilled,E.rejected)});let d,p=0,_;if(!l){const m=[Et.bind(this),void 0];for(m.unshift(...i),m.push(...c),_=m.length,d=Promise.resolve(r);p<_;)d=d.then(m[p++],m[p++]);return d}_=i.length;let R=r;for(;p<_;){const m=i[p++],E=i[p++];try{R=m(R)}catch(h){E.call(this,h);break}}try{d=Et.call(this,R)}catch(m){return Promise.reject(m)}for(p=0,_=c.length;p<_;)d=d.then(c[p++],c[p++]);return d}getUri(t){t=ee(this.defaults,t);const r=Ut(t.baseURL,t.url,t.allowAbsoluteUrls);return gt(r,t.params,t.paramsSerializer)}};u.forEach(["delete","get","head","options"],function(t){Q.prototype[t]=function(r,n){return this.request(ee(n||{},{method:t,url:r,data:(n||{}).data}))}});u.forEach(["post","put","patch","query"],function(t){function r(n){return function(o,a,i){return this.request(ee(i||{},{method:t,headers:n?{"Content-Type":"multipart/form-data"}:{},url:o,data:a}))}}Q.prototype[t]=r(),t!=="query"&&(Q.prototype[t+"Form"]=r(!0))});let kn=class Gt{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let r;this.promise=new Promise(function(o){r=o});const n=this;this.promise.then(s=>{if(!n._listeners)return;let o=n._listeners.length;for(;o-- >0;)n._listeners[o](s);n._listeners=null}),this.promise.then=s=>{let o;const a=new Promise(i=>{n.subscribe(i),o=i}).then(s);return a.cancel=function(){n.unsubscribe(o)},a},t(function(o,a,i){n.reason||(n.reason=new Ee(o,a,i),r(n.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const r=this._listeners.indexOf(t);r!==-1&&this._listeners.splice(r,1)}toAbortSignal(){const t=new AbortController,r=n=>{t.abort(n)};return this.subscribe(r),t.signal.unsubscribe=()=>this.unsubscribe(r),t.signal}static source(){let t;return{token:new Gt(function(s){t=s}),cancel:t}}};function qn(e){return function(r){return e.apply(null,r)}}function zn(e){return u.isObject(e)&&e.isAxiosError===!0}const qe={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(qe).forEach(([e,t])=>{qe[t]=e});function Mt(e){const t=new Q(e),r=Rt(Q.prototype.request,t);return u.extend(r,Q.prototype,t,{allOwnKeys:!0}),u.extend(r,t,null,{allOwnKeys:!0}),r.create=function(s){return Mt(ee(e,s))},r}const O=Mt(fe);O.Axios=Q;O.CanceledError=Ee;O.CancelToken=kn;O.isCancel=xt;O.VERSION=Ye;O.toFormData=ge;O.AxiosError=f;O.Cancel=O.CanceledError;O.all=function(t){return Promise.all(t)};O.spread=qn;O.isAxiosError=zn;O.mergeConfig=ee;O.AxiosHeaders=U;O.formToJSON=e=>Nt(u.isHTMLForm(e)?new FormData(e):e);O.getAdapter=Ht.getAdapter;O.HttpStatusCode=qe;O.default=O;const{Axios:ps,AxiosError:hs,CanceledError:fs,isCancel:Es,CancelToken:As,VERSION:Os,all:_s,Cancel:Rs,isAxiosError:ms,spread:Ts,toFormData:Ps,AxiosHeaders:Ss,HttpStatusCode:Is,formToJSON:ys,getAdapter:bs,mergeConfig:ws,create:Cs}=O,b="https://faceapi.regulaforensics.com".replace(/\/+$/,"");class ae{constructor(t,r=b,n=O){this.basePath=r,this.axios=n,t&&(this.configuration=t,this.basePath=t.basePath??r)}}class $n extends Error{constructor(t,r){super(r),this.field=t,this.name="RequiredError"}}const w={},C="https://example.com",S=function(e,t,r){if(r==null)throw new $n(t,`Required parameter ${t} was null or undefined when calling ${e}.`)};function ze(e,t,r=""){t!=null&&(typeof t=="object"?Array.isArray(t)?t.forEach(n=>ze(e,n,r)):Object.keys(t).forEach(n=>ze(e,t[n],`${r}${r!==""?".":""}${n}`)):e.has(r)?e.append(r,t):e.set(r,t))}const L=function(e,...t){const r=new URLSearchParams(e.search);ze(r,t),e.search=r.toString()},j=function(e,t,r){const n=typeof e!="string";return(n&&r&&r.isJsonMime?r.isJsonMime(t.headers["Content-Type"]):n)?JSON.stringify(e!==void 0?e:{}):e||""},g=function(e){return e.pathname+e.search+e.hash},N=function(e,t,r,n){return(s=t,o=r)=>{const a={...e.options,url:(s.defaults.baseURL?"":n?.basePath??o)+e.url};return s.request(a)}},Wn=function(e){return{detect:async(t,r,n={})=>{S("detect","detectRequest",t);const s="/api/detect",o=new URL(s,C);let a;e&&(a=e.baseOptions);const i={method:"POST",...a,...n},l={},c={};l["Content-Type"]="application/json",r!=null&&(l["X-RequestID"]=String(r)),L(o,c);let d=a&&a.headers?a.headers:{};return i.headers={...l,...d,...n.headers},i.data=j(t,i,e),{url:g(o),options:i}},match:async(t,r,n={})=>{S("match","matchRequest",t);const s="/api/match",o=new URL(s,C);let a;e&&(a=e.baseOptions);const i={method:"POST",...a,...n},l={},c={};l["Content-Type"]="application/json",r!=null&&(l["X-RequestID"]=String(r)),L(o,c);let d=a&&a.headers?a.headers:{};return i.headers={...l,...d,...n.headers},i.data=j(t,i,e),{url:g(o),options:i}},matchAndSearch:async(t,r,n={})=>{S("matchAndSearch","matchAndSearchRequest",t);const s="/api/match_and_search",o=new URL(s,C);let a;e&&(a=e.baseOptions);const i={method:"POST",...a,...n},l={},c={};l["Content-Type"]="application/json",r!=null&&(l["X-RequestID"]=String(r)),L(o,c);let d=a&&a.headers?a.headers:{};return i.headers={...l,...d,...n.headers},i.data=j(t,i,e),{url:g(o),options:i}}}},Me=function(e){const t=Wn(e);return{async detect(r,n,s){const o=await t.detect(r,n,s),a=e?.serverIndex??0,i=w["MatchApi.detect"]?.[a]?.url;return(l,c)=>N(o,O,b,e)(l,i||c)},async match(r,n,s){const o=await t.match(r,n,s),a=e?.serverIndex??0,i=w["MatchApi.match"]?.[a]?.url;return(l,c)=>N(o,O,b,e)(l,i||c)},async matchAndSearch(r,n,s){const o=await t.matchAndSearch(r,n,s),a=e?.serverIndex??0,i=w["MatchApi.matchAndSearch"]?.[a]?.url;return(l,c)=>N(o,O,b,e)(l,i||c)}}};let Xn=class extends ae{detect(t,r,n){return Me(this.configuration).detect(t,r,n).then(s=>s(this.axios,this.basePath))}match(t,r,n){return Me(this.configuration).match(t,r,n).then(s=>s(this.axios,this.basePath))}matchAndSearch(t,r,n){return Me(this.configuration).matchAndSearch(t,r,n).then(s=>s(this.axios,this.basePath))}};var vt=(e=>(e.AGE="Age",e.EMOTION="Emotion",e.EYE_LEFT="EyeLeft",e.EYE_RIGHT="EyeRight",e.SMILE="Smile",e.GLASSES="Glasses",e.HEAD_COVERING="HeadCovering",e.FOREHEAD_COVERING="ForeheadCovering",e.MOUTH="Mouth",e.MEDICAL_MASK="MedicalMask",e.OCCLUSION="Occlusion",e.STRONG_MAKEUP="StrongMakeup",e.HEADPHONES="Headphones",e))(vt||{}),Ft=(e=>(e[e.ALIGN_3x4=0]="ALIGN_3x4",e[e.ALIGN_4x5=1]="ALIGN_4x5",e[e.ALIGN_2x3=2]="ALIGN_2x3",e[e.ALIGN_1x1=3]="ALIGN_1x1",e[e.ALIGN_7x9=4]="ALIGN_7x9",e))(Ft||{}),jt=(e=>(e[e.IMAGE_CHARACTERISTICS=1]="IMAGE_CHARACTERISTICS",e[e.HEAD_SIZE_AND_POSITIONS=2]="HEAD_SIZE_AND_POSITIONS",e[e.FACE_QUALITY=3]="FACE_QUALITY",e[e.EYES_CHARACTERISTICS=4]="EYES_CHARACTERISTICS",e[e.SHADOWS_AND_LIGHTNING=5]="SHADOWS_AND_LIGHTNING",e[e.POSE_AND_EXPRESSION=6]="POSE_AND_EXPRESSION",e[e.HEAD_OCCLUSION=7]="HEAD_OCCLUSION",e[e.BACKGROUND=8]="BACKGROUND",e))(jt||{}),kt=(e=>(e.IMAGE_CHARACTERISTICS="ImageCharacteristics",e.HEAD_SIZE_AND_POSITIONS="HeadSizeAndPosition",e.FACE_QUALITY="FaceQuality",e.EYES_CHARACTERISTICS="EyesCharacteristics",e.SHADOWS_AND_LIGHTNING="ShadowsAndLightning",e.POSE_AND_EXPRESSION="PoseAndExpression",e.HEAD_OCCLUSION="HeadOcclusion",e.BACKGROUND="Background",e))(kt||{}),qt=(e=>(e[e.QUALITY_STATUS_FALSE=0]="QUALITY_STATUS_FALSE",e[e.QUALITY_STATUS_TRUE=1]="QUALITY_STATUS_TRUE",e[e.QUALITY_STATUS_UNDETERMINED=2]="QUALITY_STATUS_UNDETERMINED",e))(qt||{}),zt=(e=>(e.IMAGE_WIDTH="ImageWidth",e.IMAGE_HEIGHT="ImageHeight",e.IMAGE_WIDTH_TO_HEIGHT="ImageWidthToHeight",e.IMAGE_CHANNELS_NUMBER="ImageChannelsNumber",e.PADDING_RATIO="PaddingRatio",e.FACE_MID_POINT_HORIZONTAL_POSITION="FaceMidPointHorizontalPosition",e.FACE_MID_POINT_VERTICAL_POSITION="FaceMidPointVerticalPosition",e.HEAD_WIDTH_RATIO="HeadWidthRatio",e.HEAD_HEIGHT_RATIO="HeadHeightRatio",e.EYES_DISTANCE="EyesDistance",e.YAW="Yaw",e.PITCH="Pitch",e.ROLL="Roll",e.BLUR_LEVEL="BlurLevel",e.NOISE_LEVEL="NoiseLevel",e.EYE_RIGHT_CLOSED="EyeRightClosed",e.EYE_LEFT_CLOSED="EyeLeftClosed",e.EYE_RIGHT_OCCLUDED="EyeRightOccluded",e.EYE_LEFT_OCCLUDED="EyeLeftOccluded",e.EYES_RED="EyesRed",e.EYE_RIGHT_COVERED_WITH_HAIR="EyeRightCoveredWithHair",e.EYE_LEFT_COVERED_WITH_HAIR="EyeLeftCoveredWithHair",e.OFF_GAZE="OffGaze",e.FACE_DYNAMIC_RANGE="FaceDynamicRange",e.UNNATURAL_SKIN_TONE="UnnaturalSkinTone",e.TOO_DARK="TooDark",e.TOO_LIGHT="TooLight",e.FACE_GLARE="FaceGlare",e.SHADOWS_ON_FACE="ShadowsOnFace",e.DARK_GLASSES="DarkGlasses",e.REFLECTION_ON_GLASSES="ReflectionOnGlasses",e.FRAMES_TOO_HEAVY="FramesTooHeavy",e.FACE_OCCLUDED="FaceOccluded",e.HEAD_COVERING="HeadCovering",e.BACKGROUND_UNIFORMITY="BackgroundUniformity",e.SHADOWS_ON_BACKGROUND="ShadowsOnBackground",e.OTHER_FACES="OtherFaces",e.SHOULDERS_POSE="ShouldersPose",e.EXPRESSION_LEVEL="ExpressionLevel",e.MOUTH_OPEN="MouthOpen",e.FOREHEAD_COVERING="ForeheadCovering",e.SMILE="Smile",e.STRONG_MAKEUP="StrongMakeup",e.HEADPHONES="Headphones",e.MEDICAL_MASK="MedicalMask",e.BACKGROUND_COLOR_MATCH="BackgroundColorMatch",e.ART_FACE="ArtFace",e.CONTACT_LENSES="ContactLenses",e))(zt||{}),$t=(e=>(e.OLD_MODE="OldMode",e.QUALITY_FULL="QualityFull",e.QUALITY_ICAO="QualityICAO",e.QUALITY_VISA_SCHENGEN="QualityVisaSchengen",e.QUALITY_VISA_USA="QualityVisaUSA",e.CROP_CENTRAL_FACE="CropCentralFace",e.CROP_ALL_FACES="CropAllFaces",e.THUMBNAIL="Thumbnail",e.ATTRIBUTES_ALL="AttributesAll",e.EMPTY="",e))($t||{}),Wt=(e=>(e[e.FACER_OK=0]="FACER_OK",e[e.FR_IMAGE_EMPTY=1]="FR_IMAGE_EMPTY",e[e.FR_FACE_NOT_DETECTED=2]="FR_FACE_NOT_DETECTED",e[e.FR_LANDMARKS_NOT_DETECTED=3]="FR_LANDMARKS_NOT_DETECTED",e[e.FR_FACE_ALIGHNER_FAILED=4]="FR_FACE_ALIGHNER_FAILED",e[e.FR_DESCRIPTOR_EXTRACTOR_ERROR=5]="FR_DESCRIPTOR_EXTRACTOR_ERROR",e[e.FR_IMAGE_DECODE_ERROR=6]="FR_IMAGE_DECODE_ERROR",e[e.FR_INTERNAL_ERROR=7]="FR_INTERNAL_ERROR",e[e.FACER_CONFIG_ERROR=199]="FACER_CONFIG_ERROR",e[e.FACER_NO_LICENSE=200]="FACER_NO_LICENSE",e[e.FACER_IS_NOT_INITIALIZED=201]="FACER_IS_NOT_INITIALIZED",e[e.FACER_COMMAND_IS_NOT_SUPPORTED=202]="FACER_COMMAND_IS_NOT_SUPPORTED",e[e.FACER_COMMAND_PARAMS_READ_ERROR=203]="FACER_COMMAND_PARAMS_READ_ERROR",e[e.FACER_LESS_THAN_TWO_IMAGES_IN_REQUEST=224]="FACER_LESS_THAN_TWO_IMAGES_IN_REQUEST",e[e.FACER_VIDEO_DECODE_ERROR=227]="FACER_VIDEO_DECODE_ERROR",e[e.FACER_NOT_ENOUGH_FRAMES=228]="FACER_NOT_ENOUGH_FRAMES",e[e.FACER_OUTPUT_IS_NOT_DEFINED=229]="FACER_OUTPUT_IS_NOT_DEFINED",e[e.FACER_CLOSED_EYES_DETECTED=230]="FACER_CLOSED_EYES_DETECTED",e[e.FACER_LOW_QUALITY=231]="FACER_LOW_QUALITY",e[e.FACER_HIGH_ASYMMETRY=232]="FACER_HIGH_ASYMMETRY",e[e.FACER_FACE_OVER_EMOTIONAL=233]="FACER_FACE_OVER_EMOTIONAL",e[e.FACER_SUNGLASSES_DETECTED=234]="FACER_SUNGLASSES_DETECTED",e[e.FACER_SMALL_AGE=235]="FACER_SMALL_AGE",e[e.FACER_HEADDRESS_DETECTED=236]="FACER_HEADDRESS_DETECTED",e[e.FACER_FACES_NOT_MATCHED=237]="FACER_FACES_NOT_MATCHED",e[e.FACER_IMAGES_COUNT_LIMIT_EXCEEDED=238]="FACER_IMAGES_COUNT_LIMIT_EXCEEDED",e[e.FACER_MEDICINE_MASK_DETECTED=239]="FACER_MEDICINE_MASK_DETECTED",e[e.FACER_OCCLUSION_DETECTED=240]="FACER_OCCLUSION_DETECTED",e[e.FACER_FOREHEAD_GLASSES_DETECTED=242]="FACER_FOREHEAD_GLASSES_DETECTED",e[e.FACER_MOUTH_OPENED=243]="FACER_MOUTH_OPENED",e[e.FACER_ART_MASK_DETECTED=244]="FACER_ART_MASK_DETECTED",e[e.FACER_ELECTRONIC_DEVICE_DETECTED=245]="FACER_ELECTRONIC_DEVICE_DETECTED",e[e.FACER_TRACK_BREAK=246]="FACER_TRACK_BREAK",e[e.FACER_WRONG_GEO=247]="FACER_WRONG_GEO",e[e.FACER_WRONG_OF=248]="FACER_WRONG_OF",e[e.FACER_WRONG_VIEW=249]="FACER_WRONG_VIEW",e[e.FACER_TIMEOUT_LIVENESS_TRANSACTION=250]="FACER_TIMEOUT_LIVENESS_TRANSACTION",e[e.FACER_FAILED_LIVENESS_TRANSACTION=251]="FACER_FAILED_LIVENESS_TRANSACTION",e[e.FACER_ABORTED_LIVENESS_TRANSACTION=252]="FACER_ABORTED_LIVENESS_TRANSACTION",e[e.FACER_GENERAL_ERROR=253]="FACER_GENERAL_ERROR",e[e.FACER_PASSIVE_LIVENESS_FAIL=254]="FACER_PASSIVE_LIVENESS_FAIL",e))(Wt||{}),Xt=(e=>(e.IN="in",e.NOT_IN="nin",e))(Xt||{}),Ze=(e=>(e[e.DOCUMENT_PRINTED=1]="DOCUMENT_PRINTED",e[e.DOCUMENT_RFID=2]="DOCUMENT_RFID",e[e.LIVE=3]="LIVE",e[e.DOCUMENT_WITH_LIVE=4]="DOCUMENT_WITH_LIVE",e[e.EXTERNAL=5]="EXTERNAL",e[e.GHOST=6]="GHOST",e[e.BARCODE=7]="BARCODE",e))(Ze||{}),Yt=(e=>(e[e.ACTIVE=0]="ACTIVE",e[e.PASSIVE=1]="PASSIVE",e))(Yt||{}),ne="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Yn=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(var me=0;me<ne.length;me++)Yn[ne.charCodeAt(me)]=me;var ye=function(e){var t=new Uint8Array(e),r,n=t.length,s="";for(r=0;r<n;r+=3)s+=ne[t[r]>>2],s+=ne[(t[r]&3)<<4|t[r+1]>>4],s+=ne[(t[r+1]&15)<<2|t[r+2]>>6],s+=ne[t[r+2]&63];return n%3===2?s=s.substring(0,s.length-1)+"=":n%3===1&&(s=s.substring(0,s.length-2)+"=="),s};class Jt{constructor(t,r,n){this.superClass=new Xn(t,r,n)}async match(t,r,n){for(const o of t.images)o.type||(o.type=Ze.LIVE),typeof o.data!="string"&&(o.data=ye(o.data));return(await this.superClass.match(t,r,n)).data}async detect(t,r,n){return t.image&&typeof t.image!="string"&&(t.image=ye(t.image)),(await this.superClass.detect(t,r,n)).data}}const Jn=function(e){return{createGroup:async(t,r,n={})=>{S("createGroup","groupToCreate",t);const s="/api/groups",o=new URL(s,C);let a;e&&(a=e.baseOptions);const i={method:"POST",...a,...n},l={},c={};l["Content-Type"]="application/json",r!=null&&(l["X-RequestID"]=String(r)),L(o,c);let d=a&&a.headers?a.headers:{};return i.headers={...l,...d,...n.headers},i.data=j(t,i,e),{url:g(o),options:i}},deleteGroup:async(t,r,n={})=>{S("deleteGroup","groupId",t);const s="/api/groups/{groupId}".replace("{groupId}",encodeURIComponent(String(t))),o=new URL(s,C);let a;e&&(a=e.baseOptions);const i={method:"DELETE",...a,...n},l={},c={};r!=null&&(l["X-RequestID"]=String(r)),L(o,c);let d=a&&a.headers?a.headers:{};return i.headers={...l,...d,...n.headers},{url:g(o),options:i}},getAllGroups:async(t,r,n,s={})=>{const o="/api/groups",a=new URL(o,C);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...s},c={},d={};r!==void 0&&(d.page=r),n!==void 0&&(d.size=n),t!=null&&(c["X-RequestID"]=String(t)),L(a,d);let p=i&&i.headers?i.headers:{};return l.headers={...c,...p,...s.headers},{url:g(a),options:l}},getAllPersonsByGroupId:async(t,r,n,s,o={})=>{S("getAllPersonsByGroupId","groupId",t);const a="/api/groups/{groupId}/persons".replace("{groupId}",encodeURIComponent(String(t))),i=new URL(a,C);let l;e&&(l=e.baseOptions);const c={method:"GET",...l,...o},d={},p={};n!==void 0&&(p.page=n),s!==void 0&&(p.size=s),r!=null&&(d["X-RequestID"]=String(r)),L(i,p);let _=l&&l.headers?l.headers:{};return c.headers={...d,..._,...o.headers},{url:g(i),options:c}},getGroup:async(t,r,n={})=>{S("getGroup","groupId",t);const s="/api/groups/{groupId}".replace("{groupId}",encodeURIComponent(String(t))),o=new URL(s,C);let a;e&&(a=e.baseOptions);const i={method:"GET",...a,...n},l={},c={};r!=null&&(l["X-RequestID"]=String(r)),L(o,c);let d=a&&a.headers?a.headers:{};return i.headers={...l,...d,...n.headers},{url:g(o),options:i}},updateGroup:async(t,r,n,s={})=>{S("updateGroup","groupId",t),S("updateGroup","groupToCreate",r);const o="/api/groups/{groupId}".replace("{groupId}",encodeURIComponent(String(t))),a=new URL(o,C);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...s},c={},d={};c["Content-Type"]="application/json",n!=null&&(c["X-RequestID"]=String(n)),L(a,d);let p=i&&i.headers?i.headers:{};return l.headers={...c,...p,...s.headers},l.data=j(r,l,e),{url:g(a),options:l}},updatePersonsInGroup:async(t,r,n,s={})=>{S("updatePersonsInGroup","groupId",t),S("updatePersonsInGroup","updateGroup",r);const o="/api/groups/{groupId}/persons".replace("{groupId}",encodeURIComponent(String(t))),a=new URL(o,C);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...s},c={},d={};c["Content-Type"]="application/json",n!=null&&(c["X-RequestID"]=String(n)),L(a,d);let p=i&&i.headers?i.headers:{};return l.headers={...c,...p,...s.headers},l.data=j(r,l,e),{url:g(a),options:l}}}},Z=function(e){const t=Jn(e);return{async createGroup(r,n,s){const o=await t.createGroup(r,n,s),a=e?.serverIndex??0,i=w["GroupApi.createGroup"]?.[a]?.url;return(l,c)=>N(o,O,b,e)(l,i||c)},async deleteGroup(r,n,s){const o=await t.deleteGroup(r,n,s),a=e?.serverIndex??0,i=w["GroupApi.deleteGroup"]?.[a]?.url;return(l,c)=>N(o,O,b,e)(l,i||c)},async getAllGroups(r,n,s,o){const a=await t.getAllGroups(r,n,s,o),i=e?.serverIndex??0,l=w["GroupApi.getAllGroups"]?.[i]?.url;return(c,d)=>N(a,O,b,e)(c,l||d)},async getAllPersonsByGroupId(r,n,s,o,a){const i=await t.getAllPersonsByGroupId(r,n,s,o,a),l=e?.serverIndex??0,c=w["GroupApi.getAllPersonsByGroupId"]?.[l]?.url;return(d,p)=>N(i,O,b,e)(d,c||p)},async getGroup(r,n,s){const o=await t.getGroup(r,n,s),a=e?.serverIndex??0,i=w["GroupApi.getGroup"]?.[a]?.url;return(l,c)=>N(o,O,b,e)(l,i||c)},async updateGroup(r,n,s,o){const a=await t.updateGroup(r,n,s,o),i=e?.serverIndex??0,l=w["GroupApi.updateGroup"]?.[i]?.url;return(c,d)=>N(a,O,b,e)(c,l||d)},async updatePersonsInGroup(r,n,s,o){const a=await t.updatePersonsInGroup(r,n,s,o),i=e?.serverIndex??0,l=w["GroupApi.updatePersonsInGroup"]?.[i]?.url;return(c,d)=>N(a,O,b,e)(c,l||d)}}};let Zn=class extends ae{createGroup(t,r,n){return Z(this.configuration).createGroup(t,r,n).then(s=>s(this.axios,this.basePath))}deleteGroup(t,r,n){return Z(this.configuration).deleteGroup(t,r,n).then(s=>s(this.axios,this.basePath))}getAllGroups(t,r,n,s){return Z(this.configuration).getAllGroups(t,r,n,s).then(o=>o(this.axios,this.basePath))}getAllPersonsByGroupId(t,r,n,s,o){return Z(this.configuration).getAllPersonsByGroupId(t,r,n,s,o).then(a=>a(this.axios,this.basePath))}getGroup(t,r,n){return Z(this.configuration).getGroup(t,r,n).then(s=>s(this.axios,this.basePath))}updateGroup(t,r,n,s){return Z(this.configuration).updateGroup(t,r,n,s).then(o=>o(this.axios,this.basePath))}updatePersonsInGroup(t,r,n,s){return Z(this.configuration).updatePersonsInGroup(t,r,n,s).then(o=>o(this.axios,this.basePath))}};class Zt{constructor(t,r,n){this.superClass=new Zn(t,r,n)}async createGroup(t,r,n){const s={...t,metadata:t?.metadata?t.metadata:{}};return(await this.superClass.createGroup(s,r,n)).data}async deleteGroup(t,r,n){await this.superClass.deleteGroup(t,r,n)}async getAllGroups(t,r,n,s){return(await this.superClass.getAllGroups(n,t,r,s)).data}async getAllPersonsByGroupId(t,r,n,s,o){return(await this.superClass.getAllPersonsByGroupId(n,s,t,r,o)).data}async getGroup(t,r,n){return(await this.superClass.getGroup(t,r,n)).data}async updateGroup(t,r,n,s){await this.superClass.updateGroup(t,r,n,s)}async updatePersonsInGroup(t,r,n,s){await this.superClass.updatePersonsInGroup(t,r,n,s)}}const Kn=function(e){return{addImageToPerson:async(t,r,n,s={})=>{S("addImageToPerson","personId",t),S("addImageToPerson","addImageToPersonRequest",r);const o="/api/persons/{personId}/images".replace("{personId}",encodeURIComponent(String(t))),a=new URL(o,C);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...s},c={},d={};c["Content-Type"]="application/json",n!=null&&(c["X-RequestID"]=String(n)),L(a,d);let p=i&&i.headers?i.headers:{};return l.headers={...c,...p,...s.headers},l.data=j(r,l,e),{url:g(a),options:l}},createPerson:async(t,r,n={})=>{S("createPerson","personFields",t);const s="/api/persons",o=new URL(s,C);let a;e&&(a=e.baseOptions);const i={method:"POST",...a,...n},l={},c={};l["Content-Type"]="application/json",r!=null&&(l["X-RequestID"]=String(r)),L(o,c);let d=a&&a.headers?a.headers:{};return i.headers={...l,...d,...n.headers},i.data=j(t,i,e),{url:g(o),options:i}},deleteImageOfPerson:async(t,r,n,s={})=>{S("deleteImageOfPerson","personId",t),S("deleteImageOfPerson","imageId",r);const o="/api/persons/{personId}/images/{imageId}".replace("{personId}",encodeURIComponent(String(t))).replace("{imageId}",encodeURIComponent(String(r))),a=new URL(o,C);let i;e&&(i=e.baseOptions);const l={method:"DELETE",...i,...s},c={},d={};n!=null&&(c["X-RequestID"]=String(n)),L(a,d);let p=i&&i.headers?i.headers:{};return l.headers={...c,...p,...s.headers},{url:g(a),options:l}},deletePerson:async(t,r,n={})=>{S("deletePerson","personId",t);const s="/api/persons/{personId}".replace("{personId}",encodeURIComponent(String(t))),o=new URL(s,C);let a;e&&(a=e.baseOptions);const i={method:"DELETE",...a,...n},l={},c={};r!=null&&(l["X-RequestID"]=String(r)),L(o,c);let d=a&&a.headers?a.headers:{};return i.headers={...l,...d,...n.headers},{url:g(o),options:i}},getAllGroupsByPersonId:async(t,r,n,s,o={})=>{S("getAllGroupsByPersonId","personId",t);const a="/api/persons/{personId}/groups".replace("{personId}",encodeURIComponent(String(t))),i=new URL(a,C);let l;e&&(l=e.baseOptions);const c={method:"GET",...l,...o},d={},p={};n!==void 0&&(p.page=n),s!==void 0&&(p.size=s),r!=null&&(d["X-RequestID"]=String(r)),L(i,p);let _=l&&l.headers?l.headers:{};return c.headers={...d,..._,...o.headers},{url:g(i),options:c}},getAllImagesByPersonId:async(t,r,n,s,o={})=>{S("getAllImagesByPersonId","personId",t);const a="/api/persons/{personId}/images".replace("{personId}",encodeURIComponent(String(t))),i=new URL(a,C);let l;e&&(l=e.baseOptions);const c={method:"GET",...l,...o},d={},p={};n!==void 0&&(p.page=n),s!==void 0&&(p.size=s),r!=null&&(d["X-RequestID"]=String(r)),L(i,p);let _=l&&l.headers?l.headers:{};return c.headers={...d,..._,...o.headers},{url:g(i),options:c}},getImageOfPerson:async(t,r,n,s={})=>{S("getImageOfPerson","personId",t),S("getImageOfPerson","imageId",r);const o="/api/persons/{personId}/images/{imageId}".replace("{personId}",encodeURIComponent(String(t))).replace("{imageId}",encodeURIComponent(String(r))),a=new URL(o,C);let i;e&&(i=e.baseOptions);const l={method:"GET",...i,...s},c={},d={};n!=null&&(c["X-RequestID"]=String(n)),L(a,d);let p=i&&i.headers?i.headers:{};return l.headers={...c,...p,...s.headers},{url:g(a),options:l}},getPerson:async(t,r,n={})=>{S("getPerson","personId",t);const s="/api/persons/{personId}".replace("{personId}",encodeURIComponent(String(t))),o=new URL(s,C);let a;e&&(a=e.baseOptions);const i={method:"GET",...a,...n},l={},c={};r!=null&&(l["X-RequestID"]=String(r)),L(o,c);let d=a&&a.headers?a.headers:{};return i.headers={...l,...d,...n.headers},{url:g(o),options:i}},updatePerson:async(t,r,n,s={})=>{S("updatePerson","personId",t),S("updatePerson","personToUpdateFields",r);const o="/api/persons/{personId}".replace("{personId}",encodeURIComponent(String(t))),a=new URL(o,C);let i;e&&(i=e.baseOptions);const l={method:"PUT",...i,...s},c={},d={};c["Content-Type"]="application/json",n!=null&&(c["X-RequestID"]=String(n)),L(a,d);let p=i&&i.headers?i.headers:{};return l.headers={...c,...p,...s.headers},l.data=j(r,l,e),{url:g(a),options:l}}}},q=function(e){const t=Kn(e);return{async addImageToPerson(r,n,s,o){const a=await t.addImageToPerson(r,n,s,o),i=e?.serverIndex??0,l=w["PersonApi.addImageToPerson"]?.[i]?.url;return(c,d)=>N(a,O,b,e)(c,l||d)},async createPerson(r,n,s){const o=await t.createPerson(r,n,s),a=e?.serverIndex??0,i=w["PersonApi.createPerson"]?.[a]?.url;return(l,c)=>N(o,O,b,e)(l,i||c)},async deleteImageOfPerson(r,n,s,o){const a=await t.deleteImageOfPerson(r,n,s,o),i=e?.serverIndex??0,l=w["PersonApi.deleteImageOfPerson"]?.[i]?.url;return(c,d)=>N(a,O,b,e)(c,l||d)},async deletePerson(r,n,s){const o=await t.deletePerson(r,n,s),a=e?.serverIndex??0,i=w["PersonApi.deletePerson"]?.[a]?.url;return(l,c)=>N(o,O,b,e)(l,i||c)},async getAllGroupsByPersonId(r,n,s,o,a){const i=await t.getAllGroupsByPersonId(r,n,s,o,a),l=e?.serverIndex??0,c=w["PersonApi.getAllGroupsByPersonId"]?.[l]?.url;return(d,p)=>N(i,O,b,e)(d,c||p)},async getAllImagesByPersonId(r,n,s,o,a){const i=await t.getAllImagesByPersonId(r,n,s,o,a),l=e?.serverIndex??0,c=w["PersonApi.getAllImagesByPersonId"]?.[l]?.url;return(d,p)=>N(i,O,b,e)(d,c||p)},async getImageOfPerson(r,n,s,o){const a=await t.getImageOfPerson(r,n,s,o),i=e?.serverIndex??0,l=w["PersonApi.getImageOfPerson"]?.[i]?.url;return(c,d)=>N(a,O,b,e)(c,l||d)},async getPerson(r,n,s){const o=await t.getPerson(r,n,s),a=e?.serverIndex??0,i=w["PersonApi.getPerson"]?.[a]?.url;return(l,c)=>N(o,O,b,e)(l,i||c)},async updatePerson(r,n,s,o){const a=await t.updatePerson(r,n,s,o),i=e?.serverIndex??0,l=w["PersonApi.updatePerson"]?.[i]?.url;return(c,d)=>N(a,O,b,e)(c,l||d)}}};let Qn=class extends ae{addImageToPerson(t,r,n,s){return q(this.configuration).addImageToPerson(t,r,n,s).then(o=>o(this.axios,this.basePath))}createPerson(t,r,n){return q(this.configuration).createPerson(t,r,n).then(s=>s(this.axios,this.basePath))}deleteImageOfPerson(t,r,n,s){return q(this.configuration).deleteImageOfPerson(t,r,n,s).then(o=>o(this.axios,this.basePath))}deletePerson(t,r,n){return q(this.configuration).deletePerson(t,r,n).then(s=>s(this.axios,this.basePath))}getAllGroupsByPersonId(t,r,n,s,o){return q(this.configuration).getAllGroupsByPersonId(t,r,n,s,o).then(a=>a(this.axios,this.basePath))}getAllImagesByPersonId(t,r,n,s,o){return q(this.configuration).getAllImagesByPersonId(t,r,n,s,o).then(a=>a(this.axios,this.basePath))}getImageOfPerson(t,r,n,s){return q(this.configuration).getImageOfPerson(t,r,n,s).then(o=>o(this.axios,this.basePath))}getPerson(t,r,n){return q(this.configuration).getPerson(t,r,n).then(s=>s(this.axios,this.basePath))}updatePerson(t,r,n,s){return q(this.configuration).updatePerson(t,r,n,s).then(o=>o(this.axios,this.basePath))}};class Kt{constructor(t,r,n){this.superClass=new Qn(t,r,n)}async createPerson(t,r,n){const s={...t,metadata:t?.metadata?t.metadata:{}};return(await this.superClass.createPerson(s,r,n)).data}async addImageToPerson(t,r,n,s){return r?.image?.content&&typeof r.image.content!="string"&&(r.image.content=ye(r.image.content)),(await this.superClass.addImageToPerson(t,r,n,s)).data}async deleteImageOfPerson(t,r,n,s){await this.superClass.deleteImageOfPerson(r,t,n,s)}async deletePerson(t,r,n){await this.superClass.deletePerson(t,r,n)}async getAllGroupsByPersonId(t,r,n,s,o){return(await this.superClass.getAllGroupsByPersonId(n,s,t,r,o)).data}async getAllImagesByPersonId(t,r,n,s,o){return(await this.superClass.getAllImagesByPersonId(n,s,t,r,o)).data}async getImageOfPerson(t,r,n,s){return(await this.superClass.getImageOfPerson(r,t,n,s)).data}async getPerson(t,r,n){return(await this.superClass.getPerson(t,r,n)).data}async updatePerson(t,r,n,s){await this.superClass.updatePerson(t,r,n,s)}}const es=function(e){return{search:async(t,r,n,s={})=>{S("search","searchRequest",t);const o="/api/search",a=new URL(o,C);let i;e&&(i=e.baseOptions);const l={method:"POST",...i,...s},c={},d={};n!==void 0&&(d.withImages=n),c["Content-Type"]="application/json",r!=null&&(c["X-RequestID"]=String(r)),L(a,d);let p=i&&i.headers?i.headers:{};return l.headers={...c,...p,...s.headers},l.data=j(t,l,e),{url:g(a),options:l}}}},ts=function(e){const t=es(e);return{async search(r,n,s,o){const a=await t.search(r,n,s,o),i=e?.serverIndex??0,l=w["SearchApi.search"]?.[i]?.url;return(c,d)=>N(a,O,b,e)(c,l||d)}}};let rs=class extends ae{search(t,r,n,s){return ts(this.configuration).search(t,r,n,s).then(o=>o(this.axios,this.basePath))}};class Qt{constructor(t,r,n){this.superClass=new rs(t,r,n)}async search(t,r,n,s){return t?.image?.content&&typeof t.image.content!="string"&&(t.image.content=ye(t.image.content)),(await this.superClass.search(t,r,n,s)).data}}const ns=function(e){return{deleteLivenessTransaction:async(t,r,n={})=>{S("deleteLivenessTransaction","transactionId",t),S("deleteLivenessTransaction","tag",r);const s="/api/v2/liveness",o=new URL(s,C);let a;e&&(a=e.baseOptions);const i={method:"DELETE",...a,...n},l={},c={};t!==void 0&&(c.transactionId=t),r!==void 0&&(c.tag=r),L(o,c);let d=a&&a.headers?a.headers:{};return i.headers={...l,...d,...n.headers},{url:g(o),options:i}},getLivenessTransactionInfo:async(t,r={})=>{S("getLivenessTransactionInfo","transactionId",t);const n="/api/v2/liveness",s=new URL(n,C);let o;e&&(o=e.baseOptions);const a={method:"GET",...o,...r},i={},l={};t!==void 0&&(l.transactionId=t),L(s,l);let c=o&&o.headers?o.headers:{};return a.headers={...i,...c,...r.headers},{url:g(s),options:a}}}},Ot=function(e){const t=ns(e);return{async deleteLivenessTransaction(r,n,s){const o=await t.deleteLivenessTransaction(r,n,s),a=e?.serverIndex??0,i=w["Liveness20Api.deleteLivenessTransaction"]?.[a]?.url;return(l,c)=>N(o,O,b,e)(l,i||c)},async getLivenessTransactionInfo(r,n){const s=await t.getLivenessTransactionInfo(r,n),o=e?.serverIndex??0,a=w["Liveness20Api.getLivenessTransactionInfo"]?.[o]?.url;return(i,l)=>N(s,O,b,e)(i,a||l)}}};let ss=class extends ae{deleteLivenessTransaction(t,r,n){return Ot(this.configuration).deleteLivenessTransaction(t,r,n).then(s=>s(this.axios,this.basePath))}getLivenessTransactionInfo(t,r){return Ot(this.configuration).getLivenessTransactionInfo(t,r).then(n=>n(this.axios,this.basePath))}};class er{constructor(t,r,n){this.superClass=new ss(t,r,n)}async getLivenessTransactionInfo(t,r){return(await this.superClass.getLivenessTransactionInfo(t,r)).data}}const os=function(e){return{healthz:async(t,r={})=>{const n="/api/healthz",s=new URL(n,C);let o;e&&(o=e.baseOptions);const a={method:"GET",...o,...r},i={},l={};t!=null&&(i["X-RequestID"]=String(t)),L(s,l);let c=o&&o.headers?o.headers:{};return a.headers={...i,...c,...r.headers},{url:g(s),options:a}},readyz:async(t,r={})=>{const n="/api/readyz",s=new URL(n,C);let o;e&&(o=e.baseOptions);const a={method:"GET",...o,...r},i={},l={};t!=null&&(i["X-RequestID"]=String(t)),L(s,l);let c=o&&o.headers?o.headers:{};return a.headers={...i,...c,...r.headers},{url:g(s),options:a}}}},_t=function(e){const t=os(e);return{async healthz(r,n){const s=await t.healthz(r,n),o=e?.serverIndex??0,a=w["HealthcheckApi.healthz"]?.[o]?.url;return(i,l)=>N(s,O,b,e)(i,a||l)},async readyz(r,n){const s=await t.readyz(r,n),o=e?.serverIndex??0,a=w["HealthcheckApi.readyz"]?.[o]?.url;return(i,l)=>N(s,O,b,e)(i,a||l)}}};let as=class extends ae{healthz(t,r){return _t(this.configuration).healthz(t,r).then(n=>n(this.axios,this.basePath))}readyz(t,r){return _t(this.configuration).readyz(t,r).then(n=>n(this.axios,this.basePath))}};class tr{constructor(t,r,n){this.superClass=new as(t,r,n)}async healthz(t,r){return(await this.superClass.healthz(t,r)).data}async readyz(t,r){return(await this.superClass.readyz(t,r)).data}}class is{constructor(t,r=b,n=O){this.basePath=r,this.axios=n,this.matchApi=new Jt(t,r,n),this.groupApi=new Zt(t,r,n),this.personApi=new Kt(t,r,n),this.searchApi=new Qt(t,r,n),this.livenessApi=new er(t,r,n),this.healthcheckApi=new tr(t,r,n)}}class ls{constructor(t={}){this.apiKey=t.apiKey,this.username=t.username,this.password=t.password,this.accessToken=t.accessToken,this.basePath=t.basePath,this.serverIndex=t.serverIndex,this.baseOptions={...t.baseOptions,headers:{...t.baseOptions?.headers}},this.formDataCtor=t.formDataCtor}isJsonMime(t){const r=new RegExp("^(application/json|[^;/ ]+/[^;/ ]+[+]json)[ ]*(;.*)?$","i");return t!==null&&(r.test(t)||t.toLowerCase()==="application/json-patch+json")}}exports.Configuration=ls;exports.FaceAttribute=vt;exports.FaceImageQualityAlignType=Ft;exports.FaceImageQualityGroups=jt;exports.FaceImageQualityGroupsStrings=kt;exports.FaceImageQualityStatus=qt;exports.FaceQualityConfigName=zt;exports.FaceQualityScenarios=$t;exports.FaceSDKResultCode=Wt;exports.FaceSdk=is;exports.FilterOp=Xt;exports.GroupApi=Zt;exports.HealthcheckApi=tr;exports.ImageSource=Ze;exports.Liveness20Api=er;exports.LivenessType=Yt;exports.MatchApi=Jt;exports.PersonApi=Kt;exports.SearchApi=Qt;
|