????

Your IP : 18.223.169.109


Current Path : C:/Program Files/Azure Data Studio/resources/app/extensions/azurecore/dist/
Upload File :
Current File : C:/Program Files/Azure Data Studio/resources/app/extensions/azurecore/dist/extension.js

/*! For license information please see extension.js.LICENSE.txt */
(()=>{var e={3253:(e,t,n)=>{"use strict";function r(e){return e.toLowerCase()}function o(e){return!(!e||"object"!=typeof e)&&"function"==typeof e.rawHeaders&&"function"==typeof e.clone&&"function"==typeof e.get&&"function"==typeof e.set&&"function"==typeof e.contains&&"function"==typeof e.remove&&"function"==typeof e.headersArray&&"function"==typeof e.headerValues&&"function"==typeof e.headerNames&&"function"==typeof e.toJson}n.r(t),n.d(t,{ApiKeyCredentials:()=>Pt,AzureIdentityCredentialAdapter:()=>mt,BaseRequestPolicy:()=>Se,BasicAuthenticationCredentials:()=>Rt,Constants:()=>Me,DefaultHttpClient:()=>ge,DomainCredentials:()=>Nt,HttpHeaders:()=>i,HttpPipelineLogLevel:()=>ve,MapperType:()=>U,QueryCollectionFormat:()=>Je,RequestPolicyOptions:()=>Ce,RestError:()=>Z,Serializer:()=>O,ServiceClient:()=>vt,TokenCredentials:()=>wt,TopicCredentials:()=>Ot,URLBuilder:()=>se,URLQuery:()=>ie,WebResource:()=>F,agentPolicy:()=>tt,applyMixins:()=>A,delay:()=>C,deserializationPolicy:()=>xe,deserializeResponseBody:()=>Re,encodeUri:()=>y,executePromisesSequentially:()=>S,exponentialRetryPolicy:()=>Pe,flattenResponse:()=>Et,generateClientRequestIdPolicy:()=>ke,generateUuid:()=>T,getDefaultProxySettings:()=>at,getDefaultUserAgentValue:()=>Fe,isDuration:()=>R,isNode:()=>g,isValidUuid:()=>E,logPolicy:()=>Tt,promiseToCallback:()=>x,promiseToServiceCallback:()=>w,proxyPolicy:()=>ct,redirectPolicy:()=>He,serializeObject:()=>j,signingPolicy:()=>Qe,stripRequest:()=>b,stripResponse:()=>_,systemErrorRetryPolicy:()=>Xe,throttlingRetryPolicy:()=>dt,userAgentPolicy:()=>ze});var i=function(){function e(e){if(this._headersMap={},e)for(var t in e)this.set(t,e[t])}return e.prototype.set=function(e,t){this._headersMap[r(e)]={name:e,value:t.toString()}},e.prototype.get=function(e){var t=this._headersMap[r(e)];return t?t.value:void 0},e.prototype.contains=function(e){return!!this._headersMap[r(e)]},e.prototype.remove=function(e){var t=this.contains(e);return delete this._headersMap[r(e)],t},e.prototype.rawHeaders=function(){var e={};for(var t in this._headersMap){var n=this._headersMap[t];e[n.name.toLowerCase()]=n.value}return e},e.prototype.headersArray=function(){var e=[];for(var t in this._headersMap)e.push(this._headersMap[t]);return e},e.prototype.headerNames=function(){for(var e=[],t=this.headersArray(),n=0;n<t.length;++n)e.push(t[n].name);return e},e.prototype.headerValues=function(){for(var e=[],t=this.headersArray(),n=0;n<t.length;++n)e.push(t[n].value);return e},e.prototype.toJson=function(){return this.rawHeaders()},e.prototype.toString=function(){return JSON.stringify(this.toJson())},e.prototype.clone=function(){return new e(this.rawHeaders())},e}();function s(e){return(e instanceof Buffer?e:Buffer.from(e.buffer)).toString("base64")}function a(e){return Buffer.from(e,"base64")}var c=n(6982),u=n.n(c);const l=new Uint8Array(256);let p=l.length;function d(){return p>l.length-16&&(u().randomFillSync(l),p=0),l.slice(p,p+=16)}const h=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,f=[];for(let e=0;e<256;++e)f.push((e+256).toString(16).substr(1));const m=function(e,t=0){const n=(f[e[t+0]]+f[e[t+1]]+f[e[t+2]]+f[e[t+3]]+"-"+f[e[t+4]]+f[e[t+5]]+"-"+f[e[t+6]]+f[e[t+7]]+"-"+f[e[t+8]]+f[e[t+9]]+"-"+f[e[t+10]]+f[e[t+11]]+f[e[t+12]]+f[e[t+13]]+f[e[t+14]]+f[e[t+15]]).toLowerCase();if(!function(e){return"string"==typeof e&&h.test(e)}(n))throw TypeError("Stringified UUID is invalid");return n},v=function(e,t,n){const r=(e=e||{}).random||(e.rng||d)();if(r[6]=15&r[6]|64,r[8]=63&r[8]|128,t){n=n||0;for(let e=0;e<16;++e)t[n+e]=r[e];return t}return m(r)};var g="undefined"!=typeof process&&!!process.version&&!!process.versions&&!!process.versions.node;function y(e){return encodeURIComponent(e).replace(/!/g,"%21").replace(/"/g,"%27").replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/\*/g,"%2A")}function _(e){var t={};return t.body=e.bodyAsText,t.headers=e.headers,t.status=e.status,t}function b(e){var t=e.clone();return t.headers&&t.headers.remove("authorization"),t}function E(e){return new RegExp("^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","ig").test(e)}function T(){return v()}function S(e,t){var n=Promise.resolve(t);return e.forEach((function(e){n=n.then(e)})),n}function C(e,t){return new Promise((function(n){return setTimeout((function(){return n(t)}),e)}))}function x(e){if("function"!=typeof e.then)throw new Error("The provided input is not a Promise.");return function(t){e.then((function(e){t(void 0,e)}),(function(e){t(e)}))}}function w(e){if("function"!=typeof e.then)throw new Error("The provided input is not a Promise.");return function(t){e.then((function(e){process.nextTick(t,void 0,e.parsedBody,e.request,e)}),(function(e){process.nextTick(t,e)}))}}function A(e,t){t.forEach((function(t){Object.getOwnPropertyNames(t.prototype).forEach((function(n){e.prototype[n]=t.prototype[n]}))}))}var I=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function R(e){return I.test(e)}function P(e,t,n){return e&&t?e.split(t).join(n||""):e}var O=function(){function e(e,t){void 0===e&&(e={}),this.modelMappers=e,this.isXML=t}return e.prototype.validateConstraints=function(e,t,n){var r=function(e,r){throw new Error('"'+n+'" with value "'+t+'" should satisfy the constraint "'+e+'": '+r+".")};if(e.constraints&&null!=t){var o=e.constraints,i=o.ExclusiveMaximum,s=o.ExclusiveMinimum,a=o.InclusiveMaximum,c=o.InclusiveMinimum,u=o.MaxItems,l=o.MaxLength,p=o.MinItems,d=o.MinLength,h=o.MultipleOf,f=o.Pattern,m=o.UniqueItems;if(null!=i&&t>=i&&r("ExclusiveMaximum",i),null!=s&&t<=s&&r("ExclusiveMinimum",s),null!=a&&t>a&&r("InclusiveMaximum",a),null!=c&&t<c&&r("InclusiveMinimum",c),null!=u&&t.length>u&&r("MaxItems",u),null!=l&&t.length>l&&r("MaxLength",l),null!=p&&t.length<p&&r("MinItems",p),null!=d&&t.length<d&&r("MinLength",d),null!=h&&t%h!=0&&r("MultipleOf",h),f){var v="string"==typeof f?new RegExp(f):f;"string"==typeof t&&null!==t.match(v)||r("Pattern",f)}m&&t.some((function(e,t,n){return n.indexOf(e)!==t}))&&r("UniqueItems",m)}},e.prototype.serialize=function(e,t,n){var r={},o=e.type.name;n||(n=e.serializedName),null!==o.match(/^Sequence$/gi)&&(r=[]),e.isConstant&&(t=e.defaultValue);var i=e.required,a=e.nullable;if(i&&a&&void 0===t)throw new Error(n+" cannot be undefined.");if(i&&!a&&null==t)throw new Error(n+" cannot be null or undefined.");if(!i&&!1===a&&null===t)throw new Error(n+" cannot be null.");return null==t?r=t:(this.validateConstraints(e,t,n),null!==o.match(/^any$/gi)?r=t:null!==o.match(/^(Number|String|Boolean|Object|Stream|Uuid)$/gi)?r=function(e,t,n){if(null!=n)if(null!==e.match(/^Number$/gi)){if("number"!=typeof n)throw new Error(t+" with value "+n+" must be of type number.")}else if(null!==e.match(/^String$/gi)){if("string"!=typeof n.valueOf())throw new Error(t+' with value "'+n+'" must be of type string.')}else if(null!==e.match(/^Uuid$/gi)){if("string"!=typeof n.valueOf()||!E(n))throw new Error(t+' with value "'+n+'" must be of type string and a valid uuid.')}else if(null!==e.match(/^Boolean$/gi)){if("boolean"!=typeof n)throw new Error(t+" with value "+n+" must be of type boolean.")}else if(null!==e.match(/^Stream$/gi)){var r=typeof n;if(!("string"===r||"function"===r||n instanceof ArrayBuffer||ArrayBuffer.isView(n)||"function"==typeof Blob&&n instanceof Blob))throw new Error(t+" must be a string, Blob, ArrayBuffer, ArrayBufferView, or a function returning NodeJS.ReadableStream.")}return n}(o,n,t):null!==o.match(/^Enum$/gi)?r=function(e,t,n){if(!t)throw new Error("Please provide a set of allowedValues to validate "+e+" as an Enum Type.");if(!t.some((function(e){return"string"==typeof e.valueOf()?e.toLowerCase()===n.toLowerCase():e===n})))throw new Error(n+" is not a valid value for "+e+". The valid values are: "+JSON.stringify(t)+".");return n}(n,e.type.allowedValues,t):null!==o.match(/^(Date|DateTime|TimeSpan|DateTimeRfc1123|UnixTime)$/gi)?r=function(e,t,n){if(null!=t)if(null!==e.match(/^Date$/gi)){if(!(t instanceof Date||"string"==typeof t.valueOf()&&!isNaN(Date.parse(t))))throw new Error(n+" must be an instanceof Date or a string in ISO8601 format.");t=t instanceof Date?t.toISOString().substring(0,10):new Date(t).toISOString().substring(0,10)}else if(null!==e.match(/^DateTime$/gi)){if(!(t instanceof Date||"string"==typeof t.valueOf()&&!isNaN(Date.parse(t))))throw new Error(n+" must be an instanceof Date or a string in ISO8601 format.");t=t instanceof Date?t.toISOString():new Date(t).toISOString()}else if(null!==e.match(/^DateTimeRfc1123$/gi)){if(!(t instanceof Date||"string"==typeof t.valueOf()&&!isNaN(Date.parse(t))))throw new Error(n+" must be an instanceof Date or a string in RFC-1123 format.");t=t instanceof Date?t.toUTCString():new Date(t).toUTCString()}else if(null!==e.match(/^UnixTime$/gi)){if(!(t instanceof Date||"string"==typeof t.valueOf()&&!isNaN(Date.parse(t))))throw new Error(n+" must be an instanceof Date or a string in RFC-1123/ISO8601 format for it to be serialized in UnixTime/Epoch format.");t=function(e){if(e)return"string"==typeof e.valueOf()&&(e=new Date(e)),Math.floor(e.getTime()/1e3)}(t)}else if(null!==e.match(/^TimeSpan$/gi)&&!R(t))throw new Error(n+' must be a string in ISO 8601 format. Instead was "'+t+'".');return t}(o,t,n):null!==o.match(/^ByteArray$/gi)?r=function(e,t){if(null!=t){if(!(t instanceof Uint8Array))throw new Error(e+" must be of type Uint8Array.");t=s(t)}return t}(n,t):null!==o.match(/^Base64Url$/gi)?r=function(e,t){if(null!=t){if(!(t instanceof Uint8Array))throw new Error(e+" must be of type Uint8Array.");t=function(e){if(e){if(!(e instanceof Uint8Array))throw new Error("Please provide an input of type Uint8Array for converting to Base64Url.");return function(e){for(var t=e.length;t-1>=0&&"="===e[t-1];)--t;return e.substr(0,t)}(s(e)).replace(/\+/g,"-").replace(/\//g,"_")}}(t)}return t}(n,t):null!==o.match(/^Sequence$/gi)?r=function(e,t,n,r){if(!Array.isArray(n))throw new Error(r+" must be of type Array.");var o=t.type.element;if(!o||"object"!=typeof o)throw new Error('element" metadata for an Array must be defined in the mapper and it must of type "object" in '+r+".");for(var i=[],s=0;s<n.length;s++)i[s]=e.serialize(o,n[s],r);return i}(this,e,t,n):null!==o.match(/^Dictionary$/gi)?r=function(e,t,n,r){if("object"!=typeof n)throw new Error(r+" must be of type object.");var o=t.type.value;if(!o||"object"!=typeof o)throw new Error('"value" metadata for a Dictionary must be defined in the mapper and it must of type "object" in '+r+".");for(var i={},s=0,a=Object.keys(n);s<a.length;s++){var c=a[s];i[c]=e.serialize(o,n[c],r+"."+c)}return i}(this,e,t,n):null!==o.match(/^Composite$/gi)&&(r=function(e,t,n,r){var o;if(M(e,t)&&(t=D(e,t,n,"clientName")),null!=n){for(var i={},s=k(e,t,r),a=0,c=Object.keys(s);a<c.length;a++){var u=c[a],l=s[u];if(!l.readOnly){var p=void 0,d=i;if(e.isXML)p=l.xmlIsWrapped?l.xmlName:l.xmlElementName||l.xmlName;else{var h=N(l.serializedName);p=h.pop();for(var f=0,m=h;f<m.length;f++){var v=m[f];null==d[v]&&null!=n[u]&&(d[v]={}),d=d[v]}}if(null!=d){var g=""!==l.serializedName?r+"."+l.serializedName:r,y=n[u],_=M(e,t);_&&_.clientName===u&&null==y&&(y=t.serializedName);var b=e.serialize(l,y,g);void 0!==b&&null!=p&&(l.xmlIsAttribute?(d.$=d.$||{},d.$[p]=b):l.xmlIsWrapped?d[p]=((o={})[l.xmlElementName]=b,o):d[p]=b)}}}var E=t.type.additionalProperties;if(E){var T=Object.keys(s),S=function(t){T.every((function(e){return e!==t}))&&(i[t]=e.serialize(E,n[t],r+'["'+t+'"]'))};for(var C in n)S(C)}return i}return n}(this,e,t,n))),r},e.prototype.deserialize=function(e,t,n){if(null==t)return this.isXML&&"Sequence"===e.type.name&&!e.xmlIsWrapped&&(t=[]),void 0!==e.defaultValue&&(t=e.defaultValue),t;var r,o=e.type.name;return n||(n=e.serializedName),null!==o.match(/^Composite$/gi)?r=function(e,t,n,r){M(e,t)&&(t=D(e,t,n,"serializedName"));for(var o=k(e,t,r),i={},s=[],a=0,c=Object.keys(o);a<c.length;a++){var u=c[a],l=o[u],p=N(o[u].serializedName);s.push(p[0]);var d=l.serializedName,h=l.xmlName,f=l.xmlElementName,m=r;""!==d&&void 0!==d&&(m=r+"."+d);var v=l.headerCollectionPrefix;if(v){for(var g={},y=0,_=Object.keys(n);y<_.length;y++){var b=_[y];b.startsWith(v)&&(g[b.substring(v.length)]=e.deserialize(l.type.value,n[b],m)),s.push(b)}i[u]=g}else if(e.isXML)if(l.xmlIsAttribute&&n.$)i[u]=e.deserialize(l,n.$[h],m);else{var E=n[f||h||d];l.xmlIsWrapped&&void 0===(E=(E=n[h])&&E[f])&&(E=[]),i[u]=e.deserialize(l,E,m)}else{for(var T=void 0,S=n,C=0,x=p;C<x.length;C++){var w=x[C];if(!S)break;S=S[w]}T=S;var A=t.type.polymorphicDiscriminator;A&&u===A.clientName&&null==T&&(T=t.serializedName);var I=void 0;if(Array.isArray(n[u])&&""===o[u].serializedName){T=n[u];for(var R=e.deserialize(l,T,m),P=0,O=Object.entries(i);P<O.length;P++){var L=O[P],j=L[0],U=L[1];R.hasOwnProperty(j)||(R[j]=U)}i=R}else void 0===T&&void 0===l.defaultValue||(I=e.deserialize(l,T,m),i[u]=I)}}var F=t.type.additionalProperties;if(F){var z=function(e){for(var t in o)if(N(o[t].serializedName)[0]===e)return!1;return!0};for(var q in n)z(q)&&(i[q]=e.deserialize(F,n[q],r+'["'+q+'"]'))}else if(n)for(var B=0,H=Object.keys(n);B<H.length;B++)void 0!==i[u=H[B]]||s.includes(u)||["$","_"].includes(u)||(i[u]=n[u]);return i}(this,e,t,n):(this.isXML&&null!=t.$&&null!=t._&&(t=t._),null!==o.match(/^Number$/gi)?(r=parseFloat(t),isNaN(r)&&(r=t)):null!==o.match(/^Boolean$/gi)?r="true"===t||"false"!==t&&t:null!==o.match(/^(String|Enum|Object|Stream|Uuid|TimeSpan|any)$/gi)?r=t:null!==o.match(/^(Date|DateTime|DateTimeRfc1123)$/gi)?r=new Date(t):null!==o.match(/^UnixTime$/gi)?r=function(e){if(e)return new Date(1e3*e)}(t):null!==o.match(/^ByteArray$/gi)?r=a(t):null!==o.match(/^Base64Url$/gi)?r=function(e){if(e){if(e&&"string"!=typeof e.valueOf())throw new Error("Please provide an input of type string for converting to Uint8Array");return a(e=e.replace(/\-/g,"+").replace(/\_/g,"/"))}}(t):null!==o.match(/^Sequence$/gi)?r=function(e,t,n,r){var o=t.type.element;if(!o||"object"!=typeof o)throw new Error('element" metadata for an Array must be defined in the mapper and it must of type "object" in '+r);if(n){Array.isArray(n)||(n=[n]);for(var i=[],s=0;s<n.length;s++)i[s]=e.deserialize(o,n[s],r+"["+s+"]");return i}return n}(this,e,t,n):null!==o.match(/^Dictionary$/gi)&&(r=function(e,t,n,r){var o=t.type.value;if(!o||"object"!=typeof o)throw new Error('"value" metadata for a Dictionary must be defined in the mapper and it must of type "object" in '+r);if(n){for(var i={},s=0,a=Object.keys(n);s<a.length;s++){var c=a[s];i[c]=e.deserialize(o,n[c],r)}return i}return n}(this,e,t,n))),e.isConstant&&(r=e.defaultValue),r},e}();function N(e){var t=[],n="";if(e)for(var r=0,o=e.split(".");r<o.length;r++){var i=o[r];"\\"===i.charAt(i.length-1)?n+=i.substr(0,i.length-1)+".":(n+=i,t.push(n),n="")}return t}function k(e,t,n){var r=t.type.modelProperties;if(!r){var o=t.type.className;if(!o)throw new Error('Class name for model "'+n+'" is not provided in the mapper "'+JSON.stringify(t,void 0,2)+'".');var i=e.modelMappers[o];if(!i)throw new Error('mapper() cannot be null or undefined for model "'+o+'".');if(!(r=i.type.modelProperties))throw new Error('modelProperties cannot be null or undefined in the mapper "'+JSON.stringify(i)+'" of type "'+o+'" for object "'+n+'".')}return r}function D(e,t,n,r){var o=M(e,t);if(o){var i=o[r];if(null!=i){var s=n[i];if(null!=s){var a=t.type.uberParent||t.type.className,c=s===a?s:a+"."+s,u=e.modelMappers.discriminators[c];u&&(t=u)}}}return t}function M(e,t){return t.type.polymorphicDiscriminator||L(e,t.type.uberParent)||L(e,t.type.className)}function L(e,t){return t&&e.modelMappers[t]&&e.modelMappers[t].type.polymorphicDiscriminator}function j(e){if(null!=e){if(e instanceof Uint8Array)return s(e);if(e instanceof Date)return e.toISOString();if(Array.isArray(e)){for(var t=[],n=0;n<e.length;n++)t.push(j(e[n]));return t}if("object"==typeof e){var r={};for(var o in e)r[o]=j(e[o]);return r}return e}}var U=function(){for(var e={},t=0,n=["Base64Url","Boolean","ByteArray","Composite","Date","DateTime","DateTimeRfc1123","Dictionary","Enum","Number","Object","Sequence","String","Stream","TimeSpan","UnixTime"];t<n.length;t++){var r=n[t];e[r]=r}return e}(),F=function(){function e(e,t,n,r,s,a,c,u,l,p,d,h,f,m,v){this.streamResponseBody=a,this.url=e||"",this.method=t||"GET",this.headers=o(s)?s:new i(s),this.body=n,this.query=r,this.formData=void 0,this.withCredentials=c||!1,this.abortSignal=u,this.timeout=l||0,this.onUploadProgress=p,this.onDownloadProgress=d,this.proxySettings=h,this.keepAlive=f,this.agentSettings=m,this.redirectLimit=v}return e.prototype.validateRequestProperties=function(){if(!this.method)throw new Error("WebResource.method is required.");if(!this.url)throw new Error("WebResource.url is required.")},e.prototype.prepare=function(e){if(!e)throw new Error("options object is required");if(null==e.method||"string"!=typeof e.method.valueOf())throw new Error("options.method must be a string.");if(e.url&&e.pathTemplate)throw new Error("options.url and options.pathTemplate are mutually exclusive. Please provide exactly one of them.");if(!(null!=e.pathTemplate&&"string"==typeof e.pathTemplate.valueOf()||null!=e.url&&"string"==typeof e.url.valueOf()))throw new Error("Please provide exactly one of options.pathTemplate or options.url.");if(e.url){if("string"!=typeof e.url)throw new Error('options.url must be of type "string".');this.url=e.url}if(e.method){var t=["GET","PUT","HEAD","DELETE","OPTIONS","POST","PATCH","TRACE"];if(-1===t.indexOf(e.method.toUpperCase()))throw new Error('The provided method "'+e.method+'" is invalid. Supported HTTP methods are: '+JSON.stringify(t))}if(this.method=e.method.toUpperCase(),e.pathTemplate){var n=e.pathTemplate,r=e.pathParameters;if("string"!=typeof n)throw new Error('options.pathTemplate must be of type "string".');e.baseUrl||(e.baseUrl="https://management.azure.com");var o=e.baseUrl,i=o+(o.endsWith("/")?"":"/")+(n.startsWith("/")?n.slice(1):n),s=i.match(/({\w*\s*\w*})/gi);if(s&&s.length){if(!r)throw new Error("pathTemplate: "+n+" has been provided. Hence, options.pathParameters must also be provided.");s.forEach((function(e){var t=e.slice(1,-1),o=r[t];if(null==o||"string"!=typeof o&&"object"!=typeof o)throw new Error("pathTemplate: "+n+" contains the path parameter "+t+" however, it is not present in "+r+" - "+JSON.stringify(r,void 0,2)+'.The value of the path parameter can either be a "string" of the form { '+t+': "some sample value" } or it can be an "object" of the form { "'+t+'": { value: "some sample value", skipUrlEncoding: true } }.');if("string"==typeof o.valueOf()&&(i=i.replace(e,encodeURIComponent(o))),"object"==typeof o.valueOf()){if(!o.value)throw new Error("options.pathParameters["+t+'] is of type "object" but it does not contain a "value" property.');i=o.skipUrlEncoding?i.replace(e,o.value):i.replace(e,encodeURIComponent(o.value))}}))}this.url=i}if(e.queryParameters){var a=e.queryParameters;if("object"!=typeof a)throw new Error('options.queryParameters must be of type object. It should be a JSON object of "query-parameter-name" as the key and the "query-parameter-value" as the value. The "query-parameter-value" may be fo type "string" or an "object" of the form { value: "query-parameter-value", skipUrlEncoding: true }.');this.url&&-1===this.url.indexOf("?")&&(this.url+="?");var c=[];for(var u in this.query={},a){var l=a[u];if(l)if("string"==typeof l)c.push(u+"="+encodeURIComponent(l)),this.query[u]=encodeURIComponent(l);else if("object"==typeof l){if(!l.value)throw new Error("options.queryParameters["+u+'] is of type "object" but it does not contain a "value" property.');l.skipUrlEncoding?(c.push(u+"="+l.value),this.query[u]=l.value):(c.push(u+"="+encodeURIComponent(l.value)),this.query[u]=encodeURIComponent(l.value))}}this.url+=c.join("&")}if(e.headers)for(var p=e.headers,d=0,h=Object.keys(e.headers);d<h.length;d++){var f=h[d];this.headers.set(f,p[f])}return this.headers.get("accept-language")||this.headers.set("accept-language","en-US"),this.headers.get("x-ms-client-request-id")||e.disableClientRequestId||this.headers.set("x-ms-client-request-id",T()),this.headers.get("Content-Type")||this.headers.set("Content-Type","application/json; charset=utf-8"),this.body=e.body,null!=e.body&&(e.bodyIsStream?(this.headers.get("Transfer-Encoding")||this.headers.set("Transfer-Encoding","chunked"),"application/octet-stream"!==this.headers.get("Content-Type")&&this.headers.set("Content-Type","application/octet-stream")):(e.serializationMapper&&(this.body=new O(e.mappers).serialize(e.serializationMapper,e.body,"requestBody")),e.disableJsonStringifyOnBody||(this.body=JSON.stringify(e.body)))),this.abortSignal=e.abortSignal,this.onDownloadProgress=e.onDownloadProgress,this.onUploadProgress=e.onUploadProgress,this.redirectLimit=e.redirectLimit,this.streamResponseBody=e.streamResponseBody,this},e.prototype.clone=function(){var t=new e(this.url,this.method,this.body,this.query,this.headers&&this.headers.clone(),this.streamResponseBody,this.withCredentials,this.abortSignal,this.timeout,this.onUploadProgress,this.onDownloadProgress,this.proxySettings,this.keepAlive,this.agentSettings,this.redirectLimit);return this.formData&&(t.formData=this.formData),this.operationSpec&&(t.operationSpec=this.operationSpec),this.shouldDeserialize&&(t.shouldDeserialize=this.shouldDeserialize),this.operationResponseGetter&&(t.operationResponseGetter=this.operationResponseGetter),t},e}(),z=function(e,t){return z=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},z(e,t)};function q(e,t){function n(){this.constructor=e}z(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var B=function(){return B=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},B.apply(this,arguments)};function H(e,t,n,r){return new(n||(n=Promise))((function(o,i){function s(e){try{c(r.next(e))}catch(e){i(e)}}function a(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(s,a)}c((r=r.apply(e,t||[])).next())}))}function G(e,t){var n,r,o,i,s={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function a(i){return function(a){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return s.label++,{value:i[1],done:!1};case 5:s.label++,r=i[1],i=[0];continue;case 7:i=s.ops.pop(),s.trys.pop();continue;default:if(!((o=(o=s.trys).length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){s=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){s.label=i[1];break}if(6===i[0]&&s.label<o[1]){s.label=o[1],o=i;break}if(o&&s.label<o[2]){s.label=o[2],s.ops.push(i);break}o[2]&&s.ops.pop(),s.trys.pop();continue}i=t.call(e,s)}catch(e){i=[6,e],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,a])}}}var V=n(8611),$=n(5692);const K=require("node-fetch");var W=n.n(K),Q=n(6584),Y=n.n(Q),X=n(1706),J=n.n(X),Z=function(e){function t(n,r,o,i,s,a){var c=e.call(this,n)||this;return c.code=r,c.statusCode=o,c.request=i,c.response=s,c.body=a,Object.setPrototypeOf(c,t.prototype),c}return q(t,e),t.REQUEST_SEND_ERROR="REQUEST_SEND_ERROR",t.REQUEST_ABORTED_ERROR="REQUEST_ABORTED_ERROR",t.PARSE_ERROR="PARSE_ERROR",t}(Error),ee=n(2203),te=function(){function e(){}return e.prototype.sendRequest=function(e){return H(this,void 0,void 0,(function(){var t,n,r,o,s,a,c,u,l,p,d,h,f,m,v,g,y,_,b,E,T,S,C,x,w,A,I,R,P,O;return G(this,(function(N){switch(N.label){case 0:if(!e&&"object"!=typeof e)throw new Error("'httpRequest' (WebResource) cannot be null or undefined and must be of type object.");if(t=new(Y()),e.abortSignal){if(e.abortSignal.aborted)throw new Z("The request was aborted",Z.REQUEST_ABORTED_ERROR,void 0,e);n=function(e){"abort"===e.type&&t.abort()},e.abortSignal.addEventListener("abort",n)}if(e.timeout&&setTimeout((function(){t.abort()}),e.timeout),e.formData){for(r=e.formData,o=new(J()),s=function(e,t){"function"==typeof t&&(t=t()),t&&t.hasOwnProperty("value")&&t.hasOwnProperty("options")?o.append(e,t.value,t.options):o.append(e,t)},a=0,c=Object.keys(r);a<c.length;a++)if(u=c[a],l=r[u],Array.isArray(l))for(p=0;p<l.length;p++)s(u,l[p]);else s(u,l);e.body=o,e.formData=void 0,(d=e.headers.get("Content-Type"))&&-1!==d.indexOf("multipart/form-data")&&("function"==typeof o.getBoundary?e.headers.set("Content-Type","multipart/form-data; boundary="+o.getBoundary()):e.headers.remove("Content-Type"))}return h=e.body?"function"==typeof e.body?e.body():e.body:void 0,e.onUploadProgress&&e.body&&(f=0,m=new ee.Transform({transform:function(t,n,r){f+=t.length,e.onUploadProgress({loadedBytes:f}),r(void 0,t)}}),ne(h)?h.pipe(m):m.end(h),h=m),[4,this.prepareRequest(e)];case 1:v=N.sent(),g=B({body:h,headers:e.headers.rawHeaders(),method:e.method,signal:t.signal,redirect:"manual"},v),N.label=2;case 2:return N.trys.push([2,8,9,10]),[4,this.fetch(e.url,g)];case 3:return _=N.sent(),b=function(e){var t=new i;return e.forEach((function(e,n){t.set(n,e)})),t}(_.headers),E={headers:b,request:e,status:_.status,readableStreamBody:e.streamResponseBody?_.body:void 0},e.streamResponseBody?[3,5]:[4,_.text()];case 4:return T=N.sent(),[3,6];case 5:T=void 0,N.label=6;case 6:return E.bodyAsText=T,E.redirected=_.redirected,E.url=_.url,y=E,(S=e.onDownloadProgress)&&(ne(C=_.body||void 0)?(x=0,w=new ee.Transform({transform:function(e,t,n){x+=e.length,S({loadedBytes:x}),n(void 0,e)}}),C.pipe(w),y.readableStreamBody=w):(A=parseInt(b.get("Content-Length"))||void 0)&&S({loadedBytes:A})),[4,this.processRequest(y)];case 7:return N.sent(),[2,y];case 8:if(I=N.sent(),"ENOTFOUND"===(R=I).code)throw new Z(R.message,Z.REQUEST_SEND_ERROR,void 0,e);if("aborted"===R.type)throw new Z("The request was aborted",Z.REQUEST_ABORTED_ERROR,void 0,e);throw R;case 9:return e.abortSignal&&n&&(P=Promise.resolve(),ne(h)&&(P=re(h)),O=Promise.resolve(),ne(null==y?void 0:y.readableStreamBody)&&(O=re(y.readableStreamBody)),Promise.all([P,O]).then((function(){var t;null===(t=e.abortSignal)||void 0===t||t.removeEventListener("abort",n)})).catch((function(e){}))),[7];case 10:return[2]}}))}))},e}();function ne(e){return e&&"function"==typeof e.pipe}function re(e){return new Promise((function(t){e.on("close",t),e.on("end",t),e.on("error",t)}))}var oe=n(803),ie=function(){function e(){this._rawQuery={}}return e.prototype.any=function(){return Object.keys(this._rawQuery).length>0},e.prototype.set=function(e,t){if(e)if(null!=t){var n=Array.isArray(t)?t:t.toString();this._rawQuery[e]=n}else delete this._rawQuery[e]},e.prototype.get=function(e){return e?this._rawQuery[e]:void 0},e.prototype.toString=function(){var e="";for(var t in this._rawQuery){e&&(e+="&");var n=this._rawQuery[t];if(Array.isArray(n)){for(var r=[],o=0,i=n;o<i.length;o++){var s=i[o];r.push(t+"="+s)}e+=r.join("&")}else e+=t+"="+n}return e},e.parse=function(t){var n=new e;if(t){t.startsWith("?")&&(t=t.substring(1));for(var r="ParameterName",o="",i="",s=0;s<t.length;++s){var a=t[s];switch(r){case"ParameterName":switch(a){case"=":r="ParameterValue";break;case"&":o="",i="";break;default:o+=a}break;case"ParameterValue":"&"===a?(n.set(o,i),o="",i="",r="ParameterName"):i+=a;break;default:throw new Error("Unrecognized URLQuery parse state: "+r)}}"ParameterValue"===r&&n.set(o,i)}return n},e}(),se=function(){function e(){}return e.prototype.setScheme=function(e){e?this.set(e,"SCHEME"):this._scheme=void 0},e.prototype.getScheme=function(){return this._scheme},e.prototype.setHost=function(e){e?this.set(e,"SCHEME_OR_HOST"):this._host=void 0},e.prototype.getHost=function(){return this._host},e.prototype.setPort=function(e){null==e||""===e?this._port=void 0:this.set(e.toString(),"PORT")},e.prototype.getPort=function(){return this._port},e.prototype.setPath=function(e){if(e){var t=e.indexOf("://");if(-1!==t){var n=e.lastIndexOf("/",t);this.set(-1===n?e:e.substr(n+1),"SCHEME")}else this.set(e,"PATH")}else this._path=void 0},e.prototype.appendPath=function(e){if(e){var t=this.getPath();t&&(t.endsWith("/")||(t+="/"),e.startsWith("/")&&(e=e.substring(1)),e=t+e),this.set(e,"PATH")}},e.prototype.getPath=function(){return this._path},e.prototype.setQuery=function(e){this._query=e?ie.parse(e):void 0},e.prototype.setQueryParameter=function(e,t){e&&(this._query||(this._query=new ie),this._query.set(e,t))},e.prototype.getQueryParameterValue=function(e){return this._query?this._query.get(e):void 0},e.prototype.getQuery=function(){return this._query?this._query.toString():void 0},e.prototype.set=function(e,t){for(var n=new ce(e,t);n.next();){var r=n.current();if(r)switch(r.type){case"SCHEME":this._scheme=r.text||void 0;break;case"HOST":this._host=r.text||void 0;break;case"PORT":this._port=r.text||void 0;break;case"PATH":var o=r.text||void 0;this._path&&"/"!==this._path&&"/"===o||(this._path=o);break;case"QUERY":this._query=ie.parse(r.text);break;default:throw new Error("Unrecognized URLTokenType: "+r.type)}}},e.prototype.toString=function(){var e="";return this._scheme&&(e+=this._scheme+"://"),this._host&&(e+=this._host),this._port&&(e+=":"+this._port),this._path&&(this._path.startsWith("/")||(e+="/"),e+=this._path),this._query&&this._query.any()&&(e+="?"+this._query.toString()),e},e.prototype.replaceAll=function(e,t){e&&(this.setScheme(P(this.getScheme(),e,t)),this.setHost(P(this.getHost(),e,t)),this.setPort(P(this.getPort(),e,t)),this.setPath(P(this.getPath(),e,t)),this.setQuery(P(this.getQuery(),e,t)))},e.parse=function(t){var n=new e;return n.set(t,"SCHEME_OR_HOST"),n},e}(),ae=function(){function e(e,t){this.text=e,this.type=t}return e.scheme=function(t){return new e(t,"SCHEME")},e.host=function(t){return new e(t,"HOST")},e.port=function(t){return new e(t,"PORT")},e.path=function(t){return new e(t,"PATH")},e.query=function(t){return new e(t,"QUERY")},e}(),ce=function(){function e(e,t){this._text=e,this._textLength=e?e.length:0,this._currentState=null!=t?t:"SCHEME_OR_HOST",this._currentIndex=0}return e.prototype.current=function(){return this._currentToken},e.prototype.next=function(){if(ue(this))switch(this._currentState){case"SCHEME":t=function(e){return he(e,(function(e){return function(e){var t=e.charCodeAt(0);return 48<=t&&t<=57||65<=t&&t<=90||97<=t&&t<=122}(e)}))}(e=this),e._currentToken=ae.scheme(t),ue(e)?e._currentState="HOST":e._currentState="DONE";break;case"SCHEME_OR_HOST":!function(e){var t=fe(e,":","/","?");ue(e)?":"===le(e)?"://"===de(e,3)?(e._currentToken=ae.scheme(t),e._currentState="HOST"):(e._currentToken=ae.host(t),e._currentState="PORT"):(e._currentToken=ae.host(t),"/"===le(e)?e._currentState="PATH":e._currentState="QUERY"):(e._currentToken=ae.host(t),e._currentState="DONE")}(this);break;case"HOST":!function(e){"://"===de(e,3)&&pe(e,3);var t=fe(e,":","/","?");e._currentToken=ae.host(t),ue(e)?":"===le(e)?e._currentState="PORT":"/"===le(e)?e._currentState="PATH":e._currentState="QUERY":e._currentState="DONE"}(this);break;case"PORT":!function(e){":"===le(e)&&pe(e);var t=fe(e,"/","?");e._currentToken=ae.port(t),ue(e)?"/"===le(e)?e._currentState="PATH":e._currentState="QUERY":e._currentState="DONE"}(this);break;case"PATH":!function(e){var t=fe(e,"?");e._currentToken=ae.path(t),ue(e)?e._currentState="QUERY":e._currentState="DONE"}(this);break;case"QUERY":!function(e){"?"===le(e)&&pe(e);var t=function(e){var t="";return e._currentIndex<e._textLength&&(t=e._text.substring(e._currentIndex),e._currentIndex=e._textLength),t}(e);e._currentToken=ae.query(t),e._currentState="DONE"}(this);break;default:throw new Error("Unrecognized URLTokenizerState: "+this._currentState)}else this._currentToken=void 0;var e,t;return!!this._currentToken},e}();function ue(e){return e._currentIndex<e._textLength}function le(e){return e._text[e._currentIndex]}function pe(e,t){ue(e)&&(t||(t=1),e._currentIndex+=t)}function de(e,t){var n=e._currentIndex+t;return e._textLength<n&&(n=e._textLength),e._text.substring(e._currentIndex,n)}function he(e,t){for(var n="";ue(e);){var r=le(e);if(!t(r))break;n+=r,pe(e)}return n}function fe(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];return he(e,(function(e){return-1===t.indexOf(e)}))}function me(e,t,n){return e&&t?oe.httpsOverHttps(n):e&&!t?oe.httpsOverHttp(n):!e&&t?oe.httpOverHttps(n):oe.httpOverHttp(n)}var ve,ge=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return q(t,e),t.prototype.fetch=function(e,t){return H(this,void 0,void 0,(function(){return G(this,(function(n){return[2,W()(e,t)]}))}))},t.prototype.prepareRequest=function(e){return H(this,void 0,void 0,(function(){var t,n,r,o,i,s,a;return G(this,(function(c){return t={},e.agentSettings?(n=e.agentSettings,r=n.http,(o=n.https)&&e.url.startsWith("https")?t.agent=o:r&&(t.agent=r)):e.proxySettings&&(i=function(e,t,n){var r={proxy:{host:se.parse(t.host).getHost(),port:t.port,headers:n&&n.rawHeaders()||{}}};t.username&&t.password?r.proxy.proxyAuth=t.username+":"+t.password:t.username&&(r.proxy.proxyAuth=""+t.username);var o="https"===(se.parse(e).getScheme()||"").toLowerCase();return{isHttps:o,agent:me(o,"https"===(se.parse(t.host).getScheme()||"").toLowerCase(),r)}}(e.url,e.proxySettings,e.headers),t.agent=i.agent),!0===e.keepAlive&&(t.agent?t.agent.keepAlive=!0:(s={keepAlive:!0},a=e.url.startsWith("https")?new $.Agent(s):new V.Agent(s),t.agent=a)),[2,t]}))}))},t.prototype.processRequest=function(e){return H(this,void 0,void 0,(function(){return G(this,(function(e){return[2]}))}))},t}(te);function ye(e){return _e(e.parameterPath,e.mapper)}function _e(e,t){return"string"==typeof e?e:Array.isArray(e)?e.join("."):t.serializedName}function be(e){var t=!1;for(var n in e.responses){var r=e.responses[n];if(r.bodyMapper&&r.bodyMapper.type.name===U.Stream){t=!0;break}}return t}!function(e){e[e.OFF=0]="OFF",e[e.ERROR=1]="ERROR",e[e.WARNING=2]="WARNING",e[e.INFO=3]="INFO"}(ve||(ve={}));var Ee=n(8805);function Te(e,t){return new Ee.Builder({rootName:(t||{}).rootName,renderOpts:{pretty:!1}}).buildObject(e)}var Se=function(){function e(e,t){this._nextPolicy=e,this._options=t}return e.prototype.shouldLog=function(e){return this._options.shouldLog(e)},e.prototype.log=function(e,t){this._options.log(e,t)},e}(),Ce=function(){function e(e){this._logger=e}return e.prototype.shouldLog=function(e){return!!this._logger&&e!==ve.OFF&&e<=this._logger.minimumLogLevel},e.prototype.log=function(e,t){this._logger&&this.shouldLog(e)&&this._logger.log(e,t)},e}();function xe(e){return{create:function(t,n){return new Ie(t,e,n)}}}var we=["application/json","text/json"],Ae=["application/xml","application/atom+xml"],Ie=function(e){function t(t,n,r){var o=e.call(this,t,r)||this;return o.jsonContentTypes=n&&n.json||we,o.xmlContentTypes=n&&n.xml||Ae,o}return q(t,e),t.prototype.sendRequest=function(e){return H(this,void 0,void 0,(function(){var t=this;return G(this,(function(n){return[2,this._nextPolicy.sendRequest(e).then((function(e){return Re(t.jsonContentTypes,t.xmlContentTypes,e)}))]}))}))},t}(Se);function Re(e,t,n){return function(e,t,n){var r,o,i=function(e){var t='Error "'+e+'" occurred while parsing the response body - '+n.bodyAsText+".",r=e.code||Z.PARSE_ERROR,o=new Z(t,r,n.status,n.request,n,n.bodyAsText);return Promise.reject(o)};if(!n.request.streamResponseBody&&n.bodyAsText){var s=n.bodyAsText,a=n.headers.get("Content-Type")||"",c=a?a.split(";").map((function(e){return e.toLowerCase()})):[];if(0===c.length||c.some((function(t){return-1!==e.indexOf(t)})))return new Promise((function(e){n.parsedBody=JSON.parse(s),e(n)})).catch(i);if(c.some((function(e){return-1!==t.indexOf(e)})))return(r=s,o=new Ee.Parser({explicitArray:!1,explicitCharkey:!1,explicitRoot:!1}),new Promise((function(e,t){r?o.parseString(r,(function(n,r){n?t(n):e(r)})):t(new Error("Document is empty"))}))).then((function(e){return n.parsedBody=e,n})).catch(i)}return Promise.resolve(n)}(e,t,n).then((function(e){var t=function(e){var t=e.request.shouldDeserialize;return void 0===t||("boolean"==typeof t?t:t(e))}(e);if(t){var r=e.request.operationSpec;if(r&&r.responses){var o=e.status,i=Object.keys(r.responses),s=0===i.length||1===i.length&&"default"===i[0],a=function(e){var t,n=e.request,r=n.operationSpec;if(r){var o=n.operationResponseGetter;t=o?o(r,e):r.responses[e.status]}return t}(e);if(s?200<=o&&o<300:a){if(a){if(a.bodyMapper){m=e.parsedBody,r.isXML&&a.bodyMapper.type.name===U.Sequence&&(m="object"==typeof m?m[a.bodyMapper.xmlElementName]:[]);try{e.parsedBody=r.serializer.deserialize(a.bodyMapper,m,"operationRes.parsedBody")}catch(p){var c=new Z("Error "+p+" occurred in deserializing the responseBody - "+e.bodyAsText);return c.request=b(e.request),c.response=_(e),Promise.reject(c)}}else"HEAD"===r.httpMethod&&(e.parsedBody=n.status>=200&&n.status<300);a.headersMapper&&(e.parsedHeaders=r.serializer.deserialize(a.headersMapper,e.headers.rawHeaders(),"operationRes.parsedHeaders"))}}else{var u=r.responses.default;if(u){var l=be(r)?"Unexpected status code: "+o:e.bodyAsText,p=new Z(l);p.statusCode=o,p.request=b(e.request),p.response=_(e);var d=e.parsedBody;try{if(d){var h=u.bodyMapper;if(h&&"CloudError"===h.serializedName)d.error&&(d=d.error),d.code&&(p.code=d.code),d.message&&(p.message=d.message);else{var f=d;d.error&&(f=d.error),p.code=f.code,f.message&&(p.message=f.message)}if(h){var m=d;r.isXML&&h.type.name===U.Sequence&&(m="object"==typeof d?d[h.xmlElementName]:[]),p.body=r.serializer.deserialize(h,m,"error.body")}}}catch(t){p.message='Error "'+t.message+'" occurred in deserializing the responseBody - "'+e.bodyAsText+'" for the default response.'}return Promise.reject(p)}}}}return Promise.resolve(e)}))}function Pe(e,t,n,r){return{create:function(o,i){return new Oe(o,i,e,t,n,r)}}}var Oe=function(e){function t(t,n,r,o,i,s){var a=e.call(this,t,n)||this;function c(e){return"number"==typeof e}return a.retryCount=c(r)?r:3,a.retryInterval=c(o)?o:3e4,a.minRetryInterval=c(i)?i:3e3,a.maxRetryInterval=c(s)?s:9e4,a}return q(t,e),t.prototype.sendRequest=function(e){var t=this;return this._nextPolicy.sendRequest(e.clone()).then((function(n){return Ne(t,e,n)})).catch((function(n){return Ne(t,e,n.response,void 0,n)}))},t}(Se);function Ne(e,t,n,r,o){r=function(e,t,n){t||(t={retryCount:0,retryInterval:0}),n&&(t.error&&(n.innerError=t.error),t.error=n),t.retryCount++;var r=Math.pow(2,t.retryCount)-1;return r*=.8*e.retryInterval+Math.floor(Math.random()*(1.2*e.retryInterval-.8*e.retryInterval)),t.retryInterval=Math.min(e.minRetryInterval+r,e.maxRetryInterval),t}(e,r,o);var i=t.abortSignal&&t.abortSignal.aborted;if(!i&&function(e,t,n){if(null==t||t<500&&408!==t||501===t||505===t)return!1;if(!n)throw new Error("retryData for the ExponentialRetryPolicyFilter cannot be null.");return(n&&n.retryCount)<e.retryCount}(e,n&&n.status,r))return C(r.retryInterval).then((function(){return e._nextPolicy.sendRequest(t.clone())})).then((function(n){return Ne(e,t,n,r,void 0)})).catch((function(o){return Ne(e,t,n,r,o)}));if(i||o||!n){var s=r.error||new Z("Failed to send the request.",Z.REQUEST_SEND_ERROR,n&&n.status,n&&n.request,n);return Promise.reject(s)}return Promise.resolve(n)}function ke(e){return void 0===e&&(e="x-ms-client-request-id"),{create:function(t,n){return new De(t,n,e)}}}var De=function(e){function t(t,n,r){var o=e.call(this,t,n)||this;return o._requestIdHeaderName=r,o}return q(t,e),t.prototype.sendRequest=function(e){return e.headers.contains(this._requestIdHeaderName)||e.headers.set(this._requestIdHeaderName,T()),this._nextPolicy.sendRequest(e)},t}(Se),Me={msRestVersion:"2.7.0",HTTP:"http:",HTTPS:"https:",HTTP_PROXY:"HTTP_PROXY",HTTPS_PROXY:"HTTPS_PROXY",NO_PROXY:"NO_PROXY",ALL_PROXY:"ALL_PROXY",HttpConstants:{HttpVerbs:{PUT:"PUT",GET:"GET",DELETE:"DELETE",POST:"POST",MERGE:"MERGE",HEAD:"HEAD",PATCH:"PATCH"},StatusCodes:{TooManyRequests:429}},HeaderConstants:{AUTHORIZATION:"authorization",AUTHORIZATION_SCHEME:"Bearer",RETRY_AFTER:"Retry-After",USER_AGENT:"User-Agent"}},Le=n(857);function je(){return Me.HeaderConstants.USER_AGENT}var Ue=je;function Fe(){var e,t,n,r=[{key:"ms-rest-js",value:Me.msRestVersion}],o=[{key:"Node",value:process.version},{key:"OS",value:"("+Le.arch()+"-"+Le.type()+"-"+Le.release()+")"}];return e=r.concat(o),void 0===t&&(t=" "),void 0===n&&(n="/"),e.map((function(e){var t=e.value?""+n+e.value:"";return""+e.key+t})).join(t)}function ze(e){var t=e&&null!=e.key?e.key:je(),n=e&&null!=e.value?e.value:Fe();return{create:function(e,r){return new qe(e,r,t,n)}}}var qe=function(e){function t(t,n,r,o){var i=e.call(this,t,n)||this;return i._nextPolicy=t,i._options=n,i.headerKey=r,i.headerValue=o,i}return q(t,e),t.prototype.sendRequest=function(e){return this.addUserAgentHeader(e),this._nextPolicy.sendRequest(e)},t.prototype.addUserAgentHeader=function(e){e.headers||(e.headers=new i),!e.headers.get(this.headerKey)&&this.headerValue&&e.headers.set(this.headerKey,this.headerValue)},t}(Se),Be={handleRedirects:!0,maxRetries:20};function He(e){return void 0===e&&(e=20),{create:function(t,n){return new Ge(t,n,e)}}}var Ge=function(e){function t(t,n,r){void 0===r&&(r=20);var o=e.call(this,t,n)||this;return o.maxRetries=r,o}return q(t,e),t.prototype.sendRequest=function(e){var t=this;return this._nextPolicy.sendRequest(e).then((function(e){return Ve(t,e,0)}))},t}(Se);function Ve(e,t,n){var r=t.request,o=t.status,i=t.headers.get("location");if(i&&(300===o||301===o&&["GET","HEAD"].includes(r.method)||302===o&&["GET","POST","HEAD"].includes(r.method)||303===o&&"POST"===r.method||307===o)&&(void 0!==r.redirectLimit&&n<r.redirectLimit||void 0===r.redirectLimit&&n<e.maxRetries)){var s=se.parse(r.url);return s.setPath(i),r.url=s.toString(),302!==o&&303!==o||"POST"!==r.method||(r.method="GET",delete r.body),e._nextPolicy.sendRequest(r).then((function(t){return Ve(e,t,n+1)})).then((function(e){return function(e,t){return e.redirected||(e.redirected=!0,e.url=t),e}(e,r.url)}))}return Promise.resolve(t)}var $e=function(e){function t(t,n,r){void 0===r&&(r=30);var o=e.call(this,t,n)||this;return o._retryTimeout=r,o}return q(t,e),t.prototype.sendRequest=function(e){var t=this;return this._nextPolicy.sendRequest(e.clone()).then((function(n){return function(e,t,n){if(409===n.status){var r=function(e){var t,n;if(e){try{n=JSON.parse(e)}catch(e){}if(n&&n.error&&n.error.message&&n.error.code&&"MissingSubscriptionRegistration"===n.error.code){var r=n.error.message.match(/.*'(.*)'/i);r&&(t=r.pop())}}return t}(n.bodyAsText);if(r){var o=function(e){var t=e.match(/.*\/subscriptions\/[a-f0-9-]+\//gi);if(!t||!t[0])throw new Error("Unable to extract subscriptionId from the given url - "+e+".");return t[0]}(t.url);return function(e,t,n,r){var o=t+"providers/"+n+"/register?api-version=2016-02-01",i=t+"providers/"+n+"?api-version=2016-02-01",s=Ke(r);return s.method="POST",s.url=o,e._nextPolicy.sendRequest(s).then((function(t){if(200!==t.status)throw new Error("Autoregistration of "+n+" failed. Please try registering manually.");return We(e,i,r)}))}(e,o,r,t).catch((function(){return!1})).then((function(r){return r?(t.headers.set("x-ms-client-request-id",T()),e._nextPolicy.sendRequest(t.clone())):n}))}}return Promise.resolve(n)}(t,e,n)}))},t}(Se);function Ke(e,t){void 0===t&&(t=!1);var n=e.clone();return t&&(n.url=e.url),n.headers.set("x-ms-client-request-id",T()),n.headers.set("Content-Type","application/json; charset=utf-8"),n}function We(e,t,n){var r=Ke(n);return r.url=t,r.method="GET",e._nextPolicy.sendRequest(r).then((function(r){var o=r.parsedBody;return!(!r.parsedBody||!o.registrationState||"Registered"!==o.registrationState)||C(1e3*e._retryTimeout).then((function(){return We(e,t,n)}))}))}function Qe(e){return{create:function(t,n){return new Ye(t,n,e)}}}var Ye=function(e){function t(t,n,r){var o=e.call(this,t,n)||this;return o.authenticationProvider=r,o}return q(t,e),t.prototype.signRequest=function(e){return this.authenticationProvider.signRequest(e)},t.prototype.sendRequest=function(e){var t=this;return this.signRequest(e).then((function(e){return t._nextPolicy.sendRequest(e)}))},t}(Se);function Xe(e,t,n,r){return{create:function(o,i){return new Ze(o,i,e,t,n,r)}}}var Je,Ze=function(e){function t(t,n,r,o,i,s){var a=e.call(this,t,n)||this;return a.DEFAULT_CLIENT_RETRY_INTERVAL=3e4,a.DEFAULT_CLIENT_RETRY_COUNT=3,a.DEFAULT_CLIENT_MAX_RETRY_INTERVAL=9e4,a.DEFAULT_CLIENT_MIN_RETRY_INTERVAL=3e3,a.retryCount="number"==typeof r?r:a.DEFAULT_CLIENT_RETRY_COUNT,a.retryInterval="number"==typeof o?o:a.DEFAULT_CLIENT_RETRY_INTERVAL,a.minRetryInterval="number"==typeof i?i:a.DEFAULT_CLIENT_MIN_RETRY_INTERVAL,a.maxRetryInterval="number"==typeof s?s:a.DEFAULT_CLIENT_MAX_RETRY_INTERVAL,a}return q(t,e),t.prototype.sendRequest=function(e){var t=this;return this._nextPolicy.sendRequest(e.clone()).catch((function(n){return et(t,e,n.response,n)}))},t}(Se);function et(e,t,n,r,o){return H(this,void 0,void 0,(function(){var i;return G(this,(function(s){switch(s.label){case 0:if(o=function(e,t,n){t||(t={retryCount:0,retryInterval:0}),n&&(t.error&&(n.innerError=t.error),t.error=n),t.retryCount++;var r=Math.pow(2,t.retryCount)-1;return r*=.8*e.retryInterval+Math.floor(Math.random()*(.4*e.retryInterval)),t.retryInterval=Math.min(e.minRetryInterval+r,e.maxRetryInterval),t}(e,o,r),!(r&&r.code&&function(e,t){if(!t)throw new Error("retryData for the SystemErrorRetryPolicyFilter cannot be null.");return(t&&t.retryCount)<e.retryCount}(e,o))||"ETIMEDOUT"!==r.code&&"ESOCKETTIMEDOUT"!==r.code&&"ECONNREFUSED"!==r.code&&"ECONNRESET"!==r.code&&"ENOENT"!==r.code)return[3,5];s.label=1;case 1:return s.trys.push([1,3,,4]),[4,C(o.retryInterval)];case 2:return s.sent(),[2,e._nextPolicy.sendRequest(t.clone())];case 3:return i=s.sent(),[2,et(e,t,n,i,o)];case 4:return[3,6];case 5:return r?[2,Promise.reject(o.error)]:[2,n];case 6:return[2]}}))}))}function tt(e){return{create:function(t,n){return new rt(t,n,e)}}}!function(e){e.Csv=",",e.Ssv=" ",e.Tsv="\t",e.Pipes="|",e.Multi="Multi"}(Je||(Je={}));var nt,rt=function(e){function t(t,n,r){var o=e.call(this,t,n)||this;return o.agentSettings=r,o}return q(t,e),t.prototype.sendRequest=function(e){return e.agentSettings||(e.agentSettings=this.agentSettings),this._nextPolicy.sendRequest(e)},t}(Se),ot=(nt=st(Me.NO_PROXY))?nt.split(",").map((function(e){return e.trim()})).filter((function(e){return e.length})):[],it=new Map;function st(e){return process.env[e]?process.env[e]:process.env[e.toLowerCase()]?process.env[e.toLowerCase()]:void 0}function at(e){if(e||(e=function(){if(process){var e=st(Me.HTTPS_PROXY),t=st(Me.ALL_PROXY),n=st(Me.HTTP_PROXY);return e||t||n}}())){var t=function(e){var t=e.indexOf("@");if(-1===t)return{urlWithoutAuth:e};var n=e.indexOf("://"),r=-1!==n?n+3:0,o=e.substring(r,t),i=o.indexOf(":"),s=-1!==i;return{username:s?o.substring(0,i):o,password:s?o.substring(i+1):void 0,urlWithoutAuth:e.substring(0,r)+e.substring(t+1)}}(e),n=t.username,r=t.password,o=t.urlWithoutAuth,i=se.parse(o);return{host:(i.getScheme()?i.getScheme()+"://":"")+i.getHost(),port:Number.parseInt(i.getPort()||"80"),username:n,password:r}}}function ct(e){return e||(e=at()),{create:function(t,n){return new ut(t,n,e)}}}var ut=function(e){function t(t,n,r){var o=e.call(this,t,n)||this;return o.proxySettings=r,o}return q(t,e),t.prototype.sendRequest=function(e){return e.proxySettings||function(e){if(0===ot.length)return!1;var t=se.parse(e).getHost();if(it.has(t))return it.get(t);for(var n=!1,r=0,o=ot;r<o.length;r++){var i=o[r];"."===i[0]?(t.endsWith(i)||t.length===i.length-1&&t===i.slice(1))&&(n=!0):t===i&&(n=!0)}return it.set(t,n),n}(e.url)||(e.proxySettings=this.proxySettings),this._nextPolicy.sendRequest(e)},t}(Se),lt=Me.HttpConstants.StatusCodes,pt=3;function dt(e){return void 0===e&&(e=pt),{create:function(t,n){return new ht(t,n,e)}}}var ht=function(e){function t(t,n,r){var o=e.call(this,t,n)||this;return o.retryLimit=r,o}return q(t,e),t.prototype.sendRequest=function(e){return H(this,void 0,void 0,(function(){var t=this;return G(this,(function(n){return[2,this._nextPolicy.sendRequest(e.clone()).then((function(n){return t.retry(e,n,0)}))]}))}))},t.prototype.retry=function(e,n,r){return H(this,void 0,void 0,(function(){var o,i,s;return G(this,(function(a){switch(a.label){case 0:return n.status!==lt.TooManyRequests?[2,n]:(o=n.headers.get(Me.HeaderConstants.RETRY_AFTER))&&r<this.retryLimit&&(i=t.parseRetryAfterHeader(o))?[4,C(i)]:[3,3];case 1:return a.sent(),[4,this._nextPolicy.sendRequest(e)];case 2:return s=a.sent(),[2,this.retry(e,s,r+1)];case 3:return[2,n]}}))}))},t.parseRetryAfterHeader=function(e){var n=Number(e);return Number.isNaN(n)?t.parseDateRetryAfterHeader(e):1e3*n},t.parseDateRetryAfterHeader=function(e){try{var t=Date.now(),n=Date.parse(e)-t;return Number.isNaN(n)?void 0:n}catch(e){return}},t}(Se),ft=["https://management.windows.net","https://management.chinacloudapi.cn","https://management.usgovcloudapi.net","https://management.cloudapi.de"],mt=function(){function e(e,t){void 0===t&&(t="https://management.azure.com/.default"),this.azureTokenCredential=e,this.scopes=t}return e.prototype.getToken=function(){return H(this,void 0,void 0,(function(){var e;return G(this,(function(t){switch(t.label){case 0:return[4,this.azureTokenCredential.getToken(this.scopes)];case 1:if(null!==(e=t.sent()))return[2,{accessToken:e.token,tokenType:"Bearer",expiresOn:e.expiresOnTimestamp}];throw new Error("Could find token for scope")}}))}))},e.prototype.signRequest=function(e){return H(this,void 0,void 0,(function(){var t;return G(this,(function(n){switch(n.label){case 0:return[4,this.getToken()];case 1:return t=n.sent(),e.headers.set(Me.HeaderConstants.AUTHORIZATION,t.tokenType+" "+t.accessToken),[2,Promise.resolve(e)]}}))}))},e}(),vt=function(){function e(e,t){var n,r;if(t||(t={}),t.baseUri&&(this.baseUri=t.baseUri),function(e){const t=e;return t&&"function"==typeof t.getToken&&(void 0===t.signRequest||t.getToken.length>0)}(e)){var o=void 0;(null==t?void 0:t.baseUri)&&ft.includes(null==t?void 0:t.baseUri)&&(o=t.baseUri+"/.default"),n=new mt(e,o)}else n=e;if(n&&!n.signRequest)throw new Error("credentials argument needs to implement signRequest method");if(this._withCredentials=t.withCredentials||!1,this._httpClient=t.httpClient||new ge,this._requestPolicyOptions=new Ce(t.httpPipelineLogger),Array.isArray(t.requestPolicyFactories))r=t.requestPolicyFactories;else if(r=function(e,t){var n=[];t.generateClientRequestIdHeader&&n.push(ke(t.clientRequestIdHeaderName)),e&&("function"==typeof e.create?n.push(e):n.push(Qe(e)));var r=gt(t.userAgentHeaderName,Ue),o=gt(t.userAgent,Fe);r&&o&&n.push(ze({key:r,value:o}));var i,s=B(B({},Be),t.redirectOptions);s.handleRedirects&&n.push(He(s.maxRetries)),n.push((void 0===(i=t.rpRegistrationRetryTimeout)&&(i=30),{create:function(e,t){return new $e(e,t,i)}})),t.noRetryPolicy||(n.push(Pe()),n.push(Xe()),n.push(dt())),n.push(xe(t.deserializationContentTypes));var a=t.proxySettings||at();return a&&n.push(ct(a)),t.agentSettings&&n.push(tt(t.agentSettings)),n}(n,t),t.requestPolicyFactories){var i=t.requestPolicyFactories(r);i&&(r=i)}this._requestPolicyFactories=r}return e.prototype.sendRequest=function(e){if(null==e||"object"!=typeof e)throw new Error("options cannot be null or undefined and it must be of type object.");var t,n;try{"object"==typeof(n=e)&&"string"==typeof n.url&&"string"==typeof n.method&&"object"==typeof n.headers&&o(n.headers)&&"function"==typeof n.validateRequestProperties&&"function"==typeof n.prepare&&"function"==typeof n.clone?(e.validateRequestProperties(),t=e):t=(t=new F).prepare(e)}catch(e){return Promise.reject(e)}var r=this._httpClient;if(this._requestPolicyFactories&&this._requestPolicyFactories.length>0)for(var i=this._requestPolicyFactories.length-1;i>=0;--i)r=this._requestPolicyFactories[i].create(r,this._requestPolicyOptions);return r.sendRequest(t)},e.prototype.sendOperationRequest=function(e,t,n){"function"==typeof e.options&&(n=e.options,e.options=void 0);var r,o=new F;try{var i=t.baseUrl||this.baseUri;if(!i)throw new Error("If operationSpec.baseUrl is not specified, then the ServiceClient must have a baseUri string property that contains the base URL to use.");o.method=t.httpMethod,o.operationSpec=t;var s=se.parse(i);if(t.path&&s.appendPath(t.path),t.urlParameters&&t.urlParameters.length>0)for(var a=0,c=t.urlParameters;a<c.length;a++){var u=c[a],l=yt(this,e,u,t.serializer);l=t.serializer.serialize(u.mapper,l,ye(u)),u.skipEncoding||(l=encodeURIComponent(l)),s.replaceAll("{"+(u.mapper.serializedName||ye(u))+"}",l)}if(t.queryParameters&&t.queryParameters.length>0)for(var p=0,d=t.queryParameters;p<d.length;p++){var h=d[p],f=yt(this,e,h,t.serializer);if(null!=f){if(f=t.serializer.serialize(h.mapper,f,ye(h)),null!=h.collectionFormat)if(h.collectionFormat===Je.Multi)if(0===f.length)f="";else for(var m in f){var v=f[m];f[m]=null==v?"":v.toString()}else h.collectionFormat!==Je.Ssv&&h.collectionFormat!==Je.Tsv||(f=f.join(h.collectionFormat));if(!h.skipEncoding)if(Array.isArray(f))for(var m in f)void 0!==f[m]&&null!==f[m]&&(f[m]=encodeURIComponent(f[m]));else f=encodeURIComponent(f);null!=h.collectionFormat&&h.collectionFormat!==Je.Multi&&h.collectionFormat!==Je.Ssv&&h.collectionFormat!==Je.Tsv&&(f=f.join(h.collectionFormat)),s.setQueryParameter(h.mapper.serializedName||ye(h),f)}}o.url=s.toString();var g=t.contentType||this.requestContentType;if(g&&o.headers.set("Content-Type",g),t.headerParameters)for(var y=0,_=t.headerParameters;y<_.length;y++){var b=_[y],E=yt(this,e,b,t.serializer);if(null!=E){E=t.serializer.serialize(b.mapper,E,ye(b));var T=b.mapper.headerCollectionPrefix;if(T)for(var S=0,C=Object.keys(E);S<C.length;S++){var x=C[S];o.headers.set(T+x,E[x])}else o.headers.set(b.mapper.serializedName||ye(b),E)}}var w=e.options;if(w){if(w.customHeaders)for(var A in w.customHeaders)o.headers.set(A,w.customHeaders[A]);w.abortSignal&&(o.abortSignal=w.abortSignal),w.timeout&&(o.timeout=w.timeout),w.onUploadProgress&&(o.onUploadProgress=w.onUploadProgress),w.onDownloadProgress&&(o.onDownloadProgress=w.onDownloadProgress)}o.withCredentials=this._withCredentials,function(e,t,n,r){if(r.requestBody&&r.requestBody.mapper){t.body=yt(e,n,r.requestBody,r.serializer);var o=r.requestBody.mapper,i=o.required,s=o.xmlName,a=o.xmlElementName,c=o.serializedName,u=o.type.name;try{if(null!=t.body||i){var l=ye(r.requestBody);t.body=r.serializer.serialize(o,t.body,l);var p=u===U.Stream;r.isXML?u===U.Sequence?t.body=Te(function(e,t){var n;return Array.isArray(e)||(e=[e]),(n={})[t]=e,n}(t.body,a||s||c),{rootName:s||c}):p||(t.body=Te(t.body,{rootName:s||c})):p||(t.body=JSON.stringify(t.body))}}catch(e){throw new Error('Error "'+e.message+'" occurred in serializing the payload - '+JSON.stringify(c,void 0,"  ")+".")}}else if(r.formDataParameters&&r.formDataParameters.length>0){t.formData={};for(var d=0,h=r.formDataParameters;d<h.length;d++){var f=h[d],m=yt(e,n,f,r.serializer);if(null!=m){var v=f.mapper.serializedName||ye(f);t.formData[v]=r.serializer.serialize(f.mapper,m,ye(f))}}}}(this,o,e,t),null==o.streamResponseBody&&(o.streamResponseBody=be(t)),r=this.sendRequest(o).then((function(e){return Et(e,t.responses[e.status])}))}catch(e){r=Promise.reject(e)}var I=n;return I&&r.then((function(e){return I(null,e._response.parsedBody,e._response.request,e._response)})).catch((function(e){return I(e)})),r},e}();function gt(e,t){var n;return"string"==typeof e?n=e:(n=t(),"function"==typeof e&&(n=e(n))),n}function yt(e,t,n,r){return _t(e,t,n.parameterPath,n.mapper,r)}function _t(e,t,n,r,o){var i;if("string"==typeof n&&(n=[n]),Array.isArray(n)){if(n.length>0){if(r.isConstant)i=r.defaultValue;else{var s=bt(t,n);s.propertyFound||(s=bt(e,n));var a=!1;s.propertyFound||(a=r.required||"options"===n[0]&&2===n.length),i=a?r.defaultValue:s.propertyValue}var c=_e(n,r);o.serialize(r,i,c)}}else for(var u in r.required&&(i={}),n){var l=r.type.modelProperties[u],p=n[u],d=_t(e,t,p,l,o),h=_e(p,l);o.serialize(l,d,h),void 0!==d&&(i||(i={}),i[u]=d)}return i}function bt(e,t){for(var n={propertyFound:!1},r=0;r<t.length;++r){var o=t[r];if(null==e||!(o in e))break;e=e[o]}return r===t.length&&(n.propertyValue=e,n.propertyFound=!0),n}function Et(e,t){var n,r=e.parsedHeaders,o=t&&t.bodyMapper,i=function(t){return Object.defineProperty(t,"_response",{value:e})};if(o){var s=o.type.name;if("Stream"===s)return i(B(B({},r),{blobBody:e.blobBody,readableStreamBody:e.readableStreamBody}));var a="Composite"===s&&o.type.modelProperties||{},c=Object.keys(a).some((function(e){return""===a[e].serializedName}));if("Sequence"===s||c){for(var u=function(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;var r=Array(e),o=0;for(t=0;t<n;t++)for(var i=arguments[t],s=0,a=i.length;s<a;s++,o++)r[o]=i[s];return r}(Array.isArray(e.parsedBody)?e.parsedBody:[]),l=0,p=Object.keys(a);l<p.length;l++){var d=p[l];a[d].serializedName&&(u[d]=e.parsedBody[d])}if(r)for(var h=0,f=Object.keys(r);h<f.length;h++)u[d=f[h]]=r[d];return i(u),u}if("Composite"===s||"Dictionary"===s)return i(B(B({},r),e.parsedBody))}return o||"HEAD"===e.request.method||"object"!=typeof(n=e.parsedBody)&&"function"!=typeof n||null===n?i(B(B({},r),{body:e.parsedBody})):i(B(B({},r),e.parsedBody))}function Tt(e){return void 0===e&&(e=console.log),{create:function(t,n){return new St(t,n,e)}}}var St=function(e){function t(t,n,r){void 0===r&&(r=console.log);var o=e.call(this,t,n)||this;return o.logger=r,o}return q(t,e),t.prototype.sendRequest=function(e){var t=this;return this._nextPolicy.sendRequest(e).then((function(e){return function(e,t){e.logger(">> Request: "+JSON.stringify(t.request,void 0,2)),e.logger(">> Response status code: "+t.status);var n=t.bodyAsText;return e.logger(">> Body: "+n),Promise.resolve(t)}(t,e)}))},t}(Se),Ct=Me.HeaderConstants,xt="Bearer",wt=function(){function e(e,t){if(void 0===t&&(t=xt),this.authorizationScheme=xt,!e)throw new Error("token cannot be null or undefined.");this.token=e,this.authorizationScheme=t}return e.prototype.signRequest=function(e){return e.headers||(e.headers=new i),e.headers.set(Ct.AUTHORIZATION,this.authorizationScheme+" "+this.token),Promise.resolve(e)},e}(),At=Me.HeaderConstants,It="Basic",Rt=function(){function e(e,t,n){if(void 0===n&&(n=It),this.authorizationScheme=It,null==e||"string"!=typeof e.valueOf())throw new Error("userName cannot be null or undefined and must be of type string.");if(null==t||"string"!=typeof t.valueOf())throw new Error("password cannot be null or undefined and must be of type string.");this.userName=e,this.password=t,this.authorizationScheme=n}return e.prototype.signRequest=function(e){var t,n=this.userName+":"+this.password,r=this.authorizationScheme+" "+(t=n,Buffer.from(t).toString("base64"));return e.headers||(e.headers=new i),e.headers.set(At.AUTHORIZATION,r),Promise.resolve(e)},e}(),Pt=function(){function e(e){if(!e||e&&!e.inHeader&&!e.inQuery)throw new Error('options cannot be null or undefined. Either "inHeader" or "inQuery" property of the options object needs to be provided.');this.inHeader=e.inHeader,this.inQuery=e.inQuery}return e.prototype.signRequest=function(e){if(!e)return Promise.reject(new Error('webResource cannot be null or undefined and must be of type "object".'));if(this.inHeader)for(var t in e.headers||(e.headers=new i),this.inHeader)e.headers.set(t,this.inHeader[t]);if(this.inQuery){if(!e.url)return Promise.reject(new Error("url cannot be null in the request object."));for(var n in e.url.indexOf("?")<0&&(e.url+="?"),this.inQuery)e.url.endsWith("?")||(e.url+="&"),e.url+=n+"="+this.inQuery[n]}return Promise.resolve(e)},e}(),Ot=function(e){function t(t){if(!t||t&&"string"!=typeof t)throw new Error("topicKey cannot be null or undefined and must be of type string.");var n={inHeader:{"aeg-sas-key":t}};return e.call(this,n)||this}return q(t,e),t}(Pt),Nt=function(e){function t(t){if(!t||t&&"string"!=typeof t)throw new Error("domainKey cannot be null or undefined and must be of type string.");var n={inHeader:{"aeg-sas-key":t}};return e.call(this,n)||this}return q(t,e),t}(Pt)},1706:(e,t,n)=>{var r=n(801),o=n(9023),i=n(6928),s=n(8611),a=n(5692),c=n(7016).parse,u=n(9896),l=n(6049),p=n(1873),d=n(8399);function h(e){if(!(this instanceof h))return new h;for(var t in this._overheadLength=0,this._valueLength=0,this._valuesToMeasure=[],r.call(this),e=e||{})this[t]=e[t]}e.exports=h,o.inherits(h,r),h.LINE_BREAK="\r\n",h.DEFAULT_CONTENT_TYPE="application/octet-stream",h.prototype.append=function(e,t,n){"string"==typeof(n=n||{})&&(n={filename:n});var i=r.prototype.append.bind(this);if("number"==typeof t&&(t=""+t),o.isArray(t))this._error(new Error("Arrays are not supported."));else{var s=this._multiPartHeader(e,t,n),a=this._multiPartFooter();i(s),i(t),i(a),this._trackLength(s,t,n)}},h.prototype._trackLength=function(e,t,n){var r=0;null!=n.knownLength?r+=+n.knownLength:Buffer.isBuffer(t)?r=t.length:"string"==typeof t&&(r=Buffer.byteLength(t)),this._valueLength+=r,this._overheadLength+=Buffer.byteLength(e)+h.LINE_BREAK.length,t&&(t.path||t.readable&&t.hasOwnProperty("httpVersion"))&&(n.knownLength||this._valuesToMeasure.push(t))},h.prototype._lengthRetriever=function(e,t){e.hasOwnProperty("fd")?null!=e.end&&e.end!=1/0&&null!=e.start?t(null,e.end+1-(e.start?e.start:0)):u.stat(e.path,(function(n,r){var o;n?t(n):(o=r.size-(e.start?e.start:0),t(null,o))})):e.hasOwnProperty("httpVersion")?t(null,+e.headers["content-length"]):e.hasOwnProperty("httpModule")?(e.on("response",(function(n){e.pause(),t(null,+n.headers["content-length"])})),e.resume()):t("Unknown stream")},h.prototype._multiPartHeader=function(e,t,n){if("string"==typeof n.header)return n.header;var r,o=this._getContentDisposition(t,n),i=this._getContentType(t,n),s="",a={"Content-Disposition":["form-data",'name="'+e+'"'].concat(o||[]),"Content-Type":[].concat(i||[])};for(var c in"object"==typeof n.header&&d(a,n.header),a)a.hasOwnProperty(c)&&null!=(r=a[c])&&(Array.isArray(r)||(r=[r]),r.length&&(s+=c+": "+r.join("; ")+h.LINE_BREAK));return"--"+this.getBoundary()+h.LINE_BREAK+s+h.LINE_BREAK},h.prototype._getContentDisposition=function(e,t){var n,r;return"string"==typeof t.filepath?n=i.normalize(t.filepath).replace(/\\/g,"/"):t.filename||e.name||e.path?n=i.basename(t.filename||e.name||e.path):e.readable&&e.hasOwnProperty("httpVersion")&&(n=i.basename(e.client._httpMessage.path||"")),n&&(r='filename="'+n+'"'),r},h.prototype._getContentType=function(e,t){var n=t.contentType;return!n&&e.name&&(n=l.lookup(e.name)),!n&&e.path&&(n=l.lookup(e.path)),!n&&e.readable&&e.hasOwnProperty("httpVersion")&&(n=e.headers["content-type"]),n||!t.filepath&&!t.filename||(n=l.lookup(t.filepath||t.filename)),n||"object"!=typeof e||(n=h.DEFAULT_CONTENT_TYPE),n},h.prototype._multiPartFooter=function(){return function(e){var t=h.LINE_BREAK;0===this._streams.length&&(t+=this._lastBoundary()),e(t)}.bind(this)},h.prototype._lastBoundary=function(){return"--"+this.getBoundary()+"--"+h.LINE_BREAK},h.prototype.getHeaders=function(e){var t,n={"content-type":"multipart/form-data; boundary="+this.getBoundary()};for(t in e)e.hasOwnProperty(t)&&(n[t.toLowerCase()]=e[t]);return n},h.prototype.getBoundary=function(){return this._boundary||this._generateBoundary(),this._boundary},h.prototype.getBuffer=function(){for(var e=new Buffer.alloc(0),t=this.getBoundary(),n=0,r=this._streams.length;n<r;n++)"function"!=typeof this._streams[n]&&(e=Buffer.isBuffer(this._streams[n])?Buffer.concat([e,this._streams[n]]):Buffer.concat([e,Buffer.from(this._streams[n])]),"string"==typeof this._streams[n]&&this._streams[n].substring(2,t.length+2)===t||(e=Buffer.concat([e,Buffer.from(h.LINE_BREAK)])));return Buffer.concat([e,Buffer.from(this._lastBoundary())])},h.prototype._generateBoundary=function(){for(var e="--------------------------",t=0;t<24;t++)e+=Math.floor(10*Math.random()).toString(16);this._boundary=e},h.prototype.getLengthSync=function(){var e=this._overheadLength+this._valueLength;return this._streams.length&&(e+=this._lastBoundary().length),this.hasKnownLength()||this._error(new Error("Cannot calculate proper length in synchronous way.")),e},h.prototype.hasKnownLength=function(){var e=!0;return this._valuesToMeasure.length&&(e=!1),e},h.prototype.getLength=function(e){var t=this._overheadLength+this._valueLength;this._streams.length&&(t+=this._lastBoundary().length),this._valuesToMeasure.length?p.parallel(this._valuesToMeasure,this._lengthRetriever,(function(n,r){n?e(n):(r.forEach((function(e){t+=e})),e(null,t))})):process.nextTick(e.bind(this,null,t))},h.prototype.submit=function(e,t){var n,r,o={method:"post"};return"string"==typeof e?(e=c(e),r=d({port:e.port,path:e.pathname,host:e.hostname,protocol:e.protocol},o)):(r=d(e,o)).port||(r.port="https:"==r.protocol?443:80),r.headers=this.getHeaders(e.headers),n="https:"==r.protocol?a.request(r):s.request(r),this.getLength(function(e,r){e?this._error(e):(n.setHeader("Content-Length",r),this.pipe(n),t&&(n.on("error",t),n.on("response",t.bind(this,null))))}.bind(this)),n},h.prototype._error=function(e){this.error||(this.error=e,this.pause(),this.emit("error",e))},h.prototype.toString=function(){return"[object FormData]"}},8399:e=>{e.exports=function(e,t){return Object.keys(t).forEach((function(n){e[n]=e[n]||t[n]})),e}},3397:(e,t,n)=>{"use strict";n.r(t),n.d(t,{AADServerParamKeys:()=>d,AccessTokenEntity:()=>Ae,AccountEntity:()=>se,AppMetadataEntity:()=>Fe,AuthError:()=>G,AuthErrorMessage:()=>H,AuthToken:()=>ae,AuthenticationHeaderParser:()=>dt,AuthenticationScheme:()=>O,Authority:()=>tt,AuthorityFactory:()=>nt,AuthorityMetadataEntity:()=>Ze,AuthorityType:()=>Z,AuthorizationCodeClient:()=>Be,AzureCloudInstance:()=>Q,CacheAccountType:()=>E,CacheManager:()=>ce,CacheRecord:()=>ke,CacheSchemaType:()=>C,CacheType:()=>x,CcsCredentialType:()=>ie,ClaimsRequestKeys:()=>h,ClientAuthError:()=>K,ClientAuthErrorMessage:()=>$,ClientConfigurationError:()=>te,ClientConfigurationErrorMessage:()=>ee,ClientCredentialClient:()=>Ve,CodeChallengeMethodValues:()=>w,Constants:()=>f,CredentialEntity:()=>J,CredentialType:()=>S,DEFAULT_CRYPTO_IMPLEMENTATION:()=>V,DEFAULT_SYSTEM_OPTIONS:()=>le,DefaultStorageClass:()=>ue,DeviceCodeClient:()=>He,Errors:()=>z,HeaderNames:()=>u,IdToken:()=>ae,IdTokenEntity:()=>xe,IntFields:()=>je,InteractionRequiredAuthError:()=>Ne,InteractionRequiredAuthErrorMessage:()=>Oe,JoseHeader:()=>pt,LogLevel:()=>q,Logger:()=>Y,NetworkManager:()=>_e,OIDC_DEFAULT_SCOPES:()=>m,ONE_DAY_IN_MS:()=>B,OnBehalfOfClient:()=>$e,PasswordGrantConstants:()=>k,PerformanceClient:()=>ft,PerformanceEventStatus:()=>Ee,PerformanceEvents:()=>be,PersistentCacheKeys:()=>l,PopTokenGenerator:()=>Ue,PromptValue:()=>y,ProtocolMode:()=>Ye,ProtocolUtils:()=>De,RefreshTokenClient:()=>Ge,RefreshTokenEntity:()=>Ie,ResponseMode:()=>_,SSOTypes:()=>g,ScopeSet:()=>ne,ServerError:()=>ge,ServerTelemetryEntity:()=>rt,ServerTelemetryManager:()=>ht,SilentFlowClient:()=>Ke,StringUtils:()=>W,StubPerformanceClient:()=>vt,StubbedNetworkModule:()=>it,THE_FAMILY_ID:()=>R,ThrottlingConstants:()=>F,ThrottlingEntity:()=>ot,ThrottlingUtils:()=>ye,TimeUtils:()=>we,TokenCacheContext:()=>ze,UrlString:()=>Me,UsernamePasswordClient:()=>We,buildClientInfo:()=>re,buildClientInfoFromHomeAccountId:()=>oe,version:()=>X});var r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},r(e,t)};function o(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var i=function(){return i=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},i.apply(this,arguments)};function s(e,t,n,r){return new(n||(n=Promise))((function(o,i){function s(e){try{c(r.next(e))}catch(e){i(e)}}function a(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(s,a)}c((r=r.apply(e,t||[])).next())}))}function a(e,t){var n,r,o,i,s={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function a(i){return function(a){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return s.label++,{value:i[1],done:!1};case 5:s.label++,r=i[1],i=[0];continue;case 7:i=s.ops.pop(),s.trys.pop();continue;default:if(!((o=(o=s.trys).length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){s=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){s.label=i[1];break}if(6===i[0]&&s.label<o[1]){s.label=o[1],o=i;break}if(o&&s.label<o[2]){s.label=o[2],s.ops.push(i);break}o[2]&&s.ops.pop(),s.trys.pop();continue}i=t.call(e,s)}catch(e){i=[6,e],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,a])}}}function c(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;var r=Array(e),o=0;for(t=0;t<n;t++)for(var i=arguments[t],s=0,a=i.length;s<a;s++,o++)r[o]=i[s];return r}var u,l,p,d,h,f={LIBRARY_NAME:"MSAL.JS",SKU:"msal.js.common",CACHE_PREFIX:"msal",DEFAULT_AUTHORITY:"https://login.microsoftonline.com/common/",DEFAULT_AUTHORITY_HOST:"login.microsoftonline.com",DEFAULT_COMMON_TENANT:"common",ADFS:"adfs",DSTS:"dstsv2",AAD_INSTANCE_DISCOVERY_ENDPT:"https://login.microsoftonline.com/common/discovery/instance?api-version=1.1&authorization_endpoint=",RESOURCE_DELIM:"|",NO_ACCOUNT:"NO_ACCOUNT",CLAIMS:"claims",CONSUMER_UTID:"9188040d-6c67-4c5b-b112-36a304b66dad",OPENID_SCOPE:"openid",PROFILE_SCOPE:"profile",OFFLINE_ACCESS_SCOPE:"offline_access",EMAIL_SCOPE:"email",CODE_RESPONSE_TYPE:"code",CODE_GRANT_TYPE:"authorization_code",RT_GRANT_TYPE:"refresh_token",FRAGMENT_RESPONSE_MODE:"fragment",S256_CODE_CHALLENGE_METHOD:"S256",URL_FORM_CONTENT_TYPE:"application/x-www-form-urlencoded;charset=utf-8",AUTHORIZATION_PENDING:"authorization_pending",NOT_DEFINED:"not_defined",EMPTY_STRING:"",NOT_APPLICABLE:"N/A",FORWARD_SLASH:"/",IMDS_ENDPOINT:"http://169.254.169.254/metadata/instance/compute/location",IMDS_VERSION:"2020-06-01",IMDS_TIMEOUT:2e3,AZURE_REGION_AUTO_DISCOVER_FLAG:"TryAutoDetect",REGIONAL_AUTH_PUBLIC_CLOUD_SUFFIX:"login.microsoft.com",REGIONAL_AUTH_NON_MSI_QUERY_STRING:"allowestsrnonmsi=true",KNOWN_PUBLIC_CLOUDS:["login.microsoftonline.com","login.windows.net","login.microsoft.com","sts.windows.net"],TOKEN_RESPONSE_TYPE:"token",ID_TOKEN_RESPONSE_TYPE:"id_token",SHR_NONCE_VALIDITY:240,INVALID_INSTANCE:"invalid_instance"},m=[f.OPENID_SCOPE,f.PROFILE_SCOPE,f.OFFLINE_ACCESS_SCOPE],v=c(m,[f.EMAIL_SCOPE]);!function(e){e.CONTENT_TYPE="Content-Type",e.RETRY_AFTER="Retry-After",e.CCS_HEADER="X-AnchorMailbox",e.WWWAuthenticate="WWW-Authenticate",e.AuthenticationInfo="Authentication-Info",e.X_MS_REQUEST_ID="x-ms-request-id",e.X_MS_HTTP_VERSION="x-ms-httpver"}(u||(u={})),function(e){e.ID_TOKEN="idtoken",e.CLIENT_INFO="client.info",e.ADAL_ID_TOKEN="adal.idtoken",e.ERROR="error",e.ERROR_DESC="error.description",e.ACTIVE_ACCOUNT="active-account",e.ACTIVE_ACCOUNT_FILTERS="active-account-filters"}(l||(l={})),function(e){e.COMMON="common",e.ORGANIZATIONS="organizations",e.CONSUMERS="consumers"}(p||(p={})),function(e){e.CLIENT_ID="client_id",e.REDIRECT_URI="redirect_uri",e.RESPONSE_TYPE="response_type",e.RESPONSE_MODE="response_mode",e.GRANT_TYPE="grant_type",e.CLAIMS="claims",e.SCOPE="scope",e.ERROR="error",e.ERROR_DESCRIPTION="error_description",e.ACCESS_TOKEN="access_token",e.ID_TOKEN="id_token",e.REFRESH_TOKEN="refresh_token",e.EXPIRES_IN="expires_in",e.STATE="state",e.NONCE="nonce",e.PROMPT="prompt",e.SESSION_STATE="session_state",e.CLIENT_INFO="client_info",e.CODE="code",e.CODE_CHALLENGE="code_challenge",e.CODE_CHALLENGE_METHOD="code_challenge_method",e.CODE_VERIFIER="code_verifier",e.CLIENT_REQUEST_ID="client-request-id",e.X_CLIENT_SKU="x-client-SKU",e.X_CLIENT_VER="x-client-VER",e.X_CLIENT_OS="x-client-OS",e.X_CLIENT_CPU="x-client-CPU",e.X_CLIENT_CURR_TELEM="x-client-current-telemetry",e.X_CLIENT_LAST_TELEM="x-client-last-telemetry",e.X_MS_LIB_CAPABILITY="x-ms-lib-capability",e.X_APP_NAME="x-app-name",e.X_APP_VER="x-app-ver",e.POST_LOGOUT_URI="post_logout_redirect_uri",e.ID_TOKEN_HINT="id_token_hint",e.DEVICE_CODE="device_code",e.CLIENT_SECRET="client_secret",e.CLIENT_ASSERTION="client_assertion",e.CLIENT_ASSERTION_TYPE="client_assertion_type",e.TOKEN_TYPE="token_type",e.REQ_CNF="req_cnf",e.OBO_ASSERTION="assertion",e.REQUESTED_TOKEN_USE="requested_token_use",e.ON_BEHALF_OF="on_behalf_of",e.FOCI="foci",e.CCS_HEADER="X-AnchorMailbox",e.RETURN_SPA_CODE="return_spa_code",e.NATIVE_BROKER="nativebroker",e.LOGOUT_HINT="logout_hint"}(d||(d={})),function(e){e.ACCESS_TOKEN="access_token",e.XMS_CC="xms_cc"}(h||(h={}));var g,y={LOGIN:"login",SELECT_ACCOUNT:"select_account",CONSENT:"consent",NONE:"none",CREATE:"create",NO_SESSION:"no_session"};!function(e){e.ACCOUNT="account",e.SID="sid",e.LOGIN_HINT="login_hint",e.ID_TOKEN="id_token",e.DOMAIN_HINT="domain_hint",e.ORGANIZATIONS="organizations",e.CONSUMERS="consumers",e.ACCOUNT_ID="accountIdentifier",e.HOMEACCOUNT_ID="homeAccountIdentifier"}(g||(g={}));var _,b,E,T,S,C,x,w={PLAIN:"plain",S256:"S256"};!function(e){e.QUERY="query",e.FRAGMENT="fragment",e.FORM_POST="form_post"}(_||(_={})),function(e){e.IMPLICIT_GRANT="implicit",e.AUTHORIZATION_CODE_GRANT="authorization_code",e.CLIENT_CREDENTIALS_GRANT="client_credentials",e.RESOURCE_OWNER_PASSWORD_GRANT="password",e.REFRESH_TOKEN_GRANT="refresh_token",e.DEVICE_CODE_GRANT="device_code",e.JWT_BEARER="urn:ietf:params:oauth:grant-type:jwt-bearer"}(b||(b={})),function(e){e.MSSTS_ACCOUNT_TYPE="MSSTS",e.ADFS_ACCOUNT_TYPE="ADFS",e.MSAV1_ACCOUNT_TYPE="MSA",e.GENERIC_ACCOUNT_TYPE="Generic"}(E||(E={})),function(e){e.CACHE_KEY_SEPARATOR="-",e.CLIENT_INFO_SEPARATOR="."}(T||(T={})),function(e){e.ID_TOKEN="IdToken",e.ACCESS_TOKEN="AccessToken",e.ACCESS_TOKEN_WITH_AUTH_SCHEME="AccessToken_With_AuthScheme",e.REFRESH_TOKEN="RefreshToken"}(S||(S={})),function(e){e.ACCOUNT="Account",e.CREDENTIAL="Credential",e.ID_TOKEN="IdToken",e.ACCESS_TOKEN="AccessToken",e.REFRESH_TOKEN="RefreshToken",e.APP_METADATA="AppMetadata",e.TEMPORARY="TempCache",e.TELEMETRY="Telemetry",e.UNDEFINED="Undefined",e.THROTTLING="Throttling"}(C||(C={})),function(e){e[e.ADFS=1001]="ADFS",e[e.MSA=1002]="MSA",e[e.MSSTS=1003]="MSSTS",e[e.GENERIC=1004]="GENERIC",e[e.ACCESS_TOKEN=2001]="ACCESS_TOKEN",e[e.REFRESH_TOKEN=2002]="REFRESH_TOKEN",e[e.ID_TOKEN=2003]="ID_TOKEN",e[e.APP_METADATA=3001]="APP_METADATA",e[e.UNDEFINED=9999]="UNDEFINED"}(x||(x={}));var A,I="appmetadata",R="1",P="authority-metadata";!function(e){e.CONFIG="config",e.CACHE="cache",e.NETWORK="network",e.HARDCODED_VALUES="hardcoded_values"}(A||(A={}));var O,N={SCHEMA_VERSION:5,MAX_CUR_HEADER_BYTES:80,MAX_LAST_HEADER_BYTES:330,MAX_CACHED_ERRORS:50,CACHE_KEY:"server-telemetry",CATEGORY_SEPARATOR:"|",VALUE_SEPARATOR:",",OVERFLOW_TRUE:"1",OVERFLOW_FALSE:"0",UNKNOWN_ERROR:"unknown_error"};!function(e){e.BEARER="Bearer",e.POP="pop",e.SSH="ssh-cert"}(O||(O={}));var k,D,M,L,j,U,F={DEFAULT_THROTTLE_TIME_SECONDS:60,DEFAULT_MAX_THROTTLE_TIME_SECONDS:3600,THROTTLING_PREFIX:"throttling",X_MS_LIB_CAPABILITY_VALUE:"retry-after, h429"},z={INVALID_GRANT_ERROR:"invalid_grant",CLIENT_MISMATCH_ERROR:"client_mismatch"};!function(e){e.username="username",e.password="password"}(k||(k={})),function(e){e[e.httpSuccess=200]="httpSuccess",e[e.httpBadRequest=400]="httpBadRequest"}(D||(D={})),function(e){e.FAILED_AUTO_DETECTION="1",e.INTERNAL_CACHE="2",e.ENVIRONMENT_VARIABLE="3",e.IMDS="4"}(M||(M={})),function(e){e.CONFIGURED_MATCHES_DETECTED="1",e.CONFIGURED_NO_AUTO_DETECTION="2",e.CONFIGURED_NOT_DETECTED="3",e.AUTO_DETECTION_REQUESTED_SUCCESSFUL="4",e.AUTO_DETECTION_REQUESTED_FAILED="5"}(L||(L={})),function(e){e.NO_CACHE_HIT="0",e.FORCE_REFRESH="1",e.NO_CACHED_ACCESS_TOKEN="2",e.CACHED_ACCESS_TOKEN_EXPIRED="3",e.REFRESH_CACHED_ACCESS_TOKEN="4"}(j||(j={})),function(e){e.Jwt="JWT",e.Jwk="JWK",e.Pop="pop"}(U||(U={}));var q,B=864e5,H={unexpectedError:{code:"unexpected_error",desc:"Unexpected error in authentication."},postRequestFailed:{code:"post_request_failed",desc:"Post request failed from the network, could be a 4xx/5xx or a network unavailability. Please check the exact error code for details."}},G=function(e){function t(n,r,o){var i=this,s=r?n+": "+r:n;return i=e.call(this,s)||this,Object.setPrototypeOf(i,t.prototype),i.errorCode=n||f.EMPTY_STRING,i.errorMessage=r||f.EMPTY_STRING,i.subError=o||f.EMPTY_STRING,i.name="AuthError",i}return o(t,e),t.prototype.setCorrelationId=function(e){this.correlationId=e},t.createUnexpectedError=function(e){return new t(H.unexpectedError.code,H.unexpectedError.desc+": "+e)},t.createPostRequestFailed=function(e){return new t(H.postRequestFailed.code,H.postRequestFailed.desc+": "+e)},t}(Error),V={createNewGuid:function(){throw G.createUnexpectedError("Crypto interface - createNewGuid() has not been implemented")},base64Decode:function(){throw G.createUnexpectedError("Crypto interface - base64Decode() has not been implemented")},base64Encode:function(){throw G.createUnexpectedError("Crypto interface - base64Encode() has not been implemented")},generatePkceCodes:function(){return s(this,void 0,void 0,(function(){return a(this,(function(e){throw G.createUnexpectedError("Crypto interface - generatePkceCodes() has not been implemented")}))}))},getPublicKeyThumbprint:function(){return s(this,void 0,void 0,(function(){return a(this,(function(e){throw G.createUnexpectedError("Crypto interface - getPublicKeyThumbprint() has not been implemented")}))}))},removeTokenBindingKey:function(){return s(this,void 0,void 0,(function(){return a(this,(function(e){throw G.createUnexpectedError("Crypto interface - removeTokenBindingKey() has not been implemented")}))}))},clearKeystore:function(){return s(this,void 0,void 0,(function(){return a(this,(function(e){throw G.createUnexpectedError("Crypto interface - clearKeystore() has not been implemented")}))}))},signJwt:function(){return s(this,void 0,void 0,(function(){return a(this,(function(e){throw G.createUnexpectedError("Crypto interface - signJwt() has not been implemented")}))}))},hashString:function(){return s(this,void 0,void 0,(function(){return a(this,(function(e){throw G.createUnexpectedError("Crypto interface - hashString() has not been implemented")}))}))}},$={clientInfoDecodingError:{code:"client_info_decoding_error",desc:"The client info could not be parsed/decoded correctly. Please review the trace to determine the root cause."},clientInfoEmptyError:{code:"client_info_empty_error",desc:"The client info was empty. Please review the trace to determine the root cause."},tokenParsingError:{code:"token_parsing_error",desc:"Token cannot be parsed. Please review stack trace to determine root cause."},nullOrEmptyToken:{code:"null_or_empty_token",desc:"The token is null or empty. Please review the trace to determine the root cause."},endpointResolutionError:{code:"endpoints_resolution_error",desc:"Error: could not resolve endpoints. Please check network and try again."},networkError:{code:"network_error",desc:"Network request failed. Please check network trace to determine root cause."},unableToGetOpenidConfigError:{code:"openid_config_error",desc:"Could not retrieve endpoints. Check your authority and verify the .well-known/openid-configuration endpoint returns the required endpoints."},hashNotDeserialized:{code:"hash_not_deserialized",desc:"The hash parameters could not be deserialized. Please review the trace to determine the root cause."},blankGuidGenerated:{code:"blank_guid_generated",desc:"The guid generated was blank. Please review the trace to determine the root cause."},invalidStateError:{code:"invalid_state",desc:"State was not the expected format. Please check the logs to determine whether the request was sent using ProtocolUtils.setRequestState()."},stateMismatchError:{code:"state_mismatch",desc:"State mismatch error. Please check your network. Continued requests may cause cache overflow."},stateNotFoundError:{code:"state_not_found",desc:"State not found"},nonceMismatchError:{code:"nonce_mismatch",desc:"Nonce mismatch error. This may be caused by a race condition in concurrent requests."},nonceNotFoundError:{code:"nonce_not_found",desc:"nonce not found"},authTimeNotFoundError:{code:"auth_time_not_found",desc:"Max Age was requested and the ID token is missing the auth_time variable. auth_time is an optional claim and is not enabled by default - it must be enabled. See https://aka.ms/msaljs/optional-claims for more information."},maxAgeTranspiredError:{code:"max_age_transpired",desc:"Max Age is set to 0, or too much time has elapsed since the last end-user authentication."},noTokensFoundError:{code:"no_tokens_found",desc:"No tokens were found for the given scopes, and no authorization code was passed to acquireToken. You must retrieve an authorization code before making a call to acquireToken()."},multipleMatchingTokens:{code:"multiple_matching_tokens",desc:"The cache contains multiple tokens satisfying the requirements. Call AcquireToken again providing more requirements such as authority or account."},multipleMatchingAccounts:{code:"multiple_matching_accounts",desc:"The cache contains multiple accounts satisfying the given parameters. Please pass more info to obtain the correct account"},multipleMatchingAppMetadata:{code:"multiple_matching_appMetadata",desc:"The cache contains multiple appMetadata satisfying the given parameters. Please pass more info to obtain the correct appMetadata"},tokenRequestCannotBeMade:{code:"request_cannot_be_made",desc:"Token request cannot be made without authorization code or refresh token."},appendEmptyScopeError:{code:"cannot_append_empty_scope",desc:"Cannot append null or empty scope to ScopeSet. Please check the stack trace for more info."},removeEmptyScopeError:{code:"cannot_remove_empty_scope",desc:"Cannot remove null or empty scope from ScopeSet. Please check the stack trace for more info."},appendScopeSetError:{code:"cannot_append_scopeset",desc:"Cannot append ScopeSet due to error."},emptyInputScopeSetError:{code:"empty_input_scopeset",desc:"Empty input ScopeSet cannot be processed."},DeviceCodePollingCancelled:{code:"device_code_polling_cancelled",desc:"Caller has cancelled token endpoint polling during device code flow by setting DeviceCodeRequest.cancel = true."},DeviceCodeExpired:{code:"device_code_expired",desc:"Device code is expired."},DeviceCodeUnknownError:{code:"device_code_unknown_error",desc:"Device code stopped polling for unknown reasons."},NoAccountInSilentRequest:{code:"no_account_in_silent_request",desc:"Please pass an account object, silent flow is not supported without account information"},invalidCacheRecord:{code:"invalid_cache_record",desc:"Cache record object was null or undefined."},invalidCacheEnvironment:{code:"invalid_cache_environment",desc:"Invalid environment when attempting to create cache entry"},noAccountFound:{code:"no_account_found",desc:"No account found in cache for given key."},CachePluginError:{code:"no cache plugin set on CacheManager",desc:"ICachePlugin needs to be set before using readFromStorage or writeFromStorage"},noCryptoObj:{code:"no_crypto_object",desc:"No crypto object detected. This is required for the following operation: "},invalidCacheType:{code:"invalid_cache_type",desc:"Invalid cache type"},unexpectedAccountType:{code:"unexpected_account_type",desc:"Unexpected account type."},unexpectedCredentialType:{code:"unexpected_credential_type",desc:"Unexpected credential type."},invalidAssertion:{code:"invalid_assertion",desc:"Client assertion must meet requirements described in https://tools.ietf.org/html/rfc7515"},invalidClientCredential:{code:"invalid_client_credential",desc:"Client credential (secret, certificate, or assertion) must not be empty when creating a confidential client. An application should at most have one credential"},tokenRefreshRequired:{code:"token_refresh_required",desc:"Cannot return token from cache because it must be refreshed. This may be due to one of the following reasons: forceRefresh parameter is set to true, claims have been requested, there is no cached access token or it is expired."},userTimeoutReached:{code:"user_timeout_reached",desc:"User defined timeout for device code polling reached"},tokenClaimsRequired:{code:"token_claims_cnf_required_for_signedjwt",desc:"Cannot generate a POP jwt if the token_claims are not populated"},noAuthorizationCodeFromServer:{code:"authorization_code_missing_from_server_response",desc:"Server response does not contain an authorization code to proceed"},noAzureRegionDetected:{code:"no_azure_region_detected",desc:"No azure region was detected and no fallback was made available"},accessTokenEntityNullError:{code:"access_token_entity_null",desc:"Access token entity is null, please check logs and cache to ensure a valid access token is present."},bindingKeyNotRemovedError:{code:"binding_key_not_removed",desc:"Could not remove the credential's binding key from storage."},logoutNotSupported:{code:"end_session_endpoint_not_supported",desc:"Provided authority does not support logout."},keyIdMissing:{code:"key_id_missing",desc:"A keyId value is missing from the requested bound token's cache record and is required to match the token to it's stored binding key."},noNetworkConnectivity:{code:"no_network_connectivity",desc:"No network connectivity. Check your internet connection."},userCanceledError:{code:"user_canceled",desc:"User canceled the flow."}},K=function(e){function t(n,r){var o=e.call(this,n,r)||this;return o.name="ClientAuthError",Object.setPrototypeOf(o,t.prototype),o}return o(t,e),t.createClientInfoDecodingError=function(e){return new t($.clientInfoDecodingError.code,$.clientInfoDecodingError.desc+" Failed with error: "+e)},t.createClientInfoEmptyError=function(){return new t($.clientInfoEmptyError.code,""+$.clientInfoEmptyError.desc)},t.createTokenParsingError=function(e){return new t($.tokenParsingError.code,$.tokenParsingError.desc+" Failed with error: "+e)},t.createTokenNullOrEmptyError=function(e){return new t($.nullOrEmptyToken.code,$.nullOrEmptyToken.desc+" Raw Token Value: "+e)},t.createEndpointDiscoveryIncompleteError=function(e){return new t($.endpointResolutionError.code,$.endpointResolutionError.desc+" Detail: "+e)},t.createNetworkError=function(e,n){return new t($.networkError.code,$.networkError.desc+" | Fetch client threw: "+n+" | Attempted to reach: "+e.split("?")[0])},t.createUnableToGetOpenidConfigError=function(e){return new t($.unableToGetOpenidConfigError.code,$.unableToGetOpenidConfigError.desc+" Attempted to retrieve endpoints from: "+e)},t.createHashNotDeserializedError=function(e){return new t($.hashNotDeserialized.code,$.hashNotDeserialized.desc+" Given Object: "+e)},t.createInvalidStateError=function(e,n){return new t($.invalidStateError.code,$.invalidStateError.desc+" Invalid State: "+e+", Root Err: "+n)},t.createStateMismatchError=function(){return new t($.stateMismatchError.code,$.stateMismatchError.desc)},t.createStateNotFoundError=function(e){return new t($.stateNotFoundError.code,$.stateNotFoundError.desc+":  "+e)},t.createNonceMismatchError=function(){return new t($.nonceMismatchError.code,$.nonceMismatchError.desc)},t.createAuthTimeNotFoundError=function(){return new t($.authTimeNotFoundError.code,$.authTimeNotFoundError.desc)},t.createMaxAgeTranspiredError=function(){return new t($.maxAgeTranspiredError.code,$.maxAgeTranspiredError.desc)},t.createNonceNotFoundError=function(e){return new t($.nonceNotFoundError.code,$.nonceNotFoundError.desc+":  "+e)},t.createMultipleMatchingTokensInCacheError=function(){return new t($.multipleMatchingTokens.code,$.multipleMatchingTokens.desc+".")},t.createMultipleMatchingAccountsInCacheError=function(){return new t($.multipleMatchingAccounts.code,$.multipleMatchingAccounts.desc)},t.createMultipleMatchingAppMetadataInCacheError=function(){return new t($.multipleMatchingAppMetadata.code,$.multipleMatchingAppMetadata.desc)},t.createTokenRequestCannotBeMadeError=function(){return new t($.tokenRequestCannotBeMade.code,$.tokenRequestCannotBeMade.desc)},t.createAppendEmptyScopeToSetError=function(e){return new t($.appendEmptyScopeError.code,$.appendEmptyScopeError.desc+" Given Scope: "+e)},t.createRemoveEmptyScopeFromSetError=function(e){return new t($.removeEmptyScopeError.code,$.removeEmptyScopeError.desc+" Given Scope: "+e)},t.createAppendScopeSetError=function(e){return new t($.appendScopeSetError.code,$.appendScopeSetError.desc+" Detail Error: "+e)},t.createEmptyInputScopeSetError=function(){return new t($.emptyInputScopeSetError.code,""+$.emptyInputScopeSetError.desc)},t.createDeviceCodeCancelledError=function(){return new t($.DeviceCodePollingCancelled.code,""+$.DeviceCodePollingCancelled.desc)},t.createDeviceCodeExpiredError=function(){return new t($.DeviceCodeExpired.code,""+$.DeviceCodeExpired.desc)},t.createDeviceCodeUnknownError=function(){return new t($.DeviceCodeUnknownError.code,""+$.DeviceCodeUnknownError.desc)},t.createNoAccountInSilentRequestError=function(){return new t($.NoAccountInSilentRequest.code,""+$.NoAccountInSilentRequest.desc)},t.createNullOrUndefinedCacheRecord=function(){return new t($.invalidCacheRecord.code,$.invalidCacheRecord.desc)},t.createInvalidCacheEnvironmentError=function(){return new t($.invalidCacheEnvironment.code,$.invalidCacheEnvironment.desc)},t.createNoAccountFoundError=function(){return new t($.noAccountFound.code,$.noAccountFound.desc)},t.createCachePluginError=function(){return new t($.CachePluginError.code,""+$.CachePluginError.desc)},t.createNoCryptoObjectError=function(e){return new t($.noCryptoObj.code,""+$.noCryptoObj.desc+e)},t.createInvalidCacheTypeError=function(){return new t($.invalidCacheType.code,""+$.invalidCacheType.desc)},t.createUnexpectedAccountTypeError=function(){return new t($.unexpectedAccountType.code,""+$.unexpectedAccountType.desc)},t.createUnexpectedCredentialTypeError=function(){return new t($.unexpectedCredentialType.code,""+$.unexpectedCredentialType.desc)},t.createInvalidAssertionError=function(){return new t($.invalidAssertion.code,""+$.invalidAssertion.desc)},t.createInvalidCredentialError=function(){return new t($.invalidClientCredential.code,""+$.invalidClientCredential.desc)},t.createRefreshRequiredError=function(){return new t($.tokenRefreshRequired.code,$.tokenRefreshRequired.desc)},t.createUserTimeoutReachedError=function(){return new t($.userTimeoutReached.code,$.userTimeoutReached.desc)},t.createTokenClaimsRequiredError=function(){return new t($.tokenClaimsRequired.code,$.tokenClaimsRequired.desc)},t.createNoAuthCodeInServerResponseError=function(){return new t($.noAuthorizationCodeFromServer.code,$.noAuthorizationCodeFromServer.desc)},t.createBindingKeyNotRemovedError=function(){return new t($.bindingKeyNotRemovedError.code,$.bindingKeyNotRemovedError.desc)},t.createLogoutNotSupportedError=function(){return new t($.logoutNotSupported.code,$.logoutNotSupported.desc)},t.createKeyIdMissingError=function(){return new t($.keyIdMissing.code,$.keyIdMissing.desc)},t.createNoNetworkConnectivityError=function(){return new t($.noNetworkConnectivity.code,$.noNetworkConnectivity.desc)},t.createUserCanceledError=function(){return new t($.userCanceledError.code,$.userCanceledError.desc)},t}(G),W=function(){function e(){}return e.decodeAuthToken=function(t){if(e.isEmpty(t))throw K.createTokenNullOrEmptyError(t);var n=/^([^\.\s]*)\.([^\.\s]+)\.([^\.\s]*)$/.exec(t);if(!n||n.length<4)throw K.createTokenParsingError("Given token is malformed: "+JSON.stringify(t));return{header:n[1],JWSPayload:n[2],JWSSig:n[3]}},e.isEmpty=function(e){return void 0===e||!e||0===e.length},e.isEmptyObj=function(t){if(t&&!e.isEmpty(t))try{var n=JSON.parse(t);return 0===Object.keys(n).length}catch(e){}return!0},e.startsWith=function(e,t){return 0===e.indexOf(t)},e.endsWith=function(e,t){return e.length>=t.length&&e.lastIndexOf(t)===e.length-t.length},e.queryStringToObject=function(e){var t={},n=e.split("&"),r=function(e){return decodeURIComponent(e.replace(/\+/g," "))};return n.forEach((function(e){if(e.trim()){var n=e.split(/=(.+)/g,2),o=n[0],i=n[1];o&&i&&(t[r(o)]=r(i))}})),t},e.trimArrayEntries=function(e){return e.map((function(e){return e.trim()}))},e.removeEmptyStringsFromArray=function(t){return t.filter((function(t){return!e.isEmpty(t)}))},e.jsonParseHelper=function(e){try{return JSON.parse(e)}catch(e){return null}},e.matchPattern=function(e,t){return new RegExp(e.replace(/\\/g,"\\\\").replace(/\*/g,"[^ ]*").replace(/\?/g,"\\?")).test(t)},e}();!function(e){e[e.Error=0]="Error",e[e.Warning=1]="Warning",e[e.Info=2]="Info",e[e.Verbose=3]="Verbose",e[e.Trace=4]="Trace"}(q||(q={}));var Q,Y=function(){function e(t,n,r){this.level=q.Info;var o=t||e.createDefaultLoggerOptions();this.localCallback=o.loggerCallback||function(){},this.piiLoggingEnabled=o.piiLoggingEnabled||!1,this.level="number"==typeof o.logLevel?o.logLevel:q.Info,this.correlationId=o.correlationId||f.EMPTY_STRING,this.packageName=n||f.EMPTY_STRING,this.packageVersion=r||f.EMPTY_STRING}return e.createDefaultLoggerOptions=function(){return{loggerCallback:function(){},piiLoggingEnabled:!1,logLevel:q.Info}},e.prototype.clone=function(t,n,r){return new e({loggerCallback:this.localCallback,piiLoggingEnabled:this.piiLoggingEnabled,logLevel:this.level,correlationId:r||this.correlationId},t,n)},e.prototype.logMessage=function(e,t){if(!(t.logLevel>this.level||!this.piiLoggingEnabled&&t.containsPii)){var n=(new Date).toUTCString(),r=(W.isEmpty(t.correlationId)?W.isEmpty(this.correlationId)?"["+n+"]":"["+n+"] : ["+this.correlationId+"]":"["+n+"] : ["+t.correlationId+"]")+" : "+this.packageName+"@"+this.packageVersion+" : "+q[t.logLevel]+" - "+e;this.executeCallback(t.logLevel,r,t.containsPii||!1)}},e.prototype.executeCallback=function(e,t,n){this.localCallback&&this.localCallback(e,t,n)},e.prototype.error=function(e,t){this.logMessage(e,{logLevel:q.Error,containsPii:!1,correlationId:t||f.EMPTY_STRING})},e.prototype.errorPii=function(e,t){this.logMessage(e,{logLevel:q.Error,containsPii:!0,correlationId:t||f.EMPTY_STRING})},e.prototype.warning=function(e,t){this.logMessage(e,{logLevel:q.Warning,containsPii:!1,correlationId:t||f.EMPTY_STRING})},e.prototype.warningPii=function(e,t){this.logMessage(e,{logLevel:q.Warning,containsPii:!0,correlationId:t||f.EMPTY_STRING})},e.prototype.info=function(e,t){this.logMessage(e,{logLevel:q.Info,containsPii:!1,correlationId:t||f.EMPTY_STRING})},e.prototype.infoPii=function(e,t){this.logMessage(e,{logLevel:q.Info,containsPii:!0,correlationId:t||f.EMPTY_STRING})},e.prototype.verbose=function(e,t){this.logMessage(e,{logLevel:q.Verbose,containsPii:!1,correlationId:t||f.EMPTY_STRING})},e.prototype.verbosePii=function(e,t){this.logMessage(e,{logLevel:q.Verbose,containsPii:!0,correlationId:t||f.EMPTY_STRING})},e.prototype.trace=function(e,t){this.logMessage(e,{logLevel:q.Trace,containsPii:!1,correlationId:t||f.EMPTY_STRING})},e.prototype.tracePii=function(e,t){this.logMessage(e,{logLevel:q.Trace,containsPii:!0,correlationId:t||f.EMPTY_STRING})},e.prototype.isPiiLoggingEnabled=function(){return this.piiLoggingEnabled||!1},e}(),X="11.0.0";!function(e){e[e.None=0]="None",e.AzurePublic="https://login.microsoftonline.com",e.AzurePpe="https://login.windows-ppe.net",e.AzureChina="https://login.chinacloudapi.cn",e.AzureGermany="https://login.microsoftonline.de",e.AzureUsGovernment="https://login.microsoftonline.us"}(Q||(Q={}));var J=function(){function e(){}return e._initRegex=function(){var t=T.CACHE_KEY_SEPARATOR;e.credentialRegexMap=new Map;for(var n=0,r=Object.keys(S);n<r.length;n++){var o=r[n],i=S[o].toLowerCase();try{e.credentialRegexMap.set(S[o],new RegExp("(?<="+t+e.credentialDomainRegex+")"+t+i+t))}catch(n){e.credentialRegexMap.set(S[o],new RegExp(""+t+e.credentialDomainRegex+t+i+t))}}},e.prototype.generateAccountId=function(){return e.generateAccountIdForCacheKey(this.homeAccountId,this.environment)},e.prototype.generateCredentialId=function(){return e.generateCredentialIdForCacheKey(this.credentialType,this.clientId,this.realm,this.familyId)},e.prototype.generateTarget=function(){return e.generateTargetForCacheKey(this.target)},e.prototype.generateCredentialKey=function(){return e.generateCredentialCacheKey(this.homeAccountId,this.environment,this.credentialType,this.clientId,this.realm,this.target,this.familyId,this.tokenType,this.requestedClaimsHash)},e.prototype.generateType=function(){switch(this.credentialType){case S.ID_TOKEN:return x.ID_TOKEN;case S.ACCESS_TOKEN:case S.ACCESS_TOKEN_WITH_AUTH_SCHEME:return x.ACCESS_TOKEN;case S.REFRESH_TOKEN:return x.REFRESH_TOKEN;default:throw K.createUnexpectedCredentialTypeError()}},e.getCredentialType=function(e){for(var t,n=0,r=Object.keys(S);n<r.length;n++){var o=r[n];if(null===(t=this.credentialRegexMap.get(S[o]))||void 0===t?void 0:t.test(e.toLowerCase()))return S[o]}return f.NOT_DEFINED},e.generateCredentialCacheKey=function(e,t,n,r,o,i,s,a,c){return[this.generateAccountIdForCacheKey(e,t),this.generateCredentialIdForCacheKey(n,r,o,s),this.generateTargetForCacheKey(i),this.generateClaimsHashForCacheKey(c),this.generateSchemeForCacheKey(a)].join(T.CACHE_KEY_SEPARATOR).toLowerCase()},e.generateAccountIdForCacheKey=function(e,t){return[e,t].join(T.CACHE_KEY_SEPARATOR).toLowerCase()},e.generateCredentialIdForCacheKey=function(e,t,n,r){return[e,e===S.REFRESH_TOKEN&&r||t,n||f.EMPTY_STRING].join(T.CACHE_KEY_SEPARATOR).toLowerCase()},e.generateTargetForCacheKey=function(e){return(e||f.EMPTY_STRING).toLowerCase()},e.generateClaimsHashForCacheKey=function(e){return(e||f.EMPTY_STRING).toLowerCase()},e.generateSchemeForCacheKey=function(e){return e&&e.toLowerCase()!==O.BEARER.toLowerCase()?e.toLowerCase():f.EMPTY_STRING},e.credentialDomainRegex="(https?:\\/\\/)?((([\\w-]+\\.)*([\\w-]{1,63})(\\.(\\w{2,63})))|(localhost))(\\:[0-9]{4,5})?(\\/[\\w-]+)?",e}();J._initRegex();var Z,ee={redirectUriNotSet:{code:"redirect_uri_empty",desc:"A redirect URI is required for all calls, and none has been set."},postLogoutUriNotSet:{code:"post_logout_uri_empty",desc:"A post logout redirect has not been set."},claimsRequestParsingError:{code:"claims_request_parsing_error",desc:"Could not parse the given claims request object."},authorityUriInsecure:{code:"authority_uri_insecure",desc:"Authority URIs must use https.  Please see here for valid authority configuration options: https://docs.microsoft.com/en-us/azure/active-directory/develop/msal-js-initializing-client-applications#configuration-options"},urlParseError:{code:"url_parse_error",desc:"URL could not be parsed into appropriate segments."},urlEmptyError:{code:"empty_url_error",desc:"URL was empty or null."},emptyScopesError:{code:"empty_input_scopes_error",desc:"Scopes cannot be passed as null, undefined or empty array because they are required to obtain an access token."},nonArrayScopesError:{code:"nonarray_input_scopes_error",desc:"Scopes cannot be passed as non-array."},clientIdSingleScopeError:{code:"clientid_input_scopes_error",desc:"Client ID can only be provided as a single scope."},invalidPrompt:{code:"invalid_prompt_value",desc:"Supported prompt values are 'login', 'select_account', 'consent', 'create', 'none' and 'no_session'.  Please see here for valid configuration options: https://azuread.github.io/microsoft-authentication-library-for-js/ref/modules/_azure_msal_common.html#commonauthorizationurlrequest"},invalidClaimsRequest:{code:"invalid_claims",desc:"Given claims parameter must be a stringified JSON object."},tokenRequestEmptyError:{code:"token_request_empty",desc:"Token request was empty and not found in cache."},logoutRequestEmptyError:{code:"logout_request_empty",desc:"The logout request was null or undefined."},invalidCodeChallengeMethod:{code:"invalid_code_challenge_method",desc:'code_challenge_method passed is invalid. Valid values are "plain" and "S256".'},invalidCodeChallengeParams:{code:"pkce_params_missing",desc:"Both params: code_challenge and code_challenge_method are to be passed if to be sent in the request"},invalidCloudDiscoveryMetadata:{code:"invalid_cloud_discovery_metadata",desc:"Invalid cloudDiscoveryMetadata provided. Must be a stringified JSON object containing tenant_discovery_endpoint and metadata fields"},invalidAuthorityMetadata:{code:"invalid_authority_metadata",desc:"Invalid authorityMetadata provided. Must by a stringified JSON object containing authorization_endpoint, token_endpoint, issuer fields."},untrustedAuthority:{code:"untrusted_authority",desc:"The provided authority is not a trusted authority. Please include this authority in the knownAuthorities config parameter."},invalidAzureCloudInstance:{code:"invalid_azure_cloud_instance",desc:"Invalid AzureCloudInstance provided. Please refer MSAL JS docs: aks.ms/msaljs/azure_cloud_instance for valid values"},missingSshJwk:{code:"missing_ssh_jwk",desc:"Missing sshJwk in SSH certificate request. A stringified JSON Web Key is required when using the SSH authentication scheme."},missingSshKid:{code:"missing_ssh_kid",desc:"Missing sshKid in SSH certificate request. A string that uniquely identifies the public SSH key is required when using the SSH authentication scheme."},missingNonceAuthenticationHeader:{code:"missing_nonce_authentication_header",desc:"Unable to find an authentication header containing server nonce. Either the Authentication-Info or WWW-Authenticate headers must be present in order to obtain a server nonce."},invalidAuthenticationHeader:{code:"invalid_authentication_header",desc:"Invalid authentication header provided"}},te=function(e){function t(n,r){var o=e.call(this,n,r)||this;return o.name="ClientConfigurationError",Object.setPrototypeOf(o,t.prototype),o}return o(t,e),t.createRedirectUriEmptyError=function(){return new t(ee.redirectUriNotSet.code,ee.redirectUriNotSet.desc)},t.createPostLogoutRedirectUriEmptyError=function(){return new t(ee.postLogoutUriNotSet.code,ee.postLogoutUriNotSet.desc)},t.createClaimsRequestParsingError=function(e){return new t(ee.claimsRequestParsingError.code,ee.claimsRequestParsingError.desc+" Given value: "+e)},t.createInsecureAuthorityUriError=function(e){return new t(ee.authorityUriInsecure.code,ee.authorityUriInsecure.desc+" Given URI: "+e)},t.createUrlParseError=function(e){return new t(ee.urlParseError.code,ee.urlParseError.desc+" Given Error: "+e)},t.createUrlEmptyError=function(){return new t(ee.urlEmptyError.code,ee.urlEmptyError.desc)},t.createEmptyScopesArrayError=function(){return new t(ee.emptyScopesError.code,""+ee.emptyScopesError.desc)},t.createClientIdSingleScopeError=function(e){return new t(ee.clientIdSingleScopeError.code,ee.clientIdSingleScopeError.desc+" Given Scopes: "+e)},t.createInvalidPromptError=function(e){return new t(ee.invalidPrompt.code,ee.invalidPrompt.desc+" Given value: "+e)},t.createInvalidClaimsRequestError=function(){return new t(ee.invalidClaimsRequest.code,ee.invalidClaimsRequest.desc)},t.createEmptyLogoutRequestError=function(){return new t(ee.logoutRequestEmptyError.code,ee.logoutRequestEmptyError.desc)},t.createEmptyTokenRequestError=function(){return new t(ee.tokenRequestEmptyError.code,ee.tokenRequestEmptyError.desc)},t.createInvalidCodeChallengeMethodError=function(){return new t(ee.invalidCodeChallengeMethod.code,ee.invalidCodeChallengeMethod.desc)},t.createInvalidCodeChallengeParamsError=function(){return new t(ee.invalidCodeChallengeParams.code,ee.invalidCodeChallengeParams.desc)},t.createInvalidCloudDiscoveryMetadataError=function(){return new t(ee.invalidCloudDiscoveryMetadata.code,ee.invalidCloudDiscoveryMetadata.desc)},t.createInvalidAuthorityMetadataError=function(){return new t(ee.invalidAuthorityMetadata.code,ee.invalidAuthorityMetadata.desc)},t.createUntrustedAuthorityError=function(){return new t(ee.untrustedAuthority.code,ee.untrustedAuthority.desc)},t.createInvalidAzureCloudInstanceError=function(){return new t(ee.invalidAzureCloudInstance.code,ee.invalidAzureCloudInstance.desc)},t.createMissingSshJwkError=function(){return new t(ee.missingSshJwk.code,ee.missingSshJwk.desc)},t.createMissingSshKidError=function(){return new t(ee.missingSshKid.code,ee.missingSshKid.desc)},t.createMissingNonceAuthenticationHeadersError=function(){return new t(ee.missingNonceAuthenticationHeader.code,ee.missingNonceAuthenticationHeader.desc)},t.createInvalidAuthenticationHeaderError=function(e,n){return new t(ee.invalidAuthenticationHeader.code,ee.invalidAuthenticationHeader.desc+". Invalid header: "+e+". Details: "+n)},t}(K),ne=function(){function e(e){var t=this,n=e?W.trimArrayEntries(c(e)):[],r=n?W.removeEmptyStringsFromArray(n):[];this.validateInputScopes(r),this.scopes=new Set,r.forEach((function(e){return t.scopes.add(e)}))}return e.fromString=function(t){return new e((t||f.EMPTY_STRING).split(" "))},e.prototype.validateInputScopes=function(e){if(!e||e.length<1)throw te.createEmptyScopesArrayError()},e.prototype.containsScope=function(t){var n=new e(this.printScopesLowerCase().split(" "));return!W.isEmpty(t)&&n.scopes.has(t.toLowerCase())},e.prototype.containsScopeSet=function(e){var t=this;return!(!e||e.scopes.size<=0)&&this.scopes.size>=e.scopes.size&&e.asArray().every((function(e){return t.containsScope(e)}))},e.prototype.containsOnlyOIDCScopes=function(){var e=this,t=0;return v.forEach((function(n){e.containsScope(n)&&(t+=1)})),this.scopes.size===t},e.prototype.appendScope=function(e){W.isEmpty(e)||this.scopes.add(e.trim())},e.prototype.appendScopes=function(e){var t=this;try{e.forEach((function(e){return t.appendScope(e)}))}catch(e){throw K.createAppendScopeSetError(e)}},e.prototype.removeScope=function(e){if(W.isEmpty(e))throw K.createRemoveEmptyScopeFromSetError(e);this.scopes.delete(e.trim())},e.prototype.removeOIDCScopes=function(){var e=this;v.forEach((function(t){e.scopes.delete(t)}))},e.prototype.unionScopeSets=function(e){if(!e)throw K.createEmptyInputScopeSetError();var t=new Set;return e.scopes.forEach((function(e){return t.add(e.toLowerCase())})),this.scopes.forEach((function(e){return t.add(e.toLowerCase())})),t},e.prototype.intersectingScopeSets=function(e){if(!e)throw K.createEmptyInputScopeSetError();e.containsOnlyOIDCScopes()||e.removeOIDCScopes();var t=this.unionScopeSets(e),n=e.getScopeCount(),r=this.getScopeCount();return t.size<r+n},e.prototype.getScopeCount=function(){return this.scopes.size},e.prototype.asArray=function(){var e=[];return this.scopes.forEach((function(t){return e.push(t)})),e},e.prototype.printScopes=function(){return this.scopes?this.asArray().join(" "):f.EMPTY_STRING},e.prototype.printScopesLowerCase=function(){return this.printScopes().toLowerCase()},e}();function re(e,t){if(W.isEmpty(e))throw K.createClientInfoEmptyError();try{var n=t.base64Decode(e);return JSON.parse(n)}catch(e){throw K.createClientInfoDecodingError(e.message)}}function oe(e){if(W.isEmpty(e))throw K.createClientInfoDecodingError("Home account ID was empty.");var t=e.split(T.CLIENT_INFO_SEPARATOR,2);return{uid:t[0],utid:t.length<2?f.EMPTY_STRING:t[1]}}!function(e){e[e.Default=0]="Default",e[e.Adfs=1]="Adfs",e[e.Dsts=2]="Dsts"}(Z||(Z={}));var ie,se=function(){function e(){}return e.prototype.generateAccountId=function(){return[this.homeAccountId,this.environment].join(T.CACHE_KEY_SEPARATOR).toLowerCase()},e.prototype.generateAccountKey=function(){return e.generateAccountCacheKey({homeAccountId:this.homeAccountId,environment:this.environment,tenantId:this.realm,username:this.username,localAccountId:this.localAccountId})},e.prototype.generateType=function(){switch(this.authorityType){case E.ADFS_ACCOUNT_TYPE:return x.ADFS;case E.MSAV1_ACCOUNT_TYPE:return x.MSA;case E.MSSTS_ACCOUNT_TYPE:return x.MSSTS;case E.GENERIC_ACCOUNT_TYPE:return x.GENERIC;default:throw K.createUnexpectedAccountTypeError()}},e.prototype.getAccountInfo=function(){return{homeAccountId:this.homeAccountId,environment:this.environment,tenantId:this.realm,username:this.username,localAccountId:this.localAccountId,name:this.name,idTokenClaims:this.idTokenClaims,nativeAccountId:this.nativeAccountId}},e.generateAccountCacheKey=function(e){return[e.homeAccountId,e.environment||f.EMPTY_STRING,e.tenantId||f.EMPTY_STRING].join(T.CACHE_KEY_SEPARATOR).toLowerCase()},e.createAccount=function(t,n,r,o,i,s,a,c){var u,l,p,d,h,m,v=new e;v.authorityType=E.MSSTS_ACCOUNT_TYPE,v.clientInfo=t,v.homeAccountId=n,v.nativeAccountId=c;var g=a||o&&o.getPreferredCache();if(!g)throw K.createInvalidCacheEnvironmentError();if(v.environment=g,v.realm=(null===(u=null==r?void 0:r.claims)||void 0===u?void 0:u.tid)||f.EMPTY_STRING,r){v.idTokenClaims=r.claims,v.localAccountId=(null===(l=null==r?void 0:r.claims)||void 0===l?void 0:l.oid)||(null===(p=null==r?void 0:r.claims)||void 0===p?void 0:p.sub)||f.EMPTY_STRING;var y=null===(d=null==r?void 0:r.claims)||void 0===d?void 0:d.preferred_username,_=(null===(h=null==r?void 0:r.claims)||void 0===h?void 0:h.emails)?r.claims.emails[0]:null;v.username=y||_||f.EMPTY_STRING,v.name=null===(m=null==r?void 0:r.claims)||void 0===m?void 0:m.name}return v.cloudGraphHostName=i,v.msGraphHost=s,v},e.createGenericAccount=function(t,n,r,o,i,s){var a,c,u,l,p=new e;p.authorityType=r&&r.authorityType===Z.Adfs?E.ADFS_ACCOUNT_TYPE:E.GENERIC_ACCOUNT_TYPE,p.homeAccountId=t,p.realm=f.EMPTY_STRING;var d=s||r&&r.getPreferredCache();if(!d)throw K.createInvalidCacheEnvironmentError();return n&&(p.localAccountId=(null===(a=null==n?void 0:n.claims)||void 0===a?void 0:a.oid)||(null===(c=null==n?void 0:n.claims)||void 0===c?void 0:c.sub)||f.EMPTY_STRING,p.username=(null===(u=null==n?void 0:n.claims)||void 0===u?void 0:u.upn)||f.EMPTY_STRING,p.name=(null===(l=null==n?void 0:n.claims)||void 0===l?void 0:l.name)||f.EMPTY_STRING,p.idTokenClaims=null==n?void 0:n.claims),p.environment=d,p.cloudGraphHostName=o,p.msGraphHost=i,p},e.generateHomeAccountId=function(e,t,n,r,o){var i,s=(null===(i=null==o?void 0:o.claims)||void 0===i?void 0:i.sub)?o.claims.sub:f.EMPTY_STRING;if(t===Z.Adfs||t===Z.Dsts)return s;if(e)try{var a=re(e,r);if(!W.isEmpty(a.uid)&&!W.isEmpty(a.utid))return""+a.uid+T.CLIENT_INFO_SEPARATOR+a.utid}catch(e){}return n.verbose("No client info in response"),s},e.isAccountEntity=function(e){return!!e&&e.hasOwnProperty("homeAccountId")&&e.hasOwnProperty("environment")&&e.hasOwnProperty("realm")&&e.hasOwnProperty("localAccountId")&&e.hasOwnProperty("username")&&e.hasOwnProperty("authorityType")},e.accountInfoIsEqual=function(e,t,n){if(!e||!t)return!1;var r=!0;if(n){var o=e.idTokenClaims||{},i=t.idTokenClaims||{};r=o.iat===i.iat&&o.nonce===i.nonce}return e.homeAccountId===t.homeAccountId&&e.localAccountId===t.localAccountId&&e.username===t.username&&e.tenantId===t.tenantId&&e.environment===t.environment&&e.nativeAccountId===t.nativeAccountId&&r},e}(),ae=function(){function e(t,n){if(W.isEmpty(t))throw K.createTokenNullOrEmptyError(t);this.rawToken=t,this.claims=e.extractTokenClaims(t,n)}return e.extractTokenClaims=function(e,t){var n=W.decodeAuthToken(e);try{var r=n.JWSPayload,o=t.base64Decode(r);return JSON.parse(o)}catch(e){throw K.createTokenParsingError(e)}},e.checkMaxAge=function(e,t){if(0===t||Date.now()-3e5>e+t)throw K.createMaxAgeTranspiredError()},e}(),ce=function(){function e(e,t){this.clientId=e,this.cryptoImpl=t}return e.prototype.getAllAccounts=function(){var t=this,n=this.getAccountsFilteredBy(),r=Object.keys(n).map((function(e){return n[e]}));return r.length<1?[]:r.map((function(n){var r=e.toObject(new se,n).getAccountInfo(),o=t.readIdTokenFromCache(t.clientId,r);return o&&!r.idTokenClaims&&(r.idToken=o.secret,r.idTokenClaims=new ae(o.secret,t.cryptoImpl).claims),r}))},e.prototype.saveCacheRecord=function(e){return s(this,void 0,void 0,(function(){return a(this,(function(t){switch(t.label){case 0:if(!e)throw K.createNullOrUndefinedCacheRecord();return e.account&&this.setAccount(e.account),e.idToken&&this.setIdTokenCredential(e.idToken),e.accessToken?[4,this.saveAccessToken(e.accessToken)]:[3,2];case 1:t.sent(),t.label=2;case 2:return e.refreshToken&&this.setRefreshTokenCredential(e.refreshToken),e.appMetadata&&this.setAppMetadata(e.appMetadata),[2]}}))}))},e.prototype.saveAccessToken=function(e){return s(this,void 0,void 0,(function(){var t,n,r,o,i=this;return a(this,(function(s){switch(s.label){case 0:return t=this.getCredentialsFilteredBy({clientId:e.clientId,credentialType:e.credentialType,environment:e.environment,homeAccountId:e.homeAccountId,realm:e.realm,tokenType:e.tokenType,requestedClaimsHash:e.requestedClaimsHash}),n=ne.fromString(e.target),(r=Object.keys(t.accessTokens).map((function(e){return t.accessTokens[e]})))?(o=[],r.forEach((function(e){ne.fromString(e.target).intersectingScopeSets(n)&&o.push(i.removeCredential(e))})),[4,Promise.all(o)]):[3,2];case 1:s.sent(),s.label=2;case 2:return this.setAccessTokenCredential(e),[2]}}))}))},e.prototype.getAccountsFilteredBy=function(e){return this.getAccountsFilteredByInternal(e?e.homeAccountId:f.EMPTY_STRING,e?e.environment:f.EMPTY_STRING,e?e.realm:f.EMPTY_STRING,e?e.nativeAccountId:f.EMPTY_STRING)},e.prototype.getAccountsFilteredByInternal=function(e,t,n,r){var o=this,i=this.getKeys(),s={};return i.forEach((function(i){var a=o.getAccount(i);a&&(e&&!o.matchHomeAccountId(a,e)||t&&!o.matchEnvironment(a,t)||n&&!o.matchRealm(a,n)||r&&!o.matchNativeAccountId(a,r)||(s[i]=a))})),s},e.prototype.getCredentialsFilteredBy=function(e){return this.getCredentialsFilteredByInternal(e.homeAccountId,e.environment,e.credentialType,e.clientId,e.familyId,e.realm,e.target,e.userAssertionHash,e.tokenType,e.keyId,e.requestedClaimsHash)},e.prototype.getCredentialsFilteredByInternal=function(e,t,n,r,o,i,s,a,c,u,l){var p=this,d=this.getKeys(),h={idTokens:{},accessTokens:{},refreshTokens:{}};return d.forEach((function(d){var m=J.getCredentialType(d);if(m!==f.NOT_DEFINED){var v=p.getSpecificCredential(d,m);if(v&&(!a||p.matchUserAssertionHash(v,a))&&("string"!=typeof e||p.matchHomeAccountId(v,e))&&(!t||p.matchEnvironment(v,t))&&(!i||p.matchRealm(v,i))&&(!n||p.matchCredentialType(v,n))&&(!r||p.matchClientId(v,r))&&(!o||p.matchFamilyId(v,o))&&(!s||p.matchTarget(v,s))&&(!l&&!v.requestedClaimsHash||v.requestedClaimsHash===l)){if(n===S.ACCESS_TOKEN_WITH_AUTH_SCHEME){if(c&&!p.matchTokenType(v,c))return;if(c===O.SSH&&u&&!p.matchKeyId(v,u))return}var g=p.updateCredentialCacheKey(d,v);switch(m){case S.ID_TOKEN:h.idTokens[g]=v;break;case S.ACCESS_TOKEN:case S.ACCESS_TOKEN_WITH_AUTH_SCHEME:h.accessTokens[g]=v;break;case S.REFRESH_TOKEN:h.refreshTokens[g]=v}}}})),h},e.prototype.getAppMetadataFilteredBy=function(e){return this.getAppMetadataFilteredByInternal(e.environment,e.clientId)},e.prototype.getAppMetadataFilteredByInternal=function(e,t){var n=this,r=this.getKeys(),o={};return r.forEach((function(r){if(n.isAppMetadata(r)){var i=n.getAppMetadata(r);i&&(e&&!n.matchEnvironment(i,e)||t&&!n.matchClientId(i,t)||(o[r]=i))}})),o},e.prototype.getAuthorityMetadataByAlias=function(e){var t=this,n=this.getAuthorityMetadataKeys(),r=null;return n.forEach((function(n){if(t.isAuthorityMetadata(n)&&-1!==n.indexOf(t.clientId)){var o=t.getAuthorityMetadata(n);o&&-1!==o.aliases.indexOf(e)&&(r=o)}})),r},e.prototype.removeAllAccounts=function(){return s(this,void 0,void 0,(function(){var e,t,n=this;return a(this,(function(r){switch(r.label){case 0:return e=this.getKeys(),t=[],e.forEach((function(e){n.getAccount(e)&&t.push(n.removeAccount(e))})),[4,Promise.all(t)];case 1:return r.sent(),[2,!0]}}))}))},e.prototype.removeAccount=function(e){return s(this,void 0,void 0,(function(){var t;return a(this,(function(n){switch(n.label){case 0:if(!(t=this.getAccount(e)))throw K.createNoAccountFoundError();return[4,this.removeAccountContext(t)];case 1:return[2,n.sent()&&this.removeItem(e,C.ACCOUNT)]}}))}))},e.prototype.removeAccountContext=function(e){return s(this,void 0,void 0,(function(){var t,n,r,o=this;return a(this,(function(i){switch(i.label){case 0:return t=this.getKeys(),n=e.generateAccountId(),r=[],t.forEach((function(e){var t=J.getCredentialType(e);if(t!==f.NOT_DEFINED){var i=o.getSpecificCredential(e,t);i&&n===i.generateAccountId()&&r.push(o.removeCredential(i))}})),[4,Promise.all(r)];case 1:return i.sent(),[2,!0]}}))}))},e.prototype.removeCredential=function(e){return s(this,void 0,void 0,(function(){var t,n;return a(this,(function(r){switch(r.label){case 0:if(t=e.generateCredentialKey(),e.credentialType.toLowerCase()!==S.ACCESS_TOKEN_WITH_AUTH_SCHEME.toLowerCase())return[3,4];if(e.tokenType!==O.POP)return[3,4];if(!(n=e.keyId))return[3,4];r.label=1;case 1:return r.trys.push([1,3,,4]),[4,this.cryptoImpl.removeTokenBindingKey(n)];case 2:return r.sent(),[3,4];case 3:throw r.sent(),K.createBindingKeyNotRemovedError();case 4:return[2,this.removeItem(t,C.CREDENTIAL)]}}))}))},e.prototype.removeAppMetadata=function(){var e=this;return this.getKeys().forEach((function(t){e.isAppMetadata(t)&&e.removeItem(t,C.APP_METADATA)})),!0},e.prototype.readCacheRecord=function(e,t,n,r){var o=this.readAccountFromCache(e),i=this.readIdTokenFromCache(t,e),s=this.readAccessTokenFromCache(t,e,n),a=this.readRefreshTokenFromCache(t,e,!1),c=this.readAppMetadataFromCache(r,t);return o&&i&&(o.idTokenClaims=new ae(i.secret,this.cryptoImpl).claims),{account:o,idToken:i,accessToken:s,refreshToken:a,appMetadata:c}},e.prototype.readAccountFromCache=function(e){var t=se.generateAccountCacheKey(e);return this.getAccount(t)},e.prototype.readAccountFromCacheWithNativeAccountId=function(e){var t={nativeAccountId:e},n=this.getAccountsFilteredBy(t),r=Object.keys(n).map((function(e){return n[e]}));if(r.length<1)return null;if(r.length>1)throw K.createMultipleMatchingAccountsInCacheError();return r[0]},e.prototype.readIdTokenFromCache=function(e,t){var n={homeAccountId:t.homeAccountId,environment:t.environment,credentialType:S.ID_TOKEN,clientId:e,realm:t.tenantId},r=this.getCredentialsFilteredBy(n),o=Object.keys(r.idTokens).map((function(e){return r.idTokens[e]})),i=o.length;if(i<1)return null;if(i>1)throw K.createMultipleMatchingTokensInCacheError();return o[0]},e.prototype.readAccessTokenFromCache=function(e,t,n){var r=new ne(n.scopes||[]),o=n.authenticationScheme||O.BEARER,i=o&&o.toLowerCase()!==O.BEARER.toLowerCase()?S.ACCESS_TOKEN_WITH_AUTH_SCHEME:S.ACCESS_TOKEN,s={homeAccountId:t.homeAccountId,environment:t.environment,credentialType:i,clientId:e,realm:t.tenantId,target:r.printScopesLowerCase(),tokenType:o,keyId:n.sshKid,requestedClaimsHash:n.requestedClaimsHash},a=this.getCredentialsFilteredBy(s),c=Object.keys(a.accessTokens).map((function(e){return a.accessTokens[e]})),u=c.length;if(u<1)return null;if(u>1)throw K.createMultipleMatchingTokensInCacheError();return c[0]},e.prototype.readRefreshTokenFromCache=function(e,t,n){var r=n?R:void 0,o={homeAccountId:t.homeAccountId,environment:t.environment,credentialType:S.REFRESH_TOKEN,clientId:e,familyId:r},i=this.getCredentialsFilteredBy(o),s=Object.keys(i.refreshTokens).map((function(e){return i.refreshTokens[e]}));return s.length<1?null:s[0]},e.prototype.readAppMetadataFromCache=function(e,t){var n={environment:e,clientId:t},r=this.getAppMetadataFilteredBy(n),o=Object.keys(r).map((function(e){return r[e]})),i=o.length;if(i<1)return null;if(i>1)throw K.createMultipleMatchingAppMetadataInCacheError();return o[0]},e.prototype.isAppMetadataFOCI=function(e,t){var n=this.readAppMetadataFromCache(e,t);return!(!n||n.familyId!==R)},e.prototype.matchHomeAccountId=function(e,t){return!("string"!=typeof e.homeAccountId||t!==e.homeAccountId)},e.prototype.matchUserAssertionHash=function(e,t){return!(!e.userAssertionHash||t!==e.userAssertionHash)},e.prototype.matchEnvironment=function(e,t){var n=this.getAuthorityMetadataByAlias(t);return!!(n&&n.aliases.indexOf(e.environment)>-1)},e.prototype.matchCredentialType=function(e,t){return e.credentialType&&t.toLowerCase()===e.credentialType.toLowerCase()},e.prototype.matchClientId=function(e,t){return!(!e.clientId||t!==e.clientId)},e.prototype.matchFamilyId=function(e,t){return!(!e.familyId||t!==e.familyId)},e.prototype.matchRealm=function(e,t){return!(!e.realm||t!==e.realm)},e.prototype.matchNativeAccountId=function(e,t){return!(!e.nativeAccountId||t!==e.nativeAccountId)},e.prototype.matchTarget=function(e,t){if(e.credentialType!==S.ACCESS_TOKEN&&e.credentialType!==S.ACCESS_TOKEN_WITH_AUTH_SCHEME||!e.target)return!1;var n=ne.fromString(e.target),r=ne.fromString(t);return r.containsOnlyOIDCScopes()?r.removeScope(f.OFFLINE_ACCESS_SCOPE):r.removeOIDCScopes(),n.containsScopeSet(r)},e.prototype.matchTokenType=function(e,t){return!(!e.tokenType||e.tokenType!==t)},e.prototype.matchKeyId=function(e,t){return!(!e.keyId||e.keyId!==t)},e.prototype.isAppMetadata=function(e){return-1!==e.indexOf(I)},e.prototype.isAuthorityMetadata=function(e){return-1!==e.indexOf(P)},e.prototype.generateAuthorityMetadataCacheKey=function(e){return P+"-"+this.clientId+"-"+e},e.prototype.getSpecificCredential=function(e,t){switch(t){case S.ID_TOKEN:return this.getIdTokenCredential(e);case S.ACCESS_TOKEN:case S.ACCESS_TOKEN_WITH_AUTH_SCHEME:return this.getAccessTokenCredential(e);case S.REFRESH_TOKEN:return this.getRefreshTokenCredential(e);default:return null}},e.toObject=function(e,t){for(var n in t)e[n]=t[n];return e},e}(),ue=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.prototype.setAccount=function(){throw G.createUnexpectedError("Storage interface - setAccount() has not been implemented for the cacheStorage interface.")},t.prototype.getAccount=function(){throw G.createUnexpectedError("Storage interface - getAccount() has not been implemented for the cacheStorage interface.")},t.prototype.setIdTokenCredential=function(){throw G.createUnexpectedError("Storage interface - setIdTokenCredential() has not been implemented for the cacheStorage interface.")},t.prototype.getIdTokenCredential=function(){throw G.createUnexpectedError("Storage interface - getIdTokenCredential() has not been implemented for the cacheStorage interface.")},t.prototype.setAccessTokenCredential=function(){throw G.createUnexpectedError("Storage interface - setAccessTokenCredential() has not been implemented for the cacheStorage interface.")},t.prototype.getAccessTokenCredential=function(){throw G.createUnexpectedError("Storage interface - getAccessTokenCredential() has not been implemented for the cacheStorage interface.")},t.prototype.setRefreshTokenCredential=function(){throw G.createUnexpectedError("Storage interface - setRefreshTokenCredential() has not been implemented for the cacheStorage interface.")},t.prototype.getRefreshTokenCredential=function(){throw G.createUnexpectedError("Storage interface - getRefreshTokenCredential() has not been implemented for the cacheStorage interface.")},t.prototype.setAppMetadata=function(){throw G.createUnexpectedError("Storage interface - setAppMetadata() has not been implemented for the cacheStorage interface.")},t.prototype.getAppMetadata=function(){throw G.createUnexpectedError("Storage interface - getAppMetadata() has not been implemented for the cacheStorage interface.")},t.prototype.setServerTelemetry=function(){throw G.createUnexpectedError("Storage interface - setServerTelemetry() has not been implemented for the cacheStorage interface.")},t.prototype.getServerTelemetry=function(){throw G.createUnexpectedError("Storage interface - getServerTelemetry() has not been implemented for the cacheStorage interface.")},t.prototype.setAuthorityMetadata=function(){throw G.createUnexpectedError("Storage interface - setAuthorityMetadata() has not been implemented for the cacheStorage interface.")},t.prototype.getAuthorityMetadata=function(){throw G.createUnexpectedError("Storage interface - getAuthorityMetadata() has not been implemented for the cacheStorage interface.")},t.prototype.getAuthorityMetadataKeys=function(){throw G.createUnexpectedError("Storage interface - getAuthorityMetadataKeys() has not been implemented for the cacheStorage interface.")},t.prototype.setThrottlingCache=function(){throw G.createUnexpectedError("Storage interface - setThrottlingCache() has not been implemented for the cacheStorage interface.")},t.prototype.getThrottlingCache=function(){throw G.createUnexpectedError("Storage interface - getThrottlingCache() has not been implemented for the cacheStorage interface.")},t.prototype.removeItem=function(){throw G.createUnexpectedError("Storage interface - removeItem() has not been implemented for the cacheStorage interface.")},t.prototype.containsKey=function(){throw G.createUnexpectedError("Storage interface - containsKey() has not been implemented for the cacheStorage interface.")},t.prototype.getKeys=function(){throw G.createUnexpectedError("Storage interface - getKeys() has not been implemented for the cacheStorage interface.")},t.prototype.clear=function(){return s(this,void 0,void 0,(function(){return a(this,(function(e){throw G.createUnexpectedError("Storage interface - clear() has not been implemented for the cacheStorage interface.")}))}))},t.prototype.updateCredentialCacheKey=function(){throw G.createUnexpectedError("Storage interface - updateCredentialCacheKey() has not been implemented for the cacheStorage interface.")},t}(ce),le={tokenRenewalOffsetSeconds:300,preventCorsPreflight:!1},pe={loggerCallback:function(){},piiLoggingEnabled:!1,logLevel:q.Info,correlationId:f.EMPTY_STRING},de={sendGetRequestAsync:function(){return s(this,void 0,void 0,(function(){return a(this,(function(e){throw G.createUnexpectedError("Network interface - sendGetRequestAsync() has not been implemented")}))}))},sendPostRequestAsync:function(){return s(this,void 0,void 0,(function(){return a(this,(function(e){throw G.createUnexpectedError("Network interface - sendPostRequestAsync() has not been implemented")}))}))}},he={sku:f.SKU,version:X,cpu:f.EMPTY_STRING,os:f.EMPTY_STRING},fe={clientSecret:f.EMPTY_STRING,clientAssertion:void 0},me={azureCloudInstance:Q.None,tenant:""+f.DEFAULT_COMMON_TENANT},ve={application:{appName:"",appVersion:""}},ge=function(e){function t(n,r,o){var i=e.call(this,n,r,o)||this;return i.name="ServerError",Object.setPrototypeOf(i,t.prototype),i}return o(t,e),t}(G),ye=function(){function e(){}return e.generateThrottlingStorageKey=function(e){return F.THROTTLING_PREFIX+"."+JSON.stringify(e)},e.preProcess=function(t,n){var r,o=e.generateThrottlingStorageKey(n),i=t.getThrottlingCache(o);if(i){if(i.throttleTime<Date.now())return void t.removeItem(o,C.THROTTLING);throw new ge((null===(r=i.errorCodes)||void 0===r?void 0:r.join(" "))||f.EMPTY_STRING,i.errorMessage,i.subError)}},e.postProcess=function(t,n,r){if(e.checkResponseStatus(r)||e.checkResponseForRetryAfter(r)){var o={throttleTime:e.calculateThrottleTime(parseInt(r.headers[u.RETRY_AFTER])),error:r.body.error,errorCodes:r.body.error_codes,errorMessage:r.body.error_description,subError:r.body.suberror};t.setThrottlingCache(e.generateThrottlingStorageKey(n),o)}},e.checkResponseStatus=function(e){return 429===e.status||e.status>=500&&e.status<600},e.checkResponseForRetryAfter=function(e){return!!e.headers&&e.headers.hasOwnProperty(u.RETRY_AFTER)&&(e.status<200||e.status>=300)},e.calculateThrottleTime=function(e){var t=e<=0?0:e,n=Date.now()/1e3;return Math.floor(1e3*Math.min(n+(t||F.DEFAULT_THROTTLE_TIME_SECONDS),n+F.DEFAULT_MAX_THROTTLE_TIME_SECONDS))},e.removeThrottle=function(e,t,n,r){var o={clientId:t,authority:n.authority,scopes:n.scopes,homeAccountIdentifier:r,claims:n.claims,authenticationScheme:n.authenticationScheme,resourceRequestMethod:n.resourceRequestMethod,resourceRequestUri:n.resourceRequestUri,shrClaims:n.shrClaims,sshKid:n.sshKid},i=this.generateThrottlingStorageKey(o);return e.removeItem(i,C.THROTTLING)},e}(),_e=function(){function e(e,t){this.networkClient=e,this.cacheManager=t}return e.prototype.sendPostRequest=function(e,t,n){return s(this,void 0,void 0,(function(){var r,o;return a(this,(function(i){switch(i.label){case 0:ye.preProcess(this.cacheManager,e),i.label=1;case 1:return i.trys.push([1,3,,4]),[4,this.networkClient.sendPostRequestAsync(t,n)];case 2:return r=i.sent(),[3,4];case 3:throw(o=i.sent())instanceof G?o:K.createNetworkError(t,o);case 4:return ye.postProcess(this.cacheManager,e,r),[2,r]}}))}))},e}();!function(e){e.HOME_ACCOUNT_ID="home_account_id",e.UPN="UPN"}(ie||(ie={}));var be,Ee,Te=function(){function e(){}return e.validateRedirectUri=function(e){if(W.isEmpty(e))throw te.createRedirectUriEmptyError()},e.validatePrompt=function(e){var t=[];for(var n in y)t.push(y[n]);if(t.indexOf(e)<0)throw te.createInvalidPromptError(e)},e.validateClaims=function(e){try{JSON.parse(e)}catch(e){throw te.createInvalidClaimsRequestError()}},e.validateCodeChallengeParams=function(e,t){if(W.isEmpty(e)||W.isEmpty(t))throw te.createInvalidCodeChallengeParamsError();this.validateCodeChallengeMethod(t)},e.validateCodeChallengeMethod=function(e){if([w.PLAIN,w.S256].indexOf(e)<0)throw te.createInvalidCodeChallengeMethodError()},e.sanitizeEQParams=function(e,t){return e?(t.forEach((function(t,n){e[n]&&delete e[n]})),Object.fromEntries(Object.entries(e).filter((function(e){return""!==e[1]})))):{}},e}(),Se=function(){function e(){this.parameters=new Map}return e.prototype.addResponseTypeCode=function(){this.parameters.set(d.RESPONSE_TYPE,encodeURIComponent(f.CODE_RESPONSE_TYPE))},e.prototype.addResponseTypeForTokenAndIdToken=function(){this.parameters.set(d.RESPONSE_TYPE,encodeURIComponent(f.TOKEN_RESPONSE_TYPE+" "+f.ID_TOKEN_RESPONSE_TYPE))},e.prototype.addResponseMode=function(e){this.parameters.set(d.RESPONSE_MODE,encodeURIComponent(e||_.QUERY))},e.prototype.addNativeBroker=function(){this.parameters.set(d.NATIVE_BROKER,encodeURIComponent("1"))},e.prototype.addScopes=function(e,t){void 0===t&&(t=!0);var n=t?c(e||[],m):e||[],r=new ne(n);this.parameters.set(d.SCOPE,encodeURIComponent(r.printScopes()))},e.prototype.addClientId=function(e){this.parameters.set(d.CLIENT_ID,encodeURIComponent(e))},e.prototype.addRedirectUri=function(e){Te.validateRedirectUri(e),this.parameters.set(d.REDIRECT_URI,encodeURIComponent(e))},e.prototype.addPostLogoutRedirectUri=function(e){Te.validateRedirectUri(e),this.parameters.set(d.POST_LOGOUT_URI,encodeURIComponent(e))},e.prototype.addIdTokenHint=function(e){this.parameters.set(d.ID_TOKEN_HINT,encodeURIComponent(e))},e.prototype.addDomainHint=function(e){this.parameters.set(g.DOMAIN_HINT,encodeURIComponent(e))},e.prototype.addLoginHint=function(e){this.parameters.set(g.LOGIN_HINT,encodeURIComponent(e))},e.prototype.addCcsUpn=function(e){this.parameters.set(u.CCS_HEADER,encodeURIComponent("UPN:"+e))},e.prototype.addCcsOid=function(e){this.parameters.set(u.CCS_HEADER,encodeURIComponent("Oid:"+e.uid+"@"+e.utid))},e.prototype.addSid=function(e){this.parameters.set(g.SID,encodeURIComponent(e))},e.prototype.addClaims=function(e,t){var n=this.addClientCapabilitiesToClaims(e,t);Te.validateClaims(n),this.parameters.set(d.CLAIMS,encodeURIComponent(n))},e.prototype.addCorrelationId=function(e){this.parameters.set(d.CLIENT_REQUEST_ID,encodeURIComponent(e))},e.prototype.addLibraryInfo=function(e){this.parameters.set(d.X_CLIENT_SKU,e.sku),this.parameters.set(d.X_CLIENT_VER,e.version),e.os&&this.parameters.set(d.X_CLIENT_OS,e.os),e.cpu&&this.parameters.set(d.X_CLIENT_CPU,e.cpu)},e.prototype.addApplicationTelemetry=function(e){(null==e?void 0:e.appName)&&this.parameters.set(d.X_APP_NAME,e.appName),(null==e?void 0:e.appVersion)&&this.parameters.set(d.X_APP_VER,e.appVersion)},e.prototype.addPrompt=function(e){Te.validatePrompt(e),this.parameters.set(""+d.PROMPT,encodeURIComponent(e))},e.prototype.addState=function(e){W.isEmpty(e)||this.parameters.set(d.STATE,encodeURIComponent(e))},e.prototype.addNonce=function(e){this.parameters.set(d.NONCE,encodeURIComponent(e))},e.prototype.addCodeChallengeParams=function(e,t){if(Te.validateCodeChallengeParams(e,t),!e||!t)throw te.createInvalidCodeChallengeParamsError();this.parameters.set(d.CODE_CHALLENGE,encodeURIComponent(e)),this.parameters.set(d.CODE_CHALLENGE_METHOD,encodeURIComponent(t))},e.prototype.addAuthorizationCode=function(e){this.parameters.set(d.CODE,encodeURIComponent(e))},e.prototype.addDeviceCode=function(e){this.parameters.set(d.DEVICE_CODE,encodeURIComponent(e))},e.prototype.addRefreshToken=function(e){this.parameters.set(d.REFRESH_TOKEN,encodeURIComponent(e))},e.prototype.addCodeVerifier=function(e){this.parameters.set(d.CODE_VERIFIER,encodeURIComponent(e))},e.prototype.addClientSecret=function(e){this.parameters.set(d.CLIENT_SECRET,encodeURIComponent(e))},e.prototype.addClientAssertion=function(e){W.isEmpty(e)||this.parameters.set(d.CLIENT_ASSERTION,encodeURIComponent(e))},e.prototype.addClientAssertionType=function(e){W.isEmpty(e)||this.parameters.set(d.CLIENT_ASSERTION_TYPE,encodeURIComponent(e))},e.prototype.addOboAssertion=function(e){this.parameters.set(d.OBO_ASSERTION,encodeURIComponent(e))},e.prototype.addRequestTokenUse=function(e){this.parameters.set(d.REQUESTED_TOKEN_USE,encodeURIComponent(e))},e.prototype.addGrantType=function(e){this.parameters.set(d.GRANT_TYPE,encodeURIComponent(e))},e.prototype.addClientInfo=function(){this.parameters.set("client_info","1")},e.prototype.addExtraQueryParameters=function(e){var t=this,n=Te.sanitizeEQParams(e,this.parameters);Object.keys(n).forEach((function(n){t.parameters.set(n,e[n])}))},e.prototype.addClientCapabilitiesToClaims=function(e,t){var n;if(e)try{n=JSON.parse(e)}catch(e){throw te.createInvalidClaimsRequestError()}else n={};return t&&t.length>0&&(n.hasOwnProperty(h.ACCESS_TOKEN)||(n[h.ACCESS_TOKEN]={}),n[h.ACCESS_TOKEN][h.XMS_CC]={values:t}),JSON.stringify(n)},e.prototype.addUsername=function(e){this.parameters.set(k.username,encodeURIComponent(e))},e.prototype.addPassword=function(e){this.parameters.set(k.password,encodeURIComponent(e))},e.prototype.addPopToken=function(e){W.isEmpty(e)||(this.parameters.set(d.TOKEN_TYPE,O.POP),this.parameters.set(d.REQ_CNF,encodeURIComponent(e)))},e.prototype.addSshJwk=function(e){W.isEmpty(e)||(this.parameters.set(d.TOKEN_TYPE,O.SSH),this.parameters.set(d.REQ_CNF,encodeURIComponent(e)))},e.prototype.addServerTelemetry=function(e){this.parameters.set(d.X_CLIENT_CURR_TELEM,e.generateCurrentRequestHeaderValue()),this.parameters.set(d.X_CLIENT_LAST_TELEM,e.generateLastRequestHeaderValue())},e.prototype.addThrottling=function(){this.parameters.set(d.X_MS_LIB_CAPABILITY,F.X_MS_LIB_CAPABILITY_VALUE)},e.prototype.addLogoutHint=function(e){this.parameters.set(d.LOGOUT_HINT,encodeURIComponent(e))},e.prototype.createQueryString=function(){var e=new Array;return this.parameters.forEach((function(t,n){e.push(n+"="+t)})),e.join("&")},e}(),Ce=function(){function e(e,t){var n,r,o,s,a,c,u,l,p,d,h,f,m,v,g;this.config=(o=(n=e).authOptions,s=n.systemOptions,a=n.loggerOptions,c=n.storageInterface,u=n.networkInterface,l=n.cryptoInterface,p=n.clientCredentials,d=n.libraryInfo,h=n.telemetry,f=n.serverTelemetryManager,m=n.persistencePlugin,v=n.serializableCache,g=i(i({},pe),a),{authOptions:(r=o,i({clientCapabilities:[],azureCloudOptions:me,skipAuthorityMetadataCache:!1},r)),systemOptions:i(i({},le),s),loggerOptions:g,storageInterface:c||new ue(o.clientId,V),networkInterface:u||de,cryptoInterface:l||V,clientCredentials:p||fe,libraryInfo:i(i({},he),d),telemetry:i(i({},ve),h),serverTelemetryManager:f||null,persistencePlugin:m||null,serializableCache:v||null}),this.logger=new Y(this.config.loggerOptions,"@azure/msal-common",X),this.cryptoUtils=this.config.cryptoInterface,this.cacheManager=this.config.storageInterface,this.networkClient=this.config.networkInterface,this.networkManager=new _e(this.networkClient,this.cacheManager),this.serverTelemetryManager=this.config.serverTelemetryManager,this.authority=this.config.authOptions.authority,this.performanceClient=t}return e.prototype.createTokenRequestHeaders=function(e){var t={};if(t[u.CONTENT_TYPE]=f.URL_FORM_CONTENT_TYPE,!this.config.systemOptions.preventCorsPreflight&&e)switch(e.type){case ie.HOME_ACCOUNT_ID:try{var n=oe(e.credential);t[u.CCS_HEADER]="Oid:"+n.uid+"@"+n.utid}catch(e){this.logger.verbose("Could not parse home account ID for CCS Header: "+e)}break;case ie.UPN:t[u.CCS_HEADER]="UPN: "+e.credential}return t},e.prototype.executePostToTokenEndpoint=function(e,t,n,r){return s(this,void 0,void 0,(function(){var o;return a(this,(function(i){switch(i.label){case 0:return[4,this.networkManager.sendPostRequest(r,e,{body:t,headers:n})];case 1:return o=i.sent(),this.config.serverTelemetryManager&&o.status<500&&429!==o.status&&this.config.serverTelemetryManager.clearTelemetryCache(),[2,o]}}))}))},e.prototype.updateAuthority=function(e){if(!e.discoveryComplete())throw K.createEndpointDiscoveryIncompleteError("Updated authority has not completed endpoint discovery.");this.authority=e},e.prototype.createTokenQueryParameters=function(e){var t=new Se;return e.tokenQueryParameters&&t.addExtraQueryParameters(e.tokenQueryParameters),t.createQueryString()},e}(),xe=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.createIdTokenEntity=function(e,n,r,o,i){var s=new t;return s.credentialType=S.ID_TOKEN,s.homeAccountId=e,s.environment=n,s.clientId=o,s.secret=r,s.realm=i,s},t.isIdTokenEntity=function(e){return!!e&&e.hasOwnProperty("homeAccountId")&&e.hasOwnProperty("environment")&&e.hasOwnProperty("credentialType")&&e.hasOwnProperty("realm")&&e.hasOwnProperty("clientId")&&e.hasOwnProperty("secret")&&e.credentialType===S.ID_TOKEN},t}(J),we=function(){function e(){}return e.nowSeconds=function(){return Math.round((new Date).getTime()/1e3)},e.isTokenExpired=function(t,n){var r=Number(t)||0;return e.nowSeconds()+n>r},e.wasClockTurnedBack=function(t){return Number(t)>e.nowSeconds()},e.delay=function(e,t){return new Promise((function(n){return setTimeout((function(){return n(t)}),e)}))},e}(),Ae=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.createAccessTokenEntity=function(e,n,r,o,i,s,a,c,u,l,p,d,h,f,m){var v,g,y=new t;y.homeAccountId=e,y.credentialType=S.ACCESS_TOKEN,y.secret=r;var _=we.nowSeconds();if(y.cachedAt=_.toString(),y.expiresOn=a.toString(),y.extendedExpiresOn=c.toString(),l&&(y.refreshOn=l.toString()),y.environment=n,y.clientId=o,y.realm=i,y.target=s,y.userAssertionHash=d,y.tokenType=W.isEmpty(p)?O.BEARER:p,f&&(y.requestedClaims=f,y.requestedClaimsHash=m),(null===(v=y.tokenType)||void 0===v?void 0:v.toLowerCase())!==O.BEARER.toLowerCase())switch(y.credentialType=S.ACCESS_TOKEN_WITH_AUTH_SCHEME,y.tokenType){case O.POP:var b=ae.extractTokenClaims(r,u);if(!(null===(g=null==b?void 0:b.cnf)||void 0===g?void 0:g.kid))throw K.createTokenClaimsRequiredError();y.keyId=b.cnf.kid;break;case O.SSH:y.keyId=h}return y},t.isAccessTokenEntity=function(e){return!!e&&e.hasOwnProperty("homeAccountId")&&e.hasOwnProperty("environment")&&e.hasOwnProperty("credentialType")&&e.hasOwnProperty("realm")&&e.hasOwnProperty("clientId")&&e.hasOwnProperty("secret")&&e.hasOwnProperty("target")&&(e.credentialType===S.ACCESS_TOKEN||e.credentialType===S.ACCESS_TOKEN_WITH_AUTH_SCHEME)},t}(J),Ie=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.createRefreshTokenEntity=function(e,n,r,o,i,s){var a=new t;return a.clientId=o,a.credentialType=S.REFRESH_TOKEN,a.environment=n,a.homeAccountId=e,a.secret=r,a.userAssertionHash=s,i&&(a.familyId=i),a},t.isRefreshTokenEntity=function(e){return!!e&&e.hasOwnProperty("homeAccountId")&&e.hasOwnProperty("environment")&&e.hasOwnProperty("credentialType")&&e.hasOwnProperty("clientId")&&e.hasOwnProperty("secret")&&e.credentialType===S.REFRESH_TOKEN},t}(J),Re=["interaction_required","consent_required","login_required"],Pe=["message_only","additional_action","basic_action","user_password_expired","consent_required"],Oe={noTokensFoundError:{code:"no_tokens_found",desc:"No refresh token found in the cache. Please sign-in."},native_account_unavailable:{code:"native_account_unavailable",desc:"The requested account is not available in the native broker. It may have been deleted or logged out. Please sign-in again using an interactive API."}},Ne=function(e){function t(n,r,o,i,s,a,c){var u=e.call(this,n,r,o)||this;return Object.setPrototypeOf(u,t.prototype),u.timestamp=i||f.EMPTY_STRING,u.traceId=s||f.EMPTY_STRING,u.correlationId=a||f.EMPTY_STRING,u.claims=c||f.EMPTY_STRING,u.name="InteractionRequiredAuthError",u}return o(t,e),t.isInteractionRequiredError=function(e,t,n){var r=!!e&&Re.indexOf(e)>-1,o=!!n&&Pe.indexOf(n)>-1,i=!!t&&Re.some((function(e){return t.indexOf(e)>-1}));return r||i||o},t.createNoTokensFoundError=function(){return new t(Oe.noTokensFoundError.code,Oe.noTokensFoundError.desc)},t.createNativeAccountUnavailableError=function(){return new t(Oe.native_account_unavailable.code,Oe.native_account_unavailable.desc)},t}(G),ke=function(e,t,n,r,o){this.account=e||null,this.idToken=t||null,this.accessToken=n||null,this.refreshToken=r||null,this.appMetadata=o||null},De=function(){function e(){}return e.setRequestState=function(t,n,r){var o=e.generateLibraryState(t,r);return W.isEmpty(n)?o:""+o+f.RESOURCE_DELIM+n},e.generateLibraryState=function(e,t){if(!e)throw K.createNoCryptoObjectError("generateLibraryState");var n={id:e.createNewGuid()};t&&(n.meta=t);var r=JSON.stringify(n);return e.base64Encode(r)},e.parseRequestState=function(e,t){if(!e)throw K.createNoCryptoObjectError("parseRequestState");if(W.isEmpty(t))throw K.createInvalidStateError(t,"Null, undefined or empty state");try{var n=t.split(f.RESOURCE_DELIM),r=n[0],o=n.length>1?n.slice(1).join(f.RESOURCE_DELIM):f.EMPTY_STRING,i=e.base64Decode(r),s=JSON.parse(i);return{userRequestState:W.isEmpty(o)?f.EMPTY_STRING:o,libraryState:s}}catch(e){throw K.createInvalidStateError(t,e)}},e}(),Me=function(){function e(t){if(this._urlString=t,W.isEmpty(this._urlString))throw te.createUrlEmptyError();W.isEmpty(this.getHash())&&(this._urlString=e.canonicalizeUri(t))}return Object.defineProperty(e.prototype,"urlString",{get:function(){return this._urlString},enumerable:!1,configurable:!0}),e.canonicalizeUri=function(e){if(e){var t=e.toLowerCase();return W.endsWith(t,"?")?t=t.slice(0,-1):W.endsWith(t,"?/")&&(t=t.slice(0,-2)),W.endsWith(t,"/")||(t+="/"),t}return e},e.prototype.validateAsUri=function(){var e;try{e=this.getUrlComponents()}catch(e){throw te.createUrlParseError(e)}if(!e.HostNameAndPort||!e.PathSegments)throw te.createUrlParseError("Given url string: "+this.urlString);if(!e.Protocol||"https:"!==e.Protocol.toLowerCase())throw te.createInsecureAuthorityUriError(this.urlString)},e.appendQueryString=function(e,t){return W.isEmpty(t)?e:e.indexOf("?")<0?e+"?"+t:e+"&"+t},e.removeHashFromUrl=function(t){return e.canonicalizeUri(t.split("#")[0])},e.prototype.replaceTenantPath=function(t){var n=this.getUrlComponents(),r=n.PathSegments;return!t||0===r.length||r[0]!==p.COMMON&&r[0]!==p.ORGANIZATIONS||(r[0]=t),e.constructAuthorityUriFromObject(n)},e.prototype.getHash=function(){return e.parseHash(this.urlString)},e.prototype.getUrlComponents=function(){var e=RegExp("^(([^:/?#]+):)?(//([^/?#]*))?([^?#]*)(\\?([^#]*))?(#(.*))?"),t=this.urlString.match(e);if(!t)throw te.createUrlParseError("Given url string: "+this.urlString);var n={Protocol:t[1],HostNameAndPort:t[4],AbsolutePath:t[5],QueryString:t[7]},r=n.AbsolutePath.split("/");return r=r.filter((function(e){return e&&e.length>0})),n.PathSegments=r,!W.isEmpty(n.QueryString)&&n.QueryString.endsWith("/")&&(n.QueryString=n.QueryString.substring(0,n.QueryString.length-1)),n},e.getDomainFromUrl=function(e){var t=RegExp("^([^:/?#]+://)?([^/?#]*)"),n=e.match(t);if(!n)throw te.createUrlParseError("Given url string: "+e);return n[2]},e.getAbsoluteUrl=function(t,n){if(t[0]===f.FORWARD_SLASH){var r=new e(n).getUrlComponents();return r.Protocol+"//"+r.HostNameAndPort+t}return t},e.parseHash=function(e){var t=e.indexOf("#"),n=e.indexOf("#/");return n>-1?e.substring(n+2):t>-1?e.substring(t+1):f.EMPTY_STRING},e.parseQueryString=function(e){var t=e.indexOf("?"),n=e.indexOf("/?");return n>-1?e.substring(n+2):t>-1?e.substring(t+1):f.EMPTY_STRING},e.constructAuthorityUriFromObject=function(t){return new e(t.Protocol+"//"+t.HostNameAndPort+"/"+t.PathSegments.join("/"))},e.getDeserializedHash=function(t){if(W.isEmpty(t))return{};var n=e.parseHash(t),r=W.queryStringToObject(W.isEmpty(n)?t:n);if(!r)throw K.createHashNotDeserializedError(JSON.stringify(r));return r},e.getDeserializedQueryString=function(t){if(W.isEmpty(t))return{};var n=e.parseQueryString(t),r=W.queryStringToObject(W.isEmpty(n)?t:n);if(!r)throw K.createHashNotDeserializedError(JSON.stringify(r));return r},e.hashContainsKnownProperties=function(t){if(W.isEmpty(t)||t.indexOf("=")<0)return!1;var n=e.getDeserializedHash(t);return!!(n.code||n.error_description||n.error||n.state)},e}();!function(e){e.AcquireTokenByCode="acquireTokenByCode",e.AcquireTokenByRefreshToken="acquireTokenByRefreshToken",e.AcquireTokenSilent="acquireTokenSilent",e.AcquireTokenSilentAsync="acquireTokenSilentAsync",e.AcquireTokenPopup="acquireTokenPopup",e.CryptoOptsGetPublicKeyThumbprint="cryptoOptsGetPublicKeyThumbprint",e.CryptoOptsSignJwt="cryptoOptsSignJwt",e.SilentCacheClientAcquireToken="silentCacheClientAcquireToken",e.SilentIframeClientAcquireToken="silentIframeClientAcquireToken",e.SilentRefreshClientAcquireToken="silentRefreshClientAcquireToken",e.SsoSilent="ssoSilent",e.StandardInteractionClientGetDiscoveredAuthority="standardInteractionClientGetDiscoveredAuthority",e.FetchAccountIdWithNativeBroker="fetchAccountIdWithNativeBroker",e.NativeInteractionClientAcquireToken="nativeInteractionClientAcquireToken",e.BaseClientCreateTokenRequestHeaders="baseClientCreateTokenRequestHeaders",e.BrokerHandhshake="brokerHandshake",e.AcquireTokenByRefreshTokenInBroker="acquireTokenByRefreshTokenInBroker",e.AcquireTokenByBroker="acquireTokenByBroker",e.RefreshTokenClientExecuteTokenRequest="refreshTokenClientExecuteTokenRequest",e.RefreshTokenClientAcquireToken="refreshTokenClientAcquireToken",e.RefreshTokenClientAcquireTokenWithCachedRefreshToken="refreshTokenClientAcquireTokenWithCachedRefreshToken",e.RefreshTokenClientAcquireTokenByRefreshToken="refreshTokenClientAcquireTokenByRefreshToken",e.RefreshTokenClientCreateTokenRequestBody="refreshTokenClientCreateTokenRequestBody",e.AcquireTokenFromCache="acquireTokenFromCache",e.AcquireTokenBySilentIframe="acquireTokenBySilentIframe",e.InitializeBaseRequest="initializeBaseRequest",e.InitializeSilentRequest="initializeSilentRequest",e.InitializeClientApplication="initializeClientApplication",e.SilentIframeClientTokenHelper="silentIframeClientTokenHelper",e.SilentHandlerInitiateAuthRequest="silentHandlerInitiateAuthRequest",e.SilentHandlerMonitorIframeForHash="silentHandlerMonitorIframeForHash",e.SilentHandlerLoadFrame="silentHandlerLoadFrame",e.StandardInteractionClientCreateAuthCodeClient="standardInteractionClientCreateAuthCodeClient",e.StandardInteractionClientGetClientConfiguration="standardInteractionClientGetClientConfiguration",e.StandardInteractionClientInitializeAuthorizationRequest="standardInteractionClientInitializeAuthorizationRequest",e.StandardInteractionClientInitializeAuthorizationCodeRequest="standardInteractionClientInitializeAuthorizationCodeRequest",e.GetAuthCodeUrl="getAuthCodeUrl",e.HandleCodeResponseFromServer="handleCodeResponseFromServer",e.HandleCodeResponseFromHash="handleCodeResponseFromHash",e.UpdateTokenEndpointAuthority="updateTokenEndpointAuthority",e.AuthClientAcquireToken="authClientAcquireToken",e.AuthClientExecuteTokenRequest="authClientExecuteTokenRequest",e.AuthClientCreateTokenRequestBody="authClientCreateTokenRequestBody",e.AuthClientCreateQueryString="authClientCreateQueryString",e.PopTokenGenerateCnf="popTokenGenerateCnf",e.PopTokenGenerateKid="popTokenGenerateKid",e.HandleServerTokenResponse="handleServerTokenResponse",e.AuthorityFactoryCreateDiscoveredInstance="authorityFactoryCreateDiscoveredInstance",e.AuthorityResolveEndpointsAsync="authorityResolveEndpointsAsync",e.AuthorityGetCloudDiscoveryMetadataFromNetwork="authorityGetCloudDiscoveryMetadataFromNetwork",e.AuthorityUpdateCloudDiscoveryMetadata="authorityUpdateCloudDiscoveryMetadata",e.AuthorityGetEndpointMetadataFromNetwork="authorityGetEndpointMetadataFromNetwork",e.AuthorityUpdateEndpointMetadata="authorityUpdateEndpointMetadata",e.AuthorityUpdateMetadataWithRegionalInformation="authorityUpdateMetadataWithRegionalInformation",e.RegionDiscoveryDetectRegion="regionDiscoveryDetectRegion",e.RegionDiscoveryGetRegionFromIMDS="regionDiscoveryGetRegionFromIMDS",e.RegionDiscoveryGetCurrentVersion="regionDiscoveryGetCurrentVersion",e.AcquireTokenByCodeAsync="acquireTokenByCodeAsync",e.GetEndpointMetadataFromNetwork="getEndpointMetadataFromNetwork",e.GetCloudDiscoveryMetadataFromNetworkMeasurement="getCloudDiscoveryMetadataFromNetworkMeasurement",e.HandleRedirectPromiseMeasurement="handleRedirectPromiseMeasurement",e.UpdateCloudDiscoveryMetadataMeasurement="updateCloudDiscoveryMetadataMeasurement",e.UsernamePasswordClientAcquireToken="usernamePasswordClientAcquireToken",e.NativeMessageHandlerHandshake="nativeMessageHandlerHandshake"}(be||(be={})),function(e){e[e.NotStarted=0]="NotStarted",e[e.InProgress=1]="InProgress",e[e.Completed=2]="Completed"}(Ee||(Ee={}));var Le,je=new Set(["accessTokenSize","durationMs","idTokenSize","matsSilentStatus","matsHttpStatus","refreshTokenSize","queuedTimeMs","startTimeMs","status"]);!function(e){e.SW="sw",e.UHW="uhw"}(Le||(Le={}));var Ue=function(){function e(e,t){this.cryptoUtils=e,this.performanceClient=t}return e.prototype.generateCnf=function(e){var t,n;return s(this,void 0,void 0,(function(){var r,o,i;return a(this,(function(s){switch(s.label){case 0:return null===(t=this.performanceClient)||void 0===t||t.addQueueMeasurement(be.PopTokenGenerateCnf,e.correlationId),null===(n=this.performanceClient)||void 0===n||n.setPreQueueTime(be.PopTokenGenerateKid,e.correlationId),[4,this.generateKid(e)];case 1:return r=s.sent(),o=this.cryptoUtils.base64Encode(JSON.stringify(r)),i={kid:r.kid,reqCnfString:o},[4,this.cryptoUtils.hashString(o)];case 2:return[2,(i.reqCnfHash=s.sent(),i)]}}))}))},e.prototype.generateKid=function(e){var t;return s(this,void 0,void 0,(function(){return a(this,(function(n){switch(n.label){case 0:return null===(t=this.performanceClient)||void 0===t||t.addQueueMeasurement(be.PopTokenGenerateKid,e.correlationId),[4,this.cryptoUtils.getPublicKeyThumbprint(e)];case 1:return[2,{kid:n.sent(),xms_ksl:Le.SW}]}}))}))},e.prototype.signPopToken=function(e,t,n){return s(this,void 0,void 0,(function(){return a(this,(function(r){return[2,this.signPayload(e,t,n)]}))}))},e.prototype.signPayload=function(e,t,n,r){return s(this,void 0,void 0,(function(){var o,s,c,u,l,p;return a(this,(function(a){switch(a.label){case 0:return o=n.resourceRequestMethod,s=n.resourceRequestUri,c=n.shrClaims,u=n.shrNonce,l=s?new Me(s):void 0,p=null==l?void 0:l.getUrlComponents(),[4,this.cryptoUtils.signJwt(i({at:e,ts:we.nowSeconds(),m:null==o?void 0:o.toUpperCase(),u:null==p?void 0:p.HostNameAndPort,nonce:u||this.cryptoUtils.createNewGuid(),p:null==p?void 0:p.AbsolutePath,q:(null==p?void 0:p.QueryString)?[[],p.QueryString]:void 0,client_claims:c||void 0},r),t,n.correlationId)];case 1:return[2,a.sent()]}}))}))},e}(),Fe=function(){function e(){}return e.prototype.generateAppMetadataKey=function(){return e.generateAppMetadataCacheKey(this.environment,this.clientId)},e.generateAppMetadataCacheKey=function(e,t){return[I,e,t].join(T.CACHE_KEY_SEPARATOR).toLowerCase()},e.createAppMetadataEntity=function(t,n,r){var o=new e;return o.clientId=t,o.environment=n,r&&(o.familyId=r),o},e.isAppMetadataEntity=function(e,t){return!!t&&0===e.indexOf(I)&&t.hasOwnProperty("clientId")&&t.hasOwnProperty("environment")},e}(),ze=function(){function e(e,t){this.cache=e,this.hasChanged=t}return Object.defineProperty(e.prototype,"cacheHasChanged",{get:function(){return this.hasChanged},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tokenCache",{get:function(){return this.cache},enumerable:!1,configurable:!0}),e}(),qe=function(){function e(e,t,n,r,o,i,s){this.clientId=e,this.cacheStorage=t,this.cryptoObj=n,this.logger=r,this.serializableCache=o,this.persistencePlugin=i,this.performanceClient=s}return e.prototype.validateServerAuthorizationCodeResponse=function(e,t,n){if(!e.state||!t)throw e.state?K.createStateNotFoundError("Cached State"):K.createStateNotFoundError("Server State");if(decodeURIComponent(e.state)!==decodeURIComponent(t))throw K.createStateMismatchError();if(e.error||e.error_description||e.suberror){if(Ne.isInteractionRequiredError(e.error,e.error_description,e.suberror))throw new Ne(e.error||f.EMPTY_STRING,e.error_description,e.suberror,e.timestamp||f.EMPTY_STRING,e.trace_id||f.EMPTY_STRING,e.correlation_id||f.EMPTY_STRING,e.claims||f.EMPTY_STRING);throw new ge(e.error||f.EMPTY_STRING,e.error_description,e.suberror)}e.client_info&&re(e.client_info,n)},e.prototype.validateTokenResponse=function(e){if(e.error||e.error_description||e.suberror){if(Ne.isInteractionRequiredError(e.error,e.error_description,e.suberror))throw new Ne(e.error,e.error_description,e.suberror,e.timestamp||f.EMPTY_STRING,e.trace_id||f.EMPTY_STRING,e.correlation_id||f.EMPTY_STRING,e.claims||f.EMPTY_STRING);var t=e.error_codes+" - ["+e.timestamp+"]: "+e.error_description+" - Correlation ID: "+e.correlation_id+" - Trace ID: "+e.trace_id;throw new ge(e.error,t,e.suberror)}},e.prototype.handleServerTokenResponse=function(t,n,r,o,i,c,u,l,p){var d;return s(this,void 0,void 0,(function(){var s,h,m,v,g,y;return a(this,(function(a){switch(a.label){case 0:if(null===(d=this.performanceClient)||void 0===d||d.addQueueMeasurement(be.HandleServerTokenResponse,t.correlation_id),t.id_token){if(s=new ae(t.id_token||f.EMPTY_STRING,this.cryptoObj),i&&!W.isEmpty(i.nonce)&&s.claims.nonce!==i.nonce)throw K.createNonceMismatchError();if(o.maxAge||0===o.maxAge){if(!(h=s.claims.auth_time))throw K.createAuthTimeNotFoundError();ae.checkMaxAge(h,o.maxAge)}}this.homeAccountIdentifier=se.generateHomeAccountId(t.client_info||f.EMPTY_STRING,n.authorityType,this.logger,this.cryptoObj,s),i&&i.state&&(m=De.parseRequestState(this.cryptoObj,i.state)),t.key_id=t.key_id||o.sshKid||void 0,v=this.generateCacheRecord(t,n,r,o,s,c,i),a.label=1;case 1:return a.trys.push([1,,5,8]),this.persistencePlugin&&this.serializableCache?(this.logger.verbose("Persistence enabled, calling beforeCacheAccess"),g=new ze(this.serializableCache,!0),[4,this.persistencePlugin.beforeCacheAccess(g)]):[3,3];case 2:a.sent(),a.label=3;case 3:return!u||l||!v.account||(y=v.account.generateAccountKey(),this.cacheStorage.getAccount(y))?[4,this.cacheStorage.saveCacheRecord(v)]:(this.logger.warning("Account used to refresh tokens not in persistence, refreshed tokens will not be stored in the cache"),[2,e.generateAuthenticationResult(this.cryptoObj,n,v,!1,o,s,m,void 0,p)]);case 4:return a.sent(),[3,8];case 5:return this.persistencePlugin&&this.serializableCache&&g?(this.logger.verbose("Persistence enabled, calling afterCacheAccess"),[4,this.persistencePlugin.afterCacheAccess(g)]):[3,7];case 6:a.sent(),a.label=7;case 7:return[7];case 8:return[2,e.generateAuthenticationResult(this.cryptoObj,n,v,!1,o,s,m,t,p)]}}))}))},e.prototype.generateCacheRecord=function(e,t,n,r,o,i,s){var a,c,u=t.getPreferredCache();if(W.isEmpty(u))throw K.createInvalidCacheEnvironmentError();!W.isEmpty(e.id_token)&&o&&(a=xe.createIdTokenEntity(this.homeAccountIdentifier,u,e.id_token||f.EMPTY_STRING,this.clientId,o.claims.tid||f.EMPTY_STRING),c=this.generateAccountEntity(e,o,t,s));var l=null;if(!W.isEmpty(e.access_token)){var p=e.scope?ne.fromString(e.scope):new ne(r.scopes||[]),d=("string"==typeof e.expires_in?parseInt(e.expires_in,10):e.expires_in)||0,h=("string"==typeof e.ext_expires_in?parseInt(e.ext_expires_in,10):e.ext_expires_in)||0,m=("string"==typeof e.refresh_in?parseInt(e.refresh_in,10):e.refresh_in)||void 0,v=n+d,g=v+h,y=m&&m>0?n+m:void 0;l=Ae.createAccessTokenEntity(this.homeAccountIdentifier,u,e.access_token||f.EMPTY_STRING,this.clientId,o?o.claims.tid||f.EMPTY_STRING:t.tenant,p.printScopes(),v,g,this.cryptoObj,y,e.token_type,i,e.key_id,r.claims,r.requestedClaimsHash)}var _=null;W.isEmpty(e.refresh_token)||(_=Ie.createRefreshTokenEntity(this.homeAccountIdentifier,u,e.refresh_token||f.EMPTY_STRING,this.clientId,e.foci,i));var b=null;return W.isEmpty(e.foci)||(b=Fe.createAppMetadataEntity(this.clientId,u,e.foci)),new ke(c,a,l,_,b)},e.prototype.generateAccountEntity=function(e,t,n,r){var o=n.authorityType,i=r?r.cloud_graph_host_name:f.EMPTY_STRING,s=r?r.msgraph_host:f.EMPTY_STRING;if(o===Z.Adfs)return this.logger.verbose("Authority type is ADFS, creating ADFS account"),se.createGenericAccount(this.homeAccountIdentifier,t,n,i,s);if(W.isEmpty(e.client_info)&&"AAD"===n.protocolMode)throw K.createClientInfoEmptyError();return e.client_info?se.createAccount(e.client_info,this.homeAccountIdentifier,t,n,i,s):se.createGenericAccount(this.homeAccountIdentifier,t,n,i,s)},e.generateAuthenticationResult=function(e,t,n,r,o,i,c,u,l){var p,d,h;return s(this,void 0,void 0,(function(){var s,m,v,g,y,_,b,E,T,S,C;return a(this,(function(a){switch(a.label){case 0:if(s=f.EMPTY_STRING,m=[],v=null,y=f.EMPTY_STRING,!n.accessToken)return[3,4];if(n.accessToken.tokenType!==O.POP)return[3,2];if(_=new Ue(e),b=n.accessToken,E=b.secret,!(T=b.keyId))throw K.createKeyIdMissingError();return[4,_.signPopToken(E,T,o)];case 1:return s=a.sent(),[3,3];case 2:s=n.accessToken.secret,a.label=3;case 3:m=ne.fromString(n.accessToken.target).asArray(),v=new Date(1e3*Number(n.accessToken.expiresOn)),g=new Date(1e3*Number(n.accessToken.extendedExpiresOn)),a.label=4;case 4:return n.appMetadata&&(y=n.appMetadata.familyId===R?R:f.EMPTY_STRING),S=(null==i?void 0:i.claims.oid)||(null==i?void 0:i.claims.sub)||f.EMPTY_STRING,C=(null==i?void 0:i.claims.tid)||f.EMPTY_STRING,(null==u?void 0:u.spa_accountid)&&n.account&&(n.account.nativeAccountId=null==u?void 0:u.spa_accountid),[2,{authority:t.canonicalAuthority,uniqueId:S,tenantId:C,scopes:m,account:n.account?n.account.getAccountInfo():null,idToken:i?i.rawToken:f.EMPTY_STRING,idTokenClaims:i?i.claims:{},accessToken:s,fromCache:r,expiresOn:v,correlationId:o.correlationId,requestId:l||f.EMPTY_STRING,extExpiresOn:g,familyId:y,tokenType:(null===(p=n.accessToken)||void 0===p?void 0:p.tokenType)||f.EMPTY_STRING,state:c?c.userRequestState:f.EMPTY_STRING,cloudGraphHostName:(null===(d=n.account)||void 0===d?void 0:d.cloudGraphHostName)||f.EMPTY_STRING,msGraphHost:(null===(h=n.account)||void 0===h?void 0:h.msGraphHost)||f.EMPTY_STRING,code:null==u?void 0:u.spa_code,fromNativeBroker:!1}]}}))}))},e}(),Be=function(e){function t(t,n){var r=e.call(this,t,n)||this;return r.includeRedirectUri=!0,r}return o(t,e),t.prototype.getAuthCodeUrl=function(e){var t,n;return s(this,void 0,void 0,(function(){var r;return a(this,(function(o){switch(o.label){case 0:return null===(t=this.performanceClient)||void 0===t||t.addQueueMeasurement(be.GetAuthCodeUrl,e.correlationId),null===(n=this.performanceClient)||void 0===n||n.setPreQueueTime(be.AuthClientCreateQueryString,e.correlationId),[4,this.createAuthCodeUrlQueryString(e)];case 1:return r=o.sent(),[2,Me.appendQueryString(this.authority.authorizationEndpoint,r)]}}))}))},t.prototype.acquireToken=function(e,t){var n,r,o,i,c,l;return s(this,void 0,void 0,(function(){var s,p,d,h,f,m,v=this;return a(this,(function(a){switch(a.label){case 0:if(!e||!e.code)throw K.createTokenRequestCannotBeMadeError();return null===(n=this.performanceClient)||void 0===n||n.addQueueMeasurement(be.AuthClientAcquireToken,e.correlationId),s=null===(r=this.performanceClient)||void 0===r?void 0:r.startMeasurement("AuthCodeClientAcquireToken",e.correlationId),this.logger.info("in acquireToken call in auth-code client"),p=we.nowSeconds(),null===(o=this.performanceClient)||void 0===o||o.setPreQueueTime(be.AuthClientExecuteTokenRequest,e.correlationId),[4,this.executeTokenRequest(this.authority,e)];case 1:return d=a.sent(),h=null===(i=d.headers)||void 0===i?void 0:i[u.X_MS_REQUEST_ID],(f=null===(c=d.headers)||void 0===c?void 0:c[u.X_MS_HTTP_VERSION])&&(null==s||s.addStaticFields({httpVerAuthority:f})),(m=new qe(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,this.config.serializableCache,this.config.persistencePlugin,this.performanceClient)).validateTokenResponse(d.body),null===(l=this.performanceClient)||void 0===l||l.setPreQueueTime(be.HandleServerTokenResponse,e.correlationId),[2,m.handleServerTokenResponse(d.body,this.authority,p,e,t,void 0,void 0,void 0,h).then((function(e){return null==s||s.endMeasurement({success:!0}),e})).catch((function(t){throw v.logger.verbose("Error in fetching token in ACC",e.correlationId),null==s||s.endMeasurement({errorCode:t.errorCode,subErrorCode:t.subError,success:!1}),t}))]}}))}))},t.prototype.handleFragmentResponse=function(e,t){var n=new qe(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,null,null),r=new Me(e),o=Me.getDeserializedHash(r.getHash());if(n.validateServerAuthorizationCodeResponse(o,t,this.cryptoUtils),!o.code)throw K.createNoAuthCodeInServerResponseError();return i(i({},o),{code:o.code})},t.prototype.getLogoutUri=function(e){if(!e)throw te.createEmptyLogoutRequestError();var t=this.createLogoutUrlQueryString(e);return Me.appendQueryString(this.authority.endSessionEndpoint,t)},t.prototype.executeTokenRequest=function(e,t){var n,r;return s(this,void 0,void 0,(function(){var o,i,s,c,u,l,p;return a(this,(function(a){switch(a.label){case 0:return null===(n=this.performanceClient)||void 0===n||n.addQueueMeasurement(be.AuthClientExecuteTokenRequest,t.correlationId),null===(r=this.performanceClient)||void 0===r||r.setPreQueueTime(be.AuthClientCreateTokenRequestBody,t.correlationId),o=this.createTokenQueryParameters(t),i=Me.appendQueryString(e.tokenEndpoint,o),[4,this.createTokenRequestBody(t)];case 1:if(s=a.sent(),c=void 0,t.clientInfo)try{u=re(t.clientInfo,this.cryptoUtils),c={credential:""+u.uid+T.CLIENT_INFO_SEPARATOR+u.utid,type:ie.HOME_ACCOUNT_ID}}catch(e){this.logger.verbose("Could not parse client info for CCS Header: "+e)}return l=this.createTokenRequestHeaders(c||t.ccsCredential),p={clientId:this.config.authOptions.clientId,authority:e.canonicalAuthority,scopes:t.scopes,claims:t.claims,authenticationScheme:t.authenticationScheme,resourceRequestMethod:t.resourceRequestMethod,resourceRequestUri:t.resourceRequestUri,shrClaims:t.shrClaims,sshKid:t.sshKid},[2,this.executePostToTokenEndpoint(i,s,l,p)]}}))}))},t.prototype.createTokenRequestBody=function(e){var t,n;return s(this,void 0,void 0,(function(){var r,o,i,s,c,u,l,p;return a(this,(function(a){switch(a.label){case 0:return null===(t=this.performanceClient)||void 0===t||t.addQueueMeasurement(be.AuthClientCreateTokenRequestBody,e.correlationId),(r=new Se).addClientId(this.config.authOptions.clientId),this.includeRedirectUri?r.addRedirectUri(e.redirectUri):Te.validateRedirectUri(e.redirectUri),r.addScopes(e.scopes),r.addAuthorizationCode(e.code),r.addLibraryInfo(this.config.libraryInfo),r.addApplicationTelemetry(this.config.telemetry.application),r.addThrottling(),this.serverTelemetryManager&&r.addServerTelemetry(this.serverTelemetryManager),e.codeVerifier&&r.addCodeVerifier(e.codeVerifier),this.config.clientCredentials.clientSecret&&r.addClientSecret(this.config.clientCredentials.clientSecret),this.config.clientCredentials.clientAssertion&&(o=this.config.clientCredentials.clientAssertion,r.addClientAssertion(o.assertion),r.addClientAssertionType(o.assertionType)),r.addGrantType(b.AUTHORIZATION_CODE_GRANT),r.addClientInfo(),e.authenticationScheme!==O.POP?[3,2]:(i=new Ue(this.cryptoUtils,this.performanceClient),null===(n=this.performanceClient)||void 0===n||n.setPreQueueTime(be.PopTokenGenerateCnf,e.correlationId),[4,i.generateCnf(e)]);case 1:return s=a.sent(),r.addPopToken(s.reqCnfString),[3,3];case 2:if(e.authenticationScheme===O.SSH){if(!e.sshJwk)throw te.createMissingSshJwkError();r.addSshJwk(e.sshJwk)}a.label=3;case 3:if(c=e.correlationId||this.config.cryptoInterface.createNewGuid(),r.addCorrelationId(c),(!W.isEmptyObj(e.claims)||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&r.addClaims(e.claims,this.config.authOptions.clientCapabilities),u=void 0,e.clientInfo)try{l=re(e.clientInfo,this.cryptoUtils),u={credential:""+l.uid+T.CLIENT_INFO_SEPARATOR+l.utid,type:ie.HOME_ACCOUNT_ID}}catch(e){this.logger.verbose("Could not parse client info for CCS Header: "+e)}else u=e.ccsCredential;if(this.config.systemOptions.preventCorsPreflight&&u)switch(u.type){case ie.HOME_ACCOUNT_ID:try{l=oe(u.credential),r.addCcsOid(l)}catch(e){this.logger.verbose("Could not parse home account ID for CCS Header: "+e)}break;case ie.UPN:r.addCcsUpn(u.credential)}return e.tokenBodyParameters&&r.addExtraQueryParameters(e.tokenBodyParameters),!e.enableSpaAuthorizationCode||e.tokenBodyParameters&&e.tokenBodyParameters[d.RETURN_SPA_CODE]||r.addExtraQueryParameters(((p={})[d.RETURN_SPA_CODE]="1",p)),[2,r.createQueryString()]}}))}))},t.prototype.createAuthCodeUrlQueryString=function(e){var t;return s(this,void 0,void 0,(function(){var n,r,o,i,s,u,l;return a(this,(function(a){switch(a.label){case 0:if(null===(t=this.performanceClient)||void 0===t||t.addQueueMeasurement(be.AuthClientCreateQueryString,e.correlationId),(n=new Se).addClientId(this.config.authOptions.clientId),r=c(e.scopes||[],e.extraScopesToConsent||[]),n.addScopes(r),n.addRedirectUri(e.redirectUri),o=e.correlationId||this.config.cryptoInterface.createNewGuid(),n.addCorrelationId(o),n.addResponseMode(e.responseMode),n.addResponseTypeCode(),n.addLibraryInfo(this.config.libraryInfo),n.addApplicationTelemetry(this.config.telemetry.application),n.addClientInfo(),e.codeChallenge&&e.codeChallengeMethod&&n.addCodeChallengeParams(e.codeChallenge,e.codeChallengeMethod),e.prompt&&n.addPrompt(e.prompt),e.domainHint&&n.addDomainHint(e.domainHint),e.prompt!==y.SELECT_ACCOUNT)if(e.sid&&e.prompt===y.NONE)this.logger.verbose("createAuthCodeUrlQueryString: Prompt is none, adding sid from request"),n.addSid(e.sid);else if(e.account){if(i=this.extractAccountSid(e.account),s=this.extractLoginHint(e.account)){this.logger.verbose("createAuthCodeUrlQueryString: login_hint claim present on account"),n.addLoginHint(s);try{u=oe(e.account.homeAccountId),n.addCcsOid(u)}catch(e){this.logger.verbose("createAuthCodeUrlQueryString: Could not parse home account ID for CCS Header")}}else if(i&&e.prompt===y.NONE){this.logger.verbose("createAuthCodeUrlQueryString: Prompt is none, adding sid from account"),n.addSid(i);try{u=oe(e.account.homeAccountId),n.addCcsOid(u)}catch(e){this.logger.verbose("createAuthCodeUrlQueryString: Could not parse home account ID for CCS Header")}}else if(e.loginHint)this.logger.verbose("createAuthCodeUrlQueryString: Adding login_hint from request"),n.addLoginHint(e.loginHint),n.addCcsUpn(e.loginHint);else if(e.account.username){this.logger.verbose("createAuthCodeUrlQueryString: Adding login_hint from account"),n.addLoginHint(e.account.username);try{u=oe(e.account.homeAccountId),n.addCcsOid(u)}catch(e){this.logger.verbose("createAuthCodeUrlQueryString: Could not parse home account ID for CCS Header")}}}else e.loginHint&&(this.logger.verbose("createAuthCodeUrlQueryString: No account, adding login_hint from request"),n.addLoginHint(e.loginHint),n.addCcsUpn(e.loginHint));else this.logger.verbose("createAuthCodeUrlQueryString: Prompt is select_account, ignoring account hints");return e.nonce&&n.addNonce(e.nonce),e.state&&n.addState(e.state),(!W.isEmpty(e.claims)||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&n.addClaims(e.claims,this.config.authOptions.clientCapabilities),e.extraQueryParameters&&n.addExtraQueryParameters(e.extraQueryParameters),e.nativeBroker?(n.addNativeBroker(),e.authenticationScheme!==O.POP?[3,2]:[4,new Ue(this.cryptoUtils).generateCnf(e)]):[3,2];case 1:l=a.sent(),n.addPopToken(l.reqCnfHash),a.label=2;case 2:return[2,n.createQueryString()]}}))}))},t.prototype.createLogoutUrlQueryString=function(e){var t=new Se;return e.postLogoutRedirectUri&&t.addPostLogoutRedirectUri(e.postLogoutRedirectUri),e.correlationId&&t.addCorrelationId(e.correlationId),e.idTokenHint&&t.addIdTokenHint(e.idTokenHint),e.state&&t.addState(e.state),e.logoutHint&&t.addLogoutHint(e.logoutHint),e.extraQueryParameters&&t.addExtraQueryParameters(e.extraQueryParameters),t.createQueryString()},t.prototype.extractAccountSid=function(e){var t;return(null===(t=e.idTokenClaims)||void 0===t?void 0:t.sid)||null},t.prototype.extractLoginHint=function(e){var t;return(null===(t=e.idTokenClaims)||void 0===t?void 0:t.login_hint)||null},t}(Ce),He=function(e){function t(t){return e.call(this,t)||this}return o(t,e),t.prototype.acquireToken=function(e){return s(this,void 0,void 0,(function(){var t,n,r,o;return a(this,(function(i){switch(i.label){case 0:return[4,this.getDeviceCode(e)];case 1:return t=i.sent(),e.deviceCodeCallback(t),n=we.nowSeconds(),[4,this.acquireTokenWithDeviceCode(e,t)];case 2:return r=i.sent(),(o=new qe(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,this.config.serializableCache,this.config.persistencePlugin)).validateTokenResponse(r),[4,o.handleServerTokenResponse(r,this.authority,n,e)];case 3:return[2,i.sent()]}}))}))},t.prototype.getDeviceCode=function(e){return s(this,void 0,void 0,(function(){var t,n,r,o,i;return a(this,(function(s){return t=this.createExtraQueryParameters(e),n=Me.appendQueryString(this.authority.deviceCodeEndpoint,t),r=this.createQueryString(e),o=this.createTokenRequestHeaders(),i={clientId:this.config.authOptions.clientId,authority:e.authority,scopes:e.scopes,claims:e.claims,authenticationScheme:e.authenticationScheme,resourceRequestMethod:e.resourceRequestMethod,resourceRequestUri:e.resourceRequestUri,shrClaims:e.shrClaims,sshKid:e.sshKid},[2,this.executePostRequestToDeviceCodeEndpoint(n,r,o,i)]}))}))},t.prototype.createExtraQueryParameters=function(e){var t=new Se;return e.extraQueryParameters&&t.addExtraQueryParameters(e.extraQueryParameters),t.createQueryString()},t.prototype.executePostRequestToDeviceCodeEndpoint=function(e,t,n,r){return s(this,void 0,void 0,(function(){var o,i,s,c,u,l,p;return a(this,(function(a){switch(a.label){case 0:return[4,this.networkManager.sendPostRequest(r,e,{body:t,headers:n})];case 1:return o=a.sent().body,i=o.user_code,s=o.device_code,c=o.verification_uri,u=o.expires_in,l=o.interval,p=o.message,[2,{userCode:i,deviceCode:s,verificationUri:c,expiresIn:u,interval:l,message:p}]}}))}))},t.prototype.createQueryString=function(e){var t=new Se;return t.addScopes(e.scopes),t.addClientId(this.config.authOptions.clientId),e.extraQueryParameters&&t.addExtraQueryParameters(e.extraQueryParameters),(!W.isEmpty(e.claims)||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&t.addClaims(e.claims,this.config.authOptions.clientCapabilities),t.createQueryString()},t.prototype.continuePolling=function(e,t,n){if(n)throw this.logger.error("Token request cancelled by setting DeviceCodeRequest.cancel = true"),K.createDeviceCodeCancelledError();if(t&&t<e&&we.nowSeconds()>t)throw this.logger.error("User defined timeout for device code polling reached. The timeout was set for "+t),K.createUserTimeoutReachedError();if(we.nowSeconds()>e)throw t&&this.logger.verbose("User specified timeout ignored as the device code has expired before the timeout elapsed. The user specified timeout was set for "+t),this.logger.error("Device code expired. Expiration time of device code was "+e),K.createDeviceCodeExpiredError();return!0},t.prototype.acquireTokenWithDeviceCode=function(e,t){return s(this,void 0,void 0,(function(){var n,r,o,i,s,c,u,l,p;return a(this,(function(a){switch(a.label){case 0:n=this.createTokenQueryParameters(e),r=Me.appendQueryString(this.authority.tokenEndpoint,n),o=this.createTokenRequestBody(e,t),i=this.createTokenRequestHeaders(),s=e.timeout?we.nowSeconds()+e.timeout:void 0,c=we.nowSeconds()+t.expiresIn,u=1e3*t.interval,a.label=1;case 1:return this.continuePolling(c,s,e.cancel)?(l={clientId:this.config.authOptions.clientId,authority:e.authority,scopes:e.scopes,claims:e.claims,authenticationScheme:e.authenticationScheme,resourceRequestMethod:e.resourceRequestMethod,resourceRequestUri:e.resourceRequestUri,shrClaims:e.shrClaims,sshKid:e.sshKid},[4,this.executePostToTokenEndpoint(r,o,i,l)]):[3,8];case 2:return(p=a.sent()).body&&p.body.error?p.body.error!==f.AUTHORIZATION_PENDING?[3,4]:(this.logger.info("Authorization pending. Continue polling."),[4,we.delay(u)]):[3,6];case 3:return a.sent(),[3,5];case 4:throw this.logger.info("Unexpected error in polling from the server"),ge.createPostRequestFailed(p.body.error);case 5:return[3,7];case 6:return this.logger.verbose("Authorization completed successfully. Polling stopped."),[2,p.body];case 7:return[3,1];case 8:throw this.logger.error("Polling stopped for unknown reasons."),K.createDeviceCodeUnknownError()}}))}))},t.prototype.createTokenRequestBody=function(e,t){var n=new Se;n.addScopes(e.scopes),n.addClientId(this.config.authOptions.clientId),n.addGrantType(b.DEVICE_CODE_GRANT),n.addDeviceCode(t.deviceCode);var r=e.correlationId||this.config.cryptoInterface.createNewGuid();return n.addCorrelationId(r),n.addClientInfo(),n.addLibraryInfo(this.config.libraryInfo),n.addApplicationTelemetry(this.config.telemetry.application),n.addThrottling(),this.serverTelemetryManager&&n.addServerTelemetry(this.serverTelemetryManager),(!W.isEmptyObj(e.claims)||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&n.addClaims(e.claims,this.config.authOptions.clientCapabilities),n.createQueryString()},t}(Ce),Ge=function(e){function t(t,n){return e.call(this,t,n)||this}return o(t,e),t.prototype.acquireToken=function(e){var t,n,r,o,i,c,l;return s(this,void 0,void 0,(function(){var s,p,d,h,f,m,v=this;return a(this,(function(a){switch(a.label){case 0:return null===(t=this.performanceClient)||void 0===t||t.addQueueMeasurement(be.RefreshTokenClientAcquireToken,e.correlationId),s=null===(n=this.performanceClient)||void 0===n?void 0:n.startMeasurement(be.RefreshTokenClientAcquireToken,e.correlationId),this.logger.verbose("RefreshTokenClientAcquireToken called",e.correlationId),p=we.nowSeconds(),null===(r=this.performanceClient)||void 0===r||r.setPreQueueTime(be.RefreshTokenClientExecuteTokenRequest,e.correlationId),[4,this.executeTokenRequest(e,this.authority)];case 1:return d=a.sent(),h=null===(o=d.headers)||void 0===o?void 0:o[u.X_MS_HTTP_VERSION],null==s||s.addStaticFields({refreshTokenSize:(null===(i=d.body.refresh_token)||void 0===i?void 0:i.length)||0}),h&&(null==s||s.addStaticFields({httpVerToken:h})),f=null===(c=d.headers)||void 0===c?void 0:c[u.X_MS_REQUEST_ID],(m=new qe(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,this.config.serializableCache,this.config.persistencePlugin)).validateTokenResponse(d.body),null===(l=this.performanceClient)||void 0===l||l.setPreQueueTime(be.HandleServerTokenResponse,e.correlationId),[2,m.handleServerTokenResponse(d.body,this.authority,p,e,void 0,void 0,!0,e.forceCache,f).then((function(e){return null==s||s.endMeasurement({success:!0}),e})).catch((function(t){throw v.logger.verbose("Error in fetching refresh token",e.correlationId),null==s||s.endMeasurement({errorCode:t.errorCode,subErrorCode:t.subError,success:!1}),t}))]}}))}))},t.prototype.acquireTokenByRefreshToken=function(e){var t,n,r,o;return s(this,void 0,void 0,(function(){var i,s;return a(this,(function(a){if(!e)throw te.createEmptyTokenRequestError();if(null===(t=this.performanceClient)||void 0===t||t.addQueueMeasurement(be.RefreshTokenClientAcquireTokenByRefreshToken,e.correlationId),!e.account)throw K.createNoAccountInSilentRequestError();if(this.cacheManager.isAppMetadataFOCI(e.account.environment,this.config.authOptions.clientId))try{return null===(n=this.performanceClient)||void 0===n||n.setPreQueueTime(be.RefreshTokenClientAcquireTokenWithCachedRefreshToken,e.correlationId),[2,this.acquireTokenWithCachedRefreshToken(e,!0)]}catch(t){if(i=t instanceof Ne&&t.errorCode===Oe.noTokensFoundError.code,s=t instanceof ge&&t.errorCode===z.INVALID_GRANT_ERROR&&t.subError===z.CLIENT_MISMATCH_ERROR,i||s)return null===(r=this.performanceClient)||void 0===r||r.setPreQueueTime(be.RefreshTokenClientAcquireTokenWithCachedRefreshToken,e.correlationId),[2,this.acquireTokenWithCachedRefreshToken(e,!1)];throw t}return null===(o=this.performanceClient)||void 0===o||o.setPreQueueTime(be.RefreshTokenClientAcquireTokenWithCachedRefreshToken,e.correlationId),[2,this.acquireTokenWithCachedRefreshToken(e,!1)]}))}))},t.prototype.acquireTokenWithCachedRefreshToken=function(e,t){var n,r,o;return s(this,void 0,void 0,(function(){var s,c,u;return a(this,(function(a){if(null===(n=this.performanceClient)||void 0===n||n.addQueueMeasurement(be.RefreshTokenClientAcquireTokenWithCachedRefreshToken,e.correlationId),s=null===(r=this.performanceClient)||void 0===r?void 0:r.startMeasurement(be.RefreshTokenClientAcquireTokenWithCachedRefreshToken,e.correlationId),this.logger.verbose("RefreshTokenClientAcquireTokenWithCachedRefreshToken called",e.correlationId),!(c=this.cacheManager.readRefreshTokenFromCache(this.config.authOptions.clientId,e.account,t)))throw null==s||s.discardMeasurement(),Ne.createNoTokensFoundError();return null==s||s.endMeasurement({success:!0}),u=i(i({},e),{refreshToken:c.secret,authenticationScheme:e.authenticationScheme||O.BEARER,ccsCredential:{credential:e.account.homeAccountId,type:ie.HOME_ACCOUNT_ID}}),null===(o=this.performanceClient)||void 0===o||o.setPreQueueTime(be.RefreshTokenClientAcquireToken,e.correlationId),[2,this.acquireToken(u)]}))}))},t.prototype.executeTokenRequest=function(e,t){var n,r,o;return s(this,void 0,void 0,(function(){var i,s,c,u,l,p;return a(this,(function(a){switch(a.label){case 0:return null===(n=this.performanceClient)||void 0===n||n.addQueueMeasurement(be.RefreshTokenClientExecuteTokenRequest,e.correlationId),i=null===(r=this.performanceClient)||void 0===r?void 0:r.startMeasurement(be.RefreshTokenClientExecuteTokenRequest,e.correlationId),null===(o=this.performanceClient)||void 0===o||o.setPreQueueTime(be.RefreshTokenClientCreateTokenRequestBody,e.correlationId),s=this.createTokenQueryParameters(e),c=Me.appendQueryString(t.tokenEndpoint,s),[4,this.createTokenRequestBody(e)];case 1:return u=a.sent(),l=this.createTokenRequestHeaders(e.ccsCredential),p={clientId:this.config.authOptions.clientId,authority:t.canonicalAuthority,scopes:e.scopes,claims:e.claims,authenticationScheme:e.authenticationScheme,resourceRequestMethod:e.resourceRequestMethod,resourceRequestUri:e.resourceRequestUri,shrClaims:e.shrClaims,sshKid:e.sshKid},[2,this.executePostToTokenEndpoint(c,u,l,p).then((function(e){return null==i||i.endMeasurement({success:!0}),e})).catch((function(e){throw null==i||i.endMeasurement({success:!1}),e}))]}}))}))},t.prototype.createTokenRequestBody=function(e){var t,n,r;return s(this,void 0,void 0,(function(){var o,i,s,c,u,l,p;return a(this,(function(a){switch(a.label){case 0:return null===(t=this.performanceClient)||void 0===t||t.addQueueMeasurement(be.RefreshTokenClientCreateTokenRequestBody,e.correlationId),o=e.correlationId,i=null===(n=this.performanceClient)||void 0===n?void 0:n.startMeasurement(be.BaseClientCreateTokenRequestHeaders,o),(s=new Se).addClientId(this.config.authOptions.clientId),s.addScopes(e.scopes),s.addGrantType(b.REFRESH_TOKEN_GRANT),s.addClientInfo(),s.addLibraryInfo(this.config.libraryInfo),s.addApplicationTelemetry(this.config.telemetry.application),s.addThrottling(),this.serverTelemetryManager&&s.addServerTelemetry(this.serverTelemetryManager),s.addCorrelationId(o),s.addRefreshToken(e.refreshToken),this.config.clientCredentials.clientSecret&&s.addClientSecret(this.config.clientCredentials.clientSecret),this.config.clientCredentials.clientAssertion&&(c=this.config.clientCredentials.clientAssertion,s.addClientAssertion(c.assertion),s.addClientAssertionType(c.assertionType)),e.authenticationScheme!==O.POP?[3,2]:(u=new Ue(this.cryptoUtils,this.performanceClient),null===(r=this.performanceClient)||void 0===r||r.setPreQueueTime(be.PopTokenGenerateCnf,e.correlationId),[4,u.generateCnf(e)]);case 1:return l=a.sent(),s.addPopToken(l.reqCnfString),[3,3];case 2:if(e.authenticationScheme===O.SSH){if(!e.sshJwk)throw null==i||i.endMeasurement({success:!1}),te.createMissingSshJwkError();s.addSshJwk(e.sshJwk)}a.label=3;case 3:if((!W.isEmptyObj(e.claims)||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&s.addClaims(e.claims,this.config.authOptions.clientCapabilities),this.config.systemOptions.preventCorsPreflight&&e.ccsCredential)switch(e.ccsCredential.type){case ie.HOME_ACCOUNT_ID:try{p=oe(e.ccsCredential.credential),s.addCcsOid(p)}catch(e){this.logger.verbose("Could not parse home account ID for CCS Header: "+e)}break;case ie.UPN:s.addCcsUpn(e.ccsCredential.credential)}return null==i||i.endMeasurement({success:!0}),[2,s.createQueryString()]}}))}))},t}(Ce),Ve=function(e){function t(t,n){var r=e.call(this,t)||this;return r.appTokenProvider=n,r}return o(t,e),t.prototype.acquireToken=function(e){return s(this,void 0,void 0,(function(){var t;return a(this,(function(n){switch(n.label){case 0:return this.scopeSet=new ne(e.scopes||[]),e.skipCache?[4,this.executeTokenRequest(e,this.authority)]:[3,2];case 1:case 5:return[2,n.sent()];case 2:return[4,this.getCachedAuthenticationResult(e)];case 3:return(t=n.sent())?[2,t]:[3,4];case 4:return[4,this.executeTokenRequest(e,this.authority)]}}))}))},t.prototype.getCachedAuthenticationResult=function(e){var t,n;return s(this,void 0,void 0,(function(){var r;return a(this,(function(o){switch(o.label){case 0:return(r=this.readAccessTokenFromCache())?we.isTokenExpired(r.expiresOn,this.config.systemOptions.tokenRenewalOffsetSeconds)?(null===(n=this.serverTelemetryManager)||void 0===n||n.setCacheOutcome(j.CACHED_ACCESS_TOKEN_EXPIRED),[2,null]):[4,qe.generateAuthenticationResult(this.cryptoUtils,this.authority,{account:null,idToken:null,accessToken:r,refreshToken:null,appMetadata:null},!0,e)]:(null===(t=this.serverTelemetryManager)||void 0===t||t.setCacheOutcome(j.NO_CACHED_ACCESS_TOKEN),[2,null]);case 1:return[2,o.sent()]}}))}))},t.prototype.readAccessTokenFromCache=function(){var e={homeAccountId:f.EMPTY_STRING,environment:this.authority.canonicalAuthorityUrlComponents.HostNameAndPort,credentialType:S.ACCESS_TOKEN,clientId:this.config.authOptions.clientId,realm:this.authority.tenant,target:this.scopeSet.printScopesLowerCase()},t=this.cacheManager.getCredentialsFilteredBy(e),n=Object.keys(t.accessTokens).map((function(e){return t.accessTokens[e]}));if(n.length<1)return null;if(n.length>1)throw K.createMultipleMatchingTokensInCacheError();return n[0]},t.prototype.executeTokenRequest=function(e,t){return s(this,void 0,void 0,(function(){var n,r,o,i,s,c,u,l,p,d,h;return a(this,(function(a){switch(a.label){case 0:return this.appTokenProvider?(this.logger.info("Using appTokenProvider extensibility."),o={correlationId:e.correlationId,tenantId:this.config.authOptions.authority.tenant,scopes:e.scopes,claims:e.claims},r=we.nowSeconds(),[4,this.appTokenProvider(o)]):[3,2];case 1:return i=a.sent(),n={access_token:i.accessToken,expires_in:i.expiresInSeconds,refresh_in:i.refreshInSeconds,token_type:O.BEARER},[3,4];case 2:return s=this.createTokenQueryParameters(e),c=Me.appendQueryString(t.tokenEndpoint,s),u=this.createTokenRequestBody(e),l=this.createTokenRequestHeaders(),p={clientId:this.config.authOptions.clientId,authority:e.authority,scopes:e.scopes,claims:e.claims,authenticationScheme:e.authenticationScheme,resourceRequestMethod:e.resourceRequestMethod,resourceRequestUri:e.resourceRequestUri,shrClaims:e.shrClaims,sshKid:e.sshKid},r=we.nowSeconds(),[4,this.executePostToTokenEndpoint(c,u,l,p)];case 3:d=a.sent(),n=d.body,a.label=4;case 4:return(h=new qe(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,this.config.serializableCache,this.config.persistencePlugin)).validateTokenResponse(n),[4,h.handleServerTokenResponse(n,this.authority,r,e)];case 5:return[2,a.sent()]}}))}))},t.prototype.createTokenRequestBody=function(e){var t=new Se;t.addClientId(this.config.authOptions.clientId),t.addScopes(e.scopes,!1),t.addGrantType(b.CLIENT_CREDENTIALS_GRANT),t.addLibraryInfo(this.config.libraryInfo),t.addApplicationTelemetry(this.config.telemetry.application),t.addThrottling(),this.serverTelemetryManager&&t.addServerTelemetry(this.serverTelemetryManager);var n=e.correlationId||this.config.cryptoInterface.createNewGuid();t.addCorrelationId(n),this.config.clientCredentials.clientSecret&&t.addClientSecret(this.config.clientCredentials.clientSecret);var r=e.clientAssertion||this.config.clientCredentials.clientAssertion;return r&&(t.addClientAssertion(r.assertion),t.addClientAssertionType(r.assertionType)),(!W.isEmptyObj(e.claims)||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&t.addClaims(e.claims,this.config.authOptions.clientCapabilities),t.createQueryString()},t}(Ce),$e=function(e){function t(t){return e.call(this,t)||this}return o(t,e),t.prototype.acquireToken=function(e){return s(this,void 0,void 0,(function(){var t;return a(this,(function(n){switch(n.label){case 0:return this.scopeSet=new ne(e.scopes||[]),t=this,[4,this.cryptoUtils.hashString(e.oboAssertion)];case 1:return t.userAssertionHash=n.sent(),e.skipCache?[4,this.executeTokenRequest(e,this.authority,this.userAssertionHash)]:[3,3];case 2:case 4:case 6:return[2,n.sent()];case 3:return n.trys.push([3,5,,7]),[4,this.getCachedAuthenticationResult(e)];case 5:return n.sent(),[4,this.executeTokenRequest(e,this.authority,this.userAssertionHash)];case 7:return[2]}}))}))},t.prototype.getCachedAuthenticationResult=function(e){var t,n;return s(this,void 0,void 0,(function(){var r,o,i,s,c,u;return a(this,(function(a){switch(a.label){case 0:if(!(r=this.readAccessTokenFromCacheForOBO(this.config.authOptions.clientId,e)))throw null===(t=this.serverTelemetryManager)||void 0===t||t.setCacheOutcome(j.NO_CACHED_ACCESS_TOKEN),this.logger.info("SilentFlowClient:acquireCachedToken - No access token found in cache for the given properties."),K.createRefreshRequiredError();if(we.isTokenExpired(r.expiresOn,this.config.systemOptions.tokenRenewalOffsetSeconds))throw null===(n=this.serverTelemetryManager)||void 0===n||n.setCacheOutcome(j.CACHED_ACCESS_TOKEN_EXPIRED),this.logger.info("OnbehalfofFlow:getCachedAuthenticationResult - Cached access token is expired or will expire within "+this.config.systemOptions.tokenRenewalOffsetSeconds+" seconds."),K.createRefreshRequiredError();return o=this.readIdTokenFromCacheForOBO(e,r.homeAccountId),s=null,o&&(i=new ae(o.secret,this.config.cryptoInterface),c=i.claims.oid?i.claims.oid:i.claims.sub,u={homeAccountId:o.homeAccountId,environment:o.environment,tenantId:o.realm,username:f.EMPTY_STRING,localAccountId:c||f.EMPTY_STRING},s=this.cacheManager.readAccountFromCache(u)),this.config.serverTelemetryManager&&this.config.serverTelemetryManager.incrementCacheHits(),[4,qe.generateAuthenticationResult(this.cryptoUtils,this.authority,{account:s,accessToken:r,idToken:o,refreshToken:null,appMetadata:null},!0,e,i)];case 1:return[2,a.sent()]}}))}))},t.prototype.readIdTokenFromCacheForOBO=function(e,t){var n={homeAccountId:t,environment:this.authority.canonicalAuthorityUrlComponents.HostNameAndPort,credentialType:S.ID_TOKEN,clientId:this.config.authOptions.clientId,realm:this.authority.tenant},r=this.cacheManager.getCredentialsFilteredBy(n),o=Object.keys(r.idTokens).map((function(e){return r.idTokens[e]}));return o.length<1?null:o[0]},t.prototype.readAccessTokenFromCacheForOBO=function(e,t){var n=t.authenticationScheme||O.BEARER,r={credentialType:n&&n.toLowerCase()!==O.BEARER.toLowerCase()?S.ACCESS_TOKEN_WITH_AUTH_SCHEME:S.ACCESS_TOKEN,clientId:e,target:this.scopeSet.printScopesLowerCase(),tokenType:n,keyId:t.sshKid,requestedClaimsHash:t.requestedClaimsHash,userAssertionHash:this.userAssertionHash},o=this.cacheManager.getCredentialsFilteredBy(r),i=Object.keys(o.accessTokens).map((function(e){return o.accessTokens[e]})),s=i.length;if(s<1)return null;if(s>1)throw K.createMultipleMatchingTokensInCacheError();return i[0]},t.prototype.executeTokenRequest=function(e,t,n){return s(this,void 0,void 0,(function(){var r,o,i,s,c,u,l,p;return a(this,(function(a){switch(a.label){case 0:return r=this.createTokenQueryParameters(e),o=Me.appendQueryString(t.tokenEndpoint,r),i=this.createTokenRequestBody(e),s=this.createTokenRequestHeaders(),c={clientId:this.config.authOptions.clientId,authority:e.authority,scopes:e.scopes,claims:e.claims,authenticationScheme:e.authenticationScheme,resourceRequestMethod:e.resourceRequestMethod,resourceRequestUri:e.resourceRequestUri,shrClaims:e.shrClaims,sshKid:e.sshKid},u=we.nowSeconds(),[4,this.executePostToTokenEndpoint(o,i,s,c)];case 1:return l=a.sent(),(p=new qe(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,this.config.serializableCache,this.config.persistencePlugin)).validateTokenResponse(l.body),[4,p.handleServerTokenResponse(l.body,this.authority,u,e,void 0,n)];case 2:return[2,a.sent()]}}))}))},t.prototype.createTokenRequestBody=function(e){var t=new Se;t.addClientId(this.config.authOptions.clientId),t.addScopes(e.scopes),t.addGrantType(b.JWT_BEARER),t.addClientInfo(),t.addLibraryInfo(this.config.libraryInfo),t.addApplicationTelemetry(this.config.telemetry.application),t.addThrottling(),this.serverTelemetryManager&&t.addServerTelemetry(this.serverTelemetryManager);var n=e.correlationId||this.config.cryptoInterface.createNewGuid();if(t.addCorrelationId(n),t.addRequestTokenUse(d.ON_BEHALF_OF),t.addOboAssertion(e.oboAssertion),this.config.clientCredentials.clientSecret&&t.addClientSecret(this.config.clientCredentials.clientSecret),this.config.clientCredentials.clientAssertion){var r=this.config.clientCredentials.clientAssertion;t.addClientAssertion(r.assertion),t.addClientAssertionType(r.assertionType)}return(e.claims||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&t.addClaims(e.claims,this.config.authOptions.clientCapabilities),t.createQueryString()},t}(Ce),Ke=function(e){function t(t,n){return e.call(this,t,n)||this}return o(t,e),t.prototype.acquireToken=function(e){return s(this,void 0,void 0,(function(){var t;return a(this,(function(n){switch(n.label){case 0:return n.trys.push([0,2,,3]),[4,this.acquireCachedToken(e)];case 1:return[2,n.sent()];case 2:if((t=n.sent())instanceof K&&t.errorCode===$.tokenRefreshRequired.code)return[2,new Ge(this.config,this.performanceClient).acquireTokenByRefreshToken(e)];throw t;case 3:return[2]}}))}))},t.prototype.acquireCachedToken=function(e){var t,n,r,o;return s(this,void 0,void 0,(function(){var i,s;return a(this,(function(a){switch(a.label){case 0:if(!e)throw te.createEmptyTokenRequestError();if(e.forceRefresh)throw null===(t=this.serverTelemetryManager)||void 0===t||t.setCacheOutcome(j.FORCE_REFRESH),this.logger.info("SilentFlowClient:acquireCachedToken - Skipping cache because forceRefresh is true."),K.createRefreshRequiredError();if(!e.account)throw K.createNoAccountInSilentRequestError();if(i=e.authority||this.authority.getPreferredCache(),!(s=this.cacheManager.readCacheRecord(e.account,this.config.authOptions.clientId,e,i)).accessToken)throw null===(n=this.serverTelemetryManager)||void 0===n||n.setCacheOutcome(j.NO_CACHED_ACCESS_TOKEN),this.logger.info("SilentFlowClient:acquireCachedToken - No access token found in cache for the given properties."),K.createRefreshRequiredError();if(we.wasClockTurnedBack(s.accessToken.cachedAt)||we.isTokenExpired(s.accessToken.expiresOn,this.config.systemOptions.tokenRenewalOffsetSeconds))throw null===(r=this.serverTelemetryManager)||void 0===r||r.setCacheOutcome(j.CACHED_ACCESS_TOKEN_EXPIRED),this.logger.info("SilentFlowClient:acquireCachedToken - Cached access token is expired or will expire within "+this.config.systemOptions.tokenRenewalOffsetSeconds+" seconds."),K.createRefreshRequiredError();if(s.accessToken.refreshOn&&we.isTokenExpired(s.accessToken.refreshOn,0))throw null===(o=this.serverTelemetryManager)||void 0===o||o.setCacheOutcome(j.REFRESH_CACHED_ACCESS_TOKEN),this.logger.info("SilentFlowClient:acquireCachedToken - Cached access token's refreshOn property has been exceeded'."),K.createRefreshRequiredError();return this.config.serverTelemetryManager&&this.config.serverTelemetryManager.incrementCacheHits(),[4,this.generateResultFromCacheRecord(s,e)];case 1:return[2,a.sent()]}}))}))},t.prototype.generateResultFromCacheRecord=function(e,t){return s(this,void 0,void 0,(function(){var n,r;return a(this,(function(o){switch(o.label){case 0:if(e.idToken&&(n=new ae(e.idToken.secret,this.config.cryptoInterface)),t.maxAge||0===t.maxAge){if(!(r=null==n?void 0:n.claims.auth_time))throw K.createAuthTimeNotFoundError();ae.checkMaxAge(r,t.maxAge)}return[4,qe.generateAuthenticationResult(this.cryptoUtils,this.authority,e,!0,t,n)];case 1:return[2,o.sent()]}}))}))},t}(Ce),We=function(e){function t(t){return e.call(this,t)||this}return o(t,e),t.prototype.acquireToken=function(e){var t,n;return s(this,void 0,void 0,(function(){var r,o,i,s,c;return a(this,(function(a){switch(a.label){case 0:return r=null===(t=this.performanceClient)||void 0===t?void 0:t.startMeasurement("UsernamePasswordClientAcquireToken",e.correlationId),this.logger.info("in acquireToken call in username-password client"),o=we.nowSeconds(),[4,this.executeTokenRequest(this.authority,e)];case 1:return i=a.sent(),s=null===(n=i.headers)||void 0===n?void 0:n[u.X_MS_HTTP_VERSION],null==r||r.addStaticFields({httpVerToken:s}),(c=new qe(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,this.config.serializableCache,this.config.persistencePlugin)).validateTokenResponse(i.body),[2,c.handleServerTokenResponse(i.body,this.authority,o,e)]}}))}))},t.prototype.executeTokenRequest=function(e,t){return s(this,void 0,void 0,(function(){var n,r,o,i,s;return a(this,(function(a){return n=this.createTokenQueryParameters(t),r=Me.appendQueryString(e.tokenEndpoint,n),o=this.createTokenRequestBody(t),i=this.createTokenRequestHeaders({credential:t.username,type:ie.UPN}),s={clientId:this.config.authOptions.clientId,authority:e.canonicalAuthority,scopes:t.scopes,claims:t.claims,authenticationScheme:t.authenticationScheme,resourceRequestMethod:t.resourceRequestMethod,resourceRequestUri:t.resourceRequestUri,shrClaims:t.shrClaims,sshKid:t.sshKid},[2,this.executePostToTokenEndpoint(r,o,i,s)]}))}))},t.prototype.createTokenRequestBody=function(e){var t=new Se;t.addClientId(this.config.authOptions.clientId),t.addUsername(e.username),t.addPassword(e.password),t.addScopes(e.scopes),t.addResponseTypeForTokenAndIdToken(),t.addGrantType(b.RESOURCE_OWNER_PASSWORD_GRANT),t.addClientInfo(),t.addLibraryInfo(this.config.libraryInfo),t.addApplicationTelemetry(this.config.telemetry.application),t.addThrottling(),this.serverTelemetryManager&&t.addServerTelemetry(this.serverTelemetryManager);var n=e.correlationId||this.config.cryptoInterface.createNewGuid();if(t.addCorrelationId(n),this.config.clientCredentials.clientSecret&&t.addClientSecret(this.config.clientCredentials.clientSecret),this.config.clientCredentials.clientAssertion){var r=this.config.clientCredentials.clientAssertion;t.addClientAssertion(r.assertion),t.addClientAssertionType(r.assertionType)}return(!W.isEmptyObj(e.claims)||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&t.addClaims(e.claims,this.config.authOptions.clientCapabilities),this.config.systemOptions.preventCorsPreflight&&e.username&&t.addCcsUpn(e.username),t.createQueryString()},t}(Ce);function Qe(e){return e.hasOwnProperty("authorization_endpoint")&&e.hasOwnProperty("token_endpoint")&&e.hasOwnProperty("issuer")&&e.hasOwnProperty("jwks_uri")}var Ye,Xe={"https://login.microsoftonline.com/common/":{token_endpoint:"https://login.microsoftonline.com/common/oauth2/v2.0/token",token_endpoint_auth_methods_supported:["client_secret_post","private_key_jwt","client_secret_basic"],jwks_uri:"https://login.microsoftonline.com/common/discovery/v2.0/keys",response_modes_supported:["query","fragment","form_post"],subject_types_supported:["pairwise"],id_token_signing_alg_values_supported:["RS256"],response_types_supported:["code","id_token","code id_token","id_token token"],scopes_supported:["openid","profile","email","offline_access"],issuer:"https://login.microsoftonline.com/{tenantid}/v2.0",request_uri_parameter_supported:!1,userinfo_endpoint:"https://graph.microsoft.com/oidc/userinfo",authorization_endpoint:"https://login.microsoftonline.com/common/oauth2/v2.0/authorize",device_authorization_endpoint:"https://login.microsoftonline.com/common/oauth2/v2.0/devicecode",http_logout_supported:!0,frontchannel_logout_supported:!0,end_session_endpoint:"https://login.microsoftonline.com/common/oauth2/v2.0/logout",claims_supported:["sub","iss","cloud_instance_name","cloud_instance_host_name","cloud_graph_host_name","msgraph_host","aud","exp","iat","auth_time","acr","nonce","preferred_username","name","tid","ver","at_hash","c_hash","email"],kerberos_endpoint:"https://login.microsoftonline.com/common/kerberos",tenant_region_scope:null,cloud_instance_name:"microsoftonline.com",cloud_graph_host_name:"graph.windows.net",msgraph_host:"graph.microsoft.com",rbac_url:"https://pas.windows.net"},"https://login.chinacloudapi.cn/common/":{token_endpoint:"https://login.chinacloudapi.cn/common/oauth2/v2.0/token",token_endpoint_auth_methods_supported:["client_secret_post","private_key_jwt","client_secret_basic"],jwks_uri:"https://login.chinacloudapi.cn/common/discovery/v2.0/keys",response_modes_supported:["query","fragment","form_post"],subject_types_supported:["pairwise"],id_token_signing_alg_values_supported:["RS256"],response_types_supported:["code","id_token","code id_token","id_token token"],scopes_supported:["openid","profile","email","offline_access"],issuer:"https://login.partner.microsoftonline.cn/{tenantid}/v2.0",request_uri_parameter_supported:!1,userinfo_endpoint:"https://microsoftgraph.chinacloudapi.cn/oidc/userinfo",authorization_endpoint:"https://login.chinacloudapi.cn/common/oauth2/v2.0/authorize",device_authorization_endpoint:"https://login.chinacloudapi.cn/common/oauth2/v2.0/devicecode",http_logout_supported:!0,frontchannel_logout_supported:!0,end_session_endpoint:"https://login.chinacloudapi.cn/common/oauth2/v2.0/logout",claims_supported:["sub","iss","cloud_instance_name","cloud_instance_host_name","cloud_graph_host_name","msgraph_host","aud","exp","iat","auth_time","acr","nonce","preferred_username","name","tid","ver","at_hash","c_hash","email"],kerberos_endpoint:"https://login.chinacloudapi.cn/common/kerberos",tenant_region_scope:null,cloud_instance_name:"partner.microsoftonline.cn",cloud_graph_host_name:"graph.chinacloudapi.cn",msgraph_host:"microsoftgraph.chinacloudapi.cn",rbac_url:"https://pas.chinacloudapi.cn"},"https://login.microsoftonline.us/common/":{token_endpoint:"https://login.microsoftonline.us/common/oauth2/v2.0/token",token_endpoint_auth_methods_supported:["client_secret_post","private_key_jwt","client_secret_basic"],jwks_uri:"https://login.microsoftonline.us/common/discovery/v2.0/keys",response_modes_supported:["query","fragment","form_post"],subject_types_supported:["pairwise"],id_token_signing_alg_values_supported:["RS256"],response_types_supported:["code","id_token","code id_token","id_token token"],scopes_supported:["openid","profile","email","offline_access"],issuer:"https://login.microsoftonline.us/{tenantid}/v2.0",request_uri_parameter_supported:!1,userinfo_endpoint:"https://graph.microsoft.com/oidc/userinfo",authorization_endpoint:"https://login.microsoftonline.us/common/oauth2/v2.0/authorize",device_authorization_endpoint:"https://login.microsoftonline.us/common/oauth2/v2.0/devicecode",http_logout_supported:!0,frontchannel_logout_supported:!0,end_session_endpoint:"https://login.microsoftonline.us/common/oauth2/v2.0/logout",claims_supported:["sub","iss","cloud_instance_name","cloud_instance_host_name","cloud_graph_host_name","msgraph_host","aud","exp","iat","auth_time","acr","nonce","preferred_username","name","tid","ver","at_hash","c_hash","email"],kerberos_endpoint:"https://login.microsoftonline.us/common/kerberos",tenant_region_scope:null,cloud_instance_name:"microsoftonline.us",cloud_graph_host_name:"graph.windows.net",msgraph_host:"graph.microsoft.com",rbac_url:"https://pasff.usgovcloudapi.net"},"https://login.microsoftonline.com/consumers/":{token_endpoint:"https://login.microsoftonline.com/consumers/oauth2/v2.0/token",token_endpoint_auth_methods_supported:["client_secret_post","private_key_jwt","client_secret_basic"],jwks_uri:"https://login.microsoftonline.com/consumers/discovery/v2.0/keys",response_modes_supported:["query","fragment","form_post"],subject_types_supported:["pairwise"],id_token_signing_alg_values_supported:["RS256"],response_types_supported:["code","id_token","code id_token","id_token token"],scopes_supported:["openid","profile","email","offline_access"],issuer:"https://login.microsoftonline.com/9188040d-6c67-4c5b-b112-36a304b66dad/v2.0",request_uri_parameter_supported:!1,userinfo_endpoint:"https://graph.microsoft.com/oidc/userinfo",authorization_endpoint:"https://login.microsoftonline.com/consumers/oauth2/v2.0/authorize",device_authorization_endpoint:"https://login.microsoftonline.com/consumers/oauth2/v2.0/devicecode",http_logout_supported:!0,frontchannel_logout_supported:!0,end_session_endpoint:"https://login.microsoftonline.com/consumers/oauth2/v2.0/logout",claims_supported:["sub","iss","cloud_instance_name","cloud_instance_host_name","cloud_graph_host_name","msgraph_host","aud","exp","iat","auth_time","acr","nonce","preferred_username","name","tid","ver","at_hash","c_hash","email"],kerberos_endpoint:"https://login.microsoftonline.com/consumers/kerberos",tenant_region_scope:null,cloud_instance_name:"microsoftonline.com",cloud_graph_host_name:"graph.windows.net",msgraph_host:"graph.microsoft.com",rbac_url:"https://pas.windows.net"},"https://login.chinacloudapi.cn/consumers/":{token_endpoint:"https://login.chinacloudapi.cn/consumers/oauth2/v2.0/token",token_endpoint_auth_methods_supported:["client_secret_post","private_key_jwt","client_secret_basic"],jwks_uri:"https://login.chinacloudapi.cn/consumers/discovery/v2.0/keys",response_modes_supported:["query","fragment","form_post"],subject_types_supported:["pairwise"],id_token_signing_alg_values_supported:["RS256"],response_types_supported:["code","id_token","code id_token","id_token token"],scopes_supported:["openid","profile","email","offline_access"],issuer:"https://login.partner.microsoftonline.cn/9188040d-6c67-4c5b-b112-36a304b66dad/v2.0",request_uri_parameter_supported:!1,userinfo_endpoint:"https://microsoftgraph.chinacloudapi.cn/oidc/userinfo",authorization_endpoint:"https://login.chinacloudapi.cn/consumers/oauth2/v2.0/authorize",device_authorization_endpoint:"https://login.chinacloudapi.cn/consumers/oauth2/v2.0/devicecode",http_logout_supported:!0,frontchannel_logout_supported:!0,end_session_endpoint:"https://login.chinacloudapi.cn/consumers/oauth2/v2.0/logout",claims_supported:["sub","iss","cloud_instance_name","cloud_instance_host_name","cloud_graph_host_name","msgraph_host","aud","exp","iat","auth_time","acr","nonce","preferred_username","name","tid","ver","at_hash","c_hash","email"],kerberos_endpoint:"https://login.chinacloudapi.cn/consumers/kerberos",tenant_region_scope:null,cloud_instance_name:"partner.microsoftonline.cn",cloud_graph_host_name:"graph.chinacloudapi.cn",msgraph_host:"microsoftgraph.chinacloudapi.cn",rbac_url:"https://pas.chinacloudapi.cn"},"https://login.microsoftonline.us/consumers/":{token_endpoint:"https://login.microsoftonline.us/consumers/oauth2/v2.0/token",token_endpoint_auth_methods_supported:["client_secret_post","private_key_jwt","client_secret_basic"],jwks_uri:"https://login.microsoftonline.us/consumers/discovery/v2.0/keys",response_modes_supported:["query","fragment","form_post"],subject_types_supported:["pairwise"],id_token_signing_alg_values_supported:["RS256"],response_types_supported:["code","id_token","code id_token","id_token token"],scopes_supported:["openid","profile","email","offline_access"],issuer:"https://login.microsoftonline.us/9188040d-6c67-4c5b-b112-36a304b66dad/v2.0",request_uri_parameter_supported:!1,userinfo_endpoint:"https://graph.microsoft.com/oidc/userinfo",authorization_endpoint:"https://login.microsoftonline.us/consumers/oauth2/v2.0/authorize",device_authorization_endpoint:"https://login.microsoftonline.us/consumers/oauth2/v2.0/devicecode",http_logout_supported:!0,frontchannel_logout_supported:!0,end_session_endpoint:"https://login.microsoftonline.us/consumers/oauth2/v2.0/logout",claims_supported:["sub","iss","cloud_instance_name","cloud_instance_host_name","cloud_graph_host_name","msgraph_host","aud","exp","iat","auth_time","acr","nonce","preferred_username","name","tid","ver","at_hash","c_hash","email"],kerberos_endpoint:"https://login.microsoftonline.us/consumers/kerberos",tenant_region_scope:null,cloud_instance_name:"microsoftonline.us",cloud_graph_host_name:"graph.windows.net",msgraph_host:"graph.microsoft.com",rbac_url:"https://pasff.usgovcloudapi.net"},"https://login.microsoftonline.com/organizations/":{token_endpoint:"https://login.microsoftonline.com/organizations/oauth2/v2.0/token",token_endpoint_auth_methods_supported:["client_secret_post","private_key_jwt","client_secret_basic"],jwks_uri:"https://login.microsoftonline.com/organizations/discovery/v2.0/keys",response_modes_supported:["query","fragment","form_post"],subject_types_supported:["pairwise"],id_token_signing_alg_values_supported:["RS256"],response_types_supported:["code","id_token","code id_token","id_token token"],scopes_supported:["openid","profile","email","offline_access"],issuer:"https://login.microsoftonline.com/{tenantid}/v2.0",request_uri_parameter_supported:!1,userinfo_endpoint:"https://graph.microsoft.com/oidc/userinfo",authorization_endpoint:"https://login.microsoftonline.com/organizations/oauth2/v2.0/authorize",device_authorization_endpoint:"https://login.microsoftonline.com/organizations/oauth2/v2.0/devicecode",http_logout_supported:!0,frontchannel_logout_supported:!0,end_session_endpoint:"https://login.microsoftonline.com/organizations/oauth2/v2.0/logout",claims_supported:["sub","iss","cloud_instance_name","cloud_instance_host_name","cloud_graph_host_name","msgraph_host","aud","exp","iat","auth_time","acr","nonce","preferred_username","name","tid","ver","at_hash","c_hash","email"],kerberos_endpoint:"https://login.microsoftonline.com/organizations/kerberos",tenant_region_scope:null,cloud_instance_name:"microsoftonline.com",cloud_graph_host_name:"graph.windows.net",msgraph_host:"graph.microsoft.com",rbac_url:"https://pas.windows.net"},"https://login.chinacloudapi.cn/organizations/":{token_endpoint:"https://login.chinacloudapi.cn/organizations/oauth2/v2.0/token",token_endpoint_auth_methods_supported:["client_secret_post","private_key_jwt","client_secret_basic"],jwks_uri:"https://login.chinacloudapi.cn/organizations/discovery/v2.0/keys",response_modes_supported:["query","fragment","form_post"],subject_types_supported:["pairwise"],id_token_signing_alg_values_supported:["RS256"],response_types_supported:["code","id_token","code id_token","id_token token"],scopes_supported:["openid","profile","email","offline_access"],issuer:"https://login.partner.microsoftonline.cn/{tenantid}/v2.0",request_uri_parameter_supported:!1,userinfo_endpoint:"https://microsoftgraph.chinacloudapi.cn/oidc/userinfo",authorization_endpoint:"https://login.chinacloudapi.cn/organizations/oauth2/v2.0/authorize",device_authorization_endpoint:"https://login.chinacloudapi.cn/organizations/oauth2/v2.0/devicecode",http_logout_supported:!0,frontchannel_logout_supported:!0,end_session_endpoint:"https://login.chinacloudapi.cn/organizations/oauth2/v2.0/logout",claims_supported:["sub","iss","cloud_instance_name","cloud_instance_host_name","cloud_graph_host_name","msgraph_host","aud","exp","iat","auth_time","acr","nonce","preferred_username","name","tid","ver","at_hash","c_hash","email"],kerberos_endpoint:"https://login.chinacloudapi.cn/organizations/kerberos",tenant_region_scope:null,cloud_instance_name:"partner.microsoftonline.cn",cloud_graph_host_name:"graph.chinacloudapi.cn",msgraph_host:"microsoftgraph.chinacloudapi.cn",rbac_url:"https://pas.chinacloudapi.cn"},"https://login.microsoftonline.us/organizations/":{token_endpoint:"https://login.microsoftonline.us/organizations/oauth2/v2.0/token",token_endpoint_auth_methods_supported:["client_secret_post","private_key_jwt","client_secret_basic"],jwks_uri:"https://login.microsoftonline.us/organizations/discovery/v2.0/keys",response_modes_supported:["query","fragment","form_post"],subject_types_supported:["pairwise"],id_token_signing_alg_values_supported:["RS256"],response_types_supported:["code","id_token","code id_token","id_token token"],scopes_supported:["openid","profile","email","offline_access"],issuer:"https://login.microsoftonline.us/{tenantid}/v2.0",request_uri_parameter_supported:!1,userinfo_endpoint:"https://graph.microsoft.com/oidc/userinfo",authorization_endpoint:"https://login.microsoftonline.us/organizations/oauth2/v2.0/authorize",device_authorization_endpoint:"https://login.microsoftonline.us/organizations/oauth2/v2.0/devicecode",http_logout_supported:!0,frontchannel_logout_supported:!0,end_session_endpoint:"https://login.microsoftonline.us/organizations/oauth2/v2.0/logout",claims_supported:["sub","iss","cloud_instance_name","cloud_instance_host_name","cloud_graph_host_name","msgraph_host","aud","exp","iat","auth_time","acr","nonce","preferred_username","name","tid","ver","at_hash","c_hash","email"],kerberos_endpoint:"https://login.microsoftonline.us/organizations/kerberos",tenant_region_scope:null,cloud_instance_name:"microsoftonline.us",cloud_graph_host_name:"graph.windows.net",msgraph_host:"graph.microsoft.com",rbac_url:"https://pasff.usgovcloudapi.net"}},Je={"https://login.microsoftonline.com/common/":{tenant_discovery_endpoint:"https://login.microsoftonline.com/common/v2.0/.well-known/openid-configuration","api-version":"1.1",metadata:[{preferred_network:"login.microsoftonline.com",preferred_cache:"login.windows.net",aliases:["login.microsoftonline.com","login.windows.net","login.microsoft.com","sts.windows.net"]},{preferred_network:"login.partner.microsoftonline.cn",preferred_cache:"login.partner.microsoftonline.cn",aliases:["login.partner.microsoftonline.cn","login.chinacloudapi.cn"]},{preferred_network:"login.microsoftonline.de",preferred_cache:"login.microsoftonline.de",aliases:["login.microsoftonline.de"]},{preferred_network:"login.microsoftonline.us",preferred_cache:"login.microsoftonline.us",aliases:["login.microsoftonline.us","login.usgovcloudapi.net"]},{preferred_network:"login-us.microsoftonline.com",preferred_cache:"login-us.microsoftonline.com",aliases:["login-us.microsoftonline.com"]}]},"https://login.chinacloudapi.cn/common/":{tenant_discovery_endpoint:"https://login.chinacloudapi.cn/common/v2.0/.well-known/openid-configuration","api-version":"1.1",metadata:[{preferred_network:"login.microsoftonline.com",preferred_cache:"login.windows.net",aliases:["login.microsoftonline.com","login.windows.net","login.microsoft.com","sts.windows.net"]},{preferred_network:"login.partner.microsoftonline.cn",preferred_cache:"login.partner.microsoftonline.cn",aliases:["login.partner.microsoftonline.cn","login.chinacloudapi.cn"]},{preferred_network:"login.microsoftonline.de",preferred_cache:"login.microsoftonline.de",aliases:["login.microsoftonline.de"]},{preferred_network:"login.microsoftonline.us",preferred_cache:"login.microsoftonline.us",aliases:["login.microsoftonline.us","login.usgovcloudapi.net"]},{preferred_network:"login-us.microsoftonline.com",preferred_cache:"login-us.microsoftonline.com",aliases:["login-us.microsoftonline.com"]}]},"https://login.microsoftonline.us/common/":{tenant_discovery_endpoint:"https://login.microsoftonline.us/common/v2.0/.well-known/openid-configuration","api-version":"1.1",metadata:[{preferred_network:"login.microsoftonline.com",preferred_cache:"login.windows.net",aliases:["login.microsoftonline.com","login.windows.net","login.microsoft.com","sts.windows.net"]},{preferred_network:"login.partner.microsoftonline.cn",preferred_cache:"login.partner.microsoftonline.cn",aliases:["login.partner.microsoftonline.cn","login.chinacloudapi.cn"]},{preferred_network:"login.microsoftonline.de",preferred_cache:"login.microsoftonline.de",aliases:["login.microsoftonline.de"]},{preferred_network:"login.microsoftonline.us",preferred_cache:"login.microsoftonline.us",aliases:["login.microsoftonline.us","login.usgovcloudapi.net"]},{preferred_network:"login-us.microsoftonline.com",preferred_cache:"login-us.microsoftonline.com",aliases:["login-us.microsoftonline.com"]}]},"https://login.microsoftonline.com/consumers/":{tenant_discovery_endpoint:"https://login.microsoftonline.com/consumers/v2.0/.well-known/openid-configuration","api-version":"1.1",metadata:[{preferred_network:"login.microsoftonline.com",preferred_cache:"login.windows.net",aliases:["login.microsoftonline.com","login.windows.net","login.microsoft.com","sts.windows.net"]},{preferred_network:"login.partner.microsoftonline.cn",preferred_cache:"login.partner.microsoftonline.cn",aliases:["login.partner.microsoftonline.cn","login.chinacloudapi.cn"]},{preferred_network:"login.microsoftonline.de",preferred_cache:"login.microsoftonline.de",aliases:["login.microsoftonline.de"]},{preferred_network:"login.microsoftonline.us",preferred_cache:"login.microsoftonline.us",aliases:["login.microsoftonline.us","login.usgovcloudapi.net"]},{preferred_network:"login-us.microsoftonline.com",preferred_cache:"login-us.microsoftonline.com",aliases:["login-us.microsoftonline.com"]}]},"https://login.chinacloudapi.cn/consumers/":{tenant_discovery_endpoint:"https://login.chinacloudapi.cn/consumers/v2.0/.well-known/openid-configuration","api-version":"1.1",metadata:[{preferred_network:"login.microsoftonline.com",preferred_cache:"login.windows.net",aliases:["login.microsoftonline.com","login.windows.net","login.microsoft.com","sts.windows.net"]},{preferred_network:"login.partner.microsoftonline.cn",preferred_cache:"login.partner.microsoftonline.cn",aliases:["login.partner.microsoftonline.cn","login.chinacloudapi.cn"]},{preferred_network:"login.microsoftonline.de",preferred_cache:"login.microsoftonline.de",aliases:["login.microsoftonline.de"]},{preferred_network:"login.microsoftonline.us",preferred_cache:"login.microsoftonline.us",aliases:["login.microsoftonline.us","login.usgovcloudapi.net"]},{preferred_network:"login-us.microsoftonline.com",preferred_cache:"login-us.microsoftonline.com",aliases:["login-us.microsoftonline.com"]}]},"https://login.microsoftonline.us/consumers/":{tenant_discovery_endpoint:"https://login.microsoftonline.us/consumers/v2.0/.well-known/openid-configuration","api-version":"1.1",metadata:[{preferred_network:"login.microsoftonline.com",preferred_cache:"login.windows.net",aliases:["login.microsoftonline.com","login.windows.net","login.microsoft.com","sts.windows.net"]},{preferred_network:"login.partner.microsoftonline.cn",preferred_cache:"login.partner.microsoftonline.cn",aliases:["login.partner.microsoftonline.cn","login.chinacloudapi.cn"]},{preferred_network:"login.microsoftonline.de",preferred_cache:"login.microsoftonline.de",aliases:["login.microsoftonline.de"]},{preferred_network:"login.microsoftonline.us",preferred_cache:"login.microsoftonline.us",aliases:["login.microsoftonline.us","login.usgovcloudapi.net"]},{preferred_network:"login-us.microsoftonline.com",preferred_cache:"login-us.microsoftonline.com",aliases:["login-us.microsoftonline.com"]}]},"https://login.microsoftonline.com/organizations/":{tenant_discovery_endpoint:"https://login.microsoftonline.com/organizations/v2.0/.well-known/openid-configuration","api-version":"1.1",metadata:[{preferred_network:"login.microsoftonline.com",preferred_cache:"login.windows.net",aliases:["login.microsoftonline.com","login.windows.net","login.microsoft.com","sts.windows.net"]},{preferred_network:"login.partner.microsoftonline.cn",preferred_cache:"login.partner.microsoftonline.cn",aliases:["login.partner.microsoftonline.cn","login.chinacloudapi.cn"]},{preferred_network:"login.microsoftonline.de",preferred_cache:"login.microsoftonline.de",aliases:["login.microsoftonline.de"]},{preferred_network:"login.microsoftonline.us",preferred_cache:"login.microsoftonline.us",aliases:["login.microsoftonline.us","login.usgovcloudapi.net"]},{preferred_network:"login-us.microsoftonline.com",preferred_cache:"login-us.microsoftonline.com",aliases:["login-us.microsoftonline.com"]}]},"https://login.chinacloudapi.cn/organizations/":{tenant_discovery_endpoint:"https://login.chinacloudapi.cn/organizations/v2.0/.well-known/openid-configuration","api-version":"1.1",metadata:[{preferred_network:"login.microsoftonline.com",preferred_cache:"login.windows.net",aliases:["login.microsoftonline.com","login.windows.net","login.microsoft.com","sts.windows.net"]},{preferred_network:"login.partner.microsoftonline.cn",preferred_cache:"login.partner.microsoftonline.cn",aliases:["login.partner.microsoftonline.cn","login.chinacloudapi.cn"]},{preferred_network:"login.microsoftonline.de",preferred_cache:"login.microsoftonline.de",aliases:["login.microsoftonline.de"]},{preferred_network:"login.microsoftonline.us",preferred_cache:"login.microsoftonline.us",aliases:["login.microsoftonline.us","login.usgovcloudapi.net"]},{preferred_network:"login-us.microsoftonline.com",preferred_cache:"login-us.microsoftonline.com",aliases:["login-us.microsoftonline.com"]}]},"https://login.microsoftonline.us/organizations/":{tenant_discovery_endpoint:"https://login.microsoftonline.us/organizations/v2.0/.well-known/openid-configuration","api-version":"1.1",metadata:[{preferred_network:"login.microsoftonline.com",preferred_cache:"login.windows.net",aliases:["login.microsoftonline.com","login.windows.net","login.microsoft.com","sts.windows.net"]},{preferred_network:"login.partner.microsoftonline.cn",preferred_cache:"login.partner.microsoftonline.cn",aliases:["login.partner.microsoftonline.cn","login.chinacloudapi.cn"]},{preferred_network:"login.microsoftonline.de",preferred_cache:"login.microsoftonline.de",aliases:["login.microsoftonline.de"]},{preferred_network:"login.microsoftonline.us",preferred_cache:"login.microsoftonline.us",aliases:["login.microsoftonline.us","login.usgovcloudapi.net"]},{preferred_network:"login-us.microsoftonline.com",preferred_cache:"login-us.microsoftonline.com",aliases:["login-us.microsoftonline.com"]}]}};!function(e){e.AAD="AAD",e.OIDC="OIDC"}(Ye||(Ye={}));var Ze=function(){function e(){this.expiresAt=we.nowSeconds()+86400}return e.prototype.updateCloudDiscoveryMetadata=function(e,t){this.aliases=e.aliases,this.preferred_cache=e.preferred_cache,this.preferred_network=e.preferred_network,this.aliasesFromNetwork=t},e.prototype.updateEndpointMetadata=function(e,t){this.authorization_endpoint=e.authorization_endpoint,this.token_endpoint=e.token_endpoint,this.end_session_endpoint=e.end_session_endpoint,this.issuer=e.issuer,this.endpointsFromNetwork=t,this.jwks_uri=e.jwks_uri},e.prototype.updateCanonicalAuthority=function(e){this.canonical_authority=e},e.prototype.resetExpiresAt=function(){this.expiresAt=we.nowSeconds()+86400},e.prototype.isExpired=function(){return this.expiresAt<=we.nowSeconds()},e.isAuthorityMetadataEntity=function(e,t){return!!t&&0===e.indexOf(P)&&t.hasOwnProperty("aliases")&&t.hasOwnProperty("preferred_cache")&&t.hasOwnProperty("preferred_network")&&t.hasOwnProperty("canonical_authority")&&t.hasOwnProperty("authorization_endpoint")&&t.hasOwnProperty("token_endpoint")&&t.hasOwnProperty("issuer")&&t.hasOwnProperty("aliasesFromNetwork")&&t.hasOwnProperty("endpointsFromNetwork")&&t.hasOwnProperty("expiresAt")&&t.hasOwnProperty("jwks_uri")},e}(),et=function(){function e(e,t,n){this.networkInterface=e,this.performanceClient=t,this.correlationId=n}return e.prototype.detectRegion=function(t,n){var r,o,i,c;return s(this,void 0,void 0,(function(){var s,u,l,p,d;return a(this,(function(a){switch(a.label){case 0:if(null===(r=this.performanceClient)||void 0===r||r.addQueueMeasurement(be.RegionDiscoveryDetectRegion,this.correlationId),s=t)return[3,8];u=e.IMDS_OPTIONS,a.label=1;case 1:return a.trys.push([1,6,,7]),null===(o=this.performanceClient)||void 0===o||o.setPreQueueTime(be.RegionDiscoveryGetRegionFromIMDS,this.correlationId),[4,this.getRegionFromIMDS(f.IMDS_VERSION,u)];case 2:return(l=a.sent()).status===D.httpSuccess&&(s=l.body,n.region_source=M.IMDS),l.status!==D.httpBadRequest?[3,5]:(null===(i=this.performanceClient)||void 0===i||i.setPreQueueTime(be.RegionDiscoveryGetCurrentVersion,this.correlationId),[4,this.getCurrentVersion(u)]);case 3:return(p=a.sent())?(null===(c=this.performanceClient)||void 0===c||c.setPreQueueTime(be.RegionDiscoveryGetRegionFromIMDS,this.correlationId),[4,this.getRegionFromIMDS(p,u)]):(n.region_source=M.FAILED_AUTO_DETECTION,[2,null]);case 4:(d=a.sent()).status===D.httpSuccess&&(s=d.body,n.region_source=M.IMDS),a.label=5;case 5:return[3,7];case 6:return a.sent(),n.region_source=M.FAILED_AUTO_DETECTION,[2,null];case 7:return[3,9];case 8:n.region_source=M.ENVIRONMENT_VARIABLE,a.label=9;case 9:return s||(n.region_source=M.FAILED_AUTO_DETECTION),[2,s||null]}}))}))},e.prototype.getRegionFromIMDS=function(e,t){var n;return s(this,void 0,void 0,(function(){return a(this,(function(r){return null===(n=this.performanceClient)||void 0===n||n.addQueueMeasurement(be.RegionDiscoveryGetRegionFromIMDS,this.correlationId),[2,this.networkInterface.sendGetRequestAsync(f.IMDS_ENDPOINT+"?api-version="+e+"&format=text",t,f.IMDS_TIMEOUT)]}))}))},e.prototype.getCurrentVersion=function(e){var t;return s(this,void 0,void 0,(function(){var n;return a(this,(function(r){switch(r.label){case 0:null===(t=this.performanceClient)||void 0===t||t.addQueueMeasurement(be.RegionDiscoveryGetCurrentVersion,this.correlationId),r.label=1;case 1:return r.trys.push([1,3,,4]),[4,this.networkInterface.sendGetRequestAsync(f.IMDS_ENDPOINT+"?format=json",e)];case 2:return(n=r.sent()).status===D.httpBadRequest&&n.body&&n.body["newest-versions"]&&n.body["newest-versions"].length>0?[2,n.body["newest-versions"][0]]:[2,null];case 3:return r.sent(),[2,null];case 4:return[2]}}))}))},e.IMDS_OPTIONS={headers:{Metadata:"true"}},e}(),tt=function(){function e(e,t,n,r,o,i,s){this.canonicalAuthority=e,this._canonicalAuthority.validateAsUri(),this.networkInterface=t,this.cacheManager=n,this.authorityOptions=r,this.regionDiscoveryMetadata={region_used:void 0,region_source:void 0,region_outcome:void 0},this.logger=o,this.performanceClient=i,this.correlationId=s,this.regionDiscovery=new et(t,this.performanceClient,this.correlationId)}return Object.defineProperty(e.prototype,"authorityType",{get:function(){var e=this.canonicalAuthorityUrlComponents.PathSegments;if(e.length)switch(e[0].toLowerCase()){case f.ADFS:return Z.Adfs;case f.DSTS:return Z.Dsts}return Z.Default},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"protocolMode",{get:function(){return this.authorityOptions.protocolMode},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"options",{get:function(){return this.authorityOptions},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"canonicalAuthority",{get:function(){return this._canonicalAuthority.urlString},set:function(e){this._canonicalAuthority=new Me(e),this._canonicalAuthority.validateAsUri(),this._canonicalAuthorityUrlComponents=null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"canonicalAuthorityUrlComponents",{get:function(){return this._canonicalAuthorityUrlComponents||(this._canonicalAuthorityUrlComponents=this._canonicalAuthority.getUrlComponents()),this._canonicalAuthorityUrlComponents},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"hostnameAndPort",{get:function(){return this.canonicalAuthorityUrlComponents.HostNameAndPort.toLowerCase()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tenant",{get:function(){return this.canonicalAuthorityUrlComponents.PathSegments[0]},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"authorizationEndpoint",{get:function(){if(this.discoveryComplete()){var e=this.replacePath(this.metadata.authorization_endpoint);return this.replaceTenant(e)}throw K.createEndpointDiscoveryIncompleteError("Discovery incomplete.")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tokenEndpoint",{get:function(){if(this.discoveryComplete()){var e=this.replacePath(this.metadata.token_endpoint);return this.replaceTenant(e)}throw K.createEndpointDiscoveryIncompleteError("Discovery incomplete.")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"deviceCodeEndpoint",{get:function(){if(this.discoveryComplete()){var e=this.replacePath(this.metadata.token_endpoint.replace("/token","/devicecode"));return this.replaceTenant(e)}throw K.createEndpointDiscoveryIncompleteError("Discovery incomplete.")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"endSessionEndpoint",{get:function(){if(this.discoveryComplete()){if(!this.metadata.end_session_endpoint)throw K.createLogoutNotSupportedError();var e=this.replacePath(this.metadata.end_session_endpoint);return this.replaceTenant(e)}throw K.createEndpointDiscoveryIncompleteError("Discovery incomplete.")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"selfSignedJwtAudience",{get:function(){if(this.discoveryComplete()){var e=this.replacePath(this.metadata.issuer);return this.replaceTenant(e)}throw K.createEndpointDiscoveryIncompleteError("Discovery incomplete.")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"jwksUri",{get:function(){if(this.discoveryComplete()){var e=this.replacePath(this.metadata.jwks_uri);return this.replaceTenant(e)}throw K.createEndpointDiscoveryIncompleteError("Discovery incomplete.")},enumerable:!1,configurable:!0}),e.prototype.replaceTenant=function(e){return e.replace(/{tenant}|{tenantid}/g,this.tenant)},e.prototype.replacePath=function(e){var t=e,n=new Me(this.metadata.canonical_authority).getUrlComponents().PathSegments;return this.canonicalAuthorityUrlComponents.PathSegments.forEach((function(e,r){var o=n[r];e!==o&&(t=t.replace("/"+o+"/","/"+e+"/"))})),t},Object.defineProperty(e.prototype,"defaultOpenIdConfigurationEndpoint",{get:function(){return this.authorityType===Z.Adfs||this.authorityType===Z.Dsts||this.protocolMode===Ye.OIDC?this.canonicalAuthority+".well-known/openid-configuration":this.canonicalAuthority+"v2.0/.well-known/openid-configuration"},enumerable:!1,configurable:!0}),e.prototype.discoveryComplete=function(){return!!this.metadata},e.prototype.resolveEndpointsAsync=function(){var e,t,n;return s(this,void 0,void 0,(function(){var r,o,i,s;return a(this,(function(a){switch(a.label){case 0:return null===(e=this.performanceClient)||void 0===e||e.addQueueMeasurement(be.AuthorityResolveEndpointsAsync,this.correlationId),(r=this.cacheManager.getAuthorityMetadataByAlias(this.hostnameAndPort))||(r=new Ze).updateCanonicalAuthority(this.canonicalAuthority),null===(t=this.performanceClient)||void 0===t||t.setPreQueueTime(be.AuthorityUpdateCloudDiscoveryMetadata,this.correlationId),[4,this.updateCloudDiscoveryMetadata(r)];case 1:return o=a.sent(),this.canonicalAuthority=this.canonicalAuthority.replace(this.hostnameAndPort,r.preferred_network),null===(n=this.performanceClient)||void 0===n||n.setPreQueueTime(be.AuthorityUpdateEndpointMetadata,this.correlationId),[4,this.updateEndpointMetadata(r)];case 2:return i=a.sent(),o!==A.CACHE&&i!==A.CACHE&&(r.resetExpiresAt(),r.updateCanonicalAuthority(this.canonicalAuthority)),s=this.cacheManager.generateAuthorityMetadataCacheKey(r.preferred_cache),this.cacheManager.setAuthorityMetadata(s,r),this.metadata=r,[2]}}))}))},e.prototype.updateEndpointMetadata=function(e){var t,n,r,o,i,c;return s(this,void 0,void 0,(function(){var s,u;return a(this,(function(a){switch(a.label){case 0:return null===(t=this.performanceClient)||void 0===t||t.addQueueMeasurement(be.AuthorityUpdateEndpointMetadata,this.correlationId),(s=this.getEndpointMetadataFromConfig())?(e.updateEndpointMetadata(s,!1),[2,A.CONFIG]):this.isAuthoritySameType(e)&&e.endpointsFromNetwork&&!e.isExpired()?[2,A.CACHE]:(u=this.getEndpointMetadataFromHardcodedValues(),null===(n=this.performanceClient)||void 0===n||n.setPreQueueTime(be.AuthorityGetEndpointMetadataFromNetwork,this.correlationId),[4,this.getEndpointMetadataFromNetwork()]);case 1:return(s=a.sent())?(null===(r=this.authorityOptions.azureRegionConfiguration)||void 0===r?void 0:r.azureRegion)?(null===(o=this.performanceClient)||void 0===o||o.setPreQueueTime(be.AuthorityUpdateMetadataWithRegionalInformation,this.correlationId),[4,this.updateMetadataWithRegionalInformation(s)]):[3,3]:[3,4];case 2:s=a.sent(),a.label=3;case 3:return e.updateEndpointMetadata(s,!0),[2,A.NETWORK];case 4:return!u||this.authorityOptions.skipAuthorityMetadataCache?[3,7]:(null===(i=this.authorityOptions.azureRegionConfiguration)||void 0===i?void 0:i.azureRegion)?(null===(c=this.performanceClient)||void 0===c||c.setPreQueueTime(be.AuthorityUpdateMetadataWithRegionalInformation,this.correlationId),[4,this.updateMetadataWithRegionalInformation(u)]):[3,6];case 5:u=a.sent(),a.label=6;case 6:return e.updateEndpointMetadata(u,!1),[2,A.HARDCODED_VALUES];case 7:throw K.createUnableToGetOpenidConfigError(this.defaultOpenIdConfigurationEndpoint)}}))}))},e.prototype.isAuthoritySameType=function(e){return new Me(e.canonical_authority).getUrlComponents().PathSegments.length===this.canonicalAuthorityUrlComponents.PathSegments.length},e.prototype.getEndpointMetadataFromConfig=function(){if(this.authorityOptions.authorityMetadata)try{return JSON.parse(this.authorityOptions.authorityMetadata)}catch(e){throw te.createInvalidAuthorityMetadataError()}return null},e.prototype.getEndpointMetadataFromNetwork=function(){var e;return s(this,void 0,void 0,(function(){var t,n;return a(this,(function(r){switch(r.label){case 0:null===(e=this.performanceClient)||void 0===e||e.addQueueMeasurement(be.AuthorityGetEndpointMetadataFromNetwork,this.correlationId),t={},r.label=1;case 1:return r.trys.push([1,3,,4]),[4,this.networkInterface.sendGetRequestAsync(this.defaultOpenIdConfigurationEndpoint,t)];case 2:return[2,Qe((n=r.sent()).body)?n.body:null];case 3:return r.sent(),[2,null];case 4:return[2]}}))}))},e.prototype.getEndpointMetadataFromHardcodedValues=function(){return this.canonicalAuthority in Xe?Xe[this.canonicalAuthority]:null},e.prototype.updateMetadataWithRegionalInformation=function(t){var n,r,o,i,c,u,l;return s(this,void 0,void 0,(function(){var s,p;return a(this,(function(a){switch(a.label){case 0:return null===(n=this.performanceClient)||void 0===n||n.addQueueMeasurement(be.AuthorityUpdateMetadataWithRegionalInformation,this.correlationId),null===(r=this.performanceClient)||void 0===r||r.setPreQueueTime(be.RegionDiscoveryDetectRegion,this.correlationId),[4,this.regionDiscovery.detectRegion(null===(o=this.authorityOptions.azureRegionConfiguration)||void 0===o?void 0:o.environmentRegion,this.regionDiscoveryMetadata)];case 1:return s=a.sent(),p=(null===(i=this.authorityOptions.azureRegionConfiguration)||void 0===i?void 0:i.azureRegion)===f.AZURE_REGION_AUTO_DISCOVER_FLAG?s:null===(c=this.authorityOptions.azureRegionConfiguration)||void 0===c?void 0:c.azureRegion,(null===(u=this.authorityOptions.azureRegionConfiguration)||void 0===u?void 0:u.azureRegion)===f.AZURE_REGION_AUTO_DISCOVER_FLAG?this.regionDiscoveryMetadata.region_outcome=s?L.AUTO_DETECTION_REQUESTED_SUCCESSFUL:L.AUTO_DETECTION_REQUESTED_FAILED:this.regionDiscoveryMetadata.region_outcome=s?(null===(l=this.authorityOptions.azureRegionConfiguration)||void 0===l?void 0:l.azureRegion)===s?L.CONFIGURED_MATCHES_DETECTED:L.CONFIGURED_NOT_DETECTED:L.CONFIGURED_NO_AUTO_DETECTION,p?(this.regionDiscoveryMetadata.region_used=p,[2,e.replaceWithRegionalInformation(t,p)]):[2,t]}}))}))},e.prototype.updateCloudDiscoveryMetadata=function(e){var t,n;return s(this,void 0,void 0,(function(){var r,o,i;return a(this,(function(s){switch(s.label){case 0:return null===(t=this.performanceClient)||void 0===t||t.addQueueMeasurement(be.AuthorityUpdateCloudDiscoveryMetadata,this.correlationId),this.logger.verbose("Attempting to get cloud discovery metadata in the config"),this.logger.verbosePii("Known Authorities: "+(this.authorityOptions.knownAuthorities||f.NOT_APPLICABLE)),this.logger.verbosePii("Authority Metadata: "+(this.authorityOptions.authorityMetadata||f.NOT_APPLICABLE)),this.logger.verbosePii("Canonical Authority: "+(e.canonical_authority||f.NOT_APPLICABLE)),(r=this.getCloudDiscoveryMetadataFromConfig())?(this.logger.verbose("Found cloud discovery metadata in the config."),e.updateCloudDiscoveryMetadata(r,!1),[2,A.CONFIG]):(this.logger.verbose("Did not find cloud discovery metadata in the config... Attempting to get cloud discovery metadata from the cache."),o=e.isExpired(),this.isAuthoritySameType(e)&&e.aliasesFromNetwork&&!o?(this.logger.verbose("Found metadata in the cache."),[2,A.CACHE]):(o&&this.logger.verbose("The metadata entity is expired."),this.logger.verbose("Did not find cloud discovery metadata in the cache... Attempting to get cloud discovery metadata from the network."),null===(n=this.performanceClient)||void 0===n||n.setPreQueueTime(be.AuthorityGetCloudDiscoveryMetadataFromNetwork,this.correlationId),[4,this.getCloudDiscoveryMetadataFromNetwork()]));case 1:if(r=s.sent())return this.logger.verbose("cloud discovery metadata was successfully returned from getCloudDiscoveryMetadataFromNetwork()"),e.updateCloudDiscoveryMetadata(r,!0),[2,A.NETWORK];if(this.logger.verbose("Did not find cloud discovery metadata from the network... Attempting to get cloud discovery metadata from hardcoded values."),(i=this.getCloudDiscoveryMetadataFromHarcodedValues())&&!this.options.skipAuthorityMetadataCache)return this.logger.verbose("Found cloud discovery metadata from hardcoded values."),e.updateCloudDiscoveryMetadata(i,!1),[2,A.HARDCODED_VALUES];throw this.logger.error("Did not find cloud discovery metadata from hardcoded values... Metadata could not be obtained from config, cache, network or hardcoded values. Throwing Untrusted Authority Error."),te.createUntrustedAuthorityError()}}))}))},e.prototype.getCloudDiscoveryMetadataFromConfig=function(){if(this.authorityOptions.cloudDiscoveryMetadata){this.logger.verbose("The cloud discovery metadata has been provided as a network response, in the config.");try{this.logger.verbose("Attempting to parse the cloud discovery metadata.");var t=JSON.parse(this.authorityOptions.cloudDiscoveryMetadata),n=e.getCloudDiscoveryMetadataFromNetworkResponse(t.metadata,this.hostnameAndPort);if(this.logger.verbose("Parsed the cloud discovery metadata."),n)return this.logger.verbose("There is returnable metadata attached to the parsed cloud discovery metadata."),n;this.logger.verbose("There is no metadata attached to the parsed cloud discovery metadata.")}catch(e){throw this.logger.verbose("Unable to parse the cloud discovery metadata. Throwing Invalid Cloud Discovery Metadata Error."),te.createInvalidCloudDiscoveryMetadataError()}}return this.isInKnownAuthorities()?(this.logger.verbose("The host is included in knownAuthorities. Creating new cloud discovery metadata from the host."),e.createCloudDiscoveryMetadataFromHost(this.hostnameAndPort)):null},e.prototype.getCloudDiscoveryMetadataFromNetwork=function(){var t;return s(this,void 0,void 0,(function(){var n,r,o,i,s,c,u,l;return a(this,(function(a){switch(a.label){case 0:null===(t=this.performanceClient)||void 0===t||t.addQueueMeasurement(be.AuthorityGetCloudDiscoveryMetadataFromNetwork,this.correlationId),n=""+f.AAD_INSTANCE_DISCOVERY_ENDPT+this.canonicalAuthority+"oauth2/v2.0/authorize",r={},o=null,a.label=1;case 1:return a.trys.push([1,3,,4]),[4,this.networkInterface.sendGetRequestAsync(n,r)];case 2:if(i=a.sent(),s=void 0,c=void 0,function(e){return e.hasOwnProperty("tenant_discovery_endpoint")&&e.hasOwnProperty("metadata")}(i.body))s=i.body,c=s.metadata,this.logger.verbosePii("tenant_discovery_endpoint is: "+s.tenant_discovery_endpoint);else{if(!function(e){return e.hasOwnProperty("error")&&e.hasOwnProperty("error_description")}(i.body))return this.logger.error("AAD did not return a CloudInstanceDiscoveryResponse or CloudInstanceDiscoveryErrorResponse"),[2,null];if(this.logger.warning("A CloudInstanceDiscoveryErrorResponse was returned. The cloud instance discovery network request's status code is: "+i.status),(s=i.body).error===f.INVALID_INSTANCE)return this.logger.error("The CloudInstanceDiscoveryErrorResponse error is invalid_instance."),[2,null];this.logger.warning("The CloudInstanceDiscoveryErrorResponse error is "+s.error),this.logger.warning("The CloudInstanceDiscoveryErrorResponse error description is "+s.error_description),this.logger.warning("Setting the value of the CloudInstanceDiscoveryMetadata (returned from the network) to []"),c=[]}return this.logger.verbose("Attempting to find a match between the developer's authority and the CloudInstanceDiscoveryMetadata returned from the network request."),o=e.getCloudDiscoveryMetadataFromNetworkResponse(c,this.hostnameAndPort),[3,4];case 3:return(u=a.sent())instanceof G?this.logger.error("There was a network error while attempting to get the cloud discovery instance metadata.\nError: "+u.errorCode+"\nError Description: "+u.errorMessage):(l=u,this.logger.error("A non-MSALJS error was thrown while attempting to get the cloud instance discovery metadata.\nError: "+l.name+"\nError Description: "+l.message)),[2,null];case 4:return o||(this.logger.warning("The developer's authority was not found within the CloudInstanceDiscoveryMetadata returned from the network request."),this.logger.verbose("Creating custom Authority for custom domain scenario."),o=e.createCloudDiscoveryMetadataFromHost(this.hostnameAndPort)),[2,o]}}))}))},e.prototype.getCloudDiscoveryMetadataFromHarcodedValues=function(){return this.canonicalAuthority in Je?Je[this.canonicalAuthority]:null},e.prototype.isInKnownAuthorities=function(){var e=this;return this.authorityOptions.knownAuthorities.filter((function(t){return Me.getDomainFromUrl(t).toLowerCase()===e.hostnameAndPort})).length>0},e.generateAuthority=function(e,t){var n;if(t&&t.azureCloudInstance!==Q.None){var r=t.tenant?t.tenant:f.DEFAULT_COMMON_TENANT;n=t.azureCloudInstance+"/"+r+"/"}return n||e},e.createCloudDiscoveryMetadataFromHost=function(e){return{preferred_network:e,preferred_cache:e,aliases:[e]}},e.getCloudDiscoveryMetadataFromNetworkResponse=function(e,t){for(var n=0;n<e.length;n++){var r=e[n];if(r.aliases.indexOf(t)>-1)return r}return null},e.prototype.getPreferredCache=function(){if(this.discoveryComplete())return this.metadata.preferred_cache;throw K.createEndpointDiscoveryIncompleteError("Discovery incomplete.")},e.prototype.isAlias=function(e){return this.metadata.aliases.indexOf(e)>-1},e.isPublicCloudAuthority=function(e){return f.KNOWN_PUBLIC_CLOUDS.indexOf(e)>=0},e.buildRegionalAuthorityString=function(e,t,n){var r=new Me(e);r.validateAsUri();var o=r.getUrlComponents(),s=t+"."+o.HostNameAndPort;this.isPublicCloudAuthority(o.HostNameAndPort)&&(s=t+"."+f.REGIONAL_AUTH_PUBLIC_CLOUD_SUFFIX);var a=Me.constructAuthorityUriFromObject(i(i({},r.getUrlComponents()),{HostNameAndPort:s})).urlString;return n?a+"?"+n:a},e.replaceWithRegionalInformation=function(t,n){return t.authorization_endpoint=e.buildRegionalAuthorityString(t.authorization_endpoint,n),t.token_endpoint=e.buildRegionalAuthorityString(t.token_endpoint,n,f.REGIONAL_AUTH_NON_MSI_QUERY_STRING),t.end_session_endpoint&&(t.end_session_endpoint=e.buildRegionalAuthorityString(t.end_session_endpoint,n)),t},e}(),nt=function(){function e(){}return e.createDiscoveredInstance=function(t,n,r,o,i,c,u){return s(this,void 0,void 0,(function(){var s,l;return a(this,(function(a){switch(a.label){case 0:null==c||c.addQueueMeasurement(be.AuthorityFactoryCreateDiscoveredInstance,u),s=e.createInstance(t,n,r,o,i,c,u),a.label=1;case 1:return a.trys.push([1,3,,4]),null==c||c.setPreQueueTime(be.AuthorityResolveEndpointsAsync,u),[4,s.resolveEndpointsAsync()];case 2:return a.sent(),[2,s];case 3:throw l=a.sent(),K.createEndpointDiscoveryIncompleteError(l);case 4:return[2]}}))}))},e.createInstance=function(e,t,n,r,o,i,s){if(W.isEmpty(e))throw te.createUrlEmptyError();return new tt(e,t,n,r,o,i,s)},e}(),rt=function(){function e(){this.failedRequests=[],this.errors=[],this.cacheHits=0}return e.isServerTelemetryEntity=function(e,t){var n=0===e.indexOf(N.CACHE_KEY),r=!0;return t&&(r=t.hasOwnProperty("failedRequests")&&t.hasOwnProperty("errors")&&t.hasOwnProperty("cacheHits")),n&&r},e}(),ot=function(){function e(){}return e.isThrottlingEntity=function(e,t){var n=!1;e&&(n=0===e.indexOf(F.THROTTLING_PREFIX));var r=!0;return t&&(r=t.hasOwnProperty("throttleTime")),n&&r},e}(),it={sendGetRequestAsync:function(){return Promise.reject(G.createUnexpectedError("Network interface - sendGetRequestAsync() has not been implemented for the Network interface."))},sendPostRequestAsync:function(){return Promise.reject(G.createUnexpectedError("Network interface - sendPostRequestAsync() has not been implemented for the Network interface."))}},st="missing_kid_error",at="The JOSE Header for the requested JWT, JWS or JWK object requires a keyId to be configured as the 'kid' header claim. No 'kid' value was provided.",ct="missing_alg_error",ut="The JOSE Header for the requested JWT, JWS or JWK object requires an algorithm to be specified as the 'alg' header claim. No 'alg' value was provided.",lt=function(e){function t(n,r){var o=e.call(this,n,r)||this;return o.name="JoseHeaderError",Object.setPrototypeOf(o,t.prototype),o}return o(t,e),t.createMissingKidError=function(){return new t(st,at)},t.createMissingAlgError=function(){return new t(ct,ut)},t}(G),pt=function(){function e(e){this.typ=e.typ,this.alg=e.alg,this.kid=e.kid}return e.getShrHeaderString=function(t){if(!t.kid)throw lt.createMissingKidError();if(!t.alg)throw lt.createMissingAlgError();var n=new e({typ:t.typ||U.Pop,kid:t.kid,alg:t.alg});return JSON.stringify(n)},e}(),dt=function(){function e(e){this.headers=e}return e.prototype.getShrNonce=function(){var e=this.headers[u.AuthenticationInfo];if(e){var t=this.parseChallenges(e);if(t.nextnonce)return t.nextnonce;throw te.createInvalidAuthenticationHeaderError(u.AuthenticationInfo,"nextnonce challenge is missing.")}var n=this.headers[u.WWWAuthenticate];if(n){var r=this.parseChallenges(n);if(r.nonce)return r.nonce;throw te.createInvalidAuthenticationHeaderError(u.WWWAuthenticate,"nonce challenge is missing.")}throw te.createMissingNonceAuthenticationHeadersError()},e.prototype.parseChallenges=function(e){var t=e.indexOf(" "),n=e.substr(t+1).split(","),r={};return n.forEach((function(e){var t=e.split("="),n=t[0],o=t[1];r[n]=unescape(o.replace(/['"]+/g,f.EMPTY_STRING))})),r},e}(),ht=function(){function e(e,t){this.cacheOutcome=j.NO_CACHE_HIT,this.cacheManager=t,this.apiId=e.apiId,this.correlationId=e.correlationId,this.wrapperSKU=e.wrapperSKU||f.EMPTY_STRING,this.wrapperVer=e.wrapperVer||f.EMPTY_STRING,this.telemetryCacheKey=N.CACHE_KEY+T.CACHE_KEY_SEPARATOR+e.clientId}return e.prototype.generateCurrentRequestHeaderValue=function(){var e=""+this.apiId+N.VALUE_SEPARATOR+this.cacheOutcome,t=[this.wrapperSKU,this.wrapperVer].join(N.VALUE_SEPARATOR),n=[e,this.getRegionDiscoveryFields()].join(N.VALUE_SEPARATOR);return[N.SCHEMA_VERSION,n,t].join(N.CATEGORY_SEPARATOR)},e.prototype.generateLastRequestHeaderValue=function(){var t=this.getLastRequests(),n=e.maxErrorsToSend(t),r=t.failedRequests.slice(0,2*n).join(N.VALUE_SEPARATOR),o=t.errors.slice(0,n).join(N.VALUE_SEPARATOR),i=t.errors.length,s=[i,n<i?N.OVERFLOW_TRUE:N.OVERFLOW_FALSE].join(N.VALUE_SEPARATOR);return[N.SCHEMA_VERSION,t.cacheHits,r,o,s].join(N.CATEGORY_SEPARATOR)},e.prototype.cacheFailedRequest=function(e){var t=this.getLastRequests();t.errors.length>=N.MAX_CACHED_ERRORS&&(t.failedRequests.shift(),t.failedRequests.shift(),t.errors.shift()),t.failedRequests.push(this.apiId,this.correlationId),W.isEmpty(e.subError)?W.isEmpty(e.errorCode)?e&&e.toString()?t.errors.push(e.toString()):t.errors.push(N.UNKNOWN_ERROR):t.errors.push(e.errorCode):t.errors.push(e.subError),this.cacheManager.setServerTelemetry(this.telemetryCacheKey,t)},e.prototype.incrementCacheHits=function(){var e=this.getLastRequests();return e.cacheHits+=1,this.cacheManager.setServerTelemetry(this.telemetryCacheKey,e),e.cacheHits},e.prototype.getLastRequests=function(){var e=new rt;return this.cacheManager.getServerTelemetry(this.telemetryCacheKey)||e},e.prototype.clearTelemetryCache=function(){var t=this.getLastRequests(),n=e.maxErrorsToSend(t);if(n===t.errors.length)this.cacheManager.removeItem(this.telemetryCacheKey);else{var r=new rt;r.failedRequests=t.failedRequests.slice(2*n),r.errors=t.errors.slice(n),this.cacheManager.setServerTelemetry(this.telemetryCacheKey,r)}},e.maxErrorsToSend=function(e){var t,n=0,r=0,o=e.errors.length;for(t=0;t<o;t++){var i=e.failedRequests[2*t]||f.EMPTY_STRING,s=e.failedRequests[2*t+1]||f.EMPTY_STRING,a=e.errors[t]||f.EMPTY_STRING;if(!((r+=i.toString().length+s.toString().length+a.length+3)<N.MAX_LAST_HEADER_BYTES))break;n+=1}return n},e.prototype.getRegionDiscoveryFields=function(){var e=[];return e.push(this.regionUsed||f.EMPTY_STRING),e.push(this.regionSource||f.EMPTY_STRING),e.push(this.regionOutcome||f.EMPTY_STRING),e.join(",")},e.prototype.updateRegionDiscoveryMetadata=function(e){this.regionUsed=e.region_used,this.regionSource=e.region_source,this.regionOutcome=e.region_outcome},e.prototype.setCacheOutcome=function(e){this.cacheOutcome=e},e}(),ft=function(){function e(e,t,n,r,o,i){this.authority=t,this.libraryName=r,this.libraryVersion=o,this.applicationTelemetry=i,this.clientId=e,this.logger=n,this.callbacks=new Map,this.eventsByCorrelationId=new Map,this.queueMeasurements=new Map,this.preQueueTimeByCorrelationId=new Map}return e.prototype.startPerformanceMeasurement=function(e,t){return{}},e.prototype.startPerformanceMeasuremeant=function(e,t){return{}},e.prototype.getIntFields=function(){return je},e.prototype.getPreQueueTime=function(e,t){var n=this.preQueueTimeByCorrelationId.get(t);if(n){if(n.name===e)return n.time;this.logger.trace("PerformanceClient.getPreQueueTime: no pre-queue time found for "+e+", unable to add queue measurement")}else this.logger.trace("PerformanceClient.getPreQueueTime: no pre-queue times found for correlationId: "+t+", unable to add queue measurement")},e.prototype.calculateQueuedTime=function(e,t){return e<1?(this.logger.trace("PerformanceClient: preQueueTime should be a positive integer and not "+e),0):t<1?(this.logger.trace("PerformanceClient: currentTime should be a positive integer and not "+t),0):t<e?(this.logger.trace("PerformanceClient: currentTime is less than preQueueTime, check how time is being retrieved"),0):t-e},e.prototype.addQueueMeasurement=function(e,t,n,r){if(t){if(0===n)this.logger.trace("PerformanceClient.addQueueMeasurement: queue time provided for "+e+" is "+n);else if(!n)return void this.logger.trace("PerformanceClient.addQueueMeasurement: no queue time provided for "+e);var o={eventName:e,queueTime:n,manuallyCompleted:r},i=this.queueMeasurements.get(t);if(i)i.push(o),this.queueMeasurements.set(t,i);else{this.logger.trace("PerformanceClient.addQueueMeasurement: adding correlationId "+t+" to queue measurements");var s=[o];this.queueMeasurements.set(t,s)}this.preQueueTimeByCorrelationId.delete(t)}else this.logger.trace("PerformanceClient.addQueueMeasurement: correlationId not provided for "+e+", cannot add queue measurement")},e.prototype.startMeasurement=function(e,t){var n,r,o=this,s=t||this.generateId();t||this.logger.info("PerformanceClient: No correlation id provided for "+e+", generating",s),this.logger.trace("PerformanceClient: Performance measurement started for "+e,s);var a=this.startPerformanceMeasuremeant(e,s);a.startMeasurement();var c={eventId:this.generateId(),status:Ee.InProgress,authority:this.authority,libraryName:this.libraryName,libraryVersion:this.libraryVersion,clientId:this.clientId,name:e,startTimeMs:Date.now(),correlationId:s,appName:null===(n=this.applicationTelemetry)||void 0===n?void 0:n.appName,appVersion:null===(r=this.applicationTelemetry)||void 0===r?void 0:r.appVersion};return this.cacheEventByCorrelationId(c),{endMeasurement:function(e){return o.endMeasurement(i(i({},c),e),a)},discardMeasurement:function(){return o.discardMeasurements(c.correlationId)},addStaticFields:function(e){return o.addStaticFields(e,c.correlationId)},increment:function(e){return o.increment(e,c.correlationId)},measurement:a,event:c}},e.prototype.endMeasurement=function(e,t){var n,r,o=this,s=this.eventsByCorrelationId.get(e.correlationId);if(!s)return this.logger.trace("PerformanceClient: Measurement not found for "+e.eventId,e.correlationId),null;var a=e.eventId===s.eventId,c={totalQueueTime:0,totalQueueCount:0,manuallyCompletedCount:0};a?(c=this.getQueueInfo(e.correlationId),this.discardCache(s.correlationId)):null===(n=s.incompleteSubMeasurements)||void 0===n||n.delete(e.eventId),null==t||t.endMeasurement();var u=null==t?void 0:t.flushMeasurement();if(!u)return this.logger.trace("PerformanceClient: Performance measurement not taken",s.correlationId),null;if(this.logger.trace("PerformanceClient: Performance measurement ended for "+e.name+": "+u+" ms",e.correlationId),!a)return s[e.name+"DurationMs"]=Math.floor(u),i({},s);var l=i(i({},s),e),p=0;return null===(r=l.incompleteSubMeasurements)||void 0===r||r.forEach((function(t){o.logger.trace("PerformanceClient: Incomplete submeasurement "+t.name+" found for "+e.name,l.correlationId),p++})),l.incompleteSubMeasurements=void 0,l=i(i({},l),{durationMs:Math.round(u),queuedTimeMs:c.totalQueueTime,queuedCount:c.totalQueueCount,queuedManuallyCompletedCount:c.manuallyCompletedCount,status:Ee.Completed,incompleteSubsCount:p}),this.truncateIntegralFields(l,this.getIntFields()),this.emitEvents([l],e.correlationId),l},e.prototype.addStaticFields=function(e,t){this.logger.trace("PerformanceClient: Updating static fields");var n=this.eventsByCorrelationId.get(t);n?this.eventsByCorrelationId.set(t,i(i({},n),e)):this.logger.trace("PerformanceClient: Event not found for",t)},e.prototype.increment=function(e,t){this.logger.trace("PerformanceClient: Updating counters");var n=this.eventsByCorrelationId.get(t);if(n)for(var r in e)n.hasOwnProperty(r)||(n[r]=0),n[r]+=e[r];else this.logger.trace("PerformanceClient: Event not found for",t)},e.prototype.cacheEventByCorrelationId=function(e){var t=this.eventsByCorrelationId.get(e.correlationId);t?(this.logger.trace("PerformanceClient: Performance measurement for "+e.name+" added/updated",e.correlationId),t.incompleteSubMeasurements=t.incompleteSubMeasurements||new Map,t.incompleteSubMeasurements.set(e.eventId,{name:e.name,startTimeMs:e.startTimeMs})):(this.logger.trace("PerformanceClient: Performance measurement for "+e.name+" started",e.correlationId),this.eventsByCorrelationId.set(e.correlationId,i({},e)))},e.prototype.getQueueInfo=function(e){var t=this.queueMeasurements.get(e);t||this.logger.trace("PerformanceClient: no queue measurements found for for correlationId: "+e);var n=0,r=0,o=0;return null==t||t.forEach((function(e){n+=e.queueTime,r++,o+=e.manuallyCompleted?1:0})),{totalQueueTime:n,totalQueueCount:r,manuallyCompletedCount:o}},e.prototype.discardMeasurements=function(e){this.logger.trace("PerformanceClient: Performance measurements discarded",e),this.eventsByCorrelationId.delete(e)},e.prototype.discardCache=function(e){this.discardMeasurements(e),this.logger.trace("PerformanceClient: QueueMeasurements discarded",e),this.queueMeasurements.delete(e),this.logger.trace("PerformanceClient: Pre-queue times discarded",e),this.preQueueTimeByCorrelationId.delete(e)},e.prototype.addPerformanceCallback=function(e){var t=this.generateId();return this.callbacks.set(t,e),this.logger.verbose("PerformanceClient: Performance callback registered with id: "+t),t},e.prototype.removePerformanceCallback=function(e){var t=this.callbacks.delete(e);return t?this.logger.verbose("PerformanceClient: Performance callback "+e+" removed."):this.logger.verbose("PerformanceClient: Performance callback "+e+" not removed."),t},e.prototype.emitEvents=function(e,t){var n=this;this.logger.verbose("PerformanceClient: Emitting performance events",t),this.callbacks.forEach((function(r,o){n.logger.trace("PerformanceClient: Emitting event to callback "+o,t),r.apply(null,[e])}))},e.prototype.truncateIntegralFields=function(e,t){t.forEach((function(t){t in e&&"number"==typeof e[t]&&(e[t]=Math.floor(e[t]))}))},e}(),mt=function(){function e(){}return e.prototype.startMeasurement=function(){},e.prototype.endMeasurement=function(){},e.prototype.flushMeasurement=function(){return null},e}(),vt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.prototype.generateId=function(){return"callback-id"},t.prototype.startPerformanceMeasuremeant=function(){return new mt},t.prototype.startPerformanceMeasurement=function(){return new mt},t.prototype.calculateQueuedTime=function(e,t){return 0},t.prototype.addQueueMeasurement=function(e,t,n){},t.prototype.setPreQueueTime=function(e,t){},t}(ft)},1616:function(e,t,n){"use strict";var r=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function s(e){try{c(r.next(e))}catch(e){i(e)}}function a(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(s,a)}c((r=r.apply(e,t||[])).next())}))};Object.defineProperty(t,"__esModule",{value:!0});const o=n(7571),i=n(9695),s=["redmond.corp.microsoft.com","northamerica.corp.microsoft.com","fareast.corp.microsoft.com","ntdev.corp.microsoft.com","wingroup.corp.microsoft.com","southpacific.corp.microsoft.com","wingroup.windeploy.ntdev.microsoft.com","ddnet.microsoft.com","europe.corp.microsoft.com"],a={"common.msftInternal":function(){const e=process.env.USERDNSDOMAIN;if(!e)return!1;const t=e.toLowerCase();return s.some((e=>t===e))}()?1:0},c={};try{const e=n(235);c["common.adsversion"]=null==e?void 0:e.version}catch(e){}class u{constructor(e,t,n,r){this.reporter=e,this.eventName=t,this.properties=n,this.measurements=r,this.properties=n||{},Object.assign(this.properties,c),this.measurements=r||{},Object.assign(this.measurements,a)}send(){var e;try{null===(e=this.reporter)||void 0===e||e.sendTelemetryEvent(this.eventName,this.properties,this.measurements)}catch(e){const t=e instanceof Error?e.message:e;console.error(`Error sending ${this.eventName} event ${t}`)}}withAdditionalProperties(e){return Object.assign(this.properties,e),this}withAdditionalMeasurements(e){return Object.assign(this.measurements,e),this}withConnectionInfo(e){return"object"==typeof e?Object.assign(this.properties,{authenticationType:e.authenticationType,providerName:e.providerName}):console.error("AdsTelemetryReporter received invalid ConnectionInfo object of type "+typeof e),this}withServerInfo(e){var t,n,r;return"object"==typeof e?Object.assign(this.properties,{connectionType:void 0!==e.isCloud?e.isCloud?"Azure":"Standalone":"",serverVersion:null!==(t=e.serverVersion)&&void 0!==t?t:"",serverEdition:null!==(n=e.serverEdition)&&void 0!==n?n:"",serverEngineEdition:null!==(r=e.engineEditionId)&&void 0!==r?r:""}):console.error("AdsTelemetryReporter received invalid ServerInfo object of type "+typeof e),this}}t.default=class{constructor(e,t,n){var r,i;this._telemetryReporter=void 0;try{this._telemetryReporter=new o.default(e,t,n)}catch(t){console.error(`Error initializing TelemetryReporter for '${e}'. ${null!==(i=null===(r=t)||void 0===r?void 0:r.message)&&void 0!==i?i:t}`)}}createViewEvent(e){return new u(this._telemetryReporter,"view",{view:e})}sendViewEvent(e){this.createViewEvent(e).send()}createActionEvent(e,t,n="",r="",o){const i=o?{durationInMs:o}:{};return new u(this._telemetryReporter,"action",{view:e,action:t,target:n,source:r},i)}sendActionEvent(e,t,n="",r="",o){this.createActionEvent(e,t,n,r,o).send()}createTimedAction(e,t,n,r){return new i.TimedAction(this,e,t,n,r)}createMetricsEvent(e,t=""){return new u(this._telemetryReporter,"metrics",{groupName:t},e)}sendMetricsEvent(e,t=""){this.createMetricsEvent(e,t).send()}createErrorEvent(e,t,n="",r=""){return new u(this._telemetryReporter,"error",{view:e,name:t,errorCode:n,errorType:r})}sendErrorEvent(e,t,n="",r=""){this.createErrorEvent(e,t,n,r).send()}createErrorEvent2(e,t,n=void 0,r=!1,o="",i=""){const s={view:e,name:t,errorCode:o,errorType:i};if(n instanceof Error){s.message=!0===r?n.message:"";let e=n.stack||"";if(!0!==r&&n.message){const t=new RegExp(n.message,"g");e=e.replace(t,"<REDACTED: error-message>")}s.stack=e}else s.message=!0===r?null==n?void 0:n.toString():"",s.stack="";return new u(this._telemetryReporter,"error",s)}sendErrorEvent2(e,t,n=void 0,r=!1,o="",i=""){this.createErrorEvent2(e,t,n,r,o,i).send()}createTelemetryEvent(e,t,n){return new u(this._telemetryReporter,e,t,n)}sendTelemetryEvent(e,t,n){this.createTelemetryEvent(e,t,n).send()}dispose(){var e;return r(this,void 0,void 0,(function*(){yield null===(e=this._telemetryReporter)||void 0===e?void 0:e.dispose()}))}}},9695:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TimedAction=void 0,t.TimedAction=class{constructor(e,t,n,r="",o=""){this.reporter=e,this.view=t,this.action=n,this.target=r,this.source=o,this.properties={},this.measures={},this.start=Date.now()}withAdditionalProperties(e){return Object.assign(this.properties,e),this}withAdditionalMeasures(e){return Object.assign(this.measures,e),this}send(){this.reporter.createActionEvent(this.view,this.action,this.source,this.target,Date.now()-this.start).withAdditionalProperties(this.properties).withAdditionalMeasurements(this.measures).send()}}},2391:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,{signal:n}={}){return new Promise(((r,o)=>{function i(){null==n||n.removeEventListener("abort",i),e.removeListener(t,s),e.removeListener("error",a)}function s(...e){i(),r(e)}function a(e){i(),o(e)}null==n||n.addEventListener("abort",i),e.on(t,s),e.on("error",a)}))}},7571:(e,t,n)=>{var r,o,i,s,a=Object.create,c=Object.defineProperty,u=Object.defineProperties,l=Object.getOwnPropertyDescriptor,p=Object.getOwnPropertyDescriptors,d=Object.getOwnPropertyNames,h=Object.getOwnPropertySymbols,f=Object.getPrototypeOf,m=Object.prototype.hasOwnProperty,v=Object.prototype.propertyIsEnumerable,g=(e,t,n)=>t in e?c(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,y=(e,t)=>{for(var n in t||(t={}))m.call(t,n)&&g(e,n,t[n]);if(h)for(var n of h(t))v.call(t,n)&&g(e,n,t[n]);return e},_=(e,t)=>u(e,p(t)),b=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),E=(e,t,n,r)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let o of d(t))!m.call(e,o)&&o!==n&&c(e,o,{get:()=>t[o],enumerable:!(r=l(t,o))||r.enumerable});return e},T=(e,t,n)=>(n=null!=e?a(f(e)):{},E(!t&&e&&e.__esModule?n:c(n,"default",{value:e,enumerable:!0}),e)),S=b(((n,s)=>{var a;a=function(e){"use strict";var t="function",n="object",r="undefined",o="prototype",i="hasOwnProperty",s="default",a=Object,c=a[o],u=a.assign,l=a.create,p=a.defineProperty,d=c[i],h=null;function f(e){return void 0===e&&(e=!0),(!h||!e)&&(typeof globalThis!==r&&globalThis&&(h=globalThis),typeof self!==r&&self&&(h=self),typeof window!==r&&window&&(h=window),typeof global!==r&&global&&(h=global)),h}function m(e){throw new TypeError(e)}function v(e){if(l)return l(e);if(null==e)return{};var r=typeof e;function i(){}return r!==n&&r!==t&&m("Object prototype may only be an Object:"+e),i[o]=e,new i}var g=(f()||{}).Symbol,y=(f()||{}).Reflect,_=!!y,b="decorate",E="metadata",T="getOwnPropertySymbols",S="iterator",C=u||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])c[i].call(t,o)&&(e[o]=t[o]);return e},x=function(e,t){return(x=a.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t[i](n)&&(e[n]=t[n])})(e,t)};function w(e,n){function r(){this.constructor=e}typeof n!==t&&null!==n&&m("Class extends value "+String(n)+" is not a constructor or null"),x(e,n),e[o]=null===n?v(n):(r[o]=n[o],new r)}function A(e,t,n,r){void 0===r&&(r=n),l?p(e,r,{enumerable:!0,get:function(){return t[n]}}):e[r]=t[n]}e.ObjAssign=u,e.ObjClass=a,e.ObjCreate=l,e.ObjDefineProperty=p,e.ObjHasOwnProperty=d,e.ObjProto=c,e.__assignFn=C,e.__createBindingFn=A,e.__decorateFn=function(e,n,r,o){var i,s=arguments.length,c=s<3?n:null===o?o=a.getOwnPropertyDescriptor(n,r):o;if(_&&typeof y[b]===t)c=y[b](e,n,r,o);else for(var u=e.length-1;u>=0;u--)(i=e[u])&&(c=(s<3?i(c):s>3?i(n,r,c):i(n,r))||c);return s>3&&c&&p(n,r,c),c},e.__exportStarFn=function(e,t){for(var n in e)n!==s&&!d.call(t,n)&&A(t,e,n)},e.__exposeGlobalTsLib=function(){var e,t,n,r,o=f()||{};t=C,n=w,r=A,(e=o).__assign||(e.__assign=u||t),e.__extends||(e.__extends=n),e.__createBinding||(e.__createBinding=r),__assign||(__assign=o.__assign),__extends||(__extends=o.__extends),__createBinding||(__createBinding=o.__createBinding)},e.__extendsFn=w,e.__importDefaultFn=function(e){return e&&e.__esModule?e:{strDefault:e}},e.__importStarFn=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)n!==s&&Object.prototype.hasOwnProperty.call(e,n)&&A(t,e,n);return l?p(t,s,{enumerable:!0,value:e}):t[s]=e,t},e.__makeTemplateObjectFn=function(e,t){return p?p(e,"raw",{value:t}):e.raw=t,e},e.__metadataFn=function(e,n){if(_&&y[E]===t)return y[E](e,n)},e.__paramFn=function(e,t){return function(n,r){t(n,r,e)}},e.__readFn=function(e,n){var r=typeof g===t&&e[g[S]];if(!r)return e;var o,i,s=r.call(e),a=[];try{for(;(void 0===n||n-- >0)&&!(o=s.next()).done;)a.push(o.value)}catch(e){i={error:e}}finally{try{o&&!o.done&&(r=s.return)&&r.call(s)}finally{if(i)throw i.error}}return a},e.__restFn=function(e,n){var r={};for(var o in e)d.call(e,o)&&n.indexOf(o)<0&&(r[o]=e[o]);if(null!=e&&typeof a[T]===t)for(var i=0,s=a[T](e);i<s.length;i++)n.indexOf(s[i])<0&&c.propertyIsEnumerable.call(e,s[i])&&(r[s[i]]=e[s[i]]);return r},e.__spreadArrayFn=function(e,t){for(var n=0,r=t.length,o=e.length;n<r;n++,o++)e[o]=t[n];return e},e.__spreadArraysFn=function(){for(var e=arguments,t=0,n=0,r=e.length;n<r;n++)t+=e[n].length;var o=Array(t),i=0;for(n=0;n<r;n++)for(var s=e[n],a=0,c=s.length;a<c;a++,i++)o[i]=s[a];return o},e.__valuesFn=function(e){var n=typeof g===t&&g[S],r=n&&e[n],o=0;return r?r.call(e):e&&"number"==typeof e.length?{next:function(){return e&&o>=e.length&&(e=void 0),{value:e&&e[o++],done:!e}}}:void m(n?"Object is not iterable.":"Symbol.iterator is not defined.")},e.getGlobal=f,e.objCreateFn=v,e.strDefault=s,e.strShimFunction=t,e.strShimHasOwnProperty=i,e.strShimObject=n,e.strShimPrototype=o,e.strShimUndefined=r,e.throwTypeError=m,function(e,t,n){var r=Object.defineProperty;if(r)try{return r(e,t,n)}catch{}n&&void 0!==typeof n.value&&(e[t]=n.value)}(e,"__esModule",{value:!0})},"object"==typeof n&&typeof s<"u"?a(n):(o=[t],void 0===(i="function"==typeof(r=a)?r.apply(t,o):r)||(e.exports=i))})),C=b(((n,s)=>{var a;a=function(e){"use strict";var t="function",n="object",r="undefined",o="prototype",i="hasOwnProperty",s=Object,a=s[o],c=s.assign,u=s.create,l=s.defineProperty,p=a[i],d=null;function h(e){return void 0===e&&(e=!0),(!d||!e)&&(typeof globalThis!==r&&globalThis&&(d=globalThis),typeof self!==r&&self&&(d=self),typeof window!==r&&window&&(d=window),typeof global!==r&&global&&(d=global)),d}function f(e){throw new TypeError(e)}function m(e){if(u)return u(e);if(null==e)return{};var r=typeof e;function i(){}return r!==n&&r!==t&&f("Object prototype may only be an Object:"+e),i[o]=e,new i}(h()||{}).Symbol,(h()||{}).Reflect;var v=function(e,t){return(v=s.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t[i](n)&&(e[n]=t[n])})(e,t)};function g(e,n){function r(){this.constructor=e}typeof n!==t&&null!==n&&f("Class extends value "+String(n)+" is not a constructor or null"),v(e,n),e[o]=null===n?m(n):(r[o]=n[o],new r)}function y(e,t){for(var n=0,r=t.length,o=e.length;n<r;n++,o++)e[o]=t[n];return e}var _="",b="processTelemetry",E="priority",T="setNextPlugin",S="isInitialized",C="teardown",x="core",w="update",A="disabled",I="_doTeardown",R="processNext",P="resume",O="pause",N="NotificationListener",k="add"+N,D="remove"+N,M="eventsSent",L="eventsDiscarded",j="eventsSendRequest",U="perfEvent",F="toISOString",z="endsWith",q="startsWith",B="indexOf",H="reduce",G="trim",V="toString",$="__proto__",K="constructor",W=l,Q=s.freeze,Y=s.seal,X=s.keys,J=String[o],Z=J[G],ee=J[z],te=J[q],ne=Date[o][F],re=Array.isArray,oe=a[V],ie=p[V],se=ie.call(s),ae=/-([a-z])/g,ce=/([^\w\d_$])/g,ue=/^(\d+[\w\d_$])/,le=Object.getPrototypeOf;function pe(e){if(e){if(le)return le(e);var t=e[$]||e[o]||e[K];if(t)return t}return null}function de(e,t){return typeof e===t}function he(e){return void 0===e||typeof e===r}function fe(e){return null===e||he(e)}function me(e){return!fe(e)}function ve(e,t){return!(!e||!p.call(e,t))}function ge(e){return!(!e||typeof e!==n)}function ye(e){return!(!e||typeof e!==t)}function _e(e){var t=e;return t&&we(t)&&(t=(t=(t=t.replace(ae,(function(e,t){return t.toUpperCase()}))).replace(ce,"_")).replace(ue,(function(e,t){return"_"+t}))),t}function be(e,t){if(e)for(var n in e)p.call(e,n)&&t.call(e,n,e[n])}function Ee(e,t){var n=!1;return e&&t&&!(n=e===t)&&(n=ee?e[z](t):function(e,t){var n=!1,r=t?t.length:0,o=e?e.length:0;if(r&&o&&o>=r&&!(n=e===t)){for(var i=o-1,s=r-1;s>=0;s--){if(e[i]!=t[s])return!1;i--}n=!0}return n}(e,t)),n}function Te(e,t){return!(!e||!t)&&-1!==e.indexOf(t)}function Se(e){return!(!e||"[object Date]"!==oe.call(e))}var Ce=re||function(e){return!(!e||"[object Array]"!==oe.call(e))};function xe(e){return!(!e||"[object Error]"!==oe.call(e))}function we(e){return"string"==typeof e}function Ae(e){return"number"==typeof e}function Ie(e){return"boolean"==typeof e}function Re(e){var n=!1;if(e&&"object"==typeof e){var r=le?le(e):pe(e);r?(r[K]&&p.call(r,K)&&(r=r[K]),n=typeof r===t&&ie.call(r)===se):n=!0}return n}function Pe(e){if(e)return ne?e[F]():function(e){if(e&&e.getUTCFullYear){var t=function(e){var t=String(e);return 1===t.length&&(t="0"+t),t};return e.getUTCFullYear()+"-"+t(e.getUTCMonth()+1)+"-"+t(e.getUTCDate())+"T"+t(e.getUTCHours())+":"+t(e.getUTCMinutes())+":"+t(e.getUTCSeconds())+"."+String((e.getUTCMilliseconds()/1e3).toFixed(3)).slice(2,5)+"Z"}}(e)}function Oe(e,t,n){var r=e.length;try{for(var o=0;o<r&&(!(o in e)||-1!==t.call(n||e,e[o],o,e));o++);}catch{}}function Ne(e,t,n){if(e){if(e[B])return e[B](t,n);var r=e.length,o=n||0;try{for(var i=Math.max(o>=0?o:r-Math.abs(o),0);i<r;i++)if(i in e&&e[i]===t)return i}catch{}}return-1}function ke(e,t,n){var r;if(e){if(e.map)return e.map(t,n);var o=e.length,i=n||e;r=new Array(o);try{for(var s=0;s<o;s++)s in e&&(r[s]=t.call(i,e[s],e))}catch{}}return r}function De(e,t,n){var r;if(e){if(e[H])return e[H](t,n);var o=e.length,i=0;if(arguments.length>=3)r=arguments[2];else{for(;i<o&&!(i in e);)i++;r=e[i++]}for(;i<o;)i in e&&(r=t(r,e[i],i,e)),i++}return r}function Me(e){return e&&(e=Z&&e[G]?e[G]():e.replace?e.replace(/^\s+|\s+$/g,""):e),e}var Le=!{toString:null}.propertyIsEnumerable("toString"),je=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"];function Ue(e){var r=typeof e;if(r!==t&&(r!==n||null===e)&&f("objKeys called on non-object"),!Le&&X)return X(e);var o=[];for(var i in e)e&&p.call(e,i)&&o.push(i);if(Le)for(var s=je.length,a=0;a<s;a++)e&&p.call(e,je[a])&&o.push(je[a]);return o}function Fe(e,t,n,r){if(W)try{var o={enumerable:!0,configurable:!0};return n&&(o.get=n),r&&(o.set=r),W(e,t,o),!0}catch{}return!1}function ze(e){return e}function qe(e){return Q&&be(e,(function(e,t){(Ce(t)||ge(t))&&Q(t)})),Be(e)}var Be=Q||ze,He=Y||ze;function Ge(){var e=Date;return e.now?e.now():(new e).getTime()}function Ve(e){return xe(e)?e.name:_}function $e(e,t,n,r,o){var i=n;return e&&(i=e[t])!==n&&(!o||o(i))&&(!r||r(n))&&(i=n,e[t]=i),i}function Ke(e,t,n){var r;return e?!(r=e[t])&&fe(r)&&(r=he(n)?{}:n,e[t]=r):r=he(n)?{}:n,r}function We(e){return!e}function Qe(e){return!!e}function Ye(e){throw new Error(e)}function Xe(e,t){var n=null,r=null;return ye(e)?n=e:r=e,function(){var e=arguments;if(n&&(r=n()),r)return r[t].apply(r,e)}}function Je(e,t,n,r,o){e&&t&&n&&(!1!==o||he(e[t]))&&(e[t]=Xe(n,r))}function Ze(e,t,n,r){return e&&t&&ge(e)&&Ce(n)&&Oe(n,(function(n){we(n)&&Je(e,n,t,n,r)})),e}function et(e,t,n,r,o,i){var s=arguments,a=s[0]||{},c=s.length,u=!1,l=1;for(c>0&&Ie(a)&&(u=a,a=s[l]||{},l++),ge(a)||(a={});l<c;l++){var d=s[l],h=Ce(d),f=ge(d);for(var m in d)if(h&&m in d||f&&p.call(d,m)){var v=d[m],g=void 0;if(u&&v&&((g=Ce(v))||Re(v))){var y=a[m];g?Ce(y)||(y=[]):Re(y)||(y={}),v=et(u,y,v)}void 0!==v&&(a[m]=v)}}return a}function tt(e){var t={};return be(e,(function(e,n){t[e]=n,t[n]=e})),qe(t)}var nt=tt({Unknown:0,NonRetryableStatus:1,InvalidEvent:2,SizeLimitExceeded:3,KillSwitch:4,QueueFull:5}),rt="constructor",ot="prototype",it="function",st="_dynInstFuncs",at="_isDynProxy",ct="_dynClass",ut="_dynInstChk",lt=ut,pt="_dfOpts",dt="_unknown_",ht="__proto__",ft="_dyn"+ht,mt="_dynInstProto",vt="useBaseInst",gt="setInstFuncs",yt=Object,_t=yt.getPrototypeOf,bt=yt.getOwnPropertyNames,Et=0;function Tt(e,t){return e&&yt[ot].hasOwnProperty.call(e,t)}function St(e){return e&&(e===yt[ot]||e===Array[ot])}function Ct(e){return St(e)||e===Function[ot]}function xt(e){var t;if(e){if(_t)return _t(e);var n=e[ht]||e[ot]||(e[rt]?e[rt][ot]:null);t=e[ft]||n,Tt(e,ft)||(delete e[mt],t=e[ft]=e[mt]||e[ft],e[mt]=n)}return t}function wt(e,t){var n=[];if(bt)n=bt(e);else for(var r in e)"string"==typeof r&&Tt(e,r)&&n.push(r);if(n&&n.length>0)for(var o=0;o<n.length;o++)t(n[o])}function At(e,t,n){return t!==rt&&typeof e[t]===it&&(n||Tt(e,t))}function It(e){throw new TypeError("DynamicProto: "+e)}function Rt(e,t){for(var n=e.length-1;n>=0;n--)if(e[n]===t)return!0;return!1}function Pt(e,t,n,r,o){if(!St(e)){var i=n[st]=n[st]||{},s=i[t]=i[t]||{};!1!==i[lt]&&(i[lt]=!!o),wt(n,(function(t){At(n,t,!1)&&n[t]!==r[t]&&(s[t]=n[t],delete n[t],(!Tt(e,t)||e[t]&&!e[t][at])&&(e[t]=function(e,t){var n=function(){var r=function(e,t,n,r){var o=null;if(e&&Tt(n,ct)){var i=e[st]||{};if((o=(i[n[ct]]||{})[t])||It("Missing ["+t+"] "+it),!o[ut]&&!1!==i[lt]){for(var s=!Tt(e,t),a=xt(e),c=[];s&&a&&!Ct(a)&&!Rt(c,a);){var u=a[t];if(u){s=u===r;break}c.push(a),a=xt(a)}try{s&&(e[t]=o),o[ut]=1}catch{i[lt]=!1}}}return o}(this,t,e,n)||function(e,t,n){var r=t[e];return r===n&&(r=xt(t)[e]),typeof r!==it&&It("["+e+"] is not a "+it),r}(t,e,n);return r.apply(this,arguments)};return n[at]=1,n}(e,t)))}))}}function Ot(e,t){return Tt(e,ot)?e.name||t||dt:((e||{})[rt]||{}).name||t||dt}function Nt(e,t,n,r){Tt(e,ot)||It("theClass is an invalid class definition.");var o=e[ot];(function(e,t){if(_t){for(var n=[],r=xt(t);r&&!Ct(r)&&!Rt(n,r);){if(r===e)return!0;n.push(r),r=xt(r)}return!1}return!0})(o,t)||It("["+Ot(e)+"] is not in class hierarchy of ["+Ot(t)+"]");var i=null;Tt(o,ct)?i=o[ct]:(i="_dynCls$"+Ot(e,"_")+"$"+Et,Et++,o[ct]=i);var s=Nt[pt],a=!!s[vt];a&&r&&void 0!==r[vt]&&(a=!!r[vt]);var c=function(e){var t={};return wt(e,(function(n){!t[n]&&At(e,n,!1)&&(t[n]=e[n])})),t}(t),u=function(e,t,n,r){function o(e,t,n){var o=t[n];if(o[at]&&r){var i=e[st]||{};!1!==i[lt]&&(o=(i[t[ct]]||{})[n]||o)}return function(){return o.apply(e,arguments)}}var i={};wt(n,(function(e){i[e]=o(t,n,e)}));for(var s=xt(e),a=[];s&&!Ct(s)&&!Rt(a,s);)wt(s,(function(e){!i[e]&&At(s,e,!_t)&&(i[e]=o(t,s,e))})),a.push(s),s=xt(s);return i}(o,t,c,a);n(t,u);var l=!!_t&&!!s[gt];l&&r&&(l=!!r[gt]),Pt(o,i,t,c,!1!==l)}Nt[pt]={setInstFuncs:!0,useBaseInst:!0};var kt="window",Dt="document",Mt="navigator",Lt="location",jt="console",Ut="performance",Ft="JSON",zt="crypto",qt="msCrypto",Bt="msie",Ht="trident/",Gt="XMLHttpRequest",Vt=null,$t=null,Kt=!1,Wt=null,Qt=null;function Yt(e,t){var n=!1;if(e){try{if(!(n=t in e)){var r=e[o];r&&(n=t in r)}}catch{}if(!n)try{n=!he((new e)[t])}catch{}}return n}function Xt(e){var t=h();return t&&t[e]?t[e]:e===kt&&Jt()?window:null}function Jt(){return Boolean(typeof window===n&&window)}function Zt(){return Jt()?window:Xt(kt)}function en(){return Boolean(typeof document===n&&document)}function tn(){return en()?document:Xt(Dt)}function nn(){return Boolean(typeof navigator===n&&navigator)}function rn(){return nn()?navigator:Xt(Mt)}function on(){return Boolean(typeof history===n&&history)}function sn(e){if(e&&Kt){var t=Xt("__mockLocation");if(t)return t}return typeof location===n&&location?location:Xt(Lt)}function an(){return typeof console!==r?console:Xt(jt)}function cn(){return Xt(Ut)}function un(){return Boolean(typeof JSON===n&&JSON||null!==Xt(Ft))}function ln(){return un()?JSON||Xt(Ft):null}function pn(){return Xt(zt)}function dn(){return Xt(qt)}function hn(){var e=rn();if(e&&(e.userAgent!==$t||null===Vt)){var t=(($t=e.userAgent)||_).toLowerCase();Vt=Te(t,Bt)||Te(t,Ht)}return Vt}function fn(e){var t=Object[o].toString.call(e),n=_;return"[object Error]"===t?n="{ stack: '"+e.stack+"', message: '"+e.message+"', name: '"+e.name+"'":un()&&(n=ln().stringify(e)),t+n}function mn(){var e=!1;try{e=!!Xt(Gt)}catch{}return e}function vn(e,t){if(e)for(var n=0;n<e.length;n++){var r=e[n];if(r.name&&r.name===t)return r}return{}}function gn(e){var t=tn();return t&&e?vn(t.querySelectorAll("meta"),e).content:null}function yn(e){var t,n=cn();if(n){var r=n.getEntriesByType("navigation")||[];t=vn((r.length>0?r[0]:{}).serverTiming,e).description}return t}var _n,bn=["eventsSent","eventsDiscarded","eventsSendRequest","perfEvent"],En=null;function Tn(e,t){return function(){var n=arguments,r=Sn(t);if(r){var o=r.listener;o&&o[e]&&o[e].apply(o,n)}}}function Sn(e){var t=En;return!t&&!0!==e.disableDbgExt&&(t=En||function(){var e=Xt("Microsoft");return e&&(En=e.ApplicationInsights),En}()),t?t.ChromeDbgExt:null}function Cn(e){if(!_n){_n={};for(var t=0;t<bn.length;t++)_n[bn[t]]=Tn(bn[t],e)}return _n}function xn(e){return e?'"'+e.replace(/\"/g,_)+'"':_}function wn(e,t){var n=an();if(n){var r="log";n[e]&&(r=e),ye(n[r])&&n[r](t)}}var An=function(){function e(e,t,n,r){void 0===n&&(n=!1);var o=this;o.messageId=e,o.message=(n?"AI: ":"AI (Internal): ")+e;var i=_;un()&&(i=ln().stringify(r));var s=(t?" message:"+xn(t):_)+(r?" props:"+xn(i):_);o.message+=s}return e.dataType="MessageData",e}();function In(e,t){return(e||{}).logger||new Rn(t)}var Rn=function e(t){this.identifier="DiagnosticLogger",this.queue=[];var n=0,r={};Nt(e,this,(function(e){function o(e,n){var r=t[e];return fe(r)?n:r}function i(e,n){var r=Sn(t);r&&r.diagLog&&r.diagLog(e,n)}fe(t)&&(t={}),e.consoleLoggingLevel=function(){return o("loggingLevelConsole",0)},e.telemetryLoggingLevel=function(){return o("loggingLevelTelemetry",1)},e.maxInternalMessageLimit=function(){return o("maxMessageLimit",25)},e.enableDebugExceptions=function(){return o("enableDebugExceptions",!1)},e.throwInternal=function(t,n,o,s,a){void 0===a&&(a=!1);var c=new An(n,o,a,s);if(e.enableDebugExceptions())throw fn(c);var u=1===t?"errorToConsole":"warnToConsole";if(he(c.message))i("throw"+(1===t?"Critical":"Warning"),c);else{var l=e.consoleLoggingLevel();if(a){var p=+c.messageId;!r[p]&&l>=t&&(e[u](c.message),r[p]=!0)}else l>=t&&e[u](c.message);e.logInternalMessage(t,c)}},e.warnToConsole=function(e){wn("warn",e),i("warning",e)},e.errorToConsole=function(e){wn("error",e),i("error",e)},e.resetInternalMessageCount=function(){n=0,r={}},e.logInternalMessage=function(t,o){if(!(n>=e.maxInternalMessageLimit())){var s=!0,a="AITR_"+o.messageId;if(r[a]?s=!1:r[a]=!0,s&&(t<=e.telemetryLoggingLevel()&&(e.queue.push(o),n++,i(1===t?"error":"warn",o)),n===e.maxInternalMessageLimit())){var c="Internal events throttle limit per PageView reached for this app.",u=new An(23,c,!1);e.queue.push(u),1===t?e.errorToConsole(c):e.warnToConsole(c)}}}}))};function Pn(e){return e||new Rn}function On(e,t,n,r,o,i){void 0===i&&(i=!1),(e||new Rn).throwInternal(t,n,r,o,i)}function Nn(e,t){Pn(e).warnToConsole(t)}var kn="ctx",Dn=null,Mn=function(){function e(t,n,r){var o,i=this,s=!1;i.start=Ge(),i.name=t,i.isAsync=r,i.isChildEvt=function(){return!1},ye(n)&&(s=Fe(i,"payload",(function(){return!o&&ye(n)&&(o=n(),n=null),o}))),i.getCtx=function(t){return t?t===e.ParentContextKey||t===e.ChildrenContextKey?i[t]:(i[kn]||{})[t]:null},i.setCtx=function(t,n){t&&(t===e.ParentContextKey?(i[t]||(i.isChildEvt=function(){return!0}),i[t]=n):t===e.ChildrenContextKey?i[t]=n:(i[kn]=i[kn]||{})[t]=n)},i.complete=function(){var t=0,r=i.getCtx(e.ChildrenContextKey);if(Ce(r))for(var o=0;o<r.length;o++){var a=r[o];a&&(t+=a.time)}i.time=Ge()-i.start,i.exTime=i.time-t,i.complete=function(){},!s&&ye(n)&&(i.payload=n())}}return e.ParentContextKey="parent",e.ChildrenContextKey="childEvts",e}(),Ln=function e(t){this.ctx={},Nt(e,this,(function(e){e.create=function(e,t,n){return new Mn(e,t,n)},e.fire=function(e){e&&(e.complete(),t&&ye(t.perfEvent)&&t.perfEvent(e))},e.setCtx=function(t,n){t&&((e[kn]=e[kn]||{})[t]=n)},e.getCtx=function(t){return(e[kn]||{})[t]}}))},jn="CoreUtils.doPerf";function Un(e,t,n,r,o){if(e){var i=e;if(ye(i.getPerfMgr)&&(i=i.getPerfMgr()),i){var s=void 0,a=i.getCtx(jn);try{if(s=i.create(t(),r,o)){if(a&&s.setCtx&&(s.setCtx(Mn.ParentContextKey,a),a.getCtx&&a.setCtx)){var c=a.getCtx(Mn.ChildrenContextKey);c||(c=[],a.setCtx(Mn.ChildrenContextKey,c)),c.push(s)}return i.setCtx(jn,s),n(s)}}catch(e){s&&s.setCtx&&s.setCtx("exception",e)}finally{s&&i.fire(s),i.setCtx(jn,a)}}}return n()}function Fn(){return Dn}var zn=4294967296,qn=4294967295,Bn=!1,Hn=123456789,Gn=987654321;function Vn(e){e<0&&(e>>>=0),Hn=123456789+e&qn,Gn=987654321-e&qn,Bn=!0}function $n(){try{var e=2147483647&Ge();Vn((Math.random()*zn^e)+e)}catch{}}function Kn(e){return e>0?Math.floor(Wn()/qn*(e+1))>>>0:0}function Wn(e){var t=0,n=pn()||dn();return n&&n.getRandomValues&&(t=n.getRandomValues(new Uint32Array(1))[0]&qn),0===t&&hn()&&(Bn||$n(),t=Yn()&qn),0===t&&(t=Math.floor(zn*Math.random()|0)),e||(t>>>=0),t}function Qn(e){e?Vn(e):$n()}function Yn(e){var t=((Gn=36969*(65535&Gn)+(Gn>>16)&qn)<<16)+(65535&(Hn=18e3*(65535&Hn)+(Hn>>16)&qn))>>>0&qn;return e||(t>>>=0),t}function Xn(e){void 0===e&&(e=22);for(var t=Wn()>>>0,n=0,r=_;r.length<e;)n++,r+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(63&t),t>>>=6,5===n&&(t=(Wn()<<2&4294967295|3&t)>>>0,n=0);return r}var Jn=l,Zn="2.8.4",er="."+Xn(6),tr=0;function nr(e){return 1===e.nodeType||9===e.nodeType||!+e.nodeType}function rr(e,t){return void 0===t&&(t=!1),_e(e+tr+++(t?"."+Zn:"")+er)}function or(e){var t={id:rr("_aiData-"+(e||"")+"."+Zn),accept:function(e){return nr(e)},get:function(e,n,r,o){var i=e[t.id];return i?i[_e(n)]:(o&&((i=function(e,t){var n=t[e.id];if(!n){n={};try{nr(t)&&(function(e,t,n){if(Jn)try{return Jn(e,t,{value:n,enumerable:!1,configurable:!0}),!0}catch{}return!1}(t,e.id,n)||(t[e.id]=n))}catch{}}return n}(t,e))[_e(n)]=r),r)},kill:function(e,t){if(e&&e[t])try{delete e[t]}catch{}}};return t}var ir="toGMTString",sr="toUTCString",ar="cookie",cr="expires",ur="enabled",lr="isCookieUseDisabled",pr="disableCookiesUsage",dr="_ckMgr",hr=null,fr=null,mr=null,vr=tn(),gr={},yr={};function _r(e,t){var n=Er[dr]||yr[dr];return n||(n=Er[dr]=Er(e,t),yr[dr]=n),n}function br(e){return!e||e.isEnabled()}function Er(e,t){var n=function(e){var t=e.cookieCfg=e.cookieCfg||{};if($e(t,"domain",e.cookieDomain,me,fe),$e(t,"path",e.cookiePath||"/",null,fe),fe(t[ur])){var n=void 0;he(e[lr])||(n=!e[lr]),he(e[pr])||(n=!e[pr]),t[ur]=n}return t}(e||yr),r=n.path||"/",o=n.domain,i=!1!==n[ur],s={isEnabled:function(){var e=i&&Tr(t),n=yr[dr];return e&&n&&s!==n&&(e=br(n)),e},setEnabled:function(e){i=!1!==e},set:function(e,t,i,a,c){var u=!1;if(br(s)){var l={},p=Me(t||_),d=p.indexOf(";");if(-1!==d&&(p=Me(t.substring(0,d)),l=Sr(t.substring(d+1))),$e(l,"domain",a||o,Qe,he),!fe(i)){var h=hn();if(he(l[cr])){var f=Ge()+1e3*i;if(f>0){var m=new Date;m.setTime(f),$e(l,cr,Cr(m,h?ir:sr)||Cr(m,h?ir:sr)||_,Qe)}}h||$e(l,"max-age",_+i,null,he)}var v=sn();v&&"https:"===v.protocol&&($e(l,"secure",null,null,he),null===fr&&(fr=!Ir((rn()||{}).userAgent)),fr&&$e(l,"SameSite","None",null,he)),$e(l,"path",c||r,null,he),(n.setCookie||Ar)(e,xr(p,l)),u=!0}return u},get:function(e){var t=_;return br(s)&&(t=(n.getCookie||wr)(e)),t},del:function(e,t){var n=!1;return br(s)&&(n=s.purge(e,t)),n},purge:function(e,r){var o,i=!1;if(Tr(t)){var s=((o={}).path=r||"/",o[cr]="Thu, 01 Jan 1970 00:00:01 GMT",o);hn()||(s["max-age"]="0"),(n.delCookie||Ar)(e,xr(_,s)),i=!0}return i}};return s[dr]=s,s}function Tr(e){if(null===hr){hr=!1;try{hr=void 0!==(vr||{})[ar]}catch(t){On(e,2,68,"Cannot access document.cookie - "+Ve(t),{exception:fn(t)})}}return hr}function Sr(e){var t={};return e&&e.length&&Oe(Me(e).split(";"),(function(e){if(e=Me(e||_)){var n=e.indexOf("=");-1===n?t[e]=null:t[Me(e.substring(0,n))]=Me(e.substring(n+1))}})),t}function Cr(e,t){return ye(e[t])?e[t]():null}function xr(e,t){var n=e||_;return be(t,(function(e,t){n+="; "+e+(fe(t)?_:"="+t)})),n}function wr(e){var t=_;if(vr){var n=vr[ar]||_;mr!==n&&(gr=Sr(n),mr=n),t=Me(gr[e]||_)}return t}function Ar(e,t){vr&&(vr[ar]=e+"="+t)}function Ir(e){return!!we(e)&&!!(Te(e,"CPU iPhone OS 12")||Te(e,"iPad; CPU OS 12")||Te(e,"Macintosh; Intel Mac OS X 10_14")&&Te(e,"Version/")&&Te(e,"Safari")||Te(e,"Macintosh; Intel Mac OS X 10_14")&&Ee(e,"AppleWebKit/605.1.15 (KHTML, like Gecko)")||Te(e,"Chrome/5")||Te(e,"Chrome/6")||Te(e,"UnrealEngine")&&!Te(e,"Chrome")||Te(e,"UCBrowser/12")||Te(e,"UCBrowser/11"))}var Rr="on",Pr="attachEvent",Or="addEventListener",Nr="detachEvent",kr="removeEventListener",Dr="events",Mr="visibilitychange",Lr="pagehide",jr="pageshow",Ur="unload",Fr="beforeunload",zr=rr("aiEvtPageHide"),qr=rr("aiEvtPageShow"),Br=/\.[\.]+/g,Hr=/[\.]+$/,Gr=1,Vr=or("events"),$r=/^([^.]*)(?:\.(.+)|)/;function Kr(e){return e&&e.replace?e.replace(/^\s*\.*|\.*\s*$/g,""):e}function Wr(e,t){if(t){var n="";Ce(t)?(n="",Oe(t,(function(e){(e=Kr(e))&&("."!==e[0]&&(e="."+e),n+=e)}))):n=Kr(t),n&&("."!==n[0]&&(n="."+n),e=(e||"")+n)}var r=$r.exec(e||"")||[];return{type:r[1],ns:(r[2]||"").replace(Br,".").replace(Hr,"").split(".").sort().join(".")}}function Qr(e,t,n){void 0===n&&(n=!0);var r=Vr.get(e,Dr,{},n),o=r[t];return o||(o=r[t]=[]),o}function Yr(e,t,n,r){e&&t&&t.type&&(e[kr]?e[kr](t.type,n,r):e[Nr]&&e[Nr](Rr+t.type,n))}function Xr(e,t,n,r){for(var o=t.length;o--;){var i=t[o];i&&(!n.ns||n.ns===i.evtName.ns)&&(!r||r(i))&&(Yr(e,i.evtName,i.handler,i.capture),t.splice(o,1))}}function Jr(e,t){return t?Wr("xx",Ce(t)?[e].concat(t):[e,t]).ns.split("."):e}function Zr(e,t,n,r,o){void 0===o&&(o=!1);var i=!1;if(e)try{var s=Wr(t,r);if(i=function(e,t,n,r){var o=!1;return e&&t&&t.type&&n&&(e[Or]?(e[Or](t.type,n,r),o=!0):e[Pr]&&(e[Pr](Rr+t.type,n),o=!0)),o}(e,s,n,o),i&&Vr.accept(e)){var a={guid:Gr++,evtName:s,handler:n,capture:o};Qr(e,s.type).push(a)}}catch{}return i}function eo(e,t,n,r,o){if(void 0===o&&(o=!1),e)try{var i=Wr(t,r),s=!1;(function(e,t,n){if(t.type)Xr(e,Qr(e,t.type),t,n);else{var r=Vr.get(e,Dr,{});be(r,(function(r,o){Xr(e,o,t,n)})),0===Ue(r).length&&Vr.kill(e,Dr)}})(e,i,(function(e){return!((!i.ns||n)&&e.handler!==n||(s=!0,0))})),s||Yr(e,i,n,o)}catch{}}function to(e,t,n,r){return void 0===r&&(r=!1),Zr(e,t,n,null,r)}function no(e,t,n,r){void 0===r&&(r=!1),eo(e,t,n,null,r)}function ro(e,t,n){var r=!1,o=Zt();o&&(r=Zr(o,e,t,n),r=Zr(o.body,e,t,n)||r);var i=tn();return i&&(r=Zr(i,e,t,n)||r),r}function oo(e,t,n){var r=Zt();r&&(eo(r,e,t,n),eo(r.body,e,t,n));var o=tn();o&&eo(o,e,t,n)}function io(e,t,n,r){var o=!1;return t&&e&&e.length>0&&Oe(e,(function(e){e&&(!n||-1===Ne(n,e))&&(o=ro(e,t,r)||o)})),o}function so(e,t,n,r){var o=!1;return t&&e&&Ce(e)&&!(o=io(e,t,n,r))&&n&&n.length>0&&(o=io(e,t,null,r)),o}function ao(e,t,n){e&&Ce(e)&&Oe(e,(function(e){e&&oo(e,t,n)}))}var co,uo=null,lo=r;function po(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(vo,(function(e){var t=0|Kn(15);return("x"===e?t:3&t|8).toString(16)}))}function ho(){var e=cn();return e&&e.now?e.now():Ge()}function fo(){for(var e,t=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],n=_,r=0;r<4;r++)n+=t[15&(e=Wn())]+t[e>>4&15]+t[e>>8&15]+t[e>>12&15]+t[e>>16&15]+t[e>>20&15]+t[e>>24&15]+t[e>>28&15];var o=t[8+(3&Wn())|0];return n.substr(0,8)+n.substr(9,4)+"4"+n.substr(13,3)+o+n.substr(16,3)+n.substr(19,12)}var mo={_canUseCookies:void 0,isTypeof:de,isUndefined:he,isNullOrUndefined:fe,hasOwnProperty:ve,isFunction:ye,isObject:ge,isDate:Se,isArray:Ce,isError:xe,isString:we,isNumber:Ae,isBoolean:Ie,toISOString:Pe,arrForEach:Oe,arrIndexOf:Ne,arrMap:ke,arrReduce:De,strTrim:Me,objCreate:m,objKeys:Ue,objDefineAccessors:Fe,addEventHandler:ro,dateNow:Ge,isIE:hn,disableCookies:_o,newGuid:po,perfNow:ho,newId:Xn,randomValue:Kn,random32:Wn,mwcRandomSeed:Qn,mwcRandom32:Yn,generateW3CId:fo},vo=/[xy]/g,go={Attach:to,AttachEvent:to,Detach:no,DetachEvent:no};function yo(e,t){var n=_r(e,t),r=mo._canUseCookies;return null===uo&&(uo=[],co=r,Fe(mo,"_canUseCookies",(function(){return co}),(function(e){co=e,Oe(uo,(function(t){t.setEnabled(e)}))}))),-1===Ne(uo,n)&&uo.push(n),Ie(r)&&n.setEnabled(r),Ie(co)&&n.setEnabled(co),n}function _o(){yo().setEnabled(!1)}var bo=/^([\da-f]{2})-([\da-f]{32})-([\da-f]{16})-([\da-f]{2})(-[^\s]*)?$/,Eo="00",To="ff",So="00000000000000000000000000000000",Co="0000000000000000";function xo(e,t,n){return!(!e||e.length!==t||e===n||!e.match(/^[\da-f]*$/))}function wo(e,t,n){return xo(e,t)?e:n}function Ao(e){(isNaN(e)||e<0||e>255)&&(e=1);for(var t=e.toString(16);t.length<2;)t="0"+t;return t}function Io(e){if(!e||(Ce(e)&&(e=e[0]||""),!e||!we(e)||e.length>8192))return null;var t=bo.exec(Me(e));return t&&t[1]!==To&&t[2]!==So&&t[3]!==Co?{version:t[1],traceId:t[2],spanId:t[3],traceFlags:parseInt(t[4],16)}:null}function Ro(e){return xo(e,32,So)}function Po(e){return xo(e,16,Co)}function Oo(e){return!!(e&&xo(e.version,2,To)&&xo(e.traceId,32,So)&&xo(e.spanId,16,Co)&&xo(Ao(e.traceFlags),2))}var No=or("plugin");function ko(e){return No.get(e,"state",{},!0)}function Do(e,t){for(var n,r=[],o=null,i=e.getNext();i;){var s=i.getPlugin();s&&(o&&ye(o[T])&&ye(s[b])&&o[T](s),(ye(s[S])?s[S]():(n=ko(s))[S])||r.push(s),o=s,i=i.getNext())}Oe(r,(function(r){var o=e.core();r.initialize(e.getCfg(),o,t,e.getNext()),n=ko(r),!r[x]&&!n[x]&&(n[x]=o),n[S]=!0,delete n[C]}))}function Mo(e){return e.sort((function(e,t){var n=0;if(t){var r=ye(t[b]);ye(e[b])?n=r?e[E]-t[E]:1:r&&(n=-1)}else n=e?1:-1;return n}))}var Lo="TelemetryPluginChain",jo="_hasRun",Uo="_getTelCtx",Fo=0;function zo(e,t,n,r){var o=null,i=[];null!==r&&(o=r?function(e,t,n){for(;e;){if(e.getPlugin()===n)return e;e=e.getNext()}return Go([n],t.config||{},t)}(e,n,r):e);var s={_next:function(){var e=o;if(o=e?e.getNext():null,!e){var t=i;t&&t.length>0&&(Oe(t,(function(e){try{e.func.call(e.self,e.args)}catch(e){On(n.logger,2,73,"Unexpected Exception during onComplete - "+fn(e))}})),i=[])}return e},ctx:{core:function(){return n},diagLog:function(){return In(n,t)},getCfg:function(){return t},getExtCfg:a,getConfig:function(e,n,r){void 0===r&&(r=!1);var o,i=a(e,null);return i&&!fe(i[n])?o=i[n]:t&&!fe(t[n])&&(o=t[n]),fe(o)?r:o},hasNext:function(){return!!o},getNext:function(){return o},setNext:function(e){o=e},iterate:function(e){for(var t;t=s._next();){var n=t.getPlugin();n&&e(n)}},onComplete:function(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];e&&i.push({func:e,self:he(t)?s.ctx:t,args:n})}}};function a(e,n,r){var o;if(void 0===n&&(n={}),void 0===r&&(r=0),t){var i=t.extensionConfig;i&&e&&(o=i[e])}if(o){if(ge(n)&&0!==r){var s=et(!0,n,o);t&&2===r&&be(n,(function(e){if(fe(s[e])){var n=t[e];fe(n)||(s[e]=n)}})),o=s}}else o=n;return o}return s}function qo(e,t,n,r){var o=zo(e,t,n,r),i=o.ctx;return i.processNext=function(e){var t=o._next();return t&&t.processTelemetry(e,i),!t},i.createNew=function(e,r){return void 0===e&&(e=null),Ce(e)&&(e=Go(e,t,n,r)),qo(e||i.getNext(),t,n,r)},i}function Bo(e,t,n){var r=t.config||{},o=zo(e,r,t,n),i=o.ctx;return i.processNext=function(e){var t=o._next();return t&&t.unload(i,e),!t},i.createNew=function(e,n){return void 0===e&&(e=null),Ce(e)&&(e=Go(e,r,t,n)),Bo(e||i.getNext(),t,n)},i}function Ho(e,t,n){var r=t.config||{},o=zo(e,r,t,n).ctx;return o.processNext=function(e){return o.iterate((function(t){ye(t.update)&&t.update(o,e)}))},o.createNew=function(e,n){return void 0===e&&(e=null),Ce(e)&&(e=Go(e,r,t,n)),Ho(e||o.getNext(),t,n)},o}function Go(e,t,n,r){var o=null,i=!r;if(Ce(e)&&e.length>0){var s=null;Oe(e,(function(e){if(!i&&r===e&&(i=!0),i&&e&&ye(e.processTelemetry)){var a=function(e,t,n){var r,o=null,i=ye(e.processTelemetry),s=ye(e.setNextPlugin),a={getPlugin:function(){return e},getNext:function(){return o},processTelemetry:function(r,u){c(u=u||function(){var r;return e&&ye(e[Uo])&&(r=e[Uo]()),r||(r=qo(a,t,n)),r}(),(function(t){if(!e||!i)return!1;var n=ko(e);return!n.teardown&&!n[A]&&(s&&e.setNextPlugin(o),e.processTelemetry(r,t),!0)}),"processTelemetry",(function(){return{item:r}}),!r.sync)||u.processNext(r)},unload:function(t,n){c(t,(function(){var r=!1;if(e){var o=ko(e),i=e[x]||o.core;e&&(!i||i===t[x]())&&!o[C]&&(o[x]=null,o[C]=!0,o[S]=!1,e[C]&&!0===e[C](t,n)&&(r=!0))}return r}),"unload",(function(){}),n.isAsync)||t.processNext(n)},update:function(t,n){c(t,(function(){var r=!1;if(e){var o=ko(e),i=e[x]||o.core;e&&(!i||i===t[x]())&&!o[C]&&e[w]&&!0===e[w](t,n)&&(r=!0)}return r}),"update",(function(){}),!1)||t.processNext(n)},_id:r=e?e.identifier+"-"+e.priority+"-"+Fo++:"Unknown-0-"+Fo++,_setNext:function(e){o=e}};function c(t,n,i,s,a){var c=!1,u=e?e.identifier:Lo,l=t[jo];return l||(l=t[jo]={}),t.setNext(o),e&&Un(t[x](),(function(){return u+":"+i}),(function(){l[r]=!0;try{var e=o?o._id:_;e&&(l[e]=!1),c=n(t)}catch(e){var s=!o||l[o._id];s&&(c=!0),(!o||!s)&&On(t.diagLog(),1,73,"Plugin ["+u+"] failed during "+i+" - "+fn(e)+", run flags: "+fn(l))}}),s,a),c}return Be(a)}(e,t,n);o||(o=a),s&&s._setNext(a),s=a}}))}return r&&!o?Go([r],t,n):o}var Vo="extensionConfig",$o=500;function Ko(e,t,n,r){t&&Ce(t)&&t.length>0&&(Oe(t=t.sort((function(e,t){return e.priority-t.priority})),(function(e){e.priority<$o&&Ye("Channel has invalid priority - "+e.identifier)})),e.push({queue:Be(t),chain:Go(t,n,r)}))}function Wo(){var e=[];return{add:function(t){t&&e.push(t)},run:function(t,n){Oe(e,(function(e){try{e(t,n)}catch(e){On(t.diagLog(),2,73,"Unexpected error calling unload handler - "+fn(e))}})),e=[]}}}var Qo="getPlugin",Yo=function e(){var t,n,r,o,i,s=this;function a(e){void 0===e&&(e=null);var t=e;if(!t){var o=n||qo(null,{},s.core);t=r&&r[Qo]?o.createNew(null,r[Qo]):o.createNew(null,r)}return t}function c(e,t,o){e&&$e(e,Vo,[],null,fe),!o&&t&&(o=t.getProcessTelContext().getNext());var i=r;r&&r[Qo]&&(i=r[Qo]()),s.core=t,n=qo(o,e,t,i)}function u(){t=!1,s.core=null,n=null,r=null,i=[],o=Wo()}u(),Nt(e,s,(function(e){e.initialize=function(e,n,r,o){c(e,n,o),t=!0},e.teardown=function(t,n){var s=e.core;if(s&&(!t||s===t.core())){var a,c=!1,l=t||Bo(null,s,r&&r[Qo]?r[Qo]():r),p=n||{reason:0,isAsync:!1};return e[I]&&!0===e[I](l,p,d)?a=!0:d(),a}function d(){c||(c=!0,o.run(l,n),Oe(i,(function(e){e.rm()})),i=[],!0===a&&l.processNext(p),u())}},e.update=function(t,n){var o=e.core;if(o&&(!t||o===t.core())){var i,s=!1,a=t||Ho(null,o,r&&r[Qo]?r[Qo]():r),u=n||{reason:0};return e._doUpdate&&!0===e._doUpdate(a,u,l)?i=!0:l(),i}function l(){s||(s=!0,c(a.getCfg(),a.core(),a.getNext()))}},e._addHook=function(e){e&&(Ce(e)?i=i.concat(e):i.push(e))},Je(e,"_addUnloadCb",(function(){return o}),"add")})),s.diagLog=function(e){return a(e).diagLog()},s[S]=function(){return t},s.setInitialized=function(e){t=e},s[T]=function(e){r=e},s.processNext=function(e,t){t?t.processNext(e):r&&ye(r.processTelemetry)&&r.processTelemetry(e,null)},s._getTelCtx=a},Xo=function(e){function t(){var n,r,o=e.call(this)||this;function i(){n=0,r=[]}return o.identifier="TelemetryInitializerPlugin",o.priority=199,i(),Nt(t,o,(function(e,t){e.addTelemetryInitializer=function(e){var t={id:n++,fn:e};return r.push(t),{remove:function(){Oe(r,(function(e,n){if(e.id===t.id)return r.splice(n,1),-1}))}}},e.processTelemetry=function(t,n){for(var o=!1,i=r.length,s=0;s<i;++s){var a=r[s];if(a)try{if(!1===a.fn.apply(null,[t])){o=!0;break}}catch(e){On(n.diagLog(),1,64,"One of telemetry initializers failed, telemetry item will not be sent: "+Ve(e),{exception:fn(e)},!0)}}o||e.processNext(t,n)},e[I]=function(){i()}})),o}return g(t,e),t}(Yo),Jo="Plugins must provide initialize method",Zo="_notificationManager",ei="SDK is still unloading...",ti={loggingLevelConsole:1};function ni(e,t){return new Ln(t)}function ri(e,t){var n=!1;return Oe(t,(function(t){if(t===e)return n=!0,-1})),n}var oi=function e(){var t,n,r,o,i,s,a,c,u,l,p,d,h,f,v,g,_,b,E,T=0;Nt(e,this,(function(e){function S(){t=!1,e.config=et(!0,{},ti),e.logger=new Rn(e.config),e._extensions=[],f=new Xo,n=[],r=null,o=null,i=null,s=null,a=null,u=null,c=[],l=null,p=null,d=null,h=!1,v=null,g=rr("AIBaseCore",!0),_=Wo(),E=null}function x(){return qo(N(),e.config,e)}function w(t,n){var r=function(e,t,n){var r=[],o={};return Oe(n,(function(t){(fe(t)||fe(t.initialize))&&Ye(Jo);var n=t.priority,i=t.identifier;t&&n&&(fe(o[n])?o[n]=i:Nn(e,"Two extensions have same priority #"+n+" - "+o[n]+", "+i)),(!n||n<500)&&r.push(t)})),{all:n,core:r}}(e.logger,0,c);u=r.core,a=null;var o=r.all;if(d=Be(function(e,t,n,r){var o=[];if(e&&Oe(e,(function(e){return Ko(o,e,n,r)})),t){var i=[];Oe(t,(function(e){e.priority>$o&&i.push(e)})),Ko(o,i,n,r)}return o}(p,o,t,e)),l){var i=Ne(o,l);-1!==i&&o.splice(i,1),-1!==(i=Ne(u,l))&&u.splice(i,1),l._setQueue(d)}else l=function(e,t){var n;function r(){return qo(null,t.config,t,null)}function o(e,t,n,r){var o=e?e.length+1:1;function i(){0==--o&&(r&&r(),r=null)}o>0&&Oe(e,(function(e){if(e&&e.queue.length>0){var r=e.chain,s=t.createNew(r);s.onComplete(i),n(s)}else o--})),i()}var i=!1;return(n={identifier:"ChannelControllerPlugin",priority:$o,initialize:function(t,n,r,o){i=!0,Oe(e,(function(e){e&&e.queue.length>0&&Do(qo(e.chain,t,n),r)}))},isInitialized:function(){return i},processTelemetry:function(t,n){o(e,n||r(),(function(e){e[R](t)}),(function(){n[R](t)}))},update:function(t,n){var r=n||{reason:0};return o(e,t,(function(e){e[R](r)}),(function(){t[R](r)})),!0}})[O]=function(){o(e,r(),(function(e){e.iterate((function(e){e[O]&&e[O]()}))}),null)},n[P]=function(){o(e,r(),(function(e){e.iterate((function(e){e[P]&&e[P]()}))}),null)},n[C]=function(t,n){var r=n||{reason:0,isAsync:!1};return o(e,t,(function(e){e[R](r)}),(function(){t[R](r),i=!1})),!0},n.getChannel=function(t){var n=null;return e&&e.length>0&&Oe(e,(function(e){if(e&&e.queue.length>0&&(Oe(e.queue,(function(e){if(e.identifier===t)return n=e,-1})),n))return-1})),n},n.flush=function(t,n,i,s){var a=1,c=!1,u=null;function l(){a--,c&&0===a&&(u&&(clearTimeout(u),u=null),n&&n(c),n=null)}return s=s||5e3,o(e,r(),(function(e){e.iterate((function(e){if(e.flush){a++;var n=!1;e.flush(t,(function(){n=!0,l()}),i)||n||(t&&null==u?u=setTimeout((function(){u=null,l()}),s):l())}}))}),(function(){c=!0,l()})),!0},n._setQueue=function(t){e=t},n}(d,e);o.push(l),u.push(l),e._extensions=Mo(o),l.initialize(t,e,o),Do(x(),o),e._extensions=Be(Mo(u||[])).slice(),n&&function(t){var n=Ho(N(),e);(!e._updateHook||!0!==e._updateHook(n,t))&&n.processNext(t)}(n)}function I(t){var n=null,r=null;return Oe(e._extensions,(function(e){if(e.identifier===t&&e!==l&&e!==f)return r=e,-1})),!r&&l&&(r=l.getChannel(t)),r&&(n={plugin:r,setEnabled:function(e){ko(r)[A]=!e},isEnabled:function(){var e=ko(r);return!e[C]&&!e[A]},remove:function(t,n){void 0===t&&(t=!0);var o=[r];U(o,{reason:1,isAsync:t},(function(t){t&&w(e.config,{reason:32,removed:o}),n&&n(t)}))}}),n}function N(){if(!a){var t=(u||[]).slice();-1===Ne(t,f)&&t.push(f),a=Go(Mo(t),e.config,e)}return a}function U(t,n,r){if(t&&t.length>0){var o=Bo(Go(t,e.config,e),e);o.onComplete((function(){var e=!1,n=[];Oe(c,(function(r,o){ri(r,t)?e=!0:n.push(r)})),c=n;var o=[];p&&(Oe(p,(function(n,r){var i=[];Oe(n,(function(n){ri(n,t)?e=!0:i.push(n)})),o.push(i)})),p=o),r&&r(e)})),o.processNext(n)}else r(!1)}function F(){var t=e.logger?e.logger.queue:[];t&&(Oe(t,(function(t){var n={name:v||"InternalMessageId: "+t.messageId,iKey:e.config.instrumentationKey,time:Pe(new Date),baseType:An.dataType,baseData:{message:t.message}};e.track(n)})),t.length=0)}function z(e,t,n,r){return l?l.flush(e,t,n||6,r):(t&&t(!1),!0)}function q(t){var n=e.logger;n?On(n,2,73,t):Ye(t)}S(),e.isInitialized=function(){return t},e.initialize=function(n,o,s,a){h&&Ye(ei),e.isInitialized()&&Ye("Core should not be initialized more than once"),(!n||fe(n.instrumentationKey))&&Ye("Please provide instrumentation key"),r=a,e[Zo]=a,e.config=n||{},function(e){!0===e.disableDbgExt&&b&&(r[D](b),b=null),r&&!b&&!0!==e.disableDbgExt&&(b=Cn(e),r[k](b))}(n),function(t){!t.enablePerfMgr&&i&&(i=null),t.enablePerfMgr&&$e(e.config,"createPerfMgr",ni)}(n),n.extensions=fe(n.extensions)?[]:n.extensions,function(e){Ke(e,Vo).NotificationManager=r}(n),s&&(e.logger=s),(c=[]).push.apply(c,y(y([],o),n.extensions)),p=(n||{}).channels,w(n,null),(!d||0===d.length)&&Ye("No channels available"),t=!0,e.releaseQueue()},e.getTransmissionControls=function(){var e=[];return d&&Oe(d,(function(t){e.push(t.queue)})),Be(e)},e.track=function(t){$e(t,"iKey",e.config.instrumentationKey,null,We),$e(t,"time",Pe(new Date),null,We),$e(t,"ver","4.0",null,fe),!h&&e.isInitialized()?x().processNext(t):n.push(t)},e.getProcessTelContext=x,e.getNotifyMgr=function(){return r||(r=function(){var e;return m(((e={})[k]=function(e){},e[D]=function(e){},e[M]=function(e){},e[L]=function(e,t){},e[j]=function(e,t){},e))}(),e[Zo]=r),r},e[k]=function(e){r&&r[k](e)},e[D]=function(e){r&&r[D](e)},e.getCookieMgr=function(){return s||(s=Er(e.config,e.logger)),s},e.setCookieMgr=function(e){s=e},e.getPerfMgr=function(){return!o&&!i&&e.config&&e.config.enablePerfMgr&&ye(e.config.createPerfMgr)&&(i=e.config.createPerfMgr(e,e.getNotifyMgr())),o||i||Fn()},e.setPerfMgr=function(e){o=e},e.eventCnt=function(){return n.length},e.releaseQueue=function(){if(t&&n.length>0){var e=n;n=[],Oe(e,(function(e){x().processNext(e)}))}},e.pollInternalLogs=function(t){v=t||null;var n=e.config.diagnosticLogInterval;return(!n||!(n>0))&&(n=1e4),T&&clearInterval(T),T=setInterval((function(){F()}),n)},e.stopPollingInternalLogs=function(){T&&(clearInterval(T),T=0,F())},Ze(e,(function(){return f}),["addTelemetryInitializer"]),e.unload=function(n,r,o){void 0===n&&(n=!0),t||Ye("SDK is not initialized"),h&&Ye(ei);var i={reason:50,isAsync:n,flushComplete:!1},s=Bo(N(),e);function a(t){i.flushComplete=t,h=!0,_.run(s,i),e.stopPollingInternalLogs(),s.processNext(i)}s.onComplete((function(){S(),r&&r(i)}),e),z(n,a,6,o)||a(!1)},e.getPlugin=I,e.addPlugin=function(t,n,r,o){if(!t)return o&&o(!1),void q(Jo);var i=I(t.identifier);if(i&&!n)return o&&o(!1),void q("Plugin ["+t.identifier+"] is already loaded!");var s={reason:16};function a(n){c.push(t),s.added=[t],w(e.config,s),o&&o(!0)}if(i){var u=[i.plugin];U(u,{reason:2,isAsync:!!r},(function(e){e?(s.removed=u,s.reason|=32,a()):o&&o(!1)}))}else a()},e.evtNamespace=function(){return g},e.flush=z,e.getTraceCtx=function(e){return E||(E=function(){var e={};return{getName:function(){return e.name},setName:function(t){e.name=t},getTraceId:function(){return e.traceId},setTraceId:function(t){Ro(t)&&(e.traceId=t)},getSpanId:function(){return e.spanId},setSpanId:function(t){Po(t)&&(e.spanId=t)},getTraceFlags:function(){return e.traceFlags},setTraceFlags:function(t){e.traceFlags=t}}}()),E},e.setTraceCtx=function(e){E=e||null},Je(e,"addUnloadCb",(function(){return _}),"add")}))};function ii(e,t,n,r){Oe(e,(function(e){if(e&&e[t])if(n)setTimeout((function(){return r(e)}),0);else try{r(e)}catch{}}))}var si=function e(t){this.listeners=[];var n=!!(t||{}).perfEvtsSendAll;Nt(e,this,(function(e){e[k]=function(t){e.listeners.push(t)},e[D]=function(t){for(var n=Ne(e.listeners,t);n>-1;)e.listeners.splice(n,1),n=Ne(e.listeners,t)},e[M]=function(t){ii(e.listeners,M,!0,(function(e){e[M](t)}))},e[L]=function(t,n){ii(e.listeners,L,!0,(function(e){e[L](t,n)}))},e[j]=function(t,n){ii(e.listeners,j,n,(function(e){e[j](t,n)}))},e[U]=function(t){t&&(n||!t.isChildEvt())&&ii(e.listeners,U,!1,(function(e){t.isAsync?setTimeout((function(){return e[U](t)}),0):e[U](t)}))}}))},ai=function(e){function t(){var n=e.call(this)||this;return Nt(t,n,(function(e,t){function n(t){var n=e.getNotifyMgr();n&&n.eventsDiscarded([t],2)}e.initialize=function(e,n,r,o){t.initialize(e,n,r||new Rn(e),o||new si(e))},e.track=function(r){Un(e.getPerfMgr(),(function(){return"AppInsightsCore:track"}),(function(){null===r&&(n(r),Ye("Invalid telemetry item")),function(e){fe(e.name)&&(n(e),Ye("telemetry name required"))}(r),t.track(r)}),(function(){return{item:r}}),!r.sync)}})),n}return g(t,e),t}(oi),ci=tt({CRITICAL:1,WARNING:2}),ui=tt({BrowserDoesNotSupportLocalStorage:0,BrowserCannotReadLocalStorage:1,BrowserCannotReadSessionStorage:2,BrowserCannotWriteLocalStorage:3,BrowserCannotWriteSessionStorage:4,BrowserFailedRemovalFromLocalStorage:5,BrowserFailedRemovalFromSessionStorage:6,CannotSendEmptyTelemetry:7,ClientPerformanceMathError:8,ErrorParsingAISessionCookie:9,ErrorPVCalc:10,ExceptionWhileLoggingError:11,FailedAddingTelemetryToBuffer:12,FailedMonitorAjaxAbort:13,FailedMonitorAjaxDur:14,FailedMonitorAjaxOpen:15,FailedMonitorAjaxRSC:16,FailedMonitorAjaxSend:17,FailedMonitorAjaxGetCorrelationHeader:18,FailedToAddHandlerForOnBeforeUnload:19,FailedToSendQueuedTelemetry:20,FailedToReportDataLoss:21,FlushFailed:22,MessageLimitPerPVExceeded:23,MissingRequiredFieldSpecification:24,NavigationTimingNotSupported:25,OnError:26,SessionRenewalDateIsZero:27,SenderNotInitialized:28,StartTrackEventFailed:29,StopTrackEventFailed:30,StartTrackFailed:31,StopTrackFailed:32,TelemetrySampledAndNotSent:33,TrackEventFailed:34,TrackExceptionFailed:35,TrackMetricFailed:36,TrackPVFailed:37,TrackPVFailedCalc:38,TrackTraceFailed:39,TransmissionFailed:40,FailedToSetStorageBuffer:41,FailedToRestoreStorageBuffer:42,InvalidBackendResponse:43,FailedToFixDepricatedValues:44,InvalidDurationValue:45,TelemetryEnvelopeInvalid:46,CreateEnvelopeError:47,CannotSerializeObject:48,CannotSerializeObjectNonSerializable:49,CircularReferenceDetected:50,ClearAuthContextFailed:51,ExceptionTruncated:52,IllegalCharsInName:53,ItemNotInArray:54,MaxAjaxPerPVExceeded:55,MessageTruncated:56,NameTooLong:57,SampleRateOutOfRange:58,SetAuthContextFailed:59,SetAuthContextFailedAccountName:60,StringValueTooLong:61,StartCalledMoreThanOnce:62,StopCalledWithoutStart:63,TelemetryInitializerFailed:64,TrackArgumentsNotSpecified:65,UrlTooLong:66,SessionStorageBufferFull:67,CannotAccessCookie:68,IdTooLong:69,InvalidEvent:70,FailedMonitorAjaxSetRequestHeader:71,SendBrowserInfoOnUserInit:72,PluginException:73,NotificationException:74,SnippetScriptLoadFailure:99,InvalidInstrumentationKey:100,CannotParseAiBlobValue:101,InvalidContentBlob:102,TrackPageActionEventFailed:103,FailedAddingCustomDefinedRequestContext:104,InMemoryStorageBufferFull:105,InstrumentationKeyDeprecation:106}),li="_aiHooks",pi=["req","rsp","hkErr","fnErr"];function di(e,t){if(e)for(var n=0;n<e.length&&!t(e[n],n);n++);}function hi(e,t,n,r,o){o>=0&&o<=2&&di(e,(function(e,i){var s=e.cbks,a=s[pi[o]];if(a){t.ctx=function(){return r[i]=r[i]||{}};try{a.apply(t.inst,n)}catch(e){var c=t.err;try{var u=s[pi[2]];u&&(t.err=e,u.apply(t.inst,n))}catch{}finally{t.err=c}}}}))}function fi(e,t,n){var r=null;return e&&(ve(e,t)?r=e:n&&(r=fi(pe(e),t,!1))),r}function mi(e,t,n,r){var o=n&&n[li];if(!o){var i=function(e){return function(){var t=arguments,n=e.h,r={name:e.n,inst:this,ctx:null,set:function(e,n){(t=s([],t))[e]=n,i=s([r],t)}},o=[],i=s([r],t);function s(e,t){return di(t,(function(t){e.push(t)})),e}r.evt=Xt("event"),hi(n,r,i,o,0);var a=e.f;if(a)try{r.rslt=a.apply(this,t)}catch(e){throw r.err=e,hi(n,r,i,o,3),e}return hi(n,r,i,o,1),r.rslt}}(o={i:0,n:t,f:n,h:[]});i[li]=o,e[t]=i}var s={id:o.i,cbks:r,rm:function(){var e=this.id;di(o.h,(function(t,n){if(t.id===e)return o.h.splice(n,1),1}))}};return o.i++,o.h.push(s),s}function vi(e,n,r,o){if(void 0===o&&(o=!0),e&&n&&r){var i=fi(e,n,o);if(i){var s=i[n];if(typeof s===t)return mi(i,n,s,r)}}return null}function gi(e,t,n,r){void 0===r&&(r=!0);var o=null;return di(t,(function(t){var i=vi(e,t,n,r);i&&(o||(o=[]),o.push(i))})),o}e.AppInsightsCore=ai,e.BaseCore=oi,e.BaseTelemetryPlugin=Yo,e.CoreUtils=mo,e.DiagnosticLogger=Rn,e.EventHelper=go,e.EventsDiscardedReason=nt,e.InstrumentEvent=function(e,t,n,r){if(e&&t&&n){var o=fi(e,t,r)||e;if(o)return mi(o,t,o[t],n)}return null},e.InstrumentFunc=vi,e.InstrumentFuncs=gi,e.InstrumentProto=function(e,t,n){return e?vi(e[o],t,n,!1):null},e.InstrumentProtos=function(e,t,n){return e?gi(e[o],t,n,!1):null},e.LoggingSeverity=ci,e.MinChannelPriorty=100,e.NotificationManager=si,e.PerfEvent=Mn,e.PerfManager=Ln,e.ProcessTelemetryContext=function(e,t,n,r){var o=qo(e,t,n,r);Ze(this,o,Ue(o))},e.Undefined=lo,e._InternalLogMessage=An,e._InternalMessageId=ui,e.__getRegisteredEvents=function(e,t,n){var r=[],o=Vr.get(e,Dr,{},!1),i=Wr(t,n);return be(o,(function(e,t){Oe(t,(function(e){(!i.type||i.type===e.evtName.type)&&(!i.ns||i.ns==i.ns)&&r.push({name:e.evtName.type+(e.evtName.ns?"."+e.evtName.ns:""),handler:e.handler})}))})),r},e._legacyCookieMgr=yo,e._logInternalMessage=function(e,t,n){Pn(e).logInternalMessage(t,n)},e._throwInternal=On,e._warnToConsole=Nn,e.addEventHandler=ro,e.addEventListeners=so,e.addPageHideEventListener=function e(t,n,r){var o=Jr(zr,r),i=io([Lr],t,n,o);return(!n||-1===Ne(n,Mr))&&(i=io([Mr],(function(e){var n=tn();t&&n&&"hidden"===n.visibilityState&&t(e)}),n,o)||i),!i&&n&&(i=e(t,null,r)),i},e.addPageShowEventListener=function e(t,n,r){var o=Jr(qr,r),i=io([jr],t,n,o);return!(i=io([Mr],(function(e){var n=tn();t&&n&&"visible"===n.visibilityState&&t(e)}),n,o)||i)&&n&&(i=e(t,null,r)),i},e.addPageUnloadEventListener=function(e,t,n){return so([Fr,Ur,Lr],e,t,n)},e.areCookiesSupported=Tr,e.arrForEach=Oe,e.arrIndexOf=Ne,e.arrMap=ke,e.arrReduce=De,e.attachEvent=to,e.canUseCookies=function(e){return yo(null,e).isEnabled()},e.createClassFromInterface=function(e){return function(){var t=this;e&&be(e,(function(e,n){t[e]=n}))}},e.createCookieMgr=Er,e.createEnumMap=function(e){var t={};return be(e,(function(e,n){t[e]=e,t[n]=e})),qe(t)},e.createEnumStyle=tt,e.createProcessTelemetryContext=qo,e.createTraceParent=function(e,t,n,r){return{version:xo(r,2,To)?r:Eo,traceId:Ro(e)?e:fo(),spanId:Po(t)?t:fo().substr(0,16),traceFlags:n>=0&&n<=255?n:1}},e.createUniqueNamespace=rr,e.createUnloadHandlerContainer=Wo,e.createValueMap=function(e){var t={};return be(e,(function(e,n){t[e]=n[1],t[n[0]]=n[1]})),qe(t)},e.dateNow=Ge,e.deepFreeze=qe,e.deleteCookie=function(e,t){return yo(null,e).del(t)},e.detachEvent=no,e.disableCookies=_o,e.doPerf=Un,e.dumpObj=fn,e.eventOff=eo,e.eventOn=Zr,e.findMetaTag=gn,e.findNamedServerTiming=yn,e.findW3cTraceParent=function(){var e="traceparent",t=Io(gn(e));return t||(t=Io(yn(e))),t},e.formatTraceParent=function(e){if(e){var t=Ao(e.traceFlags);xo(t,2)||(t="01");var n=e.version||Eo;return"00"!==n&&"ff"!==n&&(n=Eo),"".concat(n,"-").concat(wo(e.traceId,32,So),"-").concat(wo(e.spanId,16,Co),"-").concat(t)}return""},e.generateW3CId=fo,e.getConsole=an,e.getCookie=function(e,t){return yo(null,e).get(t)},e.getCrypto=pn,e.getDebugExt=Sn,e.getDebugListener=Cn,e.getDocument=tn,e.getExceptionName=Ve,e.getGblPerfMgr=Fn,e.getGlobal=h,e.getGlobalInst=Xt,e.getHistory=function(){return on()?history:Xt("history")},e.getIEVersion=function(e){if(void 0===e&&(e=null),!e){var t=rn()||{};e=t?(t.userAgent||_).toLowerCase():_}var n=(e||_).toLowerCase();if(Te(n,Bt)){var r=tn()||{};return Math.max(parseInt(n.split(Bt)[1]),r.documentMode||0)}if(Te(n,Ht)){var o=parseInt(n.split(Ht)[1]);if(o)return o+4}return null},e.getJSON=ln,e.getLocation=sn,e.getMsCrypto=dn,e.getNavigator=rn,e.getPerformance=cn,e.getSetValue=Ke,e.getWindow=Zt,e.hasDocument=en,e.hasHistory=on,e.hasJSON=un,e.hasNavigator=nn,e.hasOwnProperty=ve,e.hasWindow=Jt,e.initializePlugins=Do,e.isArray=Ce,e.isBeaconsSupported=function(){return null===Qt&&(Qt=nn()&&Boolean(rn().sendBeacon)),Qt},e.isBoolean=Ie,e.isDate=Se,e.isError=xe,e.isFetchSupported=function(e){var t=!1;try{t=!!Xt("fetch");var n=Xt("Request");t&&e&&n&&(t=Yt(n,"keepalive"))}catch{}return t},e.isFunction=ye,e.isIE=hn,e.isNotNullOrUndefined=me,e.isNotTruthy=We,e.isNotUndefined=function(e){return!he(e)},e.isNullOrUndefined=fe,e.isNumber=Ae,e.isObject=ge,e.isReactNative=function(){var e=rn();return!(!e||!e.product)&&"ReactNative"===e.product},e.isSafari=function(e){if(!e||!we(e)){var t=rn()||{};e=t?(t.userAgent||_).toLowerCase():_}return(e||_).toLowerCase().indexOf("safari")>=0},e.isSampledFlag=function(e){return!(!Oo(e)||1&~e.traceFlags)},e.isString=we,e.isSymbol=function(e){return"symbol"==typeof e},e.isTruthy=Qe,e.isTypeof=de,e.isUndefined=he,e.isValidSpanId=Po,e.isValidTraceId=Ro,e.isValidTraceParent=Oo,e.isXhrSupported=mn,e.mergeEvtNamespace=Jr,e.mwcRandom32=Yn,e.mwcRandomSeed=Qn,e.newGuid=po,e.newId=Xn,e.normalizeJsName=_e,e.objCreate=m,e.objDefineAccessors=Fe,e.objExtend=et,e.objForEachKey=be,e.objFreeze=Be,e.objKeys=Ue,e.objSeal=He,e.objToString=function(e){return oe.call(e)},e.optimizeObject=function(e){return e&&c&&(e=s(c({},e))),e},e.parseTraceParent=Io,e.perfNow=ho,e.proxyAssign=function(e,t,n){if(e&&t&&ge(e)&&ge(t)){var r=function(r){if(we(r)){var o=t[r];ye(o)?(!n||n(r,!0,t,e))&&(e[r]=Xe(t,r)):(!n||n(r,!1,t,e))&&(ve(e,r)&&delete e[r],Fe(e,r,(function(){return t[r]}),(function(e){t[r]=e}))||(e[r]=o))}};for(var o in t)r(o)}return e},e.proxyFunctionAs=Je,e.proxyFunctions=Ze,e.random32=Wn,e.randomValue=Kn,e.removeEventHandler=oo,e.removeEventListeners=ao,e.removePageHideEventListener=function(e,t){var n=Jr(zr,t);ao([Lr],e,n),ao([Mr],null,n)},e.removePageShowEventListener=function(e,t){var n=Jr(qr,t);ao([jr],e,n),ao([Mr],null,n)},e.removePageUnloadEventListener=function(e,t){ao([Fr,Ur,Lr],e,t)},e.safeGetCookieMgr=function(e,t){var n;if(e)n=e.getCookieMgr();else if(t){var r=t.cookieCfg;n=r[dr]?r[dr]:Er(t)}return n||(n=_r(t,(e||{}).logger)),n},e.safeGetLogger=In,e.setCookie=function(e,t,n,r){yo(null,e).set(t,n,null,r)},e.setEnableEnvMocks=function(e){Kt=e},e.setGblPerfMgr=function(e){Dn=e},e.setValue=$e,e.sortPlugins=Mo,e.strContains=Te,e.strEndsWith=Ee,e.strFunction=t,e.strObject=n,e.strPrototype=o,e.strStartsWith=function(e,t){var n=!1;return e&&t&&!(n=e===t)&&(n=te?e[q](t):function(e,t){var n=!1,r=t?t.length:0;if(e&&r&&e.length>=r&&!(n=e===t)){for(var o=0;o<r;o++)if(e[o]!==t[o])return!1;n=!0}return n}(e,t)),n},e.strTrim=Me,e.strUndefined=r,e.throwError=Ye,e.toISOString=Pe,e.uaDisallowsSameSiteNone=Ir,e.unloadComponents=function(e,t,n,r){var o=0;return function r(){for(;o<e.length;){var i=e[o++];if(i){var s=i._doUnload||i[I];if(ye(s)&&!0===s.call(i,t,n,r))return!0}}}()},e.useXDomainRequest=function(){return null===Wt&&(Wt=typeof XDomainRequest!==r)&&mn()&&(Wt=Wt&&!Yt(Xt(Gt),"withCredentials")),Wt},function(e,t,n){var r=Object.defineProperty;if(r)try{return r(e,t,n)}catch{}n&&void 0!==typeof n.value&&(e[t]=n.value)}(e,"__esModule",{value:!0})},"object"==typeof n&&typeof s<"u"?a(n):(o=[t],void 0===(i="function"==typeof(r=a)?r.apply(t,o):r)||(e.exports=i))})),x=b(((o,s)=>{var a;a=function(){"use strict";var e="constructor",t="prototype",n="function",r="_dynInstFuncs",o="_isDynProxy",i="_dynClass",s="_dynInstChk",a=s,c="_dfOpts",u="_unknown_",l="__proto__",p="_dyn"+l,d="_dynInstProto",h="useBaseInst",f="setInstFuncs",m=Object,v=m.getPrototypeOf,g=m.getOwnPropertyNames,y=0;function _(e,n){return e&&m[t].hasOwnProperty.call(e,n)}function b(e){return e&&(e===m[t]||e===Array[t])}function E(e){return b(e)||e===Function[t]}function T(n){var r;if(n){if(v)return v(n);var o=n[l]||n[t]||(n[e]?n[e][t]:null);r=n[p]||o,_(n,p)||(delete n[d],r=n[p]=n[d]||n[p],n[d]=o)}return r}function S(e,t){var n=[];if(g)n=g(e);else for(var r in e)"string"==typeof r&&_(e,r)&&n.push(r);if(n&&n.length>0)for(var o=0;o<n.length;o++)t(n[o])}function C(t,r,o){return r!==e&&typeof t[r]===n&&(o||_(t,r))}function x(e){throw new TypeError("DynamicProto: "+e)}function w(e,t){for(var n=e.length-1;n>=0;n--)if(e[n]===t)return!0;return!1}function A(e,t,c,u,l){if(!b(e)){var p=c[r]=c[r]||{},d=p[t]=p[t]||{};!1!==p[a]&&(p[a]=!!l),S(c,(function(t){C(c,t,!1)&&c[t]!==u[t]&&(d[t]=c[t],delete c[t],(!_(e,t)||e[t]&&!e[t][o])&&(e[t]=function(e,t){var c=function(){var o=function(e,t,o,c){var u=null;if(e&&_(o,i)){var l=e[r]||{};if((u=(l[o[i]]||{})[t])||x("Missing ["+t+"] "+n),!u[s]&&!1!==l[a]){for(var p=!_(e,t),d=T(e),h=[];p&&d&&!E(d)&&!w(h,d);){var f=d[t];if(f){p=f===c;break}h.push(d),d=T(d)}try{p&&(e[t]=u),u[s]=1}catch{l[a]=!1}}}return u}(this,t,e,c)||function(e,t,r){var o=t[e];return o===r&&(o=T(t)[e]),typeof o!==n&&x("["+e+"] is not a "+n),o}(t,e,c);return o.apply(this,arguments)};return c[o]=1,c}(e,t)))}))}}function I(n,r){return _(n,t)?n.name||r||u:((n||{})[e]||{}).name||r||u}function R(e,n,s,u){_(e,t)||x("theClass is an invalid class definition.");var l=e[t];(function(e,t){if(v){for(var n=[],r=T(t);r&&!E(r)&&!w(n,r);){if(r===e)return!0;n.push(r),r=T(r)}return!1}return!0})(l,n)||x("["+I(e)+"] is not in class hierarchy of ["+I(n)+"]");var p=null;_(l,i)?p=l[i]:(p="_dynCls$"+I(e,"_")+"$"+y,y++,l[i]=p);var d=R[c],m=!!d[h];m&&u&&void 0!==u[h]&&(m=!!u[h]);var g=function(e){var t={};return S(e,(function(n){!t[n]&&C(e,n,!1)&&(t[n]=e[n])})),t}(n),b=function(e,t,n,s){function c(e,t,n){var c=t[n];if(c[o]&&s){var u=e[r]||{};!1!==u[a]&&(c=(u[t[i]]||{})[n]||c)}return function(){return c.apply(e,arguments)}}var u={};S(n,(function(e){u[e]=c(t,n,e)}));for(var l=T(e),p=[];l&&!E(l)&&!w(p,l);)S(l,(function(e){!u[e]&&C(l,e,!v)&&(u[e]=c(t,l,e))})),p.push(l),l=T(l);return u}(l,n,g,m);s(n,b);var P=!!v&&!!d[f];P&&u&&(P=!!u[f]),A(l,p,n,g,!1!==P)}return R[c]={setInstFuncs:!0,useBaseInst:!0},R},"object"==typeof o&&typeof s<"u"?s.exports=a():void 0===(i="function"==typeof(r=a)?r.call(t,n,t,e):r)||(e.exports=i)})),w=b(((s,a)=>{var c;c=function(e,t,n,r){"use strict";var o,i,s=(i=r)&&"object"==typeof i&&"default"in i?i.default:i,a=n.createEnumStyle({NotSet:0,Pii_DistinguishedName:1,Pii_GenericData:2,Pii_IPV4Address:3,Pii_IPv6Address:4,Pii_MailSubject:5,Pii_PhoneNumber:6,Pii_QueryString:7,Pii_SipAddress:8,Pii_SmtpAddress:9,Pii_Identity:10,Pii_Uri:11,Pii_Fqdn:12,Pii_IPV4AddressLegacy:13,CustomerContent_GenericContent:32}),c=n.createEnumStyle({Normal:1,CostDeferred:2,RealTime:3,Immediate:4}),u=n.createEnumStyle({Unspecified:0,String:1,Int32:2,UInt32:3,Int64:4,UInt64:5,Double:6,Bool:7,Guid:8,DateTime:9}),l=n.createEnumStyle({Normal:1,Critical:2}),p=n.createEnumStyle({NONE:0,ERROR:1,WARNING:2,INFORMATION:3}),d=n.objFreeze(t.__assignFn(t.__assignFn({},n._InternalMessageId),n.createEnumStyle({AuthHandShakeError:501,AuthRedirectFail:502,BrowserCannotReadLocalStorage:503,BrowserCannotWriteLocalStorage:504,BrowserDoesNotSupportLocalStorage:505,CannotParseBiBlobValue:506,CannotParseDataAttribute:507,CVPluginNotAvailable:508,DroppedEvent:509,ErrorParsingAISessionCookie:510,ErrorProvidedChannels:511,FailedToGetCookies:512,FailedToInitializeCorrelationVector:513,FailedToInitializeSDK:514,InvalidContentBlob:515,InvalidCorrelationValue:516,SessionRenewalDateIsZero:517,SendPostOnCompleteFailure:518,PostResponseHandler:519,SDKNotInitialized:520}))),h="3.2.3",f="1DS-Web-JS-"+h,m="withCredentials",v=((o={})[0]=0,o[2]=6,o[1]=1,o[3]=7,o[4098]=6,o[4097]=1,o[4099]=7,o),g=null,y=Boolean(n.getDocument()),_=Boolean(n.getWindow());function b(e){return!(""===e||n.isNullOrUndefined(e))}function E(e){if(e){var t=e.indexOf("-");if(t>-1)return e.substring(0,t)}return""}function T(){return null===g&&(g=!n.isUndefined(Uint8Array)&&!function(){var e=n.getNavigator();if(!n.isUndefined(e)&&e.userAgent){var t=e.userAgent.toLowerCase();if((t.indexOf("safari")>=0||t.indexOf("firefox")>=0)&&t.indexOf("chrome")<0)return!0}return!1}()&&!n.isReactNative()),g}function S(e){return!!(e&&n.isNumber(e)&&e>=1&&e<=4)}function C(e,t,r){if(!t&&!b(t)||"string"!=typeof e)return null;var o=typeof t;if("string"===o||"number"===o||"boolean"===o||n.isArray(t))t={value:t};else if("object"!==o||t.hasOwnProperty("value")){if(n.isNullOrUndefined(t.value)||""===t.value||!n.isString(t.value)&&!n.isNumber(t.value)&&!n.isBoolean(t.value)&&!n.isArray(t.value))return null}else t={value:r?JSON.stringify(t):t};if(n.isArray(t.value)&&!M(t.value))return null;if(!n.isNullOrUndefined(t.kind)){if(n.isArray(t.value)||!D(t.kind))return null;t.value=t.value.toString()}return t}function x(e,t,r){var o=-1;if(!n.isUndefined(e))if(t>0&&(32===t?o=8192:t<=13&&(o=t<<5)),function(e){return e>=0&&e<=9}(r))-1===o&&(o=0),o|=r;else{var i=v[j(e)]||-1;-1!==o&&-1!==i?o|=i:6===i&&(o=i)}return o}function w(){n.safeGetCookieMgr(null).setEnabled(!1)}function A(e,t,r){n.areCookiesSupported(null)&&n.safeGetCookieMgr(null).set(e,t,86400*r,null,"/")}function I(e){n.areCookiesSupported(null)&&n.safeGetCookieMgr(null).del(e)}function R(e){return n.areCookiesSupported(null)?P(n.safeGetCookieMgr(null),e):""}function P(e,t,n){var r;return void 0===n&&(n=!0),e&&(r=e.get(t),n&&r&&decodeURIComponent&&(r=decodeURIComponent(r))),r||""}function O(e){void 0===e&&(e="D");var t=n.newGuid();return"B"===e?t="{"+t+"}":"P"===e?t="("+t+")":"N"===e&&(t=t.replace(/-/g,"")),t}function N(e,t,r,o,i){var s={},a=!1,c=0,u=arguments.length,l=arguments;for("[object Boolean]"===Object[n.strPrototype].toString.call(l[0])&&(a=l[0],c++);c<u;c++)e=l[c],n.objForEachKey(e,(function(e,t){a&&t&&n.isObject(t)?n.isArray(t)?(s[e]=s[e]||[],n.arrForEach(t,(function(t,r){t&&n.isObject(t)?s[e][r]=N(!0,s[e][r],t):s[e][r]=t}))):s[e]=N(!0,s[e],t):s[e]=t}));return s}var k=n.perfNow;function D(e){return 0===e||e>0&&e<=13||32===e}function M(e){return e.length>0}function L(e,t){var n=e;n.timings=n.timings||{},n.timings.processTelemetryStart=n.timings.processTelemetryStart||{},n.timings.processTelemetryStart[t]=k()}function j(e){var r=0;if(null!=e){var o=typeof e;"string"===o?r=1:"number"===o?r=2:"boolean"===o?r=3:o===t.strShimObject&&(r=4,n.isArray(e)?(r=4096,e.length>0&&(r|=j(e[0]))):n.hasOwnProperty(e,"value")&&(r=8192|j(e.value)))}return r}var U={Version:h,FullVersionString:f,strUndefined:n.strUndefined,strObject:n.strObject,Undefined:n.strUndefined,arrForEach:n.arrForEach,arrIndexOf:n.arrIndexOf,arrMap:n.arrMap,arrReduce:n.arrReduce,objKeys:n.objKeys,toISOString:n.toISOString,isReactNative:n.isReactNative,isString:n.isString,isNumber:n.isNumber,isBoolean:n.isBoolean,isFunction:n.isFunction,isArray:n.isArray,isObject:n.isObject,strTrim:n.strTrim,isDocumentObjectAvailable:y,isWindowObjectAvailable:_,isValueAssigned:b,getTenantId:E,isBeaconsSupported:n.isBeaconsSupported,isUint8ArrayAvailable:T,isLatency:S,sanitizeProperty:C,getISOString:n.toISOString,useXDomainRequest:n.useXDomainRequest,getCommonSchemaMetaData:x,cookieAvailable:n.areCookiesSupported,disallowsSameSiteNone:n.uaDisallowsSameSiteNone,setCookie:A,deleteCookie:I,getCookie:R,createGuid:O,extend:N,getTime:k,isValueKind:D,isArrayValid:M,objDefineAccessors:n.objDefineAccessors,addPageUnloadEventListener:n.addPageUnloadEventListener,setProcessTelemetryTimings:L,addEventHandler:n.addEventHandler,getFieldValueType:j,strEndsWith:n.strEndsWith,objForEachKey:n.objForEachKey},F={_canUseCookies:void 0,isTypeof:n.isTypeof,isUndefined:n.isUndefined,isNullOrUndefined:n.isNullOrUndefined,hasOwnProperty:n.hasOwnProperty,isFunction:n.isFunction,isObject:n.isObject,isDate:n.isDate,isArray:n.isArray,isError:n.isError,isString:n.isString,isNumber:n.isNumber,isBoolean:n.isBoolean,toISOString:n.toISOString,arrForEach:n.arrForEach,arrIndexOf:n.arrIndexOf,arrMap:n.arrMap,arrReduce:n.arrReduce,strTrim:n.strTrim,objCreate:t.objCreateFn,objKeys:n.objKeys,objDefineAccessors:n.objDefineAccessors,addEventHandler:n.addEventHandler,dateNow:n.dateNow,isIE:n.isIE,disableCookies:w,newGuid:n.newGuid,perfNow:n.perfNow,newId:n.newId,randomValue:n.randomValue,random32:n.random32,mwcRandomSeed:n.mwcRandomSeed,mwcRandom32:n.mwcRandom32,generateW3CId:n.generateW3CId},z="version",q="properties",B=function(e){function r(){var t=e.call(this)||this;return t.pluginVersionStringArr=[],t.pluginVersionString="",s(r,t,(function(e,t){(!e.logger||!e.logger.queue)&&(e.logger=new n.DiagnosticLogger({loggingLevelConsole:1})),e.initialize=function(r,o,i,s){n.doPerf(e,(function(){return"AppInsightsCore.initialize"}),(function(){if(r){r.endpointUrl||(r.endpointUrl="https://browser.events.data.microsoft.com/OneCollector/1.0/");var a=r.propertyStorageOverride;if(a&&(!a.getProperty||!a.setProperty))throw new Error("Invalid property storage override passed.");r.channels&&n.arrForEach(r.channels,(function(t){t&&n.arrForEach(t,(function(t){if(t.identifier&&t.version){var n=t.identifier+"="+t.version;e.pluginVersionStringArr.push(n)}}))}))}e.getWParam=function(){return typeof document<"u"?0:-1},o&&n.arrForEach(o,(function(t){if(t&&t.identifier&&t.version){var n=t.identifier+"="+t.version;e.pluginVersionStringArr.push(n)}})),e.pluginVersionString=e.pluginVersionStringArr.join(";");try{t.initialize(r,o,i,s),e.pollInternalLogs("InternalLog")}catch(t){var c=e.logger,u=n.dumpObj(t);-1!==u.indexOf("channels")&&(u+="\n - Channels must be provided through config.channels only!"),c.throwInternal(1,514,"SDK Initialization Failed - no telemetry will be sent: "+u)}}),(function(){return{config:r,extensions:o,logger:i,notificationManager:s}}))},e.track=function(r){n.doPerf(e,(function(){return"AppInsightsCore.track"}),(function(){var n=r;if(n){n.timings=n.timings||{},n.timings.trackStart=k(),S(n.latency)||(n.latency=1);var o=n.ext=n.ext||{};o.sdk=o.sdk||{},o.sdk.ver=f;var i=n.baseData=n.baseData||{};i[q]||(i[q]={});var s=i[q];s[z]||(s[z]=""),""!==e.pluginVersionString&&(s[z]=e.pluginVersionString)}t.track(n)}),(function(){return{item:r}}),!r.sync)}})),t}return t.__extendsFn(r,e),r}(n.AppInsightsCore),H=function(e){function r(){var t=e.call(this)||this;return s(r,t,(function(e,t){e.initialize=function(r,o,i,s){r&&!r.endpointUrl&&(r.endpointUrl="https://browser.events.data.microsoft.com/OneCollector/1.0/"),e.getWParam=function(){return y?0:-1};try{t.initialize(r,o,i,s)}catch(t){n._throwInternal(e.logger,1,514,"Initialization Failed: "+n.dumpObj(t)+"\n - Note: Channels must be provided through config.channels only")}},e.track=function(e){var n=e;if(n){var r=n.ext=n.ext||{};r.sdk=r.sdk||{},r.sdk.ver=f}t.track(n)}})),t}return t.__extendsFn(r,e),r}(n.BaseCore),G=n.isFunction;function V(e,t,n){return function(r){e[t]=r,n()}}var $=function(){function e(t){var n=0,r=null,o=[];function i(){if(o.length>0){var e=o.slice();o=[],setTimeout((function(){for(var t=0,n=e.length;t<n;++t)try{e[t]()}catch{}}),0)}}function a(e){0===n&&(r=e,n=1,i())}function c(e){0===n&&(r=e,n=2,i())}s(e,this,(function(t){t.then=function(t,s){return new e((function(a,c){!function(t,s,a,c){o.push((function(){var o;try{(o=1===n?G(t)?t(r):r:G(s)?s(r):r)instanceof e?o.then(a,c):2!==n||G(s)?a(o):c(o)}catch(e){return void c(e)}})),0!==n&&i()}(t,s,a,c)}))},t.catch=function(e){return t.then(null,e)}})),function(){if(!G(t))throw new TypeError("ESPromise: resolvedFunc argument is not a Function");try{t(a,c)}catch(e){c(e)}}()}return e.resolve=function(t){return t instanceof e?t:t&&G(t.then)?new e((function(e,n){try{t.then(e,n)}catch(e){n(e)}})):new e((function(e){e(t)}))},e.reject=function(t){return new e((function(e,n){n(t)}))},e.all=function(t){if(t&&t.length)return new e((function(e,n){try{for(var r=[],o=0,i=0;i<t.length;i++){var s=t[i];s&&G(s.then)?(o++,s.then(V(r,i,(function(){0==--o&&e(r)})),n)):r[i]=s}0===o&&setTimeout((function(){e(r)}),0)}catch(e){n(e)}}))},e.race=function(t){return new e((function(e,n){if(t&&t.length)try{for(var r=function(r){var o=t[r];o&&G(o.then)?o.then(e,n):setTimeout((function(){e(o)}),0)},o=0;o<t.length;o++)r(o)}catch(e){n(e)}}))},e}(),K=0,W=[],Q=[],Y=[];function X(){return(new Date).getTime()}var J=function(){function e(t,r){var o=0,i=(t||"<unnamed>")+"."+K;function a(e){var t=n.getGlobal();t&&t.QUnit&&console&&console.log("ESPromiseScheduler["+i+"] "+e)}function c(e){r&&r.warnToConsole("ESPromiseScheduler["+i+"] "+e)}K++,s(e,this,(function(e){var t=null,n=0;function r(e,t){for(var n=0;n<e.length;n++)if(e[n].id===t)return e.splice(n,1)[0];return null}e.scheduleEvent=function(e,s,u){var l=i+"."+n;n++,s&&(l+="-("+s+")");var p=l+"{"+o+"}";o++;var d,h,f,m={evt:null,tm:X(),id:p,isRunning:!1,isAborted:!1};return m.evt=t?(d=m,h=t,f=new $((function(e,t){var n=X()-h.tm,o=h.id;a("["+l+"] is waiting for ["+o+":"+n+" ms] to complete before starting -- ["+Q.length+"] waiting and ["+W.length+"] running"),d.abort=function(e){d.abort=null,r(Q,l),d.isAborted=!0,t(new Error(e))},h.evt.then((function(n){r(Q,l),E(d).then(e,t)}),(function(n){r(Q,l),E(d).then(e,t)}))})),Q.push(d),f):E(m),(t=m).evt._schId=p,m.evt;function v(e){for(var t=X(),n=t-6e5,r=e.length,o=0;o<r;){var i=e[o];if(i&&i.tm<n){var s=null;i.abort?(s="Aborting ["+i.id+"] due to Excessive runtime ("+(t-i.tm)+" ms)",i.abort(s)):s="Removing ["+i.id+"] due to Excessive runtime ("+(t-i.tm)+" ms)",c(s),e.splice(o,1),r--}else o++}}function g(e,n){var o=!1,i=r(W,e);if(i||(i=r(Y,e),o=!0),i){i.to&&(clearTimeout(i.to),i.to=null);var s=X()-i.tm;n?o?c("Timed out event ["+e+"] finally complete -- "+s+" ms"):a("Promise ["+e+"] Complete -- "+s+" ms"):(Y.push(i),c("Event ["+e+"] Timed out and removed -- "+s+" ms"))}else a("Failed to remove ["+e+"] from running queue");t&&t.id===e&&(t=null),v(W),v(Q),v(Y)}function y(e,t){return function(n){return g(e,!0),t&&t(n),n}}function _(e,t,n,r){t.then((function(t){return t instanceof $?(a("Event ["+e+"] returned a promise -- waiting"),_(e,t,n,r),t):y(e,n)(t)}),y(e,r))}function b(e,t){var n=e.id;return new $((function(r,o){a("Event ["+n+"] Starting -- waited for "+(e.wTm||"--")+" ms"),e.isRunning=!0,e.abort=function(t){e.abort=null,e.isAborted=!0,g(n,!1),o(new Error(t))};var i=t(n);i instanceof $?(u&&(e.to=setTimeout((function(){g(n,!1),o(new Error("Timed out after ["+u+"] ms"))}),u)),_(n,i,(function(t){a("Event ["+n+"] Resolving after "+(X()-e.tm)+" ms"),r(t)}),o)):(a("Promise ["+n+"] Auto completed as the start action did not return a promise"),r())}))}function E(t){var n=X();return t.wTm=n-t.tm,t.tm=n,t.isAborted?$.reject(new Error("["+l+"] was aborted")):(W.push(t),b(t,e))}}}))}return e.incomplete=function(){return W},e.waitingToStart=function(){return Q},e}(),Z=function(){function e(e){var t=this,r={},o=[],i=[];function s(e,t){var s,a=r[e];if(a&&(s=a[t]),!s&&null!==s){if(n.isString(e)&&n.isString(t))if(i.length>0){for(var c=0;c<i.length;c++)if(i[c].handleField(e,t)){s={canHandle:!0,fieldHandler:i[c]};break}}else 0===o.length&&(s={canHandle:!0});if(!s&&null!==s)for(s=null,c=0;c<o.length;c++)if(o[c].handleField(e,t)){s={canHandle:!0,handler:o[c],fieldHandler:null};break}a||(a=r[e]={}),a[t]=s}return s}function a(e,t,r,o,i,s){if(e.handler)return e.handler.property(t,r,i,s);if(!n.isNullOrUndefined(i.kind)){if(!(4096&~o&&D(i.kind)))return null;i.value=i.value.toString()}return u(e.fieldHandler,t,r,o,i)}function c(e,t,n){return b(n)?{value:n}:null}function u(e,r,o,i,s){if(s&&e){var a=e.getSanitizer(r,o,i,s.kind,s.propertyType);if(a)if(4===i){var l={},p=s.value;n.objForEachKey(p,(function(t,n){var i=r+"."+o;if(b(n)){var s=c(0,0,n);(s=u(e,i,t,j(n),s))&&(l[t]=s.value)}})),s.value=l}else{var d={path:r,name:o,type:i,prop:s,sanitizer:t};s=a.call(t,d)}}return s}e&&i.push(e),t.addSanitizer=function(e){e&&(o.push(e),r={})},t.addFieldSanitizer=function(e){e&&(i.push(e),r={})},t.handleField=function(e,t){var n=s(e,t);return!!n&&n.canHandle},t.value=function(e,t,r,o){var i=s(e,t);if(i&&i.canHandle){if(!i||!i.canHandle)return null;if(i.handler)return i.handler.value(e,t,r,o);if(!n.isString(t)||n.isNullOrUndefined(r)||""===r)return null;var u=null,l=j(r);if(8192&~l)1!==l&&2!==l&&3!==l&&4096&~l?4===l&&(u=c(0,0,o?JSON.stringify(r):r)):u=c(0,0,r);else{var p=-8193&l;if(!b((u=r).value)||1!==p&&2!==p&&3!==p&&4096&~p)return null}if(u)return a(i,e,t,l,u,o)}return null},t.property=function(e,t,r,o){var i=s(e,t);if(!i||!i.canHandle||!n.isString(t)||n.isNullOrUndefined(r)||!b(r.value))return null;var c=j(r.value);return 0===c?null:a(i,e,t,c,r,o)}}return e.getFieldType=j,e}();e.BaseTelemetryPlugin=n.BaseTelemetryPlugin,e.DiagnosticLogger=n.DiagnosticLogger,e.EventHelper=n.EventHelper,e.EventsDiscardedReason=n.EventsDiscardedReason,e.InternalAppInsightsCore=n.AppInsightsCore,e.InternalBaseCore=n.BaseCore,e.LoggingSeverity=n.LoggingSeverity,e.MinChannelPriorty=n.MinChannelPriorty,e.NotificationManager=n.NotificationManager,e.PerfEvent=n.PerfEvent,e.PerfManager=n.PerfManager,e.ProcessTelemetryContext=n.ProcessTelemetryContext,e.Undefined=n.strUndefined,e._InternalLogMessage=n._InternalLogMessage,e._InternalMessageId=n._InternalMessageId,e.__getRegisteredEvents=n.__getRegisteredEvents,e._throwInternal=n._throwInternal,e.addEventHandler=n.addEventHandler,e.addEventListeners=n.addEventListeners,e.addPageHideEventListener=n.addPageHideEventListener,e.addPageShowEventListener=n.addPageShowEventListener,e.addPageUnloadEventListener=n.addPageUnloadEventListener,e.areCookiesSupported=n.areCookiesSupported,e.arrForEach=n.arrForEach,e.arrIndexOf=n.arrIndexOf,e.arrMap=n.arrMap,e.arrReduce=n.arrReduce,e.attachEvent=n.attachEvent,e.cookieAvailable=n.areCookiesSupported,e.createCookieMgr=n.createCookieMgr,e.createEnumStyle=n.createEnumStyle,e.createProcessTelemetryContext=n.createProcessTelemetryContext,e.createTraceParent=n.createTraceParent,e.createUniqueNamespace=n.createUniqueNamespace,e.createUnloadHandlerContainer=n.createUnloadHandlerContainer,e.dateNow=n.dateNow,e.detachEvent=n.detachEvent,e.disallowsSameSiteNone=n.uaDisallowsSameSiteNone,e.doPerf=n.doPerf,e.dumpObj=n.dumpObj,e.eventOff=n.eventOff,e.eventOn=n.eventOn,e.findW3cTraceParent=n.findW3cTraceParent,e.formatTraceParent=n.formatTraceParent,e.generateW3CId=n.generateW3CId,e.getConsole=n.getConsole,e.getCrypto=n.getCrypto,e.getDocument=n.getDocument,e.getExceptionName=n.getExceptionName,e.getGlobal=n.getGlobal,e.getGlobalInst=n.getGlobalInst,e.getHistory=n.getHistory,e.getIEVersion=n.getIEVersion,e.getISOString=n.toISOString,e.getJSON=n.getJSON,e.getLocation=n.getLocation,e.getMsCrypto=n.getMsCrypto,e.getNavigator=n.getNavigator,e.getPerformance=n.getPerformance,e.getSetValue=n.getSetValue,e.getWindow=n.getWindow,e.hasDocument=n.hasDocument,e.hasHistory=n.hasHistory,e.hasJSON=n.hasJSON,e.hasNavigator=n.hasNavigator,e.hasOwnProperty=n.hasOwnProperty,e.hasWindow=n.hasWindow,e.isArray=n.isArray,e.isBeaconsSupported=n.isBeaconsSupported,e.isBoolean=n.isBoolean,e.isDate=n.isDate,e.isError=n.isError,e.isFetchSupported=n.isFetchSupported,e.isFunction=n.isFunction,e.isIE=n.isIE,e.isNotTruthy=n.isNotTruthy,e.isNullOrUndefined=n.isNullOrUndefined,e.isNumber=n.isNumber,e.isObject=n.isObject,e.isReactNative=n.isReactNative,e.isSampledFlag=n.isSampledFlag,e.isString=n.isString,e.isTruthy=n.isTruthy,e.isTypeof=n.isTypeof,e.isUndefined=n.isUndefined,e.isValidSpanId=n.isValidSpanId,e.isValidTraceId=n.isValidTraceId,e.isValidTraceParent=n.isValidTraceParent,e.isXhrSupported=n.isXhrSupported,e.mergeEvtNamespace=n.mergeEvtNamespace,e.newGuid=n.newGuid,e.newId=n.newId,e.normalizeJsName=n.normalizeJsName,e.objCreate=n.objCreate,e.objDefineAccessors=n.objDefineAccessors,e.objForEachKey=n.objForEachKey,e.objFreeze=n.objFreeze,e.objKeys=n.objKeys,e.objSeal=n.objSeal,e.optimizeObject=n.optimizeObject,e.parseTraceParent=n.parseTraceParent,e.perfNow=n.perfNow,e.proxyAssign=n.proxyAssign,e.proxyFunctionAs=n.proxyFunctionAs,e.proxyFunctions=n.proxyFunctions,e.random32=n.random32,e.randomValue=n.randomValue,e.removeEventHandler=n.removeEventHandler,e.removeEventListeners=n.removeEventListeners,e.removePageHideEventListener=n.removePageHideEventListener,e.removePageShowEventListener=n.removePageShowEventListener,e.removePageUnloadEventListener=n.removePageUnloadEventListener,e.safeGetCookieMgr=n.safeGetCookieMgr,e.safeGetLogger=n.safeGetLogger,e.setEnableEnvMocks=n.setEnableEnvMocks,e.setValue=n.setValue,e.strContains=n.strContains,e.strEndsWith=n.strEndsWith,e.strFunction=n.strFunction,e.strObject=n.strObject,e.strPrototype=n.strPrototype,e.strStartsWith=n.strStartsWith,e.strTrim=n.strTrim,e.strUndefined=n.strUndefined,e.throwError=n.throwError,e.toISOString=n.toISOString,e.useXDomainRequest=n.useXDomainRequest,e.AppInsightsCore=B,e.BaseCore=H,e.CoreUtils=F,e.ESPromise=$,e.ESPromiseScheduler=J,e.EventLatency=c,e.EventPersistence=l,e.EventPropertyType=u,e.FullVersionString=f,e.TraceLevel=p,e.Utils=U,e.ValueKind=a,e.ValueSanitizer=Z,e.Version=h,e._ExtendedInternalMessageId=d,e.createGuid=O,e.deleteCookie=I,e.disableCookies=w,e.extend=N,e.getCommonSchemaMetaData=x,e.getCookie=R,e.getCookieValue=P,e.getFieldValueType=j,e.getTenantId=E,e.getTime=k,e.isArrayValid=M,e.isChromium=function(){return!!n.getGlobalInst("chrome")},e.isDocumentObjectAvailable=y,e.isLatency=S,e.isUint8ArrayAvailable=T,e.isValueAssigned=b,e.isValueKind=D,e.isWindowObjectAvailable=_,e.openXhr=function(e,t,n,r,o,i){function s(e,t,n){try{e[t]=n}catch{}}void 0===r&&(r=!1),void 0===o&&(o=!1);var a=new XMLHttpRequest;return r&&s(a,"Microsoft_ApplicationInsights_BypassAjaxInstrumentation",r),n&&s(a,m,n),a.open(e,t,!o),n&&s(a,m,n),!o&&i&&s(a,"timeout",i),a},e.sanitizeProperty=C,e.setCookie=A,e.setProcessTelemetryTimings=L,function(e,t,n){var r=Object.defineProperty;if(r)try{return r(e,t,n)}catch{}n&&void 0!==typeof n.value&&(e[t]=n.value)}(e,"__esModule",{value:!0})},"object"==typeof s&&typeof a<"u"?c(s,S(),C(),x()):(o=[t,n(2284),n(3695),n(1356)],void 0===(i="function"==typeof(r=c)?r.apply(t,o):r)||(e.exports=i))})),A=b(((n,s)=>{var a;a=function(e){"use strict";var t="function",n="object",r="undefined",o="prototype",i="hasOwnProperty",s="default",a=Object,c=a[o],u=a.assign,l=a.create,p=a.defineProperty,d=c[i],h=null;function f(e){return void 0===e&&(e=!0),(!h||!e)&&(typeof globalThis!==r&&globalThis&&(h=globalThis),typeof self!==r&&self&&(h=self),typeof window!==r&&window&&(h=window),typeof global!==r&&global&&(h=global)),h}function m(e){throw new TypeError(e)}function v(e){if(l)return l(e);if(null==e)return{};var r=typeof e;function i(){}return r!==n&&r!==t&&m("Object prototype may only be an Object:"+e),i[o]=e,new i}var g=(f()||{}).Symbol,y=(f()||{}).Reflect,_=!!y,b="decorate",E="metadata",T="getOwnPropertySymbols",S="iterator",C=u||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])c[i].call(t,o)&&(e[o]=t[o]);return e},x=function(e,t){return(x=a.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t[i](n)&&(e[n]=t[n])})(e,t)};function w(e,n){function r(){this.constructor=e}typeof n!==t&&null!==n&&m("Class extends value "+String(n)+" is not a constructor or null"),x(e,n),e[o]=null===n?v(n):(r[o]=n[o],new r)}function A(e,t,n,r){void 0===r&&(r=n),l?p(e,r,{enumerable:!0,get:function(){return t[n]}}):e[r]=t[n]}e.ObjAssign=u,e.ObjClass=a,e.ObjCreate=l,e.ObjDefineProperty=p,e.ObjHasOwnProperty=d,e.ObjProto=c,e.__assignFn=C,e.__createBindingFn=A,e.__decorateFn=function(e,n,r,o){var i,s=arguments.length,c=s<3?n:null===o?o=a.getOwnPropertyDescriptor(n,r):o;if(_&&typeof y[b]===t)c=y[b](e,n,r,o);else for(var u=e.length-1;u>=0;u--)(i=e[u])&&(c=(s<3?i(c):s>3?i(n,r,c):i(n,r))||c);return s>3&&c&&p(n,r,c),c},e.__exportStarFn=function(e,t){for(var n in e)n!==s&&!d.call(t,n)&&A(t,e,n)},e.__exposeGlobalTsLib=function(){var e,t,n,r,o=f()||{};t=C,n=w,r=A,(e=o).__assign||(e.__assign=u||t),e.__extends||(e.__extends=n),e.__createBinding||(e.__createBinding=r),__assign||(__assign=o.__assign),__extends||(__extends=o.__extends),__createBinding||(__createBinding=o.__createBinding)},e.__extendsFn=w,e.__importDefaultFn=function(e){return e&&e.__esModule?e:{strDefault:e}},e.__importStarFn=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)n!==s&&Object.prototype.hasOwnProperty.call(e,n)&&A(t,e,n);return l?p(t,s,{enumerable:!0,value:e}):t[s]=e,t},e.__makeTemplateObjectFn=function(e,t){return p?p(e,"raw",{value:t}):e.raw=t,e},e.__metadataFn=function(e,n){if(_&&y[E]===t)return y[E](e,n)},e.__paramFn=function(e,t){return function(n,r){t(n,r,e)}},e.__readFn=function(e,n){var r=typeof g===t&&e[g[S]];if(!r)return e;var o,i,s=r.call(e),a=[];try{for(;(void 0===n||n-- >0)&&!(o=s.next()).done;)a.push(o.value)}catch(e){i={error:e}}finally{try{o&&!o.done&&(r=s.return)&&r.call(s)}finally{if(i)throw i.error}}return a},e.__restFn=function(e,n){var r={};for(var o in e)d.call(e,o)&&n.indexOf(o)<0&&(r[o]=e[o]);if(null!=e&&typeof a[T]===t)for(var i=0,s=a[T](e);i<s.length;i++)n.indexOf(s[i])<0&&c.propertyIsEnumerable.call(e,s[i])&&(r[s[i]]=e[s[i]]);return r},e.__spreadArrayFn=function(e,t){for(var n=0,r=t.length,o=e.length;n<r;n++,o++)e[o]=t[n];return e},e.__spreadArraysFn=function(){for(var e=arguments,t=0,n=0,r=e.length;n<r;n++)t+=e[n].length;var o=Array(t),i=0;for(n=0;n<r;n++)for(var s=e[n],a=0,c=s.length;a<c;a++,i++)o[i]=s[a];return o},e.__valuesFn=function(e){var n=typeof g===t&&g[S],r=n&&e[n],o=0;return r?r.call(e):e&&"number"==typeof e.length?{next:function(){return e&&o>=e.length&&(e=void 0),{value:e&&e[o++],done:!e}}}:void m(n?"Object is not iterable.":"Symbol.iterator is not defined.")},e.getGlobal=f,e.objCreateFn=v,e.strDefault=s,e.strShimFunction=t,e.strShimHasOwnProperty=i,e.strShimObject=n,e.strShimPrototype=o,e.strShimUndefined=r,e.throwTypeError=m,function(e,t,n){var r=Object.defineProperty;if(r)try{return r(e,t,n)}catch{}n&&void 0!==typeof n.value&&(e[t]=n.value)}(e,"__esModule",{value:!0})},"object"==typeof n&&typeof s<"u"?a(n):(o=[t],void 0===(i="function"==typeof(r=a)?r.apply(t,o):r)||(e.exports=i))})),I=b(((s,a)=>{var c;c=function(e,t,n,r){"use strict";var o,i=(o=n)&&"object"==typeof o&&"default"in o?o.default:o,s="REAL_TIME",a="NEAR_REAL_TIME",c="BEST_EFFORT",u="POST",l="drop",p="requeue",d="application/x-json-stream",h="cache-control",f="content-type",m="kill-duration",v="time-delta-millis",g="client-version",y="client-id",_="time-delta-to-apply-millis",b="upload-time",E="apikey",T="AuthMsaDeviceTicket",S="AuthXToken",C="msfpc";function x(e){var t=(e.ext||{}).intweb;return t&&r.isValueAssigned(t[C])?t[C]:null}function w(e){for(var t=null,n=0;null===t&&n<e.length;n++)t=x(e[n]);return t}var A=function(){function e(t,n){var o=n?[].concat(n):[],i=this,s=w(o);i.iKey=function(){return t},i.Msfpc=function(){return s||""},i.count=function(){return o.length},i.events=function(){return o},i.addEvent=function(e){return!!e&&(o.push(e),s||(s=x(e)),!0)},i.split=function(n,i){var a;if(n<o.length){var c=o.length-n;r.isNullOrUndefined(i)||(c=i<c?i:c),a=o.splice(n,c),s=w(o)}return new e(t,a)}}return e.create=function(t,n){return new e(t,n)},e}(),I=2e6,R=Math.min(I,65e3),P="metadata",O="f",N=/\./,k=function e(t,n,o,s){var a="data",c="baseData",u=!!s,l=!0,p=n,d={};i(e,this,(function(e){function n(e,t,i,s,a,c,l){r.objForEachKey(e,(function(e,h){var f=null;if(h||r.isValueAssigned(h)){var m=i,v=e,g=a,y=t;if(u&&!s&&N.test(e)){var _=e.split("."),b=_.length;if(b>1){g&&(g=g.slice());for(var E=0;E<b-1;E++){var T=_[E];y=y[T]=y[T]||{},m+="."+T,g&&g.push(T)}v=_[b-1]}}var S=s&&function(e){var t=d[e];return void 0===t&&(e.length>=7&&(t=r.strStartsWith(e,"ext.metadata")||r.strStartsWith(e,"ext.web")),d[e]=t),t}(m);if(f=!S&&p&&p.handleField(m,v)?p.value(m,v,h,o):r.sanitizeProperty(v,h,o)){var C=f.value;if(y[v]=C,c&&c(g,v,f),l&&"object"==typeof C&&!r.isArray(C)){var x=g;x&&(x=x.slice()).push(v),n(h,C,m+"."+v,s,x,c,l)}}}}))}e.createPayload=function(e,t,n,r,o,i){return{apiKeys:[],payloadBlob:"",overflow:null,sizeExceed:[],failedEvts:[],batches:[],numEvents:0,retryCnt:e,isTeardown:t,isSync:n,isBeacon:r,sendType:i,sendReason:o}},e.appendPayload=function(n,o,i){var s=n&&o&&!n.overflow;return s&&r.doPerf(t,(function(){return"Serializer:appendPayload"}),(function(){for(var t=o.events(),s=n.payloadBlob,a=n.numEvents,c=!1,u=[],l=[],p=n.isBeacon,d=p?65e3:3984588,h=p?R:I,f=0,m=0;f<t.length;){var v=t[f];if(v){if(a>=i){n.overflow=o.split(f);break}var g=e.getEventBlob(v);if(g&&g.length<=h){var y=g.length;if(s.length+y>d){n.overflow=o.split(f);break}s&&(s+="\n"),s+=g,++m>20&&(s.substr(0,1),m=0),c=!0,a++}else g?u.push(v):l.push(v),t.splice(f,1),f--}f++}if(u&&u.length>0&&n.sizeExceed.push(A.create(o.iKey(),u)),l&&l.length>0&&n.failedEvts.push(A.create(o.iKey(),l)),c){n.batches.push(o),n.payloadBlob=s,n.numEvents=a;var _=o.iKey();-1===r.arrIndexOf(n.apiKeys,_)&&n.apiKeys.push(_)}}),(function(){return{payload:n,theBatch:{iKey:o.iKey(),evts:o.events()},max:i}})),s},e.getEventBlob=function(e){try{return r.doPerf(t,(function(){return"Serializer.getEventBlob"}),(function(){var t={};t.name=e.name,t.time=e.time,t.ver=e.ver,t.iKey="o:"+r.getTenantId(e.iKey);var o={},i=e.ext;i&&(t.ext=o,r.objForEachKey(i,(function(e,t){n(t,o[e]={},"ext."+e,!0,null,null,!0)})));var s=t[a]={};s.baseType=e.baseType;var u=s[c]={};return n(e.baseData,u,c,!1,[c],(function(e,t,n){D(o,e,t,n)}),l),n(e.data,s,a,!1,[],(function(e,t,n){D(o,e,t,n)}),l),JSON.stringify(t)}),(function(){return{item:e}}))}catch{return null}}}))};function D(e,t,n,o){if(o&&e){var i=r.getCommonSchemaMetaData(o.value,o.kind,o.propertyType);if(i>-1){var s=e[P];s||(s=e[P]={f:{}});var a=s[O];if(a||(a=s[O]={}),t)for(var c=0;c<t.length;c++){var u=t[c];a[u]||(a[u]={f:{}});var l=a[u][O];l||(l=a[u][O]={}),a=l}a=a[n]={},r.isArray(o.value)?a.a={t:i}:a.t=i}}}function M(e){var t,n=Math.floor(1200*Math.random())+2400;return t=Math.pow(2,e)*n,Math.min(t,6e5)}var L,j=function e(){var t={};i(e,this,(function(e){e.setKillSwitchTenants=function(e,n){if(e&&n)try{var o=function(e){var t=[];return e&&r.arrForEach(e,(function(e){t.push(r.strTrim(e))})),t}(e.split(","));if("this-request-only"===n)return o;for(var i=1e3*parseInt(n,10),s=0;s<o.length;++s)t[o[s]]=r.dateNow()+i}catch{return[]}return[]},e.isTenantKilled=function(e){var n=t,o=r.strTrim(e);return void 0!==n[o]&&n[o]>r.dateNow()||(delete n[o],!1)}}))},U=function e(){var t=!0,n=!0,r=!0,o="use-collector-delta",s=!1;i(e,this,(function(e){e.allowRequestSending=function(){return t},e.firstRequestSent=function(){r&&(r=!1,s||(t=!1))},e.shouldAddClockSkewHeaders=function(){return n},e.getClockSkewHeaderValue=function(){return o},e.setClockSkew=function(e){s||(e?(o=e,n=!0,s=!0):n=!1,t=!0)}}))},F="sendAttempt",z="&NoResponseBody=true",q=((L={})[1]=p,L[100]=p,L[200]="sent",L[8004]=l,L[8003]=l,L),B={},H={};function G(e,t,n){B[e]=t,!1!==n&&(H[t]=e)}function V(e){try{return e.responseText}catch{}return""}function $(e,t){var n=!1;if(e&&t){var o=r.objKeys(e);if(o&&o.length>0)for(var i=t.toLowerCase(),s=0;s<o.length;s++){var a=o[s];if(a&&r.hasOwnProperty(t,a)&&a.toLowerCase()===i){n=!0;break}}}return n}function K(e,t,n,r){t&&n&&n.length>0&&(r&&B[t]?(e.hdrs[B[t]]=n,e.useHdrs=!0):e.url+="&"+t+"="+n)}G(T,T,!1),G(g,g),G(y,"Client-Id"),G(E,E),G(_,_),G(b,b),G(S,S);var W=function e(t,n,o,s,a){this._responseHandlers=[];var c,p,T,S,x,w,A="?cors=true&"+f.toLowerCase()+"="+d,I=new j,R=!1,P=new U,O=!1,N=0,D=!0,L=[],B={},G=[],W=null,Q=!1,Y=!1,X=!1;i(e,this,(function(e){var i=!0;function j(e,t){for(var n=0,o=null,i=0;null==o&&i<e.length;)1===(n=e[i])?r.useXDomainRequest()?o=U:r.isXhrSupported()&&(o=Z):2===n&&r.isFetchSupported(t)?o=J:O&&3===n&&r.isBeaconsSupported()&&(o=te),i++;return o?{_transport:n,_isSync:t,sendPOST:o}:null}function U(e,t,n){var r=new XDomainRequest;r.open(u,e.urlString),e.timeout&&(r.timeout=e.timeout),r.onload=function(){var e=V(r);ee(t,200,{},e),de(e)},r.onerror=function(){ee(t,400,{})},r.ontimeout=function(){ee(t,500,{})},r.onprogress=function(){},n?r.send(e.data):a.set((function(){r.send(e.data)}),0)}function J(e,t,n){var o,s=e.urlString,c=!1,l=!1,p=((o={body:e.data,method:u}).Microsoft_ApplicationInsights_BypassAjaxInstrumentation=!0,o);n&&(p.keepalive=!0,2===e._sendReason&&(c=!0,s+=z)),i&&(p.credentials="include"),e.headers&&r.objKeys(e.headers).length>0&&(p.headers=e.headers),fetch(s,p).then((function(e){var n={},r="";e.headers&&e.headers.forEach((function(e,t){n[t]=e})),e.body&&e.text().then((function(e){r=e})),l||(l=!0,ee(t,e.status,n,r),de(r))})).catch((function(e){l||(l=!0,ee(t,0,{}))})),c&&!l&&(l=!0,ee(t,200,{})),!l&&e.timeout>0&&a.set((function(){l||(l=!0,ee(t,500,{}))}),e.timeout)}function Z(e,t,n){var o=e.urlString;function s(e,t,n){if(!e[n]&&t&&t.getResponseHeader){var o=t.getResponseHeader(n);o&&(e[n]=r.strTrim(o))}return e}function a(e,n){ee(t,e.status,function(e){var t={};return e.getAllResponseHeaders?t=function(e){var t={};if(r.isString(e)){var n=r.strTrim(e).split(/[\r\n]+/);r.arrForEach(n,(function(e){if(e){var n=e.indexOf(": ");if(-1!==n){var o=r.strTrim(e.substring(0,n)).toLowerCase(),i=r.strTrim(e.substring(n+1));t[o]=i}else t[r.strTrim(e)]=1}}))}return t}(e.getAllResponseHeaders()):(t=s(t,e,v),t=s(t,e,m),t=s(t,e,"kill-duration-seconds")),t}(e),n)}n&&e.disableXhrSync&&(n=!1);var c=r.openXhr(u,o,i,!0,n,e.timeout);r.objForEachKey(e.headers,(function(e,t){c.setRequestHeader(e,t)})),c.onload=function(){var e=V(c);a(c,e),de(e)},c.onerror=function(){a(c)},c.ontimeout=function(){a(c)},c.send(e.data)}function ee(e,t,n,o){try{e(t,n,o)}catch(e){r._throwInternal(c.diagLog(),2,518,r.dumpObj(e))}}function te(e,t,n){var o=200,i=e._thePayload,s=e.urlString+z;try{var a=r.getNavigator();if(!a.sendBeacon(s,e.data))if(i){var u=[];r.arrForEach(i.batches,(function(e){if(u&&e&&e.count()>0){for(var t=e.events(),n=0;n<t.length;n++)if(!a.sendBeacon(s,W.getEventBlob(t[n]))){u.push(e.split(n));break}}else u.push(e.split(0))})),he(u,8003,i.sendType,!0)}else o=0}catch(e){c.diagLog().warnToConsole("Failed to send telemetry using sendBeacon API. Ex:"+r.dumpObj(e)),o=0}finally{ee(t,o,{},"")}}function ne(e){return 2===e||3===e}function re(e){return Y&&ne(e)&&(e=2),e}function oe(){return!R&&N<n}function ie(){var e=G;return G=[],e}function se(e,t,n){var r=!1;return e&&e.length>0&&!R&&p[t]&&W&&(r=0!==t||oe()&&(n>0||P.allowRequestSending())),r}function ae(e){var t={};return e&&r.arrForEach(e,(function(e,n){t[n]={iKey:e.iKey(),evts:e.events()}})),t}function ce(e,n,o,i,s){if(e&&0!==e.length){if(R)return void he(e,1,i);i=re(i);try{var a=e,u=0!==i;r.doPerf(T,(function(){return"HttpManager:_sendBatches"}),(function(a){a&&(e=e.slice(0));for(var c=[],l=null,d=r.getTime(),h=p[i]||(u?p[1]:p[0]),f=(Y||ne(i)||h&&3===h._transport)&&!D&&O&&r.isBeaconsSupported();se(e,i,n);){var m=e.shift();m&&m.count()>0&&(I.isTenantKilled(m.iKey())?c.push(m):(l=l||W.createPayload(n,o,u,f,s,i),W.appendPayload(l,m,t)?null!==l.overflow&&(e=[l.overflow].concat(e),l.overflow=null,le(l,d,r.getTime(),s),d=r.getTime(),l=null):(le(l,d,r.getTime(),s),d=r.getTime(),e=[m].concat(e),l=null)))}l&&le(l,d,r.getTime(),s),e.length>0&&(G=e.concat(G)),he(c,8004,i)}),(function(){return{batches:ae(a),retryCount:n,isTeardown:o,isSynchronous:u,sendReason:s,useSendBeacon:ne(i),sendType:i}}),!u)}catch(e){r._throwInternal(c.diagLog(),2,48,"Unexpected Exception sending batch: "+r.dumpObj(e))}}}function ue(e,t,n){e[t]=e[t]||{},e[t][c.identifier]=n}function le(t,n,i,s){if(t&&t.payloadBlob&&t.payloadBlob.length>0){var a=!!e.sendHook,u=p[t.sendType];!ne(t.sendType)&&t.isBeacon&&2===t.sendReason&&(u=p[2]||p[3]||u);var l=X;(t.isBeacon||3===u._transport)&&(l=!1);var S=function(e,t){var n={url:A,hdrs:{},useHdrs:!1};t?(n.hdrs=r.extend(n.hdrs,B),n.useHdrs=r.objKeys(n.hdrs).length>0):r.objForEachKey(B,(function(e,t){H[e]?K(n,H[e],t,!1):(n.hdrs[e]=t,n.useHdrs=!0)})),K(n,y,"NO_AUTH",t),K(n,g,r.FullVersionString,t);var o="";r.arrForEach(e.apiKeys,(function(e){o.length>0&&(o+=","),o+=e})),K(n,E,o,t),K(n,b,r.dateNow().toString(),t);var i=function(e){for(var t=0;t<e.batches.length;t++){var n=e.batches[t].Msfpc();if(n)return encodeURIComponent(n)}return""}(e);if(r.isValueAssigned(i)&&(n.url+="&ext.intweb.msfpc="+i),P.shouldAddClockSkewHeaders()&&K(n,_,P.getClockSkewHeaderValue(),t),T.getWParam){var s=T.getWParam();s>=0&&(n.url+="&w="+s)}for(var a=0;a<L.length;a++)n.url+="&"+L[a].name+"="+L[a].value;return n}(t,l);l=l||S.useHdrs;var C=r.getTime();r.doPerf(T,(function(){return"HttpManager:_doPayloadSend"}),(function(){for(var p=0;p<t.batches.length;p++)for(var g=t.batches[p].events(),y=0;y<g.length;y++){var _=g[y];if(Q){var b=_.timings=_.timings||{};ue(b,"sendEventStart",C),ue(b,"serializationStart",n),ue(b,"serializationCompleted",i)}_[F]>0?_[F]++:_[F]=1}he(t.batches,1e3+(s||0),t.sendType,!0);var E={data:t.payloadBlob,urlString:S.url,headers:S.hdrs,_thePayload:t,_sendReason:s,timeout:x};r.isUndefined(w)||(E.disableXhrSync=!!w),l&&($(E.headers,h)||(E.headers[h]="no-cache, no-store"),$(E.headers,f)||(E.headers[f]=d));var A=null;u&&(A=function(n){P.firstRequestSent();var i=function(n,i){!function(t,n,i,s){var a=9e3,u=null,l=!1,p=!1;try{var d=!0;if(typeof t!==r.strUndefined){if(n){P.setClockSkew(n[v]);var h=n[m]||n["kill-duration-seconds"];r.arrForEach(I.setKillSwitchTenants(n["kill-tokens"],h),(function(e){r.arrForEach(i.batches,(function(t){if(t.iKey()===e){u=u||[];var n=t.split(0);i.numEvents-=n.count(),u.push(n)}}))}))}if(200==t||204==t)return void(a=200);(!function(e){return!(e>=300&&e<500&&408!=e&&429!=e||501==e||505==e)}(t)||i.numEvents<=0)&&(d=!1),a=9e3+t%1e3}if(d){a=100;var f=i.retryCnt;0===i.sendType&&(f<o?(l=!0,pe((function(){0===i.sendType&&N--,ce(i.batches,f+1,i.isTeardown,Y?2:i.sendType,5)}),Y,M(f))):(p=!0,Y&&(a=8001)))}}finally{l||(P.setClockSkew(),function(t,n,o,i){try{i&&c._backOffTransmission(),200===n&&(!i&&!t.isSync&&c._clearBackOff(),function(e){if(Q){var t=r.getTime();r.arrForEach(e,(function(e){e&&e.count()>0&&function(e,t){Q&&r.arrForEach(e,(function(e){ue(e.timings=e.timings||{},"sendEventCompleted",t)}))}(e.events(),t)}))}}(t.batches)),he(t.batches,n,t.sendType,!0)}finally{0===t.sendType&&(N--,5!==o&&e.sendQueuedRequests(t.sendType,o))}}(i,a,s,p)),he(u,8004,i.sendType)}}(n,i,t,s)},a=t.isTeardown||t.isSync;try{u.sendPOST(n,i,a),e.sendListener&&e.sendListener(E,n,a,t.isBeacon)}catch(e){c.diagLog().warnToConsole("Unexpected exception sending payload. Ex:"+r.dumpObj(e)),ee(i,0,{})}}),r.doPerf(T,(function(){return"HttpManager:_doPayloadSend.sender"}),(function(){if(A)if(0===t.sendType&&N++,a&&!t.isBeacon&&3!==u._transport){var n={data:E.data,urlString:E.urlString,headers:r.extend({},E.headers),timeout:E.timeout,disableXhrSync:E.disableXhrSync},o=!1;r.doPerf(T,(function(){return"HttpManager:_doPayloadSend.sendHook"}),(function(){try{e.sendHook(n,(function(e){o=!0,!D&&!e._thePayload&&(e._thePayload=e._thePayload||E._thePayload,e._sendReason=e._sendReason||E._sendReason),A(e)}),t.isSync||t.isTeardown)}catch{o||A(E)}}))}else A(E)}))}),(function(){return{thePayload:t,serializationStart:n,serializationCompleted:i,sendReason:s}}),t.isSync)}t.sizeExceed&&t.sizeExceed.length>0&&he(t.sizeExceed,8003,t.sendType),t.failedEvts&&t.failedEvts.length>0&&he(t.failedEvts,8002,t.sendType)}function pe(e,t,n){t?e():a.set(e,n)}function de(t){var n=e._responseHandlers;try{for(var o=0;o<n.length;o++)try{n[o](t)}catch(e){r._throwInternal(c.diagLog(),1,519,"Response handler failed: "+e)}if(t){var i=JSON.parse(t);r.isValueAssigned(i.webResult)&&r.isValueAssigned(i.webResult[C])&&S.set("MSFPC",i.webResult[C],31536e3)}}catch{}}function he(e,t,n,o){if(e&&e.length>0&&s){var i=s[function(e){var t=q[e];return r.isValueAssigned(t)||(t="oth",e>=9e3&&e<=9999?t="rspFail":e>=8e3&&e<=8999?t=l:e>=1e3&&e<=1999&&(t="send")),t}(t)];if(i){var a=0!==n;r.doPerf(T,(function(){return"HttpManager:_sendBatchesNotification"}),(function(){pe((function(){try{i.call(s,e,t,a,n)}catch(e){r._throwInternal(c.diagLog(),1,74,"send request notification failed: "+e)}}),o||a,0)}),(function(){return{batches:ae(e),reason:t,isSync:a,sendSync:o,sendType:n}}),!a)}}}e.initialize=function(e,t,n,o,s){var a;s||(s={}),A=e+A,X=!!r.isUndefined(s.avoidOptions)||!s.avoidOptions,T=t,S=t.getCookieMgr(),Q=!T.config.disableEventTimings;var u=!!T.config.enableCompoundKey;c=n;var l=s.valueSanitizer,d=s.stringifyObjects;r.isUndefined(s.enableCompoundKey)||(u=!!s.enableCompoundKey),x=s.xhrTimeout,w=s.disableXhrSync,O=!r.isReactNative(),W=new k(T,l,d,u);var h=o,f=s.alwaysUseXhrOverride?o:null,m=s.alwaysUseXhrOverride?o:null;if(!o){D=!1;var v=r.getLocation();v&&v.protocol&&"file:"===v.protocol.toLowerCase()&&(i=!1);var g=[];g=r.isReactNative()?[2,1]:[1,2,3];var y=s.transports;y&&(r.isNumber(y)?g=[y].concat(g):r.isArray(y)&&(g=y.concat(g))),o=j(g,!1),h=j(g,!0),o||c.diagLog().warnToConsole("No available transport to send events")}(a={})[0]=o,a[1]=h||j([1,2,3],!0),a[2]=f||j([3,2],!0)||h||j([1],!0),a[3]=m||j([2,3],!0)||h||j([1],!0),p=a},e._getDbgPlgTargets=function(){return[p[0],I,W,p]},e.addQueryStringParameter=function(e,t){for(var n=0;n<L.length;n++)if(L[n].name===e)return void(L[n].value=t);L.push({name:e,value:t})},e.addHeader=function(e,t){B[e]=t},e.canSendRequest=function(){return oe()&&P.allowRequestSending()},e.sendQueuedRequests=function(e,t){r.isUndefined(e)&&(e=0),Y&&(e=re(e),t=2),se(G,e,0)&&ce(ie(),0,!1,e,t||0)},e.isCompletelyIdle=function(){return!R&&0===N&&0===G.length},e.setUnloading=function(e){Y=e},e.addBatch=function(e){if(e&&e.count()>0){if(I.isTenantKilled(e.iKey()))return!1;G.push(e)}return!0},e.teardown=function(){G.length>0&&ce(ie(),0,!0,2,2)},e.pause=function(){R=!0},e.resume=function(){R=!1,e.sendQueuedRequests(0,4)},e.sendSynchronousBatch=function(e,t,n){e&&e.count()>0&&(r.isNullOrUndefined(t)&&(t=1),Y&&(t=re(t),n=2),ce([e],0,!1,t,n||0))}}))};function Q(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];return setTimeout(e,t,n)}function Y(e){clearTimeout(e)}function X(e,t){return{set:e||Q,clear:t||Y}}var J="eventsDiscarded",Z="overrideInstrumentationKey",ee="maxEventRetryAttempts",te="maxUnloadEventRetryAttempts",ne=function(e){function n(){var t=e.call(this)||this;t.identifier="PostChannel",t.priority=1011,t.version="3.2.3";var o,u,l,p,d,h,f,m,v=!1,g=[],y=null,_=!1,b=0,E=500,S=0,C=1e4,x={},w=s,I=null,R=null,P=0,O=0,N={},k=-1,D=!0,L=!1,j=6,U=2;return i(n,t,(function(e,t){function n(e){"beforeunload"!==(e||r.getWindow().event).type&&(L=!0,l.setUnloading(L)),$(2,2)}function i(e){L=!1,l.setUnloading(L)}function F(e,t){if(e.sendAttempt||(e.sendAttempt=0),e.latency||(e.latency=1),e.ext&&e.ext.trace&&delete e.ext.trace,e.ext&&e.ext.user&&e.ext.user.id&&delete e.ext.user.id,D&&(e.ext=r.optimizeObject(e.ext),e.baseData&&(e.baseData=r.optimizeObject(e.baseData)),e.data&&(e.data=r.optimizeObject(e.data))),e.sync)if(P||_)e.latency=3,e.sync=!1;else if(l)return D&&(e=r.optimizeObject(e)),void l.sendSynchronousBatch(A.create(e.iKey,[e]),!0===e.sync?1:e.sync,3);var n=e.latency,o=S,i=C;4===n&&(o=b,i=E);var s=!1;if(o<i)s=!Y(e,t);else{var a=1,c=20;4===n&&(a=4,c=1),s=!0,function(e,t,n,o){for(;n<=t;){var i=K(e,t,!0);if(i&&i.count()>0){var s=i.split(0,o),a=s.count();if(a>0)return 4===n?b-=a:S-=a,le(J,[s],r.EventsDiscardedReason.QueueFull),!0}n++}return ne(),!1}(e.iKey,e.latency,a,c)&&(s=!Y(e,t))}s&&ue(J,[e],r.EventsDiscardedReason.QueueFull)}function z(e,t,n){var r=re(e,t,n);return l.sendQueuedRequests(t,n),r}function q(){return S>0}function B(){if(k>=0&&re(k,0,h)&&l.sendQueuedRequests(0,h),b>0&&!R&&!_){var e=x[w][2];e>=0&&(R=G((function(){R=null,z(4,0,1),B()}),e))}var t=x[w][1];!I&&!y&&t>=0&&!_&&(q()?I=G((function(){I=null,z(0===O?3:1,0,1),O++,O%=2,B()}),t):O=0)}function H(){o=null,v=!1,g=[],y=null,_=!1,b=0,E=500,S=0,C=1e4,x={},w=s,I=null,R=null,P=0,O=0,u=null,N={},p=void 0,d=0,k=-1,h=null,D=!0,L=!1,j=6,U=2,f=null,m=X(),l=new W(500,2,1,{requeue:ae,send:pe,sent:de,drop:he,rspFail:fe,oth:me},m),se(),N[4]={batches:[],iKeyMap:{}},N[3]={batches:[],iKeyMap:{}},N[2]={batches:[],iKeyMap:{}},N[1]={batches:[],iKeyMap:{}},ve()}function G(e,t){0===t&&P&&(t=1);var n=1e3;return P&&(n=M(P-1)),m.set(e,t*n)}function V(){return null!==I&&(m.clear(I),I=null,O=0,!0)}function $(e,t){V(),y&&(m.clear(y),y=null),_||z(1,e,t)}function K(e,t,n){var r=N[t];r||(r=N[t=1]);var o=r.iKeyMap[e];return!o&&n&&(o=A.create(e),r.batches.push(o),r.iKeyMap[e]=o),o}function Q(t,n){l.canSendRequest()&&!P&&(p>0&&S>p&&(n=!0),n&&null==y&&e.flush(t,null,20))}function Y(e,t){D&&(e=r.optimizeObject(e));var n=e.latency,o=K(e.iKey,n,!0);return!!o.addEvent(e)&&(4!==n?(S++,t&&0===e.sendAttempt&&Q(!e.sync,d>0&&o.count()>=d)):b++,!0)}function ne(){for(var e=0,t=0,n=function(n){var o=N[n];o&&o.batches&&r.arrForEach(o.batches,(function(r){4===n?e+=r.count():t+=r.count()}))},o=1;o<=4;o++)n(o);S=t,b=e}function re(t,n,o){var i=!1,s=0===n;return!s||l.canSendRequest()?r.doPerf(e.core,(function(){return"PostChannel._queueBatches"}),(function(){for(var e=[],n=4;n>=t;){var o=N[n];o&&o.batches&&o.batches.length>0&&(r.arrForEach(o.batches,(function(t){l.addBatch(t)?i=i||t&&t.count()>0:e=e.concat(t.events()),4===n?b-=t.count():S-=t.count()})),o.batches=[],o.iKeyMap={}),n--}e.length>0&&ue(J,e,r.EventsDiscardedReason.KillSwitch),i&&k>=t&&(k=-1,h=0)}),(function(){return{latency:t,sendType:n,sendReason:o}}),!s):(k=k>=0?Math.min(k,t):t,h=Math.max(h,o)),i}function oe(e,t){z(1,0,t),ne(),ie((function(){e&&e(),g.length>0?y=G((function(){y=null,oe(g.shift(),t)}),0):(y=null,B())}))}function ie(e){l.isCompletelyIdle()?e():y=G((function(){y=null,ie(e)}),.25)}function se(){(x={})[s]=[2,1,0],x[a]=[6,3,0],x[c]=[18,9,0]}function ae(t,n){var o=[],i=j;L&&(i=U),r.arrForEach(t,(function(t){t&&t.count()>0&&r.arrForEach(t.events(),(function(t){t&&(t.sync&&(t.latency=4,t.sync=!1),t.sendAttempt<i?(r.setProcessTelemetryTimings(t,e.identifier),F(t,!1)):o.push(t))}))})),o.length>0&&ue(J,o,r.EventsDiscardedReason.NonRetryableStatus),L&&$(2,2)}function ce(t,n){var o=e._notificationManager||{},i=o[t];if(i)try{i.apply(o,n)}catch(n){r._throwInternal(e.diagLog(),1,74,t+" notification failed: "+n)}}function ue(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];t&&t.length>0&&ce(e,[t].concat(n))}function le(e,t){for(var n=[],o=2;o<arguments.length;o++)n[o-2]=arguments[o];t&&t.length>0&&r.arrForEach(t,(function(t){t&&t.count()>0&&ce(e,[t.events()].concat(n))}))}function pe(e,t,n){e&&e.length>0&&ce("eventsSendRequest",[t>=1e3&&t<=1999?t-1e3:0,!0!==n])}function de(e,t){le("eventsSent",e,t),B()}function he(e,t){le(J,e,t>=8e3&&t<=8999?t-8e3:r.EventsDiscardedReason.Unknown)}function fe(e){le(J,e,r.EventsDiscardedReason.NonRetryableStatus),B()}function me(e,t){le(J,e,r.EventsDiscardedReason.Unknown),B()}function ve(){d=o&&o.disableAutoBatchFlushLimit?0:Math.max(1500,C/6)}H(),e._getDbgPlgTargets=function(){return[l]},e.initialize=function(s,a,c){r.doPerf(a,(function(){return"PostChannel:initialize"}),(function(){var d=a;t.initialize(s,a,c);try{a.addUnloadCb,f=r.mergeEvtNamespace(r.createUniqueNamespace(e.identifier),a.evtNamespace&&a.evtNamespace());var h=e._getTelCtx();s.extensionConfig[e.identifier]=s.extensionConfig[e.identifier]||{},o=h.getExtCfg(e.identifier),m=X(o.setTimeoutOverride,o.clearTimeoutOverride),D=!o.disableOptimizeObj&&r.isChromium(),function(e){var t=e.getWParam;e.getWParam=function(){var e=0;return o.ignoreMc1Ms0CookieProcessing&&(e|=2),e|t()}}(d),o.eventsLimitInMem>0&&(C=o.eventsLimitInMem),o.immediateEventLimit>0&&(E=o.immediateEventLimit),o.autoFlushEventsLimit>0&&(p=o.autoFlushEventsLimit),r.isNumber(o[ee])&&(j=o[ee]),r.isNumber(o[te])&&(U=o[te]),ve(),o.httpXHROverride&&o.httpXHROverride.sendPOST&&(u=o.httpXHROverride),r.isValueAssigned(s.anonCookieName)&&l.addQueryStringParameter("anoncknm",s.anonCookieName),l.sendHook=o.payloadPreprocessor,l.sendListener=o.payloadListener;var v=o.overrideEndpointUrl?o.overrideEndpointUrl:s.endpointUrl;e._notificationManager=s.extensionConfig.NotificationManager,l.initialize(v,e.core,e,u,o);var g=s.disablePageUnloadEvents||[];r.addPageUnloadEventListener(n,g,f),r.addPageHideEventListener(n,g,f),r.addPageShowEventListener(i,s.disablePageShowEvents,f)}catch(t){throw e.setInitialized(!1),t}}),(function(){return{coreConfig:s,core:a,extensions:c}}))},e.processTelemetry=function(t,n){r.setProcessTelemetryTimings(t,e.identifier);var i=(n=e._getTelCtx(n)).getExtCfg(e.identifier),s=!!o.disableTelemetry;i&&(s=s||!!i.disableTelemetry);var a=t;!s&&!v&&(o[Z]&&(a.iKey=o[Z]),i&&i[Z]&&(a.iKey=i[Z]),F(a,!0),L?$(2,2):B()),e.processNext(a,n)},e._doTeardown=function(e,t){$(2,2),v=!0,l.teardown(),r.removePageUnloadEventListener(null,f),r.removePageHideEventListener(null,f),r.removePageShowEventListener(null,f),H()},e.setEventQueueLimits=function(e,t){C=e>0?e:1e4,p=t>0?t:0,ve();var n=S>e;if(!n&&d>0)for(var o=1;!n&&o<=3;o++){var i=N[o];i&&i.batches&&r.arrForEach(i.batches,(function(e){e&&e.count()>=d&&(n=!0)}))}Q(!0,n)},e.pause=function(){V(),_=!0,l.pause()},e.resume=function(){_=!1,l.resume(),B()},e.addResponseHandler=function(e){l._responseHandlers.push(e)},e._loadTransmitProfiles=function(e){V(),se(),w=s,B(),r.objForEachKey(e,(function(e,t){var n=t.length;if(n>=2){var r=n>2?t[2]:0;if(t.splice(0,n-2),t[1]<0&&(t[0]=-1),t[1]>0&&t[0]>0){var o=t[0]/t[1];t[0]=Math.ceil(o)*t[1]}r>=0&&t[1]>=0&&r>t[1]&&(r=t[1]),t.push(r),x[e]=t}}))},e.flush=function(e,t,n){if(void 0===e&&(e=!0),!_)if(n=n||1,e)null==y?(V(),re(1,0,n),y=G((function(){y=null,oe(t,n)}),0)):g.push(t);else{var r=V();z(1,1,n),null!=t&&t(),r&&B()}},e.setMsaAuthTicket=function(e){l.addHeader(T,e)},e.hasEvents=q,e._setTransmitProfile=function(e){w!==e&&void 0!==x[e]&&(V(),w=e,B())},e._backOffTransmission=function(){P<4&&(P++,V(),B())},e._clearBackOff=function(){P&&(P=0,V(),B())},r.objDefineAccessors(e,"_setTimeoutOverride",(function(){return m.set}),(function(e){m=X(e,m.clear)})),r.objDefineAccessors(e,"_clearTimeoutOverride",(function(){return m.clear}),(function(e){m=X(m.set,e)}))})),t}return t.__extendsFn(n,e),n}(r.BaseTelemetryPlugin);e.BE_PROFILE=c,e.NRT_PROFILE=a,e.PostChannel=ne,e.RT_PROFILE=s,function(e,t,n){var r=Object.defineProperty;if(r)try{return r(e,t,n)}catch{}n&&void 0!==typeof n.value&&(e[t]=n.value)}(e,"__esModule",{value:!0})},"object"==typeof s&&typeof a<"u"?c(s,A(),x(),w()):(o=[t,n(2284),n(1356),n(1318)],void 0===(i="function"==typeof(r=c)?r.apply(t,o):r)||(e.exports=i))})),R=b(((e,t)=>{"use strict";var n=function(){function e(){}return e.info=function(t){for(var n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];e.enableDebug&&console.info(e.TAG+t,n)},e.warn=function(t){for(var n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];e.disableWarnings||console.warn(e.TAG+t,n)},e.enableDebug=!1,e.disableWarnings=!1,e.disableErrors=!1,e.TAG="ApplicationInsights:",e}();t.exports=n})),P=b((e=>{"use strict";var t=e&&e.__assign||function(){return t=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},t.apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.AsyncScopeManager=e.OpenTelemetryScopeManagerWrapper=void 0;var r=wr(),o=n(4434),i=function(){function e(){}return e.prototype.active=function(){var e=this,n=r.CorrelationContextManager.getCurrentContext();return t(t({},n),{getValue:function(t){return e._activeSymbol?t===e._activeSymbol&&n:(e._activeSymbol=t,n)},setValue:function(){}})},e.prototype.with=function(t,n){var o=t.parentSpanId,i=t.name,s=e._spanToContext(t,o,i);return r.CorrelationContextManager.runWithContext(s,n)()},e.prototype.bind=function(e){return"function"==typeof e?r.CorrelationContextManager.wrapCallback(e):(e instanceof o.EventEmitter&&r.CorrelationContextManager.wrapEmitter(e),e)},e.prototype.enable=function(){return r.CorrelationContextManager.enable(),this},e.prototype.disable=function(){return r.CorrelationContextManager.disable(),this},e._spanToContext=function(e,n,o){var i=n?"|"+e.spanContext().traceId+"."+n+".":e.spanContext().traceId,s=t(t({},e.spanContext()),{traceFlags:e.spanContext().traceFlags});return r.CorrelationContextManager.spanToContextObject(s,i,o)},e}();e.OpenTelemetryScopeManagerWrapper=i,e.AsyncScopeManager=new i})),O=b(((e,t)=>{var n;e=t.exports=K,n="object"==typeof process&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?function(){var e=Array.prototype.slice.call(arguments,0);e.unshift("SEMVER"),console.log.apply(console,e)}:function(){},e.SEMVER_SPEC_VERSION="2.0.0";var r=256,o=Number.MAX_SAFE_INTEGER||9007199254740991,i=e.re=[],s=e.src=[],a=0,c=a++;s[c]="0|[1-9]\\d*";var u=a++;s[u]="[0-9]+";var l=a++;s[l]="\\d*[a-zA-Z-][a-zA-Z0-9-]*";var p=a++;s[p]="("+s[c]+")\\.("+s[c]+")\\.("+s[c]+")";var d=a++;s[d]="("+s[u]+")\\.("+s[u]+")\\.("+s[u]+")";var h=a++;s[h]="(?:"+s[c]+"|"+s[l]+")";var f=a++;s[f]="(?:"+s[u]+"|"+s[l]+")";var m=a++;s[m]="(?:-("+s[h]+"(?:\\."+s[h]+")*))";var v=a++;s[v]="(?:-?("+s[f]+"(?:\\."+s[f]+")*))";var g=a++;s[g]="[0-9A-Za-z-]+";var y=a++;s[y]="(?:\\+("+s[g]+"(?:\\."+s[g]+")*))";var _=a++,b="v?"+s[p]+s[m]+"?"+s[y]+"?";s[_]="^"+b+"$";var E="[v=\\s]*"+s[d]+s[v]+"?"+s[y]+"?",T=a++;s[T]="^"+E+"$";var S=a++;s[S]="((?:<|>)?=?)";var C=a++;s[C]=s[u]+"|x|X|\\*";var x=a++;s[x]=s[c]+"|x|X|\\*";var w=a++;s[w]="[v=\\s]*("+s[x]+")(?:\\.("+s[x]+")(?:\\.("+s[x]+")(?:"+s[m]+")?"+s[y]+"?)?)?";var A=a++;s[A]="[v=\\s]*("+s[C]+")(?:\\.("+s[C]+")(?:\\.("+s[C]+")(?:"+s[v]+")?"+s[y]+"?)?)?";var I=a++;s[I]="^"+s[S]+"\\s*"+s[w]+"$";var R=a++;s[R]="^"+s[S]+"\\s*"+s[A]+"$";var P=a++;s[P]="(?:^|[^\\d])(\\d{1,16})(?:\\.(\\d{1,16}))?(?:\\.(\\d{1,16}))?(?:$|[^\\d])";var O=a++;s[O]="(?:~>?)";var N=a++;s[N]="(\\s*)"+s[O]+"\\s+",i[N]=new RegExp(s[N],"g");var k=a++;s[k]="^"+s[O]+s[w]+"$";var D=a++;s[D]="^"+s[O]+s[A]+"$";var M=a++;s[M]="(?:\\^)";var L=a++;s[L]="(\\s*)"+s[M]+"\\s+",i[L]=new RegExp(s[L],"g");var j=a++;s[j]="^"+s[M]+s[w]+"$";var U=a++;s[U]="^"+s[M]+s[A]+"$";var F=a++;s[F]="^"+s[S]+"\\s*("+E+")$|^$";var z=a++;s[z]="^"+s[S]+"\\s*("+b+")$|^$";var q=a++;s[q]="(\\s*)"+s[S]+"\\s*("+E+"|"+s[w]+")",i[q]=new RegExp(s[q],"g");var B=a++;s[B]="^\\s*("+s[w]+")\\s+-\\s+("+s[w]+")\\s*$";var H=a++;s[H]="^\\s*("+s[A]+")\\s+-\\s+("+s[A]+")\\s*$";var G,V=a++;for(s[V]="(<|>)?=?\\s*\\*",G=0;G<35;G++)n(G,s[G]),i[G]||(i[G]=new RegExp(s[G]));function $(e,t){if((!t||"object"!=typeof t)&&(t={loose:!!t,includePrerelease:!1}),e instanceof K)return e;if("string"!=typeof e||e.length>r)return null;if(!(t.loose?i[T]:i[_]).test(e))return null;try{return new K(e,t)}catch{return null}}function K(e,t){if((!t||"object"!=typeof t)&&(t={loose:!!t,includePrerelease:!1}),e instanceof K){if(e.loose===t.loose)return e;e=e.version}else if("string"!=typeof e)throw new TypeError("Invalid Version: "+e);if(e.length>r)throw new TypeError("version is longer than "+r+" characters");if(!(this instanceof K))return new K(e,t);n("SemVer",e,t),this.options=t,this.loose=!!t.loose;var s=e.trim().match(t.loose?i[T]:i[_]);if(!s)throw new TypeError("Invalid Version: "+e);if(this.raw=e,this.major=+s[1],this.minor=+s[2],this.patch=+s[3],this.major>o||this.major<0)throw new TypeError("Invalid major version");if(this.minor>o||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>o||this.patch<0)throw new TypeError("Invalid patch version");s[4]?this.prerelease=s[4].split(".").map((function(e){if(/^[0-9]+$/.test(e)){var t=+e;if(t>=0&&t<o)return t}return e})):this.prerelease=[],this.build=s[5]?s[5].split("."):[],this.format()}e.parse=$,e.valid=function(e,t){var n=$(e,t);return n?n.version:null},e.clean=function(e,t){var n=$(e.trim().replace(/^[=v]+/,""),t);return n?n.version:null},e.SemVer=K,K.prototype.format=function(){return this.version=this.major+"."+this.minor+"."+this.patch,this.prerelease.length&&(this.version+="-"+this.prerelease.join(".")),this.version},K.prototype.toString=function(){return this.version},K.prototype.compare=function(e){return n("SemVer.compare",this.version,this.options,e),e instanceof K||(e=new K(e,this.options)),this.compareMain(e)||this.comparePre(e)},K.prototype.compareMain=function(e){return e instanceof K||(e=new K(e,this.options)),Q(this.major,e.major)||Q(this.minor,e.minor)||Q(this.patch,e.patch)},K.prototype.comparePre=function(e){if(e instanceof K||(e=new K(e,this.options)),this.prerelease.length&&!e.prerelease.length)return-1;if(!this.prerelease.length&&e.prerelease.length)return 1;if(!this.prerelease.length&&!e.prerelease.length)return 0;var t=0;do{var r=this.prerelease[t],o=e.prerelease[t];if(n("prerelease compare",t,r,o),void 0===r&&void 0===o)return 0;if(void 0===o)return 1;if(void 0===r)return-1;if(r!==o)return Q(r,o)}while(++t)},K.prototype.inc=function(e,t){switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",t);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",t);break;case"prepatch":this.prerelease.length=0,this.inc("patch",t),this.inc("pre",t);break;case"prerelease":0===this.prerelease.length&&this.inc("patch",t),this.inc("pre",t);break;case"major":(0!==this.minor||0!==this.patch||0===this.prerelease.length)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(0!==this.patch||0===this.prerelease.length)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":0===this.prerelease.length&&this.patch++,this.prerelease=[];break;case"pre":if(0===this.prerelease.length)this.prerelease=[0];else{for(var n=this.prerelease.length;--n>=0;)"number"==typeof this.prerelease[n]&&(this.prerelease[n]++,n=-2);-1===n&&this.prerelease.push(0)}t&&(this.prerelease[0]===t?isNaN(this.prerelease[1])&&(this.prerelease=[t,0]):this.prerelease=[t,0]);break;default:throw new Error("invalid increment argument: "+e)}return this.format(),this.raw=this.version,this},e.inc=function(e,t,n,r){"string"==typeof n&&(r=n,n=void 0);try{return new K(e,n).inc(t,r).version}catch{return null}},e.diff=function(e,t){if(Z(e,t))return null;var n=$(e),r=$(t),o="";if(n.prerelease.length||r.prerelease.length){o="pre";var i="prerelease"}for(var s in n)if(("major"===s||"minor"===s||"patch"===s)&&n[s]!==r[s])return o+s;return i},e.compareIdentifiers=Q;var W=/^[0-9]+$/;function Q(e,t){var n=W.test(e),r=W.test(t);return n&&r&&(e=+e,t=+t),e===t?0:n&&!r?-1:r&&!n?1:e<t?-1:1}function Y(e,t,n){return new K(e,n).compare(new K(t,n))}function X(e,t,n){return Y(e,t,n)>0}function J(e,t,n){return Y(e,t,n)<0}function Z(e,t,n){return 0===Y(e,t,n)}function ee(e,t,n){return 0!==Y(e,t,n)}function te(e,t,n){return Y(e,t,n)>=0}function ne(e,t,n){return Y(e,t,n)<=0}function re(e,t,n,r){switch(t){case"===":return"object"==typeof e&&(e=e.version),"object"==typeof n&&(n=n.version),e===n;case"!==":return"object"==typeof e&&(e=e.version),"object"==typeof n&&(n=n.version),e!==n;case"":case"=":case"==":return Z(e,n,r);case"!=":return ee(e,n,r);case">":return X(e,n,r);case">=":return te(e,n,r);case"<":return J(e,n,r);case"<=":return ne(e,n,r);default:throw new TypeError("Invalid operator: "+t)}}function oe(e,t){if((!t||"object"!=typeof t)&&(t={loose:!!t,includePrerelease:!1}),e instanceof oe){if(e.loose===!!t.loose)return e;e=e.value}if(!(this instanceof oe))return new oe(e,t);n("comparator",e,t),this.options=t,this.loose=!!t.loose,this.parse(e),this.semver===ie?this.value="":this.value=this.operator+this.semver.version,n("comp",this)}e.rcompareIdentifiers=function(e,t){return Q(t,e)},e.major=function(e,t){return new K(e,t).major},e.minor=function(e,t){return new K(e,t).minor},e.patch=function(e,t){return new K(e,t).patch},e.compare=Y,e.compareLoose=function(e,t){return Y(e,t,!0)},e.rcompare=function(e,t,n){return Y(t,e,n)},e.sort=function(t,n){return t.sort((function(t,r){return e.compare(t,r,n)}))},e.rsort=function(t,n){return t.sort((function(t,r){return e.rcompare(t,r,n)}))},e.gt=X,e.lt=J,e.eq=Z,e.neq=ee,e.gte=te,e.lte=ne,e.cmp=re,e.Comparator=oe;var ie={};function se(e,t){if((!t||"object"!=typeof t)&&(t={loose:!!t,includePrerelease:!1}),e instanceof se)return e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease?e:new se(e.raw,t);if(e instanceof oe)return new se(e.value,t);if(!(this instanceof se))return new se(e,t);if(this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease,this.raw=e,this.set=e.split(/\s*\|\|\s*/).map((function(e){return this.parseRange(e.trim())}),this).filter((function(e){return e.length})),!this.set.length)throw new TypeError("Invalid SemVer Range: "+e);this.format()}function ae(e){return!e||"x"===e.toLowerCase()||"*"===e}function ce(e,t,n,r,o,i,s,a,c,u,l,p,d){return((t=ae(n)?"":ae(r)?">="+n+".0.0":ae(o)?">="+n+"."+r+".0":">="+t)+" "+(a=ae(c)?"":ae(u)?"<"+(+c+1)+".0.0":ae(l)?"<"+c+"."+(+u+1)+".0":p?"<="+c+"."+u+"."+l+"-"+p:"<="+a)).trim()}function ue(e,t,r){for(var o=0;o<e.length;o++)if(!e[o].test(t))return!1;if(t.prerelease.length&&!r.includePrerelease){for(o=0;o<e.length;o++)if(n(e[o].semver),e[o].semver!==ie&&e[o].semver.prerelease.length>0){var i=e[o].semver;if(i.major===t.major&&i.minor===t.minor&&i.patch===t.patch)return!0}return!1}return!0}function le(e,t,n){try{t=new se(t,n)}catch{return!1}return t.test(e)}function pe(e,t,n,r){var o,i,s,a,c;switch(e=new K(e,r),t=new se(t,r),n){case">":o=X,i=ne,s=J,a=">",c=">=";break;case"<":o=J,i=te,s=X,a="<",c="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(le(e,t,r))return!1;for(var u=0;u<t.set.length;++u){var l=t.set[u],p=null,d=null;if(l.forEach((function(e){e.semver===ie&&(e=new oe(">=0.0.0")),p=p||e,d=d||e,o(e.semver,p.semver,r)?p=e:s(e.semver,d.semver,r)&&(d=e)})),p.operator===a||p.operator===c||(!d.operator||d.operator===a)&&i(e,d.semver))return!1;if(d.operator===c&&s(e,d.semver))return!1}return!0}oe.prototype.parse=function(e){var t=this.options.loose?i[F]:i[z],n=e.match(t);if(!n)throw new TypeError("Invalid comparator: "+e);this.operator=n[1],"="===this.operator&&(this.operator=""),n[2]?this.semver=new K(n[2],this.options.loose):this.semver=ie},oe.prototype.toString=function(){return this.value},oe.prototype.test=function(e){return n("Comparator.test",e,this.options.loose),this.semver===ie||("string"==typeof e&&(e=new K(e,this.options)),re(e,this.operator,this.semver,this.options))},oe.prototype.intersects=function(e,t){if(!(e instanceof oe))throw new TypeError("a Comparator is required");var n;if((!t||"object"!=typeof t)&&(t={loose:!!t,includePrerelease:!1}),""===this.operator)return n=new se(e.value,t),le(this.value,n,t);if(""===e.operator)return n=new se(this.value,t),le(e.semver,n,t);var r=!(">="!==this.operator&&">"!==this.operator||">="!==e.operator&&">"!==e.operator),o=!("<="!==this.operator&&"<"!==this.operator||"<="!==e.operator&&"<"!==e.operator),i=this.semver.version===e.semver.version,s=!(">="!==this.operator&&"<="!==this.operator||">="!==e.operator&&"<="!==e.operator),a=re(this.semver,"<",e.semver,t)&&(">="===this.operator||">"===this.operator)&&("<="===e.operator||"<"===e.operator),c=re(this.semver,">",e.semver,t)&&("<="===this.operator||"<"===this.operator)&&(">="===e.operator||">"===e.operator);return r||o||i&&s||a||c},e.Range=se,se.prototype.format=function(){return this.range=this.set.map((function(e){return e.join(" ").trim()})).join("||").trim(),this.range},se.prototype.toString=function(){return this.range},se.prototype.parseRange=function(e){var t=this.options.loose;e=e.trim();var r=t?i[H]:i[B];e=e.replace(r,ce),n("hyphen replace",e),e=e.replace(i[q],"$1$2$3"),n("comparator trim",e,i[q]),e=(e=(e=e.replace(i[N],"$1~")).replace(i[L],"$1^")).split(/\s+/).join(" ");var o=t?i[F]:i[z],s=e.split(" ").map((function(e){return function(e,t){return n("comp",e,t),e=function(e,t){return e.trim().split(/\s+/).map((function(e){return function(e,t){n("caret",e,t);var r=t.loose?i[U]:i[j];return e.replace(r,(function(t,r,o,i,s){var a;return n("caret",e,t,r,o,i,s),ae(r)?a="":ae(o)?a=">="+r+".0.0 <"+(+r+1)+".0.0":ae(i)?a="0"===r?">="+r+"."+o+".0 <"+r+"."+(+o+1)+".0":">="+r+"."+o+".0 <"+(+r+1)+".0.0":s?(n("replaceCaret pr",s),a="0"===r?"0"===o?">="+r+"."+o+"."+i+"-"+s+" <"+r+"."+o+"."+(+i+1):">="+r+"."+o+"."+i+"-"+s+" <"+r+"."+(+o+1)+".0":">="+r+"."+o+"."+i+"-"+s+" <"+(+r+1)+".0.0"):(n("no pr"),a="0"===r?"0"===o?">="+r+"."+o+"."+i+" <"+r+"."+o+"."+(+i+1):">="+r+"."+o+"."+i+" <"+r+"."+(+o+1)+".0":">="+r+"."+o+"."+i+" <"+(+r+1)+".0.0"),n("caret return",a),a}))}(e,t)})).join(" ")}(e,t),n("caret",e),e=function(e,t){return e.trim().split(/\s+/).map((function(e){return function(e,t){var r=t.loose?i[D]:i[k];return e.replace(r,(function(t,r,o,i,s){var a;return n("tilde",e,t,r,o,i,s),ae(r)?a="":ae(o)?a=">="+r+".0.0 <"+(+r+1)+".0.0":ae(i)?a=">="+r+"."+o+".0 <"+r+"."+(+o+1)+".0":s?(n("replaceTilde pr",s),a=">="+r+"."+o+"."+i+"-"+s+" <"+r+"."+(+o+1)+".0"):a=">="+r+"."+o+"."+i+" <"+r+"."+(+o+1)+".0",n("tilde return",a),a}))}(e,t)})).join(" ")}(e,t),n("tildes",e),e=function(e,t){return n("replaceXRanges",e,t),e.split(/\s+/).map((function(e){return function(e,t){e=e.trim();var r=t.loose?i[R]:i[I];return e.replace(r,(function(t,r,o,i,s,a){n("xRange",e,t,r,o,i,s,a);var c=ae(o),u=c||ae(i),l=u||ae(s);return"="===r&&l&&(r=""),c?t=">"===r||"<"===r?"<0.0.0":"*":r&&l?(u&&(i=0),s=0,">"===r?(r=">=",u?(o=+o+1,i=0,s=0):(i=+i+1,s=0)):"<="===r&&(r="<",u?o=+o+1:i=+i+1),t=r+o+"."+i+"."+s):u?t=">="+o+".0.0 <"+(+o+1)+".0.0":l&&(t=">="+o+"."+i+".0 <"+o+"."+(+i+1)+".0"),n("xRange return",t),t}))}(e,t)})).join(" ")}(e,t),n("xrange",e),e=function(e,t){return n("replaceStars",e,t),e.trim().replace(i[V],"")}(e,t),n("stars",e),e}(e,this.options)}),this).join(" ").split(/\s+/);return this.options.loose&&(s=s.filter((function(e){return!!e.match(o)}))),s.map((function(e){return new oe(e,this.options)}),this)},se.prototype.intersects=function(e,t){if(!(e instanceof se))throw new TypeError("a Range is required");return this.set.some((function(n){return n.every((function(n){return e.set.some((function(e){return e.every((function(e){return n.intersects(e,t)}))}))}))}))},e.toComparators=function(e,t){return new se(e,t).set.map((function(e){return e.map((function(e){return e.value})).join(" ").trim().split(" ")}))},se.prototype.test=function(e){if(!e)return!1;"string"==typeof e&&(e=new K(e,this.options));for(var t=0;t<this.set.length;t++)if(ue(this.set[t],e,this.options))return!0;return!1},e.satisfies=le,e.maxSatisfying=function(e,t,n){var r=null,o=null;try{var i=new se(t,n)}catch{return null}return e.forEach((function(e){i.test(e)&&(!r||-1===o.compare(e))&&(o=new K(r=e,n))})),r},e.minSatisfying=function(e,t,n){var r=null,o=null;try{var i=new se(t,n)}catch{return null}return e.forEach((function(e){i.test(e)&&(!r||1===o.compare(e))&&(o=new K(r=e,n))})),r},e.minVersion=function(e,t){e=new se(e,t);var n=new K("0.0.0");if(e.test(n)||(n=new K("0.0.0-0"),e.test(n)))return n;n=null;for(var r=0;r<e.set.length;++r)e.set[r].forEach((function(e){var t=new K(e.semver.version);switch(e.operator){case">":0===t.prerelease.length?t.patch++:t.prerelease.push(0),t.raw=t.format();case"":case">=":(!n||X(n,t))&&(n=t);break;case"<":case"<=":break;default:throw new Error("Unexpected operation: "+e.operator)}}));return n&&e.test(n)?n:null},e.validRange=function(e,t){try{return new se(e,t).range||"*"}catch{return null}},e.ltr=function(e,t,n){return pe(e,t,"<",n)},e.gtr=function(e,t,n){return pe(e,t,">",n)},e.outside=pe,e.prerelease=function(e,t){var n=$(e,t);return n&&n.prerelease.length?n.prerelease:null},e.intersects=function(e,t,n){return e=new se(e,n),t=new se(t,n),e.intersects(t)},e.coerce=function(e){if(e instanceof K)return e;if("string"!=typeof e)return null;var t=e.match(i[P]);return null==t?null:$(t[1]+"."+(t[2]||"0")+"."+(t[3]||"0"))}})),N=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.makePatchingRequire=void 0;var t=n(6928),r=O(),o=n(3339),i=Object.keys(process.binding("natives")),s=o.prototype.require;e.makePatchingRequire=function(e){var n={};return function(a){var c=s.apply(this,arguments);if(e[a]){var u=o._resolveFilename(a,this);if(n.hasOwnProperty(u))return n[u];var l=void 0;if(i.indexOf(a)<0)try{l=s.call(this,t.join(a,"package.json")).version}catch{return c}else l=process.version.substring(1);var p=l.indexOf("-");p>=0&&(l=l.substring(0,p));for(var d=c,h=0,f=e[a];h<f.length;h++){var m=f[h];r.satisfies(l,m.versionSpecifier)&&(d=m.patch(d,u))}return n[u]=d}return c}}})),k=b(((e,t)=>{t.exports={name:"diagnostic-channel",version:"1.0.0",main:"./dist/src/channel.js",types:"./dist/src/channel.d.ts",scripts:{build:"tsc",lint:"tslint -c tslint.json -p tsconfig.json",clean:"rimraf ./dist",test:"mocha ./dist/tests/**/*.js"},homepage:"https://github.com/Microsoft/node-diagnostic-channel",bugs:{url:"https://github.com/Microsoft/node-diagnostic-channel/issues"},repository:{type:"git",url:"https://github.com/Microsoft/node-diagnostic-channel.git"},description:"Provides a context-saving pub/sub channel to connect diagnostic event publishers and subscribers",dependencies:{semver:"^5.3.0"},devDependencies:{"@types/mocha":"^2.2.40","@types/node":"~8.0.0",mocha:"^3.2.0",rimraf:"^2.6.1",tslint:"^5.0.0",typescript:"4.1.2"},files:["dist/src/**/*.d.ts","dist/src/**/*.js","LICENSE","README.md","package.json"],license:"MIT"}})),D=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.channel=e.makePatchingRequire=void 0;var t=N(),r=N();Object.defineProperty(e,"makePatchingRequire",{enumerable:!0,get:function(){return r.makePatchingRequire}});var o=function(e){return!0},i=function(){function e(){this.version=k().version,this.subscribers={},this.contextPreservationFunction=function(e){return e},this.knownPatches={},this.currentlyPublishing=!1}return e.prototype.shouldPublish=function(e){var t=this.subscribers[e];return!!t&&t.some((function(e){var t=e.filter;return!t||t(!1)}))},e.prototype.publish=function(e,t){if(!this.currentlyPublishing){var n=this.subscribers[e];if(n){var r={timestamp:Date.now(),data:t};this.currentlyPublishing=!0,n.forEach((function(e){var t=e.listener,n=e.filter;try{n&&n(!0)&&t(r)}catch{}})),this.currentlyPublishing=!1}}},e.prototype.subscribe=function(e,t,n){void 0===n&&(n=o),this.subscribers[e]||(this.subscribers[e]=[]),this.subscribers[e].push({listener:t,filter:n})},e.prototype.unsubscribe=function(e,t,n){void 0===n&&(n=o);var r=this.subscribers[e];if(r)for(var i=0;i<r.length;++i)if(r[i].listener===t&&r[i].filter===n)return r.splice(i,1),!0;return!1},e.prototype.reset=function(){var e=this;this.subscribers={},this.contextPreservationFunction=function(e){return e},Object.getOwnPropertyNames(this.knownPatches).forEach((function(t){return delete e.knownPatches[t]}))},e.prototype.bindToContext=function(e){return this.contextPreservationFunction(e)},e.prototype.addContextPreservation=function(e){var t=this.contextPreservationFunction;this.contextPreservationFunction=function(n){return e(t(n))}},e.prototype.registerMonkeyPatch=function(e,t){this.knownPatches[e]||(this.knownPatches[e]=[]),this.knownPatches[e].push(t)},e.prototype.getPatchesObject=function(){return this.knownPatches},e}();global.diagnosticsSource||(global.diagnosticsSource=new i,n(3339).prototype.require=t.makePatchingRequire(global.diagnosticsSource.getPatchesObject())),e.channel=global.diagnosticsSource})),M=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),L=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e._globalThis=void 0,e._globalThis="object"==typeof globalThis?globalThis:global})),j=b((e=>{"use strict";var t=e&&e.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=e&&e.__exportStar||function(e,n){for(var r in e)"default"!==r&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(L(),e)})),U=b((e=>{"use strict";var t=e&&e.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=e&&e.__exportStar||function(e,n){for(var r in e)"default"!==r&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(j(),e)})),F=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.VERSION=void 0,e.VERSION="1.0.3"})),z=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.isCompatible=e._makeCompatibilityCheck=void 0;var t=F(),n=/^(\d+)\.(\d+)\.(\d+)(-(.+))?$/;function r(e){var t=new Set([e]),r=new Set,o=e.match(n);if(!o)return function(){return!1};var i=+o[1],s=+o[2],a=+o[3];if(null!=o[4])return function(t){return t===e};function c(e){return r.add(e),!1}function u(e){return t.add(e),!0}return function(e){if(t.has(e))return!0;if(r.has(e))return!1;var o=e.match(n);if(!o)return c(e);var l=+o[1],p=+o[2],d=+o[3];return null!=o[4]||i!==l?c(e):0===i?s===p&&a<=d?u(e):c(e):s<=p?u(e):c(e)}}e._makeCompatibilityCheck=r,e.isCompatible=r(t.VERSION)})),q=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.unregisterGlobal=e.getGlobal=e.registerGlobal=void 0;var t=U(),n=F(),r=z(),o=n.VERSION.split(".")[0],i=Symbol.for("opentelemetry.js.api."+o),s=t._globalThis;e.registerGlobal=function(e,t,r,o){var a;void 0===o&&(o=!1);var c=s[i]=null!==(a=s[i])&&void 0!==a?a:{version:n.VERSION};if(!o&&c[e]){var u=new Error("@opentelemetry/api: Attempted duplicate registration of API: "+e);return r.error(u.stack||u.message),!1}return c.version!==n.VERSION?(u=new Error("@opentelemetry/api: All API registration versions must match"),r.error(u.stack||u.message),!1):(c[e]=t,r.debug("@opentelemetry/api: Registered a global for "+e+" v"+n.VERSION+"."),!0)},e.getGlobal=function(e){var t,n,o=null===(t=s[i])||void 0===t?void 0:t.version;if(o&&r.isCompatible(o))return null===(n=s[i])||void 0===n?void 0:n[e]},e.unregisterGlobal=function(e,t){t.debug("@opentelemetry/api: Unregistering a global for "+e+" v"+n.VERSION+".");var r=s[i];r&&delete r[e]}})),B=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DiagComponentLogger=void 0;var t=q(),n=function(){function e(e){this._namespace=e.namespace||"DiagComponentLogger"}return e.prototype.debug=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return r("debug",this._namespace,e)},e.prototype.error=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return r("error",this._namespace,e)},e.prototype.info=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return r("info",this._namespace,e)},e.prototype.warn=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return r("warn",this._namespace,e)},e.prototype.verbose=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return r("verbose",this._namespace,e)},e}();function r(e,n,r){var o=t.getGlobal("diag");if(o)return r.unshift(n),o[e].apply(o,r)}e.DiagComponentLogger=n})),H=b((e=>{"use strict";var t;Object.defineProperty(e,"__esModule",{value:!0}),e.DiagLogLevel=void 0,(t=e.DiagLogLevel||(e.DiagLogLevel={}))[t.NONE=0]="NONE",t[t.ERROR=30]="ERROR",t[t.WARN=50]="WARN",t[t.INFO=60]="INFO",t[t.DEBUG=70]="DEBUG",t[t.VERBOSE=80]="VERBOSE",t[t.ALL=9999]="ALL"})),G=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.createLogLevelDiagLogger=void 0;var t=H();e.createLogLevelDiagLogger=function(e,n){function r(t,r){var o=n[t];return"function"==typeof o&&e>=r?o.bind(n):function(){}}return e<t.DiagLogLevel.NONE?e=t.DiagLogLevel.NONE:e>t.DiagLogLevel.ALL&&(e=t.DiagLogLevel.ALL),n=n||{},{error:r("error",t.DiagLogLevel.ERROR),warn:r("warn",t.DiagLogLevel.WARN),info:r("info",t.DiagLogLevel.INFO),debug:r("debug",t.DiagLogLevel.DEBUG),verbose:r("verbose",t.DiagLogLevel.VERBOSE)}}})),V=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DiagAPI=void 0;var t=B(),n=G(),r=H(),o=q(),i=function(){function e(){function e(e){return function(){var t=o.getGlobal("diag");if(t)return t[e].apply(t,arguments)}}var i=this;i.setLogger=function(e,t){var s,a;if(void 0===t&&(t=r.DiagLogLevel.INFO),e===i){var c=new Error("Cannot use diag as the logger for itself. Please use a DiagLogger implementation like ConsoleDiagLogger or a custom implementation");return i.error(null!==(s=c.stack)&&void 0!==s?s:c.message),!1}var u=o.getGlobal("diag"),l=n.createLogLevelDiagLogger(t,e);if(u){var p=null!==(a=(new Error).stack)&&void 0!==a?a:"<failed to generate stacktrace>";u.warn("Current logger will be overwritten from "+p),l.warn("Current logger will overwrite one already registered from "+p)}return o.registerGlobal("diag",l,i,!0)},i.disable=function(){o.unregisterGlobal("diag",i)},i.createComponentLogger=function(e){return new t.DiagComponentLogger(e)},i.verbose=e("verbose"),i.debug=e("debug"),i.info=e("info"),i.warn=e("warn"),i.error=e("error")}return e.instance=function(){return this._instance||(this._instance=new e),this._instance},e}();e.DiagAPI=i})),$=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.BaggageImpl=void 0;var t=function(){function e(e){this._entries=e?new Map(e):new Map}return e.prototype.getEntry=function(e){var t=this._entries.get(e);if(t)return Object.assign({},t)},e.prototype.getAllEntries=function(){return Array.from(this._entries.entries()).map((function(e){return[e[0],e[1]]}))},e.prototype.setEntry=function(t,n){var r=new e(this._entries);return r._entries.set(t,n),r},e.prototype.removeEntry=function(t){var n=new e(this._entries);return n._entries.delete(t),n},e.prototype.removeEntries=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];for(var r=new e(this._entries),o=0,i=t;o<i.length;o++){var s=i[o];r._entries.delete(s)}return r},e.prototype.clear=function(){return new e},e}();e.BaggageImpl=t})),K=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.baggageEntryMetadataSymbol=void 0,e.baggageEntryMetadataSymbol=Symbol("BaggageEntryMetadata")})),W=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.baggageEntryMetadataFromString=e.createBaggage=void 0;var t=V(),n=$(),r=K(),o=t.DiagAPI.instance();e.createBaggage=function(e){return void 0===e&&(e={}),new n.BaggageImpl(new Map(Object.entries(e)))},e.baggageEntryMetadataFromString=function(e){return"string"!=typeof e&&(o.error("Cannot create baggage metadata from unknown type: "+typeof e),e=""),{__TYPE__:r.baggageEntryMetadataSymbol,toString:function(){return e}}}})),Q=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Y=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),X=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DiagConsoleLogger=void 0;var t=[{n:"error",c:"error"},{n:"warn",c:"warn"},{n:"info",c:"info"},{n:"debug",c:"debug"},{n:"verbose",c:"trace"}];e.DiagConsoleLogger=function(){function e(e){return function(){var t=arguments;if(console){var n=console[e];if("function"!=typeof n&&(n=console.log),"function"==typeof n)return n.apply(console,t)}}}for(var n=0;n<t.length;n++)this[t[n].n]=e(t[n].c)}})),J=b((e=>{"use strict";var t=e&&e.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=e&&e.__exportStar||function(e,n){for(var r in e)"default"!==r&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(X(),e),n(H(),e)})),Z=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.defaultTextMapSetter=e.defaultTextMapGetter=void 0,e.defaultTextMapGetter={get:function(e,t){if(null!=e)return e[t]},keys:function(e){return null==e?[]:Object.keys(e)}},e.defaultTextMapSetter={set:function(e,t,n){null!=e&&(e[t]=n)}}})),ee=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),te=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),ne=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ROOT_CONTEXT=e.createContextKey=void 0,e.createContextKey=function(e){return Symbol.for(e)};e.ROOT_CONTEXT=new function e(t){var n=this;n._currentContext=t?new Map(t):new Map,n.getValue=function(e){return n._currentContext.get(e)},n.setValue=function(t,r){var o=new e(n._currentContext);return o._currentContext.set(t,r),o},n.deleteValue=function(t){var r=new e(n._currentContext);return r._currentContext.delete(t),r}}})),re=b((e=>{"use strict";var t=e&&e.__spreadArray||function(e,t){for(var n=0,r=t.length,o=e.length;n<r;n++,o++)e[o]=t[n];return e};Object.defineProperty(e,"__esModule",{value:!0}),e.NoopContextManager=void 0;var n=ne(),r=function(){function e(){}return e.prototype.active=function(){return n.ROOT_CONTEXT},e.prototype.with=function(e,n,r){for(var o=[],i=3;i<arguments.length;i++)o[i-3]=arguments[i];return n.call.apply(n,t([r],o))},e.prototype.bind=function(e,t){return t},e.prototype.enable=function(){return this},e.prototype.disable=function(){return this},e}();e.NoopContextManager=r})),oe=b((e=>{"use strict";var t=e&&e.__spreadArray||function(e,t){for(var n=0,r=t.length,o=e.length;n<r;n++,o++)e[o]=t[n];return e};Object.defineProperty(e,"__esModule",{value:!0}),e.ContextAPI=void 0;var n=re(),r=q(),o=V(),i="context",s=new n.NoopContextManager,a=function(){function e(){}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalContextManager=function(e){return r.registerGlobal(i,e,o.DiagAPI.instance())},e.prototype.active=function(){return this._getContextManager().active()},e.prototype.with=function(e,n,r){for(var o,i=[],s=3;s<arguments.length;s++)i[s-3]=arguments[s];return(o=this._getContextManager()).with.apply(o,t([e,n,r],i))},e.prototype.bind=function(e,t){return this._getContextManager().bind(e,t)},e.prototype._getContextManager=function(){return r.getGlobal(i)||s},e.prototype.disable=function(){this._getContextManager().disable(),r.unregisterGlobal(i,o.DiagAPI.instance())},e}();e.ContextAPI=a})),ie=b((e=>{"use strict";var t;Object.defineProperty(e,"__esModule",{value:!0}),e.TraceFlags=void 0,(t=e.TraceFlags||(e.TraceFlags={}))[t.NONE=0]="NONE",t[t.SAMPLED=1]="SAMPLED"})),se=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.INVALID_SPAN_CONTEXT=e.INVALID_TRACEID=e.INVALID_SPANID=void 0;var t=ie();e.INVALID_SPANID="0000000000000000",e.INVALID_TRACEID="00000000000000000000000000000000",e.INVALID_SPAN_CONTEXT={traceId:e.INVALID_TRACEID,spanId:e.INVALID_SPANID,traceFlags:t.TraceFlags.NONE}})),ae=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.NonRecordingSpan=void 0;var t=se(),n=function(){function e(e){void 0===e&&(e=t.INVALID_SPAN_CONTEXT),this._spanContext=e}return e.prototype.spanContext=function(){return this._spanContext},e.prototype.setAttribute=function(e,t){return this},e.prototype.setAttributes=function(e){return this},e.prototype.addEvent=function(e,t){return this},e.prototype.setStatus=function(e){return this},e.prototype.updateName=function(e){return this},e.prototype.end=function(e){},e.prototype.isRecording=function(){return!1},e.prototype.recordException=function(e,t){},e}();e.NonRecordingSpan=n})),ce=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getSpanContext=e.setSpanContext=e.deleteSpan=e.setSpan=e.getSpan=void 0;var t=ne(),n=ae(),r=t.createContextKey("OpenTelemetry Context Key SPAN");function o(e){return e.getValue(r)||void 0}function i(e,t){return e.setValue(r,t)}e.getSpan=o,e.setSpan=i,e.deleteSpan=function(e){return e.deleteValue(r)},e.setSpanContext=function(e,t){return i(e,new n.NonRecordingSpan(t))},e.getSpanContext=function(e){var t;return null===(t=o(e))||void 0===t?void 0:t.spanContext()}})),ue=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.wrapSpanContext=e.isSpanContextValid=e.isValidSpanId=e.isValidTraceId=void 0;var t=se(),n=ae(),r=/^([0-9a-f]{32})$/i,o=/^[0-9a-f]{16}$/i;function i(e){return r.test(e)&&e!==t.INVALID_TRACEID}function s(e){return o.test(e)&&e!==t.INVALID_SPANID}e.isValidTraceId=i,e.isValidSpanId=s,e.isSpanContextValid=function(e){return i(e.traceId)&&s(e.spanId)},e.wrapSpanContext=function(e){return new n.NonRecordingSpan(e)}})),le=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.NoopTracer=void 0;var t=oe(),n=ce(),r=ae(),o=ue(),i=t.ContextAPI.getInstance(),s=function(){function e(){}return e.prototype.startSpan=function(e,t,i){if(Boolean(null==t?void 0:t.root))return new r.NonRecordingSpan;var s=i&&n.getSpanContext(i);return function(e){return"object"==typeof e&&"string"==typeof e.spanId&&"string"==typeof e.traceId&&"number"==typeof e.traceFlags}(s)&&o.isSpanContextValid(s)?new r.NonRecordingSpan(s):new r.NonRecordingSpan},e.prototype.startActiveSpan=function(e,t,r,o){var s,a,c;if(!(arguments.length<2)){2===arguments.length?c=t:3===arguments.length?(s=t,c=r):(s=t,a=r,c=o);var u=a??i.active(),l=this.startSpan(e,s,u),p=n.setSpan(u,l);return i.with(p,c,void 0,l)}},e}();e.NoopTracer=s})),pe=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ProxyTracer=void 0;var t=new(le().NoopTracer),n=function(){function e(e,t,n){this._provider=e,this.name=t,this.version=n}return e.prototype.startSpan=function(e,t,n){return this._getTracer().startSpan(e,t,n)},e.prototype.startActiveSpan=function(e,t,n,r){var o=this._getTracer();return Reflect.apply(o.startActiveSpan,o,arguments)},e.prototype._getTracer=function(){if(this._delegate)return this._delegate;var e=this._provider.getDelegateTracer(this.name,this.version);return e?(this._delegate=e,this._delegate):t},e}();e.ProxyTracer=n})),de=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.NoopTracerProvider=void 0;var t=le(),n=function(){function e(){}return e.prototype.getTracer=function(e,n){return new t.NoopTracer},e}();e.NoopTracerProvider=n})),he=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ProxyTracerProvider=void 0;var t=pe(),n=new(de().NoopTracerProvider),r=function(){function e(){}return e.prototype.getTracer=function(e,n){var r;return null!==(r=this.getDelegateTracer(e,n))&&void 0!==r?r:new t.ProxyTracer(this,e,n)},e.prototype.getDelegate=function(){var e;return null!==(e=this._delegate)&&void 0!==e?e:n},e.prototype.setDelegate=function(e){this._delegate=e},e.prototype.getDelegateTracer=function(e,t){var n;return null===(n=this._delegate)||void 0===n?void 0:n.getTracer(e,t)},e}();e.ProxyTracerProvider=r})),fe=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),me=b((e=>{"use strict";var t;Object.defineProperty(e,"__esModule",{value:!0}),e.SamplingDecision=void 0,(t=e.SamplingDecision||(e.SamplingDecision={}))[t.NOT_RECORD=0]="NOT_RECORD",t[t.RECORD=1]="RECORD",t[t.RECORD_AND_SAMPLED=2]="RECORD_AND_SAMPLED"})),ve=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),ge=b((e=>{"use strict";var t;Object.defineProperty(e,"__esModule",{value:!0}),e.SpanKind=void 0,(t=e.SpanKind||(e.SpanKind={}))[t.INTERNAL=0]="INTERNAL",t[t.SERVER=1]="SERVER",t[t.CLIENT=2]="CLIENT",t[t.PRODUCER=3]="PRODUCER",t[t.CONSUMER=4]="CONSUMER"})),ye=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),_e=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),be=b((e=>{"use strict";var t;Object.defineProperty(e,"__esModule",{value:!0}),e.SpanStatusCode=void 0,(t=e.SpanStatusCode||(e.SpanStatusCode={}))[t.UNSET=0]="UNSET",t[t.OK=1]="OK",t[t.ERROR=2]="ERROR"})),Ee=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Te=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Se=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Ce=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),xe=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.TraceAPI=void 0;var t=q(),n=he(),r=ue(),o=ce(),i=V(),s="trace",a=function(){function e(){this._proxyTracerProvider=new n.ProxyTracerProvider,this.wrapSpanContext=r.wrapSpanContext,this.isSpanContextValid=r.isSpanContextValid,this.deleteSpan=o.deleteSpan,this.getSpan=o.getSpan,this.getSpanContext=o.getSpanContext,this.setSpan=o.setSpan,this.setSpanContext=o.setSpanContext}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalTracerProvider=function(e){var n=t.registerGlobal(s,this._proxyTracerProvider,i.DiagAPI.instance());return n&&this._proxyTracerProvider.setDelegate(e),n},e.prototype.getTracerProvider=function(){return t.getGlobal(s)||this._proxyTracerProvider},e.prototype.getTracer=function(e,t){return this.getTracerProvider().getTracer(e,t)},e.prototype.disable=function(){t.unregisterGlobal(s,i.DiagAPI.instance()),this._proxyTracerProvider=new n.ProxyTracerProvider},e}();e.TraceAPI=a})),we=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.NoopTextMapPropagator=void 0;var t=function(){function e(){}return e.prototype.inject=function(e,t){},e.prototype.extract=function(e,t){return e},e.prototype.fields=function(){return[]},e}();e.NoopTextMapPropagator=t})),Ae=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.deleteBaggage=e.setBaggage=e.getBaggage=void 0;var t=ne().createContextKey("OpenTelemetry Baggage Key");e.getBaggage=function(e){return e.getValue(t)||void 0},e.setBaggage=function(e,n){return e.setValue(t,n)},e.deleteBaggage=function(e){return e.deleteValue(t)}})),Ie=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.PropagationAPI=void 0;var t=q(),n=we(),r=Z(),o=Ae(),i=W(),s=V(),a="propagation",c=new n.NoopTextMapPropagator,u=function(){function e(){this.createBaggage=i.createBaggage,this.getBaggage=o.getBaggage,this.setBaggage=o.setBaggage,this.deleteBaggage=o.deleteBaggage}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalPropagator=function(e){return t.registerGlobal(a,e,s.DiagAPI.instance())},e.prototype.inject=function(e,t,n){return void 0===n&&(n=r.defaultTextMapSetter),this._getGlobalPropagator().inject(e,t,n)},e.prototype.extract=function(e,t,n){return void 0===n&&(n=r.defaultTextMapGetter),this._getGlobalPropagator().extract(e,t,n)},e.prototype.fields=function(){return this._getGlobalPropagator().fields()},e.prototype.disable=function(){t.unregisterGlobal(a,s.DiagAPI.instance())},e.prototype._getGlobalPropagator=function(){return t.getGlobal(a)||c},e}();e.PropagationAPI=u})),Re=b((e=>{"use strict";var t=e&&e.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=e&&e.__exportStar||function(e,n){for(var r in e)"default"!==r&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),e.diag=e.propagation=e.trace=e.context=e.INVALID_SPAN_CONTEXT=e.INVALID_TRACEID=e.INVALID_SPANID=e.isValidSpanId=e.isValidTraceId=e.isSpanContextValid=e.baggageEntryMetadataFromString=void 0,n(M(),e);var r=W();Object.defineProperty(e,"baggageEntryMetadataFromString",{enumerable:!0,get:function(){return r.baggageEntryMetadataFromString}}),n(Q(),e),n(Y(),e),n(J(),e),n(Z(),e),n(ee(),e),n(te(),e),n(pe(),e),n(he(),e),n(fe(),e),n(me(),e),n(ve(),e),n(ge(),e),n(ye(),e),n(_e(),e),n(be(),e),n(ie(),e),n(Ee(),e),n(Te(),e),n(Se(),e);var o=ue();Object.defineProperty(e,"isSpanContextValid",{enumerable:!0,get:function(){return o.isSpanContextValid}}),Object.defineProperty(e,"isValidTraceId",{enumerable:!0,get:function(){return o.isValidTraceId}}),Object.defineProperty(e,"isValidSpanId",{enumerable:!0,get:function(){return o.isValidSpanId}});var i=se();Object.defineProperty(e,"INVALID_SPANID",{enumerable:!0,get:function(){return i.INVALID_SPANID}}),Object.defineProperty(e,"INVALID_TRACEID",{enumerable:!0,get:function(){return i.INVALID_TRACEID}}),Object.defineProperty(e,"INVALID_SPAN_CONTEXT",{enumerable:!0,get:function(){return i.INVALID_SPAN_CONTEXT}}),n(ne(),e),n(Ce(),e);var s=oe();e.context=s.ContextAPI.getInstance();var a=xe();e.trace=a.TraceAPI.getInstance();var c=Ie();e.propagation=c.PropagationAPI.getInstance();var u=V();e.diag=u.DiagAPI.instance(),e.default={trace:e.trace,context:e.context,propagation:e.propagation,diag:e.diag}})),Pe=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.isTracingSuppressed=e.unsuppressTracing=e.suppressTracing=void 0;var t=Re().createContextKey("OpenTelemetry SDK Context Key SUPPRESS_TRACING");e.suppressTracing=function(e){return e.setValue(t,!0)},e.unsuppressTracing=function(e){return e.deleteValue(t)},e.isTracingSuppressed=function(e){return!0===e.getValue(t)}})),Oe=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.BAGGAGE_MAX_TOTAL_LENGTH=e.BAGGAGE_MAX_PER_NAME_VALUE_PAIRS=e.BAGGAGE_MAX_NAME_VALUE_PAIRS=e.BAGGAGE_HEADER=e.BAGGAGE_ITEMS_SEPARATOR=e.BAGGAGE_PROPERTIES_SEPARATOR=e.BAGGAGE_KEY_PAIR_SEPARATOR=void 0,e.BAGGAGE_KEY_PAIR_SEPARATOR="=",e.BAGGAGE_PROPERTIES_SEPARATOR=";",e.BAGGAGE_ITEMS_SEPARATOR=",",e.BAGGAGE_HEADER="baggage",e.BAGGAGE_MAX_NAME_VALUE_PAIRS=180,e.BAGGAGE_MAX_PER_NAME_VALUE_PAIRS=4096,e.BAGGAGE_MAX_TOTAL_LENGTH=8192})),Ne=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.parseKeyPairsIntoRecord=e.parsePairKeyValue=e.getKeyPairs=e.serializeKeyPairs=void 0;var t=Re(),n=Oe();e.serializeKeyPairs=e=>e.reduce(((e,t)=>{let r=`${e}${""!==e?n.BAGGAGE_ITEMS_SEPARATOR:""}${t}`;return r.length>n.BAGGAGE_MAX_TOTAL_LENGTH?e:r}),""),e.getKeyPairs=e=>e.getAllEntries().map((([e,t])=>`${encodeURIComponent(e)}=${encodeURIComponent(t.value)}`)),e.parsePairKeyValue=e=>{let r=e.split(n.BAGGAGE_PROPERTIES_SEPARATOR);if(r.length<=0)return;let o=r.shift();if(!o)return;let i=o.split(n.BAGGAGE_KEY_PAIR_SEPARATOR);if(2!==i.length)return;let s,a=decodeURIComponent(i[0].trim()),c=decodeURIComponent(i[1].trim());return r.length>0&&(s=t.baggageEntryMetadataFromString(r.join(n.BAGGAGE_PROPERTIES_SEPARATOR))),{key:a,value:c,metadata:s}},e.parseKeyPairsIntoRecord=t=>"string"!=typeof t||0===t.length?{}:t.split(n.BAGGAGE_ITEMS_SEPARATOR).map((t=>e.parsePairKeyValue(t))).filter((e=>void 0!==e&&e.value.length>0)).reduce(((e,t)=>(e[t.key]=t.value,e)),{})})),ke=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.HttpBaggagePropagator=void 0;var t=Re(),n=Pe(),r=Oe(),o=Ne();e.HttpBaggagePropagator=class{inject(e,i,s){let a=t.propagation.getBaggage(e);if(!a||n.isTracingSuppressed(e))return;let c=o.getKeyPairs(a).filter((e=>e.length<=r.BAGGAGE_MAX_PER_NAME_VALUE_PAIRS)).slice(0,r.BAGGAGE_MAX_NAME_VALUE_PAIRS),u=o.serializeKeyPairs(c);u.length>0&&s.set(i,r.BAGGAGE_HEADER,u)}extract(e,n,i){let s=i.get(n,r.BAGGAGE_HEADER);if(!s)return e;let a={};return 0===s.length||(s.split(r.BAGGAGE_ITEMS_SEPARATOR).forEach((e=>{let t=o.parsePairKeyValue(e);if(t){let e={value:t.value};t.metadata&&(e.metadata=t.metadata),a[t.key]=e}})),0===Object.entries(a).length)?e:t.propagation.setBaggage(e,t.propagation.createBaggage(a))}fields(){return[r.BAGGAGE_HEADER]}}})),De=b((e=>{"use strict";function t(e){return null==e||(Array.isArray(e)?function(e){let t;for(let r of e)if(null!=r){if(!t){if(n(r)){t=typeof r;continue}return!1}if(typeof r!==t)return!1}return!0}(e):n(e))}function n(e){switch(typeof e){case"number":case"boolean":case"string":return!0}return!1}Object.defineProperty(e,"__esModule",{value:!0}),e.isAttributeValue=e.sanitizeAttributes=void 0,e.sanitizeAttributes=function(e){let n={};if(null==e||"object"!=typeof e)return n;for(let[r,o]of Object.entries(e))t(o)&&(Array.isArray(o)?n[r]=o.slice():n[r]=o);return n},e.isAttributeValue=t})),Me=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.loggingErrorHandler=void 0;var t=Re();e.loggingErrorHandler=function(){return e=>{t.diag.error(function(e){return"string"==typeof e?e:JSON.stringify(function(e){let t={},n=e;for(;null!==n;)Object.getOwnPropertyNames(n).forEach((e=>{if(t[e])return;let r=n[e];r&&(t[e]=String(r))})),n=Object.getPrototypeOf(n);return t}(e))}(e))}}})),Le=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.globalErrorHandler=e.setGlobalErrorHandler=void 0;var t=Me().loggingErrorHandler();e.setGlobalErrorHandler=function(e){t=e},e.globalErrorHandler=e=>{try{t(e)}catch{}}})),je=b((e=>{"use strict";var t;Object.defineProperty(e,"__esModule",{value:!0}),e.TracesSamplerValues=void 0,(t=e.TracesSamplerValues||(e.TracesSamplerValues={})).AlwaysOff="always_off",t.AlwaysOn="always_on",t.ParentBasedAlwaysOff="parentbased_always_off",t.ParentBasedAlwaysOn="parentbased_always_on",t.ParentBasedTraceIdRatio="parentbased_traceidratio",t.TraceIdRatio="traceidratio"})),Ue=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.parseEnvironment=e.DEFAULT_ENVIRONMENT=void 0;var t=Re(),n=je(),r=["OTEL_BSP_EXPORT_TIMEOUT","OTEL_BSP_MAX_EXPORT_BATCH_SIZE","OTEL_BSP_MAX_QUEUE_SIZE","OTEL_BSP_SCHEDULE_DELAY","OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT","OTEL_SPAN_EVENT_COUNT_LIMIT","OTEL_SPAN_LINK_COUNT_LIMIT"];function o(e){return r.indexOf(e)>-1}var i=["OTEL_NO_PATCH_MODULES","OTEL_PROPAGATORS"];function s(e){return i.indexOf(e)>-1}function a(e,t,n,r=-1/0,o=1/0){if(typeof n[e]<"u"){let i=Number(n[e]);isNaN(i)||(t[e]=i<r?r:i>o?o:i)}}function c(e,t,n,r=","){let o=n[e];"string"==typeof o&&(t[e]=o.split(r).map((e=>e.trim())))}e.DEFAULT_ENVIRONMENT={CONTAINER_NAME:"",ECS_CONTAINER_METADATA_URI_V4:"",ECS_CONTAINER_METADATA_URI:"",HOSTNAME:"",KUBERNETES_SERVICE_HOST:"",NAMESPACE:"",OTEL_BSP_EXPORT_TIMEOUT:3e4,OTEL_BSP_MAX_EXPORT_BATCH_SIZE:512,OTEL_BSP_MAX_QUEUE_SIZE:2048,OTEL_BSP_SCHEDULE_DELAY:5e3,OTEL_EXPORTER_JAEGER_AGENT_HOST:"",OTEL_EXPORTER_JAEGER_ENDPOINT:"",OTEL_EXPORTER_JAEGER_PASSWORD:"",OTEL_EXPORTER_JAEGER_USER:"",OTEL_EXPORTER_OTLP_ENDPOINT:"",OTEL_EXPORTER_OTLP_TRACES_ENDPOINT:"",OTEL_EXPORTER_OTLP_METRICS_ENDPOINT:"",OTEL_EXPORTER_OTLP_HEADERS:"",OTEL_EXPORTER_OTLP_TRACES_HEADERS:"",OTEL_EXPORTER_OTLP_METRICS_HEADERS:"",OTEL_EXPORTER_ZIPKIN_ENDPOINT:"http://localhost:9411/api/v2/spans",OTEL_LOG_LEVEL:t.DiagLogLevel.INFO,OTEL_NO_PATCH_MODULES:[],OTEL_PROPAGATORS:["tracecontext","baggage"],OTEL_RESOURCE_ATTRIBUTES:"",OTEL_SERVICE_NAME:"",OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT:128,OTEL_SPAN_EVENT_COUNT_LIMIT:128,OTEL_SPAN_LINK_COUNT_LIMIT:128,OTEL_TRACES_EXPORTER:"none",OTEL_TRACES_SAMPLER:n.TracesSamplerValues.ParentBasedAlwaysOn,OTEL_TRACES_SAMPLER_ARG:""};var u={ALL:t.DiagLogLevel.ALL,VERBOSE:t.DiagLogLevel.VERBOSE,DEBUG:t.DiagLogLevel.DEBUG,INFO:t.DiagLogLevel.INFO,WARN:t.DiagLogLevel.WARN,ERROR:t.DiagLogLevel.ERROR,NONE:t.DiagLogLevel.NONE};function l(e,t,n){let r=n[e];if("string"==typeof r){let n=u[r.toUpperCase()];null!=n&&(t[e]=n)}}e.parseEnvironment=function(t){let n={};for(let r in e.DEFAULT_ENVIRONMENT){let e=r;if("OTEL_LOG_LEVEL"===e)l(e,n,t);else if(o(e))a(e,n,t);else if(s(e))c(e,n,t);else{let r=t[e];typeof r<"u"&&null!==r&&(n[e]=String(r))}}return n}})),Fe=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getEnv=void 0;var t=n(857),r=Ue();e.getEnv=function(){let e=r.parseEnvironment(process.env);return Object.assign({HOSTNAME:t.hostname()},r.DEFAULT_ENVIRONMENT,e)}})),ze=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.hexToBase64=void 0,e.hexToBase64=function(e){let t=e.length,n="";for(let r=0;r<t;r+=2){let t=e.substring(r,r+2),o=parseInt(t,16);n+=String.fromCharCode(o)}return Buffer.from(n,"ascii").toString("base64")}})),qe=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.RandomIdGenerator=void 0,e.RandomIdGenerator=class{constructor(){this.generateTraceId=n(16),this.generateSpanId=n(8)}};var t=Buffer.allocUnsafe(16);function n(e){return function(){for(let n=0;n<e/4;n++)t.writeUInt32BE(Math.random()*2**32>>>0,4*n);for(let n=0;n<e&&!(t[n]>0);n++)n===e-1&&(t[e-1]=1);return t.toString("hex",0,e)}}})),Be=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.otperformance=void 0;var t=n(2987);e.otperformance=t.performance})),He=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.VERSION=void 0,e.VERSION="0.23.0"})),Ge=b((e=>{"use strict";var t;Object.defineProperty(e,"__esModule",{value:!0}),e.RpcGrpcStatusCodeValues=e.MessagingOperationValues=e.MessagingDestinationKindValues=e.HttpFlavorValues=e.NetTransportValues=e.FaasInvokedProviderValues=e.FaasDocumentOperationValues=e.FaasTriggerValues=e.DbCassandraConsistencyLevelValues=e.DbSystemValues=e.SemanticAttributes=void 0,e.SemanticAttributes={DB_SYSTEM:"db.system",DB_CONNECTION_STRING:"db.connection_string",DB_USER:"db.user",DB_JDBC_DRIVER_CLASSNAME:"db.jdbc.driver_classname",DB_NAME:"db.name",DB_STATEMENT:"db.statement",DB_OPERATION:"db.operation",DB_MSSQL_INSTANCE_NAME:"db.mssql.instance_name",DB_CASSANDRA_KEYSPACE:"db.cassandra.keyspace",DB_CASSANDRA_PAGE_SIZE:"db.cassandra.page_size",DB_CASSANDRA_CONSISTENCY_LEVEL:"db.cassandra.consistency_level",DB_CASSANDRA_TABLE:"db.cassandra.table",DB_CASSANDRA_IDEMPOTENCE:"db.cassandra.idempotence",DB_CASSANDRA_SPECULATIVE_EXECUTION_COUNT:"db.cassandra.speculative_execution_count",DB_CASSANDRA_COORDINATOR_ID:"db.cassandra.coordinator.id",DB_CASSANDRA_COORDINATOR_DC:"db.cassandra.coordinator.dc",DB_HBASE_NAMESPACE:"db.hbase.namespace",DB_REDIS_DATABASE_INDEX:"db.redis.database_index",DB_MONGODB_COLLECTION:"db.mongodb.collection",DB_SQL_TABLE:"db.sql.table",EXCEPTION_TYPE:"exception.type",EXCEPTION_MESSAGE:"exception.message",EXCEPTION_STACKTRACE:"exception.stacktrace",EXCEPTION_ESCAPED:"exception.escaped",FAAS_TRIGGER:"faas.trigger",FAAS_EXECUTION:"faas.execution",FAAS_DOCUMENT_COLLECTION:"faas.document.collection",FAAS_DOCUMENT_OPERATION:"faas.document.operation",FAAS_DOCUMENT_TIME:"faas.document.time",FAAS_DOCUMENT_NAME:"faas.document.name",FAAS_TIME:"faas.time",FAAS_CRON:"faas.cron",FAAS_COLDSTART:"faas.coldstart",FAAS_INVOKED_NAME:"faas.invoked_name",FAAS_INVOKED_PROVIDER:"faas.invoked_provider",FAAS_INVOKED_REGION:"faas.invoked_region",NET_TRANSPORT:"net.transport",NET_PEER_IP:"net.peer.ip",NET_PEER_PORT:"net.peer.port",NET_PEER_NAME:"net.peer.name",NET_HOST_IP:"net.host.ip",NET_HOST_PORT:"net.host.port",NET_HOST_NAME:"net.host.name",PEER_SERVICE:"peer.service",ENDUSER_ID:"enduser.id",ENDUSER_ROLE:"enduser.role",ENDUSER_SCOPE:"enduser.scope",THREAD_ID:"thread.id",THREAD_NAME:"thread.name",CODE_FUNCTION:"code.function",CODE_NAMESPACE:"code.namespace",CODE_FILEPATH:"code.filepath",CODE_LINENO:"code.lineno",HTTP_METHOD:"http.method",HTTP_URL:"http.url",HTTP_TARGET:"http.target",HTTP_HOST:"http.host",HTTP_SCHEME:"http.scheme",HTTP_STATUS_CODE:"http.status_code",HTTP_FLAVOR:"http.flavor",HTTP_USER_AGENT:"http.user_agent",HTTP_REQUEST_CONTENT_LENGTH:"http.request_content_length",HTTP_REQUEST_CONTENT_LENGTH_UNCOMPRESSED:"http.request_content_length_uncompressed",HTTP_RESPONSE_CONTENT_LENGTH:"http.response_content_length",HTTP_RESPONSE_CONTENT_LENGTH_UNCOMPRESSED:"http.response_content_length_uncompressed",HTTP_SERVER_NAME:"http.server_name",HTTP_ROUTE:"http.route",HTTP_CLIENT_IP:"http.client_ip",AWS_DYNAMODB_TABLE_NAMES:"aws.dynamodb.table_names",AWS_DYNAMODB_CONSUMED_CAPACITY:"aws.dynamodb.consumed_capacity",AWS_DYNAMODB_ITEM_COLLECTION_METRICS:"aws.dynamodb.item_collection_metrics",AWS_DYNAMODB_PROVISIONED_READ_CAPACITY:"aws.dynamodb.provisioned_read_capacity",AWS_DYNAMODB_PROVISIONED_WRITE_CAPACITY:"aws.dynamodb.provisioned_write_capacity",AWS_DYNAMODB_CONSISTENT_READ:"aws.dynamodb.consistent_read",AWS_DYNAMODB_PROJECTION:"aws.dynamodb.projection",AWS_DYNAMODB_LIMIT:"aws.dynamodb.limit",AWS_DYNAMODB_ATTRIBUTES_TO_GET:"aws.dynamodb.attributes_to_get",AWS_DYNAMODB_INDEX_NAME:"aws.dynamodb.index_name",AWS_DYNAMODB_SELECT:"aws.dynamodb.select",AWS_DYNAMODB_GLOBAL_SECONDARY_INDEXES:"aws.dynamodb.global_secondary_indexes",AWS_DYNAMODB_LOCAL_SECONDARY_INDEXES:"aws.dynamodb.local_secondary_indexes",AWS_DYNAMODB_EXCLUSIVE_START_TABLE:"aws.dynamodb.exclusive_start_table",AWS_DYNAMODB_TABLE_COUNT:"aws.dynamodb.table_count",AWS_DYNAMODB_SCAN_FORWARD:"aws.dynamodb.scan_forward",AWS_DYNAMODB_SEGMENT:"aws.dynamodb.segment",AWS_DYNAMODB_TOTAL_SEGMENTS:"aws.dynamodb.total_segments",AWS_DYNAMODB_COUNT:"aws.dynamodb.count",AWS_DYNAMODB_SCANNED_COUNT:"aws.dynamodb.scanned_count",AWS_DYNAMODB_ATTRIBUTE_DEFINITIONS:"aws.dynamodb.attribute_definitions",AWS_DYNAMODB_GLOBAL_SECONDARY_INDEX_UPDATES:"aws.dynamodb.global_secondary_index_updates",MESSAGING_SYSTEM:"messaging.system",MESSAGING_DESTINATION:"messaging.destination",MESSAGING_DESTINATION_KIND:"messaging.destination_kind",MESSAGING_TEMP_DESTINATION:"messaging.temp_destination",MESSAGING_PROTOCOL:"messaging.protocol",MESSAGING_PROTOCOL_VERSION:"messaging.protocol_version",MESSAGING_URL:"messaging.url",MESSAGING_MESSAGE_ID:"messaging.message_id",MESSAGING_CONVERSATION_ID:"messaging.conversation_id",MESSAGING_MESSAGE_PAYLOAD_SIZE_BYTES:"messaging.message_payload_size_bytes",MESSAGING_MESSAGE_PAYLOAD_COMPRESSED_SIZE_BYTES:"messaging.message_payload_compressed_size_bytes",MESSAGING_OPERATION:"messaging.operation",MESSAGING_RABBITMQ_ROUTING_KEY:"messaging.rabbitmq.routing_key",MESSAGING_KAFKA_MESSAGE_KEY:"messaging.kafka.message_key",MESSAGING_KAFKA_CONSUMER_GROUP:"messaging.kafka.consumer_group",MESSAGING_KAFKA_CLIENT_ID:"messaging.kafka.client_id",MESSAGING_KAFKA_PARTITION:"messaging.kafka.partition",MESSAGING_KAFKA_TOMBSTONE:"messaging.kafka.tombstone",RPC_SYSTEM:"rpc.system",RPC_SERVICE:"rpc.service",RPC_METHOD:"rpc.method",RPC_GRPC_STATUS_CODE:"rpc.grpc.status_code",RPC_JSONRPC_VERSION:"rpc.jsonrpc.version",RPC_JSONRPC_METHOD:"rpc.jsonrpc.method",RPC_JSONRPC_REQUEST_ID:"rpc.jsonrpc.request_id",RPC_JSONRPC_ERROR_CODE:"rpc.jsonrpc.error_code",RPC_JSONRPC_ERROR_MESSAGE:"rpc.jsonrpc.error_message"},(t=e.DbSystemValues||(e.DbSystemValues={})).OTHER_SQL="other_sql",t.MSSQL="mssql",t.MYSQL="mysql",t.ORACLE="oracle",t.DB2="db2",t.POSTGRESQL="postgresql",t.REDSHIFT="redshift",t.HIVE="hive",t.CLOUDSCAPE="cloudscape",t.HSQLDB="hsqldb",t.PROGRESS="progress",t.MAXDB="maxdb",t.HANADB="hanadb",t.INGRES="ingres",t.FIRSTSQL="firstsql",t.EDB="edb",t.CACHE="cache",t.ADABAS="adabas",t.FIREBIRD="firebird",t.DERBY="derby",t.FILEMAKER="filemaker",t.INFORMIX="informix",t.INSTANTDB="instantdb",t.INTERBASE="interbase",t.MARIADB="mariadb",t.NETEZZA="netezza",t.PERVASIVE="pervasive",t.POINTBASE="pointbase",t.SQLITE="sqlite",t.SYBASE="sybase",t.TERADATA="teradata",t.VERTICA="vertica",t.H2="h2",t.COLDFUSION="coldfusion",t.CASSANDRA="cassandra",t.HBASE="hbase",t.MONGODB="mongodb",t.REDIS="redis",t.COUCHBASE="couchbase",t.COUCHDB="couchdb",t.COSMOSDB="cosmosdb",t.DYNAMODB="dynamodb",t.NEO4J="neo4j",t.GEODE="geode",t.ELASTICSEARCH="elasticsearch",t.MEMCACHED="memcached",t.COCKROACHDB="cockroachdb",function(e){e.ALL="all",e.EACH_QUORUM="each_quorum",e.QUORUM="quorum",e.LOCAL_QUORUM="local_quorum",e.ONE="one",e.TWO="two",e.THREE="three",e.LOCAL_ONE="local_one",e.ANY="any",e.SERIAL="serial",e.LOCAL_SERIAL="local_serial"}(e.DbCassandraConsistencyLevelValues||(e.DbCassandraConsistencyLevelValues={})),function(e){e.DATASOURCE="datasource",e.HTTP="http",e.PUBSUB="pubsub",e.TIMER="timer",e.OTHER="other"}(e.FaasTriggerValues||(e.FaasTriggerValues={})),function(e){e.INSERT="insert",e.EDIT="edit",e.DELETE="delete"}(e.FaasDocumentOperationValues||(e.FaasDocumentOperationValues={})),function(e){e.AWS="aws",e.AZURE="azure",e.GCP="gcp"}(e.FaasInvokedProviderValues||(e.FaasInvokedProviderValues={})),function(e){e.IP_TCP="ip_tcp",e.IP_UDP="ip_udp",e.IP="ip",e.UNIX="unix",e.PIPE="pipe",e.INPROC="inproc",e.OTHER="other"}(e.NetTransportValues||(e.NetTransportValues={})),function(e){e.HTTP_1_0="1.0",e.HTTP_1_1="1.1",e.HTTP_2_0="2.0",e.SPDY="SPDY",e.QUIC="QUIC"}(e.HttpFlavorValues||(e.HttpFlavorValues={})),function(e){e.QUEUE="queue",e.TOPIC="topic"}(e.MessagingDestinationKindValues||(e.MessagingDestinationKindValues={})),function(e){e.RECEIVE="receive",e.PROCESS="process"}(e.MessagingOperationValues||(e.MessagingOperationValues={})),function(e){e[e.OK=0]="OK",e[e.CANCELLED=1]="CANCELLED",e[e.UNKNOWN=2]="UNKNOWN",e[e.INVALID_ARGUMENT=3]="INVALID_ARGUMENT",e[e.DEADLINE_EXCEEDED=4]="DEADLINE_EXCEEDED",e[e.NOT_FOUND=5]="NOT_FOUND",e[e.ALREADY_EXISTS=6]="ALREADY_EXISTS",e[e.PERMISSION_DENIED=7]="PERMISSION_DENIED",e[e.RESOURCE_EXHAUSTED=8]="RESOURCE_EXHAUSTED",e[e.FAILED_PRECONDITION=9]="FAILED_PRECONDITION",e[e.ABORTED=10]="ABORTED",e[e.OUT_OF_RANGE=11]="OUT_OF_RANGE",e[e.UNIMPLEMENTED=12]="UNIMPLEMENTED",e[e.INTERNAL=13]="INTERNAL",e[e.UNAVAILABLE=14]="UNAVAILABLE",e[e.DATA_LOSS=15]="DATA_LOSS",e[e.UNAUTHENTICATED=16]="UNAUTHENTICATED"}(e.RpcGrpcStatusCodeValues||(e.RpcGrpcStatusCodeValues={}))})),Ve=b((e=>{"use strict";var t=e&&e.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=e&&e.__exportStar||function(e,n){for(var r in e)"default"!==r&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(Ge(),e)})),$e=b((e=>{"use strict";var t;Object.defineProperty(e,"__esModule",{value:!0}),e.TelemetrySdkLanguageValues=e.OsTypeValues=e.HostArchValues=e.AwsEcsLaunchtypeValues=e.CloudPlatformValues=e.CloudProviderValues=e.ResourceAttributes=void 0,e.ResourceAttributes={CLOUD_PROVIDER:"cloud.provider",CLOUD_ACCOUNT_ID:"cloud.account.id",CLOUD_REGION:"cloud.region",CLOUD_AVAILABILITY_ZONE:"cloud.availability_zone",CLOUD_PLATFORM:"cloud.platform",AWS_ECS_CONTAINER_ARN:"aws.ecs.container.arn",AWS_ECS_CLUSTER_ARN:"aws.ecs.cluster.arn",AWS_ECS_LAUNCHTYPE:"aws.ecs.launchtype",AWS_ECS_TASK_ARN:"aws.ecs.task.arn",AWS_ECS_TASK_FAMILY:"aws.ecs.task.family",AWS_ECS_TASK_REVISION:"aws.ecs.task.revision",AWS_EKS_CLUSTER_ARN:"aws.eks.cluster.arn",AWS_LOG_GROUP_NAMES:"aws.log.group.names",AWS_LOG_GROUP_ARNS:"aws.log.group.arns",AWS_LOG_STREAM_NAMES:"aws.log.stream.names",AWS_LOG_STREAM_ARNS:"aws.log.stream.arns",CONTAINER_NAME:"container.name",CONTAINER_ID:"container.id",CONTAINER_RUNTIME:"container.runtime",CONTAINER_IMAGE_NAME:"container.image.name",CONTAINER_IMAGE_TAG:"container.image.tag",DEPLOYMENT_ENVIRONMENT:"deployment.environment",DEVICE_ID:"device.id",DEVICE_MODEL_IDENTIFIER:"device.model.identifier",DEVICE_MODEL_NAME:"device.model.name",FAAS_NAME:"faas.name",FAAS_ID:"faas.id",FAAS_VERSION:"faas.version",FAAS_INSTANCE:"faas.instance",FAAS_MAX_MEMORY:"faas.max_memory",HOST_ID:"host.id",HOST_NAME:"host.name",HOST_TYPE:"host.type",HOST_ARCH:"host.arch",HOST_IMAGE_NAME:"host.image.name",HOST_IMAGE_ID:"host.image.id",HOST_IMAGE_VERSION:"host.image.version",K8S_CLUSTER_NAME:"k8s.cluster.name",K8S_NODE_NAME:"k8s.node.name",K8S_NODE_UID:"k8s.node.uid",K8S_NAMESPACE_NAME:"k8s.namespace.name",K8S_POD_UID:"k8s.pod.uid",K8S_POD_NAME:"k8s.pod.name",K8S_CONTAINER_NAME:"k8s.container.name",K8S_REPLICASET_UID:"k8s.replicaset.uid",K8S_REPLICASET_NAME:"k8s.replicaset.name",K8S_DEPLOYMENT_UID:"k8s.deployment.uid",K8S_DEPLOYMENT_NAME:"k8s.deployment.name",K8S_STATEFULSET_UID:"k8s.statefulset.uid",K8S_STATEFULSET_NAME:"k8s.statefulset.name",K8S_DAEMONSET_UID:"k8s.daemonset.uid",K8S_DAEMONSET_NAME:"k8s.daemonset.name",K8S_JOB_UID:"k8s.job.uid",K8S_JOB_NAME:"k8s.job.name",K8S_CRONJOB_UID:"k8s.cronjob.uid",K8S_CRONJOB_NAME:"k8s.cronjob.name",OS_TYPE:"os.type",OS_DESCRIPTION:"os.description",OS_NAME:"os.name",OS_VERSION:"os.version",PROCESS_PID:"process.pid",PROCESS_EXECUTABLE_NAME:"process.executable.name",PROCESS_EXECUTABLE_PATH:"process.executable.path",PROCESS_COMMAND:"process.command",PROCESS_COMMAND_LINE:"process.command_line",PROCESS_COMMAND_ARGS:"process.command_args",PROCESS_OWNER:"process.owner",PROCESS_RUNTIME_NAME:"process.runtime.name",PROCESS_RUNTIME_VERSION:"process.runtime.version",PROCESS_RUNTIME_DESCRIPTION:"process.runtime.description",SERVICE_NAME:"service.name",SERVICE_NAMESPACE:"service.namespace",SERVICE_INSTANCE_ID:"service.instance.id",SERVICE_VERSION:"service.version",TELEMETRY_SDK_NAME:"telemetry.sdk.name",TELEMETRY_SDK_LANGUAGE:"telemetry.sdk.language",TELEMETRY_SDK_VERSION:"telemetry.sdk.version",TELEMETRY_AUTO_VERSION:"telemetry.auto.version",WEBENGINE_NAME:"webengine.name",WEBENGINE_VERSION:"webengine.version",WEBENGINE_DESCRIPTION:"webengine.description"},(t=e.CloudProviderValues||(e.CloudProviderValues={})).AWS="aws",t.AZURE="azure",t.GCP="gcp",function(e){e.AWS_EC2="aws_ec2",e.AWS_ECS="aws_ecs",e.AWS_EKS="aws_eks",e.AWS_LAMBDA="aws_lambda",e.AWS_ELASTIC_BEANSTALK="aws_elastic_beanstalk",e.AZURE_VM="azure_vm",e.AZURE_CONTAINER_INSTANCES="azure_container_instances",e.AZURE_AKS="azure_aks",e.AZURE_FUNCTIONS="azure_functions",e.AZURE_APP_SERVICE="azure_app_service",e.GCP_COMPUTE_ENGINE="gcp_compute_engine",e.GCP_CLOUD_RUN="gcp_cloud_run",e.GCP_KUBERNETES_ENGINE="gcp_kubernetes_engine",e.GCP_CLOUD_FUNCTIONS="gcp_cloud_functions",e.GCP_APP_ENGINE="gcp_app_engine"}(e.CloudPlatformValues||(e.CloudPlatformValues={})),function(e){e.EC2="ec2",e.FARGATE="fargate"}(e.AwsEcsLaunchtypeValues||(e.AwsEcsLaunchtypeValues={})),function(e){e.AMD64="amd64",e.ARM32="arm32",e.ARM64="arm64",e.IA64="ia64",e.PPC32="ppc32",e.PPC64="ppc64",e.X86="x86"}(e.HostArchValues||(e.HostArchValues={})),function(e){e.WINDOWS="windows",e.LINUX="linux",e.DARWIN="darwin",e.FREEBSD="freebsd",e.NETBSD="netbsd",e.OPENBSD="openbsd",e.DRAGONFLYBSD="dragonflybsd",e.HPUX="hpux",e.AIX="aix",e.SOLARIS="solaris",e.Z_OS="z_os"}(e.OsTypeValues||(e.OsTypeValues={})),function(e){e.CPP="cpp",e.DOTNET="dotnet",e.ERLANG="erlang",e.GO="go",e.JAVA="java",e.NODEJS="nodejs",e.PHP="php",e.PYTHON="python",e.RUBY="ruby",e.WEBJS="webjs"}(e.TelemetrySdkLanguageValues||(e.TelemetrySdkLanguageValues={}))})),Ke=b((e=>{"use strict";var t=e&&e.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=e&&e.__exportStar||function(e,n){for(var r in e)"default"!==r&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n($e(),e)})),We=b((e=>{"use strict";var t=e&&e.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=e&&e.__exportStar||function(e,n){for(var r in e)"default"!==r&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(Ve(),e),n(Ke(),e)})),Qe=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.SDK_INFO=void 0;var t=He(),n=We();e.SDK_INFO={[n.ResourceAttributes.TELEMETRY_SDK_NAME]:"opentelemetry",[n.ResourceAttributes.PROCESS_RUNTIME_NAME]:"node",[n.ResourceAttributes.TELEMETRY_SDK_LANGUAGE]:n.TelemetrySdkLanguageValues.NODEJS,[n.ResourceAttributes.TELEMETRY_SDK_VERSION]:t.VERSION}})),Ye=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.unrefTimer=void 0,e.unrefTimer=function(e){e.unref()}})),Xe=b((e=>{"use strict";var t=e&&e.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=e&&e.__exportStar||function(e,n){for(var r in e)"default"!==r&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(Fe(),e),n(ze(),e),n(qe(),e),n(Be(),e),n(Qe(),e),n(Ye(),e)})),Je=b((e=>{"use strict";var t=e&&e.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=e&&e.__exportStar||function(e,n){for(var r in e)"default"!==r&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(Xe(),e)})),Ze=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.isTimeInput=e.isTimeInputHrTime=e.hrTimeToMicroseconds=e.hrTimeToMilliseconds=e.hrTimeToNanoseconds=e.hrTimeToTimeStamp=e.hrTimeDuration=e.timeInputToHrTime=e.hrTime=void 0;var t=Je(),n=9,r=Math.pow(10,n);function o(e){let t=e/1e3,o=Math.trunc(t);return[o,Number((t-o).toFixed(n))*r]}function i(){let e=t.otperformance.timeOrigin;if("number"!=typeof e){let n=t.otperformance;e=n.timing&&n.timing.fetchStart}return e}function s(e){let n=o(i()),s=o("number"==typeof e?e:t.otperformance.now()),a=n[0]+s[0],c=n[1]+s[1];return c>r&&(c-=r,a+=1),[a,c]}function a(e){return Array.isArray(e)&&2===e.length&&"number"==typeof e[0]&&"number"==typeof e[1]}e.hrTime=s,e.timeInputToHrTime=function(e){if(a(e))return e;if("number"==typeof e)return e<i()?s(e):o(e);if(e instanceof Date)return o(e.getTime());throw TypeError("Invalid input type")},e.hrTimeDuration=function(e,t){let n=t[0]-e[0],o=t[1]-e[1];return o<0&&(n-=1,o+=r),[n,o]},e.hrTimeToTimeStamp=function(e){let t=n,r=`${"0".repeat(t)}${e[1]}Z`,o=r.substr(r.length-t-1);return new Date(1e3*e[0]).toISOString().replace("000Z",o)},e.hrTimeToNanoseconds=function(e){return e[0]*r+e[1]},e.hrTimeToMilliseconds=function(e){return Math.round(1e3*e[0]+e[1]/1e6)},e.hrTimeToMicroseconds=function(e){return Math.round(1e6*e[0]+e[1]/1e3)},e.isTimeInputHrTime=a,e.isTimeInput=function(e){return a(e)||"number"==typeof e||e instanceof Date}})),et=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),tt=b((e=>{"use strict";var t;Object.defineProperty(e,"__esModule",{value:!0}),e.ExportResultCode=void 0,(t=e.ExportResultCode||(e.ExportResultCode={}))[t.SUCCESS=0]="SUCCESS",t[t.FAILED=1]="FAILED"})),nt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.CompositePropagator=void 0;var t=Re();e.CompositePropagator=class{constructor(e={}){var t;this._propagators=null!==(t=e.propagators)&&void 0!==t?t:[],this._fields=Array.from(new Set(this._propagators.map((e=>"function"==typeof e.fields?e.fields():[])).reduce(((e,t)=>e.concat(t)),[])))}inject(e,n,r){for(let o of this._propagators)try{o.inject(e,n,r)}catch(e){t.diag.warn(`Failed to inject with ${o.constructor.name}. Err: ${e.message}`)}}extract(e,n,r){return this._propagators.reduce(((e,o)=>{try{return o.extract(e,n,r)}catch(e){t.diag.warn(`Failed to inject with ${o.constructor.name}. Err: ${e.message}`)}return e}),e)}fields(){return this._fields.slice()}}})),rt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.validateValue=e.validateKey=void 0;var t="[_0-9a-z-*/]",n=new RegExp(`^(?:[a-z]${t}{0,255}|[a-z0-9]${t}{0,240}@[a-z]${t}{0,13})$`),r=/^[ -~]{0,255}[!-~]$/,o=/,|=/;e.validateKey=function(e){return n.test(e)},e.validateValue=function(e){return r.test(e)&&!o.test(e)}})),ot=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.TraceState=void 0;var t=rt(),n=class{constructor(e){this._internalState=new Map,e&&this._parse(e)}set(e,t){let n=this._clone();return n._internalState.has(e)&&n._internalState.delete(e),n._internalState.set(e,t),n}unset(e){let t=this._clone();return t._internalState.delete(e),t}get(e){return this._internalState.get(e)}serialize(){return this._keys().reduce(((e,t)=>(e.push(t+"="+this.get(t)),e)),[]).join(",")}_parse(e){e.length>512||(this._internalState=e.split(",").reverse().reduce(((e,n)=>{let r=n.trim(),o=r.indexOf("=");if(-1!==o){let i=r.slice(0,o),s=r.slice(o+1,n.length);t.validateKey(i)&&t.validateValue(s)&&e.set(i,s)}return e}),new Map),this._internalState.size>32&&(this._internalState=new Map(Array.from(this._internalState.entries()).reverse().slice(0,32))))}_keys(){return Array.from(this._internalState.keys()).reverse()}_clone(){let e=new n;return e._internalState=new Map(this._internalState),e}};e.TraceState=n})),it=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.HttpTraceContextPropagator=e.parseTraceParent=e.TRACE_STATE_HEADER=e.TRACE_PARENT_HEADER=void 0;var t=Re(),n=Pe(),r=ot();e.TRACE_PARENT_HEADER="traceparent",e.TRACE_STATE_HEADER="tracestate";var o=new RegExp("^\\s?((?!ff)[\\da-f]{2})-((?![0]{32})[\\da-f]{32})-((?![0]{16})[\\da-f]{16})-([\\da-f]{2})(-.*)?\\s?$");function i(e){let t=o.exec(e);return!t||"00"===t[1]&&t[5]?null:{traceId:t[2],spanId:t[3],traceFlags:parseInt(t[4],16)}}e.parseTraceParent=i,e.HttpTraceContextPropagator=class{inject(r,o,i){let s=t.trace.getSpanContext(r);if(!s||n.isTracingSuppressed(r)||!t.isSpanContextValid(s))return;let a=`00-${s.traceId}-${s.spanId}-0${Number(s.traceFlags||t.TraceFlags.NONE).toString(16)}`;i.set(o,e.TRACE_PARENT_HEADER,a),s.traceState&&i.set(o,e.TRACE_STATE_HEADER,s.traceState.serialize())}extract(n,o,s){let a=s.get(o,e.TRACE_PARENT_HEADER);if(!a)return n;let c=Array.isArray(a)?a[0]:a;if("string"!=typeof c)return n;let u=i(c);if(!u)return n;u.isRemote=!0;let l=s.get(o,e.TRACE_STATE_HEADER);if(l){let e=Array.isArray(l)?l.join(","):l;u.traceState=new r.TraceState("string"==typeof e?e:void 0)}return t.trace.setSpanContext(n,u)}fields(){return[e.TRACE_PARENT_HEADER,e.TRACE_STATE_HEADER]}}})),st=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),at=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getRPCMetadata=e.deleteRPCMetadata=e.setRPCMetadata=e.RPCType=void 0;var t=Re().createContextKey("OpenTelemetry SDK Context Key RPC_METADATA");(e.RPCType||(e.RPCType={})).HTTP="http",e.setRPCMetadata=function(e,n){return e.setValue(t,n)},e.deleteRPCMetadata=function(e){return e.deleteValue(t)},e.getRPCMetadata=function(e){return e.getValue(t)}})),ct=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.AlwaysOffSampler=void 0;var t=Re();e.AlwaysOffSampler=class{shouldSample(){return{decision:t.SamplingDecision.NOT_RECORD}}toString(){return"AlwaysOffSampler"}}})),ut=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.AlwaysOnSampler=void 0;var t=Re();e.AlwaysOnSampler=class{shouldSample(){return{decision:t.SamplingDecision.RECORD_AND_SAMPLED}}toString(){return"AlwaysOnSampler"}}})),lt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ParentBasedSampler=void 0;var t=Re(),n=Le(),r=ct(),o=ut();e.ParentBasedSampler=class{constructor(e){var t,i,s,a;this._root=e.root,this._root||(n.globalErrorHandler(new Error("ParentBasedSampler must have a root sampler configured")),this._root=new o.AlwaysOnSampler),this._remoteParentSampled=null!==(t=e.remoteParentSampled)&&void 0!==t?t:new o.AlwaysOnSampler,this._remoteParentNotSampled=null!==(i=e.remoteParentNotSampled)&&void 0!==i?i:new r.AlwaysOffSampler,this._localParentSampled=null!==(s=e.localParentSampled)&&void 0!==s?s:new o.AlwaysOnSampler,this._localParentNotSampled=null!==(a=e.localParentNotSampled)&&void 0!==a?a:new r.AlwaysOffSampler}shouldSample(e,n,r,o,i,s){let a=t.trace.getSpanContext(e);return a&&t.isSpanContextValid(a)?a.isRemote?a.traceFlags&t.TraceFlags.SAMPLED?this._remoteParentSampled.shouldSample(e,n,r,o,i,s):this._remoteParentNotSampled.shouldSample(e,n,r,o,i,s):a.traceFlags&t.TraceFlags.SAMPLED?this._localParentSampled.shouldSample(e,n,r,o,i,s):this._localParentNotSampled.shouldSample(e,n,r,o,i,s):this._root.shouldSample(e,n,r,o,i,s)}toString(){return`ParentBased{root=${this._root.toString()}, remoteParentSampled=${this._remoteParentSampled.toString()}, remoteParentNotSampled=${this._remoteParentNotSampled.toString()}, localParentSampled=${this._localParentSampled.toString()}, localParentNotSampled=${this._localParentNotSampled.toString()}}`}}})),pt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.TraceIdRatioBasedSampler=void 0;var t=Re();e.TraceIdRatioBasedSampler=class{constructor(e=0){this._ratio=e,this._ratio=this._normalize(e),this._upperBound=Math.floor(4294967295*this._ratio)}shouldSample(e,n){return{decision:t.isValidTraceId(n)&&this._accumulate(n)<this._upperBound?t.SamplingDecision.RECORD_AND_SAMPLED:t.SamplingDecision.NOT_RECORD}}toString(){return`TraceIdRatioBased{${this._ratio}}`}_normalize(e){return"number"!=typeof e||isNaN(e)?0:e>=1?1:e<=0?0:e}_accumulate(e){let t=0;for(let n=0;n<e.length/8;n++){let r=8*n;t=(t^parseInt(e.slice(r,r+8),16))>>>0}return t}}})),dt=b((e=>{"use strict";function t(e,t){return"string"==typeof t?e===t:t.test(e)}Object.defineProperty(e,"__esModule",{value:!0}),e.isUrlIgnored=e.urlMatches=void 0,e.urlMatches=t,e.isUrlIgnored=function(e,n){if(!n)return!1;for(let r of n)if(t(e,r))return!0;return!1}})),ht=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.isWrapped=void 0,e.isWrapped=function(e){return"function"==typeof e&&"function"==typeof e.__original&&"function"==typeof e.__unwrap&&!0===e.__wrapped}})),ft=b((e=>{"use strict";var t=e&&e.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=e&&e.__exportStar||function(e,n){for(var r in e)"default"!==r&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),e.baggageUtils=void 0,n(ke(),e),n(De(),e),n(Le(),e),n(Me(),e),n(Ze(),e),n(et(),e),n(tt(),e),n(He(),e),e.baggageUtils=Ne(),n(Je(),e),n(nt(),e),n(it(),e),n(st(),e),n(at(),e),n(ct(),e),n(ut(),e),n(lt(),e),n(pt(),e),n(Pe(),e),n(ot(),e),n(Ue(),e),n(je(),e),n(dt(),e),n(ht(),e),n(He(),e)})),mt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ExceptionEventName=void 0,e.ExceptionEventName="exception"})),vt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Span=void 0;var t=Re(),n=ft(),r=We(),o=mt();e.Span=class{constructor(e,r,o,i,s,a,c=[],u=n.hrTime()){this.attributes={},this.links=[],this.events=[],this.status={code:t.SpanStatusCode.UNSET},this.endTime=[0,0],this._ended=!1,this._duration=[-1,-1],this.name=o,this._spanContext=i,this.parentSpanId=a,this.kind=s,this.links=c,this.startTime=n.timeInputToHrTime(u),this.resource=e.resource,this.instrumentationLibrary=e.instrumentationLibrary,this._spanLimits=e.getSpanLimits(),this._spanProcessor=e.getActiveSpanProcessor(),this._spanProcessor.onStart(this,r)}spanContext(){return this._spanContext}setAttribute(e,r){return null==r||this._isSpanEnded()?this:0===e.length?(t.diag.warn(`Invalid attribute key: ${e}`),this):n.isAttributeValue(r)?(Object.keys(this.attributes).length>=this._spanLimits.attributeCountLimit&&!Object.prototype.hasOwnProperty.call(this.attributes,e)||(this.attributes[e]=r),this):(t.diag.warn(`Invalid attribute value set for key: ${e}`),this)}setAttributes(e){for(let[t,n]of Object.entries(e))this.setAttribute(t,n);return this}addEvent(e,r,o){return this._isSpanEnded()||(this.events.length>=this._spanLimits.eventCountLimit&&(t.diag.warn("Dropping extra events."),this.events.shift()),n.isTimeInput(r)&&(typeof o>"u"&&(o=r),r=void 0),typeof o>"u"&&(o=n.hrTime()),this.events.push({name:e,attributes:r,time:n.timeInputToHrTime(o)})),this}setStatus(e){return this._isSpanEnded()||(this.status=e),this}updateName(e){return this._isSpanEnded()||(this.name=e),this}end(e=n.hrTime()){this._isSpanEnded()?t.diag.error("You can only call end() on a span once."):(this._ended=!0,this.endTime=n.timeInputToHrTime(e),this._duration=n.hrTimeDuration(this.startTime,this.endTime),this._duration[0]<0&&t.diag.warn("Inconsistent start and end time, startTime > endTime",this.startTime,this.endTime),this._spanProcessor.onEnd(this))}isRecording(){return!1===this._ended}recordException(e,i=n.hrTime()){let s={};"string"==typeof e?s[r.SemanticAttributes.EXCEPTION_MESSAGE]=e:e&&(e.code?s[r.SemanticAttributes.EXCEPTION_TYPE]=e.code.toString():e.name&&(s[r.SemanticAttributes.EXCEPTION_TYPE]=e.name),e.message&&(s[r.SemanticAttributes.EXCEPTION_MESSAGE]=e.message),e.stack&&(s[r.SemanticAttributes.EXCEPTION_STACKTRACE]=e.stack)),s[r.SemanticAttributes.EXCEPTION_TYPE]||s[r.SemanticAttributes.EXCEPTION_MESSAGE]?this.addEvent(o.ExceptionEventName,s,i):t.diag.warn(`Failed to record an exception ${e}`)}get duration(){return this._duration}get ended(){return this._ended}_isSpanEnded(){return this._ended&&t.diag.warn("Can not execute the operation on ended Span {traceId: %s, spanId: %s}",this._spanContext.traceId,this._spanContext.spanId),this._ended}}})),gt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.buildSamplerFromEnv=e.DEFAULT_CONFIG=void 0;var t=Re(),n=ft(),r=n.getEnv(),o=n.TracesSamplerValues.AlwaysOn;function i(e=n.getEnv()){switch(e.OTEL_TRACES_SAMPLER){case n.TracesSamplerValues.AlwaysOn:return new n.AlwaysOnSampler;case n.TracesSamplerValues.AlwaysOff:return new n.AlwaysOffSampler;case n.TracesSamplerValues.ParentBasedAlwaysOn:return new n.ParentBasedSampler({root:new n.AlwaysOnSampler});case n.TracesSamplerValues.ParentBasedAlwaysOff:return new n.ParentBasedSampler({root:new n.AlwaysOffSampler});case n.TracesSamplerValues.TraceIdRatio:return new n.TraceIdRatioBasedSampler(a(e));case n.TracesSamplerValues.ParentBasedTraceIdRatio:return new n.ParentBasedSampler({root:new n.TraceIdRatioBasedSampler(a(e))});default:return t.diag.error(`OTEL_TRACES_SAMPLER value "${e.OTEL_TRACES_SAMPLER} invalid, defaulting to ${o}".`),new n.AlwaysOnSampler}}e.DEFAULT_CONFIG={sampler:i(r),forceFlushTimeoutMillis:3e4,spanLimits:{attributeCountLimit:n.getEnv().OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT,linkCountLimit:n.getEnv().OTEL_SPAN_LINK_COUNT_LIMIT,eventCountLimit:n.getEnv().OTEL_SPAN_EVENT_COUNT_LIMIT}},e.buildSamplerFromEnv=i;var s=1;function a(e){if(void 0===e.OTEL_TRACES_SAMPLER_ARG||""===e.OTEL_TRACES_SAMPLER_ARG)return t.diag.error(`OTEL_TRACES_SAMPLER_ARG is blank, defaulting to ${s}.`),s;let n=Number(e.OTEL_TRACES_SAMPLER_ARG);return isNaN(n)?(t.diag.error(`OTEL_TRACES_SAMPLER_ARG=${e.OTEL_TRACES_SAMPLER_ARG} was given, but it is invalid, defaulting to ${s}.`),s):n<0||n>1?(t.diag.error(`OTEL_TRACES_SAMPLER_ARG=${e.OTEL_TRACES_SAMPLER_ARG} was given, but it is out of range ([0..1]), defaulting to ${s}.`),s):n}})),yt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.mergeConfig=void 0;var t=gt();e.mergeConfig=function(e){let n={sampler:t.buildSamplerFromEnv()},r=Object.assign({},t.DEFAULT_CONFIG,n,e);return r.spanLimits=Object.assign({},t.DEFAULT_CONFIG.spanLimits,e.spanLimits||{}),r}})),_t=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Tracer=void 0;var t=Re(),n=ft(),r=vt(),o=yt();e.Tracer=class{constructor(e,t,r){this._tracerProvider=r;let i=o.mergeConfig(t);this._sampler=i.sampler,this._spanLimits=i.spanLimits,this._idGenerator=t.idGenerator||new n.RandomIdGenerator,this.resource=r.resource,this.instrumentationLibrary=e}startSpan(e,o={},i=t.context.active()){var s,a;if(n.isTracingSuppressed(i))return t.diag.debug("Instrumentation suppressed, returning Noop Span"),t.trace.wrapSpanContext(t.INVALID_SPAN_CONTEXT);let c,u,l,p=function(e,n){if(!e.root)return t.trace.getSpanContext(n)}(o,i),d=this._idGenerator.generateSpanId();p&&t.trace.isSpanContextValid(p)?(c=p.traceId,u=p.traceState,l=p.spanId):c=this._idGenerator.generateTraceId();let h=null!==(s=o.kind)&&void 0!==s?s:t.SpanKind.INTERNAL,f=null!==(a=o.links)&&void 0!==a?a:[],m=n.sanitizeAttributes(o.attributes),v=this._sampler.shouldSample(o.root?t.trace.setSpanContext(i,t.INVALID_SPAN_CONTEXT):i,c,e,h,m,f),g={traceId:c,spanId:d,traceFlags:v.decision===t.SamplingDecision.RECORD_AND_SAMPLED?t.TraceFlags.SAMPLED:t.TraceFlags.NONE,traceState:u};if(v.decision===t.SamplingDecision.NOT_RECORD)return t.diag.debug("Recording is off, propagating context in a non-recording span"),t.trace.wrapSpanContext(g);let y=new r.Span(this,i,e,g,h,l,f,o.startTime);return y.setAttributes(Object.assign(m,v.attributes)),y}startActiveSpan(e,n,r,o){let i,s,a;if(arguments.length<2)return;2===arguments.length?a=n:3===arguments.length?(i=n,a=r):(i=n,s=r,a=o);let c=s??t.context.active(),u=this.startSpan(e,i,c),l=t.trace.setSpan(c,u);return t.context.with(l,a,void 0,u)}getSpanLimits(){return this._spanLimits}getActiveSpanProcessor(){return this._tracerProvider.getActiveSpanProcessor()}}})),bt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.defaultServiceName=void 0,e.defaultServiceName=function(){return`unknown_service:${process.argv0}`}})),Et=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.detectResources=void 0;var t=At(),r=Re(),o=n(9023);e.detectResources=async(e={})=>{let n=Object.assign(e),o=await Promise.all((n.detectors||[]).map((async e=>{try{let t=await e.detect(n);return r.diag.debug(`${e.constructor.name} found resource.`,t),t}catch(n){return r.diag.debug(`${e.constructor.name} failed: ${n.message}`),t.Resource.empty()}})));return i(o),o.reduce(((e,t)=>e.merge(t)),t.Resource.empty())};var i=e=>{e.forEach((e=>{if(Object.keys(e.attributes).length>0){let t=o.inspect(e.attributes,{depth:2,breakLength:1/0,sorted:!0,compact:!1});r.diag.verbose(t)}}))}})),Tt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.envDetector=void 0;var t=Re(),n=ft(),r=We(),o=Pt();e.envDetector=new class{constructor(){this._MAX_LENGTH=255,this._COMMA_SEPARATOR=",",this._LABEL_KEY_VALUE_SPLITTER="=",this._ERROR_MESSAGE_INVALID_CHARS="should be a ASCII string with a length greater than 0 and not exceed "+this._MAX_LENGTH+" characters.",this._ERROR_MESSAGE_INVALID_VALUE="should be a ASCII string with a length not exceed "+this._MAX_LENGTH+" characters."}async detect(e){let i={},s=n.getEnv(),a=s.OTEL_RESOURCE_ATTRIBUTES,c=s.OTEL_SERVICE_NAME;if(a)try{let e=this._parseResourceAttributes(a);Object.assign(i,e)}catch(e){t.diag.debug(`EnvDetector failed: ${e.message}`)}return c&&(i[r.ResourceAttributes.SERVICE_NAME]=c),new o.Resource(i)}_parseResourceAttributes(e){if(!e)return{};let t={},n=e.split(this._COMMA_SEPARATOR,-1);for(let e of n){let n=e.split(this._LABEL_KEY_VALUE_SPLITTER,-1);if(2!==n.length)continue;let[r,o]=n;if(r=r.trim(),o=o.trim().split('^"|"$').join(""),!this._isValidAndNotEmpty(r))throw new Error(`Attribute key ${this._ERROR_MESSAGE_INVALID_CHARS}`);if(!this._isValid(o))throw new Error(`Attribute value ${this._ERROR_MESSAGE_INVALID_VALUE}`);t[r]=o}return t}_isValid(e){return e.length<=this._MAX_LENGTH&&this._isPrintableString(e)}_isPrintableString(e){for(let t=0;t<e.length;t++){let n=e.charAt(t);if(n<=" "||n>="~")return!1}return!0}_isValidAndNotEmpty(e){return e.length>0&&this._isValid(e)}}})),St=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.processDetector=void 0;var t=Re(),n=We(),r=Pt();e.processDetector=new class{async detect(e){let t={[n.ResourceAttributes.PROCESS_PID]:process.pid,[n.ResourceAttributes.PROCESS_EXECUTABLE_NAME]:process.title||"",[n.ResourceAttributes.PROCESS_COMMAND]:process.argv[1]||"",[n.ResourceAttributes.PROCESS_COMMAND_LINE]:process.argv.join(" ")||""};return this._getResourceAttributes(t,e)}_getResourceAttributes(e,o){return""===e[n.ResourceAttributes.PROCESS_EXECUTABLE_NAME]||""===e[n.ResourceAttributes.PROCESS_EXECUTABLE_PATH]||""===e[n.ResourceAttributes.PROCESS_COMMAND]||""===e[n.ResourceAttributes.PROCESS_COMMAND_LINE]?(t.diag.debug("ProcessDetector failed: Unable to find required process resources. "),r.Resource.empty()):new r.Resource(Object.assign({},e))}}})),Ct=b((e=>{"use strict";var t=e&&e.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=e&&e.__exportStar||function(e,n){for(var r in e)"default"!==r&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(Tt(),e),n(St(),e)})),xt=b((e=>{"use strict";var t=e&&e.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=e&&e.__exportStar||function(e,n){for(var r in e)"default"!==r&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(bt(),e),n(Et(),e),n(Ct(),e)})),wt=b((e=>{"use strict";var t=e&&e.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=e&&e.__exportStar||function(e,n){for(var r in e)"default"!==r&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(xt(),e)})),At=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Resource=void 0;var t=We(),n=ft(),r=wt(),o=class{constructor(e){this.attributes=e}static empty(){return o.EMPTY}static default(){return new o({[t.ResourceAttributes.SERVICE_NAME]:r.defaultServiceName(),[t.ResourceAttributes.TELEMETRY_SDK_LANGUAGE]:n.SDK_INFO[t.ResourceAttributes.TELEMETRY_SDK_LANGUAGE],[t.ResourceAttributes.TELEMETRY_SDK_NAME]:n.SDK_INFO[t.ResourceAttributes.TELEMETRY_SDK_NAME],[t.ResourceAttributes.TELEMETRY_SDK_VERSION]:n.SDK_INFO[t.ResourceAttributes.TELEMETRY_SDK_VERSION]})}merge(e){if(!e||!Object.keys(e.attributes).length)return this;let t=Object.assign({},this.attributes,e.attributes);return new o(t)}};e.Resource=o,o.EMPTY=new o({})})),It=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Rt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Pt=b((e=>{"use strict";var t=e&&e.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=e&&e.__exportStar||function(e,n){for(var r in e)"default"!==r&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(At(),e),n(wt(),e),n(It(),e),n(Rt(),e)})),Ot=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.MultiSpanProcessor=void 0;var t=ft();e.MultiSpanProcessor=class{constructor(e){this._spanProcessors=e}forceFlush(){let e=[];for(let t of this._spanProcessors)e.push(t.forceFlush());return new Promise((n=>{Promise.all(e).then((()=>{n()})).catch((e=>{t.globalErrorHandler(e||new Error("MultiSpanProcessor: forceFlush failed")),n()}))}))}onStart(e,t){for(let n of this._spanProcessors)n.onStart(e,t)}onEnd(e){for(let t of this._spanProcessors)t.onEnd(e)}shutdown(){let e=[];for(let t of this._spanProcessors)e.push(t.shutdown());return new Promise(((t,n)=>{Promise.all(e).then((()=>{t()}),n)}))}}})),Nt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.NoopSpanProcessor=void 0,e.NoopSpanProcessor=class{onStart(e,t){}onEnd(e){}shutdown(){return Promise.resolve()}forceFlush(){return Promise.resolve()}}})),kt=b(((e,t)=>{var n="__lodash_hash_undefined__",r=9007199254740991,o="[object Arguments]",i="[object AsyncFunction]",s="[object Function]",a="[object GeneratorFunction]",c="[object Null]",u="[object Object]",l="[object Proxy]",p="[object Undefined]",d=/^\[object .+?Constructor\]$/,h=/^(?:0|[1-9]\d*)$/,f={};f["[object Float32Array]"]=f["[object Float64Array]"]=f["[object Int8Array]"]=f["[object Int16Array]"]=f["[object Int32Array]"]=f["[object Uint8Array]"]=f["[object Uint8ClampedArray]"]=f["[object Uint16Array]"]=f["[object Uint32Array]"]=!0,f[o]=f["[object Array]"]=f["[object ArrayBuffer]"]=f["[object Boolean]"]=f["[object DataView]"]=f["[object Date]"]=f["[object Error]"]=f[s]=f["[object Map]"]=f["[object Number]"]=f[u]=f["[object RegExp]"]=f["[object Set]"]=f["[object String]"]=f["[object WeakMap]"]=!1;var m,v="object"==typeof global&&global&&global.Object===Object&&global,g="object"==typeof self&&self&&self.Object===Object&&self,y=v||g||Function("return this")(),_="object"==typeof e&&e&&!e.nodeType&&e,b=_&&"object"==typeof t&&t&&!t.nodeType&&t,E=b&&b.exports===_,T=E&&v.process,S=function(){try{return b&&b.require&&b.require("util").types||T&&T.binding&&T.binding("util")}catch{}}(),C=S&&S.isTypedArray,x=Array.prototype,w=Function.prototype,A=Object.prototype,I=y["__core-js_shared__"],R=w.toString,P=A.hasOwnProperty,O=(m=/[^.]+$/.exec(I&&I.keys&&I.keys.IE_PROTO||""))?"Symbol(src)_1."+m:"",N=A.toString,k=R.call(Object),D=RegExp("^"+R.call(P).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),M=E?y.Buffer:void 0,L=y.Symbol,j=y.Uint8Array,U=(M&&M.allocUnsafe,function(e,t){return function(n){return e(t(n))}}(Object.getPrototypeOf,Object)),F=Object.create,z=A.propertyIsEnumerable,q=x.splice,B=L?L.toStringTag:void 0,H=function(){try{var e=le(Object,"defineProperty");return e({},"",{}),e}catch{}}(),G=M?M.isBuffer:void 0,V=Math.max,$=Date.now,K=le(y,"Map"),W=le(Object,"create"),Q=function(){function e(){}return function(t){if(!Te(t))return{};if(F)return F(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();function Y(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function X(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function J(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Z(e){var t=this.__data__=new X(e);this.size=t.size}function ee(e,t,n){(void 0!==n&&!me(e[t],n)||void 0===n&&!(t in e))&&re(e,t,n)}function te(e,t,n){var r=e[t];(!P.call(e,t)||!me(r,n)||void 0===n&&!(t in e))&&re(e,t,n)}function ne(e,t){for(var n=e.length;n--;)if(me(e[n][0],t))return n;return-1}function re(e,t,n){"__proto__"==t&&H?H(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}Y.prototype.clear=function(){this.__data__=W?W(null):{},this.size=0},Y.prototype.delete=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},Y.prototype.get=function(e){var t=this.__data__;if(W){var r=t[e];return r===n?void 0:r}return P.call(t,e)?t[e]:void 0},Y.prototype.has=function(e){var t=this.__data__;return W?void 0!==t[e]:P.call(t,e)},Y.prototype.set=function(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=W&&void 0===t?n:t,this},X.prototype.clear=function(){this.__data__=[],this.size=0},X.prototype.delete=function(e){var t=this.__data__,n=ne(t,e);return!(n<0||(n==t.length-1?t.pop():q.call(t,n,1),--this.size,0))},X.prototype.get=function(e){var t=this.__data__,n=ne(t,e);return n<0?void 0:t[n][1]},X.prototype.has=function(e){return ne(this.__data__,e)>-1},X.prototype.set=function(e,t){var n=this.__data__,r=ne(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this},J.prototype.clear=function(){this.size=0,this.__data__={hash:new Y,map:new(K||X),string:new Y}},J.prototype.delete=function(e){var t=ue(this,e).delete(e);return this.size-=t?1:0,t},J.prototype.get=function(e){return ue(this,e).get(e)},J.prototype.has=function(e){return ue(this,e).has(e)},J.prototype.set=function(e,t){var n=ue(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this},Z.prototype.clear=function(){this.__data__=new X,this.size=0},Z.prototype.delete=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n},Z.prototype.get=function(e){return this.__data__.get(e)},Z.prototype.has=function(e){return this.__data__.has(e)},Z.prototype.set=function(e,t){var n=this.__data__;if(n instanceof X){var r=n.__data__;if(!K||r.length<199)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new J(r)}return n.set(e,t),this.size=n.size,this};var oe=function(e,t,n){for(var r=-1,o=Object(e),i=n(e),s=i.length;s--;){var a=i[++r];if(!1===t(o[a],a,o))break}return e};function ie(e){return null==e?void 0===e?p:c:B&&B in Object(e)?function(e){var t=P.call(e,B),n=e[B];try{e[B]=void 0;var r=!0}catch{}var o=N.call(e);return r&&(t?e[B]=n:delete e[B]),o}(e):function(e){return N.call(e)}(e)}function se(e){return Se(e)&&ie(e)==o}function ae(e,t,n,r,o){e!==t&&oe(t,(function(i,s){if(o||(o=new Z),Te(i))!function(e,t,n,r,o,i,s){var a=he(e,n),c=he(t,n),l=s.get(c);if(l)ee(e,n,l);else{var p=i?i(a,c,n+"",e,t,s):void 0,d=void 0===p;if(d){var h=ge(c),f=!h&&_e(c),m=!h&&!f&&Ce(c);p=c,h||f||m?ge(a)?p=a:function(e){return Se(e)&&ye(e)}(a)?p=function(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}(a):f?(d=!1,p=function(e){return e.slice()}(c)):m?(d=!1,p=function(e){var t=function(e){var t=new e.constructor(e.byteLength);return new j(t).set(new j(e)),t}(e.buffer);return new e.constructor(t,e.byteOffset,e.length)}(c)):p=[]:function(e){if(!Se(e)||ie(e)!=u)return!1;var t=U(e);if(null===t)return!0;var n=P.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&R.call(n)==k}(c)||ve(c)?(p=a,ve(a)?p=function(e){return function(e,t,n){var r=!n;n||(n={});for(var o=-1,i=t.length;++o<i;){var s=t[o],a=void 0;void 0===a&&(a=e[s]),r?re(n,s,a):te(n,s,a)}return n}(e,xe(e))}(a):(!Te(a)||be(a))&&(p=function(e){return"function"!=typeof e.constructor||de(e)?{}:Q(U(e))}(c))):d=!1}d&&(s.set(c,p),o(p,c,r,i,s),s.delete(c)),ee(e,n,p)}}(e,t,s,n,ae,r,o);else{var a=r?r(he(e,s),i,s+"",e,t,o):void 0;void 0===a&&(a=i),ee(e,s,a)}}),xe)}var ce=H?function(e,t){return H(e,"toString",{configurable:!0,enumerable:!1,value:Ae(t),writable:!0})}:Ie;function ue(e,t){var n=e.__data__;return function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}(t)?n["string"==typeof t?"string":"hash"]:n.map}function le(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return function(e){return!(!Te(e)||function(e){return!!O&&O in e}(e))&&(be(e)?D:d).test(function(e){if(null!=e){try{return R.call(e)}catch{}try{return e+""}catch{}}return""}(e))}(n)?n:void 0}function pe(e,t){var n=typeof e;return!!(t=t??r)&&("number"==n||"symbol"!=n&&h.test(e))&&e>-1&&e%1==0&&e<t}function de(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||A)}function he(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]}var fe=function(e){var t=0,n=0;return function(){var r=$(),o=16-(r-n);if(n=r,o>0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}(ce);function me(e,t){return e===t||e!=e&&t!=t}var ve=se(function(){return arguments}())?se:function(e){return Se(e)&&P.call(e,"callee")&&!z.call(e,"callee")},ge=Array.isArray;function ye(e){return null!=e&&Ee(e.length)&&!be(e)}var _e=G||function(){return!1};function be(e){if(!Te(e))return!1;var t=ie(e);return t==s||t==a||t==i||t==l}function Ee(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=r}function Te(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function Se(e){return null!=e&&"object"==typeof e}var Ce=C?function(e){return function(t){return e(t)}}(C):function(e){return Se(e)&&Ee(e.length)&&!!f[ie(e)]};function xe(e){return ye(e)?function(e,t){var n=ge(e),r=!n&&ve(e),o=!n&&!r&&_e(e),i=!n&&!r&&!o&&Ce(e),s=n||r||o||i,a=s?function(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}(e.length,String):[],c=a.length;for(var u in e)(t||P.call(e,u))&&(!s||!("length"==u||o&&("offset"==u||"parent"==u)||i&&("buffer"==u||"byteLength"==u||"byteOffset"==u)||pe(u,c)))&&a.push(u);return a}(e,!0):function(e){if(!Te(e))return function(e){var t=[];if(null!=e)for(var n in Object(e))t.push(n);return t}(e);var t=de(e),n=[];for(var r in e)"constructor"==r&&(t||!P.call(e,r))||n.push(r);return n}(e)}var we=function(e){return function(e,t){return fe(function(e,t,n){return t=V(void 0===t?e.length-1:t,0),function(){for(var r=arguments,o=-1,i=V(r.length-t,0),s=Array(i);++o<i;)s[o]=r[t+o];o=-1;for(var a=Array(t+1);++o<t;)a[o]=r[o];return a[t]=n(s),function(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}(e,this,a)}}(e,t,Ie),e+"")}((function(t,n){var r=-1,o=n.length,i=o>1?n[o-1]:void 0,s=o>2?n[2]:void 0;for(i=e.length>3&&"function"==typeof i?(o--,i):void 0,s&&function(e,t,n){if(!Te(n))return!1;var r=typeof t;return!!("number"==r?ye(n)&&pe(t,n.length):"string"==r&&t in n)&&me(n[t],e)}(n[0],n[1],s)&&(i=o<3?void 0:i,o=1),t=Object(t);++r<o;){var a=n[r];a&&e(t,a,r)}return t}))}((function(e,t,n){ae(e,t,n)}));function Ae(e){return function(){return e}}function Ie(e){return e}t.exports=we})),Dt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.BatchSpanProcessorBase=void 0;var t=Re(),n=ft();e.BatchSpanProcessorBase=class{constructor(e,t){this._exporter=e,this._finishedSpans=[],this._isShutdown=!1,this._shuttingDownPromise=Promise.resolve();let r=n.getEnv();this._maxExportBatchSize="number"==typeof(null==t?void 0:t.maxExportBatchSize)?t.maxExportBatchSize:r.OTEL_BSP_MAX_EXPORT_BATCH_SIZE,this._maxQueueSize="number"==typeof(null==t?void 0:t.maxQueueSize)?t.maxQueueSize:r.OTEL_BSP_MAX_QUEUE_SIZE,this._scheduledDelayMillis="number"==typeof(null==t?void 0:t.scheduledDelayMillis)?t.scheduledDelayMillis:r.OTEL_BSP_SCHEDULE_DELAY,this._exportTimeoutMillis="number"==typeof(null==t?void 0:t.exportTimeoutMillis)?t.exportTimeoutMillis:r.OTEL_BSP_EXPORT_TIMEOUT}forceFlush(){return this._isShutdown?this._shuttingDownPromise:this._flushAll()}onStart(e){}onEnd(e){this._isShutdown||this._addToBuffer(e)}shutdown(){return this._isShutdown||(this._isShutdown=!0,this._shuttingDownPromise=new Promise(((e,t)=>{Promise.resolve().then((()=>this.onShutdown())).then((()=>this._flushAll())).then((()=>this._exporter.shutdown())).then(e).catch((e=>{t(e)}))}))),this._shuttingDownPromise}_addToBuffer(e){this._finishedSpans.length>=this._maxQueueSize||(this._finishedSpans.push(e),this._maybeStartTimer())}_flushAll(){return new Promise(((e,t)=>{let n=[];for(let e=0,t=Math.ceil(this._finishedSpans.length/this._maxExportBatchSize);e<t;e++)n.push(this._flushOneBatch());Promise.all(n).then((()=>{e()})).catch(t)}))}_flushOneBatch(){return this._clearTimer(),0===this._finishedSpans.length?Promise.resolve():new Promise(((e,r)=>{let o=setTimeout((()=>{r(new Error("Timeout"))}),this._exportTimeoutMillis);t.context.with(n.suppressTracing(t.context.active()),(()=>{this._exporter.export(this._finishedSpans.splice(0,this._maxExportBatchSize),(t=>{var i;clearTimeout(o),t.code===n.ExportResultCode.SUCCESS?e():r(null!==(i=t.error)&&void 0!==i?i:new Error("BatchSpanProcessor: span export failed"))}))}))}))}_maybeStartTimer(){void 0===this._timer&&(this._timer=setTimeout((()=>{this._flushOneBatch().then((()=>{this._finishedSpans.length>0&&(this._clearTimer(),this._maybeStartTimer())})).catch((e=>{n.globalErrorHandler(e)}))}),this._scheduledDelayMillis),n.unrefTimer(this._timer))}_clearTimer(){void 0!==this._timer&&(clearTimeout(this._timer),this._timer=void 0)}}})),Mt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.BatchSpanProcessor=void 0;var t=Dt(),n=class extends t.BatchSpanProcessorBase{onShutdown(){}};e.BatchSpanProcessor=n})),Lt=b((e=>{"use strict";var t=e&&e.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=e&&e.__exportStar||function(e,n){for(var r in e)"default"!==r&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(Mt(),e)})),jt=b((e=>{"use strict";var t=e&&e.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=e&&e.__exportStar||function(e,n){for(var r in e)"default"!==r&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(Lt(),e)})),Ut=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.BasicTracerProvider=e.ForceFlushState=void 0;var t,n,r=Re(),o=ft(),i=Pt(),s=Kt(),a=gt(),c=Ot(),u=Nt(),l=kt(),p=jt();(n=t=e.ForceFlushState||(e.ForceFlushState={}))[n.resolved=0]="resolved",n[n.timeout=1]="timeout",n[n.error=2]="error",n[n.unresolved=3]="unresolved";var d=class{constructor(e={}){var t;this._registeredSpanProcessors=[],this._tracers=new Map;let n=l({},a.DEFAULT_CONFIG,e);this.resource=null!==(t=n.resource)&&void 0!==t?t:i.Resource.empty(),this.resource=i.Resource.default().merge(this.resource),this._config=Object.assign({},n,{resource:this.resource});let r=this._buildExporterFromEnv();if(void 0!==r){let e=new p.BatchSpanProcessor(r);this.activeSpanProcessor=e}else this.activeSpanProcessor=new u.NoopSpanProcessor}getTracer(e,t){let n=`${e}@${t||""}`;return this._tracers.has(n)||this._tracers.set(n,new s.Tracer({name:e,version:t},this._config,this)),this._tracers.get(n)}addSpanProcessor(e){0===this._registeredSpanProcessors.length&&this.activeSpanProcessor.shutdown().catch((e=>r.diag.error("Error while trying to shutdown current span processor",e))),this._registeredSpanProcessors.push(e),this.activeSpanProcessor=new c.MultiSpanProcessor(this._registeredSpanProcessors)}getActiveSpanProcessor(){return this.activeSpanProcessor}register(e={}){r.trace.setGlobalTracerProvider(this),void 0===e.propagator&&(e.propagator=this._buildPropagatorFromEnv()),e.contextManager&&r.context.setGlobalContextManager(e.contextManager),e.propagator&&r.propagation.setGlobalPropagator(e.propagator)}forceFlush(){let e=this._config.forceFlushTimeoutMillis,n=this._registeredSpanProcessors.map((n=>new Promise((r=>{let o,i=setTimeout((()=>{r(new Error(`Span processor did not completed within timeout period of ${e} ms`)),o=t.timeout}),e);n.forceFlush().then((()=>{clearTimeout(i),o!==t.timeout&&(o=t.resolved,r(o))})).catch((e=>{clearTimeout(i),o=t.error,r(e)}))}))));return new Promise(((e,r)=>{Promise.all(n).then((n=>{let o=n.filter((e=>e!==t.resolved));o.length>0?r(o):e()})).catch((e=>r([e])))}))}shutdown(){return this.activeSpanProcessor.shutdown()}_getPropagator(e){var t;return null===(t=d._registeredPropagators.get(e))||void 0===t?void 0:t()}_getSpanExporter(e){var t;return null===(t=d._registeredExporters.get(e))||void 0===t?void 0:t()}_buildPropagatorFromEnv(){let e=Array.from(new Set(o.getEnv().OTEL_PROPAGATORS)),t=e.map((e=>{let t=this._getPropagator(e);return t||r.diag.warn(`Propagator "${e}" requested through environment variable is unavailable.`),t})).reduce(((e,t)=>(t&&e.push(t),e)),[]);if(0!==t.length)return 1===e.length?t[0]:new o.CompositePropagator({propagators:t})}_buildExporterFromEnv(){let e=o.getEnv().OTEL_TRACES_EXPORTER;if("none"===e)return;let t=this._getSpanExporter(e);return t||r.diag.error(`Exporter "${e}" requested through environment variable is unavailable.`),t}};e.BasicTracerProvider=d,d._registeredPropagators=new Map([["tracecontext",()=>new o.HttpTraceContextPropagator],["baggage",()=>new o.HttpBaggagePropagator]]),d._registeredExporters=new Map})),Ft=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ConsoleSpanExporter=void 0;var t=ft();e.ConsoleSpanExporter=class{export(e,t){return this._sendSpans(e,t)}shutdown(){return this._sendSpans([]),Promise.resolve()}_exportInfo(e){return{traceId:e.spanContext().traceId,parentId:e.parentSpanId,name:e.name,id:e.spanContext().spanId,kind:e.kind,timestamp:t.hrTimeToMicroseconds(e.startTime),duration:t.hrTimeToMicroseconds(e.duration),attributes:e.attributes,status:e.status,events:e.events}}_sendSpans(e,n){for(let t of e)console.log(this._exportInfo(t));if(n)return n({code:t.ExportResultCode.SUCCESS})}}})),zt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.InMemorySpanExporter=void 0;var t=ft();e.InMemorySpanExporter=class{constructor(){this._finishedSpans=[],this._stopped=!1}export(e,n){if(this._stopped)return n({code:t.ExportResultCode.FAILED,error:new Error("Exporter has been stopped")});this._finishedSpans.push(...e),setTimeout((()=>n({code:t.ExportResultCode.SUCCESS})),0)}shutdown(){return this._stopped=!0,this._finishedSpans=[],Promise.resolve()}reset(){this._finishedSpans=[]}getFinishedSpans(){return this._finishedSpans}}})),qt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Bt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.SimpleSpanProcessor=void 0;var t=Re(),n=ft();e.SimpleSpanProcessor=class{constructor(e){this._exporter=e,this._isShutdown=!1,this._shuttingDownPromise=Promise.resolve()}forceFlush(){return Promise.resolve()}onStart(e){}onEnd(e){this._isShutdown||t.context.with(n.suppressTracing(t.context.active()),(()=>{this._exporter.export([e],(e=>{var t;e.code!==n.ExportResultCode.SUCCESS&&n.globalErrorHandler(null!==(t=e.error)&&void 0!==t?t:new Error(`SimpleSpanProcessor: span export failed (status ${e})`))}))}))}shutdown(){return this._isShutdown||(this._isShutdown=!0,this._shuttingDownPromise=new Promise(((e,t)=>{Promise.resolve().then((()=>this._exporter.shutdown())).then(e).catch((e=>{t(e)}))}))),this._shuttingDownPromise}}})),Ht=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Gt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Vt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),$t=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Kt=b((e=>{"use strict";var t=e&&e.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=e&&e.__exportStar||function(e,n){for(var r in e)"default"!==r&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(_t(),e),n(Ut(),e),n(jt(),e),n(Ft(),e),n(zt(),e),n(qt(),e),n(Bt(),e),n(Ht(),e),n(Nt(),e),n(vt(),e),n(Gt(),e),n(Vt(),e),n($t(),e)})),Wt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.enable=e.azureCoreTracing=e.AzureMonitorSymbol=void 0;var t=D();e.AzureMonitorSymbol="Azure_Monitor_Tracer";var n=!1;e.azureCoreTracing={versionSpecifier:">= 1.0.0 < 2.0.0",patch:function(r){if(n)return r;try{var o=Kt(),i=Re(),s=(new o.BasicTracerProvider).getTracer("applicationinsights tracer"),a=r.setTracer;r.setTracer=function(n){var r=n.startSpan;n.startSpan=function(e,n,o){var i=r.call(this,e,n,o),s=i.end;return i.end=function(){var e=s.apply(this,arguments);return t.channel.publish("azure-coretracing",i),e},i},n[e.AzureMonitorSymbol]=!0,a.call(this,n)},i.trace.getSpan(i.context.active()),r.setTracer(s),n=!0}catch{}return r}},e.enable=function(){t.channel.registerMonkeyPatch("@azure/core-tracing",e.azureCoreTracing)}})),Qt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.enable=e.bunyan=void 0;var t=D();e.bunyan={versionSpecifier:">= 1.0.0 < 2.0.0",patch:function(e){var n=e.prototype._emit;return e.prototype._emit=function(e,r){var o=n.apply(this,arguments);if(!r){var i=o;i||(i=n.call(this,e,!0)),t.channel.publish("bunyan",{level:e.level,result:i})}return o},e}},e.enable=function(){t.channel.registerMonkeyPatch("bunyan",e.bunyan)}})),Yt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.enable=e.console=void 0;var t=D(),r=n(2203);e.console={versionSpecifier:">= 4.0.0",patch:function(e){var n=new r.Writable,o=new r.Writable;n.write=function(e){if(!e)return!0;var n=e.toString();return t.channel.publish("console",{message:n}),!0},o.write=function(e){if(!e)return!0;var n=e.toString();return t.channel.publish("console",{message:n,stderr:!0}),!0};for(var i=new e.Console(n,o),s=function(t){var n=e[t];n&&(e[t]=function(){if(i[t])try{i[t].apply(i,arguments)}catch{}return n.apply(e,arguments)})},a=0,c=["log","info","warn","error","dir","time","timeEnd","trace","assert"];a<c.length;a++)s(c[a]);return e}},e.enable=function(){t.channel.registerMonkeyPatch("console",e.console),n(4236)}})),Xt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.enable=e.mongoCore=void 0;var t=D();e.mongoCore={versionSpecifier:">= 2.0.0 < 4.0.0",patch:function(e){var n=e.Server.prototype.connect;return e.Server.prototype.connect=function(){var e=n.apply(this,arguments),r=this.s.pool.write;this.s.pool.write=function(){var e="function"==typeof arguments[1]?1:2;return"function"==typeof arguments[e]&&(arguments[e]=t.channel.bindToContext(arguments[e])),r.apply(this,arguments)};var o=this.s.pool.logout;return this.s.pool.logout=function(){return"function"==typeof arguments[1]&&(arguments[1]=t.channel.bindToContext(arguments[1])),o.apply(this,arguments)},e},e}},e.enable=function(){t.channel.registerMonkeyPatch("mongodb-core",e.mongoCore)}})),Jt=b((e=>{"use strict";var t=e&&e.__assign||function(){return t=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},t.apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.enable=e.mongo330=e.mongo3=e.mongo2=void 0;var n=D();e.mongo2={versionSpecifier:">= 2.0.0 <= 3.0.5",patch:function(e){var r=e.instrument({operationIdGenerator:{next:function(){return n.channel.bindToContext((function(e){return e()}))}}}),o={};return r.on("started",(function(e){o[e.requestId]||(o[e.requestId]=t(t({},e),{time:new Date}))})),r.on("succeeded",(function(e){var t=o[e.requestId];t&&delete o[e.requestId],"function"==typeof e.operationId?e.operationId((function(){return n.channel.publish("mongodb",{startedData:t,event:e,succeeded:!0})})):n.channel.publish("mongodb",{startedData:t,event:e,succeeded:!0})})),r.on("failed",(function(e){var t=o[e.requestId];t&&delete o[e.requestId],"function"==typeof e.operationId?e.operationId((function(){return n.channel.publish("mongodb",{startedData:t,event:e,succeeded:!1})})):n.channel.publish("mongodb",{startedData:t,event:e,succeeded:!1})})),e}},e.mongo3={versionSpecifier:"> 3.0.5 < 3.3.0",patch:function(e){var r=e.instrument(),o={},i={};return r.on("started",(function(e){o[e.requestId]||(i[e.requestId]=n.channel.bindToContext((function(e){return e()})),o[e.requestId]=t(t({},e),{time:new Date}))})),r.on("succeeded",(function(e){var t=o[e.requestId];t&&delete o[e.requestId],"object"==typeof e&&"function"==typeof i[e.requestId]&&(i[e.requestId]((function(){return n.channel.publish("mongodb",{startedData:t,event:e,succeeded:!0})})),delete i[e.requestId])})),r.on("failed",(function(e){var t=o[e.requestId];t&&delete o[e.requestId],"object"==typeof e&&"function"==typeof i[e.requestId]&&(i[e.requestId]((function(){return n.channel.publish("mongodb",{startedData:t,event:e,succeeded:!1})})),delete i[e.requestId])})),e}},e.mongo330={versionSpecifier:">= 3.3.0 < 4.0.0",patch:function(e){!function(e){var t=e.Server.prototype.connect;e.Server.prototype.connect=function(){var e=t.apply(this,arguments),r=this.s.coreTopology.s.pool.write;this.s.coreTopology.s.pool.write=function(){var e="function"==typeof arguments[1]?1:2;return"function"==typeof arguments[e]&&(arguments[e]=n.channel.bindToContext(arguments[e])),r.apply(this,arguments)};var o=this.s.coreTopology.s.pool.logout;return this.s.coreTopology.s.pool.logout=function(){return"function"==typeof arguments[1]&&(arguments[1]=n.channel.bindToContext(arguments[1])),o.apply(this,arguments)},e}}(e);var t=e.instrument(),r={},o={};return t.on("started",(function(e){r[e.requestId]||(o[e.requestId]=n.channel.bindToContext((function(e){return e()})),r[e.requestId]=e)})),t.on("succeeded",(function(e){var t=r[e.requestId];t&&delete r[e.requestId],"object"==typeof e&&"function"==typeof o[e.requestId]&&(o[e.requestId]((function(){return n.channel.publish("mongodb",{startedData:t,event:e,succeeded:!0})})),delete o[e.requestId])})),t.on("failed",(function(e){var t=r[e.requestId];t&&delete r[e.requestId],"object"==typeof e&&"function"==typeof o[e.requestId]&&(o[e.requestId]((function(){return n.channel.publish("mongodb",{startedData:t,event:e,succeeded:!1})})),delete o[e.requestId])})),e}},e.enable=function(){n.channel.registerMonkeyPatch("mongodb",e.mongo2),n.channel.registerMonkeyPatch("mongodb",e.mongo3),n.channel.registerMonkeyPatch("mongodb",e.mongo330)}})),Zt=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.enable=e.mysql=void 0;var t=D(),r=n(6928);e.mysql={versionSpecifier:">= 2.0.0 < 3.0.0",patch:function(e,o){var i=function(e,n){return function(n,r){var o=e[n];o&&(e[n]=function(){for(var e=arguments.length-1,n=arguments.length-1;n>=0;--n){if("function"==typeof arguments[n]){e=n;break}if(typeof arguments[n]<"u")break}var i=arguments[e],s={result:null,startTime:null,startDate:null};"function"==typeof i&&(r?(s.startTime=process.hrtime(),s.startDate=new Date,arguments[e]=t.channel.bindToContext(r(s,i))):arguments[e]=t.channel.bindToContext(i));var a=o.apply(this,arguments);return s.result=a,a})}},s=function(e,t){return i(e.prototype)},a=n(889)(r.dirname(o)+"/lib/Connection");["connect","changeUser","ping","statistics","end"].forEach((function(e){return s(a)(e)})),i(a)("createQuery",(function(e,n){return function(r){var o=process.hrtime(e.startTime),i=1e3*o[0]+o[1]/1e6|0;t.channel.publish("mysql",{query:e.result,callbackArgs:arguments,err:r,duration:i,time:e.startDate}),n.apply(this,arguments)}}));var c=n(8371)(r.dirname(o)+"/lib/Pool");return["_enqueueCallback"].forEach((function(e){return s(c)(e)})),e}},e.enable=function(){t.channel.registerMonkeyPatch("mysql",e.mysql)}})),en=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.enable=e.postgresPool1=void 0;var t=D();e.postgresPool1={versionSpecifier:">= 1.0.0 < 3.0.0",patch:function(e){var n=e.prototype.connect;return e.prototype.connect=function(e){return e&&(arguments[0]=t.channel.bindToContext(e)),n.apply(this,arguments)},e}},e.enable=function(){t.channel.registerMonkeyPatch("pg-pool",e.postgresPool1)}})),tn=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.enable=e.postgres7=e.postgres6=void 0;var t=D(),r=n(4434);e.postgres6={versionSpecifier:"6.*",patch:function(e,n){var o=e.Client.prototype.query,i="__diagnosticOriginalFunc";return e.Client.prototype.query=function(e,n,s){var a,c={query:{},database:{host:this.connectionParameters.host,port:this.connectionParameters.port},result:null,error:null,duration:0,time:new Date},u=process.hrtime();function l(e){e&&e[i]&&(e=e[i]);var n=t.channel.bindToContext((function(n,o){var i=process.hrtime(u);if(c.result=o&&{rowCount:o.rowCount,command:o.command},c.error=n,c.duration=Math.ceil(1e3*i[0]+i[1]/1e6),t.channel.publish("postgres",c),n){if(e)return e.apply(this,arguments);a&&a instanceof r.EventEmitter&&a.emit("error",n)}else e&&e.apply(this,arguments)}));try{return Object.defineProperty(n,i,{value:e}),n}catch{return e}}try{"string"==typeof e?n instanceof Array?(c.query.preparable={text:e,args:n},s=l(s)):(c.query.text=e,s?s=l(s):n=l(n)):("string"==typeof e.name?c.query.plan=e.name:e.values instanceof Array?c.query.preparable={text:e.text,args:e.values}:c.query.text=e.text,s?s=l(s):n?n=l(n):e.callback=l(e.callback))}catch{return o.apply(this,arguments)}return arguments[0]=e,arguments[1]=n,arguments[2]=s,arguments.length=arguments.length>3?arguments.length:3,a=o.apply(this,arguments)},e}},e.postgres7={versionSpecifier:">=7.* <=8.*",patch:function(e,n){var o=e.Client.prototype.query,i="__diagnosticOriginalFunc";return e.Client.prototype.query=function(e,n,s){var a,c=this,u=!!s,l={query:{},database:{host:this.connectionParameters.host,port:this.connectionParameters.port},result:null,error:null,duration:0,time:new Date},p=process.hrtime();function d(e){e&&e[i]&&(e=e[i]);var n=t.channel.bindToContext((function(n,o){var i=process.hrtime(p);if(l.result=o&&{rowCount:o.rowCount,command:o.command},l.error=n,l.duration=Math.ceil(1e3*i[0]+i[1]/1e6),t.channel.publish("postgres",l),n){if(e)return e.apply(this,arguments);a&&a instanceof r.EventEmitter&&a.emit("error",n)}else e&&e.apply(this,arguments)}));try{return Object.defineProperty(n,i,{value:e}),n}catch{return e}}try{"string"==typeof e?n instanceof Array?(l.query.preparable={text:e,args:n},s=(u="function"==typeof s)?d(s):s):(l.query.text=e,s?s=(u="function"==typeof s)?d(s):s:n=(u="function"==typeof n)?d(n):n):("string"==typeof e.name?l.query.plan=e.name:e.values instanceof Array?l.query.preparable={text:e.text,args:e.values}:l.query.text=e.text,s?(u="function"==typeof s,s=d(s)):n?n=(u="function"==typeof n)?d(n):n:(u="function"==typeof e.callback,e.callback=u?d(e.callback):e.callback))}catch{return o.apply(this,arguments)}return arguments[0]=e,arguments[1]=n,arguments[2]=s,arguments.length=arguments.length>3?arguments.length:3,a=o.apply(this,arguments),u?a:a.then((function(e){return d()(void 0,e),new c._Promise((function(t,n){t(e)}))})).catch((function(e){return d()(e,void 0),new c._Promise((function(t,n){n(e)}))}))},e}},e.enable=function(){t.channel.registerMonkeyPatch("pg",e.postgres6),t.channel.registerMonkeyPatch("pg",e.postgres7)}})),nn=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.enable=e.redis=void 0;var t=D();e.redis={versionSpecifier:">= 2.0.0 < 4.0.0",patch:function(e){var n=e.RedisClient.prototype.internal_send_command;return e.RedisClient.prototype.internal_send_command=function(e){if(e){var r=e.callback;if(!r||!r.pubsubBound){var o=this.address,i=process.hrtime(),s=new Date;e.callback=t.channel.bindToContext((function(n,a){var c=process.hrtime(i),u=1e3*c[0]+c[1]/1e6|0;t.channel.publish("redis",{duration:u,address:o,commandObj:e,err:n,result:a,time:s}),"function"==typeof r&&r.apply(this,arguments)})),e.callback.pubsubBound=!0}}return n.call(this,e)},e}},e.enable=function(){t.channel.registerMonkeyPatch("redis",e.redis)}})),rn=b((e=>{"use strict";var t=e&&e.__assign||function(){return t=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},t.apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.enable=e.tedious=void 0;var n=D();e.tedious={versionSpecifier:">= 6.0.0 < 9.0.0",patch:function(e){var r=e.Connection.prototype.makeRequest;return e.Connection.prototype.makeRequest=function(){var e,o,i,s=arguments[0];arguments[0].callback=(e=s.callback,o=process.hrtime(),i={query:{},database:{host:null,port:null},result:null,error:null,duration:0},n.channel.bindToContext((function(r,s,a){var c=process.hrtime(o);i=t(t({},i),{database:{host:this.connection.config.server,port:this.connection.config.options.port},result:!r&&{rowCount:s,rows:a},query:{text:this.parametersByName.statement.value},error:r,duration:Math.ceil(1e3*c[0]+c[1]/1e6)}),n.channel.publish("tedious",i),e.call(this,r,s,a)}))),r.apply(this,arguments)},e}},e.enable=function(){n.channel.registerMonkeyPatch("tedious",e.tedious)}})),on=b((e=>{"use strict";var t,n=e&&e.__extends||(t=function(e,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},t(e,n)},function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}),r=e&&e.__rest||function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n};Object.defineProperty(e,"__esModule",{value:!0}),e.enable=e.winston2=e.winston3=void 0;var o=D();e.winston3={versionSpecifier:"3.x",patch:function(e){var t=function(e){function t(t,n){var r=e.call(this,n)||this;return r.winston=t,r}return n(t,e),t.prototype.log=function(e,t){var n=e.message,i=e.level,s=e.meta,a=r(e,["message","level","meta"]);i="function"==typeof Symbol.for?e[Symbol.for("level")]:i,n=e instanceof Error?e:n;var c=function(e,t){return null!=e.config.npm.levels[t]?"npm":null!=e.config.syslog.levels[t]?"syslog":"unknown"}(this.winston,i);for(var u in s=s||{},a)a.hasOwnProperty(u)&&(s[u]=a[u]);o.channel.publish("winston",{message:n,level:i,levelKind:c,meta:s}),t()},t}(e.Transport);function i(){var n,r=arguments[0].levels||e.config.npm.levels;for(var o in r)r.hasOwnProperty(o)&&(n=void 0===n||r[o]>r[n]?o:n);this.add(new t(e,{level:n}))}var s=e.createLogger;e.createLogger=function(){var n,r=arguments[0].levels||e.config.npm.levels;for(var o in r)r.hasOwnProperty(o)&&(n=void 0===n||r[o]>r[n]?o:n);var a=s.apply(this,arguments);a.add(new t(e,{level:n}));var c=a.configure;return a.configure=function(){c.apply(this,arguments),i.apply(this,arguments)},a};var a=e.configure;return e.configure=function(){a.apply(this,arguments),i.apply(this,arguments)},e.add(new t(e)),e}},e.winston2={versionSpecifier:"2.x",patch:function(e){var t,n=e.Logger.prototype.log,r=function(n,r,i){var s;return s=t===e.config.npm.levels?"npm":t===e.config.syslog.levels?"syslog":"unknown",o.channel.publish("winston",{level:n,message:r,meta:i,levelKind:s}),r};return e.Logger.prototype.log=function(){return t=this.levels,this.filters&&0!==this.filters.length?this.filters[this.filters.length-1]!==r&&(this.filters=this.filters.filter((function(e){return e!==r})),this.filters.push(r)):this.filters=[r],n.apply(this,arguments)},e}},e.enable=function(){o.channel.registerMonkeyPatch("winston",e.winston2),o.channel.registerMonkeyPatch("winston",e.winston3)}})),sn=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.enable=e.tedious=e.pgPool=e.pg=e.winston=e.redis=e.mysql=e.mongodb=e.mongodbCore=e.console=e.bunyan=e.azuresdk=void 0;var t=Wt();e.azuresdk=t;var n=Qt();e.bunyan=n;var r=Yt();e.console=r;var o=Xt();e.mongodbCore=o;var i=Jt();e.mongodb=i;var s=Zt();e.mysql=s;var a=en();e.pgPool=a;var c=tn();e.pg=c;var u=nn();e.redis=u;var l=rn();e.tedious=l;var p=on();e.winston=p,e.enable=function(){n.enable(),r.enable(),o.enable(),i.enable(),s.enable(),c.enable(),a.enable(),u.enable(),p.enable(),t.enable(),l.enable()}})),an=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.registerContextPreservation=e.IsInitialized=void 0;var t=P(),n=R();e.IsInitialized=!process.env.APPLICATION_INSIGHTS_NO_DIAGNOSTIC_CHANNEL;var r,o,i,s,a="DiagnosticChannel";if(e.IsInitialized){for(s in r=sn(),o=(process.env.APPLICATION_INSIGHTS_NO_PATCH_MODULES||"").split(","),i={bunyan:r.bunyan,console:r.console,mongodb:r.mongodb,mongodbCore:r.mongodbCore,mysql:r.mysql,redis:r.redis,pg:r.pg,pgPool:r.pgPool,winston:r.winston,azuresdk:r.azuresdk})-1===o.indexOf(s)&&(i[s].enable(),n.info(a,"Subscribed to "+s+" events"));o.length>0&&n.info(a,"Some modules will not be patched",o)}else n.info(a,"Not subscribing to dependency autocollection because APPLICATION_INSIGHTS_NO_DIAGNOSTIC_CHANNEL was set");e.registerContextPreservation=function(n){if(e.IsInitialized){var r=D();r.channel.addContextPreservation(n),r.channel.spanContextPropagator=t.AsyncScopeManager}}})),cn=b(((e,t)=>{"use strict";t.exports={requestContextHeader:"request-context",requestContextSourceKey:"appId",requestContextTargetKey:"appId",requestIdHeader:"request-id",parentIdHeader:"x-ms-request-id",rootIdHeader:"x-ms-request-root-id",correlationContextHeader:"correlation-context",traceparentHeader:"traceparent",traceStateHeader:"tracestate"}})),un=b(((e,t)=>{"use strict";var r=e&&e.__assign||function(){return r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},r.apply(this,arguments)},o=n(8611),i=n(5692),s=n(7016),a=n(9140),c=R(),u=cn(),l=function(){function e(){}return e.getCookie=function(t,n){var r="";if(t&&t.length&&"string"==typeof n)for(var o=t+"=",i=n.split(";"),s=0;s<i.length;s++)if(n=i[s],(n=e.trim(n))&&0===n.indexOf(o)){r=n.substring(o.length,i[s].length);break}return r},e.trim=function(e){return"string"==typeof e?e.replace(/^\s+|\s+$/g,""):""},e.int32ArrayToBase64=function(e){var t=function(e,t){return String.fromCharCode(e>>t&255)},n=e.map((function(e){return t(e,24)+t(e,16)+t(e,8)+t(e,0)})).join(""),r=(Buffer.from?Buffer.from(n,"binary"):new Buffer(n,"binary")).toString("base64");return r.substr(0,r.indexOf("="))},e.random32=function(){return 4294967296*Math.random()|0},e.randomu32=function(){return e.random32()+2147483648},e.w3cTraceId=function(){for(var t,n=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],r="",o=0;o<4;o++)r+=n[15&(t=e.random32())]+n[t>>4&15]+n[t>>8&15]+n[t>>12&15]+n[t>>16&15]+n[t>>20&15]+n[t>>24&15]+n[t>>28&15];var i=n[8+4*Math.random()|0];return r.substr(0,8)+r.substr(9,4)+"4"+r.substr(13,3)+i+r.substr(16,3)+r.substr(19,12)},e.w3cSpanId=function(){return e.w3cTraceId().substring(16)},e.isValidW3CId=function(e){return 32===e.length&&"00000000000000000000000000000000"!==e},e.isArray=function(e){return"[object Array]"===Object.prototype.toString.call(e)},e.isError=function(e){return e instanceof Error},e.isPrimitive=function(e){var t=typeof e;return"string"===t||"number"===t||"boolean"===t},e.isDate=function(e){return"[object Date]"===Object.prototype.toString.call(e)},e.msToTimeSpan=function(e){(isNaN(e)||e<0)&&(e=0);var t=(e/1e3%60).toFixed(7).replace(/0{0,4}$/,""),n=""+Math.floor(e/6e4)%60,r=""+Math.floor(e/36e5)%24,o=Math.floor(e/864e5);return t=t.indexOf(".")<2?"0"+t:t,n=n.length<2?"0"+n:n,(o>0?o+".":"")+(r=r.length<2?"0"+r:r)+":"+n+":"+t},e.extractError=function(e){var t=e;return{message:e.message,code:t.code||t.id||""}},e.extractObject=function(t){return t instanceof Error?e.extractError(t):"function"==typeof t.toJSON?t.toJSON():t},e.validateStringMap=function(t){if("object"==typeof t){var n={};for(var r in t){var o="",i=t[r],s=typeof i;if(e.isPrimitive(i))o=i.toString();else if(null===i||"undefined"===s)o="";else{if("function"===s){c.info("key: "+r+" was function; will not serialize");continue}var a=e.isArray(i)?i:e.extractObject(i);try{o=e.isPrimitive(a)?a:JSON.stringify(a)}catch(e){o=i.constructor.name.toString()+" (Error: "+e.message+")",c.info("key: "+r+", could not be serialized")}}n[r]=o.substring(0,e.MAX_PROPERTY_LENGTH)}return n}c.info("Invalid properties dropped from payload")},e.canIncludeCorrelationHeader=function(e,t){var n=e&&e.config&&e.config.correlationHeaderExcludedDomains;if(!n||0==n.length||!t)return!0;for(var r=0;r<n.length;r++)if(new RegExp(n[r].replace(/\./g,".").replace(/\*/g,".*")).test(s.parse(t).hostname))return!1;return!0},e.getCorrelationContextTarget=function(e,t){var n=e.headers&&e.headers[u.requestContextHeader];if(n)for(var r=n.split(","),o=0;o<r.length;++o){var i=r[o].split("=");if(2==i.length&&i[0]==t)return i[1]}},e.makeRequest=function(t,n,a,u){n&&0===n.indexOf("//")&&(n="https:"+n);var l=s.parse(n),p=r(r({},a),{host:l.hostname,port:l.port,path:l.pathname}),d=void 0;if("https:"===l.protocol&&(d=t.proxyHttpsUrl||void 0),"http:"===l.protocol&&(d=t.proxyHttpUrl||void 0),d){0===d.indexOf("//")&&(d="http:"+d);var h=s.parse(d);"https:"===h.protocol?(c.info("Proxies that use HTTPS are not supported"),d=void 0):p=r(r({},p),{host:h.hostname,port:h.port||"80",path:n,headers:r(r({},p.headers),{Host:l.hostname})})}var f="https:"===l.protocol&&!d;return f&&void 0!==t.httpsAgent?p.agent=t.httpsAgent:f||void 0===t.httpAgent?f&&(p.agent=e.tlsRestrictedAgent):p.agent=t.httpAgent,f?i.request(p,u):o.request(p,u)},e.safeIncludeCorrelationHeader=function(t,n,r){var o;if("string"==typeof r)o=r;else if(r instanceof Array)o=r.join(",");else if(r&&"function"==typeof r.toString)try{o=r.toString()}catch(e){c.warn("Outgoing request-context header could not be read. Correlation of requests may be lost.",e,r)}o?e.addCorrelationIdHeaderFromString(t,n,o):n.setHeader(u.requestContextHeader,u.requestContextSourceKey+"="+t.config.correlationId)},e.dumpObj=function(e){var t=Object.prototype.toString.call(e);return t+("[object Error]"===t?"{ stack: '"+e.stack+"', message: '"+e.message+"', name: '"+e.name+"'":JSON.stringify(e))},e.addCorrelationIdHeaderFromString=function(e,t,n){var r=n.split(","),o=u.requestContextSourceKey+"=";r.some((function(e){return e.substring(0,o.length)===o}))||t.setHeader(u.requestContextHeader,n+","+u.requestContextSourceKey+"="+e.config.correlationId)},e.MAX_PROPERTY_LENGTH=8192,e.tlsRestrictedAgent=new i.Agent({keepAlive:!0,maxSockets:25,secureOptions:a.SSL_OP_NO_SSLv2|a.SSL_OP_NO_SSLv3|a.SSL_OP_NO_TLSv1|a.SSL_OP_NO_TLSv1_1}),e}();t.exports=l})),ln=b(((e,t)=>{"use strict";var n=un(),r=R(),o=function(){function e(){}return e.queryCorrelationId=function(t,o){var i=t.profileQueryEndpoint+"/api/profiles/"+t.instrumentationKey+"/appId";if(e.completedLookups.hasOwnProperty(i))o(e.completedLookups[i]);else if(e.pendingLookups[i])e.pendingLookups[i].push(o);else{e.pendingLookups[i]=[o];var s=function(){if(e.pendingLookups[i]){var o={method:"GET",disableAppInsightsAutoCollection:!0};r.info(e.TAG,o);var a=n.makeRequest(t,i,o,(function(n){if(200===n.statusCode){var o="";n.setEncoding("utf-8"),n.on("data",(function(e){o+=e})),n.on("end",(function(){r.info(e.TAG,o);var t=e.correlationIdPrefix+o;e.completedLookups[i]=t,e.pendingLookups[i]&&e.pendingLookups[i].forEach((function(e){return e(t)})),delete e.pendingLookups[i]}))}else n.statusCode>=400&&n.statusCode<500?(e.completedLookups[i]=void 0,delete e.pendingLookups[i]):setTimeout(s,t.correlationIdRetryIntervalMs)}));a&&(a.on("error",(function(t){r.warn(e.TAG,t)})),a.end())}};setTimeout(s,0)}},e.cancelCorrelationIdQuery=function(t,n){var r=t.profileQueryEndpoint+"/api/profiles/"+t.instrumentationKey+"/appId",o=e.pendingLookups[r];o&&(e.pendingLookups[r]=o.filter((function(e){return e!=n})),0==e.pendingLookups[r].length&&delete e.pendingLookups[r])},e.generateRequestId=function(t){if(t){"."!==(t="|"==t[0]?t:"|"+t)[t.length-1]&&(t+=".");var n=(e.currentRootId++).toString(16);return e.appendSuffix(t,n,"_")}return e.generateRootId()},e.getRootId=function(e){var t=e.indexOf(".");t<0&&(t=e.length);var n="|"===e[0]?1:0;return e.substring(n,t)},e.generateRootId=function(){return"|"+n.w3cTraceId()+"."},e.appendSuffix=function(t,r,o){if(t.length+r.length<e.requestIdMaxLength)return t+r+o;var i=e.requestIdMaxLength-9;if(t.length>i)for(;i>1;--i){var s=t[i-1];if("."===s||"_"===s)break}if(i<=1)return e.generateRootId();for(r=n.randomu32().toString(16);r.length<8;)r="0"+r;return t.substring(0,i)+r+"#"},e.TAG="CorrelationIdManager",e.correlationIdPrefix="cid-v1:",e.w3cEnabled=!0,e.pendingLookups={},e.completedLookups={},e.requestIdMaxLength=1024,e.currentRootId=n.randomu32(),e}();t.exports=o})),pn=b(((e,t)=>{"use strict";var n=un(),r=ln(),o=function(){function e(t,o){if(this.traceFlag=e.DEFAULT_TRACE_FLAG,this.version=e.DEFAULT_VERSION,t&&"string"==typeof t)if(t.split(",").length>1)this.traceId=n.w3cTraceId(),this.spanId=n.w3cTraceId().substr(0,16);else{var i=t.trim().split("-"),s=i.length;s>=4?(this.version=i[0],this.traceId=i[1],this.spanId=i[2],this.traceFlag=i[3]):(this.traceId=n.w3cTraceId(),this.spanId=n.w3cTraceId().substr(0,16)),this.version.match(/^[0-9a-f]{2}$/g)||(this.version=e.DEFAULT_VERSION,this.traceId=n.w3cTraceId()),"00"===this.version&&4!==s&&(this.traceId=n.w3cTraceId(),this.spanId=n.w3cTraceId().substr(0,16)),"ff"===this.version&&(this.version=e.DEFAULT_VERSION,this.traceId=n.w3cTraceId(),this.spanId=n.w3cTraceId().substr(0,16)),this.version.match(/^0[0-9a-f]$/g)||(this.version=e.DEFAULT_VERSION),this.traceFlag.match(/^[0-9a-f]{2}$/g)||(this.traceFlag=e.DEFAULT_TRACE_FLAG,this.traceId=n.w3cTraceId()),e.isValidTraceId(this.traceId)||(this.traceId=n.w3cTraceId()),e.isValidSpanId(this.spanId)||(this.spanId=n.w3cTraceId().substr(0,16),this.traceId=n.w3cTraceId()),this.parentId=this.getBackCompatRequestId()}else if(o){this.parentId=o.slice();var a=r.getRootId(o);e.isValidTraceId(a)||(this.legacyRootId=a,a=n.w3cTraceId()),-1!==o.indexOf("|")&&(o=o.substring(1+o.substring(0,o.length-1).lastIndexOf("."),o.length-1)),this.traceId=a,this.spanId=o}else this.traceId=n.w3cTraceId(),this.spanId=n.w3cTraceId().substr(0,16)}return e.isValidTraceId=function(e){return e.match(/^[0-9a-f]{32}$/)&&"00000000000000000000000000000000"!==e},e.isValidSpanId=function(e){return e.match(/^[0-9a-f]{16}$/)&&"0000000000000000"!==e},e.formatOpenTelemetryTraceFlags=function(e){var t="0"+e.toString(16);return t.substring(t.length-2)},e.prototype.getBackCompatRequestId=function(){return"|"+this.traceId+"."+this.spanId+"."},e.prototype.toString=function(){return this.version+"-"+this.traceId+"-"+this.spanId+"-"+this.traceFlag},e.prototype.updateSpanId=function(){this.spanId=n.w3cTraceId().substr(0,16)},e.DEFAULT_TRACE_FLAG="01",e.DEFAULT_VERSION="00",e}();t.exports=o})),dn=b(((e,t)=>{"use strict";var n=function(){function e(e){this.fieldmap=[],e&&(this.fieldmap=this.parseHeader(e))}return e.prototype.toString=function(){var e=this.fieldmap;return e&&0!=e.length?e.join(", "):null},e.validateKeyChars=function(e){var t=e.split("@");if(2==t.length){var n=t[0].trim(),r=t[1].trim(),o=Boolean(n.match(/^[\ ]?[a-z0-9\*\-\_/]{1,241}$/)),i=Boolean(r.match(/^[\ ]?[a-z0-9\*\-\_/]{1,14}$/));return o&&i}return 1==t.length&&Boolean(e.match(/^[\ ]?[a-z0-9\*\-\_/]{1,256}$/))},e.prototype.parseHeader=function(t){var n=[],r={},o=t.split(",");if(o.length>32)return null;for(var i=0,s=o;i<s.length;i++){var a=s[i].trim();if(0!==a.length){var c=a.split("=");if(2!==c.length||!e.validateKeyChars(c[0])||r[c[0]])return null;r[c[0]]=!0,n.push(a)}}return n},e.strict=!0,e}();t.exports=n})),hn=b(((e,t)=>{"use strict";t.exports=function(){}})),fn=b(((e,t)=>{"use strict";var n,r=e&&e.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},n(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),o=function(e){function t(){var t=e.call(this)||this;return t.ver=2,t.properties={},t.measurements={},t}return r(t,e),t}(hn());t.exports=o})),mn=b(((e,t)=>{"use strict";t.exports=function(){}})),vn=b(((e,t)=>{"use strict";t.exports=function(){this.applicationVersion="ai.application.ver",this.deviceId="ai.device.id",this.deviceLocale="ai.device.locale",this.deviceModel="ai.device.model",this.deviceOEMName="ai.device.oemName",this.deviceOSVersion="ai.device.osVersion",this.deviceType="ai.device.type",this.locationIp="ai.location.ip",this.operationId="ai.operation.id",this.operationName="ai.operation.name",this.operationParentId="ai.operation.parentId",this.operationSyntheticSource="ai.operation.syntheticSource",this.operationCorrelationVector="ai.operation.correlationVector",this.sessionId="ai.session.id",this.sessionIsFirst="ai.session.isFirst",this.userAccountId="ai.user.accountId",this.userId="ai.user.id",this.userAuthUserId="ai.user.authUserId",this.cloudRole="ai.cloud.role",this.cloudRoleInstance="ai.cloud.roleInstance",this.internalSdkVersion="ai.internal.sdkVersion",this.internalAgentVersion="ai.internal.agentVersion",this.internalNodeName="ai.internal.nodeName"}})),gn=b(((e,t)=>{"use strict";var n,r=e&&e.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},n(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),o=function(e){function t(){return e.call(this)||this}return r(t,e),t}(mn());t.exports=o})),yn=b(((e,t)=>{"use strict";var n,r;(r=n||(n={}))[r.Measurement=0]="Measurement",r[r.Aggregation=1]="Aggregation",t.exports=n})),_n=b(((e,t)=>{"use strict";var n=yn();t.exports=function(){this.kind=n.Measurement}})),bn=b(((e,t)=>{"use strict";t.exports=function(){this.ver=1,this.sampleRate=100,this.tags={}}})),En=b(((e,t)=>{"use strict";var n,r=e&&e.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},n(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),o=function(e){function t(){var t=e.call(this)||this;return t.ver=2,t.properties={},t.measurements={},t}return r(t,e),t}(hn());t.exports=o})),Tn=b(((e,t)=>{"use strict";var n,r=e&&e.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},n(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),o=function(e){function t(){var t=e.call(this)||this;return t.ver=2,t.exceptions=[],t.properties={},t.measurements={},t}return r(t,e),t}(hn());t.exports=o})),Sn=b(((e,t)=>{"use strict";t.exports=function(){this.hasFullStack=!0,this.parsedStack=[]}})),Cn=b(((e,t)=>{"use strict";var n,r=e&&e.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},n(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),o=function(e){function t(){var t=e.call(this)||this;return t.ver=2,t.properties={},t}return r(t,e),t}(hn());t.exports=o})),xn=b(((e,t)=>{"use strict";var n,r=e&&e.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},n(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),o=function(e){function t(){var t=e.call(this)||this;return t.ver=2,t.metrics=[],t.properties={},t}return r(t,e),t}(hn());t.exports=o})),wn=b(((e,t)=>{"use strict";var n,r=e&&e.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},n(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),o=function(e){function t(){var t=e.call(this)||this;return t.ver=2,t.properties={},t.measurements={},t}return r(t,e),t}(En());t.exports=o})),An=b(((e,t)=>{"use strict";var n,r=e&&e.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},n(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),o=function(e){function t(){var t=e.call(this)||this;return t.ver=2,t.success=!0,t.properties={},t.measurements={},t}return r(t,e),t}(hn());t.exports=o})),In=b(((e,t)=>{"use strict";var n,r=e&&e.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},n(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),o=function(e){function t(){var t=e.call(this)||this;return t.ver=2,t.properties={},t.measurements={},t}return r(t,e),t}(hn());t.exports=o})),Rn=b(((e,t)=>{"use strict";var n,r;(r=n||(n={}))[r.Verbose=0]="Verbose",r[r.Information=1]="Information",r[r.Warning=2]="Warning",r[r.Error=3]="Error",r[r.Critical=4]="Critical",t.exports=n})),Pn=b(((e,t)=>{"use strict";t.exports=function(){}})),On=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.AvailabilityData=fn(),e.Base=mn(),e.ContextTagKeys=vn(),e.Data=gn(),e.DataPoint=_n(),e.DataPointType=yn(),e.Domain=hn(),e.Envelope=bn(),e.EventData=En(),e.ExceptionData=Tn(),e.ExceptionDetails=Sn(),e.MessageData=Cn(),e.MetricData=xn(),e.PageViewData=wn(),e.RemoteDependencyData=An(),e.RequestData=In(),e.SeverityLevel=Rn(),e.StackFrame=Pn()})),Nn=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.domainSupportsProperties=e.RemoteDependencyDataConstants=void 0;var t=On(),n=function(){function e(){}return e.TYPE_HTTP="Http",e.TYPE_AI="Http (tracked component)",e}();e.RemoteDependencyDataConstants=n,e.domainSupportsProperties=function(e){return"properties"in e||e instanceof t.EventData||e instanceof t.ExceptionData||e instanceof t.MessageData||e instanceof t.MetricData||e instanceof t.PageViewData||e instanceof t.RemoteDependencyData||e instanceof t.RequestData}})),kn=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Dn=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Mn=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Ln=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),jn=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Un=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Fn=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),zn=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),qn=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Bn=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Hn=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Gn=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Vn=b((e=>{"use strict";var t,n;Object.defineProperty(e,"__esModule",{value:!0}),e.TelemetryType=e.TelemetryTypeString=e.baseTypeToTelemetryType=e.telemetryTypeToBaseType=void 0,e.telemetryTypeToBaseType=function(e){switch(e){case t.Event:return"EventData";case t.Exception:return"ExceptionData";case t.Trace:return"MessageData";case t.Metric:return"MetricData";case t.Request:return"RequestData";case t.Dependency:return"RemoteDependencyData";case t.Availability:return"AvailabilityData";case t.PageView:return"PageViewData"}},e.baseTypeToTelemetryType=function(e){switch(e){case"EventData":return t.Event;case"ExceptionData":return t.Exception;case"MessageData":return t.Trace;case"MetricData":return t.Metric;case"RequestData":return t.Request;case"RemoteDependencyData":return t.Dependency;case"AvailabilityData":return t.Availability;case"PageViewData":return t.PageView}},e.TelemetryTypeString={Event:"EventData",Exception:"ExceptionData",Trace:"MessageData",Metric:"MetricData",Request:"RequestData",Dependency:"RemoteDependencyData",Availability:"AvailabilityData",PageView:"PageViewData"},(n=t=e.TelemetryType||(e.TelemetryType={}))[n.Event=0]="Event",n[n.Exception=1]="Exception",n[n.Trace=2]="Trace",n[n.Metric=3]="Metric",n[n.Request=4]="Request",n[n.Dependency=5]="Dependency",n[n.Availability=6]="Availability",n[n.PageView=7]="PageView"})),$n=b((e=>{"use strict";var t=e&&e.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=e&&e.__exportStar||function(e,n){for(var r in e)"default"!==r&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(kn(),e),n(Dn(),e),n(Mn(),e),n(Ln(),e),n(jn(),e),n(Un(),e),n(Fn(),e),n(zn(),e),n(qn(),e),n(Bn(),e),n(Hn(),e),n(Gn(),e),n(Vn(),e)})),Kn=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Wn=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Qn=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Yn=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Xn=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Jn=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),Zn=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),er=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),tr=b((e=>{"use strict";var t=e&&e.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=e&&e.__exportStar||function(e,n){for(var r in e)"default"!==r&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(Kn(),e),n(Wn(),e),n(Qn(),e),n(Yn(),e),n(Xn(),e),n(Jn(),e),n(Zn(),e),n(er(),e)})),nr=b((e=>{"use strict";var t=e&&e.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=e&&e.__exportStar||function(e,n){for(var r in e)"default"!==r&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(Nn(),e),n(On(),e),n($n(),e),n(tr(),e)})),rr=b(((e,t)=>{"use strict";var n=function(){function e(){}return e.prototype.getUrl=function(){return this.url},e.prototype.RequestParser=function(){this.startTime=+new Date},e.prototype._setStatus=function(e,t){var n=+new Date;this.duration=n-this.startTime,this.statusCode=e;var r=this.properties||{};if(t)if("string"==typeof t)r.error=t;else if(t instanceof Error)r.error=t.message;else if("object"==typeof t)for(var o in t)r[o]=t[o]&&t[o].toString&&t[o].toString();this.properties=r},e.prototype._isSuccess=function(){return 0<this.statusCode&&this.statusCode<400},e}();t.exports=n})),or=b(((e,t)=>{"use strict";var r,o=e&&e.__extends||(r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},r(e,t)},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=n(7016),s=nr(),a=un(),c=cn(),u=rr(),l=ln(),p=dn(),d=pn(),h=function(e){function t(t,n){var r=e.call(this)||this;return t&&(r.method=t.method,r.url=r._getAbsoluteUrl(t),r.startTime=+new Date,r.socketRemoteAddress=t.socket&&t.socket.remoteAddress,r.parseHeaders(t,n),t.connection&&(r.connectionRemoteAddress=t.connection.remoteAddress,r.legacySocketRemoteAddress=t.connection.socket&&t.connection.socket.remoteAddress)),r}return o(t,e),t.prototype.onError=function(e,t){this._setStatus(void 0,e),t&&(this.duration=t)},t.prototype.onResponse=function(e,t){this._setStatus(e.statusCode,void 0),t&&(this.duration=t)},t.prototype.getRequestTelemetry=function(e){var t={id:this.requestId,name:this.method+" "+i.parse(this.url).pathname,url:this.url,source:this.sourceCorrelationId,duration:this.duration,resultCode:this.statusCode?this.statusCode.toString():null,success:this._isSuccess(),properties:this.properties};if(e&&e.time?t.time=e.time:this.startTime&&(t.time=new Date(this.startTime)),e){for(var n in e)t[n]||(t[n]=e[n]);if(e.properties)for(var n in e.properties)t.properties[n]=e.properties[n]}return t},t.prototype.getRequestTags=function(e){var n={};for(var r in e)n[r]=e[r];return n[t.keys.locationIp]=e[t.keys.locationIp]||this._getIp(),n[t.keys.sessionId]=e[t.keys.sessionId]||this._getId("ai_session"),n[t.keys.userId]=e[t.keys.userId]||this._getId("ai_user"),n[t.keys.userAuthUserId]=e[t.keys.userAuthUserId]||this._getId("ai_authUser"),n[t.keys.operationName]=this.getOperationName(e),n[t.keys.operationParentId]=this.getOperationParentId(e),n[t.keys.operationId]=this.getOperationId(e),n},t.prototype.getOperationId=function(e){return e[t.keys.operationId]||this.operationId},t.prototype.getOperationParentId=function(e){return e[t.keys.operationParentId]||this.parentId||this.getOperationId(e)},t.prototype.getOperationName=function(e){return e[t.keys.operationName]||this.method+" "+i.parse(this.url).pathname},t.prototype.getRequestId=function(){return this.requestId},t.prototype.getCorrelationContextHeader=function(){return this.correlationContextHeader},t.prototype.getTraceparent=function(){return this.traceparent},t.prototype.getTracestate=function(){return this.tracestate},t.prototype.getLegacyRootId=function(){return this.legacyRootId},t.prototype._getAbsoluteUrl=function(e){if(!e.headers)return e.url;var t=e.connection?e.connection.encrypted:null,n=i.parse(e.url),r=n.pathname,o=n.search,s=t||"https"==e.headers["x-forwarded-proto"]?"https":"http";return i.format({protocol:s,host:e.headers.host,pathname:r,search:o})},t.prototype._getIp=function(){var e=/[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}/,t=function(t){var n=e.exec(t);if(n)return n[0]},n=t(this.rawHeaders["x-forwarded-for"])||t(this.rawHeaders["x-client-ip"])||t(this.rawHeaders["x-real-ip"])||t(this.connectionRemoteAddress)||t(this.socketRemoteAddress)||t(this.legacySocketRemoteAddress);return!n&&this.connectionRemoteAddress&&this.connectionRemoteAddress.substr&&"::"===this.connectionRemoteAddress.substr(0,2)&&(n="127.0.0.1"),n},t.prototype._getId=function(e){var n=this.rawHeaders&&this.rawHeaders.cookie&&"string"==typeof this.rawHeaders.cookie&&this.rawHeaders.cookie||"";return t.parseId(a.getCookie(e,n))},t.prototype.setBackCompatFromThisTraceContext=function(){this.operationId=this.traceparent.traceId,this.traceparent.legacyRootId&&(this.legacyRootId=this.traceparent.legacyRootId),this.parentId=this.traceparent.parentId,this.traceparent.updateSpanId(),this.requestId=this.traceparent.getBackCompatRequestId()},t.prototype.parseHeaders=function(e,t){if(this.rawHeaders=e.headers||e.rawHeaders,this.userAgent=e.headers&&e.headers["user-agent"],this.sourceCorrelationId=a.getCorrelationContextTarget(e,c.requestContextSourceKey),e.headers){var n=e.headers[c.traceStateHeader]?e.headers[c.traceStateHeader].toString():null,r=e.headers[c.traceparentHeader]?e.headers[c.traceparentHeader].toString():null,o=e.headers[c.requestIdHeader]?e.headers[c.requestIdHeader].toString():null,i=e.headers[c.parentIdHeader]?e.headers[c.parentIdHeader].toString():null,s=e.headers[c.rootIdHeader]?e.headers[c.rootIdHeader].toString():null;this.correlationContextHeader=e.headers[c.correlationContextHeader]?e.headers[c.correlationContextHeader].toString():null,l.w3cEnabled&&(r||n)?(this.traceparent=new d(r?r.toString():null),this.tracestate=r&&n&&new p(n?n.toString():null),this.setBackCompatFromThisTraceContext()):o?l.w3cEnabled?(this.traceparent=new d(null,o),this.setBackCompatFromThisTraceContext()):(this.parentId=o,this.requestId=l.generateRequestId(this.parentId),this.operationId=l.getRootId(this.requestId)):l.w3cEnabled?(this.traceparent=new d,this.traceparent.parentId=i,this.traceparent.legacyRootId=s||i,this.setBackCompatFromThisTraceContext()):(this.parentId=i,this.requestId=l.generateRequestId(s||this.parentId),this.correlationContextHeader=null,this.operationId=l.getRootId(this.requestId)),t&&(this.requestId=t,this.operationId=l.getRootId(this.requestId))}},t.parseId=function(e){var t=e.split("|");return t.length>0?t[0]:""},t.keys=new s.ContextTagKeys,t}(u);t.exports=h})),ir=b(((e,t)=>{var n;e=t.exports=K,n="object"==typeof process&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?function(){var e=Array.prototype.slice.call(arguments,0);e.unshift("SEMVER"),console.log.apply(console,e)}:function(){},e.SEMVER_SPEC_VERSION="2.0.0";var r=256,o=Number.MAX_SAFE_INTEGER||9007199254740991,i=e.re=[],s=e.src=[],a=0,c=a++;s[c]="0|[1-9]\\d*";var u=a++;s[u]="[0-9]+";var l=a++;s[l]="\\d*[a-zA-Z-][a-zA-Z0-9-]*";var p=a++;s[p]="("+s[c]+")\\.("+s[c]+")\\.("+s[c]+")";var d=a++;s[d]="("+s[u]+")\\.("+s[u]+")\\.("+s[u]+")";var h=a++;s[h]="(?:"+s[c]+"|"+s[l]+")";var f=a++;s[f]="(?:"+s[u]+"|"+s[l]+")";var m=a++;s[m]="(?:-("+s[h]+"(?:\\."+s[h]+")*))";var v=a++;s[v]="(?:-?("+s[f]+"(?:\\."+s[f]+")*))";var g=a++;s[g]="[0-9A-Za-z-]+";var y=a++;s[y]="(?:\\+("+s[g]+"(?:\\."+s[g]+")*))";var _=a++,b="v?"+s[p]+s[m]+"?"+s[y]+"?";s[_]="^"+b+"$";var E="[v=\\s]*"+s[d]+s[v]+"?"+s[y]+"?",T=a++;s[T]="^"+E+"$";var S=a++;s[S]="((?:<|>)?=?)";var C=a++;s[C]=s[u]+"|x|X|\\*";var x=a++;s[x]=s[c]+"|x|X|\\*";var w=a++;s[w]="[v=\\s]*("+s[x]+")(?:\\.("+s[x]+")(?:\\.("+s[x]+")(?:"+s[m]+")?"+s[y]+"?)?)?";var A=a++;s[A]="[v=\\s]*("+s[C]+")(?:\\.("+s[C]+")(?:\\.("+s[C]+")(?:"+s[v]+")?"+s[y]+"?)?)?";var I=a++;s[I]="^"+s[S]+"\\s*"+s[w]+"$";var R=a++;s[R]="^"+s[S]+"\\s*"+s[A]+"$";var P=a++;s[P]="(?:^|[^\\d])(\\d{1,16})(?:\\.(\\d{1,16}))?(?:\\.(\\d{1,16}))?(?:$|[^\\d])";var O=a++;s[O]="(?:~>?)";var N=a++;s[N]="(\\s*)"+s[O]+"\\s+",i[N]=new RegExp(s[N],"g");var k=a++;s[k]="^"+s[O]+s[w]+"$";var D=a++;s[D]="^"+s[O]+s[A]+"$";var M=a++;s[M]="(?:\\^)";var L=a++;s[L]="(\\s*)"+s[M]+"\\s+",i[L]=new RegExp(s[L],"g");var j=a++;s[j]="^"+s[M]+s[w]+"$";var U=a++;s[U]="^"+s[M]+s[A]+"$";var F=a++;s[F]="^"+s[S]+"\\s*("+E+")$|^$";var z=a++;s[z]="^"+s[S]+"\\s*("+b+")$|^$";var q=a++;s[q]="(\\s*)"+s[S]+"\\s*("+E+"|"+s[w]+")",i[q]=new RegExp(s[q],"g");var B=a++;s[B]="^\\s*("+s[w]+")\\s+-\\s+("+s[w]+")\\s*$";var H=a++;s[H]="^\\s*("+s[A]+")\\s+-\\s+("+s[A]+")\\s*$";var G,V=a++;for(s[V]="(<|>)?=?\\s*\\*",G=0;G<35;G++)n(G,s[G]),i[G]||(i[G]=new RegExp(s[G]));function $(e,t){if((!t||"object"!=typeof t)&&(t={loose:!!t,includePrerelease:!1}),e instanceof K)return e;if("string"!=typeof e||e.length>r)return null;if(!(t.loose?i[T]:i[_]).test(e))return null;try{return new K(e,t)}catch{return null}}function K(e,t){if((!t||"object"!=typeof t)&&(t={loose:!!t,includePrerelease:!1}),e instanceof K){if(e.loose===t.loose)return e;e=e.version}else if("string"!=typeof e)throw new TypeError("Invalid Version: "+e);if(e.length>r)throw new TypeError("version is longer than "+r+" characters");if(!(this instanceof K))return new K(e,t);n("SemVer",e,t),this.options=t,this.loose=!!t.loose;var s=e.trim().match(t.loose?i[T]:i[_]);if(!s)throw new TypeError("Invalid Version: "+e);if(this.raw=e,this.major=+s[1],this.minor=+s[2],this.patch=+s[3],this.major>o||this.major<0)throw new TypeError("Invalid major version");if(this.minor>o||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>o||this.patch<0)throw new TypeError("Invalid patch version");s[4]?this.prerelease=s[4].split(".").map((function(e){if(/^[0-9]+$/.test(e)){var t=+e;if(t>=0&&t<o)return t}return e})):this.prerelease=[],this.build=s[5]?s[5].split("."):[],this.format()}e.parse=$,e.valid=function(e,t){var n=$(e,t);return n?n.version:null},e.clean=function(e,t){var n=$(e.trim().replace(/^[=v]+/,""),t);return n?n.version:null},e.SemVer=K,K.prototype.format=function(){return this.version=this.major+"."+this.minor+"."+this.patch,this.prerelease.length&&(this.version+="-"+this.prerelease.join(".")),this.version},K.prototype.toString=function(){return this.version},K.prototype.compare=function(e){return n("SemVer.compare",this.version,this.options,e),e instanceof K||(e=new K(e,this.options)),this.compareMain(e)||this.comparePre(e)},K.prototype.compareMain=function(e){return e instanceof K||(e=new K(e,this.options)),Q(this.major,e.major)||Q(this.minor,e.minor)||Q(this.patch,e.patch)},K.prototype.comparePre=function(e){if(e instanceof K||(e=new K(e,this.options)),this.prerelease.length&&!e.prerelease.length)return-1;if(!this.prerelease.length&&e.prerelease.length)return 1;if(!this.prerelease.length&&!e.prerelease.length)return 0;var t=0;do{var r=this.prerelease[t],o=e.prerelease[t];if(n("prerelease compare",t,r,o),void 0===r&&void 0===o)return 0;if(void 0===o)return 1;if(void 0===r)return-1;if(r!==o)return Q(r,o)}while(++t)},K.prototype.inc=function(e,t){switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",t);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",t);break;case"prepatch":this.prerelease.length=0,this.inc("patch",t),this.inc("pre",t);break;case"prerelease":0===this.prerelease.length&&this.inc("patch",t),this.inc("pre",t);break;case"major":(0!==this.minor||0!==this.patch||0===this.prerelease.length)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(0!==this.patch||0===this.prerelease.length)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":0===this.prerelease.length&&this.patch++,this.prerelease=[];break;case"pre":if(0===this.prerelease.length)this.prerelease=[0];else{for(var n=this.prerelease.length;--n>=0;)"number"==typeof this.prerelease[n]&&(this.prerelease[n]++,n=-2);-1===n&&this.prerelease.push(0)}t&&(this.prerelease[0]===t?isNaN(this.prerelease[1])&&(this.prerelease=[t,0]):this.prerelease=[t,0]);break;default:throw new Error("invalid increment argument: "+e)}return this.format(),this.raw=this.version,this},e.inc=function(e,t,n,r){"string"==typeof n&&(r=n,n=void 0);try{return new K(e,n).inc(t,r).version}catch{return null}},e.diff=function(e,t){if(Z(e,t))return null;var n=$(e),r=$(t),o="";if(n.prerelease.length||r.prerelease.length){o="pre";var i="prerelease"}for(var s in n)if(("major"===s||"minor"===s||"patch"===s)&&n[s]!==r[s])return o+s;return i},e.compareIdentifiers=Q;var W=/^[0-9]+$/;function Q(e,t){var n=W.test(e),r=W.test(t);return n&&r&&(e=+e,t=+t),e===t?0:n&&!r?-1:r&&!n?1:e<t?-1:1}function Y(e,t,n){return new K(e,n).compare(new K(t,n))}function X(e,t,n){return Y(e,t,n)>0}function J(e,t,n){return Y(e,t,n)<0}function Z(e,t,n){return 0===Y(e,t,n)}function ee(e,t,n){return 0!==Y(e,t,n)}function te(e,t,n){return Y(e,t,n)>=0}function ne(e,t,n){return Y(e,t,n)<=0}function re(e,t,n,r){switch(t){case"===":return"object"==typeof e&&(e=e.version),"object"==typeof n&&(n=n.version),e===n;case"!==":return"object"==typeof e&&(e=e.version),"object"==typeof n&&(n=n.version),e!==n;case"":case"=":case"==":return Z(e,n,r);case"!=":return ee(e,n,r);case">":return X(e,n,r);case">=":return te(e,n,r);case"<":return J(e,n,r);case"<=":return ne(e,n,r);default:throw new TypeError("Invalid operator: "+t)}}function oe(e,t){if((!t||"object"!=typeof t)&&(t={loose:!!t,includePrerelease:!1}),e instanceof oe){if(e.loose===!!t.loose)return e;e=e.value}if(!(this instanceof oe))return new oe(e,t);n("comparator",e,t),this.options=t,this.loose=!!t.loose,this.parse(e),this.semver===ie?this.value="":this.value=this.operator+this.semver.version,n("comp",this)}e.rcompareIdentifiers=function(e,t){return Q(t,e)},e.major=function(e,t){return new K(e,t).major},e.minor=function(e,t){return new K(e,t).minor},e.patch=function(e,t){return new K(e,t).patch},e.compare=Y,e.compareLoose=function(e,t){return Y(e,t,!0)},e.rcompare=function(e,t,n){return Y(t,e,n)},e.sort=function(t,n){return t.sort((function(t,r){return e.compare(t,r,n)}))},e.rsort=function(t,n){return t.sort((function(t,r){return e.rcompare(t,r,n)}))},e.gt=X,e.lt=J,e.eq=Z,e.neq=ee,e.gte=te,e.lte=ne,e.cmp=re,e.Comparator=oe;var ie={};function se(e,t){if((!t||"object"!=typeof t)&&(t={loose:!!t,includePrerelease:!1}),e instanceof se)return e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease?e:new se(e.raw,t);if(e instanceof oe)return new se(e.value,t);if(!(this instanceof se))return new se(e,t);if(this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease,this.raw=e,this.set=e.split(/\s*\|\|\s*/).map((function(e){return this.parseRange(e.trim())}),this).filter((function(e){return e.length})),!this.set.length)throw new TypeError("Invalid SemVer Range: "+e);this.format()}function ae(e){return!e||"x"===e.toLowerCase()||"*"===e}function ce(e,t,n,r,o,i,s,a,c,u,l,p,d){return((t=ae(n)?"":ae(r)?">="+n+".0.0":ae(o)?">="+n+"."+r+".0":">="+t)+" "+(a=ae(c)?"":ae(u)?"<"+(+c+1)+".0.0":ae(l)?"<"+c+"."+(+u+1)+".0":p?"<="+c+"."+u+"."+l+"-"+p:"<="+a)).trim()}function ue(e,t,r){for(var o=0;o<e.length;o++)if(!e[o].test(t))return!1;if(t.prerelease.length&&!r.includePrerelease){for(o=0;o<e.length;o++)if(n(e[o].semver),e[o].semver!==ie&&e[o].semver.prerelease.length>0){var i=e[o].semver;if(i.major===t.major&&i.minor===t.minor&&i.patch===t.patch)return!0}return!1}return!0}function le(e,t,n){try{t=new se(t,n)}catch{return!1}return t.test(e)}function pe(e,t,n,r){var o,i,s,a,c;switch(e=new K(e,r),t=new se(t,r),n){case">":o=X,i=ne,s=J,a=">",c=">=";break;case"<":o=J,i=te,s=X,a="<",c="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(le(e,t,r))return!1;for(var u=0;u<t.set.length;++u){var l=t.set[u],p=null,d=null;if(l.forEach((function(e){e.semver===ie&&(e=new oe(">=0.0.0")),p=p||e,d=d||e,o(e.semver,p.semver,r)?p=e:s(e.semver,d.semver,r)&&(d=e)})),p.operator===a||p.operator===c||(!d.operator||d.operator===a)&&i(e,d.semver))return!1;if(d.operator===c&&s(e,d.semver))return!1}return!0}oe.prototype.parse=function(e){var t=this.options.loose?i[F]:i[z],n=e.match(t);if(!n)throw new TypeError("Invalid comparator: "+e);this.operator=n[1],"="===this.operator&&(this.operator=""),n[2]?this.semver=new K(n[2],this.options.loose):this.semver=ie},oe.prototype.toString=function(){return this.value},oe.prototype.test=function(e){return n("Comparator.test",e,this.options.loose),this.semver===ie||("string"==typeof e&&(e=new K(e,this.options)),re(e,this.operator,this.semver,this.options))},oe.prototype.intersects=function(e,t){if(!(e instanceof oe))throw new TypeError("a Comparator is required");var n;if((!t||"object"!=typeof t)&&(t={loose:!!t,includePrerelease:!1}),""===this.operator)return n=new se(e.value,t),le(this.value,n,t);if(""===e.operator)return n=new se(this.value,t),le(e.semver,n,t);var r=!(">="!==this.operator&&">"!==this.operator||">="!==e.operator&&">"!==e.operator),o=!("<="!==this.operator&&"<"!==this.operator||"<="!==e.operator&&"<"!==e.operator),i=this.semver.version===e.semver.version,s=!(">="!==this.operator&&"<="!==this.operator||">="!==e.operator&&"<="!==e.operator),a=re(this.semver,"<",e.semver,t)&&(">="===this.operator||">"===this.operator)&&("<="===e.operator||"<"===e.operator),c=re(this.semver,">",e.semver,t)&&("<="===this.operator||"<"===this.operator)&&(">="===e.operator||">"===e.operator);return r||o||i&&s||a||c},e.Range=se,se.prototype.format=function(){return this.range=this.set.map((function(e){return e.join(" ").trim()})).join("||").trim(),this.range},se.prototype.toString=function(){return this.range},se.prototype.parseRange=function(e){var t=this.options.loose;e=e.trim();var r=t?i[H]:i[B];e=e.replace(r,ce),n("hyphen replace",e),e=e.replace(i[q],"$1$2$3"),n("comparator trim",e,i[q]),e=(e=(e=e.replace(i[N],"$1~")).replace(i[L],"$1^")).split(/\s+/).join(" ");var o=t?i[F]:i[z],s=e.split(" ").map((function(e){return function(e,t){return n("comp",e,t),e=function(e,t){return e.trim().split(/\s+/).map((function(e){return function(e,t){n("caret",e,t);var r=t.loose?i[U]:i[j];return e.replace(r,(function(t,r,o,i,s){var a;return n("caret",e,t,r,o,i,s),ae(r)?a="":ae(o)?a=">="+r+".0.0 <"+(+r+1)+".0.0":ae(i)?a="0"===r?">="+r+"."+o+".0 <"+r+"."+(+o+1)+".0":">="+r+"."+o+".0 <"+(+r+1)+".0.0":s?(n("replaceCaret pr",s),a="0"===r?"0"===o?">="+r+"."+o+"."+i+"-"+s+" <"+r+"."+o+"."+(+i+1):">="+r+"."+o+"."+i+"-"+s+" <"+r+"."+(+o+1)+".0":">="+r+"."+o+"."+i+"-"+s+" <"+(+r+1)+".0.0"):(n("no pr"),a="0"===r?"0"===o?">="+r+"."+o+"."+i+" <"+r+"."+o+"."+(+i+1):">="+r+"."+o+"."+i+" <"+r+"."+(+o+1)+".0":">="+r+"."+o+"."+i+" <"+(+r+1)+".0.0"),n("caret return",a),a}))}(e,t)})).join(" ")}(e,t),n("caret",e),e=function(e,t){return e.trim().split(/\s+/).map((function(e){return function(e,t){var r=t.loose?i[D]:i[k];return e.replace(r,(function(t,r,o,i,s){var a;return n("tilde",e,t,r,o,i,s),ae(r)?a="":ae(o)?a=">="+r+".0.0 <"+(+r+1)+".0.0":ae(i)?a=">="+r+"."+o+".0 <"+r+"."+(+o+1)+".0":s?(n("replaceTilde pr",s),a=">="+r+"."+o+"."+i+"-"+s+" <"+r+"."+(+o+1)+".0"):a=">="+r+"."+o+"."+i+" <"+r+"."+(+o+1)+".0",n("tilde return",a),a}))}(e,t)})).join(" ")}(e,t),n("tildes",e),e=function(e,t){return n("replaceXRanges",e,t),e.split(/\s+/).map((function(e){return function(e,t){e=e.trim();var r=t.loose?i[R]:i[I];return e.replace(r,(function(t,r,o,i,s,a){n("xRange",e,t,r,o,i,s,a);var c=ae(o),u=c||ae(i),l=u||ae(s);return"="===r&&l&&(r=""),c?t=">"===r||"<"===r?"<0.0.0":"*":r&&l?(u&&(i=0),s=0,">"===r?(r=">=",u?(o=+o+1,i=0,s=0):(i=+i+1,s=0)):"<="===r&&(r="<",u?o=+o+1:i=+i+1),t=r+o+"."+i+"."+s):u?t=">="+o+".0.0 <"+(+o+1)+".0.0":l&&(t=">="+o+"."+i+".0 <"+o+"."+(+i+1)+".0"),n("xRange return",t),t}))}(e,t)})).join(" ")}(e,t),n("xrange",e),e=function(e,t){return n("replaceStars",e,t),e.trim().replace(i[V],"")}(e,t),n("stars",e),e}(e,this.options)}),this).join(" ").split(/\s+/);return this.options.loose&&(s=s.filter((function(e){return!!e.match(o)}))),s.map((function(e){return new oe(e,this.options)}),this)},se.prototype.intersects=function(e,t){if(!(e instanceof se))throw new TypeError("a Range is required");return this.set.some((function(n){return n.every((function(n){return e.set.some((function(e){return e.every((function(e){return n.intersects(e,t)}))}))}))}))},e.toComparators=function(e,t){return new se(e,t).set.map((function(e){return e.map((function(e){return e.value})).join(" ").trim().split(" ")}))},se.prototype.test=function(e){if(!e)return!1;"string"==typeof e&&(e=new K(e,this.options));for(var t=0;t<this.set.length;t++)if(ue(this.set[t],e,this.options))return!0;return!1},e.satisfies=le,e.maxSatisfying=function(e,t,n){var r=null,o=null;try{var i=new se(t,n)}catch{return null}return e.forEach((function(e){i.test(e)&&(!r||-1===o.compare(e))&&(o=new K(r=e,n))})),r},e.minSatisfying=function(e,t,n){var r=null,o=null;try{var i=new se(t,n)}catch{return null}return e.forEach((function(e){i.test(e)&&(!r||1===o.compare(e))&&(o=new K(r=e,n))})),r},e.minVersion=function(e,t){e=new se(e,t);var n=new K("0.0.0");if(e.test(n)||(n=new K("0.0.0-0"),e.test(n)))return n;n=null;for(var r=0;r<e.set.length;++r)e.set[r].forEach((function(e){var t=new K(e.semver.version);switch(e.operator){case">":0===t.prerelease.length?t.patch++:t.prerelease.push(0),t.raw=t.format();case"":case">=":(!n||X(n,t))&&(n=t);break;case"<":case"<=":break;default:throw new Error("Unexpected operation: "+e.operator)}}));return n&&e.test(n)?n:null},e.validRange=function(e,t){try{return new se(e,t).range||"*"}catch{return null}},e.ltr=function(e,t,n){return pe(e,t,"<",n)},e.gtr=function(e,t,n){return pe(e,t,">",n)},e.outside=pe,e.prerelease=function(e,t){var n=$(e,t);return n&&n.prerelease.length?n.prerelease:null},e.intersects=function(e,t,n){return e=new se(e,n),t=new se(t,n),e.intersects(t)},e.coerce=function(e){if(e instanceof K)return e;if("string"!=typeof e)return null;var t=e.match(i[P]);return null==t?null:$(t[1]+"."+(t[2]||"0")+"."+(t[3]||"0"))}})),sr=b(((e,t)=>{"use strict";function n(e){return"function"==typeof e}var r=console.error.bind(console);function o(e,t,n){var r=!!e[t]&&e.propertyIsEnumerable(t);Object.defineProperty(e,t,{configurable:!0,enumerable:r,writable:!0,value:n})}function i(e){e&&e.logger&&(n(e.logger)?r=e.logger:r("new logger isn't a function, not replacing"))}function s(e,t,i){if(e&&e[t]){if(!i)return r("no wrapper function"),void r((new Error).stack);if(n(e[t])&&n(i)){var s=e[t],a=i(s,t);return o(a,"__original",s),o(a,"__unwrap",(function(){e[t]===a&&o(e,t,s)})),o(a,"__wrapped",!0),o(e,t,a),a}r("original object and wrapper must be functions")}else r("no original function "+t+" to wrap")}function a(e,t){return e&&e[t]?e[t].__unwrap?e[t].__unwrap():void r("no original to unwrap to -- has "+t+" already been unwrapped?"):(r("no function to unwrap."),void r((new Error).stack))}i.wrap=s,i.massWrap=function(e,t,n){if(!e)return r("must provide one or more modules to patch"),void r((new Error).stack);Array.isArray(e)||(e=[e]),t&&Array.isArray(t)?e.forEach((function(e){t.forEach((function(t){s(e,t,n)}))})):r("must provide one or more functions to wrap on modules")},i.unwrap=a,i.massUnwrap=function(e,t){if(!e)return r("must provide one or more modules to patch"),void r((new Error).stack);Array.isArray(e)||(e=[e]),t&&Array.isArray(t)?e.forEach((function(e){t.forEach((function(t){a(e,t)}))})):r("must provide one or more functions to unwrap on modules")},t.exports=i})),ar=b(((e,t)=>{"use strict";var n=sr(),r=n.wrap,o=n.unwrap,i="wrap@before";function s(e,t,n){var r=!!e[t]&&e.propertyIsEnumerable(t);Object.defineProperty(e,t,{configurable:!0,enumerable:r,writable:!0,value:n})}function a(e,t){var n;return n=e._events&&e._events[t],Array.isArray(n)||(n=n?[n]:[]),n}function c(e,t){if(e){var n=e;if("function"==typeof e)n=t(e);else if(Array.isArray(e)){n=[];for(var r=0;r<e.length;r++)n[r]=t(e[r])}return n}}t.exports=function(e,t,n){if(!(e&&e.on&&e.addListener&&e.removeListener&&e.emit))throw new Error("can only wrap real EEs");if(!t)throw new Error("must have function to run on listener addition");if(!n)throw new Error("must have function to wrap listeners when emitting");function u(e){return function(t,n){var o=a(this,t).slice();try{var s=e.call(this,t,n);return function(e,t,n){var r=a(e,t).filter((function(e){return-1===n.indexOf(e)}));r.length>0&&function(e,t){for(var n=t.length,r=0;r<n;r++){var o=t[r],s=e[i];if("function"==typeof s)s(o);else if(Array.isArray(s))for(var a=s.length,c=0;c<a;c++)s[c](o)}}(e,r)}(this,t,o),s}finally{this.on.__wrapped||r(this,"on",u),this.addListener.__wrapped||r(this,"addListener",u)}}}e[i]?"function"==typeof e[i]?s(e,i,[e[i],t]):Array.isArray(e[i])&&e[i].push(t):s(e,i,t),e.__wrapped||(r(e,"addListener",u),r(e,"on",u),r(e,"emit",(function(e){return function(t){if(!this._events||!this._events[t])return e.apply(this,arguments);var i=this._events[t];r(this,"removeListener",(function(e){return function(){this._events[t]=i;try{return e.apply(this,arguments)}finally{i=this._events[t],this._events[t]=c(i,n)}}}));try{return this._events[t]=c(i,n),e.apply(this,arguments)}finally{o(this,"removeListener"),this._events[t]=i}}})),s(e,"__unwrap",(function(){o(e,"addListener"),o(e,"on"),o(e,"emit"),delete e[i],delete e.__wrapped})),s(e,"__wrapped",!0))}})),cr=b(((e,t)=>{"use strict";var r=n(9023),o=n(2613),i=ar(),s=n(290),a="cls@contexts",c="error@context",u=process.env.DEBUG_CLS_HOOKED,l=-1;function p(e){this.name=e,this.active=null,this._set=[],this.id=null,this._contexts=new Map,this._indent=0}function d(e){return process.namespaces[e]}function h(e){let t=d(e);o.ok(t,"can't delete nonexistent namespace! \""+e+'"'),o.ok(t.id,"don't assign to process.namespaces directly! "+r.inspect(t)),process.namespaces[e]=null}function f(...e){u&&process._rawDebug(`${r.format(...e)}`)}t.exports={getNamespace:d,createNamespace:function(e){o.ok(e,"namespace must be given a name."),u&&f(`NS-CREATING NAMESPACE (${e})`);let t=new p(e);return t.id=l,s.createHook({init(n,o,i,a){if(l=s.executionAsyncId(),t.active)t._contexts.set(n,t.active),u&&f(`${" ".repeat(t._indent<0?0:t._indent)}INIT [${o}] (${e}) asyncId:${n} currentUid:${l} triggerId:${i} active:${r.inspect(t.active,{showHidden:!0,depth:2,colors:!0})} resource:${a}`);else if(0===l){let i=s.triggerAsyncId(),c=t._contexts.get(i);c?(t._contexts.set(n,c),u&&f(`${" ".repeat(t._indent<0?0:t._indent)}INIT USING CONTEXT FROM TRIGGERID [${o}] (${e}) asyncId:${n} currentUid:${l} triggerId:${i} active:${r.inspect(t.active,{showHidden:!0,depth:2,colors:!0})} resource:${a}`)):u&&f(`${" ".repeat(t._indent<0?0:t._indent)}INIT MISSING CONTEXT [${o}] (${e}) asyncId:${n} currentUid:${l} triggerId:${i} active:${r.inspect(t.active,{showHidden:!0,depth:2,colors:!0})} resource:${a}`)}if(u&&"PROMISE"===o){f(r.inspect(a,{showHidden:!0}));let s=a.parentId;f(`${" ".repeat(t._indent<0?0:t._indent)}INIT RESOURCE-PROMISE [${o}] (${e}) parentId:${s} asyncId:${n} currentUid:${l} triggerId:${i} active:${r.inspect(t.active,{showHidden:!0,depth:2,colors:!0})} resource:${a}`)}},before(n){let o;if(l=s.executionAsyncId(),o=t._contexts.get(n)||t._contexts.get(l),o){if(u){let i=s.triggerAsyncId();f(`${" ".repeat(t._indent<0?0:t._indent)}BEFORE (${e}) asyncId:${n} currentUid:${l} triggerId:${i} active:${r.inspect(t.active,{showHidden:!0,depth:2,colors:!0})} context:${r.inspect(o)}`),t._indent+=2}t.enter(o)}else if(u){let o=s.triggerAsyncId();f(`${" ".repeat(t._indent<0?0:t._indent)}BEFORE MISSING CONTEXT (${e}) asyncId:${n} currentUid:${l} triggerId:${o} active:${r.inspect(t.active,{showHidden:!0,depth:2,colors:!0})} namespace._contexts:${r.inspect(t._contexts,{showHidden:!0,depth:2,colors:!0})}`),t._indent+=2}},after(n){let o;if(l=s.executionAsyncId(),o=t._contexts.get(n)||t._contexts.get(l),o){if(u){let i=s.triggerAsyncId();t._indent-=2,f(`${" ".repeat(t._indent<0?0:t._indent)}AFTER (${e}) asyncId:${n} currentUid:${l} triggerId:${i} active:${r.inspect(t.active,{showHidden:!0,depth:2,colors:!0})} context:${r.inspect(o)}`)}t.exit(o)}else if(u){let i=s.triggerAsyncId();t._indent-=2,f(`${" ".repeat(t._indent<0?0:t._indent)}AFTER MISSING CONTEXT (${e}) asyncId:${n} currentUid:${l} triggerId:${i} active:${r.inspect(t.active,{showHidden:!0,depth:2,colors:!0})} context:${r.inspect(o)}`)}},destroy(n){if(l=s.executionAsyncId(),u){let o=s.triggerAsyncId();f(`${" ".repeat(t._indent<0?0:t._indent)}DESTROY (${e}) currentUid:${l} asyncId:${n} triggerId:${o} active:${r.inspect(t.active,{showHidden:!0,depth:2,colors:!0})} context:${r.inspect(t._contexts.get(l))}`)}t._contexts.delete(n)}}).enable(),process.namespaces[e]=t,t},destroyNamespace:h,reset:function(){process.namespaces&&Object.keys(process.namespaces).forEach((function(e){h(e)})),process.namespaces=Object.create(null)},ERROR_SYMBOL:c},p.prototype.set=function(e,t){if(!this.active)throw new Error("No context available. ns.run() or ns.bind() must be called first.");return this.active[e]=t,u&&f(" ".repeat(this._indent<0?0:this._indent)+"CONTEXT-SET KEY:"+e+"="+t+" in ns:"+this.name+" currentUid:"+l+" active:"+r.inspect(this.active,{showHidden:!0,depth:2,colors:!0})),t},p.prototype.get=function(e){if(this.active){if(u){let t=s.executionAsyncId(),n=s.triggerAsyncId(),o=" ".repeat(this._indent<0?0:this._indent);f(o+"CONTEXT-GETTING KEY:"+e+"="+this.active[e]+" ("+this.name+") currentUid:"+l+" active:"+r.inspect(this.active,{showHidden:!0,depth:2,colors:!0})),f(`${o}CONTEXT-GETTING KEY: (${this.name}) ${e}=${this.active[e]} currentUid:${l} asyncHooksCurrentId:${t} triggerId:${n} len:${this._set.length} active:${r.inspect(this.active)}`)}return this.active[e]}if(u){let t=s.currentId(),n=s.triggerAsyncId();f(`${" ".repeat(this._indent<0?0:this._indent)}CONTEXT-GETTING KEY NO ACTIVE NS: (${this.name}) ${e}=undefined currentUid:${l} asyncHooksCurrentId:${t} triggerId:${n} len:${this._set.length}`)}},p.prototype.createContext=function(){let e=Object.create(this.active?this.active:Object.prototype);if(e._ns_name=this.name,e.id=l,u){let t=s.executionAsyncId(),n=s.triggerAsyncId();f(`${" ".repeat(this._indent<0?0:this._indent)}CONTEXT-CREATED Context: (${this.name}) currentUid:${l} asyncHooksCurrentId:${t} triggerId:${n} len:${this._set.length} context:${r.inspect(e,{showHidden:!0,depth:2,colors:!0})}`)}return e},p.prototype.run=function(e){let t=this.createContext();this.enter(t);try{if(u){let e=s.triggerAsyncId(),n=s.executionAsyncId();f(`${" ".repeat(this._indent<0?0:this._indent)}CONTEXT-RUN BEGIN: (${this.name}) currentUid:${l} triggerId:${e} asyncHooksCurrentId:${n} len:${this._set.length} context:${r.inspect(t)}`)}return e(t),t}catch(e){throw e&&(e[c]=t),e}finally{if(u){let e=s.triggerAsyncId(),n=s.executionAsyncId();f(`${" ".repeat(this._indent<0?0:this._indent)}CONTEXT-RUN END: (${this.name}) currentUid:${l} triggerId:${e} asyncHooksCurrentId:${n} len:${this._set.length} ${r.inspect(t)}`)}this.exit(t)}},p.prototype.runAndReturn=function(e){let t;return this.run((function(n){t=e(n)})),t},p.prototype.runPromise=function(e){let t=this.createContext();this.enter(t);let n=e(t);if(!n||!n.then||!n.catch)throw new Error("fn must return a promise.");return u&&f("CONTEXT-runPromise BEFORE: ("+this.name+") currentUid:"+l+" len:"+this._set.length+" "+r.inspect(t)),n.then((e=>(u&&f("CONTEXT-runPromise AFTER then: ("+this.name+") currentUid:"+l+" len:"+this._set.length+" "+r.inspect(t)),this.exit(t),e))).catch((e=>{throw e[c]=t,u&&f("CONTEXT-runPromise AFTER catch: ("+this.name+") currentUid:"+l+" len:"+this._set.length+" "+r.inspect(t)),this.exit(t),e}))},p.prototype.bind=function(e,t){t||(t=this.active?this.active:this.createContext());let n=this;return function(){n.enter(t);try{return e.apply(this,arguments)}catch(e){throw e&&(e[c]=t),e}finally{n.exit(t)}}},p.prototype.enter=function(e){if(o.ok(e,"context must be provided for entering"),u){let t=s.executionAsyncId(),n=s.triggerAsyncId();f(`${" ".repeat(this._indent<0?0:this._indent)}CONTEXT-ENTER: (${this.name}) currentUid:${l} triggerId:${n} asyncHooksCurrentId:${t} len:${this._set.length} ${r.inspect(e)}`)}this._set.push(this.active),this.active=e},p.prototype.exit=function(e){if(o.ok(e,"context must be provided for exiting"),u){let t=s.executionAsyncId(),n=s.triggerAsyncId();f(`${" ".repeat(this._indent<0?0:this._indent)}CONTEXT-EXIT: (${this.name}) currentUid:${l} triggerId:${n} asyncHooksCurrentId:${t} len:${this._set.length} ${r.inspect(e)}`)}if(this.active===e)return o.ok(this._set.length,"can't remove top context"),void(this.active=this._set.pop());let t=this._set.lastIndexOf(e);t<0?(u&&f("??ERROR?? context exiting but not entered - ignoring: "+r.inspect(e)),o.ok(t>=0,"context not currently entered; can't exit. \n"+r.inspect(this)+"\n"+r.inspect(e))):(o.ok(t,"can't remove top context"),this._set.splice(t,1))},p.prototype.bindEmitter=function(e){o.ok(e.on&&e.addListener&&e.emit,"can only bind real EEs");let t=this,n="context@"+this.name;i(e,(function(e){!e||(e[a]||(e[a]=Object.create(null)),e[a][n]={namespace:t,context:t.active})}),(function(e){if(!e||!e[a])return e;let t=e,n=e[a];return Object.keys(n).forEach((function(e){let r=n[e];t=r.namespace.bind(t,r.context)})),t}))},p.prototype.fromException=function(e){return e[c]},process.namespaces={}})),ur=b(((e,t)=>{"use strict";function n(){}t.exports=function(){let e=this._hooks,t=this._state,r=process.nextTick;process.nextTick=function(){if(!t.enabled)return r.apply(process,arguments);let o=new Array(arguments.length);for(let e=0;e<arguments.length;e++)o[e]=arguments[e];let i=o[0];if("function"!=typeof i)throw new TypeError("callback is not a function");let s=new n,a=--t.counter;return e.init.call(s,a,0,null,null),o[0]=function(){e.pre.call(s,a);let t=!0;try{i.apply(this,arguments),t=!1}finally{t&&process.listenerCount("uncaughtException")>0&&process.once("uncaughtException",(function(){e.post.call(s,a,!0),e.destroy.call(null,a)}))}e.post.call(s,a,!1),e.destroy.call(null,a)},r.apply(process,o)}}})),lr=b(((e,t)=>{"use strict";function n(){}t.exports=function(){let e=this._hooks,t=this._state,r=global.Promise,o=r.prototype.then;function i(t,n,r,o){return"function"!=typeof t?o?function(t){return function(n){return e.destroy.call(null,t),n}}(r):function(t){return function(n){throw e.destroy.call(null,t),n}}(r):function(){e.pre.call(n,r);try{return t.apply(this,arguments)}finally{e.post.call(n,r,!1),e.destroy.call(null,r)}}}r.prototype.then=function(r,s){if(!t.enabled)return o.call(this,r,s);let a=new n,c=--t.counter;return e.init.call(a,c,0,null,null),o.call(this,i(r,a,c,!0),i(s,a,c,!1))}}})),pr=b(((e,t)=>{"use strict";var r=n(3557);function o(){}function i(){}function s(){}var a=new Map,c=new Map,u=new Map,l=null,p=!1;function d(e,t,n,o,i,s,a){let c=r[n],u=r[o];r[n]=function(){if(!t.enabled)return c.apply(r,arguments);let n=new Array(arguments.length);for(let e=0;e<arguments.length;e++)n[e]=arguments[e];let o=n[0];if("function"!=typeof o)throw new TypeError('"callback" argument must be a function');let u,d=new i,h=--t.counter;return e.init.call(d,h,0,null,null),n[0]=function(){l=u,e.pre.call(d,h);let t=!0;try{o.apply(this,arguments),t=!1}finally{t&&process.listenerCount("uncaughtException")>0&&process.once("uncaughtException",(function(){e.post.call(d,h,!0),s.delete(u),e.destroy.call(null,h)}))}e.post.call(d,h,!1),l=null,(a||p)&&(p=!1,s.delete(u),e.destroy.call(null,h))},u=c.apply(r,n),s.set(u,h),u},r[o]=function(t){if(l===t&&null!==t)p=!0;else if(s.has(t)){let n=s.get(t);s.delete(t),e.destroy.call(null,n)}u.apply(r,arguments)}}t.exports=function(){d(this._hooks,this._state,"setTimeout","clearTimeout",o,a,!0),d(this._hooks,this._state,"setInterval","clearInterval",i,c,!1),d(this._hooks,this._state,"setImmediate","clearImmediate",s,u,!0),global.setTimeout=r.setTimeout,global.setInterval=r.setInterval,global.setImmediate=r.setImmediate,global.clearTimeout=r.clearTimeout,global.clearInterval=r.clearInterval,global.clearImmediate=r.clearImmediate}})),dr=b(((e,t)=>{t.exports={name:"async-hook-jl",description:"Inspect the life of handle objects in node",version:"1.7.6",author:"Andreas Madsen <amwebdk@gmail.com>",main:"./index.js",scripts:{test:"node ./test/runner.js && eslint ."},repository:{type:"git",url:"git://github.com/jeff-lewis/async-hook-jl.git"},keywords:["async","async hooks","inspect","async wrap"],license:"MIT",dependencies:{"stack-chain":"^1.3.7"},devDependencies:{async:"1.5.x","cli-color":"1.1.x",eslint:"^3.4.0",endpoint:"0.4.x"},engines:{node:"^4.7 || >=6.9 || >=7.3"}}})),hr=b(((e,t)=>{"use strict";var n=process.binding("async_wrap"),r=n.Providers.TIMERWRAP,o={nextTick:ur(),promise:lr(),timers:pr()},i=new Set;function s(){this.enabled=!1,this.counter=0}function a(){let e=this.initFns=[],t=this.preFns=[],n=this.postFns=[],o=this.destroyFns=[];this.init=function(t,n,o,s){if(n!==r)for(let r of e)r(t,this,n,o,s);else i.add(t)},this.pre=function(e){if(!i.has(e))for(let n of t)n(e,this)},this.post=function(e,t){if(!i.has(e))for(let r of n)r(e,this,t)},this.destroy=function(e){if(i.has(e))i.delete(e);else for(let t of o)t(e)}}function c(e,t){let n=e.indexOf(t);-1!==n&&e.splice(n,1)}function u(){this._state=new s,this._hooks=new a,this.version=dr().version,this.providers=n.Providers;for(let e of Object.keys(o))o[e].call(this);process.env.hasOwnProperty("NODE_ASYNC_HOOK_WARNING")&&console.warn("warning: you are using async-hook-jl which is unstable."),n.setupHooks({init:this._hooks.init,pre:this._hooks.pre,post:this._hooks.post,destroy:this._hooks.destroy})}a.prototype.add=function(e){e.init&&this.initFns.push(e.init),e.pre&&this.preFns.push(e.pre),e.post&&this.postFns.push(e.post),e.destroy&&this.destroyFns.push(e.destroy)},a.prototype.remove=function(e){e.init&&c(this.initFns,e.init),e.pre&&c(this.preFns,e.pre),e.post&&c(this.postFns,e.post),e.destroy&&c(this.destroyFns,e.destroy)},t.exports=u,u.prototype.addHooks=function(e){this._hooks.add(e)},u.prototype.removeHooks=function(e){this._hooks.remove(e)},u.prototype.enable=function(){this._state.enabled=!0,n.enable()},u.prototype.disable=function(){this._state.enabled=!1,n.disable()}})),fr=b(((e,t)=>{t.exports={name:"stack-chain",description:"API for combining call site modifiers",version:"1.3.7",author:"Andreas Madsen <amwebdk@gmail.com>",scripts:{test:"tap ./test/simple"},repository:{type:"git",url:"git://github.com/AndreasMadsen/stack-chain.git"},keywords:["stack","chain","trace","call site","concat","format"],devDependencies:{tap:"2.x.x","uglify-js":"2.5.x"},license:"MIT"}})),mr=b(((e,t)=>{t.exports=function(e,t){var n=[];n.push(function(e){try{return Error.prototype.toString.call(e)}catch(e){try{return"<error: "+e+">"}catch{return"<error>"}}}(e));for(var r=0;r<t.length;r++){var o,i=t[r];try{o=i.toString()}catch(e){try{o="<error: "+e+">"}catch{o="<error>"}}n.push("    at "+o)}return n.join("\n")}})),vr=b(((e,t)=>{var n=mr();function r(){this.extend=new s,this.filter=new s,this.format=new a,this.version=fr().version}var o=!1;r.prototype.callSite=function e(t){t||(t={}),o=!0;var n={};Error.captureStackTrace(n,e);var r=n.stack;return o=!1,r=r.slice(t.slice||0),t.extend&&(r=this.extend._modify(n,r)),t.filter&&(r=this.filter._modify(n,r)),r};var i=new r;function s(){this._modifiers=[]}function a(){this._formater=n,this._previous=void 0}s.prototype._modify=function(e,t){for(var n=0,r=this._modifiers.length;n<r;n++)t=this._modifiers[n](e,t);return t},s.prototype.attach=function(e){this._modifiers.push(e)},s.prototype.deattach=function(e){var t=this._modifiers.indexOf(e);return-1!==t&&(this._modifiers.splice(t,1),!0)},a.prototype.replace=function(e){e?this._formater=e:this.restore()},a.prototype.restore=function(){this._formater=n,this._previous=void 0},a.prototype._backup=function(){this._previous=this._formater},a.prototype._roolback=function(){this._previous===n?this.replace(void 0):this.replace(this._previous),this._previous=void 0},Error.prepareStackTrace&&i.format.replace(Error.prepareStackTrace);var c=!1;function u(e,t){if(o)return t;if(c)return n(e,t);var r=t.concat();r=i.extend._modify(e,r),r=(r=i.filter._modify(e,r)).slice(0,Error.stackTraceLimit),Object.isExtensible(e)&&void 0===Object.getOwnPropertyDescriptor(e,"callSite")&&(e.callSite={original:t,mutated:r}),c=!0;var s=i.format._formater(e,r);return c=!1,s}Object.defineProperty(Error,"prepareStackTrace",{get:function(){return u},set:function(e){e===u?i.format._roolback():(i.format._backup(),i.format.replace(e))}}),Object.defineProperty(Error.prototype,"callSite",{get:function(){return this.stack,this.callSite},set:function(e){Object.defineProperty(this,"callSite",{value:e,writable:!0,configurable:!0})},configurable:!0}),t.exports=i})),gr=b(((e,t)=>{if(global._stackChain){if(global._stackChain.version!==fr().version)throw new Error("Conflicting version of stack-chain found");t.exports=global._stackChain}else t.exports=global._stackChain=vr()})),yr=b(((e,t)=>{"use strict";var n=hr();if(global._asyncHook){if(global._asyncHook.version!==dr().version)throw new Error("Conflicting version of async-hook-jl found");t.exports=global._asyncHook}else gr().filter.attach((function(e,t){return t.filter((function(e){let t=e.getFileName();return!(t&&t.slice(0,__dirname.length)===__dirname)}))})),t.exports=global._asyncHook=new n})),_r=b(((e,t)=>{"use strict";var r=n(9023),o=n(2613),i=ar(),s=yr(),a="cls@contexts",c="error@context",u=[];for(let e in s.providers)u[s.providers[e]]=e;var l,p,d=process.env.DEBUG_CLS_HOOKED,h=-1;function f(e){this.name=e,this.active=null,this._set=[],this.id=null,this._contexts=new Map}function m(e){return process.namespaces[e]}function v(e){let t=m(e);o.ok(t,"can't delete nonexistent namespace! \""+e+'"'),o.ok(t.id,"don't assign to process.namespaces directly! "+r.inspect(t)),process.namespaces[e]=null}function g(e){process.env.DEBUG&&process._rawDebug(e)}function y(e){return e?"function"==typeof e?e.name?e.name:(e.toString().trim().match(/^function\s*([^\s(]+)/)||[])[1]:e.constructor&&e.constructor.name?e.constructor.name:void 0:e}if(t.exports={getNamespace:m,createNamespace:function(e){o.ok(e,"namespace must be given a name."),d&&g("CREATING NAMESPACE "+e);let t=new f(e);return t.id=h,s.addHooks({init(n,o,i,s,a){h=n,s?(t._contexts.set(n,t._contexts.get(s)),d&&g("PARENTID: "+e+" uid:"+n+" parent:"+s+" provider:"+i)):t._contexts.set(h,t.active),d&&g("INIT "+e+" uid:"+n+" parent:"+s+" provider:"+u[i]+" active:"+r.inspect(t.active,!0))},pre(n,o){h=n;let i=t._contexts.get(n);i?(d&&g(" PRE "+e+" uid:"+n+" handle:"+y(o)+" context:"+r.inspect(i)),t.enter(i)):d&&g(" PRE MISSING CONTEXT "+e+" uid:"+n+" handle:"+y(o))},post(n,o){h=n;let i=t._contexts.get(n);i?(d&&g(" POST "+e+" uid:"+n+" handle:"+y(o)+" context:"+r.inspect(i)),t.exit(i)):d&&g(" POST MISSING CONTEXT "+e+" uid:"+n+" handle:"+y(o))},destroy(n){h=n,d&&g("DESTROY "+e+" uid:"+n+" context:"+r.inspect(t._contexts.get(h))+" active:"+r.inspect(t.active,!0)),t._contexts.delete(n)}}),process.namespaces[e]=t,t},destroyNamespace:v,reset:function(){process.namespaces&&Object.keys(process.namespaces).forEach((function(e){v(e)})),process.namespaces=Object.create(null)},ERROR_SYMBOL:c},f.prototype.set=function(e,t){if(!this.active)throw new Error("No context available. ns.run() or ns.bind() must be called first.");return d&&g("    SETTING KEY:"+e+"="+t+" in ns:"+this.name+" uid:"+h+" active:"+r.inspect(this.active,!0)),this.active[e]=t,t},f.prototype.get=function(e){if(this.active)return d&&g("    GETTING KEY:"+e+"="+this.active[e]+" "+this.name+" uid:"+h+" active:"+r.inspect(this.active,!0)),this.active[e];d&&g("    GETTING KEY:"+e+"=undefined "+this.name+" uid:"+h+" active:"+r.inspect(this.active,!0))},f.prototype.createContext=function(){d&&g("   CREATING Context: "+this.name+" uid:"+h+" len:"+this._set.length+"  active:"+r.inspect(this.active,!0,2,!0));let e=Object.create(this.active?this.active:Object.prototype);return e._ns_name=this.name,e.id=h,d&&g("   CREATED Context: "+this.name+" uid:"+h+" len:"+this._set.length+"  context:"+r.inspect(e,!0,2,!0)),e},f.prototype.run=function(e){let t=this.createContext();this.enter(t);try{return d&&g(" BEFORE RUN: "+this.name+" uid:"+h+" len:"+this._set.length+" "+r.inspect(t)),e(t),t}catch(e){throw e&&(e[c]=t),e}finally{d&&g(" AFTER RUN: "+this.name+" uid:"+h+" len:"+this._set.length+" "+r.inspect(t)),this.exit(t)}},f.prototype.runAndReturn=function(e){var t;return this.run((function(n){t=e(n)})),t},f.prototype.runPromise=function(e){let t=this.createContext();this.enter(t);let n=e(t);if(!n||!n.then||!n.catch)throw new Error("fn must return a promise.");return d&&g(" BEFORE runPromise: "+this.name+" uid:"+h+" len:"+this._set.length+" "+r.inspect(t)),n.then((e=>(d&&g(" AFTER runPromise: "+this.name+" uid:"+h+" len:"+this._set.length+" "+r.inspect(t)),this.exit(t),e))).catch((e=>{throw e[c]=t,d&&g(" AFTER runPromise: "+this.name+" uid:"+h+" len:"+this._set.length+" "+r.inspect(t)),this.exit(t),e}))},f.prototype.bind=function(e,t){t||(t=this.active?this.active:this.createContext());let n=this;return function(){n.enter(t);try{return e.apply(this,arguments)}catch(e){throw e&&(e[c]=t),e}finally{n.exit(t)}}},f.prototype.enter=function(e){o.ok(e,"context must be provided for entering"),d&&g("  ENTER "+this.name+" uid:"+h+" len:"+this._set.length+" context: "+r.inspect(e)),this._set.push(this.active),this.active=e},f.prototype.exit=function(e){if(o.ok(e,"context must be provided for exiting"),d&&g("  EXIT "+this.name+" uid:"+h+" len:"+this._set.length+" context: "+r.inspect(e)),this.active===e)return o.ok(this._set.length,"can't remove top context"),void(this.active=this._set.pop());let t=this._set.lastIndexOf(e);t<0?(d&&g("??ERROR?? context exiting but not entered - ignoring: "+r.inspect(e)),o.ok(t>=0,"context not currently entered; can't exit. \n"+r.inspect(this)+"\n"+r.inspect(e))):(o.ok(t,"can't remove top context"),this._set.splice(t,1))},f.prototype.bindEmitter=function(e){o.ok(e.on&&e.addListener&&e.emit,"can only bind real EEs");let t=this,n="context@"+this.name;i(e,(function(e){!e||(e[a]||(e[a]=Object.create(null)),e[a][n]={namespace:t,context:t.active})}),(function(e){if(!e||!e[a])return e;let t=e,n=e[a];return Object.keys(n).forEach((function(e){let r=n[e];t=r.namespace.bind(t,r.context)})),t}))},f.prototype.fromException=function(e){return e[c]},process.namespaces={},s._state&&!s._state.enabled&&s.enable(),d)for(p in(l=gr()).filter._modifiers)l.filter.deattach(p)})),br=b(((e,t)=>{"use strict";var n=ir();process&&n.gte(process.versions.node,"8.0.0")?t.exports=cr():t.exports=_r()})),Er=b(((e,t)=>{var n;e=t.exports=K,n="object"==typeof process&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?function(){var e=Array.prototype.slice.call(arguments,0);e.unshift("SEMVER"),console.log.apply(console,e)}:function(){},e.SEMVER_SPEC_VERSION="2.0.0";var r=256,o=Number.MAX_SAFE_INTEGER||9007199254740991,i=e.re=[],s=e.src=[],a=0,c=a++;s[c]="0|[1-9]\\d*";var u=a++;s[u]="[0-9]+";var l=a++;s[l]="\\d*[a-zA-Z-][a-zA-Z0-9-]*";var p=a++;s[p]="("+s[c]+")\\.("+s[c]+")\\.("+s[c]+")";var d=a++;s[d]="("+s[u]+")\\.("+s[u]+")\\.("+s[u]+")";var h=a++;s[h]="(?:"+s[c]+"|"+s[l]+")";var f=a++;s[f]="(?:"+s[u]+"|"+s[l]+")";var m=a++;s[m]="(?:-("+s[h]+"(?:\\."+s[h]+")*))";var v=a++;s[v]="(?:-?("+s[f]+"(?:\\."+s[f]+")*))";var g=a++;s[g]="[0-9A-Za-z-]+";var y=a++;s[y]="(?:\\+("+s[g]+"(?:\\."+s[g]+")*))";var _=a++,b="v?"+s[p]+s[m]+"?"+s[y]+"?";s[_]="^"+b+"$";var E="[v=\\s]*"+s[d]+s[v]+"?"+s[y]+"?",T=a++;s[T]="^"+E+"$";var S=a++;s[S]="((?:<|>)?=?)";var C=a++;s[C]=s[u]+"|x|X|\\*";var x=a++;s[x]=s[c]+"|x|X|\\*";var w=a++;s[w]="[v=\\s]*("+s[x]+")(?:\\.("+s[x]+")(?:\\.("+s[x]+")(?:"+s[m]+")?"+s[y]+"?)?)?";var A=a++;s[A]="[v=\\s]*("+s[C]+")(?:\\.("+s[C]+")(?:\\.("+s[C]+")(?:"+s[v]+")?"+s[y]+"?)?)?";var I=a++;s[I]="^"+s[S]+"\\s*"+s[w]+"$";var R=a++;s[R]="^"+s[S]+"\\s*"+s[A]+"$";var P=a++;s[P]="(?:^|[^\\d])(\\d{1,16})(?:\\.(\\d{1,16}))?(?:\\.(\\d{1,16}))?(?:$|[^\\d])";var O=a++;s[O]="(?:~>?)";var N=a++;s[N]="(\\s*)"+s[O]+"\\s+",i[N]=new RegExp(s[N],"g");var k=a++;s[k]="^"+s[O]+s[w]+"$";var D=a++;s[D]="^"+s[O]+s[A]+"$";var M=a++;s[M]="(?:\\^)";var L=a++;s[L]="(\\s*)"+s[M]+"\\s+",i[L]=new RegExp(s[L],"g");var j=a++;s[j]="^"+s[M]+s[w]+"$";var U=a++;s[U]="^"+s[M]+s[A]+"$";var F=a++;s[F]="^"+s[S]+"\\s*("+E+")$|^$";var z=a++;s[z]="^"+s[S]+"\\s*("+b+")$|^$";var q=a++;s[q]="(\\s*)"+s[S]+"\\s*("+E+"|"+s[w]+")",i[q]=new RegExp(s[q],"g");var B=a++;s[B]="^\\s*("+s[w]+")\\s+-\\s+("+s[w]+")\\s*$";var H=a++;s[H]="^\\s*("+s[A]+")\\s+-\\s+("+s[A]+")\\s*$";var G,V=a++;for(s[V]="(<|>)?=?\\s*\\*",G=0;G<35;G++)n(G,s[G]),i[G]||(i[G]=new RegExp(s[G]));function $(e,t){if((!t||"object"!=typeof t)&&(t={loose:!!t,includePrerelease:!1}),e instanceof K)return e;if("string"!=typeof e||e.length>r)return null;if(!(t.loose?i[T]:i[_]).test(e))return null;try{return new K(e,t)}catch{return null}}function K(e,t){if((!t||"object"!=typeof t)&&(t={loose:!!t,includePrerelease:!1}),e instanceof K){if(e.loose===t.loose)return e;e=e.version}else if("string"!=typeof e)throw new TypeError("Invalid Version: "+e);if(e.length>r)throw new TypeError("version is longer than "+r+" characters");if(!(this instanceof K))return new K(e,t);n("SemVer",e,t),this.options=t,this.loose=!!t.loose;var s=e.trim().match(t.loose?i[T]:i[_]);if(!s)throw new TypeError("Invalid Version: "+e);if(this.raw=e,this.major=+s[1],this.minor=+s[2],this.patch=+s[3],this.major>o||this.major<0)throw new TypeError("Invalid major version");if(this.minor>o||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>o||this.patch<0)throw new TypeError("Invalid patch version");s[4]?this.prerelease=s[4].split(".").map((function(e){if(/^[0-9]+$/.test(e)){var t=+e;if(t>=0&&t<o)return t}return e})):this.prerelease=[],this.build=s[5]?s[5].split("."):[],this.format()}e.parse=$,e.valid=function(e,t){var n=$(e,t);return n?n.version:null},e.clean=function(e,t){var n=$(e.trim().replace(/^[=v]+/,""),t);return n?n.version:null},e.SemVer=K,K.prototype.format=function(){return this.version=this.major+"."+this.minor+"."+this.patch,this.prerelease.length&&(this.version+="-"+this.prerelease.join(".")),this.version},K.prototype.toString=function(){return this.version},K.prototype.compare=function(e){return n("SemVer.compare",this.version,this.options,e),e instanceof K||(e=new K(e,this.options)),this.compareMain(e)||this.comparePre(e)},K.prototype.compareMain=function(e){return e instanceof K||(e=new K(e,this.options)),Q(this.major,e.major)||Q(this.minor,e.minor)||Q(this.patch,e.patch)},K.prototype.comparePre=function(e){if(e instanceof K||(e=new K(e,this.options)),this.prerelease.length&&!e.prerelease.length)return-1;if(!this.prerelease.length&&e.prerelease.length)return 1;if(!this.prerelease.length&&!e.prerelease.length)return 0;var t=0;do{var r=this.prerelease[t],o=e.prerelease[t];if(n("prerelease compare",t,r,o),void 0===r&&void 0===o)return 0;if(void 0===o)return 1;if(void 0===r)return-1;if(r!==o)return Q(r,o)}while(++t)},K.prototype.inc=function(e,t){switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",t);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",t);break;case"prepatch":this.prerelease.length=0,this.inc("patch",t),this.inc("pre",t);break;case"prerelease":0===this.prerelease.length&&this.inc("patch",t),this.inc("pre",t);break;case"major":(0!==this.minor||0!==this.patch||0===this.prerelease.length)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(0!==this.patch||0===this.prerelease.length)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":0===this.prerelease.length&&this.patch++,this.prerelease=[];break;case"pre":if(0===this.prerelease.length)this.prerelease=[0];else{for(var n=this.prerelease.length;--n>=0;)"number"==typeof this.prerelease[n]&&(this.prerelease[n]++,n=-2);-1===n&&this.prerelease.push(0)}t&&(this.prerelease[0]===t?isNaN(this.prerelease[1])&&(this.prerelease=[t,0]):this.prerelease=[t,0]);break;default:throw new Error("invalid increment argument: "+e)}return this.format(),this.raw=this.version,this},e.inc=function(e,t,n,r){"string"==typeof n&&(r=n,n=void 0);try{return new K(e,n).inc(t,r).version}catch{return null}},e.diff=function(e,t){if(Z(e,t))return null;var n=$(e),r=$(t),o="";if(n.prerelease.length||r.prerelease.length){o="pre";var i="prerelease"}for(var s in n)if(("major"===s||"minor"===s||"patch"===s)&&n[s]!==r[s])return o+s;return i},e.compareIdentifiers=Q;var W=/^[0-9]+$/;function Q(e,t){var n=W.test(e),r=W.test(t);return n&&r&&(e=+e,t=+t),e===t?0:n&&!r?-1:r&&!n?1:e<t?-1:1}function Y(e,t,n){return new K(e,n).compare(new K(t,n))}function X(e,t,n){return Y(e,t,n)>0}function J(e,t,n){return Y(e,t,n)<0}function Z(e,t,n){return 0===Y(e,t,n)}function ee(e,t,n){return 0!==Y(e,t,n)}function te(e,t,n){return Y(e,t,n)>=0}function ne(e,t,n){return Y(e,t,n)<=0}function re(e,t,n,r){switch(t){case"===":return"object"==typeof e&&(e=e.version),"object"==typeof n&&(n=n.version),e===n;case"!==":return"object"==typeof e&&(e=e.version),"object"==typeof n&&(n=n.version),e!==n;case"":case"=":case"==":return Z(e,n,r);case"!=":return ee(e,n,r);case">":return X(e,n,r);case">=":return te(e,n,r);case"<":return J(e,n,r);case"<=":return ne(e,n,r);default:throw new TypeError("Invalid operator: "+t)}}function oe(e,t){if((!t||"object"!=typeof t)&&(t={loose:!!t,includePrerelease:!1}),e instanceof oe){if(e.loose===!!t.loose)return e;e=e.value}if(!(this instanceof oe))return new oe(e,t);n("comparator",e,t),this.options=t,this.loose=!!t.loose,this.parse(e),this.semver===ie?this.value="":this.value=this.operator+this.semver.version,n("comp",this)}e.rcompareIdentifiers=function(e,t){return Q(t,e)},e.major=function(e,t){return new K(e,t).major},e.minor=function(e,t){return new K(e,t).minor},e.patch=function(e,t){return new K(e,t).patch},e.compare=Y,e.compareLoose=function(e,t){return Y(e,t,!0)},e.rcompare=function(e,t,n){return Y(t,e,n)},e.sort=function(t,n){return t.sort((function(t,r){return e.compare(t,r,n)}))},e.rsort=function(t,n){return t.sort((function(t,r){return e.rcompare(t,r,n)}))},e.gt=X,e.lt=J,e.eq=Z,e.neq=ee,e.gte=te,e.lte=ne,e.cmp=re,e.Comparator=oe;var ie={};function se(e,t){if((!t||"object"!=typeof t)&&(t={loose:!!t,includePrerelease:!1}),e instanceof se)return e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease?e:new se(e.raw,t);if(e instanceof oe)return new se(e.value,t);if(!(this instanceof se))return new se(e,t);if(this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease,this.raw=e,this.set=e.split(/\s*\|\|\s*/).map((function(e){return this.parseRange(e.trim())}),this).filter((function(e){return e.length})),!this.set.length)throw new TypeError("Invalid SemVer Range: "+e);this.format()}function ae(e){return!e||"x"===e.toLowerCase()||"*"===e}function ce(e,t,n,r,o,i,s,a,c,u,l,p,d){return((t=ae(n)?"":ae(r)?">="+n+".0.0":ae(o)?">="+n+"."+r+".0":">="+t)+" "+(a=ae(c)?"":ae(u)?"<"+(+c+1)+".0.0":ae(l)?"<"+c+"."+(+u+1)+".0":p?"<="+c+"."+u+"."+l+"-"+p:"<="+a)).trim()}function ue(e,t,r){for(var o=0;o<e.length;o++)if(!e[o].test(t))return!1;if(t.prerelease.length&&!r.includePrerelease){for(o=0;o<e.length;o++)if(n(e[o].semver),e[o].semver!==ie&&e[o].semver.prerelease.length>0){var i=e[o].semver;if(i.major===t.major&&i.minor===t.minor&&i.patch===t.patch)return!0}return!1}return!0}function le(e,t,n){try{t=new se(t,n)}catch{return!1}return t.test(e)}function pe(e,t,n,r){var o,i,s,a,c;switch(e=new K(e,r),t=new se(t,r),n){case">":o=X,i=ne,s=J,a=">",c=">=";break;case"<":o=J,i=te,s=X,a="<",c="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(le(e,t,r))return!1;for(var u=0;u<t.set.length;++u){var l=t.set[u],p=null,d=null;if(l.forEach((function(e){e.semver===ie&&(e=new oe(">=0.0.0")),p=p||e,d=d||e,o(e.semver,p.semver,r)?p=e:s(e.semver,d.semver,r)&&(d=e)})),p.operator===a||p.operator===c||(!d.operator||d.operator===a)&&i(e,d.semver))return!1;if(d.operator===c&&s(e,d.semver))return!1}return!0}oe.prototype.parse=function(e){var t=this.options.loose?i[F]:i[z],n=e.match(t);if(!n)throw new TypeError("Invalid comparator: "+e);this.operator=n[1],"="===this.operator&&(this.operator=""),n[2]?this.semver=new K(n[2],this.options.loose):this.semver=ie},oe.prototype.toString=function(){return this.value},oe.prototype.test=function(e){return n("Comparator.test",e,this.options.loose),this.semver===ie||("string"==typeof e&&(e=new K(e,this.options)),re(e,this.operator,this.semver,this.options))},oe.prototype.intersects=function(e,t){if(!(e instanceof oe))throw new TypeError("a Comparator is required");var n;if((!t||"object"!=typeof t)&&(t={loose:!!t,includePrerelease:!1}),""===this.operator)return n=new se(e.value,t),le(this.value,n,t);if(""===e.operator)return n=new se(this.value,t),le(e.semver,n,t);var r=!(">="!==this.operator&&">"!==this.operator||">="!==e.operator&&">"!==e.operator),o=!("<="!==this.operator&&"<"!==this.operator||"<="!==e.operator&&"<"!==e.operator),i=this.semver.version===e.semver.version,s=!(">="!==this.operator&&"<="!==this.operator||">="!==e.operator&&"<="!==e.operator),a=re(this.semver,"<",e.semver,t)&&(">="===this.operator||">"===this.operator)&&("<="===e.operator||"<"===e.operator),c=re(this.semver,">",e.semver,t)&&("<="===this.operator||"<"===this.operator)&&(">="===e.operator||">"===e.operator);return r||o||i&&s||a||c},e.Range=se,se.prototype.format=function(){return this.range=this.set.map((function(e){return e.join(" ").trim()})).join("||").trim(),this.range},se.prototype.toString=function(){return this.range},se.prototype.parseRange=function(e){var t=this.options.loose;e=e.trim();var r=t?i[H]:i[B];e=e.replace(r,ce),n("hyphen replace",e),e=e.replace(i[q],"$1$2$3"),n("comparator trim",e,i[q]),e=(e=(e=e.replace(i[N],"$1~")).replace(i[L],"$1^")).split(/\s+/).join(" ");var o=t?i[F]:i[z],s=e.split(" ").map((function(e){return function(e,t){return n("comp",e,t),e=function(e,t){return e.trim().split(/\s+/).map((function(e){return function(e,t){n("caret",e,t);var r=t.loose?i[U]:i[j];return e.replace(r,(function(t,r,o,i,s){var a;return n("caret",e,t,r,o,i,s),ae(r)?a="":ae(o)?a=">="+r+".0.0 <"+(+r+1)+".0.0":ae(i)?a="0"===r?">="+r+"."+o+".0 <"+r+"."+(+o+1)+".0":">="+r+"."+o+".0 <"+(+r+1)+".0.0":s?(n("replaceCaret pr",s),a="0"===r?"0"===o?">="+r+"."+o+"."+i+"-"+s+" <"+r+"."+o+"."+(+i+1):">="+r+"."+o+"."+i+"-"+s+" <"+r+"."+(+o+1)+".0":">="+r+"."+o+"."+i+"-"+s+" <"+(+r+1)+".0.0"):(n("no pr"),a="0"===r?"0"===o?">="+r+"."+o+"."+i+" <"+r+"."+o+"."+(+i+1):">="+r+"."+o+"."+i+" <"+r+"."+(+o+1)+".0":">="+r+"."+o+"."+i+" <"+(+r+1)+".0.0"),n("caret return",a),a}))}(e,t)})).join(" ")}(e,t),n("caret",e),e=function(e,t){return e.trim().split(/\s+/).map((function(e){return function(e,t){var r=t.loose?i[D]:i[k];return e.replace(r,(function(t,r,o,i,s){var a;return n("tilde",e,t,r,o,i,s),ae(r)?a="":ae(o)?a=">="+r+".0.0 <"+(+r+1)+".0.0":ae(i)?a=">="+r+"."+o+".0 <"+r+"."+(+o+1)+".0":s?(n("replaceTilde pr",s),a=">="+r+"."+o+"."+i+"-"+s+" <"+r+"."+(+o+1)+".0"):a=">="+r+"."+o+"."+i+" <"+r+"."+(+o+1)+".0",n("tilde return",a),a}))}(e,t)})).join(" ")}(e,t),n("tildes",e),e=function(e,t){return n("replaceXRanges",e,t),e.split(/\s+/).map((function(e){return function(e,t){e=e.trim();var r=t.loose?i[R]:i[I];return e.replace(r,(function(t,r,o,i,s,a){n("xRange",e,t,r,o,i,s,a);var c=ae(o),u=c||ae(i),l=u||ae(s);return"="===r&&l&&(r=""),c?t=">"===r||"<"===r?"<0.0.0":"*":r&&l?(u&&(i=0),s=0,">"===r?(r=">=",u?(o=+o+1,i=0,s=0):(i=+i+1,s=0)):"<="===r&&(r="<",u?o=+o+1:i=+i+1),t=r+o+"."+i+"."+s):u?t=">="+o+".0.0 <"+(+o+1)+".0.0":l&&(t=">="+o+"."+i+".0 <"+o+"."+(+i+1)+".0"),n("xRange return",t),t}))}(e,t)})).join(" ")}(e,t),n("xrange",e),e=function(e,t){return n("replaceStars",e,t),e.trim().replace(i[V],"")}(e,t),n("stars",e),e}(e,this.options)}),this).join(" ").split(/\s+/);return this.options.loose&&(s=s.filter((function(e){return!!e.match(o)}))),s.map((function(e){return new oe(e,this.options)}),this)},se.prototype.intersects=function(e,t){if(!(e instanceof se))throw new TypeError("a Range is required");return this.set.some((function(n){return n.every((function(n){return e.set.some((function(e){return e.every((function(e){return n.intersects(e,t)}))}))}))}))},e.toComparators=function(e,t){return new se(e,t).set.map((function(e){return e.map((function(e){return e.value})).join(" ").trim().split(" ")}))},se.prototype.test=function(e){if(!e)return!1;"string"==typeof e&&(e=new K(e,this.options));for(var t=0;t<this.set.length;t++)if(ue(this.set[t],e,this.options))return!0;return!1},e.satisfies=le,e.maxSatisfying=function(e,t,n){var r=null,o=null;try{var i=new se(t,n)}catch{return null}return e.forEach((function(e){i.test(e)&&(!r||-1===o.compare(e))&&(o=new K(r=e,n))})),r},e.minSatisfying=function(e,t,n){var r=null,o=null;try{var i=new se(t,n)}catch{return null}return e.forEach((function(e){i.test(e)&&(!r||1===o.compare(e))&&(o=new K(r=e,n))})),r},e.minVersion=function(e,t){e=new se(e,t);var n=new K("0.0.0");if(e.test(n)||(n=new K("0.0.0-0"),e.test(n)))return n;n=null;for(var r=0;r<e.set.length;++r)e.set[r].forEach((function(e){var t=new K(e.semver.version);switch(e.operator){case">":0===t.prerelease.length?t.patch++:t.prerelease.push(0),t.raw=t.format();case"":case">=":(!n||X(n,t))&&(n=t);break;case"<":case"<=":break;default:throw new Error("Unexpected operation: "+e.operator)}}));return n&&e.test(n)?n:null},e.validRange=function(e,t){try{return new se(e,t).range||"*"}catch{return null}},e.ltr=function(e,t,n){return pe(e,t,"<",n)},e.gtr=function(e,t,n){return pe(e,t,">",n)},e.outside=pe,e.prerelease=function(e,t){var n=$(e,t);return n&&n.prerelease.length?n.prerelease:null},e.intersects=function(e,t,n){return e=new se(e,n),t=new se(t,n),e.intersects(t)},e.coerce=function(e){if(e instanceof K)return e;if("string"!=typeof e)return null;var t=e.match(i[P]);return null==t?null:$(t[1]+"."+(t[2]||"0")+"."+(t[3]||"0"))}})),Tr=b(((e,t)=>{var n,r,o,i,s,a=sr().wrap,c=1,u=2,l=4,p=8,d=[],h=0,f=!1,m=[];function v(e,t){var n=e.length,r=t.length,o=[];if(0===n&&0===r)return o;for(var i=0;i<n;i++)o[i]=e[i];if(0===r)return o;for(var s=0;s<r;s++){var a=!0;for(i=0;i<n;i++)if(e[i].uid===t[s].uid){a=!1;break}a&&o.push(t[s])}return o}function g(e,t){"function"==typeof e.create&&(this.create=e.create,this.flags|=c),"function"==typeof e.before&&(this.before=e.before,this.flags|=u),"function"==typeof e.after&&(this.after=e.after,this.flags|=l),"function"==typeof e.error&&(this.error=e.error,this.flags|=p),this.uid=++h,this.data=void 0===t?null:t}function y(e,t){if("object"!=typeof e||!e)throw new TypeError("callbacks argument must be an object");return e instanceof g?e:new g(e,t)}process._fatalException?(o=!1,n=function(e){var t=d.length;if(o||0===t)return!1;var n=!1;o=!0;for(var r=0;r<t;++r){var s=d[r];if(s.flags&p){var a=i&&i[s.uid];n=s.error(a,e)||n}}return o=!1,m.length>0&&(d=m.pop()),i=void 0,n&&!f},r=function(e,t,n){var r=[];f=!0;for(var o=0;o<n;++o){var s=t[o];if(r[s.uid]=s.data,s.flags&c){var a=s.create(s.data);void 0!==a&&(r[s.uid]=a)}}return f=!1,function(){i=r,m.push(d),d=v(t,d),f=!0;for(var o=0;o<n;++o)(t[o].flags&u)>0&&t[o].before(this,r[t[o].uid]);f=!1;var s=e.apply(this,arguments);for(f=!0,o=0;o<n;++o)(t[o].flags&l)>0&&t[o].after(this,r[t[o].uid]);return f=!1,d=m.pop(),i=void 0,s}},a(process,"_fatalException",(function(e){return function(t){return n(t)||e(t)}}))):(s=!1,n=function(e){if(s)throw e;for(var t=!1,n=d.length,r=0;r<n;++r){var o=d[r];o.flags&p&&(t=o.error(null,e)||t)}if(!t&&f)throw e},r=function(e,t,r){var o=[];f=!0;for(var i=0;i<r;++i){var a=t[i];if(o[a.uid]=a.data,a.flags&c){var h=a.create(a.data);void 0!==h&&(o[a.uid]=h)}}return f=!1,function(){var i,a=!1,c=!1;m.push(d),d=v(t,d),f=!0;for(var h=0;h<r;++h)(t[h].flags&u)>0&&t[h].before(this,o[t[h].uid]);f=!1;try{i=e.apply(this,arguments)}catch(e){for(a=!0,h=0;h<r;++h)if(d[h].flags&p)try{c=d[h].error(o[t[h].uid],e)||c}catch(e){throw s=!0,e}if(!c)throw process.removeListener("uncaughtException",n),process._originalNextTick((function(){process.addListener("uncaughtException",n)})),e}finally{if(!a||c){for(f=!0,h=0;h<r;++h)(t[h].flags&l)>0&&t[h].after(this,o[t[h].uid]);f=!1}d=m.pop()}return i}},process.addListener("uncaughtException",n)),g.prototype.create=void 0,g.prototype.before=void 0,g.prototype.after=void 0,g.prototype.error=void 0,g.prototype.data=void 0,g.prototype.uid=0,g.prototype.flags=0,process.createAsyncListener=y,process.addAsyncListener=function(e,t){var n;n=e instanceof g?e:y(e,t);for(var r=!1,o=0;o<d.length;o++)if(n===d[o]){r=!0;break}return r||d.push(n),n},process.removeAsyncListener=function(e){for(var t=0;t<d.length;t++)if(e===d[t]){d.splice(t,1);break}},t.exports=function(e){var t=d.length;if(0===t)return e;for(var n=d.slice(),o=0;o<t;++o)if(n[o].flags>0)return r(e,n,t);return function(e,t,n){f=!0;for(var r=0;r<n;++r){var o=t[r];o.create&&o.create(o.data)}return f=!1,function(){m.push(d),d=v(t,d);var n=e.apply(this,arguments);return d=m.pop(),n}}(e,n,t)}})),Sr=b(((e,t)=>{"use strict";t.exports=(e,t)=>class extends e{constructor(e){var n,r;super((function(e,i){n=this,r=[function(n){return t(o,!1),e(n)},function(e){return t(o,!1),i(e)}]}));var o=this;try{e.apply(n,r)}catch(e){r[1](e)}return o}}})),Cr=b((()=>{"use strict";if(process.addAsyncListener)throw new Error("Don't require polyfill unless needed");var e=sr(),t=Er(),r=e.wrap,o=e.massWrap,i=Tr(),s=n(9023),a=t.gte(process.version,"6.0.0"),c=t.gte(process.version,"7.0.0"),u=t.gte(process.version,"8.0.0"),l=t.gte(process.version,"11.0.0"),p=n(9278);function d(e){return function(){this.on("connection",(function(e){e._handle&&(e._handle.onread=i(e._handle.onread))}));try{return e.apply(this,arguments)}finally{this._handle&&this._handle.onconnection&&(this._handle.onconnection=i(this._handle.onconnection))}}}function h(e){if(e&&e._handle){var t=e._handle;t._originalOnread||(t._originalOnread=t.onread),t.onread=i(t._originalOnread)}}c&&!p._normalizeArgs?p._normalizeArgs=function(e){if(0===e.length)return[{},null];var t=e[0],n={};"object"==typeof t&&null!==t?n=t:function(e){return"string"==typeof e&&!1===function(e){return(e=Number(e))>=0&&e}(e)}(t)?n.path=t:(n.port=t,e.length>1&&"string"==typeof e[1]&&(n.host=e[1]));var r=e[e.length-1];return"function"!=typeof r?[n,null]:[n,r]}:!c&&!p._normalizeConnectArgs&&(p._normalizeConnectArgs=function(e){var t={};"object"==typeof e[0]&&null!==e[0]?t=e[0]:"string"==typeof e[0]&&!1===function(e){return(e=Number(e))>=0&&e}(e[0])?t.path=e[0]:(t.port=e[0],"string"==typeof e[1]&&(t.host=e[1]));var n=e[e.length-1];return"function"==typeof n?[t,n]:[t]}),"_setUpListenHandle"in p.Server.prototype?r(p.Server.prototype,"_setUpListenHandle",d):r(p.Server.prototype,"_listen2",d),r(p.Socket.prototype,"connect",(function(e){return function(){var t;(t=u&&Array.isArray(arguments[0])&&Object.getOwnPropertySymbols(arguments[0]).length>0?arguments[0]:c?p._normalizeArgs(arguments):p._normalizeConnectArgs(arguments))[1]&&(t[1]=i(t[1]));var n=e.apply(this,t);return h(this),n}}));var f=n(8611);r(f.Agent.prototype,"addRequest",(function(e){return function(t){var n=t.onSocket;return t.onSocket=i((function(e){return h(e),n.apply(this,arguments)})),e.apply(this,arguments)}}));var m=n(5317);function v(e){Array.isArray(e.stdio)&&e.stdio.forEach((function(e){e&&e._handle&&(e._handle.onread=i(e._handle.onread),r(e._handle,"close",P))})),e._handle&&(e._handle.onexit=i(e._handle.onexit))}m.ChildProcess?r(m.ChildProcess.prototype,"spawn",(function(e){return function(){var t=e.apply(this,arguments);return v(this),t}})):o(m,["execFile","fork","spawn"],(function(e){return function(){var t=e.apply(this,arguments);return v(t),t}})),process._fatalException||(process._originalNextTick=process.nextTick);var g=[];process._nextDomainTick&&g.push("_nextDomainTick"),process._tickDomainCallback&&g.push("_tickDomainCallback"),o(process,g,R),r(process,"nextTick",P);var y=["setTimeout","setInterval"];global.setImmediate&&y.push("setImmediate");var _=n(3557),b=global.setTimeout===_.setTimeout;o(_,y,P),b&&o(global,y,P);var E=n(2250);o(E,["lookup","resolve","resolve4","resolve6","resolveCname","resolveMx","resolveNs","resolveTxt","resolveSrv","reverse"],R),E.resolveNaptr&&r(E,"resolveNaptr",R);var T,S,C,x=n(9896);o(x,["watch","rename","truncate","chown","fchown","chmod","fchmod","stat","lstat","fstat","link","symlink","readlink","realpath","unlink","rmdir","mkdir","readdir","close","open","utimes","futimes","fsync","write","read","readFile","writeFile","appendFile","watchFile","unwatchFile","exists"],R),x.lchown&&r(x,"lchown",R),x.lchmod&&r(x,"lchmod",R),x.ftruncate&&r(x,"ftruncate",R);try{T=n(3106)}catch{}T&&T.Deflate&&T.Deflate.prototype&&((S=Object.getPrototypeOf(T.Deflate.prototype))._transform?r(S,"_transform",R):S.write&&S.flush&&S.end&&o(S,["write","flush","end"],R));try{C=n(6982)}catch{}C&&(w=["pbkdf2","randomBytes"],l||w.push("pseudoRandomBytes"),o(C,w,R));var w,A,I=!!global.Promise&&"function Promise() { [native code] }"===Promise.toString()&&"function toString() { [native code] }"===Promise.toString.toString();function R(e){var t=function(){var t,n=arguments.length-1;if("function"==typeof arguments[n]){t=Array(arguments.length);for(var r=0;r<arguments.length-1;r++)t[r]=arguments[r];t[n]=i(arguments[n])}return e.apply(this,t||arguments)};switch(e.length){case 1:return function(n){return 1!==arguments.length?t.apply(this,arguments):("function"==typeof n&&(n=i(n)),e.call(this,n))};case 2:return function(n,r){return 2!==arguments.length?t.apply(this,arguments):("function"==typeof r&&(r=i(r)),e.call(this,n,r))};case 3:return function(n,r,o){return 3!==arguments.length?t.apply(this,arguments):("function"==typeof o&&(o=i(o)),e.call(this,n,r,o))};case 4:return function(n,r,o,s){return 4!==arguments.length?t.apply(this,arguments):("function"==typeof s&&(s=i(s)),e.call(this,n,r,o,s))};case 5:return function(n,r,o,s,a){return 5!==arguments.length?t.apply(this,arguments):("function"==typeof a&&(a=i(a)),e.call(this,n,r,o,s,a))};case 6:return function(n,r,o,s,a,c){return 6!==arguments.length?t.apply(this,arguments):("function"==typeof c&&(c=i(c)),e.call(this,n,r,o,s,a,c))};default:return t}}function P(e){var t=function(){var t;if("function"==typeof arguments[0]){(t=Array(arguments.length))[0]=i(arguments[0]);for(var n=1;n<arguments.length;n++)t[n]=arguments[n]}return e.apply(this,t||arguments)};switch(e.length){case 1:return function(n){return 1!==arguments.length?t.apply(this,arguments):("function"==typeof n&&(n=i(n)),e.call(this,n))};case 2:return function(n,r){return 2!==arguments.length?t.apply(this,arguments):("function"==typeof n&&(n=i(n)),e.call(this,n,r))};case 3:return function(n,r,o){return 3!==arguments.length?t.apply(this,arguments):("function"==typeof n&&(n=i(n)),e.call(this,n,r,o))};case 4:return function(n,r,o,s){return 4!==arguments.length?t.apply(this,arguments):("function"==typeof n&&(n=i(n)),e.call(this,n,r,o,s))};case 5:return function(n,r,o,s,a){return 5!==arguments.length?t.apply(this,arguments):("function"==typeof n&&(n=i(n)),e.call(this,n,r,o,s,a))};case 6:return function(n,r,o,s,a,c){return 6!==arguments.length?t.apply(this,arguments):("function"==typeof n&&(n=i(n)),e.call(this,n,r,o,s,a,c))};default:return t}}I&&(A=process.addAsyncListener({create:function(){I=!1}}),global.Promise.resolve(!0).then((function(){I=!1})),process.removeAsyncListener(A)),I&&function(){var e=global.Promise;function t(r){if(!(this instanceof t))return e(r);if("function"!=typeof r)return new e(r);var o,i,s=new e((function(e,t){o=this,i=[function(t){return n(s,!1),e(t)},function(e){return n(s,!1),t(e)}]}));s.__proto__=t.prototype;try{r.apply(o,i)}catch(e){i[1](e)}return s}function n(e,t){(!e.__asl_wrapper||t)&&(e.__asl_wrapper=i(o))}function o(t,r,i,s){var a;try{return{returnVal:a=r.call(t,i),error:!1}}catch(e){return{errorVal:e,error:!0}}finally{a instanceof e?s.__asl_wrapper=function(){return(a.__asl_wrapper||o).apply(this,arguments)}:n(s,!0)}}function c(e){return function(){var t=this,n=e.apply(t,Array.prototype.map.call(arguments,(function(e){return"function"!=typeof e?e:i((function(r){var i=(t.__asl_wrapper||o)(this,e,r,n);if(i.error)throw i.errorVal;return i.returnVal}))})));return n.__asl_wrapper=function(e,r,i,s){return t.__asl_wrapper?(t.__asl_wrapper(e,(function(){}),null,n),n.__asl_wrapper(e,r,i,s)):o(e,r,i,s)},n}}s.inherits(t,e),r(e.prototype,"then",c),e.prototype.chain&&r(e.prototype,"chain",c),a?global.Promise=Sr()(e,n):(["all","race","reject","resolve","accept","defer"].forEach((function(n){"function"==typeof e[n]&&(t[n]=e[n])})),global.Promise=t)}()})),xr=b(((e,t)=>{"use strict";var r=n(2613),o=ar(),i="cls@contexts",s="error@context";function a(e){this.name=e,this.active=null,this._set=[],this.id=null}function c(e){return process.namespaces[e]}function u(e){var t=c(e);r.ok(t,"can't delete nonexistent namespace!"),r.ok(t.id,"don't assign to process.namespaces directly!"),process.removeAsyncListener(t.id),process.namespaces[e]=null}function l(){process.namespaces&&Object.keys(process.namespaces).forEach((function(e){u(e)})),process.namespaces=Object.create(null)}process.addAsyncListener||Cr(),a.prototype.set=function(e,t){if(!this.active)throw new Error("No context available. ns.run() or ns.bind() must be called first.");return this.active[e]=t,t},a.prototype.get=function(e){if(this.active)return this.active[e]},a.prototype.createContext=function(){return Object.create(this.active)},a.prototype.run=function(e){var t=this.createContext();this.enter(t);try{return e(t),t}catch(e){throw e&&(e[s]=t),e}finally{this.exit(t)}},a.prototype.runAndReturn=function(e){var t;return this.run((function(n){t=e(n)})),t},a.prototype.bind=function(e,t){t||(t=this.active?this.active:this.createContext());var n=this;return function(){n.enter(t);try{return e.apply(this,arguments)}catch(e){throw e&&(e[s]=t),e}finally{n.exit(t)}}},a.prototype.enter=function(e){r.ok(e,"context must be provided for entering"),this._set.push(this.active),this.active=e},a.prototype.exit=function(e){if(r.ok(e,"context must be provided for exiting"),this.active===e)return r.ok(this._set.length,"can't remove top context"),void(this.active=this._set.pop());var t=this._set.lastIndexOf(e);r.ok(t>=0,"context not currently entered; can't exit"),r.ok(t,"can't remove top context"),this._set.splice(t,1)},a.prototype.bindEmitter=function(e){r.ok(e.on&&e.addListener&&e.emit,"can only bind real EEs");var t=this,n="context@"+this.name;o(e,(function(e){!e||(e[i]||(e[i]=Object.create(null)),e[i][n]={namespace:t,context:t.active})}),(function(e){if(!e||!e[i])return e;var t=e,n=e[i];return Object.keys(n).forEach((function(e){var r=n[e];t=r.namespace.bind(t,r.context)})),t}))},a.prototype.fromException=function(e){return e[s]},process.namespaces||l(),t.exports={getNamespace:c,createNamespace:function(e){r.ok(e,"namespace must be given a name!");var t=new a(e);return t.id=process.addAsyncListener({create:function(){return t.active},before:function(e,n){n&&t.enter(n)},after:function(e,n){n&&t.exit(n)},error:function(e){e&&t.exit(e)}}),process.namespaces[e]=t,t},destroyNamespace:u,reset:l}})),wr=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.CorrelationContextManager=void 0;var t=R(),n=an(),r=pn(),o=dn(),i=or(),s=function(){function e(){}return e.getCurrentContext=function(){if(!e.enabled)return null;var t=e.session.get(e.CONTEXT_NAME);return void 0===t?null:t},e.generateContextObject=function(e,t,n,r,o,i){return t=t||e,this.enabled?{operation:{name:n,id:e,parentId:t,traceparent:o,tracestate:i},customProperties:new a(r)}:null},e.spanToContextObject=function(t,n,o){var i=new r;return i.traceId=t.traceId,i.spanId=t.spanId,i.traceFlag=r.formatOpenTelemetryTraceFlags(t.traceFlags)||r.DEFAULT_TRACE_FLAG,i.parentId=n,e.generateContextObject(i.traceId,i.parentId,o,null,i)},e.runWithContext=function(t,n){var r;return e.enabled?e.session.bind(n,((r={})[e.CONTEXT_NAME]=t,r))():n()},e.wrapEmitter=function(t){e.enabled&&e.session.bindEmitter(t)},e.wrapCallback=function(t,n){var r;return e.enabled?e.session.bind(t,n?((r={})[e.CONTEXT_NAME]=n,r):void 0):t},e.enable=function(t){if(!this.enabled){if(!this.isNodeVersionCompatible())return void(this.enabled=!1);e.hasEverEnabled||(this.forceClsHooked=t,this.hasEverEnabled=!0,typeof this.cls>"u"&&(!0===e.forceClsHooked||void 0===e.forceClsHooked&&e.shouldUseClsHooked()?this.cls=br():this.cls=xr()),e.session=this.cls.createNamespace("AI-CLS-Session"),n.registerContextPreservation((function(t){return e.session.bind(t)}))),this.enabled=!0}},e.startOperation=function(n,s){var a=n&&n.traceContext||null,c=n&&n.traceId?n:null,u=n&&n.headers;if(c){var l=new r("00-"+c.traceId+"-"+c.spanId+"-01"),p=new o(c.traceState?c.traceState.serialize():null);return e.generateContextObject(c.traceId,"|"+c.traceId+"."+c.spanId+".","string"==typeof s?s:"",void 0,l,p)}if(a){l=new r(a.traceparent),p=new o(a.tracestate);var d="object"==typeof s?new i(s):null;return e.generateContextObject(l.traceId,l.parentId,"string"==typeof s?s:d.getOperationName({}),d&&d.getCorrelationContextHeader()||void 0,l,p)}return u?(l=new r(u.traceparent?u.traceparent.toString():null),p=new o(u.tracestate?u.tracestate.toString():null),d=new i(n),e.generateContextObject(l.traceId,l.parentId,d.getOperationName({}),d.getCorrelationContextHeader(),l,p)):(t.warn("startOperation was called with invalid arguments",arguments),null)},e.disable=function(){this.enabled=!1},e.reset=function(){e.hasEverEnabled&&(e.session=null,e.session=this.cls.createNamespace("AI-CLS-Session"))},e.isNodeVersionCompatible=function(){var e=process.versions.node.split(".");return parseInt(e[0])>3||parseInt(e[0])>2&&parseInt(e[1])>2},e.shouldUseClsHooked=function(){var e=process.versions.node.split(".");return parseInt(e[0])>8||parseInt(e[0])>=8&&parseInt(e[1])>=2},e.canUseClsHooked=function(){var e=process.versions.node.split("."),t=parseInt(e[0])>8||parseInt(e[0])>=8&&parseInt(e[1])>=0,n=parseInt(e[0])<8||parseInt(e[0])<=8&&parseInt(e[1])<2,r=parseInt(e[0])>4||parseInt(e[0])>=4&&parseInt(e[1])>=7;return!(t&&n)&&r},e.enabled=!1,e.hasEverEnabled=!1,e.forceClsHooked=void 0,e.CONTEXT_NAME="ApplicationInsights-Context",e}();e.CorrelationContextManager=s;var a=function(){function e(e){this.props=[],this.addHeaderData(e)}return e.prototype.addHeaderData=function(e){var t=e?e.split(", "):[];this.props=t.map((function(e){var t=e.split("=");return{key:t[0],value:t[1]}})).concat(this.props)},e.prototype.serializeToHeader=function(){return this.props.map((function(e){return e.key+"="+e.value})).join(", ")},e.prototype.getProperty=function(e){for(var t=0;t<this.props.length;++t){var n=this.props[t];if(n.key===e)return n.value}},e.prototype.setProperty=function(n,r){if(e.bannedCharacters.test(n)||e.bannedCharacters.test(r))t.warn("Correlation context property keys and values must not contain ',' or '='. setProperty was called with key: "+n+" and value: "+r);else{for(var o=0;o<this.props.length;++o){var i=this.props[o];if(i.key===n)return void(i.value=r)}this.props.push({key:n,value:r})}},e.bannedCharacters=/[,=]/,e}()})),Ar=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.dispose=e.enable=void 0;var t=nr(),n=D(),r=[],o=function(e){var n=e.data.message;r.forEach((function(r){n instanceof Error?r.trackException({exception:n}):(n.lastIndexOf("\n")==n.length-1&&(n=n.substring(0,n.length-1)),r.trackTrace({message:n,severity:e.data.stderr?t.SeverityLevel.Warning:t.SeverityLevel.Information}))}))};e.enable=function(e,t){e?(0===r.length&&n.channel.subscribe("console",o),r.push(t)):0===(r=r.filter((function(e){return e!=t}))).length&&n.channel.unsubscribe("console",o)},e.dispose=function(){n.channel.unsubscribe("console",o),r=[]}})),Ir=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.dispose=e.enable=void 0;var t=nr(),n=D(),r=[],o={10:t.SeverityLevel.Verbose,20:t.SeverityLevel.Verbose,30:t.SeverityLevel.Information,40:t.SeverityLevel.Warning,50:t.SeverityLevel.Error,60:t.SeverityLevel.Critical},i=function(e){var t=e.data.result;r.forEach((function(n){var r=o[e.data.level];t instanceof Error?n.trackException({exception:t}):n.trackTrace({message:t,severity:r})}))};e.enable=function(e,t){e?(0===r.length&&n.channel.subscribe("bunyan",i),r.push(t)):0===(r=r.filter((function(e){return e!=t}))).length&&n.channel.unsubscribe("bunyan",i)},e.dispose=function(){n.channel.unsubscribe("bunyan",i),r=[]}})),Rr=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.dispose=e.enable=void 0;var t=nr(),n=D(),r=[],o={syslog:function(e){var n={emerg:t.SeverityLevel.Critical,alert:t.SeverityLevel.Critical,crit:t.SeverityLevel.Critical,error:t.SeverityLevel.Error,warning:t.SeverityLevel.Warning,notice:t.SeverityLevel.Information,info:t.SeverityLevel.Information,debug:t.SeverityLevel.Verbose};return void 0===n[e]?t.SeverityLevel.Information:n[e]},npm:function(e){var n={error:t.SeverityLevel.Error,warn:t.SeverityLevel.Warning,info:t.SeverityLevel.Information,verbose:t.SeverityLevel.Verbose,debug:t.SeverityLevel.Verbose,silly:t.SeverityLevel.Verbose};return void 0===n[e]?t.SeverityLevel.Information:n[e]},unknown:function(e){return t.SeverityLevel.Information}},i=function(e){var t=e.data.message;r.forEach((function(n){if(t instanceof Error)n.trackException({exception:t,properties:e.data.meta});else{var r=o[e.data.levelKind](e.data.level);n.trackTrace({message:t,severity:r,properties:e.data.meta})}}))};e.enable=function(e,t){e?(0===r.length&&n.channel.subscribe("winston",i),r.push(t)):0===(r=r.filter((function(e){return e!=t}))).length&&n.channel.unsubscribe("winston",i)},e.dispose=function(){n.channel.unsubscribe("winston",i),r=[]}})),Pr=b(((e,t)=>{"use strict";var n=an(),r=function(){function e(t){if(e.INSTANCE)throw new Error("Console logging adapter tracking should be configured from the applicationInsights object");this._client=t,e.INSTANCE=this}return e.prototype.enable=function(e,t){n.IsInitialized&&(Ar().enable(e&&t,this._client),Ir().enable(e,this._client),Rr().enable(e,this._client))},e.prototype.isInitialized=function(){return this._isInitialized},e.prototype.dispose=function(){e.INSTANCE=null,this.enable(!1,!1)},e._methodNames=["debug","info","log","warn","error"],e}();t.exports=r})),Or=b(((e,t)=>{"use strict";var n=function(){function e(t){if(e.INSTANCE)throw new Error("Exception tracking should be configured from the applicationInsights object");e.INSTANCE=this,this._client=t;var n=process.versions.node.split(".");e._canUseUncaughtExceptionMonitor=parseInt(n[0])>13||13===parseInt(n[0])&&parseInt(n[1])>=7}return e.prototype.isInitialized=function(){return this._isInitialized},e.prototype.enable=function(t){var n=this;if(t){if(this._isInitialized=!0,!this._exceptionListenerHandle){var r=function(t,r,o){void 0===o&&(o=new Error(e._FALLBACK_ERROR_MESSAGE)),n._client.trackException({exception:o}),n._client.flush({isAppCrashing:!0}),t&&r&&1===process.listeners(r).length&&(console.error(o),process.exit(1))};e._canUseUncaughtExceptionMonitor?(this._exceptionListenerHandle=r.bind(this,!1,void 0),process.on(e.UNCAUGHT_EXCEPTION_MONITOR_HANDLER_NAME,this._exceptionListenerHandle)):(this._exceptionListenerHandle=r.bind(this,!0,e.UNCAUGHT_EXCEPTION_HANDLER_NAME),this._rejectionListenerHandle=r.bind(this,!1,void 0),process.on(e.UNCAUGHT_EXCEPTION_HANDLER_NAME,this._exceptionListenerHandle),process.on(e.UNHANDLED_REJECTION_HANDLER_NAME,this._rejectionListenerHandle))}}else this._exceptionListenerHandle&&(e._canUseUncaughtExceptionMonitor?process.removeListener(e.UNCAUGHT_EXCEPTION_MONITOR_HANDLER_NAME,this._exceptionListenerHandle):(process.removeListener(e.UNCAUGHT_EXCEPTION_HANDLER_NAME,this._exceptionListenerHandle),process.removeListener(e.UNHANDLED_REJECTION_HANDLER_NAME,this._rejectionListenerHandle)),this._exceptionListenerHandle=void 0,this._rejectionListenerHandle=void 0,delete this._exceptionListenerHandle,delete this._rejectionListenerHandle)},e.prototype.dispose=function(){e.INSTANCE=null,this.enable(!1),this._isInitialized=!1},e.INSTANCE=null,e.UNCAUGHT_EXCEPTION_MONITOR_HANDLER_NAME="uncaughtExceptionMonitor",e.UNCAUGHT_EXCEPTION_HANDLER_NAME="uncaughtException",e.UNHANDLED_REJECTION_HANDLER_NAME="unhandledRejection",e._RETHROW_EXIT_MESSAGE="Application Insights Rethrow Exception Handler",e._FALLBACK_ERROR_MESSAGE="A promise was rejected without providing an error. Application Insights generated this error stack for you.",e._canUseUncaughtExceptionMonitor=!1,e}();t.exports=n})),Nr=b((e=>{"use strict";var t,n,r,o;Object.defineProperty(e,"__esModule",{value:!0}),e.HeartBeatMetricName=e.DependencyTypeName=e.SpanAttribute=e.TelemetryTypeStringToQuickPulseDocumentType=e.TelemetryTypeStringToQuickPulseType=e.QuickPulseType=e.QuickPulseDocumentType=e.PerformanceToQuickPulseCounter=e.MetricId=e.PerformanceCounter=e.QuickPulseCounter=e.DEFAULT_LIVEMETRICS_HOST=e.DEFAULT_LIVEMETRICS_ENDPOINT=e.DEFAULT_BREEZE_ENDPOINT=void 0,e.DEFAULT_BREEZE_ENDPOINT="https://dc.services.visualstudio.com",e.DEFAULT_LIVEMETRICS_ENDPOINT="https://rt.services.visualstudio.com",e.DEFAULT_LIVEMETRICS_HOST="rt.services.visualstudio.com",(r=n=e.QuickPulseCounter||(e.QuickPulseCounter={})).COMMITTED_BYTES="\\Memory\\Committed Bytes",r.PROCESSOR_TIME="\\Processor(_Total)\\% Processor Time",r.REQUEST_RATE="\\ApplicationInsights\\Requests/Sec",r.REQUEST_FAILURE_RATE="\\ApplicationInsights\\Requests Failed/Sec",r.REQUEST_DURATION="\\ApplicationInsights\\Request Duration",r.DEPENDENCY_RATE="\\ApplicationInsights\\Dependency Calls/Sec",r.DEPENDENCY_FAILURE_RATE="\\ApplicationInsights\\Dependency Calls Failed/Sec",r.DEPENDENCY_DURATION="\\ApplicationInsights\\Dependency Call Duration",r.EXCEPTION_RATE="\\ApplicationInsights\\Exceptions/Sec",function(e){e.PRIVATE_BYTES="\\Process(??APP_WIN32_PROC??)\\Private Bytes",e.AVAILABLE_BYTES="\\Memory\\Available Bytes",e.PROCESSOR_TIME="\\Processor(_Total)\\% Processor Time",e.PROCESS_TIME="\\Process(??APP_WIN32_PROC??)\\% Processor Time",e.REQUEST_RATE="\\ASP.NET Applications(??APP_W3SVC_PROC??)\\Requests/Sec",e.REQUEST_DURATION="\\ASP.NET Applications(??APP_W3SVC_PROC??)\\Request Execution Time"}(o=e.PerformanceCounter||(e.PerformanceCounter={})),function(e){e.REQUESTS_DURATION="requests/duration",e.DEPENDENCIES_DURATION="dependencies/duration",e.EXCEPTIONS_COUNT="exceptions/count",e.TRACES_COUNT="traces/count"}(e.MetricId||(e.MetricId={})),e.PerformanceToQuickPulseCounter=((t={})[o.PROCESSOR_TIME]=n.PROCESSOR_TIME,t[o.REQUEST_RATE]=n.REQUEST_RATE,t[o.REQUEST_DURATION]=n.REQUEST_DURATION,t[n.COMMITTED_BYTES]=n.COMMITTED_BYTES,t[n.REQUEST_FAILURE_RATE]=n.REQUEST_FAILURE_RATE,t[n.DEPENDENCY_RATE]=n.DEPENDENCY_RATE,t[n.DEPENDENCY_FAILURE_RATE]=n.DEPENDENCY_FAILURE_RATE,t[n.DEPENDENCY_DURATION]=n.DEPENDENCY_DURATION,t[n.EXCEPTION_RATE]=n.EXCEPTION_RATE,t),e.QuickPulseDocumentType={Event:"Event",Exception:"Exception",Trace:"Trace",Metric:"Metric",Request:"Request",Dependency:"RemoteDependency",Availability:"Availability",PageView:"PageView"},e.QuickPulseType={Event:"EventTelemetryDocument",Exception:"ExceptionTelemetryDocument",Trace:"TraceTelemetryDocument",Metric:"MetricTelemetryDocument",Request:"RequestTelemetryDocument",Dependency:"DependencyTelemetryDocument",Availability:"AvailabilityTelemetryDocument",PageView:"PageViewTelemetryDocument"},e.TelemetryTypeStringToQuickPulseType={EventData:e.QuickPulseType.Event,ExceptionData:e.QuickPulseType.Exception,MessageData:e.QuickPulseType.Trace,MetricData:e.QuickPulseType.Metric,RequestData:e.QuickPulseType.Request,RemoteDependencyData:e.QuickPulseType.Dependency,AvailabilityData:e.QuickPulseType.Availability,PageViewData:e.QuickPulseType.PageView},e.TelemetryTypeStringToQuickPulseDocumentType={EventData:e.QuickPulseDocumentType.Event,ExceptionData:e.QuickPulseDocumentType.Exception,MessageData:e.QuickPulseDocumentType.Trace,MetricData:e.QuickPulseDocumentType.Metric,RequestData:e.QuickPulseDocumentType.Request,RemoteDependencyData:e.QuickPulseDocumentType.Dependency,AvailabilityData:e.QuickPulseDocumentType.Availability,PageViewData:e.QuickPulseDocumentType.PageView},e.SpanAttribute={HttpHost:"http.host",HttpMethod:"http.method",HttpPort:"http.port",HttpStatusCode:"http.status_code",HttpUrl:"http.url",HttpUserAgent:"http.user_agent",GrpcMethod:"grpc.method",GrpcService:"rpc.service"},e.DependencyTypeName={Grpc:"GRPC",Http:"HTTP",InProc:"InProc"},e.HeartBeatMetricName="HeartBeat"})),kr=b(((e,t)=>{"use strict";var r=n(857),o=Nr(),i=function(){function e(t,n,r){void 0===n&&(n=6e4),void 0===r&&(r=!1),this._lastIntervalRequestExecutionTime=0,this._lastIntervalDependencyExecutionTime=0,e.INSTANCE||(e.INSTANCE=this),this._isInitialized=!1,this._client=t,this._collectionInterval=n,this._enableLiveMetricsCounters=r}return e.prototype.enable=function(t,n){var o=this;this._isEnabled=t,this._isEnabled&&!this._isInitialized&&(this._isInitialized=!0),t?this._handle||(this._lastCpus=r.cpus(),this._lastRequests={totalRequestCount:e._totalRequestCount,totalFailedRequestCount:e._totalFailedRequestCount,time:+new Date},this._lastDependencies={totalDependencyCount:e._totalDependencyCount,totalFailedDependencyCount:e._totalFailedDependencyCount,time:+new Date},this._lastExceptions={totalExceptionCount:e._totalExceptionCount,time:+new Date},"function"==typeof process.cpuUsage&&(this._lastAppCpuUsage=process.cpuUsage()),this._lastHrtime=process.hrtime(),this._collectionInterval=n||this._collectionInterval,this._handle=setInterval((function(){return o.trackPerformance()}),this._collectionInterval),this._handle.unref()):this._handle&&(clearInterval(this._handle),this._handle=void 0)},e.countRequest=function(t,n){var r;if(e.isEnabled()){if("string"==typeof t)r=+new Date("1970-01-01T"+t+"Z");else{if("number"!=typeof t)return;r=t}e._intervalRequestExecutionTime+=r,!1===n&&e._totalFailedRequestCount++,e._totalRequestCount++}},e.countException=function(){e._totalExceptionCount++},e.countDependency=function(t,n){var r;if(e.isEnabled()){if("string"==typeof t)r=+new Date("1970-01-01T"+t+"Z");else{if("number"!=typeof t)return;r=t}e._intervalDependencyExecutionTime+=r,!1===n&&e._totalFailedDependencyCount++,e._totalDependencyCount++}},e.prototype.isInitialized=function(){return this._isInitialized},e.isEnabled=function(){return e.INSTANCE&&e.INSTANCE._isEnabled},e.prototype.trackPerformance=function(){this._trackCpu(),this._trackMemory(),this._trackNetwork(),this._trackDependencyRate(),this._trackExceptionRate()},e.prototype._trackCpu=function(){var e=r.cpus();if(e&&e.length&&this._lastCpus&&e.length===this._lastCpus.length){for(var t=0,n=0,i=0,s=0,a=0,c=0;e&&c<e.length;c++){var u=e[c],l=this._lastCpus[c],p=(u.model,u.speed,u.times),d=l.times;t+=p.user-d.user||0,n+=p.sys-d.sys||0,i+=p.nice-d.nice||0,s+=p.idle-d.idle||0,a+=p.irq-d.irq||0}var h=void 0;if("function"==typeof process.cpuUsage){var f=process.cpuUsage(),m=process.hrtime(),v=f.user-this._lastAppCpuUsage.user+(f.system-this._lastAppCpuUsage.system)||0;typeof this._lastHrtime<"u"&&2===this._lastHrtime.length&&(h=100*v/((1e6*(m[0]-this._lastHrtime[0])+(m[1]-this._lastHrtime[1])/1e3||0)*e.length)),this._lastAppCpuUsage=f,this._lastHrtime=m}var g=t+n+i+s+a||1;this._client.trackMetric({name:o.PerformanceCounter.PROCESSOR_TIME,value:(g-s)/g*100}),this._client.trackMetric({name:o.PerformanceCounter.PROCESS_TIME,value:h||t/g*100})}this._lastCpus=e},e.prototype._trackMemory=function(){var e=r.freemem(),t=process.memoryUsage().rss,n=r.totalmem()-e;this._client.trackMetric({name:o.PerformanceCounter.PRIVATE_BYTES,value:t}),this._client.trackMetric({name:o.PerformanceCounter.AVAILABLE_BYTES,value:e}),this._enableLiveMetricsCounters&&this._client.trackMetric({name:o.QuickPulseCounter.COMMITTED_BYTES,value:n})},e.prototype._trackNetwork=function(){var t=this._lastRequests,n={totalRequestCount:e._totalRequestCount,totalFailedRequestCount:e._totalFailedRequestCount,time:+new Date},r=n.totalRequestCount-t.totalRequestCount||0,i=n.totalFailedRequestCount-t.totalFailedRequestCount||0,s=n.time-t.time,a=s/1e3,c=(e._intervalRequestExecutionTime-this._lastIntervalRequestExecutionTime)/r||0;if(this._lastIntervalRequestExecutionTime=e._intervalRequestExecutionTime,s>0){var u=r/a,l=i/a;this._client.trackMetric({name:o.PerformanceCounter.REQUEST_RATE,value:u}),(!this._enableLiveMetricsCounters||r>0)&&this._client.trackMetric({name:o.PerformanceCounter.REQUEST_DURATION,value:c}),this._enableLiveMetricsCounters&&this._client.trackMetric({name:o.QuickPulseCounter.REQUEST_FAILURE_RATE,value:l})}this._lastRequests=n},e.prototype._trackDependencyRate=function(){if(this._enableLiveMetricsCounters){var t=this._lastDependencies,n={totalDependencyCount:e._totalDependencyCount,totalFailedDependencyCount:e._totalFailedDependencyCount,time:+new Date},r=n.totalDependencyCount-t.totalDependencyCount||0,i=n.totalFailedDependencyCount-t.totalFailedDependencyCount||0,s=n.time-t.time,a=s/1e3,c=(e._intervalDependencyExecutionTime-this._lastIntervalDependencyExecutionTime)/r||0;if(this._lastIntervalDependencyExecutionTime=e._intervalDependencyExecutionTime,s>0){var u=r/a,l=i/a;this._client.trackMetric({name:o.QuickPulseCounter.DEPENDENCY_RATE,value:u}),this._client.trackMetric({name:o.QuickPulseCounter.DEPENDENCY_FAILURE_RATE,value:l}),(!this._enableLiveMetricsCounters||r>0)&&this._client.trackMetric({name:o.QuickPulseCounter.DEPENDENCY_DURATION,value:c})}this._lastDependencies=n}},e.prototype._trackExceptionRate=function(){if(this._enableLiveMetricsCounters){var t=this._lastExceptions,n={totalExceptionCount:e._totalExceptionCount,time:+new Date},r=n.totalExceptionCount-t.totalExceptionCount||0,i=n.time-t.time;if(i>0){var s=r/(i/1e3);this._client.trackMetric({name:o.QuickPulseCounter.EXCEPTION_RATE,value:s})}this._lastExceptions=n}},e.prototype.dispose=function(){e.INSTANCE=null,this.enable(!1),this._isInitialized=!1},e._totalRequestCount=0,e._totalFailedRequestCount=0,e._totalDependencyCount=0,e._totalFailedDependencyCount=0,e._totalExceptionCount=0,e._intervalDependencyExecutionTime=0,e._intervalRequestExecutionTime=0,e}();t.exports=i})),Dr=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.AggregatedMetricCounter=void 0;e.AggregatedMetricCounter=function(e){this.dimensions=e,this.totalCount=0,this.lastTotalCount=0,this.intervalExecutionTime=0,this.lastTime=+new Date,this.lastIntervalExecutionTime=0}})),Mr=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.PreaggregatedMetricPropertyNames=void 0,e.PreaggregatedMetricPropertyNames={cloudRoleInstance:"cloud/roleInstance",cloudRoleName:"cloud/roleName",operationSynthetic:"operation/synthetic",requestSuccess:"Request.Success",requestResultCode:"request/resultCode",dependencyType:"Dependency.Type",dependencyTarget:"dependency/target",dependencySuccess:"Dependency.Success",dependencyResultCode:"dependency/resultCode",traceSeverityLevel:"trace/severityLevel"}})),Lr=b(((e,t)=>{"use strict";var n=e&&e.__assign||function(){return n=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},n.apply(this,arguments)},r=Nr(),o=Dr(),i=Mr(),s=function(){function e(t,n){void 0===n&&(n=6e4),e.INSTANCE||(e.INSTANCE=this),this._isInitialized=!1,e._dependencyCountersCollection=[],e._requestCountersCollection=[],e._exceptionCountersCollection=[],e._traceCountersCollection=[],this._client=t,this._collectionInterval=n}return e.prototype.enable=function(e,t){var n=this;this._isEnabled=e,this._isEnabled&&!this._isInitialized&&(this._isInitialized=!0),e?this._handle||(this._collectionInterval=t||this._collectionInterval,this._handle=setInterval((function(){return n.trackPreAggregatedMetrics()}),this._collectionInterval),this._handle.unref()):this._handle&&(clearInterval(this._handle),this._handle=void 0)},e.countException=function(t){e.isEnabled()&&e._getAggregatedCounter(t,this._exceptionCountersCollection).totalCount++},e.countTrace=function(t){e.isEnabled()&&e._getAggregatedCounter(t,this._traceCountersCollection).totalCount++},e.countRequest=function(t,n){if(e.isEnabled()){var r,o=e._getAggregatedCounter(n,this._requestCountersCollection);if("string"==typeof t)r=+new Date("1970-01-01T"+t+"Z");else{if("number"!=typeof t)return;r=t}o.intervalExecutionTime+=r,o.totalCount++}},e.countDependency=function(t,n){if(e.isEnabled()){var r,o=e._getAggregatedCounter(n,this._dependencyCountersCollection);if("string"==typeof t)r=+new Date("1970-01-01T"+t+"Z");else{if("number"!=typeof t)return;r=t}o.intervalExecutionTime+=r,o.totalCount++}},e.prototype.isInitialized=function(){return this._isInitialized},e.isEnabled=function(){return e.INSTANCE&&e.INSTANCE._isEnabled},e.prototype.trackPreAggregatedMetrics=function(){this._trackRequestMetrics(),this._trackDependencyMetrics(),this._trackExceptionMetrics(),this._trackTraceMetrics()},e._getAggregatedCounter=function(e,t){for(var n=!1,r=0;r<t.length;r++){if(e===t[r].dimensions)return t[r];if(Object.keys(e).length===Object.keys(t[r].dimensions).length){for(var i in e)if(e[i]!=t[r].dimensions[i]){n=!0;break}if(!n)return t[r];n=!1}}var s=new o.AggregatedMetricCounter(e);return t.push(s),s},e.prototype._trackRequestMetrics=function(){for(var t=0;t<e._requestCountersCollection.length;t++){var n=e._requestCountersCollection[t];n.time=+new Date;var o=n.totalCount-n.lastTotalCount||0,i=n.time-n.lastTime,s=(n.intervalExecutionTime-n.lastIntervalExecutionTime)/o||0;n.lastIntervalExecutionTime=n.intervalExecutionTime,i>0&&o>0&&this._trackPreAggregatedMetric({name:"Server response time",dimensions:n.dimensions,value:s,count:o,aggregationInterval:i,metricType:r.MetricId.REQUESTS_DURATION}),n.lastTotalCount=n.totalCount,n.lastTime=n.time}},e.prototype._trackDependencyMetrics=function(){for(var t=0;t<e._dependencyCountersCollection.length;t++){var n=e._dependencyCountersCollection[t];n.time=+new Date;var o=n.totalCount-n.lastTotalCount||0,i=n.time-n.lastTime,s=(n.intervalExecutionTime-n.lastIntervalExecutionTime)/o||0;n.lastIntervalExecutionTime=n.intervalExecutionTime,i>0&&o>0&&this._trackPreAggregatedMetric({name:"Dependency duration",dimensions:n.dimensions,value:s,count:o,aggregationInterval:i,metricType:r.MetricId.DEPENDENCIES_DURATION}),n.lastTotalCount=n.totalCount,n.lastTime=n.time}},e.prototype._trackExceptionMetrics=function(){for(var t=0;t<e._exceptionCountersCollection.length;t++){var n=e._exceptionCountersCollection[t],o=n.totalCount-n.lastTotalCount||0,i=n.time-n.lastTime;this._trackPreAggregatedMetric({name:"Exceptions",dimensions:n.dimensions,value:o,count:o,aggregationInterval:i,metricType:r.MetricId.EXCEPTIONS_COUNT}),n.lastTotalCount=n.totalCount,n.lastTime=n.time}},e.prototype._trackTraceMetrics=function(){for(var t=0;t<e._traceCountersCollection.length;t++){var n=e._traceCountersCollection[t],o=n.totalCount-n.lastTotalCount||0,i=n.time-n.lastTime;this._trackPreAggregatedMetric({name:"Traces",dimensions:n.dimensions,value:o,count:o,aggregationInterval:i,metricType:r.MetricId.TRACES_COUNT}),n.lastTotalCount=n.totalCount,n.lastTime=n.time}},e.prototype._trackPreAggregatedMetric=function(e){var t={};for(var r in e.dimensions)t[i.PreaggregatedMetricPropertyNames[r]]=e.dimensions[r];t=n(n({},t),{"_MS.MetricId":e.metricType,"_MS.AggregationIntervalMs":String(e.aggregationInterval),"_MS.IsAutocollected":"True"});var o={name:e.name,value:e.value,count:e.count,properties:t,kind:"Aggregation"};this._client.trackMetric(o)},e.prototype.dispose=function(){e.INSTANCE=null,this.enable(!1),this._isInitialized=!1},e}();t.exports=s})),jr=b(((e,t)=>{"use strict";var r=n(857),o=n(9896),i=n(6928),s=nr(),a=R(),c=function(){function e(e){this.keys=new s.ContextTagKeys,this.tags={},this._loadApplicationContext(e),this._loadDeviceContext(),this._loadInternalContext()}return e.prototype._loadApplicationContext=function(t){if(t=t||i.resolve(__dirname,"../../../../package.json"),!e.appVersion[t]){e.appVersion[t]="unknown";try{var n=JSON.parse(o.readFileSync(t,"utf8"));n&&"string"==typeof n.version&&(e.appVersion[t]=n.version)}catch(e){a.info("unable to read app version: ",e)}}this.tags[this.keys.applicationVersion]=e.appVersion[t]},e.prototype._loadDeviceContext=function(){this.tags[this.keys.deviceId]="",this.tags[this.keys.cloudRoleInstance]=r&&r.hostname(),this.tags[this.keys.deviceOSVersion]=r&&r.type()+" "+r.release(),this.tags[this.keys.cloudRole]=e.DefaultRoleName,this.tags["ai.device.osArchitecture"]=r&&r.arch(),this.tags["ai.device.osPlatform"]=r&&r.platform()},e.prototype._loadInternalContext=function(){var t=i.resolve(__dirname,"../../package.json");if(!e.sdkVersion){e.sdkVersion="unknown";try{var n=JSON.parse(o.readFileSync(t,"utf8"));n&&"string"==typeof n.version&&(e.sdkVersion=n.version)}catch(e){a.info("unable to read app version: ",e)}}this.tags[this.keys.internalSdkVersion]="node:"+e.sdkVersion},e.DefaultRoleName="Web",e.appVersion={},e.sdkVersion=null,e}();t.exports=c})),Ur=b(((e,t)=>{"use strict";var r,o=e&&e.__extends||(r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},r(e,t)},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=n(7016),s=nr(),a=un(),c=cn(),u=rr(),l=ln(),p=function(e){function t(n,r){var o=e.call(this)||this;return r&&r.method&&n&&(o.method=r.method,o.url=t._getUrlFromRequestOptions(n,r),o.startTime=+new Date),o}return o(t,e),t.prototype.onError=function(e){this._setStatus(void 0,e)},t.prototype.onResponse=function(e){this._setStatus(e.statusCode,void 0),this.correlationId=a.getCorrelationContextTarget(e,c.requestContextTargetKey)},t.prototype.getDependencyTelemetry=function(e,t){var n=i.parse(this.url);n.search=void 0,n.hash=void 0;var r=this.method.toUpperCase()+" "+n.pathname,o=s.RemoteDependencyDataConstants.TYPE_HTTP,a=n.hostname;n.port&&(a+=":"+n.port),this.correlationId?(o=s.RemoteDependencyDataConstants.TYPE_AI,this.correlationId!==l.correlationIdPrefix&&(a+=" | "+this.correlationId)):o=s.RemoteDependencyDataConstants.TYPE_HTTP;var c={id:t,name:r,data:this.url,duration:this.duration,success:this._isSuccess(),resultCode:this.statusCode?this.statusCode.toString():null,properties:this.properties||{},dependencyTypeName:o,target:a};if(e&&e.time?c.time=e.time:this.startTime&&(c.time=new Date(this.startTime)),e){for(var u in e)c[u]||(c[u]=e[u]);if(e.properties)for(var u in e.properties)c.properties[u]=e.properties[u]}return c},t._getUrlFromRequestOptions=function(e,t){if("string"==typeof e)if(0===e.indexOf("http://")||0===e.indexOf("https://"))e=i.parse(e);else{var n=i.parse(e);e="443"===n.host?i.parse("https://"+e):i.parse("http://"+e)}else{if(e&&"function"==typeof i.URL&&e instanceof i.URL)return i.format(e);var r=e;e={},r&&Object.keys(r).forEach((function(t){e[t]=r[t]}))}if(e.path){var o=i.parse(e.path);e.pathname=o.pathname,e.search=o.search}return e.host&&e.port&&!i.parse("http://"+e.host).port&&e.port&&(e.hostname=e.host,delete e.host),e.protocol=e.protocol||t.agent&&t.agent.protocol||t.protocol||void 0,e.hostname=e.hostname||"localhost",i.format(e)},t}(u);t.exports=p})),Fr=b((e=>{"use strict";var t=e&&e.__assign||function(){return t=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},t.apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.spanToTelemetryContract=void 0;var n=Re(),r=Nr();function o(e){var n=t({},e);return Object.keys(r.SpanAttribute).forEach((function(e){delete n[e]})),n}e.spanToTelemetryContract=function(e){var i="|"+e.spanContext().traceId+"."+e.spanContext().spanId+".",s=Math.round(1e3*e._duration[0]+e._duration[1]/1e6),a=e.attributes["peer.address"]?e.attributes["peer.address"].toString():"",c=e.attributes.component?e.attributes.component.toString():"",u=c.toUpperCase()===r.DependencyTypeName.Http||!!e.attributes[r.SpanAttribute.HttpUrl],l=c.toLowerCase()===r.DependencyTypeName.Grpc;if(u){var p=e.attributes[r.SpanAttribute.HttpMethod]||"GET",d=new URL(e.attributes[r.SpanAttribute.HttpUrl].toString()),h=e.attributes[r.SpanAttribute.HttpHost]||d.host,f=e.attributes[r.SpanAttribute.HttpPort]||d.port||null,m=p+" "+(d.pathname||"/"),v=r.DependencyTypeName.Http,g=f?(h+":"+f).toString():h.toString(),y=d.toString(),_=e.attributes[r.SpanAttribute.HttpStatusCode]||e.status.code||0;return{id:i,name:m,dependencyTypeName:v,target:g,data:y,success:_<400,duration:s,url:y,resultCode:String(_),properties:o(e.attributes)}}if(l){p=e.attributes[r.SpanAttribute.GrpcMethod]||"rpc";var b=e.attributes[r.SpanAttribute.GrpcService],E=b?p+" "+b:e.name;return{id:i,duration:s,name:E,target:b.toString(),data:b.toString()||E,url:b.toString()||E,dependencyTypeName:r.DependencyTypeName.Grpc,resultCode:String(e.status.code||0),success:0===e.status.code,properties:o(e.attributes)}}var T=e.name,S=e.links&&e.links.map((function(e){return{operation_Id:e.context.traceId,id:e.context.spanId}}));return{id:i,duration:s,name:T,target:a,data:a||T,url:a||T,dependencyTypeName:e.kind===n.SpanKind.INTERNAL?r.DependencyTypeName.InProc:c||e.name,resultCode:String(e.status.code||0),success:0===e.status.code,properties:t(t({},o(e.attributes)),{"_MS.links":S||void 0})}}})),zr=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.enable=e.subscriber=void 0;var t=Re(),n=D(),r=pn(),o=Fr(),i=P(),s=[];e.subscriber=function(e){var n=e.data,a=o.spanToTelemetryContract(n),c=n.spanContext(),u=new r;u.traceId=c.traceId,u.spanId=c.spanId,u.traceFlag=r.formatOpenTelemetryTraceFlags(c.traceFlags),u.parentId=n.parentSpanId?"|"+c.traceId+"."+n.parentSpanId+".":null,i.AsyncScopeManager.with(n,(function(){s.forEach((function(e){n.kind===t.SpanKind.SERVER?e.trackRequest(a):(n.kind===t.SpanKind.CLIENT||n.kind===t.SpanKind.INTERNAL)&&e.trackDependency(a)}))}))},e.enable=function(t,r){t?(0===s.length&&n.channel.subscribe("azure-coretracing",e.subscriber),s.push(r)):0===(s=s.filter((function(e){return e!=r}))).length&&n.channel.unsubscribe("azure-coretracing",e.subscriber)}})),qr=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.enable=e.subscriber=void 0;var t=D(),n=[];e.subscriber=function(e){"ismaster"!==e.data.event.commandName&&n.forEach((function(t){var n=e.data.startedData&&e.data.startedData.databaseName||"Unknown database";t.trackDependency({target:n,data:e.data.event.commandName,name:e.data.event.commandName,duration:e.data.event.duration,success:e.data.succeeded,resultCode:e.data.succeeded?"0":"1",time:e.data.startedData.time,dependencyTypeName:"mongodb"})}))},e.enable=function(r,o){r?(0===n.length&&t.channel.subscribe("mongodb",e.subscriber),n.push(o)):0===(n=n.filter((function(e){return e!=o}))).length&&t.channel.unsubscribe("mongodb",e.subscriber)}})),Br=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.enable=e.subscriber=void 0;var t=D(),n=[];e.subscriber=function(e){n.forEach((function(t){var n=e.data.query||{},r=n.sql||"Unknown query",o=!e.data.err,i=(n._connection||{}).config||{},s=i.socketPath?i.socketPath:(i.host||"localhost")+":"+i.port;t.trackDependency({target:s,data:r,name:r,duration:e.data.duration,success:o,resultCode:o?"0":"1",time:e.data.time,dependencyTypeName:"mysql"})}))},e.enable=function(r,o){r?(0===n.length&&t.channel.subscribe("mysql",e.subscriber),n.push(o)):0===(n=n.filter((function(e){return e!=o}))).length&&t.channel.unsubscribe("mysql",e.subscriber)}})),Hr=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.enable=e.subscriber=void 0;var t=D(),n=[];e.subscriber=function(e){n.forEach((function(t){"info"!==e.data.commandObj.command&&t.trackDependency({target:e.data.address,name:e.data.commandObj.command,data:e.data.commandObj.command,duration:e.data.duration,success:!e.data.err,resultCode:e.data.err?"1":"0",time:e.data.time,dependencyTypeName:"redis"})}))},e.enable=function(r,o){r?(0===n.length&&t.channel.subscribe("redis",e.subscriber),n.push(o)):0===(n=n.filter((function(e){return e!=o}))).length&&t.channel.unsubscribe("redis",e.subscriber)}})),Gr=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.enable=e.subscriber=void 0;var t=D(),n=[];e.subscriber=function(e){n.forEach((function(t){var n=e.data.query,r=n.preparable&&n.preparable.text||n.plan||n.text||"unknown query",o=!e.data.error,i=e.data.database.host+":"+e.data.database.port;t.trackDependency({target:i,data:r,name:r,duration:e.data.duration,success:o,resultCode:o?"0":"1",time:e.data.time,dependencyTypeName:"postgres"})}))},e.enable=function(r,o){r?(0===n.length&&t.channel.subscribe("postgres",e.subscriber),n.push(o)):0===(n=n.filter((function(e){return e!=o}))).length&&t.channel.unsubscribe("postgres",e.subscriber)}})),Vr=b(((e,t)=>{"use strict";var r=e&&e.__spreadArrays||function(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;var r=Array(e),o=0;for(t=0;t<n;t++)for(var i=arguments[t],s=0,a=i.length;s<a;s++,o++)r[o]=i[s];return r},o=n(8611),i=n(5692),s=R(),a=un(),c=cn(),u=Ur(),l=wr(),p=ln(),d=pn(),h=an(),f=function(){function e(t){if(e.INSTANCE)throw new Error("Client request tracking should be configured from the applicationInsights object");e.INSTANCE=this,this._client=t}return e.prototype.enable=function(e){this._isEnabled=e,this._isEnabled&&!this._isInitialized&&this._initialize(),h.IsInitialized&&(zr().enable(!0,this._client),qr().enable(e,this._client),Br().enable(e,this._client),Hr().enable(e,this._client),Gr().enable(e,this._client))},e.prototype.isInitialized=function(){return this._isInitialized},e.prototype._initialize=function(){var t=this;this._isInitialized=!0;var n=o.request,s=i.request,a=function(n,r){var o=!r[e.disableCollectionRequestOption]&&!n[e.alreadyAutoCollectedFlag];r.headers&&r.headers["user-agent"]&&-1!==r.headers["user-agent"].toString().indexOf("azsdk-js")&&(o=!1),n[e.alreadyAutoCollectedFlag]=!0,n&&r&&o&&(l.CorrelationContextManager.wrapEmitter(n),e.trackRequest(t._client,{options:r,request:n}))};o.request=function(e){for(var t=[],i=1;i<arguments.length;i++)t[i-1]=arguments[i];var s=n.call.apply(n,r([o,e],t));return a(s,e),s},i.request=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var o=s.call.apply(s,r([i,e],t));return a(o,e),o},o.get=function(e){for(var t,n=[],i=1;i<arguments.length;i++)n[i-1]=arguments[i];var s=(t=o.request).call.apply(t,r([o,e],n));return s.end(),s},i.get=function(e){for(var t,n=[],o=1;o<arguments.length;o++)n[o-1]=arguments[o];var s=(t=i.request).call.apply(t,r([i,e],n));return s.end(),s}},e.trackRequest=function(t,n){if(n.options&&n.request&&t){var r,o,i=new u(n.options,n.request),h=l.CorrelationContextManager.getCurrentContext();if(h&&h.operation&&h.operation.traceparent&&d.isValidTraceId(h.operation.traceparent.traceId)?(h.operation.traceparent.updateSpanId(),r=h.operation.traceparent.getBackCompatRequestId()):p.w3cEnabled?(o=(m=new d).toString(),r=m.getBackCompatRequestId()):r=h&&h.operation&&h.operation.parentId+e.requestNumber+++".",a.canIncludeCorrelationHeader(t,i.getUrl())&&n.request.getHeader&&n.request.setHeader&&t.config&&t.config.correlationId){var f=n.request.getHeader(c.requestContextHeader);try{a.safeIncludeCorrelationHeader(t,n.request,f)}catch(e){s.warn("Request-Context header could not be set. Correlation of requests may be lost",e)}if(h&&h.operation)try{if(n.request.setHeader(c.requestIdHeader,r),t.config.ignoreLegacyHeaders||(n.request.setHeader(c.parentIdHeader,h.operation.id),n.request.setHeader(c.rootIdHeader,r)),o||h.operation.traceparent)n.request.setHeader(c.traceparentHeader,o||h.operation.traceparent.toString());else if(p.w3cEnabled){var m=(new d).toString();n.request.setHeader(c.traceparentHeader,m)}if(h.operation.tracestate){var v=h.operation.tracestate.toString();v&&n.request.setHeader(c.traceStateHeader,v)}var g=h.customProperties.serializeToHeader();g&&n.request.setHeader(c.correlationContextHeader,g)}catch(e){s.warn("Correlation headers could not be set. Correlation of requests may be lost.",e)}}n.request.on&&(n.request.on("response",(function(e){i.onResponse(e);var o=i.getDependencyTelemetry(n,r);o.contextObjects=o.contextObjects||{},o.contextObjects["http.RequestOptions"]=n.options,o.contextObjects["http.ClientRequest"]=n.request,o.contextObjects["http.ClientResponse"]=e,t.trackDependency(o)})),n.request.on("error",(function(e){i.onError(e);var o=i.getDependencyTelemetry(n,r);o.contextObjects=o.contextObjects||{},o.contextObjects["http.RequestOptions"]=n.options,o.contextObjects["http.ClientRequest"]=n.request,o.contextObjects.Error=e,t.trackDependency(o)})),n.request.on("abort",(function(){i.onError(new Error);var e=i.getDependencyTelemetry(n,r);e.contextObjects=e.contextObjects||{},e.contextObjects["http.RequestOptions"]=n.options,e.contextObjects["http.ClientRequest"]=n.request,t.trackDependency(e)})))}else s.info("AutoCollectHttpDependencies.trackRequest was called with invalid parameters: ",!n.options,!n.request,!t)},e.prototype.dispose=function(){e.INSTANCE=null,this.enable(!1),this._isInitialized=!1},e.disableCollectionRequestOption="disableAppInsightsAutoCollection",e.requestNumber=1,e.alreadyAutoCollectedFlag="_appInsightsAutoCollected",e}();t.exports=f})),$r=b(((e,t)=>{"use strict";var r=n(857),o=Nr(),i=un(),s=jr(),a=Vr(),c=function(){function e(t){this._collectionInterval=9e5,this._vmData={},this._azInst_vmId="",this._azInst_subscriptionId="",this._azInst_osType="",e.INSTANCE||(e.INSTANCE=this),this._isInitialized=!1,this._client=t}return e.prototype.enable=function(e,t){var n=this;this._isEnabled=e,this._isEnabled&&!this._isInitialized&&(this._isInitialized=!0),e?this._handle||(this._handle=setInterval((function(){return n.trackHeartBeat(t,(function(){}))}),this._collectionInterval),this._handle.unref()):this._handle&&(clearInterval(this._handle),this._handle=null)},e.prototype.isInitialized=function(){return this._isInitialized},e.isEnabled=function(){return e.INSTANCE&&e.INSTANCE._isEnabled},e.prototype.trackHeartBeat=function(e,t){var n=this,i=!1,a={},c=s.sdkVersion;a.sdk=c,a.osType=r.type(),process.env.WEBSITE_SITE_NAME?(a.appSrv_SiteName=process.env.WEBSITE_SITE_NAME||"",a.appSrv_wsStamp=process.env.WEBSITE_HOME_STAMPNAME||"",a.appSrv_wsHost=process.env.WEBSITE_HOSTNAME||""):process.env.FUNCTIONS_WORKER_RUNTIME?a.azfunction_appId=process.env.WEBSITE_HOSTNAME:e&&(void 0===this._isVM?(i=!0,this._getAzureComputeMetadata(e,(function(){n._isVM&&Object.keys(n._vmData).length>0&&(a.azInst_vmId=n._vmData.vmId||"",a.azInst_subscriptionId=n._vmData.subscriptionId||"",a.azInst_osType=n._vmData.osType||"",n._azInst_vmId=n._vmData.vmId||"",n._azInst_subscriptionId=n._vmData.subscriptionId||"",n._azInst_osType=n._vmData.osType||""),n._client.trackMetric({name:o.HeartBeatMetricName,value:0,properties:a}),t()}))):this._isVM&&(a.azInst_vmId=this._azInst_vmId,a.azInst_subscriptionId=this._azInst_subscriptionId,a.azInst_osType=this._azInst_osType)),i||(this._client.trackMetric({name:o.HeartBeatMetricName,value:0,properties:a}),t())},e.prototype.dispose=function(){e.INSTANCE=null,this.enable(!1),this._isInitialized=!1},e.prototype._getAzureComputeMetadata=function(e,t){var n,r=this,o=((n={method:"GET"})[a.disableCollectionRequestOption]=!0,n.headers={Metadata:"True"},n),s=i.makeRequest(e,"http://169.254.169.254/metadata/instance/compute?api-version=2017-12-01&format=json",o,(function(e){if(200===e.statusCode){r._isVM=!0;var n="";e.on("data",(function(e){n+=e})),e.on("end",(function(){r._vmData=r._isJSON(n)?JSON.parse(n):{},t()}))}else t()}));s&&(s.on("error",(function(e){e&&e.message&&e.message.indexOf("ENETUNREACH")>-1&&(r._isVM=!1),t()})),s.end())},e.prototype._isJSON=function(e){try{return JSON.parse(e)&&!!e}catch{return!1}},e}();t.exports=c})),Kr=b(((e,t)=>{"use strict";var r=n(8611),o=n(5692),i=R(),s=un(),a=cn(),c=or(),u=wr(),l=kr(),p=function(){function e(t){if(e.INSTANCE)throw new Error("Server request tracking should be configured from the applicationInsights object");e.INSTANCE=this,this._client=t}return e.prototype.enable=function(e){this._isEnabled=e,(this._isAutoCorrelating||this._isEnabled||l.isEnabled())&&!this._isInitialized&&(this.useAutoCorrelation(this._isAutoCorrelating),this._initialize())},e.prototype.useAutoCorrelation=function(e,t){e&&!this._isAutoCorrelating?u.CorrelationContextManager.enable(t):!e&&this._isAutoCorrelating&&u.CorrelationContextManager.disable(),this._isAutoCorrelating=e},e.prototype.isInitialized=function(){return this._isInitialized},e.prototype.isAutoCorrelating=function(){return this._isAutoCorrelating},e.prototype._generateCorrelationContext=function(e){if(this._isAutoCorrelating)return u.CorrelationContextManager.generateContextObject(e.getOperationId(this._client.context.tags),e.getRequestId(),e.getOperationName(this._client.context.tags),e.getCorrelationContextHeader(),e.getTraceparent(),e.getTracestate())},e.prototype._initialize=function(){var t=this;this._isInitialized=!0;var n=function(n){if(n){if("function"!=typeof n)throw new Error("onRequest handler must be a function");return function(r,o){u.CorrelationContextManager.wrapEmitter(r),u.CorrelationContextManager.wrapEmitter(o);var i=r&&!r[e.alreadyAutoCollectedFlag];if(r&&i){var s=new c(r),a=t._generateCorrelationContext(s);u.CorrelationContextManager.runWithContext(a,(function(){t._isEnabled&&(r[e.alreadyAutoCollectedFlag]=!0,e.trackRequest(t._client,{request:r,response:o},s)),"function"==typeof n&&n(r,o)}))}else"function"==typeof n&&n(r,o)}}},i=function(e){var t=e.addListener.bind(e);e.addListener=function(e,r){switch(e){case"request":case"checkContinue":return t(e,n(r));default:return t(e,r)}},e.on=e.addListener},s=r.createServer;r.createServer=function(e,t){if(t&&"function"==typeof t){var r=s(e,n(t));return i(r),r}return r=s(n(e)),i(r),r};var a=o.createServer;o.createServer=function(e,t){var r=a(e,n(t));return i(r),r}},e.trackRequestSync=function(t,n){if(n.request&&n.response&&t){e.addResponseCorrelationIdHeader(t,n.response);var r=u.CorrelationContextManager.getCurrentContext(),o=new c(n.request,r&&r.operation.parentId);r&&(r.operation.id=o.getOperationId(t.context.tags)||r.operation.id,r.operation.name=o.getOperationName(t.context.tags)||r.operation.name,r.operation.parentId=o.getRequestId()||r.operation.parentId,r.customProperties.addHeaderData(o.getCorrelationContextHeader())),e.endRequest(t,o,n,n.duration,n.error)}else i.info("AutoCollectHttpRequests.trackRequestSync was called with invalid parameters: ",!n.request,!n.response,!t)},e.trackRequest=function(t,n,r){if(n.request&&n.response&&t){var o=u.CorrelationContextManager.getCurrentContext(),a=r||new c(n.request,o&&o.operation.parentId);s.canIncludeCorrelationHeader(t,a.getUrl())&&e.addResponseCorrelationIdHeader(t,n.response),o&&!r&&(o.operation.id=a.getOperationId(t.context.tags)||o.operation.id,o.operation.name=a.getOperationName(t.context.tags)||o.operation.name,o.operation.parentId=a.getOperationParentId(t.context.tags)||o.operation.parentId,o.customProperties.addHeaderData(a.getCorrelationContextHeader())),n.response.once&&n.response.once("finish",(function(){e.endRequest(t,a,n,null,null)})),n.request.on&&n.request.on("error",(function(r){e.endRequest(t,a,n,null,r)})),n.request.on&&n.request.on("aborted",(function(){e.endRequest(t,a,n,null,"The request has been aborted and the network socket has closed.")}))}else i.info("AutoCollectHttpRequests.trackRequest was called with invalid parameters: ",!n.request,!n.response,!t)},e.addResponseCorrelationIdHeader=function(e,t){if(e.config&&e.config.correlationId&&t.getHeader&&t.setHeader&&!t.headersSent){var n=t.getHeader(a.requestContextHeader);s.safeIncludeCorrelationHeader(e,t,n)}},e.endRequest=function(e,t,n,r,o){o?t.onError(o,r):t.onResponse(n.response,r);var i=t.getRequestTelemetry(n);if(i.tagOverrides=t.getRequestTags(e.context.tags),n.tagOverrides)for(var s in n.tagOverrides)i.tagOverrides[s]=n.tagOverrides[s];var a=t.getLegacyRootId();a&&(i.properties.ai_legacyRootId=a),i.contextObjects=i.contextObjects||{},i.contextObjects["http.ServerRequest"]=n.request,i.contextObjects["http.ServerResponse"]=n.response,e.trackRequest(i)},e.prototype.dispose=function(){e.INSTANCE=null,this.enable(!1),this._isInitialized=!1,u.CorrelationContextManager.disable(),this._isAutoCorrelating=!1},e.alreadyAutoCollectedFlag="_appInsightsAutoCollected",e}();t.exports=p})),Wr=b(((e,t)=>{"use strict";var r=e&&e.__assign||function(){return r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},r.apply(this,arguments)},o=n(857),i=nr(),s=Nr(),a=un(),c=R(),u=a.w3cTraceId(),l=function(){function e(){}return e.createQuickPulseEnvelope=function(e,t,n,r){var i=o&&"function"==typeof o.hostname&&o.hostname()||"Unknown",s=r.tags&&r.keys&&r.keys.cloudRoleInstance&&r.tags[r.keys.cloudRoleInstance]||i,a=r.tags&&r.keys&&r.keys.cloudRole&&r.tags[r.keys.cloudRole]||null;return{Documents:t.length>0?t:null,InstrumentationKey:n.instrumentationKey||"",Metrics:e.length>0?e:null,InvariantVersion:1,Timestamp:"/Date("+Date.now()+")/",Version:r.tags[r.keys.internalSdkVersion],StreamId:u,MachineName:i,Instance:s,RoleName:a}},e.createQuickPulseMetric=function(e){return{Name:e.name,Value:e.value,Weight:e.count||1}},e.telemetryEnvelopeToQuickPulseDocument=function(t){switch(t.data.baseType){case i.TelemetryTypeString.Event:return e.createQuickPulseEventDocument(t);case i.TelemetryTypeString.Exception:return e.createQuickPulseExceptionDocument(t);case i.TelemetryTypeString.Trace:return e.createQuickPulseTraceDocument(t);case i.TelemetryTypeString.Dependency:return e.createQuickPulseDependencyDocument(t);case i.TelemetryTypeString.Request:return e.createQuickPulseRequestDocument(t)}return null},e.createQuickPulseEventDocument=function(t){var n=e.createQuickPulseDocument(t),o=t.data.baseData.name;return r(r({},n),{Name:o})},e.createQuickPulseTraceDocument=function(t){var n=e.createQuickPulseDocument(t),o=t.data.baseData.severityLevel||0;return r(r({},n),{Message:t.data.baseData.message,SeverityLevel:i.SeverityLevel[o]})},e.createQuickPulseExceptionDocument=function(t){var n=e.createQuickPulseDocument(t),o=t.data.baseData.exceptions,i="",s="",a="";return o&&o.length>0&&(o[0].parsedStack&&o[0].parsedStack.length>0?o[0].parsedStack.forEach((function(e){i+=e.assembly+"\n"})):o[0].stack&&o[0].stack.length>0&&(i=o[0].stack),s=o[0].message,a=o[0].typeName),r(r({},n),{Exception:i,ExceptionMessage:s,ExceptionType:a})},e.createQuickPulseRequestDocument=function(t){var n=e.createQuickPulseDocument(t),o=t.data.baseData;return r(r({},n),{Name:o.name,Success:o.success,Duration:o.duration,ResponseCode:o.responseCode,OperationName:o.name})},e.createQuickPulseDependencyDocument=function(t){var n=e.createQuickPulseDocument(t),o=t.data.baseData;return r(r({},n),{Name:o.name,Target:o.target,Success:o.success,Duration:o.duration,ResultCode:o.resultCode,CommandName:o.data,OperationName:n.OperationId,DependencyTypeName:o.type})},e.createQuickPulseDocument=function(t){var n,r;return t.data.baseType?(r=s.TelemetryTypeStringToQuickPulseType[t.data.baseType],n=s.TelemetryTypeStringToQuickPulseDocumentType[t.data.baseType]):c.warn("Document type invalid; not sending live metric document",t.data.baseType),{DocumentType:n,__type:r,OperationId:t.tags[e.keys.operationId],Version:"1.0",Properties:e.aggregateProperties(t)}},e.aggregateProperties=function(e){var t=[],n=e.data.baseData.measurements||{};for(var r in n)if(n.hasOwnProperty(r)){var o={key:r,value:n[r]};t.push(o)}var i=e.data.baseData.properties||{};for(var r in i)i.hasOwnProperty(r)&&(o={key:r,value:i[r]},t.push(o));return t},e.keys=new i.ContextTagKeys,e}();t.exports=l})),Qr=b(((e,t)=>{"use strict";t.exports={getTransmissionTime:function(){return 1e4*(Date.now()+621355968e5)}}})),Yr=b(((e,t)=>{"use strict";var r=e&&e.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function s(e){try{c(r.next(e))}catch(e){i(e)}}function a(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){e.done?o(e.value):function(e){return e instanceof n?e:new n((function(t){t(e)}))}(e.value).then(s,a)}c((r=r.apply(e,t||[])).next())}))},o=e&&e.__generator||function(e,t){var n,r,o,i,s={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function a(i){return function(a){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return s.label++,{value:i[1],done:!1};case 5:s.label++,r=i[1],i=[0];continue;case 7:i=s.ops.pop(),s.trys.pop();continue;default:if(!(o=(o=s.trys).length>0&&o[o.length-1])&&(6===i[0]||2===i[0])){s=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){s.label=i[1];break}if(6===i[0]&&s.label<o[1]){s.label=o[1],o=i;break}if(o&&s.label<o[2]){s.label=o[2],s.ops.push(i);break}o[2]&&s.ops.pop(),s.trys.pop();continue}i=t.call(e,s)}catch(e){i=[6,e],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,a])}}},i=n(5692),s=Vr(),a=R(),c=Qr(),u=un(),l="x-ms-qps-service-polling-interval-hint",p="x-ms-qps-service-endpoint-redirect",d=function(){function e(e){this._config=e,this._consecutiveErrors=0}return e.prototype.ping=function(e,t,n){var r=[{name:"x-ms-qps-stream-id",value:e.StreamId},{name:"x-ms-qps-machine-name",value:e.MachineName},{name:"x-ms-qps-role-name",value:e.RoleName},{name:"x-ms-qps-instance-name",value:e.Instance},{name:"x-ms-qps-invariant-version",value:e.InvariantVersion.toString()}];this._submitData(e,t,n,"ping",r)},e.prototype.post=function(e,t,n){return r(this,void 0,void 0,(function(){return o(this,(function(r){switch(r.label){case 0:return[4,this._submitData([e],t,n,"post")];case 1:return r.sent(),[2]}}))}))},e.prototype._submitData=function(e,t,n,a,d){return r(this,void 0,void 0,(function(){var r,h,f,m,v,g=this;return o(this,(function(o){return r=JSON.stringify(e),(m={})[s.disableCollectionRequestOption]=!0,m.host=t&&t.length>0?t:this._config.quickPulseHost,m.method="POST",m.path="/QuickPulseService.svc/"+a+"?ikey="+this._config.instrumentationKey,m.headers=((v={Expect:"100-continue"})["x-ms-qps-transmission-time"]=c.getTransmissionTime(),v["Content-Type"]="application/json",v["Content-Length"]=Buffer.byteLength(r),v),h=m,d&&d.length>0&&d.forEach((function(e){return h.headers[e.name]=e.value})),this._config.httpsAgent?h.agent=this._config.httpsAgent:h.agent=u.tlsRestrictedAgent,(f=i.request(h,(function(e){if(200==e.statusCode){var t="true"===e.headers["x-ms-qps-subscribed"],r=e.headers[p]?e.headers[p].toString():null,o=e.headers[l]?parseInt(e.headers[l].toString()):null;g._consecutiveErrors=0,n(t,e,r,o)}else g._onError("StatusCode:"+e.statusCode+" StatusMessage:"+e.statusMessage),n()}))).on("error",(function(e){g._onError(e),n()})),f.write(r),f.end(),[2]}))}))},e.prototype._onError=function(t){this._consecutiveErrors++;var n="Transient error connecting to the Live Metrics endpoint. This packet will not appear in your Live Metrics Stream. Error:";this._consecutiveErrors%e.MAX_QPS_FAILURES_BEFORE_WARN==0?(n="Live Metrics endpoint could not be reached "+this._consecutiveErrors+" consecutive times. Most recent error:",a.warn(e.TAG,n,t)):a.info(e.TAG,n,t)},e.TAG="QuickPulseSender",e.MAX_QPS_FAILURES_BEFORE_WARN=25,e}();t.exports=d})),Xr=b(((e,t)=>{"use strict";var n=e&&e.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function s(e){try{c(r.next(e))}catch(e){i(e)}}function a(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){e.done?o(e.value):function(e){return e instanceof n?e:new n((function(t){t(e)}))}(e.value).then(s,a)}c((r=r.apply(e,t||[])).next())}))},r=e&&e.__generator||function(e,t){var n,r,o,i,s={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function a(i){return function(a){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return s.label++,{value:i[1],done:!1};case 5:s.label++,r=i[1],i=[0];continue;case 7:i=s.ops.pop(),s.trys.pop();continue;default:if(!(o=(o=s.trys).length>0&&o[o.length-1])&&(6===i[0]||2===i[0])){s=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){s.label=i[1];break}if(6===i[0]&&s.label<o[1]){s.label=o[1],o=i;break}if(o&&s.label<o[2]){s.label=o[2],s.ops.push(i);break}o[2]&&s.ops.pop(),s.trys.pop();continue}i=t.call(e,s)}catch(e){i=[6,e],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,a])}}},o=R(),i=Wr(),s=Yr(),a=Nr(),c=jr(),u=function(){function e(e,t){this._isCollectingData=!1,this._lastSuccessTime=Date.now(),this._lastSendSucceeded=!0,this._metrics={},this._documents=[],this._collectors=[],this._redirectedHost=null,this._pollingIntervalHint=-1,this.config=e,this.context=t||new c,this._sender=new s(this.config),this._isEnabled=!1}return e.prototype.addCollector=function(e){this._collectors.push(e)},e.prototype.trackMetric=function(e){this._addMetric(e)},e.prototype.addDocument=function(e){var t=i.telemetryEnvelopeToQuickPulseDocument(e);t&&this._documents.push(t)},e.prototype.enable=function(e){e&&!this._isEnabled?(this._isEnabled=!0,this._goQuickPulse()):!e&&this._isEnabled&&(this._isEnabled=!1,clearTimeout(this._handle),this._handle=void 0)},e.prototype.enableCollectors=function(e){this._collectors.forEach((function(t){t.enable(e)}))},e.prototype._addMetric=function(e){var t=e.value,n=e.count||1,r=a.PerformanceToQuickPulseCounter[e.name];r&&(this._metrics[r]?(this._metrics[r].Value=(this._metrics[r].Value*this._metrics[r].Weight+t*n)/(this._metrics[r].Weight+n),this._metrics[r].Weight+=n):(this._metrics[r]=i.createQuickPulseMetric(e),this._metrics[r].Name=r,this._metrics[r].Weight=1))},e.prototype._resetQuickPulseBuffer=function(){delete this._metrics,this._metrics={},this._documents.length=0},e.prototype._goQuickPulse=function(){return n(this,void 0,void 0,(function(){var t,n,o,s,a=this;return r(this,(function(r){switch(r.label){case 0:return t=Object.keys(this._metrics).map((function(e){return a._metrics[e]})),n=i.createQuickPulseEnvelope(t,this._documents.slice(),this.config,this.context),this._resetQuickPulseBuffer(),this._isCollectingData?[4,this._post(n)]:[3,2];case 1:return r.sent(),[3,3];case 2:this._ping(n),r.label=3;case 3:return o=this._pollingIntervalHint>0?this._pollingIntervalHint:e.PING_INTERVAL,s=this._isCollectingData?e.POST_INTERVAL:o,this._isCollectingData&&Date.now()-this._lastSuccessTime>=e.MAX_POST_WAIT_TIME&&!this._lastSendSucceeded?(this._isCollectingData=!1,s=e.FALLBACK_INTERVAL):!this._isCollectingData&&Date.now()-this._lastSuccessTime>=e.MAX_PING_WAIT_TIME&&!this._lastSendSucceeded&&(s=e.FALLBACK_INTERVAL),this._lastSendSucceeded=null,this._handle=setTimeout(this._goQuickPulse.bind(this),s),this._handle.unref(),[2]}}))}))},e.prototype._ping=function(e){this._sender.ping(e,this._redirectedHost,this._quickPulseDone.bind(this))},e.prototype._post=function(e){return n(this,void 0,void 0,(function(){return r(this,(function(t){switch(t.label){case 0:return[4,this._sender.post(e,this._redirectedHost,this._quickPulseDone.bind(this))];case 1:return t.sent(),[2]}}))}))},e.prototype._quickPulseDone=function(e,t,n,r){null!=e?(this._isCollectingData!==e&&(o.info("Live Metrics sending data",e),this.enableCollectors(e)),this._isCollectingData=e,n&&n.length>0&&(this._redirectedHost=n,o.info("Redirecting endpoint to: ",n)),r&&r>0&&(this._pollingIntervalHint=r),t&&t.statusCode<300&&t.statusCode>=200?(this._lastSuccessTime=Date.now(),this._lastSendSucceeded=!0):this._lastSendSucceeded=!1):this._lastSendSucceeded=!1},e.MAX_POST_WAIT_TIME=2e4,e.MAX_PING_WAIT_TIME=6e4,e.FALLBACK_INTERVAL=6e4,e.PING_INTERVAL=5e3,e.POST_INTERVAL=1e3,e}();t.exports=u})),Jr=b(((e,t)=>{"use strict";var n=Nr(),r=function(){function e(){}return e.parse=function(t){if(!t)return{};var r=t.split(e._FIELDS_SEPARATOR).reduce((function(t,n){var r=n.split(e._FIELD_KEY_VALUE_SEPARATOR);if(2===r.length){var o=r[0].toLowerCase(),i=r[1];t[o]=i}return t}),{});if(Object.keys(r).length>0){if(r.endpointsuffix){var o=r.location?r.location+".":"";r.ingestionendpoint=r.ingestionendpoint||"https://"+o+"dc."+r.endpointsuffix,r.liveendpoint=r.liveendpoint||"https://"+o+"live."+r.endpointsuffix}r.ingestionendpoint=r.ingestionendpoint||n.DEFAULT_BREEZE_ENDPOINT,r.liveendpoint=r.liveendpoint||n.DEFAULT_LIVEMETRICS_ENDPOINT}return r},e._FIELDS_SEPARATOR=";",e._FIELD_KEY_VALUE_SEPARATOR="=",e}();t.exports=r})),Zr=b(((e,t)=>{"use strict";var r=ln(),o=Jr(),i=(R(),Nr()),s=n(7016),a=function(){function e(t){var n=this;this.endpointBase=i.DEFAULT_BREEZE_ENDPOINT;var r=process.env[e.ENV_connectionString],a=o.parse(t),c=o.parse(r),u=!a.instrumentationkey&&Object.keys(a).length>0?null:t;this.instrumentationKey=a.instrumentationkey||u||c.instrumentationkey||e._getInstrumentationKey(),e._validateInstrumentationKey(this.instrumentationKey),this.endpointUrl=(a.ingestionendpoint||c.ingestionendpoint||this.endpointBase)+"/v2.1/track",this.maxBatchSize=250,this.maxBatchIntervalMs=15e3,this.disableAppInsights=!1,this.samplingPercentage=100,this.correlationIdRetryIntervalMs=3e4,this.correlationHeaderExcludedDomains=["*.core.windows.net","*.core.chinacloudapi.cn","*.core.cloudapi.de","*.core.usgovcloudapi.net","*.core.microsoft.scloud","*.core.eaglex.ic.gov"],this.setCorrelationId=function(e){return n.correlationId=e},this.proxyHttpUrl=process.env[e.ENV_http_proxy]||void 0,this.proxyHttpsUrl=process.env[e.ENV_https_proxy]||void 0,this.httpAgent=void 0,this.httpsAgent=void 0,this.profileQueryEndpoint=a.ingestionendpoint||c.ingestionendpoint||process.env[e.ENV_profileQueryEndpoint]||this.endpointBase,this._quickPulseHost=a.liveendpoint||c.liveendpoint||process.env[e.ENV_quickPulseHost]||i.DEFAULT_LIVEMETRICS_HOST,this._quickPulseHost.match(/^https?:\/\//)&&(this._quickPulseHost=s.parse(this._quickPulseHost).host)}return Object.defineProperty(e.prototype,"profileQueryEndpoint",{get:function(){return this._profileQueryEndpoint},set:function(e){r.cancelCorrelationIdQuery(this,this.setCorrelationId),this._profileQueryEndpoint=e,this.correlationId=r.correlationIdPrefix,r.queryCorrelationId(this,this.setCorrelationId)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"quickPulseHost",{get:function(){return this._quickPulseHost},set:function(e){this._quickPulseHost=e},enumerable:!1,configurable:!0}),e._getInstrumentationKey=function(){var t=process.env[e.ENV_iKey]||process.env[e.ENV_azurePrefix+e.ENV_iKey]||process.env[e.legacy_ENV_iKey]||process.env[e.ENV_azurePrefix+e.legacy_ENV_iKey];if(!t||""==t)throw new Error("Instrumentation key not found, pass the key in the config to this method or set the key in the environment variable APPINSIGHTS_INSTRUMENTATIONKEY before starting the server");return t},e._validateInstrumentationKey=function(e){return new RegExp("^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$").test(e)},e.ENV_azurePrefix="APPSETTING_",e.ENV_iKey="APPINSIGHTS_INSTRUMENTATIONKEY",e.legacy_ENV_iKey="APPINSIGHTS_INSTRUMENTATION_KEY",e.ENV_profileQueryEndpoint="APPINSIGHTS_PROFILE_QUERY_ENDPOINT",e.ENV_quickPulseHost="APPINSIGHTS_QUICKPULSE_HOST",e.ENV_connectionString="APPLICATIONINSIGHTS_CONNECTION_STRING",e.ENV_nativeMetricsDisablers="APPLICATION_INSIGHTS_DISABLE_EXTENDED_METRIC",e.ENV_nativeMetricsDisableAll="APPLICATION_INSIGHTS_DISABLE_ALL_EXTENDED_METRICS",e.ENV_http_proxy="http_proxy",e.ENV_https_proxy="https_proxy",e}();t.exports=a})),eo=b((e=>{"use strict";var t=e&&e.__assign||function(){return t=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},t.apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.AutoCollectNativePerformance=void 0;var r=Zr(),o=jr(),i=R(),s=function(){function e(t){this._disabledMetrics={},e.INSTANCE&&e.INSTANCE.dispose(),e.INSTANCE=this,this._client=t}return e.isNodeVersionCompatible=function(){var e=process.versions.node.split(".");return parseInt(e[0])>=6},e.prototype.enable=function(t,r,o){var s=this;if(void 0===r&&(r={}),void 0===o&&(o=6e4),e.isNodeVersionCompatible()){if(null==e._metricsAvailable&&t&&!this._isInitialized)try{var a=n(4597);e._emitter=new a,e._metricsAvailable=!0,i.info("Native metrics module successfully loaded!")}catch{return void(e._metricsAvailable=!1)}this._isEnabled=t,this._disabledMetrics=r,this._isEnabled&&!this._isInitialized&&(this._isInitialized=!0),this._isEnabled&&e._emitter?(e._emitter.enable(!0,o),this._handle||(this._handle=setInterval((function(){return s._trackNativeMetrics()}),o),this._handle.unref())):e._emitter&&(e._emitter.enable(!1),this._handle&&(clearInterval(this._handle),this._handle=void 0))}},e.prototype.dispose=function(){this.enable(!1)},e.parseEnabled=function(e){var n=process.env[r.ENV_nativeMetricsDisableAll],o=process.env[r.ENV_nativeMetricsDisablers];if(n)return{isEnabled:!1,disabledMetrics:{}};if(o){var i=o.split(","),s={};if(i.length>0)for(var a=0,c=i;a<c.length;a++)s[c[a]]=!0;return"object"==typeof e?{isEnabled:!0,disabledMetrics:t(t({},e),s)}:{isEnabled:e,disabledMetrics:s}}return"boolean"==typeof e?{isEnabled:e,disabledMetrics:{}}:{isEnabled:!0,disabledMetrics:e}},e.prototype._trackNativeMetrics=function(){var e=!0;"object"!=typeof this._isEnabled&&(e=this._isEnabled),e&&(this._trackGarbageCollection(),this._trackEventLoop(),this._trackHeapUsage())},e.prototype._trackGarbageCollection=function(){var t;if(!this._disabledMetrics.gc){var n=e._emitter.getGCData();for(var r in n){var i=n[r].metrics,s=r+" Garbage Collection Duration",a=Math.sqrt(i.sumSquares/i.count-Math.pow(i.total/i.count,2))||0;this._client.trackMetric({name:s,value:i.total,count:i.count,max:i.max,min:i.min,stdDev:a,tagOverrides:(t={},t[this._client.context.keys.internalSdkVersion]="node-nativeperf:"+o.sdkVersion,t)})}}},e.prototype._trackEventLoop=function(){var t;if(!this._disabledMetrics.loop){var n=e._emitter.getLoopData().loopUsage;if(0!=n.count){var r=Math.sqrt(n.sumSquares/n.count-Math.pow(n.total/n.count,2))||0;this._client.trackMetric({name:"Event Loop CPU Time",value:n.total,count:n.count,min:n.min,max:n.max,stdDev:r,tagOverrides:(t={},t[this._client.context.keys.internalSdkVersion]="node-nativeperf:"+o.sdkVersion,t)})}}},e.prototype._trackHeapUsage=function(){var e,t,n;if(!this._disabledMetrics.heap){var r=process.memoryUsage(),i=r.heapUsed,s=r.heapTotal,a=r.rss;this._client.trackMetric({name:"Memory Usage (Heap)",value:i,count:1,tagOverrides:(e={},e[this._client.context.keys.internalSdkVersion]="node-nativeperf:"+o.sdkVersion,e)}),this._client.trackMetric({name:"Memory Total (Heap)",value:s,count:1,tagOverrides:(t={},t[this._client.context.keys.internalSdkVersion]="node-nativeperf:"+o.sdkVersion,t)}),this._client.trackMetric({name:"Memory Usage (Non-Heap)",value:a-s,count:1,tagOverrides:(n={},n[this._client.context.keys.internalSdkVersion]="node-nativeperf:"+o.sdkVersion,n)})}},e}();e.AutoCollectNativePerformance=s})),to=b(((e,t)=>{"use strict";var n=R(),r=function(){function e(e,t,n,r){this._buffer=[],this._lastSend=0,this._isDisabled=e,this._getBatchSize=t,this._getBatchIntervalMs=n,this._sender=r}return e.prototype.setUseDiskRetryCaching=function(e,t,n){this._sender.setDiskRetryMode(e,t,n)},e.prototype.send=function(e){var t=this;if(!this._isDisabled()){if(!e)return void n.warn("Cannot send null/undefined telemetry");if(this._buffer.push(e),this._buffer.length>=this._getBatchSize())return void this.triggerSend(!1);!this._timeoutHandle&&this._buffer.length>0&&(this._timeoutHandle=setTimeout((function(){t._timeoutHandle=null,t.triggerSend(!1)}),this._getBatchIntervalMs()))}},e.prototype.triggerSend=function(e,t){var n=this._buffer.length<1;n||(e?(this._sender.saveOnCrash(this._buffer),"function"==typeof t&&t("data saved on crash")):this._sender.send(this._buffer,t)),this._lastSend=+new Date,this._buffer=[],clearTimeout(this._timeoutHandle),this._timeoutHandle=null,n&&"function"==typeof t&&t("no data to send")},e}();t.exports=r})),no=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.azureRoleEnvironmentTelemetryProcessor=void 0,e.azureRoleEnvironmentTelemetryProcessor=function(e,t){process.env.WEBSITE_SITE_NAME&&(e.tags[t.keys.cloudRole]=process.env.WEBSITE_SITE_NAME)}})),ro=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getSamplingHashCode=e.samplingTelemetryProcessor=void 0;var t=nr();function n(e){var t=2147483647,n=5381;if(!e)return 0;for(;e.length<8;)e+=e;for(var r=0;r<e.length;r++)n=((n<<5)+n|0)+e.charCodeAt(r)|0;return(n=n<=-2147483648?t:Math.abs(n))/t*100}e.samplingTelemetryProcessor=function(e,r){var o=e.sampleRate;return!!(null==o||o>=100||e.data&&t.TelemetryType.Metric===t.baseTypeToTelemetryType(e.data.baseType))||(r.correlationContext&&r.correlationContext.operation?n(r.correlationContext.operation.id)<o:100*Math.random()<o)},e.getSamplingHashCode=n})),oo=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.performanceMetricsTelemetryProcessor=void 0;var t=kr(),n=nr();e.performanceMetricsTelemetryProcessor=function(e,r){switch(r&&r.addDocument(e),e.data.baseType){case n.TelemetryTypeString.Exception:t.countException();break;case n.TelemetryTypeString.Request:var o=e.data.baseData;t.countRequest(o.duration,o.success);break;case n.TelemetryTypeString.Dependency:var i=e.data.baseData;t.countDependency(i.duration,i.success)}return!0}})),io=b((e=>{"use strict";var t=e&&e.__assign||function(){return t=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},t.apply(this,arguments)};Object.defineProperty(e,"__esModule",{value:!0}),e.preAggregatedMetricsTelemetryProcessor=void 0;var n=nr(),r=Lr(),o=nr();e.preAggregatedMetricsTelemetryProcessor=function(e,i){if(r.isEnabled())switch(e.data.baseType){case o.TelemetryTypeString.Exception:var s=e.data.baseData;s.properties=t(t({},s.properties),{"_MS.ProcessedByMetricExtractors":"(Name:'Exceptions', Ver:'1.1')"});var a={cloudRoleInstance:e.tags[i.keys.cloudRoleInstance],cloudRoleName:e.tags[i.keys.cloudRole]};r.countException(a);break;case o.TelemetryTypeString.Trace:var c=e.data.baseData;c.properties=t(t({},c.properties),{"_MS.ProcessedByMetricExtractors":"(Name:'Traces', Ver:'1.1')"});var u={cloudRoleInstance:e.tags[i.keys.cloudRoleInstance],cloudRoleName:e.tags[i.keys.cloudRole],traceSeverityLevel:n.SeverityLevel[c.severity]};r.countTrace(u);break;case o.TelemetryTypeString.Request:var l=e.data.baseData;l.properties=t(t({},l.properties),{"_MS.ProcessedByMetricExtractors":"(Name:'Requests', Ver:'1.1')"});var p={cloudRoleInstance:e.tags[i.keys.cloudRoleInstance],cloudRoleName:e.tags[i.keys.cloudRole],operationSynthetic:e.tags[i.keys.operationSyntheticSource],requestSuccess:l.success,requestResultCode:l.responseCode};r.countRequest(l.duration,p);break;case o.TelemetryTypeString.Dependency:var d=e.data.baseData;d.properties=t(t({},d.properties),{"_MS.ProcessedByMetricExtractors":"(Name:'Dependencies', Ver:'1.1')"});var h={cloudRoleInstance:e.tags[i.keys.cloudRoleInstance],cloudRoleName:e.tags[i.keys.cloudRole],operationSynthetic:e.tags[i.keys.operationSyntheticSource],dependencySuccess:d.success,dependencyType:d.type,dependencyTarget:d.target,dependencyResultCode:d.resultCode};r.countDependency(d.duration,h)}return!0}})),so=b((e=>{"use strict";var t=e&&e.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=e&&e.__exportStar||function(e,n){for(var r in e)"default"!==r&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(no(),e),n(ro(),e),n(oo(),e),n(io(),e)})),ao=b(((e,t)=>{"use strict";var r=e&&e.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function s(e){try{c(r.next(e))}catch(e){i(e)}}function a(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){e.done?o(e.value):function(e){return e instanceof n?e:new n((function(t){t(e)}))}(e.value).then(s,a)}c((r=r.apply(e,t||[])).next())}))},o=e&&e.__generator||function(e,t){var n,r,o,i,s={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function a(i){return function(a){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return s.label++,{value:i[1],done:!1};case 5:s.label++,r=i[1],i=[0];continue;case 7:i=s.ops.pop(),s.trys.pop();continue;default:if(!(o=(o=s.trys).length>0&&o[o.length-1])&&(6===i[0]||2===i[0])){s=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){s.label=i[1];break}if(6===i[0]&&s.label<o[1]){s.label=o[1],o=i;break}if(o&&s.label<o[2]){s.label=o[2],s.ops.push(i);break}o[2]&&s.ops.pop(),s.trys.pop();continue}i=t.call(e,s)}catch(e){i=[6,e],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,a])}}},i=n(9896),s=n(857),a=n(6928),c=n(3106),u=n(5317),l=R(),p=Vr(),d=un(),h=function(){function e(t,n,r){if(this._redirectedHost=null,this._config=t,this._onSuccess=n,this._onError=r,this._enableDiskRetryMode=!1,this._resendInterval=e.WAIT_BETWEEN_RESEND,this._maxBytesOnDisk=e.MAX_BYTES_ON_DISK,this._numConsecutiveFailures=0,this._numConsecutiveRedirects=0,this._resendTimer=null,this._fileCleanupTimer=null,this._tempDir=a.join(s.tmpdir(),e.TEMPDIR_PREFIX+this._config.instrumentationKey),!e.OS_PROVIDES_FILE_PROTECTION)if(e.USE_ICACLS){try{e.OS_PROVIDES_FILE_PROTECTION=i.existsSync(e.ICACLS_PATH)}catch{}e.OS_PROVIDES_FILE_PROTECTION||l.warn(e.TAG,"Could not find ICACLS in expected location! This is necessary to use disk retry mode on Windows.")}else e.OS_PROVIDES_FILE_PROTECTION=!0}return e.prototype.setDiskRetryMode=function(t,n,r){var o=this;this._enableDiskRetryMode=e.OS_PROVIDES_FILE_PROTECTION&&t,"number"==typeof n&&n>=0&&(this._resendInterval=Math.floor(n)),"number"==typeof r&&r>=0&&(this._maxBytesOnDisk=Math.floor(r)),t&&!e.OS_PROVIDES_FILE_PROTECTION&&(this._enableDiskRetryMode=!1,l.warn(e.TAG,"Ignoring request to enable disk retry mode. Sufficient file protection capabilities were not detected.")),this._enableDiskRetryMode?this._fileCleanupTimer||(this._fileCleanupTimer=setTimeout((function(){o._fileCleanupTask()}),e.CLEANUP_TIMEOUT),this._fileCleanupTimer.unref()):this._fileCleanupTimer&&clearTimeout(this._fileCleanupTimer)},e.prototype.send=function(t,n){return r(this,void 0,void 0,(function(){var r,i,s,a,u=this;return o(this,(function(o){return t&&(r=this._redirectedHost||this._config.endpointUrl,i={method:"POST",withCredentials:!1,headers:{"Content-Type":"application/x-json-stream"}},s="",t.forEach((function(e){var t=u._stringify(e);"string"==typeof t&&(s+=t+"\n")})),s.length>0&&(s=s.substring(0,s.length-1)),a=Buffer.from?Buffer.from(s):new Buffer(s),c.gzip(a,(function(o,s){var c=s;o?(l.warn(o),c=a,i.headers["Content-Length"]=a.length.toString()):(i.headers["Content-Encoding"]="gzip",i.headers["Content-Length"]=s.length.toString()),l.info(e.TAG,i),i[p.disableCollectionRequestOption]=!0;var h=d.makeRequest(u._config,r,i,(function(r){r.setEncoding("utf-8");var o="";r.on("data",(function(e){o+=e})),r.on("end",(function(){if(u._numConsecutiveFailures=0,u._enableDiskRetryMode)if(200===r.statusCode)u._resendTimer||(u._resendTimer=setTimeout((function(){u._resendTimer=null,u._sendFirstFileOnDisk()}),u._resendInterval),u._resendTimer.unref());else if(u._isRetriable(r.statusCode))try{var i=JSON.parse(o),s=[];i.errors.forEach((function(e){u._isRetriable(e.statusCode)&&s.push(t[e.index])})),s.length>0&&u._storeToDisk(s)}catch{u._storeToDisk(t)}if(307===r.statusCode||308===r.statusCode)if(u._numConsecutiveRedirects++,u._numConsecutiveRedirects<10){var a=r.headers.location?r.headers.location.toString():null;a&&(u._redirectedHost=a,u.send(t,n))}else"function"==typeof n&&n("Error sending telemetry because of circular redirects.");else u._numConsecutiveRedirects=0,"function"==typeof n&&n(o),l.info(e.TAG,o),"function"==typeof u._onSuccess&&u._onSuccess(o)}))}));h.on("error",(function(r){if(u._numConsecutiveFailures++,!u._enableDiskRetryMode||u._numConsecutiveFailures>0&&u._numConsecutiveFailures%e.MAX_CONNECTION_FAILURES_BEFORE_WARN==0){var o="Ingestion endpoint could not be reached. This batch of telemetry items has been lost. Use Disk Retry Caching to enable resending of failed telemetry. Error:";u._enableDiskRetryMode&&(o="Ingestion endpoint could not be reached "+u._numConsecutiveFailures+" consecutive times. There may be resulting telemetry loss. Most recent error:"),l.warn(e.TAG,o,d.dumpObj(r))}else o="Transient failure to reach ingestion endpoint. This batch of telemetry items will be retried. Error:",l.info(e.TAG,o,d.dumpObj(r));u._onErrorHelper(r),"function"==typeof n&&(r&&n(d.dumpObj(r)),n("Error sending telemetry")),u._enableDiskRetryMode&&u._storeToDisk(t)})),h.write(c),h.end()}))),[2]}))}))},e.prototype.saveOnCrash=function(e){this._enableDiskRetryMode&&this._storeToDiskSync(this._stringify(e))},e.prototype._isRetriable=function(e){return 206===e||408===e||429===e||439===e||500===e||503===e},e.prototype._runICACLS=function(t,n){var r=u.spawn(e.ICACLS_PATH,t,{windowsHide:!0});r.on("error",(function(e){return n(e)})),r.on("close",(function(e,t){return n(0===e?null:new Error("Setting ACL restrictions did not succeed (ICACLS returned code "+e+")"))}))},e.prototype._runICACLSSync=function(t){if(!u.spawnSync)throw new Error("Could not synchronously call ICACLS under current version of Node.js");var n=u.spawnSync(e.ICACLS_PATH,t,{windowsHide:!0});if(n.error)throw n.error;if(0!==n.status)throw new Error("Setting ACL restrictions did not succeed (ICACLS returned code "+n.status+")")},e.prototype._getACLIdentity=function(t){if(e.ACL_IDENTITY)return t(null,e.ACL_IDENTITY);var n=u.spawn(e.POWERSHELL_PATH,["-Command","[System.Security.Principal.WindowsIdentity]::GetCurrent().Name"],{windowsHide:!0,stdio:["ignore","pipe","pipe"]}),r="";n.stdout.on("data",(function(e){return r+=e})),n.on("error",(function(e){return t(e,null)})),n.on("close",(function(n,o){return e.ACL_IDENTITY=r&&r.trim(),t(0===n?null:new Error("Getting ACL identity did not succeed (PS returned code "+n+")"),e.ACL_IDENTITY)}))},e.prototype._getACLIdentitySync=function(){if(e.ACL_IDENTITY)return e.ACL_IDENTITY;if(u.spawnSync){var t=u.spawnSync(e.POWERSHELL_PATH,["-Command","[System.Security.Principal.WindowsIdentity]::GetCurrent().Name"],{windowsHide:!0,stdio:["ignore","pipe","pipe"]});if(t.error)throw t.error;if(0!==t.status)throw new Error("Getting ACL identity did not succeed (PS returned code "+t.status+")");return e.ACL_IDENTITY=t.stdout&&t.stdout.toString().trim(),e.ACL_IDENTITY}throw new Error("Could not synchronously get ACL identity under current version of Node.js")},e.prototype._getACLArguments=function(e,t){return[e,"/grant","*S-1-5-32-544:(OI)(CI)F","/grant",t+":(OI)(CI)F","/inheritance:r"]},e.prototype._applyACLRules=function(t,n){var r=this;return e.USE_ICACLS?void 0!==e.ACLED_DIRECTORIES[t]?n(e.ACLED_DIRECTORIES[t]?null:new Error("Setting ACL restrictions did not succeed (cached result)")):(e.ACLED_DIRECTORIES[t]=!1,void this._getACLIdentity((function(o,i){if(o)return e.ACLED_DIRECTORIES[t]=!1,n(o);r._runICACLS(r._getACLArguments(t,i),(function(r){return e.ACLED_DIRECTORIES[t]=!r,n(r)}))}))):n(null)},e.prototype._applyACLRulesSync=function(t){if(e.USE_ICACLS){if(void 0===e.ACLED_DIRECTORIES[t])return this._runICACLSSync(this._getACLArguments(t,this._getACLIdentitySync())),void(e.ACLED_DIRECTORIES[t]=!0);if(!e.ACLED_DIRECTORIES[t])throw new Error("Setting ACL restrictions did not succeed (cached result)")}},e.prototype._confirmDirExists=function(e,t){var n=this;i.lstat(e,(function(r,o){r&&"ENOENT"===r.code?i.mkdir(e,(function(r){r&&"EEXIST"!==r.code?t(r):n._applyACLRules(e,t)})):!r&&o.isDirectory()?n._applyACLRules(e,t):t(r||new Error("Path existed but was not a directory"))}))},e.prototype._getShallowDirectorySize=function(e,t){i.readdir(e,(function(n,r){if(n)return t(n,-1);var o=null,s=0,c=0;if(0!==r.length)for(var u=0;u<r.length;u++)i.stat(a.join(e,r[u]),(function(e,n){c++,e?o=e:n.isFile()&&(s+=n.size),c===r.length&&t(o,o?-1:s)}));else t(null,0)}))},e.prototype._getShallowDirectorySizeSync=function(e){for(var t=i.readdirSync(e),n=0,r=0;r<t.length;r++)n+=i.statSync(a.join(e,t[r])).size;return n},e.prototype._storeToDisk=function(t){var n=this;l.info(e.TAG,"Checking existence of data storage directory: "+this._tempDir),this._confirmDirExists(this._tempDir,(function(r){if(r)return l.warn(e.TAG,"Error while checking/creating directory: "+(r&&r.message)),void n._onErrorHelper(r);n._getShallowDirectorySize(n._tempDir,(function(r,o){if(r||o<0)return l.warn(e.TAG,"Error while checking directory size: "+(r&&r.message)),void n._onErrorHelper(r);if(o>n._maxBytesOnDisk)l.warn(e.TAG,"Not saving data due to max size limit being met. Directory size in bytes is: "+o);else{var s=(new Date).getTime()+".ai.json",c=a.join(n._tempDir,s);l.info(e.TAG,"saving data to disk at: "+c),i.writeFile(c,n._stringify(t),{mode:384},(function(e){return n._onErrorHelper(e)}))}}))}))},e.prototype._storeToDiskSync=function(t){try{l.info(e.TAG,"Checking existence of data storage directory: "+this._tempDir),i.existsSync(this._tempDir)||i.mkdirSync(this._tempDir),this._applyACLRulesSync(this._tempDir);var n=this._getShallowDirectorySizeSync(this._tempDir);if(n>this._maxBytesOnDisk)return void l.info(e.TAG,"Not saving data due to max size limit being met. Directory size in bytes is: "+n);var r=(new Date).getTime()+".ai.json",o=a.join(this._tempDir,r);l.info(e.TAG,"saving data before crash to disk at: "+o),i.writeFileSync(o,t,{mode:384})}catch(t){l.warn(e.TAG,"Error while saving data to disk: "+(t&&t.message)),this._onErrorHelper(t)}},e.prototype._sendFirstFileOnDisk=function(){var e=this;i.exists(this._tempDir,(function(t){t&&i.readdir(e._tempDir,(function(t,n){if(t)e._onErrorHelper(t);else if((n=n.filter((function(e){return a.basename(e).indexOf(".ai.json")>-1}))).length>0){var r=n[0],o=a.join(e._tempDir,r);i.readFile(o,(function(t,n){t?e._onErrorHelper(t):i.unlink(o,(function(t){if(t)e._onErrorHelper(t);else try{var r=JSON.parse(n.toString());e.send(r)}catch(e){l.warn("Failed to read persisted file",e)}}))}))}}))}))},e.prototype._onErrorHelper=function(e){"function"==typeof this._onError&&this._onError(e)},e.prototype._stringify=function(e){try{return JSON.stringify(e)}catch(t){l.warn("Failed to serialize payload",t,e)}},e.prototype._fileCleanupTask=function(){var t=this;i.exists(this._tempDir,(function(n){n&&i.readdir(t._tempDir,(function(n,r){n?t._onErrorHelper(n):(r=r.filter((function(e){return a.basename(e).indexOf(".ai.json")>-1}))).length>0&&r.forEach((function(n){var r=new Date(parseInt(n.split(".ai.json")[0]));if(new Date(+new Date-e.FILE_RETEMPTION_PERIOD)>r){var o=a.join(t._tempDir,n);i.unlink(o,(function(e){e&&t._onErrorHelper(e)}))}}))}))}))},e.TAG="Sender",e.ICACLS_PATH=process.env.systemdrive+"/windows/system32/icacls.exe",e.POWERSHELL_PATH=process.env.systemdrive+"/windows/system32/windowspowershell/v1.0/powershell.exe",e.ACLED_DIRECTORIES={},e.ACL_IDENTITY=null,e.WAIT_BETWEEN_RESEND=6e4,e.MAX_BYTES_ON_DISK=52428800,e.MAX_CONNECTION_FAILURES_BEFORE_WARN=5,e.CLEANUP_TIMEOUT=36e5,e.FILE_RETEMPTION_PERIOD=6048e5,e.TEMPDIR_PREFIX="appInsights-node",e.OS_PROVIDES_FILE_PROTECTION=!1,e.USE_ICACLS="Windows_NT"===s.type(),e}();t.exports=h})),co=b(((e,t)=>{"use strict";var n=nr(),r=un(),o=wr(),i=function(){function e(){}return e.createEnvelope=function(t,o,i,s,a){var c=null;switch(o){case n.TelemetryType.Trace:c=e.createTraceData(t);break;case n.TelemetryType.Dependency:c=e.createDependencyData(t);break;case n.TelemetryType.Event:c=e.createEventData(t);break;case n.TelemetryType.Exception:c=e.createExceptionData(t);break;case n.TelemetryType.Request:c=e.createRequestData(t);break;case n.TelemetryType.Metric:c=e.createMetricData(t);break;case n.TelemetryType.Availability:c=e.createAvailabilityData(t);break;case n.TelemetryType.PageView:c=e.createPageViewData(t)}if(i&&n.domainSupportsProperties(c.baseData)){if(c&&c.baseData)if(c.baseData.properties)for(var u in i)c.baseData.properties[u]||(c.baseData.properties[u]=i[u]);else c.baseData.properties=i;c.baseData.properties=r.validateStringMap(c.baseData.properties)}var l=a&&a.instrumentationKey||"",p=new n.Envelope;return p.data=c,p.iKey=l,p.name="Microsoft.ApplicationInsights."+l.replace(/-/g,"")+"."+c.baseType.substr(0,c.baseType.length-4),p.tags=this.getTags(s,t.tagOverrides),p.time=(new Date).toISOString(),p.ver=1,p.sampleRate=a?a.samplingPercentage:100,o===n.TelemetryType.Metric&&(p.sampleRate=100),p},e.createTraceData=function(e){var t=new n.MessageData;t.message=e.message,t.properties=e.properties,isNaN(e.severity)?t.severityLevel=n.SeverityLevel.Information:t.severityLevel=e.severity;var r=new n.Data;return r.baseType=n.telemetryTypeToBaseType(n.TelemetryType.Trace),r.baseData=t,r},e.createDependencyData=function(e){var t=new n.RemoteDependencyData;"string"==typeof e.name&&(t.name=e.name.length>1024?e.name.slice(0,1021)+"...":e.name),t.data=e.data,t.target=e.target,t.duration=r.msToTimeSpan(e.duration),t.success=e.success,t.type=e.dependencyTypeName,t.properties=e.properties,t.resultCode=e.resultCode?e.resultCode+"":"",e.id?t.id=e.id:t.id=r.w3cTraceId();var o=new n.Data;return o.baseType=n.telemetryTypeToBaseType(n.TelemetryType.Dependency),o.baseData=t,o},e.createEventData=function(e){var t=new n.EventData;t.name=e.name,t.properties=e.properties,t.measurements=e.measurements;var r=new n.Data;return r.baseType=n.telemetryTypeToBaseType(n.TelemetryType.Event),r.baseData=t,r},e.createExceptionData=function(e){var t=new n.ExceptionData;t.properties=e.properties,isNaN(e.severity)?t.severityLevel=n.SeverityLevel.Error:t.severityLevel=e.severity,t.measurements=e.measurements,t.exceptions=[];var o=e.exception.stack,i=new n.ExceptionDetails;i.message=e.exception.message,i.typeName=e.exception.name,i.parsedStack=this.parseStack(o),i.hasFullStack=r.isArray(i.parsedStack)&&i.parsedStack.length>0,t.exceptions.push(i);var s=new n.Data;return s.baseType=n.telemetryTypeToBaseType(n.TelemetryType.Exception),s.baseData=t,s},e.createRequestData=function(e){var t=new n.RequestData;e.id?t.id=e.id:t.id=r.w3cTraceId(),t.name=e.name,t.url=e.url,t.source=e.source,t.duration=r.msToTimeSpan(e.duration),t.responseCode=e.resultCode?e.resultCode+"":"",t.success=e.success,t.properties=e.properties;var o=new n.Data;return o.baseType=n.telemetryTypeToBaseType(n.TelemetryType.Request),o.baseData=t,o},e.createMetricData=function(e){var t=new n.MetricData;t.metrics=[];var r=new n.DataPoint;r.count=isNaN(e.count)?1:e.count,r.kind=n.DataPointType.Aggregation,r.max=isNaN(e.max)?e.value:e.max,r.min=isNaN(e.min)?e.value:e.min,r.name=e.name,r.stdDev=isNaN(e.stdDev)?0:e.stdDev,r.value=e.value,t.metrics.push(r),t.properties=e.properties;var o=new n.Data;return o.baseType=n.telemetryTypeToBaseType(n.TelemetryType.Metric),o.baseData=t,o},e.createAvailabilityData=function(e){var t=new n.AvailabilityData;e.id?t.id=e.id:t.id=r.w3cTraceId(),t.name=e.name,t.duration=r.msToTimeSpan(e.duration),t.success=e.success,t.runLocation=e.runLocation,t.message=e.message,t.measurements=e.measurements,t.properties=e.properties;var o=new n.Data;return o.baseType=n.telemetryTypeToBaseType(n.TelemetryType.Availability),o.baseData=t,o},e.createPageViewData=function(e){var t=new n.PageViewData;t.name=e.name,t.duration=r.msToTimeSpan(e.duration),t.url=e.url,t.measurements=e.measurements,t.properties=e.properties;var o=new n.Data;return o.baseType=n.telemetryTypeToBaseType(n.TelemetryType.PageView),o.baseData=t,o},e.getTags=function(e,t){var n=o.CorrelationContextManager.getCurrentContext(),r={};if(e&&e.tags)for(var i in e.tags)r[i]=e.tags[i];if(t)for(var i in t)r[i]=t[i];return n&&(r[e.keys.operationId]=r[e.keys.operationId]||n.operation.id,r[e.keys.operationName]=r[e.keys.operationName]||n.operation.name,r[e.keys.operationParentId]=r[e.keys.operationParentId]||n.operation.parentId),r},e.parseStack=function(e){var t=void 0;if("string"==typeof e){var n=e.split("\n");t=[];for(var r=0,o=0,i=0;i<=n.length;i++){var a=n[i];if(s.regex.test(a)){var c=new s(n[i],r++);o+=c.sizeInBytes,t.push(c)}}if(o>32768)for(var u=0,l=t.length-1,p=0,d=u,h=l;u<l;){if((p+=t[u].sizeInBytes+t[l].sizeInBytes)>32768){var f=h-d+1;t.splice(d,f);break}d=u,h=l,u++,l--}}return t},e}(),s=function(){function e(t,n){this.sizeInBytes=0,this.level=n,this.method="<no_method>",this.assembly=r.trim(t);var o=t.match(e.regex);o&&o.length>=5&&(this.method=r.trim(o[2])||this.method,this.fileName=r.trim(o[4])||"<no_filename>",this.line=parseInt(o[5])||0),this.sizeInBytes+=this.method.length,this.sizeInBytes+=this.fileName.length,this.sizeInBytes+=this.assembly.length,this.sizeInBytes+=e.baseSize,this.sizeInBytes+=this.level.toString().length,this.sizeInBytes+=this.line.toString().length}return e.regex=/^(\s+at)?(.*?)(\@|\s\(|\s)([^\(\n]+):(\d+):(\d+)(\)?)$/,e.baseSize=58,e}();t.exports=i})),uo=b(((e,t)=>{"use strict";var r=n(7016),o=Zr(),i=jr(),s=nr(),a=to(),c=so(),u=wr(),l=ao(),p=un(),d=R(),h=co(),f=function(){function e(e){this._telemetryProcessors=[],this._enableAzureProperties=!1;var t=new o(e);this.config=t,this.context=new i,this.commonProperties={};var n=new l(this.config);this.channel=new a((function(){return t.disableAppInsights}),(function(){return t.maxBatchSize}),(function(){return t.maxBatchIntervalMs}),n)}return e.prototype.trackAvailability=function(e){this.track(e,s.TelemetryType.Availability)},e.prototype.trackPageView=function(e){this.track(e,s.TelemetryType.PageView)},e.prototype.trackTrace=function(e){this.track(e,s.TelemetryType.Trace)},e.prototype.trackMetric=function(e){this.track(e,s.TelemetryType.Metric)},e.prototype.trackException=function(e){e&&e.exception&&!p.isError(e.exception)&&(e.exception=new Error(e.exception.toString())),this.track(e,s.TelemetryType.Exception)},e.prototype.trackEvent=function(e){this.track(e,s.TelemetryType.Event)},e.prototype.trackRequest=function(e){this.track(e,s.TelemetryType.Request)},e.prototype.trackDependency=function(e){e&&!e.target&&e.data&&(e.target=r.parse(e.data).host),this.track(e,s.TelemetryType.Dependency)},e.prototype.flush=function(e){this.channel.triggerSend(!!e&&!!e.isAppCrashing,e?e.callback:void 0)},e.prototype.track=function(e,t){if(e&&s.telemetryTypeToBaseType(t)){var n=h.createEnvelope(e,t,this.commonProperties,this.context,this.config);e.time&&(n.time=e.time.toISOString()),this._enableAzureProperties&&c.azureRoleEnvironmentTelemetryProcessor(n,this.context);var r=this.runTelemetryProcessors(n,e.contextObjects);r=r&&c.samplingTelemetryProcessor(n,{correlationContext:u.CorrelationContextManager.getCurrentContext()}),c.preAggregatedMetricsTelemetryProcessor(n,this.context),r&&(c.performanceMetricsTelemetryProcessor(n,this.quickPulseClient),this.channel.send(n))}else d.warn("track() requires telemetry object and telemetryType to be specified.")},e.prototype.setAutoPopulateAzureProperties=function(e){this._enableAzureProperties=e},e.prototype.addTelemetryProcessor=function(e){this._telemetryProcessors.push(e)},e.prototype.clearTelemetryProcessors=function(){this._telemetryProcessors=[]},e.prototype.runTelemetryProcessors=function(e,t){var n=!0,r=this._telemetryProcessors.length;if(0===r)return n;(t=t||{}).correlationContext=u.CorrelationContextManager.getCurrentContext();for(var o=0;o<r;++o)try{var i=this._telemetryProcessors[o];if(i&&!1===i.apply(null,[e,t])){n=!1;break}}catch(t){n=!0,d.warn("One of telemetry processors failed, telemetry item will be sent.",t,e)}return n&&(e&&e.tags&&(e.tags=p.validateStringMap(e.tags)),e&&e.data&&e.data.baseData&&e.data.baseData.properties&&(e.data.baseData.properties=p.validateStringMap(e.data.baseData.properties))),n},e}();t.exports=f})),lo=b(((e,t)=>{"use strict";var n,r=e&&e.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},n(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),o=uo(),i=Kr(),s=Vr(),a=R(),c=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return r(t,e),t.prototype.trackNodeHttpRequestSync=function(e){e&&e.request&&e.response&&e.duration?i.trackRequestSync(this,e):a.warn("trackNodeHttpRequestSync requires NodeHttpRequestTelemetry object with request, response and duration specified.")},t.prototype.trackNodeHttpRequest=function(e){(e.duration||e.error)&&a.warn("trackNodeHttpRequest will ignore supplied duration and error parameters. These values are collected from the request and response objects."),e&&e.request&&e.response?i.trackRequest(this,e):a.warn("trackNodeHttpRequest requires NodeHttpRequestTelemetry object with request and response specified.")},t.prototype.trackNodeHttpDependency=function(e){e&&e.request?s.trackRequest(this,e):a.warn("trackNodeHttpDependency requires NodeHttpDependencyTelemetry object with request specified.")},t}(o);t.exports=c})),po=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})})),ho=b((e=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.dispose=e.Configuration=e.wrapWithCorrelationContext=e.startOperation=e.getCorrelationContext=e.start=e.setup=e.liveMetricsClient=e.defaultClient=e.DistributedTracingModes=void 0;var t,n,r=wr(),o=Pr(),i=Or(),s=kr(),a=Lr(),c=$r(),u=Vr(),l=Kr(),p=ln(),d=R(),h=Xr(),f=eo();e.TelemetryClient=lo(),e.Contracts=nr(),e.azureFunctionsTypes=po(),(n=t=e.DistributedTracingModes||(e.DistributedTracingModes={}))[n.AI=0]="AI",n[n.AI_AND_W3C=1]="AI_AND_W3C";var m,v,g,y,_,b,E,T,S,C,x,w=!0,A=!1,I=!0,P=!0,O=!0,N=!1,k=!0,D=!0,M=!0,L=!0,j=!1,U=!0,F=void 0,z=void 0,q=!1;function B(){return e.defaultClient?(q=!0,g.enable(w,A),y.enable(I),_.enable(P),b.enable(O),E.enable(N,e.defaultClient.config),T.enable(U,v),S.useAutoCorrelation(L,m),S.enable(k),C.enable(D),e.liveMetricsClient&&j&&e.liveMetricsClient.enable(j)):d.warn("Start cannot be called before setup"),H}e.setup=function(t){return e.defaultClient?d.info("The default client is already setup"):(e.defaultClient=new e.TelemetryClient(t),g=new o(e.defaultClient),y=new i(e.defaultClient),_=new s(e.defaultClient),b=new a(e.defaultClient),E=new c(e.defaultClient),S=new l(e.defaultClient),C=new u(e.defaultClient),T||(T=new f.AutoCollectNativePerformance(e.defaultClient))),e.defaultClient&&e.defaultClient.channel&&e.defaultClient.channel.setUseDiskRetryCaching(M,F,z),H},e.start=B,e.getCorrelationContext=function(){return L?r.CorrelationContextManager.getCurrentContext():null},e.startOperation=function(e,t){return r.CorrelationContextManager.startOperation(e,t)},e.wrapWithCorrelationContext=function(e,t){return r.CorrelationContextManager.wrapCallback(e,t)};var H=function(){function n(){}return n.setDistributedTracingMode=function(e){return p.w3cEnabled=e===t.AI_AND_W3C,n},n.setAutoCollectConsole=function(e,t){return void 0===t&&(t=!1),w=e,A=t,q&&g.enable(e,t),n},n.setAutoCollectExceptions=function(e){return I=e,q&&y.enable(e),n},n.setAutoCollectPerformance=function(e,t){void 0===t&&(t=!0),P=e;var r=f.AutoCollectNativePerformance.parseEnabled(t);return U=r.isEnabled,v=r.disabledMetrics,q&&(_.enable(e),T.enable(r.isEnabled,r.disabledMetrics)),n},n.setAutoCollectPreAggregatedMetrics=function(e){return O=e,q&&b.enable(e),n},n.setAutoCollectHeartbeat=function(t){return N=t,q&&E.enable(t,e.defaultClient.config),n},n.setAutoCollectRequests=function(e){return k=e,q&&S.enable(e),n},n.setAutoCollectDependencies=function(e){return D=e,q&&C.enable(e),n},n.setAutoDependencyCorrelation=function(e,t){return L=e,m=t,q&&S.useAutoCorrelation(e,t),n},n.setUseDiskRetryCaching=function(t,r,o){return M=t,F=r,z=o,e.defaultClient&&e.defaultClient.channel&&e.defaultClient.channel.setUseDiskRetryCaching(t,r,o),n},n.setInternalLogging=function(e,t){return void 0===e&&(e=!1),void 0===t&&(t=!0),d.enableDebug=e,d.disableWarnings=!t,n},n.setSendLiveMetrics=function(t){return void 0===t&&(t=!1),e.defaultClient?(!e.liveMetricsClient&&t?(e.liveMetricsClient=new h(e.defaultClient.config,null),x=new s(e.liveMetricsClient,1e3,!0),e.liveMetricsClient.addCollector(x),e.defaultClient.quickPulseClient=e.liveMetricsClient):e.liveMetricsClient&&e.liveMetricsClient.enable(t),j=t,n):(d.warn("Live metrics client cannot be setup without the default client"),n)},n.start=B,n}();e.Configuration=H,e.dispose=function(){p.w3cEnabled=!0,e.defaultClient=null,q=!1,g&&g.dispose(),y&&y.dispose(),_&&_.dispose(),b&&b.dispose(),E&&E.dispose(),T&&T.dispose(),S&&S.dispose(),C&&C.dispose(),e.liveMetricsClient&&(e.liveMetricsClient.enable(!1),j=!1,e.liveMetricsClient=void 0)}})),fo={};((e,t)=>{for(var n in t)c(e,n,{get:t[n],enumerable:!0})})(fo,{default:()=>Eo}),e.exports=(s=fo,E(c({},"__esModule",{value:!0}),s));var mo=T(n(857)),vo=T(n(1398)),go=T(n(5692)),yo=class{constructor(e){this.vscodeAPI=e}getTelemetryLevel(){try{let e=this.vscodeAPI.env.telemetryConfiguration;return e.isUsageEnabled&&e.isErrorsEnabled&&e.isCrashEnabled?"on":e.isErrorsEnabled&&e.isCrashEnabled?"error":"off"}catch{return void 0!==this.vscodeAPI.env.isTelemetryEnabled?this.vscodeAPI.env.isTelemetryEnabled?"on":"off":this.vscodeAPI.workspace.getConfiguration("telemetry").get("enableTelemetry")?"on":"off"}}static applyReplacements(e,t){for(let n of Object.keys(e))for(let r of t)r.lookup.test(n)&&(void 0!==r.replacementString?e[n]=r.replacementString:delete e[n])}static shouldUseOneDataSystemSDK(e){return 74===e.length&&"-"===e[32]&&"-"===e[41]&&"-"===e[46]&&"-"===e[51]&&"-"===e[56]&&"-"===e[69]}static getInstance(e){return yo._instance||(yo._instance=new yo(e)),yo._instance}},_o=class{constructor(e,t,n,r,o,i){this.extensionId=e,this.extensionVersion=t,this.telemetryAppender=n,this.osShim=r,this.vscodeAPI=o,this.firstParty=!1,this.userOptIn=!1,this.errorOptIn=!1,this.disposables=[],this.firstParty=!!i,this.updateUserOptStatus(),void 0!==o.env.onDidChangeTelemetryEnabled?(this.disposables.push(o.env.onDidChangeTelemetryEnabled((()=>this.updateUserOptStatus()))),this.disposables.push(o.workspace.onDidChangeConfiguration((()=>this.updateUserOptStatus())))):this.disposables.push(o.workspace.onDidChangeConfiguration((()=>this.updateUserOptStatus())))}updateUserOptStatus(){let e=yo.getInstance(this.vscodeAPI).getTelemetryLevel();this.userOptIn="on"===e,this.errorOptIn="error"===e||this.userOptIn,(this.userOptIn||this.errorOptIn)&&this.telemetryAppender.instantiateAppender()}cleanRemoteName(e){if(!e)return"none";let t="other";return["ssh-remote","dev-container","attached-container","wsl","codespaces"].forEach((n=>{0===e.indexOf(`${n}`)&&(t=n)})),t}get extension(){return void 0===this._extension&&(this._extension=this.vscodeAPI.extensions.getExtension(this.extensionId)),this._extension}cloneAndChange(e,t){if(null===e||"object"!=typeof e||"function"!=typeof t)return e;let n={};for(let r in e)n[r]=t(r,e[r]);return n}shouldSendErrorTelemetry(){return!(!1===this.errorOptIn||this.firstParty&&this.vscodeAPI.env.remoteName&&"other"===this.cleanRemoteName(this.vscodeAPI.env.remoteName))}getCommonProperties(){let e={};if(e["common.os"]=this.osShim.platform,e["common.nodeArch"]=this.osShim.architecture,e["common.platformversion"]=(this.osShim.release||"").replace(/^(\d+)(\.\d+)?(\.\d+)?(.*)/,"$1$2$3"),e["common.extname"]=this.extensionId,e["common.extversion"]=this.extensionVersion,this.vscodeAPI&&this.vscodeAPI.env){switch(e["common.vscodemachineid"]=this.vscodeAPI.env.machineId,e["common.vscodesessionid"]=this.vscodeAPI.env.sessionId,e["common.vscodeversion"]=this.vscodeAPI.version,e["common.isnewappinstall"]=this.vscodeAPI.env.isNewAppInstall?this.vscodeAPI.env.isNewAppInstall.toString():"false",e["common.product"]=this.vscodeAPI.env.appHost,this.vscodeAPI.env.uiKind){case this.vscodeAPI.UIKind.Web:e["common.uikind"]="web";break;case this.vscodeAPI.UIKind.Desktop:e["common.uikind"]="desktop";break;default:e["common.uikind"]="unknown"}e["common.remotename"]=this.cleanRemoteName(this.vscodeAPI.env.remoteName)}return e}anonymizeFilePaths(e,t){let n;if(null==e)return"";let r=[];""!==this.vscodeAPI.env.appRoot&&r.push(new RegExp(this.vscodeAPI.env.appRoot.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),"gi")),this.extension&&r.push(new RegExp(this.extension.extensionPath.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),"gi"));let o=e;if(t){let t=[];for(let o of r)for(;(n=o.exec(e))&&n;)t.push([n.index,o.lastIndex]);let i=/^[\\/]?(node_modules|node_modules\.asar)[\\/]/,s=/(file:\/\/)?([a-zA-Z]:(\\\\|\\|\/)|(\\\\|\\|\/))?([\w-._]+(\\\\|\\|\/))+[\w-._]*/g,a=0;for(o="";(n=s.exec(e))&&n;)n[0]&&!i.test(n[0])&&t.every((([e,t])=>n.index<e||n.index>=t))&&(o+=e.substring(a,n.index)+"<REDACTED: user-file-path>",a=s.lastIndex);a<e.length&&(o+=e.substr(a))}for(let e of r)o=o.replace(e,"");return o}removePropertiesWithPossibleUserInfo(e){if("object"!=typeof e)return;let t={};for(let n of Object.keys(e)){let r=e[n];if(!r)continue;let o=/@[a-zA-Z0-9-.]+/,i=/xox[pbaors]-[a-zA-Z0-9]+-[a-zA-Z0-9-]+?/;/(key|token|sig|signature|password|passwd|pwd|android:value)[^a-zA-Z0-9]/.test(r.toLowerCase())?t[n]="<REDACTED: secret>":o.test(r)?t[n]="<REDACTED: email>":i.test(r)?t[n]="<REDACTED: token>":t[n]=r}return t}get telemetryLevel(){switch(yo.getInstance(this.vscodeAPI).getTelemetryLevel()){case"on":return"all";case"error":return"error";case"off":return"off"}}internalSendTelemetryEvent(e,t,n,r,o){if((this.userOptIn||o)&&""!==e){if(t=y(y({},t),this.getCommonProperties()),r){let e=this.cloneAndChange(t,((e,t)=>this.anonymizeFilePaths(t,this.firstParty)));t=this.removePropertiesWithPossibleUserInfo(e)}t=t??{},n=n??{},e=`${this.extensionId}/${e}`,this.telemetryAppender.logEvent(e,{properties:t,measurements:n})}}sendTelemetryEvent(e,t,n){this.internalSendTelemetryEvent(e,t,n,!0,!1)}sendRawTelemetryEvent(e,t,n){this.internalSendTelemetryEvent(e,t,n,!1,!1)}sendDangerousTelemetryEvent(e,t,n,r=!0){this.telemetryAppender.instantiateAppender(),this.internalSendTelemetryEvent(e,t,n,r,!0)}internalSendTelemetryErrorEvent(e,t,n,r,o){if((this.shouldSendErrorTelemetry()||o)&&""!==e){if(t=y(y({},t),this.getCommonProperties()),r){let e=this.cloneAndChange(t,((e,t)=>this.anonymizeFilePaths(t,this.firstParty)));t=this.removePropertiesWithPossibleUserInfo(e)}t=t??{},n=n??{},e=`${this.extensionId}/${e}`,this.telemetryAppender.logEvent(e,{properties:t,measurements:n})}}sendTelemetryErrorEvent(e,t,n){this.internalSendTelemetryErrorEvent(e,t,n,!0,!1)}sendDangerousTelemetryErrorEvent(e,t,n,r=!0){this.telemetryAppender.instantiateAppender(),this.internalSendTelemetryErrorEvent(e,t,n,r,!0)}internalSendTelemetryException(e,t,n,r,o){if((this.shouldSendErrorTelemetry()||o)&&e){if(t=y(y({},t),this.getCommonProperties()),r){let n=this.cloneAndChange(t,((e,t)=>this.anonymizeFilePaths(t,this.firstParty)));e.stack&&(e.stack=this.anonymizeFilePaths(e.stack,this.firstParty)),t=this.removePropertiesWithPossibleUserInfo(n)}t=t??{},n=n??{},this.telemetryAppender.logException(e,{properties:t,measurements:n})}}sendTelemetryException(e,t,n){this.internalSendTelemetryException(e,t,n,!0,!1)}sendDangerousTelemetryException(e,t,n,r=!0){this.telemetryAppender.instantiateAppender(),this.internalSendTelemetryException(e,t,n,r,!0)}dispose(){return this.telemetryAppender.flush(),Promise.all(this.disposables.map((e=>e.dispose())))}},bo=class{constructor(e,t){this._instantiationStatus=0,this._eventQueue=[],this._exceptionQueue=[],this._clientFactory=t,this._key=e}logEvent(e,t){this._telemetryClient?this._telemetryClient.logEvent(e,t):2!==this._instantiationStatus&&this._eventQueue.push({eventName:e,data:t})}logException(e,t){this._telemetryClient?this._telemetryClient.logException(e,t):2!==this._instantiationStatus&&this._exceptionQueue.push({exception:e,data:t})}async flush(){this._telemetryClient&&(await this._telemetryClient.flush(),this._telemetryClient=void 0)}_flushQueues(){this._eventQueue.forEach((({eventName:e,data:t})=>this.logEvent(e,t))),this._eventQueue=[],this._exceptionQueue.forEach((({exception:e,data:t})=>this.logException(e,t))),this._exceptionQueue=[]}instantiateAppender(){0===this._instantiationStatus&&(this._instantiationStatus=1,this._clientFactory(this._key).then((e=>{this._telemetryClient=e,this._instantiationStatus=2,this._flushQueues()})).catch((e=>{console.error(e),this._instantiationStatus=2})))}},Eo=class extends _o{constructor(e,t,n,r,o){let i=e=>(async(e,t)=>{let n;try{process.env.APPLICATION_INSIGHTS_NO_DIAGNOSTIC_CHANNEL="1";let t=await Promise.resolve().then((()=>T(ho())));t.defaultClient?(n=new t.TelemetryClient(e),n.channel.setUseDiskRetryCaching(!0)):(t.setup(e).setAutoCollectRequests(!1).setAutoCollectPerformance(!1).setAutoCollectExceptions(!1).setAutoCollectDependencies(!1).setAutoDependencyCorrelation(!1).setAutoCollectConsole(!1).setAutoCollectHeartbeat(!1).setUseDiskRetryCaching(!0).start(),n=t.defaultClient),vo&&vo.env&&(n.context.tags[n.context.keys.userId]=vo.env.machineId,n.context.tags[n.context.keys.sessionId]=vo.env.sessionId,n.context.tags[n.context.keys.cloudRole]=vo.env.appName,n.context.tags[n.context.keys.cloudRoleInstance]=vo.env.appName),e&&0===e.indexOf("AIF-")&&(n.config.endpointUrl="https://mobile.events.data.microsoft.com/collect/v1")}catch(e){return Promise.reject("Failed to initialize app insights!\n"+e.message)}return null!=t&&t.length&&function(e,t){e.addTelemetryProcessor((e=>(Array.isArray(e.tags)?e.tags.forEach((e=>yo.applyReplacements(e,t))):e.tags&&yo.applyReplacements(e.tags,t),e.data.baseData&&yo.applyReplacements(e.data.baseData,t),!0)))}(n,t),{logEvent:(e,t)=>{try{null==n||n.trackEvent({name:e,properties:null==t?void 0:t.properties,measurements:null==t?void 0:t.measurements})}catch(e){throw new Error("Failed to log event to app insights!\n"+e.message)}},logException:(e,t)=>{try{null==n||n.trackException({exception:e,properties:null==t?void 0:t.properties,measurements:null==t?void 0:t.measurements})}catch(e){throw new Error("Failed to log exception to app insights!\n"+e.message)}},flush:async()=>{try{null==n||n.flush()}catch(e){throw new Error("Failed to flush app insights!\n"+e.message)}}}})(e,o);yo.shouldUseOneDataSystemSDK(n)&&(i=e=>(async(e,t,n)=>{let r=await(async(e,t,n)=>{let r=await Promise.resolve().then((()=>T(w()))),o=await Promise.resolve().then((()=>T(I()))),i=new r.AppInsightsCore,s=new o.PostChannel,a={instrumentationKey:e,endpointUrl:"https://mobile.events.data.microsoft.com/OneCollector/1.0",loggingLevelTelemetry:0,loggingLevelConsole:0,disableCookiesUsage:!0,disableDbgExt:!0,disableInstrumentationKeyValidation:!0,channels:[[s]]};if(n){a.extensionConfig={};let e={alwaysUseXhrOverride:!0,httpXHROverride:n};a.extensionConfig[s.identifier]=e}let c=t.workspace.getConfiguration("telemetry").get("internalTesting");return i.initialize(a,[]),i.addTelemetryInitializer((e=>{!c||(e.ext=e.ext??{},e.ext.utc=e.ext.utc??{},e.ext.utc.flags=8462029)})),i})(e,t,n);return{logEvent:(e,t)=>{try{null==r||r.track({name:e,baseData:{name:e,properties:null==t?void 0:t.properties,measurements:null==t?void 0:t.measurements}})}catch(e){throw new Error("Failed to log event to app insights!\n"+e.message)}},logException:(e,t)=>{throw new Error("1DS SDK does not support logging exceptions, please use logEvent for exception tracking")},flush:async()=>{try{null==r||r.unload()}catch(e){throw new Error("Failed to flush app insights!\n"+e.message)}}}})(e,vo,{sendPOST:(e,t)=>{let n={method:"POST",headers:_(y({},e.headers),{"Content-Type":"application/json","Content-Length":Buffer.byteLength(e.data)})};try{let r=go.request(e.urlString,n,(e=>{e.on("data",(function(n){t(e.statusCode??200,e.headers,n.toString())})),e.on("error",(function(){t(0,{})}))}));r.write(e.data),r.end()}catch{t(0,{})}}}));let s=new bo(n,i);n&&(0===n.indexOf("AIF-")||yo.shouldUseOneDataSystemSDK(n))&&(r=!0),super(e,t,s,{release:mo.release(),platform:mo.platform(),architecture:mo.arch()},vo,r)}}},889:e=>{function t(e){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}t.keys=()=>[],t.resolve=t,t.id=889,e.exports=t},8371:e=>{function t(e){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}t.keys=()=>[],t.resolve=t,t.id=8371,e.exports=t},6584:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(4988);class o extends r.EventTarget{constructor(){throw super(),new TypeError("AbortSignal cannot be constructed directly")}get aborted(){const e=i.get(this);if("boolean"!=typeof e)throw new TypeError("Expected 'this' to be an 'AbortSignal' object, but got "+(null===this?"null":typeof this));return e}}r.defineEventAttribute(o.prototype,"abort");const i=new WeakMap;Object.defineProperties(o.prototype,{aborted:{enumerable:!0}}),"function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag&&Object.defineProperty(o.prototype,Symbol.toStringTag,{configurable:!0,value:"AbortSignal"});class s{constructor(){a.set(this,function(){const e=Object.create(o.prototype);return r.EventTarget.call(e),i.set(e,!1),e}())}get signal(){return c(this)}abort(){var e;e=c(this),!1===i.get(e)&&(i.set(e,!0),e.dispatchEvent({type:"abort"}))}}const a=new WeakMap;function c(e){const t=a.get(e);if(null==t)throw new TypeError("Expected 'this' to be an 'AbortController' object, but got "+(null===e?"null":typeof e));return t}Object.defineProperties(s.prototype,{signal:{enumerable:!0},abort:{enumerable:!0}}),"function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag&&Object.defineProperty(s.prototype,Symbol.toStringTag,{configurable:!0,value:"AbortController"}),t.AbortController=s,t.AbortSignal=o,t.default=s,e.exports=s,e.exports.AbortController=e.exports.default=s,e.exports.AbortSignal=o},9724:function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};const o=n(4434),i=r(n(5753)),s=r(n(1956)),a=i.default("agent-base");function c(){const{stack:e}=new Error;return"string"==typeof e&&e.split("\n").some((e=>-1!==e.indexOf("(https.js:")||-1!==e.indexOf("node:https:")))}function u(e,t){return new u.Agent(e,t)}!function(e){class t extends o.EventEmitter{constructor(e,t){super();let n=t;"function"==typeof e?this.callback=e:e&&(n=e),this.timeout=null,n&&"number"==typeof n.timeout&&(this.timeout=n.timeout),this.maxFreeSockets=1,this.maxSockets=1,this.maxTotalSockets=1/0,this.sockets={},this.freeSockets={},this.requests={},this.options={}}get defaultPort(){return"number"==typeof this.explicitDefaultPort?this.explicitDefaultPort:c()?443:80}set defaultPort(e){this.explicitDefaultPort=e}get protocol(){return"string"==typeof this.explicitProtocol?this.explicitProtocol:c()?"https:":"http:"}set protocol(e){this.explicitProtocol=e}callback(e,t,n){throw new Error('"agent-base" has no default implementation, you must subclass and override `callback()`')}addRequest(e,t){const n=Object.assign({},t);"boolean"!=typeof n.secureEndpoint&&(n.secureEndpoint=c()),null==n.host&&(n.host="localhost"),null==n.port&&(n.port=n.secureEndpoint?443:80),null==n.protocol&&(n.protocol=n.secureEndpoint?"https:":"http:"),n.host&&n.path&&delete n.path,delete n.agent,delete n.hostname,delete n._defaultAgent,delete n.defaultPort,delete n.createConnection,e._last=!0,e.shouldKeepAlive=!1;let r=!1,o=null;const i=n.timeout||this.timeout,u=t=>{e._hadError||(e.emit("error",t),e._hadError=!0)},l=()=>{o=null,r=!0;const e=new Error(`A "socket" was not created for HTTP request before ${i}ms`);e.code="ETIMEOUT",u(e)},p=e=>{r||(null!==o&&(clearTimeout(o),o=null),u(e))},d=t=>{if(r)return;if(null!=o&&(clearTimeout(o),o=null),i=t,Boolean(i)&&"function"==typeof i.addRequest)return a("Callback returned another Agent instance %o",t.constructor.name),void t.addRequest(e,n);var i;if(t)return t.once("free",(()=>{this.freeSocket(t,n)})),void e.onSocket(t);const s=new Error(`no Duplex stream was returned to agent-base for \`${e.method} ${e.path}\``);u(s)};if("function"==typeof this.callback){this.promisifiedCallback||(this.callback.length>=3?(a("Converting legacy callback function to promise"),this.promisifiedCallback=s.default(this.callback)):this.promisifiedCallback=this.callback),"number"==typeof i&&i>0&&(o=setTimeout(l,i)),"port"in n&&"number"!=typeof n.port&&(n.port=Number(n.port));try{a("Resolving socket for %o request: %o",n.protocol,`${e.method} ${e.path}`),Promise.resolve(this.promisifiedCallback(e,n)).then(d,p)}catch(e){Promise.reject(e).catch(p)}}else u(new Error("`callback` is not defined"))}freeSocket(e,t){a("Freeing socket %o %o",e.constructor.name,t),e.destroy()}destroy(){a("Destroying agent %o",this.constructor.name)}}e.Agent=t,e.prototype=e.Agent.prototype}(u||(u={})),e.exports=u},1956:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return function(t,n){return new Promise(((r,o)=>{e.call(this,t,n,((e,t)=>{e?o(e):r(t)}))}))}}},1873:(e,t,n)=>{e.exports={parallel:n(8798),serial:n(2081),serialOrdered:n(28)}},4555:e=>{function t(e){"function"==typeof this.jobs[e]&&this.jobs[e]()}e.exports=function(e){Object.keys(e.jobs).forEach(t.bind(e)),e.jobs={}}},2313:(e,t,n)=>{var r=n(405);e.exports=function(e){var t=!1;return r((function(){t=!0})),function(n,o){t?e(n,o):r((function(){e(n,o)}))}}},405:e=>{e.exports=function(e){var t="function"==typeof setImmediate?setImmediate:"object"==typeof process&&"function"==typeof process.nextTick?process.nextTick:null;t?t(e):setTimeout(e,0)}},8051:(e,t,n)=>{var r=n(2313),o=n(4555);e.exports=function(e,t,n,i){var s=n.keyedList?n.keyedList[n.index]:n.index;n.jobs[s]=function(e,t,n,o){return 2==e.length?e(n,r(o)):e(n,t,r(o))}(t,s,e[s],(function(e,t){s in n.jobs&&(delete n.jobs[s],e?o(n):n.results[s]=t,i(e,n.results))}))}},9500:e=>{e.exports=function(e,t){var n=!Array.isArray(e),r={index:0,keyedList:n||t?Object.keys(e):null,jobs:{},results:n?{}:[],size:n?Object.keys(e).length:e.length};return t&&r.keyedList.sort(n?t:function(n,r){return t(e[n],e[r])}),r}},6276:(e,t,n)=>{var r=n(4555),o=n(2313);e.exports=function(e){Object.keys(this.jobs).length&&(this.index=this.size,r(this),o(e)(null,this.results))}},8798:(e,t,n)=>{var r=n(8051),o=n(9500),i=n(6276);e.exports=function(e,t,n){for(var s=o(e);s.index<(s.keyedList||e).length;)r(e,t,s,(function(e,t){e?n(e,t):0!==Object.keys(s.jobs).length||n(null,s.results)})),s.index++;return i.bind(s,n)}},2081:(e,t,n)=>{var r=n(28);e.exports=function(e,t,n){return r(e,t,null,n)}},28:(e,t,n)=>{var r=n(8051),o=n(9500),i=n(6276);function s(e,t){return e<t?-1:e>t?1:0}e.exports=function(e,t,n,s){var a=o(e,n);return r(e,t,a,(function n(o,i){o?s(o,i):(a.index++,a.index<(a.keyedList||e).length?r(e,t,a,n):s(null,a.results))})),i.bind(a,s)},e.exports.ascending=s,e.exports.descending=function(e,t){return-1*s(e,t)}},801:(e,t,n)=>{var r=n(9023),o=n(2203).Stream,i=n(8069);function s(){this.writable=!1,this.readable=!0,this.dataSize=0,this.maxDataSize=2097152,this.pauseStreams=!0,this._released=!1,this._streams=[],this._currentStream=null,this._insideLoop=!1,this._pendingNext=!1}e.exports=s,r.inherits(s,o),s.create=function(e){var t=new this;for(var n in e=e||{})t[n]=e[n];return t},s.isStreamLike=function(e){return"function"!=typeof e&&"string"!=typeof e&&"boolean"!=typeof e&&"number"!=typeof e&&!Buffer.isBuffer(e)},s.prototype.append=function(e){if(s.isStreamLike(e)){if(!(e instanceof i)){var t=i.create(e,{maxDataSize:1/0,pauseStream:this.pauseStreams});e.on("data",this._checkDataSize.bind(this)),e=t}this._handleErrors(e),this.pauseStreams&&e.pause()}return this._streams.push(e),this},s.prototype.pipe=function(e,t){return o.prototype.pipe.call(this,e,t),this.resume(),e},s.prototype._getNext=function(){if(this._currentStream=null,this._insideLoop)this._pendingNext=!0;else{this._insideLoop=!0;try{do{this._pendingNext=!1,this._realGetNext()}while(this._pendingNext)}finally{this._insideLoop=!1}}},s.prototype._realGetNext=function(){var e=this._streams.shift();void 0!==e?"function"==typeof e?e(function(e){s.isStreamLike(e)&&(e.on("data",this._checkDataSize.bind(this)),this._handleErrors(e)),this._pipeNext(e)}.bind(this)):this._pipeNext(e):this.end()},s.prototype._pipeNext=function(e){if(this._currentStream=e,s.isStreamLike(e))return e.on("end",this._getNext.bind(this)),void e.pipe(this,{end:!1});var t=e;this.write(t),this._getNext()},s.prototype._handleErrors=function(e){var t=this;e.on("error",(function(e){t._emitError(e)}))},s.prototype.write=function(e){this.emit("data",e)},s.prototype.pause=function(){this.pauseStreams&&(this.pauseStreams&&this._currentStream&&"function"==typeof this._currentStream.pause&&this._currentStream.pause(),this.emit("pause"))},s.prototype.resume=function(){this._released||(this._released=!0,this.writable=!0,this._getNext()),this.pauseStreams&&this._currentStream&&"function"==typeof this._currentStream.resume&&this._currentStream.resume(),this.emit("resume")},s.prototype.end=function(){this._reset(),this.emit("end")},s.prototype.destroy=function(){this._reset(),this.emit("close")},s.prototype._reset=function(){this.writable=!1,this._streams=[],this._currentStream=null},s.prototype._checkDataSize=function(){if(this._updateDataSize(),!(this.dataSize<=this.maxDataSize)){var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this._emitError(new Error(e))}},s.prototype._updateDataSize=function(){this.dataSize=0;var e=this;this._streams.forEach((function(t){t.dataSize&&(e.dataSize+=t.dataSize)})),this._currentStream&&this._currentStream.dataSize&&(this.dataSize+=this._currentStream.dataSize)},s.prototype._emitError=function(e){this._reset(),this.emit("error",e)}},8e3:e=>{var t=1e3,n=60*t,r=60*n,o=24*r,i=7*o;function s(e,t,n,r){var o=t>=1.5*n;return Math.round(e/n)+" "+r+(o?"s":"")}e.exports=function(e,a){a=a||{};var c,u,l=typeof e;if("string"===l&&e.length>0)return function(e){if(!((e=String(e)).length>100)){var s=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(s){var a=parseFloat(s[1]);switch((s[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*a;case"weeks":case"week":case"w":return a*i;case"days":case"day":case"d":return a*o;case"hours":case"hour":case"hrs":case"hr":case"h":return a*r;case"minutes":case"minute":case"mins":case"min":case"m":return a*n;case"seconds":case"second":case"secs":case"sec":case"s":return a*t;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return a;default:return}}}}(e);if("number"===l&&isFinite(e))return a.long?(c=e,(u=Math.abs(c))>=o?s(c,u,o,"day"):u>=r?s(c,u,r,"hour"):u>=n?s(c,u,n,"minute"):u>=t?s(c,u,t,"second"):c+" ms"):function(e){var i=Math.abs(e);return i>=o?Math.round(e/o)+"d":i>=r?Math.round(e/r)+"h":i>=n?Math.round(e/n)+"m":i>=t?Math.round(e/t)+"s":e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},7833:(e,t,n)=>{t.formatArgs=function(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const n="color: "+this.color;t.splice(1,0,n,"color: inherit");let r=0,o=0;t[0].replace(/%[a-zA-Z%]/g,(e=>{"%%"!==e&&(r++,"%c"===e&&(o=r))})),t.splice(o,0,n)},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){let e;try{e=t.storage.getItem("debug")}catch(e){}return!e&&"undefined"!=typeof process&&"env"in process&&(e=process.env.DEBUG),e},t.useColors=function(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type&&!window.process.__nwjs)||("undefined"==typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))},t.storage=function(){try{return localStorage}catch(e){}}(),t.destroy=(()=>{let e=!1;return()=>{e||(e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.log=console.debug||console.log||(()=>{}),e.exports=n(736)(t);const{formatters:r}=e.exports;r.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}},736:(e,t,n)=>{e.exports=function(e){function t(e){let n,o,i,s=null;function a(...e){if(!a.enabled)return;const r=a,o=Number(new Date),i=o-(n||o);r.diff=i,r.prev=n,r.curr=o,n=o,e[0]=t.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let s=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,((n,o)=>{if("%%"===n)return"%";s++;const i=t.formatters[o];if("function"==typeof i){const t=e[s];n=i.call(r,t),e.splice(s,1),s--}return n})),t.formatArgs.call(r,e),(r.log||t.log).apply(r,e)}return a.namespace=e,a.useColors=t.useColors(),a.color=t.selectColor(e),a.extend=r,a.destroy=t.destroy,Object.defineProperty(a,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==s?s:(o!==t.namespaces&&(o=t.namespaces,i=t.enabled(e)),i),set:e=>{s=e}}),"function"==typeof t.init&&t.init(a),a}function r(e,n){const r=t(this.namespace+(void 0===n?":":n)+e);return r.log=this.log,r}function o(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}return t.debug=t,t.default=t,t.coerce=function(e){return e instanceof Error?e.stack||e.message:e},t.disable=function(){const e=[...t.names.map(o),...t.skips.map(o).map((e=>"-"+e))].join(",");return t.enable(""),e},t.enable=function(e){let n;t.save(e),t.namespaces=e,t.names=[],t.skips=[];const r=("string"==typeof e?e:"").split(/[\s,]+/),o=r.length;for(n=0;n<o;n++)r[n]&&("-"===(e=r[n].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.slice(1)+"$")):t.names.push(new RegExp("^"+e+"$")))},t.enabled=function(e){if("*"===e[e.length-1])return!0;let n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1},t.humanize=n(8e3),t.destroy=function(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")},Object.keys(e).forEach((n=>{t[n]=e[n]})),t.names=[],t.skips=[],t.formatters={},t.selectColor=function(e){let n=0;for(let t=0;t<e.length;t++)n=(n<<5)-n+e.charCodeAt(t),n|=0;return t.colors[Math.abs(n)%t.colors.length]},t.enable(t.load()),t}},5753:(e,t,n)=>{"undefined"==typeof process||"renderer"===process.type||!0===process.browser||process.__nwjs?e.exports=n(7833):e.exports=n(6033)},6033:(e,t,n)=>{const r=n(2018),o=n(9023);t.init=function(e){e.inspectOpts={};const n=Object.keys(t.inspectOpts);for(let r=0;r<n.length;r++)e.inspectOpts[n[r]]=t.inspectOpts[n[r]]},t.log=function(...e){return process.stderr.write(o.format(...e)+"\n")},t.formatArgs=function(n){const{namespace:r,useColors:o}=this;if(o){const t=this.color,o="[3"+(t<8?t:"8;5;"+t),i=`  ${o};1m${r} `;n[0]=i+n[0].split("\n").join("\n"+i),n.push(o+"m+"+e.exports.humanize(this.diff)+"")}else n[0]=(t.inspectOpts.hideDate?"":(new Date).toISOString()+" ")+r+" "+n[0]},t.save=function(e){e?process.env.DEBUG=e:delete process.env.DEBUG},t.load=function(){return process.env.DEBUG},t.useColors=function(){return"colors"in t.inspectOpts?Boolean(t.inspectOpts.colors):r.isatty(process.stderr.fd)},t.destroy=o.deprecate((()=>{}),"Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."),t.colors=[6,2,3,4,5,1];try{const e=n(7687);e&&(e.stderr||e).level>=2&&(t.colors=[20,21,26,27,32,33,38,39,40,41,42,43,44,45,56,57,62,63,68,69,74,75,76,77,78,79,80,81,92,93,98,99,112,113,128,129,134,135,148,149,160,161,162,163,164,165,166,167,168,169,170,171,172,173,178,179,184,185,196,197,198,199,200,201,202,203,204,205,206,207,208,209,214,215,220,221])}catch(e){}t.inspectOpts=Object.keys(process.env).filter((e=>/^debug_/i.test(e))).reduce(((e,t)=>{const n=t.substring(6).toLowerCase().replace(/_([a-z])/g,((e,t)=>t.toUpperCase()));let r=process.env[t];return r=!!/^(yes|on|true|enabled)$/i.test(r)||!/^(no|off|false|disabled)$/i.test(r)&&("null"===r?null:Number(r)),e[n]=r,e}),{}),e.exports=n(736)(t);const{formatters:i}=e.exports;i.o=function(e){return this.inspectOpts.colors=this.useColors,o.inspect(e,this.inspectOpts).split("\n").map((e=>e.trim())).join(" ")},i.O=function(e){return this.inspectOpts.colors=this.useColors,o.inspect(e,this.inspectOpts)}},8069:(e,t,n)=>{var r=n(2203).Stream,o=n(9023);function i(){this.source=null,this.dataSize=0,this.maxDataSize=1048576,this.pauseStream=!0,this._maxDataSizeExceeded=!1,this._released=!1,this._bufferedEvents=[]}e.exports=i,o.inherits(i,r),i.create=function(e,t){var n=new this;for(var r in t=t||{})n[r]=t[r];n.source=e;var o=e.emit;return e.emit=function(){return n._handleEmit(arguments),o.apply(e,arguments)},e.on("error",(function(){})),n.pauseStream&&e.pause(),n},Object.defineProperty(i.prototype,"readable",{configurable:!0,enumerable:!0,get:function(){return this.source.readable}}),i.prototype.setEncoding=function(){return this.source.setEncoding.apply(this.source,arguments)},i.prototype.resume=function(){this._released||this.release(),this.source.resume()},i.prototype.pause=function(){this.source.pause()},i.prototype.release=function(){this._released=!0,this._bufferedEvents.forEach(function(e){this.emit.apply(this,e)}.bind(this)),this._bufferedEvents=[]},i.prototype.pipe=function(){var e=r.prototype.pipe.apply(this,arguments);return this.resume(),e},i.prototype._handleEmit=function(e){this._released?this.emit.apply(this,e):("data"===e[0]&&(this.dataSize+=e[1].length,this._checkIfMaxDataSizeExceeded()),this._bufferedEvents.push(e))},i.prototype._checkIfMaxDataSizeExceeded=function(){if(!(this._maxDataSizeExceeded||this.dataSize<=this.maxDataSize)){this._maxDataSizeExceeded=!0;var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this.emit("error",new Error(e))}}},4988:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=new WeakMap,r=new WeakMap;function o(e){const t=n.get(e);return console.assert(null!=t,"'this' is expected an Event object, but got",e),t}function i(e){null==e.passiveListener?e.event.cancelable&&(e.canceled=!0,"function"==typeof e.event.preventDefault&&e.event.preventDefault()):"undefined"!=typeof console&&"function"==typeof console.error&&console.error("Unable to preventDefault inside passive event listener invocation.",e.passiveListener)}function s(e,t){n.set(this,{eventTarget:e,event:t,eventPhase:2,currentTarget:e,canceled:!1,stopped:!1,immediateStopped:!1,passiveListener:null,timeStamp:t.timeStamp||Date.now()}),Object.defineProperty(this,"isTrusted",{value:!1,enumerable:!0});const r=Object.keys(t);for(let e=0;e<r.length;++e){const t=r[e];t in this||Object.defineProperty(this,t,a(t))}}function a(e){return{get(){return o(this).event[e]},set(t){o(this).event[e]=t},configurable:!0,enumerable:!0}}function c(e){return{value(){const t=o(this).event;return t[e].apply(t,arguments)},configurable:!0,enumerable:!0}}function u(e){if(null==e||e===Object.prototype)return s;let t=r.get(e);return null==t&&(t=function(e,t){const n=Object.keys(t);if(0===n.length)return e;function r(t,n){e.call(this,t,n)}r.prototype=Object.create(e.prototype,{constructor:{value:r,configurable:!0,writable:!0}});for(let o=0;o<n.length;++o){const i=n[o];if(!(i in e.prototype)){const e="function"==typeof Object.getOwnPropertyDescriptor(t,i).value;Object.defineProperty(r.prototype,i,e?c(i):a(i))}}return r}(u(Object.getPrototypeOf(e)),e),r.set(e,t)),t}function l(e){return o(e).immediateStopped}function p(e,t){o(e).passiveListener=t}s.prototype={get type(){return o(this).event.type},get target(){return o(this).eventTarget},get currentTarget(){return o(this).currentTarget},composedPath(){const e=o(this).currentTarget;return null==e?[]:[e]},get NONE(){return 0},get CAPTURING_PHASE(){return 1},get AT_TARGET(){return 2},get BUBBLING_PHASE(){return 3},get eventPhase(){return o(this).eventPhase},stopPropagation(){const e=o(this);e.stopped=!0,"function"==typeof e.event.stopPropagation&&e.event.stopPropagation()},stopImmediatePropagation(){const e=o(this);e.stopped=!0,e.immediateStopped=!0,"function"==typeof e.event.stopImmediatePropagation&&e.event.stopImmediatePropagation()},get bubbles(){return Boolean(o(this).event.bubbles)},get cancelable(){return Boolean(o(this).event.cancelable)},preventDefault(){i(o(this))},get defaultPrevented(){return o(this).canceled},get composed(){return Boolean(o(this).event.composed)},get timeStamp(){return o(this).timeStamp},get srcElement(){return o(this).eventTarget},get cancelBubble(){return o(this).stopped},set cancelBubble(e){if(!e)return;const t=o(this);t.stopped=!0,"boolean"==typeof t.event.cancelBubble&&(t.event.cancelBubble=!0)},get returnValue(){return!o(this).canceled},set returnValue(e){e||i(o(this))},initEvent(){}},Object.defineProperty(s.prototype,"constructor",{value:s,configurable:!0,writable:!0}),"undefined"!=typeof window&&void 0!==window.Event&&(Object.setPrototypeOf(s.prototype,window.Event.prototype),r.set(window.Event.prototype,s));const d=new WeakMap,h=3;function f(e){return null!==e&&"object"==typeof e}function m(e){const t=d.get(e);if(null==t)throw new TypeError("'this' is expected an EventTarget object, but got another value.");return t}function v(e,t){Object.defineProperty(e,`on${t}`,function(e){return{get(){let t=m(this).get(e);for(;null!=t;){if(t.listenerType===h)return t.listener;t=t.next}return null},set(t){"function"==typeof t||f(t)||(t=null);const n=m(this);let r=null,o=n.get(e);for(;null!=o;)o.listenerType===h?null!==r?r.next=o.next:null!==o.next?n.set(e,o.next):n.delete(e):r=o,o=o.next;if(null!==t){const o={listener:t,listenerType:h,passive:!1,once:!1,next:null};null===r?n.set(e,o):r.next=o}},configurable:!0,enumerable:!0}}(t))}function g(e){function t(){y.call(this)}t.prototype=Object.create(y.prototype,{constructor:{value:t,configurable:!0,writable:!0}});for(let n=0;n<e.length;++n)v(t.prototype,e[n]);return t}function y(){if(!(this instanceof y)){if(1===arguments.length&&Array.isArray(arguments[0]))return g(arguments[0]);if(arguments.length>0){const e=new Array(arguments.length);for(let t=0;t<arguments.length;++t)e[t]=arguments[t];return g(e)}throw new TypeError("Cannot call a class as a function")}d.set(this,new Map)}y.prototype={addEventListener(e,t,n){if(null==t)return;if("function"!=typeof t&&!f(t))throw new TypeError("'listener' should be a function or an object.");const r=m(this),o=f(n),i=(o?Boolean(n.capture):Boolean(n))?1:2,s={listener:t,listenerType:i,passive:o&&Boolean(n.passive),once:o&&Boolean(n.once),next:null};let a=r.get(e);if(void 0===a)return void r.set(e,s);let c=null;for(;null!=a;){if(a.listener===t&&a.listenerType===i)return;c=a,a=a.next}c.next=s},removeEventListener(e,t,n){if(null==t)return;const r=m(this),o=(f(n)?Boolean(n.capture):Boolean(n))?1:2;let i=null,s=r.get(e);for(;null!=s;){if(s.listener===t&&s.listenerType===o)return void(null!==i?i.next=s.next:null!==s.next?r.set(e,s.next):r.delete(e));i=s,s=s.next}},dispatchEvent(e){if(null==e||"string"!=typeof e.type)throw new TypeError('"event.type" should be a string.');const t=m(this),n=e.type;let r=t.get(n);if(null==r)return!0;const i=function(e,t){return new(u(Object.getPrototypeOf(t)))(e,t)}(this,e);let s=null;for(;null!=r;){if(r.once?null!==s?s.next=r.next:null!==r.next?t.set(n,r.next):t.delete(n):s=r,p(i,r.passive?r.listener:null),"function"==typeof r.listener)try{r.listener.call(this,i)}catch(e){"undefined"!=typeof console&&"function"==typeof console.error&&console.error(e)}else r.listenerType!==h&&"function"==typeof r.listener.handleEvent&&r.listener.handleEvent(i);if(l(i))break;r=r.next}return p(i,null),function(e){o(e).eventPhase=0}(i),function(e){o(e).currentTarget=null}(i),!i.defaultPrevented}},Object.defineProperty(y.prototype,"constructor",{value:y,configurable:!0,writable:!0}),"undefined"!=typeof window&&void 0!==window.EventTarget&&Object.setPrototypeOf(y.prototype,window.EventTarget.prototype),t.defineEventAttribute=v,t.EventTarget=y,t.default=y,e.exports=y,e.exports.EventTarget=e.exports.default=y,e.exports.defineEventAttribute=v},7507:(e,t,n)=>{var r;e.exports=function(){if(!r){try{r=n(5753)("follow-redirects")}catch(e){}"function"!=typeof r&&(r=function(){})}r.apply(null,arguments)}},3164:(e,t,n)=>{var r,o,i,s=n(7016),a=s.URL,c=n(8611),u=n(5692),l=n(2203).Writable,p=n(2613),d=n(7507);r="undefined"!=typeof process,o="undefined"!=typeof window&&"undefined"!=typeof document,i=k(Error.captureStackTrace),r||!o&&i||console.warn("The follow-redirects package should be excluded from browser builds.");var h=!1;try{p(new a(""))}catch(e){h="ERR_INVALID_URL"===e.code}var f=["auth","host","hostname","href","path","pathname","port","protocol","query","search","hash"],m=["abort","aborted","connect","error","socket","timeout"],v=Object.create(null);m.forEach((function(e){v[e]=function(t,n,r){this._redirectable.emit(e,t,n,r)}}));var g=P("ERR_INVALID_URL","Invalid URL",TypeError),y=P("ERR_FR_REDIRECTION_FAILURE","Redirected request failed"),_=P("ERR_FR_TOO_MANY_REDIRECTS","Maximum number of redirects exceeded",y),b=P("ERR_FR_MAX_BODY_LENGTH_EXCEEDED","Request body larger than maxBodyLength limit"),E=P("ERR_STREAM_WRITE_AFTER_END","write after end"),T=l.prototype.destroy||x;function S(e,t){l.call(this),this._sanitizeOptions(e),this._options=e,this._ended=!1,this._ending=!1,this._redirectCount=0,this._redirects=[],this._requestBodyLength=0,this._requestBodyBuffers=[],t&&this.on("response",t);var n=this;this._onNativeResponse=function(e){try{n._processResponse(e)}catch(e){n.emit("error",e instanceof y?e:new y({cause:e}))}},this._performRequest()}function C(e){var t={maxRedirects:21,maxBodyLength:10485760},n={};return Object.keys(e).forEach((function(r){var o=r+":",i=n[o]=e[r],s=t[r]=Object.create(i);Object.defineProperties(s,{request:{value:function(e,r,i){return a&&e instanceof a?e=I(e):N(e)?e=I(w(e)):(i=r,r=A(e),e={protocol:o}),k(r)&&(i=r,r=null),(r=Object.assign({maxRedirects:t.maxRedirects,maxBodyLength:t.maxBodyLength},e,r)).nativeProtocols=n,N(r.host)||N(r.hostname)||(r.hostname="::1"),p.equal(r.protocol,o,"protocol mismatch"),d("options",r),new S(r,i)},configurable:!0,enumerable:!0,writable:!0},get:{value:function(e,t,n){var r=s.request(e,t,n);return r.end(),r},configurable:!0,enumerable:!0,writable:!0}})})),t}function x(){}function w(e){var t;if(h)t=new a(e);else if(!N((t=A(s.parse(e))).protocol))throw new g({input:e});return t}function A(e){if(/^\[/.test(e.hostname)&&!/^\[[:0-9a-f]+\]$/i.test(e.hostname))throw new g({input:e.href||e});if(/^\[/.test(e.host)&&!/^\[[:0-9a-f]+\](:\d+)?$/i.test(e.host))throw new g({input:e.href||e});return e}function I(e,t){var n=t||{};for(var r of f)n[r]=e[r];return n.hostname.startsWith("[")&&(n.hostname=n.hostname.slice(1,-1)),""!==n.port&&(n.port=Number(n.port)),n.path=n.search?n.pathname+n.search:n.pathname,n}function R(e,t){var n;for(var r in t)e.test(r)&&(n=t[r],delete t[r]);return null==n?void 0:String(n).trim()}function P(e,t,n){function r(n){k(Error.captureStackTrace)&&Error.captureStackTrace(this,this.constructor),Object.assign(this,n||{}),this.code=e,this.message=this.cause?t+": "+this.cause.message:t}return r.prototype=new(n||Error),Object.defineProperties(r.prototype,{constructor:{value:r,enumerable:!1},name:{value:"Error ["+e+"]",enumerable:!1}}),r}function O(e,t){for(var n of m)e.removeListener(n,v[n]);e.on("error",x),e.destroy(t)}function N(e){return"string"==typeof e||e instanceof String}function k(e){return"function"==typeof e}S.prototype=Object.create(l.prototype),S.prototype.abort=function(){O(this._currentRequest),this._currentRequest.abort(),this.emit("abort")},S.prototype.destroy=function(e){return O(this._currentRequest,e),T.call(this,e),this},S.prototype.write=function(e,t,n){if(this._ending)throw new E;if(!(N(e)||"object"==typeof(r=e)&&"length"in r))throw new TypeError("data should be a string, Buffer or Uint8Array");var r;k(t)&&(n=t,t=null),0!==e.length?this._requestBodyLength+e.length<=this._options.maxBodyLength?(this._requestBodyLength+=e.length,this._requestBodyBuffers.push({data:e,encoding:t}),this._currentRequest.write(e,t,n)):(this.emit("error",new b),this.abort()):n&&n()},S.prototype.end=function(e,t,n){if(k(e)?(n=e,e=t=null):k(t)&&(n=t,t=null),e){var r=this,o=this._currentRequest;this.write(e,t,(function(){r._ended=!0,o.end(null,null,n)})),this._ending=!0}else this._ended=this._ending=!0,this._currentRequest.end(null,null,n)},S.prototype.setHeader=function(e,t){this._options.headers[e]=t,this._currentRequest.setHeader(e,t)},S.prototype.removeHeader=function(e){delete this._options.headers[e],this._currentRequest.removeHeader(e)},S.prototype.setTimeout=function(e,t){var n=this;function r(t){t.setTimeout(e),t.removeListener("timeout",t.destroy),t.addListener("timeout",t.destroy)}function o(t){n._timeout&&clearTimeout(n._timeout),n._timeout=setTimeout((function(){n.emit("timeout"),i()}),e),r(t)}function i(){n._timeout&&(clearTimeout(n._timeout),n._timeout=null),n.removeListener("abort",i),n.removeListener("error",i),n.removeListener("response",i),n.removeListener("close",i),t&&n.removeListener("timeout",t),n.socket||n._currentRequest.removeListener("socket",o)}return t&&this.on("timeout",t),this.socket?o(this.socket):this._currentRequest.once("socket",o),this.on("socket",r),this.on("abort",i),this.on("error",i),this.on("response",i),this.on("close",i),this},["flushHeaders","getHeader","setNoDelay","setSocketKeepAlive"].forEach((function(e){S.prototype[e]=function(t,n){return this._currentRequest[e](t,n)}})),["aborted","connection","socket"].forEach((function(e){Object.defineProperty(S.prototype,e,{get:function(){return this._currentRequest[e]}})})),S.prototype._sanitizeOptions=function(e){if(e.headers||(e.headers={}),e.host&&(e.hostname||(e.hostname=e.host),delete e.host),!e.pathname&&e.path){var t=e.path.indexOf("?");t<0?e.pathname=e.path:(e.pathname=e.path.substring(0,t),e.search=e.path.substring(t))}},S.prototype._performRequest=function(){var e=this._options.protocol,t=this._options.nativeProtocols[e];if(!t)throw new TypeError("Unsupported protocol "+e);if(this._options.agents){var n=e.slice(0,-1);this._options.agent=this._options.agents[n]}var r=this._currentRequest=t.request(this._options,this._onNativeResponse);for(var o of(r._redirectable=this,m))r.on(o,v[o]);if(this._currentUrl=/^\//.test(this._options.path)?s.format(this._options):this._options.path,this._isRedirect){var i=0,a=this,c=this._requestBodyBuffers;!function e(t){if(r===a._currentRequest)if(t)a.emit("error",t);else if(i<c.length){var n=c[i++];r.finished||r.write(n.data,n.encoding,e)}else a._ended&&r.end()}()}},S.prototype._processResponse=function(e){var t=e.statusCode;this._options.trackRedirects&&this._redirects.push({url:this._currentUrl,headers:e.headers,statusCode:t});var n,r=e.headers.location;if(!r||!1===this._options.followRedirects||t<300||t>=400)return e.responseUrl=this._currentUrl,e.redirects=this._redirects,this.emit("response",e),void(this._requestBodyBuffers=[]);if(O(this._currentRequest),e.destroy(),++this._redirectCount>this._options.maxRedirects)throw new _;var o=this._options.beforeRedirect;o&&(n=Object.assign({Host:e.req.getHeader("host")},this._options.headers));var i=this._options.method;((301===t||302===t)&&"POST"===this._options.method||303===t&&!/^(?:GET|HEAD)$/.test(this._options.method))&&(this._options.method="GET",this._requestBodyBuffers=[],R(/^content-/i,this._options.headers));var c,u,l=R(/^host$/i,this._options.headers),f=w(this._currentUrl),m=l||f.host,v=/^\w+:/.test(r)?this._currentUrl:s.format(Object.assign(f,{host:m})),g=(c=r,u=v,h?new a(c,u):w(s.resolve(u,c)));if(d("redirecting to",g.href),this._isRedirect=!0,I(g,this._options),(g.protocol!==f.protocol&&"https:"!==g.protocol||g.host!==m&&!function(e,t){p(N(e)&&N(t));var n=e.length-t.length-1;return n>0&&"."===e[n]&&e.endsWith(t)}(g.host,m))&&R(/^(?:(?:proxy-)?authorization|cookie)$/i,this._options.headers),k(o)){var y={headers:e.headers,statusCode:t},b={url:v,method:i,headers:n};o(this._options,y,b),this._sanitizeOptions(this._options)}this._performRequest()},e.exports=C({http:c,https:u}),e.exports.wrap=C},737:(e,t,n)=>{var r=n(801),o=n(9023),i=n(6928),s=n(8611),a=n(5692),c=n(7016).parse,u=n(9896),l=n(2203).Stream,p=n(6049),d=n(1873),h=n(1362);function f(e){if(!(this instanceof f))return new f(e);for(var t in this._overheadLength=0,this._valueLength=0,this._valuesToMeasure=[],r.call(this),e=e||{})this[t]=e[t]}e.exports=f,o.inherits(f,r),f.LINE_BREAK="\r\n",f.DEFAULT_CONTENT_TYPE="application/octet-stream",f.prototype.append=function(e,t,n){"string"==typeof(n=n||{})&&(n={filename:n});var i=r.prototype.append.bind(this);if("number"==typeof t&&(t=""+t),o.isArray(t))this._error(new Error("Arrays are not supported."));else{var s=this._multiPartHeader(e,t,n),a=this._multiPartFooter();i(s),i(t),i(a),this._trackLength(s,t,n)}},f.prototype._trackLength=function(e,t,n){var r=0;null!=n.knownLength?r+=+n.knownLength:Buffer.isBuffer(t)?r=t.length:"string"==typeof t&&(r=Buffer.byteLength(t)),this._valueLength+=r,this._overheadLength+=Buffer.byteLength(e)+f.LINE_BREAK.length,t&&(t.path||t.readable&&t.hasOwnProperty("httpVersion")||t instanceof l)&&(n.knownLength||this._valuesToMeasure.push(t))},f.prototype._lengthRetriever=function(e,t){e.hasOwnProperty("fd")?null!=e.end&&e.end!=1/0&&null!=e.start?t(null,e.end+1-(e.start?e.start:0)):u.stat(e.path,(function(n,r){var o;n?t(n):(o=r.size-(e.start?e.start:0),t(null,o))})):e.hasOwnProperty("httpVersion")?t(null,+e.headers["content-length"]):e.hasOwnProperty("httpModule")?(e.on("response",(function(n){e.pause(),t(null,+n.headers["content-length"])})),e.resume()):t("Unknown stream")},f.prototype._multiPartHeader=function(e,t,n){if("string"==typeof n.header)return n.header;var r,o=this._getContentDisposition(t,n),i=this._getContentType(t,n),s="",a={"Content-Disposition":["form-data",'name="'+e+'"'].concat(o||[]),"Content-Type":[].concat(i||[])};for(var c in"object"==typeof n.header&&h(a,n.header),a)a.hasOwnProperty(c)&&null!=(r=a[c])&&(Array.isArray(r)||(r=[r]),r.length&&(s+=c+": "+r.join("; ")+f.LINE_BREAK));return"--"+this.getBoundary()+f.LINE_BREAK+s+f.LINE_BREAK},f.prototype._getContentDisposition=function(e,t){var n,r;return"string"==typeof t.filepath?n=i.normalize(t.filepath).replace(/\\/g,"/"):t.filename||e.name||e.path?n=i.basename(t.filename||e.name||e.path):e.readable&&e.hasOwnProperty("httpVersion")&&(n=i.basename(e.client._httpMessage.path||"")),n&&(r='filename="'+n+'"'),r},f.prototype._getContentType=function(e,t){var n=t.contentType;return!n&&e.name&&(n=p.lookup(e.name)),!n&&e.path&&(n=p.lookup(e.path)),!n&&e.readable&&e.hasOwnProperty("httpVersion")&&(n=e.headers["content-type"]),n||!t.filepath&&!t.filename||(n=p.lookup(t.filepath||t.filename)),n||"object"!=typeof e||(n=f.DEFAULT_CONTENT_TYPE),n},f.prototype._multiPartFooter=function(){return function(e){var t=f.LINE_BREAK;0===this._streams.length&&(t+=this._lastBoundary()),e(t)}.bind(this)},f.prototype._lastBoundary=function(){return"--"+this.getBoundary()+"--"+f.LINE_BREAK},f.prototype.getHeaders=function(e){var t,n={"content-type":"multipart/form-data; boundary="+this.getBoundary()};for(t in e)e.hasOwnProperty(t)&&(n[t.toLowerCase()]=e[t]);return n},f.prototype.setBoundary=function(e){this._boundary=e},f.prototype.getBoundary=function(){return this._boundary||this._generateBoundary(),this._boundary},f.prototype.getBuffer=function(){for(var e=new Buffer.alloc(0),t=this.getBoundary(),n=0,r=this._streams.length;n<r;n++)"function"!=typeof this._streams[n]&&(e=Buffer.isBuffer(this._streams[n])?Buffer.concat([e,this._streams[n]]):Buffer.concat([e,Buffer.from(this._streams[n])]),"string"==typeof this._streams[n]&&this._streams[n].substring(2,t.length+2)===t||(e=Buffer.concat([e,Buffer.from(f.LINE_BREAK)])));return Buffer.concat([e,Buffer.from(this._lastBoundary())])},f.prototype._generateBoundary=function(){for(var e="--------------------------",t=0;t<24;t++)e+=Math.floor(10*Math.random()).toString(16);this._boundary=e},f.prototype.getLengthSync=function(){var e=this._overheadLength+this._valueLength;return this._streams.length&&(e+=this._lastBoundary().length),this.hasKnownLength()||this._error(new Error("Cannot calculate proper length in synchronous way.")),e},f.prototype.hasKnownLength=function(){var e=!0;return this._valuesToMeasure.length&&(e=!1),e},f.prototype.getLength=function(e){var t=this._overheadLength+this._valueLength;this._streams.length&&(t+=this._lastBoundary().length),this._valuesToMeasure.length?d.parallel(this._valuesToMeasure,this._lengthRetriever,(function(n,r){n?e(n):(r.forEach((function(e){t+=e})),e(null,t))})):process.nextTick(e.bind(this,null,t))},f.prototype.submit=function(e,t){var n,r,o={method:"post"};return"string"==typeof e?(e=c(e),r=h({port:e.port,path:e.pathname,host:e.hostname,protocol:e.protocol},o)):(r=h(e,o)).port||(r.port="https:"==r.protocol?443:80),r.headers=this.getHeaders(e.headers),n="https:"==r.protocol?a.request(r):s.request(r),this.getLength(function(e,r){if(e&&"Unknown stream"!==e)this._error(e);else if(r&&n.setHeader("Content-Length",r),this.pipe(n),t){var o,i=function(e,r){return n.removeListener("error",i),n.removeListener("response",o),t.call(this,e,r)};o=i.bind(this,null),n.on("error",i),n.on("response",o)}}.bind(this)),n},f.prototype._error=function(e){this.error||(this.error=e,this.pause(),this.emit("error",e))},f.prototype.toString=function(){return"[object FormData]"}},1362:e=>{e.exports=function(e,t){return Object.keys(t).forEach((function(n){e[n]=e[n]||t[n]})),e}},5884:e=>{"use strict";e.exports=(e,t=process.argv)=>{const n=e.startsWith("-")?"":1===e.length?"-":"--",r=t.indexOf(n+e),o=t.indexOf("--");return-1!==r&&(-1===o||r<o)}},9848:function(e,t,n){"use strict";var r=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function s(e){try{c(r.next(e))}catch(e){i(e)}}function a(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(s,a)}c((r=r.apply(e,t||[])).next())}))},o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const i=o(n(9278)),s=o(n(4756)),a=o(n(7016)),c=o(n(5753)),u=o(n(2391)),l=n(9724),p=(0,c.default)("http-proxy-agent");class d extends l.Agent{constructor(e){let t;if(t="string"==typeof e?a.default.parse(e):e,!t)throw new Error("an HTTP(S) proxy server `host` and `port` must be specified!");p("Creating new HttpProxyAgent instance: %o",t),super(t);const n=Object.assign({},t);var r;this.secureProxy=t.secureProxy||"string"==typeof(r=n.protocol)&&/^https:?$/i.test(r),n.host=n.hostname||n.host,"string"==typeof n.port&&(n.port=parseInt(n.port,10)),!n.port&&n.host&&(n.port=this.secureProxy?443:80),n.host&&n.path&&(delete n.path,delete n.pathname),this.proxy=n}callback(e,t){return r(this,void 0,void 0,(function*(){const{proxy:n,secureProxy:r}=this,o=a.default.parse(e.path);let c;if(o.protocol||(o.protocol="http:"),o.hostname||(o.hostname=t.hostname||t.host||null),null==o.port&&(t.port,1)&&(o.port=String(t.port)),"80"===o.port&&(o.port=""),e.path=a.default.format(o),n.auth&&e.setHeader("Proxy-Authorization",`Basic ${Buffer.from(n.auth).toString("base64")}`),r?(p("Creating `tls.Socket`: %o",n),c=s.default.connect(n)):(p("Creating `net.Socket`: %o",n),c=i.default.connect(n)),e._header){let t,n;p("Regenerating stored HTTP header string for request"),e._header=null,e._implicitHeader(),e.output&&e.output.length>0?(p("Patching connection write() output buffer with updated header"),t=e.output[0],n=t.indexOf("\r\n\r\n")+4,e.output[0]=e._header+t.substring(n),p("Output buffer: %o",e.output)):e.outputData&&e.outputData.length>0&&(p("Patching connection write() output buffer with updated header"),t=e.outputData[0].data,n=t.indexOf("\r\n\r\n")+4,e.outputData[0].data=e._header+t.substring(n),p("Output buffer: %o",e.outputData[0].data))}return yield(0,u.default)(c,"connect"),c}))}}t.default=d},6645:function(e,t,n){"use strict";const r=(this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}})(n(9848));function o(e){return new r.default(e)}!function(e){e.HttpProxyAgent=r.default,e.prototype=r.default.prototype}(o||(o={})),e.exports=o},6329:function(e,t,n){"use strict";var r=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function s(e){try{c(r.next(e))}catch(e){i(e)}}function a(e){try{c(r.throw(e))}catch(e){i(e)}}function c(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(s,a)}c((r=r.apply(e,t||[])).next())}))},o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const i=o(n(9278)),s=o(n(4756)),a=o(n(7016)),c=o(n(2613)),u=o(n(5753)),l=n(9724),p=o(n(3868)),d=u.default("https-proxy-agent:agent");class h extends l.Agent{constructor(e){let t;if(t="string"==typeof e?a.default.parse(e):e,!t)throw new Error("an HTTP(S) proxy server `host` and `port` must be specified!");d("creating new HttpsProxyAgent instance: %o",t),super(t);const n=Object.assign({},t);var r;this.secureProxy=t.secureProxy||"string"==typeof(r=n.protocol)&&/^https:?$/i.test(r),n.host=n.hostname||n.host,"string"==typeof n.port&&(n.port=parseInt(n.port,10)),!n.port&&n.host&&(n.port=this.secureProxy?443:80),this.secureProxy&&!("ALPNProtocols"in n)&&(n.ALPNProtocols=["http 1.1"]),n.host&&n.path&&(delete n.path,delete n.pathname),this.proxy=n}callback(e,t){return r(this,void 0,void 0,(function*(){const{proxy:n,secureProxy:r}=this;let o;r?(d("Creating `tls.Socket`: %o",n),o=s.default.connect(n)):(d("Creating `net.Socket`: %o",n),o=i.default.connect(n));const a=Object.assign({},n.headers);let u=`CONNECT ${t.host}:${t.port} HTTP/1.1\r\n`;n.auth&&(a["Proxy-Authorization"]=`Basic ${Buffer.from(n.auth).toString("base64")}`);let{host:l,port:h,secureEndpoint:m}=t;(function(e,t){return Boolean(!t&&80===e||t&&443===e)})(h,m)||(l+=`:${h}`),a.Host=l,a.Connection="close";for(const e of Object.keys(a))u+=`${e}: ${a[e]}\r\n`;const v=p.default(o);o.write(`${u}\r\n`);const{statusCode:g,buffered:y}=yield v;if(200===g){if(e.once("socket",f),t.secureEndpoint){d("Upgrading socket connection to TLS");const e=t.servername||t.host;return s.default.connect(Object.assign(Object.assign({},function(e,...t){const n={};let r;for(r in e)t.includes(r)||(n[r]=e[r]);return n}(t,"host","hostname","path","port")),{socket:o,servername:e}))}return o}o.destroy();const _=new i.default.Socket({writable:!1});return _.readable=!0,e.once("socket",(e=>{d("replaying proxy buffer for failed request"),c.default(e.listenerCount("data")>0),e.push(y),e.push(null)})),_}))}}function f(e){e.resume()}t.default=h},2288:function(e,t,n){"use strict";const r=(this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}})(n(6329));function o(e){return new r.default(e)}!function(e){e.HttpsProxyAgent=r.default,e.prototype=r.default.prototype}(o||(o={})),e.exports=o},3868:function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});const o=r(n(5753)).default("https-proxy-agent:parse-proxy-response");t.default=function(e){return new Promise(((t,n)=>{let r=0;const i=[];function s(){const n=e.read();n?function(e){i.push(e),r+=e.length;const n=Buffer.concat(i,r);if(-1===n.indexOf("\r\n\r\n"))return o("have not received end of HTTP headers yet..."),void s();const a=n.toString("ascii",0,n.indexOf("\r\n")),c=+a.split(" ")[1];o("got proxy server response: %o",a),t({statusCode:c,buffered:n})}(n):e.once("readable",s)}function a(e){o("onclose had error %o",e)}function c(){o("onend")}e.on("error",(function t(r){e.removeListener("end",c),e.removeListener("error",t),e.removeListener("close",a),e.removeListener("readable",s),o("onerror %o",r),n(r)})),e.on("close",a),e.on("end",c),s()}))}},127:(e,t,n)=>{var r=n(9896),o="wx";if(process.version.match(/^v0\.[0-6]/)){var i=n(9140);o=i.O_TRUNC|i.O_CREAT|i.O_WRONLY|i.O_EXCL}var s,a=n(857);t.filetime="ctime","win32"==a.platform()&&(t.filetime="mtime");var c=n(9023);s=c.debuglog?c.debuglog("LOCKFILE"):/\blockfile\b/i.test(process.env.NODE_DEBUG)?function(){var e=c.format.apply(c,arguments);console.error("LOCKFILE %d %s",process.pid,e)}:function(){};var u={};n(9468)((function(){s("exit listener"),Object.keys(u).forEach(t.unlockSync)})),/^v0\.[0-8]\./.test(process.version)&&(s("uncaughtException, version = %s",process.version),process.on("uncaughtException",(function e(n){if(s("uncaughtException"),!process.listeners("uncaughtException").filter((function(t){return t!==e})).length){try{Object.keys(u).forEach(t.unlockSync)}catch(e){}throw process.removeListener("uncaughtException",e),n}}))),t.unlock=function(e,t){s("unlock",e),delete u[e],r.unlink(e,(function(e){t&&t()}))},t.unlockSync=function(e){s("unlockSync",e);try{r.unlinkSync(e)}catch(e){}delete u[e]},t.check=function(e,n,o){"function"==typeof n&&(o=n,n={}),s("check",e,n),r.open(e,"r",(function(e,i){return e?"ENOENT"!==e.code?o(e):o(null,!1):n.stale?void r.fstat(i,(function(e,s){if(e)return r.close(i,(function(t){return o(e)}));r.close(i,(function(e){var r=Date.now()-s[t.filetime].getTime();return o(e,r<=n.stale)}))})):r.close(i,(function(e){return o(e,!0)}))}))},t.checkSync=function(e,n){if(s("checkSync",e,n=n||{}),n.wait)throw new Error("opts.wait not supported sync for obvious reasons");try{var o=r.openSync(e,"r")}catch(e){if("ENOENT"!==e.code)throw e;return!1}if(!n.stale){try{r.closeSync(o)}catch(e){}return!0}if(n.stale){try{var i=r.fstatSync(o)}finally{r.closeSync(o)}return Date.now()-i[t.filetime].getTime()<=n.stale}};var l=1;function p(e,n,o,i,a){r.stat(n,(function(c,u){return c?"ENOENT"===c.code?(o.stale=!1,s("lock stale enoent retry",n,o),void t.lock(n,o,a)):a(c):Date.now()-u[t.filetime].getTime()<=o.stale?d(e,n,o,a):(s("lock stale",n,o),void(i?t.unlock(n,(function(e){if(e)return a(e);s("lock stale retry",n,o),r.link(n+".STALE",n,(function(e){r.unlink(n+".STALE",(function(){a(e)}))}))})):(s("acquire .STALE file lock",o),t.lock(n+".STALE",o,(function(t){if(t)return a(t);p(e,n,o,!0,a)})))))}))}function d(e,n,r,o){if(s("notStale",n,r),"number"!=typeof r.wait||r.wait<=0)return s("notStale, wait is not a number"),o(e);var i=Date.now(),a=r.start||i,c=a+r.wait;if(c<=i)return o(e);s("now=%d, wait until %d (delta=%d)",a,c,c-a);var u=Math.min(c-a,r.pollPeriod||100);setTimeout((function(){s("notStale, polling",n,r),t.lock(n,r,o)}),u)}function h(e,n,r){if("number"==typeof n.retries&&n.retries>0){var o=n.retries-1;return s("retryThrow",e,n,o),n.retries=o,t.lockSync(e,n)}throw r}t.lock=function(e,n,i){if("function"==typeof n&&(i=n,n={}),n.req=n.req||l++,s("lock",e,n),n.start=n.start||Date.now(),"number"==typeof n.retries&&n.retries>0){s("has retries",n.retries);var a=n.retries;n.retries=0,c=i,i=function r(o,i){if(s("retry-mutated callback"),a-=1,!o||a<0)return c(o,i);function u(){n.start=Date.now(),s("retrying",n.start),t.lock(e,n,r)}s("lock retry",e,n),n.retryWait?setTimeout(u,n.retryWait):u()}}var c;r.open(e,o,(function(t,o){return t?(s("failed to acquire lock",t),"EEXIST"!==t.code?(s("not EEXIST error",t),i(t)):n.stale?p(t,e,n,!1,i):d(t,e,n,i)):(s("locked",e,o),u[e]=o,r.close(o,(function(){return i()})))})),s("lock return")},t.lockSync=function(e,n){if((n=n||{}).req=n.req||l++,s("lockSync",e,n),n.wait||n.retryWait)throw new Error("opts.wait not supported sync for obvious reasons");try{var i=r.openSync(e,o);u[e]=i;try{r.closeSync(i)}catch(e){}return void s("locked sync!",e,i)}catch(o){if("EEXIST"!==o.code)return h(e,n,o);if(n.stale){var a=r.statSync(e)[t.filetime].getTime();!(a%1e3)&&n.stale%1e3&&(n.stale=1e3*Math.ceil(n.stale/1e3));var c=Date.now()-a;if(c>n.stale)return s("lockSync stale",e,n,c),t.unlockSync(e),t.lockSync(e,n)}return s("failed to lock",e,n,o),h(e,n,o)}}},7598:(e,t,n)=>{e.exports=n(1813)},6049:(e,t,n)=>{"use strict";var r,o,i,s=n(7598),a=n(6928).extname,c=/^\s*([^;\s]*)(?:;|\s|$)/,u=/^text\//i;function l(e){if(!e||"string"!=typeof e)return!1;var t=c.exec(e),n=t&&s[t[1].toLowerCase()];return n&&n.charset?n.charset:!(!t||!u.test(t[1]))&&"UTF-8"}t.charset=l,t.charsets={lookup:l},t.contentType=function(e){if(!e||"string"!=typeof e)return!1;var n=-1===e.indexOf("/")?t.lookup(e):e;if(!n)return!1;if(-1===n.indexOf("charset")){var r=t.charset(n);r&&(n+="; charset="+r.toLowerCase())}return n},t.extension=function(e){if(!e||"string"!=typeof e)return!1;var n=c.exec(e),r=n&&t.extensions[n[1].toLowerCase()];return!(!r||!r.length)&&r[0]},t.extensions=Object.create(null),t.lookup=function(e){if(!e||"string"!=typeof e)return!1;var n=a("x."+e).toLowerCase().substr(1);return n&&t.types[n]||!1},t.types=Object.create(null),r=t.extensions,o=t.types,i=["nginx","apache",void 0,"iana"],Object.keys(s).forEach((function(e){var t=s[e],n=t.extensions;if(n&&n.length){r[e]=n;for(var a=0;a<n.length;a++){var c=n[a];if(o[c]){var u=i.indexOf(s[o[c]].source),l=i.indexOf(t.source);if("application/octet-stream"!==o[c]&&(u>l||u===l&&"application/"===o[c].substr(0,12)))continue}o[c]=e}}}))},6504:(e,t,n)=>{"use strict";var r=n(7016).parse,o={ftp:21,gopher:70,http:80,https:443,ws:80,wss:443},i=String.prototype.endsWith||function(e){return e.length<=this.length&&-1!==this.indexOf(e,this.length-e.length)};function s(e){return process.env[e.toLowerCase()]||process.env[e.toUpperCase()]||""}t.getProxyForUrl=function(e){var t="string"==typeof e?r(e):e||{},n=t.protocol,a=t.host,c=t.port;if("string"!=typeof a||!a||"string"!=typeof n)return"";if(n=n.split(":",1)[0],!function(e,t){var n=(s("npm_config_no_proxy")||s("no_proxy")).toLowerCase();return!n||"*"!==n&&n.split(/[,\s]/).every((function(n){if(!n)return!0;var r=n.match(/^(.+):(\d+)$/),o=r?r[1]:n,s=r?parseInt(r[2]):0;return!(!s||s===t)||(/^[.*]/.test(o)?("*"===o.charAt(0)&&(o=o.slice(1)),!i.call(e,o)):e!==o)}))}(a=a.replace(/:\d*$/,""),c=parseInt(c)||o[n]||0))return"";var u=s("npm_config_"+n+"_proxy")||s(n+"_proxy")||s("npm_config_proxy")||s("all_proxy");return u&&-1===u.indexOf("://")&&(u=n+"://"+u),u}},4043:(e,t,n)=>{!function(e){e.parser=function(e,t){return new o(e,t)},e.SAXParser=o,e.SAXStream=s,e.createStream=function(e,t){return new s(e,t)},e.MAX_BUFFER_LENGTH=65536;var t,r=["comment","sgmlDecl","textNode","tagName","doctype","procInstName","procInstBody","entity","attribName","attribValue","cdata","script"];function o(t,n){if(!(this instanceof o))return new o(t,n);var i=this;!function(e){for(var t=0,n=r.length;t<n;t++)e[r[t]]=""}(i),i.q=i.c="",i.bufferCheckPosition=e.MAX_BUFFER_LENGTH,i.opt=n||{},i.opt.lowercase=i.opt.lowercase||i.opt.lowercasetags,i.looseCase=i.opt.lowercase?"toLowerCase":"toUpperCase",i.tags=[],i.closed=i.closedRoot=i.sawRoot=!1,i.tag=i.error=null,i.strict=!!t,i.noscript=!(!t&&!i.opt.noscript),i.state=C.BEGIN,i.strictEntities=i.opt.strictEntities,i.ENTITIES=i.strictEntities?Object.create(e.XML_ENTITIES):Object.create(e.ENTITIES),i.attribList=[],i.opt.xmlns&&(i.ns=Object.create(p)),i.trackPosition=!1!==i.opt.position,i.trackPosition&&(i.position=i.line=i.column=0),w(i,"onready")}e.EVENTS=["text","processinginstruction","sgmldeclaration","doctype","comment","opentagstart","attribute","opentag","closetag","opencdata","cdata","closecdata","error","end","ready","script","opennamespace","closenamespace"],Object.create||(Object.create=function(e){function t(){}return t.prototype=e,new t}),Object.keys||(Object.keys=function(e){var t=[];for(var n in e)e.hasOwnProperty(n)&&t.push(n);return t}),o.prototype={end:function(){O(this)},write:function(t){var n=this;if(this.error)throw this.error;if(n.closed)return P(n,"Cannot write after close. Assign an onready handler.");if(null===t)return O(n);"object"==typeof t&&(t=t.toString());for(var o=0,i="";i=z(t,o++),n.c=i,i;)switch(n.trackPosition&&(n.position++,"\n"===i?(n.line++,n.column=0):n.column++),n.state){case C.BEGIN:if(n.state=C.BEGIN_WHITESPACE,"\ufeff"===i)continue;F(n,i);continue;case C.BEGIN_WHITESPACE:F(n,i);continue;case C.TEXT:if(n.sawRoot&&!n.closedRoot){for(var s=o-1;i&&"<"!==i&&"&"!==i;)(i=z(t,o++))&&n.trackPosition&&(n.position++,"\n"===i?(n.line++,n.column=0):n.column++);n.textNode+=t.substring(s,o-1)}"<"!==i||n.sawRoot&&n.closedRoot&&!n.strict?(v(i)||n.sawRoot&&!n.closedRoot||N(n,"Text data outside of root node."),"&"===i?n.state=C.TEXT_ENTITY:n.textNode+=i):(n.state=C.OPEN_WAKA,n.startTagPosition=n.position);continue;case C.SCRIPT:"<"===i?n.state=C.SCRIPT_ENDING:n.script+=i;continue;case C.SCRIPT_ENDING:"/"===i?n.state=C.CLOSE_TAG:(n.script+="<"+i,n.state=C.SCRIPT);continue;case C.OPEN_WAKA:if("!"===i)n.state=C.SGML_DECL,n.sgmlDecl="";else if(v(i));else if(_(d,i))n.state=C.OPEN_TAG,n.tagName=i;else if("/"===i)n.state=C.CLOSE_TAG,n.tagName="";else if("?"===i)n.state=C.PROC_INST,n.procInstName=n.procInstBody="";else{if(N(n,"Unencoded <"),n.startTagPosition+1<n.position){var u=n.position-n.startTagPosition;i=new Array(u).join(" ")+i}n.textNode+="<"+i,n.state=C.TEXT}continue;case C.SGML_DECL:(n.sgmlDecl+i).toUpperCase()===a?(A(n,"onopencdata"),n.state=C.CDATA,n.sgmlDecl="",n.cdata=""):n.sgmlDecl+i==="--"?(n.state=C.COMMENT,n.comment="",n.sgmlDecl=""):(n.sgmlDecl+i).toUpperCase()===c?(n.state=C.DOCTYPE,(n.doctype||n.sawRoot)&&N(n,"Inappropriately located doctype declaration"),n.doctype="",n.sgmlDecl=""):">"===i?(A(n,"onsgmldeclaration",n.sgmlDecl),n.sgmlDecl="",n.state=C.TEXT):g(i)?(n.state=C.SGML_DECL_QUOTED,n.sgmlDecl+=i):n.sgmlDecl+=i;continue;case C.SGML_DECL_QUOTED:i===n.q&&(n.state=C.SGML_DECL,n.q=""),n.sgmlDecl+=i;continue;case C.DOCTYPE:">"===i?(n.state=C.TEXT,A(n,"ondoctype",n.doctype),n.doctype=!0):(n.doctype+=i,"["===i?n.state=C.DOCTYPE_DTD:g(i)&&(n.state=C.DOCTYPE_QUOTED,n.q=i));continue;case C.DOCTYPE_QUOTED:n.doctype+=i,i===n.q&&(n.q="",n.state=C.DOCTYPE);continue;case C.DOCTYPE_DTD:n.doctype+=i,"]"===i?n.state=C.DOCTYPE:g(i)&&(n.state=C.DOCTYPE_DTD_QUOTED,n.q=i);continue;case C.DOCTYPE_DTD_QUOTED:n.doctype+=i,i===n.q&&(n.state=C.DOCTYPE_DTD,n.q="");continue;case C.COMMENT:"-"===i?n.state=C.COMMENT_ENDING:n.comment+=i;continue;case C.COMMENT_ENDING:"-"===i?(n.state=C.COMMENT_ENDED,n.comment=R(n.opt,n.comment),n.comment&&A(n,"oncomment",n.comment),n.comment=""):(n.comment+="-"+i,n.state=C.COMMENT);continue;case C.COMMENT_ENDED:">"!==i?(N(n,"Malformed comment"),n.comment+="--"+i,n.state=C.COMMENT):n.state=C.TEXT;continue;case C.CDATA:"]"===i?n.state=C.CDATA_ENDING:n.cdata+=i;continue;case C.CDATA_ENDING:"]"===i?n.state=C.CDATA_ENDING_2:(n.cdata+="]"+i,n.state=C.CDATA);continue;case C.CDATA_ENDING_2:">"===i?(n.cdata&&A(n,"oncdata",n.cdata),A(n,"onclosecdata"),n.cdata="",n.state=C.TEXT):"]"===i?n.cdata+="]":(n.cdata+="]]"+i,n.state=C.CDATA);continue;case C.PROC_INST:"?"===i?n.state=C.PROC_INST_ENDING:v(i)?n.state=C.PROC_INST_BODY:n.procInstName+=i;continue;case C.PROC_INST_BODY:if(!n.procInstBody&&v(i))continue;"?"===i?n.state=C.PROC_INST_ENDING:n.procInstBody+=i;continue;case C.PROC_INST_ENDING:">"===i?(A(n,"onprocessinginstruction",{name:n.procInstName,body:n.procInstBody}),n.procInstName=n.procInstBody="",n.state=C.TEXT):(n.procInstBody+="?"+i,n.state=C.PROC_INST_BODY);continue;case C.OPEN_TAG:_(h,i)?n.tagName+=i:(k(n),">"===i?L(n):"/"===i?n.state=C.OPEN_TAG_SLASH:(v(i)||N(n,"Invalid character in tag name"),n.state=C.ATTRIB));continue;case C.OPEN_TAG_SLASH:">"===i?(L(n,!0),j(n)):(N(n,"Forward-slash in opening tag not followed by >"),n.state=C.ATTRIB);continue;case C.ATTRIB:if(v(i))continue;">"===i?L(n):"/"===i?n.state=C.OPEN_TAG_SLASH:_(d,i)?(n.attribName=i,n.attribValue="",n.state=C.ATTRIB_NAME):N(n,"Invalid attribute name");continue;case C.ATTRIB_NAME:"="===i?n.state=C.ATTRIB_VALUE:">"===i?(N(n,"Attribute without value"),n.attribValue=n.attribName,M(n),L(n)):v(i)?n.state=C.ATTRIB_NAME_SAW_WHITE:_(h,i)?n.attribName+=i:N(n,"Invalid attribute name");continue;case C.ATTRIB_NAME_SAW_WHITE:if("="===i)n.state=C.ATTRIB_VALUE;else{if(v(i))continue;N(n,"Attribute without value"),n.tag.attributes[n.attribName]="",n.attribValue="",A(n,"onattribute",{name:n.attribName,value:""}),n.attribName="",">"===i?L(n):_(d,i)?(n.attribName=i,n.state=C.ATTRIB_NAME):(N(n,"Invalid attribute name"),n.state=C.ATTRIB)}continue;case C.ATTRIB_VALUE:if(v(i))continue;g(i)?(n.q=i,n.state=C.ATTRIB_VALUE_QUOTED):(N(n,"Unquoted attribute value"),n.state=C.ATTRIB_VALUE_UNQUOTED,n.attribValue=i);continue;case C.ATTRIB_VALUE_QUOTED:if(i!==n.q){"&"===i?n.state=C.ATTRIB_VALUE_ENTITY_Q:n.attribValue+=i;continue}M(n),n.q="",n.state=C.ATTRIB_VALUE_CLOSED;continue;case C.ATTRIB_VALUE_CLOSED:v(i)?n.state=C.ATTRIB:">"===i?L(n):"/"===i?n.state=C.OPEN_TAG_SLASH:_(d,i)?(N(n,"No whitespace between attributes"),n.attribName=i,n.attribValue="",n.state=C.ATTRIB_NAME):N(n,"Invalid attribute name");continue;case C.ATTRIB_VALUE_UNQUOTED:if(!y(i)){"&"===i?n.state=C.ATTRIB_VALUE_ENTITY_U:n.attribValue+=i;continue}M(n),">"===i?L(n):n.state=C.ATTRIB;continue;case C.CLOSE_TAG:if(n.tagName)">"===i?j(n):_(h,i)?n.tagName+=i:n.script?(n.script+="</"+n.tagName,n.tagName="",n.state=C.SCRIPT):(v(i)||N(n,"Invalid tagname in closing tag"),n.state=C.CLOSE_TAG_SAW_WHITE);else{if(v(i))continue;b(d,i)?n.script?(n.script+="</"+i,n.state=C.SCRIPT):N(n,"Invalid tagname in closing tag."):n.tagName=i}continue;case C.CLOSE_TAG_SAW_WHITE:if(v(i))continue;">"===i?j(n):N(n,"Invalid characters in closing tag");continue;case C.TEXT_ENTITY:case C.ATTRIB_VALUE_ENTITY_Q:case C.ATTRIB_VALUE_ENTITY_U:var l,p;switch(n.state){case C.TEXT_ENTITY:l=C.TEXT,p="textNode";break;case C.ATTRIB_VALUE_ENTITY_Q:l=C.ATTRIB_VALUE_QUOTED,p="attribValue";break;case C.ATTRIB_VALUE_ENTITY_U:l=C.ATTRIB_VALUE_UNQUOTED,p="attribValue"}if(";"===i)if(n.opt.unparsedEntities){var E=U(n);n.entity="",n.state=l,n.write(E)}else n[p]+=U(n),n.entity="",n.state=l;else _(n.entity.length?m:f,i)?n.entity+=i:(N(n,"Invalid character in entity name"),n[p]+="&"+n.entity+i,n.entity="",n.state=l);continue;default:throw new Error(n,"Unknown state: "+n.state)}return n.position>=n.bufferCheckPosition&&function(t){for(var n=Math.max(e.MAX_BUFFER_LENGTH,10),o=0,i=0,s=r.length;i<s;i++){var a=t[r[i]].length;if(a>n)switch(r[i]){case"textNode":I(t);break;case"cdata":A(t,"oncdata",t.cdata),t.cdata="";break;case"script":A(t,"onscript",t.script),t.script="";break;default:P(t,"Max buffer length exceeded: "+r[i])}o=Math.max(o,a)}var c=e.MAX_BUFFER_LENGTH-o;t.bufferCheckPosition=c+t.position}(n),n},resume:function(){return this.error=null,this},close:function(){return this.write(null)},flush:function(){var e;I(e=this),""!==e.cdata&&(A(e,"oncdata",e.cdata),e.cdata=""),""!==e.script&&(A(e,"onscript",e.script),e.script="")}};try{t=n(2203).Stream}catch(e){t=function(){}}t||(t=function(){});var i=e.EVENTS.filter((function(e){return"error"!==e&&"end"!==e}));function s(e,n){if(!(this instanceof s))return new s(e,n);t.apply(this),this._parser=new o(e,n),this.writable=!0,this.readable=!0;var r=this;this._parser.onend=function(){r.emit("end")},this._parser.onerror=function(e){r.emit("error",e),r._parser.error=null},this._decoder=null,i.forEach((function(e){Object.defineProperty(r,"on"+e,{get:function(){return r._parser["on"+e]},set:function(t){if(!t)return r.removeAllListeners(e),r._parser["on"+e]=t,t;r.on(e,t)},enumerable:!0,configurable:!1})}))}s.prototype=Object.create(t.prototype,{constructor:{value:s}}),s.prototype.write=function(e){if("function"==typeof Buffer&&"function"==typeof Buffer.isBuffer&&Buffer.isBuffer(e)){if(!this._decoder){var t=n(3193).StringDecoder;this._decoder=new t("utf8")}e=this._decoder.write(e)}return this._parser.write(e.toString()),this.emit("data",e),!0},s.prototype.end=function(e){return e&&e.length&&this.write(e),this._parser.end(),!0},s.prototype.on=function(e,n){var r=this;return r._parser["on"+e]||-1===i.indexOf(e)||(r._parser["on"+e]=function(){var t=1===arguments.length?[arguments[0]]:Array.apply(null,arguments);t.splice(0,0,e),r.emit.apply(r,t)}),t.prototype.on.call(r,e,n)};var a="[CDATA[",c="DOCTYPE",u="http://www.w3.org/XML/1998/namespace",l="http://www.w3.org/2000/xmlns/",p={xml:u,xmlns:l},d=/[:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,h=/[:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\u00B7\u0300-\u036F\u203F-\u2040.\d-]/,f=/[#:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,m=/[#:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\u00B7\u0300-\u036F\u203F-\u2040.\d-]/;function v(e){return" "===e||"\n"===e||"\r"===e||"\t"===e}function g(e){return'"'===e||"'"===e}function y(e){return">"===e||v(e)}function _(e,t){return e.test(t)}function b(e,t){return!_(e,t)}var E,T,S,C=0;for(var x in e.STATE={BEGIN:C++,BEGIN_WHITESPACE:C++,TEXT:C++,TEXT_ENTITY:C++,OPEN_WAKA:C++,SGML_DECL:C++,SGML_DECL_QUOTED:C++,DOCTYPE:C++,DOCTYPE_QUOTED:C++,DOCTYPE_DTD:C++,DOCTYPE_DTD_QUOTED:C++,COMMENT_STARTING:C++,COMMENT:C++,COMMENT_ENDING:C++,COMMENT_ENDED:C++,CDATA:C++,CDATA_ENDING:C++,CDATA_ENDING_2:C++,PROC_INST:C++,PROC_INST_BODY:C++,PROC_INST_ENDING:C++,OPEN_TAG:C++,OPEN_TAG_SLASH:C++,ATTRIB:C++,ATTRIB_NAME:C++,ATTRIB_NAME_SAW_WHITE:C++,ATTRIB_VALUE:C++,ATTRIB_VALUE_QUOTED:C++,ATTRIB_VALUE_CLOSED:C++,ATTRIB_VALUE_UNQUOTED:C++,ATTRIB_VALUE_ENTITY_Q:C++,ATTRIB_VALUE_ENTITY_U:C++,CLOSE_TAG:C++,CLOSE_TAG_SAW_WHITE:C++,SCRIPT:C++,SCRIPT_ENDING:C++},e.XML_ENTITIES={amp:"&",gt:">",lt:"<",quot:'"',apos:"'"},e.ENTITIES={amp:"&",gt:">",lt:"<",quot:'"',apos:"'",AElig:198,Aacute:193,Acirc:194,Agrave:192,Aring:197,Atilde:195,Auml:196,Ccedil:199,ETH:208,Eacute:201,Ecirc:202,Egrave:200,Euml:203,Iacute:205,Icirc:206,Igrave:204,Iuml:207,Ntilde:209,Oacute:211,Ocirc:212,Ograve:210,Oslash:216,Otilde:213,Ouml:214,THORN:222,Uacute:218,Ucirc:219,Ugrave:217,Uuml:220,Yacute:221,aacute:225,acirc:226,aelig:230,agrave:224,aring:229,atilde:227,auml:228,ccedil:231,eacute:233,ecirc:234,egrave:232,eth:240,euml:235,iacute:237,icirc:238,igrave:236,iuml:239,ntilde:241,oacute:243,ocirc:244,ograve:242,oslash:248,otilde:245,ouml:246,szlig:223,thorn:254,uacute:250,ucirc:251,ugrave:249,uuml:252,yacute:253,yuml:255,copy:169,reg:174,nbsp:160,iexcl:161,cent:162,pound:163,curren:164,yen:165,brvbar:166,sect:167,uml:168,ordf:170,laquo:171,not:172,shy:173,macr:175,deg:176,plusmn:177,sup1:185,sup2:178,sup3:179,acute:180,micro:181,para:182,middot:183,cedil:184,ordm:186,raquo:187,frac14:188,frac12:189,frac34:190,iquest:191,times:215,divide:247,OElig:338,oelig:339,Scaron:352,scaron:353,Yuml:376,fnof:402,circ:710,tilde:732,Alpha:913,Beta:914,Gamma:915,Delta:916,Epsilon:917,Zeta:918,Eta:919,Theta:920,Iota:921,Kappa:922,Lambda:923,Mu:924,Nu:925,Xi:926,Omicron:927,Pi:928,Rho:929,Sigma:931,Tau:932,Upsilon:933,Phi:934,Chi:935,Psi:936,Omega:937,alpha:945,beta:946,gamma:947,delta:948,epsilon:949,zeta:950,eta:951,theta:952,iota:953,kappa:954,lambda:955,mu:956,nu:957,xi:958,omicron:959,pi:960,rho:961,sigmaf:962,sigma:963,tau:964,upsilon:965,phi:966,chi:967,psi:968,omega:969,thetasym:977,upsih:978,piv:982,ensp:8194,emsp:8195,thinsp:8201,zwnj:8204,zwj:8205,lrm:8206,rlm:8207,ndash:8211,mdash:8212,lsquo:8216,rsquo:8217,sbquo:8218,ldquo:8220,rdquo:8221,bdquo:8222,dagger:8224,Dagger:8225,bull:8226,hellip:8230,permil:8240,prime:8242,Prime:8243,lsaquo:8249,rsaquo:8250,oline:8254,frasl:8260,euro:8364,image:8465,weierp:8472,real:8476,trade:8482,alefsym:8501,larr:8592,uarr:8593,rarr:8594,darr:8595,harr:8596,crarr:8629,lArr:8656,uArr:8657,rArr:8658,dArr:8659,hArr:8660,forall:8704,part:8706,exist:8707,empty:8709,nabla:8711,isin:8712,notin:8713,ni:8715,prod:8719,sum:8721,minus:8722,lowast:8727,radic:8730,prop:8733,infin:8734,ang:8736,and:8743,or:8744,cap:8745,cup:8746,int:8747,there4:8756,sim:8764,cong:8773,asymp:8776,ne:8800,equiv:8801,le:8804,ge:8805,sub:8834,sup:8835,nsub:8836,sube:8838,supe:8839,oplus:8853,otimes:8855,perp:8869,sdot:8901,lceil:8968,rceil:8969,lfloor:8970,rfloor:8971,lang:9001,rang:9002,loz:9674,spades:9824,clubs:9827,hearts:9829,diams:9830},Object.keys(e.ENTITIES).forEach((function(t){var n=e.ENTITIES[t],r="number"==typeof n?String.fromCharCode(n):n;e.ENTITIES[t]=r})),e.STATE)e.STATE[e.STATE[x]]=x;function w(e,t,n){e[t]&&e[t](n)}function A(e,t,n){e.textNode&&I(e),w(e,t,n)}function I(e){e.textNode=R(e.opt,e.textNode),e.textNode&&w(e,"ontext",e.textNode),e.textNode=""}function R(e,t){return e.trim&&(t=t.trim()),e.normalize&&(t=t.replace(/\s+/g," ")),t}function P(e,t){return I(e),e.trackPosition&&(t+="\nLine: "+e.line+"\nColumn: "+e.column+"\nChar: "+e.c),t=new Error(t),e.error=t,w(e,"onerror",t),e}function O(e){return e.sawRoot&&!e.closedRoot&&N(e,"Unclosed root tag"),e.state!==C.BEGIN&&e.state!==C.BEGIN_WHITESPACE&&e.state!==C.TEXT&&P(e,"Unexpected end"),I(e),e.c="",e.closed=!0,w(e,"onend"),o.call(e,e.strict,e.opt),e}function N(e,t){if("object"!=typeof e||!(e instanceof o))throw new Error("bad call to strictFail");e.strict&&P(e,t)}function k(e){e.strict||(e.tagName=e.tagName[e.looseCase]());var t=e.tags[e.tags.length-1]||e,n=e.tag={name:e.tagName,attributes:{}};e.opt.xmlns&&(n.ns=t.ns),e.attribList.length=0,A(e,"onopentagstart",n)}function D(e,t){var n=e.indexOf(":")<0?["",e]:e.split(":"),r=n[0],o=n[1];return t&&"xmlns"===e&&(r="xmlns",o=""),{prefix:r,local:o}}function M(e){if(e.strict||(e.attribName=e.attribName[e.looseCase]()),-1!==e.attribList.indexOf(e.attribName)||e.tag.attributes.hasOwnProperty(e.attribName))e.attribName=e.attribValue="";else{if(e.opt.xmlns){var t=D(e.attribName,!0),n=t.prefix,r=t.local;if("xmlns"===n)if("xml"===r&&e.attribValue!==u)N(e,"xml: prefix must be bound to "+u+"\nActual: "+e.attribValue);else if("xmlns"===r&&e.attribValue!==l)N(e,"xmlns: prefix must be bound to "+l+"\nActual: "+e.attribValue);else{var o=e.tag,i=e.tags[e.tags.length-1]||e;o.ns===i.ns&&(o.ns=Object.create(i.ns)),o.ns[r]=e.attribValue}e.attribList.push([e.attribName,e.attribValue])}else e.tag.attributes[e.attribName]=e.attribValue,A(e,"onattribute",{name:e.attribName,value:e.attribValue});e.attribName=e.attribValue=""}}function L(e,t){if(e.opt.xmlns){var n=e.tag,r=D(e.tagName);n.prefix=r.prefix,n.local=r.local,n.uri=n.ns[r.prefix]||"",n.prefix&&!n.uri&&(N(e,"Unbound namespace prefix: "+JSON.stringify(e.tagName)),n.uri=r.prefix);var o=e.tags[e.tags.length-1]||e;n.ns&&o.ns!==n.ns&&Object.keys(n.ns).forEach((function(t){A(e,"onopennamespace",{prefix:t,uri:n.ns[t]})}));for(var i=0,s=e.attribList.length;i<s;i++){var a=e.attribList[i],c=a[0],u=a[1],l=D(c,!0),p=l.prefix,d=l.local,h=""===p?"":n.ns[p]||"",f={name:c,value:u,prefix:p,local:d,uri:h};p&&"xmlns"!==p&&!h&&(N(e,"Unbound namespace prefix: "+JSON.stringify(p)),f.uri=p),e.tag.attributes[c]=f,A(e,"onattribute",f)}e.attribList.length=0}e.tag.isSelfClosing=!!t,e.sawRoot=!0,e.tags.push(e.tag),A(e,"onopentag",e.tag),t||(e.noscript||"script"!==e.tagName.toLowerCase()?e.state=C.TEXT:e.state=C.SCRIPT,e.tag=null,e.tagName=""),e.attribName=e.attribValue="",e.attribList.length=0}function j(e){if(!e.tagName)return N(e,"Weird empty close tag."),e.textNode+="</>",void(e.state=C.TEXT);if(e.script){if("script"!==e.tagName)return e.script+="</"+e.tagName+">",e.tagName="",void(e.state=C.SCRIPT);A(e,"onscript",e.script),e.script=""}var t=e.tags.length,n=e.tagName;e.strict||(n=n[e.looseCase]());for(var r=n;t--&&e.tags[t].name!==r;)N(e,"Unexpected close tag");if(t<0)return N(e,"Unmatched closing tag: "+e.tagName),e.textNode+="</"+e.tagName+">",void(e.state=C.TEXT);e.tagName=n;for(var o=e.tags.length;o-- >t;){var i=e.tag=e.tags.pop();e.tagName=e.tag.name,A(e,"onclosetag",e.tagName);var s={};for(var a in i.ns)s[a]=i.ns[a];var c=e.tags[e.tags.length-1]||e;e.opt.xmlns&&i.ns!==c.ns&&Object.keys(i.ns).forEach((function(t){var n=i.ns[t];A(e,"onclosenamespace",{prefix:t,uri:n})}))}0===t&&(e.closedRoot=!0),e.tagName=e.attribValue=e.attribName="",e.attribList.length=0,e.state=C.TEXT}function U(e){var t,n=e.entity,r=n.toLowerCase(),o="";return e.ENTITIES[n]?e.ENTITIES[n]:e.ENTITIES[r]?e.ENTITIES[r]:("#"===(n=r).charAt(0)&&("x"===n.charAt(1)?(n=n.slice(2),o=(t=parseInt(n,16)).toString(16)):(n=n.slice(1),o=(t=parseInt(n,10)).toString(10))),n=n.replace(/^0+/,""),isNaN(t)||o.toLowerCase()!==n?(N(e,"Invalid character entity"),"&"+e.entity+";"):String.fromCodePoint(t))}function F(e,t){"<"===t?(e.state=C.OPEN_WAKA,e.startTagPosition=e.position):v(t)||(N(e,"Non-whitespace before first tag."),e.textNode=t,e.state=C.TEXT)}function z(e,t){var n="";return t<e.length&&(n=e.charAt(t)),n}C=e.STATE,String.fromCodePoint||(E=String.fromCharCode,T=Math.floor,S=function(){var e,t,n=[],r=-1,o=arguments.length;if(!o)return"";for(var i="";++r<o;){var s=Number(arguments[r]);if(!isFinite(s)||s<0||s>1114111||T(s)!==s)throw RangeError("Invalid code point: "+s);s<=65535?n.push(s):(e=55296+((s-=65536)>>10),t=s%1024+56320,n.push(e,t)),(r+1===o||n.length>16384)&&(i+=E.apply(null,n),n.length=0)}return i},Object.defineProperty?Object.defineProperty(String,"fromCodePoint",{value:S,configurable:!0,writable:!0}):String.fromCodePoint=S)}(t)},9468:(e,t,n)=>{var r=global.process;const o=function(e){return e&&"object"==typeof e&&"function"==typeof e.removeListener&&"function"==typeof e.emit&&"function"==typeof e.reallyExit&&"function"==typeof e.listeners&&"function"==typeof e.kill&&"number"==typeof e.pid&&"function"==typeof e.on};if(o(r)){var i,s=n(2613),a=n(7205),c=/^win/i.test(r.platform),u=n(4434);"function"!=typeof u&&(u=u.EventEmitter),r.__signal_exit_emitter__?i=r.__signal_exit_emitter__:((i=r.__signal_exit_emitter__=new u).count=0,i.emitted={}),i.infinite||(i.setMaxListeners(1/0),i.infinite=!0),e.exports=function(e,t){if(!o(global.process))return function(){};s.equal(typeof e,"function","a callback must be provided for exit handler"),!1===h&&f();var n="exit";return t&&t.alwaysLast&&(n="afterexit"),i.on(n,e),function(){i.removeListener(n,e),0===i.listeners("exit").length&&0===i.listeners("afterexit").length&&l()}};var l=function(){h&&o(global.process)&&(h=!1,a.forEach((function(e){try{r.removeListener(e,d[e])}catch(e){}})),r.emit=g,r.reallyExit=m,i.count-=1)};e.exports.unload=l;var p=function(e,t,n){i.emitted[e]||(i.emitted[e]=!0,i.emit(e,t,n))},d={};a.forEach((function(e){d[e]=function(){o(global.process)&&r.listeners(e).length===i.count&&(l(),p("exit",null,e),p("afterexit",null,e),c&&"SIGHUP"===e&&(e="SIGINT"),r.kill(r.pid,e))}})),e.exports.signals=function(){return a};var h=!1,f=function(){!h&&o(global.process)&&(h=!0,i.count+=1,a=a.filter((function(e){try{return r.on(e,d[e]),!0}catch(e){return!1}})),r.emit=y,r.reallyExit=v)};e.exports.load=f;var m=r.reallyExit,v=function(e){o(global.process)&&(r.exitCode=e||0,p("exit",r.exitCode,null),p("afterexit",r.exitCode,null),m.call(r,r.exitCode))},g=r.emit,y=function(e,t){if("exit"===e&&o(global.process)){void 0!==t&&(r.exitCode=t);var n=g.apply(this,arguments);return p("exit",r.exitCode,null),p("afterexit",r.exitCode,null),n}return g.apply(this,arguments)}}else e.exports=function(){return function(){}}},7205:e=>{e.exports=["SIGABRT","SIGALRM","SIGHUP","SIGINT","SIGTERM"],"win32"!==process.platform&&e.exports.push("SIGVTALRM","SIGXCPU","SIGXFSZ","SIGUSR2","SIGTRAP","SIGSYS","SIGQUIT","SIGIOT"),"linux"===process.platform&&e.exports.push("SIGIO","SIGPOLL","SIGPWR","SIGSTKFLT","SIGUNUSED")},7687:(e,t,n)=>{"use strict";const r=n(857),o=n(2018),i=n(5884),{env:s}=process;let a;function c(e){return 0!==e&&{level:e,hasBasic:!0,has256:e>=2,has16m:e>=3}}function u(e,t){if(0===a)return 0;if(i("color=16m")||i("color=full")||i("color=truecolor"))return 3;if(i("color=256"))return 2;if(e&&!t&&void 0===a)return 0;const n=a||0;if("dumb"===s.TERM)return n;if("win32"===process.platform){const e=r.release().split(".");return Number(e[0])>=10&&Number(e[2])>=10586?Number(e[2])>=14931?3:2:1}if("CI"in s)return["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE"].some((e=>e in s))||"codeship"===s.CI_NAME?1:n;if("TEAMCITY_VERSION"in s)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(s.TEAMCITY_VERSION)?1:0;if("truecolor"===s.COLORTERM)return 3;if("TERM_PROGRAM"in s){const e=parseInt((s.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(s.TERM_PROGRAM){case"iTerm.app":return e>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(s.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(s.TERM)||"COLORTERM"in s?1:n}i("no-color")||i("no-colors")||i("color=false")||i("color=never")?a=0:(i("color")||i("colors")||i("color=true")||i("color=always"))&&(a=1),"FORCE_COLOR"in s&&(a="true"===s.FORCE_COLOR?1:"false"===s.FORCE_COLOR?0:0===s.FORCE_COLOR.length?1:Math.min(parseInt(s.FORCE_COLOR,10),3)),e.exports={supportsColor:function(e){return c(u(e,e&&e.isTTY))},stdout:c(u(!0,o.isatty(1))),stderr:c(u(!0,o.isatty(2)))}},803:(e,t,n)=>{e.exports=n(7469)},7469:(e,t,n)=>{"use strict";n(9278);var r,o=n(4756),i=n(8611),s=n(5692),a=n(4434),c=(n(2613),n(9023));function u(e){var t=this;t.options=e||{},t.proxyOptions=t.options.proxy||{},t.maxSockets=t.options.maxSockets||i.Agent.defaultMaxSockets,t.requests=[],t.sockets=[],t.on("free",(function(e,n,r,o){for(var i=p(n,r,o),s=0,a=t.requests.length;s<a;++s){var c=t.requests[s];if(c.host===i.host&&c.port===i.port)return t.requests.splice(s,1),void c.request.onSocket(e)}e.destroy(),t.removeSocket(e)}))}function l(e,t){var n=this;u.prototype.createSocket.call(n,e,(function(r){var i=e.request.getHeader("host"),s=d({},n.options,{socket:r,servername:i?i.replace(/:.*$/,""):e.host}),a=o.connect(0,s);n.sockets[n.sockets.indexOf(r)]=a,t(a)}))}function p(e,t,n){return"string"==typeof e?{host:e,port:t,localAddress:n}:e}function d(e){for(var t=1,n=arguments.length;t<n;++t){var r=arguments[t];if("object"==typeof r)for(var o=Object.keys(r),i=0,s=o.length;i<s;++i){var a=o[i];void 0!==r[a]&&(e[a]=r[a])}}return e}t.httpOverHttp=function(e){var t=new u(e);return t.request=i.request,t},t.httpsOverHttp=function(e){var t=new u(e);return t.request=i.request,t.createSocket=l,t.defaultPort=443,t},t.httpOverHttps=function(e){var t=new u(e);return t.request=s.request,t},t.httpsOverHttps=function(e){var t=new u(e);return t.request=s.request,t.createSocket=l,t.defaultPort=443,t},c.inherits(u,a.EventEmitter),u.prototype.addRequest=function(e,t,n,r){var o=this,i=d({request:e},o.options,p(t,n,r));o.sockets.length>=this.maxSockets?o.requests.push(i):o.createSocket(i,(function(t){function n(){o.emit("free",t,i)}function r(e){o.removeSocket(t),t.removeListener("free",n),t.removeListener("close",r),t.removeListener("agentRemove",r)}t.on("free",n),t.on("close",r),t.on("agentRemove",r),e.onSocket(t)}))},u.prototype.createSocket=function(e,t){var n=this,o={};n.sockets.push(o);var i=d({},n.proxyOptions,{method:"CONNECT",path:e.host+":"+e.port,agent:!1,headers:{host:e.host+":"+e.port}});e.localAddress&&(i.localAddress=e.localAddress),i.proxyAuth&&(i.headers=i.headers||{},i.headers["Proxy-Authorization"]="Basic "+new Buffer(i.proxyAuth).toString("base64")),r("making CONNECT request");var s=n.request(i);function a(i,a,c){var u;return s.removeAllListeners(),a.removeAllListeners(),200!==i.statusCode?(r("tunneling socket could not be established, statusCode=%d",i.statusCode),a.destroy(),(u=new Error("tunneling socket could not be established, statusCode="+i.statusCode)).code="ECONNRESET",e.request.emit("error",u),void n.removeSocket(o)):c.length>0?(r("got illegal response body from proxy"),a.destroy(),(u=new Error("got illegal response body from proxy")).code="ECONNRESET",e.request.emit("error",u),void n.removeSocket(o)):(r("tunneling connection has established"),n.sockets[n.sockets.indexOf(o)]=a,t(a))}s.useChunkedEncodingByDefault=!1,s.once("response",(function(e){e.upgrade=!0})),s.once("upgrade",(function(e,t,n){process.nextTick((function(){a(e,t,n)}))})),s.once("connect",a),s.once("error",(function(t){s.removeAllListeners(),r("tunneling socket could not be established, cause=%s\n",t.message,t.stack);var i=new Error("tunneling socket could not be established, cause="+t.message);i.code="ECONNRESET",e.request.emit("error",i),n.removeSocket(o)})),s.end()},u.prototype.removeSocket=function(e){var t=this.sockets.indexOf(e);if(-1!==t){this.sockets.splice(t,1);var n=this.requests.shift();n&&this.createSocket(n,(function(e){n.request.onSocket(e)}))}},r=process.env.NODE_DEBUG&&/\btunnel\b/.test(process.env.NODE_DEBUG)?function(){var e=Array.prototype.slice.call(arguments);"string"==typeof e[0]?e[0]="TUNNEL: "+e[0]:e.unshift("TUNNEL:"),console.error.apply(console,e)}:function(){},t.debug=r},4200:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,o,i,s,a,c,u=n(6928),l=n(9896),p=Object.prototype.toString;function d(e){return void 0!==e}function h(e){return"[object String]"===p.call(e)}function f(e){return JSON.parse(l.readFileSync(e,"utf8"))}function m(e,t){return c&&(e="ï¼»"+e.replace(/[aouei]/g,"$&$&")+"ï¼½"),0===t.length?e:e.replace(/\{(\d+)\}/g,(function(e,n){var r=n[0],o=t[r],i=e;return"string"==typeof o?i=o:"number"!=typeof o&&"boolean"!=typeof o&&null!=o||(i=String(o)),i}))}function v(e){return function(t,n){for(var r,o=[],i=2;i<arguments.length;i++)o[i-2]=arguments[i];return r=t,"[object Number]"===p.call(r)?t>=e.length?void console.error("Broken localize call found. Index out of bounds. Stacktrace is\n: "+new Error("").stack):m(e[t],o):h(n)?(console.warn("Message "+n+" didn't get externalized correctly."),m(n,o)):void console.error("Broken localize call found. Stacktrace is\n: "+new Error("").stack)}}function g(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];return m(t,n)}function y(e,t){return s[e]=t,t}function _(e){try{return function(e){var t=f(u.join(e,"nls.metadata.json")),n=Object.create(null);for(var r in t){var o=t[r];n[r]=o.messages}return n}(e)}catch(e){return void console.log("Generating default bundle from meta data failed.",e)}}function b(e,t){var n;if(!0===a.languagePackSupport&&void 0!==a.cacheRoot&&void 0!==a.languagePackId&&void 0!==a.translationsConfigFile&&void 0!==a.translationsConfig)try{n=function(e,t){var n,r,o,i=u.join(a.cacheRoot,e.id+"-"+e.hash+".json"),s=!1,c=!1;try{return n=JSON.parse(l.readFileSync(i,{encoding:"utf8",flag:"r"})),r=i,o=new Date,l.utimes(r,o,o,(function(){})),n}catch(e){if("ENOENT"===e.code)c=!0;else{if(!(e instanceof SyntaxError))throw e;console.log("Syntax error parsing message bundle: "+e.message+"."),l.unlink(i,(function(e){e&&console.error("Deleting corrupted bundle "+i+" failed.")})),s=!0}}if(n=function(e,t){var n=a.translationsConfig[e.id];if(n){var r=f(n).contents,o=f(u.join(t,"nls.metadata.json")),i=Object.create(null);for(var s in o){var c=o[s],l=r[e.outDir+"/"+s];if(l){for(var p=[],d=0;d<c.keys.length;d++){var m=c.keys[d],v=l[h(m)?m:m.key];void 0===v&&(v=c.messages[d]),p.push(v)}i[s]=p}else i[s]=c.messages}return i}}(e,t),!n||s)return n;if(c)try{l.writeFileSync(i,JSON.stringify(n),{encoding:"utf8",flag:"wx"})}catch(e){if("EEXIST"===e.code)return n;throw e}return n}(e,t)}catch(e){console.log("Load or create bundle failed ",e)}if(!n){if(a.languagePackSupport)return _(t);var r=function(e){for(var t=a.language;t;){var n=u.join(e,"nls.bundle."+t+".json");if(l.existsSync(n))return n;var r=t.lastIndexOf("-");t=r>0?t.substring(0,r):void 0}if(void 0===t&&(n=u.join(e,"nls.bundle.json"),l.existsSync(n)))return n}(t);if(r)try{return f(r)}catch(e){console.log("Loading in the box message bundle failed.",e)}n=_(t)}return n}function E(e){if(!e)return g;var t=u.extname(e);if(t&&(e=e.substr(0,e.length-t.length)),a.messageFormat===r.both||a.messageFormat===r.bundle){var n=function(e){for(var t,n=u.dirname(e);t=u.join(n,"nls.metadata.header.json"),!l.existsSync(t);){var r=u.dirname(n);if(r===n){t=void 0;break}n=r}return t}(e);if(n){var o=u.dirname(n),i=s[o];if(void 0===i)try{var p=JSON.parse(l.readFileSync(n,"utf8"));try{var h=b(p,o);i=y(o,h?{header:p,nlsBundle:h}:null)}catch(e){console.error("Failed to load nls bundle",e),i=y(o,null)}}catch(e){console.error("Failed to read header file",e),i=y(o,null)}if(i){var m=e.substr(o.length+1).replace(/\\/g,"/"),_=i.nlsBundle[m];return void 0===_?(console.error("Messages for file "+e+" not found. See console for details."),function(){return"Messages not found."}):v(_)}}}if(a.messageFormat===r.both||a.messageFormat===r.file)try{var E=f(function(e){var t;if(a.cacheLanguageResolution&&t);else{if(c||!a.language)t=".nls.json";else for(var n=a.language;n;){var r=".nls."+n+".json";if(l.existsSync(e+r)){t=r;break}var o=n.lastIndexOf("-");o>0?n=n.substring(0,o):(t=".nls.json",n=null)}a.cacheLanguageResolution}return e+t}(e));return Array.isArray(E)?v(E):d(E.messages)&&d(E.keys)?v(E.messages):(console.error("String bundle '"+e+"' uses an unsupported format."),function(){return"File bundle has unsupported format. See console for details"})}catch(e){"ENOENT"!==e.code&&console.error("Failed to load single file bundle",e)}return console.error("Failed to load message bundle for file "+e),function(){return"Failed to load message bundle. See console for details."}}!function(e){e.file="file",e.bundle="bundle",e.both="both"}(r=t.MessageFormat||(t.MessageFormat={})),function(e){e.standalone="standalone",e.languagePack="languagePack"}(o=t.BundleFormat||(t.BundleFormat={})),function(e){e.is=function(e){var t=e;return t&&d(t.key)&&d(t.comment)}}(i||(i={})),function(){if(a={locale:void 0,language:void 0,languagePackSupport:!1,cacheLanguageResolution:!0,messageFormat:r.bundle},h(process.env.VSCODE_NLS_CONFIG))try{var e=JSON.parse(process.env.VSCODE_NLS_CONFIG),t=void 0;if(e.availableLanguages){var n=e.availableLanguages["*"];h(n)&&(t=n)}if(h(e.locale)&&(a.locale=e.locale.toLowerCase()),void 0===t?a.language=a.locale:"en"!==t&&(a.language=t),function(e){return!0===e||!1===e}(e._languagePackSupport)&&(a.languagePackSupport=e._languagePackSupport),h(e._cacheRoot)&&(a.cacheRoot=e._cacheRoot),h(e._languagePackId)&&(a.languagePackId=e._languagePackId),h(e._translationsConfigFile)){a.translationsConfigFile=e._translationsConfigFile;try{a.translationsConfig=f(a.translationsConfigFile)}catch(t){if(e._corruptedFile){var o=u.dirname(e._corruptedFile);l.exists(o,(function(t){t&&l.writeFile(e._corruptedFile,"corrupted","utf8",(function(e){console.error(e)}))}))}}}}catch(e){}c="pseudo"===a.locale,s=Object.create(null)}(),t.loadMessageBundle=E,t.config=function(e){return e&&(h(e.locale)&&(a.locale=e.locale.toLowerCase(),a.language=a.locale,s=Object.create(null)),void 0!==e.messageFormat&&(a.messageFormat=e.messageFormat),e.bundleFormat===o.standalone&&!0===a.languagePackSupport&&(a.languagePackSupport=!1)),c="pseudo"===a.locale,E}},7699:(e,t,n)=>{"use strict";const r=n(1060);r.createWebSocketStream=n(3719),r.Server=n(1722),r.Receiver=n(3905),r.Sender=n(914),e.exports=r},3338:(e,t,n)=>{"use strict";const{EMPTY_BUFFER:r}=n(2614);function o(e,t){if(0===e.length)return r;if(1===e.length)return e[0];const n=Buffer.allocUnsafe(t);let o=0;for(let t=0;t<e.length;t++){const r=e[t];n.set(r,o),o+=r.length}return o<t?n.slice(0,o):n}function i(e,t,n,r,o){for(let i=0;i<o;i++)n[r+i]=e[i]^t[3&i]}function s(e,t){const n=e.length;for(let r=0;r<n;r++)e[r]^=t[3&r]}function a(e){return e.byteLength===e.buffer.byteLength?e.buffer:e.buffer.slice(e.byteOffset,e.byteOffset+e.byteLength)}function c(e){if(c.readOnly=!0,Buffer.isBuffer(e))return e;let t;return e instanceof ArrayBuffer?t=Buffer.from(e):ArrayBuffer.isView(e)?t=Buffer.from(e.buffer,e.byteOffset,e.byteLength):(t=Buffer.from(e),c.readOnly=!1),t}try{const t=n(1962),r=t.BufferUtil||t;e.exports={concat:o,mask(e,t,n,o,s){s<48?i(e,t,n,o,s):r.mask(e,t,n,o,s)},toArrayBuffer:a,toBuffer:c,unmask(e,t){e.length<32?s(e,t):r.unmask(e,t)}}}catch(t){e.exports={concat:o,mask:i,toArrayBuffer:a,toBuffer:c,unmask:s}}},2614:e=>{"use strict";e.exports={BINARY_TYPES:["nodebuffer","arraybuffer","fragments"],GUID:"258EAFA5-E914-47DA-95CA-C5AB0DC85B11",kStatusCode:Symbol("status-code"),kWebSocket:Symbol("websocket"),EMPTY_BUFFER:Buffer.alloc(0),NOOP:()=>{}}},597:e=>{"use strict";class t{constructor(e,t){this.target=t,this.type=e}}class n extends t{constructor(e,t){super("message",t),this.data=e}}class r extends t{constructor(e,t,n){super("close",n),this.wasClean=n._closeFrameReceived&&n._closeFrameSent,this.reason=t,this.code=e}}class o extends t{constructor(e){super("open",e)}}class i extends t{constructor(e,t){super("error",t),this.message=e.message,this.error=e}}const s={addEventListener(e,t,s){if("function"!=typeof t)return;function a(e){t.call(this,new n(e,this))}function c(e,n){t.call(this,new r(e,n,this))}function u(e){t.call(this,new i(e,this))}function l(){t.call(this,new o(this))}const p=s&&s.once?"once":"on";"message"===e?(a._listener=t,this[p](e,a)):"close"===e?(c._listener=t,this[p](e,c)):"error"===e?(u._listener=t,this[p](e,u)):"open"===e?(l._listener=t,this[p](e,l)):this[p](e,t)},removeEventListener(e,t){const n=this.listeners(e);for(let r=0;r<n.length;r++)n[r]!==t&&n[r]._listener!==t||this.removeListener(e,n[r])}};e.exports=s},5926:e=>{"use strict";const t=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,1,1,1,1,0,0,1,1,0,1,1,0,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,1,0,1,0];function n(e,t,n){void 0===e[t]?e[t]=[n]:e[t].push(n)}e.exports={format:function(e){return Object.keys(e).map((t=>{let n=e[t];return Array.isArray(n)||(n=[n]),n.map((e=>[t].concat(Object.keys(e).map((t=>{let n=e[t];return Array.isArray(n)||(n=[n]),n.map((e=>!0===e?t:`${t}=${e}`)).join("; ")}))).join("; "))).join(", ")})).join(", ")},parse:function(e){const r=Object.create(null);if(void 0===e||""===e)return r;let o,i,s=Object.create(null),a=!1,c=!1,u=!1,l=-1,p=-1,d=0;for(;d<e.length;d++){const h=e.charCodeAt(d);if(void 0===o)if(-1===p&&1===t[h])-1===l&&(l=d);else if(32===h||9===h)-1===p&&-1!==l&&(p=d);else{if(59!==h&&44!==h)throw new SyntaxError(`Unexpected character at index ${d}`);{if(-1===l)throw new SyntaxError(`Unexpected character at index ${d}`);-1===p&&(p=d);const t=e.slice(l,p);44===h?(n(r,t,s),s=Object.create(null)):o=t,l=p=-1}}else if(void 0===i)if(-1===p&&1===t[h])-1===l&&(l=d);else if(32===h||9===h)-1===p&&-1!==l&&(p=d);else if(59===h||44===h){if(-1===l)throw new SyntaxError(`Unexpected character at index ${d}`);-1===p&&(p=d),n(s,e.slice(l,p),!0),44===h&&(n(r,o,s),s=Object.create(null),o=void 0),l=p=-1}else{if(61!==h||-1===l||-1!==p)throw new SyntaxError(`Unexpected character at index ${d}`);i=e.slice(l,d),l=p=-1}else if(c){if(1!==t[h])throw new SyntaxError(`Unexpected character at index ${d}`);-1===l?l=d:a||(a=!0),c=!1}else if(u)if(1===t[h])-1===l&&(l=d);else if(34===h&&-1!==l)u=!1,p=d;else{if(92!==h)throw new SyntaxError(`Unexpected character at index ${d}`);c=!0}else if(34===h&&61===e.charCodeAt(d-1))u=!0;else if(-1===p&&1===t[h])-1===l&&(l=d);else if(-1===l||32!==h&&9!==h){if(59!==h&&44!==h)throw new SyntaxError(`Unexpected character at index ${d}`);{if(-1===l)throw new SyntaxError(`Unexpected character at index ${d}`);-1===p&&(p=d);let t=e.slice(l,p);a&&(t=t.replace(/\\/g,""),a=!1),n(s,i,t),44===h&&(n(r,o,s),s=Object.create(null),o=void 0),i=void 0,l=p=-1}}else-1===p&&(p=d)}if(-1===l||u)throw new SyntaxError("Unexpected end of input");-1===p&&(p=d);const h=e.slice(l,p);return void 0===o?n(r,h,s):(void 0===i?n(s,h,!0):n(s,i,a?h.replace(/\\/g,""):h),n(r,o,s)),r}}},4759:e=>{"use strict";const t=Symbol("kDone"),n=Symbol("kRun");e.exports=class{constructor(e){this[t]=()=>{this.pending--,this[n]()},this.concurrency=e||1/0,this.jobs=[],this.pending=0}add(e){this.jobs.push(e),this[n]()}[n](){if(this.pending!==this.concurrency&&this.jobs.length){const e=this.jobs.shift();this.pending++,e(this[t])}}}},2971:(e,t,n)=>{"use strict";const r=n(3106),o=n(3338),i=n(4759),{kStatusCode:s,NOOP:a}=n(2614),c=Buffer.from([0,0,255,255]),u=Symbol("permessage-deflate"),l=Symbol("total-length"),p=Symbol("callback"),d=Symbol("buffers"),h=Symbol("error");let f;function m(e){this[d].push(e),this[l]+=e.length}function v(e){this[l]+=e.length,this[u]._maxPayload<1||this[l]<=this[u]._maxPayload?this[d].push(e):(this[h]=new RangeError("Max payload size exceeded"),this[h].code="WS_ERR_UNSUPPORTED_MESSAGE_LENGTH",this[h][s]=1009,this.removeListener("data",v),this.reset())}function g(e){this[u]._inflate=null,e[s]=1007,this[p](e)}e.exports=class{constructor(e,t,n){if(this._maxPayload=0|n,this._options=e||{},this._threshold=void 0!==this._options.threshold?this._options.threshold:1024,this._isServer=!!t,this._deflate=null,this._inflate=null,this.params=null,!f){const e=void 0!==this._options.concurrencyLimit?this._options.concurrencyLimit:10;f=new i(e)}}static get extensionName(){return"permessage-deflate"}offer(){const e={};return this._options.serverNoContextTakeover&&(e.server_no_context_takeover=!0),this._options.clientNoContextTakeover&&(e.client_no_context_takeover=!0),this._options.serverMaxWindowBits&&(e.server_max_window_bits=this._options.serverMaxWindowBits),this._options.clientMaxWindowBits?e.client_max_window_bits=this._options.clientMaxWindowBits:null==this._options.clientMaxWindowBits&&(e.client_max_window_bits=!0),e}accept(e){return e=this.normalizeParams(e),this.params=this._isServer?this.acceptAsServer(e):this.acceptAsClient(e),this.params}cleanup(){if(this._inflate&&(this._inflate.close(),this._inflate=null),this._deflate){const e=this._deflate[p];this._deflate.close(),this._deflate=null,e&&e(new Error("The deflate stream was closed while data was being processed"))}}acceptAsServer(e){const t=this._options,n=e.find((e=>!(!1===t.serverNoContextTakeover&&e.server_no_context_takeover||e.server_max_window_bits&&(!1===t.serverMaxWindowBits||"number"==typeof t.serverMaxWindowBits&&t.serverMaxWindowBits>e.server_max_window_bits)||"number"==typeof t.clientMaxWindowBits&&!e.client_max_window_bits)));if(!n)throw new Error("None of the extension offers can be accepted");return t.serverNoContextTakeover&&(n.server_no_context_takeover=!0),t.clientNoContextTakeover&&(n.client_no_context_takeover=!0),"number"==typeof t.serverMaxWindowBits&&(n.server_max_window_bits=t.serverMaxWindowBits),"number"==typeof t.clientMaxWindowBits?n.client_max_window_bits=t.clientMaxWindowBits:!0!==n.client_max_window_bits&&!1!==t.clientMaxWindowBits||delete n.client_max_window_bits,n}acceptAsClient(e){const t=e[0];if(!1===this._options.clientNoContextTakeover&&t.client_no_context_takeover)throw new Error('Unexpected parameter "client_no_context_takeover"');if(t.client_max_window_bits){if(!1===this._options.clientMaxWindowBits||"number"==typeof this._options.clientMaxWindowBits&&t.client_max_window_bits>this._options.clientMaxWindowBits)throw new Error('Unexpected or invalid parameter "client_max_window_bits"')}else"number"==typeof this._options.clientMaxWindowBits&&(t.client_max_window_bits=this._options.clientMaxWindowBits);return t}normalizeParams(e){return e.forEach((e=>{Object.keys(e).forEach((t=>{let n=e[t];if(n.length>1)throw new Error(`Parameter "${t}" must have only a single value`);if(n=n[0],"client_max_window_bits"===t){if(!0!==n){const e=+n;if(!Number.isInteger(e)||e<8||e>15)throw new TypeError(`Invalid value for parameter "${t}": ${n}`);n=e}else if(!this._isServer)throw new TypeError(`Invalid value for parameter "${t}": ${n}`)}else if("server_max_window_bits"===t){const e=+n;if(!Number.isInteger(e)||e<8||e>15)throw new TypeError(`Invalid value for parameter "${t}": ${n}`);n=e}else{if("client_no_context_takeover"!==t&&"server_no_context_takeover"!==t)throw new Error(`Unknown parameter "${t}"`);if(!0!==n)throw new TypeError(`Invalid value for parameter "${t}": ${n}`)}e[t]=n}))})),e}decompress(e,t,n){f.add((r=>{this._decompress(e,t,((e,t)=>{r(),n(e,t)}))}))}compress(e,t,n){f.add((r=>{this._compress(e,t,((e,t)=>{r(),n(e,t)}))}))}_decompress(e,t,n){const i=this._isServer?"client":"server";if(!this._inflate){const e=`${i}_max_window_bits`,t="number"!=typeof this.params[e]?r.Z_DEFAULT_WINDOWBITS:this.params[e];this._inflate=r.createInflateRaw({...this._options.zlibInflateOptions,windowBits:t}),this._inflate[u]=this,this._inflate[l]=0,this._inflate[d]=[],this._inflate.on("error",g),this._inflate.on("data",v)}this._inflate[p]=n,this._inflate.write(e),t&&this._inflate.write(c),this._inflate.flush((()=>{const e=this._inflate[h];if(e)return this._inflate.close(),this._inflate=null,void n(e);const r=o.concat(this._inflate[d],this._inflate[l]);this._inflate._readableState.endEmitted?(this._inflate.close(),this._inflate=null):(this._inflate[l]=0,this._inflate[d]=[],t&&this.params[`${i}_no_context_takeover`]&&this._inflate.reset()),n(null,r)}))}_compress(e,t,n){const i=this._isServer?"server":"client";if(!this._deflate){const e=`${i}_max_window_bits`,t="number"!=typeof this.params[e]?r.Z_DEFAULT_WINDOWBITS:this.params[e];this._deflate=r.createDeflateRaw({...this._options.zlibDeflateOptions,windowBits:t}),this._deflate[l]=0,this._deflate[d]=[],this._deflate.on("error",a),this._deflate.on("data",m)}this._deflate[p]=n,this._deflate.write(e),this._deflate.flush(r.Z_SYNC_FLUSH,(()=>{if(!this._deflate)return;let e=o.concat(this._deflate[d],this._deflate[l]);t&&(e=e.slice(0,e.length-4)),this._deflate[p]=null,this._deflate[l]=0,this._deflate[d]=[],t&&this.params[`${i}_no_context_takeover`]&&this._deflate.reset(),n(null,e)}))}}},3905:(e,t,n)=>{"use strict";const{Writable:r}=n(2203),o=n(2971),{BINARY_TYPES:i,EMPTY_BUFFER:s,kStatusCode:a,kWebSocket:c}=n(2614),{concat:u,toArrayBuffer:l,unmask:p}=n(3338),{isValidStatusCode:d,isValidUTF8:h}=n(5880);function f(e,t,n,r,o){const i=new e(n?`Invalid WebSocket frame: ${t}`:t);return Error.captureStackTrace(i,f),i.code=o,i[a]=r,i}e.exports=class extends r{constructor(e,t,n,r){super(),this._binaryType=e||i[0],this[c]=void 0,this._extensions=t||{},this._isServer=!!n,this._maxPayload=0|r,this._bufferedBytes=0,this._buffers=[],this._compressed=!1,this._payloadLength=0,this._mask=void 0,this._fragmented=0,this._masked=!1,this._fin=!1,this._opcode=0,this._totalPayloadLength=0,this._messageLength=0,this._fragments=[],this._state=0,this._loop=!1}_write(e,t,n){if(8===this._opcode&&0==this._state)return n();this._bufferedBytes+=e.length,this._buffers.push(e),this.startLoop(n)}consume(e){if(this._bufferedBytes-=e,e===this._buffers[0].length)return this._buffers.shift();if(e<this._buffers[0].length){const t=this._buffers[0];return this._buffers[0]=t.slice(e),t.slice(0,e)}const t=Buffer.allocUnsafe(e);do{const n=this._buffers[0],r=t.length-e;e>=n.length?t.set(this._buffers.shift(),r):(t.set(new Uint8Array(n.buffer,n.byteOffset,e),r),this._buffers[0]=n.slice(e)),e-=n.length}while(e>0);return t}startLoop(e){let t;this._loop=!0;do{switch(this._state){case 0:t=this.getInfo();break;case 1:t=this.getPayloadLength16();break;case 2:t=this.getPayloadLength64();break;case 3:this.getMask();break;case 4:t=this.getData(e);break;default:return void(this._loop=!1)}}while(this._loop);e(t)}getInfo(){if(this._bufferedBytes<2)return void(this._loop=!1);const e=this.consume(2);if(48&e[0])return this._loop=!1,f(RangeError,"RSV2 and RSV3 must be clear",!0,1002,"WS_ERR_UNEXPECTED_RSV_2_3");const t=!(64&~e[0]);if(t&&!this._extensions[o.extensionName])return this._loop=!1,f(RangeError,"RSV1 must be clear",!0,1002,"WS_ERR_UNEXPECTED_RSV_1");if(this._fin=!(128&~e[0]),this._opcode=15&e[0],this._payloadLength=127&e[1],0===this._opcode){if(t)return this._loop=!1,f(RangeError,"RSV1 must be clear",!0,1002,"WS_ERR_UNEXPECTED_RSV_1");if(!this._fragmented)return this._loop=!1,f(RangeError,"invalid opcode 0",!0,1002,"WS_ERR_INVALID_OPCODE");this._opcode=this._fragmented}else if(1===this._opcode||2===this._opcode){if(this._fragmented)return this._loop=!1,f(RangeError,`invalid opcode ${this._opcode}`,!0,1002,"WS_ERR_INVALID_OPCODE");this._compressed=t}else{if(!(this._opcode>7&&this._opcode<11))return this._loop=!1,f(RangeError,`invalid opcode ${this._opcode}`,!0,1002,"WS_ERR_INVALID_OPCODE");if(!this._fin)return this._loop=!1,f(RangeError,"FIN must be set",!0,1002,"WS_ERR_EXPECTED_FIN");if(t)return this._loop=!1,f(RangeError,"RSV1 must be clear",!0,1002,"WS_ERR_UNEXPECTED_RSV_1");if(this._payloadLength>125)return this._loop=!1,f(RangeError,`invalid payload length ${this._payloadLength}`,!0,1002,"WS_ERR_INVALID_CONTROL_PAYLOAD_LENGTH")}if(this._fin||this._fragmented||(this._fragmented=this._opcode),this._masked=!(128&~e[1]),this._isServer){if(!this._masked)return this._loop=!1,f(RangeError,"MASK must be set",!0,1002,"WS_ERR_EXPECTED_MASK")}else if(this._masked)return this._loop=!1,f(RangeError,"MASK must be clear",!0,1002,"WS_ERR_UNEXPECTED_MASK");if(126===this._payloadLength)this._state=1;else{if(127!==this._payloadLength)return this.haveLength();this._state=2}}getPayloadLength16(){if(!(this._bufferedBytes<2))return this._payloadLength=this.consume(2).readUInt16BE(0),this.haveLength();this._loop=!1}getPayloadLength64(){if(this._bufferedBytes<8)return void(this._loop=!1);const e=this.consume(8),t=e.readUInt32BE(0);return t>Math.pow(2,21)-1?(this._loop=!1,f(RangeError,"Unsupported WebSocket frame: payload length > 2^53 - 1",!1,1009,"WS_ERR_UNSUPPORTED_DATA_PAYLOAD_LENGTH")):(this._payloadLength=t*Math.pow(2,32)+e.readUInt32BE(4),this.haveLength())}haveLength(){if(this._payloadLength&&this._opcode<8&&(this._totalPayloadLength+=this._payloadLength,this._totalPayloadLength>this._maxPayload&&this._maxPayload>0))return this._loop=!1,f(RangeError,"Max payload size exceeded",!1,1009,"WS_ERR_UNSUPPORTED_MESSAGE_LENGTH");this._masked?this._state=3:this._state=4}getMask(){this._bufferedBytes<4?this._loop=!1:(this._mask=this.consume(4),this._state=4)}getData(e){let t=s;if(this._payloadLength){if(this._bufferedBytes<this._payloadLength)return void(this._loop=!1);t=this.consume(this._payloadLength),this._masked&&p(t,this._mask)}return this._opcode>7?this.controlMessage(t):this._compressed?(this._state=5,void this.decompress(t,e)):(t.length&&(this._messageLength=this._totalPayloadLength,this._fragments.push(t)),this.dataMessage())}decompress(e,t){this._extensions[o.extensionName].decompress(e,this._fin,((e,n)=>{if(e)return t(e);if(n.length){if(this._messageLength+=n.length,this._messageLength>this._maxPayload&&this._maxPayload>0)return t(f(RangeError,"Max payload size exceeded",!1,1009,"WS_ERR_UNSUPPORTED_MESSAGE_LENGTH"));this._fragments.push(n)}const r=this.dataMessage();if(r)return t(r);this.startLoop(t)}))}dataMessage(){if(this._fin){const e=this._messageLength,t=this._fragments;if(this._totalPayloadLength=0,this._messageLength=0,this._fragmented=0,this._fragments=[],2===this._opcode){let n;n="nodebuffer"===this._binaryType?u(t,e):"arraybuffer"===this._binaryType?l(u(t,e)):t,this.emit("message",n)}else{const n=u(t,e);if(!h(n))return this._loop=!1,f(Error,"invalid UTF-8 sequence",!0,1007,"WS_ERR_INVALID_UTF8");this.emit("message",n.toString())}}this._state=0}controlMessage(e){if(8===this._opcode)if(this._loop=!1,0===e.length)this.emit("conclude",1005,""),this.end();else{if(1===e.length)return f(RangeError,"invalid payload length 1",!0,1002,"WS_ERR_INVALID_CONTROL_PAYLOAD_LENGTH");{const t=e.readUInt16BE(0);if(!d(t))return f(RangeError,`invalid status code ${t}`,!0,1002,"WS_ERR_INVALID_CLOSE_CODE");const n=e.slice(2);if(!h(n))return f(Error,"invalid UTF-8 sequence",!0,1007,"WS_ERR_INVALID_UTF8");this.emit("conclude",t,n.toString()),this.end()}}else 9===this._opcode?this.emit("ping",e):this.emit("pong",e);this._state=0}}},914:(e,t,n)=>{"use strict";n(9278),n(4756);const{randomFillSync:r}=n(6982),o=n(2971),{EMPTY_BUFFER:i}=n(2614),{isValidStatusCode:s}=n(5880),{mask:a,toBuffer:c}=n(3338),u=Buffer.alloc(4);class l{constructor(e,t){this._extensions=t||{},this._socket=e,this._firstFragment=!0,this._compress=!1,this._bufferedBytes=0,this._deflating=!1,this._queue=[]}static frame(e,t){const n=t.mask&&t.readOnly;let o=t.mask?6:2,i=e.length;e.length>=65536?(o+=8,i=127):e.length>125&&(o+=2,i=126);const s=Buffer.allocUnsafe(n?e.length+o:o);return s[0]=t.fin?128|t.opcode:t.opcode,t.rsv1&&(s[0]|=64),s[1]=i,126===i?s.writeUInt16BE(e.length,2):127===i&&(s.writeUInt32BE(0,2),s.writeUInt32BE(e.length,6)),t.mask?(r(u,0,4),s[1]|=128,s[o-4]=u[0],s[o-3]=u[1],s[o-2]=u[2],s[o-1]=u[3],n?(a(e,u,s,o,e.length),[s]):(a(e,u,e,0,e.length),[s,e])):[s,e]}close(e,t,n,r){let o;if(void 0===e)o=i;else{if("number"!=typeof e||!s(e))throw new TypeError("First argument must be a valid error code number");if(void 0===t||""===t)o=Buffer.allocUnsafe(2),o.writeUInt16BE(e,0);else{const n=Buffer.byteLength(t);if(n>123)throw new RangeError("The message must not be greater than 123 bytes");o=Buffer.allocUnsafe(2+n),o.writeUInt16BE(e,0),o.write(t,2)}}this._deflating?this.enqueue([this.doClose,o,n,r]):this.doClose(o,n,r)}doClose(e,t,n){this.sendFrame(l.frame(e,{fin:!0,rsv1:!1,opcode:8,mask:t,readOnly:!1}),n)}ping(e,t,n){const r=c(e);if(r.length>125)throw new RangeError("The data size must not be greater than 125 bytes");this._deflating?this.enqueue([this.doPing,r,t,c.readOnly,n]):this.doPing(r,t,c.readOnly,n)}doPing(e,t,n,r){this.sendFrame(l.frame(e,{fin:!0,rsv1:!1,opcode:9,mask:t,readOnly:n}),r)}pong(e,t,n){const r=c(e);if(r.length>125)throw new RangeError("The data size must not be greater than 125 bytes");this._deflating?this.enqueue([this.doPong,r,t,c.readOnly,n]):this.doPong(r,t,c.readOnly,n)}doPong(e,t,n,r){this.sendFrame(l.frame(e,{fin:!0,rsv1:!1,opcode:10,mask:t,readOnly:n}),r)}send(e,t,n){const r=c(e),i=this._extensions[o.extensionName];let s=t.binary?2:1,a=t.compress;if(this._firstFragment?(this._firstFragment=!1,a&&i&&(a=r.length>=i._threshold),this._compress=a):(a=!1,s=0),t.fin&&(this._firstFragment=!0),i){const e={fin:t.fin,rsv1:a,opcode:s,mask:t.mask,readOnly:c.readOnly};this._deflating?this.enqueue([this.dispatch,r,this._compress,e,n]):this.dispatch(r,this._compress,e,n)}else this.sendFrame(l.frame(r,{fin:t.fin,rsv1:!1,opcode:s,mask:t.mask,readOnly:c.readOnly}),n)}dispatch(e,t,n,r){if(!t)return void this.sendFrame(l.frame(e,n),r);const i=this._extensions[o.extensionName];this._bufferedBytes+=e.length,this._deflating=!0,i.compress(e,n.fin,((t,o)=>{if(this._socket.destroyed){const e=new Error("The socket was closed while data was being compressed");"function"==typeof r&&r(e);for(let t=0;t<this._queue.length;t++){const n=this._queue[t][4];"function"==typeof n&&n(e)}}else this._bufferedBytes-=e.length,this._deflating=!1,n.readOnly=!1,this.sendFrame(l.frame(o,n),r),this.dequeue()}))}dequeue(){for(;!this._deflating&&this._queue.length;){const e=this._queue.shift();this._bufferedBytes-=e[1].length,Reflect.apply(e[0],this,e.slice(1))}}enqueue(e){this._bufferedBytes+=e[1].length,this._queue.push(e)}sendFrame(e,t){2===e.length?(this._socket.cork(),this._socket.write(e[0]),this._socket.write(e[1],t),this._socket.uncork()):this._socket.write(e[0],t)}}e.exports=l},3719:(e,t,n)=>{"use strict";const{Duplex:r}=n(2203);function o(e){e.emit("close")}function i(){!this.destroyed&&this._writableState.finished&&this.destroy()}function s(e){this.removeListener("error",s),this.destroy(),0===this.listenerCount("error")&&this.emit("error",e)}e.exports=function(e,t){let n=!0,a=!0;function c(){n&&e._socket.resume()}e.readyState===e.CONNECTING?e.once("open",(function(){e._receiver.removeAllListeners("drain"),e._receiver.on("drain",c)})):(e._receiver.removeAllListeners("drain"),e._receiver.on("drain",c));const u=new r({...t,autoDestroy:!1,emitClose:!1,objectMode:!1,writableObjectMode:!1});return e.on("message",(function(t){u.push(t)||(n=!1,e._socket.pause())})),e.once("error",(function(e){u.destroyed||(a=!1,u.destroy(e))})),e.once("close",(function(){u.destroyed||u.push(null)})),u._destroy=function(t,n){if(e.readyState===e.CLOSED)return n(t),void process.nextTick(o,u);let r=!1;e.once("error",(function(e){r=!0,n(e)})),e.once("close",(function(){r||n(t),process.nextTick(o,u)})),a&&e.terminate()},u._final=function(t){e.readyState!==e.CONNECTING?null!==e._socket&&(e._socket._writableState.finished?(t(),u._readableState.endEmitted&&u.destroy()):(e._socket.once("finish",(function(){t()})),e.close())):e.once("open",(function(){u._final(t)}))},u._read=function(){e.readyState!==e.OPEN&&e.readyState!==e.CLOSING||n||(n=!0,e._receiver._writableState.needDrain||e._socket.resume())},u._write=function(t,n,r){e.readyState!==e.CONNECTING?e.send(t,r):e.once("open",(function(){u._write(t,n,r)}))},u.on("end",i),u.on("error",s),u}},5880:(e,t,n)=>{"use strict";function r(e){return e>=1e3&&e<=1014&&1004!==e&&1005!==e&&1006!==e||e>=3e3&&e<=4999}function o(e){const t=e.length;let n=0;for(;n<t;)if(128&e[n])if(192==(224&e[n])){if(n+1===t||128!=(192&e[n+1])||192==(254&e[n]))return!1;n+=2}else if(224==(240&e[n])){if(n+2>=t||128!=(192&e[n+1])||128!=(192&e[n+2])||224===e[n]&&128==(224&e[n+1])||237===e[n]&&160==(224&e[n+1]))return!1;n+=3}else{if(240!=(248&e[n]))return!1;if(n+3>=t||128!=(192&e[n+1])||128!=(192&e[n+2])||128!=(192&e[n+3])||240===e[n]&&128==(240&e[n+1])||244===e[n]&&e[n+1]>143||e[n]>244)return!1;n+=4}else n++;return!0}try{let t=n(6809);"object"==typeof t&&(t=t.Validation.isValidUTF8),e.exports={isValidStatusCode:r,isValidUTF8:e=>e.length<150?o(e):t(e)}}catch(t){e.exports={isValidStatusCode:r,isValidUTF8:o}}},1722:(e,t,n)=>{"use strict";const r=n(4434),o=n(8611),{createHash:i}=(n(5692),n(9278),n(4756),n(6982)),s=n(2971),a=n(1060),{format:c,parse:u}=n(5926),{GUID:l,kWebSocket:p}=n(2614),d=/^[+/0-9A-Za-z]{22}==$/;function h(e){e._state=2,e.emit("close")}function f(){this.destroy()}function m(e,t,n,r){e.writable&&(n=n||o.STATUS_CODES[t],r={Connection:"close","Content-Type":"text/html","Content-Length":Buffer.byteLength(n),...r},e.write(`HTTP/1.1 ${t} ${o.STATUS_CODES[t]}\r\n`+Object.keys(r).map((e=>`${e}: ${r[e]}`)).join("\r\n")+"\r\n\r\n"+n)),e.removeListener("error",f),e.destroy()}function v(e){return e.trim()}e.exports=class extends r{constructor(e,t){if(super(),null==(e={maxPayload:104857600,perMessageDeflate:!1,handleProtocols:null,clientTracking:!0,verifyClient:null,noServer:!1,backlog:null,server:null,host:null,path:null,port:null,...e}).port&&!e.server&&!e.noServer||null!=e.port&&(e.server||e.noServer)||e.server&&e.noServer)throw new TypeError('One and only one of the "port", "server", or "noServer" options must be specified');if(null!=e.port?(this._server=o.createServer(((e,t)=>{const n=o.STATUS_CODES[426];t.writeHead(426,{"Content-Length":n.length,"Content-Type":"text/plain"}),t.end(n)})),this._server.listen(e.port,e.host,e.backlog,t)):e.server&&(this._server=e.server),this._server){const e=this.emit.bind(this,"connection");this._removeListeners=function(e,t){for(const n of Object.keys(t))e.on(n,t[n]);return function(){for(const n of Object.keys(t))e.removeListener(n,t[n])}}(this._server,{listening:this.emit.bind(this,"listening"),error:this.emit.bind(this,"error"),upgrade:(t,n,r)=>{this.handleUpgrade(t,n,r,e)}})}!0===e.perMessageDeflate&&(e.perMessageDeflate={}),e.clientTracking&&(this.clients=new Set),this.options=e,this._state=0}address(){if(this.options.noServer)throw new Error('The server is operating in "noServer" mode');return this._server?this._server.address():null}close(e){if(e&&this.once("close",e),2===this._state)return void process.nextTick(h,this);if(1===this._state)return;if(this._state=1,this.clients)for(const e of this.clients)e.terminate();const t=this._server;t&&(this._removeListeners(),this._removeListeners=this._server=null,null!=this.options.port)?t.close(h.bind(void 0,this)):process.nextTick(h,this)}shouldHandle(e){if(this.options.path){const t=e.url.indexOf("?");if((-1!==t?e.url.slice(0,t):e.url)!==this.options.path)return!1}return!0}handleUpgrade(e,t,n,r){t.on("error",f);const o=void 0!==e.headers["sec-websocket-key"]&&e.headers["sec-websocket-key"].trim(),i=e.headers.upgrade,a=+e.headers["sec-websocket-version"],c={};if("GET"!==e.method||void 0===i||"websocket"!==i.toLowerCase()||!o||!d.test(o)||8!==a&&13!==a||!this.shouldHandle(e))return m(t,400);if(this.options.perMessageDeflate){const n=new s(this.options.perMessageDeflate,!0,this.options.maxPayload);try{const t=u(e.headers["sec-websocket-extensions"]);t[s.extensionName]&&(n.accept(t[s.extensionName]),c[s.extensionName]=n)}catch(e){return m(t,400)}}if(this.options.verifyClient){const i={origin:e.headers[8===a?"sec-websocket-origin":"origin"],secure:!(!e.socket.authorized&&!e.socket.encrypted),req:e};if(2===this.options.verifyClient.length)return void this.options.verifyClient(i,((i,s,a,u)=>{if(!i)return m(t,s||401,a,u);this.completeUpgrade(o,c,e,t,n,r)}));if(!this.options.verifyClient(i))return m(t,401)}this.completeUpgrade(o,c,e,t,n,r)}completeUpgrade(e,t,n,r,o,u){if(!r.readable||!r.writable)return r.destroy();if(r[p])throw new Error("server.handleUpgrade() was called more than once with the same socket, possibly due to a misconfiguration");if(this._state>0)return m(r,503);const d=["HTTP/1.1 101 Switching Protocols","Upgrade: websocket","Connection: Upgrade",`Sec-WebSocket-Accept: ${i("sha1").update(e+l).digest("base64")}`],h=new a(null);let g=n.headers["sec-websocket-protocol"];if(g&&(g=g.split(",").map(v),g=this.options.handleProtocols?this.options.handleProtocols(g,n):g[0],g&&(d.push(`Sec-WebSocket-Protocol: ${g}`),h._protocol=g)),t[s.extensionName]){const e=t[s.extensionName].params,n=c({[s.extensionName]:[e]});d.push(`Sec-WebSocket-Extensions: ${n}`),h._extensions=t}this.emit("headers",d,n),r.write(d.concat("\r\n").join("\r\n")),r.removeListener("error",f),h.setSocket(r,o,this.options.maxPayload),this.clients&&(this.clients.add(h),h.on("close",(()=>this.clients.delete(h)))),u(h,n)}}},1060:(e,t,n)=>{"use strict";const r=n(4434),o=n(5692),i=n(8611),s=n(9278),a=n(4756),{randomBytes:c,createHash:u}=n(6982),{Readable:l}=n(2203),{URL:p}=n(7016),d=n(2971),h=n(3905),f=n(914),{BINARY_TYPES:m,EMPTY_BUFFER:v,GUID:g,kStatusCode:y,kWebSocket:_,NOOP:b}=n(2614),{addEventListener:E,removeEventListener:T}=n(597),{format:S,parse:C}=n(5926),{toBuffer:x}=n(3338),w=["CONNECTING","OPEN","CLOSING","CLOSED"],A=[8,13];class I extends r{constructor(e,t,n){super(),this._binaryType=m[0],this._closeCode=1006,this._closeFrameReceived=!1,this._closeFrameSent=!1,this._closeMessage="",this._closeTimer=null,this._extensions={},this._protocol="",this._readyState=I.CONNECTING,this._receiver=null,this._sender=null,this._socket=null,null!==e?(this._bufferedAmount=0,this._isServer=!1,this._redirects=0,Array.isArray(t)?t=t.join(", "):"object"==typeof t&&null!==t&&(n=t,t=void 0),R(this,e,t,n)):this._isServer=!0}get binaryType(){return this._binaryType}set binaryType(e){m.includes(e)&&(this._binaryType=e,this._receiver&&(this._receiver._binaryType=e))}get bufferedAmount(){return this._socket?this._socket._writableState.length+this._sender._bufferedBytes:this._bufferedAmount}get extensions(){return Object.keys(this._extensions).join()}get onclose(){}set onclose(e){}get onerror(){}set onerror(e){}get onopen(){}set onopen(e){}get onmessage(){}set onmessage(e){}get protocol(){return this._protocol}get readyState(){return this._readyState}get url(){return this._url}setSocket(e,t,n){const r=new h(this.binaryType,this._extensions,this._isServer,n);this._sender=new f(e,this._extensions),this._receiver=r,this._socket=e,r[_]=this,e[_]=this,r.on("conclude",M),r.on("drain",L),r.on("error",j),r.on("message",F),r.on("ping",z),r.on("pong",q),e.setTimeout(0),e.setNoDelay(),t.length>0&&e.unshift(t),e.on("close",H),e.on("data",G),e.on("end",V),e.on("error",$),this._readyState=I.OPEN,this.emit("open")}emitClose(){if(!this._socket)return this._readyState=I.CLOSED,void this.emit("close",this._closeCode,this._closeMessage);this._extensions[d.extensionName]&&this._extensions[d.extensionName].cleanup(),this._receiver.removeAllListeners(),this._readyState=I.CLOSED,this.emit("close",this._closeCode,this._closeMessage)}close(e,t){if(this.readyState!==I.CLOSED){if(this.readyState===I.CONNECTING){const e="WebSocket was closed before the connection was established";return k(this,this._req,e)}this.readyState!==I.CLOSING?(this._readyState=I.CLOSING,this._sender.close(e,t,!this._isServer,(e=>{e||(this._closeFrameSent=!0,(this._closeFrameReceived||this._receiver._writableState.errorEmitted)&&this._socket.end())})),this._closeTimer=setTimeout(this._socket.destroy.bind(this._socket),3e4)):this._closeFrameSent&&(this._closeFrameReceived||this._receiver._writableState.errorEmitted)&&this._socket.end()}}ping(e,t,n){if(this.readyState===I.CONNECTING)throw new Error("WebSocket is not open: readyState 0 (CONNECTING)");"function"==typeof e?(n=e,e=t=void 0):"function"==typeof t&&(n=t,t=void 0),"number"==typeof e&&(e=e.toString()),this.readyState===I.OPEN?(void 0===t&&(t=!this._isServer),this._sender.ping(e||v,t,n)):D(this,e,n)}pong(e,t,n){if(this.readyState===I.CONNECTING)throw new Error("WebSocket is not open: readyState 0 (CONNECTING)");"function"==typeof e?(n=e,e=t=void 0):"function"==typeof t&&(n=t,t=void 0),"number"==typeof e&&(e=e.toString()),this.readyState===I.OPEN?(void 0===t&&(t=!this._isServer),this._sender.pong(e||v,t,n)):D(this,e,n)}send(e,t,n){if(this.readyState===I.CONNECTING)throw new Error("WebSocket is not open: readyState 0 (CONNECTING)");if("function"==typeof t&&(n=t,t={}),"number"==typeof e&&(e=e.toString()),this.readyState!==I.OPEN)return void D(this,e,n);const r={binary:"string"!=typeof e,mask:!this._isServer,compress:!0,fin:!0,...t};this._extensions[d.extensionName]||(r.compress=!1),this._sender.send(e||v,r,n)}terminate(){if(this.readyState!==I.CLOSED){if(this.readyState===I.CONNECTING){const e="WebSocket was closed before the connection was established";return k(this,this._req,e)}this._socket&&(this._readyState=I.CLOSING,this._socket.destroy())}}}function R(e,t,n,r){const s={protocolVersion:A[1],maxPayload:104857600,perMessageDeflate:!0,followRedirects:!1,maxRedirects:10,...r,createConnection:void 0,socketPath:void 0,hostname:void 0,protocol:void 0,timeout:void 0,method:void 0,host:void 0,path:void 0,port:void 0};if(!A.includes(s.protocolVersion))throw new RangeError(`Unsupported protocol version: ${s.protocolVersion} (supported versions: ${A.join(", ")})`);let a;t instanceof p?(a=t,e._url=t.href):(a=new p(t),e._url=t);const l="ws+unix:"===a.protocol;if(!(a.host||l&&a.pathname)){const t=new Error(`Invalid URL: ${e.url}`);if(0===e._redirects)throw t;return void P(e,t)}const h="wss:"===a.protocol||"https:"===a.protocol,f=h?443:80,m=c(16).toString("base64"),v=h?o.get:i.get;let y;if(s.createConnection=h?N:O,s.defaultPort=s.defaultPort||f,s.port=a.port||f,s.host=a.hostname.startsWith("[")?a.hostname.slice(1,-1):a.hostname,s.headers={"Sec-WebSocket-Version":s.protocolVersion,"Sec-WebSocket-Key":m,Connection:"Upgrade",Upgrade:"websocket",...s.headers},s.path=a.pathname+a.search,s.timeout=s.handshakeTimeout,s.perMessageDeflate&&(y=new d(!0!==s.perMessageDeflate?s.perMessageDeflate:{},!1,s.maxPayload),s.headers["Sec-WebSocket-Extensions"]=S({[d.extensionName]:y.offer()})),n&&(s.headers["Sec-WebSocket-Protocol"]=n),s.origin&&(s.protocolVersion<13?s.headers["Sec-WebSocket-Origin"]=s.origin:s.headers.Origin=s.origin),(a.username||a.password)&&(s.auth=`${a.username}:${a.password}`),l){const e=s.path.split(":");s.socketPath=e[0],s.path=e[1]}if(s.followRedirects){if(0===e._redirects){e._originalUnixSocket=l,e._originalSecure=h,e._originalHostOrSocketPath=l?s.socketPath:a.host;const t=r&&r.headers;if(r={...r,headers:{}},t)for(const[e,n]of Object.entries(t))r.headers[e.toLowerCase()]=n}else{const t=l?!!e._originalUnixSocket&&s.socketPath===e._originalHostOrSocketPath:!e._originalUnixSocket&&a.host===e._originalHostOrSocketPath;(!t||e._originalSecure&&!h)&&(delete s.headers.authorization,delete s.headers.cookie,t||delete s.headers.host,s.auth=void 0)}s.auth&&!r.headers.authorization&&(r.headers.authorization="Basic "+Buffer.from(s.auth).toString("base64"))}let _=e._req=v(s);s.timeout&&_.on("timeout",(()=>{k(e,_,"Opening handshake has timed out")})),_.on("error",(t=>{null===_||_.aborted||(_=e._req=null,P(e,t))})),_.on("response",(o=>{const i=o.headers.location,a=o.statusCode;if(i&&s.followRedirects&&a>=300&&a<400){if(++e._redirects>s.maxRedirects)return void k(e,_,"Maximum redirects exceeded");let o;_.abort();try{o=new p(i,t)}catch(t){return void P(e,t)}R(e,o,n,r)}else e.emit("unexpected-response",_,o)||k(e,_,`Unexpected server response: ${o.statusCode}`)})),_.on("upgrade",((t,r,o)=>{if(e.emit("upgrade",t),e.readyState!==I.CONNECTING)return;_=e._req=null;const i=t.headers.upgrade;if(void 0===i||"websocket"!==i.toLowerCase())return void k(e,r,"Invalid Upgrade header");const a=u("sha1").update(m+g).digest("base64");if(t.headers["sec-websocket-accept"]!==a)return void k(e,r,"Invalid Sec-WebSocket-Accept header");const c=t.headers["sec-websocket-protocol"],l=(n||"").split(/, */);let p;if(!n&&c?p="Server sent a subprotocol but none was requested":n&&!c?p="Server sent no subprotocol":c&&!l.includes(c)&&(p="Server sent an invalid subprotocol"),p)return void k(e,r,p);c&&(e._protocol=c);const h=t.headers["sec-websocket-extensions"];if(void 0!==h){if(!y)return void k(e,r,"Server sent a Sec-WebSocket-Extensions header but no extension was requested");let t;try{t=C(h)}catch(t){return void k(e,r,"Invalid Sec-WebSocket-Extensions header")}const n=Object.keys(t);if(n.length){if(1!==n.length||n[0]!==d.extensionName)return void k(e,r,"Server indicated an extension that was not requested");try{y.accept(t[d.extensionName])}catch(t){return void k(e,r,"Invalid Sec-WebSocket-Extensions header")}e._extensions[d.extensionName]=y}}e.setSocket(r,o,s.maxPayload)}))}function P(e,t){e._readyState=I.CLOSING,e.emit("error",t),e.emitClose()}function O(e){return e.path=e.socketPath,s.connect(e)}function N(e){return e.path=void 0,e.servername||""===e.servername||(e.servername=s.isIP(e.host)?"":e.host),a.connect(e)}function k(e,t,n){e._readyState=I.CLOSING;const r=new Error(n);Error.captureStackTrace(r,k),t.setHeader?(t.abort(),t.socket&&!t.socket.destroyed&&t.socket.destroy(),t.once("abort",e.emitClose.bind(e)),e.emit("error",r)):(t.destroy(r),t.once("error",e.emit.bind(e,"error")),t.once("close",e.emitClose.bind(e)))}function D(e,t,n){if(t){const n=x(t).length;e._socket?e._sender._bufferedBytes+=n:e._bufferedAmount+=n}n&&n(new Error(`WebSocket is not open: readyState ${e.readyState} (${w[e.readyState]})`))}function M(e,t){const n=this[_];n._closeFrameReceived=!0,n._closeMessage=t,n._closeCode=e,void 0!==n._socket[_]&&(n._socket.removeListener("data",G),process.nextTick(B,n._socket),1005===e?n.close():n.close(e,t))}function L(){this[_]._socket.resume()}function j(e){const t=this[_];void 0!==t._socket[_]&&(t._socket.removeListener("data",G),process.nextTick(B,t._socket),t.close(e[y])),t.emit("error",e)}function U(){this[_].emitClose()}function F(e){this[_].emit("message",e)}function z(e){const t=this[_];t.pong(e,!t._isServer,b),t.emit("ping",e)}function q(e){this[_].emit("pong",e)}function B(e){e.resume()}function H(){const e=this[_];let t;this.removeListener("close",H),this.removeListener("data",G),this.removeListener("end",V),e._readyState=I.CLOSING,this._readableState.endEmitted||e._closeFrameReceived||e._receiver._writableState.errorEmitted||null===(t=e._socket.read())||e._receiver.write(t),e._receiver.end(),this[_]=void 0,clearTimeout(e._closeTimer),e._receiver._writableState.finished||e._receiver._writableState.errorEmitted?e.emitClose():(e._receiver.on("error",U),e._receiver.on("finish",U))}function G(e){this[_]._receiver.write(e)||this.pause()}function V(){const e=this[_];e._readyState=I.CLOSING,e._receiver.end(),this.end()}function $(){const e=this[_];this.removeListener("error",$),this.on("error",b),e&&(e._readyState=I.CLOSING,this.destroy())}Object.defineProperty(I,"CONNECTING",{enumerable:!0,value:w.indexOf("CONNECTING")}),Object.defineProperty(I.prototype,"CONNECTING",{enumerable:!0,value:w.indexOf("CONNECTING")}),Object.defineProperty(I,"OPEN",{enumerable:!0,value:w.indexOf("OPEN")}),Object.defineProperty(I.prototype,"OPEN",{enumerable:!0,value:w.indexOf("OPEN")}),Object.defineProperty(I,"CLOSING",{enumerable:!0,value:w.indexOf("CLOSING")}),Object.defineProperty(I.prototype,"CLOSING",{enumerable:!0,value:w.indexOf("CLOSING")}),Object.defineProperty(I,"CLOSED",{enumerable:!0,value:w.indexOf("CLOSED")}),Object.defineProperty(I.prototype,"CLOSED",{enumerable:!0,value:w.indexOf("CLOSED")}),["binaryType","bufferedAmount","extensions","protocol","readyState","url"].forEach((e=>{Object.defineProperty(I.prototype,e,{enumerable:!0})})),["open","error","close","message"].forEach((e=>{Object.defineProperty(I.prototype,`on${e}`,{enumerable:!0,get(){const t=this.listeners(e);for(let e=0;e<t.length;e++)if(t[e]._listener)return t[e]._listener},set(t){const n=this.listeners(e);for(let t=0;t<n.length;t++)n[t]._listener&&this.removeListener(e,n[t]);this.addEventListener(e,t)}})})),I.prototype.addEventListener=E,I.prototype.removeEventListener=T,e.exports=I},3177:function(e,t){(function(){"use strict";t.stripBOM=function(e){return"\ufeff"===e[0]?e.substring(1):e}}).call(this)},6712:function(e,t,n){(function(){"use strict";var e,r,o,i,s,a={}.hasOwnProperty;e=n(9665),r=n(6465).defaults,i=function(e){return"string"==typeof e&&(e.indexOf("&")>=0||e.indexOf(">")>=0||e.indexOf("<")>=0)},s=function(e){return"<![CDATA["+o(e)+"]]>"},o=function(e){return e.replace("]]>","]]]]><![CDATA[>")},t.Builder=function(){function t(e){var t,n,o;for(t in this.options={},n=r[.2])a.call(n,t)&&(o=n[t],this.options[t]=o);for(t in e)a.call(e,t)&&(o=e[t],this.options[t]=o)}return t.prototype.buildObject=function(t){var n,o,c,u,l,p;return n=this.options.attrkey,o=this.options.charkey,1===Object.keys(t).length&&this.options.rootName===r[.2].rootName?t=t[l=Object.keys(t)[0]]:l=this.options.rootName,p=this,c=function(e,t){var r,u,l,d,h,f;if("object"!=typeof t)p.options.cdata&&i(t)?e.raw(s(t)):e.txt(t);else if(Array.isArray(t)){for(d in t)if(a.call(t,d))for(h in u=t[d])l=u[h],e=c(e.ele(h),l).up()}else for(h in t)if(a.call(t,h))if(u=t[h],h===n){if("object"==typeof u)for(r in u)f=u[r],e=e.att(r,f)}else if(h===o)e=p.options.cdata&&i(u)?e.raw(s(u)):e.txt(u);else if(Array.isArray(u))for(d in u)a.call(u,d)&&(e="string"==typeof(l=u[d])?p.options.cdata&&i(l)?e.ele(h).raw(s(l)).up():e.ele(h,l).up():c(e.ele(h),l).up());else"object"==typeof u?e=c(e.ele(h),u).up():"string"==typeof u&&p.options.cdata&&i(u)?e=e.ele(h).raw(s(u)).up():(null==u&&(u=""),e=e.ele(h,u.toString()).up());return e},u=e.create(l,this.options.xmldec,this.options.doctype,{headless:this.options.headless,allowSurrogateChars:this.options.allowSurrogateChars}),c(u,t).end(this.options.renderOpts)},t}()}).call(this)},6465:function(e,t){(function(){t.defaults={.1:{explicitCharkey:!1,trim:!0,normalize:!0,normalizeTags:!1,attrkey:"@",charkey:"#",explicitArray:!1,ignoreAttrs:!1,mergeAttrs:!1,explicitRoot:!1,validator:null,xmlns:!1,explicitChildren:!1,childkey:"@@",charsAsChildren:!1,includeWhiteChars:!1,async:!1,strict:!0,attrNameProcessors:null,attrValueProcessors:null,tagNameProcessors:null,valueProcessors:null,emptyTag:""},.2:{explicitCharkey:!1,trim:!1,normalize:!1,normalizeTags:!1,attrkey:"$",charkey:"_",explicitArray:!0,ignoreAttrs:!1,mergeAttrs:!1,explicitRoot:!0,validator:null,xmlns:!1,explicitChildren:!1,preserveChildrenOrder:!1,childkey:"$$",charsAsChildren:!1,includeWhiteChars:!1,async:!1,strict:!0,attrNameProcessors:null,attrValueProcessors:null,tagNameProcessors:null,valueProcessors:null,rootName:"root",xmldec:{version:"1.0",encoding:"UTF-8",standalone:!0},doctype:null,renderOpts:{pretty:!0,indent:"  ",newline:"\n"},headless:!1,chunkSize:1e4,emptyTag:"",cdata:!1}}}).call(this)},1912:function(e,t,n){(function(){"use strict";var e,r,o,i,s,a,c,u,l=function(e,t){return function(){return e.apply(t,arguments)}},p={}.hasOwnProperty;c=n(4043),o=n(4434),e=n(3177),a=n(2114),u=n(3557).setImmediate,r=n(6465).defaults,i=function(e){return"object"==typeof e&&null!=e&&0===Object.keys(e).length},s=function(e,t,n){var r,o;for(r=0,o=e.length;r<o;r++)t=(0,e[r])(t,n);return t},t.Parser=function(n){function o(e){var n,o,i;if(this.parseStringPromise=l(this.parseStringPromise,this),this.parseString=l(this.parseString,this),this.reset=l(this.reset,this),this.assignOrPush=l(this.assignOrPush,this),this.processAsync=l(this.processAsync,this),!(this instanceof t.Parser))return new t.Parser(e);for(n in this.options={},o=r[.2])p.call(o,n)&&(i=o[n],this.options[n]=i);for(n in e)p.call(e,n)&&(i=e[n],this.options[n]=i);this.options.xmlns&&(this.options.xmlnskey=this.options.attrkey+"ns"),this.options.normalizeTags&&(this.options.tagNameProcessors||(this.options.tagNameProcessors=[]),this.options.tagNameProcessors.unshift(a.normalize)),this.reset()}return function(e,t){for(var n in t)p.call(t,n)&&(e[n]=t[n]);function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r,e.__super__=t.prototype}(o,n),o.prototype.processAsync=function(){var e,t;try{return this.remaining.length<=this.options.chunkSize?(e=this.remaining,this.remaining="",this.saxParser=this.saxParser.write(e),this.saxParser.close()):(e=this.remaining.substr(0,this.options.chunkSize),this.remaining=this.remaining.substr(this.options.chunkSize,this.remaining.length),this.saxParser=this.saxParser.write(e),u(this.processAsync))}catch(e){if(t=e,!this.saxParser.errThrown)return this.saxParser.errThrown=!0,this.emit(t)}},o.prototype.assignOrPush=function(e,t,n){return t in e?(e[t]instanceof Array||(e[t]=[e[t]]),e[t].push(n)):this.options.explicitArray?e[t]=[n]:e[t]=n},o.prototype.reset=function(){var e,t,n,r,o;return this.removeAllListeners(),this.saxParser=c.parser(this.options.strict,{trim:!1,normalize:!1,xmlns:this.options.xmlns}),this.saxParser.errThrown=!1,this.saxParser.onerror=(o=this,function(e){if(o.saxParser.resume(),!o.saxParser.errThrown)return o.saxParser.errThrown=!0,o.emit("error",e)}),this.saxParser.onend=function(e){return function(){if(!e.saxParser.ended)return e.saxParser.ended=!0,e.emit("end",e.resultObject)}}(this),this.saxParser.ended=!1,this.EXPLICIT_CHARKEY=this.options.explicitCharkey,this.resultObject=null,r=[],e=this.options.attrkey,t=this.options.charkey,this.saxParser.onopentag=function(n){return function(o){var i,a,c,u,l;if((c=Object.create(null))[t]="",!n.options.ignoreAttrs)for(i in l=o.attributes)p.call(l,i)&&(e in c||n.options.mergeAttrs||(c[e]=Object.create(null)),a=n.options.attrValueProcessors?s(n.options.attrValueProcessors,o.attributes[i],i):o.attributes[i],u=n.options.attrNameProcessors?s(n.options.attrNameProcessors,i):i,n.options.mergeAttrs?n.assignOrPush(c,u,a):c[e][u]=a);return c["#name"]=n.options.tagNameProcessors?s(n.options.tagNameProcessors,o.name):o.name,n.options.xmlns&&(c[n.options.xmlnskey]={uri:o.uri,local:o.local}),r.push(c)}}(this),this.saxParser.onclosetag=function(e){return function(){var n,o,a,c,u,l,d,h,f,m;if(l=r.pop(),u=l["#name"],e.options.explicitChildren&&e.options.preserveChildrenOrder||delete l["#name"],!0===l.cdata&&(n=l.cdata,delete l.cdata),f=r[r.length-1],l[t].match(/^\s*$/)&&!n?(o=l[t],delete l[t]):(e.options.trim&&(l[t]=l[t].trim()),e.options.normalize&&(l[t]=l[t].replace(/\s{2,}/g," ").trim()),l[t]=e.options.valueProcessors?s(e.options.valueProcessors,l[t],u):l[t],1===Object.keys(l).length&&t in l&&!e.EXPLICIT_CHARKEY&&(l=l[t])),i(l)&&(l="function"==typeof e.options.emptyTag?e.options.emptyTag():""!==e.options.emptyTag?e.options.emptyTag:o),null!=e.options.validator&&(m="/"+function(){var e,t,n;for(n=[],e=0,t=r.length;e<t;e++)c=r[e],n.push(c["#name"]);return n}().concat(u).join("/"),function(){var t;try{return l=e.options.validator(m,f&&f[u],l)}catch(n){return t=n,e.emit("error",t)}}()),e.options.explicitChildren&&!e.options.mergeAttrs&&"object"==typeof l)if(e.options.preserveChildrenOrder){if(f){for(a in f[e.options.childkey]=f[e.options.childkey]||[],d=Object.create(null),l)p.call(l,a)&&(d[a]=l[a]);f[e.options.childkey].push(d),delete l["#name"],1===Object.keys(l).length&&t in l&&!e.EXPLICIT_CHARKEY&&(l=l[t])}}else c=Object.create(null),e.options.attrkey in l&&(c[e.options.attrkey]=l[e.options.attrkey],delete l[e.options.attrkey]),!e.options.charsAsChildren&&e.options.charkey in l&&(c[e.options.charkey]=l[e.options.charkey],delete l[e.options.charkey]),Object.getOwnPropertyNames(l).length>0&&(c[e.options.childkey]=l),l=c;return r.length>0?e.assignOrPush(f,u,l):(e.options.explicitRoot&&(h=l,(l=Object.create(null))[u]=h),e.resultObject=l,e.saxParser.ended=!0,e.emit("end",e.resultObject))}}(this),n=function(e){return function(n){var o,i;if(i=r[r.length-1])return i[t]+=n,e.options.explicitChildren&&e.options.preserveChildrenOrder&&e.options.charsAsChildren&&(e.options.includeWhiteChars||""!==n.replace(/\\n/g,"").trim())&&(i[e.options.childkey]=i[e.options.childkey]||[],(o={"#name":"__text__"})[t]=n,e.options.normalize&&(o[t]=o[t].replace(/\s{2,}/g," ").trim()),i[e.options.childkey].push(o)),i}}(this),this.saxParser.ontext=n,this.saxParser.oncdata=function(e){var t;if(t=n(e))return t.cdata=!0}},o.prototype.parseString=function(t,n){var r;null!=n&&"function"==typeof n&&(this.on("end",(function(e){return this.reset(),n(null,e)})),this.on("error",(function(e){return this.reset(),n(e)})));try{return""===(t=t.toString()).trim()?(this.emit("end",null),!0):(t=e.stripBOM(t),this.options.async?(this.remaining=t,u(this.processAsync),this.saxParser):this.saxParser.write(t).close())}catch(e){if(r=e,!this.saxParser.errThrown&&!this.saxParser.ended)return this.emit("error",r),this.saxParser.errThrown=!0;if(this.saxParser.ended)throw r}},o.prototype.parseStringPromise=function(e){return new Promise((t=this,function(n,r){return t.parseString(e,(function(e,t){return e?r(e):n(t)}))}));var t},o}(o),t.parseString=function(e,n,r){var o,i;return null!=r?("function"==typeof r&&(o=r),"object"==typeof n&&(i=n)):("function"==typeof n&&(o=n),i={}),new t.Parser(i).parseString(e,o)},t.parseStringPromise=function(e,n){var r;return"object"==typeof n&&(r=n),new t.Parser(r).parseStringPromise(e)}}).call(this)},2114:function(e,t){(function(){"use strict";var e;e=new RegExp(/(?!xmlns)^.*:/),t.normalize=function(e){return e.toLowerCase()},t.firstCharLowerCase=function(e){return e.charAt(0).toLowerCase()+e.slice(1)},t.stripPrefix=function(t){return t.replace(e,"")},t.parseNumbers=function(e){return isNaN(e)||(e=e%1==0?parseInt(e,10):parseFloat(e)),e},t.parseBooleans=function(e){return/^(?:true|false)$/i.test(e)&&(e="true"===e.toLowerCase()),e}}).call(this)},8805:function(e,t,n){(function(){"use strict";var e,r,o,i,s={}.hasOwnProperty;r=n(6465),e=n(6712),o=n(1912),i=n(2114),t.defaults=r.defaults,t.processors=i,t.ValidationError=function(){function e(e){this.message=e}return function(e,t){for(var n in t)s.call(t,n)&&(e[n]=t[n]);function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r,e.__super__=t.prototype}(e,Error),e}(),t.Builder=e.Builder,t.Parser=o.Parser,t.parseString=o.parseString,t.parseStringPromise=o.parseStringPromise}).call(this)},4923:function(e){(function(){e.exports={Disconnected:1,Preceding:2,Following:4,Contains:8,ContainedBy:16,ImplementationSpecific:32}}).call(this)},1737:function(e){(function(){e.exports={Element:1,Attribute:2,Text:3,CData:4,EntityReference:5,EntityDeclaration:6,ProcessingInstruction:7,Comment:8,Document:9,DocType:10,DocumentFragment:11,NotationDeclaration:12,Declaration:201,Raw:202,AttributeDeclaration:203,ElementDeclaration:204,Dummy:205}}).call(this)},9241:function(e){(function(){var t,n,r,o,i,s,a,c=[].slice,u={}.hasOwnProperty;t=function(){var e,t,n,r,o,s;if(s=arguments[0],o=2<=arguments.length?c.call(arguments,1):[],i(Object.assign))Object.assign.apply(null,arguments);else for(e=0,n=o.length;e<n;e++)if(null!=(r=o[e]))for(t in r)u.call(r,t)&&(s[t]=r[t]);return s},i=function(e){return!!e&&"[object Function]"===Object.prototype.toString.call(e)},s=function(e){var t;return!!e&&("function"==(t=typeof e)||"object"===t)},r=function(e){return i(Array.isArray)?Array.isArray(e):"[object Array]"===Object.prototype.toString.call(e)},o=function(e){var t;if(r(e))return!e.length;for(t in e)if(u.call(e,t))return!1;return!0},a=function(e){var t,n;return s(e)&&(n=Object.getPrototypeOf(e))&&(t=n.constructor)&&"function"==typeof t&&t instanceof t&&Function.prototype.toString.call(t)===Function.prototype.toString.call(Object)},n=function(e){return i(e.valueOf)?e.valueOf():e},e.exports.assign=t,e.exports.isFunction=i,e.exports.isObject=s,e.exports.isArray=r,e.exports.isEmpty=o,e.exports.isPlainObject=a,e.exports.getValue=n}).call(this)},8753:function(e){(function(){e.exports={None:0,OpenTag:1,InsideTag:2,CloseTag:3}}).call(this)},4238:function(e,t,n){(function(){var t;t=n(1737),n(468),e.exports=function(){function e(e,n,r){if(this.parent=e,this.parent&&(this.options=this.parent.options,this.stringify=this.parent.stringify),null==n)throw new Error("Missing attribute name. "+this.debugInfo(n));this.name=this.stringify.name(n),this.value=this.stringify.attValue(r),this.type=t.Attribute,this.isId=!1,this.schemaTypeInfo=null}return Object.defineProperty(e.prototype,"nodeType",{get:function(){return this.type}}),Object.defineProperty(e.prototype,"ownerElement",{get:function(){return this.parent}}),Object.defineProperty(e.prototype,"textContent",{get:function(){return this.value},set:function(e){return this.value=e||""}}),Object.defineProperty(e.prototype,"namespaceURI",{get:function(){return""}}),Object.defineProperty(e.prototype,"prefix",{get:function(){return""}}),Object.defineProperty(e.prototype,"localName",{get:function(){return this.name}}),Object.defineProperty(e.prototype,"specified",{get:function(){return!0}}),e.prototype.clone=function(){return Object.create(this)},e.prototype.toString=function(e){return this.options.writer.attribute(this,this.options.writer.filterOptions(e))},e.prototype.debugInfo=function(e){return null==(e=e||this.name)?"parent: <"+this.parent.name+">":"attribute: {"+e+"}, parent: <"+this.parent.name+">"},e.prototype.isEqualNode=function(e){return e.namespaceURI===this.namespaceURI&&e.prefix===this.prefix&&e.localName===this.localName&&e.value===this.value},e}()}).call(this)},2691:function(e,t,n){(function(){var t,r,o={}.hasOwnProperty;t=n(1737),r=n(7457),e.exports=function(e){function n(e,r){if(n.__super__.constructor.call(this,e),null==r)throw new Error("Missing CDATA text. "+this.debugInfo());this.name="#cdata-section",this.type=t.CData,this.value=this.stringify.cdata(r)}return function(e,t){for(var n in t)o.call(t,n)&&(e[n]=t[n]);function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r,e.__super__=t.prototype}(n,e),n.prototype.clone=function(){return Object.create(this)},n.prototype.toString=function(e){return this.options.writer.cdata(this,this.options.writer.filterOptions(e))},n}(r)}).call(this)},7457:function(e,t,n){(function(){var t,r={}.hasOwnProperty;t=n(468),e.exports=function(e){function t(e){t.__super__.constructor.call(this,e),this.value=""}return function(e,t){for(var n in t)r.call(t,n)&&(e[n]=t[n]);function o(){this.constructor=e}o.prototype=t.prototype,e.prototype=new o,e.__super__=t.prototype}(t,e),Object.defineProperty(t.prototype,"data",{get:function(){return this.value},set:function(e){return this.value=e||""}}),Object.defineProperty(t.prototype,"length",{get:function(){return this.value.length}}),Object.defineProperty(t.prototype,"textContent",{get:function(){return this.value},set:function(e){return this.value=e||""}}),t.prototype.clone=function(){return Object.create(this)},t.prototype.substringData=function(e,t){throw new Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.appendData=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.insertData=function(e,t){throw new Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.deleteData=function(e,t){throw new Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.replaceData=function(e,t,n){throw new Error("This DOM method is not implemented."+this.debugInfo())},t.prototype.isEqualNode=function(e){return!!t.__super__.isEqualNode.apply(this,arguments).isEqualNode(e)&&e.data===this.data},t}(t)}).call(this)},2679:function(e,t,n){(function(){var t,r,o={}.hasOwnProperty;t=n(1737),r=n(7457),e.exports=function(e){function n(e,r){if(n.__super__.constructor.call(this,e),null==r)throw new Error("Missing comment text. "+this.debugInfo());this.name="#comment",this.type=t.Comment,this.value=this.stringify.comment(r)}return function(e,t){for(var n in t)o.call(t,n)&&(e[n]=t[n]);function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r,e.__super__=t.prototype}(n,e),n.prototype.clone=function(){return Object.create(this)},n.prototype.toString=function(e){return this.options.writer.comment(this,this.options.writer.filterOptions(e))},n}(r)}).call(this)},3074:function(e,t,n){(function(){var t,r;t=n(5660),r=n(2527),e.exports=function(){function e(){this.defaultParams={"canonical-form":!1,"cdata-sections":!1,comments:!1,"datatype-normalization":!1,"element-content-whitespace":!0,entities:!0,"error-handler":new t,infoset:!0,"validate-if-schema":!1,namespaces:!0,"namespace-declarations":!0,"normalize-characters":!1,"schema-location":"","schema-type":"","split-cdata-sections":!0,validate:!1,"well-formed":!0},this.params=Object.create(this.defaultParams)}return Object.defineProperty(e.prototype,"parameterNames",{get:function(){return new r(Object.keys(this.defaultParams))}}),e.prototype.getParameter=function(e){return this.params.hasOwnProperty(e)?this.params[e]:null},e.prototype.canSetParameter=function(e,t){return!0},e.prototype.setParameter=function(e,t){return null!=t?this.params[e]=t:delete this.params[e]},e}()}).call(this)},5660:function(e){(function(){e.exports=function(){function e(){}return e.prototype.handleError=function(e){throw new Error(e)},e}()}).call(this)},7260:function(e){(function(){e.exports=function(){function e(){}return e.prototype.hasFeature=function(e,t){return!0},e.prototype.createDocumentType=function(e,t,n){throw new Error("This DOM method is not implemented.")},e.prototype.createDocument=function(e,t,n){throw new Error("This DOM method is not implemented.")},e.prototype.createHTMLDocument=function(e){throw new Error("This DOM method is not implemented.")},e.prototype.getFeature=function(e,t){throw new Error("This DOM method is not implemented.")},e}()}).call(this)},2527:function(e){(function(){e.exports=function(){function e(e){this.arr=e||[]}return Object.defineProperty(e.prototype,"length",{get:function(){return this.arr.length}}),e.prototype.item=function(e){return this.arr[e]||null},e.prototype.contains=function(e){return-1!==this.arr.indexOf(e)},e}()}).call(this)},4111:function(e,t,n){(function(){var t,r,o={}.hasOwnProperty;r=n(468),t=n(1737),e.exports=function(e){function n(e,r,o,i,s,a){if(n.__super__.constructor.call(this,e),null==r)throw new Error("Missing DTD element name. "+this.debugInfo());if(null==o)throw new Error("Missing DTD attribute name. "+this.debugInfo(r));if(!i)throw new Error("Missing DTD attribute type. "+this.debugInfo(r));if(!s)throw new Error("Missing DTD attribute default. "+this.debugInfo(r));if(0!==s.indexOf("#")&&(s="#"+s),!s.match(/^(#REQUIRED|#IMPLIED|#FIXED|#DEFAULT)$/))throw new Error("Invalid default value type; expected: #REQUIRED, #IMPLIED, #FIXED or #DEFAULT. "+this.debugInfo(r));if(a&&!s.match(/^(#FIXED|#DEFAULT)$/))throw new Error("Default value only applies to #FIXED or #DEFAULT. "+this.debugInfo(r));this.elementName=this.stringify.name(r),this.type=t.AttributeDeclaration,this.attributeName=this.stringify.name(o),this.attributeType=this.stringify.dtdAttType(i),a&&(this.defaultValue=this.stringify.dtdAttDefault(a)),this.defaultValueType=s}return function(e,t){for(var n in t)o.call(t,n)&&(e[n]=t[n]);function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r,e.__super__=t.prototype}(n,e),n.prototype.toString=function(e){return this.options.writer.dtdAttList(this,this.options.writer.filterOptions(e))},n}(r)}).call(this)},7696:function(e,t,n){(function(){var t,r,o={}.hasOwnProperty;r=n(468),t=n(1737),e.exports=function(e){function n(e,r,o){if(n.__super__.constructor.call(this,e),null==r)throw new Error("Missing DTD element name. "+this.debugInfo());o||(o="(#PCDATA)"),Array.isArray(o)&&(o="("+o.join(",")+")"),this.name=this.stringify.name(r),this.type=t.ElementDeclaration,this.value=this.stringify.dtdElementValue(o)}return function(e,t){for(var n in t)o.call(t,n)&&(e[n]=t[n]);function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r,e.__super__=t.prototype}(n,e),n.prototype.toString=function(e){return this.options.writer.dtdElement(this,this.options.writer.filterOptions(e))},n}(r)}).call(this)},5529:function(e,t,n){(function(){var t,r,o,i={}.hasOwnProperty;o=n(9241).isObject,r=n(468),t=n(1737),e.exports=function(e){function n(e,r,i,s){if(n.__super__.constructor.call(this,e),null==i)throw new Error("Missing DTD entity name. "+this.debugInfo(i));if(null==s)throw new Error("Missing DTD entity value. "+this.debugInfo(i));if(this.pe=!!r,this.name=this.stringify.name(i),this.type=t.EntityDeclaration,o(s)){if(!s.pubID&&!s.sysID)throw new Error("Public and/or system identifiers are required for an external entity. "+this.debugInfo(i));if(s.pubID&&!s.sysID)throw new Error("System identifier is required for a public external entity. "+this.debugInfo(i));if(this.internal=!1,null!=s.pubID&&(this.pubID=this.stringify.dtdPubID(s.pubID)),null!=s.sysID&&(this.sysID=this.stringify.dtdSysID(s.sysID)),null!=s.nData&&(this.nData=this.stringify.dtdNData(s.nData)),this.pe&&this.nData)throw new Error("Notation declaration is not allowed in a parameter entity. "+this.debugInfo(i))}else this.value=this.stringify.dtdEntityValue(s),this.internal=!0}return function(e,t){for(var n in t)i.call(t,n)&&(e[n]=t[n]);function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r,e.__super__=t.prototype}(n,e),Object.defineProperty(n.prototype,"publicId",{get:function(){return this.pubID}}),Object.defineProperty(n.prototype,"systemId",{get:function(){return this.sysID}}),Object.defineProperty(n.prototype,"notationName",{get:function(){return this.nData||null}}),Object.defineProperty(n.prototype,"inputEncoding",{get:function(){return null}}),Object.defineProperty(n.prototype,"xmlEncoding",{get:function(){return null}}),Object.defineProperty(n.prototype,"xmlVersion",{get:function(){return null}}),n.prototype.toString=function(e){return this.options.writer.dtdEntity(this,this.options.writer.filterOptions(e))},n}(r)}).call(this)},5631:function(e,t,n){(function(){var t,r,o={}.hasOwnProperty;r=n(468),t=n(1737),e.exports=function(e){function n(e,r,o){if(n.__super__.constructor.call(this,e),null==r)throw new Error("Missing DTD notation name. "+this.debugInfo(r));if(!o.pubID&&!o.sysID)throw new Error("Public or system identifiers are required for an external entity. "+this.debugInfo(r));this.name=this.stringify.name(r),this.type=t.NotationDeclaration,null!=o.pubID&&(this.pubID=this.stringify.dtdPubID(o.pubID)),null!=o.sysID&&(this.sysID=this.stringify.dtdSysID(o.sysID))}return function(e,t){for(var n in t)o.call(t,n)&&(e[n]=t[n]);function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r,e.__super__=t.prototype}(n,e),Object.defineProperty(n.prototype,"publicId",{get:function(){return this.pubID}}),Object.defineProperty(n.prototype,"systemId",{get:function(){return this.sysID}}),n.prototype.toString=function(e){return this.options.writer.dtdNotation(this,this.options.writer.filterOptions(e))},n}(r)}).call(this)},4130:function(e,t,n){(function(){var t,r,o,i={}.hasOwnProperty;o=n(9241).isObject,r=n(468),t=n(1737),e.exports=function(e){function n(e,r,i,s){var a;n.__super__.constructor.call(this,e),o(r)&&(r=(a=r).version,i=a.encoding,s=a.standalone),r||(r="1.0"),this.type=t.Declaration,this.version=this.stringify.xmlVersion(r),null!=i&&(this.encoding=this.stringify.xmlEncoding(i)),null!=s&&(this.standalone=this.stringify.xmlStandalone(s))}return function(e,t){for(var n in t)i.call(t,n)&&(e[n]=t[n]);function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r,e.__super__=t.prototype}(n,e),n.prototype.toString=function(e){return this.options.writer.declaration(this,this.options.writer.filterOptions(e))},n}(r)}).call(this)},6376:function(e,t,n){(function(){var t,r,o,i,s,a,c,u,l={}.hasOwnProperty;u=n(9241).isObject,c=n(468),t=n(1737),r=n(4111),i=n(5529),o=n(7696),s=n(5631),a=n(4797),e.exports=function(e){function n(e,r,o){var i,s,a,c,l,p;if(n.__super__.constructor.call(this,e),this.type=t.DocType,e.children)for(s=0,a=(c=e.children).length;s<a;s++)if((i=c[s]).type===t.Element){this.name=i.name;break}this.documentObject=e,u(r)&&(r=(l=r).pubID,o=l.sysID),null==o&&(o=(p=[r,o])[0],r=p[1]),null!=r&&(this.pubID=this.stringify.dtdPubID(r)),null!=o&&(this.sysID=this.stringify.dtdSysID(o))}return function(e,t){for(var n in t)l.call(t,n)&&(e[n]=t[n]);function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r,e.__super__=t.prototype}(n,e),Object.defineProperty(n.prototype,"entities",{get:function(){var e,n,r,o,i;for(o={},n=0,r=(i=this.children).length;n<r;n++)(e=i[n]).type!==t.EntityDeclaration||e.pe||(o[e.name]=e);return new a(o)}}),Object.defineProperty(n.prototype,"notations",{get:function(){var e,n,r,o,i;for(o={},n=0,r=(i=this.children).length;n<r;n++)(e=i[n]).type===t.NotationDeclaration&&(o[e.name]=e);return new a(o)}}),Object.defineProperty(n.prototype,"publicId",{get:function(){return this.pubID}}),Object.defineProperty(n.prototype,"systemId",{get:function(){return this.sysID}}),Object.defineProperty(n.prototype,"internalSubset",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),n.prototype.element=function(e,t){var n;return n=new o(this,e,t),this.children.push(n),this},n.prototype.attList=function(e,t,n,o,i){var s;return s=new r(this,e,t,n,o,i),this.children.push(s),this},n.prototype.entity=function(e,t){var n;return n=new i(this,!1,e,t),this.children.push(n),this},n.prototype.pEntity=function(e,t){var n;return n=new i(this,!0,e,t),this.children.push(n),this},n.prototype.notation=function(e,t){var n;return n=new s(this,e,t),this.children.push(n),this},n.prototype.toString=function(e){return this.options.writer.docType(this,this.options.writer.filterOptions(e))},n.prototype.ele=function(e,t){return this.element(e,t)},n.prototype.att=function(e,t,n,r,o){return this.attList(e,t,n,r,o)},n.prototype.ent=function(e,t){return this.entity(e,t)},n.prototype.pent=function(e,t){return this.pEntity(e,t)},n.prototype.not=function(e,t){return this.notation(e,t)},n.prototype.up=function(){return this.root()||this.documentObject},n.prototype.isEqualNode=function(e){return!!n.__super__.isEqualNode.apply(this,arguments).isEqualNode(e)&&e.name===this.name&&e.publicId===this.publicId&&e.systemId===this.systemId},n}(c)}).call(this)},1933:function(e,t,n){(function(){var t,r,o,i,s,a,c,u={}.hasOwnProperty;c=n(9241).isPlainObject,o=n(7260),r=n(3074),i=n(468),t=n(1737),a=n(3976),s=n(382),e.exports=function(e){function n(e){n.__super__.constructor.call(this,null),this.name="#document",this.type=t.Document,this.documentURI=null,this.domConfig=new r,e||(e={}),e.writer||(e.writer=new s),this.options=e,this.stringify=new a(e)}return function(e,t){for(var n in t)u.call(t,n)&&(e[n]=t[n]);function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r,e.__super__=t.prototype}(n,e),Object.defineProperty(n.prototype,"implementation",{value:new o}),Object.defineProperty(n.prototype,"doctype",{get:function(){var e,n,r,o;for(n=0,r=(o=this.children).length;n<r;n++)if((e=o[n]).type===t.DocType)return e;return null}}),Object.defineProperty(n.prototype,"documentElement",{get:function(){return this.rootObject||null}}),Object.defineProperty(n.prototype,"inputEncoding",{get:function(){return null}}),Object.defineProperty(n.prototype,"strictErrorChecking",{get:function(){return!1}}),Object.defineProperty(n.prototype,"xmlEncoding",{get:function(){return 0!==this.children.length&&this.children[0].type===t.Declaration?this.children[0].encoding:null}}),Object.defineProperty(n.prototype,"xmlStandalone",{get:function(){return 0!==this.children.length&&this.children[0].type===t.Declaration&&"yes"===this.children[0].standalone}}),Object.defineProperty(n.prototype,"xmlVersion",{get:function(){return 0!==this.children.length&&this.children[0].type===t.Declaration?this.children[0].version:"1.0"}}),Object.defineProperty(n.prototype,"URL",{get:function(){return this.documentURI}}),Object.defineProperty(n.prototype,"origin",{get:function(){return null}}),Object.defineProperty(n.prototype,"compatMode",{get:function(){return null}}),Object.defineProperty(n.prototype,"characterSet",{get:function(){return null}}),Object.defineProperty(n.prototype,"contentType",{get:function(){return null}}),n.prototype.end=function(e){var t;return t={},e?c(e)&&(t=e,e=this.options.writer):e=this.options.writer,e.document(this,e.filterOptions(t))},n.prototype.toString=function(e){return this.options.writer.document(this,this.options.writer.filterOptions(e))},n.prototype.createElement=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.createDocumentFragment=function(){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.createTextNode=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.createComment=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.createCDATASection=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.createProcessingInstruction=function(e,t){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.createAttribute=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.createEntityReference=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.getElementsByTagName=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.importNode=function(e,t){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.createElementNS=function(e,t){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.createAttributeNS=function(e,t){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.getElementsByTagNameNS=function(e,t){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.getElementById=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.adoptNode=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.normalizeDocument=function(){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.renameNode=function(e,t,n){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.getElementsByClassName=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.createEvent=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.createRange=function(){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.createNodeIterator=function(e,t,n){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.createTreeWalker=function(e,t,n){throw new Error("This DOM method is not implemented."+this.debugInfo())},n}(i)}).call(this)},400:function(e,t,n){(function(){var t,r,o,i,s,a,c,u,l,p,d,h,f,m,v,g,y,_,b,E,T,S,C,x={}.hasOwnProperty;C=n(9241),T=C.isObject,E=C.isFunction,S=C.isPlainObject,b=C.getValue,t=n(1737),h=n(1933),f=n(3906),i=n(2691),s=n(2679),v=n(1268),_=n(2535),m=n(5915),p=n(4130),d=n(6376),a=n(4111),u=n(5529),c=n(7696),l=n(5631),o=n(4238),y=n(3976),g=n(382),r=n(8753),e.exports=function(){function e(e,n,r){var o;this.name="?xml",this.type=t.Document,e||(e={}),o={},e.writer?S(e.writer)&&(o=e.writer,e.writer=new g):e.writer=new g,this.options=e,this.writer=e.writer,this.writerOptions=this.writer.filterOptions(o),this.stringify=new y(e),this.onDataCallback=n||function(){},this.onEndCallback=r||function(){},this.currentNode=null,this.currentLevel=-1,this.openTags={},this.documentStarted=!1,this.documentCompleted=!1,this.root=null}return e.prototype.createChildNode=function(e){var n,r,o,i,s,a,c,u;switch(e.type){case t.CData:this.cdata(e.value);break;case t.Comment:this.comment(e.value);break;case t.Element:for(r in o={},c=e.attribs)x.call(c,r)&&(n=c[r],o[r]=n.value);this.node(e.name,o);break;case t.Dummy:this.dummy();break;case t.Raw:this.raw(e.value);break;case t.Text:this.text(e.value);break;case t.ProcessingInstruction:this.instruction(e.target,e.value);break;default:throw new Error("This XML node type is not supported in a JS object: "+e.constructor.name)}for(s=0,a=(u=e.children).length;s<a;s++)i=u[s],this.createChildNode(i),i.type===t.Element&&this.up();return this},e.prototype.dummy=function(){return this},e.prototype.node=function(e,t,n){var r;if(null==e)throw new Error("Missing node name.");if(this.root&&-1===this.currentLevel)throw new Error("Document can only have one root node. "+this.debugInfo(e));return this.openCurrent(),e=b(e),null==t&&(t={}),t=b(t),T(t)||(n=(r=[t,n])[0],t=r[1]),this.currentNode=new f(this,e,t),this.currentNode.children=!1,this.currentLevel++,this.openTags[this.currentLevel]=this.currentNode,null!=n&&this.text(n),this},e.prototype.element=function(e,n,r){var o,i,s,a,c,u;if(this.currentNode&&this.currentNode.type===t.DocType)this.dtdElement.apply(this,arguments);else if(Array.isArray(e)||T(e)||E(e))for(a=this.options.noValidation,this.options.noValidation=!0,(u=new h(this.options).element("TEMP_ROOT")).element(e),this.options.noValidation=a,i=0,s=(c=u.children).length;i<s;i++)o=c[i],this.createChildNode(o),o.type===t.Element&&this.up();else this.node(e,n,r);return this},e.prototype.attribute=function(e,t){var n,r;if(!this.currentNode||this.currentNode.children)throw new Error("att() can only be used immediately after an ele() call in callback mode. "+this.debugInfo(e));if(null!=e&&(e=b(e)),T(e))for(n in e)x.call(e,n)&&(r=e[n],this.attribute(n,r));else E(t)&&(t=t.apply()),this.options.keepNullAttributes&&null==t?this.currentNode.attribs[e]=new o(this,e,""):null!=t&&(this.currentNode.attribs[e]=new o(this,e,t));return this},e.prototype.text=function(e){var t;return this.openCurrent(),t=new _(this,e),this.onData(this.writer.text(t,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},e.prototype.cdata=function(e){var t;return this.openCurrent(),t=new i(this,e),this.onData(this.writer.cdata(t,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},e.prototype.comment=function(e){var t;return this.openCurrent(),t=new s(this,e),this.onData(this.writer.comment(t,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},e.prototype.raw=function(e){var t;return this.openCurrent(),t=new v(this,e),this.onData(this.writer.raw(t,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},e.prototype.instruction=function(e,t){var n,r,o,i,s;if(this.openCurrent(),null!=e&&(e=b(e)),null!=t&&(t=b(t)),Array.isArray(e))for(n=0,i=e.length;n<i;n++)r=e[n],this.instruction(r);else if(T(e))for(r in e)x.call(e,r)&&(o=e[r],this.instruction(r,o));else E(t)&&(t=t.apply()),s=new m(this,e,t),this.onData(this.writer.processingInstruction(s,this.writerOptions,this.currentLevel+1),this.currentLevel+1);return this},e.prototype.declaration=function(e,t,n){var r;if(this.openCurrent(),this.documentStarted)throw new Error("declaration() must be the first node.");return r=new p(this,e,t,n),this.onData(this.writer.declaration(r,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},e.prototype.doctype=function(e,t,n){if(this.openCurrent(),null==e)throw new Error("Missing root node name.");if(this.root)throw new Error("dtd() must come before the root node.");return this.currentNode=new d(this,t,n),this.currentNode.rootNodeName=e,this.currentNode.children=!1,this.currentLevel++,this.openTags[this.currentLevel]=this.currentNode,this},e.prototype.dtdElement=function(e,t){var n;return this.openCurrent(),n=new c(this,e,t),this.onData(this.writer.dtdElement(n,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},e.prototype.attList=function(e,t,n,r,o){var i;return this.openCurrent(),i=new a(this,e,t,n,r,o),this.onData(this.writer.dtdAttList(i,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},e.prototype.entity=function(e,t){var n;return this.openCurrent(),n=new u(this,!1,e,t),this.onData(this.writer.dtdEntity(n,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},e.prototype.pEntity=function(e,t){var n;return this.openCurrent(),n=new u(this,!0,e,t),this.onData(this.writer.dtdEntity(n,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},e.prototype.notation=function(e,t){var n;return this.openCurrent(),n=new l(this,e,t),this.onData(this.writer.dtdNotation(n,this.writerOptions,this.currentLevel+1),this.currentLevel+1),this},e.prototype.up=function(){if(this.currentLevel<0)throw new Error("The document node has no parent.");return this.currentNode?(this.currentNode.children?this.closeNode(this.currentNode):this.openNode(this.currentNode),this.currentNode=null):this.closeNode(this.openTags[this.currentLevel]),delete this.openTags[this.currentLevel],this.currentLevel--,this},e.prototype.end=function(){for(;this.currentLevel>=0;)this.up();return this.onEnd()},e.prototype.openCurrent=function(){if(this.currentNode)return this.currentNode.children=!0,this.openNode(this.currentNode)},e.prototype.openNode=function(e){var n,o,i,s;if(!e.isOpen){if(this.root||0!==this.currentLevel||e.type!==t.Element||(this.root=e),o="",e.type===t.Element){for(i in this.writerOptions.state=r.OpenTag,o=this.writer.indent(e,this.writerOptions,this.currentLevel)+"<"+e.name,s=e.attribs)x.call(s,i)&&(n=s[i],o+=this.writer.attribute(n,this.writerOptions,this.currentLevel));o+=(e.children?">":"/>")+this.writer.endline(e,this.writerOptions,this.currentLevel),this.writerOptions.state=r.InsideTag}else this.writerOptions.state=r.OpenTag,o=this.writer.indent(e,this.writerOptions,this.currentLevel)+"<!DOCTYPE "+e.rootNodeName,e.pubID&&e.sysID?o+=' PUBLIC "'+e.pubID+'" "'+e.sysID+'"':e.sysID&&(o+=' SYSTEM "'+e.sysID+'"'),e.children?(o+=" [",this.writerOptions.state=r.InsideTag):(this.writerOptions.state=r.CloseTag,o+=">"),o+=this.writer.endline(e,this.writerOptions,this.currentLevel);return this.onData(o,this.currentLevel),e.isOpen=!0}},e.prototype.closeNode=function(e){var n;if(!e.isClosed)return"",this.writerOptions.state=r.CloseTag,n=e.type===t.Element?this.writer.indent(e,this.writerOptions,this.currentLevel)+"</"+e.name+">"+this.writer.endline(e,this.writerOptions,this.currentLevel):this.writer.indent(e,this.writerOptions,this.currentLevel)+"]>"+this.writer.endline(e,this.writerOptions,this.currentLevel),this.writerOptions.state=r.None,this.onData(n,this.currentLevel),e.isClosed=!0},e.prototype.onData=function(e,t){return this.documentStarted=!0,this.onDataCallback(e,t+1)},e.prototype.onEnd=function(){return this.documentCompleted=!0,this.onEndCallback()},e.prototype.debugInfo=function(e){return null==e?"":"node: <"+e+">"},e.prototype.ele=function(){return this.element.apply(this,arguments)},e.prototype.nod=function(e,t,n){return this.node(e,t,n)},e.prototype.txt=function(e){return this.text(e)},e.prototype.dat=function(e){return this.cdata(e)},e.prototype.com=function(e){return this.comment(e)},e.prototype.ins=function(e,t){return this.instruction(e,t)},e.prototype.dec=function(e,t,n){return this.declaration(e,t,n)},e.prototype.dtd=function(e,t,n){return this.doctype(e,t,n)},e.prototype.e=function(e,t,n){return this.element(e,t,n)},e.prototype.n=function(e,t,n){return this.node(e,t,n)},e.prototype.t=function(e){return this.text(e)},e.prototype.d=function(e){return this.cdata(e)},e.prototype.c=function(e){return this.comment(e)},e.prototype.r=function(e){return this.raw(e)},e.prototype.i=function(e,t){return this.instruction(e,t)},e.prototype.att=function(){return this.currentNode&&this.currentNode.type===t.DocType?this.attList.apply(this,arguments):this.attribute.apply(this,arguments)},e.prototype.a=function(){return this.currentNode&&this.currentNode.type===t.DocType?this.attList.apply(this,arguments):this.attribute.apply(this,arguments)},e.prototype.ent=function(e,t){return this.entity(e,t)},e.prototype.pent=function(e,t){return this.pEntity(e,t)},e.prototype.not=function(e,t){return this.notation(e,t)},e}()}).call(this)},1218:function(e,t,n){(function(){var t,r,o={}.hasOwnProperty;r=n(468),t=n(1737),e.exports=function(e){function n(e){n.__super__.constructor.call(this,e),this.type=t.Dummy}return function(e,t){for(var n in t)o.call(t,n)&&(e[n]=t[n]);function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r,e.__super__=t.prototype}(n,e),n.prototype.clone=function(){return Object.create(this)},n.prototype.toString=function(e){return""},n}(r)}).call(this)},3906:function(e,t,n){(function(){var t,r,o,i,s,a,c,u,l={}.hasOwnProperty;u=n(9241),c=u.isObject,a=u.isFunction,s=u.getValue,i=n(468),t=n(1737),r=n(4238),o=n(4797),e.exports=function(e){function n(e,r,o){var i,s,a,c;if(n.__super__.constructor.call(this,e),null==r)throw new Error("Missing element name. "+this.debugInfo());if(this.name=this.stringify.name(r),this.type=t.Element,this.attribs={},this.schemaTypeInfo=null,null!=o&&this.attribute(o),e.type===t.Document&&(this.isRoot=!0,this.documentObject=e,e.rootObject=this,e.children))for(s=0,a=(c=e.children).length;s<a;s++)if((i=c[s]).type===t.DocType){i.name=this.name;break}}return function(e,t){for(var n in t)l.call(t,n)&&(e[n]=t[n]);function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r,e.__super__=t.prototype}(n,e),Object.defineProperty(n.prototype,"tagName",{get:function(){return this.name}}),Object.defineProperty(n.prototype,"namespaceURI",{get:function(){return""}}),Object.defineProperty(n.prototype,"prefix",{get:function(){return""}}),Object.defineProperty(n.prototype,"localName",{get:function(){return this.name}}),Object.defineProperty(n.prototype,"id",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(n.prototype,"className",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(n.prototype,"classList",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(n.prototype,"attributes",{get:function(){return this.attributeMap&&this.attributeMap.nodes||(this.attributeMap=new o(this.attribs)),this.attributeMap}}),n.prototype.clone=function(){var e,t,n,r;for(t in(n=Object.create(this)).isRoot&&(n.documentObject=null),n.attribs={},r=this.attribs)l.call(r,t)&&(e=r[t],n.attribs[t]=e.clone());return n.children=[],this.children.forEach((function(e){var t;return(t=e.clone()).parent=n,n.children.push(t)})),n},n.prototype.attribute=function(e,t){var n,o;if(null!=e&&(e=s(e)),c(e))for(n in e)l.call(e,n)&&(o=e[n],this.attribute(n,o));else a(t)&&(t=t.apply()),this.options.keepNullAttributes&&null==t?this.attribs[e]=new r(this,e,""):null!=t&&(this.attribs[e]=new r(this,e,t));return this},n.prototype.removeAttribute=function(e){var t,n,r;if(null==e)throw new Error("Missing attribute name. "+this.debugInfo());if(e=s(e),Array.isArray(e))for(n=0,r=e.length;n<r;n++)t=e[n],delete this.attribs[t];else delete this.attribs[e];return this},n.prototype.toString=function(e){return this.options.writer.element(this,this.options.writer.filterOptions(e))},n.prototype.att=function(e,t){return this.attribute(e,t)},n.prototype.a=function(e,t){return this.attribute(e,t)},n.prototype.getAttribute=function(e){return this.attribs.hasOwnProperty(e)?this.attribs[e].value:null},n.prototype.setAttribute=function(e,t){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.getAttributeNode=function(e){return this.attribs.hasOwnProperty(e)?this.attribs[e]:null},n.prototype.setAttributeNode=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.removeAttributeNode=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.getElementsByTagName=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.getAttributeNS=function(e,t){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.setAttributeNS=function(e,t,n){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.removeAttributeNS=function(e,t){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.getAttributeNodeNS=function(e,t){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.setAttributeNodeNS=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.getElementsByTagNameNS=function(e,t){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.hasAttribute=function(e){return this.attribs.hasOwnProperty(e)},n.prototype.hasAttributeNS=function(e,t){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.setIdAttribute=function(e,t){return this.attribs.hasOwnProperty(e)?this.attribs[e].isId:t},n.prototype.setIdAttributeNS=function(e,t,n){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.setIdAttributeNode=function(e,t){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.getElementsByTagName=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.getElementsByTagNameNS=function(e,t){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.getElementsByClassName=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.isEqualNode=function(e){var t,r,o;if(!n.__super__.isEqualNode.apply(this,arguments).isEqualNode(e))return!1;if(e.namespaceURI!==this.namespaceURI)return!1;if(e.prefix!==this.prefix)return!1;if(e.localName!==this.localName)return!1;if(e.attribs.length!==this.attribs.length)return!1;for(t=r=0,o=this.attribs.length-1;0<=o?r<=o:r>=o;t=0<=o?++r:--r)if(!this.attribs[t].isEqualNode(e.attribs[t]))return!1;return!0},n}(i)}).call(this)},4797:function(e){(function(){e.exports=function(){function e(e){this.nodes=e}return Object.defineProperty(e.prototype,"length",{get:function(){return Object.keys(this.nodes).length||0}}),e.prototype.clone=function(){return this.nodes=null},e.prototype.getNamedItem=function(e){return this.nodes[e]},e.prototype.setNamedItem=function(e){var t;return t=this.nodes[e.nodeName],this.nodes[e.nodeName]=e,t||null},e.prototype.removeNamedItem=function(e){var t;return t=this.nodes[e],delete this.nodes[e],t||null},e.prototype.item=function(e){return this.nodes[Object.keys(this.nodes)[e]]||null},e.prototype.getNamedItemNS=function(e,t){throw new Error("This DOM method is not implemented.")},e.prototype.setNamedItemNS=function(e){throw new Error("This DOM method is not implemented.")},e.prototype.removeNamedItemNS=function(e,t){throw new Error("This DOM method is not implemented.")},e}()}).call(this)},468:function(e,t,n){(function(){var t,r,o,i,s,a,c,u,l,p,d,h,f,m,v,g,y,_={}.hasOwnProperty;y=n(9241),g=y.isObject,v=y.isFunction,m=y.isEmpty,f=y.getValue,u=null,o=null,i=null,s=null,a=null,d=null,h=null,p=null,c=null,r=null,l=null,t=null,e.exports=function(){function e(e){this.parent=e,this.parent&&(this.options=this.parent.options,this.stringify=this.parent.stringify),this.value=null,this.children=[],this.baseURI=null,u||(u=n(3906),o=n(2691),i=n(2679),s=n(4130),a=n(6376),d=n(1268),h=n(2535),p=n(5915),c=n(1218),r=n(1737),l=n(6684),n(4797),t=n(4923))}return Object.defineProperty(e.prototype,"nodeName",{get:function(){return this.name}}),Object.defineProperty(e.prototype,"nodeType",{get:function(){return this.type}}),Object.defineProperty(e.prototype,"nodeValue",{get:function(){return this.value}}),Object.defineProperty(e.prototype,"parentNode",{get:function(){return this.parent}}),Object.defineProperty(e.prototype,"childNodes",{get:function(){return this.childNodeList&&this.childNodeList.nodes||(this.childNodeList=new l(this.children)),this.childNodeList}}),Object.defineProperty(e.prototype,"firstChild",{get:function(){return this.children[0]||null}}),Object.defineProperty(e.prototype,"lastChild",{get:function(){return this.children[this.children.length-1]||null}}),Object.defineProperty(e.prototype,"previousSibling",{get:function(){var e;return e=this.parent.children.indexOf(this),this.parent.children[e-1]||null}}),Object.defineProperty(e.prototype,"nextSibling",{get:function(){var e;return e=this.parent.children.indexOf(this),this.parent.children[e+1]||null}}),Object.defineProperty(e.prototype,"ownerDocument",{get:function(){return this.document()||null}}),Object.defineProperty(e.prototype,"textContent",{get:function(){var e,t,n,o,i;if(this.nodeType===r.Element||this.nodeType===r.DocumentFragment){for(i="",t=0,n=(o=this.children).length;t<n;t++)(e=o[t]).textContent&&(i+=e.textContent);return i}return null},set:function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),e.prototype.setParent=function(e){var t,n,r,o,i;for(this.parent=e,e&&(this.options=e.options,this.stringify=e.stringify),i=[],n=0,r=(o=this.children).length;n<r;n++)t=o[n],i.push(t.setParent(this));return i},e.prototype.element=function(e,t,n){var r,o,i,s,a,c,u,l,p,d,h;if(c=null,null===t&&null==n&&(t=(p=[{},null])[0],n=p[1]),null==t&&(t={}),t=f(t),g(t)||(n=(d=[t,n])[0],t=d[1]),null!=e&&(e=f(e)),Array.isArray(e))for(i=0,u=e.length;i<u;i++)o=e[i],c=this.element(o);else if(v(e))c=this.element(e.apply());else if(g(e)){for(a in e)if(_.call(e,a))if(h=e[a],v(h)&&(h=h.apply()),!this.options.ignoreDecorators&&this.stringify.convertAttKey&&0===a.indexOf(this.stringify.convertAttKey))c=this.attribute(a.substr(this.stringify.convertAttKey.length),h);else if(!this.options.separateArrayItems&&Array.isArray(h)&&m(h))c=this.dummy();else if(g(h)&&m(h))c=this.element(a);else if(this.options.keepNullNodes||null!=h)if(!this.options.separateArrayItems&&Array.isArray(h))for(s=0,l=h.length;s<l;s++)o=h[s],(r={})[a]=o,c=this.element(r);else g(h)?!this.options.ignoreDecorators&&this.stringify.convertTextKey&&0===a.indexOf(this.stringify.convertTextKey)?c=this.element(h):(c=this.element(a)).element(h):c=this.element(a,h);else c=this.dummy()}else c=this.options.keepNullNodes||null!==n?!this.options.ignoreDecorators&&this.stringify.convertTextKey&&0===e.indexOf(this.stringify.convertTextKey)?this.text(n):!this.options.ignoreDecorators&&this.stringify.convertCDataKey&&0===e.indexOf(this.stringify.convertCDataKey)?this.cdata(n):!this.options.ignoreDecorators&&this.stringify.convertCommentKey&&0===e.indexOf(this.stringify.convertCommentKey)?this.comment(n):!this.options.ignoreDecorators&&this.stringify.convertRawKey&&0===e.indexOf(this.stringify.convertRawKey)?this.raw(n):!this.options.ignoreDecorators&&this.stringify.convertPIKey&&0===e.indexOf(this.stringify.convertPIKey)?this.instruction(e.substr(this.stringify.convertPIKey.length),n):this.node(e,t,n):this.dummy();if(null==c)throw new Error("Could not create any elements with: "+e+". "+this.debugInfo());return c},e.prototype.insertBefore=function(e,t,n){var r,o,i,s,a;if(null!=e?e.type:void 0)return s=t,(i=e).setParent(this),s?(o=children.indexOf(s),a=children.splice(o),children.push(i),Array.prototype.push.apply(children,a)):children.push(i),i;if(this.isRoot)throw new Error("Cannot insert elements at root level. "+this.debugInfo(e));return o=this.parent.children.indexOf(this),a=this.parent.children.splice(o),r=this.parent.element(e,t,n),Array.prototype.push.apply(this.parent.children,a),r},e.prototype.insertAfter=function(e,t,n){var r,o,i;if(this.isRoot)throw new Error("Cannot insert elements at root level. "+this.debugInfo(e));return o=this.parent.children.indexOf(this),i=this.parent.children.splice(o+1),r=this.parent.element(e,t,n),Array.prototype.push.apply(this.parent.children,i),r},e.prototype.remove=function(){var e;if(this.isRoot)throw new Error("Cannot remove the root element. "+this.debugInfo());return e=this.parent.children.indexOf(this),[].splice.apply(this.parent.children,[e,e-e+1].concat([])),this.parent},e.prototype.node=function(e,t,n){var r,o;return null!=e&&(e=f(e)),t||(t={}),t=f(t),g(t)||(n=(o=[t,n])[0],t=o[1]),r=new u(this,e,t),null!=n&&r.text(n),this.children.push(r),r},e.prototype.text=function(e){var t;return g(e)&&this.element(e),t=new h(this,e),this.children.push(t),this},e.prototype.cdata=function(e){var t;return t=new o(this,e),this.children.push(t),this},e.prototype.comment=function(e){var t;return t=new i(this,e),this.children.push(t),this},e.prototype.commentBefore=function(e){var t,n;return t=this.parent.children.indexOf(this),n=this.parent.children.splice(t),this.parent.comment(e),Array.prototype.push.apply(this.parent.children,n),this},e.prototype.commentAfter=function(e){var t,n;return t=this.parent.children.indexOf(this),n=this.parent.children.splice(t+1),this.parent.comment(e),Array.prototype.push.apply(this.parent.children,n),this},e.prototype.raw=function(e){var t;return t=new d(this,e),this.children.push(t),this},e.prototype.dummy=function(){return new c(this)},e.prototype.instruction=function(e,t){var n,r,o,i,s;if(null!=e&&(e=f(e)),null!=t&&(t=f(t)),Array.isArray(e))for(i=0,s=e.length;i<s;i++)n=e[i],this.instruction(n);else if(g(e))for(n in e)_.call(e,n)&&(r=e[n],this.instruction(n,r));else v(t)&&(t=t.apply()),o=new p(this,e,t),this.children.push(o);return this},e.prototype.instructionBefore=function(e,t){var n,r;return n=this.parent.children.indexOf(this),r=this.parent.children.splice(n),this.parent.instruction(e,t),Array.prototype.push.apply(this.parent.children,r),this},e.prototype.instructionAfter=function(e,t){var n,r;return n=this.parent.children.indexOf(this),r=this.parent.children.splice(n+1),this.parent.instruction(e,t),Array.prototype.push.apply(this.parent.children,r),this},e.prototype.declaration=function(e,t,n){var o,i;return o=this.document(),i=new s(o,e,t,n),0===o.children.length?o.children.unshift(i):o.children[0].type===r.Declaration?o.children[0]=i:o.children.unshift(i),o.root()||o},e.prototype.dtd=function(e,t){var n,o,i,s,c,u,l,p,d;for(n=this.document(),o=new a(n,e,t),i=s=0,u=(p=n.children).length;s<u;i=++s)if(p[i].type===r.DocType)return n.children[i]=o,o;for(i=c=0,l=(d=n.children).length;c<l;i=++c)if(d[i].isRoot)return n.children.splice(i,0,o),o;return n.children.push(o),o},e.prototype.up=function(){if(this.isRoot)throw new Error("The root node has no parent. Use doc() if you need to get the document object.");return this.parent},e.prototype.root=function(){var e;for(e=this;e;){if(e.type===r.Document)return e.rootObject;if(e.isRoot)return e;e=e.parent}},e.prototype.document=function(){var e;for(e=this;e;){if(e.type===r.Document)return e;e=e.parent}},e.prototype.end=function(e){return this.document().end(e)},e.prototype.prev=function(){var e;if((e=this.parent.children.indexOf(this))<1)throw new Error("Already at the first node. "+this.debugInfo());return this.parent.children[e-1]},e.prototype.next=function(){var e;if(-1===(e=this.parent.children.indexOf(this))||e===this.parent.children.length-1)throw new Error("Already at the last node. "+this.debugInfo());return this.parent.children[e+1]},e.prototype.importDocument=function(e){var t;return(t=e.root().clone()).parent=this,t.isRoot=!1,this.children.push(t),this},e.prototype.debugInfo=function(e){var t,n;return null!=(e=e||this.name)||(null!=(t=this.parent)?t.name:void 0)?null==e?"parent: <"+this.parent.name+">":(null!=(n=this.parent)?n.name:void 0)?"node: <"+e+">, parent: <"+this.parent.name+">":"node: <"+e+">":""},e.prototype.ele=function(e,t,n){return this.element(e,t,n)},e.prototype.nod=function(e,t,n){return this.node(e,t,n)},e.prototype.txt=function(e){return this.text(e)},e.prototype.dat=function(e){return this.cdata(e)},e.prototype.com=function(e){return this.comment(e)},e.prototype.ins=function(e,t){return this.instruction(e,t)},e.prototype.doc=function(){return this.document()},e.prototype.dec=function(e,t,n){return this.declaration(e,t,n)},e.prototype.e=function(e,t,n){return this.element(e,t,n)},e.prototype.n=function(e,t,n){return this.node(e,t,n)},e.prototype.t=function(e){return this.text(e)},e.prototype.d=function(e){return this.cdata(e)},e.prototype.c=function(e){return this.comment(e)},e.prototype.r=function(e){return this.raw(e)},e.prototype.i=function(e,t){return this.instruction(e,t)},e.prototype.u=function(){return this.up()},e.prototype.importXMLBuilder=function(e){return this.importDocument(e)},e.prototype.replaceChild=function(e,t){throw new Error("This DOM method is not implemented."+this.debugInfo())},e.prototype.removeChild=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},e.prototype.appendChild=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},e.prototype.hasChildNodes=function(){return 0!==this.children.length},e.prototype.cloneNode=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},e.prototype.normalize=function(){throw new Error("This DOM method is not implemented."+this.debugInfo())},e.prototype.isSupported=function(e,t){return!0},e.prototype.hasAttributes=function(){return 0!==this.attribs.length},e.prototype.compareDocumentPosition=function(e){var n,r;return(n=this)===e?0:this.document()!==e.document()?(r=t.Disconnected|t.ImplementationSpecific,Math.random()<.5?r|=t.Preceding:r|=t.Following,r):n.isAncestor(e)?t.Contains|t.Preceding:n.isDescendant(e)?t.Contains|t.Following:n.isPreceding(e)?t.Preceding:t.Following},e.prototype.isSameNode=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},e.prototype.lookupPrefix=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},e.prototype.isDefaultNamespace=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},e.prototype.lookupNamespaceURI=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},e.prototype.isEqualNode=function(e){var t,n,r;if(e.nodeType!==this.nodeType)return!1;if(e.children.length!==this.children.length)return!1;for(t=n=0,r=this.children.length-1;0<=r?n<=r:n>=r;t=0<=r?++n:--n)if(!this.children[t].isEqualNode(e.children[t]))return!1;return!0},e.prototype.getFeature=function(e,t){throw new Error("This DOM method is not implemented."+this.debugInfo())},e.prototype.setUserData=function(e,t,n){throw new Error("This DOM method is not implemented."+this.debugInfo())},e.prototype.getUserData=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},e.prototype.contains=function(e){return!!e&&(e===this||this.isDescendant(e))},e.prototype.isDescendant=function(e){var t,n,r,o;for(n=0,r=(o=this.children).length;n<r;n++){if(e===(t=o[n]))return!0;if(t.isDescendant(e))return!0}return!1},e.prototype.isAncestor=function(e){return e.isDescendant(this)},e.prototype.isPreceding=function(e){var t,n;return t=this.treePosition(e),n=this.treePosition(this),-1!==t&&-1!==n&&t<n},e.prototype.isFollowing=function(e){var t,n;return t=this.treePosition(e),n=this.treePosition(this),-1!==t&&-1!==n&&t>n},e.prototype.treePosition=function(e){var t,n;return n=0,t=!1,this.foreachTreeNode(this.document(),(function(r){if(n++,!t&&r===e)return t=!0})),t?n:-1},e.prototype.foreachTreeNode=function(e,t){var n,r,o,i,s;for(e||(e=this.document()),r=0,o=(i=e.children).length;r<o;r++){if(s=t(n=i[r]))return s;if(s=this.foreachTreeNode(n,t))return s}},e}()}).call(this)},6684:function(e){(function(){e.exports=function(){function e(e){this.nodes=e}return Object.defineProperty(e.prototype,"length",{get:function(){return this.nodes.length||0}}),e.prototype.clone=function(){return this.nodes=null},e.prototype.item=function(e){return this.nodes[e]||null},e}()}).call(this)},5915:function(e,t,n){(function(){var t,r,o={}.hasOwnProperty;t=n(1737),r=n(7457),e.exports=function(e){function n(e,r,o){if(n.__super__.constructor.call(this,e),null==r)throw new Error("Missing instruction target. "+this.debugInfo());this.type=t.ProcessingInstruction,this.target=this.stringify.insTarget(r),this.name=this.target,o&&(this.value=this.stringify.insValue(o))}return function(e,t){for(var n in t)o.call(t,n)&&(e[n]=t[n]);function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r,e.__super__=t.prototype}(n,e),n.prototype.clone=function(){return Object.create(this)},n.prototype.toString=function(e){return this.options.writer.processingInstruction(this,this.options.writer.filterOptions(e))},n.prototype.isEqualNode=function(e){return!!n.__super__.isEqualNode.apply(this,arguments).isEqualNode(e)&&e.target===this.target},n}(r)}).call(this)},1268:function(e,t,n){(function(){var t,r,o={}.hasOwnProperty;t=n(1737),r=n(468),e.exports=function(e){function n(e,r){if(n.__super__.constructor.call(this,e),null==r)throw new Error("Missing raw text. "+this.debugInfo());this.type=t.Raw,this.value=this.stringify.raw(r)}return function(e,t){for(var n in t)o.call(t,n)&&(e[n]=t[n]);function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r,e.__super__=t.prototype}(n,e),n.prototype.clone=function(){return Object.create(this)},n.prototype.toString=function(e){return this.options.writer.raw(this,this.options.writer.filterOptions(e))},n}(r)}).call(this)},6775:function(e,t,n){(function(){var t,r,o,i={}.hasOwnProperty;t=n(1737),o=n(6286),r=n(8753),e.exports=function(e){function n(e,t){this.stream=e,n.__super__.constructor.call(this,t)}return function(e,t){for(var n in t)i.call(t,n)&&(e[n]=t[n]);function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r,e.__super__=t.prototype}(n,e),n.prototype.endline=function(e,t,o){return e.isLastRootNode&&t.state===r.CloseTag?"":n.__super__.endline.call(this,e,t,o)},n.prototype.document=function(e,t){var n,r,o,i,s,a,c,u,l;for(r=o=0,s=(c=e.children).length;o<s;r=++o)(n=c[r]).isLastRootNode=r===e.children.length-1;for(t=this.filterOptions(t),l=[],i=0,a=(u=e.children).length;i<a;i++)n=u[i],l.push(this.writeChildNode(n,t,0));return l},n.prototype.attribute=function(e,t,r){return this.stream.write(n.__super__.attribute.call(this,e,t,r))},n.prototype.cdata=function(e,t,r){return this.stream.write(n.__super__.cdata.call(this,e,t,r))},n.prototype.comment=function(e,t,r){return this.stream.write(n.__super__.comment.call(this,e,t,r))},n.prototype.declaration=function(e,t,r){return this.stream.write(n.__super__.declaration.call(this,e,t,r))},n.prototype.docType=function(e,t,n){var o,i,s,a;if(n||(n=0),this.openNode(e,t,n),t.state=r.OpenTag,this.stream.write(this.indent(e,t,n)),this.stream.write("<!DOCTYPE "+e.root().name),e.pubID&&e.sysID?this.stream.write(' PUBLIC "'+e.pubID+'" "'+e.sysID+'"'):e.sysID&&this.stream.write(' SYSTEM "'+e.sysID+'"'),e.children.length>0){for(this.stream.write(" ["),this.stream.write(this.endline(e,t,n)),t.state=r.InsideTag,i=0,s=(a=e.children).length;i<s;i++)o=a[i],this.writeChildNode(o,t,n+1);t.state=r.CloseTag,this.stream.write("]")}return t.state=r.CloseTag,this.stream.write(t.spaceBeforeSlash+">"),this.stream.write(this.endline(e,t,n)),t.state=r.None,this.closeNode(e,t,n)},n.prototype.element=function(e,n,o){var s,a,c,u,l,p,d,h,f;for(d in o||(o=0),this.openNode(e,n,o),n.state=r.OpenTag,this.stream.write(this.indent(e,n,o)+"<"+e.name),h=e.attribs)i.call(h,d)&&(s=h[d],this.attribute(s,n,o));if(u=0===(c=e.children.length)?null:e.children[0],0===c||e.children.every((function(e){return(e.type===t.Text||e.type===t.Raw)&&""===e.value})))n.allowEmpty?(this.stream.write(">"),n.state=r.CloseTag,this.stream.write("</"+e.name+">")):(n.state=r.CloseTag,this.stream.write(n.spaceBeforeSlash+"/>"));else if(!n.pretty||1!==c||u.type!==t.Text&&u.type!==t.Raw||null==u.value){for(this.stream.write(">"+this.endline(e,n,o)),n.state=r.InsideTag,l=0,p=(f=e.children).length;l<p;l++)a=f[l],this.writeChildNode(a,n,o+1);n.state=r.CloseTag,this.stream.write(this.indent(e,n,o)+"</"+e.name+">")}else this.stream.write(">"),n.state=r.InsideTag,n.suppressPrettyCount++,this.writeChildNode(u,n,o+1),n.suppressPrettyCount--,n.state=r.CloseTag,this.stream.write("</"+e.name+">");return this.stream.write(this.endline(e,n,o)),n.state=r.None,this.closeNode(e,n,o)},n.prototype.processingInstruction=function(e,t,r){return this.stream.write(n.__super__.processingInstruction.call(this,e,t,r))},n.prototype.raw=function(e,t,r){return this.stream.write(n.__super__.raw.call(this,e,t,r))},n.prototype.text=function(e,t,r){return this.stream.write(n.__super__.text.call(this,e,t,r))},n.prototype.dtdAttList=function(e,t,r){return this.stream.write(n.__super__.dtdAttList.call(this,e,t,r))},n.prototype.dtdElement=function(e,t,r){return this.stream.write(n.__super__.dtdElement.call(this,e,t,r))},n.prototype.dtdEntity=function(e,t,r){return this.stream.write(n.__super__.dtdEntity.call(this,e,t,r))},n.prototype.dtdNotation=function(e,t,r){return this.stream.write(n.__super__.dtdNotation.call(this,e,t,r))},n}(o)}).call(this)},382:function(e,t,n){(function(){var t,r={}.hasOwnProperty;t=n(6286),e.exports=function(e){function t(e){t.__super__.constructor.call(this,e)}return function(e,t){for(var n in t)r.call(t,n)&&(e[n]=t[n]);function o(){this.constructor=e}o.prototype=t.prototype,e.prototype=new o,e.__super__=t.prototype}(t,e),t.prototype.document=function(e,t){var n,r,o,i,s;for(t=this.filterOptions(t),i="",r=0,o=(s=e.children).length;r<o;r++)n=s[r],i+=this.writeChildNode(n,t,0);return t.pretty&&i.slice(-t.newline.length)===t.newline&&(i=i.slice(0,-t.newline.length)),i},t}(t)}).call(this)},3976:function(e){(function(){var t=function(e,t){return function(){return e.apply(t,arguments)}},n={}.hasOwnProperty;e.exports=function(){function e(e){var r,o,i;for(r in this.assertLegalName=t(this.assertLegalName,this),this.assertLegalChar=t(this.assertLegalChar,this),e||(e={}),this.options=e,this.options.version||(this.options.version="1.0"),o=e.stringify||{})n.call(o,r)&&(i=o[r],this[r]=i)}return e.prototype.name=function(e){return this.options.noValidation?e:this.assertLegalName(""+e||"")},e.prototype.text=function(e){return this.options.noValidation?e:this.assertLegalChar(this.textEscape(""+e||""))},e.prototype.cdata=function(e){return this.options.noValidation?e:(e=(e=""+e||"").replace("]]>","]]]]><![CDATA[>"),this.assertLegalChar(e))},e.prototype.comment=function(e){if(this.options.noValidation)return e;if((e=""+e||"").match(/--/))throw new Error("Comment text cannot contain double-hypen: "+e);return this.assertLegalChar(e)},e.prototype.raw=function(e){return this.options.noValidation?e:""+e||""},e.prototype.attValue=function(e){return this.options.noValidation?e:this.assertLegalChar(this.attEscape(e=""+e||""))},e.prototype.insTarget=function(e){return this.options.noValidation?e:this.assertLegalChar(""+e||"")},e.prototype.insValue=function(e){if(this.options.noValidation)return e;if((e=""+e||"").match(/\?>/))throw new Error("Invalid processing instruction value: "+e);return this.assertLegalChar(e)},e.prototype.xmlVersion=function(e){if(this.options.noValidation)return e;if(!(e=""+e||"").match(/1\.[0-9]+/))throw new Error("Invalid version number: "+e);return e},e.prototype.xmlEncoding=function(e){if(this.options.noValidation)return e;if(!(e=""+e||"").match(/^[A-Za-z](?:[A-Za-z0-9._-])*$/))throw new Error("Invalid encoding: "+e);return this.assertLegalChar(e)},e.prototype.xmlStandalone=function(e){return this.options.noValidation?e:e?"yes":"no"},e.prototype.dtdPubID=function(e){return this.options.noValidation?e:this.assertLegalChar(""+e||"")},e.prototype.dtdSysID=function(e){return this.options.noValidation?e:this.assertLegalChar(""+e||"")},e.prototype.dtdElementValue=function(e){return this.options.noValidation?e:this.assertLegalChar(""+e||"")},e.prototype.dtdAttType=function(e){return this.options.noValidation?e:this.assertLegalChar(""+e||"")},e.prototype.dtdAttDefault=function(e){return this.options.noValidation?e:this.assertLegalChar(""+e||"")},e.prototype.dtdEntityValue=function(e){return this.options.noValidation?e:this.assertLegalChar(""+e||"")},e.prototype.dtdNData=function(e){return this.options.noValidation?e:this.assertLegalChar(""+e||"")},e.prototype.convertAttKey="@",e.prototype.convertPIKey="?",e.prototype.convertTextKey="#text",e.prototype.convertCDataKey="#cdata",e.prototype.convertCommentKey="#comment",e.prototype.convertRawKey="#raw",e.prototype.assertLegalChar=function(e){var t,n;if(this.options.noValidation)return e;if(t="","1.0"===this.options.version){if(t=/[\0-\x08\x0B\f\x0E-\x1F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,n=e.match(t))throw new Error("Invalid character in string: "+e+" at index "+n.index)}else if("1.1"===this.options.version&&(t=/[\0\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,n=e.match(t)))throw new Error("Invalid character in string: "+e+" at index "+n.index);return e},e.prototype.assertLegalName=function(e){var t;if(this.options.noValidation)return e;if(this.assertLegalChar(e),t=/^([:A-Z_a-z\xC0-\xD6\xD8-\xF6\xF8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])([\x2D\.0-:A-Z_a-z\xB7\xC0-\xD6\xD8-\xF6\xF8-\u037D\u037F-\u1FFF\u200C\u200D\u203F\u2040\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])*$/,!e.match(t))throw new Error("Invalid character in name");return e},e.prototype.textEscape=function(e){var t;return this.options.noValidation?e:(t=this.options.noDoubleEncoding?/(?!&\S+;)&/g:/&/g,e.replace(t,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/\r/g,"&#xD;"))},e.prototype.attEscape=function(e){var t;return this.options.noValidation?e:(t=this.options.noDoubleEncoding?/(?!&\S+;)&/g:/&/g,e.replace(t,"&amp;").replace(/</g,"&lt;").replace(/"/g,"&quot;").replace(/\t/g,"&#x9;").replace(/\n/g,"&#xA;").replace(/\r/g,"&#xD;"))},e}()}).call(this)},2535:function(e,t,n){(function(){var t,r,o={}.hasOwnProperty;t=n(1737),r=n(7457),e.exports=function(e){function n(e,r){if(n.__super__.constructor.call(this,e),null==r)throw new Error("Missing element text. "+this.debugInfo());this.name="#text",this.type=t.Text,this.value=this.stringify.text(r)}return function(e,t){for(var n in t)o.call(t,n)&&(e[n]=t[n]);function r(){this.constructor=e}r.prototype=t.prototype,e.prototype=new r,e.__super__=t.prototype}(n,e),Object.defineProperty(n.prototype,"isElementContentWhitespace",{get:function(){throw new Error("This DOM method is not implemented."+this.debugInfo())}}),Object.defineProperty(n.prototype,"wholeText",{get:function(){var e,t,n;for(n="",t=this.previousSibling;t;)n=t.data+n,t=t.previousSibling;for(n+=this.data,e=this.nextSibling;e;)n+=e.data,e=e.nextSibling;return n}}),n.prototype.clone=function(){return Object.create(this)},n.prototype.toString=function(e){return this.options.writer.text(this,this.options.writer.filterOptions(e))},n.prototype.splitText=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},n.prototype.replaceWholeText=function(e){throw new Error("This DOM method is not implemented."+this.debugInfo())},n}(r)}).call(this)},6286:function(e,t,n){(function(){var t,r,o,i={}.hasOwnProperty;o=n(9241).assign,t=n(1737),n(4130),n(6376),n(2691),n(2679),n(3906),n(1268),n(2535),n(5915),n(1218),n(4111),n(7696),n(5529),n(5631),r=n(8753),e.exports=function(){function e(e){var t,n,r;for(t in e||(e={}),this.options=e,n=e.writer||{})i.call(n,t)&&(r=n[t],this["_"+t]=this[t],this[t]=r)}return e.prototype.filterOptions=function(e){var t,n,i,s,a,c,u,l;return e||(e={}),e=o({},this.options,e),(t={writer:this}).pretty=e.pretty||!1,t.allowEmpty=e.allowEmpty||!1,t.indent=null!=(n=e.indent)?n:"  ",t.newline=null!=(i=e.newline)?i:"\n",t.offset=null!=(s=e.offset)?s:0,t.dontPrettyTextNodes=null!=(a=null!=(c=e.dontPrettyTextNodes)?c:e.dontprettytextnodes)?a:0,t.spaceBeforeSlash=null!=(u=null!=(l=e.spaceBeforeSlash)?l:e.spacebeforeslash)?u:"",!0===t.spaceBeforeSlash&&(t.spaceBeforeSlash=" "),t.suppressPrettyCount=0,t.user={},t.state=r.None,t},e.prototype.indent=function(e,t,n){var r;return!t.pretty||t.suppressPrettyCount?"":t.pretty&&(r=(n||0)+t.offset+1)>0?new Array(r).join(t.indent):""},e.prototype.endline=function(e,t,n){return!t.pretty||t.suppressPrettyCount?"":t.newline},e.prototype.attribute=function(e,t,n){var r;return this.openAttribute(e,t,n),r=" "+e.name+'="'+e.value+'"',this.closeAttribute(e,t,n),r},e.prototype.cdata=function(e,t,n){var o;return this.openNode(e,t,n),t.state=r.OpenTag,o=this.indent(e,t,n)+"<![CDATA[",t.state=r.InsideTag,o+=e.value,t.state=r.CloseTag,o+="]]>"+this.endline(e,t,n),t.state=r.None,this.closeNode(e,t,n),o},e.prototype.comment=function(e,t,n){var o;return this.openNode(e,t,n),t.state=r.OpenTag,o=this.indent(e,t,n)+"\x3c!-- ",t.state=r.InsideTag,o+=e.value,t.state=r.CloseTag,o+=" --\x3e"+this.endline(e,t,n),t.state=r.None,this.closeNode(e,t,n),o},e.prototype.declaration=function(e,t,n){var o;return this.openNode(e,t,n),t.state=r.OpenTag,o=this.indent(e,t,n)+"<?xml",t.state=r.InsideTag,o+=' version="'+e.version+'"',null!=e.encoding&&(o+=' encoding="'+e.encoding+'"'),null!=e.standalone&&(o+=' standalone="'+e.standalone+'"'),t.state=r.CloseTag,o+=t.spaceBeforeSlash+"?>",o+=this.endline(e,t,n),t.state=r.None,this.closeNode(e,t,n),o},e.prototype.docType=function(e,t,n){var o,i,s,a,c;if(n||(n=0),this.openNode(e,t,n),t.state=r.OpenTag,a=this.indent(e,t,n),a+="<!DOCTYPE "+e.root().name,e.pubID&&e.sysID?a+=' PUBLIC "'+e.pubID+'" "'+e.sysID+'"':e.sysID&&(a+=' SYSTEM "'+e.sysID+'"'),e.children.length>0){for(a+=" [",a+=this.endline(e,t,n),t.state=r.InsideTag,i=0,s=(c=e.children).length;i<s;i++)o=c[i],a+=this.writeChildNode(o,t,n+1);t.state=r.CloseTag,a+="]"}return t.state=r.CloseTag,a+=t.spaceBeforeSlash+">",a+=this.endline(e,t,n),t.state=r.None,this.closeNode(e,t,n),a},e.prototype.element=function(e,n,o){var s,a,c,u,l,p,d,h,f,m,v,g,y,_;for(f in o||(o=0),m=!1,v="",this.openNode(e,n,o),n.state=r.OpenTag,v+=this.indent(e,n,o)+"<"+e.name,g=e.attribs)i.call(g,f)&&(s=g[f],v+=this.attribute(s,n,o));if(u=0===(c=e.children.length)?null:e.children[0],0===c||e.children.every((function(e){return(e.type===t.Text||e.type===t.Raw)&&""===e.value})))n.allowEmpty?(v+=">",n.state=r.CloseTag,v+="</"+e.name+">"+this.endline(e,n,o)):(n.state=r.CloseTag,v+=n.spaceBeforeSlash+"/>"+this.endline(e,n,o));else if(!n.pretty||1!==c||u.type!==t.Text&&u.type!==t.Raw||null==u.value){if(n.dontPrettyTextNodes)for(l=0,d=(y=e.children).length;l<d;l++)if(((a=y[l]).type===t.Text||a.type===t.Raw)&&null!=a.value){n.suppressPrettyCount++,m=!0;break}for(v+=">"+this.endline(e,n,o),n.state=r.InsideTag,p=0,h=(_=e.children).length;p<h;p++)a=_[p],v+=this.writeChildNode(a,n,o+1);n.state=r.CloseTag,v+=this.indent(e,n,o)+"</"+e.name+">",m&&n.suppressPrettyCount--,v+=this.endline(e,n,o),n.state=r.None}else v+=">",n.state=r.InsideTag,n.suppressPrettyCount++,m=!0,v+=this.writeChildNode(u,n,o+1),n.suppressPrettyCount--,m=!1,n.state=r.CloseTag,v+="</"+e.name+">"+this.endline(e,n,o);return this.closeNode(e,n,o),v},e.prototype.writeChildNode=function(e,n,r){switch(e.type){case t.CData:return this.cdata(e,n,r);case t.Comment:return this.comment(e,n,r);case t.Element:return this.element(e,n,r);case t.Raw:return this.raw(e,n,r);case t.Text:return this.text(e,n,r);case t.ProcessingInstruction:return this.processingInstruction(e,n,r);case t.Dummy:return"";case t.Declaration:return this.declaration(e,n,r);case t.DocType:return this.docType(e,n,r);case t.AttributeDeclaration:return this.dtdAttList(e,n,r);case t.ElementDeclaration:return this.dtdElement(e,n,r);case t.EntityDeclaration:return this.dtdEntity(e,n,r);case t.NotationDeclaration:return this.dtdNotation(e,n,r);default:throw new Error("Unknown XML node type: "+e.constructor.name)}},e.prototype.processingInstruction=function(e,t,n){var o;return this.openNode(e,t,n),t.state=r.OpenTag,o=this.indent(e,t,n)+"<?",t.state=r.InsideTag,o+=e.target,e.value&&(o+=" "+e.value),t.state=r.CloseTag,o+=t.spaceBeforeSlash+"?>",o+=this.endline(e,t,n),t.state=r.None,this.closeNode(e,t,n),o},e.prototype.raw=function(e,t,n){var o;return this.openNode(e,t,n),t.state=r.OpenTag,o=this.indent(e,t,n),t.state=r.InsideTag,o+=e.value,t.state=r.CloseTag,o+=this.endline(e,t,n),t.state=r.None,this.closeNode(e,t,n),o},e.prototype.text=function(e,t,n){var o;return this.openNode(e,t,n),t.state=r.OpenTag,o=this.indent(e,t,n),t.state=r.InsideTag,o+=e.value,t.state=r.CloseTag,o+=this.endline(e,t,n),t.state=r.None,this.closeNode(e,t,n),o},e.prototype.dtdAttList=function(e,t,n){var o;return this.openNode(e,t,n),t.state=r.OpenTag,o=this.indent(e,t,n)+"<!ATTLIST",t.state=r.InsideTag,o+=" "+e.elementName+" "+e.attributeName+" "+e.attributeType,"#DEFAULT"!==e.defaultValueType&&(o+=" "+e.defaultValueType),e.defaultValue&&(o+=' "'+e.defaultValue+'"'),t.state=r.CloseTag,o+=t.spaceBeforeSlash+">"+this.endline(e,t,n),t.state=r.None,this.closeNode(e,t,n),o},e.prototype.dtdElement=function(e,t,n){var o;return this.openNode(e,t,n),t.state=r.OpenTag,o=this.indent(e,t,n)+"<!ELEMENT",t.state=r.InsideTag,o+=" "+e.name+" "+e.value,t.state=r.CloseTag,o+=t.spaceBeforeSlash+">"+this.endline(e,t,n),t.state=r.None,this.closeNode(e,t,n),o},e.prototype.dtdEntity=function(e,t,n){var o;return this.openNode(e,t,n),t.state=r.OpenTag,o=this.indent(e,t,n)+"<!ENTITY",t.state=r.InsideTag,e.pe&&(o+=" %"),o+=" "+e.name,e.value?o+=' "'+e.value+'"':(e.pubID&&e.sysID?o+=' PUBLIC "'+e.pubID+'" "'+e.sysID+'"':e.sysID&&(o+=' SYSTEM "'+e.sysID+'"'),e.nData&&(o+=" NDATA "+e.nData)),t.state=r.CloseTag,o+=t.spaceBeforeSlash+">"+this.endline(e,t,n),t.state=r.None,this.closeNode(e,t,n),o},e.prototype.dtdNotation=function(e,t,n){var o;return this.openNode(e,t,n),t.state=r.OpenTag,o=this.indent(e,t,n)+"<!NOTATION",t.state=r.InsideTag,o+=" "+e.name,e.pubID&&e.sysID?o+=' PUBLIC "'+e.pubID+'" "'+e.sysID+'"':e.pubID?o+=' PUBLIC "'+e.pubID+'"':e.sysID&&(o+=' SYSTEM "'+e.sysID+'"'),t.state=r.CloseTag,o+=t.spaceBeforeSlash+">"+this.endline(e,t,n),t.state=r.None,this.closeNode(e,t,n),o},e.prototype.openNode=function(e,t,n){},e.prototype.closeNode=function(e,t,n){},e.prototype.openAttribute=function(e,t,n){},e.prototype.closeAttribute=function(e,t,n){},e}()}).call(this)},9665:function(e,t,n){(function(){var t,r,o,i,s,a,c,u,l,p;p=n(9241),u=p.assign,l=p.isFunction,o=n(7260),i=n(1933),s=n(400),c=n(382),a=n(6775),t=n(1737),r=n(8753),e.exports.create=function(e,t,n,r){var o,s;if(null==e)throw new Error("Root element needs a name.");return r=u({},t,n,r),s=(o=new i(r)).element(e),r.headless||(o.declaration(r),null==r.pubID&&null==r.sysID||o.dtd(r)),s},e.exports.begin=function(e,t,n){var r;return l(e)&&(t=(r=[e,t])[0],n=r[1],e={}),t?new s(e,t,n):new i(e)},e.exports.stringWriter=function(e){return new c(e)},e.exports.streamWriter=function(e,t){return new a(e,t)},e.exports.implementation=new o,e.exports.nodeType=t,e.exports.writerState=r}).call(this)},1318:(e,t,n)=>{"use strict";n.r(t),n.d(t,{AppInsightsCore:()=>ae,BaseCore:()=>le,BaseTelemetryPlugin:()=>Se.s,CoreUtils:()=>re,DiagnosticLogger:()=>m.wq,ESPromise:()=>fe,ESPromiseScheduler:()=>be,EventHelper:()=>C.fs,EventLatency:()=>u,EventPersistence:()=>p,EventPropertyType:()=>l,EventsDiscardedReason:()=>we.x,FullVersionString:()=>P,InternalAppInsightsCore:()=>y._,InternalBaseCore:()=>ce.F,LoggingSeverity:()=>a.b,MinChannelPriorty:()=>xe.T,NotificationManager:()=>Te.h,PerfEvent:()=>v.Q6,PerfManager:()=>v.NS,ProcessTelemetryContext:()=>Ce.W0,TraceLevel:()=>d,Undefined:()=>x.bA,Utils:()=>ne,ValueKind:()=>c,ValueSanitizer:()=>Ee,Version:()=>R,_ExtendedInternalMessageId:()=>h,_InternalLogMessage:()=>m.WD,_InternalMessageId:()=>a.$,__getRegisteredEvents:()=>w.El,_logInternalMessage:()=>m.Oc,_throwInternal:()=>m.ZP,_warnToConsole:()=>m.OG,addEventHandler:()=>w.So,addEventListeners:()=>w.lQ,addPageHideEventListener:()=>w.Fc,addPageShowEventListener:()=>w.oS,addPageUnloadEventListener:()=>w.ee,areCookiesSupported:()=>S.gi,arrForEach:()=>s.Iu,arrIndexOf:()=>s.rD,arrMap:()=>s.W$,arrReduce:()=>s.KT,attachEvent:()=>w.Q3,cookieAvailable:()=>S.gi,createCookieMgr:()=>S.xN,createEnumStyle:()=>i.Hj,createGuid:()=>Q,createProcessTelemetryContext:()=>Ce.i8,createTraceParent:()=>Re.wk,createUniqueNamespace:()=>Ae.Z,createUnloadHandlerContainer:()=>Ie.P,dateNow:()=>s.x3,deleteCookie:()=>$,detachEvent:()=>w.Ym,disableCookies:()=>G,disallowsSameSiteNone:()=>S.It,doPerf:()=>v.r2,dumpObj:()=>g.mm,eventOff:()=>w.ML,eventOn:()=>w.mB,extend:()=>Y,findW3cTraceParent:()=>Re.ef,formatTraceParent:()=>Re.L0,generateW3CId:()=>C.cL,getCommonSchemaMetaData:()=>H,getConsole:()=>g.U5,getCookie:()=>K,getCookieValue:()=>W,getCrypto:()=>g.MY,getDocument:()=>g.YE,getExceptionName:()=>s.lL,getFieldValueType:()=>te,getGlobal:()=>I.mS,getGlobalInst:()=>g.EH,getHistory:()=>g.JK,getIEVersion:()=>g.L0,getISOString:()=>s._u,getJSON:()=>g.hm,getLocation:()=>g.g$,getMsCrypto:()=>g.iN,getNavigator:()=>g.w3,getPerformance:()=>g.FJ,getSetValue:()=>s.c2,getTenantId:()=>F,getTime:()=>X,getWindow:()=>g.zk,hasDocument:()=>g.Wt,hasHistory:()=>g.tw,hasJSON:()=>g.Z,hasNavigator:()=>g.w9,hasOwnProperty:()=>s.mQ,hasWindow:()=>g.Vd,isArray:()=>s.cy,isArrayValid:()=>Z,isBeaconsSupported:()=>g.Uf,isBoolean:()=>s.Lm,isChromium:()=>oe,isDate:()=>s.$P,isDocumentObjectAvailable:()=>L,isError:()=>s.bJ,isFetchSupported:()=>g.R7,isFunction:()=>s.Tn,isIE:()=>g.lT,isLatency:()=>q,isNotTruthy:()=>s.wo,isNullOrUndefined:()=>s.hX,isNumber:()=>s.Et,isObject:()=>s.Gv,isReactNative:()=>g.lV,isSampledFlag:()=>Re.N7,isString:()=>s.Kg,isTruthy:()=>s.zz,isTypeof:()=>s.Ed,isUint8ArrayAvailable:()=>z,isUndefined:()=>s.b0,isValidSpanId:()=>Re.wN,isValidTraceId:()=>Re.hX,isValidTraceParent:()=>Re.mJ,isValueAssigned:()=>U,isValueKind:()=>J,isWindowObjectAvailable:()=>j,isXhrSupported:()=>g.xk,mergeEvtNamespace:()=>w.Hm,newGuid:()=>C.aq,newId:()=>A.Si,normalizeJsName:()=>s.cH,objCreate:()=>I.AQ,objDefineAccessors:()=>s.r,objForEachKey:()=>s.z,objFreeze:()=>s.N6,objKeys:()=>s.cG,objSeal:()=>s.js,openXhr:()=>ie,optimizeObject:()=>s.hW,parseTraceParent:()=>Re.ZI,perfNow:()=>C.UU,proxyAssign:()=>s.qz,proxyFunctionAs:()=>s.RF,proxyFunctions:()=>s.o$,random32:()=>A.VN,randomValue:()=>A.Z1,removeEventHandler:()=>w.zh,removeEventListeners:()=>w.Wg,removePageHideEventListener:()=>w.sq,removePageShowEventListener:()=>w.vF,removePageUnloadEventListener:()=>w.Ds,safeGetCookieMgr:()=>S.um,safeGetLogger:()=>m.y0,sanitizeProperty:()=>B,setCookie:()=>V,setEnableEnvMocks:()=>g.cU,setProcessTelemetryTimings:()=>ee,setValue:()=>s.KY,strContains:()=>s.Ju,strEndsWith:()=>s.Cv,strFunction:()=>x.hW,strObject:()=>x._1,strPrototype:()=>x.vR,strStartsWith:()=>s.tG,strTrim:()=>s.EH,strUndefined:()=>x.bA,throwError:()=>s.$8,toISOString:()=>s._u,useXDomainRequest:()=>g.PV});var r,o=n(212),i=n(3435),s=n(2504),a=n(6166),c=(0,i.Hj)({NotSet:0,Pii_DistinguishedName:1,Pii_GenericData:2,Pii_IPV4Address:3,Pii_IPv6Address:4,Pii_MailSubject:5,Pii_PhoneNumber:6,Pii_QueryString:7,Pii_SipAddress:8,Pii_SmtpAddress:9,Pii_Identity:10,Pii_Uri:11,Pii_Fqdn:12,Pii_IPV4AddressLegacy:13,CustomerContent_GenericContent:32}),u=(0,i.Hj)({Normal:1,CostDeferred:2,RealTime:3,Immediate:4}),l=(0,i.Hj)({Unspecified:0,String:1,Int32:2,UInt32:3,Int64:4,UInt64:5,Double:6,Bool:7,Guid:8,DateTime:9}),p=(0,i.Hj)({Normal:1,Critical:2}),d=(0,i.Hj)({NONE:0,ERROR:1,WARNING:2,INFORMATION:3}),h=(0,s.N6)((0,o.Im)((0,o.Im)({},a.$),(0,i.Hj)({AuthHandShakeError:501,AuthRedirectFail:502,BrowserCannotReadLocalStorage:503,BrowserCannotWriteLocalStorage:504,BrowserDoesNotSupportLocalStorage:505,CannotParseBiBlobValue:506,CannotParseDataAttribute:507,CVPluginNotAvailable:508,DroppedEvent:509,ErrorParsingAISessionCookie:510,ErrorProvidedChannels:511,FailedToGetCookies:512,FailedToInitializeCorrelationVector:513,FailedToInitializeSDK:514,InvalidContentBlob:515,InvalidCorrelationValue:516,SessionRenewalDateIsZero:517,SendPostOnCompleteFailure:518,PostResponseHandler:519,SDKNotInitialized:520}))),f=n(1356),m=n(6392),v=n(5441),g=n(8323),y=n(6382),_="",b="https://browser.events.data.microsoft.com/OneCollector/1.0/",E="version",T="properties",S=n(5691),C=n(5955),x=n(7245),w=n(4838),A=n(9668),I=n(9381),R="3.2.13",P="1DS-Web-JS-"+R,O="Microsoft_ApplicationInsights_BypassAjaxInstrumentation",N="withCredentials",k="timeout",D=((r={})[0]=0,r[2]=6,r[1]=1,r[3]=7,r[4098]=6,r[4097]=1,r[4099]=7,r),M=null,L=Boolean((0,g.YE)()),j=Boolean((0,g.zk)());function U(e){return!(e===_||(0,s.hX)(e))}function F(e){if(e){var t=e.indexOf("-");if(t>-1)return e.substring(0,t)}return _}function z(){return null===M&&(M=!(0,s.b0)(Uint8Array)&&!function(){var e=(0,g.w3)();if(!(0,s.b0)(e)&&e.userAgent){var t=e.userAgent.toLowerCase();if((t.indexOf("safari")>=0||t.indexOf("firefox")>=0)&&t.indexOf("chrome")<0)return!0}return!1}()&&!(0,g.lV)()),M}function q(e){return!!(e&&(0,s.Et)(e)&&e>=1&&e<=4)}function B(e,t,n){if(!t&&!U(t)||"string"!=typeof e)return null;var r=typeof t;if("string"===r||"number"===r||"boolean"===r||(0,s.cy)(t))t={value:t};else if("object"!==r||x.J$.call(t,"value")){if((0,s.hX)(t.value)||t.value===_||!(0,s.Kg)(t.value)&&!(0,s.Et)(t.value)&&!(0,s.Lm)(t.value)&&!(0,s.cy)(t.value))return null}else t={value:n?JSON.stringify(t):t};if((0,s.cy)(t.value)&&!Z(t.value))return null;if(!(0,s.hX)(t.kind)){if((0,s.cy)(t.value)||!J(t.kind))return null;t.value=t.value.toString()}return t}function H(e,t,n){var r=-1;if(!(0,s.b0)(e))if(t>0&&(32===t?r=8192:t<=13&&(r=t<<5)),function(e){return e>=0&&e<=9}(n))-1===r&&(r=0),r|=n;else{var o=D[te(e)]||-1;-1!==r&&-1!==o?r|=o:6===o&&(r=o)}return r}function G(){(0,S.um)(null).setEnabled(!1)}function V(e,t,n){(0,S.gi)(null)&&(0,S.um)(null).set(e,t,86400*n,null,"/")}function $(e){(0,S.gi)(null)&&(0,S.um)(null).del(e)}function K(e){return(0,S.gi)(null)?W((0,S.um)(null),e):_}function W(e,t,n){var r;return void 0===n&&(n=!0),e&&(r=e.get(t),n&&r&&decodeURIComponent&&(r=decodeURIComponent(r))),r||_}function Q(e){void 0===e&&(e="D");var t=(0,C.aq)();return"B"===e?t="{"+t+"}":"P"===e?t="("+t+")":"N"===e&&(t=t.replace(/-/g,_)),t}function Y(e,t,n,r,o){var i={},a=!1,c=0,u=arguments.length,l=arguments;for("[object Boolean]"===Object[x.vR].toString.call(l[0])&&(a=l[0],c++);c<u;c++)e=l[c],(0,s.z)(e,(function(e,t){a&&t&&(0,s.Gv)(t)?(0,s.cy)(t)?(i[e]=i[e]||[],(0,s.Iu)(t,(function(t,n){t&&(0,s.Gv)(t)?i[e][n]=Y(!0,i[e][n],t):i[e][n]=t}))):i[e]=Y(!0,i[e],t):i[e]=t}));return i}var X=C.UU;function J(e){return 0===e||e>0&&e<=13||32===e}function Z(e){return e.length>0}function ee(e,t){var n=e;n.timings=n.timings||{},n.timings.processTelemetryStart=n.timings.processTelemetryStart||{},n.timings.processTelemetryStart[t]=X()}function te(e){var t=0;if(null!=e){var n=typeof e;"string"===n?t=1:"number"===n?t=2:"boolean"===n?t=3:n===x._1&&(t=4,(0,s.cy)(e)?(t=4096,e.length>0&&(t|=te(e[0]))):x.J$.call(e,"value")&&(t=8192|te(e.value)))}return t}var ne={Version:R,FullVersionString:P,strUndefined:x.bA,strObject:x._1,Undefined:x.bA,arrForEach:s.Iu,arrIndexOf:s.rD,arrMap:s.W$,arrReduce:s.KT,objKeys:s.cG,toISOString:s._u,isReactNative:g.lV,isString:s.Kg,isNumber:s.Et,isBoolean:s.Lm,isFunction:s.Tn,isArray:s.cy,isObject:s.Gv,strTrim:s.EH,isDocumentObjectAvailable:L,isWindowObjectAvailable:j,isValueAssigned:U,getTenantId:F,isBeaconsSupported:g.Uf,isUint8ArrayAvailable:z,isLatency:q,sanitizeProperty:B,getISOString:s._u,useXDomainRequest:g.PV,getCommonSchemaMetaData:H,cookieAvailable:S.gi,disallowsSameSiteNone:S.It,setCookie:V,deleteCookie:$,getCookie:K,createGuid:Q,extend:Y,getTime:X,isValueKind:J,isArrayValid:Z,objDefineAccessors:s.r,addPageUnloadEventListener:w.ee,setProcessTelemetryTimings:ee,addEventHandler:w.So,getFieldValueType:te,strEndsWith:s.Cv,objForEachKey:s.z},re={_canUseCookies:void 0,isTypeof:s.Ed,isUndefined:s.b0,isNullOrUndefined:s.hX,hasOwnProperty:s.mQ,isFunction:s.Tn,isObject:s.Gv,isDate:s.$P,isArray:s.cy,isError:s.bJ,isString:s.Kg,isNumber:s.Et,isBoolean:s.Lm,toISOString:s._u,arrForEach:s.Iu,arrIndexOf:s.rD,arrMap:s.W$,arrReduce:s.KT,strTrim:s.EH,objCreate:I.AQ,objKeys:s.cG,objDefineAccessors:s.r,addEventHandler:w.So,dateNow:s.x3,isIE:g.lT,disableCookies:G,newGuid:C.aq,perfNow:C.UU,newId:A.Si,randomValue:A.Z1,random32:A.VN,mwcRandomSeed:A.yc,mwcRandom32:A.k5,generateW3CId:C.cL};function oe(){return!!(0,g.EH)("chrome")}function ie(e,t,n,r,o,i){function s(e,t,n){try{e[t]=n}catch(e){}}void 0===r&&(r=!1),void 0===o&&(o=!1);var a=new XMLHttpRequest;return r&&s(a,O,r),n&&s(a,N,n),a.open(e,t,!o),n&&s(a,N,n),!o&&i&&s(a,k,i),a}var se=function(e){function t(){var n=e.call(this)||this;return n.pluginVersionStringArr=[],(0,f.default)(t,n,(function(e,t){e.logger&&e.logger.queue||(e.logger=new m.wq({loggingLevelConsole:1})),e.initialize=function(n,r,o,i){(0,v.r2)(e,(function(){return"AppInsightsCore.initialize"}),(function(){var a=e.pluginVersionStringArr;if(n){n.endpointUrl||(n.endpointUrl=b);var c=n.propertyStorageOverride;!c||c.getProperty&&c.setProperty||(0,s.$8)("Invalid property storage override passed."),n.channels&&(0,s.Iu)(n.channels,(function(e){e&&(0,s.Iu)(e,(function(e){if(e.identifier&&e.version){var t=e.identifier+"="+e.version;a.push(t)}}))}))}e.getWParam=function(){return"undefined"!=typeof document||n.enableWParam?0:-1},r&&(0,s.Iu)(r,(function(e){if(e&&e.identifier&&e.version){var t=e.identifier+"="+e.version;a.push(t)}})),e.pluginVersionString=a.join(";"),e.pluginVersionStringArr=a;try{t.initialize(n,r,o,i),e.pollInternalLogs("InternalLog")}catch(t){var u=e.logger,l=(0,g.mm)(t);-1!==l.indexOf("channels")&&(l+="\n - Channels must be provided through config.channels only!"),(0,m.ZP)(u,1,514,"SDK Initialization Failed - no telemetry will be sent: "+l)}}),(function(){return{config:n,extensions:r,logger:o,notificationManager:i}}))},e.track=function(n){(0,v.r2)(e,(function(){return"AppInsightsCore.track"}),(function(){var r=n;if(r){r.timings=r.timings||{},r.timings.trackStart=X(),q(r.latency)||(r.latency=1);var o=r.ext=r.ext||{};o.sdk=o.sdk||{},o.sdk.ver=P;var i=r.baseData=r.baseData||{};i[T]=i[T]||{};var s=i[T];s[E]=s[E]||e.pluginVersionString||_}t.track(r)}),(function(){return{item:n}}),!n.sync)}})),n}return(0,o.qU)(t,e),t.__ieDyn=1,t}(y._);const ae=se;var ce=n(3227),ue=function(e){function t(){var n=e.call(this)||this;return(0,f.default)(t,n,(function(e,t){e.initialize=function(n,r,o,i){n&&!n.endpointUrl&&(n.endpointUrl=b),e.getWParam=function(){return L||n.enableWParam?0:-1};try{t.initialize(n,r,o,i)}catch(t){(0,m.ZP)(e.logger,1,514,"Initialization Failed: "+(0,g.mm)(t)+"\n - Note: Channels must be provided through config.channels only")}},e.track=function(e){var n=e;if(n){var r=n.ext=n.ext||{};r.sdk=r.sdk||{},r.sdk.ver=P}t.track(n)}})),n}return(0,o.qU)(t,e),t.__ieDyn=1,t}(ce.F);const le=ue;var pe=s.Tn;function de(e,t,n){return function(r){e[t]=r,n()}}var he=function(){function e(t){var n=0,r=null,o=[];function i(){if(o.length>0){var e=o.slice();o=[],setTimeout((function(){for(var t=0,n=e.length;t<n;++t)try{e[t]()}catch(e){}}),0)}}function s(e){0===n&&(r=e,n=1,i())}function a(e){0===n&&(r=e,n=2,i())}(0,f.default)(e,this,(function(t){t.then=function(t,s){return new e((function(a,c){!function(t,s,a,c){o.push((function(){var o;try{(o=1===n?pe(t)?t(r):r:pe(s)?s(r):r)instanceof e?o.then(a,c):2!==n||pe(s)?a(o):c(o)}catch(e){return void c(e)}})),0!==n&&i()}(t,s,a,c)}))},t.catch=function(e){return t.then(null,e)}})),function(){if(!pe(t))throw new TypeError("ESPromise: resolvedFunc argument is not a Function");try{t(s,a)}catch(e){a(e)}}()}return e.resolve=function(t){return t instanceof e?t:t&&pe(t.then)?new e((function(e,n){try{t.then(e,n)}catch(e){n(e)}})):new e((function(e){e(t)}))},e.reject=function(t){return new e((function(e,n){n(t)}))},e.all=function(t){if(t&&t.length)return new e((function(e,n){try{for(var r=[],o=0,i=0;i<t.length;i++){var s=t[i];s&&pe(s.then)?(o++,s.then(de(r,i,(function(){0==--o&&e(r)})),n)):r[i]=s}0===o&&setTimeout((function(){e(r)}),0)}catch(e){n(e)}}))},e.race=function(t){return new e((function(e,n){if(t&&t.length)try{for(var r=function(r){var o=t[r];o&&pe(o.then)?o.then(e,n):setTimeout((function(){e(o)}),0)},o=0;o<t.length;o++)r(o)}catch(e){n(e)}}))},e}();const fe=he;var me=0,ve=[],ge=[],ye=[];function _e(){return(new Date).getTime()}const be=function(){function e(t,n){var r=0,o=(t||"<unnamed>")+"."+me;function i(e){var t=(0,I.mS)();t&&t.QUnit&&console&&console.log("ESPromiseScheduler["+o+"] "+e)}function s(e){(0,m.OG)(n,"ESPromiseScheduler["+o+"] "+e)}me++,(0,f.default)(e,this,(function(e){var t=null,n=0;function a(e,t){for(var n=0;n<e.length;n++)if(e[n].id===t)return e.splice(n,1)[0];return null}e.scheduleEvent=function(e,c,u){var l=o+"."+n;n++,c&&(l+="-("+c+")");var p=l+"{"+r+"}";r++;var d,h,f,m={evt:null,tm:_e(),id:p,isRunning:!1,isAborted:!1};return m.evt=t?(d=m,h=t,f=new fe((function(e,t){var n=_e()-h.tm,r=h.id;i("["+l+"] is waiting for ["+r+":"+n+" ms] to complete before starting -- ["+ge.length+"] waiting and ["+ve.length+"] running"),d.abort=function(e){d.abort=null,a(ge,l),d.isAborted=!0,t(new Error(e))},h.evt.then((function(n){a(ge,l),E(d).then(e,t)}),(function(n){a(ge,l),E(d).then(e,t)}))})),ge.push(d),f):E(m),(t=m).evt._schId=p,m.evt;function v(e){for(var t=_e(),n=t-6e5,r=e.length,o=0;o<r;){var i=e[o];if(i&&i.tm<n){var a=null;i.abort?(a="Aborting ["+i.id+"] due to Excessive runtime ("+(t-i.tm)+" ms)",i.abort(a)):a="Removing ["+i.id+"] due to Excessive runtime ("+(t-i.tm)+" ms)",s(a),e.splice(o,1),r--}else o++}}function g(e,n){var r=!1,o=a(ve,e);if(o||(o=a(ye,e),r=!0),o){o.to&&(clearTimeout(o.to),o.to=null);var c=_e()-o.tm;n?r?s("Timed out event ["+e+"] finally complete -- "+c+" ms"):i("Promise ["+e+"] Complete -- "+c+" ms"):(ye.push(o),s("Event ["+e+"] Timed out and removed -- "+c+" ms"))}else i("Failed to remove ["+e+"] from running queue");t&&t.id===e&&(t=null),v(ve),v(ge),v(ye)}function y(e,t){return function(n){return g(e,!0),t&&t(n),n}}function _(e,t,n,r){t.then((function(t){return t instanceof fe?(i("Event ["+e+"] returned a promise -- waiting"),_(e,t,n,r),t):y(e,n)(t)}),y(e,r))}function b(e,t){var n=e.id;return new fe((function(r,o){i("Event ["+n+"] Starting -- waited for "+(e.wTm||"--")+" ms"),e.isRunning=!0,e.abort=function(t){e.abort=null,e.isAborted=!0,g(n,!1),o(new Error(t))};var s=t(n);s instanceof fe?(u&&(e.to=setTimeout((function(){g(n,!1),o(new Error("Timed out after ["+u+"] ms"))}),u)),_(n,s,(function(t){i("Event ["+n+"] Resolving after "+(_e()-e.tm)+" ms"),r(t)}),o)):(i("Promise ["+n+"] Auto completed as the start action did not return a promise"),r())}))}function E(t){var n=_e();return t.wTm=n-t.tm,t.tm=n,t.isAborted?fe.reject(new Error("["+l+"] was aborted")):(ve.push(t),b(t,e))}}}))}return e.incomplete=function(){return ve},e.waitingToStart=function(){return ge},e}();var Ee=function(){function e(e){var t=this,n={},r=[],o=[];function i(e,t){var i,a=n[e];if(a&&(i=a[t]),!i&&null!==i){if((0,s.Kg)(e)&&(0,s.Kg)(t))if(o.length>0){for(var c=0;c<o.length;c++)if(o[c].handleField(e,t)){i={canHandle:!0,fieldHandler:o[c]};break}}else 0===r.length&&(i={canHandle:!0});if(!i&&null!==i)for(i=null,c=0;c<r.length;c++)if(r[c].handleField(e,t)){i={canHandle:!0,handler:r[c],fieldHandler:null};break}a||(a=n[e]={}),a[t]=i}return i}function a(e,t,n,r,o,i){if(e.handler)return e.handler.property(t,n,o,i);if(!(0,s.hX)(o.kind)){if(!(4096&~r&&J(o.kind)))return null;o.value=o.value.toString()}return u(e.fieldHandler,t,n,r,o)}function c(e,t,n){return U(n)?{value:n}:null}function u(e,n,r,o,i){if(i&&e){var a=e.getSanitizer(n,r,o,i.kind,i.propertyType);if(a)if(4===o){var l={},p=i.value;(0,s.z)(p,(function(t,o){var i=n+"."+r;if(U(o)){var s=c(0,0,o);(s=u(e,i,t,te(o),s))&&(l[t]=s.value)}})),i.value=l}else{var d={path:n,name:r,type:o,prop:i,sanitizer:t};i=a.call(t,d)}}return i}e&&o.push(e),t.addSanitizer=function(e){e&&(r.push(e),n={})},t.addFieldSanitizer=function(e){e&&(o.push(e),n={})},t.handleField=function(e,t){var n=i(e,t);return!!n&&n.canHandle},t.value=function(e,t,n,r){var o=i(e,t);if(o&&o.canHandle){if(!o||!o.canHandle)return null;if(o.handler)return o.handler.value(e,t,n,r);if(!(0,s.Kg)(t)||(0,s.hX)(n)||n===_)return null;var u=null,l=te(n);if(8192&~l)1!==l&&2!==l&&3!==l&&4096&~l?4===l&&(u=c(0,0,r?JSON.stringify(n):n)):u=c(0,0,n);else{var p=-8193&l;if(!U((u=n).value)||1!==p&&2!==p&&3!==p&&4096&~p)return null}if(u)return a(o,e,t,l,u,r)}return null},t.property=function(e,t,n,r){var o=i(e,t);if(!o||!o.canHandle)return null;if(!(0,s.Kg)(t)||(0,s.hX)(n)||!U(n.value))return null;var c=te(n.value);return 0===c?null:a(o,e,t,c,n,r)}}return e.getFieldType=te,e}(),Te=n(4013),Se=n(7428),Ce=n(8012),xe=n(8963),we=n(4343),Ae=n(2429),Ie=n(2755),Re=n(2675)},3435:(e,t,n)=>{"use strict";n.d(t,{Hj:()=>o,oP:()=>s,oc:()=>i});var r=n(2504);function o(e){var t={};return(0,r.z)(e,(function(e,n){t[e]=n,t[n]=e})),(0,r.ol)(t)}function i(e){var t={};return(0,r.z)(e,(function(e,n){t[e]=e,t[n]=e})),(0,r.ol)(t)}function s(e){var t={};return(0,r.z)(e,(function(e,n){t[e]=n[1],t[n[0]]=n[1]})),(0,r.ol)(t)}},4343:(e,t,n)=>{"use strict";n.d(t,{x:()=>r});var r=(0,n(3435).Hj)({Unknown:0,NonRetryableStatus:1,InvalidEvent:2,SizeLimitExceeded:3,KillSwitch:4,QueueFull:5})},6166:(e,t,n)=>{"use strict";n.d(t,{$:()=>E,b:()=>b});var r,o=n(3435),i="Failed",s=i+"MonitorAjax",a="Track",c="Start",u="Stop",l="Event",p="AuthContext",d="Exception",h="Local",f="Session",m="Storage",v="Browser",g="Cannot",y="Buffer",_="InstrumentationKey",b=(0,o.Hj)({CRITICAL:1,WARNING:2}),E=(0,o.Hj)(((r={})[v+"DoesNotSupport"+h+m]=0,r[v+g+"Read"+h+m]=1,r[v+g+"Read"+f+m]=2,r[v+g+"Write"+h+m]=3,r[v+g+"Write"+f+m]=4,r[v+i+"RemovalFrom"+h+m]=5,r[v+i+"RemovalFrom"+f+m]=6,r[g+"SendEmptyTelemetry"]=7,r.ClientPerformanceMathError=8,r["ErrorParsingAI"+f+"Cookie"]=9,r.ErrorPVCalc=10,r[d+"WhileLoggingError"]=11,r[i+"AddingTelemetryTo"+y]=12,r[s+"Abort"]=13,r[s+"Dur"]=14,r[s+"Open"]=15,r[s+"RSC"]=16,r[s+"Send"]=17,r[s+"GetCorrelationHeader"]=18,r[i+"ToAddHandlerForOnBeforeUnload"]=19,r[i+"ToSendQueuedTelemetry"]=20,r[i+"ToReportDataLoss"]=21,r["Flush"+i]=22,r.MessageLimitPerPVExceeded=23,r.MissingRequiredFieldSpecification=24,r.NavigationTimingNotSupported=25,r.OnError=26,r[f+"RenewalDateIsZero"]=27,r.SenderNotInitialized=28,r[c+a+l+i]=29,r[u+a+l+i]=30,r[c+a+i]=31,r[u+a+i]=32,r.TelemetrySampledAndNotSent=33,r[a+l+i]=34,r[a+d+i]=35,r[a+"Metric"+i]=36,r[a+"PV"+i]=37,r[a+"PV"+i+"Calc"]=38,r[a+"Trace"+i]=39,r["Transmission"+i]=40,r[i+"ToSet"+m+y]=41,r[i+"ToRestore"+m+y]=42,r.InvalidBackendResponse=43,r[i+"ToFixDepricatedValues"]=44,r.InvalidDurationValue=45,r.TelemetryEnvelopeInvalid=46,r.CreateEnvelopeError=47,r[g+"SerializeObject"]=48,r[g+"SerializeObjectNonSerializable"]=49,r.CircularReferenceDetected=50,r["Clear"+p+i]=51,r[d+"Truncated"]=52,r.IllegalCharsInName=53,r.ItemNotInArray=54,r.MaxAjaxPerPVExceeded=55,r.MessageTruncated=56,r.NameTooLong=57,r.SampleRateOutOfRange=58,r["Set"+p+i]=59,r["Set"+p+i+"AccountName"]=60,r.StringValueTooLong=61,r.StartCalledMoreThanOnce=62,r.StopCalledWithoutStart=63,r["TelemetryInitializer"+i]=64,r.TrackArgumentsNotSpecified=65,r.UrlTooLong=66,r[f+m+y+"Full"]=67,r[g+"AccessCookie"]=68,r.IdTooLong=69,r.InvalidEvent=70,r[s+"SetRequestHeader"]=71,r["Send"+v+"InfoOnUserInit"]=72,r["Plugin"+d]=73,r["Notification"+d]=74,r.SnippetScriptLoadFailure=99,r["Invalid"+_]=100,r[g+"ParseAiBlobValue"]=101,r.InvalidContentBlob=102,r[a+"PageAction"+l+i]=103,r[i+"AddingCustomDefinedRequestContext"]=104,r["InMemory"+m+y+"Full"]=105,r[_+"Deprecation"]=106,r))},8963:(e,t,n)=>{"use strict";n.d(t,{T:()=>r});var r=100},6382:(e,t,n)=>{"use strict";n.d(t,{_:()=>d});var r=n(212),o=n(9284),i=n(3229),s=n(3227),a=n(6392),c=n(2504),u=n(5397),l=n(4013),p=n(5441),d=function(e){function t(){var n=e.call(this)||this;return(0,o.A)(t,n,(function(e,t){function n(t){var n=e[i.RF]();n&&n[u.Yp]([t],2)}e[i.mE]=function(e,n,r,o){t[i.mE](e,n,r||new a.wq(e),o||new l.h(e))},e.track=function(r){(0,p.r2)(e[u.kI](),(function(){return"AppInsightsCore:track"}),(function(){null===r&&(n(r),(0,c.$8)("Invalid telemetry item")),function(e){(0,c.hX)(e[i.RS])&&(n(e),(0,c.$8)("telemetry name required"))}(r),t.track(r)}),(function(){return{item:r}}),!r.sync)}})),n}return(0,r.qU)(t,e),t.__ieDyn=1,t}(s.F)},3227:(e,t,n)=>{"use strict";n.d(t,{F:()=>I});var r=n(212),o=n(9284),i=n(9381),s=n(3229),a=n(2504),c=n(5397),u=n(8012),l=n(1267),p=500;function d(e,t,n){t&&(0,a.cy)(t)&&t[s.oI]>0&&(t=t.sort((function(e,t){return e[c.Vo]-t[c.Vo]})),(0,a.Iu)(t,(function(e){e[c.Vo]<p&&(0,a.$8)("Channel has invalid priority - "+e[s.Ju])})),e[s.y5]({queue:(0,a.N6)(t),chain:(0,u.PV)(t,n[s.GA],n)}))}var h=n(5691),f=n(2429),m=n(8074),v=n(6392),g=n(5441),y=n(7428),_=n(8323),b=function(e){function t(){var n,r,i=e.call(this)||this;function u(){n=0,r=[]}return i.identifier="TelemetryInitializerPlugin",i.priority=199,u(),(0,o.A)(t,i,(function(e,t){e.addTelemetryInitializer=function(e){var t={id:n++,fn:e};return r[s.y5](t),{remove:function(){(0,a.Iu)(r,(function(e,n){if(e.id===t.id)return r[s.Ic](n,1),-1}))}}},e[c.qT]=function(t,n){for(var o=!1,i=r[s.oI],c=0;c<i;++c){var u=r[c];if(u)try{if(!1===u.fn[s.y9](null,[t])){o=!0;break}}catch(e){(0,v.ZP)(n[s.e4](),1,64,"One of telemetry initializers failed, telemetry item will not be sent: "+(0,a.lL)(e),{exception:(0,_.mm)(e)},!0)}}o||e[s.$5](t,n)},e[s.tn]=function(){u()}})),i}return(0,r.qU)(t,e),t.__ieDyn=1,t}(y.s),E=n(2755),T="Plugins must provide initialize method",S="_notificationManager",C="SDK is still unloading...",x={loggingLevelConsole:1};function w(e,t){return new g.NS(t)}function A(e,t){var n=!1;return(0,a.Iu)(t,(function(t){if(t===e)return n=!0,-1})),n}var I=function(){function e(){var t,n,y,_,I,R,P,O,N,k,D,M,L,j,U,F,z,q,B,H,G=0,V=!1;(0,o.A)(e,this,(function(e){function o(n){if(!G&&!V&&(n||e[s.Uw]&&e[s.Uw].queue[s.oI]>0)){var r=(0,a.SA)(t.diagnosticLogInterval);r&&r>0||(r=1e4),G=setInterval((function(){clearInterval(G),G=0,J()}),r)}return G}function $(){n=!1,t=(0,a.CP)(!0,{},x),e[s.GA]=t,e[s.Uw]=new v.wq(t),e[s.H7]=[],U=new b,y=[],_=null,I=null,R=null,P=null,O=null,k=null,N=[],D=null,M=null,L=null,j=!1,F=null,z=(0,f.Z)("AIBaseCore",!0),q=(0,E.P)(),H=null}function K(){var n=(0,u.i8)(Y(),t,e);return n[s.by](o),n}function W(n){var r=function(e,t,n){var r,o=[],i={};return(0,a.Iu)(n,(function(t){((0,a.hX)(t)||(0,a.hX)(t[s.mE]))&&(0,a.$8)(T);var n=t[c.Vo],r=t[s.Ju];t&&n&&((0,a.hX)(i[n])?i[n]=r:(0,v.OG)(e,"Two extensions have same priority #"+n+" - "+i[n]+", "+r)),(!n||n<500)&&o[s.y5](t)})),(r={all:n})[c.eT]=o,r}(e[s.Uw],0,N);k=r[c.eT],O=null;var i=r.all;if(L=(0,a.N6)(function(e,t,n){var r=[];if(e&&(0,a.Iu)(e,(function(e){return d(r,e,n)})),t){var o=[];(0,a.Iu)(t,(function(e){e[c.Vo]>p&&o[s.y5](e)})),d(r,o,n)}return r}(M,i,e)),D){var h=(0,a.rD)(i,D);-1!==h&&i[s.Ic](h,1),-1!==(h=(0,a.rD)(k,D))&&k[s.Ic](h,1),D._setQueue(L)}else D=function(e,t){function n(){return(0,u.i8)(null,t[s.GA],t,null)}function r(e,t,n,r){var o=e?e[s.oI]+1:1;function i(){0==--o&&(r&&r(),r=null)}o>0&&(0,a.Iu)(e,(function(e){if(e&&e.queue[s.oI]>0){var r=e.chain,a=t[s.$o](r);a[s.by](i),n(a)}else o--})),i()}var o=!1,i={identifier:"ChannelControllerPlugin",priority:p,initialize:function(t,n,r,i){o=!0,(0,a.Iu)(e,(function(e){e&&e.queue[s.oI]>0&&(0,l.pI)((0,u.i8)(e.chain,t,n),r)}))},isInitialized:function(){return o},processTelemetry:function(t,o){r(e,o||n(),(function(e){e[s.$5](t)}),(function(){o[s.$5](t)}))},update:function(t,n){var o=n||{reason:0};return r(e,t,(function(e){e[s.$5](o)}),(function(){t[s.$5](o)})),!0},pause:function(){r(e,n(),(function(e){e.iterate((function(e){e.pause&&e.pause()}))}),null)},resume:function(){r(e,n(),(function(e){e.iterate((function(e){e.resume&&e.resume()}))}),null)},teardown:function(t,n){var i=n||{reason:0,isAsync:!1};return r(e,t,(function(e){e[s.$5](i)}),(function(){t[s.$5](i),o=!1})),!0},getChannel:function(t){var n=null;return e&&e[s.oI]>0&&(0,a.Iu)(e,(function(e){if(e&&e.queue[s.oI]>0&&((0,a.Iu)(e.queue,(function(e){if(e[s.Ju]===t)return n=e,-1})),n))return-1})),n},flush:function(t,o,i,a){var c=1,u=!1,l=null;function p(){c--,u&&0===c&&(l&&(clearTimeout(l),l=null),o&&o(u),o=null)}return a=a||5e3,r(e,n(),(function(e){e.iterate((function(e){if(e[s.EX]){c++;var n=!1;e[s.EX](t,(function(){n=!0,p()}),i)||n||(t&&null==l?l=setTimeout((function(){l=null,p()}),a):p())}}))}),(function(){u=!0,p()})),!0},_setQueue:function(t){e=t}};return i}(L,e);i[s.y5](D),k[s.y5](D),e[s.H7]=(0,l.Xc)(i),D[s.mE](t,e,i);var f=K();(0,l.pI)(f,i),e[s.H7]=(0,a.N6)((0,l.Xc)(k||[])).slice(),n&&function(t){var n=(0,u.nU)(Y(),e);n[s.by](o),e._updateHook&&!0===e._updateHook(n,t)||n[s.$5](t)}(n)}function Q(t){var n,r=null,o=null;return(0,a.Iu)(e[s.H7],(function(e){if(e[s.Ju]===t&&e!==D&&e!==U)return o=e,-1})),!o&&D&&(o=D.getChannel(t)),o&&((n={plugin:o})[s.kt]=function(e){(0,l.Cr)(o)[c.Hr]=!e},n.isEnabled=function(){var e=(0,l.Cr)(o);return!e[s.Ik]&&!e[c.Hr]},n.remove=function(e,t){var n;void 0===e&&(e=!0);var r=[o],i=((n={reason:1})[s.tI]=e,n);X(r,i,(function(e){e&&W({reason:32,removed:r}),t&&t(e)}))},r=n),r}function Y(){if(!O){var n=(k||[]).slice();-1===(0,a.rD)(n,U)&&n[s.y5](U),O=(0,u.PV)((0,l.Xc)(n),t,e)}return O}function X(n,r,i){if(n&&n[s.oI]>0){var c=(0,u.PV)(n,t,e),l=(0,u.tS)(c,e);l[s.by]((function(){var e=!1,t=[];(0,a.Iu)(N,(function(r,o){A(r,n)?e=!0:t[s.y5](r)})),N=t;var r=[];M&&((0,a.Iu)(M,(function(t,o){var i=[];(0,a.Iu)(t,(function(t){A(t,n)?e=!0:i[s.y5](t)})),r[s.y5](i)})),M=r),i&&i(e),o()})),l[s.$5](r)}else i(!1)}function J(){if(e[s.Uw]&&e[s.Uw].queue){var n=e[s.Uw].queue.slice(0);e[s.Uw].queue[s.oI]=0,(0,a.Iu)(n,(function(n){var r,o=((r={})[s.RS]=F||"InternalMessageId: "+n[s.JR],r.iKey=(0,a.SA)(t[s.sl]),r.time=(0,a._u)(new Date),r.baseType=v.WD.dataType,r.baseData={message:n[s.pM]},r);e.track(o)}))}}function Z(e,t,n,r){return D?D[s.EX](e,t,n||6,r):(t&&t(!1),!0)}function ee(t){var n=e[s.Uw];n?((0,v.ZP)(n,2,73,t),o()):(0,a.$8)(t)}$(),e[s.tZ]=function(){return n},e[s.mE]=function(o,i,u,l){var p,d;j&&(0,a.$8)(C),e[s.tZ]()&&(0,a.$8)("Core should not be initialized more than once"),t=o||{},e[s.GA]=t,(0,a.hX)(o[s.sl])&&(0,a.$8)("Please provide instrumentation key"),_=l,e[S]=l,!0===(d=(0,a.SA)(t.disableDbgExt))&&B&&(_[s.TP](B),B=null),_&&!B&&!0!==d&&(B=(0,m.M)(t),_[s.vR](B)),!(p=(0,a.SA)(t.enablePerfMgr))&&R&&(R=null),p&&(0,a.c2)(t,c.Yd,w),(0,a.c2)(t,c.Bw,{}).NotificationManager=_,u&&(e[s.Uw]=u);var h=(0,a.c2)(t,c.jy,[]);(N=[])[s.y5].apply(N,(0,r.vz)((0,r.vz)([],i,!1),h,!1)),M=(0,a.c2)(t,c.LZ,[]),W(null),L&&0!==L[s.oI]||(0,a.$8)("No "+c.LZ+" available"),n=!0,e.releaseQueue()},e.getTransmissionControls=function(){var e=[];return L&&(0,a.Iu)(L,(function(t){e[s.y5](t.queue)})),(0,a.N6)(e)},e.track=function(n){n.iKey=n.iKey||t[s.sl],n[s.fA]=n[s.fA]||(0,a._u)(new Date),n.ver=n.ver||"4.0",!j&&e[s.tZ]()?K()[s.$5](n):y[s.y5](n)},e[s.ps]=K,e[s.RF]=function(){var t;return _||(_=(0,i.AQ)(((t={})[s.vR]=function(e){},t[s.TP]=function(e){},t[c.fc]=function(e){},t[c.Yp]=function(e,t){},t[c.dI]=function(e,t){},t)),e[S]=_),_},e[s.vR]=function(e){_&&_[s.vR](e)},e[s.TP]=function(e){_&&_[s.TP](e)},e.getCookieMgr=function(){return P||(P=(0,h.xN)(t,e[s.Uw])),P},e.setCookieMgr=function(e){P=e},e[c.kI]=function(){if(!I&&!R&&(0,a.SA)(t.enablePerfMgr)){var n=(0,a.SA)(t[c.Yd]);(0,a.Tn)(n)&&(R=n(e,e[s.RF]()))}return I||R||(0,g.Z4)()},e.setPerfMgr=function(e){I=e},e.eventCnt=function(){return y[s.oI]},e.releaseQueue=function(){if(n&&y[s.oI]>0){var e=y;y=[],(0,a.Iu)(e,(function(e){K()[s.$5](e)}))}},e.pollInternalLogs=function(e){return F=e||null,V=!1,G&&(clearInterval(G),G=null),o(!0)},e[s.Di]=function(){V=!0,G&&(clearInterval(G),G=0,J())},(0,a.o$)(e,(function(){return U}),["addTelemetryInitializer"]),e.unload=function(t,r,o){var i;void 0===t&&(t=!0),n||(0,a.$8)("SDK is not initialized"),j&&(0,a.$8)(C);var c=((i={reason:50})[s.tI]=t,i.flushComplete=!1,i),l=(0,u.tS)(Y(),e);function p(t){c.flushComplete=t,j=!0,q.run(l,c),e[s.Di](),l[s.$5](c)}l[s.by]((function(){$(),r&&r(c)}),e),J(),Z(t,p,6,o)||p(!1)},e[s.AP]=Q,e.addPlugin=function(e,t,n,r){if(!e)return r&&r(!1),void ee(T);var o=Q(e[s.Ju]);if(o&&!t)return r&&r(!1),void ee("Plugin ["+e[s.Ju]+"] is already loaded!");var i={reason:16};function a(t){N[s.y5](e),i.added=[e],W(i),r&&r(!0)}if(o){var c=[o.plugin];X(c,{reason:2,isAsync:!!n},(function(e){e?(i.removed=c,i.reason|=32,a()):r&&r(!1)}))}else a()},e.evtNamespace=function(){return z},e[s.EX]=Z,e.getTraceCtx=function(e){return H||(H=(0,l.u7)()),H},e.setTraceCtx=function(e){H=e||null},(0,a.RF)(e,"addUnloadCb",(function(){return q}),"add")}))}return e.__ieDyn=1,e}()},7428:(e,t,n)=>{"use strict";n.d(t,{s:()=>l});var r=n(9284),o=n(3229),i=n(2504),s=n(5397),a=n(8012),c=n(2755),u="getPlugin",l=function(){function e(){var t,n,l,p,d,h=this;function f(e){void 0===e&&(e=null);var t=e;if(!t){var r=n||(0,a.i8)(null,{},h[s.eT]);t=l&&l[u]?r[o.$o](null,l[u]):r[o.$o](null,l)}return t}function m(e,t,r){e&&(0,i.KY)(e,s.Bw,[],null,i.hX),!r&&t&&(r=t[o.ps]()[o.uR]());var c=l;l&&l[u]&&(c=l[u]()),h[s.eT]=t,n=(0,a.i8)(r,e,t,c)}function v(){t=!1,h[s.eT]=null,n=null,l=null,d=[],p=(0,c.P)()}v(),(0,r.A)(e,h,(function(e){e[o.mE]=function(e,n,r,o){m(e,n,o),t=!0},e[o.Ik]=function(t,n){var r,c=e[s.eT];if(c&&(!t||c===t[s.eT]())){var h,f=!1,m=t||(0,a.tS)(null,c,l&&l[u]?l[u]():l),g=n||((r={reason:0})[o.tI]=!1,r);return e[o.tn]&&!0===e[o.tn](m,g,y)?h=!0:y(),h}function y(){if(!f){f=!0,p.run(m,n);var e=d;d=[],(0,i.Iu)(e,(function(e){e.rm()})),!0===h&&m[o.$5](g),v()}}},e[o.HC]=function(t,n){var r=e[s.eT];if(r&&(!t||r===t[s.eT]())){var i,c=!1,p=t||(0,a.nU)(null,r,l&&l[u]?l[u]():l),d=n||{reason:0};return e._doUpdate&&!0===e._doUpdate(p,d,h)?i=!0:h(),i}function h(){c||(c=!0,m(p.getCfg(),p.core(),p[o.uR]()))}},e._addHook=function(e){e&&((0,i.cy)(e)?d=d.concat(e):d[o.y5](e))},(0,i.RF)(e,"_addUnloadCb",(function(){return p}),"add")})),h[o.e4]=function(e){return f(e)[o.e4]()},h[o.tZ]=function(){return t},h.setInitialized=function(e){t=e},h[o.YH]=function(e){l=e},h[o.$5]=function(e,t){t?t[o.$5](e):l&&(0,i.Tn)(l[s.qT])&&l[s.qT](e,null)},h._getTelCtx=f}return e.__ieDyn=1,e}()},5691:(e,t,n)=>{"use strict";n.d(t,{It:()=>k,d5:()=>T,gi:()=>A,um:()=>x,xN:()=>w});var r=n(3229),o=n(6392),i=n(8323),s=n(2504),a=n(5397),c="toGMTString",u="toUTCString",l="cookie",p="expires",d="enabled",h="isCookieUseDisabled",f="disableCookiesUsage",m="_ckMgr",v=null,g=null,y=null,_=(0,i.YE)(),b={},E={};function T(e,t){var n=w[m]||E[m];return n||(n=w[m]=w(e,t),E[m]=n),n}function S(e){return!e||e.isEnabled()}function C(e,t){return!!(t&&e&&(0,s.cy)(e.ignoreCookies))&&-1!==e.ignoreCookies[r.Sj](t)}function x(e,t){var n;if(e)n=e.getCookieMgr();else if(t){var o=t[r.lK];n=o[m]?o[m]:w(t)}return n||(n=T(t,(e||{})[r.Uw])),n}function w(e,t){var n,o=function(e){var t=e[r.lK]=e[r.lK]||{};if((0,s.KY)(t,"domain",e.cookieDomain,s.Gh,s.hX),(0,s.KY)(t,"path",e.cookiePath||"/",null,s.hX),(0,s.hX)(t[d])){var n=void 0;(0,s.b0)(e[h])||(n=!e[h]),(0,s.b0)(e[f])||(n=!e[f]),t[d]=n}return t}(e||E),l=o.path||"/",v=o.domain,y=!1!==o[d],_=((n={isEnabled:function(){var e=y&&A(t),n=E[m];return e&&n&&_!==n&&(e=S(n)),e}})[r.kt]=function(e){y=!1!==e},n.set=function(e,t,n,d,h){var f=!1;if(S(_)&&!function(e,t){return!!(t&&e&&(0,s.cy)(e.blockedCookies)&&-1!==e.blockedCookies[r.Sj](t))||C(e,t)}(o,e)){var m={},y=(0,s.EH)(t||a.m5),b=y[r.Sj](";");if(-1!==b&&(y=(0,s.EH)(t[r.Re](0,b)),m=I(t[r.Re](b+1))),(0,s.KY)(m,"domain",d||v,s.zz,s.b0),!(0,s.hX)(n)){var E=(0,i.lT)();if((0,s.b0)(m[p])){var T=(0,s.x3)()+1e3*n;if(T>0){var x=new Date;x.setTime(T),(0,s.KY)(m,p,R(x,E?c:u)||R(x,E?c:u)||a.m5,s.zz)}}E||(0,s.KY)(m,"max-age",a.m5+n,null,s.b0)}var w=(0,i.g$)();w&&"https:"===w.protocol&&((0,s.KY)(m,"secure",null,null,s.b0),null===g&&(g=!k(((0,i.w3)()||{})[r.tX])),g&&(0,s.KY)(m,"SameSite","None",null,s.b0)),(0,s.KY)(m,"path",h||l,null,s.b0),(o.setCookie||N)(e,P(y,m)),f=!0}return f},n.get=function(e){var t=a.m5;return S(_)&&!C(o,e)&&(t=(o.getCookie||O)(e)),t},n.del=function(e,t){var n=!1;return S(_)&&(n=_.purge(e,t)),n},n.purge=function(e,n){var r,s=!1;if(A(t)){var c=((r={}).path=n||"/",r[p]="Thu, 01 Jan 1970 00:00:01 GMT",r);(0,i.lT)()||(c["max-age"]="0"),(o.delCookie||N)(e,P(a.m5,c)),s=!0}return s},n);return _[m]=_,_}function A(e){if(null===v){v=!1;try{v=void 0!==(_||{})[l]}catch(t){(0,o.ZP)(e,2,68,"Cannot access document.cookie - "+(0,s.lL)(t),{exception:(0,i.mm)(t)})}}return v}function I(e){var t={};if(e&&e[r.oI]){var n=(0,s.EH)(e)[r.sY](";");(0,s.Iu)(n,(function(e){if(e=(0,s.EH)(e||a.m5)){var n=e[r.Sj]("=");-1===n?t[e]=null:t[(0,s.EH)(e[r.Re](0,n))]=(0,s.EH)(e[r.Re](n+1))}}))}return t}function R(e,t){return(0,s.Tn)(e[t])?e[t]():null}function P(e,t){var n=e||a.m5;return(0,s.z)(t,(function(e,t){n+="; "+e+((0,s.hX)(t)?a.m5:"="+t)})),n}function O(e){var t=a.m5;if(_){var n=_[l]||a.m5;y!==n&&(b=I(n),y=n),t=(0,s.EH)(b[e]||a.m5)}return t}function N(e,t){_&&(_[l]=e+"="+t)}function k(e){return!(!(0,s.Kg)(e)||!(0,s.Ju)(e,"CPU iPhone OS 12")&&!(0,s.Ju)(e,"iPad; CPU OS 12")&&!((0,s.Ju)(e,"Macintosh; Intel Mac OS X 10_14")&&(0,s.Ju)(e,"Version/")&&(0,s.Ju)(e,"Safari"))&&(!(0,s.Ju)(e,"Macintosh; Intel Mac OS X 10_14")||!(0,s.Cv)(e,"AppleWebKit/605.1.15 (KHTML, like Gecko)"))&&!(0,s.Ju)(e,"Chrome/5")&&!(0,s.Ju)(e,"Chrome/6")&&(!(0,s.Ju)(e,"UnrealEngine")||(0,s.Ju)(e,"Chrome"))&&!(0,s.Ju)(e,"UCBrowser/12")&&!(0,s.Ju)(e,"UCBrowser/11"))}},5955:(e,t,n)=>{"use strict";n.d(t,{Rb:()=>b,Ri:()=>S,TV:()=>C,UU:()=>v,WD:()=>E,Yj:()=>x,aq:()=>m,cL:()=>g,fs:()=>_,ht:()=>T,jS:()=>y,rK:()=>f});var r,o=n(7245),i=n(9381),s=n(3229),a=n(5691),c=n(8323),u=n(4838),l=n(2504),p=n(5397),d=n(9668),h=null,f=o.bA;function m(){var e=g();return e[s.Re](0,8)+"-"+e[s.Re](8,12)+"-"+e[s.Re](12,16)+"-"+e[s.Re](16,20)+"-"+e[s.Re](20)}function v(){var e=(0,c.FJ)();return e&&e.now?e.now():(0,l.x3)()}function g(){for(var e,t=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],n=p.m5,r=0;r<4;r++)n+=t[15&(e=(0,d.VN)())]+t[e>>4&15]+t[e>>8&15]+t[e>>12&15]+t[e>>16&15]+t[e>>20&15]+t[e>>24&15]+t[e>>28&15];var o=t[8+(3&(0,d.VN)())|0];return n[s.$4](0,8)+n[s.$4](9,4)+"4"+n[s.$4](13,3)+o+n[s.$4](16,3)+n[s.$4](19,12)}var y={_canUseCookies:void 0,isTypeof:l.Ed,isUndefined:l.b0,isNullOrUndefined:l.hX,hasOwnProperty:l.mQ,isFunction:l.Tn,isObject:l.Gv,isDate:l.$P,isArray:l.cy,isError:l.bJ,isString:l.Kg,isNumber:l.Et,isBoolean:l.Lm,toISOString:l._u,arrForEach:l.Iu,arrIndexOf:l.rD,arrMap:l.W$,arrReduce:l.KT,strTrim:l.EH,objCreate:i.AQ,objKeys:l.cG,objDefineAccessors:l.r,addEventHandler:u.So,dateNow:l.x3,isIE:c.lT,disableCookies:E,newGuid:m,perfNow:v,newId:d.Si,randomValue:d.Z1,random32:d.VN,mwcRandomSeed:d.yc,mwcRandom32:d.k5,generateW3CId:g},_={Attach:u.Q3,AttachEvent:u.Q3,Detach:u.Ym,DetachEvent:u.Ym};function b(e,t){var n=(0,a.d5)(e,t),o=y._canUseCookies;return null===h&&(h=[],r=o,(0,l.r)(y,"_canUseCookies",(function(){return r}),(function(e){r=e,(0,l.Iu)(h,(function(t){t[s.kt](e)}))}))),-1===(0,l.rD)(h,n)&&h[s.y5](n),(0,l.Lm)(o)&&n[s.kt](o),(0,l.Lm)(r)&&n[s.kt](r),n}function E(){b()[s.kt](!1)}function T(e){return b(null,e).isEnabled()}function S(e,t){return b(null,e).get(t)}function C(e,t,n,r){b(null,e).set(t,n,null,r)}function x(e,t){return b(null,e).del(t)}},2429:(e,t,n)=>{"use strict";n.d(t,{T:()=>f,Z:()=>h});var r=n(7245),o=n(3229),i=n(2504),s=n(5397),a=n(9668),c=r.KU,u="2.8.15",l="."+(0,a.Si)(6),p=0;function d(e){return 1===e[o.re]||9===e[o.re]||!+e[o.re]}function h(e,t){return void 0===t&&(t=!1),(0,i.cH)(e+p+++(t?"."+u:s.m5)+l)}function f(e){var t={id:h("_aiData-"+(e||s.m5)+"."+u),accept:function(e){return d(e)},get:function(e,n,r,o){var s=e[t.id];return s?s[(0,i.cH)(n)]:(o&&((s=function(e,t){var n=t[e.id];if(!n){n={};try{d(t)&&(function(e,t,n){if(c)try{return c(e,t,{value:n,enumerable:!1,configurable:!0}),!0}catch(e){}return!1}(t,e.id,n)||(t[e.id]=n))}catch(e){}}return n}(t,e))[(0,i.cH)(n)]=r),r)},kill:function(e,t){if(e&&e[t])try{delete e[t]}catch(e){}}};return t}},8074:(e,t,n)=>{"use strict";n.d(t,{$:()=>u,M:()=>l});var r,o=n(3229),i=n(8323),s=["eventsSent","eventsDiscarded","eventsSendRequest","perfEvent"],a=null;function c(e,t){return function(){var n=arguments,r=u(t);if(r){var i=r.listener;i&&i[e]&&i[e][o.y9](i,n)}}}function u(e){var t,n=a;return n||!0===e.disableDbgExt||(n=a||((t=(0,i.EH)("Microsoft"))&&(a=t.ApplicationInsights),a)),n?n.ChromeDbgExt:null}function l(e){if(!r){r={};for(var t=0;t<s[o.oI];t++)r[s[t]]=c(s[t],e)}return r}},6392:(e,t,n)=>{"use strict";n.d(t,{OG:()=>v,Oc:()=>g,WD:()=>p,ZP:()=>m,wq:()=>h,y0:()=>d});var r=n(9284),o=n(3229),i=n(8074),s=n(8323),a=n(2504),c=n(5397);function u(e){return e?'"'+e[o.W7](/\"/g,c.m5)+'"':c.m5}function l(e,t){var n=(0,s.U5)();if(n){var r="log";n[e]&&(r=e),(0,a.Tn)(n[r])&&n[r](t)}}var p=function(){function e(e,t,n,r){void 0===n&&(n=!1);var i=this;i[o.JR]=e,i[o.pM]=(n?"AI: ":"AI (Internal): ")+e;var a=c.m5;(0,s.Z)()&&(a=(0,s.hm)().stringify(r));var l=(t?" message:"+u(t):c.m5)+(r?" props:"+u(a):c.m5);i[o.pM]+=l}return e.dataType="MessageData",e}();function d(e,t){return(e||{})[o.Uw]||new h(t)}var h=function(){function e(t){this.identifier="DiagnosticLogger",this.queue=[];var n,u,d,h,f=0,m={};(0,r.A)(e,this,(function(e){function r(t,n){if(!(f>=d)){var r=!0,i="AITR_"+n[o.JR];if(m[i]?r=!1:m[i]=!0,r&&(t<=u&&(e.queue[o.y5](n),f++,v(1===t?"error":"warn",n)),f===d)){var s="Internal events throttle limit per PageView reached for this app.",a=new p(23,s,!1);e.queue[o.y5](a),1===t?e[c.Zi](s):e[c.Tj](s)}}}function v(e,n){var r=(0,i.$)(t||{});r&&r[o.e4]&&r[o.e4](e,n)}!function(e){n=(0,a.SA)(e.loggingLevelConsole,0),u=(0,a.SA)(e.loggingLevelTelemetry,1),d=(0,a.SA)(e.maxMessageLimit,25),h=(0,a.SA)(e.enableDebug,(0,a.SA)(e[o.a$],!1))}(t||{}),e.consoleLoggingLevel=function(){return n},e.telemetryLoggingLevel=function(){return u},e.maxInternalMessageLimit=function(){return d},e[o.a$]=function(){return h},e.throwInternal=function(t,i,u,l,d){void 0===d&&(d=!1);var f=new p(i,u,d,l);if(h)throw(0,s.mm)(f);var g=1===t?c.Zi:c.Tj;if((0,a.b0)(f[o.pM]))v("throw"+(1===t?"Critical":"Warning"),f);else{if(d){var y=+f[o.JR];!m[y]&&n>=t&&(e[g](f[o.pM]),m[y]=!0)}else n>=t&&e[g](f[o.pM]);r(t,f)}},e[c.Tj]=function(e){l("warn",e),v("warning",e)},e[c.Zi]=function(e){l("error",e),v("error",e)},e.resetInternalMessageCount=function(){f=0,m={}},e[o.sx]=r}))}return e.__ieDyn=1,e}();function f(e){return e||new h}function m(e,t,n,r,o,i){void 0===i&&(i=!1),f(e).throwInternal(t,n,r,o,i)}function v(e,t){f(e)[c.Tj](t)}function g(e,t,n){f(e)[o.sx](t,n)}},8323:(e,t,n)=>{"use strict";n.d(t,{$Z:()=>ne,EH:()=>P,FJ:()=>q,Iu:()=>re,JK:()=>U,L0:()=>W,MY:()=>G,PV:()=>Z,Pt:()=>oe,R7:()=>J,Sf:()=>ie,U5:()=>z,Uf:()=>X,Vd:()=>O,Wt:()=>k,YE:()=>D,Z:()=>B,cU:()=>R,g$:()=>F,hm:()=>H,iN:()=>V,lT:()=>K,lV:()=>$,mm:()=>Q,nr:()=>Y,sN:()=>se,tw:()=>j,w3:()=>L,w9:()=>M,xk:()=>ee,zk:()=>N});var r=n(7245),o=n(9381),i=n(3229),s=n(2504),a=n(5397),c="window",u="document",l="documentMode",p="navigator",d="history",h="location",f="console",m="performance",v="JSON",g="crypto",y="msCrypto",_="ReactNative",b="msie",E="trident/",T="XMLHttpRequest",S=null,C=null,x=!1,w=null,A=null;function I(e,t){var n=!1;if(e){try{if(!(n=t in e)){var o=e[r.vR];o&&(n=t in o)}}catch(e){}if(!n)try{var i=new e;n=!(0,s.b0)(i[t])}catch(e){}}return n}function R(e){x=e}function P(e){var t=(0,o.mS)();return t&&t[e]?t[e]:e===c&&O()?window:null}function O(){return Boolean(typeof window===r._1&&window)}function N(){return O()?window:P(c)}function k(){return Boolean(typeof document===r._1&&document)}function D(){return k()?document:P(u)}function M(){return Boolean(typeof navigator===r._1&&navigator)}function L(){return M()?navigator:P(p)}function j(){return Boolean(typeof history===r._1&&history)}function U(){return j()?history:P(d)}function F(e){if(e&&x){var t=P("__mockLocation");if(t)return t}return typeof location===r._1&&location?location:P(h)}function z(){return typeof console!==r.bA?console:P(f)}function q(){return P(m)}function B(){return Boolean(typeof JSON===r._1&&JSON||null!==P(v))}function H(){return B()?JSON||P(v):null}function G(){return P(g)}function V(){return P(y)}function $(){var e=L();return!(!e||!e.product)&&e.product===_}function K(){var e=L();if(e&&(e[i.tX]!==C||null===S)){var t=((C=e[i.tX])||a.m5)[i.OL]();S=(0,s.Ju)(t,b)||(0,s.Ju)(t,E)}return S}function W(e){if(void 0===e&&(e=null),!e){var t=L()||{};e=t?(t[i.tX]||a.m5)[i.OL]():a.m5}var n=(e||a.m5)[i.OL]();if((0,s.Ju)(n,b)){var r=D()||{};return Math.max(parseInt(n[i.sY](b)[1]),r[l]||0)}if((0,s.Ju)(n,E)){var o=parseInt(n[i.sY](E)[1]);if(o)return o+4}return null}function Q(e){var t=Object[r.vR].toString[i.Ek](e),n=a.m5;return"[object Error]"===t?n="{ stack: '"+e.stack+"', message: '"+e.message+"', name: '"+e[i.RS]+"'":B()&&(n=H().stringify(e)),t+n}function Y(e){if(!e||!(0,s.Kg)(e)){var t=L()||{};e=t?(t[i.tX]||a.m5)[i.OL]():a.m5}return(e||a.m5)[i.OL]()[i.Sj]("safari")>=0}function X(){return null===A&&(A=M()&&Boolean(L().sendBeacon)),A}function J(e){var t=!1;try{t=!!P("fetch");var n=P("Request");t&&e&&n&&(t=I(n,"keepalive"))}catch(e){}return t}function Z(){return null===w&&(w=typeof XDomainRequest!==r.bA)&&ee()&&(w=w&&!I(P(T),"withCredentials")),w}function ee(){var e=!1;try{e=!!P(T)}catch(e){}return e}function te(e,t){if(e)for(var n=0;n<e[i.oI];n++){var r=e[n];if(r[i.RS]&&r[i.RS]===t)return r}return{}}function ne(e){var t=D();return t&&e?te(t.querySelectorAll("meta"),e).content:null}function re(e){var t,n=q();if(n){var r=n.getEntriesByType("navigation")||[];t=te((r[i.oI]>0?r[0]:{}).serverTiming,e).description}return t}function oe(e,t){return!!(e&&e.dispatchEvent&&t)&&(e.dispatchEvent(t),!0)}function ie(e,t){var n=null,r={detail:t||null};if((0,s.Tn)(CustomEvent))n=new CustomEvent(e,r);else{var o=D();o&&o.createEvent&&(n=o.createEvent("CustomEvent")).initCustomEvent(e,!0,!0,r)}return n}function se(e,t,n){var r=(0,o.mS)();if(r&&r.CustomEvent)try{return oe(r,ie(e,{cfg:t||null,customDetails:n||null}))}catch(e){}return!1}},4838:(e,t,n)=>{"use strict";n.d(t,{Ds:()=>H,El:()=>I,Fc:()=>G,Hm:()=>N,ML:()=>D,Q3:()=>M,So:()=>j,Wg:()=>q,Ym:()=>L,ee:()=>B,lQ:()=>z,mB:()=>k,oS:()=>$,sq:()=>V,vF:()=>K,zh:()=>U});var r=n(3229),o=n(2429),i=n(8323),s=n(2504),a=n(5397),c="on",u="attachEvent",l="addEventListener",p="detachEvent",d="removeEventListener",h="events",f="visibilitychange",m="pagehide",v="pageshow",g="unload",y="beforeunload",_=(0,o.Z)("aiEvtPageHide"),b=(0,o.Z)("aiEvtPageShow"),E=/\.[\.]+/g,T=/[\.]+$/,S=1,C=(0,o.T)("events"),x=/^([^.]*)(?:\.(.+)|)/;function w(e){return e&&e[r.W7]?e[r.W7](/^[\s\.]+|(?=[\s\.])[\.\s]+$/g,a.m5):e}function A(e,t){var n;if(t){var o=a.m5;(0,s.cy)(t)?(o=a.m5,(0,s.Iu)(t,(function(e){(e=w(e))&&("."!==e[0]&&(e="."+e),o+=e)}))):o=w(t),o&&("."!==o[0]&&(o="."+o),e=(e||a.m5)+o)}var i=x.exec(e||a.m5)||[];return(n={})[r.QM]=i[1],n.ns=(i[2]||a.m5).replace(E,".").replace(T,a.m5)[r.sY](".").sort().join("."),n}function I(e,t,n){var o=[],i=C.get(e,h,{},!1),c=A(t,n);return(0,s.z)(i,(function(e,t){(0,s.Iu)(t,(function(e){var t;c[r.QM]&&c[r.QM]!==e.evtName[r.QM]||c.ns&&c.ns!=c.ns||o[r.y5](((t={})[r.RS]=e.evtName[r.QM]+(e.evtName.ns?"."+e.evtName.ns:a.m5),t.handler=e[r.Yo],t))}))})),o}function R(e,t,n){void 0===n&&(n=!0);var r=C.get(e,h,{},n),o=r[t];return o||(o=r[t]=[]),o}function P(e,t,n,o){e&&t&&t[r.QM]&&(e[d]?e[d](t[r.QM],n,o):e[p]&&e[p](c+t[r.QM],n))}function O(e,t,n,o){for(var i=t[r.oI];i--;){var s=t[i];s&&(n.ns&&n.ns!==s.evtName.ns||o&&!o(s)||(P(e,s.evtName,s[r.Yo],s.capture),t[r.Ic](i,1)))}}function N(e,t){return t?A("xx",(0,s.cy)(t)?[e].concat(t):[e,t]).ns[r.sY]("."):e}function k(e,t,n,o,i){var s;void 0===i&&(i=!1);var a=!1;if(e)try{var p=A(t,o);if(a=function(e,t,n,o){var i=!1;return e&&t&&t[r.QM]&&n&&(e[l]?(e[l](t[r.QM],n,o),i=!0):e[u]&&(e[u](c+t[r.QM],n),i=!0)),i}(e,p,n,i),a&&C.accept(e)){var d=((s={guid:S++,evtName:p})[r.Yo]=n,s.capture=i,s);R(e,p.type)[r.y5](d)}}catch(e){}return a}function D(e,t,n,o,i){if(void 0===i&&(i=!1),e)try{var a=A(t,o),c=!1;!function(e,t,n){if(t[r.QM])O(e,R(e,t[r.QM]),t,n);else{var o=C.get(e,h,{});(0,s.z)(o,(function(r,o){O(e,o,t,n)})),0===(0,s.cG)(o)[r.oI]&&C.kill(e,h)}}(e,a,(function(e){return!((!a.ns||n)&&e[r.Yo]!==n||(c=!0,0))})),c||P(e,a,n,i)}catch(e){}}function M(e,t,n,r){return void 0===r&&(r=!1),k(e,t,n,null,r)}function L(e,t,n,r){void 0===r&&(r=!1),D(e,t,n,null,r)}function j(e,t,n){var r=!1,o=(0,i.zk)();o&&(r=k(o,e,t,n),r=k(o.body,e,t,n)||r);var s=(0,i.YE)();return s&&(r=k(s,e,t,n)||r),r}function U(e,t,n){var r=(0,i.zk)();r&&(D(r,e,t,n),D(r.body,e,t,n));var o=(0,i.YE)();o&&D(o,e,t,n)}function F(e,t,n,o){var i=!1;return t&&e&&e[r.oI]>0&&(0,s.Iu)(e,(function(e){e&&(n&&-1!==(0,s.rD)(n,e)||(i=j(e,t,o)||i))})),i}function z(e,t,n,o){var i=!1;return t&&e&&(0,s.cy)(e)&&!(i=F(e,t,n,o))&&n&&n[r.oI]>0&&(i=F(e,t,null,o)),i}function q(e,t,n){e&&(0,s.cy)(e)&&(0,s.Iu)(e,(function(e){e&&U(e,t,n)}))}function B(e,t,n){return z([y,g,m],e,t,n)}function H(e,t){q([y,g,m],e,t)}function G(e,t,n){var r=N(_,n),o=F([m],e,t,r);return t&&-1!==(0,s.rD)(t,f)||(o=F([f],(function(t){var n=(0,i.YE)();e&&n&&"hidden"===n.visibilityState&&e(t)}),t,r)||o),!o&&t&&(o=G(e,null,n)),o}function V(e,t){var n=N(_,t);q([m],e,n),q([f],null,n)}function $(e,t,n){var r=N(b,n),o=F([v],e,t,r);return!(o=F([f],(function(t){var n=(0,i.YE)();e&&n&&"visible"===n.visibilityState&&e(t)}),t,r)||o)&&t&&(o=$(e,null,n)),o}function K(e,t){var n=N(b,t);q([v],e,n),q([f],null,n)}},2504:(e,t,n)=>{"use strict";n.d(t,{$8:()=>Ce,$P:()=>Q,Bm:()=>te,CP:()=>Oe,Cv:()=>$,EA:()=>U,EH:()=>ce,Ed:()=>L,Et:()=>Z,Gh:()=>z,Gv:()=>B,Iu:()=>oe,Ju:()=>W,KT:()=>ae,KY:()=>_e,Kg:()=>J,Lm:()=>ee,N6:()=>me,Qd:()=>ne,RF:()=>Ae,SA:()=>Ee,SZ:()=>Re,Tn:()=>H,W$:()=>se,_u:()=>re,b0:()=>j,bJ:()=>X,c2:()=>be,cG:()=>pe,cH:()=>G,cy:()=>Y,fw:()=>D,hW:()=>Pe,hX:()=>F,js:()=>ve,lL:()=>ye,mQ:()=>q,o$:()=>Ie,ol:()=>fe,qz:()=>we,r:()=>de,rD:()=>ie,tG:()=>K,wo:()=>Te,x3:()=>ge,z:()=>V,zC:()=>M,zz:()=>Se});var r=n(7245),o=n(9381),i=n(3229),s=n(5397),a="toISOString",c="endsWith",u="startsWith",l="indexOf",p="map",d="reduce",h="trim",f="toString",m="__proto__",v="constructor",g=r.KU,y=r.s6.freeze,_=r.s6.seal,b=r.s6.keys,E=String[r.vR],T=E[h],S=E[c],C=E[u],x=Date[r.vR][a],w=Array.isArray,A=r.Wy[f],I=r.J$[f],R=I[i.Ek](r.s6),P=/-([a-z])/g,O=/([^\w\d_$])/g,N=/^(\d+[\w\d_$])/,k=Object.getPrototypeOf;function D(e){if(e){if(k)return k(e);var t=e[m]||e[r.vR]||e[v];if(t)return t}return null}function M(e){return A[i.Ek](e)}function L(e,t){return typeof e===t}function j(e){return void 0===e||typeof e===r.bA}function U(e){return!j(e)}function F(e){return null===e||j(e)}function z(e){return!F(e)}function q(e,t){return!(!e||!r.J$[i.Ek](e,t))}function B(e){return!(!e||typeof e!==r._1)}function H(e){return!(!e||typeof e!==r.hW)}function G(e){var t=e;return t&&J(t)&&(t=(t=(t=t[i.W7](P,(function(e,t){return t.toUpperCase()})))[i.W7](O,"_"))[i.W7](N,(function(e,t){return"_"+t}))),t}function V(e,t){if(e)for(var n in e)r.J$[i.Ek](e,n)&&t[i.Ek](e,n,e[n])}function $(e,t){var n=!1;return e&&t&&!(n=e===t)&&(n=S?e[c](t):function(e,t){var n=!1,r=t?t[i.oI]:0,o=e?e[i.oI]:0;if(r&&o&&o>=r&&!(n=e===t)){for(var s=o-1,a=r-1;a>=0;a--){if(e[s]!=t[a])return!1;s--}n=!0}return n}(e,t)),n}function K(e,t){var n=!1;return e&&t&&!(n=e===t)&&(n=C?e[u](t):function(e,t){var n=!1,r=t?t[i.oI]:0;if(e&&r&&e[i.oI]>=r&&!(n=e===t)){for(var o=0;o<r;o++)if(e[o]!==t[o])return!1;n=!0}return n}(e,t)),n}function W(e,t){return!(!e||!t)&&-1!==e[i.Sj](t)}function Q(e){return!(!e||"[object Date]"!==A[i.Ek](e))}var Y=w||function(e){return!(!e||"[object Array]"!==A[i.Ek](e))};function X(e){return!(!e||"[object Error]"!==A[i.Ek](e))}function J(e){return"string"==typeof e}function Z(e){return"number"==typeof e}function ee(e){return"boolean"==typeof e}function te(e){return"symbol"==typeof e}function ne(e){var t=!1;if(e&&"object"==typeof e){var n=k?k(e):D(e);n?(n[v]&&r.J$[i.Ek](n,v)&&(n=n[v]),t=typeof n===r.hW&&I[i.Ek](n)===R):t=!0}return t}function re(e){if(e)return x?e[a]():function(e){if(e&&e.getUTCFullYear){var t=function(e){var t=String(e);return 1===t[i.oI]&&(t="0"+t),t};return e.getUTCFullYear()+"-"+t(e.getUTCMonth()+1)+"-"+t(e.getUTCDate())+"T"+t(e.getUTCHours())+":"+t(e.getUTCMinutes())+":"+t(e.getUTCSeconds())+"."+String((e.getUTCMilliseconds()/1e3).toFixed(3)).slice(2,5)+"Z"}}(e)}function oe(e,t,n){var r=e[i.oI];try{for(var o=0;o<r&&(!(o in e)||-1!==t[i.Ek](n||e,e[o],o,e));o++);}catch(e){}}function ie(e,t,n){if(e){if(e[l])return e[l](t,n);var r=e[i.oI],o=n||0;try{for(var s=Math.max(o>=0?o:r-Math.abs(o),0);s<r;s++)if(s in e&&e[s]===t)return s}catch(e){}}return-1}function se(e,t,n){var r;if(e){if(e[p])return e[p](t,n);var o=e[i.oI],s=n||e;r=new Array(o);try{for(var a=0;a<o;a++)a in e&&(r[a]=t[i.Ek](s,e[a],e))}catch(e){}}return r}function ae(e,t,n){var r;if(e){if(e[d])return e[d](t,n);var o=e[i.oI],s=0;if(arguments[i.oI]>=3)r=arguments[2];else{for(;s<o&&!(s in e);)s++;r=e[s++]}for(;s<o;)s in e&&(r=t(r,e[s],s,e)),s++}return r}function ce(e){return e&&(e=T&&e[h]?e[h]():e[i.W7]?e[i.W7](/^\s+|(?=\s)\s+$/g,s.m5):e),e}var ue=!{toString:null}.propertyIsEnumerable("toString"),le=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"];function pe(e){var t=typeof e;if(t===r.hW||t===r._1&&null!==e||(0,o.zk)("objKeys called on non-object"),!ue&&b)return b(e);var n=[];for(var s in e)e&&r.J$[i.Ek](e,s)&&n[i.y5](s);if(ue)for(var a=le[i.oI],c=0;c<a;c++)e&&r.J$[i.Ek](e,le[c])&&n[i.y5](le[c]);return n}function de(e,t,n,r){if(g)try{var o={enumerable:!0,configurable:!0};return n&&(o.get=n),r&&(o.set=r),g(e,t,o),!0}catch(e){}return!1}function he(e){return e}function fe(e){return y&&V(e,(function(e,t){(Y(t)||B(t))&&y(t)})),me(e)}var me=y||he,ve=_||he;function ge(){var e=Date;return e.now?e.now():(new e).getTime()}function ye(e){return X(e)?e[i.RS]:s.m5}function _e(e,t,n,r,o){var i=n;return e&&((i=e[t])===n||o&&!o(i)||r&&!r(n)||(i=n,e[t]=i)),i}function be(e,t,n){var r;return e?!(r=e[t])&&F(r)&&(r=j(n)?{}:n,e[t]=r):r=j(n)?{}:n,r}function Ee(e,t){return F(e)?t:e}function Te(e){return!e}function Se(e){return!!e}function Ce(e){throw new Error(e)}function xe(e,t){var n=null,r=null;return H(e)?n=e:r=e,function(){var e=arguments;if(n&&(r=n()),r)return r[t][i.y9](r,e)}}function we(e,t,n){if(e&&t&&B(e)&&B(t)){var r=function(r){if(J(r)){var o=t[r];H(o)?n&&!n(r,!0,t,e)||(e[r]=xe(t,r)):n&&!n(r,!1,t,e)||(q(e,r)&&delete e[r],de(e,r,(function(){return t[r]}),(function(e){t[r]=e}))||(e[r]=o))}};for(var o in t)r(o)}return e}function Ae(e,t,n,r,o){e&&t&&n&&(!1!==o||j(e[t]))&&(e[t]=xe(n,r))}function Ie(e,t,n,r){return e&&t&&B(e)&&Y(n)&&oe(n,(function(n){J(n)&&Ae(e,n,t,n,r)})),e}function Re(e){return function(){var t=this;e&&V(e,(function(e,n){t[e]=n}))}}function Pe(e){return e&&r.zi&&(e=(0,r.s6)((0,r.zi)({},e))),e}function Oe(e,t,n,o,s,a){var c=arguments,u=c[0]||{},l=c[i.oI],p=!1,d=1;for(l>0&&ee(u)&&(p=u,u=c[d]||{},d++),B(u)||(u={});d<l;d++){var h=c[d],f=Y(h),m=B(h);for(var v in h)if(f&&v in h||m&&r.J$[i.Ek](h,v)){var g=h[v],y=void 0;if(p&&g&&((y=Y(g))||ne(g))){var _=u[v];y?Y(_)||(_=[]):ne(_)||(_={}),g=Oe(p,_,g)}void 0!==g&&(u[v]=g)}}return u}},5397:(e,t,n)=>{"use strict";n.d(t,{Bw:()=>c,Hr:()=>a,LZ:()=>o,Tj:()=>g,Vo:()=>p,Yd:()=>s,Yp:()=>h,Zi:()=>v,dI:()=>f,eT:()=>i,fc:()=>d,jy:()=>u,kI:()=>y,l0:()=>m,m5:()=>r,qT:()=>l});var r="",o="channels",i="core",s="createPerfMgr",a="disabled",c="extensionConfig",u="extensions",l="processTelemetry",p="priority",d="eventsSent",h="eventsDiscarded",f="eventsSendRequest",m="perfEvent",v="errorToConsole",g="warnToConsole",y="getPerfMgr"},4013:(e,t,n)=>{"use strict";n.d(t,{h:()=>c});var r=n(9284),o=n(3229),i=n(2504),s=n(5397);function a(e,t,n,r){(0,i.Iu)(e,(function(e){if(e&&e[t])if(n)setTimeout((function(){return r(e)}),0);else try{r(e)}catch(e){}}))}var c=function(){function e(t){this.listeners=[];var n=!!(t||{}).perfEvtsSendAll;(0,r.A)(e,this,(function(e){e[o.vR]=function(t){e.listeners[o.y5](t)},e[o.TP]=function(t){for(var n=(0,i.rD)(e[o.lJ],t);n>-1;)e.listeners[o.Ic](n,1),n=(0,i.rD)(e[o.lJ],t)},e[s.fc]=function(t){a(e[o.lJ],s.fc,!0,(function(e){e[s.fc](t)}))},e[s.Yp]=function(t,n){a(e[o.lJ],s.Yp,!0,(function(e){e[s.Yp](t,n)}))},e[s.dI]=function(t,n){a(e[o.lJ],s.dI,n,(function(e){e[s.dI](t,n)}))},e[s.l0]=function(t){t&&(!n&&t[o.Zu]()||a(e[o.lJ],s.l0,!1,(function(e){t[o.tI]?setTimeout((function(){return e[s.l0](t)}),0):e[s.l0](t)})))}}))}return e.__ieDyn=1,e}()},5441:(e,t,n)=>{"use strict";n.d(t,{NS:()=>d,Q6:()=>p,Z4:()=>v,jv:()=>m,r2:()=>f});var r=n(9284),o=n(3229),i=n(2504),s=n(5397),a="ctx",c="ParentContextKey",u="ChildrenContextKey",l=null,p=function(){function e(t,n,r){var s,l=this,p=!1;l.start=(0,i.x3)(),l[o.RS]=t,l[o.tI]=r,l[o.Zu]=function(){return!1},(0,i.Tn)(n)&&(p=(0,i.r)(l,"payload",(function(){return!s&&(0,i.Tn)(n)&&(s=n(),n=null),s}))),l[o.O_]=function(t){return t?t===e[c]||t===e[u]?l[t]:(l[a]||{})[t]:null},l[o.e_]=function(t,n){t&&(t===e[c]?(l[t]||(l[o.Zu]=function(){return!0}),l[t]=n):t===e[u]?l[t]=n:(l[a]=l[a]||{})[t]=n)},l[o.Ru]=function(){var t=0,r=l[o.O_](e[u]);if((0,i.cy)(r))for(var s=0;s<r[o.oI];s++){var a=r[s];a&&(t+=a[o.fA])}l[o.fA]=(0,i.x3)()-l.start,l.exTime=l[o.fA]-t,l[o.Ru]=function(){},!p&&(0,i.Tn)(n)&&(l.payload=n())}}return e.ParentContextKey="parent",e.ChildrenContextKey="childEvts",e}(),d=function(){function e(t){this.ctx={},(0,r.A)(e,this,(function(e){e.create=function(e,t,n){return new p(e,t,n)},e.fire=function(e){e&&(e[o.Ru](),t&&(0,i.Tn)(t[s.l0])&&t[s.l0](e))},e[o.e_]=function(t,n){t&&((e[a]=e[a]||{})[t]=n)},e[o.O_]=function(t){return(e[a]||{})[t]}}))}return e.__ieDyn=1,e}(),h="CoreUtils.doPerf";function f(e,t,n,r,i){if(e){var a=e;if(a[s.kI]&&(a=a[s.kI]()),a){var l=void 0,d=a[o.O_](h);try{if(l=a.create(t(),r,i)){if(d&&l[o.e_]&&(l[o.e_](p[c],d),d[o.O_]&&d[o.e_])){var f=d[o.O_](p[u]);f||(f=[],d[o.e_](p[u],f)),f[o.y5](l)}return a[o.e_](h,l),n(l)}}catch(e){l&&l[o.e_]&&l[o.e_]("exception",e)}finally{l&&a.fire(l),a[o.e_](h,d)}}}return n()}function m(e){l=e}function v(){return l}},8012:(e,t,n)=>{"use strict";n.d(t,{PV:()=>y,W0:()=>_,i8:()=>m,nU:()=>g,tS:()=>v});var r=n(3229),o=n(6392),i=n(8323),s=n(2504),a=n(5397),c=n(5441),u=n(1267),l="TelemetryPluginChain",p="_hasRun",d="_getTelCtx",h=0;function f(e,t,n,c){var u=null,l=[];null!==c&&(u=c?function(e,t,n){for(;e;){if(e[r.AP]()===n)return e;e=e[r.uR]()}return y([n],t[r.GA]||{},t)}(e,n,c):e);var p={_next:function(){var e=u;if(u=e?e[r.uR]():null,!e){var t=l;t&&t[r.oI]>0&&((0,s.Iu)(t,(function(e){try{e.func[r.Ek](e.self,e.args)}catch(e){(0,o.ZP)(n[r.Uw],2,73,"Unexpected Exception during onComplete - "+(0,i.mm)(e))}})),l=[])}return e},ctx:{core:function(){return n},diagLog:function(){return(0,o.y0)(n,t)},getCfg:function(){return t},getExtCfg:d,getConfig:function(e,n,r){void 0===r&&(r=!1);var o,i=d(e,null);return i&&!(0,s.hX)(i[n])?o=i[n]:t&&!(0,s.hX)(t[n])&&(o=t[n]),(0,s.hX)(o)?r:o},hasNext:function(){return!!u},getNext:function(){return u},setNext:function(e){u=e},iterate:function(e){for(var t;t=p._next();){var n=t[r.AP]();n&&e(n)}},onComplete:function(e,t){for(var n=[],o=2;o<arguments.length;o++)n[o-2]=arguments[o];e&&l[r.y5]({func:e,self:(0,s.b0)(t)?p.ctx:t,args:n})}}};function d(e,n,r){var o;if(void 0===n&&(n={}),void 0===r&&(r=0),t){var i=t[a.Bw];i&&e&&(o=i[e])}if(o){if((0,s.Gv)(n)&&0!==r){var c=(0,s.CP)(!0,n,o);t&&2===r&&(0,s.z)(n,(function(e){if((0,s.hX)(c[e])){var n=t[e];(0,s.hX)(n)||(c[e]=n)}})),o=c}}else o=n;return o}return p}function m(e,t,n,o){var i=f(e,t,n,o),c=i.ctx;return c[r.$5]=function(e){var t=i._next();return t&&t[a.qT](e,c),!t},c[r.$o]=function(e,o){return void 0===e&&(e=null),(0,s.cy)(e)&&(e=y(e,t,n,o)),m(e||c[r.uR](),t,n,o)},c}function v(e,t,n){var o=t[r.GA]||{},i=f(e,o,t,n),a=i.ctx;return a[r.$5]=function(e){var t=i._next();return t&&t.unload(a,e),!t},a[r.$o]=function(e,n){return void 0===e&&(e=null),(0,s.cy)(e)&&(e=y(e,o,t,n)),v(e||a[r.uR](),t,n)},a}function g(e,t,n){var o=t[r.GA]||{},i=f(e,o,t,n).ctx;return i[r.$5]=function(e){return i.iterate((function(t){(0,s.Tn)(t[r.HC])&&t[r.HC](i,e)}))},i[r.$o]=function(e,n){return void 0===e&&(e=null),(0,s.cy)(e)&&(e=y(e,o,t,n)),g(e||i[r.uR](),t,n)},i}function y(e,t,n,f){var v=null,g=!f;if((0,s.cy)(e)&&e[r.oI]>0){var _=null;(0,s.Iu)(e,(function(e){if(g||f!==e||(g=!0),g&&e&&(0,s.Tn)(e[a.qT])){var y=function(e,t,n){var f,v=null,g=(0,s.Tn)(e[a.qT]),y=(0,s.Tn)(e[r.YH]),_={getPlugin:function(){return e},getNext:function(){return v},processTelemetry:function(o,i){b(i=i||function(){var r;return e&&(0,s.Tn)(e[d])&&(r=e[d]()),r||(r=m(_,t,n)),r}(),(function(t){if(!e||!g)return!1;var n=(0,u.Cr)(e);return!n[r.Ik]&&!n[a.Hr]&&(y&&e[r.YH](v),e[a.qT](o,t),!0)}),"processTelemetry",(function(){return{item:o}}),!o.sync)||i[r.$5](o)},unload:function(t,n){b(t,(function(){var o=!1;if(e){var i=(0,u.Cr)(e),s=e[a.eT]||i[a.eT];!e||s&&s!==t.core()||i[r.Ik]||(i[a.eT]=null,i[r.Ik]=!0,i[r.tZ]=!1,e[r.Ik]&&!0===e[r.Ik](t,n)&&(o=!0))}return o}),"unload",(function(){}),n[r.tI])||t[r.$5](n)},update:function(t,n){b(t,(function(){var o=!1;if(e){var i=(0,u.Cr)(e),s=e[a.eT]||i[a.eT];!e||s&&s!==t.core()||i[r.Ik]||e[r.HC]&&!0===e[r.HC](t,n)&&(o=!0)}return o}),"update",(function(){}),!1)||t[r.$5](n)},_id:f=e?e[r.Ju]+"-"+e[a.Vo]+"-"+h++:"Unknown-0-"+h++,_setNext:function(e){v=e}};function b(t,n,s,u,d){var h=!1,m=e?e[r.Ju]:l,g=t[p];return g||(g=t[p]={}),t.setNext(v),e&&(0,c.r2)(t[a.eT](),(function(){return m+":"+s}),(function(){g[f]=!0;try{var e=v?v._id:a.m5;e&&(g[e]=!1),h=n(t)}catch(e){var c=!v||g[v._id];c&&(h=!0),v&&c||(0,o.ZP)(t[r.e4](),1,73,"Plugin ["+m+"] failed during "+s+" - "+(0,i.mm)(e)+", run flags: "+(0,i.mm)(g))}}),u,d),h}return(0,s.N6)(_)}(e,t,n);v||(v=y),_&&_._setNext(y),_=y}}))}return f&&!v?y([f],t,n):v}var _=function(e,t,n,r){var o=m(e,t,n,r);(0,s.o$)(this,o,(0,s.cG)(o))}},9668:(e,t,n)=>{"use strict";n.d(t,{Si:()=>y,VN:()=>m,Z1:()=>f,k5:()=>g,yc:()=>v});var r=n(3229),o=n(8323),i=n(2504),s=n(5397),a=4294967296,c=4294967295,u=!1,l=123456789,p=987654321;function d(e){e<0&&(e>>>=0),l=123456789+e&c,p=987654321-e&c,u=!0}function h(){try{var e=2147483647&(0,i.x3)();d((Math.random()*a^e)+e)}catch(e){}}function f(e){return e>0?Math.floor(m()/c*(e+1))>>>0:0}function m(e){var t=0,n=(0,o.MY)()||(0,o.iN)();return n&&n.getRandomValues&&(t=n.getRandomValues(new Uint32Array(1))[0]&c),0===t&&(0,o.lT)()&&(u||h(),t=g()&c),0===t&&(t=Math.floor(a*Math.random()|0)),e||(t>>>=0),t}function v(e){e?d(e):h()}function g(e){var t=((p=36969*(65535&p)+(p>>16)&c)<<16)+(65535&(l=18e3*(65535&l)+(l>>16)&c))>>>0&c;return e||(t>>>=0),t}function y(e){void 0===e&&(e=22);for(var t=m()>>>0,n=0,o=s.m5;o[r.oI]<e;)n++,o+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(63&t),t>>>=6,5===n&&(t=(m()<<2&4294967295|3&t)>>>0,n=0);return o}},1267:(e,t,n)=>{"use strict";n.d(t,{Cr:()=>u,Xc:()=>p,pI:()=>l,s4:()=>d,u7:()=>h});var r=n(3229),o=n(2429),i=n(2504),s=n(5397),a=n(2675),c=(0,o.T)("plugin");function u(e){return c.get(e,"state",{},!0)}function l(e,t){for(var n,o=[],a=null,c=e[r.uR]();c;){var l=c[r.AP]();l&&(a&&(0,i.Tn)(a[r.YH])&&(0,i.Tn)(l[s.qT])&&a[r.YH](l),((0,i.Tn)(l[r.tZ])?l[r.tZ]():(n=u(l))[r.tZ])||o[r.y5](l),a=l,c=c[r.uR]())}(0,i.Iu)(o,(function(o){var i=e[s.eT]();o[r.mE](e.getCfg(),i,t,e[r.uR]()),n=u(o),o[s.eT]||n[s.eT]||(n[s.eT]=i),n[r.tZ]=!0,delete n[r.Ik]}))}function p(e){return e.sort((function(e,t){var n=0;if(t){var r=(0,i.Tn)(t[s.qT]);(0,i.Tn)(e[s.qT])?n=r?e[s.Vo]-t[s.Vo]:1:r&&(n=-1)}else n=e?1:-1;return n}))}function d(e,t,n,o){var s=0;return function o(){for(;s<e[r.oI];){var a=e[s++];if(a){var c=a._doUnload||a[r.tn];if((0,i.Tn)(c)&&!0===c[r.Ek](a,t,n,o))return!0}}}()}function h(e){var t={};return{getName:function(){return t[r.RS]},setName:function(n){e&&e.setName(n),t[r.RS]=n},getTraceId:function(){return t[r.P5]},setTraceId:function(n){e&&e.setTraceId(n),(0,a.hX)(n)&&(t[r.P5]=n)},getSpanId:function(){return t[r.wi]},setSpanId:function(n){e&&e.setSpanId(n),(0,a.wN)(n)&&(t[r.wi]=n)},getTraceFlags:function(){return t[r.Rr]},setTraceFlags:function(n){e&&e.setTraceFlags(n),t[r.Rr]=n}}}},2755:(e,t,n)=>{"use strict";n.d(t,{P:()=>a});var r=n(3229),o=n(6392),i=n(8323),s=n(2504);function a(){var e=[];return{add:function(t){t&&e[r.y5](t)},run:function(t,n){(0,s.Iu)(e,(function(e){try{e(t,n)}catch(e){(0,o.ZP)(t[r.e4](),2,73,"Unexpected error calling unload handler - "+(0,i.mm)(e))}})),e=[]}}}},2675:(e,t,n)=>{"use strict";n.d(t,{L0:()=>T,N7:()=>E,ZI:()=>g,ef:()=>S,hX:()=>y,mJ:()=>b,wN:()=>_,wk:()=>v});var r=n(3229),o=n(5955),i=n(8323),s=n(2504),a=/^([\da-f]{2})-([\da-f]{32})-([\da-f]{16})-([\da-f]{2})(-[^\s]*)?$/,c="00",u="ff",l="00000000000000000000000000000000",p="0000000000000000",d=1;function h(e,t,n){return!(!e||e[r.oI]!==t||e===n||!e.match(/^[\da-f]*$/))}function f(e,t,n){return h(e,t)?e:n}function m(e){(isNaN(e)||e<0||e>255)&&(e=1);for(var t=e.toString(16);t[r.oI]<2;)t="0"+t;return t}function v(e,t,n,i){var s;return(s={})[r.s]=h(i,2,u)?i:c,s[r.P5]=y(e)?e:(0,o.cL)(),s.spanId=_(t)?t:(0,o.cL)()[r.$4](0,16),s.traceFlags=n>=0&&n<=255?n:1,s}function g(e){var t;if(!e)return null;if((0,s.cy)(e)&&(e=e[0]||""),!e||!(0,s.Kg)(e)||e[r.oI]>8192)return null;var n=a.exec((0,s.EH)(e));return n&&n[1]!==u&&n[2]!==l&&n[3]!==p?((t={})[r.s]=n[1],t[r.P5]=n[2],t[r.wi]=n[3],t[r.Rr]=parseInt(n[4],16),t):null}function y(e){return h(e,32,l)}function _(e){return h(e,16,p)}function b(e){return!!(e&&h(e[r.s],2,u)&&h(e[r.P5],32,l)&&h(e[r.wi],16,p)&&h(m(e[r.Rr]),2))}function E(e){return!!b(e)&&(e[r.Rr]&d)===d}function T(e){if(e){var t=m(e[r.Rr]);h(t,2)||(t="01");var n=e[r.s]||c;return"00"!==n&&"ff"!==n&&(n=c),"".concat(n,"-").concat(f(e.traceId,32,l),"-").concat(f(e.spanId,16,p),"-").concat(t)}return""}function S(){var e="traceparent",t=g((0,i.$Z)(e));return t||(t=g((0,i.Iu)(e))),t}},3229:(e,t,n)=>{"use strict";n.d(t,{$4:()=>z,$5:()=>f,$o:()=>k,AP:()=>b,Di:()=>y,EX:()=>E,Ek:()=>K,GA:()=>u,H7:()=>T,HC:()=>R,Ic:()=>S,Ik:()=>C,JR:()=>x,Ju:()=>s,OL:()=>$,O_:()=>J,P5:()=>te,QM:()=>W,RF:()=>i,RS:()=>o,Re:()=>L,Rr:()=>re,Ru:()=>ee,Sj:()=>M,TP:()=>g,Uw:()=>p,W7:()=>H,YH:()=>N,Yo:()=>Q,Zu:()=>X,a$:()=>G,by:()=>_,e4:()=>O,e_:()=>Z,fA:()=>h,kt:()=>F,lJ:()=>Y,lK:()=>D,mE:()=>r,oI:()=>d,pM:()=>w,ps:()=>m,re:()=>q,s:()=>oe,sY:()=>U,sl:()=>l,sx:()=>V,tI:()=>A,tX:()=>j,tZ:()=>c,tn:()=>I,uR:()=>P,vR:()=>v,wi:()=>ne,y5:()=>a,y9:()=>B});var r="initialize",o="name",i="getNotifyMgr",s="identifier",a="push",c="isInitialized",u="config",l="instrumentationKey",p="logger",d="length",h="time",f="processNext",m="getProcessTelContext",v="addNotificationListener",g="removeNotificationListener",y="stopPollingInternalLogs",_="onComplete",b="getPlugin",E="flush",T="_extensions",S="splice",C="teardown",x="messageId",w="message",A="isAsync",I="_doTeardown",R="update",P="getNext",O="diagLog",N="setNextPlugin",k="createNew",D="cookieCfg",M="indexOf",L="substring",j="userAgent",U="split",F="setEnabled",z="substr",q="nodeType",B="apply",H="replace",G="enableDebugExceptions",V="logInternalMessage",$="toLowerCase",K="call",W="type",Q="handler",Y="listeners",X="isChildEvt",J="getCtx",Z="setCtx",ee="complete",te="traceId",ne="spanId",re="traceFlags",oe="version"},3695:(e,t,n)=>{"use strict";n.r(t),n.d(t,{AppInsightsCore:()=>i._,BaseCore:()=>s.F,BaseTelemetryPlugin:()=>a.s,CoreUtils:()=>u.jS,DiagnosticLogger:()=>y.wq,EventHelper:()=>u.fs,EventsDiscardedReason:()=>o.x,InstrumentEvent:()=>k,InstrumentFunc:()=>O,InstrumentFuncs:()=>N,InstrumentProto:()=>I,InstrumentProtos:()=>R,LoggingSeverity:()=>E.b,MinChannelPriorty:()=>r.T,NotificationManager:()=>v.h,PerfEvent:()=>g.Q6,PerfManager:()=>g.NS,ProcessTelemetryContext:()=>_.W0,Undefined:()=>u.rK,_InternalLogMessage:()=>y.WD,_InternalMessageId:()=>E.$,__getRegisteredEvents:()=>d.El,_legacyCookieMgr:()=>u.Rb,_logInternalMessage:()=>y.Oc,_throwInternal:()=>y.ZP,_warnToConsole:()=>y.OG,addEventHandler:()=>d.So,addEventListeners:()=>d.lQ,addPageHideEventListener:()=>d.Fc,addPageShowEventListener:()=>d.oS,addPageUnloadEventListener:()=>d.ee,areCookiesSupported:()=>D.gi,arrForEach:()=>l.Iu,arrIndexOf:()=>l.rD,arrMap:()=>l.W$,arrReduce:()=>l.KT,attachEvent:()=>d.Q3,canUseCookies:()=>u.ht,createClassFromInterface:()=>l.SZ,createCookieMgr:()=>D.xN,createCustomDomEvent:()=>h.Sf,createEnumMap:()=>p.oc,createEnumStyle:()=>p.Hj,createProcessTelemetryContext:()=>_.i8,createTraceParent:()=>U.wk,createUniqueNamespace:()=>L.Z,createUnloadHandlerContainer:()=>j.P,createValueMap:()=>p.oP,dateNow:()=>l.x3,deepFreeze:()=>l.ol,deleteCookie:()=>u.Yj,detachEvent:()=>d.Ym,disableCookies:()=>u.WD,dispatchEvent:()=>h.Pt,doPerf:()=>g.r2,dumpObj:()=>h.mm,eventOff:()=>d.ML,eventOn:()=>d.mB,findMetaTag:()=>h.$Z,findNamedServerTiming:()=>h.Iu,findW3cTraceParent:()=>U.ef,formatTraceParent:()=>U.L0,generateW3CId:()=>u.cL,getConsole:()=>h.U5,getCookie:()=>u.Ri,getCrypto:()=>h.MY,getDebugExt:()=>M.$,getDebugListener:()=>M.M,getDocument:()=>h.YE,getExceptionName:()=>l.lL,getGblPerfMgr:()=>g.Z4,getGlobal:()=>f.mS,getGlobalInst:()=>h.EH,getHistory:()=>h.JK,getIEVersion:()=>h.L0,getJSON:()=>h.hm,getLocation:()=>h.g$,getMsCrypto:()=>h.iN,getNavigator:()=>h.w3,getPerformance:()=>h.FJ,getSetValue:()=>l.c2,getWindow:()=>h.zk,hasDocument:()=>h.Wt,hasHistory:()=>h.tw,hasJSON:()=>h.Z,hasNavigator:()=>h.w9,hasOwnProperty:()=>l.mQ,hasWindow:()=>h.Vd,initializePlugins:()=>b.pI,isArray:()=>l.cy,isBeaconsSupported:()=>h.Uf,isBoolean:()=>l.Lm,isDate:()=>l.$P,isError:()=>l.bJ,isFetchSupported:()=>h.R7,isFunction:()=>l.Tn,isIE:()=>h.lT,isNotNullOrUndefined:()=>l.Gh,isNotTruthy:()=>l.wo,isNotUndefined:()=>l.EA,isNullOrUndefined:()=>l.hX,isNumber:()=>l.Et,isObject:()=>l.Gv,isPlainObject:()=>l.Qd,isReactNative:()=>h.lV,isSafari:()=>h.nr,isSampledFlag:()=>U.N7,isString:()=>l.Kg,isSymbol:()=>l.Bm,isTruthy:()=>l.zz,isTypeof:()=>l.Ed,isUndefined:()=>l.b0,isValidSpanId:()=>U.wN,isValidTraceId:()=>U.hX,isValidTraceParent:()=>U.mJ,isXhrSupported:()=>h.xk,mergeEvtNamespace:()=>d.Hm,mwcRandom32:()=>c.k5,mwcRandomSeed:()=>c.yc,newGuid:()=>u.aq,newId:()=>c.Si,normalizeJsName:()=>l.cH,objCreate:()=>f.AQ,objDefineAccessors:()=>l.r,objExtend:()=>l.CP,objForEachKey:()=>l.z,objFreeze:()=>l.N6,objKeys:()=>l.cG,objSeal:()=>l.js,objToString:()=>l.zC,optimizeObject:()=>l.hW,parseTraceParent:()=>U.ZI,perfNow:()=>u.UU,proxyAssign:()=>l.qz,proxyFunctionAs:()=>l.RF,proxyFunctions:()=>l.o$,random32:()=>c.VN,randomValue:()=>c.Z1,removeEventHandler:()=>d.zh,removeEventListeners:()=>d.Wg,removePageHideEventListener:()=>d.sq,removePageShowEventListener:()=>d.vF,removePageUnloadEventListener:()=>d.Ds,safeGetCookieMgr:()=>D.um,safeGetLogger:()=>y.y0,sendCustomEvent:()=>h.sN,setCookie:()=>u.TV,setEnableEnvMocks:()=>h.cU,setGblPerfMgr:()=>g.jv,setValue:()=>l.KY,sortPlugins:()=>b.Xc,strContains:()=>l.Ju,strEndsWith:()=>l.Cv,strFunction:()=>m.hW,strObject:()=>m._1,strPrototype:()=>m.vR,strStartsWith:()=>l.tG,strTrim:()=>l.EH,strUndefined:()=>m.bA,throwError:()=>l.$8,toISOString:()=>l._u,uaDisallowsSameSiteNone:()=>D.It,unloadComponents:()=>b.s4,useXDomainRequest:()=>h.PV});var r=n(8963),o=n(4343),i=n(6382),s=n(3227),a=n(7428),c=n(9668),u=n(5955),l=n(2504),p=n(3435),d=n(4838),h=n(8323),f=n(9381),m=n(7245),v=n(4013),g=n(5441),y=n(6392),_=n(8012),b=n(1267),E=n(6166),T=n(3229),S="_aiHooks",C=["req","rsp","hkErr","fnErr"];function x(e,t){if(e)for(var n=0;n<e[T.oI]&&!t(e[n],n);n++);}function w(e,t,n,r,o){o>=0&&o<=2&&x(e,(function(e,i){var s=e.cbks,a=s[C[o]];if(a){t.ctx=function(){return r[i]=r[i]||{}};try{a[T.y9](t.inst,n)}catch(e){var c=t.err;try{var u=s[C[2]];u&&(t.err=e,u[T.y9](t.inst,n))}catch(e){}finally{t.err=c}}}}))}function A(e,t,n,r){var o=null;return e&&((0,l.mQ)(e,t)?o=e:n&&(o=A((0,l.fw)(e),t,r,!1))),o}function I(e,t,n){return e?O(e[m.vR],t,n,!1):null}function R(e,t,n){return e?N(e[m.vR],t,n,!1):null}function P(e,t,n,r){var o=n&&n[S];if(!o){var i=function(e){return function(){var t,n=arguments,r=e.h,o=((t={})[T.RS]=e.n,t.inst=this,t.ctx=null,t.set=function(e,t){(n=a([],n))[e]=t,s=a([o],n)},t),i=[],s=a([o],n);function a(e,t){return x(t,(function(t){e[T.y5](t)})),e}o.evt=(0,h.EH)("event"),w(r,o,s,i,0);var c=e.f;if(c)try{o.rslt=c[T.y9](this,n)}catch(e){throw o.err=e,w(r,o,s,i,3),e}return w(r,o,s,i,1),o.rslt}}(o={i:0,n:t,f:n,h:[]});i[S]=o,e[t]=i}var s={id:o.i,cbks:r,rm:function(){var e=this.id;x(o.h,(function(t,n){if(t.id===e)return o.h[T.Ic](n,1),1}))}};return o.i++,o.h[T.y5](s),s}function O(e,t,n,r,o){if(void 0===r&&(r=!0),e&&t&&n){var i=A(e,t,r,o);if(i){var s=i[t];if(typeof s===m.hW)return P(i,t,s,n)}}return null}function N(e,t,n,r,o){void 0===r&&(r=!0);var i=null;return x(t,(function(t){var s=O(e,t,n,r,o);s&&(i||(i=[]),i[T.y5](s))})),i}function k(e,t,n,r,o){if(e&&t&&n){var i=A(e,t,r,o)||e;if(i)return P(i,t,i[t],n)}return null}var D=n(5691),M=n(8074),L=n(2429),j=n(2755),U=n(2675)},9284:(e,t,n)=>{"use strict";var r;n.d(t,{A:()=>U});var o,i="undefined",s="constructor",a="prototype",c="function",u="_dynInstFuncs",l="_isDynProxy",p="_dynClass",d="_dynCls$",h="_dynInstChk",f=h,m="_dfOpts",v="_unknown_",g="__proto__",y="_dyn"+g,_="__dynProto$Gbl",b="_dynInstProto",E="useBaseInst",T="setInstFuncs",S=Object,C=S.getPrototypeOf,x=S.getOwnPropertyNames,w=(typeof globalThis!==i&&(o=globalThis),o||typeof self===i||(o=self),o||typeof window===i||(o=window),o||typeof global===i||(o=global),o||{}),A=w[_]||(w[_]={o:(r={},r[T]=!0,r[E]=!0,r),n:1e3});function I(e,t){return e&&S[a].hasOwnProperty.call(e,t)}function R(e){return e&&(e===S[a]||e===Array[a])}function P(e){return R(e)||e===Function[a]}function O(e){var t;if(e){if(C)return C(e);var n=e[g]||e[a]||(e[s]?e[s][a]:null);t=e[y]||n,I(e,y)||(delete e[b],t=e[y]=e[b]||e[y],e[b]=n)}return t}function N(e,t){var n=[];if(x)n=x(e);else for(var r in e)"string"==typeof r&&I(e,r)&&n.push(r);if(n&&n.length>0)for(var o=0;o<n.length;o++)t(n[o])}function k(e,t,n){return t!==s&&typeof e[t]===c&&(n||I(e,t))}function D(e){throw new TypeError("DynamicProto: "+e)}function M(e,t){for(var n=e.length-1;n>=0;n--)if(e[n]===t)return!0;return!1}function L(e,t,n,r,o){if(!R(e)){var i=n[u]=n[u]||{},s=i[t]=i[t]||{};!1!==i[f]&&(i[f]=!!o),N(n,(function(t){k(n,t,!1)&&n[t]!==r[t]&&(s[t]=n[t],delete n[t],(!I(e,t)||e[t]&&!e[t][l])&&(e[t]=function(e,t){var n=function(){var r=function(e,t,n,r){var o=null;if(e&&I(n,p)){var i=e[u]||{};if((o=(i[n[p]]||{})[t])||D("Missing ["+t+"] "+c),!o[h]&&!1!==i[f]){for(var s=!I(e,t),a=O(e),l=[];s&&a&&!P(a)&&!M(l,a);){var d=a[t];if(d){s=d===r;break}l.push(a),a=O(a)}try{s&&(e[t]=o),o[h]=1}catch(e){i[f]=!1}}}return o}(this,t,e,n)||function(e,t,n){var r=t[e];return r===n&&(r=O(t)[e]),typeof r!==c&&D("["+e+"] is not a "+c),r}(t,e,n);return r.apply(this,arguments)};return n[l]=1,n}(e,t)))}))}}function j(e,t){return I(e,a)?e.name||t||v:((e||{})[s]||{}).name||t||v}function U(e,t,n,r){I(e,a)||D("theClass is an invalid class definition.");var o=e[a];(function(e,t){if(C){for(var n=[],r=O(t);r&&!P(r)&&!M(n,r);){if(r===e)return!0;n.push(r),r=O(r)}return!1}return!0})(o,t)||D("["+j(e)+"] not in hierarchy of ["+j(t)+"]");var i=null;I(o,p)?i=o[p]:(i=d+j(e,"_")+"$"+A.n,A.n++,o[p]=i);var s=U[m],c=!!s[E];c&&r&&void 0!==r[E]&&(c=!!r[E]);var h=function(e){var t={};return N(e,(function(n){!t[n]&&k(e,n,!1)&&(t[n]=e[n])})),t}(t),v=function(e,t,n,r){function o(e,t,n){var o=t[n];if(o[l]&&r){var i=e[u]||{};!1!==i[f]&&(o=(i[t[p]]||{})[n]||o)}return function(){return o.apply(e,arguments)}}var i={};N(n,(function(e){i[e]=o(t,n,e)}));for(var s=O(e),a=[];s&&!P(s)&&!M(a,s);)N(s,(function(e){!i[e]&&k(s,e,!C)&&(i[e]=o(t,s,e))})),a.push(s),s=O(s);return i}(o,t,h,c);n(t,v);var g=!!C&&!!s[T];g&&r&&(g=!!r[T]),L(o,i,t,h,!1!==g)}U[m]=A.o},7245:(e,t,n)=>{"use strict";n.d(t,{FC:()=>c,J$:()=>f,KU:()=>h,OR:()=>d,QV:()=>a,Wy:()=>l,_1:()=>o,bA:()=>i,hW:()=>r,s6:()=>u,vR:()=>s,zi:()=>p});var r="function",o="object",i="undefined",s="prototype",a="hasOwnProperty",c="default",u=Object,l=u[s],p=u.assign,d=u.create,h=u.defineProperty,f=l[a]},9381:(e,t,n)=>{"use strict";n.d(t,{AQ:()=>a,mS:()=>i,zk:()=>s});var r=n(7245),o=null;function i(e){void 0===e&&(e=!0);var t=!1===e?null:o;return t||(typeof globalThis!==r.bA&&(t=globalThis),t||typeof self===r.bA||(t=self),t||typeof window===r.bA||(t=window),t||typeof global===r.bA||(t=global),o=t),t}function s(e){throw new TypeError(e)}function a(e){var t=r.OR;if(t)return t(e);if(null==e)return{};var n=typeof e;function o(){}return n!==r._1&&n!==r.hW&&s("Object prototype may only be an Object:"+e),o[r.vR]=e,new o}},212:(e,t,n)=>{"use strict";n.d(t,{BY:()=>_,G4:()=>b,I3:()=>v,Im:()=>d,JA:()=>m,Ri:()=>E,_J:()=>S,m6:()=>x,pP:()=>A,qU:()=>f,s4:()=>w,sx:()=>g,tl:()=>T,u7:()=>y,vz:()=>C});var r=n(7245),o=n(9381),i=((0,o.mS)()||{}).Symbol,s=((0,o.mS)()||{}).Reflect,a=!!s,c="decorate",u="metadata",l="getOwnPropertySymbols",p="iterator",d=r.zi||function(e){for(var t,n=1,o=arguments.length;n<o;n++)for(var i in t=arguments[n])r.Wy[r.QV].call(t,i)&&(e[i]=t[i]);return e},h=function(e,t){return h=r.s6.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t[r.QV](n)&&(e[n]=t[n])},h(e,t)};function f(e,t){function n(){this.constructor=e}typeof t!==r.hW&&null!==t&&(0,o.zk)("Class extends value "+String(t)+" is not a constructor or null"),h(e,t),e[r.vR]=null===t?(0,o.AQ)(t):(n[r.vR]=t[r.vR],new n)}function m(e,t){var n={};for(var o in e)r.J$.call(e,o)&&t.indexOf(o)<0&&(n[o]=e[o]);if(null!=e&&typeof r.s6[l]===r.hW)for(var i=0,s=r.s6[l](e);i<s.length;i++)t.indexOf(s[i])<0&&r.Wy.propertyIsEnumerable.call(e,s[i])&&(n[s[i]]=e[s[i]]);return n}function v(e,t,n,o){var i,u=arguments.length,l=u<3?t:null===o?o=r.s6.getOwnPropertyDescriptor(t,n):o;if(a&&typeof s[c]===r.hW)l=s[c](e,t,n,o);else for(var p=e.length-1;p>=0;p--)(i=e[p])&&(l=(u<3?i(l):u>3?i(t,n,l):i(t,n))||l);return u>3&&l&&(0,r.KU)(t,n,l),l}function g(e,t){return function(n,r){t(n,r,e)}}function y(e,t){if(a&&s[u]===r.hW)return s[u](e,t)}function _(e,t){for(var n in e)n===r.FC||r.J$.call(t,n)||b(t,e,n)}function b(e,t,n,o){void 0===o&&(o=n),r.OR?(0,r.KU)(e,o,{enumerable:!0,get:function(){return t[n]}}):e[o]=t[n]}function E(e){var t=typeof i===r.hW&&i[p],n=t&&e[t],s=0;return n?n.call(e):e&&"number"==typeof e.length?{next:function(){return e&&s>=e.length&&(e=void 0),{value:e&&e[s++],done:!e}}}:void(0,o.zk)(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function T(e,t){var n=typeof i===r.hW&&e[i[p]];if(!n)return e;var o,s,a=n.call(e),c=[];try{for(;(void 0===t||t-- >0)&&!(o=a.next()).done;)c.push(o.value)}catch(e){s={error:e}}finally{try{o&&!o.done&&(n=a.return)&&n.call(a)}finally{if(s)throw s.error}}return c}function S(){for(var e=arguments,t=0,n=0,r=e.length;n<r;n++)t+=e[n].length;var o=Array(t),i=0;for(n=0;n<r;n++)for(var s=e[n],a=0,c=s.length;a<c;a++,i++)o[i]=s[a];return o}function C(e,t){for(var n=0,r=t.length,o=e.length;n<r;n++,o++)e[o]=t[n];return e}function x(e,t){return r.KU?(0,r.KU)(e,"raw",{value:t}):e.raw=t,e}function w(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)n!==r.FC&&Object.prototype.hasOwnProperty.call(e,n)&&b(t,e,n);return r.OR?(0,r.KU)(t,r.FC,{enumerable:!0,value:e}):t[r.FC]=e,t}function A(e){return e&&e.__esModule?e:{strDefault:e}}},2284:(e,t,n)=>{"use strict";n.r(t),n.d(t,{ObjAssign:()=>r.zi,ObjClass:()=>r.s6,ObjCreate:()=>r.OR,ObjDefineProperty:()=>r.KU,ObjHasOwnProperty:()=>r.J$,ObjProto:()=>r.Wy,__assignFn:()=>i.Im,__createBindingFn:()=>i.G4,__decorateFn:()=>i.I3,__exportStarFn:()=>i.BY,__exposeGlobalTsLib:()=>s,__extendsFn:()=>i.qU,__importDefaultFn:()=>i.pP,__importStarFn:()=>i.s4,__makeTemplateObjectFn:()=>i.m6,__metadataFn:()=>i.u7,__paramFn:()=>i.sx,__readFn:()=>i.tl,__restFn:()=>i.JA,__spreadArrayFn:()=>i.vz,__spreadArraysFn:()=>i._J,__valuesFn:()=>i.Ri,getGlobal:()=>o.mS,objCreateFn:()=>o.AQ,strDefault:()=>r.FC,strShimFunction:()=>r.hW,strShimHasOwnProperty:()=>r.QV,strShimObject:()=>r._1,strShimPrototype:()=>r.vR,strShimUndefined:()=>r.bA,throwTypeError:()=>o.zk});var r=n(7245),o=n(9381),i=n(212);function s(){var e,t,n,s,a=(0,o.mS)()||{};e=a,t=i.Im,n=i.qU,s=i.G4,e.__assign||(e.__assign=r.zi||t),e.__extends||(e.__extends=n),e.__createBinding||(e.__createBinding=s),__assign||(__assign=a.__assign),__extends||(__extends=a.__extends),__createBinding||(__createBinding=a.__createBinding)}},1356:(e,t,n)=>{"use strict";var r;n.r(t),n.d(t,{default:()=>U});var o,i="undefined",s="constructor",a="prototype",c="function",u="_dynInstFuncs",l="_isDynProxy",p="_dynClass",d="_dynCls$",h="_dynInstChk",f=h,m="_dfOpts",v="_unknown_",g="__proto__",y="_dyn"+g,_="__dynProto$Gbl",b="_dynInstProto",E="useBaseInst",T="setInstFuncs",S=Object,C=S.getPrototypeOf,x=S.getOwnPropertyNames,w=(typeof globalThis!==i&&(o=globalThis),o||typeof self===i||(o=self),o||typeof window===i||(o=window),o||typeof global===i||(o=global),o||{}),A=w[_]||(w[_]={o:(r={},r[T]=!0,r[E]=!0,r),n:1e3});function I(e,t){return e&&S[a].hasOwnProperty.call(e,t)}function R(e){return e&&(e===S[a]||e===Array[a])}function P(e){return R(e)||e===Function[a]}function O(e){var t;if(e){if(C)return C(e);var n=e[g]||e[a]||(e[s]?e[s][a]:null);t=e[y]||n,I(e,y)||(delete e[b],t=e[y]=e[b]||e[y],e[b]=n)}return t}function N(e,t){var n=[];if(x)n=x(e);else for(var r in e)"string"==typeof r&&I(e,r)&&n.push(r);if(n&&n.length>0)for(var o=0;o<n.length;o++)t(n[o])}function k(e,t,n){return t!==s&&typeof e[t]===c&&(n||I(e,t))}function D(e){throw new TypeError("DynamicProto: "+e)}function M(e,t){for(var n=e.length-1;n>=0;n--)if(e[n]===t)return!0;return!1}function L(e,t,n,r,o){if(!R(e)){var i=n[u]=n[u]||{},s=i[t]=i[t]||{};!1!==i[f]&&(i[f]=!!o),N(n,(function(t){k(n,t,!1)&&n[t]!==r[t]&&(s[t]=n[t],delete n[t],(!I(e,t)||e[t]&&!e[t][l])&&(e[t]=function(e,t){var n=function(){var r=function(e,t,n,r){var o=null;if(e&&I(n,p)){var i=e[u]||{};if((o=(i[n[p]]||{})[t])||D("Missing ["+t+"] "+c),!o[h]&&!1!==i[f]){for(var s=!I(e,t),a=O(e),l=[];s&&a&&!P(a)&&!M(l,a);){var d=a[t];if(d){s=d===r;break}l.push(a),a=O(a)}try{s&&(e[t]=o),o[h]=1}catch(e){i[f]=!1}}}return o}(this,t,e,n)||function(e,t,n){var r=t[e];return r===n&&(r=O(t)[e]),typeof r!==c&&D("["+e+"] is not a "+c),r}(t,e,n);return r.apply(this,arguments)};return n[l]=1,n}(e,t)))}))}}function j(e,t){return I(e,a)?e.name||t||v:((e||{})[s]||{}).name||t||v}function U(e,t,n,r){I(e,a)||D("theClass is an invalid class definition.");var o=e[a];(function(e,t){if(C){for(var n=[],r=O(t);r&&!P(r)&&!M(n,r);){if(r===e)return!0;n.push(r),r=O(r)}return!1}return!0})(o,t)||D("["+j(e)+"] not in hierarchy of ["+j(t)+"]");var i=null;I(o,p)?i=o[p]:(i=d+j(e,"_")+"$"+A.n,A.n++,o[p]=i);var s=U[m],c=!!s[E];c&&r&&void 0!==r[E]&&(c=!!r[E]);var h=function(e){var t={};return N(e,(function(n){!t[n]&&k(e,n,!1)&&(t[n]=e[n])})),t}(t),v=function(e,t,n,r){function o(e,t,n){var o=t[n];if(o[l]&&r){var i=e[u]||{};!1!==i[f]&&(o=(i[t[p]]||{})[n]||o)}return function(){return o.apply(e,arguments)}}var i={};N(n,(function(e){i[e]=o(t,n,e)}));for(var s=O(e),a=[];s&&!P(s)&&!M(a,s);)N(s,(function(e){!i[e]&&k(s,e,!C)&&(i[e]=o(t,s,e))})),a.push(s),s=O(s);return i}(o,t,h,c);n(t,v);var g=!!C&&!!s[T];g&&r&&(g=!!r[T]),L(o,i,t,h,!1!==g)}U[m]=A.o},3980:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureAuth=void 0;const r=n(1398),o=n(235),i=n(4200),s=n(803),a=n(7016),c=n(3508),u=n(6209),l=n(7147),p=n(5448),d=n(5672),h=n(9078),f=n(6752),m=n(9329),v=n(1017),g=i.loadMessageBundle(n(6928).join(__dirname,"account-provider/auths/azureAuth.ts"));t.AzureAuth=class{constructor(e,t,n,r,o,i,s){this.metadata=e,this.msalCacheProvider=t,this.context=n,this.clientApplication=r,this.uriEventEmitter=o,this.authType=i,this.userFriendlyName=s,this.memdb=new u.MemoryDatabase,this._disposableStore=[],this.loginEndpointUrl=this.metadata.settings.host,this.commonTenant={id:"common",displayName:"common"},this.organizationTenant={id:"organizations",displayName:"organizations"},this.redirectUri=this.metadata.settings.redirectUri,this.clientId=this.metadata.settings.clientId,this.resources=[this.metadata.settings.armResource],this.metadata.settings.sqlResource&&this.resources.push(this.metadata.settings.sqlResource),this.metadata.settings.ossRdbmsResource&&this.resources.push(this.metadata.settings.ossRdbmsResource),this.metadata.settings.microsoftResource&&this.resources.push(this.metadata.settings.microsoftResource),this.metadata.settings.azureDevOpsResource&&this.resources.push(this.metadata.settings.azureDevOpsResource),this.metadata.settings.azureLogAnalyticsResource&&this.resources.push(this.metadata.settings.azureLogAnalyticsResource),this.metadata.settings.azureKeyVaultResource&&this.resources.push(this.metadata.settings.azureKeyVaultResource),this.metadata.settings.azureKustoResource&&this.resources.push(this.metadata.settings.azureKustoResource),this.metadata.settings.powerBiResource&&this.resources.push(this.metadata.settings.powerBiResource),this.scopes=[...this.metadata.settings.scopes],this.scopesString=this.scopes.join(" "),this._disposableStore.push(this.uriEventEmitter)}async startLogin(){let e;try{if(l.Logger.verbose("Starting login"),!this.metadata.settings.microsoftResource)throw new Error(g(0,null,this.metadata.displayName));const t=await this.login(this.organizationTenant,this.metadata.settings.microsoftResource);if(e=t.authComplete,!t?.response||!t.response?.account)return l.Logger.error(`Authentication failed: ${e}`),{canceled:!1};const n={key:t.response.account.homeAccountId,token:t.response.accessToken,tokenType:t.response.tokenType,expiresOn:t.response.expiresOn.getTime()/1e3,tenantId:t.response.tenantId,resource:0},r=t.response.idTokenClaims,o=await this.hydrateAccount(n,r);try{await this.msalCacheProvider.writeTokenToLocalCache(n)}catch(e){l.Logger.error(`Error writing token to local cache: ${e}`)}return e?.resolve(),o}catch(t){if(l.Logger.error(`Login failed: ${t}`),t instanceof p.AzureAuthError)e&&e.reject(t),l.Logger.error(t.originalMessageAndException);else{const n=(0,h.errorToPromptFailedResult)(t);if(n.errorMessage)return e?.reject(new p.AzureAuthError(n.errorMessage,n.errorMessage,void 0)),n;l.Logger.error(t)}return(0,h.errorToPromptFailedResult)(t)}}async hydrateAccount(e,t){let n;const r=await this.getTenants(e.token,t);return n=this.createAccount(t,e.key,r),n}async getToken(e,t,n){const r=this.resources.find((e=>e.azureResourceId===t));if(!r)throw l.Logger.error(`Unable to find Azure resource ${t}`),new Error(g(1,null,t));const i=r.endpoint.endsWith("/")?r.endpoint:r.endpoint+"/";let s,a;try{if(s=await this.getAccountFromMsalCache(e),!s)throw l.Logger.error("Error: Could not fetch account when acquiring token"),new Error(g(2,null));a=r.azureResourceId===o.AzureResource.ResourceManagement?[`${i}user_impersonation`]:[`${i}.default`];const t={account:s,authority:`${this.loginEndpointUrl}${n}`,scopes:a,forceRefresh:!0};try{return await this.clientApplication.acquireTokenSilent(t)}catch(e){if(l.Logger.error("Failed to acquireTokenSilent",e),e instanceof d.AuthError&&this.accountNeedsRefresh(e)){const e={id:n,displayName:""};return this.handleInteractionRequired(e,r)}return"ClientAuthError"===e.name&&l.Logger.verbose("[ClientAuthError] Failed to silently acquire token"),(0,h.errorToPromptFailedResult)(e)}}catch(e){return l.Logger.error(`[ClientAuthError] Failed to find account: ${e}`),(0,h.errorToPromptFailedResult)(e)}}async getAccountFromMsalCache(e){const t=this.clientApplication.getTokenCache();if(!t)return l.Logger.error("Error: Could not fetch token cache."),null;let n=null;return n=e.includes(".")?await t.getAccountByHomeId(e):await t.getAccountByLocalId(e),n}async getTenants(e,t){const n=a.resolve(this.metadata.settings.armResource.endpoint,"tenants?api-version=2019-11-01");try{l.Logger.verbose(`Fetching tenants with uri: ${n}`);let r=[];const o=(await this.makeGetRequest(n,e)).data;if((0,f.isErrorResponseBodyWithError)(o))throw l.Logger.error(`Error fetching tenants :${o.error?.code} - ${o.error?.message}`),new Error(`${o.error?.code} - ${o.error?.message}`);const i=o.value.map((e=>(e.displayName?r.push(e.displayName):(r.push(e.tenantId),l.Logger.info("Tenant display name found empty: {0}",e.tenantId)),{id:e.tenantId,displayName:e.displayName?e.displayName:e.tenantId,userId:t.oid,tenantCategory:e.tenantCategory})));l.Logger.verbose(`Tenants: ${r}`);const s=i.findIndex((e=>e.tenantCategory===c.HomeCategory));if(s>=0){const e=i.splice(s,1);i.unshift(e[0])}return l.Logger.verbose(`Filtered Tenants: ${r}`),i}catch(e){throw l.Logger.error(`Error fetching tenants :${e}`),e}}async handleInteractionRequired(e,t){if(await this.askUserForInteraction(e,t)){const n=await this.login(e,t);return n?.authComplete?.resolve(),n?.response}return null}accountNeedsRefresh(e){return e instanceof d.InteractionRequiredAuthError||e.errorMessage.includes(c.AADSTS70043)||e.errorMessage.includes(c.AADSTS50173)||e.errorMessage.includes(c.AADSTS50078)||e.errorMessage.includes(c.AADSTS50085)||e.errorMessage.includes(c.AADSTS50089)||e.errorMessage.includes(c.AADSTS700082)||e.errorMessage.includes(c.AADSTS700084)}async askUserForInteraction(e,t){if(!e.displayName&&!e.id)throw new Error("Tenant did not have display name or id");const n={title:g(3,null),booleanResult:!0},o={title:g(4,null),isCloseAffordance:!0,booleanResult:!1},i=g(5,null,e.displayName,e.id,t.endpoint),s=await r.window.showInformationMessage(i,{modal:!0},n,o);let a=!1;return s?.action&&(a=await s.action(e.id)),s?.booleanResult||a}createAccount(e,t,n){l.Logger.verbose(`Token Claims acccount: ${e.preferred_username}, TID: ${e.tid}`),n.forEach((e=>{l.Logger.verbose(`Tenant ID: ${e.id}, Tenant Name: ${e.displayName}`)}));let r="unknown";"https://sts.windows.net/72f988bf-86f1-41af-91ab-2d7cd011db47/"!==e.iss&&e.iss!==`${this.loginEndpointUrl}72f988bf-86f1-41af-91ab-2d7cd011db47/v2.0`||(r=c.AccountIssuer.Corp),"live.com"===e?.idp&&(r=c.AccountIssuer.Msft);const o=e.name??e.preferred_username??e.email??e.unique_name,i=e.preferred_username??e.email??e.unique_name;let s=this.commonTenant;e.tid?s=n.find((t=>t.id===e.tid))??{id:e.tid,displayName:"Microsoft Account"}:l.Logger.info("Could not find tenant information from tokenClaims, falling back to common Tenant.");let a,u=o;switch(i&&(u=`${u} - ${i}`),r){case c.AccountIssuer.Corp:a=g(6,null);break;case c.AccountIssuer.Msft:a=g(7,null);break;default:a=u}let p=r===c.AccountIssuer.Msft?c.AccountType.Microsoft:c.AccountType.WorkSchool;return{key:{providerId:this.metadata.id,accountId:t,accountVersion:c.AccountVersion},name:u,displayInfo:{accountType:p,userId:t,contextualDisplayName:a,displayName:u,email:i,name:o},properties:{providerSettings:this.metadata,isMsAccount:r===c.AccountIssuer.Msft,owningTenant:s,tenants:n,azureAuthType:this.authType},isStale:!1}}async makeGetRequest(e,t){const n={headers:{"Content-Type":"application/json",Authorization:`Bearer ${t}`},validateStatus:()=>!0},o=r.workspace.getConfiguration("http");let i=o.proxy;if(i||(l.Logger.verbose("Workspace HTTP config didn't contain a proxy endpoint. Checking environment variables."),i=this.loadEnvironmentProxyValue()),i){l.Logger.verbose("Proxy endpoint found in environment variables or workspace configuration."),n.proxy=!1;const t=this.createProxyAgent(e,i,o.proxyStrictSSL);t.isHttps?n.httpsAgent=t.agent:n.httpAgent=t.agent;const r=443,s=80,c=a.parse(e),u=c.protocol?.startsWith("https")?r:s,p=`${c.protocol}//${c.hostname}:${u}${c.path}`,d=await m.default.get(p,n);return l.Logger.piiSanitized("GET request ",[{name:"response",objOrArray:d.data?.value??d.data}],[],e),d}l.Logger.verbose("No proxy endpoint was found in the HTTP_PROXY, HTTPS_PROXY environment variables or in the workspace HTTP configuration.");const s=await m.default.get(e,n);return l.Logger.piiSanitized("GET request ",[{name:"response",objOrArray:s.data?.value??s.data}],[],e),s}loadEnvironmentProxyValue(){const e="HTTP_PROXY",t="HTTPS_PROXY";if(process)return process.env[e]||process.env[e.toLowerCase()]?(l.Logger.verbose("Loading proxy value from HTTP_PROXY environment variable."),process.env[e]||process.env[e.toLowerCase()]):process.env[t]||process.env[t.toLowerCase()]?(l.Logger.verbose("Loading proxy value from HTTPS_PROXY environment variable."),process.env[t]||process.env[t.toLowerCase()]):void l.Logger.verbose("No proxy value found in either HTTPS_PROXY or HTTP_PROXY environment variables.");l.Logger.verbose("No process object found, unable to read environment variables for proxy.")}createProxyAgent(e,t,n){const r=(0,v.getProxyAgentOptions)(a.parse(e),t,n);if(!r||!r.host||!r.port)throw l.Logger.verbose("Unable to read proxy agent options to create proxy agent."),new Error("Unable to read proxy agent options to create proxy agent.");let o={};o="string"==typeof r.auth&&r.auth?{proxy:{proxyAuth:r.auth,host:r.host,port:Number(r.port)}}:{proxy:{host:r.host,port:Number(r.port)}};const i=e.startsWith("https"),s=t.startsWith("https");return{isHttps:s,agent:this.createTunnelingAgent(i,s,o)}}createTunnelingAgent(e,t,n){return e&&t?(l.Logger.verbose("Creating https request over https proxy tunneling agent"),s.httpsOverHttps(n)):e&&!t?(l.Logger.verbose("Creating https request over http proxy tunneling agent"),s.httpsOverHttp(n)):!e&&t?(l.Logger.verbose("Creating http request over https proxy tunneling agent"),s.httpOverHttps(n)):(l.Logger.verbose("Creating http request over http proxy tunneling agent"),s.httpOverHttp(n))}getTokenClaims(e){try{const t=e.split(".");return JSON.parse(Buffer.from(t[1],"base64").toString("UTF8"))}catch(e){throw new Error("Unable to read token claims: "+JSON.stringify(e))}}toBase64UrlEncoding(e){return e.replace(/=/g,"").replace(/\+/g,"-").replace(/\//g,"_")}async deleteAllCache(){this.clientApplication.clearCache(),await this.msalCacheProvider.unlinkCacheFiles(),await this.msalCacheProvider.refreshCacheEncryptionKeys()}async clearCredentials(e){try{return await this.deleteAccountCache(e)}catch(e){l.Logger.error("Error when removing token from cache: ",e)}}async deleteAccountCache(e){const t=this.clientApplication.getTokenCache();try{let n=await this.getAccountFromMsalCache(e.accountId);if(!n)throw l.Logger.error(`MSAL: Unable to find account ${e.accountId} for removal`),Error(`Unable to find account ${e.accountId}`);await t.removeAccount(n)}catch(e){l.Logger.error(`[ClientAuthError] Failed to find account: ${e}`)}await this.msalCacheProvider.clearAccountFromLocalCache(e.accountId)}async dispose(){this._disposableStore.forEach((e=>e.dispose()))}async autoOAuthCancelled(){}}},611:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureAuthCodeGrant=void 0;const r=n(3980),o=n(1398),i=n(9736),s=n(5448),a=n(7147),c=n(3508),u=n(4200),l=n(6928),p=n(9896),d=n(5672),h=u.loadMessageBundle(n(6928).join(__dirname,"account-provider/auths/azureAuthCodeGrant.ts"));class f extends r.AzureAuth{constructor(e,t,n,r,o){super(e,t,n,o,r,0,f.USER_FRIENDLY_NAME),this.cryptoProvider=new d.CryptoProvider,this.pkceCodes={nonce:"",challengeMethod:c.S256_CODE_CHALLENGE_METHOD,codeVerifier:"",codeChallenge:""}}async login(e,t){let n,r,i=new Promise(((e,t)=>n={resolve:e,reject:t}));r=o.env.uiKind===o.UIKind.Web?await this.loginWeb(e,t):await this.loginDesktopMsal(e,t,i);let s=await this.clientApplication.acquireTokenByCode(r);if(s)return{response:s,authComplete:n};throw a.Logger.error("Failed to acquireTokenByCode"),a.Logger.error(`Auth Code Request: ${JSON.stringify(r)}`),Error("Failed to fetch token using auth code")}async loginWeb(e,t){const n=await o.env.asExternalUri(o.Uri.parse(`${o.env.uriScheme}://microsoft.azurecore`));await this.createCryptoValuesMsal();const r=`${(n.authority.match(/:([0-9]*)$/)||[])[1]||("https"===n.scheme?443:80)},${encodeURIComponent(this.pkceCodes.nonce)},${encodeURIComponent(n.query)}`;try{let e,t;e={scopes:this.scopes,redirectUri:this.redirectUri,codeChallenge:this.pkceCodes.codeChallenge,codeChallengeMethod:this.pkceCodes.challengeMethod,prompt:c.SELECT_ACCOUNT,state:r},t={scopes:this.scopes,redirectUri:this.redirectUri,codeVerifier:this.pkceCodes.codeVerifier,code:""};let n=await this.clientApplication.getAuthCodeUrl(e);await o.env.openExternal(o.Uri.parse(n));const i=await this.handleWebResponse(r);return t.code=i,t}catch(e){let t=h(0,null);throw a.Logger.error(t),new s.AzureAuthError(t+e.message,e.message,e)}}async handleWebResponse(e){let t;return new Promise(((n,r)=>{t=this.uriEventEmitter.event((async t=>{try{const o=this.parseQuery(t),i=o.code;if(o.state!==e&&decodeURIComponent(o.state)!==e)return void r(new Error("State mismatch"));n(i)}catch(e){r(e)}}))})).finally((()=>{t.dispose()}))}parseQuery(e){return e.query.split("&").reduce(((e,t)=>{const n=t.split("=");return e[n[0]]=n[1],e}),{})}async loginDesktopMsal(e,t,n){const r=new i.SimpleWebServer;let u;try{u=await r.startup()}catch(e){const t=h(1,null);throw new s.AzureAuthError(t,"Server could not start",e)}await this.createCryptoValuesMsal();const l=`${u},${this.pkceCodes.nonce}`;try{let t,i;t={scopes:this.scopes,redirectUri:`${this.redirectUri}:${u}/redirect`,codeChallenge:this.pkceCodes.codeChallenge,codeChallengeMethod:this.pkceCodes.challengeMethod,prompt:c.SELECT_ACCOUNT,authority:`${this.loginEndpointUrl}${e.id}`,state:l},i={scopes:this.scopes,redirectUri:`${this.redirectUri}:${u}/redirect`,codeVerifier:this.pkceCodes.codeVerifier,authority:`${this.loginEndpointUrl}${e.id}`,code:""};let s=await this.clientApplication.getAuthCodeUrl(t);await o.env.openExternal(o.Uri.parse(`http://localhost:${u}/signin?nonce=${encodeURIComponent(this.pkceCodes.nonce)}`));const a=await this.addServerListeners(r,this.pkceCodes.nonce,s,n);return i.code=a,i}catch(e){let t=h(2,null);throw a.Logger.error(t),new s.AzureAuthError(t+e.message,e.message,e)}}async addServerListeners(e,t,n,r){const o=l.join(this.context.extensionPath,"media"),i=async(e,t,n)=>{let r;try{r=await p.promises.readFile(t)}catch(t){return a.Logger.error(t),e.writeHead(400),void e.end()}e.writeHead(200,{"Content-Length":r.length,"Content-Type":n}),e.end(r)};return e.on("/landing.css",((e,t,n)=>{i(n,l.join(o,"landing.css"),"text/css; charset=utf-8").catch(a.Logger.error)})),e.on("/SignIn.svg",((e,t,n)=>{i(n,l.join(o,"SignIn.svg"),"image/svg+xml").catch(a.Logger.error)})),e.on("/signin",((e,r,o)=>{let i=r.query.nonce;if(i=i.replace(/ /g,"+"),i!==t)return o.writeHead(400,{"content-type":"text/html"}),o.write(h(3,null)),o.end(),void a.Logger.error("nonce no match",i,t);o.writeHead(302,{Location:n}),o.end()})),new Promise(((n,s)=>{e.on("/redirect",((e,t,n)=>{const r=(t.query.state??"").split(",");if(2!==r.length)return n.writeHead(400,{"content-type":"text/html"}),n.write(h(4,null)),n.end(),void s(new Error("State mismatch"));const o=r[0];n.writeHead(302,{Location:`http://127.0.0.1:${o}/callback${t.search}`}),n.end()})),e.on("/callback",((e,a,c)=>{const u=a.query.state??"",p=a.query.code??"",d=u.split(",");return 2!==d.length?(c.writeHead(400,{"content-type":"text/html"}),c.write(h(5,null)),c.end(),void s(new Error("State mismatch"))):d[1]!==encodeURIComponent(t)?(c.writeHead(400,{"content-type":"text/html"}),c.write(h(6,null)),c.end(),void s(new Error("Nonce mismatch"))):(n(p),void r.then((()=>{i(c,l.join(o,"landing.html"),"text/html; charset=utf-8").catch(console.error)}),(e=>{c.writeHead(400,{"content-type":"text/html"}),c.write(e.message),c.end()})))}))}))}async createCryptoValuesMsal(){this.pkceCodes.nonce=this.cryptoProvider.createNewGuid();const{verifier:e,challenge:t}=await this.cryptoProvider.generatePkceCodes();this.pkceCodes.codeVerifier=e,this.pkceCodes.codeChallenge=t}}t.AzureAuthCodeGrant=f,f.USER_FRIENDLY_NAME=h(7,null)},5448:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureAuthError=void 0;class n extends Error{constructor(e,t,n){super(e),this.originalMessage=t,this.originalException=n}get originalMessageAndException(){return JSON.stringify({originalMessage:this.originalMessage,originalException:this.originalException},void 0,2)}}t.AzureAuthError=n},8873:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureDeviceCode=void 0;const r=n(235),o=n(4200),i=n(3980),s=n(7147),a=o.loadMessageBundle(n(6928).join(__dirname,"account-provider/auths/azureDeviceCode.ts"));class c extends i.AzureAuth{constructor(e,t,n,r,o){super(e,t,n,o,r,1,c.USER_FRIENDLY_NAME),this.pageTitle=a(0,null,this.metadata.displayName)}async login(e,t){let n,o=new Promise(((e,t)=>n={resolve:e,reject:t}));const i={scopes:this.scopes,authority:`${this.loginEndpointUrl}${e.id}`,deviceCodeCallback:async e=>{await r.accounts.beginAutoOAuthDeviceCode(this.metadata.id,this.pageTitle,e.message,e.userCode,e.verificationUri)}},a=await this.clientApplication.acquireTokenByDeviceCode(i);return this.closeOnceComplete(o).catch(s.Logger.error),{response:a,authComplete:n}}async closeOnceComplete(e){await e,r.accounts.endAutoOAuthDeviceCode()}async autoOAuthCancelled(){return r.accounts.endAutoOAuthDeviceCode()}}t.AzureDeviceCode=c,c.USER_FRIENDLY_NAME=a(1,null)},9078:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.errorToPromptFailedResult=t.urlToHttpOptions=void 0,t.urlToHttpOptions=function(e){const t={protocol:e.protocol,hostname:e.hostname&&e.hostname.startsWith("[")?e.hostname.slice(1,-1):e.hostname,hash:e.hash,search:e.search,pathname:e.pathname,path:`${e.pathname||""}${e.search||""}`,href:e.href};return""!==e.port&&(t.port=Number(e.port)),(e.username||e.password)&&(t.auth=`${decodeURIComponent(e.username)}:${decodeURIComponent(e.password)}`),t},t.errorToPromptFailedResult=function(e){return{canceled:!1,name:e.name,errorCode:e.errorCode,errorMessage:e.errorMessage||e.message}}},4722:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureAccountProvider=void 0;const r=n(1398),o=n(4200),i=n(7147),s=n(611),a=n(8873),c=n(3508),u=n(2259),l=n(3508),p=o.loadMessageBundle(n(6928).join(__dirname,"account-provider/azureAccountProvider.ts"));t.AzureAccountProvider=class{constructor(e,t,n,o,i,s=!1){this.msalCacheProvider=o,this.forceDeviceCode=s,this.authMappings=new Map,this.initCompletePromise=new Promise(((e,t)=>this.initComplete={resolve:e,reject:t})),this.clientApplication=n,r.workspace.onDidChangeConfiguration((n=>{!0===n.affectsConfiguration(c.AccountsAzureAuthSection)&&this.handleAuthMapping(e,t,i)})),this.handleAuthMapping(e,t,i)}dispose(){this.authMappings.forEach((e=>e.dispose()))}clearTokenCache(){return this.getAuthMethod().deleteAllCache()}handleAuthMapping(e,t,n){this.authMappings.forEach((e=>e.dispose())),this.authMappings.clear();const o=r.workspace.getConfiguration(c.AccountsAzureAuthSection),i=o.get(c.AuthType.CodeGrant,!1),u=o.get(c.AuthType.DeviceCode,!1);!0!==i||this.forceDeviceCode||this.authMappings.set(0,new s.AzureAuthCodeGrant(e,this.msalCacheProvider,t,n,this.clientApplication)),(!0===u||this.forceDeviceCode)&&this.authMappings.set(1,new a.AzureDeviceCode(e,this.msalCacheProvider,t,n,this.clientApplication)),!1!==i||!1!==u||this.forceDeviceCode||console.error("No authentication methods selected")}getAuthMethod(e){if(1===this.authMappings.size)return this.authMappings.values().next().value;const t=e?.properties?.azureAuthType;if(t){const e=this.authMappings.get(t);if(e)return e}if(0===this.authMappings.size)throw new Error("No authentication mappings selected");return this.authMappings.values().next().value}initialize(e){return this._initialize(e)}async _initialize(e){const t=[];i.Logger.verbose(`Initializing stored accounts ${JSON.stringify(t)}`);for(let n of e){const e=this.getAuthMethod(n);e?(n.isStale=!1,await e.getAccountFromMsalCache(n.key.accountId)||(n.isStale=!0),t.push(n)):(n.isStale=!0,t.push(n))}return this.initComplete.resolve(),t}getSecurityToken(e,t){return this._getSecurityToken(e,t)}getAccountSecurityToken(e,t,n){return this._getAccountSecurityToken(e,t,n)}async _getAccountSecurityToken(e,t,n){await this.initCompletePromise;const r=this.getAuthMethod(e);if(r){i.Logger.piiSanitized(`Getting account security token for ${JSON.stringify(e.key)} (tenant ${t}). Auth Method = ${r.userFriendlyName}`,[],[]);try{let r=await this.msalCacheProvider.getTokenFromLocalCache(e.key.accountId,t,n);if(this.isValidToken(r)&&(await this.clientApplication.getAllAccounts()).find((t=>t.homeAccountId===e.key.accountId)))return r}catch(e){i.Logger.info(`Could not fetch access token from cache: ${e}, fetching new access token instead.`)}t=t||e.properties.owningTenant.id;let o=await r.getToken(e.key.accountId,n,t);if(this.isAuthenticationResult(o)&&o.account&&o.account.idTokenClaims){const e={key:o.account.homeAccountId,token:o.accessToken,tokenType:o.tokenType,expiresOn:o.account.idTokenClaims.exp,tenantId:t,resource:n};try{await this.msalCacheProvider.writeTokenToLocalCache(e)}catch(e){i.Logger.error(`Could not save access token to local cache: ${e}, this might cause throttling of AAD requests.`)}return e}throw i.Logger.error(`MSAL: getToken call failed: ${o}`),this.isProviderError(o)?(o.errorCode?.includes(l.multiple_matching_tokens_error)&&(o.errorMessage=o.errorMessage?.concat(" To resolve this error, please clear token cache, and refresh account credentials.")),new Error(p(0,null,o.errorCode,o.errorMessage))):new Error(p(1,null))}throw e.isStale=!0,i.Logger.error(`_getAccountSecurityToken: Authentication method not found for account ${e.displayInfo.displayName}`),Error("Failed to get authentication method, please remove and re-add the account")}isAuthenticationResult(e){return!!e&&"string"==typeof e.accessToken}isProviderError(e){return!!e&&"string"==typeof e.errorMessage}isValidToken(e){const t=(new Date).getTime()/1e3;return void 0!==e&&void 0!==e.expiresOn&&Number(e.expiresOn)-t>300}async _getSecurityToken(e,t){r.window.showInformationMessage(p(2,null));const n=e,o={};for(const r of n.properties.tenants)try{o[r.id]=await this._getAccountSecurityToken(e,r.id,t)}catch(e){if(!(e instanceof u.TenantIgnoredError))throw e}return o}prompt(){return this._prompt()}async _prompt(){const e=p(3,null),t=p(4,null);await this.initCompletePromise;class n{constructor(e){this.azureAuth=e,this.label=e.userFriendlyName}}if(0===this.authMappings.size)return i.Logger.error("No auth method was enabled."),r.window.showErrorMessage(t),{canceled:!0};if(1===this.authMappings.size)return this.getAuthMethod(void 0).startLogin();const o=[];this.authMappings.forEach((e=>{o.push(new n(e))}));const s=await r.window.showQuickPick(o,{canPickMany:!1});return s?s.azureAuth.startLogin():(i.Logger.error("No auth method was selected."),r.window.showErrorMessage(e),{canceled:!0})}refresh(e){return this._refresh(e)}async _refresh(e){return await this._clear(e.key),this.prompt()}async clear(e){return this._clear(e)}async _clear(e){await this.initCompletePromise,await(this.getAuthMethod(void 0)?.clearCredentials(e))}autoOAuthCancelled(){return this.authMappings.forEach((e=>e.autoOAuthCancelled())),Promise.resolve()}}},1991:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureAccountProviderService=void 0;const r=n(6928),o=n(235),i=n(4434),s=n(4200),a=n(1398),c=n(9896),u=n(4581),l=n(4722),p=n(8801),d=n(1651),h=n(5672),f=n(3508),m=n(7147),v=n(3397),g=n(76),y=n(1651);let _=s.loadMessageBundle(n(6928).join(__dirname,"account-provider/azureAccountProviderService.ts"));class b extends a.EventEmitter{handleUri(e){this.fire(e)}}t.AzureAccountProviderService=class{constructor(e,t){this._context=e,this._userStoragePath=t,this._disposables=[],this._accountDisposals={},this._accountProviders={},this._credentialProvider=void 0,this._cachePluginProvider=void 0,this._configChangePromiseChain=Promise.resolve(),this._currentConfig=void 0,this._event=new i.EventEmitter,this._uriEventHandler=new b,this.activeProviderCount=0,this._onEncryptionKeysUpdated=new a.EventEmitter,this._disposables.push(a.window.registerUriHandler(this._uriEventHandler))}activate(){let e=this;return this._context.subscriptions.push(a.commands.registerCommand(f.AccountsClearTokenCacheCommand,(()=>{e._event.emit(f.AccountsClearTokenCacheCommand)}))),this._event.on(f.AccountsClearTokenCacheCommand,(()=>{e.onClearTokenCache()})),o.credentials.getProvider(f.AzureAccountProviderCredentials).then((e=>(this._credentialProvider=e,this._context.subscriptions.push(a.workspace.onDidChangeConfiguration((()=>{this._configChangePromiseChain=this.onDidChangeConfiguration()}),this)),this._configChangePromiseChain=this.onDidChangeConfiguration(),!0)))}getEncryptionKeysEmitter(){return this._onEncryptionKeysUpdated}async getEncryptionKeys(){return this._cachePluginProvider||await this.onDidChangeConfiguration(),this._cachePluginProvider.getCacheEncryptionKeys()}dispose(){for(;this._disposables.length;){const e=this._disposables.pop();e&&e.dispose()}}onClearTokenCache(){let e=u.default.map((e=>this._accountProviders[e.metadata.id]?.clearTokenCache()));return Promise.all(e).then((()=>{(0,g.displayReloadAds)(y.reloadPromptCacheClear)}),(e=>{let t=_(0,null);a.window.showErrorMessage(`${d.extensionName}: ${t}: ${e}`)}))}async onDidChangeConfiguration(){await this._configChangePromiseChain;let e=a.workspace.getConfiguration(f.AccountsAzureCloudSection),t=this._currentConfig;this._currentConfig=e;let n=[];for(let r of u.default){let o=!!t&&t.get(r.configKey),i=e.get(r.configKey);o!==i&&(o&&!i&&(n.push(this.unregisterAccountProvider(r)),this.activeProviderCount--),!o&&i&&(n.push(this.registerAccountProvider(r)),this.activeProviderCount++),r.configKey!==f.enablePublicCloud&&r.configKey!==f.enableUsGovCloud&&r.configKey!==f.enableChinaCloud&&(n.push(this.registerAccountProvider(r)),this.activeProviderCount++))}0===this.activeProviderCount&&a.window.showWarningMessage(d.noCloudsEnabled,d.enablePublicCloud,d.dismiss).then((async e=>{e===d.enablePublicCloud&&await a.workspace.getConfiguration(f.AccountsAzureCloudSection).update(d.enablePublicCloudCamel,!0,a.ConfigurationTarget.Global)})),await Promise.all(n)}async registerAccountProvider(e){const t=a.env.appName.toLowerCase().indexOf(f.Saw)>0,n=f.MSALCacheName;await this.clearOldCacheIfExists();try{if(!this._credentialProvider)throw new Error("Credential provider not registered");this._cachePluginProvider=new p.MsalCachePluginProvider(n,this._userStoragePath,this._credentialProvider,this._onEncryptionKeysUpdated),await this._cachePluginProvider.init();const r={auth:{clientId:e.metadata.settings.clientId,authority:"https://login.windows.net/common"},system:{loggerOptions:{loggerCallback:this.getLoggerCallback(),logLevel:v.LogLevel.Trace,piiLoggingEnabled:!0}},cache:{cachePlugin:this._cachePluginProvider?.getCachePlugin()}};this.clientApplication=new h.PublicClientApplication(r);let i=new l.AzureAccountProvider(e.metadata,this._context,this.clientApplication,this._cachePluginProvider,this._uriEventHandler,t);this._accountProviders[e.metadata.id]=i,this._accountDisposals[e.metadata.id]=o.accounts.registerAccountProvider(e.metadata,i)}catch(e){console.error(`Failed to register account provider, isSaw: ${t}: ${e}`)}}async clearOldCacheIfExists(){let e=r.join(this._userStoragePath,f.oldMsalCacheFileName);try{await c.promises.access(e),await c.promises.unlink("file:"+e),m.Logger.verbose("Old cache file removed successfully.")}catch(e){"ENOENT"!==e.code&&m.Logger.verbose(`Error occurred while removing old cache file: ${e}`)}}getLoggerCallback(){return(e,t,n)=>{if(n)m.Logger.pii(t);else switch(e){case v.LogLevel.Error:m.Logger.error(t);break;case v.LogLevel.Info:m.Logger.info(t);break;case v.LogLevel.Verbose:default:m.Logger.verbose(t)}}}async unregisterAccountProvider(e){try{this._accountDisposals[e.metadata.id].dispose(),delete this._accountProviders[e.metadata.id],delete this._accountDisposals[e.metadata.id]}catch(e){console.error(`Failed to unregister account provider: ${e}`)}}}},4581:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=n(4200),o=n(235),i=n(76),s=r.loadMessageBundle(n(6928).join(__dirname,"account-provider/providerSettings.ts"));let a=[{configKey:"enablePublicCloud",metadata:{displayName:s(0,null),id:"azure_publicCloud",settings:{host:"https://login.microsoftonline.com/",clientId:"a69788c6-1d43-44ed-9ca3-b83e194da255",microsoftResource:{id:"marm",endpoint:"https://management.core.windows.net/",azureResourceId:o.AzureResource.MicrosoftResourceManagement},msGraphResource:{id:"msgraph",endpoint:"https://graph.microsoft.com/",azureResourceId:o.AzureResource.MsGraph},armResource:{id:"arm",endpoint:"https://management.azure.com/",azureResourceId:o.AzureResource.ResourceManagement},sqlResource:{id:"sql",endpoint:"https://database.windows.net/",azureResourceId:o.AzureResource.Sql},ossRdbmsResource:{id:"ossrdbms",endpoint:"https://ossrdbms-aad.database.windows.net/",azureResourceId:o.AzureResource.OssRdbms},azureKeyVaultResource:{id:"vault",endpoint:"https://vault.azure.net/",azureResourceId:o.AzureResource.AzureKeyVault},azureDevOpsResource:{id:"ado",endpoint:"499b84ac-1321-427f-aa17-267ca6975798/",azureResourceId:o.AzureResource.AzureDevOps},azureLogAnalyticsResource:{id:"ala",endpoint:"https://api.loganalytics.io/",azureResourceId:o.AzureResource.AzureLogAnalytics},azureStorageResource:{id:"storage",endpoint:"",endpointSuffix:".core.windows.net/",azureResourceId:o.AzureResource.AzureStorage},azureKustoResource:{id:"kusto",endpoint:"https://kusto.kusto.windows.net/",azureResourceId:o.AzureResource.AzureKusto},powerBiResource:{id:"powerbi",endpoint:"https://analysis.windows.net/powerbi/api/",azureResourceId:o.AzureResource.PowerBi},redirectUri:"http://localhost",scopes:["openid","email","profile","offline_access","https://management.azure.com/user_impersonation"],portalEndpoint:"https://portal.azure.com"}}},{configKey:"enableUsGovCloud",metadata:{displayName:s(1,null),id:"azure_usGovtCloud",settings:{host:"https://login.microsoftonline.us/",clientId:"a69788c6-1d43-44ed-9ca3-b83e194da255",microsoftResource:{id:"marm",endpoint:"https://management.core.usgovcloudapi.net/",azureResourceId:o.AzureResource.MicrosoftResourceManagement},msGraphResource:{id:"msgraph",endpoint:"https://graph.microsoft.us/",azureResourceId:o.AzureResource.MsGraph},armResource:{id:"arm",endpoint:"https://management.usgovcloudapi.net/",azureResourceId:o.AzureResource.ResourceManagement},sqlResource:{id:"sql",endpoint:"https://database.usgovcloudapi.net/",azureResourceId:o.AzureResource.Sql},ossRdbmsResource:{id:"ossrdbms",endpoint:"https://ossrdbms-aad.database.usgovcloudapi.net/",azureResourceId:o.AzureResource.OssRdbms},azureKeyVaultResource:{id:"vault",endpoint:"https://vault.usgovcloudapi.net/",azureResourceId:o.AzureResource.AzureKeyVault},azureLogAnalyticsResource:{id:"ala",endpoint:"https://api.loganalytics.us/",azureResourceId:o.AzureResource.AzureLogAnalytics},azureStorageResource:{id:"storage",endpoint:"",endpointSuffix:".core.usgovcloudapi.net/",azureResourceId:o.AzureResource.AzureStorage},azureKustoResource:{id:"kusto",endpoint:"https://kusto.kusto.usgovcloudapi.net",azureResourceId:o.AzureResource.AzureKusto},powerBiResource:{id:"powerbi",endpoint:"https://analysis.windows.net/powerbi/api/",azureResourceId:o.AzureResource.PowerBi},redirectUri:"http://localhost",scopes:["openid","email","profile","offline_access","https://management.usgovcloudapi.net/user_impersonation"],portalEndpoint:"https://portal.azure.us"}}},{configKey:"enableChinaCloud",metadata:{displayName:s(2,null),id:"azure_chinaCloud",settings:{host:"https://login.partner.microsoftonline.cn/",clientId:"a69788c6-1d43-44ed-9ca3-b83e194da255",microsoftResource:{id:"marm",endpoint:"https://management.core.chinacloudapi.cn/",azureResourceId:o.AzureResource.MicrosoftResourceManagement},msGraphResource:{id:"msgraph",endpoint:"https://microsoftgraph.chinacloudapi.cn",azureResourceId:o.AzureResource.MsGraph},armResource:{id:"arm",endpoint:"https://management.chinacloudapi.cn",azureResourceId:o.AzureResource.ResourceManagement},sqlResource:{id:"sql",endpoint:"https://database.chinacloudapi.cn/",azureResourceId:o.AzureResource.Sql},azureKeyVaultResource:{id:"vault",endpoint:"https://vault.azure.cn",azureResourceId:o.AzureResource.AzureKeyVault},azureLogAnalyticsResource:{id:"ala",endpoint:"https://api.loganalytics.azure.cn",azureResourceId:o.AzureResource.AzureLogAnalytics},azureStorageResource:{id:"storage",endpoint:"",endpointSuffix:".core.chinacloudapi.cn",azureResourceId:o.AzureResource.AzureStorage},azureKustoResource:{id:"kusto",endpoint:"https://kusto.kusto.chinacloudapi.cn",azureResourceId:o.AzureResource.AzureKusto},powerBiResource:{id:"powerbi",endpoint:"https://analysis.windows.net/powerbi/api",azureResourceId:o.AzureResource.PowerBi},redirectUri:"http://localhost",scopes:["openid","email","profile","offline_access","https://management.chinacloudapi.cn/user_impersonation"],portalEndpoint:"https://portal.azure.cn/"}}}];a=(0,i.updateCustomCloudProviderSettings)(a),t.default=a},3588:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FileEncryptionHelper=void 0;const r=n(857),o=n(6982),i=n(1398),s=n(1651),a=n(7147);t.FileEncryptionHelper=class{constructor(e,t,n){this._credentialService=e,this._fileName=t,this._onEncryptionKeysUpdated=n,this._ivCredId=`${this._fileName}-iv`,this._keyCredId=`${this._fileName}-key`,this.fileSaver=async e=>{this._keyBuffer&&this._ivBuffer||await this.init();const t=o.createCipheriv(this._algorithm,this._keyBuffer,this._ivBuffer);return`${t.update(e,"utf8",this._binaryEncoding)}${t.final(this._binaryEncoding)}`},this.fileOpener=async(e,t)=>{try{this._keyBuffer&&this._ivBuffer||await this.init();let t=e;const n=o.createDecipheriv(this._algorithm,this._keyBuffer,this._ivBuffer);return`${n.update(t,this._binaryEncoding,"utf8")}${n.final("utf8")}`}catch(e){throw a.Logger.error(`FileEncryptionHelper: Error occurred when decrypting data, IV/KEY will be reset: ${e}`),t&&await this.refreshEncryptionKeys(),new Error(`Decryption failed with error: ${e}`)}},this._algorithm="aes-256-cbc",this._bufferEncoding="utf16le",this._binaryEncoding="base64"}async init(){const e=await this.readEncryptionKey(this._ivCredId),t=await this.readEncryptionKey(this._keyCredId);e&&t?(this._ivBuffer=Buffer.from(e,this._bufferEncoding),this._keyBuffer=Buffer.from(t,this._bufferEncoding)):(this._ivBuffer=o.randomBytes(16),this._keyBuffer=o.randomBytes(32),await this.saveEncryptionKey(this._ivCredId,this._ivBuffer.toString(this._bufferEncoding))&&await this.saveEncryptionKey(this._keyCredId,this._keyBuffer.toString(this._bufferEncoding))||(a.Logger.error("Encryption keys could not be saved in credential store, this will cause access token persistence issues."),await this.showCredSaveErrorOnWindows())),this._onEncryptionKeysUpdated&&(this._onEncryptionKeysUpdated.fire(this.getEncryptionKeys()),a.Logger.verbose("FileEncryptionHelper: Fired encryption keys updated event."))}getEncryptionKeys(){return{iv:this._ivBuffer.toString(this._bufferEncoding),key:this._keyBuffer.toString(this._bufferEncoding)}}async refreshEncryptionKeys(){await this.deleteEncryptionKey(this._ivCredId),await this.deleteEncryptionKey(this._keyCredId),this._ivBuffer=void 0,this._keyBuffer=void 0,await this.init()}async readEncryptionKey(e){return(await this._credentialService.readCredential(e))?.password}async deleteEncryptionKey(e){return await this._credentialService.deleteCredential(e)}async saveEncryptionKey(e,t){let n=!1;try{await this._credentialService.saveCredential(e,t).then((t=>{n=t,t&&a.Logger.info(`FileEncryptionHelper: Successfully saved encryption key ${e} persistent cache encryption in system credential store.`)}),(t=>{throw Error(`FileEncryptionHelper: Could not save encryption key: ${e}: ${t}`)}))}catch(e){throw"win32"===r.platform()&&a.Logger.error("FileEncryptionHelper: Please try cleaning saved credentials from Windows Credential Manager created by Azure Data Studio to allow creating new credentials."),a.Logger.error(e),e}return n}async showCredSaveErrorOnWindows(){"win32"===r.platform()&&await i.window.showWarningMessage(s.azureCredStoreSaveFailedError,s.reloadChoice,s.cancel).then((async e=>{e===s.reloadChoice&&await i.commands.executeCommand("workbench.action.reloadWindow")}),(e=>{a.Logger.error(e)}))}}},6209:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MemoryDatabase=void 0,t.MemoryDatabase=class{constructor(){this.db={}}set(e,t){this.db[e]=t}delete(e){delete this.db[e]}get(e){return this.db[e]}}},8801:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MsalCachePluginProvider=void 0;const r=n(9896),o=n(127),i=n(6928),s=n(3508),a=n(7147),c=n(3588);t.MsalCachePluginProvider=class{constructor(e,t,n,r){this._serviceName=e,this._credentialService=n,this._onEncryptionKeysUpdated=r,this._emptyLocalCache={tokens:[]},this._fileEncryptionHelper=new c.FileEncryptionHelper(this._credentialService,this._serviceName,this._onEncryptionKeysUpdated),this._msalCacheConfiguration={name:"MSAL",cacheFilePath:i.join(t,this._serviceName),lockFilePath:i.join(t,this._serviceName)+s.LockFileSuffix,lockTaken:!1},this._localCacheConfiguration={name:"Local",cacheFilePath:i.join(t,this._serviceName)+s.LocalCacheSuffix,lockFilePath:i.join(t,this._serviceName)+s.LocalCacheSuffix+s.LockFileSuffix,lockTaken:!1}}async init(){await this._fileEncryptionHelper.init()}getCacheEncryptionKeys(){return this._fileEncryptionHelper.getEncryptionKeys()}async refreshCacheEncryptionKeys(){await this._fileEncryptionHelper.refreshEncryptionKeys()}getCachePlugin(){return{beforeCacheAccess:async e=>{try{const t=await this.readCache(this._msalCacheConfiguration,this._localCacheConfiguration);e.tokenCache.deserialize(t)}catch(e){a.Logger.verbose(`MsalCachePlugin: Error occurred when trying to read cache file, file will be deleted: ${e.message}`),await this.unlinkCache(this._msalCacheConfiguration)}},afterCacheAccess:async e=>{if(e.cacheHasChanged){const t=e.tokenCache.serialize();await this.writeCache(t,this._msalCacheConfiguration)}}}}async getTokenFromLocalCache(e,t,n){let r=JSON.parse(await this.readCache(this._localCacheConfiguration,this._msalCacheConfiguration)),o=r?.tokens?.find((r=>r.key===e&&r.tenantId===t&&r.resource===n));return o}async writeTokenToLocalCache(e){let t,n=0,r=-1;t=JSON.parse(await this.readCache(this._localCacheConfiguration,this._msalCacheConfiguration)),t?.tokens?t.tokens.forEach(((t,o)=>{t.key===e.key&&t.tenantId===e.tenantId&&t.resource===e.resource&&(r=o,n++)})):t=this._emptyLocalCache,0===n&&(t.tokens.push(e),n=1),1===n?(-1!==r&&(t.tokens[r]=e),await this.writeCache(JSON.stringify(t),this._localCacheConfiguration)):(a.Logger.info("Found multiple tokens in local cache, cache will be reset."),await this.writeCache(JSON.stringify(this._emptyLocalCache),this._localCacheConfiguration))}async clearAccountFromLocalCache(e){let t=JSON.parse(await this.readCache(this._localCacheConfiguration,this._msalCacheConfiguration)),n=[];t?.tokens&&t.tokens.forEach(((t,r)=>{t.key===e&&n.push(r)})),n.forEach((e=>{t.tokens.splice(e)})),a.Logger.info(`Local Cache cleared for account, ${n.length} tokens were cleared.`)}async unlinkCacheFiles(){await this.unlinkCache(this._msalCacheConfiguration),await this.unlinkCache(this._localCacheConfiguration)}async writeCache(e,t){t.lockTaken=await this.waitAndLock(t.lockFilePath,t.lockTaken);try{const n=await this._fileEncryptionHelper.fileSaver(e);await r.promises.writeFile(t.cacheFilePath,n,{encoding:"utf8"})}catch(e){throw a.Logger.error(`MsalCachePlugin: Failed to write to '${t.name}' cache file: ${e}`),e}finally{o.unlockSync(t.lockFilePath),t.lockTaken=!1}}async readCache(e,t){e.lockTaken=await this.waitAndLock(e.lockFilePath,e.lockTaken);try{const t=await r.promises.readFile(e.cacheFilePath,{encoding:"utf8"});return await this._fileEncryptionHelper.fileOpener(t,!0)}catch(n){return"ENOENT"===n.code?a.Logger.verbose(`MsalCachePlugin: Cache file for '${e.name}' cache not found on disk: ${n.code}`):(a.Logger.error(`MsalCachePlugin: Failed to read from cache file: ${n}`),a.Logger.verbose(`MsalCachePlugin: Error occurred when trying to read cache file ${e.name}, file will be deleted: ${n.message}`),await this.unlinkCache(e),e.name!==t.name&&(t.lockTaken=await this.waitAndLock(t.lockFilePath,t.lockTaken),await this.unlinkCache(t),o.unlockSync(t.lockFilePath),t.lockTaken=!1,a.Logger.verbose(`MsalCachePlugin: Cache file for ${t.name} cache also deleted.`))),"{}"}finally{o.unlockSync(e.lockFilePath),e.lockTaken=!1}}async waitAndLock(e,t){o.checkSync(e)&&!t&&(o.unlockSync(e),a.Logger.verbose("MsalCachePlugin: Stale lockfile found and has been removed."));let n=0;for(;n<=500;)try{o.lockSync(e),t=!0;break}catch(e){if(500===n)throw a.Logger.error("MsalCachePlugin: Failed to acquire lock on cache file after 500 attempts."),new Error(`Failed to acquire lock on cache file after 500 attempts. Please attempt command: '${s.AccountsClearTokenCacheCommand}' to clear access token cache.`);n++,a.Logger.verbose("MsalCachePlugin: Failed to acquire lock on cache file. Retrying in 100 ms."),await new Promise((e=>setTimeout(e,100)))}return t}async unlinkCache(e){try{await r.promises.unlink(e.cacheFilePath)}catch(t){a.Logger.info(`An error occurred when clearing ${e.name} Cache, safely ignored: ${t}`)}}}},9736:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SimpleWebServer=t.AlreadyRunningError=void 0;const r=n(8611),o=n(7016),i=n(7147);class s extends Error{}t.AlreadyRunningError=s,t.SimpleWebServer=class{constructor(e=3e5){this.autoShutoffTimer=e,this.hasStarted=!1,this.pathMappings=new Map,this.lastUsed=(new Date).getTime(),this.bumpLastUsed(),this.shutoffInterval=setInterval((()=>{(new Date).getTime()-this.lastUsed>this.autoShutoffTimer&&(i.Logger.verbose("Shutting off webserver..."),this.shutdown().catch(console.error))}),1e3),this.server=r.createServer(((e,t)=>{this.bumpLastUsed();const n=o.parse(e.url,!0),r=n.pathname?this.pathMappings.get(n.pathname):void 0;if(r)return r(e,n,t);t.writeHead(404),t.end()}))}bumpLastUsed(){this.lastUsed=(new Date).getTime()}async shutdown(){return clearInterval(this.shutoffInterval),new Promise(((e,t)=>{this.server.close((n=>{n?t(n):e()}))}))}async startup(){if(this.hasStarted)throw new s;let e;this.hasStarted=!0;const t=new Promise(((t,n)=>{e=setTimeout((()=>{n(new Error("Timed out waiting for the server to start"))}),5e3),this.server.on("listening",(()=>{const e=this.server.address();void 0===e.port&&n(new Error("Port was not defined")),t(e.port.toString())})),this.server.on("error",(()=>{n(new Error("Server error"))})),this.server.on("close",(()=>{n(new Error("Server closed"))})),this.server.listen(0,"127.0.0.1")}));return t.finally((()=>{clearTimeout(e)})),t}on(e,t){this.pathMappings.set(e,t)}}},9699:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AppContext=void 0,t.AppContext=class{constructor(e){this.extensionContext=e,this.serviceMap=new Map}getService(e){return this.serviceMap.get(e)}registerService(e,t){this.serviceMap.set(e,t)}}},9011:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureDataGridProvider=void 0;const r=n(235),o=n(7768),i=n(6752),s=n(3508),a=n(1651),c=n(76),u=n(7147),l=["microsoft.sql/servers/databases","microsoft.sql/servers","microsoft.synapse/workspaces","microsoft.synapse/workspaces/sqlpools","microsoft.sql/managedinstances","microsoft.dbforpostgresql/servers","microsoft.dbforpostgresql/flexibleservers","microsoft.azuredata/datacontrollers","microsoft.azuredata/sqlmanagedinstances","microsoft.azuredata/postgresinstances"].map((e=>`type == "${e}"`)).join(" or ");t.AzureDataGridProvider=class{constructor(e){this._appContext=e,this.providerId=s.dataGridProviderId,this.title=a.azureResourcesGridTitle}async getDataGridItems(){let e;e=await r.accounts.getAllAccounts();const t=[];return await Promise.all(e.map((async e=>{await Promise.all(e.properties.tenants.map((async n=>{try{const r=this._appContext.getService(o.AzureResourceServiceNames.subscriptionService),s=await r.getSubscriptions(e,[n.id]);try{const n=(await i.runResourceQuery(e,s,!0,`where ${l}`)).resources.map((t=>({id:t.id,name:t.name,resourceGroup:t.resourceGroup,subscriptionId:t.subscriptionId,subscriptionName:s.find((e=>e.id===t.subscriptionId))?.name??t.subscriptionId,locationDisplayName:c.getRegionDisplayName(t.location),type:t.type,typeDisplayName:c.getResourceTypeDisplayName(t.type),iconPath:c.getResourceTypeIcon(this._appContext,t.type),portalEndpoint:e.properties.providerSettings.settings.portalEndpoint})));t.push(...n)}catch(e){u.Logger.error(e)}}catch(e){u.Logger.error(e)}})))}))),t}async getDataGridColumns(){return[{id:"icon",type:"image",field:"iconPath",name:"",width:25,sortable:!1,filterable:!1,resizable:!1,tooltip:a.typeIcon},{id:"name",type:"text",field:"name",name:a.name,width:150},{id:"type",type:"text",field:"typeDisplayName",name:a.resourceType,width:150},{id:"resourceGroup",type:"text",field:"resourceGroup",name:a.resourceGroup,width:150},{id:"location",type:"text",field:"locationDisplayName",name:a.location,width:150},{id:"subscriptionId",type:"text",field:"subscriptionName",name:a.subscription,width:150}]}}},5723:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.registerAzureResourceCommands=void 0;const r=n(235),o=n(1398),i=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/commands.ts")),s=n(4729),a=n(6653),c=n(7768),u=n(8991),l=n(6752),p=n(4040),d=n(7264);t.registerAzureResourceCommands=function(e,t,n){const h=[t,n];o.commands.registerCommand("azure.resource.startterminal",(async t=>{try{if(!o.workspace.getConfiguration("workbench").get("enablePreviewFeatures")){const e=i(0,null);return void o.window.showInformationMessage(e)}let n;if(t instanceof a.AzureResourceAccountTreeNode)n=t.account;else{let e=await r.accounts.getAllAccounts();if(e=e.filter((e=>e.key.providerId.startsWith("azure"))),0===e.length){const e=i(1,null);return void(await o.window.showErrorMessage(i(2,null),e)===e&&o.commands.executeCommand("azure.resource.signin"))}if(1===e.length)n=e[0];else{const t=await o.window.showQuickPick(e.map((e=>e.displayInfo.displayName)),{canPickMany:!1,placeHolder:i(3,null)});if(!t)return void o.window.showErrorMessage(i(4,null));n=e.find((e=>e.displayInfo.displayName===t))}}if(!n)throw new Error("No Azure Account chosen");const s=e.getService(c.AzureResourceServiceNames.terminalService),u=n.properties.tenants.map((e=>e.displayName));if(0===u.length)return void o.window.showErrorMessage(i(5,null));let l;if(o.window.setStatusBarMessage(i(6,null),5e3),1===u.length)l=n.properties.tenants[0];else{const e=await o.window.showQuickPick(u,{canPickMany:!1});if(!e)return void o.window.showErrorMessage(i(7,null));l=n.properties.tenants[u.indexOf(e)]}await s.getOrCreateCloudConsole(n,l)}catch(e){console.error(e),o.window.showErrorMessage(e)}})),o.commands.registerCommand("azure.resource.selectsubscriptions",(async t=>{if(!(t instanceof a.AzureResourceAccountTreeNode||t instanceof d.FlatAccountTreeNode||t instanceof p.AzureResourceTenantTreeNode||t instanceof u.FlatTenantTreeNode))return;const n=t.account;let r=t.account.properties.tenants[0];if((t instanceof p.AzureResourceTenantTreeNode||t instanceof u.FlatTenantTreeNode)&&(r=t.tenant),!n||!r)return;const i=e.getService(c.AzureResourceServiceNames.subscriptionService),s=e.getService(c.AzureResourceServiceNames.subscriptionFilterService);let f=[];if(0===f.length)try{let e=r?[r.id]:n.properties.tenants.flatMap((e=>e.id));f=await i.getSubscriptions(n,e)}catch(e){return n.isStale=!0,void o.window.showErrorMessage(l.AzureResourceErrorMessageUtil.getErrorMessage(e))}let m=await s.getSelectedSubscriptions(n,r);m||(m=[]);const v=[];m.length>0?v.push(...m.map((e=>e.id))):v.push(...f.map((e=>e.id)));const g=f.map((e=>({label:e.name,picked:-1!==v.indexOf(e.id),subscription:e}))).sort(((e,t)=>e.label.localeCompare(t.label))),y=await o.window.showQuickPick(g,{canPickMany:!0});if(y&&y.length>0){for(const e of h)await e.refresh(void 0,!1);m=y.map((e=>e.subscription)),await s.saveSelectedSubscriptions(n,r,m)}})),o.commands.registerCommand("azure.resource.selecttenants",(async t=>{if(!(t instanceof a.AzureResourceAccountTreeNode||t instanceof d.FlatAccountTreeNode))return;const n=t.account;if(!n)return;const r=e.getService(c.AzureResourceServiceNames.tenantFilterService);let i=n.properties.tenants,s=await r.getSelectedTenants(n);s||(s=[]);const u=[];s.length>0?u.push(...s.map((e=>e.id))):u.push(...i.map((e=>e.id)));const l=i.map((e=>({label:e.displayName,picked:-1!==u.indexOf(e.id),tenant:e}))).sort(((e,t)=>e.label.localeCompare(t.label))),p=await o.window.showQuickPick(l,{canPickMany:!0});if(p&&p.length>0){for(const e of h)await e.refresh(void 0,!1);s=p.map((e=>e.tenant)),await r.saveSelectedTenants(n,s)}})),o.commands.registerCommand("azure.resource.refreshall",(()=>{for(const e of h)e.notifyNodeChanged(void 0)})),o.commands.registerCommand("azure.resource.azureview.refresh",(async e=>t.refresh(e,!0))),o.commands.registerCommand("azure.resource.connectiondialog.refresh",(async e=>(await n.refresh(e,!0),n.refresh(e,!1)))),o.commands.registerCommand("azure.resource.signin",(async e=>o.commands.executeCommand("workbench.actions.modal.linkedAccount"))),o.commands.registerCommand("azure.resource.connectsqlserver",(async e=>{if(!e)return;let t;if(e instanceof s.TreeNode){const n=await e.getTreeItem();if(!n.payload)return;t=Object.assign({},n.payload,{saveProfile:!0})}else e.isConnectionNode&&(t=Object.assign({},e.connectionProfile,{saveProfile:!0}));await r.connection.openConnectionDialog(void 0,t,{saveConnection:!0,showDashboard:!0})&&o.commands.executeCommand("workbench.view.connections")})),o.commands.registerCommand("azure.resource.openInAzurePortal",(async e=>{if(!e.azureResourceId||!e.azurePortalEndpoint||!e.azureTenantId)return;const t=`${e.azurePortalEndpoint}//${e.azureTenantId}/#resource/${e.azureResourceId}`;await o.env.openExternal(o.Uri.parse(t))}))}},7768:(e,t)=>{"use strict";var n,r,o,i;Object.defineProperty(t,"__esModule",{value:!0}),t.ResourceCategory=t.cosmosDbNoSqlKind=t.mongoDbKind=t.analyticsKind=t.pgsqlProvider=t.mySqlProvider=t.kustoProvider=t.cosmosDBNoSqlProvider=t.cosmosDBMongoProvider=t.logAnalyticsProvider=t.mssqlProvider=t.AzureResourcePrefixes=t.AzureResourceServiceNames=t.AzureResourceItemType=void 0,function(e){e.account="azure.resource.itemType.account",e.singleTenantAccount="azure.resource.itemType.singleTenantAccount",e.multipleTenantAccount="azure.resource.itemType.multipleTenantAccount",e.subscription="azure.resource.itemType.subscription",e.tenant="azure.resource.itemType.tenant",e.databaseContainer="azure.resource.itemType.databaseContainer",e.database="azure.resource.itemType.database",e.databaseServerContainer="azure.resource.itemType.databaseServerContainer",e.databaseServer="azure.resource.itemType.databaseServer",e.synapseSqlPoolContainer="azure.resource.itemType.synapseSqlPoolContainer",e.synapseSqlPool="azure.resource.itemType.synapseSqlPool",e.synapseWorkspaceContainer="azure.resource.itemType.synapseWorkspaceContainer",e.synapseWorkspace="azure.resource.itemType.synapseWorkspace",e.azureDataExplorerContainer="azure.resource.itemType.azureDataExplorerContainer",e.azureDataExplorer="azure.resource.itemType.azureDataExplorer",e.sqlInstance="azure.resource.itemType.sqlInstance",e.message="azure.resource.itemType.message",e.azureMonitor="azure.resource.itemType.azureMonitor",e.azureMonitorContainer="azure.resource.itemType.azureMonitorContainer",e.cosmosDBMongoAccount="azure.resource.itemType.cosmosDBMongoAccount",e.cosmosDBNoSqlAccount="azure.resource.itemType.cosmosDBNoSqlAccount",e.cosmosDBMongoCluster="azure.resource.itemType.cosmosDBMongoCluster",e.cosmosDBPostgresAccount="azure.resource.itemType.cosmosDBPostgresAccount",e.cosmosDBPostgresCluster="azure.resource.itemType.cosmosDBPostgresCluster"}(n||(t.AzureResourceItemType=n={})),function(e){e.resourceService="AzureResourceService",e.resourceGroupService="AzureResourceGroupService",e.cacheService="AzureResourceCacheService",e.accountService="AzureResourceAccountService",e.subscriptionService="AzureResourceSubscriptionService",e.subscriptionFilterService="AzureResourceSubscriptionFilterService",e.tenantService="AzureResourceTenantService",e.tenantFilterService="AzureResourceTenantFilterService",e.terminalService="AzureTerminalService"}(r||(t.AzureResourceServiceNames=r={})),function(e){e.logAnalytics="LogAnalytics_",e.cosmosdb="Cosmosdb_",e.database="database_",e.databaseServer="databaseServer_",e.kusto="Kusto_",e.mySqlFlexibleServer="mySqlFlexibleServer_",e.postgresServerArc="postgresServerArc_",e.postgresFlexibleServer="postgresFlexibleServer_",e.postgresServer="postgresServer_",e.sqlInstance="sqlInstance_",e.sqlInstanceArc="sqlInstanceArc_",e.synapseSqlPool="synapseSqlPool_",e.synapseWorkspace="synapseWorkspace_"}(o||(t.AzureResourcePrefixes=o={})),t.mssqlProvider="MSSQL",t.logAnalyticsProvider="LOGANALYTICS",t.cosmosDBMongoProvider="COSMOSDB_MONGO",t.cosmosDBNoSqlProvider="COSMOSDB_NOSQL",t.kustoProvider="KUSTO",t.mySqlProvider="MySQL",t.pgsqlProvider="PGSQL",t.analyticsKind="v12.0,analytics",t.mongoDbKind="MongoDB",t.cosmosDbNoSqlKind="GlobalDocumentDB",function(e){e[e.Server=0]="Server",e[e.Database=1]="Database"}(i||(t.ResourceCategory=i={}))},3042:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureSubscriptionError=void 0;const r=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/errors.ts"));class o extends Error{constructor(e,t){super(r(0,null,e)),this.errors=t}}t.AzureSubscriptionError=o},7182:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceMessageTreeNode=void 0;const r=n(1398),o=n(4729),i=n(7768);class s extends o.TreeNode{constructor(e,t){super(),this.message=e,this.parent=t,this._id="message_"+s._messageNum++}static create(e,t){return new s(e,t)}getChildren(){return[]}getTreeItem(){let e=new r.TreeItem(this.message,r.TreeItemCollapsibleState.None);return e.contextValue=i.AzureResourceItemType.message,e}getNodeInfo(){return{label:this.message,isLeaf:!0,errorMessage:void 0,metadata:void 0,nodePath:this.generateNodePath(),parentNodePath:this.parent?.generateNodePath()??"",nodeStatus:void 0,nodeType:i.AzureResourceItemType.message,nodeSubType:void 0,iconType:i.AzureResourceItemType.message}}get nodePathValue(){return this._id}}t.AzureResourceMessageTreeNode=s,s._messageNum=0},3528:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureMonitorResourceService=void 0;const r=n(4344),o=n(3614),i=n(3508);class s extends o.ResourceServiceBase{constructor(){super(...arguments),this.queryFilter=r.logAnalyticsQuery}convertServerResource(e){return{id:e.id,name:e.name,provider:i.AZURE_MONITOR_PROVIDER_ID,fullName:e.properties.customerId,loginName:"",defaultDatabaseName:"",subscription:{id:e.subscriptionId,name:e.subscriptionName||""},tenant:e.tenantId,resourceGroup:e.resourceGroup}}}t.AzureMonitorResourceService=s},7274:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureMonitorTreeDataProvider=void 0;const r=n(235),o=n(1398),i=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/providers/azuremonitor/azuremonitorTreeDataProvider.ts")),s=n(7768),a=n(6752),c=n(3614);class u extends c.ResourceTreeDataProviderBase{constructor(e,t){super(e),this._extensionContext=t}getTreeItemForResource(e,t){return{id:`${s.AzureResourcePrefixes.logAnalytics}${t.key.accountId}${e.tenant}${e.id?e.id:e.name}`,label:this.browseConnectionMode?`${e.name} (${u.containerLabel}, ${e.subscription.name})`:e.name,iconPath:this._extensionContext.asAbsolutePath("resources/logAnalyticsWorkspaces.svg"),collapsibleState:this.browseConnectionMode?o.TreeItemCollapsibleState.None:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.azureMonitor,payload:{id:(0,a.generateGuid)(),connectionName:void 0,serverName:e.fullName,databaseName:e.defaultDatabaseName,userName:e.loginName,password:"",authenticationType:r.connection.AuthenticationType.AzureMFA,savePassword:!0,groupFullName:"",groupId:"",providerName:s.logAnalyticsProvider,saveProfile:!1,options:{},azureAccount:t.key.accountId,azureTenantId:e.tenant,azureResourceId:e.id,azurePortalEndpoint:t.properties.providerSettings.settings.portalEndpoint},childProvider:s.logAnalyticsProvider,type:r.ExtensionNodeType.Server}}async getRootChild(){return{id:u.containerId,label:u.containerLabel,iconPath:this._extensionContext.asAbsolutePath("resources/logAnalyticsWorkspaces.svg"),collapsibleState:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.databaseServerContainer}}}t.AzureMonitorTreeDataProvider=u,u.containerId="azure.resource.providers.AzureMonitorContainer",u.containerLabel=i(0,null)},8111:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CosmosDbMongoService=void 0;const r=n(3614),o=n(4344),i=n(3508);class s extends r.ResourceServiceBase{constructor(){super(...arguments),this.queryFilter=o.cosmosMongoDbQuery}convertServerResource(e){let t=e.name;const n="microsoft.documentdb/mongoclusters"===e.type;return n&&(t=new URL(e.properties.connectionString).hostname),{id:e.id,name:e.name,provider:i.COSMOSDB_MONGO_PROVIDER_ID,isServer:n,fullName:t,loginName:e.properties.administratorLogin,defaultDatabaseName:"",tenant:e.tenantId,subscription:{id:e.subscriptionId,name:e.subscriptionName||""}}}}t.CosmosDbMongoService=s},7183:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CosmosDbMongoTreeDataProvider=void 0;const r=n(1398),o=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/providers/cosmosdb/mongo/cosmosDbMongoTreeDataProvider.ts")),i=n(7768),s=n(6752),a=n(3614),c=n(235);class u extends a.ResourceTreeDataProviderBase{constructor(e,t){super(e),this._extensionContext=t}getTreeItemForResource(e,t){return{id:`${i.AzureResourcePrefixes.cosmosdb}${t.key.accountId}${e.tenant}${e.id??e.name}`,label:this.browseConnectionMode?`${e.name} (${u.CONTAINER_LABEL}, ${e.subscription.name})`:`${e.name}`,iconPath:this._extensionContext.asAbsolutePath("resources/cosmosDb.svg"),collapsibleState:r.TreeItemCollapsibleState.None,contextValue:i.AzureResourceItemType.cosmosDBMongoAccount,payload:{id:(0,s.generateGuid)(),connectionName:e.name,serverName:e.fullName,userName:e.loginName,password:"",authenticationType:e.isServer?c.connection.AuthenticationType.SqlLogin:c.connection.AuthenticationType.AzureMFA,savePassword:!0,groupFullName:"",groupId:"",providerName:i.cosmosDBMongoProvider,saveProfile:!1,options:{isServer:e.isServer},azureAccount:t.key.accountId,azureTenantId:e.tenant,azureResourceId:e.id,azurePortalEndpoint:t.properties.providerSettings.settings.portalEndpoint},childProvider:i.cosmosDBMongoProvider,type:c.ExtensionNodeType.Server}}async getRootChild(){return{id:u.CONTAINER_ID,label:u.CONTAINER_LABEL,iconPath:this._extensionContext.asAbsolutePath("resources/cosmosDb.svg"),collapsibleState:r.TreeItemCollapsibleState.Collapsed,contextValue:i.AzureResourceItemType.databaseServerContainer}}}t.CosmosDbMongoTreeDataProvider=u,u.CONTAINER_ID="azure.resource.providers.databaseServer.treeDataProvider.cosmosDbMongoContainer",u.CONTAINER_LABEL=o(0,null)},9551:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CosmosDbNoSqlService=void 0;const r=n(3614),o=n(4344),i=n(3508);class s extends r.ResourceServiceBase{constructor(){super(...arguments),this.queryFilter=o.cosmosNoSqlQuery}convertServerResource(e){return{id:e.id,name:e.name,provider:i.COSMOSDB_NOSQL_PROVIDER_ID,fullName:e.properties.fullyQualifiedDomainName,loginName:e.properties.administratorLogin,defaultDatabaseName:"",tenant:e.tenantId,subscription:{id:e.subscriptionId,name:e.subscriptionName||""}}}}t.CosmosDbNoSqlService=s},3471:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CosmosDbNoSqlTreeDataProvider=void 0;const r=n(1398),o=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/providers/cosmosdb/nosql/cosmosDbNoSqlTreeDataProvider.ts")),i=n(7768),s=n(6752),a=n(3614),c=n(235);class u extends a.ResourceTreeDataProviderBase{constructor(e,t){super(e),this._extensionContext=t}getTreeItemForResource(e,t){return{id:`${i.AzureResourcePrefixes.cosmosdb}${t.key.accountId}${e.id??e.name}`,label:this.browseConnectionMode?`${e.name} (${u.CONTAINER_LABEL}, ${e.subscription.name})`:`${e.name}`,iconPath:this._extensionContext.asAbsolutePath("resources/cosmosDb.svg"),collapsibleState:r.TreeItemCollapsibleState.None,contextValue:i.AzureResourceItemType.cosmosDBNoSqlAccount,payload:{id:(0,s.generateGuid)(),connectionName:e.name,serverName:e.name,userName:e.loginName,password:"",authenticationType:c.connection.AuthenticationType.AzureMFA,savePassword:!0,groupFullName:"",groupId:"",providerName:i.cosmosDBNoSqlProvider,saveProfile:!1,options:{},azureAccount:t.key.accountId,azureTenantId:e.tenant,azureResourceId:e.id,azurePortalEndpoint:t.properties.providerSettings.settings.portalEndpoint},childProvider:i.cosmosDBNoSqlProvider,type:c.ExtensionNodeType.Server}}async getRootChild(){return{id:u.CONTAINER_ID,label:u.CONTAINER_LABEL,iconPath:this._extensionContext.asAbsolutePath("resources/cosmosDb.svg"),collapsibleState:r.TreeItemCollapsibleState.Collapsed,contextValue:i.AzureResourceItemType.databaseServerContainer}}}t.CosmosDbNoSqlTreeDataProvider=u,u.CONTAINER_ID="azure.resource.providers.databaseServer.treeDataProvider.cosmosDbNoSqlContainer",u.CONTAINER_LABEL=o(0,null)},7375:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CosmosDbPostgresService=void 0;const r=n(3614),o=n(4344),i=n(3508);class s extends r.ResourceServiceBase{constructor(){super(...arguments),this.queryFilter=o.cosmosPostgresDbQuery}convertServerResource(e){let t=e.name;const n="microsoft.documentdb/postgresclusters"===e.type;return n&&(t=new URL(e.properties.connectionString).hostname),{id:e.id,name:e.name,provider:i.COSMOSDB_POSTGRES_PROVIDER_ID,isServer:n,fullName:t,loginName:e.properties.administratorLogin,defaultDatabaseName:"",tenant:e.tenantId,subscription:{id:e.subscriptionId,name:e.subscriptionName||""}}}}t.CosmosDbPostgresService=s},6303:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CosmosDbPostgresTreeDataProvider=void 0;const r=n(1398),o=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/providers/cosmosdb/postgres/cosmosDbPostgresTreeDataProvider.ts")),i=n(7768),s=n(6752),a=n(3614),c=n(235);class u extends a.ResourceTreeDataProviderBase{constructor(e,t){super(e),this._extensionContext=t}getTreeItemForResource(e,t){return{id:`${i.AzureResourcePrefixes.cosmosdb}${t.key.accountId}${e.tenant}${e.id??e.name}`,label:this.browseConnectionMode?`${e.name} ${u.CONTAINER_LABEL}, ${e.subscription.name})`:e.name,iconPath:this._extensionContext.asAbsolutePath("resources/cosmosDb.svg"),collapsibleState:r.TreeItemCollapsibleState.None,contextValue:i.AzureResourceItemType.cosmosDBPostgresAccount,payload:{id:(0,s.generateGuid)(),connectionName:e.name,serverName:e.fullName,userName:e.loginName,password:"",authenticationType:e.isServer?c.connection.AuthenticationType.SqlLogin:c.connection.AuthenticationType.AzureMFA,savePassword:!0,groupFullName:"",groupId:"",providerName:i.pgsqlProvider,saveProfile:!1,options:{isServer:e.isServer},azureAccount:t.key.accountId,azureTenantId:e.tenant,azureResourceId:e.id,azurePortalEndpoint:t.properties.providerSettings.settings.portalEndpoint},childProvider:i.pgsqlProvider,type:c.ExtensionNodeType.Server}}async getRootChild(){return{id:u.CONTAINER_ID,label:u.CONTAINER_LABEL,iconPath:this._extensionContext.asAbsolutePath("resources/cosmosDb.svg"),collapsibleState:r.TreeItemCollapsibleState.Collapsed,contextValue:i.AzureResourceItemType.databaseServerContainer}}}t.CosmosDbPostgresTreeDataProvider=u,u.CONTAINER_ID="azure.resource.providers.databaseServer.treeDataProvider.cosmosDbPostgresContainer",u.CONTAINER_LABEL=o(0,null)},5180:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceDatabaseService=void 0;const r=n(4344),o=n(3311),i=n(3614),s=n(3508);t.AzureResourceDatabaseService=class{constructor(){this.queryFilter=r.sqlDatabaseQuery}async getResources(e,t,n){const s=[],a=new o.ResourceGraphClient(t,{baseUri:n.properties.providerSettings.settings.armResource.endpoint});let c=(0,i.queryGraphResources)(a,e,r.where+r.sqlServerQuery),u=(0,i.queryGraphResources)(a,e,r.where+this.queryFilter),l=await c,p=await u,d=new Map;l.forEach((e=>{let t=d.get(e.resourceGroup)||[];t.push(e),d.set(e.resourceGroup,t)}));const h=new RegExp("/subscriptions/.+/resourceGroups/(.+)/providers/Microsoft.Sql/servers/(.+)/databases/.+"),f=new RegExp("/subscriptions/.+/resourceGroups/(.+)/providers/Microsoft.Synapse/workspaces/(.+)/databases/.+");return p.forEach((e=>{if(d.get(e.resourceGroup)&&!e.kind.endsWith("system")&&(h.test(e.id)||f.test(e.id))){const t=h.exec(e.id)??f.exec(e.id);if(!t)return void console.warn(`Could not parse server name from ID ${e.id}`);const n=t[2];let r=l.find((e=>e.name===n));r&&s.push(this.convertDatabaseResource(e,r))}})),s}convertDatabaseResource(e,t){return t?{name:e.name,id:e.id,provider:s.DATABASE_PROVIDER_ID,serverName:t.name,serverFullName:t.properties.fullyQualifiedDomainName,loginName:t.properties.administratorLogin,subscription:{id:e.subscriptionId,name:e.subscriptionName},tenant:e.tenantId,resourceGroup:e.resourceGroup}:void 0}}},4134:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceDatabaseTreeDataProvider=void 0;const r=n(235),o=n(1398),i=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/providers/database/databaseTreeDataProvider.ts")),s=n(7768),a=n(6752),c=n(3614);class u extends c.ResourceTreeDataProviderBase{constructor(e,t){super(e),this._extensionContext=t}getTreeItemForResource(e,t){return{id:`${s.AzureResourcePrefixes.database}${t.key.accountId}${e.tenant}${e.serverFullName}.${s.AzureResourcePrefixes.database}${e.id??e.name}`,label:this.browseConnectionMode?`${e.serverName}/${e.name} (${u.containerLabel}, ${e.subscription.name})`:`${e.name} (${e.serverName})`,iconPath:this._extensionContext.asAbsolutePath("resources/sqlDatabase.svg"),collapsibleState:this.browseConnectionMode?o.TreeItemCollapsibleState.None:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.database,payload:{id:(0,a.generateGuid)(),connectionName:void 0,serverName:e.serverFullName,databaseName:e.name,userName:e.loginName,password:"",authenticationType:"",savePassword:!0,groupFullName:"",groupId:"",providerName:s.mssqlProvider,saveProfile:!1,options:{},azureAccount:t.key.accountId,azureResourceId:e.id,azureTenantId:e.tenant,azurePortalEndpoint:t.properties.providerSettings.settings.portalEndpoint},childProvider:s.mssqlProvider,type:r.ExtensionNodeType.Database}}async getRootChild(){return{id:u.containerId,label:u.containerLabel,iconPath:this._extensionContext.asAbsolutePath("resources/sqlDatabase.svg"),collapsibleState:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.databaseContainer}}}t.AzureResourceDatabaseTreeDataProvider=u,u.containerId="azure.resource.providers.database.treeDataProvider.databaseContainer",u.containerLabel=i(0,null)},694:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceDatabaseServerService=void 0;const r=n(3311),o=n(3614),i=n(4344),s=n(3508);t.AzureResourceDatabaseServerService=class{constructor(){this.queryFilter=i.sqlServerQuery}async getResources(e,t,n){const s=[],a=new r.ResourceGraphClient(t,{baseUri:n.properties.providerSettings.settings.armResource.endpoint});let c=await(0,o.queryGraphResources)(a,e,i.where+this.queryFilter);const u=new Set;return c.forEach((t=>{if(!u.has(t.id)){u.add(t.id),t.subscriptionName=e.find((e=>e.id===t.subscriptionId))?.name;const n=this.convertServerResource(t);s.push(n)}})),s}convertServerResource(e){return{id:e.id,name:e.name,provider:s.DATABASE_SERVER_PROVIDER_ID,fullName:e.properties.fullyQualifiedDomainName,loginName:e.properties.administratorLogin,defaultDatabaseName:"master",subscription:{id:e.subscriptionId,name:e.subscriptionName||""},tenant:e.tenantId,resourceGroup:e.resourceGroup}}}},3992:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceDatabaseServerTreeDataProvider=void 0;const r=n(235),o=n(1398),i=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/providers/databaseServer/databaseServerTreeDataProvider.ts")),s=n(7768),a=n(6752),c=n(3614);class u extends c.ResourceTreeDataProviderBase{constructor(e,t){super(e),this._extensionContext=t}getTreeItemForResource(e,t){return{id:`${s.AzureResourcePrefixes.databaseServer}${t.key.accountId}${e.tenant}${e.id??e.name}`,label:this.browseConnectionMode?`${e.name} (${u.containerLabel}, ${e.subscription.name})`:e.name,iconPath:this._extensionContext.asAbsolutePath("resources/sqlServer.svg"),collapsibleState:this.browseConnectionMode?o.TreeItemCollapsibleState.None:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.databaseServer,payload:{id:(0,a.generateGuid)(),connectionName:void 0,serverName:e.fullName,databaseName:e.defaultDatabaseName,userName:e.loginName,password:"",authenticationType:"",savePassword:!0,groupFullName:"",groupId:"",providerName:s.mssqlProvider,saveProfile:!1,options:{},azureAccount:t.key.accountId,azureTenantId:e.tenant,azureResourceId:e.id,azurePortalEndpoint:t.properties.providerSettings.settings.portalEndpoint},childProvider:s.mssqlProvider,type:r.ExtensionNodeType.Server}}async getRootChild(){return{id:u.containerId,label:u.containerLabel,iconPath:this._extensionContext.asAbsolutePath("resources/sqlServer.svg"),collapsibleState:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.databaseServerContainer}}}t.AzureResourceDatabaseServerTreeDataProvider=u,u.containerId="azure.resource.providers.databaseServer.treeDataProvider.databaseServerContainer",u.containerLabel=i(0,null)},272:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.KustoResourceService=void 0;const r=n(4344),o=n(3614),i=n(3508);class s extends o.ResourceServiceBase{constructor(){super(...arguments),this.queryFilter=r.kustoClusterQuery}convertServerResource(e){return{id:e.id,name:e.name,provider:i.KUSTO_PROVIDER_ID,fullName:e.properties.uri.replace("https://",""),loginName:"",defaultDatabaseName:"",subscription:{id:e.subscriptionId,name:e.subscriptionName||""},tenant:e.tenantId,resourceGroup:e.resourceGroup}}}t.KustoResourceService=s},5778:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.KustoTreeDataProvider=void 0;const r=n(235),o=n(1398),i=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/providers/kusto/kustoTreeDataProvider.ts")),s=n(7768),a=n(6752),c=n(3614);class u extends c.ResourceTreeDataProviderBase{constructor(e,t){super(e),this._extensionContext=t}getTreeItemForResource(e,t){return{id:`${s.AzureResourcePrefixes.kusto}${t.key.accountId}${e.tenant}${e.id??e.name}`,label:this.browseConnectionMode?`${e.name} (${u.containerLabel}, ${e.subscription.name})`:e.name,iconPath:this._extensionContext.asAbsolutePath("resources/dataExplorerClusterDb.svg"),collapsibleState:this.browseConnectionMode?o.TreeItemCollapsibleState.None:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.azureDataExplorer,payload:{id:(0,a.generateGuid)(),connectionName:void 0,serverName:e.fullName,databaseName:e.defaultDatabaseName,userName:e.loginName,password:"",authenticationType:r.connection.AuthenticationType.AzureMFA,savePassword:!0,groupFullName:"",groupId:"",providerName:s.kustoProvider,saveProfile:!1,options:{},azureAccount:t.key.accountId,azureTenantId:e.tenant,azureResourceId:e.id,azurePortalEndpoint:t.properties.providerSettings.settings.portalEndpoint},childProvider:s.kustoProvider,type:r.ExtensionNodeType.Server}}async getRootChild(){return{id:u.containerId,label:u.containerLabel,iconPath:this._extensionContext.asAbsolutePath("resources/dataExplorerClusterDb.svg"),collapsibleState:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.databaseServerContainer}}}t.KustoTreeDataProvider=u,u.containerId="azure.resource.providers.KustoContainer",u.containerLabel=i(0,null)},6516:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MysqlFlexibleServerService=void 0;const r=n(3614),o=n(4344),i=n(3508);class s extends r.ResourceServiceBase{constructor(){super(...arguments),this.queryFilter=o.mysqlFlexibleServerQuery}convertServerResource(e){return{id:e.id,name:e.name,provider:i.MYSQL_FLEXIBLE_SERVER_PROVIDER_ID,fullName:e.properties.fullyQualifiedDomainName,loginName:e.properties.administratorLogin,defaultDatabaseName:"",tenant:e.tenantId,subscription:{id:e.subscriptionId,name:e.subscriptionName||""},resourceGroup:e.resourceGroup}}}t.MysqlFlexibleServerService=s},8174:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MysqlFlexibleServerTreeDataProvider=void 0;const r=n(1398),o=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/providers/mysqlFlexibleServer/mysqlFlexibleServerTreeDataProvider.ts")),i=n(7768),s=n(6752),a=n(3614),c=n(235);class u extends a.ResourceTreeDataProviderBase{constructor(e,t){super(e),this._extensionContext=t}getTreeItemForResource(e,t){return{id:`${i.AzureResourcePrefixes.mySqlFlexibleServer}${t.key.accountId}${e.tenant}${e.id??e.name}`,label:this.browseConnectionMode?`${e.name} (${u.CONTAINER_LABEL}, ${e.subscription.name})`:e.name,iconPath:this._extensionContext.asAbsolutePath("resources/mysqlDatabase.svg"),collapsibleState:this.browseConnectionMode?r.TreeItemCollapsibleState.None:r.TreeItemCollapsibleState.Collapsed,contextValue:i.AzureResourceItemType.databaseServer,payload:{id:(0,s.generateGuid)(),connectionName:void 0,serverName:e.fullName,databaseName:e.defaultDatabaseName,userName:e.loginName,password:"",authenticationType:c.connection.AuthenticationType.SqlLogin,savePassword:!0,groupFullName:"",groupId:"",providerName:i.mySqlProvider,saveProfile:!1,options:{},azureAccount:t.key.accountId,azureTenantId:e.tenant,azureResourceId:e.id,azurePortalEndpoint:t.properties.providerSettings.settings.portalEndpoint},childProvider:i.mySqlProvider,type:c.ExtensionNodeType.Server}}async getRootChild(){return{id:u.CONTAINER_ID,label:u.CONTAINER_LABEL,iconPath:this._extensionContext.asAbsolutePath("resources/mysqlDatabase.svg"),collapsibleState:r.TreeItemCollapsibleState.Collapsed,contextValue:i.AzureResourceItemType.databaseServerContainer}}}t.MysqlFlexibleServerTreeDataProvider=u,u.CONTAINER_ID="azure.resource.providers.databaseServer.treeDataProvider.mysqlFlexibleServerContainer",u.CONTAINER_LABEL=o(0,null)},2032:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PostgresServerArcService=void 0;const r=n(3614),o=n(4344),i=n(3508);class s extends r.ResourceServiceBase{constructor(){super(...arguments),this.queryFilter=o.postgresArcServerQuery}convertServerResource(e){return{id:e.id,name:e.name,provider:i.POSTGRES_ARC_SERVER_PROVIDER_ID,fullName:e.name,loginName:e.properties.admin,defaultDatabaseName:"postgres",subscription:{id:e.subscriptionId,name:e.subscriptionName||""},tenant:e.tenantId,resourceGroup:e.resourceGroup}}}t.PostgresServerArcService=s},3522:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PostgresServerArcTreeDataProvider=void 0;const r=n(235),o=n(1398),i=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/providers/postgresArcServer/postgresArcServerTreeDataProvider.ts")),s=n(7768),a=n(6752),c=n(3614);class u extends c.ResourceTreeDataProviderBase{constructor(e,t){super(e),this._extensionContext=t}getTreeItemForResource(e,t){return{id:`${s.AzureResourcePrefixes.postgresServerArc}${t.key.accountId}${e.tenant}${e.id??e.name}`,label:this.browseConnectionMode?`${e.name} (${u.containerLabel}, ${e.subscription.name})`:e.name,iconPath:this._extensionContext.asAbsolutePath("resources/azureArcPostgresServer.svg"),collapsibleState:this.browseConnectionMode?o.TreeItemCollapsibleState.None:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.databaseServer,payload:{id:(0,a.generateGuid)(),connectionName:void 0,serverName:e.fullName,databaseName:e.defaultDatabaseName,userName:`${e.loginName}@${e.fullName}`,password:"",authenticationType:r.connection.AuthenticationType.SqlLogin,savePassword:!0,groupFullName:"",groupId:"",providerName:s.pgsqlProvider,saveProfile:!1,options:{sslmode:"require"},azureAccount:t.key.accountId,azureTenantId:e.tenant,azureResourceId:e.id,azurePortalEndpoint:t.properties.providerSettings.settings.portalEndpoint},childProvider:s.pgsqlProvider,type:r.ExtensionNodeType.Server}}async getRootChild(){return{id:u.containerId,label:u.containerLabel,iconPath:this._extensionContext.asAbsolutePath("resources/azureArcPostgresServer.svg"),collapsibleState:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.databaseServerContainer}}}t.PostgresServerArcTreeDataProvider=u,u.containerId="azure.resource.providers.postgresArcServer.treeDataProvider.postgresServerContainer",u.containerLabel=i(0,null)},5284:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PostgresFlexibleServerService=void 0;const r=n(3614),o=n(4344),i=n(3508);class s extends r.ResourceServiceBase{constructor(){super(...arguments),this.queryFilter=o.postgresFlexibleServerQuery}convertServerResource(e){return{id:e.id,name:e.name,provider:i.POSTGRES_FLEXIBLE_SERVER_PROVIDER_ID,fullName:e.properties.fullyQualifiedDomainName,loginName:e.properties.administratorLogin,defaultDatabaseName:"postgres",subscription:{id:e.subscriptionId,name:e.subscriptionName||""},tenant:e.tenantId,resourceGroup:e.resourceGroup}}}t.PostgresFlexibleServerService=s},1342:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PostgresFlexibleServerTreeDataProvider=void 0;const r=n(235),o=n(1398),i=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/providers/postgresFlexibleServer/postgresFlexibleServerTreeDataProvider.ts")),s=n(7768),a=n(6752),c=n(3614);class u extends c.ResourceTreeDataProviderBase{constructor(e,t){super(e),this._extensionContext=t}getTreeItemForResource(e,t){return{id:`${s.AzureResourcePrefixes.postgresFlexibleServer}${t.key.accountId}${e.tenant}${e.id??e.name}`,label:this.browseConnectionMode?`${e.name} (${u.containerLabel}, ${e.subscription.name})`:e.name,iconPath:this._extensionContext.asAbsolutePath("resources/postgresServer.svg"),collapsibleState:this.browseConnectionMode?o.TreeItemCollapsibleState.None:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.databaseServer,payload:{id:(0,a.generateGuid)(),connectionName:void 0,serverName:e.fullName,databaseName:e.defaultDatabaseName,userName:`${e.loginName}@${e.fullName}`,password:"",authenticationType:r.connection.AuthenticationType.SqlLogin,savePassword:!0,groupFullName:"",groupId:"",providerName:s.pgsqlProvider,saveProfile:!1,options:{sslmode:"require"},azureAccount:t.key.accountId,azureTenantId:e.tenant,azureResourceId:e.id,azurePortalEndpoint:t.properties.providerSettings.settings.portalEndpoint},childProvider:s.pgsqlProvider,type:r.ExtensionNodeType.Server}}async getRootChild(){return{id:u.containerId,label:u.containerLabel,iconPath:this._extensionContext.asAbsolutePath("resources/postgresServer.svg"),collapsibleState:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.databaseServerContainer}}}t.PostgresFlexibleServerTreeDataProvider=u,u.containerId="azure.resource.providers.databaseServer.treeDataProvider.postgresFlexibleServerContainer",u.containerLabel=i(0,null)},6706:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PostgresServerService=void 0;const r=n(3614),o=n(4344),i=n(3508);class s extends r.ResourceServiceBase{constructor(){super(...arguments),this.queryFilter=o.postgresServerQuery}convertServerResource(e){return{id:e.id,name:e.name,provider:i.POSTGRES_SERVER_PROVIDER_ID,fullName:e.properties.fullyQualifiedDomainName,loginName:e.properties.administratorLogin,defaultDatabaseName:"postgres",subscription:{id:e.subscriptionId,name:e.subscriptionName||""},tenant:e.tenantId,resourceGroup:e.resourceGroup}}}t.PostgresServerService=s},6556:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PostgresServerTreeDataProvider=void 0;const r=n(235),o=n(1398),i=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/providers/postgresServer/postgresServerTreeDataProvider.ts")),s=n(7768),a=n(6752),c=n(3614);class u extends c.ResourceTreeDataProviderBase{constructor(e,t){super(e),this._extensionContext=t}getTreeItemForResource(e,t){return{id:`${s.AzureResourcePrefixes.postgresServer}${t.key.accountId}${e.tenant}${e.id??e.name}`,label:this.browseConnectionMode?`${e.name} (${u.containerLabel}, ${e.subscription.name})`:e.name,iconPath:this._extensionContext.asAbsolutePath("resources/postgresServer.svg"),collapsibleState:this.browseConnectionMode?o.TreeItemCollapsibleState.None:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.databaseServer,payload:{id:(0,a.generateGuid)(),connectionName:void 0,serverName:e.fullName,databaseName:e.defaultDatabaseName,userName:`${e.loginName}@${e.fullName}`,password:"",authenticationType:r.connection.AuthenticationType.SqlLogin,savePassword:!0,groupFullName:"",groupId:"",providerName:s.pgsqlProvider,saveProfile:!1,options:{sslmode:"require"},azureAccount:t.key.accountId,azureTenantId:e.tenant,azureResourceId:e.id,azurePortalEndpoint:t.properties.providerSettings.settings.portalEndpoint},childProvider:s.pgsqlProvider,type:r.ExtensionNodeType.Server}}async getRootChild(){return{id:u.containerId,label:u.containerLabel,iconPath:this._extensionContext.asAbsolutePath("resources/postgresServer.svg"),collapsibleState:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.databaseServerContainer}}}t.PostgresServerTreeDataProvider=u,u.containerId="azure.resource.providers.databaseServer.treeDataProvider.postgresServerContainer",u.containerLabel=i(0,null)},4344:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.logAnalyticsQuery=t.cosmosNoSqlQuery=t.cosmosPostgresDbQuery=t.cosmosMongoDbQuery=t.kustoClusterQuery=t.mysqlFlexibleServerQuery=t.postgresArcServerQuery=t.postgresFlexibleServerQuery=t.postgresServerQuery=t.resourceGroupQuery=t.sqlInstanceQuery=t.sqlInstanceArcQuery=t.sqlServerQuery=t.synapseSqlPoolsQuery=t.synapseWorkspacesQuery=t.sqlDatabaseQuery=t.where=void 0;const r=n(7768);t.where="where ",t.sqlDatabaseQuery='type == "microsoft.sql/servers/databases" or type == "microsoft.synapse/workspaces/sqldatabases"',t.synapseWorkspacesQuery='type == "microsoft.synapse/workspaces"',t.synapseSqlPoolsQuery='type == "microsoft.synapse/workspaces/sqlpools"',t.sqlServerQuery=`type == "microsoft.sql/servers" and kind != "${r.analyticsKind}"`,t.sqlInstanceArcQuery='type == "microsoft.azuredata/sqlmanagedinstances"',t.sqlInstanceQuery='type == "microsoft.sql/managedinstances"',t.resourceGroupQuery='ResourceContainers | where type=="microsoft.resources/subscriptions/resourcegroups"',t.postgresServerQuery='type == "microsoft.dbforpostgresql/servers" or type == "microsoft.dbforpostgresql/serversv2" or type == "microsoft.dbforpostgresql/singleservers"',t.postgresFlexibleServerQuery='type == "microsoft.dbforpostgresql/flexibleservers"',t.postgresArcServerQuery='type == "microsoft.azuredata/postgresinstances"',t.mysqlFlexibleServerQuery='type == "microsoft.dbformysql/flexibleservers"',t.kustoClusterQuery='type == "microsoft.kusto/clusters"',t.cosmosMongoDbQuery=`(type == "microsoft.documentdb/databaseaccounts" and kind == "${r.mongoDbKind}") or type == "microsoft.documentdb/mongoclusters"`,t.cosmosPostgresDbQuery='type == "microsoft.dbforpostgresql/servergroups" or type == "microsoft.dbforpostgresql/servergroupsv2"',t.cosmosNoSqlQuery=`type == "microsoft.documentdb/databaseaccounts" and kind == "${r.cosmosDbNoSqlKind}"`,t.logAnalyticsQuery='type == "microsoft.operationalinsights/workspaces"'},9084:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceGroupService=void 0;const r=n(3614),o=n(4344);class i extends r.ResourceServiceBase{constructor(){super(...arguments),this.queryFilter=o.resourceGroupQuery}convertServerResource(e){return{id:e.id,name:e.name,subscription:{id:e.subscriptionId,name:e.subscriptionName||""},tenant:e.tenantId}}}t.AzureResourceGroupService=i},8151:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ResourceProvider=void 0,t.ResourceProvider=class{constructor(e,t){this._providerId=e,this._treeProvider=t}getTreeDataProvider(){return this._treeProvider}get providerId(){return this._providerId}}},3614:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ResourceServiceBase=t.queryGraphResources=t.ResourceTreeDataProviderBase=void 0;const r=n(235),o=n(3253),i=n(6752),s=n(3311),a=n(7147),c=n(4344);async function u(e,t,n){const r=[];let o=0,i=async s=>{const a=await e.resources({subscriptions:t.map((e=>e.id)),query:n,options:{resultFormat:"objectArray",skipToken:s}}),c=a.data;o+=c.length,r.push(...c),a.skipToken&&o<a.totalRecords&&await i(a.skipToken)};try{await i()}catch(e){try{if(e.response?.body){const t=JSON.parse(e.response.body);t.error?.details&&Array.isArray(t.error.details)&&t.error.details.length>0&&(t.error.details[0].message&&(e.message=`${t.error.details[0].message}\n${e.message}`),t.error.details[0].code&&(e.message=`${e.message} (${t.error.details[0].code})`))}}catch(e){a.Logger.error(`Unexpected error while parsing error from querying resources : ${e}`)}throw e}return r}t.ResourceTreeDataProviderBase=class{constructor(e){this._resourceService=e,this.browseConnectionMode=!1}getService(){return this._resourceService}async getChildren(e){try{return(await this.getResources(e)).map((t=>this.convertDataToResource(t,e))).sort(((e,t)=>e.treeItem.label.localeCompare(t.treeItem.label)))}catch(e){throw a.Logger.error(i.AzureResourceErrorMessageUtil.getErrorMessage(e)),e}}convertDataToResource(e,t){return{account:t.account,subscription:t.subscription,tenantId:t.subscription.tenant,treeItem:this.getTreeItemForResource(e,t.account)}}async getResources(e){const t=await r.accounts.getAccountSecurityToken(e.account,e.subscription.tenant,r.AzureResource.ResourceManagement);if(!t)throw new Error(`Did not receive security token when getting resources for account ${e.account.displayInfo.displayName}`);const n=new o.TokenCredentials(t.token,t.tokenType);return await this._resourceService.getResources([e.subscription],n,e.account)||[]}},t.queryGraphResources=u,t.ResourceServiceBase=class{async getResources(e,t,n){const r=[],o=new s.ResourceGraphClient(t,{baseUri:n.properties.providerSettings.settings.armResource.endpoint}),i=this.queryFilter===c.resourceGroupQuery?this.queryFilter:c.where+this.queryFilter,a=await u(o,e,i),l=new Set;return a.forEach((t=>{if(!l.has(t.id)){l.add(t.id),t.subscriptionName=e.find((e=>e.id===t.subscriptionId))?.name;const n=this.convertServerResource(t);r.push(n)}})),r}}},6948:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SqlInstanceResourceService=void 0;const r=n(4344),o=n(3614),i=n(3508);class s extends o.ResourceServiceBase{constructor(){super(...arguments),this.queryFilter=r.sqlInstanceQuery}convertServerResource(e){return{id:e.id,name:e.name,provider:i.SQLINSTANCE_PROVIDER_ID,fullName:e.properties.fullyQualifiedDomainName,loginName:e.properties.administratorLogin,defaultDatabaseName:"master",subscription:{id:e.subscriptionId,name:e.subscriptionName||""},tenant:e.tenantId,resourceGroup:e.resourceGroup}}}t.SqlInstanceResourceService=s},4670:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SqlInstanceTreeDataProvider=void 0;const r=n(235),o=n(1398),i=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/providers/sqlinstance/sqlInstanceTreeDataProvider.ts")),s=n(7768),a=n(6752),c=n(3614);class u extends c.ResourceTreeDataProviderBase{constructor(e,t){super(e),this._extensionContext=t}getTreeItemForResource(e,t){return{id:`${s.AzureResourcePrefixes.sqlInstance}${t.key.accountId}${e.tenant}${t.key.accountId}${e.id??e.name}`,label:this.browseConnectionMode?`${e.name} (${u.containerLabel}, ${e.subscription.name})`:e.name,iconPath:this._extensionContext.asAbsolutePath("resources/sqlManagedInstance.svg"),collapsibleState:this.browseConnectionMode?o.TreeItemCollapsibleState.None:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.databaseServer,payload:{id:(0,a.generateGuid)(),connectionName:void 0,serverName:e.fullName,databaseName:e.defaultDatabaseName,userName:e.loginName,password:"",authenticationType:r.connection.AuthenticationType.SqlLogin,savePassword:!0,groupFullName:"",groupId:"",providerName:s.mssqlProvider,saveProfile:!1,options:{},azureAccount:t.key.accountId,azureTenantId:e.tenant,azureResourceId:e.id,azurePortalEndpoint:t.properties.providerSettings.settings.portalEndpoint},childProvider:s.mssqlProvider,type:r.ExtensionNodeType.Server}}async getRootChild(){return{id:u.containerId,label:u.containerLabel,iconPath:this._extensionContext.asAbsolutePath("resources/sqlManagedInstance.svg"),collapsibleState:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.databaseServerContainer}}}t.SqlInstanceTreeDataProvider=u,u.containerId="azure.resource.providers.sqlInstanceContainer",u.containerLabel=i(0,null)},3292:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SqlInstanceArcResourceService=void 0;const r=n(3614),o=n(4344),i=n(3508);class s extends r.ResourceServiceBase{constructor(){super(...arguments),this.queryFilter=o.sqlInstanceArcQuery}convertServerResource(e){return{id:e.id,name:e.name,provider:i.SQLINSTANCE_ARC_PROVIDER_ID,fullName:e.name,loginName:e.properties.admin,defaultDatabaseName:"master",subscription:{id:e.subscriptionId,name:e.subscriptionName||""},tenant:e.tenantId,resourceGroup:e.resourceGroup}}}t.SqlInstanceArcResourceService=s},2758:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SqlInstanceArcTreeDataProvider=void 0;const r=n(235),o=n(1398),i=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/providers/sqlinstanceArc/sqlInstanceArcTreeDataProvider.ts")),s=n(7768),a=n(6752),c=n(3614);class u extends c.ResourceTreeDataProviderBase{constructor(e,t){super(e),this._extensionContext=t}getTreeItemForResource(e,t){return{id:`${s.AzureResourcePrefixes.sqlInstanceArc}${t.key.accountId}${e.tenant}${e.id??e.name}`,label:this.browseConnectionMode?`${e.name} (${u.containerLabel}, ${e.subscription.name})`:e.name,iconPath:this._extensionContext.asAbsolutePath("resources/azureArcSqlManagedInstance.svg"),collapsibleState:this.browseConnectionMode?o.TreeItemCollapsibleState.None:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.databaseServer,payload:{id:(0,a.generateGuid)(),connectionName:void 0,serverName:e.fullName,databaseName:e.defaultDatabaseName,userName:e.loginName,password:"",authenticationType:r.connection.AuthenticationType.SqlLogin,savePassword:!0,groupFullName:"",groupId:"",providerName:s.mssqlProvider,saveProfile:!1,options:{},azureAccount:t.key.accountId,azureTenantId:e.tenant,azureResourceId:e.id,azurePortalEndpoint:t.properties.providerSettings.settings.portalEndpoint},childProvider:s.mssqlProvider,type:r.ExtensionNodeType.Server}}async getRootChild(){return{id:u.containerId,label:u.containerLabel,iconPath:this._extensionContext.asAbsolutePath("resources/azureArcSqlManagedInstance.svg"),collapsibleState:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.databaseServerContainer}}}t.SqlInstanceArcTreeDataProvider=u,u.containerId="azure.resource.providers.sqlInstanceArcContainer",u.containerLabel=i(0,null)},7936:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceSynapseService=void 0;const r=n(4344),o=n(3311),i=n(3614),s=n(3508);t.AzureResourceSynapseService=class{constructor(){this.queryFilter=r.synapseSqlPoolsQuery}convertDatabaseResource(e,t){return t?{name:e.name,id:e.id,provider:s.SYNAPSE_SQL_POOL_PROVIDER_ID,serverName:t.name,serverFullName:t.properties.connectivityEndpoints?.sql,loginName:t.properties.sqlAdministratorLogin,subscription:{id:e.subscriptionId,name:e.subscriptionName},tenant:e.tenantId,resourceGroup:e.resourceGroup}:void 0}async getResources(e,t,n){const s=[],a=new o.ResourceGraphClient(t,{baseUri:n.properties.providerSettings.settings.armResource.endpoint});let c=(0,i.queryGraphResources)(a,e,r.where+this.queryFilter),u=(0,i.queryGraphResources)(a,e,r.where+r.synapseWorkspacesQuery),l=await c,p=await u,d=new Map;p.forEach((e=>{let t=d.get(e.properties.managedResourceGroupName)||[];t.push(e),d.set(e.properties.managedResourceGroupName,t)}));const h=new RegExp("/subscriptions/.+/resourceGroups/(.+)/providers/Microsoft.Synapse/workspaces/(.+)/sqlPools/.+");return l.forEach((e=>{if(!e.kind.endsWith("system")&&h.test(e.id)){const t=h.exec(e.id);if(!t)return void console.warn(`Could not parse server name from ID ${e.id}`);const n=t[2];let r=p.find((e=>e.name===n));if(r){let t=this.convertDatabaseResource(e,r);s.push(t)}}})),s}}},4034:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceSynapseSqlPoolTreeDataProvider=void 0;const r=n(235),o=n(1398),i=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/providers/synapseSqlPool/synapseSqlPoolTreeDataProvider.ts")),s=n(7768),a=n(6752),c=n(3614);class u extends c.ResourceTreeDataProviderBase{constructor(e,t){super(e),this._extensionContext=t}getTreeItemForResource(e,t){return{id:`${s.AzureResourcePrefixes.synapseWorkspace}${t.key.accountId}${e.tenant}${e.serverFullName}.${s.AzureResourcePrefixes.synapseSqlPool}${e.id??e.name}`,label:this.browseConnectionMode?`${e.serverName}/${e.name} (${u.containerLabel}, ${e.subscription.name})`:`${e.name} (${e.serverName})`,iconPath:this._extensionContext.asAbsolutePath("resources/sqlPools.svg"),collapsibleState:this.browseConnectionMode?o.TreeItemCollapsibleState.None:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.synapseSqlPool,payload:{id:(0,a.generateGuid)(),connectionName:void 0,serverName:e.serverFullName,databaseName:e.name,userName:e.loginName,password:"",authenticationType:"",savePassword:!0,groupFullName:"",groupId:"",providerName:s.mssqlProvider,saveProfile:!1,options:{},azureAccount:t.key.accountId,azureResourceId:e.id,azureTenantId:e.tenant,azurePortalEndpoint:t.properties.providerSettings.settings.portalEndpoint},childProvider:s.mssqlProvider,type:r.ExtensionNodeType.Database}}async getRootChild(){return{id:u.containerId,label:u.containerLabel,iconPath:this._extensionContext.asAbsolutePath("resources/sqlPools.svg"),collapsibleState:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.synapseSqlPoolContainer}}}t.AzureResourceSynapseSqlPoolTreeDataProvider=u,u.containerId="azure.resource.providers.synapseSqlPool.treeDataProvider.synapseSqlPoolContainer",u.containerLabel=i(0,null)},7350:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceSynapseWorkspaceService=void 0;const r=n(3311),o=n(3614),i=n(4344),s=n(3508);t.AzureResourceSynapseWorkspaceService=class{constructor(){this.queryFilter=i.synapseWorkspacesQuery}async getResources(e,t,n){const s=[],a=new r.ResourceGraphClient(t,{baseUri:n.properties.providerSettings.settings.armResource.endpoint});let c=await(0,o.queryGraphResources)(a,e,i.where+this.queryFilter);const u=new Set;return c.forEach((t=>{if(!u.has(t.id)){u.add(t.id),t.subscriptionName=e.find((e=>e.id===t.subscriptionId))?.name;const n=this.convertServerResource(t);s.push(n)}})),s}convertServerResource(e){return{id:e.id,name:e.name,provider:s.SYNAPSE_WORKSPACE_PROVIDER_ID,fullName:e.properties.connectivityEndpoints?.sql,loginName:e.properties.sqlAdministratorLogin,defaultDatabaseName:"master",subscription:{id:e.subscriptionId,name:e.subscriptionName||""},tenant:e.tenantId,resourceGroup:e.resourceGroup}}}},7304:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceSynapseWorkspaceTreeDataProvider=void 0;const r=n(235),o=n(1398),i=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/providers/synapseWorkspace/synapseWorkspaceTreeDataProvider.ts")),s=n(7768),a=n(6752),c=n(3614);class u extends c.ResourceTreeDataProviderBase{constructor(e,t){super(e),this._extensionContext=t}getTreeItemForResource(e,t){return{id:`${s.AzureResourcePrefixes.synapseWorkspace}${t.key.accountId}${e.tenant}${e.id??e.name}`,label:this.browseConnectionMode?`${e.name} (${u.containerLabel}, ${e.subscription.name})`:e.name,iconPath:this._extensionContext.asAbsolutePath("resources/azureSynapseAnalytics.svg"),collapsibleState:this.browseConnectionMode?o.TreeItemCollapsibleState.None:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.synapseWorkspace,payload:{id:(0,a.generateGuid)(),connectionName:void 0,serverName:e.fullName,databaseName:e.defaultDatabaseName,userName:e.loginName,password:"",authenticationType:"",savePassword:!0,groupFullName:"",groupId:"",providerName:s.mssqlProvider,saveProfile:!1,options:{},azureAccount:t.key.accountId,azureTenantId:e.tenant,azureResourceId:e.id,azurePortalEndpoint:t.properties.providerSettings.settings.portalEndpoint},childProvider:s.mssqlProvider,type:r.ExtensionNodeType.Server}}async getRootChild(){return{id:u.containerId,label:u.containerLabel,iconPath:this._extensionContext.asAbsolutePath("resources/azureSynapseAnalytics.svg"),collapsibleState:o.TreeItemCollapsibleState.Collapsed,contextValue:s.AzureResourceItemType.synapseWorkspaceContainer}}}t.AzureResourceSynapseWorkspaceTreeDataProvider=u,u.containerId="azure.resource.providers.synapseWorkspace.treeDataProvider.synapseWorkspaceContainer",u.containerLabel=i(0,null)},2562:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceUniversalResourceProvider=void 0,t.AzureResourceUniversalResourceProvider=class{constructor(e,t){this._providerId=e,this._treeProvider=t}getTreeDataProvider(){return this._treeProvider}get providerId(){return this._providerId}}},2748:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceUniversalService=void 0;const r=n(3311),o=n(3614),i=n(4344),s=n(4200),a=n(7768),c=n(3508),u=n(7147),l=s.loadMessageBundle(n(6928).join(__dirname,"azureResource/providers/universal/universalService.ts"));t.AzureResourceUniversalService=class{constructor(e){this.registeredTreeDataProviders=e,this.queryFilter=this.generateUniversalQueryFilter()}generateUniversalQueryFilter(){let e=i.where;return this.registeredTreeDataProviders.forEach(((t,n)=>{e+=" ("+t.getService().queryFilter+") or"})),e.substring(0,e.length-3)}getRegisteredTreeDataProviderInstance(e){if(this.registeredTreeDataProviders.has(e))return this.registeredTreeDataProviders.get(e);throw new Error(l(0,null,e))}async getResources(e,t,n){const i=[],s=new r.ResourceGraphClient(t,{baseUri:n.properties.providerSettings.settings.armResource.endpoint});let c=await(0,o.queryGraphResources)(s,e,this.queryFilter);const u=new Set;return c.forEach((t=>{if(!u.has(t.id)){let n;u.add(t.id),t.subscriptionName=e.find((e=>e.id===t.subscriptionId))?.name;let r=this.getProviderFromResourceType(t.type,t.kind);if(r[1]===a.ResourceCategory.Server)n=r[0].getService().convertServerResource(t);else if(!t.kind?.endsWith("system")){let e=r[0].getService(),o=this.getServerResource(t,c);n=e.convertDatabaseResource(t,o)}n&&i.push(n)}})),i}getProviderFromResourceType(e,t){if("microsoft.documentdb/databaseaccounts"===e&&t===a.mongoDbKind||"microsoft.documentdb/mongoclusters"===e)return[this.getRegisteredTreeDataProviderInstance(c.COSMOSDB_MONGO_PROVIDER_ID),a.ResourceCategory.Server];if("microsoft.documentdb/databaseaccounts"===e&&t===a.cosmosDbNoSqlKind)return[this.getRegisteredTreeDataProviderInstance(c.COSMOSDB_NOSQL_PROVIDER_ID),a.ResourceCategory.Server];if("microsoft.dbforpostgresql/servergroups"===e||"microsoft.dbforpostgresql/servergroupsv2"===e)return[this.getRegisteredTreeDataProviderInstance(c.COSMOSDB_POSTGRES_PROVIDER_ID),a.ResourceCategory.Server];if("microsoft.sql/servers/databases"===e||"microsoft.synapse/workspaces/sqldatabases"===e)return[this.getRegisteredTreeDataProviderInstance(c.DATABASE_PROVIDER_ID),a.ResourceCategory.Database];if("microsoft.sql/servers"===e&&t!==a.analyticsKind)return[this.getRegisteredTreeDataProviderInstance(c.DATABASE_SERVER_PROVIDER_ID),a.ResourceCategory.Server];if("microsoft.kusto/clusters"===e)return[this.getRegisteredTreeDataProviderInstance(c.KUSTO_PROVIDER_ID),a.ResourceCategory.Server];if("microsoft.operationalinsights/workspaces"===e)return[this.getRegisteredTreeDataProviderInstance(c.AZURE_MONITOR_PROVIDER_ID),a.ResourceCategory.Server];if("microsoft.dbformysql/flexibleservers"===e)return[this.getRegisteredTreeDataProviderInstance(c.MYSQL_FLEXIBLE_SERVER_PROVIDER_ID),a.ResourceCategory.Server];if("microsoft.dbforpostgresql/servers"===e||"microsoft.dbforpostgresql/serversv2"===e||"microsoft.dbforpostgresql/singleservers"===e)return[this.getRegisteredTreeDataProviderInstance(c.POSTGRES_SERVER_PROVIDER_ID),a.ResourceCategory.Server];if("microsoft.dbforpostgresql/flexibleservers"===e)return[this.getRegisteredTreeDataProviderInstance(c.POSTGRES_FLEXIBLE_SERVER_PROVIDER_ID),a.ResourceCategory.Server];if("microsoft.azuredata/postgresinstances"===e)return[this.getRegisteredTreeDataProviderInstance(c.POSTGRES_ARC_SERVER_PROVIDER_ID),a.ResourceCategory.Server];if("microsoft.sql/managedinstances"===e)return[this.getRegisteredTreeDataProviderInstance(c.SQLINSTANCE_PROVIDER_ID),a.ResourceCategory.Server];if("microsoft.azuredata/sqlmanagedinstances"===e)return[this.getRegisteredTreeDataProviderInstance(c.SQLINSTANCE_ARC_PROVIDER_ID),a.ResourceCategory.Server];if("microsoft.synapse/workspaces/sqlpools"===e)return[this.getRegisteredTreeDataProviderInstance(c.SYNAPSE_SQL_POOL_PROVIDER_ID),a.ResourceCategory.Database];if("microsoft.synapse/workspaces"===e)return[this.getRegisteredTreeDataProviderInstance(c.SYNAPSE_WORKSPACE_PROVIDER_ID),a.ResourceCategory.Server];throw u.Logger.error(`Type provider not registered: ${e}`),new Error(l(1,null,e))}getProviderFromResourceId(e){if(e.startsWith(a.AzureResourcePrefixes.cosmosdb))return this.getRegisteredTreeDataProviderInstance(c.COSMOSDB_MONGO_PROVIDER_ID);if(e.startsWith(a.AzureResourcePrefixes.database))return this.getRegisteredTreeDataProviderInstance(c.DATABASE_PROVIDER_ID);if(e.startsWith(a.AzureResourcePrefixes.databaseServer))return this.getRegisteredTreeDataProviderInstance(c.DATABASE_SERVER_PROVIDER_ID);if(e.startsWith(a.AzureResourcePrefixes.kusto))return this.getRegisteredTreeDataProviderInstance(c.KUSTO_PROVIDER_ID);if(e.startsWith(a.AzureResourcePrefixes.logAnalytics))return this.getRegisteredTreeDataProviderInstance(c.AZURE_MONITOR_PROVIDER_ID);if(e.startsWith(a.AzureResourcePrefixes.mySqlFlexibleServer))return this.getRegisteredTreeDataProviderInstance(c.MYSQL_FLEXIBLE_SERVER_PROVIDER_ID);if(e.startsWith(a.AzureResourcePrefixes.postgresServer))return this.getRegisteredTreeDataProviderInstance(c.POSTGRES_SERVER_PROVIDER_ID);if(e.startsWith(a.AzureResourcePrefixes.postgresFlexibleServer))return this.getRegisteredTreeDataProviderInstance(c.POSTGRES_FLEXIBLE_SERVER_PROVIDER_ID);if(e.startsWith(a.AzureResourcePrefixes.postgresServerArc))return this.getRegisteredTreeDataProviderInstance(c.POSTGRES_ARC_SERVER_PROVIDER_ID);if(e.startsWith(a.AzureResourcePrefixes.sqlInstance))return this.getRegisteredTreeDataProviderInstance(c.SQLINSTANCE_PROVIDER_ID);if(e.startsWith(a.AzureResourcePrefixes.sqlInstanceArc))return this.getRegisteredTreeDataProviderInstance(c.SQLINSTANCE_ARC_PROVIDER_ID);if(e.startsWith(a.AzureResourcePrefixes.synapseSqlPool))return this.getRegisteredTreeDataProviderInstance(c.SYNAPSE_SQL_POOL_PROVIDER_ID);if(e.startsWith(a.AzureResourcePrefixes.synapseWorkspace))return this.getRegisteredTreeDataProviderInstance(c.SYNAPSE_WORKSPACE_PROVIDER_ID);throw u.Logger.error(`Unrecognized provider prefix for id: ${e}`),new Error(l(2,null,e))}getServerResource(e,t){const n=e.id.split("/"),r=n.length-3,o=n[2];return t.find((e=>e.name===n[r]&&e.subscriptionId===o))??void 0}}},4502:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceUniversalTreeDataProvider=void 0;const r=n(235),o=n(3253),i=n(6752),s=n(3614),a=n(7147);class c extends s.ResourceTreeDataProviderBase{constructor(e){super(e),this.universalService=e}getService(){return this.universalService}getChildren(e){throw new Error("Method not supported for universal provider.")}getTreeItemForResource(e,t){let n=this.universalService.getRegisteredTreeDataProviderInstance(e.provider);return n.browseConnectionMode=this.browseConnectionMode,n.getTreeItemForResource(e,t)}async getRootChild(){throw new Error("Method not supported")}async getAllChildren(e,t){try{return(await this.getAllResources(e,t)).map((t=>({account:e,subscription:t.subscription,tenantId:t.tenant,resourceProviderId:t.provider,treeItem:this.getTreeItemForResource(t,e)}))).sort(((e,t)=>e.treeItem.label.localeCompare(t.treeItem.label)))}catch(e){throw a.Logger.error(i.AzureResourceErrorMessageUtil.getErrorMessage(e)),e}}async getAllResources(e,t){let n=[];for(const i of e.properties.tenants){const s=t.filter((e=>e.tenant===i.id));if(s&&s.length>0){const t=await r.accounts.getAccountSecurityToken(e,i.id,r.AzureResource.ResourceManagement);if(!t)throw new Error(`Did not receive security token when getting resources for account ${e.displayInfo.displayName}`);const a=new o.TokenCredentials(t.token,t.tokenType);n=n.concat(await this.universalService.getResources(s,a,e))}}return n}}t.AzureResourceUniversalTreeDataProvider=c},9354:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceService=void 0;const r=n(1398),o=n(3508);t.AzureResourceService=class{constructor(){this._areResourceProvidersLoaded=!1,this._resourceProviders={},this._treeDataProviders={},this._universalProvider=void 0}async listResourceProviderIds(){return await this.ensureResourceProvidersRegistered(),Object.keys(this._resourceProviders)}async getResourceProviders(){return await this.ensureResourceProvidersRegistered(),this._resourceProviders}registerResourceProvider(e){this.doRegisterResourceProvider(e)}registerUniversalResourceProvider(e){this._universalProvider=e}clearResourceProviders(){this._resourceProviders={},this._treeDataProviders={},this._areResourceProvidersLoaded=!1}async getRootChild(e,t,n){if(await this.ensureResourceProvidersRegistered(),!(e in this._resourceProviders)&&e!==o.UNIVERSAL_PROVIDER_ID)throw new Error(`Azure resource provider doesn't exist. Id: ${e}`);const r=await(this._treeDataProviders[e]?.getRootChild());return{account:t,subscription:n,tenantId:n.tenant,resourceProviderId:e,treeItem:r}}async getChildren(e,t,n=!1){if(await this.ensureResourceProvidersRegistered(),!(e in this._resourceProviders)&&e!==o.UNIVERSAL_PROVIDER_ID)throw new Error(`Azure resource provider doesn't exist. Id: ${e}`);const r=this._treeDataProviders[e];return r.browseConnectionMode=n,await r.getChildren(t)}async getAllChildren(e,t,n=!1){await this.ensureResourceProvidersRegistered();const r=this._universalProvider?.getTreeDataProvider();return r.browseConnectionMode=n,await r.getAllChildren(e,t)}get areResourceProvidersLoaded(){return this._areResourceProvidersLoaded}set areResourceProvidersLoaded(e){this._areResourceProvidersLoaded=e}async ensureResourceProvidersRegistered(){if(!this._areResourceProvidersLoaded){for(const e of r.extensions.all){const t=e.packageJSON.contributes;if(t&&t.hasAzureResourceProviders){if(await e.activate(),e.exports&&e.exports.provideResources)for(const t of e.exports.provideResources())t&&t.providerId!==o.UNIVERSAL_PROVIDER_ID&&this.doRegisterResourceProvider(t);e.exports&&e.exports.getUniversalProvider&&(this._universalProvider=e.exports.getUniversalProvider())}}this._areResourceProvidersLoaded=!0}}doRegisterResourceProvider(e){this._resourceProviders[e.providerId]=e,this._treeDataProviders[e.providerId]=e.getTreeDataProvider()}}},3749:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceResourceTreeNode=void 0;const r=n(1398),o=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/resourceTreeNode.ts")),i=n(4729),s=n(7182),a=n(6752),c=n(7768);class u extends i.TreeNode{constructor(e,t,n){super(),this.resourceNode=e,this.appContext=n,this._resourceService=n.getService(c.AzureResourceServiceNames.resourceService),this.parent=t}async getChildren(){if(this.resourceNode.treeItem.collapsibleState===r.TreeItemCollapsibleState.None)return[];try{const e=await this._resourceService.getChildren(this.resourceNode.resourceProviderId,this.resourceNode);return 0===e.length?[s.AzureResourceMessageTreeNode.create(o(0,null),this)]:e.map((e=>(e.treeItem.id=`${this.resourceNode.treeItem.id}.${e.treeItem.id}`,new u(e,this,this.appContext))))}catch(e){return[s.AzureResourceMessageTreeNode.create(a.AzureResourceErrorMessageUtil.getErrorMessage(e),this)]}}getTreeItem(){return this.resourceNode.treeItem}getNodeInfo(){const e=this.resourceNode.treeItem;return{label:"object"==typeof e.label?e.label.label:e.label||"",isLeaf:e.collapsibleState===r.TreeItemCollapsibleState.None,errorMessage:void 0,metadata:void 0,nodePath:this.generateNodePath(),parentNodePath:this.parent?.generateNodePath()??"",nodeStatus:void 0,nodeType:e.contextValue||"",nodeSubType:void 0,iconType:e.contextValue}}get nodePathValue(){return this.resourceNode.treeItem.id||""}}t.AzureResourceResourceTreeNode=u},6129:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceCacheService=void 0;class n{constructor(e){this._context=e}generateKey(e){return`${n.cacheKeyPrefix}.${e}`}get(e){return this._context.workspaceState.get(e)}async update(e,t){await this._context.workspaceState.update(e,t)}}t.AzureResourceCacheService=n,n.cacheKeyPrefix="azure.resource.cache"},8768:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceSubscriptionFilterService=void 0,t.AzureResourceSubscriptionFilterService=class{constructor(e){this._cacheService=e,this._cacheKey=this._cacheService.generateKey("selectedSubscriptions")}async getSelectedSubscriptions(e,t){let n=[];const r=this._cacheService.get(this._cacheKey);if(r&&(n=r.selectedSubscriptions[e.key.accountId+"/"+t.id],!n)){let n=r.selectedSubscriptions[e.key.accountId]?.filter((e=>e.tenant===t.id));n&&await this.saveSelectedSubscriptions(e,t,n)}return n}async saveSelectedSubscriptions(e,t,n){let r={};const o=this._cacheService.get(this._cacheKey);o&&(r=o.selectedSubscriptions),r||(r={});let i=e.key.accountId;t&&(i+="/"+t.id),r[i]=n,await this._cacheService.update(this._cacheKey,{selectedSubscriptions:r}),[].push(...r[i].map((e=>`${i}/${e.id}`)))}}},1018:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceSubscriptionService=void 0;const r=n(235),o=n(1398),i=n(5549),s=n(3042),a=n(6752),c=n(7147),u=n(4200),l=n(2259),p=n(3508),d=n(3253),h=u.loadMessageBundle(n(6928).join(__dirname,"azureResource/services/subscriptionService.ts"));t.AzureResourceSubscriptionService=class{async getSubscriptions(e,t){const n=[];let u=!1;const f=[];for(const s of t??e.properties.tenants.map((e=>e.id)))try{const t=await r.accounts.getAccountSecurityToken(e,s,r.AzureResource.ResourceManagement);if(void 0!==t){const r=new i.SubscriptionClient(new d.TokenCredentials(t.token,t.tokenType),{baseUri:e.properties.providerSettings.settings.armResource.endpoint}),o=await r.subscriptions.list();n.push(...o.map((e=>({id:e.subscriptionId||"",name:e.displayName||"",tenant:s})))),c.Logger.verbose(`AzureResourceSubscriptionService.getSubscriptions: Retrieved ${o.length} subscriptions for tenant ${s} / account ${e.displayInfo.displayName}`),u=!0}else if(!e.isStale){const t=h(0,null,e.displayInfo.displayName,s);c.Logger.error(`Failed to acquire Access Token for account '${e.displayInfo.displayName}' (tenant '${s}').`),o.window.showWarningMessage(t)}}catch(t){if(!(e.isStale||t instanceof l.TenantIgnoredError)){const n=a.AzureResourceErrorMessageUtil.getErrorMessage(t);let r=h(1,null,e.displayInfo.displayName,s,n);n.includes(p.multiple_matching_tokens_error)&&(r=r.concat(" To resolve this error, please clear token cache, and refresh account credentials.")),c.Logger.error(`Failed to get subscriptions for account ${e.displayInfo.displayName} (tenant '${s}'). ${n}`),f.push(t),o.window.showWarningMessage(r)}}if(!u)throw new s.AzureSubscriptionError(e.key.accountId,f);return n}}},4663:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceTenantFilterService=void 0,t.AzureResourceTenantFilterService=class{constructor(e){this._cacheService=e,this._cacheKey=this._cacheService.generateKey("selectedTenants")}async getSelectedTenants(e){let t=[];const n=this._cacheService.get(this._cacheKey);return n&&(t=n.selectedTenants[e.key.accountId]),t}async saveSelectedTenants(e,t){let n={};const r=this._cacheService.get(this._cacheKey);r&&(n=r.selectedTenants),n||(n={}),n[e.key.accountId]=t,await this._cacheService.update(this._cacheKey,{selectedTenants:n});const o=[];for(const e in n)o.push(...n[e].map((t=>`${e}/${t.id}/${t.displayName}`)))}}},1413:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureTerminalService=void 0;const r=n(235),o=n(1398),i=n(4200),s=n(9329),a=n(7699),c=n(7147),u=i.loadMessageBundle(n(6928).join(__dirname,"azureResource/services/terminalService.ts")),l=async()=>{const e=u(0,null);let t;!function(e){e[e.OPEN_SITE=0]="OPEN_SITE",e[e.OK=1]="OK"}(t||(t={}));const n={action:t.OPEN_SITE,title:u(1,null)},r={action:t.OK,title:u(2,null)},i=await o.window.showInformationMessage(e,n,r);i?.action===t.OPEN_SITE&&o.env.openExternal(o.Uri.parse("https://aka.ms/AA83f8f"))};t.AzureTerminalService=class{constructor(e){this.apiVersion="?api-version=2018-10-01"}async getOrCreateCloudConsole(e,t){const n=await r.accounts.getAccountSecurityToken(e,t.id,r.AzureResource.MicrosoftResourceManagement);if(!n)throw new Error("Did not receive security token when creating cloud console");const o={headers:{Accept:"application/json","Content-Type":"application/json",Authorization:`Bearer ${n.token}`},validateStatus:()=>!0},i=e.properties.providerSettings,a=this.getConsoleUserSettingsUri(i.settings.armResource.endpoint);let u;try{u=await s.default.get(a,o)}catch(e){return c.Logger.info(e,e.response),void await l()}const p=u.data?.properties?.preferredShellType??"bash",d=u.data?.properties?.preferredLocation,h=this.getConsoleRequestUri(i.settings.armResource.endpoint);let f;d&&(o.headers["x-ms-console-preferred-location"]=d);try{f=await s.default.put(h,{},o)}catch(e){return c.Logger.info(e,e.response),void await l()}if("Succeeded"!==f.data?.properties?.provisioningState)throw new Error(JSON.stringify(f.data));const m=f.data.properties.uri;return this.createTerminal(m,n.token,e.displayInfo.displayName,p)}async createTerminal(e,t,n,r){class i{constructor(e,t){this.label=e,this.value=t}}const s=[new i("PowerShell","pwsh"),new i("Bash","bash")],a=s.findIndex((e=>e.value===r)),c=s.splice(a,1);s.unshift(c[0]);let l=await o.window.showQuickPick(s,{canPickMany:!1,placeHolder:u(3,null)});if(!l)return void o.window.showErrorMessage(u(4,null));const d=u(5,null,l.label,n),h=new p(e,t,l.value);o.window.createTerminal({name:d,pty:h}).show()}getConsoleRequestUri(e){return`${e}/providers/Microsoft.Portal/consoles/default${this.apiVersion}`}getConsoleUserSettingsUri(e){return`${e}/providers/Microsoft.Portal/userSettings/cloudconsole${this.apiVersion}`}};class p{constructor(e,t,n){this.consoleUri=e,this.token=t,this.shell=n,this.socket=void 0,this.intervalTimer=void 0,this.writeEmitter=new o.EventEmitter,this.onDidWrite=this.writeEmitter.event}handleInput(e){this.socket?.send(e)}async open(e){await this.setDimensions(e)}close(){this.socket&&(this.socket.removeAllListeners("open"),this.socket.removeAllListeners("message"),this.socket.removeAllListeners("close"),this.socket.close(),this.intervalTimer&&clearInterval(this.intervalTimer))}areSameDimensions(e,t){return e?.columns===t.columns&&e?.rows===t.rows}async setDimensions(e){if(e&&!this.areSameDimensions(this.terminalDimensions,e))return this.terminalDimensions=e,this.resetTerminalSize()}async resetTerminalSize(){try{this.close();const e=await this.establishTerminal(this.terminalDimensions);if(!e)return;this.socket=new a(e),this.socket.on("message",(e=>{this.writeEmitter.fire(e.toString())})),this.socket.on("close",(()=>{this.writeEmitter.fire(u(6,null)),this.close()})),this.intervalTimer=setInterval((()=>{this.socket?.ping()}),5e3)}catch(e){c.Logger.error(e)}}async establishTerminal(e){let t;try{const n=e?`${this.consoleUri}/terminals?rows=${e.rows}&cols=${e.columns}&shell=${this.shell}`:`${this.consoleUri}/terminals?shell=${this.shell}`;t=await s.default.post(n,void 0,{headers:{Accept:"application/json","Content-Type":"application/json",Authorization:`Bearer ${this.token}`}})}catch(e){return c.Logger.info(`Error establishing terminal. ${e}, ${e.response}`),void await l()}const n=t.data?.socketUri;if(t.data.error&&o.window.showErrorMessage(t.data.error.message),!n)throw Error(JSON.stringify(t.data));return n}}},9995:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceAccountNotSignedInTreeNode=void 0;const r=n(1398),o=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/tree/accountNotSignedInTreeNode.ts")),i=n(4729),s=n(7768);class a extends i.TreeNode{getChildren(){return[]}getTreeItem(){let e=new r.TreeItem(a.signInLabel,r.TreeItemCollapsibleState.None);return e.contextValue=s.AzureResourceItemType.message,e.command={title:a.signInLabel,command:"azure.resource.signin",arguments:[this]},e}getNodeInfo(){return{label:a.signInLabel,isLeaf:!0,errorMessage:void 0,metadata:void 0,nodePath:this.generateNodePath(),parentNodePath:this.parent?.generateNodePath()??"",nodeStatus:void 0,nodeType:s.AzureResourceItemType.message,nodeSubType:void 0,iconType:s.AzureResourceItemType.message}}get nodePathValue(){return"message_accountNotSignedIn"}}t.AzureResourceAccountNotSignedInTreeNode=a,a.signInLabel=o(0,null)},6653:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceAccountTreeNode=void 0;const r=n(1398),o=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/tree/accountTreeNode.ts")),i=n(5760),s=n(7768),a=n(4040),c=n(7182);class u extends i.AzureResourceContainerTreeNodeBase{constructor(e,t,n){super(t,n,void 0),this.account=e,this._totalTenantsCount=0,this._selectedTenantsCount=0,this._tenantFilterService=this.appContext.getService(s.AzureResourceServiceNames.tenantFilterService),1===this.account.properties.tenants.length&&(this._singleTenantTreeNode=new a.AzureResourceTenantTreeNode(this.account,this.account.properties.tenants[0],this,this.appContext,this.treeChangeHandler)),this._id=`account_${this.account.key.accountId}`,this.setCacheKey(`${this._id}.tenants`),this._label=this.generateLabel()}async getChildren(){let e=this.account.properties.tenants;this._totalTenantsCount=e.length;const t=(await this._tenantFilterService.getSelectedTenants(this.account)||[]).map((e=>e.id));return t.length>0?(e=e.filter((e=>-1!==t.indexOf(e.id))),this._selectedTenantsCount=t.length):this._selectedTenantsCount=this._totalTenantsCount,this.refreshLabel(),1===this.totalTenantsCount?await(this._singleTenantTreeNode?.getChildren())??[]:0===e.length?[c.AzureResourceMessageTreeNode.create(u.noTenantsLabel,this)]:(await Promise.all(e.map((async e=>new a.AzureResourceTenantTreeNode(this.account,e,this,this.appContext,this.treeChangeHandler))))).sort(((e,t)=>e.tenant.displayName.localeCompare(t.tenant.displayName)))}getTreeItem(){const e=new r.TreeItem(this._label,r.TreeItemCollapsibleState.Collapsed);return e.id=this._id,e.contextValue=this.account.properties.tenants.length>1?s.AzureResourceItemType.multipleTenantAccount:s.AzureResourceItemType.singleTenantAccount,e.iconPath=this.appContext.extensionContext.asAbsolutePath("resources/users.svg"),e}getNodeInfo(){return{label:this._label,isLeaf:!1,errorMessage:void 0,metadata:void 0,nodePath:this.generateNodePath(),parentNodePath:this.parent?.generateNodePath()??"",nodeStatus:void 0,nodeType:s.AzureResourceItemType.account,nodeSubType:void 0,iconType:s.AzureResourceItemType.account}}get nodePathValue(){return this._id}get totalTenantsCount(){return this._totalTenantsCount}get selectedTenantCount(){return this._selectedTenantsCount}refreshLabel(){const e=this.generateLabel();this._label!==e&&(this._label=e,this.treeChangeHandler.notifyNodeChanged(this))}generateLabel(){let e=this.account.displayInfo.displayName;return 1===this._totalTenantsCount&&this._singleTenantTreeNode?e+=` (${this._singleTenantTreeNode.selectedSubscriptionCount} / ${this._singleTenantTreeNode.totalSubscriptionCount} subscriptions)`:this._totalTenantsCount>0&&(e+=` (${this._selectedTenantsCount} / ${this._totalTenantsCount} tenants)`),e}}t.AzureResourceAccountTreeNode=u,u.noTenantsLabel=o(0,null)},5760:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceContainerTreeNodeBase=void 0;const r=n(4729),o=n(7768);class i extends r.TreeNode{constructor(e,t,n){super(),this.appContext=e,this.treeChangeHandler=t,this.parent=n}}t.AzureResourceContainerTreeNodeBase=class extends i{constructor(e,t,n){super(e,t,n),this._isClearingCache=!0,this._cacheKey=void 0,this._cacheService=this.appContext.getService(o.AzureResourceServiceNames.cacheService)}clearCache(){this._isClearingCache=!0}get isClearingCache(){return this._isClearingCache}setCacheKey(e){this._cacheKey=this._cacheService.generateKey(e)}updateCache(e){return this._cacheService.update(this._cacheKey,e)}getCache(){return this.ensureCacheKey(),this._cacheService.get(this._cacheKey)}ensureCacheKey(){if(!this._cacheKey)throw new Error("A cache key must be generated first")}}},1289:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ConnectionDialogTreeProvider=void 0;const r=n(1398),o=n(235),i=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/tree/connectionDialogTreeProvider.ts")),s=n(9995),a=n(7182),c=n(5760),u=n(6752),l=n(7147),p=n(7264);t.ConnectionDialogTreeProvider=class{constructor(e){this.appContext=e,this.isSystemInitialized=!1,this.accounts=[],this._onDidChangeTreeData=new r.EventEmitter,o.accounts.onDidChangeAccounts((async e=>{let t=await o.accounts.getAllAccounts();t=t.filter((e=>e.key.providerId.startsWith("azure"))),this.setSystemInitialized(),(0,u.equals)(t,this.accounts)||(this.accounts=t,this.notifyNodeChanged(void 0))}))}async getChildren(e){if(e)return e.getChildren();if(!this.isSystemInitialized)return this.loadingAccountsPromise||(this.loadingAccountsPromise=this.loadAccounts()),[a.AzureResourceMessageTreeNode.create(i(0,null),void 0)];if(this.accounts&&this.accounts.length>0){const e=[],t=[];for(const n of this.accounts)try{const t=new p.FlatAccountTreeNode(n,this.appContext,this);t.refreshLabel(),e.push(t)}catch(e){t.push(u.AzureResourceErrorMessageUtil.getErrorMessage(e))}if(t.length>0){const e=i(1,null);r.window.showErrorMessage(i(2,null,t.join(",")),e).then((t=>{t===e&&r.commands.executeCommand("azure.resource.signin")}))}return e}return[new s.AzureResourceAccountNotSignedInTreeNode]}async loadAccounts(){try{this.accounts=await o.accounts.getAllAccounts(),this.setSystemInitialized(),this.notifyNodeChanged(void 0)}catch(e){l.Logger.error("loadAccounts failed with the following error: {0}",e.message??e),this.isSystemInitialized=!1}}setSystemInitialized(){this.isSystemInitialized=!0,this.loadingAccountsPromise=void 0}get onDidChangeTreeData(){return this._onDidChangeTreeData.event}notifyNodeChanged(e){this._onDidChangeTreeData.fire(e)}async refresh(e,t){t&&e instanceof c.AzureResourceContainerTreeNodeBase&&e.clearCache(),this.notifyNodeChanged(e)}getTreeItem(e){return e.getTreeItem()}}},7264:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FlatAccountTreeNode=void 0;const r=n(1398),o=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/tree/flatAccountTreeNode.ts")),i=n(5760),s=n(7768),a=n(7182),c=n(8991);class u extends i.AzureResourceContainerTreeNodeBase{constructor(e,t,n){super(t,n,void 0),this.account=e,this._totalTenantsCount=0,this._selectedTenantsCount=0,this._tenantFilterService=this.appContext.getService(s.AzureResourceServiceNames.tenantFilterService),this._id=`account_${this.account.key.accountId}`,this.setCacheKey(`${this._id}.tenants`),1===this.account.properties.tenants.length&&(this._singleTenantTreeNode=new c.FlatTenantTreeNode(this.account,this.account.properties.tenants[0],this,this.appContext,this.treeChangeHandler)),this._label=this.generateLabel()}async getChildren(){let e=[],t=this.account.properties.tenants;this._totalTenantsCount=t.length;const n=(await this._tenantFilterService.getSelectedTenants(this.account)||[]).map((e=>e.id));return n.length>0?(t=t.filter((e=>-1!==n.indexOf(e.id))),this._selectedTenantsCount=n.length):this._selectedTenantsCount=this._totalTenantsCount,this.refreshLabel(),1===this._totalTenantsCount?this._isClearingCache?await(this._singleTenantTreeNode?.getChildren()):e=await(this._singleTenantTreeNode?.getChildren())??[]:0===t.length?e=[a.AzureResourceMessageTreeNode.create(u.noTenantsLabel,this)]:(this._multiTenantTreeNodes||(this._multiTenantTreeNodes=await Promise.all(t.map((async e=>new c.FlatTenantTreeNode(this.account,e,void 0,this.appContext,this.treeChangeHandler))))),e=this._multiTenantTreeNodes.sort(((e,t)=>e.tenant.displayName.localeCompare(t.tenant.displayName)))),this._isClearingCache?(this._multiTenantTreeNodes?.forEach((e=>{e.clearCache()})),this._isClearingCache=!1,[]):e}getTreeItem(){const e=new r.TreeItem(this._label,r.TreeItemCollapsibleState.Collapsed);return e.id=this._id,e.contextValue=this.account.properties.tenants.length>1?s.AzureResourceItemType.multipleTenantAccount:s.AzureResourceItemType.singleTenantAccount,e.iconPath=this.appContext.extensionContext.asAbsolutePath("resources/users.svg"),e}getNodeInfo(){return{label:this._label,isLeaf:!1,errorMessage:void 0,metadata:void 0,nodePath:this.generateNodePath(),parentNodePath:this.parent?.generateNodePath()??"",nodeStatus:void 0,nodeType:s.AzureResourceItemType.account,nodeSubType:void 0,iconType:s.AzureResourceItemType.account}}get nodePathValue(){return this._id}refreshLabel(){const e=this.generateLabel();this._label!==e&&(this._label=e,this.treeChangeHandler.notifyNodeChanged(this))}generateLabel(){let e=this.account.displayInfo.displayName;return 1===this._totalTenantsCount&&this._singleTenantTreeNode?e+=` (${this._singleTenantTreeNode._selectedSubscriptionCount} / ${this._singleTenantTreeNode._totalSubscriptionCount} subscriptions)`:this._totalTenantsCount>0&&(e+=` (${this._selectedTenantsCount} / ${this._totalTenantsCount} tenants)`),e}}t.FlatAccountTreeNode=u,u.noTenantsLabel=o(0,null)},8991:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getSubscriptionInfo=t.FlatTenantTreeNode=void 0;const r=n(1398),o=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/tree/flatTenantTreeNode.ts")),i=n(3042),s=n(5760),a=n(7768),c=n(3749),u=n(6752),l=n(7182);class p extends s.AzureResourceContainerTreeNodeBase{constructor(e,t,n,r,o){super(r,o,n),this.account=e,this.tenant=t,this.parentNode=n,this._totalSubscriptionCount=0,this._selectedSubscriptionCount=0,this._subscriptionService=this.appContext.getService(a.AzureResourceServiceNames.subscriptionService),this._subscriptionFilterService=this.appContext.getService(a.AzureResourceServiceNames.subscriptionFilterService),this._resourceService=this.appContext.getService(a.AzureResourceServiceNames.resourceService),this._id=`account_${this.account.key.accountId}.tenant_${t.id}`,this.setCacheKey(`${this._id}.dataresources`),this._label=this.generateLabel()}async getChildren(){try{let e=[],t=[];this._isClearingCache?(t=await this._subscriptionService.getSubscriptions(this.account,[this.tenant.id]),await this.updateCache(t)):t=await this.getCachedSubscriptions(),this._totalSubscriptionCount=t.length;const n=await this._subscriptionFilterService.getSelectedSubscriptions(this.account,this.tenant),r=n?.filter((e=>e.tenant===this.tenant.id)),o=(r||[]).map((e=>e.id));if(o.length>0?(t=t.filter((e=>-1!==o.indexOf(e.id))),this._selectedSubscriptionCount=o.length):this._selectedSubscriptionCount=this._totalSubscriptionCount,this.refreshLabel(),this._isClearingCache)return this._isClearingCache=!1,[];if(0===t.length)e=[l.AzureResourceMessageTreeNode.create(p.noSubscriptionsLabel,this)];else{let n=[];const r=await this._resourceService.getAllChildren(this.account,t,!0);r?.length>0&&(n.push(...r.map((e=>new c.AzureResourceResourceTreeNode(e,this.parentNode??this,this.appContext)))),n=n.sort(((e,t)=>e.getNodeInfo().label.localeCompare(t.getNodeInfo().label)))),e=n}return e}catch(e){return e instanceof i.AzureSubscriptionError&&r.commands.executeCommand("azure.resource.signin"),[l.AzureResourceMessageTreeNode.create(u.AzureResourceErrorMessageUtil.getErrorMessage(e),this)]}}async getCachedSubscriptions(){return this.getCache()??[]}getTreeItem(){const e=new r.TreeItem(this._label,r.TreeItemCollapsibleState.Collapsed);return e.id=this._id,e.contextValue=a.AzureResourceItemType.tenant,e.iconPath=this.appContext.extensionContext.asAbsolutePath("resources/tenant.svg"),e}refreshLabel(){const e=this.generateLabel();this._label!==e&&(this._label=e,this.treeChangeHandler.notifyNodeChanged(this))}generateLabel(){let e=this.tenant.displayName;return 0!==this._totalSubscriptionCount&&(e+=` (${this._selectedSubscriptionCount} / ${this._totalSubscriptionCount} subscriptions)`),e}getNodeInfo(){return{label:this._label,isLeaf:!1,errorMessage:void 0,metadata:void 0,nodePath:this.generateNodePath(),parentNodePath:this.parent?.generateNodePath()??"",nodeStatus:void 0,nodeType:a.AzureResourceItemType.tenant,nodeSubType:void 0,iconType:a.AzureResourceItemType.tenant}}get nodePathValue(){return this._id}}t.FlatTenantTreeNode=p,p.noSubscriptionsLabel=o(0,null),t.getSubscriptionInfo=async function(e,t,n,r){let o=await n.getSubscriptions(e,[t.id]);const i=o.length;let s=i;const a=(await r.getSelectedSubscriptions(e,t)||[]).map((e=>e.id));return a.length>0&&(o=o.filter((e=>-1!==a.indexOf(e.id))),s=a.length),{subscriptions:o,total:i,selected:s}}},7741:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceSubscriptionTreeNode=void 0;const r=n(1398),o=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/tree/subscriptionTreeNode.ts")),i=n(5760),s=n(7768),a=n(7182),c=n(6752),u=n(3749);class l extends i.AzureResourceContainerTreeNodeBase{constructor(e,t,n,r,o,i){super(r,o,i),this.account=e,this.subscription=t,this.tenant=n,this._id=`account_${this.account.key.accountId}.tenant_${this.tenant.id}.subscription_${this.subscription.id}`,this.setCacheKey(`${this._id}.resources`)}async getChildren(){try{const e=this.appContext.getService(s.AzureResourceServiceNames.resourceService),t=await e.getAllChildren(this.account,[this.subscription],!0);let n=[];if(0===t.length)return[a.AzureResourceMessageTreeNode.create(l.noResourcesLabel,this)];for(let r of t)-1===n.findIndex((e=>e.resourceProviderId===r.resourceProviderId))&&n.push(await e.getRootChild(r.resourceProviderId,this.account,this.subscription));return n.map((e=>(e.treeItem.id=`${this._id}.${e.treeItem.id}`,new u.AzureResourceResourceTreeNode(e,this,this.appContext)))).sort(((e,t)=>e.nodePathValue.localeCompare(t.nodePathValue)))}catch(e){return[a.AzureResourceMessageTreeNode.create(c.AzureResourceErrorMessageUtil.getErrorMessage(e),this)]}}getTreeItem(){const e=new r.TreeItem(this.subscription.name,r.TreeItemCollapsibleState.Collapsed);return e.contextValue=s.AzureResourceItemType.subscription,e.iconPath=this.appContext.extensionContext.asAbsolutePath("resources/subscriptions.svg"),e}getNodeInfo(){return{label:this.subscription.name,isLeaf:!1,errorMessage:void 0,metadata:void 0,nodePath:this.generateNodePath(),parentNodePath:this.parent?.generateNodePath()??"",nodeStatus:void 0,nodeType:s.AzureResourceItemType.subscription,nodeSubType:void 0,iconType:s.AzureResourceItemType.subscription}}get nodePathValue(){return this._id}}t.AzureResourceSubscriptionTreeNode=l,l.noResourcesLabel=o(0,null)},4040:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceTenantTreeNode=void 0;const r=n(1398),o=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/tree/tenantTreeNode.ts")),i=n(3042),s=n(5760),a=n(7768),c=n(7741),u=n(7182),l=n(6752);class p extends s.AzureResourceContainerTreeNodeBase{constructor(e,t,n,r,o){super(r,o,n),this.account=e,this.tenant=t,this._totalSubscriptionCount=0,this._selectedSubscriptionCount=0,this._subscriptionService=this.appContext.getService(a.AzureResourceServiceNames.subscriptionService),this._subscriptionFilterService=this.appContext.getService(a.AzureResourceServiceNames.subscriptionFilterService),this._id=`account_${this.account.key.accountId}.tenant_${t.id}`,this.setCacheKey(`${this._id}.subscriptions`),this._label=this.generateLabel()}async getChildren(){try{let e=[];this._isClearingCache?(e=await this._subscriptionService.getSubscriptions(this.account,[this.tenant.id]),await this.updateCache(e),this._isClearingCache=!1):e=await this.getCachedSubscriptions(),this._totalSubscriptionCount=e.length;const t=await this._subscriptionFilterService.getSelectedSubscriptions(this.account,this.tenant),n=t?.filter((e=>e.tenant===this.tenant.id)),r=(n||[]).map((e=>e.id));return r.length>0?(e=e.filter((e=>-1!==r.indexOf(e.id))),this._selectedSubscriptionCount=r.length):this._selectedSubscriptionCount=this._totalSubscriptionCount,this.refreshLabel(),0===e.length?[u.AzureResourceMessageTreeNode.create(p.noSubscriptionsLabel,this)]:(await Promise.all(e.map((async e=>new c.AzureResourceSubscriptionTreeNode(this.account,e,this.tenant,this.appContext,this.treeChangeHandler,this))))).sort(((e,t)=>e.subscription.name.localeCompare(t.subscription.name)))}catch(e){return e instanceof i.AzureSubscriptionError&&r.commands.executeCommand("azure.resource.signin"),[u.AzureResourceMessageTreeNode.create(l.AzureResourceErrorMessageUtil.getErrorMessage(e),this)]}}async getCachedSubscriptions(){return this.getCache()??[]}getTreeItem(){const e=new r.TreeItem(this._label,r.TreeItemCollapsibleState.Collapsed);return e.id=this._id,e.contextValue=a.AzureResourceItemType.tenant,e.iconPath=this.appContext.extensionContext.asAbsolutePath("resources/tenant.svg"),e}getNodeInfo(){return{label:this._label,isLeaf:!1,errorMessage:void 0,metadata:void 0,nodePath:this.generateNodePath(),parentNodePath:this.parent?.generateNodePath()??"",nodeStatus:void 0,nodeType:a.AzureResourceItemType.tenant,nodeSubType:void 0,iconType:a.AzureResourceItemType.tenant}}get nodePathValue(){return this._id}get totalSubscriptionCount(){return this._totalSubscriptionCount}get selectedSubscriptionCount(){return this._selectedSubscriptionCount}refreshLabel(){const e=this.generateLabel();this._label!==e&&(this._label=e,this.treeChangeHandler.notifyNodeChanged(this))}generateLabel(){let e=this.tenant.displayName;return 0!==this._totalSubscriptionCount&&(e+=` (${this._selectedSubscriptionCount} / ${this._totalSubscriptionCount} subscriptions)`),e}sleep(e){return new Promise((t=>setTimeout(t,e)))}}t.AzureResourceTenantTreeNode=p,p.noSubscriptionsLabel=o(0,null)},1113:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AzureResourceTreeProvider=void 0;const r=n(1398),o=n(235),i=n(4200).loadMessageBundle(n(6928).join(__dirname,"azureResource/tree/treeProvider.ts")),s=n(6653),a=n(9995),c=n(7182),u=n(5760),l=n(6752);class p extends r.Disposable{constructor(e){super((()=>{this._onDidChangeTreeData.dispose()})),this.appContext=e,this.isSystemInitialized=!1,this.accounts=[],this._onDidChangeTreeData=new r.EventEmitter,o.accounts.onDidChangeAccounts((async e=>{let t=await o.accounts.getAllAccounts();t=t.filter((e=>e.key.providerId.startsWith("azure"))),this.setSystemInitialized(),(0,l.equals)(t,this.accounts)||(this.accounts=t,this.notifyNodeChanged(void 0))}))}async getChildren(e){if(e)return e.getChildren();if(!this.isSystemInitialized)return this.loadingAccountsPromise||(this.loadingAccountsPromise=this.loadAccounts()),[c.AzureResourceMessageTreeNode.create(i(0,null),void 0)];try{return this.accounts?0===this.accounts.length?[new a.AzureResourceAccountNotSignedInTreeNode]:this.accounts.map((e=>new s.AzureResourceAccountTreeNode(e,this.appContext,this))):[c.AzureResourceMessageTreeNode.create(i(1,null),void 0)]}catch(e){return[c.AzureResourceMessageTreeNode.create(l.AzureResourceErrorMessageUtil.getErrorMessage(e),void 0)]}}async loadAccounts(){try{this.accounts=await o.accounts.getAllAccounts(),this.setSystemInitialized(),this.notifyNodeChanged(void 0)}catch(e){this.isSystemInitialized=!1}}setSystemInitialized(){this.isSystemInitialized=!0,this.loadingAccountsPromise=void 0}get onDidChangeTreeData(){return this._onDidChangeTreeData.event}notifyNodeChanged(e){this._onDidChangeTreeData.fire(e)}async refresh(e,t){t&&e instanceof u.AzureResourceContainerTreeNodeBase&&e.clearCache(),this.notifyNodeChanged(e)}getTreeItem(e){return e.getTreeItem()}}t.AzureResourceTreeProvider=p},4729:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TreeNode=void 0;class n{constructor(){this.parent=void 0}generateNodePath(){let e;return this.parent&&(e=this.parent.generateNodePath()),e=e?`${e}/${this.nodePathValue}`:this.nodePathValue,e}findNodeByPath(e,t=!1){return n.findNode(this,(t=>t.getNodeInfo().nodePath===e),(t=>e.startsWith(t.getNodeInfo().nodePath)),!0)}static async findNode(e,t,n,r){if(!e)return;if(t(e))return e;if(e.getNodeInfo().isLeaf)return;let o=await e.getChildren();if(o)for(let e of o)if(n&&n(e)){let o=await this.findNode(e,t,n,r);if(o)return o}}}t.TreeNode=n},6752:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getProviderMetadataForAccount=t.getBlobs=t.getStorageAccountAccessKey=t.createResourceGroup=t.getFileShares=t.getBlobContainers=t.getManagedDatabases=t.makeHttpRequest=t.getSelectedSubscriptions=t.getSubscriptions=t.runResourceQuery=t.getAllResourceProviders=t.getLocations=t.getResourceGroups=t.equals=t.generateGuid=t.AzureResourceErrorMessageUtil=t.isErrorResponseBodyWithError=void 0;const r=n(235),o=n(1398),i=n(4200),s=n(3508),a=n(3311),c=n(3253),u=n(857),l=n(1651),p=n(7768),d=n(7583),h=n(4581),f=n(2259),m=n(3528),v=n(7274),g=n(8111),y=n(9551),_=n(7183),b=n(3471),E=n(5180),T=n(4134),S=n(694),C=n(3992),x=n(272),w=n(5778),A=n(6516),I=n(8174),R=n(2032),P=n(3522),O=n(6706),N=n(6556),k=n(8151),D=n(6948),M=n(4670),L=n(3292),j=n(2758),U=n(7936),F=n(4034),z=n(7350),q=n(7304),B=n(1342),H=n(5284),G=n(6303),V=n(7375),$=n(9329),K=i.loadMessageBundle(n(6928).join(__dirname,"azureResource/utils.ts"));function W(e){return"error"in e&&e.error}async function Q(e,t,n,o,i,s=!1,a="https://management.azure.com",c={}){const p={response:void 0,errors:[]};if(!e?.properties?.tenants||!Array.isArray(e.properties.tenants)){const e=new Error(l.invalidAzureAccount);if(!s)throw e;p.errors.push(e)}if(!t.tenant){const e=new Error(l.invalidTenant);if(!s)throw e;p.errors.push(e)}if(p.errors.length>0)return p;let d;try{d=await r.accounts.getAccountSecurityToken(e,t.tenant,r.AzureResource.ResourceManagement)}catch(e){console.error(e);const n=new Error((0,l.unableToFetchTokenError)(t?.tenant||"<unknown>"));if(!s)throw n;p.errors.push(n)}if(p.errors.length>0||!d)return p;const h={headers:{"Content-Type":"application/json",Authorization:`Bearer ${d.token}`,...c},validateStatus:()=>!0};let f,m;switch(0!==n.indexOf("/")&&(n=`/${n}`),f=a?`${a}${n}`:`${e.properties.providerSettings.settings.armResource.endpoint}${n}`,o){case 0:m=await $.default.get(f,h);break;case 2:m=await $.default.post(f,i,h);break;case 1:m=await $.default.put(f,i,h);break;case 3:m=await $.default.delete(f,h);break;case 4:m=await $.default.patch(f,h);break;default:const e=new Error(`Unknown RequestType "${o}"`);if(!s)throw e;p.errors.push(e)}if(m)if(m.status<200||m.status>299){let e=[];e.push(m.status.toString());const t=m.data;W(t)&&e.push(`${t.error.code} : ${t.error.message}`);const n=new Error(e.join(u.EOL));if(!s)throw n;p.errors.push(n)}else p.response=m;else{const e=new Error(`No response to HTTP request ${f}`);if(!s)throw e;p.errors.push(e)}return p}async function Y(e,t,n,r){const o=`/subscriptions/${t.id}/resourceGroups/${n.resourceGroup}/providers/Microsoft.Storage/storageAccounts/${n.name}/listKeys?api-version=2019-06-01`,i=X(e).settings.armResource.endpoint,s=await Q(e,t,o,2,void 0,r,i);return{keyName1:s?.response?.data?.keys[0].value??"",keyName2:s?.response?.data?.keys[0].value??"",errors:s.errors?s.errors:[]}}function X(e){const t=h.default.find((t=>e.properties.providerSettings.id===t.metadata.id));if(!t)throw new Error(`Could not find provider ${e.properties.providerSettings.id} for account ${e.displayInfo.displayName} (${e.displayInfo.userId})`);return t.metadata}t.isErrorResponseBodyWithError=W,t.AzureResourceErrorMessageUtil=class{static getErrorMessage(e){return K(0,null,function(e){return e instanceof Error?e.message:e}(e))}},t.generateGuid=function(){let e,t=["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F"],n="";for(let r=0;r<4;r++)e=4294967296*Math.random()|0,n+=t[15&e]+t[e>>4&15]+t[e>>8&15]+t[e>>12&15]+t[e>>16&15]+t[e>>20&15]+t[e>>24&15]+t[e>>28&15];let r=t[8+4*Math.random()|0];return n.substr(0,8)+"-"+n.substr(9,4)+"-4"+n.substr(13,3)+"-"+r+n.substr(16,3)+"-"+n.substr(19,12)},t.equals=function e(t,n){if(t===n)return!0;if(null==t||null==n)return!1;if(typeof t!=typeof n)return!1;if("object"!=typeof t)return!1;if(Array.isArray(t)!==Array.isArray(n))return!1;let r,o;if(Array.isArray(t)){if(t.length!==n.length)return!1;for(r=0;r<t.length;r++)if(!e(t[r],n[r]))return!1}else{const i=[];for(o in t)i.push(o);i.sort();const s=[];for(o in n)s.push(o);if(s.sort(),!e(i,s))return!1;for(r=0;r<i.length;r++)if(!e(t[i[r]],n[i[r]]))return!1}return!0},t.getResourceGroups=async function(e,t,n,o=!1){const i={resourceGroups:[],errors:[]};if(!t?.properties?.tenants||!Array.isArray(t.properties.tenants)||!n){const e=new Error(l.invalidAzureAccount);if(!o)throw e;return i.errors.push(e),i}const s=e.getService(p.AzureResourceServiceNames.resourceGroupService);return await Promise.all(t.properties.tenants.map((async e=>{try{const o=await r.accounts.getAccountSecurityToken(t,e.id,r.AzureResource.ResourceManagement);if(!o)throw new Error(`Could not fetch security token fetching resource groups for tenant "${e.id}"`);const a=o.token,u=o.tokenType;i.resourceGroups.push(...await s.getResources([n],new c.TokenCredentials(a,u),t))}catch(r){if(!(r instanceof f.TenantIgnoredError)){const s=new Error(K(1,null,t.displayInfo.displayName,t.displayInfo.userId,n.id,n.name,e.id,r instanceof Error?r.message:r));if(console.warn(s),!o)throw s;i.errors.push(s)}}}))),i},t.getLocations=async function(e,t,n,r=!1){const o={locations:[],errors:[]};if(!t?.properties?.tenants||!Array.isArray(t.properties.tenants)||!n){const e=new Error(l.invalidAzureAccount);if(!r)throw e;return o.errors.push(e),o}try{const e=`/subscriptions/${n.id}/locations?api-version=2020-01-01`,i=X(t).settings.armResource.endpoint,s=await Q(t,n,e,0,void 0,r,i);o.locations.push(...s.response?.data.value||[]),o.errors.push(...s.errors)}catch(e){const i=new Error(K(2,null,t.displayInfo.displayName,t.displayInfo.userId,n.id,n.name,t.properties.tenants[0].id,e instanceof Error?e.message:e));if(console.warn(i),!r)throw i;o.errors.push(i)}return o},t.getAllResourceProviders=function(e){const t=o.workspace.getConfiguration(s.AzureSection).get(s.EnableArcFeaturesSection),n=[new k.ResourceProvider(s.AZURE_MONITOR_PROVIDER_ID,new v.AzureMonitorTreeDataProvider(new m.AzureMonitorResourceService,e)),new k.ResourceProvider(s.COSMOSDB_MONGO_PROVIDER_ID,new _.CosmosDbMongoTreeDataProvider(new g.CosmosDbMongoService,e)),new k.ResourceProvider(s.COSMOSDB_NOSQL_PROVIDER_ID,new b.CosmosDbNoSqlTreeDataProvider(new y.CosmosDbNoSqlService,e)),new k.ResourceProvider(s.COSMOSDB_POSTGRES_PROVIDER_ID,new G.CosmosDbPostgresTreeDataProvider(new V.CosmosDbPostgresService,e)),new k.ResourceProvider(s.DATABASE_PROVIDER_ID,new T.AzureResourceDatabaseTreeDataProvider(new E.AzureResourceDatabaseService,e)),new k.ResourceProvider(s.DATABASE_SERVER_PROVIDER_ID,new C.AzureResourceDatabaseServerTreeDataProvider(new S.AzureResourceDatabaseServerService,e)),new k.ResourceProvider(s.KUSTO_PROVIDER_ID,new w.KustoTreeDataProvider(new x.KustoResourceService,e)),new k.ResourceProvider(s.MYSQL_FLEXIBLE_SERVER_PROVIDER_ID,new I.MysqlFlexibleServerTreeDataProvider(new A.MysqlFlexibleServerService,e)),new k.ResourceProvider(s.POSTGRES_FLEXIBLE_SERVER_PROVIDER_ID,new B.PostgresFlexibleServerTreeDataProvider(new H.PostgresFlexibleServerService,e)),new k.ResourceProvider(s.POSTGRES_SERVER_PROVIDER_ID,new N.PostgresServerTreeDataProvider(new O.PostgresServerService,e)),new k.ResourceProvider(s.SQLINSTANCE_PROVIDER_ID,new M.SqlInstanceTreeDataProvider(new D.SqlInstanceResourceService,e)),new k.ResourceProvider(s.SYNAPSE_SQL_POOL_PROVIDER_ID,new F.AzureResourceSynapseSqlPoolTreeDataProvider(new U.AzureResourceSynapseService,e)),new k.ResourceProvider(s.SYNAPSE_WORKSPACE_PROVIDER_ID,new q.AzureResourceSynapseWorkspaceTreeDataProvider(new z.AzureResourceSynapseWorkspaceService,e))];return t&&n.push(new k.ResourceProvider(s.SQLINSTANCE_ARC_PROVIDER_ID,new j.SqlInstanceArcTreeDataProvider(new L.SqlInstanceArcResourceService,e)),new k.ResourceProvider(s.POSTGRES_ARC_SERVER_PROVIDER_ID,new P.PostgresServerArcTreeDataProvider(new R.PostgresServerArcService,e))),n},t.runResourceQuery=async function(e,t,n=!1,o){const i={resources:[],errors:[]};if(!e?.properties?.tenants||!Array.isArray(e.properties.tenants)){const e=new Error(l.invalidAzureAccount);if(!n)throw e;return i.errors.push(e),i}if(t.forEach((e=>{if(!e.tenant){const e=new Error(l.invalidTenant);if(!n)throw e;i.errors.push(e)}})),i.errors.length>0)return i;for(let n=0;n<e.properties.tenants.length;++n){const s=e.properties.tenants[n],u=t.filter((e=>e.tenant===s.id));if(u.length<1)continue;let p;try{const t=await r.accounts.getAccountSecurityToken(e,s.id,r.AzureResource.ResourceManagement);if(!t)throw new Error(`Could not fetch security token for query "${o}" on tenant ${s.id}`);const n=t.token,i=t.tokenType,u=new c.TokenCredentials(n,i);p=new a.ResourceGraphClient(u,{baseUri:e.properties.providerSettings.settings.armResource.endpoint})}catch(e){if(console.error(e),!(e instanceof f.TenantIgnoredError)){const e=new Error((0,l.unableToFetchTokenError)(s.id));i.errors.push(e)}continue}const d=[];let h=0;const m=async e=>{const t=await p.resources({subscriptions:u.map((e=>e.id)),query:o,options:{resultFormat:"objectArray",skipToken:e}}),n=t.data;h+=n.length,d.push(...n),t.skipToken&&h<t.totalRecords&&await m(t.skipToken)};try{await m()}catch(e){console.error(e);const t=new Error(K(3,null));i.errors.push(t)}i.resources.push(...d)}return i},t.getSubscriptions=async function(e,t,n=!1){const r={subscriptions:[],errors:[]};if(!t?.properties?.tenants||!Array.isArray(t.properties.tenants)){const e=new Error(l.invalidAzureAccount);if(!n)throw e;return r.errors.push(e),r}const o=e.getService(p.AzureResourceServiceNames.subscriptionService);return await Promise.all(t.properties.tenants.map((async e=>{try{r.subscriptions.push(...await o.getSubscriptions(t,[e.id]))}catch(o){const i=new Error(K(4,null,t.displayInfo.displayName,e.id,o instanceof Error?o.message:o));if(console.warn(i),!n)throw i;r.errors.push(i)}}))),r},t.getSelectedSubscriptions=async function(e,t,n=!1){const r={subscriptions:[],errors:[]};if(!t?.properties?.tenants||!Array.isArray(t.properties.tenants)){const e=new Error(l.invalidAzureAccount);if(!n)throw e;return r.errors.push(e),r}const o=e.getService(p.AzureResourceServiceNames.subscriptionFilterService),i=e.getService(p.AzureResourceServiceNames.tenantFilterService);try{const e=await i.getSelectedTenants(t);for(const n of e)r.subscriptions.push(...await o.getSelectedSubscriptions(t,n))}catch(e){const o=new Error(K(5,null,t.displayInfo.displayName,e instanceof Error?e.message:e));if(console.warn(o),!n)throw o;r.errors.push(o)}return r},t.makeHttpRequest=Q,t.getManagedDatabases=async function(e,t,n,r){const o=`/subscriptions/${t.id}/resourceGroups/${n.resourceGroup}/providers/Microsoft.Sql/managedInstances/${n.name}/databases?api-version=2020-02-02-preview`,i=X(e).settings.armResource.endpoint,s=await Q(e,t,o,0,void 0,r,i);return{databases:s?.response?.data?.value??[],errors:s.errors?s.errors:[]}},t.getBlobContainers=async function(e,t,n,r){const o=`/subscriptions/${t.id}/resourceGroups/${n.resourceGroup}/providers/Microsoft.Storage/storageAccounts/${n.name}/blobServices/default/containers?api-version=2019-06-01`,i=X(e).settings.armResource.endpoint,s=await Q(e,t,o,0,void 0,r,i);return{blobContainers:s?.response?.data?.value??[],errors:s.errors?s.errors:[]}},t.getFileShares=async function(e,t,n,r){const o=`/subscriptions/${t.id}/resourceGroups/${n.resourceGroup}/providers/Microsoft.Storage/storageAccounts/${n.name}/fileServices/default/shares?api-version=2019-06-01`,i=X(e).settings.armResource.endpoint,s=await Q(e,t,o,0,void 0,r,i);return{fileShares:s?.response?.data?.value??[],errors:s.errors?s.errors:[]}},t.createResourceGroup=async function(e,t,n,r,o){const i=`/subscriptions/${t.id}/resourcegroups/${n}?api-version=2021-04-01`,s={location:r},a=X(e).settings.armResource.endpoint,c=await Q(e,t,i,1,s,o,a);return{resourceGroup:c?.response?.data,errors:c.errors?c.errors:[]}},t.getStorageAccountAccessKey=Y,t.getBlobs=async function(e,t,n,r,o){const i={blobs:[],errors:[]},s=await Y(e,t,n,o);if(!o)throw s.errors.toString();i.errors.push(...s.errors);try{const t=new d.StorageSharedKeyCredential(n.name,s.keyName1),o=new d.BlobServiceClient(`https://${n.name}.blob${e.properties.providerSettings.settings.azureStorageResource.endpointSuffix}`,t).getContainerClient(r);for await(const e of o.listBlobsFlat())i.blobs.push(e)}catch(e){if(!o)throw e;i.errors.push(e)}return i},t.getProviderMetadataForAccount=X},3508:(e,t)=>{"use strict";var n,r,o,i,s;Object.defineProperty(t,"__esModule",{value:!0}),t.AZURE_MONITOR_PROVIDER_ID=t.Platform=t.AccountType=t.AccountIssuer=t.AuthType=t.BuiltInCommands=t.multiple_matching_tokens_error=t.AADSTS700084=t.AADSTS700082=t.AADSTS50089=t.AADSTS50085=t.AADSTS50078=t.AADSTS50173=t.AADSTS70043=t.LockFileSuffix=t.LocalCacheSuffix=t.MSALCacheName=t.AzureTokenFolderName=t.dataGridProviderId=t.HomeCategory=t.ViewType=t.Saw=t.SELECT_ACCOUNT=t.S256_CODE_CHALLENGE_METHOD=t.httpConfigSectionName=t.Bearer=t.AccountVersion=t.PackageName=t.CustomProviderSettingsSection=t.CustomProviderSettings=t.piiLogging=t.oldMsalCacheFileName=t.NoSystemKeyChainSection=t.TenantSection=t.ServiceName=t.EnableArcFeaturesSection=t.enableChinaCloud=t.enableUsGovCloud=t.enablePublicCloud=t.AccountsAzureCloudSection=t.AccountsAzureAuthSection=t.AccountsClearTokenCacheCommand=t.ConfigSection=t.ClearTokenCacheCommand=t.CloudSection=t.AzureAccountProviderCredentials=t.AzureSection=t.AuthSection=t.AccountsSection=t.Account=void 0,t.UNIVERSAL_PROVIDER_ID=t.SYNAPSE_WORKSPACE_PROVIDER_ID=t.SYNAPSE_SQL_POOL_PROVIDER_ID=t.SQLINSTANCE_ARC_PROVIDER_ID=t.SQLINSTANCE_PROVIDER_ID=t.POSTGRES_SERVER_PROVIDER_ID=t.POSTGRES_FLEXIBLE_SERVER_PROVIDER_ID=t.POSTGRES_ARC_SERVER_PROVIDER_ID=t.MYSQL_FLEXIBLE_SERVER_PROVIDER_ID=t.KUSTO_PROVIDER_ID=t.DATABASE_SERVER_PROVIDER_ID=t.DATABASE_PROVIDER_ID=t.COSMOSDB_POSTGRES_PROVIDER_ID=t.COSMOSDB_NOSQL_PROVIDER_ID=t.COSMOSDB_MONGO_PROVIDER_ID=void 0,t.Account="account",t.AccountsSection="accounts",t.AuthSection="auth",t.AzureSection="azure",t.AzureAccountProviderCredentials="azureAccountProviderCredentials",t.CloudSection="cloud",t.ClearTokenCacheCommand="clearTokenCache",t.ConfigSection="config",t.AccountsClearTokenCacheCommand=t.AccountsSection+"."+t.ClearTokenCacheCommand,t.AccountsAzureAuthSection=t.AccountsSection+"."+t.AzureSection+"."+t.AuthSection,t.AccountsAzureCloudSection=t.AccountsSection+"."+t.AzureSection+"."+t.CloudSection,t.enablePublicCloud="enablePublicCloud",t.enableUsGovCloud="enableUsGovCloud",t.enableChinaCloud="enableChinaCloud",t.EnableArcFeaturesSection="enableArcFeatures",t.ServiceName="azuredatastudio",t.TenantSection="tenant",t.NoSystemKeyChainSection="noSystemKeychain",t.oldMsalCacheFileName="azureTokenCacheMsal-azure_publicCloud",t.piiLogging="piiLogging",t.CustomProviderSettings="customProviderSettings",t.CustomProviderSettingsSection=t.AzureSection+"."+t.CustomProviderSettings,t.PackageName="Microsoft.azurecore",t.AccountVersion="2.0",t.Bearer="Bearer",t.httpConfigSectionName="http",t.S256_CODE_CHALLENGE_METHOD="S256",t.SELECT_ACCOUNT="select_account",t.Saw="saw",t.ViewType="view",t.HomeCategory="Home",t.dataGridProviderId="azure-resources",t.AzureTokenFolderName="Azure Accounts",t.MSALCacheName="accessTokenCache",t.LocalCacheSuffix=".local",t.LockFileSuffix=".lockfile",t.AADSTS70043="AADSTS70043",t.AADSTS50173="AADSTS50173",t.AADSTS50078="AADSTS50078",t.AADSTS50085="AADSTS50085",t.AADSTS50089="AADSTS50089",t.AADSTS700082="AADSTS700082",t.AADSTS700084="AADSTS700084",t.multiple_matching_tokens_error="multiple_matching_tokens",function(e){e.SetContext="setContext"}(n||(t.BuiltInCommands=n={})),function(e){e.DeviceCode="deviceCode",e.CodeGrant="codeGrant"}(r||(t.AuthType=r={})),function(e){e.Corp="corp",e.Msft="msft"}(o||(t.AccountIssuer=o={})),function(e){e.WorkSchool="work_school",e.Microsoft="microsoft"}(i||(t.AccountType=i={})),function(e){e.Windows="win32",e.Mac="darwin",e.Linux="linux"}(s||(t.Platform=s={})),t.AZURE_MONITOR_PROVIDER_ID="azure.resource.providers.azureMonitor",t.COSMOSDB_MONGO_PROVIDER_ID="azure.resource.providers.cosmosDbMongo",t.COSMOSDB_NOSQL_PROVIDER_ID="azure.resource.providers.cosmosDbNoSql",t.COSMOSDB_POSTGRES_PROVIDER_ID="azure.resource.providers.cosmosDbPostgres",t.DATABASE_PROVIDER_ID="azure.resource.providers.database",t.DATABASE_SERVER_PROVIDER_ID="azure.resource.providers.databaseServer",t.KUSTO_PROVIDER_ID="azure.resource.providers.azureDataExplorer",t.MYSQL_FLEXIBLE_SERVER_PROVIDER_ID="azure.resource.providers.mysqlFlexibleServer",t.POSTGRES_ARC_SERVER_PROVIDER_ID="azure.resource.providers.postgresArcServer",t.POSTGRES_FLEXIBLE_SERVER_PROVIDER_ID="azure.resource.providers.postgresFlexibleServer",t.POSTGRES_SERVER_PROVIDER_ID="azure.resource.providers.postgresServer",t.SQLINSTANCE_PROVIDER_ID="azure.resource.providers.sqlInstance",t.SQLINSTANCE_ARC_PROVIDER_ID="azure.resource.providers.sqlInstanceArc",t.SYNAPSE_SQL_POOL_PROVIDER_ID="azure.resource.providers.synapseSqlPool",t.SYNAPSE_WORKSPACE_PROVIDER_ID="azure.resource.providers.synapseWorkspace",t.UNIVERSAL_PROVIDER_ID="azure.resource.providers.universal"},1651:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.name=t.westUS2=t.westUS=t.westIndia=t.westEurope=t.westCentralUS=t.ukWest=t.ukSouth=t.uaeNorth=t.uaeCentral=t.switzerlandWest=t.switzerlandNorth=t.southIndia=t.southEastAsia=t.southCentralUS=t.southAfricaWest=t.southAfricaNorth=t.norwayWest=t.norwayEast=t.northEurope=t.northCentralUS=t.koreaSouth=t.koreaCentral=t.japanWest=t.japanEast=t.germanyWestCentral=t.germanyNorth=t.franceSouth=t.franceCentral=t.eastUS2EUAP=t.eastUS2=t.eastUS=t.eastAsia=t.centralUSEUAP=t.centralUS=t.centralIndia=t.canadaEast=t.canadaCentral=t.brazilSouthEast=t.brazilSouth=t.australiaSouthEast=t.australiaEast=t.australiaCentral2=t.australiaCentral=t.enablePublicCloudCamel=t.enablePublicCloud=t.cancel=t.reload=t.requiresReload=t.extensionName=void 0,t.noCloudsEnabled=t.azureCredStoreSaveFailedError=t.unableToFetchTokenError=t.invalidTenant=t.invalidAzureAccount=t.azureResourcesGridTitle=t.unableToOpenAzureLink=t.azureArcPostgresServer=t.sqlServerArc=t.azureArcService=t.azureArcsqlManagedInstance=t.sqlManagedInstance=t.postgresFlexibleServer=t.postgresServer=t.sqlDatabase=t.sqlServer=t.switchMsal=t.dismiss=t.disable=t.piiWarning=t.reloadChoice=t.reloadPromptCacheClear=t.reloadPrompt=t.typeIcon=t.subscription=t.location=t.resourceGroup=t.resourceType=void 0;const r=n(4200).loadMessageBundle(n(6928).join(__dirname,"localizedConstants.ts"));t.extensionName=r(0,null),t.requiresReload=r(1,null),t.reload=r(2,null),t.cancel=r(3,null),t.enablePublicCloud=r(4,null),t.enablePublicCloudCamel=r(5,null),t.australiaCentral=r(6,null),t.australiaCentral2=r(7,null),t.australiaEast=r(8,null),t.australiaSouthEast=r(9,null),t.brazilSouth=r(10,null),t.brazilSouthEast=r(11,null),t.canadaCentral=r(12,null),t.canadaEast=r(13,null),t.centralIndia=r(14,null),t.centralUS=r(15,null),t.centralUSEUAP=r(16,null),t.eastAsia=r(17,null),t.eastUS=r(18,null),t.eastUS2=r(19,null),t.eastUS2EUAP=r(20,null),t.franceCentral=r(21,null),t.franceSouth=r(22,null),t.germanyNorth=r(23,null),t.germanyWestCentral=r(24,null),t.japanEast=r(25,null),t.japanWest=r(26,null),t.koreaCentral=r(27,null),t.koreaSouth=r(28,null),t.northCentralUS=r(29,null),t.northEurope=r(30,null),t.norwayEast=r(31,null),t.norwayWest=r(32,null),t.southAfricaNorth=r(33,null),t.southAfricaWest=r(34,null),t.southCentralUS=r(35,null),t.southEastAsia=r(36,null),t.southIndia=r(37,null),t.switzerlandNorth=r(38,null),t.switzerlandWest=r(39,null),t.uaeCentral=r(40,null),t.uaeNorth=r(41,null),t.ukSouth=r(42,null),t.ukWest=r(43,null),t.westCentralUS=r(44,null),t.westEurope=r(45,null),t.westIndia=r(46,null),t.westUS=r(47,null),t.westUS2=r(48,null),t.name=r(49,null),t.resourceType=r(50,null),t.resourceGroup=r(51,null),t.location=r(52,null),t.subscription=r(53,null),t.typeIcon=r(54,null),t.reloadPrompt=function(e){return r(55,null,e)},t.reloadPromptCacheClear=r(56,null),t.reloadChoice=r(57,null),t.piiWarning=r(58,null),t.disable=r(59,null),t.dismiss=r(60,null),t.switchMsal=r(61,null),t.sqlServer=r(62,null),t.sqlDatabase=r(63,null),t.postgresServer=r(64,null),t.postgresFlexibleServer=r(65,null),t.sqlManagedInstance=r(66,null),t.azureArcsqlManagedInstance=r(67,null),t.azureArcService=r(68,null),t.sqlServerArc=r(69,null),t.azureArcPostgresServer=r(70,null),t.unableToOpenAzureLink=r(71,null),t.azureResourcesGridTitle=r(72,null),t.invalidAzureAccount=r(73,null),t.invalidTenant=r(74,null),t.unableToFetchTokenError=function(e){return r(75,null,e)},t.azureCredStoreSaveFailedError=r(76,null),t.noCloudsEnabled=r(77,null)},1017:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getProxyAgentOptions=t.getProxyAgent=t.isBoolean=void 0;const r=n(6645),o=n(2288),i=n(7016);function s(e){return"http:"===e.protocol?process.env.HTTP_PROXY||process.env.http_proxy||void 0:"https:"===e.protocol&&(process.env.HTTPS_PROXY||process.env.https_proxy||process.env.HTTP_PROXY||process.env.http_proxy)||void 0}function a(e){return!0===e||!1===e}function c(e,t,n){const r=t||s(e);if(!r)return;const o=(0,i.parse)(r);return/^https?:$/.test(o.protocol)?{host:o.hostname,port:Number(o.port),auth:o.auth,rejectUnauthorized:!a(n)||n}:void 0}t.isBoolean=a,t.getProxyAgent=function(e,t,n){const a=t||s(e);if(!a)return;const u=(0,i.parse)(a),l=c(e,t,n);return"https:"===u.protocol?new o.HttpsProxyAgent(l):new r.HttpProxyAgent(l)},t.getProxyAgentOptions=c},6734:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TelemetryAction=t.TelemetryViews=t.TelemetryReporter=void 0;const r=n(1398),o=n(1616),i=n(3508),s=r.extensions.getExtension(i.PackageName)?.packageJSON;var a,c;t.TelemetryReporter=new o.default(s.name,s.version,s.aiKey),function(e){e.AzureCore="AzureCore"}(a||(t.TelemetryViews=a={})),function(e){e.LoadCustomEndpointsError="LoadCustomEndpointsError",e.LoadCustomEndpointsSuccess="LoadCustomEndpointsSuccess",e.ReloadAdsCustomEndpoints="ReloadAdsCustomEndpoints"}(c||(t.TelemetryAction=c={}))},76:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.displayReloadAds=t.getResourceTypeIcon=t.updateCustomCloudProviderSettings=t.getResourceTypeDisplayName=t.getRegionDisplayName=void 0;const r=n(1651),o=n(1398),i=n(4200),s=n(3508),a=n(235),c=n(7147),u=n(6734),l=i.loadMessageBundle(n(6928).join(__dirname,"utils.ts"));function p(e){let t={configKey:"enableCustom"+e.settings.metadata.id,metadata:{displayName:e.settings.metadata.displayName,id:e.settings.metadata.id,settings:{host:e.settings.metadata.endpoints.host,clientId:e.settings.metadata.endpoints.clientId,microsoftResource:{id:"marm",endpoint:e.settings.metadata.endpoints.microsoftResource,azureResourceId:a.AzureResource.MicrosoftResourceManagement},armResource:{id:"arm",endpoint:e.settings.metadata.endpoints.armResource,azureResourceId:a.AzureResource.ResourceManagement},azureStorageResource:{id:"storage",endpoint:e.settings.metadata.endpoints.azureStorageResource.endpoint,endpointSuffix:e.settings.metadata.endpoints.azureStorageResource.endpointSuffix,azureResourceId:a.AzureResource.AzureStorage},sqlResource:{id:"sql",endpoint:e.settings.metadata.endpoints.sqlResource,azureResourceId:a.AzureResource.Sql},redirectUri:"http://localhost",scopes:["openid","email","profile","offline_access",e.settings.metadata.endpoints.scopes]}}};return e.settings.metadata.endpoints.msGraphResource&&(t.metadata.settings.msGraphResource={id:"msgraph",endpoint:e.settings.metadata.endpoints.msGraphResource,azureResourceId:a.AzureResource.MsGraph}),e.settings.metadata.endpoints.azureLogAnalyticsResource&&(t.metadata.settings.azureLogAnalyticsResource={id:"ala",endpoint:e.settings.metadata.endpoints.azureLogAnalyticsResource,azureResourceId:a.AzureResource.AzureLogAnalytics}),e.settings.metadata.endpoints.azureKustoResource&&(t.metadata.settings.azureKustoResource={id:"kusto",endpoint:e.settings.metadata.endpoints.azureKustoResource,azureResourceId:a.AzureResource.AzureKusto}),e.settings.metadata.endpoints.azureKeyVaultResource&&(t.metadata.settings.azureKeyVaultResource={id:"vault",endpoint:e.settings.metadata.endpoints.azureKeyVaultResource,azureResourceId:a.AzureResource.AzureKeyVault}),e.settings.metadata.endpoints.powerBiResource&&(t.metadata.settings.powerBiResource={id:"powerbi",endpoint:e.settings.metadata.endpoints.powerBiResource,azureResourceId:a.AzureResource.PowerBi}),e.settings.metadata.endpoints.portalEndpoint&&(t.metadata.settings.portalEndpoint=e.settings.metadata.endpoints.portalEndpoint),t}async function d(e){return await o.window.showInformationMessage(r.reloadPrompt(e),r.reloadChoice)===r.reloadChoice&&(await o.commands.executeCommand("workbench.action.reloadWindow"),!0)}t.getRegionDisplayName=function(e){switch((e=e??"").toLocaleLowerCase()){case"australiacentral":return r.australiaCentral;case"australiacentral2":return r.australiaCentral2;case"australiaeast":return r.australiaEast;case"australiasoutheast":return r.australiaSouthEast;case"brazilsouth":return r.brazilSouth;case"brazilsoutheast":return r.brazilSouthEast;case"canadacentral":return r.canadaCentral;case"canadaeast":return r.canadaEast;case"centralindia":return r.centralIndia;case"centralus":return r.centralUS;case"centraluseuap":return r.centralUSEUAP;case"eastasia":return r.eastAsia;case"eastus":return r.eastUS;case"eastus2":return r.eastUS2;case"eastus2euap":return r.eastUS2EUAP;case"francecentral":return r.franceCentral;case"francesouth":return r.franceSouth;case"germanynorth":return r.germanyNorth;case"germanywestcentral":return r.germanyWestCentral;case"japaneast":return r.japanEast;case"japanwest":return r.japanWest;case"koreacentral":return r.koreaCentral;case"koreasouth":return r.koreaSouth;case"northcentralus":return r.northCentralUS;case"northeurope":return r.northEurope;case"norwayeast":return r.norwayEast;case"norwaywest":return r.norwayWest;case"southafricanorth":return r.southAfricaNorth;case"southafricawest":return r.southAfricaWest;case"southcentralus":return r.southCentralUS;case"southeastasia":return r.southEastAsia;case"southindia":return r.southIndia;case"switzerlandnorth":return r.switzerlandNorth;case"switzerlandwest":return r.switzerlandWest;case"uaecentral":return r.uaeCentral;case"uaenorth":return r.uaeNorth;case"uksouth":return r.ukSouth;case"ukwest":return r.ukWest;case"westcentralus":return r.westCentralUS;case"westeurope":return r.westEurope;case"westindia":return r.westIndia;case"westus":return r.westUS;case"westus2":return r.westUS2}return console.warn(`Unknown Azure region ${e}`),e},t.getResourceTypeDisplayName=function(e){switch(e){case"microsoft.sql/servers":return r.sqlServer;case"microsoft.sql/servers/databases":return r.sqlDatabase;case"microsoft.sql/managedinstances":return r.sqlManagedInstance;case"microsoft.dbforpostgresql/servers":return r.postgresServer;case"microsoft.dbforpostgresql/flexibleservers":return r.postgresFlexibleServer;case"microsoft.azuredata/sqlmanagedinstances":return r.azureArcsqlManagedInstance;case"microsoft.azuredata/datacontrollers":return r.azureArcService;case"microsoft.azuredata/postgresinstances":return r.azureArcPostgresServer}return e},t.updateCustomCloudProviderSettings=function(e){let t=o.workspace.getConfiguration(s.AzureSection).get(s.CustomProviderSettings);if(o.workspace.onDidChangeConfiguration((async e=>{!0===e.affectsConfiguration(s.CustomProviderSettingsSection)&&(await d(s.CustomProviderSettingsSection),u.TelemetryReporter.sendTelemetryEvent(u.TelemetryAction.ReloadAdsCustomEndpoints))})),t&&t.length>0)try{for(let n of t){let t=p(n);e.push(t),c.Logger.info(`Custom provider settings loaded for ${n.settings.metadata.displayName}`)}o.window.showInformationMessage(l(0,null)),u.TelemetryReporter.sendTelemetryEvent(u.TelemetryAction.LoadCustomEndpointsSuccess)}catch(e){throw o.window.showErrorMessage(l(1,null)),console.error(e.message),u.TelemetryReporter.sendErrorEvent2(u.TelemetryViews.AzureCore,u.TelemetryAction.LoadCustomEndpointsError,e),Error(e.message)}return e},t.getResourceTypeIcon=function(e,t){switch(t){case"microsoft.sql/servers":return e.extensionContext.asAbsolutePath("resources/sqlServer.svg");case"microsoft.sql/servers/databases":return e.extensionContext.asAbsolutePath("resources/sqlDatabase.svg");case"microsoft.sql/managedinstances":return e.extensionContext.asAbsolutePath("resources/sqlManagedInstance.svg");case"microsoft.dbforpostgresql/servers":return e.extensionContext.asAbsolutePath("resources/postgresServer.svg");case"microsoft.azuredata/sqlmanagedinstances":return e.extensionContext.asAbsolutePath("resources/azureArcSqlManagedInstance.svg");case"microsoft.azuredata/datacontrollers":return e.extensionContext.asAbsolutePath("resources/azureArcService.svg");case"microsoft.azuredata/postgresinstances":return e.extensionContext.asAbsolutePath("resources/azureArcPostgresServer.svg")}return""},t.displayReloadAds=d},7147:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Logger=t.LogLevel=void 0;const r=n(1398),o=n(1651);var i;!function(e){e[e.Pii=0]="Pii",e[e.Off=1]="Off",e[e.Critical=2]="Critical",e[e.Error=3]="Error",e[e.Warning=4]="Warning",e[e.Information=5]="Information",e[e.Verbose=6]="Verbose",e[e.All=7]="All"}(i||(t.LogLevel=i={}));class s{static shouldLog(e){return e<=i[s.config.loggingLevel]}static write(e,t,...n){if(this.shouldLog(e)||e===i.Pii){const r=`[${i[e]}]: ${t} - ${n.map((e=>JSON.stringify(e))).join(" - ")}`;this.channel.appendLine(r)}}static error(e,...t){this.write(i.Error,e,t)}static info(e,...t){this.write(i.Information,e,t)}static verbose(e,...t){this.write(i.Verbose,e,t)}static pii(e,...t){this.piiLogging&&s.write(i.Pii,e,t)}static piiSanitized(e,t,n,...r){this.piiLogging&&(e=[e,...t.map((e=>{return`${e.name}=${t=e.objOrArray,Array.isArray(t)?JSON.stringify(t.map((e=>a(e)))):a(t)}`;var t})),...n.map((e=>`${e.name}=${u(e.value)}`))].join(" "),s.write(i.Pii,e,r))}static set piiLogging(e){this._piiLogging=e}static get piiLogging(){return this._piiLogging}}function a(e){return delete(e=Object.assign({},e)).domains,c(e,"token"),c(e,"refresh_token"),c(e,"access_token"),c(e,"code"),c(e,"id_token"),JSON.stringify(e)}function c(e,t){e[t]&&(e[t]=u(e[t]))}function u(e){return!e||e.length<10?e:`${e.substr(0,3)}...${e.slice(-3)}`}t.Logger=s,s.channel=r.window.createOutputChannel(o.extensionName),s._piiLogging=!1,s.config=r.workspace.getConfiguration("azure")},2259:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TenantIgnoredError=void 0;class n extends Error{}t.TenantIgnoredError=n},3311:e=>{"use strict";e.exports=require("@azure/arm-resourcegraph")},5549:e=>{"use strict";e.exports=require("@azure/arm-subscriptions")},5672:e=>{"use strict";e.exports=require("@azure/msal-node")},7583:e=>{"use strict";e.exports=require("@azure/storage-blob")},4597:e=>{"use strict";e.exports=require("applicationinsights-native-metrics")},235:e=>{"use strict";e.exports=require("azdata")},1962:e=>{"use strict";e.exports=require("bufferutil")},6809:e=>{"use strict";e.exports=require("utf-8-validate")},1398:e=>{"use strict";e.exports=require("vscode")},2613:e=>{"use strict";e.exports=require("assert")},290:e=>{"use strict";e.exports=require("async_hooks")},5317:e=>{"use strict";e.exports=require("child_process")},4236:e=>{"use strict";e.exports=require("console")},9140:e=>{"use strict";e.exports=require("constants")},6982:e=>{"use strict";e.exports=require("crypto")},2250:e=>{"use strict";e.exports=require("dns")},4434:e=>{"use strict";e.exports=require("events")},9896:e=>{"use strict";e.exports=require("fs")},8611:e=>{"use strict";e.exports=require("http")},5692:e=>{"use strict";e.exports=require("https")},3339:e=>{"use strict";e.exports=require("module")},9278:e=>{"use strict";e.exports=require("net")},857:e=>{"use strict";e.exports=require("os")},6928:e=>{"use strict";e.exports=require("path")},2987:e=>{"use strict";e.exports=require("perf_hooks")},2203:e=>{"use strict";e.exports=require("stream")},3193:e=>{"use strict";e.exports=require("string_decoder")},3557:e=>{"use strict";e.exports=require("timers")},4756:e=>{"use strict";e.exports=require("tls")},2018:e=>{"use strict";e.exports=require("tty")},7016:e=>{"use strict";e.exports=require("url")},9023:e=>{"use strict";e.exports=require("util")},3106:e=>{"use strict";e.exports=require("zlib")},9329:(e,t,n)=>{"use strict";const r=n(737),o=n(7016),i=n(6504),s=n(8611),a=n(5692),c=n(9023),u=n(3164),l=n(3106),p=n(2203),d=n(4434);function h(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}const f=h(r),m=h(o),v=h(s),g=h(a),y=h(c),_=h(u),b=h(l),E=h(p);function T(e,t){return function(){return e.apply(t,arguments)}}const{toString:S}=Object.prototype,{getPrototypeOf:C}=Object,x=(w=Object.create(null),e=>{const t=S.call(e);return w[t]||(w[t]=t.slice(8,-1).toLowerCase())});var w;const A=e=>(e=e.toLowerCase(),t=>x(t)===e),I=e=>t=>typeof t===e,{isArray:R}=Array,P=I("undefined"),O=A("ArrayBuffer"),N=I("string"),k=I("function"),D=I("number"),M=e=>null!==e&&"object"==typeof e,L=e=>{if("object"!==x(e))return!1;const t=C(e);return!(null!==t&&t!==Object.prototype&&null!==Object.getPrototypeOf(t)||Symbol.toStringTag in e||Symbol.iterator in e)},j=A("Date"),U=A("File"),F=A("Blob"),z=A("FileList"),q=A("URLSearchParams"),[B,H,G,V]=["ReadableStream","Request","Response","Headers"].map(A);function $(e,t,{allOwnKeys:n=!1}={}){if(null==e)return;let r,o;if("object"!=typeof e&&(e=[e]),R(e))for(r=0,o=e.length;r<o;r++)t.call(null,e[r],r,e);else{const o=n?Object.getOwnPropertyNames(e):Object.keys(e),i=o.length;let s;for(r=0;r<i;r++)s=o[r],t.call(null,e[s],s,e)}}function K(e,t){t=t.toLowerCase();const n=Object.keys(e);let r,o=n.length;for(;o-- >0;)if(r=n[o],t===r.toLowerCase())return r;return null}const W="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:global,Q=e=>!P(e)&&e!==W,Y=(X="undefined"!=typeof Uint8Array&&C(Uint8Array),e=>X&&e instanceof X);var X;const J=A("HTMLFormElement"),Z=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),ee=A("RegExp"),te=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};$(n,((n,o)=>{let i;!1!==(i=t(n,o,e))&&(r[o]=i||n)})),Object.defineProperties(e,r)},ne="abcdefghijklmnopqrstuvwxyz",re="0123456789",oe={DIGIT:re,ALPHA:ne,ALPHA_DIGIT:ne+ne.toUpperCase()+re},ie=A("AsyncFunction"),se=(ae="function"==typeof setImmediate,ce=k(W.postMessage),ae?setImmediate:ce?(ue=`axios@${Math.random()}`,le=[],W.addEventListener("message",(({source:e,data:t})=>{e===W&&t===ue&&le.length&&le.shift()()}),!1),e=>{le.push(e),W.postMessage(ue,"*")}):e=>setTimeout(e));var ae,ce,ue,le;const pe="undefined"!=typeof queueMicrotask?queueMicrotask.bind(W):"undefined"!=typeof process&&process.nextTick||se,de={isArray:R,isArrayBuffer:O,isBuffer:function(e){return null!==e&&!P(e)&&null!==e.constructor&&!P(e.constructor)&&k(e.constructor.isBuffer)&&e.constructor.isBuffer(e)},isFormData:e=>{let t;return e&&("function"==typeof FormData&&e instanceof FormData||k(e.append)&&("formdata"===(t=x(e))||"object"===t&&k(e.toString)&&"[object FormData]"===e.toString()))},isArrayBufferView:function(e){let t;return t="undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&O(e.buffer),t},isString:N,isNumber:D,isBoolean:e=>!0===e||!1===e,isObject:M,isPlainObject:L,isReadableStream:B,isRequest:H,isResponse:G,isHeaders:V,isUndefined:P,isDate:j,isFile:U,isBlob:F,isRegExp:ee,isFunction:k,isStream:e=>M(e)&&k(e.pipe),isURLSearchParams:q,isTypedArray:Y,isFileList:z,forEach:$,merge:function e(){const{caseless:t}=Q(this)&&this||{},n={},r=(r,o)=>{const i=t&&K(n,o)||o;L(n[i])&&L(r)?n[i]=e(n[i],r):L(r)?n[i]=e({},r):R(r)?n[i]=r.slice():n[i]=r};for(let e=0,t=arguments.length;e<t;e++)arguments[e]&&$(arguments[e],r);return n},extend:(e,t,n,{allOwnKeys:r}={})=>($(t,((t,r)=>{n&&k(t)?e[r]=T(t,n):e[r]=t}),{allOwnKeys:r}),e),trim:e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,""),stripBOM:e=>(65279===e.charCodeAt(0)&&(e=e.slice(1)),e),inherits:(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},toFlatObject:(e,t,n,r)=>{let o,i,s;const a={};if(t=t||{},null==e)return t;do{for(o=Object.getOwnPropertyNames(e),i=o.length;i-- >0;)s=o[i],r&&!r(s,e,t)||a[s]||(t[s]=e[s],a[s]=!0);e=!1!==n&&C(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},kindOf:x,kindOfTest:A,endsWith:(e,t,n)=>{e=String(e),(void 0===n||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return-1!==r&&r===n},toArray:e=>{if(!e)return null;if(R(e))return e;let t=e.length;if(!D(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},forEachEntry:(e,t)=>{const n=(e&&e[Symbol.iterator]).call(e);let r;for(;(r=n.next())&&!r.done;){const n=r.value;t.call(e,n[0],n[1])}},matchAll:(e,t)=>{let n;const r=[];for(;null!==(n=e.exec(t));)r.push(n);return r},isHTMLForm:J,hasOwnProperty:Z,hasOwnProp:Z,reduceDescriptors:te,freezeMethods:e=>{te(e,((t,n)=>{if(k(e)&&-1!==["arguments","caller","callee"].indexOf(n))return!1;const r=e[n];k(r)&&(t.enumerable=!1,"writable"in t?t.writable=!1:t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")}))}))},toObjectSet:(e,t)=>{const n={},r=e=>{e.forEach((e=>{n[e]=!0}))};return R(e)?r(e):r(String(e).split(t)),n},toCamelCase:e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,(function(e,t,n){return t.toUpperCase()+n})),noop:()=>{},toFiniteNumber:(e,t)=>null!=e&&Number.isFinite(e=+e)?e:t,findKey:K,global:W,isContextDefined:Q,ALPHABET:oe,generateString:(e=16,t=oe.ALPHA_DIGIT)=>{let n="";const{length:r}=t;for(;e--;)n+=t[Math.random()*r|0];return n},isSpecCompliantForm:function(e){return!!(e&&k(e.append)&&"FormData"===e[Symbol.toStringTag]&&e[Symbol.iterator])},toJSONObject:e=>{const t=new Array(10),n=(e,r)=>{if(M(e)){if(t.indexOf(e)>=0)return;if(!("toJSON"in e)){t[r]=e;const o=R(e)?[]:{};return $(e,((e,t)=>{const i=n(e,r+1);!P(i)&&(o[t]=i)})),t[r]=void 0,o}}return e};return n(e,0)},isAsyncFn:ie,isThenable:e=>e&&(M(e)||k(e))&&k(e.then)&&k(e.catch),setImmediate:se,asap:pe};function he(e,t,n,r,o){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=(new Error).stack,this.message=e,this.name="AxiosError",t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),o&&(this.response=o)}de.inherits(he,Error,{toJSON:function(){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:de.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const fe=he.prototype,me={};function ve(e){return de.isPlainObject(e)||de.isArray(e)}function ge(e){return de.endsWith(e,"[]")?e.slice(0,-2):e}function ye(e,t,n){return e?e.concat(t).map((function(e,t){return e=ge(e),!n&&t?"["+e+"]":e})).join(n?".":""):t}["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach((e=>{me[e]={value:e}})),Object.defineProperties(he,me),Object.defineProperty(fe,"isAxiosError",{value:!0}),he.from=(e,t,n,r,o,i)=>{const s=Object.create(fe);return de.toFlatObject(e,s,(function(e){return e!==Error.prototype}),(e=>"isAxiosError"!==e)),he.call(s,e.message,t,n,r,o),s.cause=e,s.name=e.name,i&&Object.assign(s,i),s};const _e=de.toFlatObject(de,{},null,(function(e){return/^is[A-Z]/.test(e)}));function be(e,t,n){if(!de.isObject(e))throw new TypeError("target must be an object");t=t||new(f.default||FormData);const r=(n=de.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,(function(e,t){return!de.isUndefined(t[e])}))).metaTokens,o=n.visitor||u,i=n.dots,s=n.indexes,a=(n.Blob||"undefined"!=typeof Blob&&Blob)&&de.isSpecCompliantForm(t);if(!de.isFunction(o))throw new TypeError("visitor must be a function");function c(e){if(null===e)return"";if(de.isDate(e))return e.toISOString();if(!a&&de.isBlob(e))throw new he("Blob is not supported. Use a Buffer instead.");return de.isArrayBuffer(e)||de.isTypedArray(e)?a&&"function"==typeof Blob?new Blob([e]):Buffer.from(e):e}function u(e,n,o){let a=e;if(e&&!o&&"object"==typeof e)if(de.endsWith(n,"{}"))n=r?n:n.slice(0,-2),e=JSON.stringify(e);else if(de.isArray(e)&&function(e){return de.isArray(e)&&!e.some(ve)}(e)||(de.isFileList(e)||de.endsWith(n,"[]"))&&(a=de.toArray(e)))return n=ge(n),a.forEach((function(e,r){!de.isUndefined(e)&&null!==e&&t.append(!0===s?ye([n],r,i):null===s?n:n+"[]",c(e))})),!1;return!!ve(e)||(t.append(ye(o,n,i),c(e)),!1)}const l=[],p=Object.assign(_e,{defaultVisitor:u,convertValue:c,isVisitable:ve});if(!de.isObject(e))throw new TypeError("data must be an object");return function e(n,r){if(!de.isUndefined(n)){if(-1!==l.indexOf(n))throw Error("Circular reference detected in "+r.join("."));l.push(n),de.forEach(n,(function(n,i){!0===(!(de.isUndefined(n)||null===n)&&o.call(t,n,de.isString(i)?i.trim():i,r,p))&&e(n,r?r.concat(i):[i])})),l.pop()}}(e),t}function Ee(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,(function(e){return t[e]}))}function Te(e,t){this._pairs=[],e&&be(e,this,t)}const Se=Te.prototype;function Ce(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function xe(e,t,n){if(!t)return e;const r=n&&n.encode||Ce,o=n&&n.serialize;let i;if(i=o?o(t,n):de.isURLSearchParams(t)?t.toString():new Te(t,n).toString(r),i){const t=e.indexOf("#");-1!==t&&(e=e.slice(0,t)),e+=(-1===e.indexOf("?")?"?":"&")+i}return e}Se.append=function(e,t){this._pairs.push([e,t])},Se.toString=function(e){const t=e?function(t){return e.call(this,t,Ee)}:Ee;return this._pairs.map((function(e){return t(e[0])+"="+t(e[1])}),"").join("&")};const we=class{constructor(){this.handlers=[]}use(e,t,n){return this.handlers.push({fulfilled:e,rejected:t,synchronous:!!n&&n.synchronous,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){de.forEach(this.handlers,(function(t){null!==t&&e(t)}))}},Ae={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},Ie={isNode:!0,classes:{URLSearchParams:m.default.URLSearchParams,FormData:f.default,Blob:"undefined"!=typeof Blob&&Blob||null},protocols:["http","https","file","data"]},Re="undefined"!=typeof window&&"undefined"!=typeof document,Pe=(Oe="undefined"!=typeof navigator&&navigator.product,Re&&["ReactNative","NativeScript","NS"].indexOf(Oe)<0);var Oe;const Ne="undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&"function"==typeof self.importScripts,ke=Re&&window.location.href||"http://localhost",De={...Object.freeze({__proto__:null,hasBrowserEnv:Re,hasStandardBrowserWebWorkerEnv:Ne,hasStandardBrowserEnv:Pe,origin:ke}),...Ie};function Me(e){function t(e,n,r,o){let i=e[o++];if("__proto__"===i)return!0;const s=Number.isFinite(+i),a=o>=e.length;return i=!i&&de.isArray(r)?r.length:i,a?(de.hasOwnProp(r,i)?r[i]=[r[i],n]:r[i]=n,!s):(r[i]&&de.isObject(r[i])||(r[i]=[]),t(e,n,r[i],o)&&de.isArray(r[i])&&(r[i]=function(e){const t={},n=Object.keys(e);let r;const o=n.length;let i;for(r=0;r<o;r++)i=n[r],t[i]=e[i];return t}(r[i])),!s)}if(de.isFormData(e)&&de.isFunction(e.entries)){const n={};return de.forEachEntry(e,((e,r)=>{t(function(e){return de.matchAll(/\w+|\[(\w*)]/g,e).map((e=>"[]"===e[0]?"":e[1]||e[0]))}(e),r,n,0)})),n}return null}const Le={transitional:Ae,adapter:["xhr","http","fetch"],transformRequest:[function(e,t){const n=t.getContentType()||"",r=n.indexOf("application/json")>-1,o=de.isObject(e);if(o&&de.isHTMLForm(e)&&(e=new FormData(e)),de.isFormData(e))return r?JSON.stringify(Me(e)):e;if(de.isArrayBuffer(e)||de.isBuffer(e)||de.isStream(e)||de.isFile(e)||de.isBlob(e)||de.isReadableStream(e))return e;if(de.isArrayBufferView(e))return e.buffer;if(de.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let i;if(o){if(n.indexOf("application/x-www-form-urlencoded")>-1)return function(e,t){return be(e,new De.classes.URLSearchParams,Object.assign({visitor:function(e,t,n,r){return De.isNode&&de.isBuffer(e)?(this.append(t,e.toString("base64")),!1):r.defaultVisitor.apply(this,arguments)}},t))}(e,this.formSerializer).toString();if((i=de.isFileList(e))||n.indexOf("multipart/form-data")>-1){const t=this.env&&this.env.FormData;return be(i?{"files[]":e}:e,t&&new t,this.formSerializer)}}return o||r?(t.setContentType("application/json",!1),function(e){if(de.isString(e))try{return(0,JSON.parse)(e),de.trim(e)}catch(e){if("SyntaxError"!==e.name)throw e}return(0,JSON.stringify)(e)}(e)):e}],transformResponse:[function(e){const t=this.transitional||Le.transitional,n=t&&t.forcedJSONParsing,r="json"===this.responseType;if(de.isResponse(e)||de.isReadableStream(e))return e;if(e&&de.isString(e)&&(n&&!this.responseType||r)){const n=!(t&&t.silentJSONParsing)&&r;try{return JSON.parse(e)}catch(e){if(n){if("SyntaxError"===e.name)throw he.from(e,he.ERR_BAD_RESPONSE,this,null,this.response);throw e}}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:De.classes.FormData,Blob:De.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};de.forEach(["delete","get","head","post","put","patch"],(e=>{Le.headers[e]={}}));const je=Le,Ue=de.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"]),Fe=Symbol("internals");function ze(e){return e&&String(e).trim().toLowerCase()}function qe(e){return!1===e||null==e?e:de.isArray(e)?e.map(qe):String(e)}function Be(e,t,n,r,o){return de.isFunction(r)?r.call(this,t,n):(o&&(t=n),de.isString(t)?de.isString(r)?-1!==t.indexOf(r):de.isRegExp(r)?r.test(t):void 0:void 0)}class He{constructor(e){e&&this.set(e)}set(e,t,n){const r=this;function o(e,t,n){const o=ze(t);if(!o)throw new Error("header name must be a non-empty string");const i=de.findKey(r,o);(!i||void 0===r[i]||!0===n||void 0===n&&!1!==r[i])&&(r[i||t]=qe(e))}const i=(e,t)=>de.forEach(e,((e,n)=>o(e,n,t)));if(de.isPlainObject(e)||e instanceof this.constructor)i(e,t);else if(de.isString(e)&&(e=e.trim())&&!/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim()))i((e=>{const t={};let n,r,o;return e&&e.split("\n").forEach((function(e){o=e.indexOf(":"),n=e.substring(0,o).trim().toLowerCase(),r=e.substring(o+1).trim(),!n||t[n]&&Ue[n]||("set-cookie"===n?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)})),t})(e),t);else if(de.isHeaders(e))for(const[t,r]of e.entries())o(r,t,n);else null!=e&&o(t,e,n);return this}get(e,t){if(e=ze(e)){const n=de.findKey(this,e);if(n){const e=this[n];if(!t)return e;if(!0===t)return function(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}(e);if(de.isFunction(t))return t.call(this,e,n);if(de.isRegExp(t))return t.exec(e);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,t){if(e=ze(e)){const n=de.findKey(this,e);return!(!n||void 0===this[n]||t&&!Be(0,this[n],n,t))}return!1}delete(e,t){const n=this;let r=!1;function o(e){if(e=ze(e)){const o=de.findKey(n,e);!o||t&&!Be(0,n[o],o,t)||(delete n[o],r=!0)}}return de.isArray(e)?e.forEach(o):o(e),r}clear(e){const t=Object.keys(this);let n=t.length,r=!1;for(;n--;){const o=t[n];e&&!Be(0,this[o],o,e,!0)||(delete this[o],r=!0)}return r}normalize(e){const t=this,n={};return de.forEach(this,((r,o)=>{const i=de.findKey(n,o);if(i)return t[i]=qe(r),void delete t[o];const s=e?function(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,((e,t,n)=>t.toUpperCase()+n))}(o):String(o).trim();s!==o&&delete t[o],t[s]=qe(r),n[s]=!0})),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const t=Object.create(null);return de.forEach(this,((n,r)=>{null!=n&&!1!==n&&(t[r]=e&&de.isArray(n)?n.join(", "):n)})),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map((([e,t])=>e+": "+t)).join("\n")}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...t){const n=new this(e);return t.forEach((e=>n.set(e))),n}static accessor(e){const t=(this[Fe]=this[Fe]={accessors:{}}).accessors,n=this.prototype;function r(e){const r=ze(e);t[r]||(function(e,t){const n=de.toCamelCase(" "+t);["get","set","has"].forEach((r=>{Object.defineProperty(e,r+n,{value:function(e,n,o){return this[r].call(this,t,e,n,o)},configurable:!0})}))}(n,e),t[r]=!0)}return de.isArray(e)?e.forEach(r):r(e),this}}He.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),de.reduceDescriptors(He.prototype,(({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(e){this[n]=e}}})),de.freezeMethods(He);const Ge=He;function Ve(e,t){const n=this||je,r=t||n,o=Ge.from(r.headers);let i=r.data;return de.forEach(e,(function(e){i=e.call(n,i,o.normalize(),t?t.status:void 0)})),o.normalize(),i}function $e(e){return!(!e||!e.__CANCEL__)}function Ke(e,t,n){he.call(this,null==e?"canceled":e,he.ERR_CANCELED,t,n),this.name="CanceledError"}function We(e,t,n){const r=n.config.validateStatus;n.status&&r&&!r(n.status)?t(new he("Request failed with status code "+n.status,[he.ERR_BAD_REQUEST,he.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n)):e(n)}function Qe(e,t){return e&&!function(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}(t)?function(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}(e,t):t}de.inherits(Ke,he,{__CANCEL__:!0});const Ye="1.7.4";function Xe(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}const Je=/^(?:([^;]+);)?(?:[^;]+;)?(base64|),([\s\S]*)$/,Ze=Symbol("internals");class et extends E.default.Transform{constructor(e){super({readableHighWaterMark:(e=de.toFlatObject(e,{maxRate:0,chunkSize:65536,minChunkSize:100,timeWindow:500,ticksRate:2,samplesCount:15},null,((e,t)=>!de.isUndefined(t[e])))).chunkSize});const t=this[Ze]={timeWindow:e.timeWindow,chunkSize:e.chunkSize,maxRate:e.maxRate,minChunkSize:e.minChunkSize,bytesSeen:0,isCaptured:!1,notifiedBytesLoaded:0,ts:Date.now(),bytes:0,onReadCallback:null};this.on("newListener",(e=>{"progress"===e&&(t.isCaptured||(t.isCaptured=!0))}))}_read(e){const t=this[Ze];return t.onReadCallback&&t.onReadCallback(),super._read(e)}_transform(e,t,n){const r=this[Ze],o=r.maxRate,i=this.readableHighWaterMark,s=r.timeWindow,a=o/(1e3/s),c=!1!==r.minChunkSize?Math.max(r.minChunkSize,.01*a):0,u=(e,t)=>{const n=Buffer.byteLength(e);r.bytesSeen+=n,r.bytes+=n,r.isCaptured&&this.emit("progress",r.bytesSeen),this.push(e)?process.nextTick(t):r.onReadCallback=()=>{r.onReadCallback=null,process.nextTick(t)}},l=(e,t)=>{const n=Buffer.byteLength(e);let l,p=null,d=i,h=0;if(o){const e=Date.now();(!r.ts||(h=e-r.ts)>=s)&&(r.ts=e,l=a-r.bytes,r.bytes=l<0?-l:0,h=0),l=a-r.bytes}if(o){if(l<=0)return setTimeout((()=>{t(null,e)}),s-h);l<d&&(d=l)}d&&n>d&&n-d>c&&(p=e.subarray(d),e=e.subarray(0,d)),u(e,p?()=>{process.nextTick(t,null,p)}:t)};l(e,(function e(t,r){if(t)return n(t);r?l(r,e):n(null)}))}}const tt=et,{asyncIterator:nt}=Symbol,rt=async function*(e){e.stream?yield*e.stream():e.arrayBuffer?yield await e.arrayBuffer():e[nt]?yield*e[nt]():yield e},ot=de.ALPHABET.ALPHA_DIGIT+"-_",it=new c.TextEncoder,st="\r\n",at=it.encode(st);class ct{constructor(e,t){const{escapeName:n}=this.constructor,r=de.isString(t);let o=`Content-Disposition: form-data; name="${n(e)}"${!r&&t.name?`; filename="${n(t.name)}"`:""}${st}`;r?t=it.encode(String(t).replace(/\r?\n|\r\n?/g,st)):o+=`Content-Type: ${t.type||"application/octet-stream"}${st}`,this.headers=it.encode(o+st),this.contentLength=r?t.byteLength:t.size,this.size=this.headers.byteLength+this.contentLength+2,this.name=e,this.value=t}async*encode(){yield this.headers;const{value:e}=this;de.isTypedArray(e)?yield e:yield*rt(e),yield at}static escapeName(e){return String(e).replace(/[\r\n"]/g,(e=>({"\r":"%0D","\n":"%0A",'"':"%22"}[e])))}}class ut extends E.default.Transform{__transform(e,t,n){this.push(e),n()}_transform(e,t,n){if(0!==e.length&&(this._transform=this.__transform,120!==e[0])){const e=Buffer.alloc(2);e[0]=120,e[1]=156,this.push(e,t)}this.__transform(e,t,n)}}const lt=ut,pt=(e,t)=>de.isAsyncFn(e)?function(...n){const r=n.pop();e.apply(this,n).then((e=>{try{t?r(null,...t(e)):r(null,e)}catch(e){r(e)}}),r)}:e,dt=(e,t,n=3)=>{let r=0;const o=function(e,t){e=e||10;const n=new Array(e),r=new Array(e);let o,i=0,s=0;return t=void 0!==t?t:1e3,function(a){const c=Date.now(),u=r[s];o||(o=c),n[i]=a,r[i]=c;let l=s,p=0;for(;l!==i;)p+=n[l++],l%=e;if(i=(i+1)%e,i===s&&(s=(s+1)%e),c-o<t)return;const d=u&&c-u;return d?Math.round(1e3*p/d):void 0}}(50,250);return function(e,t){let n,r,o=0,i=1e3/t;const s=(t,i=Date.now())=>{o=i,n=null,r&&(clearTimeout(r),r=null),e.apply(null,t)};return[(...e)=>{const t=Date.now(),a=t-o;a>=i?s(e,t):(n=e,r||(r=setTimeout((()=>{r=null,s(n)}),i-a)))},()=>n&&s(n)]}((n=>{const i=n.loaded,s=n.lengthComputable?n.total:void 0,a=i-r,c=o(a);r=i,e({loaded:i,total:s,progress:s?i/s:void 0,bytes:a,rate:c||void 0,estimated:c&&s&&i<=s?(s-i)/c:void 0,event:n,lengthComputable:null!=s,[t?"download":"upload"]:!0})}),n)},ht=(e,t)=>{const n=null!=e;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},ft=e=>(...t)=>de.asap((()=>e(...t))),mt={flush:b.default.constants.Z_SYNC_FLUSH,finishFlush:b.default.constants.Z_SYNC_FLUSH},vt={flush:b.default.constants.BROTLI_OPERATION_FLUSH,finishFlush:b.default.constants.BROTLI_OPERATION_FLUSH},gt=de.isFunction(b.default.createBrotliDecompress),{http:yt,https:_t}=_.default,bt=/https:?/,Et=De.protocols.map((e=>e+":")),Tt=(e,[t,n])=>(e.on("end",n).on("error",n),t);function St(e,t){e.beforeRedirects.proxy&&e.beforeRedirects.proxy(e),e.beforeRedirects.config&&e.beforeRedirects.config(e,t)}function Ct(e,t,n){let r=t;if(!r&&!1!==r){const e=i.getProxyForUrl(n);e&&(r=new URL(e))}if(r){if(r.username&&(r.auth=(r.username||"")+":"+(r.password||"")),r.auth){(r.auth.username||r.auth.password)&&(r.auth=(r.auth.username||"")+":"+(r.auth.password||""));const t=Buffer.from(r.auth,"utf8").toString("base64");e.headers["Proxy-Authorization"]="Basic "+t}e.headers.host=e.hostname+(e.port?":"+e.port:"");const t=r.hostname||r.host;e.hostname=t,e.host=t,e.port=r.port,e.path=n,r.protocol&&(e.protocol=r.protocol.includes(":")?r.protocol:`${r.protocol}:`)}e.beforeRedirects.proxy=function(e){Ct(e,t,e.href)}}const xt="undefined"!=typeof process&&"process"===de.kindOf(process),wt=(e,t)=>(({address:e,family:t})=>{if(!de.isString(e))throw TypeError("address must be a string");return{address:e,family:t||(e.indexOf(".")<0?6:4)}})(de.isObject(e)?e:{address:e,family:t}),At=xt&&function(e){return t=async function(t,n,r){let{data:o,lookup:i,family:s}=e;const{responseType:a,responseEncoding:c}=e,u=e.method.toUpperCase();let l,h,f=!1;if(i){const e=pt(i,(e=>de.isArray(e)?e:[e]));i=(t,n,r)=>{e(t,n,((e,t,o)=>{if(e)return r(e);const i=de.isArray(t)?t.map((e=>wt(e))):[wt(t,o)];n.all?r(e,i):r(e,i[0].address,i[0].family)}))}}const m=new d.EventEmitter,_=()=>{e.cancelToken&&e.cancelToken.unsubscribe(T),e.signal&&e.signal.removeEventListener("abort",T),m.removeAllListeners()};function T(t){m.emit("abort",!t||t.type?new Ke(null,e,h):t)}r(((e,t)=>{l=!0,t&&(f=!0,_())})),m.once("abort",n),(e.cancelToken||e.signal)&&(e.cancelToken&&e.cancelToken.subscribe(T),e.signal&&(e.signal.aborted?T():e.signal.addEventListener("abort",T)));const S=Qe(e.baseURL,e.url),C=new URL(S,de.hasBrowserEnv?De.origin:void 0),x=C.protocol||Et[0];if("data:"===x){let r;if("GET"!==u)return We(t,n,{status:405,statusText:"method not allowed",headers:{},config:e});try{r=function(e,t,n){const r=n&&n.Blob||De.classes.Blob,o=Xe(e);if(void 0===t&&r&&(t=!0),"data"===o){e=o.length?e.slice(o.length+1):e;const n=Je.exec(e);if(!n)throw new he("Invalid URL",he.ERR_INVALID_URL);const i=n[1],s=n[2],a=n[3],c=Buffer.from(decodeURIComponent(a),s?"base64":"utf8");if(t){if(!r)throw new he("Blob is not supported",he.ERR_NOT_SUPPORT);return new r([c],{type:i})}return c}throw new he("Unsupported protocol "+o,he.ERR_NOT_SUPPORT)}(e.url,"blob"===a,{Blob:e.env&&e.env.Blob})}catch(t){throw he.from(t,he.ERR_BAD_REQUEST,e)}return"text"===a?(r=r.toString(c),c&&"utf8"!==c||(r=de.stripBOM(r))):"stream"===a&&(r=E.default.Readable.from(r)),We(t,n,{data:r,status:200,statusText:"OK",headers:new Ge,config:e})}if(-1===Et.indexOf(x))return n(new he("Unsupported protocol "+x,he.ERR_BAD_REQUEST,e));const w=Ge.from(e.headers).normalize();w.set("User-Agent","axios/"+Ye,!1);const{onUploadProgress:A,onDownloadProgress:I}=e,R=e.maxRate;let P,O;if(de.isSpecCompliantForm(o)){const e=w.getContentType(/boundary=([-_\w\d]{10,70})/i);o=((e,t,n)=>{const{tag:r="form-data-boundary",size:o=25,boundary:i=r+"-"+de.generateString(o,ot)}=n||{};if(!de.isFormData(e))throw TypeError("FormData instance required");if(i.length<1||i.length>70)throw Error("boundary must be 10-70 characters long");const s=it.encode("--"+i+st),a=it.encode("--"+i+"--"+st+st);let c=a.byteLength;const u=Array.from(e.entries()).map((([e,t])=>{const n=new ct(e,t);return c+=n.size,n}));c+=s.byteLength*u.length,c=de.toFiniteNumber(c);const l={"Content-Type":`multipart/form-data; boundary=${i}`};return Number.isFinite(c)&&(l["Content-Length"]=c),t&&t(l),p.Readable.from(async function*(){for(const e of u)yield s,yield*e.encode();yield a}())})(o,(e=>{w.set(e)}),{tag:`axios-${Ye}-boundary`,boundary:e&&e[1]||void 0})}else if(de.isFormData(o)&&de.isFunction(o.getHeaders)){if(w.set(o.getHeaders()),!w.hasContentLength())try{const e=await y.default.promisify(o.getLength).call(o);Number.isFinite(e)&&e>=0&&w.setContentLength(e)}catch(e){}}else if(de.isBlob(o))o.size&&w.setContentType(o.type||"application/octet-stream"),w.setContentLength(o.size||0),o=E.default.Readable.from(rt(o));else if(o&&!de.isStream(o)){if(Buffer.isBuffer(o));else if(de.isArrayBuffer(o))o=Buffer.from(new Uint8Array(o));else{if(!de.isString(o))return n(new he("Data after transformation must be a string, an ArrayBuffer, a Buffer, or a Stream",he.ERR_BAD_REQUEST,e));o=Buffer.from(o,"utf-8")}if(w.setContentLength(o.length,!1),e.maxBodyLength>-1&&o.length>e.maxBodyLength)return n(new he("Request body larger than maxBodyLength limit",he.ERR_BAD_REQUEST,e))}const N=de.toFiniteNumber(w.getContentLength());let k,D;de.isArray(R)?(P=R[0],O=R[1]):P=O=R,o&&(A||P)&&(de.isStream(o)||(o=E.default.Readable.from(o,{objectMode:!1})),o=E.default.pipeline([o,new tt({maxRate:de.toFiniteNumber(P)})],de.noop),A&&o.on("progress",Tt(o,ht(N,dt(ft(A),!1,3))))),e.auth&&(k=(e.auth.username||"")+":"+(e.auth.password||"")),!k&&C.username&&(k=C.username+":"+C.password),k&&w.delete("authorization");try{D=xe(C.pathname+C.search,e.params,e.paramsSerializer).replace(/^\?/,"")}catch(t){const r=new Error(t.message);return r.config=e,r.url=e.url,r.exists=!0,n(r)}w.set("Accept-Encoding","gzip, compress, deflate"+(gt?", br":""),!1);const M={path:D,method:u,headers:w.toJSON(),agents:{http:e.httpAgent,https:e.httpsAgent},auth:k,protocol:x,family:s,beforeRedirect:St,beforeRedirects:{}};let L;!de.isUndefined(i)&&(M.lookup=i),e.socketPath?M.socketPath=e.socketPath:(M.hostname=C.hostname,M.port=C.port,Ct(M,e.proxy,x+"//"+C.hostname+(C.port?":"+C.port:"")+M.path));const j=bt.test(M.protocol);if(M.agent=j?e.httpsAgent:e.httpAgent,e.transport?L=e.transport:0===e.maxRedirects?L=j?g.default:v.default:(e.maxRedirects&&(M.maxRedirects=e.maxRedirects),e.beforeRedirect&&(M.beforeRedirects.config=e.beforeRedirect),L=j?_t:yt),e.maxBodyLength>-1?M.maxBodyLength=e.maxBodyLength:M.maxBodyLength=1/0,e.insecureHTTPParser&&(M.insecureHTTPParser=e.insecureHTTPParser),h=L.request(M,(function(r){if(h.destroyed)return;const o=[r],i=+r.headers["content-length"];if(I||O){const e=new tt({maxRate:de.toFiniteNumber(O)});I&&e.on("progress",Tt(e,ht(i,dt(ft(I),!0,3)))),o.push(e)}let s=r;const l=r.req||h;if(!1!==e.decompress&&r.headers["content-encoding"])switch("HEAD"!==u&&204!==r.statusCode||delete r.headers["content-encoding"],(r.headers["content-encoding"]||"").toLowerCase()){case"gzip":case"x-gzip":case"compress":case"x-compress":o.push(b.default.createUnzip(mt)),delete r.headers["content-encoding"];break;case"deflate":o.push(new lt),o.push(b.default.createUnzip(mt)),delete r.headers["content-encoding"];break;case"br":gt&&(o.push(b.default.createBrotliDecompress(vt)),delete r.headers["content-encoding"])}s=o.length>1?E.default.pipeline(o,de.noop):o[0];const p=E.default.finished(s,(()=>{p(),_()})),d={status:r.statusCode,statusText:r.statusMessage,headers:new Ge(r.headers),config:e,request:l};if("stream"===a)d.data=s,We(t,n,d);else{const r=[];let o=0;s.on("data",(function(t){r.push(t),o+=t.length,e.maxContentLength>-1&&o>e.maxContentLength&&(f=!0,s.destroy(),n(new he("maxContentLength size of "+e.maxContentLength+" exceeded",he.ERR_BAD_RESPONSE,e,l)))})),s.on("aborted",(function(){if(f)return;const t=new he("maxContentLength size of "+e.maxContentLength+" exceeded",he.ERR_BAD_RESPONSE,e,l);s.destroy(t),n(t)})),s.on("error",(function(t){h.destroyed||n(he.from(t,null,e,l))})),s.on("end",(function(){try{let e=1===r.length?r[0]:Buffer.concat(r);"arraybuffer"!==a&&(e=e.toString(c),c&&"utf8"!==c||(e=de.stripBOM(e))),d.data=e}catch(t){return n(he.from(t,null,e,d.request,d))}We(t,n,d)}))}m.once("abort",(e=>{s.destroyed||(s.emit("error",e),s.destroy())}))})),m.once("abort",(e=>{n(e),h.destroy(e)})),h.on("error",(function(t){n(he.from(t,null,e,h))})),h.on("socket",(function(e){e.setKeepAlive(!0,6e4)})),e.timeout){const t=parseInt(e.timeout,10);if(Number.isNaN(t))return void n(new he("error trying to parse `config.timeout` to int",he.ERR_BAD_OPTION_VALUE,e,h));h.setTimeout(t,(function(){if(l)return;let t=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded";const r=e.transitional||Ae;e.timeoutErrorMessage&&(t=e.timeoutErrorMessage),n(new he(t,r.clarifyTimeoutError?he.ETIMEDOUT:he.ECONNABORTED,e,h)),T()}))}if(de.isStream(o)){let t=!1,n=!1;o.on("end",(()=>{t=!0})),o.once("error",(e=>{n=!0,h.destroy(e)})),o.on("close",(()=>{t||n||T(new Ke("Request stream has been aborted",e,h))})),o.pipe(h)}else h.end(o)},new Promise(((e,n)=>{let r,o;const i=(e,t)=>{o||(o=!0,r&&r(e,t))},s=e=>{i(e,!0),n(e)};t((t=>{i(t),e(t)}),s,(e=>r=e)).catch(s)}));var t},It=De.hasStandardBrowserEnv?function(){const e=/(msie|trident)/i.test(navigator.userAgent),t=document.createElement("a");let n;function r(n){let r=n;return e&&(t.setAttribute("href",r),r=t.href),t.setAttribute("href",r),{href:t.href,protocol:t.protocol?t.protocol.replace(/:$/,""):"",host:t.host,search:t.search?t.search.replace(/^\?/,""):"",hash:t.hash?t.hash.replace(/^#/,""):"",hostname:t.hostname,port:t.port,pathname:"/"===t.pathname.charAt(0)?t.pathname:"/"+t.pathname}}return n=r(window.location.href),function(e){const t=de.isString(e)?r(e):e;return t.protocol===n.protocol&&t.host===n.host}}():function(){return!0},Rt=De.hasStandardBrowserEnv?{write(e,t,n,r,o,i){const s=[e+"="+encodeURIComponent(t)];de.isNumber(n)&&s.push("expires="+new Date(n).toGMTString()),de.isString(r)&&s.push("path="+r),de.isString(o)&&s.push("domain="+o),!0===i&&s.push("secure"),document.cookie=s.join("; ")},read(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read:()=>null,remove(){}},Pt=e=>e instanceof Ge?{...e}:e;function Ot(e,t){t=t||{};const n={};function r(e,t,n){return de.isPlainObject(e)&&de.isPlainObject(t)?de.merge.call({caseless:n},e,t):de.isPlainObject(t)?de.merge({},t):de.isArray(t)?t.slice():t}function o(e,t,n){return de.isUndefined(t)?de.isUndefined(e)?void 0:r(void 0,e,n):r(e,t,n)}function i(e,t){if(!de.isUndefined(t))return r(void 0,t)}function s(e,t){return de.isUndefined(t)?de.isUndefined(e)?void 0:r(void 0,e):r(void 0,t)}function a(n,o,i){return i in t?r(n,o):i in e?r(void 0,n):void 0}const c={url:i,method:i,data:i,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,withXSRFToken:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,beforeRedirect:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,responseEncoding:s,validateStatus:a,headers:(e,t)=>o(Pt(e),Pt(t),!0)};return de.forEach(Object.keys(Object.assign({},e,t)),(function(r){const i=c[r]||o,s=i(e[r],t[r],r);de.isUndefined(s)&&i!==a||(n[r]=s)})),n}const Nt=e=>{const t=Ot({},e);let n,{data:r,withXSRFToken:o,xsrfHeaderName:i,xsrfCookieName:s,headers:a,auth:c}=t;if(t.headers=a=Ge.from(a),t.url=xe(Qe(t.baseURL,t.url),e.params,e.paramsSerializer),c&&a.set("Authorization","Basic "+btoa((c.username||"")+":"+(c.password?unescape(encodeURIComponent(c.password)):""))),de.isFormData(r))if(De.hasStandardBrowserEnv||De.hasStandardBrowserWebWorkerEnv)a.setContentType(void 0);else if(!1!==(n=a.getContentType())){const[e,...t]=n?n.split(";").map((e=>e.trim())).filter(Boolean):[];a.setContentType([e||"multipart/form-data",...t].join("; "))}if(De.hasStandardBrowserEnv&&(o&&de.isFunction(o)&&(o=o(t)),o||!1!==o&&It(t.url))){const e=i&&s&&Rt.read(s);e&&a.set(i,e)}return t},kt="undefined"!=typeof XMLHttpRequest&&function(e){return new Promise((function(t,n){const r=Nt(e);let o=r.data;const i=Ge.from(r.headers).normalize();let s,a,c,u,l,{responseType:p,onUploadProgress:d,onDownloadProgress:h}=r;function f(){u&&u(),l&&l(),r.cancelToken&&r.cancelToken.unsubscribe(s),r.signal&&r.signal.removeEventListener("abort",s)}let m=new XMLHttpRequest;function v(){if(!m)return;const r=Ge.from("getAllResponseHeaders"in m&&m.getAllResponseHeaders());We((function(e){t(e),f()}),(function(e){n(e),f()}),{data:p&&"text"!==p&&"json"!==p?m.response:m.responseText,status:m.status,statusText:m.statusText,headers:r,config:e,request:m}),m=null}m.open(r.method.toUpperCase(),r.url,!0),m.timeout=r.timeout,"onloadend"in m?m.onloadend=v:m.onreadystatechange=function(){m&&4===m.readyState&&(0!==m.status||m.responseURL&&0===m.responseURL.indexOf("file:"))&&setTimeout(v)},m.onabort=function(){m&&(n(new he("Request aborted",he.ECONNABORTED,e,m)),m=null)},m.onerror=function(){n(new he("Network Error",he.ERR_NETWORK,e,m)),m=null},m.ontimeout=function(){let t=r.timeout?"timeout of "+r.timeout+"ms exceeded":"timeout exceeded";const o=r.transitional||Ae;r.timeoutErrorMessage&&(t=r.timeoutErrorMessage),n(new he(t,o.clarifyTimeoutError?he.ETIMEDOUT:he.ECONNABORTED,e,m)),m=null},void 0===o&&i.setContentType(null),"setRequestHeader"in m&&de.forEach(i.toJSON(),(function(e,t){m.setRequestHeader(t,e)})),de.isUndefined(r.withCredentials)||(m.withCredentials=!!r.withCredentials),p&&"json"!==p&&(m.responseType=r.responseType),h&&([c,l]=dt(h,!0),m.addEventListener("progress",c)),d&&m.upload&&([a,u]=dt(d),m.upload.addEventListener("progress",a),m.upload.addEventListener("loadend",u)),(r.cancelToken||r.signal)&&(s=t=>{m&&(n(!t||t.type?new Ke(null,e,m):t),m.abort(),m=null)},r.cancelToken&&r.cancelToken.subscribe(s),r.signal&&(r.signal.aborted?s():r.signal.addEventListener("abort",s)));const g=Xe(r.url);g&&-1===De.protocols.indexOf(g)?n(new he("Unsupported protocol "+g+":",he.ERR_BAD_REQUEST,e)):m.send(o||null)}))},Dt=(e,t)=>{let n,r=new AbortController;const o=function(e){if(!n){n=!0,s();const t=e instanceof Error?e:this.reason;r.abort(t instanceof he?t:new Ke(t instanceof Error?t.message:t))}};let i=t&&setTimeout((()=>{o(new he(`timeout ${t} of ms exceeded`,he.ETIMEDOUT))}),t);const s=()=>{e&&(i&&clearTimeout(i),i=null,e.forEach((e=>{e&&(e.removeEventListener?e.removeEventListener("abort",o):e.unsubscribe(o))})),e=null)};e.forEach((e=>e&&e.addEventListener&&e.addEventListener("abort",o)));const{signal:a}=r;return a.unsubscribe=s,[a,()=>{i&&clearTimeout(i),i=null}]},Mt=function*(e,t){let n=e.byteLength;if(!t||n<t)return void(yield e);let r,o=0;for(;o<n;)r=o+t,yield e.slice(o,r),o=r},Lt=(e,t,n,r,o)=>{const i=async function*(e,t,n){for await(const r of e)yield*Mt(ArrayBuffer.isView(r)?r:await n(String(r)),t)}(e,t,o);let s,a=0,c=e=>{s||(s=!0,r&&r(e))};return new ReadableStream({async pull(e){try{const{done:t,value:r}=await i.next();if(t)return c(),void e.close();let o=r.byteLength;if(n){let e=a+=o;n(e)}e.enqueue(new Uint8Array(r))}catch(e){throw c(e),e}},cancel:e=>(c(e),i.return())},{highWaterMark:2})},jt="function"==typeof fetch&&"function"==typeof Request&&"function"==typeof Response,Ut=jt&&"function"==typeof ReadableStream,Ft=jt&&("function"==typeof TextEncoder?(zt=new TextEncoder,e=>zt.encode(e)):async e=>new Uint8Array(await new Response(e).arrayBuffer()));var zt;const qt=(e,...t)=>{try{return!!e(...t)}catch(e){return!1}},Bt=Ut&&qt((()=>{let e=!1;const t=new Request(De.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t})),Ht=Ut&&qt((()=>de.isReadableStream(new Response("").body))),Gt={stream:Ht&&(e=>e.body)};var Vt;jt&&(Vt=new Response,["text","arrayBuffer","blob","formData","stream"].forEach((e=>{!Gt[e]&&(Gt[e]=de.isFunction(Vt[e])?t=>t[e]():(t,n)=>{throw new he(`Response type '${e}' is not supported`,he.ERR_NOT_SUPPORT,n)})})));const $t=jt&&(async e=>{let{url:t,method:n,data:r,signal:o,cancelToken:i,timeout:s,onDownloadProgress:a,onUploadProgress:c,responseType:u,headers:l,withCredentials:p="same-origin",fetchOptions:d}=Nt(e);u=u?(u+"").toLowerCase():"text";let h,f,[m,v]=o||i||s?Dt([o,i],s):[];const g=()=>{!h&&setTimeout((()=>{m&&m.unsubscribe()})),h=!0};let y;try{if(c&&Bt&&"get"!==n&&"head"!==n&&0!==(y=await(async(e,t)=>{const n=de.toFiniteNumber(e.getContentLength());return null==n?(async e=>null==e?0:de.isBlob(e)?e.size:de.isSpecCompliantForm(e)?(await new Request(e).arrayBuffer()).byteLength:de.isArrayBufferView(e)||de.isArrayBuffer(e)?e.byteLength:(de.isURLSearchParams(e)&&(e+=""),de.isString(e)?(await Ft(e)).byteLength:void 0))(t):n})(l,r))){let e,n=new Request(t,{method:"POST",body:r,duplex:"half"});if(de.isFormData(r)&&(e=n.headers.get("content-type"))&&l.setContentType(e),n.body){const[e,t]=ht(y,dt(ft(c)));r=Lt(n.body,65536,e,t,Ft)}}de.isString(p)||(p=p?"include":"omit"),f=new Request(t,{...d,signal:m,method:n.toUpperCase(),headers:l.normalize().toJSON(),body:r,duplex:"half",credentials:p});let o=await fetch(f);const i=Ht&&("stream"===u||"response"===u);if(Ht&&(a||i)){const e={};["status","statusText","headers"].forEach((t=>{e[t]=o[t]}));const t=de.toFiniteNumber(o.headers.get("content-length")),[n,r]=a&&ht(t,dt(ft(a),!0))||[];o=new Response(Lt(o.body,65536,n,(()=>{r&&r(),i&&g()}),Ft),e)}u=u||"text";let s=await Gt[de.findKey(Gt,u)||"text"](o,e);return!i&&g(),v&&v(),await new Promise(((t,n)=>{We(t,n,{data:s,headers:Ge.from(o.headers),status:o.status,statusText:o.statusText,config:e,request:f})}))}catch(t){if(g(),t&&"TypeError"===t.name&&/fetch/i.test(t.message))throw Object.assign(new he("Network Error",he.ERR_NETWORK,e,f),{cause:t.cause||t});throw he.from(t,t&&t.code,e,f)}}),Kt={http:At,xhr:kt,fetch:$t};de.forEach(Kt,((e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch(e){}Object.defineProperty(e,"adapterName",{value:t})}}));const Wt=e=>`- ${e}`,Qt=e=>de.isFunction(e)||null===e||!1===e,Yt=e=>{e=de.isArray(e)?e:[e];const{length:t}=e;let n,r;const o={};for(let i=0;i<t;i++){let t;if(n=e[i],r=n,!Qt(n)&&(r=Kt[(t=String(n)).toLowerCase()],void 0===r))throw new he(`Unknown adapter '${t}'`);if(r)break;o[t||"#"+i]=r}if(!r){const e=Object.entries(o).map((([e,t])=>`adapter ${e} `+(!1===t?"is not supported by the environment":"is not available in the build")));throw new he("There is no suitable adapter to dispatch the request "+(t?e.length>1?"since :\n"+e.map(Wt).join("\n"):" "+Wt(e[0]):"as no adapter specified"),"ERR_NOT_SUPPORT")}return r};function Xt(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Ke(null,e)}function Jt(e){return Xt(e),e.headers=Ge.from(e.headers),e.data=Ve.call(e,e.transformRequest),-1!==["post","put","patch"].indexOf(e.method)&&e.headers.setContentType("application/x-www-form-urlencoded",!1),Yt(e.adapter||je.adapter)(e).then((function(t){return Xt(e),t.data=Ve.call(e,e.transformResponse,t),t.headers=Ge.from(t.headers),t}),(function(t){return $e(t)||(Xt(e),t&&t.response&&(t.response.data=Ve.call(e,e.transformResponse,t.response),t.response.headers=Ge.from(t.response.headers))),Promise.reject(t)}))}const Zt={};["object","boolean","number","function","string","symbol"].forEach(((e,t)=>{Zt[e]=function(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}}));const en={};Zt.transitional=function(e,t,n){function r(e,t){return"[Axios v1.7.4] Transitional option '"+e+"'"+t+(n?". "+n:"")}return(n,o,i)=>{if(!1===e)throw new he(r(o," has been removed"+(t?" in "+t:"")),he.ERR_DEPRECATED);return t&&!en[o]&&(en[o]=!0,console.warn(r(o," has been deprecated since v"+t+" and will be removed in the near future"))),!e||e(n,o,i)}};const tn={assertOptions:function(e,t,n){if("object"!=typeof e)throw new he("options must be an object",he.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let o=r.length;for(;o-- >0;){const i=r[o],s=t[i];if(s){const t=e[i],n=void 0===t||s(t,i,e);if(!0!==n)throw new he("option "+i+" must be "+n,he.ERR_BAD_OPTION_VALUE)}else if(!0!==n)throw new he("Unknown option "+i,he.ERR_BAD_OPTION)}},validators:Zt},nn=tn.validators;class rn{constructor(e){this.defaults=e,this.interceptors={request:new we,response:new we}}async request(e,t){try{return await this._request(e,t)}catch(e){if(e instanceof Error){let t;Error.captureStackTrace?Error.captureStackTrace(t={}):t=new Error;const n=t.stack?t.stack.replace(/^.+\n/,""):"";try{e.stack?n&&!String(e.stack).endsWith(n.replace(/^.+\n.+\n/,""))&&(e.stack+="\n"+n):e.stack=n}catch(e){}}throw e}}_request(e,t){"string"==typeof e?(t=t||{}).url=e:t=e||{},t=Ot(this.defaults,t);const{transitional:n,paramsSerializer:r,headers:o}=t;void 0!==n&&tn.assertOptions(n,{silentJSONParsing:nn.transitional(nn.boolean),forcedJSONParsing:nn.transitional(nn.boolean),clarifyTimeoutError:nn.transitional(nn.boolean)},!1),null!=r&&(de.isFunction(r)?t.paramsSerializer={serialize:r}:tn.assertOptions(r,{encode:nn.function,serialize:nn.function},!0)),t.method=(t.method||this.defaults.method||"get").toLowerCase();let i=o&&de.merge(o.common,o[t.method]);o&&de.forEach(["delete","get","head","post","put","patch","common"],(e=>{delete o[e]})),t.headers=Ge.concat(i,o);const s=[];let a=!0;this.interceptors.request.forEach((function(e){"function"==typeof e.runWhen&&!1===e.runWhen(t)||(a=a&&e.synchronous,s.unshift(e.fulfilled,e.rejected))}));const c=[];let u;this.interceptors.response.forEach((function(e){c.push(e.fulfilled,e.rejected)}));let l,p=0;if(!a){const e=[Jt.bind(this),void 0];for(e.unshift.apply(e,s),e.push.apply(e,c),l=e.length,u=Promise.resolve(t);p<l;)u=u.then(e[p++],e[p++]);return u}l=s.length;let d=t;for(p=0;p<l;){const e=s[p++],t=s[p++];try{d=e(d)}catch(e){t.call(this,e);break}}try{u=Jt.call(this,d)}catch(e){return Promise.reject(e)}for(p=0,l=c.length;p<l;)u=u.then(c[p++],c[p++]);return u}getUri(e){return xe(Qe((e=Ot(this.defaults,e)).baseURL,e.url),e.params,e.paramsSerializer)}}de.forEach(["delete","get","head","options"],(function(e){rn.prototype[e]=function(t,n){return this.request(Ot(n||{},{method:e,url:t,data:(n||{}).data}))}})),de.forEach(["post","put","patch"],(function(e){function t(t){return function(n,r,o){return this.request(Ot(o||{},{method:e,headers:t?{"Content-Type":"multipart/form-data"}:{},url:n,data:r}))}}rn.prototype[e]=t(),rn.prototype[e+"Form"]=t(!0)}));const on=rn;class sn{constructor(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");let t;this.promise=new Promise((function(e){t=e}));const n=this;this.promise.then((e=>{if(!n._listeners)return;let t=n._listeners.length;for(;t-- >0;)n._listeners[t](e);n._listeners=null})),this.promise.then=e=>{let t;const r=new Promise((e=>{n.subscribe(e),t=e})).then(e);return r.cancel=function(){n.unsubscribe(t)},r},e((function(e,r,o){n.reason||(n.reason=new Ke(e,r,o),t(n.reason))}))}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){this.reason?e(this.reason):this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const t=this._listeners.indexOf(e);-1!==t&&this._listeners.splice(t,1)}static source(){let e;return{token:new sn((function(t){e=t})),cancel:e}}}const an=sn,cn={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};Object.entries(cn).forEach((([e,t])=>{cn[t]=e}));const un=cn,ln=function e(t){const n=new on(t),r=T(on.prototype.request,n);return de.extend(r,on.prototype,n,{allOwnKeys:!0}),de.extend(r,n,null,{allOwnKeys:!0}),r.create=function(n){return e(Ot(t,n))},r}(je);ln.Axios=on,ln.CanceledError=Ke,ln.CancelToken=an,ln.isCancel=$e,ln.VERSION=Ye,ln.toFormData=be,ln.AxiosError=he,ln.Cancel=ln.CanceledError,ln.all=function(e){return Promise.all(e)},ln.spread=function(e){return function(t){return e.apply(null,t)}},ln.isAxiosError=function(e){return de.isObject(e)&&!0===e.isAxiosError},ln.mergeConfig=Ot,ln.AxiosHeaders=Ge,ln.formToJSON=e=>Me(de.isHTMLForm(e)?new FormData(e):e),ln.getAdapter=Yt,ln.HttpStatusCode=un,ln.default=ln,e.exports=ln},1813:e=>{"use strict";e.exports=JSON.parse('{"application/1d-interleaved-parityfec":{"source":"iana"},"application/3gpdash-qoe-report+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/3gpp-ims+xml":{"source":"iana","compressible":true},"application/3gpphal+json":{"source":"iana","compressible":true},"application/3gpphalforms+json":{"source":"iana","compressible":true},"application/a2l":{"source":"iana"},"application/ace+cbor":{"source":"iana"},"application/activemessage":{"source":"iana"},"application/activity+json":{"source":"iana","compressible":true},"application/alto-costmap+json":{"source":"iana","compressible":true},"application/alto-costmapfilter+json":{"source":"iana","compressible":true},"application/alto-directory+json":{"source":"iana","compressible":true},"application/alto-endpointcost+json":{"source":"iana","compressible":true},"application/alto-endpointcostparams+json":{"source":"iana","compressible":true},"application/alto-endpointprop+json":{"source":"iana","compressible":true},"application/alto-endpointpropparams+json":{"source":"iana","compressible":true},"application/alto-error+json":{"source":"iana","compressible":true},"application/alto-networkmap+json":{"source":"iana","compressible":true},"application/alto-networkmapfilter+json":{"source":"iana","compressible":true},"application/alto-updatestreamcontrol+json":{"source":"iana","compressible":true},"application/alto-updatestreamparams+json":{"source":"iana","compressible":true},"application/aml":{"source":"iana"},"application/andrew-inset":{"source":"iana","extensions":["ez"]},"application/applefile":{"source":"iana"},"application/applixware":{"source":"apache","extensions":["aw"]},"application/at+jwt":{"source":"iana"},"application/atf":{"source":"iana"},"application/atfx":{"source":"iana"},"application/atom+xml":{"source":"iana","compressible":true,"extensions":["atom"]},"application/atomcat+xml":{"source":"iana","compressible":true,"extensions":["atomcat"]},"application/atomdeleted+xml":{"source":"iana","compressible":true,"extensions":["atomdeleted"]},"application/atomicmail":{"source":"iana"},"application/atomsvc+xml":{"source":"iana","compressible":true,"extensions":["atomsvc"]},"application/atsc-dwd+xml":{"source":"iana","compressible":true,"extensions":["dwd"]},"application/atsc-dynamic-event-message":{"source":"iana"},"application/atsc-held+xml":{"source":"iana","compressible":true,"extensions":["held"]},"application/atsc-rdt+json":{"source":"iana","compressible":true},"application/atsc-rsat+xml":{"source":"iana","compressible":true,"extensions":["rsat"]},"application/atxml":{"source":"iana"},"application/auth-policy+xml":{"source":"iana","compressible":true},"application/bacnet-xdd+zip":{"source":"iana","compressible":false},"application/batch-smtp":{"source":"iana"},"application/bdoc":{"compressible":false,"extensions":["bdoc"]},"application/beep+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/calendar+json":{"source":"iana","compressible":true},"application/calendar+xml":{"source":"iana","compressible":true,"extensions":["xcs"]},"application/call-completion":{"source":"iana"},"application/cals-1840":{"source":"iana"},"application/captive+json":{"source":"iana","compressible":true},"application/cbor":{"source":"iana"},"application/cbor-seq":{"source":"iana"},"application/cccex":{"source":"iana"},"application/ccmp+xml":{"source":"iana","compressible":true},"application/ccxml+xml":{"source":"iana","compressible":true,"extensions":["ccxml"]},"application/cdfx+xml":{"source":"iana","compressible":true,"extensions":["cdfx"]},"application/cdmi-capability":{"source":"iana","extensions":["cdmia"]},"application/cdmi-container":{"source":"iana","extensions":["cdmic"]},"application/cdmi-domain":{"source":"iana","extensions":["cdmid"]},"application/cdmi-object":{"source":"iana","extensions":["cdmio"]},"application/cdmi-queue":{"source":"iana","extensions":["cdmiq"]},"application/cdni":{"source":"iana"},"application/cea":{"source":"iana"},"application/cea-2018+xml":{"source":"iana","compressible":true},"application/cellml+xml":{"source":"iana","compressible":true},"application/cfw":{"source":"iana"},"application/city+json":{"source":"iana","compressible":true},"application/clr":{"source":"iana"},"application/clue+xml":{"source":"iana","compressible":true},"application/clue_info+xml":{"source":"iana","compressible":true},"application/cms":{"source":"iana"},"application/cnrp+xml":{"source":"iana","compressible":true},"application/coap-group+json":{"source":"iana","compressible":true},"application/coap-payload":{"source":"iana"},"application/commonground":{"source":"iana"},"application/conference-info+xml":{"source":"iana","compressible":true},"application/cose":{"source":"iana"},"application/cose-key":{"source":"iana"},"application/cose-key-set":{"source":"iana"},"application/cpl+xml":{"source":"iana","compressible":true,"extensions":["cpl"]},"application/csrattrs":{"source":"iana"},"application/csta+xml":{"source":"iana","compressible":true},"application/cstadata+xml":{"source":"iana","compressible":true},"application/csvm+json":{"source":"iana","compressible":true},"application/cu-seeme":{"source":"apache","extensions":["cu"]},"application/cwt":{"source":"iana"},"application/cybercash":{"source":"iana"},"application/dart":{"compressible":true},"application/dash+xml":{"source":"iana","compressible":true,"extensions":["mpd"]},"application/dash-patch+xml":{"source":"iana","compressible":true,"extensions":["mpp"]},"application/dashdelta":{"source":"iana"},"application/davmount+xml":{"source":"iana","compressible":true,"extensions":["davmount"]},"application/dca-rft":{"source":"iana"},"application/dcd":{"source":"iana"},"application/dec-dx":{"source":"iana"},"application/dialog-info+xml":{"source":"iana","compressible":true},"application/dicom":{"source":"iana"},"application/dicom+json":{"source":"iana","compressible":true},"application/dicom+xml":{"source":"iana","compressible":true},"application/dii":{"source":"iana"},"application/dit":{"source":"iana"},"application/dns":{"source":"iana"},"application/dns+json":{"source":"iana","compressible":true},"application/dns-message":{"source":"iana"},"application/docbook+xml":{"source":"apache","compressible":true,"extensions":["dbk"]},"application/dots+cbor":{"source":"iana"},"application/dskpp+xml":{"source":"iana","compressible":true},"application/dssc+der":{"source":"iana","extensions":["dssc"]},"application/dssc+xml":{"source":"iana","compressible":true,"extensions":["xdssc"]},"application/dvcs":{"source":"iana"},"application/ecmascript":{"source":"iana","compressible":true,"extensions":["es","ecma"]},"application/edi-consent":{"source":"iana"},"application/edi-x12":{"source":"iana","compressible":false},"application/edifact":{"source":"iana","compressible":false},"application/efi":{"source":"iana"},"application/elm+json":{"source":"iana","charset":"UTF-8","compressible":true},"application/elm+xml":{"source":"iana","compressible":true},"application/emergencycalldata.cap+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/emergencycalldata.comment+xml":{"source":"iana","compressible":true},"application/emergencycalldata.control+xml":{"source":"iana","compressible":true},"application/emergencycalldata.deviceinfo+xml":{"source":"iana","compressible":true},"application/emergencycalldata.ecall.msd":{"source":"iana"},"application/emergencycalldata.providerinfo+xml":{"source":"iana","compressible":true},"application/emergencycalldata.serviceinfo+xml":{"source":"iana","compressible":true},"application/emergencycalldata.subscriberinfo+xml":{"source":"iana","compressible":true},"application/emergencycalldata.veds+xml":{"source":"iana","compressible":true},"application/emma+xml":{"source":"iana","compressible":true,"extensions":["emma"]},"application/emotionml+xml":{"source":"iana","compressible":true,"extensions":["emotionml"]},"application/encaprtp":{"source":"iana"},"application/epp+xml":{"source":"iana","compressible":true},"application/epub+zip":{"source":"iana","compressible":false,"extensions":["epub"]},"application/eshop":{"source":"iana"},"application/exi":{"source":"iana","extensions":["exi"]},"application/expect-ct-report+json":{"source":"iana","compressible":true},"application/express":{"source":"iana","extensions":["exp"]},"application/fastinfoset":{"source":"iana"},"application/fastsoap":{"source":"iana"},"application/fdt+xml":{"source":"iana","compressible":true,"extensions":["fdt"]},"application/fhir+json":{"source":"iana","charset":"UTF-8","compressible":true},"application/fhir+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/fido.trusted-apps+json":{"compressible":true},"application/fits":{"source":"iana"},"application/flexfec":{"source":"iana"},"application/font-sfnt":{"source":"iana"},"application/font-tdpfr":{"source":"iana","extensions":["pfr"]},"application/font-woff":{"source":"iana","compressible":false},"application/framework-attributes+xml":{"source":"iana","compressible":true},"application/geo+json":{"source":"iana","compressible":true,"extensions":["geojson"]},"application/geo+json-seq":{"source":"iana"},"application/geopackage+sqlite3":{"source":"iana"},"application/geoxacml+xml":{"source":"iana","compressible":true},"application/gltf-buffer":{"source":"iana"},"application/gml+xml":{"source":"iana","compressible":true,"extensions":["gml"]},"application/gpx+xml":{"source":"apache","compressible":true,"extensions":["gpx"]},"application/gxf":{"source":"apache","extensions":["gxf"]},"application/gzip":{"source":"iana","compressible":false,"extensions":["gz"]},"application/h224":{"source":"iana"},"application/held+xml":{"source":"iana","compressible":true},"application/hjson":{"extensions":["hjson"]},"application/http":{"source":"iana"},"application/hyperstudio":{"source":"iana","extensions":["stk"]},"application/ibe-key-request+xml":{"source":"iana","compressible":true},"application/ibe-pkg-reply+xml":{"source":"iana","compressible":true},"application/ibe-pp-data":{"source":"iana"},"application/iges":{"source":"iana"},"application/im-iscomposing+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/index":{"source":"iana"},"application/index.cmd":{"source":"iana"},"application/index.obj":{"source":"iana"},"application/index.response":{"source":"iana"},"application/index.vnd":{"source":"iana"},"application/inkml+xml":{"source":"iana","compressible":true,"extensions":["ink","inkml"]},"application/iotp":{"source":"iana"},"application/ipfix":{"source":"iana","extensions":["ipfix"]},"application/ipp":{"source":"iana"},"application/isup":{"source":"iana"},"application/its+xml":{"source":"iana","compressible":true,"extensions":["its"]},"application/java-archive":{"source":"apache","compressible":false,"extensions":["jar","war","ear"]},"application/java-serialized-object":{"source":"apache","compressible":false,"extensions":["ser"]},"application/java-vm":{"source":"apache","compressible":false,"extensions":["class"]},"application/javascript":{"source":"iana","charset":"UTF-8","compressible":true,"extensions":["js","mjs"]},"application/jf2feed+json":{"source":"iana","compressible":true},"application/jose":{"source":"iana"},"application/jose+json":{"source":"iana","compressible":true},"application/jrd+json":{"source":"iana","compressible":true},"application/jscalendar+json":{"source":"iana","compressible":true},"application/json":{"source":"iana","charset":"UTF-8","compressible":true,"extensions":["json","map"]},"application/json-patch+json":{"source":"iana","compressible":true},"application/json-seq":{"source":"iana"},"application/json5":{"extensions":["json5"]},"application/jsonml+json":{"source":"apache","compressible":true,"extensions":["jsonml"]},"application/jwk+json":{"source":"iana","compressible":true},"application/jwk-set+json":{"source":"iana","compressible":true},"application/jwt":{"source":"iana"},"application/kpml-request+xml":{"source":"iana","compressible":true},"application/kpml-response+xml":{"source":"iana","compressible":true},"application/ld+json":{"source":"iana","compressible":true,"extensions":["jsonld"]},"application/lgr+xml":{"source":"iana","compressible":true,"extensions":["lgr"]},"application/link-format":{"source":"iana"},"application/load-control+xml":{"source":"iana","compressible":true},"application/lost+xml":{"source":"iana","compressible":true,"extensions":["lostxml"]},"application/lostsync+xml":{"source":"iana","compressible":true},"application/lpf+zip":{"source":"iana","compressible":false},"application/lxf":{"source":"iana"},"application/mac-binhex40":{"source":"iana","extensions":["hqx"]},"application/mac-compactpro":{"source":"apache","extensions":["cpt"]},"application/macwriteii":{"source":"iana"},"application/mads+xml":{"source":"iana","compressible":true,"extensions":["mads"]},"application/manifest+json":{"source":"iana","charset":"UTF-8","compressible":true,"extensions":["webmanifest"]},"application/marc":{"source":"iana","extensions":["mrc"]},"application/marcxml+xml":{"source":"iana","compressible":true,"extensions":["mrcx"]},"application/mathematica":{"source":"iana","extensions":["ma","nb","mb"]},"application/mathml+xml":{"source":"iana","compressible":true,"extensions":["mathml"]},"application/mathml-content+xml":{"source":"iana","compressible":true},"application/mathml-presentation+xml":{"source":"iana","compressible":true},"application/mbms-associated-procedure-description+xml":{"source":"iana","compressible":true},"application/mbms-deregister+xml":{"source":"iana","compressible":true},"application/mbms-envelope+xml":{"source":"iana","compressible":true},"application/mbms-msk+xml":{"source":"iana","compressible":true},"application/mbms-msk-response+xml":{"source":"iana","compressible":true},"application/mbms-protection-description+xml":{"source":"iana","compressible":true},"application/mbms-reception-report+xml":{"source":"iana","compressible":true},"application/mbms-register+xml":{"source":"iana","compressible":true},"application/mbms-register-response+xml":{"source":"iana","compressible":true},"application/mbms-schedule+xml":{"source":"iana","compressible":true},"application/mbms-user-service-description+xml":{"source":"iana","compressible":true},"application/mbox":{"source":"iana","extensions":["mbox"]},"application/media-policy-dataset+xml":{"source":"iana","compressible":true,"extensions":["mpf"]},"application/media_control+xml":{"source":"iana","compressible":true},"application/mediaservercontrol+xml":{"source":"iana","compressible":true,"extensions":["mscml"]},"application/merge-patch+json":{"source":"iana","compressible":true},"application/metalink+xml":{"source":"apache","compressible":true,"extensions":["metalink"]},"application/metalink4+xml":{"source":"iana","compressible":true,"extensions":["meta4"]},"application/mets+xml":{"source":"iana","compressible":true,"extensions":["mets"]},"application/mf4":{"source":"iana"},"application/mikey":{"source":"iana"},"application/mipc":{"source":"iana"},"application/missing-blocks+cbor-seq":{"source":"iana"},"application/mmt-aei+xml":{"source":"iana","compressible":true,"extensions":["maei"]},"application/mmt-usd+xml":{"source":"iana","compressible":true,"extensions":["musd"]},"application/mods+xml":{"source":"iana","compressible":true,"extensions":["mods"]},"application/moss-keys":{"source":"iana"},"application/moss-signature":{"source":"iana"},"application/mosskey-data":{"source":"iana"},"application/mosskey-request":{"source":"iana"},"application/mp21":{"source":"iana","extensions":["m21","mp21"]},"application/mp4":{"source":"iana","extensions":["mp4s","m4p"]},"application/mpeg4-generic":{"source":"iana"},"application/mpeg4-iod":{"source":"iana"},"application/mpeg4-iod-xmt":{"source":"iana"},"application/mrb-consumer+xml":{"source":"iana","compressible":true},"application/mrb-publish+xml":{"source":"iana","compressible":true},"application/msc-ivr+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/msc-mixer+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/msword":{"source":"iana","compressible":false,"extensions":["doc","dot"]},"application/mud+json":{"source":"iana","compressible":true},"application/multipart-core":{"source":"iana"},"application/mxf":{"source":"iana","extensions":["mxf"]},"application/n-quads":{"source":"iana","extensions":["nq"]},"application/n-triples":{"source":"iana","extensions":["nt"]},"application/nasdata":{"source":"iana"},"application/news-checkgroups":{"source":"iana","charset":"US-ASCII"},"application/news-groupinfo":{"source":"iana","charset":"US-ASCII"},"application/news-transmission":{"source":"iana"},"application/nlsml+xml":{"source":"iana","compressible":true},"application/node":{"source":"iana","extensions":["cjs"]},"application/nss":{"source":"iana"},"application/oauth-authz-req+jwt":{"source":"iana"},"application/oblivious-dns-message":{"source":"iana"},"application/ocsp-request":{"source":"iana"},"application/ocsp-response":{"source":"iana"},"application/octet-stream":{"source":"iana","compressible":false,"extensions":["bin","dms","lrf","mar","so","dist","distz","pkg","bpk","dump","elc","deploy","exe","dll","deb","dmg","iso","img","msi","msp","msm","buffer"]},"application/oda":{"source":"iana","extensions":["oda"]},"application/odm+xml":{"source":"iana","compressible":true},"application/odx":{"source":"iana"},"application/oebps-package+xml":{"source":"iana","compressible":true,"extensions":["opf"]},"application/ogg":{"source":"iana","compressible":false,"extensions":["ogx"]},"application/omdoc+xml":{"source":"apache","compressible":true,"extensions":["omdoc"]},"application/onenote":{"source":"apache","extensions":["onetoc","onetoc2","onetmp","onepkg"]},"application/opc-nodeset+xml":{"source":"iana","compressible":true},"application/oscore":{"source":"iana"},"application/oxps":{"source":"iana","extensions":["oxps"]},"application/p21":{"source":"iana"},"application/p21+zip":{"source":"iana","compressible":false},"application/p2p-overlay+xml":{"source":"iana","compressible":true,"extensions":["relo"]},"application/parityfec":{"source":"iana"},"application/passport":{"source":"iana"},"application/patch-ops-error+xml":{"source":"iana","compressible":true,"extensions":["xer"]},"application/pdf":{"source":"iana","compressible":false,"extensions":["pdf"]},"application/pdx":{"source":"iana"},"application/pem-certificate-chain":{"source":"iana"},"application/pgp-encrypted":{"source":"iana","compressible":false,"extensions":["pgp"]},"application/pgp-keys":{"source":"iana","extensions":["asc"]},"application/pgp-signature":{"source":"iana","extensions":["asc","sig"]},"application/pics-rules":{"source":"apache","extensions":["prf"]},"application/pidf+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/pidf-diff+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/pkcs10":{"source":"iana","extensions":["p10"]},"application/pkcs12":{"source":"iana"},"application/pkcs7-mime":{"source":"iana","extensions":["p7m","p7c"]},"application/pkcs7-signature":{"source":"iana","extensions":["p7s"]},"application/pkcs8":{"source":"iana","extensions":["p8"]},"application/pkcs8-encrypted":{"source":"iana"},"application/pkix-attr-cert":{"source":"iana","extensions":["ac"]},"application/pkix-cert":{"source":"iana","extensions":["cer"]},"application/pkix-crl":{"source":"iana","extensions":["crl"]},"application/pkix-pkipath":{"source":"iana","extensions":["pkipath"]},"application/pkixcmp":{"source":"iana","extensions":["pki"]},"application/pls+xml":{"source":"iana","compressible":true,"extensions":["pls"]},"application/poc-settings+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/postscript":{"source":"iana","compressible":true,"extensions":["ai","eps","ps"]},"application/ppsp-tracker+json":{"source":"iana","compressible":true},"application/problem+json":{"source":"iana","compressible":true},"application/problem+xml":{"source":"iana","compressible":true},"application/provenance+xml":{"source":"iana","compressible":true,"extensions":["provx"]},"application/prs.alvestrand.titrax-sheet":{"source":"iana"},"application/prs.cww":{"source":"iana","extensions":["cww"]},"application/prs.cyn":{"source":"iana","charset":"7-BIT"},"application/prs.hpub+zip":{"source":"iana","compressible":false},"application/prs.nprend":{"source":"iana"},"application/prs.plucker":{"source":"iana"},"application/prs.rdf-xml-crypt":{"source":"iana"},"application/prs.xsf+xml":{"source":"iana","compressible":true},"application/pskc+xml":{"source":"iana","compressible":true,"extensions":["pskcxml"]},"application/pvd+json":{"source":"iana","compressible":true},"application/qsig":{"source":"iana"},"application/raml+yaml":{"compressible":true,"extensions":["raml"]},"application/raptorfec":{"source":"iana"},"application/rdap+json":{"source":"iana","compressible":true},"application/rdf+xml":{"source":"iana","compressible":true,"extensions":["rdf","owl"]},"application/reginfo+xml":{"source":"iana","compressible":true,"extensions":["rif"]},"application/relax-ng-compact-syntax":{"source":"iana","extensions":["rnc"]},"application/remote-printing":{"source":"iana"},"application/reputon+json":{"source":"iana","compressible":true},"application/resource-lists+xml":{"source":"iana","compressible":true,"extensions":["rl"]},"application/resource-lists-diff+xml":{"source":"iana","compressible":true,"extensions":["rld"]},"application/rfc+xml":{"source":"iana","compressible":true},"application/riscos":{"source":"iana"},"application/rlmi+xml":{"source":"iana","compressible":true},"application/rls-services+xml":{"source":"iana","compressible":true,"extensions":["rs"]},"application/route-apd+xml":{"source":"iana","compressible":true,"extensions":["rapd"]},"application/route-s-tsid+xml":{"source":"iana","compressible":true,"extensions":["sls"]},"application/route-usd+xml":{"source":"iana","compressible":true,"extensions":["rusd"]},"application/rpki-ghostbusters":{"source":"iana","extensions":["gbr"]},"application/rpki-manifest":{"source":"iana","extensions":["mft"]},"application/rpki-publication":{"source":"iana"},"application/rpki-roa":{"source":"iana","extensions":["roa"]},"application/rpki-updown":{"source":"iana"},"application/rsd+xml":{"source":"apache","compressible":true,"extensions":["rsd"]},"application/rss+xml":{"source":"apache","compressible":true,"extensions":["rss"]},"application/rtf":{"source":"iana","compressible":true,"extensions":["rtf"]},"application/rtploopback":{"source":"iana"},"application/rtx":{"source":"iana"},"application/samlassertion+xml":{"source":"iana","compressible":true},"application/samlmetadata+xml":{"source":"iana","compressible":true},"application/sarif+json":{"source":"iana","compressible":true},"application/sarif-external-properties+json":{"source":"iana","compressible":true},"application/sbe":{"source":"iana"},"application/sbml+xml":{"source":"iana","compressible":true,"extensions":["sbml"]},"application/scaip+xml":{"source":"iana","compressible":true},"application/scim+json":{"source":"iana","compressible":true},"application/scvp-cv-request":{"source":"iana","extensions":["scq"]},"application/scvp-cv-response":{"source":"iana","extensions":["scs"]},"application/scvp-vp-request":{"source":"iana","extensions":["spq"]},"application/scvp-vp-response":{"source":"iana","extensions":["spp"]},"application/sdp":{"source":"iana","extensions":["sdp"]},"application/secevent+jwt":{"source":"iana"},"application/senml+cbor":{"source":"iana"},"application/senml+json":{"source":"iana","compressible":true},"application/senml+xml":{"source":"iana","compressible":true,"extensions":["senmlx"]},"application/senml-etch+cbor":{"source":"iana"},"application/senml-etch+json":{"source":"iana","compressible":true},"application/senml-exi":{"source":"iana"},"application/sensml+cbor":{"source":"iana"},"application/sensml+json":{"source":"iana","compressible":true},"application/sensml+xml":{"source":"iana","compressible":true,"extensions":["sensmlx"]},"application/sensml-exi":{"source":"iana"},"application/sep+xml":{"source":"iana","compressible":true},"application/sep-exi":{"source":"iana"},"application/session-info":{"source":"iana"},"application/set-payment":{"source":"iana"},"application/set-payment-initiation":{"source":"iana","extensions":["setpay"]},"application/set-registration":{"source":"iana"},"application/set-registration-initiation":{"source":"iana","extensions":["setreg"]},"application/sgml":{"source":"iana"},"application/sgml-open-catalog":{"source":"iana"},"application/shf+xml":{"source":"iana","compressible":true,"extensions":["shf"]},"application/sieve":{"source":"iana","extensions":["siv","sieve"]},"application/simple-filter+xml":{"source":"iana","compressible":true},"application/simple-message-summary":{"source":"iana"},"application/simplesymbolcontainer":{"source":"iana"},"application/sipc":{"source":"iana"},"application/slate":{"source":"iana"},"application/smil":{"source":"iana"},"application/smil+xml":{"source":"iana","compressible":true,"extensions":["smi","smil"]},"application/smpte336m":{"source":"iana"},"application/soap+fastinfoset":{"source":"iana"},"application/soap+xml":{"source":"iana","compressible":true},"application/sparql-query":{"source":"iana","extensions":["rq"]},"application/sparql-results+xml":{"source":"iana","compressible":true,"extensions":["srx"]},"application/spdx+json":{"source":"iana","compressible":true},"application/spirits-event+xml":{"source":"iana","compressible":true},"application/sql":{"source":"iana"},"application/srgs":{"source":"iana","extensions":["gram"]},"application/srgs+xml":{"source":"iana","compressible":true,"extensions":["grxml"]},"application/sru+xml":{"source":"iana","compressible":true,"extensions":["sru"]},"application/ssdl+xml":{"source":"apache","compressible":true,"extensions":["ssdl"]},"application/ssml+xml":{"source":"iana","compressible":true,"extensions":["ssml"]},"application/stix+json":{"source":"iana","compressible":true},"application/swid+xml":{"source":"iana","compressible":true,"extensions":["swidtag"]},"application/tamp-apex-update":{"source":"iana"},"application/tamp-apex-update-confirm":{"source":"iana"},"application/tamp-community-update":{"source":"iana"},"application/tamp-community-update-confirm":{"source":"iana"},"application/tamp-error":{"source":"iana"},"application/tamp-sequence-adjust":{"source":"iana"},"application/tamp-sequence-adjust-confirm":{"source":"iana"},"application/tamp-status-query":{"source":"iana"},"application/tamp-status-response":{"source":"iana"},"application/tamp-update":{"source":"iana"},"application/tamp-update-confirm":{"source":"iana"},"application/tar":{"compressible":true},"application/taxii+json":{"source":"iana","compressible":true},"application/td+json":{"source":"iana","compressible":true},"application/tei+xml":{"source":"iana","compressible":true,"extensions":["tei","teicorpus"]},"application/tetra_isi":{"source":"iana"},"application/thraud+xml":{"source":"iana","compressible":true,"extensions":["tfi"]},"application/timestamp-query":{"source":"iana"},"application/timestamp-reply":{"source":"iana"},"application/timestamped-data":{"source":"iana","extensions":["tsd"]},"application/tlsrpt+gzip":{"source":"iana"},"application/tlsrpt+json":{"source":"iana","compressible":true},"application/tnauthlist":{"source":"iana"},"application/token-introspection+jwt":{"source":"iana"},"application/toml":{"compressible":true,"extensions":["toml"]},"application/trickle-ice-sdpfrag":{"source":"iana"},"application/trig":{"source":"iana","extensions":["trig"]},"application/ttml+xml":{"source":"iana","compressible":true,"extensions":["ttml"]},"application/tve-trigger":{"source":"iana"},"application/tzif":{"source":"iana"},"application/tzif-leap":{"source":"iana"},"application/ubjson":{"compressible":false,"extensions":["ubj"]},"application/ulpfec":{"source":"iana"},"application/urc-grpsheet+xml":{"source":"iana","compressible":true},"application/urc-ressheet+xml":{"source":"iana","compressible":true,"extensions":["rsheet"]},"application/urc-targetdesc+xml":{"source":"iana","compressible":true,"extensions":["td"]},"application/urc-uisocketdesc+xml":{"source":"iana","compressible":true},"application/vcard+json":{"source":"iana","compressible":true},"application/vcard+xml":{"source":"iana","compressible":true},"application/vemmi":{"source":"iana"},"application/vividence.scriptfile":{"source":"apache"},"application/vnd.1000minds.decision-model+xml":{"source":"iana","compressible":true,"extensions":["1km"]},"application/vnd.3gpp-prose+xml":{"source":"iana","compressible":true},"application/vnd.3gpp-prose-pc3ch+xml":{"source":"iana","compressible":true},"application/vnd.3gpp-v2x-local-service-information":{"source":"iana"},"application/vnd.3gpp.5gnas":{"source":"iana"},"application/vnd.3gpp.access-transfer-events+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.bsf+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.gmop+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.gtpc":{"source":"iana"},"application/vnd.3gpp.interworking-data":{"source":"iana"},"application/vnd.3gpp.lpp":{"source":"iana"},"application/vnd.3gpp.mc-signalling-ear":{"source":"iana"},"application/vnd.3gpp.mcdata-affiliation-command+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcdata-info+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcdata-payload":{"source":"iana"},"application/vnd.3gpp.mcdata-service-config+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcdata-signalling":{"source":"iana"},"application/vnd.3gpp.mcdata-ue-config+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcdata-user-profile+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcptt-affiliation-command+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcptt-floor-request+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcptt-info+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcptt-location-info+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcptt-mbms-usage-info+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcptt-service-config+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcptt-signed+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcptt-ue-config+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcptt-ue-init-config+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcptt-user-profile+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcvideo-affiliation-command+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcvideo-affiliation-info+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcvideo-info+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcvideo-location-info+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcvideo-mbms-usage-info+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcvideo-service-config+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcvideo-transmission-request+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcvideo-ue-config+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mcvideo-user-profile+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.mid-call+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.ngap":{"source":"iana"},"application/vnd.3gpp.pfcp":{"source":"iana"},"application/vnd.3gpp.pic-bw-large":{"source":"iana","extensions":["plb"]},"application/vnd.3gpp.pic-bw-small":{"source":"iana","extensions":["psb"]},"application/vnd.3gpp.pic-bw-var":{"source":"iana","extensions":["pvb"]},"application/vnd.3gpp.s1ap":{"source":"iana"},"application/vnd.3gpp.sms":{"source":"iana"},"application/vnd.3gpp.sms+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.srvcc-ext+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.srvcc-info+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.state-and-event-info+xml":{"source":"iana","compressible":true},"application/vnd.3gpp.ussd+xml":{"source":"iana","compressible":true},"application/vnd.3gpp2.bcmcsinfo+xml":{"source":"iana","compressible":true},"application/vnd.3gpp2.sms":{"source":"iana"},"application/vnd.3gpp2.tcap":{"source":"iana","extensions":["tcap"]},"application/vnd.3lightssoftware.imagescal":{"source":"iana"},"application/vnd.3m.post-it-notes":{"source":"iana","extensions":["pwn"]},"application/vnd.accpac.simply.aso":{"source":"iana","extensions":["aso"]},"application/vnd.accpac.simply.imp":{"source":"iana","extensions":["imp"]},"application/vnd.acucobol":{"source":"iana","extensions":["acu"]},"application/vnd.acucorp":{"source":"iana","extensions":["atc","acutc"]},"application/vnd.adobe.air-application-installer-package+zip":{"source":"apache","compressible":false,"extensions":["air"]},"application/vnd.adobe.flash.movie":{"source":"iana"},"application/vnd.adobe.formscentral.fcdt":{"source":"iana","extensions":["fcdt"]},"application/vnd.adobe.fxp":{"source":"iana","extensions":["fxp","fxpl"]},"application/vnd.adobe.partial-upload":{"source":"iana"},"application/vnd.adobe.xdp+xml":{"source":"iana","compressible":true,"extensions":["xdp"]},"application/vnd.adobe.xfdf":{"source":"iana","extensions":["xfdf"]},"application/vnd.aether.imp":{"source":"iana"},"application/vnd.afpc.afplinedata":{"source":"iana"},"application/vnd.afpc.afplinedata-pagedef":{"source":"iana"},"application/vnd.afpc.cmoca-cmresource":{"source":"iana"},"application/vnd.afpc.foca-charset":{"source":"iana"},"application/vnd.afpc.foca-codedfont":{"source":"iana"},"application/vnd.afpc.foca-codepage":{"source":"iana"},"application/vnd.afpc.modca":{"source":"iana"},"application/vnd.afpc.modca-cmtable":{"source":"iana"},"application/vnd.afpc.modca-formdef":{"source":"iana"},"application/vnd.afpc.modca-mediummap":{"source":"iana"},"application/vnd.afpc.modca-objectcontainer":{"source":"iana"},"application/vnd.afpc.modca-overlay":{"source":"iana"},"application/vnd.afpc.modca-pagesegment":{"source":"iana"},"application/vnd.age":{"source":"iana","extensions":["age"]},"application/vnd.ah-barcode":{"source":"iana"},"application/vnd.ahead.space":{"source":"iana","extensions":["ahead"]},"application/vnd.airzip.filesecure.azf":{"source":"iana","extensions":["azf"]},"application/vnd.airzip.filesecure.azs":{"source":"iana","extensions":["azs"]},"application/vnd.amadeus+json":{"source":"iana","compressible":true},"application/vnd.amazon.ebook":{"source":"apache","extensions":["azw"]},"application/vnd.amazon.mobi8-ebook":{"source":"iana"},"application/vnd.americandynamics.acc":{"source":"iana","extensions":["acc"]},"application/vnd.amiga.ami":{"source":"iana","extensions":["ami"]},"application/vnd.amundsen.maze+xml":{"source":"iana","compressible":true},"application/vnd.android.ota":{"source":"iana"},"application/vnd.android.package-archive":{"source":"apache","compressible":false,"extensions":["apk"]},"application/vnd.anki":{"source":"iana"},"application/vnd.anser-web-certificate-issue-initiation":{"source":"iana","extensions":["cii"]},"application/vnd.anser-web-funds-transfer-initiation":{"source":"apache","extensions":["fti"]},"application/vnd.antix.game-component":{"source":"iana","extensions":["atx"]},"application/vnd.apache.arrow.file":{"source":"iana"},"application/vnd.apache.arrow.stream":{"source":"iana"},"application/vnd.apache.thrift.binary":{"source":"iana"},"application/vnd.apache.thrift.compact":{"source":"iana"},"application/vnd.apache.thrift.json":{"source":"iana"},"application/vnd.api+json":{"source":"iana","compressible":true},"application/vnd.aplextor.warrp+json":{"source":"iana","compressible":true},"application/vnd.apothekende.reservation+json":{"source":"iana","compressible":true},"application/vnd.apple.installer+xml":{"source":"iana","compressible":true,"extensions":["mpkg"]},"application/vnd.apple.keynote":{"source":"iana","extensions":["key"]},"application/vnd.apple.mpegurl":{"source":"iana","extensions":["m3u8"]},"application/vnd.apple.numbers":{"source":"iana","extensions":["numbers"]},"application/vnd.apple.pages":{"source":"iana","extensions":["pages"]},"application/vnd.apple.pkpass":{"compressible":false,"extensions":["pkpass"]},"application/vnd.arastra.swi":{"source":"iana"},"application/vnd.aristanetworks.swi":{"source":"iana","extensions":["swi"]},"application/vnd.artisan+json":{"source":"iana","compressible":true},"application/vnd.artsquare":{"source":"iana"},"application/vnd.astraea-software.iota":{"source":"iana","extensions":["iota"]},"application/vnd.audiograph":{"source":"iana","extensions":["aep"]},"application/vnd.autopackage":{"source":"iana"},"application/vnd.avalon+json":{"source":"iana","compressible":true},"application/vnd.avistar+xml":{"source":"iana","compressible":true},"application/vnd.balsamiq.bmml+xml":{"source":"iana","compressible":true,"extensions":["bmml"]},"application/vnd.balsamiq.bmpr":{"source":"iana"},"application/vnd.banana-accounting":{"source":"iana"},"application/vnd.bbf.usp.error":{"source":"iana"},"application/vnd.bbf.usp.msg":{"source":"iana"},"application/vnd.bbf.usp.msg+json":{"source":"iana","compressible":true},"application/vnd.bekitzur-stech+json":{"source":"iana","compressible":true},"application/vnd.bint.med-content":{"source":"iana"},"application/vnd.biopax.rdf+xml":{"source":"iana","compressible":true},"application/vnd.blink-idb-value-wrapper":{"source":"iana"},"application/vnd.blueice.multipass":{"source":"iana","extensions":["mpm"]},"application/vnd.bluetooth.ep.oob":{"source":"iana"},"application/vnd.bluetooth.le.oob":{"source":"iana"},"application/vnd.bmi":{"source":"iana","extensions":["bmi"]},"application/vnd.bpf":{"source":"iana"},"application/vnd.bpf3":{"source":"iana"},"application/vnd.businessobjects":{"source":"iana","extensions":["rep"]},"application/vnd.byu.uapi+json":{"source":"iana","compressible":true},"application/vnd.cab-jscript":{"source":"iana"},"application/vnd.canon-cpdl":{"source":"iana"},"application/vnd.canon-lips":{"source":"iana"},"application/vnd.capasystems-pg+json":{"source":"iana","compressible":true},"application/vnd.cendio.thinlinc.clientconf":{"source":"iana"},"application/vnd.century-systems.tcp_stream":{"source":"iana"},"application/vnd.chemdraw+xml":{"source":"iana","compressible":true,"extensions":["cdxml"]},"application/vnd.chess-pgn":{"source":"iana"},"application/vnd.chipnuts.karaoke-mmd":{"source":"iana","extensions":["mmd"]},"application/vnd.ciedi":{"source":"iana"},"application/vnd.cinderella":{"source":"iana","extensions":["cdy"]},"application/vnd.cirpack.isdn-ext":{"source":"iana"},"application/vnd.citationstyles.style+xml":{"source":"iana","compressible":true,"extensions":["csl"]},"application/vnd.claymore":{"source":"iana","extensions":["cla"]},"application/vnd.cloanto.rp9":{"source":"iana","extensions":["rp9"]},"application/vnd.clonk.c4group":{"source":"iana","extensions":["c4g","c4d","c4f","c4p","c4u"]},"application/vnd.cluetrust.cartomobile-config":{"source":"iana","extensions":["c11amc"]},"application/vnd.cluetrust.cartomobile-config-pkg":{"source":"iana","extensions":["c11amz"]},"application/vnd.coffeescript":{"source":"iana"},"application/vnd.collabio.xodocuments.document":{"source":"iana"},"application/vnd.collabio.xodocuments.document-template":{"source":"iana"},"application/vnd.collabio.xodocuments.presentation":{"source":"iana"},"application/vnd.collabio.xodocuments.presentation-template":{"source":"iana"},"application/vnd.collabio.xodocuments.spreadsheet":{"source":"iana"},"application/vnd.collabio.xodocuments.spreadsheet-template":{"source":"iana"},"application/vnd.collection+json":{"source":"iana","compressible":true},"application/vnd.collection.doc+json":{"source":"iana","compressible":true},"application/vnd.collection.next+json":{"source":"iana","compressible":true},"application/vnd.comicbook+zip":{"source":"iana","compressible":false},"application/vnd.comicbook-rar":{"source":"iana"},"application/vnd.commerce-battelle":{"source":"iana"},"application/vnd.commonspace":{"source":"iana","extensions":["csp"]},"application/vnd.contact.cmsg":{"source":"iana","extensions":["cdbcmsg"]},"application/vnd.coreos.ignition+json":{"source":"iana","compressible":true},"application/vnd.cosmocaller":{"source":"iana","extensions":["cmc"]},"application/vnd.crick.clicker":{"source":"iana","extensions":["clkx"]},"application/vnd.crick.clicker.keyboard":{"source":"iana","extensions":["clkk"]},"application/vnd.crick.clicker.palette":{"source":"iana","extensions":["clkp"]},"application/vnd.crick.clicker.template":{"source":"iana","extensions":["clkt"]},"application/vnd.crick.clicker.wordbank":{"source":"iana","extensions":["clkw"]},"application/vnd.criticaltools.wbs+xml":{"source":"iana","compressible":true,"extensions":["wbs"]},"application/vnd.cryptii.pipe+json":{"source":"iana","compressible":true},"application/vnd.crypto-shade-file":{"source":"iana"},"application/vnd.cryptomator.encrypted":{"source":"iana"},"application/vnd.cryptomator.vault":{"source":"iana"},"application/vnd.ctc-posml":{"source":"iana","extensions":["pml"]},"application/vnd.ctct.ws+xml":{"source":"iana","compressible":true},"application/vnd.cups-pdf":{"source":"iana"},"application/vnd.cups-postscript":{"source":"iana"},"application/vnd.cups-ppd":{"source":"iana","extensions":["ppd"]},"application/vnd.cups-raster":{"source":"iana"},"application/vnd.cups-raw":{"source":"iana"},"application/vnd.curl":{"source":"iana"},"application/vnd.curl.car":{"source":"apache","extensions":["car"]},"application/vnd.curl.pcurl":{"source":"apache","extensions":["pcurl"]},"application/vnd.cyan.dean.root+xml":{"source":"iana","compressible":true},"application/vnd.cybank":{"source":"iana"},"application/vnd.cyclonedx+json":{"source":"iana","compressible":true},"application/vnd.cyclonedx+xml":{"source":"iana","compressible":true},"application/vnd.d2l.coursepackage1p0+zip":{"source":"iana","compressible":false},"application/vnd.d3m-dataset":{"source":"iana"},"application/vnd.d3m-problem":{"source":"iana"},"application/vnd.dart":{"source":"iana","compressible":true,"extensions":["dart"]},"application/vnd.data-vision.rdz":{"source":"iana","extensions":["rdz"]},"application/vnd.datapackage+json":{"source":"iana","compressible":true},"application/vnd.dataresource+json":{"source":"iana","compressible":true},"application/vnd.dbf":{"source":"iana","extensions":["dbf"]},"application/vnd.debian.binary-package":{"source":"iana"},"application/vnd.dece.data":{"source":"iana","extensions":["uvf","uvvf","uvd","uvvd"]},"application/vnd.dece.ttml+xml":{"source":"iana","compressible":true,"extensions":["uvt","uvvt"]},"application/vnd.dece.unspecified":{"source":"iana","extensions":["uvx","uvvx"]},"application/vnd.dece.zip":{"source":"iana","extensions":["uvz","uvvz"]},"application/vnd.denovo.fcselayout-link":{"source":"iana","extensions":["fe_launch"]},"application/vnd.desmume.movie":{"source":"iana"},"application/vnd.dir-bi.plate-dl-nosuffix":{"source":"iana"},"application/vnd.dm.delegation+xml":{"source":"iana","compressible":true},"application/vnd.dna":{"source":"iana","extensions":["dna"]},"application/vnd.document+json":{"source":"iana","compressible":true},"application/vnd.dolby.mlp":{"source":"apache","extensions":["mlp"]},"application/vnd.dolby.mobile.1":{"source":"iana"},"application/vnd.dolby.mobile.2":{"source":"iana"},"application/vnd.doremir.scorecloud-binary-document":{"source":"iana"},"application/vnd.dpgraph":{"source":"iana","extensions":["dpg"]},"application/vnd.dreamfactory":{"source":"iana","extensions":["dfac"]},"application/vnd.drive+json":{"source":"iana","compressible":true},"application/vnd.ds-keypoint":{"source":"apache","extensions":["kpxx"]},"application/vnd.dtg.local":{"source":"iana"},"application/vnd.dtg.local.flash":{"source":"iana"},"application/vnd.dtg.local.html":{"source":"iana"},"application/vnd.dvb.ait":{"source":"iana","extensions":["ait"]},"application/vnd.dvb.dvbisl+xml":{"source":"iana","compressible":true},"application/vnd.dvb.dvbj":{"source":"iana"},"application/vnd.dvb.esgcontainer":{"source":"iana"},"application/vnd.dvb.ipdcdftnotifaccess":{"source":"iana"},"application/vnd.dvb.ipdcesgaccess":{"source":"iana"},"application/vnd.dvb.ipdcesgaccess2":{"source":"iana"},"application/vnd.dvb.ipdcesgpdd":{"source":"iana"},"application/vnd.dvb.ipdcroaming":{"source":"iana"},"application/vnd.dvb.iptv.alfec-base":{"source":"iana"},"application/vnd.dvb.iptv.alfec-enhancement":{"source":"iana"},"application/vnd.dvb.notif-aggregate-root+xml":{"source":"iana","compressible":true},"application/vnd.dvb.notif-container+xml":{"source":"iana","compressible":true},"application/vnd.dvb.notif-generic+xml":{"source":"iana","compressible":true},"application/vnd.dvb.notif-ia-msglist+xml":{"source":"iana","compressible":true},"application/vnd.dvb.notif-ia-registration-request+xml":{"source":"iana","compressible":true},"application/vnd.dvb.notif-ia-registration-response+xml":{"source":"iana","compressible":true},"application/vnd.dvb.notif-init+xml":{"source":"iana","compressible":true},"application/vnd.dvb.pfr":{"source":"iana"},"application/vnd.dvb.service":{"source":"iana","extensions":["svc"]},"application/vnd.dxr":{"source":"iana"},"application/vnd.dynageo":{"source":"iana","extensions":["geo"]},"application/vnd.dzr":{"source":"iana"},"application/vnd.easykaraoke.cdgdownload":{"source":"iana"},"application/vnd.ecdis-update":{"source":"iana"},"application/vnd.ecip.rlp":{"source":"iana"},"application/vnd.eclipse.ditto+json":{"source":"iana","compressible":true},"application/vnd.ecowin.chart":{"source":"iana","extensions":["mag"]},"application/vnd.ecowin.filerequest":{"source":"iana"},"application/vnd.ecowin.fileupdate":{"source":"iana"},"application/vnd.ecowin.series":{"source":"iana"},"application/vnd.ecowin.seriesrequest":{"source":"iana"},"application/vnd.ecowin.seriesupdate":{"source":"iana"},"application/vnd.efi.img":{"source":"iana"},"application/vnd.efi.iso":{"source":"iana"},"application/vnd.emclient.accessrequest+xml":{"source":"iana","compressible":true},"application/vnd.enliven":{"source":"iana","extensions":["nml"]},"application/vnd.enphase.envoy":{"source":"iana"},"application/vnd.eprints.data+xml":{"source":"iana","compressible":true},"application/vnd.epson.esf":{"source":"iana","extensions":["esf"]},"application/vnd.epson.msf":{"source":"iana","extensions":["msf"]},"application/vnd.epson.quickanime":{"source":"iana","extensions":["qam"]},"application/vnd.epson.salt":{"source":"iana","extensions":["slt"]},"application/vnd.epson.ssf":{"source":"iana","extensions":["ssf"]},"application/vnd.ericsson.quickcall":{"source":"iana"},"application/vnd.espass-espass+zip":{"source":"iana","compressible":false},"application/vnd.eszigno3+xml":{"source":"iana","compressible":true,"extensions":["es3","et3"]},"application/vnd.etsi.aoc+xml":{"source":"iana","compressible":true},"application/vnd.etsi.asic-e+zip":{"source":"iana","compressible":false},"application/vnd.etsi.asic-s+zip":{"source":"iana","compressible":false},"application/vnd.etsi.cug+xml":{"source":"iana","compressible":true},"application/vnd.etsi.iptvcommand+xml":{"source":"iana","compressible":true},"application/vnd.etsi.iptvdiscovery+xml":{"source":"iana","compressible":true},"application/vnd.etsi.iptvprofile+xml":{"source":"iana","compressible":true},"application/vnd.etsi.iptvsad-bc+xml":{"source":"iana","compressible":true},"application/vnd.etsi.iptvsad-cod+xml":{"source":"iana","compressible":true},"application/vnd.etsi.iptvsad-npvr+xml":{"source":"iana","compressible":true},"application/vnd.etsi.iptvservice+xml":{"source":"iana","compressible":true},"application/vnd.etsi.iptvsync+xml":{"source":"iana","compressible":true},"application/vnd.etsi.iptvueprofile+xml":{"source":"iana","compressible":true},"application/vnd.etsi.mcid+xml":{"source":"iana","compressible":true},"application/vnd.etsi.mheg5":{"source":"iana"},"application/vnd.etsi.overload-control-policy-dataset+xml":{"source":"iana","compressible":true},"application/vnd.etsi.pstn+xml":{"source":"iana","compressible":true},"application/vnd.etsi.sci+xml":{"source":"iana","compressible":true},"application/vnd.etsi.simservs+xml":{"source":"iana","compressible":true},"application/vnd.etsi.timestamp-token":{"source":"iana"},"application/vnd.etsi.tsl+xml":{"source":"iana","compressible":true},"application/vnd.etsi.tsl.der":{"source":"iana"},"application/vnd.eu.kasparian.car+json":{"source":"iana","compressible":true},"application/vnd.eudora.data":{"source":"iana"},"application/vnd.evolv.ecig.profile":{"source":"iana"},"application/vnd.evolv.ecig.settings":{"source":"iana"},"application/vnd.evolv.ecig.theme":{"source":"iana"},"application/vnd.exstream-empower+zip":{"source":"iana","compressible":false},"application/vnd.exstream-package":{"source":"iana"},"application/vnd.ezpix-album":{"source":"iana","extensions":["ez2"]},"application/vnd.ezpix-package":{"source":"iana","extensions":["ez3"]},"application/vnd.f-secure.mobile":{"source":"iana"},"application/vnd.familysearch.gedcom+zip":{"source":"iana","compressible":false},"application/vnd.fastcopy-disk-image":{"source":"iana"},"application/vnd.fdf":{"source":"iana","extensions":["fdf"]},"application/vnd.fdsn.mseed":{"source":"iana","extensions":["mseed"]},"application/vnd.fdsn.seed":{"source":"iana","extensions":["seed","dataless"]},"application/vnd.ffsns":{"source":"iana"},"application/vnd.ficlab.flb+zip":{"source":"iana","compressible":false},"application/vnd.filmit.zfc":{"source":"iana"},"application/vnd.fints":{"source":"iana"},"application/vnd.firemonkeys.cloudcell":{"source":"iana"},"application/vnd.flographit":{"source":"iana","extensions":["gph"]},"application/vnd.fluxtime.clip":{"source":"iana","extensions":["ftc"]},"application/vnd.font-fontforge-sfd":{"source":"iana"},"application/vnd.framemaker":{"source":"iana","extensions":["fm","frame","maker","book"]},"application/vnd.frogans.fnc":{"source":"iana","extensions":["fnc"]},"application/vnd.frogans.ltf":{"source":"iana","extensions":["ltf"]},"application/vnd.fsc.weblaunch":{"source":"iana","extensions":["fsc"]},"application/vnd.fujifilm.fb.docuworks":{"source":"iana"},"application/vnd.fujifilm.fb.docuworks.binder":{"source":"iana"},"application/vnd.fujifilm.fb.docuworks.container":{"source":"iana"},"application/vnd.fujifilm.fb.jfi+xml":{"source":"iana","compressible":true},"application/vnd.fujitsu.oasys":{"source":"iana","extensions":["oas"]},"application/vnd.fujitsu.oasys2":{"source":"iana","extensions":["oa2"]},"application/vnd.fujitsu.oasys3":{"source":"iana","extensions":["oa3"]},"application/vnd.fujitsu.oasysgp":{"source":"iana","extensions":["fg5"]},"application/vnd.fujitsu.oasysprs":{"source":"iana","extensions":["bh2"]},"application/vnd.fujixerox.art-ex":{"source":"iana"},"application/vnd.fujixerox.art4":{"source":"iana"},"application/vnd.fujixerox.ddd":{"source":"iana","extensions":["ddd"]},"application/vnd.fujixerox.docuworks":{"source":"iana","extensions":["xdw"]},"application/vnd.fujixerox.docuworks.binder":{"source":"iana","extensions":["xbd"]},"application/vnd.fujixerox.docuworks.container":{"source":"iana"},"application/vnd.fujixerox.hbpl":{"source":"iana"},"application/vnd.fut-misnet":{"source":"iana"},"application/vnd.futoin+cbor":{"source":"iana"},"application/vnd.futoin+json":{"source":"iana","compressible":true},"application/vnd.fuzzysheet":{"source":"iana","extensions":["fzs"]},"application/vnd.genomatix.tuxedo":{"source":"iana","extensions":["txd"]},"application/vnd.gentics.grd+json":{"source":"iana","compressible":true},"application/vnd.geo+json":{"source":"iana","compressible":true},"application/vnd.geocube+xml":{"source":"iana","compressible":true},"application/vnd.geogebra.file":{"source":"iana","extensions":["ggb"]},"application/vnd.geogebra.slides":{"source":"iana"},"application/vnd.geogebra.tool":{"source":"iana","extensions":["ggt"]},"application/vnd.geometry-explorer":{"source":"iana","extensions":["gex","gre"]},"application/vnd.geonext":{"source":"iana","extensions":["gxt"]},"application/vnd.geoplan":{"source":"iana","extensions":["g2w"]},"application/vnd.geospace":{"source":"iana","extensions":["g3w"]},"application/vnd.gerber":{"source":"iana"},"application/vnd.globalplatform.card-content-mgt":{"source":"iana"},"application/vnd.globalplatform.card-content-mgt-response":{"source":"iana"},"application/vnd.gmx":{"source":"iana","extensions":["gmx"]},"application/vnd.google-apps.document":{"compressible":false,"extensions":["gdoc"]},"application/vnd.google-apps.presentation":{"compressible":false,"extensions":["gslides"]},"application/vnd.google-apps.spreadsheet":{"compressible":false,"extensions":["gsheet"]},"application/vnd.google-earth.kml+xml":{"source":"iana","compressible":true,"extensions":["kml"]},"application/vnd.google-earth.kmz":{"source":"iana","compressible":false,"extensions":["kmz"]},"application/vnd.gov.sk.e-form+xml":{"source":"iana","compressible":true},"application/vnd.gov.sk.e-form+zip":{"source":"iana","compressible":false},"application/vnd.gov.sk.xmldatacontainer+xml":{"source":"iana","compressible":true},"application/vnd.grafeq":{"source":"iana","extensions":["gqf","gqs"]},"application/vnd.gridmp":{"source":"iana"},"application/vnd.groove-account":{"source":"iana","extensions":["gac"]},"application/vnd.groove-help":{"source":"iana","extensions":["ghf"]},"application/vnd.groove-identity-message":{"source":"iana","extensions":["gim"]},"application/vnd.groove-injector":{"source":"iana","extensions":["grv"]},"application/vnd.groove-tool-message":{"source":"iana","extensions":["gtm"]},"application/vnd.groove-tool-template":{"source":"iana","extensions":["tpl"]},"application/vnd.groove-vcard":{"source":"iana","extensions":["vcg"]},"application/vnd.hal+json":{"source":"iana","compressible":true},"application/vnd.hal+xml":{"source":"iana","compressible":true,"extensions":["hal"]},"application/vnd.handheld-entertainment+xml":{"source":"iana","compressible":true,"extensions":["zmm"]},"application/vnd.hbci":{"source":"iana","extensions":["hbci"]},"application/vnd.hc+json":{"source":"iana","compressible":true},"application/vnd.hcl-bireports":{"source":"iana"},"application/vnd.hdt":{"source":"iana"},"application/vnd.heroku+json":{"source":"iana","compressible":true},"application/vnd.hhe.lesson-player":{"source":"iana","extensions":["les"]},"application/vnd.hl7cda+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/vnd.hl7v2+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/vnd.hp-hpgl":{"source":"iana","extensions":["hpgl"]},"application/vnd.hp-hpid":{"source":"iana","extensions":["hpid"]},"application/vnd.hp-hps":{"source":"iana","extensions":["hps"]},"application/vnd.hp-jlyt":{"source":"iana","extensions":["jlt"]},"application/vnd.hp-pcl":{"source":"iana","extensions":["pcl"]},"application/vnd.hp-pclxl":{"source":"iana","extensions":["pclxl"]},"application/vnd.httphone":{"source":"iana"},"application/vnd.hydrostatix.sof-data":{"source":"iana","extensions":["sfd-hdstx"]},"application/vnd.hyper+json":{"source":"iana","compressible":true},"application/vnd.hyper-item+json":{"source":"iana","compressible":true},"application/vnd.hyperdrive+json":{"source":"iana","compressible":true},"application/vnd.hzn-3d-crossword":{"source":"iana"},"application/vnd.ibm.afplinedata":{"source":"iana"},"application/vnd.ibm.electronic-media":{"source":"iana"},"application/vnd.ibm.minipay":{"source":"iana","extensions":["mpy"]},"application/vnd.ibm.modcap":{"source":"iana","extensions":["afp","listafp","list3820"]},"application/vnd.ibm.rights-management":{"source":"iana","extensions":["irm"]},"application/vnd.ibm.secure-container":{"source":"iana","extensions":["sc"]},"application/vnd.iccprofile":{"source":"iana","extensions":["icc","icm"]},"application/vnd.ieee.1905":{"source":"iana"},"application/vnd.igloader":{"source":"iana","extensions":["igl"]},"application/vnd.imagemeter.folder+zip":{"source":"iana","compressible":false},"application/vnd.imagemeter.image+zip":{"source":"iana","compressible":false},"application/vnd.immervision-ivp":{"source":"iana","extensions":["ivp"]},"application/vnd.immervision-ivu":{"source":"iana","extensions":["ivu"]},"application/vnd.ims.imsccv1p1":{"source":"iana"},"application/vnd.ims.imsccv1p2":{"source":"iana"},"application/vnd.ims.imsccv1p3":{"source":"iana"},"application/vnd.ims.lis.v2.result+json":{"source":"iana","compressible":true},"application/vnd.ims.lti.v2.toolconsumerprofile+json":{"source":"iana","compressible":true},"application/vnd.ims.lti.v2.toolproxy+json":{"source":"iana","compressible":true},"application/vnd.ims.lti.v2.toolproxy.id+json":{"source":"iana","compressible":true},"application/vnd.ims.lti.v2.toolsettings+json":{"source":"iana","compressible":true},"application/vnd.ims.lti.v2.toolsettings.simple+json":{"source":"iana","compressible":true},"application/vnd.informedcontrol.rms+xml":{"source":"iana","compressible":true},"application/vnd.informix-visionary":{"source":"iana"},"application/vnd.infotech.project":{"source":"iana"},"application/vnd.infotech.project+xml":{"source":"iana","compressible":true},"application/vnd.innopath.wamp.notification":{"source":"iana"},"application/vnd.insors.igm":{"source":"iana","extensions":["igm"]},"application/vnd.intercon.formnet":{"source":"iana","extensions":["xpw","xpx"]},"application/vnd.intergeo":{"source":"iana","extensions":["i2g"]},"application/vnd.intertrust.digibox":{"source":"iana"},"application/vnd.intertrust.nncp":{"source":"iana"},"application/vnd.intu.qbo":{"source":"iana","extensions":["qbo"]},"application/vnd.intu.qfx":{"source":"iana","extensions":["qfx"]},"application/vnd.iptc.g2.catalogitem+xml":{"source":"iana","compressible":true},"application/vnd.iptc.g2.conceptitem+xml":{"source":"iana","compressible":true},"application/vnd.iptc.g2.knowledgeitem+xml":{"source":"iana","compressible":true},"application/vnd.iptc.g2.newsitem+xml":{"source":"iana","compressible":true},"application/vnd.iptc.g2.newsmessage+xml":{"source":"iana","compressible":true},"application/vnd.iptc.g2.packageitem+xml":{"source":"iana","compressible":true},"application/vnd.iptc.g2.planningitem+xml":{"source":"iana","compressible":true},"application/vnd.ipunplugged.rcprofile":{"source":"iana","extensions":["rcprofile"]},"application/vnd.irepository.package+xml":{"source":"iana","compressible":true,"extensions":["irp"]},"application/vnd.is-xpr":{"source":"iana","extensions":["xpr"]},"application/vnd.isac.fcs":{"source":"iana","extensions":["fcs"]},"application/vnd.iso11783-10+zip":{"source":"iana","compressible":false},"application/vnd.jam":{"source":"iana","extensions":["jam"]},"application/vnd.japannet-directory-service":{"source":"iana"},"application/vnd.japannet-jpnstore-wakeup":{"source":"iana"},"application/vnd.japannet-payment-wakeup":{"source":"iana"},"application/vnd.japannet-registration":{"source":"iana"},"application/vnd.japannet-registration-wakeup":{"source":"iana"},"application/vnd.japannet-setstore-wakeup":{"source":"iana"},"application/vnd.japannet-verification":{"source":"iana"},"application/vnd.japannet-verification-wakeup":{"source":"iana"},"application/vnd.jcp.javame.midlet-rms":{"source":"iana","extensions":["rms"]},"application/vnd.jisp":{"source":"iana","extensions":["jisp"]},"application/vnd.joost.joda-archive":{"source":"iana","extensions":["joda"]},"application/vnd.jsk.isdn-ngn":{"source":"iana"},"application/vnd.kahootz":{"source":"iana","extensions":["ktz","ktr"]},"application/vnd.kde.karbon":{"source":"iana","extensions":["karbon"]},"application/vnd.kde.kchart":{"source":"iana","extensions":["chrt"]},"application/vnd.kde.kformula":{"source":"iana","extensions":["kfo"]},"application/vnd.kde.kivio":{"source":"iana","extensions":["flw"]},"application/vnd.kde.kontour":{"source":"iana","extensions":["kon"]},"application/vnd.kde.kpresenter":{"source":"iana","extensions":["kpr","kpt"]},"application/vnd.kde.kspread":{"source":"iana","extensions":["ksp"]},"application/vnd.kde.kword":{"source":"iana","extensions":["kwd","kwt"]},"application/vnd.kenameaapp":{"source":"iana","extensions":["htke"]},"application/vnd.kidspiration":{"source":"iana","extensions":["kia"]},"application/vnd.kinar":{"source":"iana","extensions":["kne","knp"]},"application/vnd.koan":{"source":"iana","extensions":["skp","skd","skt","skm"]},"application/vnd.kodak-descriptor":{"source":"iana","extensions":["sse"]},"application/vnd.las":{"source":"iana"},"application/vnd.las.las+json":{"source":"iana","compressible":true},"application/vnd.las.las+xml":{"source":"iana","compressible":true,"extensions":["lasxml"]},"application/vnd.laszip":{"source":"iana"},"application/vnd.leap+json":{"source":"iana","compressible":true},"application/vnd.liberty-request+xml":{"source":"iana","compressible":true},"application/vnd.llamagraphics.life-balance.desktop":{"source":"iana","extensions":["lbd"]},"application/vnd.llamagraphics.life-balance.exchange+xml":{"source":"iana","compressible":true,"extensions":["lbe"]},"application/vnd.logipipe.circuit+zip":{"source":"iana","compressible":false},"application/vnd.loom":{"source":"iana"},"application/vnd.lotus-1-2-3":{"source":"iana","extensions":["123"]},"application/vnd.lotus-approach":{"source":"iana","extensions":["apr"]},"application/vnd.lotus-freelance":{"source":"iana","extensions":["pre"]},"application/vnd.lotus-notes":{"source":"iana","extensions":["nsf"]},"application/vnd.lotus-organizer":{"source":"iana","extensions":["org"]},"application/vnd.lotus-screencam":{"source":"iana","extensions":["scm"]},"application/vnd.lotus-wordpro":{"source":"iana","extensions":["lwp"]},"application/vnd.macports.portpkg":{"source":"iana","extensions":["portpkg"]},"application/vnd.mapbox-vector-tile":{"source":"iana","extensions":["mvt"]},"application/vnd.marlin.drm.actiontoken+xml":{"source":"iana","compressible":true},"application/vnd.marlin.drm.conftoken+xml":{"source":"iana","compressible":true},"application/vnd.marlin.drm.license+xml":{"source":"iana","compressible":true},"application/vnd.marlin.drm.mdcf":{"source":"iana"},"application/vnd.mason+json":{"source":"iana","compressible":true},"application/vnd.maxar.archive.3tz+zip":{"source":"iana","compressible":false},"application/vnd.maxmind.maxmind-db":{"source":"iana"},"application/vnd.mcd":{"source":"iana","extensions":["mcd"]},"application/vnd.medcalcdata":{"source":"iana","extensions":["mc1"]},"application/vnd.mediastation.cdkey":{"source":"iana","extensions":["cdkey"]},"application/vnd.meridian-slingshot":{"source":"iana"},"application/vnd.mfer":{"source":"iana","extensions":["mwf"]},"application/vnd.mfmp":{"source":"iana","extensions":["mfm"]},"application/vnd.micro+json":{"source":"iana","compressible":true},"application/vnd.micrografx.flo":{"source":"iana","extensions":["flo"]},"application/vnd.micrografx.igx":{"source":"iana","extensions":["igx"]},"application/vnd.microsoft.portable-executable":{"source":"iana"},"application/vnd.microsoft.windows.thumbnail-cache":{"source":"iana"},"application/vnd.miele+json":{"source":"iana","compressible":true},"application/vnd.mif":{"source":"iana","extensions":["mif"]},"application/vnd.minisoft-hp3000-save":{"source":"iana"},"application/vnd.mitsubishi.misty-guard.trustweb":{"source":"iana"},"application/vnd.mobius.daf":{"source":"iana","extensions":["daf"]},"application/vnd.mobius.dis":{"source":"iana","extensions":["dis"]},"application/vnd.mobius.mbk":{"source":"iana","extensions":["mbk"]},"application/vnd.mobius.mqy":{"source":"iana","extensions":["mqy"]},"application/vnd.mobius.msl":{"source":"iana","extensions":["msl"]},"application/vnd.mobius.plc":{"source":"iana","extensions":["plc"]},"application/vnd.mobius.txf":{"source":"iana","extensions":["txf"]},"application/vnd.mophun.application":{"source":"iana","extensions":["mpn"]},"application/vnd.mophun.certificate":{"source":"iana","extensions":["mpc"]},"application/vnd.motorola.flexsuite":{"source":"iana"},"application/vnd.motorola.flexsuite.adsi":{"source":"iana"},"application/vnd.motorola.flexsuite.fis":{"source":"iana"},"application/vnd.motorola.flexsuite.gotap":{"source":"iana"},"application/vnd.motorola.flexsuite.kmr":{"source":"iana"},"application/vnd.motorola.flexsuite.ttc":{"source":"iana"},"application/vnd.motorola.flexsuite.wem":{"source":"iana"},"application/vnd.motorola.iprm":{"source":"iana"},"application/vnd.mozilla.xul+xml":{"source":"iana","compressible":true,"extensions":["xul"]},"application/vnd.ms-3mfdocument":{"source":"iana"},"application/vnd.ms-artgalry":{"source":"iana","extensions":["cil"]},"application/vnd.ms-asf":{"source":"iana"},"application/vnd.ms-cab-compressed":{"source":"iana","extensions":["cab"]},"application/vnd.ms-color.iccprofile":{"source":"apache"},"application/vnd.ms-excel":{"source":"iana","compressible":false,"extensions":["xls","xlm","xla","xlc","xlt","xlw"]},"application/vnd.ms-excel.addin.macroenabled.12":{"source":"iana","extensions":["xlam"]},"application/vnd.ms-excel.sheet.binary.macroenabled.12":{"source":"iana","extensions":["xlsb"]},"application/vnd.ms-excel.sheet.macroenabled.12":{"source":"iana","extensions":["xlsm"]},"application/vnd.ms-excel.template.macroenabled.12":{"source":"iana","extensions":["xltm"]},"application/vnd.ms-fontobject":{"source":"iana","compressible":true,"extensions":["eot"]},"application/vnd.ms-htmlhelp":{"source":"iana","extensions":["chm"]},"application/vnd.ms-ims":{"source":"iana","extensions":["ims"]},"application/vnd.ms-lrm":{"source":"iana","extensions":["lrm"]},"application/vnd.ms-office.activex+xml":{"source":"iana","compressible":true},"application/vnd.ms-officetheme":{"source":"iana","extensions":["thmx"]},"application/vnd.ms-opentype":{"source":"apache","compressible":true},"application/vnd.ms-outlook":{"compressible":false,"extensions":["msg"]},"application/vnd.ms-package.obfuscated-opentype":{"source":"apache"},"application/vnd.ms-pki.seccat":{"source":"apache","extensions":["cat"]},"application/vnd.ms-pki.stl":{"source":"apache","extensions":["stl"]},"application/vnd.ms-playready.initiator+xml":{"source":"iana","compressible":true},"application/vnd.ms-powerpoint":{"source":"iana","compressible":false,"extensions":["ppt","pps","pot"]},"application/vnd.ms-powerpoint.addin.macroenabled.12":{"source":"iana","extensions":["ppam"]},"application/vnd.ms-powerpoint.presentation.macroenabled.12":{"source":"iana","extensions":["pptm"]},"application/vnd.ms-powerpoint.slide.macroenabled.12":{"source":"iana","extensions":["sldm"]},"application/vnd.ms-powerpoint.slideshow.macroenabled.12":{"source":"iana","extensions":["ppsm"]},"application/vnd.ms-powerpoint.template.macroenabled.12":{"source":"iana","extensions":["potm"]},"application/vnd.ms-printdevicecapabilities+xml":{"source":"iana","compressible":true},"application/vnd.ms-printing.printticket+xml":{"source":"apache","compressible":true},"application/vnd.ms-printschematicket+xml":{"source":"iana","compressible":true},"application/vnd.ms-project":{"source":"iana","extensions":["mpp","mpt"]},"application/vnd.ms-tnef":{"source":"iana"},"application/vnd.ms-windows.devicepairing":{"source":"iana"},"application/vnd.ms-windows.nwprinting.oob":{"source":"iana"},"application/vnd.ms-windows.printerpairing":{"source":"iana"},"application/vnd.ms-windows.wsd.oob":{"source":"iana"},"application/vnd.ms-wmdrm.lic-chlg-req":{"source":"iana"},"application/vnd.ms-wmdrm.lic-resp":{"source":"iana"},"application/vnd.ms-wmdrm.meter-chlg-req":{"source":"iana"},"application/vnd.ms-wmdrm.meter-resp":{"source":"iana"},"application/vnd.ms-word.document.macroenabled.12":{"source":"iana","extensions":["docm"]},"application/vnd.ms-word.template.macroenabled.12":{"source":"iana","extensions":["dotm"]},"application/vnd.ms-works":{"source":"iana","extensions":["wps","wks","wcm","wdb"]},"application/vnd.ms-wpl":{"source":"iana","extensions":["wpl"]},"application/vnd.ms-xpsdocument":{"source":"iana","compressible":false,"extensions":["xps"]},"application/vnd.msa-disk-image":{"source":"iana"},"application/vnd.mseq":{"source":"iana","extensions":["mseq"]},"application/vnd.msign":{"source":"iana"},"application/vnd.multiad.creator":{"source":"iana"},"application/vnd.multiad.creator.cif":{"source":"iana"},"application/vnd.music-niff":{"source":"iana"},"application/vnd.musician":{"source":"iana","extensions":["mus"]},"application/vnd.muvee.style":{"source":"iana","extensions":["msty"]},"application/vnd.mynfc":{"source":"iana","extensions":["taglet"]},"application/vnd.nacamar.ybrid+json":{"source":"iana","compressible":true},"application/vnd.ncd.control":{"source":"iana"},"application/vnd.ncd.reference":{"source":"iana"},"application/vnd.nearst.inv+json":{"source":"iana","compressible":true},"application/vnd.nebumind.line":{"source":"iana"},"application/vnd.nervana":{"source":"iana"},"application/vnd.netfpx":{"source":"iana"},"application/vnd.neurolanguage.nlu":{"source":"iana","extensions":["nlu"]},"application/vnd.nimn":{"source":"iana"},"application/vnd.nintendo.nitro.rom":{"source":"iana"},"application/vnd.nintendo.snes.rom":{"source":"iana"},"application/vnd.nitf":{"source":"iana","extensions":["ntf","nitf"]},"application/vnd.noblenet-directory":{"source":"iana","extensions":["nnd"]},"application/vnd.noblenet-sealer":{"source":"iana","extensions":["nns"]},"application/vnd.noblenet-web":{"source":"iana","extensions":["nnw"]},"application/vnd.nokia.catalogs":{"source":"iana"},"application/vnd.nokia.conml+wbxml":{"source":"iana"},"application/vnd.nokia.conml+xml":{"source":"iana","compressible":true},"application/vnd.nokia.iptv.config+xml":{"source":"iana","compressible":true},"application/vnd.nokia.isds-radio-presets":{"source":"iana"},"application/vnd.nokia.landmark+wbxml":{"source":"iana"},"application/vnd.nokia.landmark+xml":{"source":"iana","compressible":true},"application/vnd.nokia.landmarkcollection+xml":{"source":"iana","compressible":true},"application/vnd.nokia.n-gage.ac+xml":{"source":"iana","compressible":true,"extensions":["ac"]},"application/vnd.nokia.n-gage.data":{"source":"iana","extensions":["ngdat"]},"application/vnd.nokia.n-gage.symbian.install":{"source":"iana","extensions":["n-gage"]},"application/vnd.nokia.ncd":{"source":"iana"},"application/vnd.nokia.pcd+wbxml":{"source":"iana"},"application/vnd.nokia.pcd+xml":{"source":"iana","compressible":true},"application/vnd.nokia.radio-preset":{"source":"iana","extensions":["rpst"]},"application/vnd.nokia.radio-presets":{"source":"iana","extensions":["rpss"]},"application/vnd.novadigm.edm":{"source":"iana","extensions":["edm"]},"application/vnd.novadigm.edx":{"source":"iana","extensions":["edx"]},"application/vnd.novadigm.ext":{"source":"iana","extensions":["ext"]},"application/vnd.ntt-local.content-share":{"source":"iana"},"application/vnd.ntt-local.file-transfer":{"source":"iana"},"application/vnd.ntt-local.ogw_remote-access":{"source":"iana"},"application/vnd.ntt-local.sip-ta_remote":{"source":"iana"},"application/vnd.ntt-local.sip-ta_tcp_stream":{"source":"iana"},"application/vnd.oasis.opendocument.chart":{"source":"iana","extensions":["odc"]},"application/vnd.oasis.opendocument.chart-template":{"source":"iana","extensions":["otc"]},"application/vnd.oasis.opendocument.database":{"source":"iana","extensions":["odb"]},"application/vnd.oasis.opendocument.formula":{"source":"iana","extensions":["odf"]},"application/vnd.oasis.opendocument.formula-template":{"source":"iana","extensions":["odft"]},"application/vnd.oasis.opendocument.graphics":{"source":"iana","compressible":false,"extensions":["odg"]},"application/vnd.oasis.opendocument.graphics-template":{"source":"iana","extensions":["otg"]},"application/vnd.oasis.opendocument.image":{"source":"iana","extensions":["odi"]},"application/vnd.oasis.opendocument.image-template":{"source":"iana","extensions":["oti"]},"application/vnd.oasis.opendocument.presentation":{"source":"iana","compressible":false,"extensions":["odp"]},"application/vnd.oasis.opendocument.presentation-template":{"source":"iana","extensions":["otp"]},"application/vnd.oasis.opendocument.spreadsheet":{"source":"iana","compressible":false,"extensions":["ods"]},"application/vnd.oasis.opendocument.spreadsheet-template":{"source":"iana","extensions":["ots"]},"application/vnd.oasis.opendocument.text":{"source":"iana","compressible":false,"extensions":["odt"]},"application/vnd.oasis.opendocument.text-master":{"source":"iana","extensions":["odm"]},"application/vnd.oasis.opendocument.text-template":{"source":"iana","extensions":["ott"]},"application/vnd.oasis.opendocument.text-web":{"source":"iana","extensions":["oth"]},"application/vnd.obn":{"source":"iana"},"application/vnd.ocf+cbor":{"source":"iana"},"application/vnd.oci.image.manifest.v1+json":{"source":"iana","compressible":true},"application/vnd.oftn.l10n+json":{"source":"iana","compressible":true},"application/vnd.oipf.contentaccessdownload+xml":{"source":"iana","compressible":true},"application/vnd.oipf.contentaccessstreaming+xml":{"source":"iana","compressible":true},"application/vnd.oipf.cspg-hexbinary":{"source":"iana"},"application/vnd.oipf.dae.svg+xml":{"source":"iana","compressible":true},"application/vnd.oipf.dae.xhtml+xml":{"source":"iana","compressible":true},"application/vnd.oipf.mippvcontrolmessage+xml":{"source":"iana","compressible":true},"application/vnd.oipf.pae.gem":{"source":"iana"},"application/vnd.oipf.spdiscovery+xml":{"source":"iana","compressible":true},"application/vnd.oipf.spdlist+xml":{"source":"iana","compressible":true},"application/vnd.oipf.ueprofile+xml":{"source":"iana","compressible":true},"application/vnd.oipf.userprofile+xml":{"source":"iana","compressible":true},"application/vnd.olpc-sugar":{"source":"iana","extensions":["xo"]},"application/vnd.oma-scws-config":{"source":"iana"},"application/vnd.oma-scws-http-request":{"source":"iana"},"application/vnd.oma-scws-http-response":{"source":"iana"},"application/vnd.oma.bcast.associated-procedure-parameter+xml":{"source":"iana","compressible":true},"application/vnd.oma.bcast.drm-trigger+xml":{"source":"iana","compressible":true},"application/vnd.oma.bcast.imd+xml":{"source":"iana","compressible":true},"application/vnd.oma.bcast.ltkm":{"source":"iana"},"application/vnd.oma.bcast.notification+xml":{"source":"iana","compressible":true},"application/vnd.oma.bcast.provisioningtrigger":{"source":"iana"},"application/vnd.oma.bcast.sgboot":{"source":"iana"},"application/vnd.oma.bcast.sgdd+xml":{"source":"iana","compressible":true},"application/vnd.oma.bcast.sgdu":{"source":"iana"},"application/vnd.oma.bcast.simple-symbol-container":{"source":"iana"},"application/vnd.oma.bcast.smartcard-trigger+xml":{"source":"iana","compressible":true},"application/vnd.oma.bcast.sprov+xml":{"source":"iana","compressible":true},"application/vnd.oma.bcast.stkm":{"source":"iana"},"application/vnd.oma.cab-address-book+xml":{"source":"iana","compressible":true},"application/vnd.oma.cab-feature-handler+xml":{"source":"iana","compressible":true},"application/vnd.oma.cab-pcc+xml":{"source":"iana","compressible":true},"application/vnd.oma.cab-subs-invite+xml":{"source":"iana","compressible":true},"application/vnd.oma.cab-user-prefs+xml":{"source":"iana","compressible":true},"application/vnd.oma.dcd":{"source":"iana"},"application/vnd.oma.dcdc":{"source":"iana"},"application/vnd.oma.dd2+xml":{"source":"iana","compressible":true,"extensions":["dd2"]},"application/vnd.oma.drm.risd+xml":{"source":"iana","compressible":true},"application/vnd.oma.group-usage-list+xml":{"source":"iana","compressible":true},"application/vnd.oma.lwm2m+cbor":{"source":"iana"},"application/vnd.oma.lwm2m+json":{"source":"iana","compressible":true},"application/vnd.oma.lwm2m+tlv":{"source":"iana"},"application/vnd.oma.pal+xml":{"source":"iana","compressible":true},"application/vnd.oma.poc.detailed-progress-report+xml":{"source":"iana","compressible":true},"application/vnd.oma.poc.final-report+xml":{"source":"iana","compressible":true},"application/vnd.oma.poc.groups+xml":{"source":"iana","compressible":true},"application/vnd.oma.poc.invocation-descriptor+xml":{"source":"iana","compressible":true},"application/vnd.oma.poc.optimized-progress-report+xml":{"source":"iana","compressible":true},"application/vnd.oma.push":{"source":"iana"},"application/vnd.oma.scidm.messages+xml":{"source":"iana","compressible":true},"application/vnd.oma.xcap-directory+xml":{"source":"iana","compressible":true},"application/vnd.omads-email+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/vnd.omads-file+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/vnd.omads-folder+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/vnd.omaloc-supl-init":{"source":"iana"},"application/vnd.onepager":{"source":"iana"},"application/vnd.onepagertamp":{"source":"iana"},"application/vnd.onepagertamx":{"source":"iana"},"application/vnd.onepagertat":{"source":"iana"},"application/vnd.onepagertatp":{"source":"iana"},"application/vnd.onepagertatx":{"source":"iana"},"application/vnd.openblox.game+xml":{"source":"iana","compressible":true,"extensions":["obgx"]},"application/vnd.openblox.game-binary":{"source":"iana"},"application/vnd.openeye.oeb":{"source":"iana"},"application/vnd.openofficeorg.extension":{"source":"apache","extensions":["oxt"]},"application/vnd.openstreetmap.data+xml":{"source":"iana","compressible":true,"extensions":["osm"]},"application/vnd.opentimestamps.ots":{"source":"iana"},"application/vnd.openxmlformats-officedocument.custom-properties+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.customxmlproperties+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.drawing+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.drawingml.chart+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.drawingml.chartshapes+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.drawingml.diagramcolors+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.drawingml.diagramdata+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.drawingml.diagramlayout+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.drawingml.diagramstyle+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.extended-properties+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.commentauthors+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.comments+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.handoutmaster+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.notesmaster+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.notesslide+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.presentation":{"source":"iana","compressible":false,"extensions":["pptx"]},"application/vnd.openxmlformats-officedocument.presentationml.presentation.main+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.presprops+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.slide":{"source":"iana","extensions":["sldx"]},"application/vnd.openxmlformats-officedocument.presentationml.slide+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.slidelayout+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.slidemaster+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.slideshow":{"source":"iana","extensions":["ppsx"]},"application/vnd.openxmlformats-officedocument.presentationml.slideshow.main+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.slideupdateinfo+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.tablestyles+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.tags+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.template":{"source":"iana","extensions":["potx"]},"application/vnd.openxmlformats-officedocument.presentationml.template.main+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.presentationml.viewprops+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.calcchain+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.chartsheet+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.comments+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.connections+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.dialogsheet+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.externallink+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.pivotcachedefinition+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.pivotcacherecords+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.pivottable+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.querytable+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.revisionheaders+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.revisionlog+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.sharedstrings+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":{"source":"iana","compressible":false,"extensions":["xlsx"]},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheetmetadata+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.table+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.tablesinglecells+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.template":{"source":"iana","extensions":["xltx"]},"application/vnd.openxmlformats-officedocument.spreadsheetml.template.main+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.usernames+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.volatiledependencies+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.theme+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.themeoverride+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.vmldrawing":{"source":"iana"},"application/vnd.openxmlformats-officedocument.wordprocessingml.comments+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.document":{"source":"iana","compressible":false,"extensions":["docx"]},"application/vnd.openxmlformats-officedocument.wordprocessingml.document.glossary+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.document.main+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.endnotes+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.fonttable+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.footer+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.footnotes+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.numbering+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.settings+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.styles+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.template":{"source":"iana","extensions":["dotx"]},"application/vnd.openxmlformats-officedocument.wordprocessingml.template.main+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-officedocument.wordprocessingml.websettings+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-package.core-properties+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-package.digital-signature-xmlsignature+xml":{"source":"iana","compressible":true},"application/vnd.openxmlformats-package.relationships+xml":{"source":"iana","compressible":true},"application/vnd.oracle.resource+json":{"source":"iana","compressible":true},"application/vnd.orange.indata":{"source":"iana"},"application/vnd.osa.netdeploy":{"source":"iana"},"application/vnd.osgeo.mapguide.package":{"source":"iana","extensions":["mgp"]},"application/vnd.osgi.bundle":{"source":"iana"},"application/vnd.osgi.dp":{"source":"iana","extensions":["dp"]},"application/vnd.osgi.subsystem":{"source":"iana","extensions":["esa"]},"application/vnd.otps.ct-kip+xml":{"source":"iana","compressible":true},"application/vnd.oxli.countgraph":{"source":"iana"},"application/vnd.pagerduty+json":{"source":"iana","compressible":true},"application/vnd.palm":{"source":"iana","extensions":["pdb","pqa","oprc"]},"application/vnd.panoply":{"source":"iana"},"application/vnd.paos.xml":{"source":"iana"},"application/vnd.patentdive":{"source":"iana"},"application/vnd.patientecommsdoc":{"source":"iana"},"application/vnd.pawaafile":{"source":"iana","extensions":["paw"]},"application/vnd.pcos":{"source":"iana"},"application/vnd.pg.format":{"source":"iana","extensions":["str"]},"application/vnd.pg.osasli":{"source":"iana","extensions":["ei6"]},"application/vnd.piaccess.application-licence":{"source":"iana"},"application/vnd.picsel":{"source":"iana","extensions":["efif"]},"application/vnd.pmi.widget":{"source":"iana","extensions":["wg"]},"application/vnd.poc.group-advertisement+xml":{"source":"iana","compressible":true},"application/vnd.pocketlearn":{"source":"iana","extensions":["plf"]},"application/vnd.powerbuilder6":{"source":"iana","extensions":["pbd"]},"application/vnd.powerbuilder6-s":{"source":"iana"},"application/vnd.powerbuilder7":{"source":"iana"},"application/vnd.powerbuilder7-s":{"source":"iana"},"application/vnd.powerbuilder75":{"source":"iana"},"application/vnd.powerbuilder75-s":{"source":"iana"},"application/vnd.preminet":{"source":"iana"},"application/vnd.previewsystems.box":{"source":"iana","extensions":["box"]},"application/vnd.proteus.magazine":{"source":"iana","extensions":["mgz"]},"application/vnd.psfs":{"source":"iana"},"application/vnd.publishare-delta-tree":{"source":"iana","extensions":["qps"]},"application/vnd.pvi.ptid1":{"source":"iana","extensions":["ptid"]},"application/vnd.pwg-multiplexed":{"source":"iana"},"application/vnd.pwg-xhtml-print+xml":{"source":"iana","compressible":true},"application/vnd.qualcomm.brew-app-res":{"source":"iana"},"application/vnd.quarantainenet":{"source":"iana"},"application/vnd.quark.quarkxpress":{"source":"iana","extensions":["qxd","qxt","qwd","qwt","qxl","qxb"]},"application/vnd.quobject-quoxdocument":{"source":"iana"},"application/vnd.radisys.moml+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-audit+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-audit-conf+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-audit-conn+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-audit-dialog+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-audit-stream+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-conf+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-dialog+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-dialog-base+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-dialog-fax-detect+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-dialog-fax-sendrecv+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-dialog-group+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-dialog-speech+xml":{"source":"iana","compressible":true},"application/vnd.radisys.msml-dialog-transform+xml":{"source":"iana","compressible":true},"application/vnd.rainstor.data":{"source":"iana"},"application/vnd.rapid":{"source":"iana"},"application/vnd.rar":{"source":"iana","extensions":["rar"]},"application/vnd.realvnc.bed":{"source":"iana","extensions":["bed"]},"application/vnd.recordare.musicxml":{"source":"iana","extensions":["mxl"]},"application/vnd.recordare.musicxml+xml":{"source":"iana","compressible":true,"extensions":["musicxml"]},"application/vnd.renlearn.rlprint":{"source":"iana"},"application/vnd.resilient.logic":{"source":"iana"},"application/vnd.restful+json":{"source":"iana","compressible":true},"application/vnd.rig.cryptonote":{"source":"iana","extensions":["cryptonote"]},"application/vnd.rim.cod":{"source":"apache","extensions":["cod"]},"application/vnd.rn-realmedia":{"source":"apache","extensions":["rm"]},"application/vnd.rn-realmedia-vbr":{"source":"apache","extensions":["rmvb"]},"application/vnd.route66.link66+xml":{"source":"iana","compressible":true,"extensions":["link66"]},"application/vnd.rs-274x":{"source":"iana"},"application/vnd.ruckus.download":{"source":"iana"},"application/vnd.s3sms":{"source":"iana"},"application/vnd.sailingtracker.track":{"source":"iana","extensions":["st"]},"application/vnd.sar":{"source":"iana"},"application/vnd.sbm.cid":{"source":"iana"},"application/vnd.sbm.mid2":{"source":"iana"},"application/vnd.scribus":{"source":"iana"},"application/vnd.sealed.3df":{"source":"iana"},"application/vnd.sealed.csf":{"source":"iana"},"application/vnd.sealed.doc":{"source":"iana"},"application/vnd.sealed.eml":{"source":"iana"},"application/vnd.sealed.mht":{"source":"iana"},"application/vnd.sealed.net":{"source":"iana"},"application/vnd.sealed.ppt":{"source":"iana"},"application/vnd.sealed.tiff":{"source":"iana"},"application/vnd.sealed.xls":{"source":"iana"},"application/vnd.sealedmedia.softseal.html":{"source":"iana"},"application/vnd.sealedmedia.softseal.pdf":{"source":"iana"},"application/vnd.seemail":{"source":"iana","extensions":["see"]},"application/vnd.seis+json":{"source":"iana","compressible":true},"application/vnd.sema":{"source":"iana","extensions":["sema"]},"application/vnd.semd":{"source":"iana","extensions":["semd"]},"application/vnd.semf":{"source":"iana","extensions":["semf"]},"application/vnd.shade-save-file":{"source":"iana"},"application/vnd.shana.informed.formdata":{"source":"iana","extensions":["ifm"]},"application/vnd.shana.informed.formtemplate":{"source":"iana","extensions":["itp"]},"application/vnd.shana.informed.interchange":{"source":"iana","extensions":["iif"]},"application/vnd.shana.informed.package":{"source":"iana","extensions":["ipk"]},"application/vnd.shootproof+json":{"source":"iana","compressible":true},"application/vnd.shopkick+json":{"source":"iana","compressible":true},"application/vnd.shp":{"source":"iana"},"application/vnd.shx":{"source":"iana"},"application/vnd.sigrok.session":{"source":"iana"},"application/vnd.simtech-mindmapper":{"source":"iana","extensions":["twd","twds"]},"application/vnd.siren+json":{"source":"iana","compressible":true},"application/vnd.smaf":{"source":"iana","extensions":["mmf"]},"application/vnd.smart.notebook":{"source":"iana"},"application/vnd.smart.teacher":{"source":"iana","extensions":["teacher"]},"application/vnd.snesdev-page-table":{"source":"iana"},"application/vnd.software602.filler.form+xml":{"source":"iana","compressible":true,"extensions":["fo"]},"application/vnd.software602.filler.form-xml-zip":{"source":"iana"},"application/vnd.solent.sdkm+xml":{"source":"iana","compressible":true,"extensions":["sdkm","sdkd"]},"application/vnd.spotfire.dxp":{"source":"iana","extensions":["dxp"]},"application/vnd.spotfire.sfs":{"source":"iana","extensions":["sfs"]},"application/vnd.sqlite3":{"source":"iana"},"application/vnd.sss-cod":{"source":"iana"},"application/vnd.sss-dtf":{"source":"iana"},"application/vnd.sss-ntf":{"source":"iana"},"application/vnd.stardivision.calc":{"source":"apache","extensions":["sdc"]},"application/vnd.stardivision.draw":{"source":"apache","extensions":["sda"]},"application/vnd.stardivision.impress":{"source":"apache","extensions":["sdd"]},"application/vnd.stardivision.math":{"source":"apache","extensions":["smf"]},"application/vnd.stardivision.writer":{"source":"apache","extensions":["sdw","vor"]},"application/vnd.stardivision.writer-global":{"source":"apache","extensions":["sgl"]},"application/vnd.stepmania.package":{"source":"iana","extensions":["smzip"]},"application/vnd.stepmania.stepchart":{"source":"iana","extensions":["sm"]},"application/vnd.street-stream":{"source":"iana"},"application/vnd.sun.wadl+xml":{"source":"iana","compressible":true,"extensions":["wadl"]},"application/vnd.sun.xml.calc":{"source":"apache","extensions":["sxc"]},"application/vnd.sun.xml.calc.template":{"source":"apache","extensions":["stc"]},"application/vnd.sun.xml.draw":{"source":"apache","extensions":["sxd"]},"application/vnd.sun.xml.draw.template":{"source":"apache","extensions":["std"]},"application/vnd.sun.xml.impress":{"source":"apache","extensions":["sxi"]},"application/vnd.sun.xml.impress.template":{"source":"apache","extensions":["sti"]},"application/vnd.sun.xml.math":{"source":"apache","extensions":["sxm"]},"application/vnd.sun.xml.writer":{"source":"apache","extensions":["sxw"]},"application/vnd.sun.xml.writer.global":{"source":"apache","extensions":["sxg"]},"application/vnd.sun.xml.writer.template":{"source":"apache","extensions":["stw"]},"application/vnd.sus-calendar":{"source":"iana","extensions":["sus","susp"]},"application/vnd.svd":{"source":"iana","extensions":["svd"]},"application/vnd.swiftview-ics":{"source":"iana"},"application/vnd.sycle+xml":{"source":"iana","compressible":true},"application/vnd.syft+json":{"source":"iana","compressible":true},"application/vnd.symbian.install":{"source":"apache","extensions":["sis","sisx"]},"application/vnd.syncml+xml":{"source":"iana","charset":"UTF-8","compressible":true,"extensions":["xsm"]},"application/vnd.syncml.dm+wbxml":{"source":"iana","charset":"UTF-8","extensions":["bdm"]},"application/vnd.syncml.dm+xml":{"source":"iana","charset":"UTF-8","compressible":true,"extensions":["xdm"]},"application/vnd.syncml.dm.notification":{"source":"iana"},"application/vnd.syncml.dmddf+wbxml":{"source":"iana"},"application/vnd.syncml.dmddf+xml":{"source":"iana","charset":"UTF-8","compressible":true,"extensions":["ddf"]},"application/vnd.syncml.dmtnds+wbxml":{"source":"iana"},"application/vnd.syncml.dmtnds+xml":{"source":"iana","charset":"UTF-8","compressible":true},"application/vnd.syncml.ds.notification":{"source":"iana"},"application/vnd.tableschema+json":{"source":"iana","compressible":true},"application/vnd.tao.intent-module-archive":{"source":"iana","extensions":["tao"]},"application/vnd.tcpdump.pcap":{"source":"iana","extensions":["pcap","cap","dmp"]},"application/vnd.think-cell.ppttc+json":{"source":"iana","compressible":true},"application/vnd.tmd.mediaflex.api+xml":{"source":"iana","compressible":true},"application/vnd.tml":{"source":"iana"},"application/vnd.tmobile-livetv":{"source":"iana","extensions":["tmo"]},"application/vnd.tri.onesource":{"source":"iana"},"application/vnd.trid.tpt":{"source":"iana","extensions":["tpt"]},"application/vnd.triscape.mxs":{"source":"iana","extensions":["mxs"]},"application/vnd.trueapp":{"source":"iana","extensions":["tra"]},"application/vnd.truedoc":{"source":"iana"},"application/vnd.ubisoft.webplayer":{"source":"iana"},"application/vnd.ufdl":{"source":"iana","extensions":["ufd","ufdl"]},"application/vnd.uiq.theme":{"source":"iana","extensions":["utz"]},"application/vnd.umajin":{"source":"iana","extensions":["umj"]},"application/vnd.unity":{"source":"iana","extensions":["unityweb"]},"application/vnd.uoml+xml":{"source":"iana","compressible":true,"extensions":["uoml"]},"application/vnd.uplanet.alert":{"source":"iana"},"application/vnd.uplanet.alert-wbxml":{"source":"iana"},"application/vnd.uplanet.bearer-choice":{"source":"iana"},"application/vnd.uplanet.bearer-choice-wbxml":{"source":"iana"},"application/vnd.uplanet.cacheop":{"source":"iana"},"application/vnd.uplanet.cacheop-wbxml":{"source":"iana"},"application/vnd.uplanet.channel":{"source":"iana"},"application/vnd.uplanet.channel-wbxml":{"source":"iana"},"application/vnd.uplanet.list":{"source":"iana"},"application/vnd.uplanet.list-wbxml":{"source":"iana"},"application/vnd.uplanet.listcmd":{"source":"iana"},"application/vnd.uplanet.listcmd-wbxml":{"source":"iana"},"application/vnd.uplanet.signal":{"source":"iana"},"application/vnd.uri-map":{"source":"iana"},"application/vnd.valve.source.material":{"source":"iana"},"application/vnd.vcx":{"source":"iana","extensions":["vcx"]},"application/vnd.vd-study":{"source":"iana"},"application/vnd.vectorworks":{"source":"iana"},"application/vnd.vel+json":{"source":"iana","compressible":true},"application/vnd.verimatrix.vcas":{"source":"iana"},"application/vnd.veritone.aion+json":{"source":"iana","compressible":true},"application/vnd.veryant.thin":{"source":"iana"},"application/vnd.ves.encrypted":{"source":"iana"},"application/vnd.vidsoft.vidconference":{"source":"iana"},"application/vnd.visio":{"source":"iana","extensions":["vsd","vst","vss","vsw"]},"application/vnd.visionary":{"source":"iana","extensions":["vis"]},"application/vnd.vividence.scriptfile":{"source":"iana"},"application/vnd.vsf":{"source":"iana","extensions":["vsf"]},"application/vnd.wap.sic":{"source":"iana"},"application/vnd.wap.slc":{"source":"iana"},"application/vnd.wap.wbxml":{"source":"iana","charset":"UTF-8","extensions":["wbxml"]},"application/vnd.wap.wmlc":{"source":"iana","extensions":["wmlc"]},"application/vnd.wap.wmlscriptc":{"source":"iana","extensions":["wmlsc"]},"application/vnd.webturbo":{"source":"iana","extensions":["wtb"]},"application/vnd.wfa.dpp":{"source":"iana"},"application/vnd.wfa.p2p":{"source":"iana"},"application/vnd.wfa.wsc":{"source":"iana"},"application/vnd.windows.devicepairing":{"source":"iana"},"application/vnd.wmc":{"source":"iana"},"application/vnd.wmf.bootstrap":{"source":"iana"},"application/vnd.wolfram.mathematica":{"source":"iana"},"application/vnd.wolfram.mathematica.package":{"source":"iana"},"application/vnd.wolfram.player":{"source":"iana","extensions":["nbp"]},"application/vnd.wordperfect":{"source":"iana","extensions":["wpd"]},"application/vnd.wqd":{"source":"iana","extensions":["wqd"]},"application/vnd.wrq-hp3000-labelled":{"source":"iana"},"application/vnd.wt.stf":{"source":"iana","extensions":["stf"]},"application/vnd.wv.csp+wbxml":{"source":"iana"},"application/vnd.wv.csp+xml":{"source":"iana","compressible":true},"application/vnd.wv.ssp+xml":{"source":"iana","compressible":true},"application/vnd.xacml+json":{"source":"iana","compressible":true},"application/vnd.xara":{"source":"iana","extensions":["xar"]},"application/vnd.xfdl":{"source":"iana","extensions":["xfdl"]},"application/vnd.xfdl.webform":{"source":"iana"},"application/vnd.xmi+xml":{"source":"iana","compressible":true},"application/vnd.xmpie.cpkg":{"source":"iana"},"application/vnd.xmpie.dpkg":{"source":"iana"},"application/vnd.xmpie.plan":{"source":"iana"},"application/vnd.xmpie.ppkg":{"source":"iana"},"application/vnd.xmpie.xlim":{"source":"iana"},"application/vnd.yamaha.hv-dic":{"source":"iana","extensions":["hvd"]},"application/vnd.yamaha.hv-script":{"source":"iana","extensions":["hvs"]},"application/vnd.yamaha.hv-voice":{"source":"iana","extensions":["hvp"]},"application/vnd.yamaha.openscoreformat":{"source":"iana","extensions":["osf"]},"application/vnd.yamaha.openscoreformat.osfpvg+xml":{"source":"iana","compressible":true,"extensions":["osfpvg"]},"application/vnd.yamaha.remote-setup":{"source":"iana"},"application/vnd.yamaha.smaf-audio":{"source":"iana","extensions":["saf"]},"application/vnd.yamaha.smaf-phrase":{"source":"iana","extensions":["spf"]},"application/vnd.yamaha.through-ngn":{"source":"iana"},"application/vnd.yamaha.tunnel-udpencap":{"source":"iana"},"application/vnd.yaoweme":{"source":"iana"},"application/vnd.yellowriver-custom-menu":{"source":"iana","extensions":["cmp"]},"application/vnd.youtube.yt":{"source":"iana"},"application/vnd.zul":{"source":"iana","extensions":["zir","zirz"]},"application/vnd.zzazz.deck+xml":{"source":"iana","compressible":true,"extensions":["zaz"]},"application/voicexml+xml":{"source":"iana","compressible":true,"extensions":["vxml"]},"application/voucher-cms+json":{"source":"iana","compressible":true},"application/vq-rtcpxr":{"source":"iana"},"application/wasm":{"source":"iana","compressible":true,"extensions":["wasm"]},"application/watcherinfo+xml":{"source":"iana","compressible":true,"extensions":["wif"]},"application/webpush-options+json":{"source":"iana","compressible":true},"application/whoispp-query":{"source":"iana"},"application/whoispp-response":{"source":"iana"},"application/widget":{"source":"iana","extensions":["wgt"]},"application/winhlp":{"source":"apache","extensions":["hlp"]},"application/wita":{"source":"iana"},"application/wordperfect5.1":{"source":"iana"},"application/wsdl+xml":{"source":"iana","compressible":true,"extensions":["wsdl"]},"application/wspolicy+xml":{"source":"iana","compressible":true,"extensions":["wspolicy"]},"application/x-7z-compressed":{"source":"apache","compressible":false,"extensions":["7z"]},"application/x-abiword":{"source":"apache","extensions":["abw"]},"application/x-ace-compressed":{"source":"apache","extensions":["ace"]},"application/x-amf":{"source":"apache"},"application/x-apple-diskimage":{"source":"apache","extensions":["dmg"]},"application/x-arj":{"compressible":false,"extensions":["arj"]},"application/x-authorware-bin":{"source":"apache","extensions":["aab","x32","u32","vox"]},"application/x-authorware-map":{"source":"apache","extensions":["aam"]},"application/x-authorware-seg":{"source":"apache","extensions":["aas"]},"application/x-bcpio":{"source":"apache","extensions":["bcpio"]},"application/x-bdoc":{"compressible":false,"extensions":["bdoc"]},"application/x-bittorrent":{"source":"apache","extensions":["torrent"]},"application/x-blorb":{"source":"apache","extensions":["blb","blorb"]},"application/x-bzip":{"source":"apache","compressible":false,"extensions":["bz"]},"application/x-bzip2":{"source":"apache","compressible":false,"extensions":["bz2","boz"]},"application/x-cbr":{"source":"apache","extensions":["cbr","cba","cbt","cbz","cb7"]},"application/x-cdlink":{"source":"apache","extensions":["vcd"]},"application/x-cfs-compressed":{"source":"apache","extensions":["cfs"]},"application/x-chat":{"source":"apache","extensions":["chat"]},"application/x-chess-pgn":{"source":"apache","extensions":["pgn"]},"application/x-chrome-extension":{"extensions":["crx"]},"application/x-cocoa":{"source":"nginx","extensions":["cco"]},"application/x-compress":{"source":"apache"},"application/x-conference":{"source":"apache","extensions":["nsc"]},"application/x-cpio":{"source":"apache","extensions":["cpio"]},"application/x-csh":{"source":"apache","extensions":["csh"]},"application/x-deb":{"compressible":false},"application/x-debian-package":{"source":"apache","extensions":["deb","udeb"]},"application/x-dgc-compressed":{"source":"apache","extensions":["dgc"]},"application/x-director":{"source":"apache","extensions":["dir","dcr","dxr","cst","cct","cxt","w3d","fgd","swa"]},"application/x-doom":{"source":"apache","extensions":["wad"]},"application/x-dtbncx+xml":{"source":"apache","compressible":true,"extensions":["ncx"]},"application/x-dtbook+xml":{"source":"apache","compressible":true,"extensions":["dtb"]},"application/x-dtbresource+xml":{"source":"apache","compressible":true,"extensions":["res"]},"application/x-dvi":{"source":"apache","compressible":false,"extensions":["dvi"]},"application/x-envoy":{"source":"apache","extensions":["evy"]},"application/x-eva":{"source":"apache","extensions":["eva"]},"application/x-font-bdf":{"source":"apache","extensions":["bdf"]},"application/x-font-dos":{"source":"apache"},"application/x-font-framemaker":{"source":"apache"},"application/x-font-ghostscript":{"source":"apache","extensions":["gsf"]},"application/x-font-libgrx":{"source":"apache"},"application/x-font-linux-psf":{"source":"apache","extensions":["psf"]},"application/x-font-pcf":{"source":"apache","extensions":["pcf"]},"application/x-font-snf":{"source":"apache","extensions":["snf"]},"application/x-font-speedo":{"source":"apache"},"application/x-font-sunos-news":{"source":"apache"},"application/x-font-type1":{"source":"apache","extensions":["pfa","pfb","pfm","afm"]},"application/x-font-vfont":{"source":"apache"},"application/x-freearc":{"source":"apache","extensions":["arc"]},"application/x-futuresplash":{"source":"apache","extensions":["spl"]},"application/x-gca-compressed":{"source":"apache","extensions":["gca"]},"application/x-glulx":{"source":"apache","extensions":["ulx"]},"application/x-gnumeric":{"source":"apache","extensions":["gnumeric"]},"application/x-gramps-xml":{"source":"apache","extensions":["gramps"]},"application/x-gtar":{"source":"apache","extensions":["gtar"]},"application/x-gzip":{"source":"apache"},"application/x-hdf":{"source":"apache","extensions":["hdf"]},"application/x-httpd-php":{"compressible":true,"extensions":["php"]},"application/x-install-instructions":{"source":"apache","extensions":["install"]},"application/x-iso9660-image":{"source":"apache","extensions":["iso"]},"application/x-iwork-keynote-sffkey":{"extensions":["key"]},"application/x-iwork-numbers-sffnumbers":{"extensions":["numbers"]},"application/x-iwork-pages-sffpages":{"extensions":["pages"]},"application/x-java-archive-diff":{"source":"nginx","extensions":["jardiff"]},"application/x-java-jnlp-file":{"source":"apache","compressible":false,"extensions":["jnlp"]},"application/x-javascript":{"compressible":true},"application/x-keepass2":{"extensions":["kdbx"]},"application/x-latex":{"source":"apache","compressible":false,"extensions":["latex"]},"application/x-lua-bytecode":{"extensions":["luac"]},"application/x-lzh-compressed":{"source":"apache","extensions":["lzh","lha"]},"application/x-makeself":{"source":"nginx","extensions":["run"]},"application/x-mie":{"source":"apache","extensions":["mie"]},"application/x-mobipocket-ebook":{"source":"apache","extensions":["prc","mobi"]},"application/x-mpegurl":{"compressible":false},"application/x-ms-application":{"source":"apache","extensions":["application"]},"application/x-ms-shortcut":{"source":"apache","extensions":["lnk"]},"application/x-ms-wmd":{"source":"apache","extensions":["wmd"]},"application/x-ms-wmz":{"source":"apache","extensions":["wmz"]},"application/x-ms-xbap":{"source":"apache","extensions":["xbap"]},"application/x-msaccess":{"source":"apache","extensions":["mdb"]},"application/x-msbinder":{"source":"apache","extensions":["obd"]},"application/x-mscardfile":{"source":"apache","extensions":["crd"]},"application/x-msclip":{"source":"apache","extensions":["clp"]},"application/x-msdos-program":{"extensions":["exe"]},"application/x-msdownload":{"source":"apache","extensions":["exe","dll","com","bat","msi"]},"application/x-msmediaview":{"source":"apache","extensions":["mvb","m13","m14"]},"application/x-msmetafile":{"source":"apache","extensions":["wmf","wmz","emf","emz"]},"application/x-msmoney":{"source":"apache","extensions":["mny"]},"application/x-mspublisher":{"source":"apache","extensions":["pub"]},"application/x-msschedule":{"source":"apache","extensions":["scd"]},"application/x-msterminal":{"source":"apache","extensions":["trm"]},"application/x-mswrite":{"source":"apache","extensions":["wri"]},"application/x-netcdf":{"source":"apache","extensions":["nc","cdf"]},"application/x-ns-proxy-autoconfig":{"compressible":true,"extensions":["pac"]},"application/x-nzb":{"source":"apache","extensions":["nzb"]},"application/x-perl":{"source":"nginx","extensions":["pl","pm"]},"application/x-pilot":{"source":"nginx","extensions":["prc","pdb"]},"application/x-pkcs12":{"source":"apache","compressible":false,"extensions":["p12","pfx"]},"application/x-pkcs7-certificates":{"source":"apache","extensions":["p7b","spc"]},"application/x-pkcs7-certreqresp":{"source":"apache","extensions":["p7r"]},"application/x-pki-message":{"source":"iana"},"application/x-rar-compressed":{"source":"apache","compressible":false,"extensions":["rar"]},"application/x-redhat-package-manager":{"source":"nginx","extensions":["rpm"]},"application/x-research-info-systems":{"source":"apache","extensions":["ris"]},"application/x-sea":{"source":"nginx","extensions":["sea"]},"application/x-sh":{"source":"apache","compressible":true,"extensions":["sh"]},"application/x-shar":{"source":"apache","extensions":["shar"]},"application/x-shockwave-flash":{"source":"apache","compressible":false,"extensions":["swf"]},"application/x-silverlight-app":{"source":"apache","extensions":["xap"]},"application/x-sql":{"source":"apache","extensions":["sql"]},"application/x-stuffit":{"source":"apache","compressible":false,"extensions":["sit"]},"application/x-stuffitx":{"source":"apache","extensions":["sitx"]},"application/x-subrip":{"source":"apache","extensions":["srt"]},"application/x-sv4cpio":{"source":"apache","extensions":["sv4cpio"]},"application/x-sv4crc":{"source":"apache","extensions":["sv4crc"]},"application/x-t3vm-image":{"source":"apache","extensions":["t3"]},"application/x-tads":{"source":"apache","extensions":["gam"]},"application/x-tar":{"source":"apache","compressible":true,"extensions":["tar"]},"application/x-tcl":{"source":"apache","extensions":["tcl","tk"]},"application/x-tex":{"source":"apache","extensions":["tex"]},"application/x-tex-tfm":{"source":"apache","extensions":["tfm"]},"application/x-texinfo":{"source":"apache","extensions":["texinfo","texi"]},"application/x-tgif":{"source":"apache","extensions":["obj"]},"application/x-ustar":{"source":"apache","extensions":["ustar"]},"application/x-virtualbox-hdd":{"compressible":true,"extensions":["hdd"]},"application/x-virtualbox-ova":{"compressible":true,"extensions":["ova"]},"application/x-virtualbox-ovf":{"compressible":true,"extensions":["ovf"]},"application/x-virtualbox-vbox":{"compressible":true,"extensions":["vbox"]},"application/x-virtualbox-vbox-extpack":{"compressible":false,"extensions":["vbox-extpack"]},"application/x-virtualbox-vdi":{"compressible":true,"extensions":["vdi"]},"application/x-virtualbox-vhd":{"compressible":true,"extensions":["vhd"]},"application/x-virtualbox-vmdk":{"compressible":true,"extensions":["vmdk"]},"application/x-wais-source":{"source":"apache","extensions":["src"]},"application/x-web-app-manifest+json":{"compressible":true,"extensions":["webapp"]},"application/x-www-form-urlencoded":{"source":"iana","compressible":true},"application/x-x509-ca-cert":{"source":"iana","extensions":["der","crt","pem"]},"application/x-x509-ca-ra-cert":{"source":"iana"},"application/x-x509-next-ca-cert":{"source":"iana"},"application/x-xfig":{"source":"apache","extensions":["fig"]},"application/x-xliff+xml":{"source":"apache","compressible":true,"extensions":["xlf"]},"application/x-xpinstall":{"source":"apache","compressible":false,"extensions":["xpi"]},"application/x-xz":{"source":"apache","extensions":["xz"]},"application/x-zmachine":{"source":"apache","extensions":["z1","z2","z3","z4","z5","z6","z7","z8"]},"application/x400-bp":{"source":"iana"},"application/xacml+xml":{"source":"iana","compressible":true},"application/xaml+xml":{"source":"apache","compressible":true,"extensions":["xaml"]},"application/xcap-att+xml":{"source":"iana","compressible":true,"extensions":["xav"]},"application/xcap-caps+xml":{"source":"iana","compressible":true,"extensions":["xca"]},"application/xcap-diff+xml":{"source":"iana","compressible":true,"extensions":["xdf"]},"application/xcap-el+xml":{"source":"iana","compressible":true,"extensions":["xel"]},"application/xcap-error+xml":{"source":"iana","compressible":true},"application/xcap-ns+xml":{"source":"iana","compressible":true,"extensions":["xns"]},"application/xcon-conference-info+xml":{"source":"iana","compressible":true},"application/xcon-conference-info-diff+xml":{"source":"iana","compressible":true},"application/xenc+xml":{"source":"iana","compressible":true,"extensions":["xenc"]},"application/xhtml+xml":{"source":"iana","compressible":true,"extensions":["xhtml","xht"]},"application/xhtml-voice+xml":{"source":"apache","compressible":true},"application/xliff+xml":{"source":"iana","compressible":true,"extensions":["xlf"]},"application/xml":{"source":"iana","compressible":true,"extensions":["xml","xsl","xsd","rng"]},"application/xml-dtd":{"source":"iana","compressible":true,"extensions":["dtd"]},"application/xml-external-parsed-entity":{"source":"iana"},"application/xml-patch+xml":{"source":"iana","compressible":true},"application/xmpp+xml":{"source":"iana","compressible":true},"application/xop+xml":{"source":"iana","compressible":true,"extensions":["xop"]},"application/xproc+xml":{"source":"apache","compressible":true,"extensions":["xpl"]},"application/xslt+xml":{"source":"iana","compressible":true,"extensions":["xsl","xslt"]},"application/xspf+xml":{"source":"apache","compressible":true,"extensions":["xspf"]},"application/xv+xml":{"source":"iana","compressible":true,"extensions":["mxml","xhvml","xvml","xvm"]},"application/yang":{"source":"iana","extensions":["yang"]},"application/yang-data+json":{"source":"iana","compressible":true},"application/yang-data+xml":{"source":"iana","compressible":true},"application/yang-patch+json":{"source":"iana","compressible":true},"application/yang-patch+xml":{"source":"iana","compressible":true},"application/yin+xml":{"source":"iana","compressible":true,"extensions":["yin"]},"application/zip":{"source":"iana","compressible":false,"extensions":["zip"]},"application/zlib":{"source":"iana"},"application/zstd":{"source":"iana"},"audio/1d-interleaved-parityfec":{"source":"iana"},"audio/32kadpcm":{"source":"iana"},"audio/3gpp":{"source":"iana","compressible":false,"extensions":["3gpp"]},"audio/3gpp2":{"source":"iana"},"audio/aac":{"source":"iana"},"audio/ac3":{"source":"iana"},"audio/adpcm":{"source":"apache","extensions":["adp"]},"audio/amr":{"source":"iana","extensions":["amr"]},"audio/amr-wb":{"source":"iana"},"audio/amr-wb+":{"source":"iana"},"audio/aptx":{"source":"iana"},"audio/asc":{"source":"iana"},"audio/atrac-advanced-lossless":{"source":"iana"},"audio/atrac-x":{"source":"iana"},"audio/atrac3":{"source":"iana"},"audio/basic":{"source":"iana","compressible":false,"extensions":["au","snd"]},"audio/bv16":{"source":"iana"},"audio/bv32":{"source":"iana"},"audio/clearmode":{"source":"iana"},"audio/cn":{"source":"iana"},"audio/dat12":{"source":"iana"},"audio/dls":{"source":"iana"},"audio/dsr-es201108":{"source":"iana"},"audio/dsr-es202050":{"source":"iana"},"audio/dsr-es202211":{"source":"iana"},"audio/dsr-es202212":{"source":"iana"},"audio/dv":{"source":"iana"},"audio/dvi4":{"source":"iana"},"audio/eac3":{"source":"iana"},"audio/encaprtp":{"source":"iana"},"audio/evrc":{"source":"iana"},"audio/evrc-qcp":{"source":"iana"},"audio/evrc0":{"source":"iana"},"audio/evrc1":{"source":"iana"},"audio/evrcb":{"source":"iana"},"audio/evrcb0":{"source":"iana"},"audio/evrcb1":{"source":"iana"},"audio/evrcnw":{"source":"iana"},"audio/evrcnw0":{"source":"iana"},"audio/evrcnw1":{"source":"iana"},"audio/evrcwb":{"source":"iana"},"audio/evrcwb0":{"source":"iana"},"audio/evrcwb1":{"source":"iana"},"audio/evs":{"source":"iana"},"audio/flexfec":{"source":"iana"},"audio/fwdred":{"source":"iana"},"audio/g711-0":{"source":"iana"},"audio/g719":{"source":"iana"},"audio/g722":{"source":"iana"},"audio/g7221":{"source":"iana"},"audio/g723":{"source":"iana"},"audio/g726-16":{"source":"iana"},"audio/g726-24":{"source":"iana"},"audio/g726-32":{"source":"iana"},"audio/g726-40":{"source":"iana"},"audio/g728":{"source":"iana"},"audio/g729":{"source":"iana"},"audio/g7291":{"source":"iana"},"audio/g729d":{"source":"iana"},"audio/g729e":{"source":"iana"},"audio/gsm":{"source":"iana"},"audio/gsm-efr":{"source":"iana"},"audio/gsm-hr-08":{"source":"iana"},"audio/ilbc":{"source":"iana"},"audio/ip-mr_v2.5":{"source":"iana"},"audio/isac":{"source":"apache"},"audio/l16":{"source":"iana"},"audio/l20":{"source":"iana"},"audio/l24":{"source":"iana","compressible":false},"audio/l8":{"source":"iana"},"audio/lpc":{"source":"iana"},"audio/melp":{"source":"iana"},"audio/melp1200":{"source":"iana"},"audio/melp2400":{"source":"iana"},"audio/melp600":{"source":"iana"},"audio/mhas":{"source":"iana"},"audio/midi":{"source":"apache","extensions":["mid","midi","kar","rmi"]},"audio/mobile-xmf":{"source":"iana","extensions":["mxmf"]},"audio/mp3":{"compressible":false,"extensions":["mp3"]},"audio/mp4":{"source":"iana","compressible":false,"extensions":["m4a","mp4a"]},"audio/mp4a-latm":{"source":"iana"},"audio/mpa":{"source":"iana"},"audio/mpa-robust":{"source":"iana"},"audio/mpeg":{"source":"iana","compressible":false,"extensions":["mpga","mp2","mp2a","mp3","m2a","m3a"]},"audio/mpeg4-generic":{"source":"iana"},"audio/musepack":{"source":"apache"},"audio/ogg":{"source":"iana","compressible":false,"extensions":["oga","ogg","spx","opus"]},"audio/opus":{"source":"iana"},"audio/parityfec":{"source":"iana"},"audio/pcma":{"source":"iana"},"audio/pcma-wb":{"source":"iana"},"audio/pcmu":{"source":"iana"},"audio/pcmu-wb":{"source":"iana"},"audio/prs.sid":{"source":"iana"},"audio/qcelp":{"source":"iana"},"audio/raptorfec":{"source":"iana"},"audio/red":{"source":"iana"},"audio/rtp-enc-aescm128":{"source":"iana"},"audio/rtp-midi":{"source":"iana"},"audio/rtploopback":{"source":"iana"},"audio/rtx":{"source":"iana"},"audio/s3m":{"source":"apache","extensions":["s3m"]},"audio/scip":{"source":"iana"},"audio/silk":{"source":"apache","extensions":["sil"]},"audio/smv":{"source":"iana"},"audio/smv-qcp":{"source":"iana"},"audio/smv0":{"source":"iana"},"audio/sofa":{"source":"iana"},"audio/sp-midi":{"source":"iana"},"audio/speex":{"source":"iana"},"audio/t140c":{"source":"iana"},"audio/t38":{"source":"iana"},"audio/telephone-event":{"source":"iana"},"audio/tetra_acelp":{"source":"iana"},"audio/tetra_acelp_bb":{"source":"iana"},"audio/tone":{"source":"iana"},"audio/tsvcis":{"source":"iana"},"audio/uemclip":{"source":"iana"},"audio/ulpfec":{"source":"iana"},"audio/usac":{"source":"iana"},"audio/vdvi":{"source":"iana"},"audio/vmr-wb":{"source":"iana"},"audio/vnd.3gpp.iufp":{"source":"iana"},"audio/vnd.4sb":{"source":"iana"},"audio/vnd.audiokoz":{"source":"iana"},"audio/vnd.celp":{"source":"iana"},"audio/vnd.cisco.nse":{"source":"iana"},"audio/vnd.cmles.radio-events":{"source":"iana"},"audio/vnd.cns.anp1":{"source":"iana"},"audio/vnd.cns.inf1":{"source":"iana"},"audio/vnd.dece.audio":{"source":"iana","extensions":["uva","uvva"]},"audio/vnd.digital-winds":{"source":"iana","extensions":["eol"]},"audio/vnd.dlna.adts":{"source":"iana"},"audio/vnd.dolby.heaac.1":{"source":"iana"},"audio/vnd.dolby.heaac.2":{"source":"iana"},"audio/vnd.dolby.mlp":{"source":"iana"},"audio/vnd.dolby.mps":{"source":"iana"},"audio/vnd.dolby.pl2":{"source":"iana"},"audio/vnd.dolby.pl2x":{"source":"iana"},"audio/vnd.dolby.pl2z":{"source":"iana"},"audio/vnd.dolby.pulse.1":{"source":"iana"},"audio/vnd.dra":{"source":"iana","extensions":["dra"]},"audio/vnd.dts":{"source":"iana","extensions":["dts"]},"audio/vnd.dts.hd":{"source":"iana","extensions":["dtshd"]},"audio/vnd.dts.uhd":{"source":"iana"},"audio/vnd.dvb.file":{"source":"iana"},"audio/vnd.everad.plj":{"source":"iana"},"audio/vnd.hns.audio":{"source":"iana"},"audio/vnd.lucent.voice":{"source":"iana","extensions":["lvp"]},"audio/vnd.ms-playready.media.pya":{"source":"iana","extensions":["pya"]},"audio/vnd.nokia.mobile-xmf":{"source":"iana"},"audio/vnd.nortel.vbk":{"source":"iana"},"audio/vnd.nuera.ecelp4800":{"source":"iana","extensions":["ecelp4800"]},"audio/vnd.nuera.ecelp7470":{"source":"iana","extensions":["ecelp7470"]},"audio/vnd.nuera.ecelp9600":{"source":"iana","extensions":["ecelp9600"]},"audio/vnd.octel.sbc":{"source":"iana"},"audio/vnd.presonus.multitrack":{"source":"iana"},"audio/vnd.qcelp":{"source":"iana"},"audio/vnd.rhetorex.32kadpcm":{"source":"iana"},"audio/vnd.rip":{"source":"iana","extensions":["rip"]},"audio/vnd.rn-realaudio":{"compressible":false},"audio/vnd.sealedmedia.softseal.mpeg":{"source":"iana"},"audio/vnd.vmx.cvsd":{"source":"iana"},"audio/vnd.wave":{"compressible":false},"audio/vorbis":{"source":"iana","compressible":false},"audio/vorbis-config":{"source":"iana"},"audio/wav":{"compressible":false,"extensions":["wav"]},"audio/wave":{"compressible":false,"extensions":["wav"]},"audio/webm":{"source":"apache","compressible":false,"extensions":["weba"]},"audio/x-aac":{"source":"apache","compressible":false,"extensions":["aac"]},"audio/x-aiff":{"source":"apache","extensions":["aif","aiff","aifc"]},"audio/x-caf":{"source":"apache","compressible":false,"extensions":["caf"]},"audio/x-flac":{"source":"apache","extensions":["flac"]},"audio/x-m4a":{"source":"nginx","extensions":["m4a"]},"audio/x-matroska":{"source":"apache","extensions":["mka"]},"audio/x-mpegurl":{"source":"apache","extensions":["m3u"]},"audio/x-ms-wax":{"source":"apache","extensions":["wax"]},"audio/x-ms-wma":{"source":"apache","extensions":["wma"]},"audio/x-pn-realaudio":{"source":"apache","extensions":["ram","ra"]},"audio/x-pn-realaudio-plugin":{"source":"apache","extensions":["rmp"]},"audio/x-realaudio":{"source":"nginx","extensions":["ra"]},"audio/x-tta":{"source":"apache"},"audio/x-wav":{"source":"apache","extensions":["wav"]},"audio/xm":{"source":"apache","extensions":["xm"]},"chemical/x-cdx":{"source":"apache","extensions":["cdx"]},"chemical/x-cif":{"source":"apache","extensions":["cif"]},"chemical/x-cmdf":{"source":"apache","extensions":["cmdf"]},"chemical/x-cml":{"source":"apache","extensions":["cml"]},"chemical/x-csml":{"source":"apache","extensions":["csml"]},"chemical/x-pdb":{"source":"apache"},"chemical/x-xyz":{"source":"apache","extensions":["xyz"]},"font/collection":{"source":"iana","extensions":["ttc"]},"font/otf":{"source":"iana","compressible":true,"extensions":["otf"]},"font/sfnt":{"source":"iana"},"font/ttf":{"source":"iana","compressible":true,"extensions":["ttf"]},"font/woff":{"source":"iana","extensions":["woff"]},"font/woff2":{"source":"iana","extensions":["woff2"]},"image/aces":{"source":"iana","extensions":["exr"]},"image/apng":{"compressible":false,"extensions":["apng"]},"image/avci":{"source":"iana","extensions":["avci"]},"image/avcs":{"source":"iana","extensions":["avcs"]},"image/avif":{"source":"iana","compressible":false,"extensions":["avif"]},"image/bmp":{"source":"iana","compressible":true,"extensions":["bmp"]},"image/cgm":{"source":"iana","extensions":["cgm"]},"image/dicom-rle":{"source":"iana","extensions":["drle"]},"image/emf":{"source":"iana","extensions":["emf"]},"image/fits":{"source":"iana","extensions":["fits"]},"image/g3fax":{"source":"iana","extensions":["g3"]},"image/gif":{"source":"iana","compressible":false,"extensions":["gif"]},"image/heic":{"source":"iana","extensions":["heic"]},"image/heic-sequence":{"source":"iana","extensions":["heics"]},"image/heif":{"source":"iana","extensions":["heif"]},"image/heif-sequence":{"source":"iana","extensions":["heifs"]},"image/hej2k":{"source":"iana","extensions":["hej2"]},"image/hsj2":{"source":"iana","extensions":["hsj2"]},"image/ief":{"source":"iana","extensions":["ief"]},"image/jls":{"source":"iana","extensions":["jls"]},"image/jp2":{"source":"iana","compressible":false,"extensions":["jp2","jpg2"]},"image/jpeg":{"source":"iana","compressible":false,"extensions":["jpeg","jpg","jpe"]},"image/jph":{"source":"iana","extensions":["jph"]},"image/jphc":{"source":"iana","extensions":["jhc"]},"image/jpm":{"source":"iana","compressible":false,"extensions":["jpm"]},"image/jpx":{"source":"iana","compressible":false,"extensions":["jpx","jpf"]},"image/jxr":{"source":"iana","extensions":["jxr"]},"image/jxra":{"source":"iana","extensions":["jxra"]},"image/jxrs":{"source":"iana","extensions":["jxrs"]},"image/jxs":{"source":"iana","extensions":["jxs"]},"image/jxsc":{"source":"iana","extensions":["jxsc"]},"image/jxsi":{"source":"iana","extensions":["jxsi"]},"image/jxss":{"source":"iana","extensions":["jxss"]},"image/ktx":{"source":"iana","extensions":["ktx"]},"image/ktx2":{"source":"iana","extensions":["ktx2"]},"image/naplps":{"source":"iana"},"image/pjpeg":{"compressible":false},"image/png":{"source":"iana","compressible":false,"extensions":["png"]},"image/prs.btif":{"source":"iana","extensions":["btif"]},"image/prs.pti":{"source":"iana","extensions":["pti"]},"image/pwg-raster":{"source":"iana"},"image/sgi":{"source":"apache","extensions":["sgi"]},"image/svg+xml":{"source":"iana","compressible":true,"extensions":["svg","svgz"]},"image/t38":{"source":"iana","extensions":["t38"]},"image/tiff":{"source":"iana","compressible":false,"extensions":["tif","tiff"]},"image/tiff-fx":{"source":"iana","extensions":["tfx"]},"image/vnd.adobe.photoshop":{"source":"iana","compressible":true,"extensions":["psd"]},"image/vnd.airzip.accelerator.azv":{"source":"iana","extensions":["azv"]},"image/vnd.cns.inf2":{"source":"iana"},"image/vnd.dece.graphic":{"source":"iana","extensions":["uvi","uvvi","uvg","uvvg"]},"image/vnd.djvu":{"source":"iana","extensions":["djvu","djv"]},"image/vnd.dvb.subtitle":{"source":"iana","extensions":["sub"]},"image/vnd.dwg":{"source":"iana","extensions":["dwg"]},"image/vnd.dxf":{"source":"iana","extensions":["dxf"]},"image/vnd.fastbidsheet":{"source":"iana","extensions":["fbs"]},"image/vnd.fpx":{"source":"iana","extensions":["fpx"]},"image/vnd.fst":{"source":"iana","extensions":["fst"]},"image/vnd.fujixerox.edmics-mmr":{"source":"iana","extensions":["mmr"]},"image/vnd.fujixerox.edmics-rlc":{"source":"iana","extensions":["rlc"]},"image/vnd.globalgraphics.pgb":{"source":"iana"},"image/vnd.microsoft.icon":{"source":"iana","compressible":true,"extensions":["ico"]},"image/vnd.mix":{"source":"iana"},"image/vnd.mozilla.apng":{"source":"iana"},"image/vnd.ms-dds":{"compressible":true,"extensions":["dds"]},"image/vnd.ms-modi":{"source":"iana","extensions":["mdi"]},"image/vnd.ms-photo":{"source":"apache","extensions":["wdp"]},"image/vnd.net-fpx":{"source":"iana","extensions":["npx"]},"image/vnd.pco.b16":{"source":"iana","extensions":["b16"]},"image/vnd.radiance":{"source":"iana"},"image/vnd.sealed.png":{"source":"iana"},"image/vnd.sealedmedia.softseal.gif":{"source":"iana"},"image/vnd.sealedmedia.softseal.jpg":{"source":"iana"},"image/vnd.svf":{"source":"iana"},"image/vnd.tencent.tap":{"source":"iana","extensions":["tap"]},"image/vnd.valve.source.texture":{"source":"iana","extensions":["vtf"]},"image/vnd.wap.wbmp":{"source":"iana","extensions":["wbmp"]},"image/vnd.xiff":{"source":"iana","extensions":["xif"]},"image/vnd.zbrush.pcx":{"source":"iana","extensions":["pcx"]},"image/webp":{"source":"apache","extensions":["webp"]},"image/wmf":{"source":"iana","extensions":["wmf"]},"image/x-3ds":{"source":"apache","extensions":["3ds"]},"image/x-cmu-raster":{"source":"apache","extensions":["ras"]},"image/x-cmx":{"source":"apache","extensions":["cmx"]},"image/x-freehand":{"source":"apache","extensions":["fh","fhc","fh4","fh5","fh7"]},"image/x-icon":{"source":"apache","compressible":true,"extensions":["ico"]},"image/x-jng":{"source":"nginx","extensions":["jng"]},"image/x-mrsid-image":{"source":"apache","extensions":["sid"]},"image/x-ms-bmp":{"source":"nginx","compressible":true,"extensions":["bmp"]},"image/x-pcx":{"source":"apache","extensions":["pcx"]},"image/x-pict":{"source":"apache","extensions":["pic","pct"]},"image/x-portable-anymap":{"source":"apache","extensions":["pnm"]},"image/x-portable-bitmap":{"source":"apache","extensions":["pbm"]},"image/x-portable-graymap":{"source":"apache","extensions":["pgm"]},"image/x-portable-pixmap":{"source":"apache","extensions":["ppm"]},"image/x-rgb":{"source":"apache","extensions":["rgb"]},"image/x-tga":{"source":"apache","extensions":["tga"]},"image/x-xbitmap":{"source":"apache","extensions":["xbm"]},"image/x-xcf":{"compressible":false},"image/x-xpixmap":{"source":"apache","extensions":["xpm"]},"image/x-xwindowdump":{"source":"apache","extensions":["xwd"]},"message/cpim":{"source":"iana"},"message/delivery-status":{"source":"iana"},"message/disposition-notification":{"source":"iana","extensions":["disposition-notification"]},"message/external-body":{"source":"iana"},"message/feedback-report":{"source":"iana"},"message/global":{"source":"iana","extensions":["u8msg"]},"message/global-delivery-status":{"source":"iana","extensions":["u8dsn"]},"message/global-disposition-notification":{"source":"iana","extensions":["u8mdn"]},"message/global-headers":{"source":"iana","extensions":["u8hdr"]},"message/http":{"source":"iana","compressible":false},"message/imdn+xml":{"source":"iana","compressible":true},"message/news":{"source":"iana"},"message/partial":{"source":"iana","compressible":false},"message/rfc822":{"source":"iana","compressible":true,"extensions":["eml","mime"]},"message/s-http":{"source":"iana"},"message/sip":{"source":"iana"},"message/sipfrag":{"source":"iana"},"message/tracking-status":{"source":"iana"},"message/vnd.si.simp":{"source":"iana"},"message/vnd.wfa.wsc":{"source":"iana","extensions":["wsc"]},"model/3mf":{"source":"iana","extensions":["3mf"]},"model/e57":{"source":"iana"},"model/gltf+json":{"source":"iana","compressible":true,"extensions":["gltf"]},"model/gltf-binary":{"source":"iana","compressible":true,"extensions":["glb"]},"model/iges":{"source":"iana","compressible":false,"extensions":["igs","iges"]},"model/mesh":{"source":"iana","compressible":false,"extensions":["msh","mesh","silo"]},"model/mtl":{"source":"iana","extensions":["mtl"]},"model/obj":{"source":"iana","extensions":["obj"]},"model/step":{"source":"iana"},"model/step+xml":{"source":"iana","compressible":true,"extensions":["stpx"]},"model/step+zip":{"source":"iana","compressible":false,"extensions":["stpz"]},"model/step-xml+zip":{"source":"iana","compressible":false,"extensions":["stpxz"]},"model/stl":{"source":"iana","extensions":["stl"]},"model/vnd.collada+xml":{"source":"iana","compressible":true,"extensions":["dae"]},"model/vnd.dwf":{"source":"iana","extensions":["dwf"]},"model/vnd.flatland.3dml":{"source":"iana"},"model/vnd.gdl":{"source":"iana","extensions":["gdl"]},"model/vnd.gs-gdl":{"source":"apache"},"model/vnd.gs.gdl":{"source":"iana"},"model/vnd.gtw":{"source":"iana","extensions":["gtw"]},"model/vnd.moml+xml":{"source":"iana","compressible":true},"model/vnd.mts":{"source":"iana","extensions":["mts"]},"model/vnd.opengex":{"source":"iana","extensions":["ogex"]},"model/vnd.parasolid.transmit.binary":{"source":"iana","extensions":["x_b"]},"model/vnd.parasolid.transmit.text":{"source":"iana","extensions":["x_t"]},"model/vnd.pytha.pyox":{"source":"iana"},"model/vnd.rosette.annotated-data-model":{"source":"iana"},"model/vnd.sap.vds":{"source":"iana","extensions":["vds"]},"model/vnd.usdz+zip":{"source":"iana","compressible":false,"extensions":["usdz"]},"model/vnd.valve.source.compiled-map":{"source":"iana","extensions":["bsp"]},"model/vnd.vtu":{"source":"iana","extensions":["vtu"]},"model/vrml":{"source":"iana","compressible":false,"extensions":["wrl","vrml"]},"model/x3d+binary":{"source":"apache","compressible":false,"extensions":["x3db","x3dbz"]},"model/x3d+fastinfoset":{"source":"iana","extensions":["x3db"]},"model/x3d+vrml":{"source":"apache","compressible":false,"extensions":["x3dv","x3dvz"]},"model/x3d+xml":{"source":"iana","compressible":true,"extensions":["x3d","x3dz"]},"model/x3d-vrml":{"source":"iana","extensions":["x3dv"]},"multipart/alternative":{"source":"iana","compressible":false},"multipart/appledouble":{"source":"iana"},"multipart/byteranges":{"source":"iana"},"multipart/digest":{"source":"iana"},"multipart/encrypted":{"source":"iana","compressible":false},"multipart/form-data":{"source":"iana","compressible":false},"multipart/header-set":{"source":"iana"},"multipart/mixed":{"source":"iana"},"multipart/multilingual":{"source":"iana"},"multipart/parallel":{"source":"iana"},"multipart/related":{"source":"iana","compressible":false},"multipart/report":{"source":"iana"},"multipart/signed":{"source":"iana","compressible":false},"multipart/vnd.bint.med-plus":{"source":"iana"},"multipart/voice-message":{"source":"iana"},"multipart/x-mixed-replace":{"source":"iana"},"text/1d-interleaved-parityfec":{"source":"iana"},"text/cache-manifest":{"source":"iana","compressible":true,"extensions":["appcache","manifest"]},"text/calendar":{"source":"iana","extensions":["ics","ifb"]},"text/calender":{"compressible":true},"text/cmd":{"compressible":true},"text/coffeescript":{"extensions":["coffee","litcoffee"]},"text/cql":{"source":"iana"},"text/cql-expression":{"source":"iana"},"text/cql-identifier":{"source":"iana"},"text/css":{"source":"iana","charset":"UTF-8","compressible":true,"extensions":["css"]},"text/csv":{"source":"iana","compressible":true,"extensions":["csv"]},"text/csv-schema":{"source":"iana"},"text/directory":{"source":"iana"},"text/dns":{"source":"iana"},"text/ecmascript":{"source":"iana"},"text/encaprtp":{"source":"iana"},"text/enriched":{"source":"iana"},"text/fhirpath":{"source":"iana"},"text/flexfec":{"source":"iana"},"text/fwdred":{"source":"iana"},"text/gff3":{"source":"iana"},"text/grammar-ref-list":{"source":"iana"},"text/html":{"source":"iana","compressible":true,"extensions":["html","htm","shtml"]},"text/jade":{"extensions":["jade"]},"text/javascript":{"source":"iana","compressible":true},"text/jcr-cnd":{"source":"iana"},"text/jsx":{"compressible":true,"extensions":["jsx"]},"text/less":{"compressible":true,"extensions":["less"]},"text/markdown":{"source":"iana","compressible":true,"extensions":["markdown","md"]},"text/mathml":{"source":"nginx","extensions":["mml"]},"text/mdx":{"compressible":true,"extensions":["mdx"]},"text/mizar":{"source":"iana"},"text/n3":{"source":"iana","charset":"UTF-8","compressible":true,"extensions":["n3"]},"text/parameters":{"source":"iana","charset":"UTF-8"},"text/parityfec":{"source":"iana"},"text/plain":{"source":"iana","compressible":true,"extensions":["txt","text","conf","def","list","log","in","ini"]},"text/provenance-notation":{"source":"iana","charset":"UTF-8"},"text/prs.fallenstein.rst":{"source":"iana"},"text/prs.lines.tag":{"source":"iana","extensions":["dsc"]},"text/prs.prop.logic":{"source":"iana"},"text/raptorfec":{"source":"iana"},"text/red":{"source":"iana"},"text/rfc822-headers":{"source":"iana"},"text/richtext":{"source":"iana","compressible":true,"extensions":["rtx"]},"text/rtf":{"source":"iana","compressible":true,"extensions":["rtf"]},"text/rtp-enc-aescm128":{"source":"iana"},"text/rtploopback":{"source":"iana"},"text/rtx":{"source":"iana"},"text/sgml":{"source":"iana","extensions":["sgml","sgm"]},"text/shaclc":{"source":"iana"},"text/shex":{"source":"iana","extensions":["shex"]},"text/slim":{"extensions":["slim","slm"]},"text/spdx":{"source":"iana","extensions":["spdx"]},"text/strings":{"source":"iana"},"text/stylus":{"extensions":["stylus","styl"]},"text/t140":{"source":"iana"},"text/tab-separated-values":{"source":"iana","compressible":true,"extensions":["tsv"]},"text/troff":{"source":"iana","extensions":["t","tr","roff","man","me","ms"]},"text/turtle":{"source":"iana","charset":"UTF-8","extensions":["ttl"]},"text/ulpfec":{"source":"iana"},"text/uri-list":{"source":"iana","compressible":true,"extensions":["uri","uris","urls"]},"text/vcard":{"source":"iana","compressible":true,"extensions":["vcard"]},"text/vnd.a":{"source":"iana"},"text/vnd.abc":{"source":"iana"},"text/vnd.ascii-art":{"source":"iana"},"text/vnd.curl":{"source":"iana","extensions":["curl"]},"text/vnd.curl.dcurl":{"source":"apache","extensions":["dcurl"]},"text/vnd.curl.mcurl":{"source":"apache","extensions":["mcurl"]},"text/vnd.curl.scurl":{"source":"apache","extensions":["scurl"]},"text/vnd.debian.copyright":{"source":"iana","charset":"UTF-8"},"text/vnd.dmclientscript":{"source":"iana"},"text/vnd.dvb.subtitle":{"source":"iana","extensions":["sub"]},"text/vnd.esmertec.theme-descriptor":{"source":"iana","charset":"UTF-8"},"text/vnd.familysearch.gedcom":{"source":"iana","extensions":["ged"]},"text/vnd.ficlab.flt":{"source":"iana"},"text/vnd.fly":{"source":"iana","extensions":["fly"]},"text/vnd.fmi.flexstor":{"source":"iana","extensions":["flx"]},"text/vnd.gml":{"source":"iana"},"text/vnd.graphviz":{"source":"iana","extensions":["gv"]},"text/vnd.hans":{"source":"iana"},"text/vnd.hgl":{"source":"iana"},"text/vnd.in3d.3dml":{"source":"iana","extensions":["3dml"]},"text/vnd.in3d.spot":{"source":"iana","extensions":["spot"]},"text/vnd.iptc.newsml":{"source":"iana"},"text/vnd.iptc.nitf":{"source":"iana"},"text/vnd.latex-z":{"source":"iana"},"text/vnd.motorola.reflex":{"source":"iana"},"text/vnd.ms-mediapackage":{"source":"iana"},"text/vnd.net2phone.commcenter.command":{"source":"iana"},"text/vnd.radisys.msml-basic-layout":{"source":"iana"},"text/vnd.senx.warpscript":{"source":"iana"},"text/vnd.si.uricatalogue":{"source":"iana"},"text/vnd.sosi":{"source":"iana"},"text/vnd.sun.j2me.app-descriptor":{"source":"iana","charset":"UTF-8","extensions":["jad"]},"text/vnd.trolltech.linguist":{"source":"iana","charset":"UTF-8"},"text/vnd.wap.si":{"source":"iana"},"text/vnd.wap.sl":{"source":"iana"},"text/vnd.wap.wml":{"source":"iana","extensions":["wml"]},"text/vnd.wap.wmlscript":{"source":"iana","extensions":["wmls"]},"text/vtt":{"source":"iana","charset":"UTF-8","compressible":true,"extensions":["vtt"]},"text/x-asm":{"source":"apache","extensions":["s","asm"]},"text/x-c":{"source":"apache","extensions":["c","cc","cxx","cpp","h","hh","dic"]},"text/x-component":{"source":"nginx","extensions":["htc"]},"text/x-fortran":{"source":"apache","extensions":["f","for","f77","f90"]},"text/x-gwt-rpc":{"compressible":true},"text/x-handlebars-template":{"extensions":["hbs"]},"text/x-java-source":{"source":"apache","extensions":["java"]},"text/x-jquery-tmpl":{"compressible":true},"text/x-lua":{"extensions":["lua"]},"text/x-markdown":{"compressible":true,"extensions":["mkd"]},"text/x-nfo":{"source":"apache","extensions":["nfo"]},"text/x-opml":{"source":"apache","extensions":["opml"]},"text/x-org":{"compressible":true,"extensions":["org"]},"text/x-pascal":{"source":"apache","extensions":["p","pas"]},"text/x-processing":{"compressible":true,"extensions":["pde"]},"text/x-sass":{"extensions":["sass"]},"text/x-scss":{"extensions":["scss"]},"text/x-setext":{"source":"apache","extensions":["etx"]},"text/x-sfv":{"source":"apache","extensions":["sfv"]},"text/x-suse-ymp":{"compressible":true,"extensions":["ymp"]},"text/x-uuencode":{"source":"apache","extensions":["uu"]},"text/x-vcalendar":{"source":"apache","extensions":["vcs"]},"text/x-vcard":{"source":"apache","extensions":["vcf"]},"text/xml":{"source":"iana","compressible":true,"extensions":["xml"]},"text/xml-external-parsed-entity":{"source":"iana"},"text/yaml":{"compressible":true,"extensions":["yaml","yml"]},"video/1d-interleaved-parityfec":{"source":"iana"},"video/3gpp":{"source":"iana","extensions":["3gp","3gpp"]},"video/3gpp-tt":{"source":"iana"},"video/3gpp2":{"source":"iana","extensions":["3g2"]},"video/av1":{"source":"iana"},"video/bmpeg":{"source":"iana"},"video/bt656":{"source":"iana"},"video/celb":{"source":"iana"},"video/dv":{"source":"iana"},"video/encaprtp":{"source":"iana"},"video/ffv1":{"source":"iana"},"video/flexfec":{"source":"iana"},"video/h261":{"source":"iana","extensions":["h261"]},"video/h263":{"source":"iana","extensions":["h263"]},"video/h263-1998":{"source":"iana"},"video/h263-2000":{"source":"iana"},"video/h264":{"source":"iana","extensions":["h264"]},"video/h264-rcdo":{"source":"iana"},"video/h264-svc":{"source":"iana"},"video/h265":{"source":"iana"},"video/iso.segment":{"source":"iana","extensions":["m4s"]},"video/jpeg":{"source":"iana","extensions":["jpgv"]},"video/jpeg2000":{"source":"iana"},"video/jpm":{"source":"apache","extensions":["jpm","jpgm"]},"video/jxsv":{"source":"iana"},"video/mj2":{"source":"iana","extensions":["mj2","mjp2"]},"video/mp1s":{"source":"iana"},"video/mp2p":{"source":"iana"},"video/mp2t":{"source":"iana","extensions":["ts"]},"video/mp4":{"source":"iana","compressible":false,"extensions":["mp4","mp4v","mpg4"]},"video/mp4v-es":{"source":"iana"},"video/mpeg":{"source":"iana","compressible":false,"extensions":["mpeg","mpg","mpe","m1v","m2v"]},"video/mpeg4-generic":{"source":"iana"},"video/mpv":{"source":"iana"},"video/nv":{"source":"iana"},"video/ogg":{"source":"iana","compressible":false,"extensions":["ogv"]},"video/parityfec":{"source":"iana"},"video/pointer":{"source":"iana"},"video/quicktime":{"source":"iana","compressible":false,"extensions":["qt","mov"]},"video/raptorfec":{"source":"iana"},"video/raw":{"source":"iana"},"video/rtp-enc-aescm128":{"source":"iana"},"video/rtploopback":{"source":"iana"},"video/rtx":{"source":"iana"},"video/scip":{"source":"iana"},"video/smpte291":{"source":"iana"},"video/smpte292m":{"source":"iana"},"video/ulpfec":{"source":"iana"},"video/vc1":{"source":"iana"},"video/vc2":{"source":"iana"},"video/vnd.cctv":{"source":"iana"},"video/vnd.dece.hd":{"source":"iana","extensions":["uvh","uvvh"]},"video/vnd.dece.mobile":{"source":"iana","extensions":["uvm","uvvm"]},"video/vnd.dece.mp4":{"source":"iana"},"video/vnd.dece.pd":{"source":"iana","extensions":["uvp","uvvp"]},"video/vnd.dece.sd":{"source":"iana","extensions":["uvs","uvvs"]},"video/vnd.dece.video":{"source":"iana","extensions":["uvv","uvvv"]},"video/vnd.directv.mpeg":{"source":"iana"},"video/vnd.directv.mpeg-tts":{"source":"iana"},"video/vnd.dlna.mpeg-tts":{"source":"iana"},"video/vnd.dvb.file":{"source":"iana","extensions":["dvb"]},"video/vnd.fvt":{"source":"iana","extensions":["fvt"]},"video/vnd.hns.video":{"source":"iana"},"video/vnd.iptvforum.1dparityfec-1010":{"source":"iana"},"video/vnd.iptvforum.1dparityfec-2005":{"source":"iana"},"video/vnd.iptvforum.2dparityfec-1010":{"source":"iana"},"video/vnd.iptvforum.2dparityfec-2005":{"source":"iana"},"video/vnd.iptvforum.ttsavc":{"source":"iana"},"video/vnd.iptvforum.ttsmpeg2":{"source":"iana"},"video/vnd.motorola.video":{"source":"iana"},"video/vnd.motorola.videop":{"source":"iana"},"video/vnd.mpegurl":{"source":"iana","extensions":["mxu","m4u"]},"video/vnd.ms-playready.media.pyv":{"source":"iana","extensions":["pyv"]},"video/vnd.nokia.interleaved-multimedia":{"source":"iana"},"video/vnd.nokia.mp4vr":{"source":"iana"},"video/vnd.nokia.videovoip":{"source":"iana"},"video/vnd.objectvideo":{"source":"iana"},"video/vnd.radgamettools.bink":{"source":"iana"},"video/vnd.radgamettools.smacker":{"source":"iana"},"video/vnd.sealed.mpeg1":{"source":"iana"},"video/vnd.sealed.mpeg4":{"source":"iana"},"video/vnd.sealed.swf":{"source":"iana"},"video/vnd.sealedmedia.softseal.mov":{"source":"iana"},"video/vnd.uvvu.mp4":{"source":"iana","extensions":["uvu","uvvu"]},"video/vnd.vivo":{"source":"iana","extensions":["viv"]},"video/vnd.youtube.yt":{"source":"iana"},"video/vp8":{"source":"iana"},"video/vp9":{"source":"iana"},"video/webm":{"source":"apache","compressible":false,"extensions":["webm"]},"video/x-f4v":{"source":"apache","extensions":["f4v"]},"video/x-fli":{"source":"apache","extensions":["fli"]},"video/x-flv":{"source":"apache","compressible":false,"extensions":["flv"]},"video/x-m4v":{"source":"apache","extensions":["m4v"]},"video/x-matroska":{"source":"apache","compressible":false,"extensions":["mkv","mk3d","mks"]},"video/x-mng":{"source":"apache","extensions":["mng"]},"video/x-ms-asf":{"source":"apache","extensions":["asf","asx"]},"video/x-ms-vob":{"source":"apache","extensions":["vob"]},"video/x-ms-wm":{"source":"apache","extensions":["wm"]},"video/x-ms-wmv":{"source":"apache","compressible":false,"extensions":["wmv"]},"video/x-ms-wmx":{"source":"apache","extensions":["wmx"]},"video/x-ms-wvx":{"source":"apache","extensions":["wvx"]},"video/x-msvideo":{"source":"apache","extensions":["avi"]},"video/x-sgi-movie":{"source":"apache","extensions":["movie"]},"video/x-smv":{"source":"apache","extensions":["smv"]},"x-conference/x-cooltalk":{"source":"apache","extensions":["ice"]},"x-shader/x-fragment":{"compressible":true},"x-shader/x-vertex":{"compressible":true}}')}},t={};function n(r){var o=t[r];if(void 0!==o)return o.exports;var i=t[r]={exports:{}};return e[r].call(i.exports,i,i.exports,n),i.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var r={};(()=>{"use strict";var e=r;Object.defineProperty(e,"__esModule",{value:!0}),e.activate=void 0;const t=n(235),o=n(1398),i=n(9896),s=n(6928),a=n(857),c=n(9699),u=n(1991),l=n(9354),p=n(7768),d=n(1018),h=n(8768),f=n(6129),m=n(5723),v=n(1113),g=n(1413),y=n(6752),_=n(76),b=n(1651),E=n(3508),T=n(9084),S=n(7147),C=n(1289),x=n(9011),w=n(2748),A=n(4502),I=n(2562),R=n(4663);let P;function O(e){P.subscriptions.push(e)}function N(){const e=o.workspace.getConfiguration(E.AzureSection).get("piiLogging",!1);S.Logger.piiLogging=e}e.activate=async function(e){P=e;let n=new c.AppContext(P),r=await async function(){let e=s.join(function(){switch(process.platform){case E.Platform.Windows:return process.env.APPDATA||s.join(process.env.USERPROFILE,"AppData","Roaming");case E.Platform.Mac:return s.join(a.homedir(),"Library","Application Support");case E.Platform.Linux:return process.env.XDG_CONFIG_HOME||s.join(a.homedir(),".config");default:throw new Error("Platform not supported")}}(),E.ServiceName),t=s.join(e,E.AzureTokenFolderName);try{await i.promises.mkdir(e,{recursive:!0})}catch(e){if("EEXIST"!==e.code)return void S.Logger.error(`Creating the base directory failed... ${e}`)}try{await i.promises.mkdir(t,{recursive:!0})}catch(e){if("EEXIST"!==e.code)return S.Logger.error(`Initialization of Azure account extension storage failed: ${e}`),void S.Logger.error("Azure accounts will not be available")}return S.Logger.verbose("Initialized Azure account extension storage."),t}();if(!r)throw new Error("Could not find or create storage path");const k=o.workspace.getConfiguration(E.AccountsAzureAuthSection);let D;o.env.uiKind===o.UIKind.Web&&await k.update("deviceCode",!0,o.ConfigurationTarget.Global),o.workspace.getConfiguration(E.AzureSection).get(E.piiLogging,!1)&&o.window.showWarningMessage(b.piiWarning,b.disable,b.dismiss).then((async e=>{e===b.disable&&await o.workspace.getConfiguration(E.AzureSection).update(E.piiLogging,!1,o.ConfigurationTarget.Global)})),N();let M=await async function(e,t){try{const n=new u.AzureAccountProviderService(e,t);return e.subscriptions.push(n),await n.activate(),n}catch(e){return void S.Logger.error("Unexpected error starting account provider: "+e.message)}}(P,r).catch((e=>S.Logger.error(e)));if(M){D=M.getEncryptionKeysEmitter(),function(e){e.registerService(p.AzureResourceServiceNames.resourceService,new l.AzureResourceService),e.registerService(p.AzureResourceServiceNames.resourceGroupService,new T.AzureResourceGroupService),e.registerService(p.AzureResourceServiceNames.cacheService,new f.AzureResourceCacheService(P)),e.registerService(p.AzureResourceServiceNames.subscriptionService,new d.AzureResourceSubscriptionService),e.registerService(p.AzureResourceServiceNames.subscriptionFilterService,new h.AzureResourceSubscriptionFilterService(new f.AzureResourceCacheService(P))),e.registerService(p.AzureResourceServiceNames.tenantFilterService,new R.AzureResourceTenantFilterService(new f.AzureResourceCacheService(P))),e.registerService(p.AzureResourceServiceNames.terminalService,new g.AzureTerminalService(P))}(n);const e=new v.AzureResourceTreeProvider(n),r=new C.ConnectionDialogTreeProvider(n);O(o.window.registerTreeDataProvider("azureResourceExplorer",e)),O(o.window.registerTreeDataProvider("connectionDialog/azureResourceExplorer",r)),O(o.workspace.onDidChangeConfiguration((e=>async function(e){e.affectsConfiguration("azure.piiLogging")&&N()}(e)))),(0,m.registerAzureResourceCommands)(n,e,r),t.dataprotocol.registerDataGridProvider(new x.AzureDataGridProvider(n)),o.commands.registerCommand("azure.dataGrid.openInAzurePortal",(async e=>{const t=e.portalEndpoint,n=e.subscriptionId,r=e.resourceGroup,i=e.type,s=e.name;t&&n&&r&&i&&s?await o.env.openExternal(o.Uri.parse(`${t}/#resource/subscriptions/${n}/resourceGroups/${r}/providers/${i}/${s}`)):(S.Logger.error(`Missing required values - subscriptionId : ${n} resourceGroup : ${r} type: ${i} name: ${s}`),o.window.showErrorMessage(b.unableToOpenAzureLink))}))}return{getSubscriptions:(e,t,r=!1)=>r?y.getSelectedSubscriptions(n,e,t):y.getSubscriptions(n,e,t),getResourceGroups:(e,t,r)=>y.getResourceGroups(n,e,t,r),getLocations:(e,t,r)=>y.getLocations(n,e,t,r),provideResources:()=>y.getAllResourceProviders(P),getUniversalProvider(){let e=y.getAllResourceProviders(P),t=new Map;return e.forEach((e=>{t.set(e.providerId,e.getTreeDataProvider())})),new I.AzureResourceUniversalResourceProvider(E.UNIVERSAL_PROVIDER_ID,new A.AzureResourceUniversalTreeDataProvider(new w.AzureResourceUniversalService(t)))},getSqlManagedInstances:(e,t,n)=>y.runResourceQuery(e,t,n,'where type == "microsoft.sql/managedinstances"'),getManagedDatabases:(e,t,n,r)=>y.getManagedDatabases(e,t,n,r),getSqlServers:(e,t,n)=>y.runResourceQuery(e,t,n,'where type == "microsoft.sql/servers"'),getSqlVMServers:(e,t,n)=>y.runResourceQuery(e,t,n,'where type == "microsoft.compute/virtualmachines" and properties.storageProfile.imageReference.publisher == "microsoftsqlserver"'),getStorageAccounts:(e,t,n)=>y.runResourceQuery(e,t,n,'where type == "microsoft.storage/storageaccounts"'),getBlobContainers:(e,t,n,r)=>y.getBlobContainers(e,t,n,r),getFileShares:(e,t,n,r)=>y.getFileShares(e,t,n,r),getStorageAccountAccessKey:(e,t,n,r)=>y.getStorageAccountAccessKey(e,t,n,r),getBlobs:(e,t,n,r,o)=>y.getBlobs(e,t,n,r,o),createResourceGroup:(e,t,n,r,o)=>y.createResourceGroup(e,t,n,r,o),makeAzureRestRequest:(e,t,n,r,o,i,s="https://management.azure.com",a={})=>y.makeHttpRequest(e,t,n,r,o,i,s,a),getRegionDisplayName:_.getRegionDisplayName,getProviderMetadataForAccount:e=>y.getProviderMetadataForAccount(e),runGraphQuery:(e,t,n,r)=>y.runResourceQuery(e,t,n,r),onEncryptionKeysUpdated:D.event,async getEncryptionKeys(){if(!M)throw new Error("Failed to initialize Azure account provider.");return await M.getEncryptionKeys()}}}})();var o=exports;for(var i in r)o[i]=r[i];r.__esModule&&Object.defineProperty(o,"__esModule",{value:!0})})();
//# sourceMappingURL=https://sqlopsbuilds.blob.core.windows.net/sourcemaps/82e35eb142bf0f4567ff8c6dd4f16f33abfc2d50/extensions/azurecore/dist/extension.js.map