netlicensing-client
Version:
JavaScript Wrapper for Labs64 NetLicensing RESTful API
5 lines • 80.4 kB
JavaScript
"use strict";var NetLicensing=(()=>{var Zt=Object.defineProperty;var Sr=Object.getOwnPropertyDescriptor;var Lr=Object.getOwnPropertyNames;var Cr=Object.prototype.hasOwnProperty;var Yn=(n,e)=>{for(var o in e)Zt(n,o,{get:e[o],enumerable:!0})},Ar=(n,e,o,t)=>{if(e&&typeof e=="object"||typeof e=="function")for(let r of Lr(e))!Cr.call(n,r)&&r!==o&&Zt(n,r,{get:()=>e[r],enumerable:!(t=Sr(e,r))||t.enumerable});return n};var Or=n=>Ar(Zt({},"__esModule",{value:!0}),n);var Wi={};Yn(Wi,{ApiKeyRole:()=>Jn,Bundle:()=>ut,BundleService:()=>mr,Constants:()=>y,Context:()=>Dr,Country:()=>dt,License:()=>Pe,LicenseService:()=>lr,LicenseTemplate:()=>lt,LicenseTemplateService:()=>fr,LicenseTransactionJoin:()=>Ut,LicenseType:()=>Me,Licensee:()=>pt,LicenseeSecretMode:()=>it,LicenseeService:()=>pr,LicensingModel:()=>Wn,NlicError:()=>V,NodeSecretMode:()=>Gn,Notification:()=>ft,NotificationEvent:()=>Ue,NotificationProtocol:()=>je,NotificationService:()=>gr,Page:()=>O,PaymentMethod:()=>gt,PaymentMethodEnum:()=>Xn,PaymentMethodService:()=>Tr,Product:()=>Tt,ProductDiscount:()=>wt,ProductModule:()=>_t,ProductModuleService:()=>hr,ProductService:()=>Pr,SecurityMode:()=>G,Service:()=>g,TimeVolumePeriod:()=>at,Token:()=>Mt,TokenService:()=>yr,TokenType:()=>Be,Transaction:()=>Xe,TransactionService:()=>Er,TransactionSource:()=>ct,TransactionStatus:()=>Fe,UtilityService:()=>br,ValidationParameters:()=>Rr,ValidationResults:()=>kt,defineEntity:()=>A,ensureNotEmpty:()=>b,ensureNotNull:()=>I,filterDecode:()=>ur,filterEncode:()=>M,isDefined:()=>wn,isValid:()=>Qe,itemToBundle:()=>ae,itemToCountry:()=>mt,itemToLicense:()=>te,itemToLicenseTemplate:()=>ue,itemToLicensee:()=>ce,itemToNotification:()=>de,itemToObject:()=>C,itemToPaymentMethod:()=>ye,itemToProduct:()=>le,itemToProductModule:()=>fe,itemToToken:()=>Le,itemToTransaction:()=>ge,serialize:()=>U});var wr=Object.freeze({DISABLED:"DISABLED",PREDEFINED:"PREDEFINED",CLIENT:"CLIENT"}),it=wr;var _r=Object.freeze({FEATURE:"FEATURE",TIMEVOLUME:"TIMEVOLUME",FLOATING:"FLOATING",QUANTITY:"QUANTITY"}),Me=_r;var Mr=Object.freeze({LICENSEE_CREATED:"LICENSEE_CREATED",LICENSE_CREATED:"LICENSE_CREATED",WARNING_LEVEL_CHANGED:"WARNING_LEVEL_CHANGED",PAYMENT_TRANSACTION_PROCESSED:"PAYMENT_TRANSACTION_PROCESSED"}),Ue=Mr;var Ur=Object.freeze({WEBHOOK:"WEBHOOK"}),je=Ur;var jr=Object.freeze({BASIC_AUTHENTICATION:"BASIC_AUTH",APIKEY_IDENTIFICATION:"APIKEY",ANONYMOUS_IDENTIFICATION:"ANONYMOUS"}),G=jr;var Br=Object.freeze({DAY:"DAY",WEEK:"WEEK",MONTH:"MONTH",YEAR:"YEAR"}),at=Br;var Fr=Object.freeze({DEFAULT:"DEFAULT",SHOP:"SHOP",APIKEY:"APIKEY",ACTION:"ACTION"}),Be=Fr;var kr=Object.freeze({SHOP:"SHOP",AUTO_LICENSE_CREATE:"AUTO_LICENSE_CREATE",AUTO_LICENSE_UPDATE:"AUTO_LICENSE_UPDATE",AUTO_LICENSE_DELETE:"AUTO_LICENSE_DELETE",AUTO_LICENSEE_CREATE:"AUTO_LICENSEE_CREATE",AUTO_LICENSEE_DELETE:"AUTO_LICENSEE_DELETE",AUTO_LICENSEE_VALIDATE:"AUTO_LICENSEE_VALIDATE",AUTO_LICENSETEMPLATE_DELETE:"AUTO_LICENSETEMPLATE_DELETE",AUTO_PRODUCTMODULE_DELETE:"AUTO_PRODUCTMODULE_DELETE",AUTO_PRODUCT_DELETE:"AUTO_PRODUCT_DELETE",AUTO_LICENSES_TRANSFER:"AUTO_LICENSES_TRANSFER",SUBSCRIPTION_UPDATE:"SUBSCRIPTION_UPDATE",RECURRING_PAYMENT:"RECURRING_PAYMENT",CANCEL_RECURRING_PAYMENT:"CANCEL_RECURRING_PAYMENT",OBTAIN_BUNDLE:"OBTAIN_BUNDLE"}),ct=kr;var qr=Object.freeze({PENDING:"PENDING",CLOSED:"CLOSED",CANCELLED:"CANCELLED"}),Fe=qr;var y={LicenseeSecretMode:it,LicenseType:Me,NotificationEvent:Ue,NotificationProtocol:je,SecurityMode:G,TimeVolumePeriod:at,TokenType:Be,TransactionSource:ct,TransactionStatus:Fe,BASIC_AUTHENTICATION:"BASIC_AUTH",APIKEY_IDENTIFICATION:"APIKEY",ANONYMOUS_IDENTIFICATION:"ANONYMOUS",FILTER:"filter",Product:{TYPE:"Product",ENDPOINT_PATH:"product"},ProductModule:{TYPE:"ProductModule",ENDPOINT_PATH:"productmodule",PRODUCT_MODULE_NUMBER:"productModuleNumber"},Licensee:{TYPE:"Licensee",ENDPOINT_PATH:"licensee",ENDPOINT_PATH_VALIDATE:"validate",ENDPOINT_PATH_TRANSFER:"transfer",LICENSEE_NUMBER:"licenseeNumber"},LicenseTemplate:{TYPE:"LicenseTemplate",ENDPOINT_PATH:"licensetemplate",LicenseType:Me},License:{TYPE:"License",ENDPOINT_PATH:"license"},Validation:{TYPE:"ProductModuleValidation"},Token:{TYPE:"Token",ENDPOINT_PATH:"token",Type:Be},PaymentMethod:{TYPE:"PaymentMethod",ENDPOINT_PATH:"paymentmethod"},Bundle:{TYPE:"Bundle",ENDPOINT_PATH:"bundle",ENDPOINT_OBTAIN_PATH:"obtain"},Notification:{TYPE:"Notification",ENDPOINT_PATH:"notification",Protocol:je,Event:Ue},Transaction:{TYPE:"Transaction",ENDPOINT_PATH:"transaction",Status:Fe},Utility:{ENDPOINT_PATH:"utility",ENDPOINT_PATH_LICENSE_TYPES:"licenseTypes",ENDPOINT_PATH_LICENSING_MODELS:"licensingModels",ENDPOINT_PATH_COUNTRIES:"countries",LICENSING_MODEL_TYPE:"LicensingModelProperties",LICENSE_TYPE:"LicenseType",COUNTRY_TYPE:"Country"}};var Vr=Object.freeze({ROLE_APIKEY_LICENSEE:"ROLE_APIKEY_LICENSEE",ROLE_APIKEY_ANALYTICS:"ROLE_APIKEY_ANALYTICS",ROLE_APIKEY_OPERATION:"ROLE_APIKEY_OPERATION",ROLE_APIKEY_MAINTENANCE:"ROLE_APIKEY_MAINTENANCE",ROLE_APIKEY_ADMIN:"ROLE_APIKEY_ADMIN"}),Jn=Vr;var Hr=Object.freeze({TRY_AND_BUY:"TryAndBuy",SUBSCRIPTION:"Subscription",RENTAL:"Rental",FLOATING:"Floating",MULTI_FEATURE:"MultiFeature",PAY_PER_USE:"PayPerUse",PRICING_TABLE:"PricingTable",QUOTA:"Quota",NODE_LOCKED:"NodeLocked",DISCOUNT:"Discount"}),Wn=Hr;var $r=Object.freeze({PREDEFINED:"PREDEFINED",CLIENT:"CLIENT"}),Gn=$r;var zr=Object.freeze({NULL:"NULL",PAYPAL:"PAYPAL",PAYPAL_SANDBOX:"PAYPAL_SANDBOX",STRIPE:"STRIPE",STRIPE_TESTING:"STRIPE_TESTING"}),Xn=zr;var Kr=n=>n==="true"||n==="false",Qn=n=>n==="null"||n===null,Zn=n=>{let e=n.trim();return e.startsWith("{")&&e.endsWith("}")||e.startsWith("[")&&e.endsWith("]")},eo=n=>{let e=n.trim();if(!e)return!1;let o=Number(e);return Number.isFinite(o)},Yr=n=>eo(n)?Number(n):n,Jr=n=>n==="true"?!0:n==="false"?!1:n,Wr=n=>Qn(n)?null:n,Gr=n=>{if(!Zn(n))return n;try{return JSON.parse(n)}catch{return n}},Xr=n=>{if(Kr(n))return n==="true";if(Qn(n))return null;if(eo(n))return Number(n);if(Zn(n))try{return JSON.parse(n)}catch{return n}return n},Qr=(n,e="auto")=>{if(n===null)return null;switch(e){case"string":return n;case"number":return Yr(n);case"boolean":return Jr(n);case"null":return Wr(n);case"json":return Gr(n);default:return Xr(n)}},to=Qr;var Zr=(n,e={})=>{let o={};return n?.forEach(({name:t,value:r})=>{o[t]=to(r,e[t])}),o},es=(n,e={})=>{let o={};return n?.forEach(t=>{let{name:r}=t;o[r]=o[r]||[],o[r].push(no(t,e))}),o},no=(n,e={})=>n?{...Zr(n.property,e),...es(n.list,e)}:{},C=no;var en=(n,e)=>Object.hasOwn(n,e),l=(n,e,o)=>{n[e]=o},p=(n,e,o)=>en(n,e)?n[e]:o;var U=(n,e={})=>{let o={},{ignore:t=[]}=e;return Object.entries(n).forEach(([r,s])=>{if(!t.includes(r)&&typeof s!="function")if(s===void 0)o[r]="";else if(typeof s=="string")o[r]=s;else if(s instanceof Date)o[r]=s.toISOString();else if(typeof s!="object"||s===null)o[r]=String(s);else try{o[r]=JSON.stringify(s)}catch{o[r]=String(s)}}),o};var ts=function(n,e,o={},t){let r={set:[],get:[]};t?.get&&r.get.push(t.get),t?.set&&r.set.push(t.set);let s={set(i,a){l(n,i,a)},get(i,a){return p(n,i,a)},has(i){return en(n,i)},setProperty(i,a){this.set(i,a)},addProperty(i,a){this.set(i,a)},getProperty(i,a){return this.get(i,a)},hasProperty(i){return this.has(i)},setProperties(i){Object.entries(i).forEach(([a,u])=>{this.set(a,u)})},serialize(){return U(n)}};return new Proxy(n,{get(i,a,u){return Object.hasOwn(e,a)?e[a]:Object.hasOwn(s,a)?s[a]:(r.get.forEach(d=>{d(i,a,u)}),Reflect.get(i,a,u))},set(i,a,u,d){return r.set.forEach(m=>{m(i,a,u,d)}),Reflect.set(i,a,u,d)},getPrototypeOf(){return o.prototype||null}})},A=ts;var oo=function(n={}){let e={...n};return A(e,{setActive(t){l(e,"active",t)},getActive(t){return p(e,"active",t)},setNumber(t){l(e,"number",t)},getNumber(t){return p(e,"number",t)},setName(t){l(e,"name",t)},getName(t){return p(e,"name",t)},setPrice(t){l(e,"price",t)},getPrice(t){return p(e,"price",t)},setCurrency(t){l(e,"currency",t)},getCurrency(t){return p(e,"currency",t)},setProductNumber(t){l(e,"productNumber",t)},getProductNumber(t){return p(e,"productNumber",t)},setLicenseTemplateNumbers(t){l(e,"licenseTemplateNumbers",t)},addLicenseTemplateNumber(t){e.licenseTemplateNumbers||(e.licenseTemplateNumbers=[]),e.licenseTemplateNumbers.push(t)},getLicenseTemplateNumbers(t){return p(e,"licenseTemplateNumbers",t)},removeLicenseTemplateNumber(t){let{licenseTemplateNumbers:r=[]}=e;r.splice(r.indexOf(t),1),e.licenseTemplateNumbers=r},getStaleLicenseTemplateNumbers(t){return p(e,"staleLicenseTemplateNumbers",t)},serialize(){let t={};return e.licenseTemplateNumbers&&(t.licenseTemplateNumbers=e.licenseTemplateNumbers.join(",")),U({...e,...t},{ignore:["staleLicenseTemplateNumbers"]})}},oo)},ut=oo;var ae=n=>{let e=C(n,{active:"boolean",number:"string",name:"string",price:"number",currency:"string",productNumber:"string",licenseTemplateNumbers:"string",staleLicenseTemplateNumbers:"string"}),{licenseTemplateNumbers:o,staleLicenseTemplateNumbers:t}=e;return o&&typeof o=="string"&&(e.licenseTemplateNumbers=o.split(",")),t&&typeof t=="string"&&(e.staleLicenseTemplateNumbers=t.split(",")),ut(e)};var ro=function(n={}){let o={...{code:"",name:"",vatPercent:0,isEu:!1},...n};return A(o,{getCode(){return o.code},getName(){return o.name},getVatPercent(){return o.vatPercent},getIsEu(){return o.isEu}},ro)},dt=ro;var mt=n=>dt(C(n,{code:"string",name:"string",vatPercent:"number",isEu:"boolean"}));var so=function(n={}){let e={...n};return A(e,{setActive(t){l(e,"active",t)},getActive(t){return p(e,"active",t)},setNumber(t){l(e,"number",t)},getNumber(t){return p(e,"number",t)},setName(t){l(e,"name",t)},getName(t){return p(e,"name",t)},setPrice(t){l(e,"price",t)},getPrice(t){return p(e,"price",t)},setCurrency(t){l(e,"currency",t)},getCurrency(t){return p(e,"currency",t)},setHidden(t){l(e,"hidden",t)},getHidden(t){return p(e,"hidden",t)},setLicenseeNumber(t){l(e,"licenseeNumber",t)},getLicenseeNumber(t){return p(e,"licenseeNumber",t)},setLicenseTemplateNumber(t){l(e,"licenseTemplateNumber",t)},getLicenseTemplateNumber(t){return p(e,"licenseTemplateNumber",t)},setProductModuleNumber(t){l(e,"productModuleNumber",t)},getProductModuleNumber(t){return p(e,"productModuleNumber",t)},serialize(){return U(e,{ignore:["inUse"]})}},so)},Pe=so;var te=n=>{let e=C(n,{active:"boolean",number:"string",name:"string",price:"number",currency:"string",hidden:"boolean",licenseeNumber:"string",licenseTemplateNumber:"string",productModuleNumber:"string",startDate:"string",inUse:"boolean"}),{startDate:o}=e;return o&&typeof o=="string"&&(e.startDate=o==="now"?o:new Date(o)),Pe(e)};var io=function(n={}){let e={...n};return A(e,{setActive(t){l(e,"active",t)},getActive(t){return p(e,"active",t)},setNumber(t){l(e,"number",t)},getNumber(t){return p(e,"number",t)},setName(t){l(e,"name",t)},getName(t){return p(e,"name",t)},setProductNumber(t){l(e,"productNumber",t)},getProductNumber(t){return p(e,"productNumber",t)},setMarkedForTransfer(t){l(e,"markedForTransfer",t)},getMarkedForTransfer(t){return p(e,"markedForTransfer",t)},serialize(){return U(e,{ignore:["inUse"]})}},io)},pt=io;var ce=n=>{let e=C(n,{active:"boolean",number:"string",name:"string",markedForTransfer:"boolean",productNumber:"string",inUse:"boolean"}),{aliases:o}=e;return o&&typeof o=="string"&&(e.aliases=o.split(",")),pt(e)};var ao=function(n={}){let e={...n};return A(e,{setActive(t){l(e,"active",t)},getActive(t){return p(e,"active",t)},setNumber(t){l(e,"number",t)},getNumber(t){return p(e,"number",t)},setName(t){l(e,"name",t)},getName(t){return p(e,"name",t)},setLicenseType(t){l(e,"licenseType",t)},getLicenseType(t){return p(e,"licenseType",t)},setPrice(t){l(e,"price",t)},getPrice(t){return p(e,"price",t)},setCurrency(t){l(e,"currency",t)},getCurrency(t){return p(e,"currency",t)},setAutomatic(t){l(e,"automatic",t)},getAutomatic(t){return p(e,"automatic",t)},setHidden(t){l(e,"hidden",t)},getHidden(t){return p(e,"hidden",t)},setHideLicenses(t){l(e,"hideLicenses",t)},getHideLicenses(t){return p(e,"hideLicenses",t)},setProductModuleNumber(t){l(e,"productModuleNumber",t)},getProductModuleNumber(t){return p(e,"productModuleNumber",t)},serialize(){return U(e,{ignore:["inUse"]})}},ao)},lt=ao;var ue=n=>lt(C(n,{active:"boolean",number:"string",name:"string",licenseType:"string",price:"number",currency:"string",automatic:"boolean",hidden:"boolean",hideLicenses:"boolean",productModuleNumber:"string",inUse:"boolean"}));var co=function(n={}){let e={...n};return A(e,{setActive(t){l(e,"active",t)},getActive(t){return p(e,"active",t)},setNumber(t){l(e,"number",t)},getNumber(t){return p(e,"number",t)},setName(t){l(e,"name",t)},getName(t){return p(e,"name",t)},setProtocol(t){l(e,"protocol",t)},getProtocol(t){return p(e,"protocol",t)},setEvents(t){l(e,"events",t)},getEvents(t){return p(e,"events",t)},addEvent(t){let r=this.getEvents([]);r.push(t),this.setEvents(r)},setPayload(t){l(e,"payload",t)},getPayload(t){return p(e,"payload",t)},setEndpoint(t){l(e,"endpoint",t)},getEndpoint(t){return p(e,"endpoint",t)},serialize(){let t=U(e);return t.events&&(t.events=this.getEvents([]).join(",")),t}},co)},ft=co;var de=n=>{let e=C(n,{active:"boolean",number:"string",name:"string",protocol:"string",events:"string",payload:"string",endpoint:"string"}),{events:o}=e;return o&&typeof o=="string"&&(e.events=o.split(",")),ft(e)};var uo=function(n={}){let e={...n};return A(e,{setActive(t){l(e,"active",t)},getActive(t){return p(e,"active",t)},setNumber(t){l(e,"number",t)},getNumber(t){return p(e,"number",t)}},uo)},gt=uo;var ye=n=>gt(C(n,{active:"boolean",number:"string"}));var mo=function(n={}){let e={...n};return A(e,{setActive(t){l(e,"active",t)},getActive(t){return p(e,"active",t)},setNumber(t){l(e,"number",t)},getNumber(t){return p(e,"number",t)},setName(t){l(e,"name",t)},getName(t){return p(e,"name",t)},setVersion(t){l(e,"version",t)},getVersion(t){return p(e,"version",t)},setDescription(t){l(e,"description",t)},getDescription(t){return p(e,"description",t)},setLicensingInfo(t){l(e,"licensingInfo",t)},getLicensingInfo(t){return p(e,"licensingInfo",t)},setLicenseeAutoCreate(t){l(e,"licenseeAutoCreate",t)},getLicenseeAutoCreate(t){return p(e,"licenseeAutoCreate",t)},setDiscounts(t){l(e,"discounts",t)},getDiscounts(t){return p(e,"discounts",t)},addDiscount(t){let r=this.getDiscounts([]);r.push(t),this.setDiscounts(r)},removeDiscount(t){let r=this.getDiscounts();Array.isArray(r)&&r.length>0&&(r.splice(r.indexOf(t),1),this.setDiscounts(r))},setProductDiscounts(t){this.setDiscounts(t)},getProductDiscounts(t){return this.getDiscounts(t)},serialize(){let t=U(e,{ignore:["discounts","inUse"]}),r=this.getDiscounts();return r&&(t.discount=r.length>0?r.map(s=>s.toString()):""),t}},mo)},Tt=mo;function ke(n,e){return function(){return n.apply(e,arguments)}}var{toString:ns}=Object.prototype,{getPrototypeOf:Pt}=Object,{iterator:yt,toStringTag:fo}=Symbol,Et=(n=>e=>{let o=ns.call(e);return n[o]||(n[o]=o.slice(8,-1).toLowerCase())})(Object.create(null)),z=n=>(n=n.toLowerCase(),e=>Et(e)===n),bt=n=>e=>typeof e===n,{isArray:pe}=Array,Ee=bt("undefined");function be(n){return n!==null&&!Ee(n)&&n.constructor!==null&&!Ee(n.constructor)&&k(n.constructor.isBuffer)&&n.constructor.isBuffer(n)}var go=z("ArrayBuffer");function os(n){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(n):e=n&&n.buffer&&go(n.buffer),e}var rs=bt("string"),k=bt("function"),To=bt("number"),qe=n=>n!==null&&typeof n=="object",ss=n=>n===!0||n===!1,ht=n=>{if(Et(n)!=="object")return!1;let e=Pt(n);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(fo in n)&&!(yt in n)},is=n=>{if(!qe(n)||be(n))return!1;try{return Object.keys(n).length===0&&Object.getPrototypeOf(n)===Object.prototype}catch{return!1}},as=z("Date"),cs=z("File"),us=n=>!!(n&&typeof n.uri<"u"),ds=n=>n&&typeof n.getParts<"u",ms=z("Blob"),ps=z("FileList"),ls=n=>qe(n)&&k(n.pipe);function fs(){return typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{}}var po=fs(),lo=typeof po.FormData<"u"?po.FormData:void 0,gs=n=>{if(!n)return!1;if(lo&&n instanceof lo)return!0;let e=Pt(n);if(!e||e===Object.prototype||!k(n.append))return!1;let o=Et(n);return o==="formdata"||o==="object"&&k(n.toString)&&n.toString()==="[object FormData]"},Ts=z("URLSearchParams"),[hs,Ps,ys,Es]=["ReadableStream","Request","Response","Headers"].map(z),bs=n=>n.trim?n.trim():n.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Ve(n,e,{allOwnKeys:o=!1}={}){if(n===null||typeof n>"u")return;let t,r;if(typeof n!="object"&&(n=[n]),pe(n))for(t=0,r=n.length;t<r;t++)e.call(null,n[t],t,n);else{if(be(n))return;let s=o?Object.getOwnPropertyNames(n):Object.keys(n),i=s.length,a;for(t=0;t<i;t++)a=s[t],e.call(null,n[a],a,n)}}function ho(n,e){if(be(n))return null;e=e.toLowerCase();let o=Object.keys(n),t=o.length,r;for(;t-- >0;)if(r=o[t],e===r.toLowerCase())return r;return null}var me=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,Po=n=>!Ee(n)&&n!==me;function tn(...n){let{caseless:e,skipUndefined:o}=Po(this)&&this||{},t={},r=(s,i)=>{if(i==="__proto__"||i==="constructor"||i==="prototype")return;let a=e&&typeof i=="string"&&ho(t,i)||i,u=nn(t,a)?t[a]:void 0;ht(u)&&ht(s)?t[a]=tn(u,s):ht(s)?t[a]=tn({},s):pe(s)?t[a]=s.slice():(!o||!Ee(s))&&(t[a]=s)};for(let s=0,i=n.length;s<i;s++){let a=n[s];if(!a||be(a)||(Ve(a,r),typeof a!="object"||pe(a)))continue;let u=Object.getOwnPropertySymbols(a);for(let d=0;d<u.length;d++){let m=u[d];ws.call(a,m)&&r(a[m],m)}}return t}var Ds=(n,e,o,{allOwnKeys:t}={})=>(Ve(e,(r,s)=>{o&&k(r)?Object.defineProperty(n,s,{__proto__:null,value:ke(r,o),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(n,s,{__proto__:null,value:r,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:t}),n),Rs=n=>(n.charCodeAt(0)===65279&&(n=n.slice(1)),n),Ns=(n,e,o,t)=>{n.prototype=Object.create(e.prototype,t),Object.defineProperty(n.prototype,"constructor",{__proto__:null,value:n,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(n,"super",{__proto__:null,value:e.prototype}),o&&Object.assign(n.prototype,o)},xs=(n,e,o,t)=>{let r,s,i,a={};if(e=e||{},n==null)return e;do{for(r=Object.getOwnPropertyNames(n),s=r.length;s-- >0;)i=r[s],(!t||t(i,n,e))&&!a[i]&&(e[i]=n[i],a[i]=!0);n=o!==!1&&Pt(n)}while(n&&(!o||o(n,e))&&n!==Object.prototype);return e},vs=(n,e,o)=>{n=String(n),(o===void 0||o>n.length)&&(o=n.length),o-=e.length;let t=n.indexOf(e,o);return t!==-1&&t===o},Is=n=>{if(!n)return null;if(pe(n))return n;let e=n.length;if(!To(e))return null;let o=new Array(e);for(;e-- >0;)o[e]=n[e];return o},Ss=(n=>e=>n&&e instanceof n)(typeof Uint8Array<"u"&&Pt(Uint8Array)),Ls=(n,e)=>{let t=(n&&n[yt]).call(n),r;for(;(r=t.next())&&!r.done;){let s=r.value;e.call(n,s[0],s[1])}},Cs=(n,e)=>{let o,t=[];for(;(o=n.exec(e))!==null;)t.push(o);return t},As=z("HTMLFormElement"),Os=n=>n.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(o,t,r){return t.toUpperCase()+r}),nn=(({hasOwnProperty:n})=>(e,o)=>n.call(e,o))(Object.prototype),{propertyIsEnumerable:ws}=Object.prototype,_s=z("RegExp"),yo=(n,e)=>{let o=Object.getOwnPropertyDescriptors(n),t={};Ve(o,(r,s)=>{let i;(i=e(r,s,n))!==!1&&(t[s]=i||r)}),Object.defineProperties(n,t)},Ms=n=>{yo(n,(e,o)=>{if(k(n)&&["arguments","caller","callee"].includes(o))return!1;let t=n[o];if(k(t)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+o+"'")})}})},Us=(n,e)=>{let o={},t=r=>{r.forEach(s=>{o[s]=!0})};return pe(n)?t(n):t(String(n).split(e)),o},js=()=>{},Bs=(n,e)=>n!=null&&Number.isFinite(n=+n)?n:e;function Fs(n){return!!(n&&k(n.append)&&n[fo]==="FormData"&&n[yt])}var ks=n=>{let e=new WeakSet,o=t=>{if(qe(t)){if(e.has(t))return;if(be(t))return t;if(!("toJSON"in t)){e.add(t);let r=pe(t)?[]:{};return Ve(t,(s,i)=>{let a=o(s);!Ee(a)&&(r[i]=a)}),e.delete(t),r}}return t};return o(n)},qs=z("AsyncFunction"),Vs=n=>n&&(qe(n)||k(n))&&k(n.then)&&k(n.catch),Eo=((n,e)=>n?setImmediate:e?((o,t)=>(me.addEventListener("message",({source:r,data:s})=>{r===me&&s===o&&t.length&&t.shift()()},!1),r=>{t.push(r),me.postMessage(o,"*")}))(`axios@${Math.random()}`,[]):o=>setTimeout(o))(typeof setImmediate=="function",k(me.postMessage)),Hs=typeof queueMicrotask<"u"?queueMicrotask.bind(me):typeof process<"u"&&process.nextTick||Eo,$s=n=>n!=null&&k(n[yt]),c={isArray:pe,isArrayBuffer:go,isBuffer:be,isFormData:gs,isArrayBufferView:os,isString:rs,isNumber:To,isBoolean:ss,isObject:qe,isPlainObject:ht,isEmptyObject:is,isReadableStream:hs,isRequest:Ps,isResponse:ys,isHeaders:Es,isUndefined:Ee,isDate:as,isFile:cs,isReactNativeBlob:us,isReactNative:ds,isBlob:ms,isRegExp:_s,isFunction:k,isStream:ls,isURLSearchParams:Ts,isTypedArray:Ss,isFileList:ps,forEach:Ve,merge:tn,extend:Ds,trim:bs,stripBOM:Rs,inherits:Ns,toFlatObject:xs,kindOf:Et,kindOfTest:z,endsWith:vs,toArray:Is,forEachEntry:Ls,matchAll:Cs,isHTMLForm:As,hasOwnProperty:nn,hasOwnProp:nn,reduceDescriptors:yo,freezeMethods:Ms,toObjectSet:Us,toCamelCase:Os,noop:js,toFiniteNumber:Bs,findKey:ho,global:me,isContextDefined:Po,isSpecCompliantForm:Fs,toJSONObject:ks,isAsyncFn:qs,isThenable:Vs,setImmediate:Eo,asap:Hs,isIterable:$s};var zs=c.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"]),bo=n=>{let e={},o,t,r;return n&&n.split(`
`).forEach(function(i){r=i.indexOf(":"),o=i.substring(0,r).trim().toLowerCase(),t=i.substring(r+1).trim(),!(!o||e[o]&&zs[o])&&(o==="set-cookie"?e[o]?e[o].push(t):e[o]=[t]:e[o]=e[o]?e[o]+", "+t:t)}),e};function Ks(n){let e=0,o=n.length;for(;e<o;){let t=n.charCodeAt(e);if(t!==9&&t!==32)break;e+=1}for(;o>e;){let t=n.charCodeAt(o-1);if(t!==9&&t!==32)break;o-=1}return e===0&&o===n.length?n:n.slice(e,o)}var Ys=new RegExp("[\\u0000-\\u0008\\u000a-\\u001f\\u007f]+","g"),Js=new RegExp("[^\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+","g");function on(n,e){return c.isArray(n)?n.map(o=>on(o,e)):Ks(String(n).replace(e,""))}var Do=n=>on(n,Ys),Ws=n=>on(n,Js);function Dt(n){let e=Object.create(null);return c.forEach(n.toJSON(),(o,t)=>{e[t]=Ws(o)}),e}var Ro=Symbol("internals");function He(n){return n&&String(n).trim().toLowerCase()}function Rt(n){return n===!1||n==null?n:c.isArray(n)?n.map(Rt):Do(String(n))}function Gs(n){let e=Object.create(null),o=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g,t;for(;t=o.exec(n);)e[t[1]]=t[2];return e}var Xs=n=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(n.trim());function rn(n,e,o,t,r){if(c.isFunction(t))return t.call(this,e,o);if(r&&(e=o),!!c.isString(e)){if(c.isString(t))return e.indexOf(t)!==-1;if(c.isRegExp(t))return t.test(e)}}function Qs(n){return n.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,o,t)=>o.toUpperCase()+t)}function Zs(n,e){let o=c.toCamelCase(" "+e);["get","set","has"].forEach(t=>{Object.defineProperty(n,t+o,{__proto__:null,value:function(r,s,i){return this[t].call(this,e,r,s,i)},configurable:!0})})}var De=class{constructor(e){e&&this.set(e)}set(e,o,t){let r=this;function s(a,u,d){let m=He(u);if(!m)return;let h=c.findKey(r,m);(!h||r[h]===void 0||d===!0||d===void 0&&r[h]!==!1)&&(r[h||u]=Rt(a))}let i=(a,u)=>c.forEach(a,(d,m)=>s(d,m,u));if(c.isPlainObject(e)||e instanceof this.constructor)i(e,o);else if(c.isString(e)&&(e=e.trim())&&!Xs(e))i(bo(e),o);else if(c.isObject(e)&&c.isIterable(e)){let a={},u,d;for(let m of e){if(!c.isArray(m))throw new TypeError("Object iterator must return a key-value pair");a[d=m[0]]=(u=a[d])?c.isArray(u)?[...u,m[1]]:[u,m[1]]:m[1]}i(a,o)}else e!=null&&s(o,e,t);return this}get(e,o){if(e=He(e),e){let t=c.findKey(this,e);if(t){let r=this[t];if(!o)return r;if(o===!0)return Gs(r);if(c.isFunction(o))return o.call(this,r,t);if(c.isRegExp(o))return o.exec(r);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,o){if(e=He(e),e){let t=c.findKey(this,e);return!!(t&&this[t]!==void 0&&(!o||rn(this,this[t],t,o)))}return!1}delete(e,o){let t=this,r=!1;function s(i){if(i=He(i),i){let a=c.findKey(t,i);a&&(!o||rn(t,t[a],a,o))&&(delete t[a],r=!0)}}return c.isArray(e)?e.forEach(s):s(e),r}clear(e){let o=Object.keys(this),t=o.length,r=!1;for(;t--;){let s=o[t];(!e||rn(this,this[s],s,e,!0))&&(delete this[s],r=!0)}return r}normalize(e){let o=this,t={};return c.forEach(this,(r,s)=>{let i=c.findKey(t,s);if(i){o[i]=Rt(r),delete o[s];return}let a=e?Qs(s):String(s).trim();a!==s&&delete o[s],o[a]=Rt(r),t[a]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){let o=Object.create(null);return c.forEach(this,(t,r)=>{t!=null&&t!==!1&&(o[r]=e&&c.isArray(t)?t.join(", "):t)}),o}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,o])=>e+": "+o).join(`
`)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...o){let t=new this(e);return o.forEach(r=>t.set(r)),t}static accessor(e){let t=(this[Ro]=this[Ro]={accessors:{}}).accessors,r=this.prototype;function s(i){let a=He(i);t[a]||(Zs(r,i),t[a]=!0)}return c.isArray(e)?e.forEach(s):s(e),this}};De.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);c.reduceDescriptors(De.prototype,({value:n},e)=>{let o=e[0].toUpperCase()+e.slice(1);return{get:()=>n,set(t){this[o]=t}}});c.freezeMethods(De);var j=De;var ei="[REDACTED ****]";function ti(n){if(c.hasOwnProp(n,"toJSON"))return!0;let e=Object.getPrototypeOf(n);for(;e&&e!==Object.prototype;){if(c.hasOwnProp(e,"toJSON"))return!0;e=Object.getPrototypeOf(e)}return!1}function ni(n,e){let o=new Set(e.map(s=>String(s).toLowerCase())),t=[],r=s=>{if(s===null||typeof s!="object"||c.isBuffer(s))return s;if(t.indexOf(s)!==-1)return;s instanceof j&&(s=s.toJSON()),t.push(s);let i;if(c.isArray(s))i=[],s.forEach((a,u)=>{let d=r(a);c.isUndefined(d)||(i[u]=d)});else{if(!c.isPlainObject(s)&&ti(s))return t.pop(),s;i=Object.create(null);for(let[a,u]of Object.entries(s)){let d=o.has(a.toLowerCase())?ei:r(u);c.isUndefined(d)||(i[a]=d)}}return t.pop(),i};return r(n)}var F=class n extends Error{static from(e,o,t,r,s,i){let a=new n(e.message,o||e.code,t,r,s);return a.cause=e,a.name=e.name,e.status!=null&&a.status==null&&(a.status=e.status),i&&Object.assign(a,i),a}constructor(e,o,t,r,s){super(e),Object.defineProperty(this,"message",{__proto__:null,value:e,enumerable:!0,writable:!0,configurable:!0}),this.name="AxiosError",this.isAxiosError=!0,o&&(this.code=o),t&&(this.config=t),r&&(this.request=r),s&&(this.response=s,this.status=s.status)}toJSON(){let e=this.config,o=e&&c.hasOwnProp(e,"redact")?e.redact:void 0,t=c.isArray(o)&&o.length>0?ni(e,o):c.toJSONObject(e);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:t,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";var P=F;var Nt=null;function an(n){return c.isPlainObject(n)||c.isArray(n)}function No(n){return c.endsWith(n,"[]")?n.slice(0,-2):n}function sn(n,e,o){return n?n.concat(e).map(function(r,s){return r=No(r),!o&&s?"["+r+"]":r}).join(o?".":""):e}function oi(n){return c.isArray(n)&&!n.some(an)}var ri=c.toFlatObject(c,{},null,function(e){return/^is[A-Z]/.test(e)});function si(n,e,o){if(!c.isObject(n))throw new TypeError("target must be an object");e=e||new(Nt||FormData),o=c.toFlatObject(o,{metaTokens:!0,dots:!1,indexes:!1},!1,function(f,E){return!c.isUndefined(E[f])});let t=o.metaTokens,r=o.visitor||h,s=o.dots,i=o.indexes,a=o.Blob||typeof Blob<"u"&&Blob,u=o.maxDepth===void 0?100:o.maxDepth,d=a&&c.isSpecCompliantForm(e);if(!c.isFunction(r))throw new TypeError("visitor must be a function");function m(T){if(T===null)return"";if(c.isDate(T))return T.toISOString();if(c.isBoolean(T))return T.toString();if(!d&&c.isBlob(T))throw new P("Blob is not supported. Use a Buffer instead.");return c.isArrayBuffer(T)||c.isTypedArray(T)?d&&typeof Blob=="function"?new Blob([T]):Buffer.from(T):T}function h(T,f,E){let S=T;if(c.isReactNative(e)&&c.isReactNativeBlob(T))return e.append(sn(E,f,s),m(T)),!1;if(T&&!E&&typeof T=="object"){if(c.endsWith(f,"{}"))f=t?f:f.slice(0,-2),T=JSON.stringify(T);else if(c.isArray(T)&&oi(T)||(c.isFileList(T)||c.endsWith(f,"[]"))&&(S=c.toArray(T)))return f=No(f),S.forEach(function(v,H){!(c.isUndefined(v)||v===null)&&e.append(i===!0?sn([f],H,s):i===null?f:f+"[]",m(v))}),!1}return an(T)?!0:(e.append(sn(E,f,s),m(T)),!1)}let D=[],R=Object.assign(ri,{defaultVisitor:h,convertValue:m,isVisitable:an});function N(T,f,E=0){if(!c.isUndefined(T)){if(E>u)throw new P("Object is too deeply nested ("+E+" levels). Max depth: "+u,P.ERR_FORM_DATA_DEPTH_EXCEEDED);if(D.indexOf(T)!==-1)throw new Error("Circular reference detected in "+f.join("."));D.push(T),c.forEach(T,function(L,v){(!(c.isUndefined(L)||L===null)&&r.call(e,L,c.isString(v)?v.trim():v,f,R))===!0&&N(L,f?f.concat(v):[v],E+1)}),D.pop()}}if(!c.isObject(n))throw new TypeError("data must be an object");return N(n),e}var re=si;function xo(n){let e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"};return encodeURIComponent(n).replace(/[!'()~]|%20/g,function(t){return e[t]})}function vo(n,e){this._pairs=[],n&&re(n,this,e)}var Io=vo.prototype;Io.append=function(e,o){this._pairs.push([e,o])};Io.toString=function(e){let o=e?function(t){return e.call(this,t,xo)}:xo;return this._pairs.map(function(r){return o(r[0])+"="+o(r[1])},"").join("&")};var xt=vo;function ii(n){return encodeURIComponent(n).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function $e(n,e,o){if(!e)return n;let t=o&&o.encode||ii,r=c.isFunction(o)?{serialize:o}:o,s=r&&r.serialize,i;if(s?i=s(e,r):i=c.isURLSearchParams(e)?e.toString():new xt(e,r).toString(t),i){let a=n.indexOf("#");a!==-1&&(n=n.slice(0,a)),n+=(n.indexOf("?")===-1?"?":"&")+i}return n}var cn=class{constructor(){this.handlers=[]}use(e,o,t){return this.handlers.push({fulfilled:e,rejected:o,synchronous:t?t.synchronous:!1,runWhen:t?t.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){c.forEach(this.handlers,function(t){t!==null&&e(t)})}},un=cn;var Re={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0,advertiseZstdAcceptEncoding:!1};var So=typeof URLSearchParams<"u"?URLSearchParams:xt;var Lo=typeof FormData<"u"?FormData:null;var Co=typeof Blob<"u"?Blob:null;var Ao={isBrowser:!0,classes:{URLSearchParams:So,FormData:Lo,Blob:Co},protocols:["http","https","file","blob","url","data"]};var pn={};Yn(pn,{hasBrowserEnv:()=>mn,hasStandardBrowserEnv:()=>ai,hasStandardBrowserWebWorkerEnv:()=>ci,navigator:()=>dn,origin:()=>ui});var mn=typeof window<"u"&&typeof document<"u",dn=typeof navigator=="object"&&navigator||void 0,ai=mn&&(!dn||["ReactNative","NativeScript","NS"].indexOf(dn.product)<0),ci=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",ui=mn&&window.location.href||"http://localhost";var _={...pn,...Ao};function ln(n,e){return re(n,new _.classes.URLSearchParams,{visitor:function(o,t,r,s){return _.isNode&&c.isBuffer(o)?(this.append(t,o.toString("base64")),!1):s.defaultVisitor.apply(this,arguments)},...e})}function di(n){return c.matchAll(/\w+|\[(\w*)]/g,n).map(e=>e[0]==="[]"?"":e[1]||e[0])}function mi(n){let e={},o=Object.keys(n),t,r=o.length,s;for(t=0;t<r;t++)s=o[t],e[s]=n[s];return e}function pi(n){function e(o,t,r,s){let i=o[s++];if(i==="__proto__")return!0;let a=Number.isFinite(+i),u=s>=o.length;return i=!i&&c.isArray(r)?r.length:i,u?(c.hasOwnProp(r,i)?r[i]=c.isArray(r[i])?r[i].concat(t):[r[i],t]:r[i]=t,!a):((!c.hasOwnProp(r,i)||!c.isObject(r[i]))&&(r[i]=[]),e(o,t,r[i],s)&&c.isArray(r[i])&&(r[i]=mi(r[i])),!a)}if(c.isFormData(n)&&c.isFunction(n.entries)){let o={};return c.forEachEntry(n,(t,r)=>{e(di(t),r,o,0)}),o}return null}var vt=pi;var Ne=(n,e)=>n!=null&&c.hasOwnProp(n,e)?n[e]:void 0;function li(n,e,o){if(c.isString(n))try{return(e||JSON.parse)(n),c.trim(n)}catch(t){if(t.name!=="SyntaxError")throw t}return(o||JSON.stringify)(n)}var fn={transitional:Re,adapter:["xhr","http","fetch"],transformRequest:[function(e,o){let t=o.getContentType()||"",r=t.indexOf("application/json")>-1,s=c.isObject(e);if(s&&c.isHTMLForm(e)&&(e=new FormData(e)),c.isFormData(e))return r?JSON.stringify(vt(e)):e;if(c.isArrayBuffer(e)||c.isBuffer(e)||c.isStream(e)||c.isFile(e)||c.isBlob(e)||c.isReadableStream(e))return e;if(c.isArrayBufferView(e))return e.buffer;if(c.isURLSearchParams(e))return o.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let a;if(s){let u=Ne(this,"formSerializer");if(t.indexOf("application/x-www-form-urlencoded")>-1)return ln(e,u).toString();if((a=c.isFileList(e))||t.indexOf("multipart/form-data")>-1){let d=Ne(this,"env"),m=d&&d.FormData;return re(a?{"files[]":e}:e,m&&new m,u)}}return s||r?(o.setContentType("application/json",!1),li(e)):e}],transformResponse:[function(e){let o=Ne(this,"transitional")||fn.transitional,t=o&&o.forcedJSONParsing,r=Ne(this,"responseType"),s=r==="json";if(c.isResponse(e)||c.isReadableStream(e))return e;if(e&&c.isString(e)&&(t&&!r||s)){let a=!(o&&o.silentJSONParsing)&&s;try{return JSON.parse(e,Ne(this,"parseReviver"))}catch(u){if(a)throw u.name==="SyntaxError"?P.from(u,P.ERR_BAD_RESPONSE,this,null,Ne(this,"response")):u}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:_.classes.FormData,Blob:_.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};c.forEach(["delete","get","head","post","put","patch","query"],n=>{fn.headers[n]={}});var xe=fn;function ze(n,e){let o=this||xe,t=e||o,r=j.from(t.headers),s=t.data;return c.forEach(n,function(a){s=a.call(o,s,r.normalize(),e?e.status:void 0)}),r.normalize(),s}function Ke(n){return!!(n&&n.__CANCEL__)}var gn=class extends P{constructor(e,o,t){super(e??"canceled",P.ERR_CANCELED,o,t),this.name="CanceledError",this.__CANCEL__=!0}},X=gn;function Ye(n,e,o){let t=o.config.validateStatus;!o.status||!t||t(o.status)?n(o):e(new P("Request failed with status code "+o.status,o.status>=400&&o.status<500?P.ERR_BAD_REQUEST:P.ERR_BAD_RESPONSE,o.config,o.request,o))}function Tn(n){let e=/^([-+\w]{1,25}):(?:\/\/)?/.exec(n);return e&&e[1]||""}function fi(n,e){n=n||10;let o=new Array(n),t=new Array(n),r=0,s=0,i;return e=e!==void 0?e:1e3,function(u){let d=Date.now(),m=t[s];i||(i=d),o[r]=u,t[r]=d;let h=s,D=0;for(;h!==r;)D+=o[h++],h=h%n;if(r=(r+1)%n,r===s&&(s=(s+1)%n),d-i<e)return;let R=m&&d-m;return R?Math.round(D*1e3/R):void 0}}var Oo=fi;function gi(n,e){let o=0,t=1e3/e,r,s,i=(d,m=Date.now())=>{o=m,r=null,s&&(clearTimeout(s),s=null),n(...d)};return[(...d)=>{let m=Date.now(),h=m-o;h>=t?i(d,m):(r=d,s||(s=setTimeout(()=>{s=null,i(r)},t-h)))},()=>r&&i(r)]}var wo=gi;var ve=(n,e,o=3)=>{let t=0,r=Oo(50,250);return wo(s=>{if(!s||typeof s.loaded!="number")return;let i=s.loaded,a=s.lengthComputable?s.total:void 0,u=a!=null?Math.min(i,a):i,d=Math.max(0,u-t),m=r(d);t=Math.max(t,u);let h={loaded:u,total:a,progress:a?u/a:void 0,bytes:d,rate:m||void 0,estimated:m&&a?(a-u)/m:void 0,event:s,lengthComputable:a!=null,[e?"download":"upload"]:!0};n(h)},o)},hn=(n,e)=>{let o=n!=null;return[t=>e[0]({lengthComputable:o,total:n,loaded:t}),e[1]]},Pn=n=>(...e)=>c.asap(()=>n(...e));var _o=_.hasStandardBrowserEnv?((n,e)=>o=>(o=new URL(o,_.origin),n.protocol===o.protocol&&n.host===o.host&&(e||n.port===o.port)))(new URL(_.origin),_.navigator&&/(msie|trident)/i.test(_.navigator.userAgent)):()=>!0;var Mo=_.hasStandardBrowserEnv?{write(n,e,o,t,r,s,i){if(typeof document>"u")return;let a=[`${n}=${encodeURIComponent(e)}`];c.isNumber(o)&&a.push(`expires=${new Date(o).toUTCString()}`),c.isString(t)&&a.push(`path=${t}`),c.isString(r)&&a.push(`domain=${r}`),s===!0&&a.push("secure"),c.isString(i)&&a.push(`SameSite=${i}`),document.cookie=a.join("; ")},read(n){if(typeof document>"u")return null;let e=document.cookie.split(";");for(let o=0;o<e.length;o++){let t=e[o].replace(/^\s+/,""),r=t.indexOf("=");if(r!==-1&&t.slice(0,r)===n)return decodeURIComponent(t.slice(r+1))}return null},remove(n){this.write(n,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function yn(n){return typeof n!="string"?!1:/^([a-z][a-z\d+\-.]*:)?\/\//i.test(n)}function En(n,e){return e?n.replace(/\/?\/$/,"")+"/"+e.replace(/^\/+/,""):n}function Je(n,e,o){let t=!yn(e);return n&&(t||o===!1)?En(n,e):e}var Uo=n=>n instanceof j?{...n}:n;function K(n,e){e=e||{};let o=Object.create(null);Object.defineProperty(o,"hasOwnProperty",{__proto__:null,value:Object.prototype.hasOwnProperty,enumerable:!1,writable:!0,configurable:!0});function t(d,m,h,D){return c.isPlainObject(d)&&c.isPlainObject(m)?c.merge.call({caseless:D},d,m):c.isPlainObject(m)?c.merge({},m):c.isArray(m)?m.slice():m}function r(d,m,h,D){if(c.isUndefined(m)){if(!c.isUndefined(d))return t(void 0,d,h,D)}else return t(d,m,h,D)}function s(d,m){if(!c.isUndefined(m))return t(void 0,m)}function i(d,m){if(c.isUndefined(m)){if(!c.isUndefined(d))return t(void 0,d)}else return t(void 0,m)}function a(d,m,h){if(c.hasOwnProp(e,h))return t(d,m);if(c.hasOwnProp(n,h))return t(void 0,d)}let u={url:s,method:s,data:s,baseURL:i,transformRequest:i,transformResponse:i,paramsSerializer:i,timeout:i,timeoutMessage:i,withCredentials:i,withXSRFToken:i,adapter:i,responseType:i,xsrfCookieName:i,xsrfHeaderName:i,onUploadProgress:i,onDownloadProgress:i,decompress:i,maxContentLength:i,maxBodyLength:i,beforeRedirect:i,transport:i,httpAgent:i,httpsAgent:i,cancelToken:i,socketPath:i,allowedSocketPaths:i,responseEncoding:i,validateStatus:a,headers:(d,m,h)=>r(Uo(d),Uo(m),h,!0)};return c.forEach(Object.keys({...n,...e}),function(m){if(m==="__proto__"||m==="constructor"||m==="prototype")return;let h=c.hasOwnProp(u,m)?u[m]:r,D=c.hasOwnProp(n,m)?n[m]:void 0,R=c.hasOwnProp(e,m)?e[m]:void 0,N=h(D,R,m);c.isUndefined(N)&&h!==a||(o[m]=N)}),o}var Ti=["content-type","content-length"];function hi(n,e,o){if(o!=="content-only"){n.set(e);return}Object.entries(e).forEach(([t,r])=>{Ti.includes(t.toLowerCase())&&n.set(t,r)})}var Pi=n=>encodeURIComponent(n).replace(/%([0-9A-F]{2})/gi,(e,o)=>String.fromCharCode(parseInt(o,16)));function yi(n){let e=K({},n),o=D=>c.hasOwnProp(e,D)?e[D]:void 0,t=o("data"),r=o("withXSRFToken"),s=o("xsrfHeaderName"),i=o("xsrfCookieName"),a=o("headers"),u=o("auth"),d=o("baseURL"),m=o("allowAbsoluteUrls"),h=o("url");if(e.headers=a=j.from(a),e.url=$e(Je(d,h,m),o("params"),o("paramsSerializer")),u&&a.set("Authorization","Basic "+btoa((u.username||"")+":"+(u.password?Pi(u.password):""))),c.isFormData(t)&&(_.hasStandardBrowserEnv||_.hasStandardBrowserWebWorkerEnv||c.isReactNative(t)?a.setContentType(void 0):c.isFunction(t.getHeaders)&&hi(a,t.getHeaders(),o("formDataHeaderPolicy"))),_.hasStandardBrowserEnv&&(c.isFunction(r)&&(r=r(e)),r===!0||r==null&&_o(e.url))){let R=s&&i&&Mo.read(i);R&&a.set(s,R)}return e}var It=yi;var Ei=typeof XMLHttpRequest<"u",jo=Ei&&function(n){return new Promise(function(o,t){let r=It(n),s=r.data,i=j.from(r.headers).normalize(),{responseType:a,onUploadProgress:u,onDownloadProgress:d}=r,m,h,D,R,N;function T(){R&&R(),N&&N(),r.cancelToken&&r.cancelToken.unsubscribe(m),r.signal&&r.signal.removeEventListener("abort",m)}let f=new XMLHttpRequest;f.open(r.method.toUpperCase(),r.url,!0),f.timeout=r.timeout;function E(){if(!f)return;let L=j.from("getAllResponseHeaders"in f&&f.getAllResponseHeaders()),H={data:!a||a==="text"||a==="json"?f.responseText:f.response,status:f.status,statusText:f.statusText,headers:L,config:n,request:f};Ye(function(Oe){o(Oe),T()},function(Oe){t(Oe),T()},H),f=null}"onloadend"in f?f.onloadend=E:f.onreadystatechange=function(){!f||f.readyState!==4||f.status===0&&!(f.responseURL&&f.responseURL.startsWith("file:"))||setTimeout(E)},f.onabort=function(){f&&(t(new P("Request aborted",P.ECONNABORTED,n,f)),T(),f=null)},f.onerror=function(v){let H=v&&v.message?v.message:"Network Error",se=new P(H,P.ERR_NETWORK,n,f);se.event=v||null,t(se),T(),f=null},f.ontimeout=function(){let v=r.timeout?"timeout of "+r.timeout+"ms exceeded":"timeout exceeded",H=r.transitional||Re;r.timeoutErrorMessage&&(v=r.timeoutErrorMessage),t(new P(v,H.clarifyTimeoutError?P.ETIMEDOUT:P.ECONNABORTED,n,f)),T(),f=null},s===void 0&&i.setContentType(null),"setRequestHeader"in f&&c.forEach(Dt(i),function(v,H){f.setRequestHeader(H,v)}),c.isUndefined(r.withCredentials)||(f.withCredentials=!!r.withCredentials),a&&a!=="json"&&(f.responseType=r.responseType),d&&([D,N]=ve(d,!0),f.addEventListener("progress",D)),u&&f.upload&&([h,R]=ve(u),f.upload.addEventListener("progress",h),f.upload.addEventListener("loadend",R)),(r.cancelToken||r.signal)&&(m=L=>{f&&(t(!L||L.type?new X(null,n,f):L),f.abort(),T(),f=null)},r.cancelToken&&r.cancelToken.subscribe(m),r.signal&&(r.signal.aborted?m():r.signal.addEventListener("abort",m)));let S=Tn(r.url);if(S&&!_.protocols.includes(S)){t(new P("Unsupported protocol "+S+":",P.ERR_BAD_REQUEST,n));return}f.send(s||null)})};var bi=(n,e)=>{if(n=n?n.filter(Boolean):[],!e&&!n.length)return;let o=new AbortController,t=!1,r=function(u){if(!t){t=!0,i();let d=u instanceof Error?u:this.reason;o.abort(d instanceof P?d:new X(d instanceof Error?d.message:d))}},s=e&&setTimeout(()=>{s=null,r(new P(`timeout of ${e}ms exceeded`,P.ETIMEDOUT))},e),i=()=>{n&&(s&&clearTimeout(s),s=null,n.forEach(u=>{u.unsubscribe?u.unsubscribe(r):u.removeEventListener("abort",r)}),n=null)};n.forEach(u=>u.addEventListener("abort",r));let{signal:a}=o;return a.unsubscribe=()=>c.asap(i),a},Bo=bi;var Di=function*(n,e){let o=n.byteLength;if(!e||o<e){yield n;return}let t=0,r;for(;t<o;)r=t+e,yield n.slice(t,r),t=r},Ri=async function*(n,e){for await(let o of Ni(n))yield*Di(o,e)},Ni=async function*(n){if(n[Symbol.asyncIterator]){yield*n;return}let e=n.getReader();try{for(;;){let{done:o,value:t}=await e.read();if(o)break;yield t}}finally{await e.cancel()}},bn=(n,e,o,t)=>{let r=Ri(n,e),s=0,i,a=u=>{i||(i=!0,t&&t(u))};return new ReadableStream({async pull(u){try{let{done:d,value:m}=await r.next();if(d){a(),u.close();return}let h=m.byteLength;if(o){let D=s+=h;o(D)}u.enqueue(new Uint8Array(m))}catch(d){throw a(d),d}},cancel(u){return a(u),r.return()}},{highWaterMark:2})};function Dn(n){if(!n||typeof n!="string"||!n.startsWith("data:"))return 0;let e=n.indexOf(",");if(e<0)return 0;let o=n.slice(5,e),t=n.slice(e+1);if(/;base64/i.test(o)){let i=t.length,a=t.length;for(let R=0;R<a;R++)if(t.charCodeAt(R)===37&&R+2<a){let N=t.charCodeAt(R+1),T=t.charCodeAt(R+2);(N>=48&&N<=57||N>=65&&N<=70||N>=97&&N<=102)&&(T>=48&&T<=57||T>=65&&T<=70||T>=97&&T<=102)&&(i-=2,R+=2)}let u=0,d=a-1,m=R=>R>=2&&t.charCodeAt(R-2)===37&&t.charCodeAt(R-1)===51&&(t.charCodeAt(R)===68||t.charCodeAt(R)===100);d>=0&&(t.charCodeAt(d)===61?(u++,d--):m(d)&&(u++,d-=3)),u===1&&d>=0&&(t.charCodeAt(d)===61||m(d))&&u++;let D=Math.floor(i/4)*3-(u||0);return D>0?D:0}if(typeof Buffer<"u"&&typeof Buffer.byteLength=="function")return Buffer.byteLength(t,"utf8");let s=0;for(let i=0,a=t.length;i<a;i++){let u=t.charCodeAt(i);if(u<128)s+=1;else if(u<2048)s+=2;else if(u>=55296&&u<=56319&&i+1<a){let d=t.charCodeAt(i+1);d>=56320&&d<=57343?(s+=4,i++):s+=3}else s+=3}return s}var Ie="1.17.0";var Fo=64*1024,{isFunction:St}=c,xi=n=>encodeURIComponent(n).replace(/%([0-9A-F]{2})/gi,(e,o)=>String.fromCharCode(parseInt(o,16))),ko=n=>{if(!c.isString(n))return n;try{return decodeURIComponent(n)}catch{return n}},qo=(n,...e)=>{try{return!!n(...e)}catch{return!1}},vi=n=>{let e=n.indexOf("://"),o=n;return e!==-1&&(o=o.slice(e+3)),o.includes("@")||o.includes(":")},Ii=n=>{let e=c.global!==void 0&&c.global!==null?c.global:globalThis,{ReadableStream:o,TextEncoder:t}=e;n=c.merge.call({skipUndefined:!0},{Request:e.Request,Response:e.Response},n);let{fetch:r,Request:s,Response:i}=n,a=r?St(r):typeof fetch=="function",u=St(s),d=St(i);if(!a)return!1;let m=a&&St(o),h=a&&(typeof t=="function"?(E=>S=>E.encode(S))(new t):async E=>new Uint8Array(await new s(E).arrayBuffer())),D=u&&m&&qo(()=>{let E=!1,S=new s(_.origin,{body:new o,method:"POST",get duplex(){return E=!0,"half"}}),L=S.headers.has("Content-Type");return S.body!=null&&S.body.cancel(),E&&!L}),R=d&&m&&qo(()=>c.isReadableStream(new i("").body)),N={stream:R&&(E=>E.body)};a&&["text","arrayBuffer","blob","formData","stream"].forEach(E=>{!N[E]&&(N[E]=(S,L)=>{let v=S&&S[E];if(v)return v.call(S);throw new P(`Response type '${E}' is not supported`,P.ERR_NOT_SUPPORT,L)})});let T=async E=>{if(E==null)return 0;if(c.isBlob(E))return E.size;if(c.isSpecCompliantForm(E))return(await new s(_.origin,{method:"POST",body:E}).arrayBuffer()).byteLength;if(c.isArrayBufferView(E)||c.isArrayBuffer(E))return E.byteLength;if(c.isURLSearchParams(E)&&(E=E+""),c.isString(E))return(await h(E)).byteLength},f=async(E,S)=>{let L=c.toFiniteNumber(E.getContentLength());return L??T(S)};return async E=>{let{url:S,method:L,data:v,signal:H,cancelToken:se,timeout:Oe,onDownloadProgress:Gt,onUploadProgress:qn,responseType:ne,headers:Q,withCredentials:rt="same-origin",fetchOptions:Vn,maxContentLength:Y,maxBodyLength:Xt}=It(E),we=c.isNumber(Y)&&Y>-1,Nr=c.isNumber(Xt)&&Xt>-1,xr=w=>c.hasOwnProp(E,w)?E[w]:void 0,Hn=r||fetch;ne=ne?(ne+"").toLowerCase():"text";let oe=Bo([H,se&&se.toAbortSignal()],Oe),$=null,ie=oe&&oe.unsubscribe&&(()=>{oe.unsubscribe()}),$n;try{let w,Z=xr("auth");if(Z){let x=Z.username||"",W=Z.password||"";w={username:x,password:W}}if(vi(S)){let x=new URL(S,_.origin);if(!w&&(x.username||x.password)){let W=ko(x.username),he=ko(x.password);w={username:W,password:he}}(x.username||x.password)&&(x.username="",x.password="",S=x.href)}if(w&&(Q.delete("authorization"),Q.set("Authorization","Basic "+btoa(xi((w.username||"")+":"+(w.password||""))))),we&&typeof S=="string"&&S.startsWith("data:")&&Dn(S)>Y)throw new P("maxContentLength size of "+Y+" exceeded",P.ERR_BAD_RESPONSE,E,$);if(Nr&&L!=="get"&&L!=="head"){let x=await f(Q,v);if(typeof x=="number"&&isFinite(x)&&x>Xt)throw new P("Request body larger than maxBodyLength limit",P.ERR_BAD_REQUEST,E,$)}if(qn&&D&&L!=="get"&&L!=="head"&&($n=await f(Q,v))!==0){let x=new s(S,{method:"POST",body:v,duplex:"half"}),W;if(c.isFormData(v)&&(W=x.headers.get("content-type"))&&Q.setContentType(W),x.body){let[he,st]=hn($n,ve(Pn(qn)));v=bn(x.body,Fo,he,st)}}c.isString(rt)||(rt=rt?"include":"omit");let vr=u&&"credentials"in s.prototype;if(c.isFormData(v)){let x=Q.getContentType();x&&/^multipart\/form-data/i.test(x)&&!/boundary=/i.test(x)&&Q.delete("content-type")}Q.set("User-Agent","axios/"+Ie,!1);let zn={...Vn,signal:oe,method:L.toUpperCase(),headers:Dt(Q.normalize()),body:v,duplex:"half",credentials:vr?rt:void 0};$=u&&new s(S,zn);let J=await(u?Hn($,Vn):Hn(S,zn));if(we){let x=c.toFiniteNumber(J.headers.get("content-length"));if(x!=null&&x>Y)throw new P("maxContentLength size of "+Y+" exceeded",P.ERR_BAD_RESPONSE,E,$)}let Qt=R&&(ne==="stream"||ne==="response");if(R&&J.body&&(Gt||we||Qt&&ie)){let x={};["status","statusText","headers"].forEach(_e=>{x[_e]=J[_e]});let W=c.toFiniteNumber(J.headers.get("content-length")),[he,st]=Gt&&hn(W,ve(Pn(Gt),!0))||[],Kn=0,Ir=_e=>{if(we&&(Kn=_e,Kn>Y))throw new P("maxContentLength size of "+Y+" exceeded",P.ERR_BAD_RESPONSE,E,$);he&&he(_e)};J=new i(bn(J.body,Fo,Ir,()=>{st&&st(),ie&&ie()}),x)}ne=ne||"text";let ee=await N[c.findKey(N,ne)||"text"](J,E);if(we&&!R&&!Qt){let x;if(ee!=null&&(typeof ee.byteLength=="number"?x=ee.byteLength:typeof ee.size=="number"?x=ee.size:typeof ee=="string"&&(x=typeof t=="function"?new t().encode(ee).byteLength:ee.length)),typeof x=="number"&&x>Y)throw new P("maxContentLength size of "+Y+" exceeded",P.ERR_BAD_RESPONSE,E,$)}return!Qt&&ie&&ie(),await new Promise((x,W)=>{Ye(x,W,{data:ee,headers:j.from(J.headers),status:J.status,statusText:J.statusText,config:E,request:$})})}catch(w){if(ie&&ie(),oe&&oe.aborted&&oe.reason instanceof P){let Z=oe.reason;throw Z.config=E,$&&(Z.request=$),w!==Z&&(Z.cause=w),Z}throw w&&w.name==="TypeError"&&/Load failed|fetch/i.test(w.message)?Object.assign(new P("Network Error",P.ERR_NETWORK,E,$,w&&w.response),{cause:w.cause||w}):P.from(w,w&&w.code,E,$,w&&w.response)}}},Si=new Map,Rn=n=>{let e=n&&n.env||{},{fetch:o,Request:t,Response:r}=e,s=[t,r,o],i=s.length,a=i,u,d,m=Si;for(;a--;)u=s[a],d=m.get(u),d===void 0&&m.set(u,d=a?new Map:Ii(e)),m=d;return d},Ud=Rn();var Nn={http:Nt,xhr:jo,fetch:{get:Rn}};c.forEach(Nn,(n,e)=>{if(n){try{Object.defineProperty(n,"name",{__proto__:null,value:e})}catch{}Object.defineProperty(n,"adapterName",{__proto__:null,value:e})}});var Vo=n=>`- ${n}`,Ci=n=>c.isFunction(n)||n===null||n===!1;function Ai(n,e){n=c.isArray(n)?n:[n];let{length:o}=n,t,r,s={};for(let i=0;i<o;i++){t=n[i];let a;if(r=t,!Ci(t)&&(r=Nn[(a=String(t)).toLowerCase()],r===void 0))throw new P(`Unknown adapter '${a}'`);if(r&&(c.isFunction(r)||(r=r.get(e))))break;s[a||"#"+i]=r}if(!r){let i=Object.entries(s).map(([u,d])=>`adapter ${u} `+(d===!1?"is not supported by the environment":"is not available in the build")),a=o?i.length>1?`since :
`+i.map(Vo).join(`
`):" "+Vo(i[0]):"as no adapter specified";throw new P("There is no suitable adapter to dispatch the request "+a,"ERR_NOT_SUPPORT")}return r}var Lt={getAdapter:Ai,adapters:Nn};function xn(n){if(n.cancelToken&&n.cancelToken.throwIfRequested(),n.signal&&n.signal.aborted)throw new X(null,n)}function Ct(n){return xn(n),n.headers=j.from(n.headers),n.data=ze.call(n,n.transformRe