@zuplo/core 5.1675.0 → 5.1677.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/create.index.minified.js +46 -46
- package/index.minified.js +1 -1
- package/package.json +1 -1
package/index.minified.js
CHANGED
|
@@ -392,7 +392,7 @@ ${h}
|
|
|
392
392
|
Content-Type: ${i["Content-Type"]}\r
|
|
393
393
|
\r
|
|
394
394
|
`;n.write(s);if(typeof i.body==="string"){n.write(i.body);n.write("\r\n")}else{i.body.pipe(n,{end:false});i.body.on("end",()=>{n.write("\r\n");n.write(r);n.end()})}}return n}a(kan,"createMultipartStream");function Zu(e,t){const{uri:r,options:n}=Ian(e);const i=e.multipart;if(e.multipart&&i.length===2){if(!t){throw new Error("Multipart without callback is not implemented.")}const s=Oan.v4();n.headers["Content-Type"]=`multipart/related; boundary=${s}`;n.body=kan(s,i);Zu.stats.requestStarting();(0,v2e.default)(r,n).then(o=>{Zu.stats.requestFinished();const u=o.headers.get("content-type");const l=dW(n,o);const c=l.body;if(u==="application/json"||u==="application/json; charset=utf-8"){o.json().then(d=>{l.body=d;t(null,l,d)},d=>{t(d,l,c)});return}o.text().then(d=>{l.body=d;t(null,l,d)},d=>{t(d,l,c)})},o=>{Zu.stats.requestFinished();t(o,null,null)});return}if(t===void 0){const s=Nan(new pW.PassThrough);let o;s.once("reading",()=>{if(o){(0,pW.pipeline)(o,s,()=>{})}else{s.once("response",()=>{(0,pW.pipeline)(o,s,()=>{})})}});n.compress=false;Zu.stats.requestStarting();(0,v2e.default)(r,n).then(u=>{Zu.stats.requestFinished();o=u.body;o.on("error",c=>{s.emit("error",c)});const l=dW(n,u);s.emit("response",l)},u=>{Zu.stats.requestFinished();s.emit("error",u)});return s}Zu.stats.requestStarting();(0,v2e.default)(r,n).then(s=>{Zu.stats.requestFinished();const o=s.headers.get("content-type");const u=dW(n,s);const l=u.body;if(o==="application/json"||o==="application/json; charset=utf-8"){if(u.statusCode===204){t(null,u,l);return}s.json().then(c=>{u.body=c;t(null,u,c)},c=>{t(c,u,l)});return}s.text().then(c=>{const d=dW(n,s);d.body=c;t(null,d,c)},c=>{t(c,u,l)})},s=>{Zu.stats.requestFinished();t(s,null,null)});return}a(Zu,"teenyRequest");zR.teenyRequest=Zu;Zu.defaults=e=>{return(t,r)=>{const n={...e,...t};if(r===void 0){return Zu(n)}Zu(n,r)}};Zu.stats=new Ngt.TeenyStatistics;Zu.resetStats=()=>{Zu.stats=new Ngt.TeenyStatistics(Zu.stats.getOptions())}});var kgt=y((HRs,Dan)=>{Dan.exports={name:"@google-cloud/storage",description:"Cloud Storage Client Library for Node.js",version:"7.5.0",license:"Apache-2.0",author:"Google Inc.",engines:{node:">=14"},repository:"googleapis/nodejs-storage",main:"./build/cjs/src/index.js",types:"./build/cjs/src/index.d.ts",type:"module",exports:{".":{import:{types:"./build/esm/src/index.d.ts",default:"./build/esm/src/index.js"},require:{types:"./build/cjs/src/index.d.ts",default:"./build/cjs/src/index.js"}}},files:["build/cjs/src","build/cjs/package.json","!build/cjs/src/**/*.map","build/esm/src","!build/esm/src/**/*.map"],keywords:["google apis client","google api client","google apis","google api","google","google cloud platform","google cloud","cloud","google storage","storage"],scripts:{"all-test":"npm test && npm run system-test && npm run samples-test",benchwrapper:"node bin/benchwrapper.js",check:"gts check",clean:"rm -rf build/","compile:cjs":"tsc -p ./tsconfig.cjs.json","compile:esm":"tsc -p .",compile:"npm run compile:cjs && npm run compile:esm","conformance-test":"mocha --parallel build/cjs/conformance-test/ --require build/cjs/conformance-test/globalHooks.js","docs-test":"linkinator docs",docs:"jsdoc -c .jsdoc.json",fix:"gts fix",lint:"gts check",postcompile:"cp ./src/package-json-helper.cjs ./build/cjs/src && cp ./src/package-json-helper.cjs ./build/esm/src","postcompile:cjs":"babel --plugins gapic-tools/build/src/replaceImportMetaUrl,gapic-tools/build/src/toggleESMFlagVariable build/cjs/src/util.js -o build/cjs/src/util.js && cp internal-tooling/helpers/package.cjs.json build/cjs/package.json",precompile:"rm -rf build/","preconformance-test":"npm run compile:cjs -- --sourceMap","predocs-test":"npm run docs",predocs:"npm run compile:cjs -- --sourceMap",prelint:"cd samples; npm link ../; npm install",prepare:"npm run compile","presystem-test:esm":"npm run compile:esm","presystem-test":"npm run compile -- --sourceMap",pretest:"npm run compile -- --sourceMap","samples-test":"npm link && cd samples/ && npm link ../ && npm test && cd ../","system-test:esm":"mocha build/esm/system-test --timeout 600000 --exit","system-test":"mocha build/cjs/system-test --timeout 600000 --exit",test:"c8 mocha build/cjs/test"},dependencies:{"@google-cloud/paginator":"^5.0.0","@google-cloud/projectify":"^4.0.0","@google-cloud/promisify":"^4.0.0","abort-controller":"^3.0.0","async-retry":"^1.3.3",compressible:"^2.0.12",duplexify:"^4.0.0",ent:"^2.2.0","fast-xml-parser":"^4.3.0",gaxios:"^6.0.2","google-auth-library":"^9.0.0",mime:"^3.0.0","mime-types":"^2.0.8","p-limit":"^3.0.1","retry-request":"^7.0.0","teeny-request":"^9.0.0",uuid:"^8.0.0"},devDependencies:{"@babel/cli":"^7.22.10","@babel/core":"^7.22.11","@google-cloud/pubsub":"^4.0.0","@grpc/grpc-js":"^1.0.3","@grpc/proto-loader":"^0.7.0","@types/async-retry":"^1.4.3","@types/compressible":"^2.0.0","@types/ent":"^2.2.1","@types/mime":"^3.0.0","@types/mime-types":"^2.1.0","@types/mocha":"^9.1.1","@types/mockery":"^1.4.29","@types/node":"^20.4.4","@types/node-fetch":"^2.1.3","@types/proxyquire":"^1.3.28","@types/request":"^2.48.4","@types/sinon":"^10.0.15","@types/tmp":"0.2.5","@types/uuid":"^8.0.0","@types/yargs":"^17.0.10",c8:"^8.0.0","form-data":"^4.0.0","gapic-tools":"^0.2.0",gts:"^5.0.0",jsdoc:"^4.0.0","jsdoc-fresh":"^3.0.0","jsdoc-region-tag":"^3.0.0",linkinator:"^4.0.0",mocha:"^9.2.2",mockery:"^2.1.0",nock:"~13.3.0","node-fetch":"^2.6.7","pack-n-play":"^2.0.0",proxyquire:"^2.1.3",sinon:"^17.0.0",tmp:"^0.2.0",typescript:"^5.1.6",yargs:"^17.3.1"}}});var KR=y(Dgt=>{function Lan(){return kgt()}a(Lan,"getPackageJSON");Dgt.getPackageJSON=Lan});var P0=y(yi=>{"use strict";var Fan=yi&&yi.__createBinding||(Object.create?function(e,t,r,n){if(n===void 0)n=r;var i=Object.getOwnPropertyDescriptor(t,r);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[r]}}}Object.defineProperty(e,n,i)}:function(e,t,r,n){if(n===void 0)n=r;e[n]=t[r]});var Ban=yi&&yi.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var A2e=yi&&yi.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null){for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))Fan(t,e,r)}Ban(t,e);return t};Object.defineProperty(yi,"__esModule",{value:true});yi.PassThroughShim=yi.getModuleFormat=yi.getDirName=yi.getUserAgentString=yi.getRuntimeTrackingString=yi.formatAsUTCISO=yi.convertObjKeysToSnakeCase=yi.unicodeJSONStringify=yi.objectKeyToLowercase=yi.qsStringify=yi.encodeURI=yi.fixedEncodeURIComponent=yi.objectEntries=yi.normalize=void 0;var KRs=A2e(require("path"));var Man=A2e(require("querystring"));var qan=require("stream");var Uan=A2e(require("url"));var $an=KR();var WRs=Uan.fileURLToPath;var jan=false;function Gan(e,t){const r=typeof e==="object"?e:{};const n=typeof e==="function"?e:t;return{options:r,callback:n}}a(Gan,"normalize");yi.normalize=Gan;function Han(e){return Object.keys(e).map(t=>[t,e[t]])}a(Han,"objectEntries");yi.objectEntries=Han;function Lgt(e){return encodeURIComponent(e).replace(/[!'()*]/g,t=>"%"+t.charCodeAt(0).toString(16).toUpperCase())}a(Lgt,"fixedEncodeURIComponent");yi.fixedEncodeURIComponent=Lgt;function Fgt(e,t){return e.split("/").map(Lgt).join(t?"%2F":"/")}a(Fgt,"encodeURI");yi.encodeURI=Fgt;function Van(e){return Man.stringify(e,"&","=",{encodeURIComponent:t=>Fgt(t,true)})}a(Van,"qsStringify");yi.qsStringify=Van;function zan(e){const t={};for(let r of Object.keys(e)){const n=e[r];r=r.toLowerCase();t[r]=n}return t}a(zan,"objectKeyToLowercase");yi.objectKeyToLowercase=zan;function Kan(e){return JSON.stringify(e).replace(/[\u0080-\uFFFF]/g,t=>"\\u"+("0000"+t.charCodeAt(0).toString(16)).slice(-4))}a(Kan,"unicodeJSONStringify");yi.unicodeJSONStringify=Kan;function b2e(e){if(e instanceof Date||e instanceof RegExp){return e}if(Array.isArray(e)){return e.map(b2e)}if(e instanceof Object){return Object.keys(e).reduce((t,r)=>{const n=r[0].toLocaleLowerCase()+r.slice(1).replace(/([A-Z]+)/g,(i,s)=>{return`_${s.toLowerCase()}`});t[n]=b2e(e[r]);return t},Object())}return e}a(b2e,"convertObjKeysToSnakeCase");yi.convertObjKeysToSnakeCase=b2e;function Wan(e,t=false,r="",n=""){const i=e.getUTCFullYear();const s=e.getUTCMonth()+1;const o=e.getUTCDate();const u=e.getUTCHours();const l=e.getUTCMinutes();const c=e.getUTCSeconds();let d=`${i.toString().padStart(4,"0")}${r}${s.toString().padStart(2,"0")}${r}${o.toString().padStart(2,"0")}`;if(t){d=`${d}T${u.toString().padStart(2,"0")}${n}${l.toString().padStart(2,"0")}${n}${c.toString().padStart(2,"0")}Z`}return d}a(Wan,"formatAsUTCISO");yi.formatAsUTCISO=Wan;function Yan(){if(globalThis.Deno&&globalThis.Deno.version&&globalThis.Deno.version.deno){return`gl-deno/${globalThis.Deno.version.deno}`}else{return`gl-node/${process.versions.node}`}}a(Yan,"getRuntimeTrackingString");yi.getRuntimeTrackingString=Yan;function Xan(){const e=(0,$an.getPackageJSON)();const t=e.name.replace("@google-cloud","gcloud-node").replace("/","-");return t+"/"+e.version}a(Xan,"getUserAgentString");yi.getUserAgentString=Xan;function Jan(){let e="";try{e=__dirname}catch(t){e=__dirname}return e}a(Jan,"getDirName");yi.getDirName=Jan;function Qan(){return jan?"ESM":"CJS"}a(Qan,"getModuleFormat");yi.getModuleFormat=Qan;var S2e=class extends qan.PassThrough{static{a(this,"PassThroughShim")}constructor(){super(...arguments);this.shouldEmitReading=true;this.shouldEmitWriting=true}_read(t){if(this.shouldEmitReading){this.emit("reading");this.shouldEmitReading=false}super._read(t)}_write(t,r,n){if(this.shouldEmitWriting){this.emit("writing");this.shouldEmitWriting=false}process.nextTick(()=>{super._write(t,r,n)})}_final(t){if(this.shouldEmitReading){this.emit("reading");this.shouldEmitReading=false}if(this.shouldEmitWriting){this.emit("writing");this.shouldEmitWriting=false}t(null)}};yi.PassThroughShim=S2e});var C2e=y((JRs,Bgt)=>{Bgt.exports=require("stream")});var $gt=y((QRs,Ugt)=>{"use strict";function Mgt(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);if(t)n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable});r.push.apply(r,n)}return r}a(Mgt,"ownKeys");function Zan(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};if(t%2){Mgt(Object(r),true).forEach(function(n){eon(e,n,r[n])})}else if(Object.getOwnPropertyDescriptors){Object.defineProperties(e,Object.getOwnPropertyDescriptors(r))}else{Mgt(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}}return e}a(Zan,"_objectSpread");function eon(e,t,r){if(t in e){Object.defineProperty(e,t,{value:r,enumerable:true,configurable:true,writable:true})}else{e[t]=r}return e}a(eon,"_defineProperty");function ton(e,t){if(!(e instanceof t)){throw new TypeError("Cannot call a class as a function")}}a(ton,"_classCallCheck");function qgt(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||false;n.configurable=true;if("value"in n)n.writable=true;Object.defineProperty(e,n.key,n)}}a(qgt,"_defineProperties");function ron(e,t,r){if(t)qgt(e.prototype,t);if(r)qgt(e,r);return e}a(ron,"_createClass");var non=require("buffer");var fW=non.Buffer;var ion=require("util");var w2e=ion.inspect;var son=w2e&&w2e.custom||"inspect";function aon(e,t,r){fW.prototype.copy.call(e,t,r)}a(aon,"copyBuffer");Ugt.exports=function(){function e(){ton(this,e);this.head=null;this.tail=null;this.length=0}a(e,"BufferList");ron(e,[{key:"push",value:a(function t(r){var n={data:r,next:null};if(this.length>0)this.tail.next=n;else this.head=n;this.tail=n;++this.length},"push")},{key:"unshift",value:a(function t(r){var n={data:r,next:this.head};if(this.length===0)this.tail=n;this.head=n;++this.length},"unshift")},{key:"shift",value:a(function t(){if(this.length===0)return;var r=this.head.data;if(this.length===1)this.head=this.tail=null;else this.head=this.head.next;--this.length;return r},"shift")},{key:"clear",value:a(function t(){this.head=this.tail=null;this.length=0},"clear")},{key:"join",value:a(function t(r){if(this.length===0)return"";var n=this.head;var i=""+n.data;while(n=n.next){i+=r+n.data}return i},"join")},{key:"concat",value:a(function t(r){if(this.length===0)return fW.alloc(0);var n=fW.allocUnsafe(r>>>0);var i=this.head;var s=0;while(i){aon(i.data,n,s);s+=i.data.length;i=i.next}return n},"concat")},{key:"consume",value:a(function t(r,n){var i;if(r<this.head.data.length){i=this.head.data.slice(0,r);this.head.data=this.head.data.slice(r)}else if(r===this.head.data.length){i=this.shift()}else{i=n?this._getString(r):this._getBuffer(r)}return i},"consume")},{key:"first",value:a(function t(){return this.head.data},"first")},{key:"_getString",value:a(function t(r){var n=this.head;var i=1;var s=n.data;r-=s.length;while(n=n.next){var o=n.data;var u=r>o.length?o.length:r;if(u===o.length)s+=o;else s+=o.slice(0,r);r-=u;if(r===0){if(u===o.length){++i;if(n.next)this.head=n.next;else this.head=this.tail=null}else{this.head=n;n.data=o.slice(u)}break}++i}this.length-=i;return s},"_getString")},{key:"_getBuffer",value:a(function t(r){var n=fW.allocUnsafe(r);var i=this.head;var s=1;i.data.copy(n);r-=i.data.length;while(i=i.next){var o=i.data;var u=r>o.length?o.length:r;o.copy(n,n.length-r,0,u);r-=u;if(r===0){if(u===o.length){++s;if(i.next)this.head=i.next;else this.head=this.tail=null}else{this.head=i;i.data=o.slice(u)}break}++s}this.length-=s;return n},"_getBuffer")},{key:son,value:a(function t(r,n){return w2e(this,Zan({},n,{depth:0,customInspect:false}))},"value")}]);return e}()});var x2e=y((eOs,Ggt)=>{"use strict";function oon(e,t){var r=this;var n=this._readableState&&this._readableState.destroyed;var i=this._writableState&&this._writableState.destroyed;if(n||i){if(t){t(e)}else if(e){if(!this._writableState){process.nextTick(T2e,this,e)}else if(!this._writableState.errorEmitted){this._writableState.errorEmitted=true;process.nextTick(T2e,this,e)}}return this}if(this._readableState){this._readableState.destroyed=true}if(this._writableState){this._writableState.destroyed=true}this._destroy(e||null,function(s){if(!t&&s){if(!r._writableState){process.nextTick(jgt,r,s)}else if(!r._writableState.errorEmitted){r._writableState.errorEmitted=true;process.nextTick(jgt,r,s)}else{process.nextTick(mW,r)}}else if(t){process.nextTick(mW,r);t(s)}else{process.nextTick(mW,r)}});return this}a(oon,"destroy");function jgt(e,t){T2e(e,t);mW(e)}a(jgt,"emitErrorAndCloseNT");function mW(e){if(e._writableState&&!e._writableState.emitClose)return;if(e._readableState&&!e._readableState.emitClose)return;e.emit("close")}a(mW,"emitCloseNT");function uon(){if(this._readableState){this._readableState.destroyed=false;this._readableState.reading=false;this._readableState.ended=false;this._readableState.endEmitted=false}if(this._writableState){this._writableState.destroyed=false;this._writableState.ended=false;this._writableState.ending=false;this._writableState.finalCalled=false;this._writableState.prefinished=false;this._writableState.finished=false;this._writableState.errorEmitted=false}}a(uon,"undestroy");function T2e(e,t){e.emit("error",t)}a(T2e,"emitErrorNT");function lon(e,t){var r=e._readableState;var n=e._writableState;if(r&&r.autoDestroy||n&&n.autoDestroy)e.destroy(t);else e.emit("error",t)}a(lon,"errorOrDestroy");Ggt.exports={destroy:oon,undestroy:uon,errorOrDestroy:lon}});var Xv=y((rOs,zgt)=>{"use strict";var Vgt={};function mf(e,t,r){if(!r){r=Error}function n(s,o,u){if(typeof t==="string"){return t}else{return t(s,o,u)}}a(n,"getMessage");class i extends r{static{a(this,"NodeError")}constructor(o,u,l){super(n(o,u,l))}}i.prototype.name=r.name;i.prototype.code=e;Vgt[e]=i}a(mf,"createErrorType");function Hgt(e,t){if(Array.isArray(e)){const r=e.length;e=e.map(n=>String(n));if(r>2){return`one of ${t} ${e.slice(0,r-1).join(", ")}, or `+e[r-1]}else if(r===2){return`one of ${t} ${e[0]} or ${e[1]}`}else{return`of ${t} ${e[0]}`}}else{return`of ${t} ${String(e)}`}}a(Hgt,"oneOf");function con(e,t,r){return e.substr(!r||r<0?0:+r,t.length)===t}a(con,"startsWith");function don(e,t,r){if(r===void 0||r>e.length){r=e.length}return e.substring(r-t.length,r)===t}a(don,"endsWith");function pon(e,t,r){if(typeof r!=="number"){r=0}if(r+t.length>e.length){return false}else{return e.indexOf(t,r)!==-1}}a(pon,"includes");mf("ERR_INVALID_OPT_VALUE",function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'},TypeError);mf("ERR_INVALID_ARG_TYPE",function(e,t,r){let n;if(typeof t==="string"&&con(t,"not ")){n="must not be";t=t.replace(/^not /,"")}else{n="must be"}let i;if(don(e," argument")){i=`The ${e} ${n} ${Hgt(t,"type")}`}else{const s=pon(e,".")?"property":"argument";i=`The "${e}" ${s} ${n} ${Hgt(t,"type")}`}i+=`. Received type ${typeof r}`;return i},TypeError);mf("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF");mf("ERR_METHOD_NOT_IMPLEMENTED",function(e){return"The "+e+" method is not implemented"});mf("ERR_STREAM_PREMATURE_CLOSE","Premature close");mf("ERR_STREAM_DESTROYED",function(e){return"Cannot call "+e+" after a stream was destroyed"});mf("ERR_MULTIPLE_CALLBACK","Callback called multiple times");mf("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable");mf("ERR_STREAM_WRITE_AFTER_END","write after end");mf("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError);mf("ERR_UNKNOWN_ENCODING",function(e){return"Unknown encoding: "+e},TypeError);mf("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event");zgt.exports.codes=Vgt});var R2e=y((iOs,Kgt)=>{"use strict";var fon=Xv().codes.ERR_INVALID_OPT_VALUE;function mon(e,t,r){return e.highWaterMark!=null?e.highWaterMark:t?e[r]:null}a(mon,"highWaterMarkFrom");function hon(e,t,r,n){var i=mon(t,n,r);if(i!=null){if(!(isFinite(i)&&Math.floor(i)===i)||i<0){var s=n?r:"highWaterMark";throw new fon(s,i)}return Math.floor(i)}return e.objectMode?16:16*1024}a(hon,"getHighWaterMark");Kgt.exports={getHighWaterMark:hon}});var Wgt=y((aOs,O2e)=>{if(typeof Object.create==="function"){O2e.exports=a(function e(t,r){if(r){t.super_=r;t.prototype=Object.create(r.prototype,{constructor:{value:t,enumerable:false,writable:true,configurable:true}})}},"inherits")}else{O2e.exports=a(function e(t,r){if(r){t.super_=r;var n=a(function(){},"TempCtor");n.prototype=r.prototype;t.prototype=new n;t.prototype.constructor=t}},"inherits")}});var Jv=y((uOs,N2e)=>{try{P2e=require("util");if(typeof P2e.inherits!=="function")throw"";N2e.exports=P2e.inherits}catch(e){N2e.exports=Wgt()}var P2e});var Xgt=y((lOs,Ygt)=>{Ygt.exports=require("util").deprecate});var D2e=y((cOs,r1t)=>{"use strict";r1t.exports=no;function Qgt(e){var t=this;this.next=null;this.entry=null;this.finish=function(){jon(t,e)}}a(Qgt,"CorkedRequest");var WR;no.WritableState=Y9;var gon={deprecate:Xgt()};var Zgt=C2e();var gW=require("buffer").Buffer;var yon=global.Uint8Array||function(){};function _on(e){return gW.from(e)}a(_on,"_uint8ArrayToBuffer");function von(e){return gW.isBuffer(e)||e instanceof yon}a(von,"_isUint8Array");var k2e=x2e();var Eon=R2e();var bon=Eon.getHighWaterMark;var Qv=Xv().codes;var Son=Qv.ERR_INVALID_ARG_TYPE;var Aon=Qv.ERR_METHOD_NOT_IMPLEMENTED;var Con=Qv.ERR_MULTIPLE_CALLBACK;var won=Qv.ERR_STREAM_CANNOT_PIPE;var Ton=Qv.ERR_STREAM_DESTROYED;var xon=Qv.ERR_STREAM_NULL_VALUES;var Ron=Qv.ERR_STREAM_WRITE_AFTER_END;var Oon=Qv.ERR_UNKNOWN_ENCODING;var YR=k2e.errorOrDestroy;Jv()(no,Zgt);function Pon(){}a(Pon,"nop");function Y9(e,t,r){WR=WR||bA();e=e||{};if(typeof r!=="boolean")r=t instanceof WR;this.objectMode=!!e.objectMode;if(r)this.objectMode=this.objectMode||!!e.writableObjectMode;this.highWaterMark=bon(this,e,"writableHighWaterMark",r);this.finalCalled=false;this.needDrain=false;this.ending=false;this.ended=false;this.finished=false;this.destroyed=false;var n=e.decodeStrings===false;this.decodeStrings=!n;this.defaultEncoding=e.defaultEncoding||"utf8";this.length=0;this.writing=false;this.corked=0;this.sync=true;this.bufferProcessing=false;this.onwrite=function(i){Bon(t,i)};this.writecb=null;this.writelen=0;this.bufferedRequest=null;this.lastBufferedRequest=null;this.pendingcb=0;this.prefinished=false;this.errorEmitted=false;this.emitClose=e.emitClose!==false;this.autoDestroy=!!e.autoDestroy;this.bufferedRequestCount=0;this.corkedRequestsFree=new Qgt(this)}a(Y9,"WritableState");Y9.prototype.getBuffer=a(function e(){var t=this.bufferedRequest;var r=[];while(t){r.push(t);t=t.next}return r},"getBuffer");(function(){try{Object.defineProperty(Y9.prototype,"buffer",{get:gon.deprecate(a(function e(){return this.getBuffer()},"writableStateBufferGetter"),"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}})();var hW;if(typeof Symbol==="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]==="function"){hW=Function.prototype[Symbol.hasInstance];Object.defineProperty(no,Symbol.hasInstance,{value:a(function e(t){if(hW.call(this,t))return true;if(this!==no)return false;return t&&t._writableState instanceof Y9},"value")})}else{hW=a(function e(t){return t instanceof this},"realHasInstance")}function no(e){WR=WR||bA();var t=this instanceof WR;if(!t&&!hW.call(no,this))return new no(e);this._writableState=new Y9(e,this,t);this.writable=true;if(e){if(typeof e.write==="function")this._write=e.write;if(typeof e.writev==="function")this._writev=e.writev;if(typeof e.destroy==="function")this._destroy=e.destroy;if(typeof e.final==="function")this._final=e.final}Zgt.call(this)}a(no,"Writable");no.prototype.pipe=function(){YR(this,new won)};function Non(e,t){var r=new Ron;YR(e,r);process.nextTick(t,r)}a(Non,"writeAfterEnd");function Ion(e,t,r,n){var i;if(r===null){i=new xon}else if(typeof r!=="string"&&!t.objectMode){i=new Son("chunk",["string","Buffer"],r)}if(i){YR(e,i);process.nextTick(n,i);return false}return true}a(Ion,"validChunk");no.prototype.write=function(e,t,r){var n=this._writableState;var i=false;var s=!n.objectMode&&von(e);if(s&&!gW.isBuffer(e)){e=_on(e)}if(typeof t==="function"){r=t;t=null}if(s)t="buffer";else if(!t)t=n.defaultEncoding;if(typeof r!=="function")r=Pon;if(n.ending)Non(this,r);else if(s||Ion(this,n,e,r)){n.pendingcb++;i=Don(this,n,s,e,t,r)}return i};no.prototype.cork=function(){this._writableState.corked++};no.prototype.uncork=function(){var e=this._writableState;if(e.corked){e.corked--;if(!e.writing&&!e.corked&&!e.bufferProcessing&&e.bufferedRequest)e1t(this,e)}};no.prototype.setDefaultEncoding=a(function e(t){if(typeof t==="string")t=t.toLowerCase();if(!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new Oon(t);this._writableState.defaultEncoding=t;return this},"setDefaultEncoding");Object.defineProperty(no.prototype,"writableBuffer",{enumerable:false,get:a(function e(){return this._writableState&&this._writableState.getBuffer()},"get")});function kon(e,t,r){if(!e.objectMode&&e.decodeStrings!==false&&typeof t==="string"){t=gW.from(t,r)}return t}a(kon,"decodeChunk");Object.defineProperty(no.prototype,"writableHighWaterMark",{enumerable:false,get:a(function e(){return this._writableState.highWaterMark},"get")});function Don(e,t,r,n,i,s){if(!r){var o=kon(t,n,i);if(n!==o){r=true;i="buffer";n=o}}var u=t.objectMode?1:n.length;t.length+=u;var l=t.length<t.highWaterMark;if(!l)t.needDrain=true;if(t.writing||t.corked){var c=t.lastBufferedRequest;t.lastBufferedRequest={chunk:n,encoding:i,isBuf:r,callback:s,next:null};if(c){c.next=t.lastBufferedRequest}else{t.bufferedRequest=t.lastBufferedRequest}t.bufferedRequestCount+=1}else{I2e(e,t,false,u,n,i,s)}return l}a(Don,"writeOrBuffer");function I2e(e,t,r,n,i,s,o){t.writelen=n;t.writecb=o;t.writing=true;t.sync=true;if(t.destroyed)t.onwrite(new Ton("write"));else if(r)e._writev(i,t.onwrite);else e._write(i,s,t.onwrite);t.sync=false}a(I2e,"doWrite");function Lon(e,t,r,n,i){--t.pendingcb;if(r){process.nextTick(i,n);process.nextTick(W9,e,t);e._writableState.errorEmitted=true;YR(e,n)}else{i(n);e._writableState.errorEmitted=true;YR(e,n);W9(e,t)}}a(Lon,"onwriteError");function Fon(e){e.writing=false;e.writecb=null;e.length-=e.writelen;e.writelen=0}a(Fon,"onwriteStateUpdate");function Bon(e,t){var r=e._writableState;var n=r.sync;var i=r.writecb;if(typeof i!=="function")throw new Con;Fon(r);if(t)Lon(e,r,n,t,i);else{var s=t1t(r)||e.destroyed;if(!s&&!r.corked&&!r.bufferProcessing&&r.bufferedRequest){e1t(e,r)}if(n){process.nextTick(Jgt,e,r,s,i)}else{Jgt(e,r,s,i)}}}a(Bon,"onwrite");function Jgt(e,t,r,n){if(!r)Mon(e,t);t.pendingcb--;n();W9(e,t)}a(Jgt,"afterWrite");function Mon(e,t){if(t.length===0&&t.needDrain){t.needDrain=false;e.emit("drain")}}a(Mon,"onwriteDrain");function e1t(e,t){t.bufferProcessing=true;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount;var i=new Array(n);var s=t.corkedRequestsFree;s.entry=r;var o=0;var u=true;while(r){i[o]=r;if(!r.isBuf)u=false;r=r.next;o+=1}i.allBuffers=u;I2e(e,t,true,t.length,i,"",s.finish);t.pendingcb++;t.lastBufferedRequest=null;if(s.next){t.corkedRequestsFree=s.next;s.next=null}else{t.corkedRequestsFree=new Qgt(t)}t.bufferedRequestCount=0}else{while(r){var l=r.chunk;var c=r.encoding;var d=r.callback;var p=t.objectMode?1:l.length;I2e(e,t,false,p,l,c,d);r=r.next;t.bufferedRequestCount--;if(t.writing){break}}if(r===null)t.lastBufferedRequest=null}t.bufferedRequest=r;t.bufferProcessing=false}a(e1t,"clearBuffer");no.prototype._write=function(e,t,r){r(new Aon("_write()"))};no.prototype._writev=null;no.prototype.end=function(e,t,r){var n=this._writableState;if(typeof e==="function"){r=e;e=null;t=null}else if(typeof t==="function"){r=t;t=null}if(e!==null&&e!==void 0)this.write(e,t);if(n.corked){n.corked=1;this.uncork()}if(!n.ending)$on(this,n,r);return this};Object.defineProperty(no.prototype,"writableLength",{enumerable:false,get:a(function e(){return this._writableState.length},"get")});function t1t(e){return e.ending&&e.length===0&&e.bufferedRequest===null&&!e.finished&&!e.writing}a(t1t,"needFinish");function qon(e,t){e._final(function(r){t.pendingcb--;if(r){YR(e,r)}t.prefinished=true;e.emit("prefinish");W9(e,t)})}a(qon,"callFinal");function Uon(e,t){if(!t.prefinished&&!t.finalCalled){if(typeof e._final==="function"&&!t.destroyed){t.pendingcb++;t.finalCalled=true;process.nextTick(qon,e,t)}else{t.prefinished=true;e.emit("prefinish")}}}a(Uon,"prefinish");function W9(e,t){var r=t1t(t);if(r){Uon(e,t);if(t.pendingcb===0){t.finished=true;e.emit("finish");if(t.autoDestroy){var n=e._readableState;if(!n||n.autoDestroy&&n.endEmitted){e.destroy()}}}}return r}a(W9,"finishMaybe");function $on(e,t,r){t.ending=true;W9(e,t);if(r){if(t.finished)process.nextTick(r);else e.once("finish",r)}t.ended=true;e.writable=false}a($on,"endWritable");function jon(e,t,r){var n=e.entry;e.entry=null;while(n){var i=n.callback;t.pendingcb--;i(r);n=n.next}t.corkedRequestsFree.next=e}a(jon,"onCorkedFinish");Object.defineProperty(no.prototype,"destroyed",{enumerable:false,get:a(function e(){if(this._writableState===void 0){return false}return this._writableState.destroyed},"get"),set:a(function e(t){if(!this._writableState){return}this._writableState.destroyed=t},"set")});no.prototype.destroy=k2e.destroy;no.prototype._undestroy=k2e.undestroy;no.prototype._destroy=function(e,t){t(e)}});var bA=y((pOs,i1t)=>{"use strict";var Gon=Object.keys||function(e){var t=[];for(var r in e){t.push(r)}return t};i1t.exports=N0;var n1t=B2e();var F2e=D2e();Jv()(N0,n1t);{L2e=Gon(F2e.prototype);for(yW=0;yW<L2e.length;yW++){_W=L2e[yW];if(!N0.prototype[_W])N0.prototype[_W]=F2e.prototype[_W]}}var L2e;var _W;var yW;function N0(e){if(!(this instanceof N0))return new N0(e);n1t.call(this,e);F2e.call(this,e);this.allowHalfOpen=true;if(e){if(e.readable===false)this.readable=false;if(e.writable===false)this.writable=false;if(e.allowHalfOpen===false){this.allowHalfOpen=false;this.once("end",Hon)}}}a(N0,"Duplex");Object.defineProperty(N0.prototype,"writableHighWaterMark",{enumerable:false,get:a(function e(){return this._writableState.highWaterMark},"get")});Object.defineProperty(N0.prototype,"writableBuffer",{enumerable:false,get:a(function e(){return this._writableState&&this._writableState.getBuffer()},"get")});Object.defineProperty(N0.prototype,"writableLength",{enumerable:false,get:a(function e(){return this._writableState.length},"get")});function Hon(){if(this._writableState.ended)return;process.nextTick(Von,this)}a(Hon,"onend");function Von(e){e.end()}a(Von,"onEndNT");Object.defineProperty(N0.prototype,"destroyed",{enumerable:false,get:a(function e(){if(this._readableState===void 0||this._writableState===void 0){return false}return this._readableState.destroyed&&this._writableState.destroyed},"get"),set:a(function e(t){if(this._readableState===void 0||this._writableState===void 0){return}this._readableState.destroyed=t;this._writableState.destroyed=t},"set")})});var o1t=y((M2e,a1t)=>{var vW=require("buffer");var ay=vW.Buffer;function s1t(e,t){for(var r in e){t[r]=e[r]}}a(s1t,"copyProps");if(ay.from&&ay.alloc&&ay.allocUnsafe&&ay.allocUnsafeSlow){a1t.exports=vW}else{s1t(vW,M2e);M2e.Buffer=XR}function XR(e,t,r){return ay(e,t,r)}a(XR,"SafeBuffer");s1t(ay,XR);XR.from=function(e,t,r){if(typeof e==="number"){throw new TypeError("Argument must not be a number")}return ay(e,t,r)};XR.alloc=function(e,t,r){if(typeof e!=="number"){throw new TypeError("Argument must be a number")}var n=ay(e);if(t!==void 0){if(typeof r==="string"){n.fill(t,r)}else{n.fill(t)}}else{n.fill(0)}return n};XR.allocUnsafe=function(e){if(typeof e!=="number"){throw new TypeError("Argument must be a number")}return ay(e)};XR.allocUnsafeSlow=function(e){if(typeof e!=="number"){throw new TypeError("Argument must be a number")}return vW.SlowBuffer(e)}});var $2e=y(l1t=>{"use strict";var U2e=o1t().Buffer;var u1t=U2e.isEncoding||function(e){e=""+e;switch(e&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return true;default:return false}};function zon(e){if(!e)return"utf8";var t;while(true){switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase();t=true}}}a(zon,"_normalizeEncoding");function Kon(e){var t=zon(e);if(typeof t!=="string"&&(U2e.isEncoding===u1t||!u1t(e)))throw new Error("Unknown encoding: "+e);return t||e}a(Kon,"normalizeEncoding");l1t.StringDecoder=X9;function X9(e){this.encoding=Kon(e);var t;switch(this.encoding){case"utf16le":this.text=Zon;this.end=eun;t=4;break;case"utf8":this.fillLast=Xon;t=4;break;case"base64":this.text=tun;this.end=run;t=3;break;default:this.write=nun;this.end=iun;return}this.lastNeed=0;this.lastTotal=0;this.lastChar=U2e.allocUnsafe(t)}a(X9,"StringDecoder");X9.prototype.write=function(e){if(e.length===0)return"";var t;var r;if(this.lastNeed){t=this.fillLast(e);if(t===void 0)return"";r=this.lastNeed;this.lastNeed=0}else{r=0}if(r<e.length)return t?t+this.text(e,r):this.text(e,r);return t||""};X9.prototype.end=Qon;X9.prototype.text=Jon;X9.prototype.fillLast=function(e){if(this.lastNeed<=e.length){e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed);return this.lastChar.toString(this.encoding,0,this.lastTotal)}e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length);this.lastNeed-=e.length};function q2e(e){if(e<=127)return 0;else if(e>>5===6)return 2;else if(e>>4===14)return 3;else if(e>>3===30)return 4;return e>>6===2?-1:-2}a(q2e,"utf8CheckByte");function Won(e,t,r){var n=t.length-1;if(n<r)return 0;var i=q2e(t[n]);if(i>=0){if(i>0)e.lastNeed=i-1;return i}if(--n<r||i===-2)return 0;i=q2e(t[n]);if(i>=0){if(i>0)e.lastNeed=i-2;return i}if(--n<r||i===-2)return 0;i=q2e(t[n]);if(i>=0){if(i>0){if(i===2)i=0;else e.lastNeed=i-3}return i}return 0}a(Won,"utf8CheckIncomplete");function Yon(e,t,r){if((t[0]&192)!==128){e.lastNeed=0;return"\uFFFD"}if(e.lastNeed>1&&t.length>1){if((t[1]&192)!==128){e.lastNeed=1;return"\uFFFD"}if(e.lastNeed>2&&t.length>2){if((t[2]&192)!==128){e.lastNeed=2;return"\uFFFD"}}}}a(Yon,"utf8CheckExtraBytes");function Xon(e){var t=this.lastTotal-this.lastNeed;var r=Yon(this,e,t);if(r!==void 0)return r;if(this.lastNeed<=e.length){e.copy(this.lastChar,t,0,this.lastNeed);return this.lastChar.toString(this.encoding,0,this.lastTotal)}e.copy(this.lastChar,t,0,e.length);this.lastNeed-=e.length}a(Xon,"utf8FillLast");function Jon(e,t){var r=Won(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var n=e.length-(r-this.lastNeed);e.copy(this.lastChar,0,n);return e.toString("utf8",t,n)}a(Jon,"utf8Text");function Qon(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed)return t+"\uFFFD";return t}a(Qon,"utf8End");function Zon(e,t){if((e.length-t)%2===0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319){this.lastNeed=2;this.lastTotal=4;this.lastChar[0]=e[e.length-2];this.lastChar[1]=e[e.length-1];return r.slice(0,-1)}}return r}this.lastNeed=1;this.lastTotal=2;this.lastChar[0]=e[e.length-1];return e.toString("utf16le",t,e.length-1)}a(Zon,"utf16Text");function eun(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}a(eun,"utf16End");function tun(e,t){var r=(e.length-t)%3;if(r===0)return e.toString("base64",t);this.lastNeed=3-r;this.lastTotal=3;if(r===1){this.lastChar[0]=e[e.length-1]}else{this.lastChar[0]=e[e.length-2];this.lastChar[1]=e[e.length-1]}return e.toString("base64",t,e.length-r)}a(tun,"base64Text");function run(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed)return t+this.lastChar.toString("base64",0,3-this.lastNeed);return t}a(run,"base64End");function nun(e){return e.toString(this.encoding)}a(nun,"simpleWrite");function iun(e){return e&&e.length?this.write(e):""}a(iun,"simpleEnd")});var EW=y((yOs,p1t)=>{"use strict";var c1t=Xv().codes.ERR_STREAM_PREMATURE_CLOSE;function sun(e){var t=false;return function(){if(t)return;t=true;for(var r=arguments.length,n=new Array(r),i=0;i<r;i++){n[i]=arguments[i]}e.apply(this,n)}}a(sun,"once");function aun(){}a(aun,"noop");function oun(e){return e.setHeader&&typeof e.abort==="function"}a(oun,"isRequest");function d1t(e,t,r){if(typeof t==="function")return d1t(e,null,t);if(!t)t={};r=sun(r||aun);var n=t.readable||t.readable!==false&&e.readable;var i=t.writable||t.writable!==false&&e.writable;var s=a(function m(){if(!e.writable)u()},"onlegacyfinish");var o=e._writableState&&e._writableState.finished;var u=a(function m(){i=false;o=true;if(!n)r.call(e)},"onfinish");var l=e._readableState&&e._readableState.endEmitted;var c=a(function m(){n=false;l=true;if(!i)r.call(e)},"onend");var d=a(function m(h){r.call(e,h)},"onerror");var p=a(function m(){var h;if(n&&!l){if(!e._readableState||!e._readableState.ended)h=new c1t;return r.call(e,h)}if(i&&!o){if(!e._writableState||!e._writableState.ended)h=new c1t;return r.call(e,h)}},"onclose");var f=a(function m(){e.req.on("finish",u)},"onrequest");if(oun(e)){e.on("complete",u);e.on("abort",p);if(e.req)f();else e.on("request",f)}else if(i&&!e._writableState){e.on("end",s);e.on("close",s)}e.on("end",c);e.on("finish",u);if(t.error!==false)e.on("error",d);e.on("close",p);return function(){e.removeListener("complete",u);e.removeListener("abort",p);e.removeListener("request",f);if(e.req)e.req.removeListener("finish",u);e.removeListener("end",s);e.removeListener("close",s);e.removeListener("finish",u);e.removeListener("end",c);e.removeListener("error",d);e.removeListener("close",p)}}a(d1t,"eos");p1t.exports=d1t});var m1t=y((vOs,f1t)=>{"use strict";var bW;function Zv(e,t,r){if(t in e){Object.defineProperty(e,t,{value:r,enumerable:true,configurable:true,writable:true})}else{e[t]=r}return e}a(Zv,"_defineProperty");var uun=EW();var eE=Symbol("lastResolve");var SA=Symbol("lastReject");var J9=Symbol("error");var SW=Symbol("ended");var AA=Symbol("lastPromise");var j2e=Symbol("handlePromise");var CA=Symbol("stream");function tE(e,t){return{value:e,done:t}}a(tE,"createIterResult");function lun(e){var t=e[eE];if(t!==null){var r=e[CA].read();if(r!==null){e[AA]=null;e[eE]=null;e[SA]=null;t(tE(r,false))}}}a(lun,"readAndResolve");function cun(e){process.nextTick(lun,e)}a(cun,"onReadable");function dun(e,t){return function(r,n){e.then(function(){if(t[SW]){r(tE(void 0,true));return}t[j2e](r,n)},n)}}a(dun,"wrapForNext");var pun=Object.getPrototypeOf(function(){});var fun=Object.setPrototypeOf((bW={get stream(){return this[CA]},next:a(function e(){var t=this;var r=this[J9];if(r!==null){return Promise.reject(r)}if(this[SW]){return Promise.resolve(tE(void 0,true))}if(this[CA].destroyed){return new Promise(function(o,u){process.nextTick(function(){if(t[J9]){u(t[J9])}else{o(tE(void 0,true))}})})}var n=this[AA];var i;if(n){i=new Promise(dun(n,this))}else{var s=this[CA].read();if(s!==null){return Promise.resolve(tE(s,false))}i=new Promise(this[j2e])}this[AA]=i;return i},"next")},Zv(bW,Symbol.asyncIterator,function(){return this}),Zv(bW,"return",a(function e(){var t=this;return new Promise(function(r,n){t[CA].destroy(null,function(i){if(i){n(i);return}r(tE(void 0,true))})})},"_return")),bW),pun);var mun=a(function e(t){var r;var n=Object.create(fun,(r={},Zv(r,CA,{value:t,writable:true}),Zv(r,eE,{value:null,writable:true}),Zv(r,SA,{value:null,writable:true}),Zv(r,J9,{value:null,writable:true}),Zv(r,SW,{value:t._readableState.endEmitted,writable:true}),Zv(r,j2e,{value:a(function i(s,o){var u=n[CA].read();if(u){n[AA]=null;n[eE]=null;n[SA]=null;s(tE(u,false))}else{n[eE]=s;n[SA]=o}},"value"),writable:true}),r));n[AA]=null;uun(t,function(i){if(i&&i.code!=="ERR_STREAM_PREMATURE_CLOSE"){var s=n[SA];if(s!==null){n[AA]=null;n[eE]=null;n[SA]=null;s(i)}n[J9]=i;return}var o=n[eE];if(o!==null){n[AA]=null;n[eE]=null;n[SA]=null;o(tE(void 0,true))}n[SW]=true});t.on("readable",cun.bind(null,n));return n},"createReadableStreamAsyncIterator");f1t.exports=mun});var _1t=y((bOs,y1t)=>{"use strict";function h1t(e,t,r,n,i,s,o){try{var u=e[s](o);var l=u.value}catch(c){r(c);return}if(u.done){t(l)}else{Promise.resolve(l).then(n,i)}}a(h1t,"asyncGeneratorStep");function hun(e){return function(){var t=this,r=arguments;return new Promise(function(n,i){var s=e.apply(t,r);function o(l){h1t(s,n,i,o,u,"next",l)}a(o,"_next");function u(l){h1t(s,n,i,o,u,"throw",l)}a(u,"_throw");o(void 0)})}}a(hun,"_asyncToGenerator");function g1t(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);if(t)n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable});r.push.apply(r,n)}return r}a(g1t,"ownKeys");function gun(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};if(t%2){g1t(Object(r),true).forEach(function(n){yun(e,n,r[n])})}else if(Object.getOwnPropertyDescriptors){Object.defineProperties(e,Object.getOwnPropertyDescriptors(r))}else{g1t(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}}return e}a(gun,"_objectSpread");function yun(e,t,r){if(t in e){Object.defineProperty(e,t,{value:r,enumerable:true,configurable:true,writable:true})}else{e[t]=r}return e}a(yun,"_defineProperty");var _un=Xv().codes.ERR_INVALID_ARG_TYPE;function vun(e,t,r){var n;if(t&&typeof t.next==="function"){n=t}else if(t&&t[Symbol.asyncIterator])n=t[Symbol.asyncIterator]();else if(t&&t[Symbol.iterator])n=t[Symbol.iterator]();else throw new _un("iterable",["Iterable"],t);var i=new e(gun({objectMode:true},r));var s=false;i._read=function(){if(!s){s=true;o()}};function o(){return u.apply(this,arguments)}a(o,"next");function u(){u=hun(function*(){try{var l=yield n.next(),c=l.value,d=l.done;if(d){i.push(null)}else if(i.push(yield c)){o()}else{s=false}}catch(p){i.destroy(p)}});return u.apply(this,arguments)}a(u,"_next2");return i}a(vun,"from");y1t.exports=vun});var B2e=y((COs,R1t)=>{"use strict";R1t.exports=Xi;var JR;Xi.ReadableState=S1t;var AOs=require("events").EventEmitter;var b1t=a(function e(t,r){return t.listeners(r).length},"EElistenerCount");var Z9=C2e();var AW=require("buffer").Buffer;var Eun=global.Uint8Array||function(){};function bun(e){return AW.from(e)}a(bun,"_uint8ArrayToBuffer");function Sun(e){return AW.isBuffer(e)||e instanceof Eun}a(Sun,"_isUint8Array");var G2e=require("util");var ei;if(G2e&&G2e.debuglog){ei=G2e.debuglog("stream")}else{ei=a(function e(){},"debug")}var Aun=$gt();var X2e=x2e();var Cun=R2e();var wun=Cun.getHighWaterMark;var CW=Xv().codes;var Tun=CW.ERR_INVALID_ARG_TYPE;var xun=CW.ERR_STREAM_PUSH_AFTER_EOF;var Run=CW.ERR_METHOD_NOT_IMPLEMENTED;var Oun=CW.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;var QR;var H2e;var V2e;Jv()(Xi,Z9);var Q9=X2e.errorOrDestroy;var z2e=["error","close","destroy","pause","resume"];function Pun(e,t,r){if(typeof e.prependListener==="function")return e.prependListener(t,r);if(!e._events||!e._events[t])e.on(t,r);else if(Array.isArray(e._events[t]))e._events[t].unshift(r);else e._events[t]=[r,e._events[t]]}a(Pun,"prependListener");function S1t(e,t,r){JR=JR||bA();e=e||{};if(typeof r!=="boolean")r=t instanceof JR;this.objectMode=!!e.objectMode;if(r)this.objectMode=this.objectMode||!!e.readableObjectMode;this.highWaterMark=wun(this,e,"readableHighWaterMark",r);this.buffer=new Aun;this.length=0;this.pipes=null;this.pipesCount=0;this.flowing=null;this.ended=false;this.endEmitted=false;this.reading=false;this.sync=true;this.needReadable=false;this.emittedReadable=false;this.readableListening=false;this.resumeScheduled=false;this.paused=true;this.emitClose=e.emitClose!==false;this.autoDestroy=!!e.autoDestroy;this.destroyed=false;this.defaultEncoding=e.defaultEncoding||"utf8";this.awaitDrain=0;this.readingMore=false;this.decoder=null;this.encoding=null;if(e.encoding){if(!QR)QR=$2e().StringDecoder;this.decoder=new QR(e.encoding);this.encoding=e.encoding}}a(S1t,"ReadableState");function Xi(e){JR=JR||bA();if(!(this instanceof Xi))return new Xi(e);var t=this instanceof JR;this._readableState=new S1t(e,this,t);this.readable=true;if(e){if(typeof e.read==="function")this._read=e.read;if(typeof e.destroy==="function")this._destroy=e.destroy}Z9.call(this)}a(Xi,"Readable");Object.defineProperty(Xi.prototype,"destroyed",{enumerable:false,get:a(function e(){if(this._readableState===void 0){return false}return this._readableState.destroyed},"get"),set:a(function e(t){if(!this._readableState){return}this._readableState.destroyed=t},"set")});Xi.prototype.destroy=X2e.destroy;Xi.prototype._undestroy=X2e.undestroy;Xi.prototype._destroy=function(e,t){t(e)};Xi.prototype.push=function(e,t){var r=this._readableState;var n;if(!r.objectMode){if(typeof e==="string"){t=t||r.defaultEncoding;if(t!==r.encoding){e=AW.from(e,t);t=""}n=true}}else{n=true}return A1t(this,e,t,false,n)};Xi.prototype.unshift=function(e){return A1t(this,e,null,true,false)};function A1t(e,t,r,n,i){ei("readableAddChunk",t);var s=e._readableState;if(t===null){s.reading=false;kun(e,s)}else{var o;if(!i)o=Nun(s,t);if(o){Q9(e,o)}else if(s.objectMode||t&&t.length>0){if(typeof t!=="string"&&!s.objectMode&&Object.getPrototypeOf(t)!==AW.prototype){t=bun(t)}if(n){if(s.endEmitted)Q9(e,new Oun);else K2e(e,s,t,true)}else if(s.ended){Q9(e,new xun)}else if(s.destroyed){return false}else{s.reading=false;if(s.decoder&&!r){t=s.decoder.write(t);if(s.objectMode||t.length!==0)K2e(e,s,t,false);else Y2e(e,s)}else{K2e(e,s,t,false)}}}else if(!n){s.reading=false;Y2e(e,s)}}return!s.ended&&(s.length<s.highWaterMark||s.length===0)}a(A1t,"readableAddChunk");function K2e(e,t,r,n){if(t.flowing&&t.length===0&&!t.sync){t.awaitDrain=0;e.emit("data",r)}else{t.length+=t.objectMode?1:r.length;if(n)t.buffer.unshift(r);else t.buffer.push(r);if(t.needReadable)wW(e)}Y2e(e,t)}a(K2e,"addChunk");function Nun(e,t){var r;if(!Sun(t)&&typeof t!=="string"&&t!==void 0&&!e.objectMode){r=new Tun("chunk",["string","Buffer","Uint8Array"],t)}return r}a(Nun,"chunkInvalid");Xi.prototype.isPaused=function(){return this._readableState.flowing===false};Xi.prototype.setEncoding=function(e){if(!QR)QR=$2e().StringDecoder;var t=new QR(e);this._readableState.decoder=t;this._readableState.encoding=this._readableState.decoder.encoding;var r=this._readableState.buffer.head;var n="";while(r!==null){n+=t.write(r.data);r=r.next}this._readableState.buffer.clear();if(n!=="")this._readableState.buffer.push(n);this._readableState.length=n.length;return this};var v1t=1073741824;function Iun(e){if(e>=v1t){e=v1t}else{e--;e|=e>>>1;e|=e>>>2;e|=e>>>4;e|=e>>>8;e|=e>>>16;e++}return e}a(Iun,"computeNewHighWaterMark");function E1t(e,t){if(e<=0||t.length===0&&t.ended)return 0;if(t.objectMode)return 1;if(e!==e){if(t.flowing&&t.length)return t.buffer.head.data.length;else return t.length}if(e>t.highWaterMark)t.highWaterMark=Iun(e);if(e<=t.length)return e;if(!t.ended){t.needReadable=true;return 0}return t.length}a(E1t,"howMuchToRead");Xi.prototype.read=function(e){ei("read",e);e=parseInt(e,10);var t=this._readableState;var r=e;if(e!==0)t.emittedReadable=false;if(e===0&&t.needReadable&&((t.highWaterMark!==0?t.length>=t.highWaterMark:t.length>0)||t.ended)){ei("read: emitReadable",t.length,t.ended);if(t.length===0&&t.ended)W2e(this);else wW(this);return null}e=E1t(e,t);if(e===0&&t.ended){if(t.length===0)W2e(this);return null}var n=t.needReadable;ei("need readable",n);if(t.length===0||t.length-e<t.highWaterMark){n=true;ei("length less than watermark",n)}if(t.ended||t.reading){n=false;ei("reading or ended",n)}else if(n){ei("do read");t.reading=true;t.sync=true;if(t.length===0)t.needReadable=true;this._read(t.highWaterMark);t.sync=false;if(!t.reading)e=E1t(r,t)}var i;if(e>0)i=T1t(e,t);else i=null;if(i===null){t.needReadable=t.length<=t.highWaterMark;e=0}else{t.length-=e;t.awaitDrain=0}if(t.length===0){if(!t.ended)t.needReadable=true;if(r!==e&&t.ended)W2e(this)}if(i!==null)this.emit("data",i);return i};function kun(e,t){ei("onEofChunk");if(t.ended)return;if(t.decoder){var r=t.decoder.end();if(r&&r.length){t.buffer.push(r);t.length+=t.objectMode?1:r.length}}t.ended=true;if(t.sync){wW(e)}else{t.needReadable=false;if(!t.emittedReadable){t.emittedReadable=true;C1t(e)}}}a(kun,"onEofChunk");function wW(e){var t=e._readableState;ei("emitReadable",t.needReadable,t.emittedReadable);t.needReadable=false;if(!t.emittedReadable){ei("emitReadable",t.flowing);t.emittedReadable=true;process.nextTick(C1t,e)}}a(wW,"emitReadable");function C1t(e){var t=e._readableState;ei("emitReadable_",t.destroyed,t.length,t.ended);if(!t.destroyed&&(t.length||t.ended)){e.emit("readable");t.emittedReadable=false}t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark;J2e(e)}a(C1t,"emitReadable_");function Y2e(e,t){if(!t.readingMore){t.readingMore=true;process.nextTick(Dun,e,t)}}a(Y2e,"maybeReadMore");function Dun(e,t){while(!t.reading&&!t.ended&&(t.length<t.highWaterMark||t.flowing&&t.length===0)){var r=t.length;ei("maybeReadMore read 0");e.read(0);if(r===t.length)break}t.readingMore=false}a(Dun,"maybeReadMore_");Xi.prototype._read=function(e){Q9(this,new Run("_read()"))};Xi.prototype.pipe=function(e,t){var r=this;var n=this._readableState;switch(n.pipesCount){case 0:n.pipes=e;break;case 1:n.pipes=[n.pipes,e];break;default:n.pipes.push(e);break}n.pipesCount+=1;ei("pipe count=%d opts=%j",n.pipesCount,t);var i=(!t||t.end!==false)&&e!==process.stdout&&e!==process.stderr;var s=i?u:g;if(n.endEmitted)process.nextTick(s);else r.once("end",s);e.on("unpipe",o);function o(_,v){ei("onunpipe");if(_===r){if(v&&v.hasUnpiped===false){v.hasUnpiped=true;d()}}}a(o,"onunpipe");function u(){ei("onend");e.end()}a(u,"onend");var l=Lun(r);e.on("drain",l);var c=false;function d(){ei("cleanup");e.removeListener("close",m);e.removeListener("finish",h);e.removeListener("drain",l);e.removeListener("error",f);e.removeListener("unpipe",o);r.removeListener("end",u);r.removeListener("end",g);r.removeListener("data",p);c=true;if(n.awaitDrain&&(!e._writableState||e._writableState.needDrain))l()}a(d,"cleanup");r.on("data",p);function p(_){ei("ondata");var v=e.write(_);ei("dest.write",v);if(v===false){if((n.pipesCount===1&&n.pipes===e||n.pipesCount>1&&x1t(n.pipes,e)!==-1)&&!c){ei("false write response, pause",n.awaitDrain);n.awaitDrain++}r.pause()}}a(p,"ondata");function f(_){ei("onerror",_);g();e.removeListener("error",f);if(b1t(e,"error")===0)Q9(e,_)}a(f,"onerror");Pun(e,"error",f);function m(){e.removeListener("finish",h);g()}a(m,"onclose");e.once("close",m);function h(){ei("onfinish");e.removeListener("close",m);g()}a(h,"onfinish");e.once("finish",h);function g(){ei("unpipe");r.unpipe(e)}a(g,"unpipe");e.emit("pipe",r);if(!n.flowing){ei("pipe resume");r.resume()}return e};function Lun(e){return a(function t(){var r=e._readableState;ei("pipeOnDrain",r.awaitDrain);if(r.awaitDrain)r.awaitDrain--;if(r.awaitDrain===0&&b1t(e,"data")){r.flowing=true;J2e(e)}},"pipeOnDrainFunctionResult")}a(Lun,"pipeOnDrain");Xi.prototype.unpipe=function(e){var t=this._readableState;var r={hasUnpiped:false};if(t.pipesCount===0)return this;if(t.pipesCount===1){if(e&&e!==t.pipes)return this;if(!e)e=t.pipes;t.pipes=null;t.pipesCount=0;t.flowing=false;if(e)e.emit("unpipe",this,r);return this}if(!e){var n=t.pipes;var i=t.pipesCount;t.pipes=null;t.pipesCount=0;t.flowing=false;for(var s=0;s<i;s++){n[s].emit("unpipe",this,{hasUnpiped:false})}return this}var o=x1t(t.pipes,e);if(o===-1)return this;t.pipes.splice(o,1);t.pipesCount-=1;if(t.pipesCount===1)t.pipes=t.pipes[0];e.emit("unpipe",this,r);return this};Xi.prototype.on=function(e,t){var r=Z9.prototype.on.call(this,e,t);var n=this._readableState;if(e==="data"){n.readableListening=this.listenerCount("readable")>0;if(n.flowing!==false)this.resume()}else if(e==="readable"){if(!n.endEmitted&&!n.readableListening){n.readableListening=n.needReadable=true;n.flowing=false;n.emittedReadable=false;ei("on readable",n.length,n.reading);if(n.length){wW(this)}else if(!n.reading){process.nextTick(Fun,this)}}}return r};Xi.prototype.addListener=Xi.prototype.on;Xi.prototype.removeListener=function(e,t){var r=Z9.prototype.removeListener.call(this,e,t);if(e==="readable"){process.nextTick(w1t,this)}return r};Xi.prototype.removeAllListeners=function(e){var t=Z9.prototype.removeAllListeners.apply(this,arguments);if(e==="readable"||e===void 0){process.nextTick(w1t,this)}return t};function w1t(e){var t=e._readableState;t.readableListening=e.listenerCount("readable")>0;if(t.resumeScheduled&&!t.paused){t.flowing=true}else if(e.listenerCount("data")>0){e.resume()}}a(w1t,"updateReadableListening");function Fun(e){ei("readable nexttick read 0");e.read(0)}a(Fun,"nReadingNextTick");Xi.prototype.resume=function(){var e=this._readableState;if(!e.flowing){ei("resume");e.flowing=!e.readableListening;Bun(this,e)}e.paused=false;return this};function Bun(e,t){if(!t.resumeScheduled){t.resumeScheduled=true;process.nextTick(Mun,e,t)}}a(Bun,"resume");function Mun(e,t){ei("resume",t.reading);if(!t.reading){e.read(0)}t.resumeScheduled=false;e.emit("resume");J2e(e);if(t.flowing&&!t.reading)e.read(0)}a(Mun,"resume_");Xi.prototype.pause=function(){ei("call pause flowing=%j",this._readableState.flowing);if(this._readableState.flowing!==false){ei("pause");this._readableState.flowing=false;this.emit("pause")}this._readableState.paused=true;return this};function J2e(e){var t=e._readableState;ei("flow",t.flowing);while(t.flowing&&e.read()!==null){;}}a(J2e,"flow");Xi.prototype.wrap=function(e){var t=this;var r=this._readableState;var n=false;e.on("end",function(){ei("wrapped end");if(r.decoder&&!r.ended){var o=r.decoder.end();if(o&&o.length)t.push(o)}t.push(null)});e.on("data",function(o){ei("wrapped data");if(r.decoder)o=r.decoder.write(o);if(r.objectMode&&(o===null||o===void 0))return;else if(!r.objectMode&&(!o||!o.length))return;var u=t.push(o);if(!u){n=true;e.pause()}});for(var i in e){if(this[i]===void 0&&typeof e[i]==="function"){this[i]=a(function o(u){return a(function l(){return e[u].apply(e,arguments)},"methodWrapReturnFunction")},"methodWrap")(i)}}for(var s=0;s<z2e.length;s++){e.on(z2e[s],this.emit.bind(this,z2e[s]))}this._read=function(o){ei("wrapped _read",o);if(n){n=false;e.resume()}};return this};if(typeof Symbol==="function"){Xi.prototype[Symbol.asyncIterator]=function(){if(H2e===void 0){H2e=m1t()}return H2e(this)}}Object.defineProperty(Xi.prototype,"readableHighWaterMark",{enumerable:false,get:a(function e(){return this._readableState.highWaterMark},"get")});Object.defineProperty(Xi.prototype,"readableBuffer",{enumerable:false,get:a(function e(){return this._readableState&&this._readableState.buffer},"get")});Object.defineProperty(Xi.prototype,"readableFlowing",{enumerable:false,get:a(function e(){return this._readableState.flowing},"get"),set:a(function e(t){if(this._readableState){this._readableState.flowing=t}},"set")});Xi._fromList=T1t;Object.defineProperty(Xi.prototype,"readableLength",{enumerable:false,get:a(function e(){return this._readableState.length},"get")});function T1t(e,t){if(t.length===0)return null;var r;if(t.objectMode)r=t.buffer.shift();else if(!e||e>=t.length){if(t.decoder)r=t.buffer.join("");else if(t.buffer.length===1)r=t.buffer.first();else r=t.buffer.concat(t.length);t.buffer.clear()}else{r=t.buffer.consume(e,t.decoder)}return r}a(T1t,"fromList");function W2e(e){var t=e._readableState;ei("endReadable",t.endEmitted);if(!t.endEmitted){t.ended=true;process.nextTick(qun,t,e)}}a(W2e,"endReadable");function qun(e,t){ei("endReadableNT",e.endEmitted,e.length);if(!e.endEmitted&&e.length===0){e.endEmitted=true;t.readable=false;t.emit("end");if(e.autoDestroy){var r=t._writableState;if(!r||r.autoDestroy&&r.finished){t.destroy()}}}}a(qun,"endReadableNT");if(typeof Symbol==="function"){Xi.from=function(e,t){if(V2e===void 0){V2e=_1t()}return V2e(Xi,e,t)}}function x1t(e,t){for(var r=0,n=e.length;r<n;r++){if(e[r]===t)return r}return-1}a(x1t,"indexOf")});var Q2e=y((TOs,P1t)=>{"use strict";P1t.exports=oy;var TW=Xv().codes;var Uun=TW.ERR_METHOD_NOT_IMPLEMENTED;var $un=TW.ERR_MULTIPLE_CALLBACK;var jun=TW.ERR_TRANSFORM_ALREADY_TRANSFORMING;var Gun=TW.ERR_TRANSFORM_WITH_LENGTH_0;var xW=bA();Jv()(oy,xW);function Hun(e,t){var r=this._transformState;r.transforming=false;var n=r.writecb;if(n===null){return this.emit("error",new $un)}r.writechunk=null;r.writecb=null;if(t!=null)this.push(t);n(e);var i=this._readableState;i.reading=false;if(i.needReadable||i.length<i.highWaterMark){this._read(i.highWaterMark)}}a(Hun,"afterTransform");function oy(e){if(!(this instanceof oy))return new oy(e);xW.call(this,e);this._transformState={afterTransform:Hun.bind(this),needTransform:false,transforming:false,writecb:null,writechunk:null,writeencoding:null};this._readableState.needReadable=true;this._readableState.sync=false;if(e){if(typeof e.transform==="function")this._transform=e.transform;if(typeof e.flush==="function")this._flush=e.flush}this.on("prefinish",Vun)}a(oy,"Transform");function Vun(){var e=this;if(typeof this._flush==="function"&&!this._readableState.destroyed){this._flush(function(t,r){O1t(e,t,r)})}else{O1t(this,null,null)}}a(Vun,"prefinish");oy.prototype.push=function(e,t){this._transformState.needTransform=false;return xW.prototype.push.call(this,e,t)};oy.prototype._transform=function(e,t,r){r(new Uun("_transform()"))};oy.prototype._write=function(e,t,r){var n=this._transformState;n.writecb=r;n.writechunk=e;n.writeencoding=t;if(!n.transforming){var i=this._readableState;if(n.needTransform||i.needReadable||i.length<i.highWaterMark)this._read(i.highWaterMark)}};oy.prototype._read=function(e){var t=this._transformState;if(t.writechunk!==null&&!t.transforming){t.transforming=true;this._transform(t.writechunk,t.writeencoding,t.afterTransform)}else{t.needTransform=true}};oy.prototype._destroy=function(e,t){xW.prototype._destroy.call(this,e,function(r){t(r)})};function O1t(e,t,r){if(t)return e.emit("error",t);if(r!=null)e.push(r);if(e._writableState.length)throw new Gun;if(e._transformState.transforming)throw new jun;return e.push(null)}a(O1t,"done")});var k1t=y((ROs,I1t)=>{"use strict";I1t.exports=eL;var N1t=Q2e();Jv()(eL,N1t);function eL(e){if(!(this instanceof eL))return new eL(e);N1t.call(this,e)}a(eL,"PassThrough");eL.prototype._transform=function(e,t,r){r(null,e)}});var M1t=y((POs,B1t)=>{"use strict";var Z2e;function zun(e){var t=false;return function(){if(t)return;t=true;e.apply(void 0,arguments)}}a(zun,"once");var F1t=Xv().codes;var Kun=F1t.ERR_MISSING_ARGS;var Wun=F1t.ERR_STREAM_DESTROYED;function D1t(e){if(e)throw e}a(D1t,"noop");function Yun(e){return e.setHeader&&typeof e.abort==="function"}a(Yun,"isRequest");function Xun(e,t,r,n){n=zun(n);var i=false;e.on("close",function(){i=true});if(Z2e===void 0)Z2e=EW();Z2e(e,{readable:t,writable:r},function(o){if(o)return n(o);i=true;n()});var s=false;return function(o){if(i)return;if(s)return;s=true;if(Yun(e))return e.abort();if(typeof e.destroy==="function")return e.destroy();n(o||new Wun("pipe"))}}a(Xun,"destroyer");function L1t(e){e()}a(L1t,"call");function Jun(e,t){return e.pipe(t)}a(Jun,"pipe");function Qun(e){if(!e.length)return D1t;if(typeof e[e.length-1]!=="function")return D1t;return e.pop()}a(Qun,"popCallback");function Zun(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++){t[r]=arguments[r]}var n=Qun(t);if(Array.isArray(t[0]))t=t[0];if(t.length<2){throw new Kun("streams")}var i;var s=t.map(function(o,u){var l=u<t.length-1;var c=u>0;return Xun(o,l,c,function(d){if(!i)i=d;if(d)s.forEach(L1t);if(l)return;s.forEach(L1t);n(i)})});return t.reduce(Jun)}a(Zun,"pipeline");B1t.exports=Zun});var q1t=y((hf,rL)=>{var tL=require("stream");if(process.env.READABLE_STREAM==="disable"&&tL){rL.exports=tL.Readable;Object.assign(rL.exports,tL);rL.exports.Stream=tL}else{hf=rL.exports=B2e();hf.Stream=tL||hf;hf.Readable=hf;hf.Writable=D2e();hf.Duplex=bA();hf.Transform=Q2e();hf.PassThrough=k1t();hf.finished=EW();hf.pipeline=M1t()}});var eSe=y((IOs,$1t)=>{$1t.exports=U1t;function U1t(e,t){if(e&&t)return U1t(e)(t);if(typeof e!=="function")throw new TypeError("need wrapper function");Object.keys(e).forEach(function(n){r[n]=e[n]});return r;function r(){var n=new Array(arguments.length);for(var i=0;i<n.length;i++){n[i]=arguments[i]}var s=e.apply(this,n);var o=n[n.length-1];if(typeof s==="function"&&s!==o){Object.keys(o).forEach(function(u){s[u]=o[u]})}return s}a(r,"wrapper")}a(U1t,"wrappy")});var OW=y((DOs,tSe)=>{var j1t=eSe();tSe.exports=j1t(RW);tSe.exports.strict=j1t(G1t);RW.proto=RW(function(){Object.defineProperty(Function.prototype,"once",{value:function(){return RW(this)},configurable:true});Object.defineProperty(Function.prototype,"onceStrict",{value:function(){return G1t(this)},configurable:true})});function RW(e){var t=a(function(){if(t.called)return t.value;t.called=true;return t.value=e.apply(this,arguments)},"f");t.called=false;return t}a(RW,"once");function G1t(e){var t=a(function(){if(t.called)throw new Error(t.onceError);t.called=true;return t.value=e.apply(this,arguments)},"f");var r=e.name||"Function wrapped with `once`";t.onceError=r+" shouldn't be called more than once";t.called=false;return t}a(G1t,"onceStrict")});var z1t=y((FOs,V1t)=>{var eln=OW();var tln=a(function(){},"noop");var rln=a(function(e){return e.setHeader&&typeof e.abort==="function"},"isRequest");var nln=a(function(e){return e.stdio&&Array.isArray(e.stdio)&&e.stdio.length===3},"isChildProcess");var H1t=a(function(e,t,r){if(typeof t==="function")return H1t(e,null,t);if(!t)t={};r=eln(r||tln);var n=e._writableState;var i=e._readableState;var s=t.readable||t.readable!==false&&e.readable;var o=t.writable||t.writable!==false&&e.writable;var u=false;var l=a(function(){if(!e.writable)c()},"onlegacyfinish");var c=a(function(){o=false;if(!s)r.call(e)},"onfinish");var d=a(function(){s=false;if(!o)r.call(e)},"onend");var p=a(function(_){r.call(e,_?new Error("exited with error code: "+_):null)},"onexit");var f=a(function(_){r.call(e,_)},"onerror");var m=a(function(){process.nextTick(h)},"onclose");var h=a(function(){if(u)return;if(s&&!(i&&(i.ended&&!i.destroyed)))return r.call(e,new Error("premature close"));if(o&&!(n&&(n.ended&&!n.destroyed)))return r.call(e,new Error("premature close"))},"onclosenexttick");var g=a(function(){e.req.on("finish",c)},"onrequest");if(rln(e)){e.on("complete",c);e.on("abort",m);if(e.req)g();else e.on("request",g)}else if(o&&!n){e.on("end",l);e.on("close",l)}if(nln(e))e.on("exit",p);e.on("end",d);e.on("finish",c);if(t.error!==false)e.on("error",f);e.on("close",m);return function(){u=true;e.removeListener("complete",c);e.removeListener("abort",m);e.removeListener("request",g);if(e.req)e.req.removeListener("finish",c);e.removeListener("end",l);e.removeListener("close",l);e.removeListener("finish",c);e.removeListener("exit",p);e.removeListener("end",d);e.removeListener("error",f);e.removeListener("close",m)}},"eos");V1t.exports=H1t});var W1t=y((MOs,K1t)=>{K1t.exports=iln;function iln(e){var t=e._readableState;if(!t)return null;return t.objectMode||typeof e._duplexState==="number"?e.read():e.read(sln(t))}a(iln,"shift");function sln(e){if(e.buffer.length){if(e.buffer.head){return e.buffer.head.data.length}return e.buffer[0].length}return e.length}a(sln,"getStateLength")});var nSe=y((UOs,Q1t)=>{var PW=q1t();var Y1t=z1t();var aln=Jv();var oln=W1t();var X1t=Buffer.from&&Buffer.from!==Uint8Array.from?Buffer.from([0]):new Buffer([0]);var rSe=a(function(e,t){if(e._corked)e.once("uncork",t);else t()},"onuncork");var uln=a(function(e,t){if(e._autoDestroy)e.destroy(t)},"autoDestroy");var J1t=a(function(e,t){return function(r){if(r)uln(e,r.message==="premature close"?null:r);else if(t&&!e._ended)e.end()}},"destroyer");var lln=a(function(e,t){if(!e)return t();if(e._writableState&&e._writableState.finished)return t();if(e._writableState)return e.end(t);e.end();t()},"end");var cln=a(function(){},"noop");var dln=a(function(e){return new PW.Readable({objectMode:true,highWaterMark:16}).wrap(e)},"toStreams2");var el=a(function(e,t,r){if(!(this instanceof el))return new el(e,t,r);PW.Duplex.call(this,r);this._writable=null;this._readable=null;this._readable2=null;this._autoDestroy=!r||r.autoDestroy!==false;this._forwardDestroy=!r||r.destroy!==false;this._forwardEnd=!r||r.end!==false;this._corked=1;this._ondrain=null;this._drained=false;this._forwarding=false;this._unwrite=null;this._unread=null;this._ended=false;this.destroyed=false;if(e)this.setWritable(e);if(t)this.setReadable(t)},"Duplexify");aln(el,PW.Duplex);el.obj=function(e,t,r){if(!r)r={};r.objectMode=true;r.highWaterMark=16;return new el(e,t,r)};el.prototype.cork=function(){if(++this._corked===1)this.emit("cork")};el.prototype.uncork=function(){if(this._corked&&--this._corked===0)this.emit("uncork")};el.prototype.setWritable=function(e){if(this._unwrite)this._unwrite();if(this.destroyed){if(e&&e.destroy)e.destroy();return}if(e===null||e===false){this.end();return}var t=this;var r=Y1t(e,{writable:true,readable:false},J1t(this,this._forwardEnd));var n=a(function(){var s=t._ondrain;t._ondrain=null;if(s)s()},"ondrain");var i=a(function(){t._writable.removeListener("drain",n);r()},"clear");if(this._unwrite)process.nextTick(n);this._writable=e;this._writable.on("drain",n);this._unwrite=i;this.uncork()};el.prototype.setReadable=function(e){if(this._unread)this._unread();if(this.destroyed){if(e&&e.destroy)e.destroy();return}if(e===null||e===false){this.push(null);this.resume();return}var t=this;var r=Y1t(e,{writable:false,readable:true},J1t(this));var n=a(function(){t._forward()},"onreadable");var i=a(function(){t.push(null)},"onend");var s=a(function(){t._readable2.removeListener("readable",n);t._readable2.removeListener("end",i);r()},"clear");this._drained=true;this._readable=e;this._readable2=e._readableState?e:dln(e);this._readable2.on("readable",n);this._readable2.on("end",i);this._unread=s;this._forward()};el.prototype._read=function(){this._drained=true;this._forward()};el.prototype._forward=function(){if(this._forwarding||!this._readable2||!this._drained)return;this._forwarding=true;var e;while(this._drained&&(e=oln(this._readable2))!==null){if(this.destroyed)continue;this._drained=this.push(e)}this._forwarding=false};el.prototype.destroy=function(e,t){if(!t)t=cln;if(this.destroyed)return t(null);this.destroyed=true;var r=this;process.nextTick(function(){r._destroy(e);t(null)})};el.prototype._destroy=function(e){if(e){var t=this._ondrain;this._ondrain=null;if(t)t(e);else this.emit("error",e)}if(this._forwardDestroy){if(this._readable&&this._readable.destroy)this._readable.destroy();if(this._writable&&this._writable.destroy)this._writable.destroy()}this.emit("close")};el.prototype._write=function(e,t,r){if(this.destroyed)return;if(this._corked)return rSe(this,this._write.bind(this,e,t,r));if(e===X1t)return this._finish(r);if(!this._writable)return r();if(this._writable.write(e)===false)this._ondrain=r;else if(!this.destroyed)r()};el.prototype._finish=function(e){var t=this;this.emit("preend");rSe(this,function(){lln(t._forwardEnd&&t._writable,function(){if(t._writableState.prefinished===false)t._writableState.prefinished=true;t.emit("prefinish");rSe(t,e)})})};el.prototype.end=function(e,t,r){if(typeof e==="function")return this.end(null,null,e);if(typeof t==="function")return this.end(e,null,t);this._ended=true;if(e)this.write(e);if(!this._writableState.ending&&!this._writableState.destroyed)this.write(X1t);return PW.Writable.prototype.end.call(this,r)};Q1t.exports=el});var TA=y(io=>{"use strict";var pln=io&&io.__createBinding||(Object.create?function(e,t,r,n){if(n===void 0)n=r;var i=Object.getOwnPropertyDescriptor(t,r);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[r]}}}Object.defineProperty(e,n,i)}:function(e,t,r,n){if(n===void 0)n=r;e[n]=t[r]});var fln=io&&io.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var ryt=io&&io.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null){for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))pln(t,e,r)}fln(t,e);return t};var nyt=io&&io.__importDefault||function(e){return e&&e.__esModule?e:{"default":e}};Object.defineProperty(io,"__esModule",{value:true});io.util=io.Util=io.PartialFailureError=io.ApiError=io.GCCL_GCS_CMD_KEY=void 0;var nL=Tft();var mln=ryt(Lft());var Z1t=iW();var eyt=nyt(M0t());var hln=require("stream");var tyt=Igt();var gln=ryt((Fv(),Ct(Lv)));var iSe=oSe();var sSe=P0();var yln=nyt(nSe());var _ln=KR();var vln=(0,_ln.getPackageJSON)();io.GCCL_GCS_CMD_KEY=Symbol.for("GCCL_GCS_CMD");var NW={timeout:6e4,gzip:true,forever:true,pool:{maxSockets:Infinity}};var Eln=true;var bln=3;var wA=class e extends Error{static{a(this,"ApiError")}constructor(t){super();if(typeof t!=="object"){this.message=t||"";return}const r=t;this.code=r.code;this.errors=r.errors;this.response=r.response;try{this.errors=JSON.parse(this.response.body).error.errors}catch(n){this.errors=r.errors}this.message=e.createMultiErrorMessage(r,this.errors);Error.captureStackTrace(this)}static createMultiErrorMessage(t,r){const n=new Set;if(t.message){n.add(t.message)}if(r&&r.length){r.forEach(({message:s})=>n.add(s))}else if(t.response&&t.response.body){n.add(mln.decode(t.response.body.toString()))}else if(!t.message){n.add("A failure occurred during this request.")}let i=Array.from(n);if(i.length>1){i=i.map((s,o)=>` ${o+1}. ${s}`);i.unshift("Multiple errors occurred during the request. Please see the `errors` array for complete details.\n");i.push("\n")}return i.join("\n")}};io.ApiError=wA;var IW=class extends Error{static{a(this,"PartialFailureError")}constructor(t){super();const r=t;this.errors=r.errors;this.name="PartialFailureError";this.response=r.response;this.message=wA.createMultiErrorMessage(r,this.errors)}};io.PartialFailureError=IW;var kW=class{static{a(this,"Util")}constructor(){this.ApiError=wA;this.PartialFailureError=IW}noop(){}handleResp(t,r,n,i){i=i||up.noop;const s={err:t||null,...r&&up.parseHttpRespMessage(r),...n&&up.parseHttpRespBody(n)};if(!s.err&&r&&typeof s.body==="object"){s.resp.body=s.body}if(s.err&&r){s.err.response=r}i(s.err,s.body,s.resp)}parseHttpRespMessage(t){const r={resp:t};if(t.statusCode<200||t.statusCode>299){r.err=new wA({errors:new Array,code:t.statusCode,message:t.statusMessage,response:t})}return r}parseHttpRespBody(t){const r={body:t};if(typeof t==="string"){try{r.body=JSON.parse(t)}catch(n){r.body=t}}if(r.body&&r.body.error){r.err=new wA(r.body.error)}return r}makeWritableStream(t,r,n){var i;n=n||up.noop;const s=new aSe;s.on("progress",c=>t.emit("progress",c));t.setWritable(s);const o={method:"POST",qs:{uploadType:"multipart"},timeout:0,maxRetries:0};const u=r.metadata||{};const l={...o,...r.request,qs:{...o.qs,...(i=r.request)===null||i===void 0?void 0:i.qs},multipart:[{"Content-Type":"application/json",body:JSON.stringify(u)},{"Content-Type":u.contentType||"application/octet-stream",body:s}]};r.makeAuthenticatedRequest(l,{onAuthenticated(c,d){if(c){t.destroy(c);return}NW.headers=up._getDefaultHeaders(l[io.GCCL_GCS_CMD_KEY]);const p=tyt.teenyRequest.defaults(NW);p(d,(f,m,h)=>{up.handleResp(f,m,h,(g,_)=>{if(g){t.destroy(g);return}t.emit("response",m);n(_)})})}})}shouldRetryRequest(t){if(t){if([408,429,500,502,503,504].indexOf(t.code)!==-1){return true}if(t.errors){for(const r of t.errors){const n=r.reason;if(n==="rateLimitExceeded"){return true}if(n==="userRateLimitExceeded"){return true}if(n&&n.includes("EAI_AGAIN")){return true}}}}return false}makeAuthenticatedRequestFactory(t){const r={...t};if(r.projectId===iSe.DEFAULT_PROJECT_ID_TOKEN){delete r.projectId}let n;if(r.authClient instanceof Z1t.GoogleAuth){n=r.authClient}else{const o={...r,authClient:r.authClient};n=new Z1t.GoogleAuth(o)}function i(o,u){let l;let c;const d={...t};let p;if(!u){l=(0,yln.default)();d.stream=l}const f=typeof u==="object"?u:void 0;const m=typeof u==="function"?u:void 0;async function h(){c=await n.getProjectId()}a(h,"setProjectId");const g=a(async(v,S)=>{const E=v;const b=v&&typeof v.message==="string"&&v.message.indexOf("Could not load the default credentials")>-1;if(b){S=o}if(!v||b){try{S=up.decorateRequest(S,c);v=null}catch(A){if(A instanceof nL.MissingProjectIdError){try{await h();S=up.decorateRequest(S,c);v=null}catch(C){v=v||C}}else{v=v||A}}}if(v){if(l){l.destroy(v)}else{const A=f&&f.onAuthenticated?f.onAuthenticated:m;A(v)}return}if(f&&f.onAuthenticated){f.onAuthenticated(null,S)}else{p=up.makeRequest(S,d,(A,...C)=>{if(A&&A.code===401&&E){A=E}m(A,...C)})}},"onAuthenticated");const _=a(async()=>{try{const v=a(async()=>{if(t.projectId&&t.projectId!==iSe.DEFAULT_PROJECT_ID_TOKEN){return t.projectId}if(t.projectIdRequired===false){return iSe.DEFAULT_PROJECT_ID_TOKEN}return h()},"getProjectId");const S=a(async()=>{if(d.customEndpoint&&!d.useAuthWithCustomEndpoint){return o}else{return n.authorizeRequest(o)}},"authorizeRequest");const[E,b]=await Promise.all([v(),S()]);if(E){c=E}return g(null,b)}catch(v){return g(v)}},"prepareRequest");_();if(l){return l}return{abort(){setImmediate(()=>{if(p){p.abort();p=null}})}}}a(i,"makeAuthenticatedRequest");const s=i;s.getCredentials=n.getCredentials.bind(n);s.authClient=n;return s}makeRequest(t,r,n){var i,s,o,u,l;let c=Eln;if(r.autoRetry!==void 0){c=r.autoRetry}else if(((i=r.retryOptions)===null||i===void 0?void 0:i.autoRetry)!==void 0){c=r.retryOptions.autoRetry}let d=bln;if(r.maxRetries!==void 0){d=r.maxRetries}else if(((s=r.retryOptions)===null||s===void 0?void 0:s.maxRetries)!==void 0){d=r.retryOptions.maxRetries}NW.headers=this._getDefaultHeaders(t[io.GCCL_GCS_CMD_KEY]);const p={request:tyt.teenyRequest.defaults(NW),retries:c!==false?d:0,noResponseRetries:c!==false?d:0,shouldRetryFn(g){var _,v;const S=up.parseHttpRespMessage(g).err;if((_=r.retryOptions)===null||_===void 0?void 0:_.retryableErrorFn){return S&&((v=r.retryOptions)===null||v===void 0?void 0:v.retryableErrorFn(S))}return S&&up.shouldRetryRequest(S)},maxRetryDelay:(o=r.retryOptions)===null||o===void 0?void 0:o.maxRetryDelay,retryDelayMultiplier:(u=r.retryOptions)===null||u===void 0?void 0:u.retryDelayMultiplier,totalTimeout:(l=r.retryOptions)===null||l===void 0?void 0:l.totalTimeout};if(typeof t.maxRetries==="number"){p.retries=t.maxRetries;p.noResponseRetries=t.maxRetries}if(!r.stream){return(0,eyt.default)(t,p,(g,_,v)=>{up.handleResp(g,_,v,n)})}const f=r.stream;let m;const h=(t.method||"GET").toUpperCase()==="GET";if(h){m=(0,eyt.default)(t,p);f.setReadable(m)}else{m=p.request(t);f.setWritable(m)}m.on("error",f.destroy.bind(f)).on("response",f.emit.bind(f,"response")).on("complete",f.emit.bind(f,"complete"));f.abort=m.abort;return f}decorateRequest(t,r){delete t.autoPaginate;delete t.autoPaginateVal;delete t.objectMode;if(t.qs!==null&&typeof t.qs==="object"){delete t.qs.autoPaginate;delete t.qs.autoPaginateVal;t.qs=(0,nL.replaceProjectIdToken)(t.qs,r)}if(Array.isArray(t.multipart)){t.multipart=t.multipart.map(n=>{return(0,nL.replaceProjectIdToken)(n,r)})}if(t.json!==null&&typeof t.json==="object"){delete t.json.autoPaginate;delete t.json.autoPaginateVal;t.json=(0,nL.replaceProjectIdToken)(t.json,r)}t.uri=(0,nL.replaceProjectIdToken)(t.uri,r);return t}isCustomType(t,r){function n(l){return l.constructor&&l.constructor.name.toLowerCase()}a(n,"getConstructorName");const i=r.split("/");const s=i[0]&&i[0].toLowerCase();const o=i[1]&&i[1].toLowerCase();if(o&&n(t)!==o){return false}let u=t;while(true){if(n(u)===s){return true}u=u.parent;if(!u){return false}}}maybeOptionsOrCallback(t,r){return typeof t==="function"?[{},t]:[t,r]}_getDefaultHeaders(t){const r={"User-Agent":(0,sSe.getUserAgentString)(),"x-goog-api-client":`${(0,sSe.getRuntimeTrackingString)()} gccl/${vln.version}-${(0,sSe.getModuleFormat)()} gccl-invocation-id/${gln.v4()}`};if(t){r["x-goog-api-client"]+=` gccl-gcs-cmd/${t}`}return r}};io.Util=kW;var aSe=class extends hln.Transform{static{a(this,"ProgressStream")}constructor(){super(...arguments);this.bytesRead=0}_transform(t,r,n){this.bytesRead+=t.length;this.emit("progress",{bytesWritten:this.bytesRead,contentLength:"*"});this.push(t);n()}};var up=new kW;io.util=up});var oSe=y(ld=>{"use strict";var Sln=ld&&ld.__createBinding||(Object.create?function(e,t,r,n){if(n===void 0)n=r;var i=Object.getOwnPropertyDescriptor(t,r);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[r]}}}Object.defineProperty(e,n,i)}:function(e,t,r,n){if(n===void 0)n=r;e[n]=t[r]});var Aln=ld&&ld.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var Cln=ld&&ld.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null){for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))Sln(t,e,r)}Aln(t,e);return t};Object.defineProperty(ld,"__esModule",{value:true});ld.Service=ld.DEFAULT_PROJECT_ID_TOKEN=void 0;var wln=Cln((Fv(),Ct(Lv)));var uSe=TA();var lSe=P0();ld.DEFAULT_PROJECT_ID_TOKEN="{{projectId}}";var cSe=class e{static{a(this,"Service")}constructor(t,r={}){this.baseUrl=t.baseUrl;this.apiEndpoint=t.apiEndpoint;this.timeout=r.timeout;this.globalInterceptors=Array.isArray(r.interceptors_)?r.interceptors_:[];this.interceptors=[];this.packageJson=t.packageJson;this.projectId=r.projectId||ld.DEFAULT_PROJECT_ID_TOKEN;this.projectIdRequired=t.projectIdRequired!==false;this.providedUserAgent=r.userAgent;const n={...t,projectIdRequired:this.projectIdRequired,projectId:this.projectId,authClient:r.authClient||t.authClient,credentials:r.credentials,keyFile:r.keyFilename,email:r.email,token:r.token};this.makeAuthenticatedRequest=uSe.util.makeAuthenticatedRequestFactory(n);this.authClient=this.makeAuthenticatedRequest.authClient;this.getCredentials=this.makeAuthenticatedRequest.getCredentials;const i=!!process.env.FUNCTION_NAME;if(i){this.interceptors.push({request(s){s.forever=false;return s}})}}getRequestInterceptors(){return[].slice.call(this.globalInterceptors).concat(this.interceptors).filter(t=>typeof t.request==="function").map(t=>t.request)}getProjectId(t){if(!t){return this.getProjectIdAsync()}this.getProjectIdAsync().then(r=>t(null,r),t)}async getProjectIdAsync(){const t=await this.authClient.getProjectId();if(this.projectId===ld.DEFAULT_PROJECT_ID_TOKEN&&t){this.projectId=t}return this.projectId}request_(t,r){t={...t,timeout:this.timeout};const n=t.uri.indexOf("http")===0;const i=[this.baseUrl];if(this.projectIdRequired){if(t.projectId){i.push("projects");i.push(t.projectId)}else{i.push("projects");i.push(this.projectId)}}i.push(t.uri);if(n){i.splice(0,i.indexOf(t.uri))}t.uri=i.map(c=>{const d=/^\/*|\/*$/g;return c.replace(d,"")}).join("/").replace(/\/:/g,":");const s=this.getRequestInterceptors();const o=Array.isArray(t.interceptors_)?t.interceptors_:[];o.forEach(c=>{if(typeof c.request==="function"){s.push(c.request)}});s.forEach(c=>{t=c(t)});delete t.interceptors_;const u=this.packageJson;let l=(0,lSe.getUserAgentString)();if(this.providedUserAgent){l=`${this.providedUserAgent} ${l}`}t.headers={...t.headers,"User-Agent":l,"x-goog-api-client":`${(0,lSe.getRuntimeTrackingString)()} gccl/${u.version}-${(0,lSe.getModuleFormat)()} gccl-invocation-id/${wln.v4()}`};if(t[uSe.GCCL_GCS_CMD_KEY]){t.headers["x-goog-api-client"]+=` gccl-gcs-cmd/${t[uSe.GCCL_GCS_CMD_KEY]}`}if(t.shouldReturnStream){return this.makeAuthenticatedRequest(t)}else{this.makeAuthenticatedRequest(t,r)}}request(t,r){e.prototype.request_.call(this,t,r)}requestStream(t){const r={...t,shouldReturnStream:true};return e.prototype.request_.call(this,r)}};ld.Service=cSe});var I0=y(gf=>{"use strict";Object.defineProperty(gf,"__esModule",{value:true});gf.callbackifyAll=gf.callbackify=gf.promisifyAll=gf.promisify=void 0;function Tln(e,t){if(e.promisified_){return e}t=t||{};const r=Array.prototype.slice;const n=a(function(){let i;for(i=arguments.length-1;i>=0;i--){const u=arguments[i];if(typeof u==="undefined"){continue}if(typeof u!=="function"){break}return e.apply(this,arguments)}const s=r.call(arguments,0,i+1);let o=Promise;if(this&&this.Promise){o=this.Promise}return new o((u,l)=>{s.push((...c)=>{const d=r.call(c);const p=d.shift();if(p){return l(p)}if(t.singular&&d.length===1){u(d[0])}else{u(d)}});e.apply(this,s)})},"wrapper");n.promisified_=true;return n}a(Tln,"promisify");gf.promisify=Tln;function xln(e,t){const r=t&&t.exclude||[];const n=Object.getOwnPropertyNames(e.prototype);const i=n.filter(s=>{return!r.includes(s)&&typeof e.prototype[s]==="function"&&!/(^_|(Stream|_)|promise$)|^constructor$/.test(s)});i.forEach(s=>{const o=e.prototype[s];if(!o.promisified_){e.prototype[s]=gf.promisify(o,t)}})}a(xln,"promisifyAll");gf.promisifyAll=xln;function Rln(e){if(e.callbackified_){return e}const t=a(function(){if(typeof arguments[arguments.length-1]!=="function"){return e.apply(this,arguments)}const r=Array.prototype.pop.call(arguments);e.apply(this,arguments).then(n=>{n=Array.isArray(n)?n:[n];r(null,...n)},n=>r(n))},"wrapper");t.callbackified_=true;return t}a(Rln,"callbackify");gf.callbackify=Rln;function Oln(e,t){const r=t&&t.exclude||[];const n=Object.getOwnPropertyNames(e.prototype);const i=n.filter(s=>{return!r.includes(s)&&typeof e.prototype[s]==="function"&&!/^_|(Stream|_)|^constructor$/.test(s)});i.forEach(s=>{const o=e.prototype[s];if(!o.callbackified_){e.prototype[s]=gf.callbackify(o)}})}a(Oln,"callbackifyAll");gf.callbackifyAll=Oln});var iyt=y(LW=>{"use strict";Object.defineProperty(LW,"__esModule",{value:true});LW.ServiceObject=void 0;var Pln=I0();var Nln=require("events");var iL=TA();var DW=class e extends Nln.EventEmitter{static{a(this,"ServiceObject")}constructor(t){super();this.metadata={};this.baseUrl=t.baseUrl;this.parent=t.parent;this.id=t.id;this.createMethod=t.createMethod;this.methods=t.methods||{};this.interceptors=[];this.projectId=t.projectId;if(t.methods){Object.getOwnPropertyNames(e.prototype).filter(r=>{return!/^request/.test(r)&&!/^getRequestInterceptors/.test(r)&&this[r]===e.prototype[r]&&!t.methods[r]}).forEach(r=>{this[r]=void 0})}}create(t,r){const n=this;const i=[this.id];if(typeof t==="function"){r=t}if(typeof t==="object"){i.push(t)}function s(...o){const[u,l]=o;if(!u){n.metadata=l.metadata;if(n.id&&l.metadata){n.id=l.metadata.id}o[1]=n}r(...o)}a(s,"onCreate");i.push(s);this.createMethod.apply(null,i)}delete(t,r){var n;const[i,s]=iL.util.maybeOptionsOrCallback(t,r);const o=i.ignoreNotFound;delete i.ignoreNotFound;const u=typeof this.methods.delete==="object"&&this.methods.delete||{};const l={method:"DELETE",uri:"",...u.reqOpts,qs:{...(n=u.reqOpts)===null||n===void 0?void 0:n.qs,...i}};e.prototype.request.call(this,l,(c,d,p)=>{if(c){if(c.code===404&&o){c=null}}s(c,p)})}exists(t,r){const[n,i]=iL.util.maybeOptionsOrCallback(t,r);this.get(n,s=>{if(s){if(s.code===404){i(null,false)}else{i(s)}return}i(null,true)})}get(t,r){const n=this;const[i,s]=iL.util.maybeOptionsOrCallback(t,r);const o=Object.assign({},i);const u=o.autoCreate&&typeof this.create==="function";delete o.autoCreate;function l(c,d,p){if(c){if(c.code===409){n.get(o,s);return}s(c,null,p);return}s(null,d,p)}a(l,"onCreate");this.getMetadata(o,(c,d)=>{if(c){if(c.code===404&&u){const p=[];if(Object.keys(o).length>0){p.push(o)}p.push(l);n.create(...p);return}s(c,null,d);return}s(null,n,d)})}getMetadata(t,r){var n;const[i,s]=iL.util.maybeOptionsOrCallback(t,r);const o=typeof this.methods.getMetadata==="object"&&this.methods.getMetadata||{};const u={uri:"",...o.reqOpts,qs:{...(n=o.reqOpts)===null||n===void 0?void 0:n.qs,...i}};e.prototype.request.call(this,u,(l,c,d)=>{this.metadata=c;s(l,this.metadata,d)})}getRequestInterceptors(){const t=this.interceptors.filter(r=>typeof r.request==="function").map(r=>r.request);return this.parent.getRequestInterceptors().concat(t)}setMetadata(t,r,n){var i,s;const[o,u]=iL.util.maybeOptionsOrCallback(r,n);const l=typeof this.methods.setMetadata==="object"&&this.methods.setMetadata||{};const c={method:"PATCH",uri:"",...l.reqOpts,json:{...(i=l.reqOpts)===null||i===void 0?void 0:i.json,...t},qs:{...(s=l.reqOpts)===null||s===void 0?void 0:s.qs,...o}};e.prototype.request.call(this,c,(d,p,f)=>{this.metadata=p;u(d,this.metadata,f)})}request_(t,r){t={...t};if(this.projectId){t.projectId=this.projectId}const n=t.uri.indexOf("http")===0;const i=[this.baseUrl,this.id||"",t.uri];if(n){i.splice(0,i.indexOf(t.uri))}t.uri=i.filter(u=>u.trim()).map(u=>{const l=/^\/*|\/*$/g;return u.replace(l,"")}).join("/");const s=Array.isArray(t.interceptors_)?t.interceptors_:[];const o=[].slice.call(this.interceptors);t.interceptors_=s.concat(o);if(t.shouldReturnStream){return this.parent.requestStream(t)}this.parent.request(t,r)}request(t,r){this.request_(t,r)}requestStream(t){const r={...t,shouldReturnStream:true};return this.request_(r)}};LW.ServiceObject=DW;(0,Pln.promisifyAll)(DW,{exclude:["getRequestInterceptors"]})});var rE=y(k0=>{"use strict";Object.defineProperty(k0,"__esModule",{value:true});k0.util=k0.ApiError=k0.ServiceObject=k0.Service=void 0;var Iln=oSe();Object.defineProperty(k0,"Service",{enumerable:true,get:function(){return Iln.Service}});var kln=iyt();Object.defineProperty(k0,"ServiceObject",{enumerable:true,get:function(){return kln.ServiceObject}});var syt=TA();Object.defineProperty(k0,"ApiError",{enumerable:true,get:function(){return syt.ApiError}});Object.defineProperty(k0,"util",{enumerable:true,get:function(){return syt.util}})});var dSe=y((JOs,ayt)=>{"use strict";var Dln=a(e=>{if(e===null||e===void 0){return[]}if(Array.isArray(e)){return e}if(typeof e==="string"){return[e]}if(typeof e[Symbol.iterator]==="function"){return[...e]}return[e]},"arrify");ayt.exports=Dln});var oyt=y(FW=>{"use strict";Object.defineProperty(FW,"__esModule",{value:true});FW.ResourceStream=void 0;var Lln=require("stream");var pSe=class extends Lln.Transform{static{a(this,"ResourceStream")}constructor(t,r){const n=Object.assign({objectMode:true},t.streamOptions);super(n);this._ended=false;this._maxApiCalls=t.maxApiCalls===-1?Infinity:t.maxApiCalls;this._nextQuery=t.query;this._reading=false;this._requestFn=r;this._requestsMade=0;this._resultsToSend=t.maxResults===-1?Infinity:t.maxResults}end(...t){this._ended=true;return super.end(...t)}_read(){if(this._reading){return}this._reading=true;try{this._requestFn(this._nextQuery,(t,r,n)=>{if(t){this.destroy(t);return}this._nextQuery=n;if(this._resultsToSend!==Infinity){r=r.splice(0,this._resultsToSend);this._resultsToSend-=r.length}let i=true;for(const u of r){if(this._ended){break}i=this.push(u)}const s=!this._nextQuery||this._resultsToSend<1;const o=++this._requestsMade>=this._maxApiCalls;if(s||o){this.end()}if(i&&!this._ended){setImmediate(()=>this._read())}this._reading=false})}catch(t){this.destroy(t)}}};FW.ResourceStream=pSe});var fSe=y(nE=>{"use strict";Object.defineProperty(nE,"__esModule",{value:true});nE.ResourceStream=nE.paginator=nE.Paginator=void 0;var Fln=dSe();var uyt=y9();var lyt=oyt();Object.defineProperty(nE,"ResourceStream",{enumerable:true,get:function(){return lyt.ResourceStream}});var BW=class{static{a(this,"Paginator")}extend(t,r){r=Fln(r);r.forEach(n=>{const i=t.prototype[n];t.prototype[n+"_"]=i;t.prototype[n]=function(...s){const o=ZR.parseArguments_(s);return ZR.run_(o,i.bind(this))}})}streamify(t){return function(...r){const n=ZR.parseArguments_(r);const i=this[t+"_"]||this[t];return ZR.runAsStream_(n,i.bind(this))}}parseArguments_(t){let r;let n=true;let i=-1;let s=-1;let o;const u=t[0];const l=t[t.length-1];if(typeof u==="function"){o=u}else{r=u}if(typeof l==="function"){o=l}if(typeof r==="object"){r=uyt(true,{},r);if(r.maxResults&&typeof r.maxResults==="number"){s=r.maxResults}else if(typeof r.pageSize==="number"){s=r.pageSize}if(r.maxApiCalls&&typeof r.maxApiCalls==="number"){i=r.maxApiCalls;delete r.maxApiCalls}if(s!==-1||r.autoPaginate===false){n=false}}const c={query:r||{},autoPaginate:n,maxApiCalls:i,maxResults:s,callback:o};c.streamOptions=uyt(true,{},c.query);delete c.streamOptions.autoPaginate;delete c.streamOptions.maxResults;delete c.streamOptions.pageSize;return c}run_(t,r){const n=t.query;const i=t.callback;if(!t.autoPaginate){return r(n,i)}const s=new Array;const o=new Promise((u,l)=>{ZR.runAsStream_(t,r).on("error",l).on("data",c=>s.push(c)).on("end",()=>u(s))});if(!i){return o.then(u=>[u])}o.then(u=>i(null,u),u=>i(u))}runAsStream_(t,r){return new lyt.ResourceStream(t,r)}};nE.Paginator=BW;var ZR=new BW;nE.paginator=ZR});var cyt=y((nPs,Bln)=>{Bln.exports={"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}}});var mSe=y((iPs,dyt)=>{dyt.exports=cyt()});var hSe=y(cd=>{"use strict";var MW=mSe();var Mln=require("path").extname;var pyt=/^\s*([^;\s]*)(?:;|\s|$)/;var qln=/^text\//i;cd.charset=fyt;cd.charsets={lookup:fyt};cd.contentType=Uln;cd.extension=$ln;cd.extensions=Object.create(null);cd.lookup=jln;cd.types=Object.create(null);Gln(cd.extensions,cd.types);function fyt(e){if(!e||typeof e!=="string"){return false}var t=pyt.exec(e);var r=t&&MW[t[1].toLowerCase()];if(r&&r.charset){return r.charset}if(t&&qln.test(t[1])){return"UTF-8"}return false}a(fyt,"charset");function Uln(e){if(!e||typeof e!=="string"){return false}var t=e.indexOf("/")===-1?cd.lookup(e):e;if(!t){return false}if(t.indexOf("charset")===-1){var r=cd.charset(t);if(r)t+="; charset="+r.toLowerCase()}return t}a(Uln,"contentType");function $ln(e){if(!e||typeof e!=="string"){return false}var t=pyt.exec(e);var r=t&&cd.extensions[t[1].toLowerCase()];if(!r||!r.length){return false}return r[0]}a($ln,"extension");function jln(e){if(!e||typeof e!=="string"){return false}var t=Mln("x."+e).toLowerCase().substr(1);if(!t){return false}return cd.types[t]||false}a(jln,"lookup");function Gln(e,t){var r=["nginx","apache",void 0,"iana"];Object.keys(MW).forEach(a(function n(i){var s=MW[i];var o=s.extensions;if(!o||!o.length){return}e[i]=o;for(var u=0;u<o.length;u++){var l=o[u];if(t[l]){var c=r.indexOf(MW[t[l]].source);var d=r.indexOf(s.source);if(t[l]!=="application/octet-stream"&&(c>d||c===d&&t[l].substr(0,12)==="application/")){continue}}t[l]=i}},"forEachMimeType"))}a(Gln,"populateMaps")});var hyt=y((oPs,myt)=>{var gSe=class{static{a(this,"Node")}constructor(t){this.value=t;this.next=void 0}};var ySe=class{static{a(this,"Queue")}constructor(){this.clear()}enqueue(t){const r=new gSe(t);if(this._head){this._tail.next=r;this._tail=r}else{this._head=r;this._tail=r}this._size++}dequeue(){const t=this._head;if(!t){return}this._head=this._head.next;this._size--;return t.value}clear(){this._head=void 0;this._tail=void 0;this._size=0}get size(){return this._size}*[Symbol.iterator](){let t=this._head;while(t){yield t.value;t=t.next}}};myt.exports=ySe});var _Se=y((lPs,gyt)=>{"use strict";var Hln=hyt();var Vln=a(e=>{if(!((Number.isInteger(e)||e===Infinity)&&e>0)){throw new TypeError("Expected `concurrency` to be a number from 1 and up")}const t=new Hln;let r=0;const n=a(()=>{r--;if(t.size>0){t.dequeue()()}},"next");const i=a(async(u,l,...c)=>{r++;const d=(async()=>u(...c))();l(d);try{await d}catch{}n()},"run");const s=a((u,l,...c)=>{t.enqueue(i.bind(null,u,l,...c));(async()=>{await Promise.resolve();if(r<e&&t.size>0){t.dequeue()()}})()},"enqueue");const o=a((u,...l)=>new Promise(c=>{s(u,c,...l)}),"generator");Object.defineProperties(o,{activeCount:{get:()=>r},pendingCount:{get:()=>t.size},clearQueue:{value:()=>{t.clear()}}});return o},"pLimit");gyt.exports=Vln});var _yt=y((dPs,yyt)=>{function yf(e,t){if(typeof t==="boolean"){t={forever:t}}this._originalTimeouts=JSON.parse(JSON.stringify(e));this._timeouts=e;this._options=t||{};this._maxRetryTime=t&&t.maxRetryTime||Infinity;this._fn=null;this._errors=[];this._attempts=1;this._operationTimeout=null;this._operationTimeoutCb=null;this._timeout=null;this._operationStart=null;this._timer=null;if(this._options.forever){this._cachedTimeouts=this._timeouts.slice(0)}}a(yf,"RetryOperation");yyt.exports=yf;yf.prototype.reset=function(){this._attempts=1;this._timeouts=this._originalTimeouts.slice(0)};yf.prototype.stop=function(){if(this._timeout){clearTimeout(this._timeout)}if(this._timer){clearTimeout(this._timer)}this._timeouts=[];this._cachedTimeouts=null};yf.prototype.retry=function(e){if(this._timeout){clearTimeout(this._timeout)}if(!e){return false}var t=new Date().getTime();if(e&&t-this._operationStart>=this._maxRetryTime){this._errors.push(e);this._errors.unshift(new Error("RetryOperation timeout occurred"));return false}this._errors.push(e);var r=this._timeouts.shift();if(r===void 0){if(this._cachedTimeouts){this._errors.splice(0,this._errors.length-1);r=this._cachedTimeouts.slice(-1)}else{return false}}var n=this;this._timer=setTimeout(function(){n._attempts++;if(n._operationTimeoutCb){n._timeout=setTimeout(function(){n._operationTimeoutCb(n._attempts)},n._operationTimeout);if(n._options.unref){n._timeout.unref()}}n._fn(n._attempts)},r);if(this._options.unref){this._timer.unref()}return true};yf.prototype.attempt=function(e,t){this._fn=e;if(t){if(t.timeout){this._operationTimeout=t.timeout}if(t.cb){this._operationTimeoutCb=t.cb}}var r=this;if(this._operationTimeoutCb){this._timeout=setTimeout(function(){r._operationTimeoutCb()},r._operationTimeout)}this._operationStart=new Date().getTime();this._fn(this._attempts)};yf.prototype.try=function(e){console.log("Using RetryOperation.try() is deprecated");this.attempt(e)};yf.prototype.start=function(e){console.log("Using RetryOperation.start() is deprecated");this.attempt(e)};yf.prototype.start=yf.prototype.try;yf.prototype.errors=function(){return this._errors};yf.prototype.attempts=function(){return this._attempts};yf.prototype.mainError=function(){if(this._errors.length===0){return null}var e={};var t=null;var r=0;for(var n=0;n<this._errors.length;n++){var i=this._errors[n];var s=i.message;var o=(e[s]||0)+1;e[s]=o;if(o>=r){t=i;r=o}}return t}});var vyt=y(xA=>{var zln=_yt();xA.operation=function(e){var t=xA.timeouts(e);return new zln(t,{forever:e&&(e.forever||e.retries===Infinity),unref:e&&e.unref,maxRetryTime:e&&e.maxRetryTime})};xA.timeouts=function(e){if(e instanceof Array){return[].concat(e)}var t={retries:10,factor:2,minTimeout:1*1e3,maxTimeout:Infinity,randomize:false};for(var r in e){t[r]=e[r]}if(t.minTimeout>t.maxTimeout){throw new Error("minTimeout is greater than maxTimeout")}var n=[];for(var i=0;i<t.retries;i++){n.push(this.createTimeout(i,t))}if(e&&e.forever&&!n.length){n.push(this.createTimeout(i,t))}n.sort(function(s,o){return s-o});return n};xA.createTimeout=function(e,t){var r=t.randomize?Math.random()+1:1;var n=Math.round(r*Math.max(t.minTimeout,1)*Math.pow(t.factor,e));n=Math.min(n,t.maxTimeout);return n};xA.wrap=function(e,t,r){if(t instanceof Array){r=t;t=null}if(!r){r=[];for(var n in e){if(typeof e[n]==="function"){r.push(n)}}}for(var i=0;i<r.length;i++){var s=r[i];var o=e[s];e[s]=a(function u(l){var c=xA.operation(t);var d=Array.prototype.slice.call(arguments,1);var p=d.pop();d.push(function(f){if(c.retry(f)){return}if(f){arguments[0]=c.mainError()}p.apply(this,arguments)});c.attempt(function(){l.apply(e,d)})},"retryWrapper").bind(e,o);e[s].options=t}}});var byt=y((hPs,Eyt)=>{Eyt.exports=vyt()});var sL=y((gPs,Syt)=>{var Kln=byt();function Wln(e,t){function r(n,i){var s=t||{};var o;if(!("randomize"in s)){s.randomize=true}o=Kln.operation(s);function u(d){i(d||new Error("Aborted"))}a(u,"bail");function l(d,p){if(d.bail){u(d);return}if(!o.retry(d)){i(o.mainError())}else if(s.onRetry){s.onRetry(d,p)}}a(l,"onError");function c(d){var p;try{p=e(u,d)}catch(f){l(f,d);return}Promise.resolve(p).then(n).catch(a(function f(m){l(m,d)},"catchIt"))}a(c,"runAttempt");o.attempt(c)}a(r,"run");return new Promise(r)}a(Wln,"retry");Syt.exports=Wln});var vSe=y(eO=>{"use strict";Object.defineProperty(eO,"__esModule",{value:true});eO.AclRoleAccessorMethods=eO.Acl=void 0;var Yln=I0();var RA=class e{static{a(this,"AclRoleAccessorMethods")}constructor(){this.owners={};this.readers={};this.writers={};this.owners={};this.readers={};this.writers={};e.roles.forEach(this._assignAccessMethods.bind(this))}_assignAccessMethods(t){const r=e.accessMethods;const n=e.entities;const i=t.toLowerCase()+"s";this[i]=n.reduce((s,o)=>{const u=o.charAt(o.length-1)==="-";r.forEach(l=>{let c=l+o[0].toUpperCase()+o.substring(1);if(u){c=c.replace("-","")}s[c]=(d,p,f)=>{let m;if(typeof p==="function"){f=p;p={}}if(u){m=o+d}else{m=o;f=d}p=Object.assign({entity:m,role:t},p);const h=[p];if(typeof f==="function"){h.push(f)}return this[l].apply(this,h)}});return s},{})}};eO.AclRoleAccessorMethods=RA;RA.accessMethods=["add","delete"];RA.entities=["allAuthenticatedUsers","allUsers","domain-","group-","project-","user-"];RA.roles=["OWNER","READER","WRITER"];var qW=class extends RA{static{a(this,"Acl")}constructor(t){super();this.pathPrefix=t.pathPrefix;this.request_=t.request}add(t,r){const n={};if(t.generation){n.generation=t.generation}if(t.userProject){n.userProject=t.userProject}this.request({method:"POST",uri:"",qs:n,maxRetries:0,json:{entity:t.entity,role:t.role.toUpperCase()}},(i,s)=>{if(i){r(i,null,s);return}r(null,this.makeAclObject_(s),s)})}delete(t,r){const n={};if(t.generation){n.generation=t.generation}if(t.userProject){n.userProject=t.userProject}this.request({method:"DELETE",uri:"/"+encodeURIComponent(t.entity),qs:n},(i,s)=>{r(i,s)})}get(t,r){const n=typeof t==="object"?t:null;const i=typeof t==="function"?t:r;let s="";const o={};if(n){s="/"+encodeURIComponent(n.entity);if(n.generation){o.generation=n.generation}if(n.userProject){o.userProject=n.userProject}}this.request({uri:s,qs:o},(u,l)=>{if(u){i(u,null,l);return}let c;if(l.items){c=l.items.map(this.makeAclObject_)}else{c=this.makeAclObject_(l)}i(null,c,l)})}update(t,r){const n={};if(t.generation){n.generation=t.generation}if(t.userProject){n.userProject=t.userProject}this.request({method:"PUT",uri:"/"+encodeURIComponent(t.entity),qs:n,json:{role:t.role.toUpperCase()}},(i,s)=>{if(i){r(i,null,s);return}r(null,this.makeAclObject_(s),s)})}makeAclObject_(t){const r={entity:t.entity,role:t.role};if(t.projectTeam){r.projectTeam=t.projectTeam}return r}request(t,r){t.uri=this.pathPrefix+t.uri;this.request_(t,r)}};eO.Acl=qW;(0,Yln.promisifyAll)(qW,{exclude:["request"]})});var Cyt=y((EPs,Ayt)=>{"use strict";var Xln=mSe();var Jln=/^text\/|\+(?:json|text|xml)$/i;var Qln=/^\s*([^;\s]*)(?:;|\s|$)/;Ayt.exports=Zln;function Zln(e){if(!e||typeof e!=="string"){return false}var t=Qln.exec(e);var r=t&&t[1].toLowerCase();var n=Xln[r];if(n&&n.compressible!==void 0){return n.compressible}return Jln.test(r)||void 0}a(Zln,"compressible")});var Tyt=y((SPs,wyt)=>{"use strict";function UW(){this._types=Object.create(null);this._extensions=Object.create(null);for(let e=0;e<arguments.length;e++){this.define(arguments[e])}this.define=this.define.bind(this);this.getType=this.getType.bind(this);this.getExtension=this.getExtension.bind(this)}a(UW,"Mime");UW.prototype.define=function(e,t){for(let r in e){let n=e[r].map(function(i){return i.toLowerCase()});r=r.toLowerCase();for(let i=0;i<n.length;i++){const s=n[i];if(s[0]==="*"){continue}if(!t&&s in this._types){throw new Error('Attempt to change mapping for "'+s+'" extension from "'+this._types[s]+'" to "'+r+'". Pass `force=true` to allow this, otherwise remove "'+s+'" from the list of extensions for "'+r+'".')}this._types[s]=r}if(t||!this._extensions[r]){const i=n[0];this._extensions[r]=i[0]!=="*"?i:i.substr(1)}}};UW.prototype.getType=function(e){e=String(e);let t=e.replace(/^.*[/\\]/,"").toLowerCase();let r=t.replace(/^.*\./,"").toLowerCase();let n=t.length<e.length;let i=r.length<t.length-1;return(i||!n)&&this._types[r]||null};UW.prototype.getExtension=function(e){e=/^\s*([^;\s]*)/.test(e)&&RegExp.$1;return e&&this._extensions[e.toLowerCase()]||null};wyt.exports=UW});var Ryt=y((CPs,xyt)=>{xyt.exports={"application/andrew-inset":["ez"],"application/applixware":["aw"],"application/atom+xml":["atom"],"application/atomcat+xml":["atomcat"],"application/atomdeleted+xml":["atomdeleted"],"application/atomsvc+xml":["atomsvc"],"application/atsc-dwd+xml":["dwd"],"application/atsc-held+xml":["held"],"application/atsc-rsat+xml":["rsat"],"application/bdoc":["bdoc"],"application/calendar+xml":["xcs"],"application/ccxml+xml":["ccxml"],"application/cdfx+xml":["cdfx"],"application/cdmi-capability":["cdmia"],"application/cdmi-container":["cdmic"],"application/cdmi-domain":["cdmid"],"application/cdmi-object":["cdmio"],"application/cdmi-queue":["cdmiq"],"application/cu-seeme":["cu"],"application/dash+xml":["mpd"],"application/davmount+xml":["davmount"],"application/docbook+xml":["dbk"],"application/dssc+der":["dssc"],"application/dssc+xml":["xdssc"],"application/ecmascript":["es","ecma"],"application/emma+xml":["emma"],"application/emotionml+xml":["emotionml"],"application/epub+zip":["epub"],"application/exi":["exi"],"application/express":["exp"],"application/fdt+xml":["fdt"],"application/font-tdpfr":["pfr"],"application/geo+json":["geojson"],"application/gml+xml":["gml"],"application/gpx+xml":["gpx"],"application/gxf":["gxf"],"application/gzip":["gz"],"application/hjson":["hjson"],"application/hyperstudio":["stk"],"application/inkml+xml":["ink","inkml"],"application/ipfix":["ipfix"],"application/its+xml":["its"],"application/java-archive":["jar","war","ear"],"application/java-serialized-object":["ser"],"application/java-vm":["class"],"application/javascript":["js","mjs"],"application/json":["json","map"],"application/json5":["json5"],"application/jsonml+json":["jsonml"],"application/ld+json":["jsonld"],"application/lgr+xml":["lgr"],"application/lost+xml":["lostxml"],"application/mac-binhex40":["hqx"],"application/mac-compactpro":["cpt"],"application/mads+xml":["mads"],"application/manifest+json":["webmanifest"],"application/marc":["mrc"],"application/marcxml+xml":["mrcx"],"application/mathematica":["ma","nb","mb"],"application/mathml+xml":["mathml"],"application/mbox":["mbox"],"application/mediaservercontrol+xml":["mscml"],"application/metalink+xml":["metalink"],"application/metalink4+xml":["meta4"],"application/mets+xml":["mets"],"application/mmt-aei+xml":["maei"],"application/mmt-usd+xml":["musd"],"application/mods+xml":["mods"],"application/mp21":["m21","mp21"],"application/mp4":["mp4s","m4p"],"application/msword":["doc","dot"],"application/mxf":["mxf"],"application/n-quads":["nq"],"application/n-triples":["nt"],"application/node":["cjs"],"application/octet-stream":["bin","dms","lrf","mar","so","dist","distz","pkg","bpk","dump","elc","deploy","exe","dll","deb","dmg","iso","img","msi","msp","msm","buffer"],"application/oda":["oda"],"application/oebps-package+xml":["opf"],"application/ogg":["ogx"],"application/omdoc+xml":["omdoc"],"application/onenote":["onetoc","onetoc2","onetmp","onepkg"],"application/oxps":["oxps"],"application/p2p-overlay+xml":["relo"],"application/patch-ops-error+xml":["xer"],"application/pdf":["pdf"],"application/pgp-encrypted":["pgp"],"application/pgp-signature":["asc","sig"],"application/pics-rules":["prf"],"application/pkcs10":["p10"],"application/pkcs7-mime":["p7m","p7c"],"application/pkcs7-signature":["p7s"],"application/pkcs8":["p8"],"application/pkix-attr-cert":["ac"],"application/pkix-cert":["cer"],"application/pkix-crl":["crl"],"application/pkix-pkipath":["pkipath"],"application/pkixcmp":["pki"],"application/pls+xml":["pls"],"application/postscript":["ai","eps","ps"],"application/provenance+xml":["provx"],"application/pskc+xml":["pskcxml"],"application/raml+yaml":["raml"],"application/rdf+xml":["rdf","owl"],"application/reginfo+xml":["rif"],"application/relax-ng-compact-syntax":["rnc"],"application/resource-lists+xml":["rl"],"application/resource-lists-diff+xml":["rld"],"application/rls-services+xml":["rs"],"application/route-apd+xml":["rapd"],"application/route-s-tsid+xml":["sls"],"application/route-usd+xml":["rusd"],"application/rpki-ghostbusters":["gbr"],"application/rpki-manifest":["mft"],"application/rpki-roa":["roa"],"application/rsd+xml":["rsd"],"application/rss+xml":["rss"],"application/rtf":["rtf"],"application/sbml+xml":["sbml"],"application/scvp-cv-request":["scq"],"application/scvp-cv-response":["scs"],"application/scvp-vp-request":["spq"],"application/scvp-vp-response":["spp"],"application/sdp":["sdp"],"application/senml+xml":["senmlx"],"application/sensml+xml":["sensmlx"],"application/set-payment-initiation":["setpay"],"application/set-registration-initiation":["setreg"],"application/shf+xml":["shf"],"application/sieve":["siv","sieve"],"application/smil+xml":["smi","smil"],"application/sparql-query":["rq"],"application/sparql-results+xml":["srx"],"application/srgs":["gram"],"application/srgs+xml":["grxml"],"application/sru+xml":["sru"],"application/ssdl+xml":["ssdl"],"application/ssml+xml":["ssml"],"application/swid+xml":["swidtag"],"application/tei+xml":["tei","teicorpus"],"application/thraud+xml":["tfi"],"application/timestamped-data":["tsd"],"application/toml":["toml"],"application/trig":["trig"],"application/ttml+xml":["ttml"],"application/ubjson":["ubj"],"application/urc-ressheet+xml":["rsheet"],"application/urc-targetdesc+xml":["td"],"application/voicexml+xml":["vxml"],"application/wasm":["wasm"],"application/widget":["wgt"],"application/winhlp":["hlp"],"application/wsdl+xml":["wsdl"],"application/wspolicy+xml":["wspolicy"],"application/xaml+xml":["xaml"],"application/xcap-att+xml":["xav"],"application/xcap-caps+xml":["xca"],"application/xcap-diff+xml":["xdf"],"application/xcap-el+xml":["xel"],"application/xcap-ns+xml":["xns"],"application/xenc+xml":["xenc"],"application/xhtml+xml":["xhtml","xht"],"application/xliff+xml":["xlf"],"application/xml":["xml","xsl","xsd","rng"],"application/xml-dtd":["dtd"],"application/xop+xml":["xop"],"application/xproc+xml":["xpl"],"application/xslt+xml":["*xsl","xslt"],"application/xspf+xml":["xspf"],"application/xv+xml":["mxml","xhvml","xvml","xvm"],"application/yang":["yang"],"application/yin+xml":["yin"],"application/zip":["zip"],"audio/3gpp":["*3gpp"],"audio/adpcm":["adp"],"audio/amr":["amr"],"audio/basic":["au","snd"],"audio/midi":["mid","midi","kar","rmi"],"audio/mobile-xmf":["mxmf"],"audio/mp3":["*mp3"],"audio/mp4":["m4a","mp4a"],"audio/mpeg":["mpga","mp2","mp2a","mp3","m2a","m3a"],"audio/ogg":["oga","ogg","spx","opus"],"audio/s3m":["s3m"],"audio/silk":["sil"],"audio/wav":["wav"],"audio/wave":["*wav"],"audio/webm":["weba"],"audio/xm":["xm"],"font/collection":["ttc"],"font/otf":["otf"],"font/ttf":["ttf"],"font/woff":["woff"],"font/woff2":["woff2"],"image/aces":["exr"],"image/apng":["apng"],"image/avif":["avif"],"image/bmp":["bmp"],"image/cgm":["cgm"],"image/dicom-rle":["drle"],"image/emf":["emf"],"image/fits":["fits"],"image/g3fax":["g3"],"image/gif":["gif"],"image/heic":["heic"],"image/heic-sequence":["heics"],"image/heif":["heif"],"image/heif-sequence":["heifs"],"image/hej2k":["hej2"],"image/hsj2":["hsj2"],"image/ief":["ief"],"image/jls":["jls"],"image/jp2":["jp2","jpg2"],"image/jpeg":["jpeg","jpg","jpe"],"image/jph":["jph"],"image/jphc":["jhc"],"image/jpm":["jpm"],"image/jpx":["jpx","jpf"],"image/jxr":["jxr"],"image/jxra":["jxra"],"image/jxrs":["jxrs"],"image/jxs":["jxs"],"image/jxsc":["jxsc"],"image/jxsi":["jxsi"],"image/jxss":["jxss"],"image/ktx":["ktx"],"image/ktx2":["ktx2"],"image/png":["png"],"image/sgi":["sgi"],"image/svg+xml":["svg","svgz"],"image/t38":["t38"],"image/tiff":["tif","tiff"],"image/tiff-fx":["tfx"],"image/webp":["webp"],"image/wmf":["wmf"],"message/disposition-notification":["disposition-notification"],"message/global":["u8msg"],"message/global-delivery-status":["u8dsn"],"message/global-disposition-notification":["u8mdn"],"message/global-headers":["u8hdr"],"message/rfc822":["eml","mime"],"model/3mf":["3mf"],"model/gltf+json":["gltf"],"model/gltf-binary":["glb"],"model/iges":["igs","iges"],"model/mesh":["msh","mesh","silo"],"model/mtl":["mtl"],"model/obj":["obj"],"model/step+xml":["stpx"],"model/step+zip":["stpz"],"model/step-xml+zip":["stpxz"],"model/stl":["stl"],"model/vrml":["wrl","vrml"],"model/x3d+binary":["*x3db","x3dbz"],"model/x3d+fastinfoset":["x3db"],"model/x3d+vrml":["*x3dv","x3dvz"],"model/x3d+xml":["x3d","x3dz"],"model/x3d-vrml":["x3dv"],"text/cache-manifest":["appcache","manifest"],"text/calendar":["ics","ifb"],"text/coffeescript":["coffee","litcoffee"],"text/css":["css"],"text/csv":["csv"],"text/html":["html","htm","shtml"],"text/jade":["jade"],"text/jsx":["jsx"],"text/less":["less"],"text/markdown":["markdown","md"],"text/mathml":["mml"],"text/mdx":["mdx"],"text/n3":["n3"],"text/plain":["txt","text","conf","def","list","log","in","ini"],"text/richtext":["rtx"],"text/rtf":["*rtf"],"text/sgml":["sgml","sgm"],"text/shex":["shex"],"text/slim":["slim","slm"],"text/spdx":["spdx"],"text/stylus":["stylus","styl"],"text/tab-separated-values":["tsv"],"text/troff":["t","tr","roff","man","me","ms"],"text/turtle":["ttl"],"text/uri-list":["uri","uris","urls"],"text/vcard":["vcard"],"text/vtt":["vtt"],"text/xml":["*xml"],"text/yaml":["yaml","yml"],"video/3gpp":["3gp","3gpp"],"video/3gpp2":["3g2"],"video/h261":["h261"],"video/h263":["h263"],"video/h264":["h264"],"video/iso.segment":["m4s"],"video/jpeg":["jpgv"],"video/jpm":["*jpm","jpgm"],"video/mj2":["mj2","mjp2"],"video/mp2t":["ts"],"video/mp4":["mp4","mp4v","mpg4"],"video/mpeg":["mpeg","mpg","mpe","m1v","m2v"],"video/ogg":["ogv"],"video/quicktime":["qt","mov"],"video/webm":["webm"]}});var Pyt=y((wPs,Oyt)=>{Oyt.exports={"application/prs.cww":["cww"],"application/vnd.1000minds.decision-model+xml":["1km"],"application/vnd.3gpp.pic-bw-large":["plb"],"application/vnd.3gpp.pic-bw-small":["psb"],"application/vnd.3gpp.pic-bw-var":["pvb"],"application/vnd.3gpp2.tcap":["tcap"],"application/vnd.3m.post-it-notes":["pwn"],"application/vnd.accpac.simply.aso":["aso"],"application/vnd.accpac.simply.imp":["imp"],"application/vnd.acucobol":["acu"],"application/vnd.acucorp":["atc","acutc"],"application/vnd.adobe.air-application-installer-package+zip":["air"],"application/vnd.adobe.formscentral.fcdt":["fcdt"],"application/vnd.adobe.fxp":["fxp","fxpl"],"application/vnd.adobe.xdp+xml":["xdp"],"application/vnd.adobe.xfdf":["xfdf"],"application/vnd.ahead.space":["ahead"],"application/vnd.airzip.filesecure.azf":["azf"],"application/vnd.airzip.filesecure.azs":["azs"],"application/vnd.amazon.ebook":["azw"],"application/vnd.americandynamics.acc":["acc"],"application/vnd.amiga.ami":["ami"],"application/vnd.android.package-archive":["apk"],"application/vnd.anser-web-certificate-issue-initiation":["cii"],"application/vnd.anser-web-funds-transfer-initiation":["fti"],"application/vnd.antix.game-component":["atx"],"application/vnd.apple.installer+xml":["mpkg"],"application/vnd.apple.keynote":["key"],"application/vnd.apple.mpegurl":["m3u8"],"application/vnd.apple.numbers":["numbers"],"application/vnd.apple.pages":["pages"],"application/vnd.apple.pkpass":["pkpass"],"application/vnd.aristanetworks.swi":["swi"],"application/vnd.astraea-software.iota":["iota"],"application/vnd.audiograph":["aep"],"application/vnd.balsamiq.bmml+xml":["bmml"],"application/vnd.blueice.multipass":["mpm"],"application/vnd.bmi":["bmi"],"application/vnd.businessobjects":["rep"],"application/vnd.chemdraw+xml":["cdxml"],"application/vnd.chipnuts.karaoke-mmd":["mmd"],"application/vnd.cinderella":["cdy"],"application/vnd.citationstyles.style+xml":["csl"],"application/vnd.claymore":["cla"],"application/vnd.cloanto.rp9":["rp9"],"application/vnd.clonk.c4group":["c4g","c4d","c4f","c4p","c4u"],"application/vnd.cluetrust.cartomobile-config":["c11amc"],"application/vnd.cluetrust.cartomobile-config-pkg":["c11amz"],"application/vnd.commonspace":["csp"],"application/vnd.contact.cmsg":["cdbcmsg"],"application/vnd.cosmocaller":["cmc"],"application/vnd.crick.clicker":["clkx"],"application/vnd.crick.clicker.keyboard":["clkk"],"application/vnd.crick.clicker.palette":["clkp"],"application/vnd.crick.clicker.template":["clkt"],"application/vnd.crick.clicker.wordbank":["clkw"],"application/vnd.criticaltools.wbs+xml":["wbs"],"application/vnd.ctc-posml":["pml"],"application/vnd.cups-ppd":["ppd"],"application/vnd.curl.car":["car"],"application/vnd.curl.pcurl":["pcurl"],"application/vnd.dart":["dart"],"application/vnd.data-vision.rdz":["rdz"],"application/vnd.dbf":["dbf"],"application/vnd.dece.data":["uvf","uvvf","uvd","uvvd"],"application/vnd.dece.ttml+xml":["uvt","uvvt"],"application/vnd.dece.unspecified":["uvx","uvvx"],"application/vnd.dece.zip":["uvz","uvvz"],"application/vnd.denovo.fcselayout-link":["fe_launch"],"application/vnd.dna":["dna"],"application/vnd.dolby.mlp":["mlp"],"application/vnd.dpgraph":["dpg"],"application/vnd.dreamfactory":["dfac"],"application/vnd.ds-keypoint":["kpxx"],"application/vnd.dvb.ait":["ait"],"application/vnd.dvb.service":["svc"],"application/vnd.dynageo":["geo"],"application/vnd.ecowin.chart":["mag"],"application/vnd.enliven":["nml"],"application/vnd.epson.esf":["esf"],"application/vnd.epson.msf":["msf"],"application/vnd.epson.quickanime":["qam"],"application/vnd.epson.salt":["slt"],"application/vnd.epson.ssf":["ssf"],"application/vnd.eszigno3+xml":["es3","et3"],"application/vnd.ezpix-album":["ez2"],"application/vnd.ezpix-package":["ez3"],"application/vnd.fdf":["fdf"],"application/vnd.fdsn.mseed":["mseed"],"application/vnd.fdsn.seed":["seed","dataless"],"application/vnd.flographit":["gph"],"application/vnd.fluxtime.clip":["ftc"],"application/vnd.framemaker":["fm","frame","maker","book"],"application/vnd.frogans.fnc":["fnc"],"application/vnd.frogans.ltf":["ltf"],"application/vnd.fsc.weblaunch":["fsc"],"application/vnd.fujitsu.oasys":["oas"],"application/vnd.fujitsu.oasys2":["oa2"],"application/vnd.fujitsu.oasys3":["oa3"],"application/vnd.fujitsu.oasysgp":["fg5"],"application/vnd.fujitsu.oasysprs":["bh2"],"application/vnd.fujixerox.ddd":["ddd"],"application/vnd.fujixerox.docuworks":["xdw"],"application/vnd.fujixerox.docuworks.binder":["xbd"],"application/vnd.fuzzysheet":["fzs"],"application/vnd.genomatix.tuxedo":["txd"],"application/vnd.geogebra.file":["ggb"],"application/vnd.geogebra.tool":["ggt"],"application/vnd.geometry-explorer":["gex","gre"],"application/vnd.geonext":["gxt"],"application/vnd.geoplan":["g2w"],"application/vnd.geospace":["g3w"],"application/vnd.gmx":["gmx"],"application/vnd.google-apps.document":["gdoc"],"application/vnd.google-apps.presentation":["gslides"],"application/vnd.google-apps.spreadsheet":["gsheet"],"application/vnd.google-earth.kml+xml":["kml"],"application/vnd.google-earth.kmz":["kmz"],"application/vnd.grafeq":["gqf","gqs"],"application/vnd.groove-account":["gac"],"application/vnd.groove-help":["ghf"],"application/vnd.groove-identity-message":["gim"],"application/vnd.groove-injector":["grv"],"application/vnd.groove-tool-message":["gtm"],"application/vnd.groove-tool-template":["tpl"],"application/vnd.groove-vcard":["vcg"],"application/vnd.hal+xml":["hal"],"application/vnd.handheld-entertainment+xml":["zmm"],"application/vnd.hbci":["hbci"],"application/vnd.hhe.lesson-player":["les"],"application/vnd.hp-hpgl":["hpgl"],"application/vnd.hp-hpid":["hpid"],"application/vnd.hp-hps":["hps"],"application/vnd.hp-jlyt":["jlt"],"application/vnd.hp-pcl":["pcl"],"application/vnd.hp-pclxl":["pclxl"],"application/vnd.hydrostatix.sof-data":["sfd-hdstx"],"application/vnd.ibm.minipay":["mpy"],"application/vnd.ibm.modcap":["afp","listafp","list3820"],"application/vnd.ibm.rights-management":["irm"],"application/vnd.ibm.secure-container":["sc"],"application/vnd.iccprofile":["icc","icm"],"application/vnd.igloader":["igl"],"application/vnd.immervision-ivp":["ivp"],"application/vnd.immervision-ivu":["ivu"],"application/vnd.insors.igm":["igm"],"application/vnd.intercon.formnet":["xpw","xpx"],"application/vnd.intergeo":["i2g"],"application/vnd.intu.qbo":["qbo"],"application/vnd.intu.qfx":["qfx"],"application/vnd.ipunplugged.rcprofile":["rcprofile"],"application/vnd.irepository.package+xml":["irp"],"application/vnd.is-xpr":["xpr"],"application/vnd.isac.fcs":["fcs"],"application/vnd.jam":["jam"],"application/vnd.jcp.javame.midlet-rms":["rms"],"application/vnd.jisp":["jisp"],"application/vnd.joost.joda-archive":["joda"],"application/vnd.kahootz":["ktz","ktr"],"application/vnd.kde.karbon":["karbon"],"application/vnd.kde.kchart":["chrt"],"application/vnd.kde.kformula":["kfo"],"application/vnd.kde.kivio":["flw"],"application/vnd.kde.kontour":["kon"],"application/vnd.kde.kpresenter":["kpr","kpt"],"application/vnd.kde.kspread":["ksp"],"application/vnd.kde.kword":["kwd","kwt"],"application/vnd.kenameaapp":["htke"],"application/vnd.kidspiration":["kia"],"application/vnd.kinar":["kne","knp"],"application/vnd.koan":["skp","skd","skt","skm"],"application/vnd.kodak-descriptor":["sse"],"application/vnd.las.las+xml":["lasxml"],"application/vnd.llamagraphics.life-balance.desktop":["lbd"],"application/vnd.llamagraphics.life-balance.exchange+xml":["lbe"],"application/vnd.lotus-1-2-3":["123"],"application/vnd.lotus-approach":["apr"],"application/vnd.lotus-freelance":["pre"],"application/vnd.lotus-notes":["nsf"],"application/vnd.lotus-organizer":["org"],"application/vnd.lotus-screencam":["scm"],"application/vnd.lotus-wordpro":["lwp"],"application/vnd.macports.portpkg":["portpkg"],"application/vnd.mapbox-vector-tile":["mvt"],"application/vnd.mcd":["mcd"],"application/vnd.medcalcdata":["mc1"],"application/vnd.mediastation.cdkey":["cdkey"],"application/vnd.mfer":["mwf"],"application/vnd.mfmp":["mfm"],"application/vnd.micrografx.flo":["flo"],"application/vnd.micrografx.igx":["igx"],"application/vnd.mif":["mif"],"application/vnd.mobius.daf":["daf"],"application/vnd.mobius.dis":["dis"],"application/vnd.mobius.mbk":["mbk"],"application/vnd.mobius.mqy":["mqy"],"application/vnd.mobius.msl":["msl"],"application/vnd.mobius.plc":["plc"],"application/vnd.mobius.txf":["txf"],"application/vnd.mophun.application":["mpn"],"application/vnd.mophun.certificate":["mpc"],"application/vnd.mozilla.xul+xml":["xul"],"application/vnd.ms-artgalry":["cil"],"application/vnd.ms-cab-compressed":["cab"],"application/vnd.ms-excel":["xls","xlm","xla","xlc","xlt","xlw"],"application/vnd.ms-excel.addin.macroenabled.12":["xlam"],"application/vnd.ms-excel.sheet.binary.macroenabled.12":["xlsb"],"application/vnd.ms-excel.sheet.macroenabled.12":["xlsm"],"application/vnd.ms-excel.template.macroenabled.12":["xltm"],"application/vnd.ms-fontobject":["eot"],"application/vnd.ms-htmlhelp":["chm"],"application/vnd.ms-ims":["ims"],"application/vnd.ms-lrm":["lrm"],"application/vnd.ms-officetheme":["thmx"],"application/vnd.ms-outlook":["msg"],"application/vnd.ms-pki.seccat":["cat"],"application/vnd.ms-pki.stl":["*stl"],"application/vnd.ms-powerpoint":["ppt","pps","pot"],"application/vnd.ms-powerpoint.addin.macroenabled.12":["ppam"],"application/vnd.ms-powerpoint.presentation.macroenabled.12":["pptm"],"application/vnd.ms-powerpoint.slide.macroenabled.12":["sldm"],"application/vnd.ms-powerpoint.slideshow.macroenabled.12":["ppsm"],"application/vnd.ms-powerpoint.template.macroenabled.12":["potm"],"application/vnd.ms-project":["mpp","mpt"],"application/vnd.ms-word.document.macroenabled.12":["docm"],"application/vnd.ms-word.template.macroenabled.12":["dotm"],"application/vnd.ms-works":["wps","wks","wcm","wdb"],"application/vnd.ms-wpl":["wpl"],"application/vnd.ms-xpsdocument":["xps"],"application/vnd.mseq":["mseq"],"application/vnd.musician":["mus"],"application/vnd.muvee.style":["msty"],"application/vnd.mynfc":["taglet"],"application/vnd.neurolanguage.nlu":["nlu"],"application/vnd.nitf":["ntf","nitf"],"application/vnd.noblenet-directory":["nnd"],"application/vnd.noblenet-sealer":["nns"],"application/vnd.noblenet-web":["nnw"],"application/vnd.nokia.n-gage.ac+xml":["*ac"],"application/vnd.nokia.n-gage.data":["ngdat"],"application/vnd.nokia.n-gage.symbian.install":["n-gage"],"application/vnd.nokia.radio-preset":["rpst"],"application/vnd.nokia.radio-presets":["rpss"],"application/vnd.novadigm.edm":["edm"],"application/vnd.novadigm.edx":["edx"],"application/vnd.novadigm.ext":["ext"],"application/vnd.oasis.opendocument.chart":["odc"],"application/vnd.oasis.opendocument.chart-template":["otc"],"application/vnd.oasis.opendocument.database":["odb"],"application/vnd.oasis.opendocument.formula":["odf"],"application/vnd.oasis.opendocument.formula-template":["odft"],"application/vnd.oasis.opendocument.graphics":["odg"],"application/vnd.oasis.opendocument.graphics-template":["otg"],"application/vnd.oasis.opendocument.image":["odi"],"application/vnd.oasis.opendocument.image-template":["oti"],"application/vnd.oasis.opendocument.presentation":["odp"],"application/vnd.oasis.opendocument.presentation-template":["otp"],"application/vnd.oasis.opendocument.spreadsheet":["ods"],"application/vnd.oasis.opendocument.spreadsheet-template":["ots"],"application/vnd.oasis.opendocument.text":["odt"],"application/vnd.oasis.opendocument.text-master":["odm"],"application/vnd.oasis.opendocument.text-template":["ott"],"application/vnd.oasis.opendocument.text-web":["oth"],"application/vnd.olpc-sugar":["xo"],"application/vnd.oma.dd2+xml":["dd2"],"application/vnd.openblox.game+xml":["obgx"],"application/vnd.openofficeorg.extension":["oxt"],"application/vnd.openstreetmap.data+xml":["osm"],"application/vnd.openxmlformats-officedocument.presentationml.presentation":["pptx"],"application/vnd.openxmlformats-officedocument.presentationml.slide":["sldx"],"application/vnd.openxmlformats-officedocument.presentationml.slideshow":["ppsx"],"application/vnd.openxmlformats-officedocument.presentationml.template":["potx"],"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":["xlsx"],"application/vnd.openxmlformats-officedocument.spreadsheetml.template":["xltx"],"application/vnd.openxmlformats-officedocument.wordprocessingml.document":["docx"],"application/vnd.openxmlformats-officedocument.wordprocessingml.template":["dotx"],"application/vnd.osgeo.mapguide.package":["mgp"],"application/vnd.osgi.dp":["dp"],"application/vnd.osgi.subsystem":["esa"],"application/vnd.palm":["pdb","pqa","oprc"],"application/vnd.pawaafile":["paw"],"application/vnd.pg.format":["str"],"application/vnd.pg.osasli":["ei6"],"application/vnd.picsel":["efif"],"application/vnd.pmi.widget":["wg"],"application/vnd.pocketlearn":["plf"],"application/vnd.powerbuilder6":["pbd"],"application/vnd.previewsystems.box":["box"],"application/vnd.proteus.magazine":["mgz"],"application/vnd.publishare-delta-tree":["qps"],"application/vnd.pvi.ptid1":["ptid"],"application/vnd.quark.quarkxpress":["qxd","qxt","qwd","qwt","qxl","qxb"],"application/vnd.rar":["rar"],"application/vnd.realvnc.bed":["bed"],"application/vnd.recordare.musicxml":["mxl"],"application/vnd.recordare.musicxml+xml":["musicxml"],"application/vnd.rig.cryptonote":["cryptonote"],"application/vnd.rim.cod":["cod"],"application/vnd.rn-realmedia":["rm"],"application/vnd.rn-realmedia-vbr":["rmvb"],"application/vnd.route66.link66+xml":["link66"],"application/vnd.sailingtracker.track":["st"],"application/vnd.seemail":["see"],"application/vnd.sema":["sema"],"application/vnd.semd":["semd"],"application/vnd.semf":["semf"],"application/vnd.shana.informed.formdata":["ifm"],"application/vnd.shana.informed.formtemplate":["itp"],"application/vnd.shana.informed.interchange":["iif"],"application/vnd.shana.informed.package":["ipk"],"application/vnd.simtech-mindmapper":["twd","twds"],"application/vnd.smaf":["mmf"],"application/vnd.smart.teacher":["teacher"],"application/vnd.software602.filler.form+xml":["fo"],"application/vnd.solent.sdkm+xml":["sdkm","sdkd"],"application/vnd.spotfire.dxp":["dxp"],"application/vnd.spotfire.sfs":["sfs"],"application/vnd.stardivision.calc":["sdc"],"application/vnd.stardivision.draw":["sda"],"application/vnd.stardivision.impress":["sdd"],"application/vnd.stardivision.math":["smf"],"application/vnd.stardivision.writer":["sdw","vor"],"application/vnd.stardivision.writer-global":["sgl"],"application/vnd.stepmania.package":["smzip"],"application/vnd.stepmania.stepchart":["sm"],"application/vnd.sun.wadl+xml":["wadl"],"application/vnd.sun.xml.calc":["sxc"],"application/vnd.sun.xml.calc.template":["stc"],"application/vnd.sun.xml.draw":["sxd"],"application/vnd.sun.xml.draw.template":["std"],"application/vnd.sun.xml.impress":["sxi"],"application/vnd.sun.xml.impress.template":["sti"],"application/vnd.sun.xml.math":["sxm"],"application/vnd.sun.xml.writer":["sxw"],"application/vnd.sun.xml.writer.global":["sxg"],"application/vnd.sun.xml.writer.template":["stw"],"application/vnd.sus-calendar":["sus","susp"],"application/vnd.svd":["svd"],"application/vnd.symbian.install":["sis","sisx"],"application/vnd.syncml+xml":["xsm"],"application/vnd.syncml.dm+wbxml":["bdm"],"application/vnd.syncml.dm+xml":["xdm"],"application/vnd.syncml.dmddf+xml":["ddf"],"application/vnd.tao.intent-module-archive":["tao"],"application/vnd.tcpdump.pcap":["pcap","cap","dmp"],"application/vnd.tmobile-livetv":["tmo"],"application/vnd.trid.tpt":["tpt"],"application/vnd.triscape.mxs":["mxs"],"application/vnd.trueapp":["tra"],"application/vnd.ufdl":["ufd","ufdl"],"application/vnd.uiq.theme":["utz"],"application/vnd.umajin":["umj"],"application/vnd.unity":["unityweb"],"application/vnd.uoml+xml":["uoml"],"application/vnd.vcx":["vcx"],"application/vnd.visio":["vsd","vst","vss","vsw"],"application/vnd.visionary":["vis"],"application/vnd.vsf":["vsf"],"application/vnd.wap.wbxml":["wbxml"],"application/vnd.wap.wmlc":["wmlc"],"application/vnd.wap.wmlscriptc":["wmlsc"],"application/vnd.webturbo":["wtb"],"application/vnd.wolfram.player":["nbp"],"application/vnd.wordperfect":["wpd"],"application/vnd.wqd":["wqd"],"application/vnd.wt.stf":["stf"],"application/vnd.xara":["xar"],"application/vnd.xfdl":["xfdl"],"application/vnd.yamaha.hv-dic":["hvd"],"application/vnd.yamaha.hv-script":["hvs"],"application/vnd.yamaha.hv-voice":["hvp"],"application/vnd.yamaha.openscoreformat":["osf"],"application/vnd.yamaha.openscoreformat.osfpvg+xml":["osfpvg"],"application/vnd.yamaha.smaf-audio":["saf"],"application/vnd.yamaha.smaf-phrase":["spf"],"application/vnd.yellowriver-custom-menu":["cmp"],"application/vnd.zul":["zir","zirz"],"application/vnd.zzazz.deck+xml":["zaz"],"application/x-7z-compressed":["7z"],"application/x-abiword":["abw"],"application/x-ace-compressed":["ace"],"application/x-apple-diskimage":["*dmg"],"application/x-arj":["arj"],"application/x-authorware-bin":["aab","x32","u32","vox"],"application/x-authorware-map":["aam"],"application/x-authorware-seg":["aas"],"application/x-bcpio":["bcpio"],"application/x-bdoc":["*bdoc"],"application/x-bittorrent":["torrent"],"application/x-blorb":["blb","blorb"],"application/x-bzip":["bz"],"application/x-bzip2":["bz2","boz"],"application/x-cbr":["cbr","cba","cbt","cbz","cb7"],"application/x-cdlink":["vcd"],"application/x-cfs-compressed":["cfs"],"application/x-chat":["chat"],"application/x-chess-pgn":["pgn"],"application/x-chrome-extension":["crx"],"application/x-cocoa":["cco"],"application/x-conference":["nsc"],"application/x-cpio":["cpio"],"application/x-csh":["csh"],"application/x-debian-package":["*deb","udeb"],"application/x-dgc-compressed":["dgc"],"application/x-director":["dir","dcr","dxr","cst","cct","cxt","w3d","fgd","swa"],"application/x-doom":["wad"],"application/x-dtbncx+xml":["ncx"],"application/x-dtbook+xml":["dtb"],"application/x-dtbresource+xml":["res"],"application/x-dvi":["dvi"],"application/x-envoy":["evy"],"application/x-eva":["eva"],"application/x-font-bdf":["bdf"],"application/x-font-ghostscript":["gsf"],"application/x-font-linux-psf":["psf"],"application/x-font-pcf":["pcf"],"application/x-font-snf":["snf"],"application/x-font-type1":["pfa","pfb","pfm","afm"],"application/x-freearc":["arc"],"application/x-futuresplash":["spl"],"application/x-gca-compressed":["gca"],"application/x-glulx":["ulx"],"application/x-gnumeric":["gnumeric"],"application/x-gramps-xml":["gramps"],"application/x-gtar":["gtar"],"application/x-hdf":["hdf"],"application/x-httpd-php":["php"],"application/x-install-instructions":["install"],"application/x-iso9660-image":["*iso"],"application/x-iwork-keynote-sffkey":["*key"],"application/x-iwork-numbers-sffnumbers":["*numbers"],"application/x-iwork-pages-sffpages":["*pages"],"application/x-java-archive-diff":["jardiff"],"application/x-java-jnlp-file":["jnlp"],"application/x-keepass2":["kdbx"],"application/x-latex":["latex"],"application/x-lua-bytecode":["luac"],"application/x-lzh-compressed":["lzh","lha"],"application/x-makeself":["run"],"application/x-mie":["mie"],"application/x-mobipocket-ebook":["prc","mobi"],"application/x-ms-application":["application"],"application/x-ms-shortcut":["lnk"],"application/x-ms-wmd":["wmd"],"application/x-ms-wmz":["wmz"],"application/x-ms-xbap":["xbap"],"application/x-msaccess":["mdb"],"application/x-msbinder":["obd"],"application/x-mscardfile":["crd"],"application/x-msclip":["clp"],"application/x-msdos-program":["*exe"],"application/x-msdownload":["*exe","*dll","com","bat","*msi"],"application/x-msmediaview":["mvb","m13","m14"],"application/x-msmetafile":["*wmf","*wmz","*emf","emz"],"application/x-msmoney":["mny"],"application/x-mspublisher":["pub"],"application/x-msschedule":["scd"],"application/x-msterminal":["trm"],"application/x-mswrite":["wri"],"application/x-netcdf":["nc","cdf"],"application/x-ns-proxy-autoconfig":["pac"],"application/x-nzb":["nzb"],"application/x-perl":["pl","pm"],"application/x-pilot":["*prc","*pdb"],"application/x-pkcs12":["p12","pfx"],"application/x-pkcs7-certificates":["p7b","spc"],"application/x-pkcs7-certreqresp":["p7r"],"application/x-rar-compressed":["*rar"],"application/x-redhat-package-manager":["rpm"],"application/x-research-info-systems":["ris"],"application/x-sea":["sea"],"application/x-sh":["sh"],"application/x-shar":["shar"],"application/x-shockwave-flash":["swf"],"application/x-silverlight-app":["xap"],"application/x-sql":["sql"],"application/x-stuffit":["sit"],"application/x-stuffitx":["sitx"],"application/x-subrip":["srt"],"application/x-sv4cpio":["sv4cpio"],"application/x-sv4crc":["sv4crc"],"application/x-t3vm-image":["t3"],"application/x-tads":["gam"],"application/x-tar":["tar"],"application/x-tcl":["tcl","tk"],"application/x-tex":["tex"],"application/x-tex-tfm":["tfm"],"application/x-texinfo":["texinfo","texi"],"application/x-tgif":["*obj"],"application/x-ustar":["ustar"],"application/x-virtualbox-hdd":["hdd"],"application/x-virtualbox-ova":["ova"],"application/x-virtualbox-ovf":["ovf"],"application/x-virtualbox-vbox":["vbox"],"application/x-virtualbox-vbox-extpack":["vbox-extpack"],"application/x-virtualbox-vdi":["vdi"],"application/x-virtualbox-vhd":["vhd"],"application/x-virtualbox-vmdk":["vmdk"],"application/x-wais-source":["src"],"application/x-web-app-manifest+json":["webapp"],"application/x-x509-ca-cert":["der","crt","pem"],"application/x-xfig":["fig"],"application/x-xliff+xml":["*xlf"],"application/x-xpinstall":["xpi"],"application/x-xz":["xz"],"application/x-zmachine":["z1","z2","z3","z4","z5","z6","z7","z8"],"audio/vnd.dece.audio":["uva","uvva"],"audio/vnd.digital-winds":["eol"],"audio/vnd.dra":["dra"],"audio/vnd.dts":["dts"],"audio/vnd.dts.hd":["dtshd"],"audio/vnd.lucent.voice":["lvp"],"audio/vnd.ms-playready.media.pya":["pya"],"audio/vnd.nuera.ecelp4800":["ecelp4800"],"audio/vnd.nuera.ecelp7470":["ecelp7470"],"audio/vnd.nuera.ecelp9600":["ecelp9600"],"audio/vnd.rip":["rip"],"audio/x-aac":["aac"],"audio/x-aiff":["aif","aiff","aifc"],"audio/x-caf":["caf"],"audio/x-flac":["flac"],"audio/x-m4a":["*m4a"],"audio/x-matroska":["mka"],"audio/x-mpegurl":["m3u"],"audio/x-ms-wax":["wax"],"audio/x-ms-wma":["wma"],"audio/x-pn-realaudio":["ram","ra"],"audio/x-pn-realaudio-plugin":["rmp"],"audio/x-realaudio":["*ra"],"audio/x-wav":["*wav"],"chemical/x-cdx":["cdx"],"chemical/x-cif":["cif"],"chemical/x-cmdf":["cmdf"],"chemical/x-cml":["cml"],"chemical/x-csml":["csml"],"chemical/x-xyz":["xyz"],"image/prs.btif":["btif"],"image/prs.pti":["pti"],"image/vnd.adobe.photoshop":["psd"],"image/vnd.airzip.accelerator.azv":["azv"],"image/vnd.dece.graphic":["uvi","uvvi","uvg","uvvg"],"image/vnd.djvu":["djvu","djv"],"image/vnd.dvb.subtitle":["*sub"],"image/vnd.dwg":["dwg"],"image/vnd.dxf":["dxf"],"image/vnd.fastbidsheet":["fbs"],"image/vnd.fpx":["fpx"],"image/vnd.fst":["fst"],"image/vnd.fujixerox.edmics-mmr":["mmr"],"image/vnd.fujixerox.edmics-rlc":["rlc"],"image/vnd.microsoft.icon":["ico"],"image/vnd.ms-dds":["dds"],"image/vnd.ms-modi":["mdi"],"image/vnd.ms-photo":["wdp"],"image/vnd.net-fpx":["npx"],"image/vnd.pco.b16":["b16"],"image/vnd.tencent.tap":["tap"],"image/vnd.valve.source.texture":["vtf"],"image/vnd.wap.wbmp":["wbmp"],"image/vnd.xiff":["xif"],"image/vnd.zbrush.pcx":["pcx"],"image/x-3ds":["3ds"],"image/x-cmu-raster":["ras"],"image/x-cmx":["cmx"],"image/x-freehand":["fh","fhc","fh4","fh5","fh7"],"image/x-icon":["*ico"],"image/x-jng":["jng"],"image/x-mrsid-image":["sid"],"image/x-ms-bmp":["*bmp"],"image/x-pcx":["*pcx"],"image/x-pict":["pic","pct"],"image/x-portable-anymap":["pnm"],"image/x-portable-bitmap":["pbm"],"image/x-portable-graymap":["pgm"],"image/x-portable-pixmap":["ppm"],"image/x-rgb":["rgb"],"image/x-tga":["tga"],"image/x-xbitmap":["xbm"],"image/x-xpixmap":["xpm"],"image/x-xwindowdump":["xwd"],"message/vnd.wfa.wsc":["wsc"],"model/vnd.collada+xml":["dae"],"model/vnd.dwf":["dwf"],"model/vnd.gdl":["gdl"],"model/vnd.gtw":["gtw"],"model/vnd.mts":["mts"],"model/vnd.opengex":["ogex"],"model/vnd.parasolid.transmit.binary":["x_b"],"model/vnd.parasolid.transmit.text":["x_t"],"model/vnd.sap.vds":["vds"],"model/vnd.usdz+zip":["usdz"],"model/vnd.valve.source.compiled-map":["bsp"],"model/vnd.vtu":["vtu"],"text/prs.lines.tag":["dsc"],"text/vnd.curl":["curl"],"text/vnd.curl.dcurl":["dcurl"],"text/vnd.curl.mcurl":["mcurl"],"text/vnd.curl.scurl":["scurl"],"text/vnd.dvb.subtitle":["sub"],"text/vnd.fly":["fly"],"text/vnd.fmi.flexstor":["flx"],"text/vnd.graphviz":["gv"],"text/vnd.in3d.3dml":["3dml"],"text/vnd.in3d.spot":["spot"],"text/vnd.sun.j2me.app-descriptor":["jad"],"text/vnd.wap.wml":["wml"],"text/vnd.wap.wmlscript":["wmls"],"text/x-asm":["s","asm"],"text/x-c":["c","cc","cxx","cpp","h","hh","dic"],"text/x-component":["htc"],"text/x-fortran":["f","for","f77","f90"],"text/x-handlebars-template":["hbs"],"text/x-java-source":["java"],"text/x-lua":["lua"],"text/x-markdown":["mkd"],"text/x-nfo":["nfo"],"text/x-opml":["opml"],"text/x-org":["*org"],"text/x-pascal":["p","pas"],"text/x-processing":["pde"],"text/x-sass":["sass"],"text/x-scss":["scss"],"text/x-setext":["etx"],"text/x-sfv":["sfv"],"text/x-suse-ymp":["ymp"],"text/x-uuencode":["uu"],"text/x-vcalendar":["vcs"],"text/x-vcard":["vcf"],"video/vnd.dece.hd":["uvh","uvvh"],"video/vnd.dece.mobile":["uvm","uvvm"],"video/vnd.dece.pd":["uvp","uvvp"],"video/vnd.dece.sd":["uvs","uvvs"],"video/vnd.dece.video":["uvv","uvvv"],"video/vnd.dvb.file":["dvb"],"video/vnd.fvt":["fvt"],"video/vnd.mpegurl":["mxu","m4u"],"video/vnd.ms-playready.media.pyv":["pyv"],"video/vnd.uvvu.mp4":["uvu","uvvu"],"video/vnd.vivo":["viv"],"video/x-f4v":["f4v"],"video/x-fli":["fli"],"video/x-flv":["flv"],"video/x-m4v":["m4v"],"video/x-matroska":["mkv","mk3d","mks"],"video/x-mng":["mng"],"video/x-ms-asf":["asf","asx"],"video/x-ms-vob":["vob"],"video/x-ms-wm":["wm"],"video/x-ms-wmv":["wmv"],"video/x-ms-wmx":["wmx"],"video/x-ms-wvx":["wvx"],"video/x-msvideo":["avi"],"video/x-sgi-movie":["movie"],"video/x-smv":["smv"],"x-conference/x-cooltalk":["ice"]}});var Iyt=y((TPs,Nyt)=>{"use strict";var ecn=Tyt();Nyt.exports=new ecn(Ryt(),Pyt())});var jyt=y((uL,oL)=>{"use strict";Object.defineProperty(uL,"__esModule",{value:true});var Myt=new WeakMap;var ESe=new WeakMap;function ya(e){const t=Myt.get(e);console.assert(t!=null,"'this' is expected an Event object, but got",e);return t}a(ya,"pd");function kyt(e){if(e.passiveListener!=null){if(typeof console!=="undefined"&&typeof console.error==="function"){console.error("Unable to preventDefault inside passive event listener invocation.",e.passiveListener)}return}if(!e.event.cancelable){return}e.canceled=true;if(typeof e.event.preventDefault==="function"){e.event.preventDefault()}}a(kyt,"setCancelFlag");function tO(e,t){Myt.set(this,{eventTarget:e,event:t,eventPhase:2,currentTarget:e,canceled:false,stopped:false,immediateStopped:false,passiveListener:null,timeStamp:t.timeStamp||Date.now()});Object.defineProperty(this,"isTrusted",{value:false,enumerable:true});const r=Object.keys(t);for(let n=0;n<r.length;++n){const i=r[n];if(!(i in this)){Object.defineProperty(this,i,qyt(i))}}}a(tO,"Event");tO.prototype={get type(){return ya(this).event.type},get target(){return ya(this).eventTarget},get currentTarget(){return ya(this).currentTarget},composedPath(){const e=ya(this).currentTarget;if(e==null){return[]}return[e]},get NONE(){return 0},get CAPTURING_PHASE(){return 1},get AT_TARGET(){return 2},get BUBBLING_PHASE(){return 3},get eventPhase(){return ya(this).eventPhase},stopPropagation(){const e=ya(this);e.stopped=true;if(typeof e.event.stopPropagation==="function"){e.event.stopPropagation()}},stopImmediatePropagation(){const e=ya(this);e.stopped=true;e.immediateStopped=true;if(typeof e.event.stopImmediatePropagation==="function"){e.event.stopImmediatePropagation()}},get bubbles(){return Boolean(ya(this).event.bubbles)},get cancelable(){return Boolean(ya(this).event.cancelable)},preventDefault(){kyt(ya(this))},get defaultPrevented(){return ya(this).canceled},get composed(){return Boolean(ya(this).event.composed)},get timeStamp(){return ya(this).timeStamp},get srcElement(){return ya(this).eventTarget},get cancelBubble(){return ya(this).stopped},set cancelBubble(e){if(!e){return}const t=ya(this);t.stopped=true;if(typeof t.event.cancelBubble==="boolean"){t.event.cancelBubble=true}},get returnValue(){return!ya(this).canceled},set returnValue(e){if(!e){kyt(ya(this))}},initEvent(){}};Object.defineProperty(tO.prototype,"constructor",{value:tO,configurable:true,writable:true});if(typeof window!=="undefined"&&typeof window.Event!=="undefined"){Object.setPrototypeOf(tO.prototype,window.Event.prototype);ESe.set(window.Event.prototype,tO)}function qyt(e){return{get(){return ya(this).event[e]},set(t){ya(this).event[e]=t},configurable:true,enumerable:true}}a(qyt,"defineRedirectDescriptor");function tcn(e){return{value(){const t=ya(this).event;return t[e].apply(t,arguments)},configurable:true,enumerable:true}}a(tcn,"defineCallDescriptor");function rcn(e,t){const r=Object.keys(t);if(r.length===0){return e}function n(i,s){e.call(this,i,s)}a(n,"CustomEvent");n.prototype=Object.create(e.prototype,{constructor:{value:n,configurable:true,writable:true}});for(let i=0;i<r.length;++i){const s=r[i];if(!(s in e.prototype)){const o=Object.getOwnPropertyDescriptor(t,s);const u=typeof o.value==="function";Object.defineProperty(n.prototype,s,u?tcn(s):qyt(s))}}return n}a(rcn,"defineWrapper");function Uyt(e){if(e==null||e===Object.prototype){return tO}let t=ESe.get(e);if(t==null){t=rcn(Uyt(Object.getPrototypeOf(e)),e);ESe.set(e,t)}return t}a(Uyt,"getWrapper");function ncn(e,t){const r=Uyt(Object.getPrototypeOf(t));return new r(e,t)}a(ncn,"wrapEvent");function icn(e){return ya(e).immediateStopped}a(icn,"isStopped");function scn(e,t){ya(e).eventPhase=t}a(scn,"setEventPhase");function acn(e,t){ya(e).currentTarget=t}a(acn,"setCurrentTarget");function Dyt(e,t){ya(e).passiveListener=t}a(Dyt,"setPassiveListener");var $yt=new WeakMap;var Lyt=1;var Fyt=2;var $W=3;function jW(e){return e!==null&&typeof e==="object"}a(jW,"isObject");function aL(e){const t=$yt.get(e);if(t==null){throw new TypeError("'this' is expected an EventTarget object, but got another value.")}return t}a(aL,"getListeners");function ocn(e){return{get(){const t=aL(this);let r=t.get(e);while(r!=null){if(r.listenerType===$W){return r.listener}r=r.next}return null},set(t){if(typeof t!=="function"&&!jW(t)){t=null}const r=aL(this);let n=null;let i=r.get(e);while(i!=null){if(i.listenerType===$W){if(n!==null){n.next=i.next}else if(i.next!==null){r.set(e,i.next)}else{r.delete(e)}}else{n=i}i=i.next}if(t!==null){const s={listener:t,listenerType:$W,passive:false,once:false,next:null};if(n===null){r.set(e,s)}else{n.next=s}}},configurable:true,enumerable:true}}a(ocn,"defineEventAttributeDescriptor");function bSe(e,t){Object.defineProperty(e,`on${t}`,ocn(t))}a(bSe,"defineEventAttribute");function Byt(e){function t(){rh.call(this)}a(t,"CustomEventTarget");t.prototype=Object.create(rh.prototype,{constructor:{value:t,configurable:true,writable:true}});for(let r=0;r<e.length;++r){bSe(t.prototype,e[r])}return t}a(Byt,"defineCustomEventTarget");function rh(){if(this instanceof rh){$yt.set(this,new Map);return}if(arguments.length===1&&Array.isArray(arguments[0])){return Byt(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 Byt(e)}throw new TypeError("Cannot call a class as a function")}a(rh,"EventTarget");rh.prototype={addEventListener(e,t,r){if(t==null){return}if(typeof t!=="function"&&!jW(t)){throw new TypeError("'listener' should be a function or an object.")}const n=aL(this);const i=jW(r);const s=i?Boolean(r.capture):Boolean(r);const o=s?Lyt:Fyt;const u={listener:t,listenerType:o,passive:i&&Boolean(r.passive),once:i&&Boolean(r.once),next:null};let l=n.get(e);if(l===void 0){n.set(e,u);return}let c=null;while(l!=null){if(l.listener===t&&l.listenerType===o){return}c=l;l=l.next}c.next=u},removeEventListener(e,t,r){if(t==null){return}const n=aL(this);const i=jW(r)?Boolean(r.capture):Boolean(r);const s=i?Lyt:Fyt;let o=null;let u=n.get(e);while(u!=null){if(u.listener===t&&u.listenerType===s){if(o!==null){o.next=u.next}else if(u.next!==null){n.set(e,u.next)}else{n.delete(e)}return}o=u;u=u.next}},dispatchEvent(e){if(e==null||typeof e.type!=="string"){throw new TypeError('"event.type" should be a string.')}const t=aL(this);const r=e.type;let n=t.get(r);if(n==null){return true}const i=ncn(this,e);let s=null;while(n!=null){if(n.once){if(s!==null){s.next=n.next}else if(n.next!==null){t.set(r,n.next)}else{t.delete(r)}}else{s=n}Dyt(i,n.passive?n.listener:null);if(typeof n.listener==="function"){try{n.listener.call(this,i)}catch(o){if(typeof console!=="undefined"&&typeof console.error==="function"){console.error(o)}}}else if(n.listenerType!==$W&&typeof n.listener.handleEvent==="function"){n.listener.handleEvent(i)}if(icn(i)){break}n=n.next}Dyt(i,null);scn(i,0);acn(i,null);return!i.defaultPrevented}};Object.defineProperty(rh.prototype,"constructor",{value:rh,configurable:true,writable:true});if(typeof window!=="undefined"&&typeof window.EventTarget!=="undefined"){Object.setPrototypeOf(rh.prototype,window.EventTarget.prototype)}uL.defineEventAttribute=bSe;uL.EventTarget=rh;uL.default=rh;oL.exports=rh;oL.exports.EventTarget=oL.exports["default"]=rh;oL.exports.defineEventAttribute=bSe});var Vyt=y((cL,lL)=>{"use strict";Object.defineProperty(cL,"__esModule",{value:true});var SSe=jyt();var iE=class extends SSe.EventTarget{static{a(this,"AbortSignal")}constructor(){super();throw new TypeError("AbortSignal cannot be constructed directly")}get aborted(){const t=GW.get(this);if(typeof t!=="boolean"){throw new TypeError(`Expected 'this' to be an 'AbortSignal' object, but got ${this===null?"null":typeof this}`)}return t}};SSe.defineEventAttribute(iE.prototype,"abort");function ucn(){const e=Object.create(iE.prototype);SSe.EventTarget.call(e);GW.set(e,false);return e}a(ucn,"createAbortSignal");function lcn(e){if(GW.get(e)!==false){return}GW.set(e,true);e.dispatchEvent({type:"abort"})}a(lcn,"abortSignal");var GW=new WeakMap;Object.defineProperties(iE.prototype,{aborted:{enumerable:true}});if(typeof Symbol==="function"&&typeof Symbol.toStringTag==="symbol"){Object.defineProperty(iE.prototype,Symbol.toStringTag,{configurable:true,value:"AbortSignal"})}var sE=class{static{a(this,"AbortController")}constructor(){Hyt.set(this,ucn())}get signal(){return Gyt(this)}abort(){lcn(Gyt(this))}};var Hyt=new WeakMap;function Gyt(e){const t=Hyt.get(e);if(t==null){throw new TypeError(`Expected 'this' to be an 'AbortController' object, but got ${e===null?"null":typeof e}`)}return t}a(Gyt,"getSignal");Object.defineProperties(sE.prototype,{signal:{enumerable:true},abort:{enumerable:true}});if(typeof Symbol==="function"&&typeof Symbol.toStringTag==="symbol"){Object.defineProperty(sE.prototype,Symbol.toStringTag,{configurable:true,value:"AbortController"})}cL.AbortController=sE;cL.AbortSignal=iE;cL.default=sE;lL.exports=sE;lL.exports.AbortController=lL.exports["default"]=sE;lL.exports.AbortSignal=iE});var Yyt=y(Ga=>{"use strict";var ccn=Ga&&Ga.__createBinding||(Object.create?function(e,t,r,n){if(n===void 0)n=r;var i=Object.getOwnPropertyDescriptor(t,r);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[r]}}}Object.defineProperty(e,n,i)}:function(e,t,r,n){if(n===void 0)n=r;e[n]=t[r]});var dcn=Ga&&Ga.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var Kyt=Ga&&Ga.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null){for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))ccn(t,e,r)}dcn(t,e);return t};var pcn=Ga&&Ga.__classPrivateFieldSet||function(e,t,r,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t==="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(e,r):i?i.value=r:t.set(e,r),r};var lp=Ga&&Ga.__classPrivateFieldGet||function(e,t,r,n){if(r==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof t==="function"?e!==t||!n:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return r==="m"?n:r==="a"?n.call(e):n?n.value:t.get(e)};var Wyt=Ga&&Ga.__importDefault||function(e){return e&&e.__esModule?e:{"default":e}};var ly;var cy;var dL;var HW;Object.defineProperty(Ga,"__esModule",{value:true});Ga.createURI=Ga.upload=Ga.Upload=Ga.PROTOCOL_REGEX=void 0;var fcn=Wyt(Vyt());var mcn=require("crypto");var hcn=Kyt(w0());var gcn=iW();var zyt=require("stream");var ycn=Wyt(sL());var rO=Kyt((Fv(),Ct(Lv)));var _cn=TA();var uy=P0();var vcn=KR();var Ecn=404;var ASe=308;var bcn=/.*\.googleapis\.com/;var CSe=(0,vcn.getPackageJSON)();Ga.PROTOCOL_REGEX=/^(\w*):\/\//;var pL=class extends zyt.Writable{static{a(this,"Upload")}constructor(t){super(t);ly.add(this);this.numBytesWritten=0;this.numRetries=0;this.currentInvocationId={chunk:rO.v4(),uri:rO.v4(),offset:rO.v4()};this.writeBuffers=[];this.numChunksReadInRequest=0;this.localWriteCache=[];this.localWriteCacheByteLength=0;this.upstreamEnded=false;cy.set(this,void 0);t=t||{};if(!t.bucket||!t.file){throw new Error("A bucket and file name are required")}t.authConfig=t.authConfig||{};t.authConfig.scopes=["https://www.googleapis.com/auth/devstorage.full_control"];this.authClient=t.authClient||new gcn.GoogleAuth(t.authConfig);this.apiEndpoint="https://storage.googleapis.com";if(t.apiEndpoint){this.apiEndpoint=this.sanitizeEndpoint(t.apiEndpoint);if(!bcn.test(t.apiEndpoint)){this.authClient=hcn}}this.baseURI=`${this.apiEndpoint}/upload/storage/v1/b`;this.bucket=t.bucket;const r=[t.bucket,t.file];if(typeof t.generation==="number"){r.push(`${t.generation}`)}this.cacheKey=r.join("/");this.customRequestOptions=t.customRequestOptions||{};this.file=t.file;this.generation=t.generation;this.kmsKeyName=t.kmsKeyName;this.metadata=t.metadata||{};this.offset=t.offset;this.origin=t.origin;this.params=t.params||{};this.userProject=t.userProject;this.chunkSize=t.chunkSize;this.retryOptions=t.retryOptions;if(t.key){const s=Buffer.from(t.key).toString("base64");this.encryption={key:s,hash:(0,mcn.createHash)("sha256").update(t.key).digest("base64")}}this.predefinedAcl=t.predefinedAcl;if(t.private)this.predefinedAcl="private";if(t.public)this.predefinedAcl="publicRead";const n=t.retryOptions.autoRetry;this.uriProvidedManually=!!t.uri;this.uri=t.uri;this.numBytesWritten=0;this.numRetries=0;if(!n){t.retryOptions.maxRetries=0}this.timeOfFirstRequest=Date.now();const i=t.metadata?Number(t.metadata.contentLength):NaN;this.contentLength=isNaN(i)?"*":i;pcn(this,cy,t[_cn.GCCL_GCS_CMD_KEY],"f");this.once("writing",()=>{if(this.uri){this.continueUploading()}else{this.createURI(s=>{if(s){return this.destroy(s)}this.startUploading();return})}})}_final(t=()=>{}){this.upstreamEnded=true;this.once("uploadFinished",t);process.nextTick(()=>{this.emit("upstreamFinished");this.emit("writing")})}_write(t,r,n=()=>{}){this.emit("writing");this.writeBuffers.push(typeof t==="string"?Buffer.from(t,r):t);this.once("readFromChunkBuffer",n);process.nextTick(()=>this.emit("wroteToChunkBuffer"))}prependLocalBufferToUpstream(t){let r=[];if(t){let i=0;while(t>i){let s=this.localWriteCache.pop();if(!s)break;i+=s.byteLength;if(i>t){const o=i-t;s=s.subarray(o);i-=o}r.unshift(s)}}else{r=this.localWriteCache}const n=this.writeBuffers;this.writeBuffers=r;for(const i of n){this.writeBuffers.push(i)}lp(this,ly,"m",dL).call(this)}*pullFromChunkBuffer(t){while(t){const r=this.writeBuffers.shift();if(!r)break;let n=r;if(r.byteLength>t){n=r.subarray(0,t);this.writeBuffers.unshift(r.subarray(t));t=0}else{t-=r.byteLength}yield n;this.emit("readFromChunkBuffer")}}async waitForNextChunk(){const t=await new Promise(r=>{if(this.writeBuffers.length){return r(true)}if(this.upstreamEnded){return r(false)}const n=a(()=>{s();return r(true)},"wroteToChunkBufferCallback");const i=a(()=>{s();if(this.writeBuffers.length)return r(true);return r(false)},"upstreamFinishedCallback");const s=a(()=>{this.removeListener("wroteToChunkBuffer",n);this.removeListener("upstreamFinished",i)},"removeListeners");this.once("wroteToChunkBuffer",n);this.once("upstreamFinished",i)});return t}async*upstreamIterator(t=Infinity){while(t&&await this.waitForNextChunk()){for(const r of this.pullFromChunkBuffer(t)){t-=r.byteLength;yield r}}}createURI(t){if(!t){return this.createURIAsync()}this.createURIAsync().then(r=>t(null,r),t)}async createURIAsync(){const t={...this.metadata};const r={};if(t.contentLength){r["X-Upload-Content-Length"]=t.contentLength.toString();delete t.contentLength}if(t.contentType){r["X-Upload-Content-Type"]=t.contentType;delete t.contentType}let n=`${(0,uy.getRuntimeTrackingString)()} gccl/${CSe.version}-${(0,uy.getModuleFormat)()} gccl-invocation-id/${this.currentInvocationId.uri}`;if(lp(this,cy,"f")){n+=` gccl-gcs-cmd/${lp(this,cy,"f")}`}const i={method:"POST",url:[this.baseURI,this.bucket,"o"].join("/"),params:Object.assign({name:this.file,uploadType:"resumable"},this.params),data:t,headers:{"User-Agent":(0,uy.getUserAgentString)(),"x-goog-api-client":n,...r}};if(t.contentLength){i.headers["X-Upload-Content-Length"]=t.contentLength.toString()}if(t.contentType){i.headers["X-Upload-Content-Type"]=t.contentType}if(typeof this.generation!=="undefined"){i.params.ifGenerationMatch=this.generation}if(this.kmsKeyName){i.params.kmsKeyName=this.kmsKeyName}if(this.predefinedAcl){i.params.predefinedAcl=this.predefinedAcl}if(this.origin){i.headers.Origin=this.origin}const s=await(0,ycn.default)(async o=>{var u,l,c;try{const d=await this.makeRequest(i);this.currentInvocationId.uri=rO.v4();return d.headers.location}catch(d){const p=d;const f={code:(u=p.response)===null||u===void 0?void 0:u.status,name:(l=p.response)===null||l===void 0?void 0:l.statusText,message:(c=p.response)===null||c===void 0?void 0:c.statusText,errors:[{reason:p.code}]};if(this.retryOptions.maxRetries>0&&this.retryOptions.retryableErrorFn(f)){throw p}else{return o(p)}}},{retries:this.retryOptions.maxRetries,factor:this.retryOptions.retryDelayMultiplier,maxTimeout:this.retryOptions.maxRetryDelay*1e3,maxRetryTime:this.retryOptions.totalTimeout*1e3});this.uri=s;this.offset=0;return s}async continueUploading(){if(typeof this.offset==="number"){this.startUploading();return}await this.getAndSetOffset();this.startUploading()}async startUploading(){const t=!!this.chunkSize;let r=false;this.numChunksReadInRequest=0;if(!this.offset){this.offset=0}if(this.offset<this.numBytesWritten){const c=this.numBytesWritten-this.offset;const d=`The offset is lower than the number of bytes written. The server has ${this.offset} bytes and while ${this.numBytesWritten} bytes has been uploaded - thus ${c} bytes are missing. Stopping as this could result in data loss. Initiate a new upload to continue.`;this.emit("error",new RangeError(d));return}if(this.numBytesWritten<this.offset){const c=this.offset-this.numBytesWritten;for await(const d of this.upstreamIterator(c)){d}this.numBytesWritten=this.offset}let n=void 0;if(typeof this.contentLength==="number"){n=this.contentLength-this.numBytesWritten}if(this.chunkSize){n=n?Math.min(this.chunkSize,n):this.chunkSize}const i=this.upstreamIterator(n);const s=new zyt.Readable({read:async()=>{if(r)s.push(null);const c=await i.next();if(c.value){this.numChunksReadInRequest++;if(t){lp(this,ly,"m",HW).call(this,c.value)}else{lp(this,ly,"m",dL).call(this);lp(this,ly,"m",HW).call(this,c.value)}this.numBytesWritten+=c.value.byteLength;this.emit("progress",{bytesWritten:this.numBytesWritten,contentLength:this.contentLength});s.push(c.value)}if(c.done){s.push(null)}}});let o=`${(0,uy.getRuntimeTrackingString)()} gccl/${CSe.version}-${(0,uy.getModuleFormat)()} gccl-invocation-id/${this.currentInvocationId.chunk}`;if(lp(this,cy,"f")){o+=` gccl-gcs-cmd/${lp(this,cy,"f")}`}const u={"User-Agent":(0,uy.getUserAgentString)(),"x-goog-api-client":o};if(t){for await(const m of this.upstreamIterator(n)){lp(this,ly,"m",HW).call(this,m)}const c=this.localWriteCacheByteLength;const d=!await this.waitForNextChunk();this.prependLocalBufferToUpstream();let p=this.contentLength;if(typeof this.contentLength!=="number"&&d){p=c+this.numBytesWritten}const f=c+this.numBytesWritten-1;u["Content-Length"]=c;u["Content-Range"]=`bytes ${this.offset}-${f}/${p}`}else{u["Content-Range"]=`bytes ${this.offset}-*/${this.contentLength}`}const l={method:"PUT",url:this.uri,headers:u,body:s};try{const c=await this.makeRequestStream(l);if(c){r=true;this.responseHandler(c)}}catch(c){const d=c;if(this.retryOptions.retryableErrorFn(d)){this.attemptDelayedRetry({status:NaN,data:d});return}this.destroy(d)}}responseHandler(t){if(t.data.error){this.destroy(t.data.error);return}this.currentInvocationId.chunk=rO.v4();const r=this.chunkSize&&t.status===ASe&&t.headers.range;if(r){const n=t.headers.range;this.offset=Number(n.split("-")[1])+1;const i=this.numBytesWritten-this.offset;if(i){this.prependLocalBufferToUpstream(i);this.numBytesWritten-=i}else{lp(this,ly,"m",dL).call(this)}this.continueUploading()}else if(!this.isSuccessfulResponse(t.status)){const n=new Error("Upload failed");n.code=t.status;n.name="Upload failed";if(t===null||t===void 0?void 0:t.data){n.errors=[t===null||t===void 0?void 0:t.data]}this.destroy(n)}else{lp(this,ly,"m",dL).call(this);if(t&&t.data){t.data.size=Number(t.data.size)}this.emit("metadata",t.data);this.emit("uploadFinished")}}async getAndSetOffset(){let t=`${(0,uy.getRuntimeTrackingString)()} gccl/${CSe.version}-${(0,uy.getModuleFormat)()} gccl-invocation-id/${this.currentInvocationId.offset}`;if(lp(this,cy,"f")){t+=` gccl-gcs-cmd/${lp(this,cy,"f")}`}const r={method:"PUT",url:this.uri,headers:{"Content-Length":0,"Content-Range":"bytes */*","User-Agent":(0,uy.getUserAgentString)(),"x-goog-api-client":t}};try{const n=await this.makeRequest(r);this.currentInvocationId.offset=rO.v4();if(n.status===ASe){if(n.headers.range){const i=n.headers.range;this.offset=Number(i.split("-")[1])+1;return}}this.offset=0}catch(n){const i=n;if(this.retryOptions.retryableErrorFn(i)){this.attemptDelayedRetry({status:NaN,data:i});return}this.destroy(i)}}async makeRequest(t){if(this.encryption){t.headers=t.headers||{};t.headers["x-goog-encryption-algorithm"]="AES256";t.headers["x-goog-encryption-key"]=this.encryption.key.toString();t.headers["x-goog-encryption-key-sha256"]=this.encryption.hash.toString()}if(this.userProject){t.params=t.params||{};t.params.userProject=this.userProject}t.validateStatus=i=>{return this.isSuccessfulResponse(i)||i===ASe};const r={...this.customRequestOptions,...t,headers:{...this.customRequestOptions.headers,...t.headers}};const n=await this.authClient.request(r);if(n.data&&n.data.error){throw n.data.error}return n}async makeRequestStream(t){const r=new fcn.default;const n=a(()=>r.abort(),"errorCallback");this.once("error",n);if(this.userProject){t.params=t.params||{};t.params.userProject=this.userProject}t.signal=r.signal;t.validateStatus=()=>true;const i={...this.customRequestOptions,...t,headers:{...this.customRequestOptions.headers,...t.headers}};const s=await this.authClient.request(i);const o=this.onResponse(s);this.removeListener("error",n);return o?s:null}onResponse(t){if(t.status!==200&&this.retryOptions.retryableErrorFn({code:t.status,message:t.statusText,name:t.statusText})){this.attemptDelayedRetry(t);return false}this.emit("response",t);return true}attemptDelayedRetry(t){if(this.numRetries<this.retryOptions.maxRetries){if(t.status===Ecn&&this.numChunksReadInRequest===0){this.startUploading()}else{const r=this.getRetryDelay();if(r<=0){this.destroy(new Error(`Retry total time limit exceeded - ${t.data}`));return}this.numBytesWritten-=this.localWriteCacheByteLength;this.prependLocalBufferToUpstream();this.offset=void 0;setTimeout(this.continueUploading.bind(this),r)}this.numRetries++}else{this.destroy(new Error("Retry limit exceeded - "+t.data))}}getRetryDelay(){const t=Math.round(Math.random()*1e3);const r=Math.pow(this.retryOptions.retryDelayMultiplier,this.numRetries)*1e3+t;const n=this.retryOptions.totalTimeout*1e3-(Date.now()-this.timeOfFirstRequest);const i=this.retryOptions.maxRetryDelay*1e3;return Math.min(r,i,n)}sanitizeEndpoint(t){if(!Ga.PROTOCOL_REGEX.test(t)){t=`https://${t}`}return t.replace(/\/+$/,"")}isSuccessfulResponse(t){return t>=200&&t<300}};Ga.Upload=pL;cy=new WeakMap,ly=new WeakSet,dL=a(function e(){this.localWriteCache=[];this.localWriteCacheByteLength=0},"_Upload_resetLocalBuffersCache"),HW=a(function e(t){this.localWriteCache.push(t);this.localWriteCacheByteLength+=t.byteLength},"_Upload_addLocalBufferCache");function Scn(e){return new pL(e)}a(Scn,"upload");Ga.upload=Scn;function Acn(e,t){const r=new pL(e);if(!t){return r.createURI()}r.createURI().then(n=>t(null,n),t)}a(Acn,"createURI");Ga.createURI=Acn});var TSe=y(yu=>{"use strict";var Ccn=yu&&yu.__createBinding||(Object.create?function(e,t,r,n){if(n===void 0)n=r;var i=Object.getOwnPropertyDescriptor(t,r);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[r]}}}Object.defineProperty(e,n,i)}:function(e,t,r,n){if(n===void 0)n=r;e[n]=t[r]});var wcn=yu&&yu.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var Zyt=yu&&yu.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null){for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))Ccn(t,e,r)}wcn(t,e);return t};Object.defineProperty(yu,"__esModule",{value:true});yu.SigningError=yu.URLSigner=yu.PATH_STYLED_HOST=yu.SignerExceptionMessages=void 0;var Tcn=Zyt(require("crypto"));var Xyt=Zyt(require("url"));var Jyt=nO();var aE=P0();var fL;(function(e){e["ACCESSIBLE_DATE_INVALID"]="The accessible at date provided was invalid.";e["EXPIRATION_BEFORE_ACCESSIBLE_DATE"]="An expiration date cannot be before accessible date.";e["X_GOOG_CONTENT_SHA256"]="The header X-Goog-Content-SHA256 must be a hexadecimal string."})(fL||(yu.SignerExceptionMessages=fL={}));var xcn="v2";var Qyt=7*24*60*60;yu.PATH_STYLED_HOST="https://storage.googleapis.com";var wSe=class{static{a(this,"URLSigner")}constructor(t,r,n){this.bucket=r;this.file=n;this.authClient=t}getSignedUrl(t){const r=this.parseExpires(t.expires);const n=t.method;const i=this.parseAccessibleAt(t.accessibleAt);if(r<i){throw new Error(fL.EXPIRATION_BEFORE_ACCESSIBLE_DATE)}let s;const o=t.virtualHostedStyle||false;if(t.cname){s=t.cname}else if(o){s=`https://${this.bucket.name}.storage.googleapis.com`}const u=1e3;const l=Object.assign({},t,{method:n,expiration:r,accessibleAt:new Date(u*i),bucket:this.bucket.name,file:this.file?(0,aE.encodeURI)(this.file.name,false):void 0});if(s){l.cname=s}const c=t.version||xcn;let d;if(c==="v2"){d=this.getSignedUrlV2(l)}else if(c==="v4"){d=this.getSignedUrlV4(l)}else{throw new Error(`Invalid signed URL version: ${c}. Supported versions are 'v2' and 'v4'.`)}return d.then(p=>{p=Object.assign(p,t.queryParams);const f=new Xyt.URL(l.cname||yu.PATH_STYLED_HOST);f.pathname=this.getResourcePath(!!l.cname,this.bucket.name,l.file);f.search=(0,aE.qsStringify)(p);return f.href})}getSignedUrlV2(t){const r=this.getCanonicalHeaders(t.extensionHeaders||{});const n=this.getResourcePath(false,t.bucket,t.file);const i=[t.method,t.contentMd5||"",t.contentType||"",t.expiration,r+n].join("\n");const s=a(async()=>{const o=this.authClient;try{const u=await o.sign(i);const l=await o.getCredentials();return{GoogleAccessId:l.client_email,Expires:t.expiration,Signature:u}}catch(u){const l=u;const c=new mL(l.message);c.stack=l.stack;throw c}},"sign");return s()}getSignedUrlV4(t){t.accessibleAt=t.accessibleAt?t.accessibleAt:new Date;const r=1/1e3;const n=t.expiration-t.accessibleAt.valueOf()*r;if(n>Qyt){throw new Error(`Max allowed expiration is seven days (${Qyt} seconds).`)}const i=Object.assign({},t.extensionHeaders);const s=new Xyt.URL(t.cname||yu.PATH_STYLED_HOST);i.host=s.host;if(t.contentMd5){i["content-md5"]=t.contentMd5}if(t.contentType){i["content-type"]=t.contentType}let o;const u=i["x-goog-content-sha256"];if(u){if(typeof u!=="string"||!/[A-Fa-f0-9]{40}/.test(u)){throw new Error(fL.X_GOOG_CONTENT_SHA256)}o=u}const l=Object.keys(i).map(m=>m.toLowerCase()).sort().join(";");const c=this.getCanonicalHeaders(i);const d=(0,aE.formatAsUTCISO)(t.accessibleAt);const p=`${d}/auto/storage/goog4_request`;const f=a(async()=>{const m=await this.authClient.getCredentials();const h=`${m.client_email}/${p}`;const g=(0,aE.formatAsUTCISO)(t.accessibleAt?t.accessibleAt:new Date,true);const _={"X-Goog-Algorithm":"GOOG4-RSA-SHA256","X-Goog-Credential":h,"X-Goog-Date":g,"X-Goog-Expires":n.toString(10),"X-Goog-SignedHeaders":l,...t.queryParams||{}};const v=this.getCanonicalQueryParams(_);const S=this.getCanonicalRequest(t.method,this.getResourcePath(!!t.cname,t.bucket,t.file),v,c,l,o);const E=Tcn.createHash("sha256").update(S).digest("hex");const b=["GOOG4-RSA-SHA256",g,p,E].join("\n");try{const A=await this.authClient.sign(b);const C=Buffer.from(A,"base64").toString("hex");const T=Object.assign({},_,{"X-Goog-Signature":C});return T}catch(A){const C=A;const T=new mL(C.message);T.stack=C.stack;throw T}},"sign");return f()}getCanonicalHeaders(t){const r=(0,aE.objectEntries)(t).map(([n,i])=>[n.toLowerCase(),i]).sort((n,i)=>n[0].localeCompare(i[0]));return r.filter(([,n])=>n!==void 0).map(([n,i])=>{const s=`${i}`.trim().replace(/\s{2,}/g," ");return`${n}:${s}
|
|
395
|
-
`}).join("")}getCanonicalRequest(t,r,n,i,s,o){return[t,r,n,i,s,o||"UNSIGNED-PAYLOAD"].join("\n")}getCanonicalQueryParams(t){return(0,aE.objectEntries)(t).map(([r,n])=>[(0,aE.encodeURI)(r,true),(0,aE.encodeURI)(n,true)]).sort((r,n)=>r[0]<n[0]?-1:1).map(([r,n])=>`${r}=${n}`).join("&")}getResourcePath(t,r,n){if(t){return"/"+(n||"")}else if(n){return`/${r}/${n}`}else{return`/${r}`}}parseExpires(t,r=new Date){const n=new Date(t).valueOf();if(isNaN(n)){throw new Error(Jyt.ExceptionMessages.EXPIRATION_DATE_INVALID)}if(n<r.valueOf()){throw new Error(Jyt.ExceptionMessages.EXPIRATION_DATE_PAST)}return Math.floor(n/1e3)}parseAccessibleAt(t){const r=new Date(t||new Date).valueOf();if(isNaN(r)){throw new Error(fL.ACCESSIBLE_DATE_INVALID)}return Math.floor(r/1e3)}};yu.URLSigner=wSe;var mL=class extends Error{static{a(this,"SigningError")}constructor(){super(...arguments);this.name="SigningError"}};yu.SigningError=mL});var hL=y(Ol=>{"use strict";var e_t=Ol&&Ol.__classPrivateFieldSet||function(e,t,r,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t==="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(e,r):i?i.value=r:t.set(e,r),r};var VW=Ol&&Ol.__classPrivateFieldGet||function(e,t,r,n){if(r==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof t==="function"?e!==t||!n:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return r==="m"?n:r==="a"?n.call(e):n?n.value:t.get(e)};var oE;Object.defineProperty(Ol,"__esModule",{value:true});Ol.CRC32C_EXTENSION_TABLE=Ol.CRC32C_EXTENSIONS=Ol.CRC32C_EXCEPTION_MESSAGES=Ol.CRC32C_DEFAULT_VALIDATOR_GENERATOR=Ol.CRC32C=void 0;var Rcn=require("fs");var xSe=[0,4067132163,3778769143,324072436,3348797215,904991772,648144872,3570033899,2329499855,2024987596,1809983544,2575936315,1296289744,3207089363,2893594407,1578318884,274646895,3795141740,4049975192,51262619,3619967088,632279923,922689671,3298075524,2592579488,1760304291,2075979607,2312596564,1562183871,2943781820,3156637768,1313733451,549293790,3537243613,3246849577,871202090,3878099393,357341890,102525238,4101499445,2858735121,1477399826,1264559846,3107202533,1845379342,2677391885,2361733625,2125378298,820201905,3263744690,3520608582,598981189,4151959214,85089709,373468761,3827903834,3124367742,1213305469,1526817161,2842354314,2107672161,2412447074,2627466902,1861252501,1098587580,3004210879,2688576843,1378610760,2262928035,1955203488,1742404180,2511436119,3416409459,969524848,714683780,3639785095,205050476,4266873199,3976438427,526918040,1361435347,2739821008,2954799652,1114974503,2529119692,1691668175,2005155131,2247081528,3690758684,697762079,986182379,3366744552,476452099,3993867776,4250756596,255256311,1640403810,2477592673,2164122517,1922457750,2791048317,1412925310,1197962378,3037525897,3944729517,427051182,170179418,4165941337,746937522,3740196785,3451792453,1070968646,1905808397,2213795598,2426610938,1657317369,3053634322,1147748369,1463399397,2773627110,4215344322,153784257,444234805,3893493558,1021025245,3467647198,3722505002,797665321,2197175160,1889384571,1674398607,2443626636,1164749927,3070701412,2757221520,1446797203,137323447,4198817972,3910406976,461344835,3484808360,1037989803,781091935,3705997148,2460548119,1623424788,1939049696,2180517859,1429367560,2807687179,3020495871,1180866812,410100952,3927582683,4182430767,186734380,3756733383,763408580,1053836080,3434856499,2722870694,1344288421,1131464017,2971354706,1708204729,2545590714,2229949006,1988219213,680717673,3673779818,3383336350,1002577565,4010310262,493091189,238226049,4233660802,2987750089,1082061258,1395524158,2705686845,1972364758,2279892693,2494862625,1725896226,952904198,3399985413,3656866545,731699698,4283874585,222117402,510512622,3959836397,3280807620,837199303,582374963,3504198960,68661723,4135334616,3844915500,390545967,1230274059,3141532936,2825850620,1510247935,2395924756,2091215383,1878366691,2644384480,3553878443,565732008,854102364,3229815391,340358836,3861050807,4117890627,119113024,1493875044,2875275879,3090270611,1247431312,2660249211,1828433272,2141937292,2378227087,3811616794,291187481,34330861,4032846830,615137029,3603020806,3314634738,939183345,1776939221,2609017814,2295496738,2058945313,2926798794,1545135305,1330124605,3173225534,4084100981,17165430,307568514,3762199681,888469610,3332340585,3587147933,665062302,2042050490,2346497209,2559330125,1793573966,3190661285,1279665062,1595330642,2910671697];Ol.CRC32C_EXTENSIONS=xSe;var t_t=new Int32Array(xSe);Ol.CRC32C_EXTENSION_TABLE=t_t;var Ocn=a(()=>new iO,"CRC32C_DEFAULT_VALIDATOR_GENERATOR");Ol.CRC32C_DEFAULT_VALIDATOR_GENERATOR=Ocn;var zW={INVALID_INIT_BASE64_RANGE:e=>`base64-encoded data expected to equal 4 bytes, not ${e}`,INVALID_INIT_BUFFER_LENGTH:e=>`Buffer expected to equal 4 bytes, not ${e}`,INVALID_INIT_INTEGER:e=>`Number expected to be a safe, unsigned 32-bit integer, not ${e}`};Ol.CRC32C_EXCEPTION_MESSAGES=zW;var iO=class e{static{a(this,"CRC32C")}constructor(t=0){oE.set(this,0);e_t(this,oE,t,"f")}update(t){let r=VW(this,oE,"f")^4294967295;for(const n of t){const i=e.CRC32C_EXTENSION_TABLE[(n^r)&255];r=i^r>>>8}e_t(this,oE,r^4294967295,"f")}validate(t){if(typeof t==="number"){return t===VW(this,oE,"f")}else if(typeof t==="string"){return t===this.toString()}else if(Buffer.isBuffer(t)){return Buffer.compare(t,this.toBuffer())===0}else{return t.toString()===this.toString()}}toBuffer(){const t=Buffer.alloc(4);t.writeInt32BE(VW(this,oE,"f"));return t}toJSON(){return this.toString()}toString(){return this.toBuffer().toString("base64")}valueOf(){return VW(this,oE,"f")}static fromBuffer(t){let r;if(Buffer.isBuffer(t)){r=t}else if("buffer"in t){r=Buffer.from(t.buffer)}else{r=Buffer.from(t)}if(r.byteLength!==4){throw new RangeError(zW.INVALID_INIT_BUFFER_LENGTH(r.byteLength))}return new e(r.readInt32BE())}static async fromFile(t){const r=new e;await new Promise((n,i)=>{(0,Rcn.createReadStream)(t).on("data",s=>r.update(s)).on("end",n).on("error",i)});return r}static fromString(t){const r=Buffer.from(t,"base64");if(r.byteLength!==4){throw new RangeError(zW.INVALID_INIT_BASE64_RANGE(r.byteLength))}return this.fromBuffer(r)}static fromNumber(t){if(!Number.isSafeInteger(t)||t>2**32||t<-(2**32)){throw new RangeError(zW.INVALID_INIT_INTEGER(t))}return new e(t)}static from(t){if(typeof t==="number"){return this.fromNumber(t)}else if(typeof t==="string"){return this.fromString(t)}else if("byteLength"in t){return this.fromBuffer(t)}else{return this.fromString(t.toString())}}};Ol.CRC32C=iO;oE=new WeakMap;iO.CRC32C_EXTENSIONS=xSe;iO.CRC32C_EXTENSION_TABLE=t_t});var PSe=y(lE=>{"use strict";var RSe=lE&&lE.__classPrivateFieldSet||function(e,t,r,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t==="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(e,r):i?i.value=r:t.set(e,r),r};var D0=lE&&lE.__classPrivateFieldGet||function(e,t,r,n){if(r==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof t==="function"?e!==t||!n:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return r==="m"?n:r==="a"?n.call(e):n?n.value:t.get(e)};var OA;var uE;var KW;Object.defineProperty(lE,"__esModule",{value:true});lE.HashStreamValidator=void 0;var Pcn=require("crypto");var Ncn=require("stream");var Icn=hL();var r_t=gL();var OSe=class extends Ncn.Transform{static{a(this,"HashStreamValidator")}constructor(t={}){super();this.updateHashesOnly=false;OA.set(this,void 0);uE.set(this,void 0);KW.set(this,"");this.crc32cEnabled=!!t.crc32c;this.md5Enabled=!!t.md5;this.updateHashesOnly=!!t.updateHashesOnly;this.crc32cExpected=t.crc32cExpected;this.md5Expected=t.md5Expected;if(this.crc32cEnabled){const r=t.crc32cGenerator||Icn.CRC32C_DEFAULT_VALIDATOR_GENERATOR;RSe(this,OA,r(),"f")}if(this.md5Enabled){RSe(this,uE,(0,Pcn.createHash)("md5"),"f")}}_flush(t){if(D0(this,uE,"f")){RSe(this,KW,D0(this,uE,"f").digest("base64"),"f")}if(this.updateHashesOnly){t();return}let r=this.crc32cEnabled||this.md5Enabled;if(this.crc32cEnabled&&this.crc32cExpected){r=!this.test("crc32c",this.crc32cExpected)}if(this.md5Enabled&&this.md5Expected){r=!this.test("md5",this.md5Expected)}if(r){const n=new r_t.RequestError(r_t.FileExceptionMessages.DOWNLOAD_MISMATCH);n.code="CONTENT_DOWNLOAD_MISMATCH";t(n)}else{t()}}_transform(t,r,n){this.push(t,r);try{if(D0(this,OA,"f"))D0(this,OA,"f").update(t);if(D0(this,uE,"f"))D0(this,uE,"f").update(t);n()}catch(i){n(i)}}test(t,r){const n=Buffer.isBuffer(r)?r.toString("base64"):r;if(t==="crc32c"&&D0(this,OA,"f")){return D0(this,OA,"f").validate(n)}if(t==="md5"&&D0(this,uE,"f")){return D0(this,KW,"f")===n}return false}};lE.HashStreamValidator=OSe;OA=new WeakMap,uE=new WeakMap,KW=new WeakMap});var gL=y(Ha=>{"use strict";var kcn=Ha&&Ha.__createBinding||(Object.create?function(e,t,r,n){if(n===void 0)n=r;var i=Object.getOwnPropertyDescriptor(t,r);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[r]}}}Object.defineProperty(e,n,i)}:function(e,t,r,n){if(n===void 0)n=r;e[n]=t[r]});var Dcn=Ha&&Ha.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var YW=Ha&&Ha.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null){for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))kcn(t,e,r)}Dcn(t,e);return t};var Lcn=Ha&&Ha.__classPrivateFieldGet||function(e,t,r,n){if(r==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof t==="function"?e!==t||!n:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return r==="m"?n:r==="a"?n.call(e):n?n.value:t.get(e)};var XW=Ha&&Ha.__importDefault||function(e){return e&&e.__esModule?e:{"default":e}};var ISe;var u_t;Object.defineProperty(Ha,"__esModule",{value:true});Ha.File=Ha.FileExceptionMessages=Ha.RequestError=Ha.STORAGE_POST_POLICY_BASE_URL=Ha.ActionToHTTPMethod=void 0;var cE=rE();var Fcn=I0();var Bcn=XW(Cyt());var Mcn=YW(require("crypto"));var n_t=YW(require("fs"));var qcn=XW(Iyt());var i_t=YW(Yyt());var yL=require("stream");var s_t=YW(require("zlib"));var _f=nO();var _L=JW();var Ucn=vSe();var NSe=TSe();var dy=TA();var $cn=XW(nSe());var py=P0();var a_t=PSe();var jcn=XW(sL());var kSe;(function(e){e["read"]="GET";e["write"]="PUT";e["delete"]="DELETE";e["resumable"]="POST"})(kSe||(Ha.ActionToHTTPMethod=kSe={}));Ha.STORAGE_POST_POLICY_BASE_URL="https://storage.googleapis.com";var Gcn=/^gs:\/\/([a-z0-9_.-]+)\/(.+)$/;var vL=class extends Error{static{a(this,"RequestError")}};Ha.RequestError=vL;var o_t=7*24*60*60;var vf;(function(e){e["EXPIRATION_TIME_NA"]="An expiration time is not available.";e["DESTINATION_NO_NAME"]="Destination file should have a name.";e["INVALID_VALIDATION_FILE_RANGE"]="Cannot use validation with file ranges (start/end).";e["MD5_NOT_AVAILABLE"]="MD5 verification was specified, but is not available for the requested object. MD5 is not available for composite objects.";e["EQUALS_CONDITION_TWO_ELEMENTS"]="Equals condition must be an array of 2 elements.";e["STARTS_WITH_TWO_ELEMENTS"]="StartsWith condition must be an array of 2 elements.";e["CONTENT_LENGTH_RANGE_MIN_MAX"]="ContentLengthRange must have numeric min & max fields.";e["DOWNLOAD_MISMATCH"]="The downloaded data did not match the data from the server. To be sure the content is the same, you should download the file again.";e["UPLOAD_MISMATCH_DELETE_FAIL"]="The uploaded data did not match the data from the server.\n As a precaution, we attempted to delete the file, but it was not successful.\n To be sure the content is the same, you should try removing the file manually,\n then uploading the file again.\n \n\nThe delete attempt failed with this message:\n\n ";e["UPLOAD_MISMATCH"]="The uploaded data did not match the data from the server.\n As a precaution, the file has been deleted.\n To be sure the content is the same, you should try uploading the file again."})(vf||(Ha.FileExceptionMessages=vf={}));var WW=class e extends cE.ServiceObject{static{a(this,"File")}constructor(t,r,n={}){var i,s;const o={};let u;if(n.generation!==null){if(typeof n.generation==="string"){u=Number(n.generation)}else{u=n.generation}if(!isNaN(u)){o.generation=u}}Object.assign(o,n.preconditionOpts);const l=n.userProject||t.userProject;if(typeof l==="string"){o.userProject=l}const c={delete:{reqOpts:{qs:o}},exists:{reqOpts:{qs:o}},get:{reqOpts:{qs:o}},getMetadata:{reqOpts:{qs:o}},setMetadata:{reqOpts:{qs:o}}};super({parent:t,baseUrl:"/o",id:encodeURIComponent(r),methods:c});ISe.add(this);this.bucket=t;this.storage=t.parent;if(n.generation!==null){let d;if(typeof n.generation==="string"){d=Number(n.generation)}else{d=n.generation}if(!isNaN(d)){this.generation=d}}this.kmsKeyName=n.kmsKeyName;this.userProject=l;this.name=r;if(n.encryptionKey){this.setEncryptionKey(n.encryptionKey)}this.acl=new Ucn.Acl({request:this.request.bind(this),pathPrefix:"/acl"});this.crc32cGenerator=n.crc32cGenerator||this.bucket.crc32cGenerator;this.instanceRetryValue=(s=(i=this.storage)===null||i===void 0?void 0:i.retryOptions)===null||s===void 0?void 0:s.autoRetry;this.instancePreconditionOpts=n===null||n===void 0?void 0:n.preconditionOpts}get cloudStorageURI(){const t=this.bucket.cloudStorageURI;t.pathname=this.name;return t}shouldRetryBasedOnPreconditionAndIdempotencyStrat(t){var r;return!((t===null||t===void 0?void 0:t.ifGenerationMatch)===void 0&&((r=this.instancePreconditionOpts)===null||r===void 0?void 0:r.ifGenerationMatch)===void 0&&this.storage.retryOptions.idempotencyStrategy===_f.IdempotencyStrategy.RetryConditional||this.storage.retryOptions.idempotencyStrategy===_f.IdempotencyStrategy.RetryNever)}copy(t,r,n){var i,s;const o=new Error(vf.DESTINATION_NO_NAME);if(!t){throw o}let u={};if(typeof r==="function"){n=r}else if(r){u={...r}}n=n||cE.util.noop;let l;let c;let d;if(typeof t==="string"){const m=Gcn.exec(t);if(m!==null&&m.length===3){l=this.storage.bucket(m[1]);c=m[2]}else{l=this.bucket;c=t}}else if(t instanceof _L.Bucket){l=t;c=this.name}else if(t instanceof e){l=t.bucket;c=t.name;d=t}else{throw o}const p={};if(this.generation!==void 0){p.sourceGeneration=this.generation}if(u.token!==void 0){p.rewriteToken=u.token}if(u.userProject!==void 0){p.userProject=u.userProject;delete u.userProject}if(u.predefinedAcl!==void 0){p.destinationPredefinedAcl=u.predefinedAcl;delete u.predefinedAcl}d=d||l.file(c);const f={};if(this.encryptionKey!==void 0){f["x-goog-copy-source-encryption-algorithm"]="AES256";f["x-goog-copy-source-encryption-key"]=this.encryptionKeyBase64;f["x-goog-copy-source-encryption-key-sha256"]=this.encryptionKeyHash}if(d.encryptionKey!==void 0){this.setEncryptionKey(d.encryptionKey)}else if(u.destinationKmsKeyName!==void 0){p.destinationKmsKeyName=u.destinationKmsKeyName;delete u.destinationKmsKeyName}else if(d.kmsKeyName!==void 0){p.destinationKmsKeyName=d.kmsKeyName}if(p.destinationKmsKeyName){this.kmsKeyName=p.destinationKmsKeyName;const m=this.interceptors.indexOf(this.encryptionKeyInterceptor);if(m>-1){this.interceptors.splice(m,1)}}if(!this.shouldRetryBasedOnPreconditionAndIdempotencyStrat(u===null||u===void 0?void 0:u.preconditionOpts)){this.storage.retryOptions.autoRetry=false}if(((i=u.preconditionOpts)===null||i===void 0?void 0:i.ifGenerationMatch)!==void 0){p.ifGenerationMatch=(s=u.preconditionOpts)===null||s===void 0?void 0:s.ifGenerationMatch;delete u.preconditionOpts}this.request({method:"POST",uri:`/rewriteTo/b/${l.name}/o/${encodeURIComponent(d.name)}`,qs:p,json:u,headers:f},(m,h)=>{this.storage.retryOptions.autoRetry=this.instanceRetryValue;if(m){n(m,null,h);return}if(h.rewriteToken){const g={token:h.rewriteToken};if(p.userProject){g.userProject=p.userProject}if(p.destinationKmsKeyName){g.destinationKmsKeyName=p.destinationKmsKeyName}this.copy(d,g,n);return}n(null,d,h)})}createReadStream(t={}){t=Object.assign({decompress:true},t);const r=typeof t.start==="number"||typeof t.end==="number";const n=t.end<0;let i=void 0;let s=void 0;const o=new py.PassThroughShim;let u=true;let l=false;if(typeof t.validation==="string"){const m=t.validation.toLowerCase().trim();u=m==="crc32c";l=m==="md5"}else if(t.validation===false){u=false}const c=!r&&(u||l);if(r){if(typeof t.validation==="string"||t.validation===true){throw new Error(vf.INVALID_VALIDATION_FILE_RANGE)}u=false;l=false}const d=a(m=>{if(m){if(s===null||s===void 0?void 0:s.agent){s.agent.destroy()}o.destroy(m)}},"onComplete");const p=a((m,h,g)=>{if(m){this.getBufferFromReadable(g).then(A=>{m.message=A.toString("utf8");o.destroy(m)});return}s=g.request;const _=g.toJSON().headers;const v=_["content-encoding"]==="gzip";const S={};const E=_["x-goog-stored-content-encoding"]==="gzip"&&v||_["x-goog-stored-content-encoding"]==="identity";const b=[];if(c){if(typeof _["x-goog-hash"]==="string"){_["x-goog-hash"].split(",").forEach(A=>{const C=A.indexOf("=");const T=A.substring(0,C);const O=A.substring(C+1);S[T]=O})}i=new a_t.HashStreamValidator({crc32c:u,md5:l,crc32cGenerator:this.crc32cGenerator,crc32cExpected:S.crc32c,md5Expected:S.md5})}if(l&&!S.md5){const A=new vL(vf.MD5_NOT_AVAILABLE);A.code="MD5_NOT_AVAILABLE";o.destroy(A);return}if(E&&c&&i){b.push(i)}if(v&&t.decompress){b.push(s_t.createGunzip())}(0,yL.pipeline)(g,...b,o,d)},"onResponse");const f=a(()=>{const m={alt:"media"};if(this.generation){m.generation=this.generation}if(t.userProject){m.userProject=t.userProject}const h={"Accept-Encoding":"gzip","Cache-Control":"no-store"};if(r){const _=typeof t.start==="number"?t.start:"0";const v=typeof t.end==="number"?t.end:"";h.Range=`bytes=${n?v:`${_}-${v}`}`}const g={uri:"",headers:h,qs:m};if(t[dy.GCCL_GCS_CMD_KEY]){g[dy.GCCL_GCS_CMD_KEY]=t[dy.GCCL_GCS_CMD_KEY]}this.requestStream(g).on("error",_=>{o.destroy(_)}).on("response",_=>{o.emit("response",_);cE.util.handleResp(null,_,null,p)}).resume()},"makeRequest");o.on("reading",f);return o}createResumableUpload(t,r){var n,i;const s=typeof t==="object"?t:{};r=typeof t==="function"?t:r;const o=this.storage.retryOptions;if(((n=s===null||s===void 0?void 0:s.preconditionOpts)===null||n===void 0?void 0:n.ifGenerationMatch)===void 0&&((i=this.instancePreconditionOpts)===null||i===void 0?void 0:i.ifGenerationMatch)===void 0&&this.storage.retryOptions.idempotencyStrategy===_f.IdempotencyStrategy.RetryConditional||this.storage.retryOptions.idempotencyStrategy===_f.IdempotencyStrategy.RetryNever){o.autoRetry=false}i_t.createURI({authClient:this.storage.authClient,apiEndpoint:this.storage.apiEndpoint,bucket:this.bucket.name,customRequestOptions:this.getRequestInterceptors().reduce((u,l)=>l(u),{}),file:this.name,generation:this.generation,key:this.encryptionKey,kmsKeyName:this.kmsKeyName,metadata:s.metadata,offset:s.offset,origin:s.origin,predefinedAcl:s.predefinedAcl,private:s.private,public:s.public,userProject:s.userProject||this.userProject,retryOptions:o,params:(s===null||s===void 0?void 0:s.preconditionOpts)||this.instancePreconditionOpts,[dy.GCCL_GCS_CMD_KEY]:s[dy.GCCL_GCS_CMD_KEY]},r);this.storage.retryOptions.autoRetry=this.instanceRetryValue}createWriteStream(t={}){var r;(r=t.metadata)!==null&&r!==void 0?r:t.metadata={};if(t.contentType){t.metadata.contentType=t.contentType}if(!t.metadata.contentType||t.metadata.contentType==="auto"){const f=qcn.default.getType(this.name);if(f){t.metadata.contentType=f}}let n=t.gzip;if(n==="auto"){n=(0,Bcn.default)(t.metadata.contentType||"")}if(n){t.metadata.contentEncoding="gzip"}let i=true;let s=false;if(typeof t.validation==="string"){t.validation=t.validation.toLowerCase();i=t.validation==="crc32c";s=t.validation==="md5"}else if(t.validation===false){i=false}let o=a(f=>{u.destroy(f||void 0)},"pipelineCallback");const u=new yL.Writable({final(f){o=f;l.end()},write(f,m,h){l.write(f,m,h)}});const l=new py.PassThroughShim;const c=new a_t.HashStreamValidator({crc32c:i,md5:s,crc32cGenerator:this.crc32cGenerator,updateHashesOnly:true});const d=(0,$cn.default)();let p=false;l.on("reading",()=>u.emit("reading"));l.on("writing",()=>u.emit("writing"));d.on("progress",f=>u.emit("progress",f));d.on("response",f=>u.emit("response",f));d.once("metadata",()=>{p=true});u.on("writing",()=>{if(t.resumable===false){this.startSimpleUpload_(d,t)}else{this.startResumableUpload_(d,t)}(0,yL.pipeline)(l,n?s_t.createGzip():new yL.PassThrough,c,d,async f=>{if(f){return o(f)}if(!p){try{await new Promise((m,h)=>{d.once("metadata",m);d.once("error",h)})}catch(m){return o(m)}}try{await Lcn(this,ISe,"m",u_t).call(this,c,{crc32c:i,md5:s});o()}catch(m){o(m)}})});return u}delete(t,r){const n=typeof t==="object"?t:{};r=typeof t==="function"?t:r;this.disableAutoRetryConditionallyIdempotent_(this.methods.delete,_L.AvailableServiceObjectMethods.delete,n);super.delete(n).then(i=>r(null,...i)).catch(r).finally(()=>{this.storage.retryOptions.autoRetry=this.instanceRetryValue})}download(t,r){let n;if(typeof t==="function"){r=t;n={}}else{n=t}let i=false;const s=a((...c)=>{if(!i)r(...c);i=true},"callback");const o=n.destination;delete n.destination;const u=this.createReadStream(n);let l=false;if(o){u.on("error",s).once("data",c=>{l=true;const d=n_t.createWriteStream(o);d.write(c);u.pipe(d).on("error",s).on("finish",s)}).on("end",()=>{if(!l){const c=Buffer.alloc(0);try{n_t.writeFileSync(o,c);s(null,c)}catch(d){s(d,c)}}})}else{this.getBufferFromReadable(u).then(c=>s===null||s===void 0?void 0:s(null,c)).catch(s)}}setEncryptionKey(t){this.encryptionKey=t;this.encryptionKeyBase64=Buffer.from(t).toString("base64");this.encryptionKeyHash=Mcn.createHash("sha256").update(this.encryptionKeyBase64,"base64").digest("base64");this.encryptionKeyInterceptor={request:r=>{r.headers=r.headers||{};r.headers["x-goog-encryption-algorithm"]="AES256";r.headers["x-goog-encryption-key"]=this.encryptionKeyBase64;r.headers["x-goog-encryption-key-sha256"]=this.encryptionKeyHash;return r}};this.interceptors.push(this.encryptionKeyInterceptor);return this}getExpirationDate(t){this.getMetadata((r,n,i)=>{if(r){t(r,null,i);return}if(!n.retentionExpirationTime){const s=new Error(vf.EXPIRATION_TIME_NA);t(s,null,i);return}t(null,new Date(n.retentionExpirationTime),i)})}generateSignedPostPolicyV2(t,r){const n=(0,py.normalize)(t,r);let i=n.options;const s=n.callback;const o=new Date(i.expires);if(isNaN(o.getTime())){throw new Error(_f.ExceptionMessages.EXPIRATION_DATE_INVALID)}if(o.valueOf()<Date.now()){throw new Error(_f.ExceptionMessages.EXPIRATION_DATE_PAST)}i=Object.assign({},i);const u=[["eq","$key",this.name],{bucket:this.bucket.name}];if(Array.isArray(i.equals)){if(!Array.isArray(i.equals[0])){i.equals=[i.equals]}i.equals.forEach(p=>{if(!Array.isArray(p)||p.length!==2){throw new Error(vf.EQUALS_CONDITION_TWO_ELEMENTS)}u.push(["eq",p[0],p[1]])})}if(Array.isArray(i.startsWith)){if(!Array.isArray(i.startsWith[0])){i.startsWith=[i.startsWith]}i.startsWith.forEach(p=>{if(!Array.isArray(p)||p.length!==2){throw new Error(vf.STARTS_WITH_TWO_ELEMENTS)}u.push(["starts-with",p[0],p[1]])})}if(i.acl){u.push({acl:i.acl})}if(i.successRedirect){u.push({success_action_redirect:i.successRedirect})}if(i.successStatus){u.push({success_action_status:i.successStatus})}if(i.contentLengthRange){const p=i.contentLengthRange.min;const f=i.contentLengthRange.max;if(typeof p!=="number"||typeof f!=="number"){throw new Error(vf.CONTENT_LENGTH_RANGE_MIN_MAX)}u.push(["content-length-range",p,f])}const l={expiration:o.toISOString(),conditions:u};const c=JSON.stringify(l);const d=Buffer.from(c).toString("base64");this.storage.authClient.sign(d).then(p=>{s(null,{string:c,base64:d,signature:p})},p=>{s(new NSe.SigningError(p.message))})}generateSignedPostPolicyV4(t,r){const n=(0,py.normalize)(t,r);let i=n.options;const s=n.callback;const o=new Date(i.expires);if(isNaN(o.getTime())){throw new Error(_f.ExceptionMessages.EXPIRATION_DATE_INVALID)}if(o.valueOf()<Date.now()){throw new Error(_f.ExceptionMessages.EXPIRATION_DATE_PAST)}if(o.valueOf()-Date.now()>o_t*1e3){throw new Error(`Max allowed expiration is seven days (${o_t} seconds).`)}i=Object.assign({},i);let u=Object.assign({},i.fields);const l=new Date;const c=(0,py.formatAsUTCISO)(l,true);const d=(0,py.formatAsUTCISO)(l);const p=a(async()=>{const{client_email:f}=await this.storage.authClient.getCredentials();const m=`${f}/${d}/auto/storage/goog4_request`;u={...u,bucket:this.bucket.name,key:this.name,"x-goog-date":c,"x-goog-credential":m,"x-goog-algorithm":"GOOG4-RSA-SHA256"};const h=i.conditions||[];Object.entries(u).forEach(([E,b])=>{if(!E.startsWith("x-ignore-")){h.push({[E]:b})}});delete u.bucket;const g=(0,py.formatAsUTCISO)(o,true,"-",":");const _={conditions:h,expiration:g};const v=(0,py.unicodeJSONStringify)(_);const S=Buffer.from(v).toString("base64");try{const E=await this.storage.authClient.sign(S);const b=Buffer.from(E,"base64").toString("hex");u["policy"]=S;u["x-goog-signature"]=b;let A;if(i.virtualHostedStyle){A=`https://${this.bucket.name}.storage.googleapis.com/`}else if(i.bucketBoundHostname){A=`${i.bucketBoundHostname}/`}else{A=`${Ha.STORAGE_POST_POLICY_BASE_URL}/${this.bucket.name}/`}return{url:A,fields:u}}catch(E){throw new NSe.SigningError(E.message)}},"sign");p().then(f=>s(null,f),s)}getSignedUrl(t,r){const n=kSe[t.action];const i=(0,py.objectKeyToLowercase)(t.extensionHeaders||{});if(t.action==="resumable"){i["x-goog-resumable"]="start"}const s=Object.assign({},t.queryParams);if(typeof t.responseType==="string"){s["response-content-type"]=t.responseType}if(typeof t.promptSaveAs==="string"){s["response-content-disposition"]='attachment; filename="'+t.promptSaveAs+'"'}if(typeof t.responseDisposition==="string"){s["response-content-disposition"]=t.responseDisposition}if(this.generation){s["generation"]=this.generation.toString()}const o={method:n,expires:t.expires,accessibleAt:t.accessibleAt,extensionHeaders:i,queryParams:s,contentMd5:t.contentMd5,contentType:t.contentType};if(t.cname){o.cname=t.cname}if(t.version){o.version=t.version}if(t.virtualHostedStyle){o.virtualHostedStyle=t.virtualHostedStyle}if(!this.signer){this.signer=new NSe.URLSigner(this.storage.authClient,this.bucket,this)}this.signer.getSignedUrl(o).then(u=>r(null,u),r)}isPublic(t){var r;const n=((r=this.storage)===null||r===void 0?void 0:r.interceptors)||[];const i=this.interceptors||[];const s=n.concat(i);const o=s.reduce((u,l)=>{const c=l.request({uri:`${this.storage.apiEndpoint}/${this.bucket.name}/${encodeURIComponent(this.name)}`});Object.assign(u,c.headers);return u},{});cE.util.makeRequest({method:"GET",uri:`${this.storage.apiEndpoint}/${this.bucket.name}/${encodeURIComponent(this.name)}`,headers:o},{retryOptions:this.storage.retryOptions},u=>{if(u){const l=u;if(l.code===403){t(null,false)}else{t(u)}}else{t(null,true)}})}makePrivate(t,r){var n,i;const s=typeof t==="object"?t:{};r=typeof t==="function"?t:r;const o={predefinedAcl:s.strict?"private":"projectPrivate"};if(((n=s.preconditionOpts)===null||n===void 0?void 0:n.ifMetagenerationMatch)!==void 0){o.ifMetagenerationMatch=(i=s.preconditionOpts)===null||i===void 0?void 0:i.ifMetagenerationMatch;delete s.preconditionOpts}if(s.userProject){o.userProject=s.userProject}const u={...s.metadata,acl:null};this.setMetadata(u,o,r)}makePublic(t){t=t||cE.util.noop;this.acl.add({entity:"allUsers",role:"READER"},(r,n,i)=>{t(r,i)})}publicUrl(){return`${this.storage.apiEndpoint}/${this.bucket.name}/${encodeURIComponent(this.name)}`}move(t,r,n){const i=typeof r==="object"?r:{};n=typeof r==="function"?r:n;n=n||cE.util.noop;this.copy(t,i,(s,o,u)=>{if(s){s.message="file#copy failed with an error - "+s.message;n(s,null,u);return}if(this.name!==o.name||this.bucket.name!==o.bucket.name){this.delete(i,(l,c)=>{if(l){l.message="file#delete failed with an error - "+l.message;n(l,o,c);return}n(null,o,u)})}else{n(null,o,u)}})}rename(t,r,n){const i=typeof r==="object"?r:{};n=typeof r==="function"?r:n;n=n||cE.util.noop;this.move(t,i,n)}request(t,r){return this.parent.request.call(this,t,r)}rotateEncryptionKey(t,r){var n;r=typeof t==="function"?t:r;let i={};if(typeof t==="string"||t instanceof Buffer){i={encryptionKey:t}}else if(typeof t==="object"){i=t}const s=this.bucket.file(this.id,i);const o=((n=i.preconditionOpts)===null||n===void 0?void 0:n.ifGenerationMatch)!==void 0?{preconditionOpts:i.preconditionOpts}:{};this.copy(s,o,r)}save(t,r,n){n=typeof r==="function"?r:n;const i=typeof r==="object"?r:{};let s=this.storage.retryOptions.maxRetries;if(!this.shouldRetryBasedOnPreconditionAndIdempotencyStrat(i===null||i===void 0?void 0:i.preconditionOpts)){s=0}const o=(0,jcn.default)(async u=>{return new Promise((l,c)=>{if(s===0){this.storage.retryOptions.autoRetry=false}const d=this.createWriteStream(i);if(i.onUploadProgress){d.on("progress",i.onUploadProgress)}const p=a(f=>{if(this.storage.retryOptions.autoRetry&&this.storage.retryOptions.retryableErrorFn(f)){return c(f)}return u(f)},"handleError");if(typeof t==="string"||Buffer.isBuffer(t)){d.on("error",p).on("finish",()=>l()).end(t)}else{(0,yL.pipeline)(t,d,f=>{if(f){if(typeof t!=="function"){return u(f)}p(f)}else{l()}})}})},{retries:s,factor:this.storage.retryOptions.retryDelayMultiplier,maxTimeout:this.storage.retryOptions.maxRetryDelay*1e3,maxRetryTime:this.storage.retryOptions.totalTimeout*1e3});if(!n){return o}else{return o.then(()=>{if(n){return n()}}).catch(n)}}setMetadata(t,r,n){const i=typeof r==="object"?r:{};n=typeof r==="function"?r:n;this.disableAutoRetryConditionallyIdempotent_(this.methods.setMetadata,_L.AvailableServiceObjectMethods.setMetadata,i);super.setMetadata(t,i).then(s=>n(null,...s)).catch(n).finally(()=>{this.storage.retryOptions.autoRetry=this.instanceRetryValue})}setStorageClass(t,r,n){n=typeof r==="function"?r:n;const i=typeof r==="object"?r:{};const s={...i,storageClass:t.replace(/-/g,"_").replace(/([a-z])([A-Z])/g,(o,u,l)=>{return u+"_"+l}).toUpperCase()};this.copy(this,s,(o,u,l)=>{if(o){n(o,l);return}this.metadata=u.metadata;n(null,l)})}setUserProject(t){this.bucket.setUserProject.call(this,t)}startResumableUpload_(t,r={}){var n;(n=r.metadata)!==null&&n!==void 0?n:r.metadata={};const i=this.storage.retryOptions;if(!this.shouldRetryBasedOnPreconditionAndIdempotencyStrat(r.preconditionOpts)){i.autoRetry=false}const s=i_t.upload({authClient:this.storage.authClient,apiEndpoint:this.storage.apiEndpoint,bucket:this.bucket.name,customRequestOptions:this.getRequestInterceptors().reduce((o,u)=>u(o),{}),file:this.name,generation:this.generation,key:this.encryptionKey,kmsKeyName:this.kmsKeyName,metadata:r.metadata,offset:r.offset,predefinedAcl:r.predefinedAcl,private:r.private,public:r.public,uri:r.uri,userProject:r.userProject||this.userProject,retryOptions:{...i},params:(r===null||r===void 0?void 0:r.preconditionOpts)||this.instancePreconditionOpts,chunkSize:r===null||r===void 0?void 0:r.chunkSize,highWaterMark:r===null||r===void 0?void 0:r.highWaterMark,[dy.GCCL_GCS_CMD_KEY]:r[dy.GCCL_GCS_CMD_KEY]});s.on("response",o=>{t.emit("response",o)}).on("metadata",o=>{this.metadata=o;t.emit("metadata")}).on("finish",()=>{t.emit("complete")}).on("progress",o=>t.emit("progress",o));t.setWritable(s);this.storage.retryOptions.autoRetry=this.instanceRetryValue}startSimpleUpload_(t,r={}){var n;(n=r.metadata)!==null&&n!==void 0?n:r.metadata={};const i=this.storage.apiEndpoint;const s=this.bucket.name;const o=`${i}/upload/storage/v1/b/${s}/o`;const u={qs:{name:this.name},uri:o,[dy.GCCL_GCS_CMD_KEY]:r[dy.GCCL_GCS_CMD_KEY]};if(this.generation!==void 0){u.qs.ifGenerationMatch=this.generation}if(this.kmsKeyName!==void 0){u.qs.kmsKeyName=this.kmsKeyName}if(typeof r.timeout==="number"){u.timeout=r.timeout}if(r.userProject||this.userProject){u.qs.userProject=r.userProject||this.userProject}if(r.predefinedAcl){u.qs.predefinedAcl=r.predefinedAcl}else if(r.private){u.qs.predefinedAcl="private"}else if(r.public){u.qs.predefinedAcl="publicRead"}Object.assign(u.qs,this.instancePreconditionOpts,r.preconditionOpts);cE.util.makeWritableStream(t,{makeAuthenticatedRequest:l=>{this.request(l,(c,d,p)=>{if(c){t.destroy(c);return}this.metadata=d;t.emit("metadata",d);t.emit("response",p);t.emit("complete")})},metadata:r.metadata,request:u})}disableAutoRetryConditionallyIdempotent_(t,r,n){var i,s,o,u;if(typeof t==="object"&&((s=(i=t===null||t===void 0?void 0:t.reqOpts)===null||i===void 0?void 0:i.qs)===null||s===void 0?void 0:s.ifGenerationMatch)===void 0&&(n===null||n===void 0?void 0:n.ifGenerationMatch)===void 0&&r===_L.AvailableServiceObjectMethods.delete&&this.storage.retryOptions.idempotencyStrategy===_f.IdempotencyStrategy.RetryConditional||this.storage.retryOptions.idempotencyStrategy===_f.IdempotencyStrategy.RetryNever){this.storage.retryOptions.autoRetry=false}if(typeof t==="object"&&((u=(o=t===null||t===void 0?void 0:t.reqOpts)===null||o===void 0?void 0:o.qs)===null||u===void 0?void 0:u.ifMetagenerationMatch)===void 0&&(n===null||n===void 0?void 0:n.ifMetagenerationMatch)===void 0&&r===_L.AvailableServiceObjectMethods.setMetadata&&this.storage.retryOptions.idempotencyStrategy===_f.IdempotencyStrategy.RetryConditional||this.storage.retryOptions.idempotencyStrategy===_f.IdempotencyStrategy.RetryNever){this.storage.retryOptions.autoRetry=false}}async getBufferFromReadable(t){const r=[];for await(const n of t){r.push(n)}return Buffer.concat(r)}};Ha.File=WW;ISe=new WeakSet,u_t=a(async function e(t,r={}){const n=this.metadata;let i=!!(r.crc32c||r.md5);if(r.crc32c&&n.crc32c){i=!t.test("crc32c",n.crc32c)}if(r.md5&&n.md5Hash){i=!t.test("md5",n.md5Hash)}if(i){const s=[];let o="";let u="";try{await this.delete();if(r.md5&&!n.md5Hash){o="MD5_NOT_AVAILABLE";u=vf.MD5_NOT_AVAILABLE}else{o="FILE_NO_UPLOAD";u=vf.UPLOAD_MISMATCH}}catch(c){const d=c;o="FILE_NO_UPLOAD_DELETE";u=`${vf.UPLOAD_MISMATCH_DELETE_FAIL}${d.message}`;s.push(d)}const l=new vL(u);l.code=o;l.errors=s;throw l}return true},"_File_validateIntegrity");(0,Fcn.promisifyAll)(WW,{exclude:["cloudStorageURI","publicUrl","request","save","setEncryptionKey","shouldRetryBasedOnPreconditionAndIdempotencyStrat","getBufferFromReadable"]})});var LSe=y(sO=>{"use strict";Object.defineProperty(sO,"__esModule",{value:true});sO.Iam=sO.IAMExceptionMessages=void 0;var Hcn=I0();var DSe=P0();var QW;(function(e){e["POLICY_OBJECT_REQUIRED"]="A policy object is required.";e["PERMISSIONS_REQUIRED"]="Permissions are required."})(QW||(sO.IAMExceptionMessages=QW={}));var ZW=class{static{a(this,"Iam")}constructor(t){this.request_=t.request.bind(t);this.resourceId_="buckets/"+t.getId()}getPolicy(t,r){const{options:n,callback:i}=(0,DSe.normalize)(t,r);const s={};if(n.userProject){s.userProject=n.userProject}if(n.requestedPolicyVersion!==null&&n.requestedPolicyVersion!==void 0){s.optionsRequestedPolicyVersion=n.requestedPolicyVersion}this.request_({uri:"/iam",qs:s},i)}setPolicy(t,r,n){if(t===null||typeof t!=="object"){throw new Error(QW.POLICY_OBJECT_REQUIRED)}const{options:i,callback:s}=(0,DSe.normalize)(r,n);let o;if(t.etag===void 0){o=0}this.request_({method:"PUT",uri:"/iam",maxRetries:o,json:Object.assign({resourceId:this.resourceId_},t),qs:i},s)}testPermissions(t,r,n){if(!Array.isArray(t)&&typeof t!=="string"){throw new Error(QW.PERMISSIONS_REQUIRED)}const{options:i,callback:s}=(0,DSe.normalize)(r,n);const o=Array.isArray(t)?t:[t];const u=Object.assign({permissions:o},i);this.request_({uri:"/iam/testPermissions",qs:u,useQuerystring:true},(l,c)=>{if(l){s(l,null,c);return}const d=Array.isArray(c.permissions)?c.permissions:[];const p=o.reduce((f,m)=>{f[m]=d.indexOf(m)>-1;return f},{});s(null,p,c)})}};sO.Iam=ZW;(0,Hcn.promisifyAll)(ZW)});var FSe=y(tY=>{"use strict";Object.defineProperty(tY,"__esModule",{value:true});tY.Notification=void 0;var Vcn=rE();var zcn=I0();var eY=class extends Vcn.ServiceObject{static{a(this,"Notification")}constructor(t,r){const n={};const i={create:true,delete:{reqOpts:{qs:n}},get:{reqOpts:{qs:n}},getMetadata:{reqOpts:{qs:n}},exists:true};super({parent:t,baseUrl:"/notificationConfigs",id:r.toString(),createMethod:t.createNotification.bind(t),methods:i})}};tY.Notification=eY;(0,zcn.promisifyAll)(eY)});var JW=y(_u=>{"use strict";var Kcn=_u&&_u.__createBinding||(Object.create?function(e,t,r,n){if(n===void 0)n=r;var i=Object.getOwnPropertyDescriptor(t,r);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[r]}}}Object.defineProperty(e,n,i)}:function(e,t,r,n){if(n===void 0)n=r;e[n]=t[r]});var Wcn=_u&&_u.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var qSe=_u&&_u.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null){for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))Kcn(t,e,r)}Wcn(t,e);return t};var p_t=_u&&_u.__importDefault||function(e){return e&&e.__esModule?e:{"default":e}};Object.defineProperty(_u,"__esModule",{value:true});_u.Bucket=_u.BucketExceptionMessages=_u.AvailableServiceObjectMethods=_u.BucketActionToHTTPMethod=void 0;var rY=rE();var f_t=fSe();var Ycn=I0();var Xcn=qSe(require("fs"));var Jcn=qSe(hSe());var Qcn=qSe(require("path"));var l_t=p_t(_Se());var c_t=require("util");var Zcn=p_t(sL());var edn=P0();var d_t=vSe();var BSe=gL();var tdn=LSe();var rdn=FSe();var aO=nO();var ndn=TSe();var idn=require("stream");var sdn=require("url");var MSe;(function(e){e["list"]="GET"})(MSe||(_u.BucketActionToHTTPMethod=MSe={}));var oO;(function(e){e[e["setMetadata"]=0]="setMetadata";e[e["delete"]=1]="delete"})(oO||(_u.AvailableServiceObjectMethods=oO={}));var L0;(function(e){e["PROVIDE_SOURCE_FILE"]="You must provide at least one source file.";e["DESTINATION_FILE_NOT_SPECIFIED"]="A destination file must be specified.";e["CHANNEL_ID_REQUIRED"]="An ID is required to create a channel.";e["TOPIC_NAME_REQUIRED"]="A valid topic name is required.";e["CONFIGURATION_OBJECT_PREFIX_REQUIRED"]="A configuration object with a prefix is required.";e["SPECIFY_FILE_NAME"]="A file name must be specified.";e["METAGENERATION_NOT_PROVIDED"]="A metageneration must be provided.";e["SUPPLY_NOTIFICATION_ID"]="You must supply a notification ID."})(L0||(_u.BucketExceptionMessages=L0={}));var EL=class e extends rY.ServiceObject{static{a(this,"Bucket")}getFilesStream(t){return new idn.Readable}constructor(t,r,n){var i,s,o,u;n=n||{};r=r.replace(/^gs:\/\//,"").replace(/\/+$/,"");const l={};if((i=n===null||n===void 0?void 0:n.preconditionOpts)===null||i===void 0?void 0:i.ifGenerationMatch){l.ifGenerationMatch=n.preconditionOpts.ifGenerationMatch}if((s=n===null||n===void 0?void 0:n.preconditionOpts)===null||s===void 0?void 0:s.ifGenerationNotMatch){l.ifGenerationNotMatch=n.preconditionOpts.ifGenerationNotMatch}if((o=n===null||n===void 0?void 0:n.preconditionOpts)===null||o===void 0?void 0:o.ifMetagenerationMatch){l.ifMetagenerationMatch=n.preconditionOpts.ifMetagenerationMatch}if((u=n===null||n===void 0?void 0:n.preconditionOpts)===null||u===void 0?void 0:u.ifMetagenerationNotMatch){l.ifMetagenerationNotMatch=n.preconditionOpts.ifMetagenerationNotMatch}const c=n.userProject;if(typeof c==="string"){l.userProject=c}const d={create:{reqOpts:{qs:l}},delete:{reqOpts:{qs:l}},exists:{reqOpts:{qs:l}},get:{reqOpts:{qs:l}},getMetadata:{reqOpts:{qs:l}},setMetadata:{reqOpts:{qs:l}}};super({parent:t,baseUrl:"/b",id:r,createMethod:t.createBucket.bind(t),methods:d});this.name=r;this.storage=t;this.userProject=n.userProject;this.acl=new d_t.Acl({request:this.request.bind(this),pathPrefix:"/acl"});this.acl.default=new d_t.Acl({request:this.request.bind(this),pathPrefix:"/defaultObjectAcl"});this.crc32cGenerator=n.crc32cGenerator||this.storage.crc32cGenerator;this.iam=new tdn.Iam(this);this.getFilesStream=f_t.paginator.streamify("getFiles");this.instanceRetryValue=t.retryOptions.autoRetry;this.instancePreconditionOpts=n===null||n===void 0?void 0:n.preconditionOpts}get cloudStorageURI(){const t=new sdn.URL("gs://");t.host=this.name;return t}addLifecycleRule(t,r,n){let i={};if(typeof r==="function"){n=r}else if(r){i=r}i=i||{};const s=Array.isArray(t)?t:[t];for(const o of s){if(o.condition.createdBefore instanceof Date){o.condition.createdBefore=o.condition.createdBefore.toISOString().replace(/T.+$/,"")}if(o.condition.customTimeBefore instanceof Date){o.condition.customTimeBefore=o.condition.customTimeBefore.toISOString().replace(/T.+$/,"")}if(o.condition.noncurrentTimeBefore instanceof Date){o.condition.noncurrentTimeBefore=o.condition.noncurrentTimeBefore.toISOString().replace(/T.+$/,"")}}if(i.append===false){this.setMetadata({lifecycle:{rule:s}},i,n);return}this.getMetadata((o,u)=>{var l,c;if(o){n(o);return}const d=Array.isArray((l=u.lifecycle)===null||l===void 0?void 0:l.rule)?(c=u.lifecycle)===null||c===void 0?void 0:c.rule:[];this.setMetadata({lifecycle:{rule:d.concat(s)}},i,n)})}combine(t,r,n,i){var s;if(!Array.isArray(t)||t.length===0){throw new Error(L0.PROVIDE_SOURCE_FILE)}if(!r){throw new Error(L0.DESTINATION_FILE_NOT_SPECIFIED)}let o={};if(typeof n==="function"){i=n}else if(n){o=n}this.disableAutoRetryConditionallyIdempotent_(this.methods.setMetadata,oO.setMetadata,o);const u=a(d=>{if(d instanceof BSe.File){return d}return this.file(d)},"convertToFile");t=t.map(u);const l=u(r);i=i||rY.util.noop;if(!l.metadata.contentType){const d=Jcn.contentType(l.name);if(d){l.metadata.contentType=d}}let c=this.storage.retryOptions.maxRetries;if(((s=l===null||l===void 0?void 0:l.instancePreconditionOpts)===null||s===void 0?void 0:s.ifGenerationMatch)===void 0&&o.ifGenerationMatch===void 0&&this.storage.retryOptions.idempotencyStrategy===aO.IdempotencyStrategy.RetryConditional||this.storage.retryOptions.idempotencyStrategy===aO.IdempotencyStrategy.RetryNever){c=0}if(o.ifGenerationMatch===void 0){Object.assign(o,l.instancePreconditionOpts,o)}l.request({method:"POST",uri:"/compose",maxRetries:c,json:{destination:{contentType:l.metadata.contentType},sourceObjects:t.map(d=>{const p={name:d.name};if(d.metadata&&d.metadata.generation){p.generation=parseInt(d.metadata.generation.toString())}return p})},qs:o},(d,p)=>{this.storage.retryOptions.autoRetry=this.instanceRetryValue;if(d){i(d,null,p);return}i(null,l,p)})}createChannel(t,r,n,i){if(typeof t!=="string"){throw new Error(L0.CHANNEL_ID_REQUIRED)}let s={};if(typeof n==="function"){i=n}else if(n){s=n}this.request({method:"POST",uri:"/o/watch",json:Object.assign({id:t,type:"web_hook"},r),qs:s},(o,u)=>{if(o){i(o,null,u);return}const l=u.resourceId;const c=this.storage.channel(t,l);c.metadata=u;i(null,c,u)})}createNotification(t,r,n){let i={};if(typeof r==="function"){n=r}else if(r){i=r}const s=t!==null&&typeof t==="object";if(s&&rY.util.isCustomType(t,"pubsub/topic")){t=t.name}if(typeof t!=="string"){throw new Error(L0.TOPIC_NAME_REQUIRED)}const o=Object.assign({topic:t},i);if(o.topic.indexOf("projects")!==0){o.topic="projects/{{projectId}}/topics/"+o.topic}o.topic="//pubsub.googleapis.com/"+o.topic;if(!o.payloadFormat){o.payloadFormat="JSON_API_V1"}const u={};if(o.userProject){u.userProject=o.userProject;delete o.userProject}this.request({method:"POST",uri:"/notificationConfigs",json:(0,edn.convertObjKeysToSnakeCase)(o),qs:u,maxRetries:0},(l,c)=>{if(l){n(l,null,c);return}const d=this.notification(c.id);d.metadata=c;n(null,d,c)})}deleteFiles(t,r){let n={};if(typeof t==="function"){r=t}else if(t){n=t}const i=10;const s=1e3;const o=[];const u=a(l=>{return l.delete(n).catch(c=>{if(!n.force){throw c}o.push(c)})},"deleteFile");(async()=>{try{let l=[];const c=(0,l_t.default)(i);const d=this.getFilesStream(n);for await(const p of d){if(l.length>=s){await Promise.all(l);l=[]}l.push(c(()=>u(p)).catch(f=>{d.destroy();throw f}))}await Promise.all(l);r(o.length>0?o:null)}catch(l){r(l);return}})()}deleteLabels(t,r,n){let i=new Array;let s={};if(typeof t==="function"){n=t}else if(typeof t==="string"){i=[t]}else if(Array.isArray(t)){i=t}else if(t){s=t}if(typeof r==="function"){n=r}else if(r){s=r}const o=a(u=>{const l=u.reduce((c,d)=>{c[d]=null;return c},{});if((s===null||s===void 0?void 0:s.ifMetagenerationMatch)!==void 0){this.setLabels(l,s,n)}else{this.setLabels(l,n)}},"deleteLabels");if(i.length===0){this.getLabels((u,l)=>{if(u){n(u);return}o(Object.keys(l))})}else{o(i)}}disableRequesterPays(t,r){let n={};if(typeof t==="function"){r=t}else if(t){n=t}this.setMetadata({billing:{requesterPays:false}},n,r)}enableLogging(t,r){if(!t||typeof t==="function"||typeof t.prefix==="undefined"){throw new Error(L0.CONFIGURATION_OBJECT_PREFIX_REQUIRED)}let n=this.id;if(t.bucket&&t.bucket instanceof e){n=t.bucket.id}else if(t.bucket&&typeof t.bucket==="string"){n=t.bucket}const i={};if(t===null||t===void 0?void 0:t.ifMetagenerationMatch){i.ifMetagenerationMatch=t.ifMetagenerationMatch}if(t===null||t===void 0?void 0:t.ifMetagenerationNotMatch){i.ifMetagenerationNotMatch=t.ifMetagenerationNotMatch}(async()=>{try{const[s]=await this.iam.getPolicy();s.bindings.push({members:["group:cloud-storage-analytics@google.com"],role:"roles/storage.objectCreator"});await this.iam.setPolicy(s);this.setMetadata({logging:{logBucket:n,logObjectPrefix:t.prefix}},i,r)}catch(s){r(s);return}})()}enableRequesterPays(t,r){let n={};if(typeof t==="function"){r=t}else if(t){n=t}this.setMetadata({billing:{requesterPays:true}},n,r)}file(t,r){if(!t){throw Error(L0.SPECIFY_FILE_NAME)}return new BSe.File(this,t,r)}getFiles(t,r){let n=typeof t==="object"?t:{};if(!r){r=t}n=Object.assign({},n);this.request({uri:"/o",qs:n},(i,s)=>{if(i){r(i,null,null,s);return}const o=s.items?s.items:[];const u=o.map(c=>{const d={};if(n.versions){d.generation=c.generation}if(c.kmsKeyName){d.kmsKeyName=c.kmsKeyName}const p=this.file(c.name,d);p.metadata=c;return p});let l=null;if(s.nextPageToken){l=Object.assign({},n,{pageToken:s.nextPageToken})}r(null,u,l,s)})}getLabels(t,r){let n={};if(typeof t==="function"){r=t}else if(t){n=t}this.getMetadata(n,(i,s)=>{if(i){r(i,null);return}r(null,(s===null||s===void 0?void 0:s.labels)||{})})}getNotifications(t,r){let n={};if(typeof t==="function"){r=t}else if(t){n=t}this.request({uri:"/notificationConfigs",qs:n},(i,s)=>{if(i){r(i,null,s);return}const o=s.items?s.items:[];const u=o.map(l=>{const c=this.notification(l.id);c.metadata=l;return c});r(null,u,s)})}getSignedUrl(t,r){const n=MSe[t.action];const i={method:n,expires:t.expires,version:t.version,cname:t.cname,extensionHeaders:t.extensionHeaders||{},queryParams:t.queryParams||{}};if(!this.signer){this.signer=new ndn.URLSigner(this.storage.authClient,this)}this.signer.getSignedUrl(i).then(s=>r(null,s),r)}lock(t,r){const n=typeof t;if(n!=="number"&&n!=="string"){throw new Error(L0.METAGENERATION_NOT_PROVIDED)}this.request({method:"POST",uri:"/lockRetentionPolicy",qs:{ifMetagenerationMatch:t}},r)}makePrivate(t,r){var n,i,s,o;const u=typeof t==="object"?t:{};r=typeof t==="function"?t:r;u.private=true;const l={predefinedAcl:"projectPrivate"};if(u.userProject){l.userProject=u.userProject}if((n=u.preconditionOpts)===null||n===void 0?void 0:n.ifGenerationMatch){l.ifGenerationMatch=u.preconditionOpts.ifGenerationMatch}if((i=u.preconditionOpts)===null||i===void 0?void 0:i.ifGenerationNotMatch){l.ifGenerationNotMatch=u.preconditionOpts.ifGenerationNotMatch}if((s=u.preconditionOpts)===null||s===void 0?void 0:s.ifMetagenerationMatch){l.ifMetagenerationMatch=u.preconditionOpts.ifMetagenerationMatch}if((o=u.preconditionOpts)===null||o===void 0?void 0:o.ifMetagenerationNotMatch){l.ifMetagenerationNotMatch=u.preconditionOpts.ifMetagenerationNotMatch}const c={...u.metadata,acl:null};this.setMetadata(c,l,d=>{if(d){r(d)}const p=a(()=>{if(u.includeFiles){return(0,c_t.promisify)(this.makeAllFilesPublicPrivate_).call(this,u)}return Promise.resolve([])},"internalCall");p().then(f=>r(null,f)).catch(r)})}makePublic(t,r){const n=typeof t==="object"?t:{};r=typeof t==="function"?t:r;const i={public:true,...n};this.acl.add({entity:"allUsers",role:"READER"}).then(()=>{return this.acl.default.add({entity:"allUsers",role:"READER"})}).then(()=>{if(i.includeFiles){return(0,c_t.promisify)(this.makeAllFilesPublicPrivate_).call(this,i)}return[]}).then(s=>r(null,s),r)}notification(t){if(!t){throw new Error(L0.SUPPLY_NOTIFICATION_ID)}return new rdn.Notification(this,t)}removeRetentionPeriod(t,r){const n=typeof t==="object"?t:{};r=typeof t==="function"?t:r;this.setMetadata({retentionPolicy:null},n,r)}request(t,r){if(this.userProject&&(!t.qs||!t.qs.userProject)){t.qs={...t.qs,userProject:this.userProject}}return super.request(t,r)}setLabels(t,r,n){const i=typeof r==="object"?r:{};n=typeof r==="function"?r:n;n=n||rY.util.noop;this.setMetadata({labels:t},i,n)}setMetadata(t,r,n){const i=typeof r==="object"?r:{};n=typeof r==="function"?r:n;this.disableAutoRetryConditionallyIdempotent_(this.methods.setMetadata,oO.setMetadata,i);super.setMetadata(t,i).then(s=>n(null,...s)).catch(n).finally(()=>{this.storage.retryOptions.autoRetry=this.instanceRetryValue})}setRetentionPeriod(t,r,n){const i=typeof r==="object"?r:{};n=typeof r==="function"?r:n;this.setMetadata({retentionPolicy:{retentionPeriod:t.toString()}},i,n)}setCorsConfiguration(t,r,n){const i=typeof r==="object"?r:{};n=typeof r==="function"?r:n;this.setMetadata({cors:t},i,n)}setStorageClass(t,r,n){const i=typeof r==="object"?r:{};n=typeof r==="function"?r:n;t=t.replace(/-/g,"_").replace(/([a-z])([A-Z])/g,(s,o,u)=>{return o+"_"+u}).toUpperCase();this.setMetadata({storageClass:t},i,n)}setUserProject(t){this.userProject=t;const r=["create","delete","exists","get","getMetadata","setMetadata"];r.forEach(n=>{const i=this.methods[n];if(typeof i==="object"){if(typeof i.reqOpts==="object"){Object.assign(i.reqOpts.qs,{userProject:t})}else{i.reqOpts={qs:{userProject:t}}}}})}upload(t,r,n){var i,s;const o=a(d=>{const p=(0,Zcn.default)(async f=>{await new Promise((m,h)=>{var g,_;if(d===0&&((_=(g=c===null||c===void 0?void 0:c.storage)===null||g===void 0?void 0:g.retryOptions)===null||_===void 0?void 0:_.autoRetry)){c.storage.retryOptions.autoRetry=false}const v=c.createWriteStream(u);if(u.onUploadProgress){v.on("progress",u.onUploadProgress)}Xcn.createReadStream(t).on("error",f).pipe(v).on("error",S=>{if(this.storage.retryOptions.autoRetry&&this.storage.retryOptions.retryableErrorFn(S)){return h(S)}else{return f(S)}}).on("finish",()=>{return m()})})},{retries:d,factor:this.storage.retryOptions.retryDelayMultiplier,maxTimeout:this.storage.retryOptions.maxRetryDelay*1e3,maxRetryTime:this.storage.retryOptions.totalTimeout*1e3});if(!n){return p}else{return p.then(()=>{if(n){return n(null,c,c.metadata)}}).catch(n)}},"upload");if(global["GCLOUD_SANDBOX_ENV"]){return}let u=typeof r==="object"?r:{};n=typeof r==="function"?r:n;u=Object.assign({metadata:{}},u);let l=this.storage.retryOptions.maxRetries;if(((i=u===null||u===void 0?void 0:u.preconditionOpts)===null||i===void 0?void 0:i.ifGenerationMatch)===void 0&&((s=this.instancePreconditionOpts)===null||s===void 0?void 0:s.ifGenerationMatch)===void 0&&this.storage.retryOptions.idempotencyStrategy===aO.IdempotencyStrategy.RetryConditional||this.storage.retryOptions.idempotencyStrategy===aO.IdempotencyStrategy.RetryNever){l=0}let c;if(u.destination instanceof BSe.File){c=u.destination}else if(u.destination!==null&&typeof u.destination==="string"){c=this.file(u.destination,{encryptionKey:u.encryptionKey,kmsKeyName:u.kmsKeyName,preconditionOpts:this.instancePreconditionOpts})}else{const d=Qcn.basename(t);c=this.file(d,{encryptionKey:u.encryptionKey,kmsKeyName:u.kmsKeyName,preconditionOpts:this.instancePreconditionOpts})}o(l)}makeAllFilesPublicPrivate_(t,r){const n=10;const i=[];const s=[];const o=typeof t==="object"?t:{};r=typeof t==="function"?t:r;const u=a(async l=>{try{await(o.public?l.makePublic():l.makePrivate(o));s.push(l)}catch(c){if(!o.force){throw c}i.push(c)}},"processFile");this.getFiles(o).then(([l])=>{const c=(0,l_t.default)(n);const d=l.map(p=>{return c(()=>u(p))});return Promise.all(d)}).then(()=>r(i.length>0?i:null,s),l=>r(l,s))}getId(){return this.id}disableAutoRetryConditionallyIdempotent_(t,r,n){var i,s;if(typeof t==="object"&&((s=(i=t===null||t===void 0?void 0:t.reqOpts)===null||i===void 0?void 0:i.qs)===null||s===void 0?void 0:s.ifMetagenerationMatch)===void 0&&(n===null||n===void 0?void 0:n.ifMetagenerationMatch)===void 0&&(r===oO.setMetadata||r===oO.delete)&&this.storage.retryOptions.idempotencyStrategy===aO.IdempotencyStrategy.RetryConditional){this.storage.retryOptions.autoRetry=false}else if(this.storage.retryOptions.idempotencyStrategy===aO.IdempotencyStrategy.RetryNever){this.storage.retryOptions.autoRetry=false}}};_u.Bucket=EL;f_t.paginator.extend(EL,"getFiles");(0,Ycn.promisifyAll)(EL,{exclude:["cloudStorageURI","request","file","notification"]})});var USe=y(iY=>{"use strict";Object.defineProperty(iY,"__esModule",{value:true});iY.Channel=void 0;var m_t=rE();var adn=I0();var nY=class extends m_t.ServiceObject{static{a(this,"Channel")}constructor(t,r,n){const i={parent:t,baseUrl:"/channels",id:"",methods:{}};super(i);this.metadata.id=r;this.metadata.resourceId=n}stop(t){t=t||m_t.util.noop;this.request({method:"POST",uri:"/stop",json:this.metadata},(r,n)=>{t(r,n)})}};iY.Channel=nY;(0,adn.promisifyAll)(nY)});var $Se=y(aY=>{"use strict";Object.defineProperty(aY,"__esModule",{value:true});aY.HmacKey=void 0;var odn=rE();var udn=nO();var ldn=I0();var sY=class extends odn.ServiceObject{static{a(this,"HmacKey")}constructor(t,r,n){const i={delete:true,get:true,getMetadata:true,setMetadata:{reqOpts:{method:"PUT"}}};const s=n&&n.projectId||t.projectId;super({parent:t,id:r,baseUrl:`/projects/${s}/hmacKeys`,methods:i});this.storage=t;this.instanceRetryValue=t.retryOptions.autoRetry}setMetadata(t,r,n){if(this.storage.retryOptions.idempotencyStrategy!==udn.IdempotencyStrategy.RetryAlways){this.storage.retryOptions.autoRetry=false}const i=typeof r==="object"?r:{};n=typeof r==="function"?r:n;super.setMetadata(t,i).then(s=>n(null,...s)).catch(n).finally(()=>{this.storage.retryOptions.autoRetry=this.instanceRetryValue})}};aY.HmacKey=sY;(0,ldn.promisifyAll)(sY)});var nO=y(cs=>{"use strict";Object.defineProperty(cs,"__esModule",{value:true});cs.Storage=cs.RETRYABLE_ERR_FN_DEFAULT=cs.MAX_RETRY_DELAY_DEFAULT=cs.TOTAL_TIMEOUT_DEFAULT=cs.RETRY_DELAY_MULTIPLIER_DEFAULT=cs.MAX_RETRY_DEFAULT=cs.AUTO_RETRY_DEFAULT=cs.PROTOCOL_REGEX=cs.StorageExceptionMessages=cs.ExceptionMessages=cs.IdempotencyStrategy=void 0;var cdn=rE();var jSe=fSe();var ddn=I0();var h_t=require("stream");var y_t=JW();var __t=USe();var pdn=gL();var oY=P0();var fdn=KR();var v_t=$Se();var mdn=hL();var GSe;(function(e){e[e["RetryAlways"]=0]="RetryAlways";e[e["RetryConditional"]=1]="RetryConditional";e[e["RetryNever"]=2]="RetryNever"})(GSe||(cs.IdempotencyStrategy=GSe={}));var g_t;(function(e){e["EXPIRATION_DATE_INVALID"]="The expiration date provided was invalid.";e["EXPIRATION_DATE_PAST"]="An expiration date cannot be in the past."})(g_t||(cs.ExceptionMessages=g_t={}));var uO;(function(e){e["BUCKET_NAME_REQUIRED"]="A bucket name is needed to use Cloud Storage.";e["BUCKET_NAME_REQUIRED_CREATE"]="A name is required to create a bucket.";e["HMAC_SERVICE_ACCOUNT"]="The first argument must be a service account email to create an HMAC key.";e["HMAC_ACCESS_ID"]="An access ID is needed to create an HmacKey object."})(uO||(cs.StorageExceptionMessages=uO={}));cs.PROTOCOL_REGEX=/^(\w*):\/\//;cs.AUTO_RETRY_DEFAULT=true;cs.MAX_RETRY_DEFAULT=3;cs.RETRY_DELAY_MULTIPLIER_DEFAULT=2;cs.TOTAL_TIMEOUT_DEFAULT=600;cs.MAX_RETRY_DELAY_DEFAULT=64;var hdn=GSe.RetryConditional;var gdn=a(function(e){var t;const r=a(n=>{return n.includes("eai_again")||n==="econnreset"||n==="unexpected connection closure"||n==="epipe"||n==="socket connection timeout"},"isConnectionProblem");if(e){if([408,429,500,502,503,504].indexOf(e.code)!==-1){return true}if(typeof e.code==="string"){if(["408","429","500","502","503","504"].indexOf(e.code)!==-1){return true}const n=e.code.toLowerCase();if(r(n)){return true}}if(e.errors){for(const n of e.errors){const i=(t=n===null||n===void 0?void 0:n.reason)===null||t===void 0?void 0:t.toString().toLowerCase();if(i&&r(i)){return true}}}}return false},"RETRYABLE_ERR_FN_DEFAULT");cs.RETRYABLE_ERR_FN_DEFAULT=gdn;var F0=class e extends cdn.Service{static{a(this,"Storage")}getBucketsStream(){return new h_t.Readable}getHmacKeysStream(){return new h_t.Readable}constructor(t={}){var r,n,i,s,o,u,l,c,d,p,f,m,h,g;let _="https://storage.googleapis.com";let v=false;const S=process.env.STORAGE_EMULATOR_HOST;if(typeof S==="string"){_=e.sanitizeEndpoint(S);v=true}if(t.apiEndpoint){_=e.sanitizeEndpoint(t.apiEndpoint);v=true}t=Object.assign({},t,{apiEndpoint:_});const E=S||`${t.apiEndpoint}/storage/v1`;const b={apiEndpoint:t.apiEndpoint,retryOptions:{autoRetry:((r=t.retryOptions)===null||r===void 0?void 0:r.autoRetry)!==void 0?(n=t.retryOptions)===null||n===void 0?void 0:n.autoRetry:cs.AUTO_RETRY_DEFAULT,maxRetries:((i=t.retryOptions)===null||i===void 0?void 0:i.maxRetries)?(s=t.retryOptions)===null||s===void 0?void 0:s.maxRetries:cs.MAX_RETRY_DEFAULT,retryDelayMultiplier:((o=t.retryOptions)===null||o===void 0?void 0:o.retryDelayMultiplier)?(u=t.retryOptions)===null||u===void 0?void 0:u.retryDelayMultiplier:cs.RETRY_DELAY_MULTIPLIER_DEFAULT,totalTimeout:((l=t.retryOptions)===null||l===void 0?void 0:l.totalTimeout)?(c=t.retryOptions)===null||c===void 0?void 0:c.totalTimeout:cs.TOTAL_TIMEOUT_DEFAULT,maxRetryDelay:((d=t.retryOptions)===null||d===void 0?void 0:d.maxRetryDelay)?(p=t.retryOptions)===null||p===void 0?void 0:p.maxRetryDelay:cs.MAX_RETRY_DELAY_DEFAULT,retryableErrorFn:((f=t.retryOptions)===null||f===void 0?void 0:f.retryableErrorFn)?(m=t.retryOptions)===null||m===void 0?void 0:m.retryableErrorFn:cs.RETRYABLE_ERR_FN_DEFAULT,idempotencyStrategy:((h=t.retryOptions)===null||h===void 0?void 0:h.idempotencyStrategy)!==void 0?(g=t.retryOptions)===null||g===void 0?void 0:g.idempotencyStrategy:hdn},baseUrl:E,customEndpoint:v,useAuthWithCustomEndpoint:t===null||t===void 0?void 0:t.useAuthWithCustomEndpoint,projectIdRequired:false,scopes:["https://www.googleapis.com/auth/iam","https://www.googleapis.com/auth/cloud-platform","https://www.googleapis.com/auth/devstorage.full_control"],packageJson:(0,fdn.getPackageJSON)()};super(b,t);this.acl=e.acl;this.crc32cGenerator=t.crc32cGenerator||mdn.CRC32C_DEFAULT_VALIDATOR_GENERATOR;this.retryOptions=b.retryOptions;this.getBucketsStream=jSe.paginator.streamify("getBuckets");this.getHmacKeysStream=jSe.paginator.streamify("getHmacKeys")}static sanitizeEndpoint(t){if(!cs.PROTOCOL_REGEX.test(t)){t=`https://${t}`}return t.replace(/\/+$/,"")}bucket(t,r){if(!t){throw new Error(uO.BUCKET_NAME_REQUIRED)}return new y_t.Bucket(this,t,r)}channel(t,r){return new __t.Channel(this,t,r)}createBucket(t,r,n){if(!t){throw new Error(uO.BUCKET_NAME_REQUIRED_CREATE)}let i;if(!n){n=r;i={}}else{i=r}const s={...i,name:t};const o={archive:"ARCHIVE",coldline:"COLDLINE",dra:"DURABLE_REDUCED_AVAILABILITY",multiRegional:"MULTI_REGIONAL",nearline:"NEARLINE",regional:"REGIONAL",standard:"STANDARD"};const u=Object.keys(o);for(const c of u){if(s[c]){if(i.storageClass&&i.storageClass!==c){throw new Error(`Both \`${c}\` and \`storageClass\` were provided.`)}s.storageClass=o[c];delete s[c]}}if(s.requesterPays){s.billing={requesterPays:s.requesterPays};delete s.requesterPays}const l={project:this.projectId};if(s.userProject){l.userProject=s.userProject;delete s.userProject}this.request({method:"POST",uri:"/b",qs:l,json:s},(c,d)=>{if(c){n(c,null,d);return}const p=this.bucket(t);p.metadata=d;n(null,p,d)})}createHmacKey(t,r,n){if(typeof t!=="string"){throw new Error(uO.HMAC_SERVICE_ACCOUNT)}const{options:i,callback:s}=(0,oY.normalize)(r,n);const o=Object.assign({},i,{serviceAccountEmail:t});const u=o.projectId||this.projectId;delete o.projectId;this.request({method:"POST",uri:`/projects/${u}/hmacKeys`,qs:o,maxRetries:0},(l,c)=>{if(l){s(l,null,null,c);return}const d=c.metadata;const p=this.hmacKey(d.accessId,{projectId:d.projectId});p.metadata=c.metadata;s(null,p,c.secret,c)})}getBuckets(t,r){const{options:n,callback:i}=(0,oY.normalize)(t,r);n.project=n.project||this.projectId;this.request({uri:"/b",qs:n},(s,o)=>{if(s){i(s,null,null,o);return}const u=o.items?o.items:[];const l=u.map(d=>{const p=this.bucket(d.id);p.metadata=d;return p});const c=o.nextPageToken?Object.assign({},n,{pageToken:o.nextPageToken}):null;i(null,l,c,o)})}getHmacKeys(t,r){const{options:n,callback:i}=(0,oY.normalize)(t,r);const s=Object.assign({},n);const o=s.projectId||this.projectId;delete s.projectId;this.request({uri:`/projects/${o}/hmacKeys`,qs:s},(u,l)=>{if(u){i(u,null,null,l);return}const c=l.items?l.items:[];const d=c.map(f=>{const m=this.hmacKey(f.accessId,{projectId:f.projectId});m.metadata=f;return m});const p=l.nextPageToken?Object.assign({},n,{pageToken:l.nextPageToken}):null;i(null,d,p,l)})}getServiceAccount(t,r){const{options:n,callback:i}=(0,oY.normalize)(t,r);this.request({uri:`/projects/${this.projectId}/serviceAccount`,qs:n},(s,o)=>{if(s){i(s,null,o);return}const u={};for(const l in o){if(o.hasOwnProperty(l)){const c=l.replace(/_(\w)/g,(d,p)=>p.toUpperCase());u[c]=o[l]}}i(null,u,o)})}hmacKey(t,r){if(!t){throw new Error(uO.HMAC_ACCESS_ID)}return new v_t.HmacKey(this,t,r)}};cs.Storage=F0;F0.Bucket=y_t.Bucket;F0.Channel=__t.Channel;F0.File=pdn.File;F0.HmacKey=v_t.HmacKey;F0.acl={OWNER_ROLE:"OWNER",READER_ROLE:"READER",WRITER_ROLE:"WRITER"};jSe.paginator.extend(F0,["getBuckets","getHmacKeys"]);(0,ddn.promisifyAll)(F0,{exclude:["bucket","channel","hmacKey"]})});var uY=y(fy=>{"use strict";var E_t=":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";var ydn=E_t+"\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040";var b_t="["+E_t+"]["+ydn+"]*";var _dn=new RegExp("^"+b_t+"$");var vdn=a(function(e,t){const r=[];let n=t.exec(e);while(n){const i=[];i.startIndex=t.lastIndex-n[0].length;const s=n.length;for(let o=0;o<s;o++){i.push(n[o])}r.push(i);n=t.exec(e)}return r},"getAllMatches");var Edn=a(function(e){const t=_dn.exec(e);return!(t===null||typeof t==="undefined")},"isName");fy.isExist=function(e){return typeof e!=="undefined"};fy.isEmptyObject=function(e){return Object.keys(e).length===0};fy.merge=function(e,t,r){if(t){const n=Object.keys(t);const i=n.length;for(let s=0;s<i;s++){if(r==="strict"){e[n[s]]=[t[n[s]]]}else{e[n[s]]=t[n[s]]}}}};fy.getValue=function(e){if(fy.isExist(e)){return e}else{return""}};fy.isName=Edn;fy.getAllMatches=vdn;fy.nameRegexp=b_t});var VSe=y(T_t=>{"use strict";var HSe=uY();var bdn={allowBooleanAttributes:false,unpairedTags:[]};T_t.validate=function(e,t){t=Object.assign({},bdn,t);const r=[];let n=false;let i=false;if(e[0]==="\uFEFF"){e=e.substr(1)}for(let s=0;s<e.length;s++){if(e[s]==="<"&&e[s+1]==="?"){s+=2;s=A_t(e,s);if(s.err)return s}else if(e[s]==="<"){let o=s;s++;if(e[s]==="!"){s=C_t(e,s);continue}else{let u=false;if(e[s]==="/"){u=true;s++}let l="";for(;s<e.length&&e[s]!==">"&&e[s]!==" "&&e[s]!==" "&&e[s]!=="\n"&&e[s]!=="\r";s++){l+=e[s]}l=l.trim();if(l[l.length-1]==="/"){l=l.substring(0,l.length-1);s--}if(!Odn(l)){let p;if(l.trim().length===0){p="Invalid space after '<'."}else{p="Tag '"+l+"' is an invalid name."}return Io("InvalidTag",p,dd(e,s))}const c=Cdn(e,s);if(c===false){return Io("InvalidAttr","Attributes for '"+l+"' have open quote.",dd(e,s))}let d=c.value;s=c.index;if(d[d.length-1]==="/"){const p=s-d.length;d=d.substring(0,d.length-1);const f=w_t(d,t);if(f===true){n=true}else{return Io(f.err.code,f.err.msg,dd(e,p+f.err.line))}}else if(u){if(!c.tagClosed){return Io("InvalidTag","Closing tag '"+l+"' doesn't have proper closing.",dd(e,s))}else if(d.trim().length>0){return Io("InvalidTag","Closing tag '"+l+"' can't have attributes or invalid starting.",dd(e,o))}else{const p=r.pop();if(l!==p.tagName){let f=dd(e,p.tagStartPos);return Io("InvalidTag","Expected closing tag '"+p.tagName+"' (opened in line "+f.line+", col "+f.col+") instead of closing tag '"+l+"'.",dd(e,o))}if(r.length==0){i=true}}}else{const p=w_t(d,t);if(p!==true){return Io(p.err.code,p.err.msg,dd(e,s-d.length+p.err.line))}if(i===true){return Io("InvalidXml","Multiple possible root nodes found.",dd(e,s))}else if(t.unpairedTags.indexOf(l)!==-1){}else{r.push({tagName:l,tagStartPos:o})}n=true}for(s++;s<e.length;s++){if(e[s]==="<"){if(e[s+1]==="!"){s++;s=C_t(e,s);continue}else if(e[s+1]==="?"){s=A_t(e,++s);if(s.err)return s}else{break}}else if(e[s]==="&"){const p=xdn(e,s);if(p==-1)return Io("InvalidChar","char '&' is not expected.",dd(e,s));s=p}else{if(i===true&&!S_t(e[s])){return Io("InvalidXml","Extra text at the end",dd(e,s))}}}if(e[s]==="<"){s--}}}else{if(S_t(e[s])){continue}return Io("InvalidChar","char '"+e[s]+"' is not expected.",dd(e,s))}}if(!n){return Io("InvalidXml","Start tag expected.",1)}else if(r.length==1){return Io("InvalidTag","Unclosed tag '"+r[0].tagName+"'.",dd(e,r[0].tagStartPos))}else if(r.length>0){return Io("InvalidXml","Invalid '"+JSON.stringify(r.map(s=>s.tagName),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1})}return true};function S_t(e){return e===" "||e===" "||e==="\n"||e==="\r"}a(S_t,"isWhiteSpace");function A_t(e,t){const r=t;for(;t<e.length;t++){if(e[t]=="?"||e[t]==" "){const n=e.substr(r,t-r);if(t>5&&n==="xml"){return Io("InvalidXml","XML declaration allowed only at the start of the document.",dd(e,t))}else if(e[t]=="?"&&e[t+1]==">"){t++;break}else{continue}}}return t}a(A_t,"readPI");function C_t(e,t){if(e.length>t+5&&e[t+1]==="-"&&e[t+2]==="-"){for(t+=3;t<e.length;t++){if(e[t]==="-"&&e[t+1]==="-"&&e[t+2]===">"){t+=2;break}}}else if(e.length>t+8&&e[t+1]==="D"&&e[t+2]==="O"&&e[t+3]==="C"&&e[t+4]==="T"&&e[t+5]==="Y"&&e[t+6]==="P"&&e[t+7]==="E"){let r=1;for(t+=8;t<e.length;t++){if(e[t]==="<"){r++}else if(e[t]===">"){r--;if(r===0){break}}}}else if(e.length>t+9&&e[t+1]==="["&&e[t+2]==="C"&&e[t+3]==="D"&&e[t+4]==="A"&&e[t+5]==="T"&&e[t+6]==="A"&&e[t+7]==="["){for(t+=8;t<e.length;t++){if(e[t]==="]"&&e[t+1]==="]"&&e[t+2]===">"){t+=2;break}}}return t}a(C_t,"readCommentAndCDATA");var Sdn='"';var Adn="'";function Cdn(e,t){let r="";let n="";let i=false;for(;t<e.length;t++){if(e[t]===Sdn||e[t]===Adn){if(n===""){n=e[t]}else if(n!==e[t]){}else{n=""}}else if(e[t]===">"){if(n===""){i=true;break}}r+=e[t]}if(n!==""){return false}return{value:r,index:t,tagClosed:i}}a(Cdn,"readAttributeStr");var wdn=new RegExp(`(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['"])(([\\s\\S])*?)\\5)?`,"g");function w_t(e,t){const r=HSe.getAllMatches(e,wdn);const n={};for(let i=0;i<r.length;i++){if(r[i][1].length===0){return Io("InvalidAttr","Attribute '"+r[i][2]+"' has no space in starting.",bL(r[i]))}else if(r[i][3]!==void 0&&r[i][4]===void 0){return Io("InvalidAttr","Attribute '"+r[i][2]+"' is without value.",bL(r[i]))}else if(r[i][3]===void 0&&!t.allowBooleanAttributes){return Io("InvalidAttr","boolean attribute '"+r[i][2]+"' is not allowed.",bL(r[i]))}const s=r[i][2];if(!Rdn(s)){return Io("InvalidAttr","Attribute '"+s+"' is an invalid name.",bL(r[i]))}if(!n.hasOwnProperty(s)){n[s]=1}else{return Io("InvalidAttr","Attribute '"+s+"' is repeated.",bL(r[i]))}}return true}a(w_t,"validateAttributeString");function Tdn(e,t){let r=/\d/;if(e[t]==="x"){t++;r=/[\da-fA-F]/}for(;t<e.length;t++){if(e[t]===";")return t;if(!e[t].match(r))break}return-1}a(Tdn,"validateNumberAmpersand");function xdn(e,t){t++;if(e[t]===";")return-1;if(e[t]==="#"){t++;return Tdn(e,t)}let r=0;for(;t<e.length;t++,r++){if(e[t].match(/\w/)&&r<20)continue;if(e[t]===";")break;return-1}return t}a(xdn,"validateAmpersand");function Io(e,t,r){return{err:{code:e,msg:t,line:r.line||r,col:r.col}}}a(Io,"getErrorObject");function Rdn(e){return HSe.isName(e)}a(Rdn,"validateAttrName");function Odn(e){return HSe.isName(e)}a(Odn,"validateTagName");function dd(e,t){const r=e.substring(0,t).split(/\r?\n/);return{line:r.length,col:r[r.length-1].length+1}}a(dd,"getLineNumberForPosition");function bL(e){return e.startIndex+e[1].length}a(bL,"getPositionFromMatch")});var R_t=y(zSe=>{var x_t={preserveOrder:false,attributeNamePrefix:"@_",attributesGroupName:false,textNodeName:"#text",ignoreAttributes:true,removeNSPrefix:false,allowBooleanAttributes:false,parseTagValue:true,parseAttributeValue:false,trimValues:true,cdataPropName:false,numberParseOptions:{hex:true,leadingZeros:true,eNotation:true},tagValueProcessor:function(e,t){return t},attributeValueProcessor:function(e,t){return t},stopNodes:[],alwaysCreateTextNode:false,isArray:()=>false,commentPropName:false,unpairedTags:[],processEntities:true,htmlEntities:false,ignoreDeclaration:false,ignorePiTags:false,transformTagName:false,transformAttributeName:false,updateTag:function(e,t,r){return e}};var Pdn=a(function(e){return Object.assign({},x_t,e)},"buildOptions");zSe.buildOptions=Pdn;zSe.defaultOptions=x_t});var P_t=y((nNs,O_t)=>{"use strict";var KSe=class{static{a(this,"XmlNode")}constructor(t){this.tagname=t;this.child=[];this[":@"]={}}add(t,r){if(t==="__proto__")t="#__proto__";this.child.push({[t]:r})}addChild(t){if(t.tagname==="__proto__")t.tagname="#__proto__";if(t[":@"]&&Object.keys(t[":@"]).length>0){this.child.push({[t.tagname]:t.child,[":@"]:t[":@"]})}else{this.child.push({[t.tagname]:t.child})}}};O_t.exports=KSe});var I_t=y((sNs,N_t)=>{var Ndn=uY();function Idn(e,t){const r={};if(e[t+3]==="O"&&e[t+4]==="C"&&e[t+5]==="T"&&e[t+6]==="Y"&&e[t+7]==="P"&&e[t+8]==="E"){t=t+9;let n=1;let i=false,s=false;let o="";for(;t<e.length;t++){if(e[t]==="<"&&!s){if(i&&Ldn(e,t)){t+=7;[entityName,val,t]=kdn(e,t+1);if(val.indexOf("&")===-1)r[qdn(entityName)]={regx:RegExp(`&${entityName};`,"g"),val}}else if(i&&Fdn(e,t))t+=8;else if(i&&Bdn(e,t))t+=8;else if(i&&Mdn(e,t))t+=9;else if(Ddn)s=true;else throw new Error("Invalid DOCTYPE");n++;o=""}else if(e[t]===">"){if(s){if(e[t-1]==="-"&&e[t-2]==="-"){s=false;n--}}else{n--}if(n===0){break}}else if(e[t]==="["){i=true}else{o+=e[t]}}if(n!==0){throw new Error(`Unclosed DOCTYPE`)}}else{throw new Error(`Invalid Tag instead of DOCTYPE`)}return{entities:r,i:t}}a(Idn,"readDocType");function kdn(e,t){let r="";for(;t<e.length&&(e[t]!=="'"&&e[t]!=='"');t++){r+=e[t]}r=r.trim();if(r.indexOf(" ")!==-1)throw new Error("External entites are not supported");const n=e[t++];let i="";for(;t<e.length&&e[t]!==n;t++){i+=e[t]}return[r,i,t]}a(kdn,"readEntityExp");function Ddn(e,t){if(e[t+1]==="!"&&e[t+2]==="-"&&e[t+3]==="-")return true;return false}a(Ddn,"isComment");function Ldn(e,t){if(e[t+1]==="!"&&e[t+2]==="E"&&e[t+3]==="N"&&e[t+4]==="T"&&e[t+5]==="I"&&e[t+6]==="T"&&e[t+7]==="Y")return true;return false}a(Ldn,"isEntity");function Fdn(e,t){if(e[t+1]==="!"&&e[t+2]==="E"&&e[t+3]==="L"&&e[t+4]==="E"&&e[t+5]==="M"&&e[t+6]==="E"&&e[t+7]==="N"&&e[t+8]==="T")return true;return false}a(Fdn,"isElement");function Bdn(e,t){if(e[t+1]==="!"&&e[t+2]==="A"&&e[t+3]==="T"&&e[t+4]==="T"&&e[t+5]==="L"&&e[t+6]==="I"&&e[t+7]==="S"&&e[t+8]==="T")return true;return false}a(Bdn,"isAttlist");function Mdn(e,t){if(e[t+1]==="!"&&e[t+2]==="N"&&e[t+3]==="O"&&e[t+4]==="T"&&e[t+5]==="A"&&e[t+6]==="T"&&e[t+7]==="I"&&e[t+8]==="O"&&e[t+9]==="N")return true;return false}a(Mdn,"isNotation");function qdn(e){if(Ndn.isName(e))return e;else throw new Error(`Invalid entity name ${e}`)}a(qdn,"validateEntityName");N_t.exports=Idn});var WSe=y((oNs,k_t)=>{var Udn=/^[-+]?0x[a-fA-F0-9]+$/;var $dn=/^([\-\+])?(0*)(\.[0-9]+([eE]\-?[0-9]+)?|[0-9]+(\.[0-9]+([eE]\-?[0-9]+)?)?)$/;if(!Number.parseInt&&window.parseInt){Number.parseInt=window.parseInt}if(!Number.parseFloat&&window.parseFloat){Number.parseFloat=window.parseFloat}var jdn={hex:true,leadingZeros:true,decimalPoint:".",eNotation:true};function Gdn(e,t={}){t=Object.assign({},jdn,t);if(!e||typeof e!=="string")return e;let r=e.trim();if(t.skipLike!==void 0&&t.skipLike.test(r))return e;else if(t.hex&&Udn.test(r)){return Number.parseInt(r,16)}else{const n=$dn.exec(r);if(n){const i=n[1];const s=n[2];let o=Hdn(n[3]);const u=n[4]||n[6];if(!t.leadingZeros&&s.length>0&&i&&r[2]!==".")return e;else if(!t.leadingZeros&&s.length>0&&!i&&r[1]!==".")return e;else{const l=Number(r);const c=""+l;if(c.search(/[eE]/)!==-1){if(t.eNotation)return l;else return e}else if(u){if(t.eNotation)return l;else return e}else if(r.indexOf(".")!==-1){if(c==="0"&&o==="")return l;else if(c===o)return l;else if(i&&c==="-"+o)return l;else return e}if(s){if(o===c)return l;else if(i+o===c)return l;else return e}if(r===c)return l;else if(r===i+c)return l;return e}}else{return e}}}a(Gdn,"toNumber");function Hdn(e){if(e&&e.indexOf(".")!==-1){e=e.replace(/0+$/,"");if(e===".")e="0";else if(e[0]===".")e="0"+e;else if(e[e.length-1]===".")e=e.substr(0,e.length-1);return e}return e}a(Hdn,"trimZeros");k_t.exports=Gdn});var L_t=y((cNs,D_t)=>{"use strict";var QSe=uY();var SL=P_t();var Vdn=I_t();var zdn=WSe();var lNs="<((!\\[CDATA\\[([\\s\\S]*?)(]]>))|((NAME:)?(NAME))([^>]*)>|((\\/)(NAME)\\s*>))([^<]*)".replace(/NAME/g,QSe.nameRegexp);var YSe=class{static{a(this,"OrderedObjParser")}constructor(t){this.options=t;this.currentNode=null;this.tagsNodeStack=[];this.docTypeEntities={};this.lastEntities={"apos":{regex:/&(apos|#39|#x27);/g,val:"'"},"gt":{regex:/&(gt|#62|#x3E);/g,val:">"},"lt":{regex:/&(lt|#60|#x3C);/g,val:"<"},"quot":{regex:/&(quot|#34|#x22);/g,val:'"'}};this.ampEntity={regex:/&(amp|#38|#x26);/g,val:"&"};this.htmlEntities={"space":{regex:/&(nbsp|#160);/g,val:" "},"cent":{regex:/&(cent|#162);/g,val:"\xA2"},"pound":{regex:/&(pound|#163);/g,val:"\xA3"},"yen":{regex:/&(yen|#165);/g,val:"\xA5"},"euro":{regex:/&(euro|#8364);/g,val:"\u20AC"},"copyright":{regex:/&(copy|#169);/g,val:"\xA9"},"reg":{regex:/&(reg|#174);/g,val:"\xAE"},"inr":{regex:/&(inr|#8377);/g,val:"\u20B9"}};this.addExternalEntities=Kdn;this.parseXml=Qdn;this.parseTextData=Wdn;this.resolveNameSpace=Ydn;this.buildAttributesMap=Jdn;this.isItStopNode=rpn;this.replaceEntitiesValue=epn;this.readStopNodeData=ipn;this.saveTextToParentTag=tpn;this.addChild=Zdn}};function Kdn(e){const t=Object.keys(e);for(let r=0;r<t.length;r++){const n=t[r];this.lastEntities[n]={regex:new RegExp("&"+n+";","g"),val:e[n]}}}a(Kdn,"addExternalEntities");function Wdn(e,t,r,n,i,s,o){if(e!==void 0){if(this.options.trimValues&&!n){e=e.trim()}if(e.length>0){if(!o)e=this.replaceEntitiesValue(e);const u=this.options.tagValueProcessor(t,e,r,i,s);if(u===null||u===void 0){return e}else if(typeof u!==typeof e||u!==e){return u}else if(this.options.trimValues){return JSe(e,this.options.parseTagValue,this.options.numberParseOptions)}else{const l=e.trim();if(l===e){return JSe(e,this.options.parseTagValue,this.options.numberParseOptions)}else{return e}}}}}a(Wdn,"parseTextData");function Ydn(e){if(this.options.removeNSPrefix){const t=e.split(":");const r=e.charAt(0)==="/"?"/":"";if(t[0]==="xmlns"){return""}if(t.length===2){e=r+t[1]}}return e}a(Ydn,"resolveNameSpace");var Xdn=new RegExp(`([^\\s=]+)\\s*(=\\s*(['"])([\\s\\S]*?)\\3)?`,"gm");function Jdn(e,t,r){if(!this.options.ignoreAttributes&&typeof e==="string"){const n=QSe.getAllMatches(e,Xdn);const i=n.length;const s={};for(let o=0;o<i;o++){const u=this.resolveNameSpace(n[o][1]);let l=n[o][4];let c=this.options.attributeNamePrefix+u;if(u.length){if(this.options.transformAttributeName){c=this.options.transformAttributeName(c)}if(c==="__proto__")c="#__proto__";if(l!==void 0){if(this.options.trimValues){l=l.trim()}l=this.replaceEntitiesValue(l);const d=this.options.attributeValueProcessor(u,l,t);if(d===null||d===void 0){s[c]=l}else if(typeof d!==typeof l||d!==l){s[c]=d}else{s[c]=JSe(l,this.options.parseAttributeValue,this.options.numberParseOptions)}}else if(this.options.allowBooleanAttributes){s[c]=true}}}if(!Object.keys(s).length){return}if(this.options.attributesGroupName){const o={};o[this.options.attributesGroupName]=s;return o}return s}}a(Jdn,"buildAttributesMap");var Qdn=a(function(e){e=e.replace(/\r\n?/g,"\n");const t=new SL("!xml");let r=t;let n="";let i="";for(let s=0;s<e.length;s++){const o=e[s];if(o==="<"){if(e[s+1]==="/"){const u=PA(e,">",s,"Closing Tag is not closed.");let l=e.substring(s+2,u).trim();if(this.options.removeNSPrefix){const p=l.indexOf(":");if(p!==-1){l=l.substr(p+1)}}if(this.options.transformTagName){l=this.options.transformTagName(l)}if(r){n=this.saveTextToParentTag(n,r,i)}const c=i.substring(i.lastIndexOf(".")+1);if(l&&this.options.unpairedTags.indexOf(l)!==-1){throw new Error(`Unpaired tag can not be used as closing tag: </${l}>`)}let d=0;if(c&&this.options.unpairedTags.indexOf(c)!==-1){d=i.lastIndexOf(".",i.lastIndexOf(".")-1);this.tagsNodeStack.pop()}else{d=i.lastIndexOf(".")}i=i.substring(0,d);r=this.tagsNodeStack.pop();n="";s=u}else if(e[s+1]==="?"){let u=XSe(e,s,false,"?>");if(!u)throw new Error("Pi Tag is not closed.");n=this.saveTextToParentTag(n,r,i);if(this.options.ignoreDeclaration&&u.tagName==="?xml"||this.options.ignorePiTags){}else{const l=new SL(u.tagName);l.add(this.options.textNodeName,"");if(u.tagName!==u.tagExp&&u.attrExpPresent){l[":@"]=this.buildAttributesMap(u.tagExp,i,u.tagName)}this.addChild(r,l,i)}s=u.closeIndex+1}else if(e.substr(s+1,3)==="!--"){const u=PA(e,"-->",s+4,"Comment is not closed.");if(this.options.commentPropName){const l=e.substring(s+4,u-2);n=this.saveTextToParentTag(n,r,i);r.add(this.options.commentPropName,[{[this.options.textNodeName]:l}])}s=u}else if(e.substr(s+1,2)==="!D"){const u=Vdn(e,s);this.docTypeEntities=u.entities;s=u.i}else if(e.substr(s+1,2)==="!["){const u=PA(e,"]]>",s,"CDATA is not closed.")-2;const l=e.substring(s+9,u);n=this.saveTextToParentTag(n,r,i);if(this.options.cdataPropName){r.add(this.options.cdataPropName,[{[this.options.textNodeName]:l}])}else{let c=this.parseTextData(l,r.tagname,i,true,false,true);if(c==void 0)c="";r.add(this.options.textNodeName,c)}s=u+2}else{let u=XSe(e,s,this.options.removeNSPrefix);let l=u.tagName;const c=u.rawTagName;let d=u.tagExp;let p=u.attrExpPresent;let f=u.closeIndex;if(this.options.transformTagName){l=this.options.transformTagName(l)}if(r&&n){if(r.tagname!=="!xml"){n=this.saveTextToParentTag(n,r,i,false)}}const m=r;if(m&&this.options.unpairedTags.indexOf(m.tagname)!==-1){r=this.tagsNodeStack.pop();i=i.substring(0,i.lastIndexOf("."))}if(l!==t.tagname){i+=i?"."+l:l}if(this.isItStopNode(this.options.stopNodes,i,l)){let h="";if(d.length>0&&d.lastIndexOf("/")===d.length-1){s=u.closeIndex}else if(this.options.unpairedTags.indexOf(l)!==-1){s=u.closeIndex}else{const _=this.readStopNodeData(e,c,f+1);if(!_)throw new Error(`Unexpected end of ${c}`);s=_.i;h=_.tagContent}const g=new SL(l);if(l!==d&&p){g[":@"]=this.buildAttributesMap(d,i,l)}if(h){h=this.parseTextData(h,l,i,true,p,true,true)}i=i.substr(0,i.lastIndexOf("."));g.add(this.options.textNodeName,h);this.addChild(r,g,i)}else{if(d.length>0&&d.lastIndexOf("/")===d.length-1){if(l[l.length-1]==="/"){l=l.substr(0,l.length-1);i=i.substr(0,i.length-1);d=l}else{d=d.substr(0,d.length-1)}if(this.options.transformTagName){l=this.options.transformTagName(l)}const h=new SL(l);if(l!==d&&p){h[":@"]=this.buildAttributesMap(d,i,l)}this.addChild(r,h,i);i=i.substr(0,i.lastIndexOf("."))}else{const h=new SL(l);this.tagsNodeStack.push(r);if(l!==d&&p){h[":@"]=this.buildAttributesMap(d,i,l)}this.addChild(r,h,i);r=h}n="";s=f}}}else{n+=e[s]}}return t.child},"parseXml");function Zdn(e,t,r){const n=this.options.updateTag(t.tagname,r,t[":@"]);if(n===false){}else if(typeof n==="string"){t.tagname=n;e.addChild(t)}else{e.addChild(t)}}a(Zdn,"addChild");var epn=a(function(e){if(this.options.processEntities){for(let t in this.docTypeEntities){const r=this.docTypeEntities[t];e=e.replace(r.regx,r.val)}for(let t in this.lastEntities){const r=this.lastEntities[t];e=e.replace(r.regex,r.val)}if(this.options.htmlEntities){for(let t in this.htmlEntities){const r=this.htmlEntities[t];e=e.replace(r.regex,r.val)}}e=e.replace(this.ampEntity.regex,this.ampEntity.val)}return e},"replaceEntitiesValue");function tpn(e,t,r,n){if(e){if(n===void 0)n=Object.keys(t.child).length===0;e=this.parseTextData(e,t.tagname,r,false,t[":@"]?Object.keys(t[":@"]).length!==0:false,n);if(e!==void 0&&e!=="")t.add(this.options.textNodeName,e);e=""}return e}a(tpn,"saveTextToParentTag");function rpn(e,t,r){const n="*."+r;for(const i in e){const s=e[i];if(n===s||t===s)return true}return false}a(rpn,"isItStopNode");function npn(e,t,r=">"){let n;let i="";for(let s=t;s<e.length;s++){let o=e[s];if(n){if(o===n)n=""}else if(o==='"'||o==="'"){n=o}else if(o===r[0]){if(r[1]){if(e[s+1]===r[1]){return{data:i,index:s}}}else{return{data:i,index:s}}}else if(o===" "){o=" "}i+=o}}a(npn,"tagExpWithClosingIndex");function PA(e,t,r,n){const i=e.indexOf(t,r);if(i===-1){throw new Error(n)}else{return i+t.length-1}}a(PA,"findClosingIndex");function XSe(e,t,r,n=">"){const i=npn(e,t+1,n);if(!i)return;let s=i.data;const o=i.index;const u=s.search(/\s/);let l=s;let c=true;if(u!==-1){l=s.substr(0,u).replace(/\s\s*$/,"");s=s.substr(u+1)}const d=l;if(r){const p=l.indexOf(":");if(p!==-1){l=l.substr(p+1);c=l!==i.data.substr(p+1)}}return{tagName:l,tagExp:s,closeIndex:o,attrExpPresent:c,rawTagName:d}}a(XSe,"readTagExp");function ipn(e,t,r){const n=r;let i=1;for(;r<e.length;r++){if(e[r]==="<"){if(e[r+1]==="/"){const s=PA(e,">",r,`${t} is not closed`);let o=e.substring(r+2,s).trim();if(o===t){i--;if(i===0){return{tagContent:e.substring(n,r),i:s}}}r=s}else if(e[r+1]==="?"){const s=PA(e,"?>",r+1,"StopNode is not closed.");r=s}else if(e.substr(r+1,3)==="!--"){const s=PA(e,"-->",r+3,"StopNode is not closed.");r=s}else if(e.substr(r+1,2)==="!["){const s=PA(e,"]]>",r,"StopNode is not closed.")-2;r=s}else{const s=XSe(e,r,">");if(s){const o=s&&s.tagName;if(o===t&&s.tagExp[s.tagExp.length-1]!=="/"){i++}r=s.closeIndex}}}}}a(ipn,"readStopNodeData");function JSe(e,t,r){if(t&&typeof e==="string"){const n=e.trim();if(n==="true")return true;else if(n==="false")return false;else return zdn(e,r)}else{if(QSe.isExist(e)){return e}else{return""}}}a(JSe,"parseValue");D_t.exports=YSe});var M_t=y(B_t=>{"use strict";function spn(e,t){return F_t(e,t)}a(spn,"prettify");function F_t(e,t,r){let n;const i={};for(let s=0;s<e.length;s++){const o=e[s];const u=apn(o);let l="";if(r===void 0)l=u;else l=r+"."+u;if(u===t.textNodeName){if(n===void 0)n=o[u];else n+=""+o[u]}else if(u===void 0){continue}else if(o[u]){let c=F_t(o[u],t,l);const d=upn(c,t);if(o[":@"]){opn(c,o[":@"],l,t)}else if(Object.keys(c).length===1&&c[t.textNodeName]!==void 0&&!t.alwaysCreateTextNode){c=c[t.textNodeName]}else if(Object.keys(c).length===0){if(t.alwaysCreateTextNode)c[t.textNodeName]="";else c=""}if(i[u]!==void 0&&i.hasOwnProperty(u)){if(!Array.isArray(i[u])){i[u]=[i[u]]}i[u].push(c)}else{if(t.isArray(u,l,d)){i[u]=[c]}else{i[u]=c}}}}if(typeof n==="string"){if(n.length>0)i[t.textNodeName]=n}else if(n!==void 0)i[t.textNodeName]=n;return i}a(F_t,"compress");function apn(e){const t=Object.keys(e);for(let r=0;r<t.length;r++){const n=t[r];if(n!==":@")return n}}a(apn,"propName");function opn(e,t,r,n){if(t){const i=Object.keys(t);const s=i.length;for(let o=0;o<s;o++){const u=i[o];if(n.isArray(u,r+"."+u,true,true)){e[u]=[t[u]]}else{e[u]=t[u]}}}}a(opn,"assignAttributes");function upn(e,t){const{textNodeName:r}=t;const n=Object.keys(e).length;if(n===0){return true}if(n===1&&(e[r]||typeof e[r]==="boolean"||e[r]===0)){return true}return false}a(upn,"isLeafTag");B_t.prettify=spn});var U_t=y((mNs,q_t)=>{var{buildOptions:lpn}=R_t();var cpn=L_t();var{prettify:dpn}=M_t();var ppn=VSe();var ZSe=class{static{a(this,"XMLParser")}constructor(t){this.externalEntities={};this.options=lpn(t)}parse(t,r){if(typeof t==="string"){}else if(t.toString){t=t.toString()}else{throw new Error("XML data is accepted in String or Bytes[] form.")}if(r){if(r===true)r={};const s=ppn.validate(t,r);if(s!==true){throw Error(`${s.err.msg}:${s.err.line}:${s.err.col}`)}}const n=new cpn(this.options);n.addExternalEntities(this.externalEntities);const i=n.parseXml(t);if(this.options.preserveOrder||i===void 0)return i;else return dpn(i,this.options)}addEntity(t,r){if(r.indexOf("&")!==-1){throw new Error("Entity value can't have '&'")}else if(t.indexOf("&")!==-1||t.indexOf(";")!==-1){throw new Error("An entity must be set without '&' and ';'. Eg. use '#xD' for '
'")}else if(r==="&"){throw new Error("An entity with value '&' is not permitted")}else{this.externalEntities[t]=r}}};q_t.exports=ZSe});var V_t=y((gNs,H_t)=>{var fpn="\n";function mpn(e,t){let r="";if(t.format&&t.indentBy.length>0){r=fpn}return j_t(e,t,"",r)}a(mpn,"toXml");function j_t(e,t,r,n){let i="";let s=false;for(let o=0;o<e.length;o++){const u=e[o];const l=hpn(u);if(l===void 0)continue;let c="";if(r.length===0)c=l;else c=`${r}.${l}`;if(l===t.textNodeName){let h=u[l];if(!gpn(c,t)){h=t.tagValueProcessor(l,h);h=G_t(h,t)}if(s){i+=n}i+=h;s=false;continue}else if(l===t.cdataPropName){if(s){i+=n}i+=`<![CDATA[${u[l][0][t.textNodeName]}]]>`;s=false;continue}else if(l===t.commentPropName){i+=n+`<!--${u[l][0][t.textNodeName]}-->`;s=true;continue}else if(l[0]==="?"){const h=$_t(u[":@"],t);const g=l==="?xml"?"":n;let _=u[l][0][t.textNodeName];_=_.length!==0?" "+_:"";i+=g+`<${l}${_}${h}?>`;s=true;continue}let d=n;if(d!==""){d+=t.indentBy}const p=$_t(u[":@"],t);const f=n+`<${l}${p}`;const m=j_t(u[l],t,c,d);if(t.unpairedTags.indexOf(l)!==-1){if(t.suppressUnpairedNode)i+=f+">";else i+=f+"/>"}else if((!m||m.length===0)&&t.suppressEmptyNode){i+=f+"/>"}else if(m&&m.endsWith(">")){i+=f+`>${m}${n}</${l}>`}else{i+=f+">";if(m&&n!==""&&(m.includes("/>")||m.includes("</"))){i+=n+t.indentBy+m+n}else{i+=m}i+=`</${l}>`}s=true}return i}a(j_t,"arrToStr");function hpn(e){const t=Object.keys(e);for(let r=0;r<t.length;r++){const n=t[r];if(!e.hasOwnProperty(n))continue;if(n!==":@")return n}}a(hpn,"propName");function $_t(e,t){let r="";if(e&&!t.ignoreAttributes){for(let n in e){if(!e.hasOwnProperty(n))continue;let i=t.attributeValueProcessor(n,e[n]);i=G_t(i,t);if(i===true&&t.suppressBooleanAttributes){r+=` ${n.substr(t.attributeNamePrefix.length)}`}else{r+=` ${n.substr(t.attributeNamePrefix.length)}="${i}"`}}}return r}a($_t,"attr_to_str");function gpn(e,t){e=e.substr(0,e.length-t.textNodeName.length-1);let r=e.substr(e.lastIndexOf(".")+1);for(let n in t.stopNodes){if(t.stopNodes[n]===e||t.stopNodes[n]==="*."+r)return true}return false}a(gpn,"isStopNode");function G_t(e,t){if(e&&e.length>0&&t.processEntities){for(let r=0;r<t.entities.length;r++){const n=t.entities[r];e=e.replace(n.regex,n.val)}}return e}a(G_t,"replaceEntitiesValue");H_t.exports=mpn});var K_t=y((_Ns,z_t)=>{"use strict";var ypn=V_t();var _pn={attributeNamePrefix:"@_",attributesGroupName:false,textNodeName:"#text",ignoreAttributes:true,cdataPropName:false,format:false,indentBy:" ",suppressEmptyNode:false,suppressUnpairedNode:true,suppressBooleanAttributes:true,tagValueProcessor:function(e,t){return t},attributeValueProcessor:function(e,t){return t},preserveOrder:false,commentPropName:false,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&"},{regex:new RegExp(">","g"),val:">"},{regex:new RegExp("<","g"),val:"<"},{regex:new RegExp("'","g"),val:"'"},{regex:new RegExp('"',"g"),val:"""}],processEntities:true,stopNodes:[],oneListGroup:false};function dE(e){this.options=Object.assign({},_pn,e);if(this.options.ignoreAttributes||this.options.attributesGroupName){this.isAttribute=function(){return false}}else{this.attrPrefixLen=this.options.attributeNamePrefix.length;this.isAttribute=bpn}this.processTextOrObjNode=vpn;if(this.options.format){this.indentate=Epn;this.tagEndChar=">\n";this.newLine="\n"}else{this.indentate=function(){return""};this.tagEndChar=">";this.newLine=""}}a(dE,"Builder");dE.prototype.build=function(e){if(this.options.preserveOrder){return ypn(e,this.options)}else{if(Array.isArray(e)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1){e={[this.options.arrayNodeName]:e}}return this.j2x(e,0).val}};dE.prototype.j2x=function(e,t){let r="";let n="";for(let i in e){if(!Object.prototype.hasOwnProperty.call(e,i))continue;if(typeof e[i]==="undefined"){if(this.isAttribute(i)){n+=""}}else if(e[i]===null){if(this.isAttribute(i)){n+=""}else if(i[0]==="?"){n+=this.indentate(t)+"<"+i+"?"+this.tagEndChar}else{n+=this.indentate(t)+"<"+i+"/"+this.tagEndChar}}else if(e[i]instanceof Date){n+=this.buildTextValNode(e[i],i,"",t)}else if(typeof e[i]!=="object"){const s=this.isAttribute(i);if(s){r+=this.buildAttrPairStr(s,""+e[i])}else{if(i===this.options.textNodeName){let o=this.options.tagValueProcessor(i,""+e[i]);n+=this.replaceEntitiesValue(o)}else{n+=this.buildTextValNode(e[i],i,"",t)}}}else if(Array.isArray(e[i])){const s=e[i].length;let o="";for(let u=0;u<s;u++){const l=e[i][u];if(typeof l==="undefined"){}else if(l===null){if(i[0]==="?")n+=this.indentate(t)+"<"+i+"?"+this.tagEndChar;else n+=this.indentate(t)+"<"+i+"/"+this.tagEndChar}else if(typeof l==="object"){if(this.options.oneListGroup){o+=this.j2x(l,t+1).val}else{o+=this.processTextOrObjNode(l,i,t)}}else{o+=this.buildTextValNode(l,i,"",t)}}if(this.options.oneListGroup){o=this.buildObjectNode(o,i,"",t)}n+=o}else{if(this.options.attributesGroupName&&i===this.options.attributesGroupName){const s=Object.keys(e[i]);const o=s.length;for(let u=0;u<o;u++){r+=this.buildAttrPairStr(s[u],""+e[i][s[u]])}}else{n+=this.processTextOrObjNode(e[i],i,t)}}}return{attrStr:r,val:n}};dE.prototype.buildAttrPairStr=function(e,t){t=this.options.attributeValueProcessor(e,""+t);t=this.replaceEntitiesValue(t);if(this.options.suppressBooleanAttributes&&t==="true"){return" "+e}else return" "+e+'="'+t+'"'};function vpn(e,t,r){const n=this.j2x(e,r+1);if(e[this.options.textNodeName]!==void 0&&Object.keys(e).length===1){return this.buildTextValNode(e[this.options.textNodeName],t,n.attrStr,r)}else{return this.buildObjectNode(n.val,t,n.attrStr,r)}}a(vpn,"processTextOrObjNode");dE.prototype.buildObjectNode=function(e,t,r,n){if(e===""){if(t[0]==="?")return this.indentate(n)+"<"+t+r+"?"+this.tagEndChar;else{return this.indentate(n)+"<"+t+r+this.closeTag(t)+this.tagEndChar}}else{let i="</"+t+this.tagEndChar;let s="";if(t[0]==="?"){s="?";i=""}if((r||r==="")&&e.indexOf("<")===-1){return this.indentate(n)+"<"+t+r+s+">"+e+i}else if(this.options.commentPropName!==false&&t===this.options.commentPropName&&s.length===0){return this.indentate(n)+`<!--${e}-->`+this.newLine}else{return this.indentate(n)+"<"+t+r+s+this.tagEndChar+e+this.indentate(n)+i}}};dE.prototype.closeTag=function(e){let t="";if(this.options.unpairedTags.indexOf(e)!==-1){if(!this.options.suppressUnpairedNode)t="/"}else if(this.options.suppressEmptyNode){t="/"}else{t=`></${e}`}return t};dE.prototype.buildTextValNode=function(e,t,r,n){if(this.options.cdataPropName!==false&&t===this.options.cdataPropName){return this.indentate(n)+`<![CDATA[${e}]]>`+this.newLine}else if(this.options.commentPropName!==false&&t===this.options.commentPropName){return this.indentate(n)+`<!--${e}-->`+this.newLine}else if(t[0]==="?"){return this.indentate(n)+"<"+t+r+"?"+this.tagEndChar}else{let i=this.options.tagValueProcessor(t,e);i=this.replaceEntitiesValue(i);if(i===""){return this.indentate(n)+"<"+t+r+this.closeTag(t)+this.tagEndChar}else{return this.indentate(n)+"<"+t+r+">"+i+"</"+t+this.tagEndChar}}};dE.prototype.replaceEntitiesValue=function(e){if(e&&e.length>0&&this.options.processEntities){for(let t=0;t<this.options.entities.length;t++){const r=this.options.entities[t];e=e.replace(r.regex,r.val)}}return e};function Epn(e){return this.options.indentBy.repeat(e)}a(Epn,"indentate");function bpn(e){if(e.startsWith(this.options.attributeNamePrefix)&&e!==this.options.textNodeName){return e.substr(this.attrPrefixLen)}else{return false}}a(bpn,"isAttribute");z_t.exports=dE});var Y_t=y((ENs,W_t)=>{"use strict";var Spn=VSe();var Apn=U_t();var Cpn=K_t();W_t.exports={XMLParser:Apn,XMLValidator:Spn,XMLBuilder:Cpn}});var evt=y(Pl=>{"use strict";var wpn=Pl&&Pl.__createBinding||(Object.create?function(e,t,r,n){if(n===void 0)n=r;var i=Object.getOwnPropertyDescriptor(t,r);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[r]}}}Object.defineProperty(e,n,i)}:function(e,t,r,n){if(n===void 0)n=r;e[n]=t[r]});var Tpn=Pl&&Pl.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var xpn=Pl&&Pl.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null){for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))wpn(t,e,r)}Tpn(t,e);return t};var NA=Pl&&Pl.__classPrivateFieldGet||function(e,t,r,n){if(r==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof t==="function"?e!==t||!n:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return r==="m"?n:r==="a"?n.call(e):n?n.value:t.get(e)};var Z_t=Pl&&Pl.__importDefault||function(e){return e&&e.__esModule?e:{"default":e}};var my;var dY;var CL;Object.defineProperty(Pl,"__esModule",{value:true});Pl.TransferManager=Pl.MultiPartUploadError=void 0;var AL=Z_t(_Se());var pE=xpn(require("path"));var lY=require("fs");var Rpn=hL();var Opn=iW();var X_t=Y_t();var cY=Z_t(sL());var Ppn=require("crypto");var eAe=TA();var J_t=P0();var Npn=KR();var Ipn=(0,Npn.getPackageJSON)();var kpn=5;var Dpn=5;var Lpn=5;var Fpn=32*1024*1024;var Bpn=32*1024*1024;var Mpn=32*1024*1024;var Q_t=5;var qpn="(?:)";var lO={UPLOAD_MANY:"tm.upload_many",DOWNLOAD_MANY:"tm.download_many",UPLOAD_SHARDED:"tm.upload_sharded",DOWNLOAD_SHARDED:"tm.download_sharded"};var Upn=a((e,t,r,n)=>{return new tAe(e,t,r,n)},"defaultMultiPartGenerator");var wL=class extends Error{static{a(this,"MultiPartUploadError")}constructor(t,r,n){super(t);this.uploadId=r;this.partsMap=n}};Pl.MultiPartUploadError=wL;var tAe=class{static{a(this,"XMLMultiPartUploadHelper")}constructor(t,r,n,i){my.add(this);this.authClient=t.storage.authClient||new Opn.GoogleAuth;this.uploadId=n||"";this.bucket=t;this.fileName=r;this.baseUrl=`https://${t.name}.${new URL(this.bucket.storage.apiEndpoint).hostname}/${r}`;this.xmlBuilder=new X_t.XMLBuilder({arrayNodeName:"Part"});this.xmlParser=new X_t.XMLParser;this.partsMap=i||new Map;this.retryOptions={retries:this.bucket.storage.retryOptions.maxRetries,factor:this.bucket.storage.retryOptions.retryDelayMultiplier,maxTimeout:this.bucket.storage.retryOptions.maxRetryDelay*1e3,maxRetryTime:this.bucket.storage.retryOptions.totalTimeout*1e3}}async initiateUpload(t={}){const r=`${this.baseUrl}?uploads`;return(0,cY.default)(async n=>{try{const i=await this.authClient.request({headers:NA(this,my,"m",dY).call(this,t),method:"POST",url:r});if(i.data&&i.data.error){throw i.data.error}const s=this.xmlParser.parse(i.data);this.uploadId=s.InitiateMultipartUploadResult.UploadId}catch(i){NA(this,my,"m",CL).call(this,i,n)}},this.retryOptions)}async uploadPart(t,r,n){const i=`${this.baseUrl}?partNumber=${t}&uploadId=${this.uploadId}`;let s=NA(this,my,"m",dY).call(this);if(n==="md5"){const o=(0,Ppn.createHash)("md5").update(r).digest("base64");s={"Content-MD5":o}}return(0,cY.default)(async o=>{try{const u=await this.authClient.request({url:i,method:"PUT",body:r,headers:s});if(u.data&&u.data.error){throw u.data.error}this.partsMap.set(t,u.headers["etag"])}catch(u){NA(this,my,"m",CL).call(this,u,o)}},this.retryOptions)}async completeUpload(){const t=`${this.baseUrl}?uploadId=${this.uploadId}`;const r=new Map([...this.partsMap.entries()].sort((s,o)=>s[0]-o[0]));const n=[];for(const s of r.entries()){n.push({PartNumber:s[0],ETag:s[1]})}const i=`<CompleteMultipartUpload>${this.xmlBuilder.build(n)}</CompleteMultipartUpload>`;return(0,cY.default)(async s=>{try{const o=await this.authClient.request({headers:NA(this,my,"m",dY).call(this),url:t,method:"POST",body:i});if(o.data&&o.data.error){throw o.data.error}return o}catch(o){NA(this,my,"m",CL).call(this,o,s);return}},this.retryOptions)}async abortUpload(){const t=`${this.baseUrl}?uploadId=${this.uploadId}`;return(0,cY.default)(async r=>{try{const n=await this.authClient.request({url:t,method:"DELETE"});if(n.data&&n.data.error){throw n.data.error}}catch(n){NA(this,my,"m",CL).call(this,n,r);return}},this.retryOptions)}};my=new WeakSet,dY=a(function e(t={}){let r=false;let n=false;for(const[i,s]of Object.entries(t)){if(i.toLocaleLowerCase().trim()==="x-goog-api-client"){r=true;if(!s.includes(lO.UPLOAD_SHARDED)){t[i]=`${s} gccl-gcs-cmd/${lO.UPLOAD_SHARDED}`}}else if(i.toLocaleLowerCase().trim()==="user-agent"){n=true}}if(!r){t["x-goog-api-client"]=`${(0,J_t.getRuntimeTrackingString)()} gccl/${Ipn.version} gccl-gcs-cmd/${lO.UPLOAD_SHARDED}`}if(!n){t["User-Agent"]=(0,J_t.getUserAgentString)()}return t},"_XMLMultiPartUploadHelper_setGoogApiClientHeaders"),CL=a(function e(t,r){if(this.bucket.storage.retryOptions.autoRetry&&this.bucket.storage.retryOptions.retryableErrorFn(t)){throw t}else{r(t)}},"_XMLMultiPartUploadHelper_handleErrorResponse");var rAe=class{static{a(this,"TransferManager")}constructor(t){this.bucket=t}async uploadManyFiles(t,r={}){var n;if(r.skipIfExists&&((n=r.passthroughOptions)===null||n===void 0?void 0:n.preconditionOpts)){r.passthroughOptions.preconditionOpts.ifGenerationMatch=0}else if(r.skipIfExists&&r.passthroughOptions===void 0){r.passthroughOptions={preconditionOpts:{ifGenerationMatch:0}}}const i=(0,AL.default)(r.concurrencyLimit||kpn);const s=[];let o=[];if(!Array.isArray(t)){for await(const u of this.getPathsFromDirectory(t)){o.push(u)}}else{o=t}for(const u of o){const l=await lY.promises.lstat(u);if(l.isDirectory()){continue}const c={...r.passthroughOptions,[eAe.GCCL_GCS_CMD_KEY]:lO.UPLOAD_MANY};c.destination=u.split(pE.sep).join(pE.posix.sep);if(r.prefix){c.destination=pE.posix.join(...r.prefix.split(pE.sep),c.destination)}s.push(i(()=>this.bucket.upload(u,c)))}return Promise.all(s)}async downloadManyFiles(t,r={}){const n=(0,AL.default)(r.concurrencyLimit||Dpn);const i=[];let s=[];if(!Array.isArray(t)){const l=await this.bucket.getFiles({prefix:t});s=l[0]}else{s=t.map(l=>{if(typeof l==="string"){return this.bucket.file(l)}return l})}const o=r.stripPrefix?`^${r.stripPrefix}`:qpn;const u=new RegExp(o,"g");for(const l of s){const c={...r.passthroughOptions,[eAe.GCCL_GCS_CMD_KEY]:lO.DOWNLOAD_MANY};if(r.prefix){c.destination=pE.join(r.prefix||"",c.destination||"",l.name)}if(r.stripPrefix){c.destination=l.name.replace(u,"")}i.push(n(()=>l.download(c)))}return Promise.all(i)}async downloadFileInChunks(t,r={}){let n=r.chunkSizeBytes||Bpn;let i=(0,AL.default)(r.concurrencyLimit||Lpn);const s=[];const o=typeof t==="string"?this.bucket.file(t):t;const u=await o.get();const l=parseInt(u[0].metadata.size.toString());if(l<Fpn){i=(0,AL.default)(1);n=l}let c=0;const d=r.destination||pE.basename(o.name);const p=await lY.promises.open(d,"w");while(c<l){const m=c;let h=c+n-1;h=h>l?l:h;s.push(i(async()=>{const g=await o.download({start:m,end:h,[eAe.GCCL_GCS_CMD_KEY]:lO.DOWNLOAD_SHARDED});return p.write(g[0],0,g[0].length,m)}));c+=n}let f;try{const m=await Promise.all(s);f=m.map(h=>h.buffer);if(r.validation==="crc32c"){await Rpn.CRC32C.fromFile(d)}return f}finally{p.close()}}async uploadFileInChunks(t,r={},n=Upn){const i=r.chunkSizeBytes||Mpn;const s=(0,AL.default)(r.concurrencyLimit||Q_t);const o=r.maxQueueSize||r.concurrencyLimit||Q_t;const u=r.uploadName||pE.basename(t);const l=n(this.bucket,u,r.uploadId,r.partsMap);let c=1;let d=[];try{if(r.uploadId===void 0){await l.initiateUpload(r.headers)}const p=l.partsMap.size*i;const f=(0,lY.createReadStream)(t,{highWaterMark:i,start:p});for await(const m of f){if(d.length>=o){await Promise.all(d);d=[]}d.push(s(()=>l.uploadPart(c++,m,r.validation)))}await Promise.all(d);return await l.completeUpload()}catch(p){if((r.autoAbortFailure===void 0||r.autoAbortFailure)&&l.uploadId){try{await l.abortUpload();return}catch(f){throw new wL(f.message,l.uploadId,l.partsMap)}}throw new wL(p.message,l.uploadId,l.partsMap)}}async*getPathsFromDirectory(t){const r=await lY.promises.readdir(t,{withFileTypes:true});for(const n of r){const i=pE.join(t,n.name);n.isDirectory()?yield*this.getPathsFromDirectory(i):yield i}}};Pl.TransferManager=rAe});var rvt=y(Gs=>{"use strict";var $pn=Gs&&Gs.__createBinding||(Object.create?function(e,t,r,n){if(n===void 0)n=r;var i=Object.getOwnPropertyDescriptor(t,r);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[r]}}}Object.defineProperty(e,n,i)}:function(e,t,r,n){if(n===void 0)n=r;e[n]=t[r]});var nAe=Gs&&Gs.__exportStar||function(e,t){for(var r in e)if(r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r))$pn(t,e,r)};Object.defineProperty(Gs,"__esModule",{value:true});Gs.Notification=Gs.Iam=Gs.HmacKey=Gs.File=Gs.Channel=Gs.Bucket=Gs.Storage=Gs.IdempotencyStrategy=Gs.ApiError=void 0;var jpn=rE();Object.defineProperty(Gs,"ApiError",{enumerable:true,get:function(){return jpn.ApiError}});var tvt=nO();Object.defineProperty(Gs,"IdempotencyStrategy",{enumerable:true,get:function(){return tvt.IdempotencyStrategy}});Object.defineProperty(Gs,"Storage",{enumerable:true,get:function(){return tvt.Storage}});var Gpn=JW();Object.defineProperty(Gs,"Bucket",{enumerable:true,get:function(){return Gpn.Bucket}});nAe(hL(),Gs);var Hpn=USe();Object.defineProperty(Gs,"Channel",{enumerable:true,get:function(){return Hpn.Channel}});var Vpn=gL();Object.defineProperty(Gs,"File",{enumerable:true,get:function(){return Vpn.File}});nAe(PSe(),Gs);var zpn=$Se();Object.defineProperty(Gs,"HmacKey",{enumerable:true,get:function(){return zpn.HmacKey}});var Kpn=LSe();Object.defineProperty(Gs,"Iam",{enumerable:true,get:function(){return Kpn.Iam}});var Wpn=FSe();Object.defineProperty(Gs,"Notification",{enumerable:true,get:function(){return Wpn.Notification}});nAe(evt(),Gs)});var sAe=y(_i=>{"use strict";var iAe=_i&&_i.__importDefault||function(e){return e&&e.__esModule?e:{"default":e}};Object.defineProperty(_i,"__esModule",{value:true});_i.deleteFolder=_i.untar=_i.tarFolderContent=_i.getParentDirFilename=_i.safePath=_i.UnsafePathError=_i.ensureDirectoryExists=_i.mkdirForFilePathIfNotExits=_i.mkdirIfNotExists=_i.listFolderContents=_i.listFolders=_i.isNotFileOrDirectory=_i.dirExists=_i.deleteFile=_i.fileExists=void 0;var nvt=iAe(require("child_process"));var mE=iAe(require("fs/promises"));var fE=iAe(require("path"));var ivt=[".git","node_modules",".yarn",".DS_Store"];async function Ypn(e){try{const t=await mE.default.stat(e);return t.isFile()}catch(t){return false}}a(Ypn,"fileExists");_i.fileExists=Ypn;async function Xpn(e,t){return await mE.default.rm(e,t)}a(Xpn,"deleteFile");_i.deleteFile=Xpn;async function fY(e){try{const t=await mE.default.stat(e);return t.isDirectory()}catch(t){return false}}a(fY,"dirExists");_i.dirExists=fY;async function Jpn(e){try{await mE.default.stat(e);return false}catch(t){return true}}a(Jpn,"isNotFileOrDirectory");_i.isNotFileOrDirectory=Jpn;function Qpn(e,t){const r=new RegExp(`(.*)(\\/${t})$|(.*)(${t}\\/)`);const n=e.match(r);if(!n){return""}const i=e.split(n[0]);return i[1]===""?"":`/${i[1]}`}a(Qpn,"getParentDirectory");async function Zpn(e){if(!await fY(e)){return[]}const t=await mE.default.readdir(e,{withFileTypes:true});const r=[];for await(const n of t){if(!ivt.includes(n.name)){if(n.isDirectory()){r.push(n.name)}}}return r}a(Zpn,"listFolders");_i.listFolders=Zpn;async function svt(e,t,r=true){const n=Qpn(e,t);const i=await mE.default.readdir(e,{withFileTypes:true});const s=[];for await(const o of i){if(!ivt.includes(o.name)||!r){if(o.isDirectory()){const u=await svt(fE.default.join(e,o.name),t,r);s.push(...u)}else{s.push(fE.default.join(n,o.name))}}}return s}a(svt,"listFolderContents");_i.listFolderContents=svt;var efn=a(async e=>{if(await fY(e)){return true}await mE.default.mkdir(e,{recursive:true})},"mkdirIfNotExists");_i.mkdirIfNotExists=efn;var tfn=a(async e=>{const t=fE.default.dirname(e);return(0,_i.mkdirIfNotExists)(t)},"mkdirForFilePathIfNotExits");_i.mkdirForFilePathIfNotExits=tfn;_i.ensureDirectoryExists=_i.mkdirForFilePathIfNotExits;var pY=class extends Error{static{a(this,"UnsafePathError")}constructor(t){super(t)}};_i.UnsafePathError=pY;function rfn(e){const t=a(r=>{if(!r.startsWith(e)){throw new pY(`Resolved path is not part of the project.`)}return r},"ensureSafePath");return{resolve:(...r)=>t(fE.default.resolve(...r))}}a(rfn,"safePath");_i.safePath=rfn;function nfn(e){return`${fE.default.basename(fE.default.dirname(e))}/${fE.default.basename(e)}`}a(nfn,"getParentDirFilename");_i.getParentDirFilename=nfn;function ifn(e,t,r,n){const i=fE.default.join(n,r);nvt.default.execSync(`tar --exclude='.git/' --exclude='dist/' -czf ${i} ${t}`,{cwd:e});return i}a(ifn,"tarFolderContent");_i.tarFolderContent=ifn;function sfn(e,t,r,n=false){nvt.default.execSync(`tar -xf ${t} ${n?"--strip-components=1 ":""}-C ${r}`,{cwd:e})}a(sfn,"untar");_i.untar=sfn;async function afn(e){if(await fY(e)){return await mE.default.rm(e,{recursive:true})}}a(afn,"deleteFolder");_i.deleteFolder=afn});var cvt=y(ti=>{"use strict";var ofn=ti&&ti.__createBinding||(Object.create?function(e,t,r,n){if(n===void 0)n=r;var i=Object.getOwnPropertyDescriptor(t,r);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[r]}}}Object.defineProperty(e,n,i)}:function(e,t,r,n){if(n===void 0)n=r;e[n]=t[r]});var ufn=ti&&ti.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var lfn=ti&&ti.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null){for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))ofn(t,e,r)}ufn(t,e);return t};var avt=ti&&ti.__importDefault||function(e){return e&&e.__esModule?e:{"default":e}};Object.defineProperty(ti,"__esModule",{value:true});ti.uploadFolderAndRemoveMissingSourceFiles=ti.cleanGCPFilePaths=ti.uploadFolder=ti.deleteDirectory=ti.deleteFile=ti.listFolderContent=ti.readFileStream=ti.fileExists=ti.getFileContents=ti.downloadFile=ti.uploadFromMemory=ti.uploadFile=ti.getBucket=ti.BucketName=void 0;var cfn=rvt();var hy=avt(require("path"));var B0=avt(qp());var mY=lfn(sAe());var IA;(function(e){e[e["Archive"]=0]="Archive";e[e["Bundle"]=1]="Bundle";e[e["SourceCode"]=2]="SourceCode";e[e["Sources"]=3]="Sources";e[e["DevPortalBuild"]=4]="DevPortalBuild"})(IA||(ti.BucketName=IA={}));function M0(e){let t;if(e===IA.Archive){if(B0.default.GCP_STORAGE_ARCHIVE_BUCKET_NAME===void 0){throw new Error(`Environment variable GCP_STORAGE_ARCHIVE_BUCKET_NAME must be set`)}t=B0.default.GCP_STORAGE_ARCHIVE_BUCKET_NAME}else if(e===IA.Bundle){if(B0.default.GCP_STORAGE_BUNDLE_BUCKET_NAME===void 0){throw new Error(`Environment variable GCP_STORAGE_BUNDLE_BUCKET_NAME must be set`)}t=B0.default.GCP_STORAGE_BUNDLE_BUCKET_NAME}else if(e===IA.SourceCode){if(B0.default.GCP_STORAGE_SOURCE_CODE_BUCKET_NAME===void 0){throw new Error(`Environment variable GCP_STORAGE_SOURCE_CODE_BUCKET_NAME must be set`)}t=B0.default.GCP_STORAGE_SOURCE_CODE_BUCKET_NAME}else if(e===IA.Sources){if(B0.default.GCP_STORAGE_SOURCES_BUCKET_NAME===void 0){throw new Error(`Environment variable GCP_STORAGE_SOURCES_BUCKET_NAME must be set`)}t=B0.default.GCP_STORAGE_SOURCES_BUCKET_NAME}else if(e===IA.DevPortalBuild){if(B0.default.GCP_STORAGE_DEV_PORTAL_BUILD_BUCKET_NAME===void 0){throw new Error(`Environment variable GCP_STORAGE_DEV_PORTAL_BUILD_BUCKET_NAME must be set`)}t=B0.default.GCP_STORAGE_DEV_PORTAL_BUILD_BUCKET_NAME}else{throw new Error("Invalid value for argument 'bucketName'")}const r=new cfn.Storage;return r.bucket(t)}a(M0,"getBucket");ti.getBucket=M0;async function aAe(e,t,r,n,i){try{await M0(e).upload(t,{destination:r,metadata:i})}catch(s){n.info(`File upload for ${e}/${r} ran into an issue`);n.error(s)}}a(aAe,"uploadFile");ti.uploadFile=aAe;async function dfn(e,t,r,n,i){try{await M0(e).file(r).save(t,i)}catch(s){n.info(`From Memory upload for ${e}/${r} ran into an issue`);n.error(s)}}a(dfn,"uploadFromMemory");ti.uploadFromMemory=dfn;async function pfn(e,t,r,n){try{const i={destination:r};await M0(e).file(t).download(i);n.info(`File ${e}/${t} successfully downloaded to ${r}`)}catch(i){n.info(`Downloading file ${e}/${t} ran into an issue`);n.error(i)}}a(pfn,"downloadFile");ti.downloadFile=pfn;async function ffn(e,t,r){try{const n=await M0(e).file(t).download();r.info(`File ${e}/${t} successfully downloaded to memory`);return n.toString()}catch(n){r.info(`Downloading file ${e}/${t} ran into an issue`);r.error(n)}}a(ffn,"getFileContents");ti.getFileContents=ffn;async function mfn(e,t,r){try{r.info(`Check if file ${e}/${t} exists in storage`);const n=await M0(e).file(t).exists();return n[0]}catch(n){r.info(`Ran into an issue while checking if a file ${e}/${t} exists in storage`);r.error(n);return false}}a(mfn,"fileExists");ti.fileExists=mfn;function hfn(e,t,r){r.info(`Reading file ${e}/${t} from storage`);return M0(e).file(t).createReadStream({decompress:true})}a(hfn,"readFileStream");ti.readFileStream=hfn;async function ovt(e,t,r){const n=new Set;try{const[i]=await M0(e).getFiles({prefix:t});for(let s=0;s<i.length;s++){const o=i[s];const u=o.name.replace(t,"");if(u===""){continue}const l=u.split("/");if(l.length>1){for(let c=0;c<l.length-1;c++){const d=`/${l[c]}`;if(!n.has(d)){n.add(d)}}}n.add(`/${u}`)}}catch(i){r.info(`Ran into an issue while listing files in ${e}/${t} storage path`);r.error(i)}return[...n]}a(ovt,"listFolderContent");ti.listFolderContent=ovt;async function uvt(e,t,r){try{r.info(`Deleting file ${e}/${t} from storage`);await M0(e).file(t).delete()}catch(n){r.warn(`Failed to delete file ${e}/${t} from storage`);r.error(n)}}a(uvt,"deleteFile");ti.deleteFile=uvt;async function gfn(e,t,r){try{r.info(`Deleting directory ${e}/${t} from storage`);await M0(e).deleteFiles({prefix:t})}catch(n){r.info(`Failed to delete directory ${e}/${t} from storage`);r.error(n)}}a(gfn,"deleteDirectory");ti.deleteDirectory=gfn;async function yfn(e,t,r,n,i){try{n.info(`Upload folder ${hy.default.basename(t)}`);if(await mY.dirExists(t)){const s=await mY.listFolderContents(t,hy.default.basename(t));if(s&&s.length>0){await Promise.all(s.map(async o=>{return await aAe(e,hy.default.join(t,o),hy.default.join(r,o),n,i)}))}}}catch(s){n.warn(`Failed to upload directory ${t} to bucket ${e}`,s)}}a(yfn,"uploadFolder");ti.uploadFolder=yfn;function lvt(e){const t=e.filter(r=>r!=="/").map(r=>r.replace(/^\/+/,""));return t}a(lvt,"cleanGCPFilePaths");ti.cleanGCPFilePaths=lvt;async function _fn(e,t,r,n,i){try{n.info(`uploadFolderAndRemoveMissingSourceFiles: upload folder ${hy.default.basename(t)}`);if(await mY.dirExists(t)){const s=await ovt(e,r,n);const o=lvt(s);const u=await mY.listFolderContents(t,hy.default.basename(t));const l=o.filter(c=>!u.includes(c)).map(c=>hy.default.join(r,c));await Promise.all(l.map(async c=>{return await uvt(e,c,n)}));await Promise.all(u.map(async c=>{return await aAe(e,hy.default.join(t,c),hy.default.join(r,c),n,i)}))}}catch(s){n.warn(`Failed to upload directory ${t} to bucket ${e}`,s)}}a(_fn,"uploadFolderAndRemoveMissingSourceFiles");ti.uploadFolderAndRemoveMissingSourceFiles=_fn});var dvt=y(hY=>{"use strict";Object.defineProperty(hY,"__esModule",{value:true});hY.graphQL=void 0;var q0=ac();async function vfn(e,t,r){const n=await fetch(`https://api.github.com/graphql`,{method:"POST",headers:{Authorization:`Bearer ${t}`},body:e});if(n.status===401){r.warn("Failed GitHub GraphQL query with status 401. User token might have been revoked directly in GitHub.");throw new q0.ApiError(q0.Problems.SOURCE_CONTROL_GH_APP_REVOKED_ACCESS)}if(n.status===403){r.warn("Failed GitHub GraphQL query with status 403. User token does not have correct permissions to query this GitHub API.");throw new q0.ApiError(q0.Problems.SOURCE_CONTROL_GH_APP_CONFIG_REQUIRED)}if(n.status===404){r.warn("Failed GitHub GraphQL query with status 404. User token has been revoked and can not query this GitHub API.");throw new q0.ApiError(q0.Problems.SOURCE_CONTROL_GH_APP_CONFIG_REQUIRED)}if(n.status===400){const i=await n.json();r.warn("Failed GitHub GraphQL query with status 400. A malformed query was ran against the GitHub API.",i);throw new q0.ApiError(q0.Problems.BAD_REQUEST)}if(n.status!==200&&n.status!==304){r.warn(`Failed GitHub GraphQL query with status ${n.status}. There was an unexpected error querying the GitHub API.`);throw new q0.ApiError(q0.Problems.SOURCE_CONTROL_GH_APP_CONFIG_REQUIRED)}return n}a(vfn,"graphQL");hY.graphQL=vfn});var yvt=y(Ef=>{"use strict";Object.defineProperty(Ef,"__esModule",{value:true});Ef.SourceControlProvider=Ef.PlanType=Ef.EnvironmentType=Ef.EnvironmentTarget=Ef.DeploymentState=void 0;var pvt;(function(e){e[e["IS_STARTING"]=0]="IS_STARTING";e[e["STARTED"]=1]="STARTED";e[e["STOPPED"]=2]="STOPPED";e[e["ERRORED"]=3]="ERRORED"})(pvt||(Ef.DeploymentState=pvt={}));var fvt;(function(e){e["CLOUDFLARE"]="CLOUDFLARE";e["KNATIVE"]="KNATIVE"})(fvt||(Ef.EnvironmentTarget=fvt={}));var mvt;(function(e){e["PRODUCTION"]="PRODUCTION";e["PREVIEW"]="PREVIEW";e["WORKING_COPY"]="WORKING_COPY"})(mvt||(Ef.EnvironmentType=mvt={}));var hvt;(function(e){e["FREE_V1"]="FREE_V1";e["BUILDER_V1"]="BUILDER_V1";e["BUSINESS_V1"]="BUSINESS_V1";e["CUSTOM"]="CUSTOM";e["EMPLOYEE"]="EMPLOYEE";e["CUSTOM_TRIAL_V1"]="CUSTOM_TRIAL_V1"})(hvt||(Ef.PlanType=hvt={}));var gvt;(function(e){e["GITHUB"]="GITHUB";e["GITLAB"]="GITLAB";e["BITBUCKET"]="BITBUCKET"})(gvt||(Ef.SourceControlProvider=gvt={}))});var vvt=y(_vt=>{"use strict";Object.defineProperty(_vt,"__esModule",{value:true})});var Evt=y(bf=>{"use strict";Object.defineProperty(bf,"__esModule",{value:true});bf.INTERNAL_ROUTE_VENDOR_TAG=bf.ZUPLO_OPEN_API_ROUTE_KEY=bf.ZUPLO_OPEN_API_PATH_KEY=bf.ZUPLO_OPEN_API_VENDOR_PREFIX=void 0;bf.ZUPLO_OPEN_API_VENDOR_PREFIX="x-zuplo";bf.ZUPLO_OPEN_API_PATH_KEY=`${bf.ZUPLO_OPEN_API_VENDOR_PREFIX}-path`;bf.ZUPLO_OPEN_API_ROUTE_KEY=`${bf.ZUPLO_OPEN_API_VENDOR_PREFIX}-route`;bf.INTERNAL_ROUTE_VENDOR_TAG="x-internal"});var bvt=y((kNs,Efn)=>{Efn.exports={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"http://schemas.zuplo.com/dev-portal.json",title:"Dev Portal Config",description:"",type:"object",required:[],additionalProperties:false,$defs:{ApiKeysConfig:{type:"object",additionalProperties:false,required:["bucketName"],properties:{bucketName:{type:"string"},apiKey:{type:"string"}}},DevPortalOAuthClientConfig:{type:"object",additionalProperties:false,required:["clientId"],properties:{clientId:{type:"string"},audience:{type:"string",description:"The audience of the API (i.e. the Zup's URL)\nOkta: not required\nAuth0: https://my-api.example.com/"}}},DevPortalOAuthClientCredentialsConfig:{type:"object",description:"This is the M2M configuration used to authenticate with OAuth provider in order to manage OAuth clients",required:["clientId","clientSecret"],additionalProperties:false,properties:{clientId:{type:"string"},clientSecret:{type:"string"}}},DevPortalAPIKeyCredentialConfig:{type:"object",description:"API Key credentials to access identity provider API",required:["apiKey"],additionalProperties:false,properties:{apiKey:{type:"string"}}},DevPortalOAuthConfig:{type:"object",description:"Settings for OAuth that is used to authenticate end-users to the developer portal and (optionally) for configuring issuing of OAuth Client Consumers using the identity provider",required:["provider","authority","jwksUrl"],additionalProperties:false,properties:{provider:{type:"string",enum:["okta","auth0","azure-ad"]},authority:{type:"string",description:"This is the full URL of the authorization server.\nOkta: https://dev-1235.okta.com/oauth2/aus123152352342\nAuth0: https://my-account.us.auth0.com\nAzure Active Directory: https://login.microsoftonline.com/{tenant}/v2.0"},jwksUrl:{type:"string",description:"The url of of the JWKS"},devPortalClient:{description:"This is the client that is used to authenticate end-users to the Zuplo developer portal",$ref:"#/$defs/DevPortalOAuthClientConfig"},managementClient:{oneOf:[{$ref:"#/$defs/DevPortalOAuthClientCredentialsConfig"},{$ref:"#/$defs/DevPortalAPIKeyCredentialConfig"}]}}},DevPortalExternalAuthConfig:{type:"object",description:"Settings for external auth that is used to authenticate end-users to the developer portal",additionalProperties:false,required:["loginUrl","provider","logoutUrl"],properties:{provider:{type:"string",enum:["external"]},loginUrl:{type:"string",description:"The URL of your external login page"},logoutUrl:{type:"string",description:"The URL of your external logout endpoint"}}},DevPortalAuthConfig:{type:"object",oneOf:[{$ref:"#/$defs/DevPortalOAuthConfig"},{$ref:"#/$defs/DevPortalExternalAuthConfig"}]}},properties:{$schema:{type:"string"},enabled:{description:"If the developer portal is enabled",type:"boolean",default:true},authentication:{description:"Authentication configuration",$ref:"#/$defs/DevPortalAuthConfig"},sitePathname:{type:"string",default:"/docs"},faviconUrl:{type:"string",description:"The favicon url"},pageTitle:{type:"string",description:"The default page title"},enableAuthentication:{type:"boolean",description:"If sign in to the developer portal is enabled."},requireAuthentication:{type:"boolean",default:false,description:"If authentication is required to access the developer portal. If false, the developer portal will be publicly accessible."},authorizePathname:{type:"string",default:"/oauth/authorize",description:"The path that starts the OAuth flow for third-party-apps"},apiKeys:{description:"Api Keys Service Configuration",$ref:"#/$defs/ApiKeysConfig"},generateExamples:{type:"boolean",default:true,description:"If false, the developer portal will no longer generate examples for endpoints that do not have examples defined"}}}});var RL=y(Ji=>{"use strict";Object.defineProperty(Ji,"__esModule",{value:true});Ji.regexpCode=Ji.getEsmExportName=Ji.getProperty=Ji.safeStringify=Ji.stringify=Ji.strConcat=Ji.addCodeArg=Ji.str=Ji._=Ji.nil=Ji._Code=Ji.Name=Ji.IDENTIFIER=Ji._CodeOrName=void 0;var TL=class{static{a(this,"_CodeOrName")}};Ji._CodeOrName=TL;Ji.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;var kA=class extends TL{static{a(this,"Name")}constructor(t){super();if(!Ji.IDENTIFIER.test(t))throw new Error("CodeGen: name must be a valid identifier");this.str=t}toString(){return this.str}emptyStr(){return false}get names(){return{[this.str]:1}}};Ji.Name=kA;var Sf=class extends TL{static{a(this,"_Code")}constructor(t){super();this._items=typeof t==="string"?[t]:t}toString(){return this.str}emptyStr(){if(this._items.length>1)return false;const t=this._items[0];return t===""||t==='""'}get str(){var t;return(t=this._str)!==null&&t!==void 0?t:this._str=this._items.reduce((r,n)=>`${r}${n}`,"")}get names(){var t;return(t=this._names)!==null&&t!==void 0?t:this._names=this._items.reduce((r,n)=>{if(n instanceof kA)r[n.str]=(r[n.str]||0)+1;return r},{})}};Ji._Code=Sf;Ji.nil=new Sf("");function Svt(e,...t){const r=[e[0]];let n=0;while(n<t.length){uAe(r,t[n]);r.push(e[++n])}return new Sf(r)}a(Svt,"_");Ji._=Svt;var oAe=new Sf("+");function Avt(e,...t){const r=[xL(e[0])];let n=0;while(n<t.length){r.push(oAe);uAe(r,t[n]);r.push(oAe,xL(e[++n]))}bfn(r);return new Sf(r)}a(Avt,"str");Ji.str=Avt;function uAe(e,t){if(t instanceof Sf)e.push(...t._items);else if(t instanceof kA)e.push(t);else e.push(Cfn(t))}a(uAe,"addCodeArg");Ji.addCodeArg=uAe;function bfn(e){let t=1;while(t<e.length-1){if(e[t]===oAe){const r=Sfn(e[t-1],e[t+1]);if(r!==void 0){e.splice(t-1,3,r);continue}e[t++]="+"}t++}}a(bfn,"optimize");function Sfn(e,t){if(t==='""')return e;if(e==='""')return t;if(typeof e=="string"){if(t instanceof kA||e[e.length-1]!=='"')return;if(typeof t!="string")return`${e.slice(0,-1)}${t}"`;if(t[0]==='"')return e.slice(0,-1)+t.slice(1);return}if(typeof t=="string"&&t[0]==='"'&&!(e instanceof kA))return`"${e}${t.slice(1)}`;return}a(Sfn,"mergeExprItems");function Afn(e,t){return t.emptyStr()?e:e.emptyStr()?t:Avt`${e}${t}`}a(Afn,"strConcat");Ji.strConcat=Afn;function Cfn(e){return typeof e=="number"||typeof e=="boolean"||e===null?e:xL(Array.isArray(e)?e.join(","):e)}a(Cfn,"interpolate");function wfn(e){return new Sf(xL(e))}a(wfn,"stringify");Ji.stringify=wfn;function xL(e){return JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}a(xL,"safeStringify");Ji.safeStringify=xL;function Tfn(e){return typeof e=="string"&&Ji.IDENTIFIER.test(e)?new Sf(`.${e}`):Svt`[${e}]`}a(Tfn,"getProperty");Ji.getProperty=Tfn;function xfn(e){if(typeof e=="string"&&Ji.IDENTIFIER.test(e)){return new Sf(`${e}`)}throw new Error(`CodeGen: invalid export name: ${e}, use explicit $id name mapping`)}a(xfn,"getEsmExportName");Ji.getEsmExportName=xfn;function Rfn(e){return new Sf(e.toString())}a(Rfn,"regexpCode");Ji.regexpCode=Rfn});var pAe=y(vc=>{"use strict";Object.defineProperty(vc,"__esModule",{value:true});vc.ValueScope=vc.ValueScopeName=vc.Scope=vc.varKinds=vc.UsedValueState=void 0;var pd=RL();var lAe=class extends Error{static{a(this,"ValueError")}constructor(t){super(`CodeGen: "code" for ${t} not defined`);this.value=t.value}};var cAe;(function(e){e[e["Started"]=0]="Started";e[e["Completed"]=1]="Completed"})(cAe=vc.UsedValueState||(vc.UsedValueState={}));vc.varKinds={const:new pd.Name("const"),let:new pd.Name("let"),var:new pd.Name("var")};var gY=class{static{a(this,"Scope")}constructor({prefixes:t,parent:r}={}){this._names={};this._prefixes=t;this._parent=r}toName(t){return t instanceof pd.Name?t:this.name(t)}name(t){return new pd.Name(this._newName(t))}_newName(t){const r=this._names[t]||this._nameGroup(t);return`${t}${r.index++}`}_nameGroup(t){var r,n;if(((n=(r=this._parent)===null||r===void 0?void 0:r._prefixes)===null||n===void 0?void 0:n.has(t))||this._prefixes&&!this._prefixes.has(t)){throw new Error(`CodeGen: prefix "${t}" is not allowed in this scope`)}return this._names[t]={prefix:t,index:0}}};vc.Scope=gY;var yY=class extends pd.Name{static{a(this,"ValueScopeName")}constructor(t,r){super(r);this.prefix=t}setValue(t,{property:r,itemIndex:n}){this.value=t;this.scopePath=(0,pd._)`.${new pd.Name(r)}[${n}]`}};vc.ValueScopeName=yY;var Ofn=(0,pd._)`\n`;var dAe=class extends gY{static{a(this,"ValueScope")}constructor(t){super(t);this._values={};this._scope=t.scope;this.opts={...t,_n:t.lines?Ofn:pd.nil}}get(){return this._scope}name(t){return new yY(t,this._newName(t))}value(t,r){var n;if(r.ref===void 0)throw new Error("CodeGen: ref must be passed in value");const i=this.toName(t);const{prefix:s}=i;const o=(n=r.key)!==null&&n!==void 0?n:r.ref;let u=this._values[s];if(u){const d=u.get(o);if(d)return d}else{u=this._values[s]=new Map}u.set(o,i);const l=this._scope[s]||(this._scope[s]=[]);const c=l.length;l[c]=r.ref;i.setValue(r,{property:s,itemIndex:c});return i}getValue(t,r){const n=this._values[t];if(!n)return;return n.get(r)}scopeRefs(t,r=this._values){return this._reduceValues(r,n=>{if(n.scopePath===void 0)throw new Error(`CodeGen: name "${n}" has no value`);return(0,pd._)`${t}${n.scopePath}`})}scopeCode(t=this._values,r,n){return this._reduceValues(t,i=>{if(i.value===void 0)throw new Error(`CodeGen: name "${i}" has no value`);return i.value.code},r,n)}_reduceValues(t,r,n={},i){let s=pd.nil;for(const o in t){const u=t[o];if(!u)continue;const l=n[o]=n[o]||new Map;u.forEach(c=>{if(l.has(c))return;l.set(c,cAe.Started);let d=r(c);if(d){const p=this.opts.es5?vc.varKinds.var:vc.varKinds.const;s=(0,pd._)`${s}${p} ${c} = ${d};${this.opts._n}`}else if(d=i===null||i===void 0?void 0:i(c)){s=(0,pd._)`${s}${d}${this.opts._n}`}else{throw new lAe(c)}l.set(c,cAe.Completed)})}return s}};vc.ValueScope=dAe});var En=y(Vn=>{"use strict";Object.defineProperty(Vn,"__esModule",{value:true});Vn.or=Vn.and=Vn.not=Vn.CodeGen=Vn.operators=Vn.varKinds=Vn.ValueScopeName=Vn.ValueScope=Vn.Scope=Vn.Name=Vn.regexpCode=Vn.stringify=Vn.getProperty=Vn.nil=Vn.strConcat=Vn.str=Vn._=void 0;var Ti=RL();var nh=pAe();var hE=RL();Object.defineProperty(Vn,"_",{enumerable:true,get:function(){return hE._}});Object.defineProperty(Vn,"str",{enumerable:true,get:function(){return hE.str}});Object.defineProperty(Vn,"strConcat",{enumerable:true,get:function(){return hE.strConcat}});Object.defineProperty(Vn,"nil",{enumerable:true,get:function(){return hE.nil}});Object.defineProperty(Vn,"getProperty",{enumerable:true,get:function(){return hE.getProperty}});Object.defineProperty(Vn,"stringify",{enumerable:true,get:function(){return hE.stringify}});Object.defineProperty(Vn,"regexpCode",{enumerable:true,get:function(){return hE.regexpCode}});Object.defineProperty(Vn,"Name",{enumerable:true,get:function(){return hE.Name}});var bY=pAe();Object.defineProperty(Vn,"Scope",{enumerable:true,get:function(){return bY.Scope}});Object.defineProperty(Vn,"ValueScope",{enumerable:true,get:function(){return bY.ValueScope}});Object.defineProperty(Vn,"ValueScopeName",{enumerable:true,get:function(){return bY.ValueScopeName}});Object.defineProperty(Vn,"varKinds",{enumerable:true,get:function(){return bY.varKinds}});Vn.operators={GT:new Ti._Code(">"),GTE:new Ti._Code(">="),LT:new Ti._Code("<"),LTE:new Ti._Code("<="),EQ:new Ti._Code("==="),NEQ:new Ti._Code("!=="),NOT:new Ti._Code("!"),OR:new Ti._Code("||"),AND:new Ti._Code("&&"),ADD:new Ti._Code("+")};var gy=class{static{a(this,"Node")}optimizeNodes(){return this}optimizeNames(t,r){return this}};var fAe=class extends gy{static{a(this,"Def")}constructor(t,r,n){super();this.varKind=t;this.name=r;this.rhs=n}render({es5:t,_n:r}){const n=t?nh.varKinds.var:this.varKind;const i=this.rhs===void 0?"":` = ${this.rhs}`;return`${n} ${this.name}${i};`+r}optimizeNames(t,r){if(!t[this.name.str])return;if(this.rhs)this.rhs=dO(this.rhs,t,r);return this}get names(){return this.rhs instanceof Ti._CodeOrName?this.rhs.names:{}}};var _Y=class extends gy{static{a(this,"Assign")}constructor(t,r,n){super();this.lhs=t;this.rhs=r;this.sideEffects=n}render({_n:t}){return`${this.lhs} = ${this.rhs};`+t}optimizeNames(t,r){if(this.lhs instanceof Ti.Name&&!t[this.lhs.str]&&!this.sideEffects)return;this.rhs=dO(this.rhs,t,r);return this}get names(){const t=this.lhs instanceof Ti.Name?{}:{...this.lhs.names};return EY(t,this.rhs)}};var mAe=class extends _Y{static{a(this,"AssignOp")}constructor(t,r,n,i){super(t,n,i);this.op=r}render({_n:t}){return`${this.lhs} ${this.op}= ${this.rhs};`+t}};var hAe=class extends gy{static{a(this,"Label")}constructor(t){super();this.label=t;this.names={}}render({_n:t}){return`${this.label}:`+t}};var gAe=class extends gy{static{a(this,"Break")}constructor(t){super();this.label=t;this.names={}}render({_n:t}){const r=this.label?` ${this.label}`:"";return`break${r};`+t}};var yAe=class extends gy{static{a(this,"Throw")}constructor(t){super();this.error=t}render({_n:t}){return`throw ${this.error};`+t}get names(){return this.error.names}};var _Ae=class extends gy{static{a(this,"AnyCode")}constructor(t){super();this.code=t}render({_n:t}){return`${this.code};`+t}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(t,r){this.code=dO(this.code,t,r);return this}get names(){return this.code instanceof Ti._CodeOrName?this.code.names:{}}};var OL=class extends gy{static{a(this,"ParentNode")}constructor(t=[]){super();this.nodes=t}render(t){return this.nodes.reduce((r,n)=>r+n.render(t),"")}optimizeNodes(){const{nodes:t}=this;let r=t.length;while(r--){const n=t[r].optimizeNodes();if(Array.isArray(n))t.splice(r,1,...n);else if(n)t[r]=n;else t.splice(r,1)}return t.length>0?this:void 0}optimizeNames(t,r){const{nodes:n}=this;let i=n.length;while(i--){const s=n[i];if(s.optimizeNames(t,r))continue;Pfn(t,s.names);n.splice(i,1)}return n.length>0?this:void 0}get names(){return this.nodes.reduce((t,r)=>FA(t,r.names),{})}};var yy=class extends OL{static{a(this,"BlockNode")}render(t){return"{"+t._n+super.render(t)+"}"+t._n}};var vAe=class extends OL{static{a(this,"Root")}};var cO=class extends yy{static{a(this,"Else")}};cO.kind="else";var DA=class e extends yy{static{a(this,"If")}constructor(t,r){super(r);this.condition=t}render(t){let r=`if(${this.condition})`+super.render(t);if(this.else)r+="else "+this.else.render(t);return r}optimizeNodes(){super.optimizeNodes();const t=this.condition;if(t===true)return this.nodes;let r=this.else;if(r){const n=r.optimizeNodes();r=this.else=Array.isArray(n)?new cO(n):n}if(r){if(t===false)return r instanceof e?r:r.nodes;if(this.nodes.length)return this;return new e(Cvt(t),r instanceof e?[r]:r.nodes)}if(t===false||!this.nodes.length)return void 0;return this}optimizeNames(t,r){var n;this.else=(n=this.else)===null||n===void 0?void 0:n.optimizeNames(t,r);if(!(super.optimizeNames(t,r)||this.else))return;this.condition=dO(this.condition,t,r);return this}get names(){const t=super.names;EY(t,this.condition);if(this.else)FA(t,this.else.names);return t}};DA.kind="if";var LA=class extends yy{static{a(this,"For")}};LA.kind="for";var EAe=class extends LA{static{a(this,"ForLoop")}constructor(t){super();this.iteration=t}render(t){return`for(${this.iteration})`+super.render(t)}optimizeNames(t,r){if(!super.optimizeNames(t,r))return;this.iteration=dO(this.iteration,t,r);return this}get names(){return FA(super.names,this.iteration.names)}};var bAe=class extends LA{static{a(this,"ForRange")}constructor(t,r,n,i){super();this.varKind=t;this.name=r;this.from=n;this.to=i}render(t){const r=t.es5?nh.varKinds.var:this.varKind;const{name:n,from:i,to:s}=this;return`for(${r} ${n}=${i}; ${n}<${s}; ${n}++)`+super.render(t)}get names(){const t=EY(super.names,this.from);return EY(t,this.to)}};var vY=class extends LA{static{a(this,"ForIter")}constructor(t,r,n,i){super();this.loop=t;this.varKind=r;this.name=n;this.iterable=i}render(t){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(t)}optimizeNames(t,r){if(!super.optimizeNames(t,r))return;this.iterable=dO(this.iterable,t,r);return this}get names(){return FA(super.names,this.iterable.names)}};var PL=class extends yy{static{a(this,"Func")}constructor(t,r,n){super();this.name=t;this.args=r;this.async=n}render(t){const r=this.async?"async ":"";return`${r}function ${this.name}(${this.args})`+super.render(t)}};PL.kind="func";var NL=class extends OL{static{a(this,"Return")}render(t){return"return "+super.render(t)}};NL.kind="return";var SAe=class extends yy{static{a(this,"Try")}render(t){let r="try"+super.render(t);if(this.catch)r+=this.catch.render(t);if(this.finally)r+=this.finally.render(t);return r}optimizeNodes(){var t,r;super.optimizeNodes();(t=this.catch)===null||t===void 0?void 0:t.optimizeNodes();(r=this.finally)===null||r===void 0?void 0:r.optimizeNodes();return this}optimizeNames(t,r){var n,i;super.optimizeNames(t,r);(n=this.catch)===null||n===void 0?void 0:n.optimizeNames(t,r);(i=this.finally)===null||i===void 0?void 0:i.optimizeNames(t,r);return this}get names(){const t=super.names;if(this.catch)FA(t,this.catch.names);if(this.finally)FA(t,this.finally.names);return t}};var IL=class extends yy{static{a(this,"Catch")}constructor(t){super();this.error=t}render(t){return`catch(${this.error})`+super.render(t)}};IL.kind="catch";var kL=class extends yy{static{a(this,"Finally")}render(t){return"finally"+super.render(t)}};kL.kind="finally";var AAe=class{static{a(this,"CodeGen")}constructor(t,r={}){this._values={};this._blockStarts=[];this._constants={};this.opts={...r,_n:r.lines?"\n":""};this._extScope=t;this._scope=new nh.Scope({parent:t});this._nodes=[new vAe]}toString(){return this._root.render(this.opts)}name(t){return this._scope.name(t)}scopeName(t){return this._extScope.name(t)}scopeValue(t,r){const n=this._extScope.value(t,r);const i=this._values[n.prefix]||(this._values[n.prefix]=new Set);i.add(n);return n}getScopeValue(t,r){return this._extScope.getValue(t,r)}scopeRefs(t){return this._extScope.scopeRefs(t,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(t,r,n,i){const s=this._scope.toName(r);if(n!==void 0&&i)this._constants[s.str]=n;this._leafNode(new fAe(t,s,n));return s}const(t,r,n){return this._def(nh.varKinds.const,t,r,n)}let(t,r,n){return this._def(nh.varKinds.let,t,r,n)}var(t,r,n){return this._def(nh.varKinds.var,t,r,n)}assign(t,r,n){return this._leafNode(new _Y(t,r,n))}add(t,r){return this._leafNode(new mAe(t,Vn.operators.ADD,r))}code(t){if(typeof t=="function")t();else if(t!==Ti.nil)this._leafNode(new _Ae(t));return this}object(...t){const r=["{"];for(const[n,i]of t){if(r.length>1)r.push(",");r.push(n);if(n!==i||this.opts.es5){r.push(":");(0,Ti.addCodeArg)(r,i)}}r.push("}");return new Ti._Code(r)}if(t,r,n){this._blockNode(new DA(t));if(r&&n){this.code(r).else().code(n).endIf()}else if(r){this.code(r).endIf()}else if(n){throw new Error('CodeGen: "else" body without "then" body')}return this}elseIf(t){return this._elseNode(new DA(t))}else(){return this._elseNode(new cO)}endIf(){return this._endBlockNode(DA,cO)}_for(t,r){this._blockNode(t);if(r)this.code(r).endFor();return this}for(t,r){return this._for(new EAe(t),r)}forRange(t,r,n,i,s=this.opts.es5?nh.varKinds.var:nh.varKinds.let){const o=this._scope.toName(t);return this._for(new bAe(s,o,r,n),()=>i(o))}forOf(t,r,n,i=nh.varKinds.const){const s=this._scope.toName(t);if(this.opts.es5){const o=r instanceof Ti.Name?r:this.var("_arr",r);return this.forRange("_i",0,(0,Ti._)`${o}.length`,u=>{this.var(s,(0,Ti._)`${o}[${u}]`);n(s)})}return this._for(new vY("of",i,s,r),()=>n(s))}forIn(t,r,n,i=this.opts.es5?nh.varKinds.var:nh.varKinds.const){if(this.opts.ownProperties){return this.forOf(t,(0,Ti._)`Object.keys(${r})`,n)}const s=this._scope.toName(t);return this._for(new vY("in",i,s,r),()=>n(s))}endFor(){return this._endBlockNode(LA)}label(t){return this._leafNode(new hAe(t))}break(t){return this._leafNode(new gAe(t))}return(t){const r=new NL;this._blockNode(r);this.code(t);if(r.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(NL)}try(t,r,n){if(!r&&!n)throw new Error('CodeGen: "try" without "catch" and "finally"');const i=new SAe;this._blockNode(i);this.code(t);if(r){const s=this.name("e");this._currNode=i.catch=new IL(s);r(s)}if(n){this._currNode=i.finally=new kL;this.code(n)}return this._endBlockNode(IL,kL)}throw(t){return this._leafNode(new yAe(t))}block(t,r){this._blockStarts.push(this._nodes.length);if(t)this.code(t).endBlock(r);return this}endBlock(t){const r=this._blockStarts.pop();if(r===void 0)throw new Error("CodeGen: not in self-balancing block");const n=this._nodes.length-r;if(n<0||t!==void 0&&n!==t){throw new Error(`CodeGen: wrong number of nodes: ${n} vs ${t} expected`)}this._nodes.length=r;return this}func(t,r=Ti.nil,n,i){this._blockNode(new PL(t,r,n));if(i)this.code(i).endFunc();return this}endFunc(){return this._endBlockNode(PL)}optimize(t=1){while(t-- >0){this._root.optimizeNodes();this._root.optimizeNames(this._root.names,this._constants)}}_leafNode(t){this._currNode.nodes.push(t);return this}_blockNode(t){this._currNode.nodes.push(t);this._nodes.push(t)}_endBlockNode(t,r){const n=this._currNode;if(n instanceof t||r&&n instanceof r){this._nodes.pop();return this}throw new Error(`CodeGen: not in block "${r?`${t.kind}/${r.kind}`:t.kind}"`)}_elseNode(t){const r=this._currNode;if(!(r instanceof DA)){throw new Error('CodeGen: "else" without "if"')}this._currNode=r.else=t;return this}get _root(){return this._nodes[0]}get _currNode(){const t=this._nodes;return t[t.length-1]}set _currNode(t){const r=this._nodes;r[r.length-1]=t}};Vn.CodeGen=AAe;function FA(e,t){for(const r in t)e[r]=(e[r]||0)+(t[r]||0);return e}a(FA,"addNames");function EY(e,t){return t instanceof Ti._CodeOrName?FA(e,t.names):e}a(EY,"addExprNames");function dO(e,t,r){if(e instanceof Ti.Name)return n(e);if(!i(e))return e;return new Ti._Code(e._items.reduce((s,o)=>{if(o instanceof Ti.Name)o=n(o);if(o instanceof Ti._Code)s.push(...o._items);else s.push(o);return s},[]));function n(s){const o=r[s.str];if(o===void 0||t[s.str]!==1)return s;delete t[s.str];return o}a(n,"replaceName");function i(s){return s instanceof Ti._Code&&s._items.some(o=>o instanceof Ti.Name&&t[o.str]===1&&r[o.str]!==void 0)}a(i,"canOptimize")}a(dO,"optimizeExpr");function Pfn(e,t){for(const r in t)e[r]=(e[r]||0)-(t[r]||0)}a(Pfn,"subtractNames");function Cvt(e){return typeof e=="boolean"||typeof e=="number"||e===null?!e:(0,Ti._)`!${CAe(e)}`}a(Cvt,"not");Vn.not=Cvt;var Nfn=wvt(Vn.operators.AND);function Ifn(...e){return e.reduce(Nfn)}a(Ifn,"and");Vn.and=Ifn;var kfn=wvt(Vn.operators.OR);function Dfn(...e){return e.reduce(kfn)}a(Dfn,"or");Vn.or=Dfn;function wvt(e){return(t,r)=>t===Ti.nil?r:r===Ti.nil?t:(0,Ti._)`${CAe(t)} ${e} ${CAe(r)}`}a(wvt,"mappend");function CAe(e){return e instanceof Ti.Name?e:(0,Ti._)`(${e})`}a(CAe,"par")});var ui=y(zn=>{"use strict";Object.defineProperty(zn,"__esModule",{value:true});zn.checkStrictMode=zn.getErrorPath=zn.Type=zn.useFunc=zn.setEvaluated=zn.evaluatedPropsToName=zn.mergeEvaluated=zn.eachItem=zn.unescapeJsonPointer=zn.escapeJsonPointer=zn.escapeFragment=zn.unescapeFragment=zn.schemaRefOrVal=zn.schemaHasRulesButRef=zn.schemaHasRules=zn.checkUnknownRules=zn.alwaysValidSchema=zn.toHash=void 0;var Hs=En();var Lfn=RL();function Ffn(e){const t={};for(const r of e)t[r]=true;return t}a(Ffn,"toHash");zn.toHash=Ffn;function Bfn(e,t){if(typeof t=="boolean")return t;if(Object.keys(t).length===0)return true;Rvt(e,t);return!Ovt(t,e.self.RULES.all)}a(Bfn,"alwaysValidSchema");zn.alwaysValidSchema=Bfn;function Rvt(e,t=e.schema){const{opts:r,self:n}=e;if(!r.strictSchema)return;if(typeof t==="boolean")return;const i=n.RULES.keywords;for(const s in t){if(!i[s])kvt(e,`unknown keyword: "${s}"`)}}a(Rvt,"checkUnknownRules");zn.checkUnknownRules=Rvt;function Ovt(e,t){if(typeof e=="boolean")return!e;for(const r in e)if(t[r])return true;return false}a(Ovt,"schemaHasRules");zn.schemaHasRules=Ovt;function Mfn(e,t){if(typeof e=="boolean")return!e;for(const r in e)if(r!=="$ref"&&t.all[r])return true;return false}a(Mfn,"schemaHasRulesButRef");zn.schemaHasRulesButRef=Mfn;function qfn({topSchemaRef:e,schemaPath:t},r,n,i){if(!i){if(typeof r=="number"||typeof r=="boolean")return r;if(typeof r=="string")return(0,Hs._)`${r}`}return(0,Hs._)`${e}${t}${(0,Hs.getProperty)(n)}`}a(qfn,"schemaRefOrVal");zn.schemaRefOrVal=qfn;function Ufn(e){return Pvt(decodeURIComponent(e))}a(Ufn,"unescapeFragment");zn.unescapeFragment=Ufn;function $fn(e){return encodeURIComponent(wAe(e))}a($fn,"escapeFragment");zn.escapeFragment=$fn;function wAe(e){if(typeof e=="number")return`${e}`;return e.replace(/~/g,"~0").replace(/\//g,"~1")}a(wAe,"escapeJsonPointer");zn.escapeJsonPointer=wAe;function Pvt(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}a(Pvt,"unescapeJsonPointer");zn.unescapeJsonPointer=Pvt;function jfn(e,t){if(Array.isArray(e)){for(const r of e)t(r)}else{t(e)}}a(jfn,"eachItem");zn.eachItem=jfn;function Tvt({mergeNames:e,mergeToName:t,mergeValues:r,resultToName:n}){return(i,s,o,u)=>{const l=o===void 0?s:o instanceof Hs.Name?(s instanceof Hs.Name?e(i,s,o):t(i,s,o),o):s instanceof Hs.Name?(t(i,o,s),s):r(s,o);return u===Hs.Name&&!(l instanceof Hs.Name)?n(i,l):l}}a(Tvt,"makeMergeEvaluated");zn.mergeEvaluated={props:Tvt({mergeNames:(e,t,r)=>e.if((0,Hs._)`${r} !== true && ${t} !== undefined`,()=>{e.if((0,Hs._)`${t} === true`,()=>e.assign(r,true),()=>e.assign(r,(0,Hs._)`${r} || {}`).code((0,Hs._)`Object.assign(${r}, ${t})`))}),mergeToName:(e,t,r)=>e.if((0,Hs._)`${r} !== true`,()=>{if(t===true){e.assign(r,true)}else{e.assign(r,(0,Hs._)`${r} || {}`);TAe(e,r,t)}}),mergeValues:(e,t)=>e===true?true:{...e,...t},resultToName:Nvt}),items:Tvt({mergeNames:(e,t,r)=>e.if((0,Hs._)`${r} !== true && ${t} !== undefined`,()=>e.assign(r,(0,Hs._)`${t} === true ? true : ${r} > ${t} ? ${r} : ${t}`)),mergeToName:(e,t,r)=>e.if((0,Hs._)`${r} !== true`,()=>e.assign(r,t===true?true:(0,Hs._)`${r} > ${t} ? ${r} : ${t}`)),mergeValues:(e,t)=>e===true?true:Math.max(e,t),resultToName:(e,t)=>e.var("items",t)})};function Nvt(e,t){if(t===true)return e.var("props",true);const r=e.var("props",(0,Hs._)`{}`);if(t!==void 0)TAe(e,r,t);return r}a(Nvt,"evaluatedPropsToName");zn.evaluatedPropsToName=Nvt;function TAe(e,t,r){Object.keys(r).forEach(n=>e.assign((0,Hs._)`${t}${(0,Hs.getProperty)(n)}`,true))}a(TAe,"setEvaluated");zn.setEvaluated=TAe;var xvt={};function Gfn(e,t){return e.scopeValue("func",{ref:t,code:xvt[t.code]||(xvt[t.code]=new Lfn._Code(t.code))})}a(Gfn,"useFunc");zn.useFunc=Gfn;var Ivt;(function(e){e[e["Num"]=0]="Num";e[e["Str"]=1]="Str"})(Ivt=zn.Type||(zn.Type={}));function Hfn(e,t,r){if(e instanceof Hs.Name){const n=t===Ivt.Num;return r?n?(0,Hs._)`"[" + ${e} + "]"`:(0,Hs._)`"['" + ${e} + "']"`:n?(0,Hs._)`"/" + ${e}`:(0,Hs._)`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return r?(0,Hs.getProperty)(e).toString():"/"+wAe(e)}a(Hfn,"getErrorPath");zn.getErrorPath=Hfn;function kvt(e,t,r=e.opts.strictSchema){if(!r)return;t=`strict mode: ${t}`;if(r===true)throw new Error(t);e.self.logger.warn(t)}a(kvt,"checkStrictMode");zn.checkStrictMode=kvt});var Af=y(xAe=>{"use strict";Object.defineProperty(xAe,"__esModule",{value:true});var Nl=En();var Vfn={data:new Nl.Name("data"),valCxt:new Nl.Name("valCxt"),instancePath:new Nl.Name("instancePath"),parentData:new Nl.Name("parentData"),parentDataProperty:new Nl.Name("parentDataProperty"),rootData:new Nl.Name("rootData"),dynamicAnchors:new Nl.Name("dynamicAnchors"),vErrors:new Nl.Name("vErrors"),errors:new Nl.Name("errors"),this:new Nl.Name("this"),self:new Nl.Name("self"),scope:new Nl.Name("scope"),json:new Nl.Name("json"),jsonPos:new Nl.Name("jsonPos"),jsonLen:new Nl.Name("jsonLen"),jsonPart:new Nl.Name("jsonPart")};xAe.default=Vfn});var DL=y(Il=>{"use strict";Object.defineProperty(Il,"__esModule",{value:true});Il.extendErrors=Il.resetErrorsCount=Il.reportExtraError=Il.reportError=Il.keyword$DataError=Il.keywordError=void 0;var Fi=En();var SY=ui();var Ec=Af();Il.keywordError={message:({keyword:e})=>(0,Fi.str)`must pass "${e}" keyword validation`};Il.keyword$DataError={message:({keyword:e,schemaType:t})=>t?(0,Fi.str)`"${e}" keyword must be ${t} ($data)`:(0,Fi.str)`"${e}" keyword is invalid ($data)`};function zfn(e,t=Il.keywordError,r,n){const{it:i}=e;const{gen:s,compositeRule:o,allErrors:u}=i;const l=Fvt(e,t,r);if(n!==null&&n!==void 0?n:o||u){Dvt(s,l)}else{Lvt(i,(0,Fi._)`[${l}]`)}}a(zfn,"reportError");Il.reportError=zfn;function Kfn(e,t=Il.keywordError,r){const{it:n}=e;const{gen:i,compositeRule:s,allErrors:o}=n;const u=Fvt(e,t,r);Dvt(i,u);if(!(s||o)){Lvt(n,Ec.default.vErrors)}}a(Kfn,"reportExtraError");Il.reportExtraError=Kfn;function Wfn(e,t){e.assign(Ec.default.errors,t);e.if((0,Fi._)`${Ec.default.vErrors} !== null`,()=>e.if(t,()=>e.assign((0,Fi._)`${Ec.default.vErrors}.length`,t),()=>e.assign(Ec.default.vErrors,null)))}a(Wfn,"resetErrorsCount");Il.resetErrorsCount=Wfn;function Yfn({gen:e,keyword:t,schemaValue:r,data:n,errsCount:i,it:s}){if(i===void 0)throw new Error("ajv implementation error");const o=e.name("err");e.forRange("i",i,Ec.default.errors,u=>{e.const(o,(0,Fi._)`${Ec.default.vErrors}[${u}]`);e.if((0,Fi._)`${o}.instancePath === undefined`,()=>e.assign((0,Fi._)`${o}.instancePath`,(0,Fi.strConcat)(Ec.default.instancePath,s.errorPath)));e.assign((0,Fi._)`${o}.schemaPath`,(0,Fi.str)`${s.errSchemaPath}/${t}`);if(s.opts.verbose){e.assign((0,Fi._)`${o}.schema`,r);e.assign((0,Fi._)`${o}.data`,n)}})}a(Yfn,"extendErrors");Il.extendErrors=Yfn;function Dvt(e,t){const r=e.const("err",t);e.if((0,Fi._)`${Ec.default.vErrors} === null`,()=>e.assign(Ec.default.vErrors,(0,Fi._)`[${r}]`),(0,Fi._)`${Ec.default.vErrors}.push(${r})`);e.code((0,Fi._)`${Ec.default.errors}++`)}a(Dvt,"addError");function Lvt(e,t){const{gen:r,validateName:n,schemaEnv:i}=e;if(i.$async){r.throw((0,Fi._)`new ${e.ValidationError}(${t})`)}else{r.assign((0,Fi._)`${n}.errors`,t);r.return(false)}}a(Lvt,"returnErrors");var BA={keyword:new Fi.Name("keyword"),schemaPath:new Fi.Name("schemaPath"),params:new Fi.Name("params"),propertyName:new Fi.Name("propertyName"),message:new Fi.Name("message"),schema:new Fi.Name("schema"),parentSchema:new Fi.Name("parentSchema")};function Fvt(e,t,r){const{createErrors:n}=e.it;if(n===false)return(0,Fi._)`{}`;return Xfn(e,t,r)}a(Fvt,"errorObjectCode");function Xfn(e,t,r={}){const{gen:n,it:i}=e;const s=[Jfn(i,r),Qfn(e,r)];Zfn(e,t,s);return n.object(...s)}a(Xfn,"errorObject");function Jfn({errorPath:e},{instancePath:t}){const r=t?(0,Fi.str)`${e}${(0,SY.getErrorPath)(t,SY.Type.Str)}`:e;return[Ec.default.instancePath,(0,Fi.strConcat)(Ec.default.instancePath,r)]}a(Jfn,"errorInstancePath");function Qfn({keyword:e,it:{errSchemaPath:t}},{schemaPath:r,parentSchema:n}){let i=n?t:(0,Fi.str)`${t}/${e}`;if(r){i=(0,Fi.str)`${i}${(0,SY.getErrorPath)(r,SY.Type.Str)}`}return[BA.schemaPath,i]}a(Qfn,"errorSchemaPath");function Zfn(e,{params:t,message:r},n){const{keyword:i,data:s,schemaValue:o,it:u}=e;const{opts:l,propertyName:c,topSchemaRef:d,schemaPath:p}=u;n.push([BA.keyword,i],[BA.params,typeof t=="function"?t(e):t||(0,Fi._)`{}`]);if(l.messages){n.push([BA.message,typeof r=="function"?r(e):r])}if(l.verbose){n.push([BA.schema,o],[BA.parentSchema,(0,Fi._)`${d}${p}`],[Ec.default.data,s])}if(c)n.push([BA.propertyName,c])}a(Zfn,"extraErrorProps")});var Mvt=y(pO=>{"use strict";Object.defineProperty(pO,"__esModule",{value:true});pO.boolOrEmptySchema=pO.topBoolOrEmptySchema=void 0;var emn=DL();var tmn=En();var rmn=Af();var nmn={message:"boolean schema is false"};function imn(e){const{gen:t,schema:r,validateName:n}=e;if(r===false){Bvt(e,false)}else if(typeof r=="object"&&r.$async===true){t.return(rmn.default.data)}else{t.assign((0,tmn._)`${n}.errors`,null);t.return(true)}}a(imn,"topBoolOrEmptySchema");pO.topBoolOrEmptySchema=imn;function smn(e,t){const{gen:r,schema:n}=e;if(n===false){r.var(t,false);Bvt(e)}else{r.var(t,true)}}a(smn,"boolOrEmptySchema");pO.boolOrEmptySchema=smn;function Bvt(e,t){const{gen:r,data:n}=e;const i={gen:r,keyword:"false schema",data:n,schema:false,schemaCode:false,schemaValue:false,params:{},it:e};(0,emn.reportError)(i,nmn,void 0,t)}a(Bvt,"falseSchemaError")});var RAe=y(fO=>{"use strict";Object.defineProperty(fO,"__esModule",{value:true});fO.getRules=fO.isJSONType=void 0;var amn=["string","number","integer","boolean","null","object","array"];var omn=new Set(amn);function umn(e){return typeof e=="string"&&omn.has(e)}a(umn,"isJSONType");fO.isJSONType=umn;function lmn(){const e={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...e,integer:true,boolean:true,null:true},rules:[{rules:[]},e.number,e.string,e.array,e.object],post:{rules:[]},all:{},keywords:{}}}a(lmn,"getRules");fO.getRules=lmn});var OAe=y(gE=>{"use strict";Object.defineProperty(gE,"__esModule",{value:true});gE.shouldUseRule=gE.shouldUseGroup=gE.schemaHasRulesForType=void 0;function cmn({schema:e,self:t},r){const n=t.RULES.types[r];return n&&n!==true&&qvt(e,n)}a(cmn,"schemaHasRulesForType");gE.schemaHasRulesForType=cmn;function qvt(e,t){return t.rules.some(r=>Uvt(e,r))}a(qvt,"shouldUseGroup");gE.shouldUseGroup=qvt;function Uvt(e,t){var r;return e[t.keyword]!==void 0||((r=t.definition.implements)===null||r===void 0?void 0:r.some(n=>e[n]!==void 0))}a(Uvt,"shouldUseRule");gE.shouldUseRule=Uvt});var FL=y(tl=>{"use strict";Object.defineProperty(tl,"__esModule",{value:true});tl.reportTypeError=tl.checkDataTypes=tl.checkDataType=tl.coerceAndCheckDataType=tl.getJSONTypes=tl.getSchemaTypes=tl.DataType=void 0;var dmn=RAe();var pmn=OAe();var fmn=DL();var On=En();var $vt=ui();var LL;(function(e){e[e["Correct"]=0]="Correct";e[e["Wrong"]=1]="Wrong"})(LL=tl.DataType||(tl.DataType={}));function mmn(e){const t=jvt(e.type);const r=t.includes("null");if(r){if(e.nullable===false)throw new Error("type: null contradicts nullable: false")}else{if(!t.length&&e.nullable!==void 0){throw new Error('"nullable" cannot be used without "type"')}if(e.nullable===true)t.push("null")}return t}a(mmn,"getSchemaTypes");tl.getSchemaTypes=mmn;function jvt(e){const t=Array.isArray(e)?e:e?[e]:[];if(t.every(dmn.isJSONType))return t;throw new Error("type must be JSONType or JSONType[]: "+t.join(","))}a(jvt,"getJSONTypes");tl.getJSONTypes=jvt;function hmn(e,t){const{gen:r,data:n,opts:i}=e;const s=gmn(t,i.coerceTypes);const o=t.length>0&&!(s.length===0&&t.length===1&&(0,pmn.schemaHasRulesForType)(e,t[0]));if(o){const u=NAe(t,n,i.strictNumbers,LL.Wrong);r.if(u,()=>{if(s.length)ymn(e,t,s);else IAe(e)})}return o}a(hmn,"coerceAndCheckDataType");tl.coerceAndCheckDataType=hmn;var Gvt=new Set(["string","number","integer","boolean","null"]);function gmn(e,t){return t?e.filter(r=>Gvt.has(r)||t==="array"&&r==="array"):[]}a(gmn,"coerceToTypes");function ymn(e,t,r){const{gen:n,data:i,opts:s}=e;const o=n.let("dataType",(0,On._)`typeof ${i}`);const u=n.let("coerced",(0,On._)`undefined`);if(s.coerceTypes==="array"){n.if((0,On._)`${o} == 'object' && Array.isArray(${i}) && ${i}.length == 1`,()=>n.assign(i,(0,On._)`${i}[0]`).assign(o,(0,On._)`typeof ${i}`).if(NAe(t,i,s.strictNumbers),()=>n.assign(u,i)))}n.if((0,On._)`${u} !== undefined`);for(const c of r){if(Gvt.has(c)||c==="array"&&s.coerceTypes==="array"){l(c)}}n.else();IAe(e);n.endIf();n.if((0,On._)`${u} !== undefined`,()=>{n.assign(i,u);_mn(e,u)});function l(c){switch(c){case"string":n.elseIf((0,On._)`${o} == "number" || ${o} == "boolean"`).assign(u,(0,On._)`"" + ${i}`).elseIf((0,On._)`${i} === null`).assign(u,(0,On._)`""`);return;case"number":n.elseIf((0,On._)`${o} == "boolean" || ${i} === null
|
|
395
|
+
`}).join("")}getCanonicalRequest(t,r,n,i,s,o){return[t,r,n,i,s,o||"UNSIGNED-PAYLOAD"].join("\n")}getCanonicalQueryParams(t){return(0,aE.objectEntries)(t).map(([r,n])=>[(0,aE.encodeURI)(r,true),(0,aE.encodeURI)(n,true)]).sort((r,n)=>r[0]<n[0]?-1:1).map(([r,n])=>`${r}=${n}`).join("&")}getResourcePath(t,r,n){if(t){return"/"+(n||"")}else if(n){return`/${r}/${n}`}else{return`/${r}`}}parseExpires(t,r=new Date){const n=new Date(t).valueOf();if(isNaN(n)){throw new Error(Jyt.ExceptionMessages.EXPIRATION_DATE_INVALID)}if(n<r.valueOf()){throw new Error(Jyt.ExceptionMessages.EXPIRATION_DATE_PAST)}return Math.floor(n/1e3)}parseAccessibleAt(t){const r=new Date(t||new Date).valueOf();if(isNaN(r)){throw new Error(fL.ACCESSIBLE_DATE_INVALID)}return Math.floor(r/1e3)}};yu.URLSigner=wSe;var mL=class extends Error{static{a(this,"SigningError")}constructor(){super(...arguments);this.name="SigningError"}};yu.SigningError=mL});var hL=y(Ol=>{"use strict";var e_t=Ol&&Ol.__classPrivateFieldSet||function(e,t,r,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t==="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(e,r):i?i.value=r:t.set(e,r),r};var VW=Ol&&Ol.__classPrivateFieldGet||function(e,t,r,n){if(r==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof t==="function"?e!==t||!n:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return r==="m"?n:r==="a"?n.call(e):n?n.value:t.get(e)};var oE;Object.defineProperty(Ol,"__esModule",{value:true});Ol.CRC32C_EXTENSION_TABLE=Ol.CRC32C_EXTENSIONS=Ol.CRC32C_EXCEPTION_MESSAGES=Ol.CRC32C_DEFAULT_VALIDATOR_GENERATOR=Ol.CRC32C=void 0;var Rcn=require("fs");var xSe=[0,4067132163,3778769143,324072436,3348797215,904991772,648144872,3570033899,2329499855,2024987596,1809983544,2575936315,1296289744,3207089363,2893594407,1578318884,274646895,3795141740,4049975192,51262619,3619967088,632279923,922689671,3298075524,2592579488,1760304291,2075979607,2312596564,1562183871,2943781820,3156637768,1313733451,549293790,3537243613,3246849577,871202090,3878099393,357341890,102525238,4101499445,2858735121,1477399826,1264559846,3107202533,1845379342,2677391885,2361733625,2125378298,820201905,3263744690,3520608582,598981189,4151959214,85089709,373468761,3827903834,3124367742,1213305469,1526817161,2842354314,2107672161,2412447074,2627466902,1861252501,1098587580,3004210879,2688576843,1378610760,2262928035,1955203488,1742404180,2511436119,3416409459,969524848,714683780,3639785095,205050476,4266873199,3976438427,526918040,1361435347,2739821008,2954799652,1114974503,2529119692,1691668175,2005155131,2247081528,3690758684,697762079,986182379,3366744552,476452099,3993867776,4250756596,255256311,1640403810,2477592673,2164122517,1922457750,2791048317,1412925310,1197962378,3037525897,3944729517,427051182,170179418,4165941337,746937522,3740196785,3451792453,1070968646,1905808397,2213795598,2426610938,1657317369,3053634322,1147748369,1463399397,2773627110,4215344322,153784257,444234805,3893493558,1021025245,3467647198,3722505002,797665321,2197175160,1889384571,1674398607,2443626636,1164749927,3070701412,2757221520,1446797203,137323447,4198817972,3910406976,461344835,3484808360,1037989803,781091935,3705997148,2460548119,1623424788,1939049696,2180517859,1429367560,2807687179,3020495871,1180866812,410100952,3927582683,4182430767,186734380,3756733383,763408580,1053836080,3434856499,2722870694,1344288421,1131464017,2971354706,1708204729,2545590714,2229949006,1988219213,680717673,3673779818,3383336350,1002577565,4010310262,493091189,238226049,4233660802,2987750089,1082061258,1395524158,2705686845,1972364758,2279892693,2494862625,1725896226,952904198,3399985413,3656866545,731699698,4283874585,222117402,510512622,3959836397,3280807620,837199303,582374963,3504198960,68661723,4135334616,3844915500,390545967,1230274059,3141532936,2825850620,1510247935,2395924756,2091215383,1878366691,2644384480,3553878443,565732008,854102364,3229815391,340358836,3861050807,4117890627,119113024,1493875044,2875275879,3090270611,1247431312,2660249211,1828433272,2141937292,2378227087,3811616794,291187481,34330861,4032846830,615137029,3603020806,3314634738,939183345,1776939221,2609017814,2295496738,2058945313,2926798794,1545135305,1330124605,3173225534,4084100981,17165430,307568514,3762199681,888469610,3332340585,3587147933,665062302,2042050490,2346497209,2559330125,1793573966,3190661285,1279665062,1595330642,2910671697];Ol.CRC32C_EXTENSIONS=xSe;var t_t=new Int32Array(xSe);Ol.CRC32C_EXTENSION_TABLE=t_t;var Ocn=a(()=>new iO,"CRC32C_DEFAULT_VALIDATOR_GENERATOR");Ol.CRC32C_DEFAULT_VALIDATOR_GENERATOR=Ocn;var zW={INVALID_INIT_BASE64_RANGE:e=>`base64-encoded data expected to equal 4 bytes, not ${e}`,INVALID_INIT_BUFFER_LENGTH:e=>`Buffer expected to equal 4 bytes, not ${e}`,INVALID_INIT_INTEGER:e=>`Number expected to be a safe, unsigned 32-bit integer, not ${e}`};Ol.CRC32C_EXCEPTION_MESSAGES=zW;var iO=class e{static{a(this,"CRC32C")}constructor(t=0){oE.set(this,0);e_t(this,oE,t,"f")}update(t){let r=VW(this,oE,"f")^4294967295;for(const n of t){const i=e.CRC32C_EXTENSION_TABLE[(n^r)&255];r=i^r>>>8}e_t(this,oE,r^4294967295,"f")}validate(t){if(typeof t==="number"){return t===VW(this,oE,"f")}else if(typeof t==="string"){return t===this.toString()}else if(Buffer.isBuffer(t)){return Buffer.compare(t,this.toBuffer())===0}else{return t.toString()===this.toString()}}toBuffer(){const t=Buffer.alloc(4);t.writeInt32BE(VW(this,oE,"f"));return t}toJSON(){return this.toString()}toString(){return this.toBuffer().toString("base64")}valueOf(){return VW(this,oE,"f")}static fromBuffer(t){let r;if(Buffer.isBuffer(t)){r=t}else if("buffer"in t){r=Buffer.from(t.buffer)}else{r=Buffer.from(t)}if(r.byteLength!==4){throw new RangeError(zW.INVALID_INIT_BUFFER_LENGTH(r.byteLength))}return new e(r.readInt32BE())}static async fromFile(t){const r=new e;await new Promise((n,i)=>{(0,Rcn.createReadStream)(t).on("data",s=>r.update(s)).on("end",n).on("error",i)});return r}static fromString(t){const r=Buffer.from(t,"base64");if(r.byteLength!==4){throw new RangeError(zW.INVALID_INIT_BASE64_RANGE(r.byteLength))}return this.fromBuffer(r)}static fromNumber(t){if(!Number.isSafeInteger(t)||t>2**32||t<-(2**32)){throw new RangeError(zW.INVALID_INIT_INTEGER(t))}return new e(t)}static from(t){if(typeof t==="number"){return this.fromNumber(t)}else if(typeof t==="string"){return this.fromString(t)}else if("byteLength"in t){return this.fromBuffer(t)}else{return this.fromString(t.toString())}}};Ol.CRC32C=iO;oE=new WeakMap;iO.CRC32C_EXTENSIONS=xSe;iO.CRC32C_EXTENSION_TABLE=t_t});var PSe=y(lE=>{"use strict";var RSe=lE&&lE.__classPrivateFieldSet||function(e,t,r,n,i){if(n==="m")throw new TypeError("Private method is not writable");if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a setter");if(typeof t==="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return n==="a"?i.call(e,r):i?i.value=r:t.set(e,r),r};var D0=lE&&lE.__classPrivateFieldGet||function(e,t,r,n){if(r==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof t==="function"?e!==t||!n:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return r==="m"?n:r==="a"?n.call(e):n?n.value:t.get(e)};var OA;var uE;var KW;Object.defineProperty(lE,"__esModule",{value:true});lE.HashStreamValidator=void 0;var Pcn=require("crypto");var Ncn=require("stream");var Icn=hL();var r_t=gL();var OSe=class extends Ncn.Transform{static{a(this,"HashStreamValidator")}constructor(t={}){super();this.updateHashesOnly=false;OA.set(this,void 0);uE.set(this,void 0);KW.set(this,"");this.crc32cEnabled=!!t.crc32c;this.md5Enabled=!!t.md5;this.updateHashesOnly=!!t.updateHashesOnly;this.crc32cExpected=t.crc32cExpected;this.md5Expected=t.md5Expected;if(this.crc32cEnabled){const r=t.crc32cGenerator||Icn.CRC32C_DEFAULT_VALIDATOR_GENERATOR;RSe(this,OA,r(),"f")}if(this.md5Enabled){RSe(this,uE,(0,Pcn.createHash)("md5"),"f")}}_flush(t){if(D0(this,uE,"f")){RSe(this,KW,D0(this,uE,"f").digest("base64"),"f")}if(this.updateHashesOnly){t();return}let r=this.crc32cEnabled||this.md5Enabled;if(this.crc32cEnabled&&this.crc32cExpected){r=!this.test("crc32c",this.crc32cExpected)}if(this.md5Enabled&&this.md5Expected){r=!this.test("md5",this.md5Expected)}if(r){const n=new r_t.RequestError(r_t.FileExceptionMessages.DOWNLOAD_MISMATCH);n.code="CONTENT_DOWNLOAD_MISMATCH";t(n)}else{t()}}_transform(t,r,n){this.push(t,r);try{if(D0(this,OA,"f"))D0(this,OA,"f").update(t);if(D0(this,uE,"f"))D0(this,uE,"f").update(t);n()}catch(i){n(i)}}test(t,r){const n=Buffer.isBuffer(r)?r.toString("base64"):r;if(t==="crc32c"&&D0(this,OA,"f")){return D0(this,OA,"f").validate(n)}if(t==="md5"&&D0(this,uE,"f")){return D0(this,KW,"f")===n}return false}};lE.HashStreamValidator=OSe;OA=new WeakMap,uE=new WeakMap,KW=new WeakMap});var gL=y(Ha=>{"use strict";var kcn=Ha&&Ha.__createBinding||(Object.create?function(e,t,r,n){if(n===void 0)n=r;var i=Object.getOwnPropertyDescriptor(t,r);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[r]}}}Object.defineProperty(e,n,i)}:function(e,t,r,n){if(n===void 0)n=r;e[n]=t[r]});var Dcn=Ha&&Ha.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var YW=Ha&&Ha.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null){for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))kcn(t,e,r)}Dcn(t,e);return t};var Lcn=Ha&&Ha.__classPrivateFieldGet||function(e,t,r,n){if(r==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof t==="function"?e!==t||!n:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return r==="m"?n:r==="a"?n.call(e):n?n.value:t.get(e)};var XW=Ha&&Ha.__importDefault||function(e){return e&&e.__esModule?e:{"default":e}};var ISe;var u_t;Object.defineProperty(Ha,"__esModule",{value:true});Ha.File=Ha.FileExceptionMessages=Ha.RequestError=Ha.STORAGE_POST_POLICY_BASE_URL=Ha.ActionToHTTPMethod=void 0;var cE=rE();var Fcn=I0();var Bcn=XW(Cyt());var Mcn=YW(require("crypto"));var n_t=YW(require("fs"));var qcn=XW(Iyt());var i_t=YW(Yyt());var yL=require("stream");var s_t=YW(require("zlib"));var _f=nO();var _L=JW();var Ucn=vSe();var NSe=TSe();var dy=TA();var $cn=XW(nSe());var py=P0();var a_t=PSe();var jcn=XW(sL());var kSe;(function(e){e["read"]="GET";e["write"]="PUT";e["delete"]="DELETE";e["resumable"]="POST"})(kSe||(Ha.ActionToHTTPMethod=kSe={}));Ha.STORAGE_POST_POLICY_BASE_URL="https://storage.googleapis.com";var Gcn=/^gs:\/\/([a-z0-9_.-]+)\/(.+)$/;var vL=class extends Error{static{a(this,"RequestError")}};Ha.RequestError=vL;var o_t=7*24*60*60;var vf;(function(e){e["EXPIRATION_TIME_NA"]="An expiration time is not available.";e["DESTINATION_NO_NAME"]="Destination file should have a name.";e["INVALID_VALIDATION_FILE_RANGE"]="Cannot use validation with file ranges (start/end).";e["MD5_NOT_AVAILABLE"]="MD5 verification was specified, but is not available for the requested object. MD5 is not available for composite objects.";e["EQUALS_CONDITION_TWO_ELEMENTS"]="Equals condition must be an array of 2 elements.";e["STARTS_WITH_TWO_ELEMENTS"]="StartsWith condition must be an array of 2 elements.";e["CONTENT_LENGTH_RANGE_MIN_MAX"]="ContentLengthRange must have numeric min & max fields.";e["DOWNLOAD_MISMATCH"]="The downloaded data did not match the data from the server. To be sure the content is the same, you should download the file again.";e["UPLOAD_MISMATCH_DELETE_FAIL"]="The uploaded data did not match the data from the server.\n As a precaution, we attempted to delete the file, but it was not successful.\n To be sure the content is the same, you should try removing the file manually,\n then uploading the file again.\n \n\nThe delete attempt failed with this message:\n\n ";e["UPLOAD_MISMATCH"]="The uploaded data did not match the data from the server.\n As a precaution, the file has been deleted.\n To be sure the content is the same, you should try uploading the file again."})(vf||(Ha.FileExceptionMessages=vf={}));var WW=class e extends cE.ServiceObject{static{a(this,"File")}constructor(t,r,n={}){var i,s;const o={};let u;if(n.generation!==null){if(typeof n.generation==="string"){u=Number(n.generation)}else{u=n.generation}if(!isNaN(u)){o.generation=u}}Object.assign(o,n.preconditionOpts);const l=n.userProject||t.userProject;if(typeof l==="string"){o.userProject=l}const c={delete:{reqOpts:{qs:o}},exists:{reqOpts:{qs:o}},get:{reqOpts:{qs:o}},getMetadata:{reqOpts:{qs:o}},setMetadata:{reqOpts:{qs:o}}};super({parent:t,baseUrl:"/o",id:encodeURIComponent(r),methods:c});ISe.add(this);this.bucket=t;this.storage=t.parent;if(n.generation!==null){let d;if(typeof n.generation==="string"){d=Number(n.generation)}else{d=n.generation}if(!isNaN(d)){this.generation=d}}this.kmsKeyName=n.kmsKeyName;this.userProject=l;this.name=r;if(n.encryptionKey){this.setEncryptionKey(n.encryptionKey)}this.acl=new Ucn.Acl({request:this.request.bind(this),pathPrefix:"/acl"});this.crc32cGenerator=n.crc32cGenerator||this.bucket.crc32cGenerator;this.instanceRetryValue=(s=(i=this.storage)===null||i===void 0?void 0:i.retryOptions)===null||s===void 0?void 0:s.autoRetry;this.instancePreconditionOpts=n===null||n===void 0?void 0:n.preconditionOpts}get cloudStorageURI(){const t=this.bucket.cloudStorageURI;t.pathname=this.name;return t}shouldRetryBasedOnPreconditionAndIdempotencyStrat(t){var r;return!((t===null||t===void 0?void 0:t.ifGenerationMatch)===void 0&&((r=this.instancePreconditionOpts)===null||r===void 0?void 0:r.ifGenerationMatch)===void 0&&this.storage.retryOptions.idempotencyStrategy===_f.IdempotencyStrategy.RetryConditional||this.storage.retryOptions.idempotencyStrategy===_f.IdempotencyStrategy.RetryNever)}copy(t,r,n){var i,s;const o=new Error(vf.DESTINATION_NO_NAME);if(!t){throw o}let u={};if(typeof r==="function"){n=r}else if(r){u={...r}}n=n||cE.util.noop;let l;let c;let d;if(typeof t==="string"){const m=Gcn.exec(t);if(m!==null&&m.length===3){l=this.storage.bucket(m[1]);c=m[2]}else{l=this.bucket;c=t}}else if(t instanceof _L.Bucket){l=t;c=this.name}else if(t instanceof e){l=t.bucket;c=t.name;d=t}else{throw o}const p={};if(this.generation!==void 0){p.sourceGeneration=this.generation}if(u.token!==void 0){p.rewriteToken=u.token}if(u.userProject!==void 0){p.userProject=u.userProject;delete u.userProject}if(u.predefinedAcl!==void 0){p.destinationPredefinedAcl=u.predefinedAcl;delete u.predefinedAcl}d=d||l.file(c);const f={};if(this.encryptionKey!==void 0){f["x-goog-copy-source-encryption-algorithm"]="AES256";f["x-goog-copy-source-encryption-key"]=this.encryptionKeyBase64;f["x-goog-copy-source-encryption-key-sha256"]=this.encryptionKeyHash}if(d.encryptionKey!==void 0){this.setEncryptionKey(d.encryptionKey)}else if(u.destinationKmsKeyName!==void 0){p.destinationKmsKeyName=u.destinationKmsKeyName;delete u.destinationKmsKeyName}else if(d.kmsKeyName!==void 0){p.destinationKmsKeyName=d.kmsKeyName}if(p.destinationKmsKeyName){this.kmsKeyName=p.destinationKmsKeyName;const m=this.interceptors.indexOf(this.encryptionKeyInterceptor);if(m>-1){this.interceptors.splice(m,1)}}if(!this.shouldRetryBasedOnPreconditionAndIdempotencyStrat(u===null||u===void 0?void 0:u.preconditionOpts)){this.storage.retryOptions.autoRetry=false}if(((i=u.preconditionOpts)===null||i===void 0?void 0:i.ifGenerationMatch)!==void 0){p.ifGenerationMatch=(s=u.preconditionOpts)===null||s===void 0?void 0:s.ifGenerationMatch;delete u.preconditionOpts}this.request({method:"POST",uri:`/rewriteTo/b/${l.name}/o/${encodeURIComponent(d.name)}`,qs:p,json:u,headers:f},(m,h)=>{this.storage.retryOptions.autoRetry=this.instanceRetryValue;if(m){n(m,null,h);return}if(h.rewriteToken){const g={token:h.rewriteToken};if(p.userProject){g.userProject=p.userProject}if(p.destinationKmsKeyName){g.destinationKmsKeyName=p.destinationKmsKeyName}this.copy(d,g,n);return}n(null,d,h)})}createReadStream(t={}){t=Object.assign({decompress:true},t);const r=typeof t.start==="number"||typeof t.end==="number";const n=t.end<0;let i=void 0;let s=void 0;const o=new py.PassThroughShim;let u=true;let l=false;if(typeof t.validation==="string"){const m=t.validation.toLowerCase().trim();u=m==="crc32c";l=m==="md5"}else if(t.validation===false){u=false}const c=!r&&(u||l);if(r){if(typeof t.validation==="string"||t.validation===true){throw new Error(vf.INVALID_VALIDATION_FILE_RANGE)}u=false;l=false}const d=a(m=>{if(m){if(s===null||s===void 0?void 0:s.agent){s.agent.destroy()}o.destroy(m)}},"onComplete");const p=a((m,h,g)=>{if(m){this.getBufferFromReadable(g).then(A=>{m.message=A.toString("utf8");o.destroy(m)});return}s=g.request;const _=g.toJSON().headers;const v=_["content-encoding"]==="gzip";const S={};const E=_["x-goog-stored-content-encoding"]==="gzip"&&v||_["x-goog-stored-content-encoding"]==="identity";const b=[];if(c){if(typeof _["x-goog-hash"]==="string"){_["x-goog-hash"].split(",").forEach(A=>{const C=A.indexOf("=");const T=A.substring(0,C);const O=A.substring(C+1);S[T]=O})}i=new a_t.HashStreamValidator({crc32c:u,md5:l,crc32cGenerator:this.crc32cGenerator,crc32cExpected:S.crc32c,md5Expected:S.md5})}if(l&&!S.md5){const A=new vL(vf.MD5_NOT_AVAILABLE);A.code="MD5_NOT_AVAILABLE";o.destroy(A);return}if(E&&c&&i){b.push(i)}if(v&&t.decompress){b.push(s_t.createGunzip())}(0,yL.pipeline)(g,...b,o,d)},"onResponse");const f=a(()=>{const m={alt:"media"};if(this.generation){m.generation=this.generation}if(t.userProject){m.userProject=t.userProject}const h={"Accept-Encoding":"gzip","Cache-Control":"no-store"};if(r){const _=typeof t.start==="number"?t.start:"0";const v=typeof t.end==="number"?t.end:"";h.Range=`bytes=${n?v:`${_}-${v}`}`}const g={uri:"",headers:h,qs:m};if(t[dy.GCCL_GCS_CMD_KEY]){g[dy.GCCL_GCS_CMD_KEY]=t[dy.GCCL_GCS_CMD_KEY]}this.requestStream(g).on("error",_=>{o.destroy(_)}).on("response",_=>{o.emit("response",_);cE.util.handleResp(null,_,null,p)}).resume()},"makeRequest");o.on("reading",f);return o}createResumableUpload(t,r){var n,i;const s=typeof t==="object"?t:{};r=typeof t==="function"?t:r;const o=this.storage.retryOptions;if(((n=s===null||s===void 0?void 0:s.preconditionOpts)===null||n===void 0?void 0:n.ifGenerationMatch)===void 0&&((i=this.instancePreconditionOpts)===null||i===void 0?void 0:i.ifGenerationMatch)===void 0&&this.storage.retryOptions.idempotencyStrategy===_f.IdempotencyStrategy.RetryConditional||this.storage.retryOptions.idempotencyStrategy===_f.IdempotencyStrategy.RetryNever){o.autoRetry=false}i_t.createURI({authClient:this.storage.authClient,apiEndpoint:this.storage.apiEndpoint,bucket:this.bucket.name,customRequestOptions:this.getRequestInterceptors().reduce((u,l)=>l(u),{}),file:this.name,generation:this.generation,key:this.encryptionKey,kmsKeyName:this.kmsKeyName,metadata:s.metadata,offset:s.offset,origin:s.origin,predefinedAcl:s.predefinedAcl,private:s.private,public:s.public,userProject:s.userProject||this.userProject,retryOptions:o,params:(s===null||s===void 0?void 0:s.preconditionOpts)||this.instancePreconditionOpts,[dy.GCCL_GCS_CMD_KEY]:s[dy.GCCL_GCS_CMD_KEY]},r);this.storage.retryOptions.autoRetry=this.instanceRetryValue}createWriteStream(t={}){var r;(r=t.metadata)!==null&&r!==void 0?r:t.metadata={};if(t.contentType){t.metadata.contentType=t.contentType}if(!t.metadata.contentType||t.metadata.contentType==="auto"){const f=qcn.default.getType(this.name);if(f){t.metadata.contentType=f}}let n=t.gzip;if(n==="auto"){n=(0,Bcn.default)(t.metadata.contentType||"")}if(n){t.metadata.contentEncoding="gzip"}let i=true;let s=false;if(typeof t.validation==="string"){t.validation=t.validation.toLowerCase();i=t.validation==="crc32c";s=t.validation==="md5"}else if(t.validation===false){i=false}let o=a(f=>{u.destroy(f||void 0)},"pipelineCallback");const u=new yL.Writable({final(f){o=f;l.end()},write(f,m,h){l.write(f,m,h)}});const l=new py.PassThroughShim;const c=new a_t.HashStreamValidator({crc32c:i,md5:s,crc32cGenerator:this.crc32cGenerator,updateHashesOnly:true});const d=(0,$cn.default)();let p=false;l.on("reading",()=>u.emit("reading"));l.on("writing",()=>u.emit("writing"));d.on("progress",f=>u.emit("progress",f));d.on("response",f=>u.emit("response",f));d.once("metadata",()=>{p=true});u.on("writing",()=>{if(t.resumable===false){this.startSimpleUpload_(d,t)}else{this.startResumableUpload_(d,t)}(0,yL.pipeline)(l,n?s_t.createGzip():new yL.PassThrough,c,d,async f=>{if(f){return o(f)}if(!p){try{await new Promise((m,h)=>{d.once("metadata",m);d.once("error",h)})}catch(m){return o(m)}}try{await Lcn(this,ISe,"m",u_t).call(this,c,{crc32c:i,md5:s});o()}catch(m){o(m)}})});return u}delete(t,r){const n=typeof t==="object"?t:{};r=typeof t==="function"?t:r;this.disableAutoRetryConditionallyIdempotent_(this.methods.delete,_L.AvailableServiceObjectMethods.delete,n);super.delete(n).then(i=>r(null,...i)).catch(r).finally(()=>{this.storage.retryOptions.autoRetry=this.instanceRetryValue})}download(t,r){let n;if(typeof t==="function"){r=t;n={}}else{n=t}let i=false;const s=a((...c)=>{if(!i)r(...c);i=true},"callback");const o=n.destination;delete n.destination;const u=this.createReadStream(n);let l=false;if(o){u.on("error",s).once("data",c=>{l=true;const d=n_t.createWriteStream(o);d.write(c);u.pipe(d).on("error",s).on("finish",s)}).on("end",()=>{if(!l){const c=Buffer.alloc(0);try{n_t.writeFileSync(o,c);s(null,c)}catch(d){s(d,c)}}})}else{this.getBufferFromReadable(u).then(c=>s===null||s===void 0?void 0:s(null,c)).catch(s)}}setEncryptionKey(t){this.encryptionKey=t;this.encryptionKeyBase64=Buffer.from(t).toString("base64");this.encryptionKeyHash=Mcn.createHash("sha256").update(this.encryptionKeyBase64,"base64").digest("base64");this.encryptionKeyInterceptor={request:r=>{r.headers=r.headers||{};r.headers["x-goog-encryption-algorithm"]="AES256";r.headers["x-goog-encryption-key"]=this.encryptionKeyBase64;r.headers["x-goog-encryption-key-sha256"]=this.encryptionKeyHash;return r}};this.interceptors.push(this.encryptionKeyInterceptor);return this}getExpirationDate(t){this.getMetadata((r,n,i)=>{if(r){t(r,null,i);return}if(!n.retentionExpirationTime){const s=new Error(vf.EXPIRATION_TIME_NA);t(s,null,i);return}t(null,new Date(n.retentionExpirationTime),i)})}generateSignedPostPolicyV2(t,r){const n=(0,py.normalize)(t,r);let i=n.options;const s=n.callback;const o=new Date(i.expires);if(isNaN(o.getTime())){throw new Error(_f.ExceptionMessages.EXPIRATION_DATE_INVALID)}if(o.valueOf()<Date.now()){throw new Error(_f.ExceptionMessages.EXPIRATION_DATE_PAST)}i=Object.assign({},i);const u=[["eq","$key",this.name],{bucket:this.bucket.name}];if(Array.isArray(i.equals)){if(!Array.isArray(i.equals[0])){i.equals=[i.equals]}i.equals.forEach(p=>{if(!Array.isArray(p)||p.length!==2){throw new Error(vf.EQUALS_CONDITION_TWO_ELEMENTS)}u.push(["eq",p[0],p[1]])})}if(Array.isArray(i.startsWith)){if(!Array.isArray(i.startsWith[0])){i.startsWith=[i.startsWith]}i.startsWith.forEach(p=>{if(!Array.isArray(p)||p.length!==2){throw new Error(vf.STARTS_WITH_TWO_ELEMENTS)}u.push(["starts-with",p[0],p[1]])})}if(i.acl){u.push({acl:i.acl})}if(i.successRedirect){u.push({success_action_redirect:i.successRedirect})}if(i.successStatus){u.push({success_action_status:i.successStatus})}if(i.contentLengthRange){const p=i.contentLengthRange.min;const f=i.contentLengthRange.max;if(typeof p!=="number"||typeof f!=="number"){throw new Error(vf.CONTENT_LENGTH_RANGE_MIN_MAX)}u.push(["content-length-range",p,f])}const l={expiration:o.toISOString(),conditions:u};const c=JSON.stringify(l);const d=Buffer.from(c).toString("base64");this.storage.authClient.sign(d).then(p=>{s(null,{string:c,base64:d,signature:p})},p=>{s(new NSe.SigningError(p.message))})}generateSignedPostPolicyV4(t,r){const n=(0,py.normalize)(t,r);let i=n.options;const s=n.callback;const o=new Date(i.expires);if(isNaN(o.getTime())){throw new Error(_f.ExceptionMessages.EXPIRATION_DATE_INVALID)}if(o.valueOf()<Date.now()){throw new Error(_f.ExceptionMessages.EXPIRATION_DATE_PAST)}if(o.valueOf()-Date.now()>o_t*1e3){throw new Error(`Max allowed expiration is seven days (${o_t} seconds).`)}i=Object.assign({},i);let u=Object.assign({},i.fields);const l=new Date;const c=(0,py.formatAsUTCISO)(l,true);const d=(0,py.formatAsUTCISO)(l);const p=a(async()=>{const{client_email:f}=await this.storage.authClient.getCredentials();const m=`${f}/${d}/auto/storage/goog4_request`;u={...u,bucket:this.bucket.name,key:this.name,"x-goog-date":c,"x-goog-credential":m,"x-goog-algorithm":"GOOG4-RSA-SHA256"};const h=i.conditions||[];Object.entries(u).forEach(([E,b])=>{if(!E.startsWith("x-ignore-")){h.push({[E]:b})}});delete u.bucket;const g=(0,py.formatAsUTCISO)(o,true,"-",":");const _={conditions:h,expiration:g};const v=(0,py.unicodeJSONStringify)(_);const S=Buffer.from(v).toString("base64");try{const E=await this.storage.authClient.sign(S);const b=Buffer.from(E,"base64").toString("hex");u["policy"]=S;u["x-goog-signature"]=b;let A;if(i.virtualHostedStyle){A=`https://${this.bucket.name}.storage.googleapis.com/`}else if(i.bucketBoundHostname){A=`${i.bucketBoundHostname}/`}else{A=`${Ha.STORAGE_POST_POLICY_BASE_URL}/${this.bucket.name}/`}return{url:A,fields:u}}catch(E){throw new NSe.SigningError(E.message)}},"sign");p().then(f=>s(null,f),s)}getSignedUrl(t,r){const n=kSe[t.action];const i=(0,py.objectKeyToLowercase)(t.extensionHeaders||{});if(t.action==="resumable"){i["x-goog-resumable"]="start"}const s=Object.assign({},t.queryParams);if(typeof t.responseType==="string"){s["response-content-type"]=t.responseType}if(typeof t.promptSaveAs==="string"){s["response-content-disposition"]='attachment; filename="'+t.promptSaveAs+'"'}if(typeof t.responseDisposition==="string"){s["response-content-disposition"]=t.responseDisposition}if(this.generation){s["generation"]=this.generation.toString()}const o={method:n,expires:t.expires,accessibleAt:t.accessibleAt,extensionHeaders:i,queryParams:s,contentMd5:t.contentMd5,contentType:t.contentType};if(t.cname){o.cname=t.cname}if(t.version){o.version=t.version}if(t.virtualHostedStyle){o.virtualHostedStyle=t.virtualHostedStyle}if(!this.signer){this.signer=new NSe.URLSigner(this.storage.authClient,this.bucket,this)}this.signer.getSignedUrl(o).then(u=>r(null,u),r)}isPublic(t){var r;const n=((r=this.storage)===null||r===void 0?void 0:r.interceptors)||[];const i=this.interceptors||[];const s=n.concat(i);const o=s.reduce((u,l)=>{const c=l.request({uri:`${this.storage.apiEndpoint}/${this.bucket.name}/${encodeURIComponent(this.name)}`});Object.assign(u,c.headers);return u},{});cE.util.makeRequest({method:"GET",uri:`${this.storage.apiEndpoint}/${this.bucket.name}/${encodeURIComponent(this.name)}`,headers:o},{retryOptions:this.storage.retryOptions},u=>{if(u){const l=u;if(l.code===403){t(null,false)}else{t(u)}}else{t(null,true)}})}makePrivate(t,r){var n,i;const s=typeof t==="object"?t:{};r=typeof t==="function"?t:r;const o={predefinedAcl:s.strict?"private":"projectPrivate"};if(((n=s.preconditionOpts)===null||n===void 0?void 0:n.ifMetagenerationMatch)!==void 0){o.ifMetagenerationMatch=(i=s.preconditionOpts)===null||i===void 0?void 0:i.ifMetagenerationMatch;delete s.preconditionOpts}if(s.userProject){o.userProject=s.userProject}const u={...s.metadata,acl:null};this.setMetadata(u,o,r)}makePublic(t){t=t||cE.util.noop;this.acl.add({entity:"allUsers",role:"READER"},(r,n,i)=>{t(r,i)})}publicUrl(){return`${this.storage.apiEndpoint}/${this.bucket.name}/${encodeURIComponent(this.name)}`}move(t,r,n){const i=typeof r==="object"?r:{};n=typeof r==="function"?r:n;n=n||cE.util.noop;this.copy(t,i,(s,o,u)=>{if(s){s.message="file#copy failed with an error - "+s.message;n(s,null,u);return}if(this.name!==o.name||this.bucket.name!==o.bucket.name){this.delete(i,(l,c)=>{if(l){l.message="file#delete failed with an error - "+l.message;n(l,o,c);return}n(null,o,u)})}else{n(null,o,u)}})}rename(t,r,n){const i=typeof r==="object"?r:{};n=typeof r==="function"?r:n;n=n||cE.util.noop;this.move(t,i,n)}request(t,r){return this.parent.request.call(this,t,r)}rotateEncryptionKey(t,r){var n;r=typeof t==="function"?t:r;let i={};if(typeof t==="string"||t instanceof Buffer){i={encryptionKey:t}}else if(typeof t==="object"){i=t}const s=this.bucket.file(this.id,i);const o=((n=i.preconditionOpts)===null||n===void 0?void 0:n.ifGenerationMatch)!==void 0?{preconditionOpts:i.preconditionOpts}:{};this.copy(s,o,r)}save(t,r,n){n=typeof r==="function"?r:n;const i=typeof r==="object"?r:{};let s=this.storage.retryOptions.maxRetries;if(!this.shouldRetryBasedOnPreconditionAndIdempotencyStrat(i===null||i===void 0?void 0:i.preconditionOpts)){s=0}const o=(0,jcn.default)(async u=>{return new Promise((l,c)=>{if(s===0){this.storage.retryOptions.autoRetry=false}const d=this.createWriteStream(i);if(i.onUploadProgress){d.on("progress",i.onUploadProgress)}const p=a(f=>{if(this.storage.retryOptions.autoRetry&&this.storage.retryOptions.retryableErrorFn(f)){return c(f)}return u(f)},"handleError");if(typeof t==="string"||Buffer.isBuffer(t)){d.on("error",p).on("finish",()=>l()).end(t)}else{(0,yL.pipeline)(t,d,f=>{if(f){if(typeof t!=="function"){return u(f)}p(f)}else{l()}})}})},{retries:s,factor:this.storage.retryOptions.retryDelayMultiplier,maxTimeout:this.storage.retryOptions.maxRetryDelay*1e3,maxRetryTime:this.storage.retryOptions.totalTimeout*1e3});if(!n){return o}else{return o.then(()=>{if(n){return n()}}).catch(n)}}setMetadata(t,r,n){const i=typeof r==="object"?r:{};n=typeof r==="function"?r:n;this.disableAutoRetryConditionallyIdempotent_(this.methods.setMetadata,_L.AvailableServiceObjectMethods.setMetadata,i);super.setMetadata(t,i).then(s=>n(null,...s)).catch(n).finally(()=>{this.storage.retryOptions.autoRetry=this.instanceRetryValue})}setStorageClass(t,r,n){n=typeof r==="function"?r:n;const i=typeof r==="object"?r:{};const s={...i,storageClass:t.replace(/-/g,"_").replace(/([a-z])([A-Z])/g,(o,u,l)=>{return u+"_"+l}).toUpperCase()};this.copy(this,s,(o,u,l)=>{if(o){n(o,l);return}this.metadata=u.metadata;n(null,l)})}setUserProject(t){this.bucket.setUserProject.call(this,t)}startResumableUpload_(t,r={}){var n;(n=r.metadata)!==null&&n!==void 0?n:r.metadata={};const i=this.storage.retryOptions;if(!this.shouldRetryBasedOnPreconditionAndIdempotencyStrat(r.preconditionOpts)){i.autoRetry=false}const s=i_t.upload({authClient:this.storage.authClient,apiEndpoint:this.storage.apiEndpoint,bucket:this.bucket.name,customRequestOptions:this.getRequestInterceptors().reduce((o,u)=>u(o),{}),file:this.name,generation:this.generation,key:this.encryptionKey,kmsKeyName:this.kmsKeyName,metadata:r.metadata,offset:r.offset,predefinedAcl:r.predefinedAcl,private:r.private,public:r.public,uri:r.uri,userProject:r.userProject||this.userProject,retryOptions:{...i},params:(r===null||r===void 0?void 0:r.preconditionOpts)||this.instancePreconditionOpts,chunkSize:r===null||r===void 0?void 0:r.chunkSize,highWaterMark:r===null||r===void 0?void 0:r.highWaterMark,[dy.GCCL_GCS_CMD_KEY]:r[dy.GCCL_GCS_CMD_KEY]});s.on("response",o=>{t.emit("response",o)}).on("metadata",o=>{this.metadata=o;t.emit("metadata")}).on("finish",()=>{t.emit("complete")}).on("progress",o=>t.emit("progress",o));t.setWritable(s);this.storage.retryOptions.autoRetry=this.instanceRetryValue}startSimpleUpload_(t,r={}){var n;(n=r.metadata)!==null&&n!==void 0?n:r.metadata={};const i=this.storage.apiEndpoint;const s=this.bucket.name;const o=`${i}/upload/storage/v1/b/${s}/o`;const u={qs:{name:this.name},uri:o,[dy.GCCL_GCS_CMD_KEY]:r[dy.GCCL_GCS_CMD_KEY]};if(this.generation!==void 0){u.qs.ifGenerationMatch=this.generation}if(this.kmsKeyName!==void 0){u.qs.kmsKeyName=this.kmsKeyName}if(typeof r.timeout==="number"){u.timeout=r.timeout}if(r.userProject||this.userProject){u.qs.userProject=r.userProject||this.userProject}if(r.predefinedAcl){u.qs.predefinedAcl=r.predefinedAcl}else if(r.private){u.qs.predefinedAcl="private"}else if(r.public){u.qs.predefinedAcl="publicRead"}Object.assign(u.qs,this.instancePreconditionOpts,r.preconditionOpts);cE.util.makeWritableStream(t,{makeAuthenticatedRequest:l=>{this.request(l,(c,d,p)=>{if(c){t.destroy(c);return}this.metadata=d;t.emit("metadata",d);t.emit("response",p);t.emit("complete")})},metadata:r.metadata,request:u})}disableAutoRetryConditionallyIdempotent_(t,r,n){var i,s,o,u;if(typeof t==="object"&&((s=(i=t===null||t===void 0?void 0:t.reqOpts)===null||i===void 0?void 0:i.qs)===null||s===void 0?void 0:s.ifGenerationMatch)===void 0&&(n===null||n===void 0?void 0:n.ifGenerationMatch)===void 0&&r===_L.AvailableServiceObjectMethods.delete&&this.storage.retryOptions.idempotencyStrategy===_f.IdempotencyStrategy.RetryConditional||this.storage.retryOptions.idempotencyStrategy===_f.IdempotencyStrategy.RetryNever){this.storage.retryOptions.autoRetry=false}if(typeof t==="object"&&((u=(o=t===null||t===void 0?void 0:t.reqOpts)===null||o===void 0?void 0:o.qs)===null||u===void 0?void 0:u.ifMetagenerationMatch)===void 0&&(n===null||n===void 0?void 0:n.ifMetagenerationMatch)===void 0&&r===_L.AvailableServiceObjectMethods.setMetadata&&this.storage.retryOptions.idempotencyStrategy===_f.IdempotencyStrategy.RetryConditional||this.storage.retryOptions.idempotencyStrategy===_f.IdempotencyStrategy.RetryNever){this.storage.retryOptions.autoRetry=false}}async getBufferFromReadable(t){const r=[];for await(const n of t){r.push(n)}return Buffer.concat(r)}};Ha.File=WW;ISe=new WeakSet,u_t=a(async function e(t,r={}){const n=this.metadata;let i=!!(r.crc32c||r.md5);if(r.crc32c&&n.crc32c){i=!t.test("crc32c",n.crc32c)}if(r.md5&&n.md5Hash){i=!t.test("md5",n.md5Hash)}if(i){const s=[];let o="";let u="";try{await this.delete();if(r.md5&&!n.md5Hash){o="MD5_NOT_AVAILABLE";u=vf.MD5_NOT_AVAILABLE}else{o="FILE_NO_UPLOAD";u=vf.UPLOAD_MISMATCH}}catch(c){const d=c;o="FILE_NO_UPLOAD_DELETE";u=`${vf.UPLOAD_MISMATCH_DELETE_FAIL}${d.message}`;s.push(d)}const l=new vL(u);l.code=o;l.errors=s;throw l}return true},"_File_validateIntegrity");(0,Fcn.promisifyAll)(WW,{exclude:["cloudStorageURI","publicUrl","request","save","setEncryptionKey","shouldRetryBasedOnPreconditionAndIdempotencyStrat","getBufferFromReadable"]})});var LSe=y(sO=>{"use strict";Object.defineProperty(sO,"__esModule",{value:true});sO.Iam=sO.IAMExceptionMessages=void 0;var Hcn=I0();var DSe=P0();var QW;(function(e){e["POLICY_OBJECT_REQUIRED"]="A policy object is required.";e["PERMISSIONS_REQUIRED"]="Permissions are required."})(QW||(sO.IAMExceptionMessages=QW={}));var ZW=class{static{a(this,"Iam")}constructor(t){this.request_=t.request.bind(t);this.resourceId_="buckets/"+t.getId()}getPolicy(t,r){const{options:n,callback:i}=(0,DSe.normalize)(t,r);const s={};if(n.userProject){s.userProject=n.userProject}if(n.requestedPolicyVersion!==null&&n.requestedPolicyVersion!==void 0){s.optionsRequestedPolicyVersion=n.requestedPolicyVersion}this.request_({uri:"/iam",qs:s},i)}setPolicy(t,r,n){if(t===null||typeof t!=="object"){throw new Error(QW.POLICY_OBJECT_REQUIRED)}const{options:i,callback:s}=(0,DSe.normalize)(r,n);let o;if(t.etag===void 0){o=0}this.request_({method:"PUT",uri:"/iam",maxRetries:o,json:Object.assign({resourceId:this.resourceId_},t),qs:i},s)}testPermissions(t,r,n){if(!Array.isArray(t)&&typeof t!=="string"){throw new Error(QW.PERMISSIONS_REQUIRED)}const{options:i,callback:s}=(0,DSe.normalize)(r,n);const o=Array.isArray(t)?t:[t];const u=Object.assign({permissions:o},i);this.request_({uri:"/iam/testPermissions",qs:u,useQuerystring:true},(l,c)=>{if(l){s(l,null,c);return}const d=Array.isArray(c.permissions)?c.permissions:[];const p=o.reduce((f,m)=>{f[m]=d.indexOf(m)>-1;return f},{});s(null,p,c)})}};sO.Iam=ZW;(0,Hcn.promisifyAll)(ZW)});var FSe=y(tY=>{"use strict";Object.defineProperty(tY,"__esModule",{value:true});tY.Notification=void 0;var Vcn=rE();var zcn=I0();var eY=class extends Vcn.ServiceObject{static{a(this,"Notification")}constructor(t,r){const n={};const i={create:true,delete:{reqOpts:{qs:n}},get:{reqOpts:{qs:n}},getMetadata:{reqOpts:{qs:n}},exists:true};super({parent:t,baseUrl:"/notificationConfigs",id:r.toString(),createMethod:t.createNotification.bind(t),methods:i})}};tY.Notification=eY;(0,zcn.promisifyAll)(eY)});var JW=y(_u=>{"use strict";var Kcn=_u&&_u.__createBinding||(Object.create?function(e,t,r,n){if(n===void 0)n=r;var i=Object.getOwnPropertyDescriptor(t,r);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[r]}}}Object.defineProperty(e,n,i)}:function(e,t,r,n){if(n===void 0)n=r;e[n]=t[r]});var Wcn=_u&&_u.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var qSe=_u&&_u.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null){for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))Kcn(t,e,r)}Wcn(t,e);return t};var p_t=_u&&_u.__importDefault||function(e){return e&&e.__esModule?e:{"default":e}};Object.defineProperty(_u,"__esModule",{value:true});_u.Bucket=_u.BucketExceptionMessages=_u.AvailableServiceObjectMethods=_u.BucketActionToHTTPMethod=void 0;var rY=rE();var f_t=fSe();var Ycn=I0();var Xcn=qSe(require("fs"));var Jcn=qSe(hSe());var Qcn=qSe(require("path"));var l_t=p_t(_Se());var c_t=require("util");var Zcn=p_t(sL());var edn=P0();var d_t=vSe();var BSe=gL();var tdn=LSe();var rdn=FSe();var aO=nO();var ndn=TSe();var idn=require("stream");var sdn=require("url");var MSe;(function(e){e["list"]="GET"})(MSe||(_u.BucketActionToHTTPMethod=MSe={}));var oO;(function(e){e[e["setMetadata"]=0]="setMetadata";e[e["delete"]=1]="delete"})(oO||(_u.AvailableServiceObjectMethods=oO={}));var L0;(function(e){e["PROVIDE_SOURCE_FILE"]="You must provide at least one source file.";e["DESTINATION_FILE_NOT_SPECIFIED"]="A destination file must be specified.";e["CHANNEL_ID_REQUIRED"]="An ID is required to create a channel.";e["TOPIC_NAME_REQUIRED"]="A valid topic name is required.";e["CONFIGURATION_OBJECT_PREFIX_REQUIRED"]="A configuration object with a prefix is required.";e["SPECIFY_FILE_NAME"]="A file name must be specified.";e["METAGENERATION_NOT_PROVIDED"]="A metageneration must be provided.";e["SUPPLY_NOTIFICATION_ID"]="You must supply a notification ID."})(L0||(_u.BucketExceptionMessages=L0={}));var EL=class e extends rY.ServiceObject{static{a(this,"Bucket")}getFilesStream(t){return new idn.Readable}constructor(t,r,n){var i,s,o,u;n=n||{};r=r.replace(/^gs:\/\//,"").replace(/\/+$/,"");const l={};if((i=n===null||n===void 0?void 0:n.preconditionOpts)===null||i===void 0?void 0:i.ifGenerationMatch){l.ifGenerationMatch=n.preconditionOpts.ifGenerationMatch}if((s=n===null||n===void 0?void 0:n.preconditionOpts)===null||s===void 0?void 0:s.ifGenerationNotMatch){l.ifGenerationNotMatch=n.preconditionOpts.ifGenerationNotMatch}if((o=n===null||n===void 0?void 0:n.preconditionOpts)===null||o===void 0?void 0:o.ifMetagenerationMatch){l.ifMetagenerationMatch=n.preconditionOpts.ifMetagenerationMatch}if((u=n===null||n===void 0?void 0:n.preconditionOpts)===null||u===void 0?void 0:u.ifMetagenerationNotMatch){l.ifMetagenerationNotMatch=n.preconditionOpts.ifMetagenerationNotMatch}const c=n.userProject;if(typeof c==="string"){l.userProject=c}const d={create:{reqOpts:{qs:l}},delete:{reqOpts:{qs:l}},exists:{reqOpts:{qs:l}},get:{reqOpts:{qs:l}},getMetadata:{reqOpts:{qs:l}},setMetadata:{reqOpts:{qs:l}}};super({parent:t,baseUrl:"/b",id:r,createMethod:t.createBucket.bind(t),methods:d});this.name=r;this.storage=t;this.userProject=n.userProject;this.acl=new d_t.Acl({request:this.request.bind(this),pathPrefix:"/acl"});this.acl.default=new d_t.Acl({request:this.request.bind(this),pathPrefix:"/defaultObjectAcl"});this.crc32cGenerator=n.crc32cGenerator||this.storage.crc32cGenerator;this.iam=new tdn.Iam(this);this.getFilesStream=f_t.paginator.streamify("getFiles");this.instanceRetryValue=t.retryOptions.autoRetry;this.instancePreconditionOpts=n===null||n===void 0?void 0:n.preconditionOpts}get cloudStorageURI(){const t=new sdn.URL("gs://");t.host=this.name;return t}addLifecycleRule(t,r,n){let i={};if(typeof r==="function"){n=r}else if(r){i=r}i=i||{};const s=Array.isArray(t)?t:[t];for(const o of s){if(o.condition.createdBefore instanceof Date){o.condition.createdBefore=o.condition.createdBefore.toISOString().replace(/T.+$/,"")}if(o.condition.customTimeBefore instanceof Date){o.condition.customTimeBefore=o.condition.customTimeBefore.toISOString().replace(/T.+$/,"")}if(o.condition.noncurrentTimeBefore instanceof Date){o.condition.noncurrentTimeBefore=o.condition.noncurrentTimeBefore.toISOString().replace(/T.+$/,"")}}if(i.append===false){this.setMetadata({lifecycle:{rule:s}},i,n);return}this.getMetadata((o,u)=>{var l,c;if(o){n(o);return}const d=Array.isArray((l=u.lifecycle)===null||l===void 0?void 0:l.rule)?(c=u.lifecycle)===null||c===void 0?void 0:c.rule:[];this.setMetadata({lifecycle:{rule:d.concat(s)}},i,n)})}combine(t,r,n,i){var s;if(!Array.isArray(t)||t.length===0){throw new Error(L0.PROVIDE_SOURCE_FILE)}if(!r){throw new Error(L0.DESTINATION_FILE_NOT_SPECIFIED)}let o={};if(typeof n==="function"){i=n}else if(n){o=n}this.disableAutoRetryConditionallyIdempotent_(this.methods.setMetadata,oO.setMetadata,o);const u=a(d=>{if(d instanceof BSe.File){return d}return this.file(d)},"convertToFile");t=t.map(u);const l=u(r);i=i||rY.util.noop;if(!l.metadata.contentType){const d=Jcn.contentType(l.name);if(d){l.metadata.contentType=d}}let c=this.storage.retryOptions.maxRetries;if(((s=l===null||l===void 0?void 0:l.instancePreconditionOpts)===null||s===void 0?void 0:s.ifGenerationMatch)===void 0&&o.ifGenerationMatch===void 0&&this.storage.retryOptions.idempotencyStrategy===aO.IdempotencyStrategy.RetryConditional||this.storage.retryOptions.idempotencyStrategy===aO.IdempotencyStrategy.RetryNever){c=0}if(o.ifGenerationMatch===void 0){Object.assign(o,l.instancePreconditionOpts,o)}l.request({method:"POST",uri:"/compose",maxRetries:c,json:{destination:{contentType:l.metadata.contentType},sourceObjects:t.map(d=>{const p={name:d.name};if(d.metadata&&d.metadata.generation){p.generation=parseInt(d.metadata.generation.toString())}return p})},qs:o},(d,p)=>{this.storage.retryOptions.autoRetry=this.instanceRetryValue;if(d){i(d,null,p);return}i(null,l,p)})}createChannel(t,r,n,i){if(typeof t!=="string"){throw new Error(L0.CHANNEL_ID_REQUIRED)}let s={};if(typeof n==="function"){i=n}else if(n){s=n}this.request({method:"POST",uri:"/o/watch",json:Object.assign({id:t,type:"web_hook"},r),qs:s},(o,u)=>{if(o){i(o,null,u);return}const l=u.resourceId;const c=this.storage.channel(t,l);c.metadata=u;i(null,c,u)})}createNotification(t,r,n){let i={};if(typeof r==="function"){n=r}else if(r){i=r}const s=t!==null&&typeof t==="object";if(s&&rY.util.isCustomType(t,"pubsub/topic")){t=t.name}if(typeof t!=="string"){throw new Error(L0.TOPIC_NAME_REQUIRED)}const o=Object.assign({topic:t},i);if(o.topic.indexOf("projects")!==0){o.topic="projects/{{projectId}}/topics/"+o.topic}o.topic="//pubsub.googleapis.com/"+o.topic;if(!o.payloadFormat){o.payloadFormat="JSON_API_V1"}const u={};if(o.userProject){u.userProject=o.userProject;delete o.userProject}this.request({method:"POST",uri:"/notificationConfigs",json:(0,edn.convertObjKeysToSnakeCase)(o),qs:u,maxRetries:0},(l,c)=>{if(l){n(l,null,c);return}const d=this.notification(c.id);d.metadata=c;n(null,d,c)})}deleteFiles(t,r){let n={};if(typeof t==="function"){r=t}else if(t){n=t}const i=10;const s=1e3;const o=[];const u=a(l=>{return l.delete(n).catch(c=>{if(!n.force){throw c}o.push(c)})},"deleteFile");(async()=>{try{let l=[];const c=(0,l_t.default)(i);const d=this.getFilesStream(n);for await(const p of d){if(l.length>=s){await Promise.all(l);l=[]}l.push(c(()=>u(p)).catch(f=>{d.destroy();throw f}))}await Promise.all(l);r(o.length>0?o:null)}catch(l){r(l);return}})()}deleteLabels(t,r,n){let i=new Array;let s={};if(typeof t==="function"){n=t}else if(typeof t==="string"){i=[t]}else if(Array.isArray(t)){i=t}else if(t){s=t}if(typeof r==="function"){n=r}else if(r){s=r}const o=a(u=>{const l=u.reduce((c,d)=>{c[d]=null;return c},{});if((s===null||s===void 0?void 0:s.ifMetagenerationMatch)!==void 0){this.setLabels(l,s,n)}else{this.setLabels(l,n)}},"deleteLabels");if(i.length===0){this.getLabels((u,l)=>{if(u){n(u);return}o(Object.keys(l))})}else{o(i)}}disableRequesterPays(t,r){let n={};if(typeof t==="function"){r=t}else if(t){n=t}this.setMetadata({billing:{requesterPays:false}},n,r)}enableLogging(t,r){if(!t||typeof t==="function"||typeof t.prefix==="undefined"){throw new Error(L0.CONFIGURATION_OBJECT_PREFIX_REQUIRED)}let n=this.id;if(t.bucket&&t.bucket instanceof e){n=t.bucket.id}else if(t.bucket&&typeof t.bucket==="string"){n=t.bucket}const i={};if(t===null||t===void 0?void 0:t.ifMetagenerationMatch){i.ifMetagenerationMatch=t.ifMetagenerationMatch}if(t===null||t===void 0?void 0:t.ifMetagenerationNotMatch){i.ifMetagenerationNotMatch=t.ifMetagenerationNotMatch}(async()=>{try{const[s]=await this.iam.getPolicy();s.bindings.push({members:["group:cloud-storage-analytics@google.com"],role:"roles/storage.objectCreator"});await this.iam.setPolicy(s);this.setMetadata({logging:{logBucket:n,logObjectPrefix:t.prefix}},i,r)}catch(s){r(s);return}})()}enableRequesterPays(t,r){let n={};if(typeof t==="function"){r=t}else if(t){n=t}this.setMetadata({billing:{requesterPays:true}},n,r)}file(t,r){if(!t){throw Error(L0.SPECIFY_FILE_NAME)}return new BSe.File(this,t,r)}getFiles(t,r){let n=typeof t==="object"?t:{};if(!r){r=t}n=Object.assign({},n);this.request({uri:"/o",qs:n},(i,s)=>{if(i){r(i,null,null,s);return}const o=s.items?s.items:[];const u=o.map(c=>{const d={};if(n.versions){d.generation=c.generation}if(c.kmsKeyName){d.kmsKeyName=c.kmsKeyName}const p=this.file(c.name,d);p.metadata=c;return p});let l=null;if(s.nextPageToken){l=Object.assign({},n,{pageToken:s.nextPageToken})}r(null,u,l,s)})}getLabels(t,r){let n={};if(typeof t==="function"){r=t}else if(t){n=t}this.getMetadata(n,(i,s)=>{if(i){r(i,null);return}r(null,(s===null||s===void 0?void 0:s.labels)||{})})}getNotifications(t,r){let n={};if(typeof t==="function"){r=t}else if(t){n=t}this.request({uri:"/notificationConfigs",qs:n},(i,s)=>{if(i){r(i,null,s);return}const o=s.items?s.items:[];const u=o.map(l=>{const c=this.notification(l.id);c.metadata=l;return c});r(null,u,s)})}getSignedUrl(t,r){const n=MSe[t.action];const i={method:n,expires:t.expires,version:t.version,cname:t.cname,extensionHeaders:t.extensionHeaders||{},queryParams:t.queryParams||{}};if(!this.signer){this.signer=new ndn.URLSigner(this.storage.authClient,this)}this.signer.getSignedUrl(i).then(s=>r(null,s),r)}lock(t,r){const n=typeof t;if(n!=="number"&&n!=="string"){throw new Error(L0.METAGENERATION_NOT_PROVIDED)}this.request({method:"POST",uri:"/lockRetentionPolicy",qs:{ifMetagenerationMatch:t}},r)}makePrivate(t,r){var n,i,s,o;const u=typeof t==="object"?t:{};r=typeof t==="function"?t:r;u.private=true;const l={predefinedAcl:"projectPrivate"};if(u.userProject){l.userProject=u.userProject}if((n=u.preconditionOpts)===null||n===void 0?void 0:n.ifGenerationMatch){l.ifGenerationMatch=u.preconditionOpts.ifGenerationMatch}if((i=u.preconditionOpts)===null||i===void 0?void 0:i.ifGenerationNotMatch){l.ifGenerationNotMatch=u.preconditionOpts.ifGenerationNotMatch}if((s=u.preconditionOpts)===null||s===void 0?void 0:s.ifMetagenerationMatch){l.ifMetagenerationMatch=u.preconditionOpts.ifMetagenerationMatch}if((o=u.preconditionOpts)===null||o===void 0?void 0:o.ifMetagenerationNotMatch){l.ifMetagenerationNotMatch=u.preconditionOpts.ifMetagenerationNotMatch}const c={...u.metadata,acl:null};this.setMetadata(c,l,d=>{if(d){r(d)}const p=a(()=>{if(u.includeFiles){return(0,c_t.promisify)(this.makeAllFilesPublicPrivate_).call(this,u)}return Promise.resolve([])},"internalCall");p().then(f=>r(null,f)).catch(r)})}makePublic(t,r){const n=typeof t==="object"?t:{};r=typeof t==="function"?t:r;const i={public:true,...n};this.acl.add({entity:"allUsers",role:"READER"}).then(()=>{return this.acl.default.add({entity:"allUsers",role:"READER"})}).then(()=>{if(i.includeFiles){return(0,c_t.promisify)(this.makeAllFilesPublicPrivate_).call(this,i)}return[]}).then(s=>r(null,s),r)}notification(t){if(!t){throw new Error(L0.SUPPLY_NOTIFICATION_ID)}return new rdn.Notification(this,t)}removeRetentionPeriod(t,r){const n=typeof t==="object"?t:{};r=typeof t==="function"?t:r;this.setMetadata({retentionPolicy:null},n,r)}request(t,r){if(this.userProject&&(!t.qs||!t.qs.userProject)){t.qs={...t.qs,userProject:this.userProject}}return super.request(t,r)}setLabels(t,r,n){const i=typeof r==="object"?r:{};n=typeof r==="function"?r:n;n=n||rY.util.noop;this.setMetadata({labels:t},i,n)}setMetadata(t,r,n){const i=typeof r==="object"?r:{};n=typeof r==="function"?r:n;this.disableAutoRetryConditionallyIdempotent_(this.methods.setMetadata,oO.setMetadata,i);super.setMetadata(t,i).then(s=>n(null,...s)).catch(n).finally(()=>{this.storage.retryOptions.autoRetry=this.instanceRetryValue})}setRetentionPeriod(t,r,n){const i=typeof r==="object"?r:{};n=typeof r==="function"?r:n;this.setMetadata({retentionPolicy:{retentionPeriod:t.toString()}},i,n)}setCorsConfiguration(t,r,n){const i=typeof r==="object"?r:{};n=typeof r==="function"?r:n;this.setMetadata({cors:t},i,n)}setStorageClass(t,r,n){const i=typeof r==="object"?r:{};n=typeof r==="function"?r:n;t=t.replace(/-/g,"_").replace(/([a-z])([A-Z])/g,(s,o,u)=>{return o+"_"+u}).toUpperCase();this.setMetadata({storageClass:t},i,n)}setUserProject(t){this.userProject=t;const r=["create","delete","exists","get","getMetadata","setMetadata"];r.forEach(n=>{const i=this.methods[n];if(typeof i==="object"){if(typeof i.reqOpts==="object"){Object.assign(i.reqOpts.qs,{userProject:t})}else{i.reqOpts={qs:{userProject:t}}}}})}upload(t,r,n){var i,s;const o=a(d=>{const p=(0,Zcn.default)(async f=>{await new Promise((m,h)=>{var g,_;if(d===0&&((_=(g=c===null||c===void 0?void 0:c.storage)===null||g===void 0?void 0:g.retryOptions)===null||_===void 0?void 0:_.autoRetry)){c.storage.retryOptions.autoRetry=false}const v=c.createWriteStream(u);if(u.onUploadProgress){v.on("progress",u.onUploadProgress)}Xcn.createReadStream(t).on("error",f).pipe(v).on("error",S=>{if(this.storage.retryOptions.autoRetry&&this.storage.retryOptions.retryableErrorFn(S)){return h(S)}else{return f(S)}}).on("finish",()=>{return m()})})},{retries:d,factor:this.storage.retryOptions.retryDelayMultiplier,maxTimeout:this.storage.retryOptions.maxRetryDelay*1e3,maxRetryTime:this.storage.retryOptions.totalTimeout*1e3});if(!n){return p}else{return p.then(()=>{if(n){return n(null,c,c.metadata)}}).catch(n)}},"upload");if(global["GCLOUD_SANDBOX_ENV"]){return}let u=typeof r==="object"?r:{};n=typeof r==="function"?r:n;u=Object.assign({metadata:{}},u);let l=this.storage.retryOptions.maxRetries;if(((i=u===null||u===void 0?void 0:u.preconditionOpts)===null||i===void 0?void 0:i.ifGenerationMatch)===void 0&&((s=this.instancePreconditionOpts)===null||s===void 0?void 0:s.ifGenerationMatch)===void 0&&this.storage.retryOptions.idempotencyStrategy===aO.IdempotencyStrategy.RetryConditional||this.storage.retryOptions.idempotencyStrategy===aO.IdempotencyStrategy.RetryNever){l=0}let c;if(u.destination instanceof BSe.File){c=u.destination}else if(u.destination!==null&&typeof u.destination==="string"){c=this.file(u.destination,{encryptionKey:u.encryptionKey,kmsKeyName:u.kmsKeyName,preconditionOpts:this.instancePreconditionOpts})}else{const d=Qcn.basename(t);c=this.file(d,{encryptionKey:u.encryptionKey,kmsKeyName:u.kmsKeyName,preconditionOpts:this.instancePreconditionOpts})}o(l)}makeAllFilesPublicPrivate_(t,r){const n=10;const i=[];const s=[];const o=typeof t==="object"?t:{};r=typeof t==="function"?t:r;const u=a(async l=>{try{await(o.public?l.makePublic():l.makePrivate(o));s.push(l)}catch(c){if(!o.force){throw c}i.push(c)}},"processFile");this.getFiles(o).then(([l])=>{const c=(0,l_t.default)(n);const d=l.map(p=>{return c(()=>u(p))});return Promise.all(d)}).then(()=>r(i.length>0?i:null,s),l=>r(l,s))}getId(){return this.id}disableAutoRetryConditionallyIdempotent_(t,r,n){var i,s;if(typeof t==="object"&&((s=(i=t===null||t===void 0?void 0:t.reqOpts)===null||i===void 0?void 0:i.qs)===null||s===void 0?void 0:s.ifMetagenerationMatch)===void 0&&(n===null||n===void 0?void 0:n.ifMetagenerationMatch)===void 0&&(r===oO.setMetadata||r===oO.delete)&&this.storage.retryOptions.idempotencyStrategy===aO.IdempotencyStrategy.RetryConditional){this.storage.retryOptions.autoRetry=false}else if(this.storage.retryOptions.idempotencyStrategy===aO.IdempotencyStrategy.RetryNever){this.storage.retryOptions.autoRetry=false}}};_u.Bucket=EL;f_t.paginator.extend(EL,"getFiles");(0,Ycn.promisifyAll)(EL,{exclude:["cloudStorageURI","request","file","notification"]})});var USe=y(iY=>{"use strict";Object.defineProperty(iY,"__esModule",{value:true});iY.Channel=void 0;var m_t=rE();var adn=I0();var nY=class extends m_t.ServiceObject{static{a(this,"Channel")}constructor(t,r,n){const i={parent:t,baseUrl:"/channels",id:"",methods:{}};super(i);this.metadata.id=r;this.metadata.resourceId=n}stop(t){t=t||m_t.util.noop;this.request({method:"POST",uri:"/stop",json:this.metadata},(r,n)=>{t(r,n)})}};iY.Channel=nY;(0,adn.promisifyAll)(nY)});var $Se=y(aY=>{"use strict";Object.defineProperty(aY,"__esModule",{value:true});aY.HmacKey=void 0;var odn=rE();var udn=nO();var ldn=I0();var sY=class extends odn.ServiceObject{static{a(this,"HmacKey")}constructor(t,r,n){const i={delete:true,get:true,getMetadata:true,setMetadata:{reqOpts:{method:"PUT"}}};const s=n&&n.projectId||t.projectId;super({parent:t,id:r,baseUrl:`/projects/${s}/hmacKeys`,methods:i});this.storage=t;this.instanceRetryValue=t.retryOptions.autoRetry}setMetadata(t,r,n){if(this.storage.retryOptions.idempotencyStrategy!==udn.IdempotencyStrategy.RetryAlways){this.storage.retryOptions.autoRetry=false}const i=typeof r==="object"?r:{};n=typeof r==="function"?r:n;super.setMetadata(t,i).then(s=>n(null,...s)).catch(n).finally(()=>{this.storage.retryOptions.autoRetry=this.instanceRetryValue})}};aY.HmacKey=sY;(0,ldn.promisifyAll)(sY)});var nO=y(cs=>{"use strict";Object.defineProperty(cs,"__esModule",{value:true});cs.Storage=cs.RETRYABLE_ERR_FN_DEFAULT=cs.MAX_RETRY_DELAY_DEFAULT=cs.TOTAL_TIMEOUT_DEFAULT=cs.RETRY_DELAY_MULTIPLIER_DEFAULT=cs.MAX_RETRY_DEFAULT=cs.AUTO_RETRY_DEFAULT=cs.PROTOCOL_REGEX=cs.StorageExceptionMessages=cs.ExceptionMessages=cs.IdempotencyStrategy=void 0;var cdn=rE();var jSe=fSe();var ddn=I0();var h_t=require("stream");var y_t=JW();var __t=USe();var pdn=gL();var oY=P0();var fdn=KR();var v_t=$Se();var mdn=hL();var GSe;(function(e){e[e["RetryAlways"]=0]="RetryAlways";e[e["RetryConditional"]=1]="RetryConditional";e[e["RetryNever"]=2]="RetryNever"})(GSe||(cs.IdempotencyStrategy=GSe={}));var g_t;(function(e){e["EXPIRATION_DATE_INVALID"]="The expiration date provided was invalid.";e["EXPIRATION_DATE_PAST"]="An expiration date cannot be in the past."})(g_t||(cs.ExceptionMessages=g_t={}));var uO;(function(e){e["BUCKET_NAME_REQUIRED"]="A bucket name is needed to use Cloud Storage.";e["BUCKET_NAME_REQUIRED_CREATE"]="A name is required to create a bucket.";e["HMAC_SERVICE_ACCOUNT"]="The first argument must be a service account email to create an HMAC key.";e["HMAC_ACCESS_ID"]="An access ID is needed to create an HmacKey object."})(uO||(cs.StorageExceptionMessages=uO={}));cs.PROTOCOL_REGEX=/^(\w*):\/\//;cs.AUTO_RETRY_DEFAULT=true;cs.MAX_RETRY_DEFAULT=3;cs.RETRY_DELAY_MULTIPLIER_DEFAULT=2;cs.TOTAL_TIMEOUT_DEFAULT=600;cs.MAX_RETRY_DELAY_DEFAULT=64;var hdn=GSe.RetryConditional;var gdn=a(function(e){var t;const r=a(n=>{return n.includes("eai_again")||n==="econnreset"||n==="unexpected connection closure"||n==="epipe"||n==="socket connection timeout"},"isConnectionProblem");if(e){if([408,429,500,502,503,504].indexOf(e.code)!==-1){return true}if(typeof e.code==="string"){if(["408","429","500","502","503","504"].indexOf(e.code)!==-1){return true}const n=e.code.toLowerCase();if(r(n)){return true}}if(e.errors){for(const n of e.errors){const i=(t=n===null||n===void 0?void 0:n.reason)===null||t===void 0?void 0:t.toString().toLowerCase();if(i&&r(i)){return true}}}}return false},"RETRYABLE_ERR_FN_DEFAULT");cs.RETRYABLE_ERR_FN_DEFAULT=gdn;var F0=class e extends cdn.Service{static{a(this,"Storage")}getBucketsStream(){return new h_t.Readable}getHmacKeysStream(){return new h_t.Readable}constructor(t={}){var r,n,i,s,o,u,l,c,d,p,f,m,h,g;let _="https://storage.googleapis.com";let v=false;const S=process.env.STORAGE_EMULATOR_HOST;if(typeof S==="string"){_=e.sanitizeEndpoint(S);v=true}if(t.apiEndpoint){_=e.sanitizeEndpoint(t.apiEndpoint);v=true}t=Object.assign({},t,{apiEndpoint:_});const E=S||`${t.apiEndpoint}/storage/v1`;const b={apiEndpoint:t.apiEndpoint,retryOptions:{autoRetry:((r=t.retryOptions)===null||r===void 0?void 0:r.autoRetry)!==void 0?(n=t.retryOptions)===null||n===void 0?void 0:n.autoRetry:cs.AUTO_RETRY_DEFAULT,maxRetries:((i=t.retryOptions)===null||i===void 0?void 0:i.maxRetries)?(s=t.retryOptions)===null||s===void 0?void 0:s.maxRetries:cs.MAX_RETRY_DEFAULT,retryDelayMultiplier:((o=t.retryOptions)===null||o===void 0?void 0:o.retryDelayMultiplier)?(u=t.retryOptions)===null||u===void 0?void 0:u.retryDelayMultiplier:cs.RETRY_DELAY_MULTIPLIER_DEFAULT,totalTimeout:((l=t.retryOptions)===null||l===void 0?void 0:l.totalTimeout)?(c=t.retryOptions)===null||c===void 0?void 0:c.totalTimeout:cs.TOTAL_TIMEOUT_DEFAULT,maxRetryDelay:((d=t.retryOptions)===null||d===void 0?void 0:d.maxRetryDelay)?(p=t.retryOptions)===null||p===void 0?void 0:p.maxRetryDelay:cs.MAX_RETRY_DELAY_DEFAULT,retryableErrorFn:((f=t.retryOptions)===null||f===void 0?void 0:f.retryableErrorFn)?(m=t.retryOptions)===null||m===void 0?void 0:m.retryableErrorFn:cs.RETRYABLE_ERR_FN_DEFAULT,idempotencyStrategy:((h=t.retryOptions)===null||h===void 0?void 0:h.idempotencyStrategy)!==void 0?(g=t.retryOptions)===null||g===void 0?void 0:g.idempotencyStrategy:hdn},baseUrl:E,customEndpoint:v,useAuthWithCustomEndpoint:t===null||t===void 0?void 0:t.useAuthWithCustomEndpoint,projectIdRequired:false,scopes:["https://www.googleapis.com/auth/iam","https://www.googleapis.com/auth/cloud-platform","https://www.googleapis.com/auth/devstorage.full_control"],packageJson:(0,fdn.getPackageJSON)()};super(b,t);this.acl=e.acl;this.crc32cGenerator=t.crc32cGenerator||mdn.CRC32C_DEFAULT_VALIDATOR_GENERATOR;this.retryOptions=b.retryOptions;this.getBucketsStream=jSe.paginator.streamify("getBuckets");this.getHmacKeysStream=jSe.paginator.streamify("getHmacKeys")}static sanitizeEndpoint(t){if(!cs.PROTOCOL_REGEX.test(t)){t=`https://${t}`}return t.replace(/\/+$/,"")}bucket(t,r){if(!t){throw new Error(uO.BUCKET_NAME_REQUIRED)}return new y_t.Bucket(this,t,r)}channel(t,r){return new __t.Channel(this,t,r)}createBucket(t,r,n){if(!t){throw new Error(uO.BUCKET_NAME_REQUIRED_CREATE)}let i;if(!n){n=r;i={}}else{i=r}const s={...i,name:t};const o={archive:"ARCHIVE",coldline:"COLDLINE",dra:"DURABLE_REDUCED_AVAILABILITY",multiRegional:"MULTI_REGIONAL",nearline:"NEARLINE",regional:"REGIONAL",standard:"STANDARD"};const u=Object.keys(o);for(const c of u){if(s[c]){if(i.storageClass&&i.storageClass!==c){throw new Error(`Both \`${c}\` and \`storageClass\` were provided.`)}s.storageClass=o[c];delete s[c]}}if(s.requesterPays){s.billing={requesterPays:s.requesterPays};delete s.requesterPays}const l={project:this.projectId};if(s.userProject){l.userProject=s.userProject;delete s.userProject}this.request({method:"POST",uri:"/b",qs:l,json:s},(c,d)=>{if(c){n(c,null,d);return}const p=this.bucket(t);p.metadata=d;n(null,p,d)})}createHmacKey(t,r,n){if(typeof t!=="string"){throw new Error(uO.HMAC_SERVICE_ACCOUNT)}const{options:i,callback:s}=(0,oY.normalize)(r,n);const o=Object.assign({},i,{serviceAccountEmail:t});const u=o.projectId||this.projectId;delete o.projectId;this.request({method:"POST",uri:`/projects/${u}/hmacKeys`,qs:o,maxRetries:0},(l,c)=>{if(l){s(l,null,null,c);return}const d=c.metadata;const p=this.hmacKey(d.accessId,{projectId:d.projectId});p.metadata=c.metadata;s(null,p,c.secret,c)})}getBuckets(t,r){const{options:n,callback:i}=(0,oY.normalize)(t,r);n.project=n.project||this.projectId;this.request({uri:"/b",qs:n},(s,o)=>{if(s){i(s,null,null,o);return}const u=o.items?o.items:[];const l=u.map(d=>{const p=this.bucket(d.id);p.metadata=d;return p});const c=o.nextPageToken?Object.assign({},n,{pageToken:o.nextPageToken}):null;i(null,l,c,o)})}getHmacKeys(t,r){const{options:n,callback:i}=(0,oY.normalize)(t,r);const s=Object.assign({},n);const o=s.projectId||this.projectId;delete s.projectId;this.request({uri:`/projects/${o}/hmacKeys`,qs:s},(u,l)=>{if(u){i(u,null,null,l);return}const c=l.items?l.items:[];const d=c.map(f=>{const m=this.hmacKey(f.accessId,{projectId:f.projectId});m.metadata=f;return m});const p=l.nextPageToken?Object.assign({},n,{pageToken:l.nextPageToken}):null;i(null,d,p,l)})}getServiceAccount(t,r){const{options:n,callback:i}=(0,oY.normalize)(t,r);this.request({uri:`/projects/${this.projectId}/serviceAccount`,qs:n},(s,o)=>{if(s){i(s,null,o);return}const u={};for(const l in o){if(o.hasOwnProperty(l)){const c=l.replace(/_(\w)/g,(d,p)=>p.toUpperCase());u[c]=o[l]}}i(null,u,o)})}hmacKey(t,r){if(!t){throw new Error(uO.HMAC_ACCESS_ID)}return new v_t.HmacKey(this,t,r)}};cs.Storage=F0;F0.Bucket=y_t.Bucket;F0.Channel=__t.Channel;F0.File=pdn.File;F0.HmacKey=v_t.HmacKey;F0.acl={OWNER_ROLE:"OWNER",READER_ROLE:"READER",WRITER_ROLE:"WRITER"};jSe.paginator.extend(F0,["getBuckets","getHmacKeys"]);(0,ddn.promisifyAll)(F0,{exclude:["bucket","channel","hmacKey"]})});var uY=y(fy=>{"use strict";var E_t=":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";var ydn=E_t+"\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040";var b_t="["+E_t+"]["+ydn+"]*";var _dn=new RegExp("^"+b_t+"$");var vdn=a(function(e,t){const r=[];let n=t.exec(e);while(n){const i=[];i.startIndex=t.lastIndex-n[0].length;const s=n.length;for(let o=0;o<s;o++){i.push(n[o])}r.push(i);n=t.exec(e)}return r},"getAllMatches");var Edn=a(function(e){const t=_dn.exec(e);return!(t===null||typeof t==="undefined")},"isName");fy.isExist=function(e){return typeof e!=="undefined"};fy.isEmptyObject=function(e){return Object.keys(e).length===0};fy.merge=function(e,t,r){if(t){const n=Object.keys(t);const i=n.length;for(let s=0;s<i;s++){if(r==="strict"){e[n[s]]=[t[n[s]]]}else{e[n[s]]=t[n[s]]}}}};fy.getValue=function(e){if(fy.isExist(e)){return e}else{return""}};fy.isName=Edn;fy.getAllMatches=vdn;fy.nameRegexp=b_t});var VSe=y(T_t=>{"use strict";var HSe=uY();var bdn={allowBooleanAttributes:false,unpairedTags:[]};T_t.validate=function(e,t){t=Object.assign({},bdn,t);const r=[];let n=false;let i=false;if(e[0]==="\uFEFF"){e=e.substr(1)}for(let s=0;s<e.length;s++){if(e[s]==="<"&&e[s+1]==="?"){s+=2;s=A_t(e,s);if(s.err)return s}else if(e[s]==="<"){let o=s;s++;if(e[s]==="!"){s=C_t(e,s);continue}else{let u=false;if(e[s]==="/"){u=true;s++}let l="";for(;s<e.length&&e[s]!==">"&&e[s]!==" "&&e[s]!==" "&&e[s]!=="\n"&&e[s]!=="\r";s++){l+=e[s]}l=l.trim();if(l[l.length-1]==="/"){l=l.substring(0,l.length-1);s--}if(!Odn(l)){let p;if(l.trim().length===0){p="Invalid space after '<'."}else{p="Tag '"+l+"' is an invalid name."}return Io("InvalidTag",p,dd(e,s))}const c=Cdn(e,s);if(c===false){return Io("InvalidAttr","Attributes for '"+l+"' have open quote.",dd(e,s))}let d=c.value;s=c.index;if(d[d.length-1]==="/"){const p=s-d.length;d=d.substring(0,d.length-1);const f=w_t(d,t);if(f===true){n=true}else{return Io(f.err.code,f.err.msg,dd(e,p+f.err.line))}}else if(u){if(!c.tagClosed){return Io("InvalidTag","Closing tag '"+l+"' doesn't have proper closing.",dd(e,s))}else if(d.trim().length>0){return Io("InvalidTag","Closing tag '"+l+"' can't have attributes or invalid starting.",dd(e,o))}else{const p=r.pop();if(l!==p.tagName){let f=dd(e,p.tagStartPos);return Io("InvalidTag","Expected closing tag '"+p.tagName+"' (opened in line "+f.line+", col "+f.col+") instead of closing tag '"+l+"'.",dd(e,o))}if(r.length==0){i=true}}}else{const p=w_t(d,t);if(p!==true){return Io(p.err.code,p.err.msg,dd(e,s-d.length+p.err.line))}if(i===true){return Io("InvalidXml","Multiple possible root nodes found.",dd(e,s))}else if(t.unpairedTags.indexOf(l)!==-1){}else{r.push({tagName:l,tagStartPos:o})}n=true}for(s++;s<e.length;s++){if(e[s]==="<"){if(e[s+1]==="!"){s++;s=C_t(e,s);continue}else if(e[s+1]==="?"){s=A_t(e,++s);if(s.err)return s}else{break}}else if(e[s]==="&"){const p=xdn(e,s);if(p==-1)return Io("InvalidChar","char '&' is not expected.",dd(e,s));s=p}else{if(i===true&&!S_t(e[s])){return Io("InvalidXml","Extra text at the end",dd(e,s))}}}if(e[s]==="<"){s--}}}else{if(S_t(e[s])){continue}return Io("InvalidChar","char '"+e[s]+"' is not expected.",dd(e,s))}}if(!n){return Io("InvalidXml","Start tag expected.",1)}else if(r.length==1){return Io("InvalidTag","Unclosed tag '"+r[0].tagName+"'.",dd(e,r[0].tagStartPos))}else if(r.length>0){return Io("InvalidXml","Invalid '"+JSON.stringify(r.map(s=>s.tagName),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1})}return true};function S_t(e){return e===" "||e===" "||e==="\n"||e==="\r"}a(S_t,"isWhiteSpace");function A_t(e,t){const r=t;for(;t<e.length;t++){if(e[t]=="?"||e[t]==" "){const n=e.substr(r,t-r);if(t>5&&n==="xml"){return Io("InvalidXml","XML declaration allowed only at the start of the document.",dd(e,t))}else if(e[t]=="?"&&e[t+1]==">"){t++;break}else{continue}}}return t}a(A_t,"readPI");function C_t(e,t){if(e.length>t+5&&e[t+1]==="-"&&e[t+2]==="-"){for(t+=3;t<e.length;t++){if(e[t]==="-"&&e[t+1]==="-"&&e[t+2]===">"){t+=2;break}}}else if(e.length>t+8&&e[t+1]==="D"&&e[t+2]==="O"&&e[t+3]==="C"&&e[t+4]==="T"&&e[t+5]==="Y"&&e[t+6]==="P"&&e[t+7]==="E"){let r=1;for(t+=8;t<e.length;t++){if(e[t]==="<"){r++}else if(e[t]===">"){r--;if(r===0){break}}}}else if(e.length>t+9&&e[t+1]==="["&&e[t+2]==="C"&&e[t+3]==="D"&&e[t+4]==="A"&&e[t+5]==="T"&&e[t+6]==="A"&&e[t+7]==="["){for(t+=8;t<e.length;t++){if(e[t]==="]"&&e[t+1]==="]"&&e[t+2]===">"){t+=2;break}}}return t}a(C_t,"readCommentAndCDATA");var Sdn='"';var Adn="'";function Cdn(e,t){let r="";let n="";let i=false;for(;t<e.length;t++){if(e[t]===Sdn||e[t]===Adn){if(n===""){n=e[t]}else if(n!==e[t]){}else{n=""}}else if(e[t]===">"){if(n===""){i=true;break}}r+=e[t]}if(n!==""){return false}return{value:r,index:t,tagClosed:i}}a(Cdn,"readAttributeStr");var wdn=new RegExp(`(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['"])(([\\s\\S])*?)\\5)?`,"g");function w_t(e,t){const r=HSe.getAllMatches(e,wdn);const n={};for(let i=0;i<r.length;i++){if(r[i][1].length===0){return Io("InvalidAttr","Attribute '"+r[i][2]+"' has no space in starting.",bL(r[i]))}else if(r[i][3]!==void 0&&r[i][4]===void 0){return Io("InvalidAttr","Attribute '"+r[i][2]+"' is without value.",bL(r[i]))}else if(r[i][3]===void 0&&!t.allowBooleanAttributes){return Io("InvalidAttr","boolean attribute '"+r[i][2]+"' is not allowed.",bL(r[i]))}const s=r[i][2];if(!Rdn(s)){return Io("InvalidAttr","Attribute '"+s+"' is an invalid name.",bL(r[i]))}if(!n.hasOwnProperty(s)){n[s]=1}else{return Io("InvalidAttr","Attribute '"+s+"' is repeated.",bL(r[i]))}}return true}a(w_t,"validateAttributeString");function Tdn(e,t){let r=/\d/;if(e[t]==="x"){t++;r=/[\da-fA-F]/}for(;t<e.length;t++){if(e[t]===";")return t;if(!e[t].match(r))break}return-1}a(Tdn,"validateNumberAmpersand");function xdn(e,t){t++;if(e[t]===";")return-1;if(e[t]==="#"){t++;return Tdn(e,t)}let r=0;for(;t<e.length;t++,r++){if(e[t].match(/\w/)&&r<20)continue;if(e[t]===";")break;return-1}return t}a(xdn,"validateAmpersand");function Io(e,t,r){return{err:{code:e,msg:t,line:r.line||r,col:r.col}}}a(Io,"getErrorObject");function Rdn(e){return HSe.isName(e)}a(Rdn,"validateAttrName");function Odn(e){return HSe.isName(e)}a(Odn,"validateTagName");function dd(e,t){const r=e.substring(0,t).split(/\r?\n/);return{line:r.length,col:r[r.length-1].length+1}}a(dd,"getLineNumberForPosition");function bL(e){return e.startIndex+e[1].length}a(bL,"getPositionFromMatch")});var R_t=y(zSe=>{var x_t={preserveOrder:false,attributeNamePrefix:"@_",attributesGroupName:false,textNodeName:"#text",ignoreAttributes:true,removeNSPrefix:false,allowBooleanAttributes:false,parseTagValue:true,parseAttributeValue:false,trimValues:true,cdataPropName:false,numberParseOptions:{hex:true,leadingZeros:true,eNotation:true},tagValueProcessor:function(e,t){return t},attributeValueProcessor:function(e,t){return t},stopNodes:[],alwaysCreateTextNode:false,isArray:()=>false,commentPropName:false,unpairedTags:[],processEntities:true,htmlEntities:false,ignoreDeclaration:false,ignorePiTags:false,transformTagName:false,transformAttributeName:false,updateTag:function(e,t,r){return e}};var Pdn=a(function(e){return Object.assign({},x_t,e)},"buildOptions");zSe.buildOptions=Pdn;zSe.defaultOptions=x_t});var P_t=y((nNs,O_t)=>{"use strict";var KSe=class{static{a(this,"XmlNode")}constructor(t){this.tagname=t;this.child=[];this[":@"]={}}add(t,r){if(t==="__proto__")t="#__proto__";this.child.push({[t]:r})}addChild(t){if(t.tagname==="__proto__")t.tagname="#__proto__";if(t[":@"]&&Object.keys(t[":@"]).length>0){this.child.push({[t.tagname]:t.child,[":@"]:t[":@"]})}else{this.child.push({[t.tagname]:t.child})}}};O_t.exports=KSe});var I_t=y((sNs,N_t)=>{var Ndn=uY();function Idn(e,t){const r={};if(e[t+3]==="O"&&e[t+4]==="C"&&e[t+5]==="T"&&e[t+6]==="Y"&&e[t+7]==="P"&&e[t+8]==="E"){t=t+9;let n=1;let i=false,s=false;let o="";for(;t<e.length;t++){if(e[t]==="<"&&!s){if(i&&Ldn(e,t)){t+=7;[entityName,val,t]=kdn(e,t+1);if(val.indexOf("&")===-1)r[qdn(entityName)]={regx:RegExp(`&${entityName};`,"g"),val}}else if(i&&Fdn(e,t))t+=8;else if(i&&Bdn(e,t))t+=8;else if(i&&Mdn(e,t))t+=9;else if(Ddn)s=true;else throw new Error("Invalid DOCTYPE");n++;o=""}else if(e[t]===">"){if(s){if(e[t-1]==="-"&&e[t-2]==="-"){s=false;n--}}else{n--}if(n===0){break}}else if(e[t]==="["){i=true}else{o+=e[t]}}if(n!==0){throw new Error(`Unclosed DOCTYPE`)}}else{throw new Error(`Invalid Tag instead of DOCTYPE`)}return{entities:r,i:t}}a(Idn,"readDocType");function kdn(e,t){let r="";for(;t<e.length&&(e[t]!=="'"&&e[t]!=='"');t++){r+=e[t]}r=r.trim();if(r.indexOf(" ")!==-1)throw new Error("External entites are not supported");const n=e[t++];let i="";for(;t<e.length&&e[t]!==n;t++){i+=e[t]}return[r,i,t]}a(kdn,"readEntityExp");function Ddn(e,t){if(e[t+1]==="!"&&e[t+2]==="-"&&e[t+3]==="-")return true;return false}a(Ddn,"isComment");function Ldn(e,t){if(e[t+1]==="!"&&e[t+2]==="E"&&e[t+3]==="N"&&e[t+4]==="T"&&e[t+5]==="I"&&e[t+6]==="T"&&e[t+7]==="Y")return true;return false}a(Ldn,"isEntity");function Fdn(e,t){if(e[t+1]==="!"&&e[t+2]==="E"&&e[t+3]==="L"&&e[t+4]==="E"&&e[t+5]==="M"&&e[t+6]==="E"&&e[t+7]==="N"&&e[t+8]==="T")return true;return false}a(Fdn,"isElement");function Bdn(e,t){if(e[t+1]==="!"&&e[t+2]==="A"&&e[t+3]==="T"&&e[t+4]==="T"&&e[t+5]==="L"&&e[t+6]==="I"&&e[t+7]==="S"&&e[t+8]==="T")return true;return false}a(Bdn,"isAttlist");function Mdn(e,t){if(e[t+1]==="!"&&e[t+2]==="N"&&e[t+3]==="O"&&e[t+4]==="T"&&e[t+5]==="A"&&e[t+6]==="T"&&e[t+7]==="I"&&e[t+8]==="O"&&e[t+9]==="N")return true;return false}a(Mdn,"isNotation");function qdn(e){if(Ndn.isName(e))return e;else throw new Error(`Invalid entity name ${e}`)}a(qdn,"validateEntityName");N_t.exports=Idn});var WSe=y((oNs,k_t)=>{var Udn=/^[-+]?0x[a-fA-F0-9]+$/;var $dn=/^([\-\+])?(0*)(\.[0-9]+([eE]\-?[0-9]+)?|[0-9]+(\.[0-9]+([eE]\-?[0-9]+)?)?)$/;if(!Number.parseInt&&window.parseInt){Number.parseInt=window.parseInt}if(!Number.parseFloat&&window.parseFloat){Number.parseFloat=window.parseFloat}var jdn={hex:true,leadingZeros:true,decimalPoint:".",eNotation:true};function Gdn(e,t={}){t=Object.assign({},jdn,t);if(!e||typeof e!=="string")return e;let r=e.trim();if(t.skipLike!==void 0&&t.skipLike.test(r))return e;else if(t.hex&&Udn.test(r)){return Number.parseInt(r,16)}else{const n=$dn.exec(r);if(n){const i=n[1];const s=n[2];let o=Hdn(n[3]);const u=n[4]||n[6];if(!t.leadingZeros&&s.length>0&&i&&r[2]!==".")return e;else if(!t.leadingZeros&&s.length>0&&!i&&r[1]!==".")return e;else{const l=Number(r);const c=""+l;if(c.search(/[eE]/)!==-1){if(t.eNotation)return l;else return e}else if(u){if(t.eNotation)return l;else return e}else if(r.indexOf(".")!==-1){if(c==="0"&&o==="")return l;else if(c===o)return l;else if(i&&c==="-"+o)return l;else return e}if(s){if(o===c)return l;else if(i+o===c)return l;else return e}if(r===c)return l;else if(r===i+c)return l;return e}}else{return e}}}a(Gdn,"toNumber");function Hdn(e){if(e&&e.indexOf(".")!==-1){e=e.replace(/0+$/,"");if(e===".")e="0";else if(e[0]===".")e="0"+e;else if(e[e.length-1]===".")e=e.substr(0,e.length-1);return e}return e}a(Hdn,"trimZeros");k_t.exports=Gdn});var L_t=y((cNs,D_t)=>{"use strict";var QSe=uY();var SL=P_t();var Vdn=I_t();var zdn=WSe();var lNs="<((!\\[CDATA\\[([\\s\\S]*?)(]]>))|((NAME:)?(NAME))([^>]*)>|((\\/)(NAME)\\s*>))([^<]*)".replace(/NAME/g,QSe.nameRegexp);var YSe=class{static{a(this,"OrderedObjParser")}constructor(t){this.options=t;this.currentNode=null;this.tagsNodeStack=[];this.docTypeEntities={};this.lastEntities={"apos":{regex:/&(apos|#39|#x27);/g,val:"'"},"gt":{regex:/&(gt|#62|#x3E);/g,val:">"},"lt":{regex:/&(lt|#60|#x3C);/g,val:"<"},"quot":{regex:/&(quot|#34|#x22);/g,val:'"'}};this.ampEntity={regex:/&(amp|#38|#x26);/g,val:"&"};this.htmlEntities={"space":{regex:/&(nbsp|#160);/g,val:" "},"cent":{regex:/&(cent|#162);/g,val:"\xA2"},"pound":{regex:/&(pound|#163);/g,val:"\xA3"},"yen":{regex:/&(yen|#165);/g,val:"\xA5"},"euro":{regex:/&(euro|#8364);/g,val:"\u20AC"},"copyright":{regex:/&(copy|#169);/g,val:"\xA9"},"reg":{regex:/&(reg|#174);/g,val:"\xAE"},"inr":{regex:/&(inr|#8377);/g,val:"\u20B9"}};this.addExternalEntities=Kdn;this.parseXml=Qdn;this.parseTextData=Wdn;this.resolveNameSpace=Ydn;this.buildAttributesMap=Jdn;this.isItStopNode=rpn;this.replaceEntitiesValue=epn;this.readStopNodeData=ipn;this.saveTextToParentTag=tpn;this.addChild=Zdn}};function Kdn(e){const t=Object.keys(e);for(let r=0;r<t.length;r++){const n=t[r];this.lastEntities[n]={regex:new RegExp("&"+n+";","g"),val:e[n]}}}a(Kdn,"addExternalEntities");function Wdn(e,t,r,n,i,s,o){if(e!==void 0){if(this.options.trimValues&&!n){e=e.trim()}if(e.length>0){if(!o)e=this.replaceEntitiesValue(e);const u=this.options.tagValueProcessor(t,e,r,i,s);if(u===null||u===void 0){return e}else if(typeof u!==typeof e||u!==e){return u}else if(this.options.trimValues){return JSe(e,this.options.parseTagValue,this.options.numberParseOptions)}else{const l=e.trim();if(l===e){return JSe(e,this.options.parseTagValue,this.options.numberParseOptions)}else{return e}}}}}a(Wdn,"parseTextData");function Ydn(e){if(this.options.removeNSPrefix){const t=e.split(":");const r=e.charAt(0)==="/"?"/":"";if(t[0]==="xmlns"){return""}if(t.length===2){e=r+t[1]}}return e}a(Ydn,"resolveNameSpace");var Xdn=new RegExp(`([^\\s=]+)\\s*(=\\s*(['"])([\\s\\S]*?)\\3)?`,"gm");function Jdn(e,t,r){if(!this.options.ignoreAttributes&&typeof e==="string"){const n=QSe.getAllMatches(e,Xdn);const i=n.length;const s={};for(let o=0;o<i;o++){const u=this.resolveNameSpace(n[o][1]);let l=n[o][4];let c=this.options.attributeNamePrefix+u;if(u.length){if(this.options.transformAttributeName){c=this.options.transformAttributeName(c)}if(c==="__proto__")c="#__proto__";if(l!==void 0){if(this.options.trimValues){l=l.trim()}l=this.replaceEntitiesValue(l);const d=this.options.attributeValueProcessor(u,l,t);if(d===null||d===void 0){s[c]=l}else if(typeof d!==typeof l||d!==l){s[c]=d}else{s[c]=JSe(l,this.options.parseAttributeValue,this.options.numberParseOptions)}}else if(this.options.allowBooleanAttributes){s[c]=true}}}if(!Object.keys(s).length){return}if(this.options.attributesGroupName){const o={};o[this.options.attributesGroupName]=s;return o}return s}}a(Jdn,"buildAttributesMap");var Qdn=a(function(e){e=e.replace(/\r\n?/g,"\n");const t=new SL("!xml");let r=t;let n="";let i="";for(let s=0;s<e.length;s++){const o=e[s];if(o==="<"){if(e[s+1]==="/"){const u=PA(e,">",s,"Closing Tag is not closed.");let l=e.substring(s+2,u).trim();if(this.options.removeNSPrefix){const p=l.indexOf(":");if(p!==-1){l=l.substr(p+1)}}if(this.options.transformTagName){l=this.options.transformTagName(l)}if(r){n=this.saveTextToParentTag(n,r,i)}const c=i.substring(i.lastIndexOf(".")+1);if(l&&this.options.unpairedTags.indexOf(l)!==-1){throw new Error(`Unpaired tag can not be used as closing tag: </${l}>`)}let d=0;if(c&&this.options.unpairedTags.indexOf(c)!==-1){d=i.lastIndexOf(".",i.lastIndexOf(".")-1);this.tagsNodeStack.pop()}else{d=i.lastIndexOf(".")}i=i.substring(0,d);r=this.tagsNodeStack.pop();n="";s=u}else if(e[s+1]==="?"){let u=XSe(e,s,false,"?>");if(!u)throw new Error("Pi Tag is not closed.");n=this.saveTextToParentTag(n,r,i);if(this.options.ignoreDeclaration&&u.tagName==="?xml"||this.options.ignorePiTags){}else{const l=new SL(u.tagName);l.add(this.options.textNodeName,"");if(u.tagName!==u.tagExp&&u.attrExpPresent){l[":@"]=this.buildAttributesMap(u.tagExp,i,u.tagName)}this.addChild(r,l,i)}s=u.closeIndex+1}else if(e.substr(s+1,3)==="!--"){const u=PA(e,"-->",s+4,"Comment is not closed.");if(this.options.commentPropName){const l=e.substring(s+4,u-2);n=this.saveTextToParentTag(n,r,i);r.add(this.options.commentPropName,[{[this.options.textNodeName]:l}])}s=u}else if(e.substr(s+1,2)==="!D"){const u=Vdn(e,s);this.docTypeEntities=u.entities;s=u.i}else if(e.substr(s+1,2)==="!["){const u=PA(e,"]]>",s,"CDATA is not closed.")-2;const l=e.substring(s+9,u);n=this.saveTextToParentTag(n,r,i);if(this.options.cdataPropName){r.add(this.options.cdataPropName,[{[this.options.textNodeName]:l}])}else{let c=this.parseTextData(l,r.tagname,i,true,false,true);if(c==void 0)c="";r.add(this.options.textNodeName,c)}s=u+2}else{let u=XSe(e,s,this.options.removeNSPrefix);let l=u.tagName;const c=u.rawTagName;let d=u.tagExp;let p=u.attrExpPresent;let f=u.closeIndex;if(this.options.transformTagName){l=this.options.transformTagName(l)}if(r&&n){if(r.tagname!=="!xml"){n=this.saveTextToParentTag(n,r,i,false)}}const m=r;if(m&&this.options.unpairedTags.indexOf(m.tagname)!==-1){r=this.tagsNodeStack.pop();i=i.substring(0,i.lastIndexOf("."))}if(l!==t.tagname){i+=i?"."+l:l}if(this.isItStopNode(this.options.stopNodes,i,l)){let h="";if(d.length>0&&d.lastIndexOf("/")===d.length-1){s=u.closeIndex}else if(this.options.unpairedTags.indexOf(l)!==-1){s=u.closeIndex}else{const _=this.readStopNodeData(e,c,f+1);if(!_)throw new Error(`Unexpected end of ${c}`);s=_.i;h=_.tagContent}const g=new SL(l);if(l!==d&&p){g[":@"]=this.buildAttributesMap(d,i,l)}if(h){h=this.parseTextData(h,l,i,true,p,true,true)}i=i.substr(0,i.lastIndexOf("."));g.add(this.options.textNodeName,h);this.addChild(r,g,i)}else{if(d.length>0&&d.lastIndexOf("/")===d.length-1){if(l[l.length-1]==="/"){l=l.substr(0,l.length-1);i=i.substr(0,i.length-1);d=l}else{d=d.substr(0,d.length-1)}if(this.options.transformTagName){l=this.options.transformTagName(l)}const h=new SL(l);if(l!==d&&p){h[":@"]=this.buildAttributesMap(d,i,l)}this.addChild(r,h,i);i=i.substr(0,i.lastIndexOf("."))}else{const h=new SL(l);this.tagsNodeStack.push(r);if(l!==d&&p){h[":@"]=this.buildAttributesMap(d,i,l)}this.addChild(r,h,i);r=h}n="";s=f}}}else{n+=e[s]}}return t.child},"parseXml");function Zdn(e,t,r){const n=this.options.updateTag(t.tagname,r,t[":@"]);if(n===false){}else if(typeof n==="string"){t.tagname=n;e.addChild(t)}else{e.addChild(t)}}a(Zdn,"addChild");var epn=a(function(e){if(this.options.processEntities){for(let t in this.docTypeEntities){const r=this.docTypeEntities[t];e=e.replace(r.regx,r.val)}for(let t in this.lastEntities){const r=this.lastEntities[t];e=e.replace(r.regex,r.val)}if(this.options.htmlEntities){for(let t in this.htmlEntities){const r=this.htmlEntities[t];e=e.replace(r.regex,r.val)}}e=e.replace(this.ampEntity.regex,this.ampEntity.val)}return e},"replaceEntitiesValue");function tpn(e,t,r,n){if(e){if(n===void 0)n=Object.keys(t.child).length===0;e=this.parseTextData(e,t.tagname,r,false,t[":@"]?Object.keys(t[":@"]).length!==0:false,n);if(e!==void 0&&e!=="")t.add(this.options.textNodeName,e);e=""}return e}a(tpn,"saveTextToParentTag");function rpn(e,t,r){const n="*."+r;for(const i in e){const s=e[i];if(n===s||t===s)return true}return false}a(rpn,"isItStopNode");function npn(e,t,r=">"){let n;let i="";for(let s=t;s<e.length;s++){let o=e[s];if(n){if(o===n)n=""}else if(o==='"'||o==="'"){n=o}else if(o===r[0]){if(r[1]){if(e[s+1]===r[1]){return{data:i,index:s}}}else{return{data:i,index:s}}}else if(o===" "){o=" "}i+=o}}a(npn,"tagExpWithClosingIndex");function PA(e,t,r,n){const i=e.indexOf(t,r);if(i===-1){throw new Error(n)}else{return i+t.length-1}}a(PA,"findClosingIndex");function XSe(e,t,r,n=">"){const i=npn(e,t+1,n);if(!i)return;let s=i.data;const o=i.index;const u=s.search(/\s/);let l=s;let c=true;if(u!==-1){l=s.substr(0,u).replace(/\s\s*$/,"");s=s.substr(u+1)}const d=l;if(r){const p=l.indexOf(":");if(p!==-1){l=l.substr(p+1);c=l!==i.data.substr(p+1)}}return{tagName:l,tagExp:s,closeIndex:o,attrExpPresent:c,rawTagName:d}}a(XSe,"readTagExp");function ipn(e,t,r){const n=r;let i=1;for(;r<e.length;r++){if(e[r]==="<"){if(e[r+1]==="/"){const s=PA(e,">",r,`${t} is not closed`);let o=e.substring(r+2,s).trim();if(o===t){i--;if(i===0){return{tagContent:e.substring(n,r),i:s}}}r=s}else if(e[r+1]==="?"){const s=PA(e,"?>",r+1,"StopNode is not closed.");r=s}else if(e.substr(r+1,3)==="!--"){const s=PA(e,"-->",r+3,"StopNode is not closed.");r=s}else if(e.substr(r+1,2)==="!["){const s=PA(e,"]]>",r,"StopNode is not closed.")-2;r=s}else{const s=XSe(e,r,">");if(s){const o=s&&s.tagName;if(o===t&&s.tagExp[s.tagExp.length-1]!=="/"){i++}r=s.closeIndex}}}}}a(ipn,"readStopNodeData");function JSe(e,t,r){if(t&&typeof e==="string"){const n=e.trim();if(n==="true")return true;else if(n==="false")return false;else return zdn(e,r)}else{if(QSe.isExist(e)){return e}else{return""}}}a(JSe,"parseValue");D_t.exports=YSe});var M_t=y(B_t=>{"use strict";function spn(e,t){return F_t(e,t)}a(spn,"prettify");function F_t(e,t,r){let n;const i={};for(let s=0;s<e.length;s++){const o=e[s];const u=apn(o);let l="";if(r===void 0)l=u;else l=r+"."+u;if(u===t.textNodeName){if(n===void 0)n=o[u];else n+=""+o[u]}else if(u===void 0){continue}else if(o[u]){let c=F_t(o[u],t,l);const d=upn(c,t);if(o[":@"]){opn(c,o[":@"],l,t)}else if(Object.keys(c).length===1&&c[t.textNodeName]!==void 0&&!t.alwaysCreateTextNode){c=c[t.textNodeName]}else if(Object.keys(c).length===0){if(t.alwaysCreateTextNode)c[t.textNodeName]="";else c=""}if(i[u]!==void 0&&i.hasOwnProperty(u)){if(!Array.isArray(i[u])){i[u]=[i[u]]}i[u].push(c)}else{if(t.isArray(u,l,d)){i[u]=[c]}else{i[u]=c}}}}if(typeof n==="string"){if(n.length>0)i[t.textNodeName]=n}else if(n!==void 0)i[t.textNodeName]=n;return i}a(F_t,"compress");function apn(e){const t=Object.keys(e);for(let r=0;r<t.length;r++){const n=t[r];if(n!==":@")return n}}a(apn,"propName");function opn(e,t,r,n){if(t){const i=Object.keys(t);const s=i.length;for(let o=0;o<s;o++){const u=i[o];if(n.isArray(u,r+"."+u,true,true)){e[u]=[t[u]]}else{e[u]=t[u]}}}}a(opn,"assignAttributes");function upn(e,t){const{textNodeName:r}=t;const n=Object.keys(e).length;if(n===0){return true}if(n===1&&(e[r]||typeof e[r]==="boolean"||e[r]===0)){return true}return false}a(upn,"isLeafTag");B_t.prettify=spn});var U_t=y((mNs,q_t)=>{var{buildOptions:lpn}=R_t();var cpn=L_t();var{prettify:dpn}=M_t();var ppn=VSe();var ZSe=class{static{a(this,"XMLParser")}constructor(t){this.externalEntities={};this.options=lpn(t)}parse(t,r){if(typeof t==="string"){}else if(t.toString){t=t.toString()}else{throw new Error("XML data is accepted in String or Bytes[] form.")}if(r){if(r===true)r={};const s=ppn.validate(t,r);if(s!==true){throw Error(`${s.err.msg}:${s.err.line}:${s.err.col}`)}}const n=new cpn(this.options);n.addExternalEntities(this.externalEntities);const i=n.parseXml(t);if(this.options.preserveOrder||i===void 0)return i;else return dpn(i,this.options)}addEntity(t,r){if(r.indexOf("&")!==-1){throw new Error("Entity value can't have '&'")}else if(t.indexOf("&")!==-1||t.indexOf(";")!==-1){throw new Error("An entity must be set without '&' and ';'. Eg. use '#xD' for '
'")}else if(r==="&"){throw new Error("An entity with value '&' is not permitted")}else{this.externalEntities[t]=r}}};q_t.exports=ZSe});var V_t=y((gNs,H_t)=>{var fpn="\n";function mpn(e,t){let r="";if(t.format&&t.indentBy.length>0){r=fpn}return j_t(e,t,"",r)}a(mpn,"toXml");function j_t(e,t,r,n){let i="";let s=false;for(let o=0;o<e.length;o++){const u=e[o];const l=hpn(u);if(l===void 0)continue;let c="";if(r.length===0)c=l;else c=`${r}.${l}`;if(l===t.textNodeName){let h=u[l];if(!gpn(c,t)){h=t.tagValueProcessor(l,h);h=G_t(h,t)}if(s){i+=n}i+=h;s=false;continue}else if(l===t.cdataPropName){if(s){i+=n}i+=`<![CDATA[${u[l][0][t.textNodeName]}]]>`;s=false;continue}else if(l===t.commentPropName){i+=n+`<!--${u[l][0][t.textNodeName]}-->`;s=true;continue}else if(l[0]==="?"){const h=$_t(u[":@"],t);const g=l==="?xml"?"":n;let _=u[l][0][t.textNodeName];_=_.length!==0?" "+_:"";i+=g+`<${l}${_}${h}?>`;s=true;continue}let d=n;if(d!==""){d+=t.indentBy}const p=$_t(u[":@"],t);const f=n+`<${l}${p}`;const m=j_t(u[l],t,c,d);if(t.unpairedTags.indexOf(l)!==-1){if(t.suppressUnpairedNode)i+=f+">";else i+=f+"/>"}else if((!m||m.length===0)&&t.suppressEmptyNode){i+=f+"/>"}else if(m&&m.endsWith(">")){i+=f+`>${m}${n}</${l}>`}else{i+=f+">";if(m&&n!==""&&(m.includes("/>")||m.includes("</"))){i+=n+t.indentBy+m+n}else{i+=m}i+=`</${l}>`}s=true}return i}a(j_t,"arrToStr");function hpn(e){const t=Object.keys(e);for(let r=0;r<t.length;r++){const n=t[r];if(!e.hasOwnProperty(n))continue;if(n!==":@")return n}}a(hpn,"propName");function $_t(e,t){let r="";if(e&&!t.ignoreAttributes){for(let n in e){if(!e.hasOwnProperty(n))continue;let i=t.attributeValueProcessor(n,e[n]);i=G_t(i,t);if(i===true&&t.suppressBooleanAttributes){r+=` ${n.substr(t.attributeNamePrefix.length)}`}else{r+=` ${n.substr(t.attributeNamePrefix.length)}="${i}"`}}}return r}a($_t,"attr_to_str");function gpn(e,t){e=e.substr(0,e.length-t.textNodeName.length-1);let r=e.substr(e.lastIndexOf(".")+1);for(let n in t.stopNodes){if(t.stopNodes[n]===e||t.stopNodes[n]==="*."+r)return true}return false}a(gpn,"isStopNode");function G_t(e,t){if(e&&e.length>0&&t.processEntities){for(let r=0;r<t.entities.length;r++){const n=t.entities[r];e=e.replace(n.regex,n.val)}}return e}a(G_t,"replaceEntitiesValue");H_t.exports=mpn});var K_t=y((_Ns,z_t)=>{"use strict";var ypn=V_t();var _pn={attributeNamePrefix:"@_",attributesGroupName:false,textNodeName:"#text",ignoreAttributes:true,cdataPropName:false,format:false,indentBy:" ",suppressEmptyNode:false,suppressUnpairedNode:true,suppressBooleanAttributes:true,tagValueProcessor:function(e,t){return t},attributeValueProcessor:function(e,t){return t},preserveOrder:false,commentPropName:false,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&"},{regex:new RegExp(">","g"),val:">"},{regex:new RegExp("<","g"),val:"<"},{regex:new RegExp("'","g"),val:"'"},{regex:new RegExp('"',"g"),val:"""}],processEntities:true,stopNodes:[],oneListGroup:false};function dE(e){this.options=Object.assign({},_pn,e);if(this.options.ignoreAttributes||this.options.attributesGroupName){this.isAttribute=function(){return false}}else{this.attrPrefixLen=this.options.attributeNamePrefix.length;this.isAttribute=bpn}this.processTextOrObjNode=vpn;if(this.options.format){this.indentate=Epn;this.tagEndChar=">\n";this.newLine="\n"}else{this.indentate=function(){return""};this.tagEndChar=">";this.newLine=""}}a(dE,"Builder");dE.prototype.build=function(e){if(this.options.preserveOrder){return ypn(e,this.options)}else{if(Array.isArray(e)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1){e={[this.options.arrayNodeName]:e}}return this.j2x(e,0).val}};dE.prototype.j2x=function(e,t){let r="";let n="";for(let i in e){if(!Object.prototype.hasOwnProperty.call(e,i))continue;if(typeof e[i]==="undefined"){if(this.isAttribute(i)){n+=""}}else if(e[i]===null){if(this.isAttribute(i)){n+=""}else if(i[0]==="?"){n+=this.indentate(t)+"<"+i+"?"+this.tagEndChar}else{n+=this.indentate(t)+"<"+i+"/"+this.tagEndChar}}else if(e[i]instanceof Date){n+=this.buildTextValNode(e[i],i,"",t)}else if(typeof e[i]!=="object"){const s=this.isAttribute(i);if(s){r+=this.buildAttrPairStr(s,""+e[i])}else{if(i===this.options.textNodeName){let o=this.options.tagValueProcessor(i,""+e[i]);n+=this.replaceEntitiesValue(o)}else{n+=this.buildTextValNode(e[i],i,"",t)}}}else if(Array.isArray(e[i])){const s=e[i].length;let o="";for(let u=0;u<s;u++){const l=e[i][u];if(typeof l==="undefined"){}else if(l===null){if(i[0]==="?")n+=this.indentate(t)+"<"+i+"?"+this.tagEndChar;else n+=this.indentate(t)+"<"+i+"/"+this.tagEndChar}else if(typeof l==="object"){if(this.options.oneListGroup){o+=this.j2x(l,t+1).val}else{o+=this.processTextOrObjNode(l,i,t)}}else{o+=this.buildTextValNode(l,i,"",t)}}if(this.options.oneListGroup){o=this.buildObjectNode(o,i,"",t)}n+=o}else{if(this.options.attributesGroupName&&i===this.options.attributesGroupName){const s=Object.keys(e[i]);const o=s.length;for(let u=0;u<o;u++){r+=this.buildAttrPairStr(s[u],""+e[i][s[u]])}}else{n+=this.processTextOrObjNode(e[i],i,t)}}}return{attrStr:r,val:n}};dE.prototype.buildAttrPairStr=function(e,t){t=this.options.attributeValueProcessor(e,""+t);t=this.replaceEntitiesValue(t);if(this.options.suppressBooleanAttributes&&t==="true"){return" "+e}else return" "+e+'="'+t+'"'};function vpn(e,t,r){const n=this.j2x(e,r+1);if(e[this.options.textNodeName]!==void 0&&Object.keys(e).length===1){return this.buildTextValNode(e[this.options.textNodeName],t,n.attrStr,r)}else{return this.buildObjectNode(n.val,t,n.attrStr,r)}}a(vpn,"processTextOrObjNode");dE.prototype.buildObjectNode=function(e,t,r,n){if(e===""){if(t[0]==="?")return this.indentate(n)+"<"+t+r+"?"+this.tagEndChar;else{return this.indentate(n)+"<"+t+r+this.closeTag(t)+this.tagEndChar}}else{let i="</"+t+this.tagEndChar;let s="";if(t[0]==="?"){s="?";i=""}if((r||r==="")&&e.indexOf("<")===-1){return this.indentate(n)+"<"+t+r+s+">"+e+i}else if(this.options.commentPropName!==false&&t===this.options.commentPropName&&s.length===0){return this.indentate(n)+`<!--${e}-->`+this.newLine}else{return this.indentate(n)+"<"+t+r+s+this.tagEndChar+e+this.indentate(n)+i}}};dE.prototype.closeTag=function(e){let t="";if(this.options.unpairedTags.indexOf(e)!==-1){if(!this.options.suppressUnpairedNode)t="/"}else if(this.options.suppressEmptyNode){t="/"}else{t=`></${e}`}return t};dE.prototype.buildTextValNode=function(e,t,r,n){if(this.options.cdataPropName!==false&&t===this.options.cdataPropName){return this.indentate(n)+`<![CDATA[${e}]]>`+this.newLine}else if(this.options.commentPropName!==false&&t===this.options.commentPropName){return this.indentate(n)+`<!--${e}-->`+this.newLine}else if(t[0]==="?"){return this.indentate(n)+"<"+t+r+"?"+this.tagEndChar}else{let i=this.options.tagValueProcessor(t,e);i=this.replaceEntitiesValue(i);if(i===""){return this.indentate(n)+"<"+t+r+this.closeTag(t)+this.tagEndChar}else{return this.indentate(n)+"<"+t+r+">"+i+"</"+t+this.tagEndChar}}};dE.prototype.replaceEntitiesValue=function(e){if(e&&e.length>0&&this.options.processEntities){for(let t=0;t<this.options.entities.length;t++){const r=this.options.entities[t];e=e.replace(r.regex,r.val)}}return e};function Epn(e){return this.options.indentBy.repeat(e)}a(Epn,"indentate");function bpn(e){if(e.startsWith(this.options.attributeNamePrefix)&&e!==this.options.textNodeName){return e.substr(this.attrPrefixLen)}else{return false}}a(bpn,"isAttribute");z_t.exports=dE});var Y_t=y((ENs,W_t)=>{"use strict";var Spn=VSe();var Apn=U_t();var Cpn=K_t();W_t.exports={XMLParser:Apn,XMLValidator:Spn,XMLBuilder:Cpn}});var evt=y(Pl=>{"use strict";var wpn=Pl&&Pl.__createBinding||(Object.create?function(e,t,r,n){if(n===void 0)n=r;var i=Object.getOwnPropertyDescriptor(t,r);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[r]}}}Object.defineProperty(e,n,i)}:function(e,t,r,n){if(n===void 0)n=r;e[n]=t[r]});var Tpn=Pl&&Pl.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var xpn=Pl&&Pl.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null){for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))wpn(t,e,r)}Tpn(t,e);return t};var NA=Pl&&Pl.__classPrivateFieldGet||function(e,t,r,n){if(r==="a"&&!n)throw new TypeError("Private accessor was defined without a getter");if(typeof t==="function"?e!==t||!n:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return r==="m"?n:r==="a"?n.call(e):n?n.value:t.get(e)};var Z_t=Pl&&Pl.__importDefault||function(e){return e&&e.__esModule?e:{"default":e}};var my;var dY;var CL;Object.defineProperty(Pl,"__esModule",{value:true});Pl.TransferManager=Pl.MultiPartUploadError=void 0;var AL=Z_t(_Se());var pE=xpn(require("path"));var lY=require("fs");var Rpn=hL();var Opn=iW();var X_t=Y_t();var cY=Z_t(sL());var Ppn=require("crypto");var eAe=TA();var J_t=P0();var Npn=KR();var Ipn=(0,Npn.getPackageJSON)();var kpn=5;var Dpn=5;var Lpn=5;var Fpn=32*1024*1024;var Bpn=32*1024*1024;var Mpn=32*1024*1024;var Q_t=5;var qpn="(?:)";var lO={UPLOAD_MANY:"tm.upload_many",DOWNLOAD_MANY:"tm.download_many",UPLOAD_SHARDED:"tm.upload_sharded",DOWNLOAD_SHARDED:"tm.download_sharded"};var Upn=a((e,t,r,n)=>{return new tAe(e,t,r,n)},"defaultMultiPartGenerator");var wL=class extends Error{static{a(this,"MultiPartUploadError")}constructor(t,r,n){super(t);this.uploadId=r;this.partsMap=n}};Pl.MultiPartUploadError=wL;var tAe=class{static{a(this,"XMLMultiPartUploadHelper")}constructor(t,r,n,i){my.add(this);this.authClient=t.storage.authClient||new Opn.GoogleAuth;this.uploadId=n||"";this.bucket=t;this.fileName=r;this.baseUrl=`https://${t.name}.${new URL(this.bucket.storage.apiEndpoint).hostname}/${r}`;this.xmlBuilder=new X_t.XMLBuilder({arrayNodeName:"Part"});this.xmlParser=new X_t.XMLParser;this.partsMap=i||new Map;this.retryOptions={retries:this.bucket.storage.retryOptions.maxRetries,factor:this.bucket.storage.retryOptions.retryDelayMultiplier,maxTimeout:this.bucket.storage.retryOptions.maxRetryDelay*1e3,maxRetryTime:this.bucket.storage.retryOptions.totalTimeout*1e3}}async initiateUpload(t={}){const r=`${this.baseUrl}?uploads`;return(0,cY.default)(async n=>{try{const i=await this.authClient.request({headers:NA(this,my,"m",dY).call(this,t),method:"POST",url:r});if(i.data&&i.data.error){throw i.data.error}const s=this.xmlParser.parse(i.data);this.uploadId=s.InitiateMultipartUploadResult.UploadId}catch(i){NA(this,my,"m",CL).call(this,i,n)}},this.retryOptions)}async uploadPart(t,r,n){const i=`${this.baseUrl}?partNumber=${t}&uploadId=${this.uploadId}`;let s=NA(this,my,"m",dY).call(this);if(n==="md5"){const o=(0,Ppn.createHash)("md5").update(r).digest("base64");s={"Content-MD5":o}}return(0,cY.default)(async o=>{try{const u=await this.authClient.request({url:i,method:"PUT",body:r,headers:s});if(u.data&&u.data.error){throw u.data.error}this.partsMap.set(t,u.headers["etag"])}catch(u){NA(this,my,"m",CL).call(this,u,o)}},this.retryOptions)}async completeUpload(){const t=`${this.baseUrl}?uploadId=${this.uploadId}`;const r=new Map([...this.partsMap.entries()].sort((s,o)=>s[0]-o[0]));const n=[];for(const s of r.entries()){n.push({PartNumber:s[0],ETag:s[1]})}const i=`<CompleteMultipartUpload>${this.xmlBuilder.build(n)}</CompleteMultipartUpload>`;return(0,cY.default)(async s=>{try{const o=await this.authClient.request({headers:NA(this,my,"m",dY).call(this),url:t,method:"POST",body:i});if(o.data&&o.data.error){throw o.data.error}return o}catch(o){NA(this,my,"m",CL).call(this,o,s);return}},this.retryOptions)}async abortUpload(){const t=`${this.baseUrl}?uploadId=${this.uploadId}`;return(0,cY.default)(async r=>{try{const n=await this.authClient.request({url:t,method:"DELETE"});if(n.data&&n.data.error){throw n.data.error}}catch(n){NA(this,my,"m",CL).call(this,n,r);return}},this.retryOptions)}};my=new WeakSet,dY=a(function e(t={}){let r=false;let n=false;for(const[i,s]of Object.entries(t)){if(i.toLocaleLowerCase().trim()==="x-goog-api-client"){r=true;if(!s.includes(lO.UPLOAD_SHARDED)){t[i]=`${s} gccl-gcs-cmd/${lO.UPLOAD_SHARDED}`}}else if(i.toLocaleLowerCase().trim()==="user-agent"){n=true}}if(!r){t["x-goog-api-client"]=`${(0,J_t.getRuntimeTrackingString)()} gccl/${Ipn.version} gccl-gcs-cmd/${lO.UPLOAD_SHARDED}`}if(!n){t["User-Agent"]=(0,J_t.getUserAgentString)()}return t},"_XMLMultiPartUploadHelper_setGoogApiClientHeaders"),CL=a(function e(t,r){if(this.bucket.storage.retryOptions.autoRetry&&this.bucket.storage.retryOptions.retryableErrorFn(t)){throw t}else{r(t)}},"_XMLMultiPartUploadHelper_handleErrorResponse");var rAe=class{static{a(this,"TransferManager")}constructor(t){this.bucket=t}async uploadManyFiles(t,r={}){var n;if(r.skipIfExists&&((n=r.passthroughOptions)===null||n===void 0?void 0:n.preconditionOpts)){r.passthroughOptions.preconditionOpts.ifGenerationMatch=0}else if(r.skipIfExists&&r.passthroughOptions===void 0){r.passthroughOptions={preconditionOpts:{ifGenerationMatch:0}}}const i=(0,AL.default)(r.concurrencyLimit||kpn);const s=[];let o=[];if(!Array.isArray(t)){for await(const u of this.getPathsFromDirectory(t)){o.push(u)}}else{o=t}for(const u of o){const l=await lY.promises.lstat(u);if(l.isDirectory()){continue}const c={...r.passthroughOptions,[eAe.GCCL_GCS_CMD_KEY]:lO.UPLOAD_MANY};c.destination=u.split(pE.sep).join(pE.posix.sep);if(r.prefix){c.destination=pE.posix.join(...r.prefix.split(pE.sep),c.destination)}s.push(i(()=>this.bucket.upload(u,c)))}return Promise.all(s)}async downloadManyFiles(t,r={}){const n=(0,AL.default)(r.concurrencyLimit||Dpn);const i=[];let s=[];if(!Array.isArray(t)){const l=await this.bucket.getFiles({prefix:t});s=l[0]}else{s=t.map(l=>{if(typeof l==="string"){return this.bucket.file(l)}return l})}const o=r.stripPrefix?`^${r.stripPrefix}`:qpn;const u=new RegExp(o,"g");for(const l of s){const c={...r.passthroughOptions,[eAe.GCCL_GCS_CMD_KEY]:lO.DOWNLOAD_MANY};if(r.prefix){c.destination=pE.join(r.prefix||"",c.destination||"",l.name)}if(r.stripPrefix){c.destination=l.name.replace(u,"")}i.push(n(()=>l.download(c)))}return Promise.all(i)}async downloadFileInChunks(t,r={}){let n=r.chunkSizeBytes||Bpn;let i=(0,AL.default)(r.concurrencyLimit||Lpn);const s=[];const o=typeof t==="string"?this.bucket.file(t):t;const u=await o.get();const l=parseInt(u[0].metadata.size.toString());if(l<Fpn){i=(0,AL.default)(1);n=l}let c=0;const d=r.destination||pE.basename(o.name);const p=await lY.promises.open(d,"w");while(c<l){const m=c;let h=c+n-1;h=h>l?l:h;s.push(i(async()=>{const g=await o.download({start:m,end:h,[eAe.GCCL_GCS_CMD_KEY]:lO.DOWNLOAD_SHARDED});return p.write(g[0],0,g[0].length,m)}));c+=n}let f;try{const m=await Promise.all(s);f=m.map(h=>h.buffer);if(r.validation==="crc32c"){await Rpn.CRC32C.fromFile(d)}return f}finally{p.close()}}async uploadFileInChunks(t,r={},n=Upn){const i=r.chunkSizeBytes||Mpn;const s=(0,AL.default)(r.concurrencyLimit||Q_t);const o=r.maxQueueSize||r.concurrencyLimit||Q_t;const u=r.uploadName||pE.basename(t);const l=n(this.bucket,u,r.uploadId,r.partsMap);let c=1;let d=[];try{if(r.uploadId===void 0){await l.initiateUpload(r.headers)}const p=l.partsMap.size*i;const f=(0,lY.createReadStream)(t,{highWaterMark:i,start:p});for await(const m of f){if(d.length>=o){await Promise.all(d);d=[]}d.push(s(()=>l.uploadPart(c++,m,r.validation)))}await Promise.all(d);return await l.completeUpload()}catch(p){if((r.autoAbortFailure===void 0||r.autoAbortFailure)&&l.uploadId){try{await l.abortUpload();return}catch(f){throw new wL(f.message,l.uploadId,l.partsMap)}}throw new wL(p.message,l.uploadId,l.partsMap)}}async*getPathsFromDirectory(t){const r=await lY.promises.readdir(t,{withFileTypes:true});for(const n of r){const i=pE.join(t,n.name);n.isDirectory()?yield*this.getPathsFromDirectory(i):yield i}}};Pl.TransferManager=rAe});var rvt=y(Gs=>{"use strict";var $pn=Gs&&Gs.__createBinding||(Object.create?function(e,t,r,n){if(n===void 0)n=r;var i=Object.getOwnPropertyDescriptor(t,r);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[r]}}}Object.defineProperty(e,n,i)}:function(e,t,r,n){if(n===void 0)n=r;e[n]=t[r]});var nAe=Gs&&Gs.__exportStar||function(e,t){for(var r in e)if(r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r))$pn(t,e,r)};Object.defineProperty(Gs,"__esModule",{value:true});Gs.Notification=Gs.Iam=Gs.HmacKey=Gs.File=Gs.Channel=Gs.Bucket=Gs.Storage=Gs.IdempotencyStrategy=Gs.ApiError=void 0;var jpn=rE();Object.defineProperty(Gs,"ApiError",{enumerable:true,get:function(){return jpn.ApiError}});var tvt=nO();Object.defineProperty(Gs,"IdempotencyStrategy",{enumerable:true,get:function(){return tvt.IdempotencyStrategy}});Object.defineProperty(Gs,"Storage",{enumerable:true,get:function(){return tvt.Storage}});var Gpn=JW();Object.defineProperty(Gs,"Bucket",{enumerable:true,get:function(){return Gpn.Bucket}});nAe(hL(),Gs);var Hpn=USe();Object.defineProperty(Gs,"Channel",{enumerable:true,get:function(){return Hpn.Channel}});var Vpn=gL();Object.defineProperty(Gs,"File",{enumerable:true,get:function(){return Vpn.File}});nAe(PSe(),Gs);var zpn=$Se();Object.defineProperty(Gs,"HmacKey",{enumerable:true,get:function(){return zpn.HmacKey}});var Kpn=LSe();Object.defineProperty(Gs,"Iam",{enumerable:true,get:function(){return Kpn.Iam}});var Wpn=FSe();Object.defineProperty(Gs,"Notification",{enumerable:true,get:function(){return Wpn.Notification}});nAe(evt(),Gs)});var sAe=y(_i=>{"use strict";var iAe=_i&&_i.__importDefault||function(e){return e&&e.__esModule?e:{"default":e}};Object.defineProperty(_i,"__esModule",{value:true});_i.deleteFolder=_i.untar=_i.tarFolderContent=_i.getParentDirFilename=_i.safePath=_i.UnsafePathError=_i.ensureDirectoryExists=_i.mkdirForFilePathIfNotExits=_i.mkdirIfNotExists=_i.listFolderContents=_i.listFolders=_i.isNotFileOrDirectory=_i.dirExists=_i.deleteFile=_i.fileExists=void 0;var nvt=iAe(require("child_process"));var mE=iAe(require("fs/promises"));var fE=iAe(require("path"));var ivt=[".git","node_modules",".yarn",".DS_Store"];async function Ypn(e){try{const t=await mE.default.stat(e);return t.isFile()}catch(t){return false}}a(Ypn,"fileExists");_i.fileExists=Ypn;async function Xpn(e,t){return await mE.default.rm(e,t)}a(Xpn,"deleteFile");_i.deleteFile=Xpn;async function fY(e){try{const t=await mE.default.stat(e);return t.isDirectory()}catch(t){return false}}a(fY,"dirExists");_i.dirExists=fY;async function Jpn(e){try{await mE.default.stat(e);return false}catch(t){return true}}a(Jpn,"isNotFileOrDirectory");_i.isNotFileOrDirectory=Jpn;function Qpn(e,t){const r=new RegExp(`(.*)(\\/${t})$|(.*)(${t}\\/)`);const n=e.match(r);if(!n){return""}const i=e.split(n[0]);return i[1]===""?"":`/${i[1]}`}a(Qpn,"getParentDirectory");async function Zpn(e){if(!await fY(e)){return[]}const t=await mE.default.readdir(e,{withFileTypes:true});const r=[];for await(const n of t){if(!ivt.includes(n.name)){if(n.isDirectory()){r.push(n.name)}}}return r}a(Zpn,"listFolders");_i.listFolders=Zpn;async function svt(e,t,r=true){const n=Qpn(e,t);const i=await mE.default.readdir(e,{withFileTypes:true});const s=[];for await(const o of i){if(!ivt.includes(o.name)||!r){if(o.isDirectory()){const u=await svt(fE.default.join(e,o.name),t,r);s.push(...u)}else{s.push(fE.default.join(n,o.name))}}}return s}a(svt,"listFolderContents");_i.listFolderContents=svt;var efn=a(async e=>{if(await fY(e)){return true}await mE.default.mkdir(e,{recursive:true})},"mkdirIfNotExists");_i.mkdirIfNotExists=efn;var tfn=a(async e=>{const t=fE.default.dirname(e);return(0,_i.mkdirIfNotExists)(t)},"mkdirForFilePathIfNotExits");_i.mkdirForFilePathIfNotExits=tfn;_i.ensureDirectoryExists=_i.mkdirForFilePathIfNotExits;var pY=class extends Error{static{a(this,"UnsafePathError")}constructor(t){super(t)}};_i.UnsafePathError=pY;function rfn(e){const t=a(r=>{if(!r.startsWith(e)){throw new pY(`Resolved path is not part of the project.`)}return r},"ensureSafePath");return{resolve:(...r)=>t(fE.default.resolve(...r))}}a(rfn,"safePath");_i.safePath=rfn;function nfn(e){return`${fE.default.basename(fE.default.dirname(e))}/${fE.default.basename(e)}`}a(nfn,"getParentDirFilename");_i.getParentDirFilename=nfn;function ifn(e,t,r,n){const i=fE.default.join(n,r);nvt.default.execSync(`tar --exclude='.git/' --exclude='dist/' -czf ${i} ${t}`,{cwd:e});return i}a(ifn,"tarFolderContent");_i.tarFolderContent=ifn;function sfn(e,t,r,n=false){nvt.default.execSync(`tar -xf ${t} ${n?"--strip-components=1 ":""}-C ${r}`,{cwd:e})}a(sfn,"untar");_i.untar=sfn;async function afn(e){if(await fY(e)){return await mE.default.rm(e,{recursive:true})}}a(afn,"deleteFolder");_i.deleteFolder=afn});var cvt=y(ti=>{"use strict";var ofn=ti&&ti.__createBinding||(Object.create?function(e,t,r,n){if(n===void 0)n=r;var i=Object.getOwnPropertyDescriptor(t,r);if(!i||("get"in i?!t.__esModule:i.writable||i.configurable)){i={enumerable:true,get:function(){return t[r]}}}Object.defineProperty(e,n,i)}:function(e,t,r,n){if(n===void 0)n=r;e[n]=t[r]});var ufn=ti&&ti.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t})}:function(e,t){e["default"]=t});var lfn=ti&&ti.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null){for(var r in e)if(r!=="default"&&Object.prototype.hasOwnProperty.call(e,r))ofn(t,e,r)}ufn(t,e);return t};var avt=ti&&ti.__importDefault||function(e){return e&&e.__esModule?e:{"default":e}};Object.defineProperty(ti,"__esModule",{value:true});ti.uploadFolderAndRemoveMissingSourceFiles=ti.cleanGCPFilePaths=ti.uploadFolder=ti.deleteDirectory=ti.deleteFile=ti.listFolderContent=ti.readFileStream=ti.fileExists=ti.getFileContents=ti.downloadFile=ti.uploadFromMemory=ti.uploadFile=ti.getBucket=ti.BucketName=void 0;var cfn=rvt();var hy=avt(require("path"));var B0=avt(qp());var mY=lfn(sAe());var IA;(function(e){e[e["Archive"]=0]="Archive";e[e["Bundle"]=1]="Bundle";e[e["SourceCode"]=2]="SourceCode";e[e["Sources"]=3]="Sources";e[e["DevPortalBuild"]=4]="DevPortalBuild"})(IA||(ti.BucketName=IA={}));function M0(e){let t;if(e===IA.Archive){if(B0.default.GCP_STORAGE_ARCHIVE_BUCKET_NAME===void 0){throw new Error(`Environment variable GCP_STORAGE_ARCHIVE_BUCKET_NAME must be set`)}t=B0.default.GCP_STORAGE_ARCHIVE_BUCKET_NAME}else if(e===IA.Bundle){if(B0.default.GCP_STORAGE_BUNDLE_BUCKET_NAME===void 0){throw new Error(`Environment variable GCP_STORAGE_BUNDLE_BUCKET_NAME must be set`)}t=B0.default.GCP_STORAGE_BUNDLE_BUCKET_NAME}else if(e===IA.SourceCode){if(B0.default.GCP_STORAGE_SOURCE_CODE_BUCKET_NAME===void 0){throw new Error(`Environment variable GCP_STORAGE_SOURCE_CODE_BUCKET_NAME must be set`)}t=B0.default.GCP_STORAGE_SOURCE_CODE_BUCKET_NAME}else if(e===IA.Sources){if(B0.default.GCP_STORAGE_SOURCES_BUCKET_NAME===void 0){throw new Error(`Environment variable GCP_STORAGE_SOURCES_BUCKET_NAME must be set`)}t=B0.default.GCP_STORAGE_SOURCES_BUCKET_NAME}else if(e===IA.DevPortalBuild){if(B0.default.GCP_STORAGE_DEV_PORTAL_BUILD_BUCKET_NAME===void 0){throw new Error(`Environment variable GCP_STORAGE_DEV_PORTAL_BUILD_BUCKET_NAME must be set`)}t=B0.default.GCP_STORAGE_DEV_PORTAL_BUILD_BUCKET_NAME}else{throw new Error("Invalid value for argument 'bucketName'")}const r=new cfn.Storage;return r.bucket(t)}a(M0,"getBucket");ti.getBucket=M0;async function aAe(e,t,r,n,i){try{await M0(e).upload(t,{destination:r,metadata:i})}catch(s){n.info(`File upload for ${e}/${r} ran into an issue`);n.error(s)}}a(aAe,"uploadFile");ti.uploadFile=aAe;async function dfn(e,t,r,n,i){try{await M0(e).file(r).save(t,i)}catch(s){n.info(`From Memory upload for ${e}/${r} ran into an issue`);n.error(s)}}a(dfn,"uploadFromMemory");ti.uploadFromMemory=dfn;async function pfn(e,t,r,n){try{const i={destination:r};await M0(e).file(t).download(i);n.info(`File ${e}/${t} successfully downloaded to ${r}`)}catch(i){n.info(`Downloading file ${e}/${t} ran into an issue`);n.error(i)}}a(pfn,"downloadFile");ti.downloadFile=pfn;async function ffn(e,t,r){try{const n=await M0(e).file(t).download();r.info(`File ${e}/${t} successfully downloaded to memory`);return n.toString()}catch(n){r.info(`Downloading file ${e}/${t} ran into an issue`);r.error(n)}}a(ffn,"getFileContents");ti.getFileContents=ffn;async function mfn(e,t,r){try{r.info(`Check if file ${e}/${t} exists in storage`);const n=await M0(e).file(t).exists();return n[0]}catch(n){r.info(`Ran into an issue while checking if a file ${e}/${t} exists in storage`);r.error(n);return false}}a(mfn,"fileExists");ti.fileExists=mfn;function hfn(e,t,r){r.info(`Reading file ${e}/${t} from storage`);return M0(e).file(t).createReadStream({decompress:true})}a(hfn,"readFileStream");ti.readFileStream=hfn;async function ovt(e,t,r){const n=new Set;try{const[i]=await M0(e).getFiles({prefix:t});for(let s=0;s<i.length;s++){const o=i[s];const u=o.name.replace(t,"");if(u===""){continue}const l=u.split("/");if(l.length>1){for(let c=0;c<l.length-1;c++){const d=`/${l[c]}`;if(!n.has(d)){n.add(d)}}}n.add(`/${u}`)}}catch(i){r.info(`Ran into an issue while listing files in ${e}/${t} storage path`);r.error(i)}return[...n]}a(ovt,"listFolderContent");ti.listFolderContent=ovt;async function uvt(e,t,r){try{r.info(`Deleting file ${e}/${t} from storage`);await M0(e).file(t).delete()}catch(n){r.warn(`Failed to delete file ${e}/${t} from storage`);r.error(n)}}a(uvt,"deleteFile");ti.deleteFile=uvt;async function gfn(e,t,r){try{r.info(`Deleting directory ${e}/${t} from storage`);await M0(e).deleteFiles({prefix:t})}catch(n){r.info(`Failed to delete directory ${e}/${t} from storage`);r.error(n)}}a(gfn,"deleteDirectory");ti.deleteDirectory=gfn;async function yfn(e,t,r,n,i){try{n.info(`Upload folder ${hy.default.basename(t)}`);if(await mY.dirExists(t)){const s=await mY.listFolderContents(t,hy.default.basename(t));if(s&&s.length>0){await Promise.all(s.map(async o=>{return await aAe(e,hy.default.join(t,o),hy.default.join(r,o),n,i)}))}}}catch(s){n.warn(`Failed to upload directory ${t} to bucket ${e}`,s)}}a(yfn,"uploadFolder");ti.uploadFolder=yfn;function lvt(e){const t=e.filter(r=>r!=="/").map(r=>r.replace(/^\/+/,""));return t}a(lvt,"cleanGCPFilePaths");ti.cleanGCPFilePaths=lvt;async function _fn(e,t,r,n,i){try{n.info(`uploadFolderAndRemoveMissingSourceFiles: upload folder ${hy.default.basename(t)}`);if(await mY.dirExists(t)){const s=await ovt(e,r,n);const o=lvt(s);const u=await mY.listFolderContents(t,hy.default.basename(t));const l=o.filter(c=>!u.includes(c)).map(c=>hy.default.join(r,c));await Promise.all(l.map(async c=>{return await uvt(e,c,n)}));await Promise.all(u.map(async c=>{return await aAe(e,hy.default.join(t,c),hy.default.join(r,c),n,i)}))}}catch(s){n.warn(`Failed to upload directory ${t} to bucket ${e}`,s)}}a(_fn,"uploadFolderAndRemoveMissingSourceFiles");ti.uploadFolderAndRemoveMissingSourceFiles=_fn});var dvt=y(hY=>{"use strict";Object.defineProperty(hY,"__esModule",{value:true});hY.graphQL=void 0;var q0=ac();async function vfn(e,t,r){const n=await fetch(`https://api.github.com/graphql`,{method:"POST",headers:{Authorization:`Bearer ${t}`},body:e});if(n.status===401){r.warn("Failed GitHub GraphQL query with status 401. User token might have been revoked directly in GitHub.");throw new q0.ApiError(q0.Problems.SOURCE_CONTROL_GH_APP_REVOKED_ACCESS)}if(n.status===403){r.warn("Failed GitHub GraphQL query with status 403. User token does not have correct permissions to query this GitHub API.");throw new q0.ApiError(q0.Problems.SOURCE_CONTROL_GH_APP_CONFIG_REQUIRED)}if(n.status===404){r.warn("Failed GitHub GraphQL query with status 404. User token has been revoked and can not query this GitHub API.");throw new q0.ApiError(q0.Problems.SOURCE_CONTROL_GH_APP_CONFIG_REQUIRED)}if(n.status===400){const i=await n.json();r.warn("Failed GitHub GraphQL query with status 400. A malformed query was ran against the GitHub API.",i);throw new q0.ApiError(q0.Problems.BAD_REQUEST)}if(n.status!==200&&n.status!==304){r.warn(`Failed GitHub GraphQL query with status ${n.status}. There was an unexpected error querying the GitHub API.`);throw new q0.ApiError(q0.Problems.SOURCE_CONTROL_GH_APP_CONFIG_REQUIRED)}return n}a(vfn,"graphQL");hY.graphQL=vfn});var yvt=y(Ef=>{"use strict";Object.defineProperty(Ef,"__esModule",{value:true});Ef.SourceControlProvider=Ef.PlanType=Ef.EnvironmentType=Ef.EnvironmentTarget=Ef.DeploymentState=void 0;var pvt;(function(e){e[e["IS_STARTING"]=0]="IS_STARTING";e[e["STARTED"]=1]="STARTED";e[e["STOPPED"]=2]="STOPPED";e[e["ERRORED"]=3]="ERRORED"})(pvt||(Ef.DeploymentState=pvt={}));var fvt;(function(e){e["CLOUDFLARE"]="CLOUDFLARE";e["KNATIVE"]="KNATIVE"})(fvt||(Ef.EnvironmentTarget=fvt={}));var mvt;(function(e){e["PRODUCTION"]="PRODUCTION";e["PREVIEW"]="PREVIEW";e["WORKING_COPY"]="WORKING_COPY"})(mvt||(Ef.EnvironmentType=mvt={}));var hvt;(function(e){e["FREE_V1"]="FREE_V1";e["BUILDER_V1"]="BUILDER_V1";e["BUSINESS_V1"]="BUSINESS_V1";e["CUSTOM"]="CUSTOM";e["EMPLOYEE"]="EMPLOYEE";e["CUSTOM_TRIAL_V1"]="CUSTOM_TRIAL_V1"})(hvt||(Ef.PlanType=hvt={}));var gvt;(function(e){e["GITHUB"]="GITHUB";e["GITLAB"]="GITLAB";e["BITBUCKET"]="BITBUCKET"})(gvt||(Ef.SourceControlProvider=gvt={}))});var vvt=y(_vt=>{"use strict";Object.defineProperty(_vt,"__esModule",{value:true})});var Evt=y(bf=>{"use strict";Object.defineProperty(bf,"__esModule",{value:true});bf.INTERNAL_ROUTE_VENDOR_TAG=bf.ZUPLO_OPEN_API_ROUTE_KEY=bf.ZUPLO_OPEN_API_PATH_KEY=bf.ZUPLO_OPEN_API_VENDOR_PREFIX=void 0;bf.ZUPLO_OPEN_API_VENDOR_PREFIX="x-zuplo";bf.ZUPLO_OPEN_API_PATH_KEY=`${bf.ZUPLO_OPEN_API_VENDOR_PREFIX}-path`;bf.ZUPLO_OPEN_API_ROUTE_KEY=`${bf.ZUPLO_OPEN_API_VENDOR_PREFIX}-route`;bf.INTERNAL_ROUTE_VENDOR_TAG="x-internal"});var bvt=y((kNs,Efn)=>{Efn.exports={$schema:"https://json-schema.org/draft/2020-12/schema",$id:"http://schemas.zuplo.com/dev-portal.json",title:"Dev Portal Config",description:"",type:"object",required:[],additionalProperties:false,$defs:{ApiKeysConfig:{type:"object",additionalProperties:false,required:["bucketName"],properties:{bucketName:{type:"string"},apiKey:{type:"string"}}},DevPortalOAuthClientConfig:{type:"object",additionalProperties:false,required:["clientId"],properties:{clientId:{type:"string"},audience:{type:"string",description:"The audience of the API (i.e. the Zup's URL)\nOkta: not required\nAuth0: https://my-api.example.com/"}}},DevPortalOAuthClientCredentialsConfig:{type:"object",description:"This is the M2M configuration used to authenticate with OAuth provider in order to manage OAuth clients",required:["clientId","clientSecret"],additionalProperties:false,properties:{clientId:{type:"string"},clientSecret:{type:"string"}}},DevPortalAPIKeyCredentialConfig:{type:"object",description:"API Key credentials to access identity provider API",required:["apiKey"],additionalProperties:false,properties:{apiKey:{type:"string"}}},DevPortalOAuthConfig:{type:"object",description:"Settings for OAuth that is used to authenticate end-users to the developer portal and (optionally) for configuring issuing of OAuth Client Consumers using the identity provider",required:["provider","authority","jwksUrl"],additionalProperties:false,properties:{provider:{type:"string",enum:["okta","auth0","azure-ad"]},authority:{type:"string",description:"This is the full URL of the authorization server.\nOkta: https://dev-1235.okta.com/oauth2/aus123152352342\nAuth0: https://my-account.us.auth0.com\nAzure Active Directory: https://login.microsoftonline.com/{tenant}/v2.0"},jwksUrl:{type:"string",description:"The url of of the JWKS"},devPortalClient:{description:"This is the client that is used to authenticate end-users to the Zuplo developer portal",$ref:"#/$defs/DevPortalOAuthClientConfig"},managementClient:{oneOf:[{$ref:"#/$defs/DevPortalOAuthClientCredentialsConfig"},{$ref:"#/$defs/DevPortalAPIKeyCredentialConfig"}]}}},DevPortalExternalAuthConfig:{type:"object",description:"Settings for external auth that is used to authenticate end-users to the developer portal",additionalProperties:false,required:["loginUrl","provider","logoutUrl"],properties:{provider:{type:"string",enum:["external"]},loginUrl:{type:"string",description:"The URL of your external login page"},logoutUrl:{type:"string",description:"The URL of your external logout endpoint"}}},DevPortalAuthConfig:{type:"object",oneOf:[{$ref:"#/$defs/DevPortalOAuthConfig"},{$ref:"#/$defs/DevPortalExternalAuthConfig"}]},DevPortalMonetizationConfig:{type:"object",description:"Settings for monetization features like self-serve checkout and subscription management",oneOf:[{$ref:"#/$defs/DevPortalStripeMonetizationConfig"}]},DevPortalStripeMonetizationConfig:{type:"object",description:"Settings used to configure Stripe for monetization features like self-serve checkout and subscription management",additionalProperties:false,required:["provider","publishableKey","pricingTableId"],properties:{provider:{type:"string",enum:["stripe"]},publishableKey:{type:"string",description:"Your Stripe publishable key - found under Developers > Standard keys"},pricingTableId:{type:"string",description:"The ID of the pricing table that will be used to display pricing information to end-users"}}}},properties:{$schema:{type:"string"},enabled:{description:"If the developer portal is enabled",type:"boolean",default:true},authentication:{description:"Authentication configuration",$ref:"#/$defs/DevPortalAuthConfig"},monetization:{description:"Monetization configuration",$ref:"#/$defs/DevPortalMonetizationConfig"},sitePathname:{type:"string",default:"/docs"},faviconUrl:{type:"string",description:"The favicon url"},pageTitle:{type:"string",description:"The default page title"},enableAuthentication:{type:"boolean",description:"If sign in to the developer portal is enabled."},enableMonetization:{type:"boolean",description:"If monetization features like self-serve checkout and subscription management are enabled."},requireAuthentication:{type:"boolean",default:false,description:"If authentication is required to access the developer portal. If false, the developer portal will be publicly accessible."},authorizePathname:{type:"string",default:"/oauth/authorize",description:"The path that starts the OAuth flow for third-party-apps"},apiKeys:{description:"Api Keys Service Configuration",$ref:"#/$defs/ApiKeysConfig"},generateExamples:{type:"boolean",default:true,description:"If false, the developer portal will no longer generate examples for endpoints that do not have examples defined"}}}});var RL=y(Ji=>{"use strict";Object.defineProperty(Ji,"__esModule",{value:true});Ji.regexpCode=Ji.getEsmExportName=Ji.getProperty=Ji.safeStringify=Ji.stringify=Ji.strConcat=Ji.addCodeArg=Ji.str=Ji._=Ji.nil=Ji._Code=Ji.Name=Ji.IDENTIFIER=Ji._CodeOrName=void 0;var TL=class{static{a(this,"_CodeOrName")}};Ji._CodeOrName=TL;Ji.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;var kA=class extends TL{static{a(this,"Name")}constructor(t){super();if(!Ji.IDENTIFIER.test(t))throw new Error("CodeGen: name must be a valid identifier");this.str=t}toString(){return this.str}emptyStr(){return false}get names(){return{[this.str]:1}}};Ji.Name=kA;var Sf=class extends TL{static{a(this,"_Code")}constructor(t){super();this._items=typeof t==="string"?[t]:t}toString(){return this.str}emptyStr(){if(this._items.length>1)return false;const t=this._items[0];return t===""||t==='""'}get str(){var t;return(t=this._str)!==null&&t!==void 0?t:this._str=this._items.reduce((r,n)=>`${r}${n}`,"")}get names(){var t;return(t=this._names)!==null&&t!==void 0?t:this._names=this._items.reduce((r,n)=>{if(n instanceof kA)r[n.str]=(r[n.str]||0)+1;return r},{})}};Ji._Code=Sf;Ji.nil=new Sf("");function Svt(e,...t){const r=[e[0]];let n=0;while(n<t.length){uAe(r,t[n]);r.push(e[++n])}return new Sf(r)}a(Svt,"_");Ji._=Svt;var oAe=new Sf("+");function Avt(e,...t){const r=[xL(e[0])];let n=0;while(n<t.length){r.push(oAe);uAe(r,t[n]);r.push(oAe,xL(e[++n]))}bfn(r);return new Sf(r)}a(Avt,"str");Ji.str=Avt;function uAe(e,t){if(t instanceof Sf)e.push(...t._items);else if(t instanceof kA)e.push(t);else e.push(Cfn(t))}a(uAe,"addCodeArg");Ji.addCodeArg=uAe;function bfn(e){let t=1;while(t<e.length-1){if(e[t]===oAe){const r=Sfn(e[t-1],e[t+1]);if(r!==void 0){e.splice(t-1,3,r);continue}e[t++]="+"}t++}}a(bfn,"optimize");function Sfn(e,t){if(t==='""')return e;if(e==='""')return t;if(typeof e=="string"){if(t instanceof kA||e[e.length-1]!=='"')return;if(typeof t!="string")return`${e.slice(0,-1)}${t}"`;if(t[0]==='"')return e.slice(0,-1)+t.slice(1);return}if(typeof t=="string"&&t[0]==='"'&&!(e instanceof kA))return`"${e}${t.slice(1)}`;return}a(Sfn,"mergeExprItems");function Afn(e,t){return t.emptyStr()?e:e.emptyStr()?t:Avt`${e}${t}`}a(Afn,"strConcat");Ji.strConcat=Afn;function Cfn(e){return typeof e=="number"||typeof e=="boolean"||e===null?e:xL(Array.isArray(e)?e.join(","):e)}a(Cfn,"interpolate");function wfn(e){return new Sf(xL(e))}a(wfn,"stringify");Ji.stringify=wfn;function xL(e){return JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}a(xL,"safeStringify");Ji.safeStringify=xL;function Tfn(e){return typeof e=="string"&&Ji.IDENTIFIER.test(e)?new Sf(`.${e}`):Svt`[${e}]`}a(Tfn,"getProperty");Ji.getProperty=Tfn;function xfn(e){if(typeof e=="string"&&Ji.IDENTIFIER.test(e)){return new Sf(`${e}`)}throw new Error(`CodeGen: invalid export name: ${e}, use explicit $id name mapping`)}a(xfn,"getEsmExportName");Ji.getEsmExportName=xfn;function Rfn(e){return new Sf(e.toString())}a(Rfn,"regexpCode");Ji.regexpCode=Rfn});var pAe=y(vc=>{"use strict";Object.defineProperty(vc,"__esModule",{value:true});vc.ValueScope=vc.ValueScopeName=vc.Scope=vc.varKinds=vc.UsedValueState=void 0;var pd=RL();var lAe=class extends Error{static{a(this,"ValueError")}constructor(t){super(`CodeGen: "code" for ${t} not defined`);this.value=t.value}};var cAe;(function(e){e[e["Started"]=0]="Started";e[e["Completed"]=1]="Completed"})(cAe=vc.UsedValueState||(vc.UsedValueState={}));vc.varKinds={const:new pd.Name("const"),let:new pd.Name("let"),var:new pd.Name("var")};var gY=class{static{a(this,"Scope")}constructor({prefixes:t,parent:r}={}){this._names={};this._prefixes=t;this._parent=r}toName(t){return t instanceof pd.Name?t:this.name(t)}name(t){return new pd.Name(this._newName(t))}_newName(t){const r=this._names[t]||this._nameGroup(t);return`${t}${r.index++}`}_nameGroup(t){var r,n;if(((n=(r=this._parent)===null||r===void 0?void 0:r._prefixes)===null||n===void 0?void 0:n.has(t))||this._prefixes&&!this._prefixes.has(t)){throw new Error(`CodeGen: prefix "${t}" is not allowed in this scope`)}return this._names[t]={prefix:t,index:0}}};vc.Scope=gY;var yY=class extends pd.Name{static{a(this,"ValueScopeName")}constructor(t,r){super(r);this.prefix=t}setValue(t,{property:r,itemIndex:n}){this.value=t;this.scopePath=(0,pd._)`.${new pd.Name(r)}[${n}]`}};vc.ValueScopeName=yY;var Ofn=(0,pd._)`\n`;var dAe=class extends gY{static{a(this,"ValueScope")}constructor(t){super(t);this._values={};this._scope=t.scope;this.opts={...t,_n:t.lines?Ofn:pd.nil}}get(){return this._scope}name(t){return new yY(t,this._newName(t))}value(t,r){var n;if(r.ref===void 0)throw new Error("CodeGen: ref must be passed in value");const i=this.toName(t);const{prefix:s}=i;const o=(n=r.key)!==null&&n!==void 0?n:r.ref;let u=this._values[s];if(u){const d=u.get(o);if(d)return d}else{u=this._values[s]=new Map}u.set(o,i);const l=this._scope[s]||(this._scope[s]=[]);const c=l.length;l[c]=r.ref;i.setValue(r,{property:s,itemIndex:c});return i}getValue(t,r){const n=this._values[t];if(!n)return;return n.get(r)}scopeRefs(t,r=this._values){return this._reduceValues(r,n=>{if(n.scopePath===void 0)throw new Error(`CodeGen: name "${n}" has no value`);return(0,pd._)`${t}${n.scopePath}`})}scopeCode(t=this._values,r,n){return this._reduceValues(t,i=>{if(i.value===void 0)throw new Error(`CodeGen: name "${i}" has no value`);return i.value.code},r,n)}_reduceValues(t,r,n={},i){let s=pd.nil;for(const o in t){const u=t[o];if(!u)continue;const l=n[o]=n[o]||new Map;u.forEach(c=>{if(l.has(c))return;l.set(c,cAe.Started);let d=r(c);if(d){const p=this.opts.es5?vc.varKinds.var:vc.varKinds.const;s=(0,pd._)`${s}${p} ${c} = ${d};${this.opts._n}`}else if(d=i===null||i===void 0?void 0:i(c)){s=(0,pd._)`${s}${d}${this.opts._n}`}else{throw new lAe(c)}l.set(c,cAe.Completed)})}return s}};vc.ValueScope=dAe});var En=y(Vn=>{"use strict";Object.defineProperty(Vn,"__esModule",{value:true});Vn.or=Vn.and=Vn.not=Vn.CodeGen=Vn.operators=Vn.varKinds=Vn.ValueScopeName=Vn.ValueScope=Vn.Scope=Vn.Name=Vn.regexpCode=Vn.stringify=Vn.getProperty=Vn.nil=Vn.strConcat=Vn.str=Vn._=void 0;var Ti=RL();var nh=pAe();var hE=RL();Object.defineProperty(Vn,"_",{enumerable:true,get:function(){return hE._}});Object.defineProperty(Vn,"str",{enumerable:true,get:function(){return hE.str}});Object.defineProperty(Vn,"strConcat",{enumerable:true,get:function(){return hE.strConcat}});Object.defineProperty(Vn,"nil",{enumerable:true,get:function(){return hE.nil}});Object.defineProperty(Vn,"getProperty",{enumerable:true,get:function(){return hE.getProperty}});Object.defineProperty(Vn,"stringify",{enumerable:true,get:function(){return hE.stringify}});Object.defineProperty(Vn,"regexpCode",{enumerable:true,get:function(){return hE.regexpCode}});Object.defineProperty(Vn,"Name",{enumerable:true,get:function(){return hE.Name}});var bY=pAe();Object.defineProperty(Vn,"Scope",{enumerable:true,get:function(){return bY.Scope}});Object.defineProperty(Vn,"ValueScope",{enumerable:true,get:function(){return bY.ValueScope}});Object.defineProperty(Vn,"ValueScopeName",{enumerable:true,get:function(){return bY.ValueScopeName}});Object.defineProperty(Vn,"varKinds",{enumerable:true,get:function(){return bY.varKinds}});Vn.operators={GT:new Ti._Code(">"),GTE:new Ti._Code(">="),LT:new Ti._Code("<"),LTE:new Ti._Code("<="),EQ:new Ti._Code("==="),NEQ:new Ti._Code("!=="),NOT:new Ti._Code("!"),OR:new Ti._Code("||"),AND:new Ti._Code("&&"),ADD:new Ti._Code("+")};var gy=class{static{a(this,"Node")}optimizeNodes(){return this}optimizeNames(t,r){return this}};var fAe=class extends gy{static{a(this,"Def")}constructor(t,r,n){super();this.varKind=t;this.name=r;this.rhs=n}render({es5:t,_n:r}){const n=t?nh.varKinds.var:this.varKind;const i=this.rhs===void 0?"":` = ${this.rhs}`;return`${n} ${this.name}${i};`+r}optimizeNames(t,r){if(!t[this.name.str])return;if(this.rhs)this.rhs=dO(this.rhs,t,r);return this}get names(){return this.rhs instanceof Ti._CodeOrName?this.rhs.names:{}}};var _Y=class extends gy{static{a(this,"Assign")}constructor(t,r,n){super();this.lhs=t;this.rhs=r;this.sideEffects=n}render({_n:t}){return`${this.lhs} = ${this.rhs};`+t}optimizeNames(t,r){if(this.lhs instanceof Ti.Name&&!t[this.lhs.str]&&!this.sideEffects)return;this.rhs=dO(this.rhs,t,r);return this}get names(){const t=this.lhs instanceof Ti.Name?{}:{...this.lhs.names};return EY(t,this.rhs)}};var mAe=class extends _Y{static{a(this,"AssignOp")}constructor(t,r,n,i){super(t,n,i);this.op=r}render({_n:t}){return`${this.lhs} ${this.op}= ${this.rhs};`+t}};var hAe=class extends gy{static{a(this,"Label")}constructor(t){super();this.label=t;this.names={}}render({_n:t}){return`${this.label}:`+t}};var gAe=class extends gy{static{a(this,"Break")}constructor(t){super();this.label=t;this.names={}}render({_n:t}){const r=this.label?` ${this.label}`:"";return`break${r};`+t}};var yAe=class extends gy{static{a(this,"Throw")}constructor(t){super();this.error=t}render({_n:t}){return`throw ${this.error};`+t}get names(){return this.error.names}};var _Ae=class extends gy{static{a(this,"AnyCode")}constructor(t){super();this.code=t}render({_n:t}){return`${this.code};`+t}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(t,r){this.code=dO(this.code,t,r);return this}get names(){return this.code instanceof Ti._CodeOrName?this.code.names:{}}};var OL=class extends gy{static{a(this,"ParentNode")}constructor(t=[]){super();this.nodes=t}render(t){return this.nodes.reduce((r,n)=>r+n.render(t),"")}optimizeNodes(){const{nodes:t}=this;let r=t.length;while(r--){const n=t[r].optimizeNodes();if(Array.isArray(n))t.splice(r,1,...n);else if(n)t[r]=n;else t.splice(r,1)}return t.length>0?this:void 0}optimizeNames(t,r){const{nodes:n}=this;let i=n.length;while(i--){const s=n[i];if(s.optimizeNames(t,r))continue;Pfn(t,s.names);n.splice(i,1)}return n.length>0?this:void 0}get names(){return this.nodes.reduce((t,r)=>FA(t,r.names),{})}};var yy=class extends OL{static{a(this,"BlockNode")}render(t){return"{"+t._n+super.render(t)+"}"+t._n}};var vAe=class extends OL{static{a(this,"Root")}};var cO=class extends yy{static{a(this,"Else")}};cO.kind="else";var DA=class e extends yy{static{a(this,"If")}constructor(t,r){super(r);this.condition=t}render(t){let r=`if(${this.condition})`+super.render(t);if(this.else)r+="else "+this.else.render(t);return r}optimizeNodes(){super.optimizeNodes();const t=this.condition;if(t===true)return this.nodes;let r=this.else;if(r){const n=r.optimizeNodes();r=this.else=Array.isArray(n)?new cO(n):n}if(r){if(t===false)return r instanceof e?r:r.nodes;if(this.nodes.length)return this;return new e(Cvt(t),r instanceof e?[r]:r.nodes)}if(t===false||!this.nodes.length)return void 0;return this}optimizeNames(t,r){var n;this.else=(n=this.else)===null||n===void 0?void 0:n.optimizeNames(t,r);if(!(super.optimizeNames(t,r)||this.else))return;this.condition=dO(this.condition,t,r);return this}get names(){const t=super.names;EY(t,this.condition);if(this.else)FA(t,this.else.names);return t}};DA.kind="if";var LA=class extends yy{static{a(this,"For")}};LA.kind="for";var EAe=class extends LA{static{a(this,"ForLoop")}constructor(t){super();this.iteration=t}render(t){return`for(${this.iteration})`+super.render(t)}optimizeNames(t,r){if(!super.optimizeNames(t,r))return;this.iteration=dO(this.iteration,t,r);return this}get names(){return FA(super.names,this.iteration.names)}};var bAe=class extends LA{static{a(this,"ForRange")}constructor(t,r,n,i){super();this.varKind=t;this.name=r;this.from=n;this.to=i}render(t){const r=t.es5?nh.varKinds.var:this.varKind;const{name:n,from:i,to:s}=this;return`for(${r} ${n}=${i}; ${n}<${s}; ${n}++)`+super.render(t)}get names(){const t=EY(super.names,this.from);return EY(t,this.to)}};var vY=class extends LA{static{a(this,"ForIter")}constructor(t,r,n,i){super();this.loop=t;this.varKind=r;this.name=n;this.iterable=i}render(t){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(t)}optimizeNames(t,r){if(!super.optimizeNames(t,r))return;this.iterable=dO(this.iterable,t,r);return this}get names(){return FA(super.names,this.iterable.names)}};var PL=class extends yy{static{a(this,"Func")}constructor(t,r,n){super();this.name=t;this.args=r;this.async=n}render(t){const r=this.async?"async ":"";return`${r}function ${this.name}(${this.args})`+super.render(t)}};PL.kind="func";var NL=class extends OL{static{a(this,"Return")}render(t){return"return "+super.render(t)}};NL.kind="return";var SAe=class extends yy{static{a(this,"Try")}render(t){let r="try"+super.render(t);if(this.catch)r+=this.catch.render(t);if(this.finally)r+=this.finally.render(t);return r}optimizeNodes(){var t,r;super.optimizeNodes();(t=this.catch)===null||t===void 0?void 0:t.optimizeNodes();(r=this.finally)===null||r===void 0?void 0:r.optimizeNodes();return this}optimizeNames(t,r){var n,i;super.optimizeNames(t,r);(n=this.catch)===null||n===void 0?void 0:n.optimizeNames(t,r);(i=this.finally)===null||i===void 0?void 0:i.optimizeNames(t,r);return this}get names(){const t=super.names;if(this.catch)FA(t,this.catch.names);if(this.finally)FA(t,this.finally.names);return t}};var IL=class extends yy{static{a(this,"Catch")}constructor(t){super();this.error=t}render(t){return`catch(${this.error})`+super.render(t)}};IL.kind="catch";var kL=class extends yy{static{a(this,"Finally")}render(t){return"finally"+super.render(t)}};kL.kind="finally";var AAe=class{static{a(this,"CodeGen")}constructor(t,r={}){this._values={};this._blockStarts=[];this._constants={};this.opts={...r,_n:r.lines?"\n":""};this._extScope=t;this._scope=new nh.Scope({parent:t});this._nodes=[new vAe]}toString(){return this._root.render(this.opts)}name(t){return this._scope.name(t)}scopeName(t){return this._extScope.name(t)}scopeValue(t,r){const n=this._extScope.value(t,r);const i=this._values[n.prefix]||(this._values[n.prefix]=new Set);i.add(n);return n}getScopeValue(t,r){return this._extScope.getValue(t,r)}scopeRefs(t){return this._extScope.scopeRefs(t,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(t,r,n,i){const s=this._scope.toName(r);if(n!==void 0&&i)this._constants[s.str]=n;this._leafNode(new fAe(t,s,n));return s}const(t,r,n){return this._def(nh.varKinds.const,t,r,n)}let(t,r,n){return this._def(nh.varKinds.let,t,r,n)}var(t,r,n){return this._def(nh.varKinds.var,t,r,n)}assign(t,r,n){return this._leafNode(new _Y(t,r,n))}add(t,r){return this._leafNode(new mAe(t,Vn.operators.ADD,r))}code(t){if(typeof t=="function")t();else if(t!==Ti.nil)this._leafNode(new _Ae(t));return this}object(...t){const r=["{"];for(const[n,i]of t){if(r.length>1)r.push(",");r.push(n);if(n!==i||this.opts.es5){r.push(":");(0,Ti.addCodeArg)(r,i)}}r.push("}");return new Ti._Code(r)}if(t,r,n){this._blockNode(new DA(t));if(r&&n){this.code(r).else().code(n).endIf()}else if(r){this.code(r).endIf()}else if(n){throw new Error('CodeGen: "else" body without "then" body')}return this}elseIf(t){return this._elseNode(new DA(t))}else(){return this._elseNode(new cO)}endIf(){return this._endBlockNode(DA,cO)}_for(t,r){this._blockNode(t);if(r)this.code(r).endFor();return this}for(t,r){return this._for(new EAe(t),r)}forRange(t,r,n,i,s=this.opts.es5?nh.varKinds.var:nh.varKinds.let){const o=this._scope.toName(t);return this._for(new bAe(s,o,r,n),()=>i(o))}forOf(t,r,n,i=nh.varKinds.const){const s=this._scope.toName(t);if(this.opts.es5){const o=r instanceof Ti.Name?r:this.var("_arr",r);return this.forRange("_i",0,(0,Ti._)`${o}.length`,u=>{this.var(s,(0,Ti._)`${o}[${u}]`);n(s)})}return this._for(new vY("of",i,s,r),()=>n(s))}forIn(t,r,n,i=this.opts.es5?nh.varKinds.var:nh.varKinds.const){if(this.opts.ownProperties){return this.forOf(t,(0,Ti._)`Object.keys(${r})`,n)}const s=this._scope.toName(t);return this._for(new vY("in",i,s,r),()=>n(s))}endFor(){return this._endBlockNode(LA)}label(t){return this._leafNode(new hAe(t))}break(t){return this._leafNode(new gAe(t))}return(t){const r=new NL;this._blockNode(r);this.code(t);if(r.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(NL)}try(t,r,n){if(!r&&!n)throw new Error('CodeGen: "try" without "catch" and "finally"');const i=new SAe;this._blockNode(i);this.code(t);if(r){const s=this.name("e");this._currNode=i.catch=new IL(s);r(s)}if(n){this._currNode=i.finally=new kL;this.code(n)}return this._endBlockNode(IL,kL)}throw(t){return this._leafNode(new yAe(t))}block(t,r){this._blockStarts.push(this._nodes.length);if(t)this.code(t).endBlock(r);return this}endBlock(t){const r=this._blockStarts.pop();if(r===void 0)throw new Error("CodeGen: not in self-balancing block");const n=this._nodes.length-r;if(n<0||t!==void 0&&n!==t){throw new Error(`CodeGen: wrong number of nodes: ${n} vs ${t} expected`)}this._nodes.length=r;return this}func(t,r=Ti.nil,n,i){this._blockNode(new PL(t,r,n));if(i)this.code(i).endFunc();return this}endFunc(){return this._endBlockNode(PL)}optimize(t=1){while(t-- >0){this._root.optimizeNodes();this._root.optimizeNames(this._root.names,this._constants)}}_leafNode(t){this._currNode.nodes.push(t);return this}_blockNode(t){this._currNode.nodes.push(t);this._nodes.push(t)}_endBlockNode(t,r){const n=this._currNode;if(n instanceof t||r&&n instanceof r){this._nodes.pop();return this}throw new Error(`CodeGen: not in block "${r?`${t.kind}/${r.kind}`:t.kind}"`)}_elseNode(t){const r=this._currNode;if(!(r instanceof DA)){throw new Error('CodeGen: "else" without "if"')}this._currNode=r.else=t;return this}get _root(){return this._nodes[0]}get _currNode(){const t=this._nodes;return t[t.length-1]}set _currNode(t){const r=this._nodes;r[r.length-1]=t}};Vn.CodeGen=AAe;function FA(e,t){for(const r in t)e[r]=(e[r]||0)+(t[r]||0);return e}a(FA,"addNames");function EY(e,t){return t instanceof Ti._CodeOrName?FA(e,t.names):e}a(EY,"addExprNames");function dO(e,t,r){if(e instanceof Ti.Name)return n(e);if(!i(e))return e;return new Ti._Code(e._items.reduce((s,o)=>{if(o instanceof Ti.Name)o=n(o);if(o instanceof Ti._Code)s.push(...o._items);else s.push(o);return s},[]));function n(s){const o=r[s.str];if(o===void 0||t[s.str]!==1)return s;delete t[s.str];return o}a(n,"replaceName");function i(s){return s instanceof Ti._Code&&s._items.some(o=>o instanceof Ti.Name&&t[o.str]===1&&r[o.str]!==void 0)}a(i,"canOptimize")}a(dO,"optimizeExpr");function Pfn(e,t){for(const r in t)e[r]=(e[r]||0)-(t[r]||0)}a(Pfn,"subtractNames");function Cvt(e){return typeof e=="boolean"||typeof e=="number"||e===null?!e:(0,Ti._)`!${CAe(e)}`}a(Cvt,"not");Vn.not=Cvt;var Nfn=wvt(Vn.operators.AND);function Ifn(...e){return e.reduce(Nfn)}a(Ifn,"and");Vn.and=Ifn;var kfn=wvt(Vn.operators.OR);function Dfn(...e){return e.reduce(kfn)}a(Dfn,"or");Vn.or=Dfn;function wvt(e){return(t,r)=>t===Ti.nil?r:r===Ti.nil?t:(0,Ti._)`${CAe(t)} ${e} ${CAe(r)}`}a(wvt,"mappend");function CAe(e){return e instanceof Ti.Name?e:(0,Ti._)`(${e})`}a(CAe,"par")});var ui=y(zn=>{"use strict";Object.defineProperty(zn,"__esModule",{value:true});zn.checkStrictMode=zn.getErrorPath=zn.Type=zn.useFunc=zn.setEvaluated=zn.evaluatedPropsToName=zn.mergeEvaluated=zn.eachItem=zn.unescapeJsonPointer=zn.escapeJsonPointer=zn.escapeFragment=zn.unescapeFragment=zn.schemaRefOrVal=zn.schemaHasRulesButRef=zn.schemaHasRules=zn.checkUnknownRules=zn.alwaysValidSchema=zn.toHash=void 0;var Hs=En();var Lfn=RL();function Ffn(e){const t={};for(const r of e)t[r]=true;return t}a(Ffn,"toHash");zn.toHash=Ffn;function Bfn(e,t){if(typeof t=="boolean")return t;if(Object.keys(t).length===0)return true;Rvt(e,t);return!Ovt(t,e.self.RULES.all)}a(Bfn,"alwaysValidSchema");zn.alwaysValidSchema=Bfn;function Rvt(e,t=e.schema){const{opts:r,self:n}=e;if(!r.strictSchema)return;if(typeof t==="boolean")return;const i=n.RULES.keywords;for(const s in t){if(!i[s])kvt(e,`unknown keyword: "${s}"`)}}a(Rvt,"checkUnknownRules");zn.checkUnknownRules=Rvt;function Ovt(e,t){if(typeof e=="boolean")return!e;for(const r in e)if(t[r])return true;return false}a(Ovt,"schemaHasRules");zn.schemaHasRules=Ovt;function Mfn(e,t){if(typeof e=="boolean")return!e;for(const r in e)if(r!=="$ref"&&t.all[r])return true;return false}a(Mfn,"schemaHasRulesButRef");zn.schemaHasRulesButRef=Mfn;function qfn({topSchemaRef:e,schemaPath:t},r,n,i){if(!i){if(typeof r=="number"||typeof r=="boolean")return r;if(typeof r=="string")return(0,Hs._)`${r}`}return(0,Hs._)`${e}${t}${(0,Hs.getProperty)(n)}`}a(qfn,"schemaRefOrVal");zn.schemaRefOrVal=qfn;function Ufn(e){return Pvt(decodeURIComponent(e))}a(Ufn,"unescapeFragment");zn.unescapeFragment=Ufn;function $fn(e){return encodeURIComponent(wAe(e))}a($fn,"escapeFragment");zn.escapeFragment=$fn;function wAe(e){if(typeof e=="number")return`${e}`;return e.replace(/~/g,"~0").replace(/\//g,"~1")}a(wAe,"escapeJsonPointer");zn.escapeJsonPointer=wAe;function Pvt(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}a(Pvt,"unescapeJsonPointer");zn.unescapeJsonPointer=Pvt;function jfn(e,t){if(Array.isArray(e)){for(const r of e)t(r)}else{t(e)}}a(jfn,"eachItem");zn.eachItem=jfn;function Tvt({mergeNames:e,mergeToName:t,mergeValues:r,resultToName:n}){return(i,s,o,u)=>{const l=o===void 0?s:o instanceof Hs.Name?(s instanceof Hs.Name?e(i,s,o):t(i,s,o),o):s instanceof Hs.Name?(t(i,o,s),s):r(s,o);return u===Hs.Name&&!(l instanceof Hs.Name)?n(i,l):l}}a(Tvt,"makeMergeEvaluated");zn.mergeEvaluated={props:Tvt({mergeNames:(e,t,r)=>e.if((0,Hs._)`${r} !== true && ${t} !== undefined`,()=>{e.if((0,Hs._)`${t} === true`,()=>e.assign(r,true),()=>e.assign(r,(0,Hs._)`${r} || {}`).code((0,Hs._)`Object.assign(${r}, ${t})`))}),mergeToName:(e,t,r)=>e.if((0,Hs._)`${r} !== true`,()=>{if(t===true){e.assign(r,true)}else{e.assign(r,(0,Hs._)`${r} || {}`);TAe(e,r,t)}}),mergeValues:(e,t)=>e===true?true:{...e,...t},resultToName:Nvt}),items:Tvt({mergeNames:(e,t,r)=>e.if((0,Hs._)`${r} !== true && ${t} !== undefined`,()=>e.assign(r,(0,Hs._)`${t} === true ? true : ${r} > ${t} ? ${r} : ${t}`)),mergeToName:(e,t,r)=>e.if((0,Hs._)`${r} !== true`,()=>e.assign(r,t===true?true:(0,Hs._)`${r} > ${t} ? ${r} : ${t}`)),mergeValues:(e,t)=>e===true?true:Math.max(e,t),resultToName:(e,t)=>e.var("items",t)})};function Nvt(e,t){if(t===true)return e.var("props",true);const r=e.var("props",(0,Hs._)`{}`);if(t!==void 0)TAe(e,r,t);return r}a(Nvt,"evaluatedPropsToName");zn.evaluatedPropsToName=Nvt;function TAe(e,t,r){Object.keys(r).forEach(n=>e.assign((0,Hs._)`${t}${(0,Hs.getProperty)(n)}`,true))}a(TAe,"setEvaluated");zn.setEvaluated=TAe;var xvt={};function Gfn(e,t){return e.scopeValue("func",{ref:t,code:xvt[t.code]||(xvt[t.code]=new Lfn._Code(t.code))})}a(Gfn,"useFunc");zn.useFunc=Gfn;var Ivt;(function(e){e[e["Num"]=0]="Num";e[e["Str"]=1]="Str"})(Ivt=zn.Type||(zn.Type={}));function Hfn(e,t,r){if(e instanceof Hs.Name){const n=t===Ivt.Num;return r?n?(0,Hs._)`"[" + ${e} + "]"`:(0,Hs._)`"['" + ${e} + "']"`:n?(0,Hs._)`"/" + ${e}`:(0,Hs._)`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return r?(0,Hs.getProperty)(e).toString():"/"+wAe(e)}a(Hfn,"getErrorPath");zn.getErrorPath=Hfn;function kvt(e,t,r=e.opts.strictSchema){if(!r)return;t=`strict mode: ${t}`;if(r===true)throw new Error(t);e.self.logger.warn(t)}a(kvt,"checkStrictMode");zn.checkStrictMode=kvt});var Af=y(xAe=>{"use strict";Object.defineProperty(xAe,"__esModule",{value:true});var Nl=En();var Vfn={data:new Nl.Name("data"),valCxt:new Nl.Name("valCxt"),instancePath:new Nl.Name("instancePath"),parentData:new Nl.Name("parentData"),parentDataProperty:new Nl.Name("parentDataProperty"),rootData:new Nl.Name("rootData"),dynamicAnchors:new Nl.Name("dynamicAnchors"),vErrors:new Nl.Name("vErrors"),errors:new Nl.Name("errors"),this:new Nl.Name("this"),self:new Nl.Name("self"),scope:new Nl.Name("scope"),json:new Nl.Name("json"),jsonPos:new Nl.Name("jsonPos"),jsonLen:new Nl.Name("jsonLen"),jsonPart:new Nl.Name("jsonPart")};xAe.default=Vfn});var DL=y(Il=>{"use strict";Object.defineProperty(Il,"__esModule",{value:true});Il.extendErrors=Il.resetErrorsCount=Il.reportExtraError=Il.reportError=Il.keyword$DataError=Il.keywordError=void 0;var Fi=En();var SY=ui();var Ec=Af();Il.keywordError={message:({keyword:e})=>(0,Fi.str)`must pass "${e}" keyword validation`};Il.keyword$DataError={message:({keyword:e,schemaType:t})=>t?(0,Fi.str)`"${e}" keyword must be ${t} ($data)`:(0,Fi.str)`"${e}" keyword is invalid ($data)`};function zfn(e,t=Il.keywordError,r,n){const{it:i}=e;const{gen:s,compositeRule:o,allErrors:u}=i;const l=Fvt(e,t,r);if(n!==null&&n!==void 0?n:o||u){Dvt(s,l)}else{Lvt(i,(0,Fi._)`[${l}]`)}}a(zfn,"reportError");Il.reportError=zfn;function Kfn(e,t=Il.keywordError,r){const{it:n}=e;const{gen:i,compositeRule:s,allErrors:o}=n;const u=Fvt(e,t,r);Dvt(i,u);if(!(s||o)){Lvt(n,Ec.default.vErrors)}}a(Kfn,"reportExtraError");Il.reportExtraError=Kfn;function Wfn(e,t){e.assign(Ec.default.errors,t);e.if((0,Fi._)`${Ec.default.vErrors} !== null`,()=>e.if(t,()=>e.assign((0,Fi._)`${Ec.default.vErrors}.length`,t),()=>e.assign(Ec.default.vErrors,null)))}a(Wfn,"resetErrorsCount");Il.resetErrorsCount=Wfn;function Yfn({gen:e,keyword:t,schemaValue:r,data:n,errsCount:i,it:s}){if(i===void 0)throw new Error("ajv implementation error");const o=e.name("err");e.forRange("i",i,Ec.default.errors,u=>{e.const(o,(0,Fi._)`${Ec.default.vErrors}[${u}]`);e.if((0,Fi._)`${o}.instancePath === undefined`,()=>e.assign((0,Fi._)`${o}.instancePath`,(0,Fi.strConcat)(Ec.default.instancePath,s.errorPath)));e.assign((0,Fi._)`${o}.schemaPath`,(0,Fi.str)`${s.errSchemaPath}/${t}`);if(s.opts.verbose){e.assign((0,Fi._)`${o}.schema`,r);e.assign((0,Fi._)`${o}.data`,n)}})}a(Yfn,"extendErrors");Il.extendErrors=Yfn;function Dvt(e,t){const r=e.const("err",t);e.if((0,Fi._)`${Ec.default.vErrors} === null`,()=>e.assign(Ec.default.vErrors,(0,Fi._)`[${r}]`),(0,Fi._)`${Ec.default.vErrors}.push(${r})`);e.code((0,Fi._)`${Ec.default.errors}++`)}a(Dvt,"addError");function Lvt(e,t){const{gen:r,validateName:n,schemaEnv:i}=e;if(i.$async){r.throw((0,Fi._)`new ${e.ValidationError}(${t})`)}else{r.assign((0,Fi._)`${n}.errors`,t);r.return(false)}}a(Lvt,"returnErrors");var BA={keyword:new Fi.Name("keyword"),schemaPath:new Fi.Name("schemaPath"),params:new Fi.Name("params"),propertyName:new Fi.Name("propertyName"),message:new Fi.Name("message"),schema:new Fi.Name("schema"),parentSchema:new Fi.Name("parentSchema")};function Fvt(e,t,r){const{createErrors:n}=e.it;if(n===false)return(0,Fi._)`{}`;return Xfn(e,t,r)}a(Fvt,"errorObjectCode");function Xfn(e,t,r={}){const{gen:n,it:i}=e;const s=[Jfn(i,r),Qfn(e,r)];Zfn(e,t,s);return n.object(...s)}a(Xfn,"errorObject");function Jfn({errorPath:e},{instancePath:t}){const r=t?(0,Fi.str)`${e}${(0,SY.getErrorPath)(t,SY.Type.Str)}`:e;return[Ec.default.instancePath,(0,Fi.strConcat)(Ec.default.instancePath,r)]}a(Jfn,"errorInstancePath");function Qfn({keyword:e,it:{errSchemaPath:t}},{schemaPath:r,parentSchema:n}){let i=n?t:(0,Fi.str)`${t}/${e}`;if(r){i=(0,Fi.str)`${i}${(0,SY.getErrorPath)(r,SY.Type.Str)}`}return[BA.schemaPath,i]}a(Qfn,"errorSchemaPath");function Zfn(e,{params:t,message:r},n){const{keyword:i,data:s,schemaValue:o,it:u}=e;const{opts:l,propertyName:c,topSchemaRef:d,schemaPath:p}=u;n.push([BA.keyword,i],[BA.params,typeof t=="function"?t(e):t||(0,Fi._)`{}`]);if(l.messages){n.push([BA.message,typeof r=="function"?r(e):r])}if(l.verbose){n.push([BA.schema,o],[BA.parentSchema,(0,Fi._)`${d}${p}`],[Ec.default.data,s])}if(c)n.push([BA.propertyName,c])}a(Zfn,"extraErrorProps")});var Mvt=y(pO=>{"use strict";Object.defineProperty(pO,"__esModule",{value:true});pO.boolOrEmptySchema=pO.topBoolOrEmptySchema=void 0;var emn=DL();var tmn=En();var rmn=Af();var nmn={message:"boolean schema is false"};function imn(e){const{gen:t,schema:r,validateName:n}=e;if(r===false){Bvt(e,false)}else if(typeof r=="object"&&r.$async===true){t.return(rmn.default.data)}else{t.assign((0,tmn._)`${n}.errors`,null);t.return(true)}}a(imn,"topBoolOrEmptySchema");pO.topBoolOrEmptySchema=imn;function smn(e,t){const{gen:r,schema:n}=e;if(n===false){r.var(t,false);Bvt(e)}else{r.var(t,true)}}a(smn,"boolOrEmptySchema");pO.boolOrEmptySchema=smn;function Bvt(e,t){const{gen:r,data:n}=e;const i={gen:r,keyword:"false schema",data:n,schema:false,schemaCode:false,schemaValue:false,params:{},it:e};(0,emn.reportError)(i,nmn,void 0,t)}a(Bvt,"falseSchemaError")});var RAe=y(fO=>{"use strict";Object.defineProperty(fO,"__esModule",{value:true});fO.getRules=fO.isJSONType=void 0;var amn=["string","number","integer","boolean","null","object","array"];var omn=new Set(amn);function umn(e){return typeof e=="string"&&omn.has(e)}a(umn,"isJSONType");fO.isJSONType=umn;function lmn(){const e={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...e,integer:true,boolean:true,null:true},rules:[{rules:[]},e.number,e.string,e.array,e.object],post:{rules:[]},all:{},keywords:{}}}a(lmn,"getRules");fO.getRules=lmn});var OAe=y(gE=>{"use strict";Object.defineProperty(gE,"__esModule",{value:true});gE.shouldUseRule=gE.shouldUseGroup=gE.schemaHasRulesForType=void 0;function cmn({schema:e,self:t},r){const n=t.RULES.types[r];return n&&n!==true&&qvt(e,n)}a(cmn,"schemaHasRulesForType");gE.schemaHasRulesForType=cmn;function qvt(e,t){return t.rules.some(r=>Uvt(e,r))}a(qvt,"shouldUseGroup");gE.shouldUseGroup=qvt;function Uvt(e,t){var r;return e[t.keyword]!==void 0||((r=t.definition.implements)===null||r===void 0?void 0:r.some(n=>e[n]!==void 0))}a(Uvt,"shouldUseRule");gE.shouldUseRule=Uvt});var FL=y(tl=>{"use strict";Object.defineProperty(tl,"__esModule",{value:true});tl.reportTypeError=tl.checkDataTypes=tl.checkDataType=tl.coerceAndCheckDataType=tl.getJSONTypes=tl.getSchemaTypes=tl.DataType=void 0;var dmn=RAe();var pmn=OAe();var fmn=DL();var On=En();var $vt=ui();var LL;(function(e){e[e["Correct"]=0]="Correct";e[e["Wrong"]=1]="Wrong"})(LL=tl.DataType||(tl.DataType={}));function mmn(e){const t=jvt(e.type);const r=t.includes("null");if(r){if(e.nullable===false)throw new Error("type: null contradicts nullable: false")}else{if(!t.length&&e.nullable!==void 0){throw new Error('"nullable" cannot be used without "type"')}if(e.nullable===true)t.push("null")}return t}a(mmn,"getSchemaTypes");tl.getSchemaTypes=mmn;function jvt(e){const t=Array.isArray(e)?e:e?[e]:[];if(t.every(dmn.isJSONType))return t;throw new Error("type must be JSONType or JSONType[]: "+t.join(","))}a(jvt,"getJSONTypes");tl.getJSONTypes=jvt;function hmn(e,t){const{gen:r,data:n,opts:i}=e;const s=gmn(t,i.coerceTypes);const o=t.length>0&&!(s.length===0&&t.length===1&&(0,pmn.schemaHasRulesForType)(e,t[0]));if(o){const u=NAe(t,n,i.strictNumbers,LL.Wrong);r.if(u,()=>{if(s.length)ymn(e,t,s);else IAe(e)})}return o}a(hmn,"coerceAndCheckDataType");tl.coerceAndCheckDataType=hmn;var Gvt=new Set(["string","number","integer","boolean","null"]);function gmn(e,t){return t?e.filter(r=>Gvt.has(r)||t==="array"&&r==="array"):[]}a(gmn,"coerceToTypes");function ymn(e,t,r){const{gen:n,data:i,opts:s}=e;const o=n.let("dataType",(0,On._)`typeof ${i}`);const u=n.let("coerced",(0,On._)`undefined`);if(s.coerceTypes==="array"){n.if((0,On._)`${o} == 'object' && Array.isArray(${i}) && ${i}.length == 1`,()=>n.assign(i,(0,On._)`${i}[0]`).assign(o,(0,On._)`typeof ${i}`).if(NAe(t,i,s.strictNumbers),()=>n.assign(u,i)))}n.if((0,On._)`${u} !== undefined`);for(const c of r){if(Gvt.has(c)||c==="array"&&s.coerceTypes==="array"){l(c)}}n.else();IAe(e);n.endIf();n.if((0,On._)`${u} !== undefined`,()=>{n.assign(i,u);_mn(e,u)});function l(c){switch(c){case"string":n.elseIf((0,On._)`${o} == "number" || ${o} == "boolean"`).assign(u,(0,On._)`"" + ${i}`).elseIf((0,On._)`${i} === null`).assign(u,(0,On._)`""`);return;case"number":n.elseIf((0,On._)`${o} == "boolean" || ${i} === null
|
|
396
396
|
|| (${o} == "string" && ${i} && ${i} == +${i})`).assign(u,(0,On._)`+${i}`);return;case"integer":n.elseIf((0,On._)`${o} === "boolean" || ${i} === null
|
|
397
397
|
|| (${o} === "string" && ${i} && ${i} == +${i} && !(${i} % 1))`).assign(u,(0,On._)`+${i}`);return;case"boolean":n.elseIf((0,On._)`${i} === "false" || ${i} === 0 || ${i} === null`).assign(u,false).elseIf((0,On._)`${i} === "true" || ${i} === 1`).assign(u,true);return;case"null":n.elseIf((0,On._)`${i} === "" || ${i} === 0 || ${i} === false`);n.assign(u,null);return;case"array":n.elseIf((0,On._)`${o} === "string" || ${o} === "number"
|
|
398
398
|
|| ${o} === "boolean" || ${i} === null`).assign(u,(0,On._)`[${i}]`)}}a(l,"coerceSpecificType")}a(ymn,"coerceData");function _mn({gen:e,parentData:t,parentDataProperty:r},n){e.if((0,On._)`${t} !== undefined`,()=>e.assign((0,On._)`${t}[${r}]`,n))}a(_mn,"assignParentData");function PAe(e,t,r,n=LL.Correct){const i=n===LL.Correct?On.operators.EQ:On.operators.NEQ;let s;switch(e){case"null":return(0,On._)`${t} ${i} null`;case"array":s=(0,On._)`Array.isArray(${t})`;break;case"object":s=(0,On._)`${t} && typeof ${t} == "object" && !Array.isArray(${t})`;break;case"integer":s=o((0,On._)`!(${t} % 1) && !isNaN(${t})`);break;case"number":s=o();break;default:return(0,On._)`typeof ${t} ${i} ${e}`}return n===LL.Correct?s:(0,On.not)(s);function o(u=On.nil){return(0,On.and)((0,On._)`typeof ${t} == "number"`,u,r?(0,On._)`isFinite(${t})`:On.nil)}a(o,"numCond")}a(PAe,"checkDataType");tl.checkDataType=PAe;function NAe(e,t,r,n){if(e.length===1){return PAe(e[0],t,r,n)}let i;const s=(0,$vt.toHash)(e);if(s.array&&s.object){const o=(0,On._)`typeof ${t} != "object"`;i=s.null?o:(0,On._)`!${t} || ${o}`;delete s.null;delete s.array;delete s.object}else{i=On.nil}if(s.number)delete s.integer;for(const o in s)i=(0,On.and)(i,PAe(o,t,r,n));return i}a(NAe,"checkDataTypes");tl.checkDataTypes=NAe;var vmn={message:({schema:e})=>`must be ${e}`,params:({schema:e,schemaValue:t})=>typeof e=="string"?(0,On._)`{type: ${e}}`:(0,On._)`{type: ${t}}`};function IAe(e){const t=Emn(e);(0,fmn.reportError)(t,vmn)}a(IAe,"reportTypeError");tl.reportTypeError=IAe;function Emn(e){const{gen:t,data:r,schema:n}=e;const i=(0,$vt.schemaRefOrVal)(e,n,"type");return{gen:t,keyword:"type",data:r,schema:n.type,schemaCode:i,schemaValue:i,parentSchema:n,params:{},it:e}}a(Emn,"getTypeErrorContext")});var Vvt=y(AY=>{"use strict";Object.defineProperty(AY,"__esModule",{value:true});AY.assignDefaults=void 0;var mO=En();var bmn=ui();function Smn(e,t){const{properties:r,items:n}=e.schema;if(t==="object"&&r){for(const i in r){Hvt(e,i,r[i].default)}}else if(t==="array"&&Array.isArray(n)){n.forEach((i,s)=>Hvt(e,s,i.default))}}a(Smn,"assignDefaults");AY.assignDefaults=Smn;function Hvt(e,t,r){const{gen:n,compositeRule:i,data:s,opts:o}=e;if(r===void 0)return;const u=(0,mO._)`${s}${(0,mO.getProperty)(t)}`;if(i){(0,bmn.checkStrictMode)(e,`default is ignored for: ${u}`);return}let l=(0,mO._)`${u} === undefined`;if(o.useDefaults==="empty"){l=(0,mO._)`${l} || ${u} === null || ${u} === ""`}n.if(l,(0,mO._)`${u} = ${(0,mO.stringify)(r)}`)}a(Hvt,"assignDefault")});var Cf=y(ks=>{"use strict";Object.defineProperty(ks,"__esModule",{value:true});ks.validateUnion=ks.validateArray=ks.usePattern=ks.callValidateCode=ks.schemaProperties=ks.allSchemaProperties=ks.noPropertyInData=ks.propertyInData=ks.isOwnProperty=ks.hasPropFunc=ks.reportMissingProp=ks.checkMissingProp=ks.checkReportMissingProp=void 0;var _a=En();var kAe=ui();var yE=Af();var Amn=ui();function Cmn(e,t){const{gen:r,data:n,it:i}=e;r.if(LAe(r,n,t,i.opts.ownProperties),()=>{e.setParams({missingProperty:(0,_a._)`${t}`},true);e.error()})}a(Cmn,"checkReportMissingProp");ks.checkReportMissingProp=Cmn;function wmn({gen:e,data:t,it:{opts:r}},n,i){return(0,_a.or)(...n.map(s=>(0,_a.and)(LAe(e,t,s,r.ownProperties),(0,_a._)`${i} = ${s}`)))}a(wmn,"checkMissingProp");ks.checkMissingProp=wmn;function Tmn(e,t){e.setParams({missingProperty:t},true);e.error()}a(Tmn,"reportMissingProp");ks.reportMissingProp=Tmn;function zvt(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,_a._)`Object.prototype.hasOwnProperty`})}a(zvt,"hasPropFunc");ks.hasPropFunc=zvt;function DAe(e,t,r){return(0,_a._)`${zvt(e)}.call(${t}, ${r})`}a(DAe,"isOwnProperty");ks.isOwnProperty=DAe;function xmn(e,t,r,n){const i=(0,_a._)`${t}${(0,_a.getProperty)(r)} !== undefined`;return n?(0,_a._)`${i} && ${DAe(e,t,r)}`:i}a(xmn,"propertyInData");ks.propertyInData=xmn;function LAe(e,t,r,n){const i=(0,_a._)`${t}${(0,_a.getProperty)(r)} === undefined`;return n?(0,_a.or)(i,(0,_a.not)(DAe(e,t,r))):i}a(LAe,"noPropertyInData");ks.noPropertyInData=LAe;function Kvt(e){return e?Object.keys(e).filter(t=>t!=="__proto__"):[]}a(Kvt,"allSchemaProperties");ks.allSchemaProperties=Kvt;function Rmn(e,t){return Kvt(t).filter(r=>!(0,kAe.alwaysValidSchema)(e,t[r]))}a(Rmn,"schemaProperties");ks.schemaProperties=Rmn;function Omn({schemaCode:e,data:t,it:{gen:r,topSchemaRef:n,schemaPath:i,errorPath:s},it:o},u,l,c){const d=c?(0,_a._)`${e}, ${t}, ${n}${i}`:t;const p=[[yE.default.instancePath,(0,_a.strConcat)(yE.default.instancePath,s)],[yE.default.parentData,o.parentData],[yE.default.parentDataProperty,o.parentDataProperty],[yE.default.rootData,yE.default.rootData]];if(o.opts.dynamicRef)p.push([yE.default.dynamicAnchors,yE.default.dynamicAnchors]);const f=(0,_a._)`${d}, ${r.object(...p)}`;return l!==_a.nil?(0,_a._)`${u}.call(${l}, ${f})`:(0,_a._)`${u}(${f})`}a(Omn,"callValidateCode");ks.callValidateCode=Omn;var Pmn=(0,_a._)`new RegExp`;function Nmn({gen:e,it:{opts:t}},r){const n=t.unicodeRegExp?"u":"";const{regExp:i}=t.code;const s=i(r,n);return e.scopeValue("pattern",{key:s.toString(),ref:s,code:(0,_a._)`${i.code==="new RegExp"?Pmn:(0,Amn.useFunc)(e,i)}(${r}, ${n})`})}a(Nmn,"usePattern");ks.usePattern=Nmn;function Imn(e){const{gen:t,data:r,keyword:n,it:i}=e;const s=t.name("valid");if(i.allErrors){const u=t.let("valid",true);o(()=>t.assign(u,false));return u}t.var(s,true);o(()=>t.break());return s;function o(u){const l=t.const("len",(0,_a._)`${r}.length`);t.forRange("i",0,l,c=>{e.subschema({keyword:n,dataProp:c,dataPropType:kAe.Type.Num},s);t.if((0,_a.not)(s),u)})}a(o,"validateItems")}a(Imn,"validateArray");ks.validateArray=Imn;function kmn(e){const{gen:t,schema:r,keyword:n,it:i}=e;if(!Array.isArray(r))throw new Error("ajv implementation error");const s=r.some(l=>(0,kAe.alwaysValidSchema)(i,l));if(s&&!i.opts.unevaluated)return;const o=t.let("valid",false);const u=t.name("_valid");t.block(()=>r.forEach((l,c)=>{const d=e.subschema({keyword:n,schemaProp:c,compositeRule:true},u);t.assign(o,(0,_a._)`${o} || ${u}`);const p=e.mergeValidEvaluated(d,u);if(!p)t.if((0,_a.not)(o))}));e.result(o,()=>e.reset(),()=>e.error(true))}a(kmn,"validateUnion");ks.validateUnion=kmn});var Xvt=y(U0=>{"use strict";Object.defineProperty(U0,"__esModule",{value:true});U0.validateKeywordUsage=U0.validSchemaType=U0.funcKeywordCode=U0.macroKeywordCode=void 0;var bc=En();var MA=Af();var Dmn=Cf();var Lmn=DL();function Fmn(e,t){const{gen:r,keyword:n,schema:i,parentSchema:s,it:o}=e;const u=t.macro.call(o.self,i,s,o);const l=Yvt(r,n,u);if(o.opts.validateSchema!==false)o.self.validateSchema(u,true);const c=r.name("valid");e.subschema({schema:u,schemaPath:bc.nil,errSchemaPath:`${o.errSchemaPath}/${n}`,topSchemaRef:l,compositeRule:true},c);e.pass(c,()=>e.error(true))}a(Fmn,"macroKeywordCode");U0.macroKeywordCode=Fmn;function Bmn(e,t){var r;const{gen:n,keyword:i,schema:s,parentSchema:o,$data:u,it:l}=e;qmn(l,t);const c=!u&&t.compile?t.compile.call(l.self,s,o,l):t.validate;const d=Yvt(n,i,c);const p=n.let("valid");e.block$data(p,f);e.ok((r=t.valid)!==null&&r!==void 0?r:p);function f(){if(t.errors===false){g();if(t.modifying)Wvt(e);_(()=>e.error())}else{const v=t.async?m():h();if(t.modifying)Wvt(e);_(()=>Mmn(e,v))}}a(f,"validateKeyword");function m(){const v=n.let("ruleErrs",null);n.try(()=>g((0,bc._)`await `),S=>n.assign(p,false).if((0,bc._)`${S} instanceof ${l.ValidationError}`,()=>n.assign(v,(0,bc._)`${S}.errors`),()=>n.throw(S)));return v}a(m,"validateAsync");function h(){const v=(0,bc._)`${d}.errors`;n.assign(v,null);g(bc.nil);return v}a(h,"validateSync");function g(v=t.async?(0,bc._)`await `:bc.nil){const S=l.opts.passContext?MA.default.this:MA.default.self;const E=!("compile"in t&&!u||t.schema===false);n.assign(p,(0,bc._)`${v}${(0,Dmn.callValidateCode)(e,d,S,E)}`,t.modifying)}a(g,"assignValid");function _(v){var S;n.if((0,bc.not)((S=t.valid)!==null&&S!==void 0?S:p),v)}a(_,"reportErrs")}a(Bmn,"funcKeywordCode");U0.funcKeywordCode=Bmn;function Wvt(e){const{gen:t,data:r,it:n}=e;t.if(n.parentData,()=>t.assign(r,(0,bc._)`${n.parentData}[${n.parentDataProperty}]`))}a(Wvt,"modifyData");function Mmn(e,t){const{gen:r}=e;r.if((0,bc._)`Array.isArray(${t})`,()=>{r.assign(MA.default.vErrors,(0,bc._)`${MA.default.vErrors} === null ? ${t} : ${MA.default.vErrors}.concat(${t})`).assign(MA.default.errors,(0,bc._)`${MA.default.vErrors}.length`);(0,Lmn.extendErrors)(e)},()=>e.error())}a(Mmn,"addErrs");function qmn({schemaEnv:e},t){if(t.async&&!e.$async)throw new Error("async keyword in sync schema")}a(qmn,"checkAsyncKeyword");function Yvt(e,t,r){if(r===void 0)throw new Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword",typeof r=="function"?{ref:r}:{ref:r,code:(0,bc.stringify)(r)})}a(Yvt,"useKeyword");function Umn(e,t,r=false){return!t.length||t.some(n=>n==="array"?Array.isArray(e):n==="object"?e&&typeof e=="object"&&!Array.isArray(e):typeof e==n||r&&typeof e=="undefined")}a(Umn,"validSchemaType");U0.validSchemaType=Umn;function $mn({schema:e,opts:t,self:r,errSchemaPath:n},i,s){if(Array.isArray(i.keyword)?!i.keyword.includes(s):i.keyword!==s){throw new Error("ajv implementation error")}const o=i.dependencies;if(o===null||o===void 0?void 0:o.some(u=>!Object.prototype.hasOwnProperty.call(e,u))){throw new Error(`parent schema must have dependencies of ${s}: ${o.join(",")}`)}if(i.validateSchema){const u=i.validateSchema(e[s]);if(!u){const l=`keyword "${s}" value is invalid at path "${n}": `+r.errorsText(i.validateSchema.errors);if(t.validateSchema==="log")r.logger.error(l);else throw new Error(l)}}}a($mn,"validateKeywordUsage");U0.validateKeywordUsage=$mn});var Qvt=y(_E=>{"use strict";Object.defineProperty(_E,"__esModule",{value:true});_E.extendSubschemaMode=_E.extendSubschemaData=_E.getSubschema=void 0;var $0=En();var Jvt=ui();function jmn(e,{keyword:t,schemaProp:r,schema:n,schemaPath:i,errSchemaPath:s,topSchemaRef:o}){if(t!==void 0&&n!==void 0){throw new Error('both "keyword" and "schema" passed, only one allowed')}if(t!==void 0){const u=e.schema[t];return r===void 0?{schema:u,schemaPath:(0,$0._)`${e.schemaPath}${(0,$0.getProperty)(t)}`,errSchemaPath:`${e.errSchemaPath}/${t}`}:{schema:u[r],schemaPath:(0,$0._)`${e.schemaPath}${(0,$0.getProperty)(t)}${(0,$0.getProperty)(r)}`,errSchemaPath:`${e.errSchemaPath}/${t}/${(0,Jvt.escapeFragment)(r)}`}}if(n!==void 0){if(i===void 0||s===void 0||o===void 0){throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"')}return{schema:n,schemaPath:i,topSchemaRef:o,errSchemaPath:s}}throw new Error('either "keyword" or "schema" must be passed')}a(jmn,"getSubschema");_E.getSubschema=jmn;function Gmn(e,t,{dataProp:r,dataPropType:n,data:i,dataTypes:s,propertyName:o}){if(i!==void 0&&r!==void 0){throw new Error('both "data" and "dataProp" passed, only one allowed')}const{gen:u}=t;if(r!==void 0){const{errorPath:c,dataPathArr:d,opts:p}=t;const f=u.let("data",(0,$0._)`${t.data}${(0,$0.getProperty)(r)}`,true);l(f);e.errorPath=(0,$0.str)`${c}${(0,Jvt.getErrorPath)(r,n,p.jsPropertySyntax)}`;e.parentDataProperty=(0,$0._)`${r}`;e.dataPathArr=[...d,e.parentDataProperty]}if(i!==void 0){const c=i instanceof $0.Name?i:u.let("data",i,true);l(c);if(o!==void 0)e.propertyName=o}if(s)e.dataTypes=s;function l(c){e.data=c;e.dataLevel=t.dataLevel+1;e.dataTypes=[];t.definedProperties=new Set;e.parentData=t.data;e.dataNames=[...t.dataNames,c]}a(l,"dataContextProps")}a(Gmn,"extendSubschemaData");_E.extendSubschemaData=Gmn;function Hmn(e,{jtdDiscriminator:t,jtdMetadata:r,compositeRule:n,createErrors:i,allErrors:s}){if(n!==void 0)e.compositeRule=n;if(i!==void 0)e.createErrors=i;if(s!==void 0)e.allErrors=s;e.jtdDiscriminator=t;e.jtdMetadata=r}a(Hmn,"extendSubschemaMode");_E.extendSubschemaMode=Hmn});var BL=y(fd=>{"use strict";Object.defineProperty(fd,"__esModule",{value:true});fd.getSchemaRefs=fd.resolveUrl=fd.normalizeId=fd._getFullPath=fd.getFullPath=fd.inlineRef=void 0;var Vmn=ui();var zmn=rp();var Kmn=dx();var Wmn=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function Ymn(e,t=true){if(typeof e=="boolean")return true;if(t===true)return!FAe(e);if(!t)return false;return Zvt(e)<=t}a(Ymn,"inlineRef");fd.inlineRef=Ymn;var Xmn=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function FAe(e){for(const t in e){if(Xmn.has(t))return true;const r=e[t];if(Array.isArray(r)&&r.some(FAe))return true;if(typeof r=="object"&&FAe(r))return true}return false}a(FAe,"hasRef");function Zvt(e){let t=0;for(const r in e){if(r==="$ref")return Infinity;t++;if(Wmn.has(r))continue;if(typeof e[r]=="object"){(0,Vmn.eachItem)(e[r],n=>t+=Zvt(n))}if(t===Infinity)return Infinity}return t}a(Zvt,"countKeys");function eEt(e,t="",r){if(r!==false)t=hO(t);const n=e.parse(t);return tEt(e,n)}a(eEt,"getFullPath");fd.getFullPath=eEt;function tEt(e,t){const r=e.serialize(t);return r.split("#")[0]+"#"}a(tEt,"_getFullPath");fd._getFullPath=tEt;var Jmn=/#\/?$/;function hO(e){return e?e.replace(Jmn,""):""}a(hO,"normalizeId");fd.normalizeId=hO;function Qmn(e,t,r){r=hO(r);return e.resolve(t,r)}a(Qmn,"resolveUrl");fd.resolveUrl=Qmn;var Zmn=/^[a-z_][-a-z0-9._]*$/i;function ehn(e,t){if(typeof e=="boolean")return{};const{schemaId:r,uriResolver:n}=this.opts;const i=hO(e[r]||t);const s={"":i};const o=eEt(n,i,false);const u={};const l=new Set;Kmn(e,{allKeys:true},(p,f,m,h)=>{if(h===void 0)return;const g=o+f;let _=s[h];if(typeof p[r]=="string")_=v.call(this,p[r]);S.call(this,p.$anchor);S.call(this,p.$dynamicAnchor);s[f]=_;function v(E){const b=this.opts.uriResolver.resolve;E=hO(_?b(_,E):E);if(l.has(E))throw d(E);l.add(E);let A=this.refs[E];if(typeof A=="string")A=this.refs[A];if(typeof A=="object"){c(p,A.schema,E)}else if(E!==hO(g)){if(E[0]==="#"){c(p,u[E],E);u[E]=p}else{this.refs[E]=g}}return E}a(v,"addRef");function S(E){if(typeof E=="string"){if(!Zmn.test(E))throw new Error(`invalid anchor "${E}"`);v.call(this,`#${E}`)}}a(S,"addAnchor")});return u;function c(p,f,m){if(f!==void 0&&!zmn(p,f))throw d(m)}a(c,"checkAmbiguosRef");function d(p){return new Error(`reference "${p}" resolves to more than one schema`)}a(d,"ambiguos")}a(ehn,"getSchemaRefs");fd.getSchemaRefs=ehn});var UL=y(vE=>{"use strict";Object.defineProperty(vE,"__esModule",{value:true});vE.getData=vE.KeywordCxt=vE.validateFunctionCode=void 0;var aEt=Mvt();var rEt=FL();var MAe=OAe();var CY=FL();var thn=Vvt();var qL=Xvt();var BAe=Qvt();var Sr=En();var tn=Af();var rhn=BL();var _y=ui();var ML=DL();function nhn(e){if(lEt(e)){cEt(e);if(uEt(e)){ahn(e);return}}oEt(e,()=>(0,aEt.topBoolOrEmptySchema)(e))}a(nhn,"validateFunctionCode");vE.validateFunctionCode=nhn;function oEt({gen:e,validateName:t,schema:r,schemaEnv:n,opts:i},s){if(i.code.es5){e.func(t,(0,Sr._)`${tn.default.data}, ${tn.default.valCxt}`,n.$async,()=>{e.code((0,Sr._)`"use strict"; ${nEt(r,i)}`);shn(e,i);e.code(s)})}else{e.func(t,(0,Sr._)`${tn.default.data}, ${ihn(i)}`,n.$async,()=>e.code(nEt(r,i)).code(s))}}a(oEt,"validateFunction");function ihn(e){return(0,Sr._)`{${tn.default.instancePath}="", ${tn.default.parentData}, ${tn.default.parentDataProperty}, ${tn.default.rootData}=${tn.default.data}${e.dynamicRef?(0,Sr._)`, ${tn.default.dynamicAnchors}={}`:Sr.nil}}={}`}a(ihn,"destructureValCxt");function shn(e,t){e.if(tn.default.valCxt,()=>{e.var(tn.default.instancePath,(0,Sr._)`${tn.default.valCxt}.${tn.default.instancePath}`);e.var(tn.default.parentData,(0,Sr._)`${tn.default.valCxt}.${tn.default.parentData}`);e.var(tn.default.parentDataProperty,(0,Sr._)`${tn.default.valCxt}.${tn.default.parentDataProperty}`);e.var(tn.default.rootData,(0,Sr._)`${tn.default.valCxt}.${tn.default.rootData}`);if(t.dynamicRef)e.var(tn.default.dynamicAnchors,(0,Sr._)`${tn.default.valCxt}.${tn.default.dynamicAnchors}`)},()=>{e.var(tn.default.instancePath,(0,Sr._)`""`);e.var(tn.default.parentData,(0,Sr._)`undefined`);e.var(tn.default.parentDataProperty,(0,Sr._)`undefined`);e.var(tn.default.rootData,tn.default.data);if(t.dynamicRef)e.var(tn.default.dynamicAnchors,(0,Sr._)`{}`)})}a(shn,"destructureValCxtES5");function ahn(e){const{schema:t,opts:r,gen:n}=e;oEt(e,()=>{if(r.$comment&&t.$comment)pEt(e);dhn(e);n.let(tn.default.vErrors,null);n.let(tn.default.errors,0);if(r.unevaluated)ohn(e);dEt(e);mhn(e)});return}a(ahn,"topSchemaObjCode");function ohn(e){const{gen:t,validateName:r}=e;e.evaluated=t.const("evaluated",(0,Sr._)`${r}.evaluated`);t.if((0,Sr._)`${e.evaluated}.dynamicProps`,()=>t.assign((0,Sr._)`${e.evaluated}.props`,(0,Sr._)`undefined`));t.if((0,Sr._)`${e.evaluated}.dynamicItems`,()=>t.assign((0,Sr._)`${e.evaluated}.items`,(0,Sr._)`undefined`))}a(ohn,"resetEvaluated");function nEt(e,t){const r=typeof e=="object"&&e[t.schemaId];return r&&(t.code.source||t.code.process)?(0,Sr._)`/*# sourceURL=${r} */`:Sr.nil}a(nEt,"funcSourceUrl");function uhn(e,t){if(lEt(e)){cEt(e);if(uEt(e)){lhn(e,t);return}}(0,aEt.boolOrEmptySchema)(e,t)}a(uhn,"subschemaCode");function uEt({schema:e,self:t}){if(typeof e=="boolean")return!e;for(const r in e)if(t.RULES.all[r])return true;return false}a(uEt,"schemaCxtHasRules");function lEt(e){return typeof e.schema!="boolean"}a(lEt,"isSchemaObj");function lhn(e,t){const{schema:r,gen:n,opts:i}=e;if(i.$comment&&r.$comment)pEt(e);phn(e);fhn(e);const s=n.const("_errs",tn.default.errors);dEt(e,s);n.var(t,(0,Sr._)`${s} === ${tn.default.errors}`)}a(lhn,"subSchemaObjCode");function cEt(e){(0,_y.checkUnknownRules)(e);chn(e)}a(cEt,"checkKeywords");function dEt(e,t){if(e.opts.jtd)return iEt(e,[],false,t);const r=(0,rEt.getSchemaTypes)(e.schema);const n=(0,rEt.coerceAndCheckDataType)(e,r);iEt(e,r,!n,t)}a(dEt,"typeAndKeywords");function chn(e){const{schema:t,errSchemaPath:r,opts:n,self:i}=e;if(t.$ref&&n.ignoreKeywordsWithRef&&(0,_y.schemaHasRulesButRef)(t,i.RULES)){i.logger.warn(`$ref: keywords ignored in schema at path "${r}"`)}}a(chn,"checkRefsAndKeywords");function dhn(e){const{schema:t,opts:r}=e;if(t.default!==void 0&&r.useDefaults&&r.strictSchema){(0,_y.checkStrictMode)(e,"default is ignored in the schema root")}}a(dhn,"checkNoDefault");function phn(e){const t=e.schema[e.opts.schemaId];if(t)e.baseId=(0,rhn.resolveUrl)(e.opts.uriResolver,e.baseId,t)}a(phn,"updateContext");function fhn(e){if(e.schema.$async&&!e.schemaEnv.$async)throw new Error("async schema in sync schema")}a(fhn,"checkAsyncSchema");function pEt({gen:e,schemaEnv:t,schema:r,errSchemaPath:n,opts:i}){const s=r.$comment;if(i.$comment===true){e.code((0,Sr._)`${tn.default.self}.logger.log(${s})`)}else if(typeof i.$comment=="function"){const o=(0,Sr.str)`${n}/$comment`;const u=e.scopeValue("root",{ref:t.root});e.code((0,Sr._)`${tn.default.self}.opts.$comment(${s}, ${o}, ${u}.schema)`)}}a(pEt,"commentKeyword");function mhn(e){const{gen:t,schemaEnv:r,validateName:n,ValidationError:i,opts:s}=e;if(r.$async){t.if((0,Sr._)`${tn.default.errors} === 0`,()=>t.return(tn.default.data),()=>t.throw((0,Sr._)`new ${i}(${tn.default.vErrors})`))}else{t.assign((0,Sr._)`${n}.errors`,tn.default.vErrors);if(s.unevaluated)hhn(e);t.return((0,Sr._)`${tn.default.errors} === 0`)}}a(mhn,"returnResults");function hhn({gen:e,evaluated:t,props:r,items:n}){if(r instanceof Sr.Name)e.assign((0,Sr._)`${t}.props`,r);if(n instanceof Sr.Name)e.assign((0,Sr._)`${t}.items`,n)}a(hhn,"assignEvaluated");function iEt(e,t,r,n){const{gen:i,schema:s,data:o,allErrors:u,opts:l,self:c}=e;const{RULES:d}=c;if(s.$ref&&(l.ignoreKeywordsWithRef||!(0,_y.schemaHasRulesButRef)(s,d))){i.block(()=>mEt(e,"$ref",d.all.$ref.definition));return}if(!l.jtd)ghn(e,t);i.block(()=>{for(const f of d.rules)p(f);p(d.post)});function p(f){if(!(0,MAe.shouldUseGroup)(s,f))return;if(f.type){i.if((0,CY.checkDataType)(f.type,o,l.strictNumbers));sEt(e,f);if(t.length===1&&t[0]===f.type&&r){i.else();(0,CY.reportTypeError)(e)}i.endIf()}else{sEt(e,f)}if(!u)i.if((0,Sr._)`${tn.default.errors} === ${n||0}`)}a(p,"groupKeywords")}a(iEt,"schemaKeywords");function sEt(e,t){const{gen:r,schema:n,opts:{useDefaults:i}}=e;if(i)(0,thn.assignDefaults)(e,t.type);r.block(()=>{for(const s of t.rules){if((0,MAe.shouldUseRule)(n,s)){mEt(e,s.keyword,s.definition,t.type)}}})}a(sEt,"iterateKeywords");function ghn(e,t){if(e.schemaEnv.meta||!e.opts.strictTypes)return;yhn(e,t);if(!e.opts.allowUnionTypes)_hn(e,t);vhn(e,e.dataTypes)}a(ghn,"checkStrictTypes");function yhn(e,t){if(!t.length)return;if(!e.dataTypes.length){e.dataTypes=t;return}t.forEach(r=>{if(!fEt(e.dataTypes,r)){qAe(e,`type "${r}" not allowed by context "${e.dataTypes.join(",")}"`)}});bhn(e,t)}a(yhn,"checkContextTypes");function _hn(e,t){if(t.length>1&&!(t.length===2&&t.includes("null"))){qAe(e,"use allowUnionTypes to allow union type keyword")}}a(_hn,"checkMultipleTypes");function vhn(e,t){const r=e.self.RULES.all;for(const n in r){const i=r[n];if(typeof i=="object"&&(0,MAe.shouldUseRule)(e.schema,i)){const{type:s}=i.definition;if(s.length&&!s.some(o=>Ehn(t,o))){qAe(e,`missing type "${s.join(",")}" for keyword "${n}"`)}}}}a(vhn,"checkKeywordTypes");function Ehn(e,t){return e.includes(t)||t==="number"&&e.includes("integer")}a(Ehn,"hasApplicableType");function fEt(e,t){return e.includes(t)||t==="integer"&&e.includes("number")}a(fEt,"includesType");function bhn(e,t){const r=[];for(const n of e.dataTypes){if(fEt(t,n))r.push(n);else if(t.includes("integer")&&n==="number")r.push("integer")}e.dataTypes=r}a(bhn,"narrowSchemaTypes");function qAe(e,t){const r=e.schemaEnv.baseId+e.errSchemaPath;t+=` at "${r}" (strictTypes)`;(0,_y.checkStrictMode)(e,t,e.opts.strictTypes)}a(qAe,"strictTypesError");var wY=class{static{a(this,"KeywordCxt")}constructor(t,r,n){(0,qL.validateKeywordUsage)(t,r,n);this.gen=t.gen;this.allErrors=t.allErrors;this.keyword=n;this.data=t.data;this.schema=t.schema[n];this.$data=r.$data&&t.opts.$data&&this.schema&&this.schema.$data;this.schemaValue=(0,_y.schemaRefOrVal)(t,this.schema,n,this.$data);this.schemaType=r.schemaType;this.parentSchema=t.schema;this.params={};this.it=t;this.def=r;if(this.$data){this.schemaCode=t.gen.const("vSchema",hEt(this.$data,t))}else{this.schemaCode=this.schemaValue;if(!(0,qL.validSchemaType)(this.schema,r.schemaType,r.allowUndefined)){throw new Error(`${n} value must be ${JSON.stringify(r.schemaType)}`)}}if("code"in r?r.trackErrors:r.errors!==false){this.errsCount=t.gen.const("_errs",tn.default.errors)}}result(t,r,n){this.failResult((0,Sr.not)(t),r,n)}failResult(t,r,n){this.gen.if(t);if(n)n();else this.error();if(r){this.gen.else();r();if(this.allErrors)this.gen.endIf()}else{if(this.allErrors)this.gen.endIf();else this.gen.else()}}pass(t,r){this.failResult((0,Sr.not)(t),void 0,r)}fail(t){if(t===void 0){this.error();if(!this.allErrors)this.gen.if(false);return}this.gen.if(t);this.error();if(this.allErrors)this.gen.endIf();else this.gen.else()}fail$data(t){if(!this.$data)return this.fail(t);const{schemaCode:r}=this;this.fail((0,Sr._)`${r} !== undefined && (${(0,Sr.or)(this.invalid$data(),t)})`)}error(t,r,n){if(r){this.setParams(r);this._error(t,n);this.setParams({});return}this._error(t,n)}_error(t,r){;(t?ML.reportExtraError:ML.reportError)(this,this.def.error,r)}$dataError(){(0,ML.reportError)(this,this.def.$dataError||ML.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,ML.resetErrorsCount)(this.gen,this.errsCount)}ok(t){if(!this.allErrors)this.gen.if(t)}setParams(t,r){if(r)Object.assign(this.params,t);else this.params=t}block$data(t,r,n=Sr.nil){this.gen.block(()=>{this.check$data(t,n);r()})}check$data(t=Sr.nil,r=Sr.nil){if(!this.$data)return;const{gen:n,schemaCode:i,schemaType:s,def:o}=this;n.if((0,Sr.or)((0,Sr._)`${i} === undefined`,r));if(t!==Sr.nil)n.assign(t,true);if(s.length||o.validateSchema){n.elseIf(this.invalid$data());this.$dataError();if(t!==Sr.nil)n.assign(t,false)}n.else()}invalid$data(){const{gen:t,schemaCode:r,schemaType:n,def:i,it:s}=this;return(0,Sr.or)(o(),u());function o(){if(n.length){if(!(r instanceof Sr.Name))throw new Error("ajv implementation error");const l=Array.isArray(n)?n:[n];return(0,Sr._)`${(0,CY.checkDataTypes)(l,r,s.opts.strictNumbers,CY.DataType.Wrong)}`}return Sr.nil}a(o,"wrong$DataType");function u(){if(i.validateSchema){const l=t.scopeValue("validate$data",{ref:i.validateSchema});return(0,Sr._)`!${l}(${r})`}return Sr.nil}a(u,"invalid$DataSchema")}subschema(t,r){const n=(0,BAe.getSubschema)(this.it,t);(0,BAe.extendSubschemaData)(n,this.it,t);(0,BAe.extendSubschemaMode)(n,t);const i={...this.it,...n,items:void 0,props:void 0};uhn(i,r);return i}mergeEvaluated(t,r){const{it:n,gen:i}=this;if(!n.opts.unevaluated)return;if(n.props!==true&&t.props!==void 0){n.props=_y.mergeEvaluated.props(i,t.props,n.props,r)}if(n.items!==true&&t.items!==void 0){n.items=_y.mergeEvaluated.items(i,t.items,n.items,r)}}mergeValidEvaluated(t,r){const{it:n,gen:i}=this;if(n.opts.unevaluated&&(n.props!==true||n.items!==true)){i.if(r,()=>this.mergeEvaluated(t,Sr.Name));return true}}};vE.KeywordCxt=wY;function mEt(e,t,r,n){const i=new wY(e,r,t);if("code"in r){r.code(i,n)}else if(i.$data&&r.validate){(0,qL.funcKeywordCode)(i,r)}else if("macro"in r){(0,qL.macroKeywordCode)(i,r)}else if(r.compile||r.validate){(0,qL.funcKeywordCode)(i,r)}}a(mEt,"keywordCode");var Shn=/^\/(?:[^~]|~0|~1)*$/;var Ahn=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function hEt(e,{dataLevel:t,dataNames:r,dataPathArr:n}){let i;let s;if(e==="")return tn.default.rootData;if(e[0]==="/"){if(!Shn.test(e))throw new Error(`Invalid JSON-pointer: ${e}`);i=e;s=tn.default.rootData}else{const c=Ahn.exec(e);if(!c)throw new Error(`Invalid JSON-pointer: ${e}`);const d=+c[1];i=c[2];if(i==="#"){if(d>=t)throw new Error(l("property/index",d));return n[t-d]}if(d>t)throw new Error(l("data",d));s=r[t-d];if(!i)return s}let o=s;const u=i.split("/");for(const c of u){if(c){s=(0,Sr._)`${s}${(0,Sr.getProperty)((0,_y.unescapeJsonPointer)(c))}`;o=(0,Sr._)`${o} && ${s}`}}return o;function l(c,d){return`Cannot access ${c} ${d} levels up, current level is ${t}`}a(l,"errorMsg")}a(hEt,"getData");vE.getData=hEt});var TY=y($Ae=>{"use strict";Object.defineProperty($Ae,"__esModule",{value:true});var UAe=class extends Error{static{a(this,"ValidationError")}constructor(t){super("validation failed");this.errors=t;this.ajv=this.validation=true}};$Ae.default=UAe});var xY=y(HAe=>{"use strict";Object.defineProperty(HAe,"__esModule",{value:true});var jAe=BL();var GAe=class extends Error{static{a(this,"MissingRefError")}constructor(t,r,n,i){super(i||`can't resolve reference ${n} from id ${r}`);this.missingRef=(0,jAe.resolveUrl)(t,r,n);this.missingSchema=(0,jAe.normalizeId)((0,jAe.getFullPath)(t,this.missingRef))}};HAe.default=GAe});var $L=y(wf=>{"use strict";Object.defineProperty(wf,"__esModule",{value:true});wf.resolveSchema=wf.getCompilingSchema=wf.resolveRef=wf.compileSchema=wf.SchemaEnv=void 0;var ih=En();var Chn=TY();var qA=Af();var sh=BL();var gEt=ui();var whn=UL();var gO=class{static{a(this,"SchemaEnv")}constructor(t){var r;this.refs={};this.dynamicAnchors={};let n;if(typeof t.schema=="object")n=t.schema;this.schema=t.schema;this.schemaId=t.schemaId;this.root=t.root||this;this.baseId=(r=t.baseId)!==null&&r!==void 0?r:(0,sh.normalizeId)(n===null||n===void 0?void 0:n[t.schemaId||"$id"]);this.schemaPath=t.schemaPath;this.localRefs=t.localRefs;this.meta=t.meta;this.$async=n===null||n===void 0?void 0:n.$async;this.refs={}}};wf.SchemaEnv=gO;function zAe(e){const t=yEt.call(this,e);if(t)return t;const r=(0,sh.getFullPath)(this.opts.uriResolver,e.root.baseId);const{es5:n,lines:i}=this.opts.code;const{ownProperties:s}=this.opts;const o=new ih.CodeGen(this.scope,{es5:n,lines:i,ownProperties:s});let u;if(e.$async){u=o.scopeValue("Error",{ref:Chn.default,code:(0,ih._)`require("ajv/dist/runtime/validation_error").default`})}const l=o.scopeName("validate");e.validateName=l;const c={gen:o,allErrors:this.opts.allErrors,data:qA.default.data,parentData:qA.default.parentData,parentDataProperty:qA.default.parentDataProperty,dataNames:[qA.default.data],dataPathArr:[ih.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:o.scopeValue("schema",this.opts.code.source===true?{ref:e.schema,code:(0,ih.stringify)(e.schema)}:{ref:e.schema}),validateName:l,ValidationError:u,schema:e.schema,schemaEnv:e,rootId:r,baseId:e.baseId||r,schemaPath:ih.nil,errSchemaPath:e.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,ih._)`""`,opts:this.opts,self:this};let d;try{this._compilations.add(e);(0,whn.validateFunctionCode)(c);o.optimize(this.opts.code.optimize);const p=o.toString();d=`${o.scopeRefs(qA.default.scope)}return ${p}`;if(this.opts.code.process)d=this.opts.code.process(d,e);const f=new Function(`${qA.default.self}`,`${qA.default.scope}`,d);const m=f(this,this.scope.get());this.scope.value(l,{ref:m});m.errors=null;m.schema=e.schema;m.schemaEnv=e;if(e.$async)m.$async=true;if(this.opts.code.source===true){m.source={validateName:l,validateCode:p,scopeValues:o._values}}if(this.opts.unevaluated){const{props:h,items:g}=c;m.evaluated={props:h instanceof ih.Name?void 0:h,items:g instanceof ih.Name?void 0:g,dynamicProps:h instanceof ih.Name,dynamicItems:g instanceof ih.Name};if(m.source)m.source.evaluated=(0,ih.stringify)(m.evaluated)}e.validate=m;return e}catch(p){delete e.validate;delete e.validateName;if(d)this.logger.error("Error compiling schema, function code:",d);throw p}finally{this._compilations.delete(e)}}a(zAe,"compileSchema");wf.compileSchema=zAe;function Thn(e,t,r){var n;r=(0,sh.resolveUrl)(this.opts.uriResolver,t,r);const i=e.refs[r];if(i)return i;let s=Ohn.call(this,e,r);if(s===void 0){const o=(n=e.localRefs)===null||n===void 0?void 0:n[r];const{schemaId:u}=this.opts;if(o)s=new gO({schema:o,schemaId:u,root:e,baseId:t})}if(s===void 0)return;return e.refs[r]=xhn.call(this,s)}a(Thn,"resolveRef");wf.resolveRef=Thn;function xhn(e){if((0,sh.inlineRef)(e.schema,this.opts.inlineRefs))return e.schema;return e.validate?e:zAe.call(this,e)}a(xhn,"inlineOrCompile");function yEt(e){for(const t of this._compilations){if(Rhn(t,e))return t}}a(yEt,"getCompilingSchema");wf.getCompilingSchema=yEt;function Rhn(e,t){return e.schema===t.schema&&e.root===t.root&&e.baseId===t.baseId}a(Rhn,"sameSchemaEnv");function Ohn(e,t){let r;while(typeof(r=this.refs[t])=="string")t=r;return r||this.schemas[t]||RY.call(this,e,t)}a(Ohn,"resolve");function RY(e,t){const r=this.opts.uriResolver.parse(t);const n=(0,sh._getFullPath)(this.opts.uriResolver,r);let i=(0,sh.getFullPath)(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&n===i){return VAe.call(this,r,e)}const s=(0,sh.normalizeId)(n);const o=this.refs[s]||this.schemas[s];if(typeof o=="string"){const u=RY.call(this,e,o);if(typeof(u===null||u===void 0?void 0:u.schema)!=="object")return;return VAe.call(this,r,u)}if(typeof(o===null||o===void 0?void 0:o.schema)!=="object")return;if(!o.validate)zAe.call(this,o);if(s===(0,sh.normalizeId)(t)){const{schema:u}=o;const{schemaId:l}=this.opts;const c=u[l];if(c)i=(0,sh.resolveUrl)(this.opts.uriResolver,i,c);return new gO({schema:u,schemaId:l,root:e,baseId:i})}return VAe.call(this,r,o)}a(RY,"resolveSchema");wf.resolveSchema=RY;var Phn=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function VAe(e,{baseId:t,schema:r,root:n}){var i;if(((i=e.fragment)===null||i===void 0?void 0:i[0])!=="/")return;for(const u of e.fragment.slice(1).split("/")){if(typeof r==="boolean")return;const l=r[(0,gEt.unescapeFragment)(u)];if(l===void 0)return;r=l;const c=typeof r==="object"&&r[this.opts.schemaId];if(!Phn.has(u)&&c){t=(0,sh.resolveUrl)(this.opts.uriResolver,t,c)}}let s;if(typeof r!="boolean"&&r.$ref&&!(0,gEt.schemaHasRulesButRef)(r,this.RULES)){const u=(0,sh.resolveUrl)(this.opts.uriResolver,t,r.$ref);s=RY.call(this,n,u)}const{schemaId:o}=this.opts;s=s||new gO({schema:r,schemaId:o,root:n,baseId:t});if(s.schema!==s.root.schema)return s;return void 0}a(VAe,"getJsonPointer")});var _Et=y((yIs,Nhn)=>{Nhn.exports={$id:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",description:"Meta-schema for $data reference (JSON AnySchema extension proposal)",type:"object",required:["$data"],properties:{$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},additionalProperties:false}});var EEt=y(KAe=>{"use strict";Object.defineProperty(KAe,"__esModule",{value:true});var vEt=sS();vEt.code='require("ajv/dist/runtime/uri").default';KAe.default=vEt});var REt=y(rl=>{"use strict";Object.defineProperty(rl,"__esModule",{value:true});rl.CodeGen=rl.Name=rl.nil=rl.stringify=rl.str=rl._=rl.KeywordCxt=void 0;var Ihn=UL();Object.defineProperty(rl,"KeywordCxt",{enumerable:true,get:function(){return Ihn.KeywordCxt}});var yO=En();Object.defineProperty(rl,"_",{enumerable:true,get:function(){return yO._}});Object.defineProperty(rl,"str",{enumerable:true,get:function(){return yO.str}});Object.defineProperty(rl,"stringify",{enumerable:true,get:function(){return yO.stringify}});Object.defineProperty(rl,"nil",{enumerable:true,get:function(){return yO.nil}});Object.defineProperty(rl,"Name",{enumerable:true,get:function(){return yO.Name}});Object.defineProperty(rl,"CodeGen",{enumerable:true,get:function(){return yO.CodeGen}});var khn=TY();var wEt=xY();var Dhn=RAe();var jL=$L();var Lhn=En();var GL=BL();var OY=FL();var YAe=ui();var bEt=_Et();var Fhn=EEt();var TEt=a((e,t)=>new RegExp(e,t),"defaultRegExp");TEt.code="new RegExp";var Bhn=["removeAdditional","useDefaults","coerceTypes"];var Mhn=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]);var qhn={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."};var Uhn={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'};var SEt=200;function $hn(e){var t,r,n,i,s,o,u,l,c,d,p,f,m,h,g,_,v,S,E,b,A,C,T,O,P;const R=e.strict;const I=(t=e.code)===null||t===void 0?void 0:t.optimize;const D=I===true||I===void 0?1:I||0;const U=(n=(r=e.code)===null||r===void 0?void 0:r.regExp)!==null&&n!==void 0?n:TEt;const te=(i=e.uriResolver)!==null&&i!==void 0?i:Fhn.default;return{strictSchema:(o=(s=e.strictSchema)!==null&&s!==void 0?s:R)!==null&&o!==void 0?o:true,strictNumbers:(l=(u=e.strictNumbers)!==null&&u!==void 0?u:R)!==null&&l!==void 0?l:true,strictTypes:(d=(c=e.strictTypes)!==null&&c!==void 0?c:R)!==null&&d!==void 0?d:"log",strictTuples:(f=(p=e.strictTuples)!==null&&p!==void 0?p:R)!==null&&f!==void 0?f:"log",strictRequired:(h=(m=e.strictRequired)!==null&&m!==void 0?m:R)!==null&&h!==void 0?h:false,code:e.code?{...e.code,optimize:D,regExp:U}:{optimize:D,regExp:U},loopRequired:(g=e.loopRequired)!==null&&g!==void 0?g:SEt,loopEnum:(_=e.loopEnum)!==null&&_!==void 0?_:SEt,meta:(v=e.meta)!==null&&v!==void 0?v:true,messages:(S=e.messages)!==null&&S!==void 0?S:true,inlineRefs:(E=e.inlineRefs)!==null&&E!==void 0?E:true,schemaId:(b=e.schemaId)!==null&&b!==void 0?b:"$id",addUsedSchema:(A=e.addUsedSchema)!==null&&A!==void 0?A:true,validateSchema:(C=e.validateSchema)!==null&&C!==void 0?C:true,validateFormats:(T=e.validateFormats)!==null&&T!==void 0?T:true,unicodeRegExp:(O=e.unicodeRegExp)!==null&&O!==void 0?O:true,int32range:(P=e.int32range)!==null&&P!==void 0?P:true,uriResolver:te}}a($hn,"requiredOptions");var HL=class{static{a(this,"Ajv")}constructor(t={}){this.schemas={};this.refs={};this.formats={};this._compilations=new Set;this._loading={};this._cache=new Map;t=this.opts={...t,...$hn(t)};const{es5:r,lines:n}=this.opts.code;this.scope=new Lhn.ValueScope({scope:{},prefixes:Mhn,es5:r,lines:n});this.logger=Khn(t.logger);const i=t.validateFormats;t.validateFormats=false;this.RULES=(0,Dhn.getRules)();AEt.call(this,qhn,t,"NOT SUPPORTED");AEt.call(this,Uhn,t,"DEPRECATED","warn");this._metaOpts=Vhn.call(this);if(t.formats)Ghn.call(this);this._addVocabularies();this._addDefaultMetaSchema();if(t.keywords)Hhn.call(this,t.keywords);if(typeof t.meta=="object")this.addMetaSchema(t.meta);jhn.call(this);t.validateFormats=i}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){const{$data:t,meta:r,schemaId:n}=this.opts;let i=bEt;if(n==="id"){i={...bEt};i.id=i.$id;delete i.$id}if(r&&t)this.addMetaSchema(i,i[n],false)}defaultMeta(){const{meta:t,schemaId:r}=this.opts;return this.opts.defaultMeta=typeof t=="object"?t[r]||t:void 0}validate(t,r){let n;if(typeof t=="string"){n=this.getSchema(t);if(!n)throw new Error(`no schema with key or ref "${t}"`)}else{n=this.compile(t)}const i=n(r);if(!("$async"in n))this.errors=n.errors;return i}compile(t,r){const n=this._addSchema(t,r);return n.validate||this._compileSchemaEnv(n)}compileAsync(t,r){if(typeof this.opts.loadSchema!="function"){throw new Error("options.loadSchema should be a function")}const{loadSchema:n}=this.opts;return i.call(this,t,r);async function i(d,p){await s.call(this,d.$schema);const f=this._addSchema(d,p);return f.validate||o.call(this,f)}a(i,"runCompileAsync");async function s(d){if(d&&!this.getSchema(d)){await i.call(this,{$ref:d},true)}}a(s,"loadMetaSchema");async function o(d){try{return this._compileSchemaEnv(d)}catch(p){if(!(p instanceof wEt.default))throw p;u.call(this,p);await l.call(this,p.missingSchema);return o.call(this,d)}}a(o,"_compileAsync");function u({missingSchema:d,missingRef:p}){if(this.refs[d]){throw new Error(`AnySchema ${d} is loaded but ${p} cannot be resolved`)}}a(u,"checkLoaded");async function l(d){const p=await c.call(this,d);if(!this.refs[d])await s.call(this,p.$schema);if(!this.refs[d])this.addSchema(p,d,r)}a(l,"loadMissingSchema");async function c(d){const p=this._loading[d];if(p)return p;try{return await(this._loading[d]=n(d))}finally{delete this._loading[d]}}a(c,"_loadSchema")}addSchema(t,r,n,i=this.opts.validateSchema){if(Array.isArray(t)){for(const o of t)this.addSchema(o,void 0,n,i);return this}let s;if(typeof t==="object"){const{schemaId:o}=this.opts;s=t[o];if(s!==void 0&&typeof s!="string"){throw new Error(`schema ${o} must be string`)}}r=(0,GL.normalizeId)(r||s);this._checkUnique(r);this.schemas[r]=this._addSchema(t,n,r,i,true);return this}addMetaSchema(t,r,n=this.opts.validateSchema){this.addSchema(t,r,true,n);return this}validateSchema(t,r){if(typeof t=="boolean")return true;let n;n=t.$schema;if(n!==void 0&&typeof n!="string"){throw new Error("$schema must be a string")}n=n||this.opts.defaultMeta||this.defaultMeta();if(!n){this.logger.warn("meta-schema not available");this.errors=null;return true}const i=this.validate(n,t);if(!i&&r){const s="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(s);else throw new Error(s)}return i}getSchema(t){let r;while(typeof(r=CEt.call(this,t))=="string")t=r;if(r===void 0){const{schemaId:n}=this.opts;const i=new jL.SchemaEnv({schema:{},schemaId:n});r=jL.resolveSchema.call(this,i,t);if(!r)return;this.refs[t]=r}return r.validate||this._compileSchemaEnv(r)}removeSchema(t){if(t instanceof RegExp){this._removeAllSchemas(this.schemas,t);this._removeAllSchemas(this.refs,t);return this}switch(typeof t){case"undefined":this._removeAllSchemas(this.schemas);this._removeAllSchemas(this.refs);this._cache.clear();return this;case"string":{const r=CEt.call(this,t);if(typeof r=="object")this._cache.delete(r.schema);delete this.schemas[t];delete this.refs[t];return this}case"object":{const r=t;this._cache.delete(r);let n=t[this.opts.schemaId];if(n){n=(0,GL.normalizeId)(n);delete this.schemas[n];delete this.refs[n]}return this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(t){for(const r of t)this.addKeyword(r);return this}addKeyword(t,r){let n;if(typeof t=="string"){n=t;if(typeof r=="object"){this.logger.warn("these parameters are deprecated, see docs for addKeyword");r.keyword=n}}else if(typeof t=="object"&&r===void 0){r=t;n=r.keyword;if(Array.isArray(n)&&!n.length){throw new Error("addKeywords: keyword must be string or non-empty array")}}else{throw new Error("invalid addKeywords parameters")}Yhn.call(this,n,r);if(!r){(0,YAe.eachItem)(n,s=>WAe.call(this,s));return this}Jhn.call(this,r);const i={...r,type:(0,OY.getJSONTypes)(r.type),schemaType:(0,OY.getJSONTypes)(r.schemaType)};(0,YAe.eachItem)(n,i.type.length===0?s=>WAe.call(this,s,i):s=>i.type.forEach(o=>WAe.call(this,s,i,o)));return this}getKeyword(t){const r=this.RULES.all[t];return typeof r=="object"?r.definition:!!r}removeKeyword(t){const{RULES:r}=this;delete r.keywords[t];delete r.all[t];for(const n of r.rules){const i=n.rules.findIndex(s=>s.keyword===t);if(i>=0)n.rules.splice(i,1)}return this}addFormat(t,r){if(typeof r=="string")r=new RegExp(r);this.formats[t]=r;return this}errorsText(t=this.errors,{separator:r=", ",dataVar:n="data"}={}){if(!t||t.length===0)return"No errors";return t.map(i=>`${n}${i.instancePath} ${i.message}`).reduce((i,s)=>i+r+s)}$dataMetaSchema(t,r){const n=this.RULES.all;t=JSON.parse(JSON.stringify(t));for(const i of r){const s=i.split("/").slice(1);let o=t;for(const u of s)o=o[u];for(const u in n){const l=n[u];if(typeof l!="object")continue;const{$data:c}=l.definition;const d=o[u];if(c&&d)o[u]=xEt(d)}}return t}_removeAllSchemas(t,r){for(const n in t){const i=t[n];if(!r||r.test(n)){if(typeof i=="string"){delete t[n]}else if(i&&!i.meta){this._cache.delete(i.schema);delete t[n]}}}}_addSchema(t,r,n,i=this.opts.validateSchema,s=this.opts.addUsedSchema){let o;const{schemaId:u}=this.opts;if(typeof t=="object"){o=t[u]}else{if(this.opts.jtd)throw new Error("schema must be object");else if(typeof t!="boolean")throw new Error("schema must be object or boolean")}let l=this._cache.get(t);if(l!==void 0)return l;n=(0,GL.normalizeId)(o||n);const c=GL.getSchemaRefs.call(this,t,n);l=new jL.SchemaEnv({schema:t,schemaId:u,meta:r,baseId:n,localRefs:c});this._cache.set(l.schema,l);if(s&&!n.startsWith("#")){if(n)this._checkUnique(n);this.refs[n]=l}if(i)this.validateSchema(t,true);return l}_checkUnique(t){if(this.schemas[t]||this.refs[t]){throw new Error(`schema with key or id "${t}" already exists`)}}_compileSchemaEnv(t){if(t.meta)this._compileMetaSchema(t);else jL.compileSchema.call(this,t);if(!t.validate)throw new Error("ajv implementation error");return t.validate}_compileMetaSchema(t){const r=this.opts;this.opts=this._metaOpts;try{jL.compileSchema.call(this,t)}finally{this.opts=r}}};rl.default=HL;HL.ValidationError=khn.default;HL.MissingRefError=wEt.default;function AEt(e,t,r,n="error"){for(const i in e){const s=i;if(s in t)this.logger[n](`${r}: option ${i}. ${e[s]}`)}}a(AEt,"checkOptions");function CEt(e){e=(0,GL.normalizeId)(e);return this.schemas[e]||this.refs[e]}a(CEt,"getSchEnv");function jhn(){const e=this.opts.schemas;if(!e)return;if(Array.isArray(e))this.addSchema(e);else for(const t in e)this.addSchema(e[t],t)}a(jhn,"addInitialSchemas");function Ghn(){for(const e in this.opts.formats){const t=this.opts.formats[e];if(t)this.addFormat(e,t)}}a(Ghn,"addInitialFormats");function Hhn(e){if(Array.isArray(e)){this.addVocabulary(e);return}this.logger.warn("keywords option as map is deprecated, pass array");for(const t in e){const r=e[t];if(!r.keyword)r.keyword=t;this.addKeyword(r)}}a(Hhn,"addInitialKeywords");function Vhn(){const e={...this.opts};for(const t of Bhn)delete e[t];return e}a(Vhn,"getMetaSchemaOptions");var zhn={log(){},warn(){},error(){}};function Khn(e){if(e===false)return zhn;if(e===void 0)return console;if(e.log&&e.warn&&e.error)return e;throw new Error("logger must implement log, warn and error methods")}a(Khn,"getLogger");var Whn=/^[a-z_$][a-z0-9_$:-]*$/i;function Yhn(e,t){const{RULES:r}=this;(0,YAe.eachItem)(e,n=>{if(r.keywords[n])throw new Error(`Keyword ${n} is already defined`);if(!Whn.test(n))throw new Error(`Keyword ${n} has invalid name`)});if(!t)return;if(t.$data&&!("code"in t||"validate"in t)){throw new Error('$data keyword must have "code" or "validate" function')}}a(Yhn,"checkKeyword");function WAe(e,t,r){var n;const i=t===null||t===void 0?void 0:t.post;if(r&&i)throw new Error('keyword with "post" flag cannot have "type"');const{RULES:s}=this;let o=i?s.post:s.rules.find(({type:l})=>l===r);if(!o){o={type:r,rules:[]};s.rules.push(o)}s.keywords[e]=true;if(!t)return;const u={keyword:e,definition:{...t,type:(0,OY.getJSONTypes)(t.type),schemaType:(0,OY.getJSONTypes)(t.schemaType)}};if(t.before)Xhn.call(this,o,u,t.before);else o.rules.push(u);s.all[e]=u;(n=t.implements)===null||n===void 0?void 0:n.forEach(l=>this.addKeyword(l))}a(WAe,"addRule");function Xhn(e,t,r){const n=e.rules.findIndex(i=>i.keyword===r);if(n>=0){e.rules.splice(n,0,t)}else{e.rules.push(t);this.logger.warn(`rule ${r} is not defined`)}}a(Xhn,"addBeforeRule");function Jhn(e){let{metaSchema:t}=e;if(t===void 0)return;if(e.$data&&this.opts.$data)t=xEt(t);e.validateSchema=this.compile(t,true)}a(Jhn,"keywordMetaschema");var Qhn={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function xEt(e){return{anyOf:[e,Qhn]}}a(xEt,"schemaOrData")});var OEt=y(XAe=>{"use strict";Object.defineProperty(XAe,"__esModule",{value:true});var Zhn={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};XAe.default=Zhn});var IY=y(UA=>{"use strict";Object.defineProperty(UA,"__esModule",{value:true});UA.callRef=UA.getValidate=void 0;var e0n=xY();var PEt=Cf();var md=En();var _O=Af();var NEt=$L();var PY=ui();var t0n={keyword:"$ref",schemaType:"string",code(e){const{gen:t,schema:r,it:n}=e;const{baseId:i,schemaEnv:s,validateName:o,opts:u,self:l}=n;const{root:c}=s;if((r==="#"||r==="#/")&&i===c.baseId)return p();const d=NEt.resolveRef.call(l,c,i,r);if(d===void 0)throw new e0n.default(n.opts.uriResolver,i,r);if(d instanceof NEt.SchemaEnv)return f(d);return m(d);function p(){if(s===c)return NY(e,o,s,s.$async);const h=t.scopeValue("root",{ref:c});return NY(e,(0,md._)`${h}.validate`,c,c.$async)}a(p,"callRootRef");function f(h){const g=IEt(e,h);NY(e,g,h,h.$async)}a(f,"callValidate");function m(h){const g=t.scopeValue("schema",u.code.source===true?{ref:h,code:(0,md.stringify)(h)}:{ref:h});const _=t.name("valid");const v=e.subschema({schema:h,dataTypes:[],schemaPath:md.nil,topSchemaRef:g,errSchemaPath:r},_);e.mergeEvaluated(v);e.ok(_)}a(m,"inlineRefSchema")}};function IEt(e,t){const{gen:r}=e;return t.validate?r.scopeValue("validate",{ref:t.validate}):(0,md._)`${r.scopeValue("wrapper",{ref:t})}.validate`}a(IEt,"getValidate");UA.getValidate=IEt;function NY(e,t,r,n){const{gen:i,it:s}=e;const{allErrors:o,schemaEnv:u,opts:l}=s;const c=l.passContext?_O.default.this:md.nil;if(n)d();else p();function d(){if(!u.$async)throw new Error("async schema referenced by sync schema");const h=i.let("valid");i.try(()=>{i.code((0,md._)`await ${(0,PEt.callValidateCode)(e,t,c)}`);m(t);if(!o)i.assign(h,true)},g=>{i.if((0,md._)`!(${g} instanceof ${s.ValidationError})`,()=>i.throw(g));f(g);if(!o)i.assign(h,false)});e.ok(h)}a(d,"callAsyncRef");function p(){e.result((0,PEt.callValidateCode)(e,t,c),()=>m(t),()=>f(t))}a(p,"callSyncRef");function f(h){const g=(0,md._)`${h}.errors`;i.assign(_O.default.vErrors,(0,md._)`${_O.default.vErrors} === null ? ${g} : ${_O.default.vErrors}.concat(${g})`);i.assign(_O.default.errors,(0,md._)`${_O.default.vErrors}.length`)}a(f,"addErrorsFrom");function m(h){var g;if(!s.opts.unevaluated)return;const _=(g=r===null||r===void 0?void 0:r.validate)===null||g===void 0?void 0:g.evaluated;if(s.props!==true){if(_&&!_.dynamicProps){if(_.props!==void 0){s.props=PY.mergeEvaluated.props(i,_.props,s.props)}}else{const v=i.var("props",(0,md._)`${h}.evaluated.props`);s.props=PY.mergeEvaluated.props(i,v,s.props,md.Name)}}if(s.items!==true){if(_&&!_.dynamicItems){if(_.items!==void 0){s.items=PY.mergeEvaluated.items(i,_.items,s.items)}}else{const v=i.var("items",(0,md._)`${h}.evaluated.items`);s.items=PY.mergeEvaluated.items(i,v,s.items,md.Name)}}}a(m,"addEvaluatedFrom")}a(NY,"callRef");UA.callRef=NY;UA.default=t0n});var kEt=y(JAe=>{"use strict";Object.defineProperty(JAe,"__esModule",{value:true});var r0n=OEt();var n0n=IY();var i0n=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",r0n.default,n0n.default];JAe.default=i0n});var DEt=y(QAe=>{"use strict";Object.defineProperty(QAe,"__esModule",{value:true});var kY=En();var EE=kY.operators;var DY={maximum:{okStr:"<=",ok:EE.LTE,fail:EE.GT},minimum:{okStr:">=",ok:EE.GTE,fail:EE.LT},exclusiveMaximum:{okStr:"<",ok:EE.LT,fail:EE.GTE},exclusiveMinimum:{okStr:">",ok:EE.GT,fail:EE.LTE}};var s0n={message:({keyword:e,schemaCode:t})=>(0,kY.str)`must be ${DY[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>(0,kY._)`{comparison: ${DY[e].okStr}, limit: ${t}}`};var a0n={keyword:Object.keys(DY),type:"number",schemaType:"number",$data:true,error:s0n,code(e){const{keyword:t,data:r,schemaCode:n}=e;e.fail$data((0,kY._)`${r} ${DY[t].fail} ${n} || isNaN(${r})`)}};QAe.default=a0n});var LEt=y(ZAe=>{"use strict";Object.defineProperty(ZAe,"__esModule",{value:true});var VL=En();var o0n={message:({schemaCode:e})=>(0,VL.str)`must be multiple of ${e}`,params:({schemaCode:e})=>(0,VL._)`{multipleOf: ${e}}`};var u0n={keyword:"multipleOf",type:"number",schemaType:"number",$data:true,error:o0n,code(e){const{gen:t,data:r,schemaCode:n,it:i}=e;const s=i.opts.multipleOfPrecision;const o=t.let("res");const u=s?(0,VL._)`Math.abs(Math.round(${o}) - ${o}) > 1e-${s}`:(0,VL._)`${o} !== parseInt(${o})`;e.fail$data((0,VL._)`(${n} === 0 || (${o} = ${r}/${n}, ${u}))`)}};ZAe.default=u0n});var BEt=y(eCe=>{"use strict";Object.defineProperty(eCe,"__esModule",{value:true});function FEt(e){const t=e.length;let r=0;let n=0;let i;while(n<t){r++;i=e.charCodeAt(n++);if(i>=55296&&i<=56319&&n<t){i=e.charCodeAt(n);if((i&64512)===56320)n++}}return r}a(FEt,"ucs2length");eCe.default=FEt;FEt.code='require("ajv/dist/runtime/ucs2length").default'});var MEt=y(tCe=>{"use strict";Object.defineProperty(tCe,"__esModule",{value:true});var $A=En();var l0n=ui();var c0n=BEt();var d0n={message({keyword:e,schemaCode:t}){const r=e==="maxLength"?"more":"fewer";return(0,$A.str)`must NOT have ${r} than ${t} characters`},params:({schemaCode:e})=>(0,$A._)`{limit: ${e}}`};var p0n={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:true,error:d0n,code(e){const{keyword:t,data:r,schemaCode:n,it:i}=e;const s=t==="maxLength"?$A.operators.GT:$A.operators.LT;const o=i.opts.unicode===false?(0,$A._)`${r}.length`:(0,$A._)`${(0,l0n.useFunc)(e.gen,c0n.default)}(${r})`;e.fail$data((0,$A._)`${o} ${s} ${n}`)}};tCe.default=p0n});var qEt=y(rCe=>{"use strict";Object.defineProperty(rCe,"__esModule",{value:true});var f0n=Cf();var LY=En();var m0n={message:({schemaCode:e})=>(0,LY.str)`must match pattern "${e}"`,params:({schemaCode:e})=>(0,LY._)`{pattern: ${e}}`};var h0n={keyword:"pattern",type:"string",schemaType:"string",$data:true,error:m0n,code(e){const{data:t,$data:r,schema:n,schemaCode:i,it:s}=e;const o=s.opts.unicodeRegExp?"u":"";const u=r?(0,LY._)`(new RegExp(${i}, ${o}))`:(0,f0n.usePattern)(e,n);e.fail$data((0,LY._)`!${u}.test(${t})`)}};rCe.default=h0n});var UEt=y(nCe=>{"use strict";Object.defineProperty(nCe,"__esModule",{value:true});var zL=En();var g0n={message({keyword:e,schemaCode:t}){const r=e==="maxProperties"?"more":"fewer";return(0,zL.str)`must NOT have ${r} than ${t} properties`},params:({schemaCode:e})=>(0,zL._)`{limit: ${e}}`};var y0n={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:true,error:g0n,code(e){const{keyword:t,data:r,schemaCode:n}=e;const i=t==="maxProperties"?zL.operators.GT:zL.operators.LT;e.fail$data((0,zL._)`Object.keys(${r}).length ${i} ${n}`)}};nCe.default=y0n});var $Et=y(iCe=>{"use strict";Object.defineProperty(iCe,"__esModule",{value:true});var KL=Cf();var WL=En();var _0n=ui();var v0n={message:({params:{missingProperty:e}})=>(0,WL.str)`must have required property '${e}'`,params:({params:{missingProperty:e}})=>(0,WL._)`{missingProperty: ${e}}`};var E0n={keyword:"required",type:"object",schemaType:"array",$data:true,error:v0n,code(e){const{gen:t,schema:r,schemaCode:n,data:i,$data:s,it:o}=e;const{opts:u}=o;if(!s&&r.length===0)return;const l=r.length>=u.loopRequired;if(o.allErrors)c();else d();if(u.strictRequired){const m=e.parentSchema.properties;const{definedProperties:h}=e.it;for(const g of r){if((m===null||m===void 0?void 0:m[g])===void 0&&!h.has(g)){const _=o.schemaEnv.baseId+o.errSchemaPath;const v=`required property "${g}" is not defined at "${_}" (strictRequired)`;(0,_0n.checkStrictMode)(o,v,o.opts.strictRequired)}}}function c(){if(l||s){e.block$data(WL.nil,p)}else{for(const m of r){(0,KL.checkReportMissingProp)(e,m)}}}a(c,"allErrorsMode");function d(){const m=t.let("missing");if(l||s){const h=t.let("valid",true);e.block$data(h,()=>f(m,h));e.ok(h)}else{t.if((0,KL.checkMissingProp)(e,r,m));(0,KL.reportMissingProp)(e,m);t.else()}}a(d,"exitOnErrorMode");function p(){t.forOf("prop",n,m=>{e.setParams({missingProperty:m});t.if((0,KL.noPropertyInData)(t,i,m,u.ownProperties),()=>e.error())})}a(p,"loopAllRequired");function f(m,h){e.setParams({missingProperty:m});t.forOf(m,n,()=>{t.assign(h,(0,KL.propertyInData)(t,i,m,u.ownProperties));t.if((0,WL.not)(h),()=>{e.error();t.break()})},WL.nil)}a(f,"loopUntilMissing")}};iCe.default=E0n});var jEt=y(sCe=>{"use strict";Object.defineProperty(sCe,"__esModule",{value:true});var YL=En();var b0n={message({keyword:e,schemaCode:t}){const r=e==="maxItems"?"more":"fewer";return(0,YL.str)`must NOT have ${r} than ${t} items`},params:({schemaCode:e})=>(0,YL._)`{limit: ${e}}`};var S0n={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:true,error:b0n,code(e){const{keyword:t,data:r,schemaCode:n}=e;const i=t==="maxItems"?YL.operators.GT:YL.operators.LT;e.fail$data((0,YL._)`${r}.length ${i} ${n}`)}};sCe.default=S0n});var FY=y(aCe=>{"use strict";Object.defineProperty(aCe,"__esModule",{value:true});var GEt=rp();GEt.code='require("ajv/dist/runtime/equal").default';aCe.default=GEt});var HEt=y(uCe=>{"use strict";Object.defineProperty(uCe,"__esModule",{value:true});var oCe=FL();var nl=En();var A0n=ui();var C0n=FY();var w0n={message:({params:{i:e,j:t}})=>(0,nl.str)`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,params:({params:{i:e,j:t}})=>(0,nl._)`{i: ${e}, j: ${t}}`};var T0n={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:true,error:w0n,code(e){const{gen:t,data:r,$data:n,schema:i,parentSchema:s,schemaCode:o,it:u}=e;if(!n&&!i)return;const l=t.let("valid");const c=s.items?(0,oCe.getSchemaTypes)(s.items):[];e.block$data(l,d,(0,nl._)`${o} === false`);e.ok(l);function d(){const h=t.let("i",(0,nl._)`${r}.length`);const g=t.let("j");e.setParams({i:h,j:g});t.assign(l,true);t.if((0,nl._)`${h} > 1`,()=>(p()?f:m)(h,g))}a(d,"validateUniqueItems");function p(){return c.length>0&&!c.some(h=>h==="object"||h==="array")}a(p,"canOptimize");function f(h,g){const _=t.name("item");const v=(0,oCe.checkDataTypes)(c,_,u.opts.strictNumbers,oCe.DataType.Wrong);const S=t.const("indices",(0,nl._)`{}`);t.for((0,nl._)`;${h}--;`,()=>{t.let(_,(0,nl._)`${r}[${h}]`);t.if(v,(0,nl._)`continue`);if(c.length>1)t.if((0,nl._)`typeof ${_} == "string"`,(0,nl._)`${_} += "_"`);t.if((0,nl._)`typeof ${S}[${_}] == "number"`,()=>{t.assign(g,(0,nl._)`${S}[${_}]`);e.error();t.assign(l,false).break()}).code((0,nl._)`${S}[${_}] = ${h}`)})}a(f,"loopN");function m(h,g){const _=(0,A0n.useFunc)(t,C0n.default);const v=t.name("outer");t.label(v).for((0,nl._)`;${h}--;`,()=>t.for((0,nl._)`${g} = ${h}; ${g}--;`,()=>t.if((0,nl._)`${_}(${r}[${h}], ${r}[${g}])`,()=>{e.error();t.assign(l,false).break(v)})))}a(m,"loopN2")}};uCe.default=T0n});var VEt=y(cCe=>{"use strict";Object.defineProperty(cCe,"__esModule",{value:true});var lCe=En();var x0n=ui();var R0n=FY();var O0n={message:"must be equal to constant",params:({schemaCode:e})=>(0,lCe._)`{allowedValue: ${e}}`};var P0n={keyword:"const",$data:true,error:O0n,code(e){const{gen:t,data:r,$data:n,schemaCode:i,schema:s}=e;if(n||s&&typeof s=="object"){e.fail$data((0,lCe._)`!${(0,x0n.useFunc)(t,R0n.default)}(${r}, ${i})`)}else{e.fail((0,lCe._)`${s} !== ${r}`)}}};cCe.default=P0n});var zEt=y(dCe=>{"use strict";Object.defineProperty(dCe,"__esModule",{value:true});var XL=En();var N0n=ui();var I0n=FY();var k0n={message:"must be equal to one of the allowed values",params:({schemaCode:e})=>(0,XL._)`{allowedValues: ${e}}`};var D0n={keyword:"enum",schemaType:"array",$data:true,error:k0n,code(e){const{gen:t,data:r,$data:n,schema:i,schemaCode:s,it:o}=e;if(!n&&i.length===0)throw new Error("enum must have non-empty array");const u=i.length>=o.opts.loopEnum;let l;const c=a(()=>l!==null&&l!==void 0?l:l=(0,N0n.useFunc)(t,I0n.default),"getEql");let d;if(u||n){d=t.let("valid");e.block$data(d,p)}else{if(!Array.isArray(i))throw new Error("ajv implementation error");const m=t.const("vSchema",s);d=(0,XL.or)(...i.map((h,g)=>f(m,g)))}e.pass(d);function p(){t.assign(d,false);t.forOf("v",s,m=>t.if((0,XL._)`${c()}(${r}, ${m})`,()=>t.assign(d,true).break()))}a(p,"loopEnum");function f(m,h){const g=i[h];return typeof g==="object"&&g!==null?(0,XL._)`${c()}(${r}, ${m}[${h}])`:(0,XL._)`${r} === ${g}`}a(f,"equalCode")}};dCe.default=D0n});var KEt=y(pCe=>{"use strict";Object.defineProperty(pCe,"__esModule",{value:true});var L0n=DEt();var F0n=LEt();var B0n=MEt();var M0n=qEt();var q0n=UEt();var U0n=$Et();var $0n=jEt();var j0n=HEt();var G0n=VEt();var H0n=zEt();var V0n=[L0n.default,F0n.default,B0n.default,M0n.default,q0n.default,U0n.default,$0n.default,j0n.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},G0n.default,H0n.default];pCe.default=V0n});var mCe=y(JL=>{"use strict";Object.defineProperty(JL,"__esModule",{value:true});JL.validateAdditionalItems=void 0;var jA=En();var fCe=ui();var z0n={message:({params:{len:e}})=>(0,jA.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,jA._)`{limit: ${e}}`};var K0n={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:z0n,code(e){const{parentSchema:t,it:r}=e;const{items:n}=t;if(!Array.isArray(n)){(0,fCe.checkStrictMode)(r,'"additionalItems" is ignored when "items" is not an array of schemas');return}WEt(e,n)}};function WEt(e,t){const{gen:r,schema:n,data:i,keyword:s,it:o}=e;o.items=true;const u=r.const("len",(0,jA._)`${i}.length`);if(n===false){e.setParams({len:t.length});e.pass((0,jA._)`${u} <= ${t.length}`)}else if(typeof n=="object"&&!(0,fCe.alwaysValidSchema)(o,n)){const c=r.var("valid",(0,jA._)`${u} <= ${t.length}`);r.if((0,jA.not)(c),()=>l(c));e.ok(c)}function l(c){r.forRange("i",t.length,u,d=>{e.subschema({keyword:s,dataProp:d,dataPropType:fCe.Type.Num},c);if(!o.allErrors)r.if((0,jA.not)(c),()=>r.break())})}a(l,"validateItems")}a(WEt,"validateAdditionalItems");JL.validateAdditionalItems=WEt;JL.default=K0n});var hCe=y(QL=>{"use strict";Object.defineProperty(QL,"__esModule",{value:true});QL.validateTuple=void 0;var YEt=En();var BY=ui();var W0n=Cf();var Y0n={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){const{schema:t,it:r}=e;if(Array.isArray(t))return XEt(e,"additionalItems",t);r.items=true;if((0,BY.alwaysValidSchema)(r,t))return;e.ok((0,W0n.validateArray)(e))}};function XEt(e,t,r=e.schema){const{gen:n,parentSchema:i,data:s,keyword:o,it:u}=e;d(i);if(u.opts.unevaluated&&r.length&&u.items!==true){u.items=BY.mergeEvaluated.items(n,r.length,u.items)}const l=n.name("valid");const c=n.const("len",(0,YEt._)`${s}.length`);r.forEach((p,f)=>{if((0,BY.alwaysValidSchema)(u,p))return;n.if((0,YEt._)`${c} > ${f}`,()=>e.subschema({keyword:o,schemaProp:f,dataProp:f},l));e.ok(l)});function d(p){const{opts:f,errSchemaPath:m}=u;const h=r.length;const g=h===p.minItems&&(h===p.maxItems||p[t]===false);if(f.strictTuples&&!g){const _=`"${o}" is ${h}-tuple, but minItems or maxItems/${t} are not specified or different at path "${m}"`;(0,BY.checkStrictMode)(u,_,f.strictTuples)}}a(d,"checkStrictTuple")}a(XEt,"validateTuple");QL.validateTuple=XEt;QL.default=Y0n});var JEt=y(gCe=>{"use strict";Object.defineProperty(gCe,"__esModule",{value:true});var X0n=hCe();var J0n={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:e=>(0,X0n.validateTuple)(e,"items")};gCe.default=J0n});var ZEt=y(yCe=>{"use strict";Object.defineProperty(yCe,"__esModule",{value:true});var QEt=En();var Q0n=ui();var Z0n=Cf();var egn=mCe();var tgn={message:({params:{len:e}})=>(0,QEt.str)`must NOT have more than ${e} items`,params:({params:{len:e}})=>(0,QEt._)`{limit: ${e}}`};var rgn={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:tgn,code(e){const{schema:t,parentSchema:r,it:n}=e;const{prefixItems:i}=r;n.items=true;if((0,Q0n.alwaysValidSchema)(n,t))return;if(i)(0,egn.validateAdditionalItems)(e,i);else e.ok((0,Z0n.validateArray)(e))}};yCe.default=rgn});var ebt=y(_Ce=>{"use strict";Object.defineProperty(_Ce,"__esModule",{value:true});var Tf=En();var MY=ui();var ngn={message:({params:{min:e,max:t}})=>t===void 0?(0,Tf.str)`must contain at least ${e} valid item(s)`:(0,Tf.str)`must contain at least ${e} and no more than ${t} valid item(s)`,params:({params:{min:e,max:t}})=>t===void 0?(0,Tf._)`{minContains: ${e}}`:(0,Tf._)`{minContains: ${e}, maxContains: ${t}}`};var ign={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:true,error:ngn,code(e){const{gen:t,schema:r,parentSchema:n,data:i,it:s}=e;let o;let u;const{minContains:l,maxContains:c}=n;if(s.opts.next){o=l===void 0?1:l;u=c}else{o=1}const d=t.const("len",(0,Tf._)`${i}.length`);e.setParams({min:o,max:u});if(u===void 0&&o===0){(0,MY.checkStrictMode)(s,`"minContains" == 0 without "maxContains": "contains" keyword ignored`);return}if(u!==void 0&&o>u){(0,MY.checkStrictMode)(s,`"minContains" > "maxContains" is always invalid`);e.fail();return}if((0,MY.alwaysValidSchema)(s,r)){let g=(0,Tf._)`${d} >= ${o}`;if(u!==void 0)g=(0,Tf._)`${g} && ${d} <= ${u}`;e.pass(g);return}s.items=true;const p=t.name("valid");if(u===void 0&&o===1){m(p,()=>t.if(p,()=>t.break()))}else if(o===0){t.let(p,true);if(u!==void 0)t.if((0,Tf._)`${i}.length > 0`,f)}else{t.let(p,false);f()}e.result(p,()=>e.reset());function f(){const g=t.name("_valid");const _=t.let("count",0);m(g,()=>t.if(g,()=>h(_)))}a(f,"validateItemsWithCount");function m(g,_){t.forRange("i",0,d,v=>{e.subschema({keyword:"contains",dataProp:v,dataPropType:MY.Type.Num,compositeRule:true},g);_()})}a(m,"validateItems");function h(g){t.code((0,Tf._)`${g}++`);if(u===void 0){t.if((0,Tf._)`${g} >= ${o}`,()=>t.assign(p,true).break())}else{t.if((0,Tf._)`${g} > ${u}`,()=>t.assign(p,false).break());if(o===1)t.assign(p,true);else t.if((0,Tf._)`${g} >= ${o}`,()=>t.assign(p,true))}}a(h,"checkLimits")}};_Ce.default=ign});var qY=y(j0=>{"use strict";Object.defineProperty(j0,"__esModule",{value:true});j0.validateSchemaDeps=j0.validatePropertyDeps=j0.error=void 0;var vCe=En();var sgn=ui();var ZL=Cf();j0.error={message:({params:{property:e,depsCount:t,deps:r}})=>{const n=t===1?"property":"properties";return(0,vCe.str)`must have ${n} ${r} when property ${e} is present`},params:({params:{property:e,depsCount:t,deps:r,missingProperty:n}})=>(0,vCe._)`{property: ${e},
|