@ashishpandeyone/cdk-lambda-web-function 0.1.0 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,58 @@
1
+ "use strict";var nX=Object.create;var yp=Object.defineProperty;var sX=Object.getOwnPropertyDescriptor;var oX=Object.getOwnPropertyNames;var iX=Object.getPrototypeOf,aX=Object.prototype.hasOwnProperty;var f=(t,e,r)=>()=>{if(r)throw r[0];try{return t&&(e=t(t=0)),e}catch(n){throw r=[n],n}};var Ne=(t,e)=>()=>{try{return e||t((e={exports:{}}).exports,e),e.exports}catch(r){throw e=0,r}},at=(t,e)=>{for(var r in e)yp(t,r,{get:e[r],enumerable:!0})},Ew=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let s of oX(e))!aX.call(t,s)&&s!==r&&yp(t,s,{get:()=>e[s],enumerable:!(n=sX(e,s))||n.enumerable});return t};var ye=(t,e,r)=>(r=t!=null?nX(iX(t)):{},Ew(e||!t||!t.__esModule?yp(r,"default",{value:t,enumerable:!0}):r,t)),O=t=>Ew(yp({},"__esModule",{value:!0}),t);var Jc,Rn,yw=f(()=>{Jc={warningEmitted:!1},Rn=t=>{if(t&&!Jc.warningEmitted){if(process.env.AWS_SDK_JS_NODE_VERSION_SUPPORT_WARNING_DISABLED==="true"){Jc.warningEmitted=!0;return}let e=parseInt(t.substring(1,t.indexOf("."))),r=22;e<r&&(Jc.warningEmitted=!0,process.emitWarning(`NodeVersionSupportWarning: The AWS SDK for JavaScript (v3)
2
+ versions published after the first week of January 2027
3
+ will require node >=${r}. You are running node ${t}.
4
+
5
+ To continue receiving updates to AWS services, bug fixes,
6
+ and security updates please upgrade to node >=${r}.
7
+
8
+ More information can be found at: https://a.co/c895JFp`))}}});var cX,uX,_w,Rw=f(()=>{cX=()=>(t,e)=>async r=>(e.__retryLongPoll=!0,t(r)),uX={name:"longPollMiddleware",tags:["RETRY"],step:"initialize",override:!0},_w=t=>({applyToStack:e=>{e.add(cX(),uX)}})});function js(t,e,r){return t.$source||(t.$source={}),t.$source[e]=r,t}var Tw=f(()=>{});var Aw,uR,Iw=f(()=>{Aw=require("node:stream"),uR=t=>t?.body instanceof Aw.Readable||typeof ReadableStream<"u"&&t?.body instanceof ReadableStream});var Ko,qs,Ks,xw,Cw,_p=f(()=>{Ko=(t,e)=>{let r=[];if(t&&r.push(t),e)for(let n of e)r.push(n);return r},qs=(t,e)=>`${t||"anonymous"}${e&&e.length>0?` (a.k.a. ${e.join(",")})`:""}`,Ks=()=>{let t=[],e=[],r=!1,n=new Set,s=d=>d.sort((m,g)=>xw[g.step]-xw[m.step]||Cw[g.priority||"normal"]-Cw[m.priority||"normal"]),o=d=>{let m=!1,g=E=>{let _=Ko(E.name,E.aliases);if(_.includes(d)){m=!0;for(let R of _)n.delete(R);return!1}return!0};return t=t.filter(g),e=e.filter(g),m},i=d=>{let m=!1,g=E=>{if(E.middleware===d){m=!0;for(let _ of Ko(E.name,E.aliases))n.delete(_);return!1}return!0};return t=t.filter(g),e=e.filter(g),m},a=d=>(t.forEach(m=>{d.add(m.middleware,{...m})}),e.forEach(m=>{d.addRelativeTo(m.middleware,{...m})}),d.identifyOnResolve?.(p.identifyOnResolve()),d),c=d=>{let m=[];return d.before.forEach(g=>{g.before.length===0&&g.after.length===0?m.push(g):m.push(...c(g))}),m.push(d),d.after.reverse().forEach(g=>{g.before.length===0&&g.after.length===0?m.push(g):m.push(...c(g))}),m},u=(d=!1)=>{let m=[],g=[],E={};return t.forEach(R=>{let T={...R,before:[],after:[]};for(let I of Ko(T.name,T.aliases))E[I]=T;m.push(T)}),e.forEach(R=>{let T={...R,before:[],after:[]};for(let I of Ko(T.name,T.aliases))E[I]=T;g.push(T)}),g.forEach(R=>{if(R.toMiddleware){let T=E[R.toMiddleware];if(T===void 0){if(d)return;throw new Error(`${R.toMiddleware} is not found when adding ${qs(R.name,R.aliases)} middleware ${R.relation} ${R.toMiddleware}`)}R.relation==="after"&&T.after.push(R),R.relation==="before"&&T.before.push(R)}}),s(m).map(c).reduce((R,T)=>(R.push(...T),R),[])},p={add:(d,m={})=>{let{name:g,override:E,aliases:_}=m,R={step:"initialize",priority:"normal",middleware:d,...m},T=Ko(g,_);if(T.length>0){if(T.some(I=>n.has(I))){if(!E)throw new Error(`Duplicate middleware name '${qs(g,_)}'`);for(let I of T){let P=t.findIndex(Z=>Z.name===I||Z.aliases?.some(Pe=>Pe===I));if(P===-1)continue;let v=t[P];if(v.step!==R.step||R.priority!==v.priority)throw new Error(`"${qs(v.name,v.aliases)}" middleware with ${v.priority} priority in ${v.step} step cannot be overridden by "${qs(g,_)}" middleware with ${R.priority} priority in ${R.step} step.`);t.splice(P,1)}}for(let I of T)n.add(I)}t.push(R)},addRelativeTo:(d,m)=>{let{name:g,override:E,aliases:_}=m,R={middleware:d,...m},T=Ko(g,_);if(T.length>0){if(T.some(I=>n.has(I))){if(!E)throw new Error(`Duplicate middleware name '${qs(g,_)}'`);for(let I of T){let P=e.findIndex(Z=>Z.name===I||Z.aliases?.some(Pe=>Pe===I));if(P===-1)continue;let v=e[P];if(v.toMiddleware!==R.toMiddleware||v.relation!==R.relation)throw new Error(`"${qs(v.name,v.aliases)}" middleware ${v.relation} "${v.toMiddleware}" middleware cannot be overridden by "${qs(g,_)}" middleware ${R.relation} "${R.toMiddleware}" middleware.`);e.splice(P,1)}}for(let I of T)n.add(I)}e.push(R)},clone:()=>a(Ks()),use:d=>{d.applyToStack(p)},remove:d=>typeof d=="string"?o(d):i(d),removeByTag:d=>{let m=!1,g=E=>{let{tags:_,name:R,aliases:T}=E;if(_&&_.includes(d)){let I=Ko(R,T);for(let P of I)n.delete(P);return m=!0,!1}return!0};return t=t.filter(g),e=e.filter(g),m},concat:d=>{let m=a(Ks());return m.use(d),m.identifyOnResolve(r||m.identifyOnResolve()||(d.identifyOnResolve?.()??!1)),m},applyToStack:a,identify:()=>u(!0).map(d=>{let m=d.step??d.relation+" "+d.toMiddleware;return qs(d.name,d.aliases)+" - "+m}),identifyOnResolve(d){return typeof d=="boolean"&&(r=d),r},resolve:(d,m)=>{for(let g of u().map(E=>E.middleware).reverse())d=g(d,m);return r&&console.log(p.identify()),d}};return p},xw={initialize:5,serialize:4,build:3,finalizeRequest:2,deserialize:1},Cw={high:3,normal:2,low:1}});var Hr=Ne(Gr=>{var lR;(function(t){t.HEADER="header",t.QUERY="query"})(lR||(lR={}));var dR;(function(t){t.HEADER="header",t.QUERY="query"})(dR||(dR={}));var pR;(function(t){t.HTTP="http",t.HTTPS="https"})(pR||(pR={}));var Xc;(function(t){t.MD5="md5",t.CRC32="crc32",t.CRC32C="crc32c",t.SHA1="sha1",t.SHA256="sha256"})(Xc||(Xc={}));var lX=t=>{let e=[];return t.sha256!==void 0&&e.push({algorithmId:()=>Xc.SHA256,checksumConstructor:()=>t.sha256}),t.md5!=null&&e.push({algorithmId:()=>Xc.MD5,checksumConstructor:()=>t.md5}),{addChecksumAlgorithm(r){e.push(r)},checksumAlgorithms(){return e}}},dX=t=>{let e={};return t.checksumAlgorithms().forEach(r=>{e[r.algorithmId()]=r.checksumConstructor()}),e},pX=t=>lX(t),fX=t=>dX(t),fR;(function(t){t[t.HEADER=0]="HEADER",t[t.TRAILER=1]="TRAILER"})(fR||(fR={}));var mX="__smithy_context",mR;(function(t){t.PROFILE="profile",t.SSO_SESSION="sso-session",t.SERVICES="services"})(mR||(mR={}));var hR;(function(t){t.HTTP_0_9="http/0.9",t.HTTP_1_0="http/1.0",t.TDS_8_0="tds/8.0"})(hR||(hR={}));Gr.AlgorithmId=Xc;Gr.EndpointURLScheme=pR;Gr.FieldPosition=fR;Gr.HttpApiKeyAuthLocation=dR;Gr.HttpAuthLocation=lR;Gr.IniSectionType=mR;Gr.RequestHandlerProtocol=hR;Gr.SMITHY_CONTEXT_KEY=mX;Gr.getDefaultClientConfiguration=pX;Gr.resolveDefaultRuntimeConfig=fX});var gR,he,bw=f(()=>{gR=ye(Hr()),he=t=>t[gR.SMITHY_CONTEXT_KEY]||(t[gR.SMITHY_CONTEXT_KEY]={})});function k(t,e){return Object.prototype.hasOwnProperty.call(t,e)}var SR=f(()=>{});function hX(t){return Object.keys(t).reduce((e,r)=>{let n=t[r];return{...e,[r]:Array.isArray(n)?[...n]:n}},{})}var J,ww=f(()=>{J=class t{method;protocol;hostname;port;path;query;headers;username;password;fragment;body;constructor(e){this.method=e.method||"GET",this.hostname=e.hostname||"localhost",this.port=e.port,this.query=e.query||{},this.headers=e.headers||{},this.body=e.body,this.protocol=e.protocol?e.protocol.slice(-1)!==":"?`${e.protocol}:`:e.protocol:"https:",this.path=e.path?e.path.charAt(0)!=="/"?`/${e.path}`:e.path:"/",this.username=e.username,this.password=e.password,this.fragment=e.fragment}static clone(e){let r=new t({...e,headers:{...e.headers}});return r.query&&(r.query=hX(r.query)),r}static isInstance(e){if(!e)return!1;let r=e;return"method"in r&&"protocol"in r&&"hostname"in r&&"path"in r&&typeof r.query=="object"&&typeof r.headers=="object"}clone(){return t.clone(this)}}});var ct,Dw=f(()=>{ct=class{statusCode;reason;headers;body;constructor(e){this.statusCode=e.statusCode,this.reason=e.reason,this.headers=e.headers||{},this.body=e.body}static isInstance(e){if(!e)return!1;let r=e;return typeof r.statusCode=="number"&&typeof r.headers=="object"}}});var gX,Vr,Ow=f(()=>{gX=new RegExp("^(?!.*-$)(?!-)[a-zA-Z0-9-]{1,63}$"),Vr=(t,e=!1)=>{if(!e)return gX.test(t);let r=t.split(".");for(let n of r)if(!Vr(n))return!1;return!0}});function Zc(t){return/^[a-z0-9][a-z0-9.-]*[a-z0-9]$/.test(t)}var vw=f(()=>{});var ge,Pw=f(()=>{ge=t=>{if(typeof t=="function")return t;let e=Promise.resolve(t);return()=>e}});function eu(t){let e={};if(t=t.replace(/^\?/,""),t)for(let r of t.split("&")){let[n,s=null]=r.split("=");n=decodeURIComponent(n),s&&(s=decodeURIComponent(s)),n in e?Array.isArray(e[n])?e[n].push(s):e[n]=[e[n],s]:e[n]=s}return e}var ER=f(()=>{});var Et,yR=f(()=>{ER();Et=t=>{if(typeof t=="string")return Et(new URL(t));let{hostname:e,pathname:r,port:n,protocol:s,search:o}=t,i;return o&&(i=eu(o)),{hostname:e,port:n?parseInt(n):void 0,protocol:s,path:r,query:i}}});var ir,Nw=f(()=>{SR();yR();ir=t=>{if(typeof t=="object"){if("url"in t){let e=Et(t.url);if(t.headers){e.headers={};for(let r in t.headers)k(t.headers,r)&&(e.headers[r.toLowerCase()]=t.headers[r].join(", "))}return e}return t}return Et(t)}});var W=f(()=>{bw();SR();ww();Dw();Ow();vw();Pw();ER();yR();Nw()});var kw,Mw=f(()=>{kw=t=>()=>{throw new Error(t)}});var Lw,$w=f(()=>{Lw=t=>()=>Promise.reject(t)});var Ki,_R=f(()=>{Ki=()=>{let t=new WeakSet;return(e,r)=>{if(typeof r=="object"&&r!==null){if(t.has(r))return"[Circular]";t.add(r)}return r}}});var Fw,Uw=f(()=>{Fw=t=>new Promise(e=>setTimeout(e,t*1e3))});var Rp,ar,Bw,Tp=f(()=>{_R();Rp={minDelay:2,maxDelay:120};(function(t){t.ABORTED="ABORTED",t.FAILURE="FAILURE",t.SUCCESS="SUCCESS",t.RETRY="RETRY",t.TIMEOUT="TIMEOUT"})(ar||(ar={}));Bw=t=>{if(t.state===ar.ABORTED){let e=new Error(`${JSON.stringify({...t,reason:"Request was aborted"},Ki())}`);throw e.name="AbortError",e}else if(t.state===ar.TIMEOUT){let e=new Error(`${JSON.stringify({...t,reason:"Waiter has timed out"},Ki())}`);throw e.name="TimeoutError",e}else if(t.state!==ar.SUCCESS)throw new Error(`${JSON.stringify(t,Ki())}`);return t}});var Gw,SX,EX,yX,_X,Hw=f(()=>{_R();Uw();Tp();Gw=async({minDelay:t,maxDelay:e,maxWaitTime:r,abortController:n,client:s,abortSignal:o},i,a)=>{let c={},[u,p]=[t*1e3,e*1e3],d=0,m=Date.now()+r*1e3,g=Date.now()+6e4,E=!1;for(;;){if(d>0){let T=yX(u,p,d,m);if(n?.signal?.aborted||o?.aborted){let I="AbortController signal aborted.";return c[I]|=0,c[I]+=1,{state:ar.ABORTED,observedResponses:c}}if(Date.now()+T>m)return{state:ar.TIMEOUT,observedResponses:c};await Fw(T/1e3)}let{state:_,reason:R}=await a(s,i);if(R){let T=EX(R);c[T]|=0,c[T]+=1}if(_!==ar.RETRY)return{state:_,reason:R,final:R,observedResponses:c};d+=1,!E&&Date.now()>=g&&(SX(c,s),E=!0)}},SX=(t={},e)=>{let r=Object.keys(t),n=0,s=0;for(let a of r){let c=t[a]|0;n=Math.max(c,n),a.startsWith("403:")&&(s+=c)}let o=e?.config?.logger,i=typeof o?.warn=="function"&&!o.constructor?.name?.includes?.("NoOpLogger")?o:console;(s>=3||r[r.length-1]?.startsWith("403:"))&&i.warn("@smithy/util-waiter WARN - 403 status code encountered during waiter polling.")},EX=t=>{let e=t?.$response?.statusCode??t?.$metadata?.httpStatusCode;return t?.$responseBodyText?`${e?e+": ":""}Deserialization error for body: ${t.$responseBodyText}`:e?t?.$response||t?.message?`${e??"Unknown"}: ${t?.message}`:`${e}: OK`:String(t?.message??JSON.stringify(t,Ki())??"Unknown")},yX=(t,e,r,n)=>{let s=Math.log(e/t)/Math.log(2)+1;if(r>s)return e;let o=t*2**(r-1),i=Math.min(o,e),a=_X(t,i);if(Date.now()+a>n){let c=n-Date.now();return Math.max(0,c-500)}return a},_X=(t,e)=>t+Math.random()*(e-t)});var Vw,Ww=f(()=>{Vw=t=>{if(t.maxWaitTime<=0)throw new Error("WaiterConfiguration.maxWaitTime must be greater than 0");if(t.minDelay<=0)throw new Error("WaiterConfiguration.minDelay must be greater than 0");if(t.maxDelay<=0)throw new Error("WaiterConfiguration.maxDelay must be greater than 0");if(t.maxWaitTime<=t.minDelay)throw new Error(`WaiterConfiguration.maxWaitTime [${t.maxWaitTime}] must be greater than WaiterConfiguration.minDelay [${t.minDelay}] for this waiter`);if(t.maxDelay<t.minDelay)throw new Error(`WaiterConfiguration.maxDelay [${t.maxDelay}] must be greater than WaiterConfiguration.minDelay [${t.minDelay}] for this waiter`)}});var zw,jw,qw=f(()=>{Hw();Ww();Tp();zw=t=>{let e,r=new Promise(n=>{e=()=>n({state:ar.ABORTED}),typeof t.addEventListener=="function"?t.addEventListener("abort",e):t.onabort=e});return{clearListener(){typeof t.removeEventListener=="function"&&t.removeEventListener("abort",e)},aborted:r}},jw=async(t,e,r)=>{let n={...Rp,...t};Vw(n);let s=[Gw(n,e,r)],o=[];if(t.abortSignal){let{aborted:i,clearListener:a}=zw(t.abortSignal);o.push(a),s.push(i)}if(t.abortController?.signal){let{aborted:i,clearListener:a}=zw(t.abortController.signal);o.push(a),s.push(i)}return Promise.race(s).then(i=>{for(let a of o)a();return i})}});var Dt,Kw=f(()=>{_p();Dt=class{config;middlewareStack=Ks();initConfig;handlers;constructor(e){this.config=e;let{protocol:r,protocolSettings:n}=e;n&&typeof r=="function"&&(e.protocol=new r(n))}send(e,r,n){let s=typeof r!="function"?r:void 0,o=typeof r=="function"?r:n,i=s===void 0&&this.config.cacheMiddleware===!0,a;if(i){this.handlers||(this.handlers=new WeakMap);let c=this.handlers;c.has(e.constructor)?a=c.get(e.constructor):(a=e.resolveMiddleware(this.middlewareStack,this.config,s),c.set(e.constructor,a))}else delete this.handlers,a=e.resolveMiddleware(this.middlewareStack,this.config,s);if(o)a(e).then(c=>o(null,c.output),c=>o(c)).catch(()=>{});else return a(e).then(c=>c.output)}destroy(){this.config?.requestHandler?.destroy?.(),delete this.handlers}}});var Yt,RR=f(()=>{Yt=t=>typeof t=="function"?t():t});var Yi,Ap=f(()=>{Yi=(t,e,r,n,s)=>({name:e,namespace:t,traits:r,input:n,output:s})});var Yw,TR,Qw=f(()=>{W();Ap();Yw=t=>(e,r)=>async n=>{let{response:s}=await e(n),{operationSchema:o}=he(r),[,i,a,c,u,p]=o??[];try{let d=await t.protocol.deserializeResponse(Yi(i,a,c,u,p),{...t,...r},s);return{response:s,output:d}}catch(d){if(Object.defineProperty(d,"$response",{value:s,enumerable:!1,writable:!1,configurable:!1}),!("$metadata"in d)){let m="Deserialization error: to see the raw response, inspect the hidden field {error}.$response on this object.";try{d.message+=`
9
+ `+m}catch{!r.logger||r.logger?.constructor?.name==="NoOpLogger"?console.warn(m):r.logger?.warn?.(m)}typeof d.$responseBodyText<"u"&&d.$response&&(d.$response.body=d.$responseBodyText);try{if(ct.isInstance(s)){let{headers:g={},statusCode:E}=s,_=Object.entries(g);d.$metadata={httpStatusCode:E,requestId:TR(/^x-[\w-]+-request-?id$/,_),extendedRequestId:TR(/^x-[\w-]+-id-2$/,_),cfId:TR(/^x-[\w-]+-cf-id$/,_)}}}catch{}}throw d}},TR=(t,e)=>(e.find(([r])=>r.match(t))||[void 0,void 0])[1]});var Jw,Xw=f(()=>{W();Ap();Jw=t=>(e,r)=>async n=>{let{operationSchema:s}=he(r),[,o,i,a,c,u]=s??[],p=r.endpointV2?async()=>ir(r.endpointV2):t.endpoint,d=await t.protocol.serializeRequest(Yi(o,i,a,c,u),n.input,{...t,...r,endpoint:p});return e({...n,request:d})}});function Tn(t){return{applyToStack:e=>{e.add(Jw(t),IR),e.add(Yw(t),AR),t.protocol.setSerdeContext(t)}}}var AR,IR,Zw=f(()=>{Qw();Xw();AR={name:"deserializerMiddleware",step:"deserialize",tags:["DESERIALIZER"],override:!0},IR={name:"serializerMiddleware",step:"serialize",tags:["SERIALIZER"],override:!0}});var Le,Ys=f(()=>{Le=class{name;namespace;traits;static assign(e,r){return Object.assign(e,r)}static[Symbol.hasInstance](e){let r=this.prototype.isPrototypeOf(e);return!r&&typeof e=="object"&&e!==null?e.symbol===this.symbol:r}getName(){return this.namespace+"#"+this.name}}});var tu,eD,tD=f(()=>{Ys();tu=class t extends Le{static symbol=Symbol.for("@smithy/lis");valueSchema;symbol=t.symbol},eD=(t,e,r,n)=>Le.assign(new tu,{name:e,namespace:t,traits:r,valueSchema:n})});var ru,rD,nD=f(()=>{Ys();ru=class t extends Le{static symbol=Symbol.for("@smithy/map");keySchema;valueSchema;symbol=t.symbol},rD=(t,e,r,n,s)=>Le.assign(new ru,{name:e,namespace:t,traits:r,keySchema:n,valueSchema:s})});var nu,sD,oD=f(()=>{Ys();nu=class t extends Le{static symbol=Symbol.for("@smithy/ope");input;output;symbol=t.symbol},sD=(t,e,r,n,s)=>Le.assign(new nu,{name:e,namespace:t,traits:r,input:n,output:s})});var Yo,iD,xR=f(()=>{Ys();Yo=class t extends Le{static symbol=Symbol.for("@smithy/str");memberNames;memberList;symbol=t.symbol},iD=(t,e,r,n,s)=>Le.assign(new Yo,{name:e,namespace:t,traits:r,memberNames:n,memberList:s})});var su,aD,cD=f(()=>{Ys();xR();su=class t extends Yo{static symbol=Symbol.for("@smithy/err");ctor;symbol=t.symbol},aD=(t,e,r,n,s,o)=>Le.assign(new su,{name:e,namespace:t,traits:r,memberNames:n,memberList:s,ctor:null})});function Wr(t){if(typeof t=="object")return t;if(t=t|0,ou[t])return ou[t];let e={},r=0;for(let n of["httpLabel","idempotent","idempotencyToken","sensitive","httpPayload","httpResponseCode","httpQueryParams"])(t>>r++&1)===1&&(e[n]=1);return ou[t]=e}var ou,CR=f(()=>{ou=[]});function au(t,e){if(t instanceof x)return Object.assign(t,{memberName:e,_isMemberSchema:!0});let r=x;return new r(t,e)}var iu,cu,uu,x,bR,wR,uD=f(()=>{RR();CR();iu={it:Symbol.for("@smithy/nor-struct-it"),ns:Symbol.for("@smithy/ns")},cu=[],uu={},x=class t{ref;memberName;static symbol=Symbol.for("@smithy/nor");symbol=t.symbol;name;schema;_isMemberSchema;traits;memberTraits;normalizedTraits;constructor(e,r){this.ref=e,this.memberName=r;let n=[],s=e,o=e;for(this._isMemberSchema=!1;bR(s);)n.push(s[1]),s=s[0],o=Yt(s),this._isMemberSchema=!0;if(n.length>0){this.memberTraits={};for(let i=n.length-1;i>=0;--i){let a=n[i];Object.assign(this.memberTraits,Wr(a))}}else this.memberTraits=0;if(o instanceof t){let i=this.memberTraits;Object.assign(this,o),this.memberTraits=Object.assign({},i,o.getMemberTraits(),this.getMemberTraits()),this.normalizedTraits=void 0,this.memberName=r??o.memberName;return}if(this.schema=Yt(o),wR(this.schema)?(this.name=`${this.schema[1]}#${this.schema[2]}`,this.traits=this.schema[3]):(this.name=this.memberName??String(o),this.traits=0),this._isMemberSchema&&!r)throw new Error(`@smithy/core/schema - NormalizedSchema member init ${this.getName(!0)} missing member name.`)}static[Symbol.hasInstance](e){let r=this.prototype.isPrototypeOf(e);return!r&&typeof e=="object"&&e!==null?e.symbol===this.symbol:r}static of(e){let r=typeof e=="function"||typeof e=="object"&&e!==null;if(typeof e=="number"){if(cu[e])return cu[e]}else if(typeof e=="string"){if(uu[e])return uu[e]}else if(r&&e[iu.ns])return e[iu.ns];let n=Yt(e);if(n instanceof t)return n;if(bR(n)){let[o,i]=n;if(o instanceof t)return Object.assign(o.getMergedTraits(),Wr(i)),o;throw new Error(`@smithy/core/schema - may not init unwrapped member schema=${JSON.stringify(e,null,2)}.`)}let s=new t(n);return r?e[iu.ns]=s:typeof n=="string"?uu[n]=s:typeof n=="number"?cu[n]=s:s}getSchema(){let e=this.schema;return Array.isArray(e)&&e[0]===0?e[4]:e}getName(e=!1){let{name:r}=this;return!e&&r&&r.includes("#")?r.split("#")[1]:r||void 0}getMemberName(){return this.memberName}isMemberSchema(){return this._isMemberSchema}isListSchema(){let e=this.getSchema();return typeof e=="number"?e>=64&&e<128:e[0]===1}isMapSchema(){let e=this.getSchema();return typeof e=="number"?e>=128&&e<=255:e[0]===2}isStructSchema(){let e=this.getSchema();if(typeof e!="object")return!1;let r=e[0];return r===3||r===-3||r===4}isUnionSchema(){let e=this.getSchema();return typeof e!="object"?!1:e[0]===4}isBlobSchema(){let e=this.getSchema();return e===21||e===42}isTimestampSchema(){let e=this.getSchema();return typeof e=="number"&&e>=4&&e<=7}isUnitSchema(){return this.getSchema()==="unit"}isDocumentSchema(){return this.getSchema()===15}isStringSchema(){return this.getSchema()===0}isBooleanSchema(){return this.getSchema()===2}isNumericSchema(){return this.getSchema()===1}isBigIntegerSchema(){return this.getSchema()===17}isBigDecimalSchema(){return this.getSchema()===19}isStreaming(){let{streaming:e}=this.getMergedTraits();return!!e||this.getSchema()===42}isIdempotencyToken(){return!!this.getMergedTraits().idempotencyToken}getMergedTraits(){return this.normalizedTraits??(this.normalizedTraits={...this.getOwnTraits(),...this.getMemberTraits()})}getMemberTraits(){return Wr(this.memberTraits)}getOwnTraits(){return Wr(this.traits)}getKeySchema(){let[e,r]=[this.isDocumentSchema(),this.isMapSchema()];if(!e&&!r)throw new Error(`@smithy/core/schema - cannot get key for non-map: ${this.getName(!0)}`);let n=this.getSchema(),s=e?15:n[4]??0;return au([s,0],"key")}getValueSchema(){let e=this.getSchema(),[r,n,s]=[this.isDocumentSchema(),this.isMapSchema(),this.isListSchema()],o=typeof e=="number"?63&e:e&&typeof e=="object"&&(n||s)?e[3+e[0]]:r?15:void 0;if(o!=null)return au([o,0],n?"value":"member");throw new Error(`@smithy/core/schema - ${this.getName(!0)} has no value member.`)}getMemberSchema(e){let r=this.getSchema();if(this.isStructSchema()&&r[4].includes(e)){let n=r[4].indexOf(e),s=r[5][n];return au(bR(s)?s:[s,0],e)}if(this.isDocumentSchema())return au([15,0],e);throw new Error(`@smithy/core/schema - ${this.getName(!0)} has no member=${e}.`)}getMemberSchemas(){let e={};try{for(let[r,n]of this.structIterator())e[r]=n}catch{}return e}getEventStreamMember(){if(this.isStructSchema()){for(let[e,r]of this.structIterator())if(r.isStreaming()&&r.isStructSchema())return e}return""}*structIterator(){if(this.isUnitSchema())return;if(!this.isStructSchema())throw new Error("@smithy/core/schema - cannot iterate non-struct schema.");let e=this.getSchema(),r=e[4].length,n=e[iu.it];if(n&&r===n.length){yield*n;return}n=Array(r);for(let s=0;s<r;++s){let o=e[4][s],i=au([e[5][s],0],o);yield n[s]=[o,i]}e[iu.it]=n}};bR=t=>Array.isArray(t)&&t.length===2,wR=t=>Array.isArray(t)&&t.length>=5});var Qi,lD,dD,pD=f(()=>{Ys();Qi=class t extends Le{static symbol=Symbol.for("@smithy/sim");schemaRef;symbol=t.symbol},lD=(t,e,r,n)=>Le.assign(new Qi,{name:e,namespace:t,traits:n,schemaRef:r}),dD=(t,e,r,n)=>Le.assign(new Qi,{name:e,namespace:t,traits:r,schemaRef:n})});var fD,mD=f(()=>{fD={BLOB:21,STREAMING_BLOB:42,BOOLEAN:2,STRING:0,NUMERIC:1,BIG_INTEGER:17,BIG_DECIMAL:19,DOCUMENT:15,TIMESTAMP_DEFAULT:4,TIMESTAMP_DATE_TIME:5,TIMESTAMP_HTTP_DATE:6,TIMESTAMP_EPOCH_SECONDS:7,LIST_MODIFIER:64,MAP_MODIFIER:128}});var ce,hD=f(()=>{ce=class t{namespace;schemas;exceptions;static registries=new Map;constructor(e,r=new Map,n=new Map){this.namespace=e,this.schemas=r,this.exceptions=n,t.registries.has(e)||t.registries.set(e,this)}static for(e){return t.registries.get(e)??new t(e)}copyFrom(e){let{schemas:r,exceptions:n}=this;for(let[s,o]of e.schemas)r.has(s)||r.set(s,o);for(let[s,o]of e.exceptions)n.has(s)||n.set(s,o)}register(e,r){let n=this.normalizeShapeId(e);for(let s of[this,t.for(n.split("#")[0])])s.schemas.has(n)||s.schemas.set(n,r)}getSchema(e){let r=this.normalizeShapeId(e);if(!this.schemas.has(r)){if(!e.includes("#")){let n="#"+e,s=[];for(let[o,i]of this.schemas.entries())o.endsWith(n)&&s.push(i);if(s.length===1)return s[0]}throw new Error(`@smithy/core/schema - schema not found for ${r}`)}return this.schemas.get(r)}registerError(e,r){let n=e,s=n[1],o=s+"#"+n[2];r.hasOwnProperty?.("shapeId")||(r.shapeId=o);for(let i of[this,t.for(s)])!i.schemas.has(o)&&!i.exceptions.has(n)&&(i.schemas.set(o,n),i.exceptions.set(n,r))}getErrorCtor(e){let r=e;return this.exceptions.has(r)?this.exceptions.get(r):t.for(r[1]).exceptions.get(r)}getBaseException(){for(let e of this.exceptions.keys())if(Array.isArray(e)){let[,r,n]=e,s=r+"#"+n;if(s.startsWith("smithy.ts.sdk.synthetic.")&&s.endsWith("ServiceException"))return e}}find(e){for(let r of this.schemas.values())if(e(r))return r}clear(){this.schemas.clear(),this.exceptions.clear()}normalizeShapeId(e){return e.includes("#")?e:this.namespace+"#"+e}}});var Ip={};at(Ip,{ErrorSchema:()=>su,ListSchema:()=>tu,MapSchema:()=>ru,NormalizedSchema:()=>x,OperationSchema:()=>nu,SCHEMA:()=>fD,Schema:()=>Le,SimpleSchema:()=>Qi,StructureSchema:()=>Yo,TypeRegistry:()=>ce,deref:()=>Yt,deserializerMiddlewareOption:()=>AR,error:()=>aD,getSchemaSerdePlugin:()=>Tn,isStaticSchema:()=>wR,list:()=>eD,map:()=>rD,op:()=>sD,operation:()=>Yi,serializerMiddlewareOption:()=>IR,sim:()=>lD,simAdapter:()=>dD,simpleSchemaCacheN:()=>cu,simpleSchemaCacheS:()=>uu,struct:()=>iD,traitsCache:()=>ou,translateTraits:()=>Wr});var K=f(()=>{RR();Zw();tD();nD();oD();Ap();cD();uD();Ys();pD();xR();mD();CR();hD()});function Ji(t,e){if(e==null)return e;let r=x.of(t);if(r.getMergedTraits().sensitive)return DR;if(r.isListSchema()){if(!!r.getValueSchema().getMergedTraits().sensitive)return DR}else if(r.isMapSchema()){if(!!r.getKeySchema().getMergedTraits().sensitive||!!r.getValueSchema().getMergedTraits().sensitive)return DR}else if(r.isStructSchema()&&typeof e=="object"){let n=e,s={};for(let[o,i]of r.structIterator())n[o]!=null&&(s[o]=Ji(i,n[o]));return s}return e}var DR,OR=f(()=>{K();DR="***SensitiveInformation***"});var vR,Ft,PR,NR=f(()=>{vR=ye(Hr());_p();OR();Ft=class{middlewareStack=Ks();schema;static classBuilder(){return new PR}resolveMiddlewareWithContext(e,r,n,{middlewareFn:s,clientName:o,commandName:i,inputFilterSensitiveLog:a,outputFilterSensitiveLog:c,smithyContext:u,additionalContext:p,CommandCtor:d}){for(let I of s.bind(this)(d,e,r,n))this.middlewareStack.use(I);let m=e.concat(this.middlewareStack),{logger:g}=r,E=p[vR.SMITHY_CONTEXT_KEY],_={logger:g,clientName:o,commandName:i,inputFilterSensitiveLog:a,outputFilterSensitiveLog:c,...p,[vR.SMITHY_CONTEXT_KEY]:{...E,commandInstance:this,...u,...n?.metricsRecorder===void 0?{}:{metricsRecorder:n.metricsRecorder}}},{requestHandler:R}=r,T=n??{};return T.metricsRecorder&&(T={...T},delete T.metricsRecorder),u.eventStream&&(T={isEventStream:!0,...T}),m.resolve(I=>R.handle(I.request,T),_)}},PR=class{_init=()=>{};_ep={};_middlewareFn=()=>[];_commandName="";_clientName="";_additionalContext={};_smithyContext={};_inputFilterSensitiveLog=void 0;_outputFilterSensitiveLog=void 0;_serializer=null;_deserializer=null;_operationSchema;init(e){this._init=e}ep(e){return this._ep=e,this}m(e){return this._middlewareFn=e,this}s(e,r,n={}){return this._smithyContext={service:e,operation:r,...n},this}c(e={}){return this._additionalContext=e,this}n(e,r){return this._clientName=e,this._commandName=r,this}f(e=n=>n,r=n=>n){return this._inputFilterSensitiveLog=e,this._outputFilterSensitiveLog=r,this}ser(e){return this._serializer=e,this}de(e){return this._deserializer=e,this}sc(e){return this._operationSchema=e,this._smithyContext.operationSchema=e,this}build(){let e=this,r;return r=class extends Ft{input;static getEndpointParameterInstructions(){return e._ep}constructor(...[n]){super(),this.input=n??{},e._init(this),this.schema=e._operationSchema}resolveMiddleware(n,s,o){let i=e._operationSchema,a=i?.[4]??i?.input,c=i?.[5]??i?.output;return this.resolveMiddlewareWithContext(n,s,o,{CommandCtor:r,middlewareFn:e._middlewareFn,clientName:e._clientName,commandName:e._commandName,inputFilterSensitiveLog:e._inputFilterSensitiveLog??(i?Ji.bind(null,a):u=>u),outputFilterSensitiveLog:e._outputFilterSensitiveLog??(i?Ji.bind(null,c):u=>u),smithyContext:e._smithyContext,additionalContext:e._additionalContext})}serialize=e._serializer;deserialize=e._deserializer}}}});var gD,SD=f(()=>{gD="***SensitiveInformation***"});var An,ED=f(()=>{An=(t,e,r)=>{for(let[o,i]of Object.entries(t)){let a=async function(u,p,d){let m=new i(u);if(typeof p=="function")this.send(m,p);else if(typeof d=="function"){if(typeof p!="object")throw new Error(`Expected http options but got ${typeof p}`);this.send(m,p||{},d)}else return this.send(m,p)},c=(o[0].toLowerCase()+o.slice(1)).replace(/Command$/,"");e.prototype[c]=a}let{paginators:n={},waiters:s={}}=r??{};for(let[o,i]of Object.entries(n))e.prototype[o]===void 0&&(e.prototype[o]=function(a={},c,...u){return i({...c,client:this},a,...u)});for(let[o,i]of Object.entries(s))e.prototype[o]===void 0&&(e.prototype[o]=async function(a={},c,...u){let p=c;return typeof c=="number"&&(p={maxWaitTime:c}),i({...p,client:this},a,...u)})}});var yr,Qo,kR=f(()=>{yr=class t extends Error{static shapeId="smithy.ts.sdk.synthetic.nonamespace.client#ServiceException";$fault;$response;$retryable;$metadata;constructor(e){super(e.message),Object.setPrototypeOf(this,Object.getPrototypeOf(this).constructor.prototype),this.name=e.name,this.$fault=e.$fault,this.$metadata=e.$metadata}static isInstance(e){if(!e)return!1;let r=e;return t.prototype.isPrototypeOf(r)||!!r.$fault&&!!r.$metadata&&(r.$fault==="client"||r.$fault==="server")}static[Symbol.hasInstance](e){if(!e)return!1;let r=e;if(this===t)return t.isInstance(e);if(t.isInstance(e)){if(this.prototype.isPrototypeOf(e))return!0;let n=Object.prototype.hasOwnProperty.call(this,"shapeId")?this.shapeId:void 0,s=!1;if(n){let i=Object.getPrototypeOf(r);for(;i&&i!==Object.prototype;){let a=i.constructor,c=a!==t&&Object.prototype.hasOwnProperty.call(a,"shapeId")?a?.shapeId:void 0;if(c&&(s=!0,c===n))return!0;i=Object.getPrototypeOf(i)}}if(n&&s)return!1;let o=this.name;if(o&&o.length>=6){if(r.name===o)return!0;let i=Object.getPrototypeOf(r);for(;i&&i!==Object.prototype;){let a=i.constructor?.name;if(a&&a!=="Error"&&a===o)return!0;i=Object.getPrototypeOf(i)}}}return!1}},Qo=(t,e={})=>{Object.entries(e).filter(([,n])=>n!==void 0).forEach(([n,s])=>{(t[n]==null||t[n]==="")&&(t[n]=s)});let r=t.message||t.Message||"UnknownError";return t.message=r,delete t.Message,t}});var MR,yD,RX,_D=f(()=>{kR();MR=({output:t,parsedBody:e,exceptionCtor:r,errorCode:n})=>{let s=RX(t),o=s.httpStatusCode?s.httpStatusCode+"":void 0,i=new r({name:e?.code||e?.Code||n||o||"UnknownError",$fault:"client",$metadata:s});throw Qo(i,e)},yD=t=>({output:e,parsedBody:r,errorCode:n})=>{MR({output:e,parsedBody:r,exceptionCtor:t,errorCode:n})},RX=t=>({httpStatusCode:t.statusCode,requestId:t.headers["x-amzn-requestid"]??t.headers["x-amzn-request-id"]??t.headers["x-amz-request-id"],extendedRequestId:t.headers["x-amz-id-2"],cfId:t.headers["x-amz-cf-id"]})});var In,RD=f(()=>{In=t=>{switch(t){case"standard":return{retryMode:"standard",connectionTimeout:3100};case"in-region":return{retryMode:"standard",connectionTimeout:1100};case"cross-region":return{retryMode:"standard",connectionTimeout:3100};case"mobile":return{retryMode:"standard",connectionTimeout:3e4};default:return{}}}});var TD,xn,AD=f(()=>{TD=!1,xn=t=>{t&&!TD&&parseInt(t.substring(1,t.indexOf(".")))<16&&(TD=!0)}});var Jo,ID,xp,Cp,LR=f(()=>{W();Jo=ye(Hr()),ID=Object.values(Jo.AlgorithmId),xp=t=>{let e=[];for(let r in Jo.AlgorithmId){if(!k(Jo.AlgorithmId,r))continue;let n=Jo.AlgorithmId[r];t[n]!==void 0&&e.push({algorithmId:()=>n,checksumConstructor:()=>t[n]})}for(let[r,n]of Object.entries(t.checksumAlgorithms??{}))e.push({algorithmId:()=>r,checksumConstructor:()=>n});return{addChecksumAlgorithm(r){t.checksumAlgorithms=t.checksumAlgorithms??{};let n=r.algorithmId(),s=r.checksumConstructor();ID.includes(n)?t.checksumAlgorithms[n.toUpperCase()]=s:t.checksumAlgorithms[n]=s,e.push(r)},checksumAlgorithms(){return e}}},Cp=t=>{let e={};return t.checksumAlgorithms().forEach(r=>{let n=r.algorithmId();ID.includes(n)&&(e[n]=r.checksumConstructor())}),e}});var bp,wp,$R=f(()=>{bp=t=>({setRetryStrategy(e){t.retryStrategy=e},retryStrategy(){return t.retryStrategy}}),wp=t=>{let e={};return e.retryStrategy=t.retryStrategy(),e}});var zr,xD,Cn,CD=f(()=>{LR();$R();zr=t=>Object.assign(xp(t),bp(t)),xD=zr,Cn=t=>Object.assign(Cp(t),wp(t))});var bD,wD=f(()=>{bD=t=>Array.isArray(t)?t:[t]});var Xo,DD=f(()=>{W();Xo=t=>{let e="#text";for(let r in t)k(t,r)&&(t[r][e]!==void 0?t[r]=t[r][e]:typeof t[r]=="object"&&t[r]!==null&&(t[r]=Xo(t[r])));return t}});var OD,vD=f(()=>{OD=t=>t!=null});var Qt,PD=f(()=>{Qt=class{trace(){}debug(){}info(){}warn(){}error(){}}});function FR(t,e,r){let n,s,o;if(typeof e>"u"&&typeof r>"u")n={},o=t;else{if(n=t,typeof e=="function")return s=e,o=r,TX(n,s,o);o=e}for(let i in o)if(k(o,i)){if(!Array.isArray(o[i])){n[i]=o[i];continue}MD(n,null,o,i)}return n}var ND,kD,TX,MD,AX,IX,LD=f(()=>{W();ND=t=>{let e={};for(let[r,n]of Object.entries(t||{}))e[r]=[,n];return e},kD=(t,e)=>{let r={};for(let n in e)k(e,n)&&MD(r,t,e,n);return r},TX=(t,e,r)=>FR(t,Object.entries(r).reduce((n,[s,o])=>(Array.isArray(o)?n[s]=o:typeof o=="function"?n[s]=[e,o()]:n[s]=[e,o],n),{})),MD=(t,e,r,n)=>{if(e!==null){let i=r[n];typeof i=="function"&&(i=[,i]);let[a=AX,c=IX,u=n]=i;(typeof a=="function"&&a(e[u])||typeof a!="function"&&a)&&(t[n]=c(e[u]));return}let[s,o]=r[n];if(typeof o=="function"){let i,a=s===void 0&&(i=o())!=null,c=typeof s=="function"&&!!s(void 0)||typeof s!="function"&&!!s;a?t[n]=i:c&&(t[n]=o())}else{let i=s===void 0&&o!=null,a=typeof s=="function"&&!!s(o)||typeof s!="function"&&!!s;(i||a)&&(t[n]=o)}},AX=t=>t!=null,IX=t=>t});var $D,FD,UD=f(()=>{$D=t=>{if(t!==t)return"NaN";switch(t){case 1/0:return"Infinity";case-1/0:return"-Infinity";default:return t}},FD=t=>t.toISOString().replace(".000Z","Z")});var Dp,BD=f(()=>{W();Dp=t=>{if(t==null)return{};if(Array.isArray(t))return t.filter(e=>e!=null).map(Dp);if(typeof t=="object"){let e={};for(let r in t)k(t,r)&&t[r]!=null&&(e[r]=Dp(t[r]));return e}return t}});function bn(t,e,r,n){return function(o,i,a,c,u={}){let p=Object.assign({},t,o);return Ft.classBuilder().ep(p).m(function(d,m,g,E){let _=i.call(this,d,m,g,E);return _.unshift(n(g,d.getEndpointParameterInstructions())),_}).s(e,a,u).n(r,a.charAt(0).toUpperCase()+a.slice(1)+"Command").sc(c).build()}}var GD=f(()=>{NR()});var Ts={};at(Ts,{AlgorithmId:()=>Jo.AlgorithmId,Client:()=>Dt,Command:()=>Ft,NoOpLogger:()=>Qt,SENSITIVE_STRING:()=>gD,ServiceException:()=>yr,WaiterState:()=>ar,_json:()=>Dp,checkExceptions:()=>Bw,constructStack:()=>Ks,convertMap:()=>ND,createAggregatedClient:()=>An,createWaiter:()=>jw,decorateServiceException:()=>Qo,emitWarningIfUnsupportedVersion:()=>xn,getArrayIfSingleItem:()=>bD,getChecksumConfiguration:()=>xp,getDefaultClientConfiguration:()=>xD,getDefaultExtensionConfiguration:()=>zr,getRetryConfiguration:()=>bp,getSmithyContext:()=>he,getValueFromTextNode:()=>Xo,invalidFunction:()=>kw,invalidProvider:()=>Lw,isSerializableHeaderValue:()=>OD,loadConfigsForDefaultMode:()=>In,makeBuilder:()=>bn,map:()=>FR,normalizeProvider:()=>ge,resolveChecksumRuntimeConfig:()=>Cp,resolveDefaultRuntimeConfig:()=>Cn,resolveRetryRuntimeConfig:()=>wp,schemaLogFilter:()=>Ji,serializeDateTime:()=>FD,serializeFloat:()=>$D,take:()=>kD,throwDefaultError:()=>MR,waiterServiceDefaults:()=>Rp,withBaseException:()=>yD});var V=f(()=>{_p();W();W();Mw();$w();qw();Tp();Kw();NR();SD();ED();_D();RD();AD();kR();CD();LR();$R();wD();DD();vD();PD();LD();OR();UD();BD();GD()});var Op,UR=f(()=>{Op=t=>typeof ArrayBuffer=="function"&&t instanceof ArrayBuffer||Object.prototype.toString.call(t)==="[object ArrayBuffer]"});var jr,Qs,Js=f(()=>{UR();jr=(t,e=0,r=t.byteLength-e)=>{if(!Op(t))throw new TypeError(`The "input" argument must be ArrayBuffer. Received type ${typeof t} (${t})`);return Buffer.from(t,e,r)},Qs=(t,e)=>{if(typeof t!="string")throw new TypeError(`The "input" argument must be of type string. Received type ${typeof t} (${t})`);return e?Buffer.from(t,e):Buffer.from(t)}});var xX,Te,HD=f(()=>{Js();xX=/^[A-Za-z0-9+/]*={0,2}$/,Te=t=>{if(t.length*3%4!==0)throw new TypeError("Incorrect padding on base64 string.");if(!xX.exec(t))throw new TypeError("Invalid base64 string.");let e=Qs(t,"base64");return new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}});var tt,vp=f(()=>{Js();tt=t=>{let e=Qs(t,"utf8");return new Uint8Array(e.buffer,e.byteOffset,e.byteLength/Uint8Array.BYTES_PER_ELEMENT)}});var ne,BR=f(()=>{Js();vp();ne=t=>{let e;if(typeof t=="string"?e=tt(t):e=t,typeof e!="object"||typeof e.byteOffset!="number"||typeof e.byteLength!="number")throw new Error("@smithy/util-base64: toBase64 encoder function only accepts string | Uint8Array.");return jr(e.buffer,e.byteOffset,e.byteLength).toString("base64")}});function VD(t,e,r,n){return class Pp extends Uint8Array{static fromString(o,i="utf-8"){if(typeof o=="string")return i==="base64"?Pp.mutate(n(o)):Pp.mutate(e(o));throw new Error(`Unsupported conversion from ${typeof o} to Uint8ArrayBlobAdapter.`)}static mutate(o){return Object.setPrototypeOf(o,Pp.prototype),o}transformToString(o="utf-8"){return o==="base64"?r(this):t(this)}}}var WD=f(()=>{});var _e,zD=f(()=>{Js();_e=t=>{if(typeof t=="string")return t;if(typeof t!="object"||typeof t.byteOffset!="number"||typeof t.byteLength!="number")throw new Error("@smithy/util-utf8: toUtf8 encoder function only accepts string | Uint8Array.");return jr(t.buffer,t.byteOffset,t.byteLength).toString("utf8")}});function jD(t){return typeof crypto<"u"&&typeof crypto.randomUUID=="function"?()=>crypto.randomUUID():()=>{let e=new Uint8Array(16);return t(e),e[6]=e[6]&15|64,e[8]=e[8]&63|128,Ot[e[0]]+Ot[e[1]]+Ot[e[2]]+Ot[e[3]]+"-"+Ot[e[4]]+Ot[e[5]]+"-"+Ot[e[6]]+Ot[e[7]]+"-"+Ot[e[8]]+Ot[e[9]]+"-"+Ot[e[10]]+Ot[e[11]]+Ot[e[12]]+Ot[e[13]]+Ot[e[14]]+Ot[e[15]]}}var Ot,qD=f(()=>{Ot=Array.from({length:256},(t,e)=>e.toString(16).padStart(2,"0"))});var KD,YD=f(()=>{KD=(t,e,r=n=>n)=>t});var QD,JD,Xi,CX,lu,Zi,XD,Np,kp,Mp,GR,bX,ZD,HR,eO,$p,du,tO,Fp,wX,ta,Up,rO,nO,sO,oO,VR,iO,aO,Xs,Bp,Lp,ea,WR=f(()=>{W();QD=t=>{switch(t){case"true":return!0;case"false":return!1;default:throw new Error(`Unable to parse boolean value "${t}"`)}},JD=t=>{if(t!=null){if(typeof t=="number"){if((t===0||t===1)&&ea.warn(Lp(`Expected boolean, got ${typeof t}: ${t}`)),t===0)return!1;if(t===1)return!0}if(typeof t=="string"){let e=t.toLowerCase();if((e==="false"||e==="true")&&ea.warn(Lp(`Expected boolean, got ${typeof t}: ${t}`)),e==="false")return!1;if(e==="true")return!0}if(typeof t=="boolean")return t;throw new TypeError(`Expected boolean, got ${typeof t}: ${t}`)}},Xi=t=>{if(t!=null){if(typeof t=="string"){let e=parseFloat(t);if(!Number.isNaN(e))return String(e)!==String(t)&&ea.warn(Lp(`Expected number but observed string: ${t}`)),e}if(typeof t=="number")return t;throw new TypeError(`Expected number, got ${typeof t}: ${t}`)}},CX=Math.ceil(2**127*(2-2**-23)),lu=t=>{let e=Xi(t);if(e!==void 0&&!Number.isNaN(e)&&e!==1/0&&e!==-1/0&&Math.abs(e)>CX)throw new TypeError(`Expected 32-bit float, got ${t}`);return e},Zi=t=>{if(t!=null){if(Number.isInteger(t)&&!Number.isNaN(t))return t;throw new TypeError(`Expected integer, got ${typeof t}: ${t}`)}},XD=Zi,Np=t=>GR(t,32),kp=t=>GR(t,16),Mp=t=>GR(t,8),GR=(t,e)=>{let r=Zi(t);if(r!==void 0&&bX(r,e)!==r)throw new TypeError(`Expected ${e}-bit integer, got ${t}`);return r},bX=(t,e)=>{switch(e){case 32:return Int32Array.of(t)[0];case 16:return Int16Array.of(t)[0];case 8:return Int8Array.of(t)[0]}},ZD=(t,e)=>{if(t==null)throw e?new TypeError(`Expected a non-null value for ${e}`):new TypeError("Expected a non-null value");return t},HR=t=>{if(t==null)return;if(typeof t=="object"&&!Array.isArray(t))return t;let e=Array.isArray(t)?"array":typeof t;throw new TypeError(`Expected object, got ${e}: ${t}`)},eO=t=>{if(t!=null){if(typeof t=="string")return t;if(["boolean","number","bigint"].includes(typeof t))return ea.warn(Lp(`Expected string, got ${typeof t}: ${t}`)),String(t);throw new TypeError(`Expected string, got ${typeof t}: ${t}`)}},$p=t=>{if(t==null)return;let e=HR(t),r=[];for(let n in e)k(e,n)&&e[n]!=null&&r.push(n);if(r.length===0)throw new TypeError("Unions must have exactly one non-null member. None were found.");if(r.length>1)throw new TypeError(`Unions must have exactly one non-null member. Keys ${r} were not null.`);return e},du=t=>Xi(typeof t=="string"?ta(t):t),tO=du,Fp=t=>lu(typeof t=="string"?ta(t):t),wX=/(-?(?:0|[1-9]\d*)(?:\.\d+)?(?:[eE][+-]?\d+)?)|(-?Infinity)|(NaN)/g,ta=t=>{let e=t.match(wX);if(e===null||e[0].length!==t.length)throw new TypeError("Expected real number, got implicit NaN");return parseFloat(t)},Up=t=>typeof t=="string"?oO(t):Xi(t),rO=Up,nO=Up,sO=t=>typeof t=="string"?oO(t):lu(t),oO=t=>{switch(t){case"NaN":return NaN;case"Infinity":return 1/0;case"-Infinity":return-1/0;default:throw new Error(`Unable to parse float value: ${t}`)}},VR=t=>Zi(typeof t=="string"?ta(t):t),iO=VR,aO=t=>Np(typeof t=="string"?ta(t):t),Xs=t=>kp(typeof t=="string"?ta(t):t),Bp=t=>Mp(typeof t=="string"?ta(t):t),Lp=t=>String(new TypeError(t).stack||t).split(`
10
+ `).slice(0,5).filter(e=>!e.includes("stackTraceWarning")).join(`
11
+ `),ea={warn:console.warn}});function yt(t){let e=t.getUTCFullYear(),r=t.getUTCMonth(),n=t.getUTCDay(),s=t.getUTCDate(),o=t.getUTCHours(),i=t.getUTCMinutes(),a=t.getUTCSeconds(),c=s<10?`0${s}`:`${s}`,u=o<10?`0${o}`:`${o}`,p=i<10?`0${i}`:`${i}`,d=a<10?`0${a}`:`${a}`;return`${DX[n]}, ${c} ${jR[r]} ${e} ${u}:${p}:${d} GMT`}var DX,jR,OX,cO,vX,Dn,PX,NX,kX,_r,On,pu,MX,LX,$X,zR,FX,UX,BX,wn,GX,HX,ra,uO=f(()=>{WR();DX=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],jR=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];OX=new RegExp(/^(\d{4})-(\d{2})-(\d{2})[tT](\d{2}):(\d{2}):(\d{2})(?:\.(\d+))?[zZ]$/),cO=t=>{if(t==null)return;if(typeof t!="string")throw new TypeError("RFC-3339 date-times must be expressed as strings");let e=OX.exec(t);if(!e)throw new TypeError("Invalid RFC-3339 date-time value");let[r,n,s,o,i,a,c,u]=e,p=Xs(ra(n)),d=wn(s,"month",1,12),m=wn(o,"day",1,31);return pu(p,d,m,{hours:i,minutes:a,seconds:c,fractionalMilliseconds:u})},vX=new RegExp(/^(\d{4})-(\d{2})-(\d{2})[tT](\d{2}):(\d{2}):(\d{2})(?:\.(\d+))?(([-+]\d{2}:\d{2})|[zZ])$/),Dn=t=>{if(t==null)return;if(typeof t!="string")throw new TypeError("RFC-3339 date-times must be expressed as strings");let e=vX.exec(t);if(!e)throw new TypeError("Invalid RFC-3339 date-time value");let[r,n,s,o,i,a,c,u,p]=e,d=Xs(ra(n)),m=wn(s,"month",1,12),g=wn(o,"day",1,31),E=pu(d,m,g,{hours:i,minutes:a,seconds:c,fractionalMilliseconds:u});return p.toUpperCase()!="Z"&&E.setTime(E.getTime()-HX(p)),E},PX=new RegExp(/^(?:Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d{2}) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d{1,2}):(\d{2}):(\d{2})(?:\.(\d+))? GMT$/),NX=new RegExp(/^(?:Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday), (\d{2})-(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)-(\d{2}) (\d{1,2}):(\d{2}):(\d{2})(?:\.(\d+))? GMT$/),kX=new RegExp(/^(?:Mon|Tue|Wed|Thu|Fri|Sat|Sun) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ( [1-9]|\d{2}) (\d{1,2}):(\d{2}):(\d{2})(?:\.(\d+))? (\d{4})$/),_r=t=>{if(t==null)return;if(typeof t!="string")throw new TypeError("RFC-7231 date-times must be expressed as strings");let e=PX.exec(t);if(e){let[r,n,s,o,i,a,c,u]=e;return pu(Xs(ra(o)),zR(s),wn(n,"day",1,31),{hours:i,minutes:a,seconds:c,fractionalMilliseconds:u})}if(e=NX.exec(t),e){let[r,n,s,o,i,a,c,u]=e;return $X(pu(MX(o),zR(s),wn(n,"day",1,31),{hours:i,minutes:a,seconds:c,fractionalMilliseconds:u}))}if(e=kX.exec(t),e){let[r,n,s,o,i,a,c,u]=e;return pu(Xs(ra(u)),zR(n),wn(s.trimLeft(),"day",1,31),{hours:o,minutes:i,seconds:a,fractionalMilliseconds:c})}throw new TypeError("Invalid RFC-7231 date-time value")},On=t=>{if(t==null)return;let e;if(typeof t=="number")e=t;else if(typeof t=="string")e=du(t);else if(typeof t=="object"&&t.tag===1)e=t.value;else throw new TypeError("Epoch timestamps must be expressed as floating point numbers or their string representation");if(Number.isNaN(e)||e===1/0||e===-1/0)throw new TypeError("Epoch timestamps must be valid, non-Infinite, non-NaN numerics");return new Date(Math.round(e*1e3))},pu=(t,e,r,n)=>{let s=e-1;return UX(t,s,r),new Date(Date.UTC(t,s,r,wn(n.hours,"hour",0,23),wn(n.minutes,"minute",0,59),wn(n.seconds,"seconds",0,60),GX(n.fractionalMilliseconds)))},MX=t=>{let e=new Date().getUTCFullYear(),r=Math.floor(e/100)*100+Xs(ra(t));return r<e?r+100:r},LX=50*365*24*60*60*1e3,$X=t=>t.getTime()-new Date().getTime()>LX?new Date(Date.UTC(t.getUTCFullYear()-100,t.getUTCMonth(),t.getUTCDate(),t.getUTCHours(),t.getUTCMinutes(),t.getUTCSeconds(),t.getUTCMilliseconds())):t,zR=t=>{let e=jR.indexOf(t);if(e<0)throw new TypeError(`Invalid month: ${t}`);return e+1},FX=[31,28,31,30,31,30,31,31,30,31,30,31],UX=(t,e,r)=>{let n=FX[e];if(e===1&&BX(t)&&(n=29),r>n)throw new TypeError(`Invalid day for ${jR[e]} in ${t}: ${r}`)},BX=t=>t%4===0&&(t%100!==0||t%400===0),wn=(t,e,r,n)=>{let s=Bp(ra(t));if(s<r||s>n)throw new TypeError(`${e} must be between ${r} and ${n}, inclusive`);return s},GX=t=>t==null?0:Fp("0."+t)*1e3,HX=t=>{let e=t[0],r=1;if(e=="+")r=1;else if(e=="-")r=-1;else throw new TypeError(`Offset direction, ${e}, must be "+" or "-"`);let n=Number(t.substring(1,3)),s=Number(t.substring(4,6));return r*(n*60+s)*60*1e3},ra=t=>{let e=0;for(;e<t.length-1&&t.charAt(e)==="0";)e++;return e===0?t:t.slice(e)}});var Se,lO=f(()=>{Se=function(e){return Object.assign(new String(e),{deserializeJSON(){return JSON.parse(String(e))},toString(){return String(e)},toJSON(){return String(e)}})};Se.from=t=>t&&typeof t=="object"&&(t instanceof Se||"deserializeJSON"in t)?t:typeof t=="string"||Object.getPrototypeOf(t)===String.prototype?Se(String(t)):Se(JSON.stringify(t));Se.fromObject=Se.from});function Gp(t){return(t.includes(",")||t.includes('"'))&&(t=`"${t.replace(/"/g,'\\"')}"`),t}var dO=f(()=>{});function As(t,e,r){let n=Number(t);if(n<e||n>r)throw new Error(`Value ${n} out of range [${e}, ${r}]`)}var qR,KR,YR,pO,fO,VX,WX,zX,jX,qX,Zs,Hp,Vp,mO=f(()=>{qR="(?:Mon|Tue|Wed|Thu|Fri|Sat|Sun)(?:[ne|u?r]?s?day)?",KR="(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)",YR="(\\d?\\d):(\\d{2}):(\\d{2})(?:\\.(\\d+))?",pO="(\\d?\\d)",fO="(\\d{4})",VX=new RegExp(/^(\d{4})-(\d\d)-(\d\d)[tT](\d\d):(\d\d):(\d\d)(\.(\d+))?(([-+]\d\d:\d\d)|[zZ])$/),WX=new RegExp(`^${qR}, ${pO} ${KR} ${fO} ${YR} GMT$`),zX=new RegExp(`^${qR}, ${pO}-${KR}-(\\d\\d) ${YR} GMT$`),jX=new RegExp(`^${qR} ${KR} ( [1-9]|\\d\\d) ${YR} ${fO}$`),qX=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],Zs=t=>{if(t==null)return;let e=NaN;if(typeof t=="number")e=t;else if(typeof t=="string"){if(!/^-?\d*\.?\d+$/.test(t))throw new TypeError("parseEpochTimestamp - numeric string invalid.");e=Number.parseFloat(t)}else typeof t=="object"&&t.tag===1&&(e=t.value);if(isNaN(e)||Math.abs(e)===1/0)throw new TypeError("Epoch timestamps must be valid finite numbers.");return new Date(Math.round(e*1e3))},Hp=t=>{if(t==null)return;if(typeof t!="string")throw new TypeError("RFC3339 timestamps must be strings");let e=VX.exec(t);if(!e)throw new TypeError(`Invalid RFC3339 timestamp format ${t}`);let[,r,n,s,o,i,a,,c,u]=e;As(n,1,12),As(s,1,31),As(o,0,23),As(i,0,59),As(a,0,60);let p=new Date(Date.UTC(Number(r),Number(n)-1,Number(s),Number(o),Number(i),Number(a),Number(c)?Math.round(parseFloat(`0.${c}`)*1e3):0));if(p.setUTCFullYear(Number(r)),u.toUpperCase()!="Z"){let[,d,m,g]=/([+-])(\d\d):(\d\d)/.exec(u)||[void 0,"+",0,0],E=d==="-"?1:-1;p.setTime(p.getTime()+E*(Number(m)*60*60*1e3+Number(g)*60*1e3))}return p},Vp=t=>{if(t==null)return;if(typeof t!="string")throw new TypeError("RFC7231 timestamps must be strings.");let e,r,n,s,o,i,a,c;if((c=WX.exec(t))?[,e,r,n,s,o,i,a]=c:(c=zX.exec(t))?([,e,r,n,s,o,i,a]=c,n=(Number(n)+1900).toString()):(c=jX.exec(t))&&([,r,e,s,o,i,a,n]=c),n&&i){let u=Date.UTC(Number(n),qX.indexOf(r),Number(e),Number(s),Number(o),Number(i),a?Math.round(parseFloat(`0.${a}`)*1e3):0);As(e,1,31),As(s,0,23),As(o,0,59),As(i,0,60);let p=new Date(u);return p.setUTCFullYear(Number(n)),p}throw new TypeError(`Invalid RFC7231 date-time value ${t}.`)}});function Wp(t,e,r){if(r<=0||!Number.isInteger(r))throw new Error("Invalid number of delimiters ("+r+") for splitEvery.");let n=t.split(e);if(r===1)return n;let s=[],o="";for(let i=0;i<n.length;i++)o===""?o=n[i]:o+=e+n[i],(i+1)%r===0&&(s.push(o),o="");return o!==""&&s.push(o),s}var hO=f(()=>{});var na,gO=f(()=>{na=t=>{let e=t.length,r=[],n=!1,s,o=0;for(let i=0;i<e;++i){let a=t[i];switch(a){case'"':s!=="\\"&&(n=!n);break;case",":n||(r.push(t.slice(o,i)),o=i+1);break;default:}s=a}return r.push(t.slice(o)),r.map(i=>{i=i.trim();let a=i.length;return a<2?i:(i[0]==='"'&&i[a-1]==='"'&&(i=i.slice(1,a-1)),i.replace(/\\"/g,'"'))})}});function zp(t){return new $(String(t),"bigDecimal")}var SO,$,EO=f(()=>{SO=/^-?((0|[1-9]\d*)(\.\d+)?|\.\d+)([eE][+-]?\d+)?$/,$=class t{string;type;constructor(e,r){if(this.string=e,this.type=r,!SO.test(e))throw new Error(`@smithy/core/serde - NumericValue string must conform to the Smithy bigDecimal format. Received: "${e}"`)}toString(){return this.string}static[Symbol.hasInstance](e){if(!e||typeof e!="object")return!1;let r=e;return t.prototype.isPrototypeOf(e)||r.type==="bigDecimal"&&SO.test(r.string)}}});function jp(t){if(t.length%2!==0)throw new Error("Hex encoded strings must have an even number length");let e=new Uint8Array(t.length/2);for(let r=0;r<t.length;r+=2){let n=t.slice(r,r+2).toLowerCase();if(n in QR)e[r/2]=QR[n];else throw new Error(`Cannot decode unrecognized sequence ${n} as hexadecimal`)}return e}function Rr(t){let e="";for(let r=0;r<t.byteLength;r++)e+=yO[t[r]];return e}var yO,QR,JR=f(()=>{yO={},QR={};for(let t=0;t<256;t++){let e=t.toString(16).toLowerCase();e.length===1&&(e=`0${e}`),yO[t]=e,QR[e]=t}});var sa,vn,_O=f(()=>{sa=require("node:fs"),vn=t=>{if(!t)return 0;if(typeof t=="string")return Buffer.byteLength(t);if(typeof t.byteLength=="number")return t.byteLength;if(typeof t.size=="number")return t.size;if(typeof t.start=="number"&&typeof t.end=="number")return t.end+1-t.start;if(t instanceof sa.ReadStream){if(t.path!=null)return(0,sa.lstatSync)(t.path).size;if(typeof t.fd=="number")return(0,sa.fstatSync)(t.fd).size}throw new Error(`Body Length computation failed for ${t}`)}});var Ut,XR=f(()=>{vp();Ut=t=>t instanceof Uint8Array?t:typeof t=="string"?tt(t):ArrayBuffer.isView(t)?new Uint8Array(t.buffer,t.byteOffset,t.byteLength/Uint8Array.BYTES_PER_ELEMENT):new Uint8Array(t)});function Pn(t,e){if(e===void 0){e=0;for(let s of t)e+=s.byteLength}let r=new Uint8Array(e),n=0;for(let s of t)r.set(s,n),n+=s.byteLength;return r}var fu=f(()=>{});var qp,ZR,e0=f(()=>{W();qp=(t,e)=>(r,n)=>async s=>{let{response:o}=await r(s);try{let i=await e(o,t);return{response:o,output:i}}catch(i){if(Object.defineProperty(i,"$response",{value:o,enumerable:!1,writable:!1,configurable:!1}),!("$metadata"in i)){let a="Deserialization error: to see the raw response, inspect the hidden field {error}.$response on this object.";try{i.message+=`
12
+ `+a}catch{!n.logger||n.logger?.constructor?.name==="NoOpLogger"?console.warn(a):n.logger?.warn?.(a)}typeof i.$responseBodyText<"u"&&i.$response&&(i.$response.body=i.$responseBodyText);try{if(ct.isInstance(o)){let{headers:c={}}=o,u=Object.entries(c);i.$metadata={httpStatusCode:o.statusCode,requestId:ZR(/^x-[\w-]+-request-?id$/,u),extendedRequestId:ZR(/^x-[\w-]+-id-2$/,u),cfId:ZR(/^x-[\w-]+-cf-id$/,u)}}}catch{}}throw i}},ZR=(t,e)=>(e.find(([r])=>r.match(t))||[void 0,void 0])[1]});var cr,mu=f(()=>{cr=class t extends Error{name="ProviderError";tryNextLink;constructor(e,r=!0){let n,s=!0;typeof r=="boolean"?(n=void 0,s=r):r!=null&&typeof r=="object"&&(n=r.logger,s=r.tryNextLink??!0),super(e),this.tryNextLink=s,Object.setPrototypeOf(this,t.prototype),n?.debug?.(`@smithy/property-provider ${s?"->":"(!)"} ${e}`)}static from(e,r=!0){return Object.assign(new this(e.message,r),e)}}});var eo,Kp=f(()=>{mu();eo=class t extends cr{name="CredentialsProviderError";constructor(e,r=!0){super(e,r),Object.setPrototypeOf(this,t.prototype)}}});var Yp,RO=f(()=>{mu();Yp=class t extends cr{name="TokenProviderError";constructor(e,r=!0){super(e,r),Object.setPrototypeOf(this,t.prototype)}}});var Qp,t0=f(()=>{mu();Qp=(...t)=>async()=>{if(t.length===0)throw new cr("No providers in chain");let e;for(let r of t)try{return await r()}catch(n){if(e=n,n?.tryNextLink)continue;throw n}throw e}});var Jp,r0=f(()=>{Jp=t=>()=>Promise.resolve(t)});var oa,Xp=f(()=>{oa=(t,e,r)=>{let n,s,o,i=!1,a=async()=>{s||(s=t());try{n=await s,o=!0,i=!1}finally{s=void 0}return n};return e===void 0?async c=>((!o||c?.forceRefresh)&&(n=await a()),n):async c=>((!o||c?.forceRefresh)&&(n=await a()),i?n:r&&!r(n)?(i=!0,n):(e(n)&&await a(),n))}});var ut,Zp=f(()=>{ut=(t,e,r)=>{if(e in t){if(t[e]==="true")return!0;if(t[e]==="false")return!1;throw new Error(`Cannot load ${r} "${e}". Expected "true" or "false", got ${t[e]}.`)}}});var TO,AO=f(()=>{TO=(t,e,r)=>{if(!(e in t))return;let n=parseInt(t[e],10);if(Number.isNaN(n))throw new TypeError(`Cannot load ${r} '${e}'. Expected number, got '${t[e]}'.`);return n}});var We,ef=f(()=>{(function(t){t.ENV="env",t.CONFIG="shared config entry"})(We||(We={}))});var IO,xO,n0,KX,Nn,ia=f(()=>{IO=require("node:os"),xO=require("node:path"),n0={},KX=()=>process&&process.geteuid?`${process.geteuid()}`:"DEFAULT",Nn=()=>{let{HOME:t,USERPROFILE:e,HOMEPATH:r,HOMEDRIVE:n=`C:${xO.sep}`}=process.env;if(t)return t;if(e)return e;if(r)return`${n}${r}`;let s=KX();return n0[s]||(n0[s]=(0,IO.homedir)()),n0[s]}});var s0,o0,tf,i0=f(()=>{s0="AWS_PROFILE",o0="default",tf=t=>t.profile||process.env[s0]||o0});var CO,bO,rf,a0=f(()=>{CO=require("node:crypto"),bO=require("node:path");ia();rf=t=>{let r=(0,CO.createHash)("sha1").update(t).digest("hex");return(0,bO.join)(Nn(),".aws","sso","cache",`${r}.json`)}});var wO,hu,DO,c0=f(()=>{wO=require("node:fs/promises");a0();hu={},DO=async t=>{if(hu[t])return hu[t];let e=rf(t),r=await(0,wO.readFile)(e,"utf8");return JSON.parse(r)}});var kn,OO=f(()=>{kn="."});var u0,vO,PO=f(()=>{u0=ye(Hr()),vO=t=>Object.entries(t).filter(([e])=>{let r=e.indexOf(".");return r===-1?!1:Object.values(u0.IniSectionType).includes(e.substring(0,r))}).reduce((e,[r,n])=>{let s=r.indexOf("."),o=r.substring(0,s)===u0.IniSectionType.PROFILE?r.substring(s+1):r;return e[o]=n,e},{...t.default&&{default:t.default}})});var NO,YX,nf,l0=f(()=>{NO=require("node:path");ia();YX="AWS_CONFIG_FILE",nf=()=>process.env[YX]||(0,NO.join)(Nn(),".aws","config")});var kO,QX,MO,LO=f(()=>{kO=require("node:path");ia();QX="AWS_SHARED_CREDENTIALS_FILE",MO=()=>process.env[QX]||(0,kO.join)(Nn(),".aws","credentials")});var $O,JX,XX,gu,d0=f(()=>{$O=ye(Hr()),JX=/^([\w-]+)\s(["'])?([\w-@+.%:/]+)\2$/,XX=["__proto__","profile __proto__"],gu=t=>{let e={},r,n;for(let s of t.split(/\r?\n/)){let o=s.split(/(^|\s)[;#]/)[0].trim();if(o[0]==="["&&o[o.length-1]==="]"){r=void 0,n=void 0;let a=o.substring(1,o.length-1),c=JX.exec(a);if(c){let[,u,,p]=c;Object.values($O.IniSectionType).includes(u)&&(r=[u,p].join("."))}else r=a;if(XX.includes(a))throw new Error(`Found invalid profile name "${a}"`)}else if(r){let a=o.indexOf("=");if(![0,-1].includes(a)){let[c,u]=[o.substring(0,a).trim(),o.substring(a+1).trim()];if(u==="")n=c;else{n&&s.trimStart()===s&&(n=void 0),e[r]=e[r]||{};let p=n?[n,c].join("."):c;e[r][p]=u}}}}return e}});var FO,p0,Su,Zo,Eu=f(()=>{FO=require("node:fs/promises"),p0={},Su={},Zo=(t,e)=>Su[t]!==void 0?Su[t]:((!p0[t]||e?.ignoreCache)&&(p0[t]=(0,FO.readFile)(t,"utf8")),p0[t])});var f0,UO,aa,sf=f(()=>{f0=require("node:path");PO();l0();LO();ia();d0();Eu();UO=()=>({}),aa=async(t={})=>{let{filepath:e=MO(),configFilepath:r=nf()}=t,n=Nn(),s="~/",o=e;e.startsWith(s)&&(o=(0,f0.join)(n,e.slice(2)));let i=r;r.startsWith(s)&&(i=(0,f0.join)(n,r.slice(2)));let a=await Promise.all([Zo(i,{ignoreCache:t.ignoreCache}).then(gu).then(vO).catch(UO),Zo(o,{ignoreCache:t.ignoreCache}).then(gu).catch(UO)]);return{configFile:a[0],credentialsFile:a[1]}}});var BO,GO,HO=f(()=>{BO=ye(Hr()),GO=t=>Object.entries(t).filter(([e])=>e.startsWith(BO.IniSectionType.SSO_SESSION+".")).reduce((e,[r,n])=>({...e,[r.substring(r.indexOf(".")+1)]:n}),{})});var ZX,VO,WO=f(()=>{l0();HO();d0();Eu();ZX=()=>({}),VO=async(t={})=>Zo(t.configFilepath??nf()).then(gu).then(GO).catch(ZX)});var zO,jO=f(()=>{zO=(...t)=>{let e={};for(let r of t)for(let[n,s]of Object.entries(r))e[n]!==void 0?Object.assign(e[n],s):e[n]=s;return e}});var qO,KO=f(()=>{sf();jO();qO=async t=>{let e=await aa(t);return zO(e.configFile,e.credentialsFile)}});var YO,QO=f(()=>{c0();Eu();YO={getFileRecord(){return Su},interceptFile(t,e){Su[t]=Promise.resolve(e)},getTokenRecord(){return hu},interceptToken(t,e){hu[t]=e}}});function of(t){try{let e=new Set(Array.from(t.match(/([A-Z_]){3,}/g)??[]));return e.delete("CONFIG"),e.delete("CONFIG_PREFIX_SEPARATOR"),e.delete("ENV"),[...e].join(", ")}catch{return t}}var m0=f(()=>{});var JO,XO=f(()=>{Kp();m0();JO=(t,e)=>async()=>{try{let r=t(process.env,e);if(r===void 0)throw new Error;return r}catch(r){throw new eo(r.message||`Not found in ENV: ${of(t.toString())}`,{logger:e?.logger})}}});var ZO,ev=f(()=>{Kp();i0();sf();m0();ZO=(t,{preferredFile:e="config",...r}={})=>async()=>{let n=tf(r),{configFile:s,credentialsFile:o}=await aa(r),i=o[n]||{},a=s[n]||{},c=e==="config"?{...i,...a}:{...a,...i};try{let p=t(c,e==="config"?s:o);if(p===void 0)throw new Error;return p}catch(u){throw new eo(u.message||`Not found in config files w/ profile [${n}]: ${of(t.toString())}`,{logger:r.logger})}}});var eZ,af,h0=f(()=>{r0();eZ=t=>typeof t=="function",af=t=>eZ(t)?async()=>await t():Jp(t)});var q,g0=f(()=>{t0();Xp();XO();ev();h0();q=({environmentVariableSelector:t,configFileSelector:e,default:r},n={})=>{let{signingName:s,logger:o}=n;return oa(Qp(JO(t,{signingName:s,logger:o}),ZO(e,n),af(r)))}});var cf,uf,tv,Mn,rv,nv=f(()=>{Zp();ef();cf="AWS_USE_DUALSTACK_ENDPOINT",uf="use_dualstack_endpoint",tv=!1,Mn={environmentVariableSelector:t=>ut(t,cf,We.ENV),configFileSelector:t=>ut(t,uf,We.CONFIG),default:!1},rv={environmentVariableSelector:t=>ut(t,cf,We.ENV),configFileSelector:t=>ut(t,uf,We.CONFIG),default:void 0}});var lf,df,sv,Ln,ov,iv=f(()=>{Zp();ef();lf="AWS_USE_FIPS_ENDPOINT",df="use_fips_endpoint",sv=!1,Ln={environmentVariableSelector:t=>ut(t,lf,We.ENV),configFileSelector:t=>ut(t,df,We.CONFIG),default:!1},ov={environmentVariableSelector:t=>ut(t,lf,We.ENV),configFileSelector:t=>ut(t,df,We.CONFIG),default:void 0}});var av,cv=f(()=>{V();av=t=>{let{tls:e,endpoint:r,urlParser:n,useDualstackEndpoint:s}=t;return Object.assign(t,{tls:e??!0,endpoint:ge(typeof r=="string"?n(r):r),isCustomEndpoint:!0,useDualstackEndpoint:ge(s??!1)})}});var uv,lv=f(()=>{uv=async t=>{let{tls:e=!0}=t,r=await t.region();if(!new RegExp(/^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]{0,61}[a-zA-Z0-9])$/).test(r))throw new Error("Invalid region in client config");let s=await t.useDualstackEndpoint(),o=await t.useFipsEndpoint(),{hostname:i}=await t.regionInfoProvider(r,{useDualstackEndpoint:s,useFipsEndpoint:o})??{};if(!i)throw new Error("Cannot resolve hostname from client config");return t.urlParser(`${e?"https:":"http:"}//${i}`)}});var dv,pv=f(()=>{V();lv();dv=t=>{let e=ge(t.useDualstackEndpoint??!1),{endpoint:r,useFipsEndpoint:n,urlParser:s,tls:o}=t;return Object.assign(t,{tls:o??!0,endpoint:r?ge(typeof r=="string"?s(r):r):()=>uv({...t,useDualstackEndpoint:e,useFipsEndpoint:n}),isCustomEndpoint:!!r,useDualstackEndpoint:e})}});var fv,S0,E0,mv,hv,gv,Sv,Ev,yv,y0=f(()=>{fv="AWS_EXECUTION_ENV",S0="AWS_REGION",E0="AWS_DEFAULT_REGION",mv="AWS_EC2_METADATA_DISABLED",hv=["in-region","cross-region","mobile","standard","legacy"],gv="/latest/meta-data/placement/region",Sv="/latest/api/token",Ev="x-aws-ec2-metadata-token",yv="x-aws-ec2-metadata-token-ttl-seconds"});var _v,tZ,Av,pf,Rv,rZ,Tv,_0=f(()=>{y0();_v=1e3,tZ=6e4,Av=0,pf=async()=>{if(!process.env[mv]&&!(Date.now()<Av))try{let t=rZ(),e=(await Tv({...t,path:Sv,method:"PUT",headers:{[yv]:"21600"}})).toString();return(await Tv({...t,path:gv,method:"GET",headers:{[Ev]:e}})).toString().trim()||Rv()}catch{return Rv()}},Rv=()=>{Av=Date.now()+tZ},rZ=()=>{let t=process.env.AWS_EC2_METADATA_SERVICE_ENDPOINT;if(t){let e=new URL(t);return{hostname:e.hostname.replace(/^\[(.+)]$/,"$1"),port:e.port?Number(e.port):void 0}}return process.env.AWS_EC2_METADATA_SERVICE_ENDPOINT_MODE==="IPv6"?{hostname:"fd00:ec2::254"}:{hostname:"169.254.169.254"}},Tv=async t=>{let{request:e}=await import("node:http");return new Promise((r,n)=>{let s=e({hostname:t.hostname,port:t.port,path:t.path,method:t.method,headers:t.headers,timeout:_v,signal:AbortSignal.timeout(_v)});s.on("error",o=>{n(o),s.destroy()}),s.on("timeout",()=>{n(new Error("TimeoutError from instance metadata service")),s.destroy()}),s.on("response",o=>{let{statusCode:i=400}=o;if(i<200||i>=300){n(Object.assign(new Error("Error response received from instance metadata service"),{statusCode:i})),s.destroy();return}let a=[];o.on("data",c=>a.push(c)),o.on("end",()=>{r(Buffer.concat(a)),s.destroy()})}),s.end()})}});var ca,ua,_t,Bt,R0=f(()=>{_0();ca="AWS_REGION",ua="region",_t={environmentVariableSelector:t=>t[ca],configFileSelector:t=>t[ua],default:async()=>{let t=await pf();if(t)return t;throw new Error("Region is missing")}},Bt={preferredFile:"credentials"}});var Iv,xv,Cv=f(()=>{W();Iv=new Set,xv=(t,e=Vr)=>{if(!Iv.has(t)&&!e(t))if(t==="*")console.warn('@smithy/config-resolver WARN - Please use the caller region instead of "*". See "sigv4a" in https://github.com/aws/aws-sdk-js-v3/blob/main/supplemental-docs/CLIENTS.md.');else throw new Error(`Region not accepted: region="${t}" is not a valid hostname component.`);else Iv.add(t)}});var ff,T0=f(()=>{ff=t=>typeof t=="string"&&(t.startsWith("fips-")||t.endsWith("-fips"))});var bv,wv=f(()=>{T0();bv=t=>ff(t)?["fips-aws-global","aws-fips"].includes(t)?"us-east-1":t.replace(/fips-(dkr-|prod-)?|-fips/,""):t});var ur,Dv=f(()=>{Cv();wv();T0();ur=t=>{let{region:e,useFipsEndpoint:r}=t;if(!e)throw new Error("Region is missing");return Object.assign(t,{region:async()=>{let n=typeof e=="function"?await e():e,s=bv(n);return xv(s),s},useFipsEndpoint:async()=>{let n=typeof e=="string"?e:await e();return ff(n)?!0:typeof r!="function"?Promise.resolve(!!r):r()}})}});var A0,Ov=f(()=>{A0=(t=[],{useFipsEndpoint:e,useDualstackEndpoint:r})=>t.find(({tags:n})=>e===n.includes("fips")&&r===n.includes("dualstack"))?.hostname});var vv,Pv=f(()=>{vv=(t,{regionHostname:e,partitionHostname:r})=>e||(r?r.replace("{region}",t):void 0)});var Nv,kv=f(()=>{Nv=(t,{partitionHash:e})=>Object.keys(e||{}).find(r=>e[r].regions.includes(t))??"aws"});var Mv,Lv=f(()=>{Mv=(t,{signingRegion:e,regionRegex:r,useFipsEndpoint:n})=>{if(e)return e;if(n){let s=r.replace("\\\\","\\").replace(/^\^/g,"\\.").replace(/\$$/g,"\\."),o=t.match(s);if(o)return o[0].slice(1,-1)}}});var $v,Fv=f(()=>{Ov();Pv();kv();Lv();$v=(t,{useFipsEndpoint:e=!1,useDualstackEndpoint:r=!1,signingService:n,regionHash:s,partitionHash:o})=>{let i=Nv(t,{partitionHash:o}),a=t in s?t:o[i]?.endpoint??t,c={useFipsEndpoint:e,useDualstackEndpoint:r},u=A0(s[a]?.variants,c),p=A0(o[i]?.variants,c),d=vv(a,{regionHostname:u,partitionHostname:p});if(d===void 0)throw new Error(`Endpoint resolution failed for: ${{resolvedRegion:a,useFipsEndpoint:e,useDualstackEndpoint:r}}`);let m=Mv(d,{signingRegion:s[a]?.signingRegion,regionRegex:o[i].regionRegex,useFipsEndpoint:e});return{partition:i,signingService:n,hostname:d,...m&&{signingRegion:m},...s[a]?.signingService&&{signingService:s[a].signingService}}}});var nZ,sZ,Uv,Bv=f(()=>{nZ="AWS_DEFAULTS_MODE",sZ="defaults_mode",Uv={environmentVariableSelector:t=>t[nZ],configFileSelector:t=>t[sZ],default:"legacy"}});var $n,oZ,iZ,Gv=f(()=>{R0();_0();g0();Xp();y0();Bv();$n=({region:t=q(_t),defaultsMode:e=q(Uv)}={})=>oa(async()=>{let r=typeof e=="function"?await e():e;switch(r?.toLowerCase()){case"auto":return oZ(t);case"in-region":case"cross-region":case"mobile":case"standard":case"legacy":return Promise.resolve(r?.toLocaleLowerCase());case void 0:return Promise.resolve("legacy");default:throw new Error(`Invalid parameter for "defaultsMode", expect ${hv.join(", ")}, got ${r}`)}}),oZ=async t=>{if(t){let e=typeof t=="function"?await t():t,r=await iZ();return r?e===r?"in-region":"cross-region":"standard"}return"standard"},iZ=async()=>process.env[fv]&&(process.env[S0]||process.env[E0])?process.env[S0]??process.env[E0]:pf()});var Gt={};at(Gt,{CONFIG_PREFIX_SEPARATOR:()=>kn,CONFIG_USE_DUALSTACK_ENDPOINT:()=>uf,CONFIG_USE_FIPS_ENDPOINT:()=>df,CredentialsProviderError:()=>eo,DEFAULT_PROFILE:()=>o0,DEFAULT_USE_DUALSTACK_ENDPOINT:()=>tv,DEFAULT_USE_FIPS_ENDPOINT:()=>sv,ENV_PROFILE:()=>s0,ENV_USE_DUALSTACK_ENDPOINT:()=>cf,ENV_USE_FIPS_ENDPOINT:()=>lf,NODE_REGION_CONFIG_FILE_OPTIONS:()=>Bt,NODE_REGION_CONFIG_OPTIONS:()=>_t,NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS:()=>Mn,NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS:()=>Ln,ProviderError:()=>cr,REGION_ENV_NAME:()=>ca,REGION_INI_NAME:()=>ua,SelectorType:()=>We,TokenProviderError:()=>Yp,booleanSelector:()=>ut,chain:()=>Qp,externalDataInterceptor:()=>YO,fromStatic:()=>af,fromValue:()=>Jp,getHomeDir:()=>Nn,getProfileName:()=>tf,getRegionInfo:()=>$v,getSSOTokenFilepath:()=>rf,getSSOTokenFromFile:()=>DO,loadConfig:()=>q,loadSharedConfigFiles:()=>aa,loadSsoSessionData:()=>VO,memoize:()=>oa,nodeDualstackConfigSelectors:()=>rv,nodeFipsConfigSelectors:()=>ov,numberSelector:()=>TO,parseKnownFiles:()=>qO,readFile:()=>Zo,resolveCustomEndpointsConfig:()=>av,resolveDefaultsModeConfig:()=>$n,resolveEndpointsConfig:()=>dv,resolveRegionConfig:()=>ur});var se=f(()=>{mu();Kp();RO();t0();r0();Xp();Zp();AO();ef();ia();i0();a0();c0();OO();sf();WO();KO();QO();Eu();g0();h0();nv();iv();cv();pv();R0();Dv();Fv();Gv()});var Hv,Vv,Wv,zv=f(()=>{Hv="AWS_ENDPOINT_URL",Vv="endpoint_url",Wv=t=>({environmentVariableSelector:e=>{let r=t.split(" ").map(o=>o.toUpperCase()),n=e[[Hv,...r].join("_")];if(n)return n;let s=e[Hv];if(s)return s},configFileSelector:(e,r)=>{if(e.services){let s=["services",e.services].join(".");if(!r||!r[s])throw new Error(`The services section "${e.services}" specified in the profile is not present in the shared configuration file.`);let o=r[s],i=t.split(" ").map(c=>c.toLowerCase()),a=o[[i.join("_"),Vv].join(".")];if(a)return a}let n=e[Vv];if(n)return n},default:void 0})});var aZ,cZ,jv,qv=f(()=>{se();aZ="AWS_IGNORE_CONFIGURED_ENDPOINT_URLS",cZ="ignore_configured_endpoint_urls",jv={environmentVariableSelector:t=>ut(t,aZ,We.ENV),configFileSelector:t=>ut(t,cZ,We.CONFIG),default:!1}});var yu,Kv=f(()=>{se();zv();qv();yu=async t=>{if(!await q(jv)())return q(Wv(t??""))()}});var I0,uZ,lZ,dZ,Yv,Qv,Jv=f(()=>{I0=async t=>{let e=t?.Bucket||"";if(typeof t.Bucket=="string"&&(t.Bucket=e.replace(/#/g,encodeURIComponent("#")).replace(/\?/g,encodeURIComponent("?"))),Qv(e)){if(t.ForcePathStyle===!0)throw new Error("Path-style addressing cannot be used with ARN buckets")}else(!Yv(e)||e.indexOf(".")!==-1&&!String(t.Endpoint).startsWith("http:")||e.toLowerCase()!==e||e.length<3)&&(t.ForcePathStyle=!0);return t.DisableMultiRegionAccessPoints&&(t.disableMultiRegionAccessPoints=!0,t.DisableMRAP=!0),t},uZ=/^[a-z0-9][a-z0-9.-]{1,61}[a-z0-9]$/,lZ=/(\d+\.){3}\d+/,dZ=/\.\./,Yv=t=>uZ.test(t)&&!lZ.test(t)&&!dZ.test(t),Qv=t=>{let[e,r,n,,,s]=t.split(":"),o=e==="arn"&&t.split(":").length>=6,i=!!(o&&r&&n&&s);if(o&&!i)throw new Error(`Invalid ARN: ${t} was an invalid ARN.`);return i}});var Xv=f(()=>{Jv()});var Zv,eP=f(()=>{Zv=(t,e,r,n=!1)=>{let s=async()=>{let o;return n?o=r.clientContextParams?.[t]??r[t]??r[e]:o=r[t]??r[e],typeof o=="function"?o():o};return t==="credentialScope"||e==="CredentialScope"?async()=>{let o=typeof r.credentials=="function"?await r.credentials():r.credentials;return o?.credentialScope??o?.CredentialScope}:t==="accountId"||e==="AccountId"?async()=>{let o=typeof r.credentials=="function"?await r.credentials():r.credentials;return o?.accountId??o?.AccountId}:t==="endpoint"||e==="endpoint"?async()=>{if(r.isCustomEndpoint===!1)return;let o=await s();if(o&&typeof o=="object"){if("url"in o)return o.url.href;if("hostname"in o){let{protocol:i,hostname:a,port:c,path:u}=o;return`${i}//${a}${c?":"+c:""}${u}`}}return o}:s}});var mf=f(()=>{W()});function hf(t){return async(e,r,n,s)=>{if(!n.isCustomEndpoint&&!n.ignoreConfiguredEndpointUrls){let a;n.serviceConfiguredEndpoint?a=await n.serviceConfiguredEndpoint():a=await t(n.serviceId),a&&(n.endpoint=()=>Promise.resolve(ir(a)),n.isCustomEndpoint=!0,s?.logger?.debug?.(`@smithy/core/endpoints - resolved endpoint from config: ${a}`))}let o=await _u(e,r,n);if(typeof n.endpointProvider!="function")throw new Error("config.endpointProvider is not set.");let i=n.endpointProvider(o,s);if(n.isCustomEndpoint&&n.endpoint){let a=await n.endpoint();if(a?.headers){i.headers??={};for(let[c,u]of Object.entries(a.headers))i.headers[c]=Array.isArray(u)?u:[u]}}return i}}var _u,gf=f(()=>{Xv();eP();mf();_u=async(t,e,r)=>{let n={},s=e?.getEndpointParameterInstructions?.()||{};for(let[o,i]of Object.entries(s))switch(i.type){case"staticContextParams":n[o]=i.value;break;case"contextParams":n[o]=t[i.name];break;case"clientContextParams":case"builtInParams":n[o]=await Zv(i.name,o,r,i.type!=="builtInParams")();break;case"operationContextParams":n[o]=i.get(t);break;default:throw new Error("Unrecognized endpoint parameter instruction: "+JSON.stringify(i))}return Object.keys(s).length===0&&Object.assign(n,r),String(r.serviceId).toLowerCase()==="s3"&&await I0(n),n}});function pZ(t,e,r){t.__smithy_context?t.__smithy_context.features||(t.__smithy_context.features={}):t.__smithy_context={features:{}},t.__smithy_context.features[e]=r}function Sf(t){let e=hf(t);return({config:r,instructions:n})=>(s,o)=>async i=>{r.isCustomEndpoint&&pZ(o,"ENDPOINT_OVERRIDE","N");let a=await e(i.input,{getEndpointParameterInstructions(){return n}},{...r},o);o.endpointV2=a,o.authSchemes=a.properties?.authSchemes;let c=o.authSchemes?.[0];if(c){o.signing_region=c.signingRegion,o.signing_service=c.signingName;let p=he(o)?.selectedHttpAuthScheme?.httpAuthOption;p&&(p.signingProperties=Object.assign(p.signingProperties||{},{signing_region:c.signingRegion,signingRegion:c.signingRegion,signing_service:c.signingName,signingName:c.signingName,signingRegionSet:c.signingRegionSet},c.properties))}return s({...i})}}var x0=f(()=>{W();gf()});function tP(t){let e=Sf(t);return(r,n)=>({applyToStack:s=>{s.addRelativeTo(e({config:r,instructions:n}),C0)}})}var fZ,C0,b0=f(()=>{x0();fZ={name:"serializerMiddleware",step:"serialize",tags:["SERIALIZER"],override:!0},C0={step:"serialize",tags:["ENDPOINT_PARAMETERS","ENDPOINT_V2","ENDPOINT"],name:"endpointV2Middleware",override:!0,relation:"before",toMiddleware:fZ.name}});function rP(t){return e=>{let r=e.tls??!0,{endpoint:n,useDualstackEndpoint:s,useFipsEndpoint:o}=e,i=n!=null?async()=>ir(await ge(n)()):void 0,c=Object.assign(e,{endpoint:i,tls:r,isCustomEndpoint:!!n,useDualstackEndpoint:ge(s??!1),useFipsEndpoint:ge(o??!1),ignoreConfiguredEndpointUrls:!!e.ignoreConfiguredEndpointUrls}),u;return c.serviceConfiguredEndpoint=async()=>(e.serviceId&&!u&&(u=t(e.serviceId)),u),c}}var nP=f(()=>{W();mf()});var Tr,sP=f(()=>{Tr=class t{nodes;root;conditions;results;constructor(e,r,n,s){this.nodes=e,this.root=r,this.conditions=n,this.results=s}static from(e,r,n,s){return new t(e,r,n,s)}}});var Ar,oP=f(()=>{Ar=class{capacity;data=new Map;parameters=[];constructor({size:e,params:r}){this.capacity=e??50,r&&(this.parameters=r)}get(e,r){let n=this.hash(e);if(n===!1)return r();if(!this.data.has(n)){if(this.data.size>this.capacity+10){let s=this.data.keys(),o=0;for(;;){let{value:i,done:a}=s.next();if(this.data.delete(i),a||++o>10)break}}this.data.set(n,r())}return this.data.get(n)}size(){return this.data.size}hash(e){let r="",{parameters:n}=this;if(n.length===0)return!1;for(let s of n){let o=e[s],i=o==null?"\0":String(o);if(i.includes("|;"))return!1;r+=i+"|;"}return r}}});var te,iP=f(()=>{te=class extends Error{constructor(e){super(e),this.name="EndpointError"}}});var lr=f(()=>{iP()});var Fn,aP=f(()=>{Fn="endpoints"});function dr(t){return typeof t!="object"||t==null?t:"ref"in t?`$${dr(t.ref)}`:"fn"in t?`${t.fn}(${(t.argv||[]).map(dr).join(", ")})`:JSON.stringify(t,null,2)}var cP=f(()=>{});var Ru=f(()=>{aP();cP()});var Jt,w0=f(()=>{Jt={}});var D0,uP=f(()=>{D0=(t,e)=>t===e});function O0(...t){for(let e of t)if(e!=null)return e}var lP=f(()=>{});var dP,pP=f(()=>{lr();dP=t=>{let e=t.split("."),r=[];for(let n of e){let s=n.indexOf("[");if(s!==-1){if(n.indexOf("]")!==n.length-1)throw new te(`Path: '${t}' does not end with ']'`);let o=n.slice(s+1,-1);if(Number.isNaN(parseInt(o)))throw new te(`Invalid array index: '${o}' in path: '${t}'`);s!==0&&r.push(n.slice(0,s)),r.push(o)}else r.push(n)}return r}});var Tu,fP=f(()=>{lr();pP();Tu=(t,e)=>dP(e).reduce((r,n)=>{if(typeof r!="object")throw new te(`Index '${n}' in '${e}' not found in '${JSON.stringify(t)}'`);if(Array.isArray(r)){let s=parseInt(n);return r[s<0?r.length+s:s]}return r[n]},t)});var v0,mP=f(()=>{v0=t=>t!=null});function P0(t,e,r){return t?e:r}var hP=f(()=>{});var N0,gP=f(()=>{N0=t=>!t});var mZ,Is,k0=f(()=>{mZ=new RegExp("^(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)(?:\\.(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)){3}$"),Is=t=>mZ.test(t)||t.startsWith("[")&&t.endsWith("]")});var Ef,M0,L0,SP=f(()=>{Ef=ye(Hr());k0();M0={[Ef.EndpointURLScheme.HTTP]:80,[Ef.EndpointURLScheme.HTTPS]:443},L0=t=>{let e=(()=>{try{if(t instanceof URL)return t;if(typeof t=="object"&&"hostname"in t){let{hostname:m,port:g,protocol:E="",path:_="",query:R={}}=t,T=new URL(`${E}//${m}${g?`:${g}`:""}${_}`);return T.search=Object.entries(R).map(([I,P])=>`${I}=${P}`).join("&"),T}return new URL(t)}catch{return null}})();if(!e)return console.error(`Unable to parse ${JSON.stringify(t)} as a whatwg URL.`),null;let r=e.href,{host:n,hostname:s,pathname:o,protocol:i,search:a}=e;if(a)return null;let c=i.slice(0,-1);if(!Object.values(Ef.EndpointURLScheme).includes(c))return null;let u=Is(s),p=r.includes(`${n}:${M0[c]}`)||typeof t=="string"&&t.includes(`${n}:${M0[c]}`),d=`${n}${p?`:${M0[c]}`:""}`;return{scheme:c,authority:d,path:o,normalizedPath:o.endsWith("/")?o:`${o}/`,isIp:u}}});function $0(t,e,r){if(r===1)return[t];if(t==="")return[""];let n=t.split(e);return r===0?n:n.slice(0,r-1).concat(n.slice(1).join(e))}var EP=f(()=>{});var F0,yP=f(()=>{F0=(t,e)=>t===e});var U0,_P=f(()=>{U0=(t,e,r,n)=>t==null||e>=r||t.length<r||/[^\u0000-\u007f]/.test(t)?null:n?t.substring(t.length-r,t.length-e):t.substring(e,r)});var B0,RP=f(()=>{B0=t=>encodeURIComponent(t).replace(/[!*'()]/g,e=>`%${e.charCodeAt(0).toString(16).toUpperCase()}`)});var G0=f(()=>{uP();lP();fP();mP();W();hP();gP();SP();EP();yP();_P();RP()});var TP,AP=f(()=>{G0();TP={booleanEquals:D0,coalesce:O0,getAttr:Tu,isSet:v0,isValidHostLabel:Vr,ite:P0,not:N0,parseURL:L0,split:$0,stringEquals:F0,substring:U0,uriEncode:B0}});var yf,H0=f(()=>{G0();yf=(t,e)=>{let r=[],{referenceRecord:n,endpointParams:s}=e,o=0;for(;o<t.length;){let i=t.indexOf("{",o);if(i===-1){r.push(t.slice(o));break}r.push(t.slice(o,i));let a=t.indexOf("}",i);if(a===-1){r.push(t.slice(i));break}t[i+1]==="{"&&t[a+1]==="}"&&(r.push(t.slice(i+1,a)),o=a+2);let c=t.substring(i+1,a);if(c.includes("#")){let[u,p]=c.split("#");r.push(Tu(n[u]??s[u],p))}else r.push(n[c]??s[c]);o=a+1}return r.join("")}});var IP,xP=f(()=>{IP=({ref:t},e)=>e.referenceRecord[t]??e.endpointParams[t]});var xs,_f,CP,la=f(()=>{lr();w0();AP();H0();xP();xs=(t,e,r)=>{if(typeof t=="string")return yf(t,r);if(t.fn)return CP.callFunction(t,r);if(t.ref)return IP(t,r);throw new te(`'${e}': ${String(t)} is not a string, function or reference.`)},_f=({fn:t,argv:e},r)=>{let n=Array(e.length);for(let i=0;i<n.length;++i){let a=e[i];typeof a=="boolean"||typeof a=="number"?n[i]=a:n[i]=CP.evaluateExpression(a,"arg",r)}let s=t.indexOf(".");if(s!==-1){let a=Jt[t.slice(0,s)]?.[t.slice(s+1)];if(typeof a=="function")return a(...n)}let o=TP[t];if(typeof o=="function")return o(...n);throw new Error(`function ${t} not loaded in endpointFunctions.`)},CP={evaluateExpression:xs,callFunction:_f}});var bP=f(()=>{la()});var Rf,V0=f(()=>{Ru();lr();bP();Rf=(t,e)=>{let{assign:r}=t;if(r&&r in e.referenceRecord)throw new te(`'${r}' is already defined in Reference Record.`);let n=_f(t,e);e.logger?.debug?.(`${Fn} evaluateCondition: ${dr(t)} = ${dr(n)}`);let s=n===""?!0:!!n;return r!=null?{result:s,toAssign:{name:r,value:n}}:{result:s}}});var Tf,W0=f(()=>{lr();la();Tf=(t,e)=>Object.entries(t??{}).reduce((r,[n,s])=>(r[n]=s.map(o=>{let i=xs(o,"Header value entry",e);if(typeof i!="string")throw new te(`Header '${n}' value '${i}' is not a string`);return i}),r),{})});var Au,wP,DP,z0=f(()=>{lr();H0();Au=(t,e)=>Object.entries(t).reduce((r,[n,s])=>(r[n]=DP.getEndpointProperty(s,e),r),{}),wP=(t,e)=>{if(Array.isArray(t))return t.map(r=>wP(r,e));switch(typeof t){case"string":return yf(t,e);case"object":if(t===null)throw new te(`Unexpected endpoint property: ${t}`);return DP.getEndpointProperties(t,e);case"boolean":return t;default:throw new te(`Unexpected endpoint property type: ${typeof t}`)}},DP={getEndpointProperty:wP,getEndpointProperties:Au}});var Af,j0=f(()=>{lr();la();Af=(t,e)=>{let r=xs(t,"Endpoint URL",e);if(typeof r=="string")try{return new URL(r)}catch(n){throw console.error(`Failed to construct URL with ${r}`,n),n}throw new te(`Endpoint URL must be a string, got ${typeof r}`)}});var q0,Un,OP=f(()=>{lr();V0();la();W0();z0();j0();q0=1e8,Un=(t,e)=>{let{nodes:r,root:n,results:s,conditions:o}=t,i=n,a={},c={referenceRecord:a,endpointParams:e.endpointParams,logger:e.logger};for(;i!==1&&i!==-1&&i<q0;){let u=3*(Math.abs(i)-1),[p,d,m]=[r[u],r[u+1],r[u+2]],[g,E,_]=o[p],R=Rf({fn:g,assign:_,argv:E},c);if(R.toAssign){let{name:T,value:I}=R.toAssign;a[T]=I}i=i>=0===R.result?d:m}if(i>=q0){let u=s[i-q0];if(u[0]===-1){let[,g]=u;throw new te(xs(g,"Error",c))}let[p,d,m]=u;return{url:Af(p,c),properties:Au(d,c),headers:Tf(m??{},c)}}throw new te("No matching endpoint.")}});var da,If=f(()=>{Ru();V0();da=(t=[],e)=>{let r={},n={...e,referenceRecord:{...e.referenceRecord}},s=!1;for(let o of t){let{result:i,toAssign:a}=Rf(o,n);if(!i)return{result:i};a&&(s=!0,r[a.name]=a.value,n.referenceRecord[a.name]=a.value,e.logger?.debug?.(`${Fn} assign: ${a.name} := ${dr(a.value)}`))}return s?{result:!0,referenceRecord:r}:{result:!0}}});var vP,PP=f(()=>{Ru();If();W0();z0();j0();vP=(t,e)=>{let{conditions:r,endpoint:n}=t,{result:s,referenceRecord:o}=da(r,e);if(!s)return;let i=o?{...e,referenceRecord:{...e.referenceRecord,...o}}:e,{url:a,properties:c,headers:u}=n;e.logger?.debug?.(`${Fn} Resolving endpoint from template: ${dr(n)}`);let p={url:Af(a,i)};return u!=null&&(p.headers=Tf(u,i)),c!=null&&(p.properties=Au(c,i)),p}});var NP,kP=f(()=>{lr();If();la();NP=(t,e)=>{let{conditions:r,error:n}=t,{result:s,referenceRecord:o}=da(r,e);if(!s)return;let i=o?{...e,referenceRecord:{...e.referenceRecord,...o}}:e;throw new te(xs(n,"Error",i))}});var xf,MP,K0,LP=f(()=>{lr();If();PP();kP();xf=(t,e)=>{for(let r of t)if(r.type==="endpoint"){let n=vP(r,e);if(n)return n}else if(r.type==="error")NP(r,e);else if(r.type==="tree"){let n=K0.evaluateTreeRule(r,e);if(n)return n}else throw new te(`Unknown endpoint rule: ${r}`);throw new te("Rules evaluation failed")},MP=(t,e)=>{let{conditions:r,rules:n}=t,{result:s,referenceRecord:o}=da(r,e);if(!s)return;let i=o?{...e,referenceRecord:{...e.referenceRecord,...o}}:e;return K0.evaluateRules(n,i)},K0={evaluateRules:xf,evaluateTreeRule:MP}});var $P=f(()=>{LP()});var Iu,FP=f(()=>{W();Ru();lr();$P();Iu=(t,e)=>{let{endpointParams:r,logger:n}=e,{parameters:s,rules:o}=t;e.logger?.debug?.(`${Fn} Initial EndpointParams: ${dr(r)}`);for(let a in s){if(!k(s,a))continue;let c=s[a],u=r[a];if(u==null&&c.default!=null){r[a]=c.default;continue}if(c.required&&u==null)throw new te(`Missing required parameter: '${a}'`)}let i=xf(o,{endpointParams:r,logger:n,referenceRecord:{}});return e.logger?.debug?.(`${Fn} Resolved endpoint: ${dr(i)}`),i}});var UP,BP=f(()=>{UP=t=>{let{endpoint:e}=t;return e===void 0&&(t.endpoint=async()=>{throw new Error("@smithy/middleware-endpoint: (default endpointRuleSet) endpoint is not set - you must configure an endpoint.")}),t}});var Cf={};at(Cf,{BinaryDecisionDiagram:()=>Tr,EndpointCache:()=>Ar,EndpointError:()=>te,customEndpointFunctions:()=>Jt,decideEndpoint:()=>Un,endpointMiddleware:()=>gZ,endpointMiddlewareOptions:()=>C0,getEndpointFromInstructions:()=>hZ,getEndpointPlugin:()=>bs,isIpAddress:()=>Is,isValidHostLabel:()=>Vr,middlewareEndpointToEndpointV1:()=>ir,resolveEndpoint:()=>Iu,resolveEndpointConfig:()=>Cs,resolveEndpointRequiredConfig:()=>UP,resolveParams:()=>_u,toEndpointV1:()=>ir});var hZ,Cs,gZ,bs,Re=f(()=>{Kv();gf();x0();b0();nP();W();sP();oP();OP();k0();W();w0();FP();lr();gf();mf();b0();BP();hZ=hf(yu),Cs=rP(yu),gZ=Sf(yu),bs=tP(yu)});var bf,Y0=f(()=>{Re();bf=(t,e)=>(r,n)=>async s=>{let o=t,i=n.endpointV2?async()=>ir(n.endpointV2):o.endpoint;if(!i)throw new Error("No valid endpoint provider available.");let a=await e(s.input,{...t,endpoint:i});return r({...s,request:a})}});function GP(t,e,r){return{applyToStack:n=>{n.add(qp(t,r),Q0),n.add(bf(t,e),J0)}}}var Q0,J0,HP=f(()=>{e0();Y0();Q0={name:"deserializerMiddleware",step:"deserialize",tags:["DESERIALIZER"],override:!0},J0={name:"serializerMiddleware",step:"serialize",tags:["SERIALIZER"],override:!0}});function VP(t,e){return Buffer.isBuffer(t)?t:typeof t=="string"?Qs(t,e):ArrayBuffer.isView(t)?jr(t.buffer,t.byteOffset,t.byteLength):jr(t)}var Df,wf,WP=f(()=>{Df=require("node:crypto");Js();XR();wf=class{algorithmIdentifier;secret;hash;constructor(e,r){this.algorithmIdentifier=e,this.secret=r,this.reset()}update(e,r){this.hash.update(Ut(VP(e,r)))}digest(){return Promise.resolve(this.hash.digest())}reset(){this.hash=this.secret?(0,Df.createHmac)(this.algorithmIdentifier,VP(this.secret)):(0,Df.createHash)(this.algorithmIdentifier)}}});var zP,pa,X0=f(()=>{zP=require("node:stream");BR();pa=class extends zP.Readable{expectedChecksum;checksumSourceLocation;checksum;source;base64Encoder;constructor({expectedChecksum:e,checksum:r,source:n,checksumSourceLocation:s,base64Encoder:o}){if(super(),typeof n.pipe!="function")throw new Error(`@smithy/util-stream: unsupported source type ${n?.constructor?.name??n} in ChecksumStream.`);this.source=n,this.base64Encoder=o??ne,this.expectedChecksum=e,this.checksum=r,this.checksumSourceLocation=s,this.source.on("data",this.onSourceData),this.source.on("end",this.onSourceEnd),this.source.on("error",this.onSourceError),this.source.on("close",this.onSourceClose),this.source.pause()}onSourceData=e=>{if(!this.destroyed){try{this.checksum.update(e)}catch(r){this.destroy(r);return}this.push(e)||this.source.pause()}};onSourceEnd=async()=>{if(!this.destroyed){try{let e=await this.checksum.digest(),r=this.base64Encoder(e);if(this.expectedChecksum!==r){this.destroy(new Error(`Checksum mismatch: expected "${this.expectedChecksum}" but received "${r}" in response header "${this.checksumSourceLocation}".`));return}}catch(e){this.destroy(e);return}this.push(null)}};onSourceError=e=>{this.destroy(e)};onSourceClose=()=>{!this.destroyed&&!this.source.readableEnded&&this.destroy(new Error("Connection lost or stream closed before all data was received."))};_read(e){this.source.resume()}_destroy(e,r){this.source?.removeListener("data",this.onSourceData),this.source?.removeListener("end",this.onSourceEnd),this.source?.removeListener("error",this.onSourceError),this.source?.removeListener("close",this.onSourceClose),this.source?.destroy(),r(e)}}});var rt,to,qr=f(()=>{rt=t=>typeof ReadableStream=="function"&&(t?.constructor?.name===ReadableStream.name||t instanceof ReadableStream),to=t=>typeof Blob=="function"&&(t?.constructor?.name===Blob.name||t instanceof Blob)});var jP,qP=f(()=>{jP=t=>new TextEncoder().encode(t)});var KP,i2e,YP,Of,Z0,QP,JP=f(()=>{KP="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",i2e=Object.entries(KP).reduce((t,[e,r])=>(t[r]=Number(e),t),{}),YP=KP.split(""),Of=6,Z0=8,QP=63});function vf(t){let e;typeof t=="string"?e=jP(t):e=t;let r=typeof e=="object"&&typeof e.length=="number",n=typeof e=="object"&&typeof e.byteOffset=="number"&&typeof e.byteLength=="number";if(!r&&!n)throw new Error("@smithy/util-base64: toBase64 encoder function only accepts string | Uint8Array.");let s="";for(let o=0;o<e.length;o+=3){let i=0,a=0;for(let u=o,p=Math.min(o+3,e.length);u<p;u++)i|=e[u]<<(p-u-1)*Z0,a+=Z0;let c=Math.ceil(a/Of);i<<=c*Of-a;for(let u=1;u<=c;u++){let p=(c-u)*Of;s+=YP[(i&QP<<p)>>p]}s+="==".slice(0,4-c)}return s}var eT=f(()=>{qP();JP()});var SZ,Pf,XP=f(()=>{SZ=typeof ReadableStream=="function"?ReadableStream:function(){},Pf=class extends SZ{}});var ZP,eN=f(()=>{eT();qr();XP();ZP=({expectedChecksum:t,checksum:e,source:r,checksumSourceLocation:n,base64Encoder:s})=>{if(!rt(r))throw new Error(`@smithy/util-stream: unsupported source type ${r?.constructor?.name??r} in ChecksumStream.`);let o=s??vf;if(typeof TransformStream!="function")throw new Error("@smithy/util-stream: unable to instantiate ChecksumStream because API unavailable: ReadableStream/TransformStream.");let i=new TransformStream({start(){},async transform(c,u){e.update(c),u.enqueue(c)},async flush(c){let u=await e.digest(),p=o(u);if(t!==p){let d=new Error(`Checksum mismatch: expected "${t}" but received "${p}" in response header "${n}".`);c.error(d)}else c.terminate()}});r.pipeThrough(i);let a=i.readable;return Object.setPrototypeOf(a,Pf.prototype),a}});function tN(t){return typeof ReadableStream=="function"&&rt(t.source)?ZP(t):new pa(t)}var rN=f(()=>{qr();X0();eN()});var ei,tT=f(()=>{ei=class{allocByteArray;byteLength=0;byteArrays=[];constructor(e){this.allocByteArray=e}push(e){this.byteArrays.push(e),this.byteLength+=e.byteLength}flush(){if(this.byteArrays.length===1){let n=this.byteArrays[0];return this.reset(),n}let e=this.allocByteArray(this.byteLength),r=0;for(let n=0;n<this.byteArrays.length;++n){let s=this.byteArrays[n];e.set(s,r),r+=s.byteLength}return this.reset(),e}reset(){this.byteArrays=[],this.byteLength=0}}});function nN(t,e,r){let n=t.getReader(),s=!1,o=0,i=["",new ei(u=>new Uint8Array(u))],a=-1,c=async u=>{let{value:p,done:d}=await n.read(),m=p;if(d){if(a!==-1){let g=ti(i,a);ws(g)>0&&u.enqueue(g)}u.close()}else{let g=nT(m,!1);if(a!==g&&(a>=0&&u.enqueue(ti(i,a)),a=g),a===-1){u.enqueue(m);return}let E=ws(m);o+=E;let _=ws(i[a]);if(E>=e&&_===0)u.enqueue(m);else{let R=rT(i,a,m);!s&&o>e*2&&(s=!0,r?.warn(`@smithy/util-stream - stream chunk size ${E} is below threshold of ${e}, automatically buffering.`)),R>=e?u.enqueue(ti(i,a)):await c(u)}}};return new ReadableStream({pull:c})}function rT(t,e,r){switch(e){case 0:return t[0]+=r,ws(t[0]);case 1:case 2:return t[e].push(r),ws(t[e])}}function ti(t,e){switch(e){case 0:let r=t[0];return t[0]="",r;case 1:case 2:return t[e].flush()}throw new Error(`@smithy/util-stream - invalid index ${e} given to flush()`)}function ws(t){return t?.byteLength??t?.length??0}function nT(t,e=!0){return e&&typeof Buffer<"u"&&t instanceof Buffer?2:t instanceof Uint8Array?1:typeof t=="string"?0:-1}var sN=f(()=>{tT()});function iN(t,e,r){if(rt(t))return nN(t,e,r);let n=new oN.Readable({read(){}}),s=!1,o=0,i=["",new ei(c=>new Uint8Array(c)),new ei(c=>Buffer.from(new Uint8Array(c)))],a=-1;return t.on("data",c=>{let u=nT(c,!0);if(a!==u&&(a>=0&&n.push(ti(i,a)),a=u),a===-1){n.push(c);return}let p=ws(c);o+=p;let d=ws(i[a]);if(p>=e&&d===0)n.push(c);else{let m=rT(i,a,c);!s&&o>e*2&&(s=!0,r?.warn(`@smithy/util-stream - stream chunk size ${p} is below threshold of ${e}, automatically buffering.`)),m>=e&&n.push(ti(i,a))}}),t.on("end",()=>{if(a!==-1){let c=ti(i,a);ws(c)>0&&n.push(c)}n.push(null)}),n}var oN,aN=f(()=>{oN=require("node:stream");tT();sN();qr()});var cN,uN=f(()=>{cN=(t,e)=>{let{base64Encoder:r,bodyLengthChecker:n,checksumAlgorithmFn:s,checksumLocationName:o,streamHasher:i}=e,a=r!==void 0&&n!==void 0&&s!==void 0&&o!==void 0&&i!==void 0,c=a?i(s,t):void 0;Promise.resolve(c).catch(()=>{});let u=t.getReader();return new ReadableStream({async pull(p){let{value:d,done:m}=await u.read();if(m){if(p.enqueue(`0\r
13
+ `),a){let g=r(await c);p.enqueue(`${o}:${g}\r
14
+ `),p.enqueue(`\r
15
+ `)}p.close()}else p.enqueue(`${(n(d)||0).toString(16)}\r
16
+ ${d}\r
17
+ `)}})}});function dN(t,e){let r=t,n=t;if(rt(n))return cN(n,e);let{base64Encoder:s,bodyLengthChecker:o,checksumAlgorithmFn:i,checksumLocationName:a,streamHasher:c}=e,u=s!==void 0&&i!==void 0&&a!==void 0&&c!==void 0,p=u?c(i,r):void 0;Promise.resolve(p).catch(()=>{});let d=new lN.Readable({read(){r.resume()}});return r.on("data",m=>{let g=o(m)||0;g!==0&&(d.push(`${g.toString(16)}\r
18
+ `),d.push(m),d.push(`\r
19
+ `)||r.pause())}),r.on("error",m=>{d.destroy(m)}),r.pause(),r.on("end",async()=>{try{if(d.push(`0\r
20
+ `),u){let m=s(await p);d.push(`${a}:${m}\r
21
+ `),d.push(`\r
22
+ `)}d.push(null)}catch(m){d.destroy(m)}}),d}var lN,pN=f(()=>{lN=require("node:stream");uN();qr()});async function fN(t,e){let r=0,n=[],s=t.getReader(),o=!1;for(;!o;){let{done:c,value:u}=await s.read();if(u&&(n.push(u),r+=u?.byteLength??0),r>=e)break;o=c}s.releaseLock();let i=new Uint8Array(Math.min(e,r)),a=0;for(let c of n){if(c.byteLength>i.byteLength-a){i.set(c.subarray(0,i.byteLength-a),a);break}else i.set(c,a);a+=c.length}return i}var mN=f(()=>{});var hN,gN,sT,SN=f(()=>{hN=require("node:stream");fu();mN();qr();gN=(t,e)=>rt(t)?fN(t,e):new Promise((r,n)=>{let s=new sT;s.limit=e,t.pipe(s),t.on("error",o=>{s.end(),n(o)}),s.on("error",n),s.on("finish",function(){let o=Pn(this.buffers);r(o)})}),sT=class extends hN.Writable{buffers=[];limit=1/0;bytesBuffered=0;_write(e,r,n){if(this.buffers.push(e),this.bytesBuffered+=e.byteLength??0,this.bytesBuffered>=this.limit){let s=this.bytesBuffered-this.limit,o=this.buffers[this.buffers.length-1];this.buffers[this.buffers.length-1]=o.subarray(0,o.byteLength-s),this.emit("finish")}n()}}});var EN,yN=f(()=>{EN=t=>{if(typeof t=="string")return t;if(typeof t!="object"||typeof t.byteOffset!="number"||typeof t.byteLength!="number")throw new Error("@smithy/util-utf8: toUtf8 encoder function only accepts string | Uint8Array.");return new TextDecoder("utf-8").decode(t)}});async function oT(t){return t.arrayBuffer().then(e=>new Uint8Array(e))}async function iT(t){let e=[],r=t.getReader(),n=0;for(;;){let{done:s,value:o}=await r.read();if(o&&(e.push(o),n+=o.length),s)break}return Pn(e,n)}var _N,aT=f(()=>{fu();qr();_N=async t=>to(t)?oT(t):iT(t)});var RN,AN,TN,IN=f(()=>{eT();JR();yN();aT();qr();RN="The stream has already been transformed.",AN=t=>{if(!TN(t)&&!rt(t)){let s=t?.__proto__?.constructor?.name||t;throw new Error(`Unexpected stream implementation, expect Blob or ReadableStream, got ${s}`)}let e=!1,r=async()=>{if(e)throw new Error(RN);return e=!0,await _N(t)},n=s=>{if(typeof s.stream!="function")throw new Error(`Cannot transform payload Blob to web stream. Please make sure the Blob.stream() is polyfilled.
23
+ If you are using React Native, this API is not yet supported, see: https://react-native.canny.io/feature-requests/p/fetch-streaming-body`);return s.stream()};return Object.assign(t,{transformToByteArray:r,transformToString:async s=>{let o=await r();if(s==="base64")return vf(o);if(s==="hex")return Rr(o);if(s===void 0||s==="utf8"||s==="utf-8")return EN(o);if(typeof TextDecoder=="function")return new TextDecoder(s).decode(o);throw new Error("TextDecoder is not available, please make sure polyfill is provided.")},transformToWebStream:()=>{if(e)throw new Error(RN);if(e=!0,TN(t))return n(t);if(rt(t))return t;throw new Error(`Cannot transform payload to web stream, got ${t}`)}})},TN=t=>typeof Blob=="function"&&t instanceof Blob});var xN,Nf,cT,uT=f(()=>{xN=require("node:stream");fu();aT();qr();Nf=t=>to(t)?oT(t):rt(t)?iT(t):new Promise((e,r)=>{let n=new cT,s=t;s.pipe(n),s.on("error",o=>{n.end(),r(o)}),n.on("error",r),n.on("finish",function(){let o=Pn(this.bufferedBytes);e(o)})}),cT=class extends xN.Writable{bufferedBytes=[];_write(e,r,n){this.bufferedBytes.push(e),n()}}});var kf,CN,Mf,bN=f(()=>{kf=require("node:stream");Js();IN();uT();CN="The stream has already been transformed.",Mf=t=>{if(!(t instanceof kf.Readable))try{return AN(t)}catch{let s=t?.__proto__?.constructor?.name||t;throw new Error(`Unexpected stream implementation, expect Stream.Readable instance, got ${s}`)}let e=!1,r=async()=>{if(e)throw new Error(CN);return e=!0,await Nf(t)};return Object.assign(t,{transformToByteArray:r,transformToString:async n=>{let s=await r();return n===void 0||Buffer.isEncoding(n)?jr(s.buffer,s.byteOffset,s.byteLength).toString(n):new TextDecoder(n).decode(s)},transformToWebStream:()=>{if(e)throw new Error(CN);if(t.readableFlowing!==null)throw new Error("The stream has been consumed by other callbacks.");if(typeof kf.Readable.toWeb!="function")throw new Error("Readable.toWeb() is not supported. Please ensure a polyfill is available.");return e=!0,kf.Readable.toWeb(t)}})}});async function wN(t){return typeof t.stream=="function"&&(t=t.stream()),t.tee()}var DN=f(()=>{});async function ON(t){if(rt(t)||to(t))return wN(t);let e=new lT.PassThrough,r=new lT.PassThrough;return t.pipe(e),t.pipe(r),[e,r]}var lT,vN=f(()=>{lT=require("node:stream");DN();qr()});var Bn={};at(Bn,{ChecksumStream:()=>pa,Hash:()=>wf,LazyJsonString:()=>Se,NumericValue:()=>$,Uint8ArrayBlobAdapter:()=>ri,_parseEpochTimestamp:()=>Zs,_parseRfc3339DateTimeWithOffset:()=>Hp,_parseRfc7231DateTime:()=>Vp,calculateBodyLength:()=>vn,concatBytes:()=>Pn,copyDocumentWithTransform:()=>KD,createBufferedReadable:()=>iN,createChecksumStream:()=>tN,dateToUtcString:()=>yt,deserializerMiddleware:()=>qp,deserializerMiddlewareOption:()=>Q0,expectBoolean:()=>JD,expectByte:()=>Mp,expectFloat32:()=>lu,expectInt:()=>XD,expectInt32:()=>Np,expectLong:()=>Zi,expectNonNull:()=>ZD,expectNumber:()=>Xi,expectObject:()=>HR,expectShort:()=>kp,expectString:()=>eO,expectUnion:()=>$p,fromArrayBuffer:()=>jr,fromBase64:()=>Te,fromHex:()=>jp,fromString:()=>Qs,fromUtf8:()=>tt,generateIdempotencyToken:()=>Rt,getAwsChunkedEncodingStream:()=>dN,getSerdePlugin:()=>GP,handleFloat:()=>rO,hasOwn:()=>k,headStream:()=>gN,isArrayBuffer:()=>Op,isBlob:()=>to,isReadableStream:()=>rt,limitedParseDouble:()=>Up,limitedParseFloat:()=>nO,limitedParseFloat32:()=>sO,logger:()=>ea,nv:()=>zp,parseBoolean:()=>QD,parseEpochTimestamp:()=>On,parseRfc3339DateTime:()=>cO,parseRfc3339DateTimeWithOffset:()=>Dn,parseRfc7231DateTime:()=>_r,quoteHeader:()=>Gp,sdkStreamMixin:()=>Mf,serializerMiddleware:()=>bf,serializerMiddlewareOption:()=>J0,splitEvery:()=>Wp,splitHeader:()=>na,splitStream:()=>ON,streamCollector:()=>Nf,strictParseByte:()=>Bp,strictParseDouble:()=>du,strictParseFloat:()=>tO,strictParseFloat32:()=>Fp,strictParseInt:()=>iO,strictParseInt32:()=>aO,strictParseLong:()=>VR,strictParseShort:()=>Xs,toBase64:()=>ne,toHex:()=>Rr,toUint8Array:()=>Ut,toUtf8:()=>_e,v4:()=>fa});var PN,ri,EZ,fa,Rt,L=f(()=>{PN=require("node:crypto");HD();BR();WD();vp();zD();qD();YD();uO();lO();WR();dO();mO();hO();gO();EO();JR();_O();XR();fu();Js();UR();e0();HP();Y0();WP();X0();rN();aN();pN();SN();bN();vN();qr();uT();W();ri=class extends VD(_e,tt,ne,Te){},EZ=PN.getRandomValues,fa=jD(EZ),Rt=fa});var Ge,ma=f(()=>{L();Ge=async(t=new Uint8Array,e)=>{if(t instanceof Uint8Array)return ri.mutate(t);if(!t)return ri.mutate(new Uint8Array);let r=e.streamCollector(t);return ri.mutate(await r)}});function Kr(t){return encodeURIComponent(t).replace(/[!'()*]/g,function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()})}var Lf=f(()=>{});var lt,ha=f(()=>{lt=class{serdeContext;setSerdeContext(e){this.serdeContext=e}}});async function $f(t,e,r=1024*1024){let n=t.size,s=0;for(;s<n;){let o=t.slice(s,Math.min(n,s+r));e(new Uint8Array(await o.arrayBuffer())),s+=o.size}}var dT=f(()=>{});var NN,kN=f(()=>{dT();NN=async function(e,r){let n=new e;return await $f(r,s=>{n.update(s)}),n.digest()}});var MN,ga,pT=f(()=>{MN=require("node:stream");L();ga=class extends MN.Writable{hash;constructor(e,r){super(r),this.hash=e}_write(e,r,n){try{this.hash.update(Ut(e))}catch(s){return n(s)}n()}}});var LN,$N,yZ,FN=f(()=>{LN=require("node:fs");pT();$N=(t,e)=>new Promise((r,n)=>{if(!yZ(e)){n(new Error("Unable to calculate hash for non-file streams."));return}let s=(0,LN.createReadStream)(e.path,{start:e.start,end:e.end}),o=new t,i=new ga(o);s.pipe(i),s.on("error",a=>{i.end(),n(a)}),i.on("error",n),i.on("finish",function(){o.digest().then(r).catch(n)})}),yZ=t=>typeof t.path=="string"});var UN,BN=f(()=>{pT();UN=(t,e)=>{if(e.readableFlowing!==null)throw new Error("Unable to calculate hash for flowing readable stream");let r=new t,n=new ga(r);return e.pipe(n),new Promise((s,o)=>{e.on("error",i=>{n.end(),o(i)}),n.on("error",o),n.on("finish",()=>{r.digest().then(s).catch(o)})})}});function fT(t,e){let r=t[0],n=t[1],s=t[2],o=t[3];for(let i=0;i<64;++i){let a,c;i<16?(a=n&s|~n&o,c=i):i<32?(a=o&n|s&~o,c=(5*i+1)%16):i<48?(a=n^s^o,c=(3*i+5)%16):(a=s^(n|~o),c=7*i%16);let u=e.getUint32(c*4,!0),p=o;o=s,s=n;let d=_Z[(i>>4)*4+(i&3)],m=(r+a&ro)+(u+RZ[i]&ro)&ro;n=n+((m<<d|m>>>32-d)>>>0)&ro,r=p}t[0]=t[0]+r&ro,t[1]=t[1]+n&ro,t[2]=t[2]+s&ro,t[3]=t[3]+o&ro}var Sa,GN,ro,_Z,RZ,mT=f(()=>{L();Sa=class{digestLength=16;state=Uint32Array.from(GN);writeBuffer=new DataView(new ArrayBuffer(64));bufferLength=0;bytesHashed=0;update(e){let r=Ut(e),n=0,s=r.byteLength;for(this.bytesHashed+=s;s>0;)this.writeBuffer.setUint8(this.bufferLength++,r[n++]),--s,this.bufferLength===64&&(fT(this.state,this.writeBuffer),this.bufferLength=0)}async digest(){let e=Uint32Array.from(this.state),r=new DataView(this.writeBuffer.buffer.slice(0)),n=this.bufferLength,s=this.bytesHashed*8;if(r.setUint8(n++,128),this.bufferLength%64>=56){for(let a=n;a<64;++a)r.setUint8(a,0);fT(e,r),n=0}for(let a=n;a<56;++a)r.setUint8(a,0);r.setUint32(56,s>>>0,!0),r.setUint32(60,Math.floor(s/2**32),!0),fT(e,r);let o=new Uint8Array(16),i=new DataView(o.buffer);for(let a=0;a<4;++a)i.setUint32(a*4,e[a],!0);return o}reset(){this.state.set(GN),this.writeBuffer=new DataView(new ArrayBuffer(64)),this.bufferLength=0,this.bytesHashed=0}},GN=[1732584193,4023233417,2562383102,271733878],ro=4294967295,_Z=Uint8Array.of(7,12,17,22,5,9,14,20,4,11,16,23,6,10,15,21),RZ=Array.from({length:64},(t,e)=>Math.abs(Math.sin(e+1))*2**32>>>0)});function AZ(){return class{digestLength=16;hash=(0,Ff.createHash)("md5");update(e){this.hash.update(Ut(e))}async digest(){let e=this.hash.copy().digest();return new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}reset(){this.hash=(0,Ff.createHash)("md5")}}}var Ff,TZ,hT,HN=f(()=>{Ff=require("node:crypto");L();mT();TZ=(()=>{try{return(0,Ff.createHash)("md5"),!0}catch{return!1}})(),hT=TZ?AZ():Sa});var VN,gT,Ea,ST=f(()=>{VN=new Uint32Array(256);for(let t=0;t<256;++t){let e=t;for(let r=0;r<8;++r)e=e&1?3988292384^e>>>1:e>>>1;VN[t]=e>>>0}gT=4294967295,Ea=class{digestLength=4;checksum=gT;update(e){for(let r=0;r<e.length;++r)this.checksum=this.checksum>>>8^VN[(this.checksum^e[r])&255]}digestSync(){return(this.checksum^gT)>>>0}async digest(){let e=this.digestSync(),r=new Uint8Array(4);return new DataView(r.buffer).setUint32(0,e,!1),r}reset(){this.checksum=gT}}});function IZ(t){return class{digestLength=4;value=0;update(r){this.value=t(r,this.value)}digestSync(){return this.value>>>0}async digest(){let r=new Uint8Array(4);return new DataView(r.buffer).setUint32(0,this.digestSync(),!1),r}reset(){this.value=0}}}var ET,WN,ni,zN=f(()=>{ET=ye(require("node:zlib"));ST();WN=typeof ET.crc32=="function"?ET.crc32:void 0,ni=WN?IZ(WN):Ea});var Tt,jN,xZ,Ds,qN,CZ,Uf=f(()=>{L();Tt=64,jN=32,xZ=2**53-1,Ds=class t{digestLength=jN;state=Int32Array.from(qN);w;buffer=new Uint8Array(64);bufferLength=0;bytesHashed=0;finished=!1;inner;outer;constructor(e){if(e){let r=t.normalizeKey(e);this.inner=new t,this.outer=new t;let{inner:n,outer:s}=this,o=new Uint8Array(Tt*2);for(let i=0;i<Tt;++i)o[i]=54^r[i],o[i+Tt]=92^r[i];n.update(o.subarray(0,Tt)),s.update(o.subarray(Tt))}}update(e){if(this.finished)throw new Error("Attempted to update an already finished HMAC.");if(this.inner){this.inner.update(e);return}let r=Ut(e),n=0,{byteLength:s}=r;if(this.bytesHashed+=s,this.bytesHashed*8>xZ)throw new Error("Cannot hash more than 2^53 - 1 bits");for(;s>0;)this.buffer[this.bufferLength++]=r[n++],s--,this.bufferLength===Tt&&(this.hashBuffer(),this.bufferLength=0)}async digest(){let{inner:e,outer:r}=this;if(e&&r){if(this.finished)throw new Error("Attempted to digest an already finished HMAC.");this.finished=!0;let n=e.digestSync();return r.update(n),r.digestSync()}return this.digestSync()}reset(){this.state=Int32Array.from(qN),this.buffer=new Uint8Array(64),this.bufferLength=0,this.bytesHashed=0}digestSync(){let e=this.state.slice(),r=this.buffer.slice(),n=this.bufferLength,s=this.bytesHashed*8,o=new DataView(r.buffer,r.byteOffset,r.byteLength);if(o.setUint8(n++,128),(n-1)%Tt>=Tt-8){for(let a=n;a<Tt;++a)o.setUint8(a,0);this.hashBufferWith(e,r),n=0}for(let a=n;a<Tt-8;++a)o.setUint8(a,0);o.setUint32(Tt-8,Math.floor(s/4294967296),!1),o.setUint32(Tt-4,s,!1),this.hashBufferWith(e,r);let i=new Uint8Array(jN);for(let a=0;a<8;++a)i[a*4]=e[a]>>>24&255,i[a*4+1]=e[a]>>>16&255,i[a*4+2]=e[a]>>>8&255,i[a*4+3]=e[a]>>>0&255;return i}static normalizeKey(e){let r=Ut(e);if(r.byteLength>Tt){let n=new t;n.update(r);let s=n.digestSync(),o=new Uint8Array(Tt);return o.set(s),o}if(r.byteLength<Tt){let n=new Uint8Array(Tt);return n.set(r),n}return r}hashBuffer(){this.hashBufferWith(this.state,this.buffer)}hashBufferWith(e,r){let n=this.w??=new Int32Array(64),s=e[0],o=e[1],i=e[2],a=e[3],c=e[4],u=e[5],p=e[6],d=e[7];for(let m=0;m<Tt;++m){if(m<16)n[m]=(r[m*4]&255)<<24|(r[m*4+1]&255)<<16|(r[m*4+2]&255)<<8|r[m*4+3]&255;else{let _=n[m-2],R=(_>>>17|_<<15)^(_>>>19|_<<13)^_>>>10;_=n[m-15];let T=(_>>>7|_<<25)^(_>>>18|_<<14)^_>>>3;n[m]=(R+n[m-7]|0)+(T+n[m-16]|0)}let g=(((c>>>6|c<<26)^(c>>>11|c<<21)^(c>>>25|c<<7))+(c&u^~c&p)|0)+(d+(CZ[m]+n[m]|0)|0)|0,E=((s>>>2|s<<30)^(s>>>13|s<<19)^(s>>>22|s<<10))+(s&o^s&i^o&i)|0;d=p,p=u,u=c,c=a+g|0,a=i,i=o,o=s,s=g+E|0}e[0]+=s,e[1]+=o,e[2]+=i,e[3]+=a,e[4]+=c,e[5]+=u,e[6]+=p,e[7]+=d}},qN=new Int32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),CZ=new Int32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298])});function wZ(){return class{digestLength=32;secret;hash;isHmac;finished=!1;constructor(e){this.secret=e,this.isHmac=!!e,this.hash=this.createHash()}update(e){if(this.finished)throw new Error("Attempted to update an already finished hash.");this.hash.update(e)}async digest(){let e;return this.isHmac?(this.finished=!0,e=this.hash.digest()):e=this.hash.copy().digest(),new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}reset(){this.hash=this.createHash(),this.finished=!1}createHash(){return this.secret?(0,xu.createHmac)("sha256",DZ(this.secret)):(0,xu.createHash)("sha256")}}}function DZ(t){return typeof t=="string"?t:ArrayBuffer.isView(t)?Buffer.from(t.buffer,t.byteOffset,t.byteLength):Buffer.from(t)}var xu,bZ,Yr,KN=f(()=>{xu=require("node:crypto");Uf();bZ=(()=>{try{return(0,xu.createHash)("sha256"),!0}catch{return!1}})(),Yr=bZ?wZ():Ds});var OZ,vZ,PZ,Bf,NZ,Gf,YN=f(()=>{L();Uf();({digest:OZ,sign:vZ,importKey:PZ}=globalThis?.crypto?.subtle??{}),Bf=typeof OZ=="function"&&typeof vZ=="function"&&typeof PZ=="function"?globalThis.crypto.subtle:void 0,NZ=8*1024*1024,Gf=class{digestLength=32;secret;pending=[];pendingBytes=0;fallback;finished=!1;constructor(e){e&&(this.secret=Ut(e))}update(e){if(this.finished)throw new Error("Attempted to update an already finished HMAC.");if(this.fallback){this.fallback.update(e);return}this.pending.push(e.slice()),this.pendingBytes+=e.byteLength,this.pendingBytes>=NZ&&this.switchToFallback()}async digest(){if(this.fallback)return this.fallback.digest();if(this.secret&&this.finished)throw new Error("Attempted to digest an already finished HMAC.");let e=Pn(this.pending);if(Bf){if(this.secret){this.finished=!0;let s=await Bf.importKey("raw",this.secret,{name:"HMAC",hash:"SHA-256"},!1,["sign"]),o=await Bf.sign("HMAC",s,e);return new Uint8Array(o)}let n=await Bf.digest("SHA-256",e);return new Uint8Array(n)}let r=new Ds(this.secret);return r.update(e),r.digest()}reset(){this.pending=[],this.pendingBytes=0,this.fallback=void 0,this.finished=!1}switchToFallback(){let e=new Ds(this.secret);for(let r of this.pending)e.update(r);this.fallback=e,this.pending=[],this.pendingBytes=0}}});var Hf={};at(Hf,{Crc32:()=>ni,Crc32Js:()=>Ea,Crc32Node:()=>ni,Md5:()=>hT,Md5Js:()=>Sa,Md5Node:()=>hT,Sha256:()=>Yr,Sha256Js:()=>Ds,Sha256Node:()=>Yr,Sha256WebCrypto:()=>Gf,blobHasher:()=>NN,blobReader:()=>$f,fileStreamHasher:()=>$N,readableStreamHasher:()=>UN});var Gn=f(()=>{kN();FN();BN();mT();HN();ST();zN();Uf();KN();YN();dT()});function QN(t){for(let e=0;e<8;e++)t[e]^=255;for(let e=7;e>-1&&(t[e]++,t[e]===0);e--);}var no,yT=f(()=>{L();no=class t{bytes;constructor(e){if(this.bytes=e,e.byteLength!==8)throw new Error("Int64 buffers must be exactly 8 bytes")}static fromNumber(e){if(e>9223372036854776e3||e<-9223372036854776e3)throw new Error(`${e} is too large (or, if negative, too small) to represent as an Int64`);let r=new Uint8Array(8);for(let n=7,s=Math.abs(Math.round(e));n>-1&&s>0;n--,s/=256)r[n]=s;return e<0&&QN(r),new t(r)}valueOf(){let e=this.bytes.slice(0),r=e[0]&128;return r&&QN(e),parseInt(Rr(e),16)*(r?-1:1)}toString(){return String(this.valueOf())}}});var ya,JN,XN,kZ,MZ,LZ,$Z,FZ,UZ,BZ,GZ,HZ,_T=f(()=>{W();L();yT();ya=class{toUtf8;fromUtf8;constructor(e,r){this.toUtf8=e,this.fromUtf8=r}format(e){let r=[];for(let o in e){if(!k(e,o))continue;let i=this.fromUtf8(o);r.push(Uint8Array.from([i.byteLength]),i,this.formatHeaderValue(e[o]))}let n=new Uint8Array(r.reduce((o,i)=>o+i.byteLength,0)),s=0;for(let o of r)n.set(o,s),s+=o.byteLength;return n}formatHeaderValue(e){switch(e.type){case"boolean":return Uint8Array.from([e.value?0:1]);case"byte":return Uint8Array.from([2,e.value]);case"short":let r=new DataView(new ArrayBuffer(3));return r.setUint8(0,3),r.setInt16(1,e.value,!1),new Uint8Array(r.buffer);case"integer":let n=new DataView(new ArrayBuffer(5));return n.setUint8(0,4),n.setInt32(1,e.value,!1),new Uint8Array(n.buffer);case"long":let s=new Uint8Array(9);return s[0]=5,s.set(e.value.bytes,1),s;case"binary":let o=new DataView(new ArrayBuffer(3+e.value.byteLength));o.setUint8(0,6),o.setUint16(1,e.value.byteLength,!1);let i=new Uint8Array(o.buffer);return i.set(e.value,3),i;case"string":let a=this.fromUtf8(e.value),c=new DataView(new ArrayBuffer(3+a.byteLength));c.setUint8(0,7),c.setUint16(1,a.byteLength,!1);let u=new Uint8Array(c.buffer);return u.set(a,3),u;case"timestamp":let p=new Uint8Array(9);return p[0]=8,p.set(no.fromNumber(e.value.valueOf()).bytes,1),p;case"uuid":if(!HZ.test(e.value))throw new Error(`Invalid UUID received: ${e.value}`);let d=new Uint8Array(17);return d[0]=9,d.set(jp(e.value.replace(/-/g,"")),1),d}}parse(e){let r={},n=0;for(;n<e.byteLength;){let s=e.getUint8(n++),o=this.toUtf8(new Uint8Array(e.buffer,e.byteOffset+n,s));switch(n+=s,e.getUint8(n++)){case 0:r[o]={type:XN,value:!0};break;case 1:r[o]={type:XN,value:!1};break;case 2:r[o]={type:kZ,value:e.getInt8(n++)};break;case 3:r[o]={type:MZ,value:e.getInt16(n,!1)},n+=2;break;case 4:r[o]={type:LZ,value:e.getInt32(n,!1)},n+=4;break;case 5:r[o]={type:$Z,value:new no(new Uint8Array(e.buffer,e.byteOffset+n,8))},n+=8;break;case 6:let i=e.getUint16(n,!1);n+=2,r[o]={type:FZ,value:new Uint8Array(e.buffer,e.byteOffset+n,i)},n+=i;break;case 7:let a=e.getUint16(n,!1);n+=2,r[o]={type:UZ,value:this.toUtf8(new Uint8Array(e.buffer,e.byteOffset+n,a))},n+=a;break;case 8:r[o]={type:BZ,value:new Date(new no(new Uint8Array(e.buffer,e.byteOffset+n,8)).valueOf())},n+=8;break;case 9:let c=new Uint8Array(e.buffer,e.byteOffset+n,16);n+=16,r[o]={type:GZ,value:`${Rr(c.subarray(0,4))}-${Rr(c.subarray(4,6))}-${Rr(c.subarray(6,8))}-${Rr(c.subarray(8,10))}-${Rr(c.subarray(10))}`};break;default:throw new Error("Unrecognized header type tag")}}return r}};(function(t){t[t.boolTrue=0]="boolTrue",t[t.boolFalse=1]="boolFalse",t[t.byte=2]="byte",t[t.short=3]="short",t[t.integer=4]="integer",t[t.long=5]="long",t[t.byteArray=6]="byteArray",t[t.string=7]="string",t[t.timestamp=8]="timestamp",t[t.uuid=9]="uuid"})(JN||(JN={}));XN="boolean",kZ="byte",MZ="short",LZ="integer",$Z="long",FZ="binary",UZ="string",BZ="timestamp",GZ="uuid",HZ=/^[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}$/});function ek({byteLength:t,byteOffset:e,buffer:r}){if(t<VZ)throw new Error("Provided message too short to accommodate event stream message overhead");let n=new DataView(r,e,t),s=n.getUint32(0,!1);if(t!==s)throw new Error("Reported message length does not match received message length");let o=n.getUint32(ZN,!1),i=n.getUint32(so,!1),a=n.getUint32(t-si,!1),c=new ni;if(c.update(new Uint8Array(r,e,so)),i!==c.digestSync())throw new Error(`The prelude checksum specified in the message (${i}) does not match the calculated CRC32 checksum (${c.digestSync()})`);if(c.update(new Uint8Array(r,e+so,t-(so+si))),a!==c.digestSync())throw new Error(`The message checksum (${c.digestSync()}) did not match the expected value of ${a}`);return{headers:new DataView(r,e+so+si,o),body:new Uint8Array(r,e+so+si+o,s-o-(so+si+si))}}var ZN,so,si,VZ,tk=f(()=>{Gn();ZN=4,so=ZN*2,si=4,VZ=so+si*2});var _a,RT=f(()=>{Gn();_T();tk();_a=class{headerMarshaller;messageBuffer;isEndOfStream;constructor(e,r){this.headerMarshaller=new ya(e,r),this.messageBuffer=[],this.isEndOfStream=!1}feed(e){this.messageBuffer.push(this.decode(e))}endOfStream(){this.isEndOfStream=!0}getMessage(){let e=this.messageBuffer.pop(),r=this.isEndOfStream;return{getMessage(){return e},isEndOfStream(){return r}}}getAvailableMessages(){let e=this.messageBuffer;this.messageBuffer=[];let r=this.isEndOfStream;return{getMessages(){return e},isEndOfStream(){return r}}}encode({headers:e,body:r}){let n=this.headerMarshaller.format(e),s=n.byteLength+r.byteLength+16,o=new Uint8Array(s),i=new DataView(o.buffer,o.byteOffset,o.byteLength),a=new ni;return i.setUint32(0,s,!1),i.setUint32(4,n.byteLength,!1),a.update(o.subarray(0,8)),i.setUint32(8,a.digestSync(),!1),o.set(n,12),o.set(r,n.byteLength+12),a.update(o.subarray(8,s-4)),i.setUint32(s-4,a.digestSync(),!1),o}decode(e){let{headers:r,body:n}=ek(e);return{headers:this.headerMarshaller.parse(r),body:n}}formatHeaders(e){return this.headerMarshaller.format(e)}}});var Ra,TT=f(()=>{Ra=class{options;constructor(e){this.options=e}[Symbol.asyncIterator](){return this.asyncIterator()}async*asyncIterator(){for await(let e of this.options.inputStream)yield this.options.decoder.decode(e)}}});var Ta,AT=f(()=>{Ta=class{options;constructor(e){this.options=e}[Symbol.asyncIterator](){return this.asyncIterator()}async*asyncIterator(){for await(let e of this.options.messageStream)yield this.options.encoder.encode(e);this.options.includeEndFrame&&(yield new Uint8Array(0))}}});var Aa,IT=f(()=>{Aa=class{options;constructor(e){this.options=e}[Symbol.asyncIterator](){return this.asyncIterator()}async*asyncIterator(){for await(let e of this.options.messageStream){let r=await this.options.deserializer(e);r!==void 0&&(yield r)}}}});var Ia,xT=f(()=>{Ia=class{options;constructor(e){this.options=e}[Symbol.asyncIterator](){return this.asyncIterator()}async*asyncIterator(){for await(let e of this.options.inputStream)yield this.options.serializer(e)}}});function Vf(t){let e=0,r=0,n=null,s=null,o=a=>{if(typeof a!="number")throw new Error("Attempted to allocate an event message where size was not a number: "+a);e=a,r=4,n=new Uint8Array(a),new DataView(n.buffer).setUint32(0,a,!1)},i=async function*(){let a=t[Symbol.asyncIterator]();for(;;){let{value:c,done:u}=await a.next();if(u){if(e)if(e===r)yield n;else throw new Error("Truncated event message received.");else return;return}let p=c.length,d=0;for(;d<p;){if(!n){let g=p-d;s||(s=new Uint8Array(4));let E=Math.min(4-r,g);if(s.set(c.slice(d,d+E),r),r+=E,d+=E,r<4)break;o(new DataView(s.buffer).getUint32(0,!1)),s=null}let m=Math.min(e-r,p-d);n.set(c.slice(d,d+m),r),r+=m,d+=m,e&&e===r&&(yield n,n=null,e=0,r=0)}}};return{[Symbol.asyncIterator]:i}}var CT=f(()=>{});function rk(t,e){let r=Cu(e.deserializer,e.toUtf8);return{[Symbol.asyncIterator]:async function*(){for await(let n of t){let s=e.eventStreamCodec.decode(n),o=await r(s);o!==void 0&&(yield o)}}}}function Cu(t,e){return async function(r){let{value:n}=r.headers[":message-type"];if(n==="error"){let s=new Error(r.headers[":error-message"].value||"UnknownError");throw s.name=r.headers[":error-code"].value,s}else if(n==="exception"){let s=r.headers[":exception-type"].value,o={[s]:r},i=await t(o);if(i.$unknown){let a=new Error(e(r.body));throw a.name=s,a}throw i[s]}else if(n==="event"){let s={[r.headers[":event-type"].value]:r},o=await t(s);return o.$unknown?void 0:o}else throw Error(`Unrecognizable event type: ${r.headers[":event-type"].value}`)}}var bT=f(()=>{});var oi,nk,wT=f(()=>{RT();TT();AT();IT();xT();CT();bT();oi=class{eventStreamCodec;utfEncoder;constructor({utf8Encoder:e,utf8Decoder:r}){this.eventStreamCodec=new _a(e,r),this.utfEncoder=e}deserialize(e,r){let n=Vf(e);return new Aa({messageStream:new Ra({inputStream:n,decoder:this.eventStreamCodec}),deserializer:Cu(r,this.utfEncoder)})}serialize(e,r){return new Ta({messageStream:new Ia({inputStream:e,serializer:r}),encoder:this.eventStreamCodec,includeEndFrame:!0})}},nk=t=>new oi(t)});async function*WZ(t){let e=!1,r=!1,n=new Array;for(t.on("error",s=>{if(e||(e=!0),s)throw s}),t.on("data",s=>{n.push(s)}),t.on("end",()=>{e=!0});!r;){let s=await new Promise(o=>setTimeout(()=>o(n.shift()),0));s&&(yield s),r=e&&n.length===0}}var sk,bu,ok,ik=f(()=>{sk=require("node:stream");wT();bu=class{universalMarshaller;constructor({utf8Encoder:e,utf8Decoder:r}){this.universalMarshaller=new oi({utf8Decoder:r,utf8Encoder:e})}deserialize(e,r){let n=typeof e[Symbol.asyncIterator]=="function"?e:WZ(e);return this.universalMarshaller.deserialize(n,r)}serialize(e,r){return sk.Readable.from(this.universalMarshaller.serialize(e,r))}},ok=t=>new bu(t)});var ak,ck,uk=f(()=>{ak=t=>({[Symbol.asyncIterator]:async function*(){let e=t.getReader();try{for(;;){let{done:r,value:n}=await e.read();if(r)return;yield n}}finally{e.releaseLock()}}}),ck=t=>{let e=t[Symbol.asyncIterator]();return new ReadableStream({async pull(r){let{done:n,value:s}=await e.next();if(n)return r.close();r.enqueue(s)}})}});var lk,dk=f(()=>{lk=t=>Object.assign(t,{eventStreamMarshaller:t.eventStreamSerdeProvider(t)})});var Wf,pk=f(()=>{W();K();L();Wf=class{marshaller;serializer;deserializer;serdeContext;defaultContentType;compositeErrorRegistry;constructor({marshaller:e,serializer:r,deserializer:n,serdeContext:s,defaultContentType:o,compositeErrorRegistry:i}){this.marshaller=e,this.serializer=r,this.deserializer=n,this.serdeContext=s,this.defaultContentType=o,this.compositeErrorRegistry=i}async serializeEventStream({eventStream:e,requestSchema:r,initialRequest:n,initialMessageType:s}){let o=this.marshaller,i=r.getEventStreamMember(),a=r.getMemberSchema(i),c=this.serializer,u=this.defaultContentType,p=Symbol("initialRequestMarker"),d={async*[Symbol.asyncIterator](){if(n){let m={":event-type":{type:"string",value:s??"initial-request"},":message-type":{type:"string",value:"event"},":content-type":{type:"string",value:u}};c.write(r,n);let g=c.flush();yield{[p]:!0,headers:m,body:g}}for await(let m of e)yield m}};return o.serialize(d,m=>{if(m[p])return{headers:m.headers,body:m.body};let g="";for(let P in m)if(k(m,P)&&P!=="__type"){g=P;break}let{additionalHeaders:E,body:_,eventType:R,explicitPayloadContentType:T}=this.writeEventBody(g,a,m);return{headers:{":event-type":{type:"string",value:R},":message-type":{type:"string",value:"event"},":content-type":{type:"string",value:T??u},...E},body:_}})}async deserializeEventStream({response:e,responseSchema:r,initialResponseContainer:n,initialMessageType:s}){let o=this.marshaller,i=r.getEventStreamMember(),c=r.getMemberSchema(i).getMemberSchemas(),u=Symbol("initialResponseMarker"),p=o.deserialize(e.body,async g=>{let E="";for(let R in g)if(k(g,R)&&R!=="__type"){E=R;break}let _=g[E].body;if(E===(s??"initial-response")){let R=await this.deserializer.read(r,_);return delete R[i],{[u]:!0,...R}}else if(E in c){let R=c[E];if(R.isStructSchema()){let T={},I=!1;for(let[P,v]of R.structIterator()){let{eventHeader:Z,eventPayload:Pe}=v.getMergedTraits();if(I=I||!!(Z||Pe),Pe)v.isBlobSchema()?T[P]=_:v.isStringSchema()?T[P]=(this.serdeContext?.utf8Encoder??_e)(_):v.isStructSchema()&&(T[P]=await this.deserializer.read(v,_));else if(Z){let be=g[E].headers[P]?.value;be!=null&&(v.isNumericSchema()?be&&typeof be=="object"&&"bytes"in be?T[P]=BigInt(be.toString()):T[P]=Number(be):T[P]=be)}}return{[E]:await this.readEventMember(R,_,I,T)}}return{[E]:await this.deserializer.read(R,_)}}else return{$unknown:g}}),d=p[Symbol.asyncIterator](),m=await d.next();if(m.done)return p;if(m.value?.[u]){if(!r)throw new Error("@smithy::core/protocols - initial-response event encountered in event stream but no response schema given.");for(let g in m.value)k(m.value,g)&&(n[g]=m.value[g])}return{async*[Symbol.asyncIterator](){for(m?.value?.[u]||(yield m.value);;){let{done:g,value:E}=await d.next();if(g)break;yield E}}}}async readEventMember(e,r,n,s){let o,i=e.getSchema();if(Array.isArray(i)&&i[0]===-3){let c=i[1],u=ce.for(c);this.compositeErrorRegistry?.copyFrom(u),o=(this.compositeErrorRegistry??u)?.getErrorCtor(i)}let a=n?s:r.byteLength===0?{}:await this.deserializer.read(e,r);if(o){let c=a.message??a.Message??"Unknown",u={},p=e.getMergedTraits().error;return p&&(u.$fault=p),Object.assign(new o({}),u,{message:c},a)}return a}writeEventBody(e,r,n){let s=this.serializer,o=e,i=null,a,c=r.getSchema()[4].includes(e),u={};if(c){let m=r.getMemberSchema(e);if(m.isStructSchema()){for(let[g,E]of m.structIterator()){let{eventHeader:_,eventPayload:R}=E.getMergedTraits();if(R)i=g;else if(_){let T=n[e][g],I="binary";E.isNumericSchema()?(-2)**31<=T&&T<=2**31-1?I="integer":I="long":E.isTimestampSchema()?I="timestamp":E.isStringSchema()?I="string":E.isBooleanSchema()&&(I="boolean"),T!=null&&(u[g]={type:I,value:T},delete n[e][g])}}if(i!==null){let g=m.getMemberSchema(i);g.isBlobSchema()?a="application/octet-stream":g.isStringSchema()&&(a="text/plain"),s.write(g,n[e][i])}else s.write(m,n[e])}else if(m.isUnitSchema())s.write(m,{});else throw new Error("@smithy/core/event-streams - non-struct member not supported in event stream union.")}else{let[m,g]=n[e];o=m,s.write(15,g)}let p=s.flush()??new Uint8Array;return{body:typeof p=="string"?(this.serdeContext?.utf8Decoder??tt)(p):p,eventType:o,explicitPayloadContentType:a,additionalHeaders:u}}}});var fk={};at(fk,{EventStreamCodec:()=>_a,EventStreamMarshaller:()=>bu,EventStreamSerde:()=>Wf,HeaderMarshaller:()=>ya,Int64:()=>no,MessageDecoderStream:()=>Ra,MessageEncoderStream:()=>Ta,SmithyMessageDecoderStream:()=>Aa,SmithyMessageEncoderStream:()=>Ia,UniversalEventStreamMarshaller:()=>oi,eventStreamSerdeProvider:()=>ok,getChunkedStream:()=>Vf,getMessageUnmarshaller:()=>Cu,getUnmarshalledStream:()=>rk,iterableToReadableStream:()=>ck,readableStreamToIterable:()=>ak,resolveEventStreamSerdeConfig:()=>lk,universalEventStreamSerdeProvider:()=>nk});var mk=f(()=>{RT();_T();yT();TT();AT();IT();xT();ik();uk();wT();CT();bT();dk();pk()});var oo,zf=f(()=>{W();K();W();ha();oo=class extends lt{options;compositeErrorRegistry;constructor(e){super(),this.options=e,this.compositeErrorRegistry=new ce(e.defaultNamespace);for(let r of e.errorTypeRegistries??[])this.compositeErrorRegistry.copyFrom(r)}getRequestType(){return J}getResponseType(){return ct}setSerdeContext(e){this.serdeContext=e,this.serializer.setSerdeContext(e),this.deserializer.setSerdeContext(e),this.getPayloadCodec()&&this.getPayloadCodec().setSerdeContext(e)}updateServiceEndpoint(e,r){if("url"in r){e.protocol=r.url.protocol,e.hostname=r.url.hostname,e.port=r.url.port?Number(r.url.port):void 0,e.path=r.url.pathname,e.fragment=r.url.hash||void 0,e.username=r.url.username||void 0,e.password=r.url.password||void 0,e.query||(e.query={});for(let[n,s]of r.url.searchParams.entries())e.query[n]=s;if(r.headers)for(let n in r.headers)k(r.headers,n)&&(e.headers[n]=r.headers[n].join(", "));return e}else{if(e.protocol=r.protocol,e.hostname=r.hostname,e.port=r.port?Number(r.port):void 0,e.path=r.path,e.query={...r.query},r.headers)for(let n in r.headers)k(r.headers,n)&&(e.headers[n]=r.headers[n]);return e}}setHostPrefix(e,r,n){if(this.serdeContext?.disableHostPrefix)return;let s=x.of(r.input),o=Wr(r.traits??{});if(o.endpoint){let i=o.endpoint?.[0];if(typeof i=="string"){for(let[a,c]of s.structIterator()){if(!c.getMergedTraits().hostLabel)continue;let u=n[a];if(typeof u!="string")throw new Error(`@smithy/core/schema - ${a} in input must be a string as hostLabel.`);i=i.replace(`{${a}}`,u)}if(e.hostname=i+e.hostname,!Zc(e.hostname))throw new Error(`[${e.hostname}] is not a valid hostname.`)}}}deserializeMetadata(e){return{httpStatusCode:e.statusCode,requestId:e.headers["x-amzn-requestid"]??e.headers["x-amzn-request-id"]??e.headers["x-amz-request-id"],extendedRequestId:e.headers["x-amz-id-2"],cfId:e.headers["x-amz-cf-id"]}}resolveError(e,r,n){let s=[-3,"","Error",0,[],[],0],o;for(let i of n)for(let a of r)try{a==="*"?o=i.getSchema(e):o=i.getSchema(a+"#"+e);let c=i.getErrorCtor(o);if(c)return[o,c,"modeled"];{let u=i.getBaseException();if(u){let p=i.getErrorCtor(u);if(p)return[o,p,"synthetic"]}}}catch{}for(let i of n){let a=i.getBaseException();if(a){let c=i.getErrorCtor(a);if(c)return[a,c,"synthetic"]}}return[s,Error,"native"]}async serializeEventStream({eventStream:e,requestSchema:r,initialRequest:n}){return(await this.loadEventStreamCapability()).serializeEventStream({eventStream:e,requestSchema:r,initialRequest:n})}async deserializeEventStream({response:e,responseSchema:r,initialResponseContainer:n}){return(await this.loadEventStreamCapability()).deserializeEventStream({response:e,responseSchema:r,initialResponseContainer:n})}async loadEventStreamCapability(){let{EventStreamSerde:e,eventStreamSerdeProvider:r}=await Promise.resolve().then(()=>(mk(),fk)),n=this.resolveEventStreamMarshaller(r);return new e({marshaller:n,serializer:this.serializer,deserializer:this.deserializer,serdeContext:this.serdeContext,defaultContentType:this.getDefaultContentType(),compositeErrorRegistry:this.compositeErrorRegistry})}getDefaultContentType(){throw new Error(`@smithy/core/protocols - ${this.constructor.name} getDefaultContentType() implementation missing.`)}async deserializeHttpMessage(e,r,n,s,o){return[]}getEventStreamMarshaller(){let e=this.serdeContext;if(!e.eventStreamMarshaller)throw new Error("@smithy/core - HttpProtocol: eventStreamMarshaller missing in serdeContext.");return e.eventStreamMarshaller}resolveEventStreamMarshaller(e){let r=this.serdeContext;return r.eventStreamMarshaller?r.eventStreamMarshaller:e(this.serdeContext)}}});var io,hk=f(()=>{W();K();L();W();zf();ma();Lf();io=class extends oo{async serializeRequest(e,r,n){let s=r&&typeof r=="object"?r:{},o=this.serializer,i={},a={},c=await n.endpoint(),u=x.of(e?.input),p=[],d=[],m=!1,g,E=new J({protocol:"",hostname:"",port:void 0,path:"",fragment:void 0,query:i,headers:a,body:void 0});if(c){this.updateServiceEndpoint(E,c),this.setHostPrefix(E,e,s);let _=Wr(e.traits);if(_.http){E.method=_.http[0];let[R,T]=_.http[1].split("?");E.path=="/"?E.path=R:E.path+=R;let I=new URLSearchParams(T??"");for(let[P,v]of I)i[P]=v}}for(let[_,R]of u.structIterator()){let T=R.getMergedTraits()??{},I=s[_];if(I==null&&!R.isIdempotencyToken()){if(T.httpLabel&&(E.path.includes(`{${_}+}`)||E.path.includes(`{${_}}`)))throw new Error(`No value provided for input HTTP label: ${_}.`);continue}if(T.httpPayload)R.isStreaming()?R.isStructSchema()?s[_]&&(g=await this.serializeEventStream({eventStream:s[_],requestSchema:u})):g=I:(o.write(R,I),g=o.flush());else if(T.httpLabel){o.write(R,I);let P=o.flush();E.path.includes(`{${_}+}`)?E.path=E.path.replace(`{${_}+}`,P.split("/").map(Kr).join("/")):E.path.includes(`{${_}}`)&&(E.path=E.path.replace(`{${_}}`,Kr(P)))}else if(T.httpHeader)o.write(R,I),a[T.httpHeader.toLowerCase()]=String(o.flush());else if(typeof T.httpPrefixHeaders=="string")for(let P in I){if(!k(I,P))continue;let v=I[P],Z=T.httpPrefixHeaders+P;o.write([R.getValueSchema(),{httpHeader:Z}],v),a[Z.toLowerCase()]=o.flush()}else T.httpQuery||T.httpQueryParams?this.serializeQuery(R,I,i):(m=!0,p.push(_),d.push(R))}if(m&&s){let[_,R]=(u.getName(!0)??"#Unknown").split("#"),T=u.getSchema()[6],I=[3,_,R,u.getMergedTraits(),p,d,void 0];T?I[6]=T:I.pop(),o.write(I,s),g=o.flush()}return E.headers=a,E.query=i,E.body=g,E}serializeQuery(e,r,n){let s=this.serializer,o=e.getMergedTraits();if(o.httpQueryParams){for(let i in r)if(k(r,i)&&!(i in n)){let a=r[i],c=e.getValueSchema();Object.assign(c.getMergedTraits(),{...o,httpQuery:i,httpQueryParams:void 0}),this.serializeQuery(c,a,n)}return}if(e.isListSchema()){let i=!!e.getMergedTraits().sparse,a=[];for(let c of r){s.write([e.getValueSchema(),o],c);let u=s.flush();(i||u!==void 0)&&a.push(u)}n[o.httpQuery]=a}else s.write([e,o],r),n[o.httpQuery]=s.flush()}async deserializeResponse(e,r,n){let s=this.deserializer,o=x.of(e.output),i={};if(n.statusCode>=300){let c=await Ge(n.body,r);throw c.byteLength>0&&Object.assign(i,await s.read(15,c)),await this.handleError(e,r,n,i,this.deserializeMetadata(n)),new Error("@smithy/core/protocols - HTTP Protocol error handler failed to throw.")}for(let c in n.headers){if(!k(n.headers,c))continue;let u=n.headers[c];delete n.headers[c],n.headers[c.toLowerCase()]=u}let a=await this.deserializeHttpMessage(o,r,n,i);if(a.length){let c=await Ge(n.body,r);if(c.byteLength>0){let u=await s.read(o,c);for(let p of a)u[p]!=null&&(i[p]=u[p])}}else a.discardResponseBody&&await Ge(n.body,r);return i.$metadata=this.deserializeMetadata(n),i}async deserializeHttpMessage(e,r,n,s,o){let i;s instanceof Set?i=o:i=s;let a=!0,c=this.deserializer,u=x.of(e),p=[];for(let[d,m]of u.structIterator()){let g=m.getMemberTraits();if(g.httpPayload){if(a=!1,m.isStreaming())m.isStructSchema()?i[d]=await this.deserializeEventStream({response:n,responseSchema:u}):i[d]=Mf(n.body);else if(n.body){let _=await Ge(n.body,r);_.byteLength>0&&(i[d]=await c.read(m,_))}}else if(g.httpHeader){let E=String(g.httpHeader).toLowerCase(),_=n.headers[E];if(_!=null)if(m.isListSchema()){let R=m.getValueSchema();R.getMergedTraits().httpHeader=E;let T;R.isTimestampSchema()&&R.getSchema()===4?T=Wp(_,",",2):T=na(_);let I=[];for(let P of T)I.push(await c.read(R,P.trim()));i[d]=I}else i[d]=await c.read(m,_)}else if(g.httpPrefixHeaders!==void 0){i[d]={};for(let E in n.headers)if(k(n.headers,E)&&E.startsWith(g.httpPrefixHeaders)){let _=n.headers[E],R=m.getValueSchema();R.getMergedTraits().httpHeader=E,i[d][E.slice(g.httpPrefixHeaders.length)]=await c.read(R,_)}}else g.httpResponseCode?i[d]=n.statusCode:p.push(d)}return p.discardResponseBody=a,p}}});var Ir,DT=f(()=>{W();K();W();zf();ma();Ir=class extends oo{async serializeRequest(e,r,n){let s=this.serializer,o={},i={},a=await n.endpoint(),c=x.of(e?.input),u=c.getSchema(),p,d=r&&typeof r=="object"?r:{},m=new J({protocol:"",hostname:"",port:void 0,path:"/",fragment:void 0,query:o,headers:i,body:void 0});if(a&&(this.updateServiceEndpoint(m,a),this.setHostPrefix(m,e,d)),d){let g=c.getEventStreamMember();if(g){if(d[g]){let E={};for(let[_]of c.structIterator())_!==g&&d[_]!=null&&(E[_]=d[_]);p=await this.serializeEventStream({eventStream:d[g],requestSchema:c,initialRequest:E})}}else s.write(u,d),p=s.flush()}return m.headers=Object.assign(m.headers,i),m.query=o,m.body=p,m.method="POST",m}async deserializeResponse(e,r,n){let s=this.deserializer,o=x.of(e.output),i={};if(n.statusCode>=300){let c=await Ge(n.body,r);throw c.byteLength>0&&Object.assign(i,await s.read(15,c)),await this.handleError(e,r,n,i,this.deserializeMetadata(n)),new Error("@smithy/core/protocols - RPC Protocol error handler failed to throw.")}for(let c in n.headers){if(!k(n.headers,c))continue;let u=n.headers[c];delete n.headers[c],n.headers[c.toLowerCase()]=u}let a=o.getEventStreamMember();if(a)i[a]=await this.deserializeEventStream({response:n,responseSchema:o,initialResponseContainer:i});else{let c=await Ge(n.body,r);c.byteLength>0&&Object.assign(i,await s.read(o,c))}return i.$metadata=this.deserializeMetadata(n),i}}});var jf,OT=f(()=>{Lf();jf=(t,e,r,n,s,o)=>{if(e!=null&&e[r]!==void 0){let i=n();if(i==null||i.length<=0)throw new Error("Empty value provided for input HTTP label: "+r+".");t=t.replace(s,o?i.split("/").map(a=>Kr(a)).join("/"):Kr(i))}else throw new Error("No value provided for input HTTP label: "+r+".");return t}});function qf(t,e){return new wu(t,e)}var wu,gk=f(()=>{W();OT();wu=class{input;context;query={};method="";headers={};path="";body=null;hostname="";resolvePathStack=[];constructor(e,r){this.input=e,this.context=r}async build(){let{hostname:e,protocol:r="https",port:n,path:s}=await this.context.endpoint();this.path=s;for(let o of this.resolvePathStack)o(this.path);return new J({protocol:r,hostname:this.hostname||e,port:n,method:this.method,path:this.path,query:this.query,body:this.body,headers:this.headers})}hn(e){return this.hostname=e,this}bp(e){return this.resolvePathStack.push(r=>{this.path=`${r?.endsWith("/")?r.slice(0,-1):r||""}`+e}),this}p(e,r,n,s){return this.resolvePathStack.push(o=>{this.path=jf(o,this.input,e,r,n,s)}),this}h(e){return this.headers=e,this}q(e){return this.query=e,this}b(e){return this.body=e,this}m(e){return this.method=e,this}}});function Ae(t,e){if(e.timestampFormat.useTrait&&t.isTimestampSchema()&&(t.getSchema()===5||t.getSchema()===6||t.getSchema()===7))return t.getSchema();let{httpLabel:r,httpPrefixHeaders:n,httpHeader:s,httpQuery:o}=t.getMergedTraits();return(e.httpBindings?typeof n=="string"||s?6:o||r?5:void 0:void 0)??e.timestampFormat.default}var ao=f(()=>{});var co,vT=f(()=>{K();L();ha();ao();co=class extends lt{settings;constructor(e){super(),this.settings=e}read(e,r){let n=x.of(e);if(n.isListSchema())return na(r).map(s=>this.read(n.getValueSchema(),s));if(n.isBlobSchema())return(this.serdeContext?.base64Decoder??Te)(r);if(n.isTimestampSchema())switch(Ae(n,this.settings)){case 5:return Hp(r);case 6:return Vp(r);case 7:return Zs(r);default:return console.warn("Missing timestamp format, parsing value with Date constructor:",r),new Date(r)}if(n.isStringSchema()){let s=n.getMergedTraits().mediaType,o=r;if(s)return n.getMergedTraits().httpHeader&&(o=this.base64ToUtf8(o)),(s==="application/json"||s.endsWith("+json"))&&(o=Se.from(o)),o}return n.isNumericSchema()?Number(r):n.isBigIntegerSchema()?BigInt(r):n.isBigDecimalSchema()?new $(r,"bigDecimal"):n.isBooleanSchema()?String(r).toLowerCase()==="true":r}base64ToUtf8(e){return(this.serdeContext?.utf8Encoder??_e)((this.serdeContext?.base64Decoder??Te)(e))}}});var uo,Sk=f(()=>{K();L();ha();vT();uo=class extends lt{codecDeserializer;stringDeserializer;constructor(e,r){super(),this.codecDeserializer=e,this.stringDeserializer=new co(r)}setSerdeContext(e){this.stringDeserializer.setSerdeContext(e),this.codecDeserializer.setSerdeContext(e),this.serdeContext=e}read(e,r){let n=x.of(e),s=n.getMergedTraits(),o=this.serdeContext?.utf8Encoder??_e;if(s.httpHeader||s.httpResponseCode)return this.stringDeserializer.read(n,o(r));if(s.httpPayload){if(n.isBlobSchema()){let i=this.serdeContext?.utf8Decoder??tt;return typeof r=="string"?i(r):r}else if(n.isStringSchema())return"byteLength"in r?o(r):r}return this.codecDeserializer.read(n,r)}}});var xa,PT=f(()=>{K();L();ha();ao();xa=class extends lt{settings;stringBuffer="";constructor(e){super(),this.settings=e}write(e,r){let n=x.of(e);switch(typeof r){case"object":if(r===null){this.stringBuffer="null";return}if(n.isTimestampSchema()){if(!(r instanceof Date))throw new Error(`@smithy/core/protocols - received non-Date value ${r} when schema expected Date in ${n.getName(!0)}`);switch(Ae(n,this.settings)){case 5:this.stringBuffer=r.toISOString().replace(".000Z","Z");break;case 6:this.stringBuffer=yt(r);break;case 7:this.stringBuffer=String(r.getTime()/1e3);break;default:console.warn("Missing timestamp format, using epoch seconds",r),this.stringBuffer=String(r.getTime()/1e3)}return}if(n.isBlobSchema()&&"byteLength"in r){this.stringBuffer=(this.serdeContext?.base64Encoder??ne)(r);return}if(n.isListSchema()&&Array.isArray(r)){let i="";for(let a of r){this.write([n.getValueSchema(),n.getMergedTraits()],a);let c=this.flush(),u=n.getValueSchema().isTimestampSchema()?c:Gp(c);i!==""&&(i+=", "),i+=u}this.stringBuffer=i;return}this.stringBuffer=JSON.stringify(r,null,2);break;case"string":let s=n.getMergedTraits().mediaType,o=r;if(s&&((s==="application/json"||s.endsWith("+json"))&&(o=Se.from(o)),n.getMergedTraits().httpHeader)){this.stringBuffer=(this.serdeContext?.base64Encoder??ne)(o.toString());return}this.stringBuffer=r;break;default:n.isIdempotencyToken()?this.stringBuffer=Rt():this.stringBuffer=String(r)}}flush(){let e=this.stringBuffer;return this.stringBuffer="",e}}});var lo,Ek=f(()=>{K();PT();lo=class{codecSerializer;stringSerializer;buffer;constructor(e,r,n=new xa(r)){this.codecSerializer=e,this.stringSerializer=n}setSerdeContext(e){this.codecSerializer.setSerdeContext(e),this.stringSerializer.setSerdeContext(e)}write(e,r){let n=x.of(e),s=n.getMergedTraits();if(s.httpHeader||s.httpLabel||s.httpQuery){this.stringSerializer.write(n,r),this.buffer=this.stringSerializer.flush();return}return this.codecSerializer.write(n,r)}flush(){if(this.buffer!==void 0){let e=this.buffer;return this.buffer=void 0,e}return this.codecSerializer.flush()}}});var yk,Kf,_k=f(()=>{yk=ye(Hr()),Kf=class{name;kind;values;constructor({name:e,kind:r=yk.FieldPosition.HEADER,values:n=[]}){this.name=e,this.kind=r,this.values=n}add(e){this.values.push(e)}set(e){this.values=e}remove(e){this.values=this.values.filter(r=>r!==e)}toString(){return this.values.map(e=>e.includes(",")||e.includes(" ")?`"${e}"`:e).join(", ")}get(){return this.values}}});var Yf,Rk=f(()=>{Yf=class{entries={};encoding;constructor({fields:e=[],encoding:r="utf-8"}){e.forEach(this.setField.bind(this)),this.encoding=r}setField(e){this.entries[e.name.toLowerCase()]=e}getField(e){return this.entries[e.toLowerCase()]}removeField(e){delete this.entries[e.toLowerCase()]}getByType(e){return Object.values(this.entries).filter(r=>r.kind===e)}}});var Hn,Vn,Tk=f(()=>{Hn=t=>(t.logger&&t.logger.constructor?.name!=="NoOpLogger"&&t.requestHandler?.updateHttpClientConfig?.(Symbol.for("logger"),t.logger),{setHttpHandler(e){t.requestHandler=e},httpHandler(){return t.requestHandler},updateHttpClientConfig(e,r){t.requestHandler?.updateHttpClientConfig(e,r)},httpHandlerConfigs(){return t.requestHandler.httpHandlerConfigs()}}),Vn=t=>({requestHandler:t.httpHandler()})});function NT(t){return e=>async r=>{let n=r.request;if(J.isInstance(n)){let{body:s,headers:o}=n;if(s&&Object.keys(o).map(i=>i.toLowerCase()).indexOf(Ak)===-1)try{let i=t(s);i!=null&&(n.headers={...n.headers,[Ak]:String(i)})}catch{}}return e({...r,request:n})}}var Ak,kT,Wn,Ik=f(()=>{W();Ak="content-length";kT={step:"build",tags:["SET_CONTENT_LENGTH","CONTENT_LENGTH"],name:"contentLengthMiddleware",override:!0},Wn=t=>({applyToStack:e=>{e.add(NT(t.bodyLengthChecker),kT)}})});var po,zZ,Qf=f(()=>{po=t=>encodeURIComponent(t).replace(/[!'()*]/g,zZ),zZ=t=>`%${t.charCodeAt(0).toString(16).toUpperCase()}`});var xk,Ck=f(()=>{Qf();xk=t=>t.split("/").map(po).join("/")});function bk(t){let e=[];for(let r of Object.keys(t).sort()){let n=t[r];if(r=po(r),Array.isArray(n))for(let s=0,o=n.length;s<o;s++)e.push(`${r}=${po(n[s])}`);else{let s=r;(n||typeof n=="string")&&(s+=`=${po(n)}`),e.push(s)}}return e.join("&")}var wk=f(()=>{Qf()});var Xt,ii=f(()=>{Xt=class{serdeContext;setSerdeContext(e){this.serdeContext=e}}});var Ca,MT=f(()=>{Ca=class{from;to;keys;constructor(e,r){this.from=e,this.to=r;let n=Object.keys(this.from),s=new Set(n);s.delete("__type"),this.keys=s}mark(e){this.keys.delete(e)}hasUnknown(){return this.keys.size===1&&Object.keys(this.to).length===0}writeUnknown(){if(this.hasUnknown()){let e=this.keys.values().next().value,r=this.from[e];this.to.$unknown=[e,r]}}}});function Jf(){if(Du===void 0)try{if(typeof Buffer!="function")Du=!1;else{let t=JSON.parse(Buffer.from([123,125]));Du=t!==null&&typeof t=="object"}}catch{Du=!1}return Du}var Du,LT=f(()=>{});function ba(t,e,r){if(r?.source){let n=r.source;if(typeof e=="number")return e<=Number.MAX_SAFE_INTEGER&&e>=Number.MIN_SAFE_INTEGER?qZ(n,e)?e:new $(n,"bigDecimal"):jZ(n)?new $(n,"bigDecimal"):/[eE]/.test(n)?KZ(n):BigInt(n)}return e}function jZ(t){let e=t.indexOf(".");if(e===-1)return!1;let r=t.search(/[eE]/);if(r===-1)return!0;let n=r-e-1;return parseInt(t.slice(r+1),10)<n}function qZ(t,e){if(t===String(e)||Object.is(e,-0))return!0;if(/[eE]/.test(t))return $T(t)===$T(String(e));let r=t.replace(/(\.\d*?)0+$/,"$1").replace(/\.$/,""),n=String(e);return r===n?!0:/[eE]/.test(n)?r===$T(n):!1}function $T(t){let e=t.startsWith("-"),r=e?t.slice(1):t,n=r.search(/[eE]/),s;if(n===-1)s=r;else{let o=parseInt(r.slice(n+1),10),i=r.slice(0,n),a=i.indexOf("."),c,u;a===-1?(c=i,u=i.length):(c=i.slice(0,a)+i.slice(a+1),u=a),c=c.replace(/0+$/,"")||"0";let p=u+o;c==="0"?s="0":p<=0?s="0."+"0".repeat(-p)+c:p>=c.length?s=c+"0".repeat(p-c.length):s=c.slice(0,p)+"."+c.slice(p)}return s.includes(".")&&(s=s.replace(/(\.\d*?)0+$/,"$1").replace(/\.$/,"")),(e?"-":"")+s}function KZ(t){let e=t.search(/[eE]/),r=parseInt(t.slice(e+1),10),n=t.startsWith("-"),s=t.slice(n?1:0,e),o=s.indexOf("."),i,a;if(o===-1)i=s,a=r;else{i=s.slice(0,o)+s.slice(o+1);let u=s.length-o-1;a=r-u}i=i.replace(/0+$/,"")||"0";let c=BigInt(i)*10n**BigInt(a+(s.replace(".","").length-i.length));return n?-c:c}var Xf=f(()=>{L()});function wa(t){let e=x.of(t),r=e.getSchema();if(Array.isArray(r)&&e.isStructSchema()){if(FT in r)return r[FT];let n=Zf(e,new Set);return r[FT]=n,n}return Zf(e,new Set)}function Zf(t,e){let r=t.getSchema();if(e.has(r))return!1;if(e.add(r),t.isBigIntegerSchema()||t.isBigDecimalSchema())return!0;if(t.isStructSchema()){for(let[,n]of t.structIterator())if(Zf(n,e))return!0}else if(t.isListSchema()||t.isMapSchema()){if(Zf(t.getValueSchema(),e))return!0}else if(t.isDocumentSchema())return!0;return!1}var FT,em=f(()=>{K();FT=Symbol.for("@aws-sdk/reviver")});var Dk,Ok=f(()=>{ma();L();Dk=(t,e)=>Ge(t,e).then(r=>(e?.utf8Encoder??_e)(r))});async function ai(t,e,r){let n;if(Jf()&&typeof t?.[Symbol.asyncIterator]=="function"){let o=await Ge(t,e);typeof Buffer=="function"&&(Buffer.isBuffer(o)?n=o:n=Buffer.from(o.buffer,o.byteOffset,o.byteLength))}if(n||(n=await Dk(t,e)),n.length===0)return{};let s=r&&wa(r)?ba:void 0;try{return JSON.parse(n,s)}catch(o){throw o?.name==="SyntaxError"&&Object.defineProperty(o,"$responseBodyText",{value:typeof n=="string"?n:n.toString("utf8")}),o}}var Pk,vk,UT,Nk,kk,tm,Mk,Ou=f(()=>{ma();Ok();LT();Xf();em();Pk=async(t,e)=>{let r=await ai(t,e);return r.message=r.message??r.Message,r},vk=(t,e)=>Object.keys(t).find(r=>r.toLowerCase()===e.toLowerCase()),UT=t=>{let e=t;return typeof e=="number"&&(e=e.toString()),e.indexOf(",")>=0&&(e=e.split(",")[0]),e.indexOf(":")>=0&&(e=e.split(":")[0]),e.indexOf("#")>=0&&(e=e.split("#")[1]),e},Nk=(t,e)=>Mk(t,e,["header","code","type"]),kk=(t,e,r=!1)=>Mk(t,e,r?["code","header","type"]:["type","code","header"]),tm=(t,e)=>{if(e?.__type!==void 0){let r=e.__type;return typeof r=="number"&&(r=r.toString()),r.indexOf(",")>=0&&(r=r.split(",")[0]),r.indexOf(":")>=0&&(r=r.split(":")[0]),r}},Mk=({headers:t},e,r)=>{for(;r.length>0;)switch(r.shift()){case"header":let s=vk(t??{},"x-amzn-errortype");if(s!==void 0)return UT(t[s]);break;case"code":let o=vk(e??{},"code");if(o&&e[o]!==void 0)return UT(e[o]);break;case"type":if(e?.__type!==void 0)return UT(e.__type);break}}});function zn(t){Object.defineProperty(t,"__proto__",{value:void 0,writable:!0,enumerable:!0,configurable:!0})}var rm=f(()=>{});var Da,BT=f(()=>{ao();K();L();ii();MT();LT();Xf();em();Ou();rm();W();Da=class extends Xt{settings;constructor(e){super(),this.settings=e}async read(e,r){let n=wa(e)?ba:void 0,s;if(typeof r=="string"){if(r.length===0)return{};s=JSON.parse(r,n)}else if(r instanceof Uint8Array&&Jf()){if(r.byteLength===0)return{};let o=Buffer.isBuffer(r)?r:Buffer.from(r.buffer,r.byteOffset,r.byteLength);s=JSON.parse(o,n)}else s=await ai(r,this.serdeContext,e);return this._read(e,s)}readObject(e,r){return this._read(e,r)}_read(e,r){let n=r!==null&&typeof r=="object",s=x.of(e);if(n){if(s.isStructSchema())return this._readStruct(s,r);if(Array.isArray(r)&&s.isListSchema()){let i=s.getValueSchema();if(this.needsTransform(i))for(let a=0;a<r.length;++a)r[a]=this._read(i,r[a]);return r}if(s.isMapSchema()){let i=s.getValueSchema(),a=r;if(this.needsTransform(i))for(let c in a)k(a,c)&&(c==="__proto__"&&zn(a),a[c]=this._read(i,a[c]));return a}}if(s.isBlobSchema()&&typeof r=="string")return Te(r);let o=s.getMergedTraits().mediaType;if(s.isStringSchema()&&typeof r=="string"&&o)return o==="application/json"||o.endsWith("+json")?Se.from(r):r;if(s.isTimestampSchema()&&r!=null)switch(Ae(s,this.settings)){case 5:return Dn(r);case 6:return _r(r);case 7:return On(r);default:return console.warn("Missing timestamp format, parsing value with Date constructor:",r),new Date(r)}if(s.isBigIntegerSchema()&&(typeof r=="number"||typeof r=="string"))return BigInt(r);if(s.isBigDecimalSchema()&&r!=null){if(r instanceof $)return r;let i=r;return i.type==="bigDecimal"&&"string"in i?new $(i.string,i.type):new $(String(r),"bigDecimal")}if(s.isNumericSchema()&&typeof r=="string"){switch(r){case"Infinity":return 1/0;case"-Infinity":return-1/0;case"NaN":return NaN}return r}if(s.isDocumentSchema()&&n)if(Array.isArray(r))for(let i=0;i<r.length;++i){let a=r[i];a instanceof $||(r[i]=this._read(s,a))}else{let i=r;for(let a in i){if(!k(i,a))continue;a==="__proto__"&&zn(i);let c=i[a];c instanceof $||(i[a]=this._read(s,c))}}return r}_readStruct(e,r){let n=e.isUnionSchema(),s={},o,i=typeof r.__type=="string",{jsonName:a}=this.settings;a&&i&&(o={});let c;n&&(c=new Ca(r,s));for(let[u,p]of e.structIterator()){let d=u;a&&(d=p.getMergedTraits().jsonName??d,i&&(o[d]=u)),n&&c.mark(d),r[d]!=null&&(s[u]=this._read(p,r[d]))}if(n)c.writeUnknown();else if(i)for(let u in r){if(!k(r,u))continue;let p=r[u],d=a?o[u]??u:u;d in s||(s[d]=p)}return s}needsTransform(e){return!!(e.isBlobSchema()||e.isTimestampSchema()||e.isBigIntegerSchema()||e.isBigDecimalSchema()||e.isNumericSchema()||e.isDocumentSchema()||e.isStructSchema()||e.isListSchema()||e.isMapSchema()||e.isStringSchema()&&e.getMergedTraits().mediaType)}}});var nm,Lk,$k=f(()=>{L();nm=class t extends Uint8Array{string=null;static allocUnsafe(e){if(typeof Buffer=="function"){let r=Buffer.allocUnsafe(e);return new t(r.buffer,r.byteOffset,r.byteLength)}return new t(e)}toString(){return this.s()}valueOf(){return this.s()}includes(e,r){return typeof e=="string"?this.s().includes(e,r):Uint8Array.prototype.includes.call(this,e,r)}indexOf(e,r){return typeof e=="string"?this.s().indexOf(e,r):Uint8Array.prototype.indexOf.call(this,e,r)}lastIndexOf(e,r){if(typeof e=="string")return this.s().lastIndexOf(e,r);let n=Uint8Array.prototype.lastIndexOf;return r!==void 0?n.call(this,e,r):n.call(this,e)}startsWith(e,r){return this.s().startsWith(e,r)}endsWith(e,r){return this.s().endsWith(e,r)}match(e){return this.s().match(e)}replace(e,r){return this.s().replace(e,r)}search(e){return this.s().search(e)}split(e,r){return this.s().split(e,r)}substring(e,r){return this.s().substring(e,r)}trim(){return this.s().trim()}trimStart(){return this.s().trimStart()}trimEnd(){return this.s().trimEnd()}charAt(e){return this.s().charAt(e)}charCodeAt(e){return this.s().charCodeAt(e)}padStart(e,r){return this.s().padStart(e,r)}padEnd(e,r){return this.s().padEnd(e,r)}repeat(e){return this.s().repeat(e)}toUpperCase(){return this.s().toUpperCase()}toLowerCase(){return this.s().toLowerCase()}s(){if(this.string==null){let e=Date.now();e>Lk+6e4&&(console.warn("@aws-sdk/core/protocols - WARN - JsonCodec2: you have called a string method on a Uint8Array request body. It has been automatically converted to string. In a future version this will throw an error."),Lk=e),this.string=_e(this)}return this.string}},Lk=0});function GT(t){return nm.allocUnsafe(t)}var sm,Fk,Uk,YZ,QZ,Oa,om,im,Bk,JZ,XZ,ZZ,jn,Gk,va,HT=f(()=>{ao();K();L();ii();W();$k();sm=new TextEncoder,Fk=123,Uk=125,YZ=91,QZ=93,Oa=34,om=58,im=44,Bk=92,JZ=new Uint8Array([116,114,117,101]),XZ=new Uint8Array([102,97,108,115,101]),ZZ=new Uint8Array([110,117,108,108]),jn=new Array(128).fill(null);jn[8]="b";jn[9]="t";jn[10]="n";jn[12]="f";jn[13]="r";jn[34]='"';jn[92]="\\";for(let t=0;t<32;t++)jn[t]===null&&(jn[t]="u00"+t.toString(16).padStart(2,"0"));Gk=2048;va=class t extends Xt{settings;json;i=0;rootSchema;rawValue;passthrough=!1;constructor(e){super(),this.settings=e,this.json=GT(Gk)}write(e,r){this.i=0,this.rawValue=r,this.rootSchema=x.of(e),this.passthrough=this.rootSchema.isBlobSchema()||this.rootSchema.isStringSchema(),this.passthrough||this.writeValue(this.rootSchema,r,void 0)}writeDiscriminatedDocument(e,r){this.i=0,this.rootSchema=x.of(e);let n=this.rootSchema;if(n.isStructSchema()&&r!=null&&typeof r=="object"){this.writeValue(n,r,void 0);let s=`"__type":"${n.getName(!0)??"Unknown"}",`,o=s.length;this.ensure(o),this.json.copyWithin(1+o,1,this.i),sm.encodeInto(s,this.json.subarray(1)),this.i+=o}else this.writeValue(n,r,void 0)}flush(){this.rootSchema=void 0;let e=this.i;this.i=0;let r=this.rawValue;if(this.rawValue=void 0,e===0)return r;let n=this.json.subarray(0,e);return this.json=GT(Gk),n}ensure(e){let{i:r,json:n}=this;if(r+e>n.length){let s=n.length*2;for(;s<r+e;)s*=2;let o=GT(s);o.set(this.json),this.json=o}}writeAscii(e){let r=e.length;this.ensure(r);let{i:n,json:s}=this;for(let o=0;o<r;++o)s[n]=e.charCodeAt(o),n+=1;this.i=n}writeAsciiQuoted(e){let r=e.length;this.ensure(r+4);let{json:n,i:s}=this;n[s++]=Oa;for(let o=0;o<r;++o)n[s++]=e.charCodeAt(o);n[s++]=Oa,this.i=s}writeJsonString(e){this.ensure(e.length*3+2),this.json[this.i++]=Oa;let r=e.length;for(let n=0;n<r;++n){let s=e.charCodeAt(n);if(s>34&&s<92)this.json[this.i++]=s;else if(s<128){let o=jn[s];if(o!==null){this.ensure(o.length+1),this.json[this.i++]=Bk;for(let i=0;i<o.length;i++)this.json[this.i++]=o.charCodeAt(i)}else this.json[this.i++]=s}else if(s>=55296&&s<=56319){let o=n+1<r?e.charCodeAt(n+1):0;if(o>=56320&&o<=57343){this.ensure(4);let{written:i}=sm.encodeInto(e.substring(n,n+2),this.json.subarray(this.i));this.i+=i,++n}else this.ensure(6),this.writeUnicodeEscape(s)}else if(s>=56320&&s<=57343)this.ensure(6),this.writeUnicodeEscape(s);else{let{i:o,json:i}=this;s<2048?(i[o++]=192|s>>6,i[o++]=128|s&63):(i[o++]=224|s>>12,i[o++]=128|s>>6&63,i[o++]=128|s&63),this.i=o}}this.json[this.i++]=Oa}writeUnicodeEscape(e){let{json:r,i:n}=this;r[n++]=Bk,r[n++]=117;let s=e.toString(16).padStart(4,"0");for(let o=0;o<4;++o)r[n++]=s.charCodeAt(o);this.i=n}static B64=(()=>{let e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",r=new Uint8Array(64);for(let n=0;n<64;++n)r[n]=e.charCodeAt(n);return r})();writeBase64(e){let r=Math.ceil(e.length/3)*4;this.ensure(r+2);let n=this.json,s=t.B64,o=this.i;n[o++]=Oa;let i=e.length,a=i%3,c=i-a;for(let u=0;u<c;u+=3){let p=e[u],d=e[u+1],m=e[u+2];n[o++]=s[p>>2],n[o++]=s[(p&3)<<4|d>>4],n[o++]=s[(d&15)<<2|m>>6],n[o++]=s[m&63]}if(a===2){let u=e[c],p=e[c+1];n[o++]=s[u>>2],n[o++]=s[(u&3)<<4|p>>4],n[o++]=s[(p&15)<<2],n[o++]=61}else if(a===1){let u=e[c];n[o++]=s[u>>2],n[o++]=s[(u&3)<<4],n[o++]=61,n[o++]=61}n[o++]=Oa,this.i=o}writeValue(e,r,n){if(r==null){if(n?.isStructSchema()){if(r===void 0&&x.of(e).isIdempotencyToken()){this.writeAsciiQuoted(Rt());return}return}this.ensure(4),this.json.set(ZZ,this.i),this.i+=4;return}let s=x.of(e),o=typeof r=="object";if(s.isStringSchema()){let i=s.getMergedTraits().mediaType;if(i&&(i==="application/json"||i.endsWith("+json"))){this.writeJsonString(Se.from(r).toString());return}}if(this.settings.bigNumberAsString&&r!=null&&(s.isBigIntegerSchema()||s.isBigDecimalSchema())){let i=r instanceof $?r.string:String(r);this.writeAsciiQuoted(i);return}if(o){if(s.isStructSchema()){this.writeStruct(s,r);return}if(Array.isArray(r)&&(s.isListSchema()||s.isDocumentSchema())){this.writeList(s,r,s.isDocumentSchema());return}if(s.isMapSchema()){this.writeMap(s,r,!1);return}if(r instanceof Uint8Array&&(s.isBlobSchema()||s.isDocumentSchema())){this.writeBase64(r);return}if(r instanceof Date&&(s.isTimestampSchema()||s.isDocumentSchema())){this.writeTimestamp(s,r);return}if(r instanceof $){this.writeAscii(r.string);return}if(s.isDocumentSchema()){Array.isArray(r)?this.writeList(s,r,!0):this.writeMap(s,r,!0);return}let i=JSON.stringify(r);this.writeAscii(i);return}if(typeof r=="string"){if(s.isBlobSchema()){let i=(this.serdeContext?.base64Encoder??ne)(r);this.writeAsciiQuoted(i);return}this.writeJsonString(r);return}if(typeof r=="number"){if(Math.abs(r)===1/0||Number.isNaN(r)){this.writeAsciiQuoted(String(r));return}let i=String(r);this.writeAscii(i);return}if(typeof r=="boolean"){this.ensure(5);let{i,json:a}=this;r?(a.set(JZ,i),i+=4):(a.set(XZ,i),i+=5),this.i=i;return}if(typeof r=="bigint"){this.writeAscii(r.toString());return}this.writeAscii(String(r))}writeStruct(e,r){this.ensure(2),this.json[this.i++]=Fk;let n=!1,s=typeof r.__type=="string",o;s&&(o=new Set);for(let[i,a]of e.structIterator()){let c=r[i];if(c==null&&!a.isIdempotencyToken())continue;n&&(this.ensure(1),this.json[this.i++]=im),n=!0;let u=this.settings.jsonName?a.getMergedTraits().jsonName??i:i;o&&(o.add(i),o.add(u)),this.writeAsciiQuoted(u),this.json[this.i++]=om,this.writeValue(a,c,e)}if(!n&&e.isUnionSchema()){let{$unknown:i}=r;if(Array.isArray(i)){let[a,c]=i;this.writeAsciiQuoted(a),this.ensure(1),this.json[this.i++]=om,this.writeValue(15,c,e)}}else if(s)for(let i in r){if(o.has(i))continue;o.add(i);let a=r[i];n&&(this.ensure(1),this.json[this.i++]=im),n=!0,this.writeAsciiQuoted(i),this.ensure(1),this.json[this.i++]=om,this.writeValue(15,a,void 0)}this.ensure(1),this.json[this.i++]=Uk}writeList(e,r,n){let s=!!e.getMergedTraits().sparse,o=e.getValueSchema();if(!n&&(o.isStringSchema()||o.isNumericSchema()||o.isBooleanSchema())){let a=!1;for(let u=0;u<r.length;++u){let p=r[u];if(Number.isNaN(p)||p===1/0||p===-1/0||p==null&&!s){a=!0;break}}let c;if(!a)c=JSON.stringify(r);else{let u=[];for(let p=0;p<r.length;++p){let d=r[p];d==null&&!s||(Number.isNaN(d)||d===1/0||d===-1/0?u.push(String(d)):u.push(d))}c=JSON.stringify(u)}this.ensure(c.length*3),this.i+=sm.encodeInto(c,this.json.subarray(this.i)).written;return}this.ensure(2),this.json[this.i++]=YZ;let i=!1;for(let a=0;a<r.length;++a){let c=r[a];(n?c===void 0:c==null&&!s)||(i&&(this.ensure(1),this.json[this.i++]=im),this.writeValue(o,c,void 0),i=!0)}this.ensure(1),this.json[this.i++]=QZ}writeMap(e,r,n){let s=!!e.getMergedTraits().sparse,o=e.getValueSchema();if(!n&&(o.isStringSchema()||o.isNumericSchema()||o.isBooleanSchema())){let a;for(let u in r){if(!k(r,u))continue;let p=r[u];Number.isNaN(p)||p===1/0||p===-1/0?((a??={})[u]=p,r[u]=String(p)):p===null&&!s&&((a??={})[u]=null,r[u]=void 0)}let c=JSON.stringify(r);a&&Object.assign(r,a),this.ensure(c.length*3),this.i+=sm.encodeInto(c,this.json.subarray(this.i)).written;return}this.ensure(2),this.json[this.i++]=Fk;let i=!0;for(let a in r){if(!k(r,a))continue;let c=r[a];(n?c===void 0:c==null&&!s)||(i||(this.ensure(1),this.json[this.i++]=im),i=!1,this.writeJsonString(a),this.ensure(1),this.json[this.i++]=om,this.writeValue(o,c,void 0))}this.ensure(1),this.json[this.i++]=Uk}writeTimestamp(e,r){switch(Ae(e,this.settings)){case 5:{let s=r.toISOString().replace(".000Z","Z");this.writeAsciiQuoted(s);return}case 6:{this.writeAsciiQuoted(yt(r));return}case 7:{let s=String(r.getTime()/1e3);this.writeAscii(s);return}default:{let s=String(r.getTime()/1e3);this.writeAscii(s);return}}}}});var Pa,VT=f(()=>{ii();BT();HT();Pa=class extends Xt{settings;constructor(e){super(),this.settings=e}createSerializer(){let e=new va(this.settings);return e.setSerdeContext(this.serdeContext),e}createDeserializer(){let e=new Da(this.settings);return e.setSerdeContext(this.serdeContext),e}}});var am,Hk=f(()=>{DT();K();W();VT();Ou();am=class extends Ir{codec=new Pa({timestampFormat:{useTrait:!1,default:7},jsonName:!1,bigNumberAsString:!0});serializer=this.codec.createSerializer();deserializer=this.codec.createDeserializer();constructor({defaultNamespace:e,errorTypeRegistries:r}){super({defaultNamespace:e,errorTypeRegistries:r})}getShapeId(){return"smithy.protocols#rpcv2Json"}getPayloadCodec(){return this.codec}async serializeRequest(e,r,n){let s=await super.serializeRequest(e,r,n);Object.assign(s.headers,{"content-type":this.getDefaultContentType(),"smithy-protocol":"rpc-v2-json",accept:this.getDefaultContentType()}),Yt(e.input)==="unit"?(delete s.body,delete s.headers["content-type"]):s.body||(s.body="{}");let{service:o,operation:i}=he(n),a=`/service/${o}/operation/${i}`;return s.path.endsWith("/")?s.path+=a.slice(1):s.path+=a,s}async deserializeResponse(e,r,n){return super.deserializeResponse(e,r,n)}async handleError(e,r,n,s,o){let i=tm(n,s)??"Unknown",a={$metadata:o,$fault:n.statusCode<=500?"client":"server"},c=this.options.defaultNamespace;i.includes("#")&&([c]=i.split("#"));let u=this.compositeErrorRegistry,p=ce.for(c);u.copyFrom(p);let d;try{d=u.getSchema(i)}catch{s.Message&&(s.message=s.Message);let P=ce.for("smithy.ts.sdk.synthetic."+c);u.copyFrom(P);let v=u.getBaseException();if(v){let Z=u.getErrorCtor(v);throw Object.assign(new Z({name:i}),a,s)}throw Object.assign(new Error(i),a,s)}let m=x.of(d),g=u.getErrorCtor(d),E=s.message??s.Message??"Unknown",_=new g({}),R={},T=this.codec.createDeserializer();for(let[I,P]of m.structIterator())s[I]!=null&&(R[I]=T.readObject(P,s[I]));throw Object.assign(_,a,{$fault:m.getMergedTraits().error,message:E},R)}getDefaultContentType(){return"application/json"}}});var Na,WT=f(()=>{ao();K();L();L();W();ii();MT();Xf();em();Ou();rm();Na=class extends Xt{settings;constructor(e){super(),this.settings=e}async read(e,r){let n=wa(e)?ba:void 0;return this._read(e,typeof r=="string"?JSON.parse(r,n):await ai(r,this.serdeContext,e))}readObject(e,r){return this._read(e,r)}_read(e,r){let n=r!==null&&typeof r=="object",s=x.of(e);if(n){if(s.isStructSchema()){let i=r,a=s.isUnionSchema(),c={},u,{jsonName:p}=this.settings;p&&(u={});let d;a&&(d=new Ca(i,c));for(let[m,g]of s.structIterator()){let E=m;p&&(E=g.getMergedTraits().jsonName??E,u[E]=m),a&&d.mark(E),i[E]!=null&&(c[m]=this._read(g,i[E]))}if(a)d.writeUnknown();else if(typeof i.__type=="string")for(let m in i){if(!k(i,m))continue;let g=i[m],E=p?u[m]??m:m;E in c||(c[E]=g)}return c}if(Array.isArray(r)&&s.isListSchema()){let i=s.getValueSchema(),a=[];for(let c of r)a.push(this._read(i,c));return a}if(s.isMapSchema()){let i=s.getValueSchema(),a={};for(let c in r)k(r,c)&&(c==="__proto__"&&zn(a),a[c]=this._read(i,r[c]));return a}}if(s.isBlobSchema()&&typeof r=="string")return Te(r);let o=s.getMergedTraits().mediaType;if(s.isStringSchema()&&typeof r=="string"&&o)return o==="application/json"||o.endsWith("+json")?Se.from(r):r;if(s.isTimestampSchema()&&r!=null)switch(Ae(s,this.settings)){case 5:return Dn(r);case 6:return _r(r);case 7:return On(r);default:return console.warn("Missing timestamp format, parsing value with Date constructor:",r),new Date(r)}if(s.isBigIntegerSchema()&&(typeof r=="number"||typeof r=="string"))return BigInt(r);if(s.isBigDecimalSchema()&&r!=null){if(r instanceof $)return r;let i=r;return i.type==="bigDecimal"&&"string"in i?new $(i.string,i.type):new $(String(r),"bigDecimal")}if(s.isNumericSchema()&&typeof r=="string"){switch(r){case"Infinity":return 1/0;case"-Infinity":return-1/0;case"NaN":return NaN}return r}if(s.isDocumentSchema())if(n){let i=Array.isArray(r)?[]:{};for(let a in r){if(!k(r,a))continue;a==="__proto__"&&zn(i);let c=r[a];c instanceof $?i[a]=c:i[a]=this._read(s,c)}return i}else return structuredClone(r);return r}}});var Vk,cm,Wk=f(()=>{L();Vk="\u039D",cm=class{values=new Map;counter=0;stage=0;createReplacer(){if(this.stage===1)throw new Error("@aws-sdk/core/protocols - JsonReplacer already created.");if(this.stage===2)throw new Error("@aws-sdk/core/protocols - JsonReplacer exhausted.");return this.stage=1,(e,r)=>{if(r instanceof $){let n=`${Vk+"nv"+this.counter++}_`+r.string;return this.values.set(`"${n}"`,r.string),n}if(typeof r=="bigint"){let n=r.toString(),s=`${Vk+"b"+this.counter++}_`+n;return this.values.set(`"${s}"`,n),s}return r}}replaceInJson(e){if(this.stage===0)throw new Error("@aws-sdk/core/protocols - JsonReplacer not created yet.");if(this.stage===2)throw new Error("@aws-sdk/core/protocols - JsonReplacer exhausted.");if(this.stage=2,this.counter===0)return e;for(let[r,n]of this.values)e=e.replace(r,n);return e}}});var ka,zT=f(()=>{ao();K();L();ii();Wk();rm();W();ka=class extends Xt{settings;buffer;useReplacer=!1;rootSchema;constructor(e){super(),this.settings=e}write(e,r){this.rootSchema=x.of(e),this.buffer=this._write(this.rootSchema,r)}flush(){let{rootSchema:e,useReplacer:r}=this;if(this.rootSchema=void 0,this.useReplacer=!1,e?.isStructSchema()||e?.isDocumentSchema()){if(!r)return JSON.stringify(this.buffer);let n=new cm;return n.replaceInJson(JSON.stringify(this.buffer,n.createReplacer(),0))}return this.buffer}writeDiscriminatedDocument(e,r){this.write(e,r),typeof this.buffer=="object"&&(this.buffer.__type=x.of(e).getName(!0))}_write(e,r,n){let s=r!==null&&typeof r=="object",o=x.of(e);if(s){if(o.isStructSchema()){let i=r,a={},{jsonName:c}=this.settings,u;c&&(u={});let p=0;for(let[d,m]of o.structIterator()){let g=this._write(m,i[d],o);if(g!==void 0){let E=d;c&&(E=m.getMergedTraits().jsonName??d,u[d]=E),a[E]=g,p++}}if(o.isUnionSchema()&&p===0){let{$unknown:d}=i;if(Array.isArray(d)){let[m,g]=d;m==="__proto__"&&zn(a),a[m]=this._write(15,g)}}else if(typeof i.__type=="string")for(let d in i){if(!k(i,d))continue;let m=i[d],g=c?u[d]??d:d;g in a||(a[g]=this._write(15,m))}return a}if(Array.isArray(r)&&o.isListSchema()){let i=o.getValueSchema(),a=[],c=!!o.getMergedTraits().sparse;for(let u of r)(c||u!=null)&&a.push(this._write(i,u));return a}if(o.isMapSchema()){let i=o.getValueSchema(),a={},c=!!o.getMergedTraits().sparse;for(let u in r){if(!k(r,u))continue;let p=r[u];(c||p!=null)&&(u==="__proto__"&&zn(a),a[u]=this._write(i,p))}return a}if(r instanceof Uint8Array&&o.isBlobSchema())return o===this.rootSchema?r:(this.serdeContext?.base64Encoder??ne)(r);if(r instanceof Date&&(o.isTimestampSchema()||o.isDocumentSchema()))switch(Ae(o,this.settings)){case 5:return r.toISOString().replace(".000Z","Z");case 6:return yt(r);case 7:return r.getTime()/1e3;default:return console.warn("Missing timestamp format, using epoch seconds",r),r.getTime()/1e3}r instanceof $&&(this.useReplacer=!0)}if(!(r===null&&n?.isStructSchema())){if(o.isStringSchema()){if(typeof r>"u"&&o.isIdempotencyToken())return Rt();let i=o.getMergedTraits().mediaType;return r!=null&&i&&(i==="application/json"||i.endsWith("+json"))?Se.from(r):r}if(typeof r=="number")return Math.abs(r)===1/0||isNaN(r)?String(r):r;if(typeof r=="string"&&o.isBlobSchema())return o===this.rootSchema?r:(this.serdeContext?.base64Encoder??ne)(r);if(typeof r=="bigint"&&(this.useReplacer=!0),o.isDocumentSchema())if(s){if(r instanceof Uint8Array)return(this.serdeContext?.base64Encoder??ne)(r);let i=Array.isArray(r)?[]:{};for(let a in r){if(!k(r,a))continue;let c=r[a];a==="__proto__"&&zn(i),c instanceof $?(this.useReplacer=!0,i[a]=c):i[a]=this._write(o,c)}return i}else return structuredClone(r);return r}}}});var um,zk=f(()=>{ii();WT();zT();um=class extends Xt{settings;constructor(e){super(),this.settings=e}createSerializer(){let e=new ka(this.settings);return e.setSerdeContext(this.serdeContext),e}createDeserializer(){let e=new Na(this.settings);return e.setSerdeContext(this.serdeContext),e}}});var qn={};at(qn,{Field:()=>Kf,Fields:()=>Yf,FromStringShapeDeserializer:()=>co,HttpBindingProtocol:()=>io,HttpInterceptingShapeDeserializer:()=>uo,HttpInterceptingShapeSerializer:()=>lo,HttpProtocol:()=>oo,HttpRequest:()=>J,HttpResponse:()=>ct,JsonCodec:()=>um,JsonCodec2:()=>Pa,JsonShapeDeserializer:()=>Na,JsonShapeDeserializer2:()=>Da,JsonShapeSerializer:()=>ka,JsonShapeSerializer2:()=>va,RequestBuilder:()=>wu,RpcProtocol:()=>Ir,SerdeContext:()=>lt,SmithyRpcV2JsonProtocol:()=>am,ToStringShapeSerializer:()=>xa,buildQueryString:()=>bk,collectBody:()=>Ge,contentLengthMiddleware:()=>NT,contentLengthMiddlewareOptions:()=>kT,determineTimestampFormat:()=>Ae,escapeUri:()=>po,escapeUriPath:()=>xk,extendedEncodeURIComponent:()=>Kr,getContentLengthPlugin:()=>Wn,getHttpHandlerExtensionConfiguration:()=>Hn,isValidHostname:()=>Zc,loadJsonRpcErrorCode:()=>kk,loadRestJsonErrorCode:()=>Nk,loadSmithyRpcV2JsonErrorCode:()=>tm,parseJsonBody:()=>ai,parseJsonErrorBody:()=>Pk,parseQueryString:()=>eu,parseUrl:()=>Et,requestBuilder:()=>qf,resolveHttpHandlerRuntimeConfig:()=>Vn,resolvedPath:()=>jf});var G=f(()=>{ma();Lf();hk();zf();DT();gk();OT();vT();Sk();Ek();PT();ao();ha();_k();Rk();W();W();W();Tk();Ik();Qf();Ck();wk();W();W();Hk();Ou();zk();zT();WT();VT();HT();BT()});var jk,qk,Kk,Yk,Qk,Jk,Xk=f(()=>{jk=["AccessDeniedException","AuthFailure","InvalidSignatureException","RequestExpired","RequestInTheFuture","RequestTimeTooSkewed","SignatureDoesNotMatch"],qk=["BandwidthLimitExceeded","EC2ThrottledException","LimitExceededException","PriorRequestNotComplete","ProvisionedThroughputExceededException","RequestLimitExceeded","RequestThrottled","RequestThrottledException","SlowDown","ThrottledException","Throttling","ThrottlingException","TooManyRequestsException","TransactionInProgressException"],Kk=["TimeoutError","RequestTimeout","RequestTimeoutException"],Yk=[500,502,503,504],Qk=["ECONNRESET","ECONNREFUSED","EPIPE","ETIMEDOUT"],Jk=["EHOSTUNREACH","ENETUNREACH","ENOTFOUND","EAI_AGAIN"]});function KT(t){return t.code==="ERR_HTTP2_STREAM_ERROR"&&t.message.includes("NGHTTP2_REFUSED_STREAM")}var vu,lm,jT,qT,Kn,fo,dm,Ma=f(()=>{Xk();vu=t=>t?.$retryable!==void 0,lm=t=>jk.includes(t.name),jT=t=>t.$metadata?.clockSkewCorrected,qT=t=>{let e=new Set(["Failed to fetch","NetworkError when attempting to fetch resource","The Internet connection appears to be offline","Load failed","Network request failed"]);return t&&t instanceof TypeError?e.has(t.message):!1},Kn=t=>t.$metadata?.httpStatusCode===429||qk.includes(t.name)||t.$retryable?.throttling==!0,fo=(t,e=0)=>t?.name!=="AbortError"&&(vu(t)||jT(t)||t.name==="InvalidSignatureException"&&t.message?.includes("Signature expired")||Kk.includes(t.name)||Qk.includes(t?.code||"")||Jk.includes(t?.code||"")||Yk.includes(t.$metadata?.httpStatusCode||0)||qT(t)||KT(t)||t.cause!==void 0&&e<=10&&fo(t.cause,e+1)),dm=t=>{if(t.$metadata?.httpStatusCode!==void 0){let e=t.$metadata.httpStatusCode;return 500<=e&&e<=599&&!fo(t)}return!1}});var pm,Pu,fm,La,YT,QT,mm,mo,ho,Nu=f(()=>{pm=100,Pu=2e4,fm=500,La=500,YT=5,QT=10,mm=1,mo="amz-sdk-invocation-id",ho="amz-sdk-request"});function JT(t,e){if(ct.isInstance(t))for(let r in t.headers){if(!k(t.headers,r))continue;let n=r.toLowerCase();if(n==="retry-after"){let s=t.headers[r],o=NaN;if(s.endsWith("GMT"))try{o=(_r(s).getTime()-Date.now())/1e3}catch(i){e?.trace?.("Failed to parse retry-after header"),e?.trace?.(i)}else s.match(/ GMT, ((\d+)|(\d+\.\d+))$/)?o=Number(s.match(/ GMT, ([\d.]+)$/)?.[1]):s.match(/^((\d+)|(\d+\.\d+))$/)?o=Number(s):Date.parse(s)>=Date.now()&&(o=(Date.parse(s)-Date.now())/1e3);return isNaN(o)?void 0:new Date(Date.now()+o*1e3)}else if(n==="x-amz-retry-after"){let s=t.headers[r],o=Number(s);if(isNaN(o)){e?.trace?.(`Failed to parse x-amz-retry-after=${s}`);return}return new Date(Date.now()+o)}}}function Zk(t,e){return JT(t,e)}var XT=f(()=>{W();G();L()});var hm,ZT=f(()=>{hm=t=>t instanceof Error?t:t instanceof Object?Object.assign(new Error,t):typeof t=="string"?new Error(t):new Error(`AWS SDK error wrapper for ${t}`)});function eA(t){return e=>(r,n)=>async s=>{let o=await e.retryStrategy(),i=await e.maxAttempts();if(tee(o)){o=o;let a=await o.acquireInitialRetryToken((n.partition_id??"")+(n.__retryLongPoll?":longpoll":"")),c=new Error,u=0,p=0,{request:d}=s,m=J.isInstance(d);for(m&&(d.headers[mo]=fa());;)try{m&&(d.headers[ho]=`attempt=${u+1}; max=${i}`);let{response:g,output:E}=await r(s);return o.recordSuccess(a),E.$metadata.attempts=u+1,E.$metadata.totalRetryDelay=p,{response:g,output:E}}catch(g){let E=ree(g,e.logger);if(c=hm(g),m&&t(d))throw(n.logger instanceof Qt?console:n.logger)?.warn("An error was encountered in a non-retryable streaming request."),c;try{a=await o.refreshRetryTokenForRetry(a,E)}catch{throw c.$metadata||(c.$metadata={}),c.$metadata.attempts=u+1,c.$metadata.totalRetryDelay=p,c}u=a.getRetryCount();let _=a.getRetryDelay();p+=(a?.$retryLog?.acquisitionDelay??0)+_,_>0&&await eee(_)}}else return o=o,o?.mode&&(n.userAgent=[...n.userAgent||[],["cfg/retry-mode",o.mode]]),o.retry(r,s)}}function eM(t){let e=eA(t);return r=>({applyToStack:n=>{n.add(e(r),tA)}})}var eee,tee,ree,nee,tA,rA=f(()=>{V();G();L();Ma();Nu();XT();ZT();eee=t=>new Promise(e=>setTimeout(e,t)),tee=t=>typeof t.acquireInitialRetryToken<"u"&&typeof t.refreshRetryTokenForRetry<"u"&&typeof t.recordSuccess<"u",ree=(t,e)=>{let r={error:t,errorType:nee(t)},n=JT(t.$response,e);return n&&(r.retryAfterHint=n),r},nee=t=>Kn(t)?"THROTTLING":fo(t)?"TRANSIENT":dm(t)?"SERVER_ERROR":"CLIENT_ERROR",tA={name:"retryMiddleware",tags:["RETRY"],step:"finalizeRequest",priority:"high",override:!0}});var go,gm=f(()=>{Ma();go=class t{static setTimeoutFn=(e,r)=>setTimeout(e,r);beta;minCapacity;minFillRate;scaleConstant;smooth;enabled=!1;availableTokens=0;lastMaxRate=0;measuredTxRate=0;requestCount=0;fillRate;lastThrottleTime;lastTimestamp=0;lastTxRateBucket;maxCapacity;timeWindow=0;constructor(e){this.beta=e?.beta??.7,this.minCapacity=e?.minCapacity??1,this.minFillRate=e?.minFillRate??.5,this.scaleConstant=e?.scaleConstant??.4,this.smooth=e?.smooth??.8,this.lastThrottleTime=this.getCurrentTimeInSeconds(),this.lastTxRateBucket=Math.floor(this.getCurrentTimeInSeconds()),this.fillRate=this.minFillRate,this.maxCapacity=this.minCapacity}async getSendToken(){return this.acquireTokenBucket(1)}updateClientSendingRate(e){let r;this.updateMeasuredRate();let n=e;if(n?.errorType==="THROTTLING"||Kn(n?.error??e)){let i=this.enabled?Math.min(this.measuredTxRate,this.fillRate):this.measuredTxRate;this.lastMaxRate=i,this.calculateTimeWindow(),this.lastThrottleTime=this.getCurrentTimeInSeconds(),r=this.cubicThrottle(i),this.enableTokenBucket()}else this.calculateTimeWindow(),r=this.cubicSuccess(this.getCurrentTimeInSeconds());let o=Math.min(r,2*this.measuredTxRate);this.updateTokenBucketRate(o)}getCurrentTimeInSeconds(){return Date.now()/1e3}async acquireTokenBucket(e){if(this.enabled){for(this.refillTokenBucket();e>this.availableTokens;){let r=(e-this.availableTokens)/this.fillRate*1e3;await new Promise(n=>t.setTimeoutFn(n,r)),this.refillTokenBucket()}this.availableTokens=this.availableTokens-e}}refillTokenBucket(){let e=this.getCurrentTimeInSeconds();if(!this.lastTimestamp){this.lastTimestamp=e;return}let r=(e-this.lastTimestamp)*this.fillRate;this.availableTokens=Math.min(this.maxCapacity,this.availableTokens+r),this.lastTimestamp=e}calculateTimeWindow(){this.timeWindow=this.getPrecise(Math.pow(this.lastMaxRate*(1-this.beta)/this.scaleConstant,1/3))}cubicThrottle(e){return this.getPrecise(e*this.beta)}cubicSuccess(e){return this.getPrecise(this.scaleConstant*Math.pow(e-this.lastThrottleTime-this.timeWindow,3)+this.lastMaxRate)}enableTokenBucket(){this.enabled=!0}updateTokenBucketRate(e){this.refillTokenBucket(),this.fillRate=Math.max(e,this.minFillRate),this.maxCapacity=Math.max(e,this.minCapacity),this.availableTokens=Math.min(this.availableTokens,this.maxCapacity)}updateMeasuredRate(){let e=this.getCurrentTimeInSeconds(),r=Math.floor(e*2)/2;if(this.requestCount++,r>this.lastTxRateBucket){let n=this.requestCount/(r-this.lastTxRateBucket);this.measuredTxRate=this.getPrecise(n*this.smooth+this.measuredTxRate*(1-this.smooth)),this.requestCount=0,this.lastTxRateBucket=r}}getPrecise(e){return parseFloat(e.toFixed(8))}}});var He,$a=f(()=>{He=class t{static v2026=typeof process<"u"&&process.env?.SMITHY_NEW_RETRIES_2026==="true";static delay(){return t.v2026?50:100}static throttlingDelay(){return t.v2026?1e3:500}static cost(){return t.v2026?14:5}static throttlingCost(){return t.v2026?5:10}static modifiedCostType(){return t.v2026?"THROTTLING":"TRANSIENT"}}});var Sm,tM=f(()=>{$a();Sm=class{x=He.delay();computeNextBackoffDelay(e){let s=Math.random()*Math.min(this.x*2**e,2e4);return Math.floor(s)}setDelayBase(e){this.x=e}}});var ku,rM=f(()=>{ku=class{delay;count;cost;longPoll;$retryLog={acquisitionDelay:0};constructor(e,r,n,s){this.delay=e,this.count=r,this.cost=n,this.longPoll=s}getRetryCount(){return this.count}getRetryDelay(){return Math.min(2e4,this.delay)}getRetryCost(){return this.cost}isLongPoll(){return this.longPoll}}});var dt,Qr,xr,ci=f(()=>{(function(t){t.STANDARD="standard",t.ADAPTIVE="adaptive"})(dt||(dt={}));Qr=3,xr=dt.STANDARD});var Em,Jr,Mu=f(()=>{tM();rM();ci();$a();Em={incompatible:1,attempts:2,capacity:3},Jr=class{mode=dt.STANDARD;retryBackoffStrategy;capacity=500;maxAttemptsProvider;baseDelay;constructor(e){typeof e=="number"?this.maxAttemptsProvider=async()=>e:typeof e=="function"?this.maxAttemptsProvider=e:e&&typeof e=="object"&&(this.maxAttemptsProvider=async()=>e.maxAttempts,this.baseDelay=e.baseDelay,this.retryBackoffStrategy=e.backoff),this.maxAttemptsProvider??=async()=>Qr,this.baseDelay??=He.delay(),this.retryBackoffStrategy??=new Sm}async acquireInitialRetryToken(e){return new ku(He.delay(),0,void 0,He.v2026&&e.includes(":longpoll"))}async refreshRetryTokenForRetry(e,r){let n=await this.getMaxAttempts(),s=this.retryCode(e,r,n),o=s===0,i=e.isLongPoll?.();if(o||i){let a=r.errorType;this.retryBackoffStrategy.setDelayBase(a==="THROTTLING"?He.throttlingDelay():this.baseDelay);let c=this.retryBackoffStrategy.computeNextBackoffDelay(e.getRetryCount()),u=c;if(r.retryAfterHint instanceof Date&&(u=Math.max(c,Math.min(r.retryAfterHint.getTime()-Date.now(),c+5e3))),o){let p=this.getCapacityCost(a);this.capacity-=p;let d=new ku(0,e.getRetryCount()+1,p,e.isLongPoll?.()??!1);return await new Promise(m=>setTimeout(m,u)),d.$retryLog.acquisitionDelay=u,d}else{let p=He.v2026&&s===Em.capacity&&i?u:0;p>0&&await new Promise(d=>setTimeout(d,p))}}throw new Error("No retry token available")}recordSuccess(e){this.capacity=Math.min(500,this.capacity+(e.getRetryCost()??1))}getCapacity(){return this.capacity}async maxAttempts(){return this.maxAttemptsProvider()}async getMaxAttempts(){try{return await this.maxAttemptsProvider()}catch{return console.warn(`Max attempts provider could not resolve. Using default of ${Qr}`),Qr}}retryCode(e,r,n){let s=e.getRetryCount()+1,o=this.isRetryableError(r.errorType)?0:Em.incompatible,i=s<n?0:Em.attempts,a=this.capacity>=this.getCapacityCost(r.errorType)?0:Em.capacity;return o||i||a}getCapacityCost(e){return e===He.modifiedCostType()?He.throttlingCost():He.cost()}isRetryableError(e){return e==="THROTTLING"||e==="TRANSIENT"}}});var Fa,nA=f(()=>{gm();Mu();ci();Fa=class{mode=dt.ADAPTIVE;rateLimiter;standardRetryStrategy;constructor(e,r){let{rateLimiter:n}=r??{};this.rateLimiter=n??new go,this.standardRetryStrategy=r?new Jr({maxAttempts:typeof e=="number"?e:3,...r}):new Jr(e)}async acquireInitialRetryToken(e){let r=await this.standardRetryStrategy.acquireInitialRetryToken(e);return await this.rateLimiter.getSendToken(),r}async refreshRetryTokenForRetry(e,r){this.rateLimiter.updateClientSendingRate(r);let n=await this.standardRetryStrategy.refreshRetryTokenForRetry(e,r);return await this.rateLimiter.getSendToken(),n}recordSuccess(e){this.rateLimiter.updateClientSendingRate({}),this.standardRetryStrategy.recordSuccess(e)}async maxAttemptsProvider(){return this.standardRetryStrategy.maxAttempts()}}});var ym,nM=f(()=>{Mu();$a();ym=class extends Jr{computeNextBackoffDelay;constructor(e,r=He.delay()){super(typeof e=="function"?e:async()=>e),typeof r=="number"?this.computeNextBackoffDelay=()=>r:this.computeNextBackoffDelay=r,this.retryBackoffStrategy.computeNextBackoffDelay=n=>{let s=n+1;return this.computeNextBackoffDelay(s)}}}});var sM,oM=f(()=>{sM=(t,e)=>{let r=t,n=e?.noRetryIncrement??1,s=e?.retryCost??5,o=e?.timeoutRetryCost??10,i=t,a=d=>d.name==="TimeoutError"?o:s,c=d=>a(d)<=i;return Object.freeze({hasRetryTokens:c,retrieveRetryTokens:d=>{if(!c(d))throw new Error("No retry token available");let m=a(d);return i-=m,m},releaseRetryTokens:d=>{i+=d??n,i=Math.min(i,r)}})}});var _m,sA=f(()=>{_m=(t,e)=>Math.floor(Math.min(2e4,Math.random()*2**e*t))});var Rm,oA=f(()=>{Ma();Rm=t=>t?vu(t)||lm(t)||Kn(t)||fo(t):!1});var Ua,see,iA=f(()=>{G();L();Ma();ci();Nu();ZT();oM();sA();oA();Ua=class{maxAttemptsProvider;retryDecider;delayDecider;retryQuota;mode=dt.STANDARD;constructor(e,r){this.maxAttemptsProvider=e,this.retryDecider=r?.retryDecider??Rm,this.delayDecider=r?.delayDecider??_m,this.retryQuota=r?.retryQuota??sM(500)}shouldRetry(e,r,n){return r<n&&this.retryDecider(e)&&this.retryQuota.hasRetryTokens(e)}async getMaxAttempts(){let e;try{e=await this.maxAttemptsProvider()}catch{e=Qr}return e}async retry(e,r,n){let s,o=0,i=0,a=await this.getMaxAttempts(),{request:c}=r;for(J.isInstance(c)&&(c.headers[mo]=fa());;)try{J.isInstance(c)&&(c.headers[ho]=`attempt=${o+1}; max=${a}`),n?.beforeRequest&&await n.beforeRequest();let{response:u,output:p}=await e(r);return n?.afterRequest&&n.afterRequest(u),this.retryQuota.releaseRetryTokens(s),p.$metadata.attempts=o+1,p.$metadata.totalRetryDelay=i,{response:u,output:p}}catch(u){let p=hm(u);if(o++,this.shouldRetry(p,o,a)){s=this.retryQuota.retrieveRetryTokens(p);let d=this.delayDecider(Kn(p)?500:100,o),m=see(p.$response),g=Math.max(m||0,d);i+=g,await new Promise(E=>setTimeout(E,g));continue}throw p.$metadata||(p.$metadata={}),p.$metadata.attempts=o,p.$metadata.totalRetryDelay=i,p}}},see=t=>{if(!ct.isInstance(t))return;let e=Object.keys(t.headers).find(o=>o.toLowerCase()==="retry-after");if(!e)return;let r=t.headers[e],n=Number(r);if(!Number.isNaN(n))return Math.min(n*1e3,2e4);let s=new Date(r);return Math.min(s.getTime()-Date.now(),2e4)}});var Tm,iM=f(()=>{gm();ci();iA();Tm=class extends Ua{rateLimiter;constructor(e,r){let{rateLimiter:n,...s}=r??{};super(e,s),this.rateLimiter=n??new go,this.mode=dt.ADAPTIVE}async retry(e,r){return super.retry(e,r,{beforeRequest:async()=>this.rateLimiter.getSendToken(),afterRequest:n=>{this.rateLimiter.updateClientSendingRate(n)}})}}});var Am,Im,Yn,Qn,aA,cA,Jn,aM=f(()=>{V();nA();Mu();ci();$a();Am="AWS_MAX_ATTEMPTS",Im="max_attempts",Yn={environmentVariableSelector:t=>{let e=t[Am];if(!e)return;let r=parseInt(e);if(Number.isNaN(r))throw new Error(`Environment variable ${Am} mast be a number, got "${e}"`);return r},configFileSelector:t=>{let e=t[Im];if(!e)return;let r=parseInt(e);if(Number.isNaN(r))throw new Error(`Shared config file entry ${Im} mast be a number, got "${e}"`);return r},default:Qr},Qn=(t,e)=>{let{retryStrategy:r,retryMode:n}=t,{defaultMaxAttempts:s=Qr,defaultBaseDelay:o=He.delay()}=e??{},i=ge(t.maxAttempts??s),a=r?Promise.resolve(r):void 0,c=async()=>{let u=await i();return await ge(n)()===dt.ADAPTIVE?new Fa(i,{maxAttempts:u,baseDelay:o}):new Jr({maxAttempts:u,baseDelay:o})};return Object.assign(t,{maxAttempts:i,retryStrategy:()=>a??=c()})},aA="AWS_RETRY_MODE",cA="retry_mode",Jn={environmentVariableSelector:t=>t[aA],configFileSelector:t=>t[cA],default:xr}});var uA,lA,cM,uM=f(()=>{G();Nu();uA=()=>t=>async e=>{let{request:r}=e;return J.isInstance(r)&&(delete r.headers[mo],delete r.headers[ho]),t(e)},lA={name:"omitRetryHeadersMiddleware",tags:["RETRY","HEADERS","OMIT_RETRY_HEADERS"],relation:"before",toMiddleware:"awsAuthMiddleware",override:!0},cM=t=>({applyToStack:e=>{e.addRelativeTo(uA(),lA)}})});var xm={};at(xm,{AdaptiveRetryStrategy:()=>Fa,CONFIG_MAX_ATTEMPTS:()=>Im,CONFIG_RETRY_MODE:()=>cA,ConfiguredRetryStrategy:()=>ym,DEFAULT_MAX_ATTEMPTS:()=>Qr,DEFAULT_RETRY_DELAY_BASE:()=>pm,DEFAULT_RETRY_MODE:()=>xr,DefaultRateLimiter:()=>go,DeprecatedAdaptiveRetryStrategy:()=>Tm,DeprecatedStandardRetryStrategy:()=>Ua,ENV_MAX_ATTEMPTS:()=>Am,ENV_RETRY_MODE:()=>aA,INITIAL_RETRY_TOKENS:()=>La,INVOCATION_ID_HEADER:()=>mo,MAXIMUM_RETRY_DELAY:()=>Pu,NODE_MAX_ATTEMPT_CONFIG_OPTIONS:()=>Yn,NODE_RETRY_MODE_CONFIG_OPTIONS:()=>Jn,NO_RETRY_INCREMENT:()=>mm,REQUEST_HEADER:()=>ho,RETRY_COST:()=>YT,RETRY_MODES:()=>dt,Retry:()=>He,StandardRetryStrategy:()=>Jr,THROTTLING_RETRY_DELAY_BASE:()=>fm,TIMEOUT_RETRY_COST:()=>QT,defaultDelayDecider:()=>_m,defaultRetryDecider:()=>Rm,getOmitRetryHeadersPlugin:()=>cM,getRetryAfterHint:()=>Zk,getRetryPlugin:()=>Os,isBrowserNetworkError:()=>qT,isClockSkewCorrectedError:()=>jT,isClockSkewError:()=>lm,isNodeJsHttp2TransientError:()=>KT,isRetryableByTrait:()=>vu,isServerError:()=>dm,isThrottlingError:()=>Kn,isTransientError:()=>fo,omitRetryHeadersMiddleware:()=>uA,omitRetryHeadersMiddlewareOptions:()=>lA,resolveRetryConfig:()=>Qn,retryMiddleware:()=>oee,retryMiddlewareOptions:()=>tA});var oee,Os,Zt=f(()=>{Iw();rA();Ma();nA();nM();gm();Mu();ci();Nu();$a();iM();iA();sA();oA();aM();uM();rA();XT();oee=eA(uR),Os=eM(uR)});function Cr(t,e,r){t.__aws_sdk_context?t.__aws_sdk_context.features||(t.__aws_sdk_context.features={}):t.__aws_sdk_context={features:{}},t.__aws_sdk_context.features[e]=r}var dA=f(()=>{Zt();He.v2026||=typeof process=="object"&&process.env?.AWS_NEW_RETRIES_2026==="true"});function lM(t,e,r){return t.$source||(t.$source={}),t.$source[e]=r,t}var dM=f(()=>{});function Ba(t){return t}var pA,fA,Xn,pM=f(()=>{G();pA=t=>e=>async r=>{if(!J.isInstance(r.request))return e(r);let{request:n}=r,{handlerProtocol:s=""}=t.requestHandler.metadata||{};if(s.indexOf("h2")>=0&&!n.headers[":authority"])delete n.headers.host,n.headers[":authority"]=n.hostname+(n.port?":"+n.port:"");else if(!n.headers.host){let o=n.hostname;n.port!=null&&(o+=`:${n.port}`),n.headers.host=o}return e(r)},fA={name:"hostHeaderMiddleware",step:"build",priority:"low",tags:["HOST"],override:!0},Xn=t=>({applyToStack:e=>{e.add(pA(t),fA)}})});var mA,hA,Zn,fM=f(()=>{mA=()=>(t,e)=>async r=>{try{let n=await t(r),{clientName:s,commandName:o,logger:i,dynamoDbDocumentClientOptions:a={}}=e,{overrideInputFilterSensitiveLog:c,overrideOutputFilterSensitiveLog:u}=a,p=c??e.inputFilterSensitiveLog,d=u??e.outputFilterSensitiveLog,{$metadata:m,...g}=n.output;return i?.info?.({clientName:s,commandName:o,input:p(r.input),output:d(g),metadata:m}),n}catch(n){let{clientName:s,commandName:o,logger:i,dynamoDbDocumentClientOptions:a={}}=e,{overrideInputFilterSensitiveLog:c}=a,u=c??e.inputFilterSensitiveLog;throw i?.error?.({clientName:s,commandName:o,input:u(r.input),error:n,metadata:n.$metadata}),n}},hA={name:"loggerMiddleware",tags:["LOGGER"],step:"initialize",override:!0},Zn=t=>({applyToStack:e=>{e.add(mA(),hA)}})});var Cm,gA=f(()=>{Cm={step:"build",tags:["RECURSION_DETECTION","TRACE_CONTEXT_PROPAGATION"],name:"recursionDetectionMiddleware",override:!0,priority:"low"}});var So,SA,bm,EA,yA,Lu,mM=f(()=>{So={REQUEST_ID:Symbol.for("_AWS_LAMBDA_REQUEST_ID"),X_RAY_TRACE_ID:Symbol.for("_AWS_LAMBDA_X_RAY_TRACE_ID"),TENANT_ID:Symbol.for("_AWS_LAMBDA_TENANT_ID"),TRACEPARENT:Symbol.for("_AWS_LAMBDA_TRACEPARENT"),TRACESTATE:Symbol.for("_AWS_LAMBDA_TRACESTATE"),BAGGAGE:Symbol.for("_AWS_LAMBDA_BAGGAGE")},SA=["true","1"].includes(process.env?.AWS_LAMBDA_NODEJS_NO_GLOBAL_AWSLAMBDA??"");SA||(globalThis.awslambda=globalThis.awslambda||{});bm=class{static PROTECTED_KEYS=So;isProtectedKey(e){return Object.values(So).includes(e)}getRequestId(){return this.get(So.REQUEST_ID)??"-"}getXRayTraceId(){return this.get(So.X_RAY_TRACE_ID)}getTenantId(){return this.get(So.TENANT_ID)}getTraceparent(){return this.get(So.TRACEPARENT)}getTracestate(){return this.get(So.TRACESTATE)}getBaggage(){return this.get(So.BAGGAGE)}},EA=class extends bm{currentContext;getContext(){return this.currentContext}hasContext(){return this.currentContext!==void 0}get(e){return this.currentContext?.[e]}set(e,r){if(this.isProtectedKey(e))throw new Error(`Cannot modify protected Lambda context field: ${String(e)}`);this.currentContext=this.currentContext||{},this.currentContext[e]=r}run(e,r){return this.currentContext=e,r()}},yA=class t extends bm{als;static async create(){let e=new t,r=await import("node:async_hooks");return e.als=new r.AsyncLocalStorage,e}getContext(){return this.als.getStore()}hasContext(){return this.als.getStore()!==void 0}get(e){return this.als.getStore()?.[e]}set(e,r){if(this.isProtectedKey(e))throw new Error(`Cannot modify protected Lambda context field: ${String(e)}`);let n=this.als.getStore();if(!n)throw new Error("No context available");n[e]=r}run(e,r){return this.als.run(e,r)}};(function(t){let e=null;async function r(n){return e||(e=(async()=>{let o=n===!0||"AWS_LAMBDA_MAX_CONCURRENCY"in process.env?await yA.create():new EA;return!SA&&globalThis.awslambda?.InvokeStore?globalThis.awslambda.InvokeStore:(!SA&&globalThis.awslambda&&(globalThis.awslambda.InvokeStore=o),o)})()),e}t.getInstanceAsync=r,t._testing=process.env.AWS_LAMBDA_BENCHMARK_MODE==="1"?{reset:()=>{e=null,globalThis.awslambda?.InvokeStore&&delete globalThis.awslambda.InvokeStore,globalThis.awslambda={InvokeStore:void 0}}}:void 0})(Lu||(Lu={}))});function cee(t){for(let e of Object.keys(t)){let r=e.toLowerCase();e!==r&&(r===RA||r===hM||r===gM)&&(t[r]=t[e],delete t[e])}}var iee,aee,_A,RA,hM,gM,wm,TA=f(()=>{mM();G();iee="AWS_LAMBDA_FUNCTION_NAME",aee="_X_AMZN_TRACE_ID",_A="X-Amzn-Trace-Id",RA="traceparent",hM="tracestate",gM="baggage",wm=()=>t=>async e=>{let{request:r}=e;if(!J.isInstance(r))return t(e);let n;{let s=Object.keys(r.headers??{}).find(o=>o.toLowerCase()===_A.toLowerCase())??_A;if(!r.headers.hasOwnProperty(s)){let o=process.env[iee],i=process.env[aee];n??=await Lu.getInstanceAsync();let c=n?.getXRayTraceId()??i,u=p=>typeof p=="string"&&p.length>0;u(o)&&u(c)&&(r.headers[_A]=c)}}if(cee(r.headers),!r.headers[RA]){let o=(n??=await Lu.getInstanceAsync())?.getTraceparent?.();if(o){r.headers[RA]=o;let i=n?.getTracestate?.();i&&(r.headers[hM]=i);let a=n?.getBaggage?.();a&&(r.headers[gM]=a)}}return t(e)}});var es,SM=f(()=>{gA();TA();es=t=>({applyToStack:e=>{e.add(wm(),Cm)}})});var EM,yM=f(()=>{EM=(t,e)=>{if(!e||e.length===0)return t;let r=[];for(let n of e)for(let s of t)s.schemeId.split("#")[1]===n&&r.push(s);for(let n of t)r.find(({schemeId:s})=>s===n.schemeId)||r.push(n);return r}});function uee(t){let e=new Map;for(let r of t)e.set(r.schemeId,r);return e}var ui,Dm=f(()=>{W();yM();ui=(t,e)=>(r,n)=>async s=>{let o=t.httpAuthSchemeProvider(await e.httpAuthSchemeParametersProvider(t,n,s.input)),i=t.authSchemePreference?await t.authSchemePreference():[],a=EM(o,i),c=uee(t.httpAuthSchemes),u=he(n),p=[];for(let d of a){let m=c.get(d.schemeId);if(!m){p.push(`HttpAuthScheme \`${d.schemeId}\` was not enabled for this service.`);continue}let g=m.identityProvider(await e.identityProviderConfigProvider(t));if(!g){p.push(`HttpAuthScheme \`${d.schemeId}\` did not have an IdentityProvider configured.`);continue}let{identityProperties:E={},signingProperties:_={}}=d.propertiesExtractor?.(t,n)||{};d.identityProperties=Object.assign(d.identityProperties||{},E),d.signingProperties=Object.assign(d.signingProperties||{},_),u.selectedHttpAuthScheme={httpAuthOption:d,identity:await g(d.identityProperties),signer:m.signer};break}if(!u.selectedHttpAuthScheme)throw new Error(p.join(`
24
+ `));return r(s)}});var Om,Xr,_M=f(()=>{Dm();Om={step:"serialize",tags:["HTTP_AUTH_SCHEME"],name:"httpAuthSchemeMiddleware",override:!0,relation:"before",toMiddleware:"endpointV2Middleware"},Xr=(t,{httpAuthSchemeParametersProvider:e,identityProviderConfigProvider:r})=>({applyToStack:n=>{n.addRelativeTo(ui(t,{httpAuthSchemeParametersProvider:e,identityProviderConfigProvider:r}),Om)}})});var vm,AA,RM=f(()=>{Dm();vm={step:"serialize",tags:["HTTP_AUTH_SCHEME"],name:"httpAuthSchemeMiddleware",override:!0,relation:"before",toMiddleware:"serializerMiddleware"},AA=(t,{httpAuthSchemeParametersProvider:e,identityProviderConfigProvider:r})=>({applyToStack:n=>{n.addRelativeTo(ui(t,{httpAuthSchemeParametersProvider:e,identityProviderConfigProvider:r}),vm)}})});var TM=f(()=>{Dm();_M();RM()});var lee,dee,$u,IA=f(()=>{G();W();lee=t=>e=>{throw e},dee=(t,e)=>{},$u=t=>(e,r)=>async n=>{if(!J.isInstance(n.request))return e(n);let o=he(r).selectedHttpAuthScheme;if(!o)throw new Error("No HttpAuthScheme was selected: unable to sign request");let{httpAuthOption:{signingProperties:i={}},identity:a,signer:c}=o,u=await e({...n,request:await c.sign(n.request,a,i)}).catch((c.errorHandler||lee)(i));return(c.successHandler||dee)(u.response,i),u}});var Pm,Zr,AM=f(()=>{IA();Pm={step:"finalizeRequest",tags:["HTTP_SIGNING"],name:"httpSigningMiddleware",aliases:["apiKeyMiddleware","tokenMiddleware","awsAuthMiddleware"],override:!0,relation:"after",toMiddleware:"retryMiddleware"},Zr=t=>({applyToStack:e=>{e.addRelativeTo($u(t),Pm)}})});var IM=f(()=>{IA();AM()});var br,xM=f(()=>{br=t=>{if(typeof t=="function")return t;let e=Promise.resolve(t);return()=>e}});function CM(t,e,r,n,s){return async function*(i,a,...c){let u=a,p=i.startingToken??u[r],d=!0,m;for(;d;){if(u[r]=p,s&&(u[s]=u[s]??i.pageSize),i.client instanceof t)m=await pee(e,i.client,a,i.withCommand,...c);else throw new Error(`Invalid client, expected instance of ${t.name}`);yield m;let g=p;p=fee(m,n),d=!!(p&&(!i.stopOnSameToken||p!==g))}return void 0}}var pee,fee,bM=f(()=>{pee=async(t,e,r,n=o=>o,...s)=>{let o=new t(r);return o=n(o)??o,await e.send(o,...s)};fee=(t,e)=>{let r=t,n=e.split(".");for(let s of n){if(!r||typeof r!="object")return;r=r[s]}return r}});function wM(t,e,r){t.__smithy_context?t.__smithy_context.features||(t.__smithy_context.features={}):t.__smithy_context={features:{}},t.__smithy_context.features[e]=r}var DM=f(()=>{});var pr,OM=f(()=>{W();pr=class{authSchemes=new Map;constructor(e){for(let r in e){if(!k(e,r))continue;let n=e[r];n!==void 0&&this.authSchemes.set(r,n)}}getIdentityProvider(e){return this.authSchemes.get(e)}}});var xA,Ga,vM=f(()=>{G();xA=ye(Hr()),Ga=class{async sign(e,r,n){if(!n)throw new Error("request could not be signed with `apiKey` since the `name` and `in` signer properties are missing");if(!n.name)throw new Error("request could not be signed with `apiKey` since the `name` signer property is missing");if(!n.in)throw new Error("request could not be signed with `apiKey` since the `in` signer property is missing");if(!r.apiKey)throw new Error("request could not be signed with `apiKey` since the `apiKey` is not defined");let s=J.clone(e);if(n.in===xA.HttpApiKeyAuthLocation.QUERY)s.query[n.name]=r.apiKey;else if(n.in===xA.HttpApiKeyAuthLocation.HEADER)s.headers[n.name]=n.scheme?`${n.scheme} ${r.apiKey}`:r.apiKey;else throw new Error("request can only be signed with `apiKey` locations `query` or `header`, but found: `"+n.in+"`");return s}}});var Ha,PM=f(()=>{G();Ha=class{async sign(e,r,n){let s=J.clone(e);if(!r.token)throw new Error("request could not be signed with `token` since the `token` is not defined");return s.headers.Authorization=`Bearer ${r.token}`,s}}});var vt,NM=f(()=>{vt=class{async sign(e,r,n){return e}}});var kM=f(()=>{vM();PM();NM()});var Nm,CA,Fu,Va,Uu,MM=f(()=>{Nm=t=>function(r){return Va(r)&&r.expiration.getTime()-Date.now()<t},CA=3e5,Fu=Nm(3e5),Va=t=>t.expiration!==void 0,Uu=(t,e,r)=>{if(t===void 0)return;let n=typeof t!="function"?async()=>Promise.resolve(t):t,s,o,i,a=!1,c=async u=>{o||(o=n(u));try{s=await o,i=!0,a=!1}finally{o=void 0}return s};return e===void 0?async u=>((!i||u?.forceRefresh)&&(s=await c(u)),s):async u=>((!i||u?.forceRefresh)&&(s=await c(u)),a?s:r(s)?(e(s)&&await c(u),s):(a=!0,s))}});var LM=f(()=>{OM();kM();MM()});var Bu={};at(Bu,{DefaultIdentityProviderConfig:()=>pr,EXPIRATION_MS:()=>CA,HttpApiKeyAuthSigner:()=>Ga,HttpBearerAuthSigner:()=>Ha,NoAuthSigner:()=>vt,createIsIdentityExpiredFunction:()=>Nm,createPaginator:()=>CM,doesIdentityRequireRefresh:()=>Va,getHttpAuthSchemeEndpointRuleSetPlugin:()=>Xr,getHttpAuthSchemePlugin:()=>AA,getHttpSigningPlugin:()=>Zr,getSmithyContext:()=>he,httpAuthSchemeEndpointRuleSetMiddlewareOptions:()=>Om,httpAuthSchemeMiddleware:()=>ui,httpAuthSchemeMiddlewareOptions:()=>vm,httpSigningMiddleware:()=>$u,httpSigningMiddlewareOptions:()=>Pm,isIdentityExpired:()=>Fu,memoizeIdentityProvider:()=>Uu,normalizeProvider:()=>br,requestBuilder:()=>qf,setFeature:()=>wM});var At=f(()=>{W();TM();IM();xM();bM();G();DM();LM()});function mee(t){return t===void 0?!0:typeof t=="string"&&t.length<=50}function ts(t){let e=br(t.userAgentAppId??Gu),{customUserAgent:r}=t;return Object.assign(t,{customUserAgent:typeof r=="string"?[[r]]:r,userAgentAppId:async()=>{let n=await e();if(!mee(n)){let s=t.logger?.constructor?.name==="NoOpLogger"||!t.logger?console:t.logger;typeof n!="string"?s?.warn("userAgentAppId must be a string or undefined."):n.length>50&&s?.warn("The provided userAgentAppId exceeds the maximum length of 50 characters.")}return n}})}var Gu,bA=f(()=>{At();Gu=void 0});var wA,$M=f(()=>{wA={partitions:[{id:"aws",outputs:{dnsSuffix:"amazonaws.com",dualStackDnsSuffix:"api.aws",implicitGlobalRegion:"us-east-1",name:"aws",supportsDualStack:!0,supportsFIPS:!0},regionRegex:"^(us|eu|ap|sa|ca|me|af|il|mx)\\-\\w+\\-\\d+$",regions:{"af-south-1":{description:"Africa (Cape Town)"},"ap-east-1":{description:"Asia Pacific (Hong Kong)"},"ap-east-2":{description:"Asia Pacific (Taipei)"},"ap-northeast-1":{description:"Asia Pacific (Tokyo)"},"ap-northeast-2":{description:"Asia Pacific (Seoul)"},"ap-northeast-3":{description:"Asia Pacific (Osaka)"},"ap-south-1":{description:"Asia Pacific (Mumbai)"},"ap-south-2":{description:"Asia Pacific (Hyderabad)"},"ap-southeast-1":{description:"Asia Pacific (Singapore)"},"ap-southeast-2":{description:"Asia Pacific (Sydney)"},"ap-southeast-3":{description:"Asia Pacific (Jakarta)"},"ap-southeast-4":{description:"Asia Pacific (Melbourne)"},"ap-southeast-5":{description:"Asia Pacific (Malaysia)"},"ap-southeast-6":{description:"Asia Pacific (New Zealand)"},"ap-southeast-7":{description:"Asia Pacific (Thailand)"},"aws-global":{description:"aws global region"},"ca-central-1":{description:"Canada (Central)"},"ca-west-1":{description:"Canada West (Calgary)"},"eu-central-1":{description:"Europe (Frankfurt)"},"eu-central-2":{description:"Europe (Zurich)"},"eu-north-1":{description:"Europe (Stockholm)"},"eu-south-1":{description:"Europe (Milan)"},"eu-south-2":{description:"Europe (Spain)"},"eu-west-1":{description:"Europe (Ireland)"},"eu-west-2":{description:"Europe (London)"},"eu-west-3":{description:"Europe (Paris)"},"il-central-1":{description:"Israel (Tel Aviv)"},"me-central-1":{description:"Middle East (UAE)"},"me-south-1":{description:"Middle East (Bahrain)"},"mx-central-1":{description:"Mexico (Central)"},"sa-east-1":{description:"South America (Sao Paulo)"},"us-east-1":{description:"US East (N. Virginia)"},"us-east-2":{description:"US East (Ohio)"},"us-west-1":{description:"US West (N. California)"},"us-west-2":{description:"US West (Oregon)"}}},{id:"aws-cn",outputs:{dnsSuffix:"amazonaws.com.cn",dualStackDnsSuffix:"api.amazonwebservices.com.cn",implicitGlobalRegion:"cn-northwest-1",name:"aws-cn",supportsDualStack:!0,supportsFIPS:!0},regionRegex:"^cn\\-\\w+\\-\\d+$",regions:{"aws-cn-global":{description:"aws-cn global region"},"cn-north-1":{description:"China (Beijing)"},"cn-northwest-1":{description:"China (Ningxia)"}}},{id:"aws-eusc",outputs:{dnsSuffix:"amazonaws.eu",dualStackDnsSuffix:"api.amazonwebservices.eu",implicitGlobalRegion:"eusc-de-east-1",name:"aws-eusc",supportsDualStack:!0,supportsFIPS:!0},regionRegex:"^eusc\\-(de)\\-\\w+\\-\\d+$",regions:{"eusc-de-east-1":{description:"AWS European Sovereign Cloud (Germany)"}}},{id:"aws-iso",outputs:{dnsSuffix:"c2s.ic.gov",dualStackDnsSuffix:"api.aws.ic.gov",implicitGlobalRegion:"us-iso-east-1",name:"aws-iso",supportsDualStack:!0,supportsFIPS:!0},regionRegex:"^us\\-iso\\-\\w+\\-\\d+$",regions:{"aws-iso-global":{description:"aws-iso global region"},"us-iso-east-1":{description:"US ISO East"},"us-iso-west-1":{description:"US ISO WEST"}}},{id:"aws-iso-b",outputs:{dnsSuffix:"sc2s.sgov.gov",dualStackDnsSuffix:"api.aws.scloud",implicitGlobalRegion:"us-isob-east-1",name:"aws-iso-b",supportsDualStack:!0,supportsFIPS:!0},regionRegex:"^us\\-isob\\-\\w+\\-\\d+$",regions:{"aws-iso-b-global":{description:"aws-iso-b global region"},"us-isob-east-1":{description:"US ISOB East (Ohio)"},"us-isob-west-1":{description:"US ISOB West"}}},{id:"aws-iso-e",outputs:{dnsSuffix:"cloud.adc-e.uk",dualStackDnsSuffix:"api.cloud-aws.adc-e.uk",implicitGlobalRegion:"eu-isoe-west-1",name:"aws-iso-e",supportsDualStack:!0,supportsFIPS:!0},regionRegex:"^eu\\-isoe\\-\\w+\\-\\d+$",regions:{"aws-iso-e-global":{description:"aws-iso-e global region"},"eu-isoe-west-1":{description:"EU ISOE West"}}},{id:"aws-iso-f",outputs:{dnsSuffix:"csp.hci.ic.gov",dualStackDnsSuffix:"api.aws.hci.ic.gov",implicitGlobalRegion:"us-isof-south-1",name:"aws-iso-f",supportsDualStack:!0,supportsFIPS:!0},regionRegex:"^us\\-isof\\-\\w+\\-\\d+$",regions:{"aws-iso-f-global":{description:"aws-iso-f global region"},"us-isof-east-1":{description:"US ISOF EAST"},"us-isof-south-1":{description:"US ISOF SOUTH"}}},{id:"aws-us-gov",outputs:{dnsSuffix:"amazonaws.com",dualStackDnsSuffix:"api.aws",implicitGlobalRegion:"us-gov-west-1",name:"aws-us-gov",supportsDualStack:!0,supportsFIPS:!0},regionRegex:"^us\\-gov\\-\\w+\\-\\d+$",regions:{"aws-us-gov-global":{description:"aws-us-gov global region"},"us-gov-east-1":{description:"AWS GovCloud (US-East)"},"us-gov-west-1":{description:"AWS GovCloud (US-West)"}}}],version:"1.1"}});var FM,UM,km,DA,BM,Mm,Lm=f(()=>{$M();FM=wA,UM="",km=t=>{let{partitions:e}=FM;for(let n of e){let{regions:s,outputs:o}=n;for(let[i,a]of Object.entries(s))if(i===t)return{...o,...a}}for(let n of e){let{regionRegex:s,outputs:o}=n;if(new RegExp(s).test(t))return{...o}}let r=e.find(n=>n.id==="aws");if(!r)throw new Error("Provided region was not found in the partition array or regex, and default partition with id 'aws' doesn't exist.");return{...r.outputs}},DA=(t,e="")=>{FM=t,UM=e},BM=()=>{DA(wA,"")},Mm=()=>UM});async function GM(t,e,r){if(r.request?.headers?.["smithy-protocol"]==="rpc-v2-cbor"&&Cr(t,"PROTOCOL_RPC_V2_CBOR","M"),typeof e.retryStrategy=="function"){let o=await e.retryStrategy();if(typeof o.mode=="string")switch(o.mode){case dt.ADAPTIVE:Cr(t,"RETRY_MODE_ADAPTIVE","F");break;case dt.STANDARD:Cr(t,"RETRY_MODE_STANDARD","E");break}}if(typeof e.accountIdEndpointMode=="function"){let o=t.endpointV2;switch(String(o?.url?.hostname).match(hee)&&Cr(t,"ACCOUNT_ID_ENDPOINT","O"),await e.accountIdEndpointMode?.()){case"disabled":Cr(t,"ACCOUNT_ID_MODE_DISABLED","Q");break;case"preferred":Cr(t,"ACCOUNT_ID_MODE_PREFERRED","P");break;case"required":Cr(t,"ACCOUNT_ID_MODE_REQUIRED","R");break}}let s=t.__smithy_context?.selectedHttpAuthScheme?.identity;if(s?.$source){let o=s;o.accountId&&Cr(t,"RESOLVED_ACCOUNT_ID","T");for(let[i,a]of Object.entries(o.$source??{}))Cr(t,i,a)}}var hee,HM=f(()=>{Zt();dA();hee=/\d{12}\.ddb/});var OA,$m,VM,WM,zM=f(()=>{OA="user-agent",$m="x-amz-user-agent",VM=/[^!$%&'*+\-.^_`|~\w]/g,WM=/[^!$%&'*+\-.^_`|~\w#]/g});function jM(t){let e="";for(let r in t){let n=t[r];if(e.length+n.length+1<=1024){e.length?e+=","+n:e+=n;continue}break}return e}var qM=f(()=>{});var PA,Fm,NA,rs,QM=f(()=>{G();Lm();HM();zM();qM();PA=t=>(e,r)=>async n=>{let{request:s}=n;if(!J.isInstance(s))return e(n);let{headers:o}=s,i=r?.userAgent?.map(Fm)||[],a=(await t.defaultUserAgentProvider()).map(Fm);await GM(r,t,n);let c=r;a.push(`m/${jM(Object.assign({},r.__smithy_context?.features,c.__aws_sdk_context?.features))}`);let u=t?.customUserAgent?.map(Fm)||[],p=await t.userAgentAppId();p&&a.push(Fm(["app",`${p}`]));let d=Mm(),m=(d?[d]:[]).concat([...a,...i,...u]).join(" "),g=[...a.filter(E=>E.startsWith("aws-sdk-")),...u].join(" ");return t.runtime!=="browser"?(g&&(o[$m]=o[$m]?`${o[OA]} ${g}`:g),o[OA]=m):o[$m]=m,e({...n,request:s})},Fm=t=>{let e=t[0].split("/").map(i=>i.replace(VM,"-")).join("/"),r=t[1]?.replace(WM,"-"),n=e.indexOf("/"),s=e.substring(0,n),o=e.substring(n+1);return s==="api"&&(o=o.toLowerCase()),[s,o,r].filter(i=>i&&i.length>0).reduce((i,a,c)=>{switch(c){case 0:return a;case 1:return`${i}/${a}`;default:return`${i}#${a}`}},"")},NA={name:"getUserAgentMiddleware",step:"build",priority:"low",tags:["SET_USER_AGENT","USER_AGENT"],override:!0},rs=t=>({applyToStack:e=>{e.add(PA(t),NA)}})});var Um,JM,XM=f(()=>{Um=require("node:process"),JM=()=>{let t=["deno","bun","llrt"];for(let e of t)if(Um.versions[e])return[`md/${e}`,Um.versions[e]];return["md/nodejs",Um.versions.node]}});var Hu,kA=f(()=>{Hu={isCrtAvailable:!1}});var ZM,eL=f(()=>{kA();ZM=()=>Hu.isCrtAvailable?["md/crt-avail"]:null});var Bm,MA,en,tL,rL=f(()=>{Bm=require("node:os"),MA=require("node:process");XM();eL();kA();en=({serviceId:t,clientVersion:e})=>{let r=JM();return async n=>{let s=[["aws-sdk-js",e],["ua","2.1"],[`os/${(0,Bm.platform)()}`,(0,Bm.release)()],["lang/js"],r],o=ZM();o&&s.push(o),t&&s.push([`api/${t}`,e]),MA.env.AWS_EXECUTION_ENV&&s.push([`exec-env/${MA.env.AWS_EXECUTION_ENV}`]);let i=await n?.userAgentAppId?.();return i?[...s,[`app/${i}`]]:[...s]}},tL=en});var LA,$A,gee,ns,nL=f(()=>{bA();LA="AWS_SDK_UA_APP_ID",$A="sdk_ua_app_id",gee="sdk-ua-app-id",ns={environmentVariableSelector:t=>t[LA],configFileSelector:t=>t[$A]??t[gee],default:Gu}});var sL=Ne((Vu,FA)=>{(function(t,e){typeof Vu=="object"&&typeof FA=="object"?FA.exports=e():typeof define=="function"&&define.amd?define([],e):typeof Vu=="object"?Vu.bowser=e():t.bowser=e()})(Vu,(function(){return(function(t){var e={};function r(n){if(e[n])return e[n].exports;var s=e[n]={i:n,l:!1,exports:{}};return t[n].call(s.exports,s,s.exports,r),s.l=!0,s.exports}return r.m=t,r.c=e,r.d=function(n,s,o){r.o(n,s)||Object.defineProperty(n,s,{enumerable:!0,get:o})},r.r=function(n){typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(n,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(n,"__esModule",{value:!0})},r.t=function(n,s){if(1&s&&(n=r(n)),8&s||4&s&&typeof n=="object"&&n&&n.__esModule)return n;var o=Object.create(null);if(r.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:n}),2&s&&typeof n!="string")for(var i in n)r.d(o,i,function(a){return n[a]}.bind(null,i));return o},r.n=function(n){var s=n&&n.__esModule?function(){return n.default}:function(){return n};return r.d(s,"a",s),s},r.o=function(n,s){return Object.prototype.hasOwnProperty.call(n,s)},r.p="",r(r.s=90)})({17:function(t,e,r){"use strict";e.__esModule=!0,e.default=void 0;var n=r(18),s=(function(){function o(){}return o.getFirstMatch=function(i,a){var c=a.match(i);return c&&c.length>0&&c[1]||""},o.getSecondMatch=function(i,a){var c=a.match(i);return c&&c.length>1&&c[2]||""},o.matchAndReturnConst=function(i,a,c){if(i.test(a))return c},o.getWindowsVersionName=function(i){switch(i){case"NT":return"NT";case"XP":return"XP";case"NT 5.0":return"2000";case"NT 5.1":return"XP";case"NT 5.2":return"2003";case"NT 6.0":return"Vista";case"NT 6.1":return"7";case"NT 6.2":return"8";case"NT 6.3":return"8.1";case"NT 10.0":return"10";default:return}},o.getMacOSVersionName=function(i){var a=i.split(".").splice(0,2).map((function(p){return parseInt(p,10)||0}));a.push(0);var c=a[0],u=a[1];if(c===10)switch(u){case 5:return"Leopard";case 6:return"Snow Leopard";case 7:return"Lion";case 8:return"Mountain Lion";case 9:return"Mavericks";case 10:return"Yosemite";case 11:return"El Capitan";case 12:return"Sierra";case 13:return"High Sierra";case 14:return"Mojave";case 15:return"Catalina";default:return}switch(c){case 11:return"Big Sur";case 12:return"Monterey";case 13:return"Ventura";case 14:return"Sonoma";case 15:return"Sequoia";default:return}},o.getAndroidVersionName=function(i){var a=i.split(".").splice(0,2).map((function(c){return parseInt(c,10)||0}));if(a.push(0),!(a[0]===1&&a[1]<5))return a[0]===1&&a[1]<6?"Cupcake":a[0]===1&&a[1]>=6?"Donut":a[0]===2&&a[1]<2?"Eclair":a[0]===2&&a[1]===2?"Froyo":a[0]===2&&a[1]>2?"Gingerbread":a[0]===3?"Honeycomb":a[0]===4&&a[1]<1?"Ice Cream Sandwich":a[0]===4&&a[1]<4?"Jelly Bean":a[0]===4&&a[1]>=4?"KitKat":a[0]===5?"Lollipop":a[0]===6?"Marshmallow":a[0]===7?"Nougat":a[0]===8?"Oreo":a[0]===9?"Pie":void 0},o.getVersionPrecision=function(i){return i.split(".").length},o.compareVersions=function(i,a,c){c===void 0&&(c=!1);var u=o.getVersionPrecision(i),p=o.getVersionPrecision(a),d=Math.max(u,p),m=0,g=o.map([i,a],(function(E){var _=d-o.getVersionPrecision(E),R=E+new Array(_+1).join(".0");return o.map(R.split("."),(function(T){return new Array(20-T.length).join("0")+T})).reverse()}));for(c&&(m=d-Math.min(u,p)),d-=1;d>=m;){if(g[0][d]>g[1][d])return 1;if(g[0][d]===g[1][d]){if(d===m)return 0;d-=1}else if(g[0][d]<g[1][d])return-1}},o.map=function(i,a){var c,u=[];if(Array.prototype.map)return Array.prototype.map.call(i,a);for(c=0;c<i.length;c+=1)u.push(a(i[c]));return u},o.find=function(i,a){var c,u;if(Array.prototype.find)return Array.prototype.find.call(i,a);for(c=0,u=i.length;c<u;c+=1){var p=i[c];if(a(p,c))return p}},o.assign=function(i){for(var a,c,u=i,p=arguments.length,d=new Array(p>1?p-1:0),m=1;m<p;m++)d[m-1]=arguments[m];if(Object.assign)return Object.assign.apply(Object,[i].concat(d));var g=function(){var E=d[a];typeof E=="object"&&E!==null&&Object.keys(E).forEach((function(_){u[_]=E[_]}))};for(a=0,c=d.length;a<c;a+=1)g();return i},o.getBrowserAlias=function(i){return n.BROWSER_ALIASES_MAP[i]},o.getBrowserTypeByAlias=function(i){return n.BROWSER_MAP[i]||""},o})();e.default=s,t.exports=e.default},18:function(t,e,r){"use strict";e.__esModule=!0,e.ENGINE_MAP=e.OS_MAP=e.PLATFORMS_MAP=e.BROWSER_MAP=e.BROWSER_ALIASES_MAP=void 0,e.BROWSER_ALIASES_MAP={AmazonBot:"amazonbot","Amazon Silk":"amazon_silk","Android Browser":"android",BaiduSpider:"baiduspider",Bada:"bada",BingCrawler:"bingcrawler",Brave:"brave",BlackBerry:"blackberry","ChatGPT-User":"chatgpt_user",Chrome:"chrome",ClaudeBot:"claudebot",Chromium:"chromium",Diffbot:"diffbot",DuckDuckBot:"duckduckbot",DuckDuckGo:"duckduckgo",Electron:"electron",Epiphany:"epiphany",FacebookExternalHit:"facebookexternalhit",Firefox:"firefox",Focus:"focus",Generic:"generic","Google Search":"google_search",Googlebot:"googlebot",GPTBot:"gptbot","Internet Explorer":"ie",InternetArchiveCrawler:"internetarchivecrawler","K-Meleon":"k_meleon",LibreWolf:"librewolf",Linespider:"linespider",Maxthon:"maxthon","Meta-ExternalAds":"meta_externalads","Meta-ExternalAgent":"meta_externalagent","Meta-ExternalFetcher":"meta_externalfetcher","Meta-WebIndexer":"meta_webindexer","Microsoft Edge":"edge","MZ Browser":"mz","NAVER Whale Browser":"naver","OAI-SearchBot":"oai_searchbot",Omgilibot:"omgilibot",Opera:"opera","Opera Coast":"opera_coast","Pale Moon":"pale_moon",PerplexityBot:"perplexitybot","Perplexity-User":"perplexity_user",PhantomJS:"phantomjs",PingdomBot:"pingdombot",Puffin:"puffin",QQ:"qq",QQLite:"qqlite",QupZilla:"qupzilla",Roku:"roku",Safari:"safari",Sailfish:"sailfish","Samsung Internet for Android":"samsung_internet",SlackBot:"slackbot",SeaMonkey:"seamonkey",Sleipnir:"sleipnir","Sogou Browser":"sogou",Swing:"swing",Tizen:"tizen","UC Browser":"uc",Vivaldi:"vivaldi","WebOS Browser":"webos",WeChat:"wechat",YahooSlurp:"yahooslurp","Yandex Browser":"yandex",YandexBot:"yandexbot",YouBot:"youbot"},e.BROWSER_MAP={amazonbot:"AmazonBot",amazon_silk:"Amazon Silk",android:"Android Browser",baiduspider:"BaiduSpider",bada:"Bada",bingcrawler:"BingCrawler",blackberry:"BlackBerry",brave:"Brave",chatgpt_user:"ChatGPT-User",chrome:"Chrome",claudebot:"ClaudeBot",chromium:"Chromium",diffbot:"Diffbot",duckduckbot:"DuckDuckBot",duckduckgo:"DuckDuckGo",edge:"Microsoft Edge",electron:"Electron",epiphany:"Epiphany",facebookexternalhit:"FacebookExternalHit",firefox:"Firefox",focus:"Focus",generic:"Generic",google_search:"Google Search",googlebot:"Googlebot",gptbot:"GPTBot",ie:"Internet Explorer",internetarchivecrawler:"InternetArchiveCrawler",k_meleon:"K-Meleon",librewolf:"LibreWolf",linespider:"Linespider",maxthon:"Maxthon",meta_externalads:"Meta-ExternalAds",meta_externalagent:"Meta-ExternalAgent",meta_externalfetcher:"Meta-ExternalFetcher",meta_webindexer:"Meta-WebIndexer",mz:"MZ Browser",naver:"NAVER Whale Browser",oai_searchbot:"OAI-SearchBot",omgilibot:"Omgilibot",opera:"Opera",opera_coast:"Opera Coast",pale_moon:"Pale Moon",perplexitybot:"PerplexityBot",perplexity_user:"Perplexity-User",phantomjs:"PhantomJS",pingdombot:"PingdomBot",puffin:"Puffin",qq:"QQ Browser",qqlite:"QQ Browser Lite",qupzilla:"QupZilla",roku:"Roku",safari:"Safari",sailfish:"Sailfish",samsung_internet:"Samsung Internet for Android",seamonkey:"SeaMonkey",slackbot:"SlackBot",sleipnir:"Sleipnir",sogou:"Sogou Browser",swing:"Swing",tizen:"Tizen",uc:"UC Browser",vivaldi:"Vivaldi",webos:"WebOS Browser",wechat:"WeChat",yahooslurp:"YahooSlurp",yandex:"Yandex Browser",yandexbot:"YandexBot",youbot:"YouBot"},e.PLATFORMS_MAP={bot:"bot",desktop:"desktop",mobile:"mobile",tablet:"tablet",tv:"tv"},e.OS_MAP={Android:"Android",Bada:"Bada",BlackBerry:"BlackBerry",ChromeOS:"Chrome OS",HarmonyOS:"HarmonyOS",iOS:"iOS",Linux:"Linux",MacOS:"macOS",PlayStation4:"PlayStation 4",Roku:"Roku",Tizen:"Tizen",WebOS:"WebOS",Windows:"Windows",WindowsPhone:"Windows Phone"},e.ENGINE_MAP={Blink:"Blink",EdgeHTML:"EdgeHTML",Gecko:"Gecko",Presto:"Presto",Trident:"Trident",WebKit:"WebKit"}},90:function(t,e,r){"use strict";e.__esModule=!0,e.default=void 0;var n,s=(n=r(91))&&n.__esModule?n:{default:n},o=r(18);function i(c,u){for(var p=0;p<u.length;p++){var d=u[p];d.enumerable=d.enumerable||!1,d.configurable=!0,"value"in d&&(d.writable=!0),Object.defineProperty(c,d.key,d)}}var a=(function(){function c(){}var u,p,d;return c.getParser=function(m,g,E){if(g===void 0&&(g=!1),E===void 0&&(E=null),typeof m!="string")throw new Error("UserAgent should be a string");return new s.default(m,g,E)},c.parse=function(m,g){return g===void 0&&(g=null),new s.default(m,g).getResult()},u=c,d=[{key:"BROWSER_MAP",get:function(){return o.BROWSER_MAP}},{key:"ENGINE_MAP",get:function(){return o.ENGINE_MAP}},{key:"OS_MAP",get:function(){return o.OS_MAP}},{key:"PLATFORMS_MAP",get:function(){return o.PLATFORMS_MAP}}],(p=null)&&i(u.prototype,p),d&&i(u,d),c})();e.default=a,t.exports=e.default},91:function(t,e,r){"use strict";e.__esModule=!0,e.default=void 0;var n=c(r(92)),s=c(r(93)),o=c(r(94)),i=c(r(95)),a=c(r(17));function c(p){return p&&p.__esModule?p:{default:p}}var u=(function(){function p(m,g,E){if(g===void 0&&(g=!1),E===void 0&&(E=null),m==null||m==="")throw new Error("UserAgent parameter can't be empty");this._ua=m;var _=!1;typeof g=="boolean"?(_=g,this._hints=E):this._hints=g!=null&&typeof g=="object"?g:null,this.parsedResult={},_!==!0&&this.parse()}var d=p.prototype;return d.getHints=function(){return this._hints},d.hasBrand=function(m){if(!this._hints||!Array.isArray(this._hints.brands))return!1;var g=m.toLowerCase();return this._hints.brands.some((function(E){return E.brand&&E.brand.toLowerCase()===g}))},d.getBrandVersion=function(m){if(this._hints&&Array.isArray(this._hints.brands)){var g=m.toLowerCase(),E=this._hints.brands.find((function(_){return _.brand&&_.brand.toLowerCase()===g}));return E?E.version:void 0}},d.getUA=function(){return this._ua},d.test=function(m){return m.test(this._ua)},d.parseBrowser=function(){var m=this;this.parsedResult.browser={};var g=a.default.find(n.default,(function(E){if(typeof E.test=="function")return E.test(m);if(Array.isArray(E.test))return E.test.some((function(_){return m.test(_)}));throw new Error("Browser's test function is not valid")}));return g&&(this.parsedResult.browser=g.describe(this.getUA(),this)),this.parsedResult.browser},d.getBrowser=function(){return this.parsedResult.browser?this.parsedResult.browser:this.parseBrowser()},d.getBrowserName=function(m){return m?String(this.getBrowser().name).toLowerCase()||"":this.getBrowser().name||""},d.getBrowserVersion=function(){return this.getBrowser().version},d.getOS=function(){return this.parsedResult.os?this.parsedResult.os:this.parseOS()},d.parseOS=function(){var m=this;this.parsedResult.os={};var g=a.default.find(s.default,(function(E){if(typeof E.test=="function")return E.test(m);if(Array.isArray(E.test))return E.test.some((function(_){return m.test(_)}));throw new Error("Browser's test function is not valid")}));return g&&(this.parsedResult.os=g.describe(this.getUA())),this.parsedResult.os},d.getOSName=function(m){var g=this.getOS().name;return m?String(g).toLowerCase()||"":g||""},d.getOSVersion=function(){return this.getOS().version},d.getPlatform=function(){return this.parsedResult.platform?this.parsedResult.platform:this.parsePlatform()},d.getPlatformType=function(m){m===void 0&&(m=!1);var g=this.getPlatform().type;return m?String(g).toLowerCase()||"":g||""},d.parsePlatform=function(){var m=this;this.parsedResult.platform={};var g=a.default.find(o.default,(function(E){if(typeof E.test=="function")return E.test(m);if(Array.isArray(E.test))return E.test.some((function(_){return m.test(_)}));throw new Error("Browser's test function is not valid")}));return g&&(this.parsedResult.platform=g.describe(this.getUA())),this.parsedResult.platform},d.getEngine=function(){return this.parsedResult.engine?this.parsedResult.engine:this.parseEngine()},d.getEngineName=function(m){return m?String(this.getEngine().name).toLowerCase()||"":this.getEngine().name||""},d.parseEngine=function(){var m=this;this.parsedResult.engine={};var g=a.default.find(i.default,(function(E){if(typeof E.test=="function")return E.test(m);if(Array.isArray(E.test))return E.test.some((function(_){return m.test(_)}));throw new Error("Browser's test function is not valid")}));return g&&(this.parsedResult.engine=g.describe(this.getUA())),this.parsedResult.engine},d.parse=function(){return this.parseBrowser(),this.parseOS(),this.parsePlatform(),this.parseEngine(),this},d.getResult=function(){return a.default.assign({},this.parsedResult)},d.satisfies=function(m){var g=this,E={},_=0,R={},T=0;if(Object.keys(m).forEach((function(Me){var Lt=m[Me];typeof Lt=="string"?(R[Me]=Lt,T+=1):typeof Lt=="object"&&(E[Me]=Lt,_+=1)})),_>0){var I=Object.keys(E),P=a.default.find(I,(function(Me){return g.isOS(Me)}));if(P){var v=this.satisfies(E[P]);if(v!==void 0)return v}var Z=a.default.find(I,(function(Me){return g.isPlatform(Me)}));if(Z){var Pe=this.satisfies(E[Z]);if(Pe!==void 0)return Pe}}if(T>0){var be=Object.keys(R),Ie=a.default.find(be,(function(Me){return g.isBrowser(Me,!0)}));if(Ie!==void 0)return this.compareVersion(R[Ie])}},d.isBrowser=function(m,g){g===void 0&&(g=!1);var E=this.getBrowserName().toLowerCase(),_=m.toLowerCase(),R=a.default.getBrowserTypeByAlias(_);return g&&R&&(_=R.toLowerCase()),_===E},d.compareVersion=function(m){var g=[0],E=m,_=!1,R=this.getBrowserVersion();if(typeof R=="string")return m[0]===">"||m[0]==="<"?(E=m.substr(1),m[1]==="="?(_=!0,E=m.substr(2)):g=[],m[0]===">"?g.push(1):g.push(-1)):m[0]==="="?E=m.substr(1):m[0]==="~"&&(_=!0,E=m.substr(1)),g.indexOf(a.default.compareVersions(R,E,_))>-1},d.isOS=function(m){return this.getOSName(!0)===String(m).toLowerCase()},d.isPlatform=function(m){return this.getPlatformType(!0)===String(m).toLowerCase()},d.isEngine=function(m){return this.getEngineName(!0)===String(m).toLowerCase()},d.is=function(m,g){return g===void 0&&(g=!1),this.isBrowser(m,g)||this.isOS(m)||this.isPlatform(m)},d.some=function(m){var g=this;return m===void 0&&(m=[]),m.some((function(E){return g.is(E)}))},p})();e.default=u,t.exports=e.default},92:function(t,e,r){"use strict";e.__esModule=!0,e.default=void 0;var n,s=(n=r(17))&&n.__esModule?n:{default:n},o=/version\/(\d+(\.?_?\d+)+)/i,i=[{test:[/gptbot/i],describe:function(a){var c={name:"GPTBot"},u=s.default.getFirstMatch(/gptbot\/(\d+(\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/chatgpt-user/i],describe:function(a){var c={name:"ChatGPT-User"},u=s.default.getFirstMatch(/chatgpt-user\/(\d+(\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/oai-searchbot/i],describe:function(a){var c={name:"OAI-SearchBot"},u=s.default.getFirstMatch(/oai-searchbot\/(\d+(\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/claudebot/i,/claude-web/i,/claude-user/i,/claude-searchbot/i],describe:function(a){var c={name:"ClaudeBot"},u=s.default.getFirstMatch(/(?:claudebot|claude-web|claude-user|claude-searchbot)\/(\d+(\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/omgilibot/i,/webzio-extended/i],describe:function(a){var c={name:"Omgilibot"},u=s.default.getFirstMatch(/(?:omgilibot|webzio-extended)\/(\d+(\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/diffbot/i],describe:function(a){var c={name:"Diffbot"},u=s.default.getFirstMatch(/diffbot\/(\d+(\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/perplexitybot/i],describe:function(a){var c={name:"PerplexityBot"},u=s.default.getFirstMatch(/perplexitybot\/(\d+(\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/perplexity-user/i],describe:function(a){var c={name:"Perplexity-User"},u=s.default.getFirstMatch(/perplexity-user\/(\d+(\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/youbot/i],describe:function(a){var c={name:"YouBot"},u=s.default.getFirstMatch(/youbot\/(\d+(\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/meta-webindexer/i],describe:function(a){var c={name:"Meta-WebIndexer"},u=s.default.getFirstMatch(/meta-webindexer\/(\d+(\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/meta-externalads/i],describe:function(a){var c={name:"Meta-ExternalAds"},u=s.default.getFirstMatch(/meta-externalads\/(\d+(\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/meta-externalagent/i],describe:function(a){var c={name:"Meta-ExternalAgent"},u=s.default.getFirstMatch(/meta-externalagent\/(\d+(\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/meta-externalfetcher/i],describe:function(a){var c={name:"Meta-ExternalFetcher"},u=s.default.getFirstMatch(/meta-externalfetcher\/(\d+(\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/googlebot/i],describe:function(a){var c={name:"Googlebot"},u=s.default.getFirstMatch(/googlebot\/(\d+(\.\d+))/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/linespider/i],describe:function(a){var c={name:"Linespider"},u=s.default.getFirstMatch(/(?:linespider)(?:-[-\w]+)?[\s/](\d+(\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/amazonbot/i],describe:function(a){var c={name:"AmazonBot"},u=s.default.getFirstMatch(/amazonbot\/(\d+(\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/bingbot/i],describe:function(a){var c={name:"BingCrawler"},u=s.default.getFirstMatch(/bingbot\/(\d+(\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/baiduspider/i],describe:function(a){var c={name:"BaiduSpider"},u=s.default.getFirstMatch(/baiduspider\/(\d+(\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/duckduckbot/i],describe:function(a){var c={name:"DuckDuckBot"},u=s.default.getFirstMatch(/duckduckbot\/(\d+(\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/ia_archiver/i],describe:function(a){var c={name:"InternetArchiveCrawler"},u=s.default.getFirstMatch(/ia_archiver\/(\d+(\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/facebookexternalhit/i,/facebookcatalog/i],describe:function(){return{name:"FacebookExternalHit"}}},{test:[/slackbot/i,/slack-imgProxy/i],describe:function(a){var c={name:"SlackBot"},u=s.default.getFirstMatch(/(?:slackbot|slack-imgproxy)(?:-[-\w]+)?[\s/](\d+(\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/yahoo!?[\s/]*slurp/i],describe:function(){return{name:"YahooSlurp"}}},{test:[/yandexbot/i,/yandexmobilebot/i],describe:function(){return{name:"YandexBot"}}},{test:[/pingdom/i],describe:function(){return{name:"PingdomBot"}}},{test:[/opera/i],describe:function(a){var c={name:"Opera"},u=s.default.getFirstMatch(o,a)||s.default.getFirstMatch(/(?:opera)[\s/](\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/opr\/|opios/i],describe:function(a){var c={name:"Opera"},u=s.default.getFirstMatch(/(?:opr|opios)[\s/](\S+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/SamsungBrowser/i],describe:function(a){var c={name:"Samsung Internet for Android"},u=s.default.getFirstMatch(o,a)||s.default.getFirstMatch(/(?:SamsungBrowser)[\s/](\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/Whale/i],describe:function(a){var c={name:"NAVER Whale Browser"},u=s.default.getFirstMatch(o,a)||s.default.getFirstMatch(/(?:whale)[\s/](\d+(?:\.\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/PaleMoon/i],describe:function(a){var c={name:"Pale Moon"},u=s.default.getFirstMatch(o,a)||s.default.getFirstMatch(/(?:PaleMoon)[\s/](\d+(?:\.\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/MZBrowser/i],describe:function(a){var c={name:"MZ Browser"},u=s.default.getFirstMatch(/(?:MZBrowser)[\s/](\d+(?:\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/focus/i],describe:function(a){var c={name:"Focus"},u=s.default.getFirstMatch(/(?:focus)[\s/](\d+(?:\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/swing/i],describe:function(a){var c={name:"Swing"},u=s.default.getFirstMatch(/(?:swing)[\s/](\d+(?:\.\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/coast/i],describe:function(a){var c={name:"Opera Coast"},u=s.default.getFirstMatch(o,a)||s.default.getFirstMatch(/(?:coast)[\s/](\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/opt\/\d+(?:.?_?\d+)+/i],describe:function(a){var c={name:"Opera Touch"},u=s.default.getFirstMatch(/(?:opt)[\s/](\d+(\.?_?\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/yabrowser/i],describe:function(a){var c={name:"Yandex Browser"},u=s.default.getFirstMatch(/(?:yabrowser)[\s/](\d+(\.?_?\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/ucbrowser/i],describe:function(a){var c={name:"UC Browser"},u=s.default.getFirstMatch(o,a)||s.default.getFirstMatch(/(?:ucbrowser)[\s/](\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/Maxthon|mxios/i],describe:function(a){var c={name:"Maxthon"},u=s.default.getFirstMatch(o,a)||s.default.getFirstMatch(/(?:Maxthon|mxios)[\s/](\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/epiphany/i],describe:function(a){var c={name:"Epiphany"},u=s.default.getFirstMatch(o,a)||s.default.getFirstMatch(/(?:epiphany)[\s/](\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/puffin/i],describe:function(a){var c={name:"Puffin"},u=s.default.getFirstMatch(o,a)||s.default.getFirstMatch(/(?:puffin)[\s/](\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/sleipnir/i],describe:function(a){var c={name:"Sleipnir"},u=s.default.getFirstMatch(o,a)||s.default.getFirstMatch(/(?:sleipnir)[\s/](\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/k-meleon/i],describe:function(a){var c={name:"K-Meleon"},u=s.default.getFirstMatch(o,a)||s.default.getFirstMatch(/(?:k-meleon)[\s/](\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/micromessenger/i],describe:function(a){var c={name:"WeChat"},u=s.default.getFirstMatch(/(?:micromessenger)[\s/](\d+(\.?_?\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/qqbrowser/i],describe:function(a){var c={name:/qqbrowserlite/i.test(a)?"QQ Browser Lite":"QQ Browser"},u=s.default.getFirstMatch(/(?:qqbrowserlite|qqbrowser)[/](\d+(\.?_?\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/msie|trident/i],describe:function(a){var c={name:"Internet Explorer"},u=s.default.getFirstMatch(/(?:msie |rv:)(\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/\sedg\//i],describe:function(a){var c={name:"Microsoft Edge"},u=s.default.getFirstMatch(/\sedg\/(\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/edg([ea]|ios)/i],describe:function(a){var c={name:"Microsoft Edge"},u=s.default.getSecondMatch(/edg([ea]|ios)\/(\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/vivaldi/i],describe:function(a){var c={name:"Vivaldi"},u=s.default.getFirstMatch(/vivaldi\/(\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/seamonkey/i],describe:function(a){var c={name:"SeaMonkey"},u=s.default.getFirstMatch(/seamonkey\/(\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/sailfish/i],describe:function(a){var c={name:"Sailfish"},u=s.default.getFirstMatch(/sailfish\s?browser\/(\d+(\.\d+)?)/i,a);return u&&(c.version=u),c}},{test:[/silk/i],describe:function(a){var c={name:"Amazon Silk"},u=s.default.getFirstMatch(/silk\/(\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/phantom/i],describe:function(a){var c={name:"PhantomJS"},u=s.default.getFirstMatch(/phantomjs\/(\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/slimerjs/i],describe:function(a){var c={name:"SlimerJS"},u=s.default.getFirstMatch(/slimerjs\/(\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/blackberry|\bbb\d+/i,/rim\stablet/i],describe:function(a){var c={name:"BlackBerry"},u=s.default.getFirstMatch(o,a)||s.default.getFirstMatch(/blackberry[\d]+\/(\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/(web|hpw)[o0]s/i],describe:function(a){var c={name:"WebOS Browser"},u=s.default.getFirstMatch(o,a)||s.default.getFirstMatch(/w(?:eb)?[o0]sbrowser\/(\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/bada/i],describe:function(a){var c={name:"Bada"},u=s.default.getFirstMatch(/dolfin\/(\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/tizen/i],describe:function(a){var c={name:"Tizen"},u=s.default.getFirstMatch(/(?:tizen\s?)?browser\/(\d+(\.?_?\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/qupzilla/i],describe:function(a){var c={name:"QupZilla"},u=s.default.getFirstMatch(/(?:qupzilla)[\s/](\d+(\.?_?\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/librewolf/i],describe:function(a){var c={name:"LibreWolf"},u=s.default.getFirstMatch(/(?:librewolf)[\s/](\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/firefox|iceweasel|fxios/i],describe:function(a){var c={name:"Firefox"},u=s.default.getFirstMatch(/(?:firefox|iceweasel|fxios)[\s/](\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/electron/i],describe:function(a){var c={name:"Electron"},u=s.default.getFirstMatch(/(?:electron)\/(\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/sogoumobilebrowser/i,/metasr/i,/se 2\.[x]/i],describe:function(a){var c={name:"Sogou Browser"},u=s.default.getFirstMatch(/(?:sogoumobilebrowser)[\s/](\d+(\.?_?\d+)+)/i,a),p=s.default.getFirstMatch(/(?:chrome|crios|crmo)\/(\d+(\.?_?\d+)+)/i,a),d=s.default.getFirstMatch(/se ([\d.]+)x/i,a),m=u||p||d;return m&&(c.version=m),c}},{test:[/MiuiBrowser/i],describe:function(a){var c={name:"Miui"},u=s.default.getFirstMatch(/(?:MiuiBrowser)[\s/](\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:function(a){return!!a.hasBrand("DuckDuckGo")||a.test(/\sDdg\/[\d.]+$/i)},describe:function(a,c){var u={name:"DuckDuckGo"};if(c){var p=c.getBrandVersion("DuckDuckGo");if(p)return u.version=p,u}var d=s.default.getFirstMatch(/\sDdg\/([\d.]+)$/i,a);return d&&(u.version=d),u}},{test:function(a){return a.hasBrand("Brave")},describe:function(a,c){var u={name:"Brave"};if(c){var p=c.getBrandVersion("Brave");if(p)return u.version=p,u}return u}},{test:[/chromium/i],describe:function(a){var c={name:"Chromium"},u=s.default.getFirstMatch(/(?:chromium)[\s/](\d+(\.?_?\d+)+)/i,a)||s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/chrome|crios|crmo/i],describe:function(a){var c={name:"Chrome"},u=s.default.getFirstMatch(/(?:chrome|crios|crmo)\/(\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/GSA/i],describe:function(a){var c={name:"Google Search"},u=s.default.getFirstMatch(/(?:GSA)\/(\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:function(a){var c=!a.test(/like android/i),u=a.test(/android/i);return c&&u},describe:function(a){var c={name:"Android Browser"},u=s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/playstation 4/i],describe:function(a){var c={name:"PlayStation 4"},u=s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/safari|applewebkit/i],describe:function(a){var c={name:"Safari"},u=s.default.getFirstMatch(o,a);return u&&(c.version=u),c}},{test:[/.*/i],describe:function(a){var c=a.search("\\(")!==-1?/^(.*)\/(.*)[ \t]\((.*)/:/^(.*)\/(.*) /;return{name:s.default.getFirstMatch(c,a),version:s.default.getSecondMatch(c,a)}}}];e.default=i,t.exports=e.default},93:function(t,e,r){"use strict";e.__esModule=!0,e.default=void 0;var n,s=(n=r(17))&&n.__esModule?n:{default:n},o=r(18),i=[{test:[/Roku\/DVP/],describe:function(a){var c=s.default.getFirstMatch(/Roku\/DVP-(\d+\.\d+)/i,a);return{name:o.OS_MAP.Roku,version:c}}},{test:[/windows phone/i],describe:function(a){var c=s.default.getFirstMatch(/windows phone (?:os)?\s?(\d+(\.\d+)*)/i,a);return{name:o.OS_MAP.WindowsPhone,version:c}}},{test:[/windows /i],describe:function(a){var c=s.default.getFirstMatch(/Windows ((NT|XP)( \d\d?.\d)?)/i,a),u=s.default.getWindowsVersionName(c);return{name:o.OS_MAP.Windows,version:c,versionName:u}}},{test:[/Macintosh(.*?) FxiOS(.*?)\//],describe:function(a){var c={name:o.OS_MAP.iOS},u=s.default.getSecondMatch(/(Version\/)(\d[\d.]+)/,a);return u&&(c.version=u),c}},{test:[/macintosh/i],describe:function(a){var c=s.default.getFirstMatch(/mac os x (\d+(\.?_?\d+)+)/i,a).replace(/[_\s]/g,"."),u=s.default.getMacOSVersionName(c),p={name:o.OS_MAP.MacOS,version:c};return u&&(p.versionName=u),p}},{test:[/(ipod|iphone|ipad)/i],describe:function(a){var c=s.default.getFirstMatch(/os (\d+([_\s]\d+)*) like mac os x/i,a).replace(/[_\s]/g,".");return{name:o.OS_MAP.iOS,version:c}}},{test:[/OpenHarmony/i],describe:function(a){var c=s.default.getFirstMatch(/OpenHarmony\s+(\d+(\.\d+)*)/i,a);return{name:o.OS_MAP.HarmonyOS,version:c}}},{test:function(a){var c=!a.test(/like android/i),u=a.test(/android/i);return c&&u},describe:function(a){var c=s.default.getFirstMatch(/android[\s/-](\d+(\.\d+)*)/i,a),u=s.default.getAndroidVersionName(c),p={name:o.OS_MAP.Android,version:c};return u&&(p.versionName=u),p}},{test:[/(web|hpw)[o0]s/i],describe:function(a){var c=s.default.getFirstMatch(/(?:web|hpw)[o0]s\/(\d+(\.\d+)*)/i,a),u={name:o.OS_MAP.WebOS};return c&&c.length&&(u.version=c),u}},{test:[/blackberry|\bbb\d+/i,/rim\stablet/i],describe:function(a){var c=s.default.getFirstMatch(/rim\stablet\sos\s(\d+(\.\d+)*)/i,a)||s.default.getFirstMatch(/blackberry\d+\/(\d+([_\s]\d+)*)/i,a)||s.default.getFirstMatch(/\bbb(\d+)/i,a);return{name:o.OS_MAP.BlackBerry,version:c}}},{test:[/bada/i],describe:function(a){var c=s.default.getFirstMatch(/bada\/(\d+(\.\d+)*)/i,a);return{name:o.OS_MAP.Bada,version:c}}},{test:[/tizen/i],describe:function(a){var c=s.default.getFirstMatch(/tizen[/\s](\d+(\.\d+)*)/i,a);return{name:o.OS_MAP.Tizen,version:c}}},{test:[/linux/i],describe:function(){return{name:o.OS_MAP.Linux}}},{test:[/CrOS/],describe:function(){return{name:o.OS_MAP.ChromeOS}}},{test:[/PlayStation 4/],describe:function(a){var c=s.default.getFirstMatch(/PlayStation 4[/\s](\d+(\.\d+)*)/i,a);return{name:o.OS_MAP.PlayStation4,version:c}}}];e.default=i,t.exports=e.default},94:function(t,e,r){"use strict";e.__esModule=!0,e.default=void 0;var n,s=(n=r(17))&&n.__esModule?n:{default:n},o=r(18),i=[{test:[/googlebot/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"Google"}}},{test:[/linespider/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"Line"}}},{test:[/amazonbot/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"Amazon"}}},{test:[/gptbot/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"OpenAI"}}},{test:[/chatgpt-user/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"OpenAI"}}},{test:[/oai-searchbot/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"OpenAI"}}},{test:[/baiduspider/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"Baidu"}}},{test:[/bingbot/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"Bing"}}},{test:[/duckduckbot/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"DuckDuckGo"}}},{test:[/claudebot/i,/claude-web/i,/claude-user/i,/claude-searchbot/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"Anthropic"}}},{test:[/omgilibot/i,/webzio-extended/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"Webz.io"}}},{test:[/diffbot/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"Diffbot"}}},{test:[/perplexitybot/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"Perplexity AI"}}},{test:[/perplexity-user/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"Perplexity AI"}}},{test:[/youbot/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"You.com"}}},{test:[/ia_archiver/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"Internet Archive"}}},{test:[/meta-webindexer/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"Meta"}}},{test:[/meta-externalads/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"Meta"}}},{test:[/meta-externalagent/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"Meta"}}},{test:[/meta-externalfetcher/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"Meta"}}},{test:[/facebookexternalhit/i,/facebookcatalog/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"Meta"}}},{test:[/slackbot/i,/slack-imgProxy/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"Slack"}}},{test:[/yahoo/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"Yahoo"}}},{test:[/yandexbot/i,/yandexmobilebot/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"Yandex"}}},{test:[/pingdom/i],describe:function(){return{type:o.PLATFORMS_MAP.bot,vendor:"Pingdom"}}},{test:[/huawei/i],describe:function(a){var c=s.default.getFirstMatch(/(can-l01)/i,a)&&"Nova",u={type:o.PLATFORMS_MAP.mobile,vendor:"Huawei"};return c&&(u.model=c),u}},{test:[/nexus\s*(?:7|8|9|10).*/i],describe:function(){return{type:o.PLATFORMS_MAP.tablet,vendor:"Nexus"}}},{test:[/ipad/i],describe:function(){return{type:o.PLATFORMS_MAP.tablet,vendor:"Apple",model:"iPad"}}},{test:[/Macintosh(.*?) FxiOS(.*?)\//],describe:function(){return{type:o.PLATFORMS_MAP.tablet,vendor:"Apple",model:"iPad"}}},{test:[/kftt build/i],describe:function(){return{type:o.PLATFORMS_MAP.tablet,vendor:"Amazon",model:"Kindle Fire HD 7"}}},{test:[/silk/i],describe:function(){return{type:o.PLATFORMS_MAP.tablet,vendor:"Amazon"}}},{test:[/tablet(?! pc)/i],describe:function(){return{type:o.PLATFORMS_MAP.tablet}}},{test:function(a){var c=a.test(/ipod|iphone/i),u=a.test(/like (ipod|iphone)/i);return c&&!u},describe:function(a){var c=s.default.getFirstMatch(/(ipod|iphone)/i,a);return{type:o.PLATFORMS_MAP.mobile,vendor:"Apple",model:c}}},{test:[/nexus\s*[0-6].*/i,/galaxy nexus/i],describe:function(){return{type:o.PLATFORMS_MAP.mobile,vendor:"Nexus"}}},{test:[/Nokia/i],describe:function(a){var c=s.default.getFirstMatch(/Nokia\s+([0-9]+(\.[0-9]+)?)/i,a),u={type:o.PLATFORMS_MAP.mobile,vendor:"Nokia"};return c&&(u.model=c),u}},{test:[/[^-]mobi/i],describe:function(){return{type:o.PLATFORMS_MAP.mobile}}},{test:function(a){return a.getBrowserName(!0)==="blackberry"},describe:function(){return{type:o.PLATFORMS_MAP.mobile,vendor:"BlackBerry"}}},{test:function(a){return a.getBrowserName(!0)==="bada"},describe:function(){return{type:o.PLATFORMS_MAP.mobile}}},{test:function(a){return a.getBrowserName()==="windows phone"},describe:function(){return{type:o.PLATFORMS_MAP.mobile,vendor:"Microsoft"}}},{test:function(a){var c=Number(String(a.getOSVersion()).split(".")[0]);return a.getOSName(!0)==="android"&&c>=3},describe:function(){return{type:o.PLATFORMS_MAP.tablet}}},{test:function(a){return a.getOSName(!0)==="android"},describe:function(){return{type:o.PLATFORMS_MAP.mobile}}},{test:[/smart-?tv|smarttv/i],describe:function(){return{type:o.PLATFORMS_MAP.tv}}},{test:[/netcast/i],describe:function(){return{type:o.PLATFORMS_MAP.tv}}},{test:function(a){return a.getOSName(!0)==="macos"},describe:function(){return{type:o.PLATFORMS_MAP.desktop,vendor:"Apple"}}},{test:function(a){return a.getOSName(!0)==="windows"},describe:function(){return{type:o.PLATFORMS_MAP.desktop}}},{test:function(a){return a.getOSName(!0)==="linux"},describe:function(){return{type:o.PLATFORMS_MAP.desktop}}},{test:function(a){return a.getOSName(!0)==="playstation 4"},describe:function(){return{type:o.PLATFORMS_MAP.tv}}},{test:function(a){return a.getOSName(!0)==="roku"},describe:function(){return{type:o.PLATFORMS_MAP.tv}}}];e.default=i,t.exports=e.default},95:function(t,e,r){"use strict";e.__esModule=!0,e.default=void 0;var n,s=(n=r(17))&&n.__esModule?n:{default:n},o=r(18),i=[{test:function(a){return a.getBrowserName(!0)==="microsoft edge"},describe:function(a){if(/\sedg\//i.test(a))return{name:o.ENGINE_MAP.Blink};var c=s.default.getFirstMatch(/edge\/(\d+(\.?_?\d+)+)/i,a);return{name:o.ENGINE_MAP.EdgeHTML,version:c}}},{test:[/trident/i],describe:function(a){var c={name:o.ENGINE_MAP.Trident},u=s.default.getFirstMatch(/trident\/(\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:function(a){return a.test(/presto/i)},describe:function(a){var c={name:o.ENGINE_MAP.Presto},u=s.default.getFirstMatch(/presto\/(\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:function(a){var c=a.test(/gecko/i),u=a.test(/like gecko/i);return c&&!u},describe:function(a){var c={name:o.ENGINE_MAP.Gecko},u=s.default.getFirstMatch(/gecko\/(\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}},{test:[/(apple)?webkit\/537\.36/i],describe:function(){return{name:o.ENGINE_MAP.Blink}}},{test:[/(apple)?webkit/i],describe:function(a){var c={name:o.ENGINE_MAP.WebKit},u=s.default.getFirstMatch(/webkit\/(\d+(\.?_?\d+)+)/i,a);return u&&(c.version=u),c}}];e.default=i,t.exports=e.default}})}))});var oL,iL=f(()=>{oL=({serviceId:t,clientVersion:e})=>async r=>{let n=await Promise.resolve().then(()=>ye(sL())),s=n.parse??n.default.parse??(()=>""),o=typeof window<"u"&&window?.navigator?.userAgent?s(window.navigator.userAgent):void 0,i=[["aws-sdk-js",e],["ua","2.1"],[`os/${o?.os?.name||"other"}`,o?.os?.version],["lang/js"],["md/browser",`${o?.browser?.name??"unknown"}_${o?.browser?.version??"unknown"}`]];t&&i.push([`api/${t}`,e]);let a=await r?.userAgentAppId?.();return a&&i.push([`app/${a}`]),i}});var aL,cL=f(()=>{aL={os(t){if(/iPhone|iPad|iPod/.test(t))return"iOS";if(/Macintosh|Mac OS X/.test(t))return"macOS";if(/Windows NT/.test(t))return"Windows";if(/Android/.test(t))return"Android";if(/Linux/.test(t))return"Linux"},browser(t){if(/EdgiOS|EdgA|Edg\//.test(t))return"Microsoft Edge";if(/Firefox\//.test(t))return"Firefox";if(/Chrome\//.test(t))return"Chrome";if(/Safari\//.test(t))return"Safari"}}});var UA=f(()=>{Re()});var Wu,BA=f(()=>{Re();UA();Wu=(t,e=!1)=>{if(e){for(let r of t.split("."))if(!Wu(r))return!1;return!0}return!(!Vr(t)||t.length<3||t.length>63||t!==t.toLowerCase()||Is(t))}});var Gm,GA=f(()=>{Gm=t=>{let e=t.split(":");if(e.length<6)return null;let[r,n,s,o,i,...a]=e;if(r!=="arn"||n===""||s===""||a.join(":")==="")return null;let c=a.map(u=>u.split("/")).flat();return{partition:n,service:s,region:o,accountId:i,resourceId:c}}});var tn,uL=f(()=>{Re();BA();GA();Lm();tn={isVirtualHostableS3Bucket:Wu,parseArn:Gm,partition:km};Jt.aws=tn});var lL=f(()=>{Re()});var dL,HA,pL=f(()=>{G();dL=t=>{if(typeof t.endpointProvider!="function")throw new Error("@aws-sdk/util-endpoint - endpointProvider and endpoint missing in config for this client.");let{endpoint:e}=t;return e===void 0&&(t.endpoint=async()=>HA(t.endpointProvider({Region:typeof t.region=="function"?await t.region():t.region,UseDualStack:typeof t.useDualstackEndpoint=="function"?await t.useDualstackEndpoint():t.useDualstackEndpoint,UseFIPS:typeof t.useFipsEndpoint=="function"?await t.useFipsEndpoint():t.useFipsEndpoint,Endpoint:void 0},{logger:t.logger}))),t},HA=t=>Et(t.url)});var fL=f(()=>{Re()});var mL=f(()=>{se();se()});function Hm(t={}){return q({..._t,async default(){return VA.silence||console.warn("@aws-sdk - WARN - default STS region of us-east-1 used. See @aws-sdk/credential-providers README and set a region explicitly."),"us-east-1"}},{...Bt,...t})}var VA,hL=f(()=>{se();VA={silence:!1}});var ss,os,gL=f(()=>{ss=t=>({setRegion(e){t.region=e},region(){return t.region}}),os=t=>({region:t.region()})});var wr={};at(wr,{DEFAULT_UA_APP_ID:()=>Gu,EndpointError:()=>te,NODE_APP_ID_CONFIG_OPTIONS:()=>ns,NODE_REGION_CONFIG_FILE_OPTIONS:()=>Bt,NODE_REGION_CONFIG_OPTIONS:()=>_t,REGION_ENV_NAME:()=>ca,REGION_INI_NAME:()=>ua,UA_APP_ID_ENV_NAME:()=>LA,UA_APP_ID_INI_NAME:()=>$A,awsEndpointFunctions:()=>tn,createDefaultUserAgentProvider:()=>en,createUserAgentStringParsingProvider:()=>oL,crtAvailability:()=>Hu,defaultUserAgent:()=>tL,emitWarningIfUnsupportedVersion:()=>Rn,fallback:()=>aL,getAwsRegionExtensionConfiguration:()=>ss,getHostHeaderPlugin:()=>Xn,getLoggerPlugin:()=>Zn,getLongPollPlugin:()=>_w,getRecursionDetectionPlugin:()=>es,getUserAgentMiddlewareOptions:()=>NA,getUserAgentPlugin:()=>rs,getUserAgentPrefix:()=>Mm,hostHeaderMiddleware:()=>pA,hostHeaderMiddlewareOptions:()=>fA,isIpAddress:()=>Is,isVirtualHostableS3Bucket:()=>Wu,loggerMiddleware:()=>mA,loggerMiddlewareOptions:()=>hA,parseArn:()=>Gm,partition:()=>km,recursionDetectionMiddleware:()=>wm,recursionDetectionMiddlewareOptions:()=>Cm,resolveAwsRegionExtensionConfiguration:()=>os,resolveDefaultAwsRegionalEndpointsConfig:()=>dL,resolveEndpoint:()=>Iu,resolveHostHeaderConfig:()=>Ba,resolveRegionConfig:()=>ur,resolveUserAgentConfig:()=>ts,setCredentialFeature:()=>js,setFeature:()=>Cr,setPartitionInfo:()=>DA,setTokenFeature:()=>lM,state:()=>Jc,stsRegionDefaultResolver:()=>Hm,stsRegionWarning:()=>VA,toEndpointV1:()=>HA,useDefaultPartitionInfo:()=>BM,userAgentMiddleware:()=>PA});var ie=f(()=>{yw();Rw();Tw();dA();dM();pM();fM();gA();SM();TA();bA();QM();rL();nL();cL();iL();uL();lL();pL();UA();BA();GA();Lm();fL();mL();hL();gL()});var Vm,Wm,SL=f(()=>{G();Vm=t=>ct.isInstance(t)?t.headers?.date??t.headers?.Date:void 0,Wm=t=>ct.isInstance(t)?t.headers?.age??t.headers?.Age:void 0});var zu,EL=f(()=>{zu=t=>new Date(Date.now()+t)});var zm,yL=f(()=>{zm=(t,e,r,n)=>{if(n!==void 0)return e;let s=Date.parse(t),o=Date.now();return r!==void 0&&o-r>9e5?e:r!==void 0?s-(r+o)/2:s-o}});var WA=f(()=>{SL();EL();yL()});var _L,ju,See,Wa,pt,zA,jA=f(()=>{G();_L=ye(Hr());WA();ju=(t,e)=>{if(!e)throw new Error(`Property \`${t}\` is not resolved for AWS SDK SigV4Auth`);return e},See=t=>t.context?.[_L.SMITHY_CONTEXT_KEY]?.eventStream?.output===!0,Wa=async t=>{let e=ju("context",t.context),r=ju("config",t.config),n=e.endpointV2?.properties?.authSchemes?.[0],o=await ju("signer",r.signer)(n),i=t?.signingRegion,a=t?.signingRegionSet,c=t?.signingName;return{config:r,signer:o,signingRegion:i,signingRegionSet:a,signingName:c}},pt=class{async sign(e,r,n){if(!J.isInstance(e))throw new Error("The request is not an instance of `HttpRequest` and cannot be signed");let s=await Wa(n),{config:o,signer:i}=s,{signingRegion:a,signingName:c}=s,u=n.context;if(u?.authSchemes?.length??!1){let[g,E]=u.authSchemes;g?.name==="sigv4a"&&E?.name==="sigv4"&&(a=E?.signingRegion??a,c=E?.signingName??c)}let p=await o.disableClockSkewCorrection?.()===!0;n._disableClockSkewCorrection=p;let d=p||See(n);return n._skipClockSkewSampling=d,d||(n._preRequestSystemClockOffset=o.systemClockOffset,n._requestSentAt=Date.now()),await i.sign(e,{signingDate:p?new Date:zu(o.systemClockOffset),signingRegion:a,signingService:c})}errorHandler(e){return r=>{let n=r;if(!e._skipClockSkewSampling&&!e._disableClockSkewCorrection){let s=n.ServerTime??Vm(n.$response);if(s){let o=ju("config",e.config),i=e._preRequestSystemClockOffset,a=e._requestSentAt,c=Wm(n.$response),u=zm(s,o.systemClockOffset,a,c);o.systemClockOffset=u,Math.abs(u)>=24e4&&(u!==i||i!==void 0&&i!==u)&&n.$metadata&&(n.$metadata.clockSkewCorrected=!0)}}throw r}}successHandler(e,r){if(r._skipClockSkewSampling||r._disableClockSkewCorrection)return;let n=Vm(e);if(n){let s=ju("config",r.config),o=r._requestSentAt,i=Wm(e);s.systemClockOffset=zm(n,s.systemClockOffset,o,i)}}},zA=pt});var vs,RL=f(()=>{G();WA();jA();vs=class extends pt{async sign(e,r,n){if(!J.isInstance(e))throw new Error("The request is not an instance of `HttpRequest` and cannot be signed");let{config:s,signer:o,signingRegion:i,signingRegionSet:a,signingName:c}=await Wa(n),p=(await s.sigv4aSigningRegionSet?.()??a??[i]).join(","),d=await s.disableClockSkewCorrection?.()===!0;return n._disableClockSkewCorrection=d,d||(n._preRequestSystemClockOffset=s.systemClockOffset,n._requestSentAt=Date.now()),await o.sign(e,{signingDate:d?new Date:zu(s.systemClockOffset),signingRegion:p,signingService:c})}}});var qA,TL=f(()=>{qA=t=>typeof t=="string"&&t.length>0?t.split(",").map(e=>e.trim()):[]});var jm,KA=f(()=>{jm=t=>`AWS_BEARER_TOKEN_${t.replace(/[\s-]/g,"_").toUpperCase()}`});var AL,IL,rn,xL=f(()=>{TL();KA();AL="AWS_AUTH_SCHEME_PREFERENCE",IL="auth_scheme_preference",rn={environmentVariableSelector:(t,e)=>{if(e?.signingName&&jm(e.signingName)in t)return["httpBearerAuth"];if(AL in t)return qA(t[AL])},configFileSelector:t=>{if(IL in t)return qA(t[IL])},default:[]}});var qu,Ku,CL=f(()=>{At();se();qu=t=>(t.sigv4aSigningRegionSet=br(t.sigv4aSigningRegionSet),t),Ku={environmentVariableSelector(t){if(t.AWS_SIGV4A_SIGNING_REGION_SET)return t.AWS_SIGV4A_SIGNING_REGION_SET.split(",").map(e=>e.trim());throw new cr("AWS_SIGV4A_SIGNING_REGION_SET not set in env.",{tryNextLink:!0})},configFileSelector(t){if(t.sigv4a_signing_region_set)return(t.sigv4a_signing_region_set??"").split(",").map(e=>e.trim());throw new cr("sigv4a_signing_region_set not set in profile.",{tryNextLink:!0})},default:void 0}});var iI=Ne(Q=>{var{hasOwn:ja,fromUtf8:bL,fromHex:Eee,toHex:li,toUint8Array:Yu,isArrayBuffer:yee}=(L(),O(Bn)),{normalizeProvider:wL}=(V(),O(Ts)),{escapeUri:qm,HttpRequest:PL}=(G(),O(qn)),YA=class{format(e){let r=[];for(let o in e){if(!ja(e,o))continue;let i=bL(o);r.push(Uint8Array.from([i.byteLength]),i,this.formatHeaderValue(e[o]))}let n=new Uint8Array(r.reduce((o,i)=>o+i.byteLength,0)),s=0;for(let o of r)n.set(o,s),s+=o.byteLength;return n}formatHeaderValue(e){switch(e.type){case"boolean":return Uint8Array.from([e.value?0:1]);case"byte":return Uint8Array.from([2,e.value]);case"short":let r=new DataView(new ArrayBuffer(3));return r.setUint8(0,3),r.setInt16(1,e.value,!1),new Uint8Array(r.buffer);case"integer":let n=new DataView(new ArrayBuffer(5));return n.setUint8(0,4),n.setInt32(1,e.value,!1),new Uint8Array(n.buffer);case"long":let s=new Uint8Array(9);return s[0]=5,s.set(e.value.bytes,1),s;case"binary":let o=new DataView(new ArrayBuffer(3+e.value.byteLength));o.setUint8(0,6),o.setUint16(1,e.value.byteLength,!1);let i=new Uint8Array(o.buffer);return i.set(e.value,3),i;case"string":let a=bL(e.value),c=new DataView(new ArrayBuffer(3+a.byteLength));c.setUint8(0,7),c.setUint16(1,a.byteLength,!1);let u=new Uint8Array(c.buffer);return u.set(a,3),u;case"timestamp":let p=new Uint8Array(9);return p[0]=8,p.set(QA.fromNumber(e.value.valueOf()).bytes,1),p;case"uuid":if(!_ee.test(e.value))throw new Error(`Invalid UUID received: ${e.value}`);let d=new Uint8Array(17);return d[0]=9,d.set(Eee(e.value.replace(/-/g,"")),1),d}}},DL;(function(t){t[t.boolTrue=0]="boolTrue",t[t.boolFalse=1]="boolFalse",t[t.byte=2]="byte",t[t.short=3]="short",t[t.integer=4]="integer",t[t.long=5]="long",t[t.byteArray=6]="byteArray",t[t.string=7]="string",t[t.timestamp=8]="timestamp",t[t.uuid=9]="uuid"})(DL||(DL={}));var _ee=/^[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}$/,QA=class t{bytes;constructor(e){if(this.bytes=e,e.byteLength!==8)throw new Error("Int64 buffers must be exactly 8 bytes")}static fromNumber(e){if(e>9223372036854776e3||e<-9223372036854776e3)throw new Error(`${e} is too large (or, if negative, too small) to represent as an Int64`);let r=new Uint8Array(8);for(let n=7,s=Math.abs(Math.round(e));n>-1&&s>0;n--,s/=256)r[n]=s;return e<0&&OL(r),new t(r)}valueOf(){let e=this.bytes.slice(0),r=e[0]&128;return r&&OL(e),parseInt(li(e),16)*(r?-1:1)}toString(){return String(this.valueOf())}};function OL(t){for(let e=0;e<8;e++)t[e]^=255;for(let e=7;e>-1&&(t[e]++,t[e]===0);e--);}var NL="X-Amz-Algorithm",kL="X-Amz-Credential",eI="X-Amz-Date",ML="X-Amz-SignedHeaders",LL="X-Amz-Expires",tI="X-Amz-Signature",rI="X-Amz-Security-Token",Ree="X-Amz-Region-Set",nI="authorization",sI=eI.toLowerCase(),$L="date",FL=[nI,sI,$L],UL=tI.toLowerCase(),Xm="x-amz-content-sha256",BL=rI.toLowerCase(),Tee="host",GL={authorization:!0,"cache-control":!0,connection:!0,expect:!0,from:!0,"keep-alive":!0,"max-forwards":!0,pragma:!0,referer:!0,te:!0,trailer:!0,"transfer-encoding":!0,upgrade:!0,"user-agent":!0,"x-amzn-trace-id":!0},HL=/^proxy-/,VL=/^sec-/,Aee=[/^proxy-/i,/^sec-/i],Km="AWS4-HMAC-SHA256",Iee="AWS4-ECDSA-P256-SHA256",WL="AWS4-HMAC-SHA256-PAYLOAD",zL="UNSIGNED-PAYLOAD",jL=50,oI="aws4_request",qL=3600*24*7,KL=({query:t={}})=>{let e=[],r={};for(let n in t){if(!ja(t,n)||n.toLowerCase()===UL)continue;let s=qm(n);e.push(s);let o=t[n];typeof o=="string"?r[s]=`${s}=${qm(o)}`:Array.isArray(o)&&(r[s]=o.slice(0).reduce((i,a)=>i.concat([`${s}=${qm(a)}`]),[]).sort().join("&"))}return e.sort().map(n=>r[n]).filter(n=>n).join("&")},xee=t=>Cee(t).toISOString().replace(/\.\d{3}Z$/,"Z"),Cee=t=>typeof t=="number"?new Date(t*1e3):typeof t=="string"?Number(t)?new Date(Number(t)*1e3):new Date(t):t,Zm=class{service;regionProvider;credentialProvider;sha256;uriEscapePath;applyChecksum;constructor({applyChecksum:e,credentials:r,region:n,service:s,sha256:o,uriEscapePath:i=!0}){this.service=s,this.sha256=o,this.uriEscapePath=i,this.applyChecksum=typeof e=="boolean"?e:!0,this.regionProvider=wL(n),this.credentialProvider=wL(r)}createCanonicalRequest(e,r,n){let s=Object.keys(r).sort();return`${e.method}
25
+ ${this.getCanonicalPath(e)}
26
+ ${KL(e)}
27
+ ${s.map(o=>`${o}:${r[o]}`).join(`
28
+ `)}
29
+
30
+ ${s.join(";")}
31
+ ${n}`}async createStringToSign(e,r,n,s){let o=new this.sha256;o.update(Yu(n));let i=await o.digest();return`${s}
32
+ ${e}
33
+ ${r}
34
+ ${li(i)}`}getCanonicalPath({path:e}){if(this.uriEscapePath){let r=[];for(let o of e.split("/"))o?.length!==0&&o!=="."&&(o===".."?r.pop():r.push(o));let n=`${e?.startsWith("/")?"/":""}${r.join("/")}${r.length>0&&e?.endsWith("/")?"/":""}`;return qm(n).replace(/%2F/g,"/")}return e}validateResolvedCredentials(e){if(typeof e!="object"||typeof e.accessKeyId!="string"||typeof e.secretAccessKey!="string")throw new Error("Resolved credential object is not valid")}formatDate(e){let r=xee(e).replace(/[-:]/g,"");return{longDate:r,shortDate:r.slice(0,8)}}getCanonicalHeaderList(e){return Object.keys(e).sort().join(";")}},za={},Ym=[],Qm=(t,e,r)=>`${t}/${e}/${r}/${oI}`,YL=async(t,e,r,n,s)=>{let o=await vL(t,e.secretAccessKey,e.accessKeyId),i=`${r}:${n}:${s}:${li(o)}:${e.sessionToken}`;if(i in za)return za[i];for(Ym.push(i);Ym.length>jL;)delete za[Ym.shift()];let a=`AWS4${e.secretAccessKey}`;for(let c of[r,n,s,oI])a=await vL(t,a,c);return za[i]=a},bee=()=>{Ym.length=0,Object.keys(za).forEach(t=>{delete za[t]})},vL=(t,e,r)=>{let n=new t(e);return n.update(Yu(r)),n.digest()},JA=({headers:t},e,r)=>{let n={};for(let s of Object.keys(t).sort()){if(t[s]==null)continue;let o=s.toLowerCase();(o in GL||e?.has(o)||HL.test(o)||VL.test(o))&&(!r||r&&!r.has(o))||(n[o]=t[s].replace(/[\r\n]/g," ").replace(/[ \t]+/g," ").replace(/^ | $/g,""))}return n},Jm=async({headers:t,body:e},r)=>{for(let n in t)if(ja(t,n)&&n.toLowerCase()===Xm)return t[n];if(e==null)return"e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855";if(typeof e=="string"||ArrayBuffer.isView(e)||yee(e)){let n=new r;return n.update(Yu(e)),li(await n.digest())}return zL},QL=(t,e)=>{t=t.toLowerCase();for(let r in e)if(ja(e,r)&&t===r.toLowerCase())return!0;return!1},JL=(t,e={})=>{let{headers:r,query:n={}}=PL.clone(t);for(let s in r){if(!ja(r,s))continue;let o=s.toLowerCase();(o.slice(0,6)==="x-amz-"&&!e.unhoistableHeaders?.has(o)||e.hoistableHeaders?.has(o))&&(n[s]=r[s],delete r[s])}return{...t,headers:r,query:n}},XA=t=>{t=PL.clone(t);for(let e in t.headers)ja(t.headers,e)&&FL.indexOf(e.toLowerCase())>-1&&delete t.headers[e];return t},ZA=class extends Zm{headerFormatter=new YA;constructor({applyChecksum:e,credentials:r,region:n,service:s,sha256:o,uriEscapePath:i=!0}){super({applyChecksum:e,credentials:r,region:n,service:s,sha256:o,uriEscapePath:i})}async presign(e,r={}){let{signingDate:n=new Date,expiresIn:s=3600,unsignableHeaders:o,unhoistableHeaders:i,signableHeaders:a,hoistableHeaders:c,signingRegion:u,signingService:p}=r,d=await this.credentialProvider();this.validateResolvedCredentials(d);let m=u??await this.regionProvider(),{longDate:g,shortDate:E}=this.formatDate(n);if(s>qL)return Promise.reject("Signature version 4 presigned URLs must have an expiration date less than one week in the future");let _=Qm(E,m,p??this.service),R=JL(XA(e),{unhoistableHeaders:i,hoistableHeaders:c});d.sessionToken&&(R.query[rI]=d.sessionToken),R.query[NL]=Km,R.query[kL]=`${d.accessKeyId}/${_}`,R.query[eI]=g,R.query[LL]=s.toString(10);let T=JA(R,o,a);return R.query[ML]=this.getCanonicalHeaderList(T),R.query[tI]=await this.getSignature(g,_,this.getSigningKey(d,m,E,p),this.createCanonicalRequest(R,T,await Jm(e,this.sha256))),R}async sign(e,r){return typeof e=="string"?this.signString(e,r):e.headers&&e.payload?this.signEvent(e,r):e.message?this.signMessage(e,r):this.signRequest(e,r)}async signEvent({headers:e,payload:r},{signingDate:n=new Date,priorSignature:s,signingRegion:o,signingService:i,eventStreamCredentials:a}){let c=o??await this.regionProvider(),{shortDate:u,longDate:p}=this.formatDate(n),d=Qm(u,c,i??this.service),m=await Jm({headers:{},body:r},this.sha256),g=new this.sha256;g.update(e);let E=li(await g.digest()),_=[WL,p,d,s,E,m].join(`
35
+ `);return this.signString(_,{signingDate:n,signingRegion:c,signingService:i,eventStreamCredentials:a})}async signMessage(e,{signingDate:r=new Date,signingRegion:n,signingService:s,eventStreamCredentials:o}){return this.signEvent({headers:this.headerFormatter.format(e.message.headers),payload:e.message.body},{signingDate:r,signingRegion:n,signingService:s,priorSignature:e.priorSignature,eventStreamCredentials:o}).then(a=>({message:e.message,signature:a}))}async signString(e,{signingDate:r=new Date,signingRegion:n,signingService:s,eventStreamCredentials:o}={}){let i=o??await this.credentialProvider();this.validateResolvedCredentials(i);let a=n??await this.regionProvider(),{shortDate:c}=this.formatDate(r),u=new this.sha256(await this.getSigningKey(i,a,c,s));return u.update(Yu(e)),li(await u.digest())}async signRequest(e,{signingDate:r=new Date,signableHeaders:n,unsignableHeaders:s,signingRegion:o,signingService:i}={}){let a=await this.credentialProvider();this.validateResolvedCredentials(a);let c=o??await this.regionProvider(),u=XA(e),{longDate:p,shortDate:d}=this.formatDate(r),m=Qm(d,c,i??this.service);u.headers[sI]=p,a.sessionToken&&(u.headers[BL]=a.sessionToken);let g=await Jm(u,this.sha256);!QL(Xm,u.headers)&&this.applyChecksum&&(u.headers[Xm]=g);let E=JA(u,s,n),_=await this.getSignature(p,m,this.getSigningKey(a,c,d,i),this.createCanonicalRequest(u,E,g));return u.headers[nI]=`${Km} Credential=${a.accessKeyId}/${m}, SignedHeaders=${this.getCanonicalHeaderList(E)}, Signature=${_}`,u}async getSignature(e,r,n,s){let o=await this.createStringToSign(e,r,s,Km),i=new this.sha256(await n);return i.update(Yu(o)),li(await i.digest())}getSigningKey(e,r,n,s){return YL(this.sha256,e,n,r,s||this.service)}},wee={SignatureV4a:null};Q.ALGORITHM_IDENTIFIER=Km;Q.ALGORITHM_IDENTIFIER_V4A=Iee;Q.ALGORITHM_QUERY_PARAM=NL;Q.ALWAYS_UNSIGNABLE_HEADERS=GL;Q.AMZ_DATE_HEADER=sI;Q.AMZ_DATE_QUERY_PARAM=eI;Q.AUTH_HEADER=nI;Q.CREDENTIAL_QUERY_PARAM=kL;Q.DATE_HEADER=$L;Q.EVENT_ALGORITHM_IDENTIFIER=WL;Q.EXPIRES_QUERY_PARAM=LL;Q.GENERATED_HEADERS=FL;Q.HOST_HEADER=Tee;Q.KEY_TYPE_IDENTIFIER=oI;Q.MAX_CACHE_SIZE=jL;Q.MAX_PRESIGNED_TTL=qL;Q.PROXY_HEADER_PATTERN=HL;Q.REGION_SET_PARAM=Ree;Q.SEC_HEADER_PATTERN=VL;Q.SHA256_HEADER=Xm;Q.SIGNATURE_HEADER=UL;Q.SIGNATURE_QUERY_PARAM=tI;Q.SIGNED_HEADERS_QUERY_PARAM=ML;Q.SignatureV4=ZA;Q.SignatureV4Base=Zm;Q.TOKEN_HEADER=BL;Q.TOKEN_QUERY_PARAM=rI;Q.UNSIGNABLE_PATTERNS=Aee;Q.UNSIGNED_PAYLOAD=zL;Q.clearCredentialCache=bee;Q.createScope=Qm;Q.getCanonicalHeaders=JA;Q.getCanonicalQuery=KL;Q.getPayloadHash=Jm;Q.getSigningKey=YL;Q.hasHeader=QL;Q.moveHeadersToQuery=JL;Q.prepareRequest=XA;Q.signatureV4aContainer=wee});function Dee(t,{credentials:e,credentialDefaultProvider:r}){let n;return e?e?.memoized?n=e:n=Uu(e,Fu,Va):r?n=br(r(Object.assign({},t,{parentClientConfig:t}))):n=async()=>{throw new Error("@aws-sdk/core::resolveAwsSdkSigV4Config - `credentials` not provided and no credentialDefaultProvider was configured.")},n.memoized=!0,n}function Oee(t,e){if(e.configBound)return e;let r=async n=>e({...n,callerClientConfig:t});return r.memoized=e.memoized,r.configBound=!0,r}var aI,cI,XL=f(()=>{ie();At();aI=ye(iI()),cI=t=>e=>{let r=e.credentials,n=!!e.credentials,s;Object.defineProperty(e,"credentials",{set(p){p&&p!==r&&p!==s&&(n=!0),r=p;let d=Dee(e,{credentials:r,credentialDefaultProvider:e.credentialDefaultProvider}),m=Oee(e,d);if(n&&!m.attributed){let g=typeof r=="object"&&r!==null;s=async E=>{let R=await m(E);return g&&(!R.$source||Object.keys(R.$source).length===0)?js(R,"CREDENTIALS_CODE","e"):R},s.memoized=m.memoized,s.configBound=m.configBound,s.attributed=!0}else s=m},get(){return s},enumerable:!0,configurable:!0}),e.credentials=r;let{signingEscapePath:o=!0,systemClockOffset:i=e.systemClockOffset||0,sha256:a}=e,c;return e.signer?c=br(e.signer):e.regionInfoProvider?c=()=>br(e.region)().then(async p=>[await e.regionInfoProvider(p,{useFipsEndpoint:await e.useFipsEndpoint(),useDualstackEndpoint:await e.useDualstackEndpoint()})||{},p]).then(([p,d])=>{let{signingRegion:m,signingService:g}=p;e.signingRegion=e.signingRegion||m||d,e.signingName=e.signingName||g||e.serviceId;let E={...e,credentials:e.credentials,region:e.signingRegion,service:e.signingName,sha256:a,uriEscapePath:o},_=e.signerConstructor||aI.SignatureV4;return new _(E)}):c=async p=>{p=Object.assign({},{name:"sigv4",signingName:e.signingName||e.defaultSigningName,signingRegion:await br(e.region)(),properties:{}},p);let d=p.signingRegion,m=p.signingName;e.signingRegion=e.signingRegion||d,e.signingName=e.signingName||m||e.serviceId;let g={...e,credentials:e.credentials,region:e.signingRegion,service:e.signingName,sha256:a,uriEscapePath:o},E=e.signerConstructor||aI.SignatureV4;return new E(g)},Object.assign(e,{systemClockOffset:i,signingEscapePath:o,signer:c,disableClockSkewCorrection:br(e.disableClockSkewCorrection??t)})}});var uI=f(()=>{jA();RL();xL();CL();XL()});var vee,Pee,ZL,e$=f(()=>{se();vee="AWS_DISABLE_CLOCK_SKEW_CORRECTION",Pee="disable_clock_skew_correction",ZL={environmentVariableSelector:t=>ut(t,vee,We.ENV),configFileSelector:t=>ut(t,Pee,We.CONFIG),default:!1}});var t$,r$=f(()=>{se();e$();t$=q(ZL)});var Qu={};at(Qu,{AWSSDKSigV4Signer:()=>zA,AwsSdkSigV4ASigner:()=>vs,AwsSdkSigV4Signer:()=>pt,NODE_AUTH_SCHEME_PREFERENCE_OPTIONS:()=>rn,NODE_SIGV4A_CONFIG_OPTIONS:()=>Ku,getBearerTokenEnvKey:()=>jm,resolveAWSSDKSigV4Config:()=>Nee,resolveAwsSdkSigV4AConfig:()=>qu,resolveAwsSdkSigV4Config:()=>is,validateSigningProperties:()=>Wa});var is,Nee,It=f(()=>{uI();KA();uI();r$();is=cI(t$),Nee=is});var lI=Ne(Eo=>{var{setCredentialFeature:kee}=(ie(),O(wr)),{CredentialsProviderError:Mee}=(se(),O(Gt)),n$="AWS_ACCESS_KEY_ID",s$="AWS_SECRET_ACCESS_KEY",o$="AWS_SESSION_TOKEN",i$="AWS_CREDENTIAL_EXPIRATION",a$="AWS_CREDENTIAL_SCOPE",c$="AWS_ACCOUNT_ID",Lee=t=>async()=>{t?.logger?.debug("@aws-sdk/credential-provider-env - fromEnv");let e=process.env[n$],r=process.env[s$],n=process.env[o$],s=process.env[i$],o=process.env[a$],i=process.env[c$];if(e&&r){let a={accessKeyId:e,secretAccessKey:r,...n&&{sessionToken:n},...s&&{expiration:new Date(s)},...o&&{credentialScope:o},...i&&{accountId:i}};return kee(a,"CREDENTIALS_ENV_VARS","g"),a}throw new Mee("Unable to find environment variable credentials.",{logger:t?.logger})};Eo.ENV_ACCOUNT_ID=c$;Eo.ENV_CREDENTIAL_SCOPE=a$;Eo.ENV_EXPIRATION=i$;Eo.ENV_KEY=n$;Eo.ENV_SECRET=s$;Eo.ENV_SESSION=o$;Eo.fromEnv=Lee});var th=Ne(Dr=>{var{ProviderError:dI,CredentialsProviderError:yo,loadConfig:gI}=(se(),O(Gt)),$ee=require("node:http"),{parseUrl:Fee}=(G(),O(qn)),p$=t=>!!t&&typeof t=="object"&&typeof t.AccessKeyId=="string"&&typeof t.SecretAccessKey=="string"&&typeof t.Token=="string"&&typeof t.Expiration=="string",f$=t=>({accessKeyId:t.AccessKeyId,secretAccessKey:t.SecretAccessKey,sessionToken:t.Token,expiration:new Date(t.Expiration),...t.AccountId&&{accountId:t.AccountId}}),m$=1e3,h$=0,SI=({maxRetries:t=h$,timeout:e=m$})=>({maxRetries:t,timeout:e});function Zu(t){return new Promise((e,r)=>{let n=$ee.request({method:"GET",...t,hostname:t.hostname?.replace(/^\[(.+)\]$/,"$1")});n.on("error",s=>{r(Object.assign(new dI("Unable to connect to instance metadata service"),s)),n.destroy()}),n.on("timeout",()=>{r(new dI("TimeoutError from instance metadata service")),n.destroy()}),n.on("response",s=>{let{statusCode:o=400}=s;(o<200||300<=o)&&(r(Object.assign(new dI("Error response received from instance metadata service"),{statusCode:o})),n.destroy());let i=[];s.on("data",a=>{i.push(a)}),s.on("end",()=>{e(Buffer.concat(i)),n.destroy()})}),n.end()})}var fI=(t,e)=>{let r=t();for(let n=0;n<e;n++)r=r.catch(t);return r},Ju="AWS_CONTAINER_CREDENTIALS_FULL_URI",eh="AWS_CONTAINER_CREDENTIALS_RELATIVE_URI",mI="AWS_CONTAINER_AUTHORIZATION_TOKEN",Uee=(t={})=>{let{timeout:e,maxRetries:r}=SI(t);return()=>fI(async()=>{let n=await Wee({logger:t.logger}),s=JSON.parse(await Bee(e,n));if(!p$(s))throw new yo("Invalid response received from instance metadata service.",{logger:t.logger});return f$(s)},r)},Bee=async(t,e)=>(process.env[mI]&&(e.headers={...e.headers,Authorization:process.env[mI]}),(await Zu({...e,timeout:t})).toString()),Gee="169.254.170.2",Hee=new Set(["localhost","127.0.0.1"]),Vee=new Set(["http:","https:"]),Wee=async({logger:t})=>{if(process.env[eh])return{hostname:Gee,path:process.env[eh]};if(process.env[Ju]){let e;try{e=new URL(process.env[Ju])}catch{throw new yo(`${process.env[Ju]} is not a valid container metadata service URL`,{tryNextLink:!1,logger:t})}if(!e.hostname||!Hee.has(e.hostname))throw new yo(`${e.hostname} is not a valid container metadata service hostname`,{tryNextLink:!1,logger:t});if(!e.protocol||!Vee.has(e.protocol))throw new yo(`${e.protocol} is not a valid container metadata service protocol`,{tryNextLink:!1,logger:t});return{protocol:e.protocol,hostname:e.hostname,path:e.pathname+e.search,port:e.port?parseInt(e.port,10):void 0}}throw new yo(`The container metadata credential provider cannot be used unless the ${eh} or ${Ju} environment variable is set`,{tryNextLink:!1,logger:t})},hI=class t extends yo{tryNextLink;name="InstanceMetadataV1FallbackError";constructor(e,r=!0){super(e,r),this.tryNextLink=r,Object.setPrototypeOf(this,t.prototype)}},Xu;(function(t){t.IPv4="http://169.254.169.254",t.IPv6="http://[fd00:ec2::254]"})(Xu||(Xu={}));var zee="AWS_EC2_METADATA_SERVICE_ENDPOINT",jee="ec2_metadata_service_endpoint",qee={environmentVariableSelector:t=>t[zee],configFileSelector:t=>t[jee],default:void 0},qa;(function(t){t.IPv4="IPv4",t.IPv6="IPv6"})(qa||(qa={}));var Kee="AWS_EC2_METADATA_SERVICE_ENDPOINT_MODE",Yee="ec2_metadata_service_endpoint_mode",Qee={environmentVariableSelector:t=>t[Kee],configFileSelector:t=>t[Yee],default:qa.IPv4},g$=async()=>Fee(await Jee()||await Xee()),Jee=async()=>gI(qee)(),Xee=async()=>{let t=await gI(Qee)();switch(t){case qa.IPv4:return Xu.IPv4;case qa.IPv6:return Xu.IPv6;default:throw new Error(`Unsupported endpoint mode: ${t}. Select from ${Object.values(qa)}`)}},Zee=300,ete=300,tte="https://docs.aws.amazon.com/sdkref/latest/guide/feature-static-credentials.html",u$=(t,e)=>{let r=Zee+Math.floor(Math.random()*ete),n=new Date(Date.now()+r*1e3);e.warn(`Attempting credential expiration extension due to a credential service availability issue. A refresh of these credentials will be attempted after ${new Date(n)}.
36
+ For more information, please visit: `+tte);let s=t.originalExpiration??t.expiration;return{...t,...s?{originalExpiration:s}:{},expiration:n}},rte=(t,e={})=>{let r=e?.logger||console,n;return async()=>{let s;try{s=await t(),s.expiration&&s.expiration.getTime()<Date.now()&&(s=u$(s,r))}catch(o){if(n)r.warn("Credential renew failed: ",o),s=u$(n,r);else throw o}return n=s,s}},S$="/latest/meta-data/iam/security-credentials/",nte="/latest/api/token",pI="AWS_EC2_METADATA_V1_DISABLED",l$="ec2_metadata_v1_disabled",d$="x-aws-ec2-metadata-token",ste=(t={})=>rte(ote(t),{logger:t.logger}),ote=(t={})=>{let e=!1,{logger:r,profile:n}=t,{timeout:s,maxRetries:o}=SI(t),i=async(a,c)=>{if(e||c.headers?.[d$]==null){let d=!1,m=!1,g=await gI({environmentVariableSelector:E=>{let _=E[pI];if(m=!!_&&_!=="false",_===void 0)throw new yo(`${pI} not set in env, checking config file next.`,{logger:t.logger});return m},configFileSelector:E=>{let _=E[l$];return d=!!_&&_!=="false",d},default:!1},{profile:n})();if(t.ec2MetadataV1Disabled||g){let E=[];throw t.ec2MetadataV1Disabled&&E.push("credential provider initialization (runtime option ec2MetadataV1Disabled)"),d&&E.push(`config file profile (${l$})`),m&&E.push(`process environment variable (${pI})`),new hI(`AWS EC2 Metadata v1 fallback has been blocked by AWS SDK configuration in the following: [${E.join(", ")}].`)}}let p=(await fI(async()=>{let d;try{d=await ate(c)}catch(m){throw m.statusCode===401&&(e=!1),m}return d},a)).trim();return fI(async()=>{let d;try{d=await cte(p,c,t)}catch(m){throw m.statusCode===401&&(e=!1),m}return d},a)};return async()=>{let a=await g$();if(e)return r?.debug("AWS SDK Instance Metadata","using v1 fallback (no token fetch)"),i(o,{...a,timeout:s});{let c;try{c=(await ite({...a,timeout:s})).toString()}catch(u){if(u?.statusCode===400)throw Object.assign(u,{message:"EC2 Metadata token request returned error"});return(u.message==="TimeoutError"||[403,404,405].includes(u.statusCode))&&(e=!0),r?.debug("AWS SDK Instance Metadata","using v1 fallback (initial)"),i(o,{...a,timeout:s})}return i(o,{...a,headers:{[d$]:c},timeout:s})}}},ite=async t=>Zu({...t,path:nte,method:"PUT",headers:{"x-aws-ec2-metadata-token-ttl-seconds":"21600"}}),ate=async t=>(await Zu({...t,path:S$})).toString(),cte=async(t,e,r)=>{let n=JSON.parse((await Zu({...e,path:S$+t})).toString());if(!p$(n))throw new yo("Invalid response received from instance metadata service.",{logger:r.logger});return f$(n)};Dr.DEFAULT_MAX_RETRIES=h$;Dr.DEFAULT_TIMEOUT=m$;Dr.ENV_CMDS_AUTH_TOKEN=mI;Dr.ENV_CMDS_FULL_URI=Ju;Dr.ENV_CMDS_RELATIVE_URI=eh;Dr.Endpoint=Xu;Dr.fromContainerMetadata=Uee;Dr.fromInstanceMetadata=ste;Dr.getInstanceMetadataEndpoint=g$;Dr.httpRequest=Zu;Dr.providerConfigFromInit=SI});var Ps=Ne(tl=>{var{hasOwn:A$}=(L(),O(Bn)),{streamCollector:ute}=(L(),O(Bn));tl.streamCollector=ute;var{buildQueryString:I$,HttpResponse:x$}=(G(),O(qn)),rh=require("node:https"),{Readable:lte}=require("node:stream"),EI=require("node:http2");function sh(t){let e=t&&typeof t=="object"&&"reason"in t?t.reason:void 0;if(e){if(e instanceof Error){let s=new Error("Request aborted");return s.name="AbortError",s.cause=e,s}let n=new Error(String(e));return n.name="AbortError",n}let r=new Error("Request aborted");return r.name="AbortError",r}var dte=["ECONNRESET","EPIPE","ETIMEDOUT"],C$=t=>{let e={};for(let r in t){if(!A$(t,r))continue;let n=t[r];e[r]=Array.isArray(n)?n.join(","):n}return e},xt={setTimeout:(t,e)=>setTimeout(t,e),clearTimeout:t=>clearTimeout(t)},E$=1e3,pte=(t,e,r=0)=>{if(!r)return-1;let n=s=>{let o=xt.setTimeout(()=>{t.destroy(),e(Object.assign(new Error(`@smithy/node-http-handler - the request socket did not establish a connection with the server within the configured timeout of ${r} ms.`),{name:"TimeoutError"}))},r-s),i=a=>{a?.connecting?a.on("connect",()=>{xt.clearTimeout(o)}):xt.clearTimeout(o)};t.socket?i(t.socket):t.on("socket",i)};return r<2e3?(n(0),0):xt.setTimeout(n.bind(null,E$),E$)},fte=(t,e,r=0,n,s)=>r?xt.setTimeout(()=>{let o=`@smithy/node-http-handler - [${n?"ERROR":"WARN"}] a request has exceeded the configured ${r} ms requestTimeout.`;if(n){let i=Object.assign(new Error(o),{name:"TimeoutError",code:"ETIMEDOUT"});t.destroy(i),e(i)}else o+=" Init client requestHandler with throwOnRequestTimeout=true to turn this into an error.",s?.warn?.(o)},r):-1,mte=3e3,hte=(t,{keepAlive:e,keepAliveMsecs:r},n=mte)=>{if(e!==!0)return-1;let s=()=>{t.socket?t.socket.setKeepAlive(e,r||0):t.on("socket",o=>{o.setKeepAlive(e,r||0)})};return n===0?(s(),0):xt.setTimeout(s,n)},y$=3e3,gte=(t,e,r=0)=>{let n=s=>{let o=r-s,i=()=>{t.destroy(),e(Object.assign(new Error(`@smithy/node-http-handler - the request socket timed out after ${r} ms of inactivity (configured by client requestHandler).`),{name:"TimeoutError"}))};t.socket?(t.socket.setTimeout(o,i),t.on("close",()=>t.socket?.removeListener("timeout",i))):t.setTimeout(o,i)};return 0<r&&r<6e3?(n(0),0):xt.setTimeout(n.bind(null,r===0?0:y$),y$)},_$=6e3;async function b$(t,e,r=_$,n=!1){let s=e.headers,o=s?s.Expect||s.expect:void 0,i=-1,a=!0;!n&&o==="100-continue"&&(a=await Promise.race([new Promise(c=>{i=Number(xt.setTimeout(()=>c(!0),Math.max(_$,r)))}),new Promise(c=>{t.on("continue",()=>{xt.clearTimeout(i),c(!0)}),t.on("response",()=>{xt.clearTimeout(i),c(!1)}),t.on("error",()=>{xt.clearTimeout(i),c(!1)})})])),a&&Ste(t,e.body)}function Ste(t,e){if(e instanceof lte){e.pipe(t);return}if(e){let r=Buffer.isBuffer(e);if(r||typeof e=="string"){r&&e.byteLength===0?t.end():t.end(e);return}let s=e;if(typeof s=="object"&&s.buffer&&typeof s.byteOffset=="number"&&typeof s.byteLength=="number"){t.end(Buffer.from(s.buffer,s.byteOffset,s.byteLength));return}t.end(Buffer.from(e));return}t.end()}var Ete=0,nh,R$,yI=class t{config;configProvider;socketWarningTimestamp=0;externalAgent=!1;metadata={handlerProtocol:"http/1.1"};static create(e){return typeof e?.handle=="function"?e:new t(e)}static checkSocketUsage(e,r,n=console){let{sockets:s,requests:o,maxSockets:i}=e;if(typeof i!="number"||i===1/0||Date.now()-15e3<r)return r;if(s&&o)for(let c in s){if(!A$(s,c))continue;let u=s[c]?.length??0,p=o[c]?.length??0;if(u>=i&&p>=2*i)return n?.warn?.(`@smithy/node-http-handler:WARN - socket usage at capacity=${u} and ${p} additional requests are enqueued.
37
+ See https://docs.aws.amazon.com/sdk-for-javascript/v3/developer-guide/node-configuring-maxsockets.html
38
+ or increase socketAcquisitionWarningTimeout=(millis) in the NodeHttpHandler config.`),Date.now()}return r}constructor(e){this.configProvider=new Promise((r,n)=>{typeof e=="function"?e().then(s=>{r(this.resolveDefaultConfig(s))}).catch(n):r(this.resolveDefaultConfig(e))})}destroy(){this.config?.httpAgent?.destroy(),this.config?.httpsAgent?.destroy()}async handle(e,{abortSignal:r,requestTimeout:n}={}){this.config||(this.config=await this.configProvider);let s=this.config,o=s.logger,i=e.protocol==="https:";return!i&&!this.config.httpAgent&&(this.config.httpAgent=await this.config.httpAgentProvider()),new Promise((a,c)=>{let u,p=-1,d=-1,m=-1,g=-1,E=-1,_=()=>{xt.clearTimeout(p),xt.clearTimeout(d),xt.clearTimeout(m),xt.clearTimeout(g),xt.clearTimeout(E)},R=async j=>{await u,_(),a(j)},T=async j=>{await u,_(),c(j)};if(r?.aborted){let j=sh(r);T(j);return}let I=e.headers,P=I?(I.Expect??I.expect)==="100-continue":!1,v=i?s.httpsAgent:s.httpAgent;P&&!this.externalAgent&&(v=new(i?rh.Agent:nh)({keepAlive:!1,maxSockets:1/0})),p=xt.setTimeout(()=>{this.socketWarningTimestamp=t.checkSocketUsage(v,this.socketWarningTimestamp,o)},s.socketAcquisitionWarningTimeout??(s.requestTimeout??2e3)+(s.connectionTimeout??1e3));let Z=e.query?I$(e.query):"",Pe;if(e.username!=null||e.password!=null){let j=e.username??"",et=e.password??"";Pe=`${j}:${et}`}let be=e.path;Z&&(be+=`?${Z}`),e.fragment&&(be+=`#${e.fragment}`);let Ie=e.hostname??"";Ie[0]==="["&&Ie.endsWith("]")?Ie=e.hostname.slice(1,-1):Ie=e.hostname;let Me={headers:e.headers,host:Ie,method:e.method,path:be,port:e.port,agent:v,auth:Pe},$t=(i?rh.request:R$)(Me,j=>{let et=new x$({statusCode:j.statusCode||-1,reason:j.statusMessage,headers:C$(j.headers),body:j});R({response:et})});if($t.on("error",j=>{dte.includes(j.code)?T(Object.assign(j,{name:"TimeoutError"})):T(j)}),r){let j=()=>{$t.destroy();let et=sh(r);T(et)};if(typeof r.addEventListener=="function"){let et=r;et.addEventListener("abort",j,{once:!0}),$t.once("close",()=>et.removeEventListener("abort",j))}else r.onabort=j}let Kt=n??s.requestTimeout;d=pte($t,T,s.connectionTimeout),m=fte($t,T,Kt,s.throwOnRequestTimeout,o??console),g=gte($t,T,s.socketTimeout);let it=Me.agent;typeof it=="object"&&"keepAlive"in it&&(E=hte($t,{keepAlive:it.keepAlive,keepAliveMsecs:it.keepAliveMsecs})),u=b$($t,e,Kt,this.externalAgent).catch(j=>(_(),c(j)))})}updateHttpClientConfig(e,r){this.config=void 0,this.configProvider=this.configProvider.then(n=>e===Symbol.for("logger")?{...n,logger:n.logger??r}:{...n,[e]:r})}httpHandlerConfigs(){return this.config??{}}resolveDefaultConfig(e){let{requestTimeout:r,connectionTimeout:n,socketTimeout:s,socketAcquisitionWarningTimeout:o,httpAgent:i,httpsAgent:a,throwOnRequestTimeout:c,logger:u}=e||{},p=!0,d=50;return{connectionTimeout:n,requestTimeout:r,socketTimeout:s,socketAcquisitionWarningTimeout:o,throwOnRequestTimeout:c,httpAgentProvider:async()=>{let m=require("node:http"),{Agent:g,request:E}=m.default??m;return R$=E,nh=g,i instanceof nh||typeof i?.destroy=="function"?(this.externalAgent=!0,i):new nh({keepAlive:p,maxSockets:d,...i})},httpsAgent:a instanceof rh.Agent||typeof a?.destroy=="function"?(this.externalAgent=!0,a):new rh.Agent({keepAlive:p,maxSockets:d,...a}),logger:u}}},yte=new Uint16Array(1),el=class{id=yte[0]++;total=0;max=0;session;refs=0;constructor(e){e.unref(),this.session=e}retain(){if(this.session.destroyed)throw new Error("@smithy/node-http-handler - cannot acquire reference to destroyed session.");this.refs+=1,this.total+=1,this.max=Math.max(this.refs,this.max),this.session.ref()}free(){if(!this.session.destroyed&&(this.refs-=1,this.refs===0&&this.session.unref(),this.refs<0))throw new Error("@smithy/node-http-handler - ClientHttp2Session refcount at zero, cannot decrement.")}deref(){return this.session}close(){this.session.closed||this.session.close()}destroy(){this.refs=0,this.session.destroyed||(this.session.setTimeout(0),this.session.destroy())}useCount(){return this.refs}},_I=class{sessions=[];maxConcurrency=0;constructor(e){this.sessions=(e??[]).map(r=>new el(r))}poll(){let e=!1;for(let r of this.sessions){if(r.deref().destroyed){e=!0;continue}if(!this.maxConcurrency||r.useCount()<this.maxConcurrency)return r}if(e)for(let r of this.sessions)r.deref().destroyed&&this.remove(r)}offerLast(e){this.sessions.push(e)}remove(e){let r=this.sessions.indexOf(e);r>-1&&this.sessions.splice(r,1)}[Symbol.iterator](){return this.sessions[Symbol.iterator]()}setMaxConcurrency(e){this.maxConcurrency=e}destroy(e){this.remove(e),e.destroy()}},RI=class{config;connectOptions;connectionPools=new Map;constructor(e){if(this.config=e,this.config.maxConcurrency&&this.config.maxConcurrency<=0)throw new RangeError("maxConcurrency must be greater than zero.")}lease(e,r){let n=this.getUrlString(e),s=this.getPool(n);if(!this.config.disableConcurrency&&!r.isEventStream){let u=s.poll();if(u)return u.retain(),u}let o=new el(this.connect(n)),i=o.deref();this.config.maxConcurrency&&i.settings({maxConcurrentStreams:this.config.maxConcurrency},u=>{if(u)throw new Error("Fail to set maxConcurrentStreams to "+this.config.maxConcurrency+"when creating new session for "+e.destination.toString())});let a=()=>{this.removeFromPoolAndClose(n,o)},c=()=>{this.removeFromPoolAndCheckedDestroy(n,o)};return i.on("goaway",a),i.on("error",c),i.on("frameError",c),i.on("close",c),r.requestTimeout&&i.setTimeout(r.requestTimeout,c),s.offerLast(o),o.retain(),o}release(e,r){r.free()}createIsolatedSession(e,r){let n=this.getUrlString(e),s=new el(this.connect(n)),o=s.deref();o.settings({maxConcurrentStreams:1});let i=()=>{s.destroy()};o.on("error",i),o.on("frameError",i),o.on("close",i);let a=r.requestTimeout??3e5;return o.setTimeout(a,i),s.retain(),s}destroy(){for(let[e,r]of this.connectionPools){for(let n of[...r])n.destroy();this.connectionPools.delete(e)}}setMaxConcurrentStreams(e){if(e&&e<=0)throw new RangeError("maxConcurrentStreams must be greater than zero.");this.config.maxConcurrency=e;for(let r of this.connectionPools.values())r.setMaxConcurrency(e)}setDisableConcurrentStreams(e){this.config.disableConcurrency=e}setNodeHttp2ConnectOptions(e){this.connectOptions=e}debug(){let e={};for(let[r,n]of this.connectionPools){let s=[];for(let o of n)s.push({id:o.id,active:o.useCount(),maxConcurrent:o.max,totalRequests:o.total});e[r]={sessions:s}}return e}removeFromPoolAndClose(e,r){this.connectionPools.get(e)?.remove(r),r.close()}removeFromPoolAndCheckedDestroy(e,r){this.connectionPools.get(e)?.remove(r),r.destroy()}getPool(e){if(!this.connectionPools.has(e)){let r=new _I;this.config.maxConcurrency&&r.setMaxConcurrency(this.config.maxConcurrency),this.connectionPools.set(e,r)}return this.connectionPools.get(e)}getUrlString(e){return e.destination.toString()}connect(e){return this.connectOptions===void 0?EI.connect(e):EI.connect(e,this.connectOptions)}},{constants:T$}=EI,TI=class t{config;configProvider;metadata={handlerProtocol:"h2"};connectionManager=new RI({});static create(e){return typeof e?.handle=="function"?e:new t(e)}constructor(e){this.configProvider=new Promise((r,n)=>{typeof e=="function"?e().then(s=>{r(s||{})}).catch(n):r(e||{})})}destroy(){this.connectionManager.destroy()}async handle(e,{abortSignal:r,requestTimeout:n,isEventStream:s}={}){if(!this.config){this.config=await this.configProvider;let{disableConcurrentStreams:u,maxConcurrentStreams:p,nodeHttp2ConnectOptions:d}=this.config;this.connectionManager.setDisableConcurrentStreams(u??!1),p&&this.connectionManager.setMaxConcurrentStreams(p),d&&this.connectionManager.setNodeHttp2ConnectOptions(d)}let{requestTimeout:o,disableConcurrentStreams:i}=this.config,a=i||s,c=n??o;return new Promise((u,p)=>{let d=!1,m,g=async j=>{await m,u(j)},E=async j=>{await m,p(j)};if(r?.aborted){d=!0;let j=sh(r);E(j);return}let{hostname:_,method:R,port:T,protocol:I,query:P}=e,v="";if(e.username!=null||e.password!=null){let j=e.username??"",et=e.password??"";v=`${j}:${et}@`}let Z=`${I}//${v}${_}${T?`:${T}`:""}`,Pe={destination:new URL(Z)},be={requestTimeout:this.config?.sessionTimeout,isEventStream:s},Ie=a?this.connectionManager.createIsolatedSession(Pe,be):this.connectionManager.lease(Pe,be),Me=Ie.deref(),Lt=j=>{a&&Ie.destroy(),d=!0,E(j)},$t=P?I$(P):"",Kt=e.path;$t&&(Kt+=`?${$t}`),e.fragment&&(Kt+=`#${e.fragment}`);let it=Me.request({...e.headers,[T$.HTTP2_HEADER_PATH]:Kt,[T$.HTTP2_HEADER_METHOD]:R});if(c&&it.setTimeout(c,()=>{it.close();let j=new Error(`Stream timed out because of no activity for ${c} ms`);j.name="TimeoutError",Lt(j)}),r){let j=()=>{it.close();let et=sh(r);Lt(et)};if(typeof r.addEventListener=="function"){let et=r;et.addEventListener("abort",j,{once:!0}),it.once("close",()=>et.removeEventListener("abort",j))}else r.onabort=j}it.on("frameError",(j,et,rX)=>{Lt(new Error(`Frame type id ${j} in stream id ${rX} has failed with code ${et}.`))}),it.on("error",Lt),it.on("aborted",()=>{Lt(new Error(`HTTP/2 stream is abnormally aborted in mid-communication with result code ${it.rstCode}.`))}),it.on("response",j=>{let et=new x$({statusCode:j[":status"]??-1,headers:C$(j),body:it});d=!0,g({response:et}),a&&(Me.close(),it.on("end",()=>{Ie.destroy()}))}),it.on("close",()=>{if(a?Ie.destroy():this.connectionManager.release(Pe,Ie),!d){let j=new Error("Unexpected error: http2 request did not get a response");Me.destroyed&&(j.name="TimeoutError"),Lt(j)}}),m=b$(it,e,c)})}updateHttpClientConfig(e,r){this.config=void 0,this.configProvider=this.configProvider.then(n=>({...n,[e]:r}))}httpHandlerConfigs(){return this.config??{}}};tl.DEFAULT_REQUEST_TIMEOUT=Ete;tl.NodeHttp2Handler=TI;tl.NodeHttpHandler=yI});var AI=Ne(D$=>{var{setCredentialFeature:_te}=(ie(),O(wr)),{CredentialsProviderError:di}=(se(),O(Gt)),{NodeHttpHandler:Rte}=Ps(),Tte=require("node:fs/promises"),{HttpRequest:Ate}=(G(),O(qn)),{sdkStreamMixin:Ite,parseRfc3339DateTime:xte}=(L(),O(Bn)),Cte="169.254.170.2",bte="169.254.170.23",wte="[fd00:ec2::23]",Dte=(t,e)=>{if(t.protocol!=="https:"&&!(t.hostname===Cte||t.hostname===bte||t.hostname===wte)){if(t.hostname.includes("[")){if(t.hostname==="[::1]"||t.hostname==="[0000:0000:0000:0000:0000:0000:0000:0001]")return}else{if(t.hostname==="localhost")return;let r=t.hostname.split("."),n=s=>{let o=parseInt(s,10);return 0<=o&&o<=255};if(r[0]==="127"&&n(r[1])&&n(r[2])&&n(r[3])&&r.length===4)return}throw new di(`URL not accepted. It must either be HTTPS or match one of the following:
39
+ - loopback CIDR 127.0.0.0/8 or [::1/128]
40
+ - ECS container host 169.254.170.2
41
+ - EKS container host 169.254.170.23 or [fd00:ec2::23]`,{logger:e})}};function Ote(t){return new Ate({protocol:t.protocol,hostname:t.hostname,port:Number(t.port),path:t.pathname,query:Array.from(t.searchParams.entries()).reduce((e,[r,n])=>(e[r]=n,e),{}),fragment:t.hash})}async function vte(t,e){let n=await Ite(t.body).transformToString();if(t.statusCode===200){let s=JSON.parse(n);if(typeof s.AccessKeyId!="string"||typeof s.SecretAccessKey!="string"||typeof s.Token!="string"||typeof s.Expiration!="string")throw new di("HTTP credential provider response not of the required format, an object matching: { AccessKeyId: string, SecretAccessKey: string, Token: string, Expiration: string(rfc3339) }",{logger:e});return{accessKeyId:s.AccessKeyId,secretAccessKey:s.SecretAccessKey,sessionToken:s.Token,expiration:xte(s.Expiration)}}if(t.statusCode>=400&&t.statusCode<500){let s={};try{s=JSON.parse(n)}catch{}throw Object.assign(new di(`Server responded with status: ${t.statusCode}`,{logger:e}),{Code:s.Code,Message:s.Message})}throw new di(`Server responded with status: ${t.statusCode}`,{logger:e})}var Pte=(t,e,r)=>async()=>{for(let n=0;n<e;++n)try{return await t()}catch{await new Promise(o=>setTimeout(o,r))}return await t()},Nte="AWS_CONTAINER_CREDENTIALS_RELATIVE_URI",kte="http://169.254.170.2",Mte="AWS_CONTAINER_CREDENTIALS_FULL_URI",Lte="AWS_CONTAINER_AUTHORIZATION_TOKEN_FILE",$te="AWS_CONTAINER_AUTHORIZATION_TOKEN",Fte=(t={})=>{t.logger?.debug("@aws-sdk/credential-provider-http - fromHttp");let e,r=t.awsContainerCredentialsRelativeUri??process.env[Nte],n=t.awsContainerCredentialsFullUri??process.env[Mte],s=t.awsContainerAuthorizationToken??process.env[$te],o=t.awsContainerAuthorizationTokenFile??process.env[Lte],i=t.logger?.constructor?.name==="NoOpLogger"||!t.logger?.warn?console.warn:t.logger.warn.bind(t.logger);if(r&&n&&(i("@aws-sdk/credential-provider-http: you have set both awsContainerCredentialsRelativeUri and awsContainerCredentialsFullUri."),i("awsContainerCredentialsRelativeUri will take precedence.")),s&&o&&(i("@aws-sdk/credential-provider-http: you have set both awsContainerAuthorizationToken and awsContainerAuthorizationTokenFile."),i("awsContainerAuthorizationTokenFile will take precedence.")),r)e=`${kte}${r}`;else if(n)e=n;else throw new di(`No HTTP credential provider host provided.
42
+ Set AWS_CONTAINER_CREDENTIALS_FULL_URI or AWS_CONTAINER_CREDENTIALS_RELATIVE_URI.`,{logger:t.logger});let a=new URL(e);Dte(a,t.logger);let c=Rte.create({connectionTimeout:t.timeout??1e3}),u=t.timeout??1e3,p=Pte(async()=>{let d=Ote(a);o?d.headers.Authorization=w$((await Tte.readFile(o)).toString()):s&&(d.headers.Authorization=w$(s));try{let m=await c.handle(d,{requestTimeout:u});return vte(m.response).then(g=>_te(g,"CREDENTIALS_HTTP","z"))}catch(m){throw new di(String(m),{logger:t.logger})}},t.maxRetries??3,t.timeout??1e3);return async()=>{try{return await p()}finally{c.destroy?.()}}},w$=t=>{if(t.includes(`\r
43
+ `))throw new di("Authorization token contains invalid \\r\\n sequence.");return t};D$.fromHttp=Fte});function Ute(t){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"sso-oauth",region:t.region},propertiesExtractor:(e,r)=>({signingProperties:{config:e,context:r}})}}function Bte(t){return{schemeId:"smithy.api#noAuth"}}var O$,v$,P$,II=f(()=>{It();V();O$=async(t,e,r)=>({operation:he(e).operation,region:await ge(t.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()});v$=t=>{let e=[];return t.operation==="CreateToken"?e.push(Bte(t)):e.push(Ute(t)),e},P$=t=>{let e=is(t);return Object.assign(e,{authSchemePreference:ge(t.authSchemePreference??[])})}});var N$,k$,xI=f(()=>{N$=t=>Object.assign(t,{useDualstackEndpoint:t.useDualstackEndpoint??!1,useFipsEndpoint:t.useFipsEndpoint??!1,defaultSigningName:"sso-oauth"}),k$={UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}}});var _o,rl=f(()=>{_o={name:"@aws-sdk/nested-clients",version:"3.997.48",description:"Nested clients for AWS SDK packages.",homepage:"https://github.com/aws/aws-sdk-js-v3/tree/main/packages/nested-clients",license:"Apache-2.0",author:{name:"AWS SDK for JavaScript Team",url:"https://aws.amazon.com/sdk-for-javascript/"},repository:{type:"git",url:"https://github.com/aws/aws-sdk-js-v3.git",directory:"packages/nested-clients"},files:["./cognito-identity.d.ts","./cognito-identity.js","./signin.d.ts","./signin.js","./sso-oidc.d.ts","./sso-oidc.js","./sso.d.ts","./sso.js","./sts.d.ts","./sts.js","dist-*/**"],sideEffects:!1,main:"./dist-cjs/index.js",module:"./dist-es/index.js",browser:{"./dist-es/submodules/cognito-identity/runtimeConfig":"./dist-es/submodules/cognito-identity/runtimeConfig.browser","./dist-es/submodules/signin/runtimeConfig":"./dist-es/submodules/signin/runtimeConfig.browser","./dist-es/submodules/sso-oidc/runtimeConfig":"./dist-es/submodules/sso-oidc/runtimeConfig.browser","./dist-es/submodules/sso/runtimeConfig":"./dist-es/submodules/sso/runtimeConfig.browser","./dist-es/submodules/sts/runtimeConfig":"./dist-es/submodules/sts/runtimeConfig.browser"},types:"./dist-types/index.d.ts",typesVersions:{"<4.5":{"dist-types/*":["dist-types/ts3.4/*"],"*":["dist-types/ts3.4/submodules/*/index.d.ts"]}},"react-native":{},exports:{"./package.json":"./package.json","./sso-oidc":{types:"./dist-types/submodules/sso-oidc/index.d.ts",module:"./dist-es/submodules/sso-oidc/index.js",node:"./dist-cjs/submodules/sso-oidc/index.js",import:"./dist-es/submodules/sso-oidc/index.js",require:"./dist-cjs/submodules/sso-oidc/index.js"},"./sts":{types:"./dist-types/submodules/sts/index.d.ts",module:"./dist-es/submodules/sts/index.js",node:"./dist-cjs/submodules/sts/index.js",import:"./dist-es/submodules/sts/index.js",require:"./dist-cjs/submodules/sts/index.js"},"./signin":{types:"./dist-types/submodules/signin/index.d.ts",module:"./dist-es/submodules/signin/index.js",node:"./dist-cjs/submodules/signin/index.js",import:"./dist-es/submodules/signin/index.js",require:"./dist-cjs/submodules/signin/index.js"},"./cognito-identity":{types:"./dist-types/submodules/cognito-identity/index.d.ts",module:"./dist-es/submodules/cognito-identity/index.js",node:"./dist-cjs/submodules/cognito-identity/index.js",import:"./dist-es/submodules/cognito-identity/index.js",require:"./dist-cjs/submodules/cognito-identity/index.js"},"./sso":{types:"./dist-types/submodules/sso/index.d.ts",module:"./dist-es/submodules/sso/index.js",node:"./dist-cjs/submodules/sso/index.js",import:"./dist-es/submodules/sso/index.js",require:"./dist-cjs/submodules/sso/index.js"}},scripts:{build:"concurrently 'yarn:build:types' 'yarn:build:es' && yarn build:cjs","build:cjs":"node ../../scripts/compilation/inline","build:es":"premove dist-es && tsc -p tsconfig.es.json","build:include:deps":'yarn g:turbo run build -F="$npm_package_name"',"build:types":"premove dist-types && tsc -p tsconfig.types.json","build:types:downlevel":"downlevel-dts dist-types dist-types/ts3.4",clean:"premove dist-cjs dist-es dist-types",lint:"node ../../scripts/validation/submodules-linter.js",prebuild:"yarn lint",test:"yarn g:vitest run","test:watch":"yarn g:vitest watch"},dependencies:{"@aws-sdk/core":"^3.978.3","@aws-sdk/signature-v4-multi-region":"^3.996.48","@aws-sdk/types":"^3.974.6","@smithy/core":"^3.35.2","@smithy/fetch-http-handler":"^5.8.0","@smithy/node-http-handler":"^4.12.1","@smithy/types":"^4.19.0",tslib:"^2.6.2"},devDependencies:{concurrently:"7.0.0","downlevel-dts":"0.10.1",premove:"4.0.0",typescript:"~7.0.2"},engines:{node:">=20.0.0"}}});var CI,M$=f(()=>{CI=Symbol("@smithy/core/cbor::tagSymbol")});var nl,bI=f(()=>{nl=(t,e)=>{let r=n=>{let s=n;return typeof s=="number"&&(s=s.toString()),s.indexOf(",")>=0&&(s=s.split(",")[0]),s.indexOf(":")>=0&&(s=s.split(":")[0]),s};if(e.__type!==void 0)return r(e.__type)}});function lh(t){let e=t.getSchema(),r=e[L$];if(r)return r;let n=[],s=[];for(let[a,c]of t.structIterator())n.push(a),s.push(c);let o=new Array(n.length);for(let a=0;a<n.length;++a)o[a]=Hte(n[a]);let i={memberNames:n,memberSchemas:s,encodedKeys:o};return e[L$]=i,i}function Hte(t){let e;dh?e=Buffer.from(t,"utf-8"):e=new TextEncoder().encode(t);let r=e.length,n;r<24?n=1:r<256?n=2:n=3;let s=new Uint8Array(n+r);return n===1?s[0]=96|r:n===2?(s[0]=120,s[1]=r):(s[0]=121,s[1]=r>>8,s[2]=r&255),s.set(e,n),s}function G$(t){return dh?Buffer.allocUnsafe(t):new Uint8Array(t)}function Ja(t,e,r,n){if(e==null){if(e===void 0&&t.isIdempotencyToken()){as(Rt());return}ue(1),Y[z++]=246;return}if(t.isUnitSchema()){ue(1),ft(5,0);return}if(typeof e=="object"){if(t.isBlobSchema()&&e instanceof Uint8Array){oh(e);return}if(t.isTimestampSchema()&&e instanceof Date){vI(e);return}if(t.isStructSchema()){Wte(t,e,n);return}if(Array.isArray(e)&&(t.isListSchema()||t.isDocumentSchema())){U$(t,e,t.isDocumentSchema(),n);return}if(t.isMapSchema()){DI(t,e,!1,n);return}if(e instanceof Date){vI(e);return}if(e instanceof Uint8Array){oh(e);return}if(e instanceof $){W$(e);return}if(e[CI]){let o=e;V$(o.tag,o.value);return}if(t.isDocumentSchema()){Array.isArray(e)?U$(t,e,!0,n):DI(t,e,!0,n);return}if(t.isBigDecimalSchema()){Xa(e);return}DI(t,e,!0,n);return}if(typeof e=="string"){if(t.isBlobSchema()){let o=(n?.base64Decoder??Te)(e);oh(o);return}as(e);return}if(typeof e=="number"){ue(9),Number.isInteger(e)&&e>=-9007199254740992&&e<=9007199254740991?ph(e):FI(e);return}if(typeof e=="boolean"){ue(1),Y[z++]=224|(e?21:20);return}if(typeof e=="bigint"){ch(e);return}as(String(e))}function Wte(t,e,r){if(t.isUnionSchema()){let d=!1;for(let[m,g]of t.structIterator()){let E=e[m];if(E!=null){ue(9),ft(5,1),as(m),Ja(g,E,t,r),d=!0;break}}if(!d){let{$unknown:m}=e;Array.isArray(m)?(ue(9),ft(5,1),as(m[0]),Xa(m[1])):(ue(9),ft(5,0))}return}let n=lh(t),{memberNames:s,memberSchemas:o,encodedKeys:i}=n,a=s.length,c;a<24?c=1:a<256?c=2:c=3,ue(c);let u=z;z+=c;let p=0;for(let d=0;d<a;++d){let m=e[s[d]];if(m==null&&!o[d].isIdempotencyToken())continue;let g=i[d];ue(g.length),Y.set(g,z),z+=g.length,Ja(o[d],m,t,r),++p}if(typeof e.__type=="string")for(let d in e)k(e,d)&&(s.includes(d)||(as(d),Xa(e[d]),++p));c===1?Y[u]=160|p:c===2?(Y[u]=184,Y[u+1]=p):(Y[u]=185,Y[u+1]=p>>8,Y[u+2]=p&255)}function U$(t,e,r,n){let s=!!t.getMergedTraits().sparse,o=t.getValueSchema();if(r||s){let i=[];for(let a=0;a<e.length;++a){let c=e[a];r?c!==void 0&&i.push(c):(c!=null||s)&&i.push(c)}ue(9),ft(4,i.length);for(let a=0;a<i.length;++a)Ja(o,i[a],void 0,n)}else{let i=0;for(let a=0;a<e.length;++a)e[a]!=null&&++i;ue(9),ft(4,i);for(let a=0;a<e.length;++a)e[a]!=null&&Ja(o,e[a],void 0,n)}}function DI(t,e,r,n){let s=!!t.getMergedTraits().sparse,o=t.getValueSchema(),i=[];for(let a in e){if(!k(e,a))continue;let c=e[a];(r?c!==void 0:c!=null||s)&&i.push(a)}ue(9),ft(5,i.length);for(let a=0;a<i.length;++a){let c=i[a];as(c),Ja(o,e[c],void 0,n)}}function Xa(t){if(t==null){ue(1),Y[z++]=246;return}if(typeof t=="string"){as(t);return}if(typeof t=="number"){ue(9),Number.isInteger(t)&&t>=-9007199254740992&&t<=9007199254740991?ph(t):FI(t);return}if(typeof t=="boolean"){ue(1),Y[z++]=224|(t?21:20);return}if(typeof t=="bigint"){ch(t);return}if(t instanceof Uint8Array){oh(t);return}if(t instanceof Date){vI(t);return}if(t instanceof $){W$(t);return}if(t[CI]){let e=t;V$(e.tag,e.value);return}if(Array.isArray(t)){ue(9),ft(4,t.length);for(let e=0;e<t.length;++e)Xa(t[e]);return}if(typeof t=="object"){let e=Object.keys(t);ue(9),ft(5,e.length);for(let r=0;r<e.length;++r)as(e[r]),Xa(t[e[r]]);return}as(String(t))}function ue(t){if(z+t>Y.length){let e=Y.length*2;for(;e<z+t;)e*=2;let r=G$(e);r.set(Y.subarray(0,z)),Y=r,fi=new DataView(r.buffer,r.byteOffset,r.byteLength)}}function ft(t,e){if(e<24)Y[z++]=t<<5|e;else if(e<256)Y[z++]=t<<5|24,Y[z++]=e;else if(e<65536)Y[z++]=t<<5|25,Y[z++]=e>>8,Y[z++]=e&255;else if(e<4294967296)Y[z++]=t<<5|26,fi.setUint32(z,e),z+=4;else{Y[z++]=t<<5|27;let r=e/4294967296|0,n=e-r*4294967296|0;fi.setUint32(z,r),fi.setUint32(z+4,n),z+=8}}function H$(t,e){let r=Number(e);if(r<4294967296){ft(t,r);return}Y[z++]=t<<5|27,fi.setBigUint64(z,e),z+=8}function as(t){let e=t.length;if(e<=23){let r=Ka.get(t);if(r){ue(r.bytes.length),Y.set(r.bytes,z),z+=r.bytes.length,r.epoch=wI;return}let n=z;B$(t,e);let s=z,o=Uint8Array.prototype.slice.call(Y,n,s);if(Ka.size>=$$){if(F$)return;let i=0;for(let[a,c]of Ka){if(i>=1024)break;c.epoch!==wI&&(Ka.delete(a),++i)}if(i===0){F$=!0;return}}Ka.size<$$&&Ka.set(t,{epoch:wI,bytes:o});return}B$(t,e)}function B$(t,e){if(dh){let r=e*3;ue(r+9);let n=Buffer.byteLength(t);ft(3,n),z+=Y.write(t,z)}else{let r=e*3;ue(r+9);let n=z,o=Vte.encodeInto(t,Y.subarray(n+9)).written,i;o<24?i=1:o<256?i=2:o<65536?i=3:o<4294967296?i=5:i=9,i<9&&Y.copyWithin(n+i,n+9,n+9+o),z=n,ft(3,o),z+=o}}function FI(t){ue(9),Y[z++]=251,fi.setFloat64(z,t),z+=8}function ph(t){ue(9);let e=t>=0,r=e?0:1,n=e?t:-t-1;ft(r,n)}function ch(t){let e=t>=0,r=e?0:1,n=e?t:-t-BigInt(1);if(n<BigInt("18446744073709551616"))ue(9),H$(r,n);else{let s=n.toString(2),o=Math.ceil(s.length/8),i=new Uint8Array(o),a=n;for(let c=o-1;c>=0;--c)i[c]=Number(a&BigInt(255)),a>>=BigInt(8);ue(o+16),Y[z++]=e?194:195,ft(2,o),Y.set(i,z),z+=o}}function oh(t){ue(t.length+9),ft(2,t.length),Y.set(t,z),z+=t.length}function V$(t,e){ue(9),typeof t=="bigint"?H$(6,t):ft(6,t),Xa(e)}function W$(t){let e=t.string,r=BigInt(0),n=e.search(/[eE]/);n!==-1&&(r=BigInt(e.slice(n+1)),e=e.slice(0,n));let s=e.indexOf("."),o=s===-1?0:e.length-s-1,i=r-BigInt(o),a=BigInt(e.replace(".",""));ue(9),Y[z++]=196,ft(4,2),ue(9),i>=-0x20000000000000n&&i<=0x1fffffffffffffn?ph(Number(i)):ch(i),ch(a)}function vI(t){ue(18),ft(6,1);let e=t.getTime()/1e3;Number.isInteger(e)?ph(e):FI(e)}var ah,L$,dh,Vte,OI,Y,fi,z,$$,Ka,wI,F$,UI=f(()=>{W();G();K();L();M$();ah=class extends lt{write(e,r){z=0;let n=x.of(e);Ja(n,r,void 0,this.serdeContext)}flush(){let e=Y.subarray(0,z);return z=0,Y=G$(OI),fi=new DataView(Y.buffer,Y.byteOffset,Y.byteLength),e}},L$=Symbol.for("@smithy/cbor-struct-cache");dh=typeof Buffer<"u",Vte=new TextEncoder,OI=2048,Y=dh?Buffer.allocUnsafe(OI):new Uint8Array(OI),fi=new DataView(Y.buffer,Y.byteOffset,Y.byteLength),z=0,$$=2048,Ka=new Map,wI=0,F$=!1});function fr(t){if(M>=mt)throw new Error("unexpected end of CBOR payload.");let e=($e[M]&224)>>5;if(($e[M]&31)===31&&e>=2&&e<=5)return Yte(t,e);switch(e){case 0:return ere();case 1:return tre();case 2:return Sh();case 3:return Za();case 4:return zte(t);case 5:return jte(t);case 6:return Kte(t);case 7:return nre();default:throw new Error(`unexpected CBOR major type ${e}.`)}}function zte(t){let e=gh(),r=t.isListSchema()?t.getValueSchema():t,n=Array(e);for(let s=0;s<e;++s)n[s]=fr(r);return n}function jte(t){let e=gh();if(t.isStructSchema())return qte(t,e,M);let r=t.isMapSchema()?t.getValueSchema():t,n={};for(let s=0;s<e;++s){let o=Za();n[o]=fr(r)}return n}function qte(t,e,r){let n=t.isUnionSchema(),s=lh(t),{memberSchemas:o,encodedKeys:i,memberNames:a}=s,c=i.length,u={},p,d,m=0,g=!1,E=0;for(let _=0;_<e;++_){let R=K$(i,c,E);if(R>=0){E=R+1,E>=c&&(E=0);let T=fr(o[R]);T!=null&&(u[a[R]]=T)}else{let T=Za(),I=fr(x.of(15));T==="__type"&&typeof I=="string"?g=!0:(p=T,d=I,++m)}}if(n){let _=!0;for(let R in u)if(k(u,R)){_=!1;break}_&&m===1&&(u.$unknown=[p,d])}else if(g){M=r;let _=x.of(15);for(let R=0;R<e;++R){let T=Za(),I=fr(_);T in u||(u[T]=I)}}return u}function Kte(t){let e=hh(),r=typeof e=="bigint"?Number(e):e;if(r===1){let o=x.of(15),i=fr(o);return Zs(i)}if(r===2||r===3){let o=Sh(),i=BigInt(0);for(let a=0;a<o.length;++a)i=i<<BigInt(8)|BigInt(o[a]);return r===3?-i-BigInt(1):i}if(r===4){let o=x.of(15),i=fr(o),[a,c]=i,u=c<0?-1:1,p=BigInt(u)*BigInt(c),d=String(p),m=c<0?"-":"",g;if(typeof a=="number"&&Math.abs(a)<=2**28){let _=a,R="0".repeat(Math.abs(_)+1)+d;g=_===0?R:R.slice(0,R.length+_)+"."+R.slice(_),g=g.replace(/^0+/g,""),g===""&&(g="0"),g[0]==="."&&(g="0"+g),g=m+g}else{let _=BigInt(a);if(d.length===1)g=m+d+"e"+String(_);else{let R=_+BigInt(d.length-1);g=m+d[0]+"."+d.slice(1)+"e"+String(R)}}return zp(g)}let n=x.of(15),s=fr(n);return{tag:Y$(e),value:s}}function Yte(t,e){switch(e){case 3:return Qte();case 2:return Jte();case 4:return Xte(t);case 5:return Zte(t);default:throw new Error(`unexpected indefinite length for major ${e}.`)}}function Qte(){M+=1;let t=[],e=0;for(;M<mt;){if($e[M]===255){M+=1;let n=new Uint8Array(e),s=0;for(let o=0;o<t.length;++o)n.set(t[o],s),s+=t[o].length;return q$?Buffer.from(n.buffer,n.byteOffset,n.byteLength).toString("utf-8"):GI.decode(n)}let r=Sh();t.push(r),e+=r.length}throw new Error("expected break marker.")}function Jte(){M+=1;let t=[],e=0;for(;M<mt;){if($e[M]===255){M+=1;let n=new Uint8Array(e),s=0;for(let o=0;o<t.length;++o)n.set(t[o],s),s+=t[o].length;return n}let r=Sh();t.push(r),e+=r.length}throw new Error("expected break marker.")}function Xte(t){M+=1;let e=t.isListSchema()?t.getValueSchema():t,r=[];for(;M<mt;){if($e[M]===255)return M+=1,r;r.push(fr(e))}throw new Error("expected break marker.")}function Zte(t){if(M+=1,t.isStructSchema()){let n=lh(t),{memberSchemas:s,encodedKeys:o,memberNames:i}=n,a=o.length,c=t.isUnionSchema(),u={},p,d,m=0,g=0;for(;M<mt;){if($e[M]===255){if(M+=1,c){let _=!0;for(let R in u)if(k(u,R)){_=!1;break}_&&m===1&&(u.$unknown=[p,d])}return u}let E=K$(o,a,g);if(E>=0){g=E+1,g>=a&&(g=0);let _=fr(s[E]);_!=null&&(u[i[E]]=_)}else{let _=Za(),R=fr(x.of(15));_!=="__type"&&(p=_,d=R,++m)}}throw new Error("expected break marker.")}let e=t.isMapSchema()?t.getValueSchema():t,r={};for(;M<mt;){if($e[M]===255)return M+=1,r;let n=Za();r[n]=fr(e)}throw new Error("expected break marker.")}function K$(t,e,r){let n=t[r];if(M+n.length<=mt&&j$(M,n))return M+=n.length,r;for(let s=0;s<e;++s){if(s===r)continue;let o=t[s];if(M+o.length<=mt&&j$(M,o))return M+=o.length,s}return-1}function j$(t,e){let r=e.length;if($e[t]!==e[0])return!1;for(let n=1;n<r;++n)if($e[t+n]!==e[n])return!1;return!0}function hh(){let t=$e[M]&31;if(t<24)return M+=1,t;switch(t){case 24:return mt-M<2&&Ns(1),M+=2,$e[M-1];case 25:return mt-M<3&&Ns(2),M+=3,Ro.getUint16(M-2);case 26:return mt-M<5&&Ns(4),M+=5,Ro.getUint32(M-4);case 27:{mt-M<9&&Ns(8),M+=9;let e=Ro.getUint32(M-8);return e<2097152?e*4294967296+Ro.getUint32(M-4):Ro.getBigUint64(M-8)}default:throw new Error(`unexpected minor value ${t}.`)}}function gh(){let t=hh();return typeof t=="bigint"?Number(t):t}function ere(){let t=hh();return Y$(t)}function tre(){let t=hh();return typeof t=="bigint"?BigInt(-1)-t:-1-t}function Sh(){let t=gh();mt-M<t&&Ns(t);let e=M;return M+=t,$e.subarray(e,e+t)}function Za(){let t=gh();mt-M<t&&Ns(t);let e=M;return M+=t,t<24?rre(e,t):HI?$e.toString("utf-8",e,e+t):GI.decode($e.subarray(e,e+t))}function rre(t,e){let r=e;for(let i=0;i<e;++i)r=r*31+$e[t+i]|0;let n=r>>>0&VI-1,s=z$[n];if(s!==void 0&&s.length===e){let i=!0;for(let a=0;a<e;++a)if(s.charCodeAt(a)!==$e[t+a]){i=!1;break}if(i)return BI[n]=il,s}let o=HI?$e.toString("utf-8",t,t+e):GI.decode($e.subarray(t,t+e));return BI[n]!==il&&(z$[n]=o,BI[n]=il),o}function nre(){let t=M,e=$e[t]&31;switch(e){case 21:return M=t+1,!0;case 20:return M=t+1,!1;case 22:return M=t+1,null;case 23:return M=t+1,null;case 25:return mt-t<3&&Ns(2),M=t+3,sre($e[t+1],$e[t+2]);case 26:return mt-t<5&&Ns(4),M=t+5,Ro.getFloat32(t+1);case 27:return mt-t<9&&Ns(8),M=t+9,Ro.getFloat64(t+1);default:throw new Error(`unexpected minor value ${e} for major 7.`)}}function sre(t,e){let r=t>>7,n=(t&124)>>2,s=(t&3)<<8|e,o=r===0?1:-1;return n===0?s===0?0:o*(Math.pow(2,-14)*(s/1024)):n===31?s===0?o*(1/0):NaN:o*(Math.pow(2,n-15)*(1+s/1024))}function Y$(t){if(typeof t=="number")return t;let e=Number(t);return Number.MIN_SAFE_INTEGER<=e&&e<=Number.MAX_SAFE_INTEGER?e:t}function Ns(t){throw new Error(`CBOR: length ${t} greater than remaining buffer length.`)}function fh(t,e){if(t.isTimestampSchema()){if(typeof e=="number")return Zs(e);if(typeof e=="object"&&e!==null&&e.tag===1&&"value"in e)return Zs(e.value)}if(t.isBlobSchema()||typeof e>"u"||typeof e=="boolean"||typeof e=="number"||typeof e=="string"||typeof e=="bigint"||typeof e=="symbol"||typeof e!="object"||e===null||"byteLength"in e||e instanceof Date||e instanceof $||t.isDocumentSchema())return e;if(t.isListSchema()){let n=t.getValueSchema(),s=[];for(let o of e)s.push(fh(n,o));return s}let r={};if(t.isMapSchema()){let n=t.getValueSchema();for(let s in e)k(e,s)&&(r[s]=fh(n,e[s]))}else if(t.isStructSchema()){let n=t.isUnionSchema(),s;if(n){s=new Set;for(let o in e)k(e,o)&&o!=="__type"&&s.add(o)}for(let[o,i]of t.structIterator())n&&s.delete(o),e[o]!=null&&(r[o]=fh(i,e[o]));if(n&&s?.size===1){let o=!0;for(let i in r)if(k(r,i)){o=!1;break}if(o){let i=s.values().next().value;r.$unknown=[i,e[i]]}}else if(typeof e.__type=="string")for(let o in e)k(e,o)&&(o in r||(r[o]=e[o]))}return r}var mh,q$,GI,$e,HI,Ro,M,mt,VI,z$,BI,il,Q$=f(()=>{W();G();K();L();UI();mh=class extends lt{read(e,r){return $e=r,HI=q$&&r instanceof Buffer,Ro=new DataView(r.buffer,r.byteOffset,r.byteLength),M=0,mt=r.length,il=il+1&65535,fr(x.of(e))}readValue(e,r){return fh(x.of(e),r)}},q$=typeof Buffer<"u",GI=new TextDecoder,$e=new Uint8Array(0),HI=!1,Ro=new DataView(new ArrayBuffer(0)),M=0,mt=0,VI=2048,z$=new Array(VI),BI=new Uint16Array(VI),il=0});var Eh,J$=f(()=>{G();UI();Q$();Eh=class extends lt{createSerializer(){let e=new ah;return e.setSerdeContext(this.serdeContext),e}createDeserializer(){let e=new mh;return e.setSerdeContext(this.serdeContext),e}}});var al,X$=f(()=>{G();K();W();J$();bI();al=class extends Ir{codec=new Eh;serializer=this.codec.createSerializer();deserializer=this.codec.createDeserializer();constructor({defaultNamespace:e,errorTypeRegistries:r}){super({defaultNamespace:e,errorTypeRegistries:r})}getShapeId(){return"smithy.protocols#rpcv2Cbor"}getPayloadCodec(){return this.codec}async serializeRequest(e,r,n){let s=await super.serializeRequest(e,r,n);Object.assign(s.headers,{"content-type":this.getDefaultContentType(),"smithy-protocol":"rpc-v2-cbor",accept:this.getDefaultContentType()}),Yt(e.input)==="unit"?(delete s.body,delete s.headers["content-type"]):(s.body||(this.serializer.write(15,{}),s.body=this.serializer.flush()),s.body instanceof Uint8Array&&(s.headers["content-length"]=String(s.body.byteLength)));let{service:o,operation:i}=he(n),a=`/service/${o}/operation/${i}`;return s.path.endsWith("/")?s.path+=a.slice(1):s.path+=a,s}async deserializeResponse(e,r,n){return super.deserializeResponse(e,r,n)}async handleError(e,r,n,s,o){let i=nl(n,s)??"Unknown",a=["*"],{defaultNamespace:c}=this.options;a.unshift(c);let[u,p]=i.includes("#")?i.split("#"):[void 0,i];u&&a.unshift(u);let d={$metadata:o,$fault:n.statusCode<500?"client":"server"},m=[this.compositeErrorRegistry];u&&m.push(ce.for(u)),m.push(ce.for(c));let[g,E,_]=this.resolveError(p,a,m);if(_==="native"||_==="synthetic"){s.Message&&(s.message=s.Message);let v=_==="synthetic"?new E({name:p}):new Error(p);throw Object.assign(v,d,s)}let R=x.of(g),T=s.message??s.Message??"Unknown",I=new E({}),P={};for(let[v,Z]of R.structIterator())P[v]=this.deserializer.readValue(Z,s[v]);throw Object.assign(I,d,{$fault:R.getMergedTraits().error,message:T},P)}getDefaultContentType(){return"application/cbor"}}});var Z$=f(()=>{bI();X$()});var Or,ec=f(()=>{V();K();Or=class{queryCompat;errorRegistry;constructor(e=!1){this.queryCompat=e}resolveRestContentType(e,r){let n=r.getMemberSchemas(),s=Object.values(n).find(o=>!!o.getMergedTraits().httpPayload);if(s){let o=s.getMergedTraits().mediaType;return o||(s.isStringSchema()?"text/plain":s.isBlobSchema()?"application/octet-stream":e)}else if(!r.isUnitSchema()&&Object.values(n).find(i=>{let{httpQuery:a,httpQueryParams:c,httpHeader:u,httpLabel:p,httpPrefixHeaders:d}=i.getMergedTraits();return!a&&!c&&!u&&!p&&d===void 0}))return e}async getErrorSchemaOrThrowBaseException(e,r,n,s,o,i){let a=e;e.includes("#")&&([,a]=e.split("#"));let c={$metadata:o,$fault:n.statusCode<500?"client":"server"};if(!this.errorRegistry)throw new Error("@aws-sdk/core/protocols - error handler not initialized.");try{return{errorSchema:i?.(this.errorRegistry,a)??this.errorRegistry.getSchema(e),errorMetadata:c}}catch{s.message=s.message??s.Message??"UnknownError";let p=this.errorRegistry,d=p.getBaseException();if(d){let E=p.getErrorCtor(d)??Error;throw this.decorateServiceException(Object.assign(new E({name:a}),c),s)}let m=s,g=m?.message??m?.Message??m?.Error?.Message??m?.Error?.message;throw this.decorateServiceException(Object.assign(new Error(g),{name:a},c),s)}}compose(e,r,n){let s=n;r.includes("#")&&([s]=r.split("#"));let o=ce.for(s),i=ce.for("smithy.ts.sdk.synthetic."+n);e.copyFrom(o),e.copyFrom(i),this.errorRegistry=e}decorateServiceException(e,r={}){if(this.queryCompat){let n=e.Message??r.Message,s=Qo(e,r);n&&(s.message=n);let o=s.Error??{};o.Type=s.Error?.Type,o.Code=s.Error?.Code,o.Message=s.Error?.message??s.Error?.Message??n,s.Error=o;let i=s.$metadata.requestId;return i&&(s.RequestId=i),s}return Qo(e,r)}setQueryCompatError(e,r){let n=r.headers?.["x-amzn-query-error"];if(e!==void 0&&n!=null){let[s,o]=n.split(";"),i=Object.keys(e),a={Code:s,Type:o};e.Code=s,e.Type=o;for(let c=0;c<i.length;c++){let u=i[c];a[u==="message"?"Message":u]=e[u]}delete a.__type,e.Error=a}}queryCompatOutput(e,r){e.Error&&(r.Error=e.Error),e.Type&&(r.Type=e.Type),e.Code&&(r.Code=e.Code)}findQueryCompatibleError(e,r){try{return e.getSchema(r)}catch{return e.find(s=>x.of(s).getMergedTraits().awsQueryError?.[0]===r)}}}});var yh,eF=f(()=>{Z$();K();ec();yh=class extends al{awsQueryCompatible;mixin;constructor({defaultNamespace:e,errorTypeRegistries:r,awsQueryCompatible:n}){super({defaultNamespace:e,errorTypeRegistries:r}),this.awsQueryCompatible=!!n,this.mixin=new Or(this.awsQueryCompatible)}async serializeRequest(e,r,n){let s=await super.serializeRequest(e,r,n);return this.awsQueryCompatible&&(s.headers["x-amzn-query-mode"]="true"),s}async handleError(e,r,n,s,o){this.awsQueryCompatible&&this.mixin.setQueryCompatError(s,n);let i=(()=>{let E=n.headers["x-amzn-query-error"];return E&&this.awsQueryCompatible?E.split(";")[0]:nl(n,s)??"Unknown"})();this.mixin.compose(this.compositeErrorRegistry,i,this.options.defaultNamespace);let{errorSchema:a,errorMetadata:c}=await this.mixin.getErrorSchemaOrThrowBaseException(i,this.options.defaultNamespace,n,s,o,this.awsQueryCompatible?this.mixin.findQueryCompatibleError:void 0),u=x.of(a),p=s.message??s.Message??"UnknownError",d=this.compositeErrorRegistry.getErrorCtor(a)??Error,m=new d({}),g={};for(let[E,_]of u.structIterator())s[E]!=null&&(g[E]=this.deserializer.readValue(_,s[E]));throw this.awsQueryCompatible&&this.mixin.queryCompatOutput(s,g),this.mixin.decorateServiceException(Object.assign(m,c,{$fault:u.getMergedTraits().error,message:p},g),s)}}});var Fe,sn=f(()=>{Fe=class{serdeContext;setSerdeContext(e){this.serdeContext=e}}});var To,_h=f(()=>{To=class{from;to;keys;constructor(e,r){this.from=e,this.to=r;let n=Object.keys(this.from),s=new Set(n);s.delete("__type"),this.keys=s}mark(e){this.keys.delete(e)}hasUnknown(){return this.keys.size===1&&Object.keys(this.to).length===0}writeUnknown(){if(this.hasUnknown()){let e=this.keys.values().next().value,r=this.from[e];this.to.$unknown=[e,r]}}}});function Rh(){if(cl===void 0)try{if(typeof Buffer!="function")cl=!1;else{let t=JSON.parse(Buffer.from([123,125]));cl=t!==null&&typeof t=="object"}}catch{cl=!1}return cl}var cl,WI=f(()=>{});function tc(t,e,r){if(r?.source){let n=r.source;if(typeof e=="number")return e<=Number.MAX_SAFE_INTEGER&&e>=Number.MIN_SAFE_INTEGER?ire(n,e)?e:new $(n,"bigDecimal"):ore(n)?new $(n,"bigDecimal"):/[eE]/.test(n)?are(n):BigInt(n)}return e}function ore(t){let e=t.indexOf(".");if(e===-1)return!1;let r=t.search(/[eE]/);if(r===-1)return!0;let n=r-e-1;return parseInt(t.slice(r+1),10)<n}function ire(t,e){if(t===String(e)||Object.is(e,-0))return!0;if(/[eE]/.test(t))return zI(t)===zI(String(e));let r=t.replace(/(\.\d*?)0+$/,"$1").replace(/\.$/,""),n=String(e);return r===n?!0:/[eE]/.test(n)?r===zI(n):!1}function zI(t){let e=t.startsWith("-"),r=e?t.slice(1):t,n=r.search(/[eE]/),s;if(n===-1)s=r;else{let o=parseInt(r.slice(n+1),10),i=r.slice(0,n),a=i.indexOf("."),c,u;a===-1?(c=i,u=i.length):(c=i.slice(0,a)+i.slice(a+1),u=a),c=c.replace(/0+$/,"")||"0";let p=u+o;c==="0"?s="0":p<=0?s="0."+"0".repeat(-p)+c:p>=c.length?s=c+"0".repeat(p-c.length):s=c.slice(0,p)+"."+c.slice(p)}return s.includes(".")&&(s=s.replace(/(\.\d*?)0+$/,"$1").replace(/\.$/,"")),(e?"-":"")+s}function are(t){let e=t.search(/[eE]/),r=parseInt(t.slice(e+1),10),n=t.startsWith("-"),s=t.slice(n?1:0,e),o=s.indexOf("."),i,a;if(o===-1)i=s,a=r;else{i=s.slice(0,o)+s.slice(o+1);let u=s.length-o-1;a=r-u}i=i.replace(/0+$/,"")||"0";let c=BigInt(i)*10n**BigInt(a+(s.replace(".","").length-i.length));return n?-c:c}var Th=f(()=>{L()});function rc(t){let e=x.of(t),r=e.getSchema();if(Array.isArray(r)&&e.isStructSchema()){if(jI in r)return r[jI];let n=Ah(e,new Set);return r[jI]=n,n}return Ah(e,new Set)}function Ah(t,e){let r=t.getSchema();if(e.has(r))return!1;if(e.add(r),t.isBigIntegerSchema()||t.isBigDecimalSchema())return!0;if(t.isStructSchema()){for(let[,n]of t.structIterator())if(Ah(n,e))return!0}else if(t.isListSchema()||t.isMapSchema()){if(Ah(t.getValueSchema(),e))return!0}else if(t.isDocumentSchema())return!0;return!1}var jI,Ih=f(()=>{K();jI=Symbol.for("@aws-sdk/reviver")});var xh,qI=f(()=>{G();L();xh=(t,e)=>Ge(t,e).then(r=>(e?.utf8Encoder??_e)(r))});async function mi(t,e,r){let n;if(Rh()&&typeof t?.[Symbol.asyncIterator]=="function"){let o=await Ge(t,e);typeof Buffer=="function"&&(Buffer.isBuffer(o)?n=o:n=Buffer.from(o.buffer,o.byteOffset,o.byteLength))}if(n||(n=await xh(t,e)),n.length===0)return{};let s=r&&rc(r)?tc:void 0;try{return JSON.parse(n,s)}catch(o){throw o?.name==="SyntaxError"&&Object.defineProperty(o,"$responseBodyText",{value:typeof n=="string"?n:n.toString("utf8")}),o}}var rF,tF,KI,Ch,bh,nF,nc=f(()=>{G();qI();WI();Th();Ih();rF=async(t,e)=>{let r=await mi(t,e);return r.message=r.message??r.Message,r},tF=(t,e)=>Object.keys(t).find(r=>r.toLowerCase()===e.toLowerCase()),KI=t=>{let e=t;return typeof e=="number"&&(e=e.toString()),e.indexOf(",")>=0&&(e=e.split(",")[0]),e.indexOf(":")>=0&&(e=e.split(":")[0]),e.indexOf("#")>=0&&(e=e.split("#")[1]),e},Ch=(t,e)=>nF(t,e,["header","code","type"]),bh=(t,e,r=!1)=>nF(t,e,r?["code","header","type"]:["type","code","header"]),nF=({headers:t},e,r)=>{for(;r.length>0;)switch(r.shift()){case"header":let s=tF(t??{},"x-amzn-errortype");if(s!==void 0)return KI(t[s]);break;case"code":let o=tF(e??{},"code");if(o&&e[o]!==void 0)return KI(e[o]);break;case"type":if(e?.__type!==void 0)return KI(e.__type);break}}});function vr(t){Object.defineProperty(t,"__proto__",{value:void 0,writable:!0,enumerable:!0,configurable:!0})}var ul=f(()=>{});var sc,YI=f(()=>{G();K();L();sn();_h();WI();Th();Ih();nc();ul();sc=class extends Fe{settings;constructor(e){super(),this.settings=e}async read(e,r){let n=rc(e)?tc:void 0,s;if(typeof r=="string"){if(r.length===0)return{};s=JSON.parse(r,n)}else if(r instanceof Uint8Array&&Rh()){if(r.byteLength===0)return{};let o=Buffer.isBuffer(r)?r:Buffer.from(r.buffer,r.byteOffset,r.byteLength);s=JSON.parse(o,n)}else s=await mi(r,this.serdeContext,e);return this._read(e,s)}readObject(e,r){return this._read(e,r)}_read(e,r){let n=r!==null&&typeof r=="object",s=x.of(e);if(n){if(s.isStructSchema())return this._readStruct(s,r);if(Array.isArray(r)&&s.isListSchema()){let i=s.getValueSchema();if(this.needsTransform(i))for(let a=0;a<r.length;++a)r[a]=this._read(i,r[a]);return r}if(s.isMapSchema()){let i=s.getValueSchema(),a=r;if(this.needsTransform(i))for(let c in a)c==="__proto__"&&vr(a),a[c]=this._read(i,a[c]);return a}}if(s.isBlobSchema()&&typeof r=="string")return Te(r);let o=s.getMergedTraits().mediaType;if(s.isStringSchema()&&typeof r=="string"&&o)return o==="application/json"||o.endsWith("+json")?Se.from(r):r;if(s.isTimestampSchema()&&r!=null)switch(Ae(s,this.settings)){case 5:return Dn(r);case 6:return _r(r);case 7:return On(r);default:return console.warn("Missing timestamp format, parsing value with Date constructor:",r),new Date(r)}if(s.isBigIntegerSchema()&&(typeof r=="number"||typeof r=="string"))return BigInt(r);if(s.isBigDecimalSchema()&&r!=null){if(r instanceof $)return r;let i=r;return i.type==="bigDecimal"&&"string"in i?new $(i.string,i.type):new $(String(r),"bigDecimal")}if(s.isNumericSchema()&&typeof r=="string"){switch(r){case"Infinity":return 1/0;case"-Infinity":return-1/0;case"NaN":return NaN}return r}if(s.isDocumentSchema()&&n)if(Array.isArray(r))for(let i=0;i<r.length;++i){let a=r[i];a instanceof $||(r[i]=this._read(s,a))}else{let i=r;for(let a in i){a==="__proto__"&&vr(i);let c=i[a];c instanceof $||(i[a]=this._read(s,c))}}return r}_readStruct(e,r){let n=e.isUnionSchema(),s={},o,i=typeof r.__type=="string",{jsonName:a}=this.settings;a&&i&&(o={});let c;n&&(c=new To(r,s));for(let[u,p]of e.structIterator()){let d=u;a&&(d=p.getMergedTraits().jsonName??d,i&&(o[d]=u)),n&&c.mark(d),r[d]!=null&&(s[u]=this._read(p,r[d]))}if(n)c.writeUnknown();else if(i)for(let u in r){let p=r[u],d=a?o[u]??u:u;d in s||(s[d]=p)}return s}needsTransform(e){return!!(e.isBlobSchema()||e.isTimestampSchema()||e.isBigIntegerSchema()||e.isBigDecimalSchema()||e.isDocumentSchema()||e.isStructSchema()||e.isListSchema()||e.isMapSchema()||e.isStringSchema()&&e.getMergedTraits().mediaType)}}});var wh,sF,oF=f(()=>{L();wh=class t extends Uint8Array{string=null;static allocUnsafe(e){if(typeof Buffer=="function"){let r=Buffer.allocUnsafe(e);return new t(r.buffer,r.byteOffset,r.byteLength)}return new t(e)}toString(){return this.s()}valueOf(){return this.s()}includes(e,r){return typeof e=="string"?this.s().includes(e,r):Uint8Array.prototype.includes.call(this,e,r)}indexOf(e,r){return typeof e=="string"?this.s().indexOf(e,r):Uint8Array.prototype.indexOf.call(this,e,r)}lastIndexOf(e,r){if(typeof e=="string")return this.s().lastIndexOf(e,r);let n=Uint8Array.prototype.lastIndexOf;return r!==void 0?n.call(this,e,r):n.call(this,e)}startsWith(e,r){return this.s().startsWith(e,r)}endsWith(e,r){return this.s().endsWith(e,r)}match(e){return this.s().match(e)}replace(e,r){return this.s().replace(e,r)}search(e){return this.s().search(e)}split(e,r){return this.s().split(e,r)}substring(e,r){return this.s().substring(e,r)}trim(){return this.s().trim()}trimStart(){return this.s().trimStart()}trimEnd(){return this.s().trimEnd()}charAt(e){return this.s().charAt(e)}charCodeAt(e){return this.s().charCodeAt(e)}padStart(e,r){return this.s().padStart(e,r)}padEnd(e,r){return this.s().padEnd(e,r)}repeat(e){return this.s().repeat(e)}toUpperCase(){return this.s().toUpperCase()}toLowerCase(){return this.s().toLowerCase()}s(){if(this.string==null){let e=Date.now();e>sF+6e4&&(console.warn("@aws-sdk/core/protocols - WARN - JsonCodec2: you have called a string method on a Uint8Array request body. It has been automatically converted to string. In a future version this will throw an error."),sF=e),this.string=_e(this)}return this.string}},sF=0});function QI(t){return wh.allocUnsafe(t)}var Dh,iF,aF,cre,ure,oc,Oh,vh,cF,lre,dre,pre,cs,uF,ic,JI=f(()=>{G();K();L();sn();oF();Dh=new TextEncoder,iF=123,aF=125,cre=91,ure=93,oc=34,Oh=58,vh=44,cF=92,lre=new Uint8Array([116,114,117,101]),dre=new Uint8Array([102,97,108,115,101]),pre=new Uint8Array([110,117,108,108]),cs=new Array(128).fill(null);cs[8]="b";cs[9]="t";cs[10]="n";cs[12]="f";cs[13]="r";cs[34]='"';cs[92]="\\";for(let t=0;t<32;t++)cs[t]===null&&(cs[t]="u00"+t.toString(16).padStart(2,"0"));uF=2048;ic=class t extends Fe{settings;json;i=0;rootSchema;rawValue;passthrough=!1;constructor(e){super(),this.settings=e,this.json=QI(uF)}write(e,r){this.i=0,this.rawValue=r,this.rootSchema=x.of(e),this.passthrough=this.rootSchema.isBlobSchema()||this.rootSchema.isStringSchema(),this.passthrough||this.writeValue(this.rootSchema,r,void 0)}writeDiscriminatedDocument(e,r){this.i=0,this.rootSchema=x.of(e);let n=this.rootSchema;if(n.isStructSchema()&&r!=null&&typeof r=="object"){this.writeValue(n,r,void 0);let s=`"__type":"${n.getName(!0)??"Unknown"}",`,o=s.length;this.ensure(o),this.json.copyWithin(1+o,1,this.i),Dh.encodeInto(s,this.json.subarray(1)),this.i+=o}else this.writeValue(n,r,void 0)}flush(){this.rootSchema=void 0;let e=this.i;this.i=0;let r=this.rawValue;if(this.rawValue=void 0,e===0)return r;let n=this.json.subarray(0,e);return this.json=QI(uF),n}ensure(e){let{i:r,json:n}=this;if(r+e>n.length){let s=n.length*2;for(;s<r+e;)s*=2;let o=QI(s);o.set(this.json),this.json=o}}writeAscii(e){let r=e.length;this.ensure(r);let{i:n,json:s}=this;for(let o=0;o<r;++o)s[n]=e.charCodeAt(o),n+=1;this.i=n}writeAsciiQuoted(e){let r=e.length;this.ensure(r+4);let{json:n,i:s}=this;n[s++]=oc;for(let o=0;o<r;++o)n[s++]=e.charCodeAt(o);n[s++]=oc,this.i=s}writeJsonString(e){this.ensure(e.length*3+2),this.json[this.i++]=oc;let r=e.length;for(let n=0;n<r;++n){let s=e.charCodeAt(n);if(s>34&&s<92)this.json[this.i++]=s;else if(s<128){let o=cs[s];if(o!==null){this.ensure(o.length+1),this.json[this.i++]=cF;for(let i=0;i<o.length;i++)this.json[this.i++]=o.charCodeAt(i)}else this.json[this.i++]=s}else if(s>=55296&&s<=56319){let o=n+1<r?e.charCodeAt(n+1):0;if(o>=56320&&o<=57343){this.ensure(4);let{written:i}=Dh.encodeInto(e.substring(n,n+2),this.json.subarray(this.i));this.i+=i,++n}else this.ensure(6),this.writeUnicodeEscape(s)}else if(s>=56320&&s<=57343)this.ensure(6),this.writeUnicodeEscape(s);else{let{i:o,json:i}=this;s<2048?(i[o++]=192|s>>6,i[o++]=128|s&63):(i[o++]=224|s>>12,i[o++]=128|s>>6&63,i[o++]=128|s&63),this.i=o}}this.json[this.i++]=oc}writeUnicodeEscape(e){let{json:r,i:n}=this;r[n++]=cF,r[n++]=117;let s=e.toString(16).padStart(4,"0");for(let o=0;o<4;++o)r[n++]=s.charCodeAt(o);this.i=n}static B64=(()=>{let e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",r=new Uint8Array(64);for(let n=0;n<64;++n)r[n]=e.charCodeAt(n);return r})();writeBase64(e){let r=Math.ceil(e.length/3)*4;this.ensure(r+2);let n=this.json,s=t.B64,o=this.i;n[o++]=oc;let i=e.length,a=i%3,c=i-a;for(let u=0;u<c;u+=3){let p=e[u],d=e[u+1],m=e[u+2];n[o++]=s[p>>2],n[o++]=s[(p&3)<<4|d>>4],n[o++]=s[(d&15)<<2|m>>6],n[o++]=s[m&63]}if(a===2){let u=e[c],p=e[c+1];n[o++]=s[u>>2],n[o++]=s[(u&3)<<4|p>>4],n[o++]=s[(p&15)<<2],n[o++]=61}else if(a===1){let u=e[c];n[o++]=s[u>>2],n[o++]=s[(u&3)<<4],n[o++]=61,n[o++]=61}n[o++]=oc,this.i=o}writeValue(e,r,n){if(r==null){if(n?.isStructSchema()){if(r===void 0&&x.of(e).isIdempotencyToken()){this.writeAsciiQuoted(Rt());return}return}this.ensure(4),this.json.set(pre,this.i),this.i+=4;return}let s=x.of(e),o=typeof r=="object";if(s.isStringSchema()){let i=s.getMergedTraits().mediaType;if(i&&(i==="application/json"||i.endsWith("+json"))){this.writeJsonString(Se.from(r).toString());return}}if(o){if(s.isStructSchema()){this.writeStruct(s,r);return}if(Array.isArray(r)&&(s.isListSchema()||s.isDocumentSchema())){this.writeList(s,r,s.isDocumentSchema());return}if(s.isMapSchema()){this.writeMap(s,r,!1);return}if(r instanceof Uint8Array&&(s.isBlobSchema()||s.isDocumentSchema())){this.writeBase64(r);return}if(r instanceof Date&&(s.isTimestampSchema()||s.isDocumentSchema())){this.writeTimestamp(s,r);return}if(r instanceof $){this.writeAscii(r.string);return}if(s.isDocumentSchema()){Array.isArray(r)?this.writeList(s,r,!0):this.writeMap(s,r,!0);return}let i=JSON.stringify(r);this.writeAscii(i);return}if(typeof r=="string"){if(s.isBlobSchema()){let i=(this.serdeContext?.base64Encoder??ne)(r);this.writeAsciiQuoted(i);return}this.writeJsonString(r);return}if(typeof r=="number"){if(Math.abs(r)===1/0||Number.isNaN(r)){this.writeAsciiQuoted(String(r));return}let i=String(r);this.writeAscii(i);return}if(typeof r=="boolean"){this.ensure(5);let{i,json:a}=this;r?(a.set(lre,i),i+=4):(a.set(dre,i),i+=5),this.i=i;return}if(typeof r=="bigint"){this.writeAscii(r.toString());return}this.writeAscii(String(r))}writeStruct(e,r){this.ensure(2),this.json[this.i++]=iF;let n=!1,s=typeof r.__type=="string",o;s&&(o=new Set);for(let[i,a]of e.structIterator()){let c=r[i];if(c==null&&!a.isIdempotencyToken())continue;n&&(this.ensure(1),this.json[this.i++]=vh),n=!0;let u=this.settings.jsonName?a.getMergedTraits().jsonName??i:i;o&&(o.add(i),o.add(u)),this.writeAsciiQuoted(u),this.json[this.i++]=Oh,this.writeValue(a,c,e)}if(!n&&e.isUnionSchema()){let{$unknown:i}=r;if(Array.isArray(i)){let[a,c]=i;this.writeAsciiQuoted(a),this.ensure(1),this.json[this.i++]=Oh,this.writeValue(15,c,e)}}else if(s)for(let i in r){if(o.has(i))continue;o.add(i);let a=r[i];n&&(this.ensure(1),this.json[this.i++]=vh),n=!0,this.writeAsciiQuoted(i),this.ensure(1),this.json[this.i++]=Oh,this.writeValue(15,a,void 0)}this.ensure(1),this.json[this.i++]=aF}writeList(e,r,n){let s=!!e.getMergedTraits().sparse,o=e.getValueSchema();if(!n&&(o.isStringSchema()||o.isNumericSchema()||o.isBooleanSchema())){let a=!1;for(let u=0;u<r.length;++u){let p=r[u];if(Number.isNaN(p)||p===1/0||p===-1/0||p==null&&!s){a=!0;break}}let c;if(!a)c=JSON.stringify(r);else{let u=[];for(let p=0;p<r.length;++p){let d=r[p];d==null&&!s||(Number.isNaN(d)||d===1/0||d===-1/0?u.push(String(d)):u.push(d))}c=JSON.stringify(u)}this.ensure(c.length*3),this.i+=Dh.encodeInto(c,this.json.subarray(this.i)).written;return}this.ensure(2),this.json[this.i++]=cre;let i=!1;for(let a=0;a<r.length;++a){let c=r[a];(n?c===void 0:c==null&&!s)||(i&&(this.ensure(1),this.json[this.i++]=vh),this.writeValue(o,c,void 0),i=!0)}this.ensure(1),this.json[this.i++]=ure}writeMap(e,r,n){let s=!!e.getMergedTraits().sparse,o=e.getValueSchema();if(!n&&(o.isStringSchema()||o.isNumericSchema()||o.isBooleanSchema())){let a;for(let u in r){let p=r[u];Number.isNaN(p)||p===1/0||p===-1/0?((a??={})[u]=p,r[u]=String(p)):p===null&&!s&&((a??={})[u]=null,r[u]=void 0)}let c=JSON.stringify(r);a&&Object.assign(r,a),this.ensure(c.length*3),this.i+=Dh.encodeInto(c,this.json.subarray(this.i)).written;return}this.ensure(2),this.json[this.i++]=iF;let i=!0;for(let a in r){let c=r[a];(n?c===void 0:c==null&&!s)||(i||(this.ensure(1),this.json[this.i++]=vh),i=!1,this.writeJsonString(a),this.ensure(1),this.json[this.i++]=Oh,this.writeValue(o,c,void 0))}this.ensure(1),this.json[this.i++]=aF}writeTimestamp(e,r){switch(Ae(e,this.settings)){case 5:{let s=r.toISOString().replace(".000Z","Z");this.writeAsciiQuoted(s);return}case 6:{this.writeAsciiQuoted(yt(r));return}case 7:{let s=String(r.getTime()/1e3);this.writeAscii(s);return}default:{let s=String(r.getTime()/1e3);this.writeAscii(s);return}}}}});var Ao,Ph=f(()=>{sn();YI();JI();Ao=class extends Fe{settings;constructor(e){super(),this.settings=e}createSerializer(){let e=new ic(this.settings);return e.setSerdeContext(this.serdeContext),e}createDeserializer(){let e=new sc(this.settings);return e.setSerdeContext(this.serdeContext),e}}});var Io,Nh=f(()=>{G();K();ec();Ph();nc();Io=class extends Ir{serializer;deserializer;serviceTarget;codec;mixin;awsQueryCompatible;constructor({defaultNamespace:e,errorTypeRegistries:r,serviceTarget:n,awsQueryCompatible:s,jsonCodec:o}){super({defaultNamespace:e,errorTypeRegistries:r}),this.serviceTarget=n,this.codec=o??new Ao({timestampFormat:{useTrait:!0,default:7},jsonName:!1}),this.serializer=this.codec.createSerializer(),this.deserializer=this.codec.createDeserializer(),this.awsQueryCompatible=!!s,this.mixin=new Or(this.awsQueryCompatible)}async serializeRequest(e,r,n){let s=await super.serializeRequest(e,r,n);return s.path.endsWith("/")||(s.path+="/"),s.headers["content-type"]=`application/x-amz-json-${this.getJsonRpcVersion()}`,s.headers["x-amz-target"]=`${this.serviceTarget}.${e.name}`,this.awsQueryCompatible&&(s.headers["x-amzn-query-mode"]="true"),(Yt(e.input)==="unit"||!s.body)&&(s.body="{}"),s}getPayloadCodec(){return this.codec}async handleError(e,r,n,s,o){let{awsQueryCompatible:i}=this;i&&this.mixin.setQueryCompatError(s,n);let a=bh(n,s,i)??"Unknown";this.mixin.compose(this.compositeErrorRegistry,a,this.options.defaultNamespace);let{errorSchema:c,errorMetadata:u}=await this.mixin.getErrorSchemaOrThrowBaseException(a,this.options.defaultNamespace,n,s,o,i?this.mixin.findQueryCompatibleError:void 0),p=x.of(c),d=s.message??s.Message??"UnknownError",m=this.compositeErrorRegistry.getErrorCtor(c)??Error,g=new m({}),E={},_=this.codec.createDeserializer();for(let[R,T]of p.structIterator())s[R]!=null&&(E[R]=_.readObject(T,s[R]));throw i&&this.mixin.queryCompatOutput(s,E),this.mixin.decorateServiceException(Object.assign(g,u,{$fault:p.getMergedTraits().error,message:d},E),s)}}});var kh,lF=f(()=>{Nh();kh=class extends Io{constructor({defaultNamespace:e,errorTypeRegistries:r,serviceTarget:n,awsQueryCompatible:s,jsonCodec:o}){super({defaultNamespace:e,errorTypeRegistries:r,serviceTarget:n,awsQueryCompatible:s,jsonCodec:o})}getShapeId(){return"aws.protocols#awsJson1_0"}getJsonRpcVersion(){return"1.0"}getDefaultContentType(){return"application/x-amz-json-1.0"}}});var Mh,dF=f(()=>{Nh();Mh=class extends Io{constructor({defaultNamespace:e,errorTypeRegistries:r,serviceTarget:n,awsQueryCompatible:s,jsonCodec:o}){super({defaultNamespace:e,errorTypeRegistries:r,serviceTarget:n,awsQueryCompatible:s,jsonCodec:o})}getShapeId(){return"aws.protocols#awsJson1_1"}getJsonRpcVersion(){return"1.1"}getDefaultContentType(){return"application/x-amz-json-1.1"}}});var us,pF=f(()=>{G();K();ec();Ph();nc();us=class extends io{serializer;deserializer;codec;mixin=new Or;constructor({defaultNamespace:e,errorTypeRegistries:r,jsonCodec:n}){super({defaultNamespace:e,errorTypeRegistries:r});let s={timestampFormat:{useTrait:!0,default:7},httpBindings:!0,jsonName:!0};this.codec=n??new Ao(s),this.serializer=new lo(this.codec.createSerializer(),s),this.deserializer=new uo(this.codec.createDeserializer(),s)}getShapeId(){return"aws.protocols#restJson1"}getPayloadCodec(){return this.codec}setSerdeContext(e){this.codec.setSerdeContext(e),super.setSerdeContext(e)}async serializeRequest(e,r,n){let s=await super.serializeRequest(e,r,n),o=x.of(e.input);if(!s.headers["content-type"]){let i=this.mixin.resolveRestContentType(this.getDefaultContentType(),o);i&&(s.headers["content-type"]=i)}return s.body==null&&s.headers["content-type"]===this.getDefaultContentType()&&(s.body="{}"),s}async deserializeResponse(e,r,n){let s=await super.deserializeResponse(e,r,n),o=x.of(e.output);for(let[i,a]of o.structIterator())a.getMemberTraits().httpPayload&&!(i in s)&&(s[i]=null);return s}async handleError(e,r,n,s,o){let i=Ch(n,s)??"Unknown";this.mixin.compose(this.compositeErrorRegistry,i,this.options.defaultNamespace);let{errorSchema:a,errorMetadata:c}=await this.mixin.getErrorSchemaOrThrowBaseException(i,this.options.defaultNamespace,n,s,o),u=x.of(a),p=s.message??s.Message??"UnknownError",d=this.compositeErrorRegistry.getErrorCtor(a)??Error,m=new d({});await this.deserializeHttpMessage(a,r,n,s);let g={},E=this.codec.createDeserializer();for(let[_,R]of u.structIterator()){let T=R.getMergedTraits().jsonName??_;g[_]=E.readObject(R,s[T])}throw this.mixin.decorateServiceException(Object.assign(m,c,{$fault:u.getMergedTraits().error,message:p},g),s)}getDefaultContentType(){return"application/json"}}});var ac,XI=f(()=>{G();K();L();L();sn();_h();Th();Ih();nc();ul();ac=class extends Fe{settings;constructor(e){super(),this.settings=e}async read(e,r){let n=rc(e)?tc:void 0;return this._read(e,typeof r=="string"?JSON.parse(r,n):await mi(r,this.serdeContext,e))}readObject(e,r){return this._read(e,r)}_read(e,r){let n=r!==null&&typeof r=="object",s=x.of(e);if(n){if(s.isStructSchema()){let i=r,a=s.isUnionSchema(),c={},u,{jsonName:p}=this.settings;p&&(u={});let d;a&&(d=new To(i,c));for(let[m,g]of s.structIterator()){let E=m;p&&(E=g.getMergedTraits().jsonName??E,u[E]=m),a&&d.mark(E),i[E]!=null&&(c[m]=this._read(g,i[E]))}if(a)d.writeUnknown();else if(typeof i.__type=="string")for(let m in i){let g=i[m],E=p?u[m]??m:m;E in c||(c[E]=g)}return c}if(Array.isArray(r)&&s.isListSchema()){let i=s.getValueSchema(),a=[];for(let c of r)a.push(this._read(i,c));return a}if(s.isMapSchema()){let i=s.getValueSchema(),a={};for(let c in r)c==="__proto__"&&vr(a),a[c]=this._read(i,r[c]);return a}}if(s.isBlobSchema()&&typeof r=="string")return Te(r);let o=s.getMergedTraits().mediaType;if(s.isStringSchema()&&typeof r=="string"&&o)return o==="application/json"||o.endsWith("+json")?Se.from(r):r;if(s.isTimestampSchema()&&r!=null)switch(Ae(s,this.settings)){case 5:return Dn(r);case 6:return _r(r);case 7:return On(r);default:return console.warn("Missing timestamp format, parsing value with Date constructor:",r),new Date(r)}if(s.isBigIntegerSchema()&&(typeof r=="number"||typeof r=="string"))return BigInt(r);if(s.isBigDecimalSchema()&&r!=null){if(r instanceof $)return r;let i=r;return i.type==="bigDecimal"&&"string"in i?new $(i.string,i.type):new $(String(r),"bigDecimal")}if(s.isNumericSchema()&&typeof r=="string"){switch(r){case"Infinity":return 1/0;case"-Infinity":return-1/0;case"NaN":return NaN}return r}if(s.isDocumentSchema())if(n){let i=Array.isArray(r)?[]:{};for(let a in r){a==="__proto__"&&vr(i);let c=r[a];c instanceof $?i[a]=c:i[a]=this._read(s,c)}return i}else return structuredClone(r);return r}}});var fF,Lh,mF=f(()=>{L();fF="\u039D",Lh=class{values=new Map;counter=0;stage=0;createReplacer(){if(this.stage===1)throw new Error("@aws-sdk/core/protocols - JsonReplacer already created.");if(this.stage===2)throw new Error("@aws-sdk/core/protocols - JsonReplacer exhausted.");return this.stage=1,(e,r)=>{if(r instanceof $){let n=`${fF+"nv"+this.counter++}_`+r.string;return this.values.set(`"${n}"`,r.string),n}if(typeof r=="bigint"){let n=r.toString(),s=`${fF+"b"+this.counter++}_`+n;return this.values.set(`"${s}"`,n),s}return r}}replaceInJson(e){if(this.stage===0)throw new Error("@aws-sdk/core/protocols - JsonReplacer not created yet.");if(this.stage===2)throw new Error("@aws-sdk/core/protocols - JsonReplacer exhausted.");if(this.stage=2,this.counter===0)return e;for(let[r,n]of this.values)e=e.replace(r,n);return e}}});var cc,ZI=f(()=>{G();K();L();sn();mF();ul();cc=class extends Fe{settings;buffer;useReplacer=!1;rootSchema;constructor(e){super(),this.settings=e}write(e,r){this.rootSchema=x.of(e),this.buffer=this._write(this.rootSchema,r)}flush(){let{rootSchema:e,useReplacer:r}=this;if(this.rootSchema=void 0,this.useReplacer=!1,e?.isStructSchema()||e?.isDocumentSchema()){if(!r)return JSON.stringify(this.buffer);let n=new Lh;return n.replaceInJson(JSON.stringify(this.buffer,n.createReplacer(),0))}return this.buffer}writeDiscriminatedDocument(e,r){this.write(e,r),typeof this.buffer=="object"&&(this.buffer.__type=x.of(e).getName(!0))}_write(e,r,n){let s=r!==null&&typeof r=="object",o=x.of(e);if(s){if(o.isStructSchema()){let i=r,a={},{jsonName:c}=this.settings,u;c&&(u={});let p=0;for(let[d,m]of o.structIterator()){let g=this._write(m,i[d],o);if(g!==void 0){let E=d;c&&(E=m.getMergedTraits().jsonName??d,u[d]=E),a[E]=g,p++}}if(o.isUnionSchema()&&p===0){let{$unknown:d}=i;if(Array.isArray(d)){let[m,g]=d;m==="__proto__"&&vr(a),a[m]=this._write(15,g)}}else if(typeof i.__type=="string")for(let d in i){let m=i[d],g=c?u[d]??d:d;g in a||(a[g]=this._write(15,m))}return a}if(Array.isArray(r)&&o.isListSchema()){let i=o.getValueSchema(),a=[],c=!!o.getMergedTraits().sparse;for(let u of r)(c||u!=null)&&a.push(this._write(i,u));return a}if(o.isMapSchema()){let i=o.getValueSchema(),a={},c=!!o.getMergedTraits().sparse;for(let u in r){let p=r[u];(c||p!=null)&&(u==="__proto__"&&vr(a),a[u]=this._write(i,p))}return a}if(r instanceof Uint8Array&&o.isBlobSchema())return o===this.rootSchema?r:(this.serdeContext?.base64Encoder??ne)(r);if(r instanceof Date&&(o.isTimestampSchema()||o.isDocumentSchema()))switch(Ae(o,this.settings)){case 5:return r.toISOString().replace(".000Z","Z");case 6:return yt(r);case 7:return r.getTime()/1e3;default:return console.warn("Missing timestamp format, using epoch seconds",r),r.getTime()/1e3}r instanceof $&&(this.useReplacer=!0)}if(!(r===null&&n?.isStructSchema())){if(o.isStringSchema()){if(typeof r>"u"&&o.isIdempotencyToken())return Rt();let i=o.getMergedTraits().mediaType;return r!=null&&i&&(i==="application/json"||i.endsWith("+json"))?Se.from(r):r}if(typeof r=="number")return Math.abs(r)===1/0||isNaN(r)?String(r):r;if(typeof r=="string"&&o.isBlobSchema())return o===this.rootSchema?r:(this.serdeContext?.base64Encoder??ne)(r);if(typeof r=="bigint"&&(this.useReplacer=!0),o.isDocumentSchema())if(s){if(r instanceof Uint8Array)return(this.serdeContext?.base64Encoder??ne)(r);let i=Array.isArray(r)?[]:{};for(let a in r){let c=r[a];a==="__proto__"&&vr(i),c instanceof $?(this.useReplacer=!0,i[a]=c):i[a]=this._write(o,c)}return i}else return structuredClone(r);return r}}}});var $h,hF=f(()=>{sn();XI();ZI();$h=class extends Fe{settings;constructor(e){super(),this.settings=e}createSerializer(){let e=new cc(this.settings);return e.setSerdeContext(this.serdeContext),e}createDeserializer(){let e=new ac(this.settings);return e.setSerdeContext(this.serdeContext),e}}});var Bh=Ne(Uh=>{var fre=/[&<>"]/g,mre={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;"};function hre(t){return t.replace(fre,e=>mre[e])}var gre=/[&"'<>\r\n\u0085\u2028]/g,Sre={"&":"&amp;",'"':"&quot;","'":"&apos;","<":"&lt;",">":"&gt;","\r":"&#x0D;","\n":"&#x0A;","\x85":"&#x85;","\u2028":"&#x2028;"};function Ere(t){return t.replace(gre,e=>Sre[e])}var Fh=class{value;constructor(e){this.value=e}toString(){return Ere(""+this.value)}},tx=class t{name;children;attributes={};static of(e,r,n){let s=new t(e);return r!==void 0&&s.addChildNode(new Fh(r)),n!==void 0&&s.withName(n),s}constructor(e,r=[]){this.name=e,this.children=r}withName(e){return this.name=e,this}addAttribute(e,r){return this.attributes[e]=r,this}addChildNode(e){return this.children.push(e),this}removeAttribute(e){return delete this.attributes[e],this}n(e){return this.name=e,this}c(e){return this.children.push(e),this}a(e,r){return r!=null&&(this.attributes[e]=r),this}cc(e,r,n=r){if(e[r]!=null){let s=t.of(r,e[r]).withName(n);this.c(s)}}l(e,r,n,s){e[r]!=null&&s().map(i=>{i.withName(n),this.c(i)})}lc(e,r,n,s){if(e[r]!=null){let o=s(),i=new t(n);o.map(a=>{i.c(a)}),this.c(i)}}toString(){let e=!!this.children.length,r=`<${this.name}`,n=this.attributes;for(let s of Object.keys(n)){let o=n[s];o!=null&&(r+=` ${s}="${hre(""+o)}"`)}return r+=e?`>${this.children.map(s=>s.toString()).join("")}</${this.name}>`:"/>"}};function ex(t){Object.defineProperty(t,"__proto__",{value:void 0,writable:!0,enumerable:!0,configurable:!0})}function yre(t){return new rx(t).parse()}var rx=class t{x;i=0;z;constructor(e){this.x=e,this.x=e.replace(/\r\n?/g,`
44
+ `),this.z=this.x.length}parse(){let e=this,{z:r}=e;for(;e.i<r&&(e.trim(),!(e.i>=r));)if(e.isNext("<?"))e.readTo("?>"),e.trim();else if(e.isNext("<!--"))e.readTo("-->"),e.trim();else if(e.isNext("<!DOCTYPE",!1))e.skipDoctype(),e.trim();else if(e.x[e.i]==="<"){let n=e.parseTag();return{[n.tag]:n.value}}else throw new Error("@aws-sdk XML parse error: unexpected content.");throw new Error("@aws-sdk XML parse error: no root element.")}isNext(e,r=!0){let n=this;return r?n.x.startsWith(e,n.i):n.x.toLowerCase().startsWith(e.toLowerCase(),n.i)}readTo(e){let r=this,n=r.x.indexOf(e,r.i);if(n===-1)throw new Error(`@aws-sdk XML parse error: expected "${e}" not found.`);let s=r.x.slice(r.i,n);return r.i=n+e.length,s}trim(){let e=this;for(;e.i<e.z&&` \r
45
+ `.includes(e.x[e.i]);)++e.i}readAttrValue(){let e=this,r=e.x[e.i];++e.i;let n="";for(;e.i<e.z&&e.x[e.i]!==r;)n+=e.x[e.i++];return++e.i,e.decodeEntities(n)}parseTag(){let e=this;++e.i;let r="";for(;e.i<e.z&&!` \r
46
+ >/`.includes(e.x[e.i]);)r+=e.x[e.i++];let n=!1,s={};for(;e.i<e.z&&(e.trim(),!">/".includes(e.x[e.i]));){let p="";for(;e.i<e.z&&!`= \r
47
+ >/?`.includes(e.x[e.i]);)p+=e.x[e.i++];if(e.trim(),e.x[e.i]!=="=")break;++e.i,e.trim(),p==="__proto__"&&ex(s),s[p]=e.readAttrValue(),n=!0}if(e.i>=e.z)throw new Error("@aws-sdk XML parse error: unexpected end of input.");if(e.x[e.i]==="/"){if(++e.i,e.i>=e.z||e.x[e.i]!==">")throw new Error("@aws-sdk XML parse error: expected > at the end of self-closing tag.");return++e.i,{tag:r,value:n?s:""}}if(e.x[e.i]!==">")throw new Error("@aws-sdk XML parse error: expected > at the end of opening tag.");++e.i;let o=[],i=[],a=!1;for(;e.i<e.z&&!e.isNext("</");)if(e.x[e.i]==="<")e.isNext("<!--")?e.readTo("-->"):e.isNext("<![CDATA[")?(e.i+=9,o.push(e.readTo("]]>"))):e.isNext("<?")?e.readTo("?>"):(a=!0,i.push(e.parseTag()));else{let p="";for(;e.i<e.z&&e.x[e.i]!=="<";)p+=e.x[e.i++];o.push(e.decodeEntities(p))}if(!e.isNext("</"))throw new Error(`@aws-sdk XML parse error: missing closing tag </${r}>.`);e.i+=2;let c=e.readTo(">").trim();if(c!==r)throw new Error(`@aws-sdk XML parse error: mismatched tags <${r}> and </${c}>.`);if(!n&&o.length===0&&!a)return{tag:r,value:""};if(!n&&!a){let p=o.length===1?o[0]:o.join("");return p.trim()===""&&p.includes(`
48
+ `)?{tag:r,value:""}:{tag:r,value:p}}let u={};for(let p of o)p.trim()===""&&p.includes(`
49
+ `)||(u["#text"]="#text"in u?u["#text"]+p:p);for(let p of i)p.tag==="__proto__"&&ex(u),p.tag in u?Array.isArray(u[p.tag])?u[p.tag].push(p.value):u[p.tag]=[u[p.tag],p.value]:u[p.tag]=p.value;for(let[p,d]of Object.entries(s))p==="__proto__"&&ex(u),u[p]=d;return{tag:r,value:u}}static ENTITIES={amp:"&",lt:"<",gt:">",quot:'"',apos:"'"};skipDoctype(){let e=this;e.i+=9;let r=0;for(;e.i<e.z;){let n=e.x[e.i];if(n==="[")++r;else if(n==="]")--r;else if(n===">"&&r===0){++e.i;return}++e.i}throw new Error("@aws-sdk XML parse error: unclosed DOCTYPE.")}decodeEntities(e){return e.replace(/&(?:#x([0-9a-fA-F]{1,6})|#(\d{1,7})|([a-zA-Z][a-zA-Z0-9]{0,30}));/g,(r,n,s,o)=>n?String.fromCharCode(parseInt(n,16)):s?String.fromCharCode(parseInt(s,10)):t.ENTITIES[o]??"")}};Uh.XmlNode=tx;Uh.XmlText=Fh;Uh.parseXML=yre});var gF,xo,Gh=f(()=>{gF=ye(Bh());V();G();K();L();sn();_h();ul();xo=class extends Fe{settings;stringDeserializer;constructor(e){super(),this.settings=e,this.stringDeserializer=new co(e)}setSerdeContext(e){this.serdeContext=e,this.stringDeserializer.setSerdeContext(e)}read(e,r,n){let s=x.of(e),o=s.getMemberSchemas();if(s.isStructSchema()&&s.isMemberSchema()&&!!Object.values(o).find(u=>!!u.getMemberTraits().eventPayload)){let u={},p=Object.keys(o)[0];return o[p].isBlobSchema()?u[p]=r:u[p]=this.read(o[p],r),u}let a=(this.serdeContext?.utf8Encoder??_e)(r),c=this.parseXml(a);return this.readSchema(e,n?c[n]:c)}readSchema(e,r){let n=x.of(e);if(n.isUnitSchema())return;let s=n.getMergedTraits();if(n.isListSchema()&&!Array.isArray(r))return this.readSchema(n,[r]);if(r==null)return r;if(typeof r=="object"){let o=!!s.xmlFlattened;if(n.isListSchema()){let a=n.getValueSchema(),c=[],u=a.getMergedTraits().xmlName??"member",p=o?r:(r[0]??r)[u];if(p==null)return c;let d=Array.isArray(p)?p:[p];for(let m of d)c.push(this.readSchema(a,m));return c}let i={};if(n.isMapSchema()){let a=n.getKeySchema(),c=n.getValueSchema(),u;o?u=Array.isArray(r)?r:[r]:u=Array.isArray(r.entry)?r.entry:[r.entry];let p=a.getMergedTraits().xmlName??"key",d=c.getMergedTraits().xmlName??"value";for(let m of u){let g=m[p],E=m[d];g==="__proto__"&&vr(i),i[g]=this.readSchema(c,E)}return i}if(n.isStructSchema()){let a=n.isUnionSchema(),c;a&&(c=new To(r,i));for(let[u,p]of n.structIterator()){let d=p.getMergedTraits(),m=d.httpPayload?d.xmlName??p.getName():p.getMemberTraits().xmlName??u;a&&c.mark(m),r[m]!=null&&(i[u]=this.readSchema(p,r[m]))}return a&&c.writeUnknown(),i}if(n.isDocumentSchema())return r;throw new Error(`@aws-sdk/core/protocols - xml deserializer unhandled schema type for ${n.getName(!0)}`)}return n.isListSchema()?[]:n.isMapSchema()||n.isStructSchema()?{}:this.stringDeserializer.read(n,r)}parseXml(e){if(e.length){let r;try{r=(0,gF.parseXML)(e)}catch(i){throw i&&typeof i=="object"&&Object.defineProperty(i,"$responseBodyText",{value:e}),i}let n="#text",s=Object.keys(r)[0],o=r[s];return o[n]&&(o[s]=o[n],delete o[n]),Xo(o)}return{}}}});var uc,nx=f(()=>{G();K();L();L();sn();uc=class extends Fe{settings;buffer;constructor(e){super(),this.settings=e}write(e,r,n=""){this.buffer===void 0&&(this.buffer="");let s=x.of(e);if(n&&!n.endsWith(".")&&(n+="."),s.isBlobSchema())(typeof r=="string"||r instanceof Uint8Array)&&(this.writeKey(n),this.writeValue((this.serdeContext?.base64Encoder??ne)(r)));else if(s.isBooleanSchema()||s.isNumericSchema()||s.isStringSchema())r!=null?(this.writeKey(n),this.writeValue(String(r))):s.isIdempotencyToken()&&(this.writeKey(n),this.writeValue(Rt()));else if(s.isBigIntegerSchema())r!=null&&(this.writeKey(n),this.writeValue(String(r)));else if(s.isBigDecimalSchema())r!=null&&(this.writeKey(n),this.writeValue(r instanceof $?r.string:String(r)));else if(s.isTimestampSchema()){if(r instanceof Date)switch(this.writeKey(n),Ae(s,this.settings)){case 5:this.writeValue(r.toISOString().replace(".000Z","Z"));break;case 6:this.writeValue(yt(r));break;case 7:this.writeValue(String(r.getTime()/1e3));break}}else if(s.isDocumentSchema())Array.isArray(r)?this.write(79,r,n):r instanceof Date?this.write(4,r,n):r instanceof Uint8Array?this.write(21,r,n):r&&typeof r=="object"?this.write(143,r,n):(this.writeKey(n),this.writeValue(String(r)));else if(s.isListSchema()){if(Array.isArray(r))if(r.length===0)this.settings.serializeEmptyLists&&(this.writeKey(n),this.writeValue(""));else{let o=s.getValueSchema(),i=this.settings.flattenLists||s.getMergedTraits().xmlFlattened,a=1;for(let c of r){if(c==null)continue;let u=o.getMergedTraits(),p=this.getKey("member",u.xmlName,u.ec2QueryName),d=i?`${n}${a}`:`${n}${p}.${a}`;this.write(o,c,d),++a}}}else if(s.isMapSchema()){if(r&&typeof r=="object"){let o=s.getKeySchema(),i=s.getValueSchema(),a=s.getMergedTraits().xmlFlattened,c=1;for(let u in r){let p=r[u];if(p==null)continue;let d=o.getMergedTraits(),m=this.getKey("key",d.xmlName,d.ec2QueryName),g=a?`${n}${c}.${m}`:`${n}entry.${c}.${m}`,E=i.getMergedTraits(),_=this.getKey("value",E.xmlName,E.ec2QueryName),R=a?`${n}${c}.${_}`:`${n}entry.${c}.${_}`;this.write(o,u,g),this.write(i,p,R),++c}}}else if(s.isStructSchema()){if(r&&typeof r=="object"){let o=!1;for(let[i,a]of s.structIterator()){if(r[i]==null&&!a.isIdempotencyToken())continue;let c=a.getMergedTraits(),u=this.getKey(i,c.xmlName,c.ec2QueryName,"struct"),p=`${n}${u}`;this.write(a,r[i],p),o=!0}if(!o&&s.isUnionSchema()){let{$unknown:i}=r;if(Array.isArray(i)){let[a,c]=i,u=`${n}${a}`;this.write(15,c,u)}}}}else if(!s.isUnitSchema())throw new Error(`@aws-sdk/core/protocols - QuerySerializer unrecognized schema type ${s.getName(!0)}`)}flush(){if(this.buffer===void 0)throw new Error("@aws-sdk/core/protocols - QuerySerializer cannot flush with nothing written to buffer.");let e=this.buffer;return delete this.buffer,e}getKey(e,r,n,s){let{ec2:o,capitalizeKeys:i}=this.settings;if(o&&n)return n;let a=r??e;return i&&s==="struct"?a[0].toUpperCase()+a.slice(1):a}writeKey(e){e.endsWith(".")&&(e=e.slice(0,e.length-1)),this.buffer+=`&${Kr(e)}=`}writeValue(e){this.buffer+=Kr(e)}}});var Co,sx=f(()=>{G();K();ec();Gh();nx();Co=class extends Ir{options;serializer;deserializer;mixin=new Or;constructor(e){super({defaultNamespace:e.defaultNamespace,errorTypeRegistries:e.errorTypeRegistries}),this.options=e;let r={timestampFormat:{useTrait:!0,default:5},httpBindings:!1,xmlNamespace:e.xmlNamespace,serviceNamespace:e.defaultNamespace,serializeEmptyLists:!0};this.serializer=new uc(r),this.deserializer=new xo(r)}getShapeId(){return"aws.protocols#awsQuery"}setSerdeContext(e){this.serializer.setSerdeContext(e),this.deserializer.setSerdeContext(e)}getPayloadCodec(){throw new Error("AWSQuery protocol has no payload codec.")}async serializeRequest(e,r,n){let s=await super.serializeRequest(e,r,n);s.path.endsWith("/")||(s.path+="/"),s.headers["content-type"]="application/x-www-form-urlencoded",(Yt(e.input)==="unit"||!s.body)&&(s.body="");let o=e.name.split("#")[1]??e.name;return s.body=`Action=${o}&Version=${this.options.version}`+s.body,s.body.endsWith("&")&&(s.body=s.body.slice(-1)),s}async deserializeResponse(e,r,n){let s=this.deserializer,o=x.of(e.output),i={};if(n.statusCode>=300){let p=await Ge(n.body,r);p.byteLength>0&&Object.assign(i,await s.read(15,p)),await this.handleError(e,r,n,i,this.deserializeMetadata(n))}for(let p in n.headers){let d=n.headers[p];delete n.headers[p],n.headers[p.toLowerCase()]=d}let a=e.name.split("#")[1]??e.name,c=o.isStructSchema()&&this.useNestedResult()?a+"Result":void 0,u=await Ge(n.body,r);return u.byteLength>0&&Object.assign(i,await s.read(o,u,c)),i.$metadata=this.deserializeMetadata(n),i}useNestedResult(){return!0}async handleError(e,r,n,s,o){let i=this.loadQueryErrorCode(n,s)??"Unknown";this.mixin.compose(this.compositeErrorRegistry,i,this.options.defaultNamespace);let a=this.loadQueryError(s)??{},c=this.loadQueryErrorMessage(s);a.message=c,a.Error={Type:a.Type,Code:a.Code,Message:c};let{errorSchema:u,errorMetadata:p}=await this.mixin.getErrorSchemaOrThrowBaseException(i,this.options.defaultNamespace,n,a,o,this.mixin.findQueryCompatibleError),d=x.of(u),m=this.compositeErrorRegistry.getErrorCtor(u)??Error,g=new m({}),E={Type:a.Error.Type,Code:a.Error.Code,Error:a.Error};for(let[_,R]of d.structIterator()){let T=R.getMergedTraits().xmlName??_,I=a[T]??s[T];E[_]=this.deserializer.readSchema(R,I)}throw this.mixin.decorateServiceException(Object.assign(g,p,{$fault:d.getMergedTraits().error,message:c},E),s)}loadQueryErrorCode(e,r){let n=(r.Errors?.[0]?.Error??r.Errors?.Error??r.Error)?.Code;if(n!==void 0)return n;if(e.statusCode==404)return"NotFound"}loadQueryError(e){return e.Errors?.[0]?.Error??e.Errors?.Error??e.Error}loadQueryErrorMessage(e){let r=this.loadQueryError(e);return r?.message??r?.Message??e.message??e.Message??"Unknown"}getDefaultContentType(){return"application/x-www-form-urlencoded"}}});var Hh,SF=f(()=>{sx();Hh=class extends Co{options;constructor(e){super(e),this.options=e;let r={capitalizeKeys:!0,flattenLists:!0,serializeEmptyLists:!1,ec2:!0};Object.assign(this.serializer.settings,r)}getShapeId(){return"aws.protocols#ec2Query"}useNestedResult(){return!1}}});var EF,ox,yF,Vh,ix=f(()=>{EF=ye(Bh());V();qI();ox=(t,e)=>xh(t,e).then(r=>{if(r.length){let n;try{n=(0,EF.parseXML)(r)}catch(a){throw a&&typeof a=="object"&&Object.defineProperty(a,"$responseBodyText",{value:r}),a}let s="#text",o=Object.keys(n)[0],i=n[o];return i[s]&&(i[o]=i[s],delete i[s]),Xo(i)}return{}}),yF=async(t,e)=>{let r=await ox(t,e);return r.Error&&(r.Error.message=r.Error.message??r.Error.Message),r},Vh=(t,e)=>{if(e?.Error?.Code!==void 0)return e.Error.Code;if(e?.Code!==void 0)return e.Code;if(t.statusCode==404)return"NotFound"}});var Ht,lc,ax=f(()=>{Ht=ye(Bh());G();K();L();L();sn();lc=class extends Fe{settings;stringBuffer;byteBuffer;buffer;constructor(e){super(),this.settings=e}write(e,r){let n=x.of(e);if(n.isStringSchema()&&typeof r=="string")this.stringBuffer=r;else if(n.isBlobSchema())this.byteBuffer="byteLength"in r?r:(this.serdeContext?.base64Decoder??Te)(r);else{this.buffer=this.writeStruct(n,r,void 0);let s=n.getMergedTraits();s.httpPayload&&!s.xmlName&&this.buffer.withName(n.getName())}}flush(){if(this.byteBuffer!==void 0){let r=this.byteBuffer;return delete this.byteBuffer,r}if(this.stringBuffer!==void 0){let r=this.stringBuffer;return delete this.stringBuffer,r}let e=this.buffer;return this.settings.xmlNamespace&&(e?.attributes?.xmlns||e.addAttribute("xmlns",this.settings.xmlNamespace)),delete this.buffer,e.toString()}writeStruct(e,r,n){let s=e.getMergedTraits(),o=e.isMemberSchema()&&!s.httpPayload?e.getMemberTraits().xmlName??e.getMemberName():s.xmlName??e.getName();if(!o||!e.isStructSchema())throw new Error(`@aws-sdk/core/protocols - xml serializer, cannot write struct with empty name or non-struct, schema=${e.getName(!0)}.`);let i=Ht.XmlNode.of(o),[a,c]=this.getXmlnsAttribute(e,n);for(let[p,d]of e.structIterator()){let m=r[p];if(m!=null||d.isIdempotencyToken()){if(d.getMergedTraits().xmlAttribute){i.addAttribute(d.getMergedTraits().xmlName??p,this.writeSimple(d,m));continue}if(d.isListSchema())this.writeList(d,m,i,c);else if(d.isMapSchema())this.writeMap(d,m,i,c);else if(d.isStructSchema())i.addChildNode(this.writeStruct(d,m,c));else{let g=Ht.XmlNode.of(d.getMergedTraits().xmlName??d.getMemberName());this.writeSimpleInto(d,m,g,c),i.addChildNode(g)}}}let{$unknown:u}=r;if(u&&e.isUnionSchema()&&Array.isArray(u)&&Object.keys(r).length===1){let[p,d]=u,m=Ht.XmlNode.of(p);if(typeof d!="string")if(r instanceof Ht.XmlNode||r instanceof Ht.XmlText)i.addChildNode(r);else throw new Error("@aws-sdk - $unknown union member in XML requires value of type string, @aws-sdk/xml-builder::XmlNode or XmlText.");this.writeSimpleInto(0,d,m,c),i.addChildNode(m)}return c&&i.addAttribute(a,c),i}writeList(e,r,n,s){if(!e.isMemberSchema())throw new Error(`@aws-sdk/core/protocols - xml serializer, cannot write non-member list: ${e.getName(!0)}`);let o=e.getMergedTraits(),i=e.getValueSchema(),a=i.getMergedTraits(),c=!!a.sparse,u=!!o.xmlFlattened,[p,d]=this.getXmlnsAttribute(e,s),m=(g,E)=>{if(i.isListSchema())this.writeList(i,Array.isArray(E)?E:[E],g,d);else if(i.isMapSchema())this.writeMap(i,E,g,d);else if(i.isStructSchema()){let _=this.writeStruct(i,E,d);g.addChildNode(_.withName(u?o.xmlName??e.getMemberName():a.xmlName??"member"))}else{let _=Ht.XmlNode.of(u?o.xmlName??e.getMemberName():a.xmlName??"member");this.writeSimpleInto(i,E,_,d),g.addChildNode(_)}};if(u)for(let g of r)(c||g!=null)&&m(n,g);else{let g=Ht.XmlNode.of(o.xmlName??e.getMemberName());d&&g.addAttribute(p,d);for(let E of r)(c||E!=null)&&m(g,E);n.addChildNode(g)}}writeMap(e,r,n,s,o=!1){if(!e.isMemberSchema())throw new Error(`@aws-sdk/core/protocols - xml serializer, cannot write non-member map: ${e.getName(!0)}`);let i=e.getMergedTraits(),a=e.getKeySchema(),u=a.getMergedTraits().xmlName??"key",p=e.getValueSchema(),d=p.getMergedTraits(),m=d.xmlName??"value",g=!!d.sparse,E=!!i.xmlFlattened,[_,R]=this.getXmlnsAttribute(e,s),T=(I,P,v)=>{let Z=Ht.XmlNode.of(u,P),[Pe,be]=this.getXmlnsAttribute(a,R);be&&Z.addAttribute(Pe,be),I.addChildNode(Z);let Ie=Ht.XmlNode.of(m);p.isListSchema()?this.writeList(p,v,Ie,R):p.isMapSchema()?this.writeMap(p,v,Ie,R,!0):p.isStructSchema()?Ie=this.writeStruct(p,v,R):this.writeSimpleInto(p,v,Ie,R),I.addChildNode(Ie)};if(E)for(let I in r){let P=r[I];if(g||P!=null){let v=Ht.XmlNode.of(i.xmlName??e.getMemberName());T(v,I,P),n.addChildNode(v)}}else{let I;o||(I=Ht.XmlNode.of(i.xmlName??e.getMemberName()),R&&I.addAttribute(_,R),n.addChildNode(I));for(let P in r){let v=r[P];if(g||v!=null){let Z=Ht.XmlNode.of("entry");T(Z,P,v),(o?n:I).addChildNode(Z)}}}}writeSimple(e,r){if(r===null)throw new Error("@aws-sdk/core/protocols - (XML serializer) cannot write null value.");let n=x.of(e),s=null;if(r&&typeof r=="object")if(n.isBlobSchema())s=(this.serdeContext?.base64Encoder??ne)(r);else if(n.isTimestampSchema()&&r instanceof Date)switch(Ae(n,this.settings)){case 5:s=r.toISOString().replace(".000Z","Z");break;case 6:s=yt(r);break;case 7:s=String(r.getTime()/1e3);break;default:console.warn("Missing timestamp format, using http date",r),s=yt(r);break}else{if(n.isBigDecimalSchema()&&r)return r instanceof $?r.string:String(r);throw n.isMapSchema()||n.isListSchema()?new Error("@aws-sdk/core/protocols - xml serializer, cannot call _write() on List/Map schema, call writeList or writeMap() instead."):new Error(`@aws-sdk/core/protocols - xml serializer, unhandled schema type for object value and schema: ${n.getName(!0)}`)}if((n.isBooleanSchema()||n.isNumericSchema()||n.isBigIntegerSchema()||n.isBigDecimalSchema())&&(s=String(r)),n.isStringSchema()&&(r===void 0&&n.isIdempotencyToken()?s=Rt():s=String(r)),s===null)throw new Error(`Unhandled schema-value pair ${n.getName(!0)}=${r}`);return s}writeSimpleInto(e,r,n,s){let o=this.writeSimple(e,r),i=x.of(e),a=new Ht.XmlText(o),[c,u]=this.getXmlnsAttribute(i,s);u&&n.addAttribute(c,u),n.addChildNode(a)}getXmlnsAttribute(e,r){let n=e.getMergedTraits(),[s,o]=n.xmlNamespace??[];return o&&o!==r?[s?`xmlns:${s}`:"xmlns",o]:[void 0,void 0]}}});var dc,cx=f(()=>{sn();Gh();ax();dc=class extends Fe{settings;constructor(e){super(),this.settings=e}createSerializer(){let e=new lc(this.settings);return e.setSerdeContext(this.serdeContext),e}createDeserializer(){let e=new xo(this.settings);return e.setSerdeContext(this.serdeContext),e}}});var Wh,_F=f(()=>{G();K();ec();ix();cx();Wh=class extends io{codec;serializer;deserializer;mixin=new Or;constructor(e){super(e);let r={timestampFormat:{useTrait:!0,default:5},httpBindings:!0,xmlNamespace:e.xmlNamespace,serviceNamespace:e.defaultNamespace};this.codec=new dc(r),this.serializer=new lo(this.codec.createSerializer(),r),this.deserializer=new uo(this.codec.createDeserializer(),r)}getPayloadCodec(){return this.codec}getShapeId(){return"aws.protocols#restXml"}async serializeRequest(e,r,n){let s=await super.serializeRequest(e,r,n),o=x.of(e.input);if(!s.headers["content-type"]){let i=this.mixin.resolveRestContentType(this.getDefaultContentType(),o);i&&(s.headers["content-type"]=i)}return typeof s.body=="string"&&s.headers["content-type"]===this.getDefaultContentType()&&!s.body.startsWith("<?xml ")&&!this.hasUnstructuredPayloadBinding(o)&&(s.body='<?xml version="1.0" encoding="UTF-8"?>'+s.body),s}async deserializeResponse(e,r,n){return super.deserializeResponse(e,r,n)}async handleError(e,r,n,s,o){let i=Vh(n,s)??"Unknown";if(this.mixin.compose(this.compositeErrorRegistry,i,this.options.defaultNamespace),s.Error&&typeof s.Error=="object")for(let _ of Object.keys(s.Error))s[_]=s.Error[_],_.toLowerCase()==="message"&&(s.message=s.Error[_]);s.RequestId&&!o.requestId&&(o.requestId=s.RequestId);let{errorSchema:a,errorMetadata:c}=await this.mixin.getErrorSchemaOrThrowBaseException(i,this.options.defaultNamespace,n,s,o),u=x.of(a),p=s.Error?.message??s.Error?.Message??s.message??s.Message??"UnknownError",d=this.compositeErrorRegistry.getErrorCtor(a)??Error,m=new d({});await this.deserializeHttpMessage(a,r,n,s);let g={},E=this.codec.createDeserializer();for(let[_,R]of u.structIterator()){let T=R.getMergedTraits().xmlName??_,I=s.Error?.[T]??s[T];g[_]=E.readSchema(R,I)}throw this.mixin.decorateServiceException(Object.assign(m,c,{$fault:u.getMergedTraits().error,message:p},g),s)}getDefaultContentType(){return"application/xml"}hasUnstructuredPayloadBinding(e){for(let[,r]of e.structIterator())if(r.getMergedTraits().httpPayload)return!(r.isStructSchema()||r.isMapSchema()||r.isListSchema());return!1}}});var RF,TF=f(()=>{L();RF=t=>{if(t!=null)return typeof t=="object"&&"__type"in t&&delete t.__type,$p(t)}});var AF,IF,xF,CF=f(()=>{AF=t=>{if(t==null)return t;if(typeof t=="number"||typeof t=="bigint"){let e=new Error(`Received number ${t} where a string was expected.`);return e.name="Warning",console.warn(e),String(t)}if(typeof t=="boolean"){let e=new Error(`Received boolean ${t} where a string was expected.`);return e.name="Warning",console.warn(e),String(t)}return t},IF=t=>{if(t==null)return t;if(typeof t=="string"){let e=t.toLowerCase();if(t!==""&&e!=="false"&&e!=="true"){let r=new Error(`Received string "${t}" where a boolean was expected.`);r.name="Warning",console.warn(r)}return t!==""&&e!=="false"}return t},xF=t=>{if(t==null)return t;if(typeof t=="string"){let e=Number(t);if(e.toString()!==t){let r=new Error(`Received string "${t}" where a number was expected.`);return r.name="Warning",console.warn(r),t}return e}return t}});var zh={};at(zh,{AwsEc2QueryProtocol:()=>Hh,AwsJson1_0Protocol:()=>kh,AwsJson1_1Protocol:()=>Mh,AwsJsonRpcProtocol:()=>Io,AwsQueryProtocol:()=>Co,AwsRestJsonProtocol:()=>us,AwsRestXmlProtocol:()=>Wh,AwsSmithyRpcV2CborProtocol:()=>yh,JsonCodec:()=>$h,JsonCodec2:()=>Ao,JsonShapeDeserializer:()=>ac,JsonShapeDeserializer2:()=>sc,JsonShapeSerializer:()=>cc,JsonShapeSerializer2:()=>ic,QueryShapeSerializer:()=>uc,XmlCodec:()=>dc,XmlShapeDeserializer:()=>xo,XmlShapeSerializer:()=>lc,_toBool:()=>IF,_toNum:()=>xF,_toStr:()=>AF,awsExpectUnion:()=>RF,loadJsonRpcErrorCode:()=>bh,loadRestJsonErrorCode:()=>Ch,loadRestXmlErrorCode:()=>Vh,parseJsonBody:()=>mi,parseJsonErrorBody:()=>rF,parseXmlBody:()=>ox,parseXmlErrorBody:()=>yF});var bo=f(()=>{eF();lF();dF();Nh();pF();hF();XI();ZI();Ph();YI();JI();nc();SF();sx();nx();_F();cx();Gh();ax();ix();TF();CF()});var ll,hi,jh,bF,vF,qh,ux,wF,lx,pc,DF,OF,_re,er,Rre,PF,NF=f(()=>{Re();ll="ref",hi=-1,jh=!0,bF="isSet",vF="PartitionResult",qh="booleanEquals",ux="getAttr",wF={[ll]:"Endpoint"},lx={[ll]:vF},pc={},DF=[{[ll]:"Region"}],OF={conditions:[[bF,[wF]],[bF,DF],["aws.partition",DF,vF],[qh,[{[ll]:"UseFIPS"},jh]],[qh,[{[ll]:"UseDualStack"},jh]],[qh,[{fn:ux,argv:[lx,"supportsDualStack"]},jh]],[qh,[{fn:ux,argv:[lx,"supportsFIPS"]},jh]],["stringEquals",[{fn:ux,argv:[lx,"name"]},"aws-us-gov"]]],results:[[hi],[hi,"Invalid Configuration: FIPS and custom endpoint are not supported"],[hi,"Invalid Configuration: Dualstack and custom endpoint are not supported"],[wF,pc],["https://oidc-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",pc],[hi,"FIPS and DualStack are enabled, but this partition does not support one or both"],["https://oidc.{Region}.amazonaws.com",pc],["https://oidc-fips.{Region}.{PartitionResult#dnsSuffix}",pc],[hi,"FIPS is enabled but this partition does not support FIPS"],["https://oidc.{Region}.{PartitionResult#dualStackDnsSuffix}",pc],[hi,"DualStack is enabled but this partition does not support DualStack"],["https://oidc.{Region}.{PartitionResult#dnsSuffix}",pc],[hi,"Invalid Configuration: Missing Region"]]},_re=2,er=1e8,Rre=new Int32Array([-1,1,-1,0,13,3,1,4,er+12,2,5,er+12,3,8,6,4,7,er+11,5,er+9,er+10,4,11,9,6,10,er+8,7,er+6,er+7,5,12,er+5,6,er+4,er+5,3,er+1,14,4,er+2,er+3]),PF=Tr.from(Rre,_re,OF.conditions,OF.results)});var Tre,kF,MF=f(()=>{ie();Re();NF();Tre=new Ar({size:50,params:["Endpoint","Region","UseDualStack","UseFIPS"]}),kF=(t,e={})=>Tre.get(t,()=>Un(PF,{endpointParams:t,logger:e.logger}));Jt.aws=tn});var ht,Kh=f(()=>{V();ht=class t extends yr{static shapeId="smithy.ts.sdk.synthetic.com.amazonaws.ssooidc#SSOOIDCServiceException";constructor(e){super(e),Object.setPrototypeOf(this,t.prototype)}}});var dl,pl,fl,ml,hl,gl,Sl,El,yl,_l,Rl,dx=f(()=>{Kh();dl=class t extends ht{static shapeId="com.amazonaws.ssooidc#AccessDeniedException";name="AccessDeniedException";$fault="client";error;reason;error_description;constructor(e){super({name:"AccessDeniedException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.error=e.error,this.reason=e.reason,this.error_description=e.error_description}},pl=class t extends ht{static shapeId="com.amazonaws.ssooidc#AuthorizationPendingException";name="AuthorizationPendingException";$fault="client";error;error_description;constructor(e){super({name:"AuthorizationPendingException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.error=e.error,this.error_description=e.error_description}},fl=class t extends ht{static shapeId="com.amazonaws.ssooidc#ExpiredTokenException";name="ExpiredTokenException";$fault="client";error;error_description;constructor(e){super({name:"ExpiredTokenException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.error=e.error,this.error_description=e.error_description}},ml=class t extends ht{static shapeId="com.amazonaws.ssooidc#InternalServerException";name="InternalServerException";$fault="server";error;error_description;constructor(e){super({name:"InternalServerException",$fault:"server",...e}),Object.setPrototypeOf(this,t.prototype),this.error=e.error,this.error_description=e.error_description}},hl=class t extends ht{static shapeId="com.amazonaws.ssooidc#InvalidClientException";name="InvalidClientException";$fault="client";error;error_description;constructor(e){super({name:"InvalidClientException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.error=e.error,this.error_description=e.error_description}},gl=class t extends ht{static shapeId="com.amazonaws.ssooidc#InvalidGrantException";name="InvalidGrantException";$fault="client";error;error_description;constructor(e){super({name:"InvalidGrantException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.error=e.error,this.error_description=e.error_description}},Sl=class t extends ht{static shapeId="com.amazonaws.ssooidc#InvalidRequestException";name="InvalidRequestException";$fault="client";error;reason;error_description;constructor(e){super({name:"InvalidRequestException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.error=e.error,this.reason=e.reason,this.error_description=e.error_description}},El=class t extends ht{static shapeId="com.amazonaws.ssooidc#InvalidScopeException";name="InvalidScopeException";$fault="client";error;error_description;constructor(e){super({name:"InvalidScopeException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.error=e.error,this.error_description=e.error_description}},yl=class t extends ht{static shapeId="com.amazonaws.ssooidc#SlowDownException";name="SlowDownException";$fault="client";error;error_description;constructor(e){super({name:"SlowDownException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.error=e.error,this.error_description=e.error_description}},_l=class t extends ht{static shapeId="com.amazonaws.ssooidc#UnauthorizedClientException";name="UnauthorizedClientException";$fault="client";error;error_description;constructor(e){super({name:"UnauthorizedClientException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.error=e.error,this.error_description=e.error_description}},Rl=class t extends ht{static shapeId="com.amazonaws.ssooidc#UnsupportedGrantTypeException";name="UnsupportedGrantTypeException";$fault="client";error;error_description;constructor(e){super({name:"UnsupportedGrantTypeException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.error=e.error,this.error_description=e.error_description}}});var Are,Ire,xre,Cre,bre,wre,Dre,Ore,vre,Pre,Nre,kre,Mre,Lre,$re,Fre,Ure,Bre,Gre,Hre,ls,Vre,Wre,zre,jre,qre,Ue,Kre,on,Yre,Qre,an,Jre,LF,$F,Xre,FF,Zre,ene,tne,ze,UF,BF,Pr,GF,HF,VF,WF,zF,jF,qF,KF,YF,QF,JF,px,rne,nne,sne,one,XF,ZF,e1,fx,Yh=f(()=>{K();dx();Kh();Are="AccessDeniedException",Ire="AuthorizationPendingException",xre="AccessToken",Cre="ClientSecret",bre="CreateToken",wre="CreateTokenRequest",Dre="CreateTokenResponse",Ore="CodeVerifier",vre="ExpiredTokenException",Pre="InvalidClientException",Nre="InvalidGrantException",kre="InvalidRequestException",Mre="InternalServerException",Lre="InvalidScopeException",$re="IdToken",Fre="RefreshToken",Ure="SlowDownException",Bre="UnauthorizedClientException",Gre="UnsupportedGrantTypeException",Hre="accessToken",ls="client",Vre="clientId",Wre="clientSecret",zre="codeVerifier",jre="code",qre="deviceCode",Ue="error",Kre="expiresIn",on="error_description",Yre="grantType",Qre="http",an="httpError",Jre="idToken",LF="reason",$F="refreshToken",Xre="redirectUri",FF="smithy.ts.sdk.synthetic.com.amazonaws.ssooidc",Zre="scope",ene="server",tne="tokenType",ze="com.amazonaws.ssooidc",UF=new ce(FF),BF=[-3,FF,"SSOOIDCServiceException",0,[],[]];UF.registerError(BF,ht);Pr=new ce(ze),GF=[-3,ze,Are,{[Ue]:ls,[an]:400},[Ue,LF,on],[0,0,0]];Pr.registerError(GF,dl);HF=[-3,ze,Ire,{[Ue]:ls,[an]:400},[Ue,on],[0,0]];Pr.registerError(HF,pl);VF=[-3,ze,vre,{[Ue]:ls,[an]:400},[Ue,on],[0,0]];Pr.registerError(VF,fl);WF=[-3,ze,Mre,{[Ue]:ene,[an]:500},[Ue,on],[0,0]];Pr.registerError(WF,ml);zF=[-3,ze,Pre,{[Ue]:ls,[an]:401},[Ue,on],[0,0]];Pr.registerError(zF,hl);jF=[-3,ze,Nre,{[Ue]:ls,[an]:400},[Ue,on],[0,0]];Pr.registerError(jF,gl);qF=[-3,ze,kre,{[Ue]:ls,[an]:400},[Ue,LF,on],[0,0,0]];Pr.registerError(qF,Sl);KF=[-3,ze,Lre,{[Ue]:ls,[an]:400},[Ue,on],[0,0]];Pr.registerError(KF,El);YF=[-3,ze,Ure,{[Ue]:ls,[an]:400},[Ue,on],[0,0]];Pr.registerError(YF,yl);QF=[-3,ze,Bre,{[Ue]:ls,[an]:400},[Ue,on],[0,0]];Pr.registerError(QF,_l);JF=[-3,ze,Gre,{[Ue]:ls,[an]:400},[Ue,on],[0,0]];Pr.registerError(JF,Rl);px=[UF,Pr],rne=[0,ze,xre,8,0],nne=[0,ze,Cre,8,0],sne=[0,ze,Ore,8,0],one=[0,ze,$re,8,0],XF=[0,ze,Fre,8,0],ZF=[3,ze,wre,0,[Vre,Wre,Yre,qre,jre,$F,Zre,Xre,zre],[0,[()=>nne,0],0,0,0,[()=>XF,0],64,0,[()=>sne,0]],3],e1=[3,ze,Dre,0,[Hre,tne,Kre,$F,Jre],[[()=>rne,0],0,1,[()=>XF,0],[()=>one,0]]],fx=[9,ze,bre,{[Qre]:["POST","/token",200]},()=>ZF,()=>e1]});var t1,r1=f(()=>{It();bo();At();Gn();V();G();L();II();MF();Yh();t1=t=>({apiVersion:"2019-06-10",base64Decoder:t?.base64Decoder??Te,base64Encoder:t?.base64Encoder??ne,disableHostPrefix:t?.disableHostPrefix??!1,endpointProvider:t?.endpointProvider??kF,extensions:t?.extensions??[],httpAuthSchemeProvider:t?.httpAuthSchemeProvider??v$,httpAuthSchemes:t?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:e=>e.getIdentityProvider("aws.auth#sigv4"),signer:new pt},{schemeId:"smithy.api#noAuth",identityProvider:e=>e.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new vt}],logger:t?.logger??new Qt,protocol:t?.protocol??us,protocolSettings:t?.protocolSettings??{defaultNamespace:"com.amazonaws.ssooidc",errorTypeRegistries:px,version:"2019-06-10",serviceTarget:"AWSSSOOIDCService"},serviceId:t?.serviceId??"SSO OIDC",sha256:t?.sha256??Yr,urlParser:t?.urlParser??Et,utf8Decoder:t?.utf8Decoder??tt,utf8Encoder:t?.utf8Encoder??_e})});var Qh,n1,s1=f(()=>{rl();ie();It();V();se();Zt();L();Qh=ye(Ps());r1();n1=t=>{xn(process.version);let e=$n(t),r=()=>e().then(In),n=t1(t);Rn(process.version);let s={profile:t?.profile,logger:n.logger};return{...n,...t,runtime:"node",defaultsMode:e,authSchemePreference:t?.authSchemePreference??q(rn,s),bodyLengthChecker:t?.bodyLengthChecker??vn,defaultUserAgentProvider:t?.defaultUserAgentProvider??en({serviceId:n.serviceId,clientVersion:_o.version}),maxAttempts:t?.maxAttempts??q(Yn,t),region:t?.region??q(_t,{...Bt,...s}),requestHandler:Qh.NodeHttpHandler.create(t?.requestHandler??r),retryMode:t?.retryMode??q({...Jn,default:async()=>(await r()).retryMode||xr},t),streamCollector:t?.streamCollector??Qh.streamCollector,useDualstackEndpoint:t?.useDualstackEndpoint??q(Mn,s),useFipsEndpoint:t?.useFipsEndpoint??q(Ln,s),userAgentAppId:t?.userAgentAppId??q(ns,s)}}});var o1,i1,a1=f(()=>{o1=t=>{let e=t.httpAuthSchemes,r=t.httpAuthSchemeProvider,n=t.credentials;return{setHttpAuthScheme(s){let o=e.findIndex(i=>i.schemeId===s.schemeId);o===-1?e.push(s):e.splice(o,1,s)},httpAuthSchemes(){return e},setHttpAuthSchemeProvider(s){r=s},httpAuthSchemeProvider(){return r},setCredentials(s){n=s},credentials(){return n}}},i1=t=>({httpAuthSchemes:t.httpAuthSchemes(),httpAuthSchemeProvider:t.httpAuthSchemeProvider(),credentials:t.credentials()})});var c1,u1=f(()=>{ie();V();G();a1();c1=(t,e)=>{let r=Object.assign(ss(t),zr(t),Hn(t),o1(t));return e.forEach(n=>n.configure(r)),Object.assign(t,os(r),Cn(r),Vn(r),i1(r))}});var Tl,mx=f(()=>{ie();At();V();se();Re();G();Zt();K();II();xI();s1();u1();Tl=class extends Dt{config;constructor(...[e]){let r=n1(e||{});super(r),this.initConfig=r;let n=N$(r),s=ts(n),o=Qn(s),i=ur(o),a=i,c=Cs(a),u=P$(c),p=c1(u,e?.extensions||[]);this.config=p,this.middlewareStack.use(Tn(this.config)),this.middlewareStack.use(rs(this.config)),this.middlewareStack.use(Os(this.config)),this.middlewareStack.use(Wn(this.config)),this.middlewareStack.use(Xn(this.config)),this.middlewareStack.use(Zn(this.config)),this.middlewareStack.use(es(this.config)),this.middlewareStack.use(Xr(this.config,{httpAuthSchemeParametersProvider:O$,identityProviderConfigProvider:async d=>new pr({"aws.auth#sigv4":d.credentials})})),this.middlewareStack.use(Zr(this.config))}destroy(){super.destroy()}}});var l1,d1,p1,f1=f(()=>{V();Re();xI();l1=bn(k$,"AWSSSOOIDCService","SSOOIDCClient",bs),d1={},p1=(t,e,r,n)=>[]});var Al,hx=f(()=>{f1();Yh();Al=class extends l1(d1,p1,"CreateToken",fx){}});var ine,Jh,m1=f(()=>{V();hx();mx();ine={CreateTokenCommand:Al},Jh=class extends Tl{};An(ine,Jh)});var h1=f(()=>{hx()});var ane,cne,g1=f(()=>{ane={KMS_ACCESS_DENIED:"KMS_AccessDeniedException"},cne={KMS_DISABLED_KEY:"KMS_DisabledException",KMS_INVALID_KEY_USAGE:"KMS_InvalidKeyUsageException",KMS_INVALID_STATE:"KMS_InvalidStateException",KMS_KEY_NOT_FOUND:"KMS_NotFoundException"}});var S1=f(()=>{});var gx={};at(gx,{$Command:()=>Ft,AccessDeniedException:()=>dl,AccessDeniedException$:()=>GF,AccessDeniedExceptionReason:()=>ane,AuthorizationPendingException:()=>pl,AuthorizationPendingException$:()=>HF,CreateToken$:()=>fx,CreateTokenCommand:()=>Al,CreateTokenRequest$:()=>ZF,CreateTokenResponse$:()=>e1,ExpiredTokenException:()=>fl,ExpiredTokenException$:()=>VF,InternalServerException:()=>ml,InternalServerException$:()=>WF,InvalidClientException:()=>hl,InvalidClientException$:()=>zF,InvalidGrantException:()=>gl,InvalidGrantException$:()=>jF,InvalidRequestException:()=>Sl,InvalidRequestException$:()=>qF,InvalidRequestExceptionReason:()=>cne,InvalidScopeException:()=>El,InvalidScopeException$:()=>KF,SSOOIDC:()=>Jh,SSOOIDCClient:()=>Tl,SSOOIDCServiceException:()=>ht,SSOOIDCServiceException$:()=>BF,SlowDownException:()=>yl,SlowDownException$:()=>YF,UnauthorizedClientException:()=>_l,UnauthorizedClientException$:()=>QF,UnsupportedGrantTypeException:()=>Rl,UnsupportedGrantTypeException$:()=>JF,__Client:()=>Dt,errorTypeRegistries:()=>px});var Sx=f(()=>{mx();m1();h1();V();Yh();g1();dx();S1();Kh()});var R1=Ne(Il=>{var{setTokenFeature:une}=(ie(),O(wr)),{getBearerTokenEnvKey:lne}=(It(),O(Qu)),{TokenProviderError:cn,getSSOTokenFilepath:dne,parseKnownFiles:pne,getProfileName:fne,loadSsoSessionData:mne,getSSOTokenFromFile:hne,memoize:gne,chain:Sne}=(se(),O(Gt)),{promises:Ene}=require("node:fs"),yne=({logger:t,signingName:e}={})=>async()=>{if(t?.debug?.("@aws-sdk/token-providers - fromEnvSigningName"),!e)throw new cn("Please pass 'signingName' to compute environment variable key",{logger:t});let r=lne(e);if(!(r in process.env))throw new cn(`Token not present in '${r}' environment variable`,{logger:t});let n={token:process.env[r]};return une(n,"BEARER_SERVICE_ENV_VARS","3"),n},_ne=300*1e3,Ex="To refresh this SSO session run 'aws sso login' with the corresponding profile.",Rne=async(t,e={},r)=>{let{SSOOIDCClient:n}=(Sx(),O(gx)),s=i=>e.clientConfig?.[i]??e.parentClientConfig?.[i]??r?.[i];return new n(Object.assign({},e.clientConfig??{},{region:t??e.clientConfig?.region,logger:s("logger"),userAgentAppId:s("userAgentAppId")}))},Tne=async(t,e,r={},n)=>{let{CreateTokenCommand:s}=(Sx(),O(gx));return(await Rne(e,r,n)).send(new s({clientId:t.clientId,clientSecret:t.clientSecret,refreshToken:t.refreshToken,grantType:"refresh_token"}))},E1=t=>{if(t.expiration&&t.expiration.getTime()<Date.now())throw new cn(`Token is expired. ${Ex}`,!1)},gi=(t,e,r=!1)=>{if(typeof e>"u")throw new cn(`Value not present for '${t}' in SSO Token${r?". Cannot refresh":""}. ${Ex}`,!1)},{writeFile:Ane}=Ene,Ine=(t,e)=>{let r=dne(t),n=JSON.stringify(e,null,2);return Ane(r,n)},y1=new Map,_1=(t={})=>async({callerClientConfig:e}={})=>{t.logger?.debug("@aws-sdk/token-providers - fromSso");let r=await pne(t),n=fne({profile:t.profile??e?.profile}),s=r[n];if(s){if(!s.sso_session)throw new cn(`Profile '${n}' is missing required property 'sso_session'.`)}else throw new cn(`Profile '${n}' could not be found in shared credentials file.`,!1);let o=s.sso_session,a=(await mne(t))[o];if(!a)throw new cn(`Sso session '${o}' could not be found in shared credentials file.`,!1);for(let E of["sso_start_url","sso_region"])if(!a[E])throw new cn(`Sso session '${o}' is missing required property '${E}'.`,!1);a.sso_start_url;let c=a.sso_region,u;try{u=await hne(o)}catch{throw new cn(`The SSO session token associated with profile=${n} was not found or is invalid. ${Ex}`,!1)}gi("accessToken",u.accessToken),gi("expiresAt",u.expiresAt);let{accessToken:p,expiresAt:d}=u,m={token:p,expiration:new Date(d)};if(m.expiration.getTime()-Date.now()>_ne)return m;let g=y1.get(o)??0;if(Date.now()-g<30*1e3)return E1(m),m;gi("clientId",u.clientId,!0),gi("clientSecret",u.clientSecret,!0),gi("refreshToken",u.refreshToken,!0);try{y1.set(o,Date.now());let E=await Tne(u,c,t,e);gi("accessToken",E.accessToken),gi("expiresIn",E.expiresIn);let _=new Date(Date.now()+E.expiresIn*1e3);try{await Ine(o,{...u,accessToken:E.accessToken,expiresAt:_.toISOString(),refreshToken:E.refreshToken})}catch{}return{token:E.accessToken,expiration:_}}catch{return E1(m),m}},xne=({token:t,logger:e})=>async()=>{if(e?.debug("@aws-sdk/token-providers - fromStatic"),!t||!t.token)throw new cn("Please pass a valid token to fromStatic",!1);return t},Cne=(t={})=>gne(Sne(_1(t),async()=>{throw new cn("Could not load token from any providers",!1)}),e=>e.expiration!==void 0&&e.expiration.getTime()-Date.now()<3e5,e=>e.expiration!==void 0);Il.fromEnvSigningName=yne;Il.fromSso=_1;Il.fromStatic=xne;Il.nodeProvider=Cne});function bne(t){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"awsssoportal",region:t.region},propertiesExtractor:(e,r)=>({signingProperties:{config:e,context:r}})}}function wne(t){return{schemeId:"smithy.api#noAuth"}}var T1,A1,I1,yx=f(()=>{It();V();T1=async(t,e,r)=>({operation:he(e).operation,region:await ge(t.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()});A1=t=>{let e=[];return t.operation==="GetRoleCredentials"?e.push(wne(t)):e.push(bne(t)),e},I1=t=>{let e=is(t);return Object.assign(e,{authSchemePreference:ge(t.authSchemePreference??[])})}});var x1,C1,_x=f(()=>{x1=t=>Object.assign(t,{useDualstackEndpoint:t.useDualstackEndpoint??!1,useFipsEndpoint:t.useFipsEndpoint??!1,defaultSigningName:"awsssoportal"}),C1={UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}}});var xl,Si,Xh,b1,v1,Zh,Rx,w1,Tx,fc,D1,O1,Dne,tr,One,P1,N1=f(()=>{Re();xl="ref",Si=-1,Xh=!0,b1="isSet",v1="PartitionResult",Zh="booleanEquals",Rx="getAttr",w1={[xl]:"Endpoint"},Tx={[xl]:v1},fc={},D1=[{[xl]:"Region"}],O1={conditions:[[b1,[w1]],[b1,D1],["aws.partition",D1,v1],[Zh,[{[xl]:"UseFIPS"},Xh]],[Zh,[{[xl]:"UseDualStack"},Xh]],[Zh,[{fn:Rx,argv:[Tx,"supportsDualStack"]},Xh]],[Zh,[{fn:Rx,argv:[Tx,"supportsFIPS"]},Xh]],["stringEquals",[{fn:Rx,argv:[Tx,"name"]},"aws-us-gov"]]],results:[[Si],[Si,"Invalid Configuration: FIPS and custom endpoint are not supported"],[Si,"Invalid Configuration: Dualstack and custom endpoint are not supported"],[w1,fc],["https://portal.sso-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",fc],[Si,"FIPS and DualStack are enabled, but this partition does not support one or both"],["https://portal.sso.{Region}.amazonaws.com",fc],["https://portal.sso-fips.{Region}.{PartitionResult#dnsSuffix}",fc],[Si,"FIPS is enabled but this partition does not support FIPS"],["https://portal.sso.{Region}.{PartitionResult#dualStackDnsSuffix}",fc],[Si,"DualStack is enabled but this partition does not support DualStack"],["https://portal.sso.{Region}.{PartitionResult#dnsSuffix}",fc],[Si,"Invalid Configuration: Missing Region"]]},Dne=2,tr=1e8,One=new Int32Array([-1,1,-1,0,13,3,1,4,tr+12,2,5,tr+12,3,8,6,4,7,tr+11,5,tr+9,tr+10,4,11,9,6,10,tr+8,7,tr+6,tr+7,5,12,tr+5,6,tr+4,tr+5,3,tr+1,14,4,tr+2,tr+3]),P1=Tr.from(One,Dne,O1.conditions,O1.results)});var vne,k1,M1=f(()=>{ie();Re();N1();vne=new Ar({size:50,params:["Endpoint","Region","UseDualStack","UseFIPS"]}),k1=(t,e={})=>vne.get(t,()=>Un(P1,{endpointParams:t,logger:e.logger}));Jt.aws=tn});var un,eg=f(()=>{V();un=class t extends yr{static shapeId="smithy.ts.sdk.synthetic.com.amazonaws.sso#SSOServiceException";constructor(e){super(e),Object.setPrototypeOf(this,t.prototype)}}});var Cl,bl,wl,Dl,Ax=f(()=>{eg();Cl=class t extends un{static shapeId="com.amazonaws.sso#InvalidRequestException";name="InvalidRequestException";$fault="client";constructor(e){super({name:"InvalidRequestException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}},bl=class t extends un{static shapeId="com.amazonaws.sso#ResourceNotFoundException";name="ResourceNotFoundException";$fault="client";constructor(e){super({name:"ResourceNotFoundException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}},wl=class t extends un{static shapeId="com.amazonaws.sso#TooManyRequestsException";name="TooManyRequestsException";$fault="client";constructor(e){super({name:"TooManyRequestsException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}},Dl=class t extends un{static shapeId="com.amazonaws.sso#UnauthorizedException";name="UnauthorizedException";$fault="client";constructor(e){super({name:"UnauthorizedException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}}});var Pne,Nne,kne,Mne,Lne,$ne,Fne,Une,Bne,Gne,Hne,Vne,Wne,zne,jne,tg,rg,qne,Kne,ng,Yne,L1,sg,Qne,Jne,Xne,$1,Zne,ese,tse,Nr,F1,U1,Ol,B1,G1,H1,V1,Ix,rse,nse,sse,W1,z1,j1,xx,og=f(()=>{K();Ax();eg();Pne="AccessTokenType",Nne="GetRoleCredentials",kne="GetRoleCredentialsRequest",Mne="GetRoleCredentialsResponse",Lne="InvalidRequestException",$ne="RoleCredentials",Fne="ResourceNotFoundException",Une="SecretAccessKeyType",Bne="SessionTokenType",Gne="TooManyRequestsException",Hne="UnauthorizedException",Vne="accountId",Wne="accessKeyId",zne="accessToken",jne="account_id",tg="client",rg="error",qne="expiration",Kne="http",ng="httpError",Yne="httpHeader",L1="httpQuery",sg="message",Qne="roleCredentials",Jne="roleName",Xne="role_name",$1="smithy.ts.sdk.synthetic.com.amazonaws.sso",Zne="secretAccessKey",ese="sessionToken",tse="x-amz-sso_bearer_token",Nr="com.amazonaws.sso",F1=new ce($1),U1=[-3,$1,"SSOServiceException",0,[],[]];F1.registerError(U1,un);Ol=new ce(Nr),B1=[-3,Nr,Lne,{[rg]:tg,[ng]:400},[sg],[0]];Ol.registerError(B1,Cl);G1=[-3,Nr,Fne,{[rg]:tg,[ng]:404},[sg],[0]];Ol.registerError(G1,bl);H1=[-3,Nr,Gne,{[rg]:tg,[ng]:429},[sg],[0]];Ol.registerError(H1,wl);V1=[-3,Nr,Hne,{[rg]:tg,[ng]:401},[sg],[0]];Ol.registerError(V1,Dl);Ix=[F1,Ol],rse=[0,Nr,Pne,8,0],nse=[0,Nr,Une,8,0],sse=[0,Nr,Bne,8,0],W1=[3,Nr,kne,0,[Jne,Vne,zne],[[0,{[L1]:Xne}],[0,{[L1]:jne}],[()=>rse,{[Yne]:tse}]],3],z1=[3,Nr,Mne,0,[Qne],[[()=>j1,0]]],j1=[3,Nr,$ne,0,[Wne,Zne,ese,qne],[0,[()=>nse,0],[()=>sse,0],1]],xx=[9,Nr,Nne,{[Kne]:["GET","/federation/credentials",200]},()=>W1,()=>z1]});var q1,K1=f(()=>{It();bo();At();Gn();V();G();L();yx();M1();og();q1=t=>({apiVersion:"2019-06-10",base64Decoder:t?.base64Decoder??Te,base64Encoder:t?.base64Encoder??ne,disableHostPrefix:t?.disableHostPrefix??!1,endpointProvider:t?.endpointProvider??k1,extensions:t?.extensions??[],httpAuthSchemeProvider:t?.httpAuthSchemeProvider??A1,httpAuthSchemes:t?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:e=>e.getIdentityProvider("aws.auth#sigv4"),signer:new pt},{schemeId:"smithy.api#noAuth",identityProvider:e=>e.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new vt}],logger:t?.logger??new Qt,protocol:t?.protocol??us,protocolSettings:t?.protocolSettings??{defaultNamespace:"com.amazonaws.sso",errorTypeRegistries:Ix,version:"2019-06-10",serviceTarget:"SWBPortalService"},serviceId:t?.serviceId??"SSO",sha256:t?.sha256??Yr,urlParser:t?.urlParser??Et,utf8Decoder:t?.utf8Decoder??tt,utf8Encoder:t?.utf8Encoder??_e})});var ig,Y1,Q1=f(()=>{rl();ie();It();V();se();Zt();L();ig=ye(Ps());K1();Y1=t=>{xn(process.version);let e=$n(t),r=()=>e().then(In),n=q1(t);Rn(process.version);let s={profile:t?.profile,logger:n.logger};return{...n,...t,runtime:"node",defaultsMode:e,authSchemePreference:t?.authSchemePreference??q(rn,s),bodyLengthChecker:t?.bodyLengthChecker??vn,defaultUserAgentProvider:t?.defaultUserAgentProvider??en({serviceId:n.serviceId,clientVersion:_o.version}),maxAttempts:t?.maxAttempts??q(Yn,t),region:t?.region??q(_t,{...Bt,...s}),requestHandler:ig.NodeHttpHandler.create(t?.requestHandler??r),retryMode:t?.retryMode??q({...Jn,default:async()=>(await r()).retryMode||xr},t),streamCollector:t?.streamCollector??ig.streamCollector,useDualstackEndpoint:t?.useDualstackEndpoint??q(Mn,s),useFipsEndpoint:t?.useFipsEndpoint??q(Ln,s),userAgentAppId:t?.userAgentAppId??q(ns,s)}}});var J1,X1,Z1=f(()=>{J1=t=>{let e=t.httpAuthSchemes,r=t.httpAuthSchemeProvider,n=t.credentials;return{setHttpAuthScheme(s){let o=e.findIndex(i=>i.schemeId===s.schemeId);o===-1?e.push(s):e.splice(o,1,s)},httpAuthSchemes(){return e},setHttpAuthSchemeProvider(s){r=s},httpAuthSchemeProvider(){return r},setCredentials(s){n=s},credentials(){return n}}},X1=t=>({httpAuthSchemes:t.httpAuthSchemes(),httpAuthSchemeProvider:t.httpAuthSchemeProvider(),credentials:t.credentials()})});var eU,tU=f(()=>{ie();V();G();Z1();eU=(t,e)=>{let r=Object.assign(ss(t),zr(t),Hn(t),J1(t));return e.forEach(n=>n.configure(r)),Object.assign(t,os(r),Cn(r),Vn(r),X1(r))}});var vl,Cx=f(()=>{ie();At();V();se();Re();G();Zt();K();yx();_x();Q1();tU();vl=class extends Dt{config;constructor(...[e]){let r=Y1(e||{});super(r),this.initConfig=r;let n=x1(r),s=ts(n),o=Qn(s),i=ur(o),a=i,c=Cs(a),u=I1(c),p=eU(u,e?.extensions||[]);this.config=p,this.middlewareStack.use(Tn(this.config)),this.middlewareStack.use(rs(this.config)),this.middlewareStack.use(Os(this.config)),this.middlewareStack.use(Wn(this.config)),this.middlewareStack.use(Xn(this.config)),this.middlewareStack.use(Zn(this.config)),this.middlewareStack.use(es(this.config)),this.middlewareStack.use(Xr(this.config,{httpAuthSchemeParametersProvider:T1,identityProviderConfigProvider:async d=>new pr({"aws.auth#sigv4":d.credentials})})),this.middlewareStack.use(Zr(this.config))}destroy(){super.destroy()}}});var rU,nU,sU,oU=f(()=>{V();Re();_x();rU=bn(C1,"SWBPortalService","SSOClient",bs),nU={},sU=(t,e,r,n)=>[]});var Pl,bx=f(()=>{oU();og();Pl=class extends rU(nU,sU,"GetRoleCredentials",xx){}});var ose,ag,iU=f(()=>{V();bx();Cx();ose={GetRoleCredentialsCommand:Pl},ag=class extends vl{};An(ose,ag)});var aU=f(()=>{bx()});var cU=f(()=>{});var uU={};at(uU,{$Command:()=>Ft,GetRoleCredentials$:()=>xx,GetRoleCredentialsCommand:()=>Pl,GetRoleCredentialsRequest$:()=>W1,GetRoleCredentialsResponse$:()=>z1,InvalidRequestException:()=>Cl,InvalidRequestException$:()=>B1,ResourceNotFoundException:()=>bl,ResourceNotFoundException$:()=>G1,RoleCredentials$:()=>j1,SSO:()=>ag,SSOClient:()=>vl,SSOServiceException:()=>un,SSOServiceException$:()=>U1,TooManyRequestsException:()=>wl,TooManyRequestsException$:()=>H1,UnauthorizedException:()=>Dl,UnauthorizedException$:()=>V1,__Client:()=>Dt,errorTypeRegistries:()=>Ix});var lU=f(()=>{Cx();iU();aU();V();og();Ax();cU();eg()});var dU=Ne(wx=>{var{GetRoleCredentialsCommand:ise,SSOClient:ase}=(lU(),O(uU));wx.GetRoleCredentialsCommand=ise;wx.SSOClient=ase});var Dx=Ne(cg=>{var{CredentialsProviderError:ln,getSSOTokenFromFile:cse,getProfileName:use,parseKnownFiles:lse,loadSsoSessionData:dse}=(se(),O(Gt)),{setCredentialFeature:pU}=(ie(),O(wr)),{fromSso:pse}=R1(),mU=t=>t&&(typeof t.sso_start_url=="string"||typeof t.sso_account_id=="string"||typeof t.sso_session=="string"||typeof t.sso_region=="string"||typeof t.sso_role_name=="string"),Nl=!1,fU=async({ssoStartUrl:t,ssoSession:e,ssoAccountId:r,ssoRegion:n,ssoRoleName:s,ssoClient:o,clientConfig:i,parentClientConfig:a,callerClientConfig:c,profile:u,filepath:p,configFilepath:d,ignoreCache:m,logger:g})=>{let E,_="To refresh this SSO session run aws sso login with the corresponding profile.";if(e)try{let Kt=await pse({profile:u,filepath:p,configFilepath:d,ignoreCache:m,clientConfig:i,parentClientConfig:a,logger:g})({callerClientConfig:c});E={accessToken:Kt.token,expiresAt:new Date(Kt.expiration).toISOString()}}catch(Kt){throw new ln(Kt.message,{tryNextLink:Nl,logger:g})}else try{E=await cse(t)}catch{throw new ln(`The SSO session associated with this profile is invalid. ${_}`,{tryNextLink:Nl,logger:g})}if(new Date(E.expiresAt).getTime()-Date.now()<=0)throw new ln(`The SSO session associated with this profile has expired. ${_}`,{tryNextLink:Nl,logger:g});let{accessToken:R}=E,{SSOClient:T,GetRoleCredentialsCommand:I}=dU(),P=o||new T(Object.assign({},i??{},{logger:i?.logger??c?.logger??a?.logger,region:i?.region??n,userAgentAppId:i?.userAgentAppId??c?.userAgentAppId??a?.userAgentAppId})),v;try{v=await P.send(new I({accountId:r,roleName:s,accessToken:R}))}catch(Kt){throw new ln(Kt,{tryNextLink:Nl,logger:g})}let{roleCredentials:{accessKeyId:Z,secretAccessKey:Pe,sessionToken:be,expiration:Ie,credentialScope:Me,accountId:Lt}={}}=v;if(!Z||!Pe||!be||!Ie)throw new ln("SSO returns an invalid temporary credential.",{tryNextLink:Nl,logger:g});let $t={accessKeyId:Z,secretAccessKey:Pe,sessionToken:be,expiration:new Date(Ie),...Me&&{credentialScope:Me},...Lt&&{accountId:Lt}};return e?pU($t,"CREDENTIALS_SSO","s"):pU($t,"CREDENTIALS_SSO_LEGACY","u"),$t},hU=(t,e)=>{let{sso_start_url:r,sso_account_id:n,sso_region:s,sso_role_name:o}=t;if(!r||!n||!s||!o)throw new ln(`Profile is configured with invalid SSO credentials. Required parameters "sso_account_id", "sso_region", "sso_role_name", "sso_start_url". Got ${Object.keys(t).join(", ")}
50
+ Reference: https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-sso.html`,{tryNextLink:!1,logger:e});return t},fse=(t={})=>async({callerClientConfig:e}={})=>{t.logger?.debug("@aws-sdk/credential-provider-sso - fromSSO");let{ssoStartUrl:r,ssoAccountId:n,ssoRegion:s,ssoRoleName:o,ssoSession:i}=t,{ssoClient:a}=t,c=use({profile:t.profile??e?.profile});if(!r&&!n&&!s&&!o&&!i){let p=(await lse(t))[c];if(!p)throw new ln(`Profile ${c} was not found.`,{logger:t.logger});if(!mU(p))throw new ln(`Profile ${c} is not configured with SSO credentials.`,{logger:t.logger});if(p?.sso_session){let T=(await dse(t))[p.sso_session],I=` configurations in profile ${c} and sso-session ${p.sso_session}`;if(s&&s!==T.sso_region)throw new ln("Conflicting SSO region"+I,{tryNextLink:!1,logger:t.logger});if(r&&r!==T.sso_start_url)throw new ln("Conflicting SSO start_url"+I,{tryNextLink:!1,logger:t.logger});p.sso_region=T.sso_region,p.sso_start_url=T.sso_start_url}let{sso_start_url:d,sso_account_id:m,sso_region:g,sso_role_name:E,sso_session:_}=hU(p,t.logger);return fU({ssoStartUrl:d,ssoSession:_,ssoAccountId:m,ssoRegion:g,ssoRoleName:E,ssoClient:a,clientConfig:t.clientConfig,parentClientConfig:t.parentClientConfig,callerClientConfig:t.callerClientConfig,profile:c,filepath:t.filepath,configFilepath:t.configFilepath,ignoreCache:t.ignoreCache,logger:t.logger})}else{if(!r||!n||!s||!o)throw new ln('Incomplete configuration. The fromSSO() argument hash must include "ssoStartUrl", "ssoAccountId", "ssoRegion", "ssoRoleName"',{tryNextLink:!1,logger:t.logger});return fU({ssoStartUrl:r,ssoSession:i,ssoAccountId:n,ssoRegion:s,ssoRoleName:o,ssoClient:a,clientConfig:t.clientConfig,parentClientConfig:t.parentClientConfig,callerClientConfig:t.callerClientConfig,profile:c,filepath:t.filepath,configFilepath:t.configFilepath,ignoreCache:t.ignoreCache,logger:t.logger})}};cg.fromSSO=fse;cg.isSsoProfile=mU;cg.validateSsoProfile=hU});var Px=Ne(lg=>{var{SignatureV4:mse,signatureV4aContainer:gU}=iI(),kl={CrtSignerV4:null},Ox="X-Amz-S3session-Token",SU=Ox.toLowerCase(),ug=class extends mse{async signWithCredentials(e,r,n){let s=EU(r);e.headers[SU]=r.sessionToken;let o=this;return yU(o,s),o.signRequest(e,n??{})}async presignWithCredentials(e,r,n){let s=EU(r);return delete e.headers[SU],e.headers[Ox]=r.sessionToken,e.query=e.query??{},e.query[Ox]=r.sessionToken,yU(this,s),this.presign(e,n)}};function EU(t){return{accessKeyId:t.accessKeyId,secretAccessKey:t.secretAccessKey,expiration:t.expiration}}function yU(t,e){let r=t.credentialProvider;t.credentialProvider=()=>(t.credentialProvider=r,Promise.resolve(e))}var vx=class{sigv4aSigner;sigv4Signer;signerOptions;static sigv4aDependency(){return typeof kl.CrtSignerV4=="function"?"crt":typeof gU.SignatureV4a=="function"?"js":"none"}constructor(e){this.sigv4Signer=new ug(e),this.signerOptions=e}async sign(e,r={}){return r.signingRegion==="*"?this.getSigv4aSigner().sign(e,r):this.sigv4Signer.sign(e,r)}async signWithCredentials(e,r,n={}){if(n.signingRegion==="*"){let s=this.getSigv4aSigner(),o=kl.CrtSignerV4;if(o&&s instanceof o)return s.signWithCredentials(e,r,n);throw new Error(`signWithCredentials with signingRegion '*' is only supported when using the CRT dependency @aws-sdk/signature-v4-crt. Please check whether you have installed the "@aws-sdk/signature-v4-crt" package explicitly. You must also register the package by calling [require("@aws-sdk/signature-v4-crt");] or an ESM equivalent such as [import "@aws-sdk/signature-v4-crt";]. For more information please go to https://github.com/aws/aws-sdk-js-v3#functionality-requiring-aws-common-runtime-crt`)}return this.sigv4Signer.signWithCredentials(e,r,n)}async presign(e,r={}){if(r.signingRegion==="*"){let n=this.getSigv4aSigner(),s=kl.CrtSignerV4;if(s&&n instanceof s)return n.presign(e,r);throw new Error(`presign with signingRegion '*' is only supported when using the CRT dependency @aws-sdk/signature-v4-crt. Please check whether you have installed the "@aws-sdk/signature-v4-crt" package explicitly. You must also register the package by calling [require("@aws-sdk/signature-v4-crt");] or an ESM equivalent such as [import "@aws-sdk/signature-v4-crt";]. For more information please go to https://github.com/aws/aws-sdk-js-v3#functionality-requiring-aws-common-runtime-crt`)}return this.sigv4Signer.presign(e,r)}async presignWithCredentials(e,r,n={}){if(n.signingRegion==="*")throw new Error("Method presignWithCredentials is not supported for [signingRegion=*].");return this.sigv4Signer.presignWithCredentials(e,r,n)}getSigv4aSigner(){if(!this.sigv4aSigner){let e=kl.CrtSignerV4,r=gU.SignatureV4a;if(this.signerOptions.runtime==="node"){if(!e&&!r)throw new Error("Neither CRT nor JS SigV4a implementation is available. Please load either @aws-sdk/signature-v4-crt or @aws-sdk/signature-v4a. For more information please go to https://github.com/aws/aws-sdk-js-v3#functionality-requiring-aws-common-runtime-crt");if(e&&typeof e=="function")this.sigv4aSigner=new e({...this.signerOptions,signingAlgorithm:1});else if(r&&typeof r=="function")this.sigv4aSigner=new r({...this.signerOptions});else throw new Error("Available SigV4a implementation is not a valid constructor. Please ensure you've properly imported @aws-sdk/signature-v4-crt or @aws-sdk/signature-v4a.For more information please go to https://github.com/aws/aws-sdk-js-v3#functionality-requiring-aws-common-runtime-crt")}else{if(!r||typeof r!="function")throw new Error("JS SigV4a implementation is not available or not a valid constructor. Please check whether you have installed the @aws-sdk/signature-v4a package explicitly. The CRT implementation is not available for browsers. You must also register the package by calling [require('@aws-sdk/signature-v4a');] or an ESM equivalent such as [import '@aws-sdk/signature-v4a';]. For more information please go to https://github.com/aws/aws-sdk-js-v3#using-javascript-non-crt-implementation-of-sigv4a");this.sigv4aSigner=new r({...this.signerOptions})}}return this.sigv4aSigner}};lg.SignatureV4MultiRegion=vx;lg.SignatureV4SignWithCredentials=ug;lg.signatureV4CrtContainer=kl});var hc,Ei,Ml,_U,wU,Ll,Ct,Nx,RU,TU,AU,IU,xU,bt,kx,mc,CU,bU,hse,oe,gse,DU,OU=f(()=>{Re();hc="ref",Ei=-1,Ml=!0,_U="isSet",wU="PartitionResult",Ll="booleanEquals",Ct="stringEquals",Nx="getAttr",RU="us-east-1",TU="sigv4",AU="sts",IU="https://sts.{Region}.{PartitionResult#dnsSuffix}",xU={[hc]:"Endpoint"},bt={[hc]:"Region"},kx={[hc]:wU},mc={},CU=[bt],bU={conditions:[[_U,[xU]],[_U,CU],["aws.partition",CU,wU],[Ll,[{[hc]:"UseFIPS"},Ml]],[Ll,[{[hc]:"UseDualStack"},Ml]],[Ct,[bt,"aws-global"]],[Ll,[{[hc]:"UseGlobalEndpoint"},Ml]],[Ct,[bt,"eu-central-1"]],[Ll,[{fn:Nx,argv:[kx,"supportsDualStack"]},Ml]],[Ll,[{fn:Nx,argv:[kx,"supportsFIPS"]},Ml]],[Ct,[bt,"ap-south-1"]],[Ct,[bt,"eu-north-1"]],[Ct,[bt,"eu-west-1"]],[Ct,[bt,"eu-west-2"]],[Ct,[bt,"eu-west-3"]],[Ct,[bt,"sa-east-1"]],[Ct,[bt,RU]],[Ct,[bt,"us-east-2"]],[Ct,[bt,"us-west-2"]],[Ct,[bt,"us-west-1"]],[Ct,[bt,"ca-central-1"]],[Ct,[bt,"ap-southeast-1"]],[Ct,[bt,"ap-northeast-1"]],[Ct,[bt,"ap-southeast-2"]],[Ct,[{fn:Nx,argv:[kx,"name"]},"aws-us-gov"]]],results:[[Ei],["https://sts.amazonaws.com",{authSchemes:[{name:TU,signingName:AU,signingRegion:RU}]}],[IU,{authSchemes:[{name:TU,signingName:AU,signingRegion:"{Region}"}]}],[Ei,"Invalid Configuration: FIPS and custom endpoint are not supported"],[Ei,"Invalid Configuration: Dualstack and custom endpoint are not supported"],[xU,mc],["https://sts-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",mc],[Ei,"FIPS and DualStack are enabled, but this partition does not support one or both"],["https://sts.{Region}.amazonaws.com",mc],["https://sts-fips.{Region}.{PartitionResult#dnsSuffix}",mc],[Ei,"FIPS is enabled but this partition does not support FIPS"],["https://sts.{Region}.{PartitionResult#dualStackDnsSuffix}",mc],[Ei,"DualStack is enabled but this partition does not support DualStack"],[IU,mc],[Ei,"Invalid Configuration: Missing Region"]]},hse=2,oe=1e8,gse=new Int32Array([-1,1,-1,0,30,3,1,4,oe+14,2,5,oe+14,3,25,6,4,24,7,5,oe+1,8,6,9,oe+13,7,oe+1,10,10,oe+1,11,11,oe+1,12,12,oe+1,13,13,oe+1,14,14,oe+1,15,15,oe+1,16,16,oe+1,17,17,oe+1,18,18,oe+1,19,19,oe+1,20,20,oe+1,21,21,oe+1,22,22,oe+1,23,23,oe+1,oe+2,8,oe+11,oe+12,4,28,26,9,27,oe+10,24,oe+8,oe+9,8,29,oe+7,9,oe+6,oe+7,3,oe+3,31,4,oe+4,oe+5]),DU=Tr.from(gse,hse,bU.conditions,bU.results)});var Sse,dg,Mx=f(()=>{ie();Re();OU();Sse=new Ar({size:50,params:["Endpoint","Region","UseDualStack","UseFIPS","UseGlobalEndpoint"]}),dg=(t,e={})=>Sse.get(t,()=>Un(DU,{endpointParams:t,logger:e.logger}));Jt.aws=tn});function NU(t){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"sts",region:t.region},propertiesExtractor:(e,r)=>({signingProperties:{config:e,context:r}})}}function Lx(t){return{schemeId:"aws.auth#sigv4a",signingProperties:{name:"sts",region:t.region},propertiesExtractor:(e,r)=>({signingProperties:{config:e,context:r}})}}function kU(t){return{schemeId:"smithy.api#noAuth"}}var vU,Ese,yse,PU,_se,Rse,MU,LU,$x=f(()=>{It();vU=ye(Px());V();Re();Mx();Ese=t=>async(e,r,n)=>{if(!n)throw new Error("Could not find `input` for `defaultEndpointRuleSetHttpAuthSchemeParametersProvider`");let s=await t(e,r,n),o=he(r)?.commandInstance?.constructor?.getEndpointParameterInstructions;if(!o)throw new Error(`getEndpointParameterInstructions() is not defined on '${r.commandName}'`);let i=await _u(n,{getEndpointParameterInstructions:o},e);return Object.assign(s,i)},yse=async(t,e,r)=>({operation:he(e).operation,region:await ge(t.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()}),PU=Ese(yse);_se=(t,e,r)=>s=>{let i=t(s).properties?.authSchemes;if(!i)return e(s);let a=[];for(let c of i){let{name:u,properties:p={},...d}=c,m=u.toLowerCase();u!==m&&console.warn(`HttpAuthScheme has been normalized with lowercasing: '${u}' to '${m}'`);let g;if(m==="sigv4a"){g="aws.auth#sigv4a";let R=i.find(T=>{let I=T.name.toLowerCase();return I!=="sigv4a"&&I.startsWith("sigv4")});if(vU.SignatureV4MultiRegion.sigv4aDependency()==="none"&&R)continue}else if(m.startsWith("sigv4"))g="aws.auth#sigv4";else throw new Error(`Unknown HttpAuthScheme found in '@smithy.rules#endpointRuleSet': '${m}'`);let E=r[g];if(!E)throw new Error(`Could not find HttpAuthOption create function for '${g}'`);let _=E(s);_.schemeId=g,_.signingProperties={..._.signingProperties||{},...d,...p},a.push(_)}return a},Rse=t=>{let e=[];return t.operation==="AssumeRoleWithWebIdentity"?(e.push(kU(t)),e.push(Lx(t))):(e.push(NU(t)),e.push(Lx(t))),e},MU=_se(dg,Rse,{"aws.auth#sigv4":NU,"aws.auth#sigv4a":Lx,"smithy.api#noAuth":kU}),LU=t=>{let e=is(t),r=qu(e);return Object.assign(r,{authSchemePreference:ge(t.authSchemePreference??[])})}});var $U,FU,Fx=f(()=>{$U=t=>Object.assign(t,{useDualstackEndpoint:t.useDualstackEndpoint??!1,useFipsEndpoint:t.useFipsEndpoint??!1,useGlobalEndpoint:t.useGlobalEndpoint??!1,defaultSigningName:"sts"}),FU={UseGlobalEndpoint:{type:"builtInParams",name:"useGlobalEndpoint"},UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}}});var rr,pg=f(()=>{V();rr=class t extends yr{static shapeId="smithy.ts.sdk.synthetic.com.amazonaws.sts#STSServiceException";constructor(e){super(e),Object.setPrototypeOf(this,t.prototype)}}});var $l,Fl,Ul,Bl,Gl,Hl,Vl,Ux=f(()=>{pg();$l=class t extends rr{static shapeId="com.amazonaws.sts#ExpiredTokenException";name="ExpiredTokenException";$fault="client";constructor(e){super({name:"ExpiredTokenException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}},Fl=class t extends rr{static shapeId="com.amazonaws.sts#MalformedPolicyDocumentException";name="MalformedPolicyDocumentException";$fault="client";constructor(e){super({name:"MalformedPolicyDocumentException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}},Ul=class t extends rr{static shapeId="com.amazonaws.sts#PackedPolicyTooLargeException";name="PackedPolicyTooLargeException";$fault="client";constructor(e){super({name:"PackedPolicyTooLargeException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}},Bl=class t extends rr{static shapeId="com.amazonaws.sts#RegionDisabledException";name="RegionDisabledException";$fault="client";constructor(e){super({name:"RegionDisabledException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}},Gl=class t extends rr{static shapeId="com.amazonaws.sts#IDPRejectedClaimException";name="IDPRejectedClaimException";$fault="client";constructor(e){super({name:"IDPRejectedClaimException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}},Hl=class t extends rr{static shapeId="com.amazonaws.sts#InvalidIdentityTokenException";name="InvalidIdentityTokenException";$fault="client";constructor(e){super({name:"InvalidIdentityTokenException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}},Vl=class t extends rr{static shapeId="com.amazonaws.sts#IDPCommunicationErrorException";name="IDPCommunicationErrorException";$fault="client";$retryable={};constructor(e){super({name:"IDPCommunicationErrorException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}}});var Tse,Ase,Ise,xse,Cse,bse,Bx,wse,Dse,Ose,vse,Gx,Pse,UU,Nse,kse,Mse,Lse,$se,Fse,Use,Bse,BU,GU,HU,Gse,Hse,Vse,Wse,zse,jse,VU,qse,Kse,WU,Yse,zU,Qse,Jse,Hx,Xse,Zse,jU,qU,eoe,toe,roe,noe,soe,ooe,ioe,aoe,yi,_i,coe,Ri,Ti,Ai,uoe,KU,loe,we,YU,QU,wo,JU,XU,ZU,e3,t3,r3,n3,Vx,doe,poe,Wx,s3,o3,i3,a3,zx,c3,u3,l3,d3,foe,moe,jx,qx,Wl=f(()=>{K();Ux();pg();Tse="Arn",Ase="AccessKeyId",Ise="AssumeRole",xse="AssumedRoleId",Cse="AssumeRoleRequest",bse="AssumeRoleResponse",Bx="AssumedRoleUser",wse="AssumeRoleWithWebIdentity",Dse="AssumeRoleWithWebIdentityRequest",Ose="AssumeRoleWithWebIdentityResponse",vse="Audience",Gx="Credentials",Pse="ContextAssertion",UU="DurationSeconds",Nse="Expiration",kse="ExternalId",Mse="ExpiredTokenException",Lse="IDPCommunicationErrorException",$se="IDPRejectedClaimException",Fse="InvalidIdentityTokenException",Use="Key",Bse="MalformedPolicyDocumentException",BU="MinimumSessionTokenSize",GU="Policy",HU="PolicyArns",Gse="ProviderArn",Hse="ProvidedContexts",Vse="ProvidedContextsListType",Wse="ProvidedContext",zse="PolicyDescriptorType",jse="ProviderId",VU="PackedPolicySize",qse="PackedPolicyTooLargeException",Kse="Provider",WU="RoleArn",Yse="RegionDisabledException",zU="RoleSessionName",Qse="SecretAccessKey",Jse="SubjectFromWebIdentityToken",Hx="SourceIdentity",Xse="SerialNumber",Zse="SessionToken",jU="SessionTokenSize",qU="SessionTokenUtilization",eoe="Tags",toe="TokenCode",roe="TransitiveTagKeys",noe="Tag",soe="Value",ooe="WebIdentityToken",ioe="arn",aoe="accessKeySecretType",yi="awsQueryError",_i="client",coe="clientTokenType",Ri="error",Ti="httpError",Ai="message",uoe="policyDescriptorListType",KU="smithy.ts.sdk.synthetic.com.amazonaws.sts",loe="tagListType",we="com.amazonaws.sts",YU=new ce(KU),QU=[-3,KU,"STSServiceException",0,[],[]];YU.registerError(QU,rr);wo=new ce(we),JU=[-3,we,Mse,{[yi]:["ExpiredTokenException",400],[Ri]:_i,[Ti]:400},[Ai],[0]];wo.registerError(JU,$l);XU=[-3,we,Lse,{[yi]:["IDPCommunicationError",400],[Ri]:_i,[Ti]:400},[Ai],[0]];wo.registerError(XU,Vl);ZU=[-3,we,$se,{[yi]:["IDPRejectedClaim",403],[Ri]:_i,[Ti]:403},[Ai],[0]];wo.registerError(ZU,Gl);e3=[-3,we,Fse,{[yi]:["InvalidIdentityToken",400],[Ri]:_i,[Ti]:400},[Ai],[0]];wo.registerError(e3,Hl);t3=[-3,we,Bse,{[yi]:["MalformedPolicyDocument",400],[Ri]:_i,[Ti]:400},[Ai],[0]];wo.registerError(t3,Fl);r3=[-3,we,qse,{[yi]:["PackedPolicyTooLarge",400],[Ri]:_i,[Ti]:400},[Ai],[0]];wo.registerError(r3,Ul);n3=[-3,we,Yse,{[yi]:["RegionDisabledException",403],[Ri]:_i,[Ti]:403},[Ai],[0]];wo.registerError(n3,Bl);Vx=[YU,wo],doe=[0,we,aoe,8,0],poe=[0,we,coe,8,0],Wx=[3,we,Bx,0,[xse,Tse],[0,0],2],s3=[3,we,Cse,0,[WU,zU,HU,GU,UU,eoe,roe,kse,Xse,toe,Hx,Hse,BU],[0,0,()=>d3,0,1,()=>moe,64,0,0,0,0,()=>foe,1],2],o3=[3,we,bse,0,[Gx,Bx,VU,Hx,qU,jU],[[()=>zx,0],()=>Wx,1,0,1,1]],i3=[3,we,Dse,0,[WU,zU,ooe,jse,HU,GU,UU,BU],[0,0,[()=>poe,0],0,()=>d3,0,1,1],3],a3=[3,we,Ose,0,[Gx,Jse,Bx,VU,Kse,vse,Hx,qU,jU],[[()=>zx,0],0,()=>Wx,1,0,0,0,1,1]],zx=[3,we,Gx,0,[Ase,Qse,Zse,Nse],[0,[()=>doe,0],0,4],4],c3=[3,we,zse,0,[ioe],[0]],u3=[3,we,Wse,0,[Gse,Pse],[0,0]],l3=[3,we,noe,0,[Use,soe],[0,0],2],d3=[1,we,uoe,0,()=>c3],foe=[1,we,Vse,0,()=>u3],moe=[1,we,loe,0,()=>l3],jx=[9,we,Ise,0,()=>s3,()=>o3],qx=[9,we,wse,0,()=>i3,()=>a3]});var p3,f3,m3=f(()=>{It();bo();p3=ye(Px());At();Gn();V();G();L();$x();Mx();Wl();f3=t=>({apiVersion:"2011-06-15",base64Decoder:t?.base64Decoder??Te,base64Encoder:t?.base64Encoder??ne,disableHostPrefix:t?.disableHostPrefix??!1,endpointProvider:t?.endpointProvider??dg,extensions:t?.extensions??[],httpAuthSchemeProvider:t?.httpAuthSchemeProvider??MU,httpAuthSchemes:t?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:e=>e.getIdentityProvider("aws.auth#sigv4"),signer:new pt},{schemeId:"aws.auth#sigv4a",identityProvider:e=>e.getIdentityProvider("aws.auth#sigv4a"),signer:new vs},{schemeId:"smithy.api#noAuth",identityProvider:e=>e.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new vt}],logger:t?.logger??new Qt,protocol:t?.protocol??Co,protocolSettings:t?.protocolSettings??{defaultNamespace:"com.amazonaws.sts",errorTypeRegistries:Vx,xmlNamespace:"https://sts.amazonaws.com/doc/2011-06-15/",version:"2011-06-15",serviceTarget:"AWSSecurityTokenServiceV20110615"},serviceId:t?.serviceId??"STS",sha256:t?.sha256??Yr,signerConstructor:t?.signerConstructor??p3.SignatureV4MultiRegion,urlParser:t?.urlParser??Et,utf8Decoder:t?.utf8Decoder??tt,utf8Encoder:t?.utf8Encoder??_e})});var fg,h3,g3=f(()=>{rl();ie();It();At();V();se();Zt();L();fg=ye(Ps());m3();h3=t=>{xn(process.version);let e=$n(t),r=()=>e().then(In),n=f3(t);Rn(process.version);let s={profile:t?.profile,logger:n.logger};return{...n,...t,runtime:"node",defaultsMode:e,authSchemePreference:t?.authSchemePreference??q(rn,s),bodyLengthChecker:t?.bodyLengthChecker??vn,defaultUserAgentProvider:t?.defaultUserAgentProvider??en({serviceId:n.serviceId,clientVersion:_o.version}),httpAuthSchemes:t?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:o=>o.getIdentityProvider("aws.auth#sigv4")||(async i=>await t.credentialDefaultProvider(i?.__config||{})()),signer:new pt},{schemeId:"aws.auth#sigv4a",identityProvider:o=>o.getIdentityProvider("aws.auth#sigv4a"),signer:new vs},{schemeId:"smithy.api#noAuth",identityProvider:o=>o.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new vt}],maxAttempts:t?.maxAttempts??q(Yn,t),region:t?.region??q(_t,{...Bt,...s}),requestHandler:fg.NodeHttpHandler.create(t?.requestHandler??r),retryMode:t?.retryMode??q({...Jn,default:async()=>(await r()).retryMode||xr},t),sigv4aSigningRegionSet:t?.sigv4aSigningRegionSet??q(Ku,s),streamCollector:t?.streamCollector??fg.streamCollector,useDualstackEndpoint:t?.useDualstackEndpoint??q(Mn,s),useFipsEndpoint:t?.useFipsEndpoint??q(Ln,s),userAgentAppId:t?.userAgentAppId??q(ns,s)}}});var S3,E3,y3=f(()=>{S3=t=>{let e=t.httpAuthSchemes,r=t.httpAuthSchemeProvider,n=t.credentials;return{setHttpAuthScheme(s){let o=e.findIndex(i=>i.schemeId===s.schemeId);o===-1?e.push(s):e.splice(o,1,s)},httpAuthSchemes(){return e},setHttpAuthSchemeProvider(s){r=s},httpAuthSchemeProvider(){return r},setCredentials(s){n=s},credentials(){return n}}},E3=t=>({httpAuthSchemes:t.httpAuthSchemes(),httpAuthSchemeProvider:t.httpAuthSchemeProvider(),credentials:t.credentials()})});var _3,R3=f(()=>{ie();V();G();y3();_3=(t,e)=>{let r=Object.assign(ss(t),zr(t),Hn(t),S3(t));return e.forEach(n=>n.configure(r)),Object.assign(t,os(r),Cn(r),Vn(r),E3(r))}});var Do,mg=f(()=>{ie();At();V();se();Re();G();Zt();K();$x();Fx();g3();R3();Do=class extends Dt{config;constructor(...[e]){let r=h3(e||{});super(r),this.initConfig=r;let n=$U(r),s=ts(n),o=Qn(s),i=ur(o),a=i,c=Cs(a),u=LU(c),p=_3(u,e?.extensions||[]);this.config=p,this.middlewareStack.use(Tn(this.config)),this.middlewareStack.use(rs(this.config)),this.middlewareStack.use(Os(this.config)),this.middlewareStack.use(Wn(this.config)),this.middlewareStack.use(Xn(this.config)),this.middlewareStack.use(Zn(this.config)),this.middlewareStack.use(es(this.config)),this.middlewareStack.use(Xr(this.config,{httpAuthSchemeParametersProvider:PU,identityProviderConfigProvider:async d=>new pr({"aws.auth#sigv4":d.credentials,"aws.auth#sigv4a":d.credentials})})),this.middlewareStack.use(Zr(this.config))}destroy(){super.destroy()}}});var hg,gg,Sg,Kx=f(()=>{V();Re();Fx();hg=bn(FU,"AWSSecurityTokenServiceV20110615","STSClient",bs),gg={},Sg=(t,e,r,n)=>[]});var Ii,Eg=f(()=>{Kx();Wl();Ii=class extends hg(gg,Sg,"AssumeRole",jx){}});var xi,yg=f(()=>{Kx();Wl();xi=class extends hg(gg,Sg,"AssumeRoleWithWebIdentity",qx){}});var hoe,_g,T3=f(()=>{V();Eg();yg();mg();hoe={AssumeRoleCommand:Ii,AssumeRoleWithWebIdentityCommand:xi},_g=class extends Do{};An(hoe,_g)});var A3=f(()=>{Eg();yg()});var I3=f(()=>{});var x3,C3,b3,w3,D3,O3=f(()=>{ie();Eg();yg();x3=t=>{if(typeof t?.Arn=="string"){let e=t.Arn.split(":");if(e.length>4&&e[4]!=="")return e[4]}},C3=async(t,e,r,n={})=>{let s=typeof t=="function"?await t():t,o=typeof e=="function"?await e():e,i="",a=s??o??(i=await Hm(n)());return r?.debug?.("@aws-sdk/client-sts::resolveRegion","accepting first of:",`${s} (credential provider clientConfig)`,`${o} (contextual client)`,`${i} (STS default: AWS_REGION, profile region, or us-east-1)`),a},b3=(t,e)=>{let r,n;return async(s,o)=>{if(n=s,!r){let{logger:p=t?.parentClientConfig?.logger,profile:d=t?.parentClientConfig?.profile,region:m,requestHandler:g=t?.parentClientConfig?.requestHandler,credentialProviderLogger:E,userAgentAppId:_=t?.parentClientConfig?.userAgentAppId}=t,R=await C3(m,t?.parentClientConfig?.region,E,{logger:p,profile:d}),T=!D3(g);r=new e({...t,userAgentAppId:_,profile:d,credentialDefaultProvider:()=>async()=>n,region:R,requestHandler:T?g:void 0,logger:p})}let{Credentials:i,AssumedRoleUser:a}=await r.send(new Ii(o));if(!i||!i.AccessKeyId||!i.SecretAccessKey)throw new Error(`Invalid response from STS.assumeRole call with role ${o.RoleArn}`);let c=x3(a),u={accessKeyId:i.AccessKeyId,secretAccessKey:i.SecretAccessKey,sessionToken:i.SessionToken,expiration:i.Expiration,...i.CredentialScope&&{credentialScope:i.CredentialScope},...c&&{accountId:c}};return js(u,"CREDENTIALS_STS_ASSUME_ROLE","i"),u}},w3=(t,e)=>{let r;return async n=>{if(!r){let{logger:c=t?.parentClientConfig?.logger,profile:u=t?.parentClientConfig?.profile,region:p,requestHandler:d=t?.parentClientConfig?.requestHandler,credentialProviderLogger:m,userAgentAppId:g=t?.parentClientConfig?.userAgentAppId}=t,E=await C3(p,t?.parentClientConfig?.region,m,{logger:c,profile:u}),_=!D3(d);r=new e({...t,userAgentAppId:g,profile:u,region:E,requestHandler:_?d:void 0,logger:c})}let{Credentials:s,AssumedRoleUser:o}=await r.send(new xi(n));if(!s||!s.AccessKeyId||!s.SecretAccessKey)throw new Error(`Invalid response from STS.assumeRoleWithWebIdentity call with role ${n.RoleArn}`);let i=x3(o),a={accessKeyId:s.AccessKeyId,secretAccessKey:s.SecretAccessKey,sessionToken:s.SessionToken,expiration:s.Expiration,...s.CredentialScope&&{credentialScope:s.CredentialScope},...i&&{accountId:i}};return i&&js(a,"RESOLVED_ACCOUNT_ID","T"),js(a,"CREDENTIALS_STS_ASSUME_ROLE_WEB_ID","k"),a}},D3=t=>t?.metadata?.handlerProtocol==="h2"});var v3,P3,N3,goe,k3=f(()=>{O3();mg();v3=(t,e)=>e?class extends t{constructor(n){super(n);for(let s of e)this.middlewareStack.use(s)}}:t,P3=(t={},e)=>b3(t,v3(Do,e)),N3=(t={},e)=>w3(t,v3(Do,e)),goe=t=>e=>t({roleAssumer:P3(e),roleAssumerWithWebIdentity:N3(e),...e})});var Yx={};at(Yx,{$Command:()=>Ft,AssumeRole$:()=>jx,AssumeRoleCommand:()=>Ii,AssumeRoleRequest$:()=>s3,AssumeRoleResponse$:()=>o3,AssumeRoleWithWebIdentity$:()=>qx,AssumeRoleWithWebIdentityCommand:()=>xi,AssumeRoleWithWebIdentityRequest$:()=>i3,AssumeRoleWithWebIdentityResponse$:()=>a3,AssumedRoleUser$:()=>Wx,Credentials$:()=>zx,ExpiredTokenException:()=>$l,ExpiredTokenException$:()=>JU,IDPCommunicationErrorException:()=>Vl,IDPCommunicationErrorException$:()=>XU,IDPRejectedClaimException:()=>Gl,IDPRejectedClaimException$:()=>ZU,InvalidIdentityTokenException:()=>Hl,InvalidIdentityTokenException$:()=>e3,MalformedPolicyDocumentException:()=>Fl,MalformedPolicyDocumentException$:()=>t3,PackedPolicyTooLargeException:()=>Ul,PackedPolicyTooLargeException$:()=>r3,PolicyDescriptorType$:()=>c3,ProvidedContext$:()=>u3,RegionDisabledException:()=>Bl,RegionDisabledException$:()=>n3,STS:()=>_g,STSClient:()=>Do,STSServiceException:()=>rr,STSServiceException$:()=>QU,Tag$:()=>l3,__Client:()=>Dt,decorateDefaultCredentialProvider:()=>goe,errorTypeRegistries:()=>Vx,getDefaultRoleAssumer:()=>P3,getDefaultRoleAssumerWithWebIdentity:()=>N3});var Qx=f(()=>{mg();T3();A3();V();Wl();Ux();I3();k3();pg()});function Soe(t){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"signin",region:t.region},propertiesExtractor:(e,r)=>({signingProperties:{config:e,context:r}})}}function Eoe(t){return{schemeId:"smithy.api#noAuth"}}var M3,L3,$3,Jx=f(()=>{It();V();M3=async(t,e,r)=>({operation:he(e).operation,region:await ge(t.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()});L3=t=>{let e=[];return t.operation==="CreateOAuth2Token"?e.push(Eoe(t)):e.push(Soe(t)),e},$3=t=>{let e=is(t);return Object.assign(e,{authSchemePreference:ge(t.authSchemePreference??[])})}});var F3,U3,Xx=f(()=>{F3=t=>Object.assign(t,{useDualstackEndpoint:t.useDualstackEndpoint??!1,useFipsEndpoint:t.useFipsEndpoint??!1,defaultSigningName:"signin"}),U3={UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}}});var Po,Oo,B3,gc,G3,Sc,H3,eC,ks,Zx,V3,W3,vo,K3,z3,Rg,Pt,j3,q3,yoe,ee,_oe,Y3,Q3=f(()=>{Re();Po="ref",Oo=-1,B3=!1,gc=!0,G3="isSet",Sc="booleanEquals",H3="coalesce",eC="PartitionResult",ks="stringEquals",Zx="getAttr",V3="https://signin.{Region}.{PartitionResult#dualStackDnsSuffix}",W3={[Po]:"Endpoint"},vo={fn:Zx,argv:[{[Po]:eC},"name"]},K3={[Po]:"Region"},z3={[Po]:eC},Rg={authSchemes:[{name:"sigv4",signingName:"signin",signingRegion:"{Region}"}]},Pt={},j3=[K3],q3={conditions:[[G3,j3],[Sc,[{fn:H3,argv:[{[Po]:"IsControlPlane"},B3]},gc]],[G3,[W3]],["aws.partition",j3,eC],[Sc,[{[Po]:"UseFIPS"},gc]],[ks,[vo,"aws"]],[Sc,[{fn:H3,argv:[{[Po]:"IsOAuthEndpoint"},B3]},gc]],[Sc,[{[Po]:"UseDualStack"},gc]],[ks,[vo,"aws-cn"]],[ks,[K3,"us-gov-west-1"]],[ks,[vo,"aws-us-gov"]],[Sc,[{fn:Zx,argv:[z3,"supportsFIPS"]},gc]],[ks,[vo,"aws-iso"]],[ks,[vo,"aws-iso-b"]],[ks,[vo,"aws-iso-f"]],[ks,[vo,"aws-iso-e"]],[ks,[vo,"aws-eusc"]],[Sc,[{fn:Zx,argv:[z3,"supportsDualStack"]},gc]]],results:[[Oo],["https://signin.{Region}.api.aws",Rg],["https://signin.{Region}.api.amazonwebservices.com.cn",Rg],[V3,Rg],[Oo,"FIPS endpoints are not supported for OAuth operations. Disable FIPS or use a non-OAuth operation."],["https://{Region}.oauth.signin.aws",Rg],["https://{Region}.signin.aws.amazon.com",Pt],["https://{Region}.signin.amazonaws.cn",Pt],["https://{Region}.signin.amazonaws-us-gov.com",Pt],["https://{Region}.signin.c2shome.ic.gov",Pt],["https://{Region}.signin.sc2shome.sgov.gov",Pt],["https://{Region}.signin.csphome.hci.ic.gov",Pt],["https://{Region}.signin.csphome.adc-e.uk",Pt],["https://{Region}.signin.amazonaws-eusc.eu",Pt],["https://signin-fips.amazonaws-us-gov.com",Pt],["https://{Region}.signin-fips.amazonaws-us-gov.com",Pt],["https://{Region}.signin.{PartitionResult#dnsSuffix}",Pt],[Oo,"Invalid Configuration: FIPS and custom endpoint are not supported"],[Oo,"Invalid Configuration: Dualstack and custom endpoint are not supported"],[W3,Pt],["https://signin-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",Pt],[Oo,"FIPS and DualStack are enabled, but this partition does not support one or both"],["https://signin-fips.{Region}.{PartitionResult#dnsSuffix}",Pt],[Oo,"FIPS is enabled but this partition does not support FIPS"],[V3,Pt],[Oo,"DualStack is enabled but this partition does not support DualStack"],["https://signin.{Region}.{PartitionResult#dnsSuffix}",Pt],[Oo,"Invalid Configuration: Missing Region"]]},yoe=2,ee=1e8,_oe=new Int32Array([-1,1,-1,0,6,3,2,36,4,4,5,ee+27,6,ee+4,ee+27,1,29,7,2,36,8,3,9,31,4,22,10,5,19,11,7,21,12,8,ee+7,13,10,ee+8,14,12,ee+9,15,13,ee+10,16,14,ee+11,17,15,ee+12,18,16,ee+13,ee+16,6,ee+5,20,7,21,ee+6,17,ee+24,ee+25,6,ee+4,23,7,27,24,9,ee+14,25,10,ee+15,26,11,ee+22,ee+23,11,28,ee+21,17,ee+20,ee+21,2,35,30,3,39,31,4,32,ee+27,6,ee+4,33,7,ee+27,34,9,ee+14,ee+27,3,39,36,4,38,37,7,ee+18,ee+19,6,ee+4,ee+17,5,ee+1,40,8,ee+2,ee+3]),Y3=Tr.from(_oe,yoe,q3.conditions,q3.results)});var Roe,J3,X3=f(()=>{ie();Re();Q3();Roe=new Ar({size:50,params:["Endpoint","IsControlPlane","IsOAuthEndpoint","Region","UseDualStack","UseFIPS"]}),J3=(t,e={})=>Roe.get(t,()=>Un(Y3,{endpointParams:t,logger:e.logger}));Jt.aws=tn});var dn,Tg=f(()=>{V();dn=class t extends yr{static shapeId="smithy.ts.sdk.synthetic.com.amazonaws.signin#SigninServiceException";constructor(e){super(e),Object.setPrototypeOf(this,t.prototype)}}});var zl,jl,ql,Kl,tC=f(()=>{Tg();zl=class t extends dn{static shapeId="com.amazonaws.signin#AccessDeniedException";name="AccessDeniedException";$fault="client";error;constructor(e){super({name:"AccessDeniedException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.error=e.error}},jl=class t extends dn{static shapeId="com.amazonaws.signin#InternalServerException";name="InternalServerException";$fault="server";error;constructor(e){super({name:"InternalServerException",$fault:"server",...e}),Object.setPrototypeOf(this,t.prototype),this.error=e.error}},ql=class t extends dn{static shapeId="com.amazonaws.signin#TooManyRequestsError";name="TooManyRequestsError";$fault="client";error;constructor(e){super({name:"TooManyRequestsError",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.error=e.error}},Kl=class t extends dn{static shapeId="com.amazonaws.signin#ValidationException";name="ValidationException";$fault="client";error;constructor(e){super({name:"ValidationException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.error=e.error}}});var Toe,Aoe,Ioe,xoe,Coe,boe,woe,Doe,Ooe,voe,Poe,Noe,koe,Moe,Loe,Z3,rC,$oe,iC,e2,t2,Foe,No,nC,Uoe,sC,Boe,i2,aC,r2,wt,Ig,Goe,Ag,n2,a2,s2,o2,Hoe,Voe,Woe,oC,zoe,Nt,c2,u2,Yl,l2,d2,p2,f2,cC,joe,m2,h2,g2,S2,E2,y2,_2,R2,uC,lC,Ql=f(()=>{K();tC();Tg();Toe="AccessDeniedException",Aoe="AccessToken",Ioe="CreateOAuth2Token",xoe="CreateOAuth2TokenRequest",Coe="CreateOAuth2TokenRequestBody",boe="CreateOAuth2TokenResponseBody",woe="CreateOAuth2TokenResponse",Doe="CreateOAuth2TokenWithIAM",Ooe="CreateOAuth2TokenWithIAMRequest",voe="CreateOAuth2TokenWithIAMResponse",Poe="InternalServerException",Noe="OAuthAccessToken",koe="RefreshToken",Moe="TooManyRequestsError",Loe="ValidationException",Z3="accessKeyId",rC="accessToken",$oe="access_token",iC="client",e2="clientId",t2="codeVerifier",Foe="code",No="error",nC="expiresIn",Uoe="expires_in",sC="grantType",Boe="grant_type",i2="http",aC="httpError",r2="idToken",wt="jsonName",Ig="message",Goe="resource",Ag="refreshToken",n2="redirectUri",a2="smithy.ts.sdk.synthetic.com.amazonaws.signin",s2="secretAccessKey",o2="sessionToken",Hoe="server",Voe="tokenInput",Woe="tokenOutput",oC="tokenType",zoe="token_type",Nt="com.amazonaws.signin",c2=new ce(a2),u2=[-3,a2,"SigninServiceException",0,[],[]];c2.registerError(u2,dn);Yl=new ce(Nt),l2=[-3,Nt,Toe,{[No]:iC},[No,Ig],[0,0],2];Yl.registerError(l2,zl);d2=[-3,Nt,Poe,{[No]:Hoe,[aC]:500},[No,Ig],[0,0],2];Yl.registerError(d2,jl);p2=[-3,Nt,Moe,{[No]:iC,[aC]:429},[No,Ig],[0,0],2];Yl.registerError(p2,ql);f2=[-3,Nt,Loe,{[No]:iC,[aC]:400},[No,Ig],[0,0],2];Yl.registerError(f2,Kl);cC=[c2,Yl],joe=[0,Nt,Noe,8,0],m2=[0,Nt,koe,8,0],h2=[3,Nt,Aoe,8,[Z3,s2,o2],[[0,{[wt]:Z3}],[0,{[wt]:s2}],[0,{[wt]:o2}]],3],g2=[3,Nt,xoe,0,[Voe],[[()=>S2,16]],1],S2=[3,Nt,Coe,0,[e2,sC,Foe,n2,t2,Ag],[[0,{[wt]:e2}],[0,{[wt]:sC}],0,[0,{[wt]:n2}],[0,{[wt]:t2}],[()=>m2,{[wt]:Ag}]],2],E2=[3,Nt,woe,0,[Woe],[[()=>y2,16]],1],y2=[3,Nt,boe,0,[rC,oC,nC,Ag,r2],[[()=>h2,{[wt]:rC}],[0,{[wt]:oC}],[1,{[wt]:nC}],[()=>m2,{[wt]:Ag}],[0,{[wt]:r2}]],4],_2=[3,Nt,Ooe,0,[sC,Goe],[[0,{[wt]:Boe}],0],2],R2=[3,Nt,voe,0,[rC,oC,nC],[[()=>joe,{[wt]:$oe}],[0,{[wt]:zoe}],[1,{[wt]:Uoe}]],3],uC=[9,Nt,Ioe,{[i2]:["POST","/v1/token",200]},()=>g2,()=>E2],lC=[9,Nt,Doe,{[i2]:["POST","/v1/token?x-amz-client-auth-method=iam",200]},()=>_2,()=>R2]});var T2,A2=f(()=>{It();bo();At();Gn();V();G();L();Jx();X3();Ql();T2=t=>({apiVersion:"2023-01-01",base64Decoder:t?.base64Decoder??Te,base64Encoder:t?.base64Encoder??ne,disableHostPrefix:t?.disableHostPrefix??!1,endpointProvider:t?.endpointProvider??J3,extensions:t?.extensions??[],httpAuthSchemeProvider:t?.httpAuthSchemeProvider??L3,httpAuthSchemes:t?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:e=>e.getIdentityProvider("aws.auth#sigv4"),signer:new pt},{schemeId:"smithy.api#noAuth",identityProvider:e=>e.getIdentityProvider("smithy.api#noAuth")||(async()=>({})),signer:new vt}],logger:t?.logger??new Qt,protocol:t?.protocol??us,protocolSettings:t?.protocolSettings??{defaultNamespace:"com.amazonaws.signin",errorTypeRegistries:cC,version:"2023-01-01",serviceTarget:"Signin"},serviceId:t?.serviceId??"Signin",sha256:t?.sha256??Yr,urlParser:t?.urlParser??Et,utf8Decoder:t?.utf8Decoder??tt,utf8Encoder:t?.utf8Encoder??_e})});var xg,I2,x2=f(()=>{rl();ie();It();V();se();Zt();L();xg=ye(Ps());A2();I2=t=>{xn(process.version);let e=$n(t),r=()=>e().then(In),n=T2(t);Rn(process.version);let s={profile:t?.profile,logger:n.logger};return{...n,...t,runtime:"node",defaultsMode:e,authSchemePreference:t?.authSchemePreference??q(rn,s),bodyLengthChecker:t?.bodyLengthChecker??vn,defaultUserAgentProvider:t?.defaultUserAgentProvider??en({serviceId:n.serviceId,clientVersion:_o.version}),maxAttempts:t?.maxAttempts??q(Yn,t),region:t?.region??q(_t,{...Bt,...s}),requestHandler:xg.NodeHttpHandler.create(t?.requestHandler??r),retryMode:t?.retryMode??q({...Jn,default:async()=>(await r()).retryMode||xr},t),streamCollector:t?.streamCollector??xg.streamCollector,useDualstackEndpoint:t?.useDualstackEndpoint??q(Mn,s),useFipsEndpoint:t?.useFipsEndpoint??q(Ln,s),userAgentAppId:t?.userAgentAppId??q(ns,s)}}});var C2,b2,w2=f(()=>{C2=t=>{let e=t.httpAuthSchemes,r=t.httpAuthSchemeProvider,n=t.credentials;return{setHttpAuthScheme(s){let o=e.findIndex(i=>i.schemeId===s.schemeId);o===-1?e.push(s):e.splice(o,1,s)},httpAuthSchemes(){return e},setHttpAuthSchemeProvider(s){r=s},httpAuthSchemeProvider(){return r},setCredentials(s){n=s},credentials(){return n}}},b2=t=>({httpAuthSchemes:t.httpAuthSchemes(),httpAuthSchemeProvider:t.httpAuthSchemeProvider(),credentials:t.credentials()})});var D2,O2=f(()=>{ie();V();G();w2();D2=(t,e)=>{let r=Object.assign(ss(t),zr(t),Hn(t),C2(t));return e.forEach(n=>n.configure(r)),Object.assign(t,os(r),Cn(r),Vn(r),b2(r))}});var Jl,dC=f(()=>{ie();At();V();se();Re();G();Zt();K();Jx();Xx();x2();O2();Jl=class extends Dt{config;constructor(...[e]){let r=I2(e||{});super(r),this.initConfig=r;let n=F3(r),s=ts(n),o=Qn(s),i=ur(o),a=i,c=Cs(a),u=$3(c),p=D2(u,e?.extensions||[]);this.config=p,this.middlewareStack.use(Tn(this.config)),this.middlewareStack.use(rs(this.config)),this.middlewareStack.use(Os(this.config)),this.middlewareStack.use(Wn(this.config)),this.middlewareStack.use(Xn(this.config)),this.middlewareStack.use(Zn(this.config)),this.middlewareStack.use(es(this.config)),this.middlewareStack.use(Xr(this.config,{httpAuthSchemeParametersProvider:M3,identityProviderConfigProvider:async d=>new pr({"aws.auth#sigv4":d.credentials})})),this.middlewareStack.use(Zr(this.config))}destroy(){super.destroy()}}});var Cg,v2,P2,bg,pC=f(()=>{V();Re();Xx();Cg=bn(U3,"Signin","SigninClient",bs),v2={IsControlPlane:{type:"staticContextParams",value:!1}},P2={IsOAuthEndpoint:{type:"staticContextParams",value:!0}},bg=(t,e,r,n)=>[]});var Xl,fC=f(()=>{pC();Ql();Xl=class extends Cg(v2,bg,"CreateOAuth2Token",uC){}});var Zl,mC=f(()=>{pC();Ql();Zl=class extends Cg(P2,bg,"CreateOAuth2TokenWithIAM",lC){}});var qoe,wg,N2=f(()=>{V();fC();mC();dC();qoe={CreateOAuth2TokenCommand:Xl,CreateOAuth2TokenWithIAMCommand:Zl},wg=class extends Jl{};An(qoe,wg)});var k2=f(()=>{fC();mC()});var Koe,M2=f(()=>{Koe={AUTHCODE_EXPIRED:"AUTHCODE_EXPIRED",CONFLICT:"CONFLICT",INSUFFICIENT_PERMISSIONS:"INSUFFICIENT_PERMISSIONS",INVALID_REQUEST:"INVALID_REQUEST",RESOURCE_NOT_FOUND:"RESOURCE_NOT_FOUND",SERVER_ERROR:"server_error",SERVICE_QUOTA_EXCEEDED:"SERVICE_QUOTA_EXCEEDED",TOKEN_EXPIRED:"TOKEN_EXPIRED",USER_CREDENTIALS_CHANGED:"USER_CREDENTIALS_CHANGED"}});var L2=f(()=>{});var $2={};at($2,{$Command:()=>Ft,AccessDeniedException:()=>zl,AccessDeniedException$:()=>l2,AccessToken$:()=>h2,CreateOAuth2Token$:()=>uC,CreateOAuth2TokenCommand:()=>Xl,CreateOAuth2TokenRequest$:()=>g2,CreateOAuth2TokenRequestBody$:()=>S2,CreateOAuth2TokenResponse$:()=>E2,CreateOAuth2TokenResponseBody$:()=>y2,CreateOAuth2TokenWithIAM$:()=>lC,CreateOAuth2TokenWithIAMCommand:()=>Zl,CreateOAuth2TokenWithIAMRequest$:()=>_2,CreateOAuth2TokenWithIAMResponse$:()=>R2,InternalServerException:()=>jl,InternalServerException$:()=>d2,OAuth2ErrorCode:()=>Koe,Signin:()=>wg,SigninClient:()=>Jl,SigninServiceException:()=>dn,SigninServiceException$:()=>u2,TooManyRequestsError:()=>ql,TooManyRequestsError$:()=>p2,ValidationException:()=>Kl,ValidationException$:()=>f2,__Client:()=>Dt,errorTypeRegistries:()=>cC});var F2=f(()=>{dC();N2();k2();V();Ql();M2();tC();L2();Tg()});var G2=Ne(B2=>{var{setCredentialFeature:Yoe}=(ie(),O(wr)),{CredentialsProviderError:ko,parseKnownFiles:Qoe,getProfileName:Joe}=(se(),O(Gt)),{HttpRequest:Xoe}=(G(),O(qn)),{createHash:Zoe,createPrivateKey:eie,createPublicKey:tie,sign:rie}=require("node:crypto"),{promises:hC}=require("node:fs"),{homedir:nie}=require("node:os"),{dirname:sie,join:U2}=require("node:path"),gC=class t{profileData;init;callerClientConfig;static REFRESH_THRESHOLD=300*1e3;constructor(e,r,n){this.profileData=e,this.init=r,this.callerClientConfig=n}async loadCredentials(){let e=await this.loadToken();if(!e)throw new ko(`Failed to load a token for session ${this.loginSession}, please re-authenticate using aws login`,{tryNextLink:!1,logger:this.logger});let r=e.accessToken,n=Date.now();return new Date(r.expiresAt).getTime()-n<=t.REFRESH_THRESHOLD?this.refresh(e):this.toCredentials(e.accessToken)}get logger(){return this.init?.logger}get loginSession(){return this.profileData.login_session}toCredentials(e){return{accessKeyId:e.accessKeyId,secretAccessKey:e.secretAccessKey,sessionToken:e.sessionToken,accountId:e.accountId,expiration:new Date(e.expiresAt)}}async refresh(e){let r=await this.loadToken().catch(()=>e),n=Date.now(),s=new Date(r.accessToken.expiresAt).getTime(),o=new Date(e.accessToken.expiresAt).getTime(),i=s<=n&&o>n?e:r;if(new Date(i.accessToken.expiresAt).getTime()-Date.now()>t.REFRESH_THRESHOLD)return this.toCredentials(i.accessToken);let{SigninClient:c,CreateOAuth2TokenCommand:u}=(F2(),O($2)),{logger:p,userAgentAppId:d}=this.callerClientConfig??{},g=(T=>T?.metadata?.handlerProtocol==="h2")(this.callerClientConfig?.requestHandler)?void 0:this.callerClientConfig?.requestHandler,E=this.profileData.region??await this.callerClientConfig?.region?.()??process.env.AWS_REGION,_=new c({credentials:{accessKeyId:"",secretAccessKey:""},region:E,requestHandler:g,logger:p,userAgentAppId:d,...this.init?.clientConfig});this.createDPoPInterceptor(_.middlewareStack);let R={tokenInput:{clientId:i.clientId,refreshToken:i.refreshToken,grantType:"refresh_token"}};try{let T=await _.send(new u(R)),{accessKeyId:I,secretAccessKey:P,sessionToken:v}=T.tokenOutput?.accessToken??{},{refreshToken:Z,expiresIn:Pe}=T.tokenOutput??{};if(!I||!P||!v||!Z)throw new ko("Token refresh response missing required fields",{logger:this.logger,tryNextLink:!1});let be=(Pe??900)*1e3,Ie=new Date(Date.now()+be),Me={...i,accessToken:{...i.accessToken,accessKeyId:I,secretAccessKey:P,sessionToken:v,expiresAt:Ie.toISOString()},refreshToken:Z};return await this.saveToken(Me),this.toCredentials(Me.accessToken)}catch(T){if(T.name==="AccessDeniedException"){let P=T.error,v;switch(P){case"TOKEN_EXPIRED":v="Your session has expired. Please reauthenticate.";break;case"USER_CREDENTIALS_CHANGED":v="Unable to refresh credentials because of a change in your password. Please reauthenticate with your new password.";break;case"INSUFFICIENT_PERMISSIONS":v="Unable to refresh credentials due to insufficient permissions. You may be missing permission for the 'CreateOAuth2Token' action.";break;default:v=`Failed to refresh token: ${String(T)}. Please re-authenticate using \`aws login\``}throw new ko(v,{logger:this.logger,tryNextLink:!1})}if(new Date(i.accessToken.expiresAt).getTime()>Date.now())return this.logger?.warn?.(`Failed to refresh token: ${String(T)}. Using existing token until expiry.`),this.toCredentials(i.accessToken);throw new ko(`Failed to refresh token: ${String(T)}. Please re-authenticate using aws login`,{logger:this.logger})}}async loadToken(){let e=this.getTokenFilePath();try{let r=await hC.readFile(e,"utf8"),n=JSON.parse(r),s=["accessToken","clientId","refreshToken","dpopKey"].filter(o=>!n[o]);if(n.accessToken?.accountId||s.push("accountId"),s.length>0)throw new ko(`Token validation failed, missing fields: ${s.join(", ")}`,{logger:this.logger,tryNextLink:!1});return n}catch(r){throw new ko(`Failed to load token from ${e}: ${String(r)}`,{logger:this.logger,tryNextLink:!1})}}async saveToken(e){let r=this.getTokenFilePath(),n=sie(r);try{await hC.mkdir(n,{recursive:!0})}catch{}await hC.writeFile(r,JSON.stringify(e,null,2),"utf8")}getTokenFilePath(){let e=process.env.AWS_LOGIN_CACHE_DIRECTORY??U2(nie(),".aws","login","cache"),r=Buffer.from(this.loginSession,"utf8"),n=Zoe("sha256").update(r).digest("hex");return U2(e,`${n}.json`)}derToRawSignature(e){let r=2;if(e[r]!==2)throw new Error("Invalid DER signature");r++;let n=e[r++],s=e.subarray(r,r+n);if(r+=n,e[r]!==2)throw new Error("Invalid DER signature");r++;let o=e[r++],i=e.subarray(r,r+o);s=s[0]===0?s.subarray(1):s,i=i[0]===0?i.subarray(1):i;let a=Buffer.concat([Buffer.alloc(32-s.length),s]),c=Buffer.concat([Buffer.alloc(32-i.length),i]);return Buffer.concat([a,c])}createDPoPInterceptor(e){e.add(r=>async n=>{if(Xoe.isInstance(n.request)){let s=n.request,o=`${s.protocol}//${s.hostname}${s.port?`:${s.port}`:""}${s.path}`,i=await this.generateDpop(s.method,o);s.headers={...s.headers,DPoP:i}}return r(n)},{step:"finalizeRequest",name:"dpopInterceptor",override:!0})}async generateDpop(e="POST",r){let n=await this.loadToken();try{let s=eie({key:n.dpopKey,format:"pem",type:"sec1"}),i=tie(s).export({format:"der",type:"spki"}),a=-1;for(let I=0;I<i.length;I++)if(i[I]===4){a=I;break}let c=i.slice(a+1,a+33),u=i.slice(a+33,a+65),p={alg:"ES256",typ:"dpop+jwt",jwk:{kty:"EC",crv:"P-256",x:c.toString("base64url"),y:u.toString("base64url")}},d={jti:crypto.randomUUID(),htm:e,htu:r,iat:Math.floor(Date.now()/1e3)},m=Buffer.from(JSON.stringify(p)).toString("base64url"),g=Buffer.from(JSON.stringify(d)).toString("base64url"),E=`${m}.${g}`,_=rie("sha256",Buffer.from(E),s),T=this.derToRawSignature(_).toString("base64url");return`${E}.${T}`}catch(s){throw new ko(`Failed to generate Dpop proof: ${s instanceof Error?s.message:String(s)}`,{logger:this.logger,tryNextLink:!1})}}},oie=t=>async({callerClientConfig:e}={})=>{t?.logger?.debug?.("@aws-sdk/credential-providers - fromLoginCredentials");let r=await Qoe(t||{}),n=Joe({profile:t?.profile??e?.profile}),s=r[n];if(!s?.login_session)throw new ko(`Profile ${n} does not contain login_session.`,{tryNextLink:!0,logger:t?.logger});let i=await new gC(s,t,e).loadCredentials();return Yoe(i,"CREDENTIALS_LOGIN","AD")};B2.fromLoginCredentials=oie});var EC=Ne(H2=>{var{externalDataInterceptor:iie,CredentialsProviderError:SC,parseKnownFiles:aie,getProfileName:cie}=(se(),O(Gt)),{exec:uie}=require("node:child_process"),{promisify:lie}=require("node:util"),{setCredentialFeature:die}=(ie(),O(wr)),pie=(t,e,r)=>{if(e.Version!==1)throw Error(`Profile ${t} credential_process did not return Version 1.`);if(e.AccessKeyId===void 0||e.SecretAccessKey===void 0)throw Error(`Profile ${t} credential_process returned invalid credentials.`);if(e.Expiration){let o=new Date;if(new Date(e.Expiration)<o)throw Error(`Profile ${t} credential_process returned expired credentials.`)}let n=e.AccountId;!n&&r?.[t]?.aws_account_id&&(n=r[t].aws_account_id);let s={accessKeyId:e.AccessKeyId,secretAccessKey:e.SecretAccessKey,...e.SessionToken&&{sessionToken:e.SessionToken},...e.Expiration&&{expiration:new Date(e.Expiration)},...e.CredentialScope&&{credentialScope:e.CredentialScope},...n&&{accountId:n}};return die(s,"CREDENTIALS_PROCESS","w"),s},fie=async(t,e,r)=>{let n=e[t];if(e[t]){let s=n.credential_process;if(s!==void 0){let o=lie(iie?.getTokenRecord?.().exec??uie);try{let{stdout:i}=await o(s),a;try{a=JSON.parse(i.trim())}catch{throw Error(`Profile ${t} credential_process returned invalid JSON.`)}return pie(t,a,e)}catch(i){throw new SC(i.message,{logger:r})}}else throw new SC(`Profile ${t} did not contain credential_process.`,{logger:r})}else throw new SC(`Profile ${t} could not be found in shared credentials file.`,{logger:r})},mie=(t={})=>async({callerClientConfig:e}={})=>{t.logger?.debug("@aws-sdk/credential-provider-process - fromProcess");let r=await aie(t);return fie(cie({profile:t.profile??e?.profile}),r,t.logger)};H2.fromProcess=mie});var _C=Ne(yC=>{var{setCredentialFeature:hie}=(ie(),O(wr)),{CredentialsProviderError:gie,externalDataInterceptor:Sie}=(se(),O(Gt)),{readFileSync:Eie}=require("node:fs"),W2=t=>async e=>{t.logger?.debug("@aws-sdk/credential-provider-web-identity - fromWebToken");let{roleArn:r,roleSessionName:n,webIdentityToken:s,providerId:o,policyArns:i,policy:a,durationSeconds:c}=t,{roleAssumerWithWebIdentity:u}=t;if(!u){let{getDefaultRoleAssumerWithWebIdentity:p}=(Qx(),O(Yx));u=p({...t.clientConfig,credentialProviderLogger:t.logger,parentClientConfig:{...e?.callerClientConfig,...t.parentClientConfig}},t.clientPlugins)}return u({RoleArn:r,RoleSessionName:n??`aws-sdk-js-session-${Date.now()}`,WebIdentityToken:s,ProviderId:o,PolicyArns:i,Policy:a,DurationSeconds:c})},V2="AWS_WEB_IDENTITY_TOKEN_FILE",yie="AWS_ROLE_ARN",_ie="AWS_ROLE_SESSION_NAME",Rie=(t={})=>async e=>{t.logger?.debug("@aws-sdk/credential-provider-web-identity - fromTokenFile");let r=t?.webIdentityTokenFile??process.env[V2],n=t?.roleArn??process.env[yie],s=t?.roleSessionName??process.env[_ie];if(!r||!n)throw new gie("Web identity configuration not specified",{logger:t.logger});let o=await W2({...t,webIdentityToken:Sie?.getTokenRecord?.()[r]??Eie(r,{encoding:"ascii"}),roleArn:n,roleSessionName:s})(e);return r===process.env[V2]&&hie(o,"CREDENTIALS_ENV_VARS_STS_WEB_ID_TOKEN","h"),o};yC.fromTokenFile=Rie;yC.fromWebToken=W2});var J2=Ne(Q2=>{var{CredentialsProviderError:Dg,chain:Tie,getProfileName:K2,parseKnownFiles:Aie}=(se(),O(Gt)),{setCredentialFeature:Ms}=(ie(),O(wr)),Iie=(t,e,r)=>{let n={EcsContainer:async s=>{let{fromHttp:o}=AI(),{fromContainerMetadata:i}=th();return r?.debug("@aws-sdk/credential-provider-ini - credential_source is EcsContainer"),async()=>Tie(o(s??{}),i(s))().then(RC)},Ec2InstanceMetadata:async s=>{r?.debug("@aws-sdk/credential-provider-ini - credential_source is Ec2InstanceMetadata");let{fromInstanceMetadata:o}=th();return async()=>o(s)().then(RC)},Environment:async s=>{r?.debug("@aws-sdk/credential-provider-ini - credential_source is Environment");let{fromEnv:o}=lI();return async()=>o(s)().then(RC)}};if(t in n)return n[t];throw new Dg(`Unsupported credential source in profile ${e}. Got ${t}, expected EcsContainer or Ec2InstanceMetadata or Environment.`,{logger:r})},RC=t=>Ms(t,"CREDENTIALS_PROFILE_NAMED_PROVIDER","p"),xie=(t,{profile:e="default",logger:r}={})=>!!t&&typeof t=="object"&&typeof t.role_arn=="string"&&["undefined","string"].indexOf(typeof t.role_session_name)>-1&&["undefined","string"].indexOf(typeof t.external_id)>-1&&["undefined","string"].indexOf(typeof t.mfa_serial)>-1&&(Cie(t,{profile:e,logger:r})||bie(t,{profile:e,logger:r})),Cie=(t,{profile:e,logger:r})=>{let n=typeof t.source_profile=="string"&&typeof t.credential_source>"u";return n&&r?.debug?.(` ${e} isAssumeRoleWithSourceProfile source_profile=${t.source_profile}`),n},bie=(t,{profile:e,logger:r})=>{let n=typeof t.credential_source=="string"&&typeof t.source_profile>"u";return n&&r?.debug?.(` ${e} isCredentialSourceProfile credential_source=${t.credential_source}`),n},wie=async(t,e,r,n,s={},o)=>{r.logger?.debug("@aws-sdk/credential-provider-ini - resolveAssumeRoleCredentials (STS)");let i=e[t],{source_profile:a,region:c}=i;if(!r.roleAssumer){let{getDefaultRoleAssumer:p}=(Qx(),O(Yx));r.roleAssumer=p({...r.clientConfig,credentialProviderLogger:r.logger,parentClientConfig:{...n,...r?.parentClientConfig,region:c??r?.parentClientConfig?.region??n?.region}},r.clientPlugins)}if(a&&a in s)throw new Dg(`Detected a cycle attempting to resolve credentials for profile ${K2(r)}. Profiles visited: `+Object.keys(s).join(", "),{logger:r.logger});r.logger?.debug(`@aws-sdk/credential-provider-ini - finding credential resolver using ${a?`source_profile=[${a}]`:`profile=[${t}]`}`);let u=a?o(a,e,r,n,{...s,[a]:!0},z2(e[a]??{})):(await Iie(i.credential_source,t,r.logger)(r))();if(z2(i))return u.then(p=>Ms(p,"CREDENTIALS_PROFILE_SOURCE_PROFILE","o"));{let p={RoleArn:i.role_arn,RoleSessionName:i.role_session_name||`aws-sdk-js-${Date.now()}`,ExternalId:i.external_id,DurationSeconds:parseInt(i.duration_seconds||"3600",10)},{mfa_serial:d}=i;if(d){if(!r.mfaCodeProvider)throw new Dg(`Profile ${t} requires multi-factor authentication, but no MFA code callback was provided.`,{logger:r.logger,tryNextLink:!1});p.SerialNumber=d,p.TokenCode=await r.mfaCodeProvider(d)}let m=await u;return r.roleAssumer(m,p).then(g=>Ms(g,"CREDENTIALS_PROFILE_SOURCE_PROFILE","o"))}},z2=t=>!t.role_arn&&!!t.credential_source,Die=t=>!!(t&&t.login_session),Oie=async(t,e,r)=>{let{fromLoginCredentials:n}=G2(),s=await n({...e,profile:t})({callerClientConfig:r});return Ms(s,"CREDENTIALS_PROFILE_LOGIN","AC")},vie=t=>!!t&&typeof t=="object"&&typeof t.credential_process=="string",Pie=async(t,e)=>{let{fromProcess:r}=EC(),n=await r({...t,profile:e})();return Ms(n,"CREDENTIALS_PROFILE_PROCESS","v")},Nie=async(t,e,r={},n)=>{let{fromSSO:s}=Dx();return s({profile:t,logger:r.logger,parentClientConfig:r.parentClientConfig,clientConfig:r.clientConfig})({callerClientConfig:n}).then(o=>e.sso_session?Ms(o,"CREDENTIALS_PROFILE_SSO","r"):Ms(o,"CREDENTIALS_PROFILE_SSO_LEGACY","t"))},kie=t=>t&&(typeof t.sso_start_url=="string"||typeof t.sso_account_id=="string"||typeof t.sso_session=="string"||typeof t.sso_region=="string"||typeof t.sso_role_name=="string"),j2=t=>!!t&&typeof t=="object"&&typeof t.aws_access_key_id=="string"&&typeof t.aws_secret_access_key=="string"&&["undefined","string"].indexOf(typeof t.aws_session_token)>-1&&["undefined","string"].indexOf(typeof t.aws_account_id)>-1,q2=async(t,e)=>{e?.logger?.debug("@aws-sdk/credential-provider-ini - resolveStaticCredentials");let r={accessKeyId:t.aws_access_key_id,secretAccessKey:t.aws_secret_access_key,sessionToken:t.aws_session_token,...t.aws_credential_scope&&{credentialScope:t.aws_credential_scope},...t.aws_account_id&&{accountId:t.aws_account_id}};return Ms(r,"CREDENTIALS_PROFILE","n")},Mie=t=>!!t&&typeof t=="object"&&typeof t.web_identity_token_file=="string"&&typeof t.role_arn=="string"&&["undefined","string"].indexOf(typeof t.role_session_name)>-1,Lie=async(t,e,r)=>{let{fromTokenFile:n}=_C(),s=await n({webIdentityTokenFile:t.web_identity_token_file,roleArn:t.role_arn,roleSessionName:t.role_session_name,roleAssumerWithWebIdentity:e.roleAssumerWithWebIdentity,logger:e.logger,parentClientConfig:e.parentClientConfig})({callerClientConfig:r});return Ms(s,"CREDENTIALS_PROFILE_STS_WEB_ID_TOKEN","q")},Y2=async(t,e,r,n,s={},o=!1)=>{let i=e[t];if(Object.keys(s).length>0&&j2(i))return q2(i,r);if(o||xie(i,{profile:t,logger:r.logger}))return wie(t,e,r,n,s,Y2);if(j2(i))return q2(i,r);if(Mie(i))return Lie(i,r,n);if(vie(i))return Pie(r,t);if(kie(i))return await Nie(t,i,r,n);if(Die(i))return Oie(t,r,n);throw new Dg(`Could not resolve credentials using profile: [${t}] in configuration/credentials file(s).`,{logger:r.logger})},$ie=(t={})=>async({callerClientConfig:e}={})=>{t.logger?.debug("@aws-sdk/credential-provider-ini - fromIni");let r=await Aie(t);return Y2(K2({profile:t.profile??e?.profile}),r,t,e)};Q2.fromIni=$ie});var Pg=Ne(vg=>{var{ENV_KEY:Fie,ENV_SECRET:Uie,fromEnv:Bie}=lI(),{chain:Gie,CredentialsProviderError:Og,ENV_PROFILE:Hie}=(se(),O(Gt)),X2="AWS_EC2_METADATA_DISABLED",Vie=async t=>{let{ENV_CMDS_FULL_URI:e,ENV_CMDS_RELATIVE_URI:r,fromContainerMetadata:n,fromInstanceMetadata:s}=th();if(process.env[r]||process.env[e]){t.logger?.debug("@aws-sdk/credential-provider-node - remoteProvider::fromHttp/fromContainerMetadata");let{fromHttp:o}=AI();return Gie(o(t),n(t))}return process.env[X2]&&process.env[X2]!=="false"?async()=>{throw new Og("EC2 Instance Metadata Service access disabled",{logger:t.logger})}:(t.logger?.debug("@aws-sdk/credential-provider-node - remoteProvider::fromInstanceMetadata"),s(t))};function Wie(t,e){let r=zie(t),n,s,o,i,a=async c=>{if(c?.forceRefresh)return i||(i=r(c).then(u=>{o=u}).finally(()=>{i=void 0})),await i,o;if(o?.expiration&&o?.expiration?.getTime()<Date.now()&&(o=void 0),n)await n;else if(!o||e?.(o))if(o)s||(s=r(c).then(u=>{o=u}).catch(()=>{}).finally(()=>{s=void 0}));else return n=r(c).then(u=>{o=u}).finally(()=>{n=void 0}),a(c);return o};return a}var zie=t=>async e=>{let r;for(let n of t)try{return await n(e)}catch(s){if(r=s,s?.tryNextLink)continue;throw s}throw r},Z2=!1,jie=(t={})=>Wie([async()=>{if(t.profile??process.env[Hie])throw process.env[Fie]&&process.env[Uie]&&(Z2||((t.logger?.warn&&t.logger?.constructor?.name!=="NoOpLogger"?t.logger.warn.bind(t.logger):console.warn)(`@aws-sdk/credential-provider-node - defaultProvider::fromEnv WARNING:
51
+ Multiple credential sources detected:
52
+ Both AWS_PROFILE and the pair AWS_ACCESS_KEY_ID/AWS_SECRET_ACCESS_KEY static credentials are set.
53
+ This SDK will proceed with the AWS_PROFILE value.
54
+
55
+ However, a future version may change this behavior to prefer the ENV static credentials.
56
+ Please ensure that your environment only sets either the AWS_PROFILE or the
57
+ AWS_ACCESS_KEY_ID/AWS_SECRET_ACCESS_KEY pair.
58
+ `),Z2=!0)),new Og("AWS_PROFILE is set, skipping fromEnv provider.",{logger:t.logger,tryNextLink:!0});return t.logger?.debug("@aws-sdk/credential-provider-node - defaultProvider::fromEnv"),Bie(t)()},async e=>{t.logger?.debug("@aws-sdk/credential-provider-node - defaultProvider::fromSSO");let{ssoStartUrl:r,ssoAccountId:n,ssoRegion:s,ssoRoleName:o,ssoSession:i}=t;if(!r&&!n&&!s&&!o&&!i)throw new Og("Skipping SSO provider in default chain (inputs do not include SSO fields).",{logger:t.logger});let{fromSSO:a}=Dx();return a(t)(e)},async e=>{t.logger?.debug("@aws-sdk/credential-provider-node - defaultProvider::fromIni");let{fromIni:r}=J2();return r(t)(e)},async e=>{t.logger?.debug("@aws-sdk/credential-provider-node - defaultProvider::fromProcess");let{fromProcess:r}=EC();return r(t)(e)},async e=>{t.logger?.debug("@aws-sdk/credential-provider-node - defaultProvider::fromTokenFile");let{fromTokenFile:r}=_C();return r(t)(e)},async()=>(t.logger?.debug("@aws-sdk/credential-provider-node - defaultProvider::remoteProvider"),(await Vie(t))()),async()=>{throw new Og("Could not load credentials from any providers",{tryNextLink:!1,logger:t.logger})}],e4),qie=t=>t?.expiration!==void 0,e4=t=>t?.expiration!==void 0&&t.expiration.getTime()-Date.now()<3e5;vg.credentialsTreatedAsExpired=e4;vg.credentialsWillNeedRefresh=qie;vg.defaultProvider=jie});var Nq=Ne(l=>{var{awsEndpointFunctions:Kie,emitWarningIfUnsupportedVersion:Yie,createDefaultUserAgentProvider:Qie,NODE_APP_ID_CONFIG_OPTIONS:Jie,getAwsRegionExtensionConfiguration:Xie,resolveAwsRegionExtensionConfiguration:Zie,resolveUserAgentConfig:eae,resolveHostHeaderConfig:tae,getUserAgentPlugin:rae,getHostHeaderPlugin:nae,getLoggerPlugin:sae,getRecursionDetectionPlugin:oae}=(ie(),O(wr)),{getHttpAuthSchemeEndpointRuleSetPlugin:iae,DefaultIdentityProviderConfig:aae,getHttpSigningPlugin:cae,createPaginator:De}=(At(),O(Bu)),{normalizeProvider:o4,getSmithyContext:uae,ServiceException:lae,NoOpLogger:dae,emitWarningIfUnsupportedVersion:pae,loadConfigsForDefaultMode:fae,getDefaultExtensionConfiguration:mae,resolveDefaultRuntimeConfig:hae,Client:i4,makeBuilder:gae,createWaiter:je,checkExceptions:ds,WaiterState:N,createAggregatedClient:Sae}=(V(),O(Ts)),{Command:Eae}=(V(),O(Ts));l.$Command=Eae;l.__Client=i4;var{resolveDefaultsModeConfig:yae,loadConfig:Ci,NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS:_ae,NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS:Rae,NODE_REGION_CONFIG_OPTIONS:Tae,NODE_REGION_CONFIG_FILE_OPTIONS:Aae,resolveRegionConfig:Iae}=(se(),O(Gt)),{BinaryDecisionDiagram:xae,EndpointCache:Cae,decideEndpoint:bae,customEndpointFunctions:wae,resolveEndpointConfig:Dae,getEndpointPlugin:Oae}=(Re(),O(Cf)),{parseUrl:vae,getHttpHandlerExtensionConfiguration:Pae,resolveHttpHandlerRuntimeConfig:Nae,getContentLengthPlugin:kae}=(G(),O(qn)),{DEFAULT_RETRY_MODE:Mae,NODE_RETRY_MODE_CONFIG_OPTIONS:Lae,NODE_MAX_ATTEMPT_CONFIG_OPTIONS:$ae,resolveRetryConfig:Fae,getRetryPlugin:Uae}=(Zt(),O(xm)),{TypeRegistry:a4,getSchemaSerdePlugin:Bae}=(K(),O(Ip)),{resolveAwsSdkSigV4Config:Gae,AwsSdkSigV4Signer:Hae,NODE_AUTH_SCHEME_PREFERENCE_OPTIONS:Vae}=(It(),O(Qu)),{defaultProvider:Wae}=Pg(),{toUtf8:zae,fromUtf8:jae,toBase64:qae,fromBase64:Kae,calculateBodyLength:Yae}=(L(),O(Bn)),{streamCollector:Qae,NodeHttpHandler:Jae}=Ps(),{AwsQueryProtocol:Xae}=(bo(),O(zh)),{Sha256:Zae}=(Gn(),O(Hf)),ece=async(t,e,r)=>({operation:uae(e).operation,region:await o4(t.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()});function tce(t){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"cloudformation",region:t.region},propertiesExtractor:(e,r)=>({signingProperties:{config:e,context:r}})}}var rce=t=>{let e=[];switch(t.operation){default:e.push(tce(t))}return e},nce=t=>{let e=Gae(t);return Object.assign(e,{authSchemePreference:o4(t.authSchemePreference??[])})},sce=t=>Object.assign(t,{useDualstackEndpoint:t.useDualstackEndpoint??!1,useFipsEndpoint:t.useFipsEndpoint??!1,defaultSigningName:"cloudformation"}),oce={UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}},ice="3.1151.0",ace={version:ice},ed="ref",bi=-1,Ng=!0,t4="isSet",c4="PartitionResult",kg="booleanEquals",TC="getAttr",r4={[ed]:"Endpoint"},AC={[ed]:c4},Ec={},n4=[{[ed]:"Region"}],s4={conditions:[[t4,[r4]],[t4,n4],["aws.partition",n4,c4],[kg,[{[ed]:"UseFIPS"},Ng]],[kg,[{[ed]:"UseDualStack"},Ng]],[kg,[{fn:TC,argv:[AC,"supportsDualStack"]},Ng]],[kg,[{fn:TC,argv:[AC,"supportsFIPS"]},Ng]],["stringEquals",[{fn:TC,argv:[AC,"name"]},"aws-us-gov"]]],results:[[bi],[bi,"Invalid Configuration: FIPS and custom endpoint are not supported"],[bi,"Invalid Configuration: Dualstack and custom endpoint are not supported"],[r4,Ec],["https://cloudformation-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",Ec],[bi,"FIPS and DualStack are enabled, but this partition does not support one or both"],["https://cloudformation.{Region}.amazonaws.com",Ec],["https://cloudformation-fips.{Region}.{PartitionResult#dnsSuffix}",Ec],[bi,"FIPS is enabled but this partition does not support FIPS"],["https://cloudformation.{Region}.{PartitionResult#dualStackDnsSuffix}",Ec],[bi,"DualStack is enabled but this partition does not support DualStack"],["https://cloudformation.{Region}.{PartitionResult#dnsSuffix}",Ec],[bi,"Invalid Configuration: Missing Region"]]},cce=2,nr=1e8,uce=new Int32Array([-1,1,-1,0,13,3,1,4,nr+12,2,5,nr+12,3,8,6,4,7,nr+11,5,nr+9,nr+10,4,11,9,6,10,nr+8,7,nr+6,nr+7,5,12,nr+5,6,nr+4,nr+5,3,nr+1,14,4,nr+2,nr+3]),lce=xae.from(uce,cce,s4.conditions,s4.results),dce=new Cae({size:50,params:["Endpoint","Region","UseDualStack","UseFIPS"]}),pce=(t,e={})=>dce.get(t,()=>bae(lce,{endpointParams:t,logger:e.logger}));wae.aws=Kie;var re=class t extends lae{static shapeId="smithy.ts.sdk.synthetic.com.amazonaws.cloudformation#CloudFormationServiceException";constructor(e){super(e),Object.setPrototypeOf(this,t.prototype)}},Mg=class t extends re{static shapeId="com.amazonaws.cloudformation#InvalidOperationException";name="InvalidOperationException";$fault="client";Message;constructor(e){super({name:"InvalidOperationException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},Lg=class t extends re{static shapeId="com.amazonaws.cloudformation#OperationNotFoundException";name="OperationNotFoundException";$fault="client";Message;constructor(e){super({name:"OperationNotFoundException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},$g=class t extends re{static shapeId="com.amazonaws.cloudformation#CFNRegistryException";name="CFNRegistryException";$fault="client";Message;constructor(e){super({name:"CFNRegistryException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},Fg=class t extends re{static shapeId="com.amazonaws.cloudformation#TypeNotFoundException";name="TypeNotFoundException";$fault="client";Message;constructor(e){super({name:"TypeNotFoundException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},Ug=class t extends re{static shapeId="com.amazonaws.cloudformation#AlreadyExistsException";name="AlreadyExistsException";$fault="client";Message;constructor(e){super({name:"AlreadyExistsException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},Bg=class t extends re{static shapeId="com.amazonaws.cloudformation#TypeConfigurationNotFoundException";name="TypeConfigurationNotFoundException";$fault="client";Message;constructor(e){super({name:"TypeConfigurationNotFoundException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},Gg=class t extends re{static shapeId="com.amazonaws.cloudformation#TokenAlreadyExistsException";name="TokenAlreadyExistsException";$fault="client";Message;constructor(e){super({name:"TokenAlreadyExistsException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},Hg=class t extends re{static shapeId="com.amazonaws.cloudformation#ChangeSetNotFoundException";name="ChangeSetNotFoundException";$fault="client";Message;constructor(e){super({name:"ChangeSetNotFoundException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},Vg=class t extends re{static shapeId="com.amazonaws.cloudformation#InsufficientCapabilitiesException";name="InsufficientCapabilitiesException";$fault="client";Message;constructor(e){super({name:"InsufficientCapabilitiesException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},Wg=class t extends re{static shapeId="com.amazonaws.cloudformation#LimitExceededException";name="LimitExceededException";$fault="client";Message;constructor(e){super({name:"LimitExceededException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},zg=class t extends re{static shapeId="com.amazonaws.cloudformation#ConcurrentResourcesLimitExceededException";name="ConcurrentResourcesLimitExceededException";$fault="client";Message;constructor(e){super({name:"ConcurrentResourcesLimitExceededException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},jg=class t extends re{static shapeId="com.amazonaws.cloudformation#OperationIdAlreadyExistsException";name="OperationIdAlreadyExistsException";$fault="client";Message;constructor(e){super({name:"OperationIdAlreadyExistsException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},qg=class t extends re{static shapeId="com.amazonaws.cloudformation#OperationInProgressException";name="OperationInProgressException";$fault="client";Message;constructor(e){super({name:"OperationInProgressException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},Kg=class t extends re{static shapeId="com.amazonaws.cloudformation#StackSetNotFoundException";name="StackSetNotFoundException";$fault="client";Message;constructor(e){super({name:"StackSetNotFoundException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},Yg=class t extends re{static shapeId="com.amazonaws.cloudformation#StaleRequestException";name="StaleRequestException";$fault="client";Message;constructor(e){super({name:"StaleRequestException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},Qg=class t extends re{static shapeId="com.amazonaws.cloudformation#CreatedButModifiedException";name="CreatedButModifiedException";$fault="client";Message;constructor(e){super({name:"CreatedButModifiedException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},Jg=class t extends re{static shapeId="com.amazonaws.cloudformation#NameAlreadyExistsException";name="NameAlreadyExistsException";$fault="client";Message;constructor(e){super({name:"NameAlreadyExistsException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},Xg=class t extends re{static shapeId="com.amazonaws.cloudformation#InvalidChangeSetStatusException";name="InvalidChangeSetStatusException";$fault="client";Message;constructor(e){super({name:"InvalidChangeSetStatusException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},Zg=class t extends re{static shapeId="com.amazonaws.cloudformation#GeneratedTemplateNotFoundException";name="GeneratedTemplateNotFoundException";$fault="client";Message;constructor(e){super({name:"GeneratedTemplateNotFoundException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},eS=class t extends re{static shapeId="com.amazonaws.cloudformation#StackSetNotEmptyException";name="StackSetNotEmptyException";$fault="client";Message;constructor(e){super({name:"StackSetNotEmptyException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},tS=class t extends re{static shapeId="com.amazonaws.cloudformation#ResourceScanNotFoundException";name="ResourceScanNotFoundException";$fault="client";Message;constructor(e){super({name:"ResourceScanNotFoundException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},rS=class t extends re{static shapeId="com.amazonaws.cloudformation#StackInstanceNotFoundException";name="StackInstanceNotFoundException";$fault="client";Message;constructor(e){super({name:"StackInstanceNotFoundException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},nS=class t extends re{static shapeId="com.amazonaws.cloudformation#StackRefactorNotFoundException";name="StackRefactorNotFoundException";$fault="client";Message;constructor(e){super({name:"StackRefactorNotFoundException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},sS=class t extends re{static shapeId="com.amazonaws.cloudformation#HookResultNotFoundException";name="HookResultNotFoundException";$fault="client";Message;constructor(e){super({name:"HookResultNotFoundException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},oS=class t extends re{static shapeId="com.amazonaws.cloudformation#StackNotFoundException";name="StackNotFoundException";$fault="client";Message;constructor(e){super({name:"StackNotFoundException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},iS=class t extends re{static shapeId="com.amazonaws.cloudformation#ResourceScanInProgressException";name="ResourceScanInProgressException";$fault="client";Message;constructor(e){super({name:"ResourceScanInProgressException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},aS=class t extends re{static shapeId="com.amazonaws.cloudformation#InvalidStateTransitionException";name="InvalidStateTransitionException";$fault="client";Message;constructor(e){super({name:"InvalidStateTransitionException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},cS=class t extends re{static shapeId="com.amazonaws.cloudformation#OperationStatusCheckFailedException";name="OperationStatusCheckFailedException";$fault="client";Message;constructor(e){super({name:"OperationStatusCheckFailedException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},uS=class t extends re{static shapeId="com.amazonaws.cloudformation#ResourceScanLimitExceededException";name="ResourceScanLimitExceededException";$fault="client";Message;constructor(e){super({name:"ResourceScanLimitExceededException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},kr="Arn",fce="AfterContext",mce="AttributeChangeType",Id="AutoDeployment",hce="AlreadyExistsException",gce="AccountFilterType",u4="AccountGateResult",Sce="AccountLimit",Ece="AccountLimitList",yce="AccountLimits",_ce="AnnotationList",Rce="AnnotationName",Tce="ActivateOrganizationsAccess",Ace="ActivateOrganizationsAccessInput",Ice="ActivateOrganizationsAccessOutput",xce="ActualProperties",Cce="AddResources",RE="AdministrationRoleARN",bce="ActivateType",wce="AcceptTermsAndConditions",Dce="ActivateTypeInput",Oce="ActivateTypeOutput",l4="AutoUpdate",vce="AccountsUrl",d4="ActualValue",Pce="AfterValueFrom",Nce="AfterValue",kce="AllowedValues",xd="Accounts",xC="Account",Cd="Action",Mce="Active",Lce="Alias",$ce="Annotation",Fce="Annotations",Uce="Attribute",Bce="BeforeContext",Gce="BatchDescribeTypeConfigurations",Hce="BatchDescribeTypeConfigurationsError",Vce="BatchDescribeTypeConfigurationsErrors",Wce="BatchDescribeTypeConfigurationsInput",zce="BatchDescribeTypeConfigurationsOutput",jce="BearerToken",qce="BeforeValue",Kce="BeforeValueFrom",Yce="Change",qe="CallAs",Qce="ConnectionArn",Jce="ConfigurationAlias",Xce="ConfigurationArn",Zce="CreatedButModifiedException",eue="CreateChangeSet",tue="CreateChangeSetInput",rue="CreateChangeSetOutput",nue="CausingEntity",sue="CFNRegistryException",oue="CreateGeneratedTemplate",iue="CreateGeneratedTemplateInput",aue="CreateGeneratedTemplateOutput",cue="ConcurrencyMode",uue="CurrentOperationStatus",p4="CapabilitiesReason",lue="ConcurrentResourcesLimitExceededException",mr="ClientRequestToken",due="ConfigurationSchema",pue="ChangeSetHook",fue="ChangeSetHookResourceTargetDetails",mue="ChangeSetHookTargetDetails",hue="ChangeSetHooks",bd="ChangeSetId",gue="CreateStackInstancesInput",Sue="CreateStackInstancesOutput",Eue="CreateStackInput",yue="CreateStackInstances",ps="ChangeSetName",_ue="ChangeSetNotFoundException",Rue="CreateStackOutput",Tue="CreateStackRefactor",Aue="CreateStackRefactorInput",Iue="CreateStackRefactorOutput",xue="ChangeSetSummary",Cue="CreateStackSetInput",bue="CreateStackSetOutput",wue="ChangeSetSummaries",Due="CreateStackSet",Oue="ChangeSetType",vue="ChangeSource",Pue="CreateStack",Rc="CreationTime",Nue="ClientToken",f4="CreationTimestamp",kue="ContinueUpdateRollback",Mue="ContinueUpdateRollbackInput",Lue="ContinueUpdateRollbackOutput",$ue="CancelUpdateStack",Fue="CancelUpdateStackInput",fs="Capabilities",Uue="Category",m4="Changes",h4="Configuration",Oe="Description",Bue="DescribeAccountLimits",Gue="DescribeAccountLimitsInput",Hue="DescribeAccountLimitsOutput",Mo="DeploymentConfig",Vue="DeleteChangeSet",Wue="DescribeChangeSetHooks",zue="DescribeChangeSetHooksInput",jue="DescribeChangeSetHooksOutput",que="DeleteChangeSetInput",Kue="DescribeChangeSetInput",Yue="DeleteChangeSetOutput",Que="DescribeChangeSetOutput",Jue="DescribeChangeSet",Xue="DriftDetectionStatus",Zue="DriftDetectionTimestamp",ele="DescribeEvents",tle="DescribeEventsInput",rle="DescribeEventsOutput",nle="DeleteGeneratedTemplate",sle="DeleteGeneratedTemplateInput",ole="DescribeGeneratedTemplateInput",ile="DescribeGeneratedTemplateOutput",ale="DescribeGeneratedTemplate",wd="DriftInformation",g4="DeploymentMode",S4="DeletionMode",cle="DependsOn",ule="DeactivateOrganizationsAccess",lle="DeactivateOrganizationsAccessInput",dle="DescribeOrganizationsAccessInput",ple="DeactivateOrganizationsAccessOutput",fle="DescribeOrganizationsAccessOutput",mle="DescribeOrganizationsAccess",hle="DeletionPolicy",gle="DescribePublisherInput",Sle="DescribePublisherOutput",Ele="DescribePublisher",Dd="DisableRollback",yle="DescribeResourceScan",_le="DescribeResourceScanInput",Rle="DescribeResourceScanOutput",Tle="DetectionReason",Ale="DetectionStatus",Ile="DetectStackDrift",xle="DescribeStackDriftDetectionStatus",Cle="DescribeStackDriftDetectionStatusInput",ble="DescribeStackDriftDetectionStatusOutput",wle="DetectStackDriftInput",Dle="DetectStackDriftOutput",Ole="DescribeStackEvents",vle="DescribeStackEventsInput",Ple="DescribeStackEventsOutput",Nle="DeleteStackInput",kle="DriftedStackInstancesCount",Mle="DeleteStackInstancesInput",Lle="DescribeStackInstanceInput",$le="DeleteStackInstancesOutput",Fle="DescribeStackInstanceOutput",Ule="DescribeStacksInput",Ble="DeleteStackInstances",Gle="DescribeStackInstance",Hle="DescribeStacksOutput",Vle="DetectionStatusReason",Wle="DriftedStackResourceCount",zle="DescribeStackResourceDrifts",jle="DescribeStackResourceDriftsInput",qle="DetectStackResourceDriftInput",Kle="DescribeStackResourceDriftsOutput",Yle="DetectStackResourceDriftOutput",Qle="DetectStackResourceDrift",Jle="DescribeStackRefactorInput",Xle="DescribeStackResourceInput",Zle="DescribeStackResourcesInput",ede="DescribeStackRefactorOutput",tde="DescribeStackResourceOutput",rde="DescribeStackResourcesOutput",nde="DescribeStackRefactor",sde="DescribeStackResource",ode="DescribeStackResources",ide="DriftStatusReason",ade="DeleteStackSet",cde="DetectStackSetDrift",ude="DetectStackSetDriftInput",lde="DetectStackSetDriftOutput",dde="DeleteStackSetInput",pde="DescribeStackSetInput",fde="DeleteStackSetOutput",mde="DescribeStackSetOperationInput",hde="DescribeStackSetOperationOutput",gde="DescribeStackSetOutput",Sde="DescribeStackSetOperation",Ede="DescribeStackSet",CC="DeprecatedStatus",yde="DeleteStack",_de="DescribeStacks",TE="DetailedStatus",AE="DriftStatus",Tc="DeploymentTargets",Rde="DeactivateTypeInput",Tde="DeregisterTypeInput",Ade="DescribeTypeInput",Ide="DeactivateTypeOutput",xde="DeregisterTypeOutput",Cde="DescribeTypeOutput",bde="DescribeTypeRegistration",wde="DescribeTypeRegistrationInput",Dde="DescribeTypeRegistrationOutput",E4="DeclaredTransforms",Ode="DeactivateType",y4="DeletionTime",vde="DeregisterType",Pde="DescribeType",Nde="DifferenceType",kde="DocumentationUrl",bC="DisableValidation",_4="DefaultVersionId",R4="DefaultValue",Mde="Details",Lde="Destination",$de="Detection",Fde="Drift",Ude="Enabled",T4="ErrorCode",Bde="ExecuteChangeSet",Gde="ExecuteChangeSetInput",Hde="ExecuteChangeSetOutput",Vde="EventFilter",A4="EventId",Wde="ErrorMessage",I4="ExportName",zde="ExpectedProperties",wC="ExecutionRoleArn",IE="ExecutionRoleName",xE="ExecutionStatus",jde="EnableStackCreation",qde="ExecutionStatusFilter",Kde="ExportingStackId",x4="ExecutionStatusReason",Yde="ExecuteStackRefactorInput",Qde="ExecuteStackRefactor",DC="EndTime",Jde="EstimateTemplateCost",Xde="EstimateTemplateCostInput",Zde="EstimateTemplateCostOutput",OC="EnableTerminationProtection",C4="EndTimestamp",epe="EventType",tpe="ExpectedValue",rpe="Entity",npe="Errors",spe="Evaluation",ope="Export",b4="Exports",CE="Filters",ipe="FailedEvents",vC="FailureMode",ape="ForceRollback",w4="FailedStackInstancesCount",cpe="FailureToleranceCount",upe="FailureTolerancePercentage",lpe="Format",dpe="GetGeneratedTemplate",ppe="GetGeneratedTemplateInput",fpe="GetGeneratedTemplateOutput",mpe="GetHookResult",hpe="GetHookResultInput",gpe="GetHookResultOutput",Spe="GetStackPolicy",Epe="GetStackPolicyInput",ype="GetStackPolicyOutput",_pe="GetTemplate",bE="GeneratedTemplateId",Rpe="GetTemplateInput",wi="GeneratedTemplateName",Tpe="GeneratedTemplateNotFoundException",Ape="GetTemplateOutput",Ipe="GetTemplateSummary",xpe="GetTemplateSummaryInput",Cpe="GetTemplateSummaryOutput",bpe="Hooks",wpe="HookExecutionTarget",D4="HookFailureMode",Dpe="HookInvocationCount",Ope="HookInvocationId",O4="HookInvocationPoint",vpe="HookResults",PC="HookResultId",Ppe="HookResultNotFoundException",Npe="HookResultSummary",kpe="HookResultSummaries",v4="HookStatus",wE="HookStatusReason",Mpe="HookTarget",P4="HookType",Lpe="Id",N4="IsActivated",k4="InvokedAt",$pe="InsufficientCapabilitiesException",Fpe="InvalidChangeSetStatusException",Upe="IsDefaultConfiguration",M4="IsDefaultVersion",NC="ImportExistingResources",kC="IncludeNestedStacks",Bpe="InvalidOperationException",MC="InvocationPoint",Gpe="InProgressStackInstancesCount",Hpe="IncludePropertyValues",Vpe="IdentityProvider",Wpe="InSyncStackInstancesCount",zpe="InvalidStateTransitionException",jpe="ImportStacksToStackSet",qpe="ImportStacksToStackSetInput",Kpe="ImportStacksToStackSetOutput",Ype="Imports",L4="Key",DE="LoggingConfig",Qpe="ListChangeSets",Jpe="ListChangeSetsInput",Xpe="ListChangeSetsOutput",OE="LastCheckTimestamp",Zpe="LogDeliveryBucket",vE="LastDriftCheckTimestamp",efe="ListExports",tfe="LimitExceededException",rfe="ListExportsInput",nfe="ListExportsOutput",sfe="LogGroupName",ofe="ListGeneratedTemplates",ife="ListGeneratedTemplatesInput",afe="ListGeneratedTemplatesOutput",cfe="ListHookResults",ufe="ListHookResultsInput",lfe="ListHookResultsOutput",dfe="ListImports",pfe="LogicalIdHierarchy",ffe="ListImportsInput",mfe="ListImportsOutput",LC="LastOperations",$4="LastOperationId",F4="LatestPublicVersion",hfe="LogRoleArn",gfe="LiveResourceDrift",gt="LogicalResourceId",U4="LogicalResourceIds",Sfe="ListResourceScans",Efe="ListResourceScansInput",yfe="ListResourceScansOutput",_fe="ListResourceScanResources",Rfe="ListResourceScanResourcesInput",Tfe="ListResourceScanResourcesOutput",Afe="ListResourceScanRelatedResources",Ife="ListResourceScanRelatedResourcesInput",xfe="ListResourceScanRelatedResourcesOutput",Cfe="ListStacks",bfe="ListStacksInput",wfe="ListStackInstancesInput",Dfe="ListStackInstancesOutput",Ofe="ListStackInstanceResourceDrifts",vfe="ListStackInstanceResourceDriftsInput",Pfe="ListStackInstanceResourceDriftsOutput",Nfe="ListStackInstances",kfe="ListStacksOutput",Mfe="ListStackRefactors",Lfe="ListStackRefactorActions",$fe="ListStackRefactorActionsInput",Ffe="ListStackRefactorActionsOutput",Ufe="ListStackRefactorsInput",Bfe="ListStackResourcesInput",Gfe="ListStackRefactorsOutput",Hfe="ListStackResourcesOutput",Vfe="ListStackResources",Wfe="ListStackSets",zfe="ListStackSetAutoDeploymentTargets",jfe="ListStackSetAutoDeploymentTargetsInput",qfe="ListStackSetAutoDeploymentTargetsOutput",Kfe="ListStackSetsInput",Yfe="ListStackSetsOutput",Qfe="ListStackSetOperationsInput",Jfe="ListStackSetOperationsOutput",Xfe="ListStackSetOperationResults",Zfe="ListStackSetOperationResultsInput",eme="ListStackSetOperationResultsOutput",tme="ListStackSetOperations",rme="ListTypes",nme="ListTypesInput",sme="ListTypesOutput",ome="ListTypeRegistrations",ime="ListTypeRegistrationsInput",ame="ListTypeRegistrationsOutput",cme="ListTypeVersions",ume="ListTypeVersionsInput",lme="ListTypeVersionsOutput",$C="LastUpdated",PE="LastUpdatedTime",B4="LastUpdatedTimestamp",le="Message",dme="ManagedByStack",pme="MaxConcurrentCount",fme="MaxConcurrentPercentage",Od="ManagedExecution",Ac="ModuleInfo",kt="MaxResults",mme="MonitoringTimeInMinutes",hme="MajorVersion",G4="Metadata",gme="Mode",vd="Name",Sme="NameAlreadyExistsException",Pd="NotificationARNs",H4="NoEcho",Eme="NewGeneratedTemplateName",yme="NumberOfResources",F="NextToken",_me="Output",V4="OperationEvents",Rme="OperationEntry",Tme="OperationEvent",Ame="OnFailure",xe="OperationId",Ime="OperationIdAlreadyExistsException",xme="OperationInProgressException",Cme="OutputKey",bme="OperationNotFoundException",Lo="OperationPreferences",wme="OperationResultFilter",Dme="OperationResultFilters",W4="OperationStatus",Ome="OperationStatusCheckFailedException",z4="OnStackFailure",j4="OperationType",vme="OriginalTypeArn",NE="OriginalTypeName",FC="OrganizationalUnitIds",kE="OrganizationalUnitId",Pme="OutputValue",q4="Outputs",Mr="Parameters",Nme="PolicyAction",K4="PercentageCompleted",Y4="ParentChangeSetId",Q4="ParameterConstraints",kme="ParameterDeclaration",Mme="PreviousDeploymentContext",Lme="ParameterDeclarations",$me="PropertyDifference",UC="PropertyDifferences",ms="PublisherId",J4="ParentId",Fme="PublisherIdentity",BC="ParameterKey",ME="PermissionModel",Ume="PublisherName",GC="ParameterOverrides",Bme="PublisherProfile",X4="PropertyPath",hs="PhysicalResourceId",HC="PhysicalResourceIdContext",Gme="PhysicalResourceIdContextKeyValuePair",Hme="PublisherStatus",Vme="ProgressStatus",Z4="ProvisioningType",eB="PublicTypeArn",Wme="PublishTypeInput",zme="PublishTypeOutput",jme="ParameterType",qme="PublishType",Kme="PreviousValue",Nd="PublicVersionNumber",Yme="ParameterValue",Qme="Parameter",tB="Path",Jme="Progress",Xme="Properties",LE="Resources",Zme="ResourceAction",ehe="RefreshAllResources",Di="RoleARN",rB="RequiredActivatedTypes",the="RequiredActivatedType",nB="ResourceChange",rhe="ResourceChangeDetail",nhe="ResourceChangeDetails",sB="RootChangeSetId",she="RegionConcurrencyType",Ic="RollbackConfiguration",ohe="ResourceDefinition",oB="ResourceDriftIgnoredAttributes",ihe="ResourceDriftIgnoredAttribute",ahe="ResourceDriftStatus",che="ResourceDetail",uhe="ResourceDefinitions",lhe="ResourceDetails",kd="RetainExceptOnCreate",dhe="ResourcesFailed",phe="RecordHandlerProgress",fhe="RecordHandlerProgressInput",mhe="RecordHandlerProgressOutput",Oi="ResourceIdentifier",iB="ResourceIdentifierSummaries",hhe="ResourceIdentifierSummary",ghe="ResourceIdentifiers",aB="RootId",She="RemediationLink",Ehe="ResourceLocation",yhe="RemediationMessage",cB="ResourceMappings",_he="ResourceModel",uB="ResourceMapping",Rhe="RegionOrder",lB="ResourceProperties",The="RegisterPublisherInput",Ahe="RegisterPublisherOutput",Ihe="ResourcesProcessing",xhe="RegisterPublisher",Che="ResourcesPending",bhe="RetainResources",whe="ResourcesRead",dB="RelatedResources",Dhe="RemoveResources",Ohe="RequiresRecreation",pB="RetainStacks",vhe="RegistrationStatusFilter",xc="ResourceScanId",Phe="ResourceScanInProgressException",Nhe="RollbackStackInput",khe="ResourceScanLimitExceededException",Mhe="ResourceScanNotFoundException",Lhe="RollbackStackOutput",$he="RetainStacksOnAccountRemoval",Cc="ResourceStatusReason",fB="ResourceScanSummaries",Fhe="ResourceScanSummary",Uhe="ResourcesScanned",bc="ResourceStatus",Bhe="ResourcesSucceeded",Ghe="RollbackStack",Vt="ResourceType",Hhe="ResourceTargetDetails",Vhe="ResourceTargetDefinition",mB="ResourcesToImport",Whe="RegisterTypeInput",zhe="ResourceToImport",jhe="RegistrationTokenList",qhe="RegisterTypeOutput",Khe="ResourceTypePrefix",Yhe="ResourcesToSkip",Md="ResourceTypes",hB="RegistrationToken",Qhe="RegisterType",gB="RollbackTriggers",Jhe="RollbackTrigger",Xhe="ResolvedValue",wc="Regions",Zhe="Reason",VC="Region",ege="Replacement",tge="Required",Ce="Status",rge="StagesAvailable",SB="StackDefinitions",WC="StackDriftDetectionId",nge="StackDriftInformation",sge="StackDriftInformationSummary",$E="StackDriftStatus",oge="StackDefinition",EB="StatusDetails",yB="StackEvents",ige="StackEvent",zC="ScanFilters",age="ScanFilter",cge="SchemaHandlerPackage",Ve="StackId",jC="StackInstanceAccount",uge="StackInstanceComprehensiveStatus",lge="StackInstanceFilter",dge="StackInstanceFilters",pge="StackInstanceNotFoundException",qC="StackInstanceRegion",fge="StackInstanceResourceDriftStatuses",mge="StackInstanceResourceDriftsSummary",hge="StackInstanceResourceDriftsSummaries",_B="StackInstanceStatus",gge="StackInstanceSummary",Sge="StackInstanceSummaries",Ege="StackIdsUrl",RB="StackInstance",TB="StackIds",yge="SeverityLevel",AB="StatusMessage",_ge="SupportedMajorVersions",X="StackName",Rge="StackNotFoundException",FE="StackPolicyBody",Tge="StackPolicyDuringUpdateBody",Age="StackPolicyDuringUpdateURL",KC="StackPolicyURL",sr="StatusReason",IB="StackRefactorActions",Ige="StackRefactorAction",xB="StackResourceDrifts",xge="StackResourceDriftInformation",Cge="StackResourceDriftInformationSummary",UE="StackResourceDriftStatus",bge="StackResourceDriftStatusFilters",CB="StackResourceDetail",bB="StackResourceDrift",wge="StaleRequestException",Dc="StackRefactorId",Dge="ScannedResourceIdentifier",Oge="ScannedResourceIdentifiers",vge="SignalResourceInput",Pge="StackRefactorNotFoundException",wB="StackRefactorSummaries",Nge="StartResourceScanInput",kge="StartResourceScanOutput",DB="StackResourceSummaries",Mge="StackRefactorSummary",Lge="StackResourceSummary",$ge="StartResourceScan",Fge="StackRefactorTagResources",Uge="ScannedResource",Bge="ScannedResources",Gge="SignalResource",OB="StackResources",Hge="StackResource",vB="StackSet",Vge="StackSetAutoDeploymentTargetSummary",Wge="StackSetAutoDeploymentTargetSummaries",zge="StackSetARN",YC="StackSetDriftDetectionDetails",jge="StackStatusFilter",Oc="StackSetId",Ke="StackSetName",qge="StackSetNotEmptyException",Kge="StackSetNotFoundException",PB="StackSetOperation",Yge="StackSetOperationPreferences",Qge="StackSetOperationResultSummary",Jge="StackSetOperationResultSummaries",Xge="StackSetOperationSummary",Zge="StackSetOperationStatusDetails",eSe="StackSetOperationSummaries",tSe="SetStackPolicy",rSe="SetStackPolicyInput",NB="StackStatusReason",nSe="StackSetSummary",sSe="StopStackSetOperation",oSe="StopStackSetOperationInput",iSe="StopStackSetOperationOutput",aSe="StackSetSummaries",kB="StackSummaries",MB="StackStatus",cSe="StackSummary",QC="StartTime",uSe="SetTypeConfiguration",lSe="SetTypeConfigurationInput",dSe="SetTypeConfigurationOutput",pSe="SetTypeDefaultVersion",fSe="SetTypeDefaultVersionInput",mSe="SetTypeDefaultVersionOutput",hSe="ScanTypeFilter",gSe="ScanType",SSe="SourceUrl",ESe="Schema",ySe="Scope",_Se="Source",LB="Stacks",RSe="Stack",$o="Summaries",nt="Type",Ls="TypeArn",TSe="TokenAlreadyExistsException",Lr="TemplateBody",ASe="TypeConfigurations",ISe="TypeConfigurationAlias",xSe="TypeConfigurationArn",CSe="TypeConfigurationDetails",bSe="TypeConfigurationDetailsList",$B="TypeConfigurationIdentifier",FB="TypeConfigurationIdentifiers",wSe="TypeConfigurationNotFoundException",JC="TypeConfigurationVersionId",BE="TemplateConfiguration",UB="TimeCreated",DSe="TargetDetails",OSe="TemplateDescription",vSe="TypeFilters",PSe="TypeHierarchy",GE="TargetId",BB="TimeoutInMinutes",NSe="TagKey",st="TypeName",GB="TypeNameAlias",kSe="TypeNotFoundException",MSe="TypeNamePrefix",LSe="TemplateParameter",$Se="TemplateProgress",FSe="TemplateParameters",USe="TagResources",BSe="TemplateStage",HB="TemplateSummaryConfig",GSe="TotalStackInstancesCount",HSe="TemplateSummary",VSe="TemplateSummaries",VB="TypeSummaries",WSe="TypeSummary",Ld="TargetType",zSe="TestTypeInput",jSe="TargetTypeName",qSe="TestTypeOutput",KSe="TypeTestsStatus",YSe="TypeTestsStatusDescription",QSe="TestType",$s="TemplateURL",JSe="TreatUnrecognizedResourceTypesAsWarnings",XSe="TagValue",WB="TypeVersionArn",XC="TypeVersionId",zB="TypeVersionSummaries",ZSe="TypeVersionSummary",eEe="TotalWarnings",Fs="Tags",tEe="Tag",jB="Target",vc="Timestamp",rEe="Types",nEe="Url",sEe="UpdateGeneratedTemplate",oEe="UpdateGeneratedTemplateInput",iEe="UpdateGeneratedTemplateOutput",aEe="UniqueId",ZC="UsePreviousTemplate",cEe="UsePreviousValue",uEe="UntagResources",lEe="UpdateReplacePolicy",dEe="UnrecognizedResourceTypes",pEe="UpdateStack",fEe="UpdateStackInput",mEe="UpdateStackInstancesInput",hEe="UpdateStackInstancesOutput",gEe="UpdateStackInstances",SEe="UpdateStackOutput",EEe="UpdateStackSet",yEe="UpdateStackSetInput",_Ee="UpdateStackSetOutput",qB="UnprocessedTypeConfigurations",REe="UpdateTerminationProtection",TEe="UpdateTerminationProtectionInput",AEe="UpdateTerminationProtectionOutput",HE="Value",IEe="VersionBump",xEe="ValidationFailureMode",$d="VersionId",CEe="ValidationName",bEe="ValidationPath",wEe="ValidationStatus",DEe="ValidationStatusReason",OEe="ValidateTemplate",vEe="ValidateTemplateInput",PEe="ValidateTemplateOutput",KB="Values",NEe="Version",YB="Visibility",eb="Warnings",kEe="WarningDetail",MEe="WarningDetails",LEe="WarningProperty",$Ee="WarningProperties",de="awsQueryError",pe="client",fe="error",me="httpError",QB="smithy.ts.sdk.synthetic.com.amazonaws.cloudformation",h="com.amazonaws.cloudformation",JB=new a4(QB),XB=[-3,QB,"CloudFormationServiceException",0,[],[]];JB.registerError(XB,re);var ae=new a4(h),ZB=[-3,h,hce,{[de]:["AlreadyExistsException",400],[fe]:pe,[me]:400},[le],[0]];ae.registerError(ZB,Ug);var eG=[-3,h,sue,{[de]:["CFNRegistryException",400],[fe]:pe,[me]:400},[le],[0]];ae.registerError(eG,$g);var tG=[-3,h,_ue,{[de]:["ChangeSetNotFound",404],[fe]:pe,[me]:404},[le],[0]];ae.registerError(tG,Hg);var rG=[-3,h,lue,{[de]:["ConcurrentResourcesLimitExceeded",429],[fe]:pe,[me]:429},[le],[0]];ae.registerError(rG,zg);var nG=[-3,h,Zce,{[de]:["CreatedButModifiedException",409],[fe]:pe,[me]:409},[le],[0]];ae.registerError(nG,Qg);var sG=[-3,h,Tpe,{[de]:["GeneratedTemplateNotFound",404],[fe]:pe,[me]:404},[le],[0]];ae.registerError(sG,Zg);var oG=[-3,h,Ppe,{[de]:["HookResultNotFound",404],[fe]:pe,[me]:404},[le],[0]];ae.registerError(oG,sS);var iG=[-3,h,$pe,{[de]:["InsufficientCapabilitiesException",400],[fe]:pe,[me]:400},[le],[0]];ae.registerError(iG,Vg);var aG=[-3,h,Fpe,{[de]:["InvalidChangeSetStatus",400],[fe]:pe,[me]:400},[le],[0]];ae.registerError(aG,Xg);var cG=[-3,h,Bpe,{[de]:["InvalidOperationException",400],[fe]:pe,[me]:400},[le],[0]];ae.registerError(cG,Mg);var uG=[-3,h,zpe,{[de]:["InvalidStateTransition",400],[fe]:pe,[me]:400},[le],[0]];ae.registerError(uG,aS);var lG=[-3,h,tfe,{[de]:["LimitExceededException",400],[fe]:pe,[me]:400},[le],[0]];ae.registerError(lG,Wg);var dG=[-3,h,Sme,{[de]:["NameAlreadyExistsException",409],[fe]:pe,[me]:409},[le],[0]];ae.registerError(dG,Jg);var pG=[-3,h,Ime,{[de]:["OperationIdAlreadyExistsException",409],[fe]:pe,[me]:409},[le],[0]];ae.registerError(pG,jg);var fG=[-3,h,xme,{[de]:["OperationInProgressException",409],[fe]:pe,[me]:409},[le],[0]];ae.registerError(fG,qg);var mG=[-3,h,bme,{[de]:["OperationNotFoundException",404],[fe]:pe,[me]:404},[le],[0]];ae.registerError(mG,Lg);var hG=[-3,h,Ome,{[de]:["ConditionalCheckFailed",400],[fe]:pe,[me]:400},[le],[0]];ae.registerError(hG,cS);var gG=[-3,h,Phe,{[de]:["ResourceScanInProgress",400],[fe]:pe,[me]:400},[le],[0]];ae.registerError(gG,iS);var SG=[-3,h,khe,{[de]:["ResourceScanLimitExceeded",400],[fe]:pe,[me]:400},[le],[0]];ae.registerError(SG,uS);var EG=[-3,h,Mhe,{[de]:["ResourceScanNotFound",400],[fe]:pe,[me]:400},[le],[0]];ae.registerError(EG,tS);var yG=[-3,h,pge,{[de]:["StackInstanceNotFoundException",404],[fe]:pe,[me]:404},[le],[0]];ae.registerError(yG,rS);var _G=[-3,h,Rge,{[de]:["StackNotFoundException",404],[fe]:pe,[me]:404},[le],[0]];ae.registerError(_G,oS);var RG=[-3,h,Pge,{[de]:["StackRefactorNotFoundException",404],[fe]:pe,[me]:404},[le],[0]];ae.registerError(RG,nS);var TG=[-3,h,qge,{[de]:["StackSetNotEmptyException",409],[fe]:pe,[me]:409},[le],[0]];ae.registerError(TG,eS);var AG=[-3,h,Kge,{[de]:["StackSetNotFoundException",404],[fe]:pe,[me]:404},[le],[0]];ae.registerError(AG,Kg);var IG=[-3,h,wge,{[de]:["StaleRequestException",409],[fe]:pe,[me]:409},[le],[0]];ae.registerError(IG,Yg);var xG=[-3,h,TSe,{[de]:["TokenAlreadyExistsException",400],[fe]:pe,[me]:400},[le],[0]];ae.registerError(xG,Gg);var CG=[-3,h,wSe,{[de]:["TypeConfigurationNotFoundException",404],[fe]:pe,[me]:404},[le],[0]];ae.registerError(CG,Bg);var bG=[-3,h,kSe,{[de]:["TypeNotFoundException",404],[fe]:pe,[me]:404},[le],[0]];ae.registerError(bG,Fg);var wG=[JB,ae],DG=[3,h,u4,0,[Ce,sr],[0,0]],OG=[3,h,Sce,0,[vd,HE],[0,1]],vG=[3,h,Ace,0,[],[]],PG=[3,h,Ice,0,[],[]],NG=[3,h,Dce,0,[nt,eB,ms,st,GB,l4,DE,wC,IEe,hme],[0,0,0,0,0,2,()=>VE,0,0,1]],kG=[3,h,Oce,0,[kr],[0]],MG=[3,h,$ce,0,[Rce,Ce,AB,yhe,She,yge],[0,0,0,0,0,0]],Fd=[3,h,Id,0,[Ude,$he,cle],[2,2,64]],LG=[3,h,Hce,0,[T4,Wde,$B],[0,0,()=>zE]],$G=[3,h,Wce,0,[FB],[()=>wye],1],FG=[3,h,zce,0,[npe,qB,ASe],[()=>BEe,()=>vye,()=>bye]],UG=[3,h,Fue,0,[X,mr],[0,0],1],BG=[3,h,Yce,0,[nt,Dpe,nB],[0,1,()=>UW]],GG=[3,h,pue,0,[MC,vC,st,XC,JC,DSe],[0,0,0,0,0,()=>VG]],HG=[3,h,fue,0,[gt,Vt,Zme],[0,0,0]],VG=[3,h,mue,0,[Ld,Hhe],[0,()=>HG]],WG=[3,h,xue,0,[Ve,X,bd,ps,xE,Ce,sr,Rc,Oe,kC,Y4,sB,NC],[0,0,0,0,0,0,0,4,0,2,0,0,2]],zG=[3,h,Mue,0,[X,Di,Yhe,mr,ape],[0,0,64,0,2],1],jG=[3,h,Lue,0,[],[]],qG=[3,h,tue,0,[X,ps,Lr,$s,ZC,Mr,fs,Md,Di,Ic,Pd,Fs,Nue,Oe,Oue,mB,kC,z4,NC,g4,Mo,bC],[0,0,0,0,2,()=>$r,64,64,0,()=>kc,64,()=>Uo,0,0,0,()=>sye,2,0,2,0,()=>Fo,2],2],KG=[3,h,rue,0,[Lpe,Ve],[0,0]],YG=[3,h,iue,0,[wi,LE,X,BE],[0,()=>oj,0,()=>WE],1],QG=[3,h,aue,0,[bE],[0]],JG=[3,h,Eue,0,[X,Lr,$s,Mr,Dd,Ic,BB,Pd,fs,Md,Di,Ame,FE,KC,Fs,mr,OC,kd,Mo,bC],[0,0,0,()=>$r,2,()=>kc,1,64,64,64,0,0,0,0,()=>Uo,0,2,2,()=>Fo,2],1],XG=[3,h,gue,0,[Ke,wc,xd,Tc,GC,Lo,xe,qe],[0,64,64,()=>Pc,()=>$r,()=>Us,[0,4],0],2],ZG=[3,h,Sue,0,[xe],[0]],eH=[3,h,Rue,0,[Ve,xe],[0,0]],tH=[3,h,Aue,0,[SB,Oe,jde,cB],[()=>cye,0,2,()=>rye],1],rH=[3,h,Iue,0,[Dc],[0],1],nH=[3,h,Cue,0,[Ke,Oe,Lr,$s,Ve,Mr,fs,Fs,RE,IE,ME,Id,qe,mr,Od],[0,0,0,0,0,()=>$r,64,()=>Uo,0,0,0,()=>Fd,0,[0,4],()=>Ud],1],sH=[3,h,bue,0,[Oc],[0]],oH=[3,h,lle,0,[],[]],iH=[3,h,ple,0,[],[]],aH=[3,h,Rde,0,[st,nt,kr],[0,0,0]],cH=[3,h,Ide,0,[],[]],uH=[3,h,que,0,[ps,X],[0,0],1],lH=[3,h,Yue,0,[],[]],dH=[3,h,sle,0,[wi],[0],1],pH=[3,h,Nle,0,[X,bhe,Di,mr,S4,Mo],[0,64,0,0,0,()=>Fo],1],fH=[3,h,Mle,0,[Ke,wc,pB,xd,Tc,Lo,xe,qe],[0,64,2,64,()=>Pc,()=>Us,[0,4],0],3],mH=[3,h,$le,0,[xe],[0]],hH=[3,h,dde,0,[Ke,qe],[0,0],1],gH=[3,h,fde,0,[],[]],Fo=[3,h,Mo,0,[gme,Dd],[0,2]],Pc=[3,h,Tc,0,[xd,vce,FC,gce],[64,0,64,0]],SH=[3,h,Tde,0,[kr,nt,st,$d],[0,0,0,0]],EH=[3,h,xde,0,[],[]],yH=[3,h,Gue,0,[F],[0]],_H=[3,h,Hue,0,[yce,F],[()=>FEe,0]],RH=[3,h,zue,0,[ps,X,F,gt],[0,0,0,0],1],TH=[3,h,jue,0,[bd,ps,bpe,Ce,F,Ve,X],[0,0,()=>HEe,0,0,0,0]],AH=[3,h,Kue,0,[ps,X,F,Hpe],[0,0,0,2],1],IH=[3,h,Que,0,[ps,bd,Ve,X,Oe,Mr,Rc,xE,Ce,sr,$E,Pd,Ic,fs,Fs,m4,F,kC,Y4,sB,z4,NC,g4,Mo],[0,0,0,0,0,()=>$r,4,0,0,0,0,64,()=>kc,64,()=>Uo,()=>GEe,0,2,0,0,0,2,0,()=>Fo]],xH=[3,h,tle,0,[X,ps,xe,CE,F],[0,0,0,()=>fV,0]],CH=[3,h,rle,0,[V4,F],[()=>jEe,0]],bH=[3,h,ole,0,[wi],[0],1],wH=[3,h,ile,0,[bE,wi,LE,Ce,sr,Rc,PE,Jme,Ve,BE,eEe],[0,0,()=>ZEe,0,0,4,4,()=>Pz,0,()=>WE,1]],DH=[3,h,dle,0,[qe],[0]],OH=[3,h,fle,0,[Ce],[0]],vH=[3,h,gle,0,[ms],[0]],PH=[3,h,Sle,0,[ms,Hme,Vpe,Bme],[0,0,0,0]],NH=[3,h,_le,0,[xc],[0],1],kH=[3,h,Rle,0,[xc,Ce,sr,QC,DC,K4,Md,Uhe,whe,zC],[0,0,0,4,4,1,64,1,1,()=>ij]],MH=[3,h,Cle,0,[WC],[0],1],LH=[3,h,ble,0,[Ve,WC,Ale,vc,$E,Vle,Wle],[0,0,0,4,0,0,1],4],$H=[3,h,vle,0,[X,F],[0,0],1],FH=[3,h,Ple,0,[yB,F],[()=>uye,0]],UH=[3,h,Lle,0,[Ke,jC,qC,qe],[0,0,0,0],3],BH=[3,h,Fle,0,[RB],[()=>lz]],GH=[3,h,Jle,0,[Dc],[0],1],HH=[3,h,ede,0,[Oe,Dc,TB,xE,x4,Ce,sr],[0,0,64,0,0,0,0]],VH=[3,h,jle,0,[X,bge,F,kt],[0,64,0,1],1],WH=[3,h,Kle,0,[xB,F],[()=>gye,0],1],zH=[3,h,Xle,0,[X,gt],[0,0],2],jH=[3,h,tde,0,[CB],[()=>Sz]],qH=[3,h,Zle,0,[X,gt,hs],[0,0,0]],KH=[3,h,rde,0,[OB],[()=>Sye]],YH=[3,h,pde,0,[Ke,qe],[0,0],1],QH=[3,h,mde,0,[Ke,xe,qe],[0,0,0],2],JH=[3,h,hde,0,[PB],[()=>Tz]],XH=[3,h,gde,0,[vB],[()=>_z]],ZH=[3,h,Ule,0,[X,F],[0,0]],eV=[3,h,Hle,0,[LB,F],[()=>yye,0]],tV=[3,h,Ade,0,[nt,st,kr,$d,ms,Nd],[0,0,0,0,0,0]],rV=[3,h,Cde,0,[kr,nt,st,_4,M4,KSe,YSe,Oe,ESe,Z4,CC,DE,rB,wC,YB,SSe,kde,$C,UB,due,ms,NE,vme,Nd,F4,N4,l4],[0,0,0,0,2,0,0,0,0,0,0,()=>VE,()=>JEe,0,0,0,0,4,4,0,0,0,0,0,0,2,2]],nV=[3,h,wde,0,[hB],[0],1],sV=[3,h,Dde,0,[Vme,Oe,Ls,WB],[0,0,0,0]],oV=[3,h,wle,0,[X,U4],[0,64],1],iV=[3,h,Dle,0,[WC],[0],1],aV=[3,h,qle,0,[X,gt],[0,0],2],cV=[3,h,Yle,0,[bB],[()=>sb],1],uV=[3,h,ude,0,[Ke,Lo,xe,qe],[0,()=>Us,[0,4],0],1],lV=[3,h,lde,0,[xe],[0]],dV=[3,h,Xde,0,[Lr,$s,Mr],[0,0,()=>$r]],pV=[3,h,Zde,0,[nEe],[0]],fV=[3,h,Vde,0,[ipe],[2]],mV=[3,h,Gde,0,[ps,X,mr,Dd,kd],[0,0,0,2,2],1],hV=[3,h,Hde,0,[],[]],gV=[3,h,Yde,0,[Dc],[0],1],SV=[3,h,ope,0,[Kde,vd,HE],[0,0,0]],EV=[3,h,ppe,0,[wi,lpe],[0,0],1],yV=[3,h,fpe,0,[Ce,Lr],[0,0]],_V=[3,h,hpe,0,[PC],[0]],RV=[3,h,gpe,0,[PC,MC,vC,st,NE,XC,JC,Ls,Ce,wE,k4,jB,Fce],[0,0,0,0,0,0,0,0,0,0,4,()=>DV,()=>UEe]],TV=[3,h,Epe,0,[X],[0],1],AV=[3,h,ype,0,[FE],[0]],IV=[3,h,Rpe,0,[X,ps,BSe],[0,0,0]],xV=[3,h,Ape,0,[Lr,rge],[0,64]],CV=[3,h,xpe,0,[Lr,$s,X,Ke,qe,HB],[0,0,0,0,0,()=>kz]],bV=[3,h,Cpe,0,[Mr,Oe,fs,p4,Md,NEe,G4,E4,iB,eb],[()=>YEe,0,64,0,64,0,0,64,()=>tye,()=>tj]],wV=[3,h,Npe,0,[PC,MC,vC,st,XC,JC,Ce,wE,k4,Ld,GE,Ls,wpe],[0,0,0,0,0,0,0,0,4,0,0,0,0]],DV=[3,h,Mpe,0,[Ld,jSe,GE,Cd],[0,0,0,0],4],OV=[3,h,qpe,0,[Ke,TB,Ege,FC,Lo,xe,qe],[0,64,0,64,()=>Us,[0,4],0],1],vV=[3,h,Kpe,0,[xe],[0]],PV=[3,h,Jpe,0,[X,F],[0,0],1],NV=[3,h,Xpe,0,[$o,F],[()=>VEe,0]],kV=[3,h,rfe,0,[F],[0]],MV=[3,h,nfe,0,[b4,F],[()=>WEe,0]],LV=[3,h,ife,0,[F,kt],[0,1]],$V=[3,h,afe,0,[$o,F],[()=>Cye,0]],FV=[3,h,ufe,0,[Ld,GE,Ls,Ce,F],[0,0,0,0,0]],UV=[3,h,lfe,0,[Ld,GE,vpe,F],[0,0,()=>zEe,0]],BV=[3,h,ffe,0,[I4,F],[0,0],1],GV=[3,h,mfe,0,[Ype,F],[64,0]],HV=[3,h,Ife,0,[xc,LE,F,kt],[0,()=>iye,0,1],2],VV=[3,h,xfe,0,[dB,F],[()=>QEe,0]],WV=[3,h,Rfe,0,[xc,Oi,Khe,NSe,XSe,F,kt],[0,0,0,0,0,0,1],1],zV=[3,h,Tfe,0,[LE,F],[()=>aye,0]],jV=[3,h,Efe,0,[F,kt,hSe],[0,1,0]],qV=[3,h,yfe,0,[fB,F],[()=>nye,0]],KV=[3,h,vfe,0,[Ke,jC,qC,xe,F,kt,fge,qe],[0,0,0,0,0,1,64,0],4],YV=[3,h,Pfe,0,[$o,F],[()=>dye,0]],QV=[3,h,wfe,0,[Ke,F,kt,CE,jC,qC,qe],[0,0,1,()=>lye,0,0,0],1],JV=[3,h,Dfe,0,[$o,F],[()=>pye,0]],XV=[3,h,$fe,0,[Dc,F,kt],[0,0,1],1],ZV=[3,h,Ffe,0,[IB,F],[()=>fye,0],1],eW=[3,h,Ufe,0,[qde,F,kt],[64,0,1]],tW=[3,h,Gfe,0,[wB,F],[()=>mye,0],1],rW=[3,h,Bfe,0,[X,F],[0,0],1],nW=[3,h,Hfe,0,[DB,F],[()=>Eye,0]],sW=[3,h,jfe,0,[Ke,F,kt,qe],[0,0,1,0],1],oW=[3,h,qfe,0,[$o,F],[()=>_ye,0]],iW=[3,h,Zfe,0,[Ke,xe,F,kt,qe,CE],[0,0,0,1,0,()=>qEe],2],aW=[3,h,eme,0,[$o,F],[()=>Rye,0]],cW=[3,h,Qfe,0,[Ke,F,kt,qe],[0,0,1,0],1],uW=[3,h,Jfe,0,[$o,F],[()=>Tye,0]],lW=[3,h,Kfe,0,[F,kt,Ce,qe],[0,1,0,0]],dW=[3,h,Yfe,0,[$o,F],[()=>Aye,0]],pW=[3,h,bfe,0,[F,jge],[0,64]],fW=[3,h,kfe,0,[kB,F],[()=>Iye,0]],mW=[3,h,ime,0,[nt,st,Ls,vhe,kt,F],[0,0,0,0,1,0]],hW=[3,h,ame,0,[jhe,F],[64,0]],gW=[3,h,nme,0,[YB,Z4,CC,nt,CE,kt,F],[0,0,0,0,()=>Fz,1,0]],SW=[3,h,sme,0,[VB,F],[()=>Dye,0]],EW=[3,h,ume,0,[nt,st,kr,kt,F,CC,ms],[0,0,0,1,0,0,0]],yW=[3,h,lme,0,[zB,F],[()=>Oye,0]],_W=[3,h,gfe,0,[Kme,d4,Zue],[0,0,4]],VE=[3,h,DE,0,[hfe,sfe],[0,0],2],Ud=[3,h,Od,0,[Mce],[2]],Nc=[3,h,Ac,0,[PSe,pfe],[0,0]],RW=[3,h,Rme,0,[j4,xe],[0,0]],TW=[3,h,Tme,0,[A4,Ve,xe,j4,W4,epe,gt,hs,Vt,vc,QC,DC,bc,Cc,lB,mr,P4,v4,wE,O4,D4,TE,xEe,CEe,wEe,DEe,bEe],[0,0,0,0,0,0,0,0,0,4,4,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]],AW=[3,h,wme,0,[vd,KB],[0,0]],IW=[3,h,_me,0,[Cme,Pme,Oe,I4],[0,0,0,0]],xW=[3,h,Qme,0,[BC,Yme,cEe,Xhe],[0,0,2,0]],CW=[3,h,Q4,0,[kce],[64]],bW=[3,h,kme,0,[BC,R4,jme,H4,Oe,Q4],[0,0,0,2,0,()=>CW]],wW=[3,h,Gme,0,[L4,HE],[0,0],2],DW=[3,h,$me,0,[X4,tpe,d4,Nde],[0,0,0,0],4],OW=[3,h,Wme,0,[nt,kr,st,Nd],[0,0,0,0]],vW=[3,h,zme,0,[eB],[0]],PW=[3,h,fhe,0,[jce,W4,uue,AB,T4,_he,mr],[0,0,0,0,0,0,0],2],NW=[3,h,mhe,0,[],[]],kW=[3,h,The,0,[wce,Qce],[2,0]],MW=[3,h,Ahe,0,[ms],[0]],LW=[3,h,Whe,0,[st,cge,nt,DE,wC,mr],[0,0,0,()=>VE,0,0],2],$W=[3,h,qhe,0,[hB],[0]],FW=[3,h,the,0,[GB,NE,ms,_ge],[0,0,0,65]],UW=[3,h,nB,0,[Nme,Cd,gt,hs,Vt,ege,ySe,ahe,oB,Mde,bd,Ac,Bce,fce,Mme],[0,0,0,0,0,0,64,0,()=>eye,()=>XEe,0,()=>Nc,0,0,0]],BW=[3,h,rhe,0,[jB,spe,vue,nue],[()=>jW,0,0,0]],GW=[3,h,ohe,0,[Vt,Oi,gt],[0,128,0],2],HW=[3,h,che,0,[Vt,gt,Oi,bc,Cc,eb],[0,0,128,0,0,()=>Pye]],VW=[3,h,ihe,0,[tB,Zhe],[0,0]],WW=[3,h,hhe,0,[Vt,U4,ghe],[0,64,64]],IC=[3,h,Ehe,0,[X,gt],[0,0],2],tb=[3,h,uB,0,[_Se,Lde],[()=>IC,()=>IC],2],zW=[3,h,Fhe,0,[xc,Ce,sr,QC,DC,K4,gSe],[0,0,0,4,4,1,0]],jW=[3,h,Vhe,0,[Uce,vd,Ohe,tB,qce,Nce,Kce,Pce,Fde,mce],[0,0,0,0,0,0,0,0,()=>_W,0]],qW=[3,h,zhe,0,[Vt,gt,Oi],[0,0,128],3],kc=[3,h,Ic,0,[gB,mme],[()=>oye,1]],KW=[3,h,Nhe,0,[X,Di,mr,kd,Mo],[0,0,0,2,()=>Fo],1],YW=[3,h,Lhe,0,[Ve,xe],[0,0]],QW=[3,h,Jhe,0,[kr,nt],[0,0],2],JW=[3,h,age,0,[rEe],[64]],rb=[3,h,Uge,0,[Vt,Oi,dme],[0,128,2]],XW=[3,h,Dge,0,[Vt,Oi],[0,128],2],ZW=[3,h,rSe,0,[X,FE,KC],[0,0,0],1],ez=[3,h,lSe,0,[h4,Ls,Jce,st,nt],[0,0,0,0,0],1],tz=[3,h,dSe,0,[Xce],[0]],rz=[3,h,fSe,0,[kr,nt,st,$d],[0,0,0,0]],nz=[3,h,mSe,0,[],[]],sz=[3,h,vge,0,[X,gt,aEe,Ce],[0,0,0,0],4],oz=[3,h,RSe,0,[X,Rc,MB,Ve,bd,Oe,Mr,y4,PE,Ic,NB,Dd,Mo,Pd,BB,fs,q4,Di,Fs,OC,J4,aB,wd,kd,S4,TE,LC],[0,4,0,0,0,0,()=>$r,4,4,()=>kc,0,2,()=>Fo,64,1,64,()=>KEe,0,()=>Uo,2,0,0,()=>az,2,0,0,()=>rj],3],iz=[3,h,oge,0,[X,Lr,$s],[0,0,0]],az=[3,h,nge,0,[$E,OE],[0,4],1],cz=[3,h,sge,0,[$E,OE],[0,4],1],uz=[3,h,ige,0,[Ve,A4,X,vc,xe,gt,hs,Vt,bc,Cc,lB,mr,P4,v4,wE,O4,Ope,D4,TE],[0,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],4],lz=[3,h,RB,0,[Oc,VC,xC,Ve,GC,Ce,_B,sr,kE,AE,vE,$4],[0,0,0,0,()=>$r,0,()=>nb,0,0,0,4,0]],nb=[3,h,uge,0,[TE],[0]],dz=[3,h,lge,0,[vd,KB],[0,0]],pz=[3,h,mge,0,[Ve,gt,Vt,UE,vc,hs,HC,UC],[0,0,0,0,4,0,()=>nj,()=>sj],5],fz=[3,h,gge,0,[Oc,VC,xC,Ve,Ce,sr,_B,kE,AE,vE,$4],[0,0,0,0,0,0,()=>nb,0,0,4,0]],mz=[3,h,Ige,0,[Cd,rpe,hs,Oi,Oe,$de,Tle,USe,uEe,uB],[0,0,0,0,0,0,0,()=>hye,64,()=>tb]],hz=[3,h,Mge,0,[Dc,Oe,xE,x4,Ce,sr],[0,0,0,0,0,0]],gz=[3,h,Hge,0,[gt,Vt,vc,bc,X,Ve,hs,Cc,Oe,wd,Ac],[0,0,4,0,0,0,0,0,0,()=>ob,()=>Nc],4],Sz=[3,h,CB,0,[gt,Vt,B4,bc,X,Ve,hs,Cc,Oe,G4,wd,Ac],[0,0,4,0,0,0,0,0,0,0,()=>ob,()=>Nc],4],sb=[3,h,bB,0,[Ve,gt,Vt,UE,vc,hs,HC,zde,xce,UC,Ac,ide],[0,0,0,0,4,0,()=>nj,0,0,()=>sj,()=>Nc,0],5],ob=[3,h,xge,0,[UE,OE],[0,4],1],Ez=[3,h,Cge,0,[UE,OE],[0,4],1],yz=[3,h,Lge,0,[gt,Vt,B4,bc,hs,Cc,wd,Ac],[0,0,4,0,0,0,()=>Ez,()=>Nc],4],_z=[3,h,vB,0,[Ke,Oc,Oe,Ce,Lr,Mr,fs,Fs,zge,RE,IE,YC,Id,ME,FC,Od,wc],[0,0,0,0,0,()=>$r,64,()=>Uo,0,0,0,()=>ib,()=>Fd,0,64,()=>Ud,64]],Rz=[3,h,Vge,0,[kE,wc],[0,64]],ib=[3,h,YC,0,[AE,Xue,vE,GSe,kle,Wpe,Gpe,w4],[0,0,4,1,1,1,1,1]],Tz=[3,h,PB,0,[xe,Oc,Cd,Ce,Lo,pB,RE,IE,f4,C4,Tc,YC,sr,EB],[0,0,0,0,()=>Us,2,0,0,4,4,()=>Pc,()=>ib,0,()=>ab]],Us=[3,h,Yge,0,[she,Rhe,cpe,upe,pme,fme,cue],[0,64,1,1,1,1,0]],Az=[3,h,Qge,0,[xC,VC,Ce,sr,u4,kE],[0,0,0,0,()=>DG,0]],ab=[3,h,Zge,0,[w4],[1]],Iz=[3,h,Xge,0,[xe,Cd,Ce,f4,C4,sr,EB,Lo],[0,0,0,4,4,0,()=>ab,()=>Us]],xz=[3,h,nSe,0,[Ke,Oc,Oe,Ce,Id,ME,AE,vE,Od],[0,0,0,0,()=>Fd,0,0,4,()=>Ud]],Cz=[3,h,cSe,0,[X,Rc,MB,Ve,OSe,PE,y4,NB,J4,aB,wd,LC],[0,4,0,0,0,4,4,0,0,0,()=>cz,()=>rj],3],bz=[3,h,Nge,0,[mr,zC],[0,()=>ij]],wz=[3,h,kge,0,[xc],[0]],Dz=[3,h,oSe,0,[Ke,xe,qe],[0,0,0],2],Oz=[3,h,iSe,0,[],[]],cb=[3,h,tEe,0,[L4,HE],[0,0],2],WE=[3,h,BE,0,[hle,lEe],[0,0]],vz=[3,h,LSe,0,[BC,R4,H4,Oe],[0,0,2,0]],Pz=[3,h,$Se,0,[Bhe,dhe,Ihe,Che],[1,1,1,1]],Nz=[3,h,HSe,0,[bE,wi,Ce,sr,Rc,PE,yme],[0,0,0,0,4,4,1]],kz=[3,h,HB,0,[JSe],[2]],Mz=[3,h,zSe,0,[kr,nt,st,$d,Zpe],[0,0,0,0,0]],Lz=[3,h,qSe,0,[WB],[0]],$z=[3,h,CSe,0,[kr,Lce,h4,$C,Ls,st,Upe],[0,0,0,4,0,0,2]],zE=[3,h,$B,0,[Ls,ISe,xSe,nt,st],[0,0,0,0,0]],Fz=[3,h,vSe,0,[Uue,ms,MSe],[0,0,0]],Uz=[3,h,WSe,0,[nt,st,_4,Ls,$C,Oe,ms,NE,Nd,F4,Fme,Ume,N4],[0,0,0,0,4,0,0,0,0,0,0,0,2]],Bz=[3,h,ZSe,0,[nt,st,$d,M4,kr,UB,Oe,Nd],[0,0,0,2,0,4,0,0]],Gz=[3,h,oEe,0,[wi,Eme,Cce,Dhe,ehe,BE],[0,0,()=>oj,64,2,()=>WE],1],Hz=[3,h,iEe,0,[bE],[0]],Vz=[3,h,fEe,0,[X,Lr,$s,ZC,Tge,Age,Mr,fs,Md,Di,Ic,FE,KC,Pd,Fs,Dd,mr,kd,Mo,bC],[0,0,0,2,0,0,()=>$r,64,64,0,()=>kc,0,0,64,()=>Uo,2,0,2,()=>Fo,2],1],Wz=[3,h,mEe,0,[Ke,wc,xd,Tc,GC,Lo,xe,qe],[0,64,64,()=>Pc,()=>$r,()=>Us,[0,4],0],2],zz=[3,h,hEe,0,[xe],[0]],jz=[3,h,SEe,0,[Ve,xe],[0,0]],qz=[3,h,yEe,0,[Ke,Oe,Lr,$s,ZC,Mr,fs,Fs,Lo,RE,IE,Tc,ME,Id,xe,xd,wc,qe,Od],[0,0,0,0,2,()=>$r,64,()=>Uo,()=>Us,0,0,()=>Pc,0,()=>Fd,[0,4],64,64,0,()=>Ud],1],Kz=[3,h,_Ee,0,[xe],[0]],Yz=[3,h,TEe,0,[OC,X],[2,0],2],Qz=[3,h,AEe,0,[Ve],[0]],Jz=[3,h,vEe,0,[Lr,$s],[0,0]],Xz=[3,h,PEe,0,[Mr,Oe,fs,p4,E4],[()=>xye,0,64,0,64]],Zz=[3,h,kEe,0,[nt,Xme],[0,()=>Nye]],ej=[3,h,LEe,0,[X4,tge,Oe],[0,2,0]],tj=[3,h,eb,0,[dEe],[64]],Mc="unit",FEe=[1,h,Ece,0,()=>OG],UEe=[1,h,_ce,0,()=>MG],BEe=[1,h,Vce,0,()=>LG],GEe=[1,h,m4,0,()=>BG],HEe=[1,h,hue,0,()=>GG],VEe=[1,h,wue,0,()=>WG],WEe=[1,h,b4,0,()=>SV],zEe=[1,h,kpe,0,()=>wV],rj=[1,h,LC,0,()=>RW],jEe=[1,h,V4,0,()=>TW],qEe=[1,h,Dme,0,()=>AW],KEe=[1,h,q4,0,()=>IW],YEe=[1,h,Lme,0,()=>bW],$r=[1,h,Mr,0,()=>xW],nj=[1,h,HC,0,()=>wW],sj=[1,h,UC,0,()=>DW],QEe=[1,h,dB,0,()=>rb],JEe=[1,h,rB,0,()=>FW],XEe=[1,h,nhe,0,()=>BW],oj=[1,h,uhe,0,()=>GW],ZEe=[1,h,lhe,0,()=>HW],eye=[1,h,oB,0,()=>VW],tye=[1,h,iB,0,()=>WW],rye=[1,h,cB,0,()=>tb],nye=[1,h,fB,0,()=>zW],sye=[1,h,mB,0,()=>qW],oye=[1,h,gB,0,()=>QW],ij=[1,h,zC,0,()=>JW],iye=[1,h,Oge,0,()=>XW],aye=[1,h,Bge,0,()=>rb],cye=[1,h,SB,0,()=>iz],uye=[1,h,yB,0,()=>uz],lye=[1,h,dge,0,()=>dz],dye=[1,h,hge,0,()=>pz],pye=[1,h,Sge,0,()=>fz],fye=[1,h,IB,0,()=>mz],mye=[1,h,wB,0,()=>hz],hye=[1,h,Fge,0,()=>cb],gye=[1,h,xB,0,()=>sb],Sye=[1,h,OB,0,()=>gz],Eye=[1,h,DB,0,()=>yz],yye=[1,h,LB,0,()=>oz],_ye=[1,h,Wge,0,()=>Rz],Rye=[1,h,Jge,0,()=>Az],Tye=[1,h,eSe,0,()=>Iz],Aye=[1,h,aSe,0,()=>xz],Iye=[1,h,kB,0,()=>Cz],Uo=[1,h,Fs,0,()=>cb],xye=[1,h,FSe,0,()=>vz],Cye=[1,h,VSe,0,()=>Nz],bye=[1,h,bSe,0,()=>$z],wye=[1,h,FB,0,()=>zE],Dye=[1,h,VB,0,()=>Uz],Oye=[1,h,zB,0,()=>Bz],vye=[1,h,qB,0,()=>zE],Pye=[1,h,MEe,0,()=>Zz],Nye=[1,h,$Ee,0,()=>ej],aj=[9,h,Tce,0,()=>vG,()=>PG],cj=[9,h,bce,2,()=>NG,()=>kG],uj=[9,h,Gce,0,()=>$G,()=>FG],lj=[9,h,$ue,0,()=>UG,()=>Mc],dj=[9,h,kue,0,()=>zG,()=>jG],pj=[9,h,eue,0,()=>qG,()=>KG],fj=[9,h,oue,0,()=>YG,()=>QG],mj=[9,h,Pue,0,()=>JG,()=>eH],hj=[9,h,yue,0,()=>XG,()=>ZG],gj=[9,h,Tue,0,()=>tH,()=>rH],Sj=[9,h,Due,0,()=>nH,()=>sH],Ej=[9,h,ule,0,()=>oH,()=>iH],yj=[9,h,Ode,2,()=>aH,()=>cH],_j=[9,h,Vue,0,()=>uH,()=>lH],Rj=[9,h,nle,0,()=>dH,()=>Mc],Tj=[9,h,yde,0,()=>pH,()=>Mc],Aj=[9,h,Ble,0,()=>fH,()=>mH],Ij=[9,h,ade,0,()=>hH,()=>gH],xj=[9,h,vde,2,()=>SH,()=>EH],Cj=[9,h,Bue,0,()=>yH,()=>_H],bj=[9,h,Jue,0,()=>AH,()=>IH],wj=[9,h,Wue,0,()=>RH,()=>TH],Dj=[9,h,ele,0,()=>xH,()=>CH],Oj=[9,h,ale,0,()=>bH,()=>wH],vj=[9,h,mle,0,()=>DH,()=>OH],Pj=[9,h,Ele,2,()=>vH,()=>PH],Nj=[9,h,yle,0,()=>NH,()=>kH],kj=[9,h,xle,0,()=>MH,()=>LH],Mj=[9,h,Ole,0,()=>$H,()=>FH],Lj=[9,h,Gle,0,()=>UH,()=>BH],$j=[9,h,nde,0,()=>GH,()=>HH],Fj=[9,h,sde,0,()=>zH,()=>jH],Uj=[9,h,zle,0,()=>VH,()=>WH],Bj=[9,h,ode,0,()=>qH,()=>KH],Gj=[9,h,_de,0,()=>ZH,()=>eV],Hj=[9,h,Ede,0,()=>YH,()=>XH],Vj=[9,h,Sde,0,()=>QH,()=>JH],Wj=[9,h,Pde,2,()=>tV,()=>rV],zj=[9,h,bde,2,()=>nV,()=>sV],jj=[9,h,Ile,0,()=>oV,()=>iV],qj=[9,h,Qle,0,()=>aV,()=>cV],Kj=[9,h,cde,0,()=>uV,()=>lV],Yj=[9,h,Jde,0,()=>dV,()=>pV],Qj=[9,h,Bde,0,()=>mV,()=>hV],Jj=[9,h,Qde,0,()=>gV,()=>Mc],Xj=[9,h,dpe,0,()=>EV,()=>yV],Zj=[9,h,mpe,0,()=>_V,()=>RV],e6=[9,h,Spe,0,()=>TV,()=>AV],t6=[9,h,_pe,0,()=>IV,()=>xV],r6=[9,h,Ipe,0,()=>CV,()=>bV],n6=[9,h,jpe,0,()=>OV,()=>vV],s6=[9,h,Qpe,0,()=>PV,()=>NV],o6=[9,h,efe,0,()=>kV,()=>MV],i6=[9,h,ofe,0,()=>LV,()=>$V],a6=[9,h,cfe,0,()=>FV,()=>UV],c6=[9,h,dfe,0,()=>BV,()=>GV],u6=[9,h,Afe,0,()=>HV,()=>VV],l6=[9,h,_fe,0,()=>WV,()=>zV],d6=[9,h,Sfe,0,()=>jV,()=>qV],p6=[9,h,Ofe,0,()=>KV,()=>YV],f6=[9,h,Nfe,0,()=>QV,()=>JV],m6=[9,h,Lfe,0,()=>XV,()=>ZV],h6=[9,h,Mfe,0,()=>eW,()=>tW],g6=[9,h,Vfe,0,()=>rW,()=>nW],S6=[9,h,Cfe,0,()=>pW,()=>fW],E6=[9,h,zfe,0,()=>sW,()=>oW],y6=[9,h,Xfe,0,()=>iW,()=>aW],_6=[9,h,tme,0,()=>cW,()=>uW],R6=[9,h,Wfe,0,()=>lW,()=>dW],T6=[9,h,ome,2,()=>mW,()=>hW],A6=[9,h,rme,2,()=>gW,()=>SW],I6=[9,h,cme,2,()=>EW,()=>yW],x6=[9,h,qme,2,()=>OW,()=>vW],C6=[9,h,phe,2,()=>PW,()=>NW],b6=[9,h,xhe,2,()=>kW,()=>MW],w6=[9,h,Qhe,2,()=>LW,()=>$W],D6=[9,h,Ghe,0,()=>KW,()=>YW],O6=[9,h,tSe,0,()=>ZW,()=>Mc],v6=[9,h,uSe,0,()=>ez,()=>tz],P6=[9,h,pSe,2,()=>rz,()=>nz],N6=[9,h,Gge,0,()=>sz,()=>Mc],k6=[9,h,$ge,0,()=>bz,()=>wz],M6=[9,h,sSe,0,()=>Dz,()=>Oz],L6=[9,h,QSe,2,()=>Mz,()=>Lz],$6=[9,h,sEe,0,()=>Gz,()=>Hz],F6=[9,h,pEe,0,()=>Vz,()=>jz],U6=[9,h,gEe,0,()=>Wz,()=>zz],B6=[9,h,EEe,0,()=>qz,()=>Kz],G6=[9,h,REe,0,()=>Yz,()=>Qz],H6=[9,h,OEe,0,()=>Jz,()=>Xz],kye=t=>({apiVersion:"2010-05-15",base64Decoder:t?.base64Decoder??Kae,base64Encoder:t?.base64Encoder??qae,disableHostPrefix:t?.disableHostPrefix??!1,endpointProvider:t?.endpointProvider??pce,extensions:t?.extensions??[],httpAuthSchemeProvider:t?.httpAuthSchemeProvider??rce,httpAuthSchemes:t?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:e=>e.getIdentityProvider("aws.auth#sigv4"),signer:new Hae}],logger:t?.logger??new dae,protocol:t?.protocol??Xae,protocolSettings:t?.protocolSettings??{defaultNamespace:"com.amazonaws.cloudformation",errorTypeRegistries:wG,xmlNamespace:"http://cloudformation.amazonaws.com/doc/2010-05-15/",version:"2010-05-15",serviceTarget:"CloudFormation"},serviceId:t?.serviceId??"CloudFormation",sha256:t?.sha256??Zae,urlParser:t?.urlParser??vae,utf8Decoder:t?.utf8Decoder??jae,utf8Encoder:t?.utf8Encoder??zae}),Mye=t=>{pae(process.version);let e=yae(t),r=()=>e().then(fae),n=kye(t);Yie(process.version);let s={profile:t?.profile,logger:n.logger};return{...n,...t,runtime:"node",defaultsMode:e,authSchemePreference:t?.authSchemePreference??Ci(Vae,s),bodyLengthChecker:t?.bodyLengthChecker??Yae,credentialDefaultProvider:t?.credentialDefaultProvider??Wae,defaultUserAgentProvider:t?.defaultUserAgentProvider??Qie({serviceId:n.serviceId,clientVersion:ace.version}),maxAttempts:t?.maxAttempts??Ci($ae,t),region:t?.region??Ci(Tae,{...Aae,...s}),requestHandler:Jae.create(t?.requestHandler??r),retryMode:t?.retryMode??Ci({...Lae,default:async()=>(await r()).retryMode||Mae},t),streamCollector:t?.streamCollector??Qae,useDualstackEndpoint:t?.useDualstackEndpoint??Ci(Rae,s),useFipsEndpoint:t?.useFipsEndpoint??Ci(_ae,s),userAgentAppId:t?.userAgentAppId??Ci(Jie,s)}},Lye=t=>{let e=t.httpAuthSchemes,r=t.httpAuthSchemeProvider,n=t.credentials;return{setHttpAuthScheme(s){let o=e.findIndex(i=>i.schemeId===s.schemeId);o===-1?e.push(s):e.splice(o,1,s)},httpAuthSchemes(){return e},setHttpAuthSchemeProvider(s){r=s},httpAuthSchemeProvider(){return r},setCredentials(s){n=s},credentials(){return n}}},$ye=t=>({httpAuthSchemes:t.httpAuthSchemes(),httpAuthSchemeProvider:t.httpAuthSchemeProvider(),credentials:t.credentials()}),Fye=(t,e)=>{let r=Object.assign(Xie(t),mae(t),Pae(t),Lye(t));return e.forEach(n=>n.configure(r)),Object.assign(t,Zie(r),hae(r),Nae(r),$ye(r))},Ee=class extends i4{config;constructor(...[e]){let r=Mye(e||{});super(r),this.initConfig=r;let n=sce(r),s=eae(n),o=Fae(s),i=Iae(o),a=tae(i),c=Dae(a),u=nce(c),p=Fye(u,e?.extensions||[]);this.config=p,this.middlewareStack.use(Bae(this.config)),this.middlewareStack.use(rae(this.config)),this.middlewareStack.use(Uae(this.config)),this.middlewareStack.use(kae(this.config)),this.middlewareStack.use(nae(this.config)),this.middlewareStack.use(sae(this.config)),this.middlewareStack.use(oae(this.config)),this.middlewareStack.use(iae(this.config,{httpAuthSchemeParametersProvider:ece,identityProviderConfigProvider:async d=>new aae({"aws.auth#sigv4":d.credentials})})),this.middlewareStack.use(cae(this.config))}destroy(){super.destroy()}},C=gae(oce,"CloudFormation","CloudFormationClient",Oae),b={},w=(t,e,r,n)=>[],lS=class extends C(b,w,"ActivateOrganizationsAccess",aj){},dS=class extends C(b,w,"ActivateType",cj){},pS=class extends C(b,w,"BatchDescribeTypeConfigurations",uj){},fS=class extends C(b,w,"CancelUpdateStack",lj){},mS=class extends C(b,w,"ContinueUpdateRollback",dj){},hS=class extends C(b,w,"CreateChangeSet",pj){},gS=class extends C(b,w,"CreateGeneratedTemplate",fj){},SS=class extends C(b,w,"CreateStack",mj){},ES=class extends C(b,w,"CreateStackInstances",hj){},yS=class extends C(b,w,"CreateStackRefactor",gj){},_S=class extends C(b,w,"CreateStackSet",Sj){},RS=class extends C(b,w,"DeactivateOrganizationsAccess",Ej){},TS=class extends C(b,w,"DeactivateType",yj){},AS=class extends C(b,w,"DeleteChangeSet",_j){},IS=class extends C(b,w,"DeleteGeneratedTemplate",Rj){},xS=class extends C(b,w,"DeleteStack",Tj){},CS=class extends C(b,w,"DeleteStackInstances",Aj){},bS=class extends C(b,w,"DeleteStackSet",Ij){},wS=class extends C(b,w,"DeregisterType",xj){},td=class extends C(b,w,"DescribeAccountLimits",Cj){},yc=class extends C(b,w,"DescribeChangeSet",bj){},DS=class extends C(b,w,"DescribeChangeSetHooks",wj){},rd=class extends C(b,w,"DescribeEvents",Dj){},OS=class extends C(b,w,"DescribeGeneratedTemplate",Oj){},vS=class extends C(b,w,"DescribeOrganizationsAccess",vj){},PS=class extends C(b,w,"DescribePublisher",Pj){},NS=class extends C(b,w,"DescribeResourceScan",Nj){},kS=class extends C(b,w,"DescribeStackDriftDetectionStatus",kj){},nd=class extends C(b,w,"DescribeStackEvents",Mj){},MS=class extends C(b,w,"DescribeStackInstance",Lj){},_c=class extends C(b,w,"DescribeStackRefactor",$j){},LS=class extends C(b,w,"DescribeStackResource",Fj){},sd=class extends C(b,w,"DescribeStackResourceDrifts",Uj){},$S=class extends C(b,w,"DescribeStackResources",Bj){},pn=class extends C(b,w,"DescribeStacks",Gj){},FS=class extends C(b,w,"DescribeStackSet",Hj){},US=class extends C(b,w,"DescribeStackSetOperation",Vj){},BS=class extends C(b,w,"DescribeType",Wj){},od=class extends C(b,w,"DescribeTypeRegistration",zj){},GS=class extends C(b,w,"DetectStackDrift",jj){},HS=class extends C(b,w,"DetectStackResourceDrift",qj){},VS=class extends C(b,w,"DetectStackSetDrift",Kj){},WS=class extends C(b,w,"EstimateTemplateCost",Yj){},zS=class extends C(b,w,"ExecuteChangeSet",Qj){},jS=class extends C(b,w,"ExecuteStackRefactor",Jj){},qS=class extends C(b,w,"GetGeneratedTemplate",Xj){},KS=class extends C(b,w,"GetHookResult",Zj){},YS=class extends C(b,w,"GetStackPolicy",e6){},QS=class extends C(b,w,"GetTemplate",t6){},JS=class extends C(b,w,"GetTemplateSummary",r6){},XS=class extends C(b,w,"ImportStacksToStackSet",n6){},id=class extends C(b,w,"ListChangeSets",s6){},ad=class extends C(b,w,"ListExports",o6){},cd=class extends C(b,w,"ListGeneratedTemplates",i6){},ZS=class extends C(b,w,"ListHookResults",a6){},ud=class extends C(b,w,"ListImports",c6){},ld=class extends C(b,w,"ListResourceScanRelatedResources",u6){},dd=class extends C(b,w,"ListResourceScanResources",l6){},pd=class extends C(b,w,"ListResourceScans",d6){},eE=class extends C(b,w,"ListStackInstanceResourceDrifts",p6){},fd=class extends C(b,w,"ListStackInstances",f6){},md=class extends C(b,w,"ListStackRefactorActions",m6){},hd=class extends C(b,w,"ListStackRefactors",h6){},gd=class extends C(b,w,"ListStackResources",g6){},Sd=class extends C(b,w,"ListStacks",S6){},tE=class extends C(b,w,"ListStackSetAutoDeploymentTargets",E6){},Ed=class extends C(b,w,"ListStackSetOperationResults",y6){},yd=class extends C(b,w,"ListStackSetOperations",_6){},_d=class extends C(b,w,"ListStackSets",R6){},Rd=class extends C(b,w,"ListTypeRegistrations",T6){},Td=class extends C(b,w,"ListTypes",A6){},Ad=class extends C(b,w,"ListTypeVersions",I6){},rE=class extends C(b,w,"PublishType",x6){},nE=class extends C(b,w,"RecordHandlerProgress",C6){},sE=class extends C(b,w,"RegisterPublisher",b6){},oE=class extends C(b,w,"RegisterType",w6){},iE=class extends C(b,w,"RollbackStack",D6){},aE=class extends C(b,w,"SetStackPolicy",O6){},cE=class extends C(b,w,"SetTypeConfiguration",v6){},uE=class extends C(b,w,"SetTypeDefaultVersion",P6){},lE=class extends C(b,w,"SignalResource",N6){},dE=class extends C(b,w,"StartResourceScan",k6){},pE=class extends C(b,w,"StopStackSetOperation",M6){},fE=class extends C(b,w,"TestType",L6){},mE=class extends C(b,w,"UpdateGeneratedTemplate",$6){},hE=class extends C(b,w,"UpdateStack",F6){},gE=class extends C(b,w,"UpdateStackInstances",U6){},SE=class extends C(b,w,"UpdateStackSet",B6){},EE=class extends C(b,w,"UpdateTerminationProtection",G6){},yE=class extends C(b,w,"ValidateTemplate",H6){},V6=De(Ee,td,"NextToken","NextToken",""),W6=De(Ee,yc,"NextToken","NextToken",""),z6=De(Ee,rd,"NextToken","NextToken",""),j6=De(Ee,nd,"NextToken","NextToken",""),q6=De(Ee,sd,"NextToken","NextToken","MaxResults"),K6=De(Ee,pn,"NextToken","NextToken",""),Y6=De(Ee,id,"NextToken","NextToken",""),Q6=De(Ee,ad,"NextToken","NextToken",""),J6=De(Ee,cd,"NextToken","NextToken","MaxResults"),X6=De(Ee,ud,"NextToken","NextToken",""),Z6=De(Ee,ld,"NextToken","NextToken","MaxResults"),eq=De(Ee,dd,"NextToken","NextToken","MaxResults"),tq=De(Ee,pd,"NextToken","NextToken","MaxResults"),rq=De(Ee,fd,"NextToken","NextToken","MaxResults"),nq=De(Ee,md,"NextToken","NextToken","MaxResults"),sq=De(Ee,hd,"NextToken","NextToken","MaxResults"),oq=De(Ee,gd,"NextToken","NextToken",""),iq=De(Ee,Ed,"NextToken","NextToken","MaxResults"),aq=De(Ee,yd,"NextToken","NextToken","MaxResults"),cq=De(Ee,_d,"NextToken","NextToken","MaxResults"),uq=De(Ee,Sd,"NextToken","NextToken",""),lq=De(Ee,Rd,"NextToken","NextToken","MaxResults"),dq=De(Ee,Td,"NextToken","NextToken","MaxResults"),pq=De(Ee,Ad,"NextToken","NextToken","MaxResults"),fq=async(t,e)=>{let r;try{let n=await t.send(new yc(e));r=n;try{if(n.Status==="CREATE_COMPLETE")return{state:N.SUCCESS,reason:r}}catch{}try{if(n.Status==="FAILED")return{state:N.FAILURE,reason:r}}catch{}}catch(n){if(r=n,n.name==="ValidationError")return{state:N.FAILURE,reason:r}}return{state:N.RETRY,reason:r}},Uye=async(t,e)=>je({...{minDelay:30,maxDelay:120},...t},e,fq),mq=async(t,e)=>{let n=await je({...{minDelay:30,maxDelay:120},...t},e,fq);return ds(n)},hq=async(t,e)=>{let r;try{let n=await t.send(new pn(e));r=n;try{let s=()=>[].concat(...n.Stacks).map(c=>c.StackStatus),o=s().length>0;for(let i of s())o=o&&i=="CREATE_COMPLETE";if(o)return{state:N.SUCCESS,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(c=>c.StackStatus),o=s().length>0;for(let i of s())o=o&&i=="UPDATE_COMPLETE";if(o)return{state:N.SUCCESS,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(c=>c.StackStatus),o=s().length>0;for(let i of s())o=o&&i=="UPDATE_IN_PROGRESS";if(o)return{state:N.SUCCESS,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(c=>c.StackStatus),o=s().length>0;for(let i of s())o=o&&i=="UPDATE_COMPLETE_CLEANUP_IN_PROGRESS";if(o)return{state:N.SUCCESS,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(c=>c.StackStatus),o=s().length>0;for(let i of s())o=o&&i=="UPDATE_FAILED";if(o)return{state:N.SUCCESS,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(c=>c.StackStatus),o=s().length>0;for(let i of s())o=o&&i=="UPDATE_ROLLBACK_IN_PROGRESS";if(o)return{state:N.SUCCESS,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(c=>c.StackStatus),o=s().length>0;for(let i of s())o=o&&i=="UPDATE_ROLLBACK_FAILED";if(o)return{state:N.SUCCESS,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(c=>c.StackStatus),o=s().length>0;for(let i of s())o=o&&i=="UPDATE_ROLLBACK_COMPLETE_CLEANUP_IN_PROGRESS";if(o)return{state:N.SUCCESS,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(c=>c.StackStatus),o=s().length>0;for(let i of s())o=o&&i=="UPDATE_ROLLBACK_COMPLETE";if(o)return{state:N.SUCCESS,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="CREATE_FAILED")return{state:N.FAILURE,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="DELETE_COMPLETE")return{state:N.FAILURE,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="DELETE_FAILED")return{state:N.FAILURE,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="ROLLBACK_FAILED")return{state:N.FAILURE,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="ROLLBACK_COMPLETE")return{state:N.FAILURE,reason:r}}catch{}}catch(n){if(r=n,n.name==="ValidationError")return{state:N.FAILURE,reason:r}}return{state:N.RETRY,reason:r}},Bye=async(t,e)=>je({...{minDelay:30,maxDelay:120},...t},e,hq),gq=async(t,e)=>{let n=await je({...{minDelay:30,maxDelay:120},...t},e,hq);return ds(n)},Sq=async(t,e)=>{let r;try{let n=await t.send(new pn(e));r=n;try{let s=()=>[].concat(...n.Stacks).map(c=>c.StackStatus),o=s().length>0;for(let i of s())o=o&&i=="DELETE_COMPLETE";if(o)return{state:N.SUCCESS,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="DELETE_FAILED")return{state:N.FAILURE,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="CREATE_FAILED")return{state:N.FAILURE,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="ROLLBACK_FAILED")return{state:N.FAILURE,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="UPDATE_ROLLBACK_IN_PROGRESS")return{state:N.FAILURE,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="UPDATE_ROLLBACK_FAILED")return{state:N.FAILURE,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="UPDATE_ROLLBACK_COMPLETE")return{state:N.FAILURE,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="UPDATE_COMPLETE")return{state:N.FAILURE,reason:r}}catch{}}catch(n){if(r=n,n.name==="ValidationError")return{state:N.SUCCESS,reason:r}}return{state:N.RETRY,reason:r}},Gye=async(t,e)=>je({...{minDelay:30,maxDelay:120},...t},e,Sq),Eq=async(t,e)=>{let n=await je({...{minDelay:30,maxDelay:120},...t},e,Sq);return ds(n)},yq=async(t,e)=>{let r;try{return r=await t.send(new pn(e)),{state:N.SUCCESS,reason:r}}catch(n){if(r=n,n.name==="ValidationError")return{state:N.RETRY,reason:r}}return{state:N.RETRY,reason:r}},Hye=async(t,e)=>je({...{minDelay:5,maxDelay:120},...t},e,yq),_q=async(t,e)=>{let n=await je({...{minDelay:5,maxDelay:120},...t},e,yq);return ds(n)},Rq=async(t,e)=>{let r;try{let n=await t.send(new pn(e));r=n;try{let s=()=>[].concat(...n.Stacks).map(c=>c.StackStatus),o=s().length>0;for(let i of s())o=o&&i=="IMPORT_COMPLETE";if(o)return{state:N.SUCCESS,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="ROLLBACK_COMPLETE")return{state:N.FAILURE,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="ROLLBACK_FAILED")return{state:N.FAILURE,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="IMPORT_ROLLBACK_IN_PROGRESS")return{state:N.FAILURE,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="IMPORT_ROLLBACK_FAILED")return{state:N.FAILURE,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="IMPORT_ROLLBACK_COMPLETE")return{state:N.FAILURE,reason:r}}catch{}}catch(n){if(r=n,n.name==="ValidationError")return{state:N.FAILURE,reason:r}}return{state:N.RETRY,reason:r}},Vye=async(t,e)=>je({...{minDelay:30,maxDelay:120},...t},e,Rq),Tq=async(t,e)=>{let n=await je({...{minDelay:30,maxDelay:120},...t},e,Rq);return ds(n)},Aq=async(t,e)=>{let r;try{let n=await t.send(new _c(e));r=n;try{if(n.Status==="CREATE_COMPLETE")return{state:N.SUCCESS,reason:r}}catch{}try{if(n.Status==="CREATE_FAILED")return{state:N.FAILURE,reason:r}}catch{}}catch(n){if(r=n,n.name==="ValidationError")return{state:N.FAILURE,reason:r}}return{state:N.RETRY,reason:r}},Wye=async(t,e)=>je({...{minDelay:5,maxDelay:120},...t},e,Aq),Iq=async(t,e)=>{let n=await je({...{minDelay:5,maxDelay:120},...t},e,Aq);return ds(n)},xq=async(t,e)=>{let r;try{let n=await t.send(new _c(e));r=n;try{if(n.ExecutionStatus==="EXECUTE_COMPLETE")return{state:N.SUCCESS,reason:r}}catch{}try{if(n.ExecutionStatus==="EXECUTE_FAILED")return{state:N.FAILURE,reason:r}}catch{}try{if(n.ExecutionStatus==="ROLLBACK_COMPLETE")return{state:N.FAILURE,reason:r}}catch{}}catch(n){if(r=n,n.name==="ValidationError")return{state:N.FAILURE,reason:r}}return{state:N.RETRY,reason:r}},zye=async(t,e)=>je({...{minDelay:15,maxDelay:120},...t},e,xq),Cq=async(t,e)=>{let n=await je({...{minDelay:15,maxDelay:120},...t},e,xq);return ds(n)},bq=async(t,e)=>{let r;try{let n=await t.send(new pn(e));r=n;try{let s=()=>[].concat(...n.Stacks).map(c=>c.StackStatus),o=s().length>0;for(let i of s())o=o&&i=="UPDATE_ROLLBACK_COMPLETE";if(o)return{state:N.SUCCESS,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="UPDATE_FAILED")return{state:N.FAILURE,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="UPDATE_ROLLBACK_FAILED")return{state:N.FAILURE,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="DELETE_FAILED")return{state:N.FAILURE,reason:r}}catch{}}catch(n){if(r=n,n.name==="ValidationError")return{state:N.FAILURE,reason:r}}return{state:N.RETRY,reason:r}},jye=async(t,e)=>je({...{minDelay:30,maxDelay:120},...t},e,bq),wq=async(t,e)=>{let n=await je({...{minDelay:30,maxDelay:120},...t},e,bq);return ds(n)},Dq=async(t,e)=>{let r;try{let n=await t.send(new pn(e));r=n;try{let s=()=>[].concat(...n.Stacks).map(c=>c.StackStatus),o=s().length>0;for(let i of s())o=o&&i=="UPDATE_COMPLETE";if(o)return{state:N.SUCCESS,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="UPDATE_FAILED")return{state:N.FAILURE,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="UPDATE_ROLLBACK_FAILED")return{state:N.FAILURE,reason:r}}catch{}try{let s=()=>[].concat(...n.Stacks).map(a=>a.StackStatus);for(let o of s())if(o=="UPDATE_ROLLBACK_COMPLETE")return{state:N.FAILURE,reason:r}}catch{}}catch(n){if(r=n,n.name==="ValidationError")return{state:N.FAILURE,reason:r}}return{state:N.RETRY,reason:r}},qye=async(t,e)=>je({...{minDelay:30,maxDelay:120},...t},e,Dq),Oq=async(t,e)=>{let n=await je({...{minDelay:30,maxDelay:120},...t},e,Dq);return ds(n)},vq=async(t,e)=>{let r;try{let n=await t.send(new od(e));r=n;try{if(n.ProgressStatus==="COMPLETE")return{state:N.SUCCESS,reason:r}}catch{}try{if(n.ProgressStatus==="FAILED")return{state:N.FAILURE,reason:r}}catch{}}catch(n){r=n}return{state:N.RETRY,reason:r}},Kye=async(t,e)=>je({...{minDelay:30,maxDelay:120},...t},e,vq),Pq=async(t,e)=>{let n=await je({...{minDelay:30,maxDelay:120},...t},e,vq);return ds(n)},Yye={ActivateOrganizationsAccessCommand:lS,ActivateTypeCommand:dS,BatchDescribeTypeConfigurationsCommand:pS,CancelUpdateStackCommand:fS,ContinueUpdateRollbackCommand:mS,CreateChangeSetCommand:hS,CreateGeneratedTemplateCommand:gS,CreateStackCommand:SS,CreateStackInstancesCommand:ES,CreateStackRefactorCommand:yS,CreateStackSetCommand:_S,DeactivateOrganizationsAccessCommand:RS,DeactivateTypeCommand:TS,DeleteChangeSetCommand:AS,DeleteGeneratedTemplateCommand:IS,DeleteStackCommand:xS,DeleteStackInstancesCommand:CS,DeleteStackSetCommand:bS,DeregisterTypeCommand:wS,DescribeAccountLimitsCommand:td,DescribeChangeSetCommand:yc,DescribeChangeSetHooksCommand:DS,DescribeEventsCommand:rd,DescribeGeneratedTemplateCommand:OS,DescribeOrganizationsAccessCommand:vS,DescribePublisherCommand:PS,DescribeResourceScanCommand:NS,DescribeStackDriftDetectionStatusCommand:kS,DescribeStackEventsCommand:nd,DescribeStackInstanceCommand:MS,DescribeStackRefactorCommand:_c,DescribeStackResourceCommand:LS,DescribeStackResourceDriftsCommand:sd,DescribeStackResourcesCommand:$S,DescribeStacksCommand:pn,DescribeStackSetCommand:FS,DescribeStackSetOperationCommand:US,DescribeTypeCommand:BS,DescribeTypeRegistrationCommand:od,DetectStackDriftCommand:GS,DetectStackResourceDriftCommand:HS,DetectStackSetDriftCommand:VS,EstimateTemplateCostCommand:WS,ExecuteChangeSetCommand:zS,ExecuteStackRefactorCommand:jS,GetGeneratedTemplateCommand:qS,GetHookResultCommand:KS,GetStackPolicyCommand:YS,GetTemplateCommand:QS,GetTemplateSummaryCommand:JS,ImportStacksToStackSetCommand:XS,ListChangeSetsCommand:id,ListExportsCommand:ad,ListGeneratedTemplatesCommand:cd,ListHookResultsCommand:ZS,ListImportsCommand:ud,ListResourceScanRelatedResourcesCommand:ld,ListResourceScanResourcesCommand:dd,ListResourceScansCommand:pd,ListStackInstanceResourceDriftsCommand:eE,ListStackInstancesCommand:fd,ListStackRefactorActionsCommand:md,ListStackRefactorsCommand:hd,ListStackResourcesCommand:gd,ListStacksCommand:Sd,ListStackSetAutoDeploymentTargetsCommand:tE,ListStackSetOperationResultsCommand:Ed,ListStackSetOperationsCommand:yd,ListStackSetsCommand:_d,ListTypeRegistrationsCommand:Rd,ListTypesCommand:Td,ListTypeVersionsCommand:Ad,PublishTypeCommand:rE,RecordHandlerProgressCommand:nE,RegisterPublisherCommand:sE,RegisterTypeCommand:oE,RollbackStackCommand:iE,SetStackPolicyCommand:aE,SetTypeConfigurationCommand:cE,SetTypeDefaultVersionCommand:uE,SignalResourceCommand:lE,StartResourceScanCommand:dE,StopStackSetOperationCommand:pE,TestTypeCommand:fE,UpdateGeneratedTemplateCommand:mE,UpdateStackCommand:hE,UpdateStackInstancesCommand:gE,UpdateStackSetCommand:SE,UpdateTerminationProtectionCommand:EE,ValidateTemplateCommand:yE},Qye={paginateDescribeAccountLimits:V6,paginateDescribeChangeSet:W6,paginateDescribeEvents:z6,paginateDescribeStackEvents:j6,paginateDescribeStackResourceDrifts:q6,paginateDescribeStacks:K6,paginateListChangeSets:Y6,paginateListExports:Q6,paginateListGeneratedTemplates:J6,paginateListImports:X6,paginateListResourceScanRelatedResources:Z6,paginateListResourceScanResources:eq,paginateListResourceScans:tq,paginateListStackInstances:rq,paginateListStackRefactorActions:nq,paginateListStackRefactors:sq,paginateListStackResources:oq,paginateListStacks:uq,paginateListStackSetOperationResults:iq,paginateListStackSetOperations:aq,paginateListStackSets:cq,paginateListTypeRegistrations:lq,paginateListTypes:dq,paginateListTypeVersions:pq},Jye={waitUntilChangeSetCreateComplete:mq,waitUntilStackRefactorCreateComplete:Iq,waitUntilStackRefactorExecuteComplete:Cq,waitUntilStackCreateComplete:gq,waitUntilStackDeleteComplete:Eq,waitUntilStackExists:_q,waitUntilStackImportComplete:Tq,waitUntilStackRollbackComplete:wq,waitUntilStackUpdateComplete:Oq,waitUntilTypeRegistrationComplete:Pq},_E=class extends Ee{};Sae(Yye,_E,{paginators:Qye,waiters:Jye});var Xye={DIFFERENCE:"DIFFERENCE",INTERSECTION:"INTERSECTION",NONE:"NONE",UNION:"UNION"},Zye={FAILED:"FAILED",SKIPPED:"SKIPPED",SUCCEEDED:"SUCCEEDED"},e_e={HOOK:"HOOK",MODULE:"MODULE",RESOURCE:"RESOURCE"},t_e={MAJOR:"MAJOR",MINOR:"MINOR"},r_e={TEMPLATE:"TEMPLATE"},n_e={CRITICAL:"CRITICAL",HIGH:"HIGH",INFORMATIONAL:"INFORMATIONAL",LOW:"LOW",MEDIUM:"MEDIUM"},s_e={FAILED:"FAILED",PASSED:"PASSED",SKIPPED:"SKIPPED"},o_e={Add:"Add",Modify:"Modify",Remove:"Remove",SyncWithActual:"SyncWithActual"},i_e={FAILED:"FAILED",IN_PROGRESS:"IN_PROGRESS",SUCCEEDED:"SUCCEEDED"},a_e={ACTUAL_STATE:"ACTUAL_STATE",PREVIOUS_DEPLOYMENT_STATE:"PREVIOUS_DEPLOYMENT_STATE"},c_e={DELEGATED_ADMIN:"DELEGATED_ADMIN",SELF:"SELF"},u_e={CAPABILITY_AUTO_EXPAND:"CAPABILITY_AUTO_EXPAND",CAPABILITY_IAM:"CAPABILITY_IAM",CAPABILITY_NAMED_IAM:"CAPABILITY_NAMED_IAM"},l_e={ACTIVATED:"ACTIVATED",AWS_TYPES:"AWS_TYPES",REGISTERED:"REGISTERED",THIRD_PARTY:"THIRD_PARTY"},d_e={Add:"Add",Dynamic:"Dynamic",Import:"Import",Modify:"Modify",Remove:"Remove",SyncWithActual:"SyncWithActual"},p_e={Automatic:"Automatic",DirectModification:"DirectModification",NoModification:"NoModification",ParameterReference:"ParameterReference",ResourceAttribute:"ResourceAttribute",ResourceReference:"ResourceReference"},f_e={Dynamic:"Dynamic",Static:"Static"},m_e={CreationPolicy:"CreationPolicy",DeletionPolicy:"DeletionPolicy",Metadata:"Metadata",Properties:"Properties",Tags:"Tags",UpdatePolicy:"UpdatePolicy",UpdateReplacePolicy:"UpdateReplacePolicy"},h_e={Always:"Always",Conditionally:"Conditionally",Never:"Never"},g_e={Delete:"Delete",ReplaceAndDelete:"ReplaceAndDelete",ReplaceAndRetain:"ReplaceAndRetain",ReplaceAndSnapshot:"ReplaceAndSnapshot",Retain:"Retain",Snapshot:"Snapshot"},S_e={Conditional:"Conditional",False:"False",True:"True"},E_e={MANAGED_BY_AWS:"MANAGED_BY_AWS",SENSITIVE_PROPERTY:"SENSITIVE_PROPERTY",WRITE_ONLY_PROPERTY:"WRITE_ONLY_PROPERTY"},y_e={DELETED:"DELETED",IN_SYNC:"IN_SYNC",MODIFIED:"MODIFIED",NOT_CHECKED:"NOT_CHECKED",UNKNOWN:"UNKNOWN",UNSUPPORTED:"UNSUPPORTED"},__e={Resource:"Resource"},R_e={FAIL:"FAIL",WARN:"WARN"},T_e={PRE_PROVISION:"PRE_PROVISION"},A_e={RESOURCE:"RESOURCE"},I_e={PLANNED:"PLANNED",PLANNING:"PLANNING",UNAVAILABLE:"UNAVAILABLE"},x_e={CREATE_COMPLETE:"CREATE_COMPLETE",CREATE_IN_PROGRESS:"CREATE_IN_PROGRESS",CREATE_PENDING:"CREATE_PENDING",DELETE_COMPLETE:"DELETE_COMPLETE",DELETE_FAILED:"DELETE_FAILED",DELETE_IN_PROGRESS:"DELETE_IN_PROGRESS",DELETE_PENDING:"DELETE_PENDING",FAILED:"FAILED"},C_e={AVAILABLE:"AVAILABLE",EXECUTE_COMPLETE:"EXECUTE_COMPLETE",EXECUTE_FAILED:"EXECUTE_FAILED",EXECUTE_IN_PROGRESS:"EXECUTE_IN_PROGRESS",OBSOLETE:"OBSOLETE",UNAVAILABLE:"UNAVAILABLE"},b_e={CREATE:"CREATE",IMPORT:"IMPORT",UPDATE:"UPDATE"},w_e={EXPRESS:"EXPRESS",STANDARD:"STANDARD"},D_e={REVERT_DRIFT:"REVERT_DRIFT"},O_e={DELETE:"DELETE",DO_NOTHING:"DO_NOTHING",ROLLBACK:"ROLLBACK"},v_e={DELETE:"DELETE",RETAIN:"RETAIN"},P_e={DELETE:"DELETE",RETAIN:"RETAIN"},N_e={DELETE:"DELETE",DO_NOTHING:"DO_NOTHING",ROLLBACK:"ROLLBACK"},k_e={SOFT_FAILURE_TOLERANCE:"SOFT_FAILURE_TOLERANCE",STRICT_FAILURE_TOLERANCE:"STRICT_FAILURE_TOLERANCE"},M_e={PARALLEL:"PARALLEL",SEQUENTIAL:"SEQUENTIAL"},L_e={SELF_MANAGED:"SELF_MANAGED",SERVICE_MANAGED:"SERVICE_MANAGED"},$_e={FORCE_DELETE_STACK:"FORCE_DELETE_STACK",STANDARD:"STANDARD"},F_e={HOOK:"HOOK",MODULE:"MODULE",RESOURCE:"RESOURCE"},U_e={DRIFTED:"DRIFTED",IN_SYNC:"IN_SYNC",NOT_CHECKED:"NOT_CHECKED",UNKNOWN:"UNKNOWN"},B_e={CONFIGURATION_COMPLETE:"CONFIGURATION_COMPLETE",VALIDATION_FAILED:"VALIDATION_FAILED"},G_e={HOOK_INVOCATION_ERROR:"HOOK_INVOCATION_ERROR",PROGRESS_EVENT:"PROGRESS_EVENT",PROVISIONING_ERROR:"PROVISIONING_ERROR",STACK_EVENT:"STACK_EVENT",VALIDATION_ERROR:"VALIDATION_ERROR"},H_e={HOOK_COMPLETE_FAILED:"HOOK_COMPLETE_FAILED",HOOK_COMPLETE_SUCCEEDED:"HOOK_COMPLETE_SUCCEEDED",HOOK_FAILED:"HOOK_FAILED",HOOK_IN_PROGRESS:"HOOK_IN_PROGRESS"},V_e={CONTINUE_ROLLBACK:"CONTINUE_ROLLBACK",CREATE_CHANGESET:"CREATE_CHANGESET",CREATE_STACK:"CREATE_STACK",DELETE_STACK:"DELETE_STACK",ROLLBACK:"ROLLBACK",UPDATE_STACK:"UPDATE_STACK"},W_e={CREATE_COMPLETE:"CREATE_COMPLETE",CREATE_FAILED:"CREATE_FAILED",CREATE_IN_PROGRESS:"CREATE_IN_PROGRESS",DELETE_COMPLETE:"DELETE_COMPLETE",DELETE_FAILED:"DELETE_FAILED",DELETE_IN_PROGRESS:"DELETE_IN_PROGRESS",DELETE_SKIPPED:"DELETE_SKIPPED",EXPORT_COMPLETE:"EXPORT_COMPLETE",EXPORT_FAILED:"EXPORT_FAILED",EXPORT_IN_PROGRESS:"EXPORT_IN_PROGRESS",EXPORT_ROLLBACK_COMPLETE:"EXPORT_ROLLBACK_COMPLETE",EXPORT_ROLLBACK_FAILED:"EXPORT_ROLLBACK_FAILED",EXPORT_ROLLBACK_IN_PROGRESS:"EXPORT_ROLLBACK_IN_PROGRESS",IMPORT_COMPLETE:"IMPORT_COMPLETE",IMPORT_FAILED:"IMPORT_FAILED",IMPORT_IN_PROGRESS:"IMPORT_IN_PROGRESS",IMPORT_ROLLBACK_COMPLETE:"IMPORT_ROLLBACK_COMPLETE",IMPORT_ROLLBACK_FAILED:"IMPORT_ROLLBACK_FAILED",IMPORT_ROLLBACK_IN_PROGRESS:"IMPORT_ROLLBACK_IN_PROGRESS",ROLLBACK_COMPLETE:"ROLLBACK_COMPLETE",ROLLBACK_FAILED:"ROLLBACK_FAILED",ROLLBACK_IN_PROGRESS:"ROLLBACK_IN_PROGRESS",UPDATE_COMPLETE:"UPDATE_COMPLETE",UPDATE_FAILED:"UPDATE_FAILED",UPDATE_IN_PROGRESS:"UPDATE_IN_PROGRESS",UPDATE_ROLLBACK_COMPLETE:"UPDATE_ROLLBACK_COMPLETE",UPDATE_ROLLBACK_FAILED:"UPDATE_ROLLBACK_FAILED",UPDATE_ROLLBACK_IN_PROGRESS:"UPDATE_ROLLBACK_IN_PROGRESS"},z_e={FAILED:"FAILED",SKIPPED:"SKIPPED"},j_e={COMPLETE:"COMPLETE",FAILED:"FAILED",IN_PROGRESS:"IN_PROGRESS",PENDING:"PENDING"},q_e={EXCLUDED_PROPERTIES:"EXCLUDED_PROPERTIES",EXCLUDED_RESOURCES:"EXCLUDED_RESOURCES",MUTUALLY_EXCLUSIVE_PROPERTIES:"MUTUALLY_EXCLUSIVE_PROPERTIES",MUTUALLY_EXCLUSIVE_TYPES:"MUTUALLY_EXCLUSIVE_TYPES",UNSUPPORTED_PROPERTIES:"UNSUPPORTED_PROPERTIES"},K_e={COMPLETE:"COMPLETE",CREATE_IN_PROGRESS:"CREATE_IN_PROGRESS",CREATE_PENDING:"CREATE_PENDING",DELETE_IN_PROGRESS:"DELETE_IN_PROGRESS",DELETE_PENDING:"DELETE_PENDING",FAILED:"FAILED",UPDATE_IN_PROGRESS:"UPDATE_IN_PROGRESS",UPDATE_PENDING:"UPDATE_PENDING"},Y_e={DISABLED:"DISABLED",DISABLED_PERMANENTLY:"DISABLED_PERMANENTLY",ENABLED:"ENABLED"},Q_e={AWS_Marketplace:"AWS_Marketplace",Bitbucket:"Bitbucket",GitHub:"GitHub"},J_e={UNVERIFIED:"UNVERIFIED",VERIFIED:"VERIFIED"},X_e={COMPLETE:"COMPLETE",EXPIRED:"EXPIRED",FAILED:"FAILED",IN_PROGRESS:"IN_PROGRESS"},Z_e={DETECTION_COMPLETE:"DETECTION_COMPLETE",DETECTION_FAILED:"DETECTION_FAILED",DETECTION_IN_PROGRESS:"DETECTION_IN_PROGRESS"},eRe={CANCELLED:"CANCELLED",FAILED:"FAILED",FAILED_IMPORT:"FAILED_IMPORT",INOPERABLE:"INOPERABLE",PENDING:"PENDING",RUNNING:"RUNNING",SKIPPED_SUSPENDED_ACCOUNT:"SKIPPED_SUSPENDED_ACCOUNT",SUCCEEDED:"SUCCEEDED"},tRe={CURRENT:"CURRENT",INOPERABLE:"INOPERABLE",OUTDATED:"OUTDATED"},rRe={AVAILABLE:"AVAILABLE",EXECUTE_COMPLETE:"EXECUTE_COMPLETE",EXECUTE_FAILED:"EXECUTE_FAILED",EXECUTE_IN_PROGRESS:"EXECUTE_IN_PROGRESS",OBSOLETE:"OBSOLETE",ROLLBACK_COMPLETE:"ROLLBACK_COMPLETE",ROLLBACK_FAILED:"ROLLBACK_FAILED",ROLLBACK_IN_PROGRESS:"ROLLBACK_IN_PROGRESS",UNAVAILABLE:"UNAVAILABLE"},nRe={CREATE_COMPLETE:"CREATE_COMPLETE",CREATE_FAILED:"CREATE_FAILED",CREATE_IN_PROGRESS:"CREATE_IN_PROGRESS",DELETE_COMPLETE:"DELETE_COMPLETE",DELETE_FAILED:"DELETE_FAILED",DELETE_IN_PROGRESS:"DELETE_IN_PROGRESS"},sRe={ADD:"ADD",NOT_EQUAL:"NOT_EQUAL",REMOVE:"REMOVE"},oRe={CREATE_COMPLETE:"CREATE_COMPLETE",CREATE_FAILED:"CREATE_FAILED",CREATE_IN_PROGRESS:"CREATE_IN_PROGRESS",DELETE_COMPLETE:"DELETE_COMPLETE",DELETE_FAILED:"DELETE_FAILED",DELETE_IN_PROGRESS:"DELETE_IN_PROGRESS",IMPORT_COMPLETE:"IMPORT_COMPLETE",IMPORT_IN_PROGRESS:"IMPORT_IN_PROGRESS",IMPORT_ROLLBACK_COMPLETE:"IMPORT_ROLLBACK_COMPLETE",IMPORT_ROLLBACK_FAILED:"IMPORT_ROLLBACK_FAILED",IMPORT_ROLLBACK_IN_PROGRESS:"IMPORT_ROLLBACK_IN_PROGRESS",REVIEW_IN_PROGRESS:"REVIEW_IN_PROGRESS",ROLLBACK_COMPLETE:"ROLLBACK_COMPLETE",ROLLBACK_FAILED:"ROLLBACK_FAILED",ROLLBACK_IN_PROGRESS:"ROLLBACK_IN_PROGRESS",UPDATE_COMPLETE:"UPDATE_COMPLETE",UPDATE_COMPLETE_CLEANUP_IN_PROGRESS:"UPDATE_COMPLETE_CLEANUP_IN_PROGRESS",UPDATE_FAILED:"UPDATE_FAILED",UPDATE_IN_PROGRESS:"UPDATE_IN_PROGRESS",UPDATE_ROLLBACK_COMPLETE:"UPDATE_ROLLBACK_COMPLETE",UPDATE_ROLLBACK_COMPLETE_CLEANUP_IN_PROGRESS:"UPDATE_ROLLBACK_COMPLETE_CLEANUP_IN_PROGRESS",UPDATE_ROLLBACK_FAILED:"UPDATE_ROLLBACK_FAILED",UPDATE_ROLLBACK_IN_PROGRESS:"UPDATE_ROLLBACK_IN_PROGRESS"},iRe={COMPLETED:"COMPLETED",FAILED:"FAILED",IN_PROGRESS:"IN_PROGRESS",PARTIAL_SUCCESS:"PARTIAL_SUCCESS",STOPPED:"STOPPED"},aRe={DRIFTED:"DRIFTED",IN_SYNC:"IN_SYNC",NOT_CHECKED:"NOT_CHECKED"},cRe={ACTIVE:"ACTIVE",DELETED:"DELETED"},uRe={CREATE:"CREATE",DELETE:"DELETE",DETECT_DRIFT:"DETECT_DRIFT",UPDATE:"UPDATE"},lRe={FAILED:"FAILED",QUEUED:"QUEUED",RUNNING:"RUNNING",STOPPED:"STOPPED",STOPPING:"STOPPING",SUCCEEDED:"SUCCEEDED"},dRe={DEPRECATED:"DEPRECATED",LIVE:"LIVE"},pRe={FULLY_MUTABLE:"FULLY_MUTABLE",IMMUTABLE:"IMMUTABLE",NON_PROVISIONABLE:"NON_PROVISIONABLE"},fRe={FAILED:"FAILED",IN_PROGRESS:"IN_PROGRESS",NOT_TESTED:"NOT_TESTED",PASSED:"PASSED"},mRe={PRIVATE:"PRIVATE",PUBLIC:"PUBLIC"},hRe={COMPLETE:"COMPLETE",FAILED:"FAILED",IN_PROGRESS:"IN_PROGRESS"},gRe={JSON:"JSON",YAML:"YAML"},SRe={CREATE:"CREATE",DELETE:"DELETE",IMPORT:"IMPORT",UPDATE:"UPDATE"},ERe={Original:"Original",Processed:"Processed"},yRe={CHANGE_SET:"CHANGE_SET",CLOUD_CONTROL:"CLOUD_CONTROL",RESOURCE:"RESOURCE",STACK:"STACK"},_Re={FULL:"FULL",PARTIAL:"PARTIAL"},RRe={DETAILED_STATUS:"DETAILED_STATUS",DRIFT_STATUS:"DRIFT_STATUS",LAST_OPERATION_ID:"LAST_OPERATION_ID"},TRe={CREATE:"CREATE",MOVE:"MOVE"},ARe={AUTO:"AUTO",MANUAL:"MANUAL"},IRe={RESOURCE:"RESOURCE",STACK:"STACK"},xRe={OPERATION_RESULT_STATUS:"OPERATION_RESULT_STATUS"},CRe={CANCELLED:"CANCELLED",FAILED:"FAILED",PENDING:"PENDING",RUNNING:"RUNNING",SUCCEEDED:"SUCCEEDED"},bRe={FAILED:"FAILED",IN_PROGRESS:"IN_PROGRESS",PENDING:"PENDING",SUCCESS:"SUCCESS"},wRe={AccessDenied:"AccessDenied",AlreadyExists:"AlreadyExists",GeneralServiceException:"GeneralServiceException",HandlerInternalFailure:"HandlerInternalFailure",InternalFailure:"InternalFailure",InvalidCredentials:"InvalidCredentials",InvalidRequest:"InvalidRequest",InvalidTypeConfiguration:"InvalidTypeConfiguration",NetworkFailure:"NetworkFailure",NonCompliant:"NonCompliant",NotFound:"NotFound",NotUpdatable:"NotUpdatable",ResourceConflict:"ResourceConflict",ServiceInternalError:"ServiceInternalError",ServiceLimitExceeded:"ServiceLimitExceeded",ServiceTimeout:"NotStabilized",Throttling:"Throttling",Unknown:"Unknown",UnsupportedTarget:"UnsupportedTarget"},DRe={FAILURE:"FAILURE",SUCCESS:"SUCCESS"};l.AccountFilterType=Xye;l.AccountGateResult$=DG;l.AccountGateStatus=Zye;l.AccountLimit$=OG;l.ActivateOrganizationsAccess$=aj;l.ActivateOrganizationsAccessCommand=lS;l.ActivateOrganizationsAccessInput$=vG;l.ActivateOrganizationsAccessOutput$=PG;l.ActivateType$=cj;l.ActivateTypeCommand=dS;l.ActivateTypeInput$=NG;l.ActivateTypeOutput$=kG;l.AfterValueFrom=r_e;l.AlreadyExistsException=Ug;l.AlreadyExistsException$=ZB;l.Annotation$=MG;l.AnnotationSeverityLevel=n_e;l.AnnotationStatus=s_e;l.AttributeChangeType=o_e;l.AutoDeployment$=Fd;l.BatchDescribeTypeConfigurations$=uj;l.BatchDescribeTypeConfigurationsCommand=pS;l.BatchDescribeTypeConfigurationsError$=LG;l.BatchDescribeTypeConfigurationsInput$=$G;l.BatchDescribeTypeConfigurationsOutput$=FG;l.BeaconStackOperationStatus=i_e;l.BeforeValueFrom=a_e;l.CFNRegistryException=$g;l.CFNRegistryException$=eG;l.CallAs=c_e;l.CancelUpdateStack$=lj;l.CancelUpdateStackCommand=fS;l.CancelUpdateStackInput$=UG;l.Capability=u_e;l.Category=l_e;l.Change$=BG;l.ChangeAction=d_e;l.ChangeSetHook$=GG;l.ChangeSetHookResourceTargetDetails$=HG;l.ChangeSetHookTargetDetails$=VG;l.ChangeSetHooksStatus=I_e;l.ChangeSetNotFoundException=Hg;l.ChangeSetNotFoundException$=tG;l.ChangeSetStatus=x_e;l.ChangeSetSummary$=WG;l.ChangeSetType=b_e;l.ChangeSource=p_e;l.ChangeType=__e;l.CloudFormation=_E;l.CloudFormationClient=Ee;l.CloudFormationServiceException=re;l.CloudFormationServiceException$=XB;l.ConcurrencyMode=k_e;l.ConcurrentResourcesLimitExceededException=zg;l.ConcurrentResourcesLimitExceededException$=rG;l.ContinueUpdateRollback$=dj;l.ContinueUpdateRollbackCommand=mS;l.ContinueUpdateRollbackInput$=zG;l.ContinueUpdateRollbackOutput$=jG;l.CreateChangeSet$=pj;l.CreateChangeSetCommand=hS;l.CreateChangeSetInput$=qG;l.CreateChangeSetOutput$=KG;l.CreateGeneratedTemplate$=fj;l.CreateGeneratedTemplateCommand=gS;l.CreateGeneratedTemplateInput$=YG;l.CreateGeneratedTemplateOutput$=QG;l.CreateStack$=mj;l.CreateStackCommand=SS;l.CreateStackInput$=JG;l.CreateStackInstances$=hj;l.CreateStackInstancesCommand=ES;l.CreateStackInstancesInput$=XG;l.CreateStackInstancesOutput$=ZG;l.CreateStackOutput$=eH;l.CreateStackRefactor$=gj;l.CreateStackRefactorCommand=yS;l.CreateStackRefactorInput$=tH;l.CreateStackRefactorOutput$=rH;l.CreateStackSet$=Sj;l.CreateStackSetCommand=_S;l.CreateStackSetInput$=nH;l.CreateStackSetOutput$=sH;l.CreatedButModifiedException=Qg;l.CreatedButModifiedException$=nG;l.DeactivateOrganizationsAccess$=Ej;l.DeactivateOrganizationsAccessCommand=RS;l.DeactivateOrganizationsAccessInput$=oH;l.DeactivateOrganizationsAccessOutput$=iH;l.DeactivateType$=yj;l.DeactivateTypeCommand=TS;l.DeactivateTypeInput$=aH;l.DeactivateTypeOutput$=cH;l.DeleteChangeSet$=_j;l.DeleteChangeSetCommand=AS;l.DeleteChangeSetInput$=uH;l.DeleteChangeSetOutput$=lH;l.DeleteGeneratedTemplate$=Rj;l.DeleteGeneratedTemplateCommand=IS;l.DeleteGeneratedTemplateInput$=dH;l.DeleteStack$=Tj;l.DeleteStackCommand=xS;l.DeleteStackInput$=pH;l.DeleteStackInstances$=Aj;l.DeleteStackInstancesCommand=CS;l.DeleteStackInstancesInput$=fH;l.DeleteStackInstancesOutput$=mH;l.DeleteStackSet$=Ij;l.DeleteStackSetCommand=bS;l.DeleteStackSetInput$=hH;l.DeleteStackSetOutput$=gH;l.DeletionMode=$_e;l.DeploymentConfig$=Fo;l.DeploymentConfigMode=w_e;l.DeploymentMode=D_e;l.DeploymentTargets$=Pc;l.DeprecatedStatus=dRe;l.DeregisterType$=xj;l.DeregisterTypeCommand=wS;l.DeregisterTypeInput$=SH;l.DeregisterTypeOutput$=EH;l.DescribeAccountLimits$=Cj;l.DescribeAccountLimitsCommand=td;l.DescribeAccountLimitsInput$=yH;l.DescribeAccountLimitsOutput$=_H;l.DescribeChangeSet$=bj;l.DescribeChangeSetCommand=yc;l.DescribeChangeSetHooks$=wj;l.DescribeChangeSetHooksCommand=DS;l.DescribeChangeSetHooksInput$=RH;l.DescribeChangeSetHooksOutput$=TH;l.DescribeChangeSetInput$=AH;l.DescribeChangeSetOutput$=IH;l.DescribeEvents$=Dj;l.DescribeEventsCommand=rd;l.DescribeEventsInput$=xH;l.DescribeEventsOutput$=CH;l.DescribeGeneratedTemplate$=Oj;l.DescribeGeneratedTemplateCommand=OS;l.DescribeGeneratedTemplateInput$=bH;l.DescribeGeneratedTemplateOutput$=wH;l.DescribeOrganizationsAccess$=vj;l.DescribeOrganizationsAccessCommand=vS;l.DescribeOrganizationsAccessInput$=DH;l.DescribeOrganizationsAccessOutput$=OH;l.DescribePublisher$=Pj;l.DescribePublisherCommand=PS;l.DescribePublisherInput$=vH;l.DescribePublisherOutput$=PH;l.DescribeResourceScan$=Nj;l.DescribeResourceScanCommand=NS;l.DescribeResourceScanInput$=NH;l.DescribeResourceScanOutput$=kH;l.DescribeStackDriftDetectionStatus$=kj;l.DescribeStackDriftDetectionStatusCommand=kS;l.DescribeStackDriftDetectionStatusInput$=MH;l.DescribeStackDriftDetectionStatusOutput$=LH;l.DescribeStackEvents$=Mj;l.DescribeStackEventsCommand=nd;l.DescribeStackEventsInput$=$H;l.DescribeStackEventsOutput$=FH;l.DescribeStackInstance$=Lj;l.DescribeStackInstanceCommand=MS;l.DescribeStackInstanceInput$=UH;l.DescribeStackInstanceOutput$=BH;l.DescribeStackRefactor$=$j;l.DescribeStackRefactorCommand=_c;l.DescribeStackRefactorInput$=GH;l.DescribeStackRefactorOutput$=HH;l.DescribeStackResource$=Fj;l.DescribeStackResourceCommand=LS;l.DescribeStackResourceDrifts$=Uj;l.DescribeStackResourceDriftsCommand=sd;l.DescribeStackResourceDriftsInput$=VH;l.DescribeStackResourceDriftsOutput$=WH;l.DescribeStackResourceInput$=zH;l.DescribeStackResourceOutput$=jH;l.DescribeStackResources$=Bj;l.DescribeStackResourcesCommand=$S;l.DescribeStackResourcesInput$=qH;l.DescribeStackResourcesOutput$=KH;l.DescribeStackSet$=Hj;l.DescribeStackSetCommand=FS;l.DescribeStackSetInput$=YH;l.DescribeStackSetOperation$=Vj;l.DescribeStackSetOperationCommand=US;l.DescribeStackSetOperationInput$=QH;l.DescribeStackSetOperationOutput$=JH;l.DescribeStackSetOutput$=XH;l.DescribeStacks$=Gj;l.DescribeStacksCommand=pn;l.DescribeStacksInput$=ZH;l.DescribeStacksOutput$=eV;l.DescribeType$=Wj;l.DescribeTypeCommand=BS;l.DescribeTypeInput$=tV;l.DescribeTypeOutput$=rV;l.DescribeTypeRegistration$=zj;l.DescribeTypeRegistrationCommand=od;l.DescribeTypeRegistrationInput$=nV;l.DescribeTypeRegistrationOutput$=sV;l.DetailedStatus=B_e;l.DetectStackDrift$=jj;l.DetectStackDriftCommand=GS;l.DetectStackDriftInput$=oV;l.DetectStackDriftOutput$=iV;l.DetectStackResourceDrift$=qj;l.DetectStackResourceDriftCommand=HS;l.DetectStackResourceDriftInput$=aV;l.DetectStackResourceDriftOutput$=cV;l.DetectStackSetDrift$=Kj;l.DetectStackSetDriftCommand=VS;l.DetectStackSetDriftInput$=uV;l.DetectStackSetDriftOutput$=lV;l.DifferenceType=sRe;l.DriftIgnoredReason=E_e;l.EstimateTemplateCost$=Yj;l.EstimateTemplateCostCommand=WS;l.EstimateTemplateCostInput$=dV;l.EstimateTemplateCostOutput$=pV;l.EvaluationType=f_e;l.EventFilter$=fV;l.EventType=G_e;l.ExecuteChangeSet$=Qj;l.ExecuteChangeSetCommand=zS;l.ExecuteChangeSetInput$=mV;l.ExecuteChangeSetOutput$=hV;l.ExecuteStackRefactor$=Jj;l.ExecuteStackRefactorCommand=jS;l.ExecuteStackRefactorInput$=gV;l.ExecutionStatus=C_e;l.Export$=SV;l.GeneratedTemplateDeletionPolicy=v_e;l.GeneratedTemplateNotFoundException=Zg;l.GeneratedTemplateNotFoundException$=sG;l.GeneratedTemplateResourceStatus=j_e;l.GeneratedTemplateStatus=K_e;l.GeneratedTemplateUpdateReplacePolicy=P_e;l.GetGeneratedTemplate$=Xj;l.GetGeneratedTemplateCommand=qS;l.GetGeneratedTemplateInput$=EV;l.GetGeneratedTemplateOutput$=yV;l.GetHookResult$=Zj;l.GetHookResultCommand=KS;l.GetHookResultInput$=_V;l.GetHookResultOutput$=RV;l.GetStackPolicy$=e6;l.GetStackPolicyCommand=YS;l.GetStackPolicyInput$=TV;l.GetStackPolicyOutput$=AV;l.GetTemplate$=t6;l.GetTemplateCommand=QS;l.GetTemplateInput$=IV;l.GetTemplateOutput$=xV;l.GetTemplateSummary$=r6;l.GetTemplateSummaryCommand=JS;l.GetTemplateSummaryInput$=CV;l.GetTemplateSummaryOutput$=bV;l.HandlerErrorCode=wRe;l.HookFailureMode=R_e;l.HookInvocationPoint=T_e;l.HookResultNotFoundException=sS;l.HookResultNotFoundException$=oG;l.HookResultSummary$=wV;l.HookStatus=H_e;l.HookTarget$=DV;l.HookTargetAction=SRe;l.HookTargetType=A_e;l.IdentityProvider=Q_e;l.ImportStacksToStackSet$=n6;l.ImportStacksToStackSetCommand=XS;l.ImportStacksToStackSetInput$=OV;l.ImportStacksToStackSetOutput$=vV;l.InsufficientCapabilitiesException=Vg;l.InsufficientCapabilitiesException$=iG;l.InvalidChangeSetStatusException=Xg;l.InvalidChangeSetStatusException$=aG;l.InvalidOperationException=Mg;l.InvalidOperationException$=cG;l.InvalidStateTransitionException=aS;l.InvalidStateTransitionException$=uG;l.LimitExceededException=Wg;l.LimitExceededException$=lG;l.ListChangeSets$=s6;l.ListChangeSetsCommand=id;l.ListChangeSetsInput$=PV;l.ListChangeSetsOutput$=NV;l.ListExports$=o6;l.ListExportsCommand=ad;l.ListExportsInput$=kV;l.ListExportsOutput$=MV;l.ListGeneratedTemplates$=i6;l.ListGeneratedTemplatesCommand=cd;l.ListGeneratedTemplatesInput$=LV;l.ListGeneratedTemplatesOutput$=$V;l.ListHookResults$=a6;l.ListHookResultsCommand=ZS;l.ListHookResultsInput$=FV;l.ListHookResultsOutput$=UV;l.ListHookResultsTargetType=yRe;l.ListImports$=c6;l.ListImportsCommand=ud;l.ListImportsInput$=BV;l.ListImportsOutput$=GV;l.ListResourceScanRelatedResources$=u6;l.ListResourceScanRelatedResourcesCommand=ld;l.ListResourceScanRelatedResourcesInput$=HV;l.ListResourceScanRelatedResourcesOutput$=VV;l.ListResourceScanResources$=l6;l.ListResourceScanResourcesCommand=dd;l.ListResourceScanResourcesInput$=WV;l.ListResourceScanResourcesOutput$=zV;l.ListResourceScans$=d6;l.ListResourceScansCommand=pd;l.ListResourceScansInput$=jV;l.ListResourceScansOutput$=qV;l.ListStackInstanceResourceDrifts$=p6;l.ListStackInstanceResourceDriftsCommand=eE;l.ListStackInstanceResourceDriftsInput$=KV;l.ListStackInstanceResourceDriftsOutput$=YV;l.ListStackInstances$=f6;l.ListStackInstancesCommand=fd;l.ListStackInstancesInput$=QV;l.ListStackInstancesOutput$=JV;l.ListStackRefactorActions$=m6;l.ListStackRefactorActionsCommand=md;l.ListStackRefactorActionsInput$=XV;l.ListStackRefactorActionsOutput$=ZV;l.ListStackRefactors$=h6;l.ListStackRefactorsCommand=hd;l.ListStackRefactorsInput$=eW;l.ListStackRefactorsOutput$=tW;l.ListStackResources$=g6;l.ListStackResourcesCommand=gd;l.ListStackResourcesInput$=rW;l.ListStackResourcesOutput$=nW;l.ListStackSetAutoDeploymentTargets$=E6;l.ListStackSetAutoDeploymentTargetsCommand=tE;l.ListStackSetAutoDeploymentTargetsInput$=sW;l.ListStackSetAutoDeploymentTargetsOutput$=oW;l.ListStackSetOperationResults$=y6;l.ListStackSetOperationResultsCommand=Ed;l.ListStackSetOperationResultsInput$=iW;l.ListStackSetOperationResultsOutput$=aW;l.ListStackSetOperations$=_6;l.ListStackSetOperationsCommand=yd;l.ListStackSetOperationsInput$=cW;l.ListStackSetOperationsOutput$=uW;l.ListStackSets$=R6;l.ListStackSetsCommand=_d;l.ListStackSetsInput$=lW;l.ListStackSetsOutput$=dW;l.ListStacks$=S6;l.ListStacksCommand=Sd;l.ListStacksInput$=pW;l.ListStacksOutput$=fW;l.ListTypeRegistrations$=T6;l.ListTypeRegistrationsCommand=Rd;l.ListTypeRegistrationsInput$=mW;l.ListTypeRegistrationsOutput$=hW;l.ListTypeVersions$=I6;l.ListTypeVersionsCommand=Ad;l.ListTypeVersionsInput$=EW;l.ListTypeVersionsOutput$=yW;l.ListTypes$=A6;l.ListTypesCommand=Td;l.ListTypesInput$=gW;l.ListTypesOutput$=SW;l.LiveResourceDrift$=_W;l.LoggingConfig$=VE;l.ManagedExecution$=Ud;l.ModuleInfo$=Nc;l.NameAlreadyExistsException=Jg;l.NameAlreadyExistsException$=dG;l.OnFailure=N_e;l.OnStackFailure=O_e;l.OperationEntry$=RW;l.OperationEvent$=TW;l.OperationIdAlreadyExistsException=jg;l.OperationIdAlreadyExistsException$=pG;l.OperationInProgressException=qg;l.OperationInProgressException$=fG;l.OperationNotFoundException=Lg;l.OperationNotFoundException$=mG;l.OperationResultFilter$=AW;l.OperationResultFilterName=xRe;l.OperationStatus=bRe;l.OperationStatusCheckFailedException=cS;l.OperationStatusCheckFailedException$=hG;l.OperationType=V_e;l.OrganizationStatus=Y_e;l.Output$=IW;l.Parameter$=xW;l.ParameterConstraints$=CW;l.ParameterDeclaration$=bW;l.PermissionModels=L_e;l.PhysicalResourceIdContextKeyValuePair$=wW;l.PolicyAction=g_e;l.PropertyDifference$=DW;l.ProvisioningType=pRe;l.PublishType$=x6;l.PublishTypeCommand=rE;l.PublishTypeInput$=OW;l.PublishTypeOutput$=vW;l.PublisherStatus=J_e;l.RecordHandlerProgress$=C6;l.RecordHandlerProgressCommand=nE;l.RecordHandlerProgressInput$=PW;l.RecordHandlerProgressOutput$=NW;l.RegionConcurrencyType=M_e;l.RegisterPublisher$=b6;l.RegisterPublisherCommand=sE;l.RegisterPublisherInput$=kW;l.RegisterPublisherOutput$=MW;l.RegisterType$=w6;l.RegisterTypeCommand=oE;l.RegisterTypeInput$=LW;l.RegisterTypeOutput$=$W;l.RegistrationStatus=hRe;l.RegistryType=F_e;l.Replacement=S_e;l.RequiredActivatedType$=FW;l.RequiresRecreation=h_e;l.ResourceAttribute=m_e;l.ResourceChange$=UW;l.ResourceChangeDetail$=BW;l.ResourceDefinition$=GW;l.ResourceDetail$=HW;l.ResourceDriftIgnoredAttribute$=VW;l.ResourceIdentifierSummary$=WW;l.ResourceLocation$=IC;l.ResourceMapping$=tb;l.ResourceScanInProgressException=iS;l.ResourceScanInProgressException$=gG;l.ResourceScanLimitExceededException=uS;l.ResourceScanLimitExceededException$=SG;l.ResourceScanNotFoundException=tS;l.ResourceScanNotFoundException$=EG;l.ResourceScanStatus=X_e;l.ResourceScanSummary$=zW;l.ResourceSignalStatus=DRe;l.ResourceStatus=W_e;l.ResourceTargetDefinition$=jW;l.ResourceToImport$=qW;l.RollbackConfiguration$=kc;l.RollbackStack$=D6;l.RollbackStackCommand=iE;l.RollbackStackInput$=KW;l.RollbackStackOutput$=YW;l.RollbackTrigger$=QW;l.ScanFilter$=JW;l.ScanType=_Re;l.ScannedResource$=rb;l.ScannedResourceIdentifier$=XW;l.SetStackPolicy$=O6;l.SetStackPolicyCommand=aE;l.SetStackPolicyInput$=ZW;l.SetTypeConfiguration$=v6;l.SetTypeConfigurationCommand=cE;l.SetTypeConfigurationInput$=ez;l.SetTypeConfigurationOutput$=tz;l.SetTypeDefaultVersion$=P6;l.SetTypeDefaultVersionCommand=uE;l.SetTypeDefaultVersionInput$=rz;l.SetTypeDefaultVersionOutput$=nz;l.SignalResource$=N6;l.SignalResourceCommand=lE;l.SignalResourceInput$=sz;l.Stack$=oz;l.StackDefinition$=iz;l.StackDriftDetectionStatus=Z_e;l.StackDriftInformation$=az;l.StackDriftInformationSummary$=cz;l.StackDriftStatus=U_e;l.StackEvent$=uz;l.StackInstance$=lz;l.StackInstanceComprehensiveStatus$=nb;l.StackInstanceDetailedStatus=eRe;l.StackInstanceFilter$=dz;l.StackInstanceFilterName=RRe;l.StackInstanceNotFoundException=rS;l.StackInstanceNotFoundException$=yG;l.StackInstanceResourceDriftsSummary$=pz;l.StackInstanceStatus=tRe;l.StackInstanceSummary$=fz;l.StackNotFoundException=oS;l.StackNotFoundException$=_G;l.StackRefactorAction$=mz;l.StackRefactorActionEntity=IRe;l.StackRefactorActionType=TRe;l.StackRefactorDetection=ARe;l.StackRefactorExecutionStatus=rRe;l.StackRefactorNotFoundException=nS;l.StackRefactorNotFoundException$=RG;l.StackRefactorStatus=nRe;l.StackRefactorSummary$=hz;l.StackResource$=gz;l.StackResourceDetail$=Sz;l.StackResourceDrift$=sb;l.StackResourceDriftInformation$=ob;l.StackResourceDriftInformationSummary$=Ez;l.StackResourceDriftStatus=y_e;l.StackResourceSummary$=yz;l.StackSet$=_z;l.StackSetAutoDeploymentTargetSummary$=Rz;l.StackSetDriftDetectionDetails$=ib;l.StackSetDriftDetectionStatus=iRe;l.StackSetDriftStatus=aRe;l.StackSetNotEmptyException=eS;l.StackSetNotEmptyException$=TG;l.StackSetNotFoundException=Kg;l.StackSetNotFoundException$=AG;l.StackSetOperation$=Tz;l.StackSetOperationAction=uRe;l.StackSetOperationPreferences$=Us;l.StackSetOperationResultStatus=CRe;l.StackSetOperationResultSummary$=Az;l.StackSetOperationStatus=lRe;l.StackSetOperationStatusDetails$=ab;l.StackSetOperationSummary$=Iz;l.StackSetStatus=cRe;l.StackSetSummary$=xz;l.StackStatus=oRe;l.StackSummary$=Cz;l.StaleRequestException=Yg;l.StaleRequestException$=IG;l.StartResourceScan$=k6;l.StartResourceScanCommand=dE;l.StartResourceScanInput$=bz;l.StartResourceScanOutput$=wz;l.StopStackSetOperation$=M6;l.StopStackSetOperationCommand=pE;l.StopStackSetOperationInput$=Dz;l.StopStackSetOperationOutput$=Oz;l.Tag$=cb;l.TemplateConfiguration$=WE;l.TemplateFormat=gRe;l.TemplateParameter$=vz;l.TemplateProgress$=Pz;l.TemplateStage=ERe;l.TemplateSummary$=Nz;l.TemplateSummaryConfig$=kz;l.TestType$=L6;l.TestTypeCommand=fE;l.TestTypeInput$=Mz;l.TestTypeOutput$=Lz;l.ThirdPartyType=e_e;l.TokenAlreadyExistsException=Gg;l.TokenAlreadyExistsException$=xG;l.TypeConfigurationDetails$=$z;l.TypeConfigurationIdentifier$=zE;l.TypeConfigurationNotFoundException=Bg;l.TypeConfigurationNotFoundException$=CG;l.TypeFilters$=Fz;l.TypeNotFoundException=Fg;l.TypeNotFoundException$=bG;l.TypeSummary$=Uz;l.TypeTestsStatus=fRe;l.TypeVersionSummary$=Bz;l.UpdateGeneratedTemplate$=$6;l.UpdateGeneratedTemplateCommand=mE;l.UpdateGeneratedTemplateInput$=Gz;l.UpdateGeneratedTemplateOutput$=Hz;l.UpdateStack$=F6;l.UpdateStackCommand=hE;l.UpdateStackInput$=Vz;l.UpdateStackInstances$=U6;l.UpdateStackInstancesCommand=gE;l.UpdateStackInstancesInput$=Wz;l.UpdateStackInstancesOutput$=zz;l.UpdateStackOutput$=jz;l.UpdateStackSet$=B6;l.UpdateStackSetCommand=SE;l.UpdateStackSetInput$=qz;l.UpdateStackSetOutput$=Kz;l.UpdateTerminationProtection$=G6;l.UpdateTerminationProtectionCommand=EE;l.UpdateTerminationProtectionInput$=Yz;l.UpdateTerminationProtectionOutput$=Qz;l.ValidateTemplate$=H6;l.ValidateTemplateCommand=yE;l.ValidateTemplateInput$=Jz;l.ValidateTemplateOutput$=Xz;l.ValidationStatus=z_e;l.VersionBump=t_e;l.Visibility=mRe;l.WarningDetail$=Zz;l.WarningProperty$=ej;l.WarningType=q_e;l.Warnings$=tj;l.errorTypeRegistries=wG;l.paginateDescribeAccountLimits=V6;l.paginateDescribeChangeSet=W6;l.paginateDescribeEvents=z6;l.paginateDescribeStackEvents=j6;l.paginateDescribeStackResourceDrifts=q6;l.paginateDescribeStacks=K6;l.paginateListChangeSets=Y6;l.paginateListExports=Q6;l.paginateListGeneratedTemplates=J6;l.paginateListImports=X6;l.paginateListResourceScanRelatedResources=Z6;l.paginateListResourceScanResources=eq;l.paginateListResourceScans=tq;l.paginateListStackInstances=rq;l.paginateListStackRefactorActions=nq;l.paginateListStackRefactors=sq;l.paginateListStackResources=oq;l.paginateListStackSetOperationResults=iq;l.paginateListStackSetOperations=aq;l.paginateListStackSets=cq;l.paginateListStacks=uq;l.paginateListTypeRegistrations=lq;l.paginateListTypeVersions=pq;l.paginateListTypes=dq;l.waitForChangeSetCreateComplete=Uye;l.waitForStackCreateComplete=Bye;l.waitForStackDeleteComplete=Gye;l.waitForStackExists=Hye;l.waitForStackImportComplete=Vye;l.waitForStackRefactorCreateComplete=Wye;l.waitForStackRefactorExecuteComplete=zye;l.waitForStackRollbackComplete=jye;l.waitForStackUpdateComplete=qye;l.waitForTypeRegistrationComplete=Kye;l.waitUntilChangeSetCreateComplete=mq;l.waitUntilStackCreateComplete=gq;l.waitUntilStackDeleteComplete=Eq;l.waitUntilStackExists=_q;l.waitUntilStackImportComplete=Tq;l.waitUntilStackRefactorCreateComplete=Iq;l.waitUntilStackRefactorExecuteComplete=Cq;l.waitUntilStackRollbackComplete=wq;l.waitUntilStackUpdateComplete=Oq;l.waitUntilTypeRegistrationComplete=Pq});var Mq=Ne(kq=>{var{createGzip:ORe}=require("node:zlib");kq.compressStream=async t=>t.pipe(ORe())});var Fq=Ne($q=>{var{promisify:vRe}=require("node:util"),{gzip:PRe}=require("node:zlib"),{toUint8Array:Lq}=(L(),O(Bn)),NRe=vRe(PRe);$q.compressString=async t=>{try{let e=await NRe(Lq(t||""));return Lq(e)}catch(e){throw new Error("Failure during compression: "+e.message)}}});var Qq=Ne(hr=>{var{booleanSelector:Uq,SelectorType:jE,numberSelector:Bq}=(se(),O(Gt)),{setFeature:kRe}=(At(),O(Bu)),{HttpRequest:MRe}=(G(),O(qn)),{compressStream:LRe}=Mq(),{compressString:$Re}=Fq(),{isArrayBuffer:FRe}=(L(),O(Bn)),{normalizeProvider:Gq}=(V(),O(Ts)),Hq="AWS_DISABLE_REQUEST_COMPRESSION",Vq="disable_request_compression",Wq=!1,URe={environmentVariableSelector:t=>Uq(t,Hq,jE.ENV),configFileSelector:t=>Uq(t,Vq,jE.CONFIG),default:Wq},zq="AWS_REQUEST_MIN_COMPRESSION_SIZE_BYTES",jq="request_min_compression_size_bytes",qq=10240,BRe={environmentVariableSelector:t=>Bq(t,zq,jE.ENV),configFileSelector:t=>Bq(t,jq,jE.CONFIG),default:qq},ub;(function(t){t.GZIP="gzip"})(ub||(ub={}));var GRe=[ub.GZIP],HRe=t=>t!==void 0&&typeof t!="string"&&!ArrayBuffer.isView(t)&&!FRe(t),Kq=(t,e)=>(r,n)=>async s=>{if(!MRe.isInstance(s.request)||await t.disableRequestCompression())return r(s);let{request:i}=s,{body:a,headers:c}=i,{encodings:u,streamRequiresLength:p}=e,d=a,m=c;for(let g of u)if(GRe.includes(g)){let E=!1;if(HRe(a))if(!p)d=await LRe(a),E=!0;else throw new Error("Compression is not supported for streaming blobs that require a length.");else{let _=t.bodyLengthChecker(a),R=await t.requestMinCompressionSizeBytes();_&&_>=R&&(d=await $Re(a),E=!0)}if(E){c["content-encoding"]?m={...c,"content-encoding":`${c["content-encoding"]}, ${g}`}:m={...c,"content-encoding":g},m["content-encoding"].includes("gzip")&&kRe(n,"GZIP_REQUEST_COMPRESSION","L");break}}return r({...s,request:{...i,body:d,headers:m}})},Yq={name:"compressionMiddleware",step:"build",tags:["REQUEST_BODY_COMPRESSION","GZIP"],override:!0,priority:"high"},VRe=(t,e)=>({applyToStack:r=>{r.add(Kq(t,e),Yq)}}),WRe=t=>{let{disableRequestCompression:e,requestMinCompressionSizeBytes:r}=t;return Object.assign(t,{disableRequestCompression:Gq(e),requestMinCompressionSizeBytes:async()=>{let n=await Gq(r)();if(n<0||n>10485760)throw new RangeError(`The value for requestMinCompressionSizeBytes must be between 0 and 10485760 inclusive. The provided value ${n} is outside this range."`);return n}})};hr.DEFAULT_DISABLE_REQUEST_COMPRESSION=Wq;hr.DEFAULT_NODE_REQUEST_MIN_COMPRESSION_SIZE_BYTES=qq;hr.NODE_DISABLE_REQUEST_COMPRESSION_CONFIG_OPTIONS=URe;hr.NODE_DISABLE_REQUEST_COMPRESSION_ENV_NAME=Hq;hr.NODE_DISABLE_REQUEST_COMPRESSION_INI_NAME=Vq;hr.NODE_REQUEST_MIN_COMPRESSION_SIZE_BYTES_CONFIG_OPTIONS=BRe;hr.NODE_REQUEST_MIN_COMPRESSION_SIZE_BYTES_ENV_NAME=zq;hr.NODE_REQUEST_MIN_COMPRESSION_SIZE_BYTES_INI_NAME=jq;hr.compressionMiddleware=Kq;hr.compressionMiddlewareOptions=Yq;hr.getCompressionPlugin=VRe;hr.resolveCompressionConfig=WRe});var VY=Ne(S=>{var{awsEndpointFunctions:zRe,emitWarningIfUnsupportedVersion:jRe,createDefaultUserAgentProvider:qRe,NODE_APP_ID_CONFIG_OPTIONS:KRe,getAwsRegionExtensionConfiguration:YRe,resolveAwsRegionExtensionConfiguration:QRe,resolveUserAgentConfig:JRe,resolveHostHeaderConfig:XRe,getUserAgentPlugin:ZRe,getHostHeaderPlugin:e0e,getLoggerPlugin:t0e,getRecursionDetectionPlugin:r0e}=(ie(),O(wr)),{getHttpAuthSchemeEndpointRuleSetPlugin:n0e,DefaultIdentityProviderConfig:s0e,getHttpSigningPlugin:o0e,createPaginator:Ss}=(At(),O(Bu)),{normalizeProvider:tK,getSmithyContext:i0e,ServiceException:a0e,NoOpLogger:c0e,emitWarningIfUnsupportedVersion:u0e,loadConfigsForDefaultMode:l0e,getDefaultExtensionConfiguration:d0e,resolveDefaultRuntimeConfig:p0e,Client:rK,makeBuilder:f0e,createWaiter:Go,checkExceptions:i_,WaiterState:Gs,createAggregatedClient:m0e}=(V(),O(Ts)),{Command:h0e}=(V(),O(Ts));S.$Command=h0e;S.__Client=rK;var{resolveDefaultsModeConfig:g0e,loadConfig:Bs,NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS:S0e,NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS:E0e,NODE_REGION_CONFIG_OPTIONS:y0e,NODE_REGION_CONFIG_FILE_OPTIONS:_0e,resolveRegionConfig:R0e}=(se(),O(Gt)),{BinaryDecisionDiagram:T0e,EndpointCache:A0e,decideEndpoint:I0e,customEndpointFunctions:x0e,resolveEndpointConfig:C0e,getEndpointPlugin:b0e}=(Re(),O(Cf)),{parseUrl:w0e,getHttpHandlerExtensionConfiguration:D0e,resolveHttpHandlerRuntimeConfig:O0e,getContentLengthPlugin:v0e}=(G(),O(qn)),{DEFAULT_RETRY_MODE:P0e,NODE_RETRY_MODE_CONFIG_OPTIONS:N0e,NODE_MAX_ATTEMPT_CONFIG_OPTIONS:k0e,resolveRetryConfig:M0e,getRetryPlugin:L0e}=(Zt(),O(xm)),{TypeRegistry:nK,getSchemaSerdePlugin:$0e}=(K(),O(Ip)),{NODE_REQUEST_MIN_COMPRESSION_SIZE_BYTES_CONFIG_OPTIONS:F0e,NODE_DISABLE_REQUEST_COMPRESSION_CONFIG_OPTIONS:U0e,resolveCompressionConfig:B0e,getCompressionPlugin:G0e}=Qq(),{resolveAwsSdkSigV4Config:H0e,AwsSdkSigV4Signer:V0e,NODE_AUTH_SCHEME_PREFERENCE_OPTIONS:W0e}=(It(),O(Qu)),{defaultProvider:z0e}=Pg(),{toUtf8:j0e,fromUtf8:q0e,toBase64:K0e,fromBase64:Y0e,calculateBodyLength:Q0e}=(L(),O(Bn)),{streamCollector:J0e,NodeHttpHandler:X0e}=Ps(),{AwsJson1_0Protocol:Z0e}=(bo(),O(zh)),{Sha256:eTe}=(Gn(),O(Hf)),tTe=async(t,e,r)=>({operation:i0e(e).operation,region:await tK(t.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()});function rTe(t){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"monitoring",region:t.region},propertiesExtractor:(e,r)=>({signingProperties:{config:e,context:r}})}}var nTe=t=>{let e=[];switch(t.operation){default:e.push(rTe(t))}return e},sTe=t=>{let e=H0e(t);return Object.assign(e,{authSchemePreference:tK(t.authSchemePreference??[])})},oTe=t=>Object.assign(t,{useDualstackEndpoint:t.useDualstackEndpoint??!1,useFipsEndpoint:t.useFipsEndpoint??!1,defaultSigningName:"monitoring"}),iTe={UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}},aTe="3.1151.0",cTe={version:aTe},Gd="ref",vi=-1,qE=!0,Jq="isSet",sK="PartitionResult",KE="booleanEquals",lb="getAttr",Xq={[Gd]:"Endpoint"},db={[Gd]:sK},Bd={},Zq=[{[Gd]:"Region"}],eK={conditions:[[Jq,[Xq]],[Jq,Zq],["aws.partition",Zq,sK],[KE,[{[Gd]:"UseFIPS"},qE]],[KE,[{[Gd]:"UseDualStack"},qE]],["stringEquals",[{fn:lb,argv:[db,"name"]},"aws-us-gov"]],[KE,[{fn:lb,argv:[db,"supportsFIPS"]},qE]],[KE,[{fn:lb,argv:[db,"supportsDualStack"]},qE]]],results:[[vi],[vi,"Invalid Configuration: FIPS and custom endpoint are not supported"],[vi,"Invalid Configuration: Dualstack and custom endpoint are not supported"],[Xq,Bd],["https://monitoring.{Region}.{PartitionResult#dnsSuffix}",Bd],["https://monitoring.{Region}.{PartitionResult#dualStackDnsSuffix}",Bd],["https://monitoring-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",Bd],[vi,"FIPS and DualStack are enabled, but this partition does not support one or both"],["https://monitoring-fips.{Region}.{PartitionResult#dnsSuffix}",Bd],[vi,"FIPS is enabled but this partition does not support FIPS"],[vi,"DualStack is enabled but this partition does not support DualStack"],[vi,"Invalid Configuration: Missing Region"]]},uTe=2,Wt=1e8,lTe=new Int32Array([-1,1,-1,0,14,3,1,4,Wt+11,2,5,Wt+11,3,8,6,4,7,Wt+4,7,Wt+5,Wt+10,4,11,9,5,Wt+4,10,6,Wt+8,Wt+9,5,Wt+5,12,6,13,Wt+7,7,Wt+6,Wt+7,3,Wt+1,15,4,Wt+2,Wt+3]),dTe=T0e.from(lTe,uTe,eK.conditions,eK.results),pTe=new A0e({size:50,params:["Endpoint","Region","UseDualStack","UseFIPS"]}),fTe=(t,e={})=>pTe.get(t,()=>I0e(dTe,{endpointParams:t,logger:e.logger}));x0e.aws=zRe;var ke=class t extends a0e{static shapeId="smithy.ts.sdk.synthetic.com.amazonaws.cloudwatch#CloudWatchServiceException";constructor(e){super(e),Object.setPrototypeOf(this,t.prototype)}},YE=class t extends ke{static shapeId="com.amazonaws.cloudwatch#ConflictException";name="ConflictException";$fault="client";Message;constructor(e){super({name:"ConflictException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},QE=class t extends ke{static shapeId="com.amazonaws.cloudwatch#KmsAccessDeniedException";name="KmsAccessDeniedException";$fault="client";Message;constructor(e){super({name:"KmsAccessDeniedException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},JE=class t extends ke{static shapeId="com.amazonaws.cloudwatch#KmsKeyDisabledException";name="KmsKeyDisabledException";$fault="client";Message;constructor(e){super({name:"KmsKeyDisabledException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},XE=class t extends ke{static shapeId="com.amazonaws.cloudwatch#KmsKeyNotFoundException";name="KmsKeyNotFoundException";$fault="client";Message;constructor(e){super({name:"KmsKeyNotFoundException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},ZE=class t extends ke{static shapeId="com.amazonaws.cloudwatch#ResourceNotFoundException";name="ResourceNotFoundException";$fault="client";ResourceType;ResourceId;Message;constructor(e){super({name:"ResourceNotFoundException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.ResourceType=e.ResourceType,this.ResourceId=e.ResourceId,this.Message=e.Message}},ey=class t extends ke{static shapeId="com.amazonaws.cloudwatch#ConcurrentModificationException";name="ConcurrentModificationException";$fault="client";Message;constructor(e){super({name:"ConcurrentModificationException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},ty=class t extends ke{static shapeId="com.amazonaws.cloudwatch#DashboardInvalidInputError";name="DashboardInvalidInputError";$fault="client";dashboardValidationMessages;constructor(e){super({name:"DashboardInvalidInputError",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.dashboardValidationMessages=e.dashboardValidationMessages}},ry=class t extends ke{static shapeId="com.amazonaws.cloudwatch#DashboardNotFoundError";name="DashboardNotFoundError";$fault="client";constructor(e){super({name:"DashboardNotFoundError",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}},ny=class t extends ke{static shapeId="com.amazonaws.cloudwatch#ResourceConflict";name="ResourceConflict";$fault="client";constructor(e){super({name:"ResourceConflict",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}},sy=class t extends ke{static shapeId="com.amazonaws.cloudwatch#ResourceNotFound";name="ResourceNotFound";$fault="client";constructor(e){super({name:"ResourceNotFound",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}},oy=class t extends ke{static shapeId="com.amazonaws.cloudwatch#InternalServiceFault";name="InternalServiceFault";$fault="server";Message;constructor(e){super({name:"InternalServiceFault",$fault:"server",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},iy=class t extends ke{static shapeId="com.amazonaws.cloudwatch#InvalidParameterCombinationException";name="InvalidParameterCombinationException";$fault="client";constructor(e){super({name:"InvalidParameterCombinationException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}},ay=class t extends ke{static shapeId="com.amazonaws.cloudwatch#InvalidParameterValueException";name="InvalidParameterValueException";$fault="client";constructor(e){super({name:"InvalidParameterValueException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}},cy=class t extends ke{static shapeId="com.amazonaws.cloudwatch#MissingRequiredParameterException";name="MissingRequiredParameterException";$fault="client";constructor(e){super({name:"MissingRequiredParameterException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}},uy=class t extends ke{static shapeId="com.amazonaws.cloudwatch#InvalidNextToken";name="InvalidNextToken";$fault="client";constructor(e){super({name:"InvalidNextToken",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}},ly=class t extends ke{static shapeId="com.amazonaws.cloudwatch#LimitExceededException";name="LimitExceededException";$fault="client";Message;constructor(e){super({name:"LimitExceededException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.Message=e.Message}},dy=class t extends ke{static shapeId="com.amazonaws.cloudwatch#LimitExceededFault";name="LimitExceededFault";$fault="client";constructor(e){super({name:"LimitExceededFault",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}},py=class t extends ke{static shapeId="com.amazonaws.cloudwatch#InvalidFormatFault";name="InvalidFormatFault";$fault="client";constructor(e){super({name:"InvalidFormatFault",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}},fy=class t extends ke{static shapeId="com.amazonaws.cloudwatch#ValidationException";name="ValidationException";$fault="client";constructor(e){super({name:"ValidationException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}},oK="Average",Lc="AlarmActions",mTe="ApproximateAggregateValue",pb="AlarmArn",hTe="AlarmContributor",gTe="AlarmContributorAttributes",iK="AlarmContributorId",fb="AlarmConfigurationUpdatedTimestamp",aK="AlarmContributors",STe="AnomalyDetector",ETe="AnomalyDetectorConfiguration",yTe="AnomalyDetectorExcludedTimeRanges",mb="AnomalyDetectorId",_Te="AnomalyDetectorIds",RTe="AssociateDatasetKmsKey",TTe="AssociateDatasetKmsKeyInput",ATe="AssociateDatasetKmsKeyOutput",ITe="AnomalyDetectorTypes",$c="AlarmDescription",cK="AnomalyDetectors",Fc="ActionsEnabled",xTe="AggregationExpression",CTe="AlarmHistoryItem",uK="AlarmHistoryItems",lK="AccountId",dK="ActionLogLineCount",pK="ActionLogLineRoleArn",fK="AlarmMuteRuleArn",mK="AlarmMuteRuleName",bTe="AlarmMuteRuleSummary",hK="AlarmMuteRuleSummaries",fn="AlarmName",wTe="AlarmNamePrefix",Xd="AlarmNames",gK="ApplyOnTransformedLogs",DTe="ActionPrefix",OTe="AlarmPromQLCriteria",SK="AlarmRule",EK="ActionsSuppressor",vTe="ActionsSuppressedBy",yK="ActionsSuppressorExtensionPeriod",PTe="ActionsSuppressedReason",_K="ActionsSuppressorWaitPeriod",NTe="AdditionalStatistics",kTe="AggregationStatistic",MTe="AlarmType",RK="AlarmTypes",LTe="ApproximateUniqueCount",$Te="AggregateValue",FTe="ApproximateValue",a_="Arn",UTe="Attributes",BTe="BatchFailures",TK="Configuration",GTe="ContributorAttributes",HTe="CompositeAlarm",AK="CompositeAlarms",c_="CreatedAt",IK="CreationDate",VTe="ConflictException",WTe="ContributorId",zTe="ConcurrentModificationException",u_="ComparisonOperator",jTe="ChildrenOfAlarmName",qTe="CreateResourceMetricsConfiguration",KTe="CreateResourceMetricsConfigurationInput",YTe="CreateResourceMetricsConfigurationOutput",QTe="Contributors",JTe="Code",XTe="Counts",gr="Dimensions",xK="DashboardArn",ZTe="DisableAlarmActions",eAe="DisableAlarmActionsInput",tAe="DescribeAlarmContributors",rAe="DescribeAlarmContributorsInput",nAe="DescribeAlarmContributorsOutput",sAe="DeleteAnomalyDetector",oAe="DeleteAnomalyDetectorInput",iAe="DescribeAnomalyDetectorsInput",aAe="DeleteAnomalyDetectorOutput",cAe="DescribeAnomalyDetectorsOutput",uAe="DescribeAnomalyDetectors",lAe="DescribeAlarmsForMetric",dAe="DescribeAlarmsForMetricInput",pAe="DescribeAlarmsForMetricOutput",fAe="DescribeAlarmHistory",mAe="DescribeAlarmHistoryInput",hAe="DescribeAlarmHistoryOutput",gAe="DeleteAlarmsInput",SAe="DescribeAlarmsInput",EAe="DeleteAlarmMuteRule",yAe="DeleteAlarmMuteRuleInput",_Ae="DescribeAlarmsOutput",RAe="DeleteAlarms",TAe="DescribeAlarms",CK="DashboardBody",AAe="DeleteDashboards",IAe="DeleteDashboardsInput",xAe="DisassociateDatasetKmsKey",CAe="DisassociateDatasetKmsKeyInput",bAe="DisassociateDatasetKmsKeyOutput",wAe="DeleteDashboardsOutput",DAe="DashboardEntry",bK="DashboardEntries",OAe="DimensionFilter",vAe="DimensionFilters",hb="DatasetIdentifier",PAe="DashboardInvalidInputError",NAe="DeleteInsightRules",kAe="DeleteInsightRulesInput",MAe="DescribeInsightRulesInput",LAe="DisableInsightRulesInput",$Ae="DeleteInsightRulesOutput",FAe="DescribeInsightRulesOutput",UAe="DisableInsightRulesOutput",BAe="DescribeInsightRules",GAe="DisableInsightRules",HAe="DatasetId",VAe="DeleteMetricStream",WAe="DeleteMetricStreamInput",zAe="DeleteMetricStreamOutput",l_="DashboardName",jAe="DashboardNotFoundError",qAe="DashboardNamePrefix",KAe="DashboardNames",YAe="DataPath",QAe="DeleteResourceMetricsConfiguration",JAe="DeleteResourceMetricsConfigurationInput",XAe="DeleteResourceMetricsConfigurationOutput",wK="DatapointsToAlarm",ZAe="DashboardValidationMessage",DK="DashboardValidationMessages",eIe="Datapoint",gb="Datapoints",OK="Description",tIe="Definition",rIe="Dimension",nIe="Duration",vK="Entity",sIe="EnableAlarmActions",oIe="EnableAlarmActionsInput",Sb="EvaluationCriteria",Eb="ExpireDate",iIe="EndDate",Pi="ExcludeFilters",PK="EvaluationInterval",aIe="EnableInsightRules",cIe="EnableInsightRulesInput",uIe="EnableInsightRulesOutput",NK="EvaluateLowSampleCountPercentile",kK="EntityMetricData",lIe="EntityMetricDataList",MK="EvaluationPeriods",LK="ExtendedStatistics",$K="EvaluationState",yb="ExtendedStatistic",d_="EndTime",dIe="EndTimeOffset",pIe="ExcludedTimeRanges",fIe="ExceptionType",_b="EvaluationWindow",mIe="Entries",FK="Expression",p_="Failures",Rb="FirehoseArn",hIe="FailureCode",gIe="FailureDescription",SIe="FailureResource",EIe="GetAlarmMuteRule",yIe="GetAlarmMuteRuleInput",_Ie="GetAlarmMuteRuleOutput",RIe="GetDashboard",TIe="GetDashboardInput",AIe="GetDatasetInput",IIe="GetDashboardOutput",xIe="GetDatasetOutput",CIe="GetDataset",bIe="GetInsightRuleReport",wIe="GetInsightRuleReportInput",DIe="GetInsightRuleReportOutput",OIe="GetMetricData",vIe="GetMetricDataInput",PIe="GetMetricDataOutput",NIe="GetMetricStatistics",kIe="GetMetricStatisticsInput",MIe="GetMetricStreamInput",LIe="GetMetricStatisticsOutput",$Ie="GetMetricStreamOutput",FIe="GetMetricStream",UIe="GetMetricWidgetImage",BIe="GetMetricWidgetImageInput",GIe="GetMetricWidgetImageOutput",HIe="GetOTelEnrichment",VIe="GetOTelEnrichmentInput",WIe="GetOTelEnrichmentOutput",zIe="GetResourceMetricsConfiguration",jIe="GetResourceMetricsConfigurationInput",qIe="GetResourceMetricsConfigurationOutput",KIe="HistoryData",UK="HistoryItemType",YIe="HistorySummary",BK="Id",Uc="InsufficientDataActions",Ni="IncludeFilters",QIe="InvalidFormatFault",JIe="IncludeLinkedAccounts",GK="IncludeLinkedAccountsMetrics",HK="IncludeMetrics",XIe="InvalidNextToken",ZIe="InvalidParameterCombinationException",exe="InvalidParameterValueException",VK="InsightRules",txe="InsightRuleContributor",rxe="InsightRuleContributorDatapoint",nxe="InsightRuleContributorDatapoints",sxe="InsightRuleContributors",oxe="InsightRuleMetricDatapoint",ixe="InsightRuleMetricDatapoints",axe="InsightRule",cxe="InternalServiceFault",uxe="Keys",lxe="KeyAttributes",dxe="KmsAccessDeniedException",WK="KmsKeyArn",pxe="KmsKeyDisabledException",fxe="KmsKeyNotFoundException",mxe="KeyLabels",hxe="Key",Tb="Label",zK="LogAlarms",gxe="ListAlarmMuteRules",Sxe="ListAlarmMuteRulesInput",Exe="ListAlarmMuteRulesOutput",yxe="LogAlarm",_xe="ListDashboards",Rxe="ListDashboardsInput",Txe="ListDashboardsOutput",Axe="LimitExceededException",Ixe="LimitExceededFault",xxe="LogGroupIdentifiers",Cxe="LastModified",bxe="ListMetricsInput",wxe="ListManagedInsightRules",Dxe="ListManagedInsightRulesInput",Oxe="ListManagedInsightRulesOutput",vxe="ListMetricsOutput",Pxe="ListMetricStreams",Nxe="ListMetricStreamsInput",kxe="ListMetricStreamsOutput",Mxe="ListMetrics",jK="LabelOptions",Lxe="ListTagsForResource",$xe="ListTagsForResourceInput",Fxe="ListTagsForResourceOutput",qK="LastUpdateDate",KK="LastUpdatedTimestamp",Hs="Message",Ab="MetricAlarms",Uxe="MetricAlarm",Ib="MetricCharacteristics",Bxe="MaxContributorCount",Gxe="MaxContributorValue",xb="MetricData",Cb="MetricDataQueries",Hxe="MetricDataQuery",YK="MetricDataResults",Vxe="MetricDataResultMessages",Wxe="MetricDataResult",zxe="MaxDatapoints",jxe="MetricDatapoints",qxe="MessageData",Kxe="MetricDatum",f_="MetricMathAnomalyDetector",Sr="MetricName",QK="MetricNames",bb="MaxRecords",Yxe="ManagedRuleDescription",Qxe="ManagedRuleDescriptions",Jxe="MissingRequiredParameterException",Xxe="ManagedRuleState",m_="MaxResults",JK="ManagedRule",wb="ManagedRules",Db="MetricSelections",Zxe="MetricStreamEntry",eCe="MetricStreamEntries",tCe="MetricStreamFilter",rCe="MetricStreamFilters",nCe="MetricStreamStatisticsConfiguration",sCe="MetricStreamStatisticsConfigurations",oCe="MetricStreamStatisticsIncludeMetrics",iCe="MetricStreamStatisticsMetric",XK="MetricStat",ZK="MuteType",aCe="MetricTimezone",Ob="MuteTargets",cCe="MetricWidget",uCe="MetricWidgetImage",vb="Maximum",Zd="Metrics",e8="Messages",t8="Metric",Pb="Minimum",zt="Namespace",Be="NextToken",Es="Name",r8="Names",lCe="OwningAccount",dCe="OwningAccounts",pCe="OrderBy",h_="OutputFormat",Bc="OKActions",fCe="OnlyStartEvaluatingAfterWarmUpPeriodEnds",mCe="OTelEnrichmentMetricSelector",hCe="OTelEnrichmentMetricSelectorList",ki="Period",gCe="PutAnomalyDetector",SCe="PutAnomalyDetectorInput",ECe="PutAnomalyDetectorOutput",yCe="PutAlarmMuteRule",_Ce="PutAlarmMuteRuleInput",RCe="PutCompositeAlarm",TCe="PutCompositeAlarmInput",ACe="PutDashboard",ICe="PutDashboardInput",xCe="PutDashboardOutput",CCe="PartialFailure",bCe="PutInsightRule",wCe="PutInsightRuleInput",DCe="PutInsightRuleOutput",OCe="PutLogAlarm",vCe="PutLogAlarmInput",PCe="PutMetricAlarm",NCe="PutMetricAlarmInput",kCe="PutMetricData",MCe="PutMetricDataInput",LCe="PutManagedInsightRules",$Ce="PutManagedInsightRulesInput",FCe="PutManagedInsightRulesOutput",UCe="PutMetricStream",BCe="PutMetricStreamInput",GCe="PutMetricStreamOutput",HCe="ParentsOfAlarmName",VCe="PendingPeriod",WCe="PromQLCriteria",zCe="PeriodicSpikes",jCe="Query",qCe="QueryARN",n8="QueryResultsToAlarm",s8="QueryResultsToEvaluate",KCe="QueryString",Nb="Rule",ep="ResourceArn",Gc="ResourceARN",YCe="RecentlyActive",o8="RoleArn",QCe="ResourceConflict",JCe="ReturnData",XCe="RuleDefinition",ZCe="ResourceId",g_="ResourceMetricsConfiguration",ebe="ResourceMetricSelection",tbe="ResourceMetricSelectionList",kb="RuleNames",rbe="ResourceNotFound",nbe="ResourceNotFoundException",Mb="RuleName",sbe="RecoveryPeriod",i8="RuleState",obe="ResourceType",ibe="Range",Lb="Status",abe="SetAlarmState",cbe="SetAlarmStateInput",a8="ScanBy",$b="SampleCount",c8="ScheduleConfiguration",u8="StatisticsConfigurations",ube="StatusCode",Fb="StartDate",lbe="ScheduleExpression",dbe="StrictEntityValidation",S_="SingleMetricAnomalyDetector",pbe="StartMetricStreams",fbe="StartMetricStreamsInput",mbe="StopMetricStreamsInput",hbe="StartMetricStreamsOutput",gbe="StopMetricStreamsOutput",Sbe="StopMetricStreams",Ebe="StartOTelEnrichment",ybe="StartOTelEnrichmentInput",_be="StopOTelEnrichmentInput",Rbe="StartOTelEnrichmentOutput",Tbe="StopOTelEnrichmentOutput",Abe="StopOTelEnrichment",Ub="ScheduledQueryConfiguration",Ibe="ScheduledQueryRoleARN",tp="StateReason",E_="StateReasonData",xbe="StorageResolution",Cbe="StatisticSet",y_="StartTime",bbe="StartTimeOffset",__="StateTransitionedTimestamp",Bb="StateUpdatedTimestamp",Hc="StateValue",wbe="StatisticValues",l8="SlidingWindow",Dbe="Schema",d8="Schedule",Obe="Size",rp="Stat",Gb="Statistic",vbe="Statistics",R_="State",Pbe="Statuses",Hb="Sum",np="Timestamp",Nbe="TagKeys",kbe="TagList",T_="TreatMissingData",p8="ThresholdMetricId",f8="TemplateName",Mbe="TagResource",Lbe="TagResourceInput",$be="TagResourceOutput",mn="Tags",Fbe="Tag",A_="Threshold",Vb="Timezone",Ube="Timestamps",Mi="Unit",I_="UpdatedAt",Bbe="UniqueContributors",Gbe="UpdateOTelEnrichment",Hbe="UpdateOTelEnrichmentInput",Vbe="UpdateOTelEnrichmentOutput",Wbe="UntagResource",zbe="UntagResourceInput",jbe="UpdateResourceMetricsConfiguration",qbe="UpdateResourceMetricsConfigurationInput",Kbe="UpdateResourceMetricsConfigurationOutput",Ybe="UntagResourceOutput",sp="Value",Qbe="ValidationException",m8="Values",h8="WallClockWindow",op="WarmUpConfiguration",Jbe="WarmUpPeriodDurationInMinutes",jt="awsQueryError",St="client",Xbe="dashboardValidationMessages",ot="error",Mt="httpError",hn="message",g8="smithy.ts.sdk.synthetic.com.amazonaws.cloudwatch",Zbe="server",y="com.amazonaws.cloudwatch",S8=new nK(g8),E8=[-3,g8,"CloudWatchServiceException",0,[],[]];S8.registerError(E8,ke);var Ye=new nK(y),y8=[-3,y,zTe,{[jt]:["ConcurrentModificationException",429],[ot]:St,[Mt]:429},[Hs],[0]];Ye.registerError(y8,ey);var _8=[-3,y,VTe,{[ot]:St,[Mt]:409},[Hs],[0]];Ye.registerError(_8,YE);var R8=[-3,y,PAe,{[jt]:["InvalidParameterInput",400],[ot]:St,[Mt]:400},[hn,Xbe],[0,()=>y7]];Ye.registerError(R8,ty);var T8=[-3,y,jAe,{[jt]:["ResourceNotFound",404],[ot]:St,[Mt]:404},[hn],[0]];Ye.registerError(T8,ry);var A8=[-3,y,cxe,{[jt]:["InternalServiceError",500],[ot]:Zbe,[Mt]:500},[Hs],[0]];Ye.registerError(A8,oy);var I8=[-3,y,QIe,{[jt]:["InvalidFormat",400],[ot]:St,[Mt]:400},[hn],[0]];Ye.registerError(I8,py);var x8=[-3,y,XIe,{[jt]:["InvalidNextToken",400],[ot]:St,[Mt]:400},[hn],[0]];Ye.registerError(x8,uy);var C8=[-3,y,ZIe,{[jt]:["InvalidParameterCombination",400],[ot]:St,[Mt]:400},[hn],[0]];Ye.registerError(C8,iy);var b8=[-3,y,exe,{[jt]:["InvalidParameterValue",400],[ot]:St,[Mt]:400},[hn],[0]];Ye.registerError(b8,ay);var w8=[-3,y,dxe,{[ot]:St},[Hs],[0],1];Ye.registerError(w8,QE);var D8=[-3,y,pxe,{[ot]:St},[Hs],[0],1];Ye.registerError(D8,JE);var O8=[-3,y,fxe,{[ot]:St},[Hs],[0],1];Ye.registerError(O8,XE);var v8=[-3,y,Axe,{[jt]:["LimitExceededException",400],[ot]:St,[Mt]:400},[Hs],[0]];Ye.registerError(v8,ly);var P8=[-3,y,Ixe,{[jt]:["LimitExceeded",400],[ot]:St,[Mt]:400},[hn],[0]];Ye.registerError(P8,dy);var N8=[-3,y,Jxe,{[jt]:["MissingParameter",400],[ot]:St,[Mt]:400},[hn],[0]];Ye.registerError(N8,cy);var k8=[-3,y,QCe,{[jt]:["ResourceConflict",409],[ot]:St,[Mt]:409},[hn],[0]];Ye.registerError(k8,ny);var M8=[-3,y,rbe,{[jt]:["ResourceNotFound",404],[ot]:St,[Mt]:404},[hn],[0]];Ye.registerError(M8,sy);var L8=[-3,y,nbe,{[jt]:["ResourceNotFoundException",404],[ot]:St,[Mt]:404},[obe,ZCe,Hs],[0,0,0]];Ye.registerError(L8,ZE);var $8=[-3,y,Qbe,{[jt]:["ValidationError",400],[ot]:St,[Mt]:400},[hn],[0]];Ye.registerError($8,fy);var F8=[S8,Ye],U8=[3,y,hTe,0,[WTe,GTe,tp,__],[0,128,0,4],3],B8=[3,y,CTe,0,[fn,iK,MTe,np,UK,YIe,KIe,gTe],[0,0,0,4,0,0,0,128]],G8=[3,y,bTe,0,[fK,Eb,Lb,ZK,KK],[0,4,0,0,4]],H8=[3,y,OTe,0,[jCe,VCe,sbe],[0,1,1],1],V8=[3,y,STe,0,[mb,zt,Sr,gr,rp,TK,Hc,Ib,S_,f_],[0,0,0,()=>gn,0,()=>Wb,0,()=>jb,()=>b_,()=>x_]],Wb=[3,y,ETe,0,[pIe,aCe],[()=>nwe,0]],W8=[3,y,TTe,0,[hb,WK],[0,0],2],z8=[3,y,ATe,0,[],[]],j8=[3,y,HTe,0,[Fc,Lc,pb,fb,$c,fn,SK,Uc,Bc,tp,E_,Bb,Hc,__,vTe,PTe,EK,_K,yK],[2,64,0,4,0,0,0,64,64,0,0,4,0,4,0,0,0,1,1]],q8=[3,y,KTe,0,[ep,Db],[0,()=>Qb],1],K8=[3,y,YTe,0,[g_],[()=>C_],1],Y8=[3,y,DAe,0,[l_,xK,Cxe,Obe],[0,0,4,1]],Q8=[3,y,ZAe,0,[YAe,Hs],[0,0]],J8=[3,y,eIe,0,[np,$b,oK,Hb,Pb,vb,Mi,LK],[4,1,1,1,1,1,0,129]],X8=[3,y,yAe,0,[mK],[0],1],Z8=[3,y,gAe,0,[Xd],[64],1],e5=[3,y,oAe,0,[mb,zt,Sr,gr,rp,S_,f_],[0,0,0,()=>gn,0,()=>b_,()=>x_]],t5=[3,y,aAe,0,[],[]],r5=[3,y,IAe,0,[KAe],[64],1],n5=[3,y,wAe,0,[],[]],s5=[3,y,kAe,0,[kb],[64],1],o5=[3,y,$Ae,0,[p_],[()=>w_]],i5=[3,y,WAe,0,[Es],[0],1],a5=[3,y,zAe,0,[],[]],c5=[3,y,JAe,0,[ep],[0],1],u5=[3,y,XAe,0,[],[]],l5=[3,y,rAe,0,[fn,Be],[0,0],1],d5=[3,y,nAe,0,[aK,Be],[()=>ewe,0],1],p5=[3,y,mAe,0,[fn,iK,RK,UK,Fb,iIe,bb,Be,a8],[0,0,64,0,4,4,1,0,0]],f5=[3,y,hAe,0,[uK,Be],[()=>twe,0]],m5=[3,y,dAe,0,[Sr,zt,Gb,yb,gr,ki,Mi],[0,0,0,0,()=>gn,1,0],2],h5=[3,y,pAe,0,[Ab],[()=>_7]],g5=[3,y,SAe,0,[Xd,wTe,RK,jTe,HCe,Hc,DTe,bb,Be],[64,0,64,0,0,0,0,1,0]],S5=[3,y,_Ae,0,[AK,Ab,zK,Be],[()=>owe,()=>_7,()=>mwe,0]],E5=[3,y,iAe,0,[_Te,Be,m_,zt,Sr,gr,ITe],[64,0,1,0,0,()=>gn,64]],y5=[3,y,cAe,0,[cK,Be],[()=>swe,0]],_5=[3,y,MAe,0,[Be,m_],[0,1]],R5=[3,y,FAe,0,[Be,VK],[0,()=>fwe]],T5=[3,y,rIe,0,[Es,sp],[0,0],2],A5=[3,y,OAe,0,[Es,sp],[0,0],1],I5=[3,y,eAe,0,[Xd],[64],1],x5=[3,y,LAe,0,[kb],[64],1],C5=[3,y,UAe,0,[p_],[()=>w_]],b5=[3,y,CAe,0,[hb],[0],1],w5=[3,y,bAe,0,[],[]],D5=[3,y,oIe,0,[Xd],[64],1],O5=[3,y,cIe,0,[kb],[64],1],v5=[3,y,uIe,0,[p_],[()=>w_]],P5=[3,y,vK,0,[lxe,UTe],[128,128]],N5=[3,y,kK,0,[vK,xb],[()=>P5,()=>R7]],k5=[3,y,yIe,0,[mK],[0],1],M5=[3,y,_Ie,0,[Es,fK,OK,Nb,Ob,Fb,Eb,Lb,KK,ZK],[0,0,0,()=>Kb,()=>qb,4,4,0,4,0]],L5=[3,y,TIe,0,[l_],[0],1],$5=[3,y,IIe,0,[xK,CK,l_],[0,0,0]],F5=[3,y,AIe,0,[hb],[0],1],U5=[3,y,xIe,0,[HAe,a_,WK],[0,0,0],2],B5=[3,y,wIe,0,[Mb,y_,d_,ki,Bxe,Zd,pCe],[0,4,4,1,1,64,0],4],G5=[3,y,DIe,0,[mxe,kTe,$Te,LTe,QTe,jxe],[64,0,1,1,()=>dwe,()=>pwe]],H5=[3,y,vIe,0,[Cb,y_,d_,Be,a8,zxe,jK],[()=>D_,4,4,0,0,1,()=>s9],3],V5=[3,y,PIe,0,[YK,Be,e8],[()=>Swe,0,()=>T7]],W5=[3,y,kIe,0,[zt,Sr,y_,d_,ki,gr,vbe,LK,Mi],[0,0,4,4,1,()=>gn,64,64,0],5],z5=[3,y,LIe,0,[Tb,gb],[0,()=>awe]],j5=[3,y,MIe,0,[Es],[0],1],q5=[3,y,$Ie,0,[a_,Es,Ni,Pi,Rb,o8,R_,IK,qK,h_,u8,GK],[0,0,()=>my,()=>my,0,0,0,4,4,0,()=>A7,2]],K5=[3,y,BIe,0,[cCe,h_],[0,0],1],Y5=[3,y,GIe,0,[uCe],[21]],Q5=[3,y,VIe,0,[],[]],J5=[3,y,WIe,0,[Lb,Ni,Pi,c_,I_],[0,()=>gs,()=>gs,4,4],1],X5=[3,y,jIe,0,[ep],[0],1],Z5=[3,y,qIe,0,[g_],[()=>C_],1],e9=[3,y,axe,0,[Es,R_,Dbe,tIe,JK,gK],[0,0,0,0,2,2],4],t9=[3,y,txe,0,[uxe,mTe,gb],[64,1,()=>lwe],3],r9=[3,y,rxe,0,[np,FTe],[4,1],2],n9=[3,y,oxe,0,[np,Bbe,Gxe,$b,oK,Hb,Pb,vb],[4,1,1,1,1,1,1,1],1],s9=[3,y,jK,0,[Vb],[0]],o9=[3,y,Sxe,0,[fn,Pbe,bb,Be],[0,64,1,0]],i9=[3,y,Exe,0,[hK,Be],[()=>rwe,0]],a9=[3,y,Rxe,0,[qAe,Be],[0,0]],c9=[3,y,Txe,0,[bK,Be],[()=>iwe,0]],u9=[3,y,Dxe,0,[Gc,Be,m_],[0,0,1],1],l9=[3,y,Oxe,0,[wb,Be],[()=>hwe,0]],d9=[3,y,bxe,0,[zt,Sr,gr,Be,YCe,JIe,lCe],[0,0,()=>cwe,0,0,2,0]],p9=[3,y,vxe,0,[Zd,Be,dCe],[()=>Ewe,0,64]],f9=[3,y,Nxe,0,[Be,m_],[0,1]],m9=[3,y,kxe,0,[Be,mIe],[0,()=>ywe]],h9=[3,y,$xe,0,[Gc],[0],1],g9=[3,y,Fxe,0,[mn],[()=>Sn]],S9=[3,y,yxe,0,[fn,pb,$c,fb,Fc,Bc,Lc,Uc,Hc,tp,E_,Bb,Ub,s8,n8,A_,u_,T_,__,$K,dK,pK,op],[0,0,0,4,2,64,64,64,0,0,0,4,()=>Yb,1,1,1,0,0,4,0,1,0,()=>ip]],E9=[3,y,JK,0,[f8,Gc,mn],[0,0,()=>Sn],2],y9=[3,y,Yxe,0,[f8,Gc,i8],[0,0,()=>_9]],_9=[3,y,Xxe,0,[Mb,R_],[0,0],2],R9=[3,y,qxe,0,[JTe,sp],[0,0]],zb=[3,y,t8,0,[zt,Sr,gr],[0,0,()=>gn]],T9=[3,y,Uxe,0,[fn,pb,$c,fb,Fc,Bc,Lc,Uc,Hc,tp,E_,Bb,Sr,zt,Gb,yb,gr,ki,Mi,MK,wK,A_,u_,T_,NK,Zd,p8,$K,__,_b,op,Sb,PK],[0,0,0,4,2,64,64,64,0,0,0,4,0,0,0,0,()=>gn,1,0,1,1,1,0,0,0,()=>D_,0,0,4,()=>Xb,()=>ip,()=>Jb,1]],jb=[3,y,Ib,0,[zCe],[2]],A9=[3,y,Hxe,0,[BK,XK,FK,Tb,JCe,ki,lK],[0,()=>C9,0,0,2,1,0],1],I9=[3,y,Wxe,0,[BK,Tb,Ube,m8,ube,e8],[0,0,68,65,0,()=>T7]],x9=[3,y,Kxe,0,[Sr,gr,np,sp,wbe,m8,XTe,Mi,xbe],[0,()=>gn,4,1,()=>s7,65,65,0,1],1],x_=[3,y,f_,0,[Cb],[()=>D_]],C9=[3,y,XK,0,[t8,ki,rp,Mi],[()=>zb,1,0,0],3],b9=[3,y,Zxe,0,[a_,IK,qK,Es,Rb,R_,h_],[0,4,4,0,0,0,0]],w9=[3,y,tCe,0,[zt,QK],[0,64]],D9=[3,y,nCe,0,[HK,NTe],[()=>_we,64],2],O9=[3,y,iCe,0,[zt,Sr],[0,0],2],qb=[3,y,Ob,0,[Xd],[64],1],v9=[3,y,mCe,0,[zt,QK],[0,64],1],P9=[3,y,CCe,0,[SIe,fIe,hIe,gIe],[0,0,0,0]],N9=[3,y,_Ce,0,[Es,Nb,OK,Ob,mn,Fb,Eb],[0,()=>Kb,0,()=>qb,()=>Sn,4,4],2],k9=[3,y,SCe,0,[zt,Sr,gr,rp,TK,Ib,S_,f_],[0,0,()=>gn,0,()=>Wb,()=>jb,()=>b_,()=>x_]],M9=[3,y,ECe,0,[mb],[0]],L9=[3,y,TCe,0,[fn,SK,Fc,Lc,$c,Uc,Bc,mn,EK,_K,yK],[0,0,2,64,0,64,64,()=>Sn,0,1,1],2],$9=[3,y,ICe,0,[l_,CK,mn],[0,0,()=>Sn],2],F9=[3,y,xCe,0,[DK],[()=>y7]],U9=[3,y,wCe,0,[Mb,XCe,i8,mn,gK],[0,0,0,()=>Sn,2],2],B9=[3,y,DCe,0,[],[]],G9=[3,y,vCe,0,[fn,Ub,s8,n8,A_,u_,$c,dK,pK,Fc,Bc,Lc,Uc,T_,mn,op],[0,()=>Yb,1,1,1,0,0,1,0,2,64,64,64,0,()=>Sn,()=>ip],6],H9=[3,y,$Ce,0,[wb],[()=>gwe],1],V9=[3,y,FCe,0,[p_],[()=>w_]],W9=[3,y,NCe,0,[fn,$c,Fc,Bc,Lc,Uc,Sr,zt,Gb,yb,gr,ki,Mi,MK,wK,A_,u_,T_,NK,Zd,mn,p8,_b,op,Sb,PK],[0,0,2,64,64,64,0,0,0,0,()=>gn,1,0,1,1,1,0,0,0,()=>D_,()=>Sn,0,()=>Xb,()=>ip,()=>Jb,1],1],z9=[3,y,MCe,0,[zt,xb,kK,dbe],[0,()=>R7,()=>uwe,2],1],j9=[3,y,BCe,0,[Es,Rb,o8,h_,Ni,Pi,mn,u8,GK],[0,0,0,0,()=>my,()=>my,()=>Sn,()=>A7,2],4],q9=[3,y,GCe,0,[a_],[0]],K9=[3,y,ibe,0,[y_,d_],[4,4],2],C_=[3,y,g_,0,[ep,c_,I_,Db],[0,4,4,()=>Qb],3],Y9=[3,y,ebe,0,[HK],[64],1],Kb=[3,y,Nb,0,[d8],[()=>Q9],1],Q9=[3,y,d8,0,[FK,nIe,Vb],[0,0,0],2],J9=[3,y,c8,0,[lbe,bbe,dIe],[0,1,1],2],Yb=[3,y,Ub,0,[KCe,Ibe,c8,xTe,xxe,qCe,mn],[0,0,()=>J9,0,64,0,()=>Sn],4],X9=[3,y,cbe,0,[fn,Hc,tp,E_],[0,0,0,0],3],b_=[3,y,S_,0,[lK,zt,Sr,gr,rp],[0,0,0,()=>gn,0]],Z9=[3,y,l8,0,[],[]],e7=[3,y,fbe,0,[r8],[64],1],t7=[3,y,hbe,0,[],[]],r7=[3,y,ybe,0,[Ni,Pi],[()=>gs,()=>gs]],n7=[3,y,Rbe,0,[Ni,Pi,c_,I_],[()=>gs,()=>gs,4,4]],s7=[3,y,Cbe,0,[$b,Hb,Pb,vb],[1,1,1,1],4],o7=[3,y,mbe,0,[r8],[64],1],i7=[3,y,gbe,0,[],[]],a7=[3,y,_be,0,[],[]],c7=[3,y,Tbe,0,[],[]],u7=[3,y,Fbe,0,[hxe,sp],[0,0],2],l7=[3,y,Lbe,0,[Gc,mn],[0,()=>Sn],2],d7=[3,y,$be,0,[],[]],p7=[3,y,zbe,0,[Gc,Nbe],[0,64],2],f7=[3,y,Ybe,0,[],[]],m7=[3,y,Hbe,0,[Ni,Pi],[()=>gs,()=>gs]],h7=[3,y,Vbe,0,[Ni,Pi,c_,I_],[()=>gs,()=>gs,4,4]],g7=[3,y,qbe,0,[ep,Db],[0,()=>Qb],1],S7=[3,y,Kbe,0,[g_],[()=>C_],1],E7=[3,y,h8,0,[Vb],[0]],ip=[3,y,op,0,[Jbe,fCe],[1,2],1],ys="unit",ewe=[1,y,aK,0,()=>U8],twe=[1,y,uK,0,()=>B8],rwe=[1,y,hK,0,()=>G8],nwe=[1,y,yTe,0,()=>K9],swe=[1,y,cK,0,()=>V8],w_=[1,y,BTe,0,()=>P9],owe=[1,y,AK,0,()=>j8],iwe=[1,y,bK,0,()=>Y8],y7=[1,y,DK,0,()=>Q8],awe=[1,y,gb,0,()=>J8],cwe=[1,y,vAe,0,()=>A5],gn=[1,y,gr,0,()=>T5],uwe=[1,y,lIe,0,()=>N5],lwe=[1,y,nxe,0,()=>r9],dwe=[1,y,sxe,0,()=>t9],pwe=[1,y,ixe,0,()=>n9],fwe=[1,y,VK,0,()=>e9],mwe=[1,y,zK,0,()=>S9],hwe=[1,y,Qxe,0,()=>y9],gwe=[1,y,wb,0,()=>E9],_7=[1,y,Ab,0,()=>T9],R7=[1,y,xb,0,()=>x9],D_=[1,y,Cb,0,()=>A9],T7=[1,y,Vxe,0,()=>R9],Swe=[1,y,YK,0,()=>I9],Ewe=[1,y,Zd,0,()=>zb],ywe=[1,y,eCe,0,()=>b9],my=[1,y,rCe,0,()=>w9],A7=[1,y,sCe,0,()=>D9],_we=[1,y,oCe,0,()=>O9],gs=[1,y,hCe,0,()=>v9],Qb=[1,y,tbe,0,()=>Y9],Sn=[1,y,kbe,0,()=>u7],Jb=[4,y,Sb,0,[WCe],[()=>H8]],Xb=[4,y,_b,0,[h8,l8],[()=>E7,()=>Z9]],I7=[9,y,RTe,0,()=>W8,()=>z8],x7=[9,y,qTe,0,()=>q8,()=>K8],C7=[9,y,EAe,0,()=>X8,()=>ys],b7=[9,y,RAe,0,()=>Z8,()=>ys],w7=[9,y,sAe,0,()=>e5,()=>t5],D7=[9,y,AAe,0,()=>r5,()=>n5],O7=[9,y,NAe,0,()=>s5,()=>o5],v7=[9,y,VAe,0,()=>i5,()=>a5],P7=[9,y,QAe,0,()=>c5,()=>u5],N7=[9,y,tAe,0,()=>l5,()=>d5],k7=[9,y,fAe,0,()=>p5,()=>f5],M7=[9,y,TAe,0,()=>g5,()=>S5],L7=[9,y,lAe,0,()=>m5,()=>h5],$7=[9,y,uAe,0,()=>E5,()=>y5],F7=[9,y,BAe,0,()=>_5,()=>R5],U7=[9,y,ZTe,0,()=>I5,()=>ys],B7=[9,y,GAe,0,()=>x5,()=>C5],G7=[9,y,xAe,2,()=>b5,()=>w5],H7=[9,y,sIe,0,()=>D5,()=>ys],V7=[9,y,aIe,0,()=>O5,()=>v5],W7=[9,y,EIe,0,()=>k5,()=>M5],z7=[9,y,RIe,0,()=>L5,()=>$5],j7=[9,y,CIe,0,()=>F5,()=>U5],q7=[9,y,bIe,0,()=>B5,()=>G5],K7=[9,y,OIe,0,()=>H5,()=>V5],Y7=[9,y,NIe,0,()=>W5,()=>z5],Q7=[9,y,FIe,0,()=>j5,()=>q5],J7=[9,y,UIe,0,()=>K5,()=>Y5],X7=[9,y,HIe,0,()=>Q5,()=>J5],Z7=[9,y,zIe,0,()=>X5,()=>Z5],eY=[9,y,gxe,0,()=>o9,()=>i9],tY=[9,y,_xe,0,()=>a9,()=>c9],rY=[9,y,wxe,0,()=>u9,()=>l9],nY=[9,y,Mxe,0,()=>d9,()=>p9],sY=[9,y,Pxe,0,()=>f9,()=>m9],oY=[9,y,Lxe,0,()=>h9,()=>g9],iY=[9,y,yCe,0,()=>N9,()=>ys],aY=[9,y,gCe,0,()=>k9,()=>M9],cY=[9,y,RCe,0,()=>L9,()=>ys],uY=[9,y,ACe,0,()=>$9,()=>F9],lY=[9,y,bCe,0,()=>U9,()=>B9],dY=[9,y,OCe,0,()=>G9,()=>ys],pY=[9,y,LCe,0,()=>H9,()=>V9],fY=[9,y,PCe,0,()=>W9,()=>ys],mY=[9,y,kCe,0,()=>z9,()=>ys],hY=[9,y,UCe,0,()=>j9,()=>q9],gY=[9,y,abe,0,()=>X9,()=>ys],SY=[9,y,pbe,0,()=>e7,()=>t7],EY=[9,y,Ebe,0,()=>r7,()=>n7],yY=[9,y,Sbe,0,()=>o7,()=>i7],_Y=[9,y,Abe,0,()=>a7,()=>c7],RY=[9,y,Mbe,0,()=>l7,()=>d7],TY=[9,y,Wbe,0,()=>p7,()=>f7],AY=[9,y,Gbe,0,()=>m7,()=>h7],IY=[9,y,jbe,0,()=>g7,()=>S7],Rwe=t=>({apiVersion:"2010-08-01",base64Decoder:t?.base64Decoder??Y0e,base64Encoder:t?.base64Encoder??K0e,disableHostPrefix:t?.disableHostPrefix??!1,endpointProvider:t?.endpointProvider??fTe,extensions:t?.extensions??[],httpAuthSchemeProvider:t?.httpAuthSchemeProvider??nTe,httpAuthSchemes:t?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:e=>e.getIdentityProvider("aws.auth#sigv4"),signer:new V0e}],logger:t?.logger??new c0e,protocol:t?.protocol??Z0e,protocolSettings:t?.protocolSettings??{defaultNamespace:"com.amazonaws.cloudwatch",errorTypeRegistries:F8,xmlNamespace:"http://monitoring.amazonaws.com/doc/2010-08-01/",version:"2010-08-01",serviceTarget:"GraniteServiceVersion20100801",awsQueryCompatible:!0},serviceId:t?.serviceId??"CloudWatch",sha256:t?.sha256??eTe,urlParser:t?.urlParser??w0e,utf8Decoder:t?.utf8Decoder??q0e,utf8Encoder:t?.utf8Encoder??j0e}),Twe=t=>{u0e(process.version);let e=g0e(t),r=()=>e().then(l0e),n=Rwe(t);jRe(process.version);let s={profile:t?.profile,logger:n.logger};return{...n,...t,runtime:"node",defaultsMode:e,authSchemePreference:t?.authSchemePreference??Bs(W0e,s),bodyLengthChecker:t?.bodyLengthChecker??Q0e,credentialDefaultProvider:t?.credentialDefaultProvider??z0e,defaultUserAgentProvider:t?.defaultUserAgentProvider??qRe({serviceId:n.serviceId,clientVersion:cTe.version}),disableRequestCompression:t?.disableRequestCompression??Bs(U0e,t),maxAttempts:t?.maxAttempts??Bs(k0e,t),region:t?.region??Bs(y0e,{..._0e,...s}),requestHandler:X0e.create(t?.requestHandler??r),requestMinCompressionSizeBytes:t?.requestMinCompressionSizeBytes??Bs(F0e,t),retryMode:t?.retryMode??Bs({...N0e,default:async()=>(await r()).retryMode||P0e},t),streamCollector:t?.streamCollector??J0e,useDualstackEndpoint:t?.useDualstackEndpoint??Bs(E0e,s),useFipsEndpoint:t?.useFipsEndpoint??Bs(S0e,s),userAgentAppId:t?.userAgentAppId??Bs(KRe,s)}},Awe=t=>{let e=t.httpAuthSchemes,r=t.httpAuthSchemeProvider,n=t.credentials;return{setHttpAuthScheme(s){let o=e.findIndex(i=>i.schemeId===s.schemeId);o===-1?e.push(s):e.splice(o,1,s)},httpAuthSchemes(){return e},setHttpAuthSchemeProvider(s){r=s},httpAuthSchemeProvider(){return r},setCredentials(s){n=s},credentials(){return n}}},Iwe=t=>({httpAuthSchemes:t.httpAuthSchemes(),httpAuthSchemeProvider:t.httpAuthSchemeProvider(),credentials:t.credentials()}),xwe=(t,e)=>{let r=Object.assign(YRe(t),d0e(t),D0e(t),Awe(t));return e.forEach(n=>n.configure(r)),Object.assign(t,QRe(r),p0e(r),O0e(r),Iwe(r))},or=class extends rK{config;constructor(...[e]){let r=Twe(e||{});super(r),this.initConfig=r;let n=oTe(r),s=JRe(n),o=M0e(s),i=R0e(o),a=XRe(i),c=C0e(a),u=sTe(c),p=B0e(u),d=xwe(p,e?.extensions||[]);this.config=d,this.middlewareStack.use($0e(this.config)),this.middlewareStack.use(ZRe(this.config)),this.middlewareStack.use(L0e(this.config)),this.middlewareStack.use(v0e(this.config)),this.middlewareStack.use(e0e(this.config)),this.middlewareStack.use(t0e(this.config)),this.middlewareStack.use(r0e(this.config)),this.middlewareStack.use(n0e(this.config,{httpAuthSchemeParametersProvider:tTe,identityProviderConfigProvider:async m=>new s0e({"aws.auth#sigv4":m.credentials})})),this.middlewareStack.use(o0e(this.config))}destroy(){super.destroy()}},U=f0e(iTe,"GraniteServiceVersion20100801","CloudWatchClient",b0e),B={},H=(t,e,r,n)=>[],Cwe=(t,e,r,n)=>[G0e(r,{encodings:["gzip"]})],hy=class extends U(B,H,"AssociateDatasetKmsKey",I7){},gy=class extends U(B,H,"CreateResourceMetricsConfiguration",x7){},Sy=class extends U(B,H,"DeleteAlarmMuteRule",C7){},Ey=class extends U(B,H,"DeleteAlarms",b7){},yy=class extends U(B,H,"DeleteAnomalyDetector",w7){},_y=class extends U(B,H,"DeleteDashboards",D7){},Ry=class extends U(B,H,"DeleteInsightRules",O7){},Ty=class extends U(B,H,"DeleteMetricStream",v7){},Ay=class extends U(B,H,"DeleteResourceMetricsConfiguration",P7){},Iy=class extends U(B,H,"DescribeAlarmContributors",N7){},Hd=class extends U(B,H,"DescribeAlarmHistory",k7){},Bo=class extends U(B,H,"DescribeAlarms",M7){},xy=class extends U(B,H,"DescribeAlarmsForMetric",L7){},Vd=class extends U(B,H,"DescribeAnomalyDetectors",$7){},Wd=class extends U(B,H,"DescribeInsightRules",F7){},Cy=class extends U(B,H,"DisableAlarmActions",U7){},by=class extends U(B,H,"DisableInsightRules",B7){},wy=class extends U(B,H,"DisassociateDatasetKmsKey",G7){},Dy=class extends U(B,H,"EnableAlarmActions",H7){},Oy=class extends U(B,H,"EnableInsightRules",V7){},zd=class extends U(B,H,"GetAlarmMuteRule",W7){},vy=class extends U(B,H,"GetDashboard",z7){},Py=class extends U(B,H,"GetDataset",j7){},Ny=class extends U(B,H,"GetInsightRuleReport",q7){},jd=class extends U(B,H,"GetMetricData",K7){},ky=class extends U(B,H,"GetMetricStatistics",Y7){},My=class extends U(B,H,"GetMetricStream",Q7){},Ly=class extends U(B,H,"GetMetricWidgetImage",J7){},$y=class extends U(B,H,"GetOTelEnrichment",X7){},Fy=class extends U(B,H,"GetResourceMetricsConfiguration",Z7){},qd=class extends U(B,H,"ListAlarmMuteRules",eY){},Kd=class extends U(B,H,"ListDashboards",tY){},Yd=class extends U(B,H,"ListManagedInsightRules",rY){},Qd=class extends U(B,H,"ListMetrics",nY){},Jd=class extends U(B,H,"ListMetricStreams",sY){},Uy=class extends U(B,H,"ListTagsForResource",oY){},By=class extends U(B,H,"PutAlarmMuteRule",iY){},Gy=class extends U(B,H,"PutAnomalyDetector",aY){},Hy=class extends U(B,H,"PutCompositeAlarm",cY){},Vy=class extends U(B,H,"PutDashboard",uY){},Wy=class extends U(B,H,"PutInsightRule",lY){},zy=class extends U(B,H,"PutLogAlarm",dY){},jy=class extends U(B,H,"PutManagedInsightRules",pY){},qy=class extends U(B,H,"PutMetricAlarm",fY){},Ky=class extends U(B,Cwe,"PutMetricData",mY){},Yy=class extends U(B,H,"PutMetricStream",hY){},Qy=class extends U(B,H,"SetAlarmState",gY){},Jy=class extends U(B,H,"StartMetricStreams",SY){},Xy=class extends U(B,H,"StartOTelEnrichment",EY){},Zy=class extends U(B,H,"StopMetricStreams",yY){},e_=class extends U(B,H,"StopOTelEnrichment",_Y){},t_=class extends U(B,H,"TagResource",RY){},r_=class extends U(B,H,"UntagResource",TY){},n_=class extends U(B,H,"UpdateOTelEnrichment",AY){},s_=class extends U(B,H,"UpdateResourceMetricsConfiguration",IY){},xY=Ss(or,Hd,"NextToken","NextToken","MaxRecords"),CY=Ss(or,Bo,"NextToken","NextToken","MaxRecords"),bY=Ss(or,Vd,"NextToken","NextToken","MaxResults"),wY=Ss(or,Wd,"NextToken","NextToken","MaxResults"),DY=Ss(or,jd,"NextToken","NextToken","MaxDatapoints"),OY=Ss(or,qd,"NextToken","NextToken","MaxRecords"),vY=Ss(or,Kd,"NextToken","NextToken",""),PY=Ss(or,Yd,"NextToken","NextToken","MaxResults"),NY=Ss(or,Qd,"NextToken","NextToken",""),kY=Ss(or,Jd,"NextToken","NextToken","MaxResults"),MY=async(t,e)=>{let r;try{let n=await t.send(new Bo(e));r=n;try{if([].concat(...n.MetricAlarms).length>0==!0)return{state:Gs.SUCCESS,reason:r}}catch{}}catch(n){r=n}return{state:Gs.RETRY,reason:r}},bwe=async(t,e)=>Go({...{minDelay:5,maxDelay:120},...t},e,MY),LY=async(t,e)=>{let n=await Go({...{minDelay:5,maxDelay:120},...t},e,MY);return i_(n)},$Y=async(t,e)=>{let r;try{return r=await t.send(new zd(e)),{state:Gs.SUCCESS,reason:r}}catch(n){if(r=n,n.name==="ResourceNotFoundException")return{state:Gs.RETRY,reason:r}}return{state:Gs.RETRY,reason:r}},wwe=async(t,e)=>Go({...{minDelay:5,maxDelay:120},...t},e,$Y),FY=async(t,e)=>{let n=await Go({...{minDelay:5,maxDelay:120},...t},e,$Y);return i_(n)},UY=async(t,e)=>{let r;try{let n=await t.send(new Bo(e));r=n;try{if([].concat(...n.CompositeAlarms).length>0==!0)return{state:Gs.SUCCESS,reason:r}}catch{}}catch(n){r=n}return{state:Gs.RETRY,reason:r}},Dwe=async(t,e)=>Go({...{minDelay:5,maxDelay:120},...t},e,UY),BY=async(t,e)=>{let n=await Go({...{minDelay:5,maxDelay:120},...t},e,UY);return i_(n)},GY=async(t,e)=>{let r;try{let n=await t.send(new Bo(e));r=n;try{if([].concat(...n.LogAlarms).length>0==!0)return{state:Gs.SUCCESS,reason:r}}catch{}}catch(n){r=n}return{state:Gs.RETRY,reason:r}},Owe=async(t,e)=>Go({...{minDelay:5,maxDelay:120},...t},e,GY),HY=async(t,e)=>{let n=await Go({...{minDelay:5,maxDelay:120},...t},e,GY);return i_(n)},vwe={AssociateDatasetKmsKeyCommand:hy,CreateResourceMetricsConfigurationCommand:gy,DeleteAlarmMuteRuleCommand:Sy,DeleteAlarmsCommand:Ey,DeleteAnomalyDetectorCommand:yy,DeleteDashboardsCommand:_y,DeleteInsightRulesCommand:Ry,DeleteMetricStreamCommand:Ty,DeleteResourceMetricsConfigurationCommand:Ay,DescribeAlarmContributorsCommand:Iy,DescribeAlarmHistoryCommand:Hd,DescribeAlarmsCommand:Bo,DescribeAlarmsForMetricCommand:xy,DescribeAnomalyDetectorsCommand:Vd,DescribeInsightRulesCommand:Wd,DisableAlarmActionsCommand:Cy,DisableInsightRulesCommand:by,DisassociateDatasetKmsKeyCommand:wy,EnableAlarmActionsCommand:Dy,EnableInsightRulesCommand:Oy,GetAlarmMuteRuleCommand:zd,GetDashboardCommand:vy,GetDatasetCommand:Py,GetInsightRuleReportCommand:Ny,GetMetricDataCommand:jd,GetMetricStatisticsCommand:ky,GetMetricStreamCommand:My,GetMetricWidgetImageCommand:Ly,GetOTelEnrichmentCommand:$y,GetResourceMetricsConfigurationCommand:Fy,ListAlarmMuteRulesCommand:qd,ListDashboardsCommand:Kd,ListManagedInsightRulesCommand:Yd,ListMetricsCommand:Qd,ListMetricStreamsCommand:Jd,ListTagsForResourceCommand:Uy,PutAlarmMuteRuleCommand:By,PutAnomalyDetectorCommand:Gy,PutCompositeAlarmCommand:Hy,PutDashboardCommand:Vy,PutInsightRuleCommand:Wy,PutLogAlarmCommand:zy,PutManagedInsightRulesCommand:jy,PutMetricAlarmCommand:qy,PutMetricDataCommand:Ky,PutMetricStreamCommand:Yy,SetAlarmStateCommand:Qy,StartMetricStreamsCommand:Jy,StartOTelEnrichmentCommand:Xy,StopMetricStreamsCommand:Zy,StopOTelEnrichmentCommand:e_,TagResourceCommand:t_,UntagResourceCommand:r_,UpdateOTelEnrichmentCommand:n_,UpdateResourceMetricsConfigurationCommand:s_},Pwe={paginateDescribeAlarmHistory:xY,paginateDescribeAlarms:CY,paginateDescribeAnomalyDetectors:bY,paginateDescribeInsightRules:wY,paginateGetMetricData:DY,paginateListAlarmMuteRules:OY,paginateListDashboards:vY,paginateListManagedInsightRules:PY,paginateListMetrics:NY,paginateListMetricStreams:kY},Nwe={waitUntilAlarmExists:LY,waitUntilCompositeAlarmExists:BY,waitUntilLogAlarmExists:HY,waitUntilAlarmMuteRuleExists:FY},o_=class extends or{};m0e(vwe,o_,{paginators:Pwe,waiters:Nwe});var kwe={Alarm:"Alarm",ExtensionPeriod:"ExtensionPeriod",WaitPeriod:"WaitPeriod"},Mwe={CompositeAlarm:"CompositeAlarm",LogAlarm:"LogAlarm",MetricAlarm:"MetricAlarm"},Lwe={Action:"Action",AlarmContributorAction:"AlarmContributorAction",AlarmContributorStateUpdate:"AlarmContributorStateUpdate",ConfigurationUpdate:"ConfigurationUpdate",StateUpdate:"StateUpdate"},$we={ACTIVE:"ACTIVE",EXPIRED:"EXPIRED",SCHEDULED:"SCHEDULED"},Fwe={Bits:"Bits",Bits_Second:"Bits/Second",Bytes:"Bytes",Bytes_Second:"Bytes/Second",Count:"Count",Count_Second:"Count/Second",Gigabits:"Gigabits",Gigabits_Second:"Gigabits/Second",Gigabytes:"Gigabytes",Gigabytes_Second:"Gigabytes/Second",Kilobits:"Kilobits",Kilobits_Second:"Kilobits/Second",Kilobytes:"Kilobytes",Kilobytes_Second:"Kilobytes/Second",Megabits:"Megabits",Megabits_Second:"Megabits/Second",Megabytes:"Megabytes",Megabytes_Second:"Megabytes/Second",Microseconds:"Microseconds",Milliseconds:"Milliseconds",None:"None",Percent:"Percent",Seconds:"Seconds",Terabits:"Terabits",Terabits_Second:"Terabits/Second",Terabytes:"Terabytes",Terabytes_Second:"Terabytes/Second"},Uwe={PENDING_TRAINING:"PENDING_TRAINING",TRAINED:"TRAINED",TRAINED_INSUFFICIENT_DATA:"TRAINED_INSUFFICIENT_DATA"},Bwe={METRIC_MATH:"METRIC_MATH",SINGLE_METRIC:"SINGLE_METRIC"},Gwe={GreaterThanOrEqualToThreshold:"GreaterThanOrEqualToThreshold",GreaterThanThreshold:"GreaterThanThreshold",GreaterThanUpperThreshold:"GreaterThanUpperThreshold",LessThanLowerOrGreaterThanUpperThreshold:"LessThanLowerOrGreaterThanUpperThreshold",LessThanLowerThreshold:"LessThanLowerThreshold",LessThanOrEqualToThreshold:"LessThanOrEqualToThreshold",LessThanThreshold:"LessThanThreshold"},Hwe={ALARM:"ALARM",INSUFFICIENT_DATA:"INSUFFICIENT_DATA",OK:"OK"},Vwe={TIMESTAMP_ASCENDING:"TimestampAscending",TIMESTAMP_DESCENDING:"TimestampDescending"},Wwe={EVALUATION_ERROR:"EVALUATION_ERROR",EVALUATION_FAILURE:"EVALUATION_FAILURE",PARTIAL_DATA:"PARTIAL_DATA"},zwe={Average:"Average",Maximum:"Maximum",Minimum:"Minimum",SampleCount:"SampleCount",Sum:"Sum"},jwe={COMPLETE:"Complete",FORBIDDEN:"Forbidden",INTERNAL_ERROR:"InternalError",PARTIAL_DATA:"PartialData"},qwe={JSON:"json",OPEN_TELEMETRY_0_7:"opentelemetry0.7",OPEN_TELEMETRY_1_0:"opentelemetry1.0"},Kwe={RUNNING:"Running",STOPPED:"Stopped"},Ywe={PT3H:"PT3H"};S.ActionsSuppressedBy=kwe;S.AlarmContributor$=U8;S.AlarmHistoryItem$=B8;S.AlarmMuteRuleStatus=$we;S.AlarmMuteRuleSummary$=G8;S.AlarmPromQLCriteria$=H8;S.AlarmType=Mwe;S.AnomalyDetector$=V8;S.AnomalyDetectorConfiguration$=Wb;S.AnomalyDetectorStateValue=Uwe;S.AnomalyDetectorType=Bwe;S.AssociateDatasetKmsKey$=I7;S.AssociateDatasetKmsKeyCommand=hy;S.AssociateDatasetKmsKeyInput$=W8;S.AssociateDatasetKmsKeyOutput$=z8;S.CloudWatch=o_;S.CloudWatchClient=or;S.CloudWatchServiceException=ke;S.CloudWatchServiceException$=E8;S.ComparisonOperator=Gwe;S.CompositeAlarm$=j8;S.ConcurrentModificationException=ey;S.ConcurrentModificationException$=y8;S.ConflictException=YE;S.ConflictException$=_8;S.CreateResourceMetricsConfiguration$=x7;S.CreateResourceMetricsConfigurationCommand=gy;S.CreateResourceMetricsConfigurationInput$=q8;S.CreateResourceMetricsConfigurationOutput$=K8;S.DashboardEntry$=Y8;S.DashboardInvalidInputError=ty;S.DashboardInvalidInputError$=R8;S.DashboardNotFoundError=ry;S.DashboardNotFoundError$=T8;S.DashboardValidationMessage$=Q8;S.Datapoint$=J8;S.DeleteAlarmMuteRule$=C7;S.DeleteAlarmMuteRuleCommand=Sy;S.DeleteAlarmMuteRuleInput$=X8;S.DeleteAlarms$=b7;S.DeleteAlarmsCommand=Ey;S.DeleteAlarmsInput$=Z8;S.DeleteAnomalyDetector$=w7;S.DeleteAnomalyDetectorCommand=yy;S.DeleteAnomalyDetectorInput$=e5;S.DeleteAnomalyDetectorOutput$=t5;S.DeleteDashboards$=D7;S.DeleteDashboardsCommand=_y;S.DeleteDashboardsInput$=r5;S.DeleteDashboardsOutput$=n5;S.DeleteInsightRules$=O7;S.DeleteInsightRulesCommand=Ry;S.DeleteInsightRulesInput$=s5;S.DeleteInsightRulesOutput$=o5;S.DeleteMetricStream$=v7;S.DeleteMetricStreamCommand=Ty;S.DeleteMetricStreamInput$=i5;S.DeleteMetricStreamOutput$=a5;S.DeleteResourceMetricsConfiguration$=P7;S.DeleteResourceMetricsConfigurationCommand=Ay;S.DeleteResourceMetricsConfigurationInput$=c5;S.DeleteResourceMetricsConfigurationOutput$=u5;S.DescribeAlarmContributors$=N7;S.DescribeAlarmContributorsCommand=Iy;S.DescribeAlarmContributorsInput$=l5;S.DescribeAlarmContributorsOutput$=d5;S.DescribeAlarmHistory$=k7;S.DescribeAlarmHistoryCommand=Hd;S.DescribeAlarmHistoryInput$=p5;S.DescribeAlarmHistoryOutput$=f5;S.DescribeAlarms$=M7;S.DescribeAlarmsCommand=Bo;S.DescribeAlarmsForMetric$=L7;S.DescribeAlarmsForMetricCommand=xy;S.DescribeAlarmsForMetricInput$=m5;S.DescribeAlarmsForMetricOutput$=h5;S.DescribeAlarmsInput$=g5;S.DescribeAlarmsOutput$=S5;S.DescribeAnomalyDetectors$=$7;S.DescribeAnomalyDetectorsCommand=Vd;S.DescribeAnomalyDetectorsInput$=E5;S.DescribeAnomalyDetectorsOutput$=y5;S.DescribeInsightRules$=F7;S.DescribeInsightRulesCommand=Wd;S.DescribeInsightRulesInput$=_5;S.DescribeInsightRulesOutput$=R5;S.Dimension$=T5;S.DimensionFilter$=A5;S.DisableAlarmActions$=U7;S.DisableAlarmActionsCommand=Cy;S.DisableAlarmActionsInput$=I5;S.DisableInsightRules$=B7;S.DisableInsightRulesCommand=by;S.DisableInsightRulesInput$=x5;S.DisableInsightRulesOutput$=C5;S.DisassociateDatasetKmsKey$=G7;S.DisassociateDatasetKmsKeyCommand=wy;S.DisassociateDatasetKmsKeyInput$=b5;S.DisassociateDatasetKmsKeyOutput$=w5;S.EnableAlarmActions$=H7;S.EnableAlarmActionsCommand=Dy;S.EnableAlarmActionsInput$=D5;S.EnableInsightRules$=V7;S.EnableInsightRulesCommand=Oy;S.EnableInsightRulesInput$=O5;S.EnableInsightRulesOutput$=v5;S.Entity$=P5;S.EntityMetricData$=N5;S.EvaluationCriteria$=Jb;S.EvaluationState=Wwe;S.EvaluationWindow$=Xb;S.GetAlarmMuteRule$=W7;S.GetAlarmMuteRuleCommand=zd;S.GetAlarmMuteRuleInput$=k5;S.GetAlarmMuteRuleOutput$=M5;S.GetDashboard$=z7;S.GetDashboardCommand=vy;S.GetDashboardInput$=L5;S.GetDashboardOutput$=$5;S.GetDataset$=j7;S.GetDatasetCommand=Py;S.GetDatasetInput$=F5;S.GetDatasetOutput$=U5;S.GetInsightRuleReport$=q7;S.GetInsightRuleReportCommand=Ny;S.GetInsightRuleReportInput$=B5;S.GetInsightRuleReportOutput$=G5;S.GetMetricData$=K7;S.GetMetricDataCommand=jd;S.GetMetricDataInput$=H5;S.GetMetricDataOutput$=V5;S.GetMetricStatistics$=Y7;S.GetMetricStatisticsCommand=ky;S.GetMetricStatisticsInput$=W5;S.GetMetricStatisticsOutput$=z5;S.GetMetricStream$=Q7;S.GetMetricStreamCommand=My;S.GetMetricStreamInput$=j5;S.GetMetricStreamOutput$=q5;S.GetMetricWidgetImage$=J7;S.GetMetricWidgetImageCommand=Ly;S.GetMetricWidgetImageInput$=K5;S.GetMetricWidgetImageOutput$=Y5;S.GetOTelEnrichment$=X7;S.GetOTelEnrichmentCommand=$y;S.GetOTelEnrichmentInput$=Q5;S.GetOTelEnrichmentOutput$=J5;S.GetResourceMetricsConfiguration$=Z7;S.GetResourceMetricsConfigurationCommand=Fy;S.GetResourceMetricsConfigurationInput$=X5;S.GetResourceMetricsConfigurationOutput$=Z5;S.HistoryItemType=Lwe;S.InsightRule$=e9;S.InsightRuleContributor$=t9;S.InsightRuleContributorDatapoint$=r9;S.InsightRuleMetricDatapoint$=n9;S.InternalServiceFault=oy;S.InternalServiceFault$=A8;S.InvalidFormatFault=py;S.InvalidFormatFault$=I8;S.InvalidNextToken=uy;S.InvalidNextToken$=x8;S.InvalidParameterCombinationException=iy;S.InvalidParameterCombinationException$=C8;S.InvalidParameterValueException=ay;S.InvalidParameterValueException$=b8;S.KmsAccessDeniedException=QE;S.KmsAccessDeniedException$=w8;S.KmsKeyDisabledException=JE;S.KmsKeyDisabledException$=D8;S.KmsKeyNotFoundException=XE;S.KmsKeyNotFoundException$=O8;S.LabelOptions$=s9;S.LimitExceededException=ly;S.LimitExceededException$=v8;S.LimitExceededFault=dy;S.LimitExceededFault$=P8;S.ListAlarmMuteRules$=eY;S.ListAlarmMuteRulesCommand=qd;S.ListAlarmMuteRulesInput$=o9;S.ListAlarmMuteRulesOutput$=i9;S.ListDashboards$=tY;S.ListDashboardsCommand=Kd;S.ListDashboardsInput$=a9;S.ListDashboardsOutput$=c9;S.ListManagedInsightRules$=rY;S.ListManagedInsightRulesCommand=Yd;S.ListManagedInsightRulesInput$=u9;S.ListManagedInsightRulesOutput$=l9;S.ListMetricStreams$=sY;S.ListMetricStreamsCommand=Jd;S.ListMetricStreamsInput$=f9;S.ListMetricStreamsOutput$=m9;S.ListMetrics$=nY;S.ListMetricsCommand=Qd;S.ListMetricsInput$=d9;S.ListMetricsOutput$=p9;S.ListTagsForResource$=oY;S.ListTagsForResourceCommand=Uy;S.ListTagsForResourceInput$=h9;S.ListTagsForResourceOutput$=g9;S.LogAlarm$=S9;S.ManagedRule$=E9;S.ManagedRuleDescription$=y9;S.ManagedRuleState$=_9;S.MessageData$=R9;S.Metric$=zb;S.MetricAlarm$=T9;S.MetricCharacteristics$=jb;S.MetricDataQuery$=A9;S.MetricDataResult$=I9;S.MetricDatum$=x9;S.MetricMathAnomalyDetector$=x_;S.MetricStat$=C9;S.MetricStreamEntry$=b9;S.MetricStreamFilter$=w9;S.MetricStreamOutputFormat=qwe;S.MetricStreamStatisticsConfiguration$=D9;S.MetricStreamStatisticsMetric$=O9;S.MissingRequiredParameterException=cy;S.MissingRequiredParameterException$=N8;S.MuteTargets$=qb;S.OTelEnrichmentMetricSelector$=v9;S.OTelEnrichmentStatus=Kwe;S.PartialFailure$=P9;S.PutAlarmMuteRule$=iY;S.PutAlarmMuteRuleCommand=By;S.PutAlarmMuteRuleInput$=N9;S.PutAnomalyDetector$=aY;S.PutAnomalyDetectorCommand=Gy;S.PutAnomalyDetectorInput$=k9;S.PutAnomalyDetectorOutput$=M9;S.PutCompositeAlarm$=cY;S.PutCompositeAlarmCommand=Hy;S.PutCompositeAlarmInput$=L9;S.PutDashboard$=uY;S.PutDashboardCommand=Vy;S.PutDashboardInput$=$9;S.PutDashboardOutput$=F9;S.PutInsightRule$=lY;S.PutInsightRuleCommand=Wy;S.PutInsightRuleInput$=U9;S.PutInsightRuleOutput$=B9;S.PutLogAlarm$=dY;S.PutLogAlarmCommand=zy;S.PutLogAlarmInput$=G9;S.PutManagedInsightRules$=pY;S.PutManagedInsightRulesCommand=jy;S.PutManagedInsightRulesInput$=H9;S.PutManagedInsightRulesOutput$=V9;S.PutMetricAlarm$=fY;S.PutMetricAlarmCommand=qy;S.PutMetricAlarmInput$=W9;S.PutMetricData$=mY;S.PutMetricDataCommand=Ky;S.PutMetricDataInput$=z9;S.PutMetricStream$=hY;S.PutMetricStreamCommand=Yy;S.PutMetricStreamInput$=j9;S.PutMetricStreamOutput$=q9;S.Range$=K9;S.RecentlyActive=Ywe;S.ResourceConflict=ny;S.ResourceConflict$=k8;S.ResourceMetricSelection$=Y9;S.ResourceMetricsConfiguration$=C_;S.ResourceNotFound=sy;S.ResourceNotFound$=M8;S.ResourceNotFoundException=ZE;S.ResourceNotFoundException$=L8;S.Rule$=Kb;S.ScanBy=Vwe;S.Schedule$=Q9;S.ScheduleConfiguration$=J9;S.ScheduledQueryConfiguration$=Yb;S.SetAlarmState$=gY;S.SetAlarmStateCommand=Qy;S.SetAlarmStateInput$=X9;S.SingleMetricAnomalyDetector$=b_;S.SlidingWindow$=Z9;S.StandardUnit=Fwe;S.StartMetricStreams$=SY;S.StartMetricStreamsCommand=Jy;S.StartMetricStreamsInput$=e7;S.StartMetricStreamsOutput$=t7;S.StartOTelEnrichment$=EY;S.StartOTelEnrichmentCommand=Xy;S.StartOTelEnrichmentInput$=r7;S.StartOTelEnrichmentOutput$=n7;S.StateValue=Hwe;S.Statistic=zwe;S.StatisticSet$=s7;S.StatusCode=jwe;S.StopMetricStreams$=yY;S.StopMetricStreamsCommand=Zy;S.StopMetricStreamsInput$=o7;S.StopMetricStreamsOutput$=i7;S.StopOTelEnrichment$=_Y;S.StopOTelEnrichmentCommand=e_;S.StopOTelEnrichmentInput$=a7;S.StopOTelEnrichmentOutput$=c7;S.Tag$=u7;S.TagResource$=RY;S.TagResourceCommand=t_;S.TagResourceInput$=l7;S.TagResourceOutput$=d7;S.UntagResource$=TY;S.UntagResourceCommand=r_;S.UntagResourceInput$=p7;S.UntagResourceOutput$=f7;S.UpdateOTelEnrichment$=AY;S.UpdateOTelEnrichmentCommand=n_;S.UpdateOTelEnrichmentInput$=m7;S.UpdateOTelEnrichmentOutput$=h7;S.UpdateResourceMetricsConfiguration$=IY;S.UpdateResourceMetricsConfigurationCommand=s_;S.UpdateResourceMetricsConfigurationInput$=g7;S.UpdateResourceMetricsConfigurationOutput$=S7;S.ValidationException=fy;S.ValidationException$=$8;S.WallClockWindow$=E7;S.WarmUpConfiguration$=ip;S.errorTypeRegistries=F8;S.paginateDescribeAlarmHistory=xY;S.paginateDescribeAlarms=CY;S.paginateDescribeAnomalyDetectors=bY;S.paginateDescribeInsightRules=wY;S.paginateGetMetricData=DY;S.paginateListAlarmMuteRules=OY;S.paginateListDashboards=vY;S.paginateListManagedInsightRules=PY;S.paginateListMetricStreams=kY;S.paginateListMetrics=NY;S.waitForAlarmExists=bwe;S.waitForAlarmMuteRuleExists=wwe;S.waitForCompositeAlarmExists=Dwe;S.waitForLogAlarmExists=Owe;S.waitUntilAlarmExists=LY;S.waitUntilAlarmMuteRuleExists=FY;S.waitUntilCompositeAlarmExists=BY;S.waitUntilLogAlarmExists=HY});var qJ=Ne(A=>{var{awsEndpointFunctions:Qwe,emitWarningIfUnsupportedVersion:Jwe,createDefaultUserAgentProvider:Xwe,NODE_APP_ID_CONFIG_OPTIONS:Zwe,getAwsRegionExtensionConfiguration:eDe,resolveAwsRegionExtensionConfiguration:tDe,resolveUserAgentConfig:rDe,resolveHostHeaderConfig:nDe,getUserAgentPlugin:sDe,getHostHeaderPlugin:oDe,getLoggerPlugin:iDe,getRecursionDetectionPlugin:aDe}=(ie(),O(wr)),{getHttpAuthSchemeEndpointRuleSetPlugin:cDe,DefaultIdentityProviderConfig:uDe,getHttpSigningPlugin:lDe,createPaginator:Zb}=(At(),O(Bu)),{normalizeProvider:JY,getSmithyContext:dDe,ServiceException:pDe,NoOpLogger:fDe,emitWarningIfUnsupportedVersion:mDe,loadConfigsForDefaultMode:hDe,getDefaultExtensionConfiguration:gDe,resolveDefaultRuntimeConfig:SDe,Client:XY,makeBuilder:EDe,createWaiter:Fr,checkExceptions:Wc,WaiterState:ve,createAggregatedClient:yDe}=(V(),O(Ts)),{Command:_De}=(V(),O(Ts));A.$Command=_De;A.__Client=XY;var{resolveDefaultsModeConfig:RDe,loadConfig:Li,NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS:TDe,NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS:ADe,NODE_REGION_CONFIG_OPTIONS:IDe,NODE_REGION_CONFIG_FILE_OPTIONS:xDe,resolveRegionConfig:CDe}=(se(),O(Gt)),{BinaryDecisionDiagram:bDe,EndpointCache:wDe,decideEndpoint:DDe,customEndpointFunctions:ODe,resolveEndpointConfig:vDe,getEndpointPlugin:PDe}=(Re(),O(Cf)),{parseUrl:NDe,getHttpHandlerExtensionConfiguration:kDe,resolveHttpHandlerRuntimeConfig:MDe,getContentLengthPlugin:LDe}=(G(),O(qn)),{DEFAULT_RETRY_MODE:$De,NODE_RETRY_MODE_CONFIG_OPTIONS:FDe,NODE_MAX_ATTEMPT_CONFIG_OPTIONS:UDe,resolveRetryConfig:BDe,getRetryPlugin:GDe}=(Zt(),O(xm)),{TypeRegistry:ZY,getSchemaSerdePlugin:HDe}=(K(),O(Ip)),{resolveAwsSdkSigV4Config:VDe,AwsSdkSigV4Signer:WDe,NODE_AUTH_SCHEME_PREFERENCE_OPTIONS:zDe}=(It(),O(Qu)),{defaultProvider:jDe}=Pg(),{toUtf8:qDe,fromUtf8:KDe,toBase64:YDe,fromBase64:QDe,calculateBodyLength:JDe}=(L(),O(Bn)),{streamCollector:XDe,NodeHttpHandler:ZDe}=Ps(),{AwsRestJsonProtocol:eOe}=(bo(),O(zh)),{Sha256:tOe}=(Gn(),O(Hf)),rOe=async(t,e,r)=>({operation:dDe(e).operation,region:await JY(t.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()});function nOe(t){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"lambda",region:t.region},propertiesExtractor:(e,r)=>({signingProperties:{config:e,context:r}})}}var sOe=t=>{let e=[];switch(t.operation){default:e.push(nOe(t))}return e},oOe=t=>{let e=VDe(t);return Object.assign(e,{authSchemePreference:JY(t.authSchemePreference??[])})},iOe=t=>Object.assign(t,{useDualstackEndpoint:t.useDualstackEndpoint??!1,useFipsEndpoint:t.useFipsEndpoint??!1,defaultSigningName:"lambda"}),aOe={UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}},cOe="3.1151.0",uOe={version:cOe},cp="ref",$i=-1,O_=!0,WY="isSet",eQ="PartitionResult",v_="booleanEquals",zY="getAttr",jY={[cp]:"Endpoint"},qY={[cp]:eQ},ap={},KY=[{[cp]:"Region"}],YY={conditions:[[WY,[jY]],[WY,KY],["aws.partition",KY,eQ],[v_,[{[cp]:"UseFIPS"},O_]],[v_,[{[cp]:"UseDualStack"},O_]],[v_,[{fn:zY,argv:[qY,"supportsDualStack"]},O_]],[v_,[{fn:zY,argv:[qY,"supportsFIPS"]},O_]]],results:[[$i],[$i,"Invalid Configuration: FIPS and custom endpoint are not supported"],[$i,"Invalid Configuration: Dualstack and custom endpoint are not supported"],[jY,ap],["https://lambda-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",ap],[$i,"FIPS and DualStack are enabled, but this partition does not support one or both"],["https://lambda-fips.{Region}.{PartitionResult#dnsSuffix}",ap],[$i,"FIPS is enabled but this partition does not support FIPS"],["https://lambda.{Region}.{PartitionResult#dualStackDnsSuffix}",ap],[$i,"DualStack is enabled but this partition does not support DualStack"],["https://lambda.{Region}.{PartitionResult#dnsSuffix}",ap],[$i,"Invalid Configuration: Missing Region"]]},lOe=2,Er=1e8,dOe=new Int32Array([-1,1,-1,0,12,3,1,4,Er+11,2,5,Er+11,3,8,6,4,7,Er+10,5,Er+8,Er+9,4,10,9,6,Er+6,Er+7,5,11,Er+5,6,Er+4,Er+5,3,Er+1,13,4,Er+2,Er+3]),pOe=bDe.from(dOe,lOe,YY.conditions,YY.results),fOe=new wDe({size:50,params:["Endpoint","Region","UseDualStack","UseFIPS"]}),mOe=(t,e={})=>fOe.get(t,()=>DDe(pOe,{endpointParams:t,logger:e.logger}));ODe.aws=Qwe;var En=class t extends pDe{static shapeId="smithy.ts.sdk.synthetic.com.amazonaws.lambdaweb#LambdaWebServiceException";constructor(e){super(e),Object.setPrototypeOf(this,t.prototype)}},P_=class t extends En{static shapeId="com.amazonaws.lambdaweb#AccessDeniedException";name="AccessDeniedException";$fault="client";constructor(e){super({name:"AccessDeniedException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}},N_=class t extends En{static shapeId="com.amazonaws.lambdaweb#ConflictException";name="ConflictException";$fault="client";resourceId;resourceType;constructor(e){super({name:"ConflictException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.resourceId=e.resourceId,this.resourceType=e.resourceType}},k_=class t extends En{static shapeId="com.amazonaws.lambdaweb#InternalServerException";name="InternalServerException";$fault="server";$retryable={};constructor(e){super({name:"InternalServerException",$fault:"server",...e}),Object.setPrototypeOf(this,t.prototype)}},M_=class t extends En{static shapeId="com.amazonaws.lambdaweb#ResourceNotFoundException";name="ResourceNotFoundException";$fault="client";resourceId;resourceType;constructor(e){super({name:"ResourceNotFoundException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.resourceId=e.resourceId,this.resourceType=e.resourceType}},L_=class t extends En{static shapeId="com.amazonaws.lambdaweb#ServiceQuotaExceededException";name="ServiceQuotaExceededException";$fault="client";resourceId;resourceType;serviceCode;quotaCode;constructor(e){super({name:"ServiceQuotaExceededException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.resourceId=e.resourceId,this.resourceType=e.resourceType,this.serviceCode=e.serviceCode,this.quotaCode=e.quotaCode}},$_=class t extends En{static shapeId="com.amazonaws.lambdaweb#ThrottlingException";name="ThrottlingException";$fault="client";$retryable={throttling:!0};retryAfterSeconds;serviceCode;quotaCode;constructor(e){super({name:"ThrottlingException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype),this.retryAfterSeconds=e.retryAfterSeconds,this.serviceCode=e.serviceCode,this.quotaCode=e.quotaCode}},F_=class t extends En{static shapeId="com.amazonaws.lambdaweb#ValidationException";name="ValidationException";$fault="client";constructor(e){super({name:"ValidationException",$fault:"client",...e}),Object.setPrototypeOf(this,t.prototype)}},hOe="AccessDeniedException",gOe="AccountQuotas",SOe="AccountUsage",EOe="BuildConfig",yOe="CodeConfig",_Oe="ConflictException",ROe="CreateWebFunction",TOe="CreateWebFunctionEndpoint",AOe="CreateWebFunctionEndpointRequest",IOe="CreateWebFunctionEndpointResponse",xOe="CreateWebFunctionRequest",COe="CreateWebFunctionRevisionRequest",bOe="CreateWebFunctionRevisionResponse",wOe="CreateWebFunctionResponse",DOe="CreateWebFunctionRevision",OOe="DeleteResourcePolicy",vOe="DeleteResourcePolicyRequest",POe="DeleteWebFunction",NOe="DeleteWebFunctionEndpoint",kOe="DeleteWebFunctionEndpointRequest",MOe="DeleteWebFunctionRequest",LOe="DeleteWebFunctionRevisionRequest",$Oe="DeleteWebFunctionRevision",FOe="EndpointConfig",UOe="EnvironmentVariables",BOe="Filter",GOe="FunctionEndpointSummary",HOe="FunctionEndpointSummaryList",VOe="FilterList",WOe="FunctionRevisionSummary",zOe="FunctionRevisionSummaryList",jOe="FunctionSummary",qOe="FunctionSummaryList",KOe="GetResourcePolicy",YOe="GetResourcePolicyRequest",QOe="GetResourcePolicyResponse",JOe="GetWebAccountSettings",XOe="GetWebAccountSettingsRequest",ZOe="GetWebAccountSettingsResponse",eve="GetWebFunction",tve="GetWebFunctionEndpoint",rve="GetWebFunctionEndpointRequest",nve="GetWebFunctionEndpointResponse",sve="GetWebFunctionRequest",ove="GetWebFunctionRevisionRequest",ive="GetWebFunctionRevisionResponse",ave="GetWebFunctionResponse",cve="GetWebFunctionRevision",uve="InternalServerException",lve="LoggingConfig",dve="ListTags",pve="ListTagsRequest",fve="ListTagsResponse",mve="ListWebFunctions",hve="ListWebFunctionEndpoints",gve="ListWebFunctionEndpointsRequest",Sve="ListWebFunctionEndpointsResponse",Eve="ListWebFunctionsRequest",yve="ListWebFunctionRevisionsRequest",_ve="ListWebFunctionRevisionsResponse",Rve="ListWebFunctionsResponse",Tve="ListWebFunctionRevisions",ew="Policy",Ave="PutResourcePolicy",Ive="PutResourcePolicyRequest",xve="PutResourcePolicyResponse",Cve="Retry-After",bve="RevisionConfig",wve="RuntimeConfig",Dve="RegionalEndpoint",Ove="RevisionError",vve="RegionalEndpoints",Pve="RevisionErrors",eR="RevisionId",Nve="ResourceNotFoundException",kve="RevisionWeight",Mve="RevisionWeightList",Lve="ScalingConfig",$ve="ServiceConfig",Fve="S3Object",Uve="ServiceQuotaExceededException",tQ="Tags",Bve="TelemetryConfig",Gve="ThrottleConfig",Hve="ThrottlingException",Vve="TagResource",Wve="TagResourceRequest",zve="UntagResource",jve="UntagResourceRequest",qve="UpdateWebFunctionEndpoint",Kve="UpdateWebFunctionEndpointRequest",Yve="UpdateWebFunctionEndpointResponse",Qve="ValidationException",Jve="attribute",Bi="autoDeploymentMode",Xve="applicationLogLevel",Zve="accountQuotas",Vo="authType",ePe="accountUsage",tPe="bucket",tR="buildConfig",zc="client",_s="createdAt",rPe="codeConfig",Ur="description",fp="domainName",Gi="error",rR="endpointArn",nPe="endpointConfig",sPe="errorCode",oPe="errorMessage",Vs="endpointName",iPe="egressNetworkConnectorArn",aPe="executionRoleArn",jc="endpointType",cPe="environmentVariables",uPe="endpoint",lPe="endpoints",rQ="errors",tw="filters",Wo="functionArn",dPe="functionCount",qt="functionName",pPe="functions",Qe="http",Hi="httpError",fPe="httpHeader",nQ="httpQuery",Ho="jsonName",mPe="key",nR="kmsKeyArn",hPe="loggingConfig",gPe="logGroup",Vi="message",SPe="maxConcurrencyPerEnvironment",EPe="maxEnvironments",yPe="maxEndpointsPerFunction",rw="maxResults",_Pe="maxRevisionsPerFunction",RPe="maxTotalArmVCpus",TPe="maxTotalRateLimit",APe="name",qc="nextToken",nw="policy",sQ="quotaCode",Kc="regions",sw="revisionArn",IPe="retryAfterSeconds",ow="resourceArn",xPe="runtimeConfig",CPe="revisionConfig",iw="regionalEndpoints",aw="resourceId",Rs="revisionId",bPe="rateLimit",cw="resourceType",Wi="revisionWeights",wPe="revision",uw="resource",DPe="revisions",OPe="runtime",oQ="smithy.ts.sdk.synthetic.com.amazonaws.lambdaweb",iQ="serviceCode",zo="scalingConfig",sR="serviceConfig",vPe="systemLogLevel",PPe="s3Object",yn="stateReason",NPe="server",_n="state",oR="tags",jo="throttleConfig",kPe="telemetryConfig",QY="tagKeys",MPe="timeoutSeconds",zi="updatedAt",mp="updateStatus",hp="updateStatusReason",LPe="values",$Pe="versionId",FPe="weight",D="com.amazonaws.lambdaweb",aQ=new ZY(oQ),cQ=[-3,oQ,"LambdaWebServiceException",0,[],[]];aQ.registerError(cQ,En);var qo=new ZY(D),uQ=[-3,D,hOe,{[Gi]:zc,[Hi]:403},[Vi],[0],1];qo.registerError(uQ,P_);var lQ=[-3,D,_Oe,{[Gi]:zc,[Hi]:409},[Vi,aw,cw],[0,0,0],1];qo.registerError(lQ,N_);var dQ=[-3,D,uve,{[Gi]:NPe,[Hi]:500},[Vi],[0]];qo.registerError(dQ,k_);var pQ=[-3,D,Nve,{[Gi]:zc,[Hi]:404},[Vi,aw,cw],[0,0,0],1];qo.registerError(pQ,M_);var fQ=[-3,D,Uve,{[Gi]:zc,[Hi]:402},[Vi,aw,cw,iQ,sQ],[0,0,0,0,0],1];qo.registerError(fQ,L_);var mQ=[-3,D,Hve,{[Gi]:zc,[Hi]:429},[Vi,IPe,iQ,sQ],[0,[1,{[fPe]:Cve}],0,0],1];qo.registerError(mQ,$_);var hQ=[-3,D,Qve,{[Gi]:zc,[Hi]:400},[Vi],[0],1];qo.registerError(hQ,F_);var gQ=[aQ,qo],SQ=[3,D,gOe,0,[RPe,TPe,_Pe,yPe],[1,1,1,1],4],EQ=[3,D,SOe,0,[dPe],[1],1],gp=[3,D,EOe,0,[rPe,xPe],[()=>yQ,()=>sJ],2],yQ=[3,D,yOe,0,[PPe],[()=>oJ],1],_Q=[3,D,AOe,0,[qt,Vs,jc,Vo,Ur,Bi,Wi,Kc,zo,jo],[[0,1],0,0,0,0,0,()=>ji,64,()=>Ws,()=>zs],4],RQ=[3,D,IOe,0,[Wo,rR,Vs,jc,fp,Vo,Bi,Wi,Kc,_n,yn,iw,_s,zi,Ur,zo,jo,mp,hp],[0,0,0,0,0,0,0,()=>ji,64,0,0,()=>fw,5,5,0,()=>Ws,()=>zs,0,0],14],TQ=[3,D,xOe,0,[qt,CPe,nPe,oR],[0,[()=>tJ,0],()=>OQ,128],1],AQ=[3,D,wOe,0,[qt,Wo,_n,yn,_s,zi,wPe,uPe,oR],[0,0,0,0,5,5,()=>dw,()=>lw,128],6],IQ=[3,D,COe,0,[qt,tR,sR,Ur,nR],[[0,1],()=>gp,[()=>Sp,0],0,0],3],xQ=[3,D,bOe,0,[Wo,sw,Rs,tR,sR,_n,yn,_s,Ur,nR,rQ],[0,0,0,()=>gp,[()=>Sp,0],0,0,5,0,0,()=>dJ],8],CQ=[3,D,vOe,0,[ow,Rs],[[0,1],[0,{[nQ]:eR}]],1],bQ=[3,D,kOe,0,[qt,Vs],[[0,1],[0,1]],2],wQ=[3,D,MOe,0,[qt],[[0,1]],1],DQ=[3,D,LOe,0,[qt,Rs],[[0,1],[0,1]],2],OQ=[3,D,FOe,0,[Vs,jc,Vo,Ur,Bi,Kc,zo,jo],[0,0,0,0,0,64,()=>Ws,()=>zs],3],vQ=[3,D,BOe,0,[APe,LPe],[0,64],2],lw=[3,D,GOe,0,[rR,Vs,jc,fp,Vo,Bi,Wi,Kc,_n,yn,_s,zi,Ur,zo,jo,mp,hp],[0,0,0,0,0,0,()=>ji,64,0,0,5,5,0,()=>Ws,()=>zs,0,0],12],dw=[3,D,WOe,0,[sw,Rs,_n,yn,_s,Ur],[0,0,0,0,5,0],5],PQ=[3,D,jOe,0,[qt,Wo,_n,yn,_s,zi],[0,0,0,0,5,5],6],NQ=[3,D,YOe,0,[ow],[[0,1]],1],kQ=[3,D,QOe,0,[nw,Rs],[[0,{[Ho]:ew}],[0,{[Ho]:eR}]],2],MQ=[3,D,XOe,0,[],[]],LQ=[3,D,ZOe,0,[Zve,ePe],[()=>SQ,()=>EQ],2],$Q=[3,D,rve,0,[qt,Vs],[[0,1],[0,1]],2],FQ=[3,D,nve,0,[Wo,rR,Vs,jc,fp,Vo,Bi,Wi,Kc,_n,yn,iw,_s,zi,Ur,zo,jo,mp,hp],[0,0,0,0,0,0,0,()=>ji,64,0,0,()=>fw,5,5,0,()=>Ws,()=>zs,0,0],14],UQ=[3,D,sve,0,[qt],[[0,1]],1],BQ=[3,D,ave,0,[qt,Wo,_n,yn,_s,zi],[0,0,0,0,5,5],6],GQ=[3,D,ove,0,[qt,Rs],[[0,1],[0,1]],2],HQ=[3,D,ive,0,[Wo,sw,Rs,tR,sR,_n,yn,_s,Ur,nR,rQ],[0,0,0,()=>gp,[()=>Sp,0],0,0,5,0,0,()=>dJ],8],VQ=[3,D,pve,0,[uw],[[0,1]],1],WQ=[3,D,fve,0,[oR],[[128,{[Ho]:tQ}]]],zQ=[3,D,gve,0,[qt,tw,rw,qc],[[0,1],()=>pw,1,0],1],jQ=[3,D,Sve,0,[lPe,qc],[()=>UPe,0],1],qQ=[3,D,yve,0,[qt,tw,rw,qc],[[0,1],()=>pw,1,0],1],KQ=[3,D,_ve,0,[DPe,qc],[()=>BPe,0],1],YQ=[3,D,Eve,0,[tw,rw,qc],[()=>pw,1,0]],QQ=[3,D,Rve,0,[pPe,qc],[()=>GPe,0],1],JQ=[3,D,lve,0,[gPe,Xve,vPe],[0,0,0]],XQ=[3,D,Ive,0,[ow,nw,Rs],[[0,1],[0,{[Ho]:ew}],[0,{[Ho]:eR}]],2],ZQ=[3,D,xve,0,[nw,Rs],[[0,{[Ho]:ew}],[0,{[Ho]:eR}]],2],eJ=[3,D,Dve,0,[Vo,Wi,_n,yn,fp,zo,jo,mp,hp],[0,()=>ji,0,0,0,()=>Ws,()=>zs,0,0],4],tJ=[3,D,bve,0,[tR,sR,Ur,nR],[()=>gp,[()=>Sp,0],0,0],2],rJ=[3,D,Ove,0,[Jve,sPe,oPe],[0,0,0],3],nJ=[3,D,kve,0,[Rs,FPe],[0,1],2],sJ=[3,D,wve,0,[OPe],[0],1],oJ=[3,D,Fve,0,[tPe,mPe,$Pe],[0,0,0],2],Ws=[3,D,Lve,0,[EPe],[1]],Sp=[3,D,$ve,0,[aPe,MPe,iPe,SPe,cPe,kPe],[0,1,0,1,[()=>HPe,0],()=>aJ],1],iJ=[3,D,Wve,0,[uw,oR],[[0,1],[128,{[Ho]:tQ}]],2],aJ=[3,D,Bve,0,[hPe],[()=>JQ]],zs=[3,D,Gve,0,[bPe],[1]],cJ=[3,D,jve,0,[uw,QY],[[0,1],[64,{[nQ]:QY}]],2],uJ=[3,D,Kve,0,[qt,Vs,Ur,Vo,Bi,Wi,zo,jo],[[0,1],[0,1],0,0,0,()=>ji,()=>Ws,()=>zs],2],lJ=[3,D,Yve,0,[Wo,rR,Vs,jc,fp,Vo,Bi,Wi,Kc,_n,yn,iw,_s,zi,Ur,zo,jo,mp,hp],[0,0,0,0,0,0,0,()=>ji,64,0,0,()=>fw,5,5,0,()=>Ws,()=>zs,0,0],14],Yc="unit",pw=[1,D,VOe,0,()=>vQ],UPe=[1,D,HOe,0,()=>lw],BPe=[1,D,zOe,0,()=>dw],GPe=[1,D,qOe,0,()=>PQ],dJ=[1,D,Pve,0,()=>rJ],ji=[1,D,Mve,0,()=>nJ],HPe=[2,D,UOe,8,0,0],fw=[2,D,vve,0,0,()=>eJ],pJ=[9,D,ROe,{[Qe]:["PUT","/2025-03-07/web-functions",202]},()=>TQ,()=>AQ],fJ=[9,D,TOe,{[Qe]:["PUT","/2025-03-07/web-functions/{functionName}/endpoints",202]},()=>_Q,()=>RQ],mJ=[9,D,DOe,{[Qe]:["POST","/2025-03-07/web-functions/{functionName}/revisions",202]},()=>IQ,()=>xQ],hJ=[9,D,OOe,{[Qe]:["DELETE","/2025-03-07/resource-policy/{resourceArn}",204]},()=>CQ,()=>Yc],gJ=[9,D,POe,{[Qe]:["DELETE","/2025-03-07/web-functions/{functionName}",204]},()=>wQ,()=>Yc],SJ=[9,D,NOe,{[Qe]:["DELETE","/2025-03-07/web-functions/{functionName}/endpoints/{endpointName}",204]},()=>bQ,()=>Yc],EJ=[9,D,$Oe,{[Qe]:["DELETE","/2025-03-07/web-functions/{functionName}/revisions/{revisionId}",204]},()=>DQ,()=>Yc],yJ=[9,D,KOe,{[Qe]:["GET","/2025-03-07/resource-policy/{resourceArn}",200]},()=>NQ,()=>kQ],_J=[9,D,JOe,{[Qe]:["GET","/2025-03-07/web-account-settings",200]},()=>MQ,()=>LQ],RJ=[9,D,eve,{[Qe]:["GET","/2025-03-07/web-functions/{functionName}",200]},()=>UQ,()=>BQ],TJ=[9,D,tve,{[Qe]:["GET","/2025-03-07/web-functions/{functionName}/endpoints/{endpointName}",200]},()=>$Q,()=>FQ],AJ=[9,D,cve,{[Qe]:["GET","/2025-03-07/web-functions/{functionName}/revisions/{revisionId}",200]},()=>GQ,()=>HQ],IJ=[9,D,dve,{[Qe]:["GET","/2025-03-07/tags/{resource}",200]},()=>VQ,()=>WQ],xJ=[9,D,hve,{[Qe]:["POST","/2025-03-07/web-functions/{functionName}/list-endpoints",200]},()=>zQ,()=>jQ],CJ=[9,D,Tve,{[Qe]:["POST","/2025-03-07/web-functions/{functionName}/list-revisions",200]},()=>qQ,()=>KQ],bJ=[9,D,mve,{[Qe]:["POST","/2025-03-07/web-functions",200]},()=>YQ,()=>QQ],wJ=[9,D,Ave,{[Qe]:["PUT","/2025-03-07/resource-policy/{resourceArn}",200]},()=>XQ,()=>ZQ],DJ=[9,D,Vve,{[Qe]:["POST","/2025-03-07/tags/{resource}",204]},()=>iJ,()=>Yc],OJ=[9,D,zve,{[Qe]:["DELETE","/2025-03-07/tags/{resource}",204]},()=>cJ,()=>Yc],vJ=[9,D,qve,{[Qe]:["PATCH","/2025-03-07/web-functions/{functionName}/endpoints/{endpointName}",202]},()=>uJ,()=>lJ],VPe=t=>({apiVersion:"2025-03-07",base64Decoder:t?.base64Decoder??QDe,base64Encoder:t?.base64Encoder??YDe,disableHostPrefix:t?.disableHostPrefix??!1,endpointProvider:t?.endpointProvider??mOe,extensions:t?.extensions??[],httpAuthSchemeProvider:t?.httpAuthSchemeProvider??sOe,httpAuthSchemes:t?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:e=>e.getIdentityProvider("aws.auth#sigv4"),signer:new WDe}],logger:t?.logger??new fDe,protocol:t?.protocol??eOe,protocolSettings:t?.protocolSettings??{defaultNamespace:"com.amazonaws.lambdaweb",errorTypeRegistries:gQ,version:"2025-03-07",serviceTarget:"LambdaWeb"},serviceId:t?.serviceId??"Lambda Web",sha256:t?.sha256??tOe,urlParser:t?.urlParser??NDe,utf8Decoder:t?.utf8Decoder??KDe,utf8Encoder:t?.utf8Encoder??qDe}),WPe=t=>{mDe(process.version);let e=RDe(t),r=()=>e().then(hDe),n=VPe(t);Jwe(process.version);let s={profile:t?.profile,logger:n.logger};return{...n,...t,runtime:"node",defaultsMode:e,authSchemePreference:t?.authSchemePreference??Li(zDe,s),bodyLengthChecker:t?.bodyLengthChecker??JDe,credentialDefaultProvider:t?.credentialDefaultProvider??jDe,defaultUserAgentProvider:t?.defaultUserAgentProvider??Xwe({serviceId:n.serviceId,clientVersion:uOe.version}),maxAttempts:t?.maxAttempts??Li(UDe,t),region:t?.region??Li(IDe,{...xDe,...s}),requestHandler:ZDe.create(t?.requestHandler??r),retryMode:t?.retryMode??Li({...FDe,default:async()=>(await r()).retryMode||$De},t),streamCollector:t?.streamCollector??XDe,useDualstackEndpoint:t?.useDualstackEndpoint??Li(ADe,s),useFipsEndpoint:t?.useFipsEndpoint??Li(TDe,s),userAgentAppId:t?.userAgentAppId??Li(Zwe,s)}},zPe=t=>{let e=t.httpAuthSchemes,r=t.httpAuthSchemeProvider,n=t.credentials;return{setHttpAuthScheme(s){let o=e.findIndex(i=>i.schemeId===s.schemeId);o===-1?e.push(s):e.splice(o,1,s)},httpAuthSchemes(){return e},setHttpAuthSchemeProvider(s){r=s},httpAuthSchemeProvider(){return r},setCredentials(s){n=s},credentials(){return n}}},jPe=t=>({httpAuthSchemes:t.httpAuthSchemes(),httpAuthSchemeProvider:t.httpAuthSchemeProvider(),credentials:t.credentials()}),qPe=(t,e)=>{let r=Object.assign(eDe(t),gDe(t),kDe(t),zPe(t));return e.forEach(n=>n.configure(r)),Object.assign(t,tDe(r),SDe(r),MDe(r),jPe(r))},Fi=class extends XY{config;constructor(...[e]){let r=WPe(e||{});super(r),this.initConfig=r;let n=iOe(r),s=rDe(n),o=BDe(s),i=CDe(o),a=nDe(i),c=vDe(a),u=oOe(c),p=qPe(u,e?.extensions||[]);this.config=p,this.middlewareStack.use(HDe(this.config)),this.middlewareStack.use(sDe(this.config)),this.middlewareStack.use(GDe(this.config)),this.middlewareStack.use(LDe(this.config)),this.middlewareStack.use(oDe(this.config)),this.middlewareStack.use(iDe(this.config)),this.middlewareStack.use(aDe(this.config)),this.middlewareStack.use(cDe(this.config,{httpAuthSchemeParametersProvider:rOe,identityProviderConfigProvider:async d=>new uDe({"aws.auth#sigv4":d.credentials})})),this.middlewareStack.use(lDe(this.config))}destroy(){super.destroy()}},Je=EDe(aOe,"LambdaWeb","LambdaWebClient",PDe),Xe={},Ze=(t,e,r,n)=>[],U_=class extends Je(Xe,Ze,"CreateWebFunction",pJ){},B_=class extends Je(Xe,Ze,"CreateWebFunctionEndpoint",fJ){},G_=class extends Je(Xe,Ze,"CreateWebFunctionRevision",mJ){},H_=class extends Je(Xe,Ze,"DeleteResourcePolicy",hJ){},V_=class extends Je(Xe,Ze,"DeleteWebFunction",gJ){},W_=class extends Je(Xe,Ze,"DeleteWebFunctionEndpoint",SJ){},z_=class extends Je(Xe,Ze,"DeleteWebFunctionRevision",EJ){},j_=class extends Je(Xe,Ze,"GetResourcePolicy",yJ){},q_=class extends Je(Xe,Ze,"GetWebAccountSettings",_J){},Vc=class extends Je(Xe,Ze,"GetWebFunction",RJ){},Ui=class extends Je(Xe,Ze,"GetWebFunctionEndpoint",TJ){},up=class extends Je(Xe,Ze,"GetWebFunctionRevision",AJ){},K_=class extends Je(Xe,Ze,"ListTags",IJ){},lp=class extends Je(Xe,Ze,"ListWebFunctionEndpoints",xJ){},dp=class extends Je(Xe,Ze,"ListWebFunctionRevisions",CJ){},pp=class extends Je(Xe,Ze,"ListWebFunctions",bJ){},Y_=class extends Je(Xe,Ze,"PutResourcePolicy",wJ){},Q_=class extends Je(Xe,Ze,"TagResource",DJ){},J_=class extends Je(Xe,Ze,"UntagResource",OJ){},X_=class extends Je(Xe,Ze,"UpdateWebFunctionEndpoint",vJ){},PJ=Zb(Fi,lp,"nextToken","nextToken","maxResults"),NJ=Zb(Fi,dp,"nextToken","nextToken","maxResults"),kJ=Zb(Fi,pp,"nextToken","nextToken","maxResults"),MJ=async(t,e)=>{let r;try{let n=await t.send(new Vc(e));r=n;try{if(n.state==="Active")return{state:ve.SUCCESS,reason:r}}catch{}try{if(n.state==="Failed")return{state:ve.FAILURE,reason:r}}catch{}try{if(n.state==="Deleting")return{state:ve.FAILURE,reason:r}}catch{}try{if(n.state==="Pending")return{state:ve.RETRY,reason:r}}catch{}}catch(n){r=n}return{state:ve.RETRY,reason:r}},KPe=async(t,e)=>Fr({...{minDelay:1,maxDelay:300},...t},e,MJ),LJ=async(t,e)=>{let n=await Fr({...{minDelay:1,maxDelay:300},...t},e,MJ);return Wc(n)},$J=async(t,e)=>{let r;try{let n=await t.send(new Vc(e));r=n;try{if(n.state==="Deleting")return{state:ve.RETRY,reason:r}}catch{}}catch(n){if(r=n,n.name==="ResourceNotFoundException")return{state:ve.SUCCESS,reason:r}}return{state:ve.RETRY,reason:r}},YPe=async(t,e)=>Fr({...{minDelay:1,maxDelay:300},...t},e,$J),FJ=async(t,e)=>{let n=await Fr({...{minDelay:1,maxDelay:300},...t},e,$J);return Wc(n)},UJ=async(t,e)=>{let r;try{let n=await t.send(new Ui(e));r=n;try{if(n.state==="Active")return{state:ve.SUCCESS,reason:r}}catch{}try{if(n.state==="Failed")return{state:ve.FAILURE,reason:r}}catch{}try{if(n.state==="Deleting")return{state:ve.FAILURE,reason:r}}catch{}try{if(n.state==="Pending")return{state:ve.RETRY,reason:r}}catch{}}catch(n){r=n}return{state:ve.RETRY,reason:r}},QPe=async(t,e)=>Fr({...{minDelay:1,maxDelay:300},...t},e,UJ),BJ=async(t,e)=>{let n=await Fr({...{minDelay:1,maxDelay:300},...t},e,UJ);return Wc(n)},GJ=async(t,e)=>{let r;try{let n=await t.send(new Ui(e));r=n;try{if(n.state==="Deleting")return{state:ve.RETRY,reason:r}}catch{}}catch(n){if(r=n,n.name==="ResourceNotFoundException")return{state:ve.SUCCESS,reason:r}}return{state:ve.RETRY,reason:r}},JPe=async(t,e)=>Fr({...{minDelay:1,maxDelay:300},...t},e,GJ),HJ=async(t,e)=>{let n=await Fr({...{minDelay:1,maxDelay:300},...t},e,GJ);return Wc(n)},VJ=async(t,e)=>{let r;try{let n=await t.send(new Ui(e));r=n;try{if(n.updateStatus==="Successful")return{state:ve.SUCCESS,reason:r}}catch{}try{if(n.updateStatus==="Failed")return{state:ve.FAILURE,reason:r}}catch{}try{if(n.updateStatus==="InProgress")return{state:ve.RETRY,reason:r}}catch{}}catch(n){r=n}return{state:ve.RETRY,reason:r}},XPe=async(t,e)=>Fr({...{minDelay:1,maxDelay:300},...t},e,VJ),WJ=async(t,e)=>{let n=await Fr({...{minDelay:1,maxDelay:300},...t},e,VJ);return Wc(n)},zJ=async(t,e)=>{let r;try{let n=await t.send(new up(e));r=n;try{if(n.state==="Active")return{state:ve.SUCCESS,reason:r}}catch{}try{if(n.state==="Failed")return{state:ve.FAILURE,reason:r}}catch{}try{if(n.state==="Pending")return{state:ve.RETRY,reason:r}}catch{}}catch(n){r=n}return{state:ve.RETRY,reason:r}},ZPe=async(t,e)=>Fr({...{minDelay:1,maxDelay:300},...t},e,zJ),jJ=async(t,e)=>{let n=await Fr({...{minDelay:1,maxDelay:300},...t},e,zJ);return Wc(n)},eNe={CreateWebFunctionCommand:U_,CreateWebFunctionEndpointCommand:B_,CreateWebFunctionRevisionCommand:G_,DeleteResourcePolicyCommand:H_,DeleteWebFunctionCommand:V_,DeleteWebFunctionEndpointCommand:W_,DeleteWebFunctionRevisionCommand:z_,GetResourcePolicyCommand:j_,GetWebAccountSettingsCommand:q_,GetWebFunctionCommand:Vc,GetWebFunctionEndpointCommand:Ui,GetWebFunctionRevisionCommand:up,ListTagsCommand:K_,ListWebFunctionEndpointsCommand:lp,ListWebFunctionRevisionsCommand:dp,ListWebFunctionsCommand:pp,PutResourcePolicyCommand:Y_,TagResourceCommand:Q_,UntagResourceCommand:J_,UpdateWebFunctionEndpointCommand:X_},tNe={paginateListWebFunctionEndpoints:PJ,paginateListWebFunctionRevisions:NJ,paginateListWebFunctions:kJ},rNe={waitUntilWebFunctionActive:LJ,waitUntilWebFunctionDeleted:FJ,waitUntilWebFunctionEndpointActive:BJ,waitUntilWebFunctionEndpointDeleted:HJ,waitUntilWebFunctionEndpointUpdated:WJ,waitUntilWebFunctionRevisionActive:jJ},Z_=class extends Fi{};yDe(eNe,Z_,{paginators:tNe,waiters:rNe});var nNe={DEBUG:"DEBUG",ERROR:"ERROR",FATAL:"FATAL",INFO:"INFO",TRACE:"TRACE",WARN:"WARN"},sNe={APPLICATION_MANAGED:"ApplicationManaged",IAM_AUTH:"IamAuth"},oNe={DISABLED:"Disabled",LATEST_REVISION:"LatestRevision"},iNe={HOME_REGION:"HomeRegion",MULTI_REGION:"MultiRegion",PER_REGION:"PerRegion"},aNe={DEBUG:"DEBUG",INFO:"INFO",WARN:"WARN"},cNe={ACTIVE:"Active",DELETING:"Deleting",FAILED:"Failed",PENDING:"Pending"},uNe={FAILED:"Failed",IN_PROGRESS:"InProgress",SUCCESSFUL:"Successful"},lNe={ACTIVE:"Active",FAILED:"Failed",PENDING:"Pending"},dNe={ACTIVE:"Active",DELETING:"Deleting",FAILED:"Failed",PENDING:"Pending"};A.AccessDeniedException=P_;A.AccessDeniedException$=uQ;A.AccountQuotas$=SQ;A.AccountUsage$=EQ;A.ApplicationLogLevel=nNe;A.AuthType=sNe;A.AutoDeploymentMode=oNe;A.BuildConfig$=gp;A.CodeConfig$=yQ;A.ConflictException=N_;A.ConflictException$=lQ;A.CreateWebFunction$=pJ;A.CreateWebFunctionCommand=U_;A.CreateWebFunctionEndpoint$=fJ;A.CreateWebFunctionEndpointCommand=B_;A.CreateWebFunctionEndpointRequest$=_Q;A.CreateWebFunctionEndpointResponse$=RQ;A.CreateWebFunctionRequest$=TQ;A.CreateWebFunctionResponse$=AQ;A.CreateWebFunctionRevision$=mJ;A.CreateWebFunctionRevisionCommand=G_;A.CreateWebFunctionRevisionRequest$=IQ;A.CreateWebFunctionRevisionResponse$=xQ;A.DeleteResourcePolicy$=hJ;A.DeleteResourcePolicyCommand=H_;A.DeleteResourcePolicyRequest$=CQ;A.DeleteWebFunction$=gJ;A.DeleteWebFunctionCommand=V_;A.DeleteWebFunctionEndpoint$=SJ;A.DeleteWebFunctionEndpointCommand=W_;A.DeleteWebFunctionEndpointRequest$=bQ;A.DeleteWebFunctionRequest$=wQ;A.DeleteWebFunctionRevision$=EJ;A.DeleteWebFunctionRevisionCommand=z_;A.DeleteWebFunctionRevisionRequest$=DQ;A.EndpointConfig$=OQ;A.EndpointState=cNe;A.EndpointType=iNe;A.EndpointUpdateStatus=uNe;A.Filter$=vQ;A.FunctionEndpointSummary$=lw;A.FunctionRevisionSummary$=dw;A.FunctionState=dNe;A.FunctionSummary$=PQ;A.GetResourcePolicy$=yJ;A.GetResourcePolicyCommand=j_;A.GetResourcePolicyRequest$=NQ;A.GetResourcePolicyResponse$=kQ;A.GetWebAccountSettings$=_J;A.GetWebAccountSettingsCommand=q_;A.GetWebAccountSettingsRequest$=MQ;A.GetWebAccountSettingsResponse$=LQ;A.GetWebFunction$=RJ;A.GetWebFunctionCommand=Vc;A.GetWebFunctionEndpoint$=TJ;A.GetWebFunctionEndpointCommand=Ui;A.GetWebFunctionEndpointRequest$=$Q;A.GetWebFunctionEndpointResponse$=FQ;A.GetWebFunctionRequest$=UQ;A.GetWebFunctionResponse$=BQ;A.GetWebFunctionRevision$=AJ;A.GetWebFunctionRevisionCommand=up;A.GetWebFunctionRevisionRequest$=GQ;A.GetWebFunctionRevisionResponse$=HQ;A.InternalServerException=k_;A.InternalServerException$=dQ;A.LambdaWeb=Z_;A.LambdaWebClient=Fi;A.LambdaWebServiceException=En;A.LambdaWebServiceException$=cQ;A.ListTags$=IJ;A.ListTagsCommand=K_;A.ListTagsRequest$=VQ;A.ListTagsResponse$=WQ;A.ListWebFunctionEndpoints$=xJ;A.ListWebFunctionEndpointsCommand=lp;A.ListWebFunctionEndpointsRequest$=zQ;A.ListWebFunctionEndpointsResponse$=jQ;A.ListWebFunctionRevisions$=CJ;A.ListWebFunctionRevisionsCommand=dp;A.ListWebFunctionRevisionsRequest$=qQ;A.ListWebFunctionRevisionsResponse$=KQ;A.ListWebFunctions$=bJ;A.ListWebFunctionsCommand=pp;A.ListWebFunctionsRequest$=YQ;A.ListWebFunctionsResponse$=QQ;A.LoggingConfig$=JQ;A.PutResourcePolicy$=wJ;A.PutResourcePolicyCommand=Y_;A.PutResourcePolicyRequest$=XQ;A.PutResourcePolicyResponse$=ZQ;A.RegionalEndpoint$=eJ;A.ResourceNotFoundException=M_;A.ResourceNotFoundException$=pQ;A.RevisionConfig$=tJ;A.RevisionError$=rJ;A.RevisionState=lNe;A.RevisionWeight$=nJ;A.RuntimeConfig$=sJ;A.S3Object$=oJ;A.ScalingConfig$=Ws;A.ServiceConfig$=Sp;A.ServiceQuotaExceededException=L_;A.ServiceQuotaExceededException$=fQ;A.SystemLogLevel=aNe;A.TagResource$=DJ;A.TagResourceCommand=Q_;A.TagResourceRequest$=iJ;A.TelemetryConfig$=aJ;A.ThrottleConfig$=zs;A.ThrottlingException=$_;A.ThrottlingException$=mQ;A.UntagResource$=OJ;A.UntagResourceCommand=J_;A.UntagResourceRequest$=cJ;A.UpdateWebFunctionEndpoint$=vJ;A.UpdateWebFunctionEndpointCommand=X_;A.UpdateWebFunctionEndpointRequest$=uJ;A.UpdateWebFunctionEndpointResponse$=lJ;A.ValidationException=F_;A.ValidationException$=hQ;A.errorTypeRegistries=gQ;A.paginateListWebFunctionEndpoints=PJ;A.paginateListWebFunctionRevisions=NJ;A.paginateListWebFunctions=kJ;A.waitForWebFunctionActive=KPe;A.waitForWebFunctionDeleted=YPe;A.waitForWebFunctionEndpointActive=QPe;A.waitForWebFunctionEndpointDeleted=JPe;A.waitForWebFunctionEndpointUpdated=XPe;A.waitForWebFunctionRevisionActive=ZPe;A.waitUntilWebFunctionActive=LJ;A.waitUntilWebFunctionDeleted=FJ;A.waitUntilWebFunctionEndpointActive=BJ;A.waitUntilWebFunctionEndpointDeleted=HJ;A.waitUntilWebFunctionEndpointUpdated=WJ;A.waitUntilWebFunctionRevisionActive=jJ});var gNe={};at(gNe,{clock:()=>Ep,isComplete:()=>mNe,onEvent:()=>fNe});module.exports=O(gNe);var aR=ye(Nq()),cR=ye(VY()),qi=ye(qJ()),pNe=5*6e4,Ep={now:()=>Date.now(),sleep:t=>new Promise(e=>setTimeout(e,t))};async function fNe(t){let e=QJ(t),r=new qi.LambdaWebClient({region:e.region}),n=t.RequestType==="Create"?KJ(e):t.PhysicalResourceId,s={PhysicalResourceId:n,Data:{Action:"none"}};if(t.RequestType==="Delete"){let g=hNe(t.PhysicalResourceId);if(!g||!await Sw(t.StackId))return s;let E=await iR(r,e);return!E||hw(E.revisionWeights,g)?s:(Br("rollback: restoring the weights from before this deployment",{endpoint:e.endpointName,weights:g}),await Qc(r,e,g),{PhysicalResourceId:n,Data:{Action:"switch",TargetWeights:JSON.stringify(g)}})}let o=await iR(r,e);if(!o)return Br("endpoint does not exist yet: CloudFormation creates it with all traffic on the revision",{endpoint:e.endpointName}),s;let i=JJ(o),a=t.RequestType==="Create"?KJ(e,i):n,c=[{revisionId:e.revisionId,weight:100}];if(hw(i,c))return Br("endpoint already serves the revision",{endpoint:e.endpointName,revisionId:e.revisionId}),{PhysicalResourceId:a,Data:{Action:"none"}};if(await Sw(t.StackId))return Br("stack is rolling back: switching all at once, without alarms",{endpoint:e.endpointName,from:i,to:c}),await Qc(r,e,c),{PhysicalResourceId:a,Data:{Action:"switch",TargetWeights:JSON.stringify(c)}};let u=await tX(e.alarmArns);if(u.length>0)throw new Error(`Not deploying ${e.revisionId} to endpoint ${e.endpointName}: alarm ${u.join(", ")} is already in ALARM. Nothing was changed.`);let p=i.find(g=>g.revisionId===e.revisionId)?.weight??0,d=XJ(i,e.revisionId),m=p>0?e.steps.find(g=>g>=p):e.steps[0];return(i.length>2||i.length===2&&p===0)&&Br("endpoint routes to revisions other than the new one; the first step leaves only the one with the most traffic",{live:i,previous:d}),Br("starting deployment",{endpoint:e.endpointName,from:i,revisionId:e.revisionId,steps:e.steps,waitSeconds:e.waitSeconds}),await Qc(r,e,ZJ(d,e.revisionId,m)),{PhysicalResourceId:a,Data:{Action:"shift",PreviousWeights:JSON.stringify(i)}}}async function mNe(t){let e=t.Data??{Action:"none"};if(e.Action==="none")return{IsComplete:!0};let r=QJ(t),n=new qi.LambdaWebClient({region:r.region}),s=await iR(n,r);if(!s){if(t.RequestType==="Delete")return{IsComplete:!0};throw new Error(`Endpoint ${r.endpointName} was deleted during the deployment`)}if(eX(s))return{IsComplete:!1};let o=JJ(s);if(e.Action==="switch"){let g=JSON.parse(e.TargetWeights),E=gw(s);if(E.length>0)throw new Error(`Endpoint ${r.endpointName} failed to update in ${E.join("; ")}`);return hw(o,g)?{IsComplete:!0}:(Br("weights differ from the rollback target; writing them again",{live:o,target:g}),await Qc(n,r,g),{IsComplete:!1})}let i=JSON.parse(e.PreviousWeights);if(await Sw(t.StackId))throw new Error(`Stack is rolling back: stopped deploying ${r.revisionId} to endpoint ${r.endpointName}`);let a=o.find(g=>g.revisionId===r.revisionId)?.weight??0;if(!r.steps.includes(a)||o.length>2)throw new Error(`Endpoint ${r.endpointName} was changed by someone else during the deployment (weights ${mw(o)}); stopped without changing it`);let c=gw(s);if(c.length>0)throw await YJ(n,r,i),new Error(`Endpoint ${r.endpointName} failed to update in ${c.join("; ")}. Restored ${mw(i)}.`);let u=await tX(r.alarmArns);if(u.length>0)throw await YJ(n,r,i),new Error(`Alarm ${u.join(", ")} went into ALARM with ${a}% of endpoint ${r.endpointName} on ${r.revisionId}. Restored ${mw(i)}.`);if(a===100)return Br("deployment complete",{endpoint:r.endpointName,revisionId:r.revisionId}),{IsComplete:!0};if((s.updatedAt?.getTime()??0)+r.waitSeconds*1e3-Ep.now()>0)return{IsComplete:!1};let m=r.steps.find(g=>g>a);return Br("next step",{endpoint:r.endpointName,revisionId:r.revisionId,from:a,to:m}),await Qc(n,r,ZJ(XJ(o,r.revisionId),r.revisionId,m)),{IsComplete:!1}}function QJ(t){let e=t.ResourceProperties;return{region:e.FunctionArn.split(":")[3],functionArn:e.FunctionArn,endpointName:e.EndpointName,revisionId:e.RevisionId,steps:e.Steps.split(",").map(Number),waitSeconds:Number(e.WaitSeconds),alarmArns:e.AlarmArns??[]}}function KJ(t,e){let r=`${t.functionArn}/endpoint/${t.endpointName}/traffic-shift`;return e?`${r}#${e.map(n=>`${n.revisionId}:${n.weight}`).join(",")}`:r}function hNe(t){let e=t.split("#")[1];if(e)return e.split(",").map(r=>{let[n,s]=r.split(":");return{revisionId:n,weight:Number(s)}})}async function iR(t,e){try{return await t.send(new qi.GetWebFunctionEndpointCommand({functionName:e.functionArn,endpointName:e.endpointName}))}catch(r){if(r.name==="ResourceNotFoundException")return;throw r}}async function Qc(t,e,r){let{functionArn:n,endpointName:s}=e;await t.send(new qi.UpdateWebFunctionEndpointCommand({functionName:n,endpointName:s,revisionWeights:r}))}async function YJ(t,e,r){Br("restoring the previous weights",{endpoint:e.endpointName,weights:r}),await Qc(t,e,r);let n=Ep.now()+pNe;for(;Ep.now()<n;){await Ep.sleep(5e3);let s=await iR(t,e);if(s&&!eX(s)){let o=gw(s);o.length>0&&Br("restore failed in some regions",{failed:o});return}}Br("restore still in progress; not waiting any longer",{endpoint:e.endpointName})}function JJ(t){return(t.revisionWeights??[]).map(e=>({revisionId:e.revisionId,weight:e.weight}))}function hw(t,e){let r=n=>n.filter(s=>s.weight>0).map(s=>`${s.revisionId}:${s.weight}`).sort().join(",");return r(t??[])===r(e)}function XJ(t,e){return t.filter(n=>n.revisionId!==e).sort((n,s)=>s.weight-n.weight)[0].revisionId}function ZJ(t,e,r){return r>=100?[{revisionId:e,weight:100}]:[{revisionId:t,weight:100-r},{revisionId:e,weight:r}]}function eX(t){return t.updateStatus==="InProgress"||Object.values(t.regionalEndpoints??{}).some(e=>e.updateStatus==="InProgress")}function gw(t){let e=Object.entries(t.regionalEndpoints??{}).filter(([,r])=>r.updateStatus==="Failed").map(([r,n])=>`${r}: ${n.updateStatusReason??"no reason given"}`);return e.length===0&&t.updateStatus==="Failed"&&e.push(t.updateStatusReason??"no reason given"),e}async function Sw(t){let r=await new aR.CloudFormationClient({region:t.split(":")[3]}).send(new aR.DescribeStacksCommand({StackName:t}));return/ROLLBACK/.test(r.Stacks?.[0]?.StackStatus??"")}async function tX(t){let e=new Map;for(let n of t){let s=n.split(":");e.set(s[3],[...e.get(s[3])??[],s.slice(6).join(":")])}let r=[];for(let[n,s]of e){let o=new cR.CloudWatchClient({region:n}),i=new Map;for(let c=0;c<s.length;c+=100){let u=await o.send(new cR.DescribeAlarmsCommand({AlarmNames:s.slice(c,c+100),AlarmTypes:["MetricAlarm","CompositeAlarm"]}));for(let p of[...u.MetricAlarms??[],...u.CompositeAlarms??[]])i.set(p.AlarmName,p.StateValue)}let a=s.filter(c=>!i.has(c));if(a.length>0)throw new Error(`Alarm ${a.join(", ")} not found in ${n}`);r.push(...s.filter(c=>i.get(c)==="ALARM").map(c=>e.size>1?`${c} (${n})`:c))}return r}function mw(t){return t.map(e=>`${e.revisionId} ${e.weight}%`).join(", ")}function Br(t,e){console.log(JSON.stringify({msg:t,...e}))}0&&(module.exports={clock,isComplete,onEvent});